dede636
%if ! (0%{?rhel})
0cc50db
# Run extra test
0cc50db
%bcond_without perl_Module_Implementation_enables_extra_test
0cc50db
# Run optional test
0cc50db
%bcond_without perl_Module_Implementation_enables_optional_test
dede636
%else
dede636
%bcond_with perl_Module_Implementation_enables_extra_test
dede636
%bcond_with perl_Module_Implementation_enables_optional_test
dede636
%endif
0cc50db
d407a78
Name:		perl-Module-Implementation
541b018
Version:	0.09
c59291e
Release:	18%{?dist}
d407a78
Summary:	Loads one of several alternate underlying implementations for a module
d407a78
Group:		Development/Libraries
d407a78
License:	Artistic 2.0
c46891e
URL:		https://metacpan.org/release/perl-Module-Implementation
c46891e
Source0:	https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/Module-Implementation-%{version}.tar.gz
d407a78
BuildArch:	noarch
d407a78
# ===================================================================
d407a78
# Build requirements
d407a78
# ===================================================================
2b64215
BuildRequires:	coreutils
2b64215
BuildRequires:	findutils
2b64215
BuildRequires:	make
7133996
BuildRequires:	perl-interpreter
882b925
BuildRequires:	perl-generators
541b018
BuildRequires:	perl(ExtUtils::MakeMaker)
d407a78
# ===================================================================
d407a78
# Module requirements
d407a78
# ===================================================================
d407a78
BuildRequires:	perl(Carp)
3e734a0
BuildRequires:	perl(Module::Runtime) >= 0.012
d407a78
BuildRequires:	perl(Try::Tiny)
d407a78
BuildRequires:	perl(strict)
d407a78
BuildRequires:	perl(warnings)
d407a78
# ===================================================================
d407a78
# Test suite requirements
d407a78
# ===================================================================
541b018
BuildRequires:	perl(File::Spec)
541b018
BuildRequires:	perl(IO::Handle)
541b018
BuildRequires:	perl(IPC::Open3)
d407a78
BuildRequires:	perl(lib)
81c92d2
BuildRequires:	perl(Test::Fatal) >= 0.006
541b018
BuildRequires:	perl(Test::More) >= 0.96
be51602
BuildRequires:	perl(Test::Requires)
0cc50db
%if %{with perl_Module_Implementation_enables_optional_test}
541b018
# ===================================================================
541b018
# Optional test requirements
541b018
# ===================================================================
541b018
BuildRequires:	perl(CPAN::Meta) >= 2.120900
f71af61
%if ! %{defined perl_bootstrap}
f71af61
# Build cycle: Test::CleanNamespaces → Package::Stash → Module::Implementation
2b64215
BuildRequires:	perl(Test::CleanNamespaces)
f71af61
%endif
d407a78
BuildRequires:	perl(Test::Taint)
0cc50db
%endif
0cc50db
%if %{with perl_Module_Implementation_enables_extra_test}
d407a78
# ===================================================================
d407a78
# Author/Release test requirements
d407a78
# ===================================================================
3c424e1
# Release tests include circular dependencies, so don't do them when bootstrapping:
3c424e1
%if ! %{defined perl_bootstrap}
81c92d2
BuildRequires:	perl(Pod::Coverage::TrustPod)
541b018
BuildRequires:	perl(Test::CPAN::Changes) >= 0.19
d407a78
BuildRequires:	perl(Test::EOL)
d407a78
BuildRequires:	perl(Test::NoTabs)
541b018
BuildRequires:	perl(Test::Pod) >= 1.41
541b018
BuildRequires:	perl(Test::Pod::Coverage) >= 1.08
541b018
BuildRequires:	perl(Test::Portability::Files)
541b018
# Can't use EPEL packages as BR: for RHEL package
81c92d2
%if ! 0%{?rhel}
c0228b7
BuildRequires:	aspell-en
541b018
BuildRequires:	perl(Pod::Wordlist)
541b018
BuildRequires:	perl(Test::Pod::LinkCheck)
541b018
BuildRequires:	perl(Test::Pod::No404s)
81c92d2
BuildRequires:	perl(Test::Spelling) >= 0.12
c8e1258
%endif
3c424e1
%endif
0cc50db
%endif
d407a78
# ===================================================================
d407a78
# Runtime requirements
d407a78
# ===================================================================
d407a78
Requires:	perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
d407a78
Requires:	perl(Carp)
d407a78
d407a78
%description
d407a78
This module abstracts out the process of choosing one of several underlying
d407a78
implementations for a module. This can be used to provide XS and pure Perl
d407a78
implementations of a module, or it could be used to load an implementation
d407a78
for a given OS or any other case of needing to provide multiple
d407a78
implementations.
d407a78
d407a78
This module is only useful when you know all the implementations ahead of
d407a78
time. If you want to load arbitrary implementations then you probably want
d407a78
something like a plugin system, not this module.
d407a78
d407a78
%prep
d407a78
%setup -q -n Module-Implementation-%{version}
d407a78
d407a78
%build
d407a78
perl Makefile.PL INSTALLDIRS=vendor
d407a78
make %{?_smp_mflags}
d407a78
d407a78
%install
d407a78
make pure_install DESTDIR=%{buildroot}
2b64215
find %{buildroot} -type f -name .packlist -delete
d407a78
%{_fixperms} %{buildroot}
d407a78
d407a78
%check
3c424e1
%if %{defined perl_bootstrap}
3c424e1
make test
3c424e1
%else
0cc50db
%if %{with perl_Module_Implementation_enables_extra_test}
81c92d2
# Don't run the author tests for EL builds (see above)
81c92d2
%if ! 0%{?rhel}
81c92d2
make test AUTHOR_TESTING=1 RELEASE_TESTING=1
81c92d2
%else
d407a78
make test RELEASE_TESTING=1
81c92d2
%endif
0cc50db
%else
0cc50db
make test
0cc50db
%endif
3c424e1
%endif
d407a78
d407a78
%files
541b018
%license LICENSE
541b018
%doc Changes README.md
d407a78
%{perl_vendorlib}/Module/
2b64215
%{_mandir}/man3/Module::Implementation.3*
d407a78
d407a78
%changelog
c59291e
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.09-18
c59291e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
c59291e
2575716
* Sun Jul 01 2018 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-17
2575716
- Perl 5.28 re-rebuild of bootstrapped packages
2575716
c297b93
* Thu Jun 28 2018 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-16
c297b93
- Perl 5.28 rebuild
c297b93
9d1d4e0
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.09-15
9d1d4e0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
9d1d4e0
54aa444
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.09-14
54aa444
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
54aa444
f891614
* Wed Jun 07 2017 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-13
f891614
- Perl 5.26 re-rebuild of bootstrapped packages
f891614
7489911
* Mon Jun 05 2017 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-12
7489911
- Perl 5.26 rebuild
7489911
7b09e1c
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.09-11
7b09e1c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
7b09e1c
f71af61
* Wed Oct 12 2016 Petr Pisar <ppisar@redhat.com> - 0.09-10
f71af61
- Break build cycle when bootstrapping (Test::CleanNamespaces →
f71af61
  Package::Stash → Module::Implementation)
