libtool
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Better soname linking


From: Jan Engelhardt
Subject: Re: Better soname linking
Date: Sun, 1 Nov 2009 13:23:19 +0100 (CET)
User-agent: Alpine 2.00 (LSU 1167 2008-08-23)

On Sunday 2009-11-01 09:46, Ralf Wildenhues wrote:
>> 
>> -version-info 23:0:1 will create a libfoo.so.22.1.0 and there is a
>> symlink libfoo.so.22 to it, so that programs originally linked for
>> v22 continue to work with a v23 that implements APIs 22–23.
>> 

>Wow.  This would be a heavy change. [...]
>Can't we use some other method to make it obvious to the distributor
>that libfoo has gone from 22.0.0 to 22.1.0?

Well the problem is really independent of any of the per-distro package
mechanisms:

>> However, a program that uses functions from API 23 is still linked
>> against libfoo.so.22.

So it seems logical to start tackling it there. Linking new programs
against so.22.1 makes no sense, since so.22.1 could go away when
so.22.2 is installed. In contrast, the so.22 and so.23 will always be
there with this patch, which should retain the desired compatibility.

>and effectively an ABI flag day, that I am very [careful] to go this
>way unless there is really no other way; and even then only with very
>good preparation and lots of positive feedback from distributions.

Do you have any alternate proposals given the independence?

>  Basically any change that causes
>different sonames on a widely used platforms will cause so much churn
>downstream,

 - The build tools: "SONAME changed from .so.22 to .so.23, please rename
   package from libfoo22 to libfoo23". No big deal.

 - Subsequently, users doing an update with their package manager should
   be seeing:
   The following new packages will be installed: libfoo23
   Packages that are going to be removed: libfoo22

So far so fine, but it seems rpm is one of the candidates that need
some more thinking, as it only inspect DT_SONAME.

# rpm -Uhv libltdl7-2.2.6-1.47.i586m pm
error: Failed dependencies:
        libltdl.so.7 is needed by (installed) opensc-0.11.6-5.2.1.i586
        libltdl.so.7 is needed by (installed) ImageMagick-6.4.3.6-5.5.1.i586
        [...]

# rpm -qlvp libltdl7-2.2.6-1.47.i586.rpm 
lrwxrwxrwx     16 Nov  1 13:10 /usr/lib/libltdl.so.7 -> libltdl.so.7.2.0
-rwxr-xr-x  38612 Nov  1 13:10 /usr/lib/libltdl.so.7.2.0 [soname=libltdl.so.9]
lrwxrwxrwx     16 Nov  1 13:10 /usr/lib/libltdl.so.8 -> libltdl.so.7.2.0
lrwxrwxrwx     16 Nov  1 13:10 /usr/lib/libltdl.so.9 -> libltdl.so.7.2.0

>checkers are common in distributions, it should be possible to amend
>them for this kind of issue, even if they need to look at the .la file
>for such a thing.

.la files are often removed because they would needlessy pull in
secondary dependencies (which has seen some discussion here on libtool
previously, but I seem to remember that being unresolved still).




reply via email to

[Prev in Thread] Current Thread [Next in Thread]