From: Sergei Trofimovich Date: Mon, 2 Oct 2023 11:08:17 +0000 (+0100) Subject: Makefile.tpl: disable -Werror for feedback stage [PR111663] X-Git-Tag: basepoints/gcc-15~5700 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2551e10038a70901f30b2168e6e3af4536748f3c;p=thirdparty%2Fgcc.git Makefile.tpl: disable -Werror for feedback stage [PR111663] 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. --- diff --git a/Makefile.in b/Makefile.in index 2f136839c35e..e0e3c4c8fe80 100644 --- a/Makefile.in +++ b/Makefile.in @@ -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) diff --git a/Makefile.tpl b/Makefile.tpl index 5872dd03f2c7..8b7783bb4f1e 100644 --- a/Makefile.tpl +++ b/Makefile.tpl @@ -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)