WebFaction
Community site: login faq

I would like to build mapnik from source but cannot meet the requirement for Boost correctly.

wget http://www.freedesktop.org/software/harfbuzz/release/harfbuzz-0.9.26.tar.bz2
tar xf harfbuzz-0.9.26.tar.bz2
cd harfbuzz-0.9.26
./configure && make && sudo make install

Exiting... the following required dependencies were not found:
   - boost version >= 1.47 (more info see: https://github.com/mapnik/mapnik/wiki/Mapnik-Installation & http://www.boost.org)
   - boost thread (more info see: https://github.com/mapnik/mapnik/wiki/Mapnik-Installation & http://www.boost.org)

See '/home/blowr/src/mapnik-2.3.x/config.log' for details on possible problems.

I thought I installed Boost correctly following the doc but still go that error when building mapnik

tar -xzf boost_1_53_0.tar.gz
cd boost_1_53_0^C
./bootstrap.sh
./b2 install

Do you have a procedure to install Boost?

asked 28 Apr '14, 00:10

burton449
1317
accept rate: 0%


You need to add the --prefix flag to your b2 command. Here are all the commands to install Boost, scons and Mapnik:

mkdir -p $HOME/bin $HOME/lib $HOME/src $HOME/tmp

export TMPDIR=$HOME/tmp
export PATH="$HOME/bin:$PATH"
export C_INCLUDE_PATH="$HOME/include:$C_INCLUDE_PATH"
export LIBRARY_PATH="$HOME/lib:$LIBRARY_PATH"
export LD_LIBRARY_PATH="$HOME/lib:$LD_LIBRARY_PATH"
export PKG_CONFIG_PATH=$HOME/lib/pkgconfig
export PYTHON=/usr/local/bin/python2.7

cd ~/src
wget http://sourceforge.net/projects/boost/files/boost/1.55.0/boost_1_55_0.tar.gz
tar zxf boost_1_55_0.tar.gz
cd boost_1_55_0
./bootstrap.sh
./b2 install --prefix=$HOME

cd ~/src
wget http://sourceforge.net/projects/scons/files/scons/2.3.1/scons-2.3.1.tar.gz
tar zxf scons-2.3.1.tar.gz
cd scons-2.3.1
python2.7 setup.py install

cd ~/src
wget http://mapnik.s3.amazonaws.com/dist/v2.2.0/mapnik-v2.2.0.tar.bz2
tar -xjf mapnik-v2.2.0.tar.bz2
cd mapnik-v2.2.0
./configure PREFIX=$HOME DESTDIR=$HOME BOOST_INCLUDES=$HOME/include/boost BOOST_LIBS=$HOME/lib PYTHON=/usr/local/bin/python2.7 PYTHON_PREFIX=$HOME
python2.7 scons/scons.py --jobs=1 install PREFIX=$HOME PYTHON_PREFIX=$HOME
permanent link

answered 28 Apr '14, 16:39

timg ♦♦
1.3k4
accept rate: 30%

edited 28 Apr '14, 16:40

Really great support! Thank you very much!

(28 Apr '14, 16:43) burton449

Installing Boost and scons was working correctly, but after many attempts I was unable to install mapnik because the ssh sessions were closed by remote host.

(03 May '14, 22:19) burton449

Run it in a screen session, so that the process will continue running even if your SSH session disconnects.

Hope that helps!

(04 May '14, 00:17) ryans ♦♦

Running the install in a screen works correctly. However, mapnik python bindings are not installed in python2.7

In a ssh session doing:

python2.7 -c "from mapnik import DatasourceCache as c; print ','.join(c.plugin_names())
ImportError: No module named mapnik

I can see the mapnik python bindings are installed in ~/home/blowr/home/blowr/lib/python2.7/site-packages/mapnik

Should I change the PYTHON variable path to /home/blowr/lib/python2.7 prior the install?

I have the same problem with bin command:

mapnik-config
-bash: mapnik-config: command not found

Thank you!

(04 May '14, 21:46) burton449
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×103
×2

question asked: 28 Apr '14, 00:10

question was seen: 3,908 times

last updated: 04 May '14, 23:50

                              
WEBFACTION
REACH US
SUPPORT
LEGAL
© COPYRIGHT 2003-2021 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM