4

I have installed the devtoolset-2 package on my Centos 6.7 64 bits. As recommanded by RH,when i want to switch from gcc 4.4.7 to gcc 4.8.2, i open a terminal and type either scl enable devtoolset-2 'bash' if i wanna run gcc in another shell or source /opt/rh/devtoolset-2/enable if i wanna run gcc in the current shell and this works just fine.

Now i would like to use gcc 4.8.2 from Qt 5.7 , so i set up a new Kit and add the new compiler version by adding the path to the g++ and gcc compilers located in /opt/rh/devtoolset-2/root/usr/bin/g++ ( same for gcc ) in compilers paths. And i am able to run the elastic node example using the new Kit to build it.

But i still have a doubt on this procedure because from Qt Creator, i am not using the command scl enable devtoolset-2 'bash' or source /opt/rh/devtoolset-2/enable, only add compilers path, so is it the right way to use devtoolset-2 with Qt ?

Vertexwahn
  • 7,709
  • 6
  • 64
  • 90
Fryz
  • 2,119
  • 2
  • 25
  • 45

1 Answers1

0

you can run one of those commands

scl enable devtoolset-2 'bash'

and

source /opt/rh/devtoolset-2/enable

by adding them into building steps before qmake execution.

ParisaN
  • 1,816
  • 2
  • 23
  • 55