dnl OpenVAS
dnl $Id: configure.in 4902 2009-09-11 07:11:43Z jan $
dnl Description: autoconf script for the OpenVAS-plugins
dnl
dnl Authors:
dnl Renaud Deraison <deraison@nessus.org> (Original pre-fork development)
dnl
dnl Copyright:
dnl Based on work Copyright (C) 1998 - 2006 Tenable Network Security, Inc.
dnl
dnl This program is free software; you can redistribute it and/or modify
dnl it under the terms of the GNU General Public License version 2,
dnl as published by the Free Software Foundation
dnl
dnl This program is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
dnl GNU General Public License for more details.
dnl
dnl You should have received a copy of the GNU General Public License
dnl along with this program; if not, write to the Free Software
dnl Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.

AC_INIT(.root-dir)
AC_REVISION($Revision: 4902 $)dnl
AC_PREREQ(2.50)

NEED_OPENVASLIBS_VERSION=1.0.0
NEED_OPENVASD_VERSION=0.9.2
INVALID_WITH_OPENVASD_VERSION=2.2.0

dnl Set up the main lines of the config script
AC_PREFIX_DEFAULT("/usr/local")

test "x$prefix" != "xNONE" || prefix=/usr/local

AC_PROG_MAKE_SET
AC_PROG_INSTALL

PWDD=`pwd`

dnl
dnl Do not use the system install script.
dnl
dnl INSTALL="`pwd`/install-sh -c"
INSTALL_DIR="$INSTALL -d"

dnl extending the search path for AC_PATH_PROG when searching for config scripts
XPATH="$DESTDIR$prefix/bin:$PATH"

test "x$prefix" = xNONE && prefix=/usr/local
AC_PATH_PROG(CP, cp)
AC_PATH_PROG(MV, mv)
AC_PATH_PROG(RM, rm)
AC_PATH_PROG(MAKE, gmake)
test "$MAKE" || {
	AC_PATH_PROG(MAKE, make)
	}

INSTALL_DIR="$INSTALL -d"

AC_PATH_PROG(ECHO, echo)
AC_PATH_PROG(TEST, test)
AC_PATH_PROG(MKDIR, mkdir)
AC_PATH_PROG(CAT, cat)

AC_SUBST(INSTALL_DIR)
AC_SUBST(INSTALL)
AC_SUBST(CP)
AC_SUBST(MV)
AC_SUBST(RM)
AC_SUBST(MAKE)
AC_SUBST(ECHO)
AC_SUBST(TEST)
AC_SUBST(MKDIR)
AC_SUBST(CAT)
AC_SUBST(PWDD)
AC_SUBST(installuser)


AC_OUTPUT(openvas.tmpl)

exit 0
