Hi Dane and Stephan,

I just wanted to follow up on my resolution. I looked at the link Stephan had 
sent for the various installations of Mapnik. The temptation was too great to 
simply use a machine with Fedora on it and install from the Fedora repository. 
I did try once to get my RedHat machine to compile Mapnik and Boost with the 
same version of the Python headers. This did not work on first try, so I took 
the easy route of going to Fedora. So, I now have a working Mapnik install and 
I seem to be generating my map tiles without any further issues.

Thank you both for your assistance.

Scott




********************************************* Scott Pezanowski 


email: [email protected]  
*********************************************



CC: [email protected]
From: [email protected]
To: [email protected]
Subject: Re: [OSM-dev] Mapnik installation errors
Date: Mon, 15 Mar 2010 08:40:27 -0700

Hi Scott,
The error you are seeing is related to Boost.Python, and you'll likely need to 
recompile the 'boost_python' library before continuing to try to install Mapnik.
Essentially what is happening is that boost python is compiling against 
different python development headers than the library is linking to. For 
example, when you built boost python it likely compiled against python2.3 
headers but is linking at runtime to python24.
The other possibility is that you don't even have the python2.4 development 
headers installed, which you should confirm that you do...
More comments below...
On Mar 15, 2010, at 12:12 AM, Scott Pezanowski wrote:Hi,

I have been struggling for a while to install Mapnik. I am hoping someone can 
point me in the right direction for why I am getting the errors I am getting. 
Or, can someone perhaps point me to a different way to install Mapnik, if 
possible (an RPM maybe?). If I am posting in the incorrect place, can you let 
me know a better place.

My environment is RedHat Linux ES 5, with boost 1.42 installed from source, 
python 2.4, and mapnik 0.7.0. 


I just compiled fine on Centos 5.4 the other day, so this setup should work 
fine.
The only trick that helped was making sure that 'usr/local/lib' was in 
ld.so.conf BEFORE compiling mapnik and after installing boost, so that the 
library was found correctly.
sudo bash -c "echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf"sudo 
/sbin/ldconfig

I configure Mapnik with this command:

python scons/scons.py configure INPUT_PLUGINS=all OPTIMIZATION=3 
SYSTEM_FONTS=/usr/share/fonts/truetype/ttf-dejavu BINDINGS=python

Things look good when I configure, but when I then run this command:  python 
scons/scons.py - I get these errors below (please let me know if you need more 
of the output):

/usr/local/include/boost/python/detail/make_tuple.hpp:25: error: 
‘PyTuple_SET_ITEM’ was not declared in this scope
/usr/local/include/boost/python/detail/make_tuple.hpp: In function 
‘boost::python::tuple boost::python::make_tuple(const A0&, const A1&, const 
A2&, const A3&, const A4&) [with A0 = long int, A1 = long int, A2 = long int, 
A3 = long int, A4 = long int]’:


[...snip..]
/usr/local/include/boost/python/numeric.hpp:121:   instantiated from ‘void 
boost::python::numeric::array::resize(const Sequence&) [with Sequence = 
boost::python::tuple]’
/usr/local/include/boost/preprocessor/iteration/detail/local.hpp:37:   
instantiated from here
/usr/local/include/boost/python/object_core.hpp:330: error: 
‘object_base_initializer’ was not declared in this scope
scons: *** [bindings/python/mapnik_shield_symbolizer.os] Error 1
scons: building terminated because of errors.



So, please go back and re-build the boost python library and this should be 
fixed. You can try something like:
cd boost_sources./bootstrap.sh./bjam --with-python python=2.4 -a  toolset=gcc 
stage -d2cp stage/lib/libboost_python.so* /usr/local/lib/
** Note, the -d2 will prompt boost to print the actual commands it sends to 
gcc. Make sure their is no paths to another python version that appear. If 
there are then I can suggest a more definite way to get bjam/boost to compile 
against the right python version, by using a special bjam config like described 
here:
https://lists.berlios.de/pipermail/mapnik-users/2010-March/003034.html
Dane
                                          
_______________________________________________
dev mailing list
[email protected]
http://lists.openstreetmap.org/listinfo/dev

Reply via email to