libtool
[Top][All Lists]
Advanced

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

Re: lib*.so symlink


From: Brian May
Subject: Re: lib*.so symlink
Date: 04 Feb 2001 14:21:09 +1100
User-agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Capitol Reef)

>>>>> "Alexandre" == Alexandre Oliva <address@hidden> writes:

I will describe the problem, maybe you could think of a better
solution. ;-)

Current libraries under Debian are made of two sets of packages, for
example:

libx1:
/usr/lib/libx.so.1     (symlink)
/usr/lib/libx.so.1.2.3

libx2:
/usr/lib/libx.so.2     (symlink)
/usr/lib/libx.so.2.2.3

libx-dev:
/usr/lib/libx.so    (symlink)
/usr/lib/libx.la
/usr/include/*

This is fine for the following situation:

    Alexandre> (i) when linking with a libtool library, it determines
    Alexandre> any additional dependencies that have to be linked in.
    Alexandre> You must make sure it corresponds to the actual
    Alexandre> dependencies of the library you're using for linking,
    Alexandre> as well as the one you're going to use at run-time.

However, it is not good for this situation:

    Alexandre> (ii) when dlopening a libtool module, it determines the
    Alexandre> SONAME to be used, as well as the dependencies that may
    Alexandre> have to be dlopened before the library itself.  You
    Alexandre> want it to match the library you're using at run-time.

As users have to install the -dev library even though they aren't
developing/compiling anything.

So the obvious solution is to move libx.la (and possible libx.so) into
libx1 and libx2, but that means libx1 and libx2 both conflict and
cannot be installed at the same time :-(

The benefit of the symlink, is it doesn't have to be included in the
package, but can be created by some script after installing or
removing the library.

Then again, I probably should ask how many libraries need to be
dlopened, it probably isn't many, so creating a separate package
containing only libx.so and libx.la may not be such a big problem.

    Alexandre> In both cases, changing a single link, either the .so
    Alexandre> or the .so.MAJOR, would have been enough, while
    Alexandre> changing the .la file would generally have no effect at
    Alexandre> all.

So just to get matters straight (I am still not quite sure of
this). For situation

i) what linking libx.la, the version pointer to by libx.so is used?

ii) when dlopening libx.la, the version pointed to by libx.so is used?
-- 
Brian May <address@hidden>



reply via email to

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