Init package
This commit is contained in:
parent
0c9c5a86a8
commit
d75e8cc914
BIN
List-AllUtils-0.19.tar.gz
Normal file
BIN
List-AllUtils-0.19.tar.gz
Normal file
Binary file not shown.
127
perl-List-AllUtils.spec
Normal file
127
perl-List-AllUtils.spec
Normal file
@ -0,0 +1,127 @@
|
||||
%global _empty_manifest_terminate_build 0
|
||||
|
||||
Name: perl-List-AllUtils
|
||||
Version: 0.19
|
||||
Release: 1
|
||||
Summary: Combines List::Util and List::SomeUtils
|
||||
License: Artistic 2.0
|
||||
URL: https://metacpan.org/release/List-AllUtils
|
||||
Source0: https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/List-AllUtils-%{version}.tar.gz
|
||||
BuildArch: noarch
|
||||
BuildRequires: coreutils
|
||||
BuildRequires: make
|
||||
BuildRequires: perl-generators
|
||||
BuildRequires: perl-interpreter
|
||||
BuildRequires: perl(Config)
|
||||
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76
|
||||
BuildRequires: perl(strict)
|
||||
BuildRequires: perl(warnings)
|
||||
BuildRequires: perl(base)
|
||||
BuildRequires: perl(Exporter)
|
||||
BuildRequires: perl(List::SomeUtils) >= 0.58
|
||||
BuildRequires: perl(List::Util) >= 1.56
|
||||
BuildRequires: perl(List::UtilsBy) >= 0.11
|
||||
BuildRequires: perl(File::Spec)
|
||||
BuildRequires: perl(Sub::Util)
|
||||
BuildRequires: perl(Test::More) >= 0.96
|
||||
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
||||
|
||||
%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\(List::Util\\) >= 1\.56$
|
||||
%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\((Sub::Util|Test::More)\\)$
|
||||
|
||||
%description
|
||||
Are you sick of trying to remember whether a particular helper is defined
|
||||
in List::Util or List::SomeUtils? I sure am. Now you don't have to remember.
|
||||
This module will export all of the functions that either of those two
|
||||
modules defines.
|
||||
|
||||
%package tests
|
||||
Summary: Tests for %{name}
|
||||
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Requires: perl-Test-Harness
|
||||
Requires: perl(List::Util) >= 1.56
|
||||
Requires: perl(Sub::Util)
|
||||
Requires: perl(Test::More) >= 0.96
|
||||
|
||||
%description tests
|
||||
Tests from %{name}. Execute them
|
||||
with "%{_libexecdir}/%{name}/test".
|
||||
|
||||
%package help
|
||||
Summary: Combines List::Util, List::SomeUtils and List::UtilsBy in one bite-sized package
|
||||
Provides: perl-List-AllUtils-doc
|
||||
|
||||
%description help
|
||||
Are you sick of trying to remember whether a particular helper is defined
|
||||
in List::Util, List::SomeUtils or List::UtilsBy? I sure am. Now you don't
|
||||
have to remember. This module will export all of the functions that either
|
||||
of those three modules defines.
|
||||
|
||||
%prep
|
||||
%setup -q -n List-AllUtils-%{version}
|
||||
for F in \
|
||||
t/00-report-prereqs.dd \
|
||||
t/00-report-prereqs.t \
|
||||
; do
|
||||
rm "$F"
|
||||
perl -i -ne 'print $_ unless m{\A\Q'"$F"'\E}' MANIFEST
|
||||
done
|
||||
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
|
||||
export PERL_MM_OPT=""
|
||||
perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1
|
||||
%{make_build}
|
||||
|
||||
%install
|
||||
%{make_install}
|
||||
%{_fixperms} %{buildroot}/*
|
||||
|
||||
pushd %{buildroot}
|
||||
touch filelist.lst
|
||||
if [ -d usr/bin ];then
|
||||
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/sbin ];then
|
||||
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/lib64 ];then
|
||||
find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
if [ -d usr/lib ];then
|
||||
find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
|
||||
fi
|
||||
popd
|
||||
mv %{buildroot}/filelist.lst .
|
||||
|
||||
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
|
||||
make test
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files -f filelist.lst
|
||||
%defattr(-,root,root,-)
|
||||
%doc azure-pipelines.yml Changes CODE_OF_CONDUCT.md CONTRIBUTING.md cpanfile dist.ini LICENSE META.json perlcriticrc perltidyrc precious.toml README.md
|
||||
%{perl_vendorlib}/*
|
||||
|
||||
%files tests
|
||||
%{_libexecdir}/%{name}
|
||||
|
||||
%files help
|
||||
%{_mandir}/*
|
||||
|
||||
%changelog
|
||||
* Thu Jun 30 2022 misaka00251 <misaka00251@misakanet.cn> - 0.19-1
|
||||
- Init package
|
||||
Loading…
x
Reference in New Issue
Block a user