Update demo.
[bertos.git] / examples / develgps / develgps.mk
1 #
2 # Copyright 2010 Develer S.r.l. (http://www.develer.com/)
3 # All rights reserved.
4 #
5 # Author: Andrea Righi <arighi@develer.com>
6 #
7
8 # Set to 1 for debug builds
9 develgps_DEBUG = 0
10
11 include bertos/fonts/fonts.mk
12
13 # Our target application
14 TRG += develgps
15
16 develgps_CSRC = \
17         examples/develgps/develgps.c \
18         examples/develgps/logo.c \
19         examples/develgps/compass.c \
20         bertos/gfx/bitmap.c \
21         bertos/gfx/line.c \
22         bertos/gfx/win.c \
23         bertos/gfx/text.c \
24         bertos/gfx/text_format.c \
25         bertos/gui/menu.c \
26         bertos/fonts/gohu.c \
27         bertos/fonts/luBS14.c \
28         bertos/icons/logo.c \
29         bertos/mware/formatwr.c \
30         bertos/mware/hex.c \
31         bertos/mware/sprintf.c \
32         bertos/mware/event.c \
33         bertos/struct/heap.c \
34         bertos/drv/timer.c \
35         bertos/drv/ser.c \
36         bertos/drv/kbd.c \
37         bertos/drv/lcd_rit128x96.c \
38         bertos/kern/kfile.c \
39         bertos/kern/monitor.c \
40         bertos/kern/proc.c \
41         bertos/kern/signal.c \
42         bertos/net/nmea.c \
43         bertos/net/nmeap/src/nmeap01.c \
44         bertos/cpu/cortex-m3/drv/flash_lm3s.c \
45         bertos/cpu/cortex-m3/drv/gpio_lm3s.c \
46         bertos/cpu/cortex-m3/drv/clock_lm3s.c \
47         bertos/cpu/cortex-m3/drv/ser_lm3s.c \
48         bertos/cpu/cortex-m3/drv/kdebug_lm3s.c \
49         bertos/cpu/cortex-m3/drv/ssi_lm3s.c \
50         bertos/cpu/cortex-m3/drv/timer_cm3.c \
51         bertos/cpu/cortex-m3/drv/irq_cm3.c \
52         bertos/cpu/cortex-m3/hw/switch_ctx_cm3.c \
53         bertos/cpu/cortex-m3/hw/init_cm3.c
54
55 develgps_CPPASRC = \
56         bertos/cpu/cortex-m3/hw/vectors_cm3.S \
57         bertos/cpu/cortex-m3/hw/crt_cm3.S \
58         #
59
60 # This is an hosted application
61 develgps_PREFIX = arm-none-eabi-
62
63 develgps_CPPAFLAGS = -mthumb -mno-thumb-interwork
64 develgps_CPPFLAGS = -D'ARCH=0' -D__ARM_LM3S1968__ -D'CPU_FREQ=(50000000L)' -D'WIZ_AUTOGEN' -mthumb -mno-thumb-interwork -Iexamples/develgps -Ibertos/cpu/cortex-m3 -fno-strict-aliasing -fwrapv
65 develgps_LDFLAGS = -nostartfiles -T bertos/cpu/cortex-m3/scripts/lm3s1968_rom.ld -Wl,--no-warn-mismatch -mthumb -mno-thumb-interwork
66
67 develgps_CPU = cortex-m3
68
69 develgps_PROGRAMMER_CPU = lm3s
70 develgps_PROGRAMMER_TYPE = luminary
71 develgps_FLASH_SCRIPT = bertos/prg_scripts/arm/flash-lm3s.sh
72 develgps_STOPFLASH_SCRIPT = bertos/prg_scripts/arm/stopopenocd.sh
73 develgps_DEBUG_SCRIPT = bertos/prg_scripts/arm/debug.sh
74 develgps_STOPDEBUG_SCRIPT = bertos/prg_scripts/arm/stopopenocd.sh
75
76 ifeq ($(develgps_DEBUG),0)
77         # Production options
78         develgps_CFLAGS += -O2 -fomit-frame-pointer
79         develgps_CXXFLAGS += -O2 -fomit-frame-pointer
80 else
81         # Debug options
82         develgps_CPPAFLAGS += -g -gdwarf-2
83         develgps_CPPFLAGS += -O0 -g3 -gdwarf-2 -fverbose-asm
84 endif