[Bug target/108287] AVR build: gcc/config/avr/t-avr tries to edit the source tree

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Jan 4 18:08:01 GMT 2023


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

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The best fix is do something similar to aarch64 in config/aarch64/t-aarch64:
$(srcdir)/config/aarch64/aarch64-tune.md: s-aarch64-tune-md; @true
s-aarch64-tune-md: $(srcdir)/config/aarch64/gentune.sh \
        $(srcdir)/config/aarch64/aarch64-cores.def
        $(SHELL) $(srcdir)/config/aarch64/gentune.sh \
                $(srcdir)/config/aarch64/aarch64-cores.def > \
                tmp-aarch64-tune.md
ifneq ($(strip $(ENABLE_MAINTAINER_RULES)),)
        $(SHELL) $(srcdir)/../move-if-change tmp-aarch64-tune.md \
                $(srcdir)/config/aarch64/aarch64-tune.md
else
        @if ! cmp -s tmp-aarch64-tune.md \
          $(srcdir)/config/aarch64/aarch64-tune.md; then \
          echo "aarch64-tune.md has changed; either"; \
          echo "configure with --enable-maintainer-mode"; \
          echo "or copy tmp-aarch64-tune.md to
$(srcdir)/config/aarch64/aarch64-tune.md"; \
          exit 1; \
        fi
endif
        $(STAMP) s-aarch64-tune-md

I suspect the issue is rather the timestamp on the files is incorrect causing
the trying of generating of the file.


More information about the Gcc-bugs mailing list