[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] Lua 5.1.2-rc3 now available
- From: "Todor Totev" <umbra.tenebris@...>
- Date: Tue, 27 Mar 2007 11:53:49 +0300
This rc fixes the glitches reported earlier.
Please take a look before we freeze it. All feedback welcome. Thanks.
--lhf
Lua still cannot be compiled with Visual Studio 2005 projects created with
default settings. This pops in the list from time to time (I personally
know about 3 threads) so it should be fixed.
The offending lines are in loadlib.c:
(101) GetModuleFileName -> GetModuleFileNameA
(115) FormatMessage -> FormatMessageA
(128) LoadLibrary -> LoadLibraryA
The easiest fix is to use the straight ANSI functions instead of the
define'd names. If you want to make Lua distribution to not depend on
the ANSI functions there is more work to do, because the strings
returned by the OS travels to Lua side for using with scripts.
Even if you do not fix the code, at least give a warning in the INSTALL
file. Something in the lines of:
+++
By default the Lua distribution works with ANSI strings under Windows but
Visual Studio 2005 defines UNICODE when creating projects. Please adjust
the
project settings or the relevant code in loadlib.c. Please note that
strings
returned from the OS travels to Lua side so you may need to manually
convert
between ANSI and UNICODE.
Also you can safely define _CRT_SECURE_NO_DEPRECATE for the Lua files to
avoid
excessive warnings from VC compiler. For more details see
http://msdn2.microsoft.com/en-us/library/8ef0s5kh(VS.80).aspx
+++
And you can change the luavs.bat file to actually define it - just add
/D_CRT_SECURE_NO_DEPRECATE to the command line of the compiler
Regards,
Todor