|
Luiz Henrique de Figueiredo wrote:
first, use luac to compile it to bytecode second, make the byte code a C char array and include it into your C file third. use lua_loadbuffer to load your C string. and last, use pcall to run it.Or use my srlua: http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/#srlua
Or my Solitary http://mraleph.gorodok.net/solitary_bin.rarIt is based on top of srlua. But have some additional features (namely, transparent modules and DLLs packing). (I can not really remember whether Solitary contains srlua code or just was inspired by srlua) For example single solpack.exe wraps together solpack.lua, solpacker.dll and lfs.dll. Still Solitary is just an internal-toy-tool. No documentation (only one sample project). It was only tested under Windows XP. No *nix version and no Vista support either.
Sources will be provided upon request. Regards, e.v.e