Download LUA: Go to official website http://www.lua.org
CD lua-5.3.1 into the catalogue
Ls
Makefile README Doc Src
There is a makefile with
Make install install_top= "/mylua"
Installing LUA in the "/mylua" directory that you created is not successful, and it shows that the Lua Luac liblua.a is missing as prompted.
CD src
Enter the SRC directory and find a makefile file
Execute command
Make install LUA Luac LIBLUA.A
The corresponding file is generated in the SRC directory
makefile lcorolib.o lfunc.h lmathlib.o lparser.h ltablib.o lundump.hlapi.c lctype.c lfunc.o lmem.c lparser.o ltm.c lundump.olapi.h lctype.h lgc.c lmem.h lprefix.h ltm.h lutf8lib.clapi.o lctype.o lgc.h lmem.o lstate.c ltm.o Lutf8lib.olauxlib.c ldblib.c lgc.o loadlib.c lstate.h lua lvm.clauxlib.h ldblib.o liblua.a loadlib.o lstate.o lua.c lvm.hlauxlib.o ldebug.c linit.c lobject.c lstring.c lua.h lvm.olbaselib.c ldebug.h linit.o lobject.h lstring.h lua.hpp lzio.clbaselib.o ldebug.o liolib.c lobject.o lstring.o lua.o lzio.hlbitlib.c ldo.c liolib.o lopcodes.c lstrlib.c luac lzio.olbitlib.o ldo.h llex.c lopcodes.h lstrlib.o luac.clcode.c ldo.o llex.h lopcodes.o ltable.c luac.olcode.h ldump.c llex.o loslib.c ltable.h luaconf.hlcode.o ldump.o llimits.h loslib.o ltable.o lualib.hlcorolib.c lfunc.c Lmathlib.c lparser.c ltablib.c lundump.c
At this time CD: Go back to the previous directory and execute
Make install install_top= "/mylua"
Show success
The resulting file directory is as follows:
Bin include Lib man share
Reference: Http://www.lua.org/start.html#installing
This article is from the "c0c0s" blog, make sure to keep this source http://9362125.blog.51cto.com/9352125/1681726
LUA compilation on iOS