[PATCH] nptl: proper soname handling

Michael Deutschmann michael at talamasca.ocis.net
Thu Apr 22 10:10:41 UTC 2010


On Thu, 22 Apr 2010, Natanael Copa wrote:
> Do you have any better suggestions how to upgrade a running system?

First, build the new uClibc, but don't install it yet.

Build a customized ld-uclibc.so.0, from the previous uClibc source, that
looks in a different place for shared libraries and ignores the
/etc/ld.so.* files.  Install it under a different filename.

Write a utility to modify the INTERP filename specified in an executable
from "/lib/ld-uclibc.so.0" to the filename of the special ld.so.  (This is
much simpler if the temporary ld.so filename is the same length as the
original.)

Hardlink the existing shared libraries into the alternate position, then
hack every existing installed executable in this way.

Then, delete all the old libraries in /usr/lib and the include files. The
shared libraries will be preserved by the hardlink, while everything else
is dispensible.  The system should still work for everything except
compilation.

Now, install the new uClibc.  Unless the ABI is so thoroughly broken as
to invalidate the old specs or libgcc.a, you should now be able to compile
new binaries.

I intend to do something like this for my 0.9.30.3 to 0.9.31 rollover,
but I haven't finished writing the necessary utilities yet.

---- Michael Deutschmann <michael at talamasca.ocis.net>


More information about the uClibc mailing list