BOOST安裝
1,解壓
tar xzvf boost_1_60_0.tar.gz
2,進入執行
./bootstrap.sh,
3,執行
./b2 cxxflags="-std=c++11"
4,執行
sudo ./b2 install
5,編輯vi ~.profile 增加以下內容:
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
export LD_LIBRARY_PATH
測試demo:
#include <iostream>
#include <boost/version.hpp>
#include <boost/config.hpp>
using namespace std;
int main()
{
cout << BOOST_VERSION << endl;
cout << BOOST_LIB_VERSION << endl;
cout << BOOST_PLATFORM << endl;
cout << BOOST_COMPILER << endl;
cout << BOOST_STDLIB << endl;
return 0;
}