gl_ASSERT: don't say assertions are disabled when they're not
authorJim Meyering <meyering@redhat.com>
Wed, 10 Dec 2008 14:06:42 +0000 (15:06 +0100)
committerJim Meyering <meyering@redhat.com>
Wed, 10 Dec 2008 17:11:43 +0000 (18:11 +0100)
* m4/assert.m4 (gl_ASSERT): Do not make configure report
"checking whether to enable assertions... no", when they are in
fact enabled.  This is solely a bug in the output of configure.
In spite of saying "no", NDEBUG was not defined in that case.

ChangeLog
m4/assert.m4

index d069445..8677895 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2008-12-10  Jim Meyering  <meyering@redhat.com>
+
+       gl_ASSERT: don't say assertions are disabled when they're not
+       * m4/assert.m4 (gl_ASSERT): Do not make configure report
+       "checking whether to enable assertions... no", when they are in
+       fact enabled.  This is solely a bug in the output of configure.
+       In spite of saying "no", NDEBUG was not defined in that case.
+       Also, as noted by Eric Blake, leave assertions enabled upon
+       --enable-assert=INVALID.
+
 2008-12-10  Bruno Haible  <bruno@clisp.org>
 
        Change MODULES.html to refer to POSIX:2008 where possible.
index cb61ce8..fb90cb3 100644 (file)
@@ -1,4 +1,4 @@
-#serial 6
+#serial 7
 
 # Copyright (C) 1998, 1999, 2001, 2004, 2008 Free Software Foundation, Inc.
 # This file is free software; the Free Software Foundation
@@ -18,7 +18,7 @@ AC_DEFUN([gl_ASSERT],
        [Define to 1 if assertions should be disabled.])],
       [test "x$enableval" != xyes],
       [AC_MSG_WARN([invalid argument supplied to --enable-assert])
-      enable_assert=no])],
-    [enable_assert=no])
+      enable_assert=yes])],
+    [enable_assert=yes])
   AC_MSG_RESULT([$enable_assert])
 ])