1# enable this for armv7 builds, lazily using iPhone SDK 2#CFLAGS = -I /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/usr/include -arch armv7 -Os 3CFLAGS = -Os -Wall -Wextra -Wno-unknown-pragmas -Werror-implicit-function-declaration -Werror -Wno-unused-parameter -Wdeclaration-after-statement -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Iinclude 4 5all: cntest 6 7test: cntest 8 (cd test; env MallocStackLogging=true ../cntest) >new.out 9 -diff new.out test/expected.out 10 11cntest: src/cbor.h include/cn-cbor/cn-cbor.h src/cn-cbor.c src/cn-error.c src/cn-get.c test/test.c 12 clang $(CFLAGS) src/cn-cbor.c src/cn-error.c src/cn-get.c test/test.c -o cntest 13 14size: cn-cbor.o 15 size cn-cbor.o 16 size -m cn-cbor.o 17 18cn-cbor.o: src/cn-cbor.c include/cn-cbor/cn-cbor.h src/cbor.h 19 clang $(CFLAGS) -c src/cn-cbor.c 20 21cn-cbor-play.zip: Makefile src/cbor.h src/cn-cbor.c include/cn-cbor/cn-cbor.h test/expected.out test/test.c 22 zip $@ $^ 23 24clean: 25 $(RM) cntest *.o new.out cn-cbor-play.zip 26