public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "christoph.hoeger at celeraone dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug bootstrap/101245] New: Bootstrap fails for a combined tree with --enable-shared
Date: Mon, 28 Jun 2021 19:10:35 +0000	[thread overview]
Message-ID: <bug-101245-4@http.gcc.gnu.org/bugzilla/> (raw)

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101245

            Bug ID: 101245
           Summary: Bootstrap fails for a combined tree with
                    --enable-shared
           Product: gcc
           Version: 11.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: bootstrap
          Assignee: unassigned at gcc dot gnu.org
          Reporter: christoph.hoeger at celeraone dot com
  Target Milestone: ---

Created attachment 51075
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51075&action=edit
Reproduction build script

I tried to bootstrap gcc 11.1.0 with binutils 2.36.1 in a combined tree and the
build fails in stage2 when building libiberty.

The failure stems from as not finding its shared libraries (opcode and bfd).
The RPATH is set wrong:

➜  test2 readelf -d build/prev-gas/.libs/lt-as-new | grep RPATH
 0x000000000000000f (RPATH)              Library rpath:
[/home/choeger/c1/scratch/gcc-combined/test2/build/opcodes/.libs:/home/choeger/c1/scratch/gcc-combined/test2/build/bfd/.libs:/usr/local/lib]
➜  test2

As you can see, the RPATH is not reset to the prev- directories.

➜  test2 build/prev-gas/as-new 
/home/choeger/c1/scratch/gcc-combined/test2/build/prev-gas/.libs/lt-as-new:
error while loading shared libraries: libopcodes-2.36.1.so: cannot open shared
object file: No such file or directory

Find attached a script to reproduce the issue.

                 reply	other threads:[~2021-06-28 19:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-101245-4@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).