Update architecture specific makefile templates so that they are as close to one-another as possible.
This commit is contained in:
parent
16f09ab50a
commit
e009aafe25
2 changed files with 33 additions and 38 deletions
|
|
@ -63,7 +63,7 @@
|
|||
MCU = ### INSERT NAME OF MICROCONTROLLER MODEL HERE ###
|
||||
|
||||
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
# Targeted chip architecture (see library "Architectures" documentation)
|
||||
ARCH = AVR8
|
||||
|
||||
|
||||
|
|
@ -177,21 +177,24 @@ CSTANDARD = -std=c99
|
|||
|
||||
# Place -D or -U options here for C sources
|
||||
CDEFS = -DF_CPU=$(F_CPU)UL
|
||||
CDEFS += -DF_CLOCK=$(F_CLOCK)UL
|
||||
CDEFS += -DF_USB=$(F_USB)UL
|
||||
CDEFS += -DBOARD=BOARD_$(BOARD)
|
||||
CDEFS += -DARCH=ARCH_$(ARCH)
|
||||
CDEFS += $(LUFA_OPTS)
|
||||
|
||||
|
||||
# Place -D or -U options here for ASM sources
|
||||
ADEFS = -DF_CPU=$(F_CPU)
|
||||
ADEFS += -DF_CLOCK=$(F_CLOCK)UL
|
||||
ADEFS += -DF_USB=$(F_USB)UL
|
||||
ADEFS += -DBOARD=BOARD_$(BOARD)
|
||||
ADEFS += -DARCH=ARCH_$(ARCH)
|
||||
ADEFS += $(LUFA_OPTS)
|
||||
|
||||
# Place -D or -U options here for C++ sources
|
||||
CPPDEFS = -DF_CPU=$(F_CPU)UL
|
||||
CPPDEFS += -DF_CLOCK=$(F_CLOCK)UL
|
||||
CPPDEFS += -DF_USB=$(F_USB)UL
|
||||
CPPDEFS += -DBOARD=BOARD_$(BOARD)
|
||||
CPPDEFS += -DARCH=ARCH_$(ARCH)
|
||||
CPPDEFS += $(LUFA_OPTS)
|
||||
#CPPDEFS += -D__STDC_LIMIT_MACROS
|
||||
#CPPDEFS += -D__STDC_CONSTANT_MACROS
|
||||
|
|
@ -217,11 +220,6 @@ CFLAGS += -fshort-enums
|
|||
CFLAGS += -fno-strict-aliasing
|
||||
CFLAGS += -Wall
|
||||
CFLAGS += -Wstrict-prototypes
|
||||
#CFLAGS += -mshort-calls
|
||||
#CFLAGS += -fno-unit-at-a-time
|
||||
#CFLAGS += -Wundef
|
||||
#CFLAGS += -Wunreachable-code
|
||||
#CFLAGS += -Wsign-compare
|
||||
CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)
|
||||
CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))
|
||||
CFLAGS += $(CSTANDARD)
|
||||
|
|
@ -241,14 +239,11 @@ CPPFLAGS += -funsigned-char
|
|||
CPPFLAGS += -funsigned-bitfields
|
||||
CPPFLAGS += -fpack-struct
|
||||
CPPFLAGS += -fshort-enums
|
||||
CPPFLAGS += -ffunction-sections
|
||||
CPPFLAGS += -fno-strict-aliasing
|
||||
CPPFLAGS += -fno-exceptions
|
||||
CPPFLAGS += -Wall
|
||||
CPPFLAGS += -Wundef
|
||||
#CPPFLAGS += -mshort-calls
|
||||
#CPPFLAGS += -fno-unit-at-a-time
|
||||
#CPPFLAGS += -Wstrict-prototypes
|
||||
#CPPFLAGS += -Wunreachable-code
|
||||
#CPPFLAGS += -Wsign-compare
|
||||
CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)
|
||||
CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))
|
||||
#CPPFLAGS += $(CSTANDARD)
|
||||
|
|
@ -592,7 +587,7 @@ extcoff: $(TARGET).elf
|
|||
%.hex: %.elf
|
||||
@echo
|
||||
@echo $(MSG_FLASH) $@
|
||||
$(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock $< $@
|
||||
$(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock -R .signature $< $@
|
||||
|
||||
%.eep: %.elf
|
||||
@echo
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue