My setup: Red Hat Enterprise Linux Server release 7.6 (Maipo)
I was previously having a linking problem when trying to link with a boost static library, which i had found out was caused of it being compiled with the C++17 standard with GCC 8.2 but /usr/lib64/libstdc++.so.6 pointing to libstdc++.so.6.0.19
. GCC 8.2 was installed from development-toolset8
which I enabled with source /opt/rh/devtoolset-8/enable
.
Now my question is what is the best practice way to solve this?( i have read quite a lot on this so i have 2 solution below, more like 1 cause the other one is a glimpse of an idea)
1) I download the package and do the installation from here specifying --enable-shared --prefix=$HOME/gcc
(any other options that you think might be useful? ) Do i need to uninstall the dev-toolset8 for this? Then i recompile the boost package with the flag -D_GLIBCXX_USE_CXX11_ABI=1
,
2) i try to somehow compile(i have no clue how) the libstdc++.so from the /opt/rh/devtoolset-8/root/usr/lib/gcc/x86_64-redhat-linux/8/libstdc++.a
(How do i do this? no idea?)
Similar description of my problem which seems to be a:RedHat bug
Thank you