Skip to content
Snippets Groups Projects
Commit f1b519de authored by Martine Lenders's avatar Martine Lenders Committed by GitHub
Browse files

Merge pull request #5713 from basilfx/bugfix/msp430_linker

boards: msp430: garbage collect dead code when linking.
parents 16cae977 7cf1c46d
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,7 @@ export TARGET_ARCH ?= msp430
# define build specific options
CFLAGS_CPU = -mmcu=$(CPU_MODEL)
CFLAGS_LINK =
CFLAGS_LINK = -ffunction-sections -fdata-sections
CFLAGS_DBG = -gdwarf-2
CFLAGS_OPT ?= -Os
# export compiler flags
......@@ -11,7 +11,7 @@ export CFLAGS += $(CFLAGS_CPU) $(CFLAGS_LINK) $(CFLAGS_DBG) $(CFLAGS_OPT)
# export assmebly flags
export ASFLAGS += $(CFLAGS_CPU) --defsym $(CPU_MODEL)=1 $(CFLAGS_DBG)
# export linker flags
export LINKFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG) $(CFLAGS_OPT) -static -lgcc
export LINKFLAGS += $(CFLAGS_CPU) $(CFLAGS_DBG) $(CFLAGS_OPT) -Wl,--gc-sections -static -lgcc
# Import all toolchain settings
include $(RIOTCPU)/Makefile.include.gnu
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment