-echo
-echo ---------------------------------------------
-echo Testing Batch
-echo ---------------------------------------------
-echo
-
-dnl Several batch systems (OpenPBS, LSF, ...) can be operated using
-dnl the Batch classes library integrated in the KERNEL module. The
-dnl checking process tests here the presence of underlying batch
-dnl softwares. If none is detected, the KERNEL is declared to be
-dnl "without batch".
-
-echo testing OpenPBS
-echo ---------------
-openpbs_ok=no
-CHECK_OPENPBS
-dnl openpbs_ok is set to yes by CHECK_OPENPBS
-
-echo testing LSF
-echo -----------
-lsf_ok=no
-CHECK_LSF
-dnl lsf_ok is set to yes by CHECK_LSF
-echo lsf = $lsf_ok
-
-echo testing Local batch system
-echo --------------------------
-localbatch_ok=no
-CHECK_LOCAL
-dnl localbatch_ok is set to yes by CHECK_LOCAL
-
-WITH_BATCH=no
-test x$openpbs_ok = xyes || test x$lsf_ok = xyes || test x$localbatch_ok = xyes && WITH_BATCH=yes
-
-AC_ARG_ENABLE(batch,
- [AC_HELP_STRING([--enable-batch],[Batch [default=yes]])],
- [case "${enableval}" in
- yes) test x$openpbs_ok = xyes || test x$lsf_ok = xyes || test x$localbatch_ok = xyes && WITH_BATCH=yes;;
- no) WITH_BATCH=no ;;
- *) AC_MSG_ERROR(bad value ${enableval} for --enable-batch) ;;
- esac],[test x$openpbs_ok = xyes || test x$lsf_ok = xyes || test x$localbatch_ok = xyes && WITH_BATCH=yes])
-
-echo Batch mode = $WITH_BATCH
-
-AC_SUBST(WITH_BATCH)
-AM_CONDITIONAL(WITH_BATCH, [test x"$WITH_BATCH" = xyes])
-