lua compiler

Source

https://sourceforge.net/projects/luabinaries/files/ 

http://luabinaries.sourceforge.net/download.html

Article Source

https://www.cnblogs.com/findumars/p/4415264.html

Because you want to provide a script function in a native application, the release of Python and say that it is a hassle. Because the required script function is very simple, so we decided to try the legendary Lua.

The first step, download the source code. Although Lua has provided binary version download, but because I am using Turbo C ++ Explorer (that is, C ++ Builder free version), so I decided to compile it yourself at the source. Of course, the download location is Lua's official website: http://www.lua.org .

The second step, compile and install. Only source in GCC provides a BAT file with the MAKE file and use the VC, BCB you need to do it yourself. I do not know where to start wrong, the compiler does not always - though compiles successfully, but execution error. Toss for a while before finally done, the appropriate compiler parameters are as follows:

bcc32 -DNDEBUG -DNO_STRICT; _NO_VCL -Hc -tWD -W-par -O2 -b- -k- -vi -tWM -tW- -c -DLUA_BUILD_AS_DLL -P- l * .c 
del lua.obj 
del luac.obj 
ilink32 -Tpd -Gn -j -x -Gi c0d32.obj lapi.obj lauxlib.obj lbaselib.obj lcode.obj ldblib.obj ldebug.obj ldo.obj ldump.obj lfunc.obj lgc.obj linit.obj liolib.obj llex .obj lmathlib.obj lmem.obj loadlib.obj lobject.obj lopcodes.obj loslib.obj lparser.obj lstate.obj lstring.obj lstrlib.obj ltable.obj ltablib.obj ltm.obj lundump.obj lvm.obj lzio.obj lua51.dll, import32.lib cw32mt.lib, 
del * .tds 
del * .obj 
bcc32 -D_isatty = isatty -DNDEBUG -DNO_STRICT; _NO_VCL -Hc -W-par -O2 -b- -k- -vi - TWC -tWM -tW- -c -DLUA_BUILD_AS_DLL -P- lua.c 
ilink32 -Tpe -Gn -j -x c0x32.obj lua.obj, lua51.exe, import32.lib lua51.lib cw32mt .lib, 
del * .tds 
del * .obj

The third step, Hello world. Successful run compiler lua51.exe try:

print "Hello world!"

Get.

All that remains is reading Yun Feng translated document LUA learn - well, the older the difficulty of learning something new after the most. -_- |||

Reference: http: //blog.csdn.net/raptor/article/details/1572207

Guess you like

Origin www.cnblogs.com/marklove/p/11921719.html