From a06b97ab1b8399a50366816f226fd98d59d022cd Mon Sep 17 00:00:00 2001 From: Nishi Date: Sat, 14 Sep 2024 15:10:29 +0000 Subject: [PATCH] fix dylib load git-svn-id: file:///raid/svn-personal/tewi/trunk@25 8739d7e6-ffea-ec47-b151-bdff447c6205 --- Makefile | 2 ++ Platform/win64.mk | 2 ++ Server/module.c | 2 +- example.conf | 5 +++-- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 490eddb..423bb44 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,8 @@ PWD = `pwd` PLATFORM = generic PREFIX = /usr/local +include Platform/$(PLATFORM).mk + FLAGS = PWD=$(PWD) PLATFORM=$(PLATFORM) PREFIX=$(PREFIX) .PHONY: all format clean ./Server ./Common ./Module diff --git a/Platform/win64.mk b/Platform/win64.mk index 0871d40..b353c38 100644 --- a/Platform/win64.mk +++ b/Platform/win64.mk @@ -1,5 +1,7 @@ # $Id$ +PREFIX = C:/Tewi + CC = x86_64-w64-mingw32-gcc AR = x86_64-w64-mingw32-ar CFLAGS = -g -std=c99 -DPREFIX=\"$(PREFIX)\" -I $(PWD)/Common -I $(PWD)/openssl/include diff --git a/Server/module.c b/Server/module.c index c7fda36..f4e6db7 100644 --- a/Server/module.c +++ b/Server/module.c @@ -27,7 +27,7 @@ void* tw_module_load(const char* path) { #ifdef __MINGW32__ lib = LoadLibraryA(path); #else - lib = dlopen(path, DL_LAZY); + lib = dlopen(path, RTLD_LAZY); #endif if(lib == NULL) { cm_log("Module", "Could not load %s", path); diff --git a/example.conf b/example.conf index 8e0ec30..a40fbbe 100644 --- a/example.conf +++ b/example.conf @@ -3,8 +3,9 @@ #LoadModule /home/nishi/SVN/tewi/trunk/Module/mod_example.so -Listen 80 -ListenSSL 443 +Listen 8000 +#Listen 80 +#ListenSSL 443 SSLKey key.pem SSLCertificate cert.pem -- 2.45.2