Fix texinfo usage, esp. doublequotes.
[bpt/emacs.git] / configure
CommitLineData
ba4481b5 1#! /bin/sh
ba4481b5 2# Guess values for system-dependent variables and create Makefiles.
35996d22 3# Generated by GNU Autoconf 2.59.
ba4481b5 4#
35996d22 5# Copyright (C) 2003 Free Software Foundation, Inc.
ba4481b5
DL
6# This configure script is free software; the Free Software Foundation
7# gives unlimited permission to copy, distribute and modify it.
c0d27fcc
MR
8## --------------------- ##
9## M4sh Initialization. ##
10## --------------------- ##
503d2be0
AS
11
12# Be Bourne compatible
13if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14 emulate sh
15 NULLCMD=:
6bae0ccf
DL
16 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17 # is contrary to our usage. Disable this feature.
18 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
19elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20 set -o posix
21fi
35996d22 22DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 23
c0d27fcc 24# Support unset when possible.
35996d22 25if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
26 as_unset=unset
27else
28 as_unset=false
29fi
30
6bae0ccf
DL
31
32# Work around bugs in pre-3.0 UWIN ksh.
33$as_unset ENV MAIL MAILPATH
34PS1='$ '
35PS2='> '
36PS4='+ '
37
38# NLS nuisances.
19650fd6
AS
39for as_var in \
40 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42 LC_TELEPHONE LC_TIME
6bae0ccf 43do
35996d22 44 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
45 eval $as_var=C; export $as_var
46 else
47 $as_unset $as_var
48 fi
49done
50
51# Required to use basename.
52if expr a : '\(a\)' >/dev/null 2>&1; then
53 as_expr=expr
54else
55 as_expr=false
56fi
57
58if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
59 as_basename=basename
60else
61 as_basename=false
62fi
c0d27fcc
MR
63
64
503d2be0 65# Name of the executable.
6bae0ccf 66as_me=`$as_basename "$0" ||
c0d27fcc
MR
67$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68 X"$0" : 'X\(//\)$' \| \
69 X"$0" : 'X\(/\)$' \| \
70 . : '\(.\)' 2>/dev/null ||
71echo X/"$0" |
72 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73 /^X\/\(\/\/\)$/{ s//\1/; q; }
74 /^X\/\(\/\).*/{ s//\1/; q; }
75 s/.*/./; q'`
76
6bae0ccf 77
c0d27fcc
MR
78# PATH needs CR, and LINENO needs CR and PATH.
79# Avoid depending upon Character Ranges.
80as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83as_cr_digits='0123456789'
84as_cr_alnum=$as_cr_Letters$as_cr_digits
85
86# The user is always right.
87if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
88 echo "#! /bin/sh" >conf$$.sh
89 echo "exit 0" >>conf$$.sh
90 chmod +x conf$$.sh
91 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
92 PATH_SEPARATOR=';'
93 else
94 PATH_SEPARATOR=:
95 fi
19650fd6 96 rm -f conf$$.sh
c0d27fcc
MR
97fi
98
99
100 as_lineno_1=$LINENO
101 as_lineno_2=$LINENO
102 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103 test "x$as_lineno_1" != "x$as_lineno_2" &&
104 test "x$as_lineno_3" = "x$as_lineno_2" || {
105 # Find who we are. Look in the path if we contain no path at all
106 # relative or not.
107 case $0 in
108 *[\\/]* ) as_myself=$0 ;;
109 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110for as_dir in $PATH
111do
112 IFS=$as_save_IFS
113 test -z "$as_dir" && as_dir=.
114 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115done
116
117 ;;
118 esac
119 # We did not find ourselves, most probably we were run as `sh COMMAND'
120 # in which case we are not to be found in the path.
121 if test "x$as_myself" = x; then
122 as_myself=$0
123 fi
124 if test ! -f "$as_myself"; then
125 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126 { (exit 1); exit 1; }; }
127 fi
128 case $CONFIG_SHELL in
129 '')
130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
131for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
132do
133 IFS=$as_save_IFS
134 test -z "$as_dir" && as_dir=.
135 for as_base in sh bash ksh sh5; do
136 case $as_dir in
137 /*)
138 if ("$as_dir/$as_base" -c '
139 as_lineno_1=$LINENO
140 as_lineno_2=$LINENO
141 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
142 test "x$as_lineno_1" != "x$as_lineno_2" &&
143 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
144 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
146 CONFIG_SHELL=$as_dir/$as_base
147 export CONFIG_SHELL
148 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149 fi;;
150 esac
151 done
152done
153;;
154 esac
155
156 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157 # uniformly replaced by the line number. The first 'sed' inserts a
158 # line-number line before each line; the second 'sed' does the real
159 # work. The second script uses 'N' to pair each line-number line
160 # with the numbered line, and appends trailing '-' during
161 # substitution so that $LINENO is not a special case at line end.
162 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
163 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
164 sed '=' <$as_myself |
165 sed '
166 N
167 s,$,-,
168 : loop
169 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
170 t loop
171 s,-$,,
172 s,^['$as_cr_digits']*\n,,
173 ' >$as_me.lineno &&
174 chmod +x $as_me.lineno ||
175 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176 { (exit 1); exit 1; }; }
177
178 # Don't try to exec as it changes $[0], causing all sort of problems
179 # (the dirname of $[0] is not the place where we might find the
180 # original and so on. Autoconf is especially sensible to this).
181 . ./$as_me.lineno
182 # Exit status is that of the last command.
183 exit
184}
185
186
187case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188 *c*,-n*) ECHO_N= ECHO_C='
189' ECHO_T=' ' ;;
190 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
192esac
503d2be0
AS
193
194if expr a : '\(a\)' >/dev/null 2>&1; then
195 as_expr=expr
196else
197 as_expr=false
198fi
199
200rm -f conf$$ conf$$.exe conf$$.file
201echo >conf$$.file
202if ln -s conf$$.file conf$$ 2>/dev/null; then
203 # We could just check for DJGPP; but this test a) works b) is more generic
204 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205 if test -f conf$$.exe; then
206 # Don't use ln at all; we don't have any links
207 as_ln_s='cp -p'
208 else
209 as_ln_s='ln -s'
210 fi
211elif ln conf$$.file conf$$ 2>/dev/null; then
212 as_ln_s=ln
213else
214 as_ln_s='cp -p'
215fi
216rm -f conf$$ conf$$.exe conf$$.file
217
6bae0ccf
DL
218if mkdir -p . 2>/dev/null; then
219 as_mkdir_p=:
220else
35996d22 221 test -d ./-p && rmdir ./-p
6bae0ccf
DL
222 as_mkdir_p=false
223fi
224
503d2be0
AS
225as_executable_p="test -f"
226
c0d27fcc 227# Sed expression to map a string onto a valid CPP name.
35996d22 228as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
229
230# Sed expression to map a string onto a valid variable name.
35996d22 231as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 232
503d2be0
AS
233
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" $as_nl"
239
240# CDPATH.
6bae0ccf 241$as_unset CDPATH
c0d27fcc 242
503d2be0
AS
243
244# Name of the host.
245# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246# so uname gets run too.
247ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249exec 6>&1
250
251#
252# Initializations.
253#
ba4481b5 254ac_default_prefix=/usr/local
6bae0ccf 255ac_config_libobj_dir=.
503d2be0
AS
256cross_compiling=no
257subdirs=
c0d27fcc
MR
258MFLAGS=
259MAKEFLAGS=
503d2be0
AS
260SHELL=${CONFIG_SHELL-/bin/sh}
261
262# Maximum number of lines to put in a shell here document.
263# This variable seems obsolete. It should probably be removed, and
264# only ac_max_sed_lines should be used.
265: ${ac_max_here_lines=38}
266
c0d27fcc
MR
267# Identity of this package.
268PACKAGE_NAME=
269PACKAGE_TARNAME=
270PACKAGE_VERSION=
271PACKAGE_STRING=
272PACKAGE_BUGREPORT=
273
503d2be0 274ac_unique_file="src/lisp.h"
6bae0ccf 275ac_config_libobj_dir=src
503d2be0
AS
276# Factoring default headers for most tests.
277ac_includes_default="\
278#include <stdio.h>
279#if HAVE_SYS_TYPES_H
280# include <sys/types.h>
281#endif
282#if HAVE_SYS_STAT_H
283# include <sys/stat.h>
284#endif
285#if STDC_HEADERS
286# include <stdlib.h>
287# include <stddef.h>
288#else
289# if HAVE_STDLIB_H
290# include <stdlib.h>
291# endif
292#endif
293#if HAVE_STRING_H
294# if !STDC_HEADERS && HAVE_MEMORY_H
295# include <memory.h>
296# endif
297# include <string.h>
298#endif
299#if HAVE_STRINGS_H
300# include <strings.h>
301#endif
302#if HAVE_INTTYPES_H
303# include <inttypes.h>
304#else
305# if HAVE_STDINT_H
306# include <stdint.h>
307# endif
308#endif
309#if HAVE_UNISTD_H
310# include <unistd.h>
311#endif"
ba4481b5 312
19650fd6 313ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MAINT build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA RANLIB ac_ct_RANLIB INSTALL_INFO EGREP LIBSOUND SET_MAKE PKG_CONFIG GTK_CFLAGS GTK_LIBS ALLOCA liblockfile LIBOBJS NEED_SETGID KMEM_GROUP GETLOADAVG_LIBS version configuration canonical srcdir lispdir locallisppath lisppath x_default_search_path etcdir archlibdir docdir bitmapdir gamedir gameuser c_switch_system c_switch_machine LD_SWITCH_X_SITE LD_SWITCH_X_SITE_AUX C_SWITCH_X_SITE X_TOOLKIT_TYPE machfile opsysfile carbon_appdir LTLIBOBJS'
6bae0ccf 314ac_subst_files=''
c0d27fcc 315
ba4481b5 316# Initialize some variables set by options.
503d2be0
AS
317ac_init_help=
318ac_init_version=false
ba4481b5
DL
319# The variables have the same names as the options, with
320# dashes changed to underlines.
503d2be0 321cache_file=/dev/null
ba4481b5 322exec_prefix=NONE
ba4481b5 323no_create=
ba4481b5
DL
324no_recursion=
325prefix=NONE
326program_prefix=NONE
327program_suffix=NONE
328program_transform_name=s,x,x,
329silent=
330site=
331srcdir=
ba4481b5
DL
332verbose=
333x_includes=NONE
334x_libraries=NONE
503d2be0
AS
335
336# Installation directory options.
337# These are left unexpanded so users can "make install exec_prefix=/foo"
338# and all the variables that are supposed to be based on exec_prefix
339# by default will actually change.
340# Use braces instead of parens because sh, perl, etc. also accept them.
ba4481b5
DL
341bindir='${exec_prefix}/bin'
342sbindir='${exec_prefix}/sbin'
343libexecdir='${exec_prefix}/libexec'
344datadir='${prefix}/share'
345sysconfdir='${prefix}/etc'
346sharedstatedir='${prefix}/com'
347localstatedir='${prefix}/var'
348libdir='${exec_prefix}/lib'
349includedir='${prefix}/include'
350oldincludedir='/usr/include'
351infodir='${prefix}/info'
352mandir='${prefix}/man'
353
ba4481b5
DL
354ac_prev=
355for ac_option
356do
ba4481b5
DL
357 # If the previous option needs an argument, assign it.
358 if test -n "$ac_prev"; then
359 eval "$ac_prev=\$ac_option"
360 ac_prev=
361 continue
362 fi
363
503d2be0 364 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
ba4481b5
DL
365
366 # Accept the important Cygnus configure options, so we can diagnose typos.
367
503d2be0 368 case $ac_option in
ba4481b5
DL
369
370 -bindir | --bindir | --bindi | --bind | --bin | --bi)
371 ac_prev=bindir ;;
372 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
503d2be0 373 bindir=$ac_optarg ;;
ba4481b5
DL
374
375 -build | --build | --buil | --bui | --bu)
503d2be0 376 ac_prev=build_alias ;;
ba4481b5 377 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
503d2be0 378 build_alias=$ac_optarg ;;
ba4481b5
DL
379
380 -cache-file | --cache-file | --cache-fil | --cache-fi \
381 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
382 ac_prev=cache_file ;;
383 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
384 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
503d2be0
AS
385 cache_file=$ac_optarg ;;
386
387 --config-cache | -C)
388 cache_file=config.cache ;;
ba4481b5
DL
389
390 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
391 ac_prev=datadir ;;
392 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
393 | --da=*)
503d2be0 394 datadir=$ac_optarg ;;
ba4481b5
DL
395
396 -disable-* | --disable-*)
503d2be0 397 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
ba4481b5 398 # Reject names that are not valid shell variable names.
503d2be0
AS
399 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
400 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
401 { (exit 1); exit 1; }; }
402 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
403 eval "enable_$ac_feature=no" ;;
ba4481b5
DL
404
405 -enable-* | --enable-*)
503d2be0 406 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
ba4481b5 407 # Reject names that are not valid shell variable names.
503d2be0
AS
408 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
409 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
410 { (exit 1); exit 1; }; }
411 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
412 case $ac_option in
413 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
414 *) ac_optarg=yes ;;
415 esac
503d2be0 416 eval "enable_$ac_feature='$ac_optarg'" ;;
ba4481b5
DL
417
418 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
419 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
420 | --exec | --exe | --ex)
421 ac_prev=exec_prefix ;;
422 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
423 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
424 | --exec=* | --exe=* | --ex=*)
503d2be0 425 exec_prefix=$ac_optarg ;;
ba4481b5
DL
426
427 -gas | --gas | --ga | --g)
428 # Obsolete; use --with-gas.
429 with_gas=yes ;;
430
503d2be0
AS
431 -help | --help | --hel | --he | -h)
432 ac_init_help=long ;;
433 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
434 ac_init_help=recursive ;;
435 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
436 ac_init_help=short ;;
ba4481b5
DL
437
438 -host | --host | --hos | --ho)
503d2be0 439 ac_prev=host_alias ;;
ba4481b5 440 -host=* | --host=* | --hos=* | --ho=*)
503d2be0 441 host_alias=$ac_optarg ;;
ba4481b5
DL
442
443 -includedir | --includedir | --includedi | --included | --include \
444 | --includ | --inclu | --incl | --inc)
445 ac_prev=includedir ;;
446 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
447 | --includ=* | --inclu=* | --incl=* | --inc=*)
503d2be0 448 includedir=$ac_optarg ;;
ba4481b5
DL
449
450 -infodir | --infodir | --infodi | --infod | --info | --inf)
451 ac_prev=infodir ;;
452 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
503d2be0 453 infodir=$ac_optarg ;;
ba4481b5
DL
454
455 -libdir | --libdir | --libdi | --libd)
456 ac_prev=libdir ;;
457 -libdir=* | --libdir=* | --libdi=* | --libd=*)
503d2be0 458 libdir=$ac_optarg ;;
ba4481b5
DL
459
460 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
461 | --libexe | --libex | --libe)
462 ac_prev=libexecdir ;;
463 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
464 | --libexe=* | --libex=* | --libe=*)
503d2be0 465 libexecdir=$ac_optarg ;;
ba4481b5
DL
466
467 -localstatedir | --localstatedir | --localstatedi | --localstated \
468 | --localstate | --localstat | --localsta | --localst \
469 | --locals | --local | --loca | --loc | --lo)
470 ac_prev=localstatedir ;;
471 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
472 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
473 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
503d2be0 474 localstatedir=$ac_optarg ;;
ba4481b5
DL
475
476 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
477 ac_prev=mandir ;;
478 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
503d2be0 479 mandir=$ac_optarg ;;
ba4481b5
DL
480
481 -nfp | --nfp | --nf)
482 # Obsolete; use --without-fp.
483 with_fp=no ;;
484
485 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
c0d27fcc 486 | --no-cr | --no-c | -n)
ba4481b5
DL
487 no_create=yes ;;
488
489 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
490 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
491 no_recursion=yes ;;
492
493 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
494 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
495 | --oldin | --oldi | --old | --ol | --o)
496 ac_prev=oldincludedir ;;
497 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
498 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
499 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
503d2be0 500 oldincludedir=$ac_optarg ;;
ba4481b5
DL
501
502 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
503 ac_prev=prefix ;;
504 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
503d2be0 505 prefix=$ac_optarg ;;
ba4481b5
DL
506
507 -program-prefix | --program-prefix | --program-prefi | --program-pref \
508 | --program-pre | --program-pr | --program-p)
509 ac_prev=program_prefix ;;
510 -program-prefix=* | --program-prefix=* | --program-prefi=* \
511 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
503d2be0 512 program_prefix=$ac_optarg ;;
ba4481b5
DL
513
514 -program-suffix | --program-suffix | --program-suffi | --program-suff \
515 | --program-suf | --program-su | --program-s)
516 ac_prev=program_suffix ;;
517 -program-suffix=* | --program-suffix=* | --program-suffi=* \
518 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
503d2be0 519 program_suffix=$ac_optarg ;;
ba4481b5
DL
520
521 -program-transform-name | --program-transform-name \
522 | --program-transform-nam | --program-transform-na \
523 | --program-transform-n | --program-transform- \
524 | --program-transform | --program-transfor \
525 | --program-transfo | --program-transf \
526 | --program-trans | --program-tran \
527 | --progr-tra | --program-tr | --program-t)
528 ac_prev=program_transform_name ;;
529 -program-transform-name=* | --program-transform-name=* \
530 | --program-transform-nam=* | --program-transform-na=* \
531 | --program-transform-n=* | --program-transform-=* \
532 | --program-transform=* | --program-transfor=* \
533 | --program-transfo=* | --program-transf=* \
534 | --program-trans=* | --program-tran=* \
535 | --progr-tra=* | --program-tr=* | --program-t=*)
503d2be0 536 program_transform_name=$ac_optarg ;;
ba4481b5
DL
537
538 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
539 | -silent | --silent | --silen | --sile | --sil)
540 silent=yes ;;
541
542 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
543 ac_prev=sbindir ;;
544 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
545 | --sbi=* | --sb=*)
503d2be0 546 sbindir=$ac_optarg ;;
ba4481b5
DL
547
548 -sharedstatedir | --sharedstatedir | --sharedstatedi \
549 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
550 | --sharedst | --shareds | --shared | --share | --shar \
551 | --sha | --sh)
552 ac_prev=sharedstatedir ;;
553 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
554 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
555 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
556 | --sha=* | --sh=*)
503d2be0 557 sharedstatedir=$ac_optarg ;;
ba4481b5
DL
558
559 -site | --site | --sit)
560 ac_prev=site ;;
561 -site=* | --site=* | --sit=*)
503d2be0 562 site=$ac_optarg ;;
ba4481b5
DL
563
564 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
565 ac_prev=srcdir ;;
566 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
503d2be0 567 srcdir=$ac_optarg ;;
ba4481b5
DL
568
569 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
570 | --syscon | --sysco | --sysc | --sys | --sy)
571 ac_prev=sysconfdir ;;
572 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
573 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
503d2be0 574 sysconfdir=$ac_optarg ;;
ba4481b5
DL
575
576 -target | --target | --targe | --targ | --tar | --ta | --t)
503d2be0 577 ac_prev=target_alias ;;
ba4481b5 578 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
503d2be0 579 target_alias=$ac_optarg ;;
ba4481b5
DL
580
581 -v | -verbose | --verbose | --verbos | --verbo | --verb)
582 verbose=yes ;;
583
503d2be0
AS
584 -version | --version | --versio | --versi | --vers | -V)
585 ac_init_version=: ;;
ba4481b5
DL
586
587 -with-* | --with-*)
503d2be0 588 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
ba4481b5 589 # Reject names that are not valid shell variable names.
503d2be0
AS
590 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
591 { echo "$as_me: error: invalid package name: $ac_package" >&2
592 { (exit 1); exit 1; }; }
ba4481b5 593 ac_package=`echo $ac_package| sed 's/-/_/g'`
503d2be0
AS
594 case $ac_option in
595 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
596 *) ac_optarg=yes ;;
597 esac
503d2be0 598 eval "with_$ac_package='$ac_optarg'" ;;
ba4481b5
DL
599
600 -without-* | --without-*)
503d2be0 601 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
ba4481b5 602 # Reject names that are not valid shell variable names.
503d2be0
AS
603 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
604 { echo "$as_me: error: invalid package name: $ac_package" >&2
605 { (exit 1); exit 1; }; }
606 ac_package=`echo $ac_package | sed 's/-/_/g'`
607 eval "with_$ac_package=no" ;;
ba4481b5
DL
608
609 --x)
610 # Obsolete; use --with-x.
611 with_x=yes ;;
612
613 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
614 | --x-incl | --x-inc | --x-in | --x-i)
615 ac_prev=x_includes ;;
616 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
617 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
503d2be0 618 x_includes=$ac_optarg ;;
ba4481b5
DL
619
620 -x-libraries | --x-libraries | --x-librarie | --x-librari \
621 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
622 ac_prev=x_libraries ;;
623 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
624 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
503d2be0 625 x_libraries=$ac_optarg ;;
ba4481b5 626
503d2be0
AS
627 -*) { echo "$as_me: error: unrecognized option: $ac_option
628Try \`$0 --help' for more information." >&2
629 { (exit 1); exit 1; }; }
ba4481b5
DL
630 ;;
631
503d2be0
AS
632 *=*)
633 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
634 # Reject names that are not valid shell variable names.
635 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
636 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
637 { (exit 1); exit 1; }; }
638 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
639 eval "$ac_envvar='$ac_optarg'"
640 export $ac_envvar ;;
641
ba4481b5 642 *)
503d2be0
AS
643 # FIXME: should be removed in autoconf 3.0.
644 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
645 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
646 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
647 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
ba4481b5
DL
648 ;;
649
650 esac
651done
652
653if test -n "$ac_prev"; then
503d2be0
AS
654 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
655 { echo "$as_me: error: missing argument to $ac_option" >&2
656 { (exit 1); exit 1; }; }
ba4481b5 657fi
ba4481b5 658
503d2be0
AS
659# Be sure to have absolute paths.
660for ac_var in exec_prefix prefix
661do
662 eval ac_val=$`echo $ac_var`
663 case $ac_val in
664 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
c0d27fcc 665 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0
AS
666 { (exit 1); exit 1; }; };;
667 esac
668done
ba4481b5 669
503d2be0
AS
670# Be sure to have absolute paths.
671for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
35996d22 672 localstatedir libdir includedir oldincludedir infodir mandir
ba4481b5 673do
503d2be0
AS
674 eval ac_val=$`echo $ac_var`
675 case $ac_val in
676 [\\/$]* | ?:[\\/]* ) ;;
c0d27fcc 677 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0 678 { (exit 1); exit 1; }; };;
ba4481b5
DL
679 esac
680done
681
503d2be0
AS
682# There might be people who depend on the old broken behavior: `$host'
683# used to hold the argument of --host etc.
c0d27fcc 684# FIXME: To remove some day.
503d2be0
AS
685build=$build_alias
686host=$host_alias
687target=$target_alias
688
c0d27fcc 689# FIXME: To remove some day.
503d2be0
AS
690if test "x$host_alias" != x; then
691 if test "x$build_alias" = x; then
692 cross_compiling=maybe
693 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
694 If a cross compiler is detected then cross compile mode will be used." >&2
695 elif test "x$build_alias" != "x$host_alias"; then
696 cross_compiling=yes
697 fi
698fi
ba4481b5 699
503d2be0
AS
700ac_tool_prefix=
701test -n "$host_alias" && ac_tool_prefix=$host_alias-
ba4481b5 702
503d2be0 703test "$silent" = yes && exec 6>/dev/null
ba4481b5 704
c0d27fcc 705
ba4481b5
DL
706# Find the source files, if location was not specified.
707if test -z "$srcdir"; then
708 ac_srcdir_defaulted=yes
709 # Try the directory containing this script, then its parent.
c0d27fcc
MR
710 ac_confdir=`(dirname "$0") 2>/dev/null ||
711$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
712 X"$0" : 'X\(//\)[^/]' \| \
713 X"$0" : 'X\(//\)$' \| \
714 X"$0" : 'X\(/\)' \| \
715 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
716echo X"$0" |
717 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
718 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
719 /^X\(\/\/\)$/{ s//\1/; q; }
720 /^X\(\/\).*/{ s//\1/; q; }
721 s/.*/./; q'`
ba4481b5
DL
722 srcdir=$ac_confdir
723 if test ! -r $srcdir/$ac_unique_file; then
724 srcdir=..
725 fi
726else
727 ac_srcdir_defaulted=no
728fi
729if test ! -r $srcdir/$ac_unique_file; then
730 if test "$ac_srcdir_defaulted" = yes; then
c0d27fcc 731 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
503d2be0 732 { (exit 1); exit 1; }; }
ba4481b5 733 else
c0d27fcc 734 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
503d2be0 735 { (exit 1); exit 1; }; }
ba4481b5
DL
736 fi
737fi
6bae0ccf
DL
738(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
739 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
740 { (exit 1); exit 1; }; }
503d2be0
AS
741srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
742ac_env_build_alias_set=${build_alias+set}
743ac_env_build_alias_value=$build_alias
744ac_cv_env_build_alias_set=${build_alias+set}
745ac_cv_env_build_alias_value=$build_alias
746ac_env_host_alias_set=${host_alias+set}
747ac_env_host_alias_value=$host_alias
748ac_cv_env_host_alias_set=${host_alias+set}
749ac_cv_env_host_alias_value=$host_alias
750ac_env_target_alias_set=${target_alias+set}
751ac_env_target_alias_value=$target_alias
752ac_cv_env_target_alias_set=${target_alias+set}
753ac_cv_env_target_alias_value=$target_alias
754ac_env_CC_set=${CC+set}
755ac_env_CC_value=$CC
756ac_cv_env_CC_set=${CC+set}
757ac_cv_env_CC_value=$CC
758ac_env_CFLAGS_set=${CFLAGS+set}
759ac_env_CFLAGS_value=$CFLAGS
760ac_cv_env_CFLAGS_set=${CFLAGS+set}
761ac_cv_env_CFLAGS_value=$CFLAGS
762ac_env_LDFLAGS_set=${LDFLAGS+set}
763ac_env_LDFLAGS_value=$LDFLAGS
764ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
765ac_cv_env_LDFLAGS_value=$LDFLAGS
766ac_env_CPPFLAGS_set=${CPPFLAGS+set}
767ac_env_CPPFLAGS_value=$CPPFLAGS
768ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
769ac_cv_env_CPPFLAGS_value=$CPPFLAGS
770ac_env_CPP_set=${CPP+set}
771ac_env_CPP_value=$CPP
772ac_cv_env_CPP_set=${CPP+set}
773ac_cv_env_CPP_value=$CPP
774
775#
776# Report the --help message.
777#
778if test "$ac_init_help" = "long"; then
779 # Omit some internal or obsolete options to make the list less imposing.
780 # This message is too long to be a string in the A/UX 3.1 sh.
c0d27fcc 781 cat <<_ACEOF
503d2be0
AS
782\`configure' configures this package to adapt to many kinds of systems.
783
784Usage: $0 [OPTION]... [VAR=VALUE]...
785
786To assign environment variables (e.g., CC, CFLAGS...), specify them as
787VAR=VALUE. See below for descriptions of some of the useful variables.
788
789Defaults for the options are specified in brackets.
790
791Configuration:
792 -h, --help display this help and exit
793 --help=short display options specific to this package
794 --help=recursive display the short help of all the included packages
795 -V, --version display version information and exit
796 -q, --quiet, --silent do not print \`checking...' messages
797 --cache-file=FILE cache test results in FILE [disabled]
798 -C, --config-cache alias for \`--cache-file=config.cache'
799 -n, --no-create do not create output files
800 --srcdir=DIR find the sources in DIR [configure dir or \`..']
801
c0d27fcc 802_ACEOF
503d2be0 803
c0d27fcc 804 cat <<_ACEOF
503d2be0
AS
805Installation directories:
806 --prefix=PREFIX install architecture-independent files in PREFIX
35996d22 807 [$ac_default_prefix]
503d2be0 808 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
35996d22 809 [PREFIX]
503d2be0
AS
810
811By default, \`make install' will install all the files in
812\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
813an installation prefix other than \`$ac_default_prefix' using \`--prefix',
814for instance \`--prefix=\$HOME'.
815
816For better control, use the options below.
817
818Fine tuning of the installation directories:
819 --bindir=DIR user executables [EPREFIX/bin]
820 --sbindir=DIR system admin executables [EPREFIX/sbin]
821 --libexecdir=DIR program executables [EPREFIX/libexec]
822 --datadir=DIR read-only architecture-independent data [PREFIX/share]
823 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
824 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
825 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
826 --libdir=DIR object code libraries [EPREFIX/lib]
827 --includedir=DIR C header files [PREFIX/include]
828 --oldincludedir=DIR C header files for non-gcc [/usr/include]
829 --infodir=DIR info documentation [PREFIX/info]
830 --mandir=DIR man documentation [PREFIX/man]
c0d27fcc 831_ACEOF
503d2be0 832
c0d27fcc 833 cat <<\_ACEOF
503d2be0 834
ba5da88a
PJ
835Program names:
836 --program-prefix=PREFIX prepend PREFIX to installed program names
837 --program-suffix=SUFFIX append SUFFIX to installed program names
838 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
839
503d2be0
AS
840X features:
841 --x-includes=DIR X include files are in DIR
842 --x-libraries=DIR X library files are in DIR
843
844System types:
845 --build=BUILD configure for building on BUILD [guessed]
c0d27fcc
MR
846 --host=HOST cross-compile to build programs to run on HOST [BUILD]
847_ACEOF
503d2be0
AS
848fi
849
850if test -n "$ac_init_help"; then
851
c0d27fcc 852 cat <<\_ACEOF
503d2be0
AS
853
854Optional Features:
855 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
856 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
6a3a24fa
JD
857 --enable-carbon-app[=DIR] [DIR=/Application]
858 specify install directory for Emacs.app on Mac OS X
19650fd6
AS
859 --enable-maintainer-mode enable make rules and dependencies not useful
860 (and sometimes confusing) to the casual installer
503d2be0
AS
861 --disable-largefile omit support for large files
862
863Optional Packages:
864 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
865 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
866 --without-gcc don't use GCC to compile Emacs if GCC is found
867 --without-pop don't support POP mail retrieval with movemail
868 --with-kerberos support Kerberos-authenticated POP
869 --with-kerberos5 support Kerberos version 5 authenticated POP
870 --with-hesiod support Hesiod to get the POP server host
2c9dccc9 871 --without-sound don't compile with sound support
488dd4c4
JD
872 --with-x-toolkit=KIT use an X toolkit
873 (KIT = yes/lucid/athena/motif/gtk/no)
503d2be0
AS
874 --with-xpm use -lXpm for displaying XPM images
875 --with-jpeg use -ljpeg for displaying JPEG images
876 --with-tiff use -ltiff for displaying TIFF images
877 --with-gif use -lungif for displaying GIF images
878 --with-png use -lpng for displaying PNG images
488dd4c4
JD
879 --with-gtk use GTK (same as --with-x-toolkit=gtk)
880 --with-pkg-config-prog Path to pkg-config to use for finding GTK
503d2be0 881 --without-toolkit-scroll-bars
cc227489
MB
882 don't use Motif or Xaw3d scroll bars
883 --without-xim don't use X11 XIM
e0f712ba 884 --without-carbon don't use Carbon GUI on Mac OS X
503d2be0
AS
885 --with-x use the X Window System
886
887Some influential environment variables:
888 CC C compiler command
889 CFLAGS C compiler flags
890 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
891 nonstandard directory <lib dir>
892 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
893 headers in a nonstandard directory <include dir>
894 CPP C preprocessor
895
896Use these variables to override the choices made by `configure' or to help
897it to find libraries and programs with nonstandard names/locations.
898
c0d27fcc 899_ACEOF
503d2be0
AS
900fi
901
902if test "$ac_init_help" = "recursive"; then
903 # If there are subdirs, report their specific --help.
904 ac_popdir=`pwd`
c0d27fcc
MR
905 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
906 test -d $ac_dir || continue
907 ac_builddir=.
908
909if test "$ac_dir" != .; then
910 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
911 # A "../" for each directory in $ac_dir_suffix.
912 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
913else
914 ac_dir_suffix= ac_top_builddir=
915fi
503d2be0 916
c0d27fcc
MR
917case $srcdir in
918 .) # No --srcdir option. We are building in place.
919 ac_srcdir=.
920 if test -z "$ac_top_builddir"; then
921 ac_top_srcdir=.
922 else
923 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
924 fi ;;
925 [\\/]* | ?:[\\/]* ) # Absolute path.
926 ac_srcdir=$srcdir$ac_dir_suffix;
927 ac_top_srcdir=$srcdir ;;
928 *) # Relative path.
929 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
930 ac_top_srcdir=$ac_top_builddir$srcdir ;;
931esac
35996d22
AS
932
933# Do not use `cd foo && pwd` to compute absolute paths, because
934# the directories may not exist.
935case `pwd` in
936.) ac_abs_builddir="$ac_dir";;
937*)
938 case "$ac_dir" in
939 .) ac_abs_builddir=`pwd`;;
940 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
941 *) ac_abs_builddir=`pwd`/"$ac_dir";;
942 esac;;
943esac
944case $ac_abs_builddir in
945.) ac_abs_top_builddir=${ac_top_builddir}.;;
946*)
947 case ${ac_top_builddir}. in
948 .) ac_abs_top_builddir=$ac_abs_builddir;;
949 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
950 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
951 esac;;
952esac
953case $ac_abs_builddir in
954.) ac_abs_srcdir=$ac_srcdir;;
955*)
956 case $ac_srcdir in
957 .) ac_abs_srcdir=$ac_abs_builddir;;
958 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
959 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
960 esac;;
961esac
962case $ac_abs_builddir in
963.) ac_abs_top_srcdir=$ac_top_srcdir;;
964*)
965 case $ac_top_srcdir in
966 .) ac_abs_top_srcdir=$ac_abs_builddir;;
967 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
968 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
969 esac;;
970esac
c0d27fcc
MR
971
972 cd $ac_dir
503d2be0 973 # Check for guested configure; otherwise get Cygnus style configure.
c0d27fcc 974 if test -f $ac_srcdir/configure.gnu; then
503d2be0 975 echo
c0d27fcc
MR
976 $SHELL $ac_srcdir/configure.gnu --help=recursive
977 elif test -f $ac_srcdir/configure; then
503d2be0 978 echo
c0d27fcc
MR
979 $SHELL $ac_srcdir/configure --help=recursive
980 elif test -f $ac_srcdir/configure.ac ||
35996d22 981 test -f $ac_srcdir/configure.in; then
503d2be0
AS
982 echo
983 $ac_configure --help
984 else
c0d27fcc 985 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
503d2be0 986 fi
57669b57 987 cd $ac_popdir
503d2be0
AS
988 done
989fi
990
991test -n "$ac_init_help" && exit 0
992if $ac_init_version; then
c0d27fcc 993 cat <<\_ACEOF
503d2be0 994
35996d22 995Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
996This configure script is free software; the Free Software Foundation
997gives unlimited permission to copy, distribute and modify it.
c0d27fcc 998_ACEOF
503d2be0
AS
999 exit 0
1000fi
1001exec 5>config.log
c0d27fcc 1002cat >&5 <<_ACEOF
503d2be0
AS
1003This file contains any messages produced by compilers while
1004running configure, to aid debugging if configure makes a mistake.
1005
1006It was created by $as_me, which was
35996d22 1007generated by GNU Autoconf 2.59. Invocation command line was
503d2be0
AS
1008
1009 $ $0 $@
1010
c0d27fcc 1011_ACEOF
503d2be0
AS
1012{
1013cat <<_ASUNAME
c0d27fcc
MR
1014## --------- ##
1015## Platform. ##
1016## --------- ##
503d2be0
AS
1017
1018hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1019uname -m = `(uname -m) 2>/dev/null || echo unknown`
1020uname -r = `(uname -r) 2>/dev/null || echo unknown`
1021uname -s = `(uname -s) 2>/dev/null || echo unknown`
1022uname -v = `(uname -v) 2>/dev/null || echo unknown`
1023
1024/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1025/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1026
1027/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1028/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1029/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1030hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1031/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1032/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1033/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1034
925c2f3f 1035_ASUNAME
c0d27fcc
MR
1036
1037as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1038for as_dir in $PATH
1039do
1040 IFS=$as_save_IFS
1041 test -z "$as_dir" && as_dir=.
1042 echo "PATH: $as_dir"
1043done
1044
503d2be0
AS
1045} >&5
1046
c0d27fcc
MR
1047cat >&5 <<_ACEOF
1048
1049
1050## ----------- ##
1051## Core tests. ##
1052## ----------- ##
1053
1054_ACEOF
503d2be0 1055
503d2be0
AS
1056
1057# Keep a trace of the command line.
1058# Strip out --no-create and --no-recursion so they do not pile up.
19650fd6 1059# Strip out --silent because we don't want to record it for future runs.
503d2be0 1060# Also quote any args containing shell meta-characters.
19650fd6 1061# Make two passes to allow for proper duplicate-argument suppression.
503d2be0 1062ac_configure_args=
19650fd6
AS
1063ac_configure_args0=
1064ac_configure_args1=
503d2be0 1065ac_sep=
19650fd6
AS
1066ac_must_keep_next=false
1067for ac_pass in 1 2
503d2be0 1068do
19650fd6
AS
1069 for ac_arg
1070 do
1071 case $ac_arg in
1072 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1073 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1074 | -silent | --silent | --silen | --sile | --sil)
1075 continue ;;
1076 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1077 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1078 esac
1079 case $ac_pass in
1080 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1081 2)
1082 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1083 if test $ac_must_keep_next = true; then
35996d22 1084 ac_must_keep_next=false # Got value, back to normal.
19650fd6 1085 else
35996d22
AS
1086 case $ac_arg in
1087 *=* | --config-cache | -C | -disable-* | --disable-* \
1088 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1089 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1090 | -with-* | --with-* | -without-* | --without-* | --x)
1091 case "$ac_configure_args0 " in
1092 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1093 esac
1094 ;;
1095 -* ) ac_must_keep_next=true ;;
1096 esac
19650fd6
AS
1097 fi
1098 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1099 # Get rid of the leading space.
1100 ac_sep=" "
1101 ;;
1102 esac
1103 done
503d2be0 1104done
19650fd6
AS
1105$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1106$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
503d2be0
AS
1107
1108# When interrupted or exit'd, cleanup temporary files, and complete
1109# config.log. We remove comments because anyway the quotes in there
1110# would cause problems or look ugly.
c0d27fcc
MR
1111# WARNING: Be sure not to use single quotes in there, as some shells,
1112# such as our DU 5.0 friend, will then `close' the trap.
503d2be0
AS
1113trap 'exit_status=$?
1114 # Save into config.log some information that might help in debugging.
c0d27fcc
MR
1115 {
1116 echo
6bae0ccf 1117
c0d27fcc
MR
1118 cat <<\_ASBOX
1119## ---------------- ##
1120## Cache variables. ##
1121## ---------------- ##
1122_ASBOX
1123 echo
1124 # The following way of writing the cache mishandles newlines in values,
503d2be0
AS
1125{
1126 (set) 2>&1 |
1127 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1128 *ac_space=\ *)
1129 sed -n \
35996d22
AS
1130 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1131 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
503d2be0
AS
1132 ;;
1133 *)
1134 sed -n \
35996d22 1135 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
1136 ;;
1137 esac;
c0d27fcc
MR
1138}
1139 echo
6bae0ccf
DL
1140
1141 cat <<\_ASBOX
1142## ----------------- ##
1143## Output variables. ##
1144## ----------------- ##
1145_ASBOX
1146 echo
1147 for ac_var in $ac_subst_vars
1148 do
1149 eval ac_val=$`echo $ac_var`
1150 echo "$ac_var='"'"'$ac_val'"'"'"
1151 done | sort
1152 echo
1153
1154 if test -n "$ac_subst_files"; then
1155 cat <<\_ASBOX
1156## ------------- ##
1157## Output files. ##
1158## ------------- ##
1159_ASBOX
1160 echo
1161 for ac_var in $ac_subst_files
1162 do
1163 eval ac_val=$`echo $ac_var`
35996d22 1164 echo "$ac_var='"'"'$ac_val'"'"'"
6bae0ccf
DL
1165 done | sort
1166 echo
1167 fi
1168
c0d27fcc
MR
1169 if test -s confdefs.h; then
1170 cat <<\_ASBOX
1171## ----------- ##
1172## confdefs.h. ##
1173## ----------- ##
1174_ASBOX
1175 echo
6bae0ccf 1176 sed "/^$/d" confdefs.h | sort
c0d27fcc
MR
1177 echo
1178 fi
1179 test "$ac_signal" != 0 &&
1180 echo "$as_me: caught signal $ac_signal"
1181 echo "$as_me: exit $exit_status"
1182 } >&5
35996d22 1183 rm -f core *.core &&
c0d27fcc 1184 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
503d2be0
AS
1185 exit $exit_status
1186 ' 0
1187for ac_signal in 1 2 13 15; do
1188 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1189done
1190ac_signal=0
1191
1192# confdefs.h avoids OS command line length limits that DEFS can exceed.
1193rm -rf conftest* confdefs.h
1194# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1195echo >confdefs.h
ba4481b5 1196
c0d27fcc
MR
1197# Predefined preprocessor variables.
1198
1199cat >>confdefs.h <<_ACEOF
1200#define PACKAGE_NAME "$PACKAGE_NAME"
1201_ACEOF
1202
1203
1204cat >>confdefs.h <<_ACEOF
1205#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1206_ACEOF
1207
1208
1209cat >>confdefs.h <<_ACEOF
1210#define PACKAGE_VERSION "$PACKAGE_VERSION"
1211_ACEOF
1212
1213
1214cat >>confdefs.h <<_ACEOF
1215#define PACKAGE_STRING "$PACKAGE_STRING"
1216_ACEOF
1217
1218
1219cat >>confdefs.h <<_ACEOF
1220#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1221_ACEOF
1222
1223
503d2be0 1224# Let the site file select an alternate cache file if it wants to.
ba4481b5
DL
1225# Prefer explicitly selected file to automatically selected ones.
1226if test -z "$CONFIG_SITE"; then
1227 if test "x$prefix" != xNONE; then
1228 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1229 else
1230 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1231 fi
1232fi
1233for ac_site_file in $CONFIG_SITE; do
1234 if test -r "$ac_site_file"; then
c0d27fcc 1235 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
503d2be0 1236echo "$as_me: loading site script $ac_site_file" >&6;}
c0d27fcc 1237 sed 's/^/| /' "$ac_site_file" >&5
ba4481b5
DL
1238 . "$ac_site_file"
1239 fi
1240done
1241
1242if test -r "$cache_file"; then
503d2be0
AS
1243 # Some versions of bash will fail to source /dev/null (special
1244 # files actually), so we avoid doing that.
1245 if test -f "$cache_file"; then
c0d27fcc 1246 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
503d2be0
AS
1247echo "$as_me: loading cache $cache_file" >&6;}
1248 case $cache_file in
1249 [\\/]* | ?:[\\/]* ) . $cache_file;;
1250 *) . ./$cache_file;;
1251 esac
1252 fi
ba4481b5 1253else
c0d27fcc 1254 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
503d2be0
AS
1255echo "$as_me: creating cache $cache_file" >&6;}
1256 >$cache_file
1257fi
1258
1259# Check that the precious variables saved in the cache have kept the same
1260# value.
1261ac_cache_corrupted=false
1262for ac_var in `(set) 2>&1 |
35996d22 1263 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
503d2be0
AS
1264 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1265 eval ac_new_set=\$ac_env_${ac_var}_set
1266 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1267 eval ac_new_val="\$ac_env_${ac_var}_value"
1268 case $ac_old_set,$ac_new_set in
1269 set,)
c0d27fcc 1270 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
503d2be0
AS
1271echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1272 ac_cache_corrupted=: ;;
1273 ,set)
c0d27fcc 1274 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
503d2be0
AS
1275echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1276 ac_cache_corrupted=: ;;
1277 ,);;
1278 *)
1279 if test "x$ac_old_val" != "x$ac_new_val"; then
35996d22 1280 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
503d2be0 1281echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
35996d22 1282 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
503d2be0 1283echo "$as_me: former value: $ac_old_val" >&2;}
35996d22 1284 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
503d2be0 1285echo "$as_me: current value: $ac_new_val" >&2;}
35996d22 1286 ac_cache_corrupted=:
503d2be0
AS
1287 fi;;
1288 esac
c0d27fcc 1289 # Pass precious variables to config.status.
503d2be0
AS
1290 if test "$ac_new_set" = set; then
1291 case $ac_new_val in
1292 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
c0d27fcc
MR
1293 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1294 *) ac_arg=$ac_var=$ac_new_val ;;
1295 esac
1296 case " $ac_configure_args " in
1297 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1298 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
503d2be0
AS
1299 esac
1300 fi
1301done
1302if $ac_cache_corrupted; then
c0d27fcc 1303 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
503d2be0 1304echo "$as_me: error: changes in the environment can compromise the build" >&2;}
c0d27fcc 1305 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
503d2be0
AS
1306echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1307 { (exit 1); exit 1; }; }
ba4481b5
DL
1308fi
1309
1310ac_ext=c
ba4481b5 1311ac_cpp='$CPP $CPPFLAGS'
503d2be0
AS
1312ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1313ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1314ac_compiler_gnu=$ac_cv_c_compiler_gnu
1315
c0d27fcc
MR
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
ba4481b5 1332
6bae0ccf
DL
1333
1334 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
ba4481b5 1335
c0d27fcc 1336
ba5da88a
PJ
1337test "$program_prefix" != NONE &&
1338 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1339# Use a double $ so make ignores it.
1340test "$program_suffix" != NONE &&
1341 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1342# Double any \ or $. echo might interpret backslashes.
1343# By default was `s,x,x', remove it if useless.
1344cat <<\_ACEOF >conftest.sed
1345s/[\\$]/&&/g;s/;s,x,x,$//
1346_ACEOF
1347program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1348rm conftest.sed
1349
c0d27fcc 1350
ba4481b5
DL
1351lispdir='${datadir}/emacs/${version}/lisp'
1352locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1353'${datadir}/emacs/site-lisp:${datadir}/emacs/${version}/leim'
1354lisppath='${locallisppath}:${lispdir}'
1355etcdir='${datadir}/emacs/${version}/etc'
1356archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1357docdir='${datadir}/emacs/${version}/etc'
24b01ec4 1358gamedir='${localstatedir}/games/emacs'
98418dba
CW
1359
1360gameuser=games
1361
c0d27fcc 1362
ba4481b5
DL
1363# Check whether --with-gcc or --without-gcc was given.
1364if test "${with_gcc+set}" = set; then
1365 withval="$with_gcc"
503d2be0
AS
1366
1367fi;
ba4481b5
DL
1368
1369# Check whether --with-pop or --without-pop was given.
1370if test "${with_pop+set}" = set; then
1371 withval="$with_pop"
243cf185 1372 if test "$withval" = yes; then
c0d27fcc 1373 cat >>confdefs.h <<\_ACEOF
ba4481b5 1374#define MAIL_USE_POP 1
c0d27fcc 1375_ACEOF
ba4481b5 1376
243cf185
DL
1377else :
1378fi
3d9fec71 1379else
c0d27fcc 1380 cat >>confdefs.h <<\_ACEOF
3d9fec71 1381#define MAIL_USE_POP 1
c0d27fcc 1382_ACEOF
3d9fec71 1383
503d2be0 1384fi;
ba4481b5 1385
c0d27fcc 1386
a21616bd
KR
1387# Check whether --with-kerberos or --without-kerberos was given.
1388if test "${with_kerberos+set}" = set; then
1389 withval="$with_kerberos"
c0d27fcc 1390 cat >>confdefs.h <<\_ACEOF
a21616bd 1391#define KERBEROS 1
c0d27fcc 1392_ACEOF
a21616bd 1393
503d2be0 1394fi;
a21616bd 1395
c0d27fcc 1396
a21616bd
KR
1397# Check whether --with-kerberos5 or --without-kerberos5 was given.
1398if test "${with_kerberos5+set}" = set; then
1399 withval="$with_kerberos5"
1400 if test "${with_kerberos5+set}" = set; then
1401 if test "${with_kerberos+set}" != set; then
1402 with_kerberos=yes
c0d27fcc 1403 cat >>confdefs.h <<\_ACEOF
a21616bd 1404#define KERBEROS 1
c0d27fcc 1405_ACEOF
a21616bd
KR
1406
1407 fi
1408fi
b936fae4 1409
c0d27fcc 1410cat >>confdefs.h <<\_ACEOF
a21616bd 1411#define KERBEROS5 1
c0d27fcc 1412_ACEOF
a21616bd 1413
503d2be0 1414fi;
a21616bd 1415
ba4481b5
DL
1416# Check whether --with-hesiod or --without-hesiod was given.
1417if test "${with_hesiod+set}" = set; then
1418 withval="$with_hesiod"
b936fae4 1419
c0d27fcc 1420cat >>confdefs.h <<\_ACEOF
ba4481b5 1421#define HESIOD 1
c0d27fcc 1422_ACEOF
ba4481b5 1423
503d2be0 1424fi;
ba4481b5 1425
c0d27fcc 1426
2c9dccc9
PJ
1427# Check whether --with-sound or --without-sound was given.
1428if test "${with_sound+set}" = set; then
1429 withval="$with_sound"
1430
1431fi;
1432
c0d27fcc 1433
ba4481b5
DL
1434# Check whether --with-x-toolkit or --without-x-toolkit was given.
1435if test "${with_x_toolkit+set}" = set; then
1436 withval="$with_x_toolkit"
1437 case "${withval}" in
1438 y | ye | yes ) val=athena ;;
1439 n | no ) val=no ;;
1440 l | lu | luc | luci | lucid ) val=lucid ;;
1441 a | at | ath | athe | athen | athena ) val=athena ;;
1442 m | mo | mot | moti | motif ) val=motif ;;
488dd4c4 1443 g | gt | gtk ) val=gtk ;;
ba4481b5 1444 * )
c0d27fcc 1445{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1446this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1447Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1448echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1449this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1450Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1451 { (exit 1); exit 1; }; }
ba4481b5
DL
1452 ;;
1453 esac
1454 with_x_toolkit=$val
1455
503d2be0 1456fi;
ba4481b5
DL
1457
1458# Check whether --with-xpm or --without-xpm was given.
1459if test "${with_xpm+set}" = set; then
1460 withval="$with_xpm"
503d2be0
AS
1461
1462fi;
ba4481b5
DL
1463
1464# Check whether --with-jpeg or --without-jpeg was given.
1465if test "${with_jpeg+set}" = set; then
1466 withval="$with_jpeg"
503d2be0
AS
1467
1468fi;
ba4481b5
DL
1469
1470# Check whether --with-tiff or --without-tiff was given.
1471if test "${with_tiff+set}" = set; then
1472 withval="$with_tiff"
503d2be0
AS
1473
1474fi;
ba4481b5
DL
1475
1476# Check whether --with-gif or --without-gif was given.
1477if test "${with_gif+set}" = set; then
1478 withval="$with_gif"
503d2be0
AS
1479
1480fi;
ba4481b5
DL
1481
1482# Check whether --with-png or --without-png was given.
1483if test "${with_png+set}" = set; then
1484 withval="$with_png"
503d2be0
AS
1485
1486fi;
ba4481b5 1487
488dd4c4
JD
1488# Check whether --with-gtk or --without-gtk was given.
1489if test "${with_gtk+set}" = set; then
1490 withval="$with_gtk"
1491
1492fi;
1493
1494# Check whether --with-pkg-config-prog or --without-pkg-config-prog was given.
1495if test "${with_pkg_config_prog+set}" = set; then
1496 withval="$with_pkg_config_prog"
1497
1498fi;
1499
ba4481b5
DL
1500# Check whether --with-toolkit-scroll-bars or --without-toolkit-scroll-bars was given.
1501if test "${with_toolkit_scroll_bars+set}" = set; then
1502 withval="$with_toolkit_scroll_bars"
503d2be0
AS
1503
1504fi;
ba4481b5 1505
1d36487c
GM
1506# Check whether --with-xim or --without-xim was given.
1507if test "${with_xim+set}" = set; then
1508 withval="$with_xim"
1d36487c 1509
503d2be0 1510fi;
ba4481b5 1511
e0f712ba
AC
1512# Check whether --with-carbon or --without-carbon was given.
1513if test "${with_carbon+set}" = set; then
1514 withval="$with_carbon"
1515
1516fi;
6a3a24fa
JD
1517# Check whether --enable-carbon-app or --disable-carbon-app was given.
1518if test "${enable_carbon_app+set}" = set; then
1519 enableval="$enable_carbon_app"
1520 carbon_appdir_x=${enableval}
1521fi;
e0f712ba 1522
19650fd6
AS
1523# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1524if test "${enable_maintainer_mode+set}" = set; then
1525 enableval="$enable_maintainer_mode"
1526 USE_MAINTAINER_MODE=$enableval
1527else
1528 USE_MAINTAINER_MODE=no
1529fi;
1530if test $USE_MAINTAINER_MODE = yes; then
1531 MAINT=
1532else
1533 MAINT=#
1534fi
1535
1536
ba4481b5 1537#### Make srcdir absolute, if it isn't already. It's important to
17494071 1538#### avoid running the path through pwd unnecessarily, since pwd can
ba4481b5
DL
1539#### give you automounter prefixes, which can go away. We do all this
1540#### so Emacs can find its files when run uninstalled.
17494071
GM
1541## Make sure CDPATH doesn't affect cd (in case PWD is relative).
1542unset CDPATH
ba4481b5
DL
1543case "${srcdir}" in
1544 /* ) ;;
1545 . )
1546 ## We may be able to use the $PWD environment variable to make this
1547 ## absolute. But sometimes PWD is inaccurate.
df645f7c
AS
1548 ## Note: we used to use ${PWD} at the end instead of `pwd`,
1549 ## but that tested only for a well-formed and valid PWD,
1550 ## it did not object when PWD was well-formed and valid but just wrong.
1551 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
ba4481b5
DL
1552 then
1553 srcdir="$PWD"
1554 else
1555 srcdir="`(cd ${srcdir}; pwd)`"
1556 fi
1557 ;;
1558 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
1559esac
1560
1561#### Check if the source directory already has a configured system in it.
1562if test `pwd` != `(cd ${srcdir} && pwd)` \
1563 && test -f "${srcdir}/src/config.h" ; then
c0d27fcc 1564 { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
503d2be0
AS
1565 as a build directory right now; it has been configured in its own
1566 right. To configure in another directory as well, you MUST
1567 use GNU make. If you do not have GNU make, then you must
1568 now do \`make distclean' in ${srcdir},
1569 and then run $0 again." >&5
1570echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
ba4481b5
DL
1571 as a build directory right now; it has been configured in its own
1572 right. To configure in another directory as well, you MUST
1573 use GNU make. If you do not have GNU make, then you must
1574 now do \`make distclean' in ${srcdir},
503d2be0 1575 and then run $0 again." >&2;}
ba4481b5
DL
1576fi
1577
1578#### Given the configuration name, set machfile and opsysfile to the
1579#### names of the m/*.h and s/*.h files we should use.
1580
1581### Canonicalize the configuration name.
1582
1583ac_aux_dir=
1584for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1585 if test -f $ac_dir/install-sh; then
1586 ac_aux_dir=$ac_dir
1587 ac_install_sh="$ac_aux_dir/install-sh -c"
1588 break
1589 elif test -f $ac_dir/install.sh; then
1590 ac_aux_dir=$ac_dir
1591 ac_install_sh="$ac_aux_dir/install.sh -c"
1592 break
503d2be0
AS
1593 elif test -f $ac_dir/shtool; then
1594 ac_aux_dir=$ac_dir
1595 ac_install_sh="$ac_aux_dir/shtool install -c"
1596 break
ba4481b5
DL
1597 fi
1598done
1599if test -z "$ac_aux_dir"; then
c0d27fcc 1600 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1601echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1602 { (exit 1); exit 1; }; }
ba4481b5 1603fi
503d2be0
AS
1604ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1605ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1606ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1607
1608# Make sure we can run config.sub.
503d2be0 1609$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1610 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1611echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1612 { (exit 1); exit 1; }; }
1613
c0d27fcc 1614echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1615echo $ECHO_N "checking build system type... $ECHO_C" >&6
1616if test "${ac_cv_build+set}" = set; then
1617 echo $ECHO_N "(cached) $ECHO_C" >&6
1618else
1619 ac_cv_build_alias=$build_alias
1620test -z "$ac_cv_build_alias" &&
1621 ac_cv_build_alias=`$ac_config_guess`
1622test -z "$ac_cv_build_alias" &&
c0d27fcc 1623 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1624echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1625 { (exit 1); exit 1; }; }
1626ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1627 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1628echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1629 { (exit 1); exit 1; }; }
1630
1631fi
c0d27fcc 1632echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1633echo "${ECHO_T}$ac_cv_build" >&6
1634build=$ac_cv_build
1635build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1636build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1637build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1638
c0d27fcc
MR
1639
1640echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1641echo $ECHO_N "checking host system type... $ECHO_C" >&6
1642if test "${ac_cv_host+set}" = set; then
1643 echo $ECHO_N "(cached) $ECHO_C" >&6
1644else
1645 ac_cv_host_alias=$host_alias
1646test -z "$ac_cv_host_alias" &&
1647 ac_cv_host_alias=$ac_cv_build_alias
1648ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1649 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1650echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1651 { (exit 1); exit 1; }; }
1652
1653fi
c0d27fcc 1654echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1655echo "${ECHO_T}$ac_cv_host" >&6
1656host=$ac_cv_host
1657host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1658host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1659host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1660
c0d27fcc 1661
ba4481b5 1662canonical=$host
531a3336 1663configuration=${host_alias-$host}
ba4481b5 1664
c0d27fcc 1665
22044edf 1666
ba4481b5
DL
1667### If you add support for a new configuration, add code to this
1668### switch statement to recognize your configuration name and select
1669### the appropriate operating system and machine description files.
1670
1671### You would hope that you could choose an m/*.h file pretty much
1672### based on the machine portion of the configuration name, and an s-
1673### file based on the operating system portion. However, it turns out
1674### that each m/*.h file is pretty manufacturer-specific - for
1675### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1676### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1677### machines. So we basically have to have a special case for each
1678### configuration name.
1679###
1680### As far as handling version numbers on operating systems is
1681### concerned, make sure things will fail in a fixable way. If
1682### /etc/MACHINES doesn't say anything about version numbers, be
1683### prepared to handle anything reasonably. If version numbers
1684### matter, be sure /etc/MACHINES says something about it.
1685###
1686### Eric Raymond says we should accept strings like "sysvr4" to mean
1687### "System V Release 4"; he writes, "The old convention encouraged
1688### confusion between `system' and `release' levels'."
1689
1690machine='' opsys='' unported=no
1691case "${canonical}" in
1692
1096bcc0
GM
1693 ## FreeBSD ports
1694 *-*-freebsd* )
1695 opsys=freebsd
1696 case "${canonical}" in
1697 alpha*-*-freebsd*) machine=alpha ;;
1698 i[3456]86-*-freebsd*) machine=intel386 ;;
1699 esac
1700 ;;
1701
ba4481b5
DL
1702 ## NetBSD ports
1703 *-*-netbsd* )
1704 opsys=netbsd
dd038e26 1705 if test -f /usr/lib/crti.o; then
f57bd967
DL
1706
1707cat >>confdefs.h <<\_ACEOF
1708#define HAVE_CRTIN
dd038e26
AS
1709_ACEOF
1710
1711 fi
1712
ba4481b5
DL
1713 case "${canonical}" in
1714 alpha*-*-netbsd*) machine=alpha ;;
1715 i[3456]86-*-netbsd*) machine=intel386 ;;
1716 m68k-*-netbsd*)
1717 # This is somewhat bogus.
1718 machine=hp9000s300 ;;
1719 powerpc-apple-netbsd*) machine=macppc ;;
1720 mips-*-netbsd*) machine=pmax ;;
2df636f4 1721 mipsel-*-netbsd*) machine=pmax ;;
97836269 1722 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1723 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1724 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1725 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1726 vax-*-netbsd*) machine=vax ;;
2df636f4 1727 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1728 esac
1729 ;;
1730
1731 ## OpenBSD ports
1732 *-*-openbsd* )
1733 opsys=openbsd
1734 case "${canonical}" in
1735 alpha*-*-openbsd*) machine=alpha ;;
1736 i386-*-openbsd*) machine=intel386 ;;
1737 m68k-*-openbsd*) machine=hp9000s300 ;;
1738 mipsel-*-openbsd*) machine=pmax ;;
1739 ns32k-*-openbsd*) machine=ns32000 ;;
1740 sparc-*-openbsd*) machine=sparc ;;
1741 vax-*-openbsd*) machine=vax ;;
1742 esac
1743 ;;
1744
1745 ## Acorn RISCiX:
1746 arm-acorn-riscix1.1* )
1747 machine=acorn opsys=riscix1-1
1748 ;;
1749 arm-acorn-riscix1.2* | arm-acorn-riscix )
1750 ## This name is riscix12 instead of riscix1.2
1751 ## to avoid a file name conflict on MSDOS.
1752 machine=acorn opsys=riscix12
1753 ;;
1754
1755 ## BSDI ports
1756 *-*-bsdi* )
1757 opsys=bsdi
1758 case "${canonical}" in
1759 i[345]86-*-bsdi*) machine=intel386 ;;
1760 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1761 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1762 esac
1763 case "${canonical}" in
1764 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1765 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1766 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1767 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1768 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1769 esac
1770 ;;
1771
1772 ## Alliant machines
1773 ## Strictly speaking, we need the version of the alliant operating
1774 ## system to choose the right machine file, but currently the
1775 ## configuration name doesn't tell us enough to choose the right
1776 ## one; we need to give alliants their own operating system name to
1777 ## do this right. When someone cares, they can help us.
1778 fx80-alliant-* )
1779 machine=alliant4 opsys=bsd4-2
1780 ;;
1781 i860-alliant-* )
1782 machine=alliant-2800 opsys=bsd4-3
1783 ;;
1784
1785 ## Alpha (DEC) machines.
1786 alpha*-dec-osf* )
1787 machine=alpha opsys=osf1
1788 # This is needed to find X11R6.1 libraries for certain tests.
1789 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1790 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1791 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1792 # due to non-traditional preprocessing with the current compiler
1793 # defaults. OSF 4 can also have that compiler version, and there
1794 # seems always to have been a usable /usr/bin/cpp.
1795 NON_GNU_CPP=/usr/bin/cpp
ca512671 1796 case "${canonical}" in
a55b799a 1797 alpha*-dec-osf[5-9]*)
bb17930d 1798 opsys=osf5-0 ;;
ca512671 1799 esac
ba4481b5
DL
1800 ;;
1801
1802 alpha*-*-linux-gnu* )
1803 machine=alpha opsys=gnu-linux
1804 ;;
1805
c4bb2108
DL
1806 arm*-*-linux-gnu* )
1807 machine=arm opsys=gnu-linux
1808 ;;
1809
1810 ppc-*-linux | \
1811 powerpc-*-linux* )
3aeecf97 1812 machine=macppc opsys=gnu-linux
c4bb2108
DL
1813 ;;
1814
ba4481b5
DL
1815 ## Altos 3068
1816 m68*-altos-sysv* )
1817 machine=altos opsys=usg5-2
1818 ;;
1819
1820 ## Amdahl UTS
1821 580-amdahl-sysv* )
1822 machine=amdahl opsys=usg5-2-2
1823 ;;
1824
1825 ## Apollo, Domain/OS
1826 m68*-apollo-* )
1827 machine=apollo opsys=bsd4-3
1828 ;;
1829
1830 ## AT&T 3b2, 3b5, 3b15, 3b20
1831 we32k-att-sysv* )
1832 machine=att3b opsys=usg5-2-2
1833 ;;
1834
1835 ## AT&T 3b1 - The Mighty Unix PC!
1836 m68*-att-sysv* )
1837 machine=7300 opsys=usg5-2-2
1838 ;;
1839
1840 ## Bull dpx20
1841 rs6000-bull-bosx* )
1842 machine=ibmrs6000 opsys=aix3-2
1843 ;;
1844
1845 ## Bull dpx2
1846 m68*-bull-sysv3* )
1847 machine=dpx2 opsys=usg5-3
1848 ;;
1849
1850 ## Bull sps7
1851 m68*-bull-sysv2* )
1852 machine=sps7 opsys=usg5-2
1853 ;;
1854
1855 ## CCI 5/32, 6/32 -- see "Tahoe".
1856
1857 ## Celerity
1858 ## I don't know what configuration name to use for this; config.sub
1859 ## doesn't seem to know anything about it. Hey, Celerity users, get
1860 ## in touch with us!
1861 celerity-celerity-bsd* )
1862 machine=celerity opsys=bsd4-2
1863 ;;
1864
1865 ## Clipper
1866 ## What operating systems does this chip run that Emacs has been
1867 ## tested on?
1868 clipper-* )
1869 machine=clipper
1870 ## We'll use the catch-all code at the bottom to guess the
1871 ## operating system.
1872 ;;
1873
df645f7c
AS
1874 ## Compaq Nonstop
1875 mips-compaq-nonstopux* )
1876 machine=nonstopux opsys=nonstopux
1877 ;;
1878
ba4481b5
DL
1879 ## Convex
1880 *-convex-bsd* | *-convex-convexos* )
1881 machine=convex opsys=bsd4-3
1882 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1883 NON_GNU_CPP="cc -E -P"
1884 ;;
1885
1886 ## Cubix QBx/386
1887 i[3456]86-cubix-sysv* )
1888 machine=intel386 opsys=usg5-3
1889 ;;
1890
1891 ## Cydra 5
1892 cydra*-cydrome-sysv* )
1893 machine=cydra5 opsys=usg5-3
1894 ;;
1895
1896 ## Data General AViiON Machines
1897 ## DG changed naming conventions with the release of 5.4.4.10, they
1898 ## dropped the initial 5.4 but left the intervening R. Because of the
1899 ## R this shouldn't conflict with older versions of the OS (which I
1900 ## think were named like dgux4.*). In addition, DG new AViiONs series
1901 ## uses either Motorola M88k or Intel Pentium CPUs.
1902 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1903 machine=aviion opsys=dgux4
1904 ;;
1905 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1906 ## This name is dgux5-4-3 instead of dgux5-4r3
1907 ## to avoid a file name conflict on MSDOS.
1908 machine=aviion opsys=dgux5-4-3
1909 ;;
1910 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1911 machine=aviion opsys=dgux5-4r2
1912 ;;
1913 m88k-dg-dgux* )
1914 machine=aviion opsys=dgux
1915 ;;
1916
1917 ## Data General AViiON Intel (x86) Machines
1918 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1919 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1920 i[345]86-dg-dguxR4* )
1921 machine=aviion-intel opsys=dgux4
1922 ;;
1923
1924 ## DECstations
1925 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1926 machine=pmax opsys=bsd4-2
1927 ;;
1928 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1929 machine=pmax opsys=bsd4-3
1930 ;;
1931 mips-dec-ultrix* )
1932 machine=pmax opsys=ultrix4-3
1933 ;;
1934 mips-dec-osf* )
1935 machine=pmax opsys=osf1
1936 ;;
1937 mips-dec-mach_bsd4.3* )
1938 machine=pmax opsys=mach-bsd4-3
1939 ;;
1940
cd890796
JD
1941 ## Motorola Delta machines
1942 m68k-motorola-sysv* | m68000-motorola-sysv* )
1943 machine=delta opsys=usg5-3
1944 if test -z "`type gnucc | grep 'not found'`"
1945 then
1946 if test -s /etc/167config
1947 then CC="gnucc -m68040"
1948 else CC="gnucc -m68881"
1949 fi
1950 else
1951 if test -z "`type gcc | grep 'not found'`"
1952 then CC=gcc
1953 else CC=cc
1954 fi
1955 fi
1956 ;;
ba4481b5
DL
1957 m88k-motorola-sysv4* )
1958 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1959 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1960 # I hope there are not other 4.0 versions for this machine
1961 # which really need usg5-4 instead.
1962 machine=delta88k opsys=usg5-4-2
1963 ;;
1964 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1965 machine=delta88k opsys=usg5-3
1966 ;;
1967
1968 ## Dual machines
1969 m68*-dual-sysv* )
1970 machine=dual opsys=usg5-2
1971 ;;
1972 m68*-dual-uniplus* )
1973 machine=dual opsys=unipl5-2
1974 ;;
1975
1976 ## Elxsi 6400
1977 elxsi-elxsi-sysv* )
1978 machine=elxsi opsys=usg5-2
1979 ;;
1980
1981 ## Encore machines
1982 ns16k-encore-bsd* )
1983 machine=ns16000 opsys=umax
1984 ;;
1985
65171e3a
DL
1986 ## The GEC 63 - apparently, this port isn't really finished yet.
1987 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
1988
1989 ## Gould Power Node and NP1
1990 pn-gould-bsd4.2* )
1991 machine=gould opsys=bsd4-2
1992 ;;
1993 pn-gould-bsd4.3* )
1994 machine=gould opsys=bsd4-3
1995 ;;
1996 np1-gould-bsd* )
1997 machine=gould-np1 opsys=bsd4-3
1998 ;;
1999
2000 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
2001 ## as far as Emacs is concerned).
2002 m88k-harris-cxux* )
2003 # Build needs to be different on 7.0 and later releases
2004 case "`uname -r`" in
2005 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
2006 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
2007 esac
2008 NON_GNU_CPP="/lib/cpp"
2009 ;;
2010 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
2011 m68k-harris-cxux* )
2012 machine=nh3000 opsys=cxux
2013 ;;
2014 ## Harris power pc NightHawk running Power UNIX (Series 6000)
2015 powerpc-harris-powerunix )
2016 machine=nh6000 opsys=powerunix
2017 NON_GNU_CPP="cc -Xo -E -P"
2018 ;;
2019 ## SR2001/SR2201 running HI-UX/MPP
2020 hppa1.1-hitachi-hiuxmpp* )
2021 machine=sr2k opsys=hiuxmpp
2022 ;;
89a336fa
GM
2023 hppa1.1-hitachi-hiuxwe2* )
2024 machine=sr2k opsys=hiuxwe2
2025 ;;
ba4481b5
DL
2026 ## Honeywell XPS100
2027 xps*-honeywell-sysv* )
2028 machine=xps100 opsys=usg5-2
2029 ;;
2030
2031 ## HP 9000 series 200 or 300
2032 m68*-hp-bsd* )
2033 machine=hp9000s300 opsys=bsd4-3
2034 ;;
2035 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2036 m68*-hp-hpux* )
2037 case "`uname -r`" in
2038 ## Someone's system reports A.B8.05 for this.
2039 ## I wonder what other possibilities there are.
2040 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2041 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2042 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2043 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2044 *) machine=hp9000s300 opsys=hpux ;;
2045 esac
2046 ;;
2047
2048 ## HP 9000 series 700 and 800, running HP/UX
2049 hppa*-hp-hpux7* )
2050 machine=hp800 opsys=hpux
2051 ;;
2052 hppa*-hp-hpux8* )
2053 machine=hp800 opsys=hpux8
2054 ;;
2055 hppa*-hp-hpux9shr* )
2056 machine=hp800 opsys=hpux9shr
2057 ;;
2058 hppa*-hp-hpux9* )
2059 machine=hp800 opsys=hpux9
2060 ;;
b0e44248
RB
2061 hppa*-hp-hpux10.2* )
2062 machine=hp800 opsys=hpux10-20
2063 ;;
cc227489 2064 hppa*-hp-hpux10* )
ba4481b5
DL
2065 machine=hp800 opsys=hpux10
2066 ;;
cc227489
MB
2067 hppa*-hp-hpux1[1-9]* )
2068 machine=hp800 opsys=hpux11
2069 ;;
ba4481b5 2070
409d9577
GM
2071 hppa*-*-linux-gnu* )
2072 machine=hp800 opsys=gnu-linux
2073 ;;
2074
ba4481b5
DL
2075 ## HP 9000 series 700 and 800, running HP/UX
2076 hppa*-hp-hpux* )
2077 ## Cross-compilation? Nah!
2078 case "`uname -r`" in
2079 ## Someone's system reports A.B8.05 for this.
2080 ## I wonder what other possibilities there are.
2081 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2082 *.08.* ) machine=hp800 opsys=hpux8 ;;
2083 *.09.* ) machine=hp800 opsys=hpux9 ;;
2084 *) machine=hp800 opsys=hpux10 ;;
2085 esac
2086 ;;
2087 hppa*-*-nextstep* )
2088 machine=hp800 opsys=nextstep
2089 ;;
2090
2091 ## Orion machines
2092 orion-orion-bsd* )
2093 machine=orion opsys=bsd4-2
2094 ;;
2095 clipper-orion-bsd* )
2096 machine=orion105 opsys=bsd4-2
2097 ;;
2098
2099 ## IBM machines
2100 i[3456]86-ibm-aix1.1* )
2101 machine=ibmps2-aix opsys=usg5-2-2
2102 ;;
2103 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2104 machine=ibmps2-aix opsys=usg5-3
2105 ;;
2106 i370-ibm-aix*)
2107 machine=ibm370aix opsys=usg5-3
2108 ;;
55597d70 2109 s390-*-linux-gnu* )
138f0859
GM
2110 machine=ibms390 opsys=gnu-linux
2111 ;;
ba4481b5
DL
2112 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2113 machine=ibmrs6000 opsys=aix3-1
2114 ;;
2115 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2116 machine=ibmrs6000 opsys=aix3-2-5
2117 ;;
2118 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2119 machine=ibmrs6000 opsys=aix4-1
2120 ;;
2121 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2122 machine=ibmrs6000 opsys=aix4-2
2123 ;;
55597d70 2124 rs6000-ibm-aix5* | powerpc-ibm-aix5* )
d6b82250
EZ
2125 machine=ibmrs6000 opsys=aix4-2
2126 ;;
ba4481b5
DL
2127 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2128 machine=ibmrs6000 opsys=aix4
2129 ;;
2130 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2131 machine=ibmrs6000 opsys=aix4-1
2132 ;;
2133 rs6000-ibm-aix* | powerpc-ibm-aix* )
2134 machine=ibmrs6000 opsys=aix3-2
2135 ;;
2136 romp-ibm-bsd4.3* )
2137 machine=ibmrt opsys=bsd4-3
2138 ;;
2139 romp-ibm-bsd4.2* )
2140 machine=ibmrt opsys=bsd4-2
2141 ;;
2142 romp-ibm-aos4.3* )
2143 machine=ibmrt opsys=bsd4-3
2144 ;;
2145 romp-ibm-aos4.2* )
2146 machine=ibmrt opsys=bsd4-2
2147 ;;
2148 romp-ibm-aos* )
2149 machine=ibmrt opsys=bsd4-3
2150 ;;
2151 romp-ibm-bsd* )
2152 machine=ibmrt opsys=bsd4-3
2153 ;;
2154 romp-ibm-aix* )
2155 machine=ibmrt-aix opsys=usg5-2-2
2156 ;;
2157
2158 ## Integrated Solutions `Optimum V'
2159 m68*-isi-bsd4.2* )
2160 machine=isi-ov opsys=bsd4-2
2161 ;;
2162 m68*-isi-bsd4.3* )
2163 machine=isi-ov opsys=bsd4-3
2164 ;;
2165
2166 ## Intel 386 machines where we do care about the manufacturer
2167 i[3456]86-intsys-sysv* )
2168 machine=is386 opsys=usg5-2-2
2169 ;;
2170
2171 ## Prime EXL
2172 i[3456]86-prime-sysv* )
2173 machine=i386 opsys=usg5-3
2174 ;;
2175
2176 ## Sequent Symmetry running Dynix
2177 i[3456]86-sequent-bsd* )
2178 machine=symmetry opsys=bsd4-3
2179 ;;
2180
2181 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2182 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2183 machine=sequent-ptx opsys=ptx4
2184 NON_GNU_CPP=/lib/cpp
2185 ;;
2186
2187 ## Sequent Symmetry running DYNIX/ptx
2188 ## Use the old cpp rather than the newer ANSI one.
2189 i[3456]86-sequent-ptx* )
2190 machine=sequent-ptx opsys=ptx
2191 NON_GNU_CPP="/lib/cpp"
2192 ;;
2193
2194 ## ncr machine running svr4.3.
2195 i[3456]86-ncr-sysv4.3 )
2196 machine=ncr386 opsys=usg5-4-3
2197 ;;
2198
2199 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2200 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2201 i[3456]86-ncr-sysv* )
2202 machine=ncr386 opsys=usg5-4-2
2203 ;;
2204
2205 ## Intel Paragon OSF/1
2206 i860-intel-osf1* )
2207 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2208 ;;
2209
2210 ## Intel 860
2211 i860-*-sysv4* )
2212 machine=i860 opsys=usg5-4
2213 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2214 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2215 ;;
2216
c76e04a8
GM
2217 ## Macintosh PowerPC
2218 powerpc*-*-linux-gnu* )
2219 machine=macppc opsys=gnu-linux
2220 ;;
2221
ba4481b5
DL
2222 ## Masscomp machines
2223 m68*-masscomp-rtu* )
2224 machine=masscomp opsys=rtu
2225 ;;
2226
2227 ## Megatest machines
2228 m68*-megatest-bsd* )
2229 machine=mega68 opsys=bsd4-2
2230 ;;
2231
2232 ## Workstations sold by MIPS
2233 ## This is not necessarily all workstations using the MIPS processor -
2234 ## Irises are produced by SGI, and DECstations by DEC.
2235
2236 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2237 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2238 ## it gives for choosing between the alternatives seems to be "Use
2239 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2240 ## the BSD world." I'll assume that these are instructions for
2241 ## handling two odd situations, and that every other situation
2242 ## should use mips.h and usg5-2-2, they being listed first.
2243 mips-mips-usg* )
2244 machine=mips4
2245 ## Fall through to the general code at the bottom to decide on the OS.
2246 ;;
2247 mips-mips-riscos4* )
2248 machine=mips4 opsys=bsd4-3
2249 NON_GNU_CC="cc -systype bsd43"
2250 NON_GNU_CPP="cc -systype bsd43 -E"
2251 ;;
2252 mips-mips-riscos5* )
2253 machine=mips4 opsys=riscos5
2254 NON_GNU_CC="cc -systype bsd43"
2255 NON_GNU_CPP="cc -systype bsd43 -E"
2256 ;;
2257 mips-mips-bsd* )
2258 machine=mips opsys=bsd4-3
2259 ;;
2260 mips-mips-* )
2261 machine=mips opsys=usg5-2-2
2262 ;;
2263
2264 ## NeXT
2265 m68*-next-* | m68k-*-nextstep* )
2266 machine=m68k opsys=nextstep
2267 ;;
2268
2269 ## The complete machine from National Semiconductor
2270 ns32k-ns-genix* )
2271 machine=ns32000 opsys=usg5-2
2272 ;;
2273
2274 ## NCR machines
2275 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2276 machine=tower32 opsys=usg5-2-2
2277 ;;
2278 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2279 machine=tower32v3 opsys=usg5-3
2280 ;;
2281
2282 ## NEC EWS4800
2283 mips-nec-sysv4*)
2284 machine=ews4800 opsys=ux4800
2285 ;;
2286
2287 ## Nixdorf Targon 31
2288 m68*-nixdorf-sysv* )
2289 machine=targon31 opsys=usg5-2-2
2290 ;;
2291
2292 ## Nu (TI or LMI)
2293 m68*-nu-sysv* )
2294 machine=nu opsys=usg5-2
2295 ;;
2296
2297 ## Plexus
2298 m68*-plexus-sysv* )
2299 machine=plexus opsys=usg5-2
2300 ;;
2301
ba4481b5
DL
2302 ## Pyramid machines
2303 ## I don't really have any idea what sort of processor the Pyramid has,
2304 ## so I'm assuming it is its own architecture.
2305 pyramid-pyramid-bsd* )
2306 machine=pyramid opsys=bsd4-2
2307 ;;
2308
2309 ## Sequent Balance
2310 ns32k-sequent-bsd4.2* )
2311 machine=sequent opsys=bsd4-2
2312 ;;
2313 ns32k-sequent-bsd4.3* )
2314 machine=sequent opsys=bsd4-3
2315 ;;
2316
2317 ## Siemens Nixdorf
2318 mips-siemens-sysv* | mips-sni-sysv*)
2319 machine=mips-siemens opsys=usg5-4
2320 NON_GNU_CC=/usr/ccs/bin/cc
2321 NON_GNU_CPP=/usr/ccs/lib/cpp
2322 ;;
2323
2324 ## Silicon Graphics machines
2325 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2326 m68*-sgi-iris3.5* )
2327 machine=irist opsys=iris3-5
2328 ;;
2329 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2330 machine=irist opsys=iris3-6
2331 ;;
2332 ## Iris 4D
2333 mips-sgi-irix3* )
2334 machine=iris4d opsys=irix3-3
2335 ;;
2336 mips-sgi-irix4* )
2337 machine=iris4d opsys=irix4-0
2338 ;;
2339 mips-sgi-irix6.5 )
2340 machine=iris4d opsys=irix6-5
946173ad
DL
2341 # Without defining _LANGUAGE_C, things get masked out in the headers
2342 # so that, for instance, grepping for `free' in stdlib.h fails and
2343 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2344 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2345 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2346 ;;
2347 mips-sgi-irix6* )
2348 machine=iris4d opsys=irix6-0
c4bb2108 2349 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2350 # but presumably it does no harm.
2351 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2352 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2353 NON_GCC_TEST_OPTIONS=-32
2354 ;;
2355 mips-sgi-irix5.[01]* )
2356 machine=iris4d opsys=irix5-0
2357 ;;
2358 mips-sgi-irix5* | mips-sgi-irix* )
2359 machine=iris4d opsys=irix5-2
2360 ;;
2361
2362 ## SONY machines
2363 m68*-sony-bsd4.2* )
2364 machine=news opsys=bsd4-2
2365 ;;
2366 m68*-sony-bsd4.3* )
2367 machine=news opsys=bsd4-3
2368 ;;
2369 m68*-sony-newsos3* | m68*-sony-news3*)
2370 machine=news opsys=bsd4-3
2371 ;;
2372 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2373 machine=news-risc opsys=bsd4-3
2374 ;;
2375 mips-sony-newsos6* )
2376 machine=news-r6 opsys=newsos6
2377 ;;
2378 mips-sony-news* )
2379 machine=news-risc opsys=newsos5
2380 ;;
2381
2382 ## Stride
2383 m68*-stride-sysv* )
2384 machine=stride opsys=usg5-2
2385 ;;
2386
2387 ## Suns
2388 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2389 machine=sparc opsys=gnu-linux
2390 ;;
2391
d054101f 2392 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2393 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2394 | rs6000-*-solaris2*)
2395 case "${canonical}" in
2396 m68*-sunos1* ) machine=sun1 ;;
2397 m68*-sunos2* ) machine=sun2 ;;
2398 m68* ) machine=sun3 ;;
2399 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2400 i[3456]86-*-* ) machine=intel386 ;;
2401 powerpcle* ) machine=powerpcle ;;
2402 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2403 sparc* ) machine=sparc ;;
2404 * ) unported=yes ;;
2405 esac
2406 case "${canonical}" in
2407 ## The Sun386 didn't get past 4.0.
2408 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2409 *-sunos4.0* ) opsys=sunos4-0 ;;
2410 *-sunos4.1.[3-9]*noshare )
2411 ## This name is sunos413 instead of sunos4-1-3
2412 ## to avoid a file name conflict on MSDOS.
2413 opsys=sunos413
2414 NON_GNU_CPP=/usr/lib/cpp
2415 NON_GCC_TEST_OPTIONS=-Bstatic
2416 GCC_TEST_OPTIONS=-static
2417 ;;
2418 *-sunos4.1.[3-9]* | *-sunos4shr*)
2419 opsys=sunos4shr
2420 NON_GNU_CPP=/usr/lib/cpp
2421 ;;
2422 *-sunos4* | *-sunos )
2423 opsys=sunos4-1
2424 NON_GCC_TEST_OPTIONS=-Bstatic
2425 GCC_TEST_OPTIONS=-static
2426 ;;
2427 *-sunos5.3* | *-solaris2.3* )
2428 opsys=sol2-3
2429 NON_GNU_CPP=/usr/ccs/lib/cpp
2430 ;;
2431 *-sunos5.4* | *-solaris2.4* )
2432 opsys=sol2-4
2433 NON_GNU_CPP=/usr/ccs/lib/cpp
2434 RANLIB="ar -ts"
2435 ;;
2436 *-sunos5.5* | *-solaris2.5* )
2437 opsys=sol2-5
2438 NON_GNU_CPP=/usr/ccs/lib/cpp
2439 RANLIB="ar -ts"
2440 ;;
8e967cf7
MR
2441 *-sunos5.6* | *-solaris2.6* )
2442 opsys=sol2-6
2443 NON_GNU_CPP=/usr/ccs/lib/cpp
2444 RANLIB="ar -ts"
2445 ;;
ba4481b5 2446 *-sunos5* | *-solaris* )
9e71690e 2447 opsys=sol2-6
ba4481b5
DL
2448 NON_GNU_CPP=/usr/ccs/lib/cpp
2449 ;;
2450 * ) opsys=bsd4-2 ;;
2451 esac
2452 ## Watch out for a compiler that we know will not work.
2453 case "${canonical}" in
2454 *-solaris* | *-sunos5* )
2455 if [ "x$CC" = x/usr/ucb/cc ]; then
2456 ## /usr/ucb/cc doesn't work;
2457 ## we should find some other compiler that does work.
2458 unset CC
2459 fi
2460 ;;
2461 *) ;;
2462 esac
2463 ;;
2464 sparc-*-nextstep* )
2465 machine=sparc opsys=nextstep
2466 ;;
2467
2468 ## Tadpole 68k
2469 m68*-tadpole-sysv* )
2470 machine=tad68k opsys=usg5-3
2471 ;;
2472
2473 ## Tahoe machines
2474 tahoe-tahoe-bsd4.2* )
2475 machine=tahoe opsys=bsd4-2
2476 ;;
2477 tahoe-tahoe-bsd4.3* )
2478 machine=tahoe opsys=bsd4-3
2479 ;;
2480
2481 ## Tandem Integrity S2
2482 mips-tandem-sysv* )
2483 machine=tandem-s2 opsys=usg5-3
2484 ;;
2485
2486 ## Tektronix XD88
2487 m88k-tektronix-sysv3* )
2488 machine=tekxd88 opsys=usg5-3
2489 ;;
2490
2491 ## Tektronix 16000 box (6130?)
2492 ns16k-tektronix-bsd* )
2493 machine=ns16000 opsys=bsd4-2
2494 ;;
2495 ## Tektronix 4300
2496 ## src/m/tek4300.h hints that this is a m68k machine.
2497 m68*-tektronix-bsd* )
2498 machine=tek4300 opsys=bsd4-3
2499 ;;
2500
2501 ## Titan P2 or P3
2502 ## We seem to have lost the machine-description file titan.h!
2503 titan-titan-sysv* )
2504 machine=titan opsys=usg5-3
2505 ;;
2506
2507 ## Ustation E30 (SS5E)
2508 m68*-unisys-uniplus* )
2509 machine=ustation opsystem=unipl5-2
2510 ;;
2511
2512 ## Vaxen.
2513 vax-dec-* )
2514 machine=vax
2515 case "${canonical}" in
2516 *-bsd4.1* ) opsys=bsd4-1 ;;
2517 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2518 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2519 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2520 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2521 *-vms* ) opsys=vms ;;
2522 * ) unported=yes
2523 esac
2524 ;;
2525
2526 ## Whitechapel MG1
2527 ns16k-whitechapel-* )
2528 machine=mg1
2529 ## We don't know what sort of OS runs on these; we'll let the
2530 ## operating system guessing code below try.
2531 ;;
2532
2533 ## Wicat
2534 m68*-wicat-sysv* )
2535 machine=wicat opsys=usg5-2
2536 ;;
2537
f4988be7
GM
2538 ## IA-64
2539 ia64*-*-linux* )
2540 machine=ia64 opsys=gnu-linux
2541 ;;
2542
ba4481b5
DL
2543 ## Intel 386 machines where we don't care about the manufacturer
2544 i[3456]86-*-* )
2545 machine=intel386
2546 case "${canonical}" in
c60ee5e7 2547 *-cygwin ) opsys=cygwin ;;
9f817ea4 2548 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2549 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2550 *-isc2.2* ) opsys=isc2-2 ;;
2551 *-isc4.0* ) opsys=isc4-0 ;;
2552 *-isc4.* ) opsys=isc4-1
2553 GCC_TEST_OPTIONS=-posix
2554 NON_GCC_TEST_OPTIONS=-Xp
2555 ;;
2556 *-isc* ) opsys=isc3-0 ;;
2557 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2558 *-esix* ) opsys=esix ;;
2559 *-xenix* ) opsys=xenix ;;
2560 *-linux-gnu* ) opsys=gnu-linux ;;
2561 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2562 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2563 NON_GNU_CPP=/lib/cpp
2564 # Prevent -belf from being passed to $CPP.
2565 # /lib/cpp does not accept it.
2566 OVERRIDE_CPPFLAGS=" "
2567 ;;
2568 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
55597d70
DL
2569 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2570 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
ba4481b5 2571 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2572 *-nextstep* ) opsys=nextstep ;;
2573 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2574 esac
2575 ;;
2576
2577 ## m68k Linux-based GNU system
2578 m68k-*-linux-gnu* )
2579 machine=m68k opsys=gnu-linux
2580 ;;
2581
2582 ## Mips Linux-based GNU system
cd958eb3 2583 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2584 machine=mips opsys=gnu-linux
2585 ;;
2586
2587 ## UXP/DS
2588 sparc-fujitsu-sysv4* )
2589 machine=sparc opsys=uxpds
2590 NON_GNU_CPP=/usr/ccs/lib/cpp
2591 RANLIB="ar -ts"
2592 ;;
2593
2594 ## UXP/V
2595 f301-fujitsu-uxpv4.1)
2596 machine=f301 opsys=uxpv
2597 ;;
2598
e0f712ba
AC
2599 ## Darwin / Mac OS X
2600 powerpc-apple-darwin* )
2601 machine=powermac opsys=darwin
2602 # Define CPP as follows to make autoconf work correctly.
2a75d75d 2603 CPP="${CC-cc} -E -no-cpp-precomp"
c14dc0ed
AS
2604 # Use fink packages if available.
2605 if test -d /sw/include && test -d /sw/lib; then
2606 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
2607 CPP="${CPP} ${GCC_TEST_OPTIONS}"
2608 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
2609 fi
e0f712ba
AC
2610 ;;
2611
598a2813
AS
2612 ## AMD x86-64 Linux-based GNU system
2613 x86_64-*-linux-gnu* )
24b01ec4 2614 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2615 ;;
2616
ba4481b5
DL
2617 * )
2618 unported=yes
2619 ;;
2620esac
2621
2622### If the code above didn't choose an operating system, just choose
2623### an operating system based on the configuration name. You really
2624### only want to use this when you have no idea what the right
2625### operating system is; if you know what operating systems a machine
2626### runs, it's cleaner to make it explicit in the case statement
2627### above.
2628if test x"${opsys}" = x; then
2629 case "${canonical}" in
2630 *-gnu* ) opsys=gnu ;;
2631 *-bsd4.[01] ) opsys=bsd4-1 ;;
2632 *-bsd4.2 ) opsys=bsd4-2 ;;
2633 *-bsd4.3 ) opsys=bsd4-3 ;;
2634 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2635 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2636 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2637 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2638 *-sysv4.2uw* ) opsys=unixware ;;
55597d70
DL
2639 *-sysv5uw* ) opsys=unixware ;;
2640 *-sysv5OpenUNIX* ) opsys=unixware ;;
ba4481b5
DL
2641 *-sysv4.1* | *-sysvr4.1* )
2642 NON_GNU_CPP=/usr/lib/cpp
2643 opsys=usg5-4 ;;
2644 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2645 if [ x$NON_GNU_CPP = x ]; then
2646 if [ -f /usr/ccs/lib/cpp ]; then
2647 NON_GNU_CPP=/usr/ccs/lib/cpp
2648 else
2649 NON_GNU_CPP=/lib/cpp
2650 fi
2651 fi
2652 opsys=usg5-4-2 ;;
2653 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2654 * )
2655 unported=yes
2656 ;;
2657 esac
2658fi
2659
c0d27fcc 2660
22044edf 2661
ba4481b5 2662if test $unported = yes; then
c0d27fcc 2663 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2664Check \`etc/MACHINES' for recognized configuration names." >&5
2665echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2666Check \`etc/MACHINES' for recognized configuration names." >&2;}
2667 { (exit 1); exit 1; }; }
ba4481b5
DL
2668fi
2669
2670machfile="m/${machine}.h"
2671opsysfile="s/${opsys}.h"
2672
c0d27fcc 2673
ba4481b5
DL
2674#### Choose a compiler.
2675test -n "$CC" && cc_specified=yes
2676
2677# Save the value of CFLAGS that the user specified.
2678SPECIFIED_CFLAGS="$CFLAGS"
2679
2680case ${with_gcc} in
2681 "yes" ) CC="gcc" GCC=yes ;;
2682 "no" ) : ${CC=cc} ;;
503d2be0
AS
2683 * )
2684esac
2685ac_ext=c
2686ac_cpp='$CPP $CPPFLAGS'
2687ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2688ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2689ac_compiler_gnu=$ac_cv_c_compiler_gnu
2690if test -n "$ac_tool_prefix"; then
2691 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2692set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2693echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2694echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2695if test "${ac_cv_prog_CC+set}" = set; then
2696 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2697else
2698 if test -n "$CC"; then
2699 ac_cv_prog_CC="$CC" # Let the user override the test.
2700else
c0d27fcc
MR
2701as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2702for as_dir in $PATH
2703do
2704 IFS=$as_save_IFS
2705 test -z "$as_dir" && as_dir=.
2706 for ac_exec_ext in '' $ac_executable_extensions; do
2707 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2708 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2709 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2710 break 2
2711 fi
2712done
503d2be0
AS
2713done
2714
ba4481b5
DL
2715fi
2716fi
503d2be0 2717CC=$ac_cv_prog_CC
ba4481b5 2718if test -n "$CC"; then
c0d27fcc 2719 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2720echo "${ECHO_T}$CC" >&6
2721else
c0d27fcc 2722 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2723echo "${ECHO_T}no" >&6
2724fi
2725
2726fi
2727if test -z "$ac_cv_prog_CC"; then
2728 ac_ct_CC=$CC
2729 # Extract the first word of "gcc", so it can be a program name with args.
2730set dummy gcc; ac_word=$2
c0d27fcc 2731echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2732echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2733if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2734 echo $ECHO_N "(cached) $ECHO_C" >&6
2735else
2736 if test -n "$ac_ct_CC"; then
2737 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2738else
c0d27fcc
MR
2739as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2740for as_dir in $PATH
2741do
2742 IFS=$as_save_IFS
2743 test -z "$as_dir" && as_dir=.
2744 for ac_exec_ext in '' $ac_executable_extensions; do
2745 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2746 ac_cv_prog_ac_ct_CC="gcc"
2747 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2748 break 2
2749 fi
2750done
503d2be0
AS
2751done
2752
2753fi
2754fi
2755ac_ct_CC=$ac_cv_prog_ac_ct_CC
2756if test -n "$ac_ct_CC"; then
c0d27fcc 2757 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2758echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2759else
c0d27fcc 2760 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2761echo "${ECHO_T}no" >&6
2762fi
2763
2764 CC=$ac_ct_CC
2765else
2766 CC="$ac_cv_prog_CC"
ba4481b5
DL
2767fi
2768
2769if test -z "$CC"; then
503d2be0
AS
2770 if test -n "$ac_tool_prefix"; then
2771 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2772set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2773echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2774echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2775if test "${ac_cv_prog_CC+set}" = set; then
2776 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2777else
2778 if test -n "$CC"; then
2779 ac_cv_prog_CC="$CC" # Let the user override the test.
2780else
c0d27fcc
MR
2781as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2782for as_dir in $PATH
2783do
2784 IFS=$as_save_IFS
2785 test -z "$as_dir" && as_dir=.
2786 for ac_exec_ext in '' $ac_executable_extensions; do
2787 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2788 ac_cv_prog_CC="${ac_tool_prefix}cc"
2789 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2790 break 2
2791 fi
2792done
503d2be0
AS
2793done
2794
2795fi
2796fi
2797CC=$ac_cv_prog_CC
2798if test -n "$CC"; then
c0d27fcc 2799 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2800echo "${ECHO_T}$CC" >&6
2801else
c0d27fcc 2802 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2803echo "${ECHO_T}no" >&6
2804fi
2805
2806fi
2807if test -z "$ac_cv_prog_CC"; then
2808 ac_ct_CC=$CC
2809 # Extract the first word of "cc", so it can be a program name with args.
2810set dummy cc; ac_word=$2
c0d27fcc 2811echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2813if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2814 echo $ECHO_N "(cached) $ECHO_C" >&6
2815else
2816 if test -n "$ac_ct_CC"; then
2817 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2818else
c0d27fcc
MR
2819as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2820for as_dir in $PATH
2821do
2822 IFS=$as_save_IFS
2823 test -z "$as_dir" && as_dir=.
2824 for ac_exec_ext in '' $ac_executable_extensions; do
2825 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2826 ac_cv_prog_ac_ct_CC="cc"
2827 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2828 break 2
2829 fi
2830done
503d2be0
AS
2831done
2832
2833fi
2834fi
2835ac_ct_CC=$ac_cv_prog_ac_ct_CC
2836if test -n "$ac_ct_CC"; then
c0d27fcc 2837 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2838echo "${ECHO_T}$ac_ct_CC" >&6
2839else
c0d27fcc 2840 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2841echo "${ECHO_T}no" >&6
2842fi
2843
2844 CC=$ac_ct_CC
2845else
2846 CC="$ac_cv_prog_CC"
2847fi
2848
2849fi
2850if test -z "$CC"; then
2851 # Extract the first word of "cc", so it can be a program name with args.
2852set dummy cc; ac_word=$2
c0d27fcc 2853echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2854echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2855if test "${ac_cv_prog_CC+set}" = set; then
2856 echo $ECHO_N "(cached) $ECHO_C" >&6
2857else
2858 if test -n "$CC"; then
2859 ac_cv_prog_CC="$CC" # Let the user override the test.
2860else
2861 ac_prog_rejected=no
c0d27fcc
MR
2862as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2863for as_dir in $PATH
2864do
2865 IFS=$as_save_IFS
2866 test -z "$as_dir" && as_dir=.
2867 for ac_exec_ext in '' $ac_executable_extensions; do
2868 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2869 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2870 ac_prog_rejected=yes
2871 continue
2872 fi
2873 ac_cv_prog_CC="cc"
2874 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2875 break 2
2876 fi
2877done
503d2be0
AS
2878done
2879
ba4481b5
DL
2880if test $ac_prog_rejected = yes; then
2881 # We found a bogon in the path, so make sure we never use it.
2882 set dummy $ac_cv_prog_CC
2883 shift
503d2be0 2884 if test $# != 0; then
ba4481b5
DL
2885 # We chose a different compiler from the bogus one.
2886 # However, it has the same basename, so the bogon will be chosen
2887 # first if we set CC to just the basename; use the full file name.
2888 shift
6bae0ccf 2889 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2890 fi
2891fi
2892fi
2893fi
503d2be0 2894CC=$ac_cv_prog_CC
ba4481b5 2895if test -n "$CC"; then
c0d27fcc 2896 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2897echo "${ECHO_T}$CC" >&6
ba4481b5 2898else
c0d27fcc 2899 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2900echo "${ECHO_T}no" >&6
ba4481b5
DL
2901fi
2902
503d2be0
AS
2903fi
2904if test -z "$CC"; then
2905 if test -n "$ac_tool_prefix"; then
2906 for ac_prog in cl
2907 do
2908 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2909set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2910echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2911echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2912if test "${ac_cv_prog_CC+set}" = set; then
2913 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2914else
2915 if test -n "$CC"; then
2916 ac_cv_prog_CC="$CC" # Let the user override the test.
2917else
c0d27fcc
MR
2918as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2919for as_dir in $PATH
2920do
2921 IFS=$as_save_IFS
2922 test -z "$as_dir" && as_dir=.
2923 for ac_exec_ext in '' $ac_executable_extensions; do
2924 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2925 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2926 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2927 break 2
2928 fi
2929done
503d2be0
AS
2930done
2931
c4bb2108
DL
2932fi
2933fi
503d2be0 2934CC=$ac_cv_prog_CC
c4bb2108 2935if test -n "$CC"; then
c0d27fcc 2936 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2937echo "${ECHO_T}$CC" >&6
c4bb2108 2938else
c0d27fcc 2939 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2940echo "${ECHO_T}no" >&6
2941fi
2942
2943 test -n "$CC" && break
2944 done
2945fi
2946if test -z "$CC"; then
2947 ac_ct_CC=$CC
2948 for ac_prog in cl
2949do
2950 # Extract the first word of "$ac_prog", so it can be a program name with args.
2951set dummy $ac_prog; ac_word=$2
c0d27fcc 2952echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2953echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2954if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2955 echo $ECHO_N "(cached) $ECHO_C" >&6
2956else
2957 if test -n "$ac_ct_CC"; then
2958 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2959else
c0d27fcc
MR
2960as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2961for as_dir in $PATH
2962do
2963 IFS=$as_save_IFS
2964 test -z "$as_dir" && as_dir=.
2965 for ac_exec_ext in '' $ac_executable_extensions; do
2966 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2967 ac_cv_prog_ac_ct_CC="$ac_prog"
2968 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2969 break 2
2970 fi
2971done
503d2be0
AS
2972done
2973
c4bb2108 2974fi
503d2be0
AS
2975fi
2976ac_ct_CC=$ac_cv_prog_ac_ct_CC
2977if test -n "$ac_ct_CC"; then
c0d27fcc 2978 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2979echo "${ECHO_T}$ac_ct_CC" >&6
2980else
c0d27fcc 2981 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2982echo "${ECHO_T}no" >&6
ba4481b5
DL
2983fi
2984
503d2be0
AS
2985 test -n "$ac_ct_CC" && break
2986done
ba4481b5 2987
503d2be0
AS
2988 CC=$ac_ct_CC
2989fi
2990
2991fi
ba4481b5 2992
c0d27fcc 2993
19650fd6
AS
2994test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2995See \`config.log' for more details." >&5
2996echo "$as_me: error: no acceptable C compiler found in \$PATH
2997See \`config.log' for more details." >&2;}
503d2be0 2998 { (exit 1); exit 1; }; }
c4bb2108 2999
503d2be0 3000# Provide some information about the compiler.
c0d27fcc 3001echo "$as_me:$LINENO:" \
503d2be0
AS
3002 "checking for C compiler version" >&5
3003ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 3004{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
3005 (eval $ac_compiler --version </dev/null >&5) 2>&5
3006 ac_status=$?
c0d27fcc 3007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3008 (exit $ac_status); }
c0d27fcc 3009{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
3010 (eval $ac_compiler -v </dev/null >&5) 2>&5
3011 ac_status=$?
c0d27fcc 3012 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3013 (exit $ac_status); }
c0d27fcc 3014{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
3015 (eval $ac_compiler -V </dev/null >&5) 2>&5
3016 ac_status=$?
c0d27fcc 3017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3018 (exit $ac_status); }
3019
3020cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3021/* confdefs.h. */
3022_ACEOF
3023cat confdefs.h >>conftest.$ac_ext
3024cat >>conftest.$ac_ext <<_ACEOF
3025/* end confdefs.h. */
c4bb2108 3026
503d2be0
AS
3027int
3028main ()
3029{
3030
3031 ;
3032 return 0;
3033}
3034_ACEOF
3035ac_clean_files_save=$ac_clean_files
19650fd6 3036ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
3037# Try to create an executable without -o first, disregard a.out.
3038# It will help us diagnose broken compilers, and finding out an intuition
3039# of exeext.
35996d22
AS
3040echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3041echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
503d2be0 3042ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 3043if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
3044 (eval $ac_link_default) 2>&5
3045 ac_status=$?
c0d27fcc 3046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3047 (exit $ac_status); }; then
3048 # Find the output, starting from the most likely. This scheme is
3049# not robust to junk in `.', hence go to wildcards (a.*) only as a last
3050# resort.
c0d27fcc
MR
3051
3052# Be careful to initialize this variable, since it used to be cached.
3053# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
3054ac_cv_exeext=
19650fd6
AS
3055# b.out is created by i960 compilers.
3056for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3057do
6bae0ccf 3058 test -f "$ac_file" || continue
503d2be0 3059 case $ac_file in
19650fd6 3060 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
35996d22 3061 ;;
19650fd6 3062 conftest.$ac_ext )
35996d22
AS
3063 # This is the source file.
3064 ;;
19650fd6 3065 [ab].out )
35996d22
AS
3066 # We found the default executable, but exeext='' is most
3067 # certainly right.
3068 break;;
19650fd6 3069 *.* )
35996d22
AS
3070 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3071 # FIXME: I believe we export ac_cv_exeext for Libtool,
3072 # but it would be cool to find out if it's true. Does anybody
3073 # maintain Libtool? --akim.
3074 export ac_cv_exeext
3075 break;;
19650fd6 3076 * )
35996d22 3077 break;;
503d2be0
AS
3078 esac
3079done
3080else
3081 echo "$as_me: failed program was:" >&5
19650fd6
AS
3082sed 's/^/| /' conftest.$ac_ext >&5
3083
6bae0ccf 3084{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
19650fd6 3085See \`config.log' for more details." >&5
6bae0ccf 3086echo "$as_me: error: C compiler cannot create executables
19650fd6 3087See \`config.log' for more details." >&2;}
503d2be0
AS
3088 { (exit 77); exit 77; }; }
3089fi
3090
3091ac_exeext=$ac_cv_exeext
c0d27fcc 3092echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3093echo "${ECHO_T}$ac_file" >&6
3094
3095# Check the compiler produces executables we can run. If not, either
3096# the compiler is broken, or we cross compile.
c0d27fcc 3097echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3098echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3099# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3100# If not cross compiling, check that we can run a simple program.
3101if test "$cross_compiling" != yes; then
3102 if { ac_try='./$ac_file'
c0d27fcc 3103 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3104 (eval $ac_try) 2>&5
3105 ac_status=$?
c0d27fcc 3106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3107 (exit $ac_status); }; }; then
3108 cross_compiling=no
ba4481b5 3109 else
503d2be0
AS
3110 if test "$cross_compiling" = maybe; then
3111 cross_compiling=yes
3112 else
c0d27fcc 3113 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
19650fd6
AS
3114If you meant to cross compile, use \`--host'.
3115See \`config.log' for more details." >&5
503d2be0 3116echo "$as_me: error: cannot run C compiled programs.
19650fd6
AS
3117If you meant to cross compile, use \`--host'.
3118See \`config.log' for more details." >&2;}
503d2be0
AS
3119 { (exit 1); exit 1; }; }
3120 fi
ba4481b5 3121 fi
503d2be0 3122fi
c0d27fcc 3123echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3124echo "${ECHO_T}yes" >&6
3125
19650fd6 3126rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3127ac_clean_files=$ac_clean_files_save
3128# Check the compiler produces executables we can run. If not, either
3129# the compiler is broken, or we cross compile.
c0d27fcc 3130echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3131echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3132echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3133echo "${ECHO_T}$cross_compiling" >&6
3134
c0d27fcc
MR
3135echo "$as_me:$LINENO: checking for suffix of executables" >&5
3136echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3137if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3138 (eval $ac_link) 2>&5
3139 ac_status=$?
c0d27fcc 3140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3141 (exit $ac_status); }; then
3142 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3143# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3144# work properly (i.e., refer to `conftest.exe'), while it won't with
3145# `rm'.
6bae0ccf
DL
3146for ac_file in conftest.exe conftest conftest.*; do
3147 test -f "$ac_file" || continue
503d2be0 3148 case $ac_file in
6bae0ccf 3149 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0 3150 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
35996d22
AS
3151 export ac_cv_exeext
3152 break;;
503d2be0
AS
3153 * ) break;;
3154 esac
3155done
ba4481b5 3156else
19650fd6
AS
3157 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3158See \`config.log' for more details." >&5
3159echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3160See \`config.log' for more details." >&2;}
503d2be0 3161 { (exit 1); exit 1; }; }
ba4481b5 3162fi
ba4481b5 3163
503d2be0 3164rm -f conftest$ac_cv_exeext
c0d27fcc 3165echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3166echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3167
503d2be0
AS
3168rm -f conftest.$ac_ext
3169EXEEXT=$ac_cv_exeext
3170ac_exeext=$EXEEXT
c0d27fcc
MR
3171echo "$as_me:$LINENO: checking for suffix of object files" >&5
3172echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3173if test "${ac_cv_objext+set}" = set; then
3174 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3175else
503d2be0 3176 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3177/* confdefs.h. */
3178_ACEOF
3179cat confdefs.h >>conftest.$ac_ext
3180cat >>conftest.$ac_ext <<_ACEOF
3181/* end confdefs.h. */
ba4481b5 3182
503d2be0
AS
3183int
3184main ()
3185{
ba4481b5 3186
503d2be0
AS
3187 ;
3188 return 0;
3189}
3190_ACEOF
3191rm -f conftest.o conftest.obj
c0d27fcc 3192if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3193 (eval $ac_compile) 2>&5
3194 ac_status=$?
c0d27fcc 3195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3196 (exit $ac_status); }; then
3197 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3198 case $ac_file in
6bae0ccf 3199 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3200 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3201 break;;
3202 esac
3203done
c4bb2108 3204else
503d2be0 3205 echo "$as_me: failed program was:" >&5
19650fd6
AS
3206sed 's/^/| /' conftest.$ac_ext >&5
3207
3208{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3209See \`config.log' for more details." >&5
3210echo "$as_me: error: cannot compute suffix of object files: cannot compile
3211See \`config.log' for more details." >&2;}
503d2be0 3212 { (exit 1); exit 1; }; }
c4bb2108
DL
3213fi
3214
503d2be0
AS
3215rm -f conftest.$ac_cv_objext conftest.$ac_ext
3216fi
c0d27fcc 3217echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3218echo "${ECHO_T}$ac_cv_objext" >&6
3219OBJEXT=$ac_cv_objext
3220ac_objext=$OBJEXT
c0d27fcc 3221echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3222echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3223if test "${ac_cv_c_compiler_gnu+set}" = set; then
3224 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3225else
503d2be0 3226 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3227/* confdefs.h. */
3228_ACEOF
3229cat confdefs.h >>conftest.$ac_ext
3230cat >>conftest.$ac_ext <<_ACEOF
3231/* end confdefs.h. */
503d2be0
AS
3232
3233int
3234main ()
3235{
3236#ifndef __GNUC__
3237 choke me
3238#endif
3239
3240 ;
3241 return 0;
3242}
3243_ACEOF
3244rm -f conftest.$ac_objext
c0d27fcc 3245if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3246 (eval $ac_compile) 2>conftest.er1
503d2be0 3247 ac_status=$?
35996d22
AS
3248 grep -v '^ *+' conftest.er1 >conftest.err
3249 rm -f conftest.er1
3250 cat conftest.err >&5
c0d27fcc 3251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3252 (exit $ac_status); } &&
35996d22
AS
3253 { ac_try='test -z "$ac_c_werror_flag"
3254 || test ! -s conftest.err'
3255 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3256 (eval $ac_try) 2>&5
3257 ac_status=$?
3258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3259 (exit $ac_status); }; } &&
3260 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3261 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3262 (eval $ac_try) 2>&5
3263 ac_status=$?
c0d27fcc 3264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3265 (exit $ac_status); }; }; then
3266 ac_compiler_gnu=yes
3267else
3268 echo "$as_me: failed program was:" >&5
19650fd6
AS
3269sed 's/^/| /' conftest.$ac_ext >&5
3270
503d2be0
AS
3271ac_compiler_gnu=no
3272fi
35996d22 3273rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3274ac_cv_c_compiler_gnu=$ac_compiler_gnu
3275
3276fi
c0d27fcc 3277echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3278echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3279GCC=`test $ac_compiler_gnu = yes && echo yes`
3280ac_test_CFLAGS=${CFLAGS+set}
3281ac_save_CFLAGS=$CFLAGS
3282CFLAGS="-g"
c0d27fcc 3283echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3284echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3285if test "${ac_cv_prog_cc_g+set}" = set; then
3286 echo $ECHO_N "(cached) $ECHO_C" >&6
3287else
3288 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3289/* confdefs.h. */
3290_ACEOF
3291cat confdefs.h >>conftest.$ac_ext
3292cat >>conftest.$ac_ext <<_ACEOF
3293/* end confdefs.h. */
503d2be0
AS
3294
3295int
3296main ()
3297{
3298
3299 ;
3300 return 0;
3301}
3302_ACEOF
3303rm -f conftest.$ac_objext
c0d27fcc 3304if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3305 (eval $ac_compile) 2>conftest.er1
503d2be0 3306 ac_status=$?
35996d22
AS
3307 grep -v '^ *+' conftest.er1 >conftest.err
3308 rm -f conftest.er1
3309 cat conftest.err >&5
c0d27fcc 3310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3311 (exit $ac_status); } &&
35996d22
AS
3312 { ac_try='test -z "$ac_c_werror_flag"
3313 || test ! -s conftest.err'
3314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3315 (eval $ac_try) 2>&5
3316 ac_status=$?
3317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3318 (exit $ac_status); }; } &&
3319 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3321 (eval $ac_try) 2>&5
3322 ac_status=$?
c0d27fcc 3323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3324 (exit $ac_status); }; }; then
ba4481b5
DL
3325 ac_cv_prog_cc_g=yes
3326else
503d2be0 3327 echo "$as_me: failed program was:" >&5
19650fd6
AS
3328sed 's/^/| /' conftest.$ac_ext >&5
3329
503d2be0 3330ac_cv_prog_cc_g=no
ba4481b5 3331fi
35996d22 3332rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 3333fi
c0d27fcc 3334echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3335echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3336if test "$ac_test_CFLAGS" = set; then
503d2be0 3337 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3338elif test $ac_cv_prog_cc_g = yes; then
3339 if test "$GCC" = yes; then
ba4481b5
DL
3340 CFLAGS="-g -O2"
3341 else
c4bb2108 3342 CFLAGS="-g"
ba4481b5 3343 fi
22afa6e8 3344else
c4bb2108
DL
3345 if test "$GCC" = yes; then
3346 CFLAGS="-O2"
3347 else
3348 CFLAGS=
3349 fi
ba4481b5 3350fi
6bae0ccf
DL
3351echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3352echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3353if test "${ac_cv_prog_cc_stdc+set}" = set; then
3354 echo $ECHO_N "(cached) $ECHO_C" >&6
3355else
3356 ac_cv_prog_cc_stdc=no
3357ac_save_CC=$CC
3358cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3359/* confdefs.h. */
3360_ACEOF
3361cat confdefs.h >>conftest.$ac_ext
3362cat >>conftest.$ac_ext <<_ACEOF
3363/* end confdefs.h. */
6bae0ccf
DL
3364#include <stdarg.h>
3365#include <stdio.h>
3366#include <sys/types.h>
3367#include <sys/stat.h>
3368/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3369struct buf { int x; };
3370FILE * (*rcsopen) (struct buf *, struct stat *, int);
3371static char *e (p, i)
3372 char **p;
3373 int i;
3374{
3375 return p[i];
3376}
3377static char *f (char * (*g) (char **, int), char **p, ...)
3378{
3379 char *s;
3380 va_list v;
3381 va_start (v,p);
3382 s = g (p, va_arg (v,int));
3383 va_end (v);
3384 return s;
3385}
35996d22
AS
3386
3387/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3388 function prototypes and stuff, but not '\xHH' hex character constants.
3389 These don't provoke an error unfortunately, instead are silently treated
3390 as 'x'. The following induces an error, until -std1 is added to get
3391 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3392 array size at least. It's necessary to write '\x00'==0 to get something
3393 that's true only with -std1. */
3394int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3395
6bae0ccf
DL
3396int test (int i, double x);
3397struct s1 {int (*f) (int a);};
3398struct s2 {int (*f) (double a);};
3399int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3400int argc;
3401char **argv;
3402int
3403main ()
3404{
3405return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3406 ;
3407 return 0;
3408}
3409_ACEOF
3410# Don't try gcc -ansi; that turns off useful extensions and
3411# breaks some systems' header files.
3412# AIX -qlanglvl=ansi
3413# Ultrix and OSF/1 -std1
3414# HP-UX 10.20 and later -Ae
3415# HP-UX older versions -Aa -D_HPUX_SOURCE
3416# SVR4 -Xc -D__EXTENSIONS__
3417for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3418do
3419 CC="$ac_save_CC $ac_arg"
3420 rm -f conftest.$ac_objext
3421if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3422 (eval $ac_compile) 2>conftest.er1
6bae0ccf 3423 ac_status=$?
35996d22
AS
3424 grep -v '^ *+' conftest.er1 >conftest.err
3425 rm -f conftest.er1
3426 cat conftest.err >&5
6bae0ccf
DL
3427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3428 (exit $ac_status); } &&
35996d22
AS
3429 { ac_try='test -z "$ac_c_werror_flag"
3430 || test ! -s conftest.err'
3431 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3432 (eval $ac_try) 2>&5
3433 ac_status=$?
3434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3435 (exit $ac_status); }; } &&
3436 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
3437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3438 (eval $ac_try) 2>&5
3439 ac_status=$?
3440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3441 (exit $ac_status); }; }; then
3442 ac_cv_prog_cc_stdc=$ac_arg
3443break
3444else
3445 echo "$as_me: failed program was:" >&5
19650fd6
AS
3446sed 's/^/| /' conftest.$ac_ext >&5
3447
6bae0ccf 3448fi
35996d22 3449rm -f conftest.err conftest.$ac_objext
6bae0ccf
DL
3450done
3451rm -f conftest.$ac_ext conftest.$ac_objext
3452CC=$ac_save_CC
3453
3454fi
3455
3456case "x$ac_cv_prog_cc_stdc" in
3457 x|xno)
3458 echo "$as_me:$LINENO: result: none needed" >&5
3459echo "${ECHO_T}none needed" >&6 ;;
3460 *)
3461 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3462echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3463 CC="$CC $ac_cv_prog_cc_stdc" ;;
3464esac
3465
503d2be0
AS
3466# Some people use a C++ compiler to compile C. Since we use `exit',
3467# in C++ we need to declare it. In case someone uses the same compiler
3468# for both compiling C and C++ we need to have the C++ compiler decide
3469# the declaration of exit, since it's the most demanding environment.
3470cat >conftest.$ac_ext <<_ACEOF
3471#ifndef __cplusplus
3472 choke me
3473#endif
3474_ACEOF
3475rm -f conftest.$ac_objext
c0d27fcc 3476if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3477 (eval $ac_compile) 2>conftest.er1
503d2be0 3478 ac_status=$?
35996d22
AS
3479 grep -v '^ *+' conftest.er1 >conftest.err
3480 rm -f conftest.er1
3481 cat conftest.err >&5
c0d27fcc 3482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3483 (exit $ac_status); } &&
35996d22
AS
3484 { ac_try='test -z "$ac_c_werror_flag"
3485 || test ! -s conftest.err'
3486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3487 (eval $ac_try) 2>&5
3488 ac_status=$?
3489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3490 (exit $ac_status); }; } &&
3491 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3493 (eval $ac_try) 2>&5
3494 ac_status=$?
c0d27fcc 3495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3496 (exit $ac_status); }; }; then
3497 for ac_declaration in \
35996d22 3498 '' \
503d2be0
AS
3499 'extern "C" void std::exit (int) throw (); using std::exit;' \
3500 'extern "C" void std::exit (int); using std::exit;' \
3501 'extern "C" void exit (int) throw ();' \
3502 'extern "C" void exit (int);' \
cffcede7 3503 'void exit (int);'
503d2be0
AS
3504do
3505 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3506/* confdefs.h. */
3507_ACEOF
3508cat confdefs.h >>conftest.$ac_ext
3509cat >>conftest.$ac_ext <<_ACEOF
3510/* end confdefs.h. */
57669b57 3511$ac_declaration
35996d22 3512#include <stdlib.h>
503d2be0
AS
3513int
3514main ()
3515{
3516exit (42);
3517 ;
3518 return 0;
3519}
3520_ACEOF
3521rm -f conftest.$ac_objext
c0d27fcc 3522if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3523 (eval $ac_compile) 2>conftest.er1
503d2be0 3524 ac_status=$?
35996d22
AS
3525 grep -v '^ *+' conftest.er1 >conftest.err
3526 rm -f conftest.er1
3527 cat conftest.err >&5
c0d27fcc 3528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3529 (exit $ac_status); } &&
35996d22
AS
3530 { ac_try='test -z "$ac_c_werror_flag"
3531 || test ! -s conftest.err'
3532 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3533 (eval $ac_try) 2>&5
3534 ac_status=$?
3535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3536 (exit $ac_status); }; } &&
3537 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3539 (eval $ac_try) 2>&5
3540 ac_status=$?
c0d27fcc 3541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3542 (exit $ac_status); }; }; then
3543 :
3544else
3545 echo "$as_me: failed program was:" >&5
19650fd6
AS
3546sed 's/^/| /' conftest.$ac_ext >&5
3547
503d2be0
AS
3548continue
3549fi
35996d22 3550rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 3551 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3552/* confdefs.h. */
3553_ACEOF
3554cat confdefs.h >>conftest.$ac_ext
3555cat >>conftest.$ac_ext <<_ACEOF
3556/* end confdefs.h. */
503d2be0
AS
3557$ac_declaration
3558int
3559main ()
3560{
3561exit (42);
3562 ;
3563 return 0;
3564}
3565_ACEOF
3566rm -f conftest.$ac_objext
c0d27fcc 3567if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3568 (eval $ac_compile) 2>conftest.er1
503d2be0 3569 ac_status=$?
35996d22
AS
3570 grep -v '^ *+' conftest.er1 >conftest.err
3571 rm -f conftest.er1
3572 cat conftest.err >&5
c0d27fcc 3573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3574 (exit $ac_status); } &&
35996d22
AS
3575 { ac_try='test -z "$ac_c_werror_flag"
3576 || test ! -s conftest.err'
3577 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3578 (eval $ac_try) 2>&5
3579 ac_status=$?
3580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3581 (exit $ac_status); }; } &&
3582 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3583 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3584 (eval $ac_try) 2>&5
3585 ac_status=$?
c0d27fcc 3586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3587 (exit $ac_status); }; }; then
3588 break
3589else
3590 echo "$as_me: failed program was:" >&5
19650fd6
AS
3591sed 's/^/| /' conftest.$ac_ext >&5
3592
503d2be0 3593fi
35996d22 3594rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3595done
3596rm -f conftest*
3597if test -n "$ac_declaration"; then
3598 echo '#ifdef __cplusplus' >>confdefs.h
3599 echo $ac_declaration >>confdefs.h
3600 echo '#endif' >>confdefs.h
3601fi
ba4481b5 3602
503d2be0
AS
3603else
3604 echo "$as_me: failed program was:" >&5
19650fd6
AS
3605sed 's/^/| /' conftest.$ac_ext >&5
3606
503d2be0 3607fi
35996d22 3608rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3609ac_ext=c
3610ac_cpp='$CPP $CPPFLAGS'
3611ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3612ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3613ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3614
c0d27fcc 3615
ba4481b5
DL
3616# On Suns, sometimes $CPP names a directory.
3617if test -n "$CPP" && test -d "$CPP"; then
3618 CPP=
3619fi
3620
3621#### Some systems specify a CPP to use unless we are using GCC.
3622#### Now that we know whether we are using GCC, we can decide whether
3623#### to use that one.
3624if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3625then
3626 CPP="$NON_GNU_CPP"
3627fi
3628
3629#### Some systems specify a CC to use unless we are using GCC.
3630#### Now that we know whether we are using GCC, we can decide whether
3631#### to use that one.
3632if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3633 test x$cc_specified != xyes
3634then
3635 CC="$NON_GNU_CC"
3636fi
3637
3638if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3639then
3640 CC="$CC $GCC_TEST_OPTIONS"
3641fi
3642
3643if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3644then
3645 CC="$CC $NON_GCC_TEST_OPTIONS"
3646fi
3647
6a3a24fa 3648#### Some other nice autoconf tests.
ba4481b5 3649
c0d27fcc 3650echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3651echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3652LN_S=$as_ln_s
3653if test "$LN_S" = "ln -s"; then
c0d27fcc 3654 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3655echo "${ECHO_T}yes" >&6
ba4481b5 3656else
c0d27fcc 3657 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3658echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3659fi
3660
503d2be0
AS
3661ac_ext=c
3662ac_cpp='$CPP $CPPFLAGS'
3663ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3664ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3665ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3666echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3667echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3668# On Suns, sometimes $CPP names a directory.
3669if test -n "$CPP" && test -d "$CPP"; then
3670 CPP=
3671fi
3672if test -z "$CPP"; then
503d2be0
AS
3673 if test "${ac_cv_prog_CPP+set}" = set; then
3674 echo $ECHO_N "(cached) $ECHO_C" >&6
3675else
3676 # Double quotes because CPP needs to be expanded
3677 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3678 do
3679 ac_preproc_ok=false
3680for ac_c_preproc_warn_flag in '' yes
3681do
3682 # Use a header file that comes with gcc, so configuring glibc
3683 # with a fresh cross-compiler works.
19650fd6
AS
3684 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3685 # <limits.h> exists even on freestanding compilers.
ba4481b5 3686 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3687 # not just through cpp. "Syntax error" is here to catch this case.
3688 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3689/* confdefs.h. */
3690_ACEOF
3691cat confdefs.h >>conftest.$ac_ext
3692cat >>conftest.$ac_ext <<_ACEOF
3693/* end confdefs.h. */
3694#ifdef __STDC__
3695# include <limits.h>
3696#else
3697# include <assert.h>
3698#endif
35996d22 3699 Syntax error
503d2be0 3700_ACEOF
c0d27fcc 3701if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3702 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3703 ac_status=$?
6bae0ccf 3704 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3705 rm -f conftest.er1
3706 cat conftest.err >&5
c0d27fcc 3707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3708 (exit $ac_status); } >/dev/null; then
3709 if test -s conftest.err; then
3710 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3711 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3712 else
3713 ac_cpp_err=
3714 fi
3715else
3716 ac_cpp_err=yes
3717fi
3718if test -z "$ac_cpp_err"; then
ba4481b5
DL
3719 :
3720else
503d2be0 3721 echo "$as_me: failed program was:" >&5
19650fd6
AS
3722sed 's/^/| /' conftest.$ac_ext >&5
3723
503d2be0
AS
3724 # Broken: fails on valid input.
3725continue
3726fi
3727rm -f conftest.err conftest.$ac_ext
3728
3729 # OK, works on sane cases. Now check whether non-existent headers
3730 # can be detected and how.
3731 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3732/* confdefs.h. */
3733_ACEOF
3734cat confdefs.h >>conftest.$ac_ext
3735cat >>conftest.$ac_ext <<_ACEOF
3736/* end confdefs.h. */
503d2be0
AS
3737#include <ac_nonexistent.h>
3738_ACEOF
c0d27fcc 3739if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3740 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3741 ac_status=$?
6bae0ccf 3742 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3743 rm -f conftest.er1
3744 cat conftest.err >&5
c0d27fcc 3745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3746 (exit $ac_status); } >/dev/null; then
3747 if test -s conftest.err; then
3748 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3749 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3750 else
3751 ac_cpp_err=
3752 fi
3753else
3754 ac_cpp_err=yes
3755fi
3756if test -z "$ac_cpp_err"; then
3757 # Broken: success on invalid input.
3758continue
c4bb2108 3759else
503d2be0 3760 echo "$as_me: failed program was:" >&5
19650fd6
AS
3761sed 's/^/| /' conftest.$ac_ext >&5
3762
503d2be0
AS
3763 # Passes both tests.
3764ac_preproc_ok=:
3765break
3766fi
3767rm -f conftest.err conftest.$ac_ext
3768
3769done
3770# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3771rm -f conftest.err conftest.$ac_ext
3772if $ac_preproc_ok; then
3773 break
3774fi
3775
3776 done
3777 ac_cv_prog_CPP=$CPP
3778
3779fi
3780 CPP=$ac_cv_prog_CPP
3781else
3782 ac_cv_prog_CPP=$CPP
3783fi
c0d27fcc 3784echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3785echo "${ECHO_T}$CPP" >&6
3786ac_preproc_ok=false
3787for ac_c_preproc_warn_flag in '' yes
3788do
3789 # Use a header file that comes with gcc, so configuring glibc
3790 # with a fresh cross-compiler works.
19650fd6
AS
3791 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3792 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3793 # On the NeXT, cc -E runs the code through the compiler's parser,
3794 # not just through cpp. "Syntax error" is here to catch this case.
3795 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3796/* confdefs.h. */
3797_ACEOF
3798cat confdefs.h >>conftest.$ac_ext
3799cat >>conftest.$ac_ext <<_ACEOF
3800/* end confdefs.h. */
3801#ifdef __STDC__
3802# include <limits.h>
3803#else
3804# include <assert.h>
3805#endif
35996d22 3806 Syntax error
503d2be0 3807_ACEOF
c0d27fcc 3808if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3809 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3810 ac_status=$?
6bae0ccf 3811 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3812 rm -f conftest.er1
3813 cat conftest.err >&5
c0d27fcc 3814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3815 (exit $ac_status); } >/dev/null; then
3816 if test -s conftest.err; then
3817 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3818 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3819 else
3820 ac_cpp_err=
3821 fi
3822else
3823 ac_cpp_err=yes
3824fi
3825if test -z "$ac_cpp_err"; then
ba4481b5
DL
3826 :
3827else
503d2be0 3828 echo "$as_me: failed program was:" >&5
19650fd6
AS
3829sed 's/^/| /' conftest.$ac_ext >&5
3830
503d2be0
AS
3831 # Broken: fails on valid input.
3832continue
3833fi
3834rm -f conftest.err conftest.$ac_ext
3835
3836 # OK, works on sane cases. Now check whether non-existent headers
3837 # can be detected and how.
3838 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3839/* confdefs.h. */
3840_ACEOF
3841cat confdefs.h >>conftest.$ac_ext
3842cat >>conftest.$ac_ext <<_ACEOF
3843/* end confdefs.h. */
503d2be0
AS
3844#include <ac_nonexistent.h>
3845_ACEOF
c0d27fcc 3846if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3847 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3848 ac_status=$?
6bae0ccf 3849 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3850 rm -f conftest.er1
3851 cat conftest.err >&5
c0d27fcc 3852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3853 (exit $ac_status); } >/dev/null; then
3854 if test -s conftest.err; then
3855 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3856 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3857 else
3858 ac_cpp_err=
3859 fi
3860else
3861 ac_cpp_err=yes
c4bb2108 3862fi
503d2be0
AS
3863if test -z "$ac_cpp_err"; then
3864 # Broken: success on invalid input.
3865continue
3866else
3867 echo "$as_me: failed program was:" >&5
19650fd6
AS
3868sed 's/^/| /' conftest.$ac_ext >&5
3869
503d2be0
AS
3870 # Passes both tests.
3871ac_preproc_ok=:
3872break
ba4481b5 3873fi
503d2be0
AS
3874rm -f conftest.err conftest.$ac_ext
3875
3876done
3877# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3878rm -f conftest.err conftest.$ac_ext
3879if $ac_preproc_ok; then
3880 :
ba4481b5 3881else
19650fd6
AS
3882 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3883See \`config.log' for more details." >&5
3884echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3885See \`config.log' for more details." >&2;}
503d2be0 3886 { (exit 1); exit 1; }; }
ba4481b5 3887fi
503d2be0
AS
3888
3889ac_ext=c
3890ac_cpp='$CPP $CPPFLAGS'
3891ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3892ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3893ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3894
3895# Find a good install program. We prefer a C program (faster),
3896# so one script is as good as another. But avoid the broken or
3897# incompatible versions:
3898# SysV /etc/install, /usr/sbin/install
3899# SunOS /usr/etc/install
3900# IRIX /sbin/install
3901# AIX /bin/install
503d2be0 3902# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3903# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3904# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3905# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
35996d22 3906# OS/2's system install, which has a completely different semantic
ba4481b5 3907# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3908echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3909echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3910if test -z "$INSTALL"; then
503d2be0
AS
3911if test "${ac_cv_path_install+set}" = set; then
3912 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3913else
c0d27fcc
MR
3914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3915for as_dir in $PATH
3916do
3917 IFS=$as_save_IFS
3918 test -z "$as_dir" && as_dir=.
3919 # Account for people who put trailing slashes in PATH elements.
3920case $as_dir/ in
3921 ./ | .// | /cC/* | \
3922 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
35996d22 3923 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
c0d27fcc
MR
3924 /usr/ucb/* ) ;;
3925 *)
3926 # OSF1 and SCO ODT 3.0 have their own names for install.
3927 # Don't use installbsd from OSF since it installs stuff as root
3928 # by default.
3929 for ac_prog in ginstall scoinst install; do
3930 for ac_exec_ext in '' $ac_executable_extensions; do
35996d22
AS
3931 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3932 if test $ac_prog = install &&
3933 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3934 # AIX install. It has an incompatible calling convention.
3935 :
3936 elif test $ac_prog = install &&
3937 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3938 # program-specific install script used by HP pwplus--don't use.
3939 :
3940 else
3941 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3942 break 3
3943 fi
3944 fi
ba4481b5 3945 done
c0d27fcc
MR
3946 done
3947 ;;
3948esac
3949done
3950
ba4481b5
DL
3951
3952fi
3953 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3954 INSTALL=$ac_cv_path_install
ba4481b5
DL
3955 else
3956 # As a last resort, use the slow shell script. We don't cache a
3957 # path for INSTALL within a source directory, because that will
3958 # break other packages using the cache if that directory is
3959 # removed, or if the path is relative.
503d2be0 3960 INSTALL=$ac_install_sh
ba4481b5
DL
3961 fi
3962fi
c0d27fcc 3963echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3964echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3965
3966# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3967# It thinks the first close brace ends the variable substitution.
3968test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3969
503d2be0 3970test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3971
ba4481b5
DL
3972test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3973
c0d27fcc
MR
3974if test "x$RANLIB" = x; then
3975 if test -n "$ac_tool_prefix"; then
3976 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3977set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3978echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3979echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3980if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3981 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3982else
3983 if test -n "$RANLIB"; then
3984 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3985else
c0d27fcc
MR
3986as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3987for as_dir in $PATH
3988do
3989 IFS=$as_save_IFS
3990 test -z "$as_dir" && as_dir=.
3991 for ac_exec_ext in '' $ac_executable_extensions; do
3992 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3993 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3994 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3995 break 2
3996 fi
3997done
503d2be0
AS
3998done
3999
7397acc4
DL
4000fi
4001fi
503d2be0 4002RANLIB=$ac_cv_prog_RANLIB
7397acc4 4003if test -n "$RANLIB"; then
c0d27fcc 4004 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
4005echo "${ECHO_T}$RANLIB" >&6
4006else
c0d27fcc 4007 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4008echo "${ECHO_T}no" >&6
4009fi
4010
4011fi
4012if test -z "$ac_cv_prog_RANLIB"; then
4013 ac_ct_RANLIB=$RANLIB
4014 # Extract the first word of "ranlib", so it can be a program name with args.
4015set dummy ranlib; ac_word=$2
c0d27fcc 4016echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
4017echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4018if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4019 echo $ECHO_N "(cached) $ECHO_C" >&6
4020else
4021 if test -n "$ac_ct_RANLIB"; then
4022 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4023else
c0d27fcc
MR
4024as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4025for as_dir in $PATH
4026do
4027 IFS=$as_save_IFS
4028 test -z "$as_dir" && as_dir=.
4029 for ac_exec_ext in '' $ac_executable_extensions; do
4030 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4031 ac_cv_prog_ac_ct_RANLIB="ranlib"
4032 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4033 break 2
4034 fi
4035done
503d2be0
AS
4036done
4037
4038 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4039fi
4040fi
4041ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4042if test -n "$ac_ct_RANLIB"; then
c0d27fcc 4043 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
4044echo "${ECHO_T}$ac_ct_RANLIB" >&6
4045else
c0d27fcc 4046 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4047echo "${ECHO_T}no" >&6
4048fi
4049
4050 RANLIB=$ac_ct_RANLIB
7397acc4 4051else
503d2be0 4052 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
4053fi
4054
4055fi
9e71690e
DK
4056# Extract the first word of "install-info", so it can be a program name with args.
4057set dummy install-info; ac_word=$2
4058echo "$as_me:$LINENO: checking for $ac_word" >&5
4059echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4060if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4061 echo $ECHO_N "(cached) $ECHO_C" >&6
4062else
4063 case $INSTALL_INFO in
4064 [\\/]* | ?:[\\/]*)
4065 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4066 ;;
4067 *)
4068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4069for as_dir in $PATH
4070do
4071 IFS=$as_save_IFS
4072 test -z "$as_dir" && as_dir=.
4073 for ac_exec_ext in '' $ac_executable_extensions; do
4074 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4075 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4076 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4077 break 2
4078 fi
4079done
4080done
4081
4082 ;;
4083esac
4084fi
4085INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4086
4087if test -n "$INSTALL_INFO"; then
4088 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4089echo "${ECHO_T}$INSTALL_INFO" >&6
4090else
4091 echo "$as_me:$LINENO: result: no" >&5
4092echo "${ECHO_T}no" >&6
4093fi
4094
4095# Extract the first word of "install-info", so it can be a program name with args.
4096set dummy install-info; ac_word=$2
4097echo "$as_me:$LINENO: checking for $ac_word" >&5
4098echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4099if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4100 echo $ECHO_N "(cached) $ECHO_C" >&6
4101else
4102 case $INSTALL_INFO in
4103 [\\/]* | ?:[\\/]*)
4104 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4105 ;;
4106 *)
4107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4108for as_dir in /usr/sbin
4109do
4110 IFS=$as_save_IFS
4111 test -z "$as_dir" && as_dir=.
4112 for ac_exec_ext in '' $ac_executable_extensions; do
4113 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4114 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4115 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4116 break 2
4117 fi
4118done
4119done
4120
4121 ;;
4122esac
4123fi
4124INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4125
4126if test -n "$INSTALL_INFO"; then
4127 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4128echo "${ECHO_T}$INSTALL_INFO" >&6
4129else
4130 echo "$as_me:$LINENO: result: no" >&5
4131echo "${ECHO_T}no" >&6
4132fi
4133
4134# Extract the first word of "install-info", so it can be a program name with args.
4135set dummy install-info; ac_word=$2
4136echo "$as_me:$LINENO: checking for $ac_word" >&5
4137echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4138if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4139 echo $ECHO_N "(cached) $ECHO_C" >&6
4140else
4141 case $INSTALL_INFO in
4142 [\\/]* | ?:[\\/]*)
4143 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4144 ;;
4145 *)
4146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4147for as_dir in /sbin
4148do
4149 IFS=$as_save_IFS
4150 test -z "$as_dir" && as_dir=.
4151 for ac_exec_ext in '' $ac_executable_extensions; do
4152 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4153 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4154 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4155 break 2
4156 fi
4157done
4158done
4159
4160 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4161 ;;
4162esac
4163fi
4164INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4165
4166if test -n "$INSTALL_INFO"; then
4167 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4168echo "${ECHO_T}$INSTALL_INFO" >&6
4169else
4170 echo "$as_me:$LINENO: result: no" >&5
4171echo "${ECHO_T}no" >&6
4172fi
4173
ba4481b5 4174
c0d27fcc 4175
8e967cf7
MR
4176if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4177then
4178 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4179fi
4180
4181if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4182then
4183 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4184fi
4185
c0d27fcc 4186
fe239f0f 4187late_LDFLAGS=$LDFLAGS
4af002d6 4188if test "$GCC" = yes; then
fe239f0f
AS
4189 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
4190else
4191 LDFLAGS="$LDFLAGS -znocombreloc"
4192fi
4193
4194echo "$as_me:$LINENO: checking For -znocombreloc" >&5
4195echo $ECHO_N "checking For -znocombreloc... $ECHO_C" >&6
4196
4197cat >conftest.$ac_ext <<_ACEOF
4198main(){return 0;}
4199_ACEOF
4200rm -f conftest.$ac_objext conftest$ac_exeext
4201if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4202 (eval $ac_link) 2>conftest.er1
4203 ac_status=$?
4204 grep -v '^ *+' conftest.er1 >conftest.err
4205 rm -f conftest.er1
4206 cat conftest.err >&5
4207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4208 (exit $ac_status); } &&
4209 { ac_try='test -z "$ac_c_werror_flag"
4210 || test ! -s conftest.err'
4211 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4212 (eval $ac_try) 2>&5
4213 ac_status=$?
4214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4215 (exit $ac_status); }; } &&
4216 { ac_try='test -s conftest$ac_exeext'
4217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4218 (eval $ac_try) 2>&5
4219 ac_status=$?
4220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4221 (exit $ac_status); }; }; then
4222 echo "$as_me:$LINENO: result: yes" >&5
4223echo "${ECHO_T}yes" >&6
4224else
4225 echo "$as_me: failed program was:" >&5
4226sed 's/^/| /' conftest.$ac_ext >&5
4227
4228LDFLAGS=$late_LDFLAGS
4229 echo "$as_me:$LINENO: result: no" >&5
4230echo "${ECHO_T}no" >&6
4231fi
4232rm -f conftest.err conftest.$ac_objext \
4233 conftest$ac_exeext conftest.$ac_ext
4234
c0d27fcc 4235
6bae0ccf
DL
4236echo "$as_me:$LINENO: checking for egrep" >&5
4237echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4238if test "${ac_cv_prog_egrep+set}" = set; then
4239 echo $ECHO_N "(cached) $ECHO_C" >&6
4240else
4241 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4242 then ac_cv_prog_egrep='grep -E'
4243 else ac_cv_prog_egrep='egrep'
4244 fi
4245fi
4246echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4247echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4248 EGREP=$ac_cv_prog_egrep
4249
4250
c0d27fcc
MR
4251
4252echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4253echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4254cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4255/* confdefs.h. */
4256_ACEOF
4257cat confdefs.h >>conftest.$ac_ext
4258cat >>conftest.$ac_ext <<_ACEOF
4259/* end confdefs.h. */
ba4481b5
DL
4260#ifdef _AIX
4261 yes
4262#endif
4263
503d2be0 4264_ACEOF
ba4481b5 4265if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4266 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4267 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4268echo "${ECHO_T}yes" >&6
c0d27fcc 4269cat >>confdefs.h <<\_ACEOF
ba4481b5 4270#define _ALL_SOURCE 1
c0d27fcc 4271_ACEOF
ba4481b5
DL
4272
4273else
c0d27fcc 4274 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4275echo "${ECHO_T}no" >&6
ba4481b5
DL
4276fi
4277rm -f conftest*
4278
c0d27fcc
MR
4279
4280
3b33a005
DL
4281#### Extract some information from the operating system and machine files.
4282
c0d27fcc 4283{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4284 - which libraries the lib-src programs will want, and
503d2be0
AS
4285 - whether the GNU malloc routines are usable..." >&5
4286echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4287 - which libraries the lib-src programs will want, and
503d2be0 4288 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4289
4290### First figure out CFLAGS (which we use for running the compiler here)
4291### and REAL_CFLAGS (which we use for real compilation).
4292### The two are the same except on a few systems, where they are made
4293### different to work around various lossages. For example,
4294### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4295### as implying static linking.
4296
4297### If the CFLAGS env var is specified, we use that value
4298### instead of the default.
4299
4300### It's not important that this name contain the PID; you can't run
4301### two configures in the same directory and have anything work
4302### anyway.
4303tempcname="conftest.c"
4304
4305echo '
4306#include "'${srcdir}'/src/'${opsysfile}'"
4307#include "'${srcdir}'/src/'${machfile}'"
4308#ifndef LIBS_MACHINE
4309#define LIBS_MACHINE
4310#endif
4311#ifndef LIBS_SYSTEM
4312#define LIBS_SYSTEM
4313#endif
4314#ifndef C_SWITCH_SYSTEM
4315#define C_SWITCH_SYSTEM
4316#endif
4317#ifndef C_SWITCH_MACHINE
4318#define C_SWITCH_MACHINE
4319#endif
4320configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4321configure___ c_switch_system=C_SWITCH_SYSTEM
4322configure___ c_switch_machine=C_SWITCH_MACHINE
4323
4324#ifndef LIB_X11_LIB
4325#define LIB_X11_LIB -lX11
4326#endif
4327
4328#ifndef LIBX11_MACHINE
4329#define LIBX11_MACHINE
4330#endif
4331
4332#ifndef LIBX11_SYSTEM
4333#define LIBX11_SYSTEM
4334#endif
4335configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4336
4337#ifdef UNEXEC
4338configure___ unexec=UNEXEC
4339#else
4340configure___ unexec=unexec.o
4341#endif
4342
4343#ifdef SYSTEM_MALLOC
4344configure___ system_malloc=yes
4345#else
4346configure___ system_malloc=no
4347#endif
4348
ef9e4345
GM
4349#ifdef USE_MMAP_FOR_BUFFERS
4350configure___ use_mmap_for_buffers=yes
73b77ee5 4351#else
ef9e4345 4352configure___ use_mmap_for_buffers=no
73b77ee5
GM
4353#endif
4354
3b33a005
DL
4355#ifndef C_DEBUG_SWITCH
4356#define C_DEBUG_SWITCH -g
4357#endif
4358
4359#ifndef C_OPTIMIZE_SWITCH
4360#ifdef __GNUC__
4361#define C_OPTIMIZE_SWITCH -O2
4362#else
4363#define C_OPTIMIZE_SWITCH -O
4364#endif
4365#endif
4366
4367#ifndef LD_SWITCH_MACHINE
4368#define LD_SWITCH_MACHINE
4369#endif
4370
4371#ifndef LD_SWITCH_SYSTEM
4372#define LD_SWITCH_SYSTEM
4373#endif
4374
4375#ifndef LD_SWITCH_X_SITE_AUX
4376#define LD_SWITCH_X_SITE_AUX
503d2be0 4377#endif
3b33a005
DL
4378
4379configure___ ld_switch_system=LD_SWITCH_SYSTEM
4380configure___ ld_switch_machine=LD_SWITCH_MACHINE
4381
4382#ifdef THIS_IS_CONFIGURE
4383
4384/* Get the CFLAGS for tests in configure. */
4385#ifdef __GNUC__
4386configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4387#else
4388configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4389#endif
4390
4391#else /* not THIS_IS_CONFIGURE */
4392
4393/* Get the CFLAGS for real compilation. */
4394#ifdef __GNUC__
4395configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4396#else
4397configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4398#endif
4399
4400#endif /* not THIS_IS_CONFIGURE */
4401' > ${tempcname}
4402
4403# The value of CPP is a quoted variable reference, so we need to do this
4404# to get its actual value...
4405CPP=`eval "echo $CPP"`
4406eval `${CPP} -Isrc ${tempcname} \
4407 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4408if test "x$SPECIFIED_CFLAGS" = x; then
4409 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4410 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4411else
4412 REAL_CFLAGS="$CFLAGS"
4413fi
4414rm ${tempcname}
4415
4416ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4417
4418### Make sure subsequent tests use flags consistent with the build flags.
4419
4420if test x"${OVERRIDE_CPPFLAGS}" != x; then
4421 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4422else
4423 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4424fi
4425
6bae0ccf
DL
4426
4427
22044edf
DL
4428
4429cat >>confdefs.h <<\_ACEOF
4430#define _GNU_SOURCE 1
4431_ACEOF
4432
4433
4434
503d2be0 4435# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4436if test "${enable_largefile+set}" = set; then
4437 enableval="$enable_largefile"
f4988be7 4438
503d2be0
AS
4439fi;
4440if test "$enable_largefile" != no; then
f4988be7 4441
c0d27fcc 4442 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4443echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4444if test "${ac_cv_sys_largefile_CC+set}" = set; then
4445 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4446else
f4988be7 4447 ac_cv_sys_largefile_CC=no
503d2be0
AS
4448 if test "$GCC" != yes; then
4449 ac_save_CC=$CC
4450 while :; do
4451 # IRIX 6.2 and later do not support large files by default,
4452 # so use the C compiler's -n32 option if that helps.
35996d22 4453 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4454/* confdefs.h. */
4455_ACEOF
4456cat confdefs.h >>conftest.$ac_ext
4457cat >>conftest.$ac_ext <<_ACEOF
4458/* end confdefs.h. */
f4988be7 4459#include <sys/types.h>
503d2be0
AS
4460 /* Check that off_t can represent 2**63 - 1 correctly.
4461 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4462 since some C++ compilers masquerading as C compilers
4463 incorrectly reject 9223372036854775807. */
4464#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4465 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4466 && LARGE_OFF_T % 2147483647 == 1)
4467 ? 1 : -1];
4468int
4469main ()
4470{
f4988be7 4471
503d2be0
AS
4472 ;
4473 return 0;
4474}
4475_ACEOF
4476 rm -f conftest.$ac_objext
c0d27fcc 4477if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4478 (eval $ac_compile) 2>conftest.er1
503d2be0 4479 ac_status=$?
35996d22
AS
4480 grep -v '^ *+' conftest.er1 >conftest.err
4481 rm -f conftest.er1
4482 cat conftest.err >&5
c0d27fcc 4483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4484 (exit $ac_status); } &&
35996d22
AS
4485 { ac_try='test -z "$ac_c_werror_flag"
4486 || test ! -s conftest.err'
4487 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4488 (eval $ac_try) 2>&5
4489 ac_status=$?
4490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4491 (exit $ac_status); }; } &&
4492 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4494 (eval $ac_try) 2>&5
4495 ac_status=$?
c0d27fcc 4496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4497 (exit $ac_status); }; }; then
4498 break
b192d653 4499else
503d2be0 4500 echo "$as_me: failed program was:" >&5
19650fd6
AS
4501sed 's/^/| /' conftest.$ac_ext >&5
4502
503d2be0 4503fi
35996d22 4504rm -f conftest.err conftest.$ac_objext
503d2be0
AS
4505 CC="$CC -n32"
4506 rm -f conftest.$ac_objext
c0d27fcc 4507if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4508 (eval $ac_compile) 2>conftest.er1
503d2be0 4509 ac_status=$?
35996d22
AS
4510 grep -v '^ *+' conftest.er1 >conftest.err
4511 rm -f conftest.er1
4512 cat conftest.err >&5
c0d27fcc 4513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4514 (exit $ac_status); } &&
35996d22
AS
4515 { ac_try='test -z "$ac_c_werror_flag"
4516 || test ! -s conftest.err'
4517 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4518 (eval $ac_try) 2>&5
4519 ac_status=$?
4520 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4521 (exit $ac_status); }; } &&
4522 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4523 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4524 (eval $ac_try) 2>&5
4525 ac_status=$?
c0d27fcc 4526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4527 (exit $ac_status); }; }; then
4528 ac_cv_sys_largefile_CC=' -n32'; break
4529else
4530 echo "$as_me: failed program was:" >&5
19650fd6
AS
4531sed 's/^/| /' conftest.$ac_ext >&5
4532
503d2be0 4533fi
35996d22
AS
4534rm -f conftest.err conftest.$ac_objext
4535 break
503d2be0
AS
4536 done
4537 CC=$ac_save_CC
4538 rm -f conftest.$ac_ext
4539 fi
b192d653 4540fi
c0d27fcc 4541echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4542echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4543 if test "$ac_cv_sys_largefile_CC" != no; then
4544 CC=$CC$ac_cv_sys_largefile_CC
4545 fi
b192d653 4546
c0d27fcc 4547 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4548echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4549if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4550 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4551else
503d2be0 4552 while :; do
f4988be7 4553 ac_cv_sys_file_offset_bits=no
503d2be0 4554 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4555/* confdefs.h. */
4556_ACEOF
4557cat confdefs.h >>conftest.$ac_ext
4558cat >>conftest.$ac_ext <<_ACEOF
4559/* end confdefs.h. */
f4988be7 4560#include <sys/types.h>
503d2be0
AS
4561 /* Check that off_t can represent 2**63 - 1 correctly.
4562 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4563 since some C++ compilers masquerading as C compilers
4564 incorrectly reject 9223372036854775807. */
4565#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4566 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4567 && LARGE_OFF_T % 2147483647 == 1)
4568 ? 1 : -1];
4569int
4570main ()
4571{
f4988be7 4572
503d2be0
AS
4573 ;
4574 return 0;
4575}
4576_ACEOF
4577rm -f conftest.$ac_objext
c0d27fcc 4578if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4579 (eval $ac_compile) 2>conftest.er1
503d2be0 4580 ac_status=$?
35996d22
AS
4581 grep -v '^ *+' conftest.er1 >conftest.err
4582 rm -f conftest.er1
4583 cat conftest.err >&5
c0d27fcc 4584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4585 (exit $ac_status); } &&
35996d22
AS
4586 { ac_try='test -z "$ac_c_werror_flag"
4587 || test ! -s conftest.err'
4588 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4589 (eval $ac_try) 2>&5
4590 ac_status=$?
4591 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4592 (exit $ac_status); }; } &&
4593 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4594 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4595 (eval $ac_try) 2>&5
4596 ac_status=$?
c0d27fcc 4597 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4598 (exit $ac_status); }; }; then
4599 break
f4988be7 4600else
503d2be0 4601 echo "$as_me: failed program was:" >&5
19650fd6
AS
4602sed 's/^/| /' conftest.$ac_ext >&5
4603
503d2be0 4604fi
35996d22 4605rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4606 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4607/* confdefs.h. */
4608_ACEOF
4609cat confdefs.h >>conftest.$ac_ext
4610cat >>conftest.$ac_ext <<_ACEOF
4611/* end confdefs.h. */
f4988be7
GM
4612#define _FILE_OFFSET_BITS 64
4613#include <sys/types.h>
503d2be0
AS
4614 /* Check that off_t can represent 2**63 - 1 correctly.
4615 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4616 since some C++ compilers masquerading as C compilers
4617 incorrectly reject 9223372036854775807. */
4618#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4619 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4620 && LARGE_OFF_T % 2147483647 == 1)
4621 ? 1 : -1];
4622int
4623main ()
4624{
4625
4626 ;
4627 return 0;
4628}
4629_ACEOF
4630rm -f conftest.$ac_objext
c0d27fcc 4631if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4632 (eval $ac_compile) 2>conftest.er1
503d2be0 4633 ac_status=$?
35996d22
AS
4634 grep -v '^ *+' conftest.er1 >conftest.err
4635 rm -f conftest.er1
4636 cat conftest.err >&5
c0d27fcc 4637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4638 (exit $ac_status); } &&
35996d22
AS
4639 { ac_try='test -z "$ac_c_werror_flag"
4640 || test ! -s conftest.err'
4641 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4642 (eval $ac_try) 2>&5
4643 ac_status=$?
4644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4645 (exit $ac_status); }; } &&
4646 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4647 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4648 (eval $ac_try) 2>&5
4649 ac_status=$?
c0d27fcc 4650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4651 (exit $ac_status); }; }; then
4652 ac_cv_sys_file_offset_bits=64; break
4653else
4654 echo "$as_me: failed program was:" >&5
19650fd6
AS
4655sed 's/^/| /' conftest.$ac_ext >&5
4656
503d2be0 4657fi
35996d22 4658rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4659 break
4660done
ba4481b5 4661fi
c0d27fcc 4662echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4663echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4664if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4665
c0d27fcc 4666cat >>confdefs.h <<_ACEOF
f4988be7 4667#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4668_ACEOF
f4988be7 4669
503d2be0
AS
4670fi
4671rm -f conftest*
c0d27fcc 4672 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4673echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4674if test "${ac_cv_sys_large_files+set}" = set; then
4675 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4676else
503d2be0 4677 while :; do
f4988be7 4678 ac_cv_sys_large_files=no
503d2be0 4679 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4680/* confdefs.h. */
4681_ACEOF
4682cat confdefs.h >>conftest.$ac_ext
4683cat >>conftest.$ac_ext <<_ACEOF
4684/* end confdefs.h. */
503d2be0
AS
4685#include <sys/types.h>
4686 /* Check that off_t can represent 2**63 - 1 correctly.
4687 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4688 since some C++ compilers masquerading as C compilers
4689 incorrectly reject 9223372036854775807. */
4690#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4691 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4692 && LARGE_OFF_T % 2147483647 == 1)
4693 ? 1 : -1];
4694int
4695main ()
4696{
ba4481b5 4697
503d2be0
AS
4698 ;
4699 return 0;
4700}
4701_ACEOF
4702rm -f conftest.$ac_objext
c0d27fcc 4703if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4704 (eval $ac_compile) 2>conftest.er1
503d2be0 4705 ac_status=$?
35996d22
AS
4706 grep -v '^ *+' conftest.er1 >conftest.err
4707 rm -f conftest.er1
4708 cat conftest.err >&5
c0d27fcc 4709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4710 (exit $ac_status); } &&
35996d22
AS
4711 { ac_try='test -z "$ac_c_werror_flag"
4712 || test ! -s conftest.err'
4713 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4714 (eval $ac_try) 2>&5
4715 ac_status=$?
4716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4717 (exit $ac_status); }; } &&
4718 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4720 (eval $ac_try) 2>&5
4721 ac_status=$?
c0d27fcc 4722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4723 (exit $ac_status); }; }; then
4724 break
ba4481b5 4725else
503d2be0 4726 echo "$as_me: failed program was:" >&5
19650fd6
AS
4727sed 's/^/| /' conftest.$ac_ext >&5
4728
503d2be0 4729fi
35996d22 4730rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4731 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4732/* confdefs.h. */
4733_ACEOF
4734cat confdefs.h >>conftest.$ac_ext
4735cat >>conftest.$ac_ext <<_ACEOF
4736/* end confdefs.h. */
f4988be7 4737#define _LARGE_FILES 1
503d2be0
AS
4738#include <sys/types.h>
4739 /* Check that off_t can represent 2**63 - 1 correctly.
4740 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4741 since some C++ compilers masquerading as C compilers
4742 incorrectly reject 9223372036854775807. */
4743#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4744 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4745 && LARGE_OFF_T % 2147483647 == 1)
4746 ? 1 : -1];
4747int
4748main ()
4749{
f4988be7 4750
503d2be0
AS
4751 ;
4752 return 0;
4753}
4754_ACEOF
4755rm -f conftest.$ac_objext
c0d27fcc 4756if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4757 (eval $ac_compile) 2>conftest.er1
503d2be0 4758 ac_status=$?
35996d22
AS
4759 grep -v '^ *+' conftest.er1 >conftest.err
4760 rm -f conftest.er1
4761 cat conftest.err >&5
c0d27fcc 4762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4763 (exit $ac_status); } &&
35996d22
AS
4764 { ac_try='test -z "$ac_c_werror_flag"
4765 || test ! -s conftest.err'
4766 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4767 (eval $ac_try) 2>&5
4768 ac_status=$?
4769 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4770 (exit $ac_status); }; } &&
4771 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4772 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4773 (eval $ac_try) 2>&5
4774 ac_status=$?
c0d27fcc 4775 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4776 (exit $ac_status); }; }; then
4777 ac_cv_sys_large_files=1; break
4778else
4779 echo "$as_me: failed program was:" >&5
19650fd6
AS
4780sed 's/^/| /' conftest.$ac_ext >&5
4781
503d2be0 4782fi
35996d22 4783rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4784 break
4785done
ba4481b5 4786fi
c0d27fcc 4787echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4788echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4789if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4790
c0d27fcc 4791cat >>confdefs.h <<_ACEOF
f4988be7 4792#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4793_ACEOF
ba4481b5 4794
503d2be0
AS
4795fi
4796rm -f conftest*
4797fi
ba4481b5 4798
c0d27fcc 4799
2c9dccc9
PJ
4800if test "${with_sound}" != "no"; then
4801 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4802 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4803echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4804if test "${ac_cv_header_stdc+set}" = set; then
4805 echo $ECHO_N "(cached) $ECHO_C" >&6
4806else
4807 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4808/* confdefs.h. */
4809_ACEOF
4810cat confdefs.h >>conftest.$ac_ext
4811cat >>conftest.$ac_ext <<_ACEOF
4812/* end confdefs.h. */
c0d27fcc
MR
4813#include <stdlib.h>
4814#include <stdarg.h>
4815#include <string.h>
4816#include <float.h>
98418dba 4817
19650fd6
AS
4818int
4819main ()
4820{
4821
4822 ;
4823 return 0;
4824}
c0d27fcc 4825_ACEOF
19650fd6
AS
4826rm -f conftest.$ac_objext
4827if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4828 (eval $ac_compile) 2>conftest.er1
cd958eb3 4829 ac_status=$?
35996d22
AS
4830 grep -v '^ *+' conftest.er1 >conftest.err
4831 rm -f conftest.er1
4832 cat conftest.err >&5
cd958eb3 4833 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 4834 (exit $ac_status); } &&
35996d22
AS
4835 { ac_try='test -z "$ac_c_werror_flag"
4836 || test ! -s conftest.err'
4837 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4838 (eval $ac_try) 2>&5
4839 ac_status=$?
4840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4841 (exit $ac_status); }; } &&
4842 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
4843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4844 (eval $ac_try) 2>&5
4845 ac_status=$?
4846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4847 (exit $ac_status); }; }; then
c0d27fcc
MR
4848 ac_cv_header_stdc=yes
4849else
4850 echo "$as_me: failed program was:" >&5
19650fd6
AS
4851sed 's/^/| /' conftest.$ac_ext >&5
4852
4853ac_cv_header_stdc=no
c0d27fcc 4854fi
35996d22 4855rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4856
4857if test $ac_cv_header_stdc = yes; then
4858 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4859 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4860/* confdefs.h. */
4861_ACEOF
4862cat confdefs.h >>conftest.$ac_ext
4863cat >>conftest.$ac_ext <<_ACEOF
4864/* end confdefs.h. */
c0d27fcc
MR
4865#include <string.h>
4866
4867_ACEOF
4868if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4869 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4870 :
4871else
4872 ac_cv_header_stdc=no
4873fi
4874rm -f conftest*
4875
4876fi
4877
4878if test $ac_cv_header_stdc = yes; then
4879 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4880 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4881/* confdefs.h. */
4882_ACEOF
4883cat confdefs.h >>conftest.$ac_ext
4884cat >>conftest.$ac_ext <<_ACEOF
4885/* end confdefs.h. */
c0d27fcc
MR
4886#include <stdlib.h>
4887
4888_ACEOF
4889if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4890 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4891 :
4892else
4893 ac_cv_header_stdc=no
4894fi
4895rm -f conftest*
4896
4897fi
4898
4899if test $ac_cv_header_stdc = yes; then
4900 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4901 if test "$cross_compiling" = yes; then
4902 :
4903else
4904 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4905/* confdefs.h. */
4906_ACEOF
4907cat confdefs.h >>conftest.$ac_ext
4908cat >>conftest.$ac_ext <<_ACEOF
4909/* end confdefs.h. */
c0d27fcc
MR
4910#include <ctype.h>
4911#if ((' ' & 0x0FF) == 0x020)
4912# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4913# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4914#else
19650fd6 4915# define ISLOWER(c) \
35996d22
AS
4916 (('a' <= (c) && (c) <= 'i') \
4917 || ('j' <= (c) && (c) <= 'r') \
4918 || ('s' <= (c) && (c) <= 'z'))
c0d27fcc
MR
4919# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4920#endif
4921
4922#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4923int
4924main ()
4925{
4926 int i;
4927 for (i = 0; i < 256; i++)
4928 if (XOR (islower (i), ISLOWER (i))
35996d22 4929 || toupper (i) != TOUPPER (i))
c0d27fcc
MR
4930 exit(2);
4931 exit (0);
4932}
4933_ACEOF
4934rm -f conftest$ac_exeext
4935if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4936 (eval $ac_link) 2>&5
4937 ac_status=$?
4938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4939 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4941 (eval $ac_try) 2>&5
4942 ac_status=$?
4943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4944 (exit $ac_status); }; }; then
4945 :
4946else
4947 echo "$as_me: program exited with status $ac_status" >&5
4948echo "$as_me: failed program was:" >&5
19650fd6
AS
4949sed 's/^/| /' conftest.$ac_ext >&5
4950
c0d27fcc
MR
4951( exit $ac_status )
4952ac_cv_header_stdc=no
4953fi
35996d22 4954rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4955fi
4956fi
4957fi
4958echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4959echo "${ECHO_T}$ac_cv_header_stdc" >&6
4960if test $ac_cv_header_stdc = yes; then
4961
4962cat >>confdefs.h <<\_ACEOF
4963#define STDC_HEADERS 1
4964_ACEOF
4965
4966fi
4967
4968# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
35996d22 4979 inttypes.h stdint.h unistd.h
98418dba
CW
4980do
4981as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4982echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4983echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4984if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4985 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4986else
925c2f3f 4987 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4988/* confdefs.h. */
4989_ACEOF
4990cat confdefs.h >>conftest.$ac_ext
4991cat >>conftest.$ac_ext <<_ACEOF
4992/* end confdefs.h. */
c0d27fcc
MR
4993$ac_includes_default
4994
4995#include <$ac_header>
4996_ACEOF
4997rm -f conftest.$ac_objext
4998if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4999 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5000 ac_status=$?
35996d22
AS
5001 grep -v '^ *+' conftest.er1 >conftest.err
5002 rm -f conftest.er1
5003 cat conftest.err >&5
c0d27fcc
MR
5004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5005 (exit $ac_status); } &&
35996d22
AS
5006 { ac_try='test -z "$ac_c_werror_flag"
5007 || test ! -s conftest.err'
5008 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5009 (eval $ac_try) 2>&5
5010 ac_status=$?
5011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5012 (exit $ac_status); }; } &&
5013 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5014 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5015 (eval $ac_try) 2>&5
5016 ac_status=$?
5017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5018 (exit $ac_status); }; }; then
5019 eval "$as_ac_Header=yes"
5020else
5021 echo "$as_me: failed program was:" >&5
19650fd6
AS
5022sed 's/^/| /' conftest.$ac_ext >&5
5023
c0d27fcc
MR
5024eval "$as_ac_Header=no"
5025fi
35996d22 5026rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5027fi
5028echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5029echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5030if test `eval echo '${'$as_ac_Header'}'` = yes; then
5031 cat >>confdefs.h <<_ACEOF
5032#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5033_ACEOF
5034
5035fi
5036
5037done
5038
5039
5040
5041
5042
5043for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
5044do
5045as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5046if eval "test \"\${$as_ac_Header+set}\" = set"; then
5047 echo "$as_me:$LINENO: checking for $ac_header" >&5
5048echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5049if eval "test \"\${$as_ac_Header+set}\" = set"; then
5050 echo $ECHO_N "(cached) $ECHO_C" >&6
5051fi
5052echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5053echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5054else
5055 # Is the header compilable?
5056echo "$as_me:$LINENO: checking $ac_header usability" >&5
5057echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5058cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5059/* confdefs.h. */
5060_ACEOF
5061cat confdefs.h >>conftest.$ac_ext
5062cat >>conftest.$ac_ext <<_ACEOF
5063/* end confdefs.h. */
c0d27fcc 5064$ac_includes_default
98418dba 5065#include <$ac_header>
503d2be0 5066_ACEOF
c0d27fcc
MR
5067rm -f conftest.$ac_objext
5068if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5069 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5070 ac_status=$?
35996d22
AS
5071 grep -v '^ *+' conftest.er1 >conftest.err
5072 rm -f conftest.er1
5073 cat conftest.err >&5
c0d27fcc
MR
5074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5075 (exit $ac_status); } &&
35996d22
AS
5076 { ac_try='test -z "$ac_c_werror_flag"
5077 || test ! -s conftest.err'
5078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5079 (eval $ac_try) 2>&5
5080 ac_status=$?
5081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5082 (exit $ac_status); }; } &&
5083 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5084 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5085 (eval $ac_try) 2>&5
5086 ac_status=$?
5087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5088 (exit $ac_status); }; }; then
5089 ac_header_compiler=yes
5090else
5091 echo "$as_me: failed program was:" >&5
19650fd6
AS
5092sed 's/^/| /' conftest.$ac_ext >&5
5093
c0d27fcc
MR
5094ac_header_compiler=no
5095fi
35996d22 5096rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5097echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5098echo "${ECHO_T}$ac_header_compiler" >&6
5099
5100# Is the header present?
5101echo "$as_me:$LINENO: checking $ac_header presence" >&5
5102echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5103cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5104/* confdefs.h. */
5105_ACEOF
5106cat confdefs.h >>conftest.$ac_ext
5107cat >>conftest.$ac_ext <<_ACEOF
5108/* end confdefs.h. */
c0d27fcc
MR
5109#include <$ac_header>
5110_ACEOF
5111if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5112 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5113 ac_status=$?
6bae0ccf 5114 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5115 rm -f conftest.er1
5116 cat conftest.err >&5
c0d27fcc 5117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5118 (exit $ac_status); } >/dev/null; then
5119 if test -s conftest.err; then
5120 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5121 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5122 else
5123 ac_cpp_err=
5124 fi
5125else
5126 ac_cpp_err=yes
5127fi
5128if test -z "$ac_cpp_err"; then
c0d27fcc 5129 ac_header_preproc=yes
f4988be7 5130else
503d2be0 5131 echo "$as_me: failed program was:" >&5
19650fd6
AS
5132sed 's/^/| /' conftest.$ac_ext >&5
5133
c0d27fcc 5134 ac_header_preproc=no
f4988be7 5135fi
98418dba 5136rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5137echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5138echo "${ECHO_T}$ac_header_preproc" >&6
5139
5140# So? What about this header?
35996d22
AS
5141case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5142 yes:no: )
c0d27fcc
MR
5143 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5144echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5145 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5146echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5147 ac_header_preproc=yes
19650fd6 5148 ;;
35996d22 5149 no:yes:* )
c0d27fcc
MR
5150 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5151echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5152 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5153echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5154 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5155echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5156 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5157echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5158 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5159echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5160 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5161echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5162 (
5163 cat <<\_ASBOX
35996d22
AS
5164## ------------------------------------------ ##
5165## Report this to the AC_PACKAGE_NAME lists. ##
5166## ------------------------------------------ ##
19650fd6
AS
5167_ASBOX
5168 ) |
5169 sed "s/^/$as_me: WARNING: /" >&2
5170 ;;
c0d27fcc
MR
5171esac
5172echo "$as_me:$LINENO: checking for $ac_header" >&5
5173echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5174if eval "test \"\${$as_ac_Header+set}\" = set"; then
5175 echo $ECHO_N "(cached) $ECHO_C" >&6
5176else
35996d22 5177 eval "$as_ac_Header=\$ac_header_preproc"
f4988be7 5178fi
c0d27fcc 5179echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5180echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5181
5182fi
98418dba 5183if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5184 cat >>confdefs.h <<_ACEOF
98418dba 5185#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5186_ACEOF
f4988be7
GM
5187
5188fi
c0d27fcc 5189
98418dba
CW
5190done
5191
5192 # Emulation library used on NetBSD.
c0d27fcc 5193 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
5194echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
5195if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 5196 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5197else
98418dba
CW
5198 ac_check_lib_save_LIBS=$LIBS
5199LIBS="-lossaudio $LIBS"
5200cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5201/* confdefs.h. */
5202_ACEOF
5203cat confdefs.h >>conftest.$ac_ext
5204cat >>conftest.$ac_ext <<_ACEOF
5205/* end confdefs.h. */
98418dba
CW
5206
5207/* Override any gcc2 internal prototype to avoid an error. */
5208#ifdef __cplusplus
5209extern "C"
f4988be7 5210#endif
98418dba
CW
5211/* We use char because int might match the return type of a gcc2
5212 builtin and then its argument prototype would still apply. */
5213char _oss_ioctl ();
503d2be0
AS
5214int
5215main ()
5216{
98418dba 5217_oss_ioctl ();
503d2be0
AS
5218 ;
5219 return 0;
5220}
5221_ACEOF
98418dba 5222rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 5223if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 5224 (eval $ac_link) 2>conftest.er1
503d2be0 5225 ac_status=$?
35996d22
AS
5226 grep -v '^ *+' conftest.er1 >conftest.err
5227 rm -f conftest.er1
5228 cat conftest.err >&5
c0d27fcc 5229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5230 (exit $ac_status); } &&
35996d22
AS
5231 { ac_try='test -z "$ac_c_werror_flag"
5232 || test ! -s conftest.err'
5233 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5234 (eval $ac_try) 2>&5
5235 ac_status=$?
5236 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5237 (exit $ac_status); }; } &&
5238 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 5239 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5240 (eval $ac_try) 2>&5
5241 ac_status=$?
c0d27fcc 5242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5243 (exit $ac_status); }; }; then
98418dba 5244 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 5245else
503d2be0 5246 echo "$as_me: failed program was:" >&5
19650fd6
AS
5247sed 's/^/| /' conftest.$ac_ext >&5
5248
98418dba 5249ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 5250fi
35996d22
AS
5251rm -f conftest.err conftest.$ac_objext \
5252 conftest$ac_exeext conftest.$ac_ext
98418dba 5253LIBS=$ac_check_lib_save_LIBS
f4988be7 5254fi
c0d27fcc 5255echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
5256echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5257if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5258 LIBSOUND=-lossaudio
5259else
5260 LIBSOUND=
5261fi
5262
c0d27fcc 5263
f4988be7 5264fi
c0d27fcc
MR
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
22044edf
DL
5283
5284
973a76b1 5285
cffcede7 5286
c0d27fcc 5287
f4988be7 5288
98418dba
CW
5289for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5290 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
25ca0bca 5291 termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
cffcede7 5292 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h
98418dba
CW
5293do
5294as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5295if eval "test \"\${$as_ac_Header+set}\" = set"; then
5296 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5297echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5298if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5299 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5300fi
5301echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5302echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5303else
c0d27fcc
MR
5304 # Is the header compilable?
5305echo "$as_me:$LINENO: checking $ac_header usability" >&5
5306echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5307cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5308/* confdefs.h. */
5309_ACEOF
5310cat confdefs.h >>conftest.$ac_ext
5311cat >>conftest.$ac_ext <<_ACEOF
5312/* end confdefs.h. */
c0d27fcc
MR
5313$ac_includes_default
5314#include <$ac_header>
5315_ACEOF
5316rm -f conftest.$ac_objext
5317if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5318 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5319 ac_status=$?
35996d22
AS
5320 grep -v '^ *+' conftest.er1 >conftest.err
5321 rm -f conftest.er1
5322 cat conftest.err >&5
c0d27fcc
MR
5323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5324 (exit $ac_status); } &&
35996d22
AS
5325 { ac_try='test -z "$ac_c_werror_flag"
5326 || test ! -s conftest.err'
5327 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5328 (eval $ac_try) 2>&5
5329 ac_status=$?
5330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5331 (exit $ac_status); }; } &&
5332 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5333 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5334 (eval $ac_try) 2>&5
5335 ac_status=$?
5336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5337 (exit $ac_status); }; }; then
5338 ac_header_compiler=yes
5339else
5340 echo "$as_me: failed program was:" >&5
19650fd6
AS
5341sed 's/^/| /' conftest.$ac_ext >&5
5342
c0d27fcc
MR
5343ac_header_compiler=no
5344fi
35996d22 5345rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5346echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5347echo "${ECHO_T}$ac_header_compiler" >&6
5348
5349# Is the header present?
5350echo "$as_me:$LINENO: checking $ac_header presence" >&5
5351echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5352cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5353/* confdefs.h. */
5354_ACEOF
5355cat confdefs.h >>conftest.$ac_ext
5356cat >>conftest.$ac_ext <<_ACEOF
5357/* end confdefs.h. */
98418dba 5358#include <$ac_header>
503d2be0 5359_ACEOF
c0d27fcc 5360if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5361 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5362 ac_status=$?
6bae0ccf 5363 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5364 rm -f conftest.er1
5365 cat conftest.err >&5
c0d27fcc 5366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5367 (exit $ac_status); } >/dev/null; then
5368 if test -s conftest.err; then
5369 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5370 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5371 else
5372 ac_cpp_err=
5373 fi
5374else
5375 ac_cpp_err=yes
5376fi
5377if test -z "$ac_cpp_err"; then
c0d27fcc 5378 ac_header_preproc=yes
34ec9ebe 5379else
503d2be0 5380 echo "$as_me: failed program was:" >&5
19650fd6
AS
5381sed 's/^/| /' conftest.$ac_ext >&5
5382
c0d27fcc 5383 ac_header_preproc=no
34ec9ebe 5384fi
98418dba 5385rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5386echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5387echo "${ECHO_T}$ac_header_preproc" >&6
5388
5389# So? What about this header?
35996d22
AS
5390case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5391 yes:no: )
c0d27fcc
MR
5392 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5393echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5394 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5395echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5396 ac_header_preproc=yes
19650fd6 5397 ;;
35996d22 5398 no:yes:* )
c0d27fcc
MR
5399 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5400echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5401 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5402echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5403 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5404echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5405 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5406echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5407 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5408echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5409 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5410echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5411 (
5412 cat <<\_ASBOX
35996d22
AS
5413## ------------------------------------------ ##
5414## Report this to the AC_PACKAGE_NAME lists. ##
5415## ------------------------------------------ ##
19650fd6
AS
5416_ASBOX
5417 ) |
5418 sed "s/^/$as_me: WARNING: /" >&2
5419 ;;
c0d27fcc
MR
5420esac
5421echo "$as_me:$LINENO: checking for $ac_header" >&5
5422echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5423if eval "test \"\${$as_ac_Header+set}\" = set"; then
5424 echo $ECHO_N "(cached) $ECHO_C" >&6
5425else
35996d22 5426 eval "$as_ac_Header=\$ac_header_preproc"
34ec9ebe 5427fi
c0d27fcc 5428echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5429echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5430
5431fi
98418dba 5432if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5433 cat >>confdefs.h <<_ACEOF
98418dba 5434#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5435_ACEOF
34ec9ebe 5436
98418dba 5437fi
c0d27fcc 5438
98418dba
CW
5439done
5440
22044edf
DL
5441
5442for ac_header in term.h
5443do
5444as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5445echo "$as_me:$LINENO: checking for $ac_header" >&5
5446echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5447if eval "test \"\${$as_ac_Header+set}\" = set"; then
5448 echo $ECHO_N "(cached) $ECHO_C" >&6
5449else
5450 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5451/* confdefs.h. */
5452_ACEOF
5453cat confdefs.h >>conftest.$ac_ext
5454cat >>conftest.$ac_ext <<_ACEOF
5455/* end confdefs.h. */
22044edf
DL
5456#include <$ac_header>
5457_ACEOF
5458if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5459 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5460 ac_status=$?
5461 grep -v '^ *+' conftest.er1 >conftest.err
5462 rm -f conftest.er1
5463 cat conftest.err >&5
5464 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5465 (exit $ac_status); } >/dev/null; then
5466 if test -s conftest.err; then
5467 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5468 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22044edf
DL
5469 else
5470 ac_cpp_err=
5471 fi
5472else
5473 ac_cpp_err=yes
5474fi
5475if test -z "$ac_cpp_err"; then
5476 eval "$as_ac_Header=yes"
5477else
5478 echo "$as_me: failed program was:" >&5
19650fd6
AS
5479sed 's/^/| /' conftest.$ac_ext >&5
5480
22044edf
DL
5481 eval "$as_ac_Header=no"
5482fi
5483rm -f conftest.err conftest.$ac_ext
5484fi
5485echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5486echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5487if test `eval echo '${'$as_ac_Header'}'` = yes; then
5488 cat >>confdefs.h <<_ACEOF
5489#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5490_ACEOF
5491
5492fi
5493
5494done
5495
c0d27fcc 5496echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5497echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5498if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5499 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5500else
503d2be0 5501 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5502/* confdefs.h. */
5503_ACEOF
5504cat confdefs.h >>conftest.$ac_ext
5505cat >>conftest.$ac_ext <<_ACEOF
5506/* end confdefs.h. */
98418dba
CW
5507#include <stdlib.h>
5508#include <stdarg.h>
5509#include <string.h>
5510#include <float.h>
5511
19650fd6
AS
5512int
5513main ()
5514{
5515
5516 ;
5517 return 0;
5518}
98418dba 5519_ACEOF
19650fd6
AS
5520rm -f conftest.$ac_objext
5521if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5522 (eval $ac_compile) 2>conftest.er1
cd958eb3 5523 ac_status=$?
35996d22
AS
5524 grep -v '^ *+' conftest.er1 >conftest.err
5525 rm -f conftest.er1
5526 cat conftest.err >&5
cd958eb3 5527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 5528 (exit $ac_status); } &&
35996d22
AS
5529 { ac_try='test -z "$ac_c_werror_flag"
5530 || test ! -s conftest.err'
5531 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5532 (eval $ac_try) 2>&5
5533 ac_status=$?
5534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5535 (exit $ac_status); }; } &&
5536 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
5537 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5538 (eval $ac_try) 2>&5
5539 ac_status=$?
5540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5541 (exit $ac_status); }; }; then
98418dba 5542 ac_cv_header_stdc=yes
ba4481b5 5543else
503d2be0 5544 echo "$as_me: failed program was:" >&5
19650fd6
AS
5545sed 's/^/| /' conftest.$ac_ext >&5
5546
5547ac_cv_header_stdc=no
ba4481b5 5548fi
35996d22 5549rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5550
5551if test $ac_cv_header_stdc = yes; then
5552 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5553 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5554/* confdefs.h. */
5555_ACEOF
5556cat confdefs.h >>conftest.$ac_ext
5557cat >>conftest.$ac_ext <<_ACEOF
5558/* end confdefs.h. */
98418dba
CW
5559#include <string.h>
5560
5561_ACEOF
5562if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5563 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5564 :
5565else
5566 ac_cv_header_stdc=no
ba4481b5 5567fi
98418dba 5568rm -f conftest*
ba4481b5
DL
5569
5570fi
5571
98418dba
CW
5572if test $ac_cv_header_stdc = yes; then
5573 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5574 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5575/* confdefs.h. */
5576_ACEOF
5577cat confdefs.h >>conftest.$ac_ext
5578cat >>conftest.$ac_ext <<_ACEOF
5579/* end confdefs.h. */
98418dba
CW
5580#include <stdlib.h>
5581
5582_ACEOF
5583if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5584 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5585 :
5586else
5587 ac_cv_header_stdc=no
5588fi
5589rm -f conftest*
5590
5591fi
5592
5593if test $ac_cv_header_stdc = yes; then
5594 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5595 if test "$cross_compiling" = yes; then
5596 :
d42122a3 5597else
503d2be0 5598 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5599/* confdefs.h. */
5600_ACEOF
5601cat confdefs.h >>conftest.$ac_ext
5602cat >>conftest.$ac_ext <<_ACEOF
5603/* end confdefs.h. */
98418dba
CW
5604#include <ctype.h>
5605#if ((' ' & 0x0FF) == 0x020)
5606# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5607# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5608#else
19650fd6 5609# define ISLOWER(c) \
35996d22
AS
5610 (('a' <= (c) && (c) <= 'i') \
5611 || ('j' <= (c) && (c) <= 'r') \
5612 || ('s' <= (c) && (c) <= 'z'))
98418dba
CW
5613# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5614#endif
5615
5616#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5617int
5618main ()
5619{
98418dba
CW
5620 int i;
5621 for (i = 0; i < 256; i++)
5622 if (XOR (islower (i), ISLOWER (i))
35996d22 5623 || toupper (i) != TOUPPER (i))
98418dba
CW
5624 exit(2);
5625 exit (0);
503d2be0
AS
5626}
5627_ACEOF
98418dba 5628rm -f conftest$ac_exeext
c0d27fcc 5629if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5630 (eval $ac_link) 2>&5
503d2be0 5631 ac_status=$?
c0d27fcc 5632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5633 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5634 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5635 (eval $ac_try) 2>&5
5636 ac_status=$?
c0d27fcc 5637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5638 (exit $ac_status); }; }; then
98418dba 5639 :
d42122a3 5640else
98418dba
CW
5641 echo "$as_me: program exited with status $ac_status" >&5
5642echo "$as_me: failed program was:" >&5
19650fd6
AS
5643sed 's/^/| /' conftest.$ac_ext >&5
5644
c0d27fcc 5645( exit $ac_status )
98418dba 5646ac_cv_header_stdc=no
d42122a3 5647fi
35996d22 5648rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5649fi
98418dba
CW
5650fi
5651fi
c0d27fcc 5652echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5653echo "${ECHO_T}$ac_cv_header_stdc" >&6
5654if test $ac_cv_header_stdc = yes; then
5655
c0d27fcc 5656cat >>confdefs.h <<\_ACEOF
98418dba 5657#define STDC_HEADERS 1
c0d27fcc 5658_ACEOF
d42122a3
DL
5659
5660fi
5661
c0d27fcc 5662echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5663echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5664if test "${ac_cv_header_time+set}" = set; then
503d2be0 5665 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5666else
503d2be0 5667 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5668/* confdefs.h. */
5669_ACEOF
5670cat confdefs.h >>conftest.$ac_ext
5671cat >>conftest.$ac_ext <<_ACEOF
5672/* end confdefs.h. */
ba4481b5 5673#include <sys/types.h>
98418dba 5674#include <sys/time.h>
ba4481b5 5675#include <time.h>
503d2be0
AS
5676
5677int
5678main ()
5679{
98418dba
CW
5680if ((struct tm *) 0)
5681return 0;
503d2be0
AS
5682 ;
5683 return 0;
5684}
5685_ACEOF
5686rm -f conftest.$ac_objext
c0d27fcc 5687if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5688 (eval $ac_compile) 2>conftest.er1
503d2be0 5689 ac_status=$?
35996d22
AS
5690 grep -v '^ *+' conftest.er1 >conftest.err
5691 rm -f conftest.er1
5692 cat conftest.err >&5
c0d27fcc 5693 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5694 (exit $ac_status); } &&
35996d22
AS
5695 { ac_try='test -z "$ac_c_werror_flag"
5696 || test ! -s conftest.err'
5697 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5698 (eval $ac_try) 2>&5
5699 ac_status=$?
5700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5701 (exit $ac_status); }; } &&
5702 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5703 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5704 (eval $ac_try) 2>&5
5705 ac_status=$?
c0d27fcc 5706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5707 (exit $ac_status); }; }; then
98418dba 5708 ac_cv_header_time=yes
ba4481b5 5709else
503d2be0 5710 echo "$as_me: failed program was:" >&5
19650fd6
AS
5711sed 's/^/| /' conftest.$ac_ext >&5
5712
98418dba 5713ac_cv_header_time=no
ba4481b5 5714fi
35996d22 5715rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5716fi
c0d27fcc 5717echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5718echo "${ECHO_T}$ac_cv_header_time" >&6
5719if test $ac_cv_header_time = yes; then
503d2be0 5720
c0d27fcc 5721cat >>confdefs.h <<\_ACEOF
98418dba 5722#define TIME_WITH_SYS_TIME 1
c0d27fcc 5723_ACEOF
ba4481b5
DL
5724
5725fi
5726
cd958eb3
MB
5727echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5728echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5729if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5730 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5731else
503d2be0 5732 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5733/* confdefs.h. */
5734_ACEOF
5735cat confdefs.h >>conftest.$ac_ext
5736cat >>conftest.$ac_ext <<_ACEOF
5737/* end confdefs.h. */
cd958eb3
MB
5738$ac_includes_default
5739int
5740main ()
5741{
5742#ifndef sys_siglist
5743 char *p = (char *) sys_siglist;
98418dba 5744#endif
503d2be0 5745
cd958eb3
MB
5746 ;
5747 return 0;
5748}
5749_ACEOF
5750rm -f conftest.$ac_objext
5751if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5752 (eval $ac_compile) 2>conftest.er1
cd958eb3 5753 ac_status=$?
35996d22
AS
5754 grep -v '^ *+' conftest.er1 >conftest.err
5755 rm -f conftest.er1
5756 cat conftest.err >&5
cd958eb3
MB
5757 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5758 (exit $ac_status); } &&
35996d22
AS
5759 { ac_try='test -z "$ac_c_werror_flag"
5760 || test ! -s conftest.err'
5761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5762 (eval $ac_try) 2>&5
5763 ac_status=$?
5764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5765 (exit $ac_status); }; } &&
5766 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
5767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5768 (eval $ac_try) 2>&5
5769 ac_status=$?
5770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5771 (exit $ac_status); }; }; then
5772 ac_cv_have_decl_sys_siglist=yes
5773else
5774 echo "$as_me: failed program was:" >&5
19650fd6
AS
5775sed 's/^/| /' conftest.$ac_ext >&5
5776
cd958eb3
MB
5777ac_cv_have_decl_sys_siglist=no
5778fi
35996d22 5779rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
5780fi
5781echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5782echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5783if test $ac_cv_have_decl_sys_siglist = yes; then
5784
5785cat >>confdefs.h <<_ACEOF
5786#define HAVE_DECL_SYS_SIGLIST 1
5787_ACEOF
5788
5789
5790else
5791 cat >>confdefs.h <<_ACEOF
5792#define HAVE_DECL_SYS_SIGLIST 0
5793_ACEOF
5794
5795
5796fi
5797
5798
5799if test $ac_cv_have_decl_sys_siglist != yes; then
5800 # For Tru64, at least:
5801 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5802echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5803if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5804 echo $ECHO_N "(cached) $ECHO_C" >&6
5805else
5806 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5807/* confdefs.h. */
5808_ACEOF
5809cat confdefs.h >>conftest.$ac_ext
5810cat >>conftest.$ac_ext <<_ACEOF
5811/* end confdefs.h. */
cd958eb3 5812$ac_includes_default
503d2be0
AS
5813int
5814main ()
5815{
cd958eb3
MB
5816#ifndef __sys_siglist
5817 char *p = (char *) __sys_siglist;
5818#endif
5819
503d2be0
AS
5820 ;
5821 return 0;
5822}
5823_ACEOF
5824rm -f conftest.$ac_objext
c0d27fcc 5825if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5826 (eval $ac_compile) 2>conftest.er1
503d2be0 5827 ac_status=$?
35996d22
AS
5828 grep -v '^ *+' conftest.er1 >conftest.err
5829 rm -f conftest.er1
5830 cat conftest.err >&5
c0d27fcc 5831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5832 (exit $ac_status); } &&
35996d22
AS
5833 { ac_try='test -z "$ac_c_werror_flag"
5834 || test ! -s conftest.err'
5835 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5836 (eval $ac_try) 2>&5
5837 ac_status=$?
5838 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5839 (exit $ac_status); }; } &&
5840 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5841 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5842 (eval $ac_try) 2>&5
5843 ac_status=$?
c0d27fcc 5844 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5845 (exit $ac_status); }; }; then
cd958eb3 5846 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5847else
503d2be0 5848 echo "$as_me: failed program was:" >&5
19650fd6
AS
5849sed 's/^/| /' conftest.$ac_ext >&5
5850
cd958eb3 5851ac_cv_have_decl___sys_siglist=no
ba4481b5 5852fi
35996d22 5853rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 5854fi
cd958eb3
MB
5855echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5856echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5857if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5858
cd958eb3
MB
5859cat >>confdefs.h <<_ACEOF
5860#define HAVE_DECL___SYS_SIGLIST 1
5861_ACEOF
5862
5863
5864else
5865 cat >>confdefs.h <<_ACEOF
5866#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5867_ACEOF
503d2be0 5868
cd958eb3 5869
ba4481b5
DL
5870fi
5871
cd958eb3
MB
5872
5873 if test $ac_cv_have_decl___sys_siglist = yes; then
5874
5875cat >>confdefs.h <<\_ACEOF
5876#define sys_siglist __sys_siglist
5877_ACEOF
5878
5879 fi
5880fi
c0d27fcc 5881echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5882echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5883if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5884 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5885else
503d2be0 5886 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5887/* confdefs.h. */
5888_ACEOF
5889cat confdefs.h >>conftest.$ac_ext
5890cat >>conftest.$ac_ext <<_ACEOF
5891/* end confdefs.h. */
98418dba
CW
5892#include <sys/types.h>
5893#include <sys/wait.h>
5894#ifndef WEXITSTATUS
5895# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5896#endif
5897#ifndef WIFEXITED
5898# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5899#endif
503d2be0
AS
5900
5901int
5902main ()
5903{
98418dba
CW
5904 int s;
5905 wait (&s);
5906 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5907 ;
5908 return 0;
5909}
5910_ACEOF
98418dba 5911rm -f conftest.$ac_objext
c0d27fcc 5912if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5913 (eval $ac_compile) 2>conftest.er1
503d2be0 5914 ac_status=$?
35996d22
AS
5915 grep -v '^ *+' conftest.er1 >conftest.err
5916 rm -f conftest.er1
5917 cat conftest.err >&5
c0d27fcc 5918 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5919 (exit $ac_status); } &&
35996d22
AS
5920 { ac_try='test -z "$ac_c_werror_flag"
5921 || test ! -s conftest.err'
5922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5923 (eval $ac_try) 2>&5
5924 ac_status=$?
5925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5926 (exit $ac_status); }; } &&
5927 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5928 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5929 (eval $ac_try) 2>&5
5930 ac_status=$?
c0d27fcc 5931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5932 (exit $ac_status); }; }; then
98418dba 5933 ac_cv_header_sys_wait_h=yes
ba4481b5 5934else
503d2be0 5935 echo "$as_me: failed program was:" >&5
19650fd6
AS
5936sed 's/^/| /' conftest.$ac_ext >&5
5937
98418dba 5938ac_cv_header_sys_wait_h=no
ba4481b5 5939fi
35996d22 5940rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5941fi
c0d27fcc 5942echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5943echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5944if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5945
c0d27fcc 5946cat >>confdefs.h <<\_ACEOF
98418dba 5947#define HAVE_SYS_WAIT_H 1
c0d27fcc 5948_ACEOF
ba4481b5 5949
ba4481b5
DL
5950fi
5951
c0d27fcc
MR
5952
5953echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5954echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5955if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5956 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5957else
503d2be0 5958 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5959/* confdefs.h. */
5960_ACEOF
5961cat confdefs.h >>conftest.$ac_ext
5962cat >>conftest.$ac_ext <<_ACEOF
5963/* end confdefs.h. */
98418dba
CW
5964#ifdef TIME_WITH_SYS_TIME
5965#include <sys/time.h>
5966#include <time.h>
5967#else
5968#ifdef HAVE_SYS_TIME_H
5969#include <sys/time.h>
5970#else
1113b624 5971#include <time.h>
98418dba
CW
5972#endif
5973#endif
5974#ifdef HAVE_UTIME_H
5975#include <utime.h>
5976#endif
503d2be0
AS
5977int
5978main ()
5979{
98418dba 5980static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5981 ;
5982 return 0;
5983}
5984_ACEOF
98418dba 5985rm -f conftest.$ac_objext
c0d27fcc 5986if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5987 (eval $ac_compile) 2>conftest.er1
503d2be0 5988 ac_status=$?
35996d22
AS
5989 grep -v '^ *+' conftest.er1 >conftest.err
5990 rm -f conftest.er1
5991 cat conftest.err >&5
c0d27fcc 5992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5993 (exit $ac_status); } &&
35996d22
AS
5994 { ac_try='test -z "$ac_c_werror_flag"
5995 || test ! -s conftest.err'
5996 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5997 (eval $ac_try) 2>&5
5998 ac_status=$?
5999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6000 (exit $ac_status); }; } &&
6001 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6002 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6003 (eval $ac_try) 2>&5
6004 ac_status=$?
c0d27fcc 6005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6006 (exit $ac_status); }; }; then
98418dba 6007 emacs_cv_struct_utimbuf=yes
1113b624 6008else
503d2be0 6009 echo "$as_me: failed program was:" >&5
19650fd6
AS
6010sed 's/^/| /' conftest.$ac_ext >&5
6011
98418dba 6012emacs_cv_struct_utimbuf=no
1113b624 6013fi
35996d22 6014rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1113b624 6015fi
c0d27fcc 6016echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
6017echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
6018if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 6019
c0d27fcc 6020cat >>confdefs.h <<\_ACEOF
98418dba 6021#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 6022_ACEOF
1113b624
PE
6023
6024fi
ba4481b5 6025
c0d27fcc 6026echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
6027echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
6028if test "${ac_cv_type_signal+set}" = set; then
503d2be0 6029 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6030else
98418dba 6031 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6032/* confdefs.h. */
6033_ACEOF
6034cat confdefs.h >>conftest.$ac_ext
6035cat >>conftest.$ac_ext <<_ACEOF
6036/* end confdefs.h. */
7397acc4 6037#include <sys/types.h>
98418dba
CW
6038#include <signal.h>
6039#ifdef signal
6040# undef signal
6041#endif
6042#ifdef __cplusplus
6043extern "C" void (*signal (int, void (*)(int)))(int);
6044#else
6045void (*signal ()) ();
6046#endif
6047
503d2be0
AS
6048int
6049main ()
6050{
98418dba 6051int i;
503d2be0
AS
6052 ;
6053 return 0;
6054}
6055_ACEOF
98418dba 6056rm -f conftest.$ac_objext
c0d27fcc 6057if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6058 (eval $ac_compile) 2>conftest.er1
503d2be0 6059 ac_status=$?
35996d22
AS
6060 grep -v '^ *+' conftest.er1 >conftest.err
6061 rm -f conftest.er1
6062 cat conftest.err >&5
c0d27fcc 6063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6064 (exit $ac_status); } &&
35996d22
AS
6065 { ac_try='test -z "$ac_c_werror_flag"
6066 || test ! -s conftest.err'
6067 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6068 (eval $ac_try) 2>&5
6069 ac_status=$?
6070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6071 (exit $ac_status); }; } &&
6072 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6073 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6074 (eval $ac_try) 2>&5
6075 ac_status=$?
c0d27fcc 6076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6077 (exit $ac_status); }; }; then
98418dba 6078 ac_cv_type_signal=void
503d2be0
AS
6079else
6080 echo "$as_me: failed program was:" >&5
19650fd6
AS
6081sed 's/^/| /' conftest.$ac_ext >&5
6082
98418dba 6083ac_cv_type_signal=int
503d2be0 6084fi
35996d22 6085rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6086fi
c0d27fcc 6087echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 6088echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 6089
c0d27fcc 6090cat >>confdefs.h <<_ACEOF
98418dba 6091#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
6092_ACEOF
6093
503d2be0 6094
c0d27fcc
MR
6095
6096echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
6097echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
6098if test "${emacs_cv_speed_t+set}" = set; then
6099 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6100else
98418dba 6101 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6102/* confdefs.h. */
6103_ACEOF
6104cat confdefs.h >>conftest.$ac_ext
6105cat >>conftest.$ac_ext <<_ACEOF
6106/* end confdefs.h. */
98418dba 6107#include <termios.h>
98418dba
CW
6108int
6109main ()
6110{
6111speed_t x = 1;
6112 ;
6113 return 0;
6114}
6115_ACEOF
6116rm -f conftest.$ac_objext
c0d27fcc 6117if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6118 (eval $ac_compile) 2>conftest.er1
98418dba 6119 ac_status=$?
35996d22
AS
6120 grep -v '^ *+' conftest.er1 >conftest.err
6121 rm -f conftest.er1
6122 cat conftest.err >&5
c0d27fcc 6123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6124 (exit $ac_status); } &&
35996d22
AS
6125 { ac_try='test -z "$ac_c_werror_flag"
6126 || test ! -s conftest.err'
6127 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6128 (eval $ac_try) 2>&5
6129 ac_status=$?
6130 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6131 (exit $ac_status); }; } &&
6132 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6133 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6134 (eval $ac_try) 2>&5
6135 ac_status=$?
c0d27fcc 6136 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6137 (exit $ac_status); }; }; then
6138 emacs_cv_speed_t=yes
6139else
6140 echo "$as_me: failed program was:" >&5
19650fd6
AS
6141sed 's/^/| /' conftest.$ac_ext >&5
6142
98418dba
CW
6143emacs_cv_speed_t=no
6144fi
35996d22 6145rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 6146fi
c0d27fcc 6147echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
6148echo "${ECHO_T}$emacs_cv_speed_t" >&6
6149if test $emacs_cv_speed_t = yes; then
b936fae4 6150
c0d27fcc 6151cat >>confdefs.h <<\_ACEOF
98418dba 6152#define HAVE_SPEED_T 1
c0d27fcc 6153_ACEOF
98418dba 6154
7397acc4
DL
6155fi
6156
c0d27fcc 6157echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
6158echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
6159if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 6160 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6161else
503d2be0 6162 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6163/* confdefs.h. */
6164_ACEOF
6165cat confdefs.h >>conftest.$ac_ext
6166cat >>conftest.$ac_ext <<_ACEOF
6167/* end confdefs.h. */
98418dba
CW
6168#ifdef TIME_WITH_SYS_TIME
6169#include <sys/time.h>
6170#include <time.h>
6171#else
6172#ifdef HAVE_SYS_TIME_H
6173#include <sys/time.h>
6174#else
6175#include <time.h>
6176#endif
6177#endif
503d2be0
AS
6178int
6179main ()
6180{
98418dba 6181static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
6182 ;
6183 return 0;
6184}
6185_ACEOF
6186rm -f conftest.$ac_objext
c0d27fcc 6187if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6188 (eval $ac_compile) 2>conftest.er1
503d2be0 6189 ac_status=$?
35996d22
AS
6190 grep -v '^ *+' conftest.er1 >conftest.err
6191 rm -f conftest.er1
6192 cat conftest.err >&5
c0d27fcc 6193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6194 (exit $ac_status); } &&
35996d22
AS
6195 { ac_try='test -z "$ac_c_werror_flag"
6196 || test ! -s conftest.err'
6197 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6198 (eval $ac_try) 2>&5
6199 ac_status=$?
6200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6201 (exit $ac_status); }; } &&
6202 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6204 (eval $ac_try) 2>&5
6205 ac_status=$?
c0d27fcc 6206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6207 (exit $ac_status); }; }; then
98418dba 6208 emacs_cv_struct_timeval=yes
7397acc4 6209else
503d2be0 6210 echo "$as_me: failed program was:" >&5
19650fd6
AS
6211sed 's/^/| /' conftest.$ac_ext >&5
6212
98418dba 6213emacs_cv_struct_timeval=no
7397acc4 6214fi
35996d22 6215rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6216fi
c0d27fcc 6217echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
6218echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
6219HAVE_TIMEVAL=$emacs_cv_struct_timeval
6220if test $emacs_cv_struct_timeval = yes; then
b936fae4 6221
c0d27fcc 6222cat >>confdefs.h <<\_ACEOF
98418dba 6223#define HAVE_TIMEVAL 1
c0d27fcc 6224_ACEOF
7397acc4
DL
6225
6226fi
6227
c0d27fcc 6228echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
6229echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
6230if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 6231 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6232else
503d2be0 6233 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6234/* confdefs.h. */
6235_ACEOF
6236cat confdefs.h >>conftest.$ac_ext
6237cat >>conftest.$ac_ext <<_ACEOF
6238/* end confdefs.h. */
98418dba 6239#include <math.h>
503d2be0
AS
6240int
6241main ()
6242{
98418dba 6243static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
6244 ;
6245 return 0;
ba4481b5 6246}
503d2be0
AS
6247_ACEOF
6248rm -f conftest.$ac_objext
c0d27fcc 6249if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6250 (eval $ac_compile) 2>conftest.er1
503d2be0 6251 ac_status=$?
35996d22
AS
6252 grep -v '^ *+' conftest.er1 >conftest.err
6253 rm -f conftest.er1
6254 cat conftest.err >&5
c0d27fcc 6255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6256 (exit $ac_status); } &&
35996d22
AS
6257 { ac_try='test -z "$ac_c_werror_flag"
6258 || test ! -s conftest.err'
6259 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6260 (eval $ac_try) 2>&5
6261 ac_status=$?
6262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6263 (exit $ac_status); }; } &&
6264 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6266 (eval $ac_try) 2>&5
6267 ac_status=$?
c0d27fcc 6268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6269 (exit $ac_status); }; }; then
98418dba 6270 emacs_cv_struct_exception=yes
ba4481b5 6271else
503d2be0 6272 echo "$as_me: failed program was:" >&5
19650fd6
AS
6273sed 's/^/| /' conftest.$ac_ext >&5
6274
98418dba 6275emacs_cv_struct_exception=no
ba4481b5 6276fi
35996d22 6277rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6278fi
c0d27fcc 6279echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
6280echo "${ECHO_T}$emacs_cv_struct_exception" >&6
6281HAVE_EXCEPTION=$emacs_cv_struct_exception
6282if test $emacs_cv_struct_exception != yes; then
b936fae4 6283
c0d27fcc 6284cat >>confdefs.h <<\_ACEOF
98418dba 6285#define NO_MATHERR 1
c0d27fcc 6286_ACEOF
ba4481b5
DL
6287
6288fi
6289
7862d3a8
AS
6290
6291for ac_header in sys/socket.h
6292do
6293as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6294if eval "test \"\${$as_ac_Header+set}\" = set"; then
6295 echo "$as_me:$LINENO: checking for $ac_header" >&5
6296echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6297if eval "test \"\${$as_ac_Header+set}\" = set"; then
6298 echo $ECHO_N "(cached) $ECHO_C" >&6
6299fi
6300echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6301echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6302else
6303 # Is the header compilable?
6304echo "$as_me:$LINENO: checking $ac_header usability" >&5
6305echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6306cat >conftest.$ac_ext <<_ACEOF
6307/* confdefs.h. */
6308_ACEOF
6309cat confdefs.h >>conftest.$ac_ext
6310cat >>conftest.$ac_ext <<_ACEOF
6311/* end confdefs.h. */
6312$ac_includes_default
6313#include <$ac_header>
6314_ACEOF
6315rm -f conftest.$ac_objext
6316if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6317 (eval $ac_compile) 2>conftest.er1
6318 ac_status=$?
6319 grep -v '^ *+' conftest.er1 >conftest.err
6320 rm -f conftest.er1
6321 cat conftest.err >&5
6322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6323 (exit $ac_status); } &&
6324 { ac_try='test -z "$ac_c_werror_flag"
6325 || test ! -s conftest.err'
6326 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6327 (eval $ac_try) 2>&5
6328 ac_status=$?
6329 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6330 (exit $ac_status); }; } &&
6331 { ac_try='test -s conftest.$ac_objext'
6332 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6333 (eval $ac_try) 2>&5
6334 ac_status=$?
6335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6336 (exit $ac_status); }; }; then
6337 ac_header_compiler=yes
6338else
6339 echo "$as_me: failed program was:" >&5
6340sed 's/^/| /' conftest.$ac_ext >&5
6341
6342ac_header_compiler=no
6343fi
6344rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6345echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6346echo "${ECHO_T}$ac_header_compiler" >&6
6347
6348# Is the header present?
6349echo "$as_me:$LINENO: checking $ac_header presence" >&5
6350echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6351cat >conftest.$ac_ext <<_ACEOF
6352/* confdefs.h. */
6353_ACEOF
6354cat confdefs.h >>conftest.$ac_ext
6355cat >>conftest.$ac_ext <<_ACEOF
6356/* end confdefs.h. */
6357#include <$ac_header>
6358_ACEOF
6359if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6360 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6361 ac_status=$?
6362 grep -v '^ *+' conftest.er1 >conftest.err
6363 rm -f conftest.er1
6364 cat conftest.err >&5
6365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6366 (exit $ac_status); } >/dev/null; then
6367 if test -s conftest.err; then
6368 ac_cpp_err=$ac_c_preproc_warn_flag
6369 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6370 else
6371 ac_cpp_err=
6372 fi
6373else
6374 ac_cpp_err=yes
6375fi
6376if test -z "$ac_cpp_err"; then
6377 ac_header_preproc=yes
6378else
6379 echo "$as_me: failed program was:" >&5
6380sed 's/^/| /' conftest.$ac_ext >&5
6381
6382 ac_header_preproc=no
6383fi
6384rm -f conftest.err conftest.$ac_ext
6385echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6386echo "${ECHO_T}$ac_header_preproc" >&6
6387
6388# So? What about this header?
6389case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6390 yes:no: )
6391 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6392echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6393 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6394echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6395 ac_header_preproc=yes
6396 ;;
6397 no:yes:* )
6398 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6399echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6400 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6401echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6402 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6403echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6404 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6405echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6406 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6407echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6408 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6409echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6410 (
6411 cat <<\_ASBOX
6412## ------------------------------------------ ##
6413## Report this to the AC_PACKAGE_NAME lists. ##
6414## ------------------------------------------ ##
6415_ASBOX
6416 ) |
6417 sed "s/^/$as_me: WARNING: /" >&2
6418 ;;
6419esac
6420echo "$as_me:$LINENO: checking for $ac_header" >&5
6421echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6422if eval "test \"\${$as_ac_Header+set}\" = set"; then
6423 echo $ECHO_N "(cached) $ECHO_C" >&6
6424else
6425 eval "$as_ac_Header=\$ac_header_preproc"
6426fi
6427echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6428echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6429
6430fi
6431if test `eval echo '${'$as_ac_Header'}'` = yes; then
6432 cat >>confdefs.h <<_ACEOF
6433#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6434_ACEOF
6435
6436fi
6437
6438done
6439
6440
6441for ac_header in net/if.h
6442do
6443as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6444echo "$as_me:$LINENO: checking for $ac_header" >&5
6445echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6446if eval "test \"\${$as_ac_Header+set}\" = set"; then
6447 echo $ECHO_N "(cached) $ECHO_C" >&6
6448else
6449 cat >conftest.$ac_ext <<_ACEOF
6450/* confdefs.h. */
6451_ACEOF
6452cat confdefs.h >>conftest.$ac_ext
6453cat >>conftest.$ac_ext <<_ACEOF
6454/* end confdefs.h. */
6455$ac_includes_default
6456#if HAVE_SYS_SOCKET_H
6457#include <sys/socket.h>
6458#endif
6459
6460#include <$ac_header>
6461_ACEOF
6462rm -f conftest.$ac_objext
6463if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6464 (eval $ac_compile) 2>conftest.er1
6465 ac_status=$?
6466 grep -v '^ *+' conftest.er1 >conftest.err
6467 rm -f conftest.er1
6468 cat conftest.err >&5
6469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6470 (exit $ac_status); } &&
6471 { ac_try='test -z "$ac_c_werror_flag"
6472 || test ! -s conftest.err'
6473 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6474 (eval $ac_try) 2>&5
6475 ac_status=$?
6476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6477 (exit $ac_status); }; } &&
6478 { ac_try='test -s conftest.$ac_objext'
6479 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6480 (eval $ac_try) 2>&5
6481 ac_status=$?
6482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6483 (exit $ac_status); }; }; then
6484 eval "$as_ac_Header=yes"
6485else
6486 echo "$as_me: failed program was:" >&5
6487sed 's/^/| /' conftest.$ac_ext >&5
6488
6489eval "$as_ac_Header=no"
6490fi
6491rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6492fi
6493echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6494echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6495if test `eval echo '${'$as_ac_Header'}'` = yes; then
6496 cat >>confdefs.h <<_ACEOF
6497#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6498_ACEOF
6499
6500fi
6501
6502done
6503
6504
c0d27fcc 6505echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
6506echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
6507if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 6508 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6509else
503d2be0 6510 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6511/* confdefs.h. */
6512_ACEOF
6513cat confdefs.h >>conftest.$ac_ext
6514cat >>conftest.$ac_ext <<_ACEOF
6515/* end confdefs.h. */
98418dba
CW
6516#include <sys/types.h>
6517#include <time.h>
7397acc4 6518
503d2be0
AS
6519int
6520main ()
6521{
98418dba 6522struct tm *tp; tp->tm_sec;
503d2be0
AS
6523 ;
6524 return 0;
6525}
6526_ACEOF
6527rm -f conftest.$ac_objext
c0d27fcc 6528if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6529 (eval $ac_compile) 2>conftest.er1
503d2be0 6530 ac_status=$?
35996d22
AS
6531 grep -v '^ *+' conftest.er1 >conftest.err
6532 rm -f conftest.er1
6533 cat conftest.err >&5
c0d27fcc 6534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6535 (exit $ac_status); } &&
35996d22
AS
6536 { ac_try='test -z "$ac_c_werror_flag"
6537 || test ! -s conftest.err'
c0d27fcc 6538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6539 (eval $ac_try) 2>&5
6540 ac_status=$?
c0d27fcc 6541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
6542 (exit $ac_status); }; } &&
6543 { ac_try='test -s conftest.$ac_objext'
6544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6545 (eval $ac_try) 2>&5
6546 ac_status=$?
6547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6548 (exit $ac_status); }; }; then
6549 ac_cv_struct_tm=time.h
6550else
503d2be0 6551 echo "$as_me: failed program was:" >&5
19650fd6
AS
6552sed 's/^/| /' conftest.$ac_ext >&5
6553
98418dba 6554ac_cv_struct_tm=sys/time.h
7397acc4 6555fi
35996d22 6556rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6557fi
c0d27fcc 6558echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
6559echo "${ECHO_T}$ac_cv_struct_tm" >&6
6560if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 6561
c0d27fcc 6562cat >>confdefs.h <<\_ACEOF
98418dba 6563#define TM_IN_SYS_TIME 1
c0d27fcc 6564_ACEOF
7397acc4
DL
6565
6566fi
ba4481b5 6567
c0d27fcc 6568echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
6569echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
6570if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 6571 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6572else
98418dba 6573 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6574/* confdefs.h. */
6575_ACEOF
6576cat confdefs.h >>conftest.$ac_ext
6577cat >>conftest.$ac_ext <<_ACEOF
6578/* end confdefs.h. */
98418dba
CW
6579#include <sys/types.h>
6580#include <$ac_cv_struct_tm>
ba4481b5 6581
c0d27fcc 6582
98418dba
CW
6583int
6584main ()
6585{
6586static struct tm ac_aggr;
6587if (ac_aggr.tm_zone)
6588return 0;
6589 ;
6590 return 0;
6591}
6592_ACEOF
6593rm -f conftest.$ac_objext
c0d27fcc 6594if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6595 (eval $ac_compile) 2>conftest.er1
98418dba 6596 ac_status=$?
35996d22
AS
6597 grep -v '^ *+' conftest.er1 >conftest.err
6598 rm -f conftest.er1
6599 cat conftest.err >&5
c0d27fcc 6600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6601 (exit $ac_status); } &&
35996d22
AS
6602 { ac_try='test -z "$ac_c_werror_flag"
6603 || test ! -s conftest.err'
6604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6605 (eval $ac_try) 2>&5
6606 ac_status=$?
6607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6608 (exit $ac_status); }; } &&
6609 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6610 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6611 (eval $ac_try) 2>&5
6612 ac_status=$?
c0d27fcc 6613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6614 (exit $ac_status); }; }; then
6615 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6616else
98418dba 6617 echo "$as_me: failed program was:" >&5
19650fd6
AS
6618sed 's/^/| /' conftest.$ac_ext >&5
6619
6bae0ccf 6620cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6621/* confdefs.h. */
6622_ACEOF
6623cat confdefs.h >>conftest.$ac_ext
6624cat >>conftest.$ac_ext <<_ACEOF
6625/* end confdefs.h. */
6bae0ccf
DL
6626#include <sys/types.h>
6627#include <$ac_cv_struct_tm>
6628
6629
6630int
6631main ()
6632{
6633static struct tm ac_aggr;
6634if (sizeof ac_aggr.tm_zone)
6635return 0;
6636 ;
6637 return 0;
6638}
6639_ACEOF
6640rm -f conftest.$ac_objext
6641if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6642 (eval $ac_compile) 2>conftest.er1
6bae0ccf 6643 ac_status=$?
35996d22
AS
6644 grep -v '^ *+' conftest.er1 >conftest.err
6645 rm -f conftest.er1
6646 cat conftest.err >&5
6bae0ccf
DL
6647 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6648 (exit $ac_status); } &&
35996d22
AS
6649 { ac_try='test -z "$ac_c_werror_flag"
6650 || test ! -s conftest.err'
6651 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6652 (eval $ac_try) 2>&5
6653 ac_status=$?
6654 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6655 (exit $ac_status); }; } &&
6656 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
6657 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6658 (eval $ac_try) 2>&5
6659 ac_status=$?
6660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6661 (exit $ac_status); }; }; then
6662 ac_cv_member_struct_tm_tm_zone=yes
6663else
6664 echo "$as_me: failed program was:" >&5
19650fd6
AS
6665sed 's/^/| /' conftest.$ac_ext >&5
6666
98418dba 6667ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6668fi
35996d22 6669rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6670fi
35996d22 6671rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6672fi
c0d27fcc 6673echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6674echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6675if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6676
c0d27fcc 6677cat >>confdefs.h <<_ACEOF
98418dba 6678#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6679_ACEOF
6680
ba4481b5 6681
98418dba 6682fi
ba4481b5 6683
98418dba 6684if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6685
c0d27fcc 6686cat >>confdefs.h <<\_ACEOF
98418dba 6687#define HAVE_TM_ZONE 1
c0d27fcc 6688_ACEOF
ba4481b5 6689
ba4481b5 6690else
c0d27fcc 6691 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6692echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6693if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6694 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6695else
98418dba 6696 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6697/* confdefs.h. */
6698_ACEOF
6699cat confdefs.h >>conftest.$ac_ext
6700cat >>conftest.$ac_ext <<_ACEOF
6701/* end confdefs.h. */
98418dba
CW
6702#include <time.h>
6703#ifndef tzname /* For SGI. */
6704extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6705#endif
6706
98418dba
CW
6707int
6708main ()
6709{
6710atoi(*tzname);
6711 ;
6712 return 0;
6713}
6714_ACEOF
6715rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6716if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 6717 (eval $ac_link) 2>conftest.er1
98418dba 6718 ac_status=$?
35996d22
AS
6719 grep -v '^ *+' conftest.er1 >conftest.err
6720 rm -f conftest.er1
6721 cat conftest.err >&5
c0d27fcc 6722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6723 (exit $ac_status); } &&
35996d22
AS
6724 { ac_try='test -z "$ac_c_werror_flag"
6725 || test ! -s conftest.err'
6726 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6727 (eval $ac_try) 2>&5
6728 ac_status=$?
6729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6730 (exit $ac_status); }; } &&
6731 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6732 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6733 (eval $ac_try) 2>&5
6734 ac_status=$?
c0d27fcc 6735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6736 (exit $ac_status); }; }; then
6737 ac_cv_var_tzname=yes
6738else
6739 echo "$as_me: failed program was:" >&5
19650fd6
AS
6740sed 's/^/| /' conftest.$ac_ext >&5
6741
98418dba 6742ac_cv_var_tzname=no
ba4481b5 6743fi
35996d22
AS
6744rm -f conftest.err conftest.$ac_objext \
6745 conftest$ac_exeext conftest.$ac_ext
98418dba 6746fi
c0d27fcc 6747echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6748echo "${ECHO_T}$ac_cv_var_tzname" >&6
6749 if test $ac_cv_var_tzname = yes; then
ba4481b5 6750
c0d27fcc 6751cat >>confdefs.h <<\_ACEOF
98418dba 6752#define HAVE_TZNAME 1
c0d27fcc 6753_ACEOF
503d2be0 6754
98418dba
CW
6755 fi
6756fi
503d2be0 6757
c0d27fcc 6758echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6759echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6760if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6761 echo $ECHO_N "(cached) $ECHO_C" >&6
6762else
6763 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6764/* confdefs.h. */
6765_ACEOF
6766cat confdefs.h >>conftest.$ac_ext
6767cat >>conftest.$ac_ext <<_ACEOF
6768/* end confdefs.h. */
98418dba 6769#include <time.h>
b936fae4 6770
98418dba
CW
6771int
6772main ()
6773{
b936fae4
AS
6774static struct tm ac_aggr;
6775if (ac_aggr.tm_gmtoff)
6776return 0;
98418dba
CW
6777 ;
6778 return 0;
6779}
6780_ACEOF
b936fae4 6781rm -f conftest.$ac_objext
c0d27fcc 6782if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6783 (eval $ac_compile) 2>conftest.er1
98418dba 6784 ac_status=$?
35996d22
AS
6785 grep -v '^ *+' conftest.er1 >conftest.err
6786 rm -f conftest.er1
6787 cat conftest.err >&5
c0d27fcc 6788 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6789 (exit $ac_status); } &&
35996d22
AS
6790 { ac_try='test -z "$ac_c_werror_flag"
6791 || test ! -s conftest.err'
6792 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6793 (eval $ac_try) 2>&5
6794 ac_status=$?
6795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6796 (exit $ac_status); }; } &&
6797 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6798 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6799 (eval $ac_try) 2>&5
6800 ac_status=$?
c0d27fcc 6801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6802 (exit $ac_status); }; }; then
b936fae4 6803 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6804else
6805 echo "$as_me: failed program was:" >&5
19650fd6
AS
6806sed 's/^/| /' conftest.$ac_ext >&5
6807
8799b3e4 6808cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6809/* confdefs.h. */
6810_ACEOF
6811cat confdefs.h >>conftest.$ac_ext
6812cat >>conftest.$ac_ext <<_ACEOF
6813/* end confdefs.h. */
6bae0ccf
DL
6814#include <time.h>
6815
8799b3e4
CW
6816int
6817main ()
6818{
6bae0ccf
DL
6819static struct tm ac_aggr;
6820if (sizeof ac_aggr.tm_gmtoff)
6821return 0;
8799b3e4
CW
6822 ;
6823 return 0;
6824}
6825_ACEOF
6bae0ccf 6826rm -f conftest.$ac_objext
c0d27fcc 6827if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6828 (eval $ac_compile) 2>conftest.er1
8799b3e4 6829 ac_status=$?
35996d22
AS
6830 grep -v '^ *+' conftest.er1 >conftest.err
6831 rm -f conftest.er1
6832 cat conftest.err >&5
c0d27fcc 6833 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6834 (exit $ac_status); } &&
35996d22
AS
6835 { ac_try='test -z "$ac_c_werror_flag"
6836 || test ! -s conftest.err'
6837 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6838 (eval $ac_try) 2>&5
6839 ac_status=$?
6840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6841 (exit $ac_status); }; } &&
6842 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6844 (eval $ac_try) 2>&5
6845 ac_status=$?
c0d27fcc 6846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6847 (exit $ac_status); }; }; then
6bae0ccf 6848 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6849else
6850 echo "$as_me: failed program was:" >&5
19650fd6
AS
6851sed 's/^/| /' conftest.$ac_ext >&5
6852
6bae0ccf 6853ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6854fi
35996d22 6855rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6856fi
35996d22 6857rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8799b3e4 6858fi
6bae0ccf
DL
6859echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6860echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6861if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6862
6863cat >>confdefs.h <<\_ACEOF
6864#define HAVE_TM_GMTOFF 1
6865_ACEOF
6866
6867fi
6868
96f3a036
DL
6869echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
6870echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6
6871if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
6872 echo $ECHO_N "(cached) $ECHO_C" >&6
6873else
6874 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6875/* confdefs.h. */
6876_ACEOF
6877cat confdefs.h >>conftest.$ac_ext
6878cat >>conftest.$ac_ext <<_ACEOF
6879/* end confdefs.h. */
7862d3a8
AS
6880$ac_includes_default
6881#if HAVE_SYS_SOCKET_H
6882#include <sys/socket.h>
6883#endif
6884#if HAVE_NET_IF_H
96f3a036 6885#include <net/if.h>
7862d3a8 6886#endif
96f3a036
DL
6887
6888int
6889main ()
6890{
6891static struct ifreq ac_aggr;
6892if (ac_aggr.ifr_flags)
6893return 0;
6894 ;
6895 return 0;
6896}
6897_ACEOF
6898rm -f conftest.$ac_objext
6899if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6900 (eval $ac_compile) 2>conftest.er1
96f3a036 6901 ac_status=$?
35996d22
AS
6902 grep -v '^ *+' conftest.er1 >conftest.err
6903 rm -f conftest.er1
6904 cat conftest.err >&5
96f3a036
DL
6905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6906 (exit $ac_status); } &&
35996d22
AS
6907 { ac_try='test -z "$ac_c_werror_flag"
6908 || test ! -s conftest.err'
6909 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6910 (eval $ac_try) 2>&5
6911 ac_status=$?
6912 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6913 (exit $ac_status); }; } &&
6914 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6915 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6916 (eval $ac_try) 2>&5
6917 ac_status=$?
6918 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6919 (exit $ac_status); }; }; then
6920 ac_cv_member_struct_ifreq_ifr_flags=yes
6921else
6922 echo "$as_me: failed program was:" >&5
6923sed 's/^/| /' conftest.$ac_ext >&5
6924
6925cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6926/* confdefs.h. */
6927_ACEOF
6928cat confdefs.h >>conftest.$ac_ext
6929cat >>conftest.$ac_ext <<_ACEOF
6930/* end confdefs.h. */
7862d3a8
AS
6931$ac_includes_default
6932#if HAVE_SYS_SOCKET_H
6933#include <sys/socket.h>
6934#endif
6935#if HAVE_NET_IF_H
96f3a036 6936#include <net/if.h>
7862d3a8 6937#endif
96f3a036
DL
6938
6939int
6940main ()
6941{
6942static struct ifreq ac_aggr;
6943if (sizeof ac_aggr.ifr_flags)
6944return 0;
6945 ;
6946 return 0;
6947}
6948_ACEOF
6949rm -f conftest.$ac_objext
6950if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6951 (eval $ac_compile) 2>conftest.er1
96f3a036 6952 ac_status=$?
35996d22
AS
6953 grep -v '^ *+' conftest.er1 >conftest.err
6954 rm -f conftest.er1
6955 cat conftest.err >&5
96f3a036
DL
6956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6957 (exit $ac_status); } &&
35996d22
AS
6958 { ac_try='test -z "$ac_c_werror_flag"
6959 || test ! -s conftest.err'
6960 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6961 (eval $ac_try) 2>&5
6962 ac_status=$?
6963 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6964 (exit $ac_status); }; } &&
6965 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6966 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6967 (eval $ac_try) 2>&5
6968 ac_status=$?
6969 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6970 (exit $ac_status); }; }; then
6971 ac_cv_member_struct_ifreq_ifr_flags=yes
6972else
6973 echo "$as_me: failed program was:" >&5
6974sed 's/^/| /' conftest.$ac_ext >&5
6975
6976ac_cv_member_struct_ifreq_ifr_flags=no
6977fi
35996d22 6978rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 6979fi
35996d22 6980rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6981fi
6982echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
6983echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6
6984if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
6985
6986cat >>confdefs.h <<_ACEOF
6987#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6988_ACEOF
6989
6990
6991fi
6992echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
6993echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
6994if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
6995 echo $ECHO_N "(cached) $ECHO_C" >&6
6996else
6997 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6998/* confdefs.h. */
6999_ACEOF
7000cat confdefs.h >>conftest.$ac_ext
7001cat >>conftest.$ac_ext <<_ACEOF
7002/* end confdefs.h. */
7862d3a8
AS
7003$ac_includes_default
7004#if HAVE_SYS_SOCKET_H
7005#include <sys/socket.h>
7006#endif
7007#if HAVE_NET_IF_H
96f3a036 7008#include <net/if.h>
7862d3a8 7009#endif
96f3a036
DL
7010
7011int
7012main ()
7013{
7014static struct ifreq ac_aggr;
7015if (ac_aggr.ifr_hwaddr)
7016return 0;
7017 ;
7018 return 0;
7019}
7020_ACEOF
7021rm -f conftest.$ac_objext
7022if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7023 (eval $ac_compile) 2>conftest.er1
96f3a036 7024 ac_status=$?
35996d22
AS
7025 grep -v '^ *+' conftest.er1 >conftest.err
7026 rm -f conftest.er1
7027 cat conftest.err >&5
96f3a036
DL
7028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7029 (exit $ac_status); } &&
35996d22
AS
7030 { ac_try='test -z "$ac_c_werror_flag"
7031 || test ! -s conftest.err'
7032 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7033 (eval $ac_try) 2>&5
7034 ac_status=$?
7035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7036 (exit $ac_status); }; } &&
7037 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7038 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7039 (eval $ac_try) 2>&5
7040 ac_status=$?
7041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7042 (exit $ac_status); }; }; then
7043 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7044else
7045 echo "$as_me: failed program was:" >&5
7046sed 's/^/| /' conftest.$ac_ext >&5
7047
7048cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7049/* confdefs.h. */
7050_ACEOF
7051cat confdefs.h >>conftest.$ac_ext
7052cat >>conftest.$ac_ext <<_ACEOF
7053/* end confdefs.h. */
7862d3a8
AS
7054$ac_includes_default
7055#if HAVE_SYS_SOCKET_H
7056#include <sys/socket.h>
7057#endif
7058#if HAVE_NET_IF_H
96f3a036 7059#include <net/if.h>
7862d3a8 7060#endif
96f3a036
DL
7061
7062int
7063main ()
7064{
7065static struct ifreq ac_aggr;
7066if (sizeof ac_aggr.ifr_hwaddr)
7067return 0;
7068 ;
7069 return 0;
7070}
7071_ACEOF
7072rm -f conftest.$ac_objext
7073if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7074 (eval $ac_compile) 2>conftest.er1
96f3a036 7075 ac_status=$?
35996d22
AS
7076 grep -v '^ *+' conftest.er1 >conftest.err
7077 rm -f conftest.er1
7078 cat conftest.err >&5
96f3a036
DL
7079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7080 (exit $ac_status); } &&
35996d22
AS
7081 { ac_try='test -z "$ac_c_werror_flag"
7082 || test ! -s conftest.err'
7083 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7084 (eval $ac_try) 2>&5
7085 ac_status=$?
7086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7087 (exit $ac_status); }; } &&
7088 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7089 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7090 (eval $ac_try) 2>&5
7091 ac_status=$?
7092 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7093 (exit $ac_status); }; }; then
7094 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7095else
7096 echo "$as_me: failed program was:" >&5
7097sed 's/^/| /' conftest.$ac_ext >&5
7098
7099ac_cv_member_struct_ifreq_ifr_hwaddr=no
7100fi
35996d22 7101rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7102fi
35996d22 7103rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7104fi
7105echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
7106echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
7107if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
7108
7109cat >>confdefs.h <<_ACEOF
7110#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
7111_ACEOF
7112
7113
7114fi
7115echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
7116echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6
7117if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
7118 echo $ECHO_N "(cached) $ECHO_C" >&6
7119else
7120 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7121/* confdefs.h. */
7122_ACEOF
7123cat confdefs.h >>conftest.$ac_ext
7124cat >>conftest.$ac_ext <<_ACEOF
7125/* end confdefs.h. */
7862d3a8
AS
7126$ac_includes_default
7127#if HAVE_SYS_SOCKET_H
7128#include <sys/socket.h>
7129#endif
7130#if HAVE_NET_IF_H
96f3a036 7131#include <net/if.h>
7862d3a8 7132#endif
96f3a036
DL
7133
7134int
7135main ()
7136{
7137static struct ifreq ac_aggr;
7138if (ac_aggr.ifr_netmask)
7139return 0;
7140 ;
7141 return 0;
7142}
7143_ACEOF
7144rm -f conftest.$ac_objext
7145if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7146 (eval $ac_compile) 2>conftest.er1
96f3a036 7147 ac_status=$?
35996d22
AS
7148 grep -v '^ *+' conftest.er1 >conftest.err
7149 rm -f conftest.er1
7150 cat conftest.err >&5
96f3a036
DL
7151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7152 (exit $ac_status); } &&
35996d22
AS
7153 { ac_try='test -z "$ac_c_werror_flag"
7154 || test ! -s conftest.err'
7155 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7156 (eval $ac_try) 2>&5
7157 ac_status=$?
7158 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7159 (exit $ac_status); }; } &&
7160 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7161 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7162 (eval $ac_try) 2>&5
7163 ac_status=$?
7164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7165 (exit $ac_status); }; }; then
7166 ac_cv_member_struct_ifreq_ifr_netmask=yes
7167else
7168 echo "$as_me: failed program was:" >&5
7169sed 's/^/| /' conftest.$ac_ext >&5
7170
7171cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7172/* confdefs.h. */
7173_ACEOF
7174cat confdefs.h >>conftest.$ac_ext
7175cat >>conftest.$ac_ext <<_ACEOF
7176/* end confdefs.h. */
7862d3a8
AS
7177$ac_includes_default
7178#if HAVE_SYS_SOCKET_H
7179#include <sys/socket.h>
7180#endif
7181#if HAVE_NET_IF_H
96f3a036 7182#include <net/if.h>
7862d3a8 7183#endif
96f3a036
DL
7184
7185int
7186main ()
7187{
7188static struct ifreq ac_aggr;
7189if (sizeof ac_aggr.ifr_netmask)
7190return 0;
7191 ;
7192 return 0;
7193}
7194_ACEOF
7195rm -f conftest.$ac_objext
7196if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7197 (eval $ac_compile) 2>conftest.er1
96f3a036 7198 ac_status=$?
35996d22
AS
7199 grep -v '^ *+' conftest.er1 >conftest.err
7200 rm -f conftest.er1
7201 cat conftest.err >&5
96f3a036
DL
7202 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7203 (exit $ac_status); } &&
35996d22
AS
7204 { ac_try='test -z "$ac_c_werror_flag"
7205 || test ! -s conftest.err'
7206 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7207 (eval $ac_try) 2>&5
7208 ac_status=$?
7209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7210 (exit $ac_status); }; } &&
7211 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7213 (eval $ac_try) 2>&5
7214 ac_status=$?
7215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7216 (exit $ac_status); }; }; then
7217 ac_cv_member_struct_ifreq_ifr_netmask=yes
7218else
7219 echo "$as_me: failed program was:" >&5
7220sed 's/^/| /' conftest.$ac_ext >&5
7221
7222ac_cv_member_struct_ifreq_ifr_netmask=no
7223fi
35996d22 7224rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7225fi
35996d22 7226rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7227fi
7228echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
7229echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6
7230if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
7231
7232cat >>confdefs.h <<_ACEOF
7233#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
7234_ACEOF
7235
7236
7237fi
7238echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
7239echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6
7240if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
7241 echo $ECHO_N "(cached) $ECHO_C" >&6
7242else
7243 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7244/* confdefs.h. */
7245_ACEOF
7246cat confdefs.h >>conftest.$ac_ext
7247cat >>conftest.$ac_ext <<_ACEOF
7248/* end confdefs.h. */
7862d3a8
AS
7249$ac_includes_default
7250#if HAVE_SYS_SOCKET_H
7251#include <sys/socket.h>
7252#endif
7253#if HAVE_NET_IF_H
96f3a036 7254#include <net/if.h>
7862d3a8 7255#endif
96f3a036
DL
7256
7257int
7258main ()
7259{
7260static struct ifreq ac_aggr;
7261if (ac_aggr.ifr_broadaddr)
7262return 0;
7263 ;
7264 return 0;
7265}
7266_ACEOF
7267rm -f conftest.$ac_objext
7268if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7269 (eval $ac_compile) 2>conftest.er1
96f3a036 7270 ac_status=$?
35996d22
AS
7271 grep -v '^ *+' conftest.er1 >conftest.err
7272 rm -f conftest.er1
7273 cat conftest.err >&5
96f3a036
DL
7274 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7275 (exit $ac_status); } &&
35996d22
AS
7276 { ac_try='test -z "$ac_c_werror_flag"
7277 || test ! -s conftest.err'
7278 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7279 (eval $ac_try) 2>&5
7280 ac_status=$?
7281 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7282 (exit $ac_status); }; } &&
7283 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7284 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7285 (eval $ac_try) 2>&5
7286 ac_status=$?
7287 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7288 (exit $ac_status); }; }; then
7289 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7290else
7291 echo "$as_me: failed program was:" >&5
7292sed 's/^/| /' conftest.$ac_ext >&5
7293
7294cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7295/* confdefs.h. */
7296_ACEOF
7297cat confdefs.h >>conftest.$ac_ext
7298cat >>conftest.$ac_ext <<_ACEOF
7299/* end confdefs.h. */
7862d3a8
AS
7300$ac_includes_default
7301#if HAVE_SYS_SOCKET_H
7302#include <sys/socket.h>
7303#endif
7304#if HAVE_NET_IF_H
96f3a036 7305#include <net/if.h>
7862d3a8 7306#endif
96f3a036
DL
7307
7308int
7309main ()
7310{
7311static struct ifreq ac_aggr;
7312if (sizeof ac_aggr.ifr_broadaddr)
7313return 0;
7314 ;
7315 return 0;
7316}
7317_ACEOF
7318rm -f conftest.$ac_objext
7319if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7320 (eval $ac_compile) 2>conftest.er1
96f3a036 7321 ac_status=$?
35996d22
AS
7322 grep -v '^ *+' conftest.er1 >conftest.err
7323 rm -f conftest.er1
7324 cat conftest.err >&5
96f3a036
DL
7325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7326 (exit $ac_status); } &&
35996d22
AS
7327 { ac_try='test -z "$ac_c_werror_flag"
7328 || test ! -s conftest.err'
7329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7330 (eval $ac_try) 2>&5
7331 ac_status=$?
7332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7333 (exit $ac_status); }; } &&
7334 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7336 (eval $ac_try) 2>&5
7337 ac_status=$?
7338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7339 (exit $ac_status); }; }; then
7340 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7341else
7342 echo "$as_me: failed program was:" >&5
7343sed 's/^/| /' conftest.$ac_ext >&5
7344
7345ac_cv_member_struct_ifreq_ifr_broadaddr=no
7346fi
35996d22 7347rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7348fi
35996d22 7349rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7350fi
7351echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
7352echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6
7353if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
7354
7355cat >>confdefs.h <<_ACEOF
7356#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
7357_ACEOF
7358
7359
7360fi
7361echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
7362echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6
7363if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
7364 echo $ECHO_N "(cached) $ECHO_C" >&6
7365else
7366 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7367/* confdefs.h. */
7368_ACEOF
7369cat confdefs.h >>conftest.$ac_ext
7370cat >>conftest.$ac_ext <<_ACEOF
7371/* end confdefs.h. */
7862d3a8
AS
7372$ac_includes_default
7373#if HAVE_SYS_SOCKET_H
7374#include <sys/socket.h>
7375#endif
7376#if HAVE_NET_IF_H
96f3a036 7377#include <net/if.h>
7862d3a8 7378#endif
96f3a036
DL
7379
7380int
7381main ()
7382{
7383static struct ifreq ac_aggr;
7384if (ac_aggr.ifr_addr)
7385return 0;
7386 ;
7387 return 0;
7388}
7389_ACEOF
7390rm -f conftest.$ac_objext
7391if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7392 (eval $ac_compile) 2>conftest.er1
96f3a036 7393 ac_status=$?
35996d22
AS
7394 grep -v '^ *+' conftest.er1 >conftest.err
7395 rm -f conftest.er1
7396 cat conftest.err >&5
96f3a036
DL
7397 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7398 (exit $ac_status); } &&
35996d22
AS
7399 { ac_try='test -z "$ac_c_werror_flag"
7400 || test ! -s conftest.err'
7401 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7402 (eval $ac_try) 2>&5
7403 ac_status=$?
7404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7405 (exit $ac_status); }; } &&
7406 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7407 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7408 (eval $ac_try) 2>&5
7409 ac_status=$?
7410 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7411 (exit $ac_status); }; }; then
7412 ac_cv_member_struct_ifreq_ifr_addr=yes
7413else
7414 echo "$as_me: failed program was:" >&5
7415sed 's/^/| /' conftest.$ac_ext >&5
7416
7417cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7418/* confdefs.h. */
7419_ACEOF
7420cat confdefs.h >>conftest.$ac_ext
7421cat >>conftest.$ac_ext <<_ACEOF
7422/* end confdefs.h. */
7862d3a8
AS
7423$ac_includes_default
7424#if HAVE_SYS_SOCKET_H
7425#include <sys/socket.h>
7426#endif
7427#if HAVE_NET_IF_H
96f3a036 7428#include <net/if.h>
7862d3a8 7429#endif
96f3a036
DL
7430
7431int
7432main ()
7433{
7434static struct ifreq ac_aggr;
7435if (sizeof ac_aggr.ifr_addr)
7436return 0;
7437 ;
7438 return 0;
7439}
7440_ACEOF
7441rm -f conftest.$ac_objext
7442if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7443 (eval $ac_compile) 2>conftest.er1
96f3a036 7444 ac_status=$?
35996d22
AS
7445 grep -v '^ *+' conftest.er1 >conftest.err
7446 rm -f conftest.er1
7447 cat conftest.err >&5
96f3a036
DL
7448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7449 (exit $ac_status); } &&
35996d22
AS
7450 { ac_try='test -z "$ac_c_werror_flag"
7451 || test ! -s conftest.err'
7452 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7453 (eval $ac_try) 2>&5
7454 ac_status=$?
7455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7456 (exit $ac_status); }; } &&
7457 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7458 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7459 (eval $ac_try) 2>&5
7460 ac_status=$?
7461 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7462 (exit $ac_status); }; }; then
7463 ac_cv_member_struct_ifreq_ifr_addr=yes
7464else
7465 echo "$as_me: failed program was:" >&5
7466sed 's/^/| /' conftest.$ac_ext >&5
7467
7468ac_cv_member_struct_ifreq_ifr_addr=no
7469fi
35996d22 7470rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7471fi
35996d22 7472rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7473fi
7474echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
7475echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6
7476if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
7477
7478cat >>confdefs.h <<_ACEOF
7479#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
7480_ACEOF
7481
7482
7483fi
7484
8799b3e4 7485
8799b3e4 7486
c0d27fcc 7487echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
7488echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
7489if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 7490 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7491echo "${ECHO_T}yes" >&6
7492
c0d27fcc 7493cat >>confdefs.h <<\_ACEOF
98418dba 7494#define PROTOTYPES 1
c0d27fcc
MR
7495_ACEOF
7496
7497
7498cat >>confdefs.h <<\_ACEOF
7499#define __PROTOTYPES 1
7500_ACEOF
98418dba
CW
7501
7502else
c0d27fcc 7503 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7504echo "${ECHO_T}no" >&6
7505fi
7506
c0d27fcc 7507echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
7508echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
7509if test "${ac_cv_c_volatile+set}" = set; then
7510 echo $ECHO_N "(cached) $ECHO_C" >&6
7511else
7512 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7513/* confdefs.h. */
7514_ACEOF
7515cat confdefs.h >>conftest.$ac_ext
7516cat >>conftest.$ac_ext <<_ACEOF
7517/* end confdefs.h. */
98418dba 7518
98418dba
CW
7519int
7520main ()
7521{
7522
7523volatile int x;
7524int * volatile y;
7525 ;
7526 return 0;
7527}
7528_ACEOF
7529rm -f conftest.$ac_objext
c0d27fcc 7530if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7531 (eval $ac_compile) 2>conftest.er1
98418dba 7532 ac_status=$?
35996d22
AS
7533 grep -v '^ *+' conftest.er1 >conftest.err
7534 rm -f conftest.er1
7535 cat conftest.err >&5
c0d27fcc 7536 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7537 (exit $ac_status); } &&
35996d22
AS
7538 { ac_try='test -z "$ac_c_werror_flag"
7539 || test ! -s conftest.err'
7540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7541 (eval $ac_try) 2>&5
7542 ac_status=$?
7543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7544 (exit $ac_status); }; } &&
7545 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7546 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7547 (eval $ac_try) 2>&5
7548 ac_status=$?
c0d27fcc 7549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7550 (exit $ac_status); }; }; then
7551 ac_cv_c_volatile=yes
7552else
7553 echo "$as_me: failed program was:" >&5
19650fd6
AS
7554sed 's/^/| /' conftest.$ac_ext >&5
7555
98418dba
CW
7556ac_cv_c_volatile=no
7557fi
35996d22 7558rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7559fi
c0d27fcc 7560echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
7561echo "${ECHO_T}$ac_cv_c_volatile" >&6
7562if test $ac_cv_c_volatile = no; then
7563
c0d27fcc 7564cat >>confdefs.h <<\_ACEOF
98418dba 7565#define volatile
c0d27fcc 7566_ACEOF
98418dba
CW
7567
7568fi
7569
c0d27fcc 7570echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
7571echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
7572if test "${ac_cv_c_const+set}" = set; then
7573 echo $ECHO_N "(cached) $ECHO_C" >&6
7574else
7575 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7576/* confdefs.h. */
7577_ACEOF
7578cat confdefs.h >>conftest.$ac_ext
7579cat >>conftest.$ac_ext <<_ACEOF
7580/* end confdefs.h. */
98418dba 7581
98418dba
CW
7582int
7583main ()
7584{
7585/* FIXME: Include the comments suggested by Paul. */
7586#ifndef __cplusplus
7587 /* Ultrix mips cc rejects this. */
7588 typedef int charset[2];
7589 const charset x;
7590 /* SunOS 4.1.1 cc rejects this. */
7591 char const *const *ccp;
7592 char **p;
7593 /* NEC SVR4.0.2 mips cc rejects this. */
7594 struct point {int x, y;};
7595 static struct point const zero = {0,0};
7596 /* AIX XL C 1.02.0.0 rejects this.
7597 It does not let you subtract one const X* pointer from another in
7598 an arm of an if-expression whose if-part is not a constant
7599 expression */
7600 const char *g = "string";
7601 ccp = &g + (g ? g-g : 0);
7602 /* HPUX 7.0 cc rejects these. */
7603 ++ccp;
7604 p = (char**) ccp;
7605 ccp = (char const *const *) p;
7606 { /* SCO 3.2v4 cc rejects this. */
7607 char *t;
7608 char const *s = 0 ? (char *) 0 : (char const *) 0;
7609
7610 *t++ = 0;
7611 }
7612 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7613 int x[] = {25, 17};
7614 const int *foo = &x[0];
7615 ++foo;
7616 }
7617 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7618 typedef const int *iptr;
7619 iptr p = 0;
7620 ++p;
7621 }
7622 { /* AIX XL C 1.02.0.0 rejects this saying
7623 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7624 struct s { int j; const int *ap[3]; };
7625 struct s *b; b->j = 5;
7626 }
7627 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7628 const int foo = 10;
7629 }
7630#endif
7631
7632 ;
7633 return 0;
7634}
7635_ACEOF
7636rm -f conftest.$ac_objext
c0d27fcc 7637if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7638 (eval $ac_compile) 2>conftest.er1
98418dba 7639 ac_status=$?
35996d22
AS
7640 grep -v '^ *+' conftest.er1 >conftest.err
7641 rm -f conftest.er1
7642 cat conftest.err >&5
c0d27fcc 7643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7644 (exit $ac_status); } &&
35996d22
AS
7645 { ac_try='test -z "$ac_c_werror_flag"
7646 || test ! -s conftest.err'
7647 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7648 (eval $ac_try) 2>&5
7649 ac_status=$?
7650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7651 (exit $ac_status); }; } &&
7652 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7653 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7654 (eval $ac_try) 2>&5
7655 ac_status=$?
c0d27fcc 7656 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7657 (exit $ac_status); }; }; then
7658 ac_cv_c_const=yes
7659else
7660 echo "$as_me: failed program was:" >&5
19650fd6
AS
7661sed 's/^/| /' conftest.$ac_ext >&5
7662
98418dba
CW
7663ac_cv_c_const=no
7664fi
35996d22 7665rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7666fi
c0d27fcc 7667echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
7668echo "${ECHO_T}$ac_cv_c_const" >&6
7669if test $ac_cv_c_const = no; then
7670
c0d27fcc 7671cat >>confdefs.h <<\_ACEOF
98418dba 7672#define const
c0d27fcc 7673_ACEOF
98418dba
CW
7674
7675fi
7676
c0d27fcc 7677echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
7678echo $ECHO_N "checking for void * support... $ECHO_C" >&6
7679if test "${emacs_cv_void_star+set}" = set; then
7680 echo $ECHO_N "(cached) $ECHO_C" >&6
7681else
7682 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7683/* confdefs.h. */
7684_ACEOF
7685cat confdefs.h >>conftest.$ac_ext
7686cat >>conftest.$ac_ext <<_ACEOF
7687/* end confdefs.h. */
98418dba 7688
98418dba
CW
7689int
7690main ()
7691{
7692void * foo;
7693 ;
7694 return 0;
7695}
7696_ACEOF
7697rm -f conftest.$ac_objext
c0d27fcc 7698if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7699 (eval $ac_compile) 2>conftest.er1
98418dba 7700 ac_status=$?
35996d22
AS
7701 grep -v '^ *+' conftest.er1 >conftest.err
7702 rm -f conftest.er1
7703 cat conftest.err >&5
c0d27fcc 7704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7705 (exit $ac_status); } &&
35996d22
AS
7706 { ac_try='test -z "$ac_c_werror_flag"
7707 || test ! -s conftest.err'
7708 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7709 (eval $ac_try) 2>&5
7710 ac_status=$?
7711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7712 (exit $ac_status); }; } &&
7713 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7715 (eval $ac_try) 2>&5
7716 ac_status=$?
c0d27fcc 7717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7718 (exit $ac_status); }; }; then
7719 emacs_cv_void_star=yes
7720else
7721 echo "$as_me: failed program was:" >&5
19650fd6
AS
7722sed 's/^/| /' conftest.$ac_ext >&5
7723
98418dba
CW
7724emacs_cv_void_star=no
7725fi
35996d22 7726rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7727fi
c0d27fcc 7728echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
7729echo "${ECHO_T}$emacs_cv_void_star" >&6
7730if test $emacs_cv_void_star = yes; then
c0d27fcc 7731 cat >>confdefs.h <<\_ACEOF
98418dba 7732#define POINTER_TYPE void
c0d27fcc 7733_ACEOF
98418dba
CW
7734
7735else
c0d27fcc 7736 cat >>confdefs.h <<\_ACEOF
98418dba 7737#define POINTER_TYPE char
c0d27fcc 7738_ACEOF
98418dba
CW
7739
7740fi
7741
c0d27fcc 7742
cd958eb3 7743
19650fd6
AS
7744echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7745echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
35996d22 7746set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
98418dba
CW
7747if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
7748 echo $ECHO_N "(cached) $ECHO_C" >&6
7749else
c0d27fcc 7750 cat >conftest.make <<\_ACEOF
98418dba 7751all:
19650fd6 7752 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 7753_ACEOF
98418dba
CW
7754# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7755eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
7756if test -n "$ac_maketemp"; then
7757 eval ac_cv_prog_make_${ac_make}_set=yes
7758else
7759 eval ac_cv_prog_make_${ac_make}_set=no
7760fi
7761rm -f conftest.make
7762fi
7763if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 7764 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7765echo "${ECHO_T}yes" >&6
7766 SET_MAKE=
7767else
c0d27fcc 7768 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7769echo "${ECHO_T}no" >&6
7770 SET_MAKE="MAKE=${MAKE-make}"
7771fi
7772
c0d27fcc
MR
7773
7774echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
7775echo $ECHO_N "checking for long file names... $ECHO_C" >&6
7776if test "${ac_cv_sys_long_file_names+set}" = set; then
7777 echo $ECHO_N "(cached) $ECHO_C" >&6
7778else
7779 ac_cv_sys_long_file_names=yes
7780# Test for long file names in all the places we know might matter:
7781# . the current directory, where building will happen
7782# $prefix/lib where we will be installing things
7783# $exec_prefix/lib likewise
7784# eval it to expand exec_prefix.
7785# $TMPDIR if set, where it might want to write temporary files
7786# if $TMPDIR is not set:
7787# /tmp where it might want to write temporary files
7788# /var/tmp likewise
7789# /usr/tmp likewise
7790if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
7791 ac_tmpdirs=$TMPDIR
7792else
7793 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
7794fi
7795for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
7796 test -d $ac_dir || continue
7797 test -w $ac_dir || continue # It is less confusing to not echo anything here.
7798 ac_xdir=$ac_dir/cf$$
7799 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
7800 ac_tf1=$ac_xdir/conftest9012345
7801 ac_tf2=$ac_xdir/conftest9012346
7802 (echo 1 >$ac_tf1) 2>/dev/null
7803 (echo 2 >$ac_tf2) 2>/dev/null
7804 ac_val=`cat $ac_tf1 2>/dev/null`
7805 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
7806 ac_cv_sys_long_file_names=no
7807 rm -rf $ac_xdir 2>/dev/null
7808 break
7809 fi
7810 rm -rf $ac_xdir 2>/dev/null
7811done
7812fi
c0d27fcc 7813echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
7814echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
7815if test $ac_cv_sys_long_file_names = yes; then
7816
c0d27fcc 7817cat >>confdefs.h <<\_ACEOF
98418dba 7818#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 7819_ACEOF
98418dba
CW
7820
7821fi
7822
c0d27fcc 7823
98418dba
CW
7824#### Choose a window system.
7825
c0d27fcc 7826echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
7827echo $ECHO_N "checking for X... $ECHO_C" >&6
7828
c0d27fcc 7829
98418dba
CW
7830# Check whether --with-x or --without-x was given.
7831if test "${with_x+set}" = set; then
7832 withval="$with_x"
7833
7834fi;
7835# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7836if test "x$with_x" = xno; then
7837 # The user explicitly disabled X.
7838 have_x=disabled
7839else
7840 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7841 # Both variables are already set.
7842 have_x=yes
7843 else
7844 if test "${ac_cv_have_x+set}" = set; then
7845 echo $ECHO_N "(cached) $ECHO_C" >&6
7846else
7847 # One or both of the vars are not set, and there is no cached value.
7848ac_x_includes=no ac_x_libraries=no
7849rm -fr conftest.dir
7850if mkdir conftest.dir; then
7851 cd conftest.dir
7852 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 7853 cat >Imakefile <<'_ACEOF'
98418dba
CW
7854acfindx:
7855 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 7856_ACEOF
98418dba
CW
7857 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7858 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7859 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7860 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7861 for ac_extension in a so sl; do
7862 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
35996d22
AS
7863 test -f $ac_im_libdir/libX11.$ac_extension; then
7864 ac_im_usrlibdir=$ac_im_libdir; break
98418dba
CW
7865 fi
7866 done
7867 # Screen out bogus values from the imake configuration. They are
7868 # bogus both because they are the default anyway, and because
7869 # using them would break gcc on systems where it needs fixed includes.
7870 case $ac_im_incroot in
7871 /usr/include) ;;
7872 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7873 esac
7874 case $ac_im_usrlibdir in
7875 /usr/lib | /lib) ;;
7876 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7877 esac
7878 fi
7879 cd ..
7880 rm -fr conftest.dir
7881fi
7882
7883# Standard set of common directories for X headers.
7884# Check X11 before X11Rn because it is often a symlink to the current release.
7885ac_x_header_dirs='
7886/usr/X11/include
7887/usr/X11R6/include
7888/usr/X11R5/include
7889/usr/X11R4/include
7890
7891/usr/include/X11
7892/usr/include/X11R6
7893/usr/include/X11R5
7894/usr/include/X11R4
7895
7896/usr/local/X11/include
7897/usr/local/X11R6/include
7898/usr/local/X11R5/include
7899/usr/local/X11R4/include
7900
7901/usr/local/include/X11
7902/usr/local/include/X11R6
7903/usr/local/include/X11R5
7904/usr/local/include/X11R4
7905
7906/usr/X386/include
7907/usr/x386/include
7908/usr/XFree86/include/X11
7909
7910/usr/include
7911/usr/local/include
7912/usr/unsupported/include
7913/usr/athena/include
7914/usr/local/x11r5/include
7915/usr/lpp/Xamples/include
7916
7917/usr/openwin/include
7918/usr/openwin/share/include'
7919
7920if test "$ac_x_includes" = no; then
7921 # Guess where to find include files, by looking for Intrinsic.h.
7922 # First, try using that file with no special directory specified.
7923 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7924/* confdefs.h. */
7925_ACEOF
7926cat confdefs.h >>conftest.$ac_ext
7927cat >>conftest.$ac_ext <<_ACEOF
7928/* end confdefs.h. */
98418dba
CW
7929#include <X11/Intrinsic.h>
7930_ACEOF
c0d27fcc 7931if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
7932 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7933 ac_status=$?
6bae0ccf 7934 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
7935 rm -f conftest.er1
7936 cat conftest.err >&5
c0d27fcc 7937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7938 (exit $ac_status); } >/dev/null; then
7939 if test -s conftest.err; then
7940 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 7941 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
7942 else
7943 ac_cpp_err=
7944 fi
7945else
7946 ac_cpp_err=yes
7947fi
7948if test -z "$ac_cpp_err"; then
7949 # We can compile using X headers with no special include directory.
7950ac_x_includes=
7951else
7952 echo "$as_me: failed program was:" >&5
19650fd6
AS
7953sed 's/^/| /' conftest.$ac_ext >&5
7954
98418dba
CW
7955 for ac_dir in $ac_x_header_dirs; do
7956 if test -r "$ac_dir/X11/Intrinsic.h"; then
7957 ac_x_includes=$ac_dir
7958 break
7959 fi
7960done
7961fi
7962rm -f conftest.err conftest.$ac_ext
7963fi # $ac_x_includes = no
7964
7965if test "$ac_x_libraries" = no; then
7966 # Check for the libraries.
7967 # See if we find them without any special options.
7968 # Don't add to $LIBS permanently.
7969 ac_save_LIBS=$LIBS
7970 LIBS="-lXt $LIBS"
7971 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7972/* confdefs.h. */
7973_ACEOF
7974cat confdefs.h >>conftest.$ac_ext
7975cat >>conftest.$ac_ext <<_ACEOF
7976/* end confdefs.h. */
98418dba 7977#include <X11/Intrinsic.h>
98418dba
CW
7978int
7979main ()
7980{
7981XtMalloc (0)
7982 ;
7983 return 0;
7984}
7985_ACEOF
7986rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7987if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 7988 (eval $ac_link) 2>conftest.er1
98418dba 7989 ac_status=$?
35996d22
AS
7990 grep -v '^ *+' conftest.er1 >conftest.err
7991 rm -f conftest.er1
7992 cat conftest.err >&5
c0d27fcc 7993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7994 (exit $ac_status); } &&
35996d22
AS
7995 { ac_try='test -z "$ac_c_werror_flag"
7996 || test ! -s conftest.err'
7997 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7998 (eval $ac_try) 2>&5
7999 ac_status=$?
8000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8001 (exit $ac_status); }; } &&
8002 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8003 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8004 (eval $ac_try) 2>&5
8005 ac_status=$?
c0d27fcc 8006 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8007 (exit $ac_status); }; }; then
8008 LIBS=$ac_save_LIBS
8009# We can link X programs with no special library path.
8010ac_x_libraries=
8011else
8012 echo "$as_me: failed program was:" >&5
19650fd6
AS
8013sed 's/^/| /' conftest.$ac_ext >&5
8014
98418dba
CW
8015LIBS=$ac_save_LIBS
8016for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8017do
8018 # Don't even attempt the hair of trying to link an X program!
8019 for ac_extension in a so sl; do
8020 if test -r $ac_dir/libXt.$ac_extension; then
8021 ac_x_libraries=$ac_dir
8022 break 2
8023 fi
8024 done
8025done
8026fi
35996d22
AS
8027rm -f conftest.err conftest.$ac_objext \
8028 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8029fi # $ac_x_libraries = no
8030
8031if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
8032 # Didn't find X anywhere. Cache the known absence of X.
8033 ac_cv_have_x="have_x=no"
8034else
8035 # Record where we found X for the cache.
8036 ac_cv_have_x="have_x=yes \
35996d22 8037 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
98418dba
CW
8038fi
8039fi
8040
8041 fi
8042 eval "$ac_cv_have_x"
8043fi # $with_x != no
8044
8045if test "$have_x" != yes; then
c0d27fcc 8046 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
8047echo "${ECHO_T}$have_x" >&6
8048 no_x=yes
8049else
8050 # If each of the values was on the command line, it overrides each guess.
8051 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8052 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8053 # Update the cache value to reflect the command line values.
8054 ac_cv_have_x="have_x=yes \
8055 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
c0d27fcc 8056 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
98418dba
CW
8057echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
8058fi
8059
8060if test "$no_x" = yes; then
8061 window_system=none
8062else
8063 window_system=x11
8064fi
8065
8066if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8067 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
8068 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
8069 x_default_search_path=""
8070 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
8071 x_search_path="\
8072${x_library}/X11/%L/%T/%N%C%S:\
8073${x_library}/X11/%l/%T/%N%C%S:\
8074${x_library}/X11/%T/%N%C%S:\
8075${x_library}/X11/%L/%T/%N%S:\
8076${x_library}/X11/%l/%T/%N%S:\
8077${x_library}/X11/%T/%N%S"
8078 if test x"${x_default_search_path}" = x; then
8079 x_default_search_path=${x_search_path}
8080 else
8081 x_default_search_path="${x_search_path}:${x_default_search_path}"
8082 fi
8083 done
8084fi
8085if test "${x_includes}" != NONE && test -n "${x_includes}"; then
8086 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
8087fi
8088
8089if test x"${x_includes}" = x; then
8090 bitmapdir=/usr/include/X11/bitmaps
8091else
8092 # accumulate include directories that have X11 bitmap subdirectories
8093 bmd_acc="dummyval"
8094 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
8095 if test -d "${bmd}/X11/bitmaps"; then
8096 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
8097 fi
8098 if test -d "${bmd}/bitmaps"; then
8099 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
8100 fi
8101 done
8102 if test ${bmd_acc} != "dummyval"; then
8103 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
8104 fi
8105fi
8106
8107case "${window_system}" in
8108 x11 )
8109 HAVE_X_WINDOWS=yes
8110 HAVE_X11=yes
8111 case "${with_x_toolkit}" in
8112 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
8113 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
8114 gtk ) with_gtk=yes
8115 USE_X_TOOLKIT=none ;;
98418dba
CW
8116 no ) USE_X_TOOLKIT=none ;;
8117 * ) USE_X_TOOLKIT=maybe ;;
8118 esac
8119 ;;
8120 none )
8121 HAVE_X_WINDOWS=no
8122 HAVE_X11=no
8123 USE_X_TOOLKIT=none
8124 ;;
8125esac
8126
8127### If we're using X11, we should use the X menu package.
8128HAVE_MENUS=no
8129case ${HAVE_X11} in
8130 yes ) HAVE_MENUS=yes ;;
8131esac
8132
8133if test "${opsys}" = "hpux9"; then
8134 case "${x_libraries}" in
8135 *X11R4* )
8136 opsysfile="s/hpux9-x11r4.h"
8137 ;;
8138 esac
8139fi
8140
8141if test "${opsys}" = "hpux9shr"; then
8142 case "${x_libraries}" in
8143 *X11R4* )
8144 opsysfile="s/hpux9shxr4.h"
8145 ;;
8146 esac
8147fi
8148
8149### Compute the unexec source name from the object name.
8150UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
8151
8152# Do the opsystem or machine files prohibit the use of the GNU malloc?
8153# Assume not, until told otherwise.
8154GNU_MALLOC=yes
8155doug_lea_malloc=yes
c0d27fcc 8156echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
8157echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
8158if test "${ac_cv_func_malloc_get_state+set}" = set; then
8159 echo $ECHO_N "(cached) $ECHO_C" >&6
8160else
8161 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8162/* confdefs.h. */
8163_ACEOF
8164cat confdefs.h >>conftest.$ac_ext
8165cat >>conftest.$ac_ext <<_ACEOF
8166/* end confdefs.h. */
35996d22
AS
8167/* Define malloc_get_state to an innocuous variant, in case <limits.h> declares malloc_get_state.
8168 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8169#define malloc_get_state innocuous_malloc_get_state
8170
98418dba 8171/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8172 which can conflict with char malloc_get_state (); below.
8173 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8174 <limits.h> exists even on freestanding compilers. */
35996d22 8175
19650fd6
AS
8176#ifdef __STDC__
8177# include <limits.h>
8178#else
8179# include <assert.h>
8180#endif
35996d22
AS
8181
8182#undef malloc_get_state
8183
98418dba
CW
8184/* Override any gcc2 internal prototype to avoid an error. */
8185#ifdef __cplusplus
8186extern "C"
19650fd6 8187{
98418dba
CW
8188#endif
8189/* We use char because int might match the return type of a gcc2
8190 builtin and then its argument prototype would still apply. */
8191char malloc_get_state ();
98418dba
CW
8192/* The GNU C library defines this for functions which it implements
8193 to always fail with ENOSYS. Some functions are actually named
8194 something starting with __ and the normal name is an alias. */
8195#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
8196choke me
8197#else
19650fd6
AS
8198char (*f) () = malloc_get_state;
8199#endif
8200#ifdef __cplusplus
8201}
98418dba
CW
8202#endif
8203
19650fd6
AS
8204int
8205main ()
8206{
8207return f != malloc_get_state;
98418dba
CW
8208 ;
8209 return 0;
8210}
8211_ACEOF
8212rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8213if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8214 (eval $ac_link) 2>conftest.er1
98418dba 8215 ac_status=$?
35996d22
AS
8216 grep -v '^ *+' conftest.er1 >conftest.err
8217 rm -f conftest.er1
8218 cat conftest.err >&5
c0d27fcc 8219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8220 (exit $ac_status); } &&
35996d22
AS
8221 { ac_try='test -z "$ac_c_werror_flag"
8222 || test ! -s conftest.err'
8223 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8224 (eval $ac_try) 2>&5
8225 ac_status=$?
8226 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8227 (exit $ac_status); }; } &&
8228 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8229 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8230 (eval $ac_try) 2>&5
8231 ac_status=$?
c0d27fcc 8232 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8233 (exit $ac_status); }; }; then
8234 ac_cv_func_malloc_get_state=yes
8235else
8236 echo "$as_me: failed program was:" >&5
19650fd6
AS
8237sed 's/^/| /' conftest.$ac_ext >&5
8238
98418dba
CW
8239ac_cv_func_malloc_get_state=no
8240fi
35996d22
AS
8241rm -f conftest.err conftest.$ac_objext \
8242 conftest$ac_exeext conftest.$ac_ext
98418dba 8243fi
c0d27fcc 8244echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
8245echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
8246if test $ac_cv_func_malloc_get_state = yes; then
8247 :
8248else
8249 doug_lea_malloc=no
8250fi
8251
c0d27fcc 8252echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
8253echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
8254if test "${ac_cv_func_malloc_set_state+set}" = set; then
8255 echo $ECHO_N "(cached) $ECHO_C" >&6
8256else
8257 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8258/* confdefs.h. */
8259_ACEOF
8260cat confdefs.h >>conftest.$ac_ext
8261cat >>conftest.$ac_ext <<_ACEOF
8262/* end confdefs.h. */
35996d22
AS
8263/* Define malloc_set_state to an innocuous variant, in case <limits.h> declares malloc_set_state.
8264 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8265#define malloc_set_state innocuous_malloc_set_state
8266
98418dba 8267/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8268 which can conflict with char malloc_set_state (); below.
8269 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8270 <limits.h> exists even on freestanding compilers. */
35996d22 8271
19650fd6
AS
8272#ifdef __STDC__
8273# include <limits.h>
8274#else
8275# include <assert.h>
8276#endif
35996d22
AS
8277
8278#undef malloc_set_state
8279
98418dba
CW
8280/* Override any gcc2 internal prototype to avoid an error. */
8281#ifdef __cplusplus
8282extern "C"
19650fd6 8283{
98418dba
CW
8284#endif
8285/* We use char because int might match the return type of a gcc2
8286 builtin and then its argument prototype would still apply. */
8287char malloc_set_state ();
98418dba
CW
8288/* The GNU C library defines this for functions which it implements
8289 to always fail with ENOSYS. Some functions are actually named
8290 something starting with __ and the normal name is an alias. */
8291#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
8292choke me
8293#else
19650fd6
AS
8294char (*f) () = malloc_set_state;
8295#endif
8296#ifdef __cplusplus
8297}
98418dba
CW
8298#endif
8299
19650fd6
AS
8300int
8301main ()
8302{
8303return f != malloc_set_state;
98418dba
CW
8304 ;
8305 return 0;
8306}
8307_ACEOF
8308rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8309if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8310 (eval $ac_link) 2>conftest.er1
98418dba 8311 ac_status=$?
35996d22
AS
8312 grep -v '^ *+' conftest.er1 >conftest.err
8313 rm -f conftest.er1
8314 cat conftest.err >&5
c0d27fcc 8315 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8316 (exit $ac_status); } &&
35996d22
AS
8317 { ac_try='test -z "$ac_c_werror_flag"
8318 || test ! -s conftest.err'
8319 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8320 (eval $ac_try) 2>&5
8321 ac_status=$?
8322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8323 (exit $ac_status); }; } &&
8324 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8325 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8326 (eval $ac_try) 2>&5
8327 ac_status=$?
c0d27fcc 8328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8329 (exit $ac_status); }; }; then
8330 ac_cv_func_malloc_set_state=yes
8331else
8332 echo "$as_me: failed program was:" >&5
19650fd6
AS
8333sed 's/^/| /' conftest.$ac_ext >&5
8334
98418dba
CW
8335ac_cv_func_malloc_set_state=no
8336fi
35996d22
AS
8337rm -f conftest.err conftest.$ac_objext \
8338 conftest$ac_exeext conftest.$ac_ext
98418dba 8339fi
c0d27fcc 8340echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
8341echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
8342if test $ac_cv_func_malloc_set_state = yes; then
8343 :
8344else
8345 doug_lea_malloc=no
8346fi
8347
c0d27fcc 8348echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
8349echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
8350if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
8351 echo $ECHO_N "(cached) $ECHO_C" >&6
8352else
8353 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8354/* confdefs.h. */
8355_ACEOF
8356cat confdefs.h >>conftest.$ac_ext
8357cat >>conftest.$ac_ext <<_ACEOF
8358/* end confdefs.h. */
98418dba 8359extern void (* __after_morecore_hook)();
98418dba
CW
8360int
8361main ()
8362{
8363__after_morecore_hook = 0
8364 ;
8365 return 0;
8366}
8367_ACEOF
8368rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8369if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8370 (eval $ac_link) 2>conftest.er1
98418dba 8371 ac_status=$?
35996d22
AS
8372 grep -v '^ *+' conftest.er1 >conftest.err
8373 rm -f conftest.er1
8374 cat conftest.err >&5
c0d27fcc 8375 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8376 (exit $ac_status); } &&
35996d22
AS
8377 { ac_try='test -z "$ac_c_werror_flag"
8378 || test ! -s conftest.err'
8379 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8380 (eval $ac_try) 2>&5
8381 ac_status=$?
8382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8383 (exit $ac_status); }; } &&
8384 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8385 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8386 (eval $ac_try) 2>&5
8387 ac_status=$?
c0d27fcc 8388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8389 (exit $ac_status); }; }; then
8390 emacs_cv_var___after_morecore_hook=yes
8391else
8392 echo "$as_me: failed program was:" >&5
19650fd6
AS
8393sed 's/^/| /' conftest.$ac_ext >&5
8394
98418dba
CW
8395emacs_cv_var___after_morecore_hook=no
8396fi
35996d22
AS
8397rm -f conftest.err conftest.$ac_objext \
8398 conftest$ac_exeext conftest.$ac_ext
98418dba 8399fi
c0d27fcc 8400echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
8401echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
8402if test $emacs_cv_var___after_morecore_hook = no; then
8403 doug_lea_malloc=no
8404fi
8405if test "${system_malloc}" = "yes"; then
8406 GNU_MALLOC=no
8407 GNU_MALLOC_reason="
8408 (The GNU allocators don't work with this system configuration.)"
8409fi
8410if test "$doug_lea_malloc" = "yes" ; then
8411 if test "$GNU_MALLOC" = yes ; then
8412 GNU_MALLOC_reason="
8413 (Using Doug Lea's new malloc from the GNU C Library.)"
8414 fi
b936fae4 8415
c0d27fcc 8416cat >>confdefs.h <<\_ACEOF
98418dba 8417#define DOUG_LEA_MALLOC 1
c0d27fcc 8418_ACEOF
98418dba
CW
8419
8420fi
8421
8422if test x"${REL_ALLOC}" = x; then
8423 REL_ALLOC=${GNU_MALLOC}
8424fi
8425
8426
c0d27fcc
MR
8427
8428
8429for ac_header in stdlib.h unistd.h
98418dba
CW
8430do
8431as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
8432if eval "test \"\${$as_ac_Header+set}\" = set"; then
8433 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
8434echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8435if eval "test \"\${$as_ac_Header+set}\" = set"; then
8436 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8437fi
8438echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8439echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 8440else
c0d27fcc
MR
8441 # Is the header compilable?
8442echo "$as_me:$LINENO: checking $ac_header usability" >&5
8443echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8444cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8445/* confdefs.h. */
8446_ACEOF
8447cat confdefs.h >>conftest.$ac_ext
8448cat >>conftest.$ac_ext <<_ACEOF
8449/* end confdefs.h. */
98418dba
CW
8450$ac_includes_default
8451#include <$ac_header>
8452_ACEOF
8453rm -f conftest.$ac_objext
c0d27fcc 8454if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 8455 (eval $ac_compile) 2>conftest.er1
98418dba 8456 ac_status=$?
35996d22
AS
8457 grep -v '^ *+' conftest.er1 >conftest.err
8458 rm -f conftest.er1
8459 cat conftest.err >&5
c0d27fcc 8460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8461 (exit $ac_status); } &&
35996d22
AS
8462 { ac_try='test -z "$ac_c_werror_flag"
8463 || test ! -s conftest.err'
8464 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8465 (eval $ac_try) 2>&5
8466 ac_status=$?
8467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8468 (exit $ac_status); }; } &&
8469 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8470 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8471 (eval $ac_try) 2>&5
8472 ac_status=$?
c0d27fcc 8473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8474 (exit $ac_status); }; }; then
c0d27fcc 8475 ac_header_compiler=yes
98418dba
CW
8476else
8477 echo "$as_me: failed program was:" >&5
19650fd6
AS
8478sed 's/^/| /' conftest.$ac_ext >&5
8479
c0d27fcc 8480ac_header_compiler=no
98418dba 8481fi
35996d22 8482rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
8483echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8484echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 8485
c0d27fcc
MR
8486# Is the header present?
8487echo "$as_me:$LINENO: checking $ac_header presence" >&5
8488echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8489cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8490/* confdefs.h. */
8491_ACEOF
8492cat confdefs.h >>conftest.$ac_ext
8493cat >>conftest.$ac_ext <<_ACEOF
8494/* end confdefs.h. */
98418dba
CW
8495#include <$ac_header>
8496_ACEOF
c0d27fcc 8497if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8498 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8499 ac_status=$?
6bae0ccf 8500 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8501 rm -f conftest.er1
8502 cat conftest.err >&5
c0d27fcc 8503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8504 (exit $ac_status); } >/dev/null; then
8505 if test -s conftest.err; then
8506 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 8507 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8508 else
8509 ac_cpp_err=
8510 fi
8511else
8512 ac_cpp_err=yes
8513fi
8514if test -z "$ac_cpp_err"; then
c0d27fcc 8515 ac_header_preproc=yes
98418dba
CW
8516else
8517 echo "$as_me: failed program was:" >&5
19650fd6
AS
8518sed 's/^/| /' conftest.$ac_ext >&5
8519
c0d27fcc 8520 ac_header_preproc=no
98418dba
CW
8521fi
8522rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8523echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8524echo "${ECHO_T}$ac_header_preproc" >&6
8525
8526# So? What about this header?
35996d22
AS
8527case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8528 yes:no: )
c0d27fcc
MR
8529 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8530echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
8531 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8532echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8533 ac_header_preproc=yes
19650fd6 8534 ;;
35996d22 8535 no:yes:* )
c0d27fcc
MR
8536 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8537echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
8538 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8539echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8540 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8541echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8542 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
8543echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 8544 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 8545echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
8546 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8547echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
8548 (
8549 cat <<\_ASBOX
35996d22
AS
8550## ------------------------------------------ ##
8551## Report this to the AC_PACKAGE_NAME lists. ##
8552## ------------------------------------------ ##
19650fd6
AS
8553_ASBOX
8554 ) |
8555 sed "s/^/$as_me: WARNING: /" >&2
8556 ;;
c0d27fcc
MR
8557esac
8558echo "$as_me:$LINENO: checking for $ac_header" >&5
8559echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8560if eval "test \"\${$as_ac_Header+set}\" = set"; then
8561 echo $ECHO_N "(cached) $ECHO_C" >&6
8562else
35996d22 8563 eval "$as_ac_Header=\$ac_header_preproc"
98418dba 8564fi
c0d27fcc 8565echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 8566echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
8567
8568fi
98418dba 8569if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 8570 cat >>confdefs.h <<_ACEOF
98418dba 8571#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 8572_ACEOF
98418dba
CW
8573
8574fi
c0d27fcc 8575
98418dba
CW
8576done
8577
c0d27fcc 8578
98418dba
CW
8579for ac_func in getpagesize
8580do
8581as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8582echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8583echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8584if eval "test \"\${$as_ac_var+set}\" = set"; then
8585 echo $ECHO_N "(cached) $ECHO_C" >&6
8586else
8587 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8588/* confdefs.h. */
8589_ACEOF
8590cat confdefs.h >>conftest.$ac_ext
8591cat >>conftest.$ac_ext <<_ACEOF
8592/* end confdefs.h. */
35996d22
AS
8593/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8594 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8595#define $ac_func innocuous_$ac_func
8596
98418dba 8597/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8598 which can conflict with char $ac_func (); below.
8599 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8600 <limits.h> exists even on freestanding compilers. */
35996d22 8601
19650fd6
AS
8602#ifdef __STDC__
8603# include <limits.h>
8604#else
8605# include <assert.h>
8606#endif
35996d22
AS
8607
8608#undef $ac_func
8609
98418dba
CW
8610/* Override any gcc2 internal prototype to avoid an error. */
8611#ifdef __cplusplus
8612extern "C"
19650fd6 8613{
98418dba
CW
8614#endif
8615/* We use char because int might match the return type of a gcc2
8616 builtin and then its argument prototype would still apply. */
8617char $ac_func ();
98418dba
CW
8618/* The GNU C library defines this for functions which it implements
8619 to always fail with ENOSYS. Some functions are actually named
8620 something starting with __ and the normal name is an alias. */
8621#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8622choke me
8623#else
19650fd6
AS
8624char (*f) () = $ac_func;
8625#endif
8626#ifdef __cplusplus
8627}
98418dba
CW
8628#endif
8629
19650fd6
AS
8630int
8631main ()
8632{
8633return f != $ac_func;
98418dba
CW
8634 ;
8635 return 0;
8636}
8637_ACEOF
8638rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8639if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8640 (eval $ac_link) 2>conftest.er1
98418dba 8641 ac_status=$?
35996d22
AS
8642 grep -v '^ *+' conftest.er1 >conftest.err
8643 rm -f conftest.er1
8644 cat conftest.err >&5
c0d27fcc 8645 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8646 (exit $ac_status); } &&
35996d22
AS
8647 { ac_try='test -z "$ac_c_werror_flag"
8648 || test ! -s conftest.err'
8649 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8650 (eval $ac_try) 2>&5
8651 ac_status=$?
8652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8653 (exit $ac_status); }; } &&
8654 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8655 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8656 (eval $ac_try) 2>&5
8657 ac_status=$?
c0d27fcc 8658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8659 (exit $ac_status); }; }; then
8660 eval "$as_ac_var=yes"
8661else
8662 echo "$as_me: failed program was:" >&5
19650fd6
AS
8663sed 's/^/| /' conftest.$ac_ext >&5
8664
98418dba
CW
8665eval "$as_ac_var=no"
8666fi
35996d22
AS
8667rm -f conftest.err conftest.$ac_objext \
8668 conftest$ac_exeext conftest.$ac_ext
98418dba 8669fi
c0d27fcc 8670echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
8671echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8672if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 8673 cat >>confdefs.h <<_ACEOF
98418dba 8674#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 8675_ACEOF
98418dba
CW
8676
8677fi
8678done
8679
c0d27fcc 8680echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
8681echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
8682if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8683 echo $ECHO_N "(cached) $ECHO_C" >&6
8684else
8685 if test "$cross_compiling" = yes; then
8686 ac_cv_func_mmap_fixed_mapped=no
8687else
8688 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8689/* confdefs.h. */
8690_ACEOF
8691cat confdefs.h >>conftest.$ac_ext
8692cat >>conftest.$ac_ext <<_ACEOF
8693/* end confdefs.h. */
98418dba 8694$ac_includes_default
c0d27fcc
MR
8695/* malloc might have been renamed as rpl_malloc. */
8696#undef malloc
8697
98418dba
CW
8698/* Thanks to Mike Haertel and Jim Avera for this test.
8699 Here is a matrix of mmap possibilities:
8700 mmap private not fixed
8701 mmap private fixed at somewhere currently unmapped
8702 mmap private fixed at somewhere already mapped
8703 mmap shared not fixed
8704 mmap shared fixed at somewhere currently unmapped
8705 mmap shared fixed at somewhere already mapped
8706 For private mappings, we should verify that changes cannot be read()
8707 back from the file, nor mmap's back from the file at a different
8708 address. (There have been systems where private was not correctly
8709 implemented like the infamous i386 svr4.0, and systems where the
8710 VM page cache was not coherent with the file system buffer cache
8711 like early versions of FreeBSD and possibly contemporary NetBSD.)
8712 For shared mappings, we should conversely verify that changes get
c0d27fcc 8713 propagated back to all the places they're supposed to be.
98418dba
CW
8714
8715 Grep wants private fixed already mapped.
8716 The main things grep needs to know about mmap are:
8717 * does it exist and is it safe to write into the mmap'd area
8718 * how to use it (BSD variants) */
8719
8720#include <fcntl.h>
8721#include <sys/mman.h>
8722
8723#if !STDC_HEADERS && !HAVE_STDLIB_H
8724char *malloc ();
8725#endif
8726
8727/* This mess was copied from the GNU getpagesize.h. */
8728#if !HAVE_GETPAGESIZE
8729/* Assume that all systems that can run configure have sys/param.h. */
8730# if !HAVE_SYS_PARAM_H
8731# define HAVE_SYS_PARAM_H 1
8732# endif
8733
8734# ifdef _SC_PAGESIZE
8735# define getpagesize() sysconf(_SC_PAGESIZE)
8736# else /* no _SC_PAGESIZE */
8737# if HAVE_SYS_PARAM_H
8738# include <sys/param.h>
8739# ifdef EXEC_PAGESIZE
8740# define getpagesize() EXEC_PAGESIZE
8741# else /* no EXEC_PAGESIZE */
8742# ifdef NBPG
8743# define getpagesize() NBPG * CLSIZE
8744# ifndef CLSIZE
8745# define CLSIZE 1
8746# endif /* no CLSIZE */
8747# else /* no NBPG */
8748# ifdef NBPC
8749# define getpagesize() NBPC
8750# else /* no NBPC */
8751# ifdef PAGESIZE
8752# define getpagesize() PAGESIZE
8753# endif /* PAGESIZE */
8754# endif /* no NBPC */
8755# endif /* no NBPG */
8756# endif /* no EXEC_PAGESIZE */
8757# else /* no HAVE_SYS_PARAM_H */
8758# define getpagesize() 8192 /* punt totally */
8759# endif /* no HAVE_SYS_PARAM_H */
8760# endif /* no _SC_PAGESIZE */
8761
8762#endif /* no HAVE_GETPAGESIZE */
8763
8764int
8765main ()
8766{
8767 char *data, *data2, *data3;
8768 int i, pagesize;
8769 int fd;
8770
8771 pagesize = getpagesize ();
8772
8773 /* First, make a file with some known garbage in it. */
8774 data = (char *) malloc (pagesize);
8775 if (!data)
8776 exit (1);
8777 for (i = 0; i < pagesize; ++i)
8778 *(data + i) = rand ();
8779 umask (0);
8780 fd = creat ("conftest.mmap", 0600);
8781 if (fd < 0)
8782 exit (1);
8783 if (write (fd, data, pagesize) != pagesize)
8784 exit (1);
8785 close (fd);
8786
8787 /* Next, try to mmap the file at a fixed address which already has
8788 something else allocated at it. If we can, also make sure that
8789 we see the same garbage. */
8790 fd = open ("conftest.mmap", O_RDWR);
8791 if (fd < 0)
8792 exit (1);
8793 data2 = (char *) malloc (2 * pagesize);
8794 if (!data2)
8795 exit (1);
35996d22 8796 data2 += (pagesize - ((long) data2 & (pagesize - 1))) & (pagesize - 1);
98418dba 8797 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
35996d22 8798 MAP_PRIVATE | MAP_FIXED, fd, 0L))
98418dba
CW
8799 exit (1);
8800 for (i = 0; i < pagesize; ++i)
8801 if (*(data + i) != *(data2 + i))
8802 exit (1);
8803
8804 /* Finally, make sure that changes to the mapped area do not
8805 percolate back to the file as seen by read(). (This is a bug on
8806 some variants of i386 svr4.0.) */
8807 for (i = 0; i < pagesize; ++i)
8808 *(data2 + i) = *(data2 + i) + 1;
8809 data3 = (char *) malloc (pagesize);
8810 if (!data3)
8811 exit (1);
8812 if (read (fd, data3, pagesize) != pagesize)
8813 exit (1);
8814 for (i = 0; i < pagesize; ++i)
8815 if (*(data + i) != *(data3 + i))
8816 exit (1);
8817 close (fd);
8818 exit (0);
8819}
8820_ACEOF
8821rm -f conftest$ac_exeext
c0d27fcc 8822if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8823 (eval $ac_link) 2>&5
8824 ac_status=$?
c0d27fcc 8825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8826 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 8827 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8828 (eval $ac_try) 2>&5
8829 ac_status=$?
c0d27fcc 8830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8831 (exit $ac_status); }; }; then
8832 ac_cv_func_mmap_fixed_mapped=yes
8833else
8834 echo "$as_me: program exited with status $ac_status" >&5
8835echo "$as_me: failed program was:" >&5
19650fd6
AS
8836sed 's/^/| /' conftest.$ac_ext >&5
8837
c0d27fcc 8838( exit $ac_status )
98418dba
CW
8839ac_cv_func_mmap_fixed_mapped=no
8840fi
35996d22 8841rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
8842fi
8843fi
c0d27fcc 8844echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
8845echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
8846if test $ac_cv_func_mmap_fixed_mapped = yes; then
8847
c0d27fcc 8848cat >>confdefs.h <<\_ACEOF
98418dba 8849#define HAVE_MMAP 1
c0d27fcc 8850_ACEOF
98418dba
CW
8851
8852fi
8853rm -f conftest.mmap
8854
8855if test $use_mmap_for_buffers = yes; then
8856 REL_ALLOC=no
8857fi
8858
8859LIBS="$libsrc_libs $LIBS"
8860
c0d27fcc
MR
8861
8862echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
8863echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
8864if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
8865 echo $ECHO_N "(cached) $ECHO_C" >&6
8866else
8867 ac_check_lib_save_LIBS=$LIBS
8868LIBS="-ldnet $LIBS"
8869cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8870/* confdefs.h. */
8871_ACEOF
8872cat confdefs.h >>conftest.$ac_ext
8873cat >>conftest.$ac_ext <<_ACEOF
8874/* end confdefs.h. */
98418dba
CW
8875
8876/* Override any gcc2 internal prototype to avoid an error. */
8877#ifdef __cplusplus
8878extern "C"
8879#endif
8880/* We use char because int might match the return type of a gcc2
8881 builtin and then its argument prototype would still apply. */
8882char dnet_ntoa ();
98418dba
CW
8883int
8884main ()
8885{
8886dnet_ntoa ();
8887 ;
8888 return 0;
8889}
8890_ACEOF
8891rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8892if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8893 (eval $ac_link) 2>conftest.er1
98418dba 8894 ac_status=$?
35996d22
AS
8895 grep -v '^ *+' conftest.er1 >conftest.err
8896 rm -f conftest.er1
8897 cat conftest.err >&5
c0d27fcc 8898 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8899 (exit $ac_status); } &&
35996d22
AS
8900 { ac_try='test -z "$ac_c_werror_flag"
8901 || test ! -s conftest.err'
8902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8903 (eval $ac_try) 2>&5
8904 ac_status=$?
8905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8906 (exit $ac_status); }; } &&
8907 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8908 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8909 (eval $ac_try) 2>&5
8910 ac_status=$?
c0d27fcc 8911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8912 (exit $ac_status); }; }; then
8913 ac_cv_lib_dnet_dnet_ntoa=yes
8914else
8915 echo "$as_me: failed program was:" >&5
19650fd6
AS
8916sed 's/^/| /' conftest.$ac_ext >&5
8917
98418dba
CW
8918ac_cv_lib_dnet_dnet_ntoa=no
8919fi
35996d22
AS
8920rm -f conftest.err conftest.$ac_objext \
8921 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8922LIBS=$ac_check_lib_save_LIBS
8923fi
c0d27fcc 8924echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
8925echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
8926if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 8927 cat >>confdefs.h <<_ACEOF
98418dba 8928#define HAVE_LIBDNET 1
c0d27fcc 8929_ACEOF
98418dba
CW
8930
8931 LIBS="-ldnet $LIBS"
8932
8933fi
8934
c0d27fcc
MR
8935
8936echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
8937echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
8938if test "${ac_cv_lib_Xbsd_main+set}" = set; then
8939 echo $ECHO_N "(cached) $ECHO_C" >&6
8940else
8941 ac_check_lib_save_LIBS=$LIBS
8942LIBS="-lXbsd $LIBS"
8943cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8944/* confdefs.h. */
8945_ACEOF
8946cat confdefs.h >>conftest.$ac_ext
8947cat >>conftest.$ac_ext <<_ACEOF
8948/* end confdefs.h. */
98418dba 8949
c0d27fcc 8950
98418dba
CW
8951int
8952main ()
8953{
8954main ();
8955 ;
8956 return 0;
8957}
8958_ACEOF
8959rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8960if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8961 (eval $ac_link) 2>conftest.er1
98418dba 8962 ac_status=$?
35996d22
AS
8963 grep -v '^ *+' conftest.er1 >conftest.err
8964 rm -f conftest.er1
8965 cat conftest.err >&5
c0d27fcc 8966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8967 (exit $ac_status); } &&
35996d22
AS
8968 { ac_try='test -z "$ac_c_werror_flag"
8969 || test ! -s conftest.err'
8970 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8971 (eval $ac_try) 2>&5
8972 ac_status=$?
8973 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8974 (exit $ac_status); }; } &&
8975 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8976 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8977 (eval $ac_try) 2>&5
8978 ac_status=$?
c0d27fcc 8979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8980 (exit $ac_status); }; }; then
8981 ac_cv_lib_Xbsd_main=yes
8982else
8983 echo "$as_me: failed program was:" >&5
19650fd6
AS
8984sed 's/^/| /' conftest.$ac_ext >&5
8985
98418dba
CW
8986ac_cv_lib_Xbsd_main=no
8987fi
35996d22
AS
8988rm -f conftest.err conftest.$ac_objext \
8989 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8990LIBS=$ac_check_lib_save_LIBS
8991fi
c0d27fcc 8992echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
8993echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
8994if test $ac_cv_lib_Xbsd_main = yes; then
8995 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
8996fi
8997
c0d27fcc
MR
8998
8999
9000echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
9001echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
9002if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
9003 echo $ECHO_N "(cached) $ECHO_C" >&6
9004else
9005 ac_check_lib_save_LIBS=$LIBS
9006LIBS="-lpthreads $LIBS"
9007cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9008/* confdefs.h. */
9009_ACEOF
9010cat confdefs.h >>conftest.$ac_ext
9011cat >>conftest.$ac_ext <<_ACEOF
9012/* end confdefs.h. */
98418dba
CW
9013
9014/* Override any gcc2 internal prototype to avoid an error. */
9015#ifdef __cplusplus
9016extern "C"
9017#endif
9018/* We use char because int might match the return type of a gcc2
9019 builtin and then its argument prototype would still apply. */
9020char cma_open ();
98418dba
CW
9021int
9022main ()
9023{
9024cma_open ();
9025 ;
9026 return 0;
9027}
9028_ACEOF
9029rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9030if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9031 (eval $ac_link) 2>conftest.er1
98418dba 9032 ac_status=$?
35996d22
AS
9033 grep -v '^ *+' conftest.er1 >conftest.err
9034 rm -f conftest.er1
9035 cat conftest.err >&5
c0d27fcc 9036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9037 (exit $ac_status); } &&
35996d22
AS
9038 { ac_try='test -z "$ac_c_werror_flag"
9039 || test ! -s conftest.err'
9040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9041 (eval $ac_try) 2>&5
9042 ac_status=$?
9043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9044 (exit $ac_status); }; } &&
9045 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9046 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9047 (eval $ac_try) 2>&5
9048 ac_status=$?
c0d27fcc 9049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9050 (exit $ac_status); }; }; then
9051 ac_cv_lib_pthreads_cma_open=yes
9052else
9053 echo "$as_me: failed program was:" >&5
19650fd6
AS
9054sed 's/^/| /' conftest.$ac_ext >&5
9055
98418dba
CW
9056ac_cv_lib_pthreads_cma_open=no
9057fi
35996d22
AS
9058rm -f conftest.err conftest.$ac_objext \
9059 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9060LIBS=$ac_check_lib_save_LIBS
9061fi
c0d27fcc 9062echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
9063echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
9064if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 9065 cat >>confdefs.h <<_ACEOF
98418dba 9066#define HAVE_LIBPTHREADS 1
c0d27fcc 9067_ACEOF
98418dba
CW
9068
9069 LIBS="-lpthreads $LIBS"
9070
9071fi
9072
c0d27fcc
MR
9073
9074echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
9075echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
9076if test -d /usr/X386/include; then
9077 HAVE_XFREE386=yes
9078 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
9079else
9080 HAVE_XFREE386=no
9081fi
c0d27fcc 9082echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
9083echo "${ECHO_T}$HAVE_XFREE386" >&6
9084
55597d70
DL
9085
9086case ${host_os} in
9087aix*)
9088 echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
9089echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
9090if test "${gdb_cv_bigtoc+set}" = set; then
9091 echo $ECHO_N "(cached) $ECHO_C" >&6
9092else
9093
9094 case $GCC in
9095 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
9096 *) gdb_cv_bigtoc=-bbigtoc ;;
9097 esac
9098
9099 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
9100 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9101/* confdefs.h. */
9102_ACEOF
9103cat confdefs.h >>conftest.$ac_ext
9104cat >>conftest.$ac_ext <<_ACEOF
9105/* end confdefs.h. */
55597d70
DL
9106
9107int
9108main ()
9109{
9110int i;
9111 ;
9112 return 0;
9113}
9114_ACEOF
9115rm -f conftest.$ac_objext conftest$ac_exeext
9116if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9117 (eval $ac_link) 2>conftest.er1
55597d70 9118 ac_status=$?
35996d22
AS
9119 grep -v '^ *+' conftest.er1 >conftest.err
9120 rm -f conftest.er1
9121 cat conftest.err >&5
55597d70
DL
9122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9123 (exit $ac_status); } &&
35996d22
AS
9124 { ac_try='test -z "$ac_c_werror_flag"
9125 || test ! -s conftest.err'
9126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9127 (eval $ac_try) 2>&5
9128 ac_status=$?
9129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9130 (exit $ac_status); }; } &&
9131 { ac_try='test -s conftest$ac_exeext'
55597d70
DL
9132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9133 (eval $ac_try) 2>&5
9134 ac_status=$?
9135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9136 (exit $ac_status); }; }; then
9137 :
9138else
9139 echo "$as_me: failed program was:" >&5
19650fd6
AS
9140sed 's/^/| /' conftest.$ac_ext >&5
9141
55597d70
DL
9142gdb_cv_bigtoc=
9143fi
35996d22
AS
9144rm -f conftest.err conftest.$ac_objext \
9145 conftest$ac_exeext conftest.$ac_ext
55597d70
DL
9146
9147fi
9148echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
9149echo "${ECHO_T}$gdb_cv_bigtoc" >&6
9150 ;;
9151esac
9152
ae1a998c
RS
9153# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
9154# used for the tests that follow. We set them back to REAL_CFLAGS and
9155# REAL_CPPFLAGS later on.
98418dba
CW
9156
9157REAL_CPPFLAGS="$CPPFLAGS"
9158
9159if test "${HAVE_X11}" = "yes"; then
9160 DEFS="$C_SWITCH_X_SITE $DEFS"
9161 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
9162 LIBS="$LIBX $LIBS"
9163 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
9164 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
9165
9166 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
9167 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
9168 # but it's more convenient here to set LD_RUN_PATH
9169 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
9170 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
9171 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
9172 export LD_RUN_PATH
9173 fi
9174
9175 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 9176 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
9177echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
9178 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9179/* confdefs.h. */
9180_ACEOF
9181cat confdefs.h >>conftest.$ac_ext
9182cat >>conftest.$ac_ext <<_ACEOF
9183/* end confdefs.h. */
98418dba 9184
98418dba
CW
9185int
9186main ()
9187{
9188XOpenDisplay ("foo");
9189 ;
9190 return 0;
9191}
9192_ACEOF
9193rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9194if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9195 (eval $ac_link) 2>conftest.er1
98418dba 9196 ac_status=$?
35996d22
AS
9197 grep -v '^ *+' conftest.er1 >conftest.err
9198 rm -f conftest.er1
9199 cat conftest.err >&5
c0d27fcc 9200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9201 (exit $ac_status); } &&
35996d22
AS
9202 { ac_try='test -z "$ac_c_werror_flag"
9203 || test ! -s conftest.err'
c0d27fcc 9204 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9205 (eval $ac_try) 2>&5
9206 ac_status=$?
c0d27fcc 9207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
9208 (exit $ac_status); }; } &&
9209 { ac_try='test -s conftest$ac_exeext'
9210 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9211 (eval $ac_try) 2>&5
9212 ac_status=$?
9213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9214 (exit $ac_status); }; }; then
9215 xlinux_first_failure=no
98418dba
CW
9216else
9217 echo "$as_me: failed program was:" >&5
19650fd6
AS
9218sed 's/^/| /' conftest.$ac_ext >&5
9219
98418dba
CW
9220xlinux_first_failure=yes
9221fi
35996d22
AS
9222rm -f conftest.err conftest.$ac_objext \
9223 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9224 if test "${xlinux_first_failure}" = "yes"; then
9225 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
9226 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
9227 OLD_CPPFLAGS="$CPPFLAGS"
9228 OLD_LIBS="$LIBS"
9229 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
9230 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
9231 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
9232 LIBS="$LIBS -b i486-linuxaout"
9233 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9234/* confdefs.h. */
9235_ACEOF
9236cat confdefs.h >>conftest.$ac_ext
9237cat >>conftest.$ac_ext <<_ACEOF
9238/* end confdefs.h. */
98418dba 9239
98418dba
CW
9240int
9241main ()
9242{
9243XOpenDisplay ("foo");
9244 ;
9245 return 0;
9246}
9247_ACEOF
9248rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9249if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9250 (eval $ac_link) 2>conftest.er1
98418dba 9251 ac_status=$?
35996d22
AS
9252 grep -v '^ *+' conftest.er1 >conftest.err
9253 rm -f conftest.er1
9254 cat conftest.err >&5
c0d27fcc 9255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9256 (exit $ac_status); } &&
35996d22
AS
9257 { ac_try='test -z "$ac_c_werror_flag"
9258 || test ! -s conftest.err'
9259 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9260 (eval $ac_try) 2>&5
9261 ac_status=$?
9262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9263 (exit $ac_status); }; } &&
9264 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9266 (eval $ac_try) 2>&5
9267 ac_status=$?
c0d27fcc 9268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9269 (exit $ac_status); }; }; then
9270 xlinux_second_failure=no
9271else
9272 echo "$as_me: failed program was:" >&5
19650fd6
AS
9273sed 's/^/| /' conftest.$ac_ext >&5
9274
98418dba
CW
9275xlinux_second_failure=yes
9276fi
35996d22
AS
9277rm -f conftest.err conftest.$ac_objext \
9278 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9279 if test "${xlinux_second_failure}" = "yes"; then
9280 # If we get the same failure with -b, there is no use adding -b.
9281 # So take it out. This plays safe.
9282 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
9283 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
9284 CPPFLAGS="$OLD_CPPFLAGS"
9285 LIBS="$OLD_LIBS"
c0d27fcc 9286 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9287echo "${ECHO_T}no" >&6
9288 else
c0d27fcc 9289 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9290echo "${ECHO_T}yes" >&6
9291 fi
9292 else
c0d27fcc 9293 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9294echo "${ECHO_T}no" >&6
9295 fi
9296 fi
9297
9298 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
9299 # header files included from there.
c0d27fcc 9300 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
9301echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
9302 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9303/* confdefs.h. */
9304_ACEOF
9305cat confdefs.h >>conftest.$ac_ext
9306cat >>conftest.$ac_ext <<_ACEOF
9307/* end confdefs.h. */
98418dba
CW
9308#include <X11/Xlib.h>
9309#include <X11/XKBlib.h>
98418dba
CW
9310int
9311main ()
9312{
9313XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
9314 ;
9315 return 0;
9316}
9317_ACEOF
9318rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9319if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9320 (eval $ac_link) 2>conftest.er1
98418dba 9321 ac_status=$?
35996d22
AS
9322 grep -v '^ *+' conftest.er1 >conftest.err
9323 rm -f conftest.er1
9324 cat conftest.err >&5
c0d27fcc 9325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9326 (exit $ac_status); } &&
35996d22
AS
9327 { ac_try='test -z "$ac_c_werror_flag"
9328 || test ! -s conftest.err'
9329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9330 (eval $ac_try) 2>&5
9331 ac_status=$?
9332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9333 (exit $ac_status); }; } &&
9334 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9336 (eval $ac_try) 2>&5
9337 ac_status=$?
c0d27fcc 9338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9339 (exit $ac_status); }; }; then
9340 emacs_xkb=yes
9341else
9342 echo "$as_me: failed program was:" >&5
19650fd6
AS
9343sed 's/^/| /' conftest.$ac_ext >&5
9344
98418dba
CW
9345emacs_xkb=no
9346fi
35996d22
AS
9347rm -f conftest.err conftest.$ac_objext \
9348 conftest$ac_exeext conftest.$ac_ext
c0d27fcc 9349 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
9350echo "${ECHO_T}$emacs_xkb" >&6
9351 if test $emacs_xkb = yes; then
b936fae4 9352
c0d27fcc 9353cat >>confdefs.h <<\_ACEOF
98418dba 9354#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 9355_ACEOF
98418dba
CW
9356
9357 fi
9358
c0d27fcc
MR
9359
9360
9361
9362
98418dba
CW
9363for ac_func in XrmSetDatabase XScreenResourceString \
9364XScreenNumberOfScreen XSetWMProtocols
9365do
9366as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 9367echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
9368echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9369if eval "test \"\${$as_ac_var+set}\" = set"; then
9370 echo $ECHO_N "(cached) $ECHO_C" >&6
9371else
9372 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9373/* confdefs.h. */
9374_ACEOF
9375cat confdefs.h >>conftest.$ac_ext
9376cat >>conftest.$ac_ext <<_ACEOF
9377/* end confdefs.h. */
35996d22
AS
9378/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9379 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9380#define $ac_func innocuous_$ac_func
9381
98418dba 9382/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
9383 which can conflict with char $ac_func (); below.
9384 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9385 <limits.h> exists even on freestanding compilers. */
35996d22 9386
19650fd6
AS
9387#ifdef __STDC__
9388# include <limits.h>
9389#else
9390# include <assert.h>
9391#endif
35996d22
AS
9392
9393#undef $ac_func
9394
98418dba
CW
9395/* Override any gcc2 internal prototype to avoid an error. */
9396#ifdef __cplusplus
9397extern "C"
19650fd6 9398{
98418dba
CW
9399#endif
9400/* We use char because int might match the return type of a gcc2
9401 builtin and then its argument prototype would still apply. */
9402char $ac_func ();
98418dba
CW
9403/* The GNU C library defines this for functions which it implements
9404 to always fail with ENOSYS. Some functions are actually named
9405 something starting with __ and the normal name is an alias. */
9406#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9407choke me
9408#else
19650fd6
AS
9409char (*f) () = $ac_func;
9410#endif
9411#ifdef __cplusplus
9412}
98418dba
CW
9413#endif
9414
19650fd6
AS
9415int
9416main ()
9417{
9418return f != $ac_func;
98418dba
CW
9419 ;
9420 return 0;
9421}
9422_ACEOF
9423rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9424if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9425 (eval $ac_link) 2>conftest.er1
98418dba 9426 ac_status=$?
35996d22
AS
9427 grep -v '^ *+' conftest.er1 >conftest.err
9428 rm -f conftest.er1
9429 cat conftest.err >&5
c0d27fcc 9430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9431 (exit $ac_status); } &&
35996d22
AS
9432 { ac_try='test -z "$ac_c_werror_flag"
9433 || test ! -s conftest.err'
9434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9435 (eval $ac_try) 2>&5
9436 ac_status=$?
9437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9438 (exit $ac_status); }; } &&
9439 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9440 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9441 (eval $ac_try) 2>&5
9442 ac_status=$?
c0d27fcc 9443 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9444 (exit $ac_status); }; }; then
9445 eval "$as_ac_var=yes"
9446else
9447 echo "$as_me: failed program was:" >&5
19650fd6
AS
9448sed 's/^/| /' conftest.$ac_ext >&5
9449
98418dba
CW
9450eval "$as_ac_var=no"
9451fi
35996d22
AS
9452rm -f conftest.err conftest.$ac_objext \
9453 conftest$ac_exeext conftest.$ac_ext
98418dba 9454fi
c0d27fcc 9455echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
9456echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9457if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 9458 cat >>confdefs.h <<_ACEOF
98418dba 9459#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 9460_ACEOF
98418dba
CW
9461
9462fi
9463done
9464
9465fi
9466
9467if test "${window_system}" = "x11"; then
c0d27fcc 9468 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
9469echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
9470 if test "${emacs_cv_x11_version_6+set}" = set; then
9471 echo $ECHO_N "(cached) $ECHO_C" >&6
9472else
9473 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9474/* confdefs.h. */
9475_ACEOF
9476cat confdefs.h >>conftest.$ac_ext
9477cat >>conftest.$ac_ext <<_ACEOF
9478/* end confdefs.h. */
98418dba 9479#include <X11/Xlib.h>
98418dba
CW
9480int
9481main ()
9482{
9483#if XlibSpecificationRelease < 6
9484fail;
9485#endif
9486
9487 ;
9488 return 0;
9489}
9490_ACEOF
9491rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9492if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9493 (eval $ac_link) 2>conftest.er1
98418dba 9494 ac_status=$?
35996d22
AS
9495 grep -v '^ *+' conftest.er1 >conftest.err
9496 rm -f conftest.er1
9497 cat conftest.err >&5
c0d27fcc 9498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9499 (exit $ac_status); } &&
35996d22
AS
9500 { ac_try='test -z "$ac_c_werror_flag"
9501 || test ! -s conftest.err'
9502 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9503 (eval $ac_try) 2>&5
9504 ac_status=$?
9505 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9506 (exit $ac_status); }; } &&
9507 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9508 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9509 (eval $ac_try) 2>&5
9510 ac_status=$?
c0d27fcc 9511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9512 (exit $ac_status); }; }; then
9513 emacs_cv_x11_version_6=yes
9514else
9515 echo "$as_me: failed program was:" >&5
19650fd6
AS
9516sed 's/^/| /' conftest.$ac_ext >&5
9517
98418dba
CW
9518emacs_cv_x11_version_6=no
9519fi
35996d22
AS
9520rm -f conftest.err conftest.$ac_objext \
9521 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9522fi
9523
9524 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 9525 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9526echo "${ECHO_T}6 or newer" >&6
b936fae4 9527
c0d27fcc 9528cat >>confdefs.h <<\_ACEOF
98418dba 9529#define HAVE_X11R6 1
c0d27fcc 9530_ACEOF
98418dba
CW
9531
9532 else
c0d27fcc 9533 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9534echo "${ECHO_T}before 6" >&6
9535 fi
9536fi
9537
9538if test "${window_system}" = "x11"; then
c0d27fcc 9539 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
9540echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
9541 if test "${emacs_cv_x11_version_5+set}" = set; then
9542 echo $ECHO_N "(cached) $ECHO_C" >&6
9543else
9544 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9545/* confdefs.h. */
9546_ACEOF
9547cat confdefs.h >>conftest.$ac_ext
9548cat >>conftest.$ac_ext <<_ACEOF
9549/* end confdefs.h. */
98418dba 9550#include <X11/Xlib.h>
98418dba
CW
9551int
9552main ()
9553{
9554#if XlibSpecificationRelease < 5
9555fail;
9556#endif
9557
9558 ;
9559 return 0;
9560}
9561_ACEOF
9562rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9563if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9564 (eval $ac_link) 2>conftest.er1
98418dba 9565 ac_status=$?
35996d22
AS
9566 grep -v '^ *+' conftest.er1 >conftest.err
9567 rm -f conftest.er1
9568 cat conftest.err >&5
c0d27fcc 9569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9570 (exit $ac_status); } &&
35996d22
AS
9571 { ac_try='test -z "$ac_c_werror_flag"
9572 || test ! -s conftest.err'
9573 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9574 (eval $ac_try) 2>&5
9575 ac_status=$?
9576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9577 (exit $ac_status); }; } &&
9578 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9579 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9580 (eval $ac_try) 2>&5
9581 ac_status=$?
c0d27fcc 9582 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9583 (exit $ac_status); }; }; then
9584 emacs_cv_x11_version_5=yes
9585else
9586 echo "$as_me: failed program was:" >&5
19650fd6
AS
9587sed 's/^/| /' conftest.$ac_ext >&5
9588
98418dba
CW
9589emacs_cv_x11_version_5=no
9590fi
35996d22
AS
9591rm -f conftest.err conftest.$ac_objext \
9592 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9593fi
9594
9595 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 9596 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
9597echo "${ECHO_T}5 or newer" >&6
9598 HAVE_X11R5=yes
b936fae4 9599
c0d27fcc 9600cat >>confdefs.h <<\_ACEOF
98418dba 9601#define HAVE_X11R5 1
c0d27fcc 9602_ACEOF
98418dba
CW
9603
9604 else
9605 HAVE_X11R5=no
c0d27fcc 9606 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
9607echo "${ECHO_T}before 5" >&6
9608 fi
9609fi
9610
488dd4c4
JD
9611
9612
9613HAVE_GTK=no
9614if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 9615 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
9616 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
9617echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
9618 { (exit 1); exit 1; }; };
9619 fi
9620 GLIB_REQUIRED=2.0.1
e512ece1 9621 GTK_REQUIRED=2.0.1
488dd4c4
JD
9622 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
9623
9624 if test "X${with_pkg_config_prog}" != X; then
9625 PKG_CONFIG="${with_pkg_config_prog}"
9626 fi
9627
9628 succeeded=no
9629
9630 if test -z "$PKG_CONFIG"; then
9631 # Extract the first word of "pkg-config", so it can be a program name with args.
9632set dummy pkg-config; ac_word=$2
9633echo "$as_me:$LINENO: checking for $ac_word" >&5
9634echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9635if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9636 echo $ECHO_N "(cached) $ECHO_C" >&6
9637else
9638 case $PKG_CONFIG in
9639 [\\/]* | ?:[\\/]*)
9640 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9641 ;;
9642 *)
9643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9644for as_dir in $PATH
9645do
9646 IFS=$as_save_IFS
9647 test -z "$as_dir" && as_dir=.
9648 for ac_exec_ext in '' $ac_executable_extensions; do
9649 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9650 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9651 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9652 break 2
9653 fi
9654done
9655done
9656
9657 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9658 ;;
9659esac
9660fi
9661PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9662
9663if test -n "$PKG_CONFIG"; then
9664 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
9665echo "${ECHO_T}$PKG_CONFIG" >&6
9666else
9667 echo "$as_me:$LINENO: result: no" >&5
9668echo "${ECHO_T}no" >&6
9669fi
9670
9671 fi
9672
9673 if test "$PKG_CONFIG" = "no" ; then
9674 echo "*** The pkg-config script could not be found. Make sure it is"
9675 echo "*** in your path, or give the full path to pkg-config with"
9676 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
9677 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
9678 else
9679 PKG_CONFIG_MIN_VERSION=0.9.0
9680 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9681 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
9682echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
9683
9684 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
9685 echo "$as_me:$LINENO: result: yes" >&5
9686echo "${ECHO_T}yes" >&6
9687 succeeded=yes
9688
9689 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
9690echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
9691 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
9692 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
9693echo "${ECHO_T}$GTK_CFLAGS" >&6
9694
9695 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
9696echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
9697 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
9698 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
9699echo "${ECHO_T}$GTK_LIBS" >&6
9700 else
9701 GTK_CFLAGS=""
9702 GTK_LIBS=""
9703 ## If we have a custom action on failure, don't print errors, but
9704 ## do set a variable so people can do so.
9705 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
9706 echo $GTK_PKG_ERRORS
9707 fi
9708
9709
9710
9711 else
9712 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9713 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9714 fi
9715 fi
9716
9717 if test $succeeded = yes; then
9718 :
9719 else
9720 { { echo "$as_me:$LINENO: error: Library requirements ($GTK_MODULES) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them." >&5
9721echo "$as_me: error: Library requirements ($GTK_MODULES) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them." >&2;}
9722 { (exit 1); exit 1; }; }
9723 fi
9724
9725
9726
9727 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
57669b57
JD
9728 CFLAGS="$CFLAGS $GTK_CFLAGS"
9729 LIBS="$GTK_LIBS $LIBS"
488dd4c4
JD
9730 HAVE_GTK=yes
9731
9732cat >>confdefs.h <<\_ACEOF
9733#define HAVE_GTK 1
9734_ACEOF
9735
9736 USE_X_TOOLKIT=none
9737
9738 with_toolkit_scroll_bars=yes
57669b57
JD
9739
9740 HAVE_GTK_MULTIDISPLAY=no
9741
9742for ac_func in gdk_display_open
9743do
9744as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9745echo "$as_me:$LINENO: checking for $ac_func" >&5
9746echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9747if eval "test \"\${$as_ac_var+set}\" = set"; then
9748 echo $ECHO_N "(cached) $ECHO_C" >&6
9749else
9750 cat >conftest.$ac_ext <<_ACEOF
57669b57
JD
9751/* confdefs.h. */
9752_ACEOF
9753cat confdefs.h >>conftest.$ac_ext
9754cat >>conftest.$ac_ext <<_ACEOF
9755/* end confdefs.h. */
35996d22
AS
9756/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9757 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9758#define $ac_func innocuous_$ac_func
9759
57669b57
JD
9760/* System header to define __stub macros and hopefully few prototypes,
9761 which can conflict with char $ac_func (); below.
9762 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9763 <limits.h> exists even on freestanding compilers. */
35996d22 9764
57669b57
JD
9765#ifdef __STDC__
9766# include <limits.h>
9767#else
9768# include <assert.h>
9769#endif
35996d22
AS
9770
9771#undef $ac_func
9772
57669b57
JD
9773/* Override any gcc2 internal prototype to avoid an error. */
9774#ifdef __cplusplus
9775extern "C"
9776{
9777#endif
9778/* We use char because int might match the return type of a gcc2
9779 builtin and then its argument prototype would still apply. */
9780char $ac_func ();
9781/* The GNU C library defines this for functions which it implements
9782 to always fail with ENOSYS. Some functions are actually named
9783 something starting with __ and the normal name is an alias. */
9784#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9785choke me
9786#else
9787char (*f) () = $ac_func;
9788#endif
9789#ifdef __cplusplus
9790}
9791#endif
9792
9793int
9794main ()
9795{
9796return f != $ac_func;
9797 ;
9798 return 0;
9799}
9800_ACEOF
9801rm -f conftest.$ac_objext conftest$ac_exeext
9802if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9803 (eval $ac_link) 2>conftest.er1
57669b57 9804 ac_status=$?
35996d22
AS
9805 grep -v '^ *+' conftest.er1 >conftest.err
9806 rm -f conftest.er1
9807 cat conftest.err >&5
57669b57
JD
9808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9809 (exit $ac_status); } &&
35996d22
AS
9810 { ac_try='test -z "$ac_c_werror_flag"
9811 || test ! -s conftest.err'
9812 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9813 (eval $ac_try) 2>&5
9814 ac_status=$?
9815 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9816 (exit $ac_status); }; } &&
9817 { ac_try='test -s conftest$ac_exeext'
57669b57
JD
9818 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9819 (eval $ac_try) 2>&5
9820 ac_status=$?
9821 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9822 (exit $ac_status); }; }; then
9823 eval "$as_ac_var=yes"
9824else
9825 echo "$as_me: failed program was:" >&5
9826sed 's/^/| /' conftest.$ac_ext >&5
9827
9828eval "$as_ac_var=no"
9829fi
35996d22
AS
9830rm -f conftest.err conftest.$ac_objext \
9831 conftest$ac_exeext conftest.$ac_ext
57669b57
JD
9832fi
9833echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9834echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9835if test `eval echo '${'$as_ac_var'}'` = yes; then
9836 cat >>confdefs.h <<_ACEOF
9837#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9838_ACEOF
9839 HAVE_GTK_MULTIDISPLAY=yes
9840fi
9841done
9842
9843 if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
9844
9845cat >>confdefs.h <<\_ACEOF
9846#define HAVE_GTK_MULTIDISPLAY 1
9847_ACEOF
9848
9849 fi
488dd4c4
JD
9850fi
9851
98418dba
CW
9852if test x"${USE_X_TOOLKIT}" = xmaybe; then
9853 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 9854 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
9855echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
9856 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
9857 echo $ECHO_N "(cached) $ECHO_C" >&6
9858else
9859 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9860/* confdefs.h. */
9861_ACEOF
9862cat confdefs.h >>conftest.$ac_ext
9863cat >>conftest.$ac_ext <<_ACEOF
9864/* end confdefs.h. */
98418dba
CW
9865
9866#include <X11/Intrinsic.h>
9867#include <X11/Xaw/Simple.h>
98418dba
CW
9868int
9869main ()
9870{
9871
9872 ;
9873 return 0;
9874}
9875_ACEOF
9876rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9877if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9878 (eval $ac_link) 2>conftest.er1
98418dba 9879 ac_status=$?
35996d22
AS
9880 grep -v '^ *+' conftest.er1 >conftest.err
9881 rm -f conftest.er1
9882 cat conftest.err >&5
c0d27fcc 9883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9884 (exit $ac_status); } &&
35996d22
AS
9885 { ac_try='test -z "$ac_c_werror_flag"
9886 || test ! -s conftest.err'
9887 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9888 (eval $ac_try) 2>&5
9889 ac_status=$?
9890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9891 (exit $ac_status); }; } &&
9892 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9893 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9894 (eval $ac_try) 2>&5
9895 ac_status=$?
c0d27fcc 9896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9897 (exit $ac_status); }; }; then
9898 emacs_cv_x11_version_5_with_xaw=yes
9899else
9900 echo "$as_me: failed program was:" >&5
19650fd6
AS
9901sed 's/^/| /' conftest.$ac_ext >&5
9902
98418dba
CW
9903emacs_cv_x11_version_5_with_xaw=no
9904fi
35996d22
AS
9905rm -f conftest.err conftest.$ac_objext \
9906 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9907fi
9908
9909 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 9910 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
9911echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
9912 USE_X_TOOLKIT=LUCID
9913 else
c0d27fcc 9914 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
9915echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
9916 USE_X_TOOLKIT=none
9917 fi
9918 else
9919 USE_X_TOOLKIT=none
9920 fi
9921fi
9922
9923X_TOOLKIT_TYPE=$USE_X_TOOLKIT
9924
9925if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 9926 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
9927echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
9928 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
9929 echo $ECHO_N "(cached) $ECHO_C" >&6
9930else
9931 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9932/* confdefs.h. */
9933_ACEOF
9934cat confdefs.h >>conftest.$ac_ext
9935cat >>conftest.$ac_ext <<_ACEOF
9936/* end confdefs.h. */
98418dba 9937#include <X11/Intrinsic.h>
98418dba
CW
9938int
9939main ()
9940{
9941#if XtSpecificationRelease < 6
9942fail;
9943#endif
9944
9945 ;
9946 return 0;
9947}
9948_ACEOF
9949rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9950if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9951 (eval $ac_link) 2>conftest.er1
98418dba 9952 ac_status=$?
35996d22
AS
9953 grep -v '^ *+' conftest.er1 >conftest.err
9954 rm -f conftest.er1
9955 cat conftest.err >&5
c0d27fcc 9956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9957 (exit $ac_status); } &&
35996d22
AS
9958 { ac_try='test -z "$ac_c_werror_flag"
9959 || test ! -s conftest.err'
9960 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9961 (eval $ac_try) 2>&5
9962 ac_status=$?
9963 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9964 (exit $ac_status); }; } &&
9965 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9966 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9967 (eval $ac_try) 2>&5
9968 ac_status=$?
c0d27fcc 9969 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9970 (exit $ac_status); }; }; then
9971 emacs_cv_x11_toolkit_version_6=yes
9972else
9973 echo "$as_me: failed program was:" >&5
19650fd6
AS
9974sed 's/^/| /' conftest.$ac_ext >&5
9975
98418dba
CW
9976emacs_cv_x11_toolkit_version_6=no
9977fi
35996d22
AS
9978rm -f conftest.err conftest.$ac_objext \
9979 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9980fi
9981
9982 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
9983 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 9984 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9985echo "${ECHO_T}6 or newer" >&6
b936fae4 9986
c0d27fcc 9987cat >>confdefs.h <<\_ACEOF
98418dba 9988#define HAVE_X11XTR6 1
c0d27fcc 9989_ACEOF
98418dba
CW
9990
9991 else
c0d27fcc 9992 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9993echo "${ECHO_T}before 6" >&6
9994 fi
9995
9996 OLDLIBS="$LIBS"
9997 if test x$HAVE_X11XTR6 = xyes; then
9998 LIBS="-lXt -lSM -lICE $LIBS"
9999 else
10000 LIBS="-lXt $LIBS"
10001 fi
10002
c0d27fcc 10003echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
10004echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
10005if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
10006 echo $ECHO_N "(cached) $ECHO_C" >&6
10007else
10008 ac_check_lib_save_LIBS=$LIBS
10009LIBS="-lXmu $LIBS"
10010cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10011/* confdefs.h. */
10012_ACEOF
10013cat confdefs.h >>conftest.$ac_ext
10014cat >>conftest.$ac_ext <<_ACEOF
10015/* end confdefs.h. */
98418dba
CW
10016
10017/* Override any gcc2 internal prototype to avoid an error. */
10018#ifdef __cplusplus
10019extern "C"
10020#endif
10021/* We use char because int might match the return type of a gcc2
10022 builtin and then its argument prototype would still apply. */
10023char XmuConvertStandardSelection ();
98418dba
CW
10024int
10025main ()
10026{
10027XmuConvertStandardSelection ();
10028 ;
10029 return 0;
10030}
10031_ACEOF
10032rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10033if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10034 (eval $ac_link) 2>conftest.er1
98418dba 10035 ac_status=$?
35996d22
AS
10036 grep -v '^ *+' conftest.er1 >conftest.err
10037 rm -f conftest.er1
10038 cat conftest.err >&5
c0d27fcc 10039 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10040 (exit $ac_status); } &&
35996d22
AS
10041 { ac_try='test -z "$ac_c_werror_flag"
10042 || test ! -s conftest.err'
10043 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10044 (eval $ac_try) 2>&5
10045 ac_status=$?
10046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10047 (exit $ac_status); }; } &&
10048 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10050 (eval $ac_try) 2>&5
10051 ac_status=$?
c0d27fcc 10052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10053 (exit $ac_status); }; }; then
10054 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
10055else
10056 echo "$as_me: failed program was:" >&5
19650fd6
AS
10057sed 's/^/| /' conftest.$ac_ext >&5
10058
98418dba
CW
10059ac_cv_lib_Xmu_XmuConvertStandardSelection=no
10060fi
35996d22
AS
10061rm -f conftest.err conftest.$ac_objext \
10062 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10063LIBS=$ac_check_lib_save_LIBS
10064fi
c0d27fcc 10065echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
10066echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
10067if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 10068 cat >>confdefs.h <<_ACEOF
98418dba 10069#define HAVE_LIBXMU 1
c0d27fcc 10070_ACEOF
98418dba
CW
10071
10072 LIBS="-lXmu $LIBS"
10073
10074fi
10075
10076 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
10077fi
10078
10079# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
10080if test "${HAVE_X11}" = "yes"; then
10081 if test "${USE_X_TOOLKIT}" != "none"; then
10082
c0d27fcc 10083echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
10084echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
10085if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
10086 echo $ECHO_N "(cached) $ECHO_C" >&6
10087else
10088 ac_check_lib_save_LIBS=$LIBS
10089LIBS="-lXext $LIBS"
10090cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10091/* confdefs.h. */
10092_ACEOF
10093cat confdefs.h >>conftest.$ac_ext
10094cat >>conftest.$ac_ext <<_ACEOF
10095/* end confdefs.h. */
98418dba
CW
10096
10097/* Override any gcc2 internal prototype to avoid an error. */
10098#ifdef __cplusplus
10099extern "C"
10100#endif
10101/* We use char because int might match the return type of a gcc2
10102 builtin and then its argument prototype would still apply. */
10103char XShapeQueryExtension ();
98418dba
CW
10104int
10105main ()
10106{
10107XShapeQueryExtension ();
10108 ;
10109 return 0;
10110}
10111_ACEOF
10112rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10113if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10114 (eval $ac_link) 2>conftest.er1
98418dba 10115 ac_status=$?
35996d22
AS
10116 grep -v '^ *+' conftest.er1 >conftest.err
10117 rm -f conftest.er1
10118 cat conftest.err >&5
c0d27fcc 10119 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10120 (exit $ac_status); } &&
35996d22
AS
10121 { ac_try='test -z "$ac_c_werror_flag"
10122 || test ! -s conftest.err'
10123 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10124 (eval $ac_try) 2>&5
10125 ac_status=$?
10126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10127 (exit $ac_status); }; } &&
10128 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10129 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10130 (eval $ac_try) 2>&5
10131 ac_status=$?
c0d27fcc 10132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10133 (exit $ac_status); }; }; then
10134 ac_cv_lib_Xext_XShapeQueryExtension=yes
10135else
10136 echo "$as_me: failed program was:" >&5
19650fd6
AS
10137sed 's/^/| /' conftest.$ac_ext >&5
10138
98418dba
CW
10139ac_cv_lib_Xext_XShapeQueryExtension=no
10140fi
35996d22
AS
10141rm -f conftest.err conftest.$ac_objext \
10142 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10143LIBS=$ac_check_lib_save_LIBS
10144fi
c0d27fcc 10145echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
10146echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
10147if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 10148 cat >>confdefs.h <<_ACEOF
98418dba 10149#define HAVE_LIBXEXT 1
c0d27fcc 10150_ACEOF
98418dba
CW
10151
10152 LIBS="-lXext $LIBS"
10153
10154fi
10155
10156 fi
10157fi
10158
10159if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10160 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
8e967cf7
MR
10161echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
10162if test "${emacs_cv_lesstif+set}" = set; then
10163 echo $ECHO_N "(cached) $ECHO_C" >&6
10164else
ae1a998c
RS
10165 # We put this in CFLAGS temporarily to precede other -I options
10166 # that might be in CFLAGS temporarily.
10167 # We put this in CPPFLAGS where it precedes the other -I options.
10168 OLD_CPPFLAGS=$CPPFLAGS
10169 OLD_CFLAGS=$CFLAGS
10170 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
10171 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
8e967cf7 10172 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10173/* confdefs.h. */
10174_ACEOF
10175cat confdefs.h >>conftest.$ac_ext
10176cat >>conftest.$ac_ext <<_ACEOF
10177/* end confdefs.h. */
8e967cf7
MR
10178#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
10179int
10180main ()
10181{
10182int x = 5;
10183 ;
10184 return 0;
10185}
10186_ACEOF
10187rm -f conftest.$ac_objext
c0d27fcc 10188if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10189 (eval $ac_compile) 2>conftest.er1
8e967cf7 10190 ac_status=$?
35996d22
AS
10191 grep -v '^ *+' conftest.er1 >conftest.err
10192 rm -f conftest.er1
10193 cat conftest.err >&5
c0d27fcc 10194 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7 10195 (exit $ac_status); } &&
35996d22
AS
10196 { ac_try='test -z "$ac_c_werror_flag"
10197 || test ! -s conftest.err'
10198 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10199 (eval $ac_try) 2>&5
10200 ac_status=$?
10201 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10202 (exit $ac_status); }; } &&
10203 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10204 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8e967cf7
MR
10205 (eval $ac_try) 2>&5
10206 ac_status=$?
c0d27fcc 10207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
10208 (exit $ac_status); }; }; then
10209 emacs_cv_lesstif=yes
10210else
10211 echo "$as_me: failed program was:" >&5
19650fd6
AS
10212sed 's/^/| /' conftest.$ac_ext >&5
10213
8e967cf7
MR
10214emacs_cv_lesstif=no
10215fi
35996d22 10216rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8e967cf7 10217fi
c0d27fcc 10218echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
8e967cf7
MR
10219echo "${ECHO_T}$emacs_cv_lesstif" >&6
10220 if test $emacs_cv_lesstif = yes; then
ae1a998c
RS
10221 # Make sure this -I option remains in CPPFLAGS after it is set
10222 # back to REAL_CPPFLAGS.
10223 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
10224 # have those other -I options anyway. Ultimately, having this
10225 # directory ultimately in CPPFLAGS will be enough.
10226 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
8e967cf7 10227 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
ae1a998c
RS
10228 else
10229 CFLAGS=$OLD_CFLAGS
10230 CPPFLAGS=$OLD_CPPFLAGS
8e967cf7 10231 fi
c0d27fcc 10232 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
10233echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
10234if test "${emacs_cv_motif_version_2_1+set}" = set; then
10235 echo $ECHO_N "(cached) $ECHO_C" >&6
10236else
10237 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10238/* confdefs.h. */
10239_ACEOF
10240cat confdefs.h >>conftest.$ac_ext
10241cat >>conftest.$ac_ext <<_ACEOF
10242/* end confdefs.h. */
98418dba 10243#include <Xm/Xm.h>
98418dba
CW
10244int
10245main ()
10246{
10247#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
10248int x = 5;
10249#else
10250Motif version prior to 2.1.
10251#endif
10252 ;
10253 return 0;
10254}
10255_ACEOF
10256rm -f conftest.$ac_objext
c0d27fcc 10257if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10258 (eval $ac_compile) 2>conftest.er1
98418dba 10259 ac_status=$?
35996d22
AS
10260 grep -v '^ *+' conftest.er1 >conftest.err
10261 rm -f conftest.er1
10262 cat conftest.err >&5
c0d27fcc 10263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10264 (exit $ac_status); } &&
35996d22
AS
10265 { ac_try='test -z "$ac_c_werror_flag"
10266 || test ! -s conftest.err'
10267 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10268 (eval $ac_try) 2>&5
10269 ac_status=$?
10270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10271 (exit $ac_status); }; } &&
10272 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10273 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10274 (eval $ac_try) 2>&5
10275 ac_status=$?
c0d27fcc 10276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10277 (exit $ac_status); }; }; then
10278 emacs_cv_motif_version_2_1=yes
10279else
10280 echo "$as_me: failed program was:" >&5
19650fd6
AS
10281sed 's/^/| /' conftest.$ac_ext >&5
10282
98418dba
CW
10283emacs_cv_motif_version_2_1=no
10284fi
35996d22 10285rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 10286fi
c0d27fcc 10287echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
10288echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
10289 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
10290 if test $emacs_cv_motif_version_2_1 = yes; then
10291 HAVE_LIBXP=no
b936fae4 10292
c0d27fcc 10293cat >>confdefs.h <<\_ACEOF
98418dba 10294#define HAVE_MOTIF_2_1 1
c0d27fcc 10295_ACEOF
98418dba 10296
c0d27fcc 10297 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
10298echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
10299if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
10300 echo $ECHO_N "(cached) $ECHO_C" >&6
10301else
10302 ac_check_lib_save_LIBS=$LIBS
10303LIBS="-lXp $LIBS"
10304cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10305/* confdefs.h. */
10306_ACEOF
10307cat confdefs.h >>conftest.$ac_ext
10308cat >>conftest.$ac_ext <<_ACEOF
10309/* end confdefs.h. */
98418dba
CW
10310
10311/* Override any gcc2 internal prototype to avoid an error. */
10312#ifdef __cplusplus
10313extern "C"
10314#endif
10315/* We use char because int might match the return type of a gcc2
10316 builtin and then its argument prototype would still apply. */
10317char XpCreateContext ();
98418dba
CW
10318int
10319main ()
10320{
10321XpCreateContext ();
10322 ;
10323 return 0;
10324}
10325_ACEOF
10326rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10327if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10328 (eval $ac_link) 2>conftest.er1
98418dba 10329 ac_status=$?
35996d22
AS
10330 grep -v '^ *+' conftest.er1 >conftest.err
10331 rm -f conftest.er1
10332 cat conftest.err >&5
c0d27fcc 10333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10334 (exit $ac_status); } &&
35996d22
AS
10335 { ac_try='test -z "$ac_c_werror_flag"
10336 || test ! -s conftest.err'
10337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10338 (eval $ac_try) 2>&5
10339 ac_status=$?
10340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10341 (exit $ac_status); }; } &&
10342 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10343 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10344 (eval $ac_try) 2>&5
10345 ac_status=$?
c0d27fcc 10346 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10347 (exit $ac_status); }; }; then
10348 ac_cv_lib_Xp_XpCreateContext=yes
10349else
10350 echo "$as_me: failed program was:" >&5
19650fd6
AS
10351sed 's/^/| /' conftest.$ac_ext >&5
10352
98418dba
CW
10353ac_cv_lib_Xp_XpCreateContext=no
10354fi
35996d22
AS
10355rm -f conftest.err conftest.$ac_objext \
10356 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10357LIBS=$ac_check_lib_save_LIBS
10358fi
c0d27fcc 10359echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
10360echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
10361if test $ac_cv_lib_Xp_XpCreateContext = yes; then
10362 HAVE_LIBXP=yes
10363fi
503d2be0 10364
98418dba 10365 if test ${HAVE_LIBXP} = yes; then
b936fae4 10366
c0d27fcc 10367cat >>confdefs.h <<\_ACEOF
98418dba 10368#define HAVE_LIBXP 1
c0d27fcc 10369_ACEOF
503d2be0 10370
98418dba
CW
10371 fi
10372 fi
10373fi
10374
10375### Is -lXaw3d available?
10376HAVE_XAW3D=no
10377if test "${HAVE_X11}" = "yes"; then
10378 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 10379 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
10380echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
10381if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
10382 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 10383else
22044edf 10384 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10385/* confdefs.h. */
10386_ACEOF
10387cat confdefs.h >>conftest.$ac_ext
10388cat >>conftest.$ac_ext <<_ACEOF
10389/* end confdefs.h. */
98418dba 10390#include <X11/Xaw3d/Scrollbar.h>
503d2be0 10391_ACEOF
c0d27fcc 10392if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
10393 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10394 ac_status=$?
6bae0ccf 10395 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
10396 rm -f conftest.er1
10397 cat conftest.err >&5
c0d27fcc 10398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10399 (exit $ac_status); } >/dev/null; then
10400 if test -s conftest.err; then
10401 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10402 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
10403 else
10404 ac_cpp_err=
10405 fi
10406else
10407 ac_cpp_err=yes
10408fi
10409if test -z "$ac_cpp_err"; then
22044edf 10410 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 10411else
503d2be0 10412 echo "$as_me: failed program was:" >&5
19650fd6
AS
10413sed 's/^/| /' conftest.$ac_ext >&5
10414
22044edf 10415 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 10416fi
503d2be0 10417rm -f conftest.err conftest.$ac_ext
98418dba 10418fi
c0d27fcc 10419echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 10420echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 10421if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 10422 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
10423echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
10424if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
10425 echo $ECHO_N "(cached) $ECHO_C" >&6
10426else
10427 ac_check_lib_save_LIBS=$LIBS
10428LIBS="-lXaw3d $LIBS"
10429cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10430/* confdefs.h. */
10431_ACEOF
10432cat confdefs.h >>conftest.$ac_ext
10433cat >>conftest.$ac_ext <<_ACEOF
10434/* end confdefs.h. */
98418dba
CW
10435
10436/* Override any gcc2 internal prototype to avoid an error. */
10437#ifdef __cplusplus
10438extern "C"
10439#endif
10440/* We use char because int might match the return type of a gcc2
10441 builtin and then its argument prototype would still apply. */
10442char XawScrollbarSetThumb ();
503d2be0
AS
10443int
10444main ()
10445{
98418dba 10446XawScrollbarSetThumb ();
503d2be0
AS
10447 ;
10448 return 0;
10449}
10450_ACEOF
10451rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10452if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10453 (eval $ac_link) 2>conftest.er1
503d2be0 10454 ac_status=$?
35996d22
AS
10455 grep -v '^ *+' conftest.er1 >conftest.err
10456 rm -f conftest.er1
10457 cat conftest.err >&5
c0d27fcc 10458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10459 (exit $ac_status); } &&
35996d22
AS
10460 { ac_try='test -z "$ac_c_werror_flag"
10461 || test ! -s conftest.err'
10462 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10463 (eval $ac_try) 2>&5
10464 ac_status=$?
10465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10466 (exit $ac_status); }; } &&
10467 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10468 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10469 (eval $ac_try) 2>&5
10470 ac_status=$?
c0d27fcc 10471 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10472 (exit $ac_status); }; }; then
98418dba 10473 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 10474else
503d2be0 10475 echo "$as_me: failed program was:" >&5
19650fd6
AS
10476sed 's/^/| /' conftest.$ac_ext >&5
10477
98418dba 10478ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 10479fi
35996d22
AS
10480rm -f conftest.err conftest.$ac_objext \
10481 conftest$ac_exeext conftest.$ac_ext
98418dba 10482LIBS=$ac_check_lib_save_LIBS
ba4481b5 10483fi
c0d27fcc 10484echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
10485echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
10486if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
10487 HAVE_XAW3D=yes
ba4481b5 10488fi
503d2be0 10489
ba4481b5
DL
10490fi
10491
c0d27fcc 10492
98418dba 10493 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 10494
c0d27fcc 10495cat >>confdefs.h <<\_ACEOF
98418dba 10496#define HAVE_XAW3D 1
c0d27fcc 10497_ACEOF
98418dba 10498
ba4481b5 10499 fi
98418dba 10500 fi
ba4481b5
DL
10501fi
10502
c0d27fcc
MR
10503
10504
98418dba
CW
10505USE_TOOLKIT_SCROLL_BARS=no
10506if test "${with_toolkit_scroll_bars}" != "no"; then
10507 if test "${USE_X_TOOLKIT}" != "none"; then
10508 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10509 cat >>confdefs.h <<\_ACEOF
98418dba 10510#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10511_ACEOF
98418dba
CW
10512
10513 HAVE_XAW3D=no
10514 USE_TOOLKIT_SCROLL_BARS=yes
10515 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 10516 cat >>confdefs.h <<\_ACEOF
98418dba 10517#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10518_ACEOF
98418dba
CW
10519
10520 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 10521 fi
488dd4c4
JD
10522 elif test "${HAVE_GTK}" = "yes"; then
10523 cat >>confdefs.h <<\_ACEOF
10524#define USE_TOOLKIT_SCROLL_BARS 1
10525_ACEOF
10526
10527 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
10528 fi
10529fi
10530
abd39b57 10531cat >conftest.$ac_ext <<_ACEOF
abd39b57
AC
10532/* confdefs.h. */
10533_ACEOF
10534cat confdefs.h >>conftest.$ac_ext
10535cat >>conftest.$ac_ext <<_ACEOF
10536/* end confdefs.h. */
10537
10538 #include <X11/Xlib.h>
10539 #include <X11/Xresource.h>
10540int
10541main ()
10542{
10543XIMProc callback;
10544 ;
10545 return 0;
10546}
10547_ACEOF
10548rm -f conftest.$ac_objext
10549if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10550 (eval $ac_compile) 2>conftest.er1
abd39b57 10551 ac_status=$?
35996d22
AS
10552 grep -v '^ *+' conftest.er1 >conftest.err
10553 rm -f conftest.er1
10554 cat conftest.err >&5
abd39b57
AC
10555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10556 (exit $ac_status); } &&
35996d22
AS
10557 { ac_try='test -z "$ac_c_werror_flag"
10558 || test ! -s conftest.err'
10559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10560 (eval $ac_try) 2>&5
10561 ac_status=$?
10562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10563 (exit $ac_status); }; } &&
10564 { ac_try='test -s conftest.$ac_objext'
abd39b57
AC
10565 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10566 (eval $ac_try) 2>&5
10567 ac_status=$?
10568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10569 (exit $ac_status); }; }; then
10570 HAVE_XIM=yes
10571
10572cat >>confdefs.h <<\_ACEOF
10573#define HAVE_XIM 1
10574_ACEOF
10575
10576else
10577 echo "$as_me: failed program was:" >&5
10578sed 's/^/| /' conftest.$ac_ext >&5
10579
10580HAVE_XIM=no
10581fi
35996d22 10582rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
abd39b57 10583
c0d27fcc 10584
98418dba 10585if test "${with_xim}" != "no"; then
b936fae4 10586
c0d27fcc 10587cat >>confdefs.h <<\_ACEOF
98418dba 10588#define USE_XIM 1
c0d27fcc 10589_ACEOF
98418dba 10590
793fa0d7 10591fi
abd39b57
AC
10592
10593
10594if test "${HAVE_XIM}" != "no"; then
849d80cf
DL
10595 late_CFLAGS=$CFLAGS
10596 if test "$GCC" = yes; then
10597 CFLAGS="$CFLAGS --pedantic-errors"
10598 fi
cffcede7 10599 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10600/* confdefs.h. */
10601_ACEOF
10602cat confdefs.h >>conftest.$ac_ext
10603cat >>conftest.$ac_ext <<_ACEOF
10604/* end confdefs.h. */
cffcede7
JD
10605
10606#include <X11/Xlib.h>
10607#include <X11/Xresource.h>
10608int
10609main ()
10610{
10611Display *display;
10612XrmDatabase db;
10613char *res_name;
10614char *res_class;
10615XIMProc callback;
10616XPointer *client_data;
849d80cf
DL
10617#ifndef __GNUC__
10618/* If we're not using GCC, it's probably not XFree86, and this is
10619 probably right, but we can't use something like --pedantic-errors. */
10620extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
10621 char*, XIMProc, XPointer*);
10622#endif
cffcede7
JD
10623(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
10624 client_data);
10625 ;
10626 return 0;
10627}
10628_ACEOF
10629rm -f conftest.$ac_objext
10630if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10631 (eval $ac_compile) 2>conftest.er1
cffcede7 10632 ac_status=$?
35996d22
AS
10633 grep -v '^ *+' conftest.er1 >conftest.err
10634 rm -f conftest.er1
10635 cat conftest.err >&5
cffcede7
JD
10636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10637 (exit $ac_status); } &&
35996d22
AS
10638 { ac_try='test -z "$ac_c_werror_flag"
10639 || test ! -s conftest.err'
10640 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10641 (eval $ac_try) 2>&5
10642 ac_status=$?
10643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10644 (exit $ac_status); }; } &&
10645 { ac_try='test -s conftest.$ac_objext'
cffcede7
JD
10646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10647 (eval $ac_try) 2>&5
10648 ac_status=$?
10649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10650 (exit $ac_status); }; }; then
10651 emacs_cv_arg6_star=yes
10652else
10653 echo "$as_me: failed program was:" >&5
19650fd6
AS
10654sed 's/^/| /' conftest.$ac_ext >&5
10655
cffcede7 10656fi
35996d22 10657rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cffcede7
JD
10658
10659 if test "$emacs_cv_arg6_star" = yes; then
f57bd967 10660 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10661#define XRegisterIMInstantiateCallback_arg6 XPointer*
10662_ACEOF
10663
10664 else
f57bd967 10665 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10666#define XRegisterIMInstantiateCallback_arg6 XPointer
10667_ACEOF
10668
10669 fi
849d80cf 10670 CFLAGS=$late_CFLAGS
98418dba
CW
10671fi
10672
10673### Use -lXpm if available, unless `--with-xpm=no'.
10674HAVE_XPM=no
10675if test "${HAVE_X11}" = "yes"; then
10676 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
10677 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10678 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
10679echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10680if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10681 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10682fi
10683echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
10684echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 10685else
c0d27fcc
MR
10686 # Is the header compilable?
10687echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
10688echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
10689cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10690/* confdefs.h. */
10691_ACEOF
10692cat confdefs.h >>conftest.$ac_ext
10693cat >>conftest.$ac_ext <<_ACEOF
10694/* end confdefs.h. */
c0d27fcc
MR
10695$ac_includes_default
10696#include <X11/xpm.h>
10697_ACEOF
10698rm -f conftest.$ac_objext
10699if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10700 (eval $ac_compile) 2>conftest.er1
c0d27fcc 10701 ac_status=$?
35996d22
AS
10702 grep -v '^ *+' conftest.er1 >conftest.err
10703 rm -f conftest.er1
10704 cat conftest.err >&5
c0d27fcc
MR
10705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10706 (exit $ac_status); } &&
35996d22
AS
10707 { ac_try='test -z "$ac_c_werror_flag"
10708 || test ! -s conftest.err'
10709 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10710 (eval $ac_try) 2>&5
10711 ac_status=$?
10712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10713 (exit $ac_status); }; } &&
10714 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10715 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10716 (eval $ac_try) 2>&5
10717 ac_status=$?
10718 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10719 (exit $ac_status); }; }; then
10720 ac_header_compiler=yes
10721else
10722 echo "$as_me: failed program was:" >&5
19650fd6
AS
10723sed 's/^/| /' conftest.$ac_ext >&5
10724
c0d27fcc
MR
10725ac_header_compiler=no
10726fi
35996d22 10727rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10728echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10729echo "${ECHO_T}$ac_header_compiler" >&6
10730
10731# Is the header present?
10732echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
10733echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
10734cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10735/* confdefs.h. */
10736_ACEOF
10737cat confdefs.h >>conftest.$ac_ext
10738cat >>conftest.$ac_ext <<_ACEOF
10739/* end confdefs.h. */
98418dba
CW
10740#include <X11/xpm.h>
10741_ACEOF
c0d27fcc 10742if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10743 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10744 ac_status=$?
6bae0ccf 10745 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10746 rm -f conftest.er1
10747 cat conftest.err >&5
c0d27fcc 10748 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10749 (exit $ac_status); } >/dev/null; then
10750 if test -s conftest.err; then
10751 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10752 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
10753 else
10754 ac_cpp_err=
10755 fi
10756else
10757 ac_cpp_err=yes
10758fi
10759if test -z "$ac_cpp_err"; then
c0d27fcc 10760 ac_header_preproc=yes
98418dba
CW
10761else
10762 echo "$as_me: failed program was:" >&5
19650fd6
AS
10763sed 's/^/| /' conftest.$ac_ext >&5
10764
c0d27fcc 10765 ac_header_preproc=no
98418dba
CW
10766fi
10767rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10768echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10769echo "${ECHO_T}$ac_header_preproc" >&6
10770
10771# So? What about this header?
35996d22
AS
10772case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10773 yes:no: )
c0d27fcc
MR
10774 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
10775echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
10776 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the compiler's result" >&5
10777echo "$as_me: WARNING: X11/xpm.h: proceeding with the compiler's result" >&2;}
10778 ac_header_preproc=yes
19650fd6 10779 ;;
35996d22 10780 no:yes:* )
c0d27fcc
MR
10781 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
10782echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
35996d22
AS
10783 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
10784echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
10785 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: see the Autoconf documentation" >&5
10786echo "$as_me: WARNING: X11/xpm.h: see the Autoconf documentation" >&2;}
10787 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&5
10788echo "$as_me: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 10789 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
19650fd6 10790echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
10791 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&5
10792echo "$as_me: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
10793 (
10794 cat <<\_ASBOX
35996d22
AS
10795## ------------------------------------------ ##
10796## Report this to the AC_PACKAGE_NAME lists. ##
10797## ------------------------------------------ ##
19650fd6
AS
10798_ASBOX
10799 ) |
10800 sed "s/^/$as_me: WARNING: /" >&2
10801 ;;
c0d27fcc
MR
10802esac
10803echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
10804echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10805if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10806 echo $ECHO_N "(cached) $ECHO_C" >&6
10807else
10808 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 10809fi
c0d27fcc 10810echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 10811echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
10812
10813fi
98418dba 10814if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 10815 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
10816echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
10817if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 10818 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10819else
98418dba
CW
10820 ac_check_lib_save_LIBS=$LIBS
10821LIBS="-lXpm -lX11 $LIBS"
10822cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10823/* confdefs.h. */
10824_ACEOF
10825cat confdefs.h >>conftest.$ac_ext
10826cat >>conftest.$ac_ext <<_ACEOF
10827/* end confdefs.h. */
98418dba 10828
ba4481b5 10829/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10830#ifdef __cplusplus
10831extern "C"
10832#endif
ba4481b5 10833/* We use char because int might match the return type of a gcc2
503d2be0 10834 builtin and then its argument prototype would still apply. */
98418dba 10835char XpmReadFileToPixmap ();
503d2be0
AS
10836int
10837main ()
10838{
98418dba 10839XpmReadFileToPixmap ();
503d2be0
AS
10840 ;
10841 return 0;
10842}
10843_ACEOF
10844rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10845if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10846 (eval $ac_link) 2>conftest.er1
503d2be0 10847 ac_status=$?
35996d22
AS
10848 grep -v '^ *+' conftest.er1 >conftest.err
10849 rm -f conftest.er1
10850 cat conftest.err >&5
c0d27fcc 10851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10852 (exit $ac_status); } &&
35996d22
AS
10853 { ac_try='test -z "$ac_c_werror_flag"
10854 || test ! -s conftest.err'
10855 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10856 (eval $ac_try) 2>&5
10857 ac_status=$?
10858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10859 (exit $ac_status); }; } &&
10860 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10861 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10862 (eval $ac_try) 2>&5
10863 ac_status=$?
c0d27fcc 10864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10865 (exit $ac_status); }; }; then
98418dba 10866 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
10867else
10868 echo "$as_me: failed program was:" >&5
19650fd6
AS
10869sed 's/^/| /' conftest.$ac_ext >&5
10870
98418dba 10871ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0 10872fi
35996d22
AS
10873rm -f conftest.err conftest.$ac_objext \
10874 conftest$ac_exeext conftest.$ac_ext
98418dba 10875LIBS=$ac_check_lib_save_LIBS
503d2be0 10876fi
c0d27fcc 10877echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
10878echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
10879if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
10880 HAVE_XPM=yes
ba4481b5
DL
10881fi
10882
98418dba
CW
10883fi
10884
c0d27fcc 10885
98418dba 10886 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10887 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
10888echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
10889 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10890/* confdefs.h. */
10891_ACEOF
10892cat confdefs.h >>conftest.$ac_ext
10893cat >>conftest.$ac_ext <<_ACEOF
10894/* end confdefs.h. */
98418dba
CW
10895#include "X11/xpm.h"
10896#ifndef XpmReturnAllocPixels
10897no_return_alloc_pixels
503d2be0 10898#endif
ba4481b5 10899
98418dba
CW
10900_ACEOF
10901if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10902 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
10903 HAVE_XPM=no
10904else
10905 HAVE_XPM=yes
10906fi
10907rm -f conftest*
ba4481b5 10908
c0d27fcc 10909
98418dba 10910 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10911 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
10912echo "${ECHO_T}yes" >&6
10913 else
c0d27fcc 10914 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
10915echo "${ECHO_T}no" >&6
10916 fi
10917 fi
10918 fi
10919
10920 if test "${HAVE_XPM}" = "yes"; then
b936fae4 10921
c0d27fcc 10922cat >>confdefs.h <<\_ACEOF
98418dba 10923#define HAVE_XPM 1
c0d27fcc 10924_ACEOF
98418dba
CW
10925
10926 fi
10927fi
10928
10929### Use -ljpeg if available, unless `--with-jpeg=no'.
10930HAVE_JPEG=no
10931if test "${HAVE_X11}" = "yes"; then
10932 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
10933 if test "${ac_cv_header_jerror_h+set}" = set; then
10934 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
10935echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
10936if test "${ac_cv_header_jerror_h+set}" = set; then
10937 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10938fi
10939echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
10940echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 10941else
c0d27fcc
MR
10942 # Is the header compilable?
10943echo "$as_me:$LINENO: checking jerror.h usability" >&5
10944echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
10945cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10946/* confdefs.h. */
10947_ACEOF
10948cat confdefs.h >>conftest.$ac_ext
10949cat >>conftest.$ac_ext <<_ACEOF
10950/* end confdefs.h. */
c0d27fcc
MR
10951$ac_includes_default
10952#include <jerror.h>
10953_ACEOF
10954rm -f conftest.$ac_objext
10955if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10956 (eval $ac_compile) 2>conftest.er1
c0d27fcc 10957 ac_status=$?
35996d22
AS
10958 grep -v '^ *+' conftest.er1 >conftest.err
10959 rm -f conftest.er1
10960 cat conftest.err >&5
c0d27fcc
MR
10961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10962 (exit $ac_status); } &&
35996d22
AS
10963 { ac_try='test -z "$ac_c_werror_flag"
10964 || test ! -s conftest.err'
10965 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10966 (eval $ac_try) 2>&5
10967 ac_status=$?
10968 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10969 (exit $ac_status); }; } &&
10970 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10971 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10972 (eval $ac_try) 2>&5
10973 ac_status=$?
10974 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10975 (exit $ac_status); }; }; then
10976 ac_header_compiler=yes
10977else
10978 echo "$as_me: failed program was:" >&5
19650fd6
AS
10979sed 's/^/| /' conftest.$ac_ext >&5
10980
c0d27fcc
MR
10981ac_header_compiler=no
10982fi
35996d22 10983rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10984echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10985echo "${ECHO_T}$ac_header_compiler" >&6
10986
10987# Is the header present?
10988echo "$as_me:$LINENO: checking jerror.h presence" >&5
10989echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
10990cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10991/* confdefs.h. */
10992_ACEOF
10993cat confdefs.h >>conftest.$ac_ext
10994cat >>conftest.$ac_ext <<_ACEOF
10995/* end confdefs.h. */
98418dba
CW
10996#include <jerror.h>
10997_ACEOF
c0d27fcc 10998if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10999 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11000 ac_status=$?
6bae0ccf 11001 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11002 rm -f conftest.er1
11003 cat conftest.err >&5
c0d27fcc 11004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11005 (exit $ac_status); } >/dev/null; then
11006 if test -s conftest.err; then
11007 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11008 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11009 else
11010 ac_cpp_err=
11011 fi
11012else
11013 ac_cpp_err=yes
503d2be0 11014fi
98418dba 11015if test -z "$ac_cpp_err"; then
c0d27fcc 11016 ac_header_preproc=yes
ba4481b5 11017else
98418dba 11018 echo "$as_me: failed program was:" >&5
19650fd6
AS
11019sed 's/^/| /' conftest.$ac_ext >&5
11020
c0d27fcc 11021 ac_header_preproc=no
98418dba
CW
11022fi
11023rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11024echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11025echo "${ECHO_T}$ac_header_preproc" >&6
11026
11027# So? What about this header?
35996d22
AS
11028case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11029 yes:no: )
c0d27fcc
MR
11030 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
11031echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11032 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the compiler's result" >&5
11033echo "$as_me: WARNING: jerror.h: proceeding with the compiler's result" >&2;}
11034 ac_header_preproc=yes
19650fd6 11035 ;;
35996d22 11036 no:yes:* )
c0d27fcc
MR
11037 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
11038echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
35996d22
AS
11039 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
11040echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
11041 { echo "$as_me:$LINENO: WARNING: jerror.h: see the Autoconf documentation" >&5
11042echo "$as_me: WARNING: jerror.h: see the Autoconf documentation" >&2;}
11043 { echo "$as_me:$LINENO: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&5
11044echo "$as_me: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11045 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
19650fd6 11046echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11047 { echo "$as_me:$LINENO: WARNING: jerror.h: in the future, the compiler will take precedence" >&5
11048echo "$as_me: WARNING: jerror.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11049 (
11050 cat <<\_ASBOX
35996d22
AS
11051## ------------------------------------------ ##
11052## Report this to the AC_PACKAGE_NAME lists. ##
11053## ------------------------------------------ ##
19650fd6
AS
11054_ASBOX
11055 ) |
11056 sed "s/^/$as_me: WARNING: /" >&2
11057 ;;
c0d27fcc
MR
11058esac
11059echo "$as_me:$LINENO: checking for jerror.h" >&5
11060echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11061if test "${ac_cv_header_jerror_h+set}" = set; then
11062 echo $ECHO_N "(cached) $ECHO_C" >&6
11063else
11064 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 11065fi
c0d27fcc 11066echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 11067echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
11068
11069fi
98418dba 11070if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 11071 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
11072echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
11073if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 11074 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11075else
98418dba
CW
11076 ac_check_lib_save_LIBS=$LIBS
11077LIBS="-ljpeg $LIBS"
11078cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11079/* confdefs.h. */
11080_ACEOF
11081cat confdefs.h >>conftest.$ac_ext
11082cat >>conftest.$ac_ext <<_ACEOF
11083/* end confdefs.h. */
98418dba
CW
11084
11085/* Override any gcc2 internal prototype to avoid an error. */
11086#ifdef __cplusplus
11087extern "C"
11088#endif
11089/* We use char because int might match the return type of a gcc2
11090 builtin and then its argument prototype would still apply. */
11091char jpeg_destroy_compress ();
503d2be0
AS
11092int
11093main ()
11094{
98418dba 11095jpeg_destroy_compress ();
503d2be0
AS
11096 ;
11097 return 0;
11098}
11099_ACEOF
11100rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11101if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11102 (eval $ac_link) 2>conftest.er1
503d2be0 11103 ac_status=$?
35996d22
AS
11104 grep -v '^ *+' conftest.er1 >conftest.err
11105 rm -f conftest.er1
11106 cat conftest.err >&5
c0d27fcc 11107 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11108 (exit $ac_status); } &&
35996d22
AS
11109 { ac_try='test -z "$ac_c_werror_flag"
11110 || test ! -s conftest.err'
11111 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11112 (eval $ac_try) 2>&5
11113 ac_status=$?
11114 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11115 (exit $ac_status); }; } &&
11116 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11117 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11118 (eval $ac_try) 2>&5
11119 ac_status=$?
c0d27fcc 11120 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11121 (exit $ac_status); }; }; then
98418dba 11122 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 11123else
503d2be0 11124 echo "$as_me: failed program was:" >&5
19650fd6
AS
11125sed 's/^/| /' conftest.$ac_ext >&5
11126
98418dba 11127ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 11128fi
35996d22
AS
11129rm -f conftest.err conftest.$ac_objext \
11130 conftest$ac_exeext conftest.$ac_ext
98418dba 11131LIBS=$ac_check_lib_save_LIBS
ba4481b5 11132fi
c0d27fcc 11133echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
11134echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
11135if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
11136 HAVE_JPEG=yes
ba4481b5 11137fi
98418dba 11138
ba4481b5 11139fi
98418dba 11140
c0d27fcc 11141
ba4481b5 11142 fi
ba4481b5 11143
c0d27fcc 11144
98418dba 11145 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 11146 cat >>confdefs.h <<\_ACEOF
98418dba 11147#define HAVE_JPEG 1
c0d27fcc 11148_ACEOF
98418dba
CW
11149
11150 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11151/* confdefs.h. */
11152_ACEOF
11153cat confdefs.h >>conftest.$ac_ext
11154cat >>conftest.$ac_ext <<_ACEOF
11155/* end confdefs.h. */
22044edf 11156#include <jpeglib.h>
98418dba
CW
11157 version=JPEG_LIB_VERSION
11158
11159_ACEOF
11160if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11161 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 11162 cat >>confdefs.h <<\_ACEOF
98418dba 11163#define HAVE_JPEG 1
c0d27fcc 11164_ACEOF
ba4481b5 11165
98418dba 11166else
c0d27fcc 11167 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
11168echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
11169 HAVE_JPEG=no
ba4481b5 11170fi
98418dba 11171rm -f conftest*
ba4481b5 11172
98418dba
CW
11173 fi
11174fi
503d2be0 11175
98418dba
CW
11176### Use -lpng if available, unless `--with-png=no'.
11177HAVE_PNG=no
11178if test "${HAVE_X11}" = "yes"; then
11179 if test "${with_png}" != "no"; then
f57bd967
DL
11180 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
11181 # in /usr/include/libpng.
11182
11183
11184for ac_header in png.h libpng/png.h
11185do
11186as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11187if eval "test \"\${$as_ac_Header+set}\" = set"; then
11188 echo "$as_me:$LINENO: checking for $ac_header" >&5
11189echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11190if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11191 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc 11192fi
f57bd967
DL
11193echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11194echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
503d2be0 11195else
c0d27fcc 11196 # Is the header compilable?
f57bd967
DL
11197echo "$as_me:$LINENO: checking $ac_header usability" >&5
11198echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
c0d27fcc 11199cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11200/* confdefs.h. */
11201_ACEOF
11202cat confdefs.h >>conftest.$ac_ext
11203cat >>conftest.$ac_ext <<_ACEOF
11204/* end confdefs.h. */
c0d27fcc 11205$ac_includes_default
f57bd967 11206#include <$ac_header>
c0d27fcc
MR
11207_ACEOF
11208rm -f conftest.$ac_objext
11209if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11210 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11211 ac_status=$?
35996d22
AS
11212 grep -v '^ *+' conftest.er1 >conftest.err
11213 rm -f conftest.er1
11214 cat conftest.err >&5
c0d27fcc
MR
11215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11216 (exit $ac_status); } &&
35996d22
AS
11217 { ac_try='test -z "$ac_c_werror_flag"
11218 || test ! -s conftest.err'
11219 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11220 (eval $ac_try) 2>&5
11221 ac_status=$?
11222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11223 (exit $ac_status); }; } &&
11224 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11225 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11226 (eval $ac_try) 2>&5
11227 ac_status=$?
11228 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11229 (exit $ac_status); }; }; then
11230 ac_header_compiler=yes
11231else
11232 echo "$as_me: failed program was:" >&5
19650fd6
AS
11233sed 's/^/| /' conftest.$ac_ext >&5
11234
c0d27fcc
MR
11235ac_header_compiler=no
11236fi
35996d22 11237rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11238echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11239echo "${ECHO_T}$ac_header_compiler" >&6
11240
11241# Is the header present?
f57bd967
DL
11242echo "$as_me:$LINENO: checking $ac_header presence" >&5
11243echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
c0d27fcc 11244cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11245/* confdefs.h. */
11246_ACEOF
11247cat confdefs.h >>conftest.$ac_ext
11248cat >>conftest.$ac_ext <<_ACEOF
11249/* end confdefs.h. */
f57bd967 11250#include <$ac_header>
503d2be0 11251_ACEOF
c0d27fcc 11252if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11253 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11254 ac_status=$?
6bae0ccf 11255 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11256 rm -f conftest.er1
11257 cat conftest.err >&5
c0d27fcc 11258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11259 (exit $ac_status); } >/dev/null; then
11260 if test -s conftest.err; then
11261 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11262 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
11263 else
11264 ac_cpp_err=
11265 fi
11266else
11267 ac_cpp_err=yes
11268fi
11269if test -z "$ac_cpp_err"; then
c0d27fcc 11270 ac_header_preproc=yes
503d2be0
AS
11271else
11272 echo "$as_me: failed program was:" >&5
19650fd6
AS
11273sed 's/^/| /' conftest.$ac_ext >&5
11274
c0d27fcc 11275 ac_header_preproc=no
ba4481b5 11276fi
503d2be0 11277rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11278echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11279echo "${ECHO_T}$ac_header_preproc" >&6
11280
11281# So? What about this header?
35996d22
AS
11282case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11283 yes:no: )
f57bd967
DL
11284 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11285echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11286 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11287echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11288 ac_header_preproc=yes
19650fd6 11289 ;;
35996d22 11290 no:yes:* )
f57bd967
DL
11291 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11292echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
11293 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11294echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11295 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11296echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11297 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11298echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
f57bd967 11299 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 11300echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11301 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11302echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11303 (
11304 cat <<\_ASBOX
35996d22
AS
11305## ------------------------------------------ ##
11306## Report this to the AC_PACKAGE_NAME lists. ##
11307## ------------------------------------------ ##
19650fd6
AS
11308_ASBOX
11309 ) |
11310 sed "s/^/$as_me: WARNING: /" >&2
11311 ;;
c0d27fcc 11312esac
f57bd967
DL
11313echo "$as_me:$LINENO: checking for $ac_header" >&5
11314echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11315if eval "test \"\${$as_ac_Header+set}\" = set"; then
c0d27fcc
MR
11316 echo $ECHO_N "(cached) $ECHO_C" >&6
11317else
35996d22 11318 eval "$as_ac_Header=\$ac_header_preproc"
f57bd967
DL
11319fi
11320echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11321echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11322
ba4481b5 11323fi
f57bd967
DL
11324if test `eval echo '${'$as_ac_Header'}'` = yes; then
11325 cat >>confdefs.h <<_ACEOF
11326#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11327_ACEOF
c0d27fcc
MR
11328
11329fi
f57bd967
DL
11330
11331done
11332
11333 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
11334 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
11335echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
11336if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 11337 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11338else
98418dba
CW
11339 ac_check_lib_save_LIBS=$LIBS
11340LIBS="-lpng -lz -lm $LIBS"
11341cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11342/* confdefs.h. */
11343_ACEOF
11344cat confdefs.h >>conftest.$ac_ext
11345cat >>conftest.$ac_ext <<_ACEOF
11346/* end confdefs.h. */
98418dba 11347
ba4481b5 11348/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11349#ifdef __cplusplus
11350extern "C"
11351#endif
ba4481b5 11352/* We use char because int might match the return type of a gcc2
503d2be0 11353 builtin and then its argument prototype would still apply. */
98418dba 11354char png_get_channels ();
503d2be0
AS
11355int
11356main ()
11357{
98418dba 11358png_get_channels ();
503d2be0
AS
11359 ;
11360 return 0;
11361}
11362_ACEOF
11363rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11364if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11365 (eval $ac_link) 2>conftest.er1
503d2be0 11366 ac_status=$?
35996d22
AS
11367 grep -v '^ *+' conftest.er1 >conftest.err
11368 rm -f conftest.er1
11369 cat conftest.err >&5
c0d27fcc 11370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11371 (exit $ac_status); } &&
35996d22
AS
11372 { ac_try='test -z "$ac_c_werror_flag"
11373 || test ! -s conftest.err'
11374 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11375 (eval $ac_try) 2>&5
11376 ac_status=$?
11377 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11378 (exit $ac_status); }; } &&
11379 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11381 (eval $ac_try) 2>&5
11382 ac_status=$?
c0d27fcc 11383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11384 (exit $ac_status); }; }; then
98418dba 11385 ac_cv_lib_png_png_get_channels=yes
73b77ee5 11386else
98418dba 11387 echo "$as_me: failed program was:" >&5
19650fd6
AS
11388sed 's/^/| /' conftest.$ac_ext >&5
11389
98418dba 11390ac_cv_lib_png_png_get_channels=no
73b77ee5 11391fi
35996d22
AS
11392rm -f conftest.err conftest.$ac_objext \
11393 conftest$ac_exeext conftest.$ac_ext
98418dba 11394LIBS=$ac_check_lib_save_LIBS
73b77ee5 11395fi
c0d27fcc 11396echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
11397echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
11398if test $ac_cv_lib_png_png_get_channels = yes; then
11399 HAVE_PNG=yes
73b77ee5 11400fi
503d2be0 11401
f57bd967 11402 fi
98418dba
CW
11403 fi
11404
11405 if test "${HAVE_PNG}" = "yes"; then
b936fae4 11406
c0d27fcc 11407cat >>confdefs.h <<\_ACEOF
98418dba 11408#define HAVE_PNG 1
c0d27fcc 11409_ACEOF
73b77ee5 11410
98418dba 11411 fi
73b77ee5
GM
11412fi
11413
98418dba
CW
11414### Use -ltiff if available, unless `--with-tiff=no'.
11415HAVE_TIFF=no
11416if test "${HAVE_X11}" = "yes"; then
11417 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
11418 if test "${ac_cv_header_tiffio_h+set}" = set; then
11419 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
11420echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11421if test "${ac_cv_header_tiffio_h+set}" = set; then
11422 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11423fi
11424echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
11425echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 11426else
c0d27fcc
MR
11427 # Is the header compilable?
11428echo "$as_me:$LINENO: checking tiffio.h usability" >&5
11429echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
11430cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11431/* confdefs.h. */
11432_ACEOF
11433cat confdefs.h >>conftest.$ac_ext
11434cat >>conftest.$ac_ext <<_ACEOF
11435/* end confdefs.h. */
c0d27fcc
MR
11436$ac_includes_default
11437#include <tiffio.h>
11438_ACEOF
11439rm -f conftest.$ac_objext
11440if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11441 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11442 ac_status=$?
35996d22
AS
11443 grep -v '^ *+' conftest.er1 >conftest.err
11444 rm -f conftest.er1
11445 cat conftest.err >&5
c0d27fcc
MR
11446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11447 (exit $ac_status); } &&
35996d22
AS
11448 { ac_try='test -z "$ac_c_werror_flag"
11449 || test ! -s conftest.err'
11450 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11451 (eval $ac_try) 2>&5
11452 ac_status=$?
11453 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11454 (exit $ac_status); }; } &&
11455 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11456 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11457 (eval $ac_try) 2>&5
11458 ac_status=$?
11459 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11460 (exit $ac_status); }; }; then
11461 ac_header_compiler=yes
11462else
11463 echo "$as_me: failed program was:" >&5
19650fd6
AS
11464sed 's/^/| /' conftest.$ac_ext >&5
11465
c0d27fcc
MR
11466ac_header_compiler=no
11467fi
35996d22 11468rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11469echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11470echo "${ECHO_T}$ac_header_compiler" >&6
11471
11472# Is the header present?
11473echo "$as_me:$LINENO: checking tiffio.h presence" >&5
11474echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
11475cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11476/* confdefs.h. */
11477_ACEOF
11478cat confdefs.h >>conftest.$ac_ext
11479cat >>conftest.$ac_ext <<_ACEOF
11480/* end confdefs.h. */
98418dba
CW
11481#include <tiffio.h>
11482_ACEOF
c0d27fcc 11483if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11484 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11485 ac_status=$?
6bae0ccf 11486 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11487 rm -f conftest.er1
11488 cat conftest.err >&5
c0d27fcc 11489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11490 (exit $ac_status); } >/dev/null; then
11491 if test -s conftest.err; then
11492 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11493 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11494 else
11495 ac_cpp_err=
11496 fi
11497else
11498 ac_cpp_err=yes
11499fi
11500if test -z "$ac_cpp_err"; then
c0d27fcc 11501 ac_header_preproc=yes
98418dba
CW
11502else
11503 echo "$as_me: failed program was:" >&5
19650fd6
AS
11504sed 's/^/| /' conftest.$ac_ext >&5
11505
c0d27fcc 11506 ac_header_preproc=no
98418dba
CW
11507fi
11508rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11509echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11510echo "${ECHO_T}$ac_header_preproc" >&6
11511
11512# So? What about this header?
35996d22
AS
11513case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11514 yes:no: )
c0d27fcc
MR
11515 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
11516echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11517 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the compiler's result" >&5
11518echo "$as_me: WARNING: tiffio.h: proceeding with the compiler's result" >&2;}
11519 ac_header_preproc=yes
19650fd6 11520 ;;
35996d22 11521 no:yes:* )
c0d27fcc
MR
11522 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
11523echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
35996d22
AS
11524 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
11525echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
11526 { echo "$as_me:$LINENO: WARNING: tiffio.h: see the Autoconf documentation" >&5
11527echo "$as_me: WARNING: tiffio.h: see the Autoconf documentation" >&2;}
11528 { echo "$as_me:$LINENO: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&5
11529echo "$as_me: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11530 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
19650fd6 11531echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11532 { echo "$as_me:$LINENO: WARNING: tiffio.h: in the future, the compiler will take precedence" >&5
11533echo "$as_me: WARNING: tiffio.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11534 (
11535 cat <<\_ASBOX
35996d22
AS
11536## ------------------------------------------ ##
11537## Report this to the AC_PACKAGE_NAME lists. ##
11538## ------------------------------------------ ##
19650fd6
AS
11539_ASBOX
11540 ) |
11541 sed "s/^/$as_me: WARNING: /" >&2
11542 ;;
c0d27fcc
MR
11543esac
11544echo "$as_me:$LINENO: checking for tiffio.h" >&5
11545echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11546if test "${ac_cv_header_tiffio_h+set}" = set; then
11547 echo $ECHO_N "(cached) $ECHO_C" >&6
11548else
11549 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 11550fi
c0d27fcc 11551echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 11552echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
11553
11554fi
98418dba
CW
11555if test $ac_cv_header_tiffio_h = yes; then
11556 tifflibs="-lz -lm"
11557 # At least one tiff package requires the jpeg library.
11558 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 11559 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
11560echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
11561if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 11562 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11563else
503d2be0 11564 ac_check_lib_save_LIBS=$LIBS
98418dba 11565LIBS="-ltiff $tifflibs $LIBS"
503d2be0 11566cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11567/* confdefs.h. */
11568_ACEOF
11569cat confdefs.h >>conftest.$ac_ext
11570cat >>conftest.$ac_ext <<_ACEOF
11571/* end confdefs.h. */
503d2be0 11572
73b77ee5 11573/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11574#ifdef __cplusplus
11575extern "C"
11576#endif
73b77ee5 11577/* We use char because int might match the return type of a gcc2
503d2be0 11578 builtin and then its argument prototype would still apply. */
98418dba 11579char TIFFGetVersion ();
503d2be0
AS
11580int
11581main ()
11582{
98418dba 11583TIFFGetVersion ();
503d2be0
AS
11584 ;
11585 return 0;
11586}
11587_ACEOF
11588rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11589if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11590 (eval $ac_link) 2>conftest.er1
503d2be0 11591 ac_status=$?
35996d22
AS
11592 grep -v '^ *+' conftest.er1 >conftest.err
11593 rm -f conftest.er1
11594 cat conftest.err >&5
c0d27fcc 11595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11596 (exit $ac_status); } &&
35996d22
AS
11597 { ac_try='test -z "$ac_c_werror_flag"
11598 || test ! -s conftest.err'
11599 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11600 (eval $ac_try) 2>&5
11601 ac_status=$?
11602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11603 (exit $ac_status); }; } &&
11604 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11606 (eval $ac_try) 2>&5
11607 ac_status=$?
c0d27fcc 11608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11609 (exit $ac_status); }; }; then
98418dba 11610 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
11611else
11612 echo "$as_me: failed program was:" >&5
19650fd6
AS
11613sed 's/^/| /' conftest.$ac_ext >&5
11614
98418dba 11615ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0 11616fi
35996d22
AS
11617rm -f conftest.err conftest.$ac_objext \
11618 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
11619LIBS=$ac_check_lib_save_LIBS
11620fi
c0d27fcc 11621echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
11622echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
11623if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
11624 HAVE_TIFF=yes
11625fi
11626
11627fi
73b77ee5 11628
c0d27fcc 11629
98418dba
CW
11630 fi
11631
11632 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 11633
c0d27fcc 11634cat >>confdefs.h <<\_ACEOF
98418dba 11635#define HAVE_TIFF 1
c0d27fcc 11636_ACEOF
98418dba
CW
11637
11638 fi
73b77ee5
GM
11639fi
11640
98418dba
CW
11641### Use -lgif if available, unless `--with-gif=no'.
11642HAVE_GIF=no
11643if test "${HAVE_X11}" = "yes"; then
11644 if test "${with_gif}" != "no"; then
c0d27fcc
MR
11645 if test "${ac_cv_header_gif_lib_h+set}" = set; then
11646 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
11647echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11648if test "${ac_cv_header_gif_lib_h+set}" = set; then
11649 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11650fi
11651echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
11652echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 11653else
c0d27fcc
MR
11654 # Is the header compilable?
11655echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
11656echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
11657cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11658/* confdefs.h. */
11659_ACEOF
11660cat confdefs.h >>conftest.$ac_ext
11661cat >>conftest.$ac_ext <<_ACEOF
11662/* end confdefs.h. */
c0d27fcc
MR
11663$ac_includes_default
11664#include <gif_lib.h>
11665_ACEOF
11666rm -f conftest.$ac_objext
11667if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11668 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11669 ac_status=$?
35996d22
AS
11670 grep -v '^ *+' conftest.er1 >conftest.err
11671 rm -f conftest.er1
11672 cat conftest.err >&5
c0d27fcc
MR
11673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11674 (exit $ac_status); } &&
35996d22
AS
11675 { ac_try='test -z "$ac_c_werror_flag"
11676 || test ! -s conftest.err'
11677 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11678 (eval $ac_try) 2>&5
11679 ac_status=$?
11680 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11681 (exit $ac_status); }; } &&
11682 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11683 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11684 (eval $ac_try) 2>&5
11685 ac_status=$?
11686 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11687 (exit $ac_status); }; }; then
11688 ac_header_compiler=yes
11689else
11690 echo "$as_me: failed program was:" >&5
19650fd6
AS
11691sed 's/^/| /' conftest.$ac_ext >&5
11692
c0d27fcc
MR
11693ac_header_compiler=no
11694fi
35996d22 11695rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11696echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11697echo "${ECHO_T}$ac_header_compiler" >&6
11698
11699# Is the header present?
11700echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
11701echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
11702cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11703/* confdefs.h. */
11704_ACEOF
11705cat confdefs.h >>conftest.$ac_ext
11706cat >>conftest.$ac_ext <<_ACEOF
11707/* end confdefs.h. */
98418dba
CW
11708#include <gif_lib.h>
11709_ACEOF
c0d27fcc 11710if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11711 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11712 ac_status=$?
6bae0ccf 11713 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11714 rm -f conftest.er1
11715 cat conftest.err >&5
c0d27fcc 11716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11717 (exit $ac_status); } >/dev/null; then
11718 if test -s conftest.err; then
11719 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11720 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11721 else
11722 ac_cpp_err=
11723 fi
11724else
11725 ac_cpp_err=yes
11726fi
11727if test -z "$ac_cpp_err"; then
c0d27fcc 11728 ac_header_preproc=yes
98418dba
CW
11729else
11730 echo "$as_me: failed program was:" >&5
19650fd6
AS
11731sed 's/^/| /' conftest.$ac_ext >&5
11732
c0d27fcc 11733 ac_header_preproc=no
98418dba
CW
11734fi
11735rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11736echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11737echo "${ECHO_T}$ac_header_preproc" >&6
11738
11739# So? What about this header?
35996d22
AS
11740case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11741 yes:no: )
c0d27fcc
MR
11742 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11743echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11744 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the compiler's result" >&5
11745echo "$as_me: WARNING: gif_lib.h: proceeding with the compiler's result" >&2;}
11746 ac_header_preproc=yes
19650fd6 11747 ;;
35996d22 11748 no:yes:* )
c0d27fcc
MR
11749 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
11750echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
35996d22
AS
11751 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
11752echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
11753 { echo "$as_me:$LINENO: WARNING: gif_lib.h: see the Autoconf documentation" >&5
11754echo "$as_me: WARNING: gif_lib.h: see the Autoconf documentation" >&2;}
11755 { echo "$as_me:$LINENO: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&5
11756echo "$as_me: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11757 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
19650fd6 11758echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11759 { echo "$as_me:$LINENO: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&5
11760echo "$as_me: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11761 (
11762 cat <<\_ASBOX
35996d22
AS
11763## ------------------------------------------ ##
11764## Report this to the AC_PACKAGE_NAME lists. ##
11765## ------------------------------------------ ##
19650fd6
AS
11766_ASBOX
11767 ) |
11768 sed "s/^/$as_me: WARNING: /" >&2
11769 ;;
c0d27fcc
MR
11770esac
11771echo "$as_me:$LINENO: checking for gif_lib.h" >&5
11772echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11773if test "${ac_cv_header_gif_lib_h+set}" = set; then
11774 echo $ECHO_N "(cached) $ECHO_C" >&6
11775else
11776 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 11777fi
c0d27fcc 11778echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 11779echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
11780
11781fi
98418dba
CW
11782if test $ac_cv_header_gif_lib_h = yes; then
11783 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
11784# Earlier versions can crash Emacs.
c0d27fcc 11785 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
11786echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
11787if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 11788 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11789else
503d2be0 11790 ac_check_lib_save_LIBS=$LIBS
98418dba 11791LIBS="-lungif $LIBS"
503d2be0 11792cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11793/* confdefs.h. */
11794_ACEOF
11795cat confdefs.h >>conftest.$ac_ext
11796cat >>conftest.$ac_ext <<_ACEOF
11797/* end confdefs.h. */
73b77ee5 11798
98418dba
CW
11799/* Override any gcc2 internal prototype to avoid an error. */
11800#ifdef __cplusplus
11801extern "C"
11802#endif
11803/* We use char because int might match the return type of a gcc2
11804 builtin and then its argument prototype would still apply. */
11805char EGifPutExtensionLast ();
503d2be0
AS
11806int
11807main ()
11808{
98418dba 11809EGifPutExtensionLast ();
503d2be0
AS
11810 ;
11811 return 0;
11812}
11813_ACEOF
11814rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11815if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11816 (eval $ac_link) 2>conftest.er1
503d2be0 11817 ac_status=$?
35996d22
AS
11818 grep -v '^ *+' conftest.er1 >conftest.err
11819 rm -f conftest.er1
11820 cat conftest.err >&5
c0d27fcc 11821 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11822 (exit $ac_status); } &&
35996d22
AS
11823 { ac_try='test -z "$ac_c_werror_flag"
11824 || test ! -s conftest.err'
c0d27fcc 11825 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
11826 (eval $ac_try) 2>&5
11827 ac_status=$?
c0d27fcc 11828 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
11829 (exit $ac_status); }; } &&
11830 { ac_try='test -s conftest$ac_exeext'
11831 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11832 (eval $ac_try) 2>&5
11833 ac_status=$?
11834 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11835 (exit $ac_status); }; }; then
11836 ac_cv_lib_ungif_EGifPutExtensionLast=yes
11837else
98418dba 11838 echo "$as_me: failed program was:" >&5
19650fd6
AS
11839sed 's/^/| /' conftest.$ac_ext >&5
11840
98418dba
CW
11841ac_cv_lib_ungif_EGifPutExtensionLast=no
11842fi
35996d22
AS
11843rm -f conftest.err conftest.$ac_objext \
11844 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
11845LIBS=$ac_check_lib_save_LIBS
11846fi
c0d27fcc 11847echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
11848echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
11849if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
11850 HAVE_GIF=yes
11851fi
11852
11853fi
11854
c0d27fcc 11855
98418dba
CW
11856 fi
11857
11858 if test "${HAVE_GIF}" = "yes"; then
b936fae4 11859
c0d27fcc 11860cat >>confdefs.h <<\_ACEOF
98418dba 11861#define HAVE_GIF 1
c0d27fcc 11862_ACEOF
98418dba
CW
11863
11864 fi
11865fi
11866
c0d27fcc
MR
11867### Use Mac OS X Carbon API to implement GUI.
11868HAVE_CARBON=no
11869if test "${with_carbon}" != "no"; then
11870 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11871 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
11872echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
11873if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11874 echo $ECHO_N "(cached) $ECHO_C" >&6
11875fi
11876echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
11877echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
11878else
11879 # Is the header compilable?
11880echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
11881echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
11882cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11883/* confdefs.h. */
11884_ACEOF
11885cat confdefs.h >>conftest.$ac_ext
11886cat >>conftest.$ac_ext <<_ACEOF
11887/* end confdefs.h. */
c0d27fcc
MR
11888$ac_includes_default
11889#include <Carbon/Carbon.h>
11890_ACEOF
11891rm -f conftest.$ac_objext
11892if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11893 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11894 ac_status=$?
35996d22
AS
11895 grep -v '^ *+' conftest.er1 >conftest.err
11896 rm -f conftest.er1
11897 cat conftest.err >&5
c0d27fcc
MR
11898 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11899 (exit $ac_status); } &&
35996d22
AS
11900 { ac_try='test -z "$ac_c_werror_flag"
11901 || test ! -s conftest.err'
11902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11903 (eval $ac_try) 2>&5
11904 ac_status=$?
11905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11906 (exit $ac_status); }; } &&
11907 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11908 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11909 (eval $ac_try) 2>&5
11910 ac_status=$?
11911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11912 (exit $ac_status); }; }; then
11913 ac_header_compiler=yes
11914else
11915 echo "$as_me: failed program was:" >&5
19650fd6
AS
11916sed 's/^/| /' conftest.$ac_ext >&5
11917
c0d27fcc
MR
11918ac_header_compiler=no
11919fi
35996d22 11920rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11921echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11922echo "${ECHO_T}$ac_header_compiler" >&6
11923
11924# Is the header present?
11925echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
11926echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
11927cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11928/* confdefs.h. */
11929_ACEOF
11930cat confdefs.h >>conftest.$ac_ext
11931cat >>conftest.$ac_ext <<_ACEOF
11932/* end confdefs.h. */
e0f712ba
AC
11933#include <Carbon/Carbon.h>
11934_ACEOF
c0d27fcc 11935if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
e0f712ba
AC
11936 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11937 ac_status=$?
6bae0ccf 11938 grep -v '^ *+' conftest.er1 >conftest.err
e0f712ba
AC
11939 rm -f conftest.er1
11940 cat conftest.err >&5
c0d27fcc 11941 echo "$as_me:$LINENO: \$? = $ac_status" >&5
e0f712ba
AC
11942 (exit $ac_status); } >/dev/null; then
11943 if test -s conftest.err; then
11944 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11945 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
e0f712ba
AC
11946 else
11947 ac_cpp_err=
11948 fi
11949else
11950 ac_cpp_err=yes
11951fi
11952if test -z "$ac_cpp_err"; then
c0d27fcc 11953 ac_header_preproc=yes
e0f712ba
AC
11954else
11955 echo "$as_me: failed program was:" >&5
19650fd6
AS
11956sed 's/^/| /' conftest.$ac_ext >&5
11957
c0d27fcc 11958 ac_header_preproc=no
e0f712ba
AC
11959fi
11960rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11961echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11962echo "${ECHO_T}$ac_header_preproc" >&6
11963
11964# So? What about this header?
35996d22
AS
11965case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11966 yes:no: )
c0d27fcc
MR
11967 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
11968echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11969 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&5
11970echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&2;}
11971 ac_header_preproc=yes
19650fd6 11972 ;;
35996d22 11973 no:yes:* )
c0d27fcc
MR
11974 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
11975echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
35996d22
AS
11976 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
11977echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
11978 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&5
11979echo "$as_me: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&2;}
11980 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&5
11981echo "$as_me: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11982 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
19650fd6 11983echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11984 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&5
11985echo "$as_me: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11986 (
11987 cat <<\_ASBOX
35996d22
AS
11988## ------------------------------------------ ##
11989## Report this to the AC_PACKAGE_NAME lists. ##
11990## ------------------------------------------ ##
19650fd6
AS
11991_ASBOX
11992 ) |
11993 sed "s/^/$as_me: WARNING: /" >&2
11994 ;;
c0d27fcc
MR
11995esac
11996echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
11997echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
11998if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11999 echo $ECHO_N "(cached) $ECHO_C" >&6
12000else
12001 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
e0f712ba 12002fi
c0d27fcc 12003echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
e0f712ba 12004echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
c0d27fcc
MR
12005
12006fi
e0f712ba
AC
12007if test $ac_cv_header_Carbon_Carbon_h = yes; then
12008 HAVE_CARBON=yes
12009fi
12010
c0d27fcc 12011
e0f712ba
AC
12012fi
12013
12014if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 12015
c0d27fcc 12016cat >>confdefs.h <<\_ACEOF
e0f712ba 12017#define HAVE_CARBON 1
c0d27fcc 12018_ACEOF
e0f712ba 12019
6a3a24fa
JD
12020 window_system=mac
12021 ## Specify the install directory
12022 carbon_appdir=
12023 if test "${carbon_appdir_x}" != ""; then
12024 case ${carbon_appdir_x} in
12025 y | ye | yes) carbon_appdir=/Applications ;;
12026 * ) carbon_appdir=${carbon_appdir_x} ;;
12027 esac
12028 fi
8f417b3b
AS
12029 # We also have mouse menus.
12030 HAVE_MENUS=yes
e0f712ba
AC
12031fi
12032
98418dba
CW
12033### Use session management (-lSM -lICE) if available
12034HAVE_X_SM=no
12035if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
12036 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12037 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
12038echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12039if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12040 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12041fi
12042echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
12043echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 12044else
c0d27fcc
MR
12045 # Is the header compilable?
12046echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
12047echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
12048cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12049/* confdefs.h. */
12050_ACEOF
12051cat confdefs.h >>conftest.$ac_ext
12052cat >>conftest.$ac_ext <<_ACEOF
12053/* end confdefs.h. */
c0d27fcc
MR
12054$ac_includes_default
12055#include <X11/SM/SMlib.h>
12056_ACEOF
12057rm -f conftest.$ac_objext
12058if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 12059 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12060 ac_status=$?
35996d22
AS
12061 grep -v '^ *+' conftest.er1 >conftest.err
12062 rm -f conftest.er1
12063 cat conftest.err >&5
c0d27fcc
MR
12064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12065 (exit $ac_status); } &&
35996d22
AS
12066 { ac_try='test -z "$ac_c_werror_flag"
12067 || test ! -s conftest.err'
12068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12069 (eval $ac_try) 2>&5
12070 ac_status=$?
12071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12072 (exit $ac_status); }; } &&
12073 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12075 (eval $ac_try) 2>&5
12076 ac_status=$?
12077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12078 (exit $ac_status); }; }; then
12079 ac_header_compiler=yes
12080else
12081 echo "$as_me: failed program was:" >&5
19650fd6
AS
12082sed 's/^/| /' conftest.$ac_ext >&5
12083
c0d27fcc
MR
12084ac_header_compiler=no
12085fi
35996d22 12086rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12087echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12088echo "${ECHO_T}$ac_header_compiler" >&6
12089
12090# Is the header present?
12091echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
12092echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
12093cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12094/* confdefs.h. */
12095_ACEOF
12096cat confdefs.h >>conftest.$ac_ext
12097cat >>conftest.$ac_ext <<_ACEOF
12098/* end confdefs.h. */
98418dba
CW
12099#include <X11/SM/SMlib.h>
12100_ACEOF
c0d27fcc 12101if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12102 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12103 ac_status=$?
6bae0ccf 12104 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12105 rm -f conftest.er1
12106 cat conftest.err >&5
c0d27fcc 12107 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12108 (exit $ac_status); } >/dev/null; then
12109 if test -s conftest.err; then
12110 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 12111 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12112 else
12113 ac_cpp_err=
12114 fi
12115else
12116 ac_cpp_err=yes
503d2be0 12117fi
98418dba 12118if test -z "$ac_cpp_err"; then
c0d27fcc 12119 ac_header_preproc=yes
98418dba
CW
12120else
12121 echo "$as_me: failed program was:" >&5
19650fd6
AS
12122sed 's/^/| /' conftest.$ac_ext >&5
12123
c0d27fcc 12124 ac_header_preproc=no
98418dba
CW
12125fi
12126rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12127echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12128echo "${ECHO_T}$ac_header_preproc" >&6
12129
12130# So? What about this header?
35996d22
AS
12131case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12132 yes:no: )
c0d27fcc
MR
12133 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12134echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
12135 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&5
12136echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&2;}
12137 ac_header_preproc=yes
19650fd6 12138 ;;
35996d22 12139 no:yes:* )
c0d27fcc
MR
12140 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
12141echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
35996d22
AS
12142 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
12143echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
12144 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&5
12145echo "$as_me: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&2;}
12146 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&5
12147echo "$as_me: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12148 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
19650fd6 12149echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
12150 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&5
12151echo "$as_me: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12152 (
12153 cat <<\_ASBOX
35996d22
AS
12154## ------------------------------------------ ##
12155## Report this to the AC_PACKAGE_NAME lists. ##
12156## ------------------------------------------ ##
19650fd6
AS
12157_ASBOX
12158 ) |
12159 sed "s/^/$as_me: WARNING: /" >&2
12160 ;;
c0d27fcc
MR
12161esac
12162echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
12163echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12164if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12165 echo $ECHO_N "(cached) $ECHO_C" >&6
12166else
12167 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 12168fi
c0d27fcc 12169echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 12170echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
12171
12172fi
98418dba 12173if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 12174 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
12175echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
12176if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 12177 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12178else
503d2be0 12179 ac_check_lib_save_LIBS=$LIBS
1660500f 12180LIBS="-lSM -lICE $LIBS"
503d2be0 12181cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12182/* confdefs.h. */
12183_ACEOF
12184cat confdefs.h >>conftest.$ac_ext
12185cat >>conftest.$ac_ext <<_ACEOF
12186/* end confdefs.h. */
503d2be0 12187
73b77ee5 12188/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12189#ifdef __cplusplus
12190extern "C"
12191#endif
73b77ee5 12192/* We use char because int might match the return type of a gcc2
503d2be0 12193 builtin and then its argument prototype would still apply. */
98418dba 12194char SmcOpenConnection ();
503d2be0
AS
12195int
12196main ()
12197{
98418dba 12198SmcOpenConnection ();
503d2be0
AS
12199 ;
12200 return 0;
12201}
12202_ACEOF
12203rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12204if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12205 (eval $ac_link) 2>conftest.er1
503d2be0 12206 ac_status=$?
35996d22
AS
12207 grep -v '^ *+' conftest.er1 >conftest.err
12208 rm -f conftest.er1
12209 cat conftest.err >&5
c0d27fcc 12210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12211 (exit $ac_status); } &&
35996d22
AS
12212 { ac_try='test -z "$ac_c_werror_flag"
12213 || test ! -s conftest.err'
12214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12215 (eval $ac_try) 2>&5
12216 ac_status=$?
12217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12218 (exit $ac_status); }; } &&
12219 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12221 (eval $ac_try) 2>&5
12222 ac_status=$?
c0d27fcc 12223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12224 (exit $ac_status); }; }; then
98418dba 12225 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
12226else
12227 echo "$as_me: failed program was:" >&5
19650fd6
AS
12228sed 's/^/| /' conftest.$ac_ext >&5
12229
98418dba 12230ac_cv_lib_SM_SmcOpenConnection=no
503d2be0 12231fi
35996d22
AS
12232rm -f conftest.err conftest.$ac_objext \
12233 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
12234LIBS=$ac_check_lib_save_LIBS
12235fi
c0d27fcc 12236echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
12237echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
12238if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
12239 HAVE_X_SM=yes
73b77ee5
GM
12240fi
12241
73b77ee5 12242fi
73b77ee5 12243
c0d27fcc
MR
12244
12245
98418dba 12246 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 12247
c0d27fcc 12248cat >>confdefs.h <<\_ACEOF
98418dba 12249#define HAVE_X_SM 1
c0d27fcc 12250_ACEOF
73b77ee5 12251
98418dba
CW
12252 case "$LIBS" in
12253 *-lSM*) ;;
12254 *) LIBS="-lSM -lICE $LIBS" ;;
12255 esac
73b77ee5 12256 fi
98418dba 12257fi
73b77ee5 12258
98418dba 12259# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 12260echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
12261echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
12262if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
12263 echo $ECHO_N "(cached) $ECHO_C" >&6
12264else
12265 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12266/* confdefs.h. */
12267_ACEOF
12268cat confdefs.h >>conftest.$ac_ext
12269cat >>conftest.$ac_ext <<_ACEOF
12270/* end confdefs.h. */
98418dba 12271#include <netdb.h>
503d2be0
AS
12272int
12273main ()
12274{
98418dba 12275return h_errno;
503d2be0
AS
12276 ;
12277 return 0;
12278}
12279_ACEOF
12280rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12281if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12282 (eval $ac_link) 2>conftest.er1
503d2be0 12283 ac_status=$?
35996d22
AS
12284 grep -v '^ *+' conftest.er1 >conftest.err
12285 rm -f conftest.er1
12286 cat conftest.err >&5
c0d27fcc 12287 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12288 (exit $ac_status); } &&
35996d22
AS
12289 { ac_try='test -z "$ac_c_werror_flag"
12290 || test ! -s conftest.err'
12291 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12292 (eval $ac_try) 2>&5
12293 ac_status=$?
12294 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12295 (exit $ac_status); }; } &&
12296 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12297 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12298 (eval $ac_try) 2>&5
12299 ac_status=$?
c0d27fcc 12300 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12301 (exit $ac_status); }; }; then
98418dba 12302 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 12303else
503d2be0 12304 echo "$as_me: failed program was:" >&5
19650fd6
AS
12305sed 's/^/| /' conftest.$ac_ext >&5
12306
98418dba 12307emacs_cv_netdb_declares_h_errno=no
73b77ee5 12308fi
35996d22
AS
12309rm -f conftest.err conftest.$ac_objext \
12310 conftest$ac_exeext conftest.$ac_ext
98418dba 12311fi
c0d27fcc 12312echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
12313echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
12314if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 12315
c0d27fcc 12316cat >>confdefs.h <<\_ACEOF
98418dba 12317#define HAVE_H_ERRNO 1
c0d27fcc 12318_ACEOF
73b77ee5 12319
98418dba
CW
12320fi
12321
12322# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
12323# for constant arguments. Useless!
c0d27fcc 12324echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
12325echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
12326if test "${ac_cv_working_alloca_h+set}" = set; then
12327 echo $ECHO_N "(cached) $ECHO_C" >&6
12328else
12329 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12330/* confdefs.h. */
12331_ACEOF
12332cat confdefs.h >>conftest.$ac_ext
12333cat >>conftest.$ac_ext <<_ACEOF
12334/* end confdefs.h. */
98418dba 12335#include <alloca.h>
503d2be0
AS
12336int
12337main ()
12338{
98418dba 12339char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
12340 ;
12341 return 0;
12342}
12343_ACEOF
12344rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12345if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12346 (eval $ac_link) 2>conftest.er1
503d2be0 12347 ac_status=$?
35996d22
AS
12348 grep -v '^ *+' conftest.er1 >conftest.err
12349 rm -f conftest.er1
12350 cat conftest.err >&5
c0d27fcc 12351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12352 (exit $ac_status); } &&
35996d22
AS
12353 { ac_try='test -z "$ac_c_werror_flag"
12354 || test ! -s conftest.err'
12355 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12356 (eval $ac_try) 2>&5
12357 ac_status=$?
12358 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12359 (exit $ac_status); }; } &&
12360 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12361 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12362 (eval $ac_try) 2>&5
12363 ac_status=$?
c0d27fcc 12364 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12365 (exit $ac_status); }; }; then
98418dba 12366 ac_cv_working_alloca_h=yes
73b77ee5 12367else
503d2be0 12368 echo "$as_me: failed program was:" >&5
19650fd6
AS
12369sed 's/^/| /' conftest.$ac_ext >&5
12370
98418dba 12371ac_cv_working_alloca_h=no
73b77ee5 12372fi
35996d22
AS
12373rm -f conftest.err conftest.$ac_objext \
12374 conftest$ac_exeext conftest.$ac_ext
98418dba 12375fi
c0d27fcc 12376echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
12377echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
12378if test $ac_cv_working_alloca_h = yes; then
73b77ee5 12379
c0d27fcc 12380cat >>confdefs.h <<\_ACEOF
98418dba 12381#define HAVE_ALLOCA_H 1
c0d27fcc 12382_ACEOF
98418dba
CW
12383
12384fi
12385
c0d27fcc 12386echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
12387echo $ECHO_N "checking for alloca... $ECHO_C" >&6
12388if test "${ac_cv_func_alloca_works+set}" = set; then
12389 echo $ECHO_N "(cached) $ECHO_C" >&6
12390else
503d2be0 12391 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12392/* confdefs.h. */
12393_ACEOF
12394cat confdefs.h >>conftest.$ac_ext
12395cat >>conftest.$ac_ext <<_ACEOF
12396/* end confdefs.h. */
98418dba
CW
12397#ifdef __GNUC__
12398# define alloca __builtin_alloca
12399#else
12400# ifdef _MSC_VER
12401# include <malloc.h>
12402# define alloca _alloca
12403# else
12404# if HAVE_ALLOCA_H
12405# include <alloca.h>
12406# else
12407# ifdef _AIX
12408 #pragma alloca
12409# else
12410# ifndef alloca /* predefined by HP cc +Olibcalls */
12411char *alloca ();
12412# endif
12413# endif
12414# endif
12415# endif
12416#endif
12417
503d2be0
AS
12418int
12419main ()
12420{
98418dba 12421char *p = (char *) alloca (1);
503d2be0
AS
12422 ;
12423 return 0;
12424}
12425_ACEOF
12426rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12427if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12428 (eval $ac_link) 2>conftest.er1
503d2be0 12429 ac_status=$?
35996d22
AS
12430 grep -v '^ *+' conftest.er1 >conftest.err
12431 rm -f conftest.er1
12432 cat conftest.err >&5
c0d27fcc 12433 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12434 (exit $ac_status); } &&
35996d22
AS
12435 { ac_try='test -z "$ac_c_werror_flag"
12436 || test ! -s conftest.err'
12437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12438 (eval $ac_try) 2>&5
12439 ac_status=$?
12440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12441 (exit $ac_status); }; } &&
12442 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12443 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12444 (eval $ac_try) 2>&5
12445 ac_status=$?
c0d27fcc 12446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12447 (exit $ac_status); }; }; then
98418dba 12448 ac_cv_func_alloca_works=yes
ac95a621 12449else
503d2be0 12450 echo "$as_me: failed program was:" >&5
19650fd6
AS
12451sed 's/^/| /' conftest.$ac_ext >&5
12452
98418dba 12453ac_cv_func_alloca_works=no
ac95a621 12454fi
35996d22
AS
12455rm -f conftest.err conftest.$ac_objext \
12456 conftest$ac_exeext conftest.$ac_ext
98418dba 12457fi
c0d27fcc 12458echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 12459echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 12460
98418dba
CW
12461if test $ac_cv_func_alloca_works = yes; then
12462
c0d27fcc 12463cat >>confdefs.h <<\_ACEOF
98418dba 12464#define HAVE_ALLOCA 1
c0d27fcc 12465_ACEOF
98418dba
CW
12466
12467else
12468 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12469# that cause trouble. Some versions do not even contain alloca or
12470# contain a buggy version. If you still want to use their alloca,
12471# use ar to extract alloca.o from them instead of compiling alloca.c.
12472
12473ALLOCA=alloca.$ac_objext
12474
c0d27fcc 12475cat >>confdefs.h <<\_ACEOF
98418dba 12476#define C_ALLOCA 1
c0d27fcc 12477_ACEOF
98418dba 12478
c0d27fcc
MR
12479
12480echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
12481echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
12482if test "${ac_cv_os_cray+set}" = set; then
12483 echo $ECHO_N "(cached) $ECHO_C" >&6
12484else
12485 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12486/* confdefs.h. */
12487_ACEOF
12488cat confdefs.h >>conftest.$ac_ext
12489cat >>conftest.$ac_ext <<_ACEOF
12490/* end confdefs.h. */
98418dba
CW
12491#if defined(CRAY) && ! defined(CRAY2)
12492webecray
12493#else
12494wenotbecray
12495#endif
12496
12497_ACEOF
12498if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 12499 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
12500 ac_cv_os_cray=yes
12501else
12502 ac_cv_os_cray=no
12503fi
12504rm -f conftest*
ac95a621 12505
98418dba 12506fi
c0d27fcc 12507echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
12508echo "${ECHO_T}$ac_cv_os_cray" >&6
12509if test $ac_cv_os_cray = yes; then
12510 for ac_func in _getb67 GETB67 getb67; do
12511 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12512echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12513echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12514if eval "test \"\${$as_ac_var+set}\" = set"; then
12515 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12516else
503d2be0 12517 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12518/* confdefs.h. */
12519_ACEOF
12520cat confdefs.h >>conftest.$ac_ext
12521cat >>conftest.$ac_ext <<_ACEOF
12522/* end confdefs.h. */
35996d22
AS
12523/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12524 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12525#define $ac_func innocuous_$ac_func
12526
73b77ee5 12527/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12528 which can conflict with char $ac_func (); below.
12529 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12530 <limits.h> exists even on freestanding compilers. */
35996d22 12531
19650fd6
AS
12532#ifdef __STDC__
12533# include <limits.h>
12534#else
12535# include <assert.h>
12536#endif
35996d22
AS
12537
12538#undef $ac_func
12539
73b77ee5 12540/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12541#ifdef __cplusplus
12542extern "C"
19650fd6 12543{
503d2be0 12544#endif
73b77ee5 12545/* We use char because int might match the return type of a gcc2
503d2be0
AS
12546 builtin and then its argument prototype would still apply. */
12547char $ac_func ();
73b77ee5
GM
12548/* The GNU C library defines this for functions which it implements
12549 to always fail with ENOSYS. Some functions are actually named
12550 something starting with __ and the normal name is an alias. */
12551#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12552choke me
12553#else
19650fd6
AS
12554char (*f) () = $ac_func;
12555#endif
12556#ifdef __cplusplus
12557}
73b77ee5
GM
12558#endif
12559
19650fd6
AS
12560int
12561main ()
12562{
12563return f != $ac_func;
503d2be0
AS
12564 ;
12565 return 0;
12566}
12567_ACEOF
12568rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12569if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12570 (eval $ac_link) 2>conftest.er1
503d2be0 12571 ac_status=$?
35996d22
AS
12572 grep -v '^ *+' conftest.er1 >conftest.err
12573 rm -f conftest.er1
12574 cat conftest.err >&5
c0d27fcc 12575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12576 (exit $ac_status); } &&
35996d22
AS
12577 { ac_try='test -z "$ac_c_werror_flag"
12578 || test ! -s conftest.err'
12579 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12580 (eval $ac_try) 2>&5
12581 ac_status=$?
12582 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12583 (exit $ac_status); }; } &&
12584 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12585 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12586 (eval $ac_try) 2>&5
12587 ac_status=$?
c0d27fcc 12588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12589 (exit $ac_status); }; }; then
12590 eval "$as_ac_var=yes"
12591else
12592 echo "$as_me: failed program was:" >&5
19650fd6
AS
12593sed 's/^/| /' conftest.$ac_ext >&5
12594
503d2be0
AS
12595eval "$as_ac_var=no"
12596fi
35996d22
AS
12597rm -f conftest.err conftest.$ac_objext \
12598 conftest$ac_exeext conftest.$ac_ext
503d2be0 12599fi
c0d27fcc 12600echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12601echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12602if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 12603
c0d27fcc 12604cat >>confdefs.h <<_ACEOF
98418dba 12605#define CRAY_STACKSEG_END $ac_func
c0d27fcc 12606_ACEOF
98418dba
CW
12607
12608 break
73b77ee5 12609fi
73b77ee5 12610
98418dba 12611 done
73b77ee5
GM
12612fi
12613
c0d27fcc 12614echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
12615echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
12616if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 12617 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
12618else
12619 if test "$cross_compiling" = yes; then
12620 ac_cv_c_stack_direction=0
73b77ee5 12621else
503d2be0 12622 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12623/* confdefs.h. */
12624_ACEOF
12625cat confdefs.h >>conftest.$ac_ext
12626cat >>conftest.$ac_ext <<_ACEOF
12627/* end confdefs.h. */
503d2be0 12628int
98418dba 12629find_stack_direction ()
503d2be0 12630{
98418dba
CW
12631 static char *addr = 0;
12632 auto char dummy;
12633 if (addr == 0)
12634 {
12635 addr = &dummy;
12636 return find_stack_direction ();
12637 }
73b77ee5 12638 else
98418dba
CW
12639 return (&dummy > addr) ? 1 : -1;
12640}
ba4481b5 12641
503d2be0
AS
12642int
12643main ()
12644{
98418dba 12645 exit (find_stack_direction () < 0);
503d2be0
AS
12646}
12647_ACEOF
98418dba 12648rm -f conftest$ac_exeext
c0d27fcc 12649if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12650 (eval $ac_link) 2>&5
12651 ac_status=$?
c0d27fcc 12652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12653 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 12654 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12655 (eval $ac_try) 2>&5
12656 ac_status=$?
c0d27fcc 12657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12658 (exit $ac_status); }; }; then
98418dba 12659 ac_cv_c_stack_direction=1
ba4481b5 12660else
98418dba
CW
12661 echo "$as_me: program exited with status $ac_status" >&5
12662echo "$as_me: failed program was:" >&5
19650fd6
AS
12663sed 's/^/| /' conftest.$ac_ext >&5
12664
c0d27fcc 12665( exit $ac_status )
98418dba 12666ac_cv_c_stack_direction=-1
ba4481b5 12667fi
35996d22 12668rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 12669fi
98418dba 12670fi
c0d27fcc 12671echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
12672echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
12673
c0d27fcc 12674cat >>confdefs.h <<_ACEOF
98418dba 12675#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
12676_ACEOF
12677
ba4481b5 12678
ba4481b5
DL
12679fi
12680
c0d27fcc 12681
98418dba
CW
12682# fmod, logb, and frexp are found in -lm on most systems.
12683# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12684
c0d27fcc 12685echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
12686echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
12687if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 12688 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12689else
98418dba
CW
12690 ac_check_lib_save_LIBS=$LIBS
12691LIBS="-lm $LIBS"
12692cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12693/* confdefs.h. */
12694_ACEOF
12695cat confdefs.h >>conftest.$ac_ext
12696cat >>conftest.$ac_ext <<_ACEOF
12697/* end confdefs.h. */
ba4481b5 12698
98418dba
CW
12699/* Override any gcc2 internal prototype to avoid an error. */
12700#ifdef __cplusplus
12701extern "C"
12702#endif
12703/* We use char because int might match the return type of a gcc2
12704 builtin and then its argument prototype would still apply. */
12705char sqrt ();
503d2be0
AS
12706int
12707main ()
12708{
98418dba 12709sqrt ();
503d2be0
AS
12710 ;
12711 return 0;
12712}
12713_ACEOF
12714rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12715if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12716 (eval $ac_link) 2>conftest.er1
503d2be0 12717 ac_status=$?
35996d22
AS
12718 grep -v '^ *+' conftest.er1 >conftest.err
12719 rm -f conftest.er1
12720 cat conftest.err >&5
c0d27fcc 12721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12722 (exit $ac_status); } &&
35996d22
AS
12723 { ac_try='test -z "$ac_c_werror_flag"
12724 || test ! -s conftest.err'
12725 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12726 (eval $ac_try) 2>&5
12727 ac_status=$?
12728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12729 (exit $ac_status); }; } &&
12730 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12731 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12732 (eval $ac_try) 2>&5
12733 ac_status=$?
c0d27fcc 12734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12735 (exit $ac_status); }; }; then
98418dba 12736 ac_cv_lib_m_sqrt=yes
ba4481b5 12737else
503d2be0 12738 echo "$as_me: failed program was:" >&5
19650fd6
AS
12739sed 's/^/| /' conftest.$ac_ext >&5
12740
98418dba 12741ac_cv_lib_m_sqrt=no
ba4481b5 12742fi
35996d22
AS
12743rm -f conftest.err conftest.$ac_objext \
12744 conftest$ac_exeext conftest.$ac_ext
98418dba 12745LIBS=$ac_check_lib_save_LIBS
ba4481b5 12746fi
c0d27fcc 12747echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
12748echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
12749if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 12750 cat >>confdefs.h <<_ACEOF
98418dba 12751#define HAVE_LIBM 1
c0d27fcc 12752_ACEOF
98418dba
CW
12753
12754 LIBS="-lm $LIBS"
ba4481b5 12755
ba4481b5
DL
12756fi
12757
c0d27fcc 12758
55597d70
DL
12759# Check for mail-locking functions in a "mail" library. Probably this should
12760# have the same check as for liblockfile below.
98418dba 12761
c0d27fcc 12762echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
12763echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
12764if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 12765 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12766else
98418dba
CW
12767 ac_check_lib_save_LIBS=$LIBS
12768LIBS="-lmail $LIBS"
12769cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12770/* confdefs.h. */
12771_ACEOF
12772cat confdefs.h >>conftest.$ac_ext
12773cat >>conftest.$ac_ext <<_ACEOF
12774/* end confdefs.h. */
98418dba
CW
12775
12776/* Override any gcc2 internal prototype to avoid an error. */
12777#ifdef __cplusplus
12778extern "C"
12779#endif
12780/* We use char because int might match the return type of a gcc2
12781 builtin and then its argument prototype would still apply. */
12782char maillock ();
503d2be0
AS
12783int
12784main ()
12785{
98418dba 12786maillock ();
503d2be0
AS
12787 ;
12788 return 0;
12789}
12790_ACEOF
12791rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12792if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12793 (eval $ac_link) 2>conftest.er1
503d2be0 12794 ac_status=$?
35996d22
AS
12795 grep -v '^ *+' conftest.er1 >conftest.err
12796 rm -f conftest.er1
12797 cat conftest.err >&5
c0d27fcc 12798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12799 (exit $ac_status); } &&
35996d22
AS
12800 { ac_try='test -z "$ac_c_werror_flag"
12801 || test ! -s conftest.err'
12802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12803 (eval $ac_try) 2>&5
12804 ac_status=$?
12805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12806 (exit $ac_status); }; } &&
12807 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12808 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12809 (eval $ac_try) 2>&5
12810 ac_status=$?
c0d27fcc 12811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12812 (exit $ac_status); }; }; then
98418dba 12813 ac_cv_lib_mail_maillock=yes
ba4481b5 12814else
503d2be0 12815 echo "$as_me: failed program was:" >&5
19650fd6
AS
12816sed 's/^/| /' conftest.$ac_ext >&5
12817
98418dba 12818ac_cv_lib_mail_maillock=no
ba4481b5 12819fi
35996d22
AS
12820rm -f conftest.err conftest.$ac_objext \
12821 conftest$ac_exeext conftest.$ac_ext
98418dba 12822LIBS=$ac_check_lib_save_LIBS
ba4481b5 12823fi
c0d27fcc 12824echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
12825echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
12826if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 12827 cat >>confdefs.h <<_ACEOF
98418dba 12828#define HAVE_LIBMAIL 1
c0d27fcc 12829_ACEOF
ba4481b5 12830
98418dba 12831 LIBS="-lmail $LIBS"
ba4481b5 12832
98418dba 12833fi
ba4481b5 12834
c0d27fcc
MR
12835
12836echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
12837echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
12838if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 12839 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12840else
503d2be0 12841 ac_check_lib_save_LIBS=$LIBS
98418dba 12842LIBS="-llockfile $LIBS"
503d2be0 12843cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12844/* confdefs.h. */
12845_ACEOF
12846cat confdefs.h >>conftest.$ac_ext
12847cat >>conftest.$ac_ext <<_ACEOF
12848/* end confdefs.h. */
503d2be0 12849
ba4481b5 12850/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12851#ifdef __cplusplus
12852extern "C"
12853#endif
ba4481b5 12854/* We use char because int might match the return type of a gcc2
503d2be0 12855 builtin and then its argument prototype would still apply. */
98418dba 12856char maillock ();
503d2be0
AS
12857int
12858main ()
12859{
98418dba 12860maillock ();
503d2be0
AS
12861 ;
12862 return 0;
12863}
12864_ACEOF
12865rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12866if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12867 (eval $ac_link) 2>conftest.er1
503d2be0 12868 ac_status=$?
35996d22
AS
12869 grep -v '^ *+' conftest.er1 >conftest.err
12870 rm -f conftest.er1
12871 cat conftest.err >&5
c0d27fcc 12872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12873 (exit $ac_status); } &&
35996d22
AS
12874 { ac_try='test -z "$ac_c_werror_flag"
12875 || test ! -s conftest.err'
12876 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12877 (eval $ac_try) 2>&5
12878 ac_status=$?
12879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12880 (exit $ac_status); }; } &&
12881 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12882 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12883 (eval $ac_try) 2>&5
12884 ac_status=$?
c0d27fcc 12885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12886 (exit $ac_status); }; }; then
98418dba 12887 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
12888else
12889 echo "$as_me: failed program was:" >&5
19650fd6
AS
12890sed 's/^/| /' conftest.$ac_ext >&5
12891
98418dba
CW
12892ac_cv_lib_lockfile_maillock=no
12893fi
35996d22
AS
12894rm -f conftest.err conftest.$ac_objext \
12895 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12896LIBS=$ac_check_lib_save_LIBS
12897fi
c0d27fcc 12898echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
12899echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
12900if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 12901 cat >>confdefs.h <<_ACEOF
98418dba 12902#define HAVE_LIBLOCKFILE 1
c0d27fcc 12903_ACEOF
98418dba
CW
12904
12905 LIBS="-llockfile $LIBS"
12906
12907fi
12908
12909# If we have the shared liblockfile, assume we must use it for mail
12910# locking (e.g. Debian). If we couldn't link against liblockfile
12911# (no liblockfile.a installed), ensure that we don't need to.
12912if test "$ac_cv_lib_lockfile_maillock" = no; then
12913 # Extract the first word of "liblockfile.so", so it can be a program name with args.
12914set dummy liblockfile.so; ac_word=$2
c0d27fcc 12915echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
12916echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12917if test "${ac_cv_prog_liblockfile+set}" = set; then
12918 echo $ECHO_N "(cached) $ECHO_C" >&6
12919else
12920 if test -n "$liblockfile"; then
12921 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
12922else
c0d27fcc 12923as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
12924as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
12925for as_dir in $as_dummy
c0d27fcc
MR
12926do
12927 IFS=$as_save_IFS
12928 test -z "$as_dir" && as_dir=.
12929 for ac_exec_ext in '' $ac_executable_extensions; do
12930 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12931 ac_cv_prog_liblockfile="yes"
12932 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12933 break 2
12934 fi
12935done
98418dba
CW
12936done
12937
12938 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 12939fi
503d2be0 12940fi
98418dba
CW
12941liblockfile=$ac_cv_prog_liblockfile
12942if test -n "$liblockfile"; then
c0d27fcc 12943 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
12944echo "${ECHO_T}$liblockfile" >&6
12945else
c0d27fcc 12946 echo "$as_me:$LINENO: result: no" >&5
98418dba 12947echo "${ECHO_T}no" >&6
ba4481b5
DL
12948fi
12949
98418dba 12950 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 12951 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
12952This probably means that movemail could lose mail.
12953There may be a \`development' package to install containing liblockfile." >&5
12954echo "$as_me: error: Shared liblockfile found but can't link against it.
12955This probably means that movemail could lose mail.
12956There may be a \`development' package to install containing liblockfile." >&2;}
12957 { (exit 1); exit 1; }; }
98418dba 12958 else :
55597d70 12959 fi
98418dba 12960fi
503d2be0 12961
98418dba
CW
12962for ac_func in touchlock
12963do
12964as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12965echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
12966echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12967if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 12968 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 12969else
98418dba 12970 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12971/* confdefs.h. */
12972_ACEOF
12973cat confdefs.h >>conftest.$ac_ext
12974cat >>conftest.$ac_ext <<_ACEOF
12975/* end confdefs.h. */
35996d22
AS
12976/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12977 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12978#define $ac_func innocuous_$ac_func
12979
98418dba 12980/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12981 which can conflict with char $ac_func (); below.
12982 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12983 <limits.h> exists even on freestanding compilers. */
35996d22 12984
19650fd6
AS
12985#ifdef __STDC__
12986# include <limits.h>
12987#else
12988# include <assert.h>
12989#endif
35996d22
AS
12990
12991#undef $ac_func
12992
457b792c 12993/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12994#ifdef __cplusplus
12995extern "C"
19650fd6 12996{
503d2be0 12997#endif
457b792c 12998/* We use char because int might match the return type of a gcc2
503d2be0 12999 builtin and then its argument prototype would still apply. */
98418dba 13000char $ac_func ();
98418dba
CW
13001/* The GNU C library defines this for functions which it implements
13002 to always fail with ENOSYS. Some functions are actually named
13003 something starting with __ and the normal name is an alias. */
13004#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13005choke me
13006#else
19650fd6
AS
13007char (*f) () = $ac_func;
13008#endif
13009#ifdef __cplusplus
13010}
cd958eb3
MB
13011#endif
13012
19650fd6
AS
13013int
13014main ()
13015{
13016return f != $ac_func;
503d2be0
AS
13017 ;
13018 return 0;
13019}
13020_ACEOF
13021rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13022if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13023 (eval $ac_link) 2>conftest.er1
503d2be0 13024 ac_status=$?
35996d22
AS
13025 grep -v '^ *+' conftest.er1 >conftest.err
13026 rm -f conftest.er1
13027 cat conftest.err >&5
c0d27fcc 13028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13029 (exit $ac_status); } &&
35996d22
AS
13030 { ac_try='test -z "$ac_c_werror_flag"
13031 || test ! -s conftest.err'
13032 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13033 (eval $ac_try) 2>&5
13034 ac_status=$?
13035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13036 (exit $ac_status); }; } &&
13037 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13038 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13039 (eval $ac_try) 2>&5
13040 ac_status=$?
c0d27fcc 13041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13042 (exit $ac_status); }; }; then
98418dba 13043 eval "$as_ac_var=yes"
503d2be0
AS
13044else
13045 echo "$as_me: failed program was:" >&5
19650fd6
AS
13046sed 's/^/| /' conftest.$ac_ext >&5
13047
98418dba 13048eval "$as_ac_var=no"
503d2be0 13049fi
35996d22
AS
13050rm -f conftest.err conftest.$ac_objext \
13051 conftest$ac_exeext conftest.$ac_ext
503d2be0 13052fi
c0d27fcc 13053echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13054echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13055if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13056 cat >>confdefs.h <<_ACEOF
98418dba 13057#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13058_ACEOF
457b792c 13059
457b792c 13060fi
98418dba 13061done
457b792c 13062
c0d27fcc 13063
98418dba
CW
13064for ac_header in maillock.h
13065do
13066as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13067if eval "test \"\${$as_ac_Header+set}\" = set"; then
13068 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13069echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13070if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 13071 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13072fi
13073echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13074echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 13075else
c0d27fcc
MR
13076 # Is the header compilable?
13077echo "$as_me:$LINENO: checking $ac_header usability" >&5
13078echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13079cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13080/* confdefs.h. */
13081_ACEOF
13082cat confdefs.h >>conftest.$ac_ext
13083cat >>conftest.$ac_ext <<_ACEOF
13084/* end confdefs.h. */
c0d27fcc
MR
13085$ac_includes_default
13086#include <$ac_header>
13087_ACEOF
13088rm -f conftest.$ac_objext
13089if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13090 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13091 ac_status=$?
35996d22
AS
13092 grep -v '^ *+' conftest.er1 >conftest.err
13093 rm -f conftest.er1
13094 cat conftest.err >&5
c0d27fcc
MR
13095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13096 (exit $ac_status); } &&
35996d22
AS
13097 { ac_try='test -z "$ac_c_werror_flag"
13098 || test ! -s conftest.err'
13099 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13100 (eval $ac_try) 2>&5
13101 ac_status=$?
13102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13103 (exit $ac_status); }; } &&
13104 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13105 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13106 (eval $ac_try) 2>&5
13107 ac_status=$?
13108 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13109 (exit $ac_status); }; }; then
13110 ac_header_compiler=yes
13111else
13112 echo "$as_me: failed program was:" >&5
19650fd6
AS
13113sed 's/^/| /' conftest.$ac_ext >&5
13114
c0d27fcc
MR
13115ac_header_compiler=no
13116fi
35996d22 13117rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13118echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13119echo "${ECHO_T}$ac_header_compiler" >&6
13120
13121# Is the header present?
13122echo "$as_me:$LINENO: checking $ac_header presence" >&5
13123echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13124cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13125/* confdefs.h. */
13126_ACEOF
13127cat confdefs.h >>conftest.$ac_ext
13128cat >>conftest.$ac_ext <<_ACEOF
13129/* end confdefs.h. */
98418dba 13130#include <$ac_header>
503d2be0 13131_ACEOF
c0d27fcc 13132if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 13133 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 13134 ac_status=$?
6bae0ccf 13135 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13136 rm -f conftest.er1
13137 cat conftest.err >&5
c0d27fcc 13138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13139 (exit $ac_status); } >/dev/null; then
13140 if test -s conftest.err; then
13141 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13142 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
13143 else
13144 ac_cpp_err=
13145 fi
503d2be0 13146else
98418dba 13147 ac_cpp_err=yes
503d2be0 13148fi
98418dba 13149if test -z "$ac_cpp_err"; then
c0d27fcc 13150 ac_header_preproc=yes
98418dba
CW
13151else
13152 echo "$as_me: failed program was:" >&5
19650fd6
AS
13153sed 's/^/| /' conftest.$ac_ext >&5
13154
c0d27fcc 13155 ac_header_preproc=no
503d2be0 13156fi
98418dba 13157rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13158echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13159echo "${ECHO_T}$ac_header_preproc" >&6
13160
13161# So? What about this header?
35996d22
AS
13162case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13163 yes:no: )
c0d27fcc
MR
13164 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13165echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13166 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13167echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13168 ac_header_preproc=yes
19650fd6 13169 ;;
35996d22 13170 no:yes:* )
c0d27fcc
MR
13171 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13172echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13173 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13174echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13175 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13176echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13177 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13178echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13179 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13180echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13181 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13182echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13183 (
13184 cat <<\_ASBOX
35996d22
AS
13185## ------------------------------------------ ##
13186## Report this to the AC_PACKAGE_NAME lists. ##
13187## ------------------------------------------ ##
19650fd6
AS
13188_ASBOX
13189 ) |
13190 sed "s/^/$as_me: WARNING: /" >&2
13191 ;;
c0d27fcc
MR
13192esac
13193echo "$as_me:$LINENO: checking for $ac_header" >&5
13194echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13195if eval "test \"\${$as_ac_Header+set}\" = set"; then
13196 echo $ECHO_N "(cached) $ECHO_C" >&6
13197else
35996d22 13198 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13199fi
c0d27fcc 13200echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13201echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13202
13203fi
98418dba 13204if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13205 cat >>confdefs.h <<_ACEOF
98418dba 13206#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13207_ACEOF
48d4b120 13208
ba4481b5 13209fi
c0d27fcc 13210
98418dba
CW
13211done
13212
c0d27fcc
MR
13213
13214
13215
13216
13217
13218
13219
13220
13221
13222
13223
13224
13225
13226
13227
13228
13229
13230
13231
13232
13233
13234
13235
13236
13237
13238
13239
13240
13241
13242
13243
13244
13245
13246
13247
13248
13249
13250
13251
13252
13253
13254
13255
13256
13257
13258
13259
13260
13261
13262
13263
13264
13265
13266
13267
22044edf
DL
13268
13269
c0d27fcc 13270
b0e44248
RB
13271
13272
973a76b1
DL
13273
13274
13275
cd958eb3 13276
25ca0bca 13277
28127e47 13278
c0d27fcc
MR
13279
13280
98418dba
CW
13281for ac_func in gethostname getdomainname dup2 \
13282rename closedir mkdir rmdir sysinfo \
13283random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
13284strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
973a76b1 13285utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
98418dba
CW
13286__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
13287sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248 13288gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
28127e47 13289memset memcmp memmove difftime memcpy mempcpy mblen mbrlen posix_memalign
98418dba
CW
13290do
13291as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13292echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13293echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13294if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13295 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13296else
503d2be0 13297 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13298/* confdefs.h. */
13299_ACEOF
13300cat confdefs.h >>conftest.$ac_ext
13301cat >>conftest.$ac_ext <<_ACEOF
13302/* end confdefs.h. */
35996d22
AS
13303/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13304 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13305#define $ac_func innocuous_$ac_func
13306
98418dba 13307/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13308 which can conflict with char $ac_func (); below.
13309 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13310 <limits.h> exists even on freestanding compilers. */
35996d22 13311
19650fd6
AS
13312#ifdef __STDC__
13313# include <limits.h>
13314#else
13315# include <assert.h>
13316#endif
35996d22
AS
13317
13318#undef $ac_func
13319
ba4481b5 13320/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13321#ifdef __cplusplus
13322extern "C"
19650fd6 13323{
503d2be0 13324#endif
ba4481b5 13325/* We use char because int might match the return type of a gcc2
503d2be0 13326 builtin and then its argument prototype would still apply. */
98418dba 13327char $ac_func ();
98418dba
CW
13328/* The GNU C library defines this for functions which it implements
13329 to always fail with ENOSYS. Some functions are actually named
13330 something starting with __ and the normal name is an alias. */
13331#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13332choke me
13333#else
19650fd6
AS
13334char (*f) () = $ac_func;
13335#endif
13336#ifdef __cplusplus
13337}
98418dba
CW
13338#endif
13339
19650fd6
AS
13340int
13341main ()
13342{
13343return f != $ac_func;
503d2be0
AS
13344 ;
13345 return 0;
13346}
13347_ACEOF
13348rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13349if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13350 (eval $ac_link) 2>conftest.er1
503d2be0 13351 ac_status=$?
35996d22
AS
13352 grep -v '^ *+' conftest.er1 >conftest.err
13353 rm -f conftest.er1
13354 cat conftest.err >&5
c0d27fcc 13355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13356 (exit $ac_status); } &&
35996d22
AS
13357 { ac_try='test -z "$ac_c_werror_flag"
13358 || test ! -s conftest.err'
13359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13360 (eval $ac_try) 2>&5
13361 ac_status=$?
13362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13363 (exit $ac_status); }; } &&
13364 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13366 (eval $ac_try) 2>&5
13367 ac_status=$?
c0d27fcc 13368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13369 (exit $ac_status); }; }; then
98418dba 13370 eval "$as_ac_var=yes"
503d2be0
AS
13371else
13372 echo "$as_me: failed program was:" >&5
19650fd6
AS
13373sed 's/^/| /' conftest.$ac_ext >&5
13374
98418dba 13375eval "$as_ac_var=no"
503d2be0 13376fi
35996d22
AS
13377rm -f conftest.err conftest.$ac_objext \
13378 conftest$ac_exeext conftest.$ac_ext
ba4481b5 13379fi
c0d27fcc 13380echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13381echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13382if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13383 cat >>confdefs.h <<_ACEOF
98418dba 13384#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13385_ACEOF
ba4481b5 13386
ba4481b5 13387fi
98418dba 13388done
ba4481b5 13389
c0d27fcc
MR
13390
13391
98418dba
CW
13392for ac_header in sys/un.h
13393do
13394as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13395if eval "test \"\${$as_ac_Header+set}\" = set"; then
13396 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13397echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13398if eval "test \"\${$as_ac_Header+set}\" = set"; then
13399 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13400fi
13401echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13402echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13403else
c0d27fcc
MR
13404 # Is the header compilable?
13405echo "$as_me:$LINENO: checking $ac_header usability" >&5
13406echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13407cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13408/* confdefs.h. */
13409_ACEOF
13410cat confdefs.h >>conftest.$ac_ext
13411cat >>conftest.$ac_ext <<_ACEOF
13412/* end confdefs.h. */
c0d27fcc
MR
13413$ac_includes_default
13414#include <$ac_header>
13415_ACEOF
13416rm -f conftest.$ac_objext
13417if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13418 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13419 ac_status=$?
35996d22
AS
13420 grep -v '^ *+' conftest.er1 >conftest.err
13421 rm -f conftest.er1
13422 cat conftest.err >&5
c0d27fcc
MR
13423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13424 (exit $ac_status); } &&
35996d22
AS
13425 { ac_try='test -z "$ac_c_werror_flag"
13426 || test ! -s conftest.err'
13427 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13428 (eval $ac_try) 2>&5
13429 ac_status=$?
13430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13431 (exit $ac_status); }; } &&
13432 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13433 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13434 (eval $ac_try) 2>&5
13435 ac_status=$?
13436 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13437 (exit $ac_status); }; }; then
13438 ac_header_compiler=yes
13439else
13440 echo "$as_me: failed program was:" >&5
19650fd6
AS
13441sed 's/^/| /' conftest.$ac_ext >&5
13442
c0d27fcc
MR
13443ac_header_compiler=no
13444fi
35996d22 13445rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13446echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13447echo "${ECHO_T}$ac_header_compiler" >&6
13448
13449# Is the header present?
13450echo "$as_me:$LINENO: checking $ac_header presence" >&5
13451echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13452cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13453/* confdefs.h. */
13454_ACEOF
13455cat confdefs.h >>conftest.$ac_ext
13456cat >>conftest.$ac_ext <<_ACEOF
13457/* end confdefs.h. */
98418dba 13458#include <$ac_header>
503d2be0 13459_ACEOF
c0d27fcc 13460if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13461 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13462 ac_status=$?
6bae0ccf 13463 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13464 rm -f conftest.er1
13465 cat conftest.err >&5
c0d27fcc 13466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13467 (exit $ac_status); } >/dev/null; then
13468 if test -s conftest.err; then
13469 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13470 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13471 else
13472 ac_cpp_err=
13473 fi
13474else
13475 ac_cpp_err=yes
13476fi
13477if test -z "$ac_cpp_err"; then
c0d27fcc 13478 ac_header_preproc=yes
ba4481b5 13479else
503d2be0 13480 echo "$as_me: failed program was:" >&5
19650fd6
AS
13481sed 's/^/| /' conftest.$ac_ext >&5
13482
c0d27fcc 13483 ac_header_preproc=no
ba4481b5 13484fi
503d2be0 13485rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13486echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13487echo "${ECHO_T}$ac_header_preproc" >&6
13488
13489# So? What about this header?
35996d22
AS
13490case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13491 yes:no: )
c0d27fcc
MR
13492 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13493echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13494 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13495echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13496 ac_header_preproc=yes
19650fd6 13497 ;;
35996d22 13498 no:yes:* )
c0d27fcc
MR
13499 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13500echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13501 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13502echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13503 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13504echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13505 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13506echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13507 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13508echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13509 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13510echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13511 (
13512 cat <<\_ASBOX
35996d22
AS
13513## ------------------------------------------ ##
13514## Report this to the AC_PACKAGE_NAME lists. ##
13515## ------------------------------------------ ##
19650fd6
AS
13516_ASBOX
13517 ) |
13518 sed "s/^/$as_me: WARNING: /" >&2
13519 ;;
c0d27fcc
MR
13520esac
13521echo "$as_me:$LINENO: checking for $ac_header" >&5
13522echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13523if eval "test \"\${$as_ac_Header+set}\" = set"; then
13524 echo $ECHO_N "(cached) $ECHO_C" >&6
13525else
35996d22 13526 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13527fi
c0d27fcc 13528echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 13529echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13530
13531fi
925c2f3f 13532if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13533 cat >>confdefs.h <<_ACEOF
925c2f3f 13534#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13535_ACEOF
503d2be0 13536
925c2f3f 13537fi
c0d27fcc 13538
925c2f3f
EZ
13539done
13540
c0d27fcc
MR
13541
13542
13543
35996d22
AS
13544
13545for ac_header in stdlib.h sys/time.h unistd.h
925c2f3f
EZ
13546do
13547as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13548if eval "test \"\${$as_ac_Header+set}\" = set"; then
13549 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
13550echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13551if eval "test \"\${$as_ac_Header+set}\" = set"; then
13552 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13553fi
13554echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13555echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 13556else
c0d27fcc
MR
13557 # Is the header compilable?
13558echo "$as_me:$LINENO: checking $ac_header usability" >&5
13559echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13560cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13561/* confdefs.h. */
13562_ACEOF
13563cat confdefs.h >>conftest.$ac_ext
13564cat >>conftest.$ac_ext <<_ACEOF
13565/* end confdefs.h. */
c0d27fcc
MR
13566$ac_includes_default
13567#include <$ac_header>
13568_ACEOF
13569rm -f conftest.$ac_objext
13570if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13571 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13572 ac_status=$?
35996d22
AS
13573 grep -v '^ *+' conftest.er1 >conftest.err
13574 rm -f conftest.er1
13575 cat conftest.err >&5
c0d27fcc
MR
13576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13577 (exit $ac_status); } &&
35996d22
AS
13578 { ac_try='test -z "$ac_c_werror_flag"
13579 || test ! -s conftest.err'
13580 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13581 (eval $ac_try) 2>&5
13582 ac_status=$?
13583 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13584 (exit $ac_status); }; } &&
13585 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13586 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13587 (eval $ac_try) 2>&5
13588 ac_status=$?
13589 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13590 (exit $ac_status); }; }; then
13591 ac_header_compiler=yes
13592else
13593 echo "$as_me: failed program was:" >&5
19650fd6
AS
13594sed 's/^/| /' conftest.$ac_ext >&5
13595
c0d27fcc
MR
13596ac_header_compiler=no
13597fi
35996d22 13598rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13599echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13600echo "${ECHO_T}$ac_header_compiler" >&6
13601
13602# Is the header present?
13603echo "$as_me:$LINENO: checking $ac_header presence" >&5
13604echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13605cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13606/* confdefs.h. */
13607_ACEOF
13608cat confdefs.h >>conftest.$ac_ext
13609cat >>conftest.$ac_ext <<_ACEOF
13610/* end confdefs.h. */
98418dba 13611#include <$ac_header>
503d2be0 13612_ACEOF
c0d27fcc 13613if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13614 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13615 ac_status=$?
6bae0ccf 13616 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13617 rm -f conftest.er1
13618 cat conftest.err >&5
c0d27fcc 13619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13620 (exit $ac_status); } >/dev/null; then
13621 if test -s conftest.err; then
13622 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13623 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13624 else
13625 ac_cpp_err=
13626 fi
13627else
13628 ac_cpp_err=yes
13629fi
13630if test -z "$ac_cpp_err"; then
c0d27fcc 13631 ac_header_preproc=yes
98418dba
CW
13632else
13633 echo "$as_me: failed program was:" >&5
19650fd6
AS
13634sed 's/^/| /' conftest.$ac_ext >&5
13635
c0d27fcc 13636 ac_header_preproc=no
98418dba
CW
13637fi
13638rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13639echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13640echo "${ECHO_T}$ac_header_preproc" >&6
13641
13642# So? What about this header?
35996d22
AS
13643case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13644 yes:no: )
c0d27fcc
MR
13645 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13646echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13647 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13648echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13649 ac_header_preproc=yes
19650fd6 13650 ;;
35996d22 13651 no:yes:* )
c0d27fcc
MR
13652 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13653echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13654 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13655echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13656 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13657echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13658 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13659echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13660 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13661echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13662 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13663echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13664 (
13665 cat <<\_ASBOX
35996d22
AS
13666## ------------------------------------------ ##
13667## Report this to the AC_PACKAGE_NAME lists. ##
13668## ------------------------------------------ ##
19650fd6
AS
13669_ASBOX
13670 ) |
13671 sed "s/^/$as_me: WARNING: /" >&2
13672 ;;
c0d27fcc
MR
13673esac
13674echo "$as_me:$LINENO: checking for $ac_header" >&5
13675echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13676if eval "test \"\${$as_ac_Header+set}\" = set"; then
13677 echo $ECHO_N "(cached) $ECHO_C" >&6
13678else
35996d22 13679 eval "$as_ac_Header=\$ac_header_preproc"
ffe36136 13680fi
c0d27fcc 13681echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13682echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13683
13684fi
98418dba 13685if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13686 cat >>confdefs.h <<_ACEOF
98418dba 13687#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13688_ACEOF
98418dba
CW
13689
13690fi
c0d27fcc 13691
98418dba
CW
13692done
13693
c0d27fcc 13694
98418dba
CW
13695for ac_func in alarm
13696do
13697as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13698echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13699echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13700if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13701 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13702else
98418dba 13703 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13704/* confdefs.h. */
13705_ACEOF
13706cat confdefs.h >>conftest.$ac_ext
13707cat >>conftest.$ac_ext <<_ACEOF
13708/* end confdefs.h. */
35996d22
AS
13709/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13710 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13711#define $ac_func innocuous_$ac_func
13712
98418dba 13713/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13714 which can conflict with char $ac_func (); below.
13715 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13716 <limits.h> exists even on freestanding compilers. */
35996d22 13717
19650fd6
AS
13718#ifdef __STDC__
13719# include <limits.h>
13720#else
13721# include <assert.h>
13722#endif
35996d22
AS
13723
13724#undef $ac_func
13725
ba4481b5 13726/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13727#ifdef __cplusplus
13728extern "C"
19650fd6 13729{
503d2be0 13730#endif
ba4481b5 13731/* We use char because int might match the return type of a gcc2
503d2be0 13732 builtin and then its argument prototype would still apply. */
98418dba 13733char $ac_func ();
98418dba
CW
13734/* The GNU C library defines this for functions which it implements
13735 to always fail with ENOSYS. Some functions are actually named
13736 something starting with __ and the normal name is an alias. */
13737#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13738choke me
13739#else
19650fd6
AS
13740char (*f) () = $ac_func;
13741#endif
13742#ifdef __cplusplus
13743}
98418dba
CW
13744#endif
13745
19650fd6
AS
13746int
13747main ()
13748{
13749return f != $ac_func;
503d2be0
AS
13750 ;
13751 return 0;
13752}
13753_ACEOF
13754rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13755if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13756 (eval $ac_link) 2>conftest.er1
503d2be0 13757 ac_status=$?
35996d22
AS
13758 grep -v '^ *+' conftest.er1 >conftest.err
13759 rm -f conftest.er1
13760 cat conftest.err >&5
c0d27fcc 13761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13762 (exit $ac_status); } &&
35996d22
AS
13763 { ac_try='test -z "$ac_c_werror_flag"
13764 || test ! -s conftest.err'
13765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13766 (eval $ac_try) 2>&5
13767 ac_status=$?
13768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13769 (exit $ac_status); }; } &&
13770 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13771 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13772 (eval $ac_try) 2>&5
13773 ac_status=$?
c0d27fcc 13774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13775 (exit $ac_status); }; }; then
98418dba 13776 eval "$as_ac_var=yes"
503d2be0
AS
13777else
13778 echo "$as_me: failed program was:" >&5
19650fd6
AS
13779sed 's/^/| /' conftest.$ac_ext >&5
13780
98418dba 13781eval "$as_ac_var=no"
503d2be0 13782fi
35996d22
AS
13783rm -f conftest.err conftest.$ac_objext \
13784 conftest$ac_exeext conftest.$ac_ext
ffe36136 13785fi
c0d27fcc 13786echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13787echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13788if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13789 cat >>confdefs.h <<_ACEOF
98418dba 13790#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13791_ACEOF
ffe36136 13792
ba4481b5 13793fi
98418dba 13794done
ba4481b5 13795
c0d27fcc 13796echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
13797echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
13798if test "${ac_cv_func_working_mktime+set}" = set; then
13799 echo $ECHO_N "(cached) $ECHO_C" >&6
13800else
13801 if test "$cross_compiling" = yes; then
13802 ac_cv_func_working_mktime=no
13803else
13804 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13805/* confdefs.h. */
13806_ACEOF
13807cat confdefs.h >>conftest.$ac_ext
13808cat >>conftest.$ac_ext <<_ACEOF
13809/* end confdefs.h. */
98418dba
CW
13810/* Test program from Paul Eggert and Tony Leneis. */
13811#if TIME_WITH_SYS_TIME
13812# include <sys/time.h>
13813# include <time.h>
13814#else
13815# if HAVE_SYS_TIME_H
13816# include <sys/time.h>
13817# else
13818# include <time.h>
13819# endif
13820#endif
ba4481b5 13821
35996d22
AS
13822#if HAVE_STDLIB_H
13823# include <stdlib.h>
13824#endif
13825
98418dba
CW
13826#if HAVE_UNISTD_H
13827# include <unistd.h>
13828#endif
ba4481b5 13829
98418dba
CW
13830#if !HAVE_ALARM
13831# define alarm(X) /* empty */
13832#endif
df645f7c 13833
98418dba
CW
13834/* Work around redefinition to rpl_putenv by other config tests. */
13835#undef putenv
df645f7c 13836
98418dba 13837static time_t time_t_max;
35996d22 13838static time_t time_t_min;
df645f7c 13839
98418dba 13840/* Values we'll use to set the TZ environment variable. */
35996d22
AS
13841static char *tz_strings[] = {
13842 (char *) 0, "TZ=GMT0", "TZ=JST-9",
98418dba
CW
13843 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
13844};
13845#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 13846
98418dba
CW
13847/* Fail if mktime fails to convert a date in the spring-forward gap.
13848 Based on a problem report from Andreas Jaeger. */
13849static void
13850spring_forward_gap ()
13851{
13852 /* glibc (up to about 1998-10-07) failed this test. */
13853 struct tm tm;
13854
13855 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
13856 instead of "TZ=America/Vancouver" in order to detect the bug even
13857 on systems that don't support the Olson extension, or don't have the
13858 full zoneinfo tables installed. */
13859 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
13860
13861 tm.tm_year = 98;
13862 tm.tm_mon = 3;
13863 tm.tm_mday = 5;
13864 tm.tm_hour = 2;
13865 tm.tm_min = 0;
13866 tm.tm_sec = 0;
13867 tm.tm_isdst = -1;
13868 if (mktime (&tm) == (time_t)-1)
13869 exit (1);
13870}
13871
13872static void
35996d22 13873mktime_test1 (now)
98418dba
CW
13874 time_t now;
13875{
13876 struct tm *lt;
13877 if ((lt = localtime (&now)) && mktime (lt) != now)
13878 exit (1);
35996d22
AS
13879}
13880
13881static void
13882mktime_test (now)
13883 time_t now;
13884{
13885 mktime_test1 (now);
13886 mktime_test1 ((time_t) (time_t_max - now));
13887 mktime_test1 ((time_t) (time_t_min + now));
98418dba
CW
13888}
13889
13890static void
13891irix_6_4_bug ()
13892{
13893 /* Based on code from Ariel Faigon. */
13894 struct tm tm;
13895 tm.tm_year = 96;
13896 tm.tm_mon = 3;
13897 tm.tm_mday = 0;
13898 tm.tm_hour = 0;
13899 tm.tm_min = 0;
13900 tm.tm_sec = 0;
13901 tm.tm_isdst = -1;
13902 mktime (&tm);
13903 if (tm.tm_mon != 2 || tm.tm_mday != 31)
13904 exit (1);
13905}
13906
13907static void
13908bigtime_test (j)
13909 int j;
13910{
13911 struct tm tm;
13912 time_t now;
13913 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
13914 now = mktime (&tm);
13915 if (now != (time_t) -1)
13916 {
13917 struct tm *lt = localtime (&now);
13918 if (! (lt
13919 && lt->tm_year == tm.tm_year
13920 && lt->tm_mon == tm.tm_mon
13921 && lt->tm_mday == tm.tm_mday
13922 && lt->tm_hour == tm.tm_hour
13923 && lt->tm_min == tm.tm_min
13924 && lt->tm_sec == tm.tm_sec
13925 && lt->tm_yday == tm.tm_yday
13926 && lt->tm_wday == tm.tm_wday
13927 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
13928 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
13929 exit (1);
13930 }
13931}
13932
13933int
13934main ()
13935{
13936 time_t t, delta;
13937 int i, j;
13938
13939 /* This test makes some buggy mktime implementations loop.
13940 Give up after 60 seconds; a mktime slower than that
13941 isn't worth using anyway. */
13942 alarm (60);
13943
13944 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
13945 continue;
13946 time_t_max--;
35996d22
AS
13947 if ((time_t) -1 < 0)
13948 for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
13949 continue;
98418dba
CW
13950 delta = time_t_max / 997; /* a suitable prime number */
13951 for (i = 0; i < N_STRINGS; i++)
13952 {
13953 if (tz_strings[i])
13954 putenv (tz_strings[i]);
503d2be0 13955
98418dba
CW
13956 for (t = 0; t <= time_t_max - delta; t += delta)
13957 mktime_test (t);
35996d22
AS
13958 mktime_test ((time_t) 1);
13959 mktime_test ((time_t) (60 * 60));
13960 mktime_test ((time_t) (60 * 60 * 24));
98418dba
CW
13961
13962 for (j = 1; 0 < j; j *= 2)
35996d22 13963 bigtime_test (j);
98418dba
CW
13964 bigtime_test (j - 1);
13965 }
13966 irix_6_4_bug ();
13967 spring_forward_gap ();
13968 exit (0);
503d2be0
AS
13969}
13970_ACEOF
98418dba 13971rm -f conftest$ac_exeext
c0d27fcc 13972if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13973 (eval $ac_link) 2>&5
13974 ac_status=$?
c0d27fcc 13975 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 13976 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 13977 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13978 (eval $ac_try) 2>&5
13979 ac_status=$?
c0d27fcc 13980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13981 (exit $ac_status); }; }; then
98418dba 13982 ac_cv_func_working_mktime=yes
503d2be0 13983else
98418dba
CW
13984 echo "$as_me: program exited with status $ac_status" >&5
13985echo "$as_me: failed program was:" >&5
19650fd6
AS
13986sed 's/^/| /' conftest.$ac_ext >&5
13987
c0d27fcc 13988( exit $ac_status )
98418dba 13989ac_cv_func_working_mktime=no
503d2be0 13990fi
35996d22 13991rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 13992fi
ba4481b5 13993fi
c0d27fcc 13994echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
13995echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
13996if test $ac_cv_func_working_mktime = no; then
35996d22
AS
13997 case $LIBOBJS in
13998 "mktime.$ac_objext" | \
13999 *" mktime.$ac_objext" | \
14000 "mktime.$ac_objext "* | \
14001 *" mktime.$ac_objext "* ) ;;
14002 *) LIBOBJS="$LIBOBJS mktime.$ac_objext" ;;
14003esac
14004
ba4481b5
DL
14005fi
14006
98418dba 14007if test "$ac_cv_func_working_mktime" = no; then
b936fae4 14008
c0d27fcc 14009cat >>confdefs.h <<\_ACEOF
98418dba 14010#define BROKEN_MKTIME 1
c0d27fcc 14011_ACEOF
ba4481b5 14012
ba4481b5 14013fi
503d2be0 14014
98418dba
CW
14015ac_have_func=no # yes means we've found a way to get the load average.
14016
6bae0ccf
DL
14017# Make sure getloadavg.c is where it belongs, at configure-time.
14018test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
14019 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
14020echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
14021 { (exit 1); exit 1; }; }
14022
98418dba
CW
14023ac_save_LIBS=$LIBS
14024
14025# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 14026(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
14027echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
14028if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 14029 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14030else
503d2be0 14031 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14032/* confdefs.h. */
14033_ACEOF
14034cat confdefs.h >>conftest.$ac_ext
14035cat >>conftest.$ac_ext <<_ACEOF
14036/* end confdefs.h. */
35996d22
AS
14037/* Define getloadavg to an innocuous variant, in case <limits.h> declares getloadavg.
14038 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14039#define getloadavg innocuous_getloadavg
14040
98418dba 14041/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14042 which can conflict with char getloadavg (); below.
14043 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14044 <limits.h> exists even on freestanding compilers. */
35996d22 14045
19650fd6
AS
14046#ifdef __STDC__
14047# include <limits.h>
14048#else
14049# include <assert.h>
14050#endif
35996d22
AS
14051
14052#undef getloadavg
14053
ba4481b5 14054/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14055#ifdef __cplusplus
14056extern "C"
19650fd6 14057{
503d2be0 14058#endif
ba4481b5 14059/* We use char because int might match the return type of a gcc2
503d2be0 14060 builtin and then its argument prototype would still apply. */
98418dba 14061char getloadavg ();
98418dba
CW
14062/* The GNU C library defines this for functions which it implements
14063 to always fail with ENOSYS. Some functions are actually named
14064 something starting with __ and the normal name is an alias. */
14065#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
14066choke me
14067#else
19650fd6
AS
14068char (*f) () = getloadavg;
14069#endif
14070#ifdef __cplusplus
14071}
cd958eb3
MB
14072#endif
14073
19650fd6
AS
14074int
14075main ()
14076{
14077return f != getloadavg;
503d2be0
AS
14078 ;
14079 return 0;
14080}
14081_ACEOF
14082rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14083if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14084 (eval $ac_link) 2>conftest.er1
503d2be0 14085 ac_status=$?
35996d22
AS
14086 grep -v '^ *+' conftest.er1 >conftest.err
14087 rm -f conftest.er1
14088 cat conftest.err >&5
c0d27fcc 14089 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14090 (exit $ac_status); } &&
35996d22
AS
14091 { ac_try='test -z "$ac_c_werror_flag"
14092 || test ! -s conftest.err'
14093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14094 (eval $ac_try) 2>&5
14095 ac_status=$?
14096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14097 (exit $ac_status); }; } &&
14098 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14099 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14100 (eval $ac_try) 2>&5
14101 ac_status=$?
c0d27fcc 14102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14103 (exit $ac_status); }; }; then
98418dba 14104 ac_cv_func_getloadavg=yes
503d2be0
AS
14105else
14106 echo "$as_me: failed program was:" >&5
19650fd6
AS
14107sed 's/^/| /' conftest.$ac_ext >&5
14108
98418dba 14109ac_cv_func_getloadavg=no
503d2be0 14110fi
35996d22
AS
14111rm -f conftest.err conftest.$ac_objext \
14112 conftest$ac_exeext conftest.$ac_ext
ba4481b5 14113fi
c0d27fcc 14114echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
14115echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
14116if test $ac_cv_func_getloadavg = yes; then
14117 exit 0
14118else
14119 exit 1
ba4481b5 14120fi
98418dba 14121) && ac_have_func=yes
ba4481b5 14122
98418dba 14123# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 14124
98418dba
CW
14125for ac_func in pstat_getdynamic
14126do
14127as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14128echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14129echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14130if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14131 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14132else
503d2be0 14133 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14134/* confdefs.h. */
14135_ACEOF
14136cat confdefs.h >>conftest.$ac_ext
14137cat >>conftest.$ac_ext <<_ACEOF
14138/* end confdefs.h. */
35996d22
AS
14139/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14140 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14141#define $ac_func innocuous_$ac_func
14142
98418dba 14143/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14144 which can conflict with char $ac_func (); below.
14145 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14146 <limits.h> exists even on freestanding compilers. */
35996d22 14147
19650fd6
AS
14148#ifdef __STDC__
14149# include <limits.h>
14150#else
14151# include <assert.h>
14152#endif
35996d22
AS
14153
14154#undef $ac_func
14155
ba4481b5 14156/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14157#ifdef __cplusplus
14158extern "C"
19650fd6 14159{
503d2be0 14160#endif
ba4481b5 14161/* We use char because int might match the return type of a gcc2
503d2be0 14162 builtin and then its argument prototype would still apply. */
98418dba 14163char $ac_func ();
98418dba
CW
14164/* The GNU C library defines this for functions which it implements
14165 to always fail with ENOSYS. Some functions are actually named
14166 something starting with __ and the normal name is an alias. */
14167#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14168choke me
14169#else
19650fd6
AS
14170char (*f) () = $ac_func;
14171#endif
14172#ifdef __cplusplus
14173}
98418dba
CW
14174#endif
14175
19650fd6
AS
14176int
14177main ()
14178{
14179return f != $ac_func;
98418dba
CW
14180 ;
14181 return 0;
14182}
f21fadcc 14183_ACEOF
98418dba 14184rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14185if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14186 (eval $ac_link) 2>conftest.er1
f21fadcc 14187 ac_status=$?
35996d22
AS
14188 grep -v '^ *+' conftest.er1 >conftest.err
14189 rm -f conftest.er1
14190 cat conftest.err >&5
c0d27fcc 14191 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14192 (exit $ac_status); } &&
35996d22
AS
14193 { ac_try='test -z "$ac_c_werror_flag"
14194 || test ! -s conftest.err'
14195 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14196 (eval $ac_try) 2>&5
14197 ac_status=$?
14198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14199 (exit $ac_status); }; } &&
14200 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14201 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14202 (eval $ac_try) 2>&5
14203 ac_status=$?
c0d27fcc 14204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14205 (exit $ac_status); }; }; then
14206 eval "$as_ac_var=yes"
f21fadcc
JD
14207else
14208 echo "$as_me: failed program was:" >&5
19650fd6
AS
14209sed 's/^/| /' conftest.$ac_ext >&5
14210
98418dba 14211eval "$as_ac_var=no"
f21fadcc 14212fi
35996d22
AS
14213rm -f conftest.err conftest.$ac_objext \
14214 conftest$ac_exeext conftest.$ac_ext
f21fadcc 14215fi
c0d27fcc 14216echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
14217echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14218if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14219 cat >>confdefs.h <<_ACEOF
98418dba 14220#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14221_ACEOF
98418dba
CW
14222
14223fi
14224done
14225
c0d27fcc 14226
98418dba
CW
14227# Solaris has libkstat which does not require root.
14228
c0d27fcc 14229echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
14230echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
14231if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
14232 echo $ECHO_N "(cached) $ECHO_C" >&6
14233else
14234 ac_check_lib_save_LIBS=$LIBS
98418dba 14235LIBS="-lkstat $LIBS"
f21fadcc 14236cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14237/* confdefs.h. */
14238_ACEOF
14239cat confdefs.h >>conftest.$ac_ext
14240cat >>conftest.$ac_ext <<_ACEOF
14241/* end confdefs.h. */
f21fadcc
JD
14242
14243/* Override any gcc2 internal prototype to avoid an error. */
14244#ifdef __cplusplus
14245extern "C"
14246#endif
14247/* We use char because int might match the return type of a gcc2
14248 builtin and then its argument prototype would still apply. */
98418dba 14249char kstat_open ();
f21fadcc
JD
14250int
14251main ()
14252{
98418dba 14253kstat_open ();
f21fadcc
JD
14254 ;
14255 return 0;
14256}
14257_ACEOF
14258rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14259if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14260 (eval $ac_link) 2>conftest.er1
f21fadcc 14261 ac_status=$?
35996d22
AS
14262 grep -v '^ *+' conftest.er1 >conftest.err
14263 rm -f conftest.er1
14264 cat conftest.err >&5
c0d27fcc 14265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14266 (exit $ac_status); } &&
35996d22
AS
14267 { ac_try='test -z "$ac_c_werror_flag"
14268 || test ! -s conftest.err'
14269 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14270 (eval $ac_try) 2>&5
14271 ac_status=$?
14272 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14273 (exit $ac_status); }; } &&
14274 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14275 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
14276 (eval $ac_try) 2>&5
14277 ac_status=$?
c0d27fcc 14278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14279 (exit $ac_status); }; }; then
98418dba 14280 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
14281else
14282 echo "$as_me: failed program was:" >&5
19650fd6
AS
14283sed 's/^/| /' conftest.$ac_ext >&5
14284
98418dba 14285ac_cv_lib_kstat_kstat_open=no
f21fadcc 14286fi
35996d22
AS
14287rm -f conftest.err conftest.$ac_objext \
14288 conftest$ac_exeext conftest.$ac_ext
f21fadcc
JD
14289LIBS=$ac_check_lib_save_LIBS
14290fi
c0d27fcc 14291echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
14292echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
14293if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 14294 cat >>confdefs.h <<_ACEOF
98418dba 14295#define HAVE_LIBKSTAT 1
c0d27fcc 14296_ACEOF
f21fadcc 14297
98418dba 14298 LIBS="-lkstat $LIBS"
f21fadcc 14299
f21fadcc
JD
14300fi
14301
98418dba
CW
14302test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
14303
14304# Some systems with -lutil have (and need) -lkvm as well, some do not.
14305# On Solaris, -lkvm requires nlist from -lelf, so check that first
14306# to get the right answer into the cache.
14307# For kstat on solaris, we need libelf to force the definition of SVR4 below.
14308if test $ac_have_func = no; then
c0d27fcc 14309 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
14310echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
14311if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 14312 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14313else
98418dba
CW
14314 ac_check_lib_save_LIBS=$LIBS
14315LIBS="-lelf $LIBS"
14316cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14317/* confdefs.h. */
14318_ACEOF
14319cat confdefs.h >>conftest.$ac_ext
14320cat >>conftest.$ac_ext <<_ACEOF
14321/* end confdefs.h. */
98418dba
CW
14322
14323/* Override any gcc2 internal prototype to avoid an error. */
14324#ifdef __cplusplus
14325extern "C"
14326#endif
14327/* We use char because int might match the return type of a gcc2
14328 builtin and then its argument prototype would still apply. */
14329char elf_begin ();
503d2be0
AS
14330int
14331main ()
14332{
98418dba 14333elf_begin ();
503d2be0
AS
14334 ;
14335 return 0;
14336}
14337_ACEOF
14338rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14339if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14340 (eval $ac_link) 2>conftest.er1
503d2be0 14341 ac_status=$?
35996d22
AS
14342 grep -v '^ *+' conftest.er1 >conftest.err
14343 rm -f conftest.er1
14344 cat conftest.err >&5
c0d27fcc 14345 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14346 (exit $ac_status); } &&
35996d22
AS
14347 { ac_try='test -z "$ac_c_werror_flag"
14348 || test ! -s conftest.err'
14349 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14350 (eval $ac_try) 2>&5
14351 ac_status=$?
14352 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14353 (exit $ac_status); }; } &&
14354 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14355 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14356 (eval $ac_try) 2>&5
14357 ac_status=$?
c0d27fcc 14358 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14359 (exit $ac_status); }; }; then
98418dba 14360 ac_cv_lib_elf_elf_begin=yes
ba4481b5 14361else
503d2be0 14362 echo "$as_me: failed program was:" >&5
19650fd6
AS
14363sed 's/^/| /' conftest.$ac_ext >&5
14364
98418dba 14365ac_cv_lib_elf_elf_begin=no
ba4481b5 14366fi
35996d22
AS
14367rm -f conftest.err conftest.$ac_objext \
14368 conftest$ac_exeext conftest.$ac_ext
98418dba 14369LIBS=$ac_check_lib_save_LIBS
ba4481b5 14370fi
c0d27fcc 14371echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
14372echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
14373if test $ac_cv_lib_elf_elf_begin = yes; then
14374 LIBS="-lelf $LIBS"
ba4481b5
DL
14375fi
14376
98418dba
CW
14377fi
14378if test $ac_have_func = no; then
c0d27fcc 14379 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
14380echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
14381if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 14382 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14383else
98418dba
CW
14384 ac_check_lib_save_LIBS=$LIBS
14385LIBS="-lkvm $LIBS"
14386cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14387/* confdefs.h. */
14388_ACEOF
14389cat confdefs.h >>conftest.$ac_ext
14390cat >>conftest.$ac_ext <<_ACEOF
14391/* end confdefs.h. */
98418dba
CW
14392
14393/* Override any gcc2 internal prototype to avoid an error. */
14394#ifdef __cplusplus
14395extern "C"
14396#endif
14397/* We use char because int might match the return type of a gcc2
14398 builtin and then its argument prototype would still apply. */
14399char kvm_open ();
503d2be0
AS
14400int
14401main ()
14402{
98418dba 14403kvm_open ();
503d2be0
AS
14404 ;
14405 return 0;
14406}
14407_ACEOF
14408rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14409if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14410 (eval $ac_link) 2>conftest.er1
503d2be0 14411 ac_status=$?
35996d22
AS
14412 grep -v '^ *+' conftest.er1 >conftest.err
14413 rm -f conftest.er1
14414 cat conftest.err >&5
c0d27fcc 14415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14416 (exit $ac_status); } &&
35996d22
AS
14417 { ac_try='test -z "$ac_c_werror_flag"
14418 || test ! -s conftest.err'
14419 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14420 (eval $ac_try) 2>&5
14421 ac_status=$?
14422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14423 (exit $ac_status); }; } &&
14424 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14425 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14426 (eval $ac_try) 2>&5
14427 ac_status=$?
c0d27fcc 14428 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14429 (exit $ac_status); }; }; then
98418dba 14430 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
14431else
14432 echo "$as_me: failed program was:" >&5
19650fd6
AS
14433sed 's/^/| /' conftest.$ac_ext >&5
14434
98418dba 14435ac_cv_lib_kvm_kvm_open=no
503d2be0 14436fi
35996d22
AS
14437rm -f conftest.err conftest.$ac_objext \
14438 conftest$ac_exeext conftest.$ac_ext
98418dba 14439LIBS=$ac_check_lib_save_LIBS
503d2be0 14440fi
c0d27fcc 14441echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
14442echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
14443if test $ac_cv_lib_kvm_kvm_open = yes; then
14444 LIBS="-lkvm $LIBS"
ba4481b5
DL
14445fi
14446
98418dba 14447 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 14448 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
14449echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
14450if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 14451 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14452else
98418dba
CW
14453 ac_check_lib_save_LIBS=$LIBS
14454LIBS="-lutil $LIBS"
14455cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14456/* confdefs.h. */
14457_ACEOF
14458cat confdefs.h >>conftest.$ac_ext
14459cat >>conftest.$ac_ext <<_ACEOF
14460/* end confdefs.h. */
98418dba
CW
14461
14462/* Override any gcc2 internal prototype to avoid an error. */
14463#ifdef __cplusplus
14464extern "C"
14465#endif
14466/* We use char because int might match the return type of a gcc2
14467 builtin and then its argument prototype would still apply. */
14468char getloadavg ();
503d2be0
AS
14469int
14470main ()
14471{
98418dba 14472getloadavg ();
503d2be0
AS
14473 ;
14474 return 0;
14475}
14476_ACEOF
14477rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14478if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14479 (eval $ac_link) 2>conftest.er1
503d2be0 14480 ac_status=$?
35996d22
AS
14481 grep -v '^ *+' conftest.er1 >conftest.err
14482 rm -f conftest.er1
14483 cat conftest.err >&5
c0d27fcc 14484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14485 (exit $ac_status); } &&
35996d22
AS
14486 { ac_try='test -z "$ac_c_werror_flag"
14487 || test ! -s conftest.err'
c0d27fcc 14488 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14489 (eval $ac_try) 2>&5
14490 ac_status=$?
c0d27fcc 14491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
14492 (exit $ac_status); }; } &&
14493 { ac_try='test -s conftest$ac_exeext'
14494 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14495 (eval $ac_try) 2>&5
14496 ac_status=$?
14497 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14498 (exit $ac_status); }; }; then
14499 ac_cv_lib_util_getloadavg=yes
14500else
503d2be0 14501 echo "$as_me: failed program was:" >&5
19650fd6
AS
14502sed 's/^/| /' conftest.$ac_ext >&5
14503
98418dba 14504ac_cv_lib_util_getloadavg=no
ba4481b5 14505fi
35996d22
AS
14506rm -f conftest.err conftest.$ac_objext \
14507 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14508LIBS=$ac_check_lib_save_LIBS
14509fi
c0d27fcc 14510echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
14511echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
14512if test $ac_cv_lib_util_getloadavg = yes; then
14513 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 14514fi
503d2be0 14515
98418dba 14516fi
ba4481b5 14517
98418dba
CW
14518if test $ac_have_func = no; then
14519 # There is a commonly available library for RS/6000 AIX.
14520 # Since it is not a standard part of AIX, it might be installed locally.
14521 ac_getloadavg_LIBS=$LIBS
14522 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 14523 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
14524echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
14525if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 14526 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14527else
98418dba
CW
14528 ac_check_lib_save_LIBS=$LIBS
14529LIBS="-lgetloadavg $LIBS"
14530cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14531/* confdefs.h. */
14532_ACEOF
14533cat confdefs.h >>conftest.$ac_ext
14534cat >>conftest.$ac_ext <<_ACEOF
14535/* end confdefs.h. */
ba4481b5 14536
98418dba
CW
14537/* Override any gcc2 internal prototype to avoid an error. */
14538#ifdef __cplusplus
14539extern "C"
14540#endif
14541/* We use char because int might match the return type of a gcc2
14542 builtin and then its argument prototype would still apply. */
14543char getloadavg ();
98418dba
CW
14544int
14545main ()
14546{
14547getloadavg ();
14548 ;
14549 return 0;
14550}
503d2be0 14551_ACEOF
98418dba 14552rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14553if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14554 (eval $ac_link) 2>conftest.er1
98418dba 14555 ac_status=$?
35996d22
AS
14556 grep -v '^ *+' conftest.er1 >conftest.err
14557 rm -f conftest.er1
14558 cat conftest.err >&5
c0d27fcc 14559 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14560 (exit $ac_status); } &&
35996d22
AS
14561 { ac_try='test -z "$ac_c_werror_flag"
14562 || test ! -s conftest.err'
14563 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14564 (eval $ac_try) 2>&5
14565 ac_status=$?
14566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14567 (exit $ac_status); }; } &&
14568 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14569 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14570 (eval $ac_try) 2>&5
14571 ac_status=$?
c0d27fcc 14572 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14573 (exit $ac_status); }; }; then
14574 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 14575else
98418dba 14576 echo "$as_me: failed program was:" >&5
19650fd6
AS
14577sed 's/^/| /' conftest.$ac_ext >&5
14578
98418dba
CW
14579ac_cv_lib_getloadavg_getloadavg=no
14580fi
35996d22
AS
14581rm -f conftest.err conftest.$ac_objext \
14582 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14583LIBS=$ac_check_lib_save_LIBS
14584fi
c0d27fcc 14585echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
14586echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
14587if test $ac_cv_lib_getloadavg_getloadavg = yes; then
14588 LIBS="-lgetloadavg $LIBS"
14589else
14590 LIBS=$ac_getloadavg_LIBS
ba4481b5 14591fi
ba4481b5
DL
14592
14593fi
98418dba
CW
14594
14595# Make sure it is really in the library, if we think we found it,
14596# otherwise set up the replacement function.
14597
14598for ac_func in getloadavg
14599do
14600as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14601echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
14602echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14603if eval "test \"\${$as_ac_var+set}\" = set"; then
14604 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14605else
503d2be0 14606 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14607/* confdefs.h. */
14608_ACEOF
14609cat confdefs.h >>conftest.$ac_ext
14610cat >>conftest.$ac_ext <<_ACEOF
14611/* end confdefs.h. */
35996d22
AS
14612/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14613 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14614#define $ac_func innocuous_$ac_func
14615
ba4481b5 14616/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14617 which can conflict with char $ac_func (); below.
14618 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14619 <limits.h> exists even on freestanding compilers. */
35996d22 14620
19650fd6
AS
14621#ifdef __STDC__
14622# include <limits.h>
14623#else
14624# include <assert.h>
14625#endif
35996d22
AS
14626
14627#undef $ac_func
14628
ba4481b5 14629/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14630#ifdef __cplusplus
14631extern "C"
19650fd6 14632{
503d2be0 14633#endif
ba4481b5 14634/* We use char because int might match the return type of a gcc2
503d2be0
AS
14635 builtin and then its argument prototype would still apply. */
14636char $ac_func ();
ba4481b5
DL
14637/* The GNU C library defines this for functions which it implements
14638 to always fail with ENOSYS. Some functions are actually named
14639 something starting with __ and the normal name is an alias. */
14640#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14641choke me
14642#else
19650fd6
AS
14643char (*f) () = $ac_func;
14644#endif
14645#ifdef __cplusplus
14646}
cd958eb3
MB
14647#endif
14648
19650fd6
AS
14649int
14650main ()
14651{
14652return f != $ac_func;
503d2be0
AS
14653 ;
14654 return 0;
14655}
14656_ACEOF
14657rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14658if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14659 (eval $ac_link) 2>conftest.er1
503d2be0 14660 ac_status=$?
35996d22
AS
14661 grep -v '^ *+' conftest.er1 >conftest.err
14662 rm -f conftest.er1
14663 cat conftest.err >&5
c0d27fcc 14664 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14665 (exit $ac_status); } &&
35996d22
AS
14666 { ac_try='test -z "$ac_c_werror_flag"
14667 || test ! -s conftest.err'
14668 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14669 (eval $ac_try) 2>&5
14670 ac_status=$?
14671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14672 (exit $ac_status); }; } &&
14673 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14674 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14675 (eval $ac_try) 2>&5
14676 ac_status=$?
c0d27fcc 14677 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14678 (exit $ac_status); }; }; then
14679 eval "$as_ac_var=yes"
14680else
14681 echo "$as_me: failed program was:" >&5
19650fd6
AS
14682sed 's/^/| /' conftest.$ac_ext >&5
14683
503d2be0
AS
14684eval "$as_ac_var=no"
14685fi
35996d22
AS
14686rm -f conftest.err conftest.$ac_objext \
14687 conftest$ac_exeext conftest.$ac_ext
503d2be0 14688fi
c0d27fcc 14689echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14690echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14691if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14692 cat >>confdefs.h <<_ACEOF
98418dba 14693#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14694_ACEOF
503d2be0 14695
98418dba 14696else
35996d22
AS
14697 case $LIBOBJS in
14698 "getloadavg.$ac_objext" | \
14699 *" getloadavg.$ac_objext" | \
14700 "getloadavg.$ac_objext "* | \
14701 *" getloadavg.$ac_objext "* ) ;;
14702 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext" ;;
14703esac
14704
ba4481b5 14705
c0d27fcc 14706cat >>confdefs.h <<\_ACEOF
98418dba 14707#define C_GETLOADAVG 1
c0d27fcc 14708_ACEOF
ba4481b5 14709
98418dba
CW
14710# Figure out what our getloadavg.c needs.
14711ac_have_func=no
c0d27fcc
MR
14712if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14713 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
14714echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14715if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 14716 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14717fi
14718echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
14719echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 14720else
c0d27fcc
MR
14721 # Is the header compilable?
14722echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
14723echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
14724cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14725/* confdefs.h. */
14726_ACEOF
14727cat confdefs.h >>conftest.$ac_ext
14728cat >>conftest.$ac_ext <<_ACEOF
14729/* end confdefs.h. */
c0d27fcc
MR
14730$ac_includes_default
14731#include <sys/dg_sys_info.h>
14732_ACEOF
14733rm -f conftest.$ac_objext
14734if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 14735 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14736 ac_status=$?
35996d22
AS
14737 grep -v '^ *+' conftest.er1 >conftest.err
14738 rm -f conftest.er1
14739 cat conftest.err >&5
c0d27fcc
MR
14740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14741 (exit $ac_status); } &&
35996d22
AS
14742 { ac_try='test -z "$ac_c_werror_flag"
14743 || test ! -s conftest.err'
14744 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14745 (eval $ac_try) 2>&5
14746 ac_status=$?
14747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14748 (exit $ac_status); }; } &&
14749 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14750 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14751 (eval $ac_try) 2>&5
14752 ac_status=$?
14753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14754 (exit $ac_status); }; }; then
14755 ac_header_compiler=yes
14756else
14757 echo "$as_me: failed program was:" >&5
19650fd6
AS
14758sed 's/^/| /' conftest.$ac_ext >&5
14759
c0d27fcc
MR
14760ac_header_compiler=no
14761fi
35996d22 14762rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14763echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14764echo "${ECHO_T}$ac_header_compiler" >&6
14765
14766# Is the header present?
14767echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
14768echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
14769cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14770/* confdefs.h. */
14771_ACEOF
14772cat confdefs.h >>conftest.$ac_ext
14773cat >>conftest.$ac_ext <<_ACEOF
14774/* end confdefs.h. */
98418dba
CW
14775#include <sys/dg_sys_info.h>
14776_ACEOF
c0d27fcc 14777if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
14778 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14779 ac_status=$?
6bae0ccf 14780 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14781 rm -f conftest.er1
14782 cat conftest.err >&5
c0d27fcc 14783 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14784 (exit $ac_status); } >/dev/null; then
14785 if test -s conftest.err; then
14786 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 14787 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
14788 else
14789 ac_cpp_err=
14790 fi
14791else
14792 ac_cpp_err=yes
ba4481b5 14793fi
98418dba 14794if test -z "$ac_cpp_err"; then
c0d27fcc 14795 ac_header_preproc=yes
98418dba
CW
14796else
14797 echo "$as_me: failed program was:" >&5
19650fd6
AS
14798sed 's/^/| /' conftest.$ac_ext >&5
14799
c0d27fcc 14800 ac_header_preproc=no
ba4481b5 14801fi
98418dba 14802rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14803echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14804echo "${ECHO_T}$ac_header_preproc" >&6
14805
14806# So? What about this header?
35996d22
AS
14807case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14808 yes:no: )
c0d27fcc
MR
14809 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
14810echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
14811 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&5
14812echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&2;}
14813 ac_header_preproc=yes
19650fd6 14814 ;;
35996d22 14815 no:yes:* )
c0d27fcc
MR
14816 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
14817echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
35996d22
AS
14818 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
14819echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
14820 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&5
14821echo "$as_me: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&2;}
14822 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&5
14823echo "$as_me: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 14824 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
19650fd6 14825echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
14826 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&5
14827echo "$as_me: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
14828 (
14829 cat <<\_ASBOX
35996d22
AS
14830## ------------------------------------------ ##
14831## Report this to the AC_PACKAGE_NAME lists. ##
14832## ------------------------------------------ ##
19650fd6
AS
14833_ASBOX
14834 ) |
14835 sed "s/^/$as_me: WARNING: /" >&2
14836 ;;
c0d27fcc
MR
14837esac
14838echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
14839echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14840if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14841 echo $ECHO_N "(cached) $ECHO_C" >&6
14842else
14843 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 14844fi
c0d27fcc 14845echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 14846echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
14847
14848fi
98418dba
CW
14849if test $ac_cv_header_sys_dg_sys_info_h = yes; then
14850 ac_have_func=yes
ba4481b5 14851
c0d27fcc 14852cat >>confdefs.h <<\_ACEOF
98418dba 14853#define DGUX 1
c0d27fcc
MR
14854_ACEOF
14855
503d2be0 14856
c0d27fcc 14857echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
14858echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
14859if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 14860 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14861else
503d2be0 14862 ac_check_lib_save_LIBS=$LIBS
98418dba 14863LIBS="-ldgc $LIBS"
503d2be0 14864cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14865/* confdefs.h. */
14866_ACEOF
14867cat confdefs.h >>conftest.$ac_ext
14868cat >>conftest.$ac_ext <<_ACEOF
14869/* end confdefs.h. */
503d2be0 14870
ba4481b5 14871/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14872#ifdef __cplusplus
14873extern "C"
14874#endif
ba4481b5 14875/* We use char because int might match the return type of a gcc2
503d2be0 14876 builtin and then its argument prototype would still apply. */
98418dba 14877char dg_sys_info ();
503d2be0
AS
14878int
14879main ()
14880{
98418dba 14881dg_sys_info ();
503d2be0
AS
14882 ;
14883 return 0;
14884}
14885_ACEOF
14886rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14887if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14888 (eval $ac_link) 2>conftest.er1
503d2be0 14889 ac_status=$?
35996d22
AS
14890 grep -v '^ *+' conftest.er1 >conftest.err
14891 rm -f conftest.er1
14892 cat conftest.err >&5
c0d27fcc 14893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14894 (exit $ac_status); } &&
35996d22
AS
14895 { ac_try='test -z "$ac_c_werror_flag"
14896 || test ! -s conftest.err'
14897 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14898 (eval $ac_try) 2>&5
14899 ac_status=$?
14900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14901 (exit $ac_status); }; } &&
14902 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14903 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14904 (eval $ac_try) 2>&5
14905 ac_status=$?
c0d27fcc 14906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14907 (exit $ac_status); }; }; then
98418dba 14908 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
14909else
14910 echo "$as_me: failed program was:" >&5
19650fd6
AS
14911sed 's/^/| /' conftest.$ac_ext >&5
14912
98418dba 14913ac_cv_lib_dgc_dg_sys_info=no
503d2be0 14914fi
35996d22
AS
14915rm -f conftest.err conftest.$ac_objext \
14916 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
14917LIBS=$ac_check_lib_save_LIBS
14918fi
c0d27fcc 14919echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
14920echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
14921if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 14922 cat >>confdefs.h <<_ACEOF
98418dba 14923#define HAVE_LIBDGC 1
c0d27fcc 14924_ACEOF
ba4481b5 14925
98418dba 14926 LIBS="-ldgc $LIBS"
ba4481b5 14927
ba4481b5
DL
14928fi
14929
98418dba 14930fi
503d2be0 14931
c0d27fcc
MR
14932
14933
14934if test "${ac_cv_header_locale_h+set}" = set; then
14935 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
14936echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
14937if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 14938 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14939fi
14940echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
14941echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 14942else
c0d27fcc
MR
14943 # Is the header compilable?
14944echo "$as_me:$LINENO: checking locale.h usability" >&5
14945echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
14946cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14947/* confdefs.h. */
14948_ACEOF
14949cat confdefs.h >>conftest.$ac_ext
14950cat >>conftest.$ac_ext <<_ACEOF
14951/* end confdefs.h. */
c0d27fcc
MR
14952$ac_includes_default
14953#include <locale.h>
14954_ACEOF
14955rm -f conftest.$ac_objext
14956if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 14957 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14958 ac_status=$?
35996d22
AS
14959 grep -v '^ *+' conftest.er1 >conftest.err
14960 rm -f conftest.er1
14961 cat conftest.err >&5
c0d27fcc
MR
14962 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14963 (exit $ac_status); } &&
35996d22
AS
14964 { ac_try='test -z "$ac_c_werror_flag"
14965 || test ! -s conftest.err'
14966 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14967 (eval $ac_try) 2>&5
14968 ac_status=$?
14969 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14970 (exit $ac_status); }; } &&
14971 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14972 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14973 (eval $ac_try) 2>&5
14974 ac_status=$?
14975 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14976 (exit $ac_status); }; }; then
14977 ac_header_compiler=yes
14978else
14979 echo "$as_me: failed program was:" >&5
19650fd6
AS
14980sed 's/^/| /' conftest.$ac_ext >&5
14981
c0d27fcc
MR
14982ac_header_compiler=no
14983fi
35996d22 14984rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14985echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14986echo "${ECHO_T}$ac_header_compiler" >&6
14987
14988# Is the header present?
14989echo "$as_me:$LINENO: checking locale.h presence" >&5
14990echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
14991cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14992/* confdefs.h. */
14993_ACEOF
14994cat confdefs.h >>conftest.$ac_ext
14995cat >>conftest.$ac_ext <<_ACEOF
14996/* end confdefs.h. */
98418dba 14997#include <locale.h>
503d2be0 14998_ACEOF
c0d27fcc 14999if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 15000 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 15001 ac_status=$?
6bae0ccf 15002 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15003 rm -f conftest.er1
15004 cat conftest.err >&5
c0d27fcc 15005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15006 (exit $ac_status); } >/dev/null; then
15007 if test -s conftest.err; then
15008 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15009 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15010 else
15011 ac_cpp_err=
15012 fi
503d2be0 15013else
98418dba 15014 ac_cpp_err=yes
503d2be0 15015fi
98418dba 15016if test -z "$ac_cpp_err"; then
c0d27fcc 15017 ac_header_preproc=yes
98418dba
CW
15018else
15019 echo "$as_me: failed program was:" >&5
19650fd6
AS
15020sed 's/^/| /' conftest.$ac_ext >&5
15021
c0d27fcc 15022 ac_header_preproc=no
ba4481b5 15023fi
98418dba 15024rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15025echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15026echo "${ECHO_T}$ac_header_preproc" >&6
15027
15028# So? What about this header?
35996d22
AS
15029case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15030 yes:no: )
c0d27fcc
MR
15031 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
15032echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15033 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the compiler's result" >&5
15034echo "$as_me: WARNING: locale.h: proceeding with the compiler's result" >&2;}
15035 ac_header_preproc=yes
19650fd6 15036 ;;
35996d22 15037 no:yes:* )
c0d27fcc
MR
15038 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
15039echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
35996d22
AS
15040 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
15041echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
15042 { echo "$as_me:$LINENO: WARNING: locale.h: see the Autoconf documentation" >&5
15043echo "$as_me: WARNING: locale.h: see the Autoconf documentation" >&2;}
15044 { echo "$as_me:$LINENO: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&5
15045echo "$as_me: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15046 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
19650fd6 15047echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15048 { echo "$as_me:$LINENO: WARNING: locale.h: in the future, the compiler will take precedence" >&5
15049echo "$as_me: WARNING: locale.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15050 (
15051 cat <<\_ASBOX
35996d22
AS
15052## ------------------------------------------ ##
15053## Report this to the AC_PACKAGE_NAME lists. ##
15054## ------------------------------------------ ##
19650fd6
AS
15055_ASBOX
15056 ) |
15057 sed "s/^/$as_me: WARNING: /" >&2
15058 ;;
c0d27fcc
MR
15059esac
15060echo "$as_me:$LINENO: checking for locale.h" >&5
15061echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15062if test "${ac_cv_header_locale_h+set}" = set; then
15063 echo $ECHO_N "(cached) $ECHO_C" >&6
15064else
15065 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 15066fi
c0d27fcc 15067echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
15068echo "${ECHO_T}$ac_cv_header_locale_h" >&6
15069
c0d27fcc
MR
15070fi
15071
15072
15073
98418dba 15074for ac_func in setlocale
ba4481b5 15075do
503d2be0 15076as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15077echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15078echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15079if eval "test \"\${$as_ac_var+set}\" = set"; then
15080 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15081else
503d2be0 15082 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15083/* confdefs.h. */
15084_ACEOF
15085cat confdefs.h >>conftest.$ac_ext
15086cat >>conftest.$ac_ext <<_ACEOF
15087/* end confdefs.h. */
35996d22
AS
15088/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15089 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15090#define $ac_func innocuous_$ac_func
15091
ba4481b5 15092/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15093 which can conflict with char $ac_func (); below.
15094 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15095 <limits.h> exists even on freestanding compilers. */
35996d22 15096
19650fd6
AS
15097#ifdef __STDC__
15098# include <limits.h>
15099#else
15100# include <assert.h>
15101#endif
35996d22
AS
15102
15103#undef $ac_func
15104
ba4481b5 15105/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15106#ifdef __cplusplus
15107extern "C"
19650fd6 15108{
503d2be0 15109#endif
ba4481b5 15110/* We use char because int might match the return type of a gcc2
503d2be0
AS
15111 builtin and then its argument prototype would still apply. */
15112char $ac_func ();
ba4481b5
DL
15113/* The GNU C library defines this for functions which it implements
15114 to always fail with ENOSYS. Some functions are actually named
15115 something starting with __ and the normal name is an alias. */
15116#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15117choke me
15118#else
19650fd6
AS
15119char (*f) () = $ac_func;
15120#endif
15121#ifdef __cplusplus
15122}
ba4481b5
DL
15123#endif
15124
19650fd6
AS
15125int
15126main ()
15127{
15128return f != $ac_func;
503d2be0
AS
15129 ;
15130 return 0;
15131}
15132_ACEOF
15133rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15134if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 15135 (eval $ac_link) 2>conftest.er1
503d2be0 15136 ac_status=$?
35996d22
AS
15137 grep -v '^ *+' conftest.er1 >conftest.err
15138 rm -f conftest.er1
15139 cat conftest.err >&5
c0d27fcc 15140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15141 (exit $ac_status); } &&
35996d22
AS
15142 { ac_try='test -z "$ac_c_werror_flag"
15143 || test ! -s conftest.err'
15144 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15145 (eval $ac_try) 2>&5
15146 ac_status=$?
15147 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15148 (exit $ac_status); }; } &&
15149 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15150 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15151 (eval $ac_try) 2>&5
15152 ac_status=$?
c0d27fcc 15153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15154 (exit $ac_status); }; }; then
15155 eval "$as_ac_var=yes"
15156else
15157 echo "$as_me: failed program was:" >&5
19650fd6
AS
15158sed 's/^/| /' conftest.$ac_ext >&5
15159
503d2be0
AS
15160eval "$as_ac_var=no"
15161fi
35996d22
AS
15162rm -f conftest.err conftest.$ac_objext \
15163 conftest$ac_exeext conftest.$ac_ext
503d2be0 15164fi
c0d27fcc 15165echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15166echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15167if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15168 cat >>confdefs.h <<_ACEOF
503d2be0 15169#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15170_ACEOF
ba4481b5 15171
ba4481b5
DL
15172fi
15173done
15174
c0d27fcc 15175
98418dba
CW
15176# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
15177# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
15178# Irix 4.0.5F has the header but not the library.
15179if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
15180 ac_have_func=yes
15181
c0d27fcc 15182cat >>confdefs.h <<\_ACEOF
98418dba 15183#define SVR4 1
c0d27fcc 15184_ACEOF
98418dba
CW
15185
15186fi
15187
15188if test $ac_have_func = no; then
c0d27fcc
MR
15189 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15190 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
15191echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15192if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 15193 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15194fi
15195echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
15196echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 15197else
c0d27fcc
MR
15198 # Is the header compilable?
15199echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
15200echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
15201cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15202/* confdefs.h. */
15203_ACEOF
15204cat confdefs.h >>conftest.$ac_ext
15205cat >>conftest.$ac_ext <<_ACEOF
15206/* end confdefs.h. */
c0d27fcc
MR
15207$ac_includes_default
15208#include <inq_stats/cpustats.h>
15209_ACEOF
15210rm -f conftest.$ac_objext
15211if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15212 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15213 ac_status=$?
35996d22
AS
15214 grep -v '^ *+' conftest.er1 >conftest.err
15215 rm -f conftest.er1
15216 cat conftest.err >&5
c0d27fcc
MR
15217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15218 (exit $ac_status); } &&
35996d22
AS
15219 { ac_try='test -z "$ac_c_werror_flag"
15220 || test ! -s conftest.err'
15221 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15222 (eval $ac_try) 2>&5
15223 ac_status=$?
15224 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15225 (exit $ac_status); }; } &&
15226 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15227 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15228 (eval $ac_try) 2>&5
15229 ac_status=$?
15230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15231 (exit $ac_status); }; }; then
15232 ac_header_compiler=yes
15233else
15234 echo "$as_me: failed program was:" >&5
19650fd6
AS
15235sed 's/^/| /' conftest.$ac_ext >&5
15236
c0d27fcc
MR
15237ac_header_compiler=no
15238fi
35996d22 15239rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15240echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15241echo "${ECHO_T}$ac_header_compiler" >&6
15242
15243# Is the header present?
15244echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
15245echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
15246cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15247/* confdefs.h. */
15248_ACEOF
15249cat confdefs.h >>conftest.$ac_ext
15250cat >>conftest.$ac_ext <<_ACEOF
15251/* end confdefs.h. */
98418dba 15252#include <inq_stats/cpustats.h>
503d2be0 15253_ACEOF
c0d27fcc 15254if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15255 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15256 ac_status=$?
6bae0ccf 15257 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15258 rm -f conftest.er1
15259 cat conftest.err >&5
c0d27fcc 15260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15261 (exit $ac_status); } >/dev/null; then
15262 if test -s conftest.err; then
15263 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15264 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15265 else
15266 ac_cpp_err=
15267 fi
15268else
15269 ac_cpp_err=yes
15270fi
15271if test -z "$ac_cpp_err"; then
c0d27fcc 15272 ac_header_preproc=yes
503d2be0
AS
15273else
15274 echo "$as_me: failed program was:" >&5
19650fd6
AS
15275sed 's/^/| /' conftest.$ac_ext >&5
15276
c0d27fcc 15277 ac_header_preproc=no
ba4481b5 15278fi
503d2be0 15279rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15280echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15281echo "${ECHO_T}$ac_header_preproc" >&6
15282
15283# So? What about this header?
35996d22
AS
15284case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15285 yes:no: )
c0d27fcc
MR
15286 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15287echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15288 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&5
15289echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&2;}
15290 ac_header_preproc=yes
19650fd6 15291 ;;
35996d22 15292 no:yes:* )
c0d27fcc
MR
15293 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
15294echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15295 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
15296echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
15297 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&5
15298echo "$as_me: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&2;}
15299 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15300echo "$as_me: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15301 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15302echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15303 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&5
15304echo "$as_me: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15305 (
15306 cat <<\_ASBOX
35996d22
AS
15307## ------------------------------------------ ##
15308## Report this to the AC_PACKAGE_NAME lists. ##
15309## ------------------------------------------ ##
19650fd6
AS
15310_ASBOX
15311 ) |
15312 sed "s/^/$as_me: WARNING: /" >&2
15313 ;;
c0d27fcc
MR
15314esac
15315echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
15316echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15317if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15318 echo $ECHO_N "(cached) $ECHO_C" >&6
15319else
15320 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 15321fi
c0d27fcc 15322echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 15323echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
15324
15325fi
98418dba
CW
15326if test $ac_cv_header_inq_stats_cpustats_h = yes; then
15327 ac_have_func=yes
ba4481b5 15328
c0d27fcc 15329cat >>confdefs.h <<\_ACEOF
98418dba 15330#define UMAX 1
c0d27fcc 15331_ACEOF
98418dba 15332
c0d27fcc
MR
15333
15334cat >>confdefs.h <<\_ACEOF
98418dba 15335#define UMAX4_3 1
c0d27fcc 15336_ACEOF
98418dba
CW
15337
15338fi
15339
c0d27fcc 15340
98418dba
CW
15341fi
15342
15343if test $ac_have_func = no; then
c0d27fcc
MR
15344 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15345 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
15346echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15347if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 15348 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15349fi
15350echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
15351echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 15352else
c0d27fcc
MR
15353 # Is the header compilable?
15354echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
15355echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
15356cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15357/* confdefs.h. */
15358_ACEOF
15359cat confdefs.h >>conftest.$ac_ext
15360cat >>conftest.$ac_ext <<_ACEOF
15361/* end confdefs.h. */
c0d27fcc
MR
15362$ac_includes_default
15363#include <sys/cpustats.h>
15364_ACEOF
15365rm -f conftest.$ac_objext
15366if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15367 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15368 ac_status=$?
35996d22
AS
15369 grep -v '^ *+' conftest.er1 >conftest.err
15370 rm -f conftest.er1
15371 cat conftest.err >&5
c0d27fcc
MR
15372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15373 (exit $ac_status); } &&
35996d22
AS
15374 { ac_try='test -z "$ac_c_werror_flag"
15375 || test ! -s conftest.err'
15376 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15377 (eval $ac_try) 2>&5
15378 ac_status=$?
15379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15380 (exit $ac_status); }; } &&
15381 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15382 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15383 (eval $ac_try) 2>&5
15384 ac_status=$?
15385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15386 (exit $ac_status); }; }; then
15387 ac_header_compiler=yes
15388else
15389 echo "$as_me: failed program was:" >&5
19650fd6
AS
15390sed 's/^/| /' conftest.$ac_ext >&5
15391
c0d27fcc
MR
15392ac_header_compiler=no
15393fi
35996d22 15394rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15395echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15396echo "${ECHO_T}$ac_header_compiler" >&6
15397
15398# Is the header present?
15399echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
15400echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
15401cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15402/* confdefs.h. */
15403_ACEOF
15404cat confdefs.h >>conftest.$ac_ext
15405cat >>conftest.$ac_ext <<_ACEOF
15406/* end confdefs.h. */
98418dba
CW
15407#include <sys/cpustats.h>
15408_ACEOF
c0d27fcc 15409if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
15410 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15411 ac_status=$?
6bae0ccf 15412 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15413 rm -f conftest.er1
15414 cat conftest.err >&5
c0d27fcc 15415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15416 (exit $ac_status); } >/dev/null; then
15417 if test -s conftest.err; then
15418 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15419 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15420 else
15421 ac_cpp_err=
15422 fi
15423else
15424 ac_cpp_err=yes
503d2be0 15425fi
98418dba 15426if test -z "$ac_cpp_err"; then
c0d27fcc 15427 ac_header_preproc=yes
98418dba
CW
15428else
15429 echo "$as_me: failed program was:" >&5
19650fd6
AS
15430sed 's/^/| /' conftest.$ac_ext >&5
15431
c0d27fcc 15432 ac_header_preproc=no
98418dba
CW
15433fi
15434rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15435echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15436echo "${ECHO_T}$ac_header_preproc" >&6
15437
15438# So? What about this header?
35996d22
AS
15439case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15440 yes:no: )
c0d27fcc
MR
15441 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15442echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15443 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&5
15444echo "$as_me: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&2;}
15445 ac_header_preproc=yes
19650fd6 15446 ;;
35996d22 15447 no:yes:* )
c0d27fcc
MR
15448 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
15449echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15450 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
15451echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
15452 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: see the Autoconf documentation" >&5
15453echo "$as_me: WARNING: sys/cpustats.h: see the Autoconf documentation" >&2;}
15454 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15455echo "$as_me: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15456 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15457echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15458 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&5
15459echo "$as_me: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15460 (
15461 cat <<\_ASBOX
35996d22
AS
15462## ------------------------------------------ ##
15463## Report this to the AC_PACKAGE_NAME lists. ##
15464## ------------------------------------------ ##
19650fd6
AS
15465_ASBOX
15466 ) |
15467 sed "s/^/$as_me: WARNING: /" >&2
15468 ;;
c0d27fcc
MR
15469esac
15470echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
15471echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15472if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15473 echo $ECHO_N "(cached) $ECHO_C" >&6
15474else
15475 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 15476fi
c0d27fcc 15477echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 15478echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
15479
15480fi
98418dba 15481if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 15482 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 15483#define UMAX 1
c0d27fcc 15484_ACEOF
ba4481b5 15485
98418dba
CW
15486fi
15487
c0d27fcc 15488
98418dba
CW
15489fi
15490
15491if test $ac_have_func = no; then
15492
15493for ac_header in mach/mach.h
2c9dccc9
PJ
15494do
15495as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15496if eval "test \"\${$as_ac_Header+set}\" = set"; then
15497 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
15498echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15499if eval "test \"\${$as_ac_Header+set}\" = set"; then
15500 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15501fi
15502echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15503echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15504else
c0d27fcc
MR
15505 # Is the header compilable?
15506echo "$as_me:$LINENO: checking $ac_header usability" >&5
15507echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15508cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15509/* confdefs.h. */
15510_ACEOF
15511cat confdefs.h >>conftest.$ac_ext
15512cat >>conftest.$ac_ext <<_ACEOF
15513/* end confdefs.h. */
c0d27fcc
MR
15514$ac_includes_default
15515#include <$ac_header>
15516_ACEOF
15517rm -f conftest.$ac_objext
15518if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15519 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15520 ac_status=$?
35996d22
AS
15521 grep -v '^ *+' conftest.er1 >conftest.err
15522 rm -f conftest.er1
15523 cat conftest.err >&5
c0d27fcc
MR
15524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15525 (exit $ac_status); } &&
35996d22
AS
15526 { ac_try='test -z "$ac_c_werror_flag"
15527 || test ! -s conftest.err'
15528 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15529 (eval $ac_try) 2>&5
15530 ac_status=$?
15531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15532 (exit $ac_status); }; } &&
15533 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15534 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15535 (eval $ac_try) 2>&5
15536 ac_status=$?
15537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15538 (exit $ac_status); }; }; then
15539 ac_header_compiler=yes
15540else
15541 echo "$as_me: failed program was:" >&5
19650fd6
AS
15542sed 's/^/| /' conftest.$ac_ext >&5
15543
c0d27fcc
MR
15544ac_header_compiler=no
15545fi
35996d22 15546rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15547echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15548echo "${ECHO_T}$ac_header_compiler" >&6
15549
15550# Is the header present?
15551echo "$as_me:$LINENO: checking $ac_header presence" >&5
15552echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15553cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15554/* confdefs.h. */
15555_ACEOF
15556cat confdefs.h >>conftest.$ac_ext
15557cat >>conftest.$ac_ext <<_ACEOF
15558/* end confdefs.h. */
2c9dccc9
PJ
15559#include <$ac_header>
15560_ACEOF
c0d27fcc 15561if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
15562 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15563 ac_status=$?
6bae0ccf 15564 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
15565 rm -f conftest.er1
15566 cat conftest.err >&5
c0d27fcc 15567 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
15568 (exit $ac_status); } >/dev/null; then
15569 if test -s conftest.err; then
15570 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15571 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2c9dccc9
PJ
15572 else
15573 ac_cpp_err=
15574 fi
15575else
15576 ac_cpp_err=yes
15577fi
15578if test -z "$ac_cpp_err"; then
c0d27fcc
MR
15579 ac_header_preproc=yes
15580else
15581 echo "$as_me: failed program was:" >&5
19650fd6
AS
15582sed 's/^/| /' conftest.$ac_ext >&5
15583
c0d27fcc
MR
15584 ac_header_preproc=no
15585fi
15586rm -f conftest.err conftest.$ac_ext
15587echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15588echo "${ECHO_T}$ac_header_preproc" >&6
15589
15590# So? What about this header?
35996d22
AS
15591case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15592 yes:no: )
c0d27fcc
MR
15593 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15594echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15595 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15596echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15597 ac_header_preproc=yes
19650fd6 15598 ;;
35996d22 15599 no:yes:* )
c0d27fcc
MR
15600 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15601echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15602 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15603echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15604 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15605echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15606 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15607echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15608 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15609echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15610 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15611echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15612 (
15613 cat <<\_ASBOX
35996d22
AS
15614## ------------------------------------------ ##
15615## Report this to the AC_PACKAGE_NAME lists. ##
15616## ------------------------------------------ ##
19650fd6
AS
15617_ASBOX
15618 ) |
15619 sed "s/^/$as_me: WARNING: /" >&2
15620 ;;
c0d27fcc
MR
15621esac
15622echo "$as_me:$LINENO: checking for $ac_header" >&5
15623echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15624if eval "test \"\${$as_ac_Header+set}\" = set"; then
15625 echo $ECHO_N "(cached) $ECHO_C" >&6
15626else
35996d22 15627 eval "$as_ac_Header=\$ac_header_preproc"
c0d27fcc
MR
15628fi
15629echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15630echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15631
15632fi
15633if test `eval echo '${'$as_ac_Header'}'` = yes; then
15634 cat >>confdefs.h <<_ACEOF
15635#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15636_ACEOF
15637
15638fi
15639
15640done
15641
15642fi
15643
15644
15645for ac_header in nlist.h
15646do
15647as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15648if eval "test \"\${$as_ac_Header+set}\" = set"; then
15649 echo "$as_me:$LINENO: checking for $ac_header" >&5
15650echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15651if eval "test \"\${$as_ac_Header+set}\" = set"; then
15652 echo $ECHO_N "(cached) $ECHO_C" >&6
15653fi
15654echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15655echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15656else
15657 # Is the header compilable?
15658echo "$as_me:$LINENO: checking $ac_header usability" >&5
15659echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15660cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15661/* confdefs.h. */
15662_ACEOF
15663cat confdefs.h >>conftest.$ac_ext
15664cat >>conftest.$ac_ext <<_ACEOF
15665/* end confdefs.h. */
c0d27fcc
MR
15666$ac_includes_default
15667#include <$ac_header>
15668_ACEOF
15669rm -f conftest.$ac_objext
15670if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15671 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15672 ac_status=$?
35996d22
AS
15673 grep -v '^ *+' conftest.er1 >conftest.err
15674 rm -f conftest.er1
15675 cat conftest.err >&5
c0d27fcc
MR
15676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15677 (exit $ac_status); } &&
35996d22
AS
15678 { ac_try='test -z "$ac_c_werror_flag"
15679 || test ! -s conftest.err'
15680 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15681 (eval $ac_try) 2>&5
15682 ac_status=$?
15683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15684 (exit $ac_status); }; } &&
15685 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15687 (eval $ac_try) 2>&5
15688 ac_status=$?
15689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15690 (exit $ac_status); }; }; then
15691 ac_header_compiler=yes
2c9dccc9
PJ
15692else
15693 echo "$as_me: failed program was:" >&5
19650fd6
AS
15694sed 's/^/| /' conftest.$ac_ext >&5
15695
c0d27fcc 15696ac_header_compiler=no
98418dba 15697fi
35996d22 15698rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15699echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15700echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 15701
c0d27fcc
MR
15702# Is the header present?
15703echo "$as_me:$LINENO: checking $ac_header presence" >&5
15704echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15705cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15706/* confdefs.h. */
15707_ACEOF
15708cat confdefs.h >>conftest.$ac_ext
15709cat >>conftest.$ac_ext <<_ACEOF
15710/* end confdefs.h. */
503d2be0
AS
15711#include <$ac_header>
15712_ACEOF
c0d27fcc 15713if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15714 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15715 ac_status=$?
6bae0ccf 15716 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15717 rm -f conftest.er1
15718 cat conftest.err >&5
c0d27fcc 15719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15720 (exit $ac_status); } >/dev/null; then
15721 if test -s conftest.err; then
15722 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15723 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15724 else
15725 ac_cpp_err=
15726 fi
15727else
15728 ac_cpp_err=yes
15729fi
15730if test -z "$ac_cpp_err"; then
c0d27fcc 15731 ac_header_preproc=yes
503d2be0
AS
15732else
15733 echo "$as_me: failed program was:" >&5
19650fd6
AS
15734sed 's/^/| /' conftest.$ac_ext >&5
15735
c0d27fcc 15736 ac_header_preproc=no
b5de8dc0 15737fi
503d2be0 15738rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15739echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15740echo "${ECHO_T}$ac_header_preproc" >&6
15741
15742# So? What about this header?
35996d22
AS
15743case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15744 yes:no: )
c0d27fcc
MR
15745 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15746echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15747 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15748echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15749 ac_header_preproc=yes
19650fd6 15750 ;;
35996d22 15751 no:yes:* )
c0d27fcc
MR
15752 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15753echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15754 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15755echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15756 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15757echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15758 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15759echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15760 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15761echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15762 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15763echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15764 (
15765 cat <<\_ASBOX
35996d22
AS
15766## ------------------------------------------ ##
15767## Report this to the AC_PACKAGE_NAME lists. ##
15768## ------------------------------------------ ##
19650fd6
AS
15769_ASBOX
15770 ) |
15771 sed "s/^/$as_me: WARNING: /" >&2
15772 ;;
c0d27fcc
MR
15773esac
15774echo "$as_me:$LINENO: checking for $ac_header" >&5
15775echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15776if eval "test \"\${$as_ac_Header+set}\" = set"; then
15777 echo $ECHO_N "(cached) $ECHO_C" >&6
15778else
35996d22 15779 eval "$as_ac_Header=\$ac_header_preproc"
b5de8dc0 15780fi
c0d27fcc 15781echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15782echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15783
15784fi
98418dba 15785if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15786 cat >>confdefs.h <<_ACEOF
98418dba 15787#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
15788_ACEOF
15789 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
15790echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
15791if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 15792 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 15793else
503d2be0 15794 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15795/* confdefs.h. */
15796_ACEOF
15797cat confdefs.h >>conftest.$ac_ext
15798cat >>conftest.$ac_ext <<_ACEOF
15799/* end confdefs.h. */
98418dba 15800#include <nlist.h>
b5de8dc0 15801
503d2be0
AS
15802int
15803main ()
15804{
98418dba
CW
15805static struct nlist ac_aggr;
15806if (ac_aggr.n_un.n_name)
15807return 0;
503d2be0
AS
15808 ;
15809 return 0;
15810}
15811_ACEOF
98418dba 15812rm -f conftest.$ac_objext
c0d27fcc 15813if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15814 (eval $ac_compile) 2>conftest.er1
503d2be0 15815 ac_status=$?
35996d22
AS
15816 grep -v '^ *+' conftest.er1 >conftest.err
15817 rm -f conftest.er1
15818 cat conftest.err >&5
c0d27fcc 15819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15820 (exit $ac_status); } &&
35996d22
AS
15821 { ac_try='test -z "$ac_c_werror_flag"
15822 || test ! -s conftest.err'
15823 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15824 (eval $ac_try) 2>&5
15825 ac_status=$?
15826 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15827 (exit $ac_status); }; } &&
15828 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15829 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15830 (eval $ac_try) 2>&5
15831 ac_status=$?
c0d27fcc 15832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15833 (exit $ac_status); }; }; then
98418dba 15834 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
15835else
15836 echo "$as_me: failed program was:" >&5
19650fd6
AS
15837sed 's/^/| /' conftest.$ac_ext >&5
15838
6bae0ccf 15839cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15840/* confdefs.h. */
15841_ACEOF
15842cat confdefs.h >>conftest.$ac_ext
15843cat >>conftest.$ac_ext <<_ACEOF
15844/* end confdefs.h. */
6bae0ccf
DL
15845#include <nlist.h>
15846
15847int
15848main ()
15849{
15850static struct nlist ac_aggr;
15851if (sizeof ac_aggr.n_un.n_name)
15852return 0;
15853 ;
15854 return 0;
15855}
15856_ACEOF
15857rm -f conftest.$ac_objext
15858if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15859 (eval $ac_compile) 2>conftest.er1
6bae0ccf 15860 ac_status=$?
35996d22
AS
15861 grep -v '^ *+' conftest.er1 >conftest.err
15862 rm -f conftest.er1
15863 cat conftest.err >&5
6bae0ccf
DL
15864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15865 (exit $ac_status); } &&
35996d22
AS
15866 { ac_try='test -z "$ac_c_werror_flag"
15867 || test ! -s conftest.err'
15868 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15869 (eval $ac_try) 2>&5
15870 ac_status=$?
15871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15872 (exit $ac_status); }; } &&
15873 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
15874 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15875 (eval $ac_try) 2>&5
15876 ac_status=$?
15877 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15878 (exit $ac_status); }; }; then
15879 ac_cv_member_struct_nlist_n_un_n_name=yes
15880else
15881 echo "$as_me: failed program was:" >&5
19650fd6
AS
15882sed 's/^/| /' conftest.$ac_ext >&5
15883
98418dba 15884ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 15885fi
35996d22 15886rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b5de8dc0 15887fi
35996d22 15888rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 15889fi
c0d27fcc 15890echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
15891echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
15892if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 15893
c0d27fcc 15894cat >>confdefs.h <<_ACEOF
98418dba 15895#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 15896_ACEOF
b5de8dc0 15897
c0d27fcc
MR
15898
15899cat >>confdefs.h <<\_ACEOF
98418dba 15900#define NLIST_NAME_UNION 1
c0d27fcc 15901_ACEOF
b5de8dc0 15902
98418dba 15903fi
b5de8dc0 15904
c0d27fcc 15905
98418dba 15906fi
c0d27fcc 15907
98418dba 15908done
b5de8dc0 15909
98418dba
CW
15910fi
15911done
b5de8dc0 15912
c0d27fcc 15913
98418dba 15914# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 15915echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
15916echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
15917if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
15918 echo $ECHO_N "(cached) $ECHO_C" >&6
15919else
15920 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15921/* confdefs.h. */
15922_ACEOF
15923cat confdefs.h >>conftest.$ac_ext
15924cat >>conftest.$ac_ext <<_ACEOF
15925/* end confdefs.h. */
6bae0ccf 15926#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
15927#ifdef LDAV_PRIVILEGED
15928Yowza Am I SETGID yet
15929#endif
15930_ACEOF
15931if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 15932 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
15933 ac_cv_func_getloadavg_setgid=yes
15934else
15935 ac_cv_func_getloadavg_setgid=no
15936fi
15937rm -f conftest*
b5de8dc0 15938
98418dba 15939fi
c0d27fcc 15940echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
15941echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
15942if test $ac_cv_func_getloadavg_setgid = yes; then
15943 NEED_SETGID=true
b5de8dc0 15944
c0d27fcc 15945cat >>confdefs.h <<\_ACEOF
98418dba 15946#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 15947_ACEOF
98418dba 15948
b5de8dc0 15949else
98418dba 15950 NEED_SETGID=false
b5de8dc0 15951fi
98418dba
CW
15952
15953if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 15954 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
15955echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
15956if test "${ac_cv_group_kmem+set}" = set; then
15957 echo $ECHO_N "(cached) $ECHO_C" >&6
15958else
15959 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
15960 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
15961 # If we got an error (system does not support symlinks), try without -L.
15962 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
15963 ac_cv_group_kmem=`echo $ac_ls_output \
35996d22 15964 | sed -ne 's/[ ][ ]*/ /g;
98418dba
CW
15965 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
15966 / /s/.* //;p;'`
15967
b5de8dc0 15968fi
c0d27fcc 15969echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
15970echo "${ECHO_T}$ac_cv_group_kmem" >&6
15971 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 15972fi
98418dba
CW
15973if test "x$ac_save_LIBS" = x; then
15974 GETLOADAVG_LIBS=$LIBS
15975else
15976 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 15977fi
98418dba 15978LIBS=$ac_save_LIBS
b5de8dc0 15979
c0d27fcc
MR
15980
15981
15982echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
15983echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
15984if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 15985 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 15986else
b936fae4
AS
15987 while :; do
15988 ac_cv_sys_largefile_source=no
503d2be0 15989 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15990/* confdefs.h. */
15991_ACEOF
15992cat confdefs.h >>conftest.$ac_ext
15993cat >>conftest.$ac_ext <<_ACEOF
15994/* end confdefs.h. */
b936fae4 15995#include <stdio.h>
503d2be0
AS
15996int
15997main ()
15998{
b936fae4
AS
15999return !fseeko;
16000 ;
16001 return 0;
16002}
16003_ACEOF
16004rm -f conftest.$ac_objext
c0d27fcc 16005if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16006 (eval $ac_compile) 2>conftest.er1
b936fae4 16007 ac_status=$?
35996d22
AS
16008 grep -v '^ *+' conftest.er1 >conftest.err
16009 rm -f conftest.er1
16010 cat conftest.err >&5
c0d27fcc 16011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16012 (exit $ac_status); } &&
35996d22
AS
16013 { ac_try='test -z "$ac_c_werror_flag"
16014 || test ! -s conftest.err'
16015 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16016 (eval $ac_try) 2>&5
16017 ac_status=$?
16018 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16019 (exit $ac_status); }; } &&
16020 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16021 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16022 (eval $ac_try) 2>&5
16023 ac_status=$?
c0d27fcc 16024 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16025 (exit $ac_status); }; }; then
16026 break
16027else
16028 echo "$as_me: failed program was:" >&5
19650fd6
AS
16029sed 's/^/| /' conftest.$ac_ext >&5
16030
b936fae4 16031fi
35996d22 16032rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4 16033 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16034/* confdefs.h. */
16035_ACEOF
16036cat confdefs.h >>conftest.$ac_ext
16037cat >>conftest.$ac_ext <<_ACEOF
16038/* end confdefs.h. */
b936fae4
AS
16039#define _LARGEFILE_SOURCE 1
16040#include <stdio.h>
b936fae4
AS
16041int
16042main ()
16043{
16044return !fseeko;
16045 ;
16046 return 0;
16047}
16048_ACEOF
16049rm -f conftest.$ac_objext
c0d27fcc 16050if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16051 (eval $ac_compile) 2>conftest.er1
b936fae4 16052 ac_status=$?
35996d22
AS
16053 grep -v '^ *+' conftest.er1 >conftest.err
16054 rm -f conftest.er1
16055 cat conftest.err >&5
c0d27fcc 16056 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16057 (exit $ac_status); } &&
35996d22
AS
16058 { ac_try='test -z "$ac_c_werror_flag"
16059 || test ! -s conftest.err'
16060 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16061 (eval $ac_try) 2>&5
16062 ac_status=$?
16063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16064 (exit $ac_status); }; } &&
16065 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16067 (eval $ac_try) 2>&5
16068 ac_status=$?
c0d27fcc 16069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16070 (exit $ac_status); }; }; then
16071 ac_cv_sys_largefile_source=1; break
16072else
16073 echo "$as_me: failed program was:" >&5
19650fd6
AS
16074sed 's/^/| /' conftest.$ac_ext >&5
16075
b936fae4 16076fi
35996d22 16077rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4
AS
16078 break
16079done
16080fi
c0d27fcc 16081echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
16082echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16083if test "$ac_cv_sys_largefile_source" != no; then
16084
c0d27fcc 16085cat >>confdefs.h <<_ACEOF
b936fae4 16086#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 16087_ACEOF
b936fae4
AS
16088
16089fi
16090rm -f conftest*
4c343001 16091
b936fae4
AS
16092# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16093# in glibc 2.1.3, but that breaks too many other things.
16094# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 16095echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
16096echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16097if test "${ac_cv_func_fseeko+set}" = set; then
16098 echo $ECHO_N "(cached) $ECHO_C" >&6
16099else
16100 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16101/* confdefs.h. */
16102_ACEOF
16103cat confdefs.h >>conftest.$ac_ext
16104cat >>conftest.$ac_ext <<_ACEOF
16105/* end confdefs.h. */
b936fae4 16106#include <stdio.h>
b936fae4
AS
16107int
16108main ()
16109{
16110return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
16111 ;
16112 return 0;
16113}
16114_ACEOF
16115rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16116if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16117 (eval $ac_link) 2>conftest.er1
503d2be0 16118 ac_status=$?
35996d22
AS
16119 grep -v '^ *+' conftest.er1 >conftest.err
16120 rm -f conftest.er1
16121 cat conftest.err >&5
c0d27fcc 16122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16123 (exit $ac_status); } &&
35996d22
AS
16124 { ac_try='test -z "$ac_c_werror_flag"
16125 || test ! -s conftest.err'
16126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16127 (eval $ac_try) 2>&5
16128 ac_status=$?
16129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16130 (exit $ac_status); }; } &&
16131 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16133 (eval $ac_try) 2>&5
16134 ac_status=$?
c0d27fcc 16135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16136 (exit $ac_status); }; }; then
b936fae4 16137 ac_cv_func_fseeko=yes
503d2be0
AS
16138else
16139 echo "$as_me: failed program was:" >&5
19650fd6
AS
16140sed 's/^/| /' conftest.$ac_ext >&5
16141
b936fae4 16142ac_cv_func_fseeko=no
503d2be0 16143fi
35996d22
AS
16144rm -f conftest.err conftest.$ac_objext \
16145 conftest$ac_exeext conftest.$ac_ext
503d2be0 16146fi
c0d27fcc 16147echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
16148echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16149if test $ac_cv_func_fseeko = yes; then
16150
c0d27fcc 16151cat >>confdefs.h <<\_ACEOF
b936fae4 16152#define HAVE_FSEEKO 1
c0d27fcc 16153_ACEOF
b936fae4 16154
4c343001
DL
16155fi
16156
c0d27fcc 16157
cd958eb3
MB
16158echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
16159echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
16160if test "${ac_cv_func_getpgrp_void+set}" = set; then
16161 echo $ECHO_N "(cached) $ECHO_C" >&6
16162else
16163 # Use it with a single arg.
16164cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16165/* confdefs.h. */
16166_ACEOF
16167cat confdefs.h >>conftest.$ac_ext
16168cat >>conftest.$ac_ext <<_ACEOF
16169/* end confdefs.h. */
cd958eb3
MB
16170$ac_includes_default
16171int
16172main ()
16173{
16174getpgrp (0);
16175 ;
16176 return 0;
16177}
16178_ACEOF
16179rm -f conftest.$ac_objext
16180if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16181 (eval $ac_compile) 2>conftest.er1
cd958eb3 16182 ac_status=$?
35996d22
AS
16183 grep -v '^ *+' conftest.er1 >conftest.err
16184 rm -f conftest.er1
16185 cat conftest.err >&5
cd958eb3
MB
16186 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16187 (exit $ac_status); } &&
35996d22
AS
16188 { ac_try='test -z "$ac_c_werror_flag"
16189 || test ! -s conftest.err'
16190 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16191 (eval $ac_try) 2>&5
16192 ac_status=$?
16193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16194 (exit $ac_status); }; } &&
16195 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
16196 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16197 (eval $ac_try) 2>&5
16198 ac_status=$?
16199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16200 (exit $ac_status); }; }; then
16201 ac_cv_func_getpgrp_void=no
16202else
16203 echo "$as_me: failed program was:" >&5
19650fd6
AS
16204sed 's/^/| /' conftest.$ac_ext >&5
16205
cd958eb3
MB
16206ac_cv_func_getpgrp_void=yes
16207fi
35996d22 16208rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
16209
16210fi
16211echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
16212echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
16213if test $ac_cv_func_getpgrp_void = yes; then
16214
16215cat >>confdefs.h <<\_ACEOF
16216#define GETPGRP_VOID 1
16217_ACEOF
16218
16219fi
16220
16221
973a76b1
DL
16222
16223for ac_func in strftime
16224do
16225as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16226echo "$as_me:$LINENO: checking for $ac_func" >&5
16227echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16228if eval "test \"\${$as_ac_var+set}\" = set"; then
16229 echo $ECHO_N "(cached) $ECHO_C" >&6
16230else
16231 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16232/* confdefs.h. */
16233_ACEOF
16234cat confdefs.h >>conftest.$ac_ext
16235cat >>conftest.$ac_ext <<_ACEOF
16236/* end confdefs.h. */
35996d22
AS
16237/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16238 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16239#define $ac_func innocuous_$ac_func
16240
973a76b1 16241/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16242 which can conflict with char $ac_func (); below.
16243 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16244 <limits.h> exists even on freestanding compilers. */
35996d22 16245
19650fd6
AS
16246#ifdef __STDC__
16247# include <limits.h>
16248#else
16249# include <assert.h>
16250#endif
35996d22
AS
16251
16252#undef $ac_func
16253
973a76b1
DL
16254/* Override any gcc2 internal prototype to avoid an error. */
16255#ifdef __cplusplus
16256extern "C"
19650fd6 16257{
973a76b1
DL
16258#endif
16259/* We use char because int might match the return type of a gcc2
16260 builtin and then its argument prototype would still apply. */
16261char $ac_func ();
16262/* The GNU C library defines this for functions which it implements
16263 to always fail with ENOSYS. Some functions are actually named
16264 something starting with __ and the normal name is an alias. */
16265#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16266choke me
16267#else
19650fd6
AS
16268char (*f) () = $ac_func;
16269#endif
16270#ifdef __cplusplus
16271}
973a76b1
DL
16272#endif
16273
19650fd6
AS
16274int
16275main ()
16276{
16277return f != $ac_func;
973a76b1
DL
16278 ;
16279 return 0;
16280}
16281_ACEOF
16282rm -f conftest.$ac_objext conftest$ac_exeext
16283if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16284 (eval $ac_link) 2>conftest.er1
973a76b1 16285 ac_status=$?
35996d22
AS
16286 grep -v '^ *+' conftest.er1 >conftest.err
16287 rm -f conftest.er1
16288 cat conftest.err >&5
973a76b1
DL
16289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16290 (exit $ac_status); } &&
35996d22
AS
16291 { ac_try='test -z "$ac_c_werror_flag"
16292 || test ! -s conftest.err'
16293 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16294 (eval $ac_try) 2>&5
16295 ac_status=$?
16296 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16297 (exit $ac_status); }; } &&
16298 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
16299 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16300 (eval $ac_try) 2>&5
16301 ac_status=$?
16302 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16303 (exit $ac_status); }; }; then
16304 eval "$as_ac_var=yes"
16305else
16306 echo "$as_me: failed program was:" >&5
19650fd6
AS
16307sed 's/^/| /' conftest.$ac_ext >&5
16308
973a76b1
DL
16309eval "$as_ac_var=no"
16310fi
35996d22
AS
16311rm -f conftest.err conftest.$ac_objext \
16312 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16313fi
16314echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16315echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16316if test `eval echo '${'$as_ac_var'}'` = yes; then
16317 cat >>confdefs.h <<_ACEOF
16318#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16319_ACEOF
16320
16321else
16322 # strftime is in -lintl on SCO UNIX.
16323echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
16324echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
16325if test "${ac_cv_lib_intl_strftime+set}" = set; then
16326 echo $ECHO_N "(cached) $ECHO_C" >&6
16327else
16328 ac_check_lib_save_LIBS=$LIBS
16329LIBS="-lintl $LIBS"
16330cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16331/* confdefs.h. */
16332_ACEOF
16333cat confdefs.h >>conftest.$ac_ext
16334cat >>conftest.$ac_ext <<_ACEOF
16335/* end confdefs.h. */
973a76b1
DL
16336
16337/* Override any gcc2 internal prototype to avoid an error. */
16338#ifdef __cplusplus
16339extern "C"
16340#endif
16341/* We use char because int might match the return type of a gcc2
16342 builtin and then its argument prototype would still apply. */
16343char strftime ();
16344int
16345main ()
16346{
16347strftime ();
16348 ;
16349 return 0;
16350}
16351_ACEOF
16352rm -f conftest.$ac_objext conftest$ac_exeext
16353if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16354 (eval $ac_link) 2>conftest.er1
973a76b1 16355 ac_status=$?
35996d22
AS
16356 grep -v '^ *+' conftest.er1 >conftest.err
16357 rm -f conftest.er1
16358 cat conftest.err >&5
973a76b1
DL
16359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16360 (exit $ac_status); } &&
35996d22
AS
16361 { ac_try='test -z "$ac_c_werror_flag"
16362 || test ! -s conftest.err'
16363 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16364 (eval $ac_try) 2>&5
16365 ac_status=$?
16366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16367 (exit $ac_status); }; } &&
16368 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
16369 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16370 (eval $ac_try) 2>&5
16371 ac_status=$?
16372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16373 (exit $ac_status); }; }; then
16374 ac_cv_lib_intl_strftime=yes
16375else
16376 echo "$as_me: failed program was:" >&5
19650fd6
AS
16377sed 's/^/| /' conftest.$ac_ext >&5
16378
973a76b1
DL
16379ac_cv_lib_intl_strftime=no
16380fi
35996d22
AS
16381rm -f conftest.err conftest.$ac_objext \
16382 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16383LIBS=$ac_check_lib_save_LIBS
16384fi
16385echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
16386echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
16387if test $ac_cv_lib_intl_strftime = yes; then
16388 cat >>confdefs.h <<\_ACEOF
16389#define HAVE_STRFTIME 1
16390_ACEOF
16391
16392LIBS="-lintl $LIBS"
16393fi
16394
16395fi
16396done
16397
16398
b936fae4
AS
16399# UNIX98 PTYs.
16400
16401for ac_func in grantpt
503d2be0
AS
16402do
16403as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16404echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
16405echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16406if eval "test \"\${$as_ac_var+set}\" = set"; then
16407 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16408else
503d2be0 16409 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16410/* confdefs.h. */
16411_ACEOF
16412cat confdefs.h >>conftest.$ac_ext
16413cat >>conftest.$ac_ext <<_ACEOF
16414/* end confdefs.h. */
35996d22
AS
16415/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16416 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16417#define $ac_func innocuous_$ac_func
16418
503d2be0 16419/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16420 which can conflict with char $ac_func (); below.
16421 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16422 <limits.h> exists even on freestanding compilers. */
35996d22 16423
19650fd6
AS
16424#ifdef __STDC__
16425# include <limits.h>
16426#else
16427# include <assert.h>
16428#endif
35996d22
AS
16429
16430#undef $ac_func
16431
4c343001 16432/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16433#ifdef __cplusplus
16434extern "C"
19650fd6 16435{
503d2be0 16436#endif
4c343001 16437/* We use char because int might match the return type of a gcc2
503d2be0
AS
16438 builtin and then its argument prototype would still apply. */
16439char $ac_func ();
503d2be0
AS
16440/* The GNU C library defines this for functions which it implements
16441 to always fail with ENOSYS. Some functions are actually named
16442 something starting with __ and the normal name is an alias. */
16443#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16444choke me
16445#else
19650fd6
AS
16446char (*f) () = $ac_func;
16447#endif
16448#ifdef __cplusplus
16449}
503d2be0 16450#endif
4c343001 16451
19650fd6
AS
16452int
16453main ()
16454{
16455return f != $ac_func;
503d2be0
AS
16456 ;
16457 return 0;
16458}
16459_ACEOF
16460rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16461if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16462 (eval $ac_link) 2>conftest.er1
503d2be0 16463 ac_status=$?
35996d22
AS
16464 grep -v '^ *+' conftest.er1 >conftest.err
16465 rm -f conftest.er1
16466 cat conftest.err >&5
c0d27fcc 16467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16468 (exit $ac_status); } &&
35996d22
AS
16469 { ac_try='test -z "$ac_c_werror_flag"
16470 || test ! -s conftest.err'
16471 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16472 (eval $ac_try) 2>&5
16473 ac_status=$?
16474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16475 (exit $ac_status); }; } &&
16476 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16478 (eval $ac_try) 2>&5
16479 ac_status=$?
c0d27fcc 16480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16481 (exit $ac_status); }; }; then
16482 eval "$as_ac_var=yes"
16483else
16484 echo "$as_me: failed program was:" >&5
19650fd6
AS
16485sed 's/^/| /' conftest.$ac_ext >&5
16486
503d2be0
AS
16487eval "$as_ac_var=no"
16488fi
35996d22
AS
16489rm -f conftest.err conftest.$ac_objext \
16490 conftest$ac_exeext conftest.$ac_ext
503d2be0 16491fi
c0d27fcc 16492echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16493echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16494if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16495 cat >>confdefs.h <<_ACEOF
503d2be0 16496#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16497_ACEOF
4c343001
DL
16498
16499fi
503d2be0
AS
16500done
16501
c0d27fcc 16502
b936fae4 16503# PTY-related GNU extensions.
4c343001 16504
b936fae4
AS
16505for ac_func in getpt
16506do
16507as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16508echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
16509echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16510if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 16511 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16512else
b936fae4 16513 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16514/* confdefs.h. */
16515_ACEOF
16516cat confdefs.h >>conftest.$ac_ext
16517cat >>conftest.$ac_ext <<_ACEOF
16518/* end confdefs.h. */
35996d22
AS
16519/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16520 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16521#define $ac_func innocuous_$ac_func
16522
087121cc 16523/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16524 which can conflict with char $ac_func (); below.
16525 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16526 <limits.h> exists even on freestanding compilers. */
35996d22 16527
19650fd6
AS
16528#ifdef __STDC__
16529# include <limits.h>
16530#else
16531# include <assert.h>
16532#endif
35996d22
AS
16533
16534#undef $ac_func
16535
087121cc 16536/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16537#ifdef __cplusplus
16538extern "C"
19650fd6 16539{
503d2be0 16540#endif
087121cc 16541/* We use char because int might match the return type of a gcc2
503d2be0
AS
16542 builtin and then its argument prototype would still apply. */
16543char $ac_func ();
087121cc
GM
16544/* The GNU C library defines this for functions which it implements
16545 to always fail with ENOSYS. Some functions are actually named
16546 something starting with __ and the normal name is an alias. */
16547#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16548choke me
16549#else
19650fd6
AS
16550char (*f) () = $ac_func;
16551#endif
16552#ifdef __cplusplus
16553}
087121cc
GM
16554#endif
16555
19650fd6
AS
16556int
16557main ()
16558{
16559return f != $ac_func;
503d2be0
AS
16560 ;
16561 return 0;
16562}
16563_ACEOF
16564rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16565if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16566 (eval $ac_link) 2>conftest.er1
503d2be0 16567 ac_status=$?
35996d22
AS
16568 grep -v '^ *+' conftest.er1 >conftest.err
16569 rm -f conftest.er1
16570 cat conftest.err >&5
c0d27fcc 16571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16572 (exit $ac_status); } &&
35996d22
AS
16573 { ac_try='test -z "$ac_c_werror_flag"
16574 || test ! -s conftest.err'
16575 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16576 (eval $ac_try) 2>&5
16577 ac_status=$?
16578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16579 (exit $ac_status); }; } &&
16580 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16581 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16582 (eval $ac_try) 2>&5
16583 ac_status=$?
c0d27fcc 16584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16585 (exit $ac_status); }; }; then
16586 eval "$as_ac_var=yes"
16587else
16588 echo "$as_me: failed program was:" >&5
19650fd6
AS
16589sed 's/^/| /' conftest.$ac_ext >&5
16590
503d2be0
AS
16591eval "$as_ac_var=no"
16592fi
35996d22
AS
16593rm -f conftest.err conftest.$ac_objext \
16594 conftest$ac_exeext conftest.$ac_ext
503d2be0 16595fi
c0d27fcc 16596echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16597echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16598if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16599 cat >>confdefs.h <<_ACEOF
503d2be0 16600#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16601_ACEOF
087121cc 16602
087121cc
GM
16603fi
16604done
16605
c0d27fcc 16606
ba4481b5
DL
16607# Check this now, so that we will NOT find the above functions in ncurses.
16608# That is because we have not set up to link ncurses in lib-src.
16609# It's better to believe a function is not available
16610# than to expect to find it in ncurses.
503d2be0 16611
c0d27fcc 16612echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
16613echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
16614if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
16615 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16616else
503d2be0 16617 ac_check_lib_save_LIBS=$LIBS
ba4481b5 16618LIBS="-lncurses $LIBS"
503d2be0 16619cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16620/* confdefs.h. */
16621_ACEOF
16622cat confdefs.h >>conftest.$ac_ext
16623cat >>conftest.$ac_ext <<_ACEOF
16624/* end confdefs.h. */
503d2be0 16625
ba4481b5 16626/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16627#ifdef __cplusplus
16628extern "C"
16629#endif
ba4481b5 16630/* We use char because int might match the return type of a gcc2
503d2be0
AS
16631 builtin and then its argument prototype would still apply. */
16632char tparm ();
16633int
16634main ()
16635{
16636tparm ();
16637 ;
16638 return 0;
16639}
16640_ACEOF
16641rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16642if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16643 (eval $ac_link) 2>conftest.er1
503d2be0 16644 ac_status=$?
35996d22
AS
16645 grep -v '^ *+' conftest.er1 >conftest.err
16646 rm -f conftest.er1
16647 cat conftest.err >&5
c0d27fcc 16648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16649 (exit $ac_status); } &&
35996d22
AS
16650 { ac_try='test -z "$ac_c_werror_flag"
16651 || test ! -s conftest.err'
16652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16653 (eval $ac_try) 2>&5
16654 ac_status=$?
16655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16656 (exit $ac_status); }; } &&
16657 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16658 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16659 (eval $ac_try) 2>&5
16660 ac_status=$?
c0d27fcc 16661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16662 (exit $ac_status); }; }; then
16663 ac_cv_lib_ncurses_tparm=yes
16664else
16665 echo "$as_me: failed program was:" >&5
19650fd6
AS
16666sed 's/^/| /' conftest.$ac_ext >&5
16667
503d2be0
AS
16668ac_cv_lib_ncurses_tparm=no
16669fi
35996d22
AS
16670rm -f conftest.err conftest.$ac_objext \
16671 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16672LIBS=$ac_check_lib_save_LIBS
16673fi
c0d27fcc 16674echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
16675echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
16676if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 16677 cat >>confdefs.h <<_ACEOF
503d2be0 16678#define HAVE_LIBNCURSES 1
c0d27fcc 16679_ACEOF
ba4481b5
DL
16680
16681 LIBS="-lncurses $LIBS"
16682
ba4481b5
DL
16683fi
16684
c0d27fcc 16685
84e70f78
KR
16686# Do we need the Hesiod library to provide the support routines?
16687if test "$with_hesiod" = yes ; then
16688 # Don't set $LIBS here -- see comments above.
16689 resolv=no
c0d27fcc 16690 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
16691echo $ECHO_N "checking for res_send... $ECHO_C" >&6
16692if test "${ac_cv_func_res_send+set}" = set; then
16693 echo $ECHO_N "(cached) $ECHO_C" >&6
16694else
16695 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16696/* confdefs.h. */
16697_ACEOF
16698cat confdefs.h >>conftest.$ac_ext
16699cat >>conftest.$ac_ext <<_ACEOF
16700/* end confdefs.h. */
35996d22
AS
16701/* Define res_send to an innocuous variant, in case <limits.h> declares res_send.
16702 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16703#define res_send innocuous_res_send
16704
84e70f78 16705/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16706 which can conflict with char res_send (); below.
16707 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16708 <limits.h> exists even on freestanding compilers. */
35996d22 16709
19650fd6
AS
16710#ifdef __STDC__
16711# include <limits.h>
16712#else
16713# include <assert.h>
16714#endif
35996d22
AS
16715
16716#undef res_send
16717
84e70f78
KR
16718/* Override any gcc2 internal prototype to avoid an error. */
16719#ifdef __cplusplus
16720extern "C"
19650fd6 16721{
84e70f78
KR
16722#endif
16723/* We use char because int might match the return type of a gcc2
16724 builtin and then its argument prototype would still apply. */
16725char res_send ();
84e70f78
KR
16726/* The GNU C library defines this for functions which it implements
16727 to always fail with ENOSYS. Some functions are actually named
16728 something starting with __ and the normal name is an alias. */
16729#if defined (__stub_res_send) || defined (__stub___res_send)
16730choke me
16731#else
19650fd6
AS
16732char (*f) () = res_send;
16733#endif
16734#ifdef __cplusplus
16735}
cd958eb3
MB
16736#endif
16737
19650fd6
AS
16738int
16739main ()
16740{
16741return f != res_send;
84e70f78
KR
16742 ;
16743 return 0;
16744}
16745_ACEOF
16746rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16747if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16748 (eval $ac_link) 2>conftest.er1
84e70f78 16749 ac_status=$?
35996d22
AS
16750 grep -v '^ *+' conftest.er1 >conftest.err
16751 rm -f conftest.er1
16752 cat conftest.err >&5
c0d27fcc 16753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16754 (exit $ac_status); } &&
35996d22
AS
16755 { ac_try='test -z "$ac_c_werror_flag"
16756 || test ! -s conftest.err'
16757 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16758 (eval $ac_try) 2>&5
16759 ac_status=$?
16760 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16761 (exit $ac_status); }; } &&
16762 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16763 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16764 (eval $ac_try) 2>&5
16765 ac_status=$?
c0d27fcc 16766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16767 (exit $ac_status); }; }; then
16768 ac_cv_func_res_send=yes
16769else
16770 echo "$as_me: failed program was:" >&5
19650fd6
AS
16771sed 's/^/| /' conftest.$ac_ext >&5
16772
84e70f78
KR
16773ac_cv_func_res_send=no
16774fi
35996d22
AS
16775rm -f conftest.err conftest.$ac_objext \
16776 conftest$ac_exeext conftest.$ac_ext
84e70f78 16777fi
c0d27fcc 16778echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
16779echo "${ECHO_T}$ac_cv_func_res_send" >&6
16780if test $ac_cv_func_res_send = yes; then
16781 :
16782else
c0d27fcc 16783 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
16784echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
16785if test "${ac_cv_func___res_send+set}" = set; then
16786 echo $ECHO_N "(cached) $ECHO_C" >&6
16787else
16788 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16789/* confdefs.h. */
16790_ACEOF
16791cat confdefs.h >>conftest.$ac_ext
16792cat >>conftest.$ac_ext <<_ACEOF
16793/* end confdefs.h. */
35996d22
AS
16794/* Define __res_send to an innocuous variant, in case <limits.h> declares __res_send.
16795 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16796#define __res_send innocuous___res_send
16797
84e70f78 16798/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16799 which can conflict with char __res_send (); below.
16800 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16801 <limits.h> exists even on freestanding compilers. */
35996d22 16802
19650fd6
AS
16803#ifdef __STDC__
16804# include <limits.h>
16805#else
16806# include <assert.h>
16807#endif
35996d22
AS
16808
16809#undef __res_send
16810
84e70f78
KR
16811/* Override any gcc2 internal prototype to avoid an error. */
16812#ifdef __cplusplus
16813extern "C"
19650fd6 16814{
84e70f78
KR
16815#endif
16816/* We use char because int might match the return type of a gcc2
16817 builtin and then its argument prototype would still apply. */
16818char __res_send ();
84e70f78
KR
16819/* The GNU C library defines this for functions which it implements
16820 to always fail with ENOSYS. Some functions are actually named
16821 something starting with __ and the normal name is an alias. */
16822#if defined (__stub___res_send) || defined (__stub_____res_send)
16823choke me
16824#else
19650fd6
AS
16825char (*f) () = __res_send;
16826#endif
16827#ifdef __cplusplus
16828}
84e70f78
KR
16829#endif
16830
19650fd6
AS
16831int
16832main ()
16833{
16834return f != __res_send;
84e70f78
KR
16835 ;
16836 return 0;
16837}
16838_ACEOF
16839rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16840if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16841 (eval $ac_link) 2>conftest.er1
84e70f78 16842 ac_status=$?
35996d22
AS
16843 grep -v '^ *+' conftest.er1 >conftest.err
16844 rm -f conftest.er1
16845 cat conftest.err >&5
c0d27fcc 16846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16847 (exit $ac_status); } &&
35996d22
AS
16848 { ac_try='test -z "$ac_c_werror_flag"
16849 || test ! -s conftest.err'
16850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16851 (eval $ac_try) 2>&5
16852 ac_status=$?
16853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16854 (exit $ac_status); }; } &&
16855 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16856 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16857 (eval $ac_try) 2>&5
16858 ac_status=$?
c0d27fcc 16859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16860 (exit $ac_status); }; }; then
16861 ac_cv_func___res_send=yes
16862else
16863 echo "$as_me: failed program was:" >&5
19650fd6
AS
16864sed 's/^/| /' conftest.$ac_ext >&5
16865
84e70f78
KR
16866ac_cv_func___res_send=no
16867fi
35996d22
AS
16868rm -f conftest.err conftest.$ac_objext \
16869 conftest$ac_exeext conftest.$ac_ext
84e70f78 16870fi
c0d27fcc 16871echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
16872echo "${ECHO_T}$ac_cv_func___res_send" >&6
16873if test $ac_cv_func___res_send = yes; then
16874 :
16875else
c0d27fcc 16876 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
16877echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
16878if test "${ac_cv_lib_resolv_res_send+set}" = set; then
16879 echo $ECHO_N "(cached) $ECHO_C" >&6
16880else
16881 ac_check_lib_save_LIBS=$LIBS
16882LIBS="-lresolv $LIBS"
16883cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16884/* confdefs.h. */
16885_ACEOF
16886cat confdefs.h >>conftest.$ac_ext
16887cat >>conftest.$ac_ext <<_ACEOF
16888/* end confdefs.h. */
84e70f78
KR
16889
16890/* Override any gcc2 internal prototype to avoid an error. */
16891#ifdef __cplusplus
16892extern "C"
16893#endif
16894/* We use char because int might match the return type of a gcc2
16895 builtin and then its argument prototype would still apply. */
16896char res_send ();
16897int
16898main ()
16899{
16900res_send ();
16901 ;
16902 return 0;
16903}
16904_ACEOF
16905rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16906if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16907 (eval $ac_link) 2>conftest.er1
84e70f78 16908 ac_status=$?
35996d22
AS
16909 grep -v '^ *+' conftest.er1 >conftest.err
16910 rm -f conftest.er1
16911 cat conftest.err >&5
c0d27fcc 16912 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16913 (exit $ac_status); } &&
35996d22
AS
16914 { ac_try='test -z "$ac_c_werror_flag"
16915 || test ! -s conftest.err'
16916 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16917 (eval $ac_try) 2>&5
16918 ac_status=$?
16919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16920 (exit $ac_status); }; } &&
16921 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16923 (eval $ac_try) 2>&5
16924 ac_status=$?
c0d27fcc 16925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16926 (exit $ac_status); }; }; then
16927 ac_cv_lib_resolv_res_send=yes
16928else
16929 echo "$as_me: failed program was:" >&5
19650fd6
AS
16930sed 's/^/| /' conftest.$ac_ext >&5
16931
84e70f78
KR
16932ac_cv_lib_resolv_res_send=no
16933fi
35996d22
AS
16934rm -f conftest.err conftest.$ac_objext \
16935 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16936LIBS=$ac_check_lib_save_LIBS
16937fi
c0d27fcc 16938echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
16939echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
16940if test $ac_cv_lib_resolv_res_send = yes; then
16941 resolv=yes
16942else
c0d27fcc 16943 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
16944echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
16945if test "${ac_cv_lib_resolv___res_send+set}" = set; then
16946 echo $ECHO_N "(cached) $ECHO_C" >&6
16947else
16948 ac_check_lib_save_LIBS=$LIBS
16949LIBS="-lresolv $LIBS"
16950cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16951/* confdefs.h. */
16952_ACEOF
16953cat confdefs.h >>conftest.$ac_ext
16954cat >>conftest.$ac_ext <<_ACEOF
16955/* end confdefs.h. */
84e70f78
KR
16956
16957/* Override any gcc2 internal prototype to avoid an error. */
16958#ifdef __cplusplus
16959extern "C"
16960#endif
16961/* We use char because int might match the return type of a gcc2
16962 builtin and then its argument prototype would still apply. */
16963char __res_send ();
16964int
16965main ()
16966{
16967__res_send ();
16968 ;
16969 return 0;
16970}
16971_ACEOF
16972rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16973if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16974 (eval $ac_link) 2>conftest.er1
84e70f78 16975 ac_status=$?
35996d22
AS
16976 grep -v '^ *+' conftest.er1 >conftest.err
16977 rm -f conftest.er1
16978 cat conftest.err >&5
c0d27fcc 16979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16980 (exit $ac_status); } &&
35996d22
AS
16981 { ac_try='test -z "$ac_c_werror_flag"
16982 || test ! -s conftest.err'
16983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16984 (eval $ac_try) 2>&5
16985 ac_status=$?
16986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16987 (exit $ac_status); }; } &&
16988 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16990 (eval $ac_try) 2>&5
16991 ac_status=$?
c0d27fcc 16992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16993 (exit $ac_status); }; }; then
16994 ac_cv_lib_resolv___res_send=yes
16995else
16996 echo "$as_me: failed program was:" >&5
19650fd6
AS
16997sed 's/^/| /' conftest.$ac_ext >&5
16998
84e70f78
KR
16999ac_cv_lib_resolv___res_send=no
17000fi
35996d22
AS
17001rm -f conftest.err conftest.$ac_objext \
17002 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17003LIBS=$ac_check_lib_save_LIBS
17004fi
c0d27fcc 17005echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
17006echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
17007if test $ac_cv_lib_resolv___res_send = yes; then
17008 resolv=yes
17009fi
17010
17011fi
17012
17013fi
17014
17015fi
17016
17017 if test "$resolv" = yes ; then
17018 RESOLVLIB=-lresolv
b936fae4 17019
c0d27fcc 17020cat >>confdefs.h <<\_ACEOF
84e70f78 17021#define HAVE_LIBRESOLV 1
c0d27fcc 17022_ACEOF
84e70f78
KR
17023
17024 else
17025 RESOLVLIB=
17026 fi
c0d27fcc 17027 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
17028echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
17029if test "${ac_cv_func_hes_getmailhost+set}" = set; then
17030 echo $ECHO_N "(cached) $ECHO_C" >&6
17031else
17032 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17033/* confdefs.h. */
17034_ACEOF
17035cat confdefs.h >>conftest.$ac_ext
17036cat >>conftest.$ac_ext <<_ACEOF
17037/* end confdefs.h. */
35996d22
AS
17038/* Define hes_getmailhost to an innocuous variant, in case <limits.h> declares hes_getmailhost.
17039 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17040#define hes_getmailhost innocuous_hes_getmailhost
17041
84e70f78 17042/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
17043 which can conflict with char hes_getmailhost (); below.
17044 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17045 <limits.h> exists even on freestanding compilers. */
35996d22 17046
19650fd6
AS
17047#ifdef __STDC__
17048# include <limits.h>
17049#else
17050# include <assert.h>
17051#endif
35996d22
AS
17052
17053#undef hes_getmailhost
17054
84e70f78
KR
17055/* Override any gcc2 internal prototype to avoid an error. */
17056#ifdef __cplusplus
17057extern "C"
19650fd6 17058{
84e70f78
KR
17059#endif
17060/* We use char because int might match the return type of a gcc2
17061 builtin and then its argument prototype would still apply. */
17062char hes_getmailhost ();
84e70f78
KR
17063/* The GNU C library defines this for functions which it implements
17064 to always fail with ENOSYS. Some functions are actually named
17065 something starting with __ and the normal name is an alias. */
17066#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
17067choke me
17068#else
19650fd6
AS
17069char (*f) () = hes_getmailhost;
17070#endif
17071#ifdef __cplusplus
17072}
cd958eb3
MB
17073#endif
17074
19650fd6
AS
17075int
17076main ()
17077{
17078return f != hes_getmailhost;
84e70f78
KR
17079 ;
17080 return 0;
17081}
17082_ACEOF
17083rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17084if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17085 (eval $ac_link) 2>conftest.er1
84e70f78 17086 ac_status=$?
35996d22
AS
17087 grep -v '^ *+' conftest.er1 >conftest.err
17088 rm -f conftest.er1
17089 cat conftest.err >&5
c0d27fcc 17090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17091 (exit $ac_status); } &&
35996d22
AS
17092 { ac_try='test -z "$ac_c_werror_flag"
17093 || test ! -s conftest.err'
17094 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17095 (eval $ac_try) 2>&5
17096 ac_status=$?
17097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17098 (exit $ac_status); }; } &&
17099 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17100 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17101 (eval $ac_try) 2>&5
17102 ac_status=$?
c0d27fcc 17103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17104 (exit $ac_status); }; }; then
17105 ac_cv_func_hes_getmailhost=yes
17106else
17107 echo "$as_me: failed program was:" >&5
19650fd6
AS
17108sed 's/^/| /' conftest.$ac_ext >&5
17109
84e70f78
KR
17110ac_cv_func_hes_getmailhost=no
17111fi
35996d22
AS
17112rm -f conftest.err conftest.$ac_objext \
17113 conftest$ac_exeext conftest.$ac_ext
84e70f78 17114fi
c0d27fcc 17115echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
17116echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
17117if test $ac_cv_func_hes_getmailhost = yes; then
17118 :
17119else
c0d27fcc 17120 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
17121echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
17122if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
17123 echo $ECHO_N "(cached) $ECHO_C" >&6
17124else
17125 ac_check_lib_save_LIBS=$LIBS
17126LIBS="-lhesiod $RESOLVLIB $LIBS"
17127cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17128/* confdefs.h. */
17129_ACEOF
17130cat confdefs.h >>conftest.$ac_ext
17131cat >>conftest.$ac_ext <<_ACEOF
17132/* end confdefs.h. */
84e70f78
KR
17133
17134/* Override any gcc2 internal prototype to avoid an error. */
17135#ifdef __cplusplus
17136extern "C"
17137#endif
17138/* We use char because int might match the return type of a gcc2
17139 builtin and then its argument prototype would still apply. */
17140char hes_getmailhost ();
17141int
17142main ()
17143{
17144hes_getmailhost ();
17145 ;
17146 return 0;
17147}
17148_ACEOF
17149rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17150if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17151 (eval $ac_link) 2>conftest.er1
84e70f78 17152 ac_status=$?
35996d22
AS
17153 grep -v '^ *+' conftest.er1 >conftest.err
17154 rm -f conftest.er1
17155 cat conftest.err >&5
c0d27fcc 17156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17157 (exit $ac_status); } &&
35996d22
AS
17158 { ac_try='test -z "$ac_c_werror_flag"
17159 || test ! -s conftest.err'
17160 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17161 (eval $ac_try) 2>&5
17162 ac_status=$?
17163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17164 (exit $ac_status); }; } &&
17165 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17166 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17167 (eval $ac_try) 2>&5
17168 ac_status=$?
c0d27fcc 17169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17170 (exit $ac_status); }; }; then
17171 ac_cv_lib_hesiod_hes_getmailhost=yes
17172else
17173 echo "$as_me: failed program was:" >&5
19650fd6
AS
17174sed 's/^/| /' conftest.$ac_ext >&5
17175
84e70f78
KR
17176ac_cv_lib_hesiod_hes_getmailhost=no
17177fi
35996d22
AS
17178rm -f conftest.err conftest.$ac_objext \
17179 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17180LIBS=$ac_check_lib_save_LIBS
17181fi
c0d27fcc 17182echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
17183echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
17184if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 17185
c0d27fcc 17186cat >>confdefs.h <<\_ACEOF
84e70f78 17187#define HAVE_LIBHESIOD 1
c0d27fcc 17188_ACEOF
84e70f78
KR
17189
17190else
17191 :
17192fi
17193
17194fi
17195
17196fi
17197
a21616bd
KR
17198# These tell us which Kerberos-related libraries to use.
17199if test "${with_kerberos+set}" = set; then
503d2be0 17200
c0d27fcc 17201echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
17202echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
17203if test "${ac_cv_lib_com_err_com_err+set}" = set; then
17204 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17205else
503d2be0 17206 ac_check_lib_save_LIBS=$LIBS
a21616bd 17207LIBS="-lcom_err $LIBS"
503d2be0 17208cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17209/* confdefs.h. */
17210_ACEOF
17211cat confdefs.h >>conftest.$ac_ext
17212cat >>conftest.$ac_ext <<_ACEOF
17213/* end confdefs.h. */
503d2be0 17214
a21616bd 17215/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17216#ifdef __cplusplus
17217extern "C"
17218#endif
a21616bd 17219/* We use char because int might match the return type of a gcc2
503d2be0
AS
17220 builtin and then its argument prototype would still apply. */
17221char com_err ();
17222int
17223main ()
17224{
17225com_err ();
17226 ;
17227 return 0;
17228}
17229_ACEOF
17230rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17231if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17232 (eval $ac_link) 2>conftest.er1
503d2be0 17233 ac_status=$?
35996d22
AS
17234 grep -v '^ *+' conftest.er1 >conftest.err
17235 rm -f conftest.er1
17236 cat conftest.err >&5
c0d27fcc 17237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17238 (exit $ac_status); } &&
35996d22
AS
17239 { ac_try='test -z "$ac_c_werror_flag"
17240 || test ! -s conftest.err'
17241 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17242 (eval $ac_try) 2>&5
17243 ac_status=$?
17244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17245 (exit $ac_status); }; } &&
17246 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17247 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17248 (eval $ac_try) 2>&5
17249 ac_status=$?
c0d27fcc 17250 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17251 (exit $ac_status); }; }; then
17252 ac_cv_lib_com_err_com_err=yes
17253else
17254 echo "$as_me: failed program was:" >&5
19650fd6
AS
17255sed 's/^/| /' conftest.$ac_ext >&5
17256
503d2be0
AS
17257ac_cv_lib_com_err_com_err=no
17258fi
35996d22
AS
17259rm -f conftest.err conftest.$ac_objext \
17260 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17261LIBS=$ac_check_lib_save_LIBS
17262fi
c0d27fcc 17263echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
17264echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
17265if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 17266 cat >>confdefs.h <<_ACEOF
503d2be0 17267#define HAVE_LIBCOM_ERR 1
c0d27fcc 17268_ACEOF
a21616bd
KR
17269
17270 LIBS="-lcom_err $LIBS"
17271
a21616bd
KR
17272fi
17273
c0d27fcc
MR
17274
17275echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
17276echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
17277if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
17278 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17279else
503d2be0 17280 ac_check_lib_save_LIBS=$LIBS
a21616bd 17281LIBS="-lk5crypto $LIBS"
503d2be0 17282cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17283/* confdefs.h. */
17284_ACEOF
17285cat confdefs.h >>conftest.$ac_ext
17286cat >>conftest.$ac_ext <<_ACEOF
17287/* end confdefs.h. */
503d2be0 17288
a21616bd 17289/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17290#ifdef __cplusplus
17291extern "C"
17292#endif
a21616bd 17293/* We use char because int might match the return type of a gcc2
503d2be0
AS
17294 builtin and then its argument prototype would still apply. */
17295char mit_des_cbc_encrypt ();
17296int
17297main ()
17298{
17299mit_des_cbc_encrypt ();
17300 ;
17301 return 0;
17302}
17303_ACEOF
17304rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17305if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17306 (eval $ac_link) 2>conftest.er1
503d2be0 17307 ac_status=$?
35996d22
AS
17308 grep -v '^ *+' conftest.er1 >conftest.err
17309 rm -f conftest.er1
17310 cat conftest.err >&5
c0d27fcc 17311 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17312 (exit $ac_status); } &&
35996d22
AS
17313 { ac_try='test -z "$ac_c_werror_flag"
17314 || test ! -s conftest.err'
17315 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17316 (eval $ac_try) 2>&5
17317 ac_status=$?
17318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17319 (exit $ac_status); }; } &&
17320 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17321 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17322 (eval $ac_try) 2>&5
17323 ac_status=$?
c0d27fcc 17324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17325 (exit $ac_status); }; }; then
17326 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
17327else
17328 echo "$as_me: failed program was:" >&5
19650fd6
AS
17329sed 's/^/| /' conftest.$ac_ext >&5
17330
503d2be0
AS
17331ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
17332fi
35996d22
AS
17333rm -f conftest.err conftest.$ac_objext \
17334 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17335LIBS=$ac_check_lib_save_LIBS
17336fi
c0d27fcc 17337echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17338echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
17339if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17340 cat >>confdefs.h <<_ACEOF
503d2be0 17341#define HAVE_LIBK5CRYPTO 1
c0d27fcc 17342_ACEOF
a21616bd
KR
17343
17344 LIBS="-lk5crypto $LIBS"
17345
a21616bd
KR
17346fi
17347
c0d27fcc
MR
17348
17349echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
17350echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
17351if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
17352 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17353else
503d2be0 17354 ac_check_lib_save_LIBS=$LIBS
a21616bd 17355LIBS="-lcrypto $LIBS"
503d2be0 17356cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17357/* confdefs.h. */
17358_ACEOF
17359cat confdefs.h >>conftest.$ac_ext
17360cat >>conftest.$ac_ext <<_ACEOF
17361/* end confdefs.h. */
503d2be0 17362
a21616bd 17363/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17364#ifdef __cplusplus
17365extern "C"
17366#endif
a21616bd 17367/* We use char because int might match the return type of a gcc2
503d2be0
AS
17368 builtin and then its argument prototype would still apply. */
17369char mit_des_cbc_encrypt ();
17370int
17371main ()
17372{
17373mit_des_cbc_encrypt ();
17374 ;
17375 return 0;
17376}
17377_ACEOF
17378rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17379if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17380 (eval $ac_link) 2>conftest.er1
503d2be0 17381 ac_status=$?
35996d22
AS
17382 grep -v '^ *+' conftest.er1 >conftest.err
17383 rm -f conftest.er1
17384 cat conftest.err >&5
c0d27fcc 17385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17386 (exit $ac_status); } &&
35996d22
AS
17387 { ac_try='test -z "$ac_c_werror_flag"
17388 || test ! -s conftest.err'
17389 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17390 (eval $ac_try) 2>&5
17391 ac_status=$?
17392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17393 (exit $ac_status); }; } &&
17394 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17395 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17396 (eval $ac_try) 2>&5
17397 ac_status=$?
c0d27fcc 17398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17399 (exit $ac_status); }; }; then
17400 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
17401else
17402 echo "$as_me: failed program was:" >&5
19650fd6
AS
17403sed 's/^/| /' conftest.$ac_ext >&5
17404
503d2be0
AS
17405ac_cv_lib_crypto_mit_des_cbc_encrypt=no
17406fi
35996d22
AS
17407rm -f conftest.err conftest.$ac_objext \
17408 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17409LIBS=$ac_check_lib_save_LIBS
17410fi
c0d27fcc 17411echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17412echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
17413if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17414 cat >>confdefs.h <<_ACEOF
503d2be0 17415#define HAVE_LIBCRYPTO 1
c0d27fcc 17416_ACEOF
a21616bd
KR
17417
17418 LIBS="-lcrypto $LIBS"
17419
a21616bd
KR
17420fi
17421
c0d27fcc
MR
17422
17423echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
17424echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
17425if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
17426 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17427else
503d2be0 17428 ac_check_lib_save_LIBS=$LIBS
a21616bd 17429LIBS="-lkrb5 $LIBS"
503d2be0 17430cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17431/* confdefs.h. */
17432_ACEOF
17433cat confdefs.h >>conftest.$ac_ext
17434cat >>conftest.$ac_ext <<_ACEOF
17435/* end confdefs.h. */
a21616bd 17436
503d2be0
AS
17437/* Override any gcc2 internal prototype to avoid an error. */
17438#ifdef __cplusplus
17439extern "C"
17440#endif
17441/* We use char because int might match the return type of a gcc2
17442 builtin and then its argument prototype would still apply. */
17443char krb5_init_context ();
17444int
17445main ()
17446{
17447krb5_init_context ();
17448 ;
17449 return 0;
17450}
17451_ACEOF
17452rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17453if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17454 (eval $ac_link) 2>conftest.er1
503d2be0 17455 ac_status=$?
35996d22
AS
17456 grep -v '^ *+' conftest.er1 >conftest.err
17457 rm -f conftest.er1
17458 cat conftest.err >&5
c0d27fcc 17459 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17460 (exit $ac_status); } &&
35996d22
AS
17461 { ac_try='test -z "$ac_c_werror_flag"
17462 || test ! -s conftest.err'
17463 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17464 (eval $ac_try) 2>&5
17465 ac_status=$?
17466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17467 (exit $ac_status); }; } &&
17468 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17469 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17470 (eval $ac_try) 2>&5
17471 ac_status=$?
c0d27fcc 17472 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17473 (exit $ac_status); }; }; then
17474 ac_cv_lib_krb5_krb5_init_context=yes
17475else
17476 echo "$as_me: failed program was:" >&5
19650fd6
AS
17477sed 's/^/| /' conftest.$ac_ext >&5
17478
503d2be0
AS
17479ac_cv_lib_krb5_krb5_init_context=no
17480fi
35996d22
AS
17481rm -f conftest.err conftest.$ac_objext \
17482 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17483LIBS=$ac_check_lib_save_LIBS
17484fi
c0d27fcc 17485echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
17486echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
17487if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 17488 cat >>confdefs.h <<_ACEOF
503d2be0 17489#define HAVE_LIBKRB5 1
c0d27fcc 17490_ACEOF
a21616bd
KR
17491
17492 LIBS="-lkrb5 $LIBS"
17493
a21616bd
KR
17494fi
17495
17496 if test "${with_kerberos5+set}" != set; then
503d2be0 17497
c0d27fcc 17498echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
17499echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
17500if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
17501 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17502else
503d2be0 17503 ac_check_lib_save_LIBS=$LIBS
a21616bd 17504LIBS="-ldes425 $LIBS"
503d2be0 17505cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17506/* confdefs.h. */
17507_ACEOF
17508cat confdefs.h >>conftest.$ac_ext
17509cat >>conftest.$ac_ext <<_ACEOF
17510/* end confdefs.h. */
503d2be0 17511
a21616bd 17512/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17513#ifdef __cplusplus
17514extern "C"
17515#endif
a21616bd 17516/* We use char because int might match the return type of a gcc2
503d2be0
AS
17517 builtin and then its argument prototype would still apply. */
17518char des_cbc_encrypt ();
17519int
17520main ()
17521{
17522des_cbc_encrypt ();
17523 ;
17524 return 0;
17525}
17526_ACEOF
17527rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17528if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17529 (eval $ac_link) 2>conftest.er1
503d2be0 17530 ac_status=$?
35996d22
AS
17531 grep -v '^ *+' conftest.er1 >conftest.err
17532 rm -f conftest.er1
17533 cat conftest.err >&5
c0d27fcc 17534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17535 (exit $ac_status); } &&
35996d22
AS
17536 { ac_try='test -z "$ac_c_werror_flag"
17537 || test ! -s conftest.err'
17538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17539 (eval $ac_try) 2>&5
17540 ac_status=$?
17541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17542 (exit $ac_status); }; } &&
17543 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17545 (eval $ac_try) 2>&5
17546 ac_status=$?
c0d27fcc 17547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17548 (exit $ac_status); }; }; then
17549 ac_cv_lib_des425_des_cbc_encrypt=yes
17550else
17551 echo "$as_me: failed program was:" >&5
19650fd6
AS
17552sed 's/^/| /' conftest.$ac_ext >&5
17553
503d2be0
AS
17554ac_cv_lib_des425_des_cbc_encrypt=no
17555fi
35996d22
AS
17556rm -f conftest.err conftest.$ac_objext \
17557 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17558LIBS=$ac_check_lib_save_LIBS
17559fi
c0d27fcc 17560echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
17561echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
17562if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 17563 cat >>confdefs.h <<_ACEOF
503d2be0 17564#define HAVE_LIBDES425 1
c0d27fcc 17565_ACEOF
a21616bd
KR
17566
17567 LIBS="-ldes425 $LIBS"
17568
17569else
503d2be0 17570
c0d27fcc 17571echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
17572echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
17573if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
17574 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17575else
503d2be0 17576 ac_check_lib_save_LIBS=$LIBS
a21616bd 17577LIBS="-ldes $LIBS"
503d2be0 17578cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17579/* confdefs.h. */
17580_ACEOF
17581cat confdefs.h >>conftest.$ac_ext
17582cat >>conftest.$ac_ext <<_ACEOF
17583/* end confdefs.h. */
503d2be0 17584
a21616bd 17585/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17586#ifdef __cplusplus
17587extern "C"
17588#endif
a21616bd 17589/* We use char because int might match the return type of a gcc2
503d2be0
AS
17590 builtin and then its argument prototype would still apply. */
17591char des_cbc_encrypt ();
17592int
17593main ()
17594{
17595des_cbc_encrypt ();
17596 ;
17597 return 0;
17598}
17599_ACEOF
17600rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17601if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17602 (eval $ac_link) 2>conftest.er1
503d2be0 17603 ac_status=$?
35996d22
AS
17604 grep -v '^ *+' conftest.er1 >conftest.err
17605 rm -f conftest.er1
17606 cat conftest.err >&5
c0d27fcc 17607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17608 (exit $ac_status); } &&
35996d22
AS
17609 { ac_try='test -z "$ac_c_werror_flag"
17610 || test ! -s conftest.err'
17611 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17612 (eval $ac_try) 2>&5
17613 ac_status=$?
17614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17615 (exit $ac_status); }; } &&
17616 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17617 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17618 (eval $ac_try) 2>&5
17619 ac_status=$?
c0d27fcc 17620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17621 (exit $ac_status); }; }; then
17622 ac_cv_lib_des_des_cbc_encrypt=yes
17623else
17624 echo "$as_me: failed program was:" >&5
19650fd6
AS
17625sed 's/^/| /' conftest.$ac_ext >&5
17626
503d2be0
AS
17627ac_cv_lib_des_des_cbc_encrypt=no
17628fi
35996d22
AS
17629rm -f conftest.err conftest.$ac_objext \
17630 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17631LIBS=$ac_check_lib_save_LIBS
17632fi
c0d27fcc 17633echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
17634echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
17635if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 17636 cat >>confdefs.h <<_ACEOF
503d2be0 17637#define HAVE_LIBDES 1
c0d27fcc 17638_ACEOF
a21616bd
KR
17639
17640 LIBS="-ldes $LIBS"
17641
a21616bd
KR
17642fi
17643
17644fi
17645
c0d27fcc
MR
17646
17647echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
17648echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
17649if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
17650 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17651else
503d2be0 17652 ac_check_lib_save_LIBS=$LIBS
a21616bd 17653LIBS="-lkrb4 $LIBS"
503d2be0 17654cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17655/* confdefs.h. */
17656_ACEOF
17657cat confdefs.h >>conftest.$ac_ext
17658cat >>conftest.$ac_ext <<_ACEOF
17659/* end confdefs.h. */
503d2be0 17660
a21616bd 17661/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17662#ifdef __cplusplus
17663extern "C"
17664#endif
a21616bd 17665/* We use char because int might match the return type of a gcc2
503d2be0
AS
17666 builtin and then its argument prototype would still apply. */
17667char krb_get_cred ();
17668int
17669main ()
17670{
17671krb_get_cred ();
17672 ;
17673 return 0;
17674}
17675_ACEOF
17676rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17677if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17678 (eval $ac_link) 2>conftest.er1
503d2be0 17679 ac_status=$?
35996d22
AS
17680 grep -v '^ *+' conftest.er1 >conftest.err
17681 rm -f conftest.er1
17682 cat conftest.err >&5
c0d27fcc 17683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17684 (exit $ac_status); } &&
35996d22
AS
17685 { ac_try='test -z "$ac_c_werror_flag"
17686 || test ! -s conftest.err'
17687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17688 (eval $ac_try) 2>&5
17689 ac_status=$?
17690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17691 (exit $ac_status); }; } &&
17692 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17694 (eval $ac_try) 2>&5
17695 ac_status=$?
c0d27fcc 17696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17697 (exit $ac_status); }; }; then
17698 ac_cv_lib_krb4_krb_get_cred=yes
17699else
17700 echo "$as_me: failed program was:" >&5
19650fd6
AS
17701sed 's/^/| /' conftest.$ac_ext >&5
17702
503d2be0
AS
17703ac_cv_lib_krb4_krb_get_cred=no
17704fi
35996d22
AS
17705rm -f conftest.err conftest.$ac_objext \
17706 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17707LIBS=$ac_check_lib_save_LIBS
17708fi
c0d27fcc 17709echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
17710echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
17711if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 17712 cat >>confdefs.h <<_ACEOF
503d2be0 17713#define HAVE_LIBKRB4 1
c0d27fcc 17714_ACEOF
a21616bd
KR
17715
17716 LIBS="-lkrb4 $LIBS"
17717
17718else
503d2be0 17719
c0d27fcc 17720echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
17721echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
17722if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
17723 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17724else
503d2be0 17725 ac_check_lib_save_LIBS=$LIBS
a21616bd 17726LIBS="-lkrb $LIBS"
503d2be0 17727cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17728/* confdefs.h. */
17729_ACEOF
17730cat confdefs.h >>conftest.$ac_ext
17731cat >>conftest.$ac_ext <<_ACEOF
17732/* end confdefs.h. */
503d2be0 17733
a21616bd 17734/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17735#ifdef __cplusplus
17736extern "C"
17737#endif
a21616bd 17738/* We use char because int might match the return type of a gcc2
503d2be0
AS
17739 builtin and then its argument prototype would still apply. */
17740char krb_get_cred ();
17741int
17742main ()
17743{
17744krb_get_cred ();
17745 ;
17746 return 0;
17747}
17748_ACEOF
17749rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17750if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17751 (eval $ac_link) 2>conftest.er1
503d2be0 17752 ac_status=$?
35996d22
AS
17753 grep -v '^ *+' conftest.er1 >conftest.err
17754 rm -f conftest.er1
17755 cat conftest.err >&5
c0d27fcc 17756 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17757 (exit $ac_status); } &&
35996d22
AS
17758 { ac_try='test -z "$ac_c_werror_flag"
17759 || test ! -s conftest.err'
17760 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17761 (eval $ac_try) 2>&5
17762 ac_status=$?
17763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17764 (exit $ac_status); }; } &&
17765 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17766 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17767 (eval $ac_try) 2>&5
17768 ac_status=$?
c0d27fcc 17769 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17770 (exit $ac_status); }; }; then
17771 ac_cv_lib_krb_krb_get_cred=yes
17772else
17773 echo "$as_me: failed program was:" >&5
19650fd6
AS
17774sed 's/^/| /' conftest.$ac_ext >&5
17775
503d2be0
AS
17776ac_cv_lib_krb_krb_get_cred=no
17777fi
35996d22
AS
17778rm -f conftest.err conftest.$ac_objext \
17779 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17780LIBS=$ac_check_lib_save_LIBS
17781fi
c0d27fcc 17782echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
17783echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
17784if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 17785 cat >>confdefs.h <<_ACEOF
503d2be0 17786#define HAVE_LIBKRB 1
c0d27fcc 17787_ACEOF
a21616bd
KR
17788
17789 LIBS="-lkrb $LIBS"
17790
a21616bd
KR
17791fi
17792
17793fi
17794
17795 fi
17796
17797 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
17798
17799for ac_header in krb5.h
a21616bd 17800do
503d2be0 17801as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17802if eval "test \"\${$as_ac_Header+set}\" = set"; then
17803 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17804echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17805if eval "test \"\${$as_ac_Header+set}\" = set"; then
17806 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17807fi
17808echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17809echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17810else
c0d27fcc
MR
17811 # Is the header compilable?
17812echo "$as_me:$LINENO: checking $ac_header usability" >&5
17813echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17814cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17815/* confdefs.h. */
17816_ACEOF
17817cat confdefs.h >>conftest.$ac_ext
17818cat >>conftest.$ac_ext <<_ACEOF
17819/* end confdefs.h. */
c0d27fcc
MR
17820$ac_includes_default
17821#include <$ac_header>
17822_ACEOF
17823rm -f conftest.$ac_objext
17824if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 17825 (eval $ac_compile) 2>conftest.er1
c0d27fcc 17826 ac_status=$?
35996d22
AS
17827 grep -v '^ *+' conftest.er1 >conftest.err
17828 rm -f conftest.er1
17829 cat conftest.err >&5
c0d27fcc
MR
17830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17831 (exit $ac_status); } &&
35996d22
AS
17832 { ac_try='test -z "$ac_c_werror_flag"
17833 || test ! -s conftest.err'
17834 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17835 (eval $ac_try) 2>&5
17836 ac_status=$?
17837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17838 (exit $ac_status); }; } &&
17839 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17841 (eval $ac_try) 2>&5
17842 ac_status=$?
17843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17844 (exit $ac_status); }; }; then
17845 ac_header_compiler=yes
17846else
17847 echo "$as_me: failed program was:" >&5
19650fd6
AS
17848sed 's/^/| /' conftest.$ac_ext >&5
17849
c0d27fcc
MR
17850ac_header_compiler=no
17851fi
35996d22 17852rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17853echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17854echo "${ECHO_T}$ac_header_compiler" >&6
17855
17856# Is the header present?
17857echo "$as_me:$LINENO: checking $ac_header presence" >&5
17858echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17859cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17860/* confdefs.h. */
17861_ACEOF
17862cat confdefs.h >>conftest.$ac_ext
17863cat >>conftest.$ac_ext <<_ACEOF
17864/* end confdefs.h. */
503d2be0
AS
17865#include <$ac_header>
17866_ACEOF
c0d27fcc 17867if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17868 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17869 ac_status=$?
6bae0ccf 17870 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17871 rm -f conftest.er1
17872 cat conftest.err >&5
c0d27fcc 17873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17874 (exit $ac_status); } >/dev/null; then
17875 if test -s conftest.err; then
17876 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 17877 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
17878 else
17879 ac_cpp_err=
17880 fi
17881else
17882 ac_cpp_err=yes
17883fi
17884if test -z "$ac_cpp_err"; then
c0d27fcc 17885 ac_header_preproc=yes
503d2be0
AS
17886else
17887 echo "$as_me: failed program was:" >&5
19650fd6
AS
17888sed 's/^/| /' conftest.$ac_ext >&5
17889
c0d27fcc 17890 ac_header_preproc=no
a21616bd 17891fi
503d2be0 17892rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17893echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17894echo "${ECHO_T}$ac_header_preproc" >&6
17895
17896# So? What about this header?
35996d22
AS
17897case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17898 yes:no: )
c0d27fcc
MR
17899 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17900echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
17901 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17902echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17903 ac_header_preproc=yes
19650fd6 17904 ;;
35996d22 17905 no:yes:* )
c0d27fcc
MR
17906 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17907echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
17908 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17909echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17910 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17911echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17912 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
17913echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 17914 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17915echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
17916 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17917echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
17918 (
17919 cat <<\_ASBOX
35996d22
AS
17920## ------------------------------------------ ##
17921## Report this to the AC_PACKAGE_NAME lists. ##
17922## ------------------------------------------ ##
19650fd6
AS
17923_ASBOX
17924 ) |
17925 sed "s/^/$as_me: WARNING: /" >&2
17926 ;;
c0d27fcc
MR
17927esac
17928echo "$as_me:$LINENO: checking for $ac_header" >&5
17929echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17930if eval "test \"\${$as_ac_Header+set}\" = set"; then
17931 echo $ECHO_N "(cached) $ECHO_C" >&6
17932else
35996d22 17933 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 17934fi
c0d27fcc 17935echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17936echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17937
17938fi
503d2be0 17939if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17940 cat >>confdefs.h <<_ACEOF
503d2be0 17941#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17942_ACEOF
503d2be0 17943
a21616bd 17944fi
c0d27fcc 17945
a21616bd
KR
17946done
17947
17948 else
503d2be0
AS
17949
17950for ac_header in des.h
a21616bd 17951do
503d2be0 17952as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17953if eval "test \"\${$as_ac_Header+set}\" = set"; then
17954 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17955echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17956if eval "test \"\${$as_ac_Header+set}\" = set"; then
17957 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17958fi
17959echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17960echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17961else
c0d27fcc
MR
17962 # Is the header compilable?
17963echo "$as_me:$LINENO: checking $ac_header usability" >&5
17964echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17965cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17966/* confdefs.h. */
17967_ACEOF
17968cat confdefs.h >>conftest.$ac_ext
17969cat >>conftest.$ac_ext <<_ACEOF
17970/* end confdefs.h. */
c0d27fcc
MR
17971$ac_includes_default
17972#include <$ac_header>
17973_ACEOF
17974rm -f conftest.$ac_objext
17975if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 17976 (eval $ac_compile) 2>conftest.er1
c0d27fcc 17977 ac_status=$?
35996d22
AS
17978 grep -v '^ *+' conftest.er1 >conftest.err
17979 rm -f conftest.er1
17980 cat conftest.err >&5
c0d27fcc
MR
17981 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17982 (exit $ac_status); } &&
35996d22
AS
17983 { ac_try='test -z "$ac_c_werror_flag"
17984 || test ! -s conftest.err'
17985 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17986 (eval $ac_try) 2>&5
17987 ac_status=$?
17988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17989 (exit $ac_status); }; } &&
17990 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17991 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17992 (eval $ac_try) 2>&5
17993 ac_status=$?
17994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17995 (exit $ac_status); }; }; then
17996 ac_header_compiler=yes
17997else
17998 echo "$as_me: failed program was:" >&5
19650fd6
AS
17999sed 's/^/| /' conftest.$ac_ext >&5
18000
c0d27fcc
MR
18001ac_header_compiler=no
18002fi
35996d22 18003rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18004echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18005echo "${ECHO_T}$ac_header_compiler" >&6
18006
18007# Is the header present?
18008echo "$as_me:$LINENO: checking $ac_header presence" >&5
18009echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18010cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18011/* confdefs.h. */
18012_ACEOF
18013cat confdefs.h >>conftest.$ac_ext
18014cat >>conftest.$ac_ext <<_ACEOF
18015/* end confdefs.h. */
503d2be0
AS
18016#include <$ac_header>
18017_ACEOF
c0d27fcc 18018if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18019 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18020 ac_status=$?
6bae0ccf 18021 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18022 rm -f conftest.er1
18023 cat conftest.err >&5
c0d27fcc 18024 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18025 (exit $ac_status); } >/dev/null; then
18026 if test -s conftest.err; then
18027 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18028 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18029 else
18030 ac_cpp_err=
18031 fi
18032else
18033 ac_cpp_err=yes
18034fi
18035if test -z "$ac_cpp_err"; then
c0d27fcc 18036 ac_header_preproc=yes
503d2be0
AS
18037else
18038 echo "$as_me: failed program was:" >&5
19650fd6
AS
18039sed 's/^/| /' conftest.$ac_ext >&5
18040
c0d27fcc 18041 ac_header_preproc=no
a21616bd 18042fi
503d2be0 18043rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18044echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18045echo "${ECHO_T}$ac_header_preproc" >&6
18046
18047# So? What about this header?
35996d22
AS
18048case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18049 yes:no: )
c0d27fcc
MR
18050 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18051echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18052 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18053echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18054 ac_header_preproc=yes
19650fd6 18055 ;;
35996d22 18056 no:yes:* )
c0d27fcc
MR
18057 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18058echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18059 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18060echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18061 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18062echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18063 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18064echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18065 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18066echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18067 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18068echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18069 (
18070 cat <<\_ASBOX
35996d22
AS
18071## ------------------------------------------ ##
18072## Report this to the AC_PACKAGE_NAME lists. ##
18073## ------------------------------------------ ##
19650fd6
AS
18074_ASBOX
18075 ) |
18076 sed "s/^/$as_me: WARNING: /" >&2
18077 ;;
c0d27fcc
MR
18078esac
18079echo "$as_me:$LINENO: checking for $ac_header" >&5
18080echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18081if eval "test \"\${$as_ac_Header+set}\" = set"; then
18082 echo $ECHO_N "(cached) $ECHO_C" >&6
18083else
35996d22 18084 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18085fi
c0d27fcc 18086echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18087echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18088
18089fi
503d2be0 18090if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18091 cat >>confdefs.h <<_ACEOF
503d2be0 18092#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18093_ACEOF
503d2be0 18094
a21616bd 18095else
503d2be0
AS
18096
18097for ac_header in kerberosIV/des.h
a21616bd 18098do
503d2be0 18099as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18100if eval "test \"\${$as_ac_Header+set}\" = set"; then
18101 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18102echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18103if eval "test \"\${$as_ac_Header+set}\" = set"; then
18104 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18105fi
18106echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18107echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18108else
c0d27fcc
MR
18109 # Is the header compilable?
18110echo "$as_me:$LINENO: checking $ac_header usability" >&5
18111echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18112cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18113/* confdefs.h. */
18114_ACEOF
18115cat confdefs.h >>conftest.$ac_ext
18116cat >>conftest.$ac_ext <<_ACEOF
18117/* end confdefs.h. */
c0d27fcc
MR
18118$ac_includes_default
18119#include <$ac_header>
18120_ACEOF
18121rm -f conftest.$ac_objext
18122if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18123 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18124 ac_status=$?
35996d22
AS
18125 grep -v '^ *+' conftest.er1 >conftest.err
18126 rm -f conftest.er1
18127 cat conftest.err >&5
c0d27fcc
MR
18128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18129 (exit $ac_status); } &&
35996d22
AS
18130 { ac_try='test -z "$ac_c_werror_flag"
18131 || test ! -s conftest.err'
18132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18133 (eval $ac_try) 2>&5
18134 ac_status=$?
18135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18136 (exit $ac_status); }; } &&
18137 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18138 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18139 (eval $ac_try) 2>&5
18140 ac_status=$?
18141 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18142 (exit $ac_status); }; }; then
18143 ac_header_compiler=yes
18144else
18145 echo "$as_me: failed program was:" >&5
19650fd6
AS
18146sed 's/^/| /' conftest.$ac_ext >&5
18147
c0d27fcc
MR
18148ac_header_compiler=no
18149fi
35996d22 18150rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18151echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18152echo "${ECHO_T}$ac_header_compiler" >&6
18153
18154# Is the header present?
18155echo "$as_me:$LINENO: checking $ac_header presence" >&5
18156echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18157cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18158/* confdefs.h. */
18159_ACEOF
18160cat confdefs.h >>conftest.$ac_ext
18161cat >>conftest.$ac_ext <<_ACEOF
18162/* end confdefs.h. */
503d2be0
AS
18163#include <$ac_header>
18164_ACEOF
c0d27fcc 18165if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18166 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18167 ac_status=$?
6bae0ccf 18168 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18169 rm -f conftest.er1
18170 cat conftest.err >&5
c0d27fcc 18171 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18172 (exit $ac_status); } >/dev/null; then
18173 if test -s conftest.err; then
18174 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18175 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18176 else
18177 ac_cpp_err=
18178 fi
18179else
18180 ac_cpp_err=yes
18181fi
18182if test -z "$ac_cpp_err"; then
c0d27fcc 18183 ac_header_preproc=yes
503d2be0
AS
18184else
18185 echo "$as_me: failed program was:" >&5
19650fd6
AS
18186sed 's/^/| /' conftest.$ac_ext >&5
18187
c0d27fcc 18188 ac_header_preproc=no
a21616bd 18189fi
503d2be0 18190rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18191echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18192echo "${ECHO_T}$ac_header_preproc" >&6
18193
18194# So? What about this header?
35996d22
AS
18195case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18196 yes:no: )
c0d27fcc
MR
18197 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18198echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18199 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18200echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18201 ac_header_preproc=yes
19650fd6 18202 ;;
35996d22 18203 no:yes:* )
c0d27fcc
MR
18204 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18205echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18206 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18207echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18208 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18209echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18210 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18211echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18212 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18213echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18214 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18215echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18216 (
18217 cat <<\_ASBOX
35996d22
AS
18218## ------------------------------------------ ##
18219## Report this to the AC_PACKAGE_NAME lists. ##
18220## ------------------------------------------ ##
19650fd6
AS
18221_ASBOX
18222 ) |
18223 sed "s/^/$as_me: WARNING: /" >&2
18224 ;;
c0d27fcc
MR
18225esac
18226echo "$as_me:$LINENO: checking for $ac_header" >&5
18227echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18228if eval "test \"\${$as_ac_Header+set}\" = set"; then
18229 echo $ECHO_N "(cached) $ECHO_C" >&6
18230else
35996d22 18231 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18232fi
c0d27fcc 18233echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18234echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18235
18236fi
503d2be0 18237if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18238 cat >>confdefs.h <<_ACEOF
503d2be0 18239#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18240_ACEOF
503d2be0 18241
a21616bd 18242else
503d2be0
AS
18243
18244for ac_header in kerberos/des.h
a21616bd 18245do
503d2be0 18246as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18247if eval "test \"\${$as_ac_Header+set}\" = set"; then
18248 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18249echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18250if eval "test \"\${$as_ac_Header+set}\" = set"; then
18251 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18252fi
18253echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18254echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18255else
c0d27fcc
MR
18256 # Is the header compilable?
18257echo "$as_me:$LINENO: checking $ac_header usability" >&5
18258echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18259cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18260/* confdefs.h. */
18261_ACEOF
18262cat confdefs.h >>conftest.$ac_ext
18263cat >>conftest.$ac_ext <<_ACEOF
18264/* end confdefs.h. */
c0d27fcc
MR
18265$ac_includes_default
18266#include <$ac_header>
18267_ACEOF
18268rm -f conftest.$ac_objext
18269if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18270 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18271 ac_status=$?
35996d22
AS
18272 grep -v '^ *+' conftest.er1 >conftest.err
18273 rm -f conftest.er1
18274 cat conftest.err >&5
c0d27fcc
MR
18275 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18276 (exit $ac_status); } &&
35996d22
AS
18277 { ac_try='test -z "$ac_c_werror_flag"
18278 || test ! -s conftest.err'
18279 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18280 (eval $ac_try) 2>&5
18281 ac_status=$?
18282 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18283 (exit $ac_status); }; } &&
18284 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18285 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18286 (eval $ac_try) 2>&5
18287 ac_status=$?
18288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18289 (exit $ac_status); }; }; then
18290 ac_header_compiler=yes
18291else
18292 echo "$as_me: failed program was:" >&5
19650fd6
AS
18293sed 's/^/| /' conftest.$ac_ext >&5
18294
c0d27fcc
MR
18295ac_header_compiler=no
18296fi
35996d22 18297rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18298echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18299echo "${ECHO_T}$ac_header_compiler" >&6
18300
18301# Is the header present?
18302echo "$as_me:$LINENO: checking $ac_header presence" >&5
18303echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18304cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18305/* confdefs.h. */
18306_ACEOF
18307cat confdefs.h >>conftest.$ac_ext
18308cat >>conftest.$ac_ext <<_ACEOF
18309/* end confdefs.h. */
503d2be0
AS
18310#include <$ac_header>
18311_ACEOF
c0d27fcc 18312if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18313 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18314 ac_status=$?
6bae0ccf 18315 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18316 rm -f conftest.er1
18317 cat conftest.err >&5
c0d27fcc 18318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18319 (exit $ac_status); } >/dev/null; then
18320 if test -s conftest.err; then
18321 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18322 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18323 else
18324 ac_cpp_err=
18325 fi
18326else
18327 ac_cpp_err=yes
18328fi
18329if test -z "$ac_cpp_err"; then
c0d27fcc 18330 ac_header_preproc=yes
503d2be0
AS
18331else
18332 echo "$as_me: failed program was:" >&5
19650fd6
AS
18333sed 's/^/| /' conftest.$ac_ext >&5
18334
c0d27fcc 18335 ac_header_preproc=no
a21616bd 18336fi
503d2be0 18337rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18338echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18339echo "${ECHO_T}$ac_header_preproc" >&6
18340
18341# So? What about this header?
35996d22
AS
18342case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18343 yes:no: )
c0d27fcc
MR
18344 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18345echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18346 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18347echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18348 ac_header_preproc=yes
19650fd6 18349 ;;
35996d22 18350 no:yes:* )
c0d27fcc
MR
18351 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18352echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18353 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18354echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18355 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18356echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18357 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18358echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18359 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18360echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18361 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18362echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18363 (
18364 cat <<\_ASBOX
35996d22
AS
18365## ------------------------------------------ ##
18366## Report this to the AC_PACKAGE_NAME lists. ##
18367## ------------------------------------------ ##
19650fd6
AS
18368_ASBOX
18369 ) |
18370 sed "s/^/$as_me: WARNING: /" >&2
18371 ;;
c0d27fcc
MR
18372esac
18373echo "$as_me:$LINENO: checking for $ac_header" >&5
18374echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18375if eval "test \"\${$as_ac_Header+set}\" = set"; then
18376 echo $ECHO_N "(cached) $ECHO_C" >&6
18377else
35996d22 18378 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18379fi
c0d27fcc 18380echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18381echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18382
18383fi
503d2be0 18384if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18385 cat >>confdefs.h <<_ACEOF
503d2be0 18386#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18387_ACEOF
a21616bd
KR
18388
18389fi
c0d27fcc 18390
a21616bd
KR
18391done
18392
98418dba 18393fi
c0d27fcc 18394
925c2f3f
EZ
18395done
18396
98418dba 18397fi
c0d27fcc 18398
925c2f3f 18399done
98418dba 18400
c0d27fcc 18401
925c2f3f
EZ
18402for ac_header in krb.h
18403do
18404as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18405if eval "test \"\${$as_ac_Header+set}\" = set"; then
18406 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
18407echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18408if eval "test \"\${$as_ac_Header+set}\" = set"; then
18409 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18410fi
18411echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18412echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18413else
18414 # Is the header compilable?
18415echo "$as_me:$LINENO: checking $ac_header usability" >&5
18416echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18417cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18418/* confdefs.h. */
18419_ACEOF
18420cat confdefs.h >>conftest.$ac_ext
18421cat >>conftest.$ac_ext <<_ACEOF
18422/* end confdefs.h. */
c0d27fcc
MR
18423$ac_includes_default
18424#include <$ac_header>
18425_ACEOF
18426rm -f conftest.$ac_objext
18427if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18428 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18429 ac_status=$?
35996d22
AS
18430 grep -v '^ *+' conftest.er1 >conftest.err
18431 rm -f conftest.er1
18432 cat conftest.err >&5
c0d27fcc
MR
18433 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18434 (exit $ac_status); } &&
35996d22
AS
18435 { ac_try='test -z "$ac_c_werror_flag"
18436 || test ! -s conftest.err'
18437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18438 (eval $ac_try) 2>&5
18439 ac_status=$?
18440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18441 (exit $ac_status); }; } &&
18442 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18443 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18444 (eval $ac_try) 2>&5
18445 ac_status=$?
18446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18447 (exit $ac_status); }; }; then
18448 ac_header_compiler=yes
925c2f3f 18449else
c0d27fcc 18450 echo "$as_me: failed program was:" >&5
19650fd6
AS
18451sed 's/^/| /' conftest.$ac_ext >&5
18452
c0d27fcc
MR
18453ac_header_compiler=no
18454fi
35996d22 18455rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18456echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18457echo "${ECHO_T}$ac_header_compiler" >&6
18458
18459# Is the header present?
18460echo "$as_me:$LINENO: checking $ac_header presence" >&5
18461echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18462cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18463/* confdefs.h. */
18464_ACEOF
18465cat confdefs.h >>conftest.$ac_ext
18466cat >>conftest.$ac_ext <<_ACEOF
18467/* end confdefs.h. */
503d2be0
AS
18468#include <$ac_header>
18469_ACEOF
c0d27fcc 18470if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18471 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18472 ac_status=$?
6bae0ccf 18473 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18474 rm -f conftest.er1
18475 cat conftest.err >&5
c0d27fcc 18476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18477 (exit $ac_status); } >/dev/null; then
18478 if test -s conftest.err; then
18479 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18480 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18481 else
18482 ac_cpp_err=
18483 fi
18484else
18485 ac_cpp_err=yes
18486fi
18487if test -z "$ac_cpp_err"; then
c0d27fcc 18488 ac_header_preproc=yes
503d2be0
AS
18489else
18490 echo "$as_me: failed program was:" >&5
19650fd6
AS
18491sed 's/^/| /' conftest.$ac_ext >&5
18492
c0d27fcc 18493 ac_header_preproc=no
a21616bd 18494fi
503d2be0 18495rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18496echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18497echo "${ECHO_T}$ac_header_preproc" >&6
18498
18499# So? What about this header?
35996d22
AS
18500case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18501 yes:no: )
c0d27fcc
MR
18502 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18503echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18504 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18505echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18506 ac_header_preproc=yes
19650fd6 18507 ;;
35996d22 18508 no:yes:* )
c0d27fcc
MR
18509 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18510echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18511 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18512echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18513 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18514echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18515 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18516echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18517 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18518echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18519 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18520echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18521 (
18522 cat <<\_ASBOX
35996d22
AS
18523## ------------------------------------------ ##
18524## Report this to the AC_PACKAGE_NAME lists. ##
18525## ------------------------------------------ ##
19650fd6
AS
18526_ASBOX
18527 ) |
18528 sed "s/^/$as_me: WARNING: /" >&2
18529 ;;
c0d27fcc
MR
18530esac
18531echo "$as_me:$LINENO: checking for $ac_header" >&5
18532echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18533if eval "test \"\${$as_ac_Header+set}\" = set"; then
18534 echo $ECHO_N "(cached) $ECHO_C" >&6
18535else
35996d22 18536 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18537fi
c0d27fcc 18538echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18539echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18540
18541fi
503d2be0 18542if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18543 cat >>confdefs.h <<_ACEOF
503d2be0 18544#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18545_ACEOF
503d2be0 18546
a21616bd 18547else
503d2be0
AS
18548
18549for ac_header in kerberosIV/krb.h
a21616bd 18550do
503d2be0 18551as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18552if eval "test \"\${$as_ac_Header+set}\" = set"; then
18553 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18554echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18555if eval "test \"\${$as_ac_Header+set}\" = set"; then
18556 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18557fi
18558echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18559echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18560else
c0d27fcc
MR
18561 # Is the header compilable?
18562echo "$as_me:$LINENO: checking $ac_header usability" >&5
18563echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18564cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18565/* confdefs.h. */
18566_ACEOF
18567cat confdefs.h >>conftest.$ac_ext
18568cat >>conftest.$ac_ext <<_ACEOF
18569/* end confdefs.h. */
c0d27fcc
MR
18570$ac_includes_default
18571#include <$ac_header>
18572_ACEOF
18573rm -f conftest.$ac_objext
18574if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18575 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18576 ac_status=$?
35996d22
AS
18577 grep -v '^ *+' conftest.er1 >conftest.err
18578 rm -f conftest.er1
18579 cat conftest.err >&5
c0d27fcc
MR
18580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18581 (exit $ac_status); } &&
35996d22
AS
18582 { ac_try='test -z "$ac_c_werror_flag"
18583 || test ! -s conftest.err'
18584 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18585 (eval $ac_try) 2>&5
18586 ac_status=$?
18587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18588 (exit $ac_status); }; } &&
18589 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18590 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18591 (eval $ac_try) 2>&5
18592 ac_status=$?
18593 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18594 (exit $ac_status); }; }; then
18595 ac_header_compiler=yes
18596else
18597 echo "$as_me: failed program was:" >&5
19650fd6
AS
18598sed 's/^/| /' conftest.$ac_ext >&5
18599
c0d27fcc
MR
18600ac_header_compiler=no
18601fi
35996d22 18602rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18603echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18604echo "${ECHO_T}$ac_header_compiler" >&6
18605
18606# Is the header present?
18607echo "$as_me:$LINENO: checking $ac_header presence" >&5
18608echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18609cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18610/* confdefs.h. */
18611_ACEOF
18612cat confdefs.h >>conftest.$ac_ext
18613cat >>conftest.$ac_ext <<_ACEOF
18614/* end confdefs.h. */
503d2be0
AS
18615#include <$ac_header>
18616_ACEOF
c0d27fcc 18617if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18618 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18619 ac_status=$?
6bae0ccf 18620 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18621 rm -f conftest.er1
18622 cat conftest.err >&5
c0d27fcc 18623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18624 (exit $ac_status); } >/dev/null; then
18625 if test -s conftest.err; then
18626 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18627 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18628 else
18629 ac_cpp_err=
18630 fi
18631else
18632 ac_cpp_err=yes
18633fi
18634if test -z "$ac_cpp_err"; then
c0d27fcc 18635 ac_header_preproc=yes
503d2be0
AS
18636else
18637 echo "$as_me: failed program was:" >&5
19650fd6
AS
18638sed 's/^/| /' conftest.$ac_ext >&5
18639
c0d27fcc 18640 ac_header_preproc=no
a21616bd 18641fi
503d2be0 18642rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18643echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18644echo "${ECHO_T}$ac_header_preproc" >&6
18645
18646# So? What about this header?
35996d22
AS
18647case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18648 yes:no: )
c0d27fcc
MR
18649 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18650echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18651 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18652echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18653 ac_header_preproc=yes
19650fd6 18654 ;;
35996d22 18655 no:yes:* )
c0d27fcc
MR
18656 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18657echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18658 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18659echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18660 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18661echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18662 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18663echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18664 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18665echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18666 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18667echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18668 (
18669 cat <<\_ASBOX
35996d22
AS
18670## ------------------------------------------ ##
18671## Report this to the AC_PACKAGE_NAME lists. ##
18672## ------------------------------------------ ##
19650fd6
AS
18673_ASBOX
18674 ) |
18675 sed "s/^/$as_me: WARNING: /" >&2
18676 ;;
c0d27fcc
MR
18677esac
18678echo "$as_me:$LINENO: checking for $ac_header" >&5
18679echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18680if eval "test \"\${$as_ac_Header+set}\" = set"; then
18681 echo $ECHO_N "(cached) $ECHO_C" >&6
18682else
35996d22 18683 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18684fi
c0d27fcc 18685echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18686echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18687
18688fi
503d2be0 18689if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18690 cat >>confdefs.h <<_ACEOF
503d2be0 18691#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18692_ACEOF
503d2be0 18693
a21616bd 18694else
503d2be0
AS
18695
18696for ac_header in kerberos/krb.h
a21616bd 18697do
503d2be0 18698as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18699if eval "test \"\${$as_ac_Header+set}\" = set"; then
18700 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18701echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18702if eval "test \"\${$as_ac_Header+set}\" = set"; then
18703 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18704fi
18705echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18706echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18707else
c0d27fcc
MR
18708 # Is the header compilable?
18709echo "$as_me:$LINENO: checking $ac_header usability" >&5
18710echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18711cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18712/* confdefs.h. */
18713_ACEOF
18714cat confdefs.h >>conftest.$ac_ext
18715cat >>conftest.$ac_ext <<_ACEOF
18716/* end confdefs.h. */
c0d27fcc
MR
18717$ac_includes_default
18718#include <$ac_header>
18719_ACEOF
18720rm -f conftest.$ac_objext
18721if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18722 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18723 ac_status=$?
35996d22
AS
18724 grep -v '^ *+' conftest.er1 >conftest.err
18725 rm -f conftest.er1
18726 cat conftest.err >&5
c0d27fcc
MR
18727 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18728 (exit $ac_status); } &&
35996d22
AS
18729 { ac_try='test -z "$ac_c_werror_flag"
18730 || test ! -s conftest.err'
18731 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18732 (eval $ac_try) 2>&5
18733 ac_status=$?
18734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18735 (exit $ac_status); }; } &&
18736 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18737 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18738 (eval $ac_try) 2>&5
18739 ac_status=$?
18740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18741 (exit $ac_status); }; }; then
18742 ac_header_compiler=yes
18743else
18744 echo "$as_me: failed program was:" >&5
19650fd6
AS
18745sed 's/^/| /' conftest.$ac_ext >&5
18746
c0d27fcc
MR
18747ac_header_compiler=no
18748fi
35996d22 18749rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18750echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18751echo "${ECHO_T}$ac_header_compiler" >&6
18752
18753# Is the header present?
18754echo "$as_me:$LINENO: checking $ac_header presence" >&5
18755echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18756cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18757/* confdefs.h. */
18758_ACEOF
18759cat confdefs.h >>conftest.$ac_ext
18760cat >>conftest.$ac_ext <<_ACEOF
18761/* end confdefs.h. */
503d2be0
AS
18762#include <$ac_header>
18763_ACEOF
c0d27fcc 18764if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18765 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18766 ac_status=$?
6bae0ccf 18767 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18768 rm -f conftest.er1
18769 cat conftest.err >&5
c0d27fcc 18770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18771 (exit $ac_status); } >/dev/null; then
18772 if test -s conftest.err; then
18773 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18774 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18775 else
18776 ac_cpp_err=
18777 fi
18778else
18779 ac_cpp_err=yes
18780fi
18781if test -z "$ac_cpp_err"; then
c0d27fcc 18782 ac_header_preproc=yes
503d2be0
AS
18783else
18784 echo "$as_me: failed program was:" >&5
19650fd6
AS
18785sed 's/^/| /' conftest.$ac_ext >&5
18786
c0d27fcc 18787 ac_header_preproc=no
a21616bd 18788fi
503d2be0 18789rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18790echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18791echo "${ECHO_T}$ac_header_preproc" >&6
35996d22
AS
18792
18793# So? What about this header?
18794case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18795 yes:no: )
18796 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18797echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18798 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18799echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18800 ac_header_preproc=yes
19650fd6 18801 ;;
35996d22 18802 no:yes:* )
c0d27fcc
MR
18803 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18804echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18805 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18806echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18807 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18808echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18809 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18810echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18811 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18812echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18813 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18814echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18815 (
18816 cat <<\_ASBOX
35996d22
AS
18817## ------------------------------------------ ##
18818## Report this to the AC_PACKAGE_NAME lists. ##
18819## ------------------------------------------ ##
19650fd6
AS
18820_ASBOX
18821 ) |
18822 sed "s/^/$as_me: WARNING: /" >&2
18823 ;;
c0d27fcc
MR
18824esac
18825echo "$as_me:$LINENO: checking for $ac_header" >&5
18826echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18827if eval "test \"\${$as_ac_Header+set}\" = set"; then
18828 echo $ECHO_N "(cached) $ECHO_C" >&6
18829else
35996d22 18830 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18831fi
c0d27fcc 18832echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18833echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18834
18835fi
503d2be0 18836if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18837 cat >>confdefs.h <<_ACEOF
503d2be0 18838#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18839_ACEOF
503d2be0 18840
a21616bd 18841fi
c0d27fcc 18842
a21616bd
KR
18843done
18844
18845fi
c0d27fcc 18846
a21616bd
KR
18847done
18848
18849fi
c0d27fcc 18850
a21616bd
KR
18851done
18852
18853 fi
503d2be0
AS
18854
18855for ac_header in com_err.h
a21616bd 18856do
503d2be0 18857as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18858if eval "test \"\${$as_ac_Header+set}\" = set"; then
18859 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18860echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18861if eval "test \"\${$as_ac_Header+set}\" = set"; then
18862 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18863fi
18864echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18865echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18866else
c0d27fcc
MR
18867 # Is the header compilable?
18868echo "$as_me:$LINENO: checking $ac_header usability" >&5
18869echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18870cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18871/* confdefs.h. */
18872_ACEOF
18873cat confdefs.h >>conftest.$ac_ext
18874cat >>conftest.$ac_ext <<_ACEOF
18875/* end confdefs.h. */
c0d27fcc
MR
18876$ac_includes_default
18877#include <$ac_header>
18878_ACEOF
18879rm -f conftest.$ac_objext
18880if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18881 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18882 ac_status=$?
35996d22
AS
18883 grep -v '^ *+' conftest.er1 >conftest.err
18884 rm -f conftest.er1
18885 cat conftest.err >&5
c0d27fcc
MR
18886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18887 (exit $ac_status); } &&
35996d22
AS
18888 { ac_try='test -z "$ac_c_werror_flag"
18889 || test ! -s conftest.err'
18890 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18891 (eval $ac_try) 2>&5
18892 ac_status=$?
18893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18894 (exit $ac_status); }; } &&
18895 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18897 (eval $ac_try) 2>&5
18898 ac_status=$?
18899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18900 (exit $ac_status); }; }; then
18901 ac_header_compiler=yes
18902else
18903 echo "$as_me: failed program was:" >&5
19650fd6
AS
18904sed 's/^/| /' conftest.$ac_ext >&5
18905
c0d27fcc
MR
18906ac_header_compiler=no
18907fi
35996d22 18908rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18909echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18910echo "${ECHO_T}$ac_header_compiler" >&6
18911
18912# Is the header present?
18913echo "$as_me:$LINENO: checking $ac_header presence" >&5
18914echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18915cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18916/* confdefs.h. */
18917_ACEOF
18918cat confdefs.h >>conftest.$ac_ext
18919cat >>conftest.$ac_ext <<_ACEOF
18920/* end confdefs.h. */
503d2be0
AS
18921#include <$ac_header>
18922_ACEOF
c0d27fcc 18923if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18924 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18925 ac_status=$?
6bae0ccf 18926 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18927 rm -f conftest.er1
18928 cat conftest.err >&5
c0d27fcc 18929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18930 (exit $ac_status); } >/dev/null; then
18931 if test -s conftest.err; then
18932 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18933 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18934 else
18935 ac_cpp_err=
18936 fi
18937else
18938 ac_cpp_err=yes
18939fi
18940if test -z "$ac_cpp_err"; then
c0d27fcc 18941 ac_header_preproc=yes
503d2be0
AS
18942else
18943 echo "$as_me: failed program was:" >&5
19650fd6
AS
18944sed 's/^/| /' conftest.$ac_ext >&5
18945
c0d27fcc 18946 ac_header_preproc=no
a21616bd 18947fi
503d2be0 18948rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18949echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18950echo "${ECHO_T}$ac_header_preproc" >&6
18951
18952# So? What about this header?
35996d22
AS
18953case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18954 yes:no: )
c0d27fcc
MR
18955 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18956echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18957 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18958echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18959 ac_header_preproc=yes
19650fd6 18960 ;;
35996d22 18961 no:yes:* )
c0d27fcc
MR
18962 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18963echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18964 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18965echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18966 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18967echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18968 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18969echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18970 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18971echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18972 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18973echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18974 (
18975 cat <<\_ASBOX
35996d22
AS
18976## ------------------------------------------ ##
18977## Report this to the AC_PACKAGE_NAME lists. ##
18978## ------------------------------------------ ##
19650fd6
AS
18979_ASBOX
18980 ) |
18981 sed "s/^/$as_me: WARNING: /" >&2
18982 ;;
c0d27fcc
MR
18983esac
18984echo "$as_me:$LINENO: checking for $ac_header" >&5
18985echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18986if eval "test \"\${$as_ac_Header+set}\" = set"; then
18987 echo $ECHO_N "(cached) $ECHO_C" >&6
18988else
35996d22 18989 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18990fi
c0d27fcc 18991echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18992echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18993
18994fi
503d2be0 18995if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18996 cat >>confdefs.h <<_ACEOF
503d2be0 18997#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18998_ACEOF
503d2be0 18999
a21616bd 19000fi
c0d27fcc 19001
a21616bd
KR
19002done
19003
19004fi
19005
ba4481b5
DL
19006# Solaris requires -lintl if you want strerror (which calls dgettext)
19007# to return localized messages.
503d2be0 19008
c0d27fcc 19009echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
19010echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
19011if test "${ac_cv_lib_intl_dgettext+set}" = set; then
19012 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19013else
503d2be0 19014 ac_check_lib_save_LIBS=$LIBS
ba4481b5 19015LIBS="-lintl $LIBS"
503d2be0 19016cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19017/* confdefs.h. */
19018_ACEOF
19019cat confdefs.h >>conftest.$ac_ext
19020cat >>conftest.$ac_ext <<_ACEOF
19021/* end confdefs.h. */
503d2be0 19022
ba4481b5 19023/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19024#ifdef __cplusplus
19025extern "C"
19026#endif
ba4481b5 19027/* We use char because int might match the return type of a gcc2
503d2be0
AS
19028 builtin and then its argument prototype would still apply. */
19029char dgettext ();
19030int
19031main ()
19032{
19033dgettext ();
19034 ;
19035 return 0;
19036}
19037_ACEOF
19038rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19039if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19040 (eval $ac_link) 2>conftest.er1
503d2be0 19041 ac_status=$?
35996d22
AS
19042 grep -v '^ *+' conftest.er1 >conftest.err
19043 rm -f conftest.er1
19044 cat conftest.err >&5
c0d27fcc 19045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19046 (exit $ac_status); } &&
35996d22
AS
19047 { ac_try='test -z "$ac_c_werror_flag"
19048 || test ! -s conftest.err'
19049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19050 (eval $ac_try) 2>&5
19051 ac_status=$?
19052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19053 (exit $ac_status); }; } &&
19054 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19055 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19056 (eval $ac_try) 2>&5
19057 ac_status=$?
c0d27fcc 19058 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19059 (exit $ac_status); }; }; then
19060 ac_cv_lib_intl_dgettext=yes
19061else
19062 echo "$as_me: failed program was:" >&5
19650fd6
AS
19063sed 's/^/| /' conftest.$ac_ext >&5
19064
503d2be0
AS
19065ac_cv_lib_intl_dgettext=no
19066fi
35996d22
AS
19067rm -f conftest.err conftest.$ac_objext \
19068 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
19069LIBS=$ac_check_lib_save_LIBS
19070fi
c0d27fcc 19071echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
19072echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
19073if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 19074 cat >>confdefs.h <<_ACEOF
503d2be0 19075#define HAVE_LIBINTL 1
c0d27fcc 19076_ACEOF
ba4481b5
DL
19077
19078 LIBS="-lintl $LIBS"
19079
ba4481b5
DL
19080fi
19081
c0d27fcc
MR
19082
19083echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
19084echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
19085if test "${emacs_cv_localtime_cache+set}" = set; then
19086 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
19087else
19088 if test x$ac_cv_func_tzset = xyes; then
19089if test "$cross_compiling" = yes; then
19090 # If we have tzset, assume the worst when cross-compiling.
19091emacs_cv_localtime_cache=yes
19092else
503d2be0 19093 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19094/* confdefs.h. */
19095_ACEOF
19096cat confdefs.h >>conftest.$ac_ext
19097cat >>conftest.$ac_ext <<_ACEOF
19098/* end confdefs.h. */
ba4481b5 19099#include <time.h>
ba4481b5
DL
19100extern char **environ;
19101unset_TZ ()
19102{
19103 char **from, **to;
19104 for (to = from = environ; (*to = *from); from++)
19105 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
19106 to++;
19107}
19108char TZ_GMT0[] = "TZ=GMT0";
19109char TZ_PST8[] = "TZ=PST8";
19110main()
19111{
19112 time_t now = time ((time_t *) 0);
19113 int hour_GMT0, hour_unset;
19114 if (putenv (TZ_GMT0) != 0)
19115 exit (1);
19116 hour_GMT0 = localtime (&now)->tm_hour;
19117 unset_TZ ();
19118 hour_unset = localtime (&now)->tm_hour;
19119 if (putenv (TZ_PST8) != 0)
19120 exit (1);
19121 if (localtime (&now)->tm_hour == hour_GMT0)
19122 exit (1);
19123 unset_TZ ();
19124 if (localtime (&now)->tm_hour != hour_unset)
19125 exit (1);
19126 exit (0);
19127}
503d2be0
AS
19128_ACEOF
19129rm -f conftest$ac_exeext
c0d27fcc 19130if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19131 (eval $ac_link) 2>&5
19132 ac_status=$?
c0d27fcc 19133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19134 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19136 (eval $ac_try) 2>&5
19137 ac_status=$?
c0d27fcc 19138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19139 (exit $ac_status); }; }; then
ba4481b5
DL
19140 emacs_cv_localtime_cache=no
19141else
503d2be0
AS
19142 echo "$as_me: program exited with status $ac_status" >&5
19143echo "$as_me: failed program was:" >&5
19650fd6
AS
19144sed 's/^/| /' conftest.$ac_ext >&5
19145
c0d27fcc 19146( exit $ac_status )
503d2be0 19147emacs_cv_localtime_cache=yes
ba4481b5 19148fi
35996d22 19149rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 19150fi
ba4481b5
DL
19151else
19152 # If we lack tzset, report that localtime does not cache TZ,
19153 # since we can't invalidate the cache if we don't have tzset.
19154 emacs_cv_localtime_cache=no
19155fi
19156fi
c0d27fcc 19157echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 19158echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 19159if test $emacs_cv_localtime_cache = yes; then
b936fae4 19160
c0d27fcc 19161cat >>confdefs.h <<\_ACEOF
ba4481b5 19162#define LOCALTIME_CACHE 1
c0d27fcc 19163_ACEOF
ba4481b5
DL
19164
19165fi
19166
19167if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
19168
19169for ac_func in gettimeofday
48d4b120 19170do
503d2be0 19171as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 19172echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
19173echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19174if eval "test \"\${$as_ac_var+set}\" = set"; then
19175 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19176else
503d2be0 19177 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19178/* confdefs.h. */
19179_ACEOF
19180cat confdefs.h >>conftest.$ac_ext
19181cat >>conftest.$ac_ext <<_ACEOF
19182/* end confdefs.h. */
35996d22
AS
19183/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19184 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19185#define $ac_func innocuous_$ac_func
19186
48d4b120 19187/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19188 which can conflict with char $ac_func (); below.
19189 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19190 <limits.h> exists even on freestanding compilers. */
35996d22 19191
19650fd6
AS
19192#ifdef __STDC__
19193# include <limits.h>
19194#else
19195# include <assert.h>
19196#endif
35996d22
AS
19197
19198#undef $ac_func
19199
48d4b120 19200/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19201#ifdef __cplusplus
19202extern "C"
19650fd6 19203{
503d2be0 19204#endif
48d4b120 19205/* We use char because int might match the return type of a gcc2
503d2be0
AS
19206 builtin and then its argument prototype would still apply. */
19207char $ac_func ();
48d4b120
DL
19208/* The GNU C library defines this for functions which it implements
19209 to always fail with ENOSYS. Some functions are actually named
19210 something starting with __ and the normal name is an alias. */
19211#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19212choke me
19213#else
19650fd6
AS
19214char (*f) () = $ac_func;
19215#endif
19216#ifdef __cplusplus
19217}
cd958eb3
MB
19218#endif
19219
19650fd6
AS
19220int
19221main ()
19222{
19223return f != $ac_func;
503d2be0
AS
19224 ;
19225 return 0;
19226}
19227_ACEOF
19228rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19229if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19230 (eval $ac_link) 2>conftest.er1
503d2be0 19231 ac_status=$?
35996d22
AS
19232 grep -v '^ *+' conftest.er1 >conftest.err
19233 rm -f conftest.er1
19234 cat conftest.err >&5
c0d27fcc 19235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19236 (exit $ac_status); } &&
35996d22
AS
19237 { ac_try='test -z "$ac_c_werror_flag"
19238 || test ! -s conftest.err'
19239 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19240 (eval $ac_try) 2>&5
19241 ac_status=$?
19242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19243 (exit $ac_status); }; } &&
19244 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19245 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19246 (eval $ac_try) 2>&5
19247 ac_status=$?
c0d27fcc 19248 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19249 (exit $ac_status); }; }; then
19250 eval "$as_ac_var=yes"
19251else
19252 echo "$as_me: failed program was:" >&5
19650fd6
AS
19253sed 's/^/| /' conftest.$ac_ext >&5
19254
503d2be0
AS
19255eval "$as_ac_var=no"
19256fi
35996d22
AS
19257rm -f conftest.err conftest.$ac_objext \
19258 conftest$ac_exeext conftest.$ac_ext
503d2be0 19259fi
c0d27fcc 19260echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
19261echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19262if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 19263 cat >>confdefs.h <<_ACEOF
503d2be0 19264#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 19265_ACEOF
48d4b120 19266
48d4b120
DL
19267fi
19268done
19269
b936fae4 19270 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 19271 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
19272echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
19273if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
19274 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19275else
503d2be0 19276 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19277/* confdefs.h. */
19278_ACEOF
19279cat confdefs.h >>conftest.$ac_ext
19280cat >>conftest.$ac_ext <<_ACEOF
19281/* end confdefs.h. */
ba4481b5 19282
a3f08d9e
DL
19283#ifdef TIME_WITH_SYS_TIME
19284#include <sys/time.h>
19285#include <time.h>
19286#else
19287#ifdef HAVE_SYS_TIME_H
19288#include <sys/time.h>
19289#else
19290#include <time.h>
19291#endif
19292#endif
503d2be0
AS
19293int
19294main ()
19295{
a3f08d9e 19296struct timeval time;
b936fae4 19297 gettimeofday (&time, 0);
503d2be0
AS
19298 ;
19299 return 0;
19300}
19301_ACEOF
19302rm -f conftest.$ac_objext
c0d27fcc 19303if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19304 (eval $ac_compile) 2>conftest.er1
503d2be0 19305 ac_status=$?
35996d22
AS
19306 grep -v '^ *+' conftest.er1 >conftest.err
19307 rm -f conftest.er1
19308 cat conftest.err >&5
c0d27fcc 19309 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19310 (exit $ac_status); } &&
35996d22
AS
19311 { ac_try='test -z "$ac_c_werror_flag"
19312 || test ! -s conftest.err'
19313 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19314 (eval $ac_try) 2>&5
19315 ac_status=$?
19316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19317 (exit $ac_status); }; } &&
19318 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19319 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19320 (eval $ac_try) 2>&5
19321 ac_status=$?
c0d27fcc 19322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19323 (exit $ac_status); }; }; then
ba4481b5
DL
19324 emacs_cv_gettimeofday_two_arguments=yes
19325else
503d2be0 19326 echo "$as_me: failed program was:" >&5
19650fd6
AS
19327sed 's/^/| /' conftest.$ac_ext >&5
19328
503d2be0 19329emacs_cv_gettimeofday_two_arguments=no
ba4481b5 19330fi
35996d22 19331rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 19332fi
c0d27fcc 19333echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 19334echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
19335 if test $emacs_cv_gettimeofday_two_arguments = no; then
19336
c0d27fcc 19337cat >>confdefs.h <<\_ACEOF
ba4481b5 19338#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 19339_ACEOF
ba4481b5 19340
b936fae4 19341 fi
ba4481b5
DL
19342 fi
19343fi
19344
973a76b1
DL
19345# This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
19346echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
19347echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
19348if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
19349 echo $ECHO_N "(cached) $ECHO_C" >&6
19350else
19351 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19352/* confdefs.h. */
19353_ACEOF
19354cat confdefs.h >>conftest.$ac_ext
19355cat >>conftest.$ac_ext <<_ACEOF
19356/* end confdefs.h. */
973a76b1
DL
19357#include <sys/types.h>
19358#include <$ac_cv_struct_tm>
19359
19360
19361int
19362main ()
19363{
19364static struct tm ac_aggr;
19365if (ac_aggr.tm_zone)
19366return 0;
19367 ;
19368 return 0;
19369}
19370_ACEOF
19371rm -f conftest.$ac_objext
19372if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19373 (eval $ac_compile) 2>conftest.er1
973a76b1 19374 ac_status=$?
35996d22
AS
19375 grep -v '^ *+' conftest.er1 >conftest.err
19376 rm -f conftest.er1
19377 cat conftest.err >&5
973a76b1
DL
19378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19379 (exit $ac_status); } &&
35996d22
AS
19380 { ac_try='test -z "$ac_c_werror_flag"
19381 || test ! -s conftest.err'
19382 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19383 (eval $ac_try) 2>&5
19384 ac_status=$?
19385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19386 (exit $ac_status); }; } &&
19387 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19388 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19389 (eval $ac_try) 2>&5
19390 ac_status=$?
19391 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19392 (exit $ac_status); }; }; then
19393 ac_cv_member_struct_tm_tm_zone=yes
19394else
19395 echo "$as_me: failed program was:" >&5
19650fd6
AS
19396sed 's/^/| /' conftest.$ac_ext >&5
19397
973a76b1 19398cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19399/* confdefs.h. */
19400_ACEOF
19401cat confdefs.h >>conftest.$ac_ext
19402cat >>conftest.$ac_ext <<_ACEOF
19403/* end confdefs.h. */
973a76b1
DL
19404#include <sys/types.h>
19405#include <$ac_cv_struct_tm>
19406
19407
19408int
19409main ()
19410{
19411static struct tm ac_aggr;
19412if (sizeof ac_aggr.tm_zone)
19413return 0;
19414 ;
19415 return 0;
19416}
19417_ACEOF
19418rm -f conftest.$ac_objext
19419if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19420 (eval $ac_compile) 2>conftest.er1
973a76b1 19421 ac_status=$?
35996d22
AS
19422 grep -v '^ *+' conftest.er1 >conftest.err
19423 rm -f conftest.er1
19424 cat conftest.err >&5
973a76b1
DL
19425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19426 (exit $ac_status); } &&
35996d22
AS
19427 { ac_try='test -z "$ac_c_werror_flag"
19428 || test ! -s conftest.err'
19429 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19430 (eval $ac_try) 2>&5
19431 ac_status=$?
19432 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19433 (exit $ac_status); }; } &&
19434 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19435 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19436 (eval $ac_try) 2>&5
19437 ac_status=$?
19438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19439 (exit $ac_status); }; }; then
19440 ac_cv_member_struct_tm_tm_zone=yes
19441else
19442 echo "$as_me: failed program was:" >&5
19650fd6
AS
19443sed 's/^/| /' conftest.$ac_ext >&5
19444
973a76b1
DL
19445ac_cv_member_struct_tm_tm_zone=no
19446fi
35996d22 19447rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1 19448fi
35996d22 19449rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
19450fi
19451echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
19452echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
19453if test $ac_cv_member_struct_tm_tm_zone = yes; then
19454
19455cat >>confdefs.h <<_ACEOF
19456#define HAVE_STRUCT_TM_TM_ZONE 1
19457_ACEOF
19458
19459
19460fi
19461
19462if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19463
19464cat >>confdefs.h <<\_ACEOF
19465#define HAVE_TM_ZONE 1
19466_ACEOF
19467
19468else
19469 echo "$as_me:$LINENO: checking for tzname" >&5
19470echo $ECHO_N "checking for tzname... $ECHO_C" >&6
19471if test "${ac_cv_var_tzname+set}" = set; then
19472 echo $ECHO_N "(cached) $ECHO_C" >&6
19473else
19474 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19475/* confdefs.h. */
19476_ACEOF
19477cat confdefs.h >>conftest.$ac_ext
19478cat >>conftest.$ac_ext <<_ACEOF
19479/* end confdefs.h. */
973a76b1
DL
19480#include <time.h>
19481#ifndef tzname /* For SGI. */
19482extern char *tzname[]; /* RS6000 and others reject char **tzname. */
19483#endif
19484
19485int
19486main ()
19487{
19488atoi(*tzname);
19489 ;
19490 return 0;
19491}
19492_ACEOF
19493rm -f conftest.$ac_objext conftest$ac_exeext
19494if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19495 (eval $ac_link) 2>conftest.er1
973a76b1 19496 ac_status=$?
35996d22
AS
19497 grep -v '^ *+' conftest.er1 >conftest.err
19498 rm -f conftest.er1
19499 cat conftest.err >&5
973a76b1
DL
19500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19501 (exit $ac_status); } &&
35996d22
AS
19502 { ac_try='test -z "$ac_c_werror_flag"
19503 || test ! -s conftest.err'
19504 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19505 (eval $ac_try) 2>&5
19506 ac_status=$?
19507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19508 (exit $ac_status); }; } &&
19509 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
19510 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19511 (eval $ac_try) 2>&5
19512 ac_status=$?
19513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19514 (exit $ac_status); }; }; then
19515 ac_cv_var_tzname=yes
19516else
19517 echo "$as_me: failed program was:" >&5
19650fd6
AS
19518sed 's/^/| /' conftest.$ac_ext >&5
19519
973a76b1
DL
19520ac_cv_var_tzname=no
19521fi
35996d22
AS
19522rm -f conftest.err conftest.$ac_objext \
19523 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
19524fi
19525echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
19526echo "${ECHO_T}$ac_cv_var_tzname" >&6
19527 if test $ac_cv_var_tzname = yes; then
19528
19529cat >>confdefs.h <<\_ACEOF
19530#define HAVE_TZNAME 1
19531_ACEOF
19532
19533 fi
19534fi
19535
19536
48d4b120 19537if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 19538 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
19539echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
19540if test "${emacs_cv_struct_timezone+set}" = set; then
19541 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19542else
503d2be0 19543 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19544/* confdefs.h. */
19545_ACEOF
19546cat confdefs.h >>conftest.$ac_ext
19547cat >>conftest.$ac_ext <<_ACEOF
19548/* end confdefs.h. */
48d4b120 19549#include <sys/time.h>
503d2be0
AS
19550int
19551main ()
19552{
48d4b120 19553struct timezone tz;
503d2be0
AS
19554 ;
19555 return 0;
19556}
19557_ACEOF
19558rm -f conftest.$ac_objext
c0d27fcc 19559if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19560 (eval $ac_compile) 2>conftest.er1
503d2be0 19561 ac_status=$?
35996d22
AS
19562 grep -v '^ *+' conftest.er1 >conftest.err
19563 rm -f conftest.er1
19564 cat conftest.err >&5
c0d27fcc 19565 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19566 (exit $ac_status); } &&
35996d22
AS
19567 { ac_try='test -z "$ac_c_werror_flag"
19568 || test ! -s conftest.err'
19569 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19570 (eval $ac_try) 2>&5
19571 ac_status=$?
19572 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19573 (exit $ac_status); }; } &&
19574 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19575 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19576 (eval $ac_try) 2>&5
19577 ac_status=$?
c0d27fcc 19578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19579 (exit $ac_status); }; }; then
48d4b120
DL
19580 if test "$cross_compiling" = yes; then
19581 emacs_cv_struct_timezone=yes
19582else
503d2be0 19583 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19584/* confdefs.h. */
19585_ACEOF
19586cat confdefs.h >>conftest.$ac_ext
19587cat >>conftest.$ac_ext <<_ACEOF
19588/* end confdefs.h. */
48d4b120
DL
19589
19590#ifdef TIME_WITH_SYS_TIME
19591#include <sys/time.h>
19592#include <time.h>
19593#else
19594#ifdef HAVE_SYS_TIME_H
19595#include <sys/time.h>
19596#else
19597#include <time.h>
19598#endif
19599#endif
19600main () {
19601 struct timeval time;
19602 struct timezone dummy;
19603 exit (gettimeofday (&time, &dummy));
19604}
503d2be0
AS
19605_ACEOF
19606rm -f conftest$ac_exeext
c0d27fcc 19607if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19608 (eval $ac_link) 2>&5
19609 ac_status=$?
c0d27fcc 19610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19611 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19612 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19613 (eval $ac_try) 2>&5
19614 ac_status=$?
c0d27fcc 19615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19616 (exit $ac_status); }; }; then
48d4b120
DL
19617 emacs_cv_struct_timezone=yes
19618else
503d2be0
AS
19619 echo "$as_me: program exited with status $ac_status" >&5
19620echo "$as_me: failed program was:" >&5
19650fd6
AS
19621sed 's/^/| /' conftest.$ac_ext >&5
19622
c0d27fcc 19623( exit $ac_status )
503d2be0 19624emacs_cv_struct_timezone=no
48d4b120 19625fi
35996d22 19626rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 19627fi
48d4b120 19628else
503d2be0 19629 echo "$as_me: failed program was:" >&5
19650fd6
AS
19630sed 's/^/| /' conftest.$ac_ext >&5
19631
503d2be0 19632emacs_cv_struct_timezone=no
48d4b120 19633fi
35996d22 19634rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
48d4b120 19635fi
c0d27fcc 19636echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 19637echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
19638fi
19639
ba4481b5 19640ok_so_far=yes
c0d27fcc 19641echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
19642echo $ECHO_N "checking for socket... $ECHO_C" >&6
19643if test "${ac_cv_func_socket+set}" = set; then
19644 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19645else
503d2be0 19646 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19647/* confdefs.h. */
19648_ACEOF
19649cat confdefs.h >>conftest.$ac_ext
19650cat >>conftest.$ac_ext <<_ACEOF
19651/* end confdefs.h. */
35996d22
AS
19652/* Define socket to an innocuous variant, in case <limits.h> declares socket.
19653 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19654#define socket innocuous_socket
19655
ba4481b5 19656/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19657 which can conflict with char socket (); below.
19658 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19659 <limits.h> exists even on freestanding compilers. */
35996d22 19660
19650fd6
AS
19661#ifdef __STDC__
19662# include <limits.h>
19663#else
19664# include <assert.h>
19665#endif
35996d22
AS
19666
19667#undef socket
19668
ba4481b5 19669/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19670#ifdef __cplusplus
19671extern "C"
19650fd6 19672{
503d2be0 19673#endif
ba4481b5 19674/* We use char because int might match the return type of a gcc2
503d2be0
AS
19675 builtin and then its argument prototype would still apply. */
19676char socket ();
ba4481b5
DL
19677/* The GNU C library defines this for functions which it implements
19678 to always fail with ENOSYS. Some functions are actually named
19679 something starting with __ and the normal name is an alias. */
19680#if defined (__stub_socket) || defined (__stub___socket)
19681choke me
19682#else
19650fd6
AS
19683char (*f) () = socket;
19684#endif
19685#ifdef __cplusplus
19686}
cd958eb3
MB
19687#endif
19688
19650fd6
AS
19689int
19690main ()
19691{
19692return f != socket;
503d2be0
AS
19693 ;
19694 return 0;
19695}
19696_ACEOF
19697rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19698if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19699 (eval $ac_link) 2>conftest.er1
503d2be0 19700 ac_status=$?
35996d22
AS
19701 grep -v '^ *+' conftest.er1 >conftest.err
19702 rm -f conftest.er1
19703 cat conftest.err >&5
c0d27fcc 19704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19705 (exit $ac_status); } &&
35996d22
AS
19706 { ac_try='test -z "$ac_c_werror_flag"
19707 || test ! -s conftest.err'
19708 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19709 (eval $ac_try) 2>&5
19710 ac_status=$?
19711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19712 (exit $ac_status); }; } &&
19713 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19715 (eval $ac_try) 2>&5
19716 ac_status=$?
c0d27fcc 19717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19718 (exit $ac_status); }; }; then
19719 ac_cv_func_socket=yes
19720else
19721 echo "$as_me: failed program was:" >&5
19650fd6
AS
19722sed 's/^/| /' conftest.$ac_ext >&5
19723
503d2be0
AS
19724ac_cv_func_socket=no
19725fi
35996d22
AS
19726rm -f conftest.err conftest.$ac_objext \
19727 conftest$ac_exeext conftest.$ac_ext
503d2be0 19728fi
c0d27fcc 19729echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
19730echo "${ECHO_T}$ac_cv_func_socket" >&6
19731if test $ac_cv_func_socket = yes; then
ba4481b5
DL
19732 :
19733else
503d2be0 19734 ok_so_far=no
ba4481b5
DL
19735fi
19736
19737if test $ok_so_far = yes; then
c0d27fcc
MR
19738 if test "${ac_cv_header_netinet_in_h+set}" = set; then
19739 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
19740echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19741if test "${ac_cv_header_netinet_in_h+set}" = set; then
19742 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19743fi
19744echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
19745echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 19746else
c0d27fcc
MR
19747 # Is the header compilable?
19748echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
19749echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
19750cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19751/* confdefs.h. */
19752_ACEOF
19753cat confdefs.h >>conftest.$ac_ext
19754cat >>conftest.$ac_ext <<_ACEOF
19755/* end confdefs.h. */
c0d27fcc
MR
19756$ac_includes_default
19757#include <netinet/in.h>
19758_ACEOF
19759rm -f conftest.$ac_objext
19760if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19761 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19762 ac_status=$?
35996d22
AS
19763 grep -v '^ *+' conftest.er1 >conftest.err
19764 rm -f conftest.er1
19765 cat conftest.err >&5
c0d27fcc
MR
19766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19767 (exit $ac_status); } &&
35996d22
AS
19768 { ac_try='test -z "$ac_c_werror_flag"
19769 || test ! -s conftest.err'
19770 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19771 (eval $ac_try) 2>&5
19772 ac_status=$?
19773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19774 (exit $ac_status); }; } &&
19775 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19776 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19777 (eval $ac_try) 2>&5
19778 ac_status=$?
19779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19780 (exit $ac_status); }; }; then
19781 ac_header_compiler=yes
19782else
19783 echo "$as_me: failed program was:" >&5
19650fd6
AS
19784sed 's/^/| /' conftest.$ac_ext >&5
19785
c0d27fcc
MR
19786ac_header_compiler=no
19787fi
35996d22 19788rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19789echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19790echo "${ECHO_T}$ac_header_compiler" >&6
19791
19792# Is the header present?
19793echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
19794echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
19795cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19796/* confdefs.h. */
19797_ACEOF
19798cat confdefs.h >>conftest.$ac_ext
19799cat >>conftest.$ac_ext <<_ACEOF
19800/* end confdefs.h. */
ba4481b5 19801#include <netinet/in.h>
503d2be0 19802_ACEOF
c0d27fcc 19803if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19804 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19805 ac_status=$?
6bae0ccf 19806 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19807 rm -f conftest.er1
19808 cat conftest.err >&5
c0d27fcc 19809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19810 (exit $ac_status); } >/dev/null; then
19811 if test -s conftest.err; then
19812 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19813 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19814 else
19815 ac_cpp_err=
19816 fi
19817else
19818 ac_cpp_err=yes
19819fi
19820if test -z "$ac_cpp_err"; then
c0d27fcc 19821 ac_header_preproc=yes
ba4481b5 19822else
503d2be0 19823 echo "$as_me: failed program was:" >&5
19650fd6
AS
19824sed 's/^/| /' conftest.$ac_ext >&5
19825
c0d27fcc 19826 ac_header_preproc=no
ba4481b5 19827fi
503d2be0 19828rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19829echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19830echo "${ECHO_T}$ac_header_preproc" >&6
19831
19832# So? What about this header?
35996d22
AS
19833case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19834 yes:no: )
c0d27fcc
MR
19835 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
19836echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19837 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the compiler's result" >&5
19838echo "$as_me: WARNING: netinet/in.h: proceeding with the compiler's result" >&2;}
19839 ac_header_preproc=yes
19650fd6 19840 ;;
35996d22 19841 no:yes:* )
c0d27fcc
MR
19842 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
19843echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
35996d22
AS
19844 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
19845echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
19846 { echo "$as_me:$LINENO: WARNING: netinet/in.h: see the Autoconf documentation" >&5
19847echo "$as_me: WARNING: netinet/in.h: see the Autoconf documentation" >&2;}
19848 { echo "$as_me:$LINENO: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&5
19849echo "$as_me: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19850 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
19650fd6 19851echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19852 { echo "$as_me:$LINENO: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&5
19853echo "$as_me: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19854 (
19855 cat <<\_ASBOX
35996d22
AS
19856## ------------------------------------------ ##
19857## Report this to the AC_PACKAGE_NAME lists. ##
19858## ------------------------------------------ ##
19650fd6
AS
19859_ASBOX
19860 ) |
19861 sed "s/^/$as_me: WARNING: /" >&2
19862 ;;
c0d27fcc
MR
19863esac
19864echo "$as_me:$LINENO: checking for netinet/in.h" >&5
19865echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19866if test "${ac_cv_header_netinet_in_h+set}" = set; then
19867 echo $ECHO_N "(cached) $ECHO_C" >&6
19868else
19869 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 19870fi
c0d27fcc 19871echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 19872echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
19873
19874fi
503d2be0 19875if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
19876 :
19877else
503d2be0 19878 ok_so_far=no
ba4481b5
DL
19879fi
19880
c0d27fcc 19881
ba4481b5
DL
19882fi
19883if test $ok_so_far = yes; then
c0d27fcc
MR
19884 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19885 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
19886echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
19887if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19888 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19889fi
19890echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
19891echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 19892else
c0d27fcc
MR
19893 # Is the header compilable?
19894echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
19895echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
19896cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19897/* confdefs.h. */
19898_ACEOF
19899cat confdefs.h >>conftest.$ac_ext
19900cat >>conftest.$ac_ext <<_ACEOF
19901/* end confdefs.h. */
c0d27fcc
MR
19902$ac_includes_default
19903#include <arpa/inet.h>
19904_ACEOF
19905rm -f conftest.$ac_objext
19906if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19907 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19908 ac_status=$?
35996d22
AS
19909 grep -v '^ *+' conftest.er1 >conftest.err
19910 rm -f conftest.er1
19911 cat conftest.err >&5
c0d27fcc
MR
19912 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19913 (exit $ac_status); } &&
35996d22
AS
19914 { ac_try='test -z "$ac_c_werror_flag"
19915 || test ! -s conftest.err'
19916 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19917 (eval $ac_try) 2>&5
19918 ac_status=$?
19919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19920 (exit $ac_status); }; } &&
19921 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19923 (eval $ac_try) 2>&5
19924 ac_status=$?
19925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19926 (exit $ac_status); }; }; then
19927 ac_header_compiler=yes
19928else
19929 echo "$as_me: failed program was:" >&5
19650fd6
AS
19930sed 's/^/| /' conftest.$ac_ext >&5
19931
c0d27fcc
MR
19932ac_header_compiler=no
19933fi
35996d22 19934rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19935echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19936echo "${ECHO_T}$ac_header_compiler" >&6
19937
19938# Is the header present?
19939echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
19940echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
19941cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19942/* confdefs.h. */
19943_ACEOF
19944cat confdefs.h >>conftest.$ac_ext
19945cat >>conftest.$ac_ext <<_ACEOF
19946/* end confdefs.h. */
ba4481b5 19947#include <arpa/inet.h>
503d2be0 19948_ACEOF
c0d27fcc 19949if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19950 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19951 ac_status=$?
6bae0ccf 19952 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19953 rm -f conftest.er1
19954 cat conftest.err >&5
c0d27fcc 19955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19956 (exit $ac_status); } >/dev/null; then
19957 if test -s conftest.err; then
19958 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19959 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19960 else
19961 ac_cpp_err=
19962 fi
19963else
19964 ac_cpp_err=yes
19965fi
19966if test -z "$ac_cpp_err"; then
c0d27fcc 19967 ac_header_preproc=yes
ba4481b5 19968else
503d2be0 19969 echo "$as_me: failed program was:" >&5
19650fd6
AS
19970sed 's/^/| /' conftest.$ac_ext >&5
19971
c0d27fcc 19972 ac_header_preproc=no
ba4481b5 19973fi
503d2be0 19974rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19975echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19976echo "${ECHO_T}$ac_header_preproc" >&6
19977
19978# So? What about this header?
35996d22
AS
19979case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19980 yes:no: )
c0d27fcc
MR
19981 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
19982echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19983 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the compiler's result" >&5
19984echo "$as_me: WARNING: arpa/inet.h: proceeding with the compiler's result" >&2;}
19985 ac_header_preproc=yes
19650fd6 19986 ;;
35996d22 19987 no:yes:* )
c0d27fcc
MR
19988 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
19989echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
35996d22
AS
19990 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
19991echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
19992 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: see the Autoconf documentation" >&5
19993echo "$as_me: WARNING: arpa/inet.h: see the Autoconf documentation" >&2;}
19994 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&5
19995echo "$as_me: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19996 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
19650fd6 19997echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19998 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&5
19999echo "$as_me: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20000 (
20001 cat <<\_ASBOX
35996d22
AS
20002## ------------------------------------------ ##
20003## Report this to the AC_PACKAGE_NAME lists. ##
20004## ------------------------------------------ ##
19650fd6
AS
20005_ASBOX
20006 ) |
20007 sed "s/^/$as_me: WARNING: /" >&2
20008 ;;
c0d27fcc
MR
20009esac
20010echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
20011echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
20012if test "${ac_cv_header_arpa_inet_h+set}" = set; then
20013 echo $ECHO_N "(cached) $ECHO_C" >&6
20014else
20015 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 20016fi
c0d27fcc 20017echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 20018echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
20019
20020fi
503d2be0 20021if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
20022 :
20023else
503d2be0 20024 ok_so_far=no
ba4481b5
DL
20025fi
20026
c0d27fcc 20027
ba4481b5
DL
20028fi
20029if test $ok_so_far = yes; then
b936fae4 20030
c0d27fcc 20031cat >>confdefs.h <<\_ACEOF
ba4481b5 20032#define HAVE_INET_SOCKETS 1
c0d27fcc 20033_ACEOF
ba4481b5
DL
20034
20035fi
20036
2d2b6695 20037
7862d3a8 20038for ac_header in sys/ioctl.h
2d2b6695
KS
20039do
20040as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20041if eval "test \"\${$as_ac_Header+set}\" = set"; then
20042 echo "$as_me:$LINENO: checking for $ac_header" >&5
20043echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20044if eval "test \"\${$as_ac_Header+set}\" = set"; then
20045 echo $ECHO_N "(cached) $ECHO_C" >&6
20046fi
20047echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20048echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20049else
20050 # Is the header compilable?
20051echo "$as_me:$LINENO: checking $ac_header usability" >&5
20052echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20053cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
20054/* confdefs.h. */
20055_ACEOF
20056cat confdefs.h >>conftest.$ac_ext
20057cat >>conftest.$ac_ext <<_ACEOF
20058/* end confdefs.h. */
20059$ac_includes_default
20060#include <$ac_header>
20061_ACEOF
20062rm -f conftest.$ac_objext
20063if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20064 (eval $ac_compile) 2>conftest.er1
2d2b6695 20065 ac_status=$?
35996d22
AS
20066 grep -v '^ *+' conftest.er1 >conftest.err
20067 rm -f conftest.er1
20068 cat conftest.err >&5
2d2b6695
KS
20069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20070 (exit $ac_status); } &&
35996d22
AS
20071 { ac_try='test -z "$ac_c_werror_flag"
20072 || test ! -s conftest.err'
20073 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20074 (eval $ac_try) 2>&5
20075 ac_status=$?
20076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20077 (exit $ac_status); }; } &&
20078 { ac_try='test -s conftest.$ac_objext'
2d2b6695
KS
20079 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20080 (eval $ac_try) 2>&5
20081 ac_status=$?
20082 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20083 (exit $ac_status); }; }; then
20084 ac_header_compiler=yes
20085else
20086 echo "$as_me: failed program was:" >&5
20087sed 's/^/| /' conftest.$ac_ext >&5
20088
20089ac_header_compiler=no
20090fi
35996d22 20091rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2d2b6695
KS
20092echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20093echo "${ECHO_T}$ac_header_compiler" >&6
20094
20095# Is the header present?
20096echo "$as_me:$LINENO: checking $ac_header presence" >&5
20097echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20098cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
20099/* confdefs.h. */
20100_ACEOF
20101cat confdefs.h >>conftest.$ac_ext
20102cat >>conftest.$ac_ext <<_ACEOF
20103/* end confdefs.h. */
20104#include <$ac_header>
20105_ACEOF
20106if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20107 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20108 ac_status=$?
20109 grep -v '^ *+' conftest.er1 >conftest.err
20110 rm -f conftest.er1
20111 cat conftest.err >&5
20112 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20113 (exit $ac_status); } >/dev/null; then
20114 if test -s conftest.err; then
20115 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20116 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2d2b6695
KS
20117 else
20118 ac_cpp_err=
20119 fi
20120else
20121 ac_cpp_err=yes
20122fi
20123if test -z "$ac_cpp_err"; then
20124 ac_header_preproc=yes
20125else
20126 echo "$as_me: failed program was:" >&5
20127sed 's/^/| /' conftest.$ac_ext >&5
20128
20129 ac_header_preproc=no
20130fi
20131rm -f conftest.err conftest.$ac_ext
20132echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20133echo "${ECHO_T}$ac_header_preproc" >&6
20134
20135# So? What about this header?
35996d22
AS
20136case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20137 yes:no: )
2d2b6695
KS
20138 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20139echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20140 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20141echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20142 ac_header_preproc=yes
2d2b6695 20143 ;;
35996d22 20144 no:yes:* )
2d2b6695
KS
20145 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20146echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20147 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20148echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20149 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20150echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20151 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20152echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
2d2b6695
KS
20153 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20154echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20155 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20156echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
2d2b6695
KS
20157 (
20158 cat <<\_ASBOX
35996d22
AS
20159## ------------------------------------------ ##
20160## Report this to the AC_PACKAGE_NAME lists. ##
20161## ------------------------------------------ ##
2d2b6695
KS
20162_ASBOX
20163 ) |
20164 sed "s/^/$as_me: WARNING: /" >&2
20165 ;;
20166esac
20167echo "$as_me:$LINENO: checking for $ac_header" >&5
20168echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20169if eval "test \"\${$as_ac_Header+set}\" = set"; then
20170 echo $ECHO_N "(cached) $ECHO_C" >&6
20171else
35996d22 20172 eval "$as_ac_Header=\$ac_header_preproc"
2d2b6695
KS
20173fi
20174echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20175echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20176
20177fi
20178if test `eval echo '${'$as_ac_Header'}'` = yes; then
20179 cat >>confdefs.h <<_ACEOF
20180#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20181_ACEOF
20182
20183fi
20184
20185done
20186
20187
ba4481b5 20188if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 20189
c0d27fcc 20190cat >>confdefs.h <<\_ACEOF
ba4481b5 20191#define HAVE_AIX_SMT_EXP 1
c0d27fcc 20192_ACEOF
ba4481b5
DL
20193
20194fi
20195
c0d27fcc 20196echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 20197echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 20198if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 20199 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 20200echo "${ECHO_T}yes" >&6
b936fae4 20201
c0d27fcc 20202cat >>confdefs.h <<\_ACEOF
3d9fec71 20203#define HAVE_DEV_PTMX 1
c0d27fcc 20204_ACEOF
3d9fec71
DL
20205
20206else
c0d27fcc 20207 echo "$as_me:$LINENO: result: no" >&5
503d2be0 20208echo "${ECHO_T}no" >&6
3d9fec71
DL
20209fi
20210
c0d27fcc 20211echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
20212echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
20213if test "${ac_cv_type_pid_t+set}" = set; then
20214 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 20215else
503d2be0 20216 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20217/* confdefs.h. */
20218_ACEOF
20219cat confdefs.h >>conftest.$ac_ext
20220cat >>conftest.$ac_ext <<_ACEOF
20221/* end confdefs.h. */
503d2be0
AS
20222$ac_includes_default
20223int
20224main ()
20225{
20226if ((pid_t *) 0)
20227 return 0;
20228if (sizeof (pid_t))
20229 return 0;
20230 ;
20231 return 0;
20232}
20233_ACEOF
20234rm -f conftest.$ac_objext
c0d27fcc 20235if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20236 (eval $ac_compile) 2>conftest.er1
503d2be0 20237 ac_status=$?
35996d22
AS
20238 grep -v '^ *+' conftest.er1 >conftest.err
20239 rm -f conftest.er1
20240 cat conftest.err >&5
c0d27fcc 20241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20242 (exit $ac_status); } &&
35996d22
AS
20243 { ac_try='test -z "$ac_c_werror_flag"
20244 || test ! -s conftest.err'
20245 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20246 (eval $ac_try) 2>&5
20247 ac_status=$?
20248 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20249 (exit $ac_status); }; } &&
20250 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20251 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20252 (eval $ac_try) 2>&5
20253 ac_status=$?
c0d27fcc 20254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20255 (exit $ac_status); }; }; then
647847ea
DL
20256 ac_cv_type_pid_t=yes
20257else
503d2be0 20258 echo "$as_me: failed program was:" >&5
19650fd6
AS
20259sed 's/^/| /' conftest.$ac_ext >&5
20260
503d2be0 20261ac_cv_type_pid_t=no
647847ea 20262fi
35996d22 20263rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
647847ea 20264fi
c0d27fcc 20265echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
20266echo "${ECHO_T}$ac_cv_type_pid_t" >&6
20267if test $ac_cv_type_pid_t = yes; then
20268 :
20269else
20270
c0d27fcc 20271cat >>confdefs.h <<_ACEOF
647847ea 20272#define pid_t int
c0d27fcc 20273_ACEOF
647847ea
DL
20274
20275fi
20276
c0d27fcc
MR
20277
20278
503d2be0
AS
20279for ac_header in unistd.h vfork.h
20280do
20281as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
20282if eval "test \"\${$as_ac_Header+set}\" = set"; then
20283 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
20284echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20285if eval "test \"\${$as_ac_Header+set}\" = set"; then
20286 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20287fi
20288echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20289echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 20290else
c0d27fcc
MR
20291 # Is the header compilable?
20292echo "$as_me:$LINENO: checking $ac_header usability" >&5
20293echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20294cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20295/* confdefs.h. */
20296_ACEOF
20297cat confdefs.h >>conftest.$ac_ext
20298cat >>conftest.$ac_ext <<_ACEOF
20299/* end confdefs.h. */
c0d27fcc
MR
20300$ac_includes_default
20301#include <$ac_header>
20302_ACEOF
20303rm -f conftest.$ac_objext
20304if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20305 (eval $ac_compile) 2>conftest.er1
c0d27fcc 20306 ac_status=$?
35996d22
AS
20307 grep -v '^ *+' conftest.er1 >conftest.err
20308 rm -f conftest.er1
20309 cat conftest.err >&5
c0d27fcc
MR
20310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20311 (exit $ac_status); } &&
35996d22
AS
20312 { ac_try='test -z "$ac_c_werror_flag"
20313 || test ! -s conftest.err'
20314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20315 (eval $ac_try) 2>&5
20316 ac_status=$?
20317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20318 (exit $ac_status); }; } &&
20319 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20321 (eval $ac_try) 2>&5
20322 ac_status=$?
20323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20324 (exit $ac_status); }; }; then
20325 ac_header_compiler=yes
20326else
20327 echo "$as_me: failed program was:" >&5
19650fd6
AS
20328sed 's/^/| /' conftest.$ac_ext >&5
20329
c0d27fcc
MR
20330ac_header_compiler=no
20331fi
35996d22 20332rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20333echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20334echo "${ECHO_T}$ac_header_compiler" >&6
20335
20336# Is the header present?
20337echo "$as_me:$LINENO: checking $ac_header presence" >&5
20338echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20339cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20340/* confdefs.h. */
20341_ACEOF
20342cat confdefs.h >>conftest.$ac_ext
20343cat >>conftest.$ac_ext <<_ACEOF
20344/* end confdefs.h. */
503d2be0
AS
20345#include <$ac_header>
20346_ACEOF
c0d27fcc 20347if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20348 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20349 ac_status=$?
6bae0ccf 20350 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20351 rm -f conftest.er1
20352 cat conftest.err >&5
c0d27fcc 20353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20354 (exit $ac_status); } >/dev/null; then
20355 if test -s conftest.err; then
20356 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20357 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20358 else
20359 ac_cpp_err=
20360 fi
647847ea 20361else
503d2be0
AS
20362 ac_cpp_err=yes
20363fi
20364if test -z "$ac_cpp_err"; then
c0d27fcc 20365 ac_header_preproc=yes
647847ea 20366else
503d2be0 20367 echo "$as_me: failed program was:" >&5
19650fd6
AS
20368sed 's/^/| /' conftest.$ac_ext >&5
20369
c0d27fcc 20370 ac_header_preproc=no
647847ea 20371fi
503d2be0 20372rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20373echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20374echo "${ECHO_T}$ac_header_preproc" >&6
20375
20376# So? What about this header?
35996d22
AS
20377case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20378 yes:no: )
c0d27fcc
MR
20379 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20380echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20381 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20382echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20383 ac_header_preproc=yes
19650fd6 20384 ;;
35996d22 20385 no:yes:* )
c0d27fcc
MR
20386 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20387echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20388 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20389echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20390 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20391echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20392 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20393echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20394 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 20395echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20396 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20397echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20398 (
20399 cat <<\_ASBOX
35996d22
AS
20400## ------------------------------------------ ##
20401## Report this to the AC_PACKAGE_NAME lists. ##
20402## ------------------------------------------ ##
19650fd6
AS
20403_ASBOX
20404 ) |
20405 sed "s/^/$as_me: WARNING: /" >&2
20406 ;;
c0d27fcc
MR
20407esac
20408echo "$as_me:$LINENO: checking for $ac_header" >&5
20409echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20410if eval "test \"\${$as_ac_Header+set}\" = set"; then
20411 echo $ECHO_N "(cached) $ECHO_C" >&6
20412else
35996d22 20413 eval "$as_ac_Header=\$ac_header_preproc"
647847ea 20414fi
c0d27fcc 20415echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 20416echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
20417
20418fi
503d2be0 20419if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 20420 cat >>confdefs.h <<_ACEOF
503d2be0 20421#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 20422_ACEOF
647847ea 20423
73b77ee5 20424fi
c0d27fcc 20425
503d2be0 20426done
73b77ee5 20427
c0d27fcc
MR
20428
20429
503d2be0
AS
20430for ac_func in fork vfork
20431do
20432as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 20433echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
20434echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
20435if eval "test \"\${$as_ac_var+set}\" = set"; then
20436 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20437else
503d2be0 20438 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20439/* confdefs.h. */
20440_ACEOF
20441cat confdefs.h >>conftest.$ac_ext
20442cat >>conftest.$ac_ext <<_ACEOF
20443/* end confdefs.h. */
35996d22
AS
20444/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20445 For example, HP-UX 11i <limits.h> declares gettimeofday. */
20446#define $ac_func innocuous_$ac_func
20447
fa0b693c 20448/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
20449 which can conflict with char $ac_func (); below.
20450 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20451 <limits.h> exists even on freestanding compilers. */
35996d22 20452
19650fd6
AS
20453#ifdef __STDC__
20454# include <limits.h>
20455#else
20456# include <assert.h>
20457#endif
35996d22
AS
20458
20459#undef $ac_func
20460
fa0b693c 20461/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20462#ifdef __cplusplus
20463extern "C"
19650fd6 20464{
503d2be0 20465#endif
fa0b693c 20466/* We use char because int might match the return type of a gcc2
503d2be0
AS
20467 builtin and then its argument prototype would still apply. */
20468char $ac_func ();
fa0b693c
GM
20469/* The GNU C library defines this for functions which it implements
20470 to always fail with ENOSYS. Some functions are actually named
20471 something starting with __ and the normal name is an alias. */
503d2be0 20472#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
20473choke me
20474#else
19650fd6
AS
20475char (*f) () = $ac_func;
20476#endif
20477#ifdef __cplusplus
20478}
fa0b693c
GM
20479#endif
20480
19650fd6
AS
20481int
20482main ()
20483{
20484return f != $ac_func;
503d2be0
AS
20485 ;
20486 return 0;
20487}
20488_ACEOF
20489rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20490if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20491 (eval $ac_link) 2>conftest.er1
503d2be0 20492 ac_status=$?
35996d22
AS
20493 grep -v '^ *+' conftest.er1 >conftest.err
20494 rm -f conftest.er1
20495 cat conftest.err >&5
c0d27fcc 20496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20497 (exit $ac_status); } &&
35996d22
AS
20498 { ac_try='test -z "$ac_c_werror_flag"
20499 || test ! -s conftest.err'
20500 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20501 (eval $ac_try) 2>&5
20502 ac_status=$?
20503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20504 (exit $ac_status); }; } &&
20505 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 20506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20507 (eval $ac_try) 2>&5
20508 ac_status=$?
c0d27fcc 20509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20510 (exit $ac_status); }; }; then
20511 eval "$as_ac_var=yes"
20512else
20513 echo "$as_me: failed program was:" >&5
19650fd6
AS
20514sed 's/^/| /' conftest.$ac_ext >&5
20515
503d2be0
AS
20516eval "$as_ac_var=no"
20517fi
35996d22
AS
20518rm -f conftest.err conftest.$ac_objext \
20519 conftest$ac_exeext conftest.$ac_ext
503d2be0 20520fi
c0d27fcc 20521echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
20522echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
20523if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 20524 cat >>confdefs.h <<_ACEOF
503d2be0 20525#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 20526_ACEOF
503d2be0 20527
fa0b693c 20528fi
503d2be0 20529done
fa0b693c 20530
503d2be0 20531if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 20532 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
20533echo $ECHO_N "checking for working fork... $ECHO_C" >&6
20534if test "${ac_cv_func_fork_works+set}" = set; then
20535 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20536else
503d2be0
AS
20537 if test "$cross_compiling" = yes; then
20538 ac_cv_func_fork_works=cross
20539else
20540 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 20541/* By Ruediger Kuhlmann. */
503d2be0
AS
20542 #include <sys/types.h>
20543 #if HAVE_UNISTD_H
20544 # include <unistd.h>
20545 #endif
20546 /* Some systems only have a dummy stub for fork() */
20547 int main ()
20548 {
35996d22
AS
20549 if (fork() < 0)
20550 exit (1);
20551 exit (0);
503d2be0
AS
20552 }
20553_ACEOF
20554rm -f conftest$ac_exeext
c0d27fcc 20555if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20556 (eval $ac_link) 2>&5
20557 ac_status=$?
c0d27fcc 20558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20559 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20561 (eval $ac_try) 2>&5
20562 ac_status=$?
c0d27fcc 20563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20564 (exit $ac_status); }; }; then
20565 ac_cv_func_fork_works=yes
20566else
20567 echo "$as_me: program exited with status $ac_status" >&5
20568echo "$as_me: failed program was:" >&5
19650fd6
AS
20569sed 's/^/| /' conftest.$ac_ext >&5
20570
c0d27fcc 20571( exit $ac_status )
503d2be0
AS
20572ac_cv_func_fork_works=no
20573fi
35996d22 20574rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
20575fi
20576fi
c0d27fcc 20577echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
20578echo "${ECHO_T}$ac_cv_func_fork_works" >&6
20579
6bae0ccf
DL
20580else
20581 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
20582fi
20583if test "x$ac_cv_func_fork_works" = xcross; then
20584 case $host in
20585 *-*-amigaos* | *-*-msdosdjgpp*)
20586 # Override, as these systems have only a dummy fork() stub
20587 ac_cv_func_fork_works=no
20588 ;;
20589 *)
20590 ac_cv_func_fork_works=yes
20591 ;;
20592 esac
c0d27fcc
MR
20593 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
20594echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 20595fi
73b77ee5 20596ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 20597if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 20598 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
20599echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
20600if test "${ac_cv_func_vfork_works+set}" = set; then
20601 echo $ECHO_N "(cached) $ECHO_C" >&6
20602else
20603 if test "$cross_compiling" = yes; then
20604 ac_cv_func_vfork_works=cross
fa0b693c 20605else
503d2be0 20606 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20607/* confdefs.h. */
20608_ACEOF
20609cat confdefs.h >>conftest.$ac_ext
20610cat >>conftest.$ac_ext <<_ACEOF
20611/* end confdefs.h. */
73b77ee5
GM
20612/* Thanks to Paul Eggert for this test. */
20613#include <stdio.h>
19650fd6 20614#include <stdlib.h>
fa0b693c 20615#include <sys/types.h>
73b77ee5 20616#include <sys/stat.h>
19650fd6 20617#include <sys/wait.h>
503d2be0
AS
20618#if HAVE_UNISTD_H
20619# include <unistd.h>
73b77ee5 20620#endif
503d2be0
AS
20621#if HAVE_VFORK_H
20622# include <vfork.h>
73b77ee5
GM
20623#endif
20624/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
20625 argument registers are propagated back to the parent. The compiler
20626 is told about this with #include <vfork.h>, but some compilers
20627 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
20628 static variable whose address is put into a register that is
20629 clobbered by the vfork. */
19650fd6 20630static void
fa0b693c 20631#ifdef __cplusplus
73b77ee5 20632sparc_address_test (int arg)
503d2be0 20633# else
73b77ee5 20634sparc_address_test (arg) int arg;
fa0b693c 20635#endif
fa0b693c 20636{
73b77ee5
GM
20637 static pid_t child;
20638 if (!child) {
20639 child = vfork ();
20640 if (child < 0) {
20641 perror ("vfork");
20642 _exit(2);
20643 }
20644 if (!child) {
20645 arg = getpid();
20646 write(-1, "", 0);
20647 _exit (arg);
20648 }
20649 }
20650}
503d2be0
AS
20651
20652int
20653main ()
20654{
73b77ee5
GM
20655 pid_t parent = getpid ();
20656 pid_t child;
fa0b693c 20657
19650fd6 20658 sparc_address_test (0);
fa0b693c 20659
73b77ee5 20660 child = vfork ();
fa0b693c 20661
73b77ee5 20662 if (child == 0) {
503d2be0
AS
20663 /* Here is another test for sparc vfork register problems. This
20664 test uses lots of local variables, at least as many local
20665 variables as main has allocated so far including compiler
20666 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
20667 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
20668 reuse the register of parent for one of the local variables,
20669 since it will think that parent can't possibly be used any more
20670 in this routine. Assigning to the local variable will thus
20671 munge parent in the parent process. */
73b77ee5
GM
20672 pid_t
20673 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
20674 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
20675 /* Convince the compiler that p..p7 are live; otherwise, it might
20676 use the same hardware register for all 8 local variables. */
20677 if (p != p1 || p != p2 || p != p3 || p != p4
20678 || p != p5 || p != p6 || p != p7)
20679 _exit(1);
fa0b693c 20680
503d2be0
AS
20681 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
20682 from child file descriptors. If the child closes a descriptor
20683 before it execs or exits, this munges the parent's descriptor
20684 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
20685 _exit(close(fileno(stdout)) != 0);
20686 } else {
20687 int status;
20688 struct stat st;
20689
20690 while (wait(&status) != child)
20691 ;
20692 exit(
20693 /* Was there some problem with vforking? */
20694 child < 0
20695
20696 /* Did the child fail? (This shouldn't happen.) */
20697 || status
20698
20699 /* Did the vfork/compiler bug occur? */
20700 || parent != getpid()
fa0b693c 20701
73b77ee5
GM
20702 /* Did the file descriptor bug occur? */
20703 || fstat(fileno(stdout), &st) != 0
20704 );
20705 }
20706}
503d2be0
AS
20707_ACEOF
20708rm -f conftest$ac_exeext
c0d27fcc 20709if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20710 (eval $ac_link) 2>&5
20711 ac_status=$?
c0d27fcc 20712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20713 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20715 (eval $ac_try) 2>&5
20716 ac_status=$?
c0d27fcc 20717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20718 (exit $ac_status); }; }; then
73b77ee5 20719 ac_cv_func_vfork_works=yes
fa0b693c 20720else
503d2be0
AS
20721 echo "$as_me: program exited with status $ac_status" >&5
20722echo "$as_me: failed program was:" >&5
19650fd6
AS
20723sed 's/^/| /' conftest.$ac_ext >&5
20724
c0d27fcc 20725( exit $ac_status )
503d2be0
AS
20726ac_cv_func_vfork_works=no
20727fi
35996d22 20728rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 20729fi
fa0b693c 20730fi
c0d27fcc 20731echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 20732echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 20733
503d2be0
AS
20734fi;
20735if test "x$ac_cv_func_fork_works" = xcross; then
35996d22 20736 ac_cv_func_vfork_works=$ac_cv_func_vfork
c0d27fcc
MR
20737 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
20738echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
20739fi
20740
503d2be0
AS
20741if test "x$ac_cv_func_vfork_works" = xyes; then
20742
c0d27fcc 20743cat >>confdefs.h <<\_ACEOF
503d2be0 20744#define HAVE_WORKING_VFORK 1
c0d27fcc 20745_ACEOF
503d2be0
AS
20746
20747else
20748
c0d27fcc 20749cat >>confdefs.h <<\_ACEOF
73b77ee5 20750#define vfork fork
c0d27fcc 20751_ACEOF
fa0b693c
GM
20752
20753fi
503d2be0
AS
20754if test "x$ac_cv_func_fork_works" = xyes; then
20755
c0d27fcc 20756cat >>confdefs.h <<\_ACEOF
503d2be0 20757#define HAVE_WORKING_FORK 1
c0d27fcc 20758_ACEOF
fa0b693c 20759
503d2be0 20760fi
647847ea 20761
c0d27fcc 20762
6a3a24fa
JD
20763echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
20764echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
20765if test "${emacs_cv_langinfo_codeset+set}" = set; then
20766 echo $ECHO_N "(cached) $ECHO_C" >&6
20767else
20768 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20769/* confdefs.h. */
20770_ACEOF
20771cat confdefs.h >>conftest.$ac_ext
20772cat >>conftest.$ac_ext <<_ACEOF
20773/* end confdefs.h. */
6a3a24fa
JD
20774#include <langinfo.h>
20775int
20776main ()
20777{
20778char* cs = nl_langinfo(CODESET);
20779 ;
20780 return 0;
20781}
20782_ACEOF
20783rm -f conftest.$ac_objext conftest$ac_exeext
20784if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20785 (eval $ac_link) 2>conftest.er1
6a3a24fa 20786 ac_status=$?
35996d22
AS
20787 grep -v '^ *+' conftest.er1 >conftest.err
20788 rm -f conftest.er1
20789 cat conftest.err >&5
6a3a24fa
JD
20790 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20791 (exit $ac_status); } &&
35996d22
AS
20792 { ac_try='test -z "$ac_c_werror_flag"
20793 || test ! -s conftest.err'
20794 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20795 (eval $ac_try) 2>&5
20796 ac_status=$?
20797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20798 (exit $ac_status); }; } &&
20799 { ac_try='test -s conftest$ac_exeext'
6a3a24fa
JD
20800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20801 (eval $ac_try) 2>&5
20802 ac_status=$?
20803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20804 (exit $ac_status); }; }; then
20805 emacs_cv_langinfo_codeset=yes
20806else
20807 echo "$as_me: failed program was:" >&5
19650fd6
AS
20808sed 's/^/| /' conftest.$ac_ext >&5
20809
6a3a24fa
JD
20810emacs_cv_langinfo_codeset=no
20811fi
35996d22
AS
20812rm -f conftest.err conftest.$ac_objext \
20813 conftest$ac_exeext conftest.$ac_ext
6a3a24fa
JD
20814
20815fi
20816echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
20817echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
20818if test $emacs_cv_langinfo_codeset = yes; then
20819
20820cat >>confdefs.h <<\_ACEOF
20821#define HAVE_LANGINFO_CODESET 1
20822_ACEOF
20823
20824fi
20825
c0d27fcc 20826echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
20827echo $ECHO_N "checking for size_t... $ECHO_C" >&6
20828if test "${ac_cv_type_size_t+set}" = set; then
20829 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 20830else
503d2be0 20831 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20832/* confdefs.h. */
20833_ACEOF
20834cat confdefs.h >>conftest.$ac_ext
20835cat >>conftest.$ac_ext <<_ACEOF
20836/* end confdefs.h. */
503d2be0
AS
20837$ac_includes_default
20838int
20839main ()
20840{
20841if ((size_t *) 0)
20842 return 0;
20843if (sizeof (size_t))
20844 return 0;
20845 ;
20846 return 0;
20847}
20848_ACEOF
20849rm -f conftest.$ac_objext
c0d27fcc 20850if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20851 (eval $ac_compile) 2>conftest.er1
503d2be0 20852 ac_status=$?
35996d22
AS
20853 grep -v '^ *+' conftest.er1 >conftest.err
20854 rm -f conftest.er1
20855 cat conftest.err >&5
c0d27fcc 20856 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20857 (exit $ac_status); } &&
35996d22
AS
20858 { ac_try='test -z "$ac_c_werror_flag"
20859 || test ! -s conftest.err'
20860 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20861 (eval $ac_try) 2>&5
20862 ac_status=$?
20863 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20864 (exit $ac_status); }; } &&
20865 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20866 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20867 (eval $ac_try) 2>&5
20868 ac_status=$?
c0d27fcc 20869 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20870 (exit $ac_status); }; }; then
8730a8da
DL
20871 ac_cv_type_size_t=yes
20872else
503d2be0 20873 echo "$as_me: failed program was:" >&5
19650fd6
AS
20874sed 's/^/| /' conftest.$ac_ext >&5
20875
503d2be0 20876ac_cv_type_size_t=no
8730a8da 20877fi
35996d22 20878rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8730a8da 20879fi
c0d27fcc 20880echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
20881echo "${ECHO_T}$ac_cv_type_size_t" >&6
20882if test $ac_cv_type_size_t = yes; then
503d2be0 20883
c0d27fcc
MR
20884cat >>confdefs.h <<_ACEOF
20885#define HAVE_SIZE_T 1
20886_ACEOF
20887
8730a8da
DL
20888
20889fi
20890
c0d27fcc 20891
973a76b1
DL
20892echo "$as_me:$LINENO: checking for mbstate_t" >&5
20893echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
20894if test "${ac_cv_type_mbstate_t+set}" = set; then
20895 echo $ECHO_N "(cached) $ECHO_C" >&6
20896else
20897 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20898/* confdefs.h. */
20899_ACEOF
20900cat confdefs.h >>conftest.$ac_ext
20901cat >>conftest.$ac_ext <<_ACEOF
20902/* end confdefs.h. */
973a76b1
DL
20903$ac_includes_default
20904# include <wchar.h>
20905int
20906main ()
20907{
20908mbstate_t x; return sizeof x;
20909 ;
20910 return 0;
20911}
20912_ACEOF
20913rm -f conftest.$ac_objext
20914if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20915 (eval $ac_compile) 2>conftest.er1
973a76b1 20916 ac_status=$?
35996d22
AS
20917 grep -v '^ *+' conftest.er1 >conftest.err
20918 rm -f conftest.er1
20919 cat conftest.err >&5
973a76b1
DL
20920 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20921 (exit $ac_status); } &&
35996d22
AS
20922 { ac_try='test -z "$ac_c_werror_flag"
20923 || test ! -s conftest.err'
20924 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20925 (eval $ac_try) 2>&5
20926 ac_status=$?
20927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20928 (exit $ac_status); }; } &&
20929 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
20930 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20931 (eval $ac_try) 2>&5
20932 ac_status=$?
20933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20934 (exit $ac_status); }; }; then
20935 ac_cv_type_mbstate_t=yes
20936else
20937 echo "$as_me: failed program was:" >&5
19650fd6
AS
20938sed 's/^/| /' conftest.$ac_ext >&5
20939
973a76b1
DL
20940ac_cv_type_mbstate_t=no
20941fi
35996d22 20942rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
20943fi
20944echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
20945echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6
20946 if test $ac_cv_type_mbstate_t = yes; then
20947
20948cat >>confdefs.h <<\_ACEOF
20949#define HAVE_MBSTATE_T 1
20950_ACEOF
20951
20952 else
20953
20954cat >>confdefs.h <<\_ACEOF
20955#define mbstate_t int
20956_ACEOF
20957
20958 fi
20959
22044edf
DL
20960echo "$as_me:$LINENO: checking for C restrict keyword" >&5
20961echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
20962if test "${emacs_cv_c_restrict+set}" = set; then
20963 echo $ECHO_N "(cached) $ECHO_C" >&6
20964else
20965 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20966/* confdefs.h. */
20967_ACEOF
20968cat confdefs.h >>conftest.$ac_ext
20969cat >>conftest.$ac_ext <<_ACEOF
20970/* end confdefs.h. */
22044edf
DL
20971void fred (int *restrict x);
20972int
20973main ()
20974{
b936fae4 20975
22044edf
DL
20976 ;
20977 return 0;
20978}
c0d27fcc 20979_ACEOF
22044edf
DL
20980rm -f conftest.$ac_objext
20981if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20982 (eval $ac_compile) 2>conftest.er1
22044edf 20983 ac_status=$?
35996d22
AS
20984 grep -v '^ *+' conftest.er1 >conftest.err
20985 rm -f conftest.er1
20986 cat conftest.err >&5
22044edf
DL
20987 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20988 (exit $ac_status); } &&
35996d22
AS
20989 { ac_try='test -z "$ac_c_werror_flag"
20990 || test ! -s conftest.err'
20991 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20992 (eval $ac_try) 2>&5
20993 ac_status=$?
20994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20995 (exit $ac_status); }; } &&
20996 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
20997 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20998 (eval $ac_try) 2>&5
20999 ac_status=$?
21000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21001 (exit $ac_status); }; }; then
21002 emacs_cv_c_restrict=yes
21003else
21004 echo "$as_me: failed program was:" >&5
19650fd6
AS
21005sed 's/^/| /' conftest.$ac_ext >&5
21006
22044edf 21007cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21008/* confdefs.h. */
21009_ACEOF
21010cat confdefs.h >>conftest.$ac_ext
21011cat >>conftest.$ac_ext <<_ACEOF
21012/* end confdefs.h. */
22044edf
DL
21013void fred (int *__restrict x);
21014int
21015main ()
21016{
c0d27fcc 21017
22044edf
DL
21018 ;
21019 return 0;
21020}
c0d27fcc 21021_ACEOF
22044edf
DL
21022rm -f conftest.$ac_objext
21023if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21024 (eval $ac_compile) 2>conftest.er1
22044edf 21025 ac_status=$?
35996d22
AS
21026 grep -v '^ *+' conftest.er1 >conftest.err
21027 rm -f conftest.er1
21028 cat conftest.err >&5
22044edf
DL
21029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21030 (exit $ac_status); } &&
35996d22
AS
21031 { ac_try='test -z "$ac_c_werror_flag"
21032 || test ! -s conftest.err'
21033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21034 (eval $ac_try) 2>&5
21035 ac_status=$?
21036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21037 (exit $ac_status); }; } &&
21038 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21039 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21040 (eval $ac_try) 2>&5
21041 ac_status=$?
21042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21043 (exit $ac_status); }; }; then
21044 emacs_cv_c_restrict=__restrict
21045else
21046 echo "$as_me: failed program was:" >&5
19650fd6
AS
21047sed 's/^/| /' conftest.$ac_ext >&5
21048
22044edf 21049emacs_cv_c_restrict=no
ba4481b5 21050fi
35996d22 21051rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21052fi
35996d22 21053rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21054fi
22044edf
DL
21055echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
21056echo "${ECHO_T}$emacs_cv_c_restrict" >&6
21057case "$emacs_cv_c_restrict" in
21058 yes) emacs_restrict=restrict;;
21059 no) emacs_restrict="";;
21060 *) emacs_restrict="$emacs_cv_c_restrict";;
21061esac
21062if test "$emacs_restrict" != __restrict; then
b936fae4 21063
22044edf
DL
21064cat >>confdefs.h <<_ACEOF
21065#define __restrict $emacs_restrict
c0d27fcc 21066_ACEOF
ba4481b5
DL
21067
21068fi
ba4481b5 21069
22044edf
DL
21070echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
21071echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
21072if test "${emacs_cv_c_restrict_arr+set}" = set; then
21073 echo $ECHO_N "(cached) $ECHO_C" >&6
21074else
21075 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21076/* confdefs.h. */
21077_ACEOF
21078cat confdefs.h >>conftest.$ac_ext
21079cat >>conftest.$ac_ext <<_ACEOF
21080/* end confdefs.h. */
22044edf
DL
21081void fred (int x[__restrict]);
21082int
21083main ()
21084{
b936fae4 21085
22044edf
DL
21086 ;
21087 return 0;
21088}
c0d27fcc 21089_ACEOF
22044edf
DL
21090rm -f conftest.$ac_objext
21091if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21092 (eval $ac_compile) 2>conftest.er1
22044edf 21093 ac_status=$?
35996d22
AS
21094 grep -v '^ *+' conftest.er1 >conftest.err
21095 rm -f conftest.er1
21096 cat conftest.err >&5
22044edf
DL
21097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21098 (exit $ac_status); } &&
35996d22
AS
21099 { ac_try='test -z "$ac_c_werror_flag"
21100 || test ! -s conftest.err'
21101 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21102 (eval $ac_try) 2>&5
21103 ac_status=$?
21104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21105 (exit $ac_status); }; } &&
21106 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21107 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21108 (eval $ac_try) 2>&5
21109 ac_status=$?
21110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21111 (exit $ac_status); }; }; then
21112 emacs_cv_c_restrict_arr=yes
21113else
21114 echo "$as_me: failed program was:" >&5
19650fd6
AS
21115sed 's/^/| /' conftest.$ac_ext >&5
21116
22044edf 21117emacs_cv_c_restrict_arr=no
ba4481b5 21118fi
35996d22 21119rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22044edf
DL
21120fi
21121echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
21122echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
21123if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 21124
c0d27fcc 21125cat >>confdefs.h <<\_ACEOF
22044edf 21126#define __restrict_arr __restrict
c0d27fcc 21127_ACEOF
ba4481b5 21128
ba4481b5
DL
21129fi
21130
c0d27fcc 21131
c0d27fcc 21132
22044edf
DL
21133# Set up the CFLAGS for real compilation, so we can substitute it.
21134CFLAGS="$REAL_CFLAGS"
21135CPPFLAGS="$REAL_CPPFLAGS"
21136
21137#### Find out which version of Emacs this is.
21138version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
21139 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
21140if test x"${version}" = x; then
21141 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
21142echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
21143 { (exit 1); exit 1; }; }
21144fi
21145
21146### Specify what sort of things we'll be editing into Makefile and config.h.
21147### Use configuration here uncanonicalized to avoid exceeding size limits.
21148
21149
21150
21151
21152
21153
21154
21155
21156
21157
21158
21159
21160
21161
21162
21163
21164
21165
21166
21167
21168
21169
21170
21171
21172
21173
21174
21175
21176
21177
21178
21179
6a3a24fa 21180
22044edf
DL
21181
21182
21183cat >>confdefs.h <<_ACEOF
21184#define EMACS_CONFIGURATION "${canonical}"
21185_ACEOF
21186
21187
21188cat >>confdefs.h <<_ACEOF
21189#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
21190_ACEOF
21191
21192
21193cat >>confdefs.h <<_ACEOF
21194#define config_machfile "${machfile}"
21195_ACEOF
21196
21197
21198cat >>confdefs.h <<_ACEOF
21199#define config_opsysfile "${opsysfile}"
21200_ACEOF
21201
21202
21203cat >>confdefs.h <<_ACEOF
21204#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
21205_ACEOF
21206
21207
21208cat >>confdefs.h <<_ACEOF
21209#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
21210_ACEOF
21211
21212
21213cat >>confdefs.h <<_ACEOF
21214#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
21215_ACEOF
21216
21217
21218cat >>confdefs.h <<_ACEOF
21219#define UNEXEC_SRC ${UNEXEC_SRC}
21220_ACEOF
21221
21222
21223if test "${HAVE_X_WINDOWS}" = "yes" ; then
21224
21225cat >>confdefs.h <<\_ACEOF
21226#define HAVE_X_WINDOWS 1
21227_ACEOF
21228
21229fi
21230if test "${USE_X_TOOLKIT}" != "none" ; then
21231
21232cat >>confdefs.h <<\_ACEOF
21233#define USE_X_TOOLKIT 1
21234_ACEOF
21235
21236fi
21237if test "${HAVE_X11}" = "yes" ; then
21238
21239cat >>confdefs.h <<\_ACEOF
21240#define HAVE_X11 1
21241_ACEOF
21242
21243fi
21244if test "${HAVE_XFREE386}" = "yes" ; then
21245
21246cat >>confdefs.h <<\_ACEOF
21247#define HAVE_XFREE386 1
21248_ACEOF
21249
21250fi
21251if test "${HAVE_MENUS}" = "yes" ; then
21252
21253cat >>confdefs.h <<\_ACEOF
21254#define HAVE_MENUS 1
21255_ACEOF
21256
21257fi
21258if test "${GNU_MALLOC}" = "yes" ; then
21259
21260cat >>confdefs.h <<\_ACEOF
21261#define GNU_MALLOC 1
21262_ACEOF
21263
21264fi
21265if test "${REL_ALLOC}" = "yes" ; then
21266
21267cat >>confdefs.h <<\_ACEOF
21268#define REL_ALLOC 1
21269_ACEOF
21270
21271fi
21272
21273
21274
c0d27fcc
MR
21275
21276
ba4481b5 21277#### Report on what we decided to do.
488dd4c4
JD
21278#### Report GTK as a toolkit, even if it doesn't use Xt.
21279#### It makes printing result more understandable as using GTK sets
21280#### toolkit_scroll_bars to yes by default.
21281if test "${HAVE_GTK}" = "yes"; then
21282 USE_X_TOOLKIT=GTK
21283fi
21284
ba4481b5
DL
21285echo "
21286Configured for \`${canonical}'.
21287
21288 Where should the build process find the source code? ${srcdir}
21289 What operating system and machine description files should Emacs use?
21290 \`${opsysfile}' and \`${machfile}'
21291 What compiler should emacs be built with? ${CC} ${CFLAGS}
21292 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 21293 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 21294 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 21295 What window system should Emacs use? ${window_system}
8e967cf7 21296 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
21297
21298if test -n "${x_includes}"; then
21299echo " Where do we find X Windows header files? ${x_includes}"
21300else
21301echo " Where do we find X Windows header files? Standard dirs"
21302fi
21303if test -n "${x_libraries}"; then
21304echo " Where do we find X Windows libraries? ${x_libraries}"
21305else
21306echo " Where do we find X Windows libraries? Standard dirs"
21307fi
21308
21309echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
21310echo " Does Emacs use -lXpm? ${HAVE_XPM}"
21311echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
21312echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
21313echo " Does Emacs use -lungif? ${HAVE_GIF}"
21314echo " Does Emacs use -lpng? ${HAVE_PNG}"
21315echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
21316echo
21317
21318# Remove any trailing slashes in these variables.
21319test "${prefix}" != NONE &&
21320 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
21321test "${exec_prefix}" != NONE &&
21322 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
21323
d0e9bfd2
GM
21324## Check if the C preprocessor will convert `..' to `. .'. If so, set
21325## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
21326## from Makefile.c can correctly provide the arg `-traditional' to the
21327## C preprocessor.
21328
503d2be0 21329cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21330/* confdefs.h. */
21331_ACEOF
21332cat confdefs.h >>conftest.$ac_ext
21333cat >>conftest.$ac_ext <<_ACEOF
21334/* end confdefs.h. */
d0e9bfd2 21335yes..yes
503d2be0 21336_ACEOF
d0e9bfd2 21337if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 21338 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
21339 CPP_NEED_TRADITIONAL=no
21340else
d0e9bfd2
GM
21341 CPP_NEED_TRADITIONAL=yes
21342fi
21343rm -f conftest*
21344
c0d27fcc 21345
6bae0ccf
DL
21346 ac_config_files="$ac_config_files Makefile lib-src/Makefile.c:lib-src/Makefile.in oldXMenu/Makefile man/Makefile lwlib/Makefile src/Makefile.c:src/Makefile.in lisp/Makefile lispref/Makefile lispintro/Makefile leim/Makefile"
21347 ac_config_commands="$ac_config_commands default"
503d2be0 21348cat >confcache <<\_ACEOF
ba4481b5
DL
21349# This file is a shell script that caches the results of configure
21350# tests run on this system so they can be shared between configure
503d2be0
AS
21351# scripts and configure runs, see configure's option --config-cache.
21352# It is not useful on other systems. If it contains results you don't
21353# want to keep, you may remove or edit it.
ba4481b5 21354#
503d2be0
AS
21355# config.status only pays attention to the cache file if you give it
21356# the --recheck option to rerun configure.
ba4481b5 21357#
6bae0ccf 21358# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
21359# loading this file, other *unset* `ac_cv_foo' will be assigned the
21360# following values.
21361
21362_ACEOF
21363
ba4481b5
DL
21364# The following way of writing the cache mishandles newlines in values,
21365# but we know of no workaround that is simple, portable, and efficient.
21366# So, don't put newlines in cache variables' values.
21367# Ultrix sh set writes to stderr and can't be redirected directly,
21368# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
21369{
21370 (set) 2>&1 |
21371 case `(ac_space=' '; set | grep ac_space) 2>&1` in
21372 *ac_space=\ *)
21373 # `set' does not quote correctly, so add quotes (double-quote
21374 # substitution turns \\\\ into \\, and sed turns \\ into \).
21375 sed -n \
35996d22
AS
21376 "s/'/'\\\\''/g;
21377 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
503d2be0
AS
21378 ;;
21379 *)
21380 # `set' quotes correctly as required by POSIX, so do not add quotes.
21381 sed -n \
35996d22 21382 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
21383 ;;
21384 esac;
21385} |
21386 sed '
21387 t clear
21388 : clear
21389 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21390 t end
21391 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21392 : end' >>confcache
19650fd6 21393if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 21394 if test -w $cache_file; then
503d2be0
AS
21395 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
21396 cat confcache >$cache_file
ba4481b5
DL
21397 else
21398 echo "not updating unwritable cache $cache_file"
21399 fi
21400fi
21401rm -f confcache
21402
ba4481b5
DL
21403test "x$prefix" = xNONE && prefix=$ac_default_prefix
21404# Let make expand exec_prefix.
21405test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21406
503d2be0
AS
21407# VPATH may cause trouble with some makes, so we remove $(srcdir),
21408# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
21409# trailing colons and then remove the whole line if VPATH becomes empty
21410# (actually we leave an empty line to preserve line numbers).
ba4481b5 21411if test "x$srcdir" = x.; then
35996d22 21412 ac_vpsub='/^[ ]*VPATH[ ]*=/{
503d2be0
AS
21413s/:*\$(srcdir):*/:/;
21414s/:*\${srcdir}:*/:/;
21415s/:*@srcdir@:*/:/;
35996d22 21416s/^\([^=]*=[ ]*\):*/\1/;
503d2be0 21417s/:*$//;
35996d22 21418s/^[^=]*=[ ]*$//;
503d2be0 21419}'
ba4481b5
DL
21420fi
21421
ba4481b5
DL
21422DEFS=-DHAVE_CONFIG_H
21423
6bae0ccf
DL
21424ac_libobjs=
21425ac_ltlibobjs=
21426for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21427 # 1. Remove the extension, and $U if already installed.
21428 ac_i=`echo "$ac_i" |
35996d22 21429 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
6bae0ccf
DL
21430 # 2. Add them.
21431 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
21432 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
21433done
21434LIBOBJS=$ac_libobjs
21435
21436LTLIBOBJS=$ac_ltlibobjs
21437
21438
c0d27fcc 21439
ba4481b5 21440: ${CONFIG_STATUS=./config.status}
503d2be0
AS
21441ac_clean_files_save=$ac_clean_files
21442ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 21443{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
21444echo "$as_me: creating $CONFIG_STATUS" >&6;}
21445cat >$CONFIG_STATUS <<_ACEOF
21446#! $SHELL
c0d27fcc 21447# Generated by $as_me.
ba4481b5 21448# Run this file to recreate the current configuration.
ba4481b5 21449# Compiler output produced by configure, useful for debugging
503d2be0 21450# configure, is in config.log if it exists.
ba4481b5 21451
503d2be0 21452debug=false
19650fd6
AS
21453ac_cs_recheck=false
21454ac_cs_silent=false
503d2be0 21455SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
21456_ACEOF
21457
21458cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
21459## --------------------- ##
21460## M4sh Initialization. ##
21461## --------------------- ##
21462
503d2be0
AS
21463# Be Bourne compatible
21464if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
21465 emulate sh
21466 NULLCMD=:
6bae0ccf
DL
21467 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21468 # is contrary to our usage. Disable this feature.
21469 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
21470elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21471 set -o posix
21472fi
35996d22 21473DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 21474
c0d27fcc 21475# Support unset when possible.
35996d22 21476if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
21477 as_unset=unset
21478else
21479 as_unset=false
21480fi
21481
6bae0ccf
DL
21482
21483# Work around bugs in pre-3.0 UWIN ksh.
21484$as_unset ENV MAIL MAILPATH
21485PS1='$ '
21486PS2='> '
21487PS4='+ '
21488
21489# NLS nuisances.
19650fd6
AS
21490for as_var in \
21491 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
21492 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
21493 LC_TELEPHONE LC_TIME
6bae0ccf 21494do
35996d22 21495 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
21496 eval $as_var=C; export $as_var
21497 else
21498 $as_unset $as_var
21499 fi
21500done
21501
21502# Required to use basename.
21503if expr a : '\(a\)' >/dev/null 2>&1; then
21504 as_expr=expr
21505else
21506 as_expr=false
21507fi
21508
21509if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
21510 as_basename=basename
21511else
21512 as_basename=false
21513fi
c0d27fcc
MR
21514
21515
503d2be0 21516# Name of the executable.
6bae0ccf 21517as_me=`$as_basename "$0" ||
c0d27fcc
MR
21518$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21519 X"$0" : 'X\(//\)$' \| \
21520 X"$0" : 'X\(/\)$' \| \
21521 . : '\(.\)' 2>/dev/null ||
21522echo X/"$0" |
21523 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
21524 /^X\/\(\/\/\)$/{ s//\1/; q; }
21525 /^X\/\(\/\).*/{ s//\1/; q; }
21526 s/.*/./; q'`
21527
6bae0ccf 21528
c0d27fcc
MR
21529# PATH needs CR, and LINENO needs CR and PATH.
21530# Avoid depending upon Character Ranges.
21531as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21532as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21533as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21534as_cr_digits='0123456789'
21535as_cr_alnum=$as_cr_Letters$as_cr_digits
21536
21537# The user is always right.
21538if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
21539 echo "#! /bin/sh" >conf$$.sh
21540 echo "exit 0" >>conf$$.sh
21541 chmod +x conf$$.sh
21542 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
21543 PATH_SEPARATOR=';'
21544 else
21545 PATH_SEPARATOR=:
21546 fi
19650fd6 21547 rm -f conf$$.sh
c0d27fcc
MR
21548fi
21549
21550
21551 as_lineno_1=$LINENO
21552 as_lineno_2=$LINENO
21553 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21554 test "x$as_lineno_1" != "x$as_lineno_2" &&
21555 test "x$as_lineno_3" = "x$as_lineno_2" || {
21556 # Find who we are. Look in the path if we contain no path at all
21557 # relative or not.
21558 case $0 in
21559 *[\\/]* ) as_myself=$0 ;;
21560 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21561for as_dir in $PATH
21562do
21563 IFS=$as_save_IFS
21564 test -z "$as_dir" && as_dir=.
21565 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21566done
21567
21568 ;;
21569 esac
21570 # We did not find ourselves, most probably we were run as `sh COMMAND'
21571 # in which case we are not to be found in the path.
21572 if test "x$as_myself" = x; then
21573 as_myself=$0
21574 fi
21575 if test ! -f "$as_myself"; then
21576 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
21577echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
21578 { (exit 1); exit 1; }; }
21579 fi
21580 case $CONFIG_SHELL in
21581 '')
21582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21583for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
21584do
21585 IFS=$as_save_IFS
21586 test -z "$as_dir" && as_dir=.
21587 for as_base in sh bash ksh sh5; do
21588 case $as_dir in
21589 /*)
21590 if ("$as_dir/$as_base" -c '
21591 as_lineno_1=$LINENO
21592 as_lineno_2=$LINENO
21593 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21594 test "x$as_lineno_1" != "x$as_lineno_2" &&
21595 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
21596 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
21597 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
21598 CONFIG_SHELL=$as_dir/$as_base
21599 export CONFIG_SHELL
21600 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
21601 fi;;
21602 esac
21603 done
21604done
21605;;
21606 esac
21607
21608 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
21609 # uniformly replaced by the line number. The first 'sed' inserts a
21610 # line-number line before each line; the second 'sed' does the real
21611 # work. The second script uses 'N' to pair each line-number line
21612 # with the numbered line, and appends trailing '-' during
21613 # substitution so that $LINENO is not a special case at line end.
21614 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
21615 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
21616 sed '=' <$as_myself |
21617 sed '
21618 N
21619 s,$,-,
21620 : loop
21621 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
21622 t loop
21623 s,-$,,
21624 s,^['$as_cr_digits']*\n,,
21625 ' >$as_me.lineno &&
21626 chmod +x $as_me.lineno ||
21627 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
21628echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
21629 { (exit 1); exit 1; }; }
21630
21631 # Don't try to exec as it changes $[0], causing all sort of problems
21632 # (the dirname of $[0] is not the place where we might find the
21633 # original and so on. Autoconf is especially sensible to this).
21634 . ./$as_me.lineno
21635 # Exit status is that of the last command.
21636 exit
21637}
21638
21639
21640case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
21641 *c*,-n*) ECHO_N= ECHO_C='
21642' ECHO_T=' ' ;;
21643 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
21644 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
21645esac
503d2be0
AS
21646
21647if expr a : '\(a\)' >/dev/null 2>&1; then
21648 as_expr=expr
21649else
21650 as_expr=false
21651fi
21652
21653rm -f conf$$ conf$$.exe conf$$.file
21654echo >conf$$.file
21655if ln -s conf$$.file conf$$ 2>/dev/null; then
21656 # We could just check for DJGPP; but this test a) works b) is more generic
21657 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
21658 if test -f conf$$.exe; then
21659 # Don't use ln at all; we don't have any links
21660 as_ln_s='cp -p'
21661 else
21662 as_ln_s='ln -s'
21663 fi
21664elif ln conf$$.file conf$$ 2>/dev/null; then
21665 as_ln_s=ln
21666else
21667 as_ln_s='cp -p'
21668fi
21669rm -f conf$$ conf$$.exe conf$$.file
21670
6bae0ccf
DL
21671if mkdir -p . 2>/dev/null; then
21672 as_mkdir_p=:
21673else
35996d22 21674 test -d ./-p && rmdir ./-p
6bae0ccf
DL
21675 as_mkdir_p=false
21676fi
21677
503d2be0
AS
21678as_executable_p="test -f"
21679
c0d27fcc 21680# Sed expression to map a string onto a valid CPP name.
35996d22 21681as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
21682
21683# Sed expression to map a string onto a valid variable name.
35996d22 21684as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 21685
503d2be0
AS
21686
21687# IFS
21688# We need space, tab and new line, in precisely that order.
21689as_nl='
21690'
21691IFS=" $as_nl"
21692
21693# CDPATH.
6bae0ccf 21694$as_unset CDPATH
503d2be0
AS
21695
21696exec 6>&1
21697
c0d27fcc
MR
21698# Open the log real soon, to keep \$[0] and so on meaningful, and to
21699# report actual input values of CONFIG_FILES etc. instead of their
21700# values after options handling. Logging --version etc. is OK.
21701exec 5>>config.log
21702{
21703 echo
21704 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
21705## Running $as_me. ##
21706_ASBOX
21707} >&5
21708cat >&5 <<_CSEOF
21709
21710This file was extended by $as_me, which was
35996d22 21711generated by GNU Autoconf 2.59. Invocation command line was
c0d27fcc
MR
21712
21713 CONFIG_FILES = $CONFIG_FILES
21714 CONFIG_HEADERS = $CONFIG_HEADERS
21715 CONFIG_LINKS = $CONFIG_LINKS
21716 CONFIG_COMMANDS = $CONFIG_COMMANDS
21717 $ $0 $@
21718
21719_CSEOF
21720echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
21721echo >&5
503d2be0
AS
21722_ACEOF
21723
21724# Files that config.status was made for.
21725if test -n "$ac_config_files"; then
21726 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
21727fi
21728
21729if test -n "$ac_config_headers"; then
21730 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
21731fi
21732
21733if test -n "$ac_config_links"; then
21734 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
21735fi
21736
21737if test -n "$ac_config_commands"; then
21738 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
21739fi
21740
c0d27fcc 21741cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21742
21743ac_cs_usage="\
21744\`$as_me' instantiates files from templates according to the
21745current configuration.
21746
21747Usage: $0 [OPTIONS] [FILE]...
21748
21749 -h, --help print this help, then exit
21750 -V, --version print version number, then exit
19650fd6 21751 -q, --quiet do not print progress messages
503d2be0
AS
21752 -d, --debug don't remove temporary files
21753 --recheck update $as_me by reconfiguring in the same conditions
21754 --file=FILE[:TEMPLATE]
35996d22 21755 instantiate the configuration file FILE
503d2be0 21756 --header=FILE[:TEMPLATE]
35996d22 21757 instantiate the configuration header FILE
503d2be0
AS
21758
21759Configuration files:
21760$config_files
21761
21762Configuration headers:
21763$config_headers
21764
21765Configuration commands:
21766$config_commands
21767
21768Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 21769_ACEOF
503d2be0 21770
c0d27fcc 21771cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21772ac_cs_version="\\
21773config.status
35996d22 21774configured by $0, generated by GNU Autoconf 2.59,
503d2be0
AS
21775 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
21776
35996d22 21777Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
21778This config.status script is free software; the Free Software Foundation
21779gives unlimited permission to copy, distribute and modify it."
21780srcdir=$srcdir
21781INSTALL="$INSTALL"
c0d27fcc 21782_ACEOF
503d2be0 21783
c0d27fcc 21784cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21785# If no file are specified by the user, then we need to provide default
21786# value. By we need to know if files were specified by the user.
21787ac_need_defaults=:
21788while test $# != 0
ba4481b5 21789do
503d2be0
AS
21790 case $1 in
21791 --*=*)
21792 ac_option=`expr "x$1" : 'x\([^=]*\)='`
21793 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
21794 ac_shift=:
21795 ;;
21796 -*)
21797 ac_option=$1
21798 ac_optarg=$2
21799 ac_shift=shift
503d2be0 21800 ;;
503d2be0
AS
21801 *) # This is not an option, so the user has probably given explicit
21802 # arguments.
6bae0ccf 21803 ac_option=$1
503d2be0
AS
21804 ac_need_defaults=false;;
21805 esac
21806
6bae0ccf 21807 case $ac_option in
503d2be0 21808 # Handling of the options.
c0d27fcc 21809_ACEOF
f57bd967 21810cat >>$CONFIG_STATUS <<\_ACEOF
19650fd6
AS
21811 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
21812 ac_cs_recheck=: ;;
503d2be0
AS
21813 --version | --vers* | -V )
21814 echo "$ac_cs_version"; exit 0 ;;
21815 --he | --h)
21816 # Conflict between --help and --header
c0d27fcc 21817 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
21818Try \`$0 --help' for more information." >&5
21819echo "$as_me: error: ambiguous option: $1
21820Try \`$0 --help' for more information." >&2;}
21821 { (exit 1); exit 1; }; };;
21822 --help | --hel | -h )
21823 echo "$ac_cs_usage"; exit 0 ;;
21824 --debug | --d* | -d )
21825 debug=: ;;
21826 --file | --fil | --fi | --f )
6bae0ccf
DL
21827 $ac_shift
21828 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
21829 ac_need_defaults=false;;
21830 --header | --heade | --head | --hea )
6bae0ccf
DL
21831 $ac_shift
21832 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 21833 ac_need_defaults=false;;
19650fd6
AS
21834 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
21835 | -silent | --silent | --silen | --sile | --sil | --si | --s)
21836 ac_cs_silent=: ;;
503d2be0
AS
21837
21838 # This is an error.
c0d27fcc 21839 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
21840Try \`$0 --help' for more information." >&5
21841echo "$as_me: error: unrecognized option: $1
21842Try \`$0 --help' for more information." >&2;}
21843 { (exit 1); exit 1; }; } ;;
21844
21845 *) ac_config_targets="$ac_config_targets $1" ;;
21846
ba4481b5 21847 esac
503d2be0 21848 shift
ba4481b5
DL
21849done
21850
19650fd6
AS
21851ac_configure_extra_args=
21852
21853if $ac_cs_silent; then
21854 exec 6>/dev/null
21855 ac_configure_extra_args="$ac_configure_extra_args --silent"
21856fi
21857
21858_ACEOF
21859cat >>$CONFIG_STATUS <<_ACEOF
21860if \$ac_cs_recheck; then
21861 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
21862 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
21863fi
21864
503d2be0 21865_ACEOF
ba4481b5 21866
c0d27fcc 21867cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21868#
21869# INIT-COMMANDS section.
21870#
ba4481b5 21871
503d2be0
AS
21872GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
21873
c0d27fcc
MR
21874_ACEOF
21875
503d2be0 21876
c0d27fcc
MR
21877
21878cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21879for ac_config_target in $ac_config_targets
21880do
21881 case "$ac_config_target" in
21882 # Handling of arguments.
21883 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
21884 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
21885 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
21886 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
21887 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
21888 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
21889 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 21890 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 21891 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
21892 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
21893 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
21894 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 21895 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
21896echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
21897 { (exit 1); exit 1; }; };;
21898 esac
ba4481b5 21899done
503d2be0
AS
21900
21901# If the user did not use the arguments to specify the items to instantiate,
21902# then the envvar interface is used. Set only those that are not.
21903# We use the long form for the default assignment because of an extremely
21904# bizarre bug on SunOS 4.1.3.
21905if $ac_need_defaults; then
21906 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
21907 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
21908 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 21909fi
503d2be0 21910
19650fd6
AS
21911# Have a temporary directory for convenience. Make it in the build tree
21912# simply because there is no reason to put it here, and in addition,
21913# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
21914# Create a temporary directory, and hook for its removal unless debugging.
21915$debug ||
21916{
21917 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
21918 trap '{ (exit 1); exit 1; }' 1 2 13 15
21919}
21920
21921# Create a (secure) tmp directory for tmp files.
19650fd6 21922
503d2be0 21923{
19650fd6 21924 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
21925 test -n "$tmp" && test -d "$tmp"
21926} ||
21927{
19650fd6 21928 tmp=./confstat$$-$RANDOM
503d2be0
AS
21929 (umask 077 && mkdir $tmp)
21930} ||
21931{
19650fd6 21932 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
21933 { (exit 1); exit 1; }
21934}
21935
c0d27fcc 21936_ACEOF
503d2be0 21937
c0d27fcc 21938cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21939
21940#
21941# CONFIG_FILES section.
21942#
21943
21944# No need to generate the scripts if there are no CONFIG_FILES.
21945# This happens for instance when ./config.status config.h
21946if test -n "\$CONFIG_FILES"; then
21947 # Protect against being on the right side of a sed subst in config.status.
21948 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
21949 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
21950s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
21951s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
21952s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
21953s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
21954s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
21955s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
21956s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
21957s,@exec_prefix@,$exec_prefix,;t t
21958s,@prefix@,$prefix,;t t
21959s,@program_transform_name@,$program_transform_name,;t t
21960s,@bindir@,$bindir,;t t
21961s,@sbindir@,$sbindir,;t t
21962s,@libexecdir@,$libexecdir,;t t
21963s,@datadir@,$datadir,;t t
21964s,@sysconfdir@,$sysconfdir,;t t
21965s,@sharedstatedir@,$sharedstatedir,;t t
21966s,@localstatedir@,$localstatedir,;t t
21967s,@libdir@,$libdir,;t t
21968s,@includedir@,$includedir,;t t
21969s,@oldincludedir@,$oldincludedir,;t t
21970s,@infodir@,$infodir,;t t
21971s,@mandir@,$mandir,;t t
503d2be0
AS
21972s,@build_alias@,$build_alias,;t t
21973s,@host_alias@,$host_alias,;t t
21974s,@target_alias@,$target_alias,;t t
c0d27fcc 21975s,@DEFS@,$DEFS,;t t
503d2be0
AS
21976s,@ECHO_C@,$ECHO_C,;t t
21977s,@ECHO_N@,$ECHO_N,;t t
21978s,@ECHO_T@,$ECHO_T,;t t
503d2be0 21979s,@LIBS@,$LIBS,;t t
19650fd6 21980s,@MAINT@,$MAINT,;t t
503d2be0
AS
21981s,@build@,$build,;t t
21982s,@build_cpu@,$build_cpu,;t t
21983s,@build_vendor@,$build_vendor,;t t
21984s,@build_os@,$build_os,;t t
21985s,@host@,$host,;t t
21986s,@host_cpu@,$host_cpu,;t t
21987s,@host_vendor@,$host_vendor,;t t
21988s,@host_os@,$host_os,;t t
21989s,@CC@,$CC,;t t
21990s,@CFLAGS@,$CFLAGS,;t t
21991s,@LDFLAGS@,$LDFLAGS,;t t
21992s,@CPPFLAGS@,$CPPFLAGS,;t t
21993s,@ac_ct_CC@,$ac_ct_CC,;t t
21994s,@EXEEXT@,$EXEEXT,;t t
21995s,@OBJEXT@,$OBJEXT,;t t
21996s,@LN_S@,$LN_S,;t t
21997s,@CPP@,$CPP,;t t
21998s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
21999s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
22000s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
22001s,@RANLIB@,$RANLIB,;t t
22002s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 22003s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 22004s,@EGREP@,$EGREP,;t t
503d2be0
AS
22005s,@LIBSOUND@,$LIBSOUND,;t t
22006s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
22007s,@PKG_CONFIG@,$PKG_CONFIG,;t t
22008s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
22009s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
22010s,@ALLOCA@,$ALLOCA,;t t
22011s,@liblockfile@,$liblockfile,;t t
22012s,@LIBOBJS@,$LIBOBJS,;t t
22013s,@NEED_SETGID@,$NEED_SETGID,;t t
22014s,@KMEM_GROUP@,$KMEM_GROUP,;t t
22015s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
22016s,@version@,$version,;t t
22017s,@configuration@,$configuration,;t t
22018s,@canonical@,$canonical,;t t
22019s,@srcdir@,$srcdir,;t t
22020s,@lispdir@,$lispdir,;t t
22021s,@locallisppath@,$locallisppath,;t t
22022s,@lisppath@,$lisppath,;t t
22023s,@x_default_search_path@,$x_default_search_path,;t t
22024s,@etcdir@,$etcdir,;t t
22025s,@archlibdir@,$archlibdir,;t t
22026s,@docdir@,$docdir,;t t
22027s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
22028s,@gamedir@,$gamedir,;t t
22029s,@gameuser@,$gameuser,;t t
503d2be0
AS
22030s,@c_switch_system@,$c_switch_system,;t t
22031s,@c_switch_machine@,$c_switch_machine,;t t
22032s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
22033s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
22034s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
22035s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
22036s,@machfile@,$machfile,;t t
22037s,@opsysfile@,$opsysfile,;t t
6a3a24fa 22038s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 22039s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
22040CEOF
22041
c0d27fcc 22042_ACEOF
ba4481b5 22043
c0d27fcc 22044 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22045 # Split the substitutions into bite-sized pieces for seds with
22046 # small command number limits, like on Digital OSF/1 and HP-UX.
22047 ac_max_sed_lines=48
22048 ac_sed_frag=1 # Number of current file.
22049 ac_beg=1 # First line for current file.
22050 ac_end=$ac_max_sed_lines # Line after last line for current file.
22051 ac_more_lines=:
22052 ac_sed_cmds=
22053 while $ac_more_lines; do
22054 if test $ac_beg -gt 1; then
22055 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22056 else
22057 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22058 fi
22059 if test ! -s $tmp/subs.frag; then
22060 ac_more_lines=false
22061 else
22062 # The purpose of the label and of the branching condition is to
22063 # speed up the sed processing (if there are no `@' at all, there
22064 # is no need to browse any of the substitutions).
22065 # These are the two extra sed commands mentioned above.
22066 (echo ':t
22067 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22068 if test -z "$ac_sed_cmds"; then
35996d22 22069 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0 22070 else
35996d22 22071 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0
AS
22072 fi
22073 ac_sed_frag=`expr $ac_sed_frag + 1`
22074 ac_beg=$ac_end
22075 ac_end=`expr $ac_end + $ac_max_sed_lines`
22076 fi
22077 done
22078 if test -z "$ac_sed_cmds"; then
22079 ac_sed_cmds=cat
22080 fi
22081fi # test -n "$CONFIG_FILES"
ba4481b5 22082
c0d27fcc
MR
22083_ACEOF
22084cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 22085for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 22086 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22087 case $ac_file in
22088 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22089 cat >$tmp/stdin
22090 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22091 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22092 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22093 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22094 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22095 esac
22096
503d2be0 22097 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
22098 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22099$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22100 X"$ac_file" : 'X\(//\)[^/]' \| \
22101 X"$ac_file" : 'X\(//\)$' \| \
22102 X"$ac_file" : 'X\(/\)' \| \
22103 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22104echo X"$ac_file" |
22105 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22106 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22107 /^X\(\/\/\)$/{ s//\1/; q; }
22108 /^X\(\/\).*/{ s//\1/; q; }
22109 s/.*/./; q'`
6bae0ccf
DL
22110 { if $as_mkdir_p; then
22111 mkdir -p "$ac_dir"
22112 else
22113 as_dir="$ac_dir"
22114 as_dirs=
22115 while test ! -d "$as_dir"; do
22116 as_dirs="$as_dir $as_dirs"
22117 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22118$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22119 X"$as_dir" : 'X\(//\)[^/]' \| \
22120 X"$as_dir" : 'X\(//\)$' \| \
22121 X"$as_dir" : 'X\(/\)' \| \
22122 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22123echo X"$as_dir" |
22124 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22125 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22126 /^X\(\/\/\)$/{ s//\1/; q; }
22127 /^X\(\/\).*/{ s//\1/; q; }
22128 s/.*/./; q'`
22129 done
22130 test ! -n "$as_dirs" || mkdir $as_dirs
22131 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22132echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22133 { (exit 1); exit 1; }; }; }
503d2be0 22134
c0d27fcc 22135 ac_builddir=.
98418dba 22136
c0d27fcc
MR
22137if test "$ac_dir" != .; then
22138 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22139 # A "../" for each directory in $ac_dir_suffix.
22140 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22141else
22142 ac_dir_suffix= ac_top_builddir=
22143fi
22144
22145case $srcdir in
22146 .) # No --srcdir option. We are building in place.
22147 ac_srcdir=.
22148 if test -z "$ac_top_builddir"; then
22149 ac_top_srcdir=.
22150 else
22151 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22152 fi ;;
22153 [\\/]* | ?:[\\/]* ) # Absolute path.
22154 ac_srcdir=$srcdir$ac_dir_suffix;
22155 ac_top_srcdir=$srcdir ;;
ba4481b5 22156 *) # Relative path.
c0d27fcc
MR
22157 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22158 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22159esac
35996d22
AS
22160
22161# Do not use `cd foo && pwd` to compute absolute paths, because
22162# the directories may not exist.
22163case `pwd` in
22164.) ac_abs_builddir="$ac_dir";;
22165*)
22166 case "$ac_dir" in
22167 .) ac_abs_builddir=`pwd`;;
22168 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22169 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22170 esac;;
22171esac
22172case $ac_abs_builddir in
22173.) ac_abs_top_builddir=${ac_top_builddir}.;;
22174*)
22175 case ${ac_top_builddir}. in
22176 .) ac_abs_top_builddir=$ac_abs_builddir;;
22177 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22178 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22179 esac;;
22180esac
22181case $ac_abs_builddir in
22182.) ac_abs_srcdir=$ac_srcdir;;
22183*)
22184 case $ac_srcdir in
22185 .) ac_abs_srcdir=$ac_abs_builddir;;
22186 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22187 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22188 esac;;
22189esac
22190case $ac_abs_builddir in
22191.) ac_abs_top_srcdir=$ac_top_srcdir;;
22192*)
22193 case $ac_top_srcdir in
22194 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22195 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22196 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22197 esac;;
22198esac
c0d27fcc 22199
ba4481b5 22200
503d2be0
AS
22201 case $INSTALL in
22202 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 22203 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
22204 esac
22205
503d2be0 22206 if test x"$ac_file" != x-; then
c0d27fcc 22207 { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
22208echo "$as_me: creating $ac_file" >&6;}
22209 rm -f "$ac_file"
22210 fi
22211 # Let's still pretend it is `configure' which instantiates (i.e., don't
22212 # use $as_me), people would be surprised to read:
c0d27fcc
MR
22213 # /* config.h. Generated by config.status. */
22214 if test x"$ac_file" = x-; then
22215 configure_input=
22216 else
22217 configure_input="$ac_file. "
22218 fi
22219 configure_input=$configure_input"Generated from `echo $ac_file_in |
35996d22 22220 sed 's,.*/,,'` by configure."
503d2be0
AS
22221
22222 # First look for the input files in the build tree, otherwise in the
22223 # src tree.
22224 ac_file_inputs=`IFS=:
22225 for f in $ac_file_in; do
22226 case $f in
22227 -) echo $tmp/stdin ;;
22228 [\\/$]*)
35996d22
AS
22229 # Absolute (can't be DOS-style, as IFS=:)
22230 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22231echo "$as_me: error: cannot find input file: $f" >&2;}
22232 { (exit 1); exit 1; }; }
35996d22 22233 echo "$f";;
503d2be0 22234 *) # Relative
35996d22
AS
22235 if test -f "$f"; then
22236 # Build tree
22237 echo "$f"
22238 elif test -f "$srcdir/$f"; then
22239 # Source tree
22240 echo "$srcdir/$f"
22241 else
22242 # /dev/null tree
22243 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22244echo "$as_me: error: cannot find input file: $f" >&2;}
22245 { (exit 1); exit 1; }; }
35996d22 22246 fi;;
503d2be0
AS
22247 esac
22248 done` || { (exit 1); exit 1; }
c0d27fcc
MR
22249_ACEOF
22250cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
22251 sed "$ac_vpsub
22252$extrasub
c0d27fcc
MR
22253_ACEOF
22254cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22255:t
22256/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22257s,@configure_input@,$configure_input,;t t
22258s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 22259s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 22260s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
22261s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
22262s,@builddir@,$ac_builddir,;t t
22263s,@abs_builddir@,$ac_abs_builddir,;t t
22264s,@top_builddir@,$ac_top_builddir,;t t
22265s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
22266s,@INSTALL@,$ac_INSTALL,;t t
22267" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
22268 rm -f $tmp/stdin
22269 if test x"$ac_file" != x-; then
22270 mv $tmp/out $ac_file
22271 else
22272 cat $tmp/out
22273 rm -f $tmp/out
22274 fi
22275
22276done
c0d27fcc
MR
22277_ACEOF
22278cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22279
503d2be0
AS
22280#
22281# CONFIG_HEADER section.
22282#
ba4481b5
DL
22283
22284# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
22285# NAME is the cpp macro being defined and VALUE is the value it is being given.
22286#
22287# ac_d sets the value in "#define NAME VALUE" lines.
35996d22
AS
22288ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
22289ac_dB='[ ].*$,\1#\2'
503d2be0
AS
22290ac_dC=' '
22291ac_dD=',;t'
22292# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
35996d22 22293ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
503d2be0 22294ac_uB='$,\1#\2define\3'
ba4481b5 22295ac_uC=' '
503d2be0 22296ac_uD=',;t'
ba4481b5 22297
503d2be0 22298for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 22299 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22300 case $ac_file in
22301 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22302 cat >$tmp/stdin
22303 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22304 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22305 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22306 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22307 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22308 esac
22309
c0d27fcc 22310 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
22311echo "$as_me: creating $ac_file" >&6;}
22312
22313 # First look for the input files in the build tree, otherwise in the
22314 # src tree.
22315 ac_file_inputs=`IFS=:
22316 for f in $ac_file_in; do
22317 case $f in
22318 -) echo $tmp/stdin ;;
22319 [\\/$]*)
35996d22
AS
22320 # Absolute (can't be DOS-style, as IFS=:)
22321 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22322echo "$as_me: error: cannot find input file: $f" >&2;}
22323 { (exit 1); exit 1; }; }
35996d22
AS
22324 # Do quote $f, to prevent DOS paths from being IFS'd.
22325 echo "$f";;
503d2be0 22326 *) # Relative
35996d22
AS
22327 if test -f "$f"; then
22328 # Build tree
22329 echo "$f"
22330 elif test -f "$srcdir/$f"; then
22331 # Source tree
22332 echo "$srcdir/$f"
22333 else
22334 # /dev/null tree
22335 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22336echo "$as_me: error: cannot find input file: $f" >&2;}
22337 { (exit 1); exit 1; }; }
35996d22 22338 fi;;
503d2be0
AS
22339 esac
22340 done` || { (exit 1); exit 1; }
22341 # Remove the trailing spaces.
35996d22 22342 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
503d2be0 22343
c0d27fcc 22344_ACEOF
503d2be0
AS
22345
22346# Transform confdefs.h into two sed scripts, `conftest.defines' and
22347# `conftest.undefs', that substitutes the proper values into
22348# config.h.in to produce config.h. The first handles `#define'
22349# templates, and the second `#undef' templates.
22350# And first: Protect against being on the right side of a sed subst in
22351# config.status. Protect against being in an unquoted here document
22352# in config.status.
22353rm -f conftest.defines conftest.undefs
22354# Using a here document instead of a string reduces the quoting nightmare.
22355# Putting comments in sed scripts is not portable.
22356#
22357# `end' is used to avoid that the second main sed command (meant for
22358# 0-ary CPP macros) applies to n-ary macro definitions.
22359# See the Autoconf documentation for `clear'.
c0d27fcc 22360cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
22361s/[\\&,]/\\&/g
22362s,[\\$`],\\&,g
22363t clear
22364: clear
35996d22 22365s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0 22366t end
35996d22 22367s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
503d2be0 22368: end
c0d27fcc 22369_ACEOF
503d2be0
AS
22370# If some macros were called several times there might be several times
22371# the same #defines, which is useless. Nevertheless, we may not want to
22372# sort them, since we want the *last* AC-DEFINE to be honored.
22373uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
22374sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
22375rm -f confdef2sed.sed
ba4481b5
DL
22376
22377# This sed command replaces #undef with comments. This is necessary, for
22378# example, in the case of _POSIX_SOURCE, which is predefined and required
22379# on some systems where configure will not decide to define it.
c0d27fcc 22380cat >>conftest.undefs <<\_ACEOF
35996d22 22381s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 22382_ACEOF
ba4481b5 22383
503d2be0
AS
22384# Break up conftest.defines because some shells have a limit on the size
22385# of here documents, and old seds have small limits too (100 cmds).
22386echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
35996d22 22387echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
22388echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
22389echo ' :' >>$CONFIG_STATUS
22390rm -f conftest.tail
22391while grep . conftest.defines >/dev/null
22392do
22393 # Write a limited-size here document to $tmp/defines.sed.
22394 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
22395 # Speed up: don't consider the non `#define' lines.
35996d22 22396 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
503d2be0
AS
22397 # Work around the forget-to-reset-the-flag bug.
22398 echo 't clr' >>$CONFIG_STATUS
22399 echo ': clr' >>$CONFIG_STATUS
22400 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
22401 echo 'CEOF
22402 sed -f $tmp/defines.sed $tmp/in >$tmp/out
22403 rm -f $tmp/in
22404 mv $tmp/out $tmp/in
22405' >>$CONFIG_STATUS
22406 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
22407 rm -f conftest.defines
22408 mv conftest.tail conftest.defines
22409done
22410rm -f conftest.defines
6bae0ccf 22411echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 22412echo >>$CONFIG_STATUS
ba4481b5 22413
503d2be0
AS
22414# Break up conftest.undefs because some shells have a limit on the size
22415# of here documents, and old seds have small limits too (100 cmds).
22416echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 22417rm -f conftest.tail
503d2be0 22418while grep . conftest.undefs >/dev/null
ba4481b5 22419do
503d2be0
AS
22420 # Write a limited-size here document to $tmp/undefs.sed.
22421 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
22422 # Speed up: don't consider the non `#undef'
35996d22 22423 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
503d2be0
AS
22424 # Work around the forget-to-reset-the-flag bug.
22425 echo 't clr' >>$CONFIG_STATUS
22426 echo ': clr' >>$CONFIG_STATUS
22427 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 22428 echo 'CEOF
503d2be0
AS
22429 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
22430 rm -f $tmp/in
22431 mv $tmp/out $tmp/in
22432' >>$CONFIG_STATUS
22433 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
22434 rm -f conftest.undefs
22435 mv conftest.tail conftest.undefs
ba4481b5 22436done
503d2be0
AS
22437rm -f conftest.undefs
22438
c0d27fcc 22439cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22440 # Let's still pretend it is `configure' which instantiates (i.e., don't
22441 # use $as_me), people would be surprised to read:
c0d27fcc 22442 # /* config.h. Generated by config.status. */
503d2be0 22443 if test x"$ac_file" = x-; then
c0d27fcc 22444 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 22445 else
c0d27fcc 22446 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
22447 fi
22448 cat $tmp/in >>$tmp/config.h
22449 rm -f $tmp/in
22450 if test x"$ac_file" != x-; then
19650fd6 22451 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 22452 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
22453echo "$as_me: $ac_file is unchanged" >&6;}
22454 else
c0d27fcc
MR
22455 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22456$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22457 X"$ac_file" : 'X\(//\)[^/]' \| \
22458 X"$ac_file" : 'X\(//\)$' \| \
22459 X"$ac_file" : 'X\(/\)' \| \
22460 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22461echo X"$ac_file" |
22462 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22463 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22464 /^X\(\/\/\)$/{ s//\1/; q; }
22465 /^X\(\/\).*/{ s//\1/; q; }
22466 s/.*/./; q'`
6bae0ccf
DL
22467 { if $as_mkdir_p; then
22468 mkdir -p "$ac_dir"
22469 else
22470 as_dir="$ac_dir"
22471 as_dirs=
22472 while test ! -d "$as_dir"; do
22473 as_dirs="$as_dir $as_dirs"
22474 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22475$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22476 X"$as_dir" : 'X\(//\)[^/]' \| \
22477 X"$as_dir" : 'X\(//\)$' \| \
22478 X"$as_dir" : 'X\(/\)' \| \
22479 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22480echo X"$as_dir" |
22481 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22482 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22483 /^X\(\/\/\)$/{ s//\1/; q; }
22484 /^X\(\/\).*/{ s//\1/; q; }
22485 s/.*/./; q'`
22486 done
22487 test ! -n "$as_dirs" || mkdir $as_dirs
22488 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22489echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22490 { (exit 1); exit 1; }; }; }
503d2be0 22491
503d2be0
AS
22492 rm -f $ac_file
22493 mv $tmp/config.h $ac_file
ba4481b5 22494 fi
503d2be0
AS
22495 else
22496 cat $tmp/config.h
22497 rm -f $tmp/config.h
ba4481b5 22498 fi
503d2be0 22499done
c0d27fcc
MR
22500_ACEOF
22501cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22502
22503#
22504# CONFIG_COMMANDS section.
22505#
22506for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
22507 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
22508 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
22509 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
22510$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22511 X"$ac_dest" : 'X\(//\)[^/]' \| \
22512 X"$ac_dest" : 'X\(//\)$' \| \
22513 X"$ac_dest" : 'X\(/\)' \| \
22514 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
22515echo X"$ac_dest" |
22516 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22517 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22518 /^X\(\/\/\)$/{ s//\1/; q; }
22519 /^X\(\/\).*/{ s//\1/; q; }
22520 s/.*/./; q'`
35996d22
AS
22521 { if $as_mkdir_p; then
22522 mkdir -p "$ac_dir"
22523 else
22524 as_dir="$ac_dir"
22525 as_dirs=
22526 while test ! -d "$as_dir"; do
22527 as_dirs="$as_dir $as_dirs"
22528 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22529$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22530 X"$as_dir" : 'X\(//\)[^/]' \| \
22531 X"$as_dir" : 'X\(//\)$' \| \
22532 X"$as_dir" : 'X\(/\)' \| \
22533 . : '\(.\)' 2>/dev/null ||
22534echo X"$as_dir" |
22535 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22536 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22537 /^X\(\/\/\)$/{ s//\1/; q; }
22538 /^X\(\/\).*/{ s//\1/; q; }
22539 s/.*/./; q'`
22540 done
22541 test ! -n "$as_dirs" || mkdir $as_dirs
22542 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22543echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22544 { (exit 1); exit 1; }; }; }
22545
c0d27fcc
MR
22546 ac_builddir=.
22547
22548if test "$ac_dir" != .; then
22549 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22550 # A "../" for each directory in $ac_dir_suffix.
22551 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22552else
22553 ac_dir_suffix= ac_top_builddir=
22554fi
22555
22556case $srcdir in
22557 .) # No --srcdir option. We are building in place.
22558 ac_srcdir=.
22559 if test -z "$ac_top_builddir"; then
22560 ac_top_srcdir=.
22561 else
22562 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22563 fi ;;
22564 [\\/]* | ?:[\\/]* ) # Absolute path.
22565 ac_srcdir=$srcdir$ac_dir_suffix;
22566 ac_top_srcdir=$srcdir ;;
22567 *) # Relative path.
22568 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22569 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22570esac
35996d22
AS
22571
22572# Do not use `cd foo && pwd` to compute absolute paths, because
22573# the directories may not exist.
22574case `pwd` in
22575.) ac_abs_builddir="$ac_dir";;
22576*)
22577 case "$ac_dir" in
22578 .) ac_abs_builddir=`pwd`;;
22579 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22580 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22581 esac;;
22582esac
22583case $ac_abs_builddir in
22584.) ac_abs_top_builddir=${ac_top_builddir}.;;
22585*)
22586 case ${ac_top_builddir}. in
22587 .) ac_abs_top_builddir=$ac_abs_builddir;;
22588 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22589 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22590 esac;;
22591esac
22592case $ac_abs_builddir in
22593.) ac_abs_srcdir=$ac_srcdir;;
22594*)
22595 case $ac_srcdir in
22596 .) ac_abs_srcdir=$ac_abs_builddir;;
22597 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22598 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22599 esac;;
22600esac
22601case $ac_abs_builddir in
22602.) ac_abs_top_srcdir=$ac_top_srcdir;;
22603*)
22604 case $ac_top_srcdir in
22605 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22606 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22607 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22608 esac;;
22609esac
ba4481b5 22610
c0d27fcc
MR
22611
22612 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
22613echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
22614 case $ac_dest in
22615 default )
ba4481b5
DL
22616
22617### Make the necessary directories, if they don't exist.
22618for dir in etc lisp ; do
22619 test -d ${dir} || mkdir ${dir}
22620done
22621
22622# Build src/Makefile from ${srcdir}/src/Makefile.c
22623# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
22624# This must be done after src/config.h is built, since we rely on that file.
22625
22626# Now get this: Some word that is part of the ${srcdir} directory name
22627# or the ${configuration} value might, just might, happen to be an
22628# identifier like `sun4' or `i386' or something, and be predefined by
22629# the C preprocessor to some helpful value like 1, or maybe the empty
22630# string. Needless to say consequent macro substitutions are less
22631# than conducive to the makefile finding the correct directory.
22632undefs="`echo $top_srcdir $configuration $canonical |
22633sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
22634 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
22635`"
22636
22637echo creating src/epaths.h
4aa6b955 22638${MAKE-make} epaths-force
ba4481b5 22639
1c203d4c
DL
22640# As of 2000-11-19, newest development versions of GNU cpp preprocess
22641# `..' to `. .' unless invoked with -traditional
22642
d0e9bfd2 22643if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
22644 CPPFLAGS="$CPPFLAGS -traditional"
22645fi
22646
ba4481b5
DL
22647echo creating lib-src/Makefile
22648( cd lib-src
22649 rm -f junk.c junk1.c junk2.c
22650 sed -e '/start of cpp stuff/q' \
22651 < Makefile.c > junk1.c
22652 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22653 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22654 < Makefile.c > junk.c
503d2be0 22655 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22656 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22657 cat junk1.c junk2.c > Makefile.new
22658 rm -f junk.c junk1.c junk2.c
22659 chmod 444 Makefile.new
22660 mv -f Makefile.new Makefile
22661)
22662
22663echo creating src/Makefile
22664( cd src
22665 rm -f junk.c junk1.c junk2.c
22666 sed -e '/start of cpp stuff/q' \
22667 < Makefile.c > junk1.c
22668 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22669 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22670 < Makefile.c > junk.c
503d2be0 22671 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22672 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22673 cat junk1.c junk2.c > Makefile.new
22674 rm -f junk.c junk1.c junk2.c
22675 chmod 444 Makefile.new
22676 mv -f Makefile.new Makefile
22677)
22678
503d2be0 22679if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 22680 echo creating src/.gdbinit
503d2be0 22681 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
22682fi
22683
22684# This is how we know whether to re-run configure in certain cases.
22685touch src/config.stamp
22686
503d2be0
AS
22687 ;;
22688 esac
22689done
c0d27fcc 22690_ACEOF
503d2be0 22691
c0d27fcc 22692cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22693
503d2be0 22694{ (exit 0); exit 0; }
c0d27fcc 22695_ACEOF
ba4481b5 22696chmod +x $CONFIG_STATUS
503d2be0
AS
22697ac_clean_files=$ac_clean_files_save
22698
c0d27fcc 22699
503d2be0
AS
22700# configure is writing to config.log, and then calls config.status.
22701# config.status does its own redirection, appending to config.log.
22702# Unfortunately, on DOS this fails, as config.log is still kept open
22703# by configure, so config.status won't be able to write to it; its
22704# output is simply discarded. So we exec the FD to /dev/null,
22705# effectively closing config.log, so it can be properly (re)opened and
22706# appended to by config.status. When coming back to configure, we
22707# need to make the FD available again.
22708if test "$no_create" != yes; then
22709 ac_cs_success=:
19650fd6
AS
22710 ac_config_status_args=
22711 test "$silent" = yes &&
22712 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 22713 exec 5>/dev/null
19650fd6 22714 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
22715 exec 5>>config.log
22716 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
22717 # would make configure fail if this is the last instruction.
22718 $ac_cs_success || { (exit 1); exit 1; }
22719fi
f5f47add 22720
c0d27fcc 22721