Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[solved] udev-200 and libudev.so.0
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
AgBr
Apprentice
Apprentice


Joined: 06 Nov 2010
Posts: 195

PostPosted: Wed Apr 24, 2013 1:35 pm    Post subject: [solved] udev-200 and libudev.so.0 Reply with quote

On my client-box, getting binary-installs of firefox and libreoffice from my build-server, both programs are failing to run due to a missing libudev.so.0
My inquiries led to the following insights so far:

Code:

build-server / # equery belongs /lib/libudev.so.0
 * Searching for /lib/libudev.so.0 ...
sys-fs/udev-200 (/lib/libudev.so.0)


build-server / # equery files sys-fs/udev
 * Searching for udev in sys-fs ...
 * Contents of sys-fs/udev-200:
/bin
/bin/udevadm
/etc
/etc/udev
/etc/udev/hwdb.d
/etc/udev/rules.d
/etc/udev/rules.d/80-net-name-slot.rules
/etc/udev/rules.d/99-allow-user-access.rules
/etc/udev/udev.conf
/lib
/lib/libudev.so.0
/lib/libudev.so.1 -> libudev.so.1.3.1
[...]

build-server / # tar jtvf /usr/portage/packages/sys-fs/udev-200.tbz2
drwxr-xr-x root/root         0 2013-04-09 05:09 ./
drwxr-xr-x root/root         0 2013-04-09 05:09 ./lib/
lrwxrwxrwx root/root         0 2013-04-09 05:09 ./lib/libudev.so.1 -> libudev.so.1.3.1
-rwxr-xr-x root/root     79180 2013-04-09 05:09 ./lib/libudev.so.1.3.1
[...]


So as can be seen. libudev.so.0 gets installed on the build-server but not packaged into the tarball. Consequently on my Client:
Code:

client / # ls -l /lib/libudev.so*
lrwxrwxrwx 1 root root    16 18. Apr 12:07 /lib/libudev.so.1 -> libudev.so.1.3.1
-rwxr-xr-x 1 root root 79180  9. Apr 05:09 /lib/libudev.so.1.3.1
client / # ls -l /usr/lib/libudev.so*
lrwxrwxrwx 1 root root 26 18. Apr 12:07 /usr/lib/libudev.so -> ../../lib/libudev.so.1.3.1
is11-05-wlan / #


the library is missing.

If I link libudev.so.0 in /usr/lib and /lib to /lib/libudev.so.1.3.1 all is running fine. Probably there are some more packages affected, I don't know actally.
What is going on here?


Last edited by AgBr on Wed Apr 24, 2013 6:38 pm; edited 1 time in total
Back to top
View user's profile Send private message
miket
Guru
Guru


Joined: 28 Apr 2007
Posts: 378
Location: Gainesville, FL, USA

PostPosted: Wed Apr 24, 2013 2:30 pm    Post subject: Re: udev-200 and libudev.so.0 Reply with quote

AgBr wrote:
On my client-box, getting binary-installs of firefox and libreoffice from my build-server, both programs are failing to run due to a missing libudev.so.0

It looks like revdep-rebuild time. When you update libraries such that they get new sonames, you have to rebuild all the packages that depend on them. Have you run revdep-rebuild on the build server? That should make it so that all the packages that depend on udev resolve correctly.

