Installations
Les commandes sont données pour un système avec ubuntu server 16.04.
Mises à jour & installations serveurs
sudo apt-get update && sudo apt-get upgrade sudo apt-get install tasksel sudo tasksel install lamp-server sudo tasksel install postgresql-server
Installation des dépendances
sudo apt-get install libboost-all-dev subversion git-core tar unzip wget bzip2 build-essential autoconf libtool libxml2-dev libgeos-dev libgeos++-dev libpq-dev libbz2-dev libproj-dev munin-node munin libprotobuf-c-dev protobuf-c-compiler libfreetype6-dev libpng12-dev libtiff5-dev libicu-dev libgdal-dev libcairo2-dev libcairomm-1.0-dev apache2-dev libagg-dev liblua5.3-dev ttf-unifont lua5.3 liblua5.3-dev node-carto
Installation de PostGIS
sudo apt-get install postgresql-contrib postgis postgresql-9.5-postgis-2.2
Conf de PostGIS
sudo -u postgres -i psql CREATE ROLE username LOGIN PASSWORD 'pass-en-clair'; CREATE DATABASE template_postgis TEMPLATE template0; \c template_postgis; CREATE EXTENSION postgis; \q
Installation d’osm2pgsql
Installation des dépendances
sudo apt-get install make cmake g++ libboost-dev libboost-system-dev libboost-filesystem-dev libexpat1-dev zlib1g-dev libbz2-dev libpq-dev libgeos-dev libgeos++-dev libproj-dev
mkdir ~/src cd ~/src git clone https://github.com/openstreetmap/osm2pgsql.git cd osm2pgsql mkdir build cd build cmake .. make sudo make install
Installation de Mapnik
cd ~/src git clone https://github.com/mapnik/mapnik.git cd mapnik git submodule update --init sudo apt-get install python zlib1g-dev clang make pkg-config source bootstrap.sh ./configure CUSTOM_CXXFLAGS="-D_GLIBCXX_USE_CXX11_ABI=0" make make test sudo make install
sudo apt-get install libmapnik-dev
Installation de mod_tile & renderd
cd ~/src git clone https://github.com/openstreetmap/mod_tile.git cd mod_tile/ ./autogen.sh ./configure make
Pour le moment, cette étape ne passe pas.
Sur le make, j’ai les erreurs suivantes :
g++: error: unrecognized command line option ‘-Wtautological-compare’ g++: error: unrecognized command line option ‘-Wheader-hygiene’
J’ai pu corriger la première en éditant : ~/src/mod_tile/Makefile
et en remplacant
-Wtautological-compare
par
-Tautological-compare
Mais pour la deuxième, je cherche encore.
La suite de l’installation serait :
sudo make install sudo make install-mod_tile