Last active
August 7, 2022 20:10
-
-
Save jimporter/10442880 to your computer and use it in GitHub Desktop.
Build Boost against libc++
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# First, build libc++ See <http://libcxx.llvm.org/>, "Build on Linux using CMake | |
# and libsupc++." and substitute libsupc++ for libstdc++. NOTE: You'll probably | |
# need to explicitly link libsupc++ when you compile your own code! | |
# | |
# Next, download Boost and extract it somewhere. Set SRC_DIR to that location. | |
SRC_DIR=$HOME/src/boost_1_55_0 | |
# Set this to be the install prefix. "/usr" is also a good choice. | |
INSTALL_DIR=$HOME | |
cd $SRC_DIR | |
./bootstrap.sh --with-toolset=clang --prefix=$INSTALL_DIR | |
./b2 clean | |
./b2 toolset=clang cxxflags="-std=c++1y -stdlib=libc++" linkflags="-stdlib=libc++" --prefix=$INSTALL_DIR -j 4 stage release | |
./b2 install toolset=clang cxxflags="-std=c++1y -stdlib=libc++" linkflags="-stdlib=libc++" --prefix=$INSTALL_DIR |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment