From a5dd30772755a090ffb82d021145e6497d1e5a2b Mon Sep 17 00:00:00 2001 From: Tim Niemueller Date: Mon, 6 Mar 2017 17:52:12 +0100 Subject: [PATCH] Arduino.mk: on Fedora, disable LTO by default --- Arduino.mk | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Arduino.mk b/Arduino.mk index 204677e..ea71c01 100644 --- a/Arduino.mk +++ b/Arduino.mk @@ -1046,7 +1046,12 @@ ifndef AR_NAME endif ifeq ($(shell expr $(CC_VERNUM) '>' 490), 1) - USE_LTO ?= 1 + DISTRO=$(if $(wildcard /etc/os-release),$(shell sed -n "/^ID=/ s/ID=//p" /etc/os-release),unknown) + ifeq ($(DISTRO),fedora) + USE_LTO ?= 0 + else + USE_LTO ?= 1 + endif endif