lua-users home
lua-l archive

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

This is the 1st thing I wanted to have in Lua, so I came up w/ a quite crude solution, see there:

Limitations are described there.
If you need the sources just drop me a mail.

Regards, Frank

Mike Crowe wrote:

Hi folks,

This is probably very easy, but I can't seem to see how to do it. I have a complete project of ~12 .lua files that I want to distribute. Windows platform. Assume destination has lua.exe and luac.exe

I thought the answer was to:
   luac -o myfile.luac file1.lua file2.lua file3.lua .... file12.lua

That creates "myfile.luac" that appears to be all the files together.

However, if I copy this file to a new directory, and execute:
   lua myfile.luac

I get an error like:
lua: cannot read compat.lua: No such file or directory
stack traceback:
       [C]: in function `dofile'
       all.lua:9: in main chunk
       (luac): in main chunk
       [C]: ?

(compat.lua is one of the files in my project).

What am I missing here?

No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 10.02.2005