Name: perl-Hash-Ordered Version: 0.014 Release: 1%{?dist} Summary: Perl class for ordered hashes License: Apache-2.0 URL: https://metacpan.org/release/dist/Hash-Ordered Source0: https://cpan.metacpan.org/authors/id/D/DA/DAGOLDEN/Hash-Ordered-%{version}.tar.gz BuildArch: noarch BuildRequires: coreutils BuildRequires: make BuildRequires: perl-generators BuildRequires: perl-interpreter BuildRequires: perl(:VERSION) >= 5.8 BuildRequires: perl(Config) BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 BuildRequires: perl(strict) BuildRequires: perl(warnings) # Run-time: BuildRequires: perl(Carp) BuildRequires: perl(constant) BuildRequires: perl(overload) # Tests: BuildRequires: perl(File::Spec) BuildRequires: perl(List::Util) BuildRequires: perl(Test::Deep) BuildRequires: perl(Test::FailWarnings) BuildRequires: perl(Test::Fatal) BuildRequires: perl(Test::More) >= 0.96 # Optional tests: # CPAN::Meta not helpful %description This module implements an ordered hash, meaning that it associates keys with values like a Perl hash, but keeps the keys in a consistent order. Because it is implemented as an object and manipulated with method calls, it is much slower than a Perl hash. This is the cost of keeping order. %package tests Summary: Tests for %{name} Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release} Requires: perl-Test-Harness %description tests Tests from %{name}. Execute them with "%{_libexecdir}/%{name}/test". %prep %setup -q -n Hash-Ordered-%{version} # Help generators to recognize Perl scripts for F in t/*.t; do perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!\s*perl}{$Config{startperl}}' "$F" chmod +x "$F" done %build perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 %{make_build} %install %{make_install} %{_fixperms} %{buildroot}/* # Install tests mkdir -p %{buildroot}%{_libexecdir}/%{name} cp -a t %{buildroot}%{_libexecdir}/%{name} cat > %{buildroot}%{_libexecdir}/%{name}/test << 'EOF' #!/bin/sh cd %{_libexecdir}/%{name} && exec prove -I . -j "$(getconf _NPROCESSORS_ONLN)" EOF chmod +x %{buildroot}%{_libexecdir}/%{name}/test %check unset AUTHOR_TESTING export HARNESS_OPTIONS=j$(perl -e 'if ($ARGV[0] =~ /.*-j([0-9][0-9]*).*/) {print $1} else {print 1}' -- '%{?_smp_mflags}') make test %files %license LICENSE %doc Changes CONTRIBUTING.mkdn README %dir %{perl_vendorlib}/Hash %{perl_vendorlib}/Hash/Ordered %{perl_vendorlib}/Hash/Ordered.pm %{_mandir}/man3/Hash::Ordered.* %{_mandir}/man3/Hash::Ordered::* %files tests %{_libexecdir}/%{name} %changelog * Tue Apr 18 2023 Petr Pisar 0.014-1 - Specfile autogenerated by cpanspec 1.78.