From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32341 invoked by alias); 27 Oct 2010 12:02:43 -0000 Received: (qmail 32331 invoked by uid 22791); 27 Oct 2010 12:02:42 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,MISSING_MID X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 27 Oct 2010 12:02:38 +0000 From: "joseph at codesourcery dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/46191] [4.5/4.6 regression] Non-absolute names in libgcc_s.so X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: joseph at codesourcery dot com X-Bugzilla-Status: WAITING X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Wed, 27 Oct 2010 12:02:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-10/txt/msg02292.txt.bz2 Message-ID: <20101027120200.JonPxciBx3cGZBlAdR5Z5LvSbCToUbltcZ76ggFFbH0@z> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46191 --- Comment #5 from joseph at codesourcery dot com 2010-10-27 12:02:35 UTC --- On Wed, 27 Oct 2010, jakub at gcc dot gnu.org wrote: > Using absolute names is undesirable too, because then gcc is not actually > relocatable. Guess we want something like $ORIGIN relative path if $ORIGIN or > something similar expands to the directory the linker script was found in. Absolute paths work in linker scripts in sysrooted compilers, in that they are interpreted relative to the (relocatable) sysroot for a linker script (typically libc.so) found in the sysroot. But GCC itself never installs anything in a sysroot, meaning that if you put a linker script there (after GCC's own installation) you also need to update paths in it accordingly - and so to have a relative path from the sysroot to libgcc.a outside the sysroot. Perhaps what's actually wanted is a way to have the linker search for libgcc.a in its normal search path (the compiler should have passed -L options that include the libgcc.a installation directory) rather than in "."?