From: Alan Modra <amodra@gmail.com>
To: Simon Marchi <simon.marchi@polymtl.ca>
Cc: Jeff Law <jeffreyalaw@gmail.com>, Nick Clifton <nickc@redhat.com>,
gcc-patches@gcc.gnu.org, gdb-patches@sourceware.org,
Binutils <binutils@sourceware.org>
Subject: Re: RFC: Changing AC_PROG_CC to AC_PROG_CC_C99 in top level configure
Date: Tue, 4 May 2021 07:21:49 +0930 [thread overview]
Message-ID: <20210503215149.GI22624@bubble.grove.modra.org> (raw)
In-Reply-To: <e9af4380-4c97-798e-f151-174e098e0065@polymtl.ca>
On Mon, May 03, 2021 at 10:47:15AM -0400, Simon Marchi wrote:
> > Yes, I prefer the configure fix too. If we state we require C99 in
> > binutils then we ought to be able to use C99..
> >
> > Nick, does the configure.ac change also need to go in all subdirs, to
> > support people running make in say ld/ rather than running make in the
> > top build dir?
>
> For GDB, it's not supported to run gdb/configure directly, you need to
> use the top-level configure. Is it supported from some of the other
> projects in the repo?
>
> I just tried with ld, it doesn't work since it depends on bfd also being
> built. I tried with just bfd, it doesn't work (with the default
> configure options at least) because it requires zlib being built.
I wasn't talking about running configure, I was talking about running
make. For example, you configure and make binutils as usual, then
after making a change to ld/ files, run make in the ld build dir. I
don't tend to do that myself but I do run "make check" sometimes in a
subdir expecting to get the same results in that subdir as if "make
check" was run from the top level.
But I should have just tried it myself rather than asking. CC, CPP
and others are inherited from the top level and appear with -std=gnu99
in the subdir Makefiles. So it seems all the AC_PROG_CC in subdir
configure.ac can stay as they are.
>
> So if all projects need to go through the top-level configure script
> anyway, and C99 is a baseline for all projects, then having the check
> only in the top-level makes sense to me. Projects that have more
> specific requirements can have their own checks. For example, sim/
> requires C11 now. Unless the C99 check at top-level somehow does not
> play well with the C11 check in sim/? Like if that would cause CC to be
> set to "gcc -std=gnu99 -std=gnu11" or something like that.
>
> Simon
--
Alan Modra
Australia Development Lab, IBM
next prev parent reply other threads:[~2021-05-03 21:51 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-26 11:32 Nick Clifton
2021-04-26 19:32 ` Joseph Myers
2021-04-26 20:05 ` Mike Frysinger
2021-04-26 21:31 ` Christian Biesinger
2021-04-27 10:49 ` Nick Clifton
2021-04-27 16:58 ` Joseph Myers
2021-04-30 18:36 ` Simon Marchi
2021-04-30 21:48 ` Jeff Law
2021-05-03 6:28 ` Alan Modra
2021-05-03 14:47 ` Simon Marchi
2021-05-03 16:26 ` Tom Tromey
2021-05-03 21:51 ` Alan Modra [this message]
2021-05-03 23:30 ` Simon Marchi
2021-05-04 12:42 ` Nick Clifton
2021-05-04 15:16 ` Simon Marchi
2021-05-05 0:18 ` Alan Modra
2021-05-05 7:05 ` Iain Sandoe
2021-05-05 7:20 ` Alan Modra
2021-05-05 7:23 ` Iain Sandoe
2021-05-10 8:49 ` Iain Sandoe
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=20210503215149.GI22624@bubble.grove.modra.org \
--to=amodra@gmail.com \
--cc=binutils@sourceware.org \
--cc=gcc-patches@gcc.gnu.org \
--cc=gdb-patches@sourceware.org \
--cc=jeffreyalaw@gmail.com \
--cc=nickc@redhat.com \
--cc=simon.marchi@polymtl.ca \
/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).