lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> The modification you're asking for doesn't make Lua better, it makes
> it more suited to your application (LfW). But changing the PATH
> environment variable is not the only alternative.

  I do think it makes Lua better because LfW is more than a simple "application". It is a very popular Lua distribution for general use. But if there are alternatives I would like to know them.

 
> In your situation I'd rather patch the lua.exe interpreter so that it
> replaces the default C module searchers with a custom version that use
> LOAD_WITH_ALTERED_SEARCH_PATH. The Lua dll stays intact, should it be
> used by other applications (that may or may not use C modules from the
> LfW install). Only the interpreter application has to know about the
> specific way to load modules, and with a custom searcher that's
> exactly the case.

  How we do that?

 
> And if you don't want to patch Lua, it's still possible to put that
> searcher substition code in a LUA_INIT environment variable.

  No we can't do this, it will not solve the problem of dependent DLLs. Because that DLLs are searched by the system, not by Lua.

Best,
Scuri