altos/flash-loader: Check memory addresses against flash space
[fw/altos] / src / product / Makefile.telelaunch
index 5da42e4622c8db57218ffa5ed1fd4bee270c1d48..90fe7833f4d239f3b72f9175abace26d8b13a203 100644 (file)
@@ -4,8 +4,8 @@
 # define TELELAUNCH_VER, TELELAUNCH_DEF
 # this file
 
-vpath %.c ..:../core:../cc1111:../drivers:../product
-vpath %.h ..:../core:../cc1111:../drivers:../product
+vpath %.c ..:../kernel:../cc1111:../drivers:../product
+vpath %.h ..:../kernel:../cc1111:../drivers:../product
 vpath ao-make-product.5c ../util
 
 ifndef VERSION
@@ -15,6 +15,8 @@ endif
 INC = \
        ao.h \
        ao_pins.h \
+       ao_arch.h \
+       ao_arch_funcs.h \
        cc1111.h \
        ao_product.h
 
@@ -27,7 +29,8 @@ CORE_SRC = \
        ao_panic.c \
        ao_stdio.c \
        ao_storage.c \
-       ao_task.c
+       ao_task.c \
+       ao_freq.c
 
 CC1111_SRC = \
        ao_adc.c \
@@ -38,13 +41,12 @@ CC1111_SRC = \
        ao_ignite.c \
        ao_intflash.c \
        ao_led.c \
-       ao_packet.c \
-       ao_packet_slave.c \
        ao_radio.c \
        ao_radio_cmac.c \
        ao_romconfig.c \
        ao_serial.c \
        ao_spi.c \
+       ao_string.c \
        ao_timer.c \
        ao_usb.c \
        _bp.c
@@ -60,7 +62,8 @@ SRC = \
        $(DRIVER_SRC) \
        $(PRODUCT_SRC)
 
-PROG = telelaunch-v$(TELELAUNCH_VER)-$(VERSION).ihx
+PROGNAME = telelaunch-v$(TELELAUNCH_VER)
+PROG = $(PROGNAME)-$(VERSION).ihx
 PRODUCT=TeleLaunch-v$(TELELAUNCH_VER)
 PRODUCT_DEF=-DTELELAUNCH_V_$(TELELAUNCH_DEF)
 IDPRODUCT=0x000f
@@ -79,22 +82,18 @@ endif
 # Otherwise, print the full command line.
 quiet ?= $($1)
 
-all: ../$(PROG)
+all: $(PROG)
 
-../$(PROG): $(REL) Makefile
+$(PROG): $(REL) Makefile
        $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(REL) && cp $(PROG) $(PMAP) ..
-       $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM)
+       $(call quiet,CHECK_STACK) ../cc1111/ao_arch.h $(PMEM)  || rm $@
 
 ao_product.h: ao-make-product.5c ../Version
        $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
 
 distclean:     clean
 
-clean:
-       rm -f $(ADB) $(ASM) $(LNK) $(LST) $(REL) $(RST) $(SYM)
-       rm -f $(PROG) $(PCDB) $(PLNK) $(PMAP) $(PMEM) $(PAOM)
-       rm -f ao_product.h
-       rm -f ../$(PROG) ../$(PMAP)
+clean: clean-cc1111
 
 install: