From 5275f2fa5d863435ef3d5c228d23c4bcb1f37c3b875aa78e1af3fc7ada65ce8b Mon Sep 17 00:00:00 2001 From: Peter Trommler Date: Wed, 5 Nov 2014 16:08:07 +0000 Subject: [PATCH] Accepting request 259855 from devel:languages:haskell:platform Haskell Platform 2014.2.0.0 update OBS-URL: https://build.opensuse.org/request/show/259855 OBS-URL: https://build.opensuse.org/package/show/devel:languages:haskell/ghc-rpm-macros?expand=0&rev=36 --- add-group.patch | 10 +++--- disable-execstack.patch | 20 ----------- files-defattr.patch | 8 ++--- fix-gen-filelists.patch | 6 ++-- fix-runpath.patch | 13 +++++++ ...f9db56515862de9839f12a17be5f2ed2eb7.tar.xz | 3 ++ ...c851a2c672494e295b3cbfc4eded20c3a11.tar.xz | 3 -- ghc-rpm-macros.changes | 21 +++++++++++ ghc-rpm-macros.spec | 36 +++++++------------ suse-disable-debug-packages.patch | 30 +++++----------- suse-docdir.patch | 6 ++-- 11 files changed, 73 insertions(+), 83 deletions(-) delete mode 100644 disable-execstack.patch create mode 100644 fix-runpath.patch create mode 100644 ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.tar.xz delete mode 100644 ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.tar.xz diff --git a/add-group.patch b/add-group.patch index 9d1e2d7..a3c5978 100644 --- a/add-group.patch +++ b/add-group.patch @@ -1,8 +1,8 @@ -Index: ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc-extra +Index: ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc-extra =================================================================== ---- ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.orig/ghc-rpm-macros.ghc-extra -+++ ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc-extra -@@ -9,6 +9,7 @@ +--- ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.orig/macros.ghc-extra ++++ ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc-extra +@@ -8,6 +8,7 @@ %define basepkg ghc-%{pkgname}\ %package -n %{basepkg}\ Summary: Haskell %{pkgname} library\ @@ -10,7 +10,7 @@ Index: ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.gh %{?1:Version: %{pkgver}}\ %{-l:License: %{-l*}}\ Url: http://hackage.haskell.org/package/%{pkgname}\ -@@ -19,6 +20,7 @@ This package provides the Haskell %{pkgn +@@ -18,6 +19,7 @@ This package provides the Haskell %{pkgn \ %package -n %{basepkg}-devel\ Summary: Haskell %{pkgname} library development files\ diff --git a/disable-execstack.patch b/disable-execstack.patch deleted file mode 100644 index 0bb6467..0000000 --- a/disable-execstack.patch +++ /dev/null @@ -1,20 +0,0 @@ -Index: ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc -=================================================================== ---- ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.orig/ghc-rpm-macros.ghc -+++ ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc -@@ -130,7 +130,6 @@ fi - %global __find_requires %{_rpmconfigdir}/ghc-deps.sh --requires %{buildroot}%{ghclibdir}\ - %cabal_install\ - %{!?1:%ghc_strip_dynlinked}\ --%{!?1:%ghc_clear_execstack}\ - %{nil} - - # ghc_lib_install [name] [version] -@@ -142,7 +141,6 @@ fi - %cabal_pkg_conf\ - %ghc_gen_filelists\ - %{!?1:%ghc_strip_dynlinked}\ --%{!?1:%ghc_clear_execstack}\ - %{nil} - - # ghc_fix_dynamic_rpath prog ... diff --git a/files-defattr.patch b/files-defattr.patch index 5cc2aed..58e31a2 100644 --- a/files-defattr.patch +++ b/files-defattr.patch @@ -1,8 +1,8 @@ -Index: ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc-extra +Index: ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc-extra =================================================================== ---- ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.orig/ghc-rpm-macros.ghc-extra -+++ ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11/ghc-rpm-macros.ghc-extra -@@ -40,8 +40,10 @@ This package provides the Haskell %{pkgn +--- ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.orig/macros.ghc-extra ++++ ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc-extra +@@ -39,8 +39,10 @@ This package provides the Haskell %{pkgn %ghc_pkg_recache\ \ %files -n %{basepkg} -f %{basepkg}.files\ diff --git a/fix-gen-filelists.patch b/fix-gen-filelists.patch index c262d06..193aaea 100644 --- a/fix-gen-filelists.patch +++ b/fix-gen-filelists.patch @@ -1,7 +1,7 @@ -Index: ghc-rpm-macros-master/ghc-rpm-macros.ghc +Index: ghc-rpm-macros-master/macros.ghc =================================================================== ---- ghc-rpm-macros-master.orig/ghc-rpm-macros.ghc -+++ ghc-rpm-macros-master/ghc-rpm-macros.ghc +--- ghc-rpm-macros-master.orig/macros.ghc ++++ ghc-rpm-macros-master/macros.ghc @@ -48,7 +48,7 @@ fi %define docdir %{ghclibdocdir}/%{pkgname}\ rm -f %{basepkg}.files %{basepkg}-devel.files\ diff --git a/fix-runpath.patch b/fix-runpath.patch new file mode 100644 index 0000000..56a97c3 --- /dev/null +++ b/fix-runpath.patch @@ -0,0 +1,13 @@ +Index: ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc +=================================================================== +--- ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.orig/macros.ghc ++++ ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc +@@ -128,7 +128,7 @@ PDIR=$(pwd)\ + for i in %*; do\ + PROG=%{buildroot}%{_bindir}/$i\ + if [ -x "$PROG" ]; then\ +- RPATH=$(chrpath $PROG | sed -e "s@^$PROG: RPATH=@@")\ ++ RPATH=$(chrpath $PROG | sed -e "s@^$PROG: R\\(UN\\)\\?PATH=@@")\ + case $RPATH in\ + *$PDIR*)\ + NEWRPATH=$(echo $RPATH | sed -e "s@$PDIR/dist/build@%{ghclibdir}/%{pkg_name}-%{version}@g")\ diff --git a/ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.tar.xz b/ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.tar.xz new file mode 100644 index 0000000..dba5f09 --- /dev/null +++ b/ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5413cfb813942151578e7acc4ef45cb38cd3bf8e13fc4a7c1edf0a6ef513ec4 +size 22600 diff --git a/ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.tar.xz b/ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.tar.xz deleted file mode 100644 index badd3ed..0000000 --- a/ghc-rpm-macros-48199c851a2c672494e295b3cbfc4eded20c3a11.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5dcdd3d5176f5b3315f3c781118eaa8e0af82259962ee26d2eb3b9b752b87d3e -size 22268 diff --git a/ghc-rpm-macros.changes b/ghc-rpm-macros.changes index 49af2be..7627c26 100644 --- a/ghc-rpm-macros.changes +++ b/ghc-rpm-macros.changes @@ -1,3 +1,24 @@ +------------------------------------------------------------------- +Tue Oct 21 15:05:27 UTC 2014 - peter.trommler@ohm-hochschule.de + +- update to 1.3.6 +* remove execstack workaround and prelink requirement +* improve ghc_fix_dynamic_rpath macro +* do not use -O2 optimization (out of memory failures on OBS) +- refresh patches: +* add-group.patch +* files-defattr.patch +* fix-gen-filelists.patch +* suse-disable-debug-packages.patch +* suse-docdir.patch +-drop patch disable-execstack.patch +* fixed in ghc 7.8 +- add fix-runpath.patch +* starting with ghc 7.8 shared objects with RUNPATH work +* support RUNPATH as well as RPATH +- enable shared libraries and dynamic linking on ppc64 and ppc64le +* shared libraries for ppc still disabled (see haskell trac #8024) + ------------------------------------------------------------------- Fri Sep 12 13:11:17 UTC 2014 - dmueller@suse.com diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec index 0008150..118620a 100644 --- a/ghc-rpm-macros.spec +++ b/ghc-rpm-macros.spec @@ -16,14 +16,14 @@ # -%global git_hash 48199c851a2c672494e295b3cbfc4eded20c3a11 +%global git_hash 2da26f9db56515862de9839f12a17be5f2ed2eb7 %global macros_dir %{_sysconfdir}/rpm %global without_hscolour 1 Name: ghc-rpm-macros -Version: 1.2.7 +Version: 1.3.6 Release: 0 Summary: RPM Macros for building packages for GHC License: GPL-3.0+ @@ -43,17 +43,12 @@ Patch3: files-defattr.patch Patch4: suse-docdir.patch # PATCH-FIX_UPSTREAM fix-gen-filelists.patch Patch5: fix-gen-filelists.patch -# PATCH-FIX-OPENSUSE disable-execstack.patch peter.trommler@ohm-hochschule.de -- disable execstack workaround -Patch6: disable-execstack.patch +# PATCH-FIX-UPSTREAM fix-runpath.patch peter.trommler@ohm-hochschule.de -- In openSUSE we patch binutils to default to the "new" RUNPATH dynamic tag and not the obsolete RPATH. This patch adds support for the former and still works for the latter. +Patch7: fix-runpath.patch # PATCH-FIX-SLE sle-sp1-rpmdeps.patch peter.trommler@ohm-hochschule.de -- SLE's RPM is too old in 11 SP1 and SP2 and SP3 Patch100: sle-sp1-rpmdeps.patch BuildRequires: xz -Requires: ghc-srpm-macros = %{version}-%{release} -%ifnarch ppc64le aarch64 %arm -# for execstack -Requires: prelink -%endif Requires: rpm %if %{undefined without_hscolour} Requires: hscolour @@ -99,10 +94,7 @@ Macros used when generating source Haskell rpm packages. %patch3 -p1 %patch4 -p1 %patch5 -p1 -# remove when prelink is available on any of those architectures -%ifarch ppc64le aarch64 %arm -%patch6 -p1 -%endif +%patch7 -p1 %if 0%{?sles_version} %patch -P 100 -p1 %endif @@ -111,16 +103,17 @@ Macros used when generating source Haskell rpm packages. echo no build stage needed %install -install -p -D -m 0644 ./ghc-rpm-macros.ghc %{buildroot}%{macros_dir}/macros.ghc -install -p -D -m 0644 ./ghc-rpm-macros.ghc-extra %{buildroot}/%{macros_dir}/macros.ghc-extra +install -p -D -m 0644 macros.ghc %{buildroot}%{macros_dir}/macros.ghc +install -p -D -m 0644 macros.ghc-extra %{buildroot}/%{macros_dir}/macros.ghc-extra install -p -D -m 0755 ghc-deps.sh %{buildroot}/%{_prefix}/lib/rpm/ghc-deps.sh +install -p -D -m 0644 ghc.attr %{buildroot}/%{_prefix}/lib/rpm/fileattrs/ghc.attr install -p -D -m 0755 cabal-tweak-dep-ver %{buildroot}/%{_bindir}/cabal-tweak-dep-ver install -p -D -m 0755 cabal-tweak-flag %{buildroot}/%{_bindir}/cabal-tweak-flag -install -p -D -m 0644 ghc-rpm-macros.ghc-srpm %{buildroot}/%{macros_dir}/macros.ghc-srpm -# this is why this package is now arch-dependent: -# turn off shared libs and dynamic linking on secondary archs -%ifnarch %{ix86} x86_64 +# this is why this package is (still) arch-dependent: +# turn off shared libs and dynamic linking on ppc +# See Haskell trac #8024 +%ifarch ppc cat >> %{buildroot}%{macros_dir}/macros.ghc < debugsources.list\ +mkdir -p %{buildroot}/usr/src/debug -+ - # ghc_bin_build - %ghc_bin_build\ --%global debug_package %{nil}\ -+%ghc_suse_disable_debug_packages\ - %cabal_configure\ - %cabal build - - # ghc_lib_build_without_haddock [name] [version] - %ghc_lib_build_without_haddock()\ --%global debug_package %{nil}\ -+%ghc_suse_disable_debug_packages\ - %cabal_configure %{!?without_prof:-p} %{!?ghc_without_shared:--enable-shared} %{?pkg_name:--htmldir=%{ghclibdocdir}/%{pkg_name}} %{?1:--docdir=%{_docdir}/ghc-%1%{!?fedora:-%2} --htmldir=%{ghclibdocdir}/%1} %{!?1:--global} %{?ghc_with_lib_for_ghci:--enable-library-for-ghci} --ghc-option=-O2\ - %cabal build\ - %{nil} diff --git a/suse-docdir.patch b/suse-docdir.patch index e180eb8..d754741 100644 --- a/suse-docdir.patch +++ b/suse-docdir.patch @@ -1,7 +1,7 @@ -Index: ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/ghc-rpm-macros.ghc +Index: ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/macros.ghc =================================================================== ---- ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52.orig/ghc-rpm-macros.ghc -+++ ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/ghc-rpm-macros.ghc +--- ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52.orig/macros.ghc ++++ ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/macros.ghc @@ -18,6 +18,9 @@ proceeding, to avoid dependency ABI brea %endif\ fi