linux系统下mapnik地图渲染源码安装

参考官方https://github.com/mapnik/mapnik/wiki/UbuntuInstallation

1.安装之前执行以下命令

sudo apt-get update
sudo apt-get upgrade

2、源码安装

  1. 更新过期clang
# you might have to update your outdated clang
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
sudo apt-get update -y
sudo apt-get install -y gcc-6 g++-6 clang-3.8
export CXX="clang++-3.8" && export CC="clang-3.8"
  1. 安装mapnik
 # install mapnik
git clone https://github.com/mapnik/mapnik mapnik --depth 10
cd mapnik
git submodule update --init
sudo apt-get install python zlib1g-dev clang make pkg-config curl
source bootstrap.sh
./configure CUSTOM_CXXFLAGS="-D_GLIBCXX_USE_CXX11_ABI=0" CXX=${CXX} CC=${CC}
  1. 编译
make
  1. 测试
make test
  1. 安装
  `sudo make install` 

你可能感兴趣的:(c++)