distros that don't set library links (ie .so -> .so.1.2.3) - Setup

This is a discussion on distros that don't set library links (ie .so -> .so.1.2.3) - Setup ; Hello knowledgable folks, I've got a basic question about shared libraries on Linux: Shouldn't there always be a link from .so pointing to the particular version installed/used? For example, I recall Mandrake linux a few years ago shipped 9.x without ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: distros that don't set library links (ie .so -> .so.1.2.3)

  1. distros that don't set library links (ie .so -> .so.1.2.3)

    Hello knowledgable folks,

    I've got a basic question about shared libraries on Linux: Shouldn't
    there always be a link from .so pointing to the particular version
    installed/used? For example, I recall Mandrake linux a few years ago
    shipped 9.x without such links, and nothing compiled until you
    manually went through and created the links, or wrote a program/script
    to do it.

    Now am having the same problem on Suse linux. Half the libs are so.1
    etc, ie specific version only, without the link from .so -> .so.1.2.3,
    for example. Is this considered a bug, or what?

    Am working on a system that don't have root priveleges on, so normally
    the solution would be to make the links in my $HOME and set
    LD_LIBRARY_PATH to include the directory where those links exists, but
    the installers I'm working with switch shells and what-not so that the
    env variable is lost.

    But my basic question is: Shouldn't distros create those links during
    installation?

    Thanks
    Charles

  2. Re: distros that don't set library links (ie .so -> .so.1.2.3)

    On 2008-09-12, charlie wrote:
    > I've got a basic question about shared libraries on Linux: Shouldn't
    > there always be a link from .so pointing to the particular version
    > installed/used?


    Not always.

    > For example, I recall Mandrake linux a few years ago
    > shipped 9.x without such links, and nothing compiled until you
    > manually went through and created the links, or wrote a program/script
    > to do it.
    >
    > Now am having the same problem on Suse linux. Half the libs are so.1
    > etc, i.e. specific version only, without the link from .so -> .so.1.2.3,
    > for example.


    The libblah.so link is there merely for building programs.

    The resulting program does not know about anything called "libblah.so" (*).
    Instead, it knows to look for a library with the appropriate "soname",
    which typically has the form "libblah.so.1". The soname link libblah.so.1
    -> libblah.so.1.0.0.0.1 is _required_ at runtime.

    $ strings /bin/bash | grep ncurses
    libncurses.so.5
    $ objdump -x /usr/lib/libncurses.so | grep SONAME
    SONAME libncurses.so.5

    (*--Unless the library has the degenerate soname "libblah.so".)

    > But my basic question is: Shouldn't distros create those links during
    > installation?


    During installation of the runtime-only component of the library, no.
    During installation of the development component, yes.

    --
    Paul Kimoto
    This message was originally posted on Usenet in plain text. Any images,
    hyperlinks, or the like shown here have been added without my consent,
    and may be a violation of international copyright law.

+ Reply to Thread