lua-users home
lua-l archive

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


Am 12.07.2016 um 15:00 schröbte Nagaev Boris:
On Tue, Jul 12, 2016 at 1:41 PM, Tom Sutcliffe <tomsci@me.com> wrote:
Hi list,


Hi!

In an ideal world I would build Lua as a DLL, have both the EXE and the extension DLL link against the Lua DLL, then there'd only ever be 1 version of the static data as nature intended.

You can compile Lua twice:
   - as DLL and link Lua C modules against that DLL,
   - then compile Lua statically as a part of your main executable.

Well, and the above mentioned DLL should be a proxy DLL. See here[1] (also look at the links at the bottom).

AFAIK, it's also possible to export the Lua API from the main executable and link the extension modules directly against said executable instead of a DLL, but I've never done that myself.


Philipp

  [1]: http://lua-users.org/wiki/LuaProxyDll