lua-users home
lua-l archive

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


Paul K wrote:
In a more general case, do I need to provide luasocket compiled with
different runtimes for those people who use them? Is there a way to
check for the version of runtime (maybe a windows API call?) such that
I can load an appropriate dll? Or is it sufficient to provide
mingw-linked and MSVCRT.DLL-linked versions and ask users to use
MSVCRT.DLL-linked one if they see strange crashes while debugging? Or
maybe there is something I can change in luasocket to avoid these
issues?

MSVCRT.DLL is the MinGW (and Visual Studio 6/1998) runtime. Visual Studio links against a different runtime depending upon which version you use (and there is a different runtime for every version VC 2002/2003/2005/2008/2010/2012 plus often for each service pack).

Generally, I think the best thing would be to find out where LuaSocket is going wrong and modifying it to not care about the C Runtime that Lua is built with.

Identifying the runtime would involve looking at the DLLs linked against the lua.dll that the application uses.