Skip to content

Commit 44a6cbf

Browse files
Federico Fissorecmaglie
Federico Fissore
authored andcommitted
Enabling link-time optimization. See arduino#660
1 parent 792e7fd commit 44a6cbf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

hardware/arduino/avr/platform.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ version=1.5.6
1414
# Default "compiler.path" is correct, change only if you want to overidde the initial value
1515
compiler.path={runtime.ide.path}/hardware/tools/avr/bin/
1616
compiler.c.cmd=avr-gcc
17-
compiler.c.flags=-c -g -Os -w -ffunction-sections -fdata-sections -MMD
18-
compiler.c.elf.flags=-Os -Wl,--gc-sections
17+
compiler.c.flags=-c -g -Os -w -ffunction-sections -fdata-sections -MMD -flto
18+
compiler.c.elf.flags=-Os -Wl,--gc-sections -flto
1919
compiler.c.elf.cmd=avr-gcc
2020
compiler.S.flags=-c -g -x assembler-with-cpp
2121
compiler.cpp.cmd=avr-g++
22-
compiler.cpp.flags=-c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD
22+
compiler.cpp.flags=-c -g -Os -w -fno-exceptions -ffunction-sections -fdata-sections -MMD -flto
2323
compiler.ar.cmd=avr-ar
2424
compiler.ar.flags=rcs
2525
compiler.objcopy.cmd=avr-objcopy

0 commit comments

Comments
 (0)