[packages/python-pisa] - fixed bogus version test and removed unnecessary dep - rel 5

baggins baggins at pld-linux.org
Sun May 29 09:46:41 CEST 2016


commit d160e3050b3e46fdbb9b5244c882eac490afec87
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Sun May 29 09:46:13 2016 +0200

    - fixed bogus version test and removed unnecessary dep
    - rel 5

 python-pisa.spec |  5 +++--
 reportlab3.patch | 15 +++++++++++++++
 2 files changed, 18 insertions(+), 2 deletions(-)
---
diff --git a/python-pisa.spec b/python-pisa.spec
index e1ac508..2d5f013 100644
--- a/python-pisa.spec
+++ b/python-pisa.spec
@@ -3,11 +3,12 @@ Summary:	HTML/XML/CSS to PDF converter using the ReportLab toolkit
 Summary(pl.UTF-8):	Konwerter formatów HTML/XML/CSS do PDF korzystający z narzędzi ReportLab
 Name:		python-%{module}
 Version:	3.0.33
-Release:	4
+Release:	5
 License:	Apache v2.0
 Group:		Libraries/Python
 Source0:	http://pypi.python.org/packages/source/p/pisa/%{module}-%{version}.tar.gz
 # Source0-md5:	e2040b12211303d065bc4ae2470d2700
+Patch0:		reportlab3.patch
 URL:		http://www.xhtml2pdf.com/
 BuildRequires:	python-devel >= 1:2.5
 BuildRequires:	python-html5lib
@@ -16,7 +17,6 @@ BuildRequires:	rpmbuild(macros) >= 1.710
 BuildRequires:	sed >= 4.0
 Requires:	python
 Requires:	python-PIL
-Requires:	python-ReportLab < 3.0
 Requires:	python-ReportLab >= 2.2
 Requires:	python-html5lib
 Requires:	python-pyPdf
@@ -32,6 +32,7 @@ ReportLab.
 
 %prep
 %setup -q -n %{module}-%{version}
+%patch0 -p1
 
 %build
 %py_build
diff --git a/reportlab3.patch b/reportlab3.patch
new file mode 100644
index 0000000..bbcccf6
--- /dev/null
+++ b/reportlab3.patch
@@ -0,0 +1,15 @@
+--- pisa-3.0.33/sx/pisa3/pisa_util.py~	2010-06-16 15:43:35.000000000 +0200
++++ pisa-3.0.33/sx/pisa3/pisa_util.py	2016-05-29 09:40:20.286049651 +0200
+@@ -51,10 +51,10 @@
+ 
+ rgb_re = re.compile("^.*?rgb[(]([0-9]+).*?([0-9]+).*?([0-9]+)[)].*?[ ]*$")
+ 
+-if not(reportlab.Version[0] == "2" and reportlab.Version[2] >= "1"):
++if not(reportlab.Version[0] == "3" or (reportlab.Version[0] == "2" and reportlab.Version[2] >= "1")):
+     raise ImportError("Reportlab Version 2.1+ is needed!")
+ 
+-REPORTLAB22 = (reportlab.Version[0] == "2" and reportlab.Version[2] >= "2")
++REPORTLAB22 = (reportlab.Version[0] == "3" or (reportlab.Version[0] == "2" and reportlab.Version[2] >= "2"))
+ # print "***", reportlab.Version, REPORTLAB22, reportlab.__file__
+ 
+ import logging
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-pisa.git/commitdiff/d160e3050b3e46fdbb9b5244c882eac490afec87



More information about the pld-cvs-commit mailing list