1.PHONY: all 2all: runtest 3 4$(shell mkdir -p out) 5 6CC := gcc 7CFLAGS := -g -Wall -Werror 8#CFLAGS += -O2 9 10out/main.o: main.c ../../HeapBitmap.h 11 $(CC) $(CFLAGS) -c $< -o $@ -I ../.. 12 13out/HeapBitmap.o: ../../HeapBitmap.c ../../HeapBitmap.h ../../clz.h include/cutils/ashmem.h include/Dalvik.h 14 $(CC) $(CFLAGS) -c $< -o $@ -I ../.. -I include 15 16out/clz.o: ../../clz.c ../../clz.h 17 $(CC) $(CFLAGS) -c $< -o $@ -I ../.. 18 19out/hbtest: out/main.o out/HeapBitmap.o out/clz.o 20 $(CC) $^ -o $@ 21 22.PHONY: runtest 23runtest: out/hbtest 24 out/hbtest 25 26.PHONY: clean 27clean: 28 rm -rf out 29