1997-09-16 23:33:21 +04:00
|
|
|
#
|
2004-05-01 00:13:38 +04:00
|
|
|
## $Id: makefile,v 2.1 2003/12/10 12:13:36 roberto Exp roberto $
|
1997-09-16 23:33:21 +04:00
|
|
|
## Makefile
|
|
|
|
## See Copyright Notice in lua.h
|
|
|
|
#
|
|
|
|
|
1995-10-09 21:51:49 +03:00
|
|
|
|
1997-09-16 23:33:21 +04:00
|
|
|
#CONFIGURATION
|
1995-10-09 21:51:49 +03:00
|
|
|
|
2003-03-20 00:27:30 +03:00
|
|
|
# -DEXTERNMEMCHECK -DHARDSTACKTESTS
|
2003-12-10 15:13:36 +03:00
|
|
|
DEBUG = -g -DLUA_USER_H='"ltests.h"'
|
2002-08-06 23:12:54 +04:00
|
|
|
OPTIMIZE = -O2 \
|
2003-03-20 00:27:30 +03:00
|
|
|
# -fomit-frame-pointer
|
2002-08-06 23:12:54 +04:00
|
|
|
|
2001-07-24 21:25:30 +04:00
|
|
|
|
2004-05-01 00:13:38 +04:00
|
|
|
# -DUSE_TMPNAME??
|
|
|
|
CONFIG = $(DEBUG) $(OPTIMIZE) -DLUA_COMPATUPSYNTAX -DUSE_DLOPEN
|
1997-07-01 23:32:41 +04:00
|
|
|
|
|
|
|
|
1993-12-17 21:59:10 +03:00
|
|
|
# Compilation parameters
|
2002-03-18 21:18:35 +03:00
|
|
|
CC = gcc
|
2002-02-15 00:49:33 +03:00
|
|
|
CWARNS = -Wall -pedantic \
|
2000-08-09 23:16:57 +04:00
|
|
|
-Waggregate-return \
|
|
|
|
-Wcast-align \
|
|
|
|
-Wmissing-prototypes \
|
2002-02-15 00:49:33 +03:00
|
|
|
-Wstrict-prototypes \
|
2000-08-09 23:16:57 +04:00
|
|
|
-Wnested-externs \
|
|
|
|
-Wpointer-arith \
|
|
|
|
-Wshadow \
|
2001-07-24 21:25:30 +04:00
|
|
|
-Wwrite-strings \
|
2002-02-15 00:49:33 +03:00
|
|
|
# -Wtraditional \
|
2000-08-09 23:16:57 +04:00
|
|
|
# -Wcast-qual
|
|
|
|
|
2003-03-20 00:27:30 +03:00
|
|
|
CFLAGS = $(CONFIG) $(CWARNS) # -ansi
|
1994-11-23 23:15:04 +03:00
|
|
|
|
1993-12-17 21:59:10 +03:00
|
|
|
|
1999-01-11 23:23:54 +03:00
|
|
|
# To make early versions
|
|
|
|
CO_OPTIONS =
|
|
|
|
|
|
|
|
|
1993-12-17 21:59:10 +03:00
|
|
|
AR = ar
|
|
|
|
ARFLAGS = rvl
|
|
|
|
|
1996-11-06 23:48:03 +03:00
|
|
|
|
1993-12-17 21:59:10 +03:00
|
|
|
# Aplication modules
|
1995-11-10 20:56:06 +03:00
|
|
|
LUAOBJS = \
|
2000-04-14 21:52:09 +04:00
|
|
|
lstate.o \
|
1997-09-16 23:33:21 +04:00
|
|
|
lapi.o \
|
|
|
|
lmem.o \
|
|
|
|
lstring.o \
|
|
|
|
ltable.o \
|
|
|
|
ltm.o \
|
|
|
|
lvm.o \
|
2000-04-14 21:52:09 +04:00
|
|
|
ldo.o \
|
|
|
|
lobject.o \
|
|
|
|
lfunc.o \
|
|
|
|
lgc.o \
|
|
|
|
lcode.o \
|
|
|
|
lparser.o \
|
|
|
|
llex.o \
|
2001-07-24 21:25:30 +04:00
|
|
|
lopcodes.o \
|
1997-09-16 23:33:21 +04:00
|
|
|
lundump.o \
|
2002-10-26 01:38:17 +04:00
|
|
|
ldump.o \
|
2000-02-22 16:31:43 +03:00
|
|
|
lzio.o \
|
2000-04-14 21:52:09 +04:00
|
|
|
ldebug.o \
|
2001-07-24 21:25:30 +04:00
|
|
|
ltests.o
|
1995-11-10 20:56:06 +03:00
|
|
|
|
|
|
|
LIBOBJS = \
|
2000-09-12 00:29:27 +04:00
|
|
|
lauxlib.o \
|
|
|
|
lbaselib.o \
|
2002-08-06 23:12:54 +04:00
|
|
|
ltablib.o \
|
1997-09-16 23:33:21 +04:00
|
|
|
lmathlib.o \
|
2002-02-15 00:49:33 +03:00
|
|
|
liolib.o \
|
1999-01-08 19:47:44 +03:00
|
|
|
lstrlib.o \
|
2003-03-20 00:27:30 +03:00
|
|
|
ldblib.o \
|
|
|
|
loadlib.o
|
1995-11-10 20:56:06 +03:00
|
|
|
|
1993-12-17 21:59:10 +03:00
|
|
|
|
1996-11-06 23:48:03 +03:00
|
|
|
lua : lua.o liblua.a liblualib.a
|
2003-03-20 00:27:30 +03:00
|
|
|
$(CC) $(CFLAGS) -o $@ lua.o -Wl,-E -L. -llua -llualib -lm -ldl
|
1993-12-17 21:59:10 +03:00
|
|
|
|
1996-11-06 23:48:03 +03:00
|
|
|
liblua.a : $(LUAOBJS)
|
1993-12-17 21:59:10 +03:00
|
|
|
$(AR) $(ARFLAGS) $@ $?
|
1996-11-06 23:48:03 +03:00
|
|
|
ranlib $@
|
1993-12-17 21:59:10 +03:00
|
|
|
|
1996-11-06 23:48:03 +03:00
|
|
|
liblualib.a : $(LIBOBJS)
|
1993-12-17 21:59:10 +03:00
|
|
|
$(AR) $(ARFLAGS) $@ $?
|
|
|
|
ranlib $@
|
|
|
|
|
|
|
|
liblua.so.1.0 : lua.o
|
|
|
|
ld -o liblua.so.1.0 $(LUAOBJS)
|
|
|
|
|
|
|
|
|
1994-07-20 02:04:51 +04:00
|
|
|
clear :
|
|
|
|
rcsclean
|
2000-02-22 16:31:43 +03:00
|
|
|
rm -f *.o *.a
|
1994-07-20 02:04:51 +04:00
|
|
|
|
1996-03-15 21:22:09 +03:00
|
|
|
|
1996-11-06 23:48:03 +03:00
|
|
|
%.h : RCS/%.h,v
|
1999-01-11 23:23:54 +03:00
|
|
|
co $(CO_OPTIONS) $@
|
1996-11-06 23:48:03 +03:00
|
|
|
|
|
|
|
%.c : RCS/%.c,v
|
1999-01-11 23:23:54 +03:00
|
|
|
co $(CO_OPTIONS) $@
|
1994-01-10 22:49:56 +03:00
|
|
|
|
1998-05-27 17:08:34 +04:00
|
|
|
|
2004-05-01 00:13:38 +04:00
|
|
|
lapi.o: lapi.c lua.h luaconf.h lapi.h lobject.h llimits.h ldebug.h \
|
|
|
|
lstate.h ltm.h lzio.h lmem.h ldo.h lfunc.h lgc.h lstring.h ltable.h \
|
2002-10-26 01:38:17 +04:00
|
|
|
lundump.h lvm.h
|
2004-05-01 00:13:38 +04:00
|
|
|
lauxlib.o: lauxlib.c lua.h luaconf.h lauxlib.h
|
|
|
|
lbaselib.o: lbaselib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
lcode.o: lcode.c lua.h luaconf.h lcode.h llex.h lobject.h llimits.h \
|
|
|
|
lzio.h lmem.h lopcodes.h lparser.h ltable.h ldebug.h lstate.h ltm.h \
|
|
|
|
ldo.h lgc.h
|
|
|
|
ldblib.o: ldblib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
ldebug.o: ldebug.c lua.h luaconf.h lapi.h lobject.h llimits.h lcode.h \
|
2003-12-10 15:13:36 +03:00
|
|
|
llex.h lzio.h lmem.h lopcodes.h lparser.h ltable.h ldebug.h lstate.h \
|
2004-05-01 00:13:38 +04:00
|
|
|
ltm.h ldo.h lfunc.h lstring.h lgc.h lvm.h
|
|
|
|
ldo.o: ldo.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h ltm.h \
|
|
|
|
lzio.h lmem.h ldo.h lfunc.h lgc.h lopcodes.h lparser.h ltable.h \
|
|
|
|
lstring.h lundump.h lvm.h
|
|
|
|
ldump.o: ldump.c lua.h luaconf.h lobject.h llimits.h lopcodes.h lstate.h \
|
|
|
|
ltm.h lzio.h lmem.h lundump.h
|
|
|
|
lfunc.o: lfunc.c lua.h luaconf.h lfunc.h lobject.h llimits.h lgc.h lmem.h \
|
|
|
|
lstate.h ltm.h lzio.h
|
|
|
|
lgc.o: lgc.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h ltm.h \
|
|
|
|
lzio.h lmem.h ldo.h lfunc.h lgc.h lstring.h ltable.h
|
|
|
|
liolib.o: liolib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
llex.o: llex.c lua.h luaconf.h ldo.h lobject.h llimits.h lstate.h ltm.h \
|
|
|
|
lzio.h lmem.h llex.h lparser.h ltable.h lstring.h lgc.h
|
|
|
|
lmathlib.o: lmathlib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
lmem.o: lmem.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h \
|
|
|
|
ltm.h lzio.h lmem.h ldo.h
|
|
|
|
loadlib.o: loadlib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
lobject.o: lobject.c lua.h luaconf.h ldo.h lobject.h llimits.h lstate.h \
|
|
|
|
ltm.h lzio.h lmem.h lstring.h lgc.h lvm.h
|
|
|
|
lopcodes.o: lopcodes.c lua.h luaconf.h lobject.h llimits.h lopcodes.h
|
|
|
|
lparser.o: lparser.c lua.h luaconf.h lcode.h llex.h lobject.h llimits.h \
|
|
|
|
lzio.h lmem.h lopcodes.h lparser.h ltable.h ldebug.h lstate.h ltm.h \
|
|
|
|
ldo.h lfunc.h lstring.h lgc.h
|
|
|
|
lstate.o: lstate.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h \
|
|
|
|
ltm.h lzio.h lmem.h ldo.h lfunc.h lgc.h llex.h lstring.h ltable.h
|
|
|
|
lstring.o: lstring.c lua.h luaconf.h lmem.h llimits.h lobject.h lstate.h \
|
|
|
|
ltm.h lzio.h lstring.h lgc.h
|
|
|
|
lstrlib.o: lstrlib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
ltable.o: ltable.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h \
|
|
|
|
ltm.h lzio.h lmem.h ldo.h lgc.h ltable.h
|
|
|
|
ltablib.o: ltablib.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
ltests.o: ltests.c lua.h luaconf.h lapi.h lobject.h llimits.h lauxlib.h \
|
|
|
|
lcode.h llex.h lzio.h lmem.h lopcodes.h lparser.h ltable.h ldebug.h \
|
|
|
|
lstate.h ltm.h ldo.h lfunc.h lstring.h lgc.h lualib.h
|
|
|
|
ltm.o: ltm.c lua.h luaconf.h lobject.h llimits.h lstate.h ltm.h lzio.h \
|
|
|
|
lmem.h lstring.h lgc.h ltable.h
|
|
|
|
lua.o: lua.c lua.h luaconf.h lauxlib.h lualib.h
|
|
|
|
lundump.o: lundump.c lua.h luaconf.h ldebug.h lstate.h lobject.h \
|
|
|
|
llimits.h ltm.h lzio.h lmem.h ldo.h lfunc.h lopcodes.h lstring.h lgc.h \
|
|
|
|
lundump.h
|
|
|
|
lvm.o: lvm.c lua.h luaconf.h ldebug.h lstate.h lobject.h llimits.h ltm.h \
|
|
|
|
lzio.h lmem.h ldo.h lfunc.h lgc.h lopcodes.h lstring.h ltable.h lvm.h
|
|
|
|
lzio.o: lzio.c lua.h luaconf.h llimits.h lmem.h lstate.h lobject.h ltm.h \
|
|
|
|
lzio.h
|