首先下载cppcms库
wget -O cppcms-1.0.5.tar.bz2 http://downloads.sourceforge.net/project/cppcms/cppcms/1.0.5/cppcms-1.0.5.tar.bz2?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fcppcms%2Ffiles%2F&ts=1443867793&use_mirror=jaist
解压
tar jxvf cppcms-1.0.5.tar.bz2
然后安装依赖程序和库
apt-get install libpcre3-dev zlib1g-dev libgcrypt20-dev
需要修改CMakeLists.txt文件的140行
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
set(CXX_FLAGS "-Wall -Wextra -std=c++11")
开始编译
cd cppcms-1.0.5/
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr ..
make
make test
最后进行安装
sudo make install
Ubuntu 15.04 clang++ 4.6编译boost 1.59:http://www.linuxdiyf.com/linux/14611.html
在ubuntu14.04上安装clang 3.6:http://www.linuxdiyf.com/linux/14259.html
在Linux CentOS上编译并安装Clang 3.5.0:http://www.linuxdiyf.com/linux/11534.html