OpenStreetMap logo OpenStreetMap

I spent about eight hours today (eight hours when I could have been out mapping) trying to install mapnik. I followed the instructions here:

http://trac.mapnik.org/wiki/MacInstallation

But, there are some problems with these instructions. For example, the instructions provide a link to install Macports, but the link is to version 1.7.1, which doesn't work with Snow Leopard. The correct version (as of this writing) is 1.8.1. Too bad no one had time to update the instructions.

The instructions tell you that you have to install the Macports Python 2.6 and use that instead of Python 2.5 which comes with Leopard. However, Snow Leopard come with 2.6. Of course, the instructions are silent as to whether you need the Macports version or if you can use the 2.6 version that gets installed with Snow Leopard. I decided to install the Macports version, for no good reason.

From there, the installation of mapnik from Macports seemed to go smoothly. No compilation errors.

However, for a long time I got stuck here:

>>> import mapnik
Traceback (most recent call last):
File "", line 1, in
ImportError: No module named mapnik

I fixed some paths and was able to get an error free:

>>> import mapnik

This also worked:

>>> dir(mapnik)
['BoostPythonMetaclass', 'Color', 'Coord', 'CreateDatasource', 'Datasource',…]

But, now I'm stuck here:

>>> help(mapnik)
Segmentation fault

Too tired to continue today. But, it looks like mapnik is installed. Maybe I'll use the tutorial to create an actual map tile tomorrow.

Email icon Bluesky Icon Facebook Icon LinkedIn Icon Mastodon Icon Telegram Icon X Icon

Discussion

Log in to leave a comment