perl-File-Slurper/perl-File-Slurper.spec

95 lines
2.9 KiB
RPMSpec
Raw Normal View History

2020-11-05 19:22:43 +08:00
%global _empty_manifest_terminate_build 0
Name: perl-File-Slurper
Version: 0.012
Release: 1
Summary: Simple, sane and efficient module to slurp a file
License: Perl_5
Group: Development/Libraries
URL: http://search.cpan.org/dist/File-Slurper/
Source0: http://www.cpan.org/authors/id/L/LE/LEONT/File-Slurper-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: perl-generators
BuildRequires: perl >= 0:5.008
BuildRequires: perl(Carp)
BuildRequires: perl(constant)
BuildRequires: perl(Encode) >= 2.11
BuildRequires: perl(Exporter) >= 5.57
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: perl(File::Spec::Functions)
BuildRequires: perl(File::Temp)
BuildRequires: perl(PerlIO::utf8_strict)
BuildRequires: perl(strict)
BuildRequires: perl(Test::More)
BuildRequires: perl(Test::Warnings)
BuildRequires: perl(warnings)
Requires: perl(Carp)
Requires: perl(constant)
Requires: perl(Encode) >= 2.11
Requires: perl(Exporter) >= 5.57
Requires: perl(PerlIO::utf8_strict)
Requires: perl(strict)
Requires: perl(warnings)
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
%description
This module provides functions for fast and correct slurping and spewing.
All functions are optionally exported. All functions throw exceptions on
errors, write functions don't return any meaningful value.
%package help
Summary : Simple, sane and efficient module to slurp a file
Provides: perl-File-Slurper-doc
%description help
This module provides functions for fast and correct slurping and spewing.
All functions are optionally exported. All functions throw exceptions on
errors, write functions don't return any meaningful value.
%prep
%setup -q -n File-Slurper-%{version}
%build
export PERL_MM_OPT=""
%{__perl} Makefile.PL INSTALLDIRS=vendor
make %{?_smp_mflags}
%install
export PERL_MM_OPT=""
rm -rf $RPM_BUILD_ROOT
make pure_install PERL_INSTALL_ROOT=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} \;
find $RPM_BUILD_ROOT -depth -type d -exec rmdir {} 2>/dev/null \;
%{_fixperms} $RPM_BUILD_ROOT/*
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 .
%check
make test
%clean
rm -rf $RPM_BUILD_ROOT
%files -f filelist.lst
%defattr(-,root,root,-)
%doc Changes dist.ini LICENSE META.json README
%{perl_vendorlib}/*
%files help
%{_mandir}/*
%changelog
* Thu Jun 11 2020 Perl_Bot <Perl_Bot@openeuler.org> 0.012-1
- Specfile autogenerated by Perl_Bot