Clang Import Breakage

Konstantin Belousov kostikbel at gmail.com
Sun Mar 24 09:14:35 UTC 2019


On Sun, Mar 24, 2019 at 07:03:11AM +0100, Jan Beich wrote:
> Sean Bruno <sbruno at freebsd.org> writes:
> 
> > On 3/23/19 5:57 PM, Dimitry Andric wrote:
> >> This is fallout of <https://svnweb.freebsd.org/changeset/base/345349>,
> >> which enabled --no-allow-shlib-undefined by default.  See also
> >> <https://bugs.freebsd.org/236141>.  Executive summary: lots of programs
> >> do not specify all their required libraries, a.k.a. "under-linking".
> >> 
> >> I haven't yet reverted lld's new default, since it seems that a lot of
> >> under-linking fixes are now being made.  These problems will also occur
> >> when linking with gold, for instance, so it is quite useful to solve
> >> them once and for all.
> >> 
> >> -Dimitry
> >
> > Oh, hrm.  Ok.
> >
> > So, before the changes, my port succeeds in adding libogg to its LD list
> > when doing its link.
> 
> LLD before and BFD linker didn't complain that your port bootlegged
> libogg via libvorbis. For one, libvorbis may stop depending on libogg,
> may bundle libogg as a static library or import libogg symbols with
> LOCAL visibility.
But in this case, you get the breakage even with the ld.bfd, and if
you get over the static linking stage, with runtime linker as well.
This is exactly the issue that disabling of underlinking uncovers:
if you use a symbol provided by a library, the library must appear in
DT_NEEDED.

> 
> Ditto for libssl bootlegging libcrypto.
> _______________________________________________
> freebsd-ports at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-ports
> To unsubscribe, send any mail to "freebsd-ports-unsubscribe at freebsd.org"


More information about the freebsd-ports mailing list