File: pr123-install-mapnik-printing.patch

package info (click to toggle)
python-mapnik 1%3A0.0~20161104-ea5fd11-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 6,868 kB
  • ctags: 1,796
  • sloc: python: 11,913; cpp: 5,702; sh: 99; makefile: 19
file content (36 lines) | stat: -rw-r--r-- 1,128 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
Description: Fix printing module.
 Currently the printing module isn't being installed by setup.py
Author: Asbjørn Sloth Tønnesen <asbjorn@asbjorn.st>
Origin: https://github.com/mapnik/python-mapnik/pull/123

--- a/setup.py
+++ b/setup.py
@@ -256,7 +256,7 @@ if os.environ.get("CXX", False) == False
 setup(
     name="mapnik",
     version="0.1",
-    packages=['mapnik'],
+    packages=['mapnik','mapnik.printing'],
     author="Blake Thompson",
     author_email="flippmoke@gmail.com",
     description="Python bindings for Mapnik",
--- a/mapnik/printing/__init__.py
+++ b/mapnik/printing/__init__.py
@@ -65,6 +65,7 @@ class PDFPrinter(object):
     Main class for creating PDF print outs. Basic usage is along the lines of
 
     import mapnik
+    import mapnik.printing
 
     page = mapnik.printing.PDFPrinter()
     m = mapnik.Map(100,100)
--- a/test/python_tests/pdf_printing_test.py
+++ b/test/python_tests/pdf_printing_test.py
@@ -6,6 +6,7 @@ from nose.tools import eq_
 from nose.plugins.skip import SkipTest
 
 import mapnik
+import mapnik.printing
 from .utilities import execution_path, run_all
 
 def setup():