%define ver 1_19 %define py_platsitedir %{_libdir}/python2.4/site-packages Summary: ReportLab library to create PDF documents using Python Name: python2.4-reportlab Version: 1.19 Release: %mkrel 8 URL: http://www.reportlab.org/ Source0: http://www.reportlab.org/ftp/ReportLab_%{ver}.tar.bz2 Patch0: python-reportlab-table.patch.bz2 Patch1: python-reportlab-image.patch.bz2 Patch2: python-reportlab-filename.patch.bz2 Patch3: pdfimages.py.patch License: BSD Group: Publishing BuildRoot: %{_tmppath}/%{name}-buildroot BuildRequires: python2.4-devel %description ReportLab is a library that lets you directly create documents in Adobe's Portable Document Format (PDF) using the Python programming language. ReportLab library creates PDF based on graphics commands without intervening steps. It's therefore extremely fast, and flexible (since you're using a full-blown programming language). Sample use cases are: * Dynamic PDF generation on the web * High-volume corporate reporting and database publishing * As embeddable print engine for other applications, including a 'report language' so that users can customize their own reports. * As 'build system' for complex documents with charts, tables and text such as management accounts, statistical reports and scientific papers * from XML to PDF in one step %prep %setup -q -n reportlab-%ver find . -type f | xargs perl -p -i -e 's@#!/bin/env python@#!/usr/bin/env python2.4@' cd reportlab %patch0 -p1 %patch1 -p1 %patch2 -p1 %build cd reportlab python2.4 setup.py build %install rm -rf $RPM_BUILD_ROOT cd reportlab python2.4 setup.py install --root=$RPM_BUILD_ROOT cd $RPM_BUILD_ROOT%_libdir/python* tar c reportlab | tar x -C site-packages rm -rf reportlab %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) %doc reportlab/docs %{py_platsitedir}/* %changelog * Tue Feb 10 2009 Kazuhiko Shiozaki 1.19-8nxd2009.0 - apply pdfimages.py.patch to add a missing import * Mon Sep 10 2007 Kazuhiko Shiozaki 1.19-7mdv2007.1 - apply some patches * Sat Jun 30 2007 Jean-Paul Smets 1.19-6mdv2007.1 - py_platsitedir is now based on _libdir * Tue May 29 2007 Kazuhiko Shiozaki 1.19-5.1mdv2007.1 - use python2.4 * Tue Dec 05 2006 Michael Scherer 1.19-5mdv2007.0 + Revision: 91357 - rebuild for new python, fix file listing, as it is not a noarch package + Nicolas Lécureuil - Rebuild against new python - import python-reportlab-1.19-3mdk