From 752533f86541214b855c123215f4c40a5bcae761 Mon Sep 17 00:00:00 2001 From: Kai Blin Date: Fri, 19 Mar 2010 09:17:15 +0100 Subject: [PATCH] build: Enable more warnings when using the --pedantic configuration option --- lib/replace/wscript | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/replace/wscript b/lib/replace/wscript index e189ab31df5..9b4aa6d9fe9 100644 --- a/lib/replace/wscript +++ b/lib/replace/wscript @@ -30,6 +30,9 @@ def set_options(opt): help=("use file timestamps instead of content for build dependencies (BROKEN)"), action="store_true", dest='timestamp_dependencies', default=False) opt.add_option('-C', action='store_true', help='dummy option for autoconf compatibility') + opt.add_option('--pedantic', + help=("Enable even more compiler warnings"), + action='store_true', dest='pedantic', default=False) @wafsamba.runonce def configure(conf): @@ -214,6 +217,9 @@ def configure(conf): addmain=False, msg="Checking for C99 vsnprintf") + if Options.options.pedantic: + conf.ADD_CFLAGS('-W') + if Options.options.developer: conf.ADD_CFLAGS('-Wall -g -Wfatal-errors -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Werror-implicit-function-declaration -Wformat=2 -Wno-format-y2k')