Klipper3d / klipper

Klipper is a 3d-printer firmware
GNU General Public License v3.0
8.95k stars 5.16k forks source link

makefile: fix warning about lto serial compilation #6543

Closed junland closed 2 months ago

junland commented 2 months ago

When building, a warning message appears at the end of the build output:

...
Version: ?-20240326_165244-67c86037cf03
  Preprocessing out/src/generic/armcm_link.ld
  Linking out/klipper.elf
lto-wrapper: warning: using serial compilation of 4 LTRANS jobs
lto-wrapper: note: see the '-flto' option documentation for more information
  Creating hex file out/klipper.bin
...

To avoid this non-erroneous output, we set CFLAGS LTO flag with -flto=auto in the Makefile.

Signed-off-by: John Unland junland.foss@gmail.com

KevinOConnor commented 2 months ago

Thanks.

-Kevin