From owner-freebsd-ports@FreeBSD.ORG Tue Feb 21 22:18:57 2012 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A82A3106564A; Tue, 21 Feb 2012 22:18:57 +0000 (UTC) (envelope-from db@db.net) Received: from diana.db.net (diana.db.net [66.113.102.10]) by mx1.freebsd.org (Postfix) with ESMTP id 8C9D78FC0C; Tue, 21 Feb 2012 22:18:57 +0000 (UTC) Received: from night.db.net (localhost [127.0.0.1]) by diana.db.net (Postfix) with ESMTP id 75A222283F; Tue, 21 Feb 2012 15:00:50 -0700 (MST) Received: by night.db.net (Postfix, from userid 1000) id BDA945DB6; Tue, 21 Feb 2012 17:00:53 -0500 (EST) Date: Tue, 21 Feb 2012 17:00:53 -0500 From: Diane Bruce To: Dimitry Andric Message-ID: <20120221220053.GA44386@night.db.net> References: <20120221182850.GA20768@troutmask.apl.washington.edu> <20120221185754.GL55074@deviant.kiev.zoral.com.ua> <20120221194259.GA21185@troutmask.apl.washington.edu> <4F440E8B.9020306@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4F440E8B.9020306@FreeBSD.org> User-Agent: Mutt/1.4.2.3i Cc: Konstantin Belousov , freebsd-current@freebsd.org, freebsd-ports@freebsd.org, Steve Kargl Subject: Re: rtld or lang/gcc cannot find libgcc_s.so.1 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Feb 2012 22:18:57 -0000 On Tue, Feb 21, 2012 at 10:37:15PM +0100, Dimitry Andric wrote: > On 2012-02-21 20:42, Steve Kargl wrote: > ... > > Yes, /lib comes before /usr/local/lib/gcc46. I suppose > > that this is a heads up for gerald@. lang/gcc is used by > > the ports collections to build a large number of other > > ports, so others are likely to hit this issue. Does -rpath not help ? man ld -rpath dir Add a directory to the runtime library search path. This is used when linking an ELF executable with shared objects. All -rpath arguments are concatenated and passed to the runtime linker, which uses them to locate shared objects at runtime. The -rpath option is also used when locating shared objects which are needed by shared objects explicitly included in the link; see the description of the -rpath-link option. If -rpath is not used when linking an ELF executable, the contents of the environment variable "LD_RUN_PATH" will be used if it is defined. Or is this another problem? -rpath is added in /usr/ports/Mk > However, at runtime, it links against the system libstdc++: I ran into this with two of my own ports. -rpath needed to be passed to ld. - Diane -- - db@FreeBSD.org db@db.net http://www.db.net/~db Why leave money to our children if we don't leave them the Earth?