Then, inless you're not using Portage to install your binary packages onto your client machine, you need to run revdep-rebuild on that one too. You won't be (or shouldn't be) incurring the overhead of actually rebuilding the packages when you do that, but you will straighten out the dependency situation. You have to do that second revdep-rebuild: packages include only their own code, never the external libraries on which they depend.

Funny that you would be running into this with udev. I've had plenty to say in other threads about that particular transition, but the library-update problem is true for all dependencies. It sounds like you sailed through the udev update unscathed: be glad you've got a simple setup.
Back to top
View user's profile Send private message
AgBr
Apprentice
Apprentice


Joined: 06 Nov 2010
Posts: 195

PostPosted: Wed Apr 24, 2013 2:59 pm    Post subject: Re: udev-200 and libudev.so.0 Reply with quote

miket wrote:
AgBr wrote:
On my client-box, getting binary-installs of firefox and libreoffice from my build-server, both programs are failing to run due to a missing libudev.so.0

It looks like revdep-rebuild time. When you update libraries such that they get new sonames, you have to rebuild all the packages that depend on them. Have you run revdep-rebuild on the build server? That should make it so that all the packages that depend on udev resolve correctly.

Then, inless you're not using Portage to install your binary packages onto your client machine, you need to run revdep-rebuild on that one too. You won't be (or shouldn't be) incurring the overhead of actually rebuilding the packages when you do that, but you will straighten out the dependency situation. You have to do that second revdep-rebuild: packages include only their own code, never the external libraries on which they depend.

Funny that you would be running into this with udev. I've had plenty to say in other threads about that particular transition, but the library-update problem is true for all dependencies. It sounds like you sailed through the udev update unscathed: be glad you've got a simple setup.


On the build-server a revdep-rebuild after an update world is obligatory. I even have emerge -C 'd the ebuilds in question and reinstalled them. I did not run a revdep-rebuild on the client though. It's not even installed there as the client-boxes get installed purely from binaries. In fact I am creating sort of a binary-distribution on the build-server.
As libudev.so.0 is part of udev-200, from the ebuilds point of view all is well. So as far as I can understand, revdep-rebuild would not so any need for action. Only libudev.so.0, that is part of the ebuild udev-200, is missing in the tarball.
What is strange too is, that libudev.so.0 is a binary, not a link to libudev.so.1.3.1 and creating a link solves the problem seemingly.
Back to top
View user's profile Send private message
Gusar
Advocate
Advocate


Joined: 09 Apr 2005
Posts: 2655
Location: Slovenia

PostPosted: Wed Apr 24, 2013 4:19 pm    Post subject: Re: udev-200 and libudev.so.0 Reply with quote

AgBr wrote:
As libudev.so.0 is part of udev-200

No it isn't. Udev since 183 has libudev.so.1, earlier versions had libudev.so.0

AgBr wrote:
What is strange too is, that libudev.so.0 is a binary not a link to libudev.so.1.3.1

Why would so.0 be a symlink to so.1 ??

And it's a binary because portage's library preserving feature created it. You're supposed to delete it after running revdep-rebuild. That's the instruction portage gives - run revdep-rebuild, then delete the old preserved library - but of course no one reads portage's output...

AgBr wrote:
and creating a link solves the problem seemingly.

That's the craziest hack one can do. Libraries have sonames for a reason. Doing such symlinks is just asking for breakage down the road. Instead of such hacks, properly rebuild all your software so it'll link to libudev.so.1, then delete libudev.so.0
Back to top
View user's profile Send private message
AgBr
Apprentice
Apprentice


Joined: 06 Nov 2010
Posts: 195

PostPosted: Wed Apr 24, 2013 6:38 pm    Post subject: Re: udev-200 and libudev.so.0 Reply with quote

Gusar wrote:
AgBr wrote:
As libudev.so.0 is part of udev-200

No it isn't. Udev since 183 has libudev.so.1, earlier versions had libudev.so.0

AgBr wrote:
What is strange too is, that libudev.so.0 is a binary not a link to libudev.so.1.3.1

Why would so.0 be a symlink to so.1 ??

And it's a binary because portage's library preserving feature created it. You're supposed to delete it after running revdep-rebuild. That's the instruction portage gives - run revdep-rebuild, then delete the old preserved library - but of course no one reads portage's output...

AgBr wrote:
and creating a link solves the problem seemingly.

That's the craziest hack one can do. Libraries have sonames for a reason. Doing such symlinks is just asking for breakage down the road. Instead of such hacks, properly rebuild all your software so it'll link to libudev.so.1, then delete libudev.so.0

Of cause it is. I just tried to find out what happened. And in fact I didn't read the instructions :oops: I had expected that emerge would have removed the library or at least orphaned it, that it belonged to udev-200 irritated me. The whole build process on my system is script driven and revdep-rebuild is called automatically. I hadn't expected that there would be the need to remove a file manually between update world and revdep-rebuild. So thanks for your hint.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming 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