Open ashaw opened 5 years ago
Same issue
Same issue after installing with brew
mapnik 3.0.22
boost 1.72.0
UPDATE: I now recommend building master of both mapnik and python-mapnik, its easier in the end (trust me :-P), I have an updated gist build-python-mapnik-osx.sh
that does this: https://gist.github.com/snickell/ee8f3d96f11f457c30ef5416a12d625e
THE FOLLOWING IS NOW OUTDATED, USE THE GIST ABOVE
As a workaround, I unlinked boost@1.73, and relinked in an older version of boost that is not affected, boost@1.60:
brew unlink boost
brew install boost@1.60
brew link --force boost@1.60
My build-python-mapnik.sh
script might be useful to other people on OSX/Mojave:
#!/bin/bash
if [[ "$OSTYPE" == "darwin"* ]]; then
# if Mac OSX:
# Homebrew Boost >= 1.70 on MacOSX Mojave seems to be having troubkle:
# https://github.com/mapnik/python-mapnik/issues/207
brew install mapnik boost-python3 boost@1.60
# unlink boost in case 1.7x is installed already:
brew unlink boost
brew link --force boost@1.60
fi
git clone -b v3.0.x https://github.com/mapnik/python-mapnik
export MASON_BUILD=false
# We get Boost link errors if we don't set these explicitly
export BOOST_PYTHON_LIB=boost_python38
cd python-mapnik
git checkout v3.0.x
set -e # complain if compilation fails
python3 setup.py install
echo
echo "If you want to run the tests to verify python-mapnik:"
echo " cd python-mapnik"
echo " git submodule update --init"
echo " python3 setup.py test"
echo
echo "python-mapnik package installed, you should now be able to do:"
echo " import mapnik"
echo
python3 setup.py install
Getting these errors compiling on the v3.0.x branch with Python 3.7,
mapnik-config --version
is 3.0.22