AC_INIT(kalyptus)

AC_DEFUN(AC_FIND_PERL,
[
AC_MSG_CHECKING(for perl 5 or greater)
if $srcdir/findperl; then
	$1=`cat perlbin`
	echo $$1
else
	echo "Couldn't find perl 5 or later. kdoc will not run."
	exit 1
fi	
])

AC_DEFUN(AC_KALYPTUS_VERSION,
[
AC_MSG_CHECKING(kalyptus version)
$1=`cat $srcdir/Version | sed 's#Revision##g' | tr -d '\$:'`
echo $$1
])

AC_PROG_INSTALL
AC_FIND_PERL(perl)
AC_SUBST(perl)
AC_KALYPTUS_VERSION(Version)
AC_SUBST(Version)

AC_OUTPUT(Makefile)
