Accepting request 287472 from devel:languages:haskell

1

OBS-URL: https://build.opensuse.org/request/show/287472
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/ghc-rpm-macros?expand=0&rev=18
This commit is contained in:
Dominique Leuenberger 2015-02-24 12:03:01 +00:00 committed by Git OBS Bridge
commit da7a4bd12c
9 changed files with 64 additions and 48 deletions

View File

@ -1,10 +1,10 @@
Index: ghc-rpm-macros-master/macros.ghc Index: ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
=================================================================== ===================================================================
--- ghc-rpm-macros-master.orig/macros.ghc --- ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381.orig/macros.ghc
+++ ghc-rpm-macros-master/macros.ghc +++ ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
@@ -48,7 +48,7 @@ fi @@ -66,7 +66,7 @@ tests
%define docdir %{ghclibdocdir}/%{pkgname}\
rm -f %{basepkg}.files %{basepkg}-devel.files\ rm -f %{basepkg}.files %{basepkg}-devel.files\
touch %{basepkg}.files %{basepkg}-devel.files\
if [ -d "%{buildroot}%{pkgdir}" ]; then\ if [ -d "%{buildroot}%{pkgdir}" ]; then\
-echo "%dir %{pkgdir}" >> %{basepkg}.files\ -echo "%dir %{pkgdir}" >> %{basepkg}.files\
+echo "%%dir %{pkgdir}" >> %{basepkg}.files\ +echo "%%dir %{pkgdir}" >> %{basepkg}.files\

View File

@ -1,13 +0,0 @@
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")\

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b5413cfb813942151578e7acc4ef45cb38cd3bf8e13fc4a7c1edf0a6ef513ec4
size 22600

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d126e6f0c09245d85df09e427e663ec4bb8f0bd0211aeba784fb1e45c9eb88e6
size 23252

View File

@ -1,3 +1,18 @@
-------------------------------------------------------------------
Mon Feb 23 16:38:21 UTC 2015 - peter.trommler@ohm-hochschule.de
- update to 1.4.7
- drop fix-runpath.patch
* fixed upstream
- refresh fix-gen-filelists.patch
- refresh suse-disable-debug-packages.patch
- refresh suse-docdir.patch
- add remove-flags.patch
* remove passing of CFLAGS and LDFLAGS to ghc
* no macro %__global_ldflags in openSUSE
- remove provides ghc() workaround
* fixed upstream
------------------------------------------------------------------- -------------------------------------------------------------------
Sun Dec 14 09:26:31 UTC 2014 - peter.trommler@ohm-hochschule.de Sun Dec 14 09:26:31 UTC 2014 - peter.trommler@ohm-hochschule.de

View File

@ -1,7 +1,7 @@
# #
# spec file for package ghc-rpm-macros # spec file for package ghc-rpm-macros
# #
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2015 SUSE LINUX Products GmbH, Nuernberg, Germany.
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@ -16,14 +16,14 @@
# #
%global git_hash 2da26f9db56515862de9839f12a17be5f2ed2eb7 %global git_hash 81726e4857a866d19cc59b496846d127b9e8c381
%global macros_dir %{_sysconfdir}/rpm %global macros_dir %{_sysconfdir}/rpm
%global without_hscolour 1 %global without_hscolour 1
Name: ghc-rpm-macros Name: ghc-rpm-macros
Version: 1.3.6 Version: 1.4.7
Release: 0 Release: 0
BuildArch: noarch BuildArch: noarch
Summary: RPM Macros for building packages for GHC Summary: RPM Macros for building packages for GHC
@ -43,8 +43,8 @@ Patch3: files-defattr.patch
Patch4: suse-docdir.patch Patch4: suse-docdir.patch
# PATCH-FIX_UPSTREAM fix-gen-filelists.patch # PATCH-FIX_UPSTREAM fix-gen-filelists.patch
Patch5: fix-gen-filelists.patch Patch5: fix-gen-filelists.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. # PATCH-FIX-OPENSUSE remove-flags.patch peter.trommler@ohm-hochschule.de -- Do not pass CFLAGS and LDFLAGS to ghc. openSUSE is missing a RPM macro %%__global_ldflags.
Patch7: fix-runpath.patch Patch8: remove-flags.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 # 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 Patch100: sle-sp1-rpmdeps.patch
@ -53,12 +53,6 @@ Requires: rpm
%if %{undefined without_hscolour} %if %{undefined without_hscolour}
Requires: hscolour Requires: hscolour
%endif %endif
# This is a workaround for a bug in the automatic dependencies generator
# ghc-deps.sh generates this symbol for extra libraries installed with a
# dynamic ghc, currently only %%{ix86} and x86_64
%ifarch %{ix86} x86_64
Provides: ghc()
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -94,7 +88,7 @@ Macros used when generating source Haskell rpm packages.
%patch3 -p1 %patch3 -p1
%patch4 -p1 %patch4 -p1
%patch5 -p1 %patch5 -p1
%patch7 -p1 %patch8 -p1
%if 0%{?sles_version} %if 0%{?sles_version}
%patch -P 100 -p1 %patch -P 100 -p1
%endif %endif
@ -106,7 +100,8 @@ echo no build stage needed
install -p -D -m 0644 macros.ghc %{buildroot}%{macros_dir}/macros.ghc 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 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 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 0644 ghc_bin.attr %{buildroot}/%{_prefix}/lib/rpm/fileattrs/ghc_bin.attr
install -p -D -m 0644 ghc_lib.attr %{buildroot}/%{_prefix}/lib/rpm/fileattrs/ghc_lib.attr
install -p -D -m 0755 cabal-tweak-dep-ver %{buildroot}/%{_bindir}/cabal-tweak-dep-ver 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 0755 cabal-tweak-flag %{buildroot}/%{_bindir}/cabal-tweak-flag
@ -114,7 +109,8 @@ install -p -D -m 0755 cabal-tweak-flag %{buildroot}/%{_bindir}/cabal-tweak-flag
%defattr(-,root,root,-) %defattr(-,root,root,-)
%doc COPYING AUTHORS %doc COPYING AUTHORS
%config %{macros_dir}/macros.ghc %config %{macros_dir}/macros.ghc
%{_prefix}/lib/rpm/fileattrs/ghc.attr %{_prefix}/lib/rpm/fileattrs/ghc_bin.attr
%{_prefix}/lib/rpm/fileattrs/ghc_lib.attr
%{_prefix}/lib/rpm/ghc-deps.sh %{_prefix}/lib/rpm/ghc-deps.sh
%{_bindir}/cabal-tweak-dep-ver %{_bindir}/cabal-tweak-dep-ver
%{_bindir}/cabal-tweak-flag %{_bindir}/cabal-tweak-flag

