From 6f5292c87ece138a2b80d102ba0919b105b1839a Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Wed, 1 Oct 2003 17:28:12 +0000 Subject: define DEBUG, NDEBUG, and G_DISABLE_ASSERTS --- m4/openbox.m4 | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'm4') diff --git a/m4/openbox.m4 b/m4/openbox.m4 index 7c19ab4b..db592e91 100644 --- a/m4/openbox.m4 +++ b/m4/openbox.m4 @@ -61,12 +61,18 @@ AC_DEFUN([OB_COMPILER_FLAGS], FLAGS="" + if test "$DEBUG" = "yes"; then + FLAGS="-DDEBUG" + else + FLAGS="-DNDEBUG -DG_DISABLE_ASSERT" + fi + # Check what compiler we are using AC_MSG_CHECKING([for GNU CC]) if test "$GCC" = "yes"; then AC_MSG_RESULT([yes]) if test "$DEBUG" = "yes"; then - FLAGS="-g -fno-inline" + FLAGS="$FLAGS -g -fno-inline" FLAGS="$FLAGS -Wall -Wsign-compare -Waggregate-return" FLAGS="$FLAGS -Wcast-qual -Wbad-function-cast -Wpointer-arith" # for Python.h -- cgit v1.2.3