-
Notifications
You must be signed in to change notification settings - Fork 19
/
Makefile
60 lines (43 loc) · 1.13 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# $Id: Makefile,v 1.25 2005/05/12 00:29:32 lhf Exp lhf $
# makefile for Lua compiler
LUA= distr
WARN= -Wall -Wextra $(XWARN)
XWARN= -Wc++-compat -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes
XWARN=
CC= gcc -std=gnu99
CFLAGS= -O2 $(WARN) $(INCS) $G
INCS= -I$(LUA)
LIBS= $(LUA)/liblua.a -lm
OBJS= luac.o
SRCS= luac.c
# targets --------------------------------------------------------------------
all: luac
luac: $(OBJS) $(LIBS)
$(CC) -o $@ $(OBJS) $(LIBS)
$(LIBS):
make -C $(LUA) a "CFLAGS=$(CFLAGS)"
print.c: $(LUA)/lopcodes.h
@diff lopcodes.h $(LUA)
clean:
-rm -f luac *.o luac.out a.out core core.* mon.out gmon.out tags luac.lst lua
@#cd test; $(MAKE) $@
co:
co -l -M $(SRCS)
conl:
co -M $(SRCS)
ci:
ci -u $(SRCS)
diff:
@#-rcsdiff $(SRCS) Makefile 2>&1 | awk -f rcsdiff.awk
@-rcsdiff $(SRCS) 2>&1 | awk -f rcsdiff.awk
wl:
@rlog -L -R RCS/* | sed 's/RCS.//;s/,v//'
opp:
grep Kst lopcodes.h | grep ^OP_; echo ''
grep RK lopcodes.h | grep ^OP_; echo ''
grep pc lopcodes.h | grep ^OP_; echo ''
diffd:
-diff ldump.c $(LUA)
-diff lundump.c $(LUA)
-diff lundump.h $(LUA)
-cat luac.c print.c | diff - $(LUA)/luac.c