aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Celes <celes@tecgraf.puc-rio.br>1993-12-17 16:59:10 -0200
committerWaldemar Celes <celes@tecgraf.puc-rio.br>1993-12-17 16:59:10 -0200
commit2f5ff96e8fb70c5cf1589c788af34f0b2e73d1ae (patch)
treec7c2071bee9e46a98b34234201cac4f2cc0c5a1c
parenteca011188687bfacdfff221d8db190d817570599 (diff)
downloadlua-2f5ff96e8fb70c5cf1589c788af34f0b2e73d1ae.tar.gz
lua-2f5ff96e8fb70c5cf1589c788af34f0b2e73d1ae.tar.bz2
lua-2f5ff96e8fb70c5cf1589c788af34f0b2e73d1ae.zip
LUA makefile
-rw-r--r--makefile52
1 files changed, 52 insertions, 0 deletions
diff --git a/makefile b/makefile
new file mode 100644
index 00000000..6f785e79
--- /dev/null
+++ b/makefile
@@ -0,0 +1,52 @@
1# $Id: $
2# Compilation parameters
3CC = gcc
4CFLAGS = -I/usr/5include -Wall -DMAXCODE=4096 -DMAXCONSTANT=1024 -DMAXSYMBOL=1024
5
6AR = ar
7ARFLAGS = rvl
8
9# Aplication modules
10LUAMOD = \
11 lex.yy \
12 y.tab \
13 opcode \
14 hash \
15 table \
16 inout
17
18LIBMOD = \
19 iolib \
20 strlib \
21 mathlib
22
23LUAOBJS = $(LUAMOD:%=%.o)
24
25LIBOBJS = $(LIBMOD:%=%.o)
26
27lua : lua.o lua.a lualib.a
28 $(CC) $(CFLAGS) -o $@ lua.c lua.a lualib.a -lm
29
30lua.a : lex.yy.c y.tab.c $(LUAOBJS)
31 $(AR) $(ARFLAGS) $@ $?
32 ranlib lua.a
33
34lualib.a : $(LIBOBJS)
35 $(AR) $(ARFLAGS) $@ $?
36 ranlib $@
37
38.KEEP_STATE:
39
40liblua.so.1.0 : lua.o
41 ld -o liblua.so.1.0 $(LUAOBJS)
42
43%.o : %.c
44 $(CC) $(CFLAGS) -c -o $@ $<
45
46lex.yy.c : lua.lex
47 lex lua.lex
48
49y.tab.c : lua.stx
50 yacc -d lua.stx ; ex y.tab.c <exscript
51
52