-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
57 lines (46 loc) · 930 Bytes
/
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
all: build schemeken
SOURCES= \
Slip/SlipCompile.c \
Slip/SlipCache.c \
Slip/SlipDictionary.c \
Slip/SlipEnvironment.c \
Slip/SlipEvaluate.c \
Slip/SlipGrammar.c \
Slip/SlipMain.c \
Slip/SlipMemory.c \
Slip/SlipNative.c \
Slip/SlipPool.c \
Slip/SlipPrint.c \
Slip/SlipRead.c \
Slip/SlipScan.c \
Slip/SlipStack.c \
Slip/SlipThread.c \
Slip/SlipPersist.c \
Slip/SlipKen.c \
Ken/ken.c \
Ken/kencom.c \
Ken/kencrc.c \
Ken/kenpat.c \
Ken/kenvar.c
ifdef GOBACKN
SOURCES += Ken/kenext_gbn.c
else
SOURCES += Ken/kenext_orig.c
endif
DEBUG_FLAGS=-g
CFLAGS=$(DEBUG_FLAGS) -I Ken -I Slip
LDFLAGS=-Xlinker -no_pie
CFLAGS+=-std=gnu99
OBJECTS=$(addprefix build/,$(notdir $(SOURCES:.c=.o)))
build/%.o: Slip/%.c
gcc -c -o $@ $(CFLAGS) $^
build/%.o: Ken/%.c
gcc -c -o $@ $(CFLAGS) $^
build:
mkdir build build/Slip build/Ken
schemeken: $(OBJECTS)
gcc $(DEBUG_FLAGS) $(LDFLAGS) -o $@ $^
clean:
-rm -r build
-rm schemeken
.PHONY: all