replace %ghc_set_cflags with simplified %ghc_set_gcc_flags

tested in ghc.spec in ghc:8.4 module
This commit is contained in:
Jens Petersen 2018-10-05 17:53:41 +09:00
parent 4972b52b10
commit d190fa9b04
2 changed files with 8 additions and 9 deletions

View File

@ -10,7 +10,7 @@
#%%global without_hscolour 1
Name: ghc-rpm-macros
Version: 1.9.2
Version: 1.9.3
Release: 1%{?dist}
Summary: RPM macros for building Haskell packages for GHC
@ -170,6 +170,9 @@ EOF
%changelog
* Fri Oct 5 2018 Jens Petersen <petersen@redhat.com> - 1.9.3-1
- replace ghc_set_cflags with simplified ghc_set_gcc_flags
* Tue Jul 31 2018 Jens Petersen <petersen@redhat.com> - 1.9.2-1
- inject a Setup.hs if none shipped

View File

@ -9,14 +9,10 @@ LANG=en_US.utf8\
# compiler version
%ghc_version %{!?ghc_version_override:%(ghc --numeric-version)}%{?ghc_version_override}
%ghc_set_cflags\
# -Wunused-label is extremely noisy\
%ifarch aarch64 s390x\
CFLAGS="${CFLAGS:-$(echo %optflags | sed -e 's/-Wall //' -e 's/-Werror=format-security //')}"\
%else\
CFLAGS="${CFLAGS:-%optflags}"\
%endif\
export CFLAGS\
%ghc_set_gcc_flags\
export CFLAGS="${CFLAGS:-%optflags}"\
export LDFLAGS="${LDFLAGS:-%{?__global_ldflags}}"\
%{nil}
# configure