public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "gjl at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/108287] AVR build: gcc/config/avr/t-avr tries to edit the source tree
Date: Sat, 21 Jan 2023 12:33:19 +0000	[thread overview]
Message-ID: <bug-108287-4-28kNnxSG80@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-108287-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #4 from Georg-Johann Lay <gjl at gcc dot gnu.org> ---
Well, updating or creating some auto-generated files is intentional.

What's not supported as of GCC documentation is configure'ing in the source
tree:

https://gcc.gnu.org/install/configure.html

> First, we **highly** recommend that GCC be built into a separate directory
> from the sources which does not reside within the source tree.
> This is how we generally build GCC; building where srcdir == objdir
> should still work, but doesn’t get extensive testing; building where
> objdir is a subdirectory of srcdir is unsupported.

The reason why it does not work for you might be:

1) Maybe you changed avr-mcus.def to support more devices. This change will
trigger more changes, for example to auto-generated documentation (texi) bits. 
This means you are basically a maintainer, which in turn means you migth have
more jobs to do, or tools to use than a simple user who just builds GCC from
source.

2) When you get the sources from some repo like git, the checked-out sources
might have timestamps that don't reflect their true state. This triggers make
to re-build auto-generated files, even though no prerequisite was changed and
the targets need not be rebuilt.

To fix this, run
  ./contrib/gcc_update --touch
from the top-level source dir.  This script will touch some source files and
fix their timestamps.  You obviously need write permission for that.

  parent reply	other threads:[~2023-01-21 12:33 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-04 18:02 [Bug other/108287] New: " nicow.mattia at gmail dot com
2023-01-04 18:08 ` [Bug target/108287] " pinskia at gcc dot gnu.org
2023-01-04 18:08 ` pinskia at gcc dot gnu.org
2023-01-04 18:11 ` nicow.mattia at gmail dot com
2023-01-21 12:33 ` gjl at gcc dot gnu.org [this message]
2023-01-21 12:34 ` gjl at gcc dot gnu.org

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-108287-4-28kNnxSG80@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).