summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJérémie Courrèges-Anglas <jca@wxcvbn.org>2014-06-14 16:48:55 +0200
committerJérémie Courrèges-Anglas <jca@wxcvbn.org>2014-06-14 16:48:55 +0200
commit8904b43449d280f39a738c09e3e649b58f519e4f (patch)
tree3cdeb3de2dff77b2d20b0b66c7ba54c4a5f316f7
parent4fe2bf0b5e7ac663285eb171d9dd7e4b85c0506b (diff)
downloadratpoison-8904b43449d280f39a738c09e3e649b58f519e4f.zip
Support --enable-debug=no
Reported by Jeroen Roovers (jer@gentoo) who proposed a similar patch.
-rw-r--r--configure.ac9
1 files changed, 6 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index 9e83098..f4603ac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -31,9 +31,12 @@ dnl by default turn off debugging
AC_MSG_CHECKING([whether to enable debugging])
AC_ARG_ENABLE([debug],
[AS_HELP_STRING([--enable-debug],[build with extra debugging messages])],
- [AC_MSG_RESULT([yes])
- AC_DEFINE([DEBUG], 1, [Define this to enable debugging messages])],
- [AC_MSG_RESULT([no])])
+ [], [enable_debug=no])
+AS_CASE([$enable_debug],
+ [yes], [AC_MSG_RESULT([yes])
+ AC_DEFINE([DEBUG], 1, [Define this to enable debugging messages])],
+ [no], [AC_MSG_RESULT([no])],
+ [AC_MSG_ERROR([invalid --enable-debug="$enable_debug" parameter])])
AC_ARG_WITH([electric-fence],
[AS_HELP_STRING([--with-electric-fence],