From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1MuBOd-0001Ts-5k for garchives@archives.gentoo.org; Sat, 03 Oct 2009 20:40:03 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 1F2CFE0AC5; Sat, 3 Oct 2009 20:40:02 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id EF4D7E0AC5 for ; Sat, 3 Oct 2009 20:40:01 +0000 (UTC) Received: from [192.168.0.101] (dyn-207-11-dsl.vsp.fi [83.146.207.11]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id 0DB8F64DA7 for ; Sat, 3 Oct 2009 20:40:00 +0000 (UTC) Message-ID: <4AC7B6B2.9080404@gentoo.org> Date: Sat, 03 Oct 2009 23:40:18 +0300 From: Samuli Suominen User-Agent: Thunderbird 2.0.0.23 (X11/20090828) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] RFC: LD_AS_NEEDED="1" in profiles/targets/developer/make.defaults? References: <4AC7A277.7040300@gentoo.org> <20091003202929.2a56a1b2@snowcone> <4AC7A79E.2010302@gentoo.org> <20091003201521.GM19056@gentoo.org> <4AC7B3BD.3030903@gentoo.org> <20091003203343.GO19056@gentoo.org> In-Reply-To: <20091003203343.GO19056@gentoo.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Archives-Salt: 840d7df7-b6e7-4e1d-9734-855bafde03e5 X-Archives-Hash: b5277e1b938a669f36e4d1656d2bd542 Fabian Groffen wrote: > On 03-10-2009 23:27:41 +0300, Samuli Suominen wrote: >> The amount of pkgs in tree with valid code that fails with asneeded is >> close to zero. We can use this, >> >> if use userland_GNU; then >> append-ldflags -Wl,--no-as-needed >> fi >> >> logic so it won't cause you troubles. Or the obvious shorter && version >> of it. > > Not really, because the userland is GNU, the compiler too, but the > linker is not. We once played with a version of append-ldflags that > tested the flag against the linker to see if it would work, but that's > expensive as well as allowing real typos/bugs to go unnoticed. > > We currently do either a CHOST check, or call ld to see if it's GNU for > all packages that hardcode -Wl,--{,no-}as-needed usage. > Ah. I wasn't aware of that. Perhaps we could add a new function to the flag-o-matic that does the CHOST check, and appends the flag, so the check code wouldn't have to be duplicated in ebuilds? It should be rather trivial.