|
|
|
@ -1,15 +1,16 @@
|
|
|
|
|
Name: perl-Pod-Usage
|
|
|
|
|
# Compete with perl.spec's epoch
|
|
|
|
|
Epoch: 4
|
|
|
|
|
Version: 2.01
|
|
|
|
|
Release: 4%{?dist}
|
|
|
|
|
Version: 2.03
|
|
|
|
|
Release: 511%{?dist}
|
|
|
|
|
Summary: Print a usage message from embedded POD documentation
|
|
|
|
|
# License clarification CPAN RT#102529
|
|
|
|
|
License: GPL+ or Artistic
|
|
|
|
|
License: GPL-1.0-or-later OR Artistic-1.0-Perl
|
|
|
|
|
URL: https://metacpan.org/release/Pod-Usage
|
|
|
|
|
Source0: https://cpan.metacpan.org/authors/id/A/AT/ATOOMIC/Pod-Usage-%{version}.tar.gz
|
|
|
|
|
Source0: https://cpan.metacpan.org/authors/id/M/MA/MAREKR/Pod-Usage-%{version}.tar.gz
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
BuildRequires: coreutils
|
|
|
|
|
BuildRequires: findutils
|
|
|
|
|
BuildRequires: make
|
|
|
|
|
BuildRequires: perl-generators
|
|
|
|
|
BuildRequires: perl-interpreter
|
|
|
|
@ -43,7 +44,6 @@ BuildRequires: perl(vars)
|
|
|
|
|
# Optional tests:
|
|
|
|
|
# CPAN::Meta not helpful
|
|
|
|
|
# CPAN::Meta::Prereqs not helpful
|
|
|
|
|
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
|
|
|
|
Requires: perl(File::Spec) >= 0.82
|
|
|
|
|
# Pod::Usage executes perldoc from perl-Pod-Perldoc by default
|
|
|
|
|
Requires: perl-Pod-Perldoc
|
|
|
|
@ -51,6 +51,7 @@ Requires: perl(Pod::Text) >= 4
|
|
|
|
|
|
|
|
|
|
# Remove under-specified dependencies
|
|
|
|
|
%global __requires_exclude %{?__requires_exclude|%{__requires_exclude}|}^perl\\(File::Spec\\)$
|
|
|
|
|
%global __provides_exclude_from %{?__provides_exclude_from:%__provides_exclude_from|}^%{_libexecdir}
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
pod2usage will print a usage message for the invoking script (using its
|
|
|
|
@ -61,21 +62,61 @@ If the verbose level is 1, then the synopsis is printed along with a
|
|
|
|
|
description (if present) of the command line options and arguments. If the
|
|
|
|
|
verbose level is 2, then the entire manual page is printed.
|
|
|
|
|
|
|
|
|
|
%package tests
|
|
|
|
|
Summary: Tests for %{name}
|
|
|
|
|
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
|
|
|
|
Requires: perl-Test-Harness
|
|
|
|
|
Requires: perl(Pod::PlainText)
|
|
|
|
|
|
|
|
|
|
%description tests
|
|
|
|
|
Tests from %{name}. Execute them
|
|
|
|
|
with "%{_libexecdir}/%{name}/test".
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n Pod-Usage-%{version}
|
|
|
|
|
# Remove bundled modules
|
|
|
|
|
rm -rf t/inc
|
|
|
|
|
perl -i -ne 'print $_ unless m{^t/inc/}' MANIFEST
|
|
|
|
|
|
|
|
|
|
# Help generators to recognize Perl scripts
|
|
|
|
|
for F in `find t -name *.t -o -name *.pl`; 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 NO_PACKLIST=1 NO_PERLLOCAL=1
|
|
|
|
|
%{make_build}
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%{make_install}
|
|
|
|
|
%{_fixperms} $RPM_BUILD_ROOT/*
|
|
|
|
|
%{_fixperms} %{buildroot}/*
|
|
|
|
|
|
|
|
|
|
# Install tests
|
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
cp -a t %{buildroot}%{_libexecdir}/%{name}
|
|
|
|
|
perl -i -pe 's{-Mblib}{}' %{buildroot}%{_libexecdir}/%{name}/t/pod/*
|
|
|
|
|
perl -i -pe 's{ \@blib,}{}' %{buildroot}%{_libexecdir}/%{name}/t/pod/pod2usage2.t
|
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/%{name}/lib/Pod
|
|
|
|
|
mkdir -p %{buildroot}%{_libexecdir}/%{name}/scripts
|
|
|
|
|
ln -s %{perl_vendorlib}/Pod/Usage.pm %{buildroot}%{_libexecdir}/%{name}/lib/Pod/
|
|
|
|
|
ln -s %{_bindir}/pod2usage %{buildroot}%{_libexecdir}/%{name}/scripts/pod2usage.PL
|
|
|
|
|
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 . -r -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
|
|
|
|
@ -86,13 +127,62 @@ make test
|
|
|
|
|
%{_mandir}/man1/*
|
|
|
|
|
%{_mandir}/man3/*
|
|
|
|
|
|
|
|
|
|
%files tests
|
|
|
|
|
%{_libexecdir}/%{name}
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 4:2.01-4
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 4:2.03-511
|
|
|
|
|
- Bump release for October 2024 mass rebuild:
|
|
|
|
|
Resolves: RHEL-64018
|
|
|
|
|
|
|
|
|
|
* Fri Oct 25 2024 MSVSphere Packaging Team <packager@msvsphere-os.ru> - 4:2.03-510
|
|
|
|
|
- Rebuilt for MSVSphere 10
|
|
|
|
|
|
|
|
|
|
* Thu Jul 18 2024 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-510
|
|
|
|
|
- Increase release to favour standalone package
|
|
|
|
|
|
|
|
|
|
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 4:2.03-505
|
|
|
|
|
- Bump release for June 2024 mass rebuild
|
|
|
|
|
|
|
|
|
|
* Wed May 15 2024 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-504
|
|
|
|
|
- Filter provides from sub-package tests
|
|
|
|
|
- Resolves: RHEL-36310
|
|
|
|
|
|
|
|
|
|
* Wed Feb 07 2024 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-503
|
|
|
|
|
- Package tests
|
|
|
|
|
|
|
|
|
|
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.03-502
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 4:2.01-3
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.03-501
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jul 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.03-500
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Tue Jul 11 2023 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-499
|
|
|
|
|
- Increase release to favour standalone package
|
|
|
|
|
|
|
|
|
|
* Fri Jan 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.03-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.03-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Mon May 30 2022 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-2
|
|
|
|
|
- Perl 5.36 rebuild
|
|
|
|
|
|
|
|
|
|
* Sun May 22 2022 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.03-1
|
|
|
|
|
- 2.03 bump
|
|
|
|
|
|
|
|
|
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.01-479
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.01-478
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri May 21 2021 Jitka Plesnikova <jplesnik@redhat.com> - 4:2.01-477
|
|
|
|
|
- Increase release to favour standalone package
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4:2.01-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|