2 # TeleMetrum build file
4 # The various telemetrum versions differ only
5 # in which flash and GPS drivers are included,
6 # so the per-board makefiles simply define
7 # TM_VER, TM_DEF, TM_INC and TM_SRC and include
10 vpath %.c .:..:../core:../cc1111:../drivers:../product
11 vpath %.h .:..:../core:../cc1111:../drivers:../product
12 vpath ao-make-product.5c ../util
76 PROG = telemetrum-v$(TM_VER)-$(VERSION)$(TM_EXTRA).ihx
77 PRODUCT=TeleMetrum-v$(TM_VER)
78 PRODUCT_DEF=-DTELEMETRUM_V_$(TM_DEF)
81 include ../cc1111/Makefile.cc1111
84 CHECK_STACK=sh ../util/check-stack
87 # The user has explicitly enabled quiet compilation.
89 quiet = @printf " $1 $2 $@\n"; $($1)
91 # Otherwise, print the full command line.
96 ../$(PROG): $(REL) Makefile
97 $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(REL) && cp $(PROG) $(PMAP) ..
98 $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM) || rm $@
100 ao_product.h: ao-make-product.5c ../Version
101 $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
106 rm -f $(ADB) $(ASM) $(LNK) $(LST) $(REL) $(RST) $(SYM)
107 rm -f $(PROG) $(PCDB) $(PLNK) $(PMAP) $(PMEM) $(PAOM)
109 rm -f ../$(PROG) ../$(PMAP)