forked from codeplea/tinyexpr
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
51 lines (35 loc) · 1.08 KB
/
Makefile
File metadata and controls
51 lines (35 loc) · 1.08 KB
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
CC = gcc
CCFLAGS = -Wall -Wshadow -O2
LFLAGS = -lm
.PHONY = all clean
all: smoke smoke_pr repl bench example example2 example3 array_test bitwise_test
smoke: smoke.c tinyexpr.c
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
./$@
smoke_pr: smoke.c tinyexpr.c
$(CC) $(CCFLAGS) -DTE_POW_FROM_RIGHT -DTE_NAT_LOG -o $@ $^ $(LFLAGS)
./$@
repl: repl.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
repl-readline: repl-readline.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS) -lreadline
bench: benchmark.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
example: example.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
example2: example2.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
example3: example3.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
array_test: array_test.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
./$@
bitwise_test: bitwise_test.o tinyexpr.o
$(CC) $(CCFLAGS) -o $@ $^ $(LFLAGS)
./$@
repl-readline.o: repl.c
$(CC) -c -DUSE_READLINE $(CCFLAGS) $< -o $@
.c.o:
$(CC) -c $(CCFLAGS) $< -o $@
clean:
rm -f *.o *.exe example example2 example3 bench repl smoke_pr smoke