User Tools

Site Tools


gcc_tools

Default gcc is version 4.4.7

Centos 6 only support devtools with gcc/g++ 4.4.7

To see which version of gcc tools are set for your environment:

gcc --version

Software Collections

To install and use other versions, we use Software Collections. This provides a way to easily set up your environment to use a particular version of software that's not installed in a standard location.

The gcc collections below are available both on chead and on the nodes.

To see everything available with scl (Software Collections)

scl -l 

To use a Software Collection, you invoke the scl command like below:

gcc 4.8.2

devtools-2 has been installed and includes gcc 4.8.2. To use it, run this command to enable it for your current login

scl enable devtoolset-2 bash

This will start a new shell that's set up for gcc 4.8.2. Run gcc –version to verify.

gcc 4.9.1

devtools-3 has been installed and includes gcc 4.9.1. To use it, run this command to enable it for your current login

scl enable devtoolset-3 bash

Alternately

For either version you can:

export CC=/opt/rh/devtoolset-[2 or 3]/root/usr/bin/gcc  
export CPP=/opt/rh/devtoolset-[2 or 3]/root/usr/bin/cpp
export CXX=/opt/rh/devtoolset-[2 or 3]/root/usr/bin/c++
gcc_tools.txt · Last modified: 2017/06/02 19:43 by mgstauff