From 4b53d0e94908111f9c293704e632deed2d484e09 Mon Sep 17 00:00:00 2001 From: Jens Petersen Date: Tue, 4 Aug 2020 01:13:50 +0800 Subject: [PATCH] disable LTO on (unregisterised) s390x (#1863601) --- ghc-rpm-macros.spec | 8 ++++++-- macros.ghc | 1 + 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec index 8ed8ba6..46cb7cb 100644 --- a/ghc-rpm-macros.spec +++ b/ghc-rpm-macros.spec @@ -10,8 +10,8 @@ #%%global without_hscolour 1 Name: ghc-rpm-macros -Version: 2.0.12 -Release: 3%{?dist} +Version: 2.0.13 +Release: 1%{?dist} Summary: RPM macros for building Haskell packages for GHC License: GPLv3+ @@ -217,6 +217,10 @@ EOF %changelog +* Tue Aug 4 2020 Jens Petersen - 2.0.13-1 +- disable LTO on (unregisterised) s390x (#1863601) + to prevent linker warning flood for prof libraries + * Mon Jul 27 2020 Fedora Release Engineering - 2.0.12-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild diff --git a/macros.ghc b/macros.ghc index 5cd24b9..aed8d80 100644 --- a/macros.ghc +++ b/macros.ghc @@ -13,6 +13,7 @@ LANG=C.utf8\ %ghc_set_gcc_flags\ # -Wunused-label is extremely noisy\ %ifarch s390x\ +%define _lto_cflags %{nil}\ CFLAGS="${CFLAGS:-$(echo %optflags | sed -e 's/-Wall //' -e 's/-Werror=format-security //')}"\ %else\ CFLAGS="${CFLAGS:-%optflags}"\