Spec clean-up
- Add provides filters that work with all supported distributions - BR: perl(Carp) and perl(Exporter) - Make %files list more explicit - Drop explicit requires of perl(Exporter) since it's auto-detected by rpm 4.9 onwards, and is bundled with perl on all older distributions - Don't need to remove empty directories from buildroot - Don't use macros for commands - %defattr redundant since rpm 4.4 - Use tabs
This commit is contained in:
parent
0995cf1650
commit
2a0b790122
@ -1,49 +1,47 @@
|
||||
Name: perl-SUPER
|
||||
Version: 1.17
|
||||
Release: 6%{?dist}
|
||||
Release: 7%{?dist}
|
||||
Summary: Sane superclass method dispatcher
|
||||
License: GPL+ or Artistic
|
||||
Group: Development/Libraries
|
||||
URL: http://search.cpan.org/dist/SUPER/
|
||||
Source0: http://search.cpan.org/CPAN/authors/id/C/CH/CHROMATIC/SUPER-%{version}.tar.gz
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
|
||||
BuildArch: noarch
|
||||
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
|
||||
|
||||
BuildRequires: perl(Carp)
|
||||
BuildRequires: perl(Exporter)
|
||||
BuildRequires: perl(Module::Build)
|
||||
BuildRequires: perl(Test::Simple) >= 0.61
|
||||
BuildRequires: perl(Sub::Identify) >= 0.03
|
||||
BuildRequires: perl(Scalar::Util) >= 1.20
|
||||
|
||||
Requires: perl(Exporter)
|
||||
BuildRequires: perl(Sub::Identify) >= 0.03
|
||||
BuildRequires: perl(Test::Simple) >= 0.61
|
||||
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
||||
Requires: perl(Scalar::Util) >= 1.20
|
||||
Requires: perl(Sub::Identify) >= 0.03
|
||||
|
||||
%{?perl_default_filter:
|
||||
%filter_from_provides /perl(UNIVERSAL)/d; /perl(DB)/d
|
||||
%perl_default_filter
|
||||
}
|
||||
# Filter out bogus provides (rpm 4.9 onwards)
|
||||
%global __provides_exclude ^perl\\((DB|UNIVERSAL)\\)
|
||||
|
||||
%description
|
||||
When subclassing a class, you occasionally want to dispatch control to the
|
||||
superclass -- at least conditionally and temporarily. This module provides
|
||||
superclass - at least conditionally and temporarily. This module provides
|
||||
an easier, cleaner way for class methods to access their ancestor's
|
||||
implementation.
|
||||
|
||||
%prep
|
||||
%setup -q -n SUPER-%{version}
|
||||
|
||||
# Filter out bogus provides (prior to rpm 4.9)
|
||||
%global provfilt /bin/sh -c "%{__perl_provides} | grep -Evx 'perl[(](DB|UNIVERSAL)[)]'"
|
||||
%define __perl_provides %{provfilt}
|
||||
|
||||
%build
|
||||
%{__perl} Build.PL installdirs=vendor
|
||||
perl Build.PL installdirs=vendor
|
||||
./Build
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
|
||||
./Build install destdir=%{buildroot} create_packlist=0
|
||||
find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \;
|
||||
|
||||
%{_fixperms} %{buildroot}/*
|
||||
%{_fixperms} %{buildroot}
|
||||
|
||||
%check
|
||||
./Build test
|
||||
@ -52,12 +50,22 @@ find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \;
|
||||
rm -rf %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc Changes README
|
||||
%{perl_vendorlib}/*
|
||||
%{_mandir}/man3/*
|
||||
%{perl_vendorlib}/SUPER.pm
|
||||
%{_mandir}/man3/SUPER.3pm*
|
||||
|
||||
%changelog
|
||||
* Tue Mar 6 2012 Paul Howarth <paul@city-fan.org> - 1.17-7
|
||||
- Add provides filters that work with all supported distributions
|
||||
- BR: perl(Carp) and perl(Exporter)
|
||||
- Make %%files list more explicit
|
||||
- Drop explicit requires of perl(Exporter) since it's auto-detected by rpm
|
||||
4.9 onwards, and is bundled with perl on all older distributions
|
||||
- Don't need to remove empty directories from buildroot
|
||||
- Don't use macros for commands
|
||||
- %%defattr redundant since rpm 4.4
|
||||
- Use tabs
|
||||
|
||||
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.17-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user