From 46a6bfd423d031743f79b5ec4e76c9edbee2efe4 Mon Sep 17 00:00:00 2001 From: Jens Petersen Date: Oct 17 2016 01:48:52 +0000 Subject: try not setting CFLAGS and LDFLAGS for aarch64 (for ghc-7.10.3) - -Wall is very noisy (unused warnings) - dynlink failing --- diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec index 9cc44a7..064f01a 100644 --- a/ghc-rpm-macros.spec +++ b/ghc-rpm-macros.spec @@ -11,7 +11,7 @@ Name: ghc-rpm-macros Version: 1.6.9 -Release: 4%{?dist} +Release: 5%{?dist} Summary: RPM macros for building Haskell packages for GHC License: GPLv3+ @@ -137,6 +137,9 @@ EOF %changelog +* Mon Oct 17 2016 Jens Petersen - 1.6.9-5 +- for aarch64 do not set CFLAGS and LDFLAGS + * Wed Oct 12 2016 Jens Petersen - 1.6.9-4 - remove Agda obsoletes diff --git a/macros.ghc b/macros.ghc index d4bb2a2..156197b 100644 --- a/macros.ghc +++ b/macros.ghc @@ -23,8 +23,10 @@ fi %cabal_configure\ %ghc_check_bootstrap\ %global _hardened_ldflags %{nil}\ +%ifnarch aarch64\ CFLAGS="${CFLAGS:-%optflags}"; export CFLAGS\ LDFLAGS="${LDFLAGS:-%{?__global_ldflags}}"; export LDFLAGS\ +%endif\ %cabal configure %{?cabal_verbose} --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{_defaultlicensedir}/%{name} --libsubdir='$compiler/$pkgkey' --datasubdir='$pkgid' --ghc %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} --ghc-options="$(echo ' '$CFLAGS | sed -e 's/ / -optc/g') $(echo ' '$LDFLAGS | sed -e 's/ / -optl/g')" %{?cabal_configure_options} $cabal_configure_extra_options # install