Index: LinearAlgebra/configure.ac
===================================================================
--- LinearAlgebra/configure.ac	(revision 7bace8c6a0fc5f316d62ec82ddff0efda879896b)
+++ LinearAlgebra/configure.ac	(revision 908dc743816b2e8b11f5297f04644e47e0d110d9)
@@ -38,18 +38,29 @@
 dnl Check if we have enable debug support.
 AC_MSG_CHECKING(whether to enable debugging)
-AC_ARG_ENABLE(debug, [  --enable-debug=[no/yes/full] turn on debugging
-                     [default=yes]],, enable_debug=$enableval)
+have_debug="no"
+AC_ARG_ENABLE(
+	[debug],
+	AS_HELP_STRING([--enable-debug],[turn on debugging [default=no]]),
+	enable_debug=$enableval,
+	enable_debug="no")
 AC_MSG_RESULT($enable_debug)
-if test "x$enable_debug" = "xyes"; then
+AS_IF([test x"$enable_debug" = x"yes"],[
   AC_DEFINE(MEMDEBUG,1, ["Use memory debugger."])
   AC_DEFINE(HAVE_DEBUG,1, ["Use debug setting to compile code."])
-elif test "x$enable_debug" = "xfull"; then
-  AC_DEFINE(MEMDEBUG,1, ["Use memory debugger."])
-  AC_DEFINE(LOG_OBSERVER,1, ["Use observer log."])
-  AC_DEFINE(HAVE_DEBUG,2, ["Use debug setting to compile code."])
-else
-  AC_DEFINE(NDEBUG,1, ["Don't compile in debugging code."])
-  AC_DEFINE(HAVE_DEBUG,0, ["Use debug setting to compile code."])
-fi
+  have_debug="yes"
+],[
+	AS_IF([test x"$enable_debug" = x"full"],[
+	  AC_DEFINE(MEMDEBUG,1, ["Use memory debugger."])
+	  AC_DEFINE(LOG_OBSERVER,1, ["Use observer log."])
+	  AC_DEFINE(HAVE_DEBUG,2, ["Use debug setting to compile code."])
+	  AC_DEFINE(QT_DEBUG,, ["Enable Qt debug messages."])
+	  have_debug="full"
+	],[
+	  AC_DEFINE(NDEBUG,1, ["Don't compile in debugging code."])
+	  AC_DEFINE(HAVE_DEBUG,0, ["Use debug setting to compile code."])
+	  AC_DEFINE(QT_NO_DEBUG,, ["Disable Qt debug messages."])
+	  have_debug="no"
+	])
+])
 AC_SUBST(HAVE_DEBUG)
 
@@ -57,15 +68,17 @@
 dnl to the configure script (./configure --enable-debug)
 dnl Check if we have enable debug support.
-AC_MSG_CHECKING([whether to enable internal caching of values (speedup!)])
-AC_ARG_ENABLE(cache, [  --enable-cache=[no/yes] turn on caching
-                     [default=yes]],, enable_cache=$enableval)
+AC_MSG_CHECKING(whether to enable internal caching/lazy evaluation)
+AC_ARG_ENABLE(
+	[cache],
+	AS_HELP_STRING([--enable-cache],[turn on internal lazy evaluation [default=yes]]),
+	enable_cache=$enableval,
+	enable_cache="yes")
 AC_MSG_RESULT($enable_cache)
-if test "x$enable_cache" = "xno"; then
+AS_IF([test x"$enable_cache" != x"no"],[
+  AC_DEFINE(HAVE_CACHE,1, ["cache variables to speed up the code."])
+],[
   AC_DEFINE(NO_CACHING,1, ["Don't use caching code."])
   AC_DEFINE(HAVE_CACHE,0, ["cache variables to speed up the code."])
-else
-  AC_DEFINE(HAVE_CACHE,1, ["cache variables to speed up the code."])
-  AC_MSG_RESULT(yes)
-fi
+])
 AC_SUBST(HAVE_CACHE)
 
@@ -111,17 +124,25 @@
 
 # use CppUnit TestRunner or not
-AC_ARG_ENABLE([ecut],AS_HELP_STRING([--enable-ecut],[Use ECut TestRunnerClient (default is no)]),
-              [enable_ecut=$enableval], [enable_ecut=no])
-if test x"$enable_ecut" = xyes; then
+AC_MSG_CHECKING(whether to enable ECut TestRunnerClient)
+AC_ARG_ENABLE(
+	[ecut],
+	AS_HELP_STRING([--enable-ecut],[Use ECut TestRunnerClient [default=no]]),
+	enable_ecut=$disableval,
+	enable_ecut="no")
+AC_MSG_RESULT($enable_ecut)
+AS_IF([test x"$enable_ecut" = x"yes"],[
   AC_DEFINE(HAVE_ECUT,1, ["Use ECut TestRunnerClient instead of our own."])
   AC_SUBST(HAVE_ECUT)
-fi
+])
 
 # with valgrinding testsuite or not
 AC_MSG_CHECKING(whether to enable valgrind memory checking in testsuite)
-AC_ARG_WITH([valgrind],AS_HELP_STRING([--with-valgrind],[Use Valgrind on the testsuite (default is no)]),
-              [with_valgrind=$withval], [with_valgrind=no])
-AC_MSG_RESULT($with_valgrind)
-AS_IF([test "$with_valgrind" = yes],[
+AC_ARG_ENABLE(
+	[valgrind],
+	AS_HELP_STRING([--enable-valgrind],[Use Valgrind on the testsuite [default=no]]),
+        enable_valgrind=$enableval,
+	enable_valgrind="no")
+AC_MSG_RESULT($enable_valgrind)
+AS_IF([test x"$enable_valgrind" = x"yes"], [
   AC_CHECK_HEADER([valgrind/valgrind.h],
     [
