Skip to main content Skip to navigation

Compiling needs a higher version of gcc or another compiler

Sometimes it is required or desirable for higher versions of compilers to be used to compiler software. As the base distibution we use (CentOS) is a long term supported stable distribution, the versions of these compilers are not regularly updated. This means that newer features are not supported which can prevent software from compiling or disable new desirable features. It is not practical to simply change all of the compiler versions as it is recommended that all sources are built with the same version of the compiler used to build the kernel, especially kernel modules, as this process is often automatated, the default compilers must remain the same.

A solution to this problem is to use a developer toolset as provided by Centos Software Collections.

We currently have Developer Toolset 6 installed and available on all Managed Linux Desktops. To use the packages in this toolset they must be enabled. You can do this with the following code:

$ scl enable devtoolset-6 bash

This will give you a bash shell that uses the developer tools rather than the standard tools in the distribution. To return to your normal shell simply exit the shell by typing the "exit" command.

The current versions included in the developer toolset are as follows:

binutils 2.27-12.el7.1
dwz 0.12-1.el7
dyninst 9.2.0-4.el7
elfutils 0.168-3.el7
elfutils-libelf 0.168-3.el7
elfutils-libs 0.168-3.el7
gcc 6.3.1-3.1.el7
gcc-c++ 6.3.1-3.1.el7
gcc-gfortran 6.3.1-3.1.el7
gdb 7.12.1-48.el7
libquadmath-devel 6.3.1-3.1.el7
libstdc++-devel 6.3.1-3.1.el7
ltrace 0.7.91-17.el7
make 1:4.1-3.el7
memstomp 0.1.5-5.el7
oprofile 1.1.0-4.el7
perftools 6.1-1.el7
runtime 6.1-1.el7
strace 4.12-3.el7
systemtap 3.0-8s.el7
systemtap-client 3.0-8s.el7
systemtap-devel 3.0-8s.el7
systemtap-runtime 3.0-8s.el7
toolchain 6.1-1.el7
valgrind 1:3.12.0-1.el7