| 1 | # MRO is part of the Perl core since 5.9.5
|
|---|
| 2 | %if 0%{?fedora} < 9 && 0%{?rhel} < 6
|
|---|
| 3 | %global mro_in_core 0
|
|---|
| 4 | %else
|
|---|
| 5 | %global mro_in_core 1
|
|---|
| 6 | %endif
|
|---|
| 7 |
|
|---|
| 8 | Name: perl-MRO-Compat
|
|---|
| 9 | Version: 0.13
|
|---|
| 10 | Release: 1%{?dist}
|
|---|
| 11 | Summary: Mro::* interface compatibility for Perls < 5.9.5
|
|---|
| 12 | License: GPL+ or Artistic
|
|---|
| 13 | Group: Development/Libraries
|
|---|
| 14 | Vendor: bww bitwise works GmbH
|
|---|
| 15 | URL: http://search.cpan.org/dist/MRO-Compat/
|
|---|
| 16 | Source0: http://search.cpan.org/CPAN/authors/id/H/HA/HAARG/MRO-Compat-%{version}.tar.gz
|
|---|
| 17 | BuildArch: noarch
|
|---|
| 18 | # Build
|
|---|
| 19 | BuildRequires: coreutils
|
|---|
| 20 | BuildRequires: findutils
|
|---|
| 21 | BuildRequires: make
|
|---|
| 22 | #BuildRequires: perl-interpreter
|
|---|
| 23 | BuildRequires: perl-generators
|
|---|
| 24 | BuildRequires: perl(ExtUtils::MakeMaker)
|
|---|
| 25 | # Module
|
|---|
| 26 | %if ! %{mro_in_core}
|
|---|
| 27 | BuildRequires: perl(Class::C3) >= 0.24
|
|---|
| 28 | BuildRequires: perl(Class::C3::XS) >= 0.08
|
|---|
| 29 | %endif
|
|---|
| 30 | BuildRequires: perl(strict)
|
|---|
| 31 | BuildRequires: perl(warnings)
|
|---|
| 32 | # Test
|
|---|
| 33 | #BuildRequires: perl(Test::More) >= 0.47
|
|---|
| 34 | # Dependencies
|
|---|
| 35 | Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
|---|
| 36 | %if ! %{mro_in_core}
|
|---|
| 37 | Requires: perl(Class::C3) >= 0.24
|
|---|
| 38 | Requires: perl(Class::C3::XS) >= 0.08
|
|---|
| 39 | %endif
|
|---|
| 40 |
|
|---|
| 41 | %description
|
|---|
| 42 | The "mro" namespace provides several utilities for dealing with method
|
|---|
| 43 | resolution order and method caching in general in Perl 5.9.5 and higher.
|
|---|
| 44 | This module provides those interfaces for earlier versions of Perl (back
|
|---|
| 45 | to 5.6.0 anyways).
|
|---|
| 46 |
|
|---|
| 47 | It is a harmless no-op to use this module on 5.9.5+. That is to say,
|
|---|
| 48 | code which properly uses MRO::Compat will work unmodified on both older
|
|---|
| 49 | Perls and 5.9.5+.
|
|---|
| 50 |
|
|---|
| 51 | If you're writing a piece of software that would like to use the parts
|
|---|
| 52 | of 5.9.5+'s mro:: interfaces that are supported here, and you want
|
|---|
| 53 | compatibility with older Perls, this is the module for you.
|
|---|
| 54 |
|
|---|
| 55 | %prep
|
|---|
| 56 | %setup -q -n MRO-Compat-%{version}
|
|---|
| 57 |
|
|---|
| 58 | # Fix script interpreter
|
|---|
| 59 | perl -MExtUtils::MakeMaker -e 'ExtUtils::MM_Unix->fixin(q{t/15pkg_gen.t})'
|
|---|
| 60 |
|
|---|
| 61 | %build
|
|---|
| 62 | perl Makefile.PL INSTALLDIRS=vendor
|
|---|
| 63 | make %{?_smp_mflags}
|
|---|
| 64 | make manifypods
|
|---|
| 65 |
|
|---|
| 66 | %install
|
|---|
| 67 | rm -rf %{buildroot}
|
|---|
| 68 | make pure_install DESTDIR=%{buildroot}
|
|---|
| 69 | find %{buildroot} -type f -name .packlist -delete
|
|---|
| 70 | %{_fixperms} -c %{buildroot}
|
|---|
| 71 |
|
|---|
| 72 | %check
|
|---|
| 73 | #make test
|
|---|
| 74 |
|
|---|
| 75 | %files
|
|---|
| 76 | %doc Changes README t/
|
|---|
| 77 | %{perl_vendorlib}/MRO/
|
|---|
| 78 | %{_mandir}/man3/*.3*
|
|---|
| 79 |
|
|---|
| 80 | %changelog
|
|---|
| 81 | * Thu Mar 13 2018 Elbert Pol <elbert.pol@gmail.com> - 0.13-1
|
|---|
| 82 | - initial rpm for OS2
|
|---|