perl-PDF-API2/perl-PDF-API2.spec

65 lines
2.0 KiB
RPMSpec

%define perl_major_ver %(eval `perl -V:version`; echo ${version%*.[0-9]*}.0)
Name: perl-PDF-API2
Version: 2.030
Release: 1mamba
Summary: PDF::API2 - Module for the Creation and Modification of PDF Files
Group: System/Libraries/Perl
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: http://www.cpan.org
Source: http://search.cpan.org/CPAN/authors/id/S/SS/SSIMMS/PDF-API2-%{version}.tar.gz
Patch0: %{name}-0.73-fix_autoreq.patch
License: Artistic, GPL
Requires: perl >= %perl_major_ver
Requires: perl-Font-TTF
BuildRequires: perl-devel >= %perl_major_ver
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
PDF::API2 - A Perl Module Chain to faciliate the Creation and Modification of High-Quality "Portable Document Format (aka. PDF)" Files.
%prep
%setup -q -n PDF-API2-%{version}
#%patch0 -p1
%build
perl Makefile.PL PREFIX=%{_prefix} INSTALLDIRS=vendor
%make
%make test
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%makeinstall_perl
packlist=`find %{buildroot} -name .packlist`
[ -z "$packlist" ] && exit 1 || cat $packlist | \
sed "s,%buildroot,,g;s,.*/man/.*,&.gz,g" | \
sort -u > .packlist && rm $packlist
rm -f %{buildroot}%{perl_vendorlib}/PDF/API2/Win32.pm
rm -f %{buildroot}%{perl_vendorlib}/PDF/API2/Basic/TTF/Win32.pm
sed -i "/Win32.pm/d" .packlist
strid=`echo $packlist | sed 's,.*auto\(.*\)/.packlist,\1,'`
for dir in `find %{buildroot} -type d | grep $strid`; do
echo "%dir ${dir#%buildroot}" >> .packlist
done
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
rm -f .packlist
%files -f .packlist
%defattr(-,root,root)
%changelog
* Sun Nov 20 2016 Silvan Calarco <silvan.calarco@mambasoft.it> 2.030-1mamba
- update to 2.030
* Sun Jul 14 2013 Automatic Build System <autodist@mambasoft.it> 0.73-2mamba
- automatic rebuild by autodist
* Mon May 04 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 0.73-1mamba
- package created by autospec