boards/x86-multiboot-common/Makefile.include: Add -Wl,--gc-sections to linker options

This commit is contained in:
Joakim Nohlgård 2015-07-14 13:13:29 +02:00 committed by Kaspar Schleiser
parent 16469543db
commit 4d95f8a0ba

View File

@ -50,6 +50,11 @@ LINKFLAGS += -m32 -nostdlib -nostdinc -nostartfiles -nodefaultlibs \
--prefix=$(NEWLIB_BASE) \ --prefix=$(NEWLIB_BASE) \
-Wl,-rpath,$(NEWLIB_BASE)/lib \ -Wl,-rpath,$(NEWLIB_BASE)/lib \
-T$(RIOTBASE)/boards/x86-multiboot-common/linker.ld -T$(RIOTBASE)/boards/x86-multiboot-common/linker.ld
# clean up unused functions
export CFLAGS += -ffunction-sections -fdata-sections
export LINKFLAGS += -Wl,--gc-sections
UNDEF += $(BINDIR)x86-multiboot-common/startup.o UNDEF += $(BINDIR)x86-multiboot-common/startup.o
BASELIBS += $(NEWLIB_BASE)/lib/libc.a \ BASELIBS += $(NEWLIB_BASE)/lib/libc.a \