linux手动安装boost
2015-10-20 21:17
274 查看
查询已安装的boost包:rpm -qa | grep -i boost
然后用yum remove命令删除已安装的boost包
下载最新版本的boost,例如:boost_1_59_0.tar.bz2
tar --bzip2 -xf boost_1_59_0.tar.bz2
cd boost_1_59_0/
./bootstrap.sh --prefix=/usr/local/share/boost-1.59.0/
./b2 install --build-dir=/tmp/ --prefix=/usr/local/share/boost-1.59.0/ --build-type=minimal --layout=tagged toolset=gcc
cp -p /etc/profile /etc/profile.`date +%Y%m%d%H%M%S`
cat >> /etc/profile <<EOF
export BOOST_ROOT=/usr/local/share/boost-1.59.0
export BOOST_INCLUDE=\$BOOST_ROOT/include/
export BOOST_LIB=\$BOOST_ROOT/lib
EOF
source /etc/profile
cat > /etc/ld.so.conf.d/boost.conf <<EOF
$BOOST_LIB
EOF
ldconfig
然后用yum remove命令删除已安装的boost包
下载最新版本的boost,例如:boost_1_59_0.tar.bz2
tar --bzip2 -xf boost_1_59_0.tar.bz2
cd boost_1_59_0/
./bootstrap.sh --prefix=/usr/local/share/boost-1.59.0/
./b2 install --build-dir=/tmp/ --prefix=/usr/local/share/boost-1.59.0/ --build-type=minimal --layout=tagged toolset=gcc
cp -p /etc/profile /etc/profile.`date +%Y%m%d%H%M%S`
cat >> /etc/profile <<EOF
export BOOST_ROOT=/usr/local/share/boost-1.59.0
export BOOST_INCLUDE=\$BOOST_ROOT/include/
export BOOST_LIB=\$BOOST_ROOT/lib
EOF
source /etc/profile
cat > /etc/ld.so.conf.d/boost.conf <<EOF
$BOOST_LIB
EOF
ldconfig
相关文章推荐
- Linux socket 初步
- 升级fedora16beta遇到的问题
- linux lsof详解
- linux 文件权限
- Linux 执行数学运算
- 10 篇对初学者和专家都有用的 Linux 命令教程
- Linux 与 Windows 对UNICODE 的处理方式
- Ubuntu12.04下QQ完美走起啊!走起啊!有木有啊!
- 解決Linux下Android开发真机调试设备不被识别问题
- 运维入门
- 运维提升
- Linux 自检和 SystemTap
- Ubuntu Linux使用体验
- c语言实现hashmap(转载)
- Linux 信号signal处理机制
- linux下mysql添加用户
- Scientific Linux 5.5 图形安装教程
- 基于 Linux 集群环境上 GPFS 的问题诊断
- 谁是桌面王者?Win PK Linux三大镇山之宝