From: Junio C Hamano Date: Fri, 18 Jan 2019 21:49:55 +0000 (-0800) Subject: Merge branch 'jk/dev-build-format-security' X-Git-Tag: v2.21.0-rc0~86 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/74ae0652c4736629db9c97f7a3ac7cebedaeae10 Merge branch 'jk/dev-build-format-security' Earlier we added "-Wformat-security" to developer builds, assuming that "-Wall" (which includes "-Wformat" which in turn is required to use "-Wformat-security") is always in effect. This is not true when config.mak.autogen is in use, unfortunately. This has been fixed by unconditionally adding "-Wall" to developer builds. * jk/dev-build-format-security: config.mak.dev: add -Wall, primarily for -Wformat, to help autoconf users --- 74ae0652c4736629db9c97f7a3ac7cebedaeae10 diff --cc config.mak.dev index bbeeff44fe,74337f1f92..7354fe15b3 --- a/config.mak.dev +++ b/config.mak.dev @@@ -1,11 -1,7 +1,12 @@@ ifeq ($(filter no-error,$(DEVOPTS)),) CFLAGS += -Werror endif +ifneq ($(filter pedantic,$(DEVOPTS)),) +CFLAGS += -pedantic +# don't warn for each N_ use +CFLAGS += -DUSE_PARENS_AROUND_GETTEXT_N=0 +endif + CFLAGS += -Wall CFLAGS += -Wdeclaration-after-statement CFLAGS += -Wformat-security CFLAGS += -Wno-format-zero-length