]> git.decadent.org.uk Git - nfs-utils.git/blobdiff - configure
2001-03-11 H.J. Lu <hjl@lucon.org>
[nfs-utils.git] / configure
index 1611d709fd2e6efc5effe11de9e0f9675465fb4a..2f2a25e33d91ad7dd3b365d80e9ac5fa8a41ee2c 100755 (executable)
--- a/configure
+++ b/configure
@@ -12,6 +12,8 @@ ac_help=
 ac_default_prefix=/usr/local
 # Any additions from configure.in:
 ac_default_prefix=/usr
+ac_help="$ac_help
+  --with-release=XXX      set release to XXX [1]"
 ac_help="$ac_help
   --with-statedir=/foo    use state dir /foo [/var/lib/nfs]"
 ac_help="$ac_help
@@ -37,7 +39,6 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
-sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -152,7 +153,6 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
-  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -323,11 +323,6 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
-  -site-file | --site-file | --site-fil | --site-fi | --site-f)
-    ac_prev=sitefile ;;
-  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
-    sitefile="$ac_optarg" ;;
-
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -493,16 +488,12 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
-  if test -z "$CONFIG_SITE"; then
-    if test "x$prefix" != xNONE; then
-      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-    else
-      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-    fi
+if test -z "$CONFIG_SITE"; then
+  if test "x$prefix" != xNONE; then
+    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+  else
+    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
   fi
-else
-  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -544,9 +535,18 @@ fi
 
 
 # The nfs-utils version
-VERSION="0.1.8.1"
+VERSION="0.3.2"
 
 
+# Check whether --with-release or --without-release was given.
+if test "${with_release+set}" = set; then
+  withval="$with_release"
+  RELEASE=$withval
+else
+  RELEASE=1
+fi
+
+       
 # Check whether --with-statedir or --without-statedir was given.
 if test "${with_statedir+set}" = set; then
   withval="$with_statedir"
@@ -1427,16 +1427,55 @@ fi
 
 
 
+echo $ac_n "checking for the tcp wrapper library""... $ac_c" 1>&6
+echo "configure:1432: checking for the tcp wrapper library" >&5
+  if eval "test \"`echo '$''{'knfsd_cv_tcp_wrapper'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  old_LIBS="$LIBS"
+   LIBS="$LIBS -lwrap $LIBNSL"
+   cat > conftest.$ac_ext <<EOF
+#line 1439 "configure"
+#include "confdefs.h"
+
+      int deny_severity = 0;
+      int allow_severity = 0;
+int main() {
+return hosts_ctl ("nfsd", "", "")
+; return 0; }
+EOF
+if { (eval echo configure:1448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  knfsd_cv_tcp_wrapper=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  knfsd_cv_tcp_wrapper=no
+fi
+rm -f conftest*
+   LIBS="$old_LIBS"
+fi
+
+  echo "$ac_t""$knfsd_cv_tcp_wrapper" 1>&6
+  if test "$knfsd_cv_tcp_wrapper" = yes; then
+    CFLAGS="$CFLAGS -DHAVE_TCP_WRAPPER"
+    CXXFLAGS="$CXXFLAGS -DHAVE_TCP_WRAPPER"
+    LIBWRAP="-lwrap"
+  fi
+
+
+
 
 for ac_func in innetgr
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1435: checking for $ac_func" >&5
+echo "configure:1474: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1440 "configure"
+#line 1479 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -1459,7 +1498,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:1463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -1626,6 +1665,7 @@ s%@oldincludedir@%$oldincludedir%g
 s%@infodir@%$infodir%g
 s%@mandir@%$mandir%g
 s%@VERSION@%$VERSION%g
+s%@RELEASE@%$RELEASE%g
 s%@statedir@%$statedir%g
 s%@enable_nfsv3@%$enable_nfsv3%g
 s%@kprefix@%$kprefix%g
@@ -1640,6 +1680,7 @@ s%@LIBSOCKET@%$LIBSOCKET%g
 s%@LIBNSL@%$LIBNSL%g
 s%@LIBCRYPT@%$LIBCRYPT%g
 s%@LIBBSD@%$LIBBSD%g
+s%@LIBWRAP@%$LIBWRAP%g
 
 CEOF
 EOF