lua-users home
lua-l archive

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


Luiz and Peter,

Thanks to both of you for your quick responses. That description makes
sense. After updating to 5.1.4, I didn't think about the compiler changing
as well. I have just created a new luac.exe from 5.1.4 and everything works.
Thanks again!

Michael


-----Original Message-----
From: lua-l-bounces@lists.lua.org [mailto:lua-l-bounces@lists.lua.org] On
Behalf Of Luiz Henrique de Figueiredo
Sent: Saturday, October 23, 2010 11:44 AM
To: Lua mailing list
Subject: Re: precompiled code problem in 5.1.4

> We updated to Lua 5.1.4 and our Windows app fails trying to load a
> pre-compiled lua library. Specifically, luaL_loadfile() returns 3 and the
> error message is "bad header in precompiled chunk". This library was
created
> using luac.exe dated March 19 2004 (114,688 bytes).

Given the date of your luac.exe, it's definitely not Lua 5.1. So the message
is saying (but not too clearly) that you have the wrong version. Precompiled
Lua scripts can only be loaded in the same version of Lua with which they
were
created. Did you lose the original source files?