%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Name: pdfposter
Version: 0.5.0
Release: 2%{?dist}
Summary: Scale and tile PDF images/pages to print on multiple pages
Group: Applications/Engineering
License: GPLv3+
URL: http://pdfposter.origo.ethz.ch/
Source0: http://download.origo.ethz.ch/%{name}/1095/pdftools.%{name}-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: python
BuildRequires: python-setuptools-devel
Requires: pyPdf
%description
Pdfposter can be used to create a large poster by building it from multple
pages and/or printing it on large media. It expects as input a PDF file,
normally printing on a single page. The output is again a PDF file, maybe
containing multiple pages together building the poster. The input page
will be scaled to obtain the desired size.
%prep
%setup -q -n pdftools.%{name}-%{version}
#Remove shebang
for Files in pdftools/pdfposter/cmd.py pdftools/pdfposter/__init__.py; do
sed -i.orig -e 1d ${Files}
touch -r ${Files}.orig ${Files}
rm ${Files}.orig
done
%build
python ./setup.py build
%install
rm -rf %{buildroot}
python ./setup.py install -O1 --skip-build --root=%{buildroot}
install -Dp -m 0644 %{name}.1 %{buildroot}%{_mandir}/man1/%{name}.1
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
%doc COPYING README.txt examples/
%{_mandir}/man*/*.gz
%{_bindir}/%{name}
%{python_sitelib}/pdftools*/
%changelog
* Thu Jul 09 2009 Fabian Affolter <fabian@bernewireless.net> - 0.5.0-2
- Replaced 'define' with 'global'
* Sun May 03 2009 Fabian Affolter <fabian@bernewireless.net> - 0.5.0-1
- Updated to new upstream version 0.5.0
* Thu Apr 07 2009 Fabian Affolter <fabian@bernewireless.net> - 0.4.6-1
- Initial package for Fedora