Sign in to follow this  

Lua compiler & dofile

This topic is 3151 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I want to compile a lua library organized over many files. For exemple : main.lua: dofile('memory.lua') dofile('graphics.lua') dofile('ui.lua') luac.exe -o main.lo main.lua The problem I have is that the memory, graphics and ui files are not compiled. The main.lo file only contains references to the "dofile" functions with their parameters. Can you help me?

Share this post


Link to post
Share on other sites
I saw that "require" is best suited for including library scripts but it doesnt solve my problem anyway.

Maybe I can change my main.lua file so that instead of calling "dofile/require" it first compiles the 'memory', 'graphics' and 'ui' scripts to binaries and then calling 'require' on the bin files.

Can I compile a script to bin from lua?

Share this post


Link to post
Share on other sites

This topic is 3151 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this