public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jakub Jelinek <jakub@redhat.com>
To: Pierre-Marie de Rodat <derodat@adacore.com>
Cc: gcc-patches@gcc.gnu.org, Arnaud Charlet <charlet@adacore.com>
Subject: Re: [Ada] Use runtime from base compiler during stage1
Date: Wed, 16 Jun 2021 01:18:45 +0200	[thread overview]
Message-ID: <20210615231845.GV7746@tucnak> (raw)
In-Reply-To: <20210615102052.GA3883@adacore.com>

On Tue, Jun 15, 2021 at 06:20:52AM -0400, Pierre-Marie de Rodat wrote:
> When performing a bootstrap with Ada, we are currently using the runtime
> files from the repository during stage1, causing some subtle
> inconsistencies during stage1 of the bootstrap, sometimes hard to
> workaround. This change now uses the runtime from the base compiler
> during stage1 only. We still rely on a few more recent runtime services,
> so we have to copy some files from libgnat to <object dir>/gcc/ada in
> the process.
> 
> Tested on x86_64-pc-linux-gnu, committed on trunk
> 
> gcc/ada/
> 
> 	* Make-generated.in: Add rule to copy runtime files needed
> 	during stage1.
> 	* raise.c: Remove obsolete symbols used during bootstrap.
> 	* gcc-interface/Make-lang.in: Do not use libgnat sources during
> 	stage1.
> 	(GNAT_ADA_OBJS, GNATBIND_OBJS): Split in two parts, the common
> 	part and the part only used outside of stage1.
> 	(ADA_GENERATED_FILES): Add runtime files needed during bootstrap
> 	when recent APIs are needed.
> 	(ada/b_gnatb.adb): Remove prerequisite.
> 	* gcc-interface/system.ads: Remove obsolete entries.

This breaks bootstrap on Fedora, where usually only libgnat.so* and not
libgnat.a is installed (one needs to install libgnat-static for it to be
present).
Shouldn't it instead just add
-L $(dir $(shell $(CC) -print-libgcc-file-name))adalib/ -lgnat
instead of forcing to always link against libgnat.a?
Or at least test whether libgnat.a is present and otherwise use the above.

	Jakub


  reply	other threads:[~2021-06-15 23:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-15 10:20 Pierre-Marie de Rodat
2021-06-15 23:18 ` Jakub Jelinek [this message]
2021-06-16  6:23   ` Arnaud Charlet

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=20210615231845.GV7746@tucnak \
    --to=jakub@redhat.com \
    --cc=charlet@adacore.com \
    --cc=derodat@adacore.com \
    --cc=gcc-patches@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).