!2 add source and spec file

Merge pull request !2 from 桐小哥/master
This commit is contained in:
openeuler-ci-bot 2020-07-31 20:58:56 +08:00 committed by Gitee
commit ccd3d2ddb2
2 changed files with 84 additions and 0 deletions

BIN
File-Find-Rule-0.34.tar.gz Normal file

Binary file not shown.

84
perl-File-Find-Rule.spec Normal file
View File

@ -0,0 +1,84 @@
%global _empty_manifest_terminate_build 0
Name: perl-File-Find-Rule
Version: 0.34
Release: 2
Summary: Alternative interface to File::Find
License: CHECK(Distributable)
Group: Development/Libraries
URL: http://search.cpan.org/dist/File-Find-Rule/
Source0: http://www.cpan.org/authors/id/R/RC/RCLAMP/File-Find-Rule-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: perl(File::Spec)
BuildRequires: perl(Number::Compare)
BuildRequires: perl(Test::More)
BuildRequires: perl(Text::Glob) >= 0.07
BuildRequires: perl-generators
Requires: perl(File::Spec)
Requires: perl(Number::Compare)
Requires: perl(Test::More)
Requires: perl(Text::Glob) >= 0.07
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
%description
File::Find::Rule is a friendlier interface to File::Find. It allows you to
build rules which specify the desired files and directories.
%package help
Summary : Alternative interface to File::Find
Provides: perl-File-Find-Rule-doc
%description help
File::Find::Rule is a friendlier interface to File::Find. It allows you to
build rules which specify the desired files and directories.
%prep
%setup -q -n File-Find-Rule-%{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 findrule META.json
%{perl_vendorlib}/*
%files help
%{_mandir}/*
%changelog
* Fri Jul 31 2020 shixuantong <shixuantong@huawei.com> - 0.34-2
- Add tar package and Remove %{?dist} in release tag
* Thu Jun 11 2020 Perl_Bot <Perl_Bot@openeuler.org> 0.34-1
- Specfile autogenerated by Perl_Bot