manywarnings: omit -Wdisabled-optimization
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 28 Apr 2025 06:49:12 +0000 (23:49 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 28 Apr 2025 06:55:41 +0000 (23:55 -0700)
* m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
Remove -Wdisabled-optimization, as this is a warning about the
compiler not the program.  I discovered the need for this when
compiling bleeding-edge Emacs with gcc-15 (Ubuntu
15-20250404-0ubuntu1) 15.0.1 20250404 (experimental) [master
r15-9193-g08e803aa9be] on x86-64.  Also, omit a
no-longer-necessary LC_ALL=C in a comment.

ChangeLog
HACKING
build-aux/gcc-warning.spec
m4/manywarnings.m4

index 98ffe323cc7835c9a9abfaf56fc72bfb28d69bcf..84c5fecf1bba2ca35ac436b22b4f6d43acf1aa92 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
 2025-04-27  Paul Eggert  <eggert@cs.ucla.edu>
 
+       manywarnings: omit -Wdisabled-optimization
+       * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
+       Remove -Wdisabled-optimization, as this is a warning about the
+       compiler not the program.  I discovered the need for this when
+       compiling bleeding-edge Emacs with gcc-15 (Ubuntu
+       15-20250404-0ubuntu1) 15.0.1 20250404 (experimental) [master
+       r15-9193-g08e803aa9be] on x86-64.  Also, omit a
+       no-longer-necessary LC_ALL=C in a comment.
+
        gendocs: do not depend on awk
        * build-aux/gendocs.sh (calcsize): Use shell directly, rather than
        depending on awk.  Allow spaces in outdir.  Simplify.
diff --git a/HACKING b/HACKING
index 6503c27b4c34c4f48049bd3b7776256272a43156..e0f54a4ccf9e128c989ad46d434c139a2eb361cd 100644 (file)
--- a/HACKING
+++ b/HACKING
@@ -192,7 +192,6 @@ there are three possible approaches:
       -Warith-conversion
       -Wcast-align=strict
       -Wdate-time
-      -Wdisabled-optimization
       -Wduplicated-cond
       -Wextra
       -Wformat-signedness
@@ -274,7 +273,6 @@ there are three possible approaches:
       -Warith-conversion
       -Wcast-align=strict
       -Wdate-time
-      -Wdisabled-optimization
       -Wduplicated-cond
       -Wextra
       -Wformat-signedness
index 7d1397136f1effc569b96bb46492ecb40ae612ff..e147f491492aac35171dea56d0a10a62a07f350e 100644 (file)
 -Wdeprecated-non-prototype             c compatibility
 -Wdeprecated-variadic-comma-omission   c++ and objc+++ compatibility
 -Wdesignated-init                      default
+-Wdisabled-optimization                        warns about compiler not about program
 -Wdiscarded-array-qualifiers           default
 -Wdiscarded-qualifiers                 default
 -Wdo-subscript                         fortran
index cf3f730b4c3b5088498d9d8aeac3a15abde38817..eebba901806648504ddf3fd2ac79bac481c5b441 100644 (file)
@@ -97,7 +97,7 @@ AC_DEFUN([gl_MANYWARN_ALL_GCC(C)],
   # export LC_ALL=C && comm -3 \
   #  <((sed -n 's/^  *\(-[^ 0-9][^ ]*\).*/\1/p' manywarnings.m4; \
   #     awk '/^[^#]/ {print $1}' ../build-aux/gcc-warning.spec) | sort) \
-  #  <(LC_ALL=C gcc --help=warnings | sed -n 's/^  \(-[^ ]*\) .*/\1/p' | sort)
+  #  <(gcc --help=warnings | sed -n 's/^  \(-[^ ]*\) .*/\1/p' | sort)
 
   $1=
   for gl_manywarn_item in -fanalyzer -fstrict-flex-arrays \
@@ -106,7 +106,6 @@ AC_DEFUN([gl_MANYWARN_ALL_GCC(C)],
     -Wbad-function-cast \
     -Wcast-align=strict \
     -Wdate-time \
-    -Wdisabled-optimization \
     -Wdouble-promotion \
     -Wduplicated-branches \
     -Wduplicated-cond \