1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

make: optionally add gcc lto flags

This commit enables building using link time optimization when
specifying "LTO=yes" in the application's Makefile.
This commit is contained in:
Kaspar Schleiser 2014-11-03 11:50:01 +01:00
parent 43ef437e4b
commit 9cf054fe96

View File

@ -41,3 +41,9 @@ endif
# Unwanted flags for c++
CXXUWFLAGS += -std=%
ifeq ($(LTO),yes)
LTOFLAGS = -flto -ffat-lto-objects
CFLAGS += ${LTOFLAGS}
LINKFLAGS += ${LTOFLAGS}
endif