]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Makefile.tpl: disable -Werror for feedback stage [PR111663]
authorSergei Trofimovich <siarheit@google.com>
Mon, 2 Oct 2023 11:08:17 +0000 (12:08 +0100)
committerSergei Trofimovich <siarheit@google.com>
Fri, 6 Oct 2023 19:25:20 +0000 (20:25 +0100)
Without the change profiled bootstrap fails for various warnings on
master branch as:

    $ ../gcc/configure
    $ make profiledbootstrap
    ...
    gcc/genmodes.cc: In function ‘int main(int, char**)’:
    gcc/genmodes.cc:2152:1: error: ‘gcc/build/genmodes.gcda’ profile count data file not found [-Werror=missing-profile]
    ...
    gcc/gengtype-parse.cc: In function ‘void parse_error(const char*, ...)’:
    gcc/gengtype-parse.cc:142:21: error: ‘%s’ directive argument is null [-Werror=format-overflow=]

The change removes -Werror just like autofeedback does today.

/

PR bootstrap/111663
* Makefile.tpl (STAGEfeedback_CONFIGURE_FLAGS): Disable -Werror.
* Makefile.in: Regenerate.

Makefile.in
Makefile.tpl

index 2f136839c35ebdcafffb1c8db8041d49d4088d71..e0e3c4c8fe80409e3a1f475350de1ad1f9b77e2a 100644 (file)
@@ -638,6 +638,10 @@ STAGEtrain_TFLAGS = $(filter-out -fchecking=1,$(STAGE3_TFLAGS))
 
 STAGEfeedback_CFLAGS = $(STAGE4_CFLAGS) -fprofile-use -fprofile-reproducible=parallel-runs
 STAGEfeedback_TFLAGS = $(STAGE4_TFLAGS)
+# Disable warnings as errors for a few reasons:
+# - sources for gen* binaries do not have .gcda files available
+# - inlining decisions generate extra warnings
+STAGEfeedback_CONFIGURE_FLAGS = $(filter-out --enable-werror-always,$(STAGE_CONFIGURE_FLAGS))
 
 STAGEautoprofile_CFLAGS = $(filter-out -gtoggle,$(STAGE2_CFLAGS)) -g
 STAGEautoprofile_TFLAGS = $(STAGE2_TFLAGS)
index 5872dd03f2c7070b9df4b923f049b52afea9c924..8b7783bb4f1e6036471e503e37589636cb9c5365 100644 (file)
@@ -561,6 +561,10 @@ STAGEtrain_TFLAGS = $(filter-out -fchecking=1,$(STAGE3_TFLAGS))
 
 STAGEfeedback_CFLAGS = $(STAGE4_CFLAGS) -fprofile-use -fprofile-reproducible=parallel-runs
 STAGEfeedback_TFLAGS = $(STAGE4_TFLAGS)
+# Disable warnings as errors for a few reasons:
+# - sources for gen* binaries do not have .gcda files available
+# - inlining decisions generate extra warnings
+STAGEfeedback_CONFIGURE_FLAGS = $(filter-out --enable-werror-always,$(STAGE_CONFIGURE_FLAGS))
 
 STAGEautoprofile_CFLAGS = $(filter-out -gtoggle,$(STAGE2_CFLAGS)) -g
 STAGEautoprofile_TFLAGS = $(STAGE2_TFLAGS)