lua-users home
lua-l archive

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

On Sun, 24 Oct 2010 23:20:24 +0800
Johnson Lin <> wrote:

> 2. vanilla Lua is implemented in ANSI C, so what might be preventing
> builds from gcc to work, when builds from msvc worked? I've tried all
> builds of Lua/LuaJIT mentioned above with some luarocks, which have
> prebuilt binaries linked against lua5.1.dll (such as luasocket),
> all of them worked without problems.

I guess this could have something to do with the fact that GCC and MSVC
could be using different versions/copies of msvcrt.dll, and each one of
the DLLs has different stacks, heaps, etc. This leads to funny things
like the fact that you cannot malloc() memory using one copy of the
library and free() it with the other one -- because their “view” of
what's in memory is different.

For some more info on this, consider reading the “Windows and the C
runtime DLLs (msvc*.dll)” section at the BuildingModules page from
the Lua-users wiki [1].

Hope this helps :)

Adrian Perez <>
Igalia - Free Software Engineering

Attachment: signature.asc
Description: PGP signature