Skip to content

Instantly share code, notes, and snippets.

@JBaczuk
Last active August 25, 2018 20:50
Show Gist options
  • Save JBaczuk/d65b585677962c41dd4ac5939f75e78f to your computer and use it in GitHub Desktop.
Save JBaczuk/d65b585677962c41dd4ac5939f75e78f to your computer and use it in GitHub Desktop.
C++ Environment

Boost

Get the version of Boost that you require.

See https://sourceforge.net/projects/boost/files/boost/ for list of versions

wget https://astuteinternet.dl.sourceforge.net/project/boost/boost/1.68.0/boost_1_68_0.tar.gz
tar xzvf boost_1_68_0.tar.gz
cd boost_1_68_0/

Get the required libraries, main ones are icu for boost::regex support:

sudo apt-get update
sudo apt-get install build-essential g++ python-dev autotools-dev libicu-dev build-essential libbz2-dev 

Boost's bootstrap setup:

./bootstrap.sh

Find the maximum number of physical cores:

n=`cat /proc/cpuinfo | grep "cpu cores" | uniq | awk '{print $NF}'`

Install boost in parallel:

sudo ./b2 --with=all -j $n install

Reset the ldconfig:

sudo ldconfig

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment