home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 9 / FreshFishVol9-CD2.bin / bbs / gnu / sharutils-4.1-src.lha / sharutils-4.1 / configure < prev    next >
Encoding:
Text File  |  1994-12-23  |  59.9 KB  |  2,317 lines

  1. #!/bin/sh
  2.  
  3. # Guess values for system-dependent variables and create Makefiles.
  4. # Generated automatically using autoconf version 2.1 
  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=/gnu
  13. # Any additions from configure.in:
  14. ac_help="$ac_help
  15.   --disable-uucode        disable installation of uuencode and uudecode"
  16. ac_help="$ac_help
  17.   --with-dmalloc          use dmalloc, as in dmalloc.tar.gz from
  18.                           @/ftp.antaire.com:antaire/src/dmalloc."
  19.  
  20. # Initialize some variables set by options.
  21. # The variables have the same names as the options, with
  22. # dashes changed to underlines.
  23. build=NONE
  24. cache_file=./config.cache
  25. exec_prefix=NONE
  26. host=NONE
  27. no_create=
  28. nonopt=NONE
  29. no_recursion=
  30. prefix=NONE
  31. program_prefix=NONE
  32. program_suffix=NONE
  33. program_transform_name=s,x,x,
  34. silent=
  35. site=
  36. srcdir=
  37. target=NONE
  38. verbose=
  39. x_includes=NONE
  40. x_libraries=NONE
  41.  
  42. # Initialize some other variables.
  43. subdirs=
  44.  
  45. ac_prev=
  46. for ac_option
  47. do
  48.  
  49.   # If the previous option needs an argument, assign it.
  50.   if test -n "$ac_prev"; then
  51.     eval "$ac_prev=\$ac_option"
  52.     ac_prev=
  53.     continue
  54.   fi
  55.  
  56.   case "$ac_option" in
  57.   -*=*) ac_optarg=`/bin/echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  58.   *) ac_optarg= ;;
  59.   esac
  60.  
  61.   # Accept the important Cygnus configure options, so we can diagnose typos.
  62.  
  63.   case "$ac_option" in
  64.  
  65.   -build | --build | --buil | --bui | --bu | --b)
  66.     ac_prev=build ;;
  67.   -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  68.     build="$ac_optarg" ;;
  69.  
  70.   -cache-file | --cache-file | --cache-fil | --cache-fi \
  71.   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  72.     ac_prev=cache_file ;;
  73.   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  74.   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  75.     cache_file="$ac_optarg" ;;
  76.  
  77.   -disable-* | --disable-*)
  78.     ac_feature=`/bin/echo $ac_option|sed -e 's/-*disable-//'`
  79.     # Reject names that are not valid shell variable names.
  80.     if test -n "`/bin/echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  81.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  82.     fi
  83.     ac_feature=`/bin/echo $ac_feature| sed 's/-/_/g'`
  84.     eval "enable_${ac_feature}=no" ;;
  85.  
  86.   -enable-* | --enable-*)
  87.     ac_feature=`/bin/echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  88.     # Reject names that are not valid shell variable names.
  89.     if test -n "`/bin/echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  90.       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  91.     fi
  92.     ac_feature=`/bin/echo $ac_feature| sed 's/-/_/g'`
  93.     case "$ac_option" in
  94.       *=*) ;;
  95.       *) ac_optarg=yes ;;
  96.     esac
  97.     eval "enable_${ac_feature}='$ac_optarg'" ;;
  98.  
  99.   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  100.   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  101.   | --exec | --exe | --ex)
  102.     ac_prev=exec_prefix ;;
  103.   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  104.   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  105.   | --exec=* | --exe=* | --ex=*)
  106.     exec_prefix="$ac_optarg" ;;
  107.  
  108.   -gas | --gas | --ga | --g)
  109.     # Obsolete; use --with-gas.
  110.     with_gas=yes ;;
  111.  
  112.   -help | --help | --hel | --he)
  113.     # Omit some internal or obsolete options to make the list less imposing.
  114.     # This message is too long to be a string in the A/UX 3.1 sh.
  115.     cat << EOF
  116. Usage: configure [options] [host]
  117. Options: [defaults in brackets after descriptions]
  118. Configuration:
  119.   --cache-file=FILE       cache test results in FILE
  120.   --help                  print this message
  121.   --no-create             do not create output files
  122.   --quiet, --silent       do not print \`checking...' messages
  123.   --version               print the version of autoconf that created configure
  124. Directory and file names:
  125.   --prefix=PREFIX         install architecture-independent files in PREFIX
  126.                           [$ac_default_prefix]
  127.   --exec-prefix=PREFIX    install architecture-dependent files in PREFIX
  128.                           [same as prefix]
  129.   --srcdir=DIR            find the sources in DIR [configure dir or ..]
  130.   --program-prefix=PREFIX prepend PREFIX to installed program names
  131.   --program-suffix=SUFFIX append SUFFIX to installed program names
  132.   --program-transform-name=PROGRAM run sed PROGRAM on installed program names
  133. Host type:
  134.   --build=BUILD           configure for building on BUILD [BUILD=HOST]
  135.   --host=HOST             configure for HOST [guessed]
  136.   --target=TARGET         configure for TARGET [TARGET=HOST]
  137. Features and packages:
  138.   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  139.   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  140.   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  141.   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  142.   --x-includes=DIR        X include files are in DIR
  143.   --x-libraries=DIR       X library files are in DIR
  144. --enable and --with options recognized:$ac_help
  145. EOF
  146.     exit 0 ;;
  147.  
  148.   -host | --host | --hos | --ho)
  149.     ac_prev=host ;;
  150.   -host=* | --host=* | --hos=* | --ho=*)
  151.     host="$ac_optarg" ;;
  152.  
  153.   -nfp | --nfp | --nf)
  154.     # Obsolete; use --without-fp.
  155.     with_fp=no ;;
  156.  
  157.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  158.   | --no-cr | --no-c)
  159.     no_create=yes ;;
  160.  
  161.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  162.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  163.     no_recursion=yes ;;
  164.  
  165.   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  166.     ac_prev=prefix ;;
  167.   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  168.     prefix="$ac_optarg" ;;
  169.  
  170.   -program-prefix | --program-prefix | --program-prefi | --program-pref \
  171.   | --program-pre | --program-pr | --program-p)
  172.     ac_prev=program_prefix ;;
  173.   -program-prefix=* | --program-prefix=* | --program-prefi=* \
  174.   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  175.     program_prefix="$ac_optarg" ;;
  176.  
  177.   -program-suffix | --program-suffix | --program-suffi | --program-suff \
  178.   | --program-suf | --program-su | --program-s)
  179.     ac_prev=program_suffix ;;
  180.   -program-suffix=* | --program-suffix=* | --program-suffi=* \
  181.   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  182.     program_suffix="$ac_optarg" ;;
  183.  
  184.   -program-transform-name | --program-transform-name \
  185.   | --program-transform-nam | --program-transform-na \
  186.   | --program-transform-n | --program-transform- \
  187.   | --program-transform | --program-transfor \
  188.   | --program-transfo | --program-transf \
  189.   | --program-trans | --program-tran \
  190.   | --progr-tra | --program-tr | --program-t)
  191.     ac_prev=program_transform_name ;;
  192.   -program-transform-name=* | --program-transform-name=* \
  193.   | --program-transform-nam=* | --program-transform-na=* \
  194.   | --program-transform-n=* | --program-transform-=* \
  195.   | --program-transform=* | --program-transfor=* \
  196.   | --program-transfo=* | --program-transf=* \
  197.   | --program-trans=* | --program-tran=* \
  198.   | --progr-tra=* | --program-tr=* | --program-t=*)
  199.     program_transform_name="$ac_optarg" ;;
  200.  
  201.   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  202.   | -silent | --silent | --silen | --sile | --sil)
  203.     silent=yes ;;
  204.  
  205.   -site | --site | --sit)
  206.     ac_prev=site ;;
  207.   -site=* | --site=* | --sit=*)
  208.     site="$ac_optarg" ;;
  209.  
  210.   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  211.     ac_prev=srcdir ;;
  212.   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  213.     srcdir="$ac_optarg" ;;
  214.  
  215.   -target | --target | --targe | --targ | --tar | --ta | --t)
  216.     ac_prev=target ;;
  217.   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  218.     target="$ac_optarg" ;;
  219.  
  220.   -v | -verbose | --verbose | --verbos | --verbo | --verb)
  221.     verbose=yes ;;
  222.  
  223.   -version | --version | --versio | --versi | --vers)
  224.     echo "configure generated by autoconf version 2.1"
  225.     exit 0 ;;
  226.  
  227.   -with-* | --with-*)
  228.     ac_package=`/bin/echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  229.     # Reject names that are not valid shell variable names.
  230.     if test -n "`/bin/echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  231.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  232.     fi
  233.     ac_package=`/bin/echo $ac_package| sed 's/-/_/g'`
  234.     case "$ac_option" in
  235.       *=*) ;;
  236.       *) ac_optarg=yes ;;
  237.     esac
  238.     eval "with_${ac_package}='$ac_optarg'" ;;
  239.  
  240.   -without-* | --without-*)
  241.     ac_package=`/bin/echo $ac_option|sed -e 's/-*without-//'`
  242.     # Reject names that are not valid shell variable names.
  243.     if test -n "`/bin/echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  244.       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  245.     fi
  246.     ac_package=`/bin/echo $ac_package| sed 's/-/_/g'`
  247.     eval "with_${ac_package}=no" ;;
  248.  
  249.   --x)
  250.     # Obsolete; use --with-x.
  251.     with_x=yes ;;
  252.  
  253.   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  254.   | --x-incl | --x-inc | --x-in | --x-i)
  255.     ac_prev=x_includes ;;
  256.   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  257.   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  258.     x_includes="$ac_optarg" ;;
  259.  
  260.   -x-libraries | --x-libraries | --x-librarie | --x-librari \
  261.   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  262.     ac_prev=x_libraries ;;
  263.   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  264.   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  265.     x_libraries="$ac_optarg" ;;
  266.  
  267.   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  268.     ;;
  269.  
  270.   *) 
  271.     if test -n "`/bin/echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  272.       echo "configure: warning: $ac_option: invalid host type" 1>&2
  273.     fi
  274.     if test "x$nonopt" != xNONE; then
  275.       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  276.     fi
  277.     nonopt="$ac_option"
  278.     ;;
  279.  
  280.   esac
  281. done
  282.  
  283. if test -n "$ac_prev"; then
  284.   { echo "configure: error: missing argument to --`/bin/echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  285. fi
  286.  
  287. trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
  288.  
  289. # File descriptor usage:
  290. # 0 unused; standard input
  291. # 1 file creation
  292. # 2 errors and warnings
  293. # 3 unused; some systems may open it to /dev/tty
  294. # 4 checking for... messages and results
  295. # 5 compiler messages saved in config.log
  296. if test "$silent" = yes; then
  297.   exec 4>/dev/null
  298. else
  299.   exec 4>&1
  300. fi
  301. exec 5>./config.log
  302.  
  303. echo "\
  304. This file contains any messages produced by compilers while
  305. running configure, to aid debugging if configure makes a mistake.
  306. " 1>&5
  307.  
  308. # Strip out --no-create and --no-recursion so they do not pile up.
  309. # Also quote any args containing shell metacharacters.
  310. ac_configure_args=
  311. for ac_arg
  312. do
  313.   case "$ac_arg" in
  314.   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  315.   | --no-cr | --no-c) ;;
  316.   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  317.   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  318.   *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  319.   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  320.   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  321.   esac
  322. done
  323.  
  324. # NLS nuisances.
  325. # Only set LANG and LC_ALL to C if already set.
  326. # These must not be set unconditionally because not all systems understand
  327. # e.g. LANG=C (notably SCO).
  328. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  329. if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
  330.  
  331. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  332. rm -rf conftest* confdefs.h
  333. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  334. /bin/echo > confdefs.h
  335.  
  336. # A filename unique to this package, relative to the directory that
  337. # configure is in, which we can look for to find out if srcdir is correct.
  338. ac_unique_file=shar.c
  339.  
  340. # Find the source files, if location was not specified.
  341. if test -z "$srcdir"; then
  342.   ac_srcdir_defaulted=yes
  343.   # Try the directory containing this script, then its parent.
  344.   ac_prog=$0
  345.   ac_confdir=`/bin/echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  346.   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  347.   srcdir=$ac_confdir
  348.   if test ! -r $srcdir/$ac_unique_file; then
  349.     srcdir=..
  350.   fi
  351. else
  352.   ac_srcdir_defaulted=no
  353. fi
  354. if test ! -r $srcdir/$ac_unique_file; then
  355.   if test "$ac_srcdir_defaulted" = yes; then
  356.     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  357.   else
  358.     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  359.   fi
  360. fi
  361. srcdir=`/bin/echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
  362.  
  363. # Prefer explicitly selected file to automatically selected ones.
  364. if test -z "$CONFIG_SITE"; then
  365.   if test "x$prefix" != xNONE; then
  366.     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  367.   else
  368.     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  369.   fi
  370. fi
  371. for ac_site_file in $CONFIG_SITE; do
  372.   if test -r "$ac_site_file"; then
  373.     echo "loading site script $ac_site_file"
  374.     . "$ac_site_file"
  375.   fi
  376. done
  377.  
  378. if test -r "$cache_file"; then
  379.   echo "loading cache $cache_file"
  380.   . $cache_file
  381. else
  382.   echo "creating cache $cache_file"
  383.   > $cache_file
  384. fi
  385.  
  386. ac_ext=c
  387. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  388. ac_cpp='$CPP $CPPFLAGS'
  389. ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
  390. ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
  391.  
  392. if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  393.   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  394.   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  395.     ac_n= ac_c='
  396. ' ac_t='    '
  397.   else
  398.     ac_n=-n ac_c= ac_t=
  399.   fi
  400. else
  401.   ac_n= ac_c='\c' ac_t=
  402. fi
  403.  
  404.  
  405.  
  406. if test "$program_transform_name" = s,x,x,; then
  407.   program_transform_name=
  408. else
  409.   # Double any \ or $.
  410.   echo 's,\\,\\\\,g; s,\$,$$,g' > conftestsed
  411.   program_transform_name="`/bin/echo $program_transform_name|sed -f conftestsed`"
  412.   rm -f conftestsed
  413. fi
  414. test "$program_prefix" != NONE &&
  415.   program_transform_name="s,^,${program_prefix},; $program_transform_name"
  416. # Use a double $ so make ignores it.
  417. test "$program_suffix" != NONE &&
  418.   program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
  419.  
  420. # sed with no file args requires a program.
  421. test "$program_transform_name" = "" && program_transform_name="s,x,x,"
  422.  
  423.  
  424. PRODUCT=sharutils
  425. VERSION=4.1
  426. PROGRAMS="shar unshar"
  427. cat >> confdefs.h <<EOF
  428. #define PRODUCT "$PRODUCT"
  429. EOF
  430.  
  431. cat >> confdefs.h <<EOF
  432. #define VERSION "$VERSION"
  433. EOF
  434.  
  435.  
  436.  
  437.  
  438.  
  439. # Extract the first word of "gcc", so it can be a program name with args.
  440. set dummy gcc; ac_word=$2
  441. /bin/echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  442. if eval "test \"`echo '${'ac_cv_prog_CC'+set}'`\" = set"; then
  443.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  444. else
  445.   if test -n "$CC"; then
  446.   ac_cv_prog_CC="$CC" # Let the user override the test.
  447. else
  448.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  449.   for ac_dir in $PATH; do
  450.     test -z "$ac_dir" && ac_dir=.
  451.     if test -f $ac_dir/$ac_word; then
  452.       ac_cv_prog_CC="gcc"
  453.       break
  454.     fi
  455.   done
  456.   IFS="$ac_save_ifs"
  457.   test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
  458. fi
  459. fi
  460. CC="$ac_cv_prog_CC"
  461. if test -n "$CC"; then
  462.   /bin/echo "$ac_t""$CC" 1>&4
  463. else
  464.   /bin/echo "$ac_t""no" 1>&4
  465. fi
  466.  
  467.  
  468. /bin/echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&4
  469. if eval "test \"`echo '${'ac_cv_prog_gcc'+set}'`\" = set"; then
  470.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  471. else
  472.   cat > conftest.c <<EOF
  473. #ifdef __GNUC__
  474.   yes;
  475. #endif
  476. EOF
  477. if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
  478.   ac_cv_prog_gcc=yes
  479. else
  480.   ac_cv_prog_gcc=no
  481. fi
  482. fi
  483. /bin/echo "$ac_t""$ac_cv_prog_gcc" 1>&4
  484. if test $ac_cv_prog_gcc = yes; then
  485.   GCC=yes
  486.   if test "${CFLAGS+set}" != set; then
  487.     /bin/echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&4
  488. if eval "test \"`echo '${'ac_cv_prog_gcc_g'+set}'`\" = set"; then
  489.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  490. else
  491.   echo 'void f(){}' > conftest.c
  492. if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
  493.   ac_cv_prog_gcc_g=yes
  494. else
  495.   ac_cv_prog_gcc_g=no
  496. fi
  497. rm -f conftest*
  498.  
  499. fi
  500.     /bin/echo "$ac_t""$ac_cv_prog_gcc_g" 1>&4
  501.     if test $ac_cv_prog_gcc_g = yes; then
  502.       # Amiga hack - suppress automatically using -g for now
  503.       # Also default to using -O2
  504.       CFLAGS="-O2"
  505.     else
  506.       CFLAGS="-O2"
  507.     fi
  508.   fi
  509. else
  510.   GCC=
  511.   test "${CFLAGS+set}" = set || CFLAGS="-g"
  512. fi
  513.  
  514. ac_aux_dir=
  515. for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  516.   if test -f $ac_dir/install-sh; then
  517.     ac_aux_dir=$ac_dir
  518.     ac_install_sh="$ac_aux_dir/install-sh -c"
  519.     break
  520.   elif test -f $ac_dir/install.sh; then
  521.     ac_aux_dir=$ac_dir
  522.     ac_install_sh="$ac_aux_dir/install.sh -c"
  523.     break
  524.   fi
  525. done
  526. if test -z "$ac_aux_dir"; then
  527.   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
  528. fi
  529. ac_config_guess=$ac_aux_dir/config.guess
  530. ac_config_sub=$ac_aux_dir/config.sub
  531. ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
  532.  
  533. # Find a good install program.  We prefer a C program (faster),
  534. # so one script is as good as another.  But avoid the broken or
  535. # incompatible versions:
  536. # SysV /etc/install, /usr/sbin/install
  537. # SunOS /usr/etc/install
  538. # IRIX /sbin/install
  539. # AIX /bin/install
  540. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  541. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  542. # ./install, which can be erroneously created by make from ./install.sh.
  543. /bin/echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&4
  544. if test -z "$INSTALL"; then
  545. if eval "test \"`echo '${'ac_cv_path_install'+set}'`\" = set"; then
  546.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  547. else
  548.     IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  549.   for ac_dir in $PATH; do
  550.     case "$ac_dir" in
  551.     ''|.|/gnu/etc) ;;
  552.     *)
  553.       # OSF1 and SCO ODT 3.0 have their own names for install.
  554.       for ac_prog in ginstall installbsd scoinst install; do
  555.         if test -f $ac_dir/$ac_prog; then
  556.       if test $ac_prog = install &&
  557.             grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  558.         # AIX install.  It has an incompatible calling convention.
  559.         # OSF/1 installbsd also uses dspmsg, but is usable.
  560.         :
  561.       else
  562.         ac_cv_path_install="$ac_dir/$ac_prog -c"
  563.         break 2
  564.       fi
  565.     fi
  566.       done
  567.       ;;
  568.     esac
  569.   done
  570.   IFS="$ac_save_ifs"
  571.   # As a last resort, use the slow shell script.
  572.   test -z "$ac_cv_path_install" && ac_cv_path_install="$ac_install_sh"
  573. fi
  574.   INSTALL="$ac_cv_path_install"
  575. fi
  576. /bin/echo "$ac_t""$INSTALL" 1>&4
  577.  
  578. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  579. # It thinks the first close brace ends the variable substitution.
  580. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  581.  
  582. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  583.  
  584. # Extract the first word of "ranlib", so it can be a program name with args.
  585. set dummy ranlib; ac_word=$2
  586. /bin/echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
  587. if eval "test \"`echo '${'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  588.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  589. else
  590.   if test -n "$RANLIB"; then
  591.   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  592. else
  593.   IFS="${IFS=     }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  594.   for ac_dir in $PATH; do
  595.     test -z "$ac_dir" && ac_dir=.
  596.     if test -f $ac_dir/$ac_word; then
  597.       ac_cv_prog_RANLIB="ranlib"
  598.       break
  599.     fi
  600.   done
  601.   IFS="$ac_save_ifs"
  602.   test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  603. fi
  604. fi
  605. RANLIB="$ac_cv_prog_RANLIB"
  606. if test -n "$RANLIB"; then
  607.   /bin/echo "$ac_t""$RANLIB" 1>&4
  608. else
  609.   /bin/echo "$ac_t""no" 1>&4
  610. fi
  611.  
  612.  
  613. /bin/echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&4
  614. # On Suns, sometimes $CPP names a directory.
  615. if test -n "$CPP" && test -d "$CPP"; then
  616.   CPP=
  617. fi
  618. if test -z "$CPP"; then
  619. if eval "test \"`echo '${'ac_cv_prog_CPP'+set}'`\" = set"; then
  620.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  621. else
  622.     # This must be in double quotes, not single quotes, because CPP may get
  623.   # substituted into the Makefile and "${CC-cc}" will confuse make.
  624.   CPP="${CC-cc} -E"
  625.   # On the NeXT, cc -E runs the code through the compiler's parser,
  626.   # not just through cpp.
  627.   cat > conftest.$ac_ext <<EOF
  628. #line 629 "configure"
  629. #include "confdefs.h"
  630. #include <assert.h>
  631. Syntax Error
  632. EOF
  633. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  634. ac_err=`grep -v '^ *+' conftest.out`
  635. if test -z "$ac_err"; then
  636.   :
  637. else
  638.   /bin/echo "$ac_err" >&5
  639.   rm -rf conftest*
  640.   CPP="${CC-cc} -E -traditional-cpp"
  641.   cat > conftest.$ac_ext <<EOF
  642. #line 643 "configure"
  643. #include "confdefs.h"
  644. #include <assert.h>
  645. Syntax Error
  646. EOF
  647. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  648. ac_err=`grep -v '^ *+' conftest.out`
  649. if test -z "$ac_err"; then
  650.   :
  651. else
  652.   /bin/echo "$ac_err" >&5
  653.   rm -rf conftest*
  654.   CPP=/lib/cpp
  655. fi
  656. rm -f conftest*
  657. fi
  658. rm -f conftest*
  659.   ac_cv_prog_CPP="$CPP"
  660. fi
  661. fi
  662. CPP="$ac_cv_prog_CPP"
  663. /bin/echo "$ac_t""$CPP" 1>&4
  664.  
  665. /bin/echo $ac_n "checking for AIX""... $ac_c" 1>&4
  666. cat > conftest.$ac_ext <<EOF
  667. #line 668 "configure"
  668. #include "confdefs.h"
  669. #ifdef _AIX
  670.   yes
  671. #endif
  672.  
  673. EOF
  674. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  675.   egrep "yes" >/dev/null 2>&1; then
  676.   rm -rf conftest*
  677.   /bin/echo "$ac_t""yes" 1>&4; cat >> confdefs.h <<\EOF
  678. #define _ALL_SOURCE 1
  679. EOF
  680.  
  681. else
  682.   rm -rf conftest*
  683.   /bin/echo "$ac_t""no" 1>&4
  684. fi
  685. rm -f conftest*
  686.  
  687.  
  688. /bin/echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&4
  689. if test -d /gnu/etc/conf/kconfig.d &&
  690.   grep _POSIX_VERSION /gnu/include/sys/unistd.h >/dev/null 2>&1
  691. then
  692.   /bin/echo "$ac_t""yes" 1>&4
  693.   ISC=yes # If later tests want to check for ISC.
  694.   cat >> confdefs.h <<\EOF
  695. #define _POSIX_SOURCE 1
  696. EOF
  697.  
  698.   if test "$GCC" = yes; then
  699.     CC="$CC -posix"
  700.   else
  701.     CC="$CC -Xp"
  702.   fi
  703. else
  704.   /bin/echo "$ac_t""no" 1>&4
  705.   ISC=
  706. fi
  707.  
  708. ac_safe=`/bin/echo "minix/config.h" | tr './\055' '___'`
  709. /bin/echo $ac_n "checking for minix/config.h""... $ac_c" 1>&4
  710. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  711.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  712. else
  713.   cat > conftest.$ac_ext <<EOF
  714. #line 715 "configure"
  715. #include "confdefs.h"
  716. #include <minix/config.h>
  717. EOF
  718. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  719. ac_err=`grep -v '^ *+' conftest.out`
  720. if test -z "$ac_err"; then
  721.   rm -rf conftest*
  722.   eval "ac_cv_header_$ac_safe=yes"
  723. else
  724.   /bin/echo "$ac_err" >&5
  725.   rm -rf conftest*
  726.   eval "ac_cv_header_$ac_safe=no"
  727. fi
  728. rm -f conftest*
  729. fi
  730. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  731.   /bin/echo "$ac_t""yes" 1>&4
  732.   MINIX=yes
  733. else
  734.   /bin/echo "$ac_t""no" 1>&4
  735. MINIX=
  736. fi
  737.  
  738. if test "$MINIX" = yes; then
  739.   cat >> confdefs.h <<\EOF
  740. #define _POSIX_SOURCE 1
  741. EOF
  742.  
  743.   cat >> confdefs.h <<\EOF
  744. #define _POSIX_1_SOURCE 2
  745. EOF
  746.  
  747.   cat >> confdefs.h <<\EOF
  748. #define _MINIX 1
  749. EOF
  750.  
  751. fi
  752.  
  753. # If we cannot run a trivial program, we must be cross compiling.
  754. /bin/echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&4
  755. if eval "test \"`echo '${'ac_cv_c_cross'+set}'`\" = set"; then
  756.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  757. else
  758.   if test "$cross_compiling" = yes; then
  759.   ac_cv_cross=yes
  760. else
  761. cat > conftest.$ac_ext <<EOF
  762. #line 763 "configure"
  763. #include "confdefs.h"
  764. main(){return(0);}
  765. EOF
  766. eval $ac_link
  767. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  768.   ac_cv_c_cross=no
  769. else
  770.   ac_cv_c_cross=yes
  771. fi
  772. fi
  773. rm -fr conftest*
  774. fi
  775. cross_compiling=$ac_cv_c_cross
  776. /bin/echo "$ac_t""$ac_cv_c_cross" 1>&4
  777.  
  778. if test $cross_compiling = no; then
  779.   /bin/echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&4
  780. if eval "test \"`echo '${'ac_cv_c_char_unsigned'+set}'`\" = set"; then
  781.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  782. else
  783.   if test "$GCC" = yes; then
  784.   # GCC predefines this symbol on systems where it applies.
  785. cat > conftest.$ac_ext <<EOF
  786. #line 787 "configure"
  787. #include "confdefs.h"
  788. #ifdef __CHAR_UNSIGNED__
  789.   yes
  790. #endif
  791.  
  792. EOF
  793. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  794.   egrep "yes" >/dev/null 2>&1; then
  795.   rm -rf conftest*
  796.   ac_cv_c_char_unsigned=yes
  797. else
  798.   rm -rf conftest*
  799.   ac_cv_c_char_unsigned=no
  800. fi
  801. rm -f conftest*
  802.  
  803. else
  804. if test "$cross_compiling" = yes; then
  805.     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  806. else
  807. cat > conftest.$ac_ext <<EOF
  808. #line 809 "configure"
  809. #include "confdefs.h"
  810. /* volatile prevents gcc2 from optimizing the test away on sparcs.  */
  811. #if !defined(__STDC__) || __STDC__ != 1
  812. #define volatile
  813. #endif
  814. main() {
  815.   volatile char c = 255; exit(c < 0);
  816. }
  817. EOF
  818. eval $ac_link
  819. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  820.   ac_cv_c_char_unsigned=yes
  821. else
  822.   ac_cv_c_char_unsigned=no
  823. fi
  824. fi
  825. rm -fr conftest*
  826. fi
  827. fi
  828. /bin/echo "$ac_t""$ac_cv_c_char_unsigned" 1>&4
  829. if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
  830.   cat >> confdefs.h <<\EOF
  831. #define __CHAR_UNSIGNED__ 1
  832. EOF
  833.  
  834. fi
  835.  
  836. fi
  837. /bin/echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&4
  838. if eval "test \"`echo '${'ac_cv_prog_cc_stdc'+set}'`\" = set"; then
  839.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  840. else
  841.   ac_cv_prog_cc_stdc=no
  842. ac_save_CFLAGS="$CFLAGS"
  843. # Don't try gcc -ansi; that turns off useful extensions and
  844. # breaks some systems' header files.
  845. # AIX            -qlanglvl=ansi
  846. # Ultrix and OSF/1    -std1
  847. # HP-UX            -Aa -D_HPUX_SOURCE
  848. # SVR4            -Xc
  849. for ac_arg in "" -qlanglvl=ansi -std1 "-Aa -D_HPUX_SOURCE" -Xc
  850. do
  851.   CFLAGS="$ac_save_CFLAGS $ac_arg"
  852.   cat > conftest.$ac_ext <<EOF
  853. #line 854 "configure"
  854. #include "confdefs.h"
  855. #if !defined(__STDC__) || __STDC__ != 1
  856. choke me
  857. #endif    
  858.  
  859. int main() { return 0; }
  860. int t() {
  861. int test (int i, double x);
  862. struct s1 {int (*f) (int a);};
  863. struct s2 {int (*f) (double a);};
  864. ; return 0; }
  865. EOF
  866. if eval $ac_compile; then
  867.   rm -rf conftest*
  868.   ac_cv_prog_cc_stdc="$ac_arg"; break
  869. fi
  870. rm -f conftest*
  871.  
  872. done
  873. CFLAGS="$ac_save_CFLAGS"
  874.  
  875. fi
  876.  
  877. /bin/echo "$ac_t""$ac_cv_prog_cc_stdc" 1>&4
  878. case "x$ac_cv_prog_cc_stdc" in
  879.   x|xno) ;;
  880.   *) CC="$CC $ac_cv_prog_cc_stdc" ;;
  881. esac
  882.  
  883.  
  884. /bin/echo $ac_n "checking for function prototypes""... $ac_c" 1>&4
  885. if test "$ac_cv_prog_cc_stdc" != no; then
  886.   /bin/echo "$ac_t""yes" 1>&4
  887.   cat >> confdefs.h <<\EOF
  888. #define PROTOTYPES 1
  889. EOF
  890.  
  891.   U= ANSI2KNR=
  892. else
  893.   /bin/echo "$ac_t""no" 1>&4
  894.   U=_ ANSI2KNR=ansi2knr
  895. fi
  896.  
  897. /bin/echo $ac_n "checking for working const""... $ac_c" 1>&4
  898. if eval "test \"`echo '${'ac_cv_c_const'+set}'`\" = set"; then
  899.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  900. else
  901.   cat > conftest.$ac_ext <<EOF
  902. #line 903 "configure"
  903. #include "confdefs.h"
  904.  
  905. int main() { return 0; }
  906. int t() {
  907.  
  908. /* Ultrix mips cc rejects this.  */
  909. typedef int charset[2]; const charset x;
  910. /* SunOS 4.1.1 cc rejects this.  */
  911. char const *const *ccp;
  912. char **p;
  913. /* NEC SVR4.0.2 mips cc rejects this.  */
  914. struct point {int x, y;};
  915. static struct point const zero;
  916. /* AIX XL C 1.02.0.0 rejects this.
  917.    It does not let you subtract one const X* pointer from another in an arm
  918.    of an if-expression whose if-part is not a constant expression */
  919. const char *g = "string";
  920. ccp = &g + (g ? g-g : 0);
  921. /* HPUX 7.0 cc rejects these. */
  922. ++ccp;
  923. p = (char**) ccp;
  924. ccp = (char const *const *) p;
  925. { /* SCO 3.2v4 cc rejects this.  */
  926.   char *t;
  927.   char const *s = 0 ? (char *) 0 : (char const *) 0;
  928.  
  929.   *t++ = 0;
  930. }
  931. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  932.   int x[] = {25, 17};
  933.   const int *foo = &x[0];
  934.   ++foo;
  935. }
  936. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  937.   typedef const int *iptr;
  938.   iptr p = 0;
  939.   ++p;
  940. }
  941. { /* AIX XL C 1.02.0.0 rejects this saying
  942.      "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  943.   struct s { int j; const int *ap[3]; };
  944.   struct s *b; b->j = 5;
  945. }
  946. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  947.   const int foo = 10;
  948. }
  949.  
  950. ; return 0; }
  951. EOF
  952. if eval $ac_compile; then
  953.   rm -rf conftest*
  954.   ac_cv_c_const=yes
  955. else
  956.   rm -rf conftest*
  957.   ac_cv_c_const=no
  958. fi
  959. rm -f conftest*
  960.  
  961. fi
  962. /bin/echo "$ac_t""$ac_cv_c_const" 1>&4
  963. if test $ac_cv_c_const = no; then
  964.   cat >> confdefs.h <<\EOF
  965. #define const 
  966. EOF
  967.  
  968. fi
  969.  
  970.  
  971. for ac_hdr in limits.h memory.h string.h sys/wait.h unistd.h
  972. do
  973. ac_safe=`/bin/echo "$ac_hdr" | tr './\055' '___'`
  974. /bin/echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4
  975. if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  976.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  977. else
  978.   cat > conftest.$ac_ext <<EOF
  979. #line 980 "configure"
  980. #include "confdefs.h"
  981. #include <$ac_hdr>
  982. EOF
  983. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  984. ac_err=`grep -v '^ *+' conftest.out`
  985. if test -z "$ac_err"; then
  986.   rm -rf conftest*
  987.   eval "ac_cv_header_$ac_safe=yes"
  988. else
  989.   /bin/echo "$ac_err" >&5
  990.   rm -rf conftest*
  991.   eval "ac_cv_header_$ac_safe=no"
  992. fi
  993. rm -f conftest*
  994. fi
  995. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  996.   /bin/echo "$ac_t""yes" 1>&4
  997.     ac_tr_hdr=HAVE_`/bin/echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  998.   cat >> confdefs.h <<EOF
  999. #define $ac_tr_hdr 1
  1000. EOF
  1001.  
  1002. else
  1003.   /bin/echo "$ac_t""no" 1>&4
  1004. fi
  1005. done
  1006.  
  1007. ac_header_dirent=no
  1008. for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
  1009. do
  1010. ac_safe=`/bin/echo "$ac_hdr" | tr './\055' '___'`
  1011. /bin/echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&4
  1012. if eval "test \"`echo '${'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
  1013.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1014. else
  1015.   cat > conftest.$ac_ext <<EOF
  1016. #line 1017 "configure"
  1017. #include "confdefs.h"
  1018. #include <sys/types.h>
  1019. #include <$ac_hdr>
  1020. int main() { return 0; }
  1021. int t() {
  1022. DIR *dirp = 0;
  1023. ; return 0; }
  1024. EOF
  1025. if eval $ac_compile; then
  1026.   rm -rf conftest*
  1027.   eval "ac_cv_header_dirent_$ac_safe=yes"
  1028. else
  1029.   rm -rf conftest*
  1030.   eval "ac_cv_header_dirent_$ac_safe=no"
  1031. fi
  1032. rm -f conftest*
  1033.  
  1034. fi
  1035. if eval "test \"`/bin/echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
  1036.   /bin/echo "$ac_t""yes" 1>&4
  1037.     ac_tr_hdr=HAVE_`/bin/echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
  1038.   cat >> confdefs.h <<EOF
  1039. #define $ac_tr_hdr 1
  1040. EOF
  1041.  ac_header_dirent=$ac_hdr; break
  1042. else
  1043.   /bin/echo "$ac_t""no" 1>&4
  1044. fi
  1045. done
  1046. # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
  1047. if test $ac_header_dirent = dirent.h; then
  1048. /bin/echo $ac_n "checking for -ldir""... $ac_c" 1>&4
  1049. if eval "test \"`echo '${'ac_cv_lib_dir'+set}'`\" = set"; then
  1050.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1051. else
  1052.   ac_save_LIBS="$LIBS"
  1053. LIBS="$LIBS -ldir "
  1054. cat > conftest.$ac_ext <<EOF
  1055. #line 1056 "configure"
  1056. #include "confdefs.h"
  1057.  
  1058. int main() { return 0; }
  1059. int t() {
  1060. opendir()
  1061. ; return 0; }
  1062. EOF
  1063. if eval $ac_link; then
  1064.   rm -rf conftest*
  1065.   eval "ac_cv_lib_dir=yes"
  1066. else
  1067.   rm -rf conftest*
  1068.   eval "ac_cv_lib_dir=no"
  1069. fi
  1070. rm -f conftest*
  1071. LIBS="$ac_save_LIBS"
  1072.  
  1073. fi
  1074. if eval "test \"`echo '$ac_cv_lib_'dir`\" = yes"; then
  1075.   /bin/echo "$ac_t""yes" 1>&4
  1076.   LIBS="$LIBS -ldir"
  1077. else
  1078.   /bin/echo "$ac_t""no" 1>&4
  1079. fi
  1080.  
  1081. else
  1082. /bin/echo $ac_n "checking for -lx""... $ac_c" 1>&4
  1083. if eval "test \"`echo '${'ac_cv_lib_x'+set}'`\" = set"; then
  1084.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1085. else
  1086.   ac_save_LIBS="$LIBS"
  1087. LIBS="$LIBS -lx "
  1088. cat > conftest.$ac_ext <<EOF
  1089. #line 1090 "configure"
  1090. #include "confdefs.h"
  1091.  
  1092. int main() { return 0; }
  1093. int t() {
  1094. opendir()
  1095. ; return 0; }
  1096. EOF
  1097. if eval $ac_link; then
  1098.   rm -rf conftest*
  1099.   eval "ac_cv_lib_x=yes"
  1100. else
  1101.   rm -rf conftest*
  1102.   eval "ac_cv_lib_x=no"
  1103. fi
  1104. rm -f conftest*
  1105. LIBS="$ac_save_LIBS"
  1106.  
  1107. fi
  1108. if eval "test \"`echo '$ac_cv_lib_'x`\" = yes"; then
  1109.   /bin/echo "$ac_t""yes" 1>&4
  1110.   LIBS="$LIBS -lx"
  1111. else
  1112.   /bin/echo "$ac_t""no" 1>&4
  1113. fi
  1114.  
  1115. fi
  1116.  
  1117. /bin/echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&4
  1118. if eval "test \"`echo '${'ac_cv_header_stat_broken'+set}'`\" = set"; then
  1119.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1120. else
  1121.   cat > conftest.$ac_ext <<EOF
  1122. #line 1123 "configure"
  1123. #include "confdefs.h"
  1124. #include <sys/types.h>
  1125. #include <sys/stat.h>
  1126. #ifdef S_ISBLK
  1127. # if S_ISBLK (S_IFDIR)
  1128. You lose.
  1129. # endif
  1130. # ifdef S_IFCHR
  1131. #  if S_ISBLK (S_IFCHR)
  1132. You lose.
  1133. #  endif
  1134. # endif
  1135. #endif
  1136.  
  1137. #ifdef S_ISLNK
  1138. # if S_ISLNK (S_IFREG)
  1139. You lose.
  1140. # endif
  1141. #endif
  1142.  
  1143. #ifdef S_ISSOCK
  1144. # if S_ISSOCK (S_IFREG)
  1145. You lose.
  1146. # endif
  1147. #endif
  1148.  
  1149. EOF
  1150. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1151.   egrep "You lose" >/dev/null 2>&1; then
  1152.   rm -rf conftest*
  1153.   ac_cv_header_stat_broken=yes
  1154. else
  1155.   rm -rf conftest*
  1156.   ac_cv_header_stat_broken=no
  1157. fi
  1158. rm -f conftest*
  1159.  
  1160. fi
  1161. /bin/echo "$ac_t""$ac_cv_header_stat_broken" 1>&4
  1162. if test $ac_cv_header_stat_broken = yes; then
  1163.   cat >> confdefs.h <<\EOF
  1164. #define STAT_MACROS_BROKEN 1
  1165. EOF
  1166.  
  1167. fi
  1168.  
  1169. /bin/echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4
  1170. if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then
  1171.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1172. else
  1173.   cat > conftest.$ac_ext <<EOF
  1174. #line 1175 "configure"
  1175. #include "confdefs.h"
  1176. #include <stdlib.h>
  1177. #include <stdarg.h>
  1178. #include <string.h>
  1179. #include <float.h>
  1180. EOF
  1181. eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1182. ac_err=`grep -v '^ *+' conftest.out`
  1183. if test -z "$ac_err"; then
  1184.   rm -rf conftest*
  1185.   ac_cv_header_stdc=yes
  1186. else
  1187.   /bin/echo "$ac_err" >&5
  1188.   rm -rf conftest*
  1189.   ac_cv_header_stdc=no
  1190. fi
  1191. rm -f conftest*
  1192.  
  1193. if test $ac_cv_header_stdc = yes; then
  1194.   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  1195. cat > conftest.$ac_ext <<EOF
  1196. #line 1197 "configure"
  1197. #include "confdefs.h"
  1198. #include <string.h>
  1199. EOF
  1200. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1201.   egrep "memchr" >/dev/null 2>&1; then
  1202.   :
  1203. else
  1204.   rm -rf conftest*
  1205.   ac_cv_header_stdc=no
  1206. fi
  1207. rm -f conftest*
  1208.  
  1209. fi
  1210.  
  1211. if test $ac_cv_header_stdc = yes; then
  1212.   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  1213. cat > conftest.$ac_ext <<EOF
  1214. #line 1215 "configure"
  1215. #include "confdefs.h"
  1216. #include <stdlib.h>
  1217. EOF
  1218. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1219.   egrep "free" >/dev/null 2>&1; then
  1220.   :
  1221. else
  1222.   rm -rf conftest*
  1223.   ac_cv_header_stdc=no
  1224. fi
  1225. rm -f conftest*
  1226.  
  1227. fi
  1228.  
  1229. if test $ac_cv_header_stdc = yes; then
  1230.   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  1231. if test "$cross_compiling" = yes; then
  1232.   ac_cv_header_stdc=no
  1233. else
  1234. cat > conftest.$ac_ext <<EOF
  1235. #line 1236 "configure"
  1236. #include "confdefs.h"
  1237. #include <ctype.h>
  1238. #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  1239. #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  1240. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  1241. int main () { int i; for (i = 0; i < 256; i++)
  1242. if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
  1243. exit (0); }
  1244.  
  1245. EOF
  1246. eval $ac_link
  1247. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1248.   :
  1249. else
  1250.   ac_cv_header_stdc=no
  1251. fi
  1252. fi
  1253. rm -fr conftest*
  1254. fi
  1255. fi
  1256. /bin/echo "$ac_t""$ac_cv_header_stdc" 1>&4
  1257. if test $ac_cv_header_stdc = yes; then
  1258.   cat >> confdefs.h <<\EOF
  1259. #define STDC_HEADERS 1
  1260. EOF
  1261.  
  1262. fi
  1263.  
  1264. /bin/echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&4
  1265. if eval "test \"`echo '${'ac_cv_struct_tm'+set}'`\" = set"; then
  1266.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1267. else
  1268.   cat > conftest.$ac_ext <<EOF
  1269. #line 1270 "configure"
  1270. #include "confdefs.h"
  1271. #include <sys/types.h>
  1272. #include <time.h>
  1273. int main() { return 0; }
  1274. int t() {
  1275. struct tm *tp; tp->tm_sec;
  1276. ; return 0; }
  1277. EOF
  1278. if eval $ac_compile; then
  1279.   rm -rf conftest*
  1280.   ac_cv_struct_tm=time.h
  1281. else
  1282.   rm -rf conftest*
  1283.   ac_cv_struct_tm=sys/time.h
  1284. fi
  1285. rm -f conftest*
  1286.  
  1287. fi
  1288. /bin/echo "$ac_t""$ac_cv_struct_tm" 1>&4
  1289. if test $ac_cv_struct_tm = sys/time.h; then
  1290.   cat >> confdefs.h <<\EOF
  1291. #define TM_IN_SYS_TIME 1
  1292. EOF
  1293.  
  1294. fi
  1295.  
  1296. /bin/echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&4
  1297. if eval "test \"`echo '${'ac_cv_struct_tm_zone'+set}'`\" = set"; then
  1298.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1299. else
  1300.   cat > conftest.$ac_ext <<EOF
  1301. #line 1302 "configure"
  1302. #include "confdefs.h"
  1303. #include <sys/types.h>
  1304. #include <$ac_cv_struct_tm>
  1305. int main() { return 0; }
  1306. int t() {
  1307. struct tm tm; tm.tm_zone;
  1308. ; return 0; }
  1309. EOF
  1310. if eval $ac_compile; then
  1311.   rm -rf conftest*
  1312.   ac_cv_struct_tm_zone=yes
  1313. else
  1314.   rm -rf conftest*
  1315.   ac_cv_struct_tm_zone=no
  1316. fi
  1317. rm -f conftest*
  1318.  
  1319. fi
  1320. /bin/echo "$ac_t""$ac_cv_struct_tm_zone" 1>&4
  1321. if test "$ac_cv_struct_tm_zone" = yes; then
  1322.   cat >> confdefs.h <<\EOF
  1323. #define HAVE_TM_ZONE 1
  1324. EOF
  1325.  
  1326. else
  1327.   /bin/echo $ac_n "checking for tzname""... $ac_c" 1>&4
  1328. if eval "test \"`echo '${'ac_cv_var_tzname'+set}'`\" = set"; then
  1329.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1330. else
  1331.   cat > conftest.$ac_ext <<EOF
  1332. #line 1333 "configure"
  1333. #include "confdefs.h"
  1334. #include <time.h>
  1335. #ifndef tzname /* For SGI.  */
  1336. extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
  1337. #endif
  1338. int main() { return 0; }
  1339. int t() {
  1340. atoi(*tzname);
  1341. ; return 0; }
  1342. EOF
  1343. if eval $ac_link; then
  1344.   rm -rf conftest*
  1345.   ac_cv_var_tzname=yes
  1346. else
  1347.   rm -rf conftest*
  1348.   ac_cv_var_tzname=no
  1349. fi
  1350. rm -f conftest*
  1351.  
  1352. fi
  1353.   /bin/echo "$ac_t""$ac_cv_var_tzname" 1>&4
  1354.   if test $ac_cv_var_tzname = yes; then
  1355.     cat >> confdefs.h <<\EOF
  1356. #define HAVE_TZNAME 1
  1357. EOF
  1358.  
  1359.   fi
  1360. fi
  1361.  
  1362. /bin/echo $ac_n "checking for size_t""... $ac_c" 1>&4
  1363. if eval "test \"`echo '${'ac_cv_type_size_t'+set}'`\" = set"; then
  1364.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1365. else
  1366.   cat > conftest.$ac_ext <<EOF
  1367. #line 1368 "configure"
  1368. #include "confdefs.h"
  1369. #include <sys/types.h>
  1370. #if STDC_HEADERS
  1371. #include <stdlib.h>
  1372. #endif
  1373. EOF
  1374. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1375.   egrep "size_t" >/dev/null 2>&1; then
  1376.   rm -rf conftest*
  1377.   ac_cv_type_size_t=yes
  1378. else
  1379.   rm -rf conftest*
  1380.   ac_cv_type_size_t=no
  1381. fi
  1382. rm -f conftest*
  1383.  
  1384. fi
  1385. /bin/echo "$ac_t""$ac_cv_type_size_t" 1>&4
  1386. if test $ac_cv_type_size_t = no; then
  1387.   cat >> confdefs.h <<\EOF
  1388. #define size_t unsigned
  1389. EOF
  1390.  
  1391. fi
  1392.  
  1393.  
  1394. for ac_func in basename fchmod getcwd memcpy strchr strerror uname
  1395. do
  1396. /bin/echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  1397. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  1398.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1399. else
  1400.   cat > conftest.$ac_ext <<EOF
  1401. #line 1402 "configure"
  1402. #include "confdefs.h"
  1403. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1404. /* Override any gcc2 internal prototype to avoid an error.  */
  1405. char $ac_func(); 
  1406.  
  1407. int main() { return 0; }
  1408. int t() {
  1409.  
  1410. /* The GNU C library defines this for functions which it implements
  1411.     to always fail with ENOSYS.  Some functions are actually named
  1412.     something starting with __ and the normal name is an alias.  */
  1413. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  1414. choke me
  1415. #else
  1416. $ac_func();
  1417. #endif
  1418.  
  1419. ; return 0; }
  1420. EOF
  1421. if eval $ac_link; then
  1422.   rm -rf conftest*
  1423.   eval "ac_cv_func_$ac_func=yes"
  1424. else
  1425.   rm -rf conftest*
  1426.   eval "ac_cv_func_$ac_func=no"
  1427. fi
  1428. rm -f conftest*
  1429.  
  1430. fi
  1431. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  1432.   /bin/echo "$ac_t""yes" 1>&4
  1433.     ac_tr_func=HAVE_`/bin/echo $ac_func | tr '[a-z]' '[A-Z]'`
  1434.   cat >> confdefs.h <<EOF
  1435. #define $ac_tr_func 1
  1436. EOF
  1437.  
  1438. else
  1439.   /bin/echo "$ac_t""no" 1>&4
  1440. fi
  1441. done
  1442.  
  1443. # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
  1444. # for constant arguments.  Useless!
  1445. /bin/echo $ac_n "checking for working alloca.h""... $ac_c" 1>&4
  1446. if eval "test \"`echo '${'ac_cv_header_alloca_h'+set}'`\" = set"; then
  1447.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1448. else
  1449.   cat > conftest.$ac_ext <<EOF
  1450. #line 1451 "configure"
  1451. #include "confdefs.h"
  1452. #include <alloca.h>
  1453. int main() { return 0; }
  1454. int t() {
  1455. char *p = alloca(2 * sizeof(int));
  1456. ; return 0; }
  1457. EOF
  1458. if eval $ac_link; then
  1459.   rm -rf conftest*
  1460.   ac_cv_header_alloca_h=yes
  1461. else
  1462.   rm -rf conftest*
  1463.   ac_cv_header_alloca_h=no
  1464. fi
  1465. rm -f conftest*
  1466.  
  1467. fi
  1468. /bin/echo "$ac_t""$ac_cv_header_alloca_h" 1>&4
  1469. if test $ac_cv_header_alloca_h = yes; then
  1470.   cat >> confdefs.h <<\EOF
  1471. #define HAVE_ALLOCA_H 1
  1472. EOF
  1473.  
  1474. fi
  1475.  
  1476. /bin/echo $ac_n "checking for alloca""... $ac_c" 1>&4
  1477. if eval "test \"`echo '${'ac_cv_func_alloca'+set}'`\" = set"; then
  1478.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1479. else
  1480.   cat > conftest.$ac_ext <<EOF
  1481. #line 1482 "configure"
  1482. #include "confdefs.h"
  1483.  
  1484. #ifdef __GNUC__
  1485. # define alloca __builtin_alloca
  1486. #else
  1487. # if HAVE_ALLOCA_H
  1488. #  include <alloca.h>
  1489. # else
  1490. #  ifdef _AIX
  1491.  #pragma alloca
  1492. #  else
  1493. #   ifndef alloca /* predefined by HP cc +Olibcalls */
  1494. char *alloca ();
  1495. #   endif
  1496. #  endif
  1497. # endif
  1498. #endif
  1499.  
  1500. int main() { return 0; }
  1501. int t() {
  1502. char *p = (char *) alloca(1);
  1503. ; return 0; }
  1504. EOF
  1505. if eval $ac_link; then
  1506.   rm -rf conftest*
  1507.   ac_cv_func_alloca=yes
  1508. else
  1509.   rm -rf conftest*
  1510.   ac_cv_func_alloca=no
  1511. fi
  1512. rm -f conftest*
  1513.  
  1514. fi
  1515. /bin/echo "$ac_t""$ac_cv_func_alloca" 1>&4
  1516. if test $ac_cv_func_alloca = yes; then
  1517.   cat >> confdefs.h <<\EOF
  1518. #define HAVE_ALLOCA 1
  1519. EOF
  1520.  
  1521. fi
  1522.  
  1523. if test $ac_cv_func_alloca = no; then
  1524.   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  1525.   # that cause trouble.  Some versions do not even contain alloca or
  1526.   # contain a buggy version.  If you still want to use their alloca,
  1527.   # use ar to extract alloca.o from them instead of compiling alloca.c.
  1528.   ALLOCA=alloca.o
  1529.   cat >> confdefs.h <<\EOF
  1530. #define C_ALLOCA 1
  1531. EOF
  1532.  
  1533.  
  1534. /bin/echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&4
  1535. if eval "test \"`echo '${'ac_cv_os_cray'+set}'`\" = set"; then
  1536.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1537. else
  1538.   cat > conftest.$ac_ext <<EOF
  1539. #line 1540 "configure"
  1540. #include "confdefs.h"
  1541. #if defined(CRAY) && ! defined(CRAY2)
  1542. webecray
  1543. #else
  1544. wenotbecray
  1545. #endif
  1546.  
  1547. EOF
  1548. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  1549.   egrep "webecray" >/dev/null 2>&1; then
  1550.   rm -rf conftest*
  1551.   ac_cv_os_cray=yes
  1552. else
  1553.   rm -rf conftest*
  1554.   ac_cv_os_cray=no
  1555. fi
  1556. rm -f conftest*
  1557.  
  1558. fi
  1559. /bin/echo "$ac_t""$ac_cv_os_cray" 1>&4
  1560. if test $ac_cv_os_cray = yes; then
  1561. /bin/echo $ac_n "checking for _getb67""... $ac_c" 1>&4
  1562. if eval "test \"`echo '${'ac_cv_func__getb67'+set}'`\" = set"; then
  1563.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1564. else
  1565.   cat > conftest.$ac_ext <<EOF
  1566. #line 1567 "configure"
  1567. #include "confdefs.h"
  1568. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1569. /* Override any gcc2 internal prototype to avoid an error.  */
  1570. char _getb67(); 
  1571.  
  1572. int main() { return 0; }
  1573. int t() {
  1574.  
  1575. /* The GNU C library defines this for functions which it implements
  1576.     to always fail with ENOSYS.  Some functions are actually named
  1577.     something starting with __ and the normal name is an alias.  */
  1578. #if defined (__stub__getb67) || defined (__stub____getb67)
  1579. choke me
  1580. #else
  1581. _getb67();
  1582. #endif
  1583.  
  1584. ; return 0; }
  1585. EOF
  1586. if eval $ac_link; then
  1587.   rm -rf conftest*
  1588.   eval "ac_cv_func__getb67=yes"
  1589. else
  1590.   rm -rf conftest*
  1591.   eval "ac_cv_func__getb67=no"
  1592. fi
  1593. rm -f conftest*
  1594.  
  1595. fi
  1596. if eval "test \"`echo '$ac_cv_func_'_getb67`\" = yes"; then
  1597.   /bin/echo "$ac_t""yes" 1>&4
  1598.   cat >> confdefs.h <<\EOF
  1599. #define CRAY_STACKSEG_END _getb67
  1600. EOF
  1601.  
  1602. else
  1603.   /bin/echo "$ac_t""no" 1>&4
  1604. /bin/echo $ac_n "checking for GETB67""... $ac_c" 1>&4
  1605. if eval "test \"`echo '${'ac_cv_func_GETB67'+set}'`\" = set"; then
  1606.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1607. else
  1608.   cat > conftest.$ac_ext <<EOF
  1609. #line 1610 "configure"
  1610. #include "confdefs.h"
  1611. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1612. /* Override any gcc2 internal prototype to avoid an error.  */
  1613. char GETB67(); 
  1614.  
  1615. int main() { return 0; }
  1616. int t() {
  1617.  
  1618. /* The GNU C library defines this for functions which it implements
  1619.     to always fail with ENOSYS.  Some functions are actually named
  1620.     something starting with __ and the normal name is an alias.  */
  1621. #if defined (__stub_GETB67) || defined (__stub___GETB67)
  1622. choke me
  1623. #else
  1624. GETB67();
  1625. #endif
  1626.  
  1627. ; return 0; }
  1628. EOF
  1629. if eval $ac_link; then
  1630.   rm -rf conftest*
  1631.   eval "ac_cv_func_GETB67=yes"
  1632. else
  1633.   rm -rf conftest*
  1634.   eval "ac_cv_func_GETB67=no"
  1635. fi
  1636. rm -f conftest*
  1637.  
  1638. fi
  1639. if eval "test \"`echo '$ac_cv_func_'GETB67`\" = yes"; then
  1640.   /bin/echo "$ac_t""yes" 1>&4
  1641.   cat >> confdefs.h <<\EOF
  1642. #define CRAY_STACKSEG_END GETB67
  1643. EOF
  1644.  
  1645. else
  1646.   /bin/echo "$ac_t""no" 1>&4
  1647. /bin/echo $ac_n "checking for getb67""... $ac_c" 1>&4
  1648. if eval "test \"`echo '${'ac_cv_func_getb67'+set}'`\" = set"; then
  1649.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1650. else
  1651.   cat > conftest.$ac_ext <<EOF
  1652. #line 1653 "configure"
  1653. #include "confdefs.h"
  1654. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1655. /* Override any gcc2 internal prototype to avoid an error.  */
  1656. char getb67(); 
  1657.  
  1658. int main() { return 0; }
  1659. int t() {
  1660.  
  1661. /* The GNU C library defines this for functions which it implements
  1662.     to always fail with ENOSYS.  Some functions are actually named
  1663.     something starting with __ and the normal name is an alias.  */
  1664. #if defined (__stub_getb67) || defined (__stub___getb67)
  1665. choke me
  1666. #else
  1667. getb67();
  1668. #endif
  1669.  
  1670. ; return 0; }
  1671. EOF
  1672. if eval $ac_link; then
  1673.   rm -rf conftest*
  1674.   eval "ac_cv_func_getb67=yes"
  1675. else
  1676.   rm -rf conftest*
  1677.   eval "ac_cv_func_getb67=no"
  1678. fi
  1679. rm -f conftest*
  1680.  
  1681. fi
  1682. if eval "test \"`echo '$ac_cv_func_'getb67`\" = yes"; then
  1683.   /bin/echo "$ac_t""yes" 1>&4
  1684.   cat >> confdefs.h <<\EOF
  1685. #define CRAY_STACKSEG_END getb67
  1686. EOF
  1687.  
  1688. else
  1689.   /bin/echo "$ac_t""no" 1>&4
  1690. fi
  1691.  
  1692. fi
  1693.  
  1694. fi
  1695.  
  1696. fi
  1697.  
  1698. /bin/echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&4
  1699. if eval "test \"`echo '${'ac_cv_c_stack_direction'+set}'`\" = set"; then
  1700.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1701. else
  1702.   if test "$cross_compiling" = yes; then
  1703.   ac_cv_c_stack_direction=0
  1704. else
  1705. cat > conftest.$ac_ext <<EOF
  1706. #line 1707 "configure"
  1707. #include "confdefs.h"
  1708. find_stack_direction ()
  1709. {
  1710.   static char *addr = 0;
  1711.   auto char dummy;
  1712.   if (addr == 0)
  1713.     {
  1714.       addr = &dummy;
  1715.       return find_stack_direction ();
  1716.     }
  1717.   else
  1718.     return (&dummy > addr) ? 1 : -1;
  1719. }
  1720. main ()
  1721. {
  1722.   exit (find_stack_direction() < 0);
  1723. }
  1724. EOF
  1725. eval $ac_link
  1726. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1727.   ac_cv_c_stack_direction=1
  1728. else
  1729.   ac_cv_c_stack_direction=-1
  1730. fi
  1731. fi
  1732. rm -fr conftest*
  1733. fi
  1734. /bin/echo "$ac_t""$ac_cv_c_stack_direction" 1>&4
  1735. cat >> confdefs.h <<EOF
  1736. #define STACK_DIRECTION $ac_cv_c_stack_direction
  1737. EOF
  1738.  
  1739. fi
  1740.  
  1741. /bin/echo $ac_n "checking whether closedir returns void""... $ac_c" 1>&4
  1742. if eval "test \"`echo '${'ac_cv_func_closedir_void'+set}'`\" = set"; then
  1743.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1744. else
  1745.   if test "$cross_compiling" = yes; then
  1746.     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  1747. else
  1748. cat > conftest.$ac_ext <<EOF
  1749. #line 1750 "configure"
  1750. #include "confdefs.h"
  1751. #include <sys/types.h>
  1752. #include <$ac_header_dirent>
  1753. int closedir(); main() { exit(closedir(opendir(".")) != 0); }
  1754. EOF
  1755. eval $ac_link
  1756. if test -s conftest && (./conftest; exit) 2>/dev/null; then
  1757.   ac_cv_func_closedir_void=no
  1758. else
  1759.   ac_cv_func_closedir_void=yes
  1760. fi
  1761. fi
  1762. rm -fr conftest*
  1763. fi
  1764. /bin/echo "$ac_t""$ac_cv_func_closedir_void" 1>&4
  1765. if test $ac_cv_func_closedir_void = yes; then
  1766.   cat >> confdefs.h <<\EOF
  1767. #define CLOSEDIR_VOID 1
  1768. EOF
  1769.  
  1770. fi
  1771.  
  1772. # strftime is in -lintl on SCO UNIX.
  1773. /bin/echo $ac_n "checking for -lintl""... $ac_c" 1>&4
  1774. if eval "test \"`echo '${'ac_cv_lib_intl'+set}'`\" = set"; then
  1775.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1776. else
  1777.   ac_save_LIBS="$LIBS"
  1778. LIBS="$LIBS -lintl "
  1779. cat > conftest.$ac_ext <<EOF
  1780. #line 1781 "configure"
  1781. #include "confdefs.h"
  1782.  
  1783. int main() { return 0; }
  1784. int t() {
  1785. strftime()
  1786. ; return 0; }
  1787. EOF
  1788. if eval $ac_link; then
  1789.   rm -rf conftest*
  1790.   eval "ac_cv_lib_intl=yes"
  1791. else
  1792.   rm -rf conftest*
  1793.   eval "ac_cv_lib_intl=no"
  1794. fi
  1795. rm -f conftest*
  1796. LIBS="$ac_save_LIBS"
  1797.  
  1798. fi
  1799. if eval "test \"`echo '$ac_cv_lib_'intl`\" = yes"; then
  1800.   /bin/echo "$ac_t""yes" 1>&4
  1801.   LIBS="$LIBS -lintl"
  1802. else
  1803.   /bin/echo "$ac_t""no" 1>&4
  1804. fi
  1805.  
  1806. /bin/echo $ac_n "checking for strftime""... $ac_c" 1>&4
  1807. if eval "test \"`echo '${'ac_cv_func_strftime'+set}'`\" = set"; then
  1808.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1809. else
  1810.   cat > conftest.$ac_ext <<EOF
  1811. #line 1812 "configure"
  1812. #include "confdefs.h"
  1813. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1814. /* Override any gcc2 internal prototype to avoid an error.  */
  1815. char strftime(); 
  1816.  
  1817. int main() { return 0; }
  1818. int t() {
  1819.  
  1820. /* The GNU C library defines this for functions which it implements
  1821.     to always fail with ENOSYS.  Some functions are actually named
  1822.     something starting with __ and the normal name is an alias.  */
  1823. #if defined (__stub_strftime) || defined (__stub___strftime)
  1824. choke me
  1825. #else
  1826. strftime();
  1827. #endif
  1828.  
  1829. ; return 0; }
  1830. EOF
  1831. if eval $ac_link; then
  1832.   rm -rf conftest*
  1833.   eval "ac_cv_func_strftime=yes"
  1834. else
  1835.   rm -rf conftest*
  1836.   eval "ac_cv_func_strftime=no"
  1837. fi
  1838. rm -f conftest*
  1839.  
  1840. fi
  1841. if eval "test \"`echo '$ac_cv_func_'strftime`\" = yes"; then
  1842.   /bin/echo "$ac_t""yes" 1>&4
  1843.   cat >> confdefs.h <<\EOF
  1844. #define HAVE_STRFTIME 1
  1845. EOF
  1846.  
  1847. else
  1848.   /bin/echo "$ac_t""no" 1>&4
  1849. fi
  1850.  
  1851. /bin/echo $ac_n "checking for vprintf""... $ac_c" 1>&4
  1852. if eval "test \"`echo '${'ac_cv_func_vprintf'+set}'`\" = set"; then
  1853.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1854. else
  1855.   cat > conftest.$ac_ext <<EOF
  1856. #line 1857 "configure"
  1857. #include "confdefs.h"
  1858. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1859. /* Override any gcc2 internal prototype to avoid an error.  */
  1860. char vprintf(); 
  1861.  
  1862. int main() { return 0; }
  1863. int t() {
  1864.  
  1865. /* The GNU C library defines this for functions which it implements
  1866.     to always fail with ENOSYS.  Some functions are actually named
  1867.     something starting with __ and the normal name is an alias.  */
  1868. #if defined (__stub_vprintf) || defined (__stub___vprintf)
  1869. choke me
  1870. #else
  1871. vprintf();
  1872. #endif
  1873.  
  1874. ; return 0; }
  1875. EOF
  1876. if eval $ac_link; then
  1877.   rm -rf conftest*
  1878.   eval "ac_cv_func_vprintf=yes"
  1879. else
  1880.   rm -rf conftest*
  1881.   eval "ac_cv_func_vprintf=no"
  1882. fi
  1883. rm -f conftest*
  1884.  
  1885. fi
  1886. if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
  1887.   /bin/echo "$ac_t""yes" 1>&4
  1888.   cat >> confdefs.h <<\EOF
  1889. #define HAVE_VPRINTF 1
  1890. EOF
  1891.  
  1892. else
  1893.   /bin/echo "$ac_t""no" 1>&4
  1894. fi
  1895.  
  1896. if test "$ac_cv_func_vprintf" != yes; then
  1897. /bin/echo $ac_n "checking for _doprnt""... $ac_c" 1>&4
  1898. if eval "test \"`echo '${'ac_cv_func__doprnt'+set}'`\" = set"; then
  1899.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1900. else
  1901.   cat > conftest.$ac_ext <<EOF
  1902. #line 1903 "configure"
  1903. #include "confdefs.h"
  1904. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1905. /* Override any gcc2 internal prototype to avoid an error.  */
  1906. char _doprnt(); 
  1907.  
  1908. int main() { return 0; }
  1909. int t() {
  1910.  
  1911. /* The GNU C library defines this for functions which it implements
  1912.     to always fail with ENOSYS.  Some functions are actually named
  1913.     something starting with __ and the normal name is an alias.  */
  1914. #if defined (__stub__doprnt) || defined (__stub____doprnt)
  1915. choke me
  1916. #else
  1917. _doprnt();
  1918. #endif
  1919.  
  1920. ; return 0; }
  1921. EOF
  1922. if eval $ac_link; then
  1923.   rm -rf conftest*
  1924.   eval "ac_cv_func__doprnt=yes"
  1925. else
  1926.   rm -rf conftest*
  1927.   eval "ac_cv_func__doprnt=no"
  1928. fi
  1929. rm -f conftest*
  1930.  
  1931. fi
  1932. if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
  1933.   /bin/echo "$ac_t""yes" 1>&4
  1934.   cat >> confdefs.h <<\EOF
  1935. #define HAVE_DOPRNT 1
  1936. EOF
  1937.  
  1938. else
  1939.   /bin/echo "$ac_t""no" 1>&4
  1940. fi
  1941.  
  1942. fi
  1943.  
  1944. for ac_func in memset mktime strftime
  1945. do
  1946. /bin/echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
  1947. if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
  1948.   /bin/echo $ac_n "(cached) $ac_c" 1>&4
  1949. else
  1950.   cat > conftest.$ac_ext <<EOF
  1951. #line 1952 "configure"
  1952. #include "confdefs.h"
  1953. #include <ctype.h> /* Arbitrary system header to define __stub macros. */
  1954. /* Override any gcc2 internal prototype to avoid an error.  */
  1955. char $ac_func(); 
  1956.  
  1957. int main() { return 0; }
  1958. int t() {
  1959.  
  1960. /* The GNU C library defines this for functions which it implements
  1961.     to always fail with ENOSYS.  Some functions are actually named
  1962.     something starting with __ and the normal name is an alias.  */
  1963. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  1964. choke me
  1965. #else
  1966. $ac_func();
  1967. #endif
  1968.  
  1969. ; return 0; }
  1970. EOF
  1971. if eval $ac_link; then
  1972.   rm -rf conftest*
  1973.   eval "ac_cv_func_$ac_func=yes"
  1974. else
  1975.   rm -rf conftest*
  1976.   eval "ac_cv_func_$ac_func=no"
  1977. fi
  1978. rm -f conftest*
  1979.  
  1980. fi
  1981. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  1982.   /bin/echo "$ac_t""yes" 1>&4
  1983.   :
  1984. else
  1985.   /bin/echo "$ac_t""no" 1>&4
  1986. LIBOBJS="$LIBOBJS ${ac_func}.o"
  1987. fi
  1988.  
  1989. done
  1990.  
  1991. test "$ac_cv_func_basename" = yes || LIBOBJS="$LIBOBJS basename.o"
  1992.  
  1993. /bin/echo $ac_n "checking for /etc/systemid""... $ac_c" 1>&4
  1994. if test -f /etc/systemid; then
  1995.   /bin/echo "$ac_t""yes" 1>&4
  1996.   cat >> confdefs.h <<\EOF
  1997. #define HAVE_ETC_SYSTEMID 1
  1998. EOF
  1999.  
  2000. else
  2001.   /bin/echo "$ac_t""no" 1>&4
  2002. fi
  2003.  
  2004. /bin/echo $ac_n "checking if uuencode and uudecode are wanted""... $ac_c" 1>&4
  2005. # Check whether --enable-uucode or --disable-uucode was given.
  2006. enableval="$enable_uucode"
  2007. if test -n "$enableval"; then
  2008.   if test "$enableval" = yes; then
  2009.   /bin/echo "$ac_t""yes" 1>&4
  2010.   PROGRAMS="$PROGRAMS uudecode uuencode"
  2011. else
  2012.   /bin/echo "$ac_t""no" 1>&4
  2013. fi
  2014. else
  2015.   
  2016.   /bin/echo "$ac_t""yes" 1>&4
  2017.   PROGRAMS="$PROGRAMS uudecode uuencode"
  2018.  
  2019. fi
  2020.  
  2021.  
  2022. /bin/echo $ac_n "checking if malloc debugging is wanted""... $ac_c" 1>&4
  2023. # Check whether --with-dmalloc or --without-dmalloc was given.
  2024. withval="$with_dmalloc"
  2025. if test -n "$withval"; then
  2026.   if test "$withval" = yes; then
  2027.   /bin/echo "$ac_t""yes" 1>&4
  2028.   cat >> confdefs.h <<\EOF
  2029. #define WITH_DMALLOC 1
  2030. EOF
  2031.  
  2032.   LIBS="$LIBS -ldmalloc"
  2033.   LDFLAGS="$LDFLAGS -g"
  2034. else
  2035.   /bin/echo "$ac_t""no" 1>&4
  2036. fi
  2037. else
  2038.   /bin/echo "$ac_t""no" 1>&4
  2039. fi
  2040.  
  2041.  
  2042. trap '' 1 2 15
  2043. if test -w $cache_file; then
  2044. echo "updating cache $cache_file"
  2045. cat > $cache_file <<\EOF
  2046. # This file is a shell script that caches the results of configure
  2047. # tests run on this system so they can be shared between configure
  2048. # scripts and configure runs.  It is not useful on other systems.
  2049. # If it contains results you don't want to keep, you may remove or edit it.
  2050. #
  2051. # By default, configure uses ./config.cache as the cache file,
  2052. # creating it if it does not exist already.  You can give configure
  2053. # the --cache-file=FILE option to use a different cache file; that is
  2054. # what configure does when it calls configure scripts in
  2055. # subdirectories, so they share the cache.
  2056. # Giving --cache-file=/dev/null disables caching, for debugging configure.
  2057. # config.status only pays attention to the cache file if you give it the
  2058. # --recheck option to rerun configure.
  2059. #
  2060. EOF
  2061. # Ultrix sh set writes to stderr and can't be redirected directly.
  2062. (set) 2>&1 |
  2063.   sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/: \${\1='\2'}/p" \
  2064.   >> $cache_file
  2065. else
  2066. echo "not updating unwritable cache $cache_file"
  2067. fi
  2068.  
  2069. trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
  2070.  
  2071. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  2072. # Let make expand exec_prefix.
  2073. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  2074.  
  2075. # Any assignment to VPATH causes Sun make to only execute
  2076. # the first set of double-colon rules, so remove it if not needed.
  2077. # If there is a colon in the path, we need to keep it.
  2078. if test "x$srcdir" = x.; then
  2079.   ac_vpsub='/^[     ]*VPATH[     ]*=[^:]*$/d'
  2080. fi
  2081.  
  2082. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  2083.  
  2084. DEFS=-DHAVE_CONFIG_H
  2085.  
  2086. # Without the "./", some shells look in PATH for config.status.
  2087. : ${CONFIG_STATUS=./config.status}
  2088.  
  2089. echo creating $CONFIG_STATUS
  2090. # Some systems, like AmigaDOS, won't allow you to remove a script that is
  2091. # being executed, so just move it out of the way instead.
  2092. if test -f $CONFIG_STATUS; then mv $CONFIG_STATUS $CONFIG_STATUS.old; else true; fi
  2093. cat > $CONFIG_STATUS <<EOF
  2094. #!/bin/sh
  2095. # Generated automatically by configure.
  2096. # Run this file to recreate the current configuration.
  2097. # This directory was configured as follows,
  2098. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  2099. #
  2100. # $0 $ac_configure_args
  2101. #
  2102. # Compiler output produced by configure, useful for debugging
  2103. # configure, is in ./config.log if it exists.
  2104.  
  2105. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  2106. for ac_option
  2107. do
  2108.   case "\$ac_option" in
  2109.   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  2110.     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  2111.     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  2112.   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  2113.     /bin/echo "$CONFIG_STATUS generated by autoconf version 2.1"
  2114.     exit 0 ;;
  2115.   -help | --help | --hel | --he | --h)
  2116.     echo "\$ac_cs_usage"; exit 0 ;;
  2117.   *) echo "\$ac_cs_usage"; exit 1 ;;
  2118.   esac
  2119. done
  2120.  
  2121. ac_given_srcdir=$srcdir
  2122. ac_given_INSTALL="$INSTALL"
  2123.  
  2124. trap 'rm -fr Makefile config.h conftest*; exit 1' 1 2 15
  2125.  
  2126. # Protect against being on the right side of a sed subst in config.status. 
  2127. sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g; 
  2128.  s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
  2129. $ac_vpsub
  2130. $extrasub
  2131. s%@CFLAGS@%$CFLAGS%g
  2132. s%@CPPFLAGS@%$CPPFLAGS%g
  2133. s%@CXXFLAGS@%$CXXFLAGS%g
  2134. s%@DEFS@%$DEFS%g
  2135. s%@LDFLAGS@%$LDFLAGS%g
  2136. s%@LIBS@%$LIBS%g
  2137. s%@exec_prefix@%$exec_prefix%g
  2138. s%@prefix@%$prefix%g
  2139. s%@program_transform_name@%$program_transform_name%g
  2140. s%@PRODUCT@%$PRODUCT%g
  2141. s%@VERSION@%$VERSION%g
  2142. s%@PROGRAMS@%$PROGRAMS%g
  2143. s%@CC@%$CC%g
  2144. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  2145. s%@INSTALL_DATA@%$INSTALL_DATA%g
  2146. s%@RANLIB@%$RANLIB%g
  2147. s%@CPP@%$CPP%g
  2148. s%@U@%$U%g
  2149. s%@ANSI2KNR@%$ANSI2KNR%g
  2150. s%@ALLOCA@%$ALLOCA%g
  2151. s%@LIBOBJS@%$LIBOBJS%g
  2152.  
  2153. CEOF
  2154. EOF
  2155. cat >> $CONFIG_STATUS <<EOF
  2156.  
  2157. CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
  2158. EOF
  2159. cat >> $CONFIG_STATUS <<\EOF
  2160. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  2161.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  2162.   case "$ac_file" in
  2163.   *:*) ac_file_in=`/bin/echo "$ac_file"|sed 's%.*:%%'`
  2164.        ac_file=`/bin/echo "$ac_file"|sed 's%:.*%%'` ;;
  2165.   *) ac_file_in="${ac_file}.in" ;;
  2166.   esac
  2167.  
  2168.   # Adjust relative srcdir, etc. for subdirectories.
  2169.  
  2170.   # Remove last slash and all that follows it.  Not all systems have dirname.
  2171.   ac_dir=`/bin/echo $ac_file|sed 's%/[^/][^/]*$%%'`
  2172.   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  2173.     # The file is in a subdirectory.
  2174.     test ! -d "$ac_dir" && mkdir "$ac_dir"
  2175.     ac_dir_suffix="/$ac_dir"
  2176.     # A "../" for each directory in $ac_dir_suffix.
  2177.     ac_dots=`/bin/echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  2178.   else
  2179.     ac_dir_suffix= ac_dots=
  2180.   fi
  2181.  
  2182.   case "$ac_given_srcdir" in
  2183.   .)  srcdir=.
  2184.       if test -z "$ac_dots"; then top_srcdir=.
  2185.       else top_srcdir=`/bin/echo $ac_dots|sed 's%/$%%'`; fi ;;
  2186.   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  2187.   *) # Relative path.
  2188.     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  2189.     top_srcdir="$ac_dots$ac_given_srcdir" ;;
  2190.   esac
  2191.  
  2192.   case "$ac_given_INSTALL" in
  2193.   [/$]*) INSTALL="$ac_given_INSTALL" ;;
  2194.   *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  2195.   esac
  2196.   echo creating "$ac_file"
  2197.   rm -f "$ac_file"
  2198.   configure_input="Generated automatically from `/bin/echo $ac_file_in|sed 's%.*/%%'` by configure."
  2199.   case "$ac_file" in
  2200.   *Makefile*) ac_comsub="1i\\
  2201. # $configure_input" ;;
  2202.   *) ac_comsub= ;;
  2203.   esac
  2204.   sed -e "$ac_comsub
  2205. s%@configure_input@%$configure_input%g
  2206. s%@srcdir@%$srcdir%g
  2207. s%@top_srcdir@%$top_srcdir%g
  2208. s%@INSTALL@%$INSTALL%g
  2209. " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
  2210. fi; done
  2211. rm -f conftest.subs
  2212.  
  2213. # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
  2214. # NAME is the cpp macro being defined and VALUE is the value it is being given.
  2215. #
  2216. # ac_d sets the value in "#define NAME VALUE" lines.
  2217. ac_dA='s%^\([     ]*\)#\([     ]*define[     ][     ]*\)'
  2218. ac_dB='\([     ][     ]*\)[^     ]*%\1#\2'
  2219. ac_dC='\3'
  2220. ac_dD='%g'
  2221. # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  2222. ac_uA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  2223. ac_uB='\([     ]\)%\1#\2define\3'
  2224. ac_uC=' '
  2225. ac_uD='\4%g'
  2226. # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  2227. ac_eA='s%^\([     ]*\)#\([     ]*\)undef\([     ][     ]*\)'
  2228. ac_eB='$%\1#\2define\3'
  2229. ac_eC=' '
  2230. ac_eD='%g'
  2231.  
  2232. CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"}
  2233. for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
  2234.   # Support "outfile[:infile]", defaulting infile="outfile.in".
  2235.   case "$ac_file" in
  2236.   *:*) ac_file_in=`/bin/echo "$ac_file"|sed 's%.*:%%'`
  2237.        ac_file=`/bin/echo "$ac_file"|sed 's%:.*%%'` ;;
  2238.   *) ac_file_in="${ac_file}.in" ;;
  2239.   esac
  2240.  
  2241.   echo creating $ac_file
  2242.  
  2243.   rm -f conftest.frag conftest.in conftest.out
  2244.   cp $ac_given_srcdir/$ac_file_in conftest.in
  2245.  
  2246. EOF
  2247.  
  2248. # Transform confdefs.h into a sed script conftest.vals that substitutes
  2249. # the proper values into config.h.in to produce config.h.  And first:
  2250. # Protect against being on the right side of a sed subst in config.status. 
  2251. # Protect against being in an unquoted here document in config.status.
  2252. rm -f conftest.vals
  2253. cat > conftest.hdr <<\EOF
  2254. s/[\\&%]/\\&/g
  2255. s%[\\$`]%\\&%g
  2256. s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
  2257. s%ac_d%ac_u%gp
  2258. s%ac_u%ac_e%gp
  2259. EOF
  2260. sed -n -f conftest.hdr confdefs.h > conftest.vals
  2261. rm -f conftest.hdr
  2262.  
  2263. # This sed command replaces #undef with comments.  This is necessary, for
  2264. # example, in the case of _POSIX_SOURCE, which is predefined and required
  2265. # on some systems where configure will not decide to define it.
  2266. cat >> conftest.vals <<\EOF
  2267. s%^[     ]*#[     ]*undef[     ][     ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
  2268. EOF
  2269.  
  2270. # Break up conftest.vals because some shells have a limit on
  2271. # the size of here documents, and old seds have small limits too.
  2272. # Maximum number of lines to put in a single here document.
  2273. ac_max_here_lines=12
  2274.  
  2275. rm -f conftest.tail
  2276. while :
  2277. do
  2278.   ac_lines=`grep -c . conftest.vals`
  2279.   # grep -c gives empty output for an empty file on some AIX systems.
  2280.   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  2281.   # Write a limited-size here document to conftest.frag.
  2282.   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  2283.   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
  2284.   echo 'CEOF
  2285.   sed -f conftest.frag conftest.in > conftest.out
  2286.   rm -f conftest.in
  2287.   mv conftest.out conftest.in
  2288. ' >> $CONFIG_STATUS
  2289.   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  2290.   rm -f conftest.vals
  2291.   mv conftest.tail conftest.vals
  2292. done
  2293. rm -f conftest.vals
  2294.  
  2295. cat >> $CONFIG_STATUS <<\EOF
  2296.   rm -f conftest.frag conftest.h
  2297.   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  2298.   cat conftest.in >> conftest.h
  2299.   rm -f conftest.in
  2300.   if cmp -s $ac_file conftest.h 2>/dev/null; then
  2301.     /bin/echo "$ac_file is unchanged"
  2302.     rm -f conftest.h
  2303.   else
  2304.     rm -f $ac_file
  2305.     mv conftest.h $ac_file
  2306.   fi
  2307. fi; done
  2308.  
  2309.  
  2310. test -z "$CONFIG_HEADERS" || date > stamp-h
  2311. exit 0
  2312. EOF
  2313. chmod +x $CONFIG_STATUS
  2314. rm -fr confdefs* $ac_clean_files
  2315. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS
  2316.  
  2317.