[PATCH] configure --disable-debug enables debugging

Jeroen Roovers <[email protected]>
Newsgroups gmane.comp.window-managers.ratpoison.devel
Message-ID <[email protected]>
When given --disable-debug, configure will still enable debugging. The
second argument to AC_ARG_ENABLE is executed when either
--enable-/feature/ or --disable-/feature/ is set, so we need to check
$enableval for the option argument (defaulting to yes/no) instead.

Patch attached.


Regards,
     Jeroen Roovers

_______________________________________________
Ratpoison-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/ratpoison-devel
ratpoison-1.4.7-configure.patch (text/plain, 509 B)
--- a/configure.ac
+++ b/configure.ac
@@ -34,8 +34,12 @@
 AC_MSG_CHECKING([whether to enable debugging])
 AC_ARG_ENABLE([debug],
   [AS_HELP_STRING([--enable-debug],[build with extra debugging messages])],
+  if test x$enableval = xyes; then
   [AC_MSG_RESULT([yes])
-   AC_DEFINE([DEBUG], 1, [Define this to enable debugging messages])],
+   AC_DEFINE([DEBUG], 1, [Define this to enable debugging messages])]
+  else
+  [AC_MSG_RESULT([no])]
+  fi,
   [AC_MSG_RESULT([no])])
 
 AC_ARG_WITH([electric-fence],
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.