Merge branch 'bugfix/lto' into 'master'

Disable LTO also for RHEL 7

See merge request packaging/rpm-icinga2!4
This commit is contained in:
Noah Hilverling 2020-07-15 10:25:13 +02:00
commit 6d80e958aa
1 changed files with 3 additions and 2 deletions

View File

@ -68,9 +68,10 @@
%bcond_without unity_build
%endif
# Disable lto_build for older SUSE versions
# Disable lto_build for older compiler versions
# see https://github.com/Icinga/icinga2/issues/7149
%if "%{_vendor}" == "suse" && 0%{?suse_version} <= 1315
# lto1: internal compiler error: in prune_unused_types_prune, at dwarf2out.c
%if "%{_vendor}" == "suse" && 0%{?suse_version} <= 1315 || "%{_vendor}" == "redhat" && (0%{?el7} || 0%{?rhel} == 7 || "%{?dist}" == ".el7")
%bcond_with lto_build
%else # suse_version 1315
%bcond_without lto_build