Date: Thu, 1 Oct 1998 21:38:46 -0700 (PDT) From: hjl@lucon.org (H.J. Lu) To: devel@XFree86.Org Cc: kaleb@ics.com, hackers@FreeBSD.ORG Subject: Re: ELF shared library "revision" numbers Message-ID: <m0zOwzP-000395C@ocean.lucon.org> In-Reply-To: <Pine.BSI.3.95.981001104117.6970C-100000@fish.hooked.net> from "Alex" at Oct 1, 98 10:50:44 am
next in thread | previous in thread | raw e-mail | index | archive | help
> > > > > The definition of "incompatible" that FreeBSD has chosen > > > includes adding new functions while keeping all the previous interfaces > > > unchanged. > > > > Ugh. That's bad. That's going to force people to keep old libraries > > around for old programs, and /usr/lib is going to suffer from bloat. > > Either that or it's going to force people to go manually dink their > > /usr/lib to create symlinks if they want to get rid of old libraries. > > (Yeah, yeah, disk is cheap.) > > It's _good_. It would force people to link statically if they're horribly > desperate, or perhaps just relink. Yes, it's true Linux added new > functions to its libc5 without bumping the major number. Let me tell you, > when you've got a populace that's so full of clueless idiots, doing > something like that is a bad idea. Ever try and run programs linked with > libc.so.5.44 on a libc.so.5.12 system? It's not fun, but something like > that _should_ work. When you introduce binary or source incompatablity, > it's time to change the major number. No. The binary compatibility is backward, not forward. It is true bewteen glibc 2.0 and glibc 2.1. And it is the case for Solaris 2.5.1 and 2.6. That is one reason why we, the company I work for, have to compile our Solaris binaries on Solaris 2.5.1 machines. > > > Bumping the SONAME/version when you add APIs doesn't buy you anything. > > It buys you sanity. Unless you want to explain why a libc.so.3 from the > 12th won't work with programs linked with a libc.so.3 from the 13th. > That is why SONAME and filename should be different. On glibc 2.0 machine, # cd /lib # ls -l -rwxr-xr-x 1 root root 2493455 Sep 2 14:44 libc-2.0.7.so lrwxrwxrwx 1 root root 13 Sep 2 18:50 libc.so.6 -> libc-2.0.7.so On glibc 2.1, # cd /lib # ls -l -rwxr-xr-x 1 root root 3876819 Sep 11 10:01 libc-2.0.96.so lrwxrwxrwx 1 root root 14 Sep 11 08:25 libc.so.6 -> libc-2.0.96.so We change the version number. But we don't change the SONAME. It is up to developer to make sure the right library is used to link binaries. That is why the glibc 2.0 binaries I distributed are always compiled in glibc 2.0 machines. -- H.J. Lu (hjl@gnu.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?m0zOwzP-000395C>