#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by Autoconf 2.52.
#
# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
# Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.

# Avoid depending upon Character Ranges.
as_cr_letters='abcdefghijklmnopqrstuvwxyz'
as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits

# Sed expression to map a string onto a valid variable name.
as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"

# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"

# Be Bourne compatible
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
  set -o posix
fi

# Name of the executable.
as_me=`echo "$0" |sed 's,.*[\\/],,'`

if expr a : '\(a\)' >/dev/null 2>&1; then
  as_expr=expr
else
  as_expr=false
fi

rm -f conf$$ conf$$.exe conf$$.file
echo >conf$$.file
if ln -s conf$$.file conf$$ 2>/dev/null; then
  # We could just check for DJGPP; but this test a) works b) is more generic
  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
  if test -f conf$$.exe; then
    # Don't use ln at all; we don't have any links
    as_ln_s='cp -p'
  else
    as_ln_s='ln -s'
  fi
elif ln conf$$.file conf$$ 2>/dev/null; then
  as_ln_s=ln
else
  as_ln_s='cp -p'
fi
rm -f conf$$ conf$$.exe conf$$.file

as_executable_p="test -f"

# Support unset when possible.
if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
  as_unset=unset
else
  as_unset=false
fi

# NLS nuisances.
$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }

# IFS
# We need space, tab and new line, in precisely that order.
as_nl='
'
IFS=" 	$as_nl"

# CDPATH.
$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }

# Name of the host.
# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`

exec 6>&1

#
# Initializations.
#
ac_default_prefix=/usr/local
cross_compiling=no
subdirs=
MFLAGS= MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}

# Maximum number of lines to put in a shell here document.
# This variable seems obsolete.  It should probably be removed, and
# only ac_max_sed_lines should be used.
: ${ac_max_here_lines=38}

ac_unique_file="lispbibl.d"
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
#if HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
#if HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
#if STDC_HEADERS
# include <stdlib.h>
# include <stddef.h>
#else
# if HAVE_STDLIB_H
#  include <stdlib.h>
# endif
#endif
#if HAVE_STRING_H
# if !STDC_HEADERS && HAVE_MEMORY_H
#  include <memory.h>
# endif
# include <string.h>
#endif
#if HAVE_STRINGS_H
# include <strings.h>
#endif
#if HAVE_INTTYPES_H
# include <inttypes.h>
#else
# if HAVE_STDINT_H
#  include <stdint.h>
# endif
#endif
#if HAVE_UNISTD_H
# include <unistd.h>
#endif"

# Initialize some variables set by options.
ac_init_help=
ac_init_version=false
# The variables have the same names as the options, with
# dashes changed to underlines.
cache_file=/dev/null
exec_prefix=NONE
no_create=
no_recursion=
prefix=NONE
program_prefix=NONE
program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
srcdir=
verbose=
x_includes=NONE
x_libraries=NONE

# Installation directory options.
# These are left unexpanded so users can "make install exec_prefix=/foo"
# and all the variables that are supposed to be based on exec_prefix
# by default will actually change.
# Use braces instead of parens because sh, perl, etc. also accept them.
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datadir='${prefix}/share'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'

# Identity of this package.
PACKAGE_NAME=
PACKAGE_TARNAME=
PACKAGE_VERSION=
PACKAGE_STRING=
PACKAGE_BUGREPORT=

ac_prev=
for ac_option
do
  # If the previous option needs an argument, assign it.
  if test -n "$ac_prev"; then
    eval "$ac_prev=\$ac_option"
    ac_prev=
    continue
  fi

  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`

  # Accept the important Cygnus configure options, so we can diagnose typos.

  case $ac_option in

  -bindir | --bindir | --bindi | --bind | --bin | --bi)
    ac_prev=bindir ;;
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
    bindir=$ac_optarg ;;

  -build | --build | --buil | --bui | --bu)
    ac_prev=build_alias ;;
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
    build_alias=$ac_optarg ;;

  -cache-file | --cache-file | --cache-fil | --cache-fi \
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
    ac_prev=cache_file ;;
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
    cache_file=$ac_optarg ;;

  --config-cache | -C)
    cache_file=config.cache ;;

  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
    ac_prev=datadir ;;
  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  | --da=*)
    datadir=$ac_optarg ;;

  -disable-* | --disable-*)
    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
   { (exit 1); exit 1; }; }
    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
    eval "enable_$ac_feature=no" ;;

  -enable-* | --enable-*)
    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
   { (exit 1); exit 1; }; }
    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
    case $ac_option in
      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
      *) ac_optarg=yes ;;
    esac
    eval "enable_$ac_feature='$ac_optarg'" ;;

  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  | --exec | --exe | --ex)
    ac_prev=exec_prefix ;;
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  | --exec=* | --exe=* | --ex=*)
    exec_prefix=$ac_optarg ;;

  -gas | --gas | --ga | --g)
    # Obsolete; use --with-gas.
    with_gas=yes ;;

  -help | --help | --hel | --he | -h)
    ac_init_help=long ;;
  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
    ac_init_help=recursive ;;
  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
    ac_init_help=short ;;

  -host | --host | --hos | --ho)
    ac_prev=host_alias ;;
  -host=* | --host=* | --hos=* | --ho=*)
    host_alias=$ac_optarg ;;

  -includedir | --includedir | --includedi | --included | --include \
  | --includ | --inclu | --incl | --inc)
    ac_prev=includedir ;;
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  | --includ=* | --inclu=* | --incl=* | --inc=*)
    includedir=$ac_optarg ;;

  -infodir | --infodir | --infodi | --infod | --info | --inf)
    ac_prev=infodir ;;
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
    infodir=$ac_optarg ;;

  -libdir | --libdir | --libdi | --libd)
    ac_prev=libdir ;;
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
    libdir=$ac_optarg ;;

  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  | --libexe | --libex | --libe)
    ac_prev=libexecdir ;;
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  | --libexe=* | --libex=* | --libe=*)
    libexecdir=$ac_optarg ;;

  -localstatedir | --localstatedir | --localstatedi | --localstated \
  | --localstate | --localstat | --localsta | --localst \
  | --locals | --local | --loca | --loc | --lo)
    ac_prev=localstatedir ;;
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
    localstatedir=$ac_optarg ;;

  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
    ac_prev=mandir ;;
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
    mandir=$ac_optarg ;;

  -nfp | --nfp | --nf)
    # Obsolete; use --without-fp.
    with_fp=no ;;

  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c)
    no_create=yes ;;

  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
    no_recursion=yes ;;

  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  | --oldin | --oldi | --old | --ol | --o)
    ac_prev=oldincludedir ;;
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
    oldincludedir=$ac_optarg ;;

  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
    ac_prev=prefix ;;
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
    prefix=$ac_optarg ;;

  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  | --program-pre | --program-pr | --program-p)
    ac_prev=program_prefix ;;
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
    program_prefix=$ac_optarg ;;

  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  | --program-suf | --program-su | --program-s)
    ac_prev=program_suffix ;;
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
    program_suffix=$ac_optarg ;;

  -program-transform-name | --program-transform-name \
  | --program-transform-nam | --program-transform-na \
  | --program-transform-n | --program-transform- \
  | --program-transform | --program-transfor \
  | --program-transfo | --program-transf \
  | --program-trans | --program-tran \
  | --progr-tra | --program-tr | --program-t)
    ac_prev=program_transform_name ;;
  -program-transform-name=* | --program-transform-name=* \
  | --program-transform-nam=* | --program-transform-na=* \
  | --program-transform-n=* | --program-transform-=* \
  | --program-transform=* | --program-transfor=* \
  | --program-transfo=* | --program-transf=* \
  | --program-trans=* | --program-tran=* \
  | --progr-tra=* | --program-tr=* | --program-t=*)
    program_transform_name=$ac_optarg ;;

  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil)
    silent=yes ;;

  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
    ac_prev=sbindir ;;
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  | --sbi=* | --sb=*)
    sbindir=$ac_optarg ;;

  -sharedstatedir | --sharedstatedir | --sharedstatedi \
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  | --sharedst | --shareds | --shared | --share | --shar \
  | --sha | --sh)
    ac_prev=sharedstatedir ;;
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  | --sha=* | --sh=*)
    sharedstatedir=$ac_optarg ;;

  -site | --site | --sit)
    ac_prev=site ;;
  -site=* | --site=* | --sit=*)
    site=$ac_optarg ;;

  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
    ac_prev=srcdir ;;
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
    srcdir=$ac_optarg ;;

  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  | --syscon | --sysco | --sysc | --sys | --sy)
    ac_prev=sysconfdir ;;
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
    sysconfdir=$ac_optarg ;;

  -target | --target | --targe | --targ | --tar | --ta | --t)
    ac_prev=target_alias ;;
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
    target_alias=$ac_optarg ;;

  -v | -verbose | --verbose | --verbos | --verbo | --verb)
    verbose=yes ;;

  -version | --version | --versio | --versi | --vers | -V)
    ac_init_version=: ;;

  -with-* | --with-*)
    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
      { echo "$as_me: error: invalid package name: $ac_package" >&2
   { (exit 1); exit 1; }; }
    ac_package=`echo $ac_package| sed 's/-/_/g'`
    case $ac_option in
      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
      *) ac_optarg=yes ;;
    esac
    eval "with_$ac_package='$ac_optarg'" ;;

  -without-* | --without-*)
    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
      { echo "$as_me: error: invalid package name: $ac_package" >&2
   { (exit 1); exit 1; }; }
    ac_package=`echo $ac_package | sed 's/-/_/g'`
    eval "with_$ac_package=no" ;;

  --x)
    # Obsolete; use --with-x.
    with_x=yes ;;

  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  | --x-incl | --x-inc | --x-in | --x-i)
    ac_prev=x_includes ;;
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
    x_includes=$ac_optarg ;;

  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
    ac_prev=x_libraries ;;
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
    x_libraries=$ac_optarg ;;

  -*) { echo "$as_me: error: unrecognized option: $ac_option
Try \`$0 --help' for more information." >&2
   { (exit 1); exit 1; }; }
    ;;

  *=*)
    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
    # Reject names that are not valid shell variable names.
    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
   { (exit 1); exit 1; }; }
    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
    eval "$ac_envvar='$ac_optarg'"
    export $ac_envvar ;;

  *)
    # FIXME: should be removed in autoconf 3.0.
    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
    ;;

  esac
done

if test -n "$ac_prev"; then
  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
  { echo "$as_me: error: missing argument to $ac_option" >&2
   { (exit 1); exit 1; }; }
fi

# Be sure to have absolute paths.
for ac_var in exec_prefix prefix
do
  eval ac_val=$`echo $ac_var`
  case $ac_val in
    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
   { (exit 1); exit 1; }; };;
  esac
done

# Be sure to have absolute paths.
for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
              localstatedir libdir includedir oldincludedir infodir mandir
do
  eval ac_val=$`echo $ac_var`
  case $ac_val in
    [\\/$]* | ?:[\\/]* ) ;;
    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
   { (exit 1); exit 1; }; };;
  esac
done

# There might be people who depend on the old broken behavior: `$host'
# used to hold the argument of --host etc.
build=$build_alias
host=$host_alias
target=$target_alias

# FIXME: should be removed in autoconf 3.0.
if test "x$host_alias" != x; then
  if test "x$build_alias" = x; then
    cross_compiling=maybe
    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used." >&2
  elif test "x$build_alias" != "x$host_alias"; then
    cross_compiling=yes
  fi
fi

ac_tool_prefix=
test -n "$host_alias" && ac_tool_prefix=$host_alias-

test "$silent" = yes && exec 6>/dev/null

# Find the source files, if location was not specified.
if test -z "$srcdir"; then
  ac_srcdir_defaulted=yes
  # Try the directory containing this script, then its parent.
  ac_prog=$0
  ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  srcdir=$ac_confdir
  if test ! -r $srcdir/$ac_unique_file; then
    srcdir=..
  fi
else
  ac_srcdir_defaulted=no
fi
if test ! -r $srcdir/$ac_unique_file; then
  if test "$ac_srcdir_defaulted" = yes; then
    { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
   { (exit 1); exit 1; }; }
  else
    { echo "$as_me: error: cannot find sources in $srcdir" >&2
   { (exit 1); exit 1; }; }
  fi
fi
srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
ac_env_build_alias_set=${build_alias+set}
ac_env_build_alias_value=$build_alias
ac_cv_env_build_alias_set=${build_alias+set}
ac_cv_env_build_alias_value=$build_alias
ac_env_host_alias_set=${host_alias+set}
ac_env_host_alias_value=$host_alias
ac_cv_env_host_alias_set=${host_alias+set}
ac_cv_env_host_alias_value=$host_alias
ac_env_target_alias_set=${target_alias+set}
ac_env_target_alias_value=$target_alias
ac_cv_env_target_alias_set=${target_alias+set}
ac_cv_env_target_alias_value=$target_alias
ac_env_CC_set=${CC+set}
ac_env_CC_value=$CC
ac_cv_env_CC_set=${CC+set}
ac_cv_env_CC_value=$CC
ac_env_CFLAGS_set=${CFLAGS+set}
ac_env_CFLAGS_value=$CFLAGS
ac_cv_env_CFLAGS_set=${CFLAGS+set}
ac_cv_env_CFLAGS_value=$CFLAGS
ac_env_LDFLAGS_set=${LDFLAGS+set}
ac_env_LDFLAGS_value=$LDFLAGS
ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
ac_cv_env_LDFLAGS_value=$LDFLAGS
ac_env_CPPFLAGS_set=${CPPFLAGS+set}
ac_env_CPPFLAGS_value=$CPPFLAGS
ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
ac_cv_env_CPPFLAGS_value=$CPPFLAGS
ac_env_CPP_set=${CPP+set}
ac_env_CPP_value=$CPP
ac_cv_env_CPP_set=${CPP+set}
ac_cv_env_CPP_value=$CPP

#
# Report the --help message.
#
if test "$ac_init_help" = "long"; then
  # Omit some internal or obsolete options to make the list less imposing.
  # This message is too long to be a string in the A/UX 3.1 sh.
  cat <<EOF
\`configure' configures this package to adapt to many kinds of systems.

Usage: $0 [OPTION]... [VAR=VALUE]...

To assign environment variables (e.g., CC, CFLAGS...), specify them as
VAR=VALUE.  See below for descriptions of some of the useful variables.

Defaults for the options are specified in brackets.

Configuration:
  -h, --help              display this help and exit
      --help=short        display options specific to this package
      --help=recursive    display the short help of all the included packages
  -V, --version           display version information and exit
  -q, --quiet, --silent   do not print \`checking...' messages
      --cache-file=FILE   cache test results in FILE [disabled]
  -C, --config-cache      alias for \`--cache-file=config.cache'
  -n, --no-create         do not create output files
      --srcdir=DIR        find the sources in DIR [configure dir or \`..']

EOF

  cat <<EOF
Installation directories:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [$ac_default_prefix]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [PREFIX]

By default, \`make install' will install all the files in
\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
an installation prefix other than \`$ac_default_prefix' using \`--prefix',
for instance \`--prefix=\$HOME'.

For better control, use the options below.

Fine tuning of the installation directories:
  --bindir=DIR           user executables [EPREFIX/bin]
  --sbindir=DIR          system admin executables [EPREFIX/sbin]
  --libexecdir=DIR       program executables [EPREFIX/libexec]
  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
  --libdir=DIR           object code libraries [EPREFIX/lib]
  --includedir=DIR       C header files [PREFIX/include]
  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
  --infodir=DIR          info documentation [PREFIX/info]
  --mandir=DIR           man documentation [PREFIX/man]
EOF

  cat <<\EOF

X features:
  --x-includes=DIR    X include files are in DIR
  --x-libraries=DIR   X library files are in DIR

System types:
  --build=BUILD     configure for building on BUILD [guessed]
  --host=HOST       build programs to run on HOST [BUILD]
EOF
fi

if test -n "$ac_init_help"; then

  cat <<\EOF

Optional Packages:
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --with-x                use the X Window System

Some influential environment variables:
  CC          C compiler command
  CFLAGS      C compiler flags
  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
              nonstandard directory <lib dir>
  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
              headers in a nonstandard directory <include dir>
  CPP         C preprocessor

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.

EOF
fi

if test "$ac_init_help" = "recursive"; then
  # If there are subdirs, report their specific --help.
  ac_popdir=`pwd`
  for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
    cd $ac_subdir
    # A "../" for each directory in /$ac_subdir.
    ac_dots=`echo $ac_subdir |
             sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`

    case $srcdir in
    .) # No --srcdir option.  We are building in place.
      ac_sub_srcdir=$srcdir ;;
    [\\/]* | ?:[\\/]* ) # Absolute path.
      ac_sub_srcdir=$srcdir/$ac_subdir ;;
    *) # Relative path.
      ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
    esac

    # Check for guested configure; otherwise get Cygnus style configure.
    if test -f $ac_sub_srcdir/configure.gnu; then
      echo
      $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
    elif test -f $ac_sub_srcdir/configure; then
      echo
      $SHELL $ac_sub_srcdir/configure  --help=recursive
    elif test -f $ac_sub_srcdir/configure.ac ||
           test -f $ac_sub_srcdir/configure.in; then
      echo
      $ac_configure --help
    else
      echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
    fi
    cd $ac_popdir
  done
fi

test -n "$ac_init_help" && exit 0
if $ac_init_version; then
  cat <<\EOF

Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
EOF
  exit 0
fi
exec 5>config.log
cat >&5 <<EOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by $as_me, which was
generated by GNU Autoconf 2.52.  Invocation command line was

  $ $0 $@

EOF
{
cat <<_ASUNAME
## ---------- ##
## Platform.  ##
## ---------- ##

hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
uname -m = `(uname -m) 2>/dev/null || echo unknown`
uname -r = `(uname -r) 2>/dev/null || echo unknown`
uname -s = `(uname -s) 2>/dev/null || echo unknown`
uname -v = `(uname -v) 2>/dev/null || echo unknown`

/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`

/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`

PATH = $PATH

_ASUNAME
} >&5

cat >&5 <<EOF
## ------------ ##
## Core tests.  ##
## ------------ ##

EOF

# Keep a trace of the command line.
# Strip out --no-create and --no-recursion so they do not pile up.
# Also quote any args containing shell meta-characters.
ac_configure_args=
ac_sep=
for ac_arg
do
  case $ac_arg in
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c) ;;
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
    ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
    ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
    ac_sep=" " ;;
  *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
     ac_sep=" " ;;
  esac
  # Get rid of the leading space.
done

# When interrupted or exit'd, cleanup temporary files, and complete
# config.log.  We remove comments because anyway the quotes in there
# would cause problems or look ugly.
trap 'exit_status=$?
  # Save into config.log some information that might help in debugging.
  echo >&5
  echo "## ----------------- ##" >&5
  echo "## Cache variables.  ##" >&5
  echo "## ----------------- ##" >&5
  echo >&5
  # The following way of writing the cache mishandles newlines in values,
{
  (set) 2>&1 |
    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
    *ac_space=\ *)
      sed -n \
        "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
      ;;
    *)
      sed -n \
        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
      ;;
    esac;
} >&5
  sed "/^$/d" confdefs.h >conftest.log
  if test -s conftest.log; then
    echo >&5
    echo "## ------------ ##" >&5
    echo "## confdefs.h.  ##" >&5
    echo "## ------------ ##" >&5
    echo >&5
    cat conftest.log >&5
  fi
  (echo; echo) >&5
  test "$ac_signal" != 0 &&
    echo "$as_me: caught signal $ac_signal" >&5
  echo "$as_me: exit $exit_status" >&5
  rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
    exit $exit_status
     ' 0
for ac_signal in 1 2 13 15; do
  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
done
ac_signal=0

# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -rf conftest* confdefs.h
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
echo >confdefs.h

# Let the site file select an alternate cache file if it wants to.
# Prefer explicitly selected file to automatically selected ones.
if test -z "$CONFIG_SITE"; then
  if test "x$prefix" != xNONE; then
    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  else
    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  fi
fi
for ac_site_file in $CONFIG_SITE; do
  if test -r "$ac_site_file"; then
    { echo "$as_me:868: loading site script $ac_site_file" >&5
echo "$as_me: loading site script $ac_site_file" >&6;}
    cat "$ac_site_file" >&5
    . "$ac_site_file"
  fi
done

if test -r "$cache_file"; then
  # Some versions of bash will fail to source /dev/null (special
  # files actually), so we avoid doing that.
  if test -f "$cache_file"; then
    { echo "$as_me:879: loading cache $cache_file" >&5
echo "$as_me: loading cache $cache_file" >&6;}
    case $cache_file in
      [\\/]* | ?:[\\/]* ) . $cache_file;;
      *)                      . ./$cache_file;;
    esac
  fi
else
  { echo "$as_me:887: creating cache $cache_file" >&5
echo "$as_me: creating cache $cache_file" >&6;}
  >$cache_file
fi

# Check that the precious variables saved in the cache have kept the same
# value.
ac_cache_corrupted=false
for ac_var in `(set) 2>&1 |
               sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
  eval ac_old_set=\$ac_cv_env_${ac_var}_set
  eval ac_new_set=\$ac_env_${ac_var}_set
  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
  eval ac_new_val="\$ac_env_${ac_var}_value"
  case $ac_old_set,$ac_new_set in
    set,)
      { echo "$as_me:903: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
      ac_cache_corrupted=: ;;
    ,set)
      { echo "$as_me:907: error: \`$ac_var' was not set in the previous run" >&5
echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
      ac_cache_corrupted=: ;;
    ,);;
    *)
      if test "x$ac_old_val" != "x$ac_new_val"; then
        { echo "$as_me:913: error: \`$ac_var' has changed since the previous run:" >&5
echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
        { echo "$as_me:915:   former value:  $ac_old_val" >&5
echo "$as_me:   former value:  $ac_old_val" >&2;}
        { echo "$as_me:917:   current value: $ac_new_val" >&5
echo "$as_me:   current value: $ac_new_val" >&2;}
        ac_cache_corrupted=:
      fi;;
  esac
  # Pass precious variables to config.status.  It doesn't matter if
  # we pass some twice (in addition to the command line arguments).
  if test "$ac_new_set" = set; then
    case $ac_new_val in
    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
      ac_configure_args="$ac_configure_args '$ac_arg'"
      ;;
    *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
       ;;
    esac
  fi
done
if $ac_cache_corrupted; then
  { echo "$as_me:936: error: changes in the environment can compromise the build" >&5
echo "$as_me: error: changes in the environment can compromise the build" >&2;}
  { { echo "$as_me:938: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
   { (exit 1); exit 1; }; }
fi

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
  *c*,-n*) ECHO_N= ECHO_C='
' ECHO_T='	' ;;
  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
  *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
esac
echo "#! $SHELL" >conftest.sh
echo  "exit 0"   >>conftest.sh
chmod +x conftest.sh
if { (echo "$as_me:958: PATH=\".;.\"; conftest.sh") >&5
  (PATH=".;."; conftest.sh) 2>&5
  ac_status=$?
  echo "$as_me:961: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  ac_path_separator=';'
else
  ac_path_separator=:
fi
PATH_SEPARATOR="$ac_path_separator"
rm -f conftest.sh

ac_config_headers="$ac_config_headers unixconf.h"

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
echo "$as_me:980: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="${ac_tool_prefix}gcc"
echo "$as_me:995: found $ac_dir/$ac_word" >&5
break
done

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  echo "$as_me:1003: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
  echo "$as_me:1006: result: no" >&5
echo "${ECHO_T}no" >&6
fi

fi
if test -z "$ac_cv_prog_CC"; then
  ac_ct_CC=$CC
  # Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo "$as_me:1015: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$ac_ct_CC"; then
  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="gcc"
echo "$as_me:1030: found $ac_dir/$ac_word" >&5
break
done

fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
  echo "$as_me:1038: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
  echo "$as_me:1041: result: no" >&5
echo "${ECHO_T}no" >&6
fi

  CC=$ac_ct_CC
else
  CC="$ac_cv_prog_CC"
fi

if test -z "$CC"; then
  if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
echo "$as_me:1054: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="${ac_tool_prefix}cc"
echo "$as_me:1069: found $ac_dir/$ac_word" >&5
break
done

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  echo "$as_me:1077: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
  echo "$as_me:1080: result: no" >&5
echo "${ECHO_T}no" >&6
fi

fi
if test -z "$ac_cv_prog_CC"; then
  ac_ct_CC=$CC
  # Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo "$as_me:1089: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$ac_ct_CC"; then
  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="cc"
echo "$as_me:1104: found $ac_dir/$ac_word" >&5
break
done

fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
  echo "$as_me:1112: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
  echo "$as_me:1115: result: no" >&5
echo "${ECHO_T}no" >&6
fi

  CC=$ac_ct_CC
else
  CC="$ac_cv_prog_CC"
fi

fi
if test -z "$CC"; then
  # Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo "$as_me:1128: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
  ac_prog_rejected=no
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
  ac_prog_rejected=yes
  continue
fi
ac_cv_prog_CC="cc"
echo "$as_me:1148: found $ac_dir/$ac_word" >&5
break
done

if test $ac_prog_rejected = yes; then
  # We found a bogon in the path, so make sure we never use it.
  set dummy $ac_cv_prog_CC
  shift
  if test $# != 0; then
    # We chose a different compiler from the bogus one.
    # However, it has the same basename, so the bogon will be chosen
    # first if we set CC to just the basename; use the full file name.
    shift
    set dummy "$ac_dir/$ac_word" ${1+"$@"}
    shift
    ac_cv_prog_CC="$@"
  fi
fi
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  echo "$as_me:1170: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
  echo "$as_me:1173: result: no" >&5
echo "${ECHO_T}no" >&6
fi

fi
if test -z "$CC"; then
  if test -n "$ac_tool_prefix"; then
  for ac_prog in cl
  do
    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
echo "$as_me:1184: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
echo "$as_me:1199: found $ac_dir/$ac_word" >&5
break
done

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  echo "$as_me:1207: result: $CC" >&5
echo "${ECHO_T}$CC" >&6
else
  echo "$as_me:1210: result: no" >&5
echo "${ECHO_T}no" >&6
fi

    test -n "$CC" && break
  done
fi
if test -z "$CC"; then
  ac_ct_CC=$CC
  for ac_prog in cl
do
  # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo "$as_me:1223: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$ac_ct_CC"; then
  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_ac_ct_CC="$ac_prog"
echo "$as_me:1238: found $ac_dir/$ac_word" >&5
break
done

fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
  echo "$as_me:1246: result: $ac_ct_CC" >&5
echo "${ECHO_T}$ac_ct_CC" >&6
else
  echo "$as_me:1249: result: no" >&5
echo "${ECHO_T}no" >&6
fi

  test -n "$ac_ct_CC" && break
done

  CC=$ac_ct_CC
fi

fi

test -z "$CC" && { { echo "$as_me:1261: error: no acceptable cc found in \$PATH" >&5
echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
   { (exit 1); exit 1; }; }

# Provide some information about the compiler.
echo "$as_me:1266:" \
     "checking for C compiler version" >&5
ac_compiler=`set X $ac_compile; echo $2`
{ (eval echo "$as_me:1269: \"$ac_compiler --version </dev/null >&5\"") >&5
  (eval $ac_compiler --version </dev/null >&5) 2>&5
  ac_status=$?
  echo "$as_me:1272: \$? = $ac_status" >&5
  (exit $ac_status); }
{ (eval echo "$as_me:1274: \"$ac_compiler -v </dev/null >&5\"") >&5
  (eval $ac_compiler -v </dev/null >&5) 2>&5
  ac_status=$?
  echo "$as_me:1277: \$? = $ac_status" >&5
  (exit $ac_status); }
{ (eval echo "$as_me:1279: \"$ac_compiler -V </dev/null >&5\"") >&5
  (eval $ac_compiler -V </dev/null >&5) 2>&5
  ac_status=$?
  echo "$as_me:1282: \$? = $ac_status" >&5
  (exit $ac_status); }

cat >conftest.$ac_ext <<_ACEOF
#line 1286 "configure"
#include "confdefs.h"

int
main ()
{

  ;
  return 0;
}
_ACEOF
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files a.out a.exe"
# Try to create an executable without -o first, disregard a.out.
# It will help us diagnose broken compilers, and finding out an intuition
# of exeext.
echo "$as_me:1302: checking for C compiler default output" >&5
echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
if { (eval echo "$as_me:1305: \"$ac_link_default\"") >&5
  (eval $ac_link_default) 2>&5
  ac_status=$?
  echo "$as_me:1308: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  # Find the output, starting from the most likely.  This scheme is
# not robust to junk in `.', hence go to wildcards (a.*) only as a last
# resort.
for ac_file in `ls a.exe conftest.exe 2>/dev/null;
                ls a.out conftest 2>/dev/null;
                ls a.* conftest.* 2>/dev/null`; do
  case $ac_file in
    *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
    a.out ) # We found the default executable, but exeext='' is most
            # certainly right.
            break;;
    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
          # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
          export ac_cv_exeext
          break;;
    * ) break;;
  esac
done
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
{ { echo "$as_me:1331: error: C compiler cannot create executables" >&5
echo "$as_me: error: C compiler cannot create executables" >&2;}
   { (exit 77); exit 77; }; }
fi

ac_exeext=$ac_cv_exeext
echo "$as_me:1337: result: $ac_file" >&5
echo "${ECHO_T}$ac_file" >&6

# Check the compiler produces executables we can run.  If not, either
# the compiler is broken, or we cross compile.
echo "$as_me:1342: checking whether the C compiler works" >&5
echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
# If not cross compiling, check that we can run a simple program.
if test "$cross_compiling" != yes; then
  if { ac_try='./$ac_file'
  { (eval echo "$as_me:1348: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1351: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
    cross_compiling=no
  else
    if test "$cross_compiling" = maybe; then
	cross_compiling=yes
    else
	{ { echo "$as_me:1358: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'." >&5
echo "$as_me: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'." >&2;}
   { (exit 1); exit 1; }; }
    fi
  fi
fi
echo "$as_me:1366: result: yes" >&5
echo "${ECHO_T}yes" >&6

rm -f a.out a.exe conftest$ac_cv_exeext
ac_clean_files=$ac_clean_files_save
# Check the compiler produces executables we can run.  If not, either
# the compiler is broken, or we cross compile.
echo "$as_me:1373: checking whether we are cross compiling" >&5
echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
echo "$as_me:1375: result: $cross_compiling" >&5
echo "${ECHO_T}$cross_compiling" >&6

echo "$as_me:1378: checking for executable suffix" >&5
echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
if { (eval echo "$as_me:1380: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:1383: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  # If both `conftest.exe' and `conftest' are `present' (well, observable)
# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
# work properly (i.e., refer to `conftest.exe'), while it won't with
# `rm'.
for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
  case $ac_file in
    *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
          export ac_cv_exeext
          break;;
    * ) break;;
  esac
done
else
  { { echo "$as_me:1399: error: cannot compute EXEEXT: cannot compile and link" >&5
echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
   { (exit 1); exit 1; }; }
fi

rm -f conftest$ac_cv_exeext
echo "$as_me:1405: result: $ac_cv_exeext" >&5
echo "${ECHO_T}$ac_cv_exeext" >&6

rm -f conftest.$ac_ext
EXEEXT=$ac_cv_exeext
ac_exeext=$EXEEXT
echo "$as_me:1411: checking for object suffix" >&5
echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
if test "${ac_cv_objext+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 1417 "configure"
#include "confdefs.h"

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.o conftest.obj
if { (eval echo "$as_me:1429: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1432: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
  case $ac_file in
    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
       break;;
  esac
done
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
{ { echo "$as_me:1444: error: cannot compute OBJEXT: cannot compile" >&5
echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
   { (exit 1); exit 1; }; }
fi

rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
echo "$as_me:1451: result: $ac_cv_objext" >&5
echo "${ECHO_T}$ac_cv_objext" >&6
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
echo "$as_me:1455: checking whether we are using the GNU C compiler" >&5
echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
if test "${ac_cv_c_compiler_gnu+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 1461 "configure"
#include "confdefs.h"

int
main ()
{
#ifndef __GNUC__
       choke me
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:1476: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1479: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:1482: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1485: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_compiler_gnu=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_compiler_gnu=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu

fi
echo "$as_me:1497: result: $ac_cv_c_compiler_gnu" >&5
echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
GCC=`test $ac_compiler_gnu = yes && echo yes`
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
CFLAGS="-g"
echo "$as_me:1503: checking whether $CC accepts -g" >&5
echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
if test "${ac_cv_prog_cc_g+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 1509 "configure"
#include "confdefs.h"

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:1521: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1524: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:1527: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1530: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_prog_cc_g=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_prog_cc_g=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:1540: result: $ac_cv_prog_cc_g" >&5
echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
if test "$ac_test_CFLAGS" = set; then
  CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
  if test "$GCC" = yes; then
    CFLAGS="-g -O2"
  else
    CFLAGS="-g"
  fi
else
  if test "$GCC" = yes; then
    CFLAGS="-O2"
  else
    CFLAGS=
  fi
fi
# Some people use a C++ compiler to compile C.  Since we use `exit',
# in C++ we need to declare it.  In case someone uses the same compiler
# for both compiling C and C++ we need to have the C++ compiler decide
# the declaration of exit, since it's the most demanding environment.
cat >conftest.$ac_ext <<_ACEOF
#ifndef __cplusplus
  choke me
#endif
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:1567: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1570: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:1573: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1576: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  for ac_declaration in \
   ''\
   '#include <stdlib.h>' \
   'extern "C" void std::exit (int) throw (); using std::exit;' \
   'extern "C" void std::exit (int); using std::exit;' \
   'extern "C" void exit (int) throw ();' \
   'extern "C" void exit (int);' \
   'void exit (int);'
do
  cat >conftest.$ac_ext <<_ACEOF
#line 1588 "configure"
#include "confdefs.h"
#include <stdlib.h>
$ac_declaration
int
main ()
{
exit (42);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:1601: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1604: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:1607: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1610: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  :
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
continue
fi
rm -f conftest.$ac_objext conftest.$ac_ext
  cat >conftest.$ac_ext <<_ACEOF
#line 1620 "configure"
#include "confdefs.h"
$ac_declaration
int
main ()
{
exit (42);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:1632: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:1635: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:1638: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:1641: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  break
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
done
rm -f conftest*
if test -n "$ac_declaration"; then
  echo '#ifdef __cplusplus' >>confdefs.h
  echo $ac_declaration      >>confdefs.h
  echo '#endif'             >>confdefs.h
fi

else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

                      ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
echo "$as_me:1673: checking how to run the C preprocessor" >&5
echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
  CPP=
fi
if test -z "$CPP"; then
  if test "${ac_cv_prog_CPP+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
      # Double quotes because CPP needs to be expanded
    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
    do
      ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
  # Use a header file that comes with gcc, so configuring glibc
  # with a fresh cross-compiler works.
  # On the NeXT, cc -E runs the code through the compiler's parser,
  # not just through cpp. "Syntax error" is here to catch this case.
  cat >conftest.$ac_ext <<_ACEOF
#line 1694 "configure"
#include "confdefs.h"
#include <assert.h>
                     Syntax error
_ACEOF
if { (eval echo "$as_me:1699: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:1705: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  :
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  # Broken: fails on valid input.
continue
fi
rm -f conftest.err conftest.$ac_ext

  # OK, works on sane cases.  Now check whether non-existent headers
  # can be detected and how.
  cat >conftest.$ac_ext <<_ACEOF
#line 1728 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
_ACEOF
if { (eval echo "$as_me:1732: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:1738: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  # Broken: success on invalid input.
continue
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  # Passes both tests.
ac_preproc_ok=:
break
fi
rm -f conftest.err conftest.$ac_ext

done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
  break
fi

    done
    ac_cv_prog_CPP=$CPP

fi
  CPP=$ac_cv_prog_CPP
else
  ac_cv_prog_CPP=$CPP
fi
echo "$as_me:1775: result: $CPP" >&5
echo "${ECHO_T}$CPP" >&6
ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
  # Use a header file that comes with gcc, so configuring glibc
  # with a fresh cross-compiler works.
  # On the NeXT, cc -E runs the code through the compiler's parser,
  # not just through cpp. "Syntax error" is here to catch this case.
  cat >conftest.$ac_ext <<_ACEOF
#line 1785 "configure"
#include "confdefs.h"
#include <assert.h>
                     Syntax error
_ACEOF
if { (eval echo "$as_me:1790: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:1796: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  :
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  # Broken: fails on valid input.
continue
fi
rm -f conftest.err conftest.$ac_ext

  # OK, works on sane cases.  Now check whether non-existent headers
  # can be detected and how.
  cat >conftest.$ac_ext <<_ACEOF
#line 1819 "configure"
#include "confdefs.h"
#include <ac_nonexistent.h>
_ACEOF
if { (eval echo "$as_me:1823: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:1829: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  # Broken: success on invalid input.
continue
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  # Passes both tests.
ac_preproc_ok=:
break
fi
rm -f conftest.err conftest.$ac_ext

done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
  :
else
  { { echo "$as_me:1857: error: C preprocessor \"$CPP\" fails sanity check" >&5
echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
   { (exit 1); exit 1; }; }
fi

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

echo "$as_me:1868: checking for AIX" >&5
echo $ECHO_N "checking for AIX... $ECHO_C" >&6
cat >conftest.$ac_ext <<_ACEOF
#line 1871 "configure"
#include "confdefs.h"
#ifdef _AIX
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  echo "$as_me:1880: result: yes" >&5
echo "${ECHO_T}yes" >&6
cat >>confdefs.h <<\EOF
#define _ALL_SOURCE 1
EOF

else
  echo "$as_me:1887: result: no" >&5
echo "${ECHO_T}no" >&6
fi
rm -f conftest*

echo "$as_me:1892: checking whether using GNU C" >&5
echo $ECHO_N "checking whether using GNU C... $ECHO_C" >&6
if test "${cl_cv_prog_cc_gcc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 1899 "configure"
#include "confdefs.h"
#ifdef __GNUC__
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_prog_cc_gcc=yes
else
  cl_cv_prog_cc_gcc=no
fi
rm -f conftest*

fi
echo "$as_me:1915: result: $cl_cv_prog_cc_gcc" >&5
echo "${ECHO_T}$cl_cv_prog_cc_gcc" >&6
if test $cl_cv_prog_cc_gcc = yes; then
  CC_GCC=true
  GCC_X_NONE='-x none'
else
  CC_GCC=false
  GCC_X_NONE=''
fi

echo "$as_me:1925: checking whether using C++" >&5
echo $ECHO_N "checking whether using C++... $ECHO_C" >&6
if test "${cl_cv_prog_cc_cplusplus+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 1932 "configure"
#include "confdefs.h"
#ifdef __cplusplus
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_prog_cc_cplusplus=yes
else
  cl_cv_prog_cc_cplusplus=no
fi
rm -f conftest*

fi
echo "$as_me:1948: result: $cl_cv_prog_cc_cplusplus" >&5
echo "${ECHO_T}$cl_cv_prog_cc_cplusplus" >&6
if test $cl_cv_prog_cc_cplusplus = yes; then
  CC_CPLUSPLUS=true
else
  CC_CPLUSPLUS=false
fi

echo "$as_me:1956: checking whether using ANSI C" >&5
echo $ECHO_N "checking whether using ANSI C... $ECHO_C" >&6
if test "${cl_cv_prog_cc_ansi+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 1963 "configure"
#include "confdefs.h"
#if defined(__STDC__) || defined(__cplusplus)
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_prog_cc_ansi=yes
else
  cl_cv_prog_cc_ansi=no
fi
rm -f conftest*

fi
echo "$as_me:1979: result: $cl_cv_prog_cc_ansi" >&5
echo "${ECHO_T}$cl_cv_prog_cc_ansi" >&6
if test $cl_cv_prog_cc_ansi = yes; then
  CC_ANSI=true
else
  CC_ANSI=false
fi

echo "$as_me:1987: checking whether CPP likes indented directives" >&5
echo $ECHO_N "checking whether CPP likes indented directives... $ECHO_C" >&6
if test "${cl_cv_prog_cc_indented+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 1994 "configure"
#include "confdefs.h"
 #define foo
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "#.*foo" >/dev/null 2>&1; then
  cl_cv_prog_cc_indented=no
else
  cl_cv_prog_cc_indented=yes
fi
rm -f conftest*

fi
echo "$as_me:2007: result: $cl_cv_prog_cc_indented" >&5
echo "${ECHO_T}$cl_cv_prog_cc_indented" >&6
if test $cl_cv_prog_cc_indented = yes; then
  CC_NEED_CCPAUX=false
else
  CC_NEED_CCPAUX=true
fi

echo "$as_me:2015: checking whether CPP likes empty macro arguments" >&5
echo $ECHO_N "checking whether CPP likes empty macro arguments... $ECHO_C" >&6
if test "${cl_cv_prog_cc_ema+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 2022 "configure"
#include "confdefs.h"
#define divide(x,y,q_zuw,r_zuw) (r_zuw(x)-(q_zuw(x)/(y))*(y))
foo(x,y) int x,y; { int q; divide(x,y,q=,); return q; }
_ACEOF
if { (eval echo "$as_me:2027: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:2033: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  cl_cv_prog_cc_ema=yes
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  cl_cv_prog_cc_ema=no
fi
rm -f conftest.err conftest.$ac_ext

fi
echo "$as_me:2053: result: $cl_cv_prog_cc_ema" >&5
echo "${ECHO_T}$cl_cv_prog_cc_ema" >&6
if test $cl_cv_prog_cc_ema = yes; then
  CC_NEED_DEEMA=false
else
  CC_NEED_DEEMA=true
fi

echo "$as_me:2061: checking for underscore in external names" >&5
echo $ECHO_N "checking for underscore in external names... $ECHO_C" >&6
if test "${cl_cv_prog_as_underscore+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat > conftest.c <<EOF
int foo() { return 0; }
EOF
# look for the assembly language name in the .s file
{ ac_try='${CC-cc} -S conftest.c'
  { (eval echo "$as_me:2072: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2075: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null 2>&1
if grep _foo conftest.s >/dev/null ; then
  cl_cv_prog_as_underscore=yes
else
  cl_cv_prog_as_underscore=no
fi
rm -f conftest*

fi
echo "$as_me:2085: result: $cl_cv_prog_as_underscore" >&5
echo "${ECHO_T}$cl_cv_prog_as_underscore" >&6
if test $cl_cv_prog_as_underscore = yes; then
  AS_UNDERSCORE=true
  cat >>confdefs.h <<\EOF
#define ASM_UNDERSCORE 1
EOF

else
  AS_UNDERSCORE=false
fi

                      # Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo "$as_me:2099: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_RANLIB+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_RANLIB="ranlib"
echo "$as_me:2114: found $ac_dir/$ac_word" >&5
break
done

  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB="true"
fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
  echo "$as_me:2123: result: $RANLIB" >&5
echo "${ECHO_T}$RANLIB" >&6
else
  echo "$as_me:2126: result: no" >&5
echo "${ECHO_T}no" >&6
fi

                      # Find a good install program.  We prefer a C program (faster),
# so one script is as good as another.  But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AFS /usr/afsws/bin/install, which mis-handles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo "$as_me:2140: checking for a BSD compatible install" >&5
echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
if test -z "$INSTALL"; then
if test "${cl_cv_path_install+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
    IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    # Account for people who put trailing slashes in PATH elements.
    case "$ac_dir/" in
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
    *)
      # OSF1 and SCO ODT 3.0 have their own names for install.
      for ac_prog in ginstall installbsd scoinst install; do
        if test -f $ac_dir/$ac_prog; then
	  if test $ac_prog = install &&
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
	    # AIX install.  It has an incompatible calling convention.
	    # OSF/1 installbsd also uses dspmsg, but is usable.
	    :
	  else
	    if test $ac_prog = installbsd &&
	      grep src/bos $ac_dir/$ac_prog >/dev/null 2>&1; then
	      # AIX installbsd doesn't work without option "-g".
	      :
	    else
	      cl_cv_path_install="$ac_dir/$ac_prog -c"
	      break 2
	    fi
	  fi
	fi
      done
      ;;
    esac
  done
  IFS="$ac_save_ifs"
  # As a last resort, use cp.
  test -z "$cl_cv_path_install" && cl_cv_path_install="cp"

fi
  INSTALL="$cl_cv_path_install"
fi
echo "$as_me:2182: result: $INSTALL" >&5
echo "${ECHO_T}$INSTALL" >&6
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='$(INSTALL)'
if test -z "$INSTALL_DATA"; then
  case "$INSTALL" in
    cp | */cp ) INSTALL_DATA='$(INSTALL)' ;;
    * )         INSTALL_DATA='$(INSTALL) -m 644' ;;
  esac
fi

                      echo "$as_me:2194: checking how to copy files" >&5
echo $ECHO_N "checking how to copy files... $ECHO_C" >&6
if test "${cl_cv_prog_cp+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

echo "blabla" > conftest.x
err=`/bin/sh -c "cp -p conftest.x conftest.y 2>&1"`
if test -z "$err"; then
  cl_cv_prog_cp='cp -p'
else
  cl_cv_prog_cp='cp'
fi
rm -f conftest*

fi
echo "$as_me:2210: result: $cl_cv_prog_cp" >&5
echo "${ECHO_T}$cl_cv_prog_cp" >&6
CP="$cl_cv_prog_cp"

                      echo "$as_me:2214: checking how to make hard links" >&5
echo $ECHO_N "checking how to make hard links... $ECHO_C" >&6
if test "${cl_cv_prog_LN+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

rm -f conftestdata conftestfile
echo data > conftestfile
if ln conftestfile conftestdata 2>/dev/null; then
  cl_cv_prog_LN=ln
else
  cl_cv_prog_LN="$cl_cv_prog_cp"
fi
rm -f conftestdata conftestfile

fi
echo "$as_me:2230: result: $cl_cv_prog_LN" >&5
echo "${ECHO_T}$cl_cv_prog_LN" >&6
LN="$cl_cv_prog_LN"

echo "$as_me:2234: checking whether ln -s works" >&5
echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
if test "${cl_cv_prog_LN_S+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

rm -f conftestdata
if ln -s X conftestdata 2>/dev/null; then
  cl_cv_prog_LN_S="ln -s"
else
  cl_cv_prog_LN_S="$cl_cv_prog_LN"
fi
rm -f conftestdata

fi
if test "$cl_cv_prog_LN_S" = "ln -s"; then
  echo "$as_me:2250: result: yes" >&5
echo "${ECHO_T}yes" >&6
else
  echo "$as_me:2253: result: no" >&5
echo "${ECHO_T}no" >&6
fi
LN_S="$cl_cv_prog_LN_S"

                      echo "$as_me:2258: checking how to make hard links to symlinks" >&5
echo $ECHO_N "checking how to make hard links to symlinks... $ECHO_C" >&6
if test "${cl_cv_prog_hln+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cl_cv_prog_hln="ln"
if test "$cl_cv_prog_LN_S" = "ln -s"; then
echo "blabla" > conftest.x
ln -s conftest.x conftest.y
ln conftest.y conftest.z 2>&5
rm -f conftest.x
if cat conftest.z > /dev/null 2>&1 ; then
  # ln is usable.
  cl_cv_prog_hln="ln"
else
  # conftest.z is a symbolic link to the non-existent conftest.x
  cl_cv_prog_hln="hln"
fi
else
# If there are no symbolic links, the problem cannot occur.
cl_cv_prog_hln="ln"
fi
rm -f conftest*

fi
echo "$as_me:2284: result: $cl_cv_prog_hln" >&5
echo "${ECHO_T}$cl_cv_prog_hln" >&6
HLN="$cl_cv_prog_hln"

                      # Extract the first word of "groff", so it can be a program name with args.
set dummy groff; ac_word=$2
echo "$as_me:2290: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_GROFF+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$GROFF"; then
  ac_cv_prog_GROFF="$GROFF" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_GROFF="groff"
echo "$as_me:2305: found $ac_dir/$ac_word" >&5
break
done

fi
fi
GROFF=$ac_cv_prog_GROFF
if test -n "$GROFF"; then
  echo "$as_me:2313: result: $GROFF" >&5
echo "${ECHO_T}$GROFF" >&6
else
  echo "$as_me:2316: result: no" >&5
echo "${ECHO_T}no" >&6
fi

                      echo "$as_me:2320: checking for getpwnam" >&5
echo $ECHO_N "checking for getpwnam... $ECHO_C" >&6
if test "${ac_cv_func_getpwnam+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 2326 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char getpwnam (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char getpwnam ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_getpwnam) || defined (__stub___getpwnam)
choke me
#else
f = getpwnam;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2357: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2360: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2363: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2366: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_getpwnam=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_getpwnam=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:2376: result: $ac_cv_func_getpwnam" >&5
echo "${ECHO_T}$ac_cv_func_getpwnam" >&6
if test $ac_cv_func_getpwnam = yes; then
  have_getpwnam=1
fi

if test -z "$have_getpwnam"; then

echo "$as_me:2384: checking for getpwnam in -lsun" >&5
echo $ECHO_N "checking for getpwnam in -lsun... $ECHO_C" >&6
if test "${ac_cv_lib_sun_getpwnam+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lsun  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 2392 "configure"
#include "confdefs.h"

/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char getpwnam ();
int
main ()
{
getpwnam ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2411: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2414: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2417: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2420: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_sun_getpwnam=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_sun_getpwnam=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:2431: result: $ac_cv_lib_sun_getpwnam" >&5
echo "${ECHO_T}$ac_cv_lib_sun_getpwnam" >&6
if test $ac_cv_lib_sun_getpwnam = yes; then
  cat >>confdefs.h <<EOF
#define HAVE_LIBSUN 1
EOF

  LIBS="-lsun $LIBS"

fi

fi

                      echo "$as_me:2444: checking for DYNIX/ptx libseq or libsocket" >&5
echo $ECHO_N "checking for DYNIX/ptx libseq or libsocket... $ECHO_C" >&6
if test "${cl_cv_lib_sequent+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 2451 "configure"
#include "confdefs.h"
#if defined(_SEQUENT_)
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_lib_sequent=yes
else
  cl_cv_lib_sequent=no
fi
rm -f conftest*

fi
echo "$as_me:2467: result: $cl_cv_lib_sequent" >&5
echo "${ECHO_T}$cl_cv_lib_sequent" >&6
if test $cl_cv_lib_sequent = yes; then
echo "$as_me:2470: checking for main in -lseq" >&5
echo $ECHO_N "checking for main in -lseq... $ECHO_C" >&6
if test "${ac_cv_lib_seq_main+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lseq  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 2478 "configure"
#include "confdefs.h"

int
main ()
{
main ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2490: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2493: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2496: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2499: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_seq_main=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_seq_main=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:2510: result: $ac_cv_lib_seq_main" >&5
echo "${ECHO_T}$ac_cv_lib_seq_main" >&6
if test $ac_cv_lib_seq_main = yes; then
  LIBS="$LIBS -lseq"
fi

echo "$as_me:2516: checking for main in -lsocket" >&5
echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
if test "${ac_cv_lib_socket_main+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lsocket  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 2524 "configure"
#include "confdefs.h"

int
main ()
{
main ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2536: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2539: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2542: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2545: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_socket_main=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_socket_main=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:2556: result: $ac_cv_lib_socket_main" >&5
echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
if test $ac_cv_lib_socket_main = yes; then
  LIBS="$LIBS -lsocket"
fi

fi

                      echo "$as_me:2564: checking whether gethostent requires -lnsl" >&5
echo $ECHO_N "checking whether gethostent requires -lnsl... $ECHO_C" >&6
if test "${cl_cv_lib_nsl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cl_cv_lib_nsl=no
cat >conftest.$ac_ext <<_ACEOF
#line 2572 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char gethostent();
int
main ()
{
gethostent();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2588: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2591: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2594: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2597: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_gethostent=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test -z "$have_gethostent"; then
cl_save_LIBS="$LIBS"
LIBS="$LIBS -lnsl"
cat >conftest.$ac_ext <<_ACEOF
#line 2609 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char gethostent();
int
main ()
{
gethostent();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2625: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2628: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2631: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2634: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_lib_nsl=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS="$cl_save_LIBS"
fi

fi
echo "$as_me:2646: result: $cl_cv_lib_nsl" >&5
echo "${ECHO_T}$cl_cv_lib_nsl" >&6
if test $cl_cv_lib_nsl = yes; then
  LIBS="$LIBS -lnsl"
fi
echo "$as_me:2651: checking whether setsockopt requires -lsocket" >&5
echo $ECHO_N "checking whether setsockopt requires -lsocket... $ECHO_C" >&6
if test "${cl_cv_lib_socket+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cl_cv_lib_socket=no
cat >conftest.$ac_ext <<_ACEOF
#line 2659 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char setsockopt();
int
main ()
{
setsockopt();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2675: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2678: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2681: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2684: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_setsockopt=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test -z "$have_setsockopt"; then
cl_save_LIBS="$LIBS"
LIBS="$LIBS -lsocket"
cat >conftest.$ac_ext <<_ACEOF
#line 2696 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char setsockopt();
int
main ()
{
setsockopt();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2712: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2715: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2718: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2721: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_lib_socket=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS="$cl_save_LIBS"
fi

fi
echo "$as_me:2733: result: $cl_cv_lib_socket" >&5
echo "${ECHO_T}$cl_cv_lib_socket" >&6
if test $cl_cv_lib_socket = yes; then
  LIBS="$LIBS -lsocket"
fi

                      echo "$as_me:2739: checking whether CC works at all" >&5
echo $ECHO_N "checking whether CC works at all... $ECHO_C" >&6
if test "${cl_cv_prog_cc_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

if test "$cross_compiling" = yes; then
  cat >conftest.$ac_ext <<_ACEOF
#line 2753 "configure"
#include "confdefs.h"

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:2765: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2768: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:2771: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2774: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_prog_cc_works=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_prog_cc_works=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
else
  cat >conftest.$ac_ext <<_ACEOF
#line 2785 "configure"
#include "confdefs.h"
int main() { exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:2790: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:2793: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:2795: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:2798: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_prog_cc_works=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_prog_cc_works=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu

fi
echo "$as_me:2816: result: $cl_cv_prog_cc_works" >&5
echo "${ECHO_T}$cl_cv_prog_cc_works" >&6
case "$cl_cv_prog_cc_works" in
  *no) echo "Installation or configuration problem: C compiler cannot create executables."; exit 1;;
  *yes) ;;
esac

                       ac_aux_dir=${srcdir}/autoconf
ac_config_guess="$SHELL $ac_aux_dir/config.guess"
ac_config_sub="$SHELL $ac_aux_dir/config.sub"
# Make sure we can run config.sub.
$ac_config_sub sun4 >/dev/null 2>&1 ||
  { { echo "$as_me:2828: error: cannot run $ac_config_sub" >&5
echo "$as_me: error: cannot run $ac_config_sub" >&2;}
   { (exit 1); exit 1; }; }

echo "$as_me:2832: checking build system type" >&5
echo $ECHO_N "checking build system type... $ECHO_C" >&6
if test "${ac_cv_build+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_cv_build_alias=$build_alias
test -z "$ac_cv_build_alias" &&
  ac_cv_build_alias=`$ac_config_guess`
test -z "$ac_cv_build_alias" &&
  { { echo "$as_me:2841: error: cannot guess build type; you must specify one" >&5
echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
   { (exit 1); exit 1; }; }
ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
  { { echo "$as_me:2845: error: $ac_config_sub $ac_cv_build_alias failed." >&5
echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
   { (exit 1); exit 1; }; }

fi
echo "$as_me:2850: result: $ac_cv_build" >&5
echo "${ECHO_T}$ac_cv_build" >&6
build=$ac_cv_build
build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`

echo "$as_me:2857: checking host system type" >&5
echo $ECHO_N "checking host system type... $ECHO_C" >&6
if test "${ac_cv_host+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_cv_host_alias=$host_alias
test -z "$ac_cv_host_alias" &&
  ac_cv_host_alias=$ac_cv_build_alias
ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
  { { echo "$as_me:2866: error: $ac_config_sub $ac_cv_host_alias failed" >&5
echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
   { (exit 1); exit 1; }; }

fi
echo "$as_me:2871: result: $ac_cv_host" >&5
echo "${ECHO_T}$ac_cv_host" >&6
host=$ac_cv_host
host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`

case "$host_cpu" in
  i[4567]86 )
    host_cpu=i386
    ;;
  alphaev[4-7] | alphaev56 | alphapca5[67] )
    host_cpu=alpha
    ;;
  hppa1.0 | hppa1.1 | hppa2.0 )
    host_cpu=hppa
    ;;
  powerpc )
    host_cpu=rs6000
    ;;
  c1 | c2 | c32 | c34 | c38 | c4 )
    host_cpu=convex
    ;;
  mips )
    echo "$as_me:2895: checking for 64-bit MIPS" >&5
echo $ECHO_N "checking for 64-bit MIPS... $ECHO_C" >&6
if test "${cl_cv_host_mips64+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 2902 "configure"
#include "confdefs.h"
#if defined(_MIPS_SZLONG)
#if (_MIPS_SZLONG == 64)
/* We should also check for (_MIPS_SZPTR == 64), but gcc keeps this at 32. */
  yes
#endif
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_host_mips64=yes
else
  cl_cv_host_mips64=no
fi
rm -f conftest*

fi
echo "$as_me:2921: result: $cl_cv_host_mips64" >&5
echo "${ECHO_T}$cl_cv_host_mips64" >&6
if test $cl_cv_host_mips64 = yes; then
  host_cpu=mips64
fi
    ;;
  sparc | sparc64 )
    echo "$as_me:2928: checking for 64-bit SPARC" >&5
echo $ECHO_N "checking for 64-bit SPARC... $ECHO_C" >&6
if test "${cl_cv_host_sparc64+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 2935 "configure"
#include "confdefs.h"
#if defined(__sparcv9) || defined(__arch64__)
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_host_sparc64=yes
else
  cl_cv_host_sparc64=no
fi
rm -f conftest*

fi
echo "$as_me:2951: result: $cl_cv_host_sparc64" >&5
echo "${ECHO_T}$cl_cv_host_sparc64" >&6
if test $cl_cv_host_sparc64 = yes; then
  host_cpu=sparc64
else
  host_cpu=sparc
fi
    ;;
esac
cat >> confdefs.h <<EOF
#ifndef __${host_cpu}__
#define __${host_cpu}__ 1
#endif
EOF

                      echo "$as_me:2966: checking for $CC option to accept ANSI C" >&5
echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
if test "${ac_cv_prog_cc_stdc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_cv_prog_cc_stdc=no
ac_save_CC=$CC
cat >conftest.$ac_ext <<_ACEOF
#line 2974 "configure"
#include "confdefs.h"
#include <stdarg.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
struct buf { int x; };
FILE * (*rcsopen) (struct buf *, struct stat *, int);
static char *e (p, i)
     char **p;
     int i;
{
  return p[i];
}
static char *f (char * (*g) (char **, int), char **p, ...)
{
  char *s;
  va_list v;
  va_start (v,p);
  s = g (p, va_arg (v,int));
  va_end (v);
  return s;
}
int test (int i, double x);
struct s1 {int (*f) (int a);};
struct s2 {int (*f) (double a);};
int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
int argc;
char **argv;
int
main ()
{
return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
  ;
  return 0;
}
_ACEOF
# Don't try gcc -ansi; that turns off useful extensions and
# breaks some systems' header files.
# AIX			-qlanglvl=ansi
# Ultrix and OSF/1	-std1
# HP-UX 10.20 and later	-Ae
# HP-UX older versions	-Aa -D_HPUX_SOURCE
# SVR4			-Xc -D__EXTENSIONS__
for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
  CC="$ac_save_CC $ac_arg"
  rm -f conftest.$ac_objext
if { (eval echo "$as_me:3023: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3026: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3029: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3032: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_prog_cc_stdc=$ac_arg
break
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext
done
rm -f conftest.$ac_ext conftest.$ac_objext
CC=$ac_save_CC

fi

case "x$ac_cv_prog_cc_stdc" in
  x|xno)
    echo "$as_me:3049: result: none needed" >&5
echo "${ECHO_T}none needed" >&6 ;;
  *)
    echo "$as_me:3052: result: $ac_cv_prog_cc_stdc" >&5
echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
    CC="$CC $ac_cv_prog_cc_stdc" ;;
esac

echo "$as_me:3057: checking for inline" >&5
echo $ECHO_N "checking for inline... $ECHO_C" >&6
if test "${ac_cv_c_inline+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
  cat >conftest.$ac_ext <<_ACEOF
#line 3065 "configure"
#include "confdefs.h"
#ifndef __cplusplus
static $ac_kw int static_foo () {return 0; }
$ac_kw int foo () {return 0; }
#endif

_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3074: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3077: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3080: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3083: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_c_inline=$ac_kw; break
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
done

fi
echo "$as_me:3094: result: $ac_cv_c_inline" >&5
echo "${ECHO_T}$ac_cv_c_inline" >&6
case $ac_cv_c_inline in
  inline | yes) ;;
  no)
cat >>confdefs.h <<\EOF
#define inline
EOF
 ;;
  *)  cat >>confdefs.h <<EOF
#define inline $ac_cv_c_inline
EOF
 ;;
esac

                      echo "$as_me:3109: checking for working void" >&5
echo $ECHO_N "checking for working void... $ECHO_C" >&6
if test "${cl_cv_c_void+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3116 "configure"
#include "confdefs.h"

int
main ()
{
void f();
typedef void x; x g();
typedef void* y; y a;

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3131: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3134: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3137: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3140: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_c_void=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_c_void=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3152: result: $cl_cv_c_void" >&5
echo "${ECHO_T}$cl_cv_c_void" >&6
if test $cl_cv_c_void = yes; then
  have_void=1
else
  cat >>confdefs.h <<\EOF
#define void char
EOF

fi
if test -n "$have_void"; then
echo "$as_me:3163: checking for working \"return void\"" >&5
echo $ECHO_N "checking for working \"return void\"... $ECHO_C" >&6
if test "${cl_cv_c_return_void+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3170 "configure"
#include "confdefs.h"
void f() {} typedef void x; x g() { return f(); }
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3182: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3185: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3188: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3191: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_c_return_void=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_c_return_void=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3203: result: $cl_cv_c_return_void" >&5
echo "${ECHO_T}$cl_cv_c_return_void" >&6
if test $cl_cv_c_return_void = yes; then
  cat >>confdefs.h <<\EOF
#define return_void return
EOF

else
  cat >>confdefs.h <<\EOF
#define return_void
EOF

fi
fi

                      echo "$as_me:3218: checking for long long type" >&5
echo $ECHO_N "checking for long long type... $ECHO_C" >&6
if test "${cl_cv_c_longlong+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_c_longlong="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3228 "configure"
#include "confdefs.h"
int main()
{
/* long longs don't work right with gcc-2.7.2 on m68k */
/* long longs don't work right with gcc-2.7.2 on rs6000: avcall/tests.c gets
   miscompiled. */
#ifdef __GNUC__
#if defined(__m68k__) || (defined(_IBMR2) || defined(__powerpc))
#if (__GNUC__ == 2)
#if (__GNUC_MINOR__ <= 7)
  exit(1);
#endif
#endif
#endif
#endif
  { long x = 944938507; long y = 737962842; long z = 162359677;
    exit(!(((long long) x)*((long long) y)>>32 == z));
  }
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:3250: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:3253: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:3255: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3258: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_c_longlong=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_c_longlong=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:3271: result: $cl_cv_c_longlong" >&5
echo "${ECHO_T}$cl_cv_c_longlong" >&6
case "$cl_cv_c_longlong" in
  *yes) cat >>confdefs.h <<\EOF
#define HAVE_LONGLONG 1
EOF
 ;;
  *no) ;;
esac

                      echo "$as_me:3281: checking for ANSI C header files" >&5
echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
if test "${cl_cv_header_stdc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3288 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>
#include <limits.h>
_ACEOF
if { (eval echo "$as_me:3296: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:3302: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  cl_cv_header_stdc=yes
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  cl_cv_header_stdc=no
fi
rm -f conftest.err conftest.$ac_ext

fi

echo "$as_me:3323: result: $cl_cv_header_stdc" >&5
echo "${ECHO_T}$cl_cv_header_stdc" >&6
if test $cl_cv_header_stdc = yes; then
  cat >>confdefs.h <<\EOF
#define STDC_HEADERS 1
EOF

fi

                      echo "$as_me:3332: checking for offsetof in stddef.h" >&5
echo $ECHO_N "checking for offsetof in stddef.h... $ECHO_C" >&6
if test "${cl_cv_offsetof+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3339 "configure"
#include "confdefs.h"
#include <stddef.h>
int
main ()
{
#ifndef offsetof
error no offsetof
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3354: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3357: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3360: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3363: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_offsetof=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_offsetof=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3375: result: $cl_cv_offsetof" >&5
echo "${ECHO_T}$cl_cv_offsetof" >&6
if test $cl_cv_offsetof = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_OFFSETOF 1
EOF

fi

                      echo "$as_me:3384: checking for stdbool.h" >&5
echo $ECHO_N "checking for stdbool.h... $ECHO_C" >&6
if test "${cl_cv_header_stdbool_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3391 "configure"
#include "confdefs.h"
#include <stdbool.h>
#if false
int A[-1];
#endif
#define b -1
#if true
#undef b
#define b 1
#endif
int B[b];

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3413: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3416: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3419: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3422: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_header_stdbool_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_header_stdbool_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3434: result: $cl_cv_header_stdbool_h" >&5
echo "${ECHO_T}$cl_cv_header_stdbool_h" >&6
if test $cl_cv_header_stdbool_h = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_STDBOOL_H 1
EOF

STDBOOL_H=''
else
  STDBOOL_H='stdbool.h'
fi

for ac_header in locale.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:3449: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3455 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:3459: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:3465: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:3484: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

for ac_header in unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:3497: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3503 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:3507: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:3513: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:3532: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

for ac_header in sys/file.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:3545: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3551 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:3555: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:3561: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:3580: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

if test $ac_cv_header_sys_file_h = yes; then
accessflags_decl='
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
'
accessflags_prog='int x = R_OK | W_OK | X_OK;'
echo "$as_me:3599: checking for R_OK in unistd.h" >&5
echo $ECHO_N "checking for R_OK in unistd.h... $ECHO_C" >&6
if test "${cl_cv_decl_R_OK_unistd_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3606 "configure"
#include "confdefs.h"
$accessflags_decl
int
main ()
{
$accessflags_prog
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3618: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3621: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3624: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3627: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_R_OK_unistd_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_R_OK_unistd_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3639: result: $cl_cv_decl_R_OK_unistd_h" >&5
echo "${ECHO_T}$cl_cv_decl_R_OK_unistd_h" >&6
if test $cl_cv_decl_R_OK_unistd_h = yes; then
  accessflags_ok=1
fi
if test -z "$accessflags_ok"; then
cat >>confdefs.h <<\EOF
#define ACCESS_NEEDS_SYS_FILE_H 1
EOF

fi
fi

for ac_header in sys/file.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:3655: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3661 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:3665: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:3671: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:3690: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

if test $ac_cv_header_sys_file_h = yes; then
openflags_decl='
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
#include <fcntl.h>
'
openflags_prog='int x = O_RDWR | O_RDONLY | O_WRONLY | O_CREAT | O_TRUNC;'
echo "$as_me:3710: checking for O_RDWR in fcntl.h" >&5
echo $ECHO_N "checking for O_RDWR in fcntl.h... $ECHO_C" >&6
if test "${cl_cv_decl_O_RDWR_fcntl_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3717 "configure"
#include "confdefs.h"
$openflags_decl
int
main ()
{
$openflags_prog
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3729: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3732: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3735: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3738: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_O_RDWR_fcntl_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_O_RDWR_fcntl_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3750: result: $cl_cv_decl_O_RDWR_fcntl_h" >&5
echo "${ECHO_T}$cl_cv_decl_O_RDWR_fcntl_h" >&6
if test $cl_cv_decl_O_RDWR_fcntl_h = yes; then
  openflags_ok=1
fi
if test -z "$openflags_ok"; then
cat >>confdefs.h <<\EOF
#define OPEN_NEEDS_SYS_FILE_H 1
EOF

fi
fi

                      ac_header_dirent=no
for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
  ac_safe=`echo "$ac_hdr" | sed 'y%./%__%'`
  echo "$as_me:3766: checking for $ac_hdr that defines DIR" >&5
echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
  if eval "test \"\${ac_cv_header_dirent_$ac_safe+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 3772 "configure"
#include "confdefs.h"
#include <sys/types.h>
     #include <$ac_hdr>
int
main ()
{
DIR *dirp = 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3785: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3788: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3791: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3794: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "ac_cv_header_dirent_$ac_safe=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "ac_cv_header_dirent_$ac_safe=no"
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
  if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
    echo "$as_me:3805: result: yes" >&5
echo "${ECHO_T}yes" >&6
    ac_header_dirent=$ac_hdr
    break
  else
    echo "$as_me:3810: result: no" >&5
echo "${ECHO_T}no" >&6
  fi
done
case "$ac_header_dirent" in
dirent.h) cat >>confdefs.h <<\EOF
#define DIRENT 1
EOF
 ;;
sys/ndir.h) cat >>confdefs.h <<\EOF
#define SYSNDIR 1
EOF
 ;;
sys/dir.h) cat >>confdefs.h <<\EOF
#define SYSDIR 1
EOF
 ;;
ndir.h) cat >>confdefs.h <<\EOF
#define NDIR 1
EOF
 ;;
esac
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo "$as_me:3834: checking for opendir in -ldir" >&5
echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
if test "${ac_cv_lib_dir_opendir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-ldir  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 3842 "configure"
#include "confdefs.h"

/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char opendir ();
int
main ()
{
opendir ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:3861: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:3864: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:3867: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3870: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_dir_opendir=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_dir_opendir=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:3881: result: $ac_cv_lib_dir_opendir" >&5
echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
if test $ac_cv_lib_dir_opendir = yes; then
  LIBS="$LIBS -ldir"
fi

else
echo "$as_me:3888: checking for opendir in -lx" >&5
echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
if test "${ac_cv_lib_x_opendir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lx  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 3896 "configure"
#include "confdefs.h"

/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char opendir ();
int
main ()
{
opendir ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:3915: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:3918: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:3921: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3924: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_x_opendir=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_x_opendir=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:3935: result: $ac_cv_lib_x_opendir" >&5
echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
if test $ac_cv_lib_x_opendir = yes; then
  LIBS="$LIBS -lx"
fi

fi

                      echo "$as_me:3943: checking for sys/utsname.h and struct utsname" >&5
echo $ECHO_N "checking for sys/utsname.h and struct utsname... $ECHO_C" >&6
if test "${cl_cv_struct_utsname+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 3950 "configure"
#include "confdefs.h"
#include <sys/utsname.h>
int
main ()
{
struct utsname u;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:3962: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:3965: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:3968: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:3971: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_utsname=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_utsname=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:3983: result: $cl_cv_struct_utsname" >&5
echo "${ECHO_T}$cl_cv_struct_utsname" >&6
if test $cl_cv_struct_utsname = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SYS_UTSNAME_H 1
EOF

fi

for ac_header in netdb.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:3995: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 4001 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:4005: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4011: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:4030: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

for ac_header in sys/shm.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:4043: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 4049 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:4053: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4059: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:4078: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

if test $ac_cv_header_sys_shm_h = yes; then

for ac_header in sys/ipc.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:4093: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 4099 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:4103: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4109: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:4128: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

fi

for ac_header in termios.h termio.h sys/termio.h sgtty.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:4143: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 4149 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:4153: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4159: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:4178: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_header_termios_h = yes; then
echo "$as_me:4188: checking for tcgetattr" >&5
echo $ECHO_N "checking for tcgetattr... $ECHO_C" >&6
if test "${cl_cv_func_tcgetattr+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4195 "configure"
#include "confdefs.h"
#include <termios.h>
int
main ()
{
struct termios t; tcgetattr(0,&t);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:4207: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:4210: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:4213: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4216: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_tcgetattr=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_tcgetattr=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:4228: result: $cl_cv_func_tcgetattr" >&5
echo "${ECHO_T}$cl_cv_func_tcgetattr" >&6
if test $cl_cv_func_tcgetattr = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_TCGETATTR 1
EOF

fi
if test $cl_cv_func_tcgetattr = yes; then
echo "$as_me:4237: checking for tcsetattr declaration" >&5
echo $ECHO_N "checking for tcsetattr declaration... $ECHO_C" >&6
if test "${cl_cv_proto_tcsetattr+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4244 "configure"
#include "confdefs.h"

#include <termios.h>
#ifndef tcsetattr
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int tcsetattr (int, int, struct termios *);
#else
int tcsetattr ();
#endif
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:4270: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:4273: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:4276: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4279: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_tcsetattr_arg3=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_tcsetattr_arg3="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_tcsetattr="extern int tcsetattr (int, int, $cl_cv_proto_tcsetattr_arg3 struct termios *);"
fi

cl_cv_proto_tcsetattr=`echo "$cl_cv_proto_tcsetattr" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:4293: result: ${ac_t:-
         }$cl_cv_proto_tcsetattr" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_tcsetattr" >&6

cat >>confdefs.h <<EOF
#define TCSETATTR_CONST $cl_cv_proto_tcsetattr_arg3
EOF

fi
echo "$as_me:4303: checking for TCSAFLUSH in termios.h" >&5
echo $ECHO_N "checking for TCSAFLUSH in termios.h... $ECHO_C" >&6
if test "${cl_cv_decl_TCSAFLUSH+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4310 "configure"
#include "confdefs.h"
#include <termios.h>
int
main ()
{
int x = TCSAFLUSH;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:4322: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:4325: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:4328: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4331: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_TCSAFLUSH=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_TCSAFLUSH=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:4343: result: $cl_cv_decl_TCSAFLUSH" >&5
echo "${ECHO_T}$cl_cv_decl_TCSAFLUSH" >&6
if test $cl_cv_decl_TCSAFLUSH = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_TCSAFLUSH 1
EOF

fi
echo "$as_me:4351: checking for struct winsize in termios.h" >&5
echo $ECHO_N "checking for struct winsize in termios.h... $ECHO_C" >&6
if test "${cl_cv_struct_winsize+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4358 "configure"
#include "confdefs.h"
#include <termios.h>
int
main ()
{
struct winsize w;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:4370: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:4373: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:4376: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4379: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_winsize=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_winsize=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:4391: result: $cl_cv_struct_winsize" >&5
echo "${ECHO_T}$cl_cv_struct_winsize" >&6
if test $cl_cv_struct_winsize = yes; then
  :
fi
if test $cl_cv_struct_winsize = no; then
echo "$as_me:4397: checking for struct winsize in sys/ioctl.h" >&5
echo $ECHO_N "checking for struct winsize in sys/ioctl.h... $ECHO_C" >&6
if test "${cl_cv_struct_winsize_ioctl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4404 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/ioctl.h>
int
main ()
{
struct winsize w;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:4417: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:4420: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:4423: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4426: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_winsize_ioctl=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_winsize_ioctl=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:4438: result: $cl_cv_struct_winsize_ioctl" >&5
echo "${ECHO_T}$cl_cv_struct_winsize_ioctl" >&6
if test $cl_cv_struct_winsize_ioctl = yes; then
  cat >>confdefs.h <<\EOF
#define WINSIZE_NEED_SYS_IOCTL_H 1
EOF

fi
if test $cl_cv_struct_winsize_ioctl = no; then
echo "$as_me:4447: checking for struct winsize in sys/ptem.h" >&5
echo $ECHO_N "checking for struct winsize in sys/ptem.h... $ECHO_C" >&6
if test "${cl_cv_struct_winsize_ptem+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4454 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/stream.h>
#include <sys/ptem.h>
int
main ()
{
struct winsize w;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:4468: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:4471: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:4474: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4477: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_winsize_ptem=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_winsize_ptem=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:4489: result: $cl_cv_struct_winsize_ptem" >&5
echo "${ECHO_T}$cl_cv_struct_winsize_ptem" >&6
if test $cl_cv_struct_winsize_ptem = yes; then
  cat >>confdefs.h <<\EOF
#define WINSIZE_NEED_SYS_PTEM_H 1
EOF

fi
fi
fi
fi

                      { echo "$as_me:4501: checking for X11..." >&5
echo "$as_me: checking for X11..." >&6;}
X_INCLUDES=''
X_LIBS=''
# Extract the first word of "xmkmf", so it can be a program name with args.
set dummy xmkmf; ac_word=$2
echo "$as_me:4507: checking for $ac_word" >&5
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
if test "${ac_cv_prog_HAVE_XMKMF+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test -n "$HAVE_XMKMF"; then
  ac_cv_prog_HAVE_XMKMF="$HAVE_XMKMF" # Let the user override the test.
else
  ac_save_IFS=$IFS; IFS=$ac_path_separator
ac_dummy="$PATH"
for ac_dir in $ac_dummy; do
  IFS=$ac_save_IFS
  test -z "$ac_dir" && ac_dir=.
  $as_executable_p "$ac_dir/$ac_word" || continue
ac_cv_prog_HAVE_XMKMF="yes"
echo "$as_me:4522: found $ac_dir/$ac_word" >&5
break
done

fi
fi
HAVE_XMKMF=$ac_cv_prog_HAVE_XMKMF
if test -n "$HAVE_XMKMF"; then
  echo "$as_me:4530: result: $HAVE_XMKMF" >&5
echo "${ECHO_T}$HAVE_XMKMF" >&6
else
  echo "$as_me:4533: result: no" >&5
echo "${ECHO_T}no" >&6
fi
if test "$HAVE_XMKMF" = yes; then
  have_x11=1
  cat >>confdefs.h <<\EOF
#define HAVE_X11 1
EOF

  X_LIBS='-lX11'
  echo "$as_me:4543: checking for X" >&5
echo $ECHO_N "checking for X... $ECHO_C" >&6

# Check whether --with-x or --without-x was given.
if test "${with_x+set}" = set; then
  withval="$with_x"

fi;
# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
if test "x$with_x" = xno; then
  # The user explicitly disabled X.
  have_x=disabled
else
  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
    # Both variables are already set.
    have_x=yes
  else
    if test "${ac_cv_have_x+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  # One or both of the vars are not set, and there is no cached value.
ac_x_includes=no ac_x_libraries=no
rm -fr conftest.dir
if mkdir conftest.dir; then
  cd conftest.dir
  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
  cat >Imakefile <<'EOF'
acfindx:
	@echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
EOF
  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
    for ac_extension in a so sl; do
      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
         test -f $ac_im_libdir/libX11.$ac_extension; then
        ac_im_usrlibdir=$ac_im_libdir; break
      fi
    done
    # Screen out bogus values from the imake configuration.  They are
    # bogus both because they are the default anyway, and because
    # using them would break gcc on systems where it needs fixed includes.
    case $ac_im_incroot in
	/usr/include) ;;
	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
    esac
    case $ac_im_usrlibdir in
	/usr/lib | /lib) ;;
	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
    esac
  fi
  cd ..
  rm -fr conftest.dir
fi

# Standard set of common directories for X headers.
# Check X11 before X11Rn because it is often a symlink to the current release.
ac_x_header_dirs='
/usr/X11/include
/usr/X11R6/include
/usr/X11R5/include
/usr/X11R4/include

/usr/include/X11
/usr/include/X11R6
/usr/include/X11R5
/usr/include/X11R4

/usr/local/X11/include
/usr/local/X11R6/include
/usr/local/X11R5/include
/usr/local/X11R4/include

/usr/local/include/X11
/usr/local/include/X11R6
/usr/local/include/X11R5
/usr/local/include/X11R4

/usr/X386/include
/usr/x386/include
/usr/XFree86/include/X11

/usr/include
/usr/local/include
/usr/unsupported/include
/usr/athena/include
/usr/local/x11r5/include
/usr/lpp/Xamples/include

/usr/openwin/include
/usr/openwin/share/include'

if test "$ac_x_includes" = no; then
  # Guess where to find include files, by looking for Intrinsic.h.
  # First, try using that file with no special directory specified.
  cat >conftest.$ac_ext <<_ACEOF
#line 4640 "configure"
#include "confdefs.h"
#include <X11/Intrinsic.h>
_ACEOF
if { (eval echo "$as_me:4644: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4650: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  # We can compile using X headers with no special include directory.
ac_x_includes=
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  for ac_dir in $ac_x_header_dirs; do
  if test -r "$ac_dir/X11/Intrinsic.h"; then
    ac_x_includes=$ac_dir
    break
  fi
done
fi
rm -f conftest.err conftest.$ac_ext
fi # $ac_x_includes = no

if test "$ac_x_libraries" = no; then
  # Check for the libraries.
  # See if we find them without any special options.
  # Don't add to $LIBS permanently.
  ac_save_LIBS=$LIBS
  LIBS="-lXt $LIBS"
  cat >conftest.$ac_ext <<_ACEOF
#line 4683 "configure"
#include "confdefs.h"
#include <X11/Intrinsic.h>
int
main ()
{
XtMalloc (0)
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:4695: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:4698: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:4701: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4704: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  LIBS=$ac_save_LIBS
# We can link X programs with no special library path.
ac_x_libraries=
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
LIBS=$ac_save_LIBS
for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
do
  # Don't even attempt the hair of trying to link an X program!
  for ac_extension in a so sl; do
    if test -r $ac_dir/libXt.$ac_extension; then
      ac_x_libraries=$ac_dir
      break 2
    fi
  done
done
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi # $ac_x_libraries = no

if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
  # Didn't find X anywhere.  Cache the known absence of X.
  ac_cv_have_x="have_x=no"
else
  # Record where we found X for the cache.
  ac_cv_have_x="have_x=yes \
	        ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
fi
fi

  fi
  eval "$ac_cv_have_x"
fi # $with_x != no

if test "$have_x" != yes; then
  echo "$as_me:4742: result: $have_x" >&5
echo "${ECHO_T}$have_x" >&6
  no_x=yes
else
  # If each of the values was on the command line, it overrides each guess.
  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
  # Update the cache value to reflect the command line values.
  ac_cv_have_x="have_x=yes \
		ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
  echo "$as_me:4752: result: libraries $x_libraries, headers $x_includes" >&5
echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
fi
  if test -n "$x_includes" -a "$x_includes" != NONE; then
    # Adding -I/usr/include may override gcc's private include hierarchy.
    if test "$x_includes" != "/usr/include"; then
      X_INCLUDES="-I$x_includes"
    fi
  fi
  if test -n "$x_libraries" -a "$x_libraries" != NONE; then
    X_LIBS="-L$x_libraries "$X_LIBS
  fi
else
      echo "$as_me:4765: checking for X11 header files" >&5
echo $ECHO_N "checking for X11 header files... $ECHO_C" >&6
  cat >conftest.$ac_ext <<_ACEOF
#line 4768 "configure"
#include "confdefs.h"
#include <X11/Intrinsic.h>
_ACEOF
if { (eval echo "$as_me:4772: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:4778: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  have_x_includes=1
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5

fi
rm -f conftest.err conftest.$ac_ext
  if test -z "$have_x_includes"; then
    for dir in /usr/X11/include /usr/openwin/include /usr/include/X11R5 /usr/X11R5/include /usr/include/X11R4 /usr/X386/include /usr/x386/include /usr/local/include /usr/unsupported/include; do
      if test -z "$have_x_includes"; then
        if test -r $dir/X11/Intrinsic.h; then
          x_includes="$dir"
          have_x_includes=1
        fi
      fi
    done
  fi
  if test -n "$x_includes" -a "$x_includes" != NONE; then
    X_INCLUDES="-I$x_includes"
  fi
  echo "$as_me:4809: result: $X_INCLUDES" >&5
echo "${ECHO_T}$X_INCLUDES" >&6
  echo "$as_me:4811: checking for X11 library" >&5
echo $ECHO_N "checking for X11 library... $ECHO_C" >&6

  :
if test "${ac_cv_lib_X11_main+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lX11  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 4821 "configure"
#include "confdefs.h"

int
main ()
{
main ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:4833: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:4836: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:4839: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4842: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_X11_main=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_X11_main=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:4853: result: $ac_cv_lib_X11_main" >&5
echo "${ECHO_T}$ac_cv_lib_X11_main" >&6
if test $ac_cv_lib_X11_main = yes; then
  have_x_libraries=1
fi
  if test -z "$have_x_libraries"; then
    for dir in /usr/X11/lib /usr/openwin/lib /usr/lib/X11R5 /usr/X11R5/lib /usr/lib/X11R4 /usr/X386/lib /usr/x386/lib /usr/local/lib /usr/unsupported/lib; do
      if test -z "$have_x_libraries"; then
        if test -r $dir/libX11.a; then
          x_libraries="$dir"
          have_x_libraries=1
        fi
      fi
    done
  fi
  if test -n "$have_x_libraries"; then
    X_LIBS='-lX11'
    if test -n "$x_libraries" -a "$x_libraries" != NONE; then
      X_LIBS="-L$x_libraries "$X_LIBS
    fi
  else
    :
if test "${ac_cv_lib_Xwindow_main+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lXwindow  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 4881 "configure"
#include "confdefs.h"

int
main ()
{
main ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:4893: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:4896: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:4899: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:4902: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_Xwindow_main=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_Xwindow_main=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:4913: result: $ac_cv_lib_Xwindow_main" >&5
echo "${ECHO_T}$ac_cv_lib_Xwindow_main" >&6
if test $ac_cv_lib_Xwindow_main = yes; then
  X_LIBS='-lXwindow' have_x_libraries=1
fi
  fi

  echo "$as_me:4920: result: $X_LIBS" >&5
echo "${ECHO_T}$X_LIBS" >&6
    if test -n "$have_x_includes" -a -n "$have_x_libraries"; then
    have_x11=1
    cat >>confdefs.h <<\EOF
#define HAVE_X11 1
EOF

  else
    X_INCLUDES=''
    X_LIBS=''
  fi
fi

                      echo "$as_me:4934: checking for caddr_t in sys/types.h" >&5
echo $ECHO_N "checking for caddr_t in sys/types.h... $ECHO_C" >&6
if test "${cl_cv_type_caddr_t+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4941 "configure"
#include "confdefs.h"
#include <sys/types.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "caddr_t" >/dev/null 2>&1; then
  cl_cv_type_caddr_t=yes
else
  cl_cv_type_caddr_t=no
fi
rm -f conftest*

fi
echo "$as_me:4955: result: $cl_cv_type_caddr_t" >&5
echo "${ECHO_T}$cl_cv_type_caddr_t" >&6
if test $cl_cv_type_caddr_t = yes; then
  cat >>confdefs.h <<\EOF
#define CADDR_T caddr_t
EOF

else
  cat >>confdefs.h <<\EOF
#define CADDR_T void*
EOF

fi

                      echo "$as_me:4969: checking for socklen_t in sys/socket.h" >&5
echo $ECHO_N "checking for socklen_t in sys/socket.h... $ECHO_C" >&6
if test "${cl_cv_type_socklen_t+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 4976 "configure"
#include "confdefs.h"
#include <sys/socket.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "socklen_t" >/dev/null 2>&1; then
  cl_cv_type_socklen_t=yes
else
  cl_cv_type_socklen_t=no
fi
rm -f conftest*

fi
echo "$as_me:4990: result: $cl_cv_type_socklen_t" >&5
echo "${ECHO_T}$cl_cv_type_socklen_t" >&6
if test $cl_cv_type_socklen_t = yes; then
  cat >>confdefs.h <<\EOF
#define SOCKLEN_T socklen_t
EOF

else
  cat >>confdefs.h <<\EOF
#define SOCKLEN_T int
EOF

fi

                      echo "$as_me:5004: checking for d_namlen in struct dirent" >&5
echo $ECHO_N "checking for d_namlen in struct dirent... $ECHO_C" >&6
if test "${cl_cv_struct_dirent_d_namlen+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5011 "configure"
#include "confdefs.h"
#include <dirent.h>
int
main ()
{
struct dirent d; d.d_namlen;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5023: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5026: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5029: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5032: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_dirent_d_namlen=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_dirent_d_namlen=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:5044: result: $cl_cv_struct_dirent_d_namlen" >&5
echo "${ECHO_T}$cl_cv_struct_dirent_d_namlen" >&6
if test $cl_cv_struct_dirent_d_namlen = yes; then
  :
else
  cat >>confdefs.h <<\EOF
#define DIRENT_WITHOUT_NAMLEN 1
EOF

fi

                      echo "$as_me:5055: checking for struct tm in sys/time.h" >&5
echo $ECHO_N "checking for struct tm in sys/time.h... $ECHO_C" >&6
if test "${cl_cv_struct_tm_sys_time_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5062 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
int
main ()
{
struct tm *tp; tp->tm_sec;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5075: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5078: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5081: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5084: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_tm_sys_time_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_tm_sys_time_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:5096: result: $cl_cv_struct_tm_sys_time_h" >&5
echo "${ECHO_T}$cl_cv_struct_tm_sys_time_h" >&6
if test $cl_cv_struct_tm_sys_time_h = yes; then
  cat >>confdefs.h <<\EOF
#define TM_IN_SYS_TIME 1
EOF

fi

# This is a bit tricky since strlen is a gcc2 built-in function, and
# gcc's criterion when to reject a prototype for it is extremely mysterious.
#   extern int strlen (char * s); extern unsigned int strlen (char * s);
# produces an error, while
#   extern unsigned int strlen (char * s); extern int strlen (char * s);
# compiles well.
if test -z "$cl_cv_proto_strlen_macro"; then
cat >conftest.$ac_ext <<_ACEOF
#line 5113 "configure"
#include "confdefs.h"
#include <string.h>
#ifdef strlen
is a macro
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "is a macro" >/dev/null 2>&1; then
  cl_cv_proto_strlen_macro=yes
else
  cl_cv_proto_strlen_macro=no
fi
rm -f conftest*

fi
if test $cl_cv_proto_strlen_macro = no; then
echo "$as_me:5131: checking for strlen declaration" >&5
echo $ECHO_N "checking for strlen declaration... $ECHO_C" >&6
if test "${cl_cv_proto_strlen+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5138 "configure"
#include "confdefs.h"
#define strlen foo
#include <string.h>

extern
#ifdef __cplusplus
"C"
#endif
size_t strlen();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5158: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5161: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5164: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5167: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_strlen_ret="size_t"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_strlen_ret="int"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cat >conftest.$ac_ext <<_ACEOF
#line 5178 "configure"
#include "confdefs.h"
#define strlen foo
#include <string.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$cl_cv_proto_strlen_ret strlen (char* s);
#else
$cl_cv_proto_strlen_ret strlen();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5203: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5206: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5209: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5212: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_strlen_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_strlen_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_strlen="extern $cl_cv_proto_strlen_ret strlen ($cl_cv_proto_strlen_arg1 char*);"
fi

cl_cv_proto_strlen=`echo "$cl_cv_proto_strlen" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:5226: result: ${ac_t:-
         }$cl_cv_proto_strlen" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_strlen" >&6

cat >>confdefs.h <<EOF
#define RETSTRLENTYPE $cl_cv_proto_strlen_ret
EOF

cat >>confdefs.h <<EOF
#define STRLEN_CONST $cl_cv_proto_strlen_arg1
EOF

fi

                      echo "$as_me:5241: checking for memset declaration" >&5
echo $ECHO_N "checking for memset declaration... $ECHO_C" >&6
if test "${cl_cv_proto_memset+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for y in 'int' 'size_t'; do
for x in 'char*' 'void*'; do
if test -z "$have_memset"; then
cat >conftest.$ac_ext <<_ACEOF
#line 5251 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <string.h>
#undef memset
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$x memset ($x s, int c, $y n);
#else
$x memset();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5280: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5283: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5286: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5289: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_memset_ret="$x"
cl_cv_proto_memset_arg1="$x"
cl_cv_proto_memset_arg3="$y"
have_memset=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done
done

cl_cv_proto_memset="extern $cl_cv_proto_memset_ret memset ($cl_cv_proto_memset_arg1, int, $cl_cv_proto_memset_arg3);"
fi

cl_cv_proto_memset=`echo "$cl_cv_proto_memset" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:5308: result: ${ac_t:-
         }$cl_cv_proto_memset" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_memset" >&6

cat >>confdefs.h <<EOF
#define RETMEMSETTYPE $cl_cv_proto_memset_ret
EOF

                      echo "$as_me:5317: checking for broken HP/UX malloc" >&5
echo $ECHO_N "checking for broken HP/UX malloc... $ECHO_C" >&6
if test "${cl_cv_func_malloc_broken+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
# Note that HP-UX has two different malloc() implementations.
# Both are broken. When used with CLISP, the one in the default libc.a
# leads to a SIGSEGV, the one in libmalloc.a leads to a SIGBUS.
case "$host_os" in
  hpux*) cl_cv_func_malloc_broken=yes ;;
  *) cl_cv_func_malloc_broken=no ;;
esac
else
cl_cv_func_malloc_broken="guessing no"
fi

fi
echo "$as_me:5336: result: $cl_cv_func_malloc_broken" >&5
echo "${ECHO_T}$cl_cv_func_malloc_broken" >&6
case "$cl_cv_func_malloc_broken" in
  *yes) # Remedy: Use GNU malloc.
        GMALLOC=gmalloc ;;
  *no)  GMALLOC='' ;;
esac

                      echo "$as_me:5344: checking for malloc declaration" >&5
echo $ECHO_N "checking for malloc declaration... $ECHO_C" >&6
if test "${cl_cv_proto_malloc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5351 "configure"
#include "confdefs.h"
#include <stdlib.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "void.*\*.*malloc" >/dev/null 2>&1; then
  malloc_void=1
fi
rm -f conftest*
if test -z "$malloc_void"; then
cat >conftest.$ac_ext <<_ACEOF
#line 5363 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif
void* malloc();
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5384: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5387: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5390: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5393: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  malloc_void=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
if test -n "$malloc_void"; then
cl_cv_proto_malloc_ret="void*"
else
cl_cv_proto_malloc_ret="char*"
fi
cat >conftest.$ac_ext <<_ACEOF
#line 5408 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$cl_cv_proto_malloc_ret malloc (unsigned int size);
#else
$cl_cv_proto_malloc_ret malloc();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5436: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5439: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5442: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5445: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_malloc_arg1="unsigned int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_malloc_arg1="size_t"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_malloc="extern $cl_cv_proto_malloc_ret malloc ($cl_cv_proto_malloc_arg1);"
fi

cl_cv_proto_malloc=`echo "$cl_cv_proto_malloc" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:5459: result: ${ac_t:-
         }$cl_cv_proto_malloc" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_malloc" >&6

cat >>confdefs.h <<EOF
#define RETMALLOCTYPE $cl_cv_proto_malloc_ret
EOF

cat >>confdefs.h <<EOF
#define MALLOC_SIZE_T $cl_cv_proto_malloc_arg1
EOF

                      echo "$as_me:5472: checking for free declaration" >&5
echo $ECHO_N "checking for free declaration... $ECHO_C" >&6
if test "${cl_cv_proto_free+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5479 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif
int free();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5502: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5505: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5508: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5511: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_free_ret="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_free_ret="void"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_free="extern $cl_cv_proto_free_ret free ($cl_cv_proto_malloc_ret);"
fi

cl_cv_proto_free=`echo "$cl_cv_proto_free" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:5525: result: ${ac_t:-
         }$cl_cv_proto_free" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_free" >&6

cat >>confdefs.h <<EOF
#define RETFREETYPE $cl_cv_proto_free_ret
EOF

                      # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments.  Useless!
echo "$as_me:5536: checking for working alloca.h" >&5
echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
if test "${cl_cv_header_alloca_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5543 "configure"
#include "confdefs.h"
#include <alloca.h>
int
main ()
{
char *p = (char *) alloca(2 * sizeof(int));
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:5555: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:5558: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:5561: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5564: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_header_alloca_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_header_alloca_h=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:5576: result: $cl_cv_header_alloca_h" >&5
echo "${ECHO_T}$cl_cv_header_alloca_h" >&6
if test $cl_cv_header_alloca_h = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_ALLOCA_H 1
EOF

fi
decl="#ifdef __GNUC__
#define alloca __builtin_alloca
#else
#ifdef _MSC_VER
#include <malloc.h>
#define alloca _alloca
#else
#ifdef HAVE_ALLOCA_H
#include <alloca.h>
#else
#ifdef _AIX
 #pragma alloca
#else
#ifndef alloca
char *alloca ();
#endif
#endif
#endif
#endif
#endif
"
echo "$as_me:5605: checking for alloca" >&5
echo $ECHO_N "checking for alloca... $ECHO_C" >&6
if test "${cl_cv_func_alloca+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 5612 "configure"
#include "confdefs.h"
$decl
int
main ()
{
char *p = (char *) alloca(1);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:5624: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:5627: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:5630: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5633: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_alloca=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_alloca=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:5645: result: $cl_cv_func_alloca" >&5
echo "${ECHO_T}$cl_cv_func_alloca" >&6
if test $cl_cv_func_alloca = yes; then
  :
else
  alloca_missing=1
fi
if test -n "$alloca_missing"; then
  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  # that cause trouble.  Some versions do not even contain alloca or
  # contain a buggy version.  If you still want to use their alloca,
  # use ar to extract alloca.o from them instead of compiling alloca.c.
  ALLOCA=alloca.${ac_objext}
  cat >>confdefs.h <<\EOF
#define NO_ALLOCA 1
EOF

fi

                      echo "$as_me:5664: checking for _setjmp" >&5
echo $ECHO_N "checking for _setjmp... $ECHO_C" >&6
if test "${ac_cv_func__setjmp+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 5670 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char _setjmp (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char _setjmp ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub__setjmp) || defined (__stub____setjmp)
choke me
#else
f = _setjmp;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:5701: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:5704: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:5707: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5710: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func__setjmp=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func__setjmp=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:5720: result: $ac_cv_func__setjmp" >&5
echo "${ECHO_T}$ac_cv_func__setjmp" >&6
if test $ac_cv_func__setjmp = yes; then
  :
else
  no__jmp=1
fi
if test -z "$no__jmp"; then
echo "$as_me:5728: checking for _longjmp" >&5
echo $ECHO_N "checking for _longjmp... $ECHO_C" >&6
if test "${ac_cv_func__longjmp+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 5734 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char _longjmp (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char _longjmp ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub__longjmp) || defined (__stub____longjmp)
choke me
#else
f = _longjmp;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:5765: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:5768: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:5771: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5774: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func__longjmp=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func__longjmp=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:5784: result: $ac_cv_func__longjmp" >&5
echo "${ECHO_T}$ac_cv_func__longjmp" >&6
if test $ac_cv_func__longjmp = yes; then
  :
else
  no__jmp=1
fi
fi
if test -z "$no__jmp"; then
cat >>confdefs.h <<\EOF
#define HAVE__JMP 1
EOF

fi
cat >conftest.$ac_ext <<_ACEOF
#line 5799 "configure"
#include "confdefs.h"
#include <setjmp.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "void.* longjmp" >/dev/null 2>&1; then
  :
else
  cat >>confdefs.h <<\EOF
#define LONGJMP_RETURNS 1
EOF

fi
rm -f conftest*

                      echo "$as_me:5815: checking return type of signal handlers" >&5
echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
if test "${cl_cv_type_signal+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 5821 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
#ifdef signal
#undef signal
#endif
extern
#ifdef __cplusplus
"C" void (*signal (int, void (*)(int)))(int);
#else
void (*signal ()) ();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5844: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5847: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5850: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5853: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_type_signal=void
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5

cat >conftest.$ac_ext <<_ACEOF
#line 5861 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
#ifdef signal
#undef signal
#endif
extern
#ifdef __cplusplus
"C" void (*signal (...))(...);
#else
void (*signal ()) ();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5884: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5887: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5890: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5893: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_type_signal=void
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_type_signal=int
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:5905: result: $cl_cv_type_signal" >&5
echo "${ECHO_T}$cl_cv_type_signal" >&6
cat >>confdefs.h <<EOF
#define RETSIGTYPE $cl_cv_type_signal
EOF

echo "$as_me:5911: checking whether the signal handler function type needs dots" >&5
echo $ECHO_N "checking whether the signal handler function type needs dots... $ECHO_C" >&6
if test "${cl_cv_proto_signal_dots+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 5917 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
#ifdef signal
#undef signal
#endif
extern
#ifdef __cplusplus
"C" $cl_cv_type_signal (*signal (int, $cl_cv_type_signal (*)(int)))(int);
#else
$cl_cv_type_signal (*signal ()) ();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:5940: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:5943: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:5946: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:5949: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_signal_dots=no
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_signal_dots=yes
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:5959: result: $cl_cv_proto_signal_dots" >&5
echo "${ECHO_T}$cl_cv_proto_signal_dots" >&6
if test $cl_cv_proto_signal_dots = yes; then
cat >>confdefs.h <<\EOF
#define SIGTYPE_DOTS 1
EOF

fi

                      signalblocks=""
echo "$as_me:5969: checking for sighold" >&5
echo $ECHO_N "checking for sighold... $ECHO_C" >&6
if test "${ac_cv_func_sighold+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 5975 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sighold (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char sighold ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sighold) || defined (__stub___sighold)
choke me
#else
f = sighold;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6006: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6009: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6012: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6015: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_sighold=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_sighold=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6025: result: $ac_cv_func_sighold" >&5
echo "${ECHO_T}$ac_cv_func_sighold" >&6
if test $ac_cv_func_sighold = yes; then
  cat >>confdefs.h <<\EOF
#define SIGNALBLOCK_SYSV 1
EOF

signalblocks="$signalblocks SystemV"
fi
cat >conftest.$ac_ext <<_ACEOF
#line 6035 "configure"
#include "confdefs.h"
#include <signal.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "sigset_t" >/dev/null 2>&1; then
  :
else
  signals_not_posix=1
fi
rm -f conftest*
if test -z "$signals_not_posix"; then
echo "$as_me:6048: checking for sigprocmask" >&5
echo $ECHO_N "checking for sigprocmask... $ECHO_C" >&6
if test "${ac_cv_func_sigprocmask+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6054 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sigprocmask (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char sigprocmask ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sigprocmask) || defined (__stub___sigprocmask)
choke me
#else
f = sigprocmask;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6085: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6088: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6091: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6094: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_sigprocmask=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_sigprocmask=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6104: result: $ac_cv_func_sigprocmask" >&5
echo "${ECHO_T}$ac_cv_func_sigprocmask" >&6
if test $ac_cv_func_sigprocmask = yes; then
  cat >>confdefs.h <<\EOF
#define SIGNALBLOCK_POSIX 1
EOF

signalblocks="$signalblocks POSIX"
fi
fi
echo "$as_me:6114: checking for sigblock" >&5
echo $ECHO_N "checking for sigblock... $ECHO_C" >&6
if test "${ac_cv_func_sigblock+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6120 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sigblock (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char sigblock ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sigblock) || defined (__stub___sigblock)
choke me
#else
f = sigblock;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6151: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6154: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6157: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6160: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_sigblock=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_sigblock=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6170: result: $ac_cv_func_sigblock" >&5
echo "${ECHO_T}$ac_cv_func_sigblock" >&6
if test $ac_cv_func_sigblock = yes; then
  cat >>confdefs.h <<\EOF
#define SIGNALBLOCK_BSD 1
EOF

signalblocks="$signalblocks BSD"
fi
echo "$as_me:6179: checking for signal blocking interfaces" >&5
echo $ECHO_N "checking for signal blocking interfaces... $ECHO_C" >&6
if test "${cl_cv_func_signalblocks+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test -z "$signalblocks"; then
  cl_cv_func_signalblocks="none"
else
  cl_cv_func_signalblocks=`echo $signalblocks`
fi

fi
echo "$as_me:6192: result: $cl_cv_func_signalblocks" >&5
echo "${ECHO_T}$cl_cv_func_signalblocks" >&6

                      case "$signalblocks" in
  *POSIX*)
echo "$as_me:6197: checking for sigprocmask declaration" >&5
echo $ECHO_N "checking for sigprocmask declaration... $ECHO_C" >&6
if test "${cl_cv_proto_sigprocmask+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 6204 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int sigprocmask (int how, sigset_t* set, sigset_t* oset);
#else
int sigprocmask();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:6233: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:6236: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:6239: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6242: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_sigprocmask_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_sigprocmask_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_sigprocmask="extern int sigprocmask (int, $cl_cv_proto_sigprocmask_arg2 sigset_t*, sigset_t*);"
fi

cl_cv_proto_sigprocmask=`echo "$cl_cv_proto_sigprocmask" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:6256: result: ${ac_t:-
         }$cl_cv_proto_sigprocmask" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_sigprocmask" >&6

cat >>confdefs.h <<EOF
#define SIGPROCMASK_CONST $cl_cv_proto_sigprocmask_arg2
EOF

  ;;
  *) ;;
esac

                      echo "$as_me:6269: checking whether signal handlers need to be reinstalled" >&5
echo $ECHO_N "checking whether signal handlers need to be reinstalled... $ECHO_C" >&6
if test "${cl_cv_func_signal_reinstall+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_signal_reinstall="guessing yes"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6279 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>
#ifdef __CYGWIN32__
/* On Cygwin32 version 18, this test would hang (SIGALRM not being signalled).
 * Let it fail instead. */
#error "better fail than hang"
#endif
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
volatile int gotsig=0;
RETSIGTYPE sigalrm_handler() { gotsig=1; }
int got_sig () { return gotsig; }
#ifdef __cplusplus
#ifdef SIGTYPE_DOTS
typedef RETSIGTYPE (*signal_handler) (...);
#else
typedef RETSIGTYPE (*signal_handler) (int);
#endif
#else
typedef RETSIGTYPE (*signal_handler) ();
#endif
int main() { /* returns 0 if they need not to be reinstalled */
  signal(SIGALRM,(signal_handler)sigalrm_handler); alarm(1); while (!got_sig());
  exit(!( (signal_handler)signal(SIGALRM,(signal_handler)sigalrm_handler)
          == (signal_handler)sigalrm_handler
      ) );
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:6315: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6318: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:6320: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6323: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_signal_reinstall=no
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_signal_reinstall=yes
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:6336: result: $cl_cv_func_signal_reinstall" >&5
echo "${ECHO_T}$cl_cv_func_signal_reinstall" >&6
case "$cl_cv_func_signal_reinstall" in
  *yes) cat >>confdefs.h <<\EOF
#define SIGNAL_NEED_REINSTALL 1
EOF
 ;;
  *no) ;;
esac

                      case "$signalblocks" in
  *POSIX* | *BSD*)
echo "$as_me:6348: checking whether signals are blocked when signal handlers are entered" >&5
echo $ECHO_N "checking whether signals are blocked when signal handlers are entered... $ECHO_C" >&6
if test "${cl_cv_func_signal_blocked+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_signal_blocked="guessing yes"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6358 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>
#ifdef __CYGWIN32__
/* On Cygwin32 version 18, this test would hang (SIGALRM not being signalled).
 * Let it fail instead. */
#error "better fail than hang"
#endif
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
volatile int gotsig=0;
volatile int wasblocked=0;
#ifdef __cplusplus
#ifdef SIGTYPE_DOTS
typedef RETSIGTYPE (*signal_handler) (...);
#else
typedef RETSIGTYPE (*signal_handler) (int);
#endif
#else
typedef RETSIGTYPE (*signal_handler) ();
#endif
RETSIGTYPE sigalrm_handler()
{ gotsig=1;
#ifdef SIGNAL_NEED_REINSTALL
  signal(SIGALRM,(signal_handler)sigalrm_handler);
#endif
#ifdef SIGNALBLOCK_POSIX
  { sigset_t blocked;
    sigprocmask(SIG_BLOCK, (sigset_t *) 0, &blocked);
    wasblocked = sigismember(&blocked,SIGALRM) ? 1 : 0;
  }
#else
  wasblocked = ((sigblock(0) & sigmask(SIGALRM)) != 0);
#endif
}
int got_sig () { return gotsig; }
int main() { /* returns 0 if they need not to be unblocked */
  signal(SIGALRM,(signal_handler)sigalrm_handler); alarm(1); while (!got_sig());
  exit(wasblocked);
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:6406: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6409: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:6411: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6414: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_signal_blocked=no
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_signal_blocked=yes
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:6427: result: $cl_cv_func_signal_blocked" >&5
echo "${ECHO_T}$cl_cv_func_signal_blocked" >&6
case "$cl_cv_func_signal_blocked" in
  *yes) cat >>confdefs.h <<\EOF
#define SIGNAL_NEED_UNBLOCK 1
EOF
 ;;
  *no) ;;
esac
  ;;
  *) ;;
esac

                      case "$signalblocks" in
  *POSIX* | *BSD*)
echo "$as_me:6442: checking whether other signals are blocked when signal handlers are entered" >&5
echo $ECHO_N "checking whether other signals are blocked when signal handlers are entered... $ECHO_C" >&6
if test "${cl_cv_func_signal_blocked_others+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_signal_blocked_others="guessing yes"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6452 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>
#ifdef __CYGWIN32__
/* On Cygwin32 version 18, this test would hang (SIGALRM not being signalled).
 * Let it fail instead. */
#error "better fail than hang"
#endif
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
volatile int gotsig=0;
volatile int somewereblocked=0;
#ifdef __cplusplus
#ifdef SIGTYPE_DOTS
typedef RETSIGTYPE (*signal_handler) (...);
#else
typedef RETSIGTYPE (*signal_handler) (int);
#endif
#else
typedef RETSIGTYPE (*signal_handler) ();
#endif
RETSIGTYPE sigalrm_handler()
{ gotsig=1;
#ifdef SIGNAL_NEED_REINSTALL
  signal(SIGALRM,(signal_handler)sigalrm_handler);
#endif
#ifdef SIGNALBLOCK_POSIX
  { sigset_t blocked;
    int i;
    sigprocmask(SIG_BLOCK, (sigset_t *) 0, &blocked);
    for (i=1; i<32; i++)
      if (i!=SIGALRM && sigismember(&blocked,i))
        somewereblocked = 1;
  }
#else
  somewereblocked = ((sigblock(0) & ~sigmask(SIGALRM)) != 0);
#endif
}
int got_sig () { return gotsig; }
int main() { /* returns 0 if they need not to be unblocked */
  signal(SIGALRM,(signal_handler)sigalrm_handler); alarm(1); while (!got_sig());
  exit(somewereblocked);
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:6503: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6506: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:6508: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6511: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_signal_blocked_others=no
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_signal_blocked_others=yes
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:6524: result: $cl_cv_func_signal_blocked_others" >&5
echo "${ECHO_T}$cl_cv_func_signal_blocked_others" >&6
case "$cl_cv_func_signal_blocked_others" in
  *yes) cat >>confdefs.h <<\EOF
#define SIGNAL_NEED_UNBLOCK_OTHERS 1
EOF
 ;;
  *no) ;;
esac
  ;;
  *) ;;
esac

echo "$as_me:6537: checking for sigaction" >&5
echo $ECHO_N "checking for sigaction... $ECHO_C" >&6
if test "${ac_cv_func_sigaction+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6543 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sigaction (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char sigaction ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sigaction) || defined (__stub___sigaction)
choke me
#else
f = sigaction;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6574: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6577: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6580: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6583: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_sigaction=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_sigaction=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6593: result: $ac_cv_func_sigaction" >&5
echo "${ECHO_T}$ac_cv_func_sigaction" >&6
if test $ac_cv_func_sigaction = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SIGACTION 1
EOF

have_sigaction=1
fi

                      if test -n "$have_sigaction"; then
echo "$as_me:6604: checking whether sigaction handlers need to be reinstalled" >&5
echo $ECHO_N "checking whether sigaction handlers need to be reinstalled... $ECHO_C" >&6
if test "${cl_cv_func_sigaction_reinstall+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_sigaction_reinstall="guessing yes"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6614 "configure"
#include "confdefs.h"

#include <stdlib.h>
#include <string.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>
#ifdef __CYGWIN32__
/* On Cygwin32 version 18, this test would hang (SIGALRM not being signalled).
 * Let it fail instead. */
#error "better fail than hang"
#endif
#ifdef __cplusplus
#ifdef SIGTYPE_DOTS
typedef RETSIGTYPE (*signal_handler) (...);
#else
typedef RETSIGTYPE (*signal_handler) (int);
#endif
#else
typedef RETSIGTYPE (*signal_handler) ();
#endif
#if defined(__STDC__) || defined(__cplusplus)
signal_handler mysignal (int sig, signal_handler handler)
#else
signal_handler mysignal (sig, handler)
     int sig;
     signal_handler handler;
#endif
{ struct sigaction old_sa;
  struct sigaction new_sa;
  memset(&new_sa,0,sizeof(new_sa));
  new_sa.sa_handler = handler;
  if (sigaction(sig,&new_sa,&old_sa)<0) { return (signal_handler)SIG_IGN; }
  return (signal_handler)old_sa.sa_handler;
}
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
volatile int gotsig=0;
RETSIGTYPE sigalrm_handler() { gotsig=1; }
int got_sig () { return gotsig; }
int main() { /* returns 0 if they need not to be reinstalled */
  mysignal(SIGALRM,(signal_handler)sigalrm_handler); alarm(1); while (!got_sig());
  exit(!( mysignal(SIGALRM,(signal_handler)sigalrm_handler)
          == (signal_handler)sigalrm_handler
      ) );
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:6665: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6668: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:6670: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6673: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_sigaction_reinstall=no
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_sigaction_reinstall=yes
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:6686: result: $cl_cv_func_sigaction_reinstall" >&5
echo "${ECHO_T}$cl_cv_func_sigaction_reinstall" >&6
case "$cl_cv_func_sigaction_reinstall" in
  *yes) cat >>confdefs.h <<\EOF
#define SIGACTION_NEED_REINSTALL 1
EOF
 ;;
  *no) ;;
esac
fi

                      if test -n "$have_sigaction"; then
case "$signalblocks" in
  *POSIX* | *BSD*)
echo "$as_me:6700: checking whether signals are blocked when sigaction handlers are entered" >&5
echo $ECHO_N "checking whether signals are blocked when sigaction handlers are entered... $ECHO_C" >&6
if test "${cl_cv_func_sigaction_blocked+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_sigaction_blocked="guessing yes"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6710 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <signal.h>
#ifdef __CYGWIN32__
/* On Cygwin32 version 18, this test would hang (SIGALRM not being signalled).
 * Let it fail instead. */
#error "better fail than hang"
#endif
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
#ifdef __cplusplus
#ifdef SIGTYPE_DOTS
typedef RETSIGTYPE (*signal_handler) (...);
#else
typedef RETSIGTYPE (*signal_handler) (int);
#endif
#else
typedef RETSIGTYPE (*signal_handler) ();
#endif
#if defined(__STDC__) || defined(__cplusplus)
signal_handler mysignal (int sig, signal_handler handler)
#else
signal_handler mysignal (sig, handler)
     int sig;
     signal_handler handler;
#endif
{ struct sigaction old_sa;
  struct sigaction new_sa;
  memset(&new_sa,0,sizeof(new_sa));
  new_sa.sa_handler = handler;
  if (sigaction(sig,&new_sa,&old_sa)<0) { return (signal_handler)SIG_IGN; }
  return (signal_handler)old_sa.sa_handler;
}
volatile int gotsig=0;
volatile int wasblocked=0;
RETSIGTYPE sigalrm_handler()
{ gotsig=1;
#ifdef SIGNAL_NEED_REINSTALL
  mysignal(SIGALRM,(signal_handler)sigalrm_handler);
#endif
#ifdef SIGNALBLOCK_POSIX
  { sigset_t blocked;
    sigprocmask(SIG_BLOCK, (sigset_t *) 0, &blocked);
    wasblocked = sigismember(&blocked,SIGALRM) ? 1 : 0;
  }
#else
  wasblocked = ((sigblock(0) & sigmask(SIGALRM)) != 0);
#endif
}
int got_sig () { return gotsig; }
int main() { /* returns 0 if they need not to be unblocked */
  mysignal(SIGALRM,(signal_handler)sigalrm_handler); alarm(1); while (!got_sig());
  exit(wasblocked);
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:6772: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6775: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:6777: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6780: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_sigaction_blocked=no
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_sigaction_blocked=yes
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:6793: result: $cl_cv_func_sigaction_blocked" >&5
echo "${ECHO_T}$cl_cv_func_sigaction_blocked" >&6
case "$cl_cv_func_sigaction_blocked" in
  *yes) cat >>confdefs.h <<\EOF
#define SIGACTION_NEED_UNBLOCK 1
EOF
 ;;
  *no) ;;
esac
  ;;
  *) ;;
esac
fi

                      echo "$as_me:6807: checking for siginterrupt" >&5
echo $ECHO_N "checking for siginterrupt... $ECHO_C" >&6
if test "${ac_cv_func_siginterrupt+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6813 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char siginterrupt (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char siginterrupt ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_siginterrupt) || defined (__stub___siginterrupt)
choke me
#else
f = siginterrupt;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6844: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6847: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6850: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6853: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_siginterrupt=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_siginterrupt=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6863: result: $ac_cv_func_siginterrupt" >&5
echo "${ECHO_T}$ac_cv_func_siginterrupt" >&6
if test $ac_cv_func_siginterrupt = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SIGINTERRUPT 1
EOF

have_siginterrupt=1
fi
if test -z "$have_siginterrupt" -a -z "$have_sigaction"; then

for ac_func in sigvec
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:6877: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 6883 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:6914: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:6917: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:6920: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6923: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:6933: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
fi

                      echo "$as_me:6944: checking for fpu_control_t" >&5
echo $ECHO_N "checking for fpu_control_t... $ECHO_C" >&6
if test "${cl_cv_type_fpu_control_t+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 6951 "configure"
#include "confdefs.h"
#include <fpu_control.h>
int
main ()
{
fpu_control_t x;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:6963: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:6966: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:6969: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:6972: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_type_fpu_control_t=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_type_fpu_control_t=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:6984: result: $cl_cv_type_fpu_control_t" >&5
echo "${ECHO_T}$cl_cv_type_fpu_control_t" >&6
if test $cl_cv_type_fpu_control_t = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_FPU_CONTROL_T 1
EOF

fi

echo "$as_me:6993: checking for __setfpucw" >&5
echo $ECHO_N "checking for __setfpucw... $ECHO_C" >&6
if test "${cl_cv_func_setfpucw+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7000 "configure"
#include "confdefs.h"
#include <fpu_control.h>
int
main ()
{
__setfpucw(_FPU_IEEE);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7012: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7015: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7018: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7021: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_setfpucw=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_setfpucw=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:7033: result: $cl_cv_func_setfpucw" >&5
echo "${ECHO_T}$cl_cv_func_setfpucw" >&6
if test $cl_cv_func_setfpucw = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SETFPUCW 1
EOF

fi

                      echo "$as_me:7042: checking for raise" >&5
echo $ECHO_N "checking for raise... $ECHO_C" >&6
if test "${cl_cv_func_raise+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7049 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
int
main ()
{
raise(6);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:7062: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:7065: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:7068: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7071: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_raise=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_raise=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:7083: result: $cl_cv_func_raise" >&5
echo "${ECHO_T}$cl_cv_func_raise" >&6
if test $cl_cv_func_raise = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_RAISE 1
EOF

fi

                      echo "$as_me:7092: checking for abort declaration" >&5
echo $ECHO_N "checking for abort declaration... $ECHO_C" >&6
if test "${cl_cv_proto_abort+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7099 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif
int abort();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7122: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7125: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7128: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7131: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_abort_ret="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_abort_ret="void"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cat >conftest.$ac_ext <<_ACEOF
#line 7142 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif
$cl_cv_proto_abort_ret abort();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7165: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7168: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7171: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7174: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_abort_vol=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_abort_vol="__volatile__"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_abort="extern $cl_cv_proto_abort_vol $cl_cv_proto_abort_ret abort (void);"
fi

cl_cv_proto_abort=`echo "$cl_cv_proto_abort" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7188: result: ${ac_t:-
         }$cl_cv_proto_abort" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_abort" >&6

cat >>confdefs.h <<EOF
#define RETABORTTYPE $cl_cv_proto_abort_ret
EOF

cat >>confdefs.h <<EOF
#define ABORT_VOLATILE $cl_cv_proto_abort_vol
EOF

                      echo "$as_me:7201: checking for perror declaration" >&5
echo $ECHO_N "checking for perror declaration... $ECHO_C" >&6
if test "${cl_cv_proto_perror+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7208 "configure"
#include "confdefs.h"

/* Some systems declare perror() in <errno.h>, some in <stdio.h>, some don't
   declare it at all. */
#include <stdio.h>
#include <errno.h>
extern
#ifdef __cplusplus
"C"
#endif
double perror ();
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7229: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7232: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7235: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7238: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_perror=no
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_perror=yes
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:7250: result: $cl_cv_proto_perror" >&5
echo "${ECHO_T}$cl_cv_proto_perror" >&6
if test $cl_cv_proto_perror = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_PERROR_DECL 1
EOF

fi

for ac_func in strerror
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:7262: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 7268 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:7299: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:7302: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:7305: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7308: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:7318: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

                      brackets='[]'
echo "$as_me:7329: checking for sys_errlist declaration" >&5
echo $ECHO_N "checking for sys_errlist declaration... $ECHO_C" >&6
if test "${cl_cv_proto_sys_errlist+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7336 "configure"
#include "confdefs.h"

/* Most systems declare sys_errlist in <errno.h>, NetBSD 1.0 in <stdio.h>. */
#include <stdio.h>
#include <errno.h>
extern char* sys_errlist $brackets ;

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7353: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7356: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7359: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7362: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_sys_errlist_const=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_sys_errlist_const="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_sys_errlist="extern $cl_cv_proto_sys_errlist_const char* $cl_cv_proto_sys_errlist_const sys_errlist$brackets;"
fi

cl_cv_proto_sys_errlist=`echo "$cl_cv_proto_sys_errlist" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7376: result: ${ac_t:-
         }$cl_cv_proto_sys_errlist" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_sys_errlist" >&6

cat >>confdefs.h <<EOF
#define SYS_ERRLIST_CONST $cl_cv_proto_sys_errlist_const
EOF

                      echo "$as_me:7385: checking for getenv declaration" >&5
echo $ECHO_N "checking for getenv declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getenv+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7392 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
char* getenv (char* name);
#else
char* getenv();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7420: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7423: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7426: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7429: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getenv_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getenv_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getenv="extern char* getenv ($cl_cv_proto_getenv_arg1 char*);"
fi

cl_cv_proto_getenv=`echo "$cl_cv_proto_getenv" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7443: result: ${ac_t:-
         }$cl_cv_proto_getenv" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getenv" >&6

cat >>confdefs.h <<EOF
#define GETENV_CONST $cl_cv_proto_getenv_arg1
EOF

for ac_func in putenv
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:7455: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 7461 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:7492: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:7495: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:7498: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7501: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:7511: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_putenv = yes; then
echo "$as_me:7521: checking for putenv declaration" >&5
echo $ECHO_N "checking for putenv declaration... $ECHO_C" >&6
if test "${cl_cv_proto_putenv+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7528 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int putenv (char* name);
#else
int putenv();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7556: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7559: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7562: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7565: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_putenv_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_putenv_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_putenv="extern int putenv ($cl_cv_proto_putenv_arg1 char*);"
fi

cl_cv_proto_putenv=`echo "$cl_cv_proto_putenv" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7579: result: ${ac_t:-
         }$cl_cv_proto_putenv" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_putenv" >&6

cat >>confdefs.h <<EOF
#define PUTENV_CONST $cl_cv_proto_putenv_arg1
EOF

else

for ac_func in setenv
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:7593: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 7599 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:7630: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:7633: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:7636: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7639: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:7649: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
fi

                      echo "$as_me:7660: checking for setlocale declaration" >&5
echo $ECHO_N "checking for setlocale declaration... $ECHO_C" >&6
if test "${cl_cv_proto_setlocale+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7667 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifdef HAVE_LOCALE_H
#include <locale.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
char* setlocale (int category, char* locale);
#else
char* setlocale();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7698: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7701: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7704: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7707: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_setlocale_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_setlocale_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_setlocale="extern char* setlocale (int, $cl_cv_proto_setlocale_arg1 char*);"
fi

cl_cv_proto_setlocale=`echo "$cl_cv_proto_setlocale" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7721: result: ${ac_t:-
         }$cl_cv_proto_setlocale" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_setlocale" >&6

cat >>confdefs.h <<EOF
#define SETLOCALE_CONST $cl_cv_proto_setlocale_arg1
EOF

for ac_func in setrlimit
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:7733: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 7739 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:7770: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:7773: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:7776: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7779: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:7789: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_setrlimit = yes; then
echo "$as_me:7799: checking for getrlimit declaration" >&5
echo $ECHO_N "checking for getrlimit declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getrlimit+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7806 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/time.h>
#include <sys/resource.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int getrlimit (int resource, struct rlimit * rlim);
#else
int getrlimit();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7837: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7840: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7843: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7846: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getrlimit_arg1="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getrlimit_arg1="enum __rlimit_resource"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getrlimit="extern int getrlimit ($cl_cv_proto_getrlimit_arg1, struct rlimit *);"
fi

cl_cv_proto_getrlimit=`echo "$cl_cv_proto_getrlimit" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7860: result: ${ac_t:-
         }$cl_cv_proto_getrlimit" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getrlimit" >&6

cat >>confdefs.h <<EOF
#define RLIMIT_RESOURCE_T $cl_cv_proto_getrlimit_arg1
EOF

echo "$as_me:7869: checking for setrlimit declaration" >&5
echo $ECHO_N "checking for setrlimit declaration... $ECHO_C" >&6
if test "${cl_cv_proto_setrlimit+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 7876 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/time.h>
#include <sys/resource.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int setrlimit (RLIMIT_RESOURCE_T resource, struct rlimit * rlim);
#else
int setrlimit();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:7907: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:7910: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:7913: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:7916: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_setrlimit_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_setrlimit_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_setrlimit="extern int setrlimit ($cl_cv_proto_getrlimit_arg1, $cl_cv_proto_setrlimit_arg2 struct rlimit *);"
fi

cl_cv_proto_setrlimit=`echo "$cl_cv_proto_setrlimit" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:7930: result: ${ac_t:-
         }$cl_cv_proto_setrlimit" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_setrlimit" >&6

cat >>confdefs.h <<EOF
#define SETRLIMIT_CONST $cl_cv_proto_setrlimit_arg2
EOF

fi

                      echo "$as_me:7941: checking for ANSI C header files" >&5
echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
if test "${ac_cv_header_stdc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 7947 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>

_ACEOF
if { (eval echo "$as_me:7955: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:7961: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  ac_cv_header_stdc=yes
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  ac_cv_header_stdc=no
fi
rm -f conftest.err conftest.$ac_ext

if test $ac_cv_header_stdc = yes; then
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  cat >conftest.$ac_ext <<_ACEOF
#line 7983 "configure"
#include "confdefs.h"
#include <string.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "memchr" >/dev/null 2>&1; then
  :
else
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  cat >conftest.$ac_ext <<_ACEOF
#line 8001 "configure"
#include "confdefs.h"
#include <stdlib.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "free" >/dev/null 2>&1; then
  :
else
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  if test "$cross_compiling" = yes; then
  :
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8022 "configure"
#include "confdefs.h"
#include <ctype.h>
#if ((' ' & 0x0FF) == 0x020)
# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
#else
# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
                     || ('j' <= (c) && (c) <= 'r') \
                     || ('s' <= (c) && (c) <= 'z'))
# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
#endif

#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
int
main ()
{
  int i;
  for (i = 0; i < 256; i++)
    if (XOR (islower (i), ISLOWER (i))
        || toupper (i) != TOUPPER (i))
      exit(2);
  exit (0);
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:8048: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:8051: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:8053: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8056: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  :
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_header_stdc=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
fi
echo "$as_me:8069: result: $ac_cv_header_stdc" >&5
echo "${ECHO_T}$ac_cv_header_stdc" >&6
if test $ac_cv_header_stdc = yes; then

cat >>confdefs.h <<\EOF
#define STDC_HEADERS 1
EOF

fi

# On IRIX 5.3, sys/types and inttypes.h are conflicting.

for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
                  inttypes.h stdint.h unistd.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:8085: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8091 "configure"
#include "confdefs.h"
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8097: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8100: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8103: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8106: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_Header=no"
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:8116: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

echo "$as_me:8126: checking for pid_t" >&5
echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
if test "${ac_cv_type_pid_t+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8132 "configure"
#include "confdefs.h"
$ac_includes_default
int
main ()
{
if ((pid_t *) 0)
  return 0;
if (sizeof (pid_t))
  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8147: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8150: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8153: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8156: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_type_pid_t=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_type_pid_t=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
echo "$as_me:8166: result: $ac_cv_type_pid_t" >&5
echo "${ECHO_T}$ac_cv_type_pid_t" >&6
if test $ac_cv_type_pid_t = yes; then
  :
else

cat >>confdefs.h <<EOF
#define pid_t int
EOF

fi

for ac_header in unistd.h vfork.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:8181: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8187 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:8191: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:8197: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:8216: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

for ac_func in fork vfork
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:8229: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8235 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:8266: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:8269: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:8272: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8275: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:8285: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

ac_cv_func_fork_works=$ac_cv_func_fork
if test "x$ac_cv_func_fork" = xyes; then
  echo "$as_me:8297: checking for working fork" >&5
echo $ECHO_N "checking for working fork... $ECHO_C" >&6
if test "${ac_cv_func_fork_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test "$cross_compiling" = yes; then
  ac_cv_func_fork_works=cross
else
  cat >conftest.$ac_ext <<_ACEOF
/* By Rüdiger Kuhlmann. */
      #include <sys/types.h>
      #if HAVE_UNISTD_H
      # include <unistd.h>
      #endif
      /* Some systems only have a dummy stub for fork() */
      int main ()
      {
        if (fork() < 0)
          exit (1);
        exit (0);
      }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:8320: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:8323: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:8325: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8328: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_fork_works=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_fork_works=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
echo "$as_me:8340: result: $ac_cv_func_fork_works" >&5
echo "${ECHO_T}$ac_cv_func_fork_works" >&6

fi
if test "x$ac_cv_func_fork_works" = xcross; then
  case $host in
    *-*-amigaos* | *-*-msdosdjgpp*)
      # Override, as these systems have only a dummy fork() stub
      ac_cv_func_fork_works=no
      ;;
    *)
      ac_cv_func_fork_works=yes
      ;;
  esac
  { echo "$as_me:8354: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&5
echo "$as_me: WARNING: CROSS: Result $ac_cv_func_fork_works guessed due to cross-compiling." >&2;}
fi
ac_cv_func_vfork_works=$ac_cv_func_vfork
if test "x$ac_cv_func_vfork" = xyes; then
  echo "$as_me:8359: checking for working vfork" >&5
echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
if test "${ac_cv_func_vfork_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  if test "$cross_compiling" = yes; then
  ac_cv_func_vfork_works=cross
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8368 "configure"
#include "confdefs.h"
/* Thanks to Paul Eggert for this test.  */
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#if HAVE_UNISTD_H
# include <unistd.h>
#endif
#if HAVE_VFORK_H
# include <vfork.h>
#endif
/* On some sparc systems, changes by the child to local and incoming
   argument registers are propagated back to the parent.  The compiler
   is told about this with #include <vfork.h>, but some compilers
   (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
   static variable whose address is put into a register that is
   clobbered by the vfork.  */
static
#ifdef __cplusplus
sparc_address_test (int arg)
# else
sparc_address_test (arg) int arg;
#endif
{
  static pid_t child;
  if (!child) {
    child = vfork ();
    if (child < 0) {
      perror ("vfork");
      _exit(2);
    }
    if (!child) {
      arg = getpid();
      write(-1, "", 0);
      _exit (arg);
    }
  }
}

int
main ()
{
  pid_t parent = getpid ();
  pid_t child;

  sparc_address_test ();

  child = vfork ();

  if (child == 0) {
    /* Here is another test for sparc vfork register problems.  This
       test uses lots of local variables, at least as many local
       variables as main has allocated so far including compiler
       temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
       4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
       reuse the register of parent for one of the local variables,
       since it will think that parent can't possibly be used any more
       in this routine.  Assigning to the local variable will thus
       munge parent in the parent process.  */
    pid_t
      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
    /* Convince the compiler that p..p7 are live; otherwise, it might
       use the same hardware register for all 8 local variables.  */
    if (p != p1 || p != p2 || p != p3 || p != p4
	|| p != p5 || p != p6 || p != p7)
      _exit(1);

    /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
       from child file descriptors.  If the child closes a descriptor
       before it execs or exits, this munges the parent's descriptor
       as well.  Test for this by closing stdout in the child.  */
    _exit(close(fileno(stdout)) != 0);
  } else {
    int status;
    struct stat st;

    while (wait(&status) != child)
      ;
    exit(
	 /* Was there some problem with vforking?  */
	 child < 0

	 /* Did the child fail?  (This shouldn't happen.)  */
	 || status

	 /* Did the vfork/compiler bug occur?  */
	 || parent != getpid()

	 /* Did the file descriptor bug occur?  */
	 || fstat(fileno(stdout), &st) != 0
	 );
  }
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:8465: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:8468: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:8470: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8473: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_vfork_works=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_vfork_works=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
echo "$as_me:8485: result: $ac_cv_func_vfork_works" >&5
echo "${ECHO_T}$ac_cv_func_vfork_works" >&6

fi;
if test "x$ac_cv_func_fork_works" = xcross; then
  ac_cv_func_vfork_works=ac_cv_func_vfork
  { echo "$as_me:8491: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&5
echo "$as_me: WARNING: CROSS: Result $ac_cv_func_vfork_works guessed due to cross-compiling." >&2;}
fi

if test "x$ac_cv_func_vfork_works" = xyes; then

cat >>confdefs.h <<\EOF
#define HAVE_WORKING_VFORK 1
EOF

else

cat >>confdefs.h <<\EOF
#define vfork fork
EOF

fi
if test "x$ac_cv_func_fork_works" = xyes; then

cat >>confdefs.h <<\EOF
#define HAVE_WORKING_FORK 1
EOF

fi

                      echo "$as_me:8516: checking for vfork declaration" >&5
echo $ECHO_N "checking for vfork declaration... $ECHO_C" >&6
if test "${cl_cv_proto_vfork+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 8523 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#ifdef HAVE_VFORK_H
#include <vfork.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
pid_t vfork (void);
#else
pid_t vfork();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8555: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8558: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8561: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8564: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_vfork_ret="pid_t"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_vfork_ret="int"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_vfork="extern $cl_cv_proto_vfork_ret vfork (void);"
fi

cl_cv_proto_vfork=`echo "$cl_cv_proto_vfork" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:8578: result: ${ac_t:-
         }$cl_cv_proto_vfork" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_vfork" >&6

cat >>confdefs.h <<EOF
#define RETVFORKTYPE $cl_cv_proto_vfork_ret
EOF

for ac_func in setsid setpgid
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:8590: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8596 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:8627: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:8630: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:8633: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8636: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:8646: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

                      brackets='[]'
echo "$as_me:8657: checking for execv declaration" >&5
echo $ECHO_N "checking for execv declaration... $ECHO_C" >&6
if test "${cl_cv_proto_execv+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for z in '' 'const'; do
for y in '' 'const'; do
for x in '' 'const'; do
if test -z "$have_execv"; then
cat >conftest.$ac_ext <<_ACEOF
#line 8668 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int execv ($x char* path, $y char* $z argv$brackets);
#else
int execv();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8695: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8698: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8701: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8704: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_execv_arg1="$x"
cl_cv_proto_execv_arg2a="$y"
cl_cv_proto_execv_arg2b="$z"
have_execv=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done
done
done

cl_cv_proto_execv="extern int execv ($cl_cv_proto_execv_arg1 char*, $cl_cv_proto_execv_arg2a char* $cl_cv_proto_execv_arg2b$brackets);"
fi

cl_cv_proto_execv=`echo "$cl_cv_proto_execv" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:8724: result: ${ac_t:-
         }$cl_cv_proto_execv" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_execv" >&6

cat >>confdefs.h <<EOF
#define EXECV_CONST $cl_cv_proto_execv_arg1
EOF

cat >>confdefs.h <<EOF
#define EXECV1_CONST $cl_cv_proto_execv_arg2a
EOF

cat >>confdefs.h <<EOF
#define EXECV2_CONST $cl_cv_proto_execv_arg2b
EOF

                      echo "$as_me:8741: checking for execl declaration" >&5
echo $ECHO_N "checking for execl declaration... $ECHO_C" >&6
if test "${cl_cv_proto_execl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in '' 'const'; do
if test -z "$have_execl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 8750 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int execl (EXECV_CONST char* path, $x char* arg, ...);
#else
int execl();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8777: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8780: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8783: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8786: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_execl_arg2="$x"
cl_cv_proto_execl_dots=yes
cl_cv_proto_execl_args="$cl_cv_proto_execv_arg1 char*, $cl_cv_proto_execl_arg2 char*, ..."
have_execl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done
for x in '' 'const'; do
if test -z "$have_execl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 8803 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int execl (EXECV_CONST char* path, $x char* arg0, $x char* arg1, $x char* arg2, $x char* arg3);
#else
int execl();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8830: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8833: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8836: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8839: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_execl_arg2="$x"
cl_cv_proto_execl_dots=no
cl_cv_proto_execl_args="$cl_cv_proto_execv_arg1 char*, $cl_cv_proto_execl_arg2 char*, $cl_cv_proto_execl_arg2 char*, $cl_cv_proto_execl_arg2 char*, $cl_cv_proto_execl_arg2 char*"
have_execl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done

cl_cv_proto_execl="extern int execl ($cl_cv_proto_execl_args);"
fi

cl_cv_proto_execl=`echo "$cl_cv_proto_execl" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:8858: result: ${ac_t:-
         }$cl_cv_proto_execl" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_execl" >&6

cat >>confdefs.h <<EOF
#define EXECL_CONST $cl_cv_proto_execl_arg2
EOF

if test $cl_cv_proto_execl_dots = yes; then
  cat >>confdefs.h <<\EOF
#define EXECL_DOTS 1
EOF

fi

                      echo "$as_me:8874: checking for waitpid declaration" >&5
echo $ECHO_N "checking for waitpid declaration... $ECHO_C" >&6
if test "${cl_cv_proto_waitpid+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 8881 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
pid_t waitpid (pid_t pid, int* statusp, int options);
#else
pid_t waitpid();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:8910: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:8913: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:8916: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:8919: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_waitpid_arg1="pid_t"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_waitpid_arg1="int"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_waitpid="extern pid_t waitpid ($cl_cv_proto_waitpid_arg1, int*, int);"
fi

cl_cv_proto_waitpid=`echo "$cl_cv_proto_waitpid" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:8933: result: ${ac_t:-
         }$cl_cv_proto_waitpid" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_waitpid" >&6

cat >>confdefs.h <<EOF
#define PID_T $cl_cv_proto_waitpid_arg1
EOF

for ac_header in sys/resource.h sys/times.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:8945: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 8951 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:8955: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:8961: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:8980: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_header_sys_resource_h = yes; then
    echo "$as_me:8990: checking for getrusage" >&5
echo $ECHO_N "checking for getrusage... $ECHO_C" >&6
if test "${cl_cv_func_getrusage+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 8997 "configure"
#include "confdefs.h"
#include <sys/types.h> /* NetBSD 1.0 needs this */
#include <sys/time.h>
#include <sys/resource.h>
int
main ()
{
struct rusage x; int y = RUSAGE_SELF; getrusage(y,&x); x.ru_utime.tv_sec;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9011: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9014: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9017: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9020: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_getrusage=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_getrusage=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:9032: result: $cl_cv_func_getrusage" >&5
echo "${ECHO_T}$cl_cv_func_getrusage" >&6
if test $cl_cv_func_getrusage = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_GETRUSAGE 1
EOF

fi
  if test $cl_cv_func_getrusage = yes; then
    echo "$as_me:9041: checking for getrusage declaration" >&5
echo $ECHO_N "checking for getrusage declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getrusage+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

    cat >conftest.$ac_ext <<_ACEOF
#line 9048 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h> /* NetBSD 1.0 needs this */
#include <sys/time.h>
#include <sys/resource.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int getrusage (int who, struct rusage * rusage);
#else
int getrusage();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:9079: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:9082: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:9085: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9088: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getrusage_arg1="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getrusage_arg1="enum __rusage_who"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getrusage="extern int getrusage ($cl_cv_proto_getrusage_arg1, struct rusage *);"
fi

cl_cv_proto_getrusage=`echo "$cl_cv_proto_getrusage" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9102: result: ${ac_t:-
         }$cl_cv_proto_getrusage" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getrusage" >&6

    cat >>confdefs.h <<EOF
#define RUSAGE_WHO_T $cl_cv_proto_getrusage_arg1
EOF

  fi
fi

                      echo "$as_me:9114: checking for getcwd" >&5
echo $ECHO_N "checking for getcwd... $ECHO_C" >&6
if test "${cl_cv_func_getcwd+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9121 "configure"
#include "confdefs.h"

#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif

int
main ()
{
getcwd((char*)0,1024);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9138: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9141: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9144: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9147: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_getcwd=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_getcwd=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:9159: result: $cl_cv_func_getcwd" >&5
echo "${ECHO_T}$cl_cv_func_getcwd" >&6
if test $cl_cv_func_getcwd = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_GETCWD 1
EOF

fi

if test $cl_cv_func_getcwd = yes; then
echo "$as_me:9169: checking for getcwd declaration" >&5
echo $ECHO_N "checking for getcwd declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getcwd+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9176 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
char* getcwd (char* buf, int bufsize);
#else
char* getcwd();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:9204: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:9207: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:9210: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9213: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getcwd_arg2="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getcwd_arg2="size_t"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getcwd="extern char* getcwd (char*, $cl_cv_proto_getcwd_arg2);"
fi

cl_cv_proto_getcwd=`echo "$cl_cv_proto_getcwd" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9227: result: ${ac_t:-
         }$cl_cv_proto_getcwd" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getcwd" >&6

cat >>confdefs.h <<EOF
#define GETCWD_SIZE_T $cl_cv_proto_getcwd_arg2
EOF

fi

                      echo "$as_me:9238: checking for chdir declaration" >&5
echo $ECHO_N "checking for chdir declaration... $ECHO_C" >&6
if test "${cl_cv_proto_chdir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9245 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int chdir (char* path);
#else
int chdir();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:9273: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:9276: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:9279: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9282: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_chdir_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_chdir_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_chdir="extern int chdir ($cl_cv_proto_chdir_arg1 char*);"
fi

cl_cv_proto_chdir=`echo "$cl_cv_proto_chdir" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9296: result: ${ac_t:-
         }$cl_cv_proto_chdir" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_chdir" >&6

cat >>confdefs.h <<EOF
#define CHDIR_CONST $cl_cv_proto_chdir_arg1
EOF

                      echo "$as_me:9305: checking for mkdir declaration" >&5
echo $ECHO_N "checking for mkdir declaration... $ECHO_C" >&6
if test "${cl_cv_proto_mkdir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9312 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int mkdir (char* path, mode_t mode);
#else
int mkdir();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:9342: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:9345: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:9348: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9351: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_mkdir_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_mkdir_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_mkdir="extern int mkdir ($cl_cv_proto_mkdir_arg1 char*, mode_t);"
fi

cl_cv_proto_mkdir=`echo "$cl_cv_proto_mkdir" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9365: result: ${ac_t:-
         }$cl_cv_proto_mkdir" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_mkdir" >&6

cat >>confdefs.h <<EOF
#define MKDIR_CONST $cl_cv_proto_mkdir_arg1
EOF

                      echo "$as_me:9374: checking for rmdir declaration" >&5
echo $ECHO_N "checking for rmdir declaration... $ECHO_C" >&6
if test "${cl_cv_proto_rmdir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9381 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int rmdir (char* path);
#else
int rmdir();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:9409: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:9412: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:9415: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9418: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_rmdir_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_rmdir_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_rmdir="extern int rmdir ($cl_cv_proto_rmdir_arg1 char*);"
fi

cl_cv_proto_rmdir=`echo "$cl_cv_proto_rmdir" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9432: result: ${ac_t:-
         }$cl_cv_proto_rmdir" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_rmdir" >&6

cat >>confdefs.h <<EOF
#define RMDIR_CONST $cl_cv_proto_rmdir_arg1
EOF

                      echo "$as_me:9441: checking whether stat file-mode macros are broken" >&5
echo $ECHO_N "checking whether stat file-mode macros are broken... $ECHO_C" >&6
if test "${ac_cv_header_stat_broken+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 9447 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/stat.h>

#if defined(S_ISBLK) && defined(S_IFDIR)
# if S_ISBLK (S_IFDIR)
You lose.
# endif
#endif

#if defined(S_ISBLK) && defined(S_IFCHR)
# if S_ISBLK (S_IFCHR)
You lose.
# endif
#endif

#if defined(S_ISLNK) && defined(S_IFREG)
# if S_ISLNK (S_IFREG)
You lose.
# endif
#endif

#if defined(S_ISSOCK) && defined(S_IFREG)
# if S_ISSOCK (S_IFREG)
You lose.
# endif
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "You lose" >/dev/null 2>&1; then
  ac_cv_header_stat_broken=yes
else
  ac_cv_header_stat_broken=no
fi
rm -f conftest*

fi
echo "$as_me:9486: result: $ac_cv_header_stat_broken" >&5
echo "${ECHO_T}$ac_cv_header_stat_broken" >&6
if test $ac_cv_header_stat_broken = yes; then

cat >>confdefs.h <<\EOF
#define STAT_MACROS_BROKEN 1
EOF

fi

                      echo "$as_me:9496: checking for fstat declaration" >&5
echo $ECHO_N "checking for fstat declaration... $ECHO_C" >&6
if test "${cl_cv_proto_fstat+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9503 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int fstat (int fd, struct stat * buf);
#else
int fstat();
#endif

int
main ()
{
return fstat(0,(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9533: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9536: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9539: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9542: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_fstat_inline=no
have_fstat_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test -z "$have_fstat_decl"; then
  # This happens on Linux with g++ and libc-5.0.9.
  cl_cv_proto_fstat_inline=yes
fi

cl_cv_proto_fstat="extern int fstat (int, struct stat *);"
fi

cl_cv_proto_fstat=`echo "$cl_cv_proto_fstat" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9560: result: ${ac_t:-
         }$cl_cv_proto_fstat" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_fstat" >&6

if test $cl_cv_proto_fstat_inline = yes; then
  cat >>confdefs.h <<\EOF
#define FSTAT_INLINE 1
EOF

fi

                      cl_cv_proto_stat_inline=$cl_cv_proto_fstat_inline
if test $cl_cv_proto_stat_inline = yes; then
  cat >>confdefs.h <<\EOF
#define STAT_INLINE 1
EOF

fi
echo "$as_me:9579: checking for stat declaration" >&5
echo $ECHO_N "checking for stat declaration... $ECHO_C" >&6
if test "${cl_cv_proto_stat+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9586 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>
#if defined(__cplusplus) && defined(STAT_INLINE)
extern
#else

extern
#ifdef __cplusplus
"C"
#endif

#endif
#if defined(__STDC__) || defined(__cplusplus)
int stat (char* path, struct stat * buf);
#else
int stat();
#endif

int
main ()
{
return stat((char*)"",(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9620: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9623: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9626: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9629: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_stat_arg1=""
have_stat_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test -z "$have_stat_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 9640 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>
#if defined(__cplusplus) && defined(STAT_INLINE)
extern
#else

extern
#ifdef __cplusplus
"C"
#endif

#endif
#if defined(__STDC__) || defined(__cplusplus)
int stat (const char* path, struct stat * buf);
#else
int stat();
#endif

int
main ()
{
return stat((const char*)"",(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9674: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9677: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9680: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9683: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_stat_arg1="const"
have_stat_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi

cl_cv_proto_stat="extern int stat ($cl_cv_proto_stat_arg1 char*, struct stat *);"
fi

cl_cv_proto_stat=`echo "$cl_cv_proto_stat" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9698: result: ${ac_t:-
         }$cl_cv_proto_stat" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_stat" >&6

cat >>confdefs.h <<EOF
#define STAT_CONST $cl_cv_proto_stat_arg1
EOF

                      echo "$as_me:9707: checking for lstat" >&5
echo $ECHO_N "checking for lstat... $ECHO_C" >&6
if test "${cl_cv_func_lstat+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9714 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/stat.h>

int
main ()
{
return lstat("",(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9729: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9732: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9735: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9738: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_lstat=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_lstat=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:9750: result: $cl_cv_func_lstat" >&5
echo "${ECHO_T}$cl_cv_func_lstat" >&6
if test $cl_cv_func_lstat = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_LSTAT 1
EOF

fi
if test $cl_cv_func_lstat = yes; then
cl_cv_proto_lstat_inline=$cl_cv_proto_fstat_inline
if test $cl_cv_proto_lstat_inline = yes; then
  cat >>confdefs.h <<\EOF
#define LSTAT_INLINE 1
EOF

fi
echo "$as_me:9766: checking for lstat declaration" >&5
echo $ECHO_N "checking for lstat declaration... $ECHO_C" >&6
if test "${cl_cv_proto_lstat+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 9773 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>
#if defined(__cplusplus) && defined(LSTAT_INLINE)
extern
#else

extern
#ifdef __cplusplus
"C"
#endif

#endif
#if defined(__STDC__) || defined(__cplusplus)
int lstat (char* path, struct stat * buf);
#else
int lstat();
#endif

int
main ()
{
return lstat((char*)"",(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9807: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9810: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9813: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9816: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_lstat_arg1=""
have_lstat_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test -z "$have_lstat_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 9827 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/stat.h>
#if defined(__cplusplus) && defined(STAT_INLINE)
extern
#else

extern
#ifdef __cplusplus
"C"
#endif

#endif
#if defined(__STDC__) || defined(__cplusplus)
int lstat (const char* path, struct stat * buf);
#else
int lstat();
#endif

int
main ()
{
return lstat((const char*)"",(struct stat *)0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9861: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9864: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9867: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9870: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_lstat_arg1="const"
have_lstat_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi

cl_cv_proto_lstat="extern int lstat ($cl_cv_proto_lstat_arg1 char*, struct stat *);"
fi

cl_cv_proto_lstat=`echo "$cl_cv_proto_lstat" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:9885: result: ${ac_t:-
         }$cl_cv_proto_lstat" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_lstat" >&6

cat >>confdefs.h <<EOF
#define LSTAT_CONST $cl_cv_proto_lstat_arg1
EOF

fi

for ac_func in readlink
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:9899: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 9905 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:9936: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:9939: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:9942: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:9945: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:9955: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_readlink = yes; then
echo "$as_me:9965: checking for readlink declaration" >&5
echo $ECHO_N "checking for readlink declaration... $ECHO_C" >&6
if test "${cl_cv_proto_readlink+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for r in 'int' 'ssize_t'; do
for z in 'int' 'size_t'; do
for y in 'char*' 'void*'; do
for x in '' 'const'; do
if test -z "$have_readlink"; then
cat >conftest.$ac_ext <<_ACEOF
#line 9977 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$r readlink ($x char* path, $y buf, $z bufsiz);
#else
$r readlink();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10004: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10007: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10010: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10013: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_readlink_ret="$r"
cl_cv_proto_readlink_arg1="$x"
cl_cv_proto_readlink_arg2="$y"
cl_cv_proto_readlink_arg3="$z"
have_readlink=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done
done
done
done

cl_cv_proto_readlink="extern $cl_cv_proto_readlink_ret readlink ($cl_cv_proto_readlink_arg1 char*, $cl_cv_proto_readlink_arg2, $cl_cv_proto_readlink_arg3);"
fi

cl_cv_proto_readlink=`echo "$cl_cv_proto_readlink" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10035: result: ${ac_t:-
         }$cl_cv_proto_readlink" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_readlink" >&6

cat >>confdefs.h <<EOF
#define RETREADLINKTYPE $cl_cv_proto_readlink_ret
EOF

cat >>confdefs.h <<EOF
#define READLINK_CONST $cl_cv_proto_readlink_arg1
EOF

cat >>confdefs.h <<EOF
#define READLINK_BUF_T $cl_cv_proto_readlink_arg2
EOF

cat >>confdefs.h <<EOF
#define READLINK_SIZE_T $cl_cv_proto_readlink_arg3
EOF

fi

                      echo "$as_me:10058: checking for ELOOP" >&5
echo $ECHO_N "checking for ELOOP... $ECHO_C" >&6
if test "${cl_cv_decl_eloop+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
cat > conftest.c <<EOF
#include "confdefs.h"
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <errno.h>
#include <stdio.h>
#ifdef ELOOP
int main () { printf("ELOOP\n"); exit(0); }
#else
extern int errno;
#define foo "conflink"
#define foobar "conflink/somefile"
int main()
{ /* If a system goes into an endless loop on this, it must be really broken. */
  if (symlink(foo,foo)<0) exit(1);
  if (unlink(foobar)>=0) { unlink(foo); exit(1); }
  printf("%d\n",errno); unlink(foo); exit(0);
}
#endif
EOF
{ (eval echo "$as_me:10087: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:10090: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_decl_ELOOP=`./conftest`
if test "$cl_cv_decl_ELOOP" = "ELOOP"; then
  cl_cv_decl_eloop=yes
else
  cl_cv_decl_eloop="$cl_cv_decl_ELOOP"
fi
else
cat >conftest.$ac_ext <<_ACEOF
#line 10100 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <errno.h>
#include <stdio.h>
#ifdef ELOOP
yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  cl_cv_decl_eloop=yes
else
  cl_cv_decl_eloop=no
fi
rm -f conftest*

cl_cv_decl_ELOOP="ELOOP"
fi
rm -f conftest*

fi
echo "$as_me:10127: result: $cl_cv_decl_eloop" >&5
echo "${ECHO_T}$cl_cv_decl_eloop" >&6
cat >>confdefs.h <<EOF
#define ELOOP_VALUE $cl_cv_decl_ELOOP
EOF

                      echo "$as_me:10133: checking for opendir declaration" >&5
echo $ECHO_N "checking for opendir declaration... $ECHO_C" >&6
if test "${cl_cv_proto_opendir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10140 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <$ac_header_dirent>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
DIR* opendir (char* dirname);
#else
DIR* opendir();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10169: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10172: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10175: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10178: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_opendir_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_opendir_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_opendir="extern DIR* opendir ($cl_cv_proto_opendir_arg1 char*);"
fi

cl_cv_proto_opendir=`echo "$cl_cv_proto_opendir" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10192: result: ${ac_t:-
         }$cl_cv_proto_opendir" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_opendir" >&6

cat >>confdefs.h <<EOF
#define OPENDIR_CONST $cl_cv_proto_opendir_arg1
EOF

                      echo "$as_me:10201: checking for closedir declaration" >&5
echo $ECHO_N "checking for closedir declaration... $ECHO_C" >&6
if test "${cl_cv_proto_closedir+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10208 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
#include <$ac_header_dirent>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int closedir (DIR* dir);
#else
int closedir();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10238: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10241: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10244: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10247: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_closedir_ret="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_closedir_ret="void"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_closedir="extern $cl_cv_proto_closedir_ret closedir (DIR*);"
fi

cl_cv_proto_closedir=`echo "$cl_cv_proto_closedir" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10261: result: ${ac_t:-
         }$cl_cv_proto_closedir" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_closedir" >&6

cat >>confdefs.h <<EOF
#define RETCLOSEDIRTYPE $cl_cv_proto_closedir_ret
EOF

if test $cl_cv_proto_closedir_ret = void; then
  cat >>confdefs.h <<\EOF
#define VOID_CLOSEDIR 1
EOF

else
  # The following test is necessary, because Cygwin32 declares closedir()
  # as returning int but the return value is unusable.
  echo "$as_me:10278: checking for usable closedir return value" >&5
echo $ECHO_N "checking for usable closedir return value... $ECHO_C" >&6
if test "${cl_cv_func_closedir_retval+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  # When cross-compiling, don't assume a return value.
cl_cv_func_closedir_retval="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 10289 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
/* Declare opendir(), closedir(). */
#include <$ac_header_dirent>
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
DIR* opendir (OPENDIR_CONST char* dirname);
#else
DIR* opendir();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETCLOSEDIRTYPE closedir (DIR* dirp);
#else
RETCLOSEDIRTYPE closedir();
#endif
int main() { exit(closedir(opendir(".")) != 0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:10322: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:10325: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:10327: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10330: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_closedir_retval=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_closedir_retval=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
echo "$as_me:10342: result: $cl_cv_func_closedir_retval" >&5
echo "${ECHO_T}$cl_cv_func_closedir_retval" >&6
case "$cl_cv_func_closedir_retval" in
  *no) cat >>confdefs.h <<\EOF
#define VOID_CLOSEDIR 1
EOF
 ;;
esac
fi

                      echo "$as_me:10352: checking for open declaration" >&5
echo $ECHO_N "checking for open declaration... $ECHO_C" >&6
if test "${cl_cv_proto_open+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for y in 'mode_t mode' '...'; do
for x in '' 'const'; do
if test -z "$have_open"; then
cat >conftest.$ac_ext <<_ACEOF
#line 10362 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <fcntl.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int open ($x char* path, int flags, $y);
#else
int open();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10391: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10394: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10397: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10400: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_open_arg1="$x"
if test "$y" = "..."; then
cl_cv_proto_open_dots=yes
else
cl_cv_proto_open_dots=no
fi
have_open=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
if test -z "$cl_cv_proto_open_dots"; then
  cl_cv_proto_open_arg1="const"
  cl_cv_proto_open_dots=yes
fi
if test $cl_cv_proto_open_dots = yes; then
cl_cv_proto_open_args="$cl_cv_proto_open_arg1 char*, int, ..."
else
cl_cv_proto_open_args="$cl_cv_proto_open_arg1 char*, int, mode_t"
fi

cl_cv_proto_open="extern int open ($cl_cv_proto_open_args);"
fi

cl_cv_proto_open=`echo "$cl_cv_proto_open" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10433: result: ${ac_t:-
         }$cl_cv_proto_open" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_open" >&6

cat >>confdefs.h <<EOF
#define OPEN_CONST $cl_cv_proto_open_arg1
EOF

if test $cl_cv_proto_open_dots = yes; then
cat >>confdefs.h <<\EOF
#define OPEN_DOTS 1
EOF

fi

                      echo "$as_me:10449: checking for read declaration" >&5
echo $ECHO_N "checking for read declaration... $ECHO_C" >&6
if test "${cl_cv_proto_read+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for z in 'int' 'size_t' "unsigned $cl_cv_proto_retrwtype" 'off_t'; do
for y in 'char*' 'void*'; do
for x in 'int' 'long'; do
if test -z "$have_rw"; then
cat >conftest.$ac_ext <<_ACEOF
#line 10460 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$x read (int fd, $y buf, $z count);
#else
$x read();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10488: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10491: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10494: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10497: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_retrwtype="$x"
cl_cv_proto_rw_buf_t="$y"
cl_cv_proto_rw_size_t="$z"
have_rw=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
done

cl_cv_proto_read="extern $cl_cv_proto_retrwtype read (int, $cl_cv_proto_rw_buf_t, $cl_cv_proto_rw_size_t);"
fi

cl_cv_proto_read=`echo "$cl_cv_proto_read" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10519: result: ${ac_t:-
         }$cl_cv_proto_read" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_read" >&6

cat >>confdefs.h <<EOF
#define RETRWTYPE $cl_cv_proto_retrwtype
EOF

cat >>confdefs.h <<EOF
#define RW_BUF_T $cl_cv_proto_rw_buf_t
EOF

cat >>confdefs.h <<EOF
#define RW_SIZE_T $cl_cv_proto_rw_size_t
EOF

                      echo "$as_me:10536: checking for write declaration" >&5
echo $ECHO_N "checking for write declaration... $ECHO_C" >&6
if test "${cl_cv_proto_write+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10543 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$cl_cv_proto_retrwtype write (int fd, $cl_cv_proto_rw_buf_t buf, $cl_cv_proto_rw_size_t count);
#else
$cl_cv_proto_retrwtype write();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10571: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10574: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10577: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10580: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_write_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_write_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_write="extern $cl_cv_proto_retrwtype write (int, $cl_cv_proto_write_arg2 $cl_cv_proto_rw_buf_t, $cl_cv_proto_rw_size_t);"
fi

cl_cv_proto_write=`echo "$cl_cv_proto_write" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10594: result: ${ac_t:-
         }$cl_cv_proto_write" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_write" >&6

cat >>confdefs.h <<EOF
#define WRITE_CONST $cl_cv_proto_write_arg2
EOF

                      echo "$as_me:10603: checking for rename declaration" >&5
echo $ECHO_N "checking for rename declaration... $ECHO_C" >&6
if test "${cl_cv_proto_rename+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10610 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <stdio.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int rename (char* oldpath, char* newpath);
#else
int rename();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10639: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10642: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10645: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10648: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_rename_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_rename_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_rename="extern int rename ($cl_cv_proto_rename_arg1 char*, $cl_cv_proto_rename_arg1 char*);"
fi

cl_cv_proto_rename=`echo "$cl_cv_proto_rename" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10662: result: ${ac_t:-
         }$cl_cv_proto_rename" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_rename" >&6

cat >>confdefs.h <<EOF
#define RENAME_CONST $cl_cv_proto_rename_arg1
EOF

                      echo "$as_me:10671: checking for unlink declaration" >&5
echo $ECHO_N "checking for unlink declaration... $ECHO_C" >&6
if test "${cl_cv_proto_unlink+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10678 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int unlink (char* path);
#else
int unlink();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10706: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10709: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10712: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10715: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_unlink_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_unlink_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_unlink="extern int unlink ($cl_cv_proto_unlink_arg1 char*);"
fi

cl_cv_proto_unlink=`echo "$cl_cv_proto_unlink" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10729: result: ${ac_t:-
         }$cl_cv_proto_unlink" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_unlink" >&6

cat >>confdefs.h <<EOF
#define UNLINK_CONST $cl_cv_proto_unlink_arg1
EOF

for ac_func in fsync
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:10741: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 10747 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:10778: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:10781: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:10784: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10787: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:10797: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

                      ioctl_decl1='
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
#ifndef HAVE_TCSAFLUSH
#undef HAVE_TERMIOS_H
#endif
#ifdef HAVE_TERMIOS_H
#include <termios.h>
#else
#ifdef HAVE_SYS_TERMIO_H
#include <sys/termio.h>
#else
#ifdef HAVE_TERMIO_H
#include <termio.h>
#else
#ifdef HAVE_SGTTY_H
#include <sgtty.h>
#include <sys/ioctl.h>
#endif
#endif
#endif
#endif
'
echo "$as_me:10833: checking for ioctl declaration" >&5
echo $ECHO_N "checking for ioctl declaration... $ECHO_C" >&6
if test "${cl_cv_proto_ioctl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 10840 "configure"
#include "confdefs.h"
$ioctl_decl1
extern
#ifdef __cplusplus
"C"
#endif
char* ioctl();
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10857: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10860: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10863: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10866: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  try_sys_ioctl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ioctl_decl="$ioctl_decl1"
fi
rm -f conftest.$ac_objext conftest.$ac_ext
if test -n "try_sys_ioctl"; then
ioctl_decl2='
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif
#include <sys/ioctl.h>
'
cat >conftest.$ac_ext <<_ACEOF
#line 10885 "configure"
#include "confdefs.h"
$ioctl_decl2
extern
#ifdef __cplusplus
"C"
#endif
char* ioctl();
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10902: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10905: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10908: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10911: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ioctl_decl="$ioctl_decl1"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ioctl_decl="$ioctl_decl2"
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
for y in 'caddr_t arg' 'void* arg' '...'; do
for x in 'int' 'unsigned long' 'long'; do
if test -z "$have_ioctl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 10925 "configure"
#include "confdefs.h"
$ioctl_decl
#ifdef INCLUDE_SYS_IOCTL_H
#include <sys/ioctl.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int ioctl (int fd, $x request, $y);
#else
int ioctl();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:10952: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:10955: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:10958: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:10961: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_ioctl_arg2="$x"
if test "$y" = "..."; then
cl_cv_proto_ioctl_dots=yes
cl_cv_proto_ioctl_args="int, $cl_cv_proto_ioctl_arg2, ..."
else
cl_cv_proto_ioctl_dots=no
cl_cv_proto_ioctl_arg3=`echo "$y" | sed -e 's, arg,,'`
cl_cv_proto_ioctl_args="int, $cl_cv_proto_ioctl_arg2, $cl_cv_proto_ioctl_arg3"
fi
have_ioctl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done

cl_cv_proto_ioctl="extern int ioctl ($cl_cv_proto_ioctl_args);"
fi

cl_cv_proto_ioctl=`echo "$cl_cv_proto_ioctl" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:10988: result: ${ac_t:-
         }$cl_cv_proto_ioctl" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_ioctl" >&6

cat >>confdefs.h <<EOF
#define IOCTL_REQUEST_T $cl_cv_proto_ioctl_arg2
EOF

if test $cl_cv_proto_ioctl_dots = yes; then
cat >>confdefs.h <<\EOF
#define IOCTL_DOTS 1
EOF

else
cat >>confdefs.h <<EOF
#define IOCTL_ARGUMENT_T $cl_cv_proto_ioctl_arg3
EOF

fi
ioctl_decl="$ioctl_decl1"
ioctl_prog='int x = FIONREAD;'
echo "$as_me:11010: checking for FIONREAD" >&5
echo $ECHO_N "checking for FIONREAD... $ECHO_C" >&6
if test "${cl_cv_decl_FIONREAD_1+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11017 "configure"
#include "confdefs.h"
$ioctl_decl
int
main ()
{
$ioctl_prog
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11029: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11032: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11035: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11038: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_FIONREAD_1=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_FIONREAD_1=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:11050: result: $cl_cv_decl_FIONREAD_1" >&5
echo "${ECHO_T}$cl_cv_decl_FIONREAD_1" >&6
if test $cl_cv_decl_FIONREAD_1 = yes; then
  ioctl_ok=1
fi
if test -z "$ioctl_ok"; then
echo "$as_me:11056: checking for FIONREAD in sys/filio.h" >&5
echo $ECHO_N "checking for FIONREAD in sys/filio.h... $ECHO_C" >&6
if test "${cl_cv_decl_FIONREAD_1_sys_filio_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11063 "configure"
#include "confdefs.h"
$ioctl_decl#include <sys/filio.h>
int
main ()
{
$ioctl_prog
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11075: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11078: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11081: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11084: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_FIONREAD_1_sys_filio_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_FIONREAD_1_sys_filio_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:11096: result: $cl_cv_decl_FIONREAD_1_sys_filio_h" >&5
echo "${ECHO_T}$cl_cv_decl_FIONREAD_1_sys_filio_h" >&6
if test $cl_cv_decl_FIONREAD_1_sys_filio_h = yes; then
  cat >>confdefs.h <<\EOF
#define NEED_SYS_FILIO_H 1
EOF

ioctl_ok=1
fi
fi
if test -z "$ioctl_ok"; then
echo "$as_me:11107: checking for FIONREAD in sys/ioctl.h" >&5
echo $ECHO_N "checking for FIONREAD in sys/ioctl.h... $ECHO_C" >&6
if test "${cl_cv_decl_FIONREAD_1_sys_ioctl_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11114 "configure"
#include "confdefs.h"
$ioctl_decl#include <sys/ioctl.h>
int
main ()
{
$ioctl_prog
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11126: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11129: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11132: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11135: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_FIONREAD_1_sys_ioctl_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_FIONREAD_1_sys_ioctl_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:11147: result: $cl_cv_decl_FIONREAD_1_sys_ioctl_h" >&5
echo "${ECHO_T}$cl_cv_decl_FIONREAD_1_sys_ioctl_h" >&6
if test $cl_cv_decl_FIONREAD_1_sys_ioctl_h = yes; then
  cat >>confdefs.h <<\EOF
#define NEED_SYS_IOCTL_H 1
EOF

ioctl_ok=1
fi
fi
if test -n "$ioctl_ok"; then
cat >>confdefs.h <<\EOF
#define HAVE_FIONREAD 1
EOF

# Now check whether FIONREAD reliably checks for the EOF of a regular file.
# The number of available characters returned by ioctl(fd,FIONREAD,...) should
# be > 0 for a non-empty regular file at least. On Solaris 2, it is 0.
echo "$as_me:11165: checking for reliable FIONREAD" >&5
echo $ECHO_N "checking for reliable FIONREAD... $ECHO_C" >&6
if test "${cl_cv_decl_FIONREAD_reliable+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_decl_FIONREAD_reliable="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11175 "configure"
#include "confdefs.h"

/* Declare ioctl(). */
$ioctl_decl
#ifdef NEED_SYS_FILIO_H
#include <sys/filio.h>
#endif
#ifdef NEED_SYS_IOCTL_H
#include <sys/ioctl.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int ioctl ($cl_cv_proto_ioctl_args);
#else
int ioctl();
#endif
/* Declare open(). */
#include <fcntl.h>
#ifdef OPEN_NEEDS_SYS_FILE_H
#include <sys/file.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int open ($cl_cv_proto_open_args);
#else
int open();
#endif
int main ()
{ int fd = open("conftest.c",O_RDONLY,0644);
  long x;
  exit(!((fd >= 0) && (ioctl(fd,FIONREAD,&x) >= 0) && (x > 0)));
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:11218: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11221: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:11223: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11226: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_decl_FIONREAD_reliable=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_decl_FIONREAD_reliable=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:11239: result: $cl_cv_decl_FIONREAD_reliable" >&5
echo "${ECHO_T}$cl_cv_decl_FIONREAD_reliable" >&6
case "$cl_cv_decl_FIONREAD_reliable" in
  *yes) cat >>confdefs.h <<\EOF
#define HAVE_RELIABLE_FIONREAD 1
EOF
 ;;
  *no) ;;
esac
fi

                      echo "$as_me:11250: checking for fcntl declaration" >&5
echo $ECHO_N "checking for fcntl declaration... $ECHO_C" >&6
if test "${cl_cv_proto_fcntl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in 'int arg' '...'; do
if test -z "$have_fcntl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 11259 "configure"
#include "confdefs.h"

#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <fcntl.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int fcntl (int fd, int cmd, $x);
#else
int fcntl();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11287: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11290: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11293: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11296: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

if test "$x" = "..."; then
cl_cv_fcntl_arg3="..."
else
cl_cv_fcntl_arg3="int"
fi
have_fcntl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done

cl_cv_proto_fcntl="extern int fcntl (int, int, $cl_cv_fcntl_arg3);"
fi

cl_cv_proto_fcntl=`echo "$cl_cv_proto_fcntl" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:11318: result: ${ac_t:-
         }$cl_cv_proto_fcntl" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_fcntl" >&6

if test "$cl_cv_fcntl_arg3" = "..."; then
cat >>confdefs.h <<\EOF
#define FCNTL_DOTS 1
EOF

fi

for ac_func in select
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11333: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11339 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:11370: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11373: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:11376: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11379: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:11389: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_select = yes; then
echo "$as_me:11399: checking for sys/select.h" >&5
echo $ECHO_N "checking for sys/select.h... $ECHO_C" >&6
if test "${cl_cv_header_sys_select_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11406 "configure"
#include "confdefs.h"
#ifdef __BEOS__
#include <sys/socket.h>
#endif
#include <sys/time.h>
#include <sys/select.h>
int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11422: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11425: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11428: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11431: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_header_sys_select_h=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_header_sys_select_h=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:11443: result: $cl_cv_header_sys_select_h" >&5
echo "${ECHO_T}$cl_cv_header_sys_select_h" >&6
if test $cl_cv_header_sys_select_h = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SYS_SELECT_H 1
EOF

fi
echo "$as_me:11451: checking for select declaration" >&5
echo $ECHO_N "checking for select declaration... $ECHO_C" >&6
if test "${cl_cv_proto_select+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for z in '' 'const'; do
for y in 'fd_set' 'int' 'void' 'struct fd_set'; do
for x in 'int' 'size_t'; do
if test -z "$have_select"; then
cat >conftest.$ac_ext <<_ACEOF
#line 11462 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#ifdef __BEOS__
#include <sys/socket.h>
#endif
#include <sys/time.h>
#ifdef HAVE_SYS_SELECT_H
#include <sys/select.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int select ($x width, $y * readfds, $y * writefds, $y * exceptfds, $z struct timeval * timeout);
#else
int select();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11498: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11501: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11504: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11507: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_select_arg1="$x"
cl_cv_proto_select_arg2="$y"
cl_cv_proto_select_arg5="$z"
have_select=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
done

cl_cv_proto_select="extern int select ($cl_cv_proto_select_arg1, $cl_cv_proto_select_arg2 *, $cl_cv_proto_select_arg2 *, $cl_cv_proto_select_arg2 *, $cl_cv_proto_select_arg5 struct timeval *);"
fi

cl_cv_proto_select=`echo "$cl_cv_proto_select" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:11529: result: ${ac_t:-
         }$cl_cv_proto_select" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_select" >&6

cat >>confdefs.h <<EOF
#define SELECT_WIDTH_T $cl_cv_proto_select_arg1
EOF

cat >>confdefs.h <<EOF
#define SELECT_SET_T $cl_cv_proto_select_arg2
EOF

cat >>confdefs.h <<EOF
#define SELECT_CONST $cl_cv_proto_select_arg5
EOF

else

for ac_func in poll
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11551: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11557 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:11588: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11591: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:11594: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11597: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:11607: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
fi

for ac_func in ualarm
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11621: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11627 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:11658: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11661: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:11664: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11667: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:11677: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

for ac_func in setitimer
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11690: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11696 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:11727: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11730: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:11733: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11736: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:11746: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_setitimer = yes; then
echo "$as_me:11756: checking for setitimer declaration" >&5
echo $ECHO_N "checking for setitimer declaration... $ECHO_C" >&6
if test "${cl_cv_proto_setitimer+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11763 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/time.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int setitimer (int which, struct itimerval * ivalue, struct itimerval * ovalue);
#else
int setitimer();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11792: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11795: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11798: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11801: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_setitimer_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_setitimer_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_setitimer="extern int setitimer (int, $cl_cv_proto_setitimer_arg2 struct itimerval *, struct itimerval *);"
fi

cl_cv_proto_setitimer=`echo "$cl_cv_proto_setitimer" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:11815: result: ${ac_t:-
         }$cl_cv_proto_setitimer" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_setitimer" >&6

cat >>confdefs.h <<EOF
#define SETITIMER_CONST $cl_cv_proto_setitimer_arg2
EOF

fi

for ac_func in usleep
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11829: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11835 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:11866: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:11869: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:11872: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11875: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:11885: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

                      echo "$as_me:11895: checking for localtime declaration" >&5
echo $ECHO_N "checking for localtime declaration... $ECHO_C" >&6
if test "${cl_cv_proto_localtime+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 11902 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifdef TM_IN_SYS_TIME
#include <sys/time.h>
#else
#include <time.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
struct tm * localtime (time_t* clock);
#else
struct tm * localtime();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:11935: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:11938: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:11941: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:11944: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_localtime_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_localtime_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_localtime="extern struct tm * localtime ($cl_cv_proto_localtime_arg1 time_t*);"
fi

cl_cv_proto_localtime=`echo "$cl_cv_proto_localtime" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:11958: result: ${ac_t:-
         }$cl_cv_proto_localtime" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_localtime" >&6

cat >>confdefs.h <<EOF
#define LOCALTIME_CONST $cl_cv_proto_localtime_arg1
EOF

for ac_func in gettimeofday
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:11970: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 11976 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:12007: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:12010: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:12013: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12016: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:12026: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_gettimeofday = yes; then
echo "$as_me:12036: checking for gettimeofday declaration" >&5
echo $ECHO_N "checking for gettimeofday declaration... $ECHO_C" >&6
if test "${cl_cv_proto_gettimeofday+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12043 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/time.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int gettimeofday (struct timeval * tp, struct timezone * tzp);
#else
int gettimeofday();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12069: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12072: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12075: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12078: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_gettimeofday_dots=no
cl_cv_proto_gettimeofday_arg2="struct timezone *"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cat >conftest.$ac_ext <<_ACEOF
#line 12086 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/time.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int gettimeofday (struct timeval * tp, void * tzp);
#else
int gettimeofday();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12112: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12115: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12118: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12121: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_gettimeofday_dots=no
cl_cv_proto_gettimeofday_arg2="void *"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_gettimeofday_dots=yes
cl_cv_proto_gettimeofday_arg2="..."
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_gettimeofday="extern int gettimeofday (struct timeval *, $cl_cv_proto_gettimeofday_arg2);"
fi

cl_cv_proto_gettimeofday=`echo "$cl_cv_proto_gettimeofday" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12140: result: ${ac_t:-
         }$cl_cv_proto_gettimeofday" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_gettimeofday" >&6

if test $cl_cv_proto_gettimeofday_dots = yes; then
cat >>confdefs.h <<\EOF
#define GETTIMEOFDAY_DOTS 1
EOF

else
cat >>confdefs.h <<EOF
#define GETTIMEOFDAY_TZP_T $cl_cv_proto_gettimeofday_arg2
EOF

fi
fi

for ac_func in ftime
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:12161: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12167 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:12198: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:12201: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:12204: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12207: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:12217: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

                      if test $ac_cv_func_gettimeofday = no -a $ac_cv_func_ftime = no; then
echo "$as_me:12228: checking for times" >&5
echo $ECHO_N "checking for times... $ECHO_C" >&6
if test "${ac_cv_func_times+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12234 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char times (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char times ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_times) || defined (__stub___times)
choke me
#else
f = times;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:12265: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:12268: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:12271: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12274: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_times=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_times=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:12284: result: $ac_cv_func_times" >&5
echo "${ECHO_T}$ac_cv_func_times" >&6
if test $ac_cv_func_times = yes; then
  :
else
  no_times=1
fi
if test -z "$no_times"; then
echo "$as_me:12292: checking for times return value" >&5
echo $ECHO_N "checking for times return value... $ECHO_C" >&6
if test "${cl_cv_func_times_return+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_times_return="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12302 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <time.h> /* needed for CLK_TCK */
#ifndef CLK_TCK
#include <sys/time.h> /* needed for CLK_TCK on SYSV PTX */
#endif
#include <sys/times.h>
int main ()
{ struct tms buffer;
  clock_t result1;
  clock_t result2;
  int ticks;
  result1 = times(&buffer);
  if ((result1 == (clock_t)0) || (result1 == (clock_t)(-1))) exit(1);
  sleep(1);
  result2 = times(&buffer);
  if ((result2 == (clock_t)0) || (result2 == (clock_t)(-1))) exit(1);
  ticks = result2 - result1;
  exit(!((ticks >= CLK_TCK/2) && (ticks <= 3*CLK_TCK/2)));
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:12326: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:12329: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:12331: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12334: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_times_return=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_times_return=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:12347: result: $cl_cv_func_times_return" >&5
echo "${ECHO_T}$cl_cv_func_times_return" >&6
case "$cl_cv_func_times_return" in
  *yes) cat >>confdefs.h <<\EOF
#define HAVE_TIMES_CLOCK 1
EOF
 ;;
  *no)  ;;
esac
fi
fi

                      echo "$as_me:12359: checking for getpwnam declaration" >&5
echo $ECHO_N "checking for getpwnam declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getpwnam+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12366 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <pwd.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
struct passwd * getpwnam (char* name);
#else
struct passwd * getpwnam();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12395: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12398: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12401: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12404: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getpwnam_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getpwnam_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getpwnam="extern struct passwd * getpwnam ($cl_cv_proto_getpwnam_arg1 char*);"
fi

cl_cv_proto_getpwnam=`echo "$cl_cv_proto_getpwnam" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12418: result: ${ac_t:-
         }$cl_cv_proto_getpwnam" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getpwnam" >&6

cat >>confdefs.h <<EOF
#define GETPWNAM_CONST $cl_cv_proto_getpwnam_arg1
EOF

                      echo "$as_me:12427: checking for getpwuid declaration" >&5
echo $ECHO_N "checking for getpwuid declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getpwuid+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12434 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <pwd.h>
#include <sys/types.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
struct passwd * getpwuid (uid_t uid);
#else
struct passwd * getpwuid();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12464: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12467: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12470: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12473: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getpwuid_arg1="uid_t"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getpwuid_arg1="int"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getpwuid="extern struct passwd * getpwuid ($cl_cv_proto_getpwuid_arg1);"
fi

cl_cv_proto_getpwuid=`echo "$cl_cv_proto_getpwuid" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12487: result: ${ac_t:-
         }$cl_cv_proto_getpwuid" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getpwuid" >&6

cat >>confdefs.h <<EOF
#define GETPWUID_UID_T $cl_cv_proto_getpwuid_arg1
EOF

for ac_func in gethostname
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:12499: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12505 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:12536: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:12539: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:12542: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12545: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:12555: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_gethostname = yes; then
echo "$as_me:12565: checking for gethostname declaration" >&5
echo $ECHO_N "checking for gethostname declaration... $ECHO_C" >&6
if test "${cl_cv_proto_gethostname+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in 'int' 'size_t' 'unsigned int'; do
if test -z "$have_gethostname"; then
cat >conftest.$ac_ext <<_ACEOF
#line 12574 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifdef __BEOS__
#include <sys/socket.h>
#include <netdb.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int gethostname (char* name, $x namelen);
#else
int gethostname();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12605: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12608: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12611: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12614: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_gethostname_arg2="$x"
have_gethostname=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext
fi
done

cl_cv_proto_gethostname="extern int gethostname (char*, $cl_cv_proto_gethostname_arg2);"
fi

cl_cv_proto_gethostname=`echo "$cl_cv_proto_gethostname" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12630: result: ${ac_t:-
         }$cl_cv_proto_gethostname" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_gethostname" >&6

cat >>confdefs.h <<EOF
#define GETHOSTNAME_SIZE_T $cl_cv_proto_gethostname_arg2
EOF

fi

                      if test $ac_cv_header_netdb_h = yes; then
  have_netdb=1
else
  echo "$as_me:12644: checking for sun/netdb.h" >&5
echo $ECHO_N "checking for sun/netdb.h... $ECHO_C" >&6
if test "${ac_cv_header_sun_netdb_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12650 "configure"
#include "confdefs.h"
#include <sun/netdb.h>
_ACEOF
if { (eval echo "$as_me:12654: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:12660: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  ac_cv_header_sun_netdb_h=yes
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  ac_cv_header_sun_netdb_h=no
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:12679: result: $ac_cv_header_sun_netdb_h" >&5
echo "${ECHO_T}$ac_cv_header_sun_netdb_h" >&6
if test $ac_cv_header_sun_netdb_h = yes; then
  have_netdb=1
fi

fi
if test -n "$have_netdb"; then
cat >>confdefs.h <<\EOF
#define HAVE_GETHOSTBYNAME 1
EOF

echo "$as_me:12691: checking for gethostbyname declaration" >&5
echo $ECHO_N "checking for gethostbyname declaration... $ECHO_C" >&6
if test "${cl_cv_proto_gethostbyname+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12698 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#ifdef HAVE_NETDB_H
#include <sys/socket.h>
#include <netdb.h>
#else
#include <sun/netdb.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
struct hostent * gethostbyname (char* name);
#else
struct hostent * gethostbyname();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12733: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12736: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12739: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12742: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_gethostbyname_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_gethostbyname_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_gethostbyname="extern struct hostent * gethostbyname ($cl_cv_proto_gethostbyname_arg1 char*);"
fi

cl_cv_proto_gethostbyname=`echo "$cl_cv_proto_gethostbyname" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12756: result: ${ac_t:-
         }$cl_cv_proto_gethostbyname" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_gethostbyname" >&6

cat >>confdefs.h <<EOF
#define GETHOSTBYNAME_CONST $cl_cv_proto_gethostbyname_arg1
EOF

fi

                      echo "$as_me:12767: checking for connect declaration" >&5
echo $ECHO_N "checking for connect declaration... $ECHO_C" >&6
if test "${cl_cv_proto_connect+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in '' 'const'; do
for y in 'struct sockaddr *' 'void*'; do
for z in 'int' 'size_t' 'socklen_t'; do
if test -z "$have_connect_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 12778 "configure"
#include "confdefs.h"

#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/socket.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int connect (int fd, $x $y name, $z namelen);
#else
int connect();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12807: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12810: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12813: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12816: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_connect_arg2a="$x"
cl_cv_proto_connect_arg2b="$y"
cl_cv_proto_connect_arg3="$z"
have_connect_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
done

cl_cv_proto_connect="extern int connect (int, $cl_cv_proto_connect_arg2a $cl_cv_proto_connect_arg2b, $cl_cv_proto_connect_arg3);"
fi

cl_cv_proto_connect=`echo "$cl_cv_proto_connect" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:12838: result: ${ac_t:-
         }$cl_cv_proto_connect" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_connect" >&6

cat >>confdefs.h <<EOF
#define CONNECT_CONST $cl_cv_proto_connect_arg2a
EOF

cat >>confdefs.h <<EOF
#define CONNECT_NAME_T $cl_cv_proto_connect_arg2b
EOF

cat >>confdefs.h <<EOF
#define CONNECT_ADDRLEN_T $cl_cv_proto_connect_arg3
EOF

for ac_header in sys/un.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:12858: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 12864 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:12868: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:12874: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:12893: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_header_sys_un_h = yes; then
echo "$as_me:12903: checking for sun_len in struct sockaddr_un" >&5
echo $ECHO_N "checking for sun_len in struct sockaddr_un... $ECHO_C" >&6
if test "${cl_cv_struct_sockaddr_sun_len+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12910 "configure"
#include "confdefs.h"
#include <sys/types.h> /* NetBSD 1.0 needs this */
#include <sys/un.h>
int
main ()
{
struct sockaddr_un unaddr; unaddr.sun_len;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12923: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12926: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12929: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12932: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_struct_sockaddr_sun_len=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_struct_sockaddr_sun_len=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:12944: result: $cl_cv_struct_sockaddr_sun_len" >&5
echo "${ECHO_T}$cl_cv_struct_sockaddr_sun_len" >&6
if test $cl_cv_struct_sockaddr_sun_len = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_SOCKADDR_UN_LEN 1
EOF

fi
fi

                      echo "$as_me:12954: checking for IPv4 sockets" >&5
echo $ECHO_N "checking for IPv4 sockets... $ECHO_C" >&6
if test "${cl_cv_socket_ipv4+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 12961 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
int
main ()
{
int x = AF_INET; struct in_addr y; struct sockaddr_in z;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:12975: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:12978: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:12981: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:12984: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_socket_ipv4=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_socket_ipv4=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:12996: result: $cl_cv_socket_ipv4" >&5
echo "${ECHO_T}$cl_cv_socket_ipv4" >&6
if test $cl_cv_socket_ipv4 = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_IPV4 1
EOF

fi

echo "$as_me:13005: checking for IPv6 sockets" >&5
echo $ECHO_N "checking for IPv6 sockets... $ECHO_C" >&6
if test "${cl_cv_socket_ipv6+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13012 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
int
main ()
{
int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:13026: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:13029: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:13032: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13035: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_socket_ipv6=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_socket_ipv6=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:13047: result: $cl_cv_socket_ipv6" >&5
echo "${ECHO_T}$cl_cv_socket_ipv6" >&6
if test $cl_cv_socket_ipv6 = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_IPV6 1
EOF

fi

if test $cl_cv_socket_ipv6 = no; then
echo "$as_me:13057: checking for IPv6 sockets in linux/in6.h" >&5
echo $ECHO_N "checking for IPv6 sockets in linux/in6.h... $ECHO_C" >&6
if test "${cl_cv_socket_ipv6_linux+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13064 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <linux/in6.h>
int
main ()
{
int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:13079: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:13082: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:13085: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13088: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_socket_ipv6_linux=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_socket_ipv6_linux=no
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi

echo "$as_me:13100: result: $cl_cv_socket_ipv6_linux" >&5
echo "${ECHO_T}$cl_cv_socket_ipv6_linux" >&6
if test $cl_cv_socket_ipv6_linux = yes; then
  cat >>confdefs.h <<\EOF
#define IPV6_NEED_LINUX_IN6_H 1
EOF

cat >>confdefs.h <<\EOF
#define HAVE_IPV6 1
EOF

fi

fi

for ac_func in inet_pton inet_ntop
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:13118: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13124 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:13155: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13158: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:13161: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13164: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:13174: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

for ac_header in netinet/in.h arpa/inet.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:13187: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13193 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:13197: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:13203: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:13222: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done
echo "$as_me:13231: checking for inet_addr declaration" >&5
echo $ECHO_N "checking for inet_addr declaration... $ECHO_C" >&6
if test "${cl_cv_proto_inet_addr+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in '' 'const'; do
for y in 'struct in_addr' 'unsigned long' 'unsigned int'; do
if test -z "$have_inet_addr"; then
cat >conftest.$ac_ext <<_ACEOF
#line 13241 "configure"
#include "confdefs.h"

#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <netinet/in.h>
#ifdef HAVE_ARPA_INET_H
#include <arpa/inet.h>
#endif
#ifdef __BEOS__
#include <sys/socket.h>
#include <netdb.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$y inet_addr ($x char *);
#else
$y inet_addr();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:13277: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:13280: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:13283: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13286: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_inet_addr_ret="$y"
cl_cv_proto_inet_addr_arg1="$x"
have_inet_addr=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done

cl_cv_proto_inet_addr="extern $cl_cv_proto_inet_addr_ret inet_addr ($cl_cv_proto_inet_addr_arg1 char*);"
fi

cl_cv_proto_inet_addr=`echo "$cl_cv_proto_inet_addr" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:13306: result: ${ac_t:-
         }$cl_cv_proto_inet_addr" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_inet_addr" >&6

cat >>confdefs.h <<EOF
#define RET_INET_ADDR_TYPE $cl_cv_proto_inet_addr_ret
EOF

cat >>confdefs.h <<EOF
#define INET_ADDR_CONST $cl_cv_proto_inet_addr_arg1
EOF

if test "$cl_cv_proto_inet_addr_ret" = "struct in_addr"; then
cat >>confdefs.h <<\EOF
#define INET_ADDR_SUFFIX .s_addr
EOF

else
cat >>confdefs.h <<\EOF
#define INET_ADDR_SUFFIX
EOF

fi

for ac_header in netinet/tcp.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:13334: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13340 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:13344: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:13350: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:13369: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done
echo "$as_me:13378: checking for setsockopt declaration" >&5
echo $ECHO_N "checking for setsockopt declaration... $ECHO_C" >&6
if test "${cl_cv_proto_setsockopt+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for z in 'int' 'unsigned int' 'size_t'; do
for y in 'char*' 'void*'; do
for x in '' 'const'; do
if test -z "$have_setsockopt_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 13389 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/socket.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int setsockopt (int, int, int, $x $y, $z);
#else
int setsockopt ();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:13415: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:13418: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:13421: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13424: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_setsockopt_const="$x"
cl_cv_proto_setsockopt_arg_t="$y"
cl_cv_proto_setsockopt_optlen_t="$z"
have_setsockopt_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
done

cl_cv_proto_setsockopt="extern int setsockopt (int, int, int, $cl_cv_proto_setsockopt_const $cl_cv_proto_setsockopt_arg_t, $cl_cv_proto_setsockopt_optlen_t);"
fi

cl_cv_proto_setsockopt=`echo "$cl_cv_proto_setsockopt" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:13446: result: ${ac_t:-
         }$cl_cv_proto_setsockopt" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_setsockopt" >&6

cat >>confdefs.h <<EOF
#define SETSOCKOPT_CONST $cl_cv_proto_setsockopt_const
EOF

cat >>confdefs.h <<EOF
#define SETSOCKOPT_ARG_T $cl_cv_proto_setsockopt_arg_t
EOF

cat >>confdefs.h <<EOF
#define SETSOCKOPT_OPTLEN_T $cl_cv_proto_setsockopt_optlen_t
EOF

                      address_range_prog='
#include <stdio.h>
#ifdef __cplusplus
extern "C" void exit(int);
#endif
#if defined(__STDC__) || defined(__cplusplus)
void printf_address (unsigned long addr)
#else
printf_address (addr)
  unsigned long addr;
#endif
{ if (sizeof(unsigned long) <= 4)
    printf ("0x%08X", (unsigned int)addr);
  else
    printf ("0x%08X%08X",(unsigned int)(addr>>32),(unsigned int)(addr&0xFFFFFFFF));
}
#define chop_address(addr) ((unsigned long)(char*)(addr) & ~0x00FFFFFFL)
'
if test $cl_cv_prog_cc_ansi = yes; then
  ul='UL'
else
  ul=''
fi
echo "$as_me:13486: checking for the code address range" >&5
echo $ECHO_N "checking for the code address range... $ECHO_C" >&6
if test "${cl_cv_address_code+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
cat > conftest.c <<EOF
#include "confdefs.h"
$address_range_prog
int main() { printf_address(chop_address(&printf_address)); exit(0); }
EOF
{ (eval echo "$as_me:13498: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13501: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_address_code=`./conftest`
rm -f conftest*
else
cl_cv_address_code='guessing 0'
fi

fi
echo "$as_me:13510: result: $cl_cv_address_code" >&5
echo "${ECHO_T}$cl_cv_address_code" >&6
x=`echo $cl_cv_address_code | sed -e 's,^guessing ,,'`"$ul"
cat >>confdefs.h <<EOF
#define CODE_ADDRESS_RANGE $x
EOF

echo "$as_me:13517: checking for the malloc address range" >&5
echo $ECHO_N "checking for the malloc address range... $ECHO_C" >&6
if test "${cl_cv_address_malloc+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
cat > conftest.c <<EOF
#include "confdefs.h"
#include <sys/types.h>
/* declare malloc() */
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifndef malloc
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETMALLOCTYPE malloc (MALLOC_SIZE_T size);
#else
RETMALLOCTYPE malloc();
#endif
#endif
$address_range_prog
int main() { printf_address(chop_address(malloc(10000))); exit(0); }
EOF
{ (eval echo "$as_me:13547: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13550: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_address_malloc=`./conftest`
rm -f conftest*
else
cl_cv_address_malloc='guessing 0'
fi

fi
echo "$as_me:13559: result: $cl_cv_address_malloc" >&5
echo "${ECHO_T}$cl_cv_address_malloc" >&6
x=`echo $cl_cv_address_malloc | sed -e 's,^guessing ,,'`"$ul"
cat >>confdefs.h <<EOF
#define MALLOC_ADDRESS_RANGE $x
EOF

echo "$as_me:13566: checking for the shared library address range" >&5
echo $ECHO_N "checking for the shared library address range... $ECHO_C" >&6
if test "${cl_cv_address_shlib+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
cat > conftest.c <<EOF
#include "confdefs.h"
$address_range_prog
/* Declare printf(). */
#if defined(sun) /* for SunOS 4, but not for IRIX 6 */
#ifdef __cplusplus
extern "C" int printf (const char *, ...);
#else
extern int printf ();
#endif
#endif
/* Declare tmpnam(). */
#ifdef __cplusplus
extern "C" char* tmpnam (char*);
#else
extern char* tmpnam ();
#endif
/* With normal simple DLLs, &printf is in the shared library. Fine.
   But with ELF, &printf is a trampoline function allocated near the
   program's code range. errno and other global variables - such as
   &stdout - are allocated near the program's code and bss as well.
   However, the return value of tmpnam(NULL) is a pointer to a static
   buffer in the shared library. (This buffer is unlikely to be named
   by a global symbol.) */
int main() {
  char* addr;
  addr = (char*) tmpnam((char*)0);
  if (!addr) addr = (char*) &printf;
  printf_address(chop_address(addr));
  exit(0);
}
EOF
{ (eval echo "$as_me:13605: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13608: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_address_shlib=`./conftest`
rm -f conftest*
else
cl_cv_address_shlib='guessing 0'
fi

fi
echo "$as_me:13617: result: $cl_cv_address_shlib" >&5
echo "${ECHO_T}$cl_cv_address_shlib" >&6
x=`echo $cl_cv_address_shlib | sed -e 's,^guessing ,,'`"$ul"
cat >>confdefs.h <<EOF
#define SHLIB_ADDRESS_RANGE $x
EOF

echo "$as_me:13624: checking for the stack address range" >&5
echo $ECHO_N "checking for the stack address range... $ECHO_C" >&6
if test "${cl_cv_address_stack+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
cat > conftest.c <<EOF
#include "confdefs.h"
$address_range_prog
int main() { int dummy; printf_address(chop_address(&dummy)); exit(0); }
EOF
{ (eval echo "$as_me:13636: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13639: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_address_stack=`./conftest`
rm -f conftest*
else
cl_cv_address_stack='guessing ~0'
fi

fi
echo "$as_me:13648: result: $cl_cv_address_stack" >&5
echo "${ECHO_T}$cl_cv_address_stack" >&6
x=`echo "$cl_cv_address_stack" | sed -e 's,^guessing ,,'`"$ul"
cat >>confdefs.h <<EOF
#define STACK_ADDRESS_RANGE $x
EOF

echo "$as_me:13655: checking for getpagesize" >&5
echo $ECHO_N "checking for getpagesize... $ECHO_C" >&6
if test "${cl_cv_func_getpagesize+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13662 "configure"
#include "confdefs.h"

#ifdef HAVE_UNISTD_H
#include <sys/types.h>
#include <unistd.h>
#endif

int
main ()
{
getpagesize();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:13679: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13682: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:13685: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13688: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_getpagesize=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_getpagesize=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:13700: result: $cl_cv_func_getpagesize" >&5
echo "${ECHO_T}$cl_cv_func_getpagesize" >&6
if test $cl_cv_func_getpagesize = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_GETPAGESIZE 1
EOF

have_getpagesize=1
fi
if test -n "$have_getpagesize"; then
echo "$as_me:13710: checking for getpagesize declaration" >&5
echo $ECHO_N "checking for getpagesize declaration... $ECHO_C" >&6
if test "${cl_cv_proto_getpagesize+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13717 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif

extern
#ifdef __cplusplus
"C"
#endif
int getpagesize();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:13740: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:13743: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:13746: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13749: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_getpagesize_ret="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_getpagesize_ret="size_t"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_getpagesize="extern $cl_cv_proto_getpagesize_ret getpagesize (void);"
fi

cl_cv_proto_getpagesize=`echo "$cl_cv_proto_getpagesize" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:13763: result: ${ac_t:-
         }$cl_cv_proto_getpagesize" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_getpagesize" >&6

cat >>confdefs.h <<EOF
#define RETGETPAGESIZETYPE $cl_cv_proto_getpagesize_ret
EOF

else

for ac_header in sys/param.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:13777: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13783 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:13787: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:13793: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:13812: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

fi

                      echo "$as_me:13824: checking for vadvise" >&5
echo $ECHO_N "checking for vadvise... $ECHO_C" >&6
if test "${cl_cv_func_vadvise+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13831 "configure"
#include "confdefs.h"
#include <sys/vadvise.h>
int
main ()
{
vadvise(0);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:13843: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13846: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:13849: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13852: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_vadvise=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_vadvise=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:13864: result: $cl_cv_func_vadvise" >&5
echo "${ECHO_T}$cl_cv_func_vadvise" >&6
if test $cl_cv_func_vadvise = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_VADVISE 1
EOF

fi

                      echo "$as_me:13873: checking for vm_allocate" >&5
echo $ECHO_N "checking for vm_allocate... $ECHO_C" >&6
if test "${cl_cv_func_vm+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 13880 "configure"
#include "confdefs.h"

int
main ()
{
vm_allocate(); task_self();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:13892: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:13895: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:13898: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:13901: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_vm=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_vm=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext

fi

echo "$as_me:13913: result: $cl_cv_func_vm" >&5
echo "${ECHO_T}$cl_cv_func_vm" >&6
if test $cl_cv_func_vm = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_MACH_VM 1
EOF

fi

echo "$as_me:13922: checking for sys/mman.h" >&5
echo $ECHO_N "checking for sys/mman.h... $ECHO_C" >&6
if test "${ac_cv_header_sys_mman_h+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13928 "configure"
#include "confdefs.h"
#include <sys/mman.h>
_ACEOF
if { (eval echo "$as_me:13932: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:13938: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  ac_cv_header_sys_mman_h=yes
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  ac_cv_header_sys_mman_h=no
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:13957: result: $ac_cv_header_sys_mman_h" >&5
echo "${ECHO_T}$ac_cv_header_sys_mman_h" >&6
if test $ac_cv_header_sys_mman_h = yes; then
  :
else
  no_mmap=1
fi
if test -z "$no_mmap"; then
echo "$as_me:13965: checking for mmap" >&5
echo $ECHO_N "checking for mmap... $ECHO_C" >&6
if test "${ac_cv_func_mmap+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 13971 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char mmap (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char mmap ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_mmap) || defined (__stub___mmap)
choke me
#else
f = mmap;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:14002: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14005: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:14008: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14011: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_func_mmap=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_func_mmap=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:14021: result: $ac_cv_func_mmap" >&5
echo "${ECHO_T}$ac_cv_func_mmap" >&6
if test $ac_cv_func_mmap = yes; then
  :
else
  no_mmap=1
fi
if test -z "$no_mmap"; then
cat >>confdefs.h <<\EOF
#define HAVE_MMAP 1
EOF

echo "$as_me:14033: checking for mmap declaration" >&5
echo $ECHO_N "checking for mmap declaration... $ECHO_C" >&6
if test "${cl_cv_proto_mmap+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for z in 'int' 'size_t'; do
for y in 'void*' 'caddr_t'; do
for x in 'void*' 'caddr_t'; do
if test -z "$have_mmap_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 14044 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/mman.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$x mmap ($y addr, $z length, int prot, int flags, int fd, off_t off);
#else
$x mmap();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:14074: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:14077: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:14080: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14083: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_mmap_ret="$x"
cl_cv_proto_mmap_arg1="$y"
cl_cv_proto_mmap_arg2="$z"
have_mmap_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done
done
done

cl_cv_proto_mmap="extern $cl_cv_proto_mmap_ret mmap ($cl_cv_proto_mmap_arg1, $cl_cv_proto_mmap_arg2, int, int, int, off_t);"
fi

cl_cv_proto_mmap=`echo "$cl_cv_proto_mmap" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:14105: result: ${ac_t:-
         }$cl_cv_proto_mmap" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_mmap" >&6

cat >>confdefs.h <<EOF
#define RETMMAPTYPE $cl_cv_proto_mmap_ret
EOF

cat >>confdefs.h <<EOF
#define MMAP_ADDR_T $cl_cv_proto_mmap_arg1
EOF

cat >>confdefs.h <<EOF
#define MMAP_SIZE_T $cl_cv_proto_mmap_arg2
EOF

echo "$as_me:14122: checking for working mmap" >&5
echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
if test "${cl_cv_func_mmap_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

case "$host" in
  i345686-*-sysv4*)
    # UNIX_SYSV_UHC_1
    avoid=0x08000000 ;;
  mips-sgi-irix* | mips-dec-ultrix*)
    # UNIX_IRIX, UNIX_DEC_ULTRIX
    avoid=0x10000000 ;;
  rs6000-ibm-aix*)
    # UNIX_AIX
    avoid=0x20000000 ;;
  *)
    avoid=0 ;;
esac
mmap_prog_1='
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <fcntl.h>
#ifdef OPEN_NEEDS_SYS_FILE_H
#include <sys/file.h>
#endif
#include <sys/types.h>
#include <sys/mman.h>
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETMMAPTYPE mmap (MMAP_ADDR_T addr, MMAP_SIZE_T length, int prot, int flags, int fd, off_t off);
#else
RETMMAPTYPE mmap();
#endif
int main () {
'
mmap_prog_2="#define bits_to_avoid $avoid"'
#define my_shift 24
#define my_low   1
#ifdef FOR_SUN4_29
#define my_high  31
#define my_size  32768 /* hope that 32768 is a multiple of the page size */
/* i*32 KB for i=1..31 gives a total of 15.5 MB, which is close to what we need */
#else
#define my_high  64
#define my_size  8192 /* hope that 8192 is a multiple of the page size */
/* i*8 KB for i=1..64 gives a total of 16.25 MB, which is close to what we need */
#endif
 {long i;
#define i_ok(i)  ((i) & (bits_to_avoid >> my_shift) == 0)
  for (i=my_low; i<=my_high; i++)
    if (i_ok(i))
      { caddr_t addr = (caddr_t)(i << my_shift);
/* Check for 8 MB, not 16 MB. This is more likely to work on Solaris 2. */
#if bits_to_avoid
        long size = i*my_size;
#else
        long size = ((i+1)/2)*my_size;
#endif
        if (mmap(addr,size,PROT_READ|PROT_WRITE,flags|MAP_FIXED,fd,0) == (RETMMAPTYPE)-1) exit(1);
    }
#define x(i)  *(unsigned char *) ((i<<my_shift) + (i*i))
#define y(i)  (unsigned char)((3*i-4)*(7*i+3))
  for (i=my_low; i<=my_high; i++) if (i_ok(i)) { x(i) = y(i); }
  for (i=my_high; i>=my_low; i--) if (i_ok(i)) { if (x(i) != y(i)) exit(1); }
  exit(0);
}}
'
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14201 "configure"
#include "confdefs.h"
$mmap_prog_1
  int flags = MAP_ANON | MAP_PRIVATE;
  int fd = -1;
$mmap_prog_2

_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14210: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14213: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14215: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14218: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_mmap_anon=1
cl_cv_func_mmap_anon=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14235 "configure"
#include "confdefs.h"
$mmap_prog_1
  int flags = MAP_ANONYMOUS | MAP_PRIVATE;
  int fd = -1;
$mmap_prog_2

_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14244: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14247: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14249: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14252: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_mmap_anon=1
cl_cv_func_mmap_anonymous=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14269 "configure"
#include "confdefs.h"
$mmap_prog_1
#ifndef MAP_FILE
#define MAP_FILE 0
#endif
  int flags = MAP_FILE | MAP_PRIVATE;
  int fd = open("/dev/zero",O_RDONLY,0666);
  if (fd<0) exit(1);
$mmap_prog_2

_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14282: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14285: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14287: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14290: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_mmap_devzero=1
cl_cv_func_mmap_devzero=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
retry_mmap=1
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
if test -n "$retry_mmap"; then
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14309 "configure"
#include "confdefs.h"
#define FOR_SUN4_29
$mmap_prog_1
#ifndef MAP_FILE
#define MAP_FILE 0
#endif
  int flags = MAP_FILE | MAP_PRIVATE;
  int fd = open("/dev/zero",O_RDONLY,0666);
  if (fd<0) exit(1);
$mmap_prog_2

_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14323: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14326: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14328: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14331: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  have_mmap_devzero=1
cl_cv_func_mmap_devzero_sun4_29=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
if test -n "$have_mmap_anon" -o -n "$have_mmap_devzero"; then
cl_cv_func_mmap_works=yes
else
cl_cv_func_mmap_works=no
fi

fi
echo "$as_me:14351: result: $cl_cv_func_mmap_works" >&5
echo "${ECHO_T}$cl_cv_func_mmap_works" >&6
if test "$cl_cv_func_mmap_anon" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_MMAP_ANON 1
EOF

fi
if test "$cl_cv_func_mmap_anonymous" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_MMAP_ANONYMOUS 1
EOF

fi
if test "$cl_cv_func_mmap_devzero" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_MMAP_DEVZERO 1
EOF

fi
if test "$cl_cv_func_mmap_devzero_sun4_29" = yes; then
cat >>confdefs.h <<\EOF
#define HAVE_MMAP_DEVZERO_SUN4_29 1
EOF

fi
fi
fi

                      if test -z "$no_mmap"; then

for ac_func in munmap
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:14385: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 14391 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:14422: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14425: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:14428: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14431: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:14441: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
fi

                      if test -z "$no_mmap"; then

for ac_func in msync
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:14457: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 14463 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:14494: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14497: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:14500: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14503: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:14513: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
fi

for ac_func in mprotect
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:14527: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 14533 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:14564: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14567: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:14570: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14573: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:14583: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done
if test $ac_cv_func_mprotect = yes; then
echo "$as_me:14593: checking for mprotect declaration" >&5
echo $ECHO_N "checking for mprotect declaration... $ECHO_C" >&6
if test "${cl_cv_proto_mprotect+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 14600 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/mman.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int mprotect (MMAP_ADDR_T addr, MMAP_SIZE_T len, int prot);
#else
int mprotect();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:14630: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:14633: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:14636: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14639: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_mprotect_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_mprotect_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_mprotect="extern int mprotect ($cl_cv_proto_mprotect_arg1 $cl_cv_proto_mmap_arg1, $cl_cv_proto_mmap_arg2, int);"
fi

cl_cv_proto_mprotect=`echo "$cl_cv_proto_mprotect" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:14653: result: ${ac_t:-
         }$cl_cv_proto_mprotect" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_mprotect" >&6

cat >>confdefs.h <<EOF
#define MPROTECT_CONST $cl_cv_proto_mprotect_arg1
EOF

echo "$as_me:14662: checking for working mprotect" >&5
echo $ECHO_N "checking for working mprotect... $ECHO_C" >&6
if test "${cl_cv_func_mprotect_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

mprotect_prog='
#include <sys/types.h>
/* declare malloc() */
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#ifndef malloc
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETMALLOCTYPE malloc (MALLOC_SIZE_T size);
#else
RETMALLOCTYPE malloc();
#endif
#endif
/* declare getpagesize() and mprotect() */
#include <sys/mman.h>
#ifndef HAVE_GETPAGESIZE
#include <sys/param.h>
#define getpagesize() PAGESIZE
#else
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETGETPAGESIZETYPE getpagesize (void);
#else
RETGETPAGESIZETYPE getpagesize();
#endif
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int mprotect (MPROTECT_CONST MMAP_ADDR_T addr, MMAP_SIZE_T len, int prot);
#else
int mprotect();
#endif
char foo;
int main () {
  unsigned long pagesize = getpagesize();
#define page_align(address)  (char*)((unsigned long)(address) & -pagesize)
'
if test "$cross_compiling" = yes; then
  # When cross-compiling, don't assume anything.
no_mprotect=1
else
  cat >conftest.$ac_ext <<_ACEOF
#line 14724 "configure"
#include "confdefs.h"
$mprotect_prog
  if ((pagesize-1) & pagesize) exit(1);
  exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14731: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14734: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14736: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14739: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  :
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
no_mprotect=1
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
mprotect_prog="$mprotect_prog"'
  char* area = (char*) malloc(6*pagesize);
  char* fault_address = area + pagesize*7/2;
'
if test -z "$no_mprotect"; then
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14760 "configure"
#include "confdefs.h"
$mprotect_prog
  if (mprotect(page_align(fault_address),pagesize,PROT_NONE) < 0) exit(0);
  foo = *fault_address; /* this should cause a core dump */
  exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14768: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14771: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14773: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14776: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  no_mprotect=1
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
if test -z "$no_mprotect"; then
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14794 "configure"
#include "confdefs.h"
$mprotect_prog
  if (mprotect(page_align(fault_address),pagesize,PROT_NONE) < 0) exit(0);
  *fault_address = 'z'; /* this should cause a core dump */
  exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14802: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14805: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14807: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14810: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  no_mprotect=1
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
if test -z "$no_mprotect"; then
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14828 "configure"
#include "confdefs.h"
$mprotect_prog
  if (mprotect(page_align(fault_address),pagesize,PROT_READ) < 0) exit(0);
  *fault_address = 'z'; /* this should cause a core dump */
  exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14836: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14839: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14841: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14844: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  no_mprotect=1
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
if test -z "$no_mprotect"; then
if test "$cross_compiling" = yes; then
  : # When cross-compiling, don't assume anything.

else
  cat >conftest.$ac_ext <<_ACEOF
#line 14862 "configure"
#include "confdefs.h"
$mprotect_prog
  if (mprotect(page_align(fault_address),pagesize,PROT_READ) < 0) exit(1);
  if (mprotect(page_align(fault_address),pagesize,PROT_READ|PROT_WRITE) < 0) exit(1);
  *fault_address = 'z'; /* this should not cause a core dump */
  exit(0); }
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:14871: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:14874: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:14876: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14879: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  :
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
no_mprotect=1
rm -f core
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
if test -z "$no_mprotect"; then
  cl_cv_func_mprotect_works=yes
else
  cl_cv_func_mprotect_works=no
fi

fi
echo "$as_me:14899: result: $cl_cv_func_mprotect_works" >&5
echo "${ECHO_T}$cl_cv_func_mprotect_works" >&6
if test $cl_cv_func_mprotect_works = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_WORKING_MPROTECT 1
EOF

fi
fi

                      if test "$ac_cv_header_sys_shm_h" = yes -a "$ac_cv_header_sys_ipc_h" = yes; then
echo "$as_me:14910: checking for shmget declaration" >&5
echo $ECHO_N "checking for shmget declaration... $ECHO_C" >&6
if test "${cl_cv_proto_shmget+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 14917 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmget (key_t key, int size, int shmflg);
#else
int shmget();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:14948: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:14951: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:14954: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:14957: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_shmget_arg2="int"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_shmget_arg2="size_t"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_shmget="extern int shmget (key_t, $cl_cv_proto_shmget_arg2, int);"
fi

cl_cv_proto_shmget=`echo "$cl_cv_proto_shmget" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:14971: result: ${ac_t:-
         }$cl_cv_proto_shmget" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_shmget" >&6

cat >>confdefs.h <<EOF
#define SHMGET_SIZE_T $cl_cv_proto_shmget_arg2
EOF

fi

                      if test "$ac_cv_header_sys_shm_h" = yes -a "$ac_cv_header_sys_ipc_h" = yes; then
echo "$as_me:14983: checking for shmat declaration" >&5
echo $ECHO_N "checking for shmat declaration... $ECHO_C" >&6
if test "${cl_cv_proto_shmat+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 14990 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>

extern
#ifdef __cplusplus
"C"
#endif
void* shmat();

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15016: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15019: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15022: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15025: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_shmat_ret="void*"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_shmat_ret="char*"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cat >conftest.$ac_ext <<_ACEOF
#line 15036 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$cl_cv_proto_shmat_ret shmat (int shmid, $cl_cv_proto_shmat_ret shmaddr, int shmflg);
#else
$cl_cv_proto_shmat_ret shmat();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15067: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15070: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15073: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15076: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_shmat_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_shmat_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_shmat="extern $cl_cv_proto_shmat_ret shmat (int, $cl_cv_proto_shmat_arg2 $cl_cv_proto_shmat_ret, int);"
fi

cl_cv_proto_shmat=`echo "$cl_cv_proto_shmat" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15090: result: ${ac_t:-
         }$cl_cv_proto_shmat" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_shmat" >&6

cat >>confdefs.h <<EOF
#define RETSHMATTYPE $cl_cv_proto_shmat_ret
EOF

cat >>confdefs.h <<EOF
#define SHMAT_CONST $cl_cv_proto_shmat_arg2
EOF

fi

                      if test "$ac_cv_header_sys_shm_h" = yes -a "$ac_cv_header_sys_ipc_h" = yes; then
echo "$as_me:15106: checking for shmdt declaration" >&5
echo $ECHO_N "checking for shmdt declaration... $ECHO_C" >&6
if test "${cl_cv_proto_shmdt+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

for x in 'void*' 'char*' 'const void *' 'const char *'; do
if test -z "$have_shmdt_decl"; then
cat >conftest.$ac_ext <<_ACEOF
#line 15115 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmdt($x addr);
#else
int shmdt();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15146: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15149: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15152: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15155: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_shmdt_arg1="$x"
have_shmdt_decl=1
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest.$ac_ext

fi
done

cl_cv_proto_shmdt="extern int shmdt ($cl_cv_proto_shmdt_arg1);"
fi

cl_cv_proto_shmdt=`echo "$cl_cv_proto_shmdt" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15173: result: ${ac_t:-
         }$cl_cv_proto_shmdt" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_shmdt" >&6

cat >>confdefs.h <<EOF
#define SHMDT_ADDR_T $cl_cv_proto_shmdt_arg1
EOF

fi

                      if test "$ac_cv_header_sys_shm_h" = yes -a "$ac_cv_header_sys_ipc_h" = yes; then
echo "$as_me:15185: checking for shmctl declaration" >&5
echo $ECHO_N "checking for shmctl declaration... $ECHO_C" >&6
if test "${cl_cv_proto_shmctl+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 15192 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmctl (int shmid, int cmd, struct shmid_ds * buf);
#else
int shmctl();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15223: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15226: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15229: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15232: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

cl_cv_proto_shmctl_dots=no
cl_cv_proto_shmctl_args="int, int, struct shmid_ds *"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5

cl_cv_proto_shmctl_dots=yes
cl_cv_proto_shmctl_args="int, int, ..."
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_shmctl="extern int shmctl ($cl_cv_proto_shmctl_args);"
fi

cl_cv_proto_shmctl=`echo "$cl_cv_proto_shmctl" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15250: result: ${ac_t:-
         }$cl_cv_proto_shmctl" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_shmctl" >&6

if test $cl_cv_proto_shmctl_dots = yes; then
  cat >>confdefs.h <<\EOF
#define SHMCTL_DOTS 1
EOF

fi
fi

                      if test "$ac_cv_header_sys_shm_h" = yes -a "$ac_cv_header_sys_ipc_h" = yes; then
# This test is from Marcus Daniels
echo "$as_me:15265: checking for working shared memory" >&5
echo $ECHO_N "checking for working shared memory... $ECHO_C" >&6
if test "${cl_cv_sys_shm_works+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_sys_shm_works="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 15275 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmget (key_t key, $cl_cv_proto_shmget_arg2 size, int shmflg);
#else
int shmget();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
$cl_cv_proto_shmat_ret shmat (int shmid, $cl_cv_proto_shmat_arg2 $cl_cv_proto_shmat_ret shmaddr, int shmflg);
#else
$cl_cv_proto_shmat_ret shmat();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmdt ($cl_cv_proto_shmdt_arg1 shmaddr);
#else
int shmdt();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int shmctl ($cl_cv_proto_shmctl_args);
#else
int shmctl();
#endif
/* try attaching a single segment to multiple addresses */
#define segsize 0x10000
#define attaches 128
#define base_addr 0x01000000
int main ()
{ int shmid, i; char* addr; char* result;
  if ((shmid = shmget(IPC_PRIVATE,segsize,0400)) < 0) exit(1);
  for (i=0, addr = (char*)0x01000000; i<attaches; i++, addr += segsize)
    if ((result = (char*)shmat(shmid,addr,SHM_RDONLY)) == (char*)(-1)) break;
  for (i=0, addr = (char*)0x01000000; i<attaches; i++, addr += segsize)
    shmdt(addr);
  shmctl(shmid,IPC_RMID,0);
  exit(result == (char*)(-1));
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:15336: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15339: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:15341: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15344: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_sys_shm_works=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_sys_shm_works=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:15357: result: $cl_cv_sys_shm_works" >&5
echo "${ECHO_T}$cl_cv_sys_shm_works" >&6
fi
case "$cl_cv_sys_shm_works" in
  *yes) have_shm=1
        cat >>confdefs.h <<\EOF
#define HAVE_SHM 1
EOF

for ac_header in sys/sysmacros.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
echo "$as_me:15369: checking for $ac_header" >&5
echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
if eval "test \"\${$as_ac_Header+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 15375 "configure"
#include "confdefs.h"
#include <$ac_header>
_ACEOF
if { (eval echo "$as_me:15379: \"$ac_cpp conftest.$ac_ext\"") >&5
  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
  ac_status=$?
  egrep -v '^ *\+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  echo "$as_me:15385: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null; then
  if test -s conftest.err; then
    ac_cpp_err=$ac_c_preproc_warn_flag
  else
    ac_cpp_err=
  fi
else
  ac_cpp_err=yes
fi
if test -z "$ac_cpp_err"; then
  eval "$as_ac_Header=yes"
else
  echo "$as_me: failed program was:" >&5
  cat conftest.$ac_ext >&5
  eval "$as_ac_Header=no"
fi
rm -f conftest.err conftest.$ac_ext
fi
echo "$as_me:15404: result: `eval echo '${'$as_ac_Header'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
if test `eval echo '${'$as_ac_Header'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
EOF

fi
done

        ;;
  *) ;;
esac

                      if test -n "$have_shm"; then
echo "$as_me:15419: checking for attachability of removed shared memory" >&5
echo $ECHO_N "checking for attachability of removed shared memory... $ECHO_C" >&6
if test "${cl_cv_func_shmctl_attachable+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test "$cross_compiling" = yes; then
  cl_cv_func_shmctl_attachable="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 15429 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#ifdef HAVE_SYS_SYSMACROS_H
#include <sys/sysmacros.h>
#endif
#if defined(__STDC__) || defined(__cplusplus)
extern
#ifdef __cplusplus
"C"
#endif
int shmget (key_t key, SHMGET_SIZE_T size, int shmflg);
extern
#ifdef __cplusplus
"C"
#endif
RETSHMATTYPE shmat (int shmid, SHMAT_CONST RETSHMATTYPE shmaddr, int shmflg);
extern
#ifdef __cplusplus
"C"
#endif

#ifdef SHMCTL_DOTS
int shmctl (int shmid, int cmd, ...);
#else
int shmctl (int shmid, int cmd, struct shmid_ds * buf);
#endif
#else
extern int shmget();
extern RETSHMATTYPE shmat();
extern int shmctl();
#endif
int main ()
{ unsigned int pagesize = 8192; /* should be a multiple of SHMLBA */
  unsigned long addr = (unsigned long) malloc(2*pagesize);
  addr += pagesize-1; addr = (addr/pagesize)*pagesize;
 {unsigned long addr1 = addr + 0x10000;
  unsigned long addr2 = addr + 0x20000;
  int id = shmget(IPC_PRIVATE,pagesize,IPC_CREAT|0600);
  if (id<0)
    { exit(1); }
  if (shmat(id,(RETSHMATTYPE)addr1,0) == (RETSHMATTYPE)(-1))
    { shmctl(id,IPC_RMID,NULL); exit(1); }
  if (shmctl(id,IPC_RMID,NULL) < 0)
    { exit(1); }
  if (shmat(id,(RETSHMATTYPE)addr2,0) == (RETSHMATTYPE)(-1))
    { shmctl(id,IPC_RMID,NULL); exit(1); }
  shmctl(id,IPC_RMID,NULL);
  exit(0);
}}

_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:15489: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15492: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:15494: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15497: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_shmctl_attachable=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_func_shmctl_attachable=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi

fi
echo "$as_me:15510: result: $cl_cv_func_shmctl_attachable" >&5
echo "${ECHO_T}$cl_cv_func_shmctl_attachable" >&6
case "$cl_cv_func_shmctl_attachable" in
  *yes) cat >>confdefs.h <<\EOF
#define SHM_RMID_VALID 1
EOF
 ;;
  *no)  ;;
esac
fi

                      echo "$as_me:15521: checking for dlopen" >&5
echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
if test "${cl_cv_func_dlopen+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cl_cv_func_dlopen=no
cl_cv_lib_dl=no
cat >conftest.$ac_ext <<_ACEOF
#line 15530 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char dlopen();
int
main ()
{
dlopen();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:15546: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15549: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:15552: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15555: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_dlopen=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test "$cl_cv_func_dlopen" = no; then
cl_save_LIBS="$LIBS"
LIBS="$LIBS -ldl"
cat >conftest.$ac_ext <<_ACEOF
#line 15567 "configure"
#include "confdefs.h"
extern
#ifdef __cplusplus
"C"
#endif
char dlopen();
int
main ()
{
dlopen();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:15583: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15586: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:15589: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15592: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_lib_dl=yes
cl_cv_func_dlopen=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS="$cl_save_LIBS"
fi

fi
echo "$as_me:15605: result: $cl_cv_func_dlopen" >&5
echo "${ECHO_T}$cl_cv_func_dlopen" >&6
if test "$cl_cv_func_dlopen" = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_DLOPEN 1
EOF

  echo "$as_me:15612: checking for dlsym declaration" >&5
echo $ECHO_N "checking for dlsym declaration... $ECHO_C" >&6
if test "${cl_cv_proto_dlsym+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

  cat >conftest.$ac_ext <<_ACEOF
#line 15619 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <dlfcn.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
void* dlsym (void* handle, char* symbol);
#else
void* dlsym();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15648: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15651: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15654: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15657: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_dlsym_arg2=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_dlsym_arg2="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_dlsym="extern void* dlsym (void* handle, $cl_cv_proto_dlsym_arg2 char* symbol);"
fi

cl_cv_proto_dlsym=`echo "$cl_cv_proto_dlsym" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15671: result: ${ac_t:-
         }$cl_cv_proto_dlsym" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_dlsym" >&6

  cat >>confdefs.h <<EOF
#define DLSYM_CONST $cl_cv_proto_dlsym_arg2
EOF

  echo "$as_me:15680: checking for dlerror declaration" >&5
echo $ECHO_N "checking for dlerror declaration... $ECHO_C" >&6
if test "${cl_cv_proto_dlerror+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

  cat >conftest.$ac_ext <<_ACEOF
#line 15687 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <dlfcn.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
char * dlerror ();
#else
char * dlerror();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15716: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15719: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15722: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15725: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_dlerror_ret=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_dlerror_ret="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_dlerror="extern $cl_cv_proto_dlerror_ret char * dlerror ();"
fi

cl_cv_proto_dlerror=`echo "$cl_cv_proto_dlerror" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15739: result: ${ac_t:-
         }$cl_cv_proto_dlerror" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_dlerror" >&6

  cat >>confdefs.h <<EOF
#define DLERROR_CONST $cl_cv_proto_dlerror_ret
EOF

fi
LIBDL=
if test "$cl_cv_lib_dl" = yes; then
  LIBDL="-ldl"
fi

echo "$as_me:15754: checking for iconv" >&5
echo $ECHO_N "checking for iconv... $ECHO_C" >&6
if test "${cl_cv_func_iconv+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cl_cv_func_iconv=no
cl_cv_lib_iconv=no
cat >conftest.$ac_ext <<_ACEOF
#line 15763 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <iconv.h>

int
main ()
{
iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL);
iconv_close(cd);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:15778: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15781: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:15784: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15787: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_func_iconv=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
if test "$cl_cv_func_iconv" = no; then
cl_save_LIBS="$LIBS"
LIBS="$LIBS -liconv"
cat >conftest.$ac_ext <<_ACEOF
#line 15799 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <iconv.h>

int
main ()
{
iconv_t cd = iconv_open("",""); iconv(cd,NULL,NULL,NULL,NULL);
iconv_close(cd);
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:15814: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15817: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:15820: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15823: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_lib_iconv=yes
cl_cv_func_iconv=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS="$cl_save_LIBS"
fi

fi
echo "$as_me:15836: result: $cl_cv_func_iconv" >&5
echo "${ECHO_T}$cl_cv_func_iconv" >&6
if test "$cl_cv_func_iconv" = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_ICONV 1
EOF

echo "$as_me:15843: checking for iconv declaration" >&5
echo $ECHO_N "checking for iconv declaration... $ECHO_C" >&6
if test "${cl_cv_proto_iconv+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat >conftest.$ac_ext <<_ACEOF
#line 15850 "configure"
#include "confdefs.h"

#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <sys/types.h>
#include <iconv.h>

extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t* outbytesleft);
#else
size_t iconv();
#endif

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (eval echo "$as_me:15880: \"$ac_compile\"") >&5
  (eval $ac_compile) 2>&5
  ac_status=$?
  echo "$as_me:15883: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest.$ac_objext'
  { (eval echo "$as_me:15886: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15889: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  cl_cv_proto_iconv_arg1=""
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
cl_cv_proto_iconv_arg1="const"
fi
rm -f conftest.$ac_objext conftest.$ac_ext

cl_cv_proto_iconv="extern size_t iconv (iconv_t cd, $cl_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t* outbytesleft);"
fi

cl_cv_proto_iconv=`echo "$cl_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
echo "$as_me:15903: result: ${ac_t:-
         }$cl_cv_proto_iconv" >&5
echo "${ECHO_T}${ac_t:-
         }$cl_cv_proto_iconv" >&6

cat >>confdefs.h <<EOF
#define ICONV_CONST $cl_cv_proto_iconv_arg1
EOF

fi
LIBICONV=
if test "$cl_cv_lib_iconv" = yes; then
  LIBICONV="-liconv"
fi

                      LIBTERMCAP=

for ac_func in tgetent
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:15923: checking for $ac_func" >&5
echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
if eval "test \"\${$as_ac_var+set}\" = set"; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  cat >conftest.$ac_ext <<_ACEOF
#line 15929 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char $ac_func ();
char (*f) ();

int
main ()
{
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
f = $ac_func;
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:15960: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:15963: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:15966: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:15969: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  eval "$as_ac_var=yes"
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
eval "$as_ac_var=no"
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
echo "$as_me:15979: result: `eval echo '${'$as_ac_var'}'`" >&5
echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
if test `eval echo '${'$as_ac_var'}'` = yes; then
  cat >>confdefs.h <<EOF
#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
EOF

fi
done

if test $ac_cv_func_tgetent = yes; then
  :
else
  echo "$as_me:15992: checking for tgetent in -lncurses" >&5
echo $ECHO_N "checking for tgetent in -lncurses... $ECHO_C" >&6
if test "${ac_cv_lib_ncurses_tgetent+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lncurses  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 16000 "configure"
#include "confdefs.h"

/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char tgetent ();
int
main ()
{
tgetent ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:16019: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:16022: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:16025: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:16028: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_ncurses_tgetent=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_ncurses_tgetent=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:16039: result: $ac_cv_lib_ncurses_tgetent" >&5
echo "${ECHO_T}$ac_cv_lib_ncurses_tgetent" >&6
if test $ac_cv_lib_ncurses_tgetent = yes; then
  LIBTERMCAP="-lncurses"
fi

  if test -z "$LIBTERMCAP"; then
    echo "$as_me:16046: checking for tgetent in -ltermcap" >&5
echo $ECHO_N "checking for tgetent in -ltermcap... $ECHO_C" >&6
if test "${ac_cv_lib_termcap_tgetent+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-ltermcap  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line 16054 "configure"
#include "confdefs.h"

/* Override any gcc2 internal prototype to avoid an error.  */
#ifdef __cplusplus
extern "C"
#endif
/* We use char because int might match the return type of a gcc2
   builtin and then its argument prototype would still apply.  */
char tgetent ();
int
main ()
{
tgetent ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:16073: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:16076: \$? = $ac_status" >&5
  (exit $ac_status); } &&
         { ac_try='test -s conftest$ac_exeext'
  { (eval echo "$as_me:16079: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:16082: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_lib_termcap_tgetent=yes
else
  echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_termcap_tgetent=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:16093: result: $ac_cv_lib_termcap_tgetent" >&5
echo "${ECHO_T}$ac_cv_lib_termcap_tgetent" >&6
if test $ac_cv_lib_termcap_tgetent = yes; then
  LIBTERMCAP="-ltermcap"
fi

  fi
fi

                      echo "$as_me:16102: checking for the valid characters in filenames" >&5
echo $ECHO_N "checking for the valid characters in filenames... $ECHO_C" >&6
if test "${cl_cv_os_valid_filename_char+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $cross_compiling = no; then
mkdir conftestdir
cat > conftest.c <<EOF
#include "confdefs.h"
#include <sys/types.h>
#include <stdlib.h>
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <string.h>
#include <stdio.h>
/* Declare chdir(). */
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int chdir (CHDIR_CONST char* path);
#else
int chdir();
#endif
/* Declare open(). */
#include <fcntl.h>
#ifdef OPEN_NEEDS_SYS_FILE_H
#include <sys/file.h>
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
int open ($cl_cv_proto_open_args);
#else
int open();
#endif
/* Declare opendir(), readdir(), closedir(). */
#include <$ac_header_dirent>
#ifdef DIRENT
#define SDIRENT struct dirent
#else
#define SDIRENT struct direct
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
DIR* opendir (OPENDIR_CONST char* dirname);
#else
DIR* opendir();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
SDIRENT* readdir (DIR* dirp);
#else
SDIRENT* readdir();
#endif
extern
#ifdef __cplusplus
"C"
#endif

#if defined(__STDC__) || defined(__cplusplus)
RETCLOSEDIRTYPE closedir (DIR* dirp);
#else
RETCLOSEDIRTYPE closedir();
#endif
/* A small program which checks for each character whether or not it is
 * valid in filenames. */
#define N 256
int main ()
{
#ifdef __CYGWIN32__
  /* The test below would cause a dialog box to pop up (ch == ':'),
     and create files which cause "rm -rf conftest*" to hang
     (ch == '"') || (ch == '<') || (ch == '>') || (ch == 197) || (ch == 206).
     Also, it would make appear that (ch >= 'A') && (ch <= 'Z') doesn't work,
     because it would create files in lower case. But we don't want to forbid
     upper case letters in file names. */
  printf("(ch >= 1) && (ch <= 127) && (ch != 34) && (ch != 42) && (ch != 47) && (ch != 58) && (ch != 60) && (ch != 62) && (ch != 63) && (ch != 92) || (ch == 131) || (ch >= 160) && (ch != 197) && (ch != 206)\n");
#else
  char legal[N];
  char filename[4];
  int i;
  if (chdir("conftestdir") < 0) exit(1);
  for (i = 0; i < N; i++) legal[i] = 0;
  strcpy(filename,"a_z");
  for (i = 0; i < N; i++)
    if (i != '\0')
      { filename[1] = i;
        /* Determine whether the filename is valid: create a file
         * and check that it is present afterwards, under the same name. */
        { int fd = open(filename, O_CREAT | O_RDWR, 0644);
          if (fd >=0)
            { DIR* dirp = opendir(".");
              if (dirp != (DIR*)0)
                { SDIRENT* d;
                  while ((d = readdir(dirp)))
                    { if (!strcmp(d->d_name,".")) continue;
                      if (!strcmp(d->d_name,"..")) continue;
                      if (!strcmp(d->d_name,filename)) legal[i] = 1;
                      /* Remove the file even if its name is something else. */
                      unlink(d->d_name);
                    }
                  closedir(dirp);
                }
              close(fd);
      } }   }
  /* Output a boolean expression equivalent to legal[ch] (0 <= ch < N). */
  { int need_or = 0;
    int z;
    for (z = 0; z < N; )
      { int x, y;
        if (! legal[z]) { z++; continue; }
        x = z;
        if (need_or) printf(" || ");
        z++;
        if ((z < N) && legal[z])
          { do { do { z++; } while ((z < N) && legal[z]);
                 y = z-1;
                 z++;
               } while ((z < N) && legal[z]);
            { int premises = 0;
              if (x > 0) premises++;
              if (y < N-1) premises++;
              for (i = x; i <= y; i++)
                if (! legal[i])
                  premises++;
              if (premises > 1) printf("(");
              { int need_and = 0;
                if (x > 0) { printf("(ch >= %d)",x); need_and = 1; }
                if (y < N-1)
                  { if (need_and) printf(" && ");
                    printf("(ch <= %d)",y);
                    need_and = 1;
                  }
                for (i = x; i <= y; i++)
                  if (! legal[i])
                    { if (need_and) printf(" && ");
                      printf("(ch != %d)",i);
                      need_and = 1;
                    }
                if (!need_and) printf("1");
              }
              if (premises > 1) printf(")");
            }
            z = y+1;
          }
          else
          { printf("(ch == %d)",x); z++; }
        need_or = 1;
      }
    printf("\n");
  }
#endif
  exit(0);
}
EOF
{ (eval echo "$as_me:16273: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:16276: \$? = $ac_status" >&5
  (exit $ac_status); }
cl_cv_os_valid_filename_char=`./conftest`
fi
rm -rf conftest*

fi

if test -z "$cl_cv_os_valid_filename_char"; then
  cl_cv_os_valid_filename_charset="guessing 7-bit"
else
  if test "$cl_cv_os_valid_filename_char" = '((ch >= 1) && (ch != 47))'; then
    cl_cv_os_valid_filename_charset="8-bit"
  else
    cl_cv_os_valid_filename_charset="7-bit"
  fi
fi
echo "$as_me:16293: result: $cl_cv_os_valid_filename_charset" >&5
echo "${ECHO_T}$cl_cv_os_valid_filename_charset" >&6
if test -n "$cl_cv_os_valid_filename_char"; then
  cat >>confdefs.h <<EOF
#define VALID_FILENAME_CHAR $cl_cv_os_valid_filename_char
EOF

fi

                      echo "$as_me:16302: checking for inline __builtin_strlen" >&5
echo $ECHO_N "checking for inline __builtin_strlen... $ECHO_C" >&6
if test "${cl_cv_builtin_strlen+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

cat > conftest.$ac_ext <<EOF
#if defined(__STDC__) || defined(__cplusplus)
int foo (char* x)
#else
int foo (x) char* x;
#endif
{ return __builtin_strlen(x); }
EOF
if { ac_try='${CC-cc} -S $CFLAGS $CPPFLAGS conftest.$ac_ext'
  { (eval echo "$as_me:16317: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:16320: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null 2>&1 ; then
  if grep strlen conftest.s >/dev/null ; then
    cl_cv_builtin_strlen=no
  else
    cl_cv_builtin_strlen=yes
  fi
else
  cl_cv_builtin_strlen=no
fi
rm -f conftest*

fi
echo "$as_me:16333: result: $cl_cv_builtin_strlen" >&5
echo "${ECHO_T}$cl_cv_builtin_strlen" >&6
if test $cl_cv_builtin_strlen = yes; then
  cat >>confdefs.h <<\EOF
#define HAVE_BUILTIN_STRLEN 1
EOF

fi

                      echo "$as_me:16342: checking whether characters are unsigned" >&5
echo $ECHO_N "checking whether characters are unsigned... $ECHO_C" >&6
if test "${ac_cv_c_char_unsigned+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else

if test $ac_cv_c_compiler_gnu = yes; then
  # GCC predefines this symbol on systems where it applies.
cat >conftest.$ac_ext <<_ACEOF
#line 16351 "configure"
#include "confdefs.h"
#ifdef __CHAR_UNSIGNED__
  yes
#endif

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "yes" >/dev/null 2>&1; then
  ac_cv_c_char_unsigned=yes
else
  ac_cv_c_char_unsigned=no
fi
rm -f conftest*

else
if test "$cross_compiling" = yes; then
  ac_cv_c_char_unsigned="guessing no"
else
  cat >conftest.$ac_ext <<_ACEOF
#line 16371 "configure"
#include "confdefs.h"
/* volatile prevents gcc2 from optimizing the test away on sparcs.  */
#if !defined(__STDC__) || __STDC__ != 1
#define volatile
#endif
int main() {
  volatile char c = 255; exit(c < 0);
}
_ACEOF
rm -f conftest$ac_exeext
if { (eval echo "$as_me:16382: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:16385: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (eval echo "$as_me:16387: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  echo "$as_me:16390: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_c_char_unsigned=yes
else
  echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_c_char_unsigned=no
fi
rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
fi
fi
echo "$as_me:16403: result: $ac_cv_c_char_unsigned" >&5
echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
if test $ac_cv_c_compiler_gnu = no; then
  # GCC defines __CHAR_UNSIGNED__ by itself, no need to fix up.
  case "$ac_cv_c_char_unsigned" in
    *yes) cat >>confdefs.h <<\EOF
#define __CHAR_UNSIGNED__ 1
EOF
 ;;
    *no) ;;
  esac
fi

                      cl_machine_file_c=${srcdir}/intparam.c
cl_machine_file_h=intparam.h
if test $cross_compiling = no; then
if test -z "$cl_cv_file_intparam_h"; then
{ echo "$as_me:16420: checking for integer types and behaviour..." >&5
echo "$as_me: checking for integer types and behaviour..." >&6;}
cat > conftest.$ac_ext <<EOF
#include "confdefs.h"
EOF
cat "$cl_machine_file_c" >> conftest.$ac_ext
ORIGCC="$CC"
if test $ac_cv_c_compiler_gnu = yes; then
# gcc -O (gcc version <= 2.3.2) crashes when compiling long long shifts for
# target 80386. Strip "-O".
CC=`echo "$CC " | sed -e 's/-O //g'`
fi
{ (eval echo "$as_me:16432: \"$ac_link\"") >&5
  (eval $ac_link) 2>&5
  ac_status=$?
  echo "$as_me:16435: \$? = $ac_status" >&5
  (exit $ac_status); }
CC="$ORIGCC"
if test -s conftest; then
  echo "creating $cl_machine_file_h"
  ./conftest > conftest.h
  if cmp -s "$cl_machine_file_h" conftest.h 2>/dev/null; then
    # The file exists and we would not be changing it
    rm -f conftest.h
  else
    rm -f "$cl_machine_file_h"
    mv conftest.h "$cl_machine_file_h"
  fi
  cl_cv_file_intparam_h=1
else
  echo "creation of $cl_machine_file_h failed"
fi
rm -f conftest*
fi
else
echo "cross-compiling - cannot create $cl_machine_file_h"
fi

                      ac_config_files="$ac_config_files makemake"
ac_config_commands="$ac_config_commands default"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
# scripts and configure runs, see configure's option --config-cache.
# It is not useful on other systems.  If it contains results you don't
# want to keep, you may remove or edit it.
#
# config.status only pays attention to the cache file if you give it
# the --recheck option to rerun configure.
#
# `ac_cv_env_foo' variables (set or unset) will be overriden when
# loading this file, other *unset* `ac_cv_foo' will be assigned the
# following values.

_ACEOF

# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
# So, don't put newlines in cache variables' values.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
{
  (set) 2>&1 |
    case `(ac_space=' '; set | grep ac_space) 2>&1` in
    *ac_space=\ *)
      # `set' does not quote correctly, so add quotes (double-quote
      # substitution turns \\\\ into \\, and sed turns \\ into \).
      sed -n \
        "s/'/'\\\\''/g;
    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
      ;;
    *)
      # `set' quotes correctly as required by POSIX, so do not add quotes.
      sed -n \
        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
      ;;
    esac;
} |
  sed '
     t clear
     : clear
     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
     t end
     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
     : end' >>confcache
if cmp -s $cache_file confcache; then :; else
  if test -w $cache_file; then
    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
    cat confcache >$cache_file
  else
    echo "not updating unwritable cache $cache_file"
  fi
fi
rm -f confcache

test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'

# VPATH may cause trouble with some makes, so we remove $(srcdir),
# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
# trailing colons and then remove the whole line if VPATH becomes empty
# (actually we leave an empty line to preserve line numbers).
if test "x$srcdir" = x.; then
  ac_vpsub='/^[ 	]*VPATH[ 	]*=/{
s/:*\$(srcdir):*/:/;
s/:*\${srcdir}:*/:/;
s/:*@srcdir@:*/:/;
s/^\([^=]*=[ 	]*\):*/\1/;
s/:*$//;
s/^[^=]*=[ 	]*$//;
}'
fi

DEFS=-DHAVE_CONFIG_H

: ${CONFIG_STATUS=./config.status}
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
{ echo "$as_me:16539: creating $CONFIG_STATUS" >&5
echo "$as_me: creating $CONFIG_STATUS" >&6;}
cat >$CONFIG_STATUS <<_ACEOF
#! $SHELL
# Generated automatically by configure.
# Run this file to recreate the current configuration.
# Compiler output produced by configure, useful for debugging
# configure, is in config.log if it exists.

debug=false
SHELL=\${CONFIG_SHELL-$SHELL}
ac_cs_invocation="\$0 \$@"

_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF
# Be Bourne compatible
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
  set -o posix
fi

# Name of the executable.
as_me=`echo "$0" |sed 's,.*[\\/],,'`

if expr a : '\(a\)' >/dev/null 2>&1; then
  as_expr=expr
else
  as_expr=false
fi

rm -f conf$$ conf$$.exe conf$$.file
echo >conf$$.file
if ln -s conf$$.file conf$$ 2>/dev/null; then
  # We could just check for DJGPP; but this test a) works b) is more generic
  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
  if test -f conf$$.exe; then
    # Don't use ln at all; we don't have any links
    as_ln_s='cp -p'
  else
    as_ln_s='ln -s'
  fi
elif ln conf$$.file conf$$ 2>/dev/null; then
  as_ln_s=ln
else
  as_ln_s='cp -p'
fi
rm -f conf$$ conf$$.exe conf$$.file

as_executable_p="test -f"

# Support unset when possible.
if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
  as_unset=unset
else
  as_unset=false
fi

# NLS nuisances.
$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }

# IFS
# We need space, tab and new line, in precisely that order.
as_nl='
'
IFS=" 	$as_nl"

# CDPATH.
$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }

exec 6>&1

_ACEOF

# Files that config.status was made for.
if test -n "$ac_config_files"; then
  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
fi

if test -n "$ac_config_headers"; then
  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
fi

if test -n "$ac_config_links"; then
  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
fi

if test -n "$ac_config_commands"; then
  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
fi

cat >>$CONFIG_STATUS <<\EOF

ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
current configuration.

Usage: $0 [OPTIONS] [FILE]...

  -h, --help       print this help, then exit
  -V, --version    print version number, then exit
  -d, --debug      don't remove temporary files
      --recheck    update $as_me by reconfiguring in the same conditions
  --file=FILE[:TEMPLATE]
                   instantiate the configuration file FILE
  --header=FILE[:TEMPLATE]
                   instantiate the configuration header FILE

Configuration files:
$config_files

Configuration headers:
$config_headers

Configuration commands:
$config_commands

Report bugs to <bug-autoconf@gnu.org>."
EOF

cat >>$CONFIG_STATUS <<EOF
ac_cs_version="\\
config.status
configured by $0, generated by GNU Autoconf 2.52,
  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"

Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
srcdir=$srcdir
EOF

cat >>$CONFIG_STATUS <<\EOF
# If no file are specified by the user, then we need to provide default
# value.  By we need to know if files were specified by the user.
ac_need_defaults=:
while test $# != 0
do
  case $1 in
  --*=*)
    ac_option=`expr "x$1" : 'x\([^=]*\)='`
    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
    shift
    set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
    shift
    ;;
  -*);;
  *) # This is not an option, so the user has probably given explicit
     # arguments.
     ac_need_defaults=false;;
  esac

  case $1 in
  # Handling of the options.
EOF
cat >>$CONFIG_STATUS <<EOF
  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
    echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
    exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
EOF
cat >>$CONFIG_STATUS <<\EOF
  --version | --vers* | -V )
    echo "$ac_cs_version"; exit 0 ;;
  --he | --h)
    # Conflict between --help and --header
    { { echo "$as_me:16714: error: ambiguous option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: ambiguous option: $1
Try \`$0 --help' for more information." >&2;}
   { (exit 1); exit 1; }; };;
  --help | --hel | -h )
    echo "$ac_cs_usage"; exit 0 ;;
  --debug | --d* | -d )
    debug=: ;;
  --file | --fil | --fi | --f )
    shift
    CONFIG_FILES="$CONFIG_FILES $1"
    ac_need_defaults=false;;
  --header | --heade | --head | --hea )
    shift
    CONFIG_HEADERS="$CONFIG_HEADERS $1"
    ac_need_defaults=false;;

  # This is an error.
  -*) { { echo "$as_me:16733: error: unrecognized option: $1
Try \`$0 --help' for more information." >&5
echo "$as_me: error: unrecognized option: $1
Try \`$0 --help' for more information." >&2;}
   { (exit 1); exit 1; }; } ;;

  *) ac_config_targets="$ac_config_targets $1" ;;

  esac
  shift
done

exec 5>>config.log
cat >&5 << _ACEOF

## ----------------------- ##
## Running config.status.  ##
## ----------------------- ##

This file was extended by $as_me 2.52, executed with
  CONFIG_FILES    = $CONFIG_FILES
  CONFIG_HEADERS  = $CONFIG_HEADERS
  CONFIG_LINKS    = $CONFIG_LINKS
  CONFIG_COMMANDS = $CONFIG_COMMANDS
  > $ac_cs_invocation
on `(hostname || uname -n) 2>/dev/null | sed 1q`

_ACEOF
EOF

cat >>$CONFIG_STATUS <<\EOF
for ac_config_target in $ac_config_targets
do
  case "$ac_config_target" in
  # Handling of arguments.
  "makemake" ) CONFIG_FILES="$CONFIG_FILES makemake" ;;
  "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
  "unixconf.h" ) CONFIG_HEADERS="$CONFIG_HEADERS unixconf.h" ;;
  *) { { echo "$as_me:16771: error: invalid argument: $ac_config_target" >&5
echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
   { (exit 1); exit 1; }; };;
  esac
done

# If the user did not use the arguments to specify the items to instantiate,
# then the envvar interface is used.  Set only those that are not.
# We use the long form for the default assignment because of an extremely
# bizarre bug on SunOS 4.1.3.
if $ac_need_defaults; then
  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
fi

# Create a temporary directory, and hook for its removal unless debugging.
$debug ||
{
  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
  trap '{ (exit 1); exit 1; }' 1 2 13 15
}

# Create a (secure) tmp directory for tmp files.
: ${TMPDIR=/tmp}
{
  tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
  test -n "$tmp" && test -d "$tmp"
}  ||
{
  tmp=$TMPDIR/cs$$-$RANDOM
  (umask 077 && mkdir $tmp)
} ||
{
   echo "$me: cannot create a temporary directory in $TMPDIR" >&2
   { (exit 1); exit 1; }
}

EOF

cat >>$CONFIG_STATUS <<EOF

#
# CONFIG_FILES section.
#

# No need to generate the scripts if there are no CONFIG_FILES.
# This happens for instance when ./config.status config.h
if test -n "\$CONFIG_FILES"; then
  # Protect against being on the right side of a sed subst in config.status.
  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
s,@SHELL@,$SHELL,;t t
s,@exec_prefix@,$exec_prefix,;t t
s,@prefix@,$prefix,;t t
s,@program_transform_name@,$program_transform_name,;t t
s,@bindir@,$bindir,;t t
s,@sbindir@,$sbindir,;t t
s,@libexecdir@,$libexecdir,;t t
s,@datadir@,$datadir,;t t
s,@sysconfdir@,$sysconfdir,;t t
s,@sharedstatedir@,$sharedstatedir,;t t
s,@localstatedir@,$localstatedir,;t t
s,@libdir@,$libdir,;t t
s,@includedir@,$includedir,;t t
s,@oldincludedir@,$oldincludedir,;t t
s,@infodir@,$infodir,;t t
s,@mandir@,$mandir,;t t
s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
s,@build_alias@,$build_alias,;t t
s,@host_alias@,$host_alias,;t t
s,@target_alias@,$target_alias,;t t
s,@ECHO_C@,$ECHO_C,;t t
s,@ECHO_N@,$ECHO_N,;t t
s,@ECHO_T@,$ECHO_T,;t t
s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
s,@DEFS@,$DEFS,;t t
s,@LIBS@,$LIBS,;t t
s,@CC@,$CC,;t t
s,@CFLAGS@,$CFLAGS,;t t
s,@LDFLAGS@,$LDFLAGS,;t t
s,@CPPFLAGS@,$CPPFLAGS,;t t
s,@ac_ct_CC@,$ac_ct_CC,;t t
s,@EXEEXT@,$EXEEXT,;t t
s,@OBJEXT@,$OBJEXT,;t t
s,@CPP@,$CPP,;t t
s,@CC_GCC@,$CC_GCC,;t t
s,@GCC_X_NONE@,$GCC_X_NONE,;t t
s,@CC_CPLUSPLUS@,$CC_CPLUSPLUS,;t t
s,@CC_ANSI@,$CC_ANSI,;t t
s,@CC_NEED_CCPAUX@,$CC_NEED_CCPAUX,;t t
s,@CC_NEED_DEEMA@,$CC_NEED_DEEMA,;t t
s,@AS_UNDERSCORE@,$AS_UNDERSCORE,;t t
s,@RANLIB@,$RANLIB,;t t
s,@INSTALL@,$INSTALL,;t t
s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
s,@INSTALL_DATA@,$INSTALL_DATA,;t t
s,@CP@,$CP,;t t
s,@LN@,$LN,;t t
s,@LN_S@,$LN_S,;t t
s,@HLN@,$HLN,;t t
s,@GROFF@,$GROFF,;t t
s,@build@,$build,;t t
s,@build_cpu@,$build_cpu,;t t
s,@build_vendor@,$build_vendor,;t t
s,@build_os@,$build_os,;t t
s,@host@,$host,;t t
s,@host_cpu@,$host_cpu,;t t
s,@host_vendor@,$host_vendor,;t t
s,@host_os@,$host_os,;t t
s,@STDBOOL_H@,$STDBOOL_H,;t t
s,@HAVE_XMKMF@,$HAVE_XMKMF,;t t
s,@X_INCLUDES@,$X_INCLUDES,;t t
s,@X_LIBS@,$X_LIBS,;t t
s,@GMALLOC@,$GMALLOC,;t t
s,@ALLOCA@,$ALLOCA,;t t
s,@LIBDL@,$LIBDL,;t t
s,@LIBICONV@,$LIBICONV,;t t
s,@LIBTERMCAP@,$LIBTERMCAP,;t t
CEOF

EOF

  cat >>$CONFIG_STATUS <<\EOF
  # Split the substitutions into bite-sized pieces for seds with
  # small command number limits, like on Digital OSF/1 and HP-UX.
  ac_max_sed_lines=48
  ac_sed_frag=1 # Number of current file.
  ac_beg=1 # First line for current file.
  ac_end=$ac_max_sed_lines # Line after last line for current file.
  ac_more_lines=:
  ac_sed_cmds=
  while $ac_more_lines; do
    if test $ac_beg -gt 1; then
      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
    else
      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
    fi
    if test ! -s $tmp/subs.frag; then
      ac_more_lines=false
    else
      # The purpose of the label and of the branching condition is to
      # speed up the sed processing (if there are no `@' at all, there
      # is no need to browse any of the substitutions).
      # These are the two extra sed commands mentioned above.
      (echo ':t
  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
      if test -z "$ac_sed_cmds"; then
  	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
      else
  	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
      fi
      ac_sed_frag=`expr $ac_sed_frag + 1`
      ac_beg=$ac_end
      ac_end=`expr $ac_end + $ac_max_sed_lines`
    fi
  done
  if test -z "$ac_sed_cmds"; then
    ac_sed_cmds=cat
  fi
fi # test -n "$CONFIG_FILES"

EOF
cat >>$CONFIG_STATUS <<\EOF
for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
  case $ac_file in
  - | *:- | *:-:* ) # input from stdin
        cat >$tmp/stdin
        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
  * )   ac_file_in=$ac_file.in ;;
  esac

  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
  ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
         X"$ac_file" : 'X\(//\)[^/]' \| \
         X"$ac_file" : 'X\(//\)$' \| \
         X"$ac_file" : 'X\(/\)' \| \
         .     : '\(.\)' 2>/dev/null ||
echo X"$ac_file" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
  	  /^X\(\/\/\)$/{ s//\1/; q; }
  	  /^X\(\/\).*/{ s//\1/; q; }
  	  s/.*/./; q'`
  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
    { case "$ac_dir" in
  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
  *)                      as_incr_dir=.;;
esac
as_dummy="$ac_dir"
for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
  case $as_mkdir_dir in
    # Skip DOS drivespec
    ?:) as_incr_dir=$as_mkdir_dir ;;
    *)
      as_incr_dir=$as_incr_dir/$as_mkdir_dir
      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
    ;;
  esac
done; }

    ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
    # A "../" for each directory in $ac_dir_suffix.
    ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
  else
    ac_dir_suffix= ac_dots=
  fi

  case $srcdir in
  .)  ac_srcdir=.
      if test -z "$ac_dots"; then
         ac_top_srcdir=.
      else
         ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
      fi ;;
  [\\/]* | ?:[\\/]* )
      ac_srcdir=$srcdir$ac_dir_suffix;
      ac_top_srcdir=$srcdir ;;
  *) # Relative path.
    ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
    ac_top_srcdir=$ac_dots$srcdir ;;
  esac

  if test x"$ac_file" != x-; then
    { echo "$as_me:17003: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}
    rm -f "$ac_file"
  fi
  # Let's still pretend it is `configure' which instantiates (i.e., don't
  # use $as_me), people would be surprised to read:
  #    /* config.h.  Generated automatically by config.status.  */
  configure_input="Generated automatically from `echo $ac_file_in |
                                                 sed 's,.*/,,'` by configure."

  # First look for the input files in the build tree, otherwise in the
  # src tree.
  ac_file_inputs=`IFS=:
    for f in $ac_file_in; do
      case $f in
      -) echo $tmp/stdin ;;
      [\\/$]*)
         # Absolute (can't be DOS-style, as IFS=:)
         test -f "$f" || { { echo "$as_me:17021: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
   { (exit 1); exit 1; }; }
         echo $f;;
      *) # Relative
         if test -f "$f"; then
           # Build tree
           echo $f
         elif test -f "$srcdir/$f"; then
           # Source tree
           echo $srcdir/$f
         else
           # /dev/null tree
           { { echo "$as_me:17034: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
   { (exit 1); exit 1; }; }
         fi;;
      esac
    done` || { (exit 1); exit 1; }
EOF
cat >>$CONFIG_STATUS <<EOF
  sed "$ac_vpsub
$extrasub
EOF
cat >>$CONFIG_STATUS <<\EOF
:t
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
s,@configure_input@,$configure_input,;t t
s,@srcdir@,$ac_srcdir,;t t
s,@top_srcdir@,$ac_top_srcdir,;t t
" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
  rm -f $tmp/stdin
  if test x"$ac_file" != x-; then
    mv $tmp/out $ac_file
  else
    cat $tmp/out
    rm -f $tmp/out
  fi

done
EOF
cat >>$CONFIG_STATUS <<\EOF

#
# CONFIG_HEADER section.
#

# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
# NAME is the cpp macro being defined and VALUE is the value it is being given.
#
# ac_d sets the value in "#define NAME VALUE" lines.
ac_dA='s,^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
ac_dB='[ 	].*$,\1#\2'
ac_dC=' '
ac_dD=',;t'
# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
ac_uA='s,^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
ac_uB='$,\1#\2define\3'
ac_uC=' '
ac_uD=',;t'

for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
  case $ac_file in
  - | *:- | *:-:* ) # input from stdin
        cat >$tmp/stdin
        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
  * )   ac_file_in=$ac_file.in ;;
  esac

  test x"$ac_file" != x- && { echo "$as_me:17094: creating $ac_file" >&5
echo "$as_me: creating $ac_file" >&6;}

  # First look for the input files in the build tree, otherwise in the
  # src tree.
  ac_file_inputs=`IFS=:
    for f in $ac_file_in; do
      case $f in
      -) echo $tmp/stdin ;;
      [\\/$]*)
         # Absolute (can't be DOS-style, as IFS=:)
         test -f "$f" || { { echo "$as_me:17105: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
   { (exit 1); exit 1; }; }
         echo $f;;
      *) # Relative
         if test -f "$f"; then
           # Build tree
           echo $f
         elif test -f "$srcdir/$f"; then
           # Source tree
           echo $srcdir/$f
         else
           # /dev/null tree
           { { echo "$as_me:17118: error: cannot find input file: $f" >&5
echo "$as_me: error: cannot find input file: $f" >&2;}
   { (exit 1); exit 1; }; }
         fi;;
      esac
    done` || { (exit 1); exit 1; }
  # Remove the trailing spaces.
  sed 's/[ 	]*$//' $ac_file_inputs >$tmp/in

EOF

# Transform confdefs.h into two sed scripts, `conftest.defines' and
# `conftest.undefs', that substitutes the proper values into
# config.h.in to produce config.h.  The first handles `#define'
# templates, and the second `#undef' templates.
# And first: Protect against being on the right side of a sed subst in
# config.status.  Protect against being in an unquoted here document
# in config.status.
rm -f conftest.defines conftest.undefs
# Using a here document instead of a string reduces the quoting nightmare.
# Putting comments in sed scripts is not portable.
#
# `end' is used to avoid that the second main sed command (meant for
# 0-ary CPP macros) applies to n-ary macro definitions.
# See the Autoconf documentation for `clear'.
cat >confdef2sed.sed <<\EOF
s/[\\&,]/\\&/g
s,[\\$`],\\&,g
t clear
: clear
s,^[ 	]*#[ 	]*define[ 	][ 	]*\(\([^ 	(][^ 	(]*\)([^)]*)\)[ 	]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
t end
s,^[ 	]*#[ 	]*define[ 	][ 	]*\([^ 	][^ 	]*\)[ 	]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
: end
EOF
# If some macros were called several times there might be several times
# the same #defines, which is useless.  Nevertheless, we may not want to
# sort them, since we want the *last* AC-DEFINE to be honored.
uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
rm -f confdef2sed.sed

# This sed command replaces #undef with comments.  This is necessary, for
# example, in the case of _POSIX_SOURCE, which is predefined and required
# on some systems where configure will not decide to define it.
cat >>conftest.undefs <<\EOF
s,^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
EOF

# Break up conftest.defines because some shells have a limit on the size
# of here documents, and old seds have small limits too (100 cmds).
echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
echo '  if egrep "^[ 	]*#[ 	]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
echo '  :' >>$CONFIG_STATUS
rm -f conftest.tail
while grep . conftest.defines >/dev/null
do
  # Write a limited-size here document to $tmp/defines.sed.
  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
  # Speed up: don't consider the non `#define' lines.
  echo '/^[ 	]*#[ 	]*define/!b' >>$CONFIG_STATUS
  # Work around the forget-to-reset-the-flag bug.
  echo 't clr' >>$CONFIG_STATUS
  echo ': clr' >>$CONFIG_STATUS
  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
  echo 'CEOF
  sed -f $tmp/defines.sed $tmp/in >$tmp/out
  rm -f $tmp/in
  mv $tmp/out $tmp/in
' >>$CONFIG_STATUS
  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
  rm -f conftest.defines
  mv conftest.tail conftest.defines
done
rm -f conftest.defines
echo '  fi # egrep' >>$CONFIG_STATUS
echo >>$CONFIG_STATUS

# Break up conftest.undefs because some shells have a limit on the size
# of here documents, and old seds have small limits too (100 cmds).
echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
rm -f conftest.tail
while grep . conftest.undefs >/dev/null
do
  # Write a limited-size here document to $tmp/undefs.sed.
  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
  # Speed up: don't consider the non `#undef'
  echo '/^[ 	]*#[ 	]*undef/!b' >>$CONFIG_STATUS
  # Work around the forget-to-reset-the-flag bug.
  echo 't clr' >>$CONFIG_STATUS
  echo ': clr' >>$CONFIG_STATUS
  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
  echo 'CEOF
  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
  rm -f $tmp/in
  mv $tmp/out $tmp/in
' >>$CONFIG_STATUS
  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
  rm -f conftest.undefs
  mv conftest.tail conftest.undefs
done
rm -f conftest.undefs

cat >>$CONFIG_STATUS <<\EOF
  # Let's still pretend it is `configure' which instantiates (i.e., don't
  # use $as_me), people would be surprised to read:
  #    /* config.h.  Generated automatically by config.status.  */
  if test x"$ac_file" = x-; then
    echo "/* Generated automatically by configure.  */" >$tmp/config.h
  else
    echo "/* $ac_file.  Generated automatically by configure.  */" >$tmp/config.h
  fi
  cat $tmp/in >>$tmp/config.h
  rm -f $tmp/in
  if test x"$ac_file" != x-; then
    if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
      { echo "$as_me:17235: $ac_file is unchanged" >&5
echo "$as_me: $ac_file is unchanged" >&6;}
    else
      ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
         X"$ac_file" : 'X\(//\)[^/]' \| \
         X"$ac_file" : 'X\(//\)$' \| \
         X"$ac_file" : 'X\(/\)' \| \
         .     : '\(.\)' 2>/dev/null ||
echo X"$ac_file" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
  	  /^X\(\/\/\)$/{ s//\1/; q; }
  	  /^X\(\/\).*/{ s//\1/; q; }
  	  s/.*/./; q'`
      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
        { case "$ac_dir" in
  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
  *)                      as_incr_dir=.;;
esac
as_dummy="$ac_dir"
for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
  case $as_mkdir_dir in
    # Skip DOS drivespec
    ?:) as_incr_dir=$as_mkdir_dir ;;
    *)
      as_incr_dir=$as_incr_dir/$as_mkdir_dir
      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
    ;;
  esac
done; }

      fi
      rm -f $ac_file
      mv $tmp/config.h $ac_file
    fi
  else
    cat $tmp/config.h
    rm -f $tmp/config.h
  fi
done
EOF
cat >>$CONFIG_STATUS <<\EOF

#
# CONFIG_COMMANDS section.
#
for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
  ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
  ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`

  case $ac_dest in
    default ) echo '#!/bin/sh' > makemake.tmp
echo '# Generated automatically from makemake.in by configure.' >> makemake.tmp
cat makemake >> makemake.tmp
mv makemake.tmp makemake
chmod a+x makemake
 ;;
  esac
done
EOF

cat >>$CONFIG_STATUS <<\EOF

{ (exit 0); exit 0; }
EOF
chmod +x $CONFIG_STATUS
ac_clean_files=$ac_clean_files_save

# configure is writing to config.log, and then calls config.status.
# config.status does its own redirection, appending to config.log.
# Unfortunately, on DOS this fails, as config.log is still kept open
# by configure, so config.status won't be able to write to it; its
# output is simply discarded.  So we exec the FD to /dev/null,
# effectively closing config.log, so it can be properly (re)opened and
# appended to by config.status.  When coming back to configure, we
# need to make the FD available again.
if test "$no_create" != yes; then
  ac_cs_success=:
  exec 5>/dev/null
  $SHELL $CONFIG_STATUS || ac_cs_success=false
  exec 5>>config.log
  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
  # would make configure fail if this is the last instruction.
  $ac_cs_success || { (exit 1); exit 1; }
fi

