Skip to content
This repository has been archived by the owner on Oct 17, 2024. It is now read-only.

Commit

Permalink
Use CMake for Boost to avoid compiling b2
Browse files Browse the repository at this point in the history
  • Loading branch information
bryanwweber committed Jul 16, 2024
1 parent 646c883 commit 644e9ca
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions install_boost.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@ pushd /tmp
BOOST_DOWNLOAD_FILE="/cache/boost-cmake.tar.xz"
curl -fsSL -o $BOOST_DOWNLOAD_FILE https://github.com/boostorg/boost/releases/download/boost-${BOOST_VERSION}/boost-${BOOST_VERSION}-cmake.tar.xz
tar -xf $BOOST_DOWNLOAD_FILE -C /tmp
pushd boost-${BOOST_VERSION}
mkdir -p boost-${BOOST_VERSION}/build
pushd boost-${BOOST_VERSION}/build

./bootstrap.sh --prefix=${BOOST_DIR}
# We have to explicitly include cmakedir here so that cmake files are installed
./b2 variant=release toolset=gcc --with-headers --cmakedir=${BOOST_DIR}/lib/cmake install
cmake -G "Ninja" \
-DCMAKE_BUILD_TYPE=release \
-DBOOST_INCLUDE_LIBRARIES="algorithm;dll;stacktrace;core;math;numeric/ublas;serialization;multi_array" \
..
ninja install

popd

Expand Down

0 comments on commit 644e9ca

Please sign in to comment.