SCIENTIFIC-LINUX-USERS Archives

July 2011

SCIENTIFIC-LINUX-USERS@LISTSERV.FNAL.GOV

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Phil Perry <[log in to unmask]>
Reply To:
Phil Perry <[log in to unmask]>
Date:
Fri, 15 Jul 2011 23:20:32 +0100
Content-Type:
text/plain
Parts/Attachments:
text/plain (20 lines)
On 15/07/11 21:59, Mark Stodola wrote:
> If I'm not mistaken, you should not need to manually link libraries.
> ldconfig should be taking care of this for you, so all you would need is
> the %post entry to run ldconfig with the proper flags after
> install/upgrade/removal. Assuming it ends up in a standard path,
> otherwise the ld.so.conf entries are needed as well.
>
> -Mark
>

Correct. Running ldconfig in %post will create the symlinks from the 
SONAME, assuming they are present in the lib. But you must still ensure 
the symlinks are owned by the package otherwise they get left behind 
when the package is removed. A wildcard entry in %files might be all 
that's needed (e.g, %{_libdir}/lib_andrew.so*)

You can query the SONAME with objdump:

objdump -p /usr/lib/lib_andrew.so.1.2.3 | grep SONAME

ATOM RSS1 RSS2