]> git.gag.com Git - fw/altos/blob - src/stm/Makefile.defs
Remove ao_radio_cal from stm products without radios
[fw/altos] / src / stm / Makefile.defs
1 vpath % ../stm:../product:../drivers:../kernel:../util:../kalman:../aes:../math:../draw:../scheme:..
2 vpath make-altitude ../util
3 vpath make-kalman ../util
4 vpath kalman.5c ../kalman
5 vpath kalman_filter.5c ../kalman
6 vpath load_csv.5c ../kalman
7 vpath matrix.5c ../kalman
8 vpath ao-make-product.5c ../util
9
10 .SUFFIXES: .elf .ihx
11
12 .elf.ihx:
13         $(ELFTOHEX) --output=$@ $*.elf
14
15 ifndef TOPDIR
16 TOPDIR=..
17 endif
18
19 ifndef VERSION
20 include $(TOPDIR)/Version
21 endif
22 include $(TOPDIR)/Makedefs
23
24 CC=$(ARM_CC)
25 LIBS=$(PDCLIB_LIBS_M3) -lgcc
26
27 WARN_FLAGS=-Wall -Wextra -Werror
28
29 AO_CFLAGS=-I. -I../stm -I../kernel -I../drivers -I../math -I../draw -I../lisp -I.. $(PDCLIB_INCLUDES)
30 STM_CFLAGS=-std=gnu99 -mlittle-endian -mcpu=cortex-m3 -mthumb -Wcast-align \
31         -ffreestanding -nostdlib $(AO_CFLAGS) $(WARN_FLAGS)
32
33 LDFLAGS=-L../stm -Wl,-Taltos.ld
34
35 NICKLE=nickle
36 ELFTOHEX=$(TOPDIR)/../ao-tools/ao-elftohex/ao-elftohex
37
38 V=0
39 # The user has explicitly enabled quiet compilation.
40 ifeq ($(V),0)
41 quiet = @printf "  $1 $2 $@\n"; $($1)
42 endif
43 # Otherwise, print the full command line.
44 quiet ?= $($1)
45
46 .c.o:
47         $(call quiet,CC) -c $(CFLAGS) -o $@ $<