Open fiatracer28 opened 7 years ago
Hello !
I think the python bindings are not needed for Mapnik 2, you need them for Mapnik 3.
"ImportError: No module named mapnik" means that python can't find mapnik in the folder /Library/Python/2.7/site-packages ; did you have any mapnik-related folder or file in it ?
PS : why are you on mapnik 2 and not on mapnik 3 ? If you are afraid to install mapnik 3, I can help you, I've managed to install mapnik 3 from source under El Capitan and Sierra.
@djakk : do you install mapnik 3 on Sierra with python3? I am trying to install mapnik with python3 from source and I pump into this issue: BOOST_SPIRIT_DEFINE( ^ /usr/local/include/boost/spirit/home/x3/nonterminal/rule.hpp:184:5: note: expanded from macro 'BOOST_SPIRIT_DEFINE' BOOST_SPIRITDEFINE, _, BOOST_PP_VARIADIC_TO_SEQ(__VA_ARGS__)) \ ^ include/mapnik/svg/svg_path_grammar_x3_def.hpp:119:21: note: candidate function template not viable: requires single argument 'ctx', but no arguments were provided auto const arc_to = [] (auto & ctx) ^ 2 errors generated. scons: [src/svg/svg_path_grammar_x3.os] Error 1 scons: building terminated because of errors. make: [mapnik] Error 2
Do you have any suggestion how to solve this?
The steps that I did:
git clone https://github.com/mapnik/mapnik.git cd mapnik/ git submodule update --init PYTHON=python3 ./configure make PYTHON=python3
Thank you
Hello @ngunhaSO ! Unfortunately, I did install with python 2.7 only. What is your config file ?
@djakk I decided to use brew to install the mapnik. mapnik-config --version 3.0.20
Now I am stuck with the mapnik-python installation. I keep getting this error: "ld: library not found for -lboost-python3 clang: error: linker command failed with exit code 1 (use -v to see invocation) error: command 'clang++' failed with exit status 1"
Even though when i do: brew list | grep 'boost', I got the following boost like the below boost boost-python boost-python3
Before I ran: python3 setup.py build, I also exported the environment by doing this: export BOOST_PYTHON_LIB=boost-python3
But the error still persists
Full steps that I did to try to install this mapnik-python mapping:
My python3 version: python3 --version Python 3.6.5 mapnik-config --version 3.0.20
Do you have any idea how to fix this?
If i do: export MASON_BUILD=true, I got a different error: /Users/jackynguyen/Downloads/python-mapnik/mason_packages/.link/include/boost/config/posix_features.hpp:18:15: fatal error: 'unistd.h' file not found
Hi
I am sure this is not a new issue, but I can't seem to find a solution.
I have installed Mapnik 2.2 via the OSX 64 bit package and I get the error "ImportError: No module named mapnik"
I also tried the Homebrew installation with the same message. Can anyone help with the solution please, I did read on a forum Python bindings need to be installed, but cannot find anything about how to do this.
I am new to all of this so any idiot proof advice would be greatly appreciated!
Thanks