diff --git a/.perl-Digest-SHA1.metadata b/.perl-Digest-SHA1.metadata index b599766..594c2e6 100644 --- a/.perl-Digest-SHA1.metadata +++ b/.perl-Digest-SHA1.metadata @@ -1 +1 @@ -77379a2775c744dd7a9890f5638da6362ae58013 SOURCES/Digest-SHA1-2.13.tar.gz +77379a2775c744dd7a9890f5638da6362ae58013 SOURCES/Digest-SHA1-2.13.tar.gz diff --git a/SPECS/perl-Digest-SHA1.spec b/SPECS/perl-Digest-SHA1.spec index b40b1e0..70c4cf6 100644 --- a/SPECS/perl-Digest-SHA1.spec +++ b/SPECS/perl-Digest-SHA1.spec @@ -1,18 +1,20 @@ Name: perl-Digest-SHA1 Version: 2.13 -Release: 34%{?dist} +Release: 45%{?dist} Summary: Digest-SHA1 Perl module -License: GPL+ or Artistic +License: GPL-1.0-or-later OR Artistic-1.0-Perl URL: https://metacpan.org/release/Digest-SHA1 Source0: https://cpan.metacpan.org/authors/id/G/GA/GAAS/Digest-SHA1-%{version}.tar.gz +BuildRequires: coreutils BuildRequires: findutils BuildRequires: gcc BuildRequires: glibc-common BuildRequires: make -BuildRequires: perl-interpreter BuildRequires: perl-devel BuildRequires: perl-generators +BuildRequires: perl-interpreter +BuildRequires: perl(Config) BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 # Run-time BuildRequires: perl(Digest::base) @@ -22,7 +24,6 @@ BuildRequires: perl(strict) BuildRequires: perl(vars) # Tests BuildRequires: perl(Test) -Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) Recommends: perl(Digest::base) %description @@ -38,21 +39,53 @@ arbitrary length and which can read files directly. A binary digest will be 20 bytes long. A hex digest will be 40 characters long. A base64 digest will be 27 characters long. +%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 Digest-SHA1-%{version} f=Changes ; iconv -f iso-8859-1 -t utf-8 $f > $f.utf8 ; mv $f.utf8 $f +# Help generators to recognize Perl scripts +for F in t/*.t; do + perl -i -MConfig -ple 'print $Config{startperl} if $. == 1 && !s{\A#!.*perl\b}{$Config{startperl}}' "$F" + chmod +x "$F" +done + %build -perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS" NO_PACKLIST=1 -make %{?_smp_mflags} +perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" NO_PACKLIST=1 NO_PERLLOCAL=1 +%{make_build} %install -make pure_install DESTDIR=$RPM_BUILD_ROOT -find $RPM_BUILD_ROOT -type f -name '*.bs' -a -size 0 -delete -chmod -R u+w $RPM_BUILD_ROOT/* +%{make_install} +find %{buildroot} -type f -name '*.bs' -empty -delete +%{_fixperms} %{buildroot} + +# Install tests +mkdir -p %{buildroot}%{_libexecdir}/%{name} +cp -a t %{buildroot}%{_libexecdir}/%{name} +cat > %{buildroot}%{_libexecdir}/%{name}/test << 'EOF' +#!/bin/bash +set -e +# Some tests write into temporary files/directories. The easiest solution +# is to copy the tests into a writable directory and execute them from there. +DIR=$(mktemp -d) +pushd "$DIR" +cp -a %{_libexecdir}/%{name}/* ./ +prove -I . -j "$(getconf _NPROCESSORS_ONLN)" +popd +rm -rf "$DIR" +EOF +chmod +x %{buildroot}%{_libexecdir}/%{name}/test %check +export HARNESS_OPTIONS=j$(perl -e 'if ($ARGV[0] =~ /.*-j([0-9][0-9]*).*/) {print $1} else {print 1}' -- '%{?_smp_mflags}') make test %files @@ -61,14 +94,51 @@ make test %{perl_vendorarch}/auto/Digest/ %{_mandir}/man3/*.3* +%files tests +%{_libexecdir}/%{name} %changelog -* Mon Aug 09 2021 Mohan Boddu - 2.13-34 -- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags - Related: rhbz#1991688 +* Sat Jan 04 2025 Arkady L. Shane - 2.13-45 +- Rebuilt for MSVSphere 10 + +* Fri Jul 19 2024 Fedora Release Engineering - 2.13-45 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + +* Mon Jun 10 2024 Jitka Plesnikova - 2.13-44 +- Perl 5.40 rebuild + +* Thu Jan 25 2024 Fedora Release Engineering - 2.13-43 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Sun Jan 21 2024 Fedora Release Engineering - 2.13-42 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Thu Sep 14 2023 Jitka Plesnikova - 2.13-41 +- Package tests + +* Thu Jul 20 2023 Fedora Release Engineering - 2.13-40 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + +* Tue Jul 11 2023 Jitka Plesnikova - 2.13-39 +- Perl 5.38 rebuild + +* Fri Jan 20 2023 Fedora Release Engineering - 2.13-38 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Fri Jul 22 2022 Fedora Release Engineering - 2.13-37 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Mon May 30 2022 Jitka Plesnikova - 2.13-36 +- Perl 5.36 rebuild + +* Fri Jan 21 2022 Fedora Release Engineering - 2.13-35 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Thu Jul 22 2021 Fedora Release Engineering - 2.13-34 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild -* Fri Apr 16 2021 Mohan Boddu - 2.13-33 -- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937 +* Fri May 21 2021 Jitka Plesnikova - 2.13-33 +- Perl 5.34 rebuild * Wed Jan 27 2021 Fedora Release Engineering - 2.13-32 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild