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

Re: Stupid library ABI question



Hi Kevin,

On Mon, Jan 08, 2007 at 11:19:40AM -0800, Kevin B. McCarty wrote:
> I have a dumb library ABI question.  Suppose I maintain a library
> libfoo.so that has public functions A(), B() and C().  Now there is a
> new release in which libfoo.so only provides A(), but it is now (newly)
> dynamically linked against libbar.so, which has public functions B() and
> C() with interfaces identical to the old B() and C() in the old version
> of libfoo.so.

> Does libfoo.so need to have its soname bumped, since it no longer
> provides B() and C()?  Or can it keep the same soname since it still
> indirectly provides B() and C() via its new dependency on libbar.so?

No need to change the soname, because B() and C() are still part of the ABI
exported by libfoo.so except in certain corner cases involving dlopen()ing
libfoo directly.  In fact, an X library made such a change in the not so
distant past, and no one noticed except the LSB folks, who were using
dlopen() to try to check the ABI...

-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
vorlon@debian.org                                   http://www.debian.org/



Reply to: