# MRO is part of the Perl core since 5.9.5 %if 0%{?fedora} < 9 && 0%{?rhel} < 6 %global mro_in_core 0 %else %global mro_in_core 1 %endif Name: perl-MRO-Compat Version: 0.13 Release: 1%{?dist} Summary: Mro::* interface compatibility for Perls < 5.9.5 License: GPL+ or Artistic Group: Development/Libraries Vendor: bww bitwise works GmbH URL: http://search.cpan.org/dist/MRO-Compat/ Source0: http://search.cpan.org/CPAN/authors/id/H/HA/HAARG/MRO-Compat-%{version}.tar.gz BuildArch: noarch # Build BuildRequires: coreutils BuildRequires: findutils BuildRequires: make #BuildRequires: perl-interpreter BuildRequires: perl-generators BuildRequires: perl(ExtUtils::MakeMaker) # Module %if ! %{mro_in_core} BuildRequires: perl(Class::C3) >= 0.24 BuildRequires: perl(Class::C3::XS) >= 0.08 %endif BuildRequires: perl(strict) BuildRequires: perl(warnings) # Test #BuildRequires: perl(Test::More) >= 0.47 # Dependencies Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) %if ! %{mro_in_core} Requires: perl(Class::C3) >= 0.24 Requires: perl(Class::C3::XS) >= 0.08 %endif %description The "mro" namespace provides several utilities for dealing with method resolution order and method caching in general in Perl 5.9.5 and higher. This module provides those interfaces for earlier versions of Perl (back to 5.6.0 anyways). It is a harmless no-op to use this module on 5.9.5+. That is to say, code which properly uses MRO::Compat will work unmodified on both older Perls and 5.9.5+. If you're writing a piece of software that would like to use the parts of 5.9.5+'s mro:: interfaces that are supported here, and you want compatibility with older Perls, this is the module for you. %prep %setup -q -n MRO-Compat-%{version} # Fix script interpreter perl -MExtUtils::MakeMaker -e 'ExtUtils::MM_Unix->fixin(q{t/15pkg_gen.t})' %build perl Makefile.PL INSTALLDIRS=vendor make %{?_smp_mflags} make manifypods %install rm -rf %{buildroot} make pure_install DESTDIR=%{buildroot} find %{buildroot} -type f -name .packlist -delete %{_fixperms} -c %{buildroot} %check #make test %files %doc Changes README t/ %{perl_vendorlib}/MRO/ %{_mandir}/man3/*.3* %changelog * Thu Mar 13 2018 Elbert Pol - 0.13-1 - initial rpm for OS2