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

Re: libtool, c++ and SO_names



Randolph Chung <tausq@debian.org> writes:

>> What would happen if I change my c++-compiler but upstream doesn't?
>> Would that mean that SO-names would be out of sync?
>> Is everything easy and changing SO-names is really only needed for
>> interface changes?
>> If so, what does one have to consider?
> 
> There really are two parts to this question:
> 
> Interface changes (changes in any C++ methods, including type changes)
> need to be reflected by a change in the soname. This should be handled
> by upstream and maintained by the Debian maintainer. We should not have
> different sonames than upstream. This will result in a change of the
> Debian version, and either you need to change the package name (e.g.
> libfoo0, libfoo1, etc) or you need to use versioned dependencies with
> correct shlib files.
> 
> Compiler differences should (imo) be handled by Debian via "Depends". 
> All c++ shared libraries in a given distribution (potato,
> woody, etc) on a given platform are compiled with the same c++ library
> (whatever is specified via gcc-defaults on that platform), so there is
> usually no issues as long as you Depend on the right version of
> libstdc++. [1]

Certain compiler changes change the interface, and those changes must
be reflected in the soname too.  sonames identify interfaces at the
binary level, not the source level.

Ideally upstream gets this right, otherwise there is a risk of binary
incompatibility across Linux distributions.

-- 
http://www.greenend.org.uk/rjk/



Reply to: