|
From: | Bob Friesenhahn |
Subject: | Re: transitive shared library dependencies and installation |
Date: | Sun, 5 Jan 2020 15:21:37 -0600 (CST) |
User-agent: | Alpine 2.20 (GSO 67 2015-01-07) |
On Sun, 5 Jan 2020, address@hidden wrote:
On the other hand, this overlinks the final binary: $ objdump -p .libs/translib | fgrep NEEDED NEEDED liba.so NEEDED libb.so NEEDED libc.so.6 libb.so is unneeded here (but is present in the installed program as well). Coincidentally, the most prominent search result https://wiki.mageia.org/en/Overlinking_issues_in_packaging mentions that "this is fixed using a patch from Debian" for libtool. What's your position on this? Is overlinking a problem or not? (It causes problems for distributions.) Should everybody use --as-needed globally to combat it? Something else entirely?
This has been the most common complaint (in the GNU Linux world) I have heard about libtool. There is a choice of working reliably and portably (with possible over-linking) or relying on implicit library dependencies (which are definitely not portable), or failing as you have encountered. A similar complaint is that libtool uses information in installed ".la" files in order to link with all libraries that the program/library is dependent on. Due to this, GNU Linux distributions often patch out this capability, and they don't distribute ".la" files.
Unfortunately, --as-needed may not be 100% reliable since it only reliably detects direct dependence on library symbols, and not "transitive" dependence.
Bob -- Bob Friesenhahn address@hidden, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/ Public Key, http://www.simplesystems.org/users/bfriesen/public-key.txt
[Prev in Thread] | Current Thread | [Next in Thread] |