Commit | Line | Data |
---|---|---|
4920c9ac | 1 | |
aa5d6bed | 2 | CC=gcc |
5de08d7d CM |
3 | CFLAGS = -g -Wall |
4 | headers = radix-tree.h ctree.h disk-io.h kerncompat.h print-tree.h | |
5 | objects = ctree.o disk-io.o radix-tree.o mkfs.o extent-tree.o print-tree.o | |
eb60ceac | 6 | |
af86d07e | 7 | # if you don't have sparse installed, use ls instead |
aa5d6bed CM |
8 | CHECKFLAGS=-D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ -Wbitwise \ |
9 | -Wcontext -Wcast-truncate -Wuninitialized -Wshadow -Wundef | |
10 | check=sparse $(CHECKFLAGS) | |
af86d07e CM |
11 | #check=ls |
12 | ||
13 | .c.o: | |
14 | $(check) $< | |
15 | $(CC) $(CFLAGS) -c $< | |
eb60ceac | 16 | |
fec577fb CM |
17 | all: tester debug-tree |
18 | ||
19 | debug-tree: $(objects) debug-tree.o | |
20 | gcc $(CFLAGS) -o debug-tree $(objects) debug-tree.o | |
21 | ||
22 | tester: $(objects) random-test.o | |
23 | gcc $(CFLAGS) -o tester $(objects) random-test.o | |
4920c9ac | 24 | |
5de08d7d CM |
25 | $(objects) : $(headers) |
26 | ||
27 | clean : | |
7cf75962 | 28 | rm debug-tree tester *.o |
4920c9ac | 29 | |
fec577fb | 30 |