2

Please help me to install dev toolset-8 in rhel 8 image.

i have pulled the base image as below . I want to install devtoolset-8. is there any other way please let me know.

sudo docker pull registry.access.redhat.com/ubi8/ubi:8.2

Prashant Naik
  • 105
  • 1
  • 8

3 Answers3

3

devtoolset is called gcc-toolset in RHEL8.

The following commands worked for me:

microdnf install -y gcc-toolset-12
scl enable gcc-toolset-12 bash
gcc --version
# gcc (GCC) 12.1.1 20220628 (Red Hat 12.1.1-3)
Tyler2P
  • 2,324
  • 26
  • 22
  • 31
Mirko Wf
  • 33
  • 5
0

According to that article, you can check if you have access to Red Hat Software Collections (RHSCL) by running the following command by the root user:

$ su -
# subscription-manager repos --list | egrep rhscl

If you have, enable necessary software repo and then install devtoolset:

# subscription-manager repos --enable rhel-7-server-optional-rpms
# yum install devtoolset-8
Rigidit
  • 1
  • 1
0

The other answer seems to be for RHEL 7.

On the RedHat site

Chrisian Labisch answered this with:

RHEL 8 doesn't work with Software Collections, RHEL 8 uses modules instead.

sudo dnf module list

In RHEL 8 you find the developer tools in the CodeReady Builder repository. :)

sudo subscription-manager repos --enable codeready-builder-for-rhel-8-x86_64-rpms

But even that seems to be unneeded because the system compiler version for RHEL is already GCC 8, so you would normally only need devtoolset-9 or up for it, if I understood the purpose correctly.

Additionally this blog post outlines the differences between the old SCL toolsets and the new AppStreams concept.

PeterT
  • 7,981
  • 1
  • 26
  • 34