install gcc
Hi all,
I am going to upgrade gcc to v3.0. Must I uninstall the previous one first? I have installed gcc3.0 directly without removing the previous version. However, when I issue `g++ -v`, it still reports the previous version. So I tried to uninstall the previous version, however, system report I can't do that because of dependences. Anyway, I issue `rpm -e` to remove gcc-g++ and the some libraries finally. After have reinstalled gcc3.0 again, I can compile codes but fail in running them(report xxx.so.3 and so on missing). How can I upgrade gcc correctly? What should I do now? Thanks. |
gcc v3+ is normally called gcc3 not gcc, unless you specifically link it to that name. you should keep 2.9whatever installed aswell. they exist fine side by side.
|
Do you mean I should issue gcc3 rather than gcc for compiling?
|
most confgiure scripts will check for gcc and then gcc3. if you want to compile with gcc3 always then manually change the gcc3 symlink or just uninstall the old one
|
Yes, I found that the new compiler has gcc located at other directory. I built a link point to the new compiler and everything is all right. However, when I run the compiled program which is compiling with the new compiler. Error occurs!!!
/test:relocation error: undefined symbol:_ZTVN10__cxxabiv117__class_type_infoE I think the executable file need some libraries that have linked to the old one. I don't know what to do. |
You need library path to libraries coming with new gcc. If gcc is in /usr/local/bin (default), its libraries are in /usr/local/lib. Add this directory into /etc/ld.so.conf and run ldconfig.
|
Still no good. I don't know why. I can't compile the old source code with new compiler now.
Do you know what cvs is? Can I use cvs to upgrade gcc? How? Thanks. |
All times are GMT -5. The time now is 10:26 PM. |