LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 11-30-2005, 08:43 AM   #1
syavne
LQ Newbie
 
Registered: Jun 2004
Distribution: Fedora Core
Posts: 9

Rep: Reputation: 0
Unhappy Rollback of gcc failed and rpm is not working


I used apt to get the new kernel (2.6.14-1.1644) and gcc was updated to 4.0.2-8 at the same time.

However, I needed to recompile a kernel driver and I found a warning:
>> Your kernel was built with "gcc" version "4.0.1", while you are trying to use
>> "/usr/bin/gcc" version "4.0.2".
As expected, the driver didn't work.

So, what I did was to try to rollback the update with the command:
>> rpm -Uvh /var/cache/apt/archives/*4.0.1-4* --force

And the following packages were re-installed:
cpp_4.0.1-4.fc4_i386.rpm libgcj_4.0.1-4.fc4_i386.rpm
gcc_4.0.1-4.fc4_i386.rpm libgcj-devel_4.0.1-4.fc4_i386.rpm
gcc-c++_4.0.1-4.fc4_i386.rpm libgfortran_4.0.1-4.fc4_i386.rpm
gcc-gfortran_4.0.1-4.fc4_i386.rpm libstdc++_4.0.1-4.fc4_i386.rpm
gcc-java_4.0.1-4.fc4_i386.rpm libstdc++-devel_4.0.1-4.fc4_i386.rpm
libgcc_4.0.1-4.fc4_i386.rpm

I successfully compiled the kernel module, however when I try to run applications this error shows up and there's nothing I can do:
>> rpm: error while loading shared libraries: libstdc++.so.6:
>> cannot open shared object file: No such file or directory

It pressents with the rpm command so I can't use it to update gcc to use the correct version.

Now I understand, it was a really bad idea to try the rollback of gcc and I deserve the punishment of reinstalling the entire OS, not such a punishment really since my home directory is in an independent partition and the same goes to apt archives, but it will take a couple of hours.

Is there any way to correct this problem without a full reinstallation of the OS?.
 
Old 11-30-2005, 06:55 PM   #2
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Try to determine whether this library file exists or not. I'm betting that it does, because everything uses it, yet the error message indicates that it doesn't exist at all. If may be a symlink to libstd+++.so. If it does exist, then try running the "ldconfig" command as root. Sometimes this will fix up the library paths, in the case when it wasn't done successfully after using the RPM command.

On the other hand, I think that it was the "--force" option which did you in. You may have ignored other packages which depend on packages that you had replaced.

Good Luck. I'm not couragous enough to attempt to update gcc on my system without upgrading the distro.

Last edited by jschiwal; 11-30-2005 at 07:52 PM.
 
Old 12-01-2005, 05:52 AM   #3
syavne
LQ Newbie
 
Registered: Jun 2004
Distribution: Fedora Core
Posts: 9

Original Poster
Rep: Reputation: 0
You're right!, it was a problem with the symlink.

The file libstdc++.so.6.0.7 wasn't there so I just extracted the missing file from the latest RPM and it solved everything, it was a little bit difficult to extract the file from the rpm but it worked.

Thank you very much for your reply.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
nvidia drivers, gcc-version-check failed Seiken Slackware 26 02-25-2005 09:50 PM
gcc wont install, 'failed dependencies: glibc-devel is needed by gcc-3.3.3-41' TdlSnare SUSE / openSUSE 3 11-29-2004 02:13 PM
rpm - failed dependencies jonnycarlos Linux - Software 3 04-15-2004 10:57 AM
RPM 'failed dependencies': Why can I not install any rpm packages? leontini Linux - Newbie 7 09-16-2003 12:44 AM
RPM Rollback (Patch installation) adme Linux - General 3 04-15-2003 03:27 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 05:46 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration