|
|
|
@ -7,8 +7,7 @@ LANG=C.utf8\
|
|
|
|
|
./Setup
|
|
|
|
|
|
|
|
|
|
# compiler version
|
|
|
|
|
%ghc_version %{!?ghc_version_override:%(ghc --numeric-version)}%{?ghc_version_override}
|
|
|
|
|
|
|
|
|
|
%ghc_version %{?ghc_version_override}%{!?ghc_version_override:%(rpm -q --qf %%{version} %{?ghc_name}%{!?ghc_name:ghc})}
|
|
|
|
|
|
|
|
|
|
%ghc_set_gcc_flags\
|
|
|
|
|
%global _lto_cflags %{nil}\
|
|
|
|
@ -32,7 +31,7 @@ if ! [ -f Setup.hs -o -f Setup.lhs ]; then\
|
|
|
|
|
cp %{_datadir}/ghc-rpm-macros/Setup.hs .\
|
|
|
|
|
fi\
|
|
|
|
|
%cabal --version\
|
|
|
|
|
%cabal configure --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{_ghcdocdir} --libsubdir='$compiler/$pkgid' --datasubdir='$pkgid' --libexecsubdir='$pkgid' --ghc %{?_ghcdynlibdir:--dynlibdir=%{_ghcdynlibdir}} %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} %{?ghc_subpackaging:--user}%{!?ghc_subpackaging:--global} --ghc-options="${CFLAGS:+$(echo ' '$CFLAGS | sed -e 's/ / -optc/g')} ${LDFLAGS:+$(echo ' '$LDFLAGS | sed -e 's/ / -optl/g')} -fhide-source-paths" %{?cabal_configure_options} $cabal_configure_extra_options
|
|
|
|
|
%cabal configure %{?ghc_name:--with-compiler=%{_bindir}/ghc-%{ghc_version}} --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{_ghcdocdir} --libsubdir='$compiler/$pkgid' --datasubdir='$pkgid' --libexecsubdir='$pkgid' --ghc %{?_ghcdynlibdir:--dynlibdir=%{_ghcdynlibdir}} %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} %{?ghc_subpackaging:--user}%{!?ghc_subpackaging:--global} --ghc-options="${CFLAGS:+$(echo ' '$CFLAGS | sed -e 's/ / -optc/g')} ${LDFLAGS:+$(echo ' '$LDFLAGS | sed -e 's/ / -optl/g')} -fhide-source-paths" %{?cabal_configure_options} $cabal_configure_extra_options
|
|
|
|
|
|
|
|
|
|
# install
|
|
|
|
|
%cabal_install %cabal copy --destdir=%{buildroot} %{?cabal_install_options}
|
|
|
|
|