changeset 36:e40e919721b0

Conditionalise USB support, use DWARF debugging as AVR studio groks it.
author darius
date Tue, 23 Oct 2007 10:55:51 +0930
parents fed32b382de2
children 25fa387ef7e9
files Makefile
diffstat 1 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile	Tue Oct 23 10:54:01 2007 +0930
+++ b/Makefile	Tue Oct 23 10:55:51 2007 +0930
@@ -3,11 +3,17 @@
 #
 
 PROG=	testavr
-SRCS=	1wire.c testavr.c usb.c
+SRCS=	1wire.c testavr.c 
+.if defined(WITHUSB)
+SRCS+=	usb.c
+CFLAGS+=-DWITHUSB
+.endif
 
 MCU=	atmega32
 PART=	m32
-CFLAGS+=-O2 -g -Wall -Wunreachable-code
+CFLAGS+=-O2 -Wall -gdwarf-2
+#CFLAGS+=-Wunreachable-code
 CFLAGS+=-DF_CPU=16000000
 #CFLAGS+= -mcall-prologues -frename-registers -fstrict-aliasing -fnew-ra
+
 .include "Makefile.avr"