This was added by Hauke to try to avoid causing compile
errors where old kernels had warnings enabled by default
such as -Werror=unused-but-set-variable. This is a common
error and enabling -Werror would make compilation fail.
The following upstream patch however sould take care of this
by disabling -Werror if *any* -W* flag is found on EXTRA_FLAGS:
commit
6f56b06e74e2805577bf7940dc0fb17b3310d6b6
Author: Chen Gang <gang.chen@asianux.com>
Date: Wed Feb 27 14:55:06 2013 +0800
drivers/net/wireless/ath/wil6210: Makefile, only -Werror when no -W* in EXTRA_CFLAGS
When make with EXTRA_CFLAGS=-W, it will report error.
so give a check in Makefile.
Signed-off-by: Chen Gang <gang.chen@asianux.com>
Acked-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
The change was as follows:
-subdir-ccflags-y += -Werror
+ifeq (, $(findstring -W,$(EXTRA_CFLAGS)))
+ subdir-ccflags-y += -Werror
+endif
Since this is now upstream, just nuke this work around!
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
+++ /dev/null
---- a/drivers/net/wireless/ath/wil6210/Makefile
-+++ b/drivers/net/wireless/ath/wil6210/Makefile
-@@ -9,5 +9,4 @@ wil6210-objs += wmi.o
- wil6210-objs += interrupt.o
- wil6210-objs += txrx.o
-
--subdir-ccflags-y += -Werror
- subdir-ccflags-y += -D__CHECK_ENDIAN__