[reportlab-users] setup patch

Dirk Datzert reportlab-users@reportlab.com
Thu, 12 Dec 2002 21:52:39 +0100


Dies ist eine mehrteilige Nachricht im MIME-Format.
--------------E8E119201C53E81938755191
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi Andy,

I worked on the right setup.py for linux SuSE SLES 7 with python 2.1.
With that patch I can build a RPM via 'python setup.py bdist_rpm'
without an error. I can also sent you the RPM I build with this
configuration.

Regards,
Dirk
--------------E8E119201C53E81938755191
Content-Type: text/plain; charset=us-ascii;
 name="reportlab-setup.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="reportlab-setup.patch"

diff -uNr reportlab/MANIFEST.in reportlab-1.17/MANIFEST.in
--- reportlab/MANIFEST.in	Thu Jan  1 01:00:00 1970
+++ reportlab-1.17/MANIFEST.in	Thu Dec 12 21:30:11 2002
@@ -0,0 +1,3 @@
+recursive-include fonts *
+recursive-include docs *
+recursive-include lib *.c *.h *.in
diff -uNr reportlab/setup.py reportlab-1.17/setup.py
--- reportlab/setup.py	Thu Dec 12 21:45:41 2002
+++ reportlab-1.17/setup.py	Thu Dec 12 21:43:43 2002
@@ -4,28 +4,31 @@
 
 from distutils.core import setup, Extension
 
+import sys
+
+package_path = "/usr/lib/python%s/site-packages/reportlab" % sys.version [:3]
+
+
 # why oh why don't most setup scripts have a script handler?
 # if you don't have one, you can't edit in Pythonwin
 def run():
     LIBS = []
     setup(
             name="Reportlab",
-            version="1.15.3",
+            version="1.17",
             description="Reportlab PDF generation tools",
             author="The boys from SW19",
             author_email="info@reportlab.com",
             url="http://www.reportlab.com/",
 
-            package_dir = {'': '..'},
+            package_dir = {'reportlab': '.'},
 
             packages=[ # include anything with an __init__
                     'reportlab',
                     'reportlab.docs',
                     'reportlab.docs.graphguide',
-                    'reportlab.docs.images',
                     'reportlab.docs.reference',
                     'reportlab.docs.userguide',
-                    'reportlab.fonts',
                     'reportlab.graphics',
                     'reportlab.graphics.charts',
                     'reportlab.graphics.widgets',
@@ -34,19 +37,21 @@
                     'reportlab.pdfgen',
                     'reportlab.platypus',
                       ],
-              data_files = [('docs/images', ['docs/images/Edit_Prefs.gif',
-                                                 'docs/images/Python_21.gif',
-                                                 'docs/images/Python_21_HINT.gif',
-                                                 'docs/images/fileExchange.gif',
-                                                 'docs/images/jpn.gif',
-                                                 'docs/images/jpnchars.jpg',
-                                                 'docs/images/lj8100.jpg',
-                                                 'docs/images/replogo.a85',
-                                                 'docs/images/replogo.gif']),
-                    ('fonts', ['fonts/LeERC___.AFM',
-                                     'fonts/LeERC___.PFB',
-                                     'fonts/luxiserif.ttf',
-                                     'fonts/rina.ttf']
+              data_files = [('%s/docs/images' % package_path, 
+				['docs/images/Edit_Prefs.gif',
+                                 'docs/images/Python_21.gif',
+                                 'docs/images/Python_21_HINT.gif',
+                                 'docs/images/fileExchange.gif',
+                                 'docs/images/jpn.gif',
+                                 'docs/images/jpnchars.jpg',
+                                 'docs/images/lj8100.jpg',
+                                 'docs/images/replogo.a85',
+                                 'docs/images/replogo.gif']),
+                    ('%s/fonts' % package_path, 
+				['fonts/LeERC___.AFM',
+                                 'fonts/LeERC___.PFB',
+                                 'fonts/luxiserif.ttf',
+                                 'fonts/rina.ttf']
                      )],
 
             ext_modules =   [Extension( '_rl_accel',

--------------E8E119201C53E81938755191--