This service will be undergoing maintenance at 00:00 UTC, 2016-09-28. It is expected to last about 1 hours
Bug 2104 - C++ compilation doesn't work following installation of relevant packages
C++ compilation doesn't work following installation of relevant packages
Status: CLOSED NOTABUG
Product: Red Hat Linux
Classification: Retired
Component: egcs (Show other bugs)
5.2
All Linux
high Severity high
: ---
: ---
Assigned To: David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-04-09 21:47 EDT by jao
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-04-12 10:45:06 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description jao 1999-04-09 21:47:55 EDT
I believe there is a bug in your setup of the C++ part of
gcc.

I just did a custom install of Red Hat 5.2, and selected for
installation all packages pertaining to C and
C++ development.

gcc worked when compiling .c files. However, when compiling
.cc files, there was an error message, indicating that
cc1plus could not be found. cc1plus and related executables
are in /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.90.29, but
they aren't on the default PATH, nor are there any links to
them on PATH. I fixed this by setting up some links in
/usr/local/bin:

[jao@zack jao]$ ls -l /usr/local/bin
total 0
lrwxrwxrwx   1 root     root           51 Apr  9 03:21 cc1
-> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.90.29/cc1
lrwxrwxrwx   1 root     root           55 Apr  9 03:23
cc1plus ->
/usr/lib/gcc-lib/i386-redhat-linux/egcs-2.90.29/cc1plus
lrwxrwxrwx   1 root     root           51 Apr  9 03:21 cpp
-> /usr/lib/gcc-lib/i386-redhat-linux/egcs-2.90.29/cpp


Being new to Linux, I'm not sure this is the best solution,
but it seems to work.

I think you should fix your egcs-c++ installation to ensure
that these executables are reachable from /usr/bin or
/usr/local/bin.

I'd also appreciate it if you could let me know if my fix is
correct, or if there is something else more consistent with
FSSTND. Thanks.

Jack Orenstein
Comment 1 Chris Siebenmann 1999-04-09 23:39:59 EDT
This appears to be an interesting consequence of RedHat 5.2's
C++ compiler being egcs but the default 'gcc' being gcc-2.7.2.3.
'c++ -c foo.cc' and 'egcs -c foo.cc' both work, but 'gcc -c foo.cc'
bombs out with this error, presumably because it's trying to use
the 2.7.2.3 C++ compiler (not installed).
Comment 2 Bill Nottingham 1999-04-12 10:45:59 EDT
You should not be using gcc for c++; use egcs/c++ instead.

Note You need to log in before you can comment on or make changes to this bug.