Enable Link Time Optimization and function garbage collection

This commit is contained in:
Arti Zirk 2016-10-19 22:27:25 +02:00
parent adc3ad6a4a
commit 89b7339775

View File

@ -46,10 +46,14 @@ CFLAGS = -Wall \
-mmcu=$(BOARD) \ -mmcu=$(BOARD) \
-DF_CPU=16000000UL \ -DF_CPU=16000000UL \
-DGIT_DESCR=\"$(shell git describe --abbrev=6 --dirty --always --tags --long)\" \ -DGIT_DESCR=\"$(shell git describe --abbrev=6 --dirty --always --tags --long)\" \
-std=c11 -std=c11 \
-flto \
-fdata-sections -ffunction-sections
# Linker flags # Linker flags
LDFLAGS = -mmcu=$(BOARD) LDFLAGS = -mmcu=$(BOARD) \
-flto \
-Wl,-gc-sections
OBJCOPYARGS = -O ihex \ OBJCOPYARGS = -O ihex \
-R .eeprom -R .eeprom