X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=app%2Ftriface%2Ftriface.mk;h=8c8d566a45fcc14054b5c2398ee8cd063afc5e44;hb=4cc44c9888a0336b9d01121ec0b7ad95f4a76195;hp=9cf4fed620164094261cb4a20fd9b44574dafc89;hpb=d29e3fcf59e19b2cafe8f9294388e8c759c56cc6;p=bertos.git diff --git a/app/triface/triface.mk b/app/triface/triface.mk index 9cf4fed6..8c8d566a 100644 --- a/app/triface/triface.mk +++ b/app/triface/triface.mk @@ -5,10 +5,12 @@ # # Makefile fragment for DevLib triface application. # -# Author: Bernardo Innocenti +# Author: Bernie Innocenti # # +# This is an embedded project +triface_EMBEDDED_TGT = 1 # Set to 1 for debug builds triface_DEBUG = 1 @@ -42,7 +44,7 @@ triface_CSRC = \ triface_PCSRC += bertos/mware/formatwr.c -triface_CFLAGS = -O2 -D'ARCH=0' -fno-strict-aliasing -Iapp/triface -Ibertos/cpu/avr +triface_CFLAGS = -O2 -D'ARCH=(ARCH_TRIFACE)' -fno-strict-aliasing -Iapp/triface -Ibertos/cpu/avr triface_LDFLAGS = -Wl triface_MCU = atmega64 @@ -54,3 +56,35 @@ ifeq ($(triface_DEBUG),1) triface_PCSRC += bertos/drv/kdebug.c endif + +boot_EMBEDDED_TGT = 1 +# Set to 1 for debug builds +boot_DEBUG = 0 + +# Our target application +TRG += boot + +boot_MCU = atmega64 +boot_CSRC = \ + app/triface/boot/main.c \ + bertos/net/xmodem.c \ + bertos/drv/ser.c \ + bertos/cpu/avr/drv/ser_avr.c \ + bertos/cpu/avr/drv/flash_avr.c \ + bertos/drv/timer.c \ + bertos/algo/crc.c \ + bertos/mware/hex.c \ + bertos/kern/kfile.c \ + # +boot_CROSS = avr- +boot_CPPFLAGS = -D'ARCH=(ARCH_TRIFACE|ARCH_BOOT)' -Iapp/triface/boot -Ibertos/cpu/avr +boot_CFLAGS = -Os -mcall-prologues +boot_LDSCRIPT = app/triface/boot/boot.ld +boot_LDFLAGS = -Wl,--relax + +# Debug stuff +ifeq ($(boot_DEBUG),1) + boot_CFLAGS += -D_DEBUG + boot_PCSRC += bertos/drv/kdebug.c bertos/mware/formatwr.c +endif +