Add telegps initial version
[fw/altos] / src / telegps-v0.1 / Makefile
1 #
2 # AltOS build
3 #
4 #
5
6 include ../stm/Makefile.defs
7
8 INC = \
9         ao.h \
10         ao_arch.h \
11         ao_arch_funcs.h \
12         ao_pins.h \
13         ao_product.h \
14         ao_task.h \
15         ao_whiten.h \
16         stm32l.h \
17         Makefile
18
19 #PROFILE=ao_profile.c
20 #PROFILE_DEF=-DAO_PROFILE=1
21
22 #SAMPLE_PROFILE=ao_sample_profile.c \
23 #       ao_sample_profile_timer.c
24 #SAMPLE_PROFILE_DEF=-DHAS_SAMPLE_PROFILE=1
25
26 #STACK_GUARD=ao_mpu_stm.c
27 #STACK_GUARD_DEF=-DHAS_STACK_GUARD=1
28
29 ALTOS_SRC = \
30         ao_interrupt.c \
31         ao_product.c \
32         ao_romconfig.c \
33         ao_cmd.c \
34         ao_config.c \
35         ao_task.c \
36         ao_led.c \
37         ao_stdio.c \
38         ao_panic.c \
39         ao_timer.c \
40         ao_mutex.c \
41         ao_freq.c \
42         ao_dma_stm.c \
43         ao_spi_stm.c \
44         ao_usb_stm.c \
45         ao_exti_stm.c \
46         ao_serial_stm.c \
47         ao_gps_skytraq.c
48
49 PRODUCT=TeleGPS-v0.1
50 PRODUCT_DEF=-DTELEGPS
51 IDPRODUCT=0x0024
52
53 CFLAGS = $(PRODUCT_DEF) $(STM_CFLAGS) $(PROFILE_DEF) $(SAMPLE_PROFILE_DEF) $(STACK_GUARD_DEF) -Os -g
54
55 PROGNAME=telegps-v0.1
56 PROG=$(PROGNAME)-$(VERSION).elf
57
58 SRC=$(ALTOS_SRC) ao_telegps.c
59 OBJ=$(SRC:.c=.o)
60
61 all: $(PROG)
62
63 $(PROG): Makefile $(OBJ) altos.ld
64         $(call quiet,CC) $(LDFLAGS) $(CFLAGS) -o $(PROG) $(OBJ) $(SAT_CLIB) -lgcc
65
66 $(OBJ): $(INC)
67
68 ao_product.h: ao-make-product.5c ../Version
69         $(call quiet,NICKLE,$<) $< -m altusmetrum.org -i $(IDPRODUCT) -p $(PRODUCT) -v $(VERSION) > $@
70
71 distclean:      clean
72
73 clean:
74         rm -f *.o $(PROGNAME)-*.elf
75         rm -f ao_product.h
76
77 install:
78
79 uninstall: