dnl Process this file with autoconf to produce a configure script.
AC_INIT(mod_aolserver.c)

dnl Checks for programs.
AC_PROG_CC
AC_PROG_INSTALL

dnl Find the Apache extension builder.
MAS_PATH_APXS

dnl Find the MM library.
MAS_PATH_MM

dnl Pick a database

AC_ARG_WITH(database,
    [  --with-database=DBNAME  Either \`ora8' or \`postgres'],
    [
	AC_SUBST(DBNAME)
	DBNAME="$withval"
	if test x"$withval" = xora8; then
	    MAS_PATH_ORACLE
	elif test x"$withval" = xpostgres; then
	    MAS_PATH_POSTGRES
	else
	    AC_MSG_ERROR([Unknown database \`$withval'])
	fi
    ],
    [
	AC_MSG_ERROR([Must specify database driver using --with-database.])
    ]
)

# Find Tcl.

SC_PATH_TCLCONFIG
SC_LOAD_TCLCONFIG

AC_OUTPUT(Makefile)