Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Library problems
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Tue Aug 16, 2005 9:09 pm    Post subject: Library problems Reply with quote

Despite practically re-installing the system, I cannot get rid of some library problems.

See here how it started. In short, I was a bit careless in emerging a package (brlcad) that overwrote a couple of system libraries. Then, I think something like this must have happened (not 100% sure): The system started to depend on those libs. Then when I tried to upgrade the package, all kinds of apps were missing the libs they had come to depend on. I then chose to unmerge the package. Luckily, an "emerge -e world" solved all of the dependencies, except for one. That is:

Code:

/lib/librt.la


Not really knowing what to do, I figured that a bootstrap over the currently running system couldn't hurt. After that I am now doing another emerge -e world. Unfortunately, the problem is not gone.

I have no idea what to do next. Are there some strategies how to get rid of this, preferably without re-installing the system from scratch? I have never really had such issues. Thanks for any help, hints or links regarding some good reading on this.

List of apps that fail to start (not complete):
Code:

mplayer
all things efl ( e, entice, entrance, evidence, etc..... )
xine and it's clients


When one of these apps fails to start, this is a typical error message:
Code:

rogier@rosj ~ $ mplayer
mplayer: error while loading shared libraries: librt.19: cannot open shared object file: No such file or directory


Packages that I know fail to compile (not complete):
Code:
DirectFB
some things efl
all things related to xine

It is funny to see, that some apps, do compile, but fail to run. Mplayer is one of those.

When one of these apps fails to compile, this is typical error message:
Code:

/usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.5-20050130/../../../../i686-pc-linux-gnu/bin/ld: warning: creating a DT_TEXTREL in object.
creating libdirectfb_sdl.la
/bin/sed: can't read /usr/lib/librt.la: No such file or directory
libtool: link: `/usr/lib/librt.la' is not a valid libtool archive
make[3]: *** [libdirectfb_sdlinput.la] Error 1
make[3]: *** Waiting for unfinished jobs....
/bin/sed: can't read /usr/lib/librt.la: No such file or directory
libtool: link: `/usr/lib/librt.la' is not a valid libtool archive
make[3]: *** [libdirectfb_sdl.la] Error 1
make[3]: Leaving directory `/var/tmp/portage/DirectFB-0.9.22/work/DirectFB-0.9.22/systems/sdl'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/DirectFB-0.9.22/work/DirectFB-0.9.22/systems'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/DirectFB-0.9.22/work/DirectFB-0.9.22'
make: *** [all] Error 2

!!! ERROR: dev-libs/DirectFB-0.9.22 failed.
!!! Function src_compile, Line 103, Exitcode 2
!!! (no error message)
!!! If you need support, post the topmost build error, NOT this status message.

rogier rogier #
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Wed Aug 17, 2005 1:34 pm    Post subject: Reply with quote

Rosjahh wrote:
Code:
libtool: link: `/usr/lib/librt.la' is not a valid libtool archive
Obviously /usr/lib/librt.la is a broken symlink (its target, probably /lib/librt.la, no longer exists). Get rid of the broken symlink with
Code:
rm /usr/lib/librt.la
and re-emerge the packages that complain about the missing library.
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Wed Aug 17, 2005 9:24 pm    Post subject: Reply with quote

moocha, well yes, that seems obvisous. but unfortunately, the link from /usr/lib/librt.la doesn't exist !! :?

Code:

rogier lib # ls -lh /usr/lib/librt.la
ls: /usr/lib/librt.la: No such file or directory


So I have no idea, why the compile process tries to follow an non-existing link.... ?? There must be some leftovers somewhere ( in libtool?) that have a reference to /usr/lib/librt.la , but I have no idea where (and how) to start looking.
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Wed Aug 17, 2005 9:29 pm    Post subject: Reply with quote

