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