GNOME Bugzilla – Bug 707475
Allow custom warnings in GNOME_COMPILE_WARNINGS
Last modified: 2013-09-05 05:23:30 UTC
Patch coming up which adds an optional second parameter to GNOME_COMPILE_WARNINGS which allows projects to specify additional warning/error flags which they want to use (dependent on --enable-compile-warnings). This will allow projects to enable stricter compilation warnings on a per-project basis, but still allow them to be turned off by users (with --enable-compile-warnings=no) if they’re a problem for some reason. This should fix the situation where the maintainer compiles a module with some set of locally-enabled strict warning flags, then someone else commits a patch which was developed only against the standard warning flags, and introduces a warning which breaks the build for the maintainer (and nobody else).
Created attachment 254099 [details] [review] compiler-flags: Add an optional second argument for custom warnings This allows module authors to choose to enforce stricter warnings on a per-module basis, to avoid the situation where an outside contributor submits a patch which introduces warnings the maintainer has enabled locally. Closes:
Review of attachment 254099 [details] [review]: The changes look fine to me. Should a serial be added to gnome-compiler-flags.m4, or is the one in gnome-common.m4 sufficient?
(In reply to comment #2) > Should a serial be added to gnome-compiler-flags.m4, or is the one in > gnome-common.m4 sufficient? Looking at the manual, serials are per-file, so I’ve added one to gnome-compiler-flags.m4. I didn’t know about them before; thanks for pointing them out! commit f8f5bc923239d02a5e2f5f8ee8d357eafb2bfc12 Author: Philip Withnall <philip@tecnocode.co.uk> Date: Wed Sep 4 23:11:14 2013 -0600 compiler-flags: Add a #serial line As suggested in bug #707475, this will ensure the latest version of gnome-compiler-flags.m4 is used if conflicting versions are found in different directories in the autoconf search path. Helps: https://bugzilla.gnome.org/show_bug.cgi?id=707475 macros2/gnome-compiler-flags.m4 | 5 +++++ 1 file changed, 5 insertions(+) commit c834b24651e1b0f510ede8610bde0be1e940de14 Author: Philip Withnall <philip@tecnocode.co.uk> Date: Wed Sep 4 00:48:19 2013 -0600 compiler-flags: Add an optional second argument for custom warnings This allows module authors to choose to enforce stricter warnings on a per-module basis, to avoid the situation where an outside contributor submits a patch which introduces warnings the maintainer has enabled locally. Closes: https://bugzilla.gnome.org/show_bug.cgi?id=707475 macros2/gnome-compiler-flags.m4 | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-)