I believe there is a bug in your setup of the C++ part of
I just did a custom install of Red Hat 5.2, and selected for
installation all packages pertaining to C and
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
[jao@zack jao]$ ls -l /usr/local/bin
lrwxrwxrwx 1 root root 51 Apr 9 03:21 cc1
lrwxrwxrwx 1 root root 55 Apr 9 03:23
lrwxrwxrwx 1 root root 51 Apr 9 03:21 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
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
This appears to be an interesting consequence of RedHat 5.2's
C++ compiler being egcs but the default 'gcc' being gcc-220.127.116.11.
'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 18.104.22.168 C++ compiler (not installed).
You should not be using gcc for c++; use egcs/c++ instead.