All of lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] meson: Turn off -Werror
@ 2021-02-01  6:33 Petri Latvala
  2021-02-01  8:01 ` Chris Wilson
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Petri Latvala @ 2021-02-01  6:33 UTC (permalink / raw)
  To: igt-dev; +Cc: Petri Latvala, Chris Wilson

No, we don't want all warnings ever to be errors. While being rid of
compile warnings (especially the more obscure ones from future
compilers) is great, having it on always is not acceptable. It's not
even on "by default", it was non-overrideably set on.

Not to mention adding -Werror to compiler flags is the incorrect way
of turning it on. Use the meson command line flag --werror instead on
whatever local checkout or company-internal fork you're using, where
you have control over which compilers are used. Turning it on
unconditionally in an upstream repository for all current and future
compilers is never ok.

This partially reverts commit e02612921a4e95aef3a368e7468f4337c9dcee7d.

Signed-off-by: Petri Latvala <petri.latvala@intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Arkadiusz Hiler <arek@hiler.eu>
---
 meson.build | 28 +++++++++++++---------------
 1 file changed, 13 insertions(+), 15 deletions(-)

diff --git a/meson.build b/meson.build
index 3f3693f9..f4ee14f1 100644
--- a/meson.build
+++ b/meson.build
@@ -51,21 +51,19 @@ cc_args = [
 	'-Wno-unused-parameter',
 	'-Wno-unused-result',
 
-	'-Waddress',
-	'-Warray-bounds',
-	'-Wimplicit',
-	'-Winit-self',
-	'-Wint-to-pointer-cast',
-	'-Wmain',
-	'-Wmissing-braces',
-	'-Wnonnull',
-	'-Wpointer-to-int-cast',
-	'-Wreturn-type',
-	'-Wsequence-point',
-	'-Wtrigraphs',
-	'-Wwrite-strings',
-
-	'-Werror',
+	'-Werror=address',
+	'-Werror=array-bounds',
+	'-Werror=implicit',
+	'-Werror=init-self',
+	'-Werror=int-to-pointer-cast',
+	'-Werror=main',
+	'-Werror=missing-braces',
+	'-Werror=nonnull',
+	'-Werror=pointer-to-int-cast',
+	'-Werror=return-type',
+	'-Werror=sequence-point',
+	'-Werror=trigraphs',
+	'-Werror=write-strings',
 # Disable the memory allocating builtins as they may cause unexpected behavior
 # with our framework. They *may* get optimized out in favor of a register or
 # stack variable, making them effectively local. Local variables do not play
-- 
2.29.2

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-02-01 10:34 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-01  6:33 [igt-dev] [PATCH i-g-t] meson: Turn off -Werror Petri Latvala
2021-02-01  8:01 ` Chris Wilson
2021-02-01  8:07   ` Petri Latvala
2021-02-01  8:12     ` Chris Wilson
2021-02-01  8:40 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2021-02-01 10:34 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.