【修改】修改lua-5.4.6中的makefile,将编译产物生成至output路径中,添加-fPIC方便编译动态库
This commit is contained in:
@@ -10,7 +10,7 @@ PLAT= guess
|
|||||||
# so take care if INSTALL_TOP is not an absolute path. See the local target.
|
# so take care if INSTALL_TOP is not an absolute path. See the local target.
|
||||||
# You may want to make INSTALL_LMOD and INSTALL_CMOD consistent with
|
# You may want to make INSTALL_LMOD and INSTALL_CMOD consistent with
|
||||||
# LUA_ROOT, LUA_LDIR, and LUA_CDIR in luaconf.h.
|
# LUA_ROOT, LUA_LDIR, and LUA_CDIR in luaconf.h.
|
||||||
INSTALL_TOP= /usr/local
|
INSTALL_TOP= ./../../../output
|
||||||
INSTALL_BIN= $(INSTALL_TOP)/bin
|
INSTALL_BIN= $(INSTALL_TOP)/bin
|
||||||
INSTALL_INC= $(INSTALL_TOP)/include
|
INSTALL_INC= $(INSTALL_TOP)/include
|
||||||
INSTALL_LIB= $(INSTALL_TOP)/lib
|
INSTALL_LIB= $(INSTALL_TOP)/lib
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
PLAT= guess
|
PLAT= guess
|
||||||
|
|
||||||
CC= gcc -std=gnu99
|
CC= gcc -std=gnu99
|
||||||
CFLAGS= -O2 -Wall -Wextra -DLUA_COMPAT_5_3 $(SYSCFLAGS) $(MYCFLAGS)
|
CFLAGS= -O2 -Wall -fPIC -Wextra -DLUA_COMPAT_5_3 $(SYSCFLAGS) $(MYCFLAGS)
|
||||||
LDFLAGS= $(SYSLDFLAGS) $(MYLDFLAGS)
|
LDFLAGS= $(SYSLDFLAGS) $(MYLDFLAGS)
|
||||||
LIBS= -lm $(SYSLIBS) $(MYLIBS)
|
LIBS= -lm $(SYSLIBS) $(MYLIBS)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user