diff --git a/autodie-2.34.tar.gz b/autodie-2.34.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..c1b8f9e07f46ab3d55a0c8bc9db5353c0bdf08bf Binary files /dev/null and b/autodie-2.34.tar.gz differ diff --git a/perl-autodie.spec b/perl-autodie.spec new file mode 100644 index 0000000000000000000000000000000000000000..cb9255345a29c8a7bd610137666bbf76079d882a --- /dev/null +++ b/perl-autodie.spec @@ -0,0 +1,103 @@ +%define anolis_release 1 +# Run optional test +%bcond_without perl_autodie_enables_optional_test + +Name: perl-autodie +Version: 2.34 +Epoch: 1 +Release: %{anolis_release}%{?dist} +Summary: Replace functions with ones that succeed or die +License: GPL+ or Artistic +URL: https://metacpan.org/release/autodie +Source0: https://cpan.metacpan.org/authors/id/T/TO/TODDR/autodie-%{version}.tar.gz +BuildArch: noarch +BuildRequires: coreutils +BuildRequires: findutils +BuildRequires: make +BuildRequires: perl-interpreter +BuildRequires: perl-generators +BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 +BuildRequires: perl(strict) +BuildRequires: perl(warnings) +# Run-time: +BuildRequires: perl(B) +BuildRequires: perl(Carp) +BuildRequires: perl(Config) +BuildRequires: perl(constant) +BuildRequires: perl(Exporter) >= 5.57 +BuildRequires: perl(Fcntl) +%if !%{defined perl_bootstrap} +BuildRequires: perl(IPC::System::Simple) >= 0.12 +%endif +BuildRequires: perl(overload) +BuildRequires: perl(parent) +BuildRequires: perl(POSIX) +BuildRequires: perl(Scalar::Util) +# Sub::Identify is optional with a fallback +BuildRequires: perl(Tie::RefHash) +# Tests: +# English not used +BuildRequires: perl(File::Copy) +BuildRequires: perl(File::Spec) +BuildRequires: perl(File::Temp) +BuildRequires: perl(FindBin) +BuildRequires: perl(if) +BuildRequires: perl(IO::Handle) +BuildRequires: perl(lib) +BuildRequires: perl(open) +BuildRequires: perl(Socket) +BuildRequires: perl(Test::More) +# Test::Perl::Critic not used +# Test::Pod 1.41 not used +# Test::Pod::Coverage 1.08 not used +# Optional tests: +%if %{with perl_autodie_enables_optional_test} && !%{defined perl_bootstrap} +BuildRequires: perl(BSD::Resource) +BuildRequires: perl(Import::Into) >= 1.002004 +%endif +Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) +Requires: perl(B) +Requires: perl(Fcntl) +Requires: perl(POSIX) +# Optional: +%if !%{defined perl_bootstrap} +# IPC::System::Simple dependency requested, bug #1183231 +Requires: perl(IPC::System::Simple) >= 0.12 +%endif + +# Remove falsely detected perl(lib) +%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\(lib\\)$ + +%description +The "autodie" and "Fatal" pragma provides a convenient way to replace +functions that normally return false on failure with equivalents that throw an +exception on failure. + +However "Fatal" has been obsoleted by the new autodie pragma. Please use +autodie in preference to "Fatal". + +%prep +%setup -q -n autodie-%{version} +find -type f -exec chmod -x {} + + +%build +perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 +%{make_build} + +%install +%{make_install} +%{_fixperms} $RPM_BUILD_ROOT/* + +%check +unset AUTHOR_TESTING AUTOMATED_TESTING PERL_CORE RELEASE_TESTING +make test + +%files +%license LICENSE +%doc AUTHORS Changes README.md +%{perl_vendorlib}/* +%{_mandir}/man3/* + +%changelog +* Wed Apr 20 2022 Chunmei Xu - 1:2.34-1 +- init from upstream