blob: 08283a8410669be9d847d173620802feacc54b62 [file] [log] [blame]
Matthew Wilcox1366c372016-03-17 14:21:45 -07001
Matthew Wilcoxebb9a9a2016-12-14 15:07:56 -08002CFLAGS += -I. -I../../include -g -O2 -Wall -D_LGPL_SOURCE
Matthew Wilcox1366c372016-03-17 14:21:45 -07003LDFLAGS += -lpthread -lurcu
4TARGETS = main
5OFILES = main.o radix-tree.o linux.o test.o tag_check.o find_next_bit.o \
Ross Zwislereec48522016-10-11 13:51:21 -07006 regression1.o regression2.o regression3.o multiorder.o \
Konstantin Khlebnikovcfa40bc2016-12-14 15:08:14 -08007 iteration_check.o benchmark.o
8
9ifdef BENCHMARK
10 CFLAGS += -DBENCHMARK=1
11endif
Matthew Wilcox1366c372016-03-17 14:21:45 -070012
13targets: $(TARGETS)
14
15main: $(OFILES)
16 $(CC) $(CFLAGS) $(LDFLAGS) $(OFILES) -o main
17
18clean:
19 $(RM) -f $(TARGETS) *.o radix-tree.c
20
Ross Zwisler7f308672016-05-20 17:01:48 -070021$(OFILES): *.h */*.h ../../../include/linux/radix-tree.h ../../include/linux/*.h
Matthew Wilcox1366c372016-03-17 14:21:45 -070022
23radix-tree.c: ../../../lib/radix-tree.c
24 sed -e 's/^static //' -e 's/__always_inline //' -e 's/inline //' < $< > $@