使用自己的toolset, c++11, c++0x來編譯boost

Adam posted @ Sun, 28 Jul 2013 23:24:35 +0800 in C++ with tags c++ boost , 2314 readers

使用自己的toolset, c++11, c++0x來編譯boost

在解壓出的boost文件夾中tools/build/v2/user-config.jam文件中添加如下configuration

# Configure gcc-4.8
using gcc 
    : 4.8 
    : "/usr/bin/g++-4.8"
    : <cxxflags>"-std=c++11 -march=native -flto -O3" <linkflags>"-flto -O3"                                       
;

然後,使用./b2 toolset=gcc-4.8來編譯BOOST即可。


Login *


loading captcha image...
(type the code from the image)
or Ctrl+Enter