source: trunk/third/gmake/configure @ 15977

Revision 15977, 173.2 KB checked in by ghudson, 24 years ago (diff)
Regenerate.
  • Property svn:executable set to *
Line 
1#! /bin/sh
2
3# From configure.in Id: configure.in,v 1.4 2001/04/04 00:04:41 ghudson Exp
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34# The following is taken from automake 1.4,
35# except that it prefers the compiler option -Ae to "-Aa -D_HPUX_SOURCE"
36# because only the former supports 64-bit integral types on HP-UX 10.20.
37
38
39# serial 2
40
41# @defmac AC_PROG_CC_STDC
42# @maindex PROG_CC_STDC
43# @ovindex CC
44# If the C compiler in not in ANSI C mode by default, try to add an option
45# to output variable @code{CC} to make it so.  This macro tries various
46# options that select ANSI C on some system or another.  It considers the
47# compiler to be in ANSI C mode if it handles function prototypes correctly.
48#
49# If you use this macro, you should check after calling it whether the C
50# compiler has been set to accept ANSI C; if not, the shell variable
51# @code{am_cv_prog_cc_stdc} is set to @samp{no}.  If you wrote your source
52# code in ANSI C, you can make an un-ANSIfied copy of it by using the
53# program @code{ansi2knr}, which comes with Ghostscript.
54# @end defmac
55
56
57
58
59
60
61
62
63# Define a conditional.
64
65
66
67# Check whether LC_MESSAGES is available in <locale.h>.
68# Ulrich Drepper <drepper@cygnus.com>, 1995.
69#
70# This file can be copied and used freely without restrictions.  It can
71# be used in projects which are not available under the GNU Public License
72# but which still want to provide support for the GNU gettext functionality.
73# Please note that the actual code is *not* freely available.
74
75# serial 1
76
77
78
79# Do all the work for Automake.  This macro actually does too much --
80# some checks are only needed if your package does certain things.
81# But this isn't really a big deal.
82
83# serial 1
84
85
86
87
88#
89# Check to make sure that the build environment is sane.
90#
91
92
93
94
95
96# Like AC_CONFIG_HEADER, but automatically create stamp file.
97
98
99
100# Guess values for system-dependent variables and create Makefiles.
101# Generated automatically using autoconf version 2.13
102# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
103#
104# This configure script is free software; the Free Software Foundation
105# gives unlimited permission to copy, distribute and modify it.
106
107# Defaults:
108ac_help=
109ac_default_prefix=/usr/local
110# Any additions from configure.in:
111ac_help="$ac_help
112  --disable-largefile     omit support for large files"
113ac_help="$ac_help
114  --disable-nls           disallow Native Language Support"
115ac_help="$ac_help
116  --with-included-gettext use the GNU gettext library included here"
117ac_help="$ac_help
118  --disable-nsec-timestamps disable use of sub-second timestamps"
119ac_help="$ac_help
120  --with-customs=DIR      Enable remote jobs via Customs--see README.customs"
121ac_help="$ac_help
122  --disable-job-server    Disallow recursive make communication during -jN"
123ac_help="$ac_help
124  --enable-dmalloc        Enable support for the dmalloc debugging library"
125
126# Initialize some variables set by options.
127# The variables have the same names as the options, with
128# dashes changed to underlines.
129build=NONE
130cache_file=./config.cache
131exec_prefix=NONE
132host=NONE
133no_create=
134nonopt=NONE
135no_recursion=
136prefix=NONE
137program_prefix=NONE
138program_suffix=NONE
139program_transform_name=s,x,x,
140silent=
141site=
142srcdir=
143target=NONE
144verbose=
145x_includes=NONE
146x_libraries=NONE
147bindir='${exec_prefix}/bin'
148sbindir='${exec_prefix}/sbin'
149libexecdir='${exec_prefix}/libexec'
150datadir='${prefix}/share'
151sysconfdir='${prefix}/etc'
152sharedstatedir='${prefix}/com'
153localstatedir='${prefix}/var'
154libdir='${exec_prefix}/lib'
155includedir='${prefix}/include'
156oldincludedir='/usr/include'
157infodir='${prefix}/info'
158mandir='${prefix}/man'
159
160# Initialize some other variables.
161subdirs=
162MFLAGS= MAKEFLAGS=
163SHELL=${CONFIG_SHELL-/bin/sh}
164# Maximum number of lines to put in a shell here document.
165ac_max_here_lines=12
166
167ac_prev=
168for ac_option
169do
170
171  # If the previous option needs an argument, assign it.
172  if test -n "$ac_prev"; then
173    eval "$ac_prev=\$ac_option"
174    ac_prev=
175    continue
176  fi
177
178  case "$ac_option" in
179  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
180  *) ac_optarg= ;;
181  esac
182
183  # Accept the important Cygnus configure options, so we can diagnose typos.
184
185  case "$ac_option" in
186
187  -bindir | --bindir | --bindi | --bind | --bin | --bi)
188    ac_prev=bindir ;;
189  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
190    bindir="$ac_optarg" ;;
191
192  -build | --build | --buil | --bui | --bu)
193    ac_prev=build ;;
194  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
195    build="$ac_optarg" ;;
196
197  -cache-file | --cache-file | --cache-fil | --cache-fi \
198  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
199    ac_prev=cache_file ;;
200  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
201  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
202    cache_file="$ac_optarg" ;;
203
204  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
205    ac_prev=datadir ;;
206  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
207  | --da=*)
208    datadir="$ac_optarg" ;;
209
210  -disable-* | --disable-*)
211    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
212    # Reject names that are not valid shell variable names.
213    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
214      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
215    fi
216    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
217    eval "enable_${ac_feature}=no" ;;
218
219  -enable-* | --enable-*)
220    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
221    # Reject names that are not valid shell variable names.
222    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
223      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
224    fi
225    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
226    case "$ac_option" in
227      *=*) ;;
228      *) ac_optarg=yes ;;
229    esac
230    eval "enable_${ac_feature}='$ac_optarg'" ;;
231
232  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
233  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
234  | --exec | --exe | --ex)
235    ac_prev=exec_prefix ;;
236  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
237  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
238  | --exec=* | --exe=* | --ex=*)
239    exec_prefix="$ac_optarg" ;;
240
241  -gas | --gas | --ga | --g)
242    # Obsolete; use --with-gas.
243    with_gas=yes ;;
244
245  -help | --help | --hel | --he)
246    # Omit some internal or obsolete options to make the list less imposing.
247    # This message is too long to be a string in the A/UX 3.1 sh.
248    cat << EOF
249Usage: configure [options] [host]
250Options: [defaults in brackets after descriptions]
251Configuration:
252  --cache-file=FILE       cache test results in FILE
253  --help                  print this message
254  --no-create             do not create output files
255  --quiet, --silent       do not print \`checking...' messages
256  --version               print the version of autoconf that created configure
257Directory and file names:
258  --prefix=PREFIX         install architecture-independent files in PREFIX
259                          [$ac_default_prefix]
260  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
261                          [same as prefix]
262  --bindir=DIR            user executables in DIR [EPREFIX/bin]
263  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
264  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
265  --datadir=DIR           read-only architecture-independent data in DIR
266                          [PREFIX/share]
267  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
268  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
269                          [PREFIX/com]
270  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
271  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
272  --includedir=DIR        C header files in DIR [PREFIX/include]
273  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
274  --infodir=DIR           info documentation in DIR [PREFIX/info]
275  --mandir=DIR            man documentation in DIR [PREFIX/man]
276  --srcdir=DIR            find the sources in DIR [configure dir or ..]
277  --program-prefix=PREFIX prepend PREFIX to installed program names
278  --program-suffix=SUFFIX append SUFFIX to installed program names
279  --program-transform-name=PROGRAM
280                          run sed PROGRAM on installed program names
281EOF
282    cat << EOF
283Host type:
284  --build=BUILD           configure for building on BUILD [BUILD=HOST]
285  --host=HOST             configure for HOST [guessed]
286  --target=TARGET         configure for TARGET [TARGET=HOST]
287Features and packages:
288  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
289  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
290  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
291  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
292  --x-includes=DIR        X include files are in DIR
293  --x-libraries=DIR       X library files are in DIR
294EOF
295    if test -n "$ac_help"; then
296      echo "--enable and --with options recognized:$ac_help"
297    fi
298    exit 0 ;;
299
300  -host | --host | --hos | --ho)
301    ac_prev=host ;;
302  -host=* | --host=* | --hos=* | --ho=*)
303    host="$ac_optarg" ;;
304
305  -includedir | --includedir | --includedi | --included | --include \
306  | --includ | --inclu | --incl | --inc)
307    ac_prev=includedir ;;
308  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
309  | --includ=* | --inclu=* | --incl=* | --inc=*)
310    includedir="$ac_optarg" ;;
311
312  -infodir | --infodir | --infodi | --infod | --info | --inf)
313    ac_prev=infodir ;;
314  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
315    infodir="$ac_optarg" ;;
316
317  -libdir | --libdir | --libdi | --libd)
318    ac_prev=libdir ;;
319  -libdir=* | --libdir=* | --libdi=* | --libd=*)
320    libdir="$ac_optarg" ;;
321
322  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
323  | --libexe | --libex | --libe)
324    ac_prev=libexecdir ;;
325  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
326  | --libexe=* | --libex=* | --libe=*)
327    libexecdir="$ac_optarg" ;;
328
329  -localstatedir | --localstatedir | --localstatedi | --localstated \
330  | --localstate | --localstat | --localsta | --localst \
331  | --locals | --local | --loca | --loc | --lo)
332    ac_prev=localstatedir ;;
333  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
334  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
335  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
336    localstatedir="$ac_optarg" ;;
337
338  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
339    ac_prev=mandir ;;
340  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
341    mandir="$ac_optarg" ;;
342
343  -nfp | --nfp | --nf)
344    # Obsolete; use --without-fp.
345    with_fp=no ;;
346
347  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
348  | --no-cr | --no-c)
349    no_create=yes ;;
350
351  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
352  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
353    no_recursion=yes ;;
354
355  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
356  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
357  | --oldin | --oldi | --old | --ol | --o)
358    ac_prev=oldincludedir ;;
359  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
360  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
361  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
362    oldincludedir="$ac_optarg" ;;
363
364  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
365    ac_prev=prefix ;;
366  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
367    prefix="$ac_optarg" ;;
368
369  -program-prefix | --program-prefix | --program-prefi | --program-pref \
370  | --program-pre | --program-pr | --program-p)
371    ac_prev=program_prefix ;;
372  -program-prefix=* | --program-prefix=* | --program-prefi=* \
373  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
374    program_prefix="$ac_optarg" ;;
375
376  -program-suffix | --program-suffix | --program-suffi | --program-suff \
377  | --program-suf | --program-su | --program-s)
378    ac_prev=program_suffix ;;
379  -program-suffix=* | --program-suffix=* | --program-suffi=* \
380  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
381    program_suffix="$ac_optarg" ;;
382
383  -program-transform-name | --program-transform-name \
384  | --program-transform-nam | --program-transform-na \
385  | --program-transform-n | --program-transform- \
386  | --program-transform | --program-transfor \
387  | --program-transfo | --program-transf \
388  | --program-trans | --program-tran \
389  | --progr-tra | --program-tr | --program-t)
390    ac_prev=program_transform_name ;;
391  -program-transform-name=* | --program-transform-name=* \
392  | --program-transform-nam=* | --program-transform-na=* \
393  | --program-transform-n=* | --program-transform-=* \
394  | --program-transform=* | --program-transfor=* \
395  | --program-transfo=* | --program-transf=* \
396  | --program-trans=* | --program-tran=* \
397  | --progr-tra=* | --program-tr=* | --program-t=*)
398    program_transform_name="$ac_optarg" ;;
399
400  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
401  | -silent | --silent | --silen | --sile | --sil)
402    silent=yes ;;
403
404  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
405    ac_prev=sbindir ;;
406  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
407  | --sbi=* | --sb=*)
408    sbindir="$ac_optarg" ;;
409
410  -sharedstatedir | --sharedstatedir | --sharedstatedi \
411  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
412  | --sharedst | --shareds | --shared | --share | --shar \
413  | --sha | --sh)
414    ac_prev=sharedstatedir ;;
415  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
416  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
417  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
418  | --sha=* | --sh=*)
419    sharedstatedir="$ac_optarg" ;;
420
421  -site | --site | --sit)
422    ac_prev=site ;;
423  -site=* | --site=* | --sit=*)
424    site="$ac_optarg" ;;
425
426  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
427    ac_prev=srcdir ;;
428  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
429    srcdir="$ac_optarg" ;;
430
431  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
432  | --syscon | --sysco | --sysc | --sys | --sy)
433    ac_prev=sysconfdir ;;
434  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
435  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
436    sysconfdir="$ac_optarg" ;;
437
438  -target | --target | --targe | --targ | --tar | --ta | --t)
439    ac_prev=target ;;
440  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
441    target="$ac_optarg" ;;
442
443  -v | -verbose | --verbose | --verbos | --verbo | --verb)
444    verbose=yes ;;
445
446  -version | --version | --versio | --versi | --vers)
447    echo "configure generated by autoconf version 2.13"
448    exit 0 ;;
449
450  -with-* | --with-*)
451    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
452    # Reject names that are not valid shell variable names.
453    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
454      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
455    fi
456    ac_package=`echo $ac_package| sed 's/-/_/g'`
457    case "$ac_option" in
458      *=*) ;;
459      *) ac_optarg=yes ;;
460    esac
461    eval "with_${ac_package}='$ac_optarg'" ;;
462
463  -without-* | --without-*)
464    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
465    # Reject names that are not valid shell variable names.
466    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
467      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
468    fi
469    ac_package=`echo $ac_package| sed 's/-/_/g'`
470    eval "with_${ac_package}=no" ;;
471
472  --x)
473    # Obsolete; use --with-x.
474    with_x=yes ;;
475
476  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
477  | --x-incl | --x-inc | --x-in | --x-i)
478    ac_prev=x_includes ;;
479  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
480  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
481    x_includes="$ac_optarg" ;;
482
483  -x-libraries | --x-libraries | --x-librarie | --x-librari \
484  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
485    ac_prev=x_libraries ;;
486  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
487  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
488    x_libraries="$ac_optarg" ;;
489
490  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
491    ;;
492
493  *)
494    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
495      echo "configure: warning: $ac_option: invalid host type" 1>&2
496    fi
497    if test "x$nonopt" != xNONE; then
498      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
499    fi
500    nonopt="$ac_option"
501    ;;
502
503  esac
504done
505
506if test -n "$ac_prev"; then
507  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
508fi
509
510trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
511
512# File descriptor usage:
513# 0 standard input
514# 1 file creation
515# 2 errors and warnings
516# 3 some systems may open it to /dev/tty
517# 4 used on the Kubota Titan
518# 6 checking for... messages and results
519# 5 compiler messages saved in config.log
520if test "$silent" = yes; then
521  exec 6>/dev/null
522else
523  exec 6>&1
524fi
525exec 5>./config.log
526
527echo "\
528This file contains any messages produced by compilers while
529running configure, to aid debugging if configure makes a mistake.
530" 1>&5
531
532# Strip out --no-create and --no-recursion so they do not pile up.
533# Also quote any args containing shell metacharacters.
534ac_configure_args=
535for ac_arg
536do
537  case "$ac_arg" in
538  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
539  | --no-cr | --no-c) ;;
540  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
541  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
542  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
543  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
544  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
545  esac
546done
547
548# NLS nuisances.
549# Only set these to C if already set.  These must not be set unconditionally
550# because not all systems understand e.g. LANG=C (notably SCO).
551# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
552# Non-C LC_CTYPE values break the ctype check.
553if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
554if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
555if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
556if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
557
558# confdefs.h avoids OS command line length limits that DEFS can exceed.
559rm -rf conftest* confdefs.h
560# AIX cpp loses on an empty file, so make sure it contains at least a newline.
561echo > confdefs.h
562
563# A filename unique to this package, relative to the directory that
564# configure is in, which we can look for to find out if srcdir is correct.
565ac_unique_file=vpath.c
566
567# Find the source files, if location was not specified.
568if test -z "$srcdir"; then
569  ac_srcdir_defaulted=yes
570  # Try the directory containing this script, then its parent.
571  ac_prog=$0
572  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
573  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
574  srcdir=$ac_confdir
575  if test ! -r $srcdir/$ac_unique_file; then
576    srcdir=..
577  fi
578else
579  ac_srcdir_defaulted=no
580fi
581if test ! -r $srcdir/$ac_unique_file; then
582  if test "$ac_srcdir_defaulted" = yes; then
583    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
584  else
585    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
586  fi
587fi
588srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
589
590# Prefer explicitly selected file to automatically selected ones.
591if test -z "$CONFIG_SITE"; then
592  if test "x$prefix" != xNONE; then
593    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
594  else
595    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
596  fi
597fi
598for ac_site_file in $CONFIG_SITE; do
599  if test -r "$ac_site_file"; then
600    echo "loading site script $ac_site_file"
601    . "$ac_site_file"
602  fi
603done
604
605if test -r "$cache_file"; then
606  echo "loading cache $cache_file"
607  . $cache_file
608else
609  echo "creating cache $cache_file"
610  > $cache_file
611fi
612
613ac_ext=c
614# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
615ac_cpp='$CPP $CPPFLAGS'
616ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
617ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
618cross_compiling=$ac_cv_prog_cc_cross
619
620ac_exeext=
621ac_objext=o
622if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
623  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
624  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
625    ac_n= ac_c='
626' ac_t='        '
627  else
628    ac_n=-n ac_c= ac_t=
629  fi
630else
631  ac_n= ac_c='\c' ac_t=
632fi
633
634
635ac_aux_dir=
636for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
637  if test -f $ac_dir/install-sh; then
638    ac_aux_dir=$ac_dir
639    ac_install_sh="$ac_aux_dir/install-sh -c"
640    break
641  elif test -f $ac_dir/install.sh; then
642    ac_aux_dir=$ac_dir
643    ac_install_sh="$ac_aux_dir/install.sh -c"
644    break
645  fi
646done
647if test -z "$ac_aux_dir"; then
648  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
649fi
650ac_config_guess=$ac_aux_dir/config.guess
651ac_config_sub=$ac_aux_dir/config.sub
652ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
653
654# Find a good install program.  We prefer a C program (faster),
655# so one script is as good as another.  But avoid the broken or
656# incompatible versions:
657# SysV /etc/install, /usr/sbin/install
658# SunOS /usr/etc/install
659# IRIX /sbin/install
660# AIX /bin/install
661# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
662# AFS /usr/afsws/bin/install, which mishandles nonexistent args
663# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
664# ./install, which can be erroneously created by make from ./install.sh.
665echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
666echo "configure:667: checking for a BSD compatible install" >&5
667if test -z "$INSTALL"; then
668if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
669  echo $ac_n "(cached) $ac_c" 1>&6
670else
671    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
672  for ac_dir in $PATH; do
673    # Account for people who put trailing slashes in PATH elements.
674    case "$ac_dir/" in
675    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
676    *)
677      # OSF1 and SCO ODT 3.0 have their own names for install.
678      # Don't use installbsd from OSF since it installs stuff as root
679      # by default.
680      for ac_prog in ginstall scoinst install; do
681        if test -f $ac_dir/$ac_prog; then
682          if test $ac_prog = install &&
683            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
684            # AIX install.  It has an incompatible calling convention.
685            :
686          else
687            ac_cv_path_install="$ac_dir/$ac_prog -c"
688            break 2
689          fi
690        fi
691      done
692      ;;
693    esac
694  done
695  IFS="$ac_save_IFS"
696
697fi
698  if test "${ac_cv_path_install+set}" = set; then
699    INSTALL="$ac_cv_path_install"
700  else
701    # As a last resort, use the slow shell script.  We don't cache a
702    # path for INSTALL within a source directory, because that will
703    # break other packages using the cache if that directory is
704    # removed, or if the path is relative.
705    INSTALL="$ac_install_sh"
706  fi
707fi
708echo "$ac_t""$INSTALL" 1>&6
709
710# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
711# It thinks the first close brace ends the variable substitution.
712test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
713
714test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
715
716test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
717
718echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
719echo "configure:720: checking whether build environment is sane" >&5
720# Just in case
721sleep 1
722echo timestamp > conftestfile
723# Do `set' in a subshell so we don't clobber the current shell's
724# arguments.  Must try -L first in case configure is actually a
725# symlink; some systems play weird games with the mod time of symlinks
726# (eg FreeBSD returns the mod time of the symlink's containing
727# directory).
728if (
729   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
730   if test "$*" = "X"; then
731      # -L didn't work.
732      set X `ls -t $srcdir/configure conftestfile`
733   fi
734   if test "$*" != "X $srcdir/configure conftestfile" \
735      && test "$*" != "X conftestfile $srcdir/configure"; then
736
737      # If neither matched, then we have a broken ls.  This can happen
738      # if, for instance, CONFIG_SHELL is bash and it inherits a
739      # broken ls alias from the environment.  This has actually
740      # happened.  Such a system could not be considered "sane".
741      { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
742alias in your environment" 1>&2; exit 1; }
743   fi
744
745   test "$2" = conftestfile
746   )
747then
748   # Ok.
749   :
750else
751   { echo "configure: error: newly created file is older than distributed files!
752Check your system clock" 1>&2; exit 1; }
753fi
754rm -f conftest*
755echo "$ac_t""yes" 1>&6
756if test "$program_transform_name" = s,x,x,; then
757  program_transform_name=
758else
759  # Double any \ or $.  echo might interpret backslashes.
760  cat <<\EOF_SED > conftestsed
761s,\\,\\\\,g; s,\$,$$,g
762EOF_SED
763  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
764  rm -f conftestsed
765fi
766test "$program_prefix" != NONE &&
767  program_transform_name="s,^,${program_prefix},; $program_transform_name"
768# Use a double $ so make ignores it.
769test "$program_suffix" != NONE &&
770  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
771
772# sed with no file args requires a program.
773test "$program_transform_name" = "" && program_transform_name="s,x,x,"
774
775echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
776echo "configure:777: checking whether ${MAKE-make} sets \${MAKE}" >&5
777set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
778if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
779  echo $ac_n "(cached) $ac_c" 1>&6
780else
781  cat > conftestmake <<\EOF
782all:
783        @echo 'ac_maketemp="${MAKE}"'
784EOF
785# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
786eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
787if test -n "$ac_maketemp"; then
788  eval ac_cv_prog_make_${ac_make}_set=yes
789else
790  eval ac_cv_prog_make_${ac_make}_set=no
791fi
792rm -f conftestmake
793fi
794if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
795  echo "$ac_t""yes" 1>&6
796  SET_MAKE=
797else
798  echo "$ac_t""no" 1>&6
799  SET_MAKE="MAKE=${MAKE-make}"
800fi
801
802
803PACKAGE=make
804
805VERSION=3.79.1
806
807if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
808  { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
809fi
810cat >> confdefs.h <<EOF
811#define PACKAGE "$PACKAGE"
812EOF
813
814cat >> confdefs.h <<EOF
815#define VERSION "$VERSION"
816EOF
817
818
819
820missing_dir=`cd $ac_aux_dir && pwd`
821echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
822echo "configure:823: checking for working aclocal" >&5
823# Run test in a subshell; some versions of sh will print an error if
824# an executable is not found, even if stderr is redirected.
825# Redirect stdin to placate older versions of autoconf.  Sigh.
826if (aclocal --version) < /dev/null > /dev/null 2>&1; then
827   ACLOCAL=aclocal
828   echo "$ac_t""found" 1>&6
829else
830   ACLOCAL="$missing_dir/missing aclocal"
831   echo "$ac_t""missing" 1>&6
832fi
833
834echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
835echo "configure:836: checking for working autoconf" >&5
836# Run test in a subshell; some versions of sh will print an error if
837# an executable is not found, even if stderr is redirected.
838# Redirect stdin to placate older versions of autoconf.  Sigh.
839if (autoconf --version) < /dev/null > /dev/null 2>&1; then
840   AUTOCONF=autoconf
841   echo "$ac_t""found" 1>&6
842else
843   AUTOCONF="$missing_dir/missing autoconf"
844   echo "$ac_t""missing" 1>&6
845fi
846
847echo $ac_n "checking for working automake""... $ac_c" 1>&6
848echo "configure:849: checking for working automake" >&5
849# Run test in a subshell; some versions of sh will print an error if
850# an executable is not found, even if stderr is redirected.
851# Redirect stdin to placate older versions of autoconf.  Sigh.
852if (automake --version) < /dev/null > /dev/null 2>&1; then
853   AUTOMAKE=automake
854   echo "$ac_t""found" 1>&6
855else
856   AUTOMAKE="$missing_dir/missing automake"
857   echo "$ac_t""missing" 1>&6
858fi
859
860echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
861echo "configure:862: checking for working autoheader" >&5
862# Run test in a subshell; some versions of sh will print an error if
863# an executable is not found, even if stderr is redirected.
864# Redirect stdin to placate older versions of autoconf.  Sigh.
865if (autoheader --version) < /dev/null > /dev/null 2>&1; then
866   AUTOHEADER=autoheader
867   echo "$ac_t""found" 1>&6
868else
869   AUTOHEADER="$missing_dir/missing autoheader"
870   echo "$ac_t""missing" 1>&6
871fi
872
873echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
874echo "configure:875: checking for working makeinfo" >&5
875# Run test in a subshell; some versions of sh will print an error if
876# an executable is not found, even if stderr is redirected.
877# Redirect stdin to placate older versions of autoconf.  Sigh.
878if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
879   MAKEINFO=makeinfo
880   echo "$ac_t""found" 1>&6
881else
882   MAKEINFO="$missing_dir/missing makeinfo"
883   echo "$ac_t""missing" 1>&6
884fi
885
886
887
888
889
890
891
892
893# Make sure we can run config.sub.
894if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
895else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
896fi
897
898echo $ac_n "checking host system type""... $ac_c" 1>&6
899echo "configure:900: checking host system type" >&5
900
901host_alias=$host
902case "$host_alias" in
903NONE)
904  case $nonopt in
905  NONE)
906    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
907    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
908    fi ;;
909  *) host_alias=$nonopt ;;
910  esac ;;
911esac
912
913host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
914host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
915host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
916host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
917echo "$ac_t""$host" 1>&6
918
919echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
920echo "configure:921: checking whether ${MAKE-make} sets \${MAKE}" >&5
921set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
922if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
923  echo $ac_n "(cached) $ac_c" 1>&6
924else
925  cat > conftestmake <<\EOF
926all:
927        @echo 'ac_maketemp="${MAKE}"'
928EOF
929# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
930eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
931if test -n "$ac_maketemp"; then
932  eval ac_cv_prog_make_${ac_make}_set=yes
933else
934  eval ac_cv_prog_make_${ac_make}_set=no
935fi
936rm -f conftestmake
937fi
938if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
939  echo "$ac_t""yes" 1>&6
940  SET_MAKE=
941else
942  echo "$ac_t""no" 1>&6
943  SET_MAKE="MAKE=${MAKE-make}"
944fi
945
946# Extract the first word of "gcc", so it can be a program name with args.
947set dummy gcc; ac_word=$2
948echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
949echo "configure:950: checking for $ac_word" >&5
950if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
951  echo $ac_n "(cached) $ac_c" 1>&6
952else
953  if test -n "$CC"; then
954  ac_cv_prog_CC="$CC" # Let the user override the test.
955else
956  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
957  ac_dummy="$PATH"
958  for ac_dir in $ac_dummy; do
959    test -z "$ac_dir" && ac_dir=.
960    if test -f $ac_dir/$ac_word; then
961      ac_cv_prog_CC="gcc"
962      break
963    fi
964  done
965  IFS="$ac_save_ifs"
966fi
967fi
968CC="$ac_cv_prog_CC"
969if test -n "$CC"; then
970  echo "$ac_t""$CC" 1>&6
971else
972  echo "$ac_t""no" 1>&6
973fi
974
975if test -z "$CC"; then
976  # Extract the first word of "cc", so it can be a program name with args.
977set dummy cc; ac_word=$2
978echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
979echo "configure:980: checking for $ac_word" >&5
980if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
981  echo $ac_n "(cached) $ac_c" 1>&6
982else
983  if test -n "$CC"; then
984  ac_cv_prog_CC="$CC" # Let the user override the test.
985else
986  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
987  ac_prog_rejected=no
988  ac_dummy="$PATH"
989  for ac_dir in $ac_dummy; do
990    test -z "$ac_dir" && ac_dir=.
991    if test -f $ac_dir/$ac_word; then
992      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
993        ac_prog_rejected=yes
994        continue
995      fi
996      ac_cv_prog_CC="cc"
997      break
998    fi
999  done
1000  IFS="$ac_save_ifs"
1001if test $ac_prog_rejected = yes; then
1002  # We found a bogon in the path, so make sure we never use it.
1003  set dummy $ac_cv_prog_CC
1004  shift
1005  if test $# -gt 0; then
1006    # We chose a different compiler from the bogus one.
1007    # However, it has the same basename, so the bogon will be chosen
1008    # first if we set CC to just the basename; use the full file name.
1009    shift
1010    set dummy "$ac_dir/$ac_word" "$@"
1011    shift
1012    ac_cv_prog_CC="$@"
1013  fi
1014fi
1015fi
1016fi
1017CC="$ac_cv_prog_CC"
1018if test -n "$CC"; then
1019  echo "$ac_t""$CC" 1>&6
1020else
1021  echo "$ac_t""no" 1>&6
1022fi
1023
1024  if test -z "$CC"; then
1025    case "`uname -s`" in
1026    *win32* | *WIN32*)
1027      # Extract the first word of "cl", so it can be a program name with args.
1028set dummy cl; ac_word=$2
1029echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1030echo "configure:1031: checking for $ac_word" >&5
1031if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1032  echo $ac_n "(cached) $ac_c" 1>&6
1033else
1034  if test -n "$CC"; then
1035  ac_cv_prog_CC="$CC" # Let the user override the test.
1036else
1037  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1038  ac_dummy="$PATH"
1039  for ac_dir in $ac_dummy; do
1040    test -z "$ac_dir" && ac_dir=.
1041    if test -f $ac_dir/$ac_word; then
1042      ac_cv_prog_CC="cl"
1043      break
1044    fi
1045  done
1046  IFS="$ac_save_ifs"
1047fi
1048fi
1049CC="$ac_cv_prog_CC"
1050if test -n "$CC"; then
1051  echo "$ac_t""$CC" 1>&6
1052else
1053  echo "$ac_t""no" 1>&6
1054fi
1055 ;;
1056    esac
1057  fi
1058  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1059fi
1060
1061echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1062echo "configure:1063: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1063
1064ac_ext=c
1065# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1066ac_cpp='$CPP $CPPFLAGS'
1067ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1068ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1069cross_compiling=$ac_cv_prog_cc_cross
1070
1071cat > conftest.$ac_ext << EOF
1072
1073#line 1074 "configure"
1074#include "confdefs.h"
1075
1076main(){return(0);}
1077EOF
1078if { (eval echo configure:1079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1079  ac_cv_prog_cc_works=yes
1080  # If we can't run a trivial program, we are probably using a cross compiler.
1081  if (./conftest; exit) 2>/dev/null; then
1082    ac_cv_prog_cc_cross=no
1083  else
1084    ac_cv_prog_cc_cross=yes
1085  fi
1086else
1087  echo "configure: failed program was:" >&5
1088  cat conftest.$ac_ext >&5
1089  ac_cv_prog_cc_works=no
1090fi
1091rm -fr conftest*
1092ac_ext=c
1093# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1094ac_cpp='$CPP $CPPFLAGS'
1095ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1096ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1097cross_compiling=$ac_cv_prog_cc_cross
1098
1099echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1100if test $ac_cv_prog_cc_works = no; then
1101  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1102fi
1103echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1104echo "configure:1105: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1105echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1106cross_compiling=$ac_cv_prog_cc_cross
1107
1108echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1109echo "configure:1110: checking whether we are using GNU C" >&5
1110if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1111  echo $ac_n "(cached) $ac_c" 1>&6
1112else
1113  cat > conftest.c <<EOF
1114#ifdef __GNUC__
1115  yes;
1116#endif
1117EOF
1118if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1119: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1119  ac_cv_prog_gcc=yes
1120else
1121  ac_cv_prog_gcc=no
1122fi
1123fi
1124
1125echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1126
1127if test $ac_cv_prog_gcc = yes; then
1128  GCC=yes
1129else
1130  GCC=
1131fi
1132
1133ac_test_CFLAGS="${CFLAGS+set}"
1134ac_save_CFLAGS="$CFLAGS"
1135CFLAGS=
1136echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1137echo "configure:1138: checking whether ${CC-cc} accepts -g" >&5
1138if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1139  echo $ac_n "(cached) $ac_c" 1>&6
1140else
1141  echo 'void f(){}' > conftest.c
1142if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1143  ac_cv_prog_cc_g=yes
1144else
1145  ac_cv_prog_cc_g=no
1146fi
1147rm -f conftest*
1148
1149fi
1150
1151echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1152if test "$ac_test_CFLAGS" = set; then
1153  CFLAGS="$ac_save_CFLAGS"
1154elif test $ac_cv_prog_cc_g = yes; then
1155  if test "$GCC" = yes; then
1156    CFLAGS="-g -O2"
1157  else
1158    CFLAGS="-g"
1159  fi
1160else
1161  if test "$GCC" = yes; then
1162    CFLAGS="-O2"
1163  else
1164    CFLAGS=
1165  fi
1166fi
1167
1168# Find a good install program.  We prefer a C program (faster),
1169# so one script is as good as another.  But avoid the broken or
1170# incompatible versions:
1171# SysV /etc/install, /usr/sbin/install
1172# SunOS /usr/etc/install
1173# IRIX /sbin/install
1174# AIX /bin/install
1175# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1176# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1177# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1178# ./install, which can be erroneously created by make from ./install.sh.
1179echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1180echo "configure:1181: checking for a BSD compatible install" >&5
1181if test -z "$INSTALL"; then
1182if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1183  echo $ac_n "(cached) $ac_c" 1>&6
1184else
1185    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
1186  for ac_dir in $PATH; do
1187    # Account for people who put trailing slashes in PATH elements.
1188    case "$ac_dir/" in
1189    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1190    *)
1191      # OSF1 and SCO ODT 3.0 have their own names for install.
1192      # Don't use installbsd from OSF since it installs stuff as root
1193      # by default.
1194      for ac_prog in ginstall scoinst install; do
1195        if test -f $ac_dir/$ac_prog; then
1196          if test $ac_prog = install &&
1197            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1198            # AIX install.  It has an incompatible calling convention.
1199            :
1200          else
1201            ac_cv_path_install="$ac_dir/$ac_prog -c"
1202            break 2
1203          fi
1204        fi
1205      done
1206      ;;
1207    esac
1208  done
1209  IFS="$ac_save_IFS"
1210
1211fi
1212  if test "${ac_cv_path_install+set}" = set; then
1213    INSTALL="$ac_cv_path_install"
1214  else
1215    # As a last resort, use the slow shell script.  We don't cache a
1216    # path for INSTALL within a source directory, because that will
1217    # break other packages using the cache if that directory is
1218    # removed, or if the path is relative.
1219    INSTALL="$ac_install_sh"
1220  fi
1221fi
1222echo "$ac_t""$INSTALL" 1>&6
1223
1224# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1225# It thinks the first close brace ends the variable substitution.
1226test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1227
1228test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1229
1230test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1231
1232# Extract the first word of "ar", so it can be a program name with args.
1233set dummy ar; ac_word=$2
1234echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1235echo "configure:1236: checking for $ac_word" >&5
1236if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
1237  echo $ac_n "(cached) $ac_c" 1>&6
1238else
1239  if test -n "$AR"; then
1240  ac_cv_prog_AR="$AR" # Let the user override the test.
1241else
1242  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1243  ac_dummy="$PATH"
1244  for ac_dir in $ac_dummy; do
1245    test -z "$ac_dir" && ac_dir=.
1246    if test -f $ac_dir/$ac_word; then
1247      ac_cv_prog_AR="ar"
1248      break
1249    fi
1250  done
1251  IFS="$ac_save_ifs"
1252  test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
1253fi
1254fi
1255AR="$ac_cv_prog_AR"
1256if test -n "$AR"; then
1257  echo "$ac_t""$AR" 1>&6
1258else
1259  echo "$ac_t""no" 1>&6
1260fi
1261
1262# Extract the first word of "ranlib", so it can be a program name with args.
1263set dummy ranlib; ac_word=$2
1264echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1265echo "configure:1266: checking for $ac_word" >&5
1266if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1267  echo $ac_n "(cached) $ac_c" 1>&6
1268else
1269  if test -n "$RANLIB"; then
1270  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1271else
1272  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1273  ac_dummy="$PATH"
1274  for ac_dir in $ac_dummy; do
1275    test -z "$ac_dir" && ac_dir=.
1276    if test -f $ac_dir/$ac_word; then
1277      ac_cv_prog_RANLIB="ranlib"
1278      break
1279    fi
1280  done
1281  IFS="$ac_save_ifs"
1282  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1283fi
1284fi
1285RANLIB="$ac_cv_prog_RANLIB"
1286if test -n "$RANLIB"; then
1287  echo "$ac_t""$RANLIB" 1>&6
1288else
1289  echo "$ac_t""no" 1>&6
1290fi
1291
1292echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1293echo "configure:1294: checking how to run the C preprocessor" >&5
1294# On Suns, sometimes $CPP names a directory.
1295if test -n "$CPP" && test -d "$CPP"; then
1296  CPP=
1297fi
1298if test -z "$CPP"; then
1299if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1300  echo $ac_n "(cached) $ac_c" 1>&6
1301else
1302    # This must be in double quotes, not single quotes, because CPP may get
1303  # substituted into the Makefile and "${CC-cc}" will confuse make.
1304  CPP="${CC-cc} -E"
1305  # On the NeXT, cc -E runs the code through the compiler's parser,
1306  # not just through cpp.
1307  cat > conftest.$ac_ext <<EOF
1308#line 1309 "configure"
1309#include "confdefs.h"
1310#include <assert.h>
1311Syntax Error
1312EOF
1313ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1314{ (eval echo configure:1315: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1315ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1316if test -z "$ac_err"; then
1317  :
1318else
1319  echo "$ac_err" >&5
1320  echo "configure: failed program was:" >&5
1321  cat conftest.$ac_ext >&5
1322  rm -rf conftest*
1323  CPP="${CC-cc} -E -traditional-cpp"
1324  cat > conftest.$ac_ext <<EOF
1325#line 1326 "configure"
1326#include "confdefs.h"
1327#include <assert.h>
1328Syntax Error
1329EOF
1330ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1331{ (eval echo configure:1332: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1332ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1333if test -z "$ac_err"; then
1334  :
1335else
1336  echo "$ac_err" >&5
1337  echo "configure: failed program was:" >&5
1338  cat conftest.$ac_ext >&5
1339  rm -rf conftest*
1340  CPP="${CC-cc} -nologo -E"
1341  cat > conftest.$ac_ext <<EOF
1342#line 1343 "configure"
1343#include "confdefs.h"
1344#include <assert.h>
1345Syntax Error
1346EOF
1347ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1348{ (eval echo configure:1349: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1349ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1350if test -z "$ac_err"; then
1351  :
1352else
1353  echo "$ac_err" >&5
1354  echo "configure: failed program was:" >&5
1355  cat conftest.$ac_ext >&5
1356  rm -rf conftest*
1357  CPP=/lib/cpp
1358fi
1359rm -f conftest*
1360fi
1361rm -f conftest*
1362fi
1363rm -f conftest*
1364  ac_cv_prog_CPP="$CPP"
1365fi
1366  CPP="$ac_cv_prog_CPP"
1367else
1368  ac_cv_prog_CPP="$CPP"
1369fi
1370echo "$ac_t""$CPP" 1>&6
1371                        echo $ac_n "checking for AIX""... $ac_c" 1>&6
1372echo "configure:1373: checking for AIX" >&5
1373cat > conftest.$ac_ext <<EOF
1374#line 1375 "configure"
1375#include "confdefs.h"
1376#ifdef _AIX
1377  yes
1378#endif
1379
1380EOF
1381if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1382  egrep "yes" >/dev/null 2>&1; then
1383  rm -rf conftest*
1384  echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
1385#define _ALL_SOURCE 1
1386EOF
1387
1388else
1389  rm -rf conftest*
1390  echo "$ac_t""no" 1>&6
1391fi
1392rm -f conftest*
1393
1394
1395echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
1396echo "configure:1397: checking for POSIXized ISC" >&5
1397if test -d /etc/conf/kconfig.d &&
1398  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1399then
1400  echo "$ac_t""yes" 1>&6
1401  ISC=yes # If later tests want to check for ISC.
1402  cat >> confdefs.h <<\EOF
1403#define _POSIX_SOURCE 1
1404EOF
1405
1406  if test "$GCC" = yes; then
1407    CC="$CC -posix"
1408  else
1409    CC="$CC -Xp"
1410  fi
1411else
1412  echo "$ac_t""no" 1>&6
1413  ISC=
1414fi
1415
1416ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
1417echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
1418echo "configure:1419: checking for minix/config.h" >&5
1419if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1420  echo $ac_n "(cached) $ac_c" 1>&6
1421else
1422  cat > conftest.$ac_ext <<EOF
1423#line 1424 "configure"
1424#include "confdefs.h"
1425#include <minix/config.h>
1426EOF
1427ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1428{ (eval echo configure:1429: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1429ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1430if test -z "$ac_err"; then
1431  rm -rf conftest*
1432  eval "ac_cv_header_$ac_safe=yes"
1433else
1434  echo "$ac_err" >&5
1435  echo "configure: failed program was:" >&5
1436  cat conftest.$ac_ext >&5
1437  rm -rf conftest*
1438  eval "ac_cv_header_$ac_safe=no"
1439fi
1440rm -f conftest*
1441fi
1442if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1443  echo "$ac_t""yes" 1>&6
1444  MINIX=yes
1445else
1446  echo "$ac_t""no" 1>&6
1447MINIX=
1448fi
1449
1450if test "$MINIX" = yes; then
1451  cat >> confdefs.h <<\EOF
1452#define _POSIX_SOURCE 1
1453EOF
1454
1455  cat >> confdefs.h <<\EOF
1456#define _POSIX_1_SOURCE 2
1457EOF
1458
1459  cat >> confdefs.h <<\EOF
1460#define _MINIX 1
1461EOF
1462
1463fi
1464
1465
1466# Extract the first word of "perl", so it can be a program name with args.
1467set dummy perl; ac_word=$2
1468echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1469echo "configure:1470: checking for $ac_word" >&5
1470if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then
1471  echo $ac_n "(cached) $ac_c" 1>&6
1472else
1473  if test -n "$PERL"; then
1474  ac_cv_prog_PERL="$PERL" # Let the user override the test.
1475else
1476  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1477  ac_dummy="$PATH"
1478  for ac_dir in $ac_dummy; do
1479    test -z "$ac_dir" && ac_dir=.
1480    if test -f $ac_dir/$ac_word; then
1481      ac_cv_prog_PERL="perl"
1482      break
1483    fi
1484  done
1485  IFS="$ac_save_ifs"
1486  test -z "$ac_cv_prog_PERL" && ac_cv_prog_PERL="perl"
1487fi
1488fi
1489PERL="$ac_cv_prog_PERL"
1490if test -n "$PERL"; then
1491  echo "$ac_t""$PERL" 1>&6
1492else
1493  echo "$ac_t""no" 1>&6
1494fi
1495       
1496echo $ac_n "checking build system type""... $ac_c" 1>&6
1497echo "configure:1498: checking build system type" >&5
1498
1499build_alias=$build
1500case "$build_alias" in
1501NONE)
1502  case $nonopt in
1503  NONE) build_alias=$host_alias ;;
1504  *) build_alias=$nonopt ;;
1505  esac ;;
1506esac
1507
1508build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
1509build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1510build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1511build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1512echo "$ac_t""$build" 1>&6
1513
1514if test $host != $build; then
1515  ac_tool_prefix=${host_alias}-
1516else
1517  ac_tool_prefix=
1518fi
1519
1520
1521   # Check whether --enable-largefile or --disable-largefile was given.
1522if test "${enable_largefile+set}" = set; then
1523  enableval="$enable_largefile"
1524  :
1525fi
1526
1527   if test "$enable_largefile" != no; then
1528     # Extract the first word of "${ac_tool_prefix}getconf", so it can be a program name with args.
1529set dummy ${ac_tool_prefix}getconf; ac_word=$2
1530echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1531echo "configure:1532: checking for $ac_word" >&5
1532if eval "test \"`echo '$''{'ac_cv_prog_GETCONF'+set}'`\" = set"; then
1533  echo $ac_n "(cached) $ac_c" 1>&6
1534else
1535  if test -n "$GETCONF"; then
1536  ac_cv_prog_GETCONF="$GETCONF" # Let the user override the test.
1537else
1538  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1539  ac_dummy="$PATH"
1540  for ac_dir in $ac_dummy; do
1541    test -z "$ac_dir" && ac_dir=.
1542    if test -f $ac_dir/$ac_word; then
1543      ac_cv_prog_GETCONF="${ac_tool_prefix}getconf"
1544      break
1545    fi
1546  done
1547  IFS="$ac_save_ifs"
1548  test -z "$ac_cv_prog_GETCONF" && ac_cv_prog_GETCONF="getconf"
1549fi
1550fi
1551GETCONF="$ac_cv_prog_GETCONF"
1552if test -n "$GETCONF"; then
1553  echo "$ac_t""$GETCONF" 1>&6
1554else
1555  echo "$ac_t""no" 1>&6
1556fi
1557
1558
1559
1560     echo $ac_n "checking for CFLAGS value to request large file support""... $ac_c" 1>&6
1561echo "configure:1562: checking for CFLAGS value to request large file support" >&5
1562if eval "test \"`echo '$''{'ac_cv_sys_largefile_CFLAGS'+set}'`\" = set"; then
1563  echo $ac_n "(cached) $ac_c" 1>&6
1564else
1565  if ($GETCONF LFS_CFLAGS) >conftest.1 2>conftest.2 && test ! -s conftest.2
1566      then
1567        ac_cv_sys_largefile_CFLAGS=`cat conftest.1`
1568      else
1569        ac_cv_sys_largefile_CFLAGS=no
1570        case "$host_os" in
1571           # HP-UX 10.20 requires -D__STDC_EXT__ with gcc 2.95.1.
1572           hpux10.[2-9][0-9]* | hpux1[1-9]* | hpux[2-9][0-9]*)
1573             if test "$GCC" = yes; then
1574               ac_cv_sys_largefile_CFLAGS=-D__STDC_EXT__
1575             fi
1576             ;;
1577           # IRIX 6.2 and later require cc -n32.
1578           irix6.[2-9]* | irix6.1[0-9]* | irix[7-9].* | irix[1-9][0-9]*)
1579             if test "$GCC" != yes; then
1580               ac_cv_sys_largefile_CFLAGS=-n32
1581             fi
1582           esac
1583           if test "$ac_cv_sys_largefile_CFLAGS" != no; then
1584             ac_save_CC="$CC"
1585             CC="$CC $ac_cv_sys_largefile_CFLAGS"
1586             cat > conftest.$ac_ext <<EOF
1587#line 1588 "configure"
1588#include "confdefs.h"
1589
1590int main() {
1591
1592; return 0; }
1593EOF
1594if { (eval echo configure:1595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1595  :
1596else
1597  echo "configure: failed program was:" >&5
1598  cat conftest.$ac_ext >&5
1599  rm -rf conftest*
1600  ac_cv_sys_largefile_CFLAGS=no
1601fi
1602rm -f conftest*
1603             CC="$ac_save_CC"
1604           fi
1605      fi
1606      rm -f conftest*
1607fi
1608
1609echo "$ac_t""$ac_cv_sys_largefile_CFLAGS" 1>&6
1610     echo $ac_n "checking for LDFLAGS value to request large file support""... $ac_c" 1>&6
1611echo "configure:1612: checking for LDFLAGS value to request large file support" >&5
1612if eval "test \"`echo '$''{'ac_cv_sys_largefile_LDFLAGS'+set}'`\" = set"; then
1613  echo $ac_n "(cached) $ac_c" 1>&6
1614else
1615  if ($GETCONF LFS_LDFLAGS) >conftest.1 2>conftest.2 && test ! -s conftest.2
1616      then
1617        ac_cv_sys_largefile_LDFLAGS=`cat conftest.1`
1618      else
1619        ac_cv_sys_largefile_LDFLAGS=no
1620       
1621      fi
1622      rm -f conftest*
1623fi
1624
1625echo "$ac_t""$ac_cv_sys_largefile_LDFLAGS" 1>&6
1626     echo $ac_n "checking for LIBS value to request large file support""... $ac_c" 1>&6
1627echo "configure:1628: checking for LIBS value to request large file support" >&5
1628if eval "test \"`echo '$''{'ac_cv_sys_largefile_LIBS'+set}'`\" = set"; then
1629  echo $ac_n "(cached) $ac_c" 1>&6
1630else
1631  if ($GETCONF LFS_LIBS) >conftest.1 2>conftest.2 && test ! -s conftest.2
1632      then
1633        ac_cv_sys_largefile_LIBS=`cat conftest.1`
1634      else
1635        ac_cv_sys_largefile_LIBS=no
1636       
1637      fi
1638      rm -f conftest*
1639fi
1640
1641echo "$ac_t""$ac_cv_sys_largefile_LIBS" 1>&6
1642
1643     for ac_flag in $ac_cv_sys_largefile_CFLAGS no; do
1644       case "$ac_flag" in
1645       no) ;;
1646       -D_FILE_OFFSET_BITS=*) ;;
1647       -D_LARGEFILE_SOURCE | -D_LARGEFILE_SOURCE=*) ;;
1648       -D_LARGE_FILES | -D_LARGE_FILES=*) ;;
1649       -D?* | -I?*)
1650         case "$ac_flag" in
1651   no) ;;
1652   ?*)
1653     case "$CPPFLAGS" in
1654     '') CPPFLAGS="$ac_flag" ;;
1655     *) CPPFLAGS=$CPPFLAGS' '"$ac_flag" ;;
1656     esac ;;
1657   esac ;;
1658       *)
1659         case "$ac_flag" in
1660   no) ;;
1661   ?*)
1662     case "$CFLAGS" in
1663     '') CFLAGS="$ac_flag" ;;
1664     *) CFLAGS=$CFLAGS' '"$ac_flag" ;;
1665     esac ;;
1666   esac ;;
1667       esac
1668     done
1669     case "$ac_cv_sys_largefile_LDFLAGS" in
1670   no) ;;
1671   ?*)
1672     case "$LDFLAGS" in
1673     '') LDFLAGS="$ac_cv_sys_largefile_LDFLAGS" ;;
1674     *) LDFLAGS=$LDFLAGS' '"$ac_cv_sys_largefile_LDFLAGS" ;;
1675     esac ;;
1676   esac
1677     case "$ac_cv_sys_largefile_LIBS" in
1678   no) ;;
1679   ?*)
1680     case "$LIBS" in
1681     '') LIBS="$ac_cv_sys_largefile_LIBS" ;;
1682     *) LIBS=$LIBS' '"$ac_cv_sys_largefile_LIBS" ;;
1683     esac ;;
1684   esac
1685     echo $ac_n "checking for _FILE_OFFSET_BITS""... $ac_c" 1>&6
1686echo "configure:1687: checking for _FILE_OFFSET_BITS" >&5
1687if eval "test \"`echo '$''{'ac_cv_sys_file_offset_bits'+set}'`\" = set"; then
1688  echo $ac_n "(cached) $ac_c" 1>&6
1689else
1690  ac_cv_sys_file_offset_bits=no
1691      case "$host_os" in
1692        # HP-UX 10.20 and later
1693        hpux10.[2-9][0-9]* | hpux1[1-9]* | hpux[2-9][0-9]*)
1694          ac_cv_sys_file_offset_bits=64 ;;
1695        esac
1696      for ac_flag in $ac_cv_sys_largefile_CFLAGS no; do
1697        case "$ac_flag" in
1698        -D_FILE_OFFSET_BITS)
1699          ac_cv_sys_file_offset_bits=1 ;;
1700        -D_FILE_OFFSET_BITS=*)
1701          ac_cv_sys_file_offset_bits=`expr " $ac_flag" : '[^=]*=\(.*\)'` ;;
1702        esac
1703      done
1704     
1705fi
1706
1707echo "$ac_t""$ac_cv_sys_file_offset_bits" 1>&6
1708   if test "$ac_cv_sys_file_offset_bits" != no; then
1709     cat >> confdefs.h <<EOF
1710#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
1711EOF
1712
1713   fi
1714     echo $ac_n "checking for _LARGEFILE_SOURCE""... $ac_c" 1>&6
1715echo "configure:1716: checking for _LARGEFILE_SOURCE" >&5
1716if eval "test \"`echo '$''{'ac_cv_sys_largefile_source'+set}'`\" = set"; then
1717  echo $ac_n "(cached) $ac_c" 1>&6
1718else
1719  ac_cv_sys_largefile_source=no
1720      case "$host_os" in
1721        # HP-UX 10.20 and later
1722        hpux10.[2-9][0-9]* | hpux1[1-9]* | hpux[2-9][0-9]*)
1723          ac_cv_sys_largefile_source=1 ;;
1724        esac
1725      for ac_flag in $ac_cv_sys_largefile_CFLAGS no; do
1726        case "$ac_flag" in
1727        -D_LARGEFILE_SOURCE)
1728          ac_cv_sys_largefile_source=1 ;;
1729        -D_LARGEFILE_SOURCE=*)
1730          ac_cv_sys_largefile_source=`expr " $ac_flag" : '[^=]*=\(.*\)'` ;;
1731        esac
1732      done
1733     
1734fi
1735
1736echo "$ac_t""$ac_cv_sys_largefile_source" 1>&6
1737   if test "$ac_cv_sys_largefile_source" != no; then
1738     cat >> confdefs.h <<EOF
1739#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
1740EOF
1741
1742   fi
1743     echo $ac_n "checking for _LARGE_FILES""... $ac_c" 1>&6
1744echo "configure:1745: checking for _LARGE_FILES" >&5
1745if eval "test \"`echo '$''{'ac_cv_sys_large_files'+set}'`\" = set"; then
1746  echo $ac_n "(cached) $ac_c" 1>&6
1747else
1748  ac_cv_sys_large_files=no
1749      case "$host_os" in
1750        # AIX 4.2 and later
1751        aix4.[2-9]* | aix4.1[0-9]* | aix[5-9].* | aix[1-9][0-9]*)
1752          ac_cv_sys_large_files=1 ;;
1753        esac
1754      for ac_flag in $ac_cv_sys_largefile_CFLAGS no; do
1755        case "$ac_flag" in
1756        -D_LARGE_FILES)
1757          ac_cv_sys_large_files=1 ;;
1758        -D_LARGE_FILES=*)
1759          ac_cv_sys_large_files=`expr " $ac_flag" : '[^=]*=\(.*\)'` ;;
1760        esac
1761      done
1762     
1763fi
1764
1765echo "$ac_t""$ac_cv_sys_large_files" 1>&6
1766   if test "$ac_cv_sys_large_files" != no; then
1767     cat >> confdefs.h <<EOF
1768#define _LARGE_FILES $ac_cv_sys_large_files
1769EOF
1770
1771   fi
1772   fi
1773 
1774
1775echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1776echo "configure:1777: checking for ANSI C header files" >&5
1777if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1778  echo $ac_n "(cached) $ac_c" 1>&6
1779else
1780  cat > conftest.$ac_ext <<EOF
1781#line 1782 "configure"
1782#include "confdefs.h"
1783#include <stdlib.h>
1784#include <stdarg.h>
1785#include <string.h>
1786#include <float.h>
1787EOF
1788ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1789{ (eval echo configure:1790: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1790ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1791if test -z "$ac_err"; then
1792  rm -rf conftest*
1793  ac_cv_header_stdc=yes
1794else
1795  echo "$ac_err" >&5
1796  echo "configure: failed program was:" >&5
1797  cat conftest.$ac_ext >&5
1798  rm -rf conftest*
1799  ac_cv_header_stdc=no
1800fi
1801rm -f conftest*
1802
1803if test $ac_cv_header_stdc = yes; then
1804  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1805cat > conftest.$ac_ext <<EOF
1806#line 1807 "configure"
1807#include "confdefs.h"
1808#include <string.h>
1809EOF
1810if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1811  egrep "memchr" >/dev/null 2>&1; then
1812  :
1813else
1814  rm -rf conftest*
1815  ac_cv_header_stdc=no
1816fi
1817rm -f conftest*
1818
1819fi
1820
1821if test $ac_cv_header_stdc = yes; then
1822  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1823cat > conftest.$ac_ext <<EOF
1824#line 1825 "configure"
1825#include "confdefs.h"
1826#include <stdlib.h>
1827EOF
1828if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1829  egrep "free" >/dev/null 2>&1; then
1830  :
1831else
1832  rm -rf conftest*
1833  ac_cv_header_stdc=no
1834fi
1835rm -f conftest*
1836
1837fi
1838
1839if test $ac_cv_header_stdc = yes; then
1840  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1841if test "$cross_compiling" = yes; then
1842  :
1843else
1844  cat > conftest.$ac_ext <<EOF
1845#line 1846 "configure"
1846#include "confdefs.h"
1847#include <ctype.h>
1848#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1849#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1850#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1851int main () { int i; for (i = 0; i < 256; i++)
1852if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1853exit (0); }
1854
1855EOF
1856if { (eval echo configure:1857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1857then
1858  :
1859else
1860  echo "configure: failed program was:" >&5
1861  cat conftest.$ac_ext >&5
1862  rm -fr conftest*
1863  ac_cv_header_stdc=no
1864fi
1865rm -fr conftest*
1866fi
1867
1868fi
1869fi
1870
1871echo "$ac_t""$ac_cv_header_stdc" 1>&6
1872if test $ac_cv_header_stdc = yes; then
1873  cat >> confdefs.h <<\EOF
1874#define STDC_HEADERS 1
1875EOF
1876
1877fi
1878
1879ac_header_dirent=no
1880for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1881do
1882ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1883echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1884echo "configure:1885: checking for $ac_hdr that defines DIR" >&5
1885if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1886  echo $ac_n "(cached) $ac_c" 1>&6
1887else
1888  cat > conftest.$ac_ext <<EOF
1889#line 1890 "configure"
1890#include "confdefs.h"
1891#include <sys/types.h>
1892#include <$ac_hdr>
1893int main() {
1894DIR *dirp = 0;
1895; return 0; }
1896EOF
1897if { (eval echo configure:1898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1898  rm -rf conftest*
1899  eval "ac_cv_header_dirent_$ac_safe=yes"
1900else
1901  echo "configure: failed program was:" >&5
1902  cat conftest.$ac_ext >&5
1903  rm -rf conftest*
1904  eval "ac_cv_header_dirent_$ac_safe=no"
1905fi
1906rm -f conftest*
1907fi
1908if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1909  echo "$ac_t""yes" 1>&6
1910    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1911  cat >> confdefs.h <<EOF
1912#define $ac_tr_hdr 1
1913EOF
1914 ac_header_dirent=$ac_hdr; break
1915else
1916  echo "$ac_t""no" 1>&6
1917fi
1918done
1919# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1920if test $ac_header_dirent = dirent.h; then
1921echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1922echo "configure:1923: checking for opendir in -ldir" >&5
1923ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1924if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1925  echo $ac_n "(cached) $ac_c" 1>&6
1926else
1927  ac_save_LIBS="$LIBS"
1928LIBS="-ldir  $LIBS"
1929cat > conftest.$ac_ext <<EOF
1930#line 1931 "configure"
1931#include "confdefs.h"
1932/* Override any gcc2 internal prototype to avoid an error.  */
1933/* We use char because int might match the return type of a gcc2
1934    builtin and then its argument prototype would still apply.  */
1935char opendir();
1936
1937int main() {
1938opendir()
1939; return 0; }
1940EOF
1941if { (eval echo configure:1942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1942  rm -rf conftest*
1943  eval "ac_cv_lib_$ac_lib_var=yes"
1944else
1945  echo "configure: failed program was:" >&5
1946  cat conftest.$ac_ext >&5
1947  rm -rf conftest*
1948  eval "ac_cv_lib_$ac_lib_var=no"
1949fi
1950rm -f conftest*
1951LIBS="$ac_save_LIBS"
1952
1953fi
1954if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1955  echo "$ac_t""yes" 1>&6
1956  LIBS="$LIBS -ldir"
1957else
1958  echo "$ac_t""no" 1>&6
1959fi
1960
1961else
1962echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1963echo "configure:1964: checking for opendir in -lx" >&5
1964ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1965if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1966  echo $ac_n "(cached) $ac_c" 1>&6
1967else
1968  ac_save_LIBS="$LIBS"
1969LIBS="-lx  $LIBS"
1970cat > conftest.$ac_ext <<EOF
1971#line 1972 "configure"
1972#include "confdefs.h"
1973/* Override any gcc2 internal prototype to avoid an error.  */
1974/* We use char because int might match the return type of a gcc2
1975    builtin and then its argument prototype would still apply.  */
1976char opendir();
1977
1978int main() {
1979opendir()
1980; return 0; }
1981EOF
1982if { (eval echo configure:1983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1983  rm -rf conftest*
1984  eval "ac_cv_lib_$ac_lib_var=yes"
1985else
1986  echo "configure: failed program was:" >&5
1987  cat conftest.$ac_ext >&5
1988  rm -rf conftest*
1989  eval "ac_cv_lib_$ac_lib_var=no"
1990fi
1991rm -f conftest*
1992LIBS="$ac_save_LIBS"
1993
1994fi
1995if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1996  echo "$ac_t""yes" 1>&6
1997  LIBS="$LIBS -lx"
1998else
1999  echo "$ac_t""no" 1>&6
2000fi
2001
2002fi
2003
2004echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
2005echo "configure:2006: checking for uid_t in sys/types.h" >&5
2006if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
2007  echo $ac_n "(cached) $ac_c" 1>&6
2008else
2009  cat > conftest.$ac_ext <<EOF
2010#line 2011 "configure"
2011#include "confdefs.h"
2012#include <sys/types.h>
2013EOF
2014if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2015  egrep "uid_t" >/dev/null 2>&1; then
2016  rm -rf conftest*
2017  ac_cv_type_uid_t=yes
2018else
2019  rm -rf conftest*
2020  ac_cv_type_uid_t=no
2021fi
2022rm -f conftest*
2023
2024fi
2025
2026echo "$ac_t""$ac_cv_type_uid_t" 1>&6
2027if test $ac_cv_type_uid_t = no; then
2028  cat >> confdefs.h <<\EOF
2029#define uid_t int
2030EOF
2031
2032  cat >> confdefs.h <<\EOF
2033#define gid_t int
2034EOF
2035
2036fi
2037                        echo $ac_n "checking for pid_t""... $ac_c" 1>&6
2038echo "configure:2039: checking for pid_t" >&5
2039if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
2040  echo $ac_n "(cached) $ac_c" 1>&6
2041else
2042  cat > conftest.$ac_ext <<EOF
2043#line 2044 "configure"
2044#include "confdefs.h"
2045#include <sys/types.h>
2046#if STDC_HEADERS
2047#include <stdlib.h>
2048#include <stddef.h>
2049#endif
2050EOF
2051if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2052  egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2053  rm -rf conftest*
2054  ac_cv_type_pid_t=yes
2055else
2056  rm -rf conftest*
2057  ac_cv_type_pid_t=no
2058fi
2059rm -f conftest*
2060
2061fi
2062echo "$ac_t""$ac_cv_type_pid_t" 1>&6
2063if test $ac_cv_type_pid_t = no; then
2064  cat >> confdefs.h <<\EOF
2065#define pid_t int
2066EOF
2067
2068fi
2069
2070echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
2071echo "configure:2072: checking return type of signal handlers" >&5
2072if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
2073  echo $ac_n "(cached) $ac_c" 1>&6
2074else
2075  cat > conftest.$ac_ext <<EOF
2076#line 2077 "configure"
2077#include "confdefs.h"
2078#include <sys/types.h>
2079#include <signal.h>
2080#ifdef signal
2081#undef signal
2082#endif
2083#ifdef __cplusplus
2084extern "C" void (*signal (int, void (*)(int)))(int);
2085#else
2086void (*signal ()) ();
2087#endif
2088
2089int main() {
2090int i;
2091; return 0; }
2092EOF
2093if { (eval echo configure:2094: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2094  rm -rf conftest*
2095  ac_cv_type_signal=void
2096else
2097  echo "configure: failed program was:" >&5
2098  cat conftest.$ac_ext >&5
2099  rm -rf conftest*
2100  ac_cv_type_signal=int
2101fi
2102rm -f conftest*
2103fi
2104
2105echo "$ac_t""$ac_cv_type_signal" 1>&6
2106cat >> confdefs.h <<EOF
2107#define RETSIGTYPE $ac_cv_type_signal
2108EOF
2109
2110
2111for ac_hdr in stdlib.h unistd.h limits.h sys/param.h fcntl.h string.h \
2112                 memory.h sys/time.h sys/timeb.h
2113do
2114ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2115echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2116echo "configure:2117: checking for $ac_hdr" >&5
2117if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2118  echo $ac_n "(cached) $ac_c" 1>&6
2119else
2120  cat > conftest.$ac_ext <<EOF
2121#line 2122 "configure"
2122#include "confdefs.h"
2123#include <$ac_hdr>
2124EOF
2125ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2126{ (eval echo configure:2127: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2127ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2128if test -z "$ac_err"; then
2129  rm -rf conftest*
2130  eval "ac_cv_header_$ac_safe=yes"
2131else
2132  echo "$ac_err" >&5
2133  echo "configure: failed program was:" >&5
2134  cat conftest.$ac_ext >&5
2135  rm -rf conftest*
2136  eval "ac_cv_header_$ac_safe=no"
2137fi
2138rm -f conftest*
2139fi
2140if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2141  echo "$ac_t""yes" 1>&6
2142    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2143  cat >> confdefs.h <<EOF
2144#define $ac_tr_hdr 1
2145EOF
2146 
2147else
2148  echo "$ac_t""no" 1>&6
2149fi
2150done
2151
2152if test "x$CC" != xcc; then
2153  echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
2154echo "configure:2155: checking whether $CC and cc understand -c and -o together" >&5
2155else
2156  echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
2157echo "configure:2158: checking whether cc understands -c and -o together" >&5
2158fi
2159set dummy $CC; ac_cc="`echo $2 |
2160                       sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
2161if eval "test \"`echo '$''{'ac_cv_prog_cc_${ac_cc}_c_o'+set}'`\" = set"; then
2162  echo $ac_n "(cached) $ac_c" 1>&6
2163else
2164  echo 'foo(){}' > conftest.c
2165# Make sure it works both with $CC and with simple cc.
2166# We do the test twice because some compilers refuse to overwrite an
2167# existing .o file with -o, though they will create one.
2168ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
2169if { (eval echo configure:2170: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
2170   test -f conftest.o && { (eval echo configure:2171: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
2171then
2172  eval ac_cv_prog_cc_${ac_cc}_c_o=yes
2173  if test "x$CC" != xcc; then
2174    # Test first that cc exists at all.
2175    if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:2176: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
2176      ac_try='cc -c conftest.c -o conftest.o 1>&5'
2177      if { (eval echo configure:2178: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
2178         test -f conftest.o && { (eval echo configure:2179: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
2179      then
2180        # cc works too.
2181        :
2182      else
2183        # cc exists but doesn't like -o.
2184        eval ac_cv_prog_cc_${ac_cc}_c_o=no
2185      fi
2186    fi
2187  fi
2188else
2189  eval ac_cv_prog_cc_${ac_cc}_c_o=no
2190fi
2191rm -f conftest*
2192
2193fi
2194if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
2195  echo "$ac_t""yes" 1>&6
2196else
2197  echo "$ac_t""no" 1>&6
2198  cat >> confdefs.h <<\EOF
2199#define NO_MINUS_C_MINUS_O 1
2200EOF
2201
2202fi
2203
2204
2205
2206
2207echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
2208echo "configure:2209: checking for ${CC-cc} option to accept ANSI C" >&5
2209if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then
2210  echo $ac_n "(cached) $ac_c" 1>&6
2211else
2212  am_cv_prog_cc_stdc=no
2213ac_save_CC="$CC"
2214# Don't try gcc -ansi; that turns off useful extensions and
2215# breaks some systems' header files.
2216# AIX                   -qlanglvl=ansi
2217# Ultrix and OSF/1      -std1
2218# HP-UX                 -Aa -D_HPUX_SOURCE
2219# SVR4                  -Xc -D__EXTENSIONS__
2220for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2221do
2222  CC="$ac_save_CC $ac_arg"
2223  cat > conftest.$ac_ext <<EOF
2224#line 2225 "configure"
2225#include "confdefs.h"
2226#include <stdarg.h>
2227#include <stdio.h>
2228#include <sys/types.h>
2229#include <sys/stat.h>
2230/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2231struct buf { int x; };
2232FILE * (*rcsopen) (struct buf *, struct stat *, int);
2233static char *e (p, i)
2234     char **p;
2235     int i;
2236{
2237  return p[i];
2238}
2239static char *f (char * (*g) (char **, int), char **p, ...)
2240{
2241  char *s;
2242  va_list v;
2243  va_start (v,p);
2244  s = g (p, va_arg (v,int));
2245  va_end (v);
2246  return s;
2247}
2248int test (int i, double x);
2249struct s1 {int (*f) (int a);};
2250struct s2 {int (*f) (double a);};
2251int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2252int argc;
2253char **argv;
2254
2255int main() {
2256
2257return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2258
2259; return 0; }
2260EOF
2261if { (eval echo configure:2262: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2262  rm -rf conftest*
2263  am_cv_prog_cc_stdc="$ac_arg"; break
2264else
2265  echo "configure: failed program was:" >&5
2266  cat conftest.$ac_ext >&5
2267fi
2268rm -f conftest*
2269done
2270CC="$ac_save_CC"
2271
2272fi
2273
2274if test -z "$am_cv_prog_cc_stdc"; then
2275  echo "$ac_t""none needed" 1>&6
2276else
2277  echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
2278fi
2279case "x$am_cv_prog_cc_stdc" in
2280  x|xno) ;;
2281  *) CC="$CC $am_cv_prog_cc_stdc" ;;
2282esac
2283
2284echo $ac_n "checking for working const""... $ac_c" 1>&6
2285echo "configure:2286: checking for working const" >&5
2286if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
2287  echo $ac_n "(cached) $ac_c" 1>&6
2288else
2289  cat > conftest.$ac_ext <<EOF
2290#line 2291 "configure"
2291#include "confdefs.h"
2292
2293int main() {
2294
2295/* Ultrix mips cc rejects this.  */
2296typedef int charset[2]; const charset x;
2297/* SunOS 4.1.1 cc rejects this.  */
2298char const *const *ccp;
2299char **p;
2300/* NEC SVR4.0.2 mips cc rejects this.  */
2301struct point {int x, y;};
2302static struct point const zero = {0,0};
2303/* AIX XL C 1.02.0.0 rejects this.
2304   It does not let you subtract one const X* pointer from another in an arm
2305   of an if-expression whose if-part is not a constant expression */
2306const char *g = "string";
2307ccp = &g + (g ? g-g : 0);
2308/* HPUX 7.0 cc rejects these. */
2309++ccp;
2310p = (char**) ccp;
2311ccp = (char const *const *) p;
2312{ /* SCO 3.2v4 cc rejects this.  */
2313  char *t;
2314  char const *s = 0 ? (char *) 0 : (char const *) 0;
2315
2316  *t++ = 0;
2317}
2318{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
2319  int x[] = {25, 17};
2320  const int *foo = &x[0];
2321  ++foo;
2322}
2323{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
2324  typedef const int *iptr;
2325  iptr p = 0;
2326  ++p;
2327}
2328{ /* AIX XL C 1.02.0.0 rejects this saying
2329     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
2330  struct s { int j; const int *ap[3]; };
2331  struct s *b; b->j = 5;
2332}
2333{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
2334  const int foo = 10;
2335}
2336
2337; return 0; }
2338EOF
2339if { (eval echo configure:2340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2340  rm -rf conftest*
2341  ac_cv_c_const=yes
2342else
2343  echo "configure: failed program was:" >&5
2344  cat conftest.$ac_ext >&5
2345  rm -rf conftest*
2346  ac_cv_c_const=no
2347fi
2348rm -f conftest*
2349fi
2350
2351echo "$ac_t""$ac_cv_c_const" 1>&6
2352if test $ac_cv_c_const = no; then
2353  cat >> confdefs.h <<\EOF
2354#define const
2355EOF
2356
2357fi
2358                        echo $ac_n "checking for inline""... $ac_c" 1>&6
2359echo "configure:2360: checking for inline" >&5
2360if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
2361  echo $ac_n "(cached) $ac_c" 1>&6
2362else
2363  ac_cv_c_inline=no
2364for ac_kw in inline __inline__ __inline; do
2365  cat > conftest.$ac_ext <<EOF
2366#line 2367 "configure"
2367#include "confdefs.h"
2368
2369int main() {
2370} $ac_kw foo() {
2371; return 0; }
2372EOF
2373if { (eval echo configure:2374: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2374  rm -rf conftest*
2375  ac_cv_c_inline=$ac_kw; break
2376else
2377  echo "configure: failed program was:" >&5
2378  cat conftest.$ac_ext >&5
2379fi
2380rm -f conftest*
2381done
2382
2383fi
2384
2385echo "$ac_t""$ac_cv_c_inline" 1>&6
2386case "$ac_cv_c_inline" in
2387  inline | yes) ;;
2388  no) cat >> confdefs.h <<\EOF
2389#define inline
2390EOF
2391 ;;
2392  *)  cat >> confdefs.h <<EOF
2393#define inline $ac_cv_c_inline
2394EOF
2395 ;;
2396esac
2397                        echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
2398echo "configure:2399: checking whether stat file-mode macros are broken" >&5
2399if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
2400  echo $ac_n "(cached) $ac_c" 1>&6
2401else
2402  cat > conftest.$ac_ext <<EOF
2403#line 2404 "configure"
2404#include "confdefs.h"
2405#include <sys/types.h>
2406#include <sys/stat.h>
2407
2408#if defined(S_ISBLK) && defined(S_IFDIR)
2409# if S_ISBLK (S_IFDIR)
2410You lose.
2411# endif
2412#endif
2413
2414#if defined(S_ISBLK) && defined(S_IFCHR)
2415# if S_ISBLK (S_IFCHR)
2416You lose.
2417# endif
2418#endif
2419
2420#if defined(S_ISLNK) && defined(S_IFREG)
2421# if S_ISLNK (S_IFREG)
2422You lose.
2423# endif
2424#endif
2425
2426#if defined(S_ISSOCK) && defined(S_IFREG)
2427# if S_ISSOCK (S_IFREG)
2428You lose.
2429# endif
2430#endif
2431
2432EOF
2433if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2434  egrep "You lose" >/dev/null 2>&1; then
2435  rm -rf conftest*
2436  ac_cv_header_stat_broken=yes
2437else
2438  rm -rf conftest*
2439  ac_cv_header_stat_broken=no
2440fi
2441rm -f conftest*
2442
2443fi
2444
2445echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
2446if test $ac_cv_header_stat_broken = yes; then
2447  cat >> confdefs.h <<\EOF
2448#define STAT_MACROS_BROKEN 1
2449EOF
2450
2451fi
2452
2453echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
2454echo "configure:2455: checking whether time.h and sys/time.h may both be included" >&5
2455if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
2456  echo $ac_n "(cached) $ac_c" 1>&6
2457else
2458  cat > conftest.$ac_ext <<EOF
2459#line 2460 "configure"
2460#include "confdefs.h"
2461#include <sys/types.h>
2462#include <sys/time.h>
2463#include <time.h>
2464int main() {
2465struct tm *tp;
2466; return 0; }
2467EOF
2468if { (eval echo configure:2469: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2469  rm -rf conftest*
2470  ac_cv_header_time=yes
2471else
2472  echo "configure: failed program was:" >&5
2473  cat conftest.$ac_ext >&5
2474  rm -rf conftest*
2475  ac_cv_header_time=no
2476fi
2477rm -f conftest*
2478fi
2479
2480echo "$ac_t""$ac_cv_header_time" 1>&6
2481if test $ac_cv_header_time = yes; then
2482  cat >> confdefs.h <<\EOF
2483#define TIME_WITH_SYS_TIME 1
2484EOF
2485
2486fi
2487
2488
2489
2490ALL_LINGUAS="de es fr ja ko nl pl pt_BR ru"
2491
2492
2493  echo $ac_n "checking whether NLS is wanted""... $ac_c" 1>&6
2494echo "configure:2495: checking whether NLS is wanted" >&5
2495  # Check whether --enable-nls or --disable-nls was given.
2496if test "${enable_nls+set}" = set; then
2497  enableval="$enable_nls"
2498  enable_nls=$enableval
2499else
2500  enable_nls=yes
2501fi
2502
2503  echo "$ac_t""$enable_nls" 1>&6
2504  use_nls=$enable_nls
2505 
2506
2507if test $use_nls = yes; then
2508  USE_NLS_TRUE=
2509  USE_NLS_FALSE='#'
2510else
2511  USE_NLS_TRUE='#'
2512  USE_NLS_FALSE=
2513fi
2514
2515  if test $enable_nls = yes; then
2516    cat >> confdefs.h <<\EOF
2517#define ENABLE_NLS 1
2518EOF
2519
2520
2521    # We don't support catgets at all
2522    if test "x$with_catgets" != x; then
2523      echo "configure: warning: catgets not supported; --with-catgets ignored" 1>&2
2524    fi
2525
2526    # Find out what the user wants.
2527
2528    # Check whether --with-included-gettext or --without-included-gettext was given.
2529if test "${with_included_gettext+set}" = set; then
2530  withval="$with_included_gettext"
2531  with_included_gettext=yes
2532else
2533  with_included_gettext=maybe
2534fi
2535
2536
2537    if test "x$with_included_gettext" != xyes; then
2538     
2539
2540  # OK.  What we're going to do is see if the system gettext is really
2541  # GNU gettext, and we're going to make _sure_ (as we can) that if
2542  # it's not we'll use the included gettext.
2543
2544  pds_keep_LIBS="$LIBS"
2545
2546  # Look around for gettext() and libintl.h on the system
2547  for ac_hdr in locale.h
2548do
2549ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2550echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2551echo "configure:2552: checking for $ac_hdr" >&5
2552if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2553  echo $ac_n "(cached) $ac_c" 1>&6
2554else
2555  cat > conftest.$ac_ext <<EOF
2556#line 2557 "configure"
2557#include "confdefs.h"
2558#include <$ac_hdr>
2559EOF
2560ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2561{ (eval echo configure:2562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2562ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2563if test -z "$ac_err"; then
2564  rm -rf conftest*
2565  eval "ac_cv_header_$ac_safe=yes"
2566else
2567  echo "$ac_err" >&5
2568  echo "configure: failed program was:" >&5
2569  cat conftest.$ac_ext >&5
2570  rm -rf conftest*
2571  eval "ac_cv_header_$ac_safe=no"
2572fi
2573rm -f conftest*
2574fi
2575if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2576  echo "$ac_t""yes" 1>&6
2577    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2578  cat >> confdefs.h <<EOF
2579#define $ac_tr_hdr 1
2580EOF
2581 
2582else
2583  echo "$ac_t""no" 1>&6
2584fi
2585done
2586
2587 
2588echo $ac_n "checking for library containing gettext""... $ac_c" 1>&6
2589echo "configure:2590: checking for library containing gettext" >&5
2590if eval "test \"`echo '$''{'ac_cv_search_gettext'+set}'`\" = set"; then
2591  echo $ac_n "(cached) $ac_c" 1>&6
2592else
2593  ac_func_search_save_LIBS="$LIBS"
2594ac_cv_search_gettext="no"
2595cat > conftest.$ac_ext <<EOF
2596#line 2597 "configure"
2597#include "confdefs.h"
2598/* Override any gcc2 internal prototype to avoid an error.  */
2599/* We use char because int might match the return type of a gcc2
2600    builtin and then its argument prototype would still apply.  */
2601char gettext();
2602
2603int main() {
2604gettext()
2605; return 0; }
2606EOF
2607if { (eval echo configure:2608: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2608  rm -rf conftest*
2609  ac_cv_search_gettext="none required"
2610else
2611  echo "configure: failed program was:" >&5
2612  cat conftest.$ac_ext >&5
2613fi
2614rm -f conftest*
2615test "$ac_cv_search_gettext" = "no" && for i in intl; do
2616LIBS="-l$i  $ac_func_search_save_LIBS"
2617cat > conftest.$ac_ext <<EOF
2618#line 2619 "configure"
2619#include "confdefs.h"
2620/* Override any gcc2 internal prototype to avoid an error.  */
2621/* We use char because int might match the return type of a gcc2
2622    builtin and then its argument prototype would still apply.  */
2623char gettext();
2624
2625int main() {
2626gettext()
2627; return 0; }
2628EOF
2629if { (eval echo configure:2630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2630  rm -rf conftest*
2631  ac_cv_search_gettext="-l$i"
2632break
2633else
2634  echo "configure: failed program was:" >&5
2635  cat conftest.$ac_ext >&5
2636fi
2637rm -f conftest*
2638done
2639LIBS="$ac_func_search_save_LIBS"
2640fi
2641
2642echo "$ac_t""$ac_cv_search_gettext" 1>&6
2643if test "$ac_cv_search_gettext" != "no"; then
2644  test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
2645 
2646else :
2647 
2648fi
2649  if test "$ac_cv_search_gettext" = no; then
2650    with_included_gettext=yes
2651
2652  else
2653    # We only want to deal with GNU's gettext; if we don't have that
2654    # we'll just use our own, thanks very much.
2655    echo $ac_n "checking whether the system has GNU gettext""... $ac_c" 1>&6
2656echo "configure:2657: checking whether the system has GNU gettext" >&5
2657if eval "test \"`echo '$''{'pds_cv_system_gnu_gettext'+set}'`\" = set"; then
2658  echo $ac_n "(cached) $ac_c" 1>&6
2659else
2660 
2661      cat > conftest.$ac_ext <<EOF
2662#line 2663 "configure"
2663#include "confdefs.h"
2664
2665#include <libintl.h>
2666#ifdef HAVE_LOCALE_H
2667#include <locale.h>
2668#endif
2669
2670int main() {
2671
2672#if __USE_GNU_GETTEXT
2673  extern int _nl_msg_cat_cntr;
2674  return _nl_msg_cat_cntr;
2675#else
2676not GNU gettext
2677#endif
2678
2679; return 0; }
2680EOF
2681if { (eval echo configure:2682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2682  rm -rf conftest*
2683  pds_cv_system_gnu_gettext=yes
2684else
2685  echo "configure: failed program was:" >&5
2686  cat conftest.$ac_ext >&5
2687  rm -rf conftest*
2688  pds_cv_system_gnu_gettext=no
2689fi
2690rm -f conftest*
2691fi
2692
2693echo "$ac_t""$pds_cv_system_gnu_gettext" 1>&6
2694
2695    if test "x$pds_cv_system_gnu_gettext" = xyes; then
2696      with_included_gettext=no
2697      cat >> confdefs.h <<\EOF
2698#define HAVE_LIBINTL_H 1
2699EOF
2700
2701    else
2702      with_included_gettext=yes
2703      LIBS="$pds_keep_LIBS"
2704    fi
2705  fi
2706
2707    fi
2708
2709    echo $ac_n "checking whether to use included gettext""... $ac_c" 1>&6
2710echo "configure:2711: checking whether to use included gettext" >&5
2711    echo "$ac_t""$with_included_gettext" 1>&6
2712
2713    if test "$with_included_gettext" = yes; then
2714      LIBOBJS="$LIBOBJS gettext.o"
2715    fi
2716
2717    cat >> confdefs.h <<\EOF
2718#define HAVE_GETTEXT 1
2719EOF
2720
2721    cat >> confdefs.h <<\EOF
2722#define HAVE_DCGETTEXT 1
2723EOF
2724
2725
2726    for ac_func in getcwd setlocale stpcpy
2727do
2728echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2729echo "configure:2730: checking for $ac_func" >&5
2730if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2731  echo $ac_n "(cached) $ac_c" 1>&6
2732else
2733  cat > conftest.$ac_ext <<EOF
2734#line 2735 "configure"
2735#include "confdefs.h"
2736/* System header to define __stub macros and hopefully few prototypes,
2737    which can conflict with char $ac_func(); below.  */
2738#include <assert.h>
2739/* Override any gcc2 internal prototype to avoid an error.  */
2740/* We use char because int might match the return type of a gcc2
2741    builtin and then its argument prototype would still apply.  */
2742char $ac_func();
2743
2744int main() {
2745
2746/* The GNU C library defines this for functions which it implements
2747    to always fail with ENOSYS.  Some functions are actually named
2748    something starting with __ and the normal name is an alias.  */
2749#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2750choke me
2751#else
2752$ac_func();
2753#endif
2754
2755; return 0; }
2756EOF
2757if { (eval echo configure:2758: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2758  rm -rf conftest*
2759  eval "ac_cv_func_$ac_func=yes"
2760else
2761  echo "configure: failed program was:" >&5
2762  cat conftest.$ac_ext >&5
2763  rm -rf conftest*
2764  eval "ac_cv_func_$ac_func=no"
2765fi
2766rm -f conftest*
2767fi
2768
2769if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2770  echo "$ac_t""yes" 1>&6
2771    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2772  cat >> confdefs.h <<EOF
2773#define $ac_tr_func 1
2774EOF
2775 
2776else
2777  echo "$ac_t""no" 1>&6
2778fi
2779done
2780
2781    if test $ac_cv_header_locale_h = yes; then
2782    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
2783echo "configure:2784: checking for LC_MESSAGES" >&5
2784if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
2785  echo $ac_n "(cached) $ac_c" 1>&6
2786else
2787  cat > conftest.$ac_ext <<EOF
2788#line 2789 "configure"
2789#include "confdefs.h"
2790#include <locale.h>
2791int main() {
2792return LC_MESSAGES
2793; return 0; }
2794EOF
2795if { (eval echo configure:2796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2796  rm -rf conftest*
2797  am_cv_val_LC_MESSAGES=yes
2798else
2799  echo "configure: failed program was:" >&5
2800  cat conftest.$ac_ext >&5
2801  rm -rf conftest*
2802  am_cv_val_LC_MESSAGES=no
2803fi
2804rm -f conftest*
2805fi
2806
2807echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
2808    if test $am_cv_val_LC_MESSAGES = yes; then
2809      cat >> confdefs.h <<\EOF
2810#define HAVE_LC_MESSAGES 1
2811EOF
2812
2813    fi
2814  fi
2815
2816    if test -z "$ALL_LINGUAS"; then
2817      echo "configure: warning: This package does not install translations yet." 1>&2
2818    else
2819      ac_items="$ALL_LINGUAS"
2820      for ac_item in $ac_items; do
2821        ALL_POFILES="$ALL_POFILES $ac_item.po"
2822        ALL_MOFILES="$ALL_MOFILES $ac_item.mo"
2823      done
2824    fi
2825   
2826   
2827   
2828
2829    echo $ac_n "checking which translations to install""... $ac_c" 1>&6
2830echo "configure:2831: checking which translations to install" >&5
2831    if test -z "$LINGUAS"; then
2832      ac_print="$ALL_LINGUAS"
2833      MOFILES="$ALL_MOFILES"
2834    else
2835      ac_items="$LINGUAS"
2836      for ac_item in $ac_items; do
2837        case "$ALL_LINGUAS" in
2838          *$ac_item*)
2839            ac_print="$ac_print $ac_item"
2840            MOFILES="$MOFILES $ac_item.mo"
2841            ;;
2842        esac
2843      done
2844    fi
2845   
2846    if test -z "$ac_print"; then
2847      echo "$ac_t""none" 1>&6
2848    else
2849      echo "$ac_t""$ac_print" 1>&6
2850    fi
2851
2852    if test "x$prefix" = xNONE; then
2853      cat >> confdefs.h <<EOF
2854#define LOCALEDIR "$ac_default_prefix/share/locale"
2855EOF
2856
2857    else
2858      cat >> confdefs.h <<EOF
2859#define LOCALEDIR "$prefix/share/locale"
2860EOF
2861
2862    fi
2863  fi
2864
2865
2866
2867# Check whether --enable-nsec-timestamps or --disable-nsec-timestamps was given.
2868if test "${enable_nsec_timestamps+set}" = set; then
2869  enableval="$enable_nsec_timestamps"
2870  make_cv_nsec_timestamps="$enableval"
2871else
2872  make_cv_nsec_timestamps="yes"
2873fi
2874
2875
2876if test "x$make_cv_nsec_timestamps" != xno; then
2877  echo $ac_n "checking for nanoseconds member of struct stat.st_mtim""... $ac_c" 1>&6
2878echo "configure:2879: checking for nanoseconds member of struct stat.st_mtim" >&5
2879if eval "test \"`echo '$''{'ac_cv_struct_st_mtim_nsec'+set}'`\" = set"; then
2880  echo $ac_n "(cached) $ac_c" 1>&6
2881else
2882  ac_save_CPPFLAGS="$CPPFLAGS"
2883    ac_cv_struct_st_mtim_nsec=no
2884    # tv_nsec -- the usual case
2885    # _tv_nsec -- Solaris 2.6, if
2886    #   (defined _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED == 1
2887    #    && !defined __EXTENSIONS__)
2888    # st__tim.tv_nsec -- UnixWare 2.1.2
2889    for ac_val in tv_nsec _tv_nsec st__tim.tv_nsec; do
2890      CPPFLAGS="$ac_save_CPPFLAGS -DST_MTIM_NSEC=$ac_val"
2891      cat > conftest.$ac_ext <<EOF
2892#line 2893 "configure"
2893#include "confdefs.h"
2894#include <sys/types.h>
2895#include <sys/stat.h>
2896int main() {
2897struct stat s; s.st_mtim.ST_MTIM_NSEC;
2898; return 0; }
2899EOF
2900if { (eval echo configure:2901: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2901  rm -rf conftest*
2902  ac_cv_struct_st_mtim_nsec=$ac_val; break
2903else
2904  echo "configure: failed program was:" >&5
2905  cat conftest.$ac_ext >&5
2906fi
2907rm -f conftest*
2908    done
2909    CPPFLAGS="$ac_save_CPPFLAGS"
2910fi
2911
2912echo "$ac_t""$ac_cv_struct_st_mtim_nsec" 1>&6
2913
2914  if test $ac_cv_struct_st_mtim_nsec != no; then
2915    cat >> confdefs.h <<EOF
2916#define ST_MTIM_NSEC $ac_cv_struct_st_mtim_nsec
2917EOF
2918
2919  fi
2920 
2921
2922fi
2923
2924  if test x = y; then
2925                for ac_func in INTTYPES_H
2926do
2927echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2928echo "configure:2929: checking for $ac_func" >&5
2929if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2930  echo $ac_n "(cached) $ac_c" 1>&6
2931else
2932  cat > conftest.$ac_ext <<EOF
2933#line 2934 "configure"
2934#include "confdefs.h"
2935/* System header to define __stub macros and hopefully few prototypes,
2936    which can conflict with char $ac_func(); below.  */
2937#include <assert.h>
2938/* Override any gcc2 internal prototype to avoid an error.  */
2939/* We use char because int might match the return type of a gcc2
2940    builtin and then its argument prototype would still apply.  */
2941char $ac_func();
2942
2943int main() {
2944
2945/* The GNU C library defines this for functions which it implements
2946    to always fail with ENOSYS.  Some functions are actually named
2947    something starting with __ and the normal name is an alias.  */
2948#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2949choke me
2950#else
2951$ac_func();
2952#endif
2953
2954; return 0; }
2955EOF
2956if { (eval echo configure:2957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2957  rm -rf conftest*
2958  eval "ac_cv_func_$ac_func=yes"
2959else
2960  echo "configure: failed program was:" >&5
2961  cat conftest.$ac_ext >&5
2962  rm -rf conftest*
2963  eval "ac_cv_func_$ac_func=no"
2964fi
2965rm -f conftest*
2966fi
2967
2968if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2969  echo "$ac_t""yes" 1>&6
2970    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2971  cat >> confdefs.h <<EOF
2972#define $ac_tr_func 1
2973EOF
2974 
2975else
2976  echo "$ac_t""no" 1>&6
2977fi
2978done
2979
2980  fi
2981  echo $ac_n "checking for inttypes.h""... $ac_c" 1>&6
2982echo "configure:2983: checking for inttypes.h" >&5
2983if eval "test \"`echo '$''{'jm_ac_cv_header_inttypes_h'+set}'`\" = set"; then
2984  echo $ac_n "(cached) $ac_c" 1>&6
2985else
2986  cat > conftest.$ac_ext <<EOF
2987#line 2988 "configure"
2988#include "confdefs.h"
2989#include <sys/types.h>
2990#include <inttypes.h>
2991int main() {
2992uintmax_t i = (uintmax_t) -1;
2993; return 0; }
2994EOF
2995if { (eval echo configure:2996: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2996  rm -rf conftest*
2997  jm_ac_cv_header_inttypes_h=yes
2998else
2999  echo "configure: failed program was:" >&5
3000  cat conftest.$ac_ext >&5
3001  rm -rf conftest*
3002  jm_ac_cv_header_inttypes_h=no
3003fi
3004rm -f conftest*
3005fi
3006
3007echo "$ac_t""$jm_ac_cv_header_inttypes_h" 1>&6
3008  if test $jm_ac_cv_header_inttypes_h = yes; then
3009    ac_kludge=HAVE_INTTYPES_H
3010    cat >> confdefs.h <<EOF
3011#define $ac_kludge 1
3012EOF
3013
3014  fi
3015
3016
3017 
3018  if test $jm_ac_cv_header_inttypes_h = no; then
3019    echo $ac_n "checking for unsigned long long""... $ac_c" 1>&6
3020echo "configure:3021: checking for unsigned long long" >&5
3021if eval "test \"`echo '$''{'ac_cv_type_unsigned_long_long'+set}'`\" = set"; then
3022  echo $ac_n "(cached) $ac_c" 1>&6
3023else
3024  cat > conftest.$ac_ext <<EOF
3025#line 3026 "configure"
3026#include "confdefs.h"
3027unsigned long long ull = 1; int i = 63;
3028int main() {
3029unsigned long long ullmax = (unsigned long long) -1;
3030       return ull << i | ull >> i | ullmax / ull | ullmax % ull;
3031; return 0; }
3032EOF
3033if { (eval echo configure:3034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3034  rm -rf conftest*
3035  ac_cv_type_unsigned_long_long=yes
3036else
3037  echo "configure: failed program was:" >&5
3038  cat conftest.$ac_ext >&5
3039  rm -rf conftest*
3040  ac_cv_type_unsigned_long_long=no
3041fi
3042rm -f conftest*
3043fi
3044
3045echo "$ac_t""$ac_cv_type_unsigned_long_long" 1>&6
3046    if test $ac_cv_type_unsigned_long_long = yes; then
3047      cat >> confdefs.h <<\EOF
3048#define uintmax_t unsigned long long
3049EOF
3050
3051    else
3052      cat >> confdefs.h <<\EOF
3053#define uintmax_t unsigned long
3054EOF
3055
3056    fi
3057  fi
3058
3059
3060
3061
3062
3063# Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
3064# Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
3065
3066echo $ac_n "checking for library containing clock_gettime""... $ac_c" 1>&6
3067echo "configure:3068: checking for library containing clock_gettime" >&5
3068if eval "test \"`echo '$''{'ac_cv_search_clock_gettime'+set}'`\" = set"; then
3069  echo $ac_n "(cached) $ac_c" 1>&6
3070else
3071  ac_func_search_save_LIBS="$LIBS"
3072ac_cv_search_clock_gettime="no"
3073cat > conftest.$ac_ext <<EOF
3074#line 3075 "configure"
3075#include "confdefs.h"
3076/* Override any gcc2 internal prototype to avoid an error.  */
3077/* We use char because int might match the return type of a gcc2
3078    builtin and then its argument prototype would still apply.  */
3079char clock_gettime();
3080
3081int main() {
3082clock_gettime()
3083; return 0; }
3084EOF
3085if { (eval echo configure:3086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3086  rm -rf conftest*
3087  ac_cv_search_clock_gettime="none required"
3088else
3089  echo "configure: failed program was:" >&5
3090  cat conftest.$ac_ext >&5
3091fi
3092rm -f conftest*
3093test "$ac_cv_search_clock_gettime" = "no" && for i in rt posix4; do
3094LIBS="-l$i  $ac_func_search_save_LIBS"
3095cat > conftest.$ac_ext <<EOF
3096#line 3097 "configure"
3097#include "confdefs.h"
3098/* Override any gcc2 internal prototype to avoid an error.  */
3099/* We use char because int might match the return type of a gcc2
3100    builtin and then its argument prototype would still apply.  */
3101char clock_gettime();
3102
3103int main() {
3104clock_gettime()
3105; return 0; }
3106EOF
3107if { (eval echo configure:3108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3108  rm -rf conftest*
3109  ac_cv_search_clock_gettime="-l$i"
3110break
3111else
3112  echo "configure: failed program was:" >&5
3113  cat conftest.$ac_ext >&5
3114fi
3115rm -f conftest*
3116done
3117LIBS="$ac_func_search_save_LIBS"
3118fi
3119
3120echo "$ac_t""$ac_cv_search_clock_gettime" 1>&6
3121if test "$ac_cv_search_clock_gettime" != "no"; then
3122  test "$ac_cv_search_clock_gettime" = "none required" || LIBS="$ac_cv_search_clock_gettime $LIBS"
3123 
3124else :
3125 
3126fi
3127if test "$ac_cv_search_clock_gettime" != no; then
3128  cat >> confdefs.h <<\EOF
3129#define HAVE_CLOCK_GETTIME 1
3130EOF
3131
3132fi
3133
3134# See if we have a standard version of gettimeofday().  Since actual
3135# implementations can differ, just make sure we have the most common
3136# one.
3137echo $ac_n "checking for standard gettimeofday""... $ac_c" 1>&6
3138echo "configure:3139: checking for standard gettimeofday" >&5
3139if eval "test \"`echo '$''{'ac_cv_func_gettimeofday'+set}'`\" = set"; then
3140  echo $ac_n "(cached) $ac_c" 1>&6
3141else
3142  ac_cv_func_gettimeofday=no
3143   if test "$cross_compiling" = yes; then
3144  ac_cv_func_gettimeofday="no (cross-compiling)"
3145else
3146  cat > conftest.$ac_ext <<EOF
3147#line 3148 "configure"
3148#include "confdefs.h"
3149#include <sys/time.h>
3150               int main ()
3151               {
3152                 struct timeval t; t.tv_sec = -1; t.tv_usec = -1;
3153                 exit (gettimeofday (&t, 0) != 0
3154                       || t.tv_sec < 0 || t.tv_usec < 0);
3155               }
3156EOF
3157if { (eval echo configure:3158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3158then
3159  ac_cv_func_gettimeofday=yes
3160else
3161  echo "configure: failed program was:" >&5
3162  cat conftest.$ac_ext >&5
3163  rm -fr conftest*
3164  ac_cv_func_gettimeofday=no
3165fi
3166rm -fr conftest*
3167fi
3168
3169fi
3170
3171echo "$ac_t""$ac_cv_func_gettimeofday" 1>&6
3172if test $ac_cv_func_gettimeofday = yes; then
3173  cat >> confdefs.h <<\EOF
3174#define HAVE_GETTIMEOFDAY 1
3175EOF
3176
3177fi
3178
3179for ac_func in memmove memcpy strchr strdup psignal mkstemp mktemp fdopen \
3180                dup2 getcwd sigsetmask sigaction getgroups setlinebuf \
3181                seteuid setegid setreuid setregid pipe strerror strsignal
3182do
3183echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3184echo "configure:3185: checking for $ac_func" >&5
3185if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3186  echo $ac_n "(cached) $ac_c" 1>&6
3187else
3188  cat > conftest.$ac_ext <<EOF
3189#line 3190 "configure"
3190#include "confdefs.h"
3191/* System header to define __stub macros and hopefully few prototypes,
3192    which can conflict with char $ac_func(); below.  */
3193#include <assert.h>
3194/* Override any gcc2 internal prototype to avoid an error.  */
3195/* We use char because int might match the return type of a gcc2
3196    builtin and then its argument prototype would still apply.  */
3197char $ac_func();
3198
3199int main() {
3200
3201/* The GNU C library defines this for functions which it implements
3202    to always fail with ENOSYS.  Some functions are actually named
3203    something starting with __ and the normal name is an alias.  */
3204#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3205choke me
3206#else
3207$ac_func();
3208#endif
3209
3210; return 0; }
3211EOF
3212if { (eval echo configure:3213: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3213  rm -rf conftest*
3214  eval "ac_cv_func_$ac_func=yes"
3215else
3216  echo "configure: failed program was:" >&5
3217  cat conftest.$ac_ext >&5
3218  rm -rf conftest*
3219  eval "ac_cv_func_$ac_func=no"
3220fi
3221rm -f conftest*
3222fi
3223
3224if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3225  echo "$ac_t""yes" 1>&6
3226    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
3227  cat >> confdefs.h <<EOF
3228#define $ac_tr_func 1
3229EOF
3230 
3231else
3232  echo "$ac_t""no" 1>&6
3233fi
3234done
3235
3236
3237echo $ac_n "checking for sys_siglist""... $ac_c" 1>&6
3238echo "configure:3239: checking for sys_siglist" >&5
3239if eval "test \"`echo '$''{'ac_cv_check_symbol_sys_siglist'+set}'`\" = set"; then
3240  echo $ac_n "(cached) $ac_c" 1>&6
3241else
3242  cat > conftest.$ac_ext <<EOF
3243#line 3244 "configure"
3244#include "confdefs.h"
3245
3246int main() {
3247extern char *sys_siglist[]; puts(*sys_siglist);
3248; return 0; }
3249EOF
3250if { (eval echo configure:3251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3251  rm -rf conftest*
3252  ac_cv_check_symbol_sys_siglist=yes
3253else
3254  echo "configure: failed program was:" >&5
3255  cat conftest.$ac_ext >&5
3256  rm -rf conftest*
3257  ac_cv_check_symbol_sys_siglist=no
3258fi
3259rm -f conftest*
3260fi
3261
3262if test "$ac_cv_check_symbol_sys_siglist" = yes; then
3263  ac_tr_symbol=`echo sys_siglist | tr '[a-z]' '[A-Z]'`
3264  cat >> confdefs.h <<EOF
3265#define HAVE_${ac_tr_symbol} 1
3266EOF
3267
3268fi
3269echo "$ac_t""$ac_cv_check_symbol_sys_siglist" 1>&6
3270# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
3271# for constant arguments.  Useless!
3272echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
3273echo "configure:3274: checking for working alloca.h" >&5
3274if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
3275  echo $ac_n "(cached) $ac_c" 1>&6
3276else
3277  cat > conftest.$ac_ext <<EOF
3278#line 3279 "configure"
3279#include "confdefs.h"
3280#include <alloca.h>
3281int main() {
3282char *p = alloca(2 * sizeof(int));
3283; return 0; }
3284EOF
3285if { (eval echo configure:3286: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3286  rm -rf conftest*
3287  ac_cv_header_alloca_h=yes
3288else
3289  echo "configure: failed program was:" >&5
3290  cat conftest.$ac_ext >&5
3291  rm -rf conftest*
3292  ac_cv_header_alloca_h=no
3293fi
3294rm -f conftest*
3295fi
3296
3297echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
3298if test $ac_cv_header_alloca_h = yes; then
3299  cat >> confdefs.h <<\EOF
3300#define HAVE_ALLOCA_H 1
3301EOF
3302
3303fi
3304
3305echo $ac_n "checking for alloca""... $ac_c" 1>&6
3306echo "configure:3307: checking for alloca" >&5
3307if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
3308  echo $ac_n "(cached) $ac_c" 1>&6
3309else
3310  cat > conftest.$ac_ext <<EOF
3311#line 3312 "configure"
3312#include "confdefs.h"
3313
3314#ifdef __GNUC__
3315# define alloca __builtin_alloca
3316#else
3317# ifdef _MSC_VER
3318#  include <malloc.h>
3319#  define alloca _alloca
3320# else
3321#  if HAVE_ALLOCA_H
3322#   include <alloca.h>
3323#  else
3324#   ifdef _AIX
3325 #pragma alloca
3326#   else
3327#    ifndef alloca /* predefined by HP cc +Olibcalls */
3328char *alloca ();
3329#    endif
3330#   endif
3331#  endif
3332# endif
3333#endif
3334
3335int main() {
3336char *p = (char *) alloca(1);
3337; return 0; }
3338EOF
3339if { (eval echo configure:3340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3340  rm -rf conftest*
3341  ac_cv_func_alloca_works=yes
3342else
3343  echo "configure: failed program was:" >&5
3344  cat conftest.$ac_ext >&5
3345  rm -rf conftest*
3346  ac_cv_func_alloca_works=no
3347fi
3348rm -f conftest*
3349fi
3350
3351echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
3352if test $ac_cv_func_alloca_works = yes; then
3353  cat >> confdefs.h <<\EOF
3354#define HAVE_ALLOCA 1
3355EOF
3356
3357fi
3358
3359if test $ac_cv_func_alloca_works = no; then
3360  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
3361  # that cause trouble.  Some versions do not even contain alloca or
3362  # contain a buggy version.  If you still want to use their alloca,
3363  # use ar to extract alloca.o from them instead of compiling alloca.c.
3364  ALLOCA=alloca.${ac_objext}
3365  cat >> confdefs.h <<\EOF
3366#define C_ALLOCA 1
3367EOF
3368
3369
3370echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
3371echo "configure:3372: checking whether alloca needs Cray hooks" >&5
3372if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
3373  echo $ac_n "(cached) $ac_c" 1>&6
3374else
3375  cat > conftest.$ac_ext <<EOF
3376#line 3377 "configure"
3377#include "confdefs.h"
3378#if defined(CRAY) && ! defined(CRAY2)
3379webecray
3380#else
3381wenotbecray
3382#endif
3383
3384EOF
3385if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3386  egrep "webecray" >/dev/null 2>&1; then
3387  rm -rf conftest*
3388  ac_cv_os_cray=yes
3389else
3390  rm -rf conftest*
3391  ac_cv_os_cray=no
3392fi
3393rm -f conftest*
3394
3395fi
3396
3397echo "$ac_t""$ac_cv_os_cray" 1>&6
3398if test $ac_cv_os_cray = yes; then
3399for ac_func in _getb67 GETB67 getb67; do
3400  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3401echo "configure:3402: checking for $ac_func" >&5
3402if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3403  echo $ac_n "(cached) $ac_c" 1>&6
3404else
3405  cat > conftest.$ac_ext <<EOF
3406#line 3407 "configure"
3407#include "confdefs.h"
3408/* System header to define __stub macros and hopefully few prototypes,
3409    which can conflict with char $ac_func(); below.  */
3410#include <assert.h>
3411/* Override any gcc2 internal prototype to avoid an error.  */
3412/* We use char because int might match the return type of a gcc2
3413    builtin and then its argument prototype would still apply.  */
3414char $ac_func();
3415
3416int main() {
3417
3418/* The GNU C library defines this for functions which it implements
3419    to always fail with ENOSYS.  Some functions are actually named
3420    something starting with __ and the normal name is an alias.  */
3421#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
3422choke me
3423#else
3424$ac_func();
3425#endif
3426
3427; return 0; }
3428EOF
3429if { (eval echo configure:3430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3430  rm -rf conftest*
3431  eval "ac_cv_func_$ac_func=yes"
3432else
3433  echo "configure: failed program was:" >&5
3434  cat conftest.$ac_ext >&5
3435  rm -rf conftest*
3436  eval "ac_cv_func_$ac_func=no"
3437fi
3438rm -f conftest*
3439fi
3440
3441if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
3442  echo "$ac_t""yes" 1>&6
3443  cat >> confdefs.h <<EOF
3444#define CRAY_STACKSEG_END $ac_func
3445EOF
3446
3447  break
3448else
3449  echo "$ac_t""no" 1>&6
3450fi
3451
3452done
3453fi
3454
3455echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
3456echo "configure:3457: checking stack direction for C alloca" >&5
3457if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
3458  echo $ac_n "(cached) $ac_c" 1>&6
3459else
3460  if test "$cross_compiling" = yes; then
3461  ac_cv_c_stack_direction=0
3462else
3463  cat > conftest.$ac_ext <<EOF
3464#line 3465 "configure"
3465#include "confdefs.h"
3466find_stack_direction ()
3467{
3468  static char *addr = 0;
3469  auto char dummy;
3470  if (addr == 0)
3471    {
3472      addr = &dummy;
3473      return find_stack_direction ();
3474    }
3475  else
3476    return (&dummy > addr) ? 1 : -1;
3477}
3478main ()
3479{
3480  exit (find_stack_direction() < 0);
3481}
3482EOF
3483if { (eval echo configure:3484: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3484then
3485  ac_cv_c_stack_direction=1
3486else
3487  echo "configure: failed program was:" >&5
3488  cat conftest.$ac_ext >&5
3489  rm -fr conftest*
3490  ac_cv_c_stack_direction=-1
3491fi
3492rm -fr conftest*
3493fi
3494
3495fi
3496
3497echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
3498cat >> confdefs.h <<EOF
3499#define STACK_DIRECTION $ac_cv_c_stack_direction
3500EOF
3501
3502fi
3503
3504ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
3505echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
3506echo "configure:3507: checking for vfork.h" >&5
3507if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3508  echo $ac_n "(cached) $ac_c" 1>&6
3509else
3510  cat > conftest.$ac_ext <<EOF
3511#line 3512 "configure"
3512#include "confdefs.h"
3513#include <vfork.h>
3514EOF
3515ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3516{ (eval echo configure:3517: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3517ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3518if test -z "$ac_err"; then
3519  rm -rf conftest*
3520  eval "ac_cv_header_$ac_safe=yes"
3521else
3522  echo "$ac_err" >&5
3523  echo "configure: failed program was:" >&5
3524  cat conftest.$ac_ext >&5
3525  rm -rf conftest*
3526  eval "ac_cv_header_$ac_safe=no"
3527fi
3528rm -f conftest*
3529fi
3530if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3531  echo "$ac_t""yes" 1>&6
3532  cat >> confdefs.h <<\EOF
3533#define HAVE_VFORK_H 1
3534EOF
3535
3536else
3537  echo "$ac_t""no" 1>&6
3538fi
3539
3540echo $ac_n "checking for working vfork""... $ac_c" 1>&6
3541echo "configure:3542: checking for working vfork" >&5
3542if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
3543  echo $ac_n "(cached) $ac_c" 1>&6
3544else
3545  if test "$cross_compiling" = yes; then
3546  echo $ac_n "checking for vfork""... $ac_c" 1>&6
3547echo "configure:3548: checking for vfork" >&5
3548if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
3549  echo $ac_n "(cached) $ac_c" 1>&6
3550else
3551  cat > conftest.$ac_ext <<EOF
3552#line 3553 "configure"
3553#include "confdefs.h"
3554/* System header to define __stub macros and hopefully few prototypes,
3555    which can conflict with char vfork(); below.  */
3556#include <assert.h>
3557/* Override any gcc2 internal prototype to avoid an error.  */
3558/* We use char because int might match the return type of a gcc2
3559    builtin and then its argument prototype would still apply.  */
3560char vfork();
3561
3562int main() {
3563
3564/* The GNU C library defines this for functions which it implements
3565    to always fail with ENOSYS.  Some functions are actually named
3566    something starting with __ and the normal name is an alias.  */
3567#if defined (__stub_vfork) || defined (__stub___vfork)
3568choke me
3569#else
3570vfork();
3571#endif
3572
3573; return 0; }
3574EOF
3575if { (eval echo configure:3576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3576  rm -rf conftest*
3577  eval "ac_cv_func_vfork=yes"
3578else
3579  echo "configure: failed program was:" >&5
3580  cat conftest.$ac_ext >&5
3581  rm -rf conftest*
3582  eval "ac_cv_func_vfork=no"
3583fi
3584rm -f conftest*
3585fi
3586
3587if eval "test \"`echo '$ac_cv_func_'vfork`\" = yes"; then
3588  echo "$ac_t""yes" 1>&6
3589  :
3590else
3591  echo "$ac_t""no" 1>&6
3592fi
3593
3594ac_cv_func_vfork_works=$ac_cv_func_vfork
3595else
3596  cat > conftest.$ac_ext <<EOF
3597#line 3598 "configure"
3598#include "confdefs.h"
3599/* Thanks to Paul Eggert for this test.  */
3600#include <stdio.h>
3601#include <sys/types.h>
3602#include <sys/stat.h>
3603#ifdef HAVE_UNISTD_H
3604#include <unistd.h>
3605#endif
3606#ifdef HAVE_VFORK_H
3607#include <vfork.h>
3608#endif
3609/* On some sparc systems, changes by the child to local and incoming
3610   argument registers are propagated back to the parent.
3611   The compiler is told about this with #include <vfork.h>,
3612   but some compilers (e.g. gcc -O) don't grok <vfork.h>.
3613   Test for this by using a static variable whose address
3614   is put into a register that is clobbered by the vfork.  */
3615static
3616#ifdef __cplusplus
3617sparc_address_test (int arg)
3618#else
3619sparc_address_test (arg) int arg;
3620#endif
3621{
3622  static pid_t child;
3623  if (!child) {
3624    child = vfork ();
3625    if (child < 0) {
3626      perror ("vfork");
3627      _exit(2);
3628    }
3629    if (!child) {
3630      arg = getpid();
3631      write(-1, "", 0);
3632      _exit (arg);
3633    }
3634  }
3635}
3636main() {
3637  pid_t parent = getpid ();
3638  pid_t child;
3639
3640  sparc_address_test ();
3641
3642  child = vfork ();
3643
3644  if (child == 0) {
3645    /* Here is another test for sparc vfork register problems.
3646       This test uses lots of local variables, at least
3647       as many local variables as main has allocated so far
3648       including compiler temporaries.  4 locals are enough for
3649       gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe.
3650       A buggy compiler should reuse the register of parent
3651       for one of the local variables, since it will think that
3652       parent can't possibly be used any more in this routine.
3653       Assigning to the local variable will thus munge parent
3654       in the parent process.  */
3655    pid_t
3656      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
3657      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
3658    /* Convince the compiler that p..p7 are live; otherwise, it might
3659       use the same hardware register for all 8 local variables.  */
3660    if (p != p1 || p != p2 || p != p3 || p != p4
3661        || p != p5 || p != p6 || p != p7)
3662      _exit(1);
3663
3664    /* On some systems (e.g. IRIX 3.3),
3665       vfork doesn't separate parent from child file descriptors.
3666       If the child closes a descriptor before it execs or exits,
3667       this munges the parent's descriptor as well.
3668       Test for this by closing stdout in the child.  */
3669    _exit(close(fileno(stdout)) != 0);
3670  } else {
3671    int status;
3672    struct stat st;
3673
3674    while (wait(&status) != child)
3675      ;
3676    exit(
3677         /* Was there some problem with vforking?  */
3678         child < 0
3679
3680         /* Did the child fail?  (This shouldn't happen.)  */
3681         || status
3682
3683         /* Did the vfork/compiler bug occur?  */
3684         || parent != getpid()
3685
3686         /* Did the file descriptor bug occur?  */
3687         || fstat(fileno(stdout), &st) != 0
3688         );
3689  }
3690}
3691EOF
3692if { (eval echo configure:3693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3693then
3694  ac_cv_func_vfork_works=yes
3695else
3696  echo "configure: failed program was:" >&5
3697  cat conftest.$ac_ext >&5
3698  rm -fr conftest*
3699  ac_cv_func_vfork_works=no
3700fi
3701rm -fr conftest*
3702fi
3703
3704fi
3705
3706echo "$ac_t""$ac_cv_func_vfork_works" 1>&6
3707if test $ac_cv_func_vfork_works = no; then
3708  cat >> confdefs.h <<\EOF
3709#define vfork fork
3710EOF
3711
3712fi
3713
3714echo $ac_n "checking for vprintf""... $ac_c" 1>&6
3715echo "configure:3716: checking for vprintf" >&5
3716if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
3717  echo $ac_n "(cached) $ac_c" 1>&6
3718else
3719  cat > conftest.$ac_ext <<EOF
3720#line 3721 "configure"
3721#include "confdefs.h"
3722/* System header to define __stub macros and hopefully few prototypes,
3723    which can conflict with char vprintf(); below.  */
3724#include <assert.h>
3725/* Override any gcc2 internal prototype to avoid an error.  */
3726/* We use char because int might match the return type of a gcc2
3727    builtin and then its argument prototype would still apply.  */
3728char vprintf();
3729
3730int main() {
3731
3732/* The GNU C library defines this for functions which it implements
3733    to always fail with ENOSYS.  Some functions are actually named
3734    something starting with __ and the normal name is an alias.  */
3735#if defined (__stub_vprintf) || defined (__stub___vprintf)
3736choke me
3737#else
3738vprintf();
3739#endif
3740
3741; return 0; }
3742EOF
3743if { (eval echo configure:3744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3744  rm -rf conftest*
3745  eval "ac_cv_func_vprintf=yes"
3746else
3747  echo "configure: failed program was:" >&5
3748  cat conftest.$ac_ext >&5
3749  rm -rf conftest*
3750  eval "ac_cv_func_vprintf=no"
3751fi
3752rm -f conftest*
3753fi
3754
3755if eval "test \"`echo '$ac_cv_func_'vprintf`\" = yes"; then
3756  echo "$ac_t""yes" 1>&6
3757  cat >> confdefs.h <<\EOF
3758#define HAVE_VPRINTF 1
3759EOF
3760
3761else
3762  echo "$ac_t""no" 1>&6
3763fi
3764
3765if test "$ac_cv_func_vprintf" != yes; then
3766echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
3767echo "configure:3768: checking for _doprnt" >&5
3768if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
3769  echo $ac_n "(cached) $ac_c" 1>&6
3770else
3771  cat > conftest.$ac_ext <<EOF
3772#line 3773 "configure"
3773#include "confdefs.h"
3774/* System header to define __stub macros and hopefully few prototypes,
3775    which can conflict with char _doprnt(); below.  */
3776#include <assert.h>
3777/* Override any gcc2 internal prototype to avoid an error.  */
3778/* We use char because int might match the return type of a gcc2
3779    builtin and then its argument prototype would still apply.  */
3780char _doprnt();
3781
3782int main() {
3783
3784/* The GNU C library defines this for functions which it implements
3785    to always fail with ENOSYS.  Some functions are actually named
3786    something starting with __ and the normal name is an alias.  */
3787#if defined (__stub__doprnt) || defined (__stub____doprnt)
3788choke me
3789#else
3790_doprnt();
3791#endif
3792
3793; return 0; }
3794EOF
3795if { (eval echo configure:3796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3796  rm -rf conftest*
3797  eval "ac_cv_func__doprnt=yes"
3798else
3799  echo "configure: failed program was:" >&5
3800  cat conftest.$ac_ext >&5
3801  rm -rf conftest*
3802  eval "ac_cv_func__doprnt=no"
3803fi
3804rm -f conftest*
3805fi
3806
3807if eval "test \"`echo '$ac_cv_func_'_doprnt`\" = yes"; then
3808  echo "$ac_t""yes" 1>&6
3809  cat >> confdefs.h <<\EOF
3810#define HAVE_DOPRNT 1
3811EOF
3812
3813else
3814  echo "$ac_t""no" 1>&6
3815fi
3816
3817fi
3818
3819echo $ac_n "checking for working strcoll""... $ac_c" 1>&6
3820echo "configure:3821: checking for working strcoll" >&5
3821if eval "test \"`echo '$''{'ac_cv_func_strcoll_works'+set}'`\" = set"; then
3822  echo $ac_n "(cached) $ac_c" 1>&6
3823else
3824  if test "$cross_compiling" = yes; then
3825  ac_cv_func_strcoll_works=no
3826else
3827  cat > conftest.$ac_ext <<EOF
3828#line 3829 "configure"
3829#include "confdefs.h"
3830#include <string.h>
3831main ()
3832{
3833  exit (strcoll ("abc", "def") >= 0 ||
3834        strcoll ("ABC", "DEF") >= 0 ||
3835        strcoll ("123", "456") >= 0);
3836}
3837EOF
3838if { (eval echo configure:3839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3839then
3840  ac_cv_func_strcoll_works=yes
3841else
3842  echo "configure: failed program was:" >&5
3843  cat conftest.$ac_ext >&5
3844  rm -fr conftest*
3845  ac_cv_func_strcoll_works=no
3846fi
3847rm -fr conftest*
3848fi
3849
3850fi
3851
3852echo "$ac_t""$ac_cv_func_strcoll_works" 1>&6
3853if test $ac_cv_func_strcoll_works = yes; then
3854  cat >> confdefs.h <<\EOF
3855#define HAVE_STRCOLL 1
3856EOF
3857
3858fi
3859
3860echo $ac_n "checking whether closedir returns void""... $ac_c" 1>&6
3861echo "configure:3862: checking whether closedir returns void" >&5
3862if eval "test \"`echo '$''{'ac_cv_func_closedir_void'+set}'`\" = set"; then
3863  echo $ac_n "(cached) $ac_c" 1>&6
3864else
3865  if test "$cross_compiling" = yes; then
3866  ac_cv_func_closedir_void=yes
3867else
3868  cat > conftest.$ac_ext <<EOF
3869#line 3870 "configure"
3870#include "confdefs.h"
3871#include <sys/types.h>
3872#include <$ac_header_dirent>
3873int closedir(); main() { exit(closedir(opendir(".")) != 0); }
3874EOF
3875if { (eval echo configure:3876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3876then
3877  ac_cv_func_closedir_void=no
3878else
3879  echo "configure: failed program was:" >&5
3880  cat conftest.$ac_ext >&5
3881  rm -fr conftest*
3882  ac_cv_func_closedir_void=yes
3883fi
3884rm -fr conftest*
3885fi
3886
3887fi
3888
3889echo "$ac_t""$ac_cv_func_closedir_void" 1>&6
3890if test $ac_cv_func_closedir_void = yes; then
3891  cat >> confdefs.h <<\EOF
3892#define CLOSEDIR_VOID 1
3893EOF
3894
3895fi
3896
3897echo $ac_n "checking whether setvbuf arguments are reversed""... $ac_c" 1>&6
3898echo "configure:3899: checking whether setvbuf arguments are reversed" >&5
3899if eval "test \"`echo '$''{'ac_cv_func_setvbuf_reversed'+set}'`\" = set"; then
3900  echo $ac_n "(cached) $ac_c" 1>&6
3901else
3902  if test "$cross_compiling" = yes; then
3903    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3904else
3905  cat > conftest.$ac_ext <<EOF
3906#line 3907 "configure"
3907#include "confdefs.h"
3908#include <stdio.h>
3909/* If setvbuf has the reversed format, exit 0. */
3910main () {
3911  /* This call has the arguments reversed.
3912     A reversed system may check and see that the address of main
3913     is not _IOLBF, _IONBF, or _IOFBF, and return nonzero.  */
3914  if (setvbuf(stdout, _IOLBF, (char *) main, BUFSIZ) != 0)
3915    exit(1);
3916  putc('\r', stdout);
3917  exit(0);                      /* Non-reversed systems segv here.  */
3918}
3919EOF
3920if { (eval echo configure:3921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3921then
3922  ac_cv_func_setvbuf_reversed=yes
3923else
3924  echo "configure: failed program was:" >&5
3925  cat conftest.$ac_ext >&5
3926  rm -fr conftest*
3927  ac_cv_func_setvbuf_reversed=no
3928fi
3929rm -fr conftest*
3930fi
3931
3932rm -f core core.* *.core
3933fi
3934
3935echo "$ac_t""$ac_cv_func_setvbuf_reversed" 1>&6
3936if test $ac_cv_func_setvbuf_reversed = yes; then
3937  cat >> confdefs.h <<\EOF
3938#define SETVBUF_REVERSED 1
3939EOF
3940
3941fi
3942
3943
3944echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6
3945echo "configure:3946: checking for kstat_open in -lkstat" >&5
3946ac_lib_var=`echo kstat'_'kstat_open | sed 'y%./+-%__p_%'`
3947if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3948  echo $ac_n "(cached) $ac_c" 1>&6
3949else
3950  ac_save_LIBS="$LIBS"
3951LIBS="-lkstat  $LIBS"
3952cat > conftest.$ac_ext <<EOF
3953#line 3954 "configure"
3954#include "confdefs.h"
3955/* Override any gcc2 internal prototype to avoid an error.  */
3956/* We use char because int might match the return type of a gcc2
3957    builtin and then its argument prototype would still apply.  */
3958char kstat_open();
3959
3960int main() {
3961kstat_open()
3962; return 0; }
3963EOF
3964if { (eval echo configure:3965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3965  rm -rf conftest*
3966  eval "ac_cv_lib_$ac_lib_var=yes"
3967else
3968  echo "configure: failed program was:" >&5
3969  cat conftest.$ac_ext >&5
3970  rm -rf conftest*
3971  eval "ac_cv_lib_$ac_lib_var=no"
3972fi
3973rm -f conftest*
3974LIBS="$ac_save_LIBS"
3975
3976fi
3977if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3978  echo "$ac_t""yes" 1>&6
3979    ac_tr_lib=HAVE_LIB`echo kstat | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3980    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3981  cat >> confdefs.h <<EOF
3982#define $ac_tr_lib 1
3983EOF
3984
3985  LIBS="-lkstat $LIBS"
3986
3987else
3988  echo "$ac_t""no" 1>&6
3989fi
3990 for ac_func in pstat_getdynamic
3991do
3992echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3993echo "configure:3994: checking for $ac_func" >&5
3994if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
3995  echo $ac_n "(cached) $ac_c" 1>&6
3996else
3997  cat > conftest.$ac_ext <<EOF
3998#line 3999 "configure"
3999#include "confdefs.h"
4000/* System header to define __stub macros and hopefully few prototypes,
4001    which can conflict with char $ac_func(); below.  */
4002#include <assert.h>
4003/* Override any gcc2 internal prototype to avoid an error.  */
4004/* We use char because int might match the return type of a gcc2
4005    builtin and then its argument prototype would still apply.  */
4006char $ac_func();
4007
4008int main() {
4009
4010/* The GNU C library defines this for functions which it implements
4011    to always fail with ENOSYS.  Some functions are actually named
4012    something starting with __ and the normal name is an alias.  */
4013#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4014choke me
4015#else
4016$ac_func();
4017#endif
4018
4019; return 0; }
4020EOF
4021if { (eval echo configure:4022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4022  rm -rf conftest*
4023  eval "ac_cv_func_$ac_func=yes"
4024else
4025  echo "configure: failed program was:" >&5
4026  cat conftest.$ac_ext >&5
4027  rm -rf conftest*
4028  eval "ac_cv_func_$ac_func=no"
4029fi
4030rm -f conftest*
4031fi
4032
4033if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4034  echo "$ac_t""yes" 1>&6
4035    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4036  cat >> confdefs.h <<EOF
4037#define $ac_tr_func 1
4038EOF
4039 
4040else
4041  echo "$ac_t""no" 1>&6
4042fi
4043done
4044 ac_have_func=no # yes means we've found a way to get the load average.
4045
4046# Some systems with -lutil have (and need) -lkvm as well, some do not.
4047# On Solaris, -lkvm requires nlist from -lelf, so check that first
4048# to get the right answer into the cache.
4049echo $ac_n "checking for elf_begin in -lelf""... $ac_c" 1>&6
4050echo "configure:4051: checking for elf_begin in -lelf" >&5
4051ac_lib_var=`echo elf'_'elf_begin | sed 'y%./+-%__p_%'`
4052if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4053  echo $ac_n "(cached) $ac_c" 1>&6
4054else
4055  ac_save_LIBS="$LIBS"
4056LIBS="-lelf  $LIBS"
4057cat > conftest.$ac_ext <<EOF
4058#line 4059 "configure"
4059#include "confdefs.h"
4060/* Override any gcc2 internal prototype to avoid an error.  */
4061/* We use char because int might match the return type of a gcc2
4062    builtin and then its argument prototype would still apply.  */
4063char elf_begin();
4064
4065int main() {
4066elf_begin()
4067; return 0; }
4068EOF
4069if { (eval echo configure:4070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4070  rm -rf conftest*
4071  eval "ac_cv_lib_$ac_lib_var=yes"
4072else
4073  echo "configure: failed program was:" >&5
4074  cat conftest.$ac_ext >&5
4075  rm -rf conftest*
4076  eval "ac_cv_lib_$ac_lib_var=no"
4077fi
4078rm -f conftest*
4079LIBS="$ac_save_LIBS"
4080
4081fi
4082if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4083  echo "$ac_t""yes" 1>&6
4084  LIBS="-lelf $LIBS"
4085else
4086  echo "$ac_t""no" 1>&6
4087fi
4088
4089echo $ac_n "checking for kvm_open in -lkvm""... $ac_c" 1>&6
4090echo "configure:4091: checking for kvm_open in -lkvm" >&5
4091ac_lib_var=`echo kvm'_'kvm_open | sed 'y%./+-%__p_%'`
4092if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4093  echo $ac_n "(cached) $ac_c" 1>&6
4094else
4095  ac_save_LIBS="$LIBS"
4096LIBS="-lkvm  $LIBS"
4097cat > conftest.$ac_ext <<EOF
4098#line 4099 "configure"
4099#include "confdefs.h"
4100/* Override any gcc2 internal prototype to avoid an error.  */
4101/* We use char because int might match the return type of a gcc2
4102    builtin and then its argument prototype would still apply.  */
4103char kvm_open();
4104
4105int main() {
4106kvm_open()
4107; return 0; }
4108EOF
4109if { (eval echo configure:4110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4110  rm -rf conftest*
4111  eval "ac_cv_lib_$ac_lib_var=yes"
4112else
4113  echo "configure: failed program was:" >&5
4114  cat conftest.$ac_ext >&5
4115  rm -rf conftest*
4116  eval "ac_cv_lib_$ac_lib_var=no"
4117fi
4118rm -f conftest*
4119LIBS="$ac_save_LIBS"
4120
4121fi
4122if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4123  echo "$ac_t""yes" 1>&6
4124  LIBS="-lkvm $LIBS"
4125else
4126  echo "$ac_t""no" 1>&6
4127fi
4128
4129# Check for the 4.4BSD definition of getloadavg.
4130echo $ac_n "checking for getloadavg in -lutil""... $ac_c" 1>&6
4131echo "configure:4132: checking for getloadavg in -lutil" >&5
4132ac_lib_var=`echo util'_'getloadavg | sed 'y%./+-%__p_%'`
4133if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4134  echo $ac_n "(cached) $ac_c" 1>&6
4135else
4136  ac_save_LIBS="$LIBS"
4137LIBS="-lutil  $LIBS"
4138cat > conftest.$ac_ext <<EOF
4139#line 4140 "configure"
4140#include "confdefs.h"
4141/* Override any gcc2 internal prototype to avoid an error.  */
4142/* We use char because int might match the return type of a gcc2
4143    builtin and then its argument prototype would still apply.  */
4144char getloadavg();
4145
4146int main() {
4147getloadavg()
4148; return 0; }
4149EOF
4150if { (eval echo configure:4151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4151  rm -rf conftest*
4152  eval "ac_cv_lib_$ac_lib_var=yes"
4153else
4154  echo "configure: failed program was:" >&5
4155  cat conftest.$ac_ext >&5
4156  rm -rf conftest*
4157  eval "ac_cv_lib_$ac_lib_var=no"
4158fi
4159rm -f conftest*
4160LIBS="$ac_save_LIBS"
4161
4162fi
4163if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4164  echo "$ac_t""yes" 1>&6
4165  LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
4166else
4167  echo "$ac_t""no" 1>&6
4168fi
4169
4170
4171if test $ac_have_func = no; then
4172  # There is a commonly available library for RS/6000 AIX.
4173  # Since it is not a standard part of AIX, it might be installed locally.
4174  ac_getloadavg_LIBS="$LIBS"; LIBS="-L/usr/local/lib $LIBS"
4175  echo $ac_n "checking for getloadavg in -lgetloadavg""... $ac_c" 1>&6
4176echo "configure:4177: checking for getloadavg in -lgetloadavg" >&5
4177ac_lib_var=`echo getloadavg'_'getloadavg | sed 'y%./+-%__p_%'`
4178if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4179  echo $ac_n "(cached) $ac_c" 1>&6
4180else
4181  ac_save_LIBS="$LIBS"
4182LIBS="-lgetloadavg  $LIBS"
4183cat > conftest.$ac_ext <<EOF
4184#line 4185 "configure"
4185#include "confdefs.h"
4186/* Override any gcc2 internal prototype to avoid an error.  */
4187/* We use char because int might match the return type of a gcc2
4188    builtin and then its argument prototype would still apply.  */
4189char getloadavg();
4190
4191int main() {
4192getloadavg()
4193; return 0; }
4194EOF
4195if { (eval echo configure:4196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4196  rm -rf conftest*
4197  eval "ac_cv_lib_$ac_lib_var=yes"
4198else
4199  echo "configure: failed program was:" >&5
4200  cat conftest.$ac_ext >&5
4201  rm -rf conftest*
4202  eval "ac_cv_lib_$ac_lib_var=no"
4203fi
4204rm -f conftest*
4205LIBS="$ac_save_LIBS"
4206
4207fi
4208if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4209  echo "$ac_t""yes" 1>&6
4210  LIBS="-lgetloadavg $LIBS"
4211else
4212  echo "$ac_t""no" 1>&6
4213LIBS="$ac_getloadavg_LIBS"
4214fi
4215
4216fi
4217
4218# Make sure it is really in the library, if we think we found it.
4219for ac_func in getloadavg
4220do
4221echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4222echo "configure:4223: checking for $ac_func" >&5
4223if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4224  echo $ac_n "(cached) $ac_c" 1>&6
4225else
4226  cat > conftest.$ac_ext <<EOF
4227#line 4228 "configure"
4228#include "confdefs.h"
4229/* System header to define __stub macros and hopefully few prototypes,
4230    which can conflict with char $ac_func(); below.  */
4231#include <assert.h>
4232/* Override any gcc2 internal prototype to avoid an error.  */
4233/* We use char because int might match the return type of a gcc2
4234    builtin and then its argument prototype would still apply.  */
4235char $ac_func();
4236
4237int main() {
4238
4239/* The GNU C library defines this for functions which it implements
4240    to always fail with ENOSYS.  Some functions are actually named
4241    something starting with __ and the normal name is an alias.  */
4242#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4243choke me
4244#else
4245$ac_func();
4246#endif
4247
4248; return 0; }
4249EOF
4250if { (eval echo configure:4251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4251  rm -rf conftest*
4252  eval "ac_cv_func_$ac_func=yes"
4253else
4254  echo "configure: failed program was:" >&5
4255  cat conftest.$ac_ext >&5
4256  rm -rf conftest*
4257  eval "ac_cv_func_$ac_func=no"
4258fi
4259rm -f conftest*
4260fi
4261
4262if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4263  echo "$ac_t""yes" 1>&6
4264    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4265  cat >> confdefs.h <<EOF
4266#define $ac_tr_func 1
4267EOF
4268 
4269else
4270  echo "$ac_t""no" 1>&6
4271LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
4272fi
4273done
4274
4275
4276
4277if test $ac_cv_func_getloadavg = yes; then
4278  cat >> confdefs.h <<\EOF
4279#define HAVE_GETLOADAVG 1
4280EOF
4281
4282  ac_have_func=yes
4283else
4284  # Figure out what our getloadavg.c needs.
4285  ac_have_func=no
4286  ac_safe=`echo "sys/dg_sys_info.h" | sed 'y%./+-%__p_%'`
4287echo $ac_n "checking for sys/dg_sys_info.h""... $ac_c" 1>&6
4288echo "configure:4289: checking for sys/dg_sys_info.h" >&5
4289if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4290  echo $ac_n "(cached) $ac_c" 1>&6
4291else
4292  cat > conftest.$ac_ext <<EOF
4293#line 4294 "configure"
4294#include "confdefs.h"
4295#include <sys/dg_sys_info.h>
4296EOF
4297ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4298{ (eval echo configure:4299: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4299ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4300if test -z "$ac_err"; then
4301  rm -rf conftest*
4302  eval "ac_cv_header_$ac_safe=yes"
4303else
4304  echo "$ac_err" >&5
4305  echo "configure: failed program was:" >&5
4306  cat conftest.$ac_ext >&5
4307  rm -rf conftest*
4308  eval "ac_cv_header_$ac_safe=no"
4309fi
4310rm -f conftest*
4311fi
4312if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4313  echo "$ac_t""yes" 1>&6
4314  ac_have_func=yes; cat >> confdefs.h <<\EOF
4315#define DGUX 1
4316EOF
4317
4318  echo $ac_n "checking for dg_sys_info in -ldgc""... $ac_c" 1>&6
4319echo "configure:4320: checking for dg_sys_info in -ldgc" >&5
4320ac_lib_var=`echo dgc'_'dg_sys_info | sed 'y%./+-%__p_%'`
4321if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4322  echo $ac_n "(cached) $ac_c" 1>&6
4323else
4324  ac_save_LIBS="$LIBS"
4325LIBS="-ldgc  $LIBS"
4326cat > conftest.$ac_ext <<EOF
4327#line 4328 "configure"
4328#include "confdefs.h"
4329/* Override any gcc2 internal prototype to avoid an error.  */
4330/* We use char because int might match the return type of a gcc2
4331    builtin and then its argument prototype would still apply.  */
4332char dg_sys_info();
4333
4334int main() {
4335dg_sys_info()
4336; return 0; }
4337EOF
4338if { (eval echo configure:4339: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4339  rm -rf conftest*
4340  eval "ac_cv_lib_$ac_lib_var=yes"
4341else
4342  echo "configure: failed program was:" >&5
4343  cat conftest.$ac_ext >&5
4344  rm -rf conftest*
4345  eval "ac_cv_lib_$ac_lib_var=no"
4346fi
4347rm -f conftest*
4348LIBS="$ac_save_LIBS"
4349
4350fi
4351if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4352  echo "$ac_t""yes" 1>&6
4353    ac_tr_lib=HAVE_LIB`echo dgc | sed -e 's/[^a-zA-Z0-9_]/_/g' \
4354    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
4355  cat >> confdefs.h <<EOF
4356#define $ac_tr_lib 1
4357EOF
4358
4359  LIBS="-ldgc $LIBS"
4360
4361else
4362  echo "$ac_t""no" 1>&6
4363fi
4364
4365else
4366  echo "$ac_t""no" 1>&6
4367fi
4368
4369
4370  # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
4371  # uses stabs), but it is still SVR4.  We cannot check for <elf.h> because
4372  # Irix 4.0.5F has the header but not the library.
4373  if test $ac_have_func = no && test $ac_cv_lib_elf_elf_begin = yes; then
4374    ac_have_func=yes; cat >> confdefs.h <<\EOF
4375#define SVR4 1
4376EOF
4377
4378  fi
4379
4380  if test $ac_have_func = no; then
4381    ac_safe=`echo "inq_stats/cpustats.h" | sed 'y%./+-%__p_%'`
4382echo $ac_n "checking for inq_stats/cpustats.h""... $ac_c" 1>&6
4383echo "configure:4384: checking for inq_stats/cpustats.h" >&5
4384if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4385  echo $ac_n "(cached) $ac_c" 1>&6
4386else
4387  cat > conftest.$ac_ext <<EOF
4388#line 4389 "configure"
4389#include "confdefs.h"
4390#include <inq_stats/cpustats.h>
4391EOF
4392ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4393{ (eval echo configure:4394: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4394ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4395if test -z "$ac_err"; then
4396  rm -rf conftest*
4397  eval "ac_cv_header_$ac_safe=yes"
4398else
4399  echo "$ac_err" >&5
4400  echo "configure: failed program was:" >&5
4401  cat conftest.$ac_ext >&5
4402  rm -rf conftest*
4403  eval "ac_cv_header_$ac_safe=no"
4404fi
4405rm -f conftest*
4406fi
4407if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4408  echo "$ac_t""yes" 1>&6
4409  ac_have_func=yes; cat >> confdefs.h <<\EOF
4410#define UMAX 1
4411EOF
4412
4413    cat >> confdefs.h <<\EOF
4414#define UMAX4_3 1
4415EOF
4416
4417else
4418  echo "$ac_t""no" 1>&6
4419fi
4420
4421  fi
4422
4423  if test $ac_have_func = no; then
4424    ac_safe=`echo "sys/cpustats.h" | sed 'y%./+-%__p_%'`
4425echo $ac_n "checking for sys/cpustats.h""... $ac_c" 1>&6
4426echo "configure:4427: checking for sys/cpustats.h" >&5
4427if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4428  echo $ac_n "(cached) $ac_c" 1>&6
4429else
4430  cat > conftest.$ac_ext <<EOF
4431#line 4432 "configure"
4432#include "confdefs.h"
4433#include <sys/cpustats.h>
4434EOF
4435ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4436{ (eval echo configure:4437: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4437ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4438if test -z "$ac_err"; then
4439  rm -rf conftest*
4440  eval "ac_cv_header_$ac_safe=yes"
4441else
4442  echo "$ac_err" >&5
4443  echo "configure: failed program was:" >&5
4444  cat conftest.$ac_ext >&5
4445  rm -rf conftest*
4446  eval "ac_cv_header_$ac_safe=no"
4447fi
4448rm -f conftest*
4449fi
4450if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4451  echo "$ac_t""yes" 1>&6
4452  ac_have_func=yes; cat >> confdefs.h <<\EOF
4453#define UMAX 1
4454EOF
4455
4456else
4457  echo "$ac_t""no" 1>&6
4458fi
4459
4460  fi
4461
4462  if test $ac_have_func = no; then
4463    for ac_hdr in mach/mach.h
4464do
4465ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4466echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4467echo "configure:4468: checking for $ac_hdr" >&5
4468if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4469  echo $ac_n "(cached) $ac_c" 1>&6
4470else
4471  cat > conftest.$ac_ext <<EOF
4472#line 4473 "configure"
4473#include "confdefs.h"
4474#include <$ac_hdr>
4475EOF
4476ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4477{ (eval echo configure:4478: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4478ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4479if test -z "$ac_err"; then
4480  rm -rf conftest*
4481  eval "ac_cv_header_$ac_safe=yes"
4482else
4483  echo "$ac_err" >&5
4484  echo "configure: failed program was:" >&5
4485  cat conftest.$ac_ext >&5
4486  rm -rf conftest*
4487  eval "ac_cv_header_$ac_safe=no"
4488fi
4489rm -f conftest*
4490fi
4491if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4492  echo "$ac_t""yes" 1>&6
4493    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4494  cat >> confdefs.h <<EOF
4495#define $ac_tr_hdr 1
4496EOF
4497 
4498else
4499  echo "$ac_t""no" 1>&6
4500fi
4501done
4502
4503  fi
4504
4505  ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'`
4506echo $ac_n "checking for nlist.h""... $ac_c" 1>&6
4507echo "configure:4508: checking for nlist.h" >&5
4508if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4509  echo $ac_n "(cached) $ac_c" 1>&6
4510else
4511  cat > conftest.$ac_ext <<EOF
4512#line 4513 "configure"
4513#include "confdefs.h"
4514#include <nlist.h>
4515EOF
4516ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4517{ (eval echo configure:4518: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4518ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4519if test -z "$ac_err"; then
4520  rm -rf conftest*
4521  eval "ac_cv_header_$ac_safe=yes"
4522else
4523  echo "$ac_err" >&5
4524  echo "configure: failed program was:" >&5
4525  cat conftest.$ac_ext >&5
4526  rm -rf conftest*
4527  eval "ac_cv_header_$ac_safe=no"
4528fi
4529rm -f conftest*
4530fi
4531if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4532  echo "$ac_t""yes" 1>&6
4533  cat >> confdefs.h <<\EOF
4534#define NLIST_STRUCT 1
4535EOF
4536
4537  echo $ac_n "checking for n_un in struct nlist""... $ac_c" 1>&6
4538echo "configure:4539: checking for n_un in struct nlist" >&5
4539if eval "test \"`echo '$''{'ac_cv_struct_nlist_n_un'+set}'`\" = set"; then
4540  echo $ac_n "(cached) $ac_c" 1>&6
4541else
4542  cat > conftest.$ac_ext <<EOF
4543#line 4544 "configure"
4544#include "confdefs.h"
4545#include <nlist.h>
4546int main() {
4547struct nlist n; n.n_un.n_name = 0;
4548; return 0; }
4549EOF
4550if { (eval echo configure:4551: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4551  rm -rf conftest*
4552  ac_cv_struct_nlist_n_un=yes
4553else
4554  echo "configure: failed program was:" >&5
4555  cat conftest.$ac_ext >&5
4556  rm -rf conftest*
4557  ac_cv_struct_nlist_n_un=no
4558fi
4559rm -f conftest*
4560fi
4561
4562echo "$ac_t""$ac_cv_struct_nlist_n_un" 1>&6
4563  if test $ac_cv_struct_nlist_n_un = yes; then
4564    cat >> confdefs.h <<\EOF
4565#define NLIST_NAME_UNION 1
4566EOF
4567
4568  fi
4569 
4570else
4571  echo "$ac_t""no" 1>&6
4572fi
4573fi # Do not have getloadavg in system libraries.
4574
4575# Some definitions of getloadavg require that the program be installed setgid.
4576echo $ac_n "checking whether getloadavg requires setgid""... $ac_c" 1>&6
4577echo "configure:4578: checking whether getloadavg requires setgid" >&5
4578if eval "test \"`echo '$''{'ac_cv_func_getloadavg_setgid'+set}'`\" = set"; then
4579  echo $ac_n "(cached) $ac_c" 1>&6
4580else
4581  cat > conftest.$ac_ext <<EOF
4582#line 4583 "configure"
4583#include "confdefs.h"
4584#include "$srcdir/getloadavg.c"
4585#ifdef LDAV_PRIVILEGED
4586Yowza Am I SETGID yet
4587#endif
4588EOF
4589if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4590  egrep "Yowza Am I SETGID yet" >/dev/null 2>&1; then
4591  rm -rf conftest*
4592  ac_cv_func_getloadavg_setgid=yes
4593else
4594  rm -rf conftest*
4595  ac_cv_func_getloadavg_setgid=no
4596fi
4597rm -f conftest*
4598
4599fi
4600
4601echo "$ac_t""$ac_cv_func_getloadavg_setgid" 1>&6
4602if test $ac_cv_func_getloadavg_setgid = yes; then
4603  NEED_SETGID=true; cat >> confdefs.h <<\EOF
4604#define GETLOADAVG_PRIVILEGED 1
4605EOF
4606
4607else
4608  NEED_SETGID=false
4609fi
4610
4611if test $ac_cv_func_getloadavg_setgid = yes; then
4612  echo $ac_n "checking group of /dev/kmem""... $ac_c" 1>&6
4613echo "configure:4614: checking group of /dev/kmem" >&5
4614if eval "test \"`echo '$''{'ac_cv_group_kmem'+set}'`\" = set"; then
4615  echo $ac_n "(cached) $ac_c" 1>&6
4616else
4617    # On Solaris, /dev/kmem is a symlink.  Get info on the real file.
4618  ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
4619  # If we got an error (system does not support symlinks), try without -L.
4620  test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
4621  ac_cv_group_kmem=`echo $ac_ls_output \
4622    | sed -ne 's/[      ][      ]*/ /g;
4623               s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\)  *.*/\1/;
4624               / /s/.* //;p;'`
4625
4626fi
4627
4628echo "$ac_t""$ac_cv_group_kmem" 1>&6
4629  KMEM_GROUP=$ac_cv_group_kmem
4630fi
4631
4632
4633# Check out the wait reality.
4634for ac_hdr in sys/wait.h
4635do
4636ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4637echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4638echo "configure:4639: checking for $ac_hdr" >&5
4639if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4640  echo $ac_n "(cached) $ac_c" 1>&6
4641else
4642  cat > conftest.$ac_ext <<EOF
4643#line 4644 "configure"
4644#include "confdefs.h"
4645#include <$ac_hdr>
4646EOF
4647ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4648{ (eval echo configure:4649: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4649ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4650if test -z "$ac_err"; then
4651  rm -rf conftest*
4652  eval "ac_cv_header_$ac_safe=yes"
4653else
4654  echo "$ac_err" >&5
4655  echo "configure: failed program was:" >&5
4656  cat conftest.$ac_ext >&5
4657  rm -rf conftest*
4658  eval "ac_cv_header_$ac_safe=no"
4659fi
4660rm -f conftest*
4661fi
4662if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4663  echo "$ac_t""yes" 1>&6
4664    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4665  cat >> confdefs.h <<EOF
4666#define $ac_tr_hdr 1
4667EOF
4668 
4669else
4670  echo "$ac_t""no" 1>&6
4671fi
4672done
4673
4674for ac_func in waitpid wait3
4675do
4676echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4677echo "configure:4678: checking for $ac_func" >&5
4678if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4679  echo $ac_n "(cached) $ac_c" 1>&6
4680else
4681  cat > conftest.$ac_ext <<EOF
4682#line 4683 "configure"
4683#include "confdefs.h"
4684/* System header to define __stub macros and hopefully few prototypes,
4685    which can conflict with char $ac_func(); below.  */
4686#include <assert.h>
4687/* Override any gcc2 internal prototype to avoid an error.  */
4688/* We use char because int might match the return type of a gcc2
4689    builtin and then its argument prototype would still apply.  */
4690char $ac_func();
4691
4692int main() {
4693
4694/* The GNU C library defines this for functions which it implements
4695    to always fail with ENOSYS.  Some functions are actually named
4696    something starting with __ and the normal name is an alias.  */
4697#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4698choke me
4699#else
4700$ac_func();
4701#endif
4702
4703; return 0; }
4704EOF
4705if { (eval echo configure:4706: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4706  rm -rf conftest*
4707  eval "ac_cv_func_$ac_func=yes"
4708else
4709  echo "configure: failed program was:" >&5
4710  cat conftest.$ac_ext >&5
4711  rm -rf conftest*
4712  eval "ac_cv_func_$ac_func=no"
4713fi
4714rm -f conftest*
4715fi
4716
4717if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4718  echo "$ac_t""yes" 1>&6
4719    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4720  cat >> confdefs.h <<EOF
4721#define $ac_tr_func 1
4722EOF
4723 
4724else
4725  echo "$ac_t""no" 1>&6
4726fi
4727done
4728
4729echo $ac_n "checking for union wait""... $ac_c" 1>&6
4730echo "configure:4731: checking for union wait" >&5
4731if eval "test \"`echo '$''{'make_cv_union_wait'+set}'`\" = set"; then
4732  echo $ac_n "(cached) $ac_c" 1>&6
4733else
4734  cat > conftest.$ac_ext <<EOF
4735#line 4736 "configure"
4736#include "confdefs.h"
4737#include <sys/types.h>
4738#include <sys/wait.h>
4739int main() {
4740union wait status; int pid; pid = wait (&status);
4741#ifdef WEXITSTATUS
4742/* Some POSIXoid systems have both the new-style macros and the old
4743   union wait type, and they do not work together.  If union wait
4744   conflicts with WEXITSTATUS et al, we don't want to use it at all.  */
4745if (WEXITSTATUS (status) != 0) pid = -1;
4746#ifdef WTERMSIG
4747/* If we have WEXITSTATUS and WTERMSIG, just use them on ints.  */
4748-- blow chunks here --
4749#endif
4750#endif
4751#ifdef HAVE_WAITPID
4752/* Make sure union wait works with waitpid.  */
4753pid = waitpid (-1, &status, 0);
4754#endif
4755
4756; return 0; }
4757EOF
4758if { (eval echo configure:4759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4759  rm -rf conftest*
4760  make_cv_union_wait=yes
4761else
4762  echo "configure: failed program was:" >&5
4763  cat conftest.$ac_ext >&5
4764  rm -rf conftest*
4765  make_cv_union_wait=no
4766fi
4767rm -f conftest*
4768fi
4769
4770if test "$make_cv_union_wait" = yes; then
4771  cat >> confdefs.h <<\EOF
4772#define HAVE_UNION_WAIT 1
4773EOF
4774
4775fi
4776echo "$ac_t""$make_cv_union_wait" 1>&6
4777
4778echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6
4779echo "configure:4780: checking for sys_siglist declaration in signal.h or unistd.h" >&5
4780if eval "test \"`echo '$''{'ac_cv_decl_sys_siglist'+set}'`\" = set"; then
4781  echo $ac_n "(cached) $ac_c" 1>&6
4782else
4783  cat > conftest.$ac_ext <<EOF
4784#line 4785 "configure"
4785#include "confdefs.h"
4786#include <sys/types.h>
4787#include <signal.h>
4788/* NetBSD declares sys_siglist in unistd.h.  */
4789#ifdef HAVE_UNISTD_H
4790#include <unistd.h>
4791#endif
4792int main() {
4793char *msg = *(sys_siglist + 1);
4794; return 0; }
4795EOF
4796if { (eval echo configure:4797: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4797  rm -rf conftest*
4798  ac_cv_decl_sys_siglist=yes
4799else
4800  echo "configure: failed program was:" >&5
4801  cat conftest.$ac_ext >&5
4802  rm -rf conftest*
4803  ac_cv_decl_sys_siglist=no
4804fi
4805rm -f conftest*
4806fi
4807
4808echo "$ac_t""$ac_cv_decl_sys_siglist" 1>&6
4809if test $ac_cv_decl_sys_siglist = yes; then
4810  cat >> confdefs.h <<\EOF
4811#define SYS_SIGLIST_DECLARED 1
4812EOF
4813
4814fi
4815
4816
4817# The presence of the following is not meant to imply
4818# that make necessarily works on those systems.
4819
4820echo $ac_n "checking for library containing getpwnam""... $ac_c" 1>&6
4821echo "configure:4822: checking for library containing getpwnam" >&5
4822if eval "test \"`echo '$''{'ac_cv_search_getpwnam'+set}'`\" = set"; then
4823  echo $ac_n "(cached) $ac_c" 1>&6
4824else
4825  ac_func_search_save_LIBS="$LIBS"
4826ac_cv_search_getpwnam="no"
4827cat > conftest.$ac_ext <<EOF
4828#line 4829 "configure"
4829#include "confdefs.h"
4830/* Override any gcc2 internal prototype to avoid an error.  */
4831/* We use char because int might match the return type of a gcc2
4832    builtin and then its argument prototype would still apply.  */
4833char getpwnam();
4834
4835int main() {
4836getpwnam()
4837; return 0; }
4838EOF
4839if { (eval echo configure:4840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4840  rm -rf conftest*
4841  ac_cv_search_getpwnam="none required"
4842else
4843  echo "configure: failed program was:" >&5
4844  cat conftest.$ac_ext >&5
4845fi
4846rm -f conftest*
4847test "$ac_cv_search_getpwnam" = "no" && for i in sun; do
4848LIBS="-l$i  $ac_func_search_save_LIBS"
4849cat > conftest.$ac_ext <<EOF
4850#line 4851 "configure"
4851#include "confdefs.h"
4852/* Override any gcc2 internal prototype to avoid an error.  */
4853/* We use char because int might match the return type of a gcc2
4854    builtin and then its argument prototype would still apply.  */
4855char getpwnam();
4856
4857int main() {
4858getpwnam()
4859; return 0; }
4860EOF
4861if { (eval echo configure:4862: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4862  rm -rf conftest*
4863  ac_cv_search_getpwnam="-l$i"
4864break
4865else
4866  echo "configure: failed program was:" >&5
4867  cat conftest.$ac_ext >&5
4868fi
4869rm -f conftest*
4870done
4871LIBS="$ac_func_search_save_LIBS"
4872fi
4873
4874echo "$ac_t""$ac_cv_search_getpwnam" 1>&6
4875if test "$ac_cv_search_getpwnam" != "no"; then
4876  test "$ac_cv_search_getpwnam" = "none required" || LIBS="$ac_cv_search_getpwnam $LIBS"
4877 
4878else :
4879 
4880fi
4881
4882 REMOTE=stub
4883make_try_customs=no
4884# Check whether --with-customs or --without-customs was given.
4885if test "${with_customs+set}" = set; then
4886  withval="$with_customs"
4887  case "$withval" in
4888  n|no) ;;
4889  *) make_cppflags="$CPPFLAGS"
4890     case "$withval" in
4891       y|ye|yes) ;;
4892       *) CPPFLAGS="$CPPFLAGS -I$with_customs/include/customs"
4893          make_ldflags="$LDFLAGS -L$with_customs/lib" ;;
4894     esac
4895     
4896cf_test_netlibs=no
4897echo $ac_n "checking for network libraries""... $ac_c" 1>&6
4898echo "configure:4899: checking for network libraries" >&5
4899if eval "test \"`echo '$''{'cf_cv_netlibs'+set}'`\" = set"; then
4900  echo $ac_n "(cached) $ac_c" 1>&6
4901else
4902 
4903echo "$ac_t""working..." 1>&6
4904cf_cv_netlibs=""
4905cf_test_netlibs=yes
4906for ac_func in gethostname
4907do
4908echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4909echo "configure:4910: checking for $ac_func" >&5
4910if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4911  echo $ac_n "(cached) $ac_c" 1>&6
4912else
4913  cat > conftest.$ac_ext <<EOF
4914#line 4915 "configure"
4915#include "confdefs.h"
4916/* System header to define __stub macros and hopefully few prototypes,
4917    which can conflict with char $ac_func(); below.  */
4918#include <assert.h>
4919/* Override any gcc2 internal prototype to avoid an error.  */
4920/* We use char because int might match the return type of a gcc2
4921    builtin and then its argument prototype would still apply.  */
4922char $ac_func();
4923
4924int main() {
4925
4926/* The GNU C library defines this for functions which it implements
4927    to always fail with ENOSYS.  Some functions are actually named
4928    something starting with __ and the normal name is an alias.  */
4929#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4930choke me
4931#else
4932$ac_func();
4933#endif
4934
4935; return 0; }
4936EOF
4937if { (eval echo configure:4938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4938  rm -rf conftest*
4939  eval "ac_cv_func_$ac_func=yes"
4940else
4941  echo "configure: failed program was:" >&5
4942  cat conftest.$ac_ext >&5
4943  rm -rf conftest*
4944  eval "ac_cv_func_$ac_func=no"
4945fi
4946rm -f conftest*
4947fi
4948
4949if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4950  echo "$ac_t""yes" 1>&6
4951    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4952  cat >> confdefs.h <<EOF
4953#define $ac_tr_func 1
4954EOF
4955 
4956else
4957  echo "$ac_t""no" 1>&6
4958
4959echo $ac_n "checking for gethostname in -lnsl""... $ac_c" 1>&6
4960echo "configure:4961: checking for gethostname in -lnsl" >&5
4961ac_lib_var=`echo nsl'_'gethostname | sed 'y%./+-%__p_%'`
4962if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4963  echo $ac_n "(cached) $ac_c" 1>&6
4964else
4965  ac_save_LIBS="$LIBS"
4966LIBS="-lnsl $cf_cv_netlibs $LIBS"
4967cat > conftest.$ac_ext <<EOF
4968#line 4969 "configure"
4969#include "confdefs.h"
4970/* Override any gcc2 internal prototype to avoid an error.  */
4971/* We use char because int might match the return type of a gcc2
4972    builtin and then its argument prototype would still apply.  */
4973char gethostname();
4974
4975int main() {
4976gethostname()
4977; return 0; }
4978EOF
4979if { (eval echo configure:4980: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4980  rm -rf conftest*
4981  eval "ac_cv_lib_$ac_lib_var=yes"
4982else
4983  echo "configure: failed program was:" >&5
4984  cat conftest.$ac_ext >&5
4985  rm -rf conftest*
4986  eval "ac_cv_lib_$ac_lib_var=no"
4987fi
4988rm -f conftest*
4989LIBS="$ac_save_LIBS"
4990
4991fi
4992if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4993  echo "$ac_t""yes" 1>&6
4994 
4995       
4996cf_tr_func=`echo gethostname | tr 'a-z' 'A-Z'`
4997
4998        cat >> confdefs.h <<EOF
4999#define HAVE_$cf_tr_func 1
5000EOF
5001
5002        ac_cv_func_gethostname=yes
5003        cf_cv_netlibs="-lnsl $cf_cv_netlibs"
5004else
5005  echo "$ac_t""no" 1>&6
5006
5007        ac_cv_func_gethostname=unknown
5008        unset ac_cv_func_gethostname 2>/dev/null
5009       
5010               
5011echo $ac_n "checking for gethostname in -lsocket""... $ac_c" 1>&6
5012echo "configure:5013: checking for gethostname in -lsocket" >&5
5013ac_lib_var=`echo socket'_'gethostname | sed 'y%./+-%__p_%'`
5014if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5015  echo $ac_n "(cached) $ac_c" 1>&6
5016else
5017  ac_save_LIBS="$LIBS"
5018LIBS="-lsocket $cf_cv_netlibs $LIBS"
5019cat > conftest.$ac_ext <<EOF
5020#line 5021 "configure"
5021#include "confdefs.h"
5022/* Override any gcc2 internal prototype to avoid an error.  */
5023/* We use char because int might match the return type of a gcc2
5024    builtin and then its argument prototype would still apply.  */
5025char gethostname();
5026
5027int main() {
5028gethostname()
5029; return 0; }
5030EOF
5031if { (eval echo configure:5032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5032  rm -rf conftest*
5033  eval "ac_cv_lib_$ac_lib_var=yes"
5034else
5035  echo "configure: failed program was:" >&5
5036  cat conftest.$ac_ext >&5
5037  rm -rf conftest*
5038  eval "ac_cv_lib_$ac_lib_var=no"
5039fi
5040rm -f conftest*
5041LIBS="$ac_save_LIBS"
5042
5043fi
5044if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5045  echo "$ac_t""yes" 1>&6
5046 
5047       
5048cf_tr_func=`echo gethostname | tr 'a-z' 'A-Z'`
5049
5050        cat >> confdefs.h <<EOF
5051#define HAVE_$cf_tr_func 1
5052EOF
5053
5054        ac_cv_func_gethostname=yes
5055        cf_cv_netlibs="-lsocket $cf_cv_netlibs"
5056else
5057  echo "$ac_t""no" 1>&6
5058
5059        ac_cv_func_gethostname=unknown
5060        unset ac_cv_func_gethostname 2>/dev/null
5061       
5062fi
5063
5064
5065fi
5066
5067
5068fi
5069done
5070
5071#
5072# FIXME:  sequent needs this library (i.e., -lsocket -linet -lnsl), but
5073# I don't know the entrypoints - 97/7/22 TD
5074echo $ac_n "checking for main in -linet""... $ac_c" 1>&6
5075echo "configure:5076: checking for main in -linet" >&5
5076ac_lib_var=`echo inet'_'main | sed 'y%./+-%__p_%'`
5077if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5078  echo $ac_n "(cached) $ac_c" 1>&6
5079else
5080  ac_save_LIBS="$LIBS"
5081LIBS="-linet  $LIBS"
5082cat > conftest.$ac_ext <<EOF
5083#line 5084 "configure"
5084#include "confdefs.h"
5085
5086int main() {
5087main()
5088; return 0; }
5089EOF
5090if { (eval echo configure:5091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5091  rm -rf conftest*
5092  eval "ac_cv_lib_$ac_lib_var=yes"
5093else
5094  echo "configure: failed program was:" >&5
5095  cat conftest.$ac_ext >&5
5096  rm -rf conftest*
5097  eval "ac_cv_lib_$ac_lib_var=no"
5098fi
5099rm -f conftest*
5100LIBS="$ac_save_LIBS"
5101
5102fi
5103if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5104  echo "$ac_t""yes" 1>&6
5105  cf_cv_netlibs="-linet $cf_cv_netlibs"
5106else
5107  echo "$ac_t""no" 1>&6
5108fi
5109
5110#
5111if test "$ac_cv_func_lsocket" != no ; then
5112for ac_func in socket
5113do
5114echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5115echo "configure:5116: checking for $ac_func" >&5
5116if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5117  echo $ac_n "(cached) $ac_c" 1>&6
5118else
5119  cat > conftest.$ac_ext <<EOF
5120#line 5121 "configure"
5121#include "confdefs.h"
5122/* System header to define __stub macros and hopefully few prototypes,
5123    which can conflict with char $ac_func(); below.  */
5124#include <assert.h>
5125/* Override any gcc2 internal prototype to avoid an error.  */
5126/* We use char because int might match the return type of a gcc2
5127    builtin and then its argument prototype would still apply.  */
5128char $ac_func();
5129
5130int main() {
5131
5132/* The GNU C library defines this for functions which it implements
5133    to always fail with ENOSYS.  Some functions are actually named
5134    something starting with __ and the normal name is an alias.  */
5135#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5136choke me
5137#else
5138$ac_func();
5139#endif
5140
5141; return 0; }
5142EOF
5143if { (eval echo configure:5144: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5144  rm -rf conftest*
5145  eval "ac_cv_func_$ac_func=yes"
5146else
5147  echo "configure: failed program was:" >&5
5148  cat conftest.$ac_ext >&5
5149  rm -rf conftest*
5150  eval "ac_cv_func_$ac_func=no"
5151fi
5152rm -f conftest*
5153fi
5154
5155if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5156  echo "$ac_t""yes" 1>&6
5157    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5158  cat >> confdefs.h <<EOF
5159#define $ac_tr_func 1
5160EOF
5161 
5162else
5163  echo "$ac_t""no" 1>&6
5164
5165echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
5166echo "configure:5167: checking for socket in -lsocket" >&5
5167ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
5168if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5169  echo $ac_n "(cached) $ac_c" 1>&6
5170else
5171  ac_save_LIBS="$LIBS"
5172LIBS="-lsocket $cf_cv_netlibs $LIBS"
5173cat > conftest.$ac_ext <<EOF
5174#line 5175 "configure"
5175#include "confdefs.h"
5176/* Override any gcc2 internal prototype to avoid an error.  */
5177/* We use char because int might match the return type of a gcc2
5178    builtin and then its argument prototype would still apply.  */
5179char socket();
5180
5181int main() {
5182socket()
5183; return 0; }
5184EOF
5185if { (eval echo configure:5186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5186  rm -rf conftest*
5187  eval "ac_cv_lib_$ac_lib_var=yes"
5188else
5189  echo "configure: failed program was:" >&5
5190  cat conftest.$ac_ext >&5
5191  rm -rf conftest*
5192  eval "ac_cv_lib_$ac_lib_var=no"
5193fi
5194rm -f conftest*
5195LIBS="$ac_save_LIBS"
5196
5197fi
5198if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5199  echo "$ac_t""yes" 1>&6
5200 
5201       
5202cf_tr_func=`echo socket | tr 'a-z' 'A-Z'`
5203
5204        cat >> confdefs.h <<EOF
5205#define HAVE_$cf_tr_func 1
5206EOF
5207
5208        ac_cv_func_socket=yes
5209        cf_cv_netlibs="-lsocket $cf_cv_netlibs"
5210else
5211  echo "$ac_t""no" 1>&6
5212
5213        ac_cv_func_socket=unknown
5214        unset ac_cv_func_socket 2>/dev/null
5215       
5216               
5217echo $ac_n "checking for socket in -lbsd""... $ac_c" 1>&6
5218echo "configure:5219: checking for socket in -lbsd" >&5
5219ac_lib_var=`echo bsd'_'socket | sed 'y%./+-%__p_%'`
5220if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5221  echo $ac_n "(cached) $ac_c" 1>&6
5222else
5223  ac_save_LIBS="$LIBS"
5224LIBS="-lbsd $cf_cv_netlibs $LIBS"
5225cat > conftest.$ac_ext <<EOF
5226#line 5227 "configure"
5227#include "confdefs.h"
5228/* Override any gcc2 internal prototype to avoid an error.  */
5229/* We use char because int might match the return type of a gcc2
5230    builtin and then its argument prototype would still apply.  */
5231char socket();
5232
5233int main() {
5234socket()
5235; return 0; }
5236EOF
5237if { (eval echo configure:5238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5238  rm -rf conftest*
5239  eval "ac_cv_lib_$ac_lib_var=yes"
5240else
5241  echo "configure: failed program was:" >&5
5242  cat conftest.$ac_ext >&5
5243  rm -rf conftest*
5244  eval "ac_cv_lib_$ac_lib_var=no"
5245fi
5246rm -f conftest*
5247LIBS="$ac_save_LIBS"
5248
5249fi
5250if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5251  echo "$ac_t""yes" 1>&6
5252 
5253       
5254cf_tr_func=`echo socket | tr 'a-z' 'A-Z'`
5255
5256        cat >> confdefs.h <<EOF
5257#define HAVE_$cf_tr_func 1
5258EOF
5259
5260        ac_cv_func_socket=yes
5261        cf_cv_netlibs="-lbsd $cf_cv_netlibs"
5262else
5263  echo "$ac_t""no" 1>&6
5264
5265        ac_cv_func_socket=unknown
5266        unset ac_cv_func_socket 2>/dev/null
5267       
5268fi
5269
5270
5271fi
5272
5273
5274fi
5275done
5276
5277fi
5278#
5279for ac_func in gethostbyname
5280do
5281echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5282echo "configure:5283: checking for $ac_func" >&5
5283if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5284  echo $ac_n "(cached) $ac_c" 1>&6
5285else
5286  cat > conftest.$ac_ext <<EOF
5287#line 5288 "configure"
5288#include "confdefs.h"
5289/* System header to define __stub macros and hopefully few prototypes,
5290    which can conflict with char $ac_func(); below.  */
5291#include <assert.h>
5292/* Override any gcc2 internal prototype to avoid an error.  */
5293/* We use char because int might match the return type of a gcc2
5294    builtin and then its argument prototype would still apply.  */
5295char $ac_func();
5296
5297int main() {
5298
5299/* The GNU C library defines this for functions which it implements
5300    to always fail with ENOSYS.  Some functions are actually named
5301    something starting with __ and the normal name is an alias.  */
5302#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5303choke me
5304#else
5305$ac_func();
5306#endif
5307
5308; return 0; }
5309EOF
5310if { (eval echo configure:5311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5311  rm -rf conftest*
5312  eval "ac_cv_func_$ac_func=yes"
5313else
5314  echo "configure: failed program was:" >&5
5315  cat conftest.$ac_ext >&5
5316  rm -rf conftest*
5317  eval "ac_cv_func_$ac_func=no"
5318fi
5319rm -f conftest*
5320fi
5321
5322if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5323  echo "$ac_t""yes" 1>&6
5324    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5325  cat >> confdefs.h <<EOF
5326#define $ac_tr_func 1
5327EOF
5328 
5329else
5330  echo "$ac_t""no" 1>&6
5331
5332echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
5333echo "configure:5334: checking for gethostbyname in -lnsl" >&5
5334ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
5335if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5336  echo $ac_n "(cached) $ac_c" 1>&6
5337else
5338  ac_save_LIBS="$LIBS"
5339LIBS="-lnsl $cf_cv_netlibs $LIBS"
5340cat > conftest.$ac_ext <<EOF
5341#line 5342 "configure"
5342#include "confdefs.h"
5343/* Override any gcc2 internal prototype to avoid an error.  */
5344/* We use char because int might match the return type of a gcc2
5345    builtin and then its argument prototype would still apply.  */
5346char gethostbyname();
5347
5348int main() {
5349gethostbyname()
5350; return 0; }
5351EOF
5352if { (eval echo configure:5353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5353  rm -rf conftest*
5354  eval "ac_cv_lib_$ac_lib_var=yes"
5355else
5356  echo "configure: failed program was:" >&5
5357  cat conftest.$ac_ext >&5
5358  rm -rf conftest*
5359  eval "ac_cv_lib_$ac_lib_var=no"
5360fi
5361rm -f conftest*
5362LIBS="$ac_save_LIBS"
5363
5364fi
5365if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5366  echo "$ac_t""yes" 1>&6
5367 
5368       
5369cf_tr_func=`echo gethostbyname | tr 'a-z' 'A-Z'`
5370
5371        cat >> confdefs.h <<EOF
5372#define HAVE_$cf_tr_func 1
5373EOF
5374
5375        ac_cv_func_gethostbyname=yes
5376        cf_cv_netlibs="-lnsl $cf_cv_netlibs"
5377else
5378  echo "$ac_t""no" 1>&6
5379
5380        ac_cv_func_gethostbyname=unknown
5381        unset ac_cv_func_gethostbyname 2>/dev/null
5382       
5383fi
5384
5385
5386fi
5387done
5388
5389#
5390for ac_func in strcasecmp
5391do
5392echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5393echo "configure:5394: checking for $ac_func" >&5
5394if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5395  echo $ac_n "(cached) $ac_c" 1>&6
5396else
5397  cat > conftest.$ac_ext <<EOF
5398#line 5399 "configure"
5399#include "confdefs.h"
5400/* System header to define __stub macros and hopefully few prototypes,
5401    which can conflict with char $ac_func(); below.  */
5402#include <assert.h>
5403/* Override any gcc2 internal prototype to avoid an error.  */
5404/* We use char because int might match the return type of a gcc2
5405    builtin and then its argument prototype would still apply.  */
5406char $ac_func();
5407
5408int main() {
5409
5410/* The GNU C library defines this for functions which it implements
5411    to always fail with ENOSYS.  Some functions are actually named
5412    something starting with __ and the normal name is an alias.  */
5413#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5414choke me
5415#else
5416$ac_func();
5417#endif
5418
5419; return 0; }
5420EOF
5421if { (eval echo configure:5422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5422  rm -rf conftest*
5423  eval "ac_cv_func_$ac_func=yes"
5424else
5425  echo "configure: failed program was:" >&5
5426  cat conftest.$ac_ext >&5
5427  rm -rf conftest*
5428  eval "ac_cv_func_$ac_func=no"
5429fi
5430rm -f conftest*
5431fi
5432
5433if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5434  echo "$ac_t""yes" 1>&6
5435    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5436  cat >> confdefs.h <<EOF
5437#define $ac_tr_func 1
5438EOF
5439 
5440else
5441  echo "$ac_t""no" 1>&6
5442
5443echo $ac_n "checking for strcasecmp in -lresolv""... $ac_c" 1>&6
5444echo "configure:5445: checking for strcasecmp in -lresolv" >&5
5445ac_lib_var=`echo resolv'_'strcasecmp | sed 'y%./+-%__p_%'`
5446if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5447  echo $ac_n "(cached) $ac_c" 1>&6
5448else
5449  ac_save_LIBS="$LIBS"
5450LIBS="-lresolv $cf_cv_netlibs $LIBS"
5451cat > conftest.$ac_ext <<EOF
5452#line 5453 "configure"
5453#include "confdefs.h"
5454/* Override any gcc2 internal prototype to avoid an error.  */
5455/* We use char because int might match the return type of a gcc2
5456    builtin and then its argument prototype would still apply.  */
5457char strcasecmp();
5458
5459int main() {
5460strcasecmp()
5461; return 0; }
5462EOF
5463if { (eval echo configure:5464: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5464  rm -rf conftest*
5465  eval "ac_cv_lib_$ac_lib_var=yes"
5466else
5467  echo "configure: failed program was:" >&5
5468  cat conftest.$ac_ext >&5
5469  rm -rf conftest*
5470  eval "ac_cv_lib_$ac_lib_var=no"
5471fi
5472rm -f conftest*
5473LIBS="$ac_save_LIBS"
5474
5475fi
5476if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5477  echo "$ac_t""yes" 1>&6
5478 
5479       
5480cf_tr_func=`echo strcasecmp | tr 'a-z' 'A-Z'`
5481
5482        cat >> confdefs.h <<EOF
5483#define HAVE_$cf_tr_func 1
5484EOF
5485
5486        ac_cv_func_strcasecmp=yes
5487        cf_cv_netlibs="-lresolv $cf_cv_netlibs"
5488else
5489  echo "$ac_t""no" 1>&6
5490
5491        ac_cv_func_strcasecmp=unknown
5492        unset ac_cv_func_strcasecmp 2>/dev/null
5493       
5494fi
5495
5496
5497fi
5498done
5499
5500
5501fi
5502
5503LIBS="$LIBS $cf_cv_netlibs"
5504test $cf_test_netlibs = no && echo "$cf_cv_netlibs" >&6
5505
5506     ac_safe=`echo "customs.h" | sed 'y%./+-%__p_%'`
5507echo $ac_n "checking for customs.h""... $ac_c" 1>&6
5508echo "configure:5509: checking for customs.h" >&5
5509if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5510  echo $ac_n "(cached) $ac_c" 1>&6
5511else
5512  cat > conftest.$ac_ext <<EOF
5513#line 5514 "configure"
5514#include "confdefs.h"
5515#include <customs.h>
5516EOF
5517ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5518{ (eval echo configure:5519: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5519ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5520if test -z "$ac_err"; then
5521  rm -rf conftest*
5522  eval "ac_cv_header_$ac_safe=yes"
5523else
5524  echo "$ac_err" >&5
5525  echo "configure: failed program was:" >&5
5526  cat conftest.$ac_ext >&5
5527  rm -rf conftest*
5528  eval "ac_cv_header_$ac_safe=no"
5529fi
5530rm -f conftest*
5531fi
5532if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5533  echo "$ac_t""yes" 1>&6
5534  REMOTE=cstms
5535                       LIBS="$LIBS -lcustoms" LDFLAGS="$make_ldflags"
5536else
5537  echo "$ac_t""no" 1>&6
5538with_customs=no
5539                       CPPFLAGS="$make_cppflags" make_badcust=yes
5540fi
5541
5542     ;;
5543esac
5544fi
5545
5546
5547
5548# Check whether --enable-job-server or --disable-job-server was given.
5549if test "${enable_job_server+set}" = set; then
5550  enableval="$enable_job_server"
5551  make_cv_job_server="$enableval" user_job_server="$enableval"
5552else
5553  make_cv_job_server="yes"
5554fi
5555
5556
5557has_wait_nohang=yes
5558case "$ac_cv_func_waitpid/$ac_cv_func_wait3" in
5559  no/no) has_wait_nohang=no ;;
5560esac
5561
5562case "$ac_cv_func_pipe/$ac_cv_func_sigaction/$has_wait_nohang/$make_cv_job_server" in
5563  yes/yes/yes/yes) cat >> confdefs.h <<\EOF
5564#define MAKE_JOBSERVER 1
5565EOF
5566;;
5567esac
5568
5569
5570# Check whether --enable-dmalloc or --disable-dmalloc was given.
5571if test "${enable_dmalloc+set}" = set; then
5572  enableval="$enable_dmalloc"
5573  make_cv_dmalloc="$enableval"
5574else
5575  make_cv_dmalloc="no"
5576fi
5577
5578
5579case "$make_cv_dmalloc" in
5580  yes) for ac_hdr in dmalloc.h
5581do
5582ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
5583echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5584echo "configure:5585: checking for $ac_hdr" >&5
5585if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5586  echo $ac_n "(cached) $ac_c" 1>&6
5587else
5588  cat > conftest.$ac_ext <<EOF
5589#line 5590 "configure"
5590#include "confdefs.h"
5591#include <$ac_hdr>
5592EOF
5593ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5594{ (eval echo configure:5595: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5595ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5596if test -z "$ac_err"; then
5597  rm -rf conftest*
5598  eval "ac_cv_header_$ac_safe=yes"
5599else
5600  echo "$ac_err" >&5
5601  echo "configure: failed program was:" >&5
5602  cat conftest.$ac_ext >&5
5603  rm -rf conftest*
5604  eval "ac_cv_header_$ac_safe=no"
5605fi
5606rm -f conftest*
5607fi
5608if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5609  echo "$ac_t""yes" 1>&6
5610    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
5611  cat >> confdefs.h <<EOF
5612#define $ac_tr_hdr 1
5613EOF
5614 
5615else
5616  echo "$ac_t""no" 1>&6
5617fi
5618done
5619
5620       echo $ac_n "checking for dmalloc_shutdown in -ldmalloc""... $ac_c" 1>&6
5621echo "configure:5622: checking for dmalloc_shutdown in -ldmalloc" >&5
5622ac_lib_var=`echo dmalloc'_'dmalloc_shutdown | sed 'y%./+-%__p_%'`
5623if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5624  echo $ac_n "(cached) $ac_c" 1>&6
5625else
5626  ac_save_LIBS="$LIBS"
5627LIBS="-ldmalloc  $LIBS"
5628cat > conftest.$ac_ext <<EOF
5629#line 5630 "configure"
5630#include "confdefs.h"
5631/* Override any gcc2 internal prototype to avoid an error.  */
5632/* We use char because int might match the return type of a gcc2
5633    builtin and then its argument prototype would still apply.  */
5634char dmalloc_shutdown();
5635
5636int main() {
5637dmalloc_shutdown()
5638; return 0; }
5639EOF
5640if { (eval echo configure:5641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5641  rm -rf conftest*
5642  eval "ac_cv_lib_$ac_lib_var=yes"
5643else
5644  echo "configure: failed program was:" >&5
5645  cat conftest.$ac_ext >&5
5646  rm -rf conftest*
5647  eval "ac_cv_lib_$ac_lib_var=no"
5648fi
5649rm -f conftest*
5650LIBS="$ac_save_LIBS"
5651
5652fi
5653if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5654  echo "$ac_t""yes" 1>&6
5655    ac_tr_lib=HAVE_LIB`echo dmalloc | sed -e 's/[^a-zA-Z0-9_]/_/g' \
5656    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
5657  cat >> confdefs.h <<EOF
5658#define $ac_tr_lib 1
5659EOF
5660
5661  LIBS="-ldmalloc $LIBS"
5662
5663else
5664  echo "$ac_t""no" 1>&6
5665fi
5666
5667       CPPFLAGS="$CPPFLAGS -DDMALLOC_FUNC_CHECK" ;;
5668esac
5669
5670echo $ac_n "checking for location of SCCS get command""... $ac_c" 1>&6
5671echo "configure:5672: checking for location of SCCS get command" >&5
5672if eval "test \"`echo '$''{'make_cv_path_sccs_get'+set}'`\" = set"; then
5673  echo $ac_n "(cached) $ac_c" 1>&6
5674else
5675 
5676if test -f /usr/sccs/get; then
5677  make_cv_path_sccs_get=/usr/sccs/get
5678else
5679  make_cv_path_sccs_get=get
5680fi
5681fi
5682
5683echo "$ac_t""$make_cv_path_sccs_get" 1>&6
5684cat >> confdefs.h <<EOF
5685#define SCCS_GET "$make_cv_path_sccs_get"
5686EOF
5687
5688
5689ac_clean_files="$ac_clean_files s.conftest conftoast" # Remove these later.
5690if ( /usr/sccs/admin -n s.conftest || admin -n s.conftest ) >/dev/null 2>&1 &&
5691   test -f s.conftest; then
5692  # We successfully created an SCCS file.
5693  echo $ac_n "checking if SCCS get command understands -G""... $ac_c" 1>&6
5694echo "configure:5695: checking if SCCS get command understands -G" >&5
5695if eval "test \"`echo '$''{'make_cv_sys_get_minus_G'+set}'`\" = set"; then
5696  echo $ac_n "(cached) $ac_c" 1>&6
5697else
5698 
5699    if $make_cv_path_sccs_get -Gconftoast s.conftest >/dev/null 2>&1 &&
5700       test -f conftoast; then
5701       make_cv_sys_get_minus_G=yes
5702    else
5703       make_cv_sys_get_minus_G=no
5704    fi
5705fi
5706
5707echo "$ac_t""$make_cv_sys_get_minus_G" 1>&6
5708  case "$make_cv_sys_get_minus_G" in
5709    yes) cat >> confdefs.h <<\EOF
5710#define SCCS_GET_MINUS_G 1
5711EOF
5712;;
5713  esac
5714fi
5715rm -f s.conftest conftoast
5716
5717echo $ac_n "checking if system libc has GNU glob""... $ac_c" 1>&6
5718echo "configure:5719: checking if system libc has GNU glob" >&5
5719if eval "test \"`echo '$''{'make_cv_sys_gnu_glob'+set}'`\" = set"; then
5720  echo $ac_n "(cached) $ac_c" 1>&6
5721else
5722 
5723 cat > conftest.$ac_ext <<EOF
5724#line 5725 "configure"
5725#include "confdefs.h"
5726
5727#include <features.h>
5728#include <glob.h>
5729#include <fnmatch.h>
5730
5731#define GLOB_INTERFACE_VERSION 1
5732#if defined _LIBC || !defined __GNU_LIBRARY__ || __GNU_LIBRARY__ <= 1
5733# error no gnu glob
5734#else
5735# include <gnu-versions.h>
5736# if _GNU_GLOB_INTERFACE_VERSION != GLOB_INTERFACE_VERSION
5737#  error no gnu glob
5738# endif
5739#endif
5740 
5741EOF
5742ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5743{ (eval echo configure:5744: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5744ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
5745if test -z "$ac_err"; then
5746  rm -rf conftest*
5747  make_cv_sys_gnu_glob=yes
5748else
5749  echo "$ac_err" >&5
5750  echo "configure: failed program was:" >&5
5751  cat conftest.$ac_ext >&5
5752  rm -rf conftest*
5753  make_cv_sys_gnu_glob=no
5754fi
5755rm -f conftest*
5756fi
5757
5758case "$make_cv_sys_gnu_glob" in
5759  yes) echo "$ac_t""yes; using local copy anyway" 1>&6
5760        GLOBDIR=glob
5761        GLOBINC='-I$(srcdir)/glob'
5762        GLOBLIB=glob/libglob.a
5763       ;;
5764  no)  echo "$ac_t""no; using local copy" 1>&6
5765        GLOBDIR=glob
5766        GLOBINC='-I$(srcdir)/glob'
5767        GLOBLIB=glob/libglob.a
5768       ;;
5769esac
5770
5771cat >> confdefs.h <<EOF
5772#define MAKE_HOST "$host"
5773EOF
5774
5775MAKE_HOST="$host"
5776
5777
5778MAINT_MAKEFILE=/dev/null
5779if test -r "$srcdir/maintMakefile"; then
5780  MAINT_MAKEFILE="$srcdir/maintMakefile"
5781fi
5782
5783
5784trap '' 1 2 15
5785cat > confcache <<\EOF
5786# This file is a shell script that caches the results of configure
5787# tests run on this system so they can be shared between configure
5788# scripts and configure runs.  It is not useful on other systems.
5789# If it contains results you don't want to keep, you may remove or edit it.
5790#
5791# By default, configure uses ./config.cache as the cache file,
5792# creating it if it does not exist already.  You can give configure
5793# the --cache-file=FILE option to use a different cache file; that is
5794# what configure does when it calls configure scripts in
5795# subdirectories, so they share the cache.
5796# Giving --cache-file=/dev/null disables caching, for debugging configure.
5797# config.status only pays attention to the cache file if you give it the
5798# --recheck option to rerun configure.
5799#
5800EOF
5801# The following way of writing the cache mishandles newlines in values,
5802# but we know of no workaround that is simple, portable, and efficient.
5803# So, don't put newlines in cache variables' values.
5804# Ultrix sh set writes to stderr and can't be redirected directly,
5805# and sets the high bit in the cache file unless we assign to the vars.
5806(set) 2>&1 |
5807  case `(ac_space=' '; set | grep ac_space) 2>&1` in
5808  *ac_space=\ *)
5809    # `set' does not quote correctly, so add quotes (double-quote substitution
5810    # turns \\\\ into \\, and sed turns \\ into \).
5811    sed -n \
5812      -e "s/'/'\\\\''/g" \
5813      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
5814    ;;
5815  *)
5816    # `set' quotes correctly as required by POSIX, so do not add quotes.
5817    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
5818    ;;
5819  esac >> confcache
5820if cmp -s $cache_file confcache; then
5821  :
5822else
5823  if test -w $cache_file; then
5824    echo "updating cache $cache_file"
5825    cat confcache > $cache_file
5826  else
5827    echo "not updating unwritable cache $cache_file"
5828  fi
5829fi
5830rm -f confcache
5831
5832trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
5833
5834test "x$prefix" = xNONE && prefix=$ac_default_prefix
5835# Let make expand exec_prefix.
5836test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
5837
5838# Any assignment to VPATH causes Sun make to only execute
5839# the first set of double-colon rules, so remove it if not needed.
5840# If there is a colon in the path, we need to keep it.
5841if test "x$srcdir" = x.; then
5842  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
5843fi
5844
5845trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
5846
5847DEFS=-DHAVE_CONFIG_H
5848
5849# Without the "./", some shells look in PATH for config.status.
5850: ${CONFIG_STATUS=./config.status}
5851
5852echo creating $CONFIG_STATUS
5853rm -f $CONFIG_STATUS
5854cat > $CONFIG_STATUS <<EOF
5855#! /bin/sh
5856# Generated automatically by configure.
5857# Run this file to recreate the current configuration.
5858# This directory was configured as follows,
5859# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
5860#
5861# $0 $ac_configure_args
5862#
5863# Compiler output produced by configure, useful for debugging
5864# configure, is in ./config.log if it exists.
5865
5866ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
5867for ac_option
5868do
5869  case "\$ac_option" in
5870  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
5871    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
5872    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
5873  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
5874    echo "$CONFIG_STATUS generated by autoconf version 2.13"
5875    exit 0 ;;
5876  -help | --help | --hel | --he | --h)
5877    echo "\$ac_cs_usage"; exit 0 ;;
5878  *) echo "\$ac_cs_usage"; exit 1 ;;
5879  esac
5880done
5881
5882ac_given_srcdir=$srcdir
5883ac_given_INSTALL="$INSTALL"
5884
5885trap 'rm -fr `echo "build.sh Makefile glob/Makefile i18n/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
5886EOF
5887cat >> $CONFIG_STATUS <<EOF
5888
5889# Protect against being on the right side of a sed subst in config.status.
5890sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
5891 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
5892$ac_vpsub
5893$extrasub
5894s%@SHELL@%$SHELL%g
5895s%@CFLAGS@%$CFLAGS%g
5896s%@CPPFLAGS@%$CPPFLAGS%g
5897s%@CXXFLAGS@%$CXXFLAGS%g
5898s%@FFLAGS@%$FFLAGS%g
5899s%@DEFS@%$DEFS%g
5900s%@LDFLAGS@%$LDFLAGS%g
5901s%@LIBS@%$LIBS%g
5902s%@exec_prefix@%$exec_prefix%g
5903s%@prefix@%$prefix%g
5904s%@program_transform_name@%$program_transform_name%g
5905s%@bindir@%$bindir%g
5906s%@sbindir@%$sbindir%g
5907s%@libexecdir@%$libexecdir%g
5908s%@datadir@%$datadir%g
5909s%@sysconfdir@%$sysconfdir%g
5910s%@sharedstatedir@%$sharedstatedir%g
5911s%@localstatedir@%$localstatedir%g
5912s%@libdir@%$libdir%g
5913s%@includedir@%$includedir%g
5914s%@oldincludedir@%$oldincludedir%g
5915s%@infodir@%$infodir%g
5916s%@mandir@%$mandir%g
5917s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5918s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5919s%@INSTALL_DATA@%$INSTALL_DATA%g
5920s%@PACKAGE@%$PACKAGE%g
5921s%@VERSION@%$VERSION%g
5922s%@ACLOCAL@%$ACLOCAL%g
5923s%@AUTOCONF@%$AUTOCONF%g
5924s%@AUTOMAKE@%$AUTOMAKE%g
5925s%@AUTOHEADER@%$AUTOHEADER%g
5926s%@MAKEINFO@%$MAKEINFO%g
5927s%@SET_MAKE@%$SET_MAKE%g
5928s%@host@%$host%g
5929s%@host_alias@%$host_alias%g
5930s%@host_cpu@%$host_cpu%g
5931s%@host_vendor@%$host_vendor%g
5932s%@host_os@%$host_os%g
5933s%@CC@%$CC%g
5934s%@AR@%$AR%g
5935s%@RANLIB@%$RANLIB%g
5936s%@CPP@%$CPP%g
5937s%@PERL@%$PERL%g
5938s%@build@%$build%g
5939s%@build_alias@%$build_alias%g
5940s%@build_cpu@%$build_cpu%g
5941s%@build_vendor@%$build_vendor%g
5942s%@build_os@%$build_os%g
5943s%@GETCONF@%$GETCONF%g
5944s%@USE_NLS_TRUE@%$USE_NLS_TRUE%g
5945s%@USE_NLS_FALSE@%$USE_NLS_FALSE%g
5946s%@ALL_LINGUAS@%$ALL_LINGUAS%g
5947s%@ALL_POFILES@%$ALL_POFILES%g
5948s%@ALL_MOFILES@%$ALL_MOFILES%g
5949s%@MOFILES@%$MOFILES%g
5950s%@LIBOBJS@%$LIBOBJS%g
5951s%@ALLOCA@%$ALLOCA%g
5952s%@NEED_SETGID@%$NEED_SETGID%g
5953s%@KMEM_GROUP@%$KMEM_GROUP%g
5954s%@REMOTE@%$REMOTE%g
5955s%@GLOBDIR@%$GLOBDIR%g
5956s%@GLOBINC@%$GLOBINC%g
5957s%@GLOBLIB@%$GLOBLIB%g
5958s%@MAKE_HOST@%$MAKE_HOST%g
5959/@MAINT_MAKEFILE@/r $MAINT_MAKEFILE
5960s%@MAINT_MAKEFILE@%%g
5961
5962CEOF
5963EOF
5964
5965cat >> $CONFIG_STATUS <<\EOF
5966
5967# Split the substitutions into bite-sized pieces for seds with
5968# small command number limits, like on Digital OSF/1 and HP-UX.
5969ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5970ac_file=1 # Number of current file.
5971ac_beg=1 # First line for current file.
5972ac_end=$ac_max_sed_cmds # Line after last line for current file.
5973ac_more_lines=:
5974ac_sed_cmds=""
5975while $ac_more_lines; do
5976  if test $ac_beg -gt 1; then
5977    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5978  else
5979    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5980  fi
5981  if test ! -s conftest.s$ac_file; then
5982    ac_more_lines=false
5983    rm -f conftest.s$ac_file
5984  else
5985    if test -z "$ac_sed_cmds"; then
5986      ac_sed_cmds="sed -f conftest.s$ac_file"
5987    else
5988      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5989    fi
5990    ac_file=`expr $ac_file + 1`
5991    ac_beg=$ac_end
5992    ac_end=`expr $ac_end + $ac_max_sed_cmds`
5993  fi
5994done
5995if test -z "$ac_sed_cmds"; then
5996  ac_sed_cmds=cat
5997fi
5998EOF
5999
6000cat >> $CONFIG_STATUS <<EOF
6001
6002CONFIG_FILES=\${CONFIG_FILES-"build.sh Makefile glob/Makefile i18n/Makefile"}
6003EOF
6004cat >> $CONFIG_STATUS <<\EOF
6005for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
6006  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6007  case "$ac_file" in
6008  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6009       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6010  *) ac_file_in="${ac_file}.in" ;;
6011  esac
6012
6013  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
6014
6015  # Remove last slash and all that follows it.  Not all systems have dirname.
6016  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6017  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6018    # The file is in a subdirectory.
6019    test ! -d "$ac_dir" && mkdir "$ac_dir"
6020    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
6021    # A "../" for each directory in $ac_dir_suffix.
6022    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
6023  else
6024    ac_dir_suffix= ac_dots=
6025  fi
6026
6027  case "$ac_given_srcdir" in
6028  .)  srcdir=.
6029      if test -z "$ac_dots"; then top_srcdir=.
6030      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
6031  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
6032  *) # Relative path.
6033    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
6034    top_srcdir="$ac_dots$ac_given_srcdir" ;;
6035  esac
6036
6037  case "$ac_given_INSTALL" in
6038  [/$]*) INSTALL="$ac_given_INSTALL" ;;
6039  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
6040  esac
6041
6042  echo creating "$ac_file"
6043  rm -f "$ac_file"
6044  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
6045  case "$ac_file" in
6046  *Makefile*) ac_comsub="1i\\
6047# $configure_input" ;;
6048  *) ac_comsub= ;;
6049  esac
6050
6051  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6052  sed -e "$ac_comsub
6053s%@configure_input@%$configure_input%g
6054s%@srcdir@%$srcdir%g
6055s%@top_srcdir@%$top_srcdir%g
6056s%@INSTALL@%$INSTALL%g
6057" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
6058fi; done
6059rm -f conftest.s*
6060
6061# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
6062# NAME is the cpp macro being defined and VALUE is the value it is being given.
6063#
6064# ac_d sets the value in "#define NAME VALUE" lines.
6065ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
6066ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
6067ac_dC='\3'
6068ac_dD='%g'
6069# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
6070ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6071ac_uB='\([      ]\)%\1#\2define\3'
6072ac_uC=' '
6073ac_uD='\4%g'
6074# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
6075ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
6076ac_eB='$%\1#\2define\3'
6077ac_eC=' '
6078ac_eD='%g'
6079
6080if test "${CONFIG_HEADERS+set}" != set; then
6081EOF
6082cat >> $CONFIG_STATUS <<EOF
6083  CONFIG_HEADERS="config.h"
6084EOF
6085cat >> $CONFIG_STATUS <<\EOF
6086fi
6087for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
6088  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
6089  case "$ac_file" in
6090  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
6091       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
6092  *) ac_file_in="${ac_file}.in" ;;
6093  esac
6094
6095  echo creating $ac_file
6096
6097  rm -f conftest.frag conftest.in conftest.out
6098  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
6099  cat $ac_file_inputs > conftest.in
6100
6101EOF
6102
6103# Transform confdefs.h into a sed script conftest.vals that substitutes
6104# the proper values into config.h.in to produce config.h.  And first:
6105# Protect against being on the right side of a sed subst in config.status.
6106# Protect against being in an unquoted here document in config.status.
6107rm -f conftest.vals
6108cat > conftest.hdr <<\EOF
6109s/[\\&%]/\\&/g
6110s%[\\$`]%\\&%g
6111s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
6112s%ac_d%ac_u%gp
6113s%ac_u%ac_e%gp
6114EOF
6115sed -n -f conftest.hdr confdefs.h > conftest.vals
6116rm -f conftest.hdr
6117
6118# This sed command replaces #undef with comments.  This is necessary, for
6119# example, in the case of _POSIX_SOURCE, which is predefined and required
6120# on some systems where configure will not decide to define it.
6121cat >> conftest.vals <<\EOF
6122s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
6123EOF
6124
6125# Break up conftest.vals because some shells have a limit on
6126# the size of here documents, and old seds have small limits too.
6127
6128rm -f conftest.tail
6129while :
6130do
6131  ac_lines=`grep -c . conftest.vals`
6132  # grep -c gives empty output for an empty file on some AIX systems.
6133  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
6134  # Write a limited-size here document to conftest.frag.
6135  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
6136  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
6137  echo 'CEOF
6138  sed -f conftest.frag conftest.in > conftest.out
6139  rm -f conftest.in
6140  mv conftest.out conftest.in
6141' >> $CONFIG_STATUS
6142  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
6143  rm -f conftest.vals
6144  mv conftest.tail conftest.vals
6145done
6146rm -f conftest.vals
6147
6148cat >> $CONFIG_STATUS <<\EOF
6149  rm -f conftest.frag conftest.h
6150  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
6151  cat conftest.in >> conftest.h
6152  rm -f conftest.in
6153  if cmp -s $ac_file conftest.h 2>/dev/null; then
6154    echo "$ac_file is unchanged"
6155    rm -f conftest.h
6156  else
6157    # Remove last slash and all that follows it.  Not all systems have dirname.
6158      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
6159      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
6160      # The file is in a subdirectory.
6161      test ! -d "$ac_dir" && mkdir "$ac_dir"
6162    fi
6163    rm -f $ac_file
6164    mv conftest.h $ac_file
6165  fi
6166fi; done
6167
6168EOF
6169cat >> $CONFIG_STATUS <<EOF
6170
6171
6172EOF
6173cat >> $CONFIG_STATUS <<\EOF
6174test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
6175
6176exit 0
6177EOF
6178chmod +x $CONFIG_STATUS
6179rm -fr confdefs* $ac_clean_files
6180test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
6181
6182
6183
6184
6185case "$make_badcust" in
6186  yes) echo
6187       echo "WARNING: --with-customs specified but no customs.h could be found;"
6188       echo "         disabling Customs support."
6189       echo ;;
6190esac
6191
6192case "$with_customs" in
6193  ""|n|no|y|ye|yes) ;;
6194  *) if test -f "$with_customs/lib/libcustoms.a"; then
6195       :
6196     else
6197       echo
6198       echo "WARNING: \`$with_customs/lib' does not appear to contain the"
6199       echo "         Customs library.  You must build and install Customs"
6200       echo "         before compiling GNU make."
6201       echo
6202     fi ;;
6203esac
6204
6205case "$has_wait_nohang" in
6206  no) echo
6207      echo "WARNING: Your system has neither waitpid() nor wait3()."
6208      echo "         Without one of these, signal handling is unreliable."
6209      echo "         You should be aware that running GNU make with -j"
6210      echo "         could result in erratic behavior."
6211      echo ;;
6212esac
6213
6214case "$make_cv_job_server/$user_job_server" in
6215  no/yes) echo
6216          echo "WARNING: Make job server requires a POSIX-ish system that"
6217          echo "         supports the pipe(), sigaction(), and either"
6218          echo "         waitpid() or wait3() functions.  Your system doesn't"
6219          echo "         appear to provide one or more of those."
6220          echo "         Disabling job server support."
6221          echo ;;
6222esac
6223
Note: See TracBrowser for help on using the repository browser.