Hello,
I'm experiencing problems installing the Mapnik Python bindings into a virtualenv using pip on Ubuntu 12.04.
It works if I just install python-mapnik via apt-get and use the --system-site-packages option when creating the virtualenv.
$ sudo apt-get install python-mapnik
$ mkvirtualenv --system-site-packages mapniktest
(mapniktest)$ python
>>> import mapnik
>>> # works
That's usually not what you want to do with virtualenvs, however.
Without the system site packages, I tried installing the bindings via pip:
$ mkvirtualenv --no-site-packages mapniktest
(mapniktest)$ pip install mapnik2
That fails with the following error:
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for Ada/C/ObjC but not for C++ [enabled by default]
/usr/include/mapnik/marker_cache.hpp: In function ‘void {anonymous}::set_marker_type(mapnik::markers_symbolizer&, const string&)’:
/usr/include/mapnik/marker_cache.hpp:57:17: error: invalid use of non-static data member ‘mapnik::marker_cache::known_svg_prefix_’
cpp/mapnik_markers_symbolizer.cpp:57:42: error: from this location
/usr/include/mapnik/marker_cache.hpp:57:17: error: invalid use of non-static data member ‘mapnik::marker_cache::known_svg_prefix_’
cpp/mapnik_markers_symbolizer.cpp:61:42: error: from this location
error: command 'gcc' failed with exit status 1
Also, I installed all the libboost-* packages, the libmapnik-(dev) and mapnik-utils.
Do you have any advice for me on the issue?
Also, which code is current for the python bindings now?
The one on PyPI seems to be from pymapnik2...
Thanks and BR,
Fabian