+# -------------------------------------------
+# bat (default off)
+# -------------------------------------------
+# Check whether --enable-bat was given.
+if test "${enable_bat+set}" = set; then
+ enableval=$enable_bat; if test x$enableval = xyes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_BAT 1
+_ACEOF
+
+ support_bat=yes
+ fi
+fi
+
+
+BAT_DIR=
+if test x$support_bat = xyes; then
+ abc=`$PKGCONFIG --atleast-version=4.2 QtGui`
+ pkg=$?
+ if test $pkg = 0; then
+ BAT_DIR=src/qt-console
+ else
+ { { echo "$as_me:$LINENO: error: Unable to find Qt4 installation needed by bat" >&5
+echo "$as_me: error: Unable to find Qt4 installation needed by bat" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+
+