15
remove-flags.patch Normal file
View File

@ -0,0 +1,15 @@
Index: ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
===================================================================
--- ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381.orig/macros.ghc
+++ ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
@@ -24,9 +24,7 @@ fi
# configure
%cabal_configure\
%ghc_check_bootstrap\
-CFLAGS="${CFLAGS:-%optflags}"; export CFLAGS\
-LDFLAGS="${LDFLAGS:-%__global_ldflags}"; export LDFLAGS\
-%cabal configure --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}} --libsubdir='$compiler/$pkgid' --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
+%cabal configure --prefix=%{_prefix} --libdir=%{_libdir} --docdir=%{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}} --libsubdir='$compiler/$pkgid' --datasubdir='$pkgid' --ghc %{!?ghc_without_dynamic:--enable-executable-dynamic} %{?with_tests:--enable-tests} %{?cabal_configure_options} $cabal_configure_extra_options
# install
%cabal_install %cabal copy --destdir=%{buildroot} -v

View File

@ -1,8 +1,8 @@
Index: ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc Index: ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
=================================================================== ===================================================================
--- ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7.orig/macros.ghc --- ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381.orig/macros.ghc
+++ ghc-rpm-macros-2da26f9db56515862de9839f12a17be5f2ed2eb7/macros.ghc +++ ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
@@ -150,3 +150,13 @@ done\ @@ -177,3 +177,13 @@ done\
%global without_prof 1\ %global without_prof 1\
%global without_haddock 1\ %global without_haddock 1\
%global without_manual 1 %global without_manual 1

View File

@ -1,7 +1,7 @@
Index: ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/macros.ghc Index: ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
=================================================================== ===================================================================
--- ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52.orig/macros.ghc --- ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381.orig/macros.ghc
+++ ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/macros.ghc +++ ghc-rpm-macros-81726e4857a866d19cc59b496846d127b9e8c381/macros.ghc
@@ -18,6 +18,9 @@ proceeding, to avoid dependency ABI brea @@ -18,6 +18,9 @@ proceeding, to avoid dependency ABI brea
%endif\ %endif\
fi fi
@ -12,12 +12,15 @@ Index: ghc-rpm-macros-4d2eb25803c01c46ee84cd7f30f1bc5fb4efba52/macros.ghc
# configure # configure
%cabal_configure\ %cabal_configure\
%ghc_check_bootstrap\ %ghc_check_bootstrap\
@@ -27,7 +30,7 @@ fi @@ -35,9 +38,9 @@ tests
%cabal_install %cabal copy --destdir=%{buildroot} -v %endif
# root dir for ghc docs # root dir for ghc docs (used by ghc.spec)
-%ghc_html_dir %{_docdir}/ghc/html
+%ghc_html_dir %{_datadir}/doc/ghc/html
# deprecates
-%ghcdocbasedir %{_docdir}/ghc/html -%ghcdocbasedir %{_docdir}/ghc/html
+%ghcdocbasedir %{_datadir}/doc/ghc/html +%ghcdocbasedir %{_datadir}/doc/ghc/html
# libraries doc dir
%ghclibdocdir %{ghcdocbasedir}/libraries # libraries doc dir (internal)
# pkg doc dir %ghc_html_libraries_dir %{ghc_html_dir}/libraries