-#AC_DEFINE([MYVERSION], [5.6])
-#AC_DEFINE_UNQUOTED([MYDIR], "${sysconfdir}")
-#AC_DEFINE([SYSCONFDIR], [$sysconfdir], [System config dir])
-AC_SUBST([CFGDIR], "${sysconfdir}")
+# BASH may already be set in the shell, if the admin then changes the
+# the /bin/sh symlink to a non-bash shell, all hell will break lose.
+unset BASH
+AC_PATH_PROGS([BASH], [bash], [/bin/bash], [$PATH:/bin:/usr/bin:/usr/sbin])
+if test x$BASH = "x"; then
+ AC_MSG_ERROR([bash is required])
+fi
+
+AC_CHECK_PROGS(SED, sed)
+if test x$SED = "x"; then
+ AC_MSG_ERROR([sed is required])
+fi