From owner-freebsd-current@FreeBSD.ORG Tue Dec 6 21:41:38 2011 Return-Path: Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 92B121065670; Tue, 6 Dec 2011 21:41:38 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 79BF78FC13; Tue, 6 Dec 2011 21:41:37 +0000 (UTC) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id XAA10577; Tue, 06 Dec 2011 23:41:36 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1RY2lb-000OY6-Pe; Tue, 06 Dec 2011 23:41:35 +0200 Message-ID: <4EDE8C0E.7050806@FreeBSD.org> Date: Tue, 06 Dec 2011 23:41:34 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:8.0) Gecko/20111108 Thunderbird/8.0 MIME-Version: 1.0 To: Martin Matuska References: <4EDE474C.8090600@FreeBSD.org> <4EDE8816.7030505@FreeBSD.org> In-Reply-To: <4EDE8816.7030505@FreeBSD.org> X-Enigmail-Version: undefined Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: FreeBSD current , FreeBSD Ports Subject: Re: binutils-2.22: ld and --copy-dt-needed-entries X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Dec 2011 21:41:38 -0000 on 06/12/2011 23:24 Martin Matuska said the following: > On 6.12.2011 17:48, Andriy Gapon wrote: >> Just for your information. >> It seems that ld from binutils-2.22 by default has --no-copy-dt-needed-entries >> behavior, and so explicit --copy-dt-needed-entries is now needed where the >> previous default behavior is relied upon. >> >> A short excerpt from the man page for your convenience: >> >>> This option also has an effect on the resolution of symbols in >>> dynamic libraries. With --copy-dt-needed-entries dynamic libraries >>> mentioned on the command line will be recursively searched, >>> following their DT_NEEDED tags to other libraries, in order to >>> resolve symbols required by the output binary. With the default >>> setting however the searching of dynamic libraries that follow it >>> will stop with the dynamic library itself. No DT_NEEDED links will >>> be traversed to resolve symbols. > What do we do with this? > We can go back, patch to behave as before or to continue. > Are there any serious complaints? I am not sure. Eventually all upstreams of our ports will have to deal with this. So far I've encountered only one problematic port (gegl) that links a binary with -lglib-2.0 expecting that a required -liconv dependency would be automatically picked up via DT_NEEDED. libglib-2.0.so indeed has a DT_NEEDED entry for libiconv.so. But this dependency is not explicitly advertised via pkg-config metadata: $ fgrep -i Libs /usr/local/libdata/pkgconfig/glib-2.0.pc Libs: -L${libdir} -lglib-2.0 Libs.private: -liconv So there could be other issues related to this in the future. Perhaps this is actually an issue with glib, maybe it should have -liconv in Libs. I am not really knowledgeable about his stuff. -- Andriy Gapon