From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22315 invoked by alias); 14 May 2009 07:02:07 -0000 Received: (qmail 21804 invoked by alias); 14 May 2009 07:02:03 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS X-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS X-Spam-Check-By: sourceware.org X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on bastion2.fedora.phx.redhat.com Subject: cluster: STABLE3 - build: set paranoia build warnings by default To: cluster-cvs-relay@redhat.com X-Project: Cluster Project X-Git-Module: cluster.git X-Git-Refname: refs/heads/STABLE3 X-Git-Reftype: branch X-Git-Oldrev: c091d13d40da0c8c78c571e3ce1e0689a666ba5a X-Git-Newrev: fa43932c378e13890b05735a2aabfe27c108d8d6 From: "Fabio M. Di Nitto" Message-Id: <20090514070127.8BD2512030F@lists.fedorahosted.org> Date: Thu, 14 May 2009 07:02:00 -0000 X-Scanned-By: MIMEDefang 2.58 on 172.16.52.254 Mailing-List: contact cluster-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: cluster-cvs-owner@sourceware.org X-SW-Source: 2009-q2/txt/msg00312.txt.bz2 Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=fa43932c378e13890b05735a2aabfe27c108d8d6 Commit: fa43932c378e13890b05735a2aabfe27c108d8d6 Parent: c091d13d40da0c8c78c571e3ce1e0689a666ba5a Author: Fabio M. Di Nitto AuthorDate: Thu May 14 08:59:35 2009 +0200 Committer: Fabio M. Di Nitto CommitterDate: Thu May 14 08:59:35 2009 +0200 build: set paranoia build warnings by default - drop -Werror from qdisk/xvm/rgmanager - enable "old" paranoia cflags by default - make paranoia cflags set -Werror - change -g to -ggdb3 Signed-off-by: Fabio M. Di Nitto --- cman/qdisk/Makefile | 1 - configure | 23 ++++++++++++----------- fence/agents/xvm/Makefile | 1 - rgmanager/src/clulib/Makefile | 2 +- rgmanager/src/daemons/Makefile | 2 +- rgmanager/src/utils/Makefile | 2 +- 6 files changed, 15 insertions(+), 16 deletions(-) diff --git a/cman/qdisk/Makefile b/cman/qdisk/Makefile index d050ead..0b3629d 100644 --- a/cman/qdisk/Makefile +++ b/cman/qdisk/Makefile @@ -12,7 +12,6 @@ include $(OBJDIR)/make/install.mk include $(OBJDIR)/make/uninstall.mk CFLAGS += -D_GNU_SOURCE -CFLAGS += -Werror -Wstrict-prototypes -Wshadow CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${logtincdir} CFLAGS += -I${zlibincdir} CFLAGS += -I$(S) diff --git a/configure b/configure index 5949111..1daa4a7 100755 --- a/configure +++ b/configure @@ -230,10 +230,10 @@ if ($help || !$err) { print "--module_dir=\tthe base directory for kernel modules. (Default: /lib/modules/`uname -r`/kernel\n"; print "\nbuild flags:\n"; print "--cc=\t\tcompiler to use. (Default: gcc)\n"; - print "--debug\t\tEnable debugging build. Changes default CFLAGS to -Wall -O0 -DDEBUG -g.\n"; - print "--cflags=\toverride default CFLAGS settings. (Default: -Wall -O2 -g)\n"; + print "--debug\t\tEnable debugging build. Changes default optimization CFLAGS to -O0 -DDEBUG -ggdb3\n"; + print "--cflags=\toverride default CFLAGS settings.\n"; print "--extracflags=\tadd extra compiler options to default CFLAGS setting. (Default: none)\n"; - print "--enable_paranoia_cflags=\tadd paranoia compiler options to default CFLAGS setting. (Default: tons)\n"; + print "--enable_paranoia_cflags=\tadd paranoia compiler options to default CFLAGS setting. (Default: -Werror)\n"; print "--ldflags=\toverride default LDFLAGS settings. (Default: none)\n"; print "--extraldflags=\tadd extra linking options to default LDFLAGS settings. (Default: none)\n"; print "--objdir=\tspecify directory where to store object files. (Defaults: current build dir)\n"; @@ -370,24 +370,25 @@ if (!$cc) { $cc="gcc"; } if (!$cflags) { - $cflags="-Wall -Wformat=2 -MMD"; + $cflags=""; + $cflags="${cflags} -Wall -Wformat=2 -Wshadow -Wmissing-prototypes"; + $cflags="${cflags} -Wstrict-prototypes -Wdeclaration-after-statement"; + $cflags="${cflags} -Wpointer-arith -Wwrite-strings -Wcast-align"; + $cflags="${cflags} -Wbad-function-cast -Wmissing-format-attribute"; + $cflags="${cflags} -Wformat-security -Wformat-nonliteral -Wno-long-long"; + $cflags="${cflags} -Wno-strict-aliasing -Wmissing-declarations"; if (!$debug) { $cflags="${cflags} -O2"; } else { $cflags="${cflags} -O0 -DDEBUG"; } - $cflags="${cflags} -g"; + $cflags="${cflags} -ggdb3 -MMD"; } if ($extracflags) { $cflags="${cflags} ${extracflags}"; } if ($enable_paranoia_cflags) { - $cflags="${cflags} -Wshadow -Wmissing-prototypes -Wmissing-declarations"; - $cflags="${cflags} -Wstrict-prototypes -Wdeclaration-after-statement"; - $cflags="${cflags} -Wpointer-arith -Wwrite-strings -Wcast-align"; - $cflags="${cflags} -Wbad-function-cast -Wmissing-format-attribute"; - $cflags="${cflags} -Wformat-security -Wformat-nonliteral -Wno-long-long"; - $cflags="${cflags} -Wno-strict-aliasing"; + $cflags="-Werror ${cflags}"; } if (!$ldflags) { $ldflags=""; diff --git a/fence/agents/xvm/Makefile b/fence/agents/xvm/Makefile index cbabda0..627e4dc 100644 --- a/fence/agents/xvm/Makefile +++ b/fence/agents/xvm/Makefile @@ -30,7 +30,6 @@ SHAREDOBJS= mcast.o \ debug.o CFLAGS += -D_GNU_SOURCE -CFLAGS += -Werror -Wstrict-prototypes -Wshadow CFLAGS += -I${ccsincdir} -I${cmanincdir} CFLAGS += -I${corosyncincdir} -I${openaisincdir} CFLAGS += -I${logtincdir} diff --git a/rgmanager/src/clulib/Makefile b/rgmanager/src/clulib/Makefile index 52cd438..34f58fb 100644 --- a/rgmanager/src/clulib/Makefile +++ b/rgmanager/src/clulib/Makefile @@ -16,7 +16,7 @@ OBJS1= logging.o daemon_init.o signals.o msgsimple.o \ OBJS2= msgtest.o -CFLAGS += -Werror -Wstrict-prototypes -Wshadow -fPIC -D_GNU_SOURCE +CFLAGS += -fPIC -D_GNU_SOURCE CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${dlmincdir} CFLAGS += -I${logtincdir} CFLAGS += -I$(S)/../../include diff --git a/rgmanager/src/daemons/Makefile b/rgmanager/src/daemons/Makefile index 0b8e6f9..14f269a 100644 --- a/rgmanager/src/daemons/Makefile +++ b/rgmanager/src/daemons/Makefile @@ -47,7 +47,7 @@ SHAREDOBJS= depends-noccs.o \ event_config-noccs.o CFLAGS += -DSHAREDIR=\"${sharedir}\" -CFLAGS += -Werror -Wstrict-prototypes -Wshadow -fPIC +CFLAGS += -fPIC CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${dlmincdir} -I${logtincdir} CFLAGS += `xml2-config --cflags` -I${readlineincdir} -I${slangincdir} CFLAGS += -I$(S)/../../include diff --git a/rgmanager/src/utils/Makefile b/rgmanager/src/utils/Makefile index 0e01c73..48f3885 100644 --- a/rgmanager/src/utils/Makefile +++ b/rgmanager/src/utils/Makefile @@ -17,7 +17,7 @@ include $(OBJDIR)/make/uninstall.mk DISABLEDTARGETS= cluarp -CFLAGS += -Werror -Wstrict-prototypes -Wshadow -fPIC -D_GNU_SOURCE +CFLAGS += -fPIC -D_GNU_SOURCE CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${dlmincdir} CFLAGS += -I${logtincdir} -I${ncursesincdir} CFLAGS += -I$(S)/../../include