[ghc-rpm-macros] add ghc_exclude_docdir to exclude docdir from filelists

Jens Petersen petersen at fedoraproject.org
Sat Oct 15 04:02:03 UTC 2011


commit bd7f38e058e8a38d61862e236e67885dc35971b3
Author: Jens Petersen <petersen at redhat.com>
Date:   Sat Oct 15 13:01:58 2011 +0900

    add ghc_exclude_docdir to exclude docdir from filelists

 ghc-rpm-macros.ghc  |    4 ++--
 ghc-rpm-macros.spec |    5 ++++-
 2 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/ghc-rpm-macros.ghc b/ghc-rpm-macros.ghc
index 24e5c12..970c6eb 100644
--- a/ghc-rpm-macros.ghc
+++ b/ghc-rpm-macros.ghc
@@ -48,12 +48,12 @@ echo "%dir %{pkgdir}" >> %{basepkg}.files\
 echo "%attr(755,root,root) %{pkgdir}/libHS%{pkgnamever}-ghc%{ghc_version}.so" >> %{basepkg}.files\
 fi\
 %endif\
-%if 0%{!?1:1}\
+%if 0%{!?1:1} && %{undefined ghc_exclude_docdir}\
 if [ -d "%{buildroot}%{_docdir}/%{name}-%{version}" ]; then\
   echo "%{_docdir}/%{name}-%{version}" >> %{basepkg}%{?ghc_without_shared:-devel}.files\
 fi\
 %endif\
-%if 0%{?1:1}\
+%if 0%{!?1:1} && %{undefined ghc_exclude_docdir}\
 if [ -d "%{buildroot}%{_docdir}/ghc-%{pkgnamever}" ]; then\
   echo "%{_docdir}/ghc-%{pkgnamever}" >> %{basepkg}%{?ghc_without_shared:-devel}.files\
 fi\
diff --git a/ghc-rpm-macros.spec b/ghc-rpm-macros.spec
index ff1ab37..08e9daf 100644
--- a/ghc-rpm-macros.spec
+++ b/ghc-rpm-macros.spec
@@ -3,7 +3,7 @@
 %global macros_file %{_sysconfdir}/rpm/macros.ghc
 
 Name:           ghc-rpm-macros
-Version:        0.13.11
+Version:        0.13.12
 Release:        1%{?dist}
 Summary:        Macros for building packages for GHC
 
@@ -60,6 +60,9 @@ EOF
 
 
 %changelog
+* Sat Oct 15 2011 Jens Petersen <petersen at redhat.com> - 0.13.12-1
+- add ghc_exclude_docdir to exclude docdir from filelists
+
 * Fri Sep 30 2011 Jens Petersen <petersen at redhat.com> - 0.13.11-1
 - fix devel subpackage's prof and doc obsoletes and provides versions
   for multiple lib packages like ghc (reported by Henrik Nordström)


More information about the scm-commits mailing list