[perl-Declare-Constraints-Simple] Spec clean-up
Paul Howarth
pghmcfc at fedoraproject.org
Wed Jan 11 12:41:21 UTC 2012
commit 455a7f274fe2c12d6a83ad18073445734671d006
Author: Paul Howarth <paul at city-fan.org>
Date: Wed Jan 11 12:40:47 2012 +0000
Spec clean-up
- Simplify pre-rpm-4.9 provides filter
- Use DESTDIR rather than PERL_INSTALL_ROOT
- Make %files list more specific
perl-Declare-Constraints-Simple.spec | 33 +++++++++++++++------------------
1 files changed, 15 insertions(+), 18 deletions(-)
---
diff --git a/perl-Declare-Constraints-Simple.spec b/perl-Declare-Constraints-Simple.spec
index 0d0852a..ee73011 100644
--- a/perl-Declare-Constraints-Simple.spec
+++ b/perl-Declare-Constraints-Simple.spec
@@ -1,6 +1,6 @@
Name: perl-Declare-Constraints-Simple
Version: 0.03
-Release: 13%{?dist}
+Release: 14%{?dist}
Summary: Declarative Validation of Data Structures
License: GPL+ or Artistic
Group: Development/Libraries
@@ -32,15 +32,9 @@ declarative keywords in the importing namespace.
%prep
%setup -q -n Declare-Constraints-Simple-%{version}
-# Filter unwanted Requires: (pre rpm 4.9)
-cat << \EOF > %{name}-req
-#!/bin/sh
-%{__perl_requires} $* |\
- sed -e '/perl(Declare::Constraints::Simple-Library)/d'
-EOF
-
-%define __perl_requires %{_builddir}/Declare-Constraints-Simple-%{version}/%{name}-req
-chmod +x %{__perl_requires}
+# Filter unwanted Requires (prior to rpm 4.9)
+%global reqfilt /bin/sh -c "%{__perl_requires} | grep -Fvx 'perl(Declare::Constraints::Simple-Library)'"
+%define __perl_requires %{reqfilt}
%build
%{__perl} Makefile.PL INSTALLDIRS=vendor
@@ -48,13 +42,10 @@ make %{?_smp_mflags}
%install
rm -rf %{buildroot}
-
-make pure_install PERL_INSTALL_ROOT=%{buildroot}
-
+make pure_install DESTDIR=%{buildroot}
find %{buildroot} -type f -name .packlist -exec rm -f {} \;
-find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \;
-
-%{_fixperms} %{buildroot}/*
+find %{buildroot} -depth -type d -exec rmdir {} \; 2>/dev/null
+%{_fixperms} %{buildroot}
%check
make test
@@ -65,10 +56,16 @@ rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
%doc Changes README t/
-%{perl_vendorlib}/*
-%{_mandir}/man3/*
+%{perl_vendorlib}/Declare/
+%{_mandir}/man3/Declare::Constraints::Simple*
%changelog
+* Wed Jan 11 2012 Paul Howarth <paul at city-fan.org> - 0.03-14
+- Spec clean-up
+ - Simplify pre-rpm-4.9 provides filter
+ - Use DESTDIR rather than PERL_INSTALL_ROOT
+ - Make %%files list more specific
+
* Wed Jun 29 2011 Marcela Mašláňová <mmaslano at redhat.com> - 0.03-13
- Perl mass rebuild
More information about the perl-devel
mailing list