Odd. Then let's turn to trusty ole grep:
Code:
grep -r librt\\.la /usr/lib
(try it on /lib too if the previous search doesn't turn up any matches). This is slow as hell, but it should give some more clues.
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Wed Aug 17, 2005 9:43 pm    Post subject: Reply with quote

Okay running now!
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Wed Aug 17, 2005 11:12 pm    Post subject: Reply with quote

First one is done. The result of "grep -r librt\\.la /lib", so checking /lib only.

See here.

Scan of /usr/lib still running.

What to do with these results?
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Thu Aug 18, 2005 6:16 am    Post subject: Reply with quote

Hmm. Removing the /usr/lib/librt.la instances from all the files should fix it. Don't know whether
Code:
fix_libtool_files.sh
takes care of this (haven't used it in a while).... If not, you may need to do it manually, bleh.
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Thu Aug 18, 2005 7:57 am    Post subject: Reply with quote

Well, I already tried fix_libtool_files.sh, a couple of times, so that'll be manual then. I'm going to look at this tonight again (around 9 hours from now). Thanks for helping !
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Thu Aug 18, 2005 2:43 pm    Post subject: Reply with quote

Of course, you won't be able to remove it from the binary files that matched, but a revdep-rebuild should take care of those (or, if no other less time-consuming way can be found, an emerge -e world) :).
Hope you'll get your system fixed soon. Good luck!
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Fri Aug 19, 2005 10:08 am    Post subject: Reply with quote

Yeah thanks. After removing all those references to librt.la files and a revdep-rebuild, some packages start to work again. Most notably is the xine family. Mplayer and everything enlightenment related is still not fixed. So I am in an emerge -e world again, for something like the fifth time now. Yay 8O

EDIT: mplayer is also working again now. So only enlightenment is still to go. I'm pretty confident that everything will return to normal.
Back to top
View user's profile Send private message
gabrielitos
n00b
n00b


Joined: 21 Dec 2005
Posts: 16

PostPosted: Sat Nov 03, 2007 10:04 am    Post subject: Reply with quote

Hi,I got the same problem with the same library! Your topic is very useful, but how can you remove all the references to the missing library? I ran grep on my folders and there are a lot of results...
Back to top
View user's profile Send private message
Rosjahh
Apprentice
Apprentice


Joined: 16 Jan 2003
Posts: 182
Location: Below sealevel

PostPosted: Sun Nov 04, 2007 2:33 pm    Post subject: Reply with quote

gabrielitos, I switched to debian a year ago. I'm not as good around the system as I used to be. But, I think I followed the advice moocha gave here: manually removing references to

"/usr/lib/librt.la"

references in all files that were found by

"grep -r librt\\.la /usr/lib"

and then run re-emerge the packages that had those references and those that depend on them. But this is all from memory, so I am not 100% sure how I did it. But I am 100% percent sure that I did recover from these problems with an install from scratch.

Good luck !
Back to top
View user's profile Send private message
lexington
n00b
n00b


Joined: 10 Apr 2005
Posts: 25
Location: Cambridge, MA

PostPosted: Wed Mar 05, 2008 7:22 pm    Post subject: Reply with quote

Hi guys, I recently had this issue when I installed a brlcad ebuild from an overlay without having collision-protect, sandbox, etc enabled in my portage FEATURES.

I have been able to fully recover from this mess by writing a python script to fix my libtool archives (ie *.la files in /usr/lib64) and using revdep-rebuild (no emerge -e world but still a lot of packages from revdep unfortunately)

I originally posted to bugs about a gcc issue (gcc fails with: /usr/lib64/librt.so: wrong file format) which ended up being caused by the combination of the brlcad overlay ebuild and lack of collision-protect/sandbox. The bug report can be found here:

sys-devel/gcc-4.2.0 compile fails 32bit multilib on amd64

In the bug report I give a brief description of the problem and how I went about fixing it. As I mention at the end of the bug, I'll be blogging soon about the full process of fixing this issue for those that may need it. My blog is at:

http://www.gentoojedi.com/blog/jtriley

~jtriley
Back to top
View user's profile Send private message
blossa
Apprentice
Apprentice


Joined: 13 Jan 2005
Posts: 169

PostPosted: Fri Jun 27, 2008 8:45 am    Post subject: Reply with quote

I have been away for a while... Any updates about this issue?

Thanks in advance!
/ Anders
_________________
QX9650, P5E64WS Pro, 4x1GB
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum