[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: loadlib options for Windows sytems
- From: Lorenzo Donati <lorenzodonatibz@...>
- Date: Sun, 11 Dec 2011 10:20:17 +0100
Hi all!
On Windows Lua 5.1.4 uses Win32 API function LoadLibrary to load DLLs.
To ameliorate the DLL-hell problem I tweaked loadlib.c in order to make
it use LoadLibraryEx with LOAD_WITH_ALTERED_SEARCH_PATH flag instead.
Lua 5.2.0 apparently adds support for this approach by using
LoadLibraryEx and adding a LUA_LLE_FLAGS macro (see loadlib.c - line
164). I remember having read a lua-l post long ago, but I couldn't find it.
Anyway, I wonder why this hasn't been placed in luaconf.h. Is it still
experimental or has issues? How I'm supposed to use it in a "right way"?
It is sufficient to place the following line somewhere in luaconf.h:
#define LUA_LLE_FLAGS LOAD_WITH_ALTERED_SEARCH_PATH
or should I specify -DLUA_LLE_FLAGS=LOAD_WITH_ALTERED_SEARCH_PATH
when invoking make?
Any suggestion/clarification appreciated!
Cheers.
--Lorenzo