Monday, February 18, 2019

cslc compilation

On Ubuntu 
 1. install Boost
Download boost
https://www.boost.org/doc/libs/1_62_0/more/getting_started/unix-variants.html

https://codeyarns.com/2017/01/24/how-to-build-boost-on-linux/


 
 undefined reference to `intToString[abi:cxx11](int)'

 https://stackoverflow.com/questions/39826917/boost-build-fails-c11-feature-checks-when-using-custom-gcc-4-x-or-5-x?noredirect=1&lq=1

https://docs.computecanada.ca/wiki/GCC_C%2B%2B_Dual_ABI


https://stackoverflow.com/questions/39826917/boost-build-fails-c11-feature-checks-when-using-custom-gcc-4-x-or-5-x?noredirect=1&lq=1


$ echo "using gcc : 5.4 : /usr/bin/g++-5 : -std=c++11 ;" > ./tools/build/src/user-config.jam



Let's assume for the sake of this example that:
  • You want to build Boost with GCC 5.4
  • The g++ 5.4 binary is at /some/where/g++-5.4
  • You've downloaded the Boost sources and unpacked them into /path/to/sources/of/boost-1.62.0/
  • (Perhaps) you want to install Boost to /dest/path
  • You have N cores (so you want to parallelize the build N-ways)
Now:./b2 install --prefix=--prefix=/opt/local
  1. cd /path/to/sources/of/boost-1.62.0/
  2. Booststrap the build system by running ./bootstrap.sh
  3. echo "using gcc : 5.4 : /usr/bin/g++-5 : -std=c++11 ;" > ./tools/build/src/user-config.jam
  4. ./b2 --prefix=--prefix=/opt/local --toolset=gcc-5 -j 4 define=_GLIBCXX_USE_CXX11_ABI=0
  5. ./b2 --prefix=--prefix=/opt/local --toolset=gcc-5 -j 4 (N being the number of cores on your system)
  6. ./b2 install --prefix=/opt/local
  7.  
  8.  
  9.  ./b2 --prefix=--prefix=/opt/local --toolset=gcc-5 -j 4 define=_GLIBCXX_USE_CXX11_ABI=0

wget https://www-eu.apache.org/dist//xerces/c/KEYS
gpg --import < KEYS
wget https://www-eu.apache.org/dist//xerces/c/3/sources/xerces-c-3.2.2.tar.gz

// Compare the following sha256 to https://www-eu.apache.org/dist//xerces/c/3/sources/xerces-c-3.2.2.tar.gz

sha256sum xerces-c-3.2.2.tar.gz
dd6191f8aa256d3b4686b64b0544eea2b450d98b4254996ffdfe630e0c610413  xerces-c-3.2.2.tar.gz

cd xerces...

./configure
make
sudo make install
$ ls /usr/local/lib/
libxerces-c-3.2.so*  libxerces-c.la*  pkgconfig/  python3.5/
libxerces-c.a         libxerces-c.so@  python2.7/



No comments:

Post a Comment