[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua's great (and LuaJIT's broken)
- From: Mike Pall <mikelu-0806@...>
- Date: Sat, 28 Jun 2008 00:28:48 +0200
Sebastien Loisel wrote:
> I haven't had problems compiling it either! But the .exe doesn't work. Why
> don't you make a .exe that you distribute on your web site?
Because Lua (and LuaJIT, too) is meant to be embedded. Few people
use it solely as a standalone language (especially on Windows).
And if it's embedded into a C/C++ program, then it must be
compiled with exactly the same compiler you used to compile the
rest of your application or you'll wreak havoc on Windows.
So, how many compilers do I need to buy and how many variations of
EXEs and DLLs do I need to distribute? And how many Windows VMs do
I need to set up to avoid all of these compilers stomping on each
other? I think I cannot solve this. LuaJIT is squarely aimed at
developers and they are usually happier when they can compile from
source.
[And no, the situation is not different with the free compilers
available for Windows. There are just too many versions.]
> In this email, I will show you what happens in Vista and Cygwin. I will
> mention what happens in MinGW and XP (without redoing it), but if you want
> me to redo it, I can also do that.
Well, the CygWin target is still in there, but few people use it.
The install target cannot be used for MinGW and CygWin, because it
assumes a Unix layout (i.e. without the DLL). So just follow the
instructions in the install docs for Windows.
> At this point, the window "luajit.exe has stopped working..." pops up once.
No idea what this could be without a more detailed error message.
> In XP, the "crash" or hang is much less interesting. Instead of popping up
> this "luajit.exe has stopped working..." window, it just returns to the
> prompt without doing anything. It also had some interesting behavior in gdb.
> In MinGW, I used "make mingw". There is the additional problem that the
> lua5.1.dll or whatever it's called, wasn't copied anywhere where it could be
> found. Once I fixed that, I was able to start luajit.exe, which went into an
> infinite loop.
Depressing, certainly. I haven't installed MinGW natively on
Windows, but rather cross-compile from Linux. The resulting
EXE/DLL works just fine on Windows. I have no idea what's going
wrong here (since it uses the same compiler (GCC) after all).
[And if you really, really cannot get it to work, I can
temporarily put up a MinGW cross-compiled LuaJIT binary for you.]
--Mike