Files
xahaud/bin/sh/install-boost.sh
2015-09-18 12:18:38 -04:00

21 lines
587 B
Bash

#!/bin/sh
# Assumptions:
# 1) BOOST_ROOT and BOOST_URL are already defined,
# and contain valid values.
# 2) The last namepart of BOOST_ROOT matches the
# folder name internal to boost's .tar.gz
set -e
if [ ! -d "$BOOST_ROOT/lib" ]
then
wget $BOOST_URL -O /tmp/boost.tar.gz
cd `dirname $BOOST_ROOT`
tar xzf /tmp/boost.tar.gz
cd $BOOST_ROOT && \
./bootstrap.sh --prefix=$BOOST_ROOT && \
./b2 -d1 define=-D_GLIBCXX_USE_CXX11_ABI=0 && ./b2 -d0 define=-D_GLIBCXX_USE_CXX11_ABI=0 install
define=-D_GLIBCXX_USE_CXX11_ABI=0
else
echo "Using cached boost at $BOOST_ROOT"
fi