home *** CD-ROM | disk | FTP | other *** search
/ PC-Online 1996 May / PCOnline_05_1996.bin / linux / source / a / bin / fileutil.12 / fileutil / fileutils-3.12 / configure < prev    next >
Encoding:
Text File  |  1994-11-01  |  90.7 KB  |  3,737 lines

  1. #!/bin/sh
  2.  
  3. # Guess values for system-dependent variables and create Makefiles.
  4. # Generated automatically using autoconf version 2.0 
  5. # Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
  6. #
  7. # This configure script is free software; the Free Software Foundation
  8. # gives unlimited permission to copy, distribute and modify it.
  9.  
  10. # Defaults:
  11. ac_help=
  12. ac_default_prefix=/usr/local
  13. # Any additions from configure.in:
  14.  
  15. # Omit some internal or obsolete options to make the list less imposing.
  16. ac_usage="Usage: configure [options] [host]
  17. Options: [defaults in brackets after descriptions]
  18. Configuration:
  19.   --cache-file=FILE       cache test results in FILE
  20.   --help                  print this message
  21.   --no-create             do not create output files
  22.   --quiet, --silent       do not print \`checking...' messages
  23.   --version               print the version of autoconf that created configure
  24. Directory and file names:
  25.   --prefix=PREFIX         install architecture-independent files in PREFIX
  26.                           [$ac_default_prefix]
  27.   --exec-prefix=PREFIX    install architecture-dependent files in PREFIX
  28.                           [same as prefix]
  29.   --srcdir=DIR            find the sources in DIR [configure dir or ..]
  30.   --program-prefix=PREFIX prepend PREFIX to installed program names
  31.   --program-suffix=SUFFIX append SUFFIX to installed program names
  32.   --program-transform-name=PROGRAM run sed PROGRAM on installed program names
  33. Host type:
  34.   --build=BUILD           configure for building on BUILD [BUILD=HOST]
  35.   --host=HOST             configure for HOST [guessed]
  36.   --target=TARGET         configure for TARGET [TARGET=HOST]
  37. Features and packages:
  38.   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  39.   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  40.   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  41.   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  42.   --x-includes=DIR        X include files are in DIR
  43.   --x-libraries=DIR       X library files are in DIR
  44. --enable and --with options recognized:$ac_help"
  45.  
  46. # Initialize some variables set by options.
  47. # The variables have the same names as the options, with
  48. # dashes changed to underlines.
  49. build=NONE
  50. cache_file=./config.cache
  51. exec_prefix=NONE
  52. host=NONE
  53. no_create=
  54. nonopt=NONE
  55. no_recursion=
  56. prefix=NONE
  57. program_prefix=NONE
  58. program_suffix=NONE
  59. program_transform_name=s,x,x,
  60. silent=
  61. site=
  62. srcdir=
  63. target=NONE
  64. verbose=
  65. x_includes=NONE
  66. x_libraries=NONE
  67.  
  68. # Initialize some other variables.
  69. subdirs=
  70.  
  71. ac_prev=
  72. for ac_option
  73. do
  74.  
  75.   # If the previous option needs an argument, assign it.
  76.   if test -n "$ac_prev"; then
  77.     eval "$ac_prev=\$ac_option"
  78.     ac_prev=
  79.     continue
  80.   fi
  81.  
  82.   case "$ac_option" in
  83.   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  84.   *) ac_optarg= ;;
  85.   esac
  86.  
  87.   # Accept the important Cygnus configure options, so we can diagnose typos.
  88.  
  89.   case "$ac_option" in
  90.  
  91.   -build | --build | --buil | --bui | --bu | --b)
  92.     ac_prev=build ;;
  93.   -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  94.     build="$ac_optarg" ;;
  95.  
  96.   -cache-file | --cache-file | --cache-fil | --cache-fi \
  97.   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  98.     ac_prev=cache_file ;;
  99.   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  100.   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  101.     cache_file="$ac_optarg" ;;
  102.  
  103.   -disable-* | --disable-*)
  104.     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  105.     # Reject names that are not valid shell variable names.
  106.     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  107.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  108.     fi
  109.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  110.     eval "enable_${ac_feature}=no" ;;
  111.  
  112.   -enable-* | --enable-*)
  113.     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  114.     # Reject names that are not valid shell variable names.
  115.     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  116.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  117.     fi
  118.     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  119.     case "$ac_option" in
  120.       *=*) ;;
  121.       *) ac_optarg=yes ;;
  122.     esac
  123.     eval "enable_${ac_feature}='$ac_optarg'" ;;
  124.  
  125.   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  126.   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  127.   | --exec | --exe | --ex)
  128.     ac_prev=exec_prefix ;;
  129.   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  130.   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  131.   | --exec=* | --exe=* | --ex=*)
  132.     exec_prefix="$ac_optarg" ;;
  133.  
  134.   -gas | --gas | --ga | --g)
  135.     # Obsolete; use --with-gas.
  136.     with_gas=yes ;;
  137.  
  138.   -help | --help | --hel | --he)
  139.     cat << EOF
  140. $ac_usage
  141. EOF
  142.     exit 0 ;;
  143.  
  144.   -host | --host | --hos | --ho)
  145.     ac_prev=host ;;
  146.   -host=* | --host=* | --hos=* | --ho=*)
  147.     host="$ac_optarg" ;;
  148.  
  149.   -nfp | --nfp | --nf)
  150.     # Obsolete; use --without-fp.
  151.     with_fp=no ;;
  152.  
  153.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  154.   | --no-cr | --no-c)
  155.     no_create=yes ;;
  156.  
  157.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  158.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  159.     no_recursion=yes ;;
  160.  
  161.   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  162.     ac_prev=prefix ;;
  163.   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  164.     prefix="$ac_optarg" ;;
  165.  
  166.   -program-prefix | --program-prefix | --program-prefi | --program-pref \
  167.   | --program-pre | --program-pr | --program-p)
  168.     ac_prev=program_prefix ;;
  169.   -program-prefix=* | --program-prefix=* | --program-prefi=* \
  170.   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  171.     program_prefix="$ac_optarg" ;;
  172.  
  173.   -program-suffix | --program-suffix | --program-suffi | --program-suff \
  174.   | --program-suf | --program-su | --program-s)
  175.     ac_prev=program_suffix ;;
  176.   -program-suffix=* | --program-suffix=* | --program-suffi=* \
  177.   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  178.     program_suffix="$ac_optarg" ;;
  179.  
  180.   -program-transform-name | --program-transform-name \
  181.   | --program-transform-nam | --program-transform-na \
  182.   | --program-transform-n | --program-transform- \
  183.   | --program-transform | --program-transfor \
  184.   | --program-transfo | --program-transf \
  185.   | --program-trans | --program-tran \
  186.   | --progr-tra | --program-tr | --program-t)
  187.     ac_prev=program_transform_name ;;
  188.   -program-transform-name=* | --program-transform-name=* \
  189.   | --program-transform-nam=* | --program-transform-na=* \
  190.   | --program-transform-n=* | --program-transform-=* \
  191.   | --program-transform=* | --program-transfor=* \
  192.   | --program-transfo=* | --program-transf=* \
  193.   | --program-trans=* | --program-tran=* \
  194.   | --progr-tra=* | --program-tr=* | --program-t=*)
  195.     program_transform_name="$ac_optarg" ;;
  196.  
  197.   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  198.   | -silent | --silent | --silen | --sile | --sil)
  199.     silent=yes ;;
  200.  
  201.   -site | --site | --sit)
  202.     ac_prev=site ;;
  203.   -site=* | --site=* | --sit=*)
  204.     site="$ac_optarg" ;;
  205.  
  206.   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  207.     ac_prev=srcdir ;;
  208.   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  209.     srcdir="$ac_optarg" ;;
  210.  
  211.   -target | --target | --targe | --targ | --tar | --ta | --t)
  212.     ac_prev=target ;;
  213.   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  214.     target="$ac_optarg" ;;
  215.  
  216.   -v | -verbose | --verbose | --verbos | --verbo | --verb)
  217.     verbose=yes ;;
  218.  
  219.   -version | --version | --versio | --versi | --vers)
  220.     echo "configure generated by autoconf version 2.0"
  221.     exit 0 ;;
  222.  
  223.   -with-* | --with-*)
  224.     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  225.     # Reject names that are not valid shell variable names.
  226.     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  227.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  228.     fi
  229.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  230.     case "$ac_option" in
  231.       *=*) ;;
  232.       *) ac_optarg=yes ;;
  233.     esac
  234.     eval "with_${ac_package}='$ac_optarg'" ;;
  235.  
  236.   -without-* | --without-*)
  237.     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  238.     # Reject names that are not valid shell variable names.
  239.     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  240.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  241.     fi
  242.     ac_package=`echo $ac_package| sed 's/-/_/g'`
  243.     eval "with_${ac_package}=no" ;;
  244.  
  245.   --x)
  246.     # Obsolete; use --with-x.
  247.     with_x=yes ;;
  248.  
  249.   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  250.   | --x-incl | --x-inc | --x-in | --x-i)
  251.     ac_prev=x_includes ;;
  252.   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  253.   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  254.     x_includes="$ac_optarg" ;;
  255.  
  256.   -x-libraries | --x-libraries | --x-librarie | --x-librari \
  257.   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  258.     ac_prev=x_libraries ;;
  259.   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  260.   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  261.     x_libraries="$ac_optarg" ;;
  262.  
  263.   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  264.     ;;
  265.  
  266.   *) 
  267.     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  268.       echo "configure: warning: $ac_option: invalid host type" 1>&2
  269.     fi
  270.     if test "x$nonopt" != xNONE; then
  271.       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  272.     fi
  273.     nonopt="$ac_option"
  274.     ;;
  275.  
  276.   esac
  277. done
  278.  
  279. if test -n "$ac_prev"; then
  280.   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  281. fi
  282.  
  283. trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
  284.  
  285. # File descriptor usage:
  286. # 0 unused; standard input
  287. # 1 file creation
  288. # 2 errors and warnings
  289. # 3 unused; some systems may open it to /dev/tty
  290. # 4 checking for... messages and results
  291. # 5 compiler messages saved in config.log
  292. if test "$silent" = yes; then
  293.   exec 4>/dev/null
  294. else
  295.   exec 4>&1
  296. fi
  297. exec 5>./config.log
  298.  
  299. echo "\
  300. This file contains any messages produced by compilers while
  301. running configure, to aid debugging if configure makes a mistake.
  302. " 1>&5
  303.  
  304. # Strip out --no-create and --no-recursion so they do not pile up.
  305. # Also quote any args containing shell metacharacters.
  306. ac_configure_args=
  307. for ac_arg
  308. do
  309.   case "$ac_arg" in
  310.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  311.   | --no-cr | --no-c) ;;
  312.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  313.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  314.   *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  315.   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  316.   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  317.   esac
  318. done
  319.  
  320. # NLS nuisances.
  321. # Only set LANG and LC_ALL to C if already set.
  322. # These must not be set unconditionally because not all systems understand
  323. # e.g. LANG=C (notably SCO).
  324. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  325. if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
  326.  
  327. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  328. rm -rf conftest* confdefs.h
  329. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  330. echo > confdefs.h
  331.  
  332. # A filename unique to this package, relative to the directory that
  333. # configure is in, which we can look for to find out if srcdir is correct.
  334. ac_unique_file=src/ls.c
  335.  
  336. # Find the source files, if location was not specified.
  337. if test -z "$srcdir"; then
  338.   ac_srcdir_defaulted=yes
  339.   # Try the directory containing this script, then its parent.
  340.   ac_prog=$0
  341.   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  342.   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  343.   srcdir=$ac_confdir
  344.   if test ! -r $srcdir/$ac_unique_file; then
  345.     srcdir=..
  346.   fi
  347. else
  348.   ac_srcdir_defaulted=no
  349. fi
  350. if test ! -r $srcdir/$ac_unique_file; then
  351.   if test "$ac_srcdir_defaulted" = yes; then
  352.     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  353.   else
  354.     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  355.   fi
  356. fi
  357. srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
  358.  
  359. # Prefer explicitly selected file to automatically selected ones.
  360. if test -z "$CONFIG_SITE"; then
  361.   if test "x$prefix" != xNONE; then
  362.     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  363.   else
  364.     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  365.   fi
  366. fi
  367. for ac_site_file in $CONFIG_SITE; do
  368.   if test -r "$ac_site_file"; then
  369.     echo "loading site script $ac_site_file"
  370.     . "$ac_site_file"
  371.   fi
  372. done
  373.  
  374. if test -r "$cache_file"; then
  375.   echo "loading cache $cache_file"
  376.   . $cache_file
  377. else
  378.   echo "creating cache $cache_file"
  379.   > $cache_file
  380. fi
  381.  
  382. ac_ext=c
  383. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  384. ac_cpp='$CPP $CPPFLAGS'
  385. ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
  386. ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
  387.  
  388. if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  389.   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  390.   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  391.     ac_n= ac_c='
  392. ' ac_t='    '
  393.   else
  394.     ac_n=-n ac_c= ac_t=
  395.   fi
  396. else
  397.   ac_n= ac_c='\c' ac_t=
  398. fi
  399.  
  400.  
  401.  
  402. echo $ac_n "checking whether ${MAKE-make} sets \$MAKE""... $ac_c" 1>&4
  403. set dummy ${MAKE-make}; ac_make=$2
  404. if eval "test \"`echo '${'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
  405.   echo $ac_n "(cached) $ac_c" 1>&4
  406. else
  407.   cat > conftestmake <<\EOF
  408. all:
  409.     @echo 'ac_maketemp="${MAKE}"'
  410. EOF
  411. # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
  412. eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
  413. if test -n "$ac_maketemp"; then
  414.   eval ac_cv_prog_make_${ac_make}_set=yes
  415. else
  416.   eval ac_cv_prog_make_${ac_make}_set=no
  417. fi
  418. rm -f conftestmake
  419. fi
  420. if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
  421.   echo "$ac_t""yes" 1>&4
  422.   SET_MAKE=
  423. else
  424.   echo "$ac_t""no" 1>&4
  425.   SET_MAKE="MAKE=${MAKE-make}"
  426. fi
  427.  
  428.  
  429. # Extract the first word of "ln", so it can be a program name with args.
  430. set dummy ln; ac_word=$2
  431. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  432. if eval "test \"`echo '${'ac_cv_path_LN'+set}'`\" = set"; then
  433.   echo $ac_n "(cached) $ac_c" 1>&4
  434. else
  435.   case "$LN" in
  436.   /*)
  437.   ac_cv_path_LN="$LN" # Let the user override the test with a path.
  438.   ;;
  439.   *)
  440.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  441.   for ac_dir in $PATH; do
  442.     test -z "$ac_dir" && ac_dir=.
  443.     if test -f $ac_dir/$ac_word; then
  444.       ac_cv_path_LN="$ac_dir/$ac_word"
  445.       break
  446.     fi
  447.   done
  448.   IFS="$ac_save_ifs"
  449.   test -z "$ac_cv_path_LN" && ac_cv_path_LN="ln"
  450.   ;;
  451. esac
  452. fi
  453. LN="$ac_cv_path_LN"
  454. if test -n "$LN"; then
  455.   echo "$ac_t""$LN" 1>&4
  456. else
  457.   echo "$ac_t""no" 1>&4
  458. fi
  459. # Extract the first word of "mv", so it can be a program name with args.
  460. set dummy mv; ac_word=$2
  461. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  462. if eval "test \"`echo '${'ac_cv_path_MV'+set}'`\" = set"; then
  463.   echo $ac_n "(cached) $ac_c" 1>&4
  464. else
  465.   case "$MV" in
  466.   /*)
  467.   ac_cv_path_MV="$MV" # Let the user override the test with a path.
  468.   ;;
  469.   *)
  470.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  471.   for ac_dir in $PATH; do
  472.     test -z "$ac_dir" && ac_dir=.
  473.     if test -f $ac_dir/$ac_word; then
  474.       ac_cv_path_MV="$ac_dir/$ac_word"
  475.       break
  476.     fi
  477.   done
  478.   IFS="$ac_save_ifs"
  479.   test -z "$ac_cv_path_MV" && ac_cv_path_MV="mv"
  480.   ;;
  481. esac
  482. fi
  483. MV="$ac_cv_path_MV"
  484. if test -n "$MV"; then
  485.   echo "$ac_t""$MV" 1>&4
  486. else
  487.   echo "$ac_t""no" 1>&4
  488. fi
  489. # Extract the first word of "rm", so it can be a program name with args.
  490. set dummy rm; ac_word=$2
  491. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  492. if eval "test \"`echo '${'ac_cv_path_RM'+set}'`\" = set"; then
  493.   echo $ac_n "(cached) $ac_c" 1>&4
  494. else
  495.   case "$RM" in
  496.   /*)
  497.   ac_cv_path_RM="$RM" # Let the user override the test with a path.
  498.   ;;
  499.   *)
  500.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  501.   for ac_dir in $PATH; do
  502.     test -z "$ac_dir" && ac_dir=.
  503.     if test -f $ac_dir/$ac_word; then
  504.       ac_cv_path_RM="$ac_dir/$ac_word"
  505.       break
  506.     fi
  507.   done
  508.   IFS="$ac_save_ifs"
  509.   test -z "$ac_cv_path_RM" && ac_cv_path_RM="rm"
  510.   ;;
  511. esac
  512. fi
  513. RM="$ac_cv_path_RM"
  514. if test -n "$RM"; then
  515.   echo "$ac_t""$RM" 1>&4
  516. else
  517.   echo "$ac_t""no" 1>&4
  518. fi
  519. # Extract the first word of "gcc", so it can be a program name with args.
  520. set dummy gcc; ac_word=$2
  521. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  522. if eval "test \"`echo '${'ac_cv_prog_CC'+set}'`\" = set"; then
  523.   echo $ac_n "(cached) $ac_c" 1>&4
  524. else
  525.   if test -n "$CC"; then
  526.   ac_cv_prog_CC="$CC" # Let the user override the test.
  527. else
  528.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  529.   for ac_dir in $PATH; do
  530.     test -z "$ac_dir" && ac_dir=.
  531.     if test -f $ac_dir/$ac_word; then
  532.       ac_cv_prog_CC="gcc"
  533.       break
  534.     fi
  535.   done
  536.   IFS="$ac_save_ifs"
  537.   test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
  538. fi
  539. fi
  540. CC="$ac_cv_prog_CC"
  541. if test -n "$CC"; then
  542.   echo "$ac_t""$CC" 1>&4
  543. else
  544.   echo "$ac_t""no" 1>&4
  545. fi
  546.  
  547.  
  548. echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&4
  549. if eval "test \"`echo '${'ac_cv_prog_gcc'+set}'`\" = set"; then
  550.   echo $ac_n "(cached) $ac_c" 1>&4
  551. else
  552.   cat > conftest.c <<EOF
  553. #ifdef __GNUC__
  554.   yes;
  555. #endif
  556. EOF
  557. if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
  558.   ac_cv_prog_gcc=yes
  559. else
  560.   ac_cv_prog_gcc=no
  561. fi
  562. fi
  563. echo "$ac_t""$ac_cv_prog_gcc" 1>&4
  564. if test $ac_cv_prog_gcc = yes; then
  565.   GCC=yes
  566.   if test "${CFLAGS+set}" != set; then
  567.     echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&4
  568. if eval "test \"`echo '${'ac_cv_prog_gcc_g'+set}'`\" = set"; then
  569.   echo $ac_n "(cached) $ac_c" 1>&4
  570. else
  571.   echo 'void f(){}' > conftest.c
  572. if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
  573.   ac_cv_prog_gcc_g=yes
  574. else
  575.   ac_cv_prog_gcc_g=no
  576. fi
  577. rm -f conftest*
  578.  
  579. fi
  580.     echo "$ac_t""$ac_cv_prog_gcc_g" 1>&4
  581.     if test $ac_cv_prog_gcc_g = yes; then
  582.       CFLAGS="-g -O"
  583.     else
  584.       CFLAGS="-O"
  585.     fi
  586.   fi
  587. else
  588.   GCC=
  589.   test "${CFLAGS+set}" = set || CFLAGS="-g"
  590. fi
  591.  
  592. echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&4
  593. # On Suns, sometimes $CPP names a directory.
  594. if test -n "$CPP" && test -d "$CPP"; then
  595.   CPP=
  596. fi
  597. if test -z "$CPP"; then
  598. if eval "test \"`echo '${'ac_cv_prog_CPP'+set}'`\" = set"; then
  599.   echo $ac_n "(cached) $ac_c" 1>&4
  600. else
  601.     # This must be in double quotes, not single quotes, because CPP may get
  602.   # substituted into the Makefile and "${CC-cc}" will confuse make.
  603.   CPP="${CC-cc} -E"
  604.   # On the NeXT, cc -E runs the code through the compiler's parser,
  605.   # not just through cpp.
  606.   cat > conftest.$ac_ext <<EOF
  607. #line 608 "configure"
  608. #include "confdefs.h"
  609. #include <assert.h>
  610. Syntax Error
  611. EOF
  612. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  613. ac_err=`grep -v '^ *+' conftest.out`
  614. if test -z "$ac_err"; then
  615.   :
  616. else
  617.   echo "$ac_err" >&5
  618.   rm -rf conftest*
  619.   CPP="${CC-cc} -E -traditional-cpp"
  620.   cat > conftest.$ac_ext <<EOF
  621. #line 622 "configure"
  622. #include "confdefs.h"
  623. #include <assert.h>
  624. Syntax Error
  625. EOF
  626. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  627. ac_err=`grep -v '^ *+' conftest.out`
  628. if test -z "$ac_err"; then
  629.   :
  630. else
  631.   echo "$ac_err" >&5
  632.   rm -rf conftest*
  633.   CPP=/lib/cpp
  634. fi
  635. rm -f conftest*
  636. fi
  637. rm -f conftest*
  638.   ac_cv_prog_CPP="$CPP"
  639. fi
  640. fi
  641. CPP="$ac_cv_prog_CPP"
  642. echo "$ac_t""$CPP" 1>&4
  643.  
  644. if test $ac_cv_prog_gcc = yes; then
  645.   echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&4
  646. if eval "test \"`echo '${'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
  647.   echo $ac_n "(cached) $ac_c" 1>&4
  648. else
  649.     ac_pattern="Autoconf.*'x'"
  650.   cat > conftest.$ac_ext <<EOF
  651. #line 652 "configure"
  652. #include "confdefs.h"
  653. #include <sgtty.h>
  654. Autoconf TIOCGETP
  655. EOF
  656. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  657.   egrep "$ac_pattern" >/dev/null 2>&1; then
  658.   rm -rf conftest*
  659.   ac_cv_prog_gcc_traditional=yes
  660. else
  661.   rm -rf conftest*
  662.   ac_cv_prog_gcc_traditional=no
  663. fi
  664. rm -f conftest*
  665.  
  666.  
  667.   if test $ac_cv_prog_gcc_traditional = no; then
  668.     cat > conftest.$ac_ext <<EOF
  669. #line 670 "configure"
  670. #include "confdefs.h"
  671. #include <termio.h>
  672. Autoconf TCGETA
  673. EOF
  674. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  675.   egrep "$ac_pattern" >/dev/null 2>&1; then
  676.   rm -rf conftest*
  677.   ac_cv_prog_gcc_traditional=yes
  678. fi
  679. rm -f conftest*
  680.  
  681.   fi
  682. fi
  683.   echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&4
  684.   if test $ac_cv_prog_gcc_traditional = yes; then
  685.     CC="$CC -traditional"
  686.   fi
  687. fi
  688.  
  689. ac_aux_dir=
  690. for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  691.   if test -f $ac_dir/install-sh; then
  692.     ac_aux_dir=$ac_dir
  693.     ac_install_sh="$ac_aux_dir/install-sh -c"
  694.     break
  695.   elif test -f $ac_dir/install.sh; then
  696.     ac_aux_dir=$ac_dir
  697.     ac_install_sh="$ac_aux_dir/install.sh -c"
  698.     break
  699.   fi
  700. done
  701. if test -z "$ac_aux_dir"; then
  702.   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
  703. fi
  704. ac_config_guess=$ac_aux_dir/config.guess
  705. ac_config_sub=$ac_aux_dir/config.sub
  706. ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
  707.  
  708. # Find a good install program.  We prefer a C program (faster),
  709. # so one script is as good as another.  But avoid the broken or
  710. # incompatible versions:
  711. # SysV /etc/install, /usr/sbin/install
  712. # SunOS /usr/etc/install
  713. # IRIX /sbin/install
  714. # AIX /bin/install
  715. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  716. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  717. # ./install, which can be erroneously created by make from ./install.sh.
  718. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&4
  719. if test -z "$INSTALL"; then
  720. if eval "test \"`echo '${'ac_cv_path_install'+set}'`\" = set"; then
  721.   echo $ac_n "(cached) $ac_c" 1>&4
  722. else
  723.     IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  724.   for ac_dir in $PATH; do
  725.     case "$ac_dir" in
  726.     ''|.|/etc|/usr/sbin|/usr/etc|/sbin|/usr/afsws/bin|/usr/ucb) ;;
  727.     *)
  728.       # OSF1 and SCO ODT 3.0 have their own names for install.
  729.       for ac_prog in ginstall installbsd scoinst install; do
  730.         if test -f $ac_dir/$ac_prog; then
  731.       if test $ac_prog = install &&
  732.             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  733.         # AIX install.  It has an incompatible calling convention.
  734.         # OSF/1 installbsd also uses dspmsg, but is usable.
  735.         :
  736.       else
  737.         ac_cv_path_install="$ac_dir/$ac_prog -c"
  738.         break 2
  739.       fi
  740.     fi
  741.       done
  742.       ;;
  743.     esac
  744.   done
  745.   IFS="$ac_save_ifs"
  746.   # As a last resort, use the slow shell script.
  747.   test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
  748. fi
  749.   INSTALL="$ac_cv_path_install"
  750. fi
  751. echo "$ac_t""$INSTALL" 1>&4
  752.  
  753. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  754. # It thinks the first close brace ends the variable substitution.
  755. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  756.  
  757. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  758.  
  759. # Extract the first word of "ranlib", so it can be a program name with args.
  760. set dummy ranlib; ac_word=$2
  761. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  762. if eval "test \"`echo '${'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  763.   echo $ac_n "(cached) $ac_c" 1>&4
  764. else
  765.   if test -n "$RANLIB"; then
  766.   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  767. else
  768.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  769.   for ac_dir in $PATH; do
  770.     test -z "$ac_dir" && ac_dir=.
  771.     if test -f $ac_dir/$ac_word; then
  772.       ac_cv_prog_RANLIB="ranlib"
  773.       break
  774.     fi
  775.   done
  776.   IFS="$ac_save_ifs"
  777.   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  778. fi
  779. fi
  780. RANLIB="$ac_cv_prog_RANLIB"
  781. if test -n "$RANLIB"; then
  782.   echo "$ac_t""$RANLIB" 1>&4
  783. else
  784.   echo "$ac_t""no" 1>&4
  785. fi
  786.  
  787. for ac_prog in 'bison -y' byacc
  788. do
  789. # Extract the first word of "$ac_prog", so it can be a program name with args.
  790. set dummy $ac_prog; ac_word=$2
  791. echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  792. if eval "test \"`echo '${'ac_cv_prog_YACC'+set}'`\" = set"; then
  793.   echo $ac_n "(cached) $ac_c" 1>&4
  794. else
  795.   if test -n "$YACC"; then
  796.   ac_cv_prog_YACC="$YACC" # Let the user override the test.
  797. else
  798.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  799.   for ac_dir in $PATH; do
  800.     test -z "$ac_dir" && ac_dir=.
  801.     if test -f $ac_dir/$ac_word; then
  802.       ac_cv_prog_YACC="$ac_prog"
  803.       break
  804.     fi
  805.   done
  806.   IFS="$ac_save_ifs"
  807. fi
  808. fi
  809. YACC="$ac_cv_prog_YACC"
  810. if test -n "$YACC"; then
  811.   echo "$ac_t""$YACC" 1>&4
  812. else
  813.   echo "$ac_t""no" 1>&4
  814. fi
  815.  
  816. test -n "$YACC" && break
  817. done
  818. test -n "$YACC" || YACC="yacc"
  819.  
  820. echo $ac_n "checking for AIX""... $ac_c" 1>&4
  821. cat > conftest.$ac_ext <<EOF
  822. #line 823 "configure"
  823. #include "confdefs.h"
  824. #ifdef _AIX
  825.   yes
  826. #endif
  827.  
  828. EOF
  829. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  830.   egrep "yes" >/dev/null 2>&1; then
  831.   rm -rf conftest*
  832.   echo "$ac_t""yes" 1>&4; cat >> confdefs.h <<\EOF
  833. #define _ALL_SOURCE 1
  834. EOF
  835.  
  836. else
  837.   rm -rf conftest*
  838.   echo "$ac_t""no" 1>&4
  839. fi
  840. rm -f conftest*
  841.  
  842.  
  843. ac_safe=`echo "minix/config.h" | tr './\055' '___'`
  844. echo $ac_n "checking for minix/config.h""... $ac_c" 1>&4
  845. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  846.   echo $ac_n "(cached) $ac_c" 1>&4
  847. else
  848.   cat > conftest.$ac_ext <<EOF
  849. #line 850 "configure"
  850. #include "confdefs.h"
  851. #include <minix/config.h>
  852. EOF
  853. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  854. ac_err=`grep -v '^ *+' conftest.out`
  855. if test -z "$ac_err"; then
  856.   rm -rf conftest*
  857.   eval "ac_cv_header_$ac_safe=yes"
  858. else
  859.   echo "$ac_err" >&5
  860.   rm -rf conftest*
  861.   eval "ac_cv_header_$ac_safe=no"
  862. fi
  863. rm -f conftest*
  864. fi
  865. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  866.   echo "$ac_t""yes" 1>&4
  867.   MINIX=yes
  868. else
  869.   echo "$ac_t""no" 1>&4
  870. MINIX=
  871. fi
  872.  
  873. if test "$MINIX" = yes; then
  874.   cat >> confdefs.h <<\EOF
  875. #define _POSIX_SOURCE 1
  876. EOF
  877.  
  878.   cat >> confdefs.h <<\EOF
  879. #define _POSIX_1_SOURCE 2
  880. EOF
  881.  
  882.   cat >> confdefs.h <<\EOF
  883. #define _MINIX 1
  884. EOF
  885.  
  886. fi
  887.  
  888. echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&4
  889. if test -d /etc/conf/kconfig.d &&
  890.   grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
  891. then
  892.   echo "$ac_t""yes" 1>&4
  893.   ISC=yes # If later tests want to check for ISC.
  894.   cat >> confdefs.h <<\EOF
  895. #define _POSIX_SOURCE 1
  896. EOF
  897.  
  898.   if test "$GCC" = yes; then
  899.     CC="$CC -posix"
  900.   else
  901.     CC="$CC -Xp"
  902.   fi
  903. else
  904.   echo "$ac_t""no" 1>&4
  905.   ISC=
  906. fi
  907.  
  908. echo $ac_n "checking whether sys/types.h defines makedev""... $ac_c" 1>&4
  909. if eval "test \"`echo '${'ac_cv_header_sys_types_h_makedev'+set}'`\" = set"; then
  910.   echo $ac_n "(cached) $ac_c" 1>&4
  911. else
  912.   cat > conftest.$ac_ext <<EOF
  913. #line 914 "configure"
  914. #include "confdefs.h"
  915. #include <sys/types.h>
  916. int main() { return 0; }
  917. int t() {
  918. return makedev(0, 0);
  919. ; return 0; }
  920. EOF
  921. if eval $ac_link; then
  922.   rm -rf conftest*
  923.   ac_cv_header_sys_types_h_makedev=yes
  924. else
  925.   rm -rf conftest*
  926.   ac_cv_header_sys_types_h_makedev=no
  927. fi
  928. rm -f conftest*
  929.  
  930.  
  931. fi
  932. echo "$ac_t""$ac_cv_header_sys_types_h_makedev" 1>&4
  933.  
  934. if test $ac_cv_header_sys_types_h_makedev = no; then
  935. ac_safe=`echo "sys/mkdev.h" | tr './\055' '___'`
  936. echo $ac_n "checking for sys/mkdev.h""... $ac_c" 1>&4
  937. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  938.   echo $ac_n "(cached) $ac_c" 1>&4
  939. else
  940.   cat > conftest.$ac_ext <<EOF
  941. #line 942 "configure"
  942. #include "confdefs.h"
  943. #include <sys/mkdev.h>
  944. EOF
  945. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  946. ac_err=`grep -v '^ *+' conftest.out`
  947. if test -z "$ac_err"; then
  948.   rm -rf conftest*
  949.   eval "ac_cv_header_$ac_safe=yes"
  950. else
  951.   echo "$ac_err" >&5
  952.   rm -rf conftest*
  953.   eval "ac_cv_header_$ac_safe=no"
  954. fi
  955. rm -f conftest*
  956. fi
  957. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  958.   echo "$ac_t""yes" 1>&4
  959.   cat >> confdefs.h <<\EOF
  960. #define MAJOR_IN_MKDEV 1
  961. EOF
  962.  
  963. else
  964.   echo "$ac_t""no" 1>&4
  965. fi
  966.  
  967.  
  968.   if test $ac_cv_header_sys_mkdev_h = no; then
  969. ac_safe=`echo "sys/sysmacros.h" | tr './\055' '___'`
  970. echo $ac_n "checking for sys/sysmacros.h""... $ac_c" 1>&4
  971. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  972.   echo $ac_n "(cached) $ac_c" 1>&4
  973. else
  974.   cat > conftest.$ac_ext <<EOF
  975. #line 976 "configure"
  976. #include "confdefs.h"
  977. #include <sys/sysmacros.h>
  978. EOF
  979. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  980. ac_err=`grep -v '^ *+' conftest.out`
  981. if test -z "$ac_err"; then
  982.   rm -rf conftest*
  983.   eval "ac_cv_header_$ac_safe=yes"
  984. else
  985.   echo "$ac_err" >&5
  986.   rm -rf conftest*
  987.   eval "ac_cv_header_$ac_safe=no"
  988. fi
  989. rm -f conftest*
  990. fi
  991. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  992.   echo "$ac_t""yes" 1>&4
  993.   cat >> confdefs.h <<\EOF
  994. #define MAJOR_IN_SYSMACROS 1
  995. EOF
  996.  
  997. else
  998.   echo "$ac_t""no" 1>&4
  999. fi
  1000.  
  1001.   fi
  1002. fi
  1003.  
  1004.  
  1005. ac_header_dirent=no
  1006. for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
  1007. do
  1008. ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
  1009. echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&4
  1010. if eval "test \"`echo '${'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
  1011.   echo $ac_n "(cached) $ac_c" 1>&4
  1012. else
  1013.   cat > conftest.$ac_ext <<EOF
  1014. #line 1015 "configure"
  1015. #include "confdefs.h"
  1016. #include <sys/types.h>
  1017. #include <$ac_hdr>
  1018. int main() { return 0; }
  1019. int t() {
  1020. DIR *dirp = 0;
  1021. ; return 0; }
  1022. EOF
  1023. if eval $ac_compile; then
  1024.   rm -rf conftest*
  1025.   eval "ac_cv_header_dirent_$ac_safe=yes"
  1026. else
  1027.   rm -rf conftest*
  1028.   eval "ac_cv_header_dirent_$ac_safe=no"
  1029. fi
  1030. rm -f conftest*
  1031.  
  1032. fi
  1033. if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
  1034.   echo "$ac_t""yes" 1>&4
  1035.     ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  1036.   cat >> confdefs.h <<EOF
  1037. #define $ac_tr_hdr 1
  1038. EOF
  1039.  ac_header_dirent=$ac_hdr; break
  1040. else
  1041.   echo "$ac_t""no" 1>&4
  1042. fi
  1043. done
  1044. # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
  1045. if test $ac_header_dirent = dirent.h; then
  1046. echo $ac_n "checking for -ldir""... $ac_c" 1>&4
  1047. if eval "test \"`echo '${'ac_cv_lib_dir'+set}'`\" = set"; then
  1048.   echo $ac_n "(cached) $ac_c" 1>&4
  1049. else
  1050.   ac_save_LIBS="$LIBS"
  1051. LIBS="$LIBS -ldir "
  1052. cat > conftest.$ac_ext <<EOF
  1053. #line 1054 "configure"
  1054. #include "confdefs.h"
  1055.  
  1056. int main() { return 0; }
  1057. int t() {
  1058. opendir()
  1059. ; return 0; }
  1060. EOF
  1061. if eval $ac_link; then
  1062.   rm -rf conftest*
  1063.   eval "ac_cv_lib_dir=yes"
  1064. else
  1065.   rm -rf conftest*
  1066.   eval "ac_cv_lib_dir=no"
  1067. fi
  1068. rm -f conftest*
  1069. LIBS="$ac_save_LIBS"
  1070.  
  1071. fi
  1072. if eval "test \"`echo '$ac_cv_lib_'dir`\" = yes"; then
  1073.   echo "$ac_t""yes" 1>&4
  1074.   LIBS="$LIBS -ldir"
  1075. else
  1076.   echo "$ac_t""no" 1>&4
  1077. fi
  1078.  
  1079. else
  1080. echo $ac_n "checking for -lx""... $ac_c" 1>&4
  1081. if eval "test \"`echo '${'ac_cv_lib_x'+set}'`\" = set"; then
  1082.   echo $ac_n "(cached) $ac_c" 1>&4
  1083. else
  1084.   ac_save_LIBS="$LIBS"
  1085. LIBS="$LIBS -lx "
  1086. cat > conftest.$ac_ext <<EOF
  1087. #line 1088 "configure"
  1088. #include "confdefs.h"
  1089.  
  1090. int main() { return 0; }
  1091. int t() {
  1092. opendir()
  1093. ; return 0; }
  1094. EOF
  1095. if eval $ac_link; then
  1096.   rm -rf conftest*
  1097.   eval "ac_cv_lib_x=yes"
  1098. else
  1099.   rm -rf conftest*
  1100.   eval "ac_cv_lib_x=no"
  1101. fi
  1102. rm -f conftest*
  1103. LIBS="$ac_save_LIBS"
  1104.  
  1105. fi
  1106. if eval "test \"`echo '$ac_cv_lib_'x`\" = yes"; then
  1107.   echo "$ac_t""yes" 1>&4
  1108.   LIBS="$LIBS -lx"
  1109. else
  1110.   echo "$ac_t""no" 1>&4
  1111. fi
  1112.  
  1113. fi
  1114.  
  1115. # If we cannot run a trivial program, we must be cross compiling.
  1116. echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&4
  1117. if eval "test \"`echo '${'ac_cv_c_cross'+set}'`\" = set"; then
  1118.   echo $ac_n "(cached) $ac_c" 1>&4
  1119. else
  1120.   if test "$cross_compiling" = yes; then
  1121.   ac_cv_cross=yes
  1122. else
  1123. cat > conftest.$ac_ext <<EOF
  1124. #line 1125 "configure"
  1125. #include "confdefs.h"
  1126. main(){return(0);}
  1127. EOF
  1128. eval $ac_link
  1129. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1130.   ac_cv_c_cross=no
  1131. else
  1132.   ac_cv_c_cross=yes
  1133. fi
  1134. fi
  1135. rm -fr conftest*
  1136. fi
  1137. cross_compiling=$ac_cv_c_cross
  1138. echo "$ac_t""$ac_cv_c_cross" 1>&4
  1139.  
  1140. echo $ac_n "checking whether closedir returns void""... $ac_c" 1>&4
  1141. if eval "test \"`echo '${'ac_cv_func_closedir_void'+set}'`\" = set"; then
  1142.   echo $ac_n "(cached) $ac_c" 1>&4
  1143. else
  1144.   if test "$cross_compiling" = yes; then
  1145.     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  1146. else
  1147. cat > conftest.$ac_ext <<EOF
  1148. #line 1149 "configure"
  1149. #include "confdefs.h"
  1150. #include <sys/types.h>
  1151. #include <$ac_header_dirent>
  1152. int closedir(); main() { exit(closedir(opendir(".")) != 0); }
  1153. EOF
  1154. eval $ac_link
  1155. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1156.   ac_cv_func_closedir_void=no
  1157. else
  1158.   ac_cv_func_closedir_void=yes
  1159. fi
  1160. fi
  1161. rm -fr conftest*
  1162. fi
  1163. echo "$ac_t""$ac_cv_func_closedir_void" 1>&4
  1164. if test $ac_cv_func_closedir_void = yes; then
  1165.   cat >> confdefs.h <<\EOF
  1166. #define CLOSEDIR_VOID 1
  1167. EOF
  1168.  
  1169. fi
  1170.  
  1171.  
  1172. echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&4
  1173. if eval "test \"`echo '${'ac_cv_type_uid_t'+set}'`\" = set"; then
  1174.   echo $ac_n "(cached) $ac_c" 1>&4
  1175. else
  1176.   cat > conftest.$ac_ext <<EOF
  1177. #line 1178 "configure"
  1178. #include "confdefs.h"
  1179. #include <sys/types.h>
  1180. EOF
  1181. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1182.   egrep "uid_t" >/dev/null 2>&1; then
  1183.   rm -rf conftest*
  1184.   ac_cv_type_uid_t=yes
  1185. else
  1186.   rm -rf conftest*
  1187.   ac_cv_type_uid_t=no
  1188. fi
  1189. rm -f conftest*
  1190.  
  1191. fi
  1192. echo "$ac_t""$ac_cv_type_uid_t" 1>&4
  1193. if test $ac_cv_type_uid_t = no; then
  1194.   cat >> confdefs.h <<\EOF
  1195. #define uid_t int
  1196. EOF
  1197.  
  1198.   cat >> confdefs.h <<\EOF
  1199. #define gid_t int
  1200. EOF
  1201.  
  1202. fi
  1203.  
  1204. echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&4
  1205. if eval "test \"`echo '${'ac_cv_type_getgroups'+set}'`\" = set"; then
  1206.   echo $ac_n "(cached) $ac_c" 1>&4
  1207. else
  1208.   if test "$cross_compiling" = yes; then
  1209.   ac_cv_type_getgroups=cross
  1210. else
  1211. cat > conftest.$ac_ext <<EOF
  1212. #line 1213 "configure"
  1213. #include "confdefs.h"
  1214.  
  1215. /* Thanks to Mike Rendell for this test.  */
  1216. #include <sys/types.h>
  1217. #define NGID 256
  1218. #undef MAX
  1219. #define MAX(x, y) ((x) > (y) ? (x) : (y))
  1220. main()
  1221. {
  1222.   gid_t gidset[NGID];
  1223.   int i, n;
  1224.   union { gid_t gval; long lval; }  val;
  1225.  
  1226.   val.lval = -1;
  1227.   for (i = 0; i < NGID; i++)
  1228.     gidset[i] = val.gval;
  1229.   n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
  1230.                  gidset);
  1231.   /* Exit non-zero if getgroups seems to require an array of ints.  This
  1232.      happens when gid_t is short but getgroups modifies an array of ints.  */
  1233.   exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
  1234. }
  1235.  
  1236. EOF
  1237. eval $ac_link
  1238. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1239.     ac_cv_type_getgroups=gid_t
  1240. else
  1241.   ac_cv_type_getgroups=int
  1242. fi
  1243. fi
  1244. rm -fr conftest*
  1245. if test $ac_cv_type_getgroups = cross; then
  1246.         cat > conftest.$ac_ext <<EOF
  1247. #line 1248 "configure"
  1248. #include "confdefs.h"
  1249. #include <unistd.h>
  1250. EOF
  1251. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1252.   egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
  1253.   rm -rf conftest*
  1254.   ac_cv_type_getgroups=gid_t
  1255. else
  1256.   rm -rf conftest*
  1257.   ac_cv_type_getgroups=int
  1258. fi
  1259. rm -f conftest*
  1260.  
  1261. fi
  1262. fi
  1263. echo "$ac_t""$ac_cv_type_getgroups" 1>&4
  1264. cat >> confdefs.h <<EOF
  1265. #define GETGROUPS_T $ac_cv_type_getgroups
  1266. EOF
  1267.  
  1268.  
  1269. echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4
  1270. if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then
  1271.   echo $ac_n "(cached) $ac_c" 1>&4
  1272. else
  1273.   cat > conftest.$ac_ext <<EOF
  1274. #line 1275 "configure"
  1275. #include "confdefs.h"
  1276. #include <stdlib.h>
  1277. #include <stdarg.h>
  1278. #include <string.h>
  1279. #include <float.h>
  1280. EOF
  1281. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1282. ac_err=`grep -v '^ *+' conftest.out`
  1283. if test -z "$ac_err"; then
  1284.   rm -rf conftest*
  1285.   ac_cv_header_stdc=yes
  1286. else
  1287.   echo "$ac_err" >&5
  1288.   rm -rf conftest*
  1289.   ac_cv_header_stdc=no
  1290. fi
  1291. rm -f conftest*
  1292.  
  1293. if test $ac_cv_header_stdc = yes; then
  1294.   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  1295. cat > conftest.$ac_ext <<EOF
  1296. #line 1297 "configure"
  1297. #include "confdefs.h"
  1298. #include <string.h>
  1299. EOF
  1300. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1301.   egrep "memchr" >/dev/null 2>&1; then
  1302.   :
  1303. else
  1304.   rm -rf conftest*
  1305.   ac_cv_header_stdc=no
  1306. fi
  1307. rm -f conftest*
  1308.  
  1309. fi
  1310.  
  1311. if test $ac_cv_header_stdc = yes; then
  1312.   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  1313. cat > conftest.$ac_ext <<EOF
  1314. #line 1315 "configure"
  1315. #include "confdefs.h"
  1316. #include <stdlib.h>
  1317. EOF
  1318. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1319.   egrep "free" >/dev/null 2>&1; then
  1320.   :
  1321. else
  1322.   rm -rf conftest*
  1323.   ac_cv_header_stdc=no
  1324. fi
  1325. rm -f conftest*
  1326.  
  1327. fi
  1328.  
  1329. if test $ac_cv_header_stdc = yes; then
  1330.   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  1331. if test "$cross_compiling" = yes; then
  1332.   ac_cv_header_stdc=no
  1333. else
  1334. cat > conftest.$ac_ext <<EOF
  1335. #line 1336 "configure"
  1336. #include "confdefs.h"
  1337. #include <ctype.h>
  1338. #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  1339. #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  1340. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  1341. int main () { int i; for (i = 0; i < 256; i++)
  1342. if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
  1343. exit (0); }
  1344.  
  1345. EOF
  1346. eval $ac_link
  1347. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1348.   :
  1349. else
  1350.   ac_cv_header_stdc=no
  1351. fi
  1352. fi
  1353. rm -fr conftest*
  1354. fi
  1355. fi
  1356. echo "$ac_t""$ac_cv_header_stdc" 1>&4
  1357. if test $ac_cv_header_stdc = yes; then
  1358.   cat >> confdefs.h <<\EOF
  1359. #define STDC_HEADERS 1
  1360. EOF
  1361.  
  1362. fi
  1363.  
  1364. echo $ac_n "checking for mode_t""... $ac_c" 1>&4
  1365. if eval "test \"`echo '${'ac_cv_type_mode_t'+set}'`\" = set"; then
  1366.   echo $ac_n "(cached) $ac_c" 1>&4
  1367. else
  1368.   cat > conftest.$ac_ext <<EOF
  1369. #line 1370 "configure"
  1370. #include "confdefs.h"
  1371. #include <sys/types.h>
  1372. #if STDC_HEADERS
  1373. #include <stdlib.h>
  1374. #endif
  1375. EOF
  1376. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1377.   egrep "mode_t" >/dev/null 2>&1; then
  1378.   rm -rf conftest*
  1379.   ac_cv_type_mode_t=yes
  1380. else
  1381.   rm -rf conftest*
  1382.   ac_cv_type_mode_t=no
  1383. fi
  1384. rm -f conftest*
  1385.  
  1386. fi
  1387. echo "$ac_t""$ac_cv_type_mode_t" 1>&4
  1388. if test $ac_cv_type_mode_t = no; then
  1389.   cat >> confdefs.h <<\EOF
  1390. #define mode_t int
  1391. EOF
  1392.  
  1393. fi
  1394.  
  1395. echo $ac_n "checking for off_t""... $ac_c" 1>&4
  1396. if eval "test \"`echo '${'ac_cv_type_off_t'+set}'`\" = set"; then
  1397.   echo $ac_n "(cached) $ac_c" 1>&4
  1398. else
  1399.   cat > conftest.$ac_ext <<EOF
  1400. #line 1401 "configure"
  1401. #include "confdefs.h"
  1402. #include <sys/types.h>
  1403. #if STDC_HEADERS
  1404. #include <stdlib.h>
  1405. #endif
  1406. EOF
  1407. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1408.   egrep "off_t" >/dev/null 2>&1; then
  1409.   rm -rf conftest*
  1410.   ac_cv_type_off_t=yes
  1411. else
  1412.   rm -rf conftest*
  1413.   ac_cv_type_off_t=no
  1414. fi
  1415. rm -f conftest*
  1416.  
  1417. fi
  1418. echo "$ac_t""$ac_cv_type_off_t" 1>&4
  1419. if test $ac_cv_type_off_t = no; then
  1420.   cat >> confdefs.h <<\EOF
  1421. #define off_t long
  1422. EOF
  1423.  
  1424. fi
  1425.  
  1426. echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&4
  1427. if eval "test \"`echo '${'ac_cv_type_signal'+set}'`\" = set"; then
  1428.   echo $ac_n "(cached) $ac_c" 1>&4
  1429. else
  1430.   cat > conftest.$ac_ext <<EOF
  1431. #line 1432 "configure"
  1432. #include "confdefs.h"
  1433. #include <sys/types.h>
  1434. #include <signal.h>
  1435. #ifdef signal
  1436. #undef signal
  1437. #endif
  1438. extern void (*signal ()) ();
  1439. int main() { return 0; }
  1440. int t() {
  1441. int i;
  1442. ; return 0; }
  1443. EOF
  1444. if eval $ac_compile; then
  1445.   rm -rf conftest*
  1446.   ac_cv_type_signal=void
  1447. else
  1448.   rm -rf conftest*
  1449.   ac_cv_type_signal=int
  1450. fi
  1451. rm -f conftest*
  1452.  
  1453. fi
  1454. echo "$ac_t""$ac_cv_type_signal" 1>&4
  1455. cat >> confdefs.h <<EOF
  1456. #define RETSIGTYPE $ac_cv_type_signal
  1457. EOF
  1458.  
  1459.  
  1460. echo $ac_n "checking for size_t""... $ac_c" 1>&4
  1461. if eval "test \"`echo '${'ac_cv_type_size_t'+set}'`\" = set"; then
  1462.   echo $ac_n "(cached) $ac_c" 1>&4
  1463. else
  1464.   cat > conftest.$ac_ext <<EOF
  1465. #line 1466 "configure"
  1466. #include "confdefs.h"
  1467. #include <sys/types.h>
  1468. #if STDC_HEADERS
  1469. #include <stdlib.h>
  1470. #endif
  1471. EOF
  1472. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1473.   egrep "size_t" >/dev/null 2>&1; then
  1474.   rm -rf conftest*
  1475.   ac_cv_type_size_t=yes
  1476. else
  1477.   rm -rf conftest*
  1478.   ac_cv_type_size_t=no
  1479. fi
  1480. rm -f conftest*
  1481.  
  1482. fi
  1483. echo "$ac_t""$ac_cv_type_size_t" 1>&4
  1484. if test $ac_cv_type_size_t = no; then
  1485.   cat >> confdefs.h <<\EOF
  1486. #define size_t unsigned
  1487. EOF
  1488.  
  1489. fi
  1490.  
  1491. echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&4
  1492. if eval "test \"`echo '${'ac_cv_type_uid_t'+set}'`\" = set"; then
  1493.   echo $ac_n "(cached) $ac_c" 1>&4
  1494. else
  1495.   cat > conftest.$ac_ext <<EOF
  1496. #line 1497 "configure"
  1497. #include "confdefs.h"
  1498. #include <sys/types.h>
  1499. EOF
  1500. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1501.   egrep "uid_t" >/dev/null 2>&1; then
  1502.   rm -rf conftest*
  1503.   ac_cv_type_uid_t=yes
  1504. else
  1505.   rm -rf conftest*
  1506.   ac_cv_type_uid_t=no
  1507. fi
  1508. rm -f conftest*
  1509.  
  1510. fi
  1511. echo "$ac_t""$ac_cv_type_uid_t" 1>&4
  1512. if test $ac_cv_type_uid_t = no; then
  1513.   cat >> confdefs.h <<\EOF
  1514. #define uid_t int
  1515. EOF
  1516.  
  1517.   cat >> confdefs.h <<\EOF
  1518. #define gid_t int
  1519. EOF
  1520.  
  1521. fi
  1522.  
  1523. echo $ac_n "checking for ino_t""... $ac_c" 1>&4
  1524. if eval "test \"`echo '${'ac_cv_type_ino_t'+set}'`\" = set"; then
  1525.   echo $ac_n "(cached) $ac_c" 1>&4
  1526. else
  1527.   cat > conftest.$ac_ext <<EOF
  1528. #line 1529 "configure"
  1529. #include "confdefs.h"
  1530. #include <sys/types.h>
  1531. #if STDC_HEADERS
  1532. #include <stdlib.h>
  1533. #endif
  1534. EOF
  1535. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1536.   egrep "ino_t" >/dev/null 2>&1; then
  1537.   rm -rf conftest*
  1538.   ac_cv_type_ino_t=yes
  1539. else
  1540.   rm -rf conftest*
  1541.   ac_cv_type_ino_t=no
  1542. fi
  1543. rm -f conftest*
  1544.  
  1545. fi
  1546. echo "$ac_t""$ac_cv_type_ino_t" 1>&4
  1547. if test $ac_cv_type_ino_t = no; then
  1548.   cat >> confdefs.h <<\EOF
  1549. #define ino_t unsigned long
  1550. EOF
  1551.  
  1552. fi
  1553.  
  1554.  
  1555. echo $ac_n "checking for working const""... $ac_c" 1>&4
  1556. if eval "test \"`echo '${'ac_cv_c_const'+set}'`\" = set"; then
  1557.   echo $ac_n "(cached) $ac_c" 1>&4
  1558. else
  1559.   cat > conftest.$ac_ext <<EOF
  1560. #line 1561 "configure"
  1561. #include "confdefs.h"
  1562.  
  1563. int main() { return 0; }
  1564. int t() {
  1565.  
  1566. /* Ultrix mips cc rejects this.  */
  1567. typedef int charset[2]; const charset x;
  1568. /* SunOS 4.1.1 cc rejects this.  */
  1569. char const *const *ccp;
  1570. char **p;
  1571. /* NEC SVR4.0.2 mips cc rejects this.  */
  1572. struct point {int x, y;};
  1573. static struct point const zero;
  1574. /* AIX XL C 1.02.0.0 rejects this.
  1575.    It does not let you subtract one const X* pointer from another in an arm
  1576.    of an if-expression whose if-part is not a constant expression */
  1577. const char *g = "string";
  1578. ccp = &g + (g ? g-g : 0);
  1579. /* HPUX 7.0 cc rejects these. */
  1580. ++ccp;
  1581. p = (char**) ccp;
  1582. ccp = (char const *const *) p;
  1583. { /* SCO 3.2v4 cc rejects this.  */
  1584.   char *t;
  1585.   char const *s = 0 ? (char *) 0 : (char const *) 0;
  1586.  
  1587.   *t++ = 0;
  1588. }
  1589. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  1590.   int x[] = {25, 17};
  1591.   const int *foo = &x[0];
  1592.   ++foo;
  1593. }
  1594. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  1595.   typedef const int *iptr;
  1596.   iptr p = 0;
  1597.   ++p;
  1598. }
  1599. { /* AIX XL C 1.02.0.0 rejects this saying
  1600.      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  1601.   struct s { int j; const int *ap[3]; };
  1602.   struct s *b; b->j = 5;
  1603. }
  1604. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  1605.   const int foo = 10;
  1606. }
  1607.  
  1608. ; return 0; }
  1609. EOF
  1610. if eval $ac_compile; then
  1611.   rm -rf conftest*
  1612.   ac_cv_c_const=yes
  1613. else
  1614.   rm -rf conftest*
  1615.   ac_cv_c_const=no
  1616. fi
  1617. rm -f conftest*
  1618.  
  1619. fi
  1620. echo "$ac_t""$ac_cv_c_const" 1>&4
  1621. if test $ac_cv_c_const = no; then
  1622.   cat >> confdefs.h <<\EOF
  1623. #define const 
  1624. EOF
  1625.  
  1626. fi
  1627.  
  1628. echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4
  1629. if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then
  1630.   echo $ac_n "(cached) $ac_c" 1>&4
  1631. else
  1632.   cat > conftest.$ac_ext <<EOF
  1633. #line 1634 "configure"
  1634. #include "confdefs.h"
  1635. #include <stdlib.h>
  1636. #include <stdarg.h>
  1637. #include <string.h>
  1638. #include <float.h>
  1639. EOF
  1640. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1641. ac_err=`grep -v '^ *+' conftest.out`
  1642. if test -z "$ac_err"; then
  1643.   rm -rf conftest*
  1644.   ac_cv_header_stdc=yes
  1645. else
  1646.   echo "$ac_err" >&5
  1647.   rm -rf conftest*
  1648.   ac_cv_header_stdc=no
  1649. fi
  1650. rm -f conftest*
  1651.  
  1652. if test $ac_cv_header_stdc = yes; then
  1653.   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  1654. cat > conftest.$ac_ext <<EOF
  1655. #line 1656 "configure"
  1656. #include "confdefs.h"
  1657. #include <string.h>
  1658. EOF
  1659. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1660.   egrep "memchr" >/dev/null 2>&1; then
  1661.   :
  1662. else
  1663.   rm -rf conftest*
  1664.   ac_cv_header_stdc=no
  1665. fi
  1666. rm -f conftest*
  1667.  
  1668. fi
  1669.  
  1670. if test $ac_cv_header_stdc = yes; then
  1671.   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  1672. cat > conftest.$ac_ext <<EOF
  1673. #line 1674 "configure"
  1674. #include "confdefs.h"
  1675. #include <stdlib.h>
  1676. EOF
  1677. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1678.   egrep "free" >/dev/null 2>&1; then
  1679.   :
  1680. else
  1681.   rm -rf conftest*
  1682.   ac_cv_header_stdc=no
  1683. fi
  1684. rm -f conftest*
  1685.  
  1686. fi
  1687.  
  1688. if test $ac_cv_header_stdc = yes; then
  1689.   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  1690. if test "$cross_compiling" = yes; then
  1691.   ac_cv_header_stdc=no
  1692. else
  1693. cat > conftest.$ac_ext <<EOF
  1694. #line 1695 "configure"
  1695. #include "confdefs.h"
  1696. #include <ctype.h>
  1697. #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  1698. #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  1699. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  1700. int main () { int i; for (i = 0; i < 256; i++)
  1701. if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
  1702. exit (0); }
  1703.  
  1704. EOF
  1705. eval $ac_link
  1706. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1707.   :
  1708. else
  1709.   ac_cv_header_stdc=no
  1710. fi
  1711. fi
  1712. rm -fr conftest*
  1713. fi
  1714. fi
  1715. echo "$ac_t""$ac_cv_header_stdc" 1>&4
  1716. if test $ac_cv_header_stdc = yes; then
  1717.   cat >> confdefs.h <<\EOF
  1718. #define STDC_HEADERS 1
  1719. EOF
  1720.  
  1721. fi
  1722.  
  1723. echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&4
  1724. if eval "test \"`echo '${'ac_cv_struct_tm'+set}'`\" = set"; then
  1725.   echo $ac_n "(cached) $ac_c" 1>&4
  1726. else
  1727.   cat > conftest.$ac_ext <<EOF
  1728. #line 1729 "configure"
  1729. #include "confdefs.h"
  1730. #include <sys/types.h>
  1731. #include <time.h>
  1732. int main() { return 0; }
  1733. int t() {
  1734. struct tm *tp; tp->tm_sec;
  1735. ; return 0; }
  1736. EOF
  1737. if eval $ac_compile; then
  1738.   rm -rf conftest*
  1739.   ac_cv_struct_tm=time.h
  1740. else
  1741.   rm -rf conftest*
  1742.   ac_cv_struct_tm=sys/time.h
  1743. fi
  1744. rm -f conftest*
  1745.  
  1746. fi
  1747. echo "$ac_t""$ac_cv_struct_tm" 1>&4
  1748. if test $ac_cv_struct_tm = sys/time.h; then
  1749.   cat >> confdefs.h <<\EOF
  1750. #define TM_IN_SYS_TIME 1
  1751. EOF
  1752.  
  1753. fi
  1754.  
  1755. echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&4
  1756. if eval "test \"`echo '${'ac_cv_struct_st_blocks'+set}'`\" = set"; then
  1757.   echo $ac_n "(cached) $ac_c" 1>&4
  1758. else
  1759.   cat > conftest.$ac_ext <<EOF
  1760. #line 1761 "configure"
  1761. #include "confdefs.h"
  1762. #include <sys/types.h>
  1763. #include <sys/stat.h>
  1764. int main() { return 0; }
  1765. int t() {
  1766. struct stat s; s.st_blocks;
  1767. ; return 0; }
  1768. EOF
  1769. if eval $ac_compile; then
  1770.   rm -rf conftest*
  1771.   ac_cv_struct_st_blocks=yes
  1772. else
  1773.   rm -rf conftest*
  1774.   ac_cv_struct_st_blocks=no
  1775. fi
  1776. rm -f conftest*
  1777.  
  1778. fi
  1779. echo "$ac_t""$ac_cv_struct_st_blocks" 1>&4
  1780. if test $ac_cv_struct_st_blocks = yes; then
  1781.   cat >> confdefs.h <<\EOF
  1782. #define HAVE_ST_BLOCKS 1
  1783. EOF
  1784.  
  1785. else
  1786.   LIBOBJS="$LIBOBJS fileblocks.o"
  1787. fi
  1788.  
  1789. echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&4
  1790. if eval "test \"`echo '${'ac_cv_header_time'+set}'`\" = set"; then
  1791.   echo $ac_n "(cached) $ac_c" 1>&4
  1792. else
  1793.   cat > conftest.$ac_ext <<EOF
  1794. #line 1795 "configure"
  1795. #include "confdefs.h"
  1796. #include <sys/types.h>
  1797. #include <sys/time.h>
  1798. #include <time.h>
  1799. int main() { return 0; }
  1800. int t() {
  1801. struct tm *tp;
  1802. ; return 0; }
  1803. EOF
  1804. if eval $ac_compile; then
  1805.   rm -rf conftest*
  1806.   ac_cv_header_time=yes
  1807. else
  1808.   rm -rf conftest*
  1809.   ac_cv_header_time=no
  1810. fi
  1811. rm -f conftest*
  1812.  
  1813. fi
  1814. echo "$ac_t""$ac_cv_header_time" 1>&4
  1815. if test $ac_cv_header_time = yes; then
  1816.   cat >> confdefs.h <<\EOF
  1817. #define TIME_WITH_SYS_TIME 1
  1818. EOF
  1819.  
  1820. fi
  1821.  
  1822. echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&4
  1823. if eval "test \"`echo '${'ac_cv_header_stat_broken'+set}'`\" = set"; then
  1824.   echo $ac_n "(cached) $ac_c" 1>&4
  1825. else
  1826.   cat > conftest.$ac_ext <<EOF
  1827. #line 1828 "configure"
  1828. #include "confdefs.h"
  1829. #include <sys/types.h>
  1830. #include <sys/stat.h>
  1831. #ifdef S_ISBLK
  1832. # if S_ISBLK (S_IFDIR)
  1833. You lose.
  1834. # endif
  1835. # ifdef S_IFCHR
  1836. #  if S_ISBLK (S_IFCHR)
  1837. You lose.
  1838. #  endif
  1839. # endif
  1840. #endif
  1841.  
  1842. #ifdef S_ISLNK
  1843. # if S_ISLNK (S_IFREG)
  1844. You lose.
  1845. # endif
  1846. #endif
  1847.  
  1848. #ifdef S_ISSOCK
  1849. # if S_ISSOCK (S_IFREG)
  1850. You lose.
  1851. # endif
  1852. #endif
  1853.  
  1854. EOF
  1855. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1856.   egrep "You lose" >/dev/null 2>&1; then
  1857.   rm -rf conftest*
  1858.   ac_cv_header_stat_broken=yes
  1859. else
  1860.   rm -rf conftest*
  1861.   ac_cv_header_stat_broken=no
  1862. fi
  1863. rm -f conftest*
  1864.  
  1865. fi
  1866. echo "$ac_t""$ac_cv_header_stat_broken" 1>&4
  1867. if test $ac_cv_header_stat_broken = yes; then
  1868.   cat >> confdefs.h <<\EOF
  1869. #define STAT_MACROS_BROKEN 1
  1870. EOF
  1871.  
  1872. fi
  1873.  
  1874.  
  1875. for ac_hdr in string.h fcntl.h limits.h sys/time.h errno.h unistd.h \
  1876.     sys/param.h sys/statfs.h sys/fstyp.h mnttab.h mntent.h utime.h \
  1877.     sys/statvfs.h sys/vfs.h sys/mount.h sys/filsys.h sys/fs_types.h
  1878. do
  1879. ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
  1880. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4
  1881. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  1882.   echo $ac_n "(cached) $ac_c" 1>&4
  1883. else
  1884.   cat > conftest.$ac_ext <<EOF
  1885. #line 1886 "configure"
  1886. #include "confdefs.h"
  1887. #include <$ac_hdr>
  1888. EOF
  1889. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1890. ac_err=`grep -v '^ *+' conftest.out`
  1891. if test -z "$ac_err"; then
  1892.   rm -rf conftest*
  1893.   eval "ac_cv_header_$ac_safe=yes"
  1894. else
  1895.   echo "$ac_err" >&5
  1896.   rm -rf conftest*
  1897.   eval "ac_cv_header_$ac_safe=no"
  1898. fi
  1899. rm -f conftest*
  1900. fi
  1901. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  1902.   echo "$ac_t""yes" 1>&4
  1903.     ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  1904.   cat >> confdefs.h <<EOF
  1905. #define $ac_tr_hdr 1
  1906. EOF
  1907.  
  1908. else
  1909.   echo "$ac_t""no" 1>&4
  1910. fi
  1911. done
  1912.  
  1913. for ac_func in euidaccess fnmatch mkdir mktime rename rmdir stpcpy \
  1914.     strdup strstr
  1915. do
  1916. echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  1917. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  1918.   echo $ac_n "(cached) $ac_c" 1>&4
  1919. else
  1920.   cat > conftest.$ac_ext <<EOF
  1921. #line 1922 "configure"
  1922. #include "confdefs.h"
  1923. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1924. int main() { return 0; }
  1925. int t() {
  1926.  
  1927. /* The GNU C library defines this for functions which it implements
  1928.     to always fail with ENOSYS.  Some functions are actually named
  1929.     something starting with __ and the normal name is an alias.  */
  1930. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  1931. choke me
  1932. #else
  1933. /* Override any gcc2 internal prototype to avoid an error.  */
  1934. char $ac_func(); $ac_func();
  1935. #endif
  1936.  
  1937. ; return 0; }
  1938. EOF
  1939. if eval $ac_link; then
  1940.   rm -rf conftest*
  1941.   eval "ac_cv_func_$ac_func=yes"
  1942. else
  1943.   rm -rf conftest*
  1944.   eval "ac_cv_func_$ac_func=no"
  1945. fi
  1946. rm -f conftest*
  1947.  
  1948. fi
  1949. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  1950.   echo "$ac_t""yes" 1>&4
  1951.   :
  1952. else
  1953.   echo "$ac_t""no" 1>&4
  1954. LIBOBJS="$LIBOBJS ${ac_func}.o"
  1955. fi
  1956.  
  1957. done
  1958.  
  1959. for ac_func in bcopy endgrent fchdir ftime ftruncate getcwd getgroups \
  1960.     getmntinfo gettimeofday isascii memcpy mkfifo strerror
  1961. do
  1962. echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  1963. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  1964.   echo $ac_n "(cached) $ac_c" 1>&4
  1965. else
  1966.   cat > conftest.$ac_ext <<EOF
  1967. #line 1968 "configure"
  1968. #include "confdefs.h"
  1969. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1970. int main() { return 0; }
  1971. int t() {
  1972.  
  1973. /* The GNU C library defines this for functions which it implements
  1974.     to always fail with ENOSYS.  Some functions are actually named
  1975.     something starting with __ and the normal name is an alias.  */
  1976. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  1977. choke me
  1978. #else
  1979. /* Override any gcc2 internal prototype to avoid an error.  */
  1980. char $ac_func(); $ac_func();
  1981. #endif
  1982.  
  1983. ; return 0; }
  1984. EOF
  1985. if eval $ac_link; then
  1986.   rm -rf conftest*
  1987.   eval "ac_cv_func_$ac_func=yes"
  1988. else
  1989.   rm -rf conftest*
  1990.   eval "ac_cv_func_$ac_func=no"
  1991. fi
  1992. rm -f conftest*
  1993.  
  1994. fi
  1995. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  1996.   echo "$ac_t""yes" 1>&4
  1997.     ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'`
  1998.   cat >> confdefs.h <<EOF
  1999. #define $ac_tr_func 1
  2000. EOF
  2001.  
  2002. else
  2003.   echo "$ac_t""no" 1>&4
  2004. fi
  2005. done
  2006.  
  2007.  
  2008. echo $ac_n "checking for vprintf""... $ac_c" 1>&4
  2009. if eval "test \"`echo '${'ac_cv_func_vprintf'+set}'`\" = set"; then
  2010.   echo $ac_n "(cached) $ac_c" 1>&4
  2011. else
  2012.   cat > conftest.$ac_ext <<EOF
  2013. #line 2014 "configure"
  2014. #include "confdefs.h"
  2015. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2016. int main() { return 0; }
  2017. int t() {
  2018.  
  2019. /* The GNU C library defines this for functions which it implements
  2020.     to always fail with ENOSYS.  Some functions are actually named
  2021.     something starting with __ and the normal name is an alias.  */
  2022. #if defined (__stub_vprintf) || defined (__stub___vprintf)
  2023. choke me
  2024. #else
  2025. /* Override any gcc2 internal prototype to avoid an error.  */
  2026. char vprintf(); vprintf();
  2027. #endif
  2028.  
  2029. ; return 0; }
  2030. EOF
  2031. if eval $ac_link; then
  2032.   rm -rf conftest*
  2033.   eval "ac_cv_func_vprintf=yes"
  2034. else
  2035.   rm -rf conftest*
  2036.   eval "ac_cv_func_vprintf=no"
  2037. fi
  2038. rm -f conftest*
  2039.  
  2040. fi
  2041. if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
  2042.   echo "$ac_t""yes" 1>&4
  2043.   cat >> confdefs.h <<\EOF
  2044. #define HAVE_VPRINTF 1
  2045. EOF
  2046.  
  2047. else
  2048.   echo "$ac_t""no" 1>&4
  2049. fi
  2050.  
  2051. if test "$ac_cv_func_vprintf" != yes; then
  2052. echo $ac_n "checking for _doprnt""... $ac_c" 1>&4
  2053. if eval "test \"`echo '${'ac_cv_func__doprnt'+set}'`\" = set"; then
  2054.   echo $ac_n "(cached) $ac_c" 1>&4
  2055. else
  2056.   cat > conftest.$ac_ext <<EOF
  2057. #line 2058 "configure"
  2058. #include "confdefs.h"
  2059. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2060. int main() { return 0; }
  2061. int t() {
  2062.  
  2063. /* The GNU C library defines this for functions which it implements
  2064.     to always fail with ENOSYS.  Some functions are actually named
  2065.     something starting with __ and the normal name is an alias.  */
  2066. #if defined (__stub__doprnt) || defined (__stub____doprnt)
  2067. choke me
  2068. #else
  2069. /* Override any gcc2 internal prototype to avoid an error.  */
  2070. char _doprnt(); _doprnt();
  2071. #endif
  2072.  
  2073. ; return 0; }
  2074. EOF
  2075. if eval $ac_link; then
  2076.   rm -rf conftest*
  2077.   eval "ac_cv_func__doprnt=yes"
  2078. else
  2079.   rm -rf conftest*
  2080.   eval "ac_cv_func__doprnt=no"
  2081. fi
  2082. rm -f conftest*
  2083.  
  2084. fi
  2085. if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
  2086.   echo "$ac_t""yes" 1>&4
  2087.   cat >> confdefs.h <<\EOF
  2088. #define HAVE_DOPRNT 1
  2089. EOF
  2090.  
  2091. else
  2092.   echo "$ac_t""no" 1>&4
  2093. fi
  2094.  
  2095. fi
  2096.  
  2097. # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
  2098. # for constant arguments.  Useless!
  2099. echo $ac_n "checking for working alloca.h""... $ac_c" 1>&4
  2100. if eval "test \"`echo '${'ac_cv_header_alloca_h'+set}'`\" = set"; then
  2101.   echo $ac_n "(cached) $ac_c" 1>&4
  2102. else
  2103.   cat > conftest.$ac_ext <<EOF
  2104. #line 2105 "configure"
  2105. #include "confdefs.h"
  2106. #include <alloca.h>
  2107. int main() { return 0; }
  2108. int t() {
  2109. char *p = alloca(2 * sizeof(int));
  2110. ; return 0; }
  2111. EOF
  2112. if eval $ac_link; then
  2113.   rm -rf conftest*
  2114.   ac_cv_header_alloca_h=yes
  2115. else
  2116.   rm -rf conftest*
  2117.   ac_cv_header_alloca_h=no
  2118. fi
  2119. rm -f conftest*
  2120.  
  2121. fi
  2122. echo "$ac_t""$ac_cv_header_alloca_h" 1>&4
  2123. if test $ac_cv_header_alloca_h = yes; then
  2124.   cat >> confdefs.h <<\EOF
  2125. #define HAVE_ALLOCA_H 1
  2126. EOF
  2127.  
  2128. fi
  2129.  
  2130. echo $ac_n "checking for alloca""... $ac_c" 1>&4
  2131. if eval "test \"`echo '${'ac_cv_func_alloca'+set}'`\" = set"; then
  2132.   echo $ac_n "(cached) $ac_c" 1>&4
  2133. else
  2134.   cat > conftest.$ac_ext <<EOF
  2135. #line 2136 "configure"
  2136. #include "confdefs.h"
  2137.  
  2138. #ifdef __GNUC__
  2139. # define alloca __builtin_alloca
  2140. #else
  2141. # if HAVE_ALLOCA_H
  2142. #  include <alloca.h>
  2143. # else
  2144. #  ifdef _AIX
  2145.  #pragma alloca
  2146. #  else
  2147. #   ifndef alloca /* predefined by HP cc +Olibcalls */
  2148. char *alloca ();
  2149. #   endif
  2150. #  endif
  2151. # endif
  2152. #endif
  2153.  
  2154. int main() { return 0; }
  2155. int t() {
  2156. char *p = (char *) alloca(1);
  2157. ; return 0; }
  2158. EOF
  2159. if eval $ac_link; then
  2160.   rm -rf conftest*
  2161.   ac_cv_func_alloca=yes
  2162. else
  2163.   rm -rf conftest*
  2164.   ac_cv_func_alloca=no
  2165. fi
  2166. rm -f conftest*
  2167.  
  2168. fi
  2169. echo "$ac_t""$ac_cv_func_alloca" 1>&4
  2170. if test $ac_cv_func_alloca = yes; then
  2171.   cat >> confdefs.h <<\EOF
  2172. #define HAVE_ALLOCA 1
  2173. EOF
  2174.  
  2175. fi
  2176.  
  2177. if test $ac_cv_func_alloca = no; then
  2178.   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  2179.   # that cause trouble.  Some versions do not even contain alloca or
  2180.   # contain a buggy version.  If you still want to use their alloca,
  2181.   # use ar to extract alloca.o from them instead of compiling alloca.c.
  2182.   ALLOCA=alloca.o
  2183.   cat >> confdefs.h <<\EOF
  2184. #define C_ALLOCA 1
  2185. EOF
  2186.  
  2187.  
  2188. echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&4
  2189. if eval "test \"`echo '${'ac_cv_os_cray'+set}'`\" = set"; then
  2190.   echo $ac_n "(cached) $ac_c" 1>&4
  2191. else
  2192.   cat > conftest.$ac_ext <<EOF
  2193. #line 2194 "configure"
  2194. #include "confdefs.h"
  2195. #if defined(CRAY) && ! defined(CRAY2)
  2196. webecray
  2197. #else
  2198. wenotbecray
  2199. #endif
  2200.  
  2201. EOF
  2202. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  2203.   egrep "webecray" >/dev/null 2>&1; then
  2204.   rm -rf conftest*
  2205.   ac_cv_os_cray=yes
  2206. else
  2207.   rm -rf conftest*
  2208.   ac_cv_os_cray=no
  2209. fi
  2210. rm -f conftest*
  2211.  
  2212. fi
  2213. echo "$ac_t""$ac_cv_os_cray" 1>&4
  2214. if test $ac_cv_os_cray = yes; then
  2215. echo $ac_n "checking for _getb67""... $ac_c" 1>&4
  2216. if eval "test \"`echo '${'ac_cv_func__getb67'+set}'`\" = set"; then
  2217.   echo $ac_n "(cached) $ac_c" 1>&4
  2218. else
  2219.   cat > conftest.$ac_ext <<EOF
  2220. #line 2221 "configure"
  2221. #include "confdefs.h"
  2222. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2223. int main() { return 0; }
  2224. int t() {
  2225.  
  2226. /* The GNU C library defines this for functions which it implements
  2227.     to always fail with ENOSYS.  Some functions are actually named
  2228.     something starting with __ and the normal name is an alias.  */
  2229. #if defined (__stub__getb67) || defined (__stub____getb67)
  2230. choke me
  2231. #else
  2232. /* Override any gcc2 internal prototype to avoid an error.  */
  2233. char _getb67(); _getb67();
  2234. #endif
  2235.  
  2236. ; return 0; }
  2237. EOF
  2238. if eval $ac_link; then
  2239.   rm -rf conftest*
  2240.   eval "ac_cv_func__getb67=yes"
  2241. else
  2242.   rm -rf conftest*
  2243.   eval "ac_cv_func__getb67=no"
  2244. fi
  2245. rm -f conftest*
  2246.  
  2247. fi
  2248. if eval "test \"`echo '$ac_cv_func_'_getb67`\" = yes"; then
  2249.   echo "$ac_t""yes" 1>&4
  2250.   cat >> confdefs.h <<\EOF
  2251. #define CRAY_STACKSEG_END _getb67
  2252. EOF
  2253.  
  2254. else
  2255.   echo "$ac_t""no" 1>&4
  2256. echo $ac_n "checking for GETB67""... $ac_c" 1>&4
  2257. if eval "test \"`echo '${'ac_cv_func_GETB67'+set}'`\" = set"; then
  2258.   echo $ac_n "(cached) $ac_c" 1>&4
  2259. else
  2260.   cat > conftest.$ac_ext <<EOF
  2261. #line 2262 "configure"
  2262. #include "confdefs.h"
  2263. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2264. int main() { return 0; }
  2265. int t() {
  2266.  
  2267. /* The GNU C library defines this for functions which it implements
  2268.     to always fail with ENOSYS.  Some functions are actually named
  2269.     something starting with __ and the normal name is an alias.  */
  2270. #if defined (__stub_GETB67) || defined (__stub___GETB67)
  2271. choke me
  2272. #else
  2273. /* Override any gcc2 internal prototype to avoid an error.  */
  2274. char GETB67(); GETB67();
  2275. #endif
  2276.  
  2277. ; return 0; }
  2278. EOF
  2279. if eval $ac_link; then
  2280.   rm -rf conftest*
  2281.   eval "ac_cv_func_GETB67=yes"
  2282. else
  2283.   rm -rf conftest*
  2284.   eval "ac_cv_func_GETB67=no"
  2285. fi
  2286. rm -f conftest*
  2287.  
  2288. fi
  2289. if eval "test \"`echo '$ac_cv_func_'GETB67`\" = yes"; then
  2290.   echo "$ac_t""yes" 1>&4
  2291.   cat >> confdefs.h <<\EOF
  2292. #define CRAY_STACKSEG_END GETB67
  2293. EOF
  2294.  
  2295. else
  2296.   echo "$ac_t""no" 1>&4
  2297. echo $ac_n "checking for getb67""... $ac_c" 1>&4
  2298. if eval "test \"`echo '${'ac_cv_func_getb67'+set}'`\" = set"; then
  2299.   echo $ac_n "(cached) $ac_c" 1>&4
  2300. else
  2301.   cat > conftest.$ac_ext <<EOF
  2302. #line 2303 "configure"
  2303. #include "confdefs.h"
  2304. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2305. int main() { return 0; }
  2306. int t() {
  2307.  
  2308. /* The GNU C library defines this for functions which it implements
  2309.     to always fail with ENOSYS.  Some functions are actually named
  2310.     something starting with __ and the normal name is an alias.  */
  2311. #if defined (__stub_getb67) || defined (__stub___getb67)
  2312. choke me
  2313. #else
  2314. /* Override any gcc2 internal prototype to avoid an error.  */
  2315. char getb67(); getb67();
  2316. #endif
  2317.  
  2318. ; return 0; }
  2319. EOF
  2320. if eval $ac_link; then
  2321.   rm -rf conftest*
  2322.   eval "ac_cv_func_getb67=yes"
  2323. else
  2324.   rm -rf conftest*
  2325.   eval "ac_cv_func_getb67=no"
  2326. fi
  2327. rm -f conftest*
  2328.  
  2329. fi
  2330. if eval "test \"`echo '$ac_cv_func_'getb67`\" = yes"; then
  2331.   echo "$ac_t""yes" 1>&4
  2332.   cat >> confdefs.h <<\EOF
  2333. #define CRAY_STACKSEG_END getb67
  2334. EOF
  2335.  
  2336. else
  2337.   echo "$ac_t""no" 1>&4
  2338. fi
  2339.  
  2340. fi
  2341.  
  2342. fi
  2343.  
  2344. fi
  2345.  
  2346. echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&4
  2347. if eval "test \"`echo '${'ac_cv_c_stack_direction'+set}'`\" = set"; then
  2348.   echo $ac_n "(cached) $ac_c" 1>&4
  2349. else
  2350.   if test "$cross_compiling" = yes; then
  2351.   ac_cv_c_stack_direction=0
  2352. else
  2353. cat > conftest.$ac_ext <<EOF
  2354. #line 2355 "configure"
  2355. #include "confdefs.h"
  2356. find_stack_direction ()
  2357. {
  2358.   static char *addr = 0;
  2359.   auto char dummy;
  2360.   if (addr == 0)
  2361.     {
  2362.       addr = &dummy;
  2363.       return find_stack_direction ();
  2364.     }
  2365.   else
  2366.     return (&dummy > addr) ? 1 : -1;
  2367. }
  2368. main ()
  2369. {
  2370.   exit (find_stack_direction() < 0);
  2371. }
  2372. EOF
  2373. eval $ac_link
  2374. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  2375.   ac_cv_c_stack_direction=1
  2376. else
  2377.   ac_cv_c_stack_direction=-1
  2378. fi
  2379. fi
  2380. rm -fr conftest*
  2381. fi
  2382. echo "$ac_t""$ac_cv_c_stack_direction" 1>&4
  2383. cat >> confdefs.h <<EOF
  2384. #define STACK_DIRECTION $ac_cv_c_stack_direction
  2385. EOF
  2386.  
  2387. fi
  2388.  
  2389. echo $ac_n "checking whether utime accepts a null argument""... $ac_c" 1>&4
  2390. if eval "test \"`echo '${'ac_cv_func_utime_null'+set}'`\" = set"; then
  2391.   echo $ac_n "(cached) $ac_c" 1>&4
  2392. else
  2393.   rm -f conftestdata; > conftestdata
  2394. # Sequent interprets utime(file, 0) to mean use start of epoch.  Wrong.
  2395. if test "$cross_compiling" = yes; then
  2396.   ac_cv_func_utime_null=no
  2397. else
  2398. cat > conftest.$ac_ext <<EOF
  2399. #line 2400 "configure"
  2400. #include "confdefs.h"
  2401. #include <sys/types.h>
  2402. #include <sys/stat.h>
  2403. main() {
  2404. struct stat s, t;
  2405. exit(!(stat ("conftestdata", &s) == 0 && utime("conftestdata", (long *)0) == 0
  2406. && stat("conftestdata", &t) == 0 && t.st_mtime >= s.st_mtime
  2407. && t.st_mtime - s.st_mtime < 120));
  2408. }
  2409. EOF
  2410. eval $ac_link
  2411. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  2412.   ac_cv_func_utime_null=yes
  2413. else
  2414.   ac_cv_func_utime_null=no
  2415. fi
  2416. fi
  2417. rm -fr conftest*
  2418. rm -f core
  2419. fi
  2420. echo "$ac_t""$ac_cv_func_utime_null" 1>&4
  2421. if test $ac_cv_func_utime_null = yes; then
  2422.   cat >> confdefs.h <<\EOF
  2423. #define HAVE_UTIME_NULL 1
  2424. EOF
  2425.  
  2426. fi
  2427.  
  2428.  
  2429. echo $ac_n "checking for d_ino member in directory struct""... $ac_c" 1>&4
  2430. if eval "test \"`echo '${'fu_cv_sys_d_ino_in_dirent'+set}'`\" = set"; then
  2431.   echo $ac_n "(cached) $ac_c" 1>&4
  2432. else
  2433.   cat > conftest.$ac_ext <<EOF
  2434. #line 2435 "configure"
  2435. #include "confdefs.h"
  2436.  
  2437. #include <sys/types.h>
  2438. #ifdef HAVE_DIRENT_H
  2439. # include <dirent.h>
  2440. #else /* not HAVE_DIRENT_H */
  2441. # define dirent direct
  2442. # ifdef HAVE_SYS_NDIR_H
  2443. #  include <sys/ndir.h>
  2444. # endif /* HAVE_SYS_NDIR_H */
  2445. # ifdef HAVE_SYS_DIR_H
  2446. #  include <sys/dir.h>
  2447. # endif /* HAVE_SYS_DIR_H */
  2448. # ifdef HAVE_NDIR_H
  2449. #  include <ndir.h>
  2450. # endif /* HAVE_NDIR_H */
  2451. #endif /* HAVE_DIRENT_H */
  2452.  
  2453. int main() { return 0; }
  2454. int t() {
  2455. struct dirent dp; dp.d_ino = 0;
  2456. ; return 0; }
  2457. EOF
  2458. if eval $ac_link; then
  2459.   rm -rf conftest*
  2460.   fu_cv_sys_d_ino_in_dirent=yes
  2461. else
  2462.   rm -rf conftest*
  2463.   fu_cv_sys_d_ino_in_dirent=no
  2464. fi
  2465. rm -f conftest*
  2466.  
  2467. fi
  2468.  
  2469. echo "$ac_t""$fu_cv_sys_d_ino_in_dirent" 1>&4
  2470. if test $fu_cv_sys_d_ino_in_dirent = yes; then
  2471.   cat >> confdefs.h <<\EOF
  2472. #define D_INO_IN_DIRENT 1
  2473. EOF
  2474.  
  2475. fi
  2476.  
  2477. # Determine how to get the list of mounted filesystems.
  2478. list_mounted_fs=
  2479.  
  2480. # If the getmntent function is available but not in the standard library,
  2481. # make sure LIBS contains -lsun (on Irix4) or -lseq (on PTX).
  2482. # getmntent is in -lsun on Irix 4, -lseq on Dynix/PTX.
  2483. echo $ac_n "checking for -lsun""... $ac_c" 1>&4
  2484. if eval "test \"`echo '${'ac_cv_lib_sun'+set}'`\" = set"; then
  2485.   echo $ac_n "(cached) $ac_c" 1>&4
  2486. else
  2487.   ac_save_LIBS="$LIBS"
  2488. LIBS="$LIBS -lsun "
  2489. cat > conftest.$ac_ext <<EOF
  2490. #line 2491 "configure"
  2491. #include "confdefs.h"
  2492.  
  2493. int main() { return 0; }
  2494. int t() {
  2495. getmntent()
  2496. ; return 0; }
  2497. EOF
  2498. if eval $ac_link; then
  2499.   rm -rf conftest*
  2500.   eval "ac_cv_lib_sun=yes"
  2501. else
  2502.   rm -rf conftest*
  2503.   eval "ac_cv_lib_sun=no"
  2504. fi
  2505. rm -f conftest*
  2506. LIBS="$ac_save_LIBS"
  2507.  
  2508. fi
  2509. if eval "test \"`echo '$ac_cv_lib_'sun`\" = yes"; then
  2510.   echo "$ac_t""yes" 1>&4
  2511.   LIBS="$LIBS -lsun"
  2512. else
  2513.   echo "$ac_t""no" 1>&4
  2514. echo $ac_n "checking for -lseq""... $ac_c" 1>&4
  2515. if eval "test \"`echo '${'ac_cv_lib_seq'+set}'`\" = set"; then
  2516.   echo $ac_n "(cached) $ac_c" 1>&4
  2517. else
  2518.   ac_save_LIBS="$LIBS"
  2519. LIBS="$LIBS -lseq "
  2520. cat > conftest.$ac_ext <<EOF
  2521. #line 2522 "configure"
  2522. #include "confdefs.h"
  2523.  
  2524. int main() { return 0; }
  2525. int t() {
  2526. getmntent()
  2527. ; return 0; }
  2528. EOF
  2529. if eval $ac_link; then
  2530.   rm -rf conftest*
  2531.   eval "ac_cv_lib_seq=yes"
  2532. else
  2533.   rm -rf conftest*
  2534.   eval "ac_cv_lib_seq=no"
  2535. fi
  2536. rm -f conftest*
  2537. LIBS="$ac_save_LIBS"
  2538.  
  2539. fi
  2540. if eval "test \"`echo '$ac_cv_lib_'seq`\" = yes"; then
  2541.   echo "$ac_t""yes" 1>&4
  2542.   LIBS="$LIBS -lseq"
  2543. else
  2544.   echo "$ac_t""no" 1>&4
  2545. fi
  2546.  
  2547. fi
  2548.  
  2549. echo $ac_n "checking for getmntent""... $ac_c" 1>&4
  2550. if eval "test \"`echo '${'ac_cv_func_getmntent'+set}'`\" = set"; then
  2551.   echo $ac_n "(cached) $ac_c" 1>&4
  2552. else
  2553.   cat > conftest.$ac_ext <<EOF
  2554. #line 2555 "configure"
  2555. #include "confdefs.h"
  2556. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2557. int main() { return 0; }
  2558. int t() {
  2559.  
  2560. /* The GNU C library defines this for functions which it implements
  2561.     to always fail with ENOSYS.  Some functions are actually named
  2562.     something starting with __ and the normal name is an alias.  */
  2563. #if defined (__stub_getmntent) || defined (__stub___getmntent)
  2564. choke me
  2565. #else
  2566. /* Override any gcc2 internal prototype to avoid an error.  */
  2567. char getmntent(); getmntent();
  2568. #endif
  2569.  
  2570. ; return 0; }
  2571. EOF
  2572. if eval $ac_link; then
  2573.   rm -rf conftest*
  2574.   eval "ac_cv_func_getmntent=yes"
  2575. else
  2576.   rm -rf conftest*
  2577.   eval "ac_cv_func_getmntent=no"
  2578. fi
  2579. rm -f conftest*
  2580.  
  2581. fi
  2582. if eval "test \"`echo '$ac_cv_func_'getmntent`\" = yes"; then
  2583.   echo "$ac_t""yes" 1>&4
  2584.   cat >> confdefs.h <<\EOF
  2585. #define HAVE_GETMNTENT 1
  2586. EOF
  2587.  
  2588. else
  2589.   echo "$ac_t""no" 1>&4
  2590. fi
  2591.  
  2592.  
  2593. if test $ac_cv_func_getmntent = yes; then
  2594.  
  2595.   # This system has the getmntent function.
  2596.   # Determine whether it's the one-argument variant or the two-argument one.
  2597.  
  2598.   if test -z "$list_mounted_fs"; then
  2599.     # 4.3BSD, SunOS, HP-UX, Dynix, Irix
  2600.     echo $ac_n "checking for one-argument getmntent function""... $ac_c" 1>&4
  2601.     if eval "test \"`echo '${'fu_cv_sys_mounted_getmntent1'+set}'`\" = set"; then
  2602.   echo $ac_n "(cached) $ac_c" 1>&4
  2603. else
  2604.   test $ac_cv_header_mntent_h = yes \
  2605.            && fu_cv_sys_mounted_getmntent1=yes \
  2606.            || fu_cv_sys_mounted_getmntent1=no
  2607. fi
  2608.  
  2609.     echo "$ac_t""$fu_cv_sys_mounted_getmntent1" 1>&4
  2610.     if test $fu_cv_sys_mounted_getmntent1 = yes; then
  2611.       list_mounted_fs=found
  2612.       cat >> confdefs.h <<\EOF
  2613. #define MOUNTED_GETMNTENT1 1
  2614. EOF
  2615.  
  2616.     fi
  2617.   fi
  2618.  
  2619.   if test -z "$list_mounted_fs"; then
  2620.     # SVR4
  2621.     echo $ac_n "checking for two-argument getmntent function""... $ac_c" 1>&4
  2622.     if eval "test \"`echo '${'fu_cv_sys_mounted_getmntent2'+set}'`\" = set"; then
  2623.   echo $ac_n "(cached) $ac_c" 1>&4
  2624. else
  2625.   cat > conftest.$ac_ext <<EOF
  2626. #line 2627 "configure"
  2627. #include "confdefs.h"
  2628. #include <sys/mnttab.h>
  2629. EOF
  2630. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  2631.   egrep "getmntent" >/dev/null 2>&1; then
  2632.   rm -rf conftest*
  2633.   fu_cv_sys_mounted_getmntent2=yes
  2634. else
  2635.   rm -rf conftest*
  2636.   fu_cv_sys_mounted_getmntent2=no
  2637. fi
  2638. rm -f conftest*
  2639.  
  2640. fi
  2641.  
  2642.     echo "$ac_t""$fu_cv_sys_mounted_getmntent2" 1>&4
  2643.     if test $fu_cv_sys_mounted_getmntent2 = yes; then
  2644.       list_mounted_fs=found
  2645.       cat >> confdefs.h <<\EOF
  2646. #define MOUNTED_GETMNTENT2 1
  2647. EOF
  2648.  
  2649.     fi
  2650.   fi
  2651.  
  2652.   if test -z "$list_mounted_fs"; then
  2653.     { echo "configure: error: could not determine how to read list of mounted filesystems" 1>&2; exit 1; }
  2654.   fi
  2655.  
  2656. fi
  2657.  
  2658. if test -z "$list_mounted_fs"; then
  2659.   # DEC Alpha running OSF/1.
  2660.   echo $ac_n "checking for getfsstat function""... $ac_c" 1>&4
  2661.   if eval "test \"`echo '${'fu_cv_sys_mounted_getsstat'+set}'`\" = set"; then
  2662.   echo $ac_n "(cached) $ac_c" 1>&4
  2663. else
  2664.   cat > conftest.$ac_ext <<EOF
  2665. #line 2666 "configure"
  2666. #include "confdefs.h"
  2667.  
  2668. #include <sys/types.h>
  2669. #include <sys/mount.h>
  2670. #include <sys/fs_types.h>
  2671. int main() { return 0; }
  2672. int t() {
  2673. struct statfs *stats;
  2674.   numsys = getfsstat ((struct statfs *)0, 0L, MNT_WAIT); 
  2675. ; return 0; }
  2676. EOF
  2677. if eval $ac_link; then
  2678.   rm -rf conftest*
  2679.   fu_cv_sys_mounted_getsstat=yes
  2680. else
  2681.   rm -rf conftest*
  2682.   fu_cv_sys_mounted_getsstat=no
  2683. fi
  2684. rm -f conftest*
  2685.  
  2686. fi
  2687.  
  2688.   echo "$ac_t""$fu_cv_sys_mounted_getsstat" 1>&4
  2689.   if test $fu_cv_sys_mounted_getsstat = yes; then
  2690.     list_mounted_fs=found
  2691.     cat >> confdefs.h <<\EOF
  2692. #define MOUNTED_GETFSSTAT 1
  2693. EOF
  2694.  
  2695.   fi
  2696. fi
  2697.  
  2698. if test -z "$list_mounted_fs"; then
  2699.   # AIX.
  2700.   echo $ac_n "checking for mntctl function and struct vmount""... $ac_c" 1>&4
  2701.   if eval "test \"`echo '${'fu_cv_sys_mounted_vmount'+set}'`\" = set"; then
  2702.   echo $ac_n "(cached) $ac_c" 1>&4
  2703. else
  2704.   cat > conftest.$ac_ext <<EOF
  2705. #line 2706 "configure"
  2706. #include "confdefs.h"
  2707. #include <fshelp.h>
  2708. EOF
  2709. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  2710. ac_err=`grep -v '^ *+' conftest.out`
  2711. if test -z "$ac_err"; then
  2712.   rm -rf conftest*
  2713.   fu_cv_sys_mounted_vmount=yes
  2714. else
  2715.   echo "$ac_err" >&5
  2716.   rm -rf conftest*
  2717.   fu_cv_sys_mounted_vmount=no
  2718. fi
  2719. rm -f conftest*
  2720. fi
  2721.  
  2722.   echo "$ac_t""$fu_cv_sys_mounted_vmount" 1>&4
  2723.   if test $fu_cv_sys_mounted_vmount = yes; then
  2724.     list_mounted_fs=found
  2725.     cat >> confdefs.h <<\EOF
  2726. #define MOUNTED_VMOUNT 1
  2727. EOF
  2728.  
  2729.   fi
  2730. fi
  2731.  
  2732. if test -z "$list_mounted_fs"; then
  2733.   # SVR3
  2734.   echo $ac_n "checking for FIXME existence of three headers""... $ac_c" 1>&4
  2735.   if eval "test \"`echo '${'fu_cv_sys_mounted_fread_fstyp'+set}'`\" = set"; then
  2736.   echo $ac_n "(cached) $ac_c" 1>&4
  2737. else
  2738.   cat > conftest.$ac_ext <<EOF
  2739. #line 2740 "configure"
  2740. #include "confdefs.h"
  2741.  
  2742. #include <sys/statfs.h>
  2743. #include <sys/fstyp.h>
  2744. #include <mnttab.h>
  2745. EOF
  2746. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  2747. ac_err=`grep -v '^ *+' conftest.out`
  2748. if test -z "$ac_err"; then
  2749.   rm -rf conftest*
  2750.   fu_cv_sys_mounted_fread_fstyp=yes
  2751. else
  2752.   echo "$ac_err" >&5
  2753.   rm -rf conftest*
  2754.   fu_cv_sys_mounted_fread_fstyp=no
  2755. fi
  2756. rm -f conftest*
  2757. fi
  2758.  
  2759.   echo "$ac_t""$fu_cv_sys_mounted_fread_fstyp" 1>&4
  2760.   if test $fu_cv_sys_mounted_fread_fstyp = yes; then
  2761.     list_mounted_fs=found
  2762.     cat >> confdefs.h <<\EOF
  2763. #define MOUNTED_FREAD_FSTYP 1
  2764. EOF
  2765.  
  2766.   fi
  2767. fi
  2768.  
  2769. if test -z "$list_mounted_fs"; then
  2770.   # 4.4BSD and DEC OSF/1.
  2771.   echo $ac_n "checking for getmntinfo function""... $ac_c" 1>&4
  2772.   if eval "test \"`echo '${'fu_cv_sys_mounted_getmntinfo'+set}'`\" = set"; then
  2773.   echo $ac_n "(cached) $ac_c" 1>&4
  2774. else
  2775.   
  2776.       ok=
  2777.       if test $ac_cv_func_getmntinfo = yes; then
  2778.     cat > conftest.$ac_ext <<EOF
  2779. #line 2780 "configure"
  2780. #include "confdefs.h"
  2781. #include <sys/mount.h>
  2782. EOF
  2783. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  2784.   egrep "f_type;" >/dev/null 2>&1; then
  2785.   rm -rf conftest*
  2786.   ok=yes
  2787. fi
  2788. rm -f conftest*
  2789.  
  2790.       fi
  2791.       test -n "$ok" \
  2792.       && fu_cv_sys_mounted_getmntinfo=yes \
  2793.       || fu_cv_sys_mounted_getmntinfo=no
  2794.     
  2795. fi
  2796.  
  2797.   echo "$ac_t""$fu_cv_sys_mounted_getmntinfo" 1>&4
  2798.   if test $fu_cv_sys_mounted_getmntinfo = yes; then
  2799.     list_mounted_fs=found
  2800.     cat >> confdefs.h <<\EOF
  2801. #define MOUNTED_GETMNTINFO 1
  2802. EOF
  2803.  
  2804.   fi
  2805. fi
  2806.  
  2807. # FIXME: add a test for netbsd-1.1 here
  2808.  
  2809. if test -z "$list_mounted_fs"; then
  2810.   # Ultrix
  2811.   echo $ac_n "checking for getmnt function""... $ac_c" 1>&4
  2812.   if eval "test \"`echo '${'fu_cv_sys_mounted_getmnt'+set}'`\" = set"; then
  2813.   echo $ac_n "(cached) $ac_c" 1>&4
  2814. else
  2815.   cat > conftest.$ac_ext <<EOF
  2816. #line 2817 "configure"
  2817. #include "confdefs.h"
  2818.  
  2819. #include <sys/fs_types.h>
  2820. #include <sys/mount.h>
  2821. EOF
  2822. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  2823. ac_err=`grep -v '^ *+' conftest.out`
  2824. if test -z "$ac_err"; then
  2825.   rm -rf conftest*
  2826.   fu_cv_sys_mounted_getmnt=yes
  2827. else
  2828.   echo "$ac_err" >&5
  2829.   rm -rf conftest*
  2830.   fu_cv_sys_mounted_getmnt=no
  2831. fi
  2832. rm -f conftest*
  2833. fi
  2834.  
  2835.   echo "$ac_t""$fu_cv_sys_mounted_getmnt" 1>&4
  2836.   if test $fu_cv_sys_mounted_getmnt = yes; then
  2837.     list_mounted_fs=found
  2838.     cat >> confdefs.h <<\EOF
  2839. #define MOUNTED_GETMNT 1
  2840. EOF
  2841.  
  2842.   fi
  2843. fi
  2844.  
  2845. if test -z "$list_mounted_fs"; then
  2846.   # SVR2
  2847.   echo $ac_n "checking whether it is possible to resort to fread on /etc/mnttab""... $ac_c" 1>&4
  2848.   if eval "test \"`echo '${'fu_cv_sys_mounted_fread'+set}'`\" = set"; then
  2849.   echo $ac_n "(cached) $ac_c" 1>&4
  2850. else
  2851.   cat > conftest.$ac_ext <<EOF
  2852. #line 2853 "configure"
  2853. #include "confdefs.h"
  2854. #include <mnttab.h>
  2855. EOF
  2856. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  2857. ac_err=`grep -v '^ *+' conftest.out`
  2858. if test -z "$ac_err"; then
  2859.   rm -rf conftest*
  2860.   fu_cv_sys_mounted_fread=yes
  2861. else
  2862.   echo "$ac_err" >&5
  2863.   rm -rf conftest*
  2864.   fu_cv_sys_mounted_fread=no
  2865. fi
  2866. rm -f conftest*
  2867. fi
  2868.  
  2869.   echo "$ac_t""$fu_cv_sys_mounted_fread" 1>&4
  2870.   if test $fu_cv_sys_mounted_fread = yes; then
  2871.     list_mounted_fs=found
  2872.     cat >> confdefs.h <<\EOF
  2873. #define MOUNTED_FREAD 1
  2874. EOF
  2875.  
  2876.   fi
  2877. fi
  2878.  
  2879. if test -z "$list_mounted_fs"; then
  2880.   { echo "configure: error: could not determine how to read list of mounted filesystems" 1>&2; exit 1; }
  2881.   # FIXME -- no need to abort building the whole package
  2882.   # Can't build mountlist.c or anything that needs its functions
  2883. fi
  2884.  
  2885. echo "checking how to get filesystem space usage" 1>&4
  2886. space=no
  2887.  
  2888. # Here we'll compromise a little (and perform only the link test)
  2889. # since it seems there are no variants of the statvfs function.
  2890. if test $space = no; then
  2891.   # SVR4
  2892.   for ac_func in statvfs
  2893. do
  2894. echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  2895. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  2896.   echo $ac_n "(cached) $ac_c" 1>&4
  2897. else
  2898.   cat > conftest.$ac_ext <<EOF
  2899. #line 2900 "configure"
  2900. #include "confdefs.h"
  2901. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  2902. int main() { return 0; }
  2903. int t() {
  2904.  
  2905. /* The GNU C library defines this for functions which it implements
  2906.     to always fail with ENOSYS.  Some functions are actually named
  2907.     something starting with __ and the normal name is an alias.  */
  2908. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  2909. choke me
  2910. #else
  2911. /* Override any gcc2 internal prototype to avoid an error.  */
  2912. char $ac_func(); $ac_func();
  2913. #endif
  2914.  
  2915. ; return 0; }
  2916. EOF
  2917. if eval $ac_link; then
  2918.   rm -rf conftest*
  2919.   eval "ac_cv_func_$ac_func=yes"
  2920. else
  2921.   rm -rf conftest*
  2922.   eval "ac_cv_func_$ac_func=no"
  2923. fi
  2924. rm -f conftest*
  2925.  
  2926. fi
  2927. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  2928.   echo "$ac_t""yes" 1>&4
  2929.     ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'`
  2930.   cat >> confdefs.h <<EOF
  2931. #define $ac_tr_func 1
  2932. EOF
  2933.  
  2934. else
  2935.   echo "$ac_t""no" 1>&4
  2936. fi
  2937. done
  2938.  
  2939.   if test $ac_cv_func_statvfs = yes; then
  2940.     space=yes
  2941.     cat >> confdefs.h <<\EOF
  2942. #define STAT_STATVFS 1
  2943. EOF
  2944.  
  2945.   fi
  2946. fi
  2947.  
  2948. if test $space = no; then
  2949.   # DEC Alpha running OSF/1
  2950.   echo $ac_n "checking for 3-argument statfs function (DEC OSF/1)""... $ac_c" 1>&4
  2951.   if eval "test \"`echo '${'fu_cv_sys_stat_statfs3_osf1'+set}'`\" = set"; then
  2952.   echo $ac_n "(cached) $ac_c" 1>&4
  2953. else
  2954.   if test "$cross_compiling" = yes; then
  2955.   fu_cv_sys_stat_statfs3_osf1=no
  2956. else
  2957. cat > conftest.$ac_ext <<EOF
  2958. #line 2959 "configure"
  2959. #include "confdefs.h"
  2960.  
  2961. #include <sys/param.h>
  2962. #include <sys/types.h>
  2963. #include <sys/mount.h>
  2964.   main ()
  2965.   {
  2966.     struct statfs fsd;
  2967.     fsd.f_fsize = 0;
  2968.     exit (statfs (".", &fsd, sizeof (struct statfs)));
  2969.   }
  2970. EOF
  2971. eval $ac_link
  2972. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  2973.   fu_cv_sys_stat_statfs3_osf1=yes
  2974. else
  2975.   fu_cv_sys_stat_statfs3_osf1=no
  2976. fi
  2977. fi
  2978. rm -fr conftest*
  2979. fi
  2980.  
  2981.   echo "$ac_t""$fu_cv_sys_stat_statfs3_osf1" 1>&4
  2982.   if test $fu_cv_sys_stat_statfs3_osf1 = yes; then
  2983.     space=yes
  2984.     cat >> confdefs.h <<\EOF
  2985. #define STAT_STATFS3_OSF1 1
  2986. EOF
  2987.  
  2988.   fi
  2989. fi
  2990.  
  2991. if test $space = no; then
  2992. # AIX
  2993.   echo $ac_n "checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)""... $ac_c" 1>&4
  2994.   if eval "test \"`echo '${'fu_cv_sys_stat_statfs2_bsize'+set}'`\" = set"; then
  2995.   echo $ac_n "(cached) $ac_c" 1>&4
  2996. else
  2997.   if test "$cross_compiling" = yes; then
  2998.   fu_cv_sys_stat_statfs2_bsize=no
  2999. else
  3000. cat > conftest.$ac_ext <<EOF
  3001. #line 3002 "configure"
  3002. #include "confdefs.h"
  3003.  
  3004. #ifdef HAVE_SYS_PARAM_H
  3005. #include <sys/param.h>
  3006. #endif
  3007. #ifdef HAVE_SYS_MOUNT_H
  3008. #include <sys/mount.h>
  3009. #endif
  3010. #ifdef HAVE_SYS_VFS_H
  3011. #include <sys/vfs.h>
  3012. #endif
  3013.   main ()
  3014.   {
  3015.   struct statfs fsd;
  3016.   fsd.f_bsize = 0;
  3017.   exit (statfs (".", &fsd));
  3018.   }
  3019. EOF
  3020. eval $ac_link
  3021. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  3022.   fu_cv_sys_stat_statfs2_bsize=yes
  3023. else
  3024.   fu_cv_sys_stat_statfs2_bsize=no
  3025. fi
  3026. fi
  3027. rm -fr conftest*
  3028. fi
  3029.  
  3030.   echo "$ac_t""$fu_cv_sys_stat_statfs2_bsize" 1>&4
  3031.   if test $fu_cv_sys_stat_statfs2_bsize = yes; then
  3032.     space=yes
  3033.     cat >> confdefs.h <<\EOF
  3034. #define STAT_STATFS2_BSIZE 1
  3035. EOF
  3036.  
  3037.   fi
  3038. fi
  3039.  
  3040. if test $space = no; then
  3041. # SVR3
  3042.   echo $ac_n "checking for four-argument statfs (AIX-3.2.5, SVR3)""... $ac_c" 1>&4
  3043.   if eval "test \"`echo '${'fu_cv_sys_stat_statfs4'+set}'`\" = set"; then
  3044.   echo $ac_n "(cached) $ac_c" 1>&4
  3045. else
  3046.   if test "$cross_compiling" = yes; then
  3047.   fu_cv_sys_stat_statfs4=no
  3048. else
  3049. cat > conftest.$ac_ext <<EOF
  3050. #line 3051 "configure"
  3051. #include "confdefs.h"
  3052. #include <sys/types.h>
  3053. #include <sys/statfs.h>
  3054.   main ()
  3055.   {
  3056.   struct statfs fsd;
  3057.   exit (statfs (".", &fsd, sizeof fsd, 0));
  3058.   }
  3059. EOF
  3060. eval $ac_link
  3061. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  3062.   fu_cv_sys_stat_statfs4=yes
  3063. else
  3064.   fu_cv_sys_stat_statfs4=no
  3065. fi
  3066. fi
  3067. rm -fr conftest*
  3068. fi
  3069.  
  3070.   echo "$ac_t""$fu_cv_sys_stat_statfs4" 1>&4
  3071.   if test $fu_cv_sys_stat_statfs4 = yes; then
  3072.     space=yes
  3073.     cat >> confdefs.h <<\EOF
  3074. #define STAT_STATFS4 1
  3075. EOF
  3076.  
  3077.   fi
  3078. fi
  3079.  
  3080. if test $space = no; then
  3081. # 4.4BSD and NetBSD
  3082.   echo $ac_n "checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)""... $ac_c" 1>&4
  3083.   if eval "test \"`echo '${'fu_cv_sys_stat_statfs2_fsize'+set}'`\" = set"; then
  3084.   echo $ac_n "(cached) $ac_c" 1>&4
  3085. else
  3086.   if test "$cross_compiling" = yes; then
  3087.   fu_cv_sys_stat_statfs2_fsize=no
  3088. else
  3089. cat > conftest.$ac_ext <<EOF
  3090. #line 3091 "configure"
  3091. #include "confdefs.h"
  3092. #include <sys/types.h>
  3093. #ifdef HAVE_SYS_PARAM_H
  3094. #include <sys/param.h>
  3095. #endif
  3096. #ifdef HAVE_SYS_MOUNT_H
  3097. #include <sys/mount.h>
  3098. #endif
  3099.   main ()
  3100.   {
  3101.   struct statfs fsd;
  3102.   fsd.f_fsize = 0;
  3103.   exit (statfs (".", &fsd));
  3104.   }
  3105. EOF
  3106. eval $ac_link
  3107. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  3108.   fu_cv_sys_stat_statfs2_fsize=yes
  3109. else
  3110.   fu_cv_sys_stat_statfs2_fsize=no
  3111. fi
  3112. fi
  3113. rm -fr conftest*
  3114. fi
  3115.  
  3116.   echo "$ac_t""$fu_cv_sys_stat_statfs2_fsize" 1>&4
  3117.   if test $fu_cv_sys_stat_statfs2_fsize = yes; then
  3118.     space=yes
  3119.     cat >> confdefs.h <<\EOF
  3120. #define STAT_STATFS2_FSIZE 1
  3121. EOF
  3122.  
  3123.   fi
  3124. fi
  3125.  
  3126. if test $space = no; then
  3127.   # Ultrix
  3128.   echo $ac_n "checking for two-argument statfs with struct fs_data (Ultrix)""... $ac_c" 1>&4
  3129.   if eval "test \"`echo '${'fu_cv_sys_stat_fs_data'+set}'`\" = set"; then
  3130.   echo $ac_n "(cached) $ac_c" 1>&4
  3131. else
  3132.   if test "$cross_compiling" = yes; then
  3133.   fu_cv_sys_stat_fs_data=no
  3134. else
  3135. cat > conftest.$ac_ext <<EOF
  3136. #line 3137 "configure"
  3137. #include "confdefs.h"
  3138. #include <sys/types.h>
  3139. #ifdef HAVE_SYS_PARAM_H
  3140. #include <sys/param.h>
  3141. #endif
  3142. #ifdef HAVE_SYS_MOUNT_H
  3143. #include <sys/mount.h>
  3144. #endif
  3145. #ifdef HAVE_SYS_FS_TYPES_H
  3146. #include <sys/fs_types.h>
  3147. #endif
  3148.   main ()
  3149.   {
  3150.   struct fs_data fsd;
  3151.   /* Ultrix's statfs returns 1 for success,
  3152.      0 for not mounted, -1 for failure.  */
  3153.   exit (statfs (".", &fsd) != 1);
  3154.   }
  3155. EOF
  3156. eval $ac_link
  3157. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  3158.   fu_cv_sys_stat_fs_data=yes
  3159. else
  3160.   fu_cv_sys_stat_fs_data=no
  3161. fi
  3162. fi
  3163. rm -fr conftest*
  3164. fi
  3165.  
  3166.   echo "$ac_t""$fu_cv_sys_stat_fs_data" 1>&4
  3167.   if test $fu_cv_sys_stat_fs_data = yes; then
  3168.     space=yes
  3169.     cat >> confdefs.h <<\EOF
  3170. #define STAT_STATFS2_FS_DATA 1
  3171. EOF
  3172.  
  3173.   fi
  3174. fi
  3175.  
  3176. if test $space = no; then
  3177. # SVR2
  3178. cat > conftest.$ac_ext <<EOF
  3179. #line 3180 "configure"
  3180. #include "confdefs.h"
  3181. #include <sys/filsys.h>
  3182. EOF
  3183. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3184. ac_err=`grep -v '^ *+' conftest.out`
  3185. if test -z "$ac_err"; then
  3186.   rm -rf conftest*
  3187.   cat >> confdefs.h <<\EOF
  3188. #define STAT_READ_FILSYS 1
  3189. EOF
  3190.  space=yes
  3191. else
  3192.   echo "$ac_err" >&5
  3193. fi
  3194. rm -f conftest*
  3195. fi
  3196.  
  3197. if test -n "$list_mounted_fs" && test $space != no; then
  3198.   PROGS="$PROGS df" LIBOBJS="$LIBOBJS fsusage.o mountlist.o"
  3199. fi
  3200.  
  3201. for ac_func in ftruncate
  3202. do
  3203. echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  3204. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  3205.   echo $ac_n "(cached) $ac_c" 1>&4
  3206. else
  3207.   cat > conftest.$ac_ext <<EOF
  3208. #line 3209 "configure"
  3209. #include "confdefs.h"
  3210. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  3211. int main() { return 0; }
  3212. int t() {
  3213.  
  3214. /* The GNU C library defines this for functions which it implements
  3215.     to always fail with ENOSYS.  Some functions are actually named
  3216.     something starting with __ and the normal name is an alias.  */
  3217. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3218. choke me
  3219. #else
  3220. /* Override any gcc2 internal prototype to avoid an error.  */
  3221. char $ac_func(); $ac_func();
  3222. #endif
  3223.  
  3224. ; return 0; }
  3225. EOF
  3226. if eval $ac_link; then
  3227.   rm -rf conftest*
  3228.   eval "ac_cv_func_$ac_func=yes"
  3229. else
  3230.   rm -rf conftest*
  3231.   eval "ac_cv_func_$ac_func=no"
  3232. fi
  3233. rm -f conftest*
  3234.  
  3235. fi
  3236. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3237.   echo "$ac_t""yes" 1>&4
  3238.     ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'`
  3239.   cat >> confdefs.h <<EOF
  3240. #define $ac_tr_func 1
  3241. EOF
  3242.  
  3243. else
  3244.   echo "$ac_t""no" 1>&4
  3245. ftruncate_missing=yes
  3246. fi
  3247. done
  3248.  
  3249.  
  3250. if test "$ftruncate_missing" = yes; then
  3251.   echo $ac_n "checking fcntl emulation of ftruncate""... $ac_c" 1>&4
  3252.   if eval "test \"`echo '${'fu_cv_sys_ftruncate_emulation'+set}'`\" = set"; then
  3253.   echo $ac_n "(cached) $ac_c" 1>&4
  3254. else
  3255.   cat > conftest.$ac_ext <<EOF
  3256. #line 3257 "configure"
  3257. #include "confdefs.h"
  3258.  
  3259. #include <sys/types.h>
  3260. #include <fcntl.h>
  3261. int main() { return 0; }
  3262. int t() {
  3263.  
  3264. #if !defined(F_CHSIZE) && !defined(F_FREESP)
  3265. chsize();
  3266. #endif
  3267.  
  3268. ; return 0; }
  3269. EOF
  3270. if eval $ac_link; then
  3271.   rm -rf conftest*
  3272.   fu_cv_sys_ftruncate_emulation=yes
  3273. else
  3274.   rm -rf conftest*
  3275.   fu_cv_sys_ftruncate_emulation=no
  3276. fi
  3277. rm -f conftest*
  3278.  
  3279. fi
  3280.  
  3281.   echo "$ac_t""$fu_cv_sys_ftruncate_emulation" 1>&4
  3282.   if test $fu_cv_sys_ftruncate_emulation = yes; then
  3283.     LIBOBJS="$LIBOBJS ftruncate.o"
  3284.   fi
  3285. fi
  3286.  
  3287. case "$LIBOBJS" in
  3288. *rename.o*)
  3289.   LIBPROGS="$LIBPROGS mvdir"
  3290.   ;;
  3291. esac
  3292.  
  3293. # If we don't yet have getgroups, see if it's in -lbsd.
  3294. # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
  3295. echo $ac_n "checking for getgroups""... $ac_c" 1>&4
  3296. if eval "test \"`echo '${'ac_cv_func_getgroups'+set}'`\" = set"; then
  3297.   echo $ac_n "(cached) $ac_c" 1>&4
  3298. else
  3299.   cat > conftest.$ac_ext <<EOF
  3300. #line 3301 "configure"
  3301. #include "confdefs.h"
  3302. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  3303. int main() { return 0; }
  3304. int t() {
  3305.  
  3306. /* The GNU C library defines this for functions which it implements
  3307.     to always fail with ENOSYS.  Some functions are actually named
  3308.     something starting with __ and the normal name is an alias.  */
  3309. #if defined (__stub_getgroups) || defined (__stub___getgroups)
  3310. choke me
  3311. #else
  3312. /* Override any gcc2 internal prototype to avoid an error.  */
  3313. char getgroups(); getgroups();
  3314. #endif
  3315.  
  3316. ; return 0; }
  3317. EOF
  3318. if eval $ac_link; then
  3319.   rm -rf conftest*
  3320.   eval "ac_cv_func_getgroups=yes"
  3321. else
  3322.   rm -rf conftest*
  3323.   eval "ac_cv_func_getgroups=no"
  3324. fi
  3325. rm -f conftest*
  3326.  
  3327. fi
  3328. if eval "test \"`echo '$ac_cv_func_'getgroups`\" = yes"; then
  3329.   echo "$ac_t""yes" 1>&4
  3330.   :
  3331. else
  3332.   echo "$ac_t""no" 1>&4
  3333. echo $ac_n "checking for -lbsd""... $ac_c" 1>&4
  3334. if eval "test \"`echo '${'ac_cv_lib_bsd'+set}'`\" = set"; then
  3335.   echo $ac_n "(cached) $ac_c" 1>&4
  3336. else
  3337.   ac_save_LIBS="$LIBS"
  3338. LIBS="$LIBS -lbsd "
  3339. cat > conftest.$ac_ext <<EOF
  3340. #line 3341 "configure"
  3341. #include "confdefs.h"
  3342.  
  3343. int main() { return 0; }
  3344. int t() {
  3345. getgroups()
  3346. ; return 0; }
  3347. EOF
  3348. if eval $ac_link; then
  3349.   rm -rf conftest*
  3350.   eval "ac_cv_lib_bsd=yes"
  3351. else
  3352.   rm -rf conftest*
  3353.   eval "ac_cv_lib_bsd=no"
  3354. fi
  3355. rm -f conftest*
  3356. LIBS="$ac_save_LIBS"
  3357.  
  3358. fi
  3359. if eval "test \"`echo '$ac_cv_lib_'bsd`\" = yes"; then
  3360.   echo "$ac_t""yes" 1>&4
  3361.     ac_tr_lib=HAVE_LIB`echo bsd | tr 'a-z' 'A-Z'`
  3362.   cat >> confdefs.h <<EOF
  3363. #define $ac_tr_lib 1
  3364. EOF
  3365.  
  3366.   LIBS="$LIBS -lbsd"
  3367.  
  3368. else
  3369.   echo "$ac_t""no" 1>&4
  3370. fi
  3371.  
  3372. fi
  3373.  
  3374.  
  3375. # Check for libypsec.a on Dolphin M88K machines.
  3376. echo $ac_n "checking for -lypsec""... $ac_c" 1>&4
  3377. if eval "test \"`echo '${'ac_cv_lib_ypsec'+set}'`\" = set"; then
  3378.   echo $ac_n "(cached) $ac_c" 1>&4
  3379. else
  3380.   ac_save_LIBS="$LIBS"
  3381. LIBS="$LIBS -lypsec "
  3382. cat > conftest.$ac_ext <<EOF
  3383. #line 3384 "configure"
  3384. #include "confdefs.h"
  3385.  
  3386. int main() { return 0; }
  3387. int t() {
  3388. main()
  3389. ; return 0; }
  3390. EOF
  3391. if eval $ac_link; then
  3392.   rm -rf conftest*
  3393.   eval "ac_cv_lib_ypsec=yes"
  3394. else
  3395.   rm -rf conftest*
  3396.   eval "ac_cv_lib_ypsec=no"
  3397. fi
  3398. rm -f conftest*
  3399. LIBS="$ac_save_LIBS"
  3400.  
  3401. fi
  3402. if eval "test \"`echo '$ac_cv_lib_'ypsec`\" = yes"; then
  3403.   echo "$ac_t""yes" 1>&4
  3404.     ac_tr_lib=HAVE_LIB`echo ypsec | tr '[a-z]' '[A-Z]'`
  3405.   cat >> confdefs.h <<EOF
  3406. #define $ac_tr_lib 1
  3407. EOF
  3408.  
  3409.   LIBS="$LIBS -lypsec"
  3410.  
  3411. else
  3412.   echo "$ac_t""no" 1>&4
  3413. fi
  3414.  
  3415.  
  3416. # m88k running dgux 5.4 needs this
  3417. echo $ac_n "checking for -lldgc""... $ac_c" 1>&4
  3418. if eval "test \"`echo '${'ac_cv_lib_ldgc'+set}'`\" = set"; then
  3419.   echo $ac_n "(cached) $ac_c" 1>&4
  3420. else
  3421.   ac_save_LIBS="$LIBS"
  3422. LIBS="$LIBS -lldgc "
  3423. cat > conftest.$ac_ext <<EOF
  3424. #line 3425 "configure"
  3425. #include "confdefs.h"
  3426.  
  3427. int main() { return 0; }
  3428. int t() {
  3429. main()
  3430. ; return 0; }
  3431. EOF
  3432. if eval $ac_link; then
  3433.   rm -rf conftest*
  3434.   eval "ac_cv_lib_ldgc=yes"
  3435. else
  3436.   rm -rf conftest*
  3437.   eval "ac_cv_lib_ldgc=no"
  3438. fi
  3439. rm -f conftest*
  3440. LIBS="$ac_save_LIBS"
  3441.  
  3442. fi
  3443. if eval "test \"`echo '$ac_cv_lib_'ldgc`\" = yes"; then
  3444.   echo "$ac_t""yes" 1>&4
  3445.     ac_tr_lib=HAVE_LIB`echo ldgc | tr '[a-z]' '[A-Z]'`
  3446.   cat >> confdefs.h <<EOF
  3447. #define $ac_tr_lib 1
  3448. EOF
  3449.  
  3450.   LIBS="$LIBS -lldgc"
  3451.  
  3452. else
  3453.   echo "$ac_t""no" 1>&4
  3454. fi
  3455.  
  3456.  
  3457. echo "checking for AFS" 1>&4
  3458. test -d /afs && cat >> confdefs.h <<\EOF
  3459. #define AFS 1
  3460. EOF
  3461.  
  3462.  
  3463. trap '' 1 2 15
  3464. if test -w $cache_file; then
  3465. echo "updating cache $cache_file"
  3466. cat > $cache_file <<\EOF
  3467. # This file is a shell script that caches the results of configure
  3468. # tests run on this system so they can be shared between configure
  3469. # scripts and configure runs.  It is not useful on other systems.
  3470. # If it contains results you don't want to keep, you may remove or edit it.
  3471. #
  3472. # By default, configure uses ./config.cache as the cache file,
  3473. # creating it if it does not exist already.  You can give configure
  3474. # the --cache-file=FILE option to use a different cache file; that is
  3475. # what configure does when it calls configure scripts in
  3476. # subdirectories, so they share the cache.
  3477. # Giving --cache-file=/dev/null disables caching, for debugging configure.
  3478. # config.status only pays attention to the cache file if you give it the
  3479. # --recheck option to rerun configure.
  3480. #
  3481. EOF
  3482. # Ultrix sh set writes to stderr and can't be redirected directly.
  3483. (set) 2>&1 |
  3484.   sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/: \${\1='\2'}/p" \
  3485.   >> $cache_file
  3486. else
  3487. echo "not updating unwritable cache $cache_file"
  3488. fi
  3489.  
  3490. trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
  3491.  
  3492. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  3493. # Let make expand exec_prefix.
  3494. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  3495.  
  3496. # Any assignment to VPATH causes Sun make to only execute
  3497. # the first set of double-colon rules, so remove it if not needed.
  3498. # If there is a colon in the path, we need to keep it.
  3499. if test "x$srcdir" = x.; then
  3500.   ac_vpsub='/^[     ]*VPATH[     ]*=[^:]*$/d'
  3501. fi
  3502.  
  3503. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  3504.  
  3505. DEFS=-DHAVE_CONFIG_H
  3506.  
  3507. # Without the "./", some shells look in PATH for config.status.
  3508. : ${CONFIG_STATUS=./config.status}
  3509.  
  3510. echo creating $CONFIG_STATUS
  3511. rm -f $CONFIG_STATUS
  3512. cat > $CONFIG_STATUS <<EOF
  3513. #!/bin/sh
  3514. # Generated automatically by configure.
  3515. # Run this file to recreate the current configuration.
  3516. # This directory was configured as follows,
  3517. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  3518. #
  3519. # $0 $ac_configure_args
  3520. #
  3521. # Compiler output produced by configure, useful for debugging
  3522. # configure, is in ./config.log if it exists.
  3523.  
  3524. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  3525. for ac_option
  3526. do
  3527.   case "\$ac_option" in
  3528.   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  3529.     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  3530.     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  3531.   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  3532.     echo "$CONFIG_STATUS generated by autoconf version 2.0"
  3533.     exit 0 ;;
  3534.   -help | --help | --hel | --he | --h)
  3535.     echo "\$ac_cs_usage"; exit 0 ;;
  3536.   *) echo "\$ac_cs_usage"; exit 1 ;;
  3537.   esac
  3538. done
  3539.  
  3540. ac_given_srcdir=$srcdir
  3541. ac_given_INSTALL="$INSTALL"
  3542.  
  3543. trap 'rm -fr Makefile doc/Makefile lib/Makefile man/Makefile src/Makefile config.h conftest*; exit 1' 1 2 15
  3544.  
  3545. # Protect against being on the right side of a sed subst in config.status. 
  3546. sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; 
  3547.  s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
  3548. $ac_vpsub
  3549. $extrasub
  3550. s%@CFLAGS@%$CFLAGS%g
  3551. s%@CPPFLAGS@%$CPPFLAGS%g
  3552. s%@CXXFLAGS@%$CXXFLAGS%g
  3553. s%@DEFS@%$DEFS%g
  3554. s%@LDFLAGS@%$LDFLAGS%g
  3555. s%@LIBS@%$LIBS%g
  3556. s%@exec_prefix@%$exec_prefix%g
  3557. s%@prefix@%$prefix%g
  3558. s%@program_transform_name@%$program_transform_name%g
  3559. s%@SET_MAKE@%$SET_MAKE%g
  3560. s%@PROGS@%$PROGS%g
  3561. s%@LN@%$LN%g
  3562. s%@MV@%$MV%g
  3563. s%@RM@%$RM%g
  3564. s%@LIBPROGS@%$LIBPROGS%g
  3565. s%@CC@%$CC%g
  3566. s%@CPP@%$CPP%g
  3567. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  3568. s%@INSTALL_DATA@%$INSTALL_DATA%g
  3569. s%@RANLIB@%$RANLIB%g
  3570. s%@YACC@%$YACC%g
  3571. s%@LIBOBJS@%$LIBOBJS%g
  3572. s%@ALLOCA@%$ALLOCA%g
  3573.  
  3574. CEOF
  3575. EOF
  3576. cat >> $CONFIG_STATUS <<EOF
  3577.  
  3578. CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile lib/Makefile man/Makefile src/Makefile"}
  3579. EOF
  3580. cat >> $CONFIG_STATUS <<\EOF
  3581. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  3582.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  3583.   case "$ac_file" in
  3584.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  3585.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  3586.   *) ac_file_in="${ac_file}.in" ;;
  3587.   esac
  3588.  
  3589.   # Adjust relative srcdir, etc. for subdirectories.
  3590.  
  3591.   # Remove last slash and all that follows it.  Not all systems have dirname.
  3592.   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  3593.   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  3594.     # The file is in a subdirectory.
  3595.     test ! -d "$ac_dir" && mkdir "$ac_dir"
  3596.     ac_dir_suffix="/$ac_dir"
  3597.     # A "../" for each directory in $ac_dir_suffix.
  3598.     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  3599.   else
  3600.     ac_dir_suffix= ac_dots=
  3601.   fi
  3602.  
  3603.   case "$ac_given_srcdir" in
  3604.   .)  srcdir=.
  3605.       if test -z "$ac_dots"; then top_srcdir=.
  3606.       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  3607.   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  3608.   *) # Relative path.
  3609.     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  3610.     top_srcdir="$ac_dots$ac_given_srcdir" ;;
  3611.   esac
  3612.  
  3613.   case "$ac_given_INSTALL" in
  3614.   [/$]*) INSTALL="$ac_given_INSTALL" ;;
  3615.   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  3616.   esac
  3617.   echo creating "$ac_file"
  3618.   rm -f "$ac_file"
  3619.   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  3620.   case "$ac_file" in
  3621.   *Makefile*) ac_comsub="1i\\
  3622. # $configure_input" ;;
  3623.   *) ac_comsub= ;;
  3624.   esac
  3625.   sed -e "$ac_comsub
  3626. s%@configure_input@%$configure_input%g
  3627. s%@srcdir@%$srcdir%g
  3628. s%@top_srcdir@%$top_srcdir%g
  3629. s%@INSTALL@%$INSTALL%g
  3630. " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
  3631. fi; done
  3632. rm -f conftest.subs
  3633.  
  3634. # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
  3635. # NAME is the cpp macro being defined and VALUE is the value it is being given.
  3636. #
  3637. # ac_d sets the value in "#define NAME VALUE" lines.
  3638. ac_dA='s%^\([     ]*\)#\([     ]*define[     ][     ]*\)'
  3639. ac_dB='\([     ][     ]*\)[^     ]*%\1#\2'
  3640. ac_dC='\3'
  3641. ac_dD='%g'
  3642. # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  3643. ac_uA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  3644. ac_uB='\([     ]\)%\1#\2define\3'
  3645. ac_uC=' '
  3646. ac_uD='\4%g'
  3647. # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  3648. ac_eA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  3649. ac_eB='$%\1#\2define\3'
  3650. ac_eC=' '
  3651. ac_eD='%g'
  3652.  
  3653. CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"}
  3654. for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
  3655.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  3656.   case "$ac_file" in
  3657.   *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
  3658.        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  3659.   *) ac_file_in="${ac_file}.in" ;;
  3660.   esac
  3661.  
  3662.   echo creating $ac_file
  3663.  
  3664.   rm -f conftest.frag conftest.in conftest.out
  3665.   cp $ac_given_srcdir/$ac_file_in conftest.in
  3666.  
  3667. EOF
  3668.  
  3669. # Transform confdefs.h into a sed script conftest.vals that substitutes
  3670. # the proper values into config.h.in to produce config.h.  And first:
  3671. # Protect against being on the right side of a sed subst in config.status. 
  3672. # Protect against being in an unquoted here document in config.status.
  3673. rm -f conftest.vals
  3674. cat > conftest.hdr <<\EOF
  3675. s/[\\&%]/\\&/g
  3676. s%[\\$`]%\\&%g
  3677. s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
  3678. s%ac_d%ac_u%gp
  3679. s%ac_u%ac_e%gp
  3680. EOF
  3681. sed -n -f conftest.hdr confdefs.h > conftest.vals
  3682. rm -f conftest.hdr
  3683.  
  3684. # This sed command replaces #undef with comments.  This is necessary, for
  3685. # example, in the case of _POSIX_SOURCE, which is predefined and required
  3686. # on some systems where configure will not decide to define it.
  3687. cat >> conftest.vals <<\EOF
  3688. s%^[     ]*#[     ]*undef[     ][     ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
  3689. EOF
  3690.  
  3691. # Break up conftest.vals because some shells have a limit on
  3692. # the size of here documents, and old seds have small limits too.
  3693. # Maximum number of lines to put in a single here document.
  3694. ac_max_here_lines=12
  3695.  
  3696. rm -f conftest.tail
  3697. while :
  3698. do
  3699.   ac_lines=`grep -c . conftest.vals`
  3700.   # grep -c gives empty output for an empty file on some AIX systems.
  3701.   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  3702.   # Write a limited-size here document to conftest.frag.
  3703.   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  3704.   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
  3705.   echo 'CEOF
  3706.   sed -f conftest.frag conftest.in > conftest.out
  3707.   rm -f conftest.in
  3708.   mv conftest.out conftest.in
  3709. ' >> $CONFIG_STATUS
  3710.   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  3711.   rm -f conftest.vals
  3712.   mv conftest.tail conftest.vals
  3713. done
  3714. rm -f conftest.vals
  3715.  
  3716. cat >> $CONFIG_STATUS <<\EOF
  3717.   rm -f conftest.frag conftest.h
  3718.   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  3719.   cat conftest.in >> conftest.h
  3720.   rm -f conftest.in
  3721.   if cmp -s $ac_file conftest.h 2>/dev/null; then
  3722.     echo "$ac_file is unchanged"
  3723.     rm -f conftest.h
  3724.   else
  3725.     rm -f $ac_file
  3726.     mv conftest.h $ac_file
  3727.   fi
  3728. fi; done
  3729.  
  3730.  
  3731. echo > stamp-h
  3732. exit 0
  3733. EOF
  3734. chmod +x $CONFIG_STATUS
  3735. rm -fr confdefs* $ac_clean_files
  3736. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS
  3737.