From b60ddd4560032c636a19a4af437a554471bdf0b2 Mon Sep 17 00:00:00 2001 From: Jens Petersen Date: Sat, 2 Feb 2019 01:17:16 +0800 Subject: [PATCH] leave stripping to generic rpm macros --- ghc-rpm-macros.spec | 1 + macros.ghc | 10 +--------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec index 7cd6347..d0e1b3c 100644 --- a/ghc-rpm-macros.spec +++ b/ghc-rpm-macros.spec @@ -177,6 +177,7 @@ EOF %changelog * Fri Feb 1 2019 Jens Petersen - 1.9.6-1 - disable debuginfo by undefining _enable_debug_packages +- leave stripping to generic rpm macros * Thu Jan 31 2019 Fedora Release Engineering - 1.9.5-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild diff --git a/macros.ghc b/macros.ghc index 5d77bee..9ef602f 100644 --- a/macros.ghc +++ b/macros.ghc @@ -29,7 +29,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')}" %{?cabal_configure_options} $cabal_configure_extra_options +%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')}" --disable-executable-stripping --disable-library-stripping %{?cabal_configure_options} $cabal_configure_extra_options # install %cabal_install %cabal copy --destdir=%{buildroot} %{?cabal_install_options} @@ -148,18 +148,11 @@ fi\ %endif\ %{nil} -# ghc_strip_dynlinked -%ghc_strip_dynlinked\ -%if %{undefined __debug_package}\ -find %{buildroot} -type f -exec sh -c "file {} | grep -q 'dynamically linked'" \\; -exec strip "{}" \\;\ -%endif - # install bin package %ghc_bin_install()\ %{!?_fileattrsdir:%global _use_internal_dependency_generator 0}\ %{!?_fileattrsdir:%global __find_requires %{_rpmconfigdir}/ghc-deps.sh %{buildroot}%{ghclibdir}}\ %cabal_install\ -%{!?1:%ghc_strip_dynlinked}\ %{?ghc_subpackaging:%ghc_fix_rpath %{subpkgs}}\ %{nil} @@ -171,7 +164,6 @@ find %{buildroot} -type f -exec sh -c "file {} | grep -q 'dynamically linked'" \ %cabal_install\ %cabal_pkg_conf %{?1} %{?2}\ %ghc_gen_filelists %{?1} %{?2}\ -%{!?1:%ghc_strip_dynlinked}\ %{?ghc_subpackaging:%ghc_fix_rpath %{subpkgs}}\ %{nil}