11

I have a RHEL 6 machine, which came with gcc but without g++. The gcc version is 4.4.4 20100726 (this is what I got from gcc --version).

How can I get g++ working? Currently, the shell just returns "command not found".

1
  • 1
    It's called gcc-c++ in RedHat. Commented Nov 23, 2010 at 14:32

1 Answer 1

16

You need to install the gcc-c++ package: yum install gcc-c++

4
  • 1
    Thank you - but I'm getting "No package gcc-c++ available". What can be the reason? Commented Nov 23, 2010 at 14:45
  • Post the results of rpm -qa | grep gcc Commented Nov 23, 2010 at 15:03
  • @iamsid rpm -qa | grep gc for me gives only these packages: libgcc-4.4.5-6.el6.x86_64, gcc-4.4.5-6.el6.x86_64 Commented Aug 20, 2011 at 14:09
  • @ArtemAO If your server is not registered on rhn yum will not work.. You'd have to install the version on your cd. Commented Aug 20, 2011 at 16:43

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.