2007-01-26 14:38:42 -07:00
|
|
|
|
2007-02-28 14:35:06 -07:00
|
|
|
CC=gcc
|
2007-02-24 04:24:44 -07:00
|
|
|
CFLAGS = -g -Wall
|
|
|
|
headers = radix-tree.h ctree.h disk-io.h kerncompat.h print-tree.h
|
|
|
|
objects = ctree.o disk-io.o radix-tree.o mkfs.o extent-tree.o print-tree.o
|
2007-02-02 07:18:22 -07:00
|
|
|
|
2007-02-28 07:40:58 -07:00
|
|
|
# if you don't have sparse installed, use ls instead
|
2007-02-28 14:35:06 -07:00
|
|
|
CHECKFLAGS=-D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ -Wbitwise \
|
|
|
|
-Wcontext -Wcast-truncate -Wuninitialized -Wshadow -Wundef
|
|
|
|
check=sparse $(CHECKFLAGS)
|
2007-02-28 07:40:58 -07:00
|
|
|
#check=ls
|
|
|
|
|
|
|
|
.c.o:
|
|
|
|
$(check) $<
|
|
|
|
$(CC) $(CFLAGS) -c $<
|
2007-02-02 07:18:22 -07:00
|
|
|
|
2007-02-26 08:40:21 -07:00
|
|
|
all: tester debug-tree
|
|
|
|
|
|
|
|
debug-tree: $(objects) debug-tree.o
|
|
|
|
gcc $(CFLAGS) -o debug-tree $(objects) debug-tree.o
|
|
|
|
|
|
|
|
tester: $(objects) random-test.o
|
|
|
|
gcc $(CFLAGS) -o tester $(objects) random-test.o
|
2007-01-26 14:38:42 -07:00
|
|
|
|
2007-02-24 04:24:44 -07:00
|
|
|
$(objects) : $(headers)
|
|
|
|
|
|
|
|
clean :
|
2007-02-26 08:55:01 -07:00
|
|
|
rm debug-tree tester *.o
|
2007-01-26 14:38:42 -07:00
|
|
|
|
2007-02-26 08:40:21 -07:00
|
|
|
|