f71af61
2b64215
* Tue Sep  6 2016 Paul Howarth <paul@city-fan.org> - 0.09-9
2b64215
- BR: perl(Test::CleanNamespaces)
2b64215
- Simplify find command using -delete
2b64215
6ae07ab
* Wed May 18 2016 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-8
6ae07ab
- Perl 5.24 re-rebuild of bootstrapped packages
6ae07ab
ef8a1b8
* Sun May 15 2016 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-7
ef8a1b8
- Perl 5.24 rebuild
ef8a1b8
7718209
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.09-6
7718209
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
7718209
f6201de
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.09-5
f6201de
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
f6201de
c40128a
* Wed Jun 10 2015 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-4
c40128a
- Perl 5.22 re-rebuild of bootstrapped packages
c40128a
c325bd2
* Sat Jun 06 2015 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-3
c325bd2
- Perl 5.22 rebuild
c325bd2
87f256f
* Tue Sep 09 2014 Jitka Plesnikova <jplesnik@redhat.com> - 0.09-2
87f256f
- Perl 5.20 mass
87f256f
541b018
* Mon Sep  8 2014 Paul Howarth <paul@city-fan.org> - 0.09-1
541b018
- Update to 0.09
541b018
  - Implemented and then reverted a change to use Sub::Name (CPAN RT#98097)
541b018
- Modernize spec
541b018
- Hack out references to currently-unavailable Test::CleanNamespaces
541b018
c3c7975
* Fri Aug 29 2014 Jitka Plesnikova <jplesnik@redhat.com> - 0.07-6
c3c7975
- Perl 5.20 rebuild
c3c7975
3c424e1
* Tue Aug 05 2014 Jitka Plesnikova <jplesnik@redhat.com> - 0.07-5
3c424e1
- Do not run release and author tests on bootstrap
3c424e1
cce2805
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.07-4
cce2805
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
cce2805
7361b46
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.07-3
7361b46
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
7361b46
c0b65b5
* Wed Jul 24 2013 Petr Pisar <ppisar@redhat.com> - 0.07-2
c0b65b5
- Perl 5.18 rebuild
c0b65b5
81c92d2
* Mon Jul 15 2013 Paul Howarth <paul@city-fan.org> - 0.07-1
81c92d2
- Update to 0.07
81c92d2
  - Require Test::Fatal ≥ 0.006 to avoid test failures (CPAN RT#76809)
81c92d2
- Explicitly run author tests, except for EL builds
81c92d2
- Add buildreqs for new tests
81c92d2
- Apply old Test::More patch if we have Test::More < 0.96
81c92d2
6b40ecc
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.06-6
6b40ecc
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
6b40ecc
c8dcafa
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.06-5
c8dcafa
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
c8dcafa
ad625b9
* Wed Jun 13 2012 Petr Pisar <ppisar@redhat.com> - 0.06-4
ad625b9
- Perl 5.16 rebuild
ad625b9
c0228b7
* Thu Jun  7 2012 Paul Howarth <paul@city-fan.org> - 0.06-3
c0228b7
- Drop %%defattr, redundant since rpm 4.4
c0228b7
- Don't need to remove empty directories from buildroot
c0228b7
- Add commentary regarding conditionalized buildreqs
c0228b7
c8e1258
* Thu Jun  7 2012 Marcela Mašláňová <mmaslano@redhat.com> - 0.06-2
c0228b7
- Conditionalize aspell-en dependency
c8e1258
3e734a0
* Sun Feb 12 2012 Paul Howarth <paul@city-fan.org> - 0.06-1
3e734a0
- Update to 0.06
3e734a0
  - Require Module::Runtime 0.012, which has a number of useful bug fixes
3e734a0
be51602
* Fri Feb 10 2012 Paul Howarth <paul@city-fan.org> - 0.05-1
be51602
- Update to 0.05
be51602
  - Make Test::Taint an optional dependency; it requires XS, and requiring a
be51602
    compiler for Module::Implementation defeats its purpose (CPAN RT#74817)
be51602
- BR: perl(Test::Requires)
be51602
- Update patch for building with old Test::More versions
be51602
f128b86
* Thu Feb  9 2012 Paul Howarth <paul@city-fan.org> - 0.04-1
f128b86
- Update to 0.04
f128b86
  - This module no longer installs an _implementation() subroutine in callers;
f128b86
    instead, you can call Module::Implementation::implementation_for($package)
f128b86
    to get the implementation used for a given package
f128b86
- Update patch for building with old Test::More versions
f128b86
d407a78
* Wed Feb  8 2012 Paul Howarth <paul@city-fan.org> - 0.03-3
d407a78
- Incorporate feedback from package review (#788258)
d407a78
  - Correct License tag, which should be Artistic 2.0
d407a78
  - BR: perl(lib) for test suite
d407a78
  - Explicitly require perl(Carp), not automatically detected
d407a78
d407a78
* Tue Feb  7 2012 Paul Howarth <paul@city-fan.org> - 0.03-2
d407a78
- Sanitize for Fedora submission
d407a78
d407a78
* Tue Feb  7 2012 Paul Howarth <paul@city-fan.org> - 0.03-1
d407a78
- Initial RPM version