From: Denis Vlasenko Date: Thu, 1 Feb 2007 01:51:36 +0000 (-0000) Subject: add -Wwrite-strings to Makefile X-Git-Tag: 1_5_1~231 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4bb31899e5fe8e25b2e79b468de87007933c4eb9;p=platform%2Fupstream%2Fbusybox.git add -Wwrite-strings to Makefile --- diff --git a/Makefile.flags b/Makefile.flags index 9de52d8..e4ca7c6 100644 --- a/Makefile.flags +++ b/Makefile.flags @@ -16,10 +16,7 @@ CPPFLAGS += \ -D"BB_VER=KBUILD_STR($(BB_VER))" -DBB_BT=AUTOCONF_TIMESTAMP # flag checks are grouped together to speed the checks up a bit.. -CFLAGS += $(call cc-option,-Wall -Wshadow,) -ifeq ($(CONFIG_WERROR),y) -CFLAGS += $(call cc-option,-Werror,) -endif +CFLAGS += $(call cc-option,-Wall -Wshadow -Wwrite-strings,) CFLAGS += $(call cc-option,-Wundef -Wstrict-prototypes,) # If you want to add "-Wmissing-prototypes -Wmissing-declarations" above # (or anything else for that matter) make sure that it is still possible @@ -28,6 +25,9 @@ CFLAGS += $(call cc-option,-Wundef -Wstrict-prototypes,) # But still, warning-free compile is a must, or else we will drown # in warnings pretty soon. +ifeq ($(CONFIG_WERROR),y) +CFLAGS += $(call cc-option,-Werror,) +endif # gcc 3.x emits bogus "old style proto" warning on find.c:alloc_action() CFLAGS += $(call cc-ifversion, -ge, 0400, -Wold-style-definition)