Lua is a C script engine (for the Lua languages) and is not distributed in such a nice way. So I spent a few hours preparing a (Python) script to repack Lua 5.3.3 into a single header. (By the time I fix my blog posting stuff 5.3.4 will probably be out)
Merry (belated) Christmas!
Why would you do this?
Mostly to conform to [Sean Nothings Barret’s]() constraints.
Who would care?
Anyone who wants to slap (somewhat) minimal Lua into a project and see what happens.
How did you do this?
I used a python 3.5.1 script to crack open the
.tar.gz file, scan the Makefile, then concatenate sources as needed
- I scan for some test cases that you (obviously) won’t have - sorry
- You’ll need a
.cpp… sorrynotsorry) file for Lua to actually compile … so there’s that.
- … my tests are written in
.cppthough … as is the Catch unit testing framework …
- I used a regex and POSIX line endings to get the whole thing under 1MB
- so that KDiff likes it
- … hopefully, future updates won’t break this