(x_update_window_end): Call draw_window_fringes.
[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 1576
22044edf 1577extrasub='/^VPATH[ ]*=/c\
ba4481b5
DL
1578vpath %.c $(srcdir)\
1579vpath %.h $(srcdir)\
1580vpath %.y $(srcdir)\
1581vpath %.l $(srcdir)\
1582vpath %.s $(srcdir)\
1583vpath %.in $(srcdir)\
1584vpath %.texi $(srcdir)'
1585fi
1586
1587#### Given the configuration name, set machfile and opsysfile to the
1588#### names of the m/*.h and s/*.h files we should use.
1589
1590### Canonicalize the configuration name.
1591
1592ac_aux_dir=
1593for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1594 if test -f $ac_dir/install-sh; then
1595 ac_aux_dir=$ac_dir
1596 ac_install_sh="$ac_aux_dir/install-sh -c"
1597 break
1598 elif test -f $ac_dir/install.sh; then
1599 ac_aux_dir=$ac_dir
1600 ac_install_sh="$ac_aux_dir/install.sh -c"
1601 break
503d2be0
AS
1602 elif test -f $ac_dir/shtool; then
1603 ac_aux_dir=$ac_dir
1604 ac_install_sh="$ac_aux_dir/shtool install -c"
1605 break
ba4481b5
DL
1606 fi
1607done
1608if test -z "$ac_aux_dir"; then
c0d27fcc 1609 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1610echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1611 { (exit 1); exit 1; }; }
ba4481b5 1612fi
503d2be0
AS
1613ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1614ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1615ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1616
1617# Make sure we can run config.sub.
503d2be0 1618$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1619 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1620echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1621 { (exit 1); exit 1; }; }
1622
c0d27fcc 1623echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1624echo $ECHO_N "checking build system type... $ECHO_C" >&6
1625if test "${ac_cv_build+set}" = set; then
1626 echo $ECHO_N "(cached) $ECHO_C" >&6
1627else
1628 ac_cv_build_alias=$build_alias
1629test -z "$ac_cv_build_alias" &&
1630 ac_cv_build_alias=`$ac_config_guess`
1631test -z "$ac_cv_build_alias" &&
c0d27fcc 1632 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1633echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1634 { (exit 1); exit 1; }; }
1635ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1636 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1637echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1638 { (exit 1); exit 1; }; }
1639
1640fi
c0d27fcc 1641echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1642echo "${ECHO_T}$ac_cv_build" >&6
1643build=$ac_cv_build
1644build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1645build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1646build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1647
c0d27fcc
MR
1648
1649echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1650echo $ECHO_N "checking host system type... $ECHO_C" >&6
1651if test "${ac_cv_host+set}" = set; then
1652 echo $ECHO_N "(cached) $ECHO_C" >&6
1653else
1654 ac_cv_host_alias=$host_alias
1655test -z "$ac_cv_host_alias" &&
1656 ac_cv_host_alias=$ac_cv_build_alias
1657ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1658 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1659echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1660 { (exit 1); exit 1; }; }
1661
1662fi
c0d27fcc 1663echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1664echo "${ECHO_T}$ac_cv_host" >&6
1665host=$ac_cv_host
1666host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1667host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1668host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1669
c0d27fcc 1670
ba4481b5 1671canonical=$host
531a3336 1672configuration=${host_alias-$host}
ba4481b5 1673
c0d27fcc 1674
22044edf 1675
ba4481b5
DL
1676### If you add support for a new configuration, add code to this
1677### switch statement to recognize your configuration name and select
1678### the appropriate operating system and machine description files.
1679
1680### You would hope that you could choose an m/*.h file pretty much
1681### based on the machine portion of the configuration name, and an s-
1682### file based on the operating system portion. However, it turns out
1683### that each m/*.h file is pretty manufacturer-specific - for
1684### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1685### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1686### machines. So we basically have to have a special case for each
1687### configuration name.
1688###
1689### As far as handling version numbers on operating systems is
1690### concerned, make sure things will fail in a fixable way. If
1691### /etc/MACHINES doesn't say anything about version numbers, be
1692### prepared to handle anything reasonably. If version numbers
1693### matter, be sure /etc/MACHINES says something about it.
1694###
1695### Eric Raymond says we should accept strings like "sysvr4" to mean
1696### "System V Release 4"; he writes, "The old convention encouraged
1697### confusion between `system' and `release' levels'."
1698
1699machine='' opsys='' unported=no
1700case "${canonical}" in
1701
1096bcc0
GM
1702 ## FreeBSD ports
1703 *-*-freebsd* )
1704 opsys=freebsd
1705 case "${canonical}" in
1706 alpha*-*-freebsd*) machine=alpha ;;
1707 i[3456]86-*-freebsd*) machine=intel386 ;;
1708 esac
1709 ;;
1710
ba4481b5
DL
1711 ## NetBSD ports
1712 *-*-netbsd* )
1713 opsys=netbsd
dd038e26 1714 if test -f /usr/lib/crti.o; then
f57bd967
DL
1715
1716cat >>confdefs.h <<\_ACEOF
1717#define HAVE_CRTIN
dd038e26
AS
1718_ACEOF
1719
1720 fi
1721
ba4481b5
DL
1722 case "${canonical}" in
1723 alpha*-*-netbsd*) machine=alpha ;;
1724 i[3456]86-*-netbsd*) machine=intel386 ;;
1725 m68k-*-netbsd*)
1726 # This is somewhat bogus.
1727 machine=hp9000s300 ;;
1728 powerpc-apple-netbsd*) machine=macppc ;;
1729 mips-*-netbsd*) machine=pmax ;;
2df636f4 1730 mipsel-*-netbsd*) machine=pmax ;;
97836269 1731 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1732 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1733 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1734 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1735 vax-*-netbsd*) machine=vax ;;
2df636f4 1736 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1737 esac
1738 ;;
1739
1740 ## OpenBSD ports
1741 *-*-openbsd* )
1742 opsys=openbsd
1743 case "${canonical}" in
1744 alpha*-*-openbsd*) machine=alpha ;;
1745 i386-*-openbsd*) machine=intel386 ;;
1746 m68k-*-openbsd*) machine=hp9000s300 ;;
1747 mipsel-*-openbsd*) machine=pmax ;;
1748 ns32k-*-openbsd*) machine=ns32000 ;;
1749 sparc-*-openbsd*) machine=sparc ;;
1750 vax-*-openbsd*) machine=vax ;;
1751 esac
1752 ;;
1753
1754 ## Acorn RISCiX:
1755 arm-acorn-riscix1.1* )
1756 machine=acorn opsys=riscix1-1
1757 ;;
1758 arm-acorn-riscix1.2* | arm-acorn-riscix )
1759 ## This name is riscix12 instead of riscix1.2
1760 ## to avoid a file name conflict on MSDOS.
1761 machine=acorn opsys=riscix12
1762 ;;
1763
1764 ## BSDI ports
1765 *-*-bsdi* )
1766 opsys=bsdi
1767 case "${canonical}" in
1768 i[345]86-*-bsdi*) machine=intel386 ;;
1769 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1770 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1771 esac
1772 case "${canonical}" in
1773 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1774 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1775 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1776 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1777 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1778 esac
1779 ;;
1780
1781 ## Alliant machines
1782 ## Strictly speaking, we need the version of the alliant operating
1783 ## system to choose the right machine file, but currently the
1784 ## configuration name doesn't tell us enough to choose the right
1785 ## one; we need to give alliants their own operating system name to
1786 ## do this right. When someone cares, they can help us.
1787 fx80-alliant-* )
1788 machine=alliant4 opsys=bsd4-2
1789 ;;
1790 i860-alliant-* )
1791 machine=alliant-2800 opsys=bsd4-3
1792 ;;
1793
1794 ## Alpha (DEC) machines.
1795 alpha*-dec-osf* )
1796 machine=alpha opsys=osf1
1797 # This is needed to find X11R6.1 libraries for certain tests.
1798 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1799 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1800 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1801 # due to non-traditional preprocessing with the current compiler
1802 # defaults. OSF 4 can also have that compiler version, and there
1803 # seems always to have been a usable /usr/bin/cpp.
1804 NON_GNU_CPP=/usr/bin/cpp
ca512671 1805 case "${canonical}" in
a55b799a 1806 alpha*-dec-osf[5-9]*)
bb17930d 1807 opsys=osf5-0 ;;
ca512671 1808 esac
ba4481b5
DL
1809 ;;
1810
1811 alpha*-*-linux-gnu* )
1812 machine=alpha opsys=gnu-linux
1813 ;;
1814
c4bb2108
DL
1815 arm*-*-linux-gnu* )
1816 machine=arm opsys=gnu-linux
1817 ;;
1818
1819 ppc-*-linux | \
1820 powerpc-*-linux* )
3aeecf97 1821 machine=macppc opsys=gnu-linux
c4bb2108
DL
1822 ;;
1823
ba4481b5
DL
1824 ## Altos 3068
1825 m68*-altos-sysv* )
1826 machine=altos opsys=usg5-2
1827 ;;
1828
1829 ## Amdahl UTS
1830 580-amdahl-sysv* )
1831 machine=amdahl opsys=usg5-2-2
1832 ;;
1833
1834 ## Apollo, Domain/OS
1835 m68*-apollo-* )
1836 machine=apollo opsys=bsd4-3
1837 ;;
1838
1839 ## AT&T 3b2, 3b5, 3b15, 3b20
1840 we32k-att-sysv* )
1841 machine=att3b opsys=usg5-2-2
1842 ;;
1843
1844 ## AT&T 3b1 - The Mighty Unix PC!
1845 m68*-att-sysv* )
1846 machine=7300 opsys=usg5-2-2
1847 ;;
1848
1849 ## Bull dpx20
1850 rs6000-bull-bosx* )
1851 machine=ibmrs6000 opsys=aix3-2
1852 ;;
1853
1854 ## Bull dpx2
1855 m68*-bull-sysv3* )
1856 machine=dpx2 opsys=usg5-3
1857 ;;
1858
1859 ## Bull sps7
1860 m68*-bull-sysv2* )
1861 machine=sps7 opsys=usg5-2
1862 ;;
1863
1864 ## CCI 5/32, 6/32 -- see "Tahoe".
1865
1866 ## Celerity
1867 ## I don't know what configuration name to use for this; config.sub
1868 ## doesn't seem to know anything about it. Hey, Celerity users, get
1869 ## in touch with us!
1870 celerity-celerity-bsd* )
1871 machine=celerity opsys=bsd4-2
1872 ;;
1873
1874 ## Clipper
1875 ## What operating systems does this chip run that Emacs has been
1876 ## tested on?
1877 clipper-* )
1878 machine=clipper
1879 ## We'll use the catch-all code at the bottom to guess the
1880 ## operating system.
1881 ;;
1882
df645f7c
AS
1883 ## Compaq Nonstop
1884 mips-compaq-nonstopux* )
1885 machine=nonstopux opsys=nonstopux
1886 ;;
1887
ba4481b5
DL
1888 ## Convex
1889 *-convex-bsd* | *-convex-convexos* )
1890 machine=convex opsys=bsd4-3
1891 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1892 NON_GNU_CPP="cc -E -P"
1893 ;;
1894
1895 ## Cubix QBx/386
1896 i[3456]86-cubix-sysv* )
1897 machine=intel386 opsys=usg5-3
1898 ;;
1899
1900 ## Cydra 5
1901 cydra*-cydrome-sysv* )
1902 machine=cydra5 opsys=usg5-3
1903 ;;
1904
1905 ## Data General AViiON Machines
1906 ## DG changed naming conventions with the release of 5.4.4.10, they
1907 ## dropped the initial 5.4 but left the intervening R. Because of the
1908 ## R this shouldn't conflict with older versions of the OS (which I
1909 ## think were named like dgux4.*). In addition, DG new AViiONs series
1910 ## uses either Motorola M88k or Intel Pentium CPUs.
1911 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1912 machine=aviion opsys=dgux4
1913 ;;
1914 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1915 ## This name is dgux5-4-3 instead of dgux5-4r3
1916 ## to avoid a file name conflict on MSDOS.
1917 machine=aviion opsys=dgux5-4-3
1918 ;;
1919 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1920 machine=aviion opsys=dgux5-4r2
1921 ;;
1922 m88k-dg-dgux* )
1923 machine=aviion opsys=dgux
1924 ;;
1925
1926 ## Data General AViiON Intel (x86) Machines
1927 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1928 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1929 i[345]86-dg-dguxR4* )
1930 machine=aviion-intel opsys=dgux4
1931 ;;
1932
1933 ## DECstations
1934 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1935 machine=pmax opsys=bsd4-2
1936 ;;
1937 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1938 machine=pmax opsys=bsd4-3
1939 ;;
1940 mips-dec-ultrix* )
1941 machine=pmax opsys=ultrix4-3
1942 ;;
1943 mips-dec-osf* )
1944 machine=pmax opsys=osf1
1945 ;;
1946 mips-dec-mach_bsd4.3* )
1947 machine=pmax opsys=mach-bsd4-3
1948 ;;
1949
cd890796
JD
1950 ## Motorola Delta machines
1951 m68k-motorola-sysv* | m68000-motorola-sysv* )
1952 machine=delta opsys=usg5-3
1953 if test -z "`type gnucc | grep 'not found'`"
1954 then
1955 if test -s /etc/167config
1956 then CC="gnucc -m68040"
1957 else CC="gnucc -m68881"
1958 fi
1959 else
1960 if test -z "`type gcc | grep 'not found'`"
1961 then CC=gcc
1962 else CC=cc
1963 fi
1964 fi
1965 ;;
ba4481b5
DL
1966 m88k-motorola-sysv4* )
1967 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1968 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1969 # I hope there are not other 4.0 versions for this machine
1970 # which really need usg5-4 instead.
1971 machine=delta88k opsys=usg5-4-2
1972 ;;
1973 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1974 machine=delta88k opsys=usg5-3
1975 ;;
1976
1977 ## Dual machines
1978 m68*-dual-sysv* )
1979 machine=dual opsys=usg5-2
1980 ;;
1981 m68*-dual-uniplus* )
1982 machine=dual opsys=unipl5-2
1983 ;;
1984
1985 ## Elxsi 6400
1986 elxsi-elxsi-sysv* )
1987 machine=elxsi opsys=usg5-2
1988 ;;
1989
1990 ## Encore machines
1991 ns16k-encore-bsd* )
1992 machine=ns16000 opsys=umax
1993 ;;
1994
65171e3a
DL
1995 ## The GEC 63 - apparently, this port isn't really finished yet.
1996 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
1997
1998 ## Gould Power Node and NP1
1999 pn-gould-bsd4.2* )
2000 machine=gould opsys=bsd4-2
2001 ;;
2002 pn-gould-bsd4.3* )
2003 machine=gould opsys=bsd4-3
2004 ;;
2005 np1-gould-bsd* )
2006 machine=gould-np1 opsys=bsd4-3
2007 ;;
2008
2009 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
2010 ## as far as Emacs is concerned).
2011 m88k-harris-cxux* )
2012 # Build needs to be different on 7.0 and later releases
2013 case "`uname -r`" in
2014 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
2015 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
2016 esac
2017 NON_GNU_CPP="/lib/cpp"
2018 ;;
2019 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
2020 m68k-harris-cxux* )
2021 machine=nh3000 opsys=cxux
2022 ;;
2023 ## Harris power pc NightHawk running Power UNIX (Series 6000)
2024 powerpc-harris-powerunix )
2025 machine=nh6000 opsys=powerunix
2026 NON_GNU_CPP="cc -Xo -E -P"
2027 ;;
2028 ## SR2001/SR2201 running HI-UX/MPP
2029 hppa1.1-hitachi-hiuxmpp* )
2030 machine=sr2k opsys=hiuxmpp
2031 ;;
89a336fa
GM
2032 hppa1.1-hitachi-hiuxwe2* )
2033 machine=sr2k opsys=hiuxwe2
2034 ;;
ba4481b5
DL
2035 ## Honeywell XPS100
2036 xps*-honeywell-sysv* )
2037 machine=xps100 opsys=usg5-2
2038 ;;
2039
2040 ## HP 9000 series 200 or 300
2041 m68*-hp-bsd* )
2042 machine=hp9000s300 opsys=bsd4-3
2043 ;;
2044 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2045 m68*-hp-hpux* )
2046 case "`uname -r`" in
2047 ## Someone's system reports A.B8.05 for this.
2048 ## I wonder what other possibilities there are.
2049 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2050 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2051 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2052 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2053 *) machine=hp9000s300 opsys=hpux ;;
2054 esac
2055 ;;
2056
2057 ## HP 9000 series 700 and 800, running HP/UX
2058 hppa*-hp-hpux7* )
2059 machine=hp800 opsys=hpux
2060 ;;
2061 hppa*-hp-hpux8* )
2062 machine=hp800 opsys=hpux8
2063 ;;
2064 hppa*-hp-hpux9shr* )
2065 machine=hp800 opsys=hpux9shr
2066 ;;
2067 hppa*-hp-hpux9* )
2068 machine=hp800 opsys=hpux9
2069 ;;
b0e44248
RB
2070 hppa*-hp-hpux10.2* )
2071 machine=hp800 opsys=hpux10-20
2072 ;;
cc227489 2073 hppa*-hp-hpux10* )
ba4481b5
DL
2074 machine=hp800 opsys=hpux10
2075 ;;
cc227489
MB
2076 hppa*-hp-hpux1[1-9]* )
2077 machine=hp800 opsys=hpux11
2078 ;;
ba4481b5 2079
409d9577
GM
2080 hppa*-*-linux-gnu* )
2081 machine=hp800 opsys=gnu-linux
2082 ;;
2083
ba4481b5
DL
2084 ## HP 9000 series 700 and 800, running HP/UX
2085 hppa*-hp-hpux* )
2086 ## Cross-compilation? Nah!
2087 case "`uname -r`" in
2088 ## Someone's system reports A.B8.05 for this.
2089 ## I wonder what other possibilities there are.
2090 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2091 *.08.* ) machine=hp800 opsys=hpux8 ;;
2092 *.09.* ) machine=hp800 opsys=hpux9 ;;
2093 *) machine=hp800 opsys=hpux10 ;;
2094 esac
2095 ;;
2096 hppa*-*-nextstep* )
2097 machine=hp800 opsys=nextstep
2098 ;;
2099
2100 ## Orion machines
2101 orion-orion-bsd* )
2102 machine=orion opsys=bsd4-2
2103 ;;
2104 clipper-orion-bsd* )
2105 machine=orion105 opsys=bsd4-2
2106 ;;
2107
2108 ## IBM machines
2109 i[3456]86-ibm-aix1.1* )
2110 machine=ibmps2-aix opsys=usg5-2-2
2111 ;;
2112 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2113 machine=ibmps2-aix opsys=usg5-3
2114 ;;
2115 i370-ibm-aix*)
2116 machine=ibm370aix opsys=usg5-3
2117 ;;
55597d70 2118 s390-*-linux-gnu* )
138f0859
GM
2119 machine=ibms390 opsys=gnu-linux
2120 ;;
ba4481b5
DL
2121 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2122 machine=ibmrs6000 opsys=aix3-1
2123 ;;
2124 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2125 machine=ibmrs6000 opsys=aix3-2-5
2126 ;;
2127 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2128 machine=ibmrs6000 opsys=aix4-1
2129 ;;
2130 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2131 machine=ibmrs6000 opsys=aix4-2
2132 ;;
55597d70 2133 rs6000-ibm-aix5* | powerpc-ibm-aix5* )
d6b82250
EZ
2134 machine=ibmrs6000 opsys=aix4-2
2135 ;;
ba4481b5
DL
2136 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2137 machine=ibmrs6000 opsys=aix4
2138 ;;
2139 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2140 machine=ibmrs6000 opsys=aix4-1
2141 ;;
2142 rs6000-ibm-aix* | powerpc-ibm-aix* )
2143 machine=ibmrs6000 opsys=aix3-2
2144 ;;
2145 romp-ibm-bsd4.3* )
2146 machine=ibmrt opsys=bsd4-3
2147 ;;
2148 romp-ibm-bsd4.2* )
2149 machine=ibmrt opsys=bsd4-2
2150 ;;
2151 romp-ibm-aos4.3* )
2152 machine=ibmrt opsys=bsd4-3
2153 ;;
2154 romp-ibm-aos4.2* )
2155 machine=ibmrt opsys=bsd4-2
2156 ;;
2157 romp-ibm-aos* )
2158 machine=ibmrt opsys=bsd4-3
2159 ;;
2160 romp-ibm-bsd* )
2161 machine=ibmrt opsys=bsd4-3
2162 ;;
2163 romp-ibm-aix* )
2164 machine=ibmrt-aix opsys=usg5-2-2
2165 ;;
2166
2167 ## Integrated Solutions `Optimum V'
2168 m68*-isi-bsd4.2* )
2169 machine=isi-ov opsys=bsd4-2
2170 ;;
2171 m68*-isi-bsd4.3* )
2172 machine=isi-ov opsys=bsd4-3
2173 ;;
2174
2175 ## Intel 386 machines where we do care about the manufacturer
2176 i[3456]86-intsys-sysv* )
2177 machine=is386 opsys=usg5-2-2
2178 ;;
2179
2180 ## Prime EXL
2181 i[3456]86-prime-sysv* )
2182 machine=i386 opsys=usg5-3
2183 ;;
2184
2185 ## Sequent Symmetry running Dynix
2186 i[3456]86-sequent-bsd* )
2187 machine=symmetry opsys=bsd4-3
2188 ;;
2189
2190 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2191 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2192 machine=sequent-ptx opsys=ptx4
2193 NON_GNU_CPP=/lib/cpp
2194 ;;
2195
2196 ## Sequent Symmetry running DYNIX/ptx
2197 ## Use the old cpp rather than the newer ANSI one.
2198 i[3456]86-sequent-ptx* )
2199 machine=sequent-ptx opsys=ptx
2200 NON_GNU_CPP="/lib/cpp"
2201 ;;
2202
2203 ## ncr machine running svr4.3.
2204 i[3456]86-ncr-sysv4.3 )
2205 machine=ncr386 opsys=usg5-4-3
2206 ;;
2207
2208 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2209 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2210 i[3456]86-ncr-sysv* )
2211 machine=ncr386 opsys=usg5-4-2
2212 ;;
2213
2214 ## Intel Paragon OSF/1
2215 i860-intel-osf1* )
2216 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2217 ;;
2218
2219 ## Intel 860
2220 i860-*-sysv4* )
2221 machine=i860 opsys=usg5-4
2222 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2223 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2224 ;;
2225
c76e04a8
GM
2226 ## Macintosh PowerPC
2227 powerpc*-*-linux-gnu* )
2228 machine=macppc opsys=gnu-linux
2229 ;;
2230
ba4481b5
DL
2231 ## Masscomp machines
2232 m68*-masscomp-rtu* )
2233 machine=masscomp opsys=rtu
2234 ;;
2235
2236 ## Megatest machines
2237 m68*-megatest-bsd* )
2238 machine=mega68 opsys=bsd4-2
2239 ;;
2240
2241 ## Workstations sold by MIPS
2242 ## This is not necessarily all workstations using the MIPS processor -
2243 ## Irises are produced by SGI, and DECstations by DEC.
2244
2245 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2246 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2247 ## it gives for choosing between the alternatives seems to be "Use
2248 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2249 ## the BSD world." I'll assume that these are instructions for
2250 ## handling two odd situations, and that every other situation
2251 ## should use mips.h and usg5-2-2, they being listed first.
2252 mips-mips-usg* )
2253 machine=mips4
2254 ## Fall through to the general code at the bottom to decide on the OS.
2255 ;;
2256 mips-mips-riscos4* )
2257 machine=mips4 opsys=bsd4-3
2258 NON_GNU_CC="cc -systype bsd43"
2259 NON_GNU_CPP="cc -systype bsd43 -E"
2260 ;;
2261 mips-mips-riscos5* )
2262 machine=mips4 opsys=riscos5
2263 NON_GNU_CC="cc -systype bsd43"
2264 NON_GNU_CPP="cc -systype bsd43 -E"
2265 ;;
2266 mips-mips-bsd* )
2267 machine=mips opsys=bsd4-3
2268 ;;
2269 mips-mips-* )
2270 machine=mips opsys=usg5-2-2
2271 ;;
2272
2273 ## NeXT
2274 m68*-next-* | m68k-*-nextstep* )
2275 machine=m68k opsys=nextstep
2276 ;;
2277
2278 ## The complete machine from National Semiconductor
2279 ns32k-ns-genix* )
2280 machine=ns32000 opsys=usg5-2
2281 ;;
2282
2283 ## NCR machines
2284 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2285 machine=tower32 opsys=usg5-2-2
2286 ;;
2287 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2288 machine=tower32v3 opsys=usg5-3
2289 ;;
2290
2291 ## NEC EWS4800
2292 mips-nec-sysv4*)
2293 machine=ews4800 opsys=ux4800
2294 ;;
2295
2296 ## Nixdorf Targon 31
2297 m68*-nixdorf-sysv* )
2298 machine=targon31 opsys=usg5-2-2
2299 ;;
2300
2301 ## Nu (TI or LMI)
2302 m68*-nu-sysv* )
2303 machine=nu opsys=usg5-2
2304 ;;
2305
2306 ## Plexus
2307 m68*-plexus-sysv* )
2308 machine=plexus opsys=usg5-2
2309 ;;
2310
ba4481b5
DL
2311 ## Pyramid machines
2312 ## I don't really have any idea what sort of processor the Pyramid has,
2313 ## so I'm assuming it is its own architecture.
2314 pyramid-pyramid-bsd* )
2315 machine=pyramid opsys=bsd4-2
2316 ;;
2317
2318 ## Sequent Balance
2319 ns32k-sequent-bsd4.2* )
2320 machine=sequent opsys=bsd4-2
2321 ;;
2322 ns32k-sequent-bsd4.3* )
2323 machine=sequent opsys=bsd4-3
2324 ;;
2325
2326 ## Siemens Nixdorf
2327 mips-siemens-sysv* | mips-sni-sysv*)
2328 machine=mips-siemens opsys=usg5-4
2329 NON_GNU_CC=/usr/ccs/bin/cc
2330 NON_GNU_CPP=/usr/ccs/lib/cpp
2331 ;;
2332
2333 ## Silicon Graphics machines
2334 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2335 m68*-sgi-iris3.5* )
2336 machine=irist opsys=iris3-5
2337 ;;
2338 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2339 machine=irist opsys=iris3-6
2340 ;;
2341 ## Iris 4D
2342 mips-sgi-irix3* )
2343 machine=iris4d opsys=irix3-3
2344 ;;
2345 mips-sgi-irix4* )
2346 machine=iris4d opsys=irix4-0
2347 ;;
2348 mips-sgi-irix6.5 )
2349 machine=iris4d opsys=irix6-5
946173ad
DL
2350 # Without defining _LANGUAGE_C, things get masked out in the headers
2351 # so that, for instance, grepping for `free' in stdlib.h fails and
2352 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2353 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2354 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2355 ;;
2356 mips-sgi-irix6* )
2357 machine=iris4d opsys=irix6-0
c4bb2108 2358 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2359 # but presumably it does no harm.
2360 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2361 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2362 NON_GCC_TEST_OPTIONS=-32
2363 ;;
2364 mips-sgi-irix5.[01]* )
2365 machine=iris4d opsys=irix5-0
2366 ;;
2367 mips-sgi-irix5* | mips-sgi-irix* )
2368 machine=iris4d opsys=irix5-2
2369 ;;
2370
2371 ## SONY machines
2372 m68*-sony-bsd4.2* )
2373 machine=news opsys=bsd4-2
2374 ;;
2375 m68*-sony-bsd4.3* )
2376 machine=news opsys=bsd4-3
2377 ;;
2378 m68*-sony-newsos3* | m68*-sony-news3*)
2379 machine=news opsys=bsd4-3
2380 ;;
2381 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2382 machine=news-risc opsys=bsd4-3
2383 ;;
2384 mips-sony-newsos6* )
2385 machine=news-r6 opsys=newsos6
2386 ;;
2387 mips-sony-news* )
2388 machine=news-risc opsys=newsos5
2389 ;;
2390
2391 ## Stride
2392 m68*-stride-sysv* )
2393 machine=stride opsys=usg5-2
2394 ;;
2395
2396 ## Suns
2397 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2398 machine=sparc opsys=gnu-linux
2399 ;;
2400
d054101f 2401 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2402 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2403 | rs6000-*-solaris2*)
2404 case "${canonical}" in
2405 m68*-sunos1* ) machine=sun1 ;;
2406 m68*-sunos2* ) machine=sun2 ;;
2407 m68* ) machine=sun3 ;;
2408 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2409 i[3456]86-*-* ) machine=intel386 ;;
2410 powerpcle* ) machine=powerpcle ;;
2411 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2412 sparc* ) machine=sparc ;;
2413 * ) unported=yes ;;
2414 esac
2415 case "${canonical}" in
2416 ## The Sun386 didn't get past 4.0.
2417 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2418 *-sunos4.0* ) opsys=sunos4-0 ;;
2419 *-sunos4.1.[3-9]*noshare )
2420 ## This name is sunos413 instead of sunos4-1-3
2421 ## to avoid a file name conflict on MSDOS.
2422 opsys=sunos413
2423 NON_GNU_CPP=/usr/lib/cpp
2424 NON_GCC_TEST_OPTIONS=-Bstatic
2425 GCC_TEST_OPTIONS=-static
2426 ;;
2427 *-sunos4.1.[3-9]* | *-sunos4shr*)
2428 opsys=sunos4shr
2429 NON_GNU_CPP=/usr/lib/cpp
2430 ;;
2431 *-sunos4* | *-sunos )
2432 opsys=sunos4-1
2433 NON_GCC_TEST_OPTIONS=-Bstatic
2434 GCC_TEST_OPTIONS=-static
2435 ;;
2436 *-sunos5.3* | *-solaris2.3* )
2437 opsys=sol2-3
2438 NON_GNU_CPP=/usr/ccs/lib/cpp
2439 ;;
2440 *-sunos5.4* | *-solaris2.4* )
2441 opsys=sol2-4
2442 NON_GNU_CPP=/usr/ccs/lib/cpp
2443 RANLIB="ar -ts"
2444 ;;
2445 *-sunos5.5* | *-solaris2.5* )
2446 opsys=sol2-5
2447 NON_GNU_CPP=/usr/ccs/lib/cpp
2448 RANLIB="ar -ts"
2449 ;;
8e967cf7
MR
2450 *-sunos5.6* | *-solaris2.6* )
2451 opsys=sol2-6
2452 NON_GNU_CPP=/usr/ccs/lib/cpp
2453 RANLIB="ar -ts"
2454 ;;
ba4481b5 2455 *-sunos5* | *-solaris* )
9e71690e 2456 opsys=sol2-6
ba4481b5
DL
2457 NON_GNU_CPP=/usr/ccs/lib/cpp
2458 ;;
2459 * ) opsys=bsd4-2 ;;
2460 esac
2461 ## Watch out for a compiler that we know will not work.
2462 case "${canonical}" in
2463 *-solaris* | *-sunos5* )
2464 if [ "x$CC" = x/usr/ucb/cc ]; then
2465 ## /usr/ucb/cc doesn't work;
2466 ## we should find some other compiler that does work.
2467 unset CC
2468 fi
2469 ;;
2470 *) ;;
2471 esac
2472 ;;
2473 sparc-*-nextstep* )
2474 machine=sparc opsys=nextstep
2475 ;;
2476
2477 ## Tadpole 68k
2478 m68*-tadpole-sysv* )
2479 machine=tad68k opsys=usg5-3
2480 ;;
2481
2482 ## Tahoe machines
2483 tahoe-tahoe-bsd4.2* )
2484 machine=tahoe opsys=bsd4-2
2485 ;;
2486 tahoe-tahoe-bsd4.3* )
2487 machine=tahoe opsys=bsd4-3
2488 ;;
2489
2490 ## Tandem Integrity S2
2491 mips-tandem-sysv* )
2492 machine=tandem-s2 opsys=usg5-3
2493 ;;
2494
2495 ## Tektronix XD88
2496 m88k-tektronix-sysv3* )
2497 machine=tekxd88 opsys=usg5-3
2498 ;;
2499
2500 ## Tektronix 16000 box (6130?)
2501 ns16k-tektronix-bsd* )
2502 machine=ns16000 opsys=bsd4-2
2503 ;;
2504 ## Tektronix 4300
2505 ## src/m/tek4300.h hints that this is a m68k machine.
2506 m68*-tektronix-bsd* )
2507 machine=tek4300 opsys=bsd4-3
2508 ;;
2509
2510 ## Titan P2 or P3
2511 ## We seem to have lost the machine-description file titan.h!
2512 titan-titan-sysv* )
2513 machine=titan opsys=usg5-3
2514 ;;
2515
2516 ## Ustation E30 (SS5E)
2517 m68*-unisys-uniplus* )
2518 machine=ustation opsystem=unipl5-2
2519 ;;
2520
2521 ## Vaxen.
2522 vax-dec-* )
2523 machine=vax
2524 case "${canonical}" in
2525 *-bsd4.1* ) opsys=bsd4-1 ;;
2526 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2527 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2528 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2529 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2530 *-vms* ) opsys=vms ;;
2531 * ) unported=yes
2532 esac
2533 ;;
2534
2535 ## Whitechapel MG1
2536 ns16k-whitechapel-* )
2537 machine=mg1
2538 ## We don't know what sort of OS runs on these; we'll let the
2539 ## operating system guessing code below try.
2540 ;;
2541
2542 ## Wicat
2543 m68*-wicat-sysv* )
2544 machine=wicat opsys=usg5-2
2545 ;;
2546
f4988be7
GM
2547 ## IA-64
2548 ia64*-*-linux* )
2549 machine=ia64 opsys=gnu-linux
2550 ;;
2551
ba4481b5
DL
2552 ## Intel 386 machines where we don't care about the manufacturer
2553 i[3456]86-*-* )
2554 machine=intel386
2555 case "${canonical}" in
c60ee5e7 2556 *-cygwin ) opsys=cygwin ;;
9f817ea4 2557 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2558 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2559 *-isc2.2* ) opsys=isc2-2 ;;
2560 *-isc4.0* ) opsys=isc4-0 ;;
2561 *-isc4.* ) opsys=isc4-1
2562 GCC_TEST_OPTIONS=-posix
2563 NON_GCC_TEST_OPTIONS=-Xp
2564 ;;
2565 *-isc* ) opsys=isc3-0 ;;
2566 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2567 *-esix* ) opsys=esix ;;
2568 *-xenix* ) opsys=xenix ;;
2569 *-linux-gnu* ) opsys=gnu-linux ;;
2570 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2571 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2572 NON_GNU_CPP=/lib/cpp
2573 # Prevent -belf from being passed to $CPP.
2574 # /lib/cpp does not accept it.
2575 OVERRIDE_CPPFLAGS=" "
2576 ;;
2577 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
55597d70
DL
2578 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2579 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
ba4481b5 2580 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2581 *-nextstep* ) opsys=nextstep ;;
2582 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2583 esac
2584 ;;
2585
2586 ## m68k Linux-based GNU system
2587 m68k-*-linux-gnu* )
2588 machine=m68k opsys=gnu-linux
2589 ;;
2590
2591 ## Mips Linux-based GNU system
cd958eb3 2592 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2593 machine=mips opsys=gnu-linux
2594 ;;
2595
2596 ## UXP/DS
2597 sparc-fujitsu-sysv4* )
2598 machine=sparc opsys=uxpds
2599 NON_GNU_CPP=/usr/ccs/lib/cpp
2600 RANLIB="ar -ts"
2601 ;;
2602
2603 ## UXP/V
2604 f301-fujitsu-uxpv4.1)
2605 machine=f301 opsys=uxpv
2606 ;;
2607
e0f712ba
AC
2608 ## Darwin / Mac OS X
2609 powerpc-apple-darwin* )
2610 machine=powermac opsys=darwin
2611 # Define CPP as follows to make autoconf work correctly.
2a75d75d 2612 CPP="${CC-cc} -E -no-cpp-precomp"
e0f712ba
AC
2613 ;;
2614
598a2813
AS
2615 ## AMD x86-64 Linux-based GNU system
2616 x86_64-*-linux-gnu* )
24b01ec4 2617 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2618 ;;
2619
ba4481b5
DL
2620 * )
2621 unported=yes
2622 ;;
2623esac
2624
2625### If the code above didn't choose an operating system, just choose
2626### an operating system based on the configuration name. You really
2627### only want to use this when you have no idea what the right
2628### operating system is; if you know what operating systems a machine
2629### runs, it's cleaner to make it explicit in the case statement
2630### above.
2631if test x"${opsys}" = x; then
2632 case "${canonical}" in
2633 *-gnu* ) opsys=gnu ;;
2634 *-bsd4.[01] ) opsys=bsd4-1 ;;
2635 *-bsd4.2 ) opsys=bsd4-2 ;;
2636 *-bsd4.3 ) opsys=bsd4-3 ;;
2637 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2638 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2639 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2640 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2641 *-sysv4.2uw* ) opsys=unixware ;;
55597d70
DL
2642 *-sysv5uw* ) opsys=unixware ;;
2643 *-sysv5OpenUNIX* ) opsys=unixware ;;
ba4481b5
DL
2644 *-sysv4.1* | *-sysvr4.1* )
2645 NON_GNU_CPP=/usr/lib/cpp
2646 opsys=usg5-4 ;;
2647 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2648 if [ x$NON_GNU_CPP = x ]; then
2649 if [ -f /usr/ccs/lib/cpp ]; then
2650 NON_GNU_CPP=/usr/ccs/lib/cpp
2651 else
2652 NON_GNU_CPP=/lib/cpp
2653 fi
2654 fi
2655 opsys=usg5-4-2 ;;
2656 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2657 * )
2658 unported=yes
2659 ;;
2660 esac
2661fi
2662
c0d27fcc 2663
22044edf 2664
ba4481b5 2665if test $unported = yes; then
c0d27fcc 2666 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2667Check \`etc/MACHINES' for recognized configuration names." >&5
2668echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2669Check \`etc/MACHINES' for recognized configuration names." >&2;}
2670 { (exit 1); exit 1; }; }
ba4481b5
DL
2671fi
2672
2673machfile="m/${machine}.h"
2674opsysfile="s/${opsys}.h"
2675
c0d27fcc 2676
ba4481b5
DL
2677#### Choose a compiler.
2678test -n "$CC" && cc_specified=yes
2679
2680# Save the value of CFLAGS that the user specified.
2681SPECIFIED_CFLAGS="$CFLAGS"
2682
2683case ${with_gcc} in
2684 "yes" ) CC="gcc" GCC=yes ;;
2685 "no" ) : ${CC=cc} ;;
503d2be0
AS
2686 * )
2687esac
2688ac_ext=c
2689ac_cpp='$CPP $CPPFLAGS'
2690ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2691ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2692ac_compiler_gnu=$ac_cv_c_compiler_gnu
2693if test -n "$ac_tool_prefix"; then
2694 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2695set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2696echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2697echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2698if test "${ac_cv_prog_CC+set}" = set; then
2699 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2700else
2701 if test -n "$CC"; then
2702 ac_cv_prog_CC="$CC" # Let the user override the test.
2703else
c0d27fcc
MR
2704as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2705for as_dir in $PATH
2706do
2707 IFS=$as_save_IFS
2708 test -z "$as_dir" && as_dir=.
2709 for ac_exec_ext in '' $ac_executable_extensions; do
2710 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2711 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2712 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2713 break 2
2714 fi
2715done
503d2be0
AS
2716done
2717
ba4481b5
DL
2718fi
2719fi
503d2be0 2720CC=$ac_cv_prog_CC
ba4481b5 2721if test -n "$CC"; then
c0d27fcc 2722 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2723echo "${ECHO_T}$CC" >&6
2724else
c0d27fcc 2725 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2726echo "${ECHO_T}no" >&6
2727fi
2728
2729fi
2730if test -z "$ac_cv_prog_CC"; then
2731 ac_ct_CC=$CC
2732 # Extract the first word of "gcc", so it can be a program name with args.
2733set dummy gcc; ac_word=$2
c0d27fcc 2734echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2735echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2736if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2737 echo $ECHO_N "(cached) $ECHO_C" >&6
2738else
2739 if test -n "$ac_ct_CC"; then
2740 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2741else
c0d27fcc
MR
2742as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2743for as_dir in $PATH
2744do
2745 IFS=$as_save_IFS
2746 test -z "$as_dir" && as_dir=.
2747 for ac_exec_ext in '' $ac_executable_extensions; do
2748 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2749 ac_cv_prog_ac_ct_CC="gcc"
2750 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2751 break 2
2752 fi
2753done
503d2be0
AS
2754done
2755
2756fi
2757fi
2758ac_ct_CC=$ac_cv_prog_ac_ct_CC
2759if test -n "$ac_ct_CC"; then
c0d27fcc 2760 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2761echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2762else
c0d27fcc 2763 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2764echo "${ECHO_T}no" >&6
2765fi
2766
2767 CC=$ac_ct_CC
2768else
2769 CC="$ac_cv_prog_CC"
ba4481b5
DL
2770fi
2771
2772if test -z "$CC"; then
503d2be0
AS
2773 if test -n "$ac_tool_prefix"; then
2774 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2775set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2776echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2777echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2778if test "${ac_cv_prog_CC+set}" = set; then
2779 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2780else
2781 if test -n "$CC"; then
2782 ac_cv_prog_CC="$CC" # Let the user override the test.
2783else
c0d27fcc
MR
2784as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2785for as_dir in $PATH
2786do
2787 IFS=$as_save_IFS
2788 test -z "$as_dir" && as_dir=.
2789 for ac_exec_ext in '' $ac_executable_extensions; do
2790 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2791 ac_cv_prog_CC="${ac_tool_prefix}cc"
2792 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2793 break 2
2794 fi
2795done
503d2be0
AS
2796done
2797
2798fi
2799fi
2800CC=$ac_cv_prog_CC
2801if test -n "$CC"; then
c0d27fcc 2802 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2803echo "${ECHO_T}$CC" >&6
2804else
c0d27fcc 2805 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2806echo "${ECHO_T}no" >&6
2807fi
2808
2809fi
2810if test -z "$ac_cv_prog_CC"; then
2811 ac_ct_CC=$CC
2812 # Extract the first word of "cc", so it can be a program name with args.
2813set dummy cc; ac_word=$2
c0d27fcc 2814echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2815echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2816if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2817 echo $ECHO_N "(cached) $ECHO_C" >&6
2818else
2819 if test -n "$ac_ct_CC"; then
2820 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2821else
c0d27fcc
MR
2822as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2823for as_dir in $PATH
2824do
2825 IFS=$as_save_IFS
2826 test -z "$as_dir" && as_dir=.
2827 for ac_exec_ext in '' $ac_executable_extensions; do
2828 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2829 ac_cv_prog_ac_ct_CC="cc"
2830 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2831 break 2
2832 fi
2833done
503d2be0
AS
2834done
2835
2836fi
2837fi
2838ac_ct_CC=$ac_cv_prog_ac_ct_CC
2839if test -n "$ac_ct_CC"; then
c0d27fcc 2840 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2841echo "${ECHO_T}$ac_ct_CC" >&6
2842else
c0d27fcc 2843 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2844echo "${ECHO_T}no" >&6
2845fi
2846
2847 CC=$ac_ct_CC
2848else
2849 CC="$ac_cv_prog_CC"
2850fi
2851
2852fi
2853if test -z "$CC"; then
2854 # Extract the first word of "cc", so it can be a program name with args.
2855set dummy cc; ac_word=$2
c0d27fcc 2856echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2857echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2858if test "${ac_cv_prog_CC+set}" = set; then
2859 echo $ECHO_N "(cached) $ECHO_C" >&6
2860else
2861 if test -n "$CC"; then
2862 ac_cv_prog_CC="$CC" # Let the user override the test.
2863else
2864 ac_prog_rejected=no
c0d27fcc
MR
2865as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2866for as_dir in $PATH
2867do
2868 IFS=$as_save_IFS
2869 test -z "$as_dir" && as_dir=.
2870 for ac_exec_ext in '' $ac_executable_extensions; do
2871 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2872 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2873 ac_prog_rejected=yes
2874 continue
2875 fi
2876 ac_cv_prog_CC="cc"
2877 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2878 break 2
2879 fi
2880done
503d2be0
AS
2881done
2882
ba4481b5
DL
2883if test $ac_prog_rejected = yes; then
2884 # We found a bogon in the path, so make sure we never use it.
2885 set dummy $ac_cv_prog_CC
2886 shift
503d2be0 2887 if test $# != 0; then
ba4481b5
DL
2888 # We chose a different compiler from the bogus one.
2889 # However, it has the same basename, so the bogon will be chosen
2890 # first if we set CC to just the basename; use the full file name.
2891 shift
6bae0ccf 2892 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2893 fi
2894fi
2895fi
2896fi
503d2be0 2897CC=$ac_cv_prog_CC
ba4481b5 2898if test -n "$CC"; then
c0d27fcc 2899 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2900echo "${ECHO_T}$CC" >&6
ba4481b5 2901else
c0d27fcc 2902 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2903echo "${ECHO_T}no" >&6
ba4481b5
DL
2904fi
2905
503d2be0
AS
2906fi
2907if test -z "$CC"; then
2908 if test -n "$ac_tool_prefix"; then
2909 for ac_prog in cl
2910 do
2911 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2912set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2913echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2914echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2915if test "${ac_cv_prog_CC+set}" = set; then
2916 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2917else
2918 if test -n "$CC"; then
2919 ac_cv_prog_CC="$CC" # Let the user override the test.
2920else
c0d27fcc
MR
2921as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2922for as_dir in $PATH
2923do
2924 IFS=$as_save_IFS
2925 test -z "$as_dir" && as_dir=.
2926 for ac_exec_ext in '' $ac_executable_extensions; do
2927 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2928 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2929 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2930 break 2
2931 fi
2932done
503d2be0
AS
2933done
2934
c4bb2108
DL
2935fi
2936fi
503d2be0 2937CC=$ac_cv_prog_CC
c4bb2108 2938if test -n "$CC"; then
c0d27fcc 2939 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2940echo "${ECHO_T}$CC" >&6
c4bb2108 2941else
c0d27fcc 2942 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2943echo "${ECHO_T}no" >&6
2944fi
2945
2946 test -n "$CC" && break
2947 done
2948fi
2949if test -z "$CC"; then
2950 ac_ct_CC=$CC
2951 for ac_prog in cl
2952do
2953 # Extract the first word of "$ac_prog", so it can be a program name with args.
2954set dummy $ac_prog; ac_word=$2
c0d27fcc 2955echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2956echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2957if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2958 echo $ECHO_N "(cached) $ECHO_C" >&6
2959else
2960 if test -n "$ac_ct_CC"; then
2961 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2962else
c0d27fcc
MR
2963as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2964for as_dir in $PATH
2965do
2966 IFS=$as_save_IFS
2967 test -z "$as_dir" && as_dir=.
2968 for ac_exec_ext in '' $ac_executable_extensions; do
2969 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2970 ac_cv_prog_ac_ct_CC="$ac_prog"
2971 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2972 break 2
2973 fi
2974done
503d2be0
AS
2975done
2976
c4bb2108 2977fi
503d2be0
AS
2978fi
2979ac_ct_CC=$ac_cv_prog_ac_ct_CC
2980if test -n "$ac_ct_CC"; then
c0d27fcc 2981 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2982echo "${ECHO_T}$ac_ct_CC" >&6
2983else
c0d27fcc 2984 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2985echo "${ECHO_T}no" >&6
ba4481b5
DL
2986fi
2987
503d2be0
AS
2988 test -n "$ac_ct_CC" && break
2989done
ba4481b5 2990
503d2be0
AS
2991 CC=$ac_ct_CC
2992fi
2993
2994fi
ba4481b5 2995
c0d27fcc 2996
19650fd6
AS
2997test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2998See \`config.log' for more details." >&5
2999echo "$as_me: error: no acceptable C compiler found in \$PATH
3000See \`config.log' for more details." >&2;}
503d2be0 3001 { (exit 1); exit 1; }; }
c4bb2108 3002
503d2be0 3003# Provide some information about the compiler.
c0d27fcc 3004echo "$as_me:$LINENO:" \
503d2be0
AS
3005 "checking for C compiler version" >&5
3006ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 3007{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
3008 (eval $ac_compiler --version </dev/null >&5) 2>&5
3009 ac_status=$?
c0d27fcc 3010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3011 (exit $ac_status); }
c0d27fcc 3012{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
3013 (eval $ac_compiler -v </dev/null >&5) 2>&5
3014 ac_status=$?
c0d27fcc 3015 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3016 (exit $ac_status); }
c0d27fcc 3017{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
3018 (eval $ac_compiler -V </dev/null >&5) 2>&5
3019 ac_status=$?
c0d27fcc 3020 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3021 (exit $ac_status); }
3022
3023cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3024/* confdefs.h. */
3025_ACEOF
3026cat confdefs.h >>conftest.$ac_ext
3027cat >>conftest.$ac_ext <<_ACEOF
3028/* end confdefs.h. */
c4bb2108 3029
503d2be0
AS
3030int
3031main ()
3032{
3033
3034 ;
3035 return 0;
3036}
3037_ACEOF
3038ac_clean_files_save=$ac_clean_files
19650fd6 3039ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
3040# Try to create an executable without -o first, disregard a.out.
3041# It will help us diagnose broken compilers, and finding out an intuition
3042# of exeext.
35996d22
AS
3043echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3044echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
503d2be0 3045ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 3046if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
3047 (eval $ac_link_default) 2>&5
3048 ac_status=$?
c0d27fcc 3049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3050 (exit $ac_status); }; then
3051 # Find the output, starting from the most likely. This scheme is
3052# not robust to junk in `.', hence go to wildcards (a.*) only as a last
3053# resort.
c0d27fcc
MR
3054
3055# Be careful to initialize this variable, since it used to be cached.
3056# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
3057ac_cv_exeext=
19650fd6
AS
3058# b.out is created by i960 compilers.
3059for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3060do
6bae0ccf 3061 test -f "$ac_file" || continue
503d2be0 3062 case $ac_file in
19650fd6 3063 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
35996d22 3064 ;;
19650fd6 3065 conftest.$ac_ext )
35996d22
AS
3066 # This is the source file.
3067 ;;
19650fd6 3068 [ab].out )
35996d22
AS
3069 # We found the default executable, but exeext='' is most
3070 # certainly right.
3071 break;;
19650fd6 3072 *.* )
35996d22
AS
3073 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3074 # FIXME: I believe we export ac_cv_exeext for Libtool,
3075 # but it would be cool to find out if it's true. Does anybody
3076 # maintain Libtool? --akim.
3077 export ac_cv_exeext
3078 break;;
19650fd6 3079 * )
35996d22 3080 break;;
503d2be0
AS
3081 esac
3082done
3083else
3084 echo "$as_me: failed program was:" >&5
19650fd6
AS
3085sed 's/^/| /' conftest.$ac_ext >&5
3086
6bae0ccf 3087{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
19650fd6 3088See \`config.log' for more details." >&5
6bae0ccf 3089echo "$as_me: error: C compiler cannot create executables
19650fd6 3090See \`config.log' for more details." >&2;}
503d2be0
AS
3091 { (exit 77); exit 77; }; }
3092fi
3093
3094ac_exeext=$ac_cv_exeext
c0d27fcc 3095echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3096echo "${ECHO_T}$ac_file" >&6
3097
3098# Check the compiler produces executables we can run. If not, either
3099# the compiler is broken, or we cross compile.
c0d27fcc 3100echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3101echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3102# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3103# If not cross compiling, check that we can run a simple program.
3104if test "$cross_compiling" != yes; then
3105 if { ac_try='./$ac_file'
c0d27fcc 3106 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3107 (eval $ac_try) 2>&5
3108 ac_status=$?
c0d27fcc 3109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3110 (exit $ac_status); }; }; then
3111 cross_compiling=no
ba4481b5 3112 else
503d2be0
AS
3113 if test "$cross_compiling" = maybe; then
3114 cross_compiling=yes
3115 else
c0d27fcc 3116 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
19650fd6
AS
3117If you meant to cross compile, use \`--host'.
3118See \`config.log' for more details." >&5
503d2be0 3119echo "$as_me: error: cannot run C compiled programs.
19650fd6
AS
3120If you meant to cross compile, use \`--host'.
3121See \`config.log' for more details." >&2;}
503d2be0
AS
3122 { (exit 1); exit 1; }; }
3123 fi
ba4481b5 3124 fi
503d2be0 3125fi
c0d27fcc 3126echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3127echo "${ECHO_T}yes" >&6
3128
19650fd6 3129rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3130ac_clean_files=$ac_clean_files_save
3131# Check the compiler produces executables we can run. If not, either
3132# the compiler is broken, or we cross compile.
c0d27fcc 3133echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3134echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3135echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3136echo "${ECHO_T}$cross_compiling" >&6
3137
c0d27fcc
MR
3138echo "$as_me:$LINENO: checking for suffix of executables" >&5
3139echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3140if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3141 (eval $ac_link) 2>&5
3142 ac_status=$?
c0d27fcc 3143 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3144 (exit $ac_status); }; then
3145 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3146# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3147# work properly (i.e., refer to `conftest.exe'), while it won't with
3148# `rm'.
6bae0ccf
DL
3149for ac_file in conftest.exe conftest conftest.*; do
3150 test -f "$ac_file" || continue
503d2be0 3151 case $ac_file in
6bae0ccf 3152 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0 3153 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
35996d22
AS
3154 export ac_cv_exeext
3155 break;;
503d2be0
AS
3156 * ) break;;
3157 esac
3158done
ba4481b5 3159else
19650fd6
AS
3160 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3161See \`config.log' for more details." >&5
3162echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3163See \`config.log' for more details." >&2;}
503d2be0 3164 { (exit 1); exit 1; }; }
ba4481b5 3165fi
ba4481b5 3166
503d2be0 3167rm -f conftest$ac_cv_exeext
c0d27fcc 3168echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3169echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3170
503d2be0
AS
3171rm -f conftest.$ac_ext
3172EXEEXT=$ac_cv_exeext
3173ac_exeext=$EXEEXT
c0d27fcc
MR
3174echo "$as_me:$LINENO: checking for suffix of object files" >&5
3175echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3176if test "${ac_cv_objext+set}" = set; then
3177 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3178else
503d2be0 3179 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3180/* confdefs.h. */
3181_ACEOF
3182cat confdefs.h >>conftest.$ac_ext
3183cat >>conftest.$ac_ext <<_ACEOF
3184/* end confdefs.h. */
ba4481b5 3185
503d2be0
AS
3186int
3187main ()
3188{
ba4481b5 3189
503d2be0
AS
3190 ;
3191 return 0;
3192}
3193_ACEOF
3194rm -f conftest.o conftest.obj
c0d27fcc 3195if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3196 (eval $ac_compile) 2>&5
3197 ac_status=$?
c0d27fcc 3198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3199 (exit $ac_status); }; then
3200 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3201 case $ac_file in
6bae0ccf 3202 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3203 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3204 break;;
3205 esac
3206done
c4bb2108 3207else
503d2be0 3208 echo "$as_me: failed program was:" >&5
19650fd6
AS
3209sed 's/^/| /' conftest.$ac_ext >&5
3210
3211{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3212See \`config.log' for more details." >&5
3213echo "$as_me: error: cannot compute suffix of object files: cannot compile
3214See \`config.log' for more details." >&2;}
503d2be0 3215 { (exit 1); exit 1; }; }
c4bb2108
DL
3216fi
3217
503d2be0
AS
3218rm -f conftest.$ac_cv_objext conftest.$ac_ext
3219fi
c0d27fcc 3220echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3221echo "${ECHO_T}$ac_cv_objext" >&6
3222OBJEXT=$ac_cv_objext
3223ac_objext=$OBJEXT
c0d27fcc 3224echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3225echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3226if test "${ac_cv_c_compiler_gnu+set}" = set; then
3227 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3228else
503d2be0 3229 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3230/* confdefs.h. */
3231_ACEOF
3232cat confdefs.h >>conftest.$ac_ext
3233cat >>conftest.$ac_ext <<_ACEOF
3234/* end confdefs.h. */
503d2be0
AS
3235
3236int
3237main ()
3238{
3239#ifndef __GNUC__
3240 choke me
3241#endif
3242
3243 ;
3244 return 0;
3245}
3246_ACEOF
3247rm -f conftest.$ac_objext
c0d27fcc 3248if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3249 (eval $ac_compile) 2>conftest.er1
503d2be0 3250 ac_status=$?
35996d22
AS
3251 grep -v '^ *+' conftest.er1 >conftest.err
3252 rm -f conftest.er1
3253 cat conftest.err >&5
c0d27fcc 3254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3255 (exit $ac_status); } &&
35996d22
AS
3256 { ac_try='test -z "$ac_c_werror_flag"
3257 || test ! -s conftest.err'
3258 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3259 (eval $ac_try) 2>&5
3260 ac_status=$?
3261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3262 (exit $ac_status); }; } &&
3263 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3264 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3265 (eval $ac_try) 2>&5
3266 ac_status=$?
c0d27fcc 3267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3268 (exit $ac_status); }; }; then
3269 ac_compiler_gnu=yes
3270else
3271 echo "$as_me: failed program was:" >&5
19650fd6
AS
3272sed 's/^/| /' conftest.$ac_ext >&5
3273
503d2be0
AS
3274ac_compiler_gnu=no
3275fi
35996d22 3276rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3277ac_cv_c_compiler_gnu=$ac_compiler_gnu
3278
3279fi
c0d27fcc 3280echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3281echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3282GCC=`test $ac_compiler_gnu = yes && echo yes`
3283ac_test_CFLAGS=${CFLAGS+set}
3284ac_save_CFLAGS=$CFLAGS
3285CFLAGS="-g"
c0d27fcc 3286echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3287echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3288if test "${ac_cv_prog_cc_g+set}" = set; then
3289 echo $ECHO_N "(cached) $ECHO_C" >&6
3290else
3291 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3292/* confdefs.h. */
3293_ACEOF
3294cat confdefs.h >>conftest.$ac_ext
3295cat >>conftest.$ac_ext <<_ACEOF
3296/* end confdefs.h. */
503d2be0
AS
3297
3298int
3299main ()
3300{
3301
3302 ;
3303 return 0;
3304}
3305_ACEOF
3306rm -f conftest.$ac_objext
c0d27fcc 3307if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3308 (eval $ac_compile) 2>conftest.er1
503d2be0 3309 ac_status=$?
35996d22
AS
3310 grep -v '^ *+' conftest.er1 >conftest.err
3311 rm -f conftest.er1
3312 cat conftest.err >&5
c0d27fcc 3313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3314 (exit $ac_status); } &&
35996d22
AS
3315 { ac_try='test -z "$ac_c_werror_flag"
3316 || test ! -s conftest.err'
3317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3318 (eval $ac_try) 2>&5
3319 ac_status=$?
3320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3321 (exit $ac_status); }; } &&
3322 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3323 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3324 (eval $ac_try) 2>&5
3325 ac_status=$?
c0d27fcc 3326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3327 (exit $ac_status); }; }; then
ba4481b5
DL
3328 ac_cv_prog_cc_g=yes
3329else
503d2be0 3330 echo "$as_me: failed program was:" >&5
19650fd6
AS
3331sed 's/^/| /' conftest.$ac_ext >&5
3332
503d2be0 3333ac_cv_prog_cc_g=no
ba4481b5 3334fi
35996d22 3335rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 3336fi
c0d27fcc 3337echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3338echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3339if test "$ac_test_CFLAGS" = set; then
503d2be0 3340 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3341elif test $ac_cv_prog_cc_g = yes; then
3342 if test "$GCC" = yes; then
ba4481b5
DL
3343 CFLAGS="-g -O2"
3344 else
c4bb2108 3345 CFLAGS="-g"
ba4481b5 3346 fi
22afa6e8 3347else
c4bb2108
DL
3348 if test "$GCC" = yes; then
3349 CFLAGS="-O2"
3350 else
3351 CFLAGS=
3352 fi
ba4481b5 3353fi
6bae0ccf
DL
3354echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3355echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3356if test "${ac_cv_prog_cc_stdc+set}" = set; then
3357 echo $ECHO_N "(cached) $ECHO_C" >&6
3358else
3359 ac_cv_prog_cc_stdc=no
3360ac_save_CC=$CC
3361cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3362/* confdefs.h. */
3363_ACEOF
3364cat confdefs.h >>conftest.$ac_ext
3365cat >>conftest.$ac_ext <<_ACEOF
3366/* end confdefs.h. */
6bae0ccf
DL
3367#include <stdarg.h>
3368#include <stdio.h>
3369#include <sys/types.h>
3370#include <sys/stat.h>
3371/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3372struct buf { int x; };
3373FILE * (*rcsopen) (struct buf *, struct stat *, int);
3374static char *e (p, i)
3375 char **p;
3376 int i;
3377{
3378 return p[i];
3379}
3380static char *f (char * (*g) (char **, int), char **p, ...)
3381{
3382 char *s;
3383 va_list v;
3384 va_start (v,p);
3385 s = g (p, va_arg (v,int));
3386 va_end (v);
3387 return s;
3388}
35996d22
AS
3389
3390/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3391 function prototypes and stuff, but not '\xHH' hex character constants.
3392 These don't provoke an error unfortunately, instead are silently treated
3393 as 'x'. The following induces an error, until -std1 is added to get
3394 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3395 array size at least. It's necessary to write '\x00'==0 to get something
3396 that's true only with -std1. */
3397int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3398
6bae0ccf
DL
3399int test (int i, double x);
3400struct s1 {int (*f) (int a);};
3401struct s2 {int (*f) (double a);};
3402int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3403int argc;
3404char **argv;
3405int
3406main ()
3407{
3408return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3409 ;
3410 return 0;
3411}
3412_ACEOF
3413# Don't try gcc -ansi; that turns off useful extensions and
3414# breaks some systems' header files.
3415# AIX -qlanglvl=ansi
3416# Ultrix and OSF/1 -std1
3417# HP-UX 10.20 and later -Ae
3418# HP-UX older versions -Aa -D_HPUX_SOURCE
3419# SVR4 -Xc -D__EXTENSIONS__
3420for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3421do
3422 CC="$ac_save_CC $ac_arg"
3423 rm -f conftest.$ac_objext
3424if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3425 (eval $ac_compile) 2>conftest.er1
6bae0ccf 3426 ac_status=$?
35996d22
AS
3427 grep -v '^ *+' conftest.er1 >conftest.err
3428 rm -f conftest.er1
3429 cat conftest.err >&5
6bae0ccf
DL
3430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3431 (exit $ac_status); } &&
35996d22
AS
3432 { ac_try='test -z "$ac_c_werror_flag"
3433 || test ! -s conftest.err'
3434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3435 (eval $ac_try) 2>&5
3436 ac_status=$?
3437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3438 (exit $ac_status); }; } &&
3439 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
3440 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3441 (eval $ac_try) 2>&5
3442 ac_status=$?
3443 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3444 (exit $ac_status); }; }; then
3445 ac_cv_prog_cc_stdc=$ac_arg
3446break
3447else
3448 echo "$as_me: failed program was:" >&5
19650fd6
AS
3449sed 's/^/| /' conftest.$ac_ext >&5
3450
6bae0ccf 3451fi
35996d22 3452rm -f conftest.err conftest.$ac_objext
6bae0ccf
DL
3453done
3454rm -f conftest.$ac_ext conftest.$ac_objext
3455CC=$ac_save_CC
3456
3457fi
3458
3459case "x$ac_cv_prog_cc_stdc" in
3460 x|xno)
3461 echo "$as_me:$LINENO: result: none needed" >&5
3462echo "${ECHO_T}none needed" >&6 ;;
3463 *)
3464 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3465echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3466 CC="$CC $ac_cv_prog_cc_stdc" ;;
3467esac
3468
503d2be0
AS
3469# Some people use a C++ compiler to compile C. Since we use `exit',
3470# in C++ we need to declare it. In case someone uses the same compiler
3471# for both compiling C and C++ we need to have the C++ compiler decide
3472# the declaration of exit, since it's the most demanding environment.
3473cat >conftest.$ac_ext <<_ACEOF
3474#ifndef __cplusplus
3475 choke me
3476#endif
3477_ACEOF
3478rm -f conftest.$ac_objext
c0d27fcc 3479if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3480 (eval $ac_compile) 2>conftest.er1
503d2be0 3481 ac_status=$?
35996d22
AS
3482 grep -v '^ *+' conftest.er1 >conftest.err
3483 rm -f conftest.er1
3484 cat conftest.err >&5
c0d27fcc 3485 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3486 (exit $ac_status); } &&
35996d22
AS
3487 { ac_try='test -z "$ac_c_werror_flag"
3488 || test ! -s conftest.err'
3489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3490 (eval $ac_try) 2>&5
3491 ac_status=$?
3492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3493 (exit $ac_status); }; } &&
3494 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3495 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3496 (eval $ac_try) 2>&5
3497 ac_status=$?
c0d27fcc 3498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3499 (exit $ac_status); }; }; then
3500 for ac_declaration in \
35996d22 3501 '' \
503d2be0
AS
3502 'extern "C" void std::exit (int) throw (); using std::exit;' \
3503 'extern "C" void std::exit (int); using std::exit;' \
3504 'extern "C" void exit (int) throw ();' \
3505 'extern "C" void exit (int);' \
cffcede7 3506 'void exit (int);'
503d2be0
AS
3507do
3508 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3509/* confdefs.h. */
3510_ACEOF
3511cat confdefs.h >>conftest.$ac_ext
3512cat >>conftest.$ac_ext <<_ACEOF
3513/* end confdefs.h. */
57669b57 3514$ac_declaration
35996d22 3515#include <stdlib.h>
503d2be0
AS
3516int
3517main ()
3518{
3519exit (42);
3520 ;
3521 return 0;
3522}
3523_ACEOF
3524rm -f conftest.$ac_objext
c0d27fcc 3525if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3526 (eval $ac_compile) 2>conftest.er1
503d2be0 3527 ac_status=$?
35996d22
AS
3528 grep -v '^ *+' conftest.er1 >conftest.err
3529 rm -f conftest.er1
3530 cat conftest.err >&5
c0d27fcc 3531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3532 (exit $ac_status); } &&
35996d22
AS
3533 { ac_try='test -z "$ac_c_werror_flag"
3534 || test ! -s conftest.err'
3535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3536 (eval $ac_try) 2>&5
3537 ac_status=$?
3538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3539 (exit $ac_status); }; } &&
3540 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3542 (eval $ac_try) 2>&5
3543 ac_status=$?
c0d27fcc 3544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3545 (exit $ac_status); }; }; then
3546 :
3547else
3548 echo "$as_me: failed program was:" >&5
19650fd6
AS
3549sed 's/^/| /' conftest.$ac_ext >&5
3550
503d2be0
AS
3551continue
3552fi
35996d22 3553rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 3554 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3555/* confdefs.h. */
3556_ACEOF
3557cat confdefs.h >>conftest.$ac_ext
3558cat >>conftest.$ac_ext <<_ACEOF
3559/* end confdefs.h. */
503d2be0
AS
3560$ac_declaration
3561int
3562main ()
3563{
3564exit (42);
3565 ;
3566 return 0;
3567}
3568_ACEOF
3569rm -f conftest.$ac_objext
c0d27fcc 3570if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3571 (eval $ac_compile) 2>conftest.er1
503d2be0 3572 ac_status=$?
35996d22
AS
3573 grep -v '^ *+' conftest.er1 >conftest.err
3574 rm -f conftest.er1
3575 cat conftest.err >&5
c0d27fcc 3576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3577 (exit $ac_status); } &&
35996d22
AS
3578 { ac_try='test -z "$ac_c_werror_flag"
3579 || test ! -s conftest.err'
3580 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3581 (eval $ac_try) 2>&5
3582 ac_status=$?
3583 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3584 (exit $ac_status); }; } &&
3585 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3586 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3587 (eval $ac_try) 2>&5
3588 ac_status=$?
c0d27fcc 3589 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3590 (exit $ac_status); }; }; then
3591 break
3592else
3593 echo "$as_me: failed program was:" >&5
19650fd6
AS
3594sed 's/^/| /' conftest.$ac_ext >&5
3595
503d2be0 3596fi
35996d22 3597rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3598done
3599rm -f conftest*
3600if test -n "$ac_declaration"; then
3601 echo '#ifdef __cplusplus' >>confdefs.h
3602 echo $ac_declaration >>confdefs.h
3603 echo '#endif' >>confdefs.h
3604fi
ba4481b5 3605
503d2be0
AS
3606else
3607 echo "$as_me: failed program was:" >&5
19650fd6
AS
3608sed 's/^/| /' conftest.$ac_ext >&5
3609
503d2be0 3610fi
35996d22 3611rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3612ac_ext=c
3613ac_cpp='$CPP $CPPFLAGS'
3614ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3615ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3616ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3617
c0d27fcc 3618
ba4481b5
DL
3619# On Suns, sometimes $CPP names a directory.
3620if test -n "$CPP" && test -d "$CPP"; then
3621 CPP=
3622fi
3623
3624#### Some systems specify a CPP to use unless we are using GCC.
3625#### Now that we know whether we are using GCC, we can decide whether
3626#### to use that one.
3627if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3628then
3629 CPP="$NON_GNU_CPP"
3630fi
3631
3632#### Some systems specify a CC to use unless we are using GCC.
3633#### Now that we know whether we are using GCC, we can decide whether
3634#### to use that one.
3635if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3636 test x$cc_specified != xyes
3637then
3638 CC="$NON_GNU_CC"
3639fi
3640
3641if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3642then
3643 CC="$CC $GCC_TEST_OPTIONS"
3644fi
3645
3646if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3647then
3648 CC="$CC $NON_GCC_TEST_OPTIONS"
3649fi
3650
6a3a24fa 3651#### Some other nice autoconf tests.
ba4481b5 3652
c0d27fcc 3653echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3654echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3655LN_S=$as_ln_s
3656if test "$LN_S" = "ln -s"; then
c0d27fcc 3657 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3658echo "${ECHO_T}yes" >&6
ba4481b5 3659else
c0d27fcc 3660 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3661echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3662fi
3663
503d2be0
AS
3664ac_ext=c
3665ac_cpp='$CPP $CPPFLAGS'
3666ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3667ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3668ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3669echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3670echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3671# On Suns, sometimes $CPP names a directory.
3672if test -n "$CPP" && test -d "$CPP"; then
3673 CPP=
3674fi
3675if test -z "$CPP"; then
503d2be0
AS
3676 if test "${ac_cv_prog_CPP+set}" = set; then
3677 echo $ECHO_N "(cached) $ECHO_C" >&6
3678else
3679 # Double quotes because CPP needs to be expanded
3680 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3681 do
3682 ac_preproc_ok=false
3683for ac_c_preproc_warn_flag in '' yes
3684do
3685 # Use a header file that comes with gcc, so configuring glibc
3686 # with a fresh cross-compiler works.
19650fd6
AS
3687 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3688 # <limits.h> exists even on freestanding compilers.
ba4481b5 3689 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3690 # not just through cpp. "Syntax error" is here to catch this case.
3691 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3692/* confdefs.h. */
3693_ACEOF
3694cat confdefs.h >>conftest.$ac_ext
3695cat >>conftest.$ac_ext <<_ACEOF
3696/* end confdefs.h. */
3697#ifdef __STDC__
3698# include <limits.h>
3699#else
3700# include <assert.h>
3701#endif
35996d22 3702 Syntax error
503d2be0 3703_ACEOF
c0d27fcc 3704if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3705 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3706 ac_status=$?
6bae0ccf 3707 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3708 rm -f conftest.er1
3709 cat conftest.err >&5
c0d27fcc 3710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3711 (exit $ac_status); } >/dev/null; then
3712 if test -s conftest.err; then
3713 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3714 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3715 else
3716 ac_cpp_err=
3717 fi
3718else
3719 ac_cpp_err=yes
3720fi
3721if test -z "$ac_cpp_err"; then
ba4481b5
DL
3722 :
3723else
503d2be0 3724 echo "$as_me: failed program was:" >&5
19650fd6
AS
3725sed 's/^/| /' conftest.$ac_ext >&5
3726
503d2be0
AS
3727 # Broken: fails on valid input.
3728continue
3729fi
3730rm -f conftest.err conftest.$ac_ext
3731
3732 # OK, works on sane cases. Now check whether non-existent headers
3733 # can be detected and how.
3734 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3735/* confdefs.h. */
3736_ACEOF
3737cat confdefs.h >>conftest.$ac_ext
3738cat >>conftest.$ac_ext <<_ACEOF
3739/* end confdefs.h. */
503d2be0
AS
3740#include <ac_nonexistent.h>
3741_ACEOF
c0d27fcc 3742if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3743 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3744 ac_status=$?
6bae0ccf 3745 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3746 rm -f conftest.er1
3747 cat conftest.err >&5
c0d27fcc 3748 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3749 (exit $ac_status); } >/dev/null; then
3750 if test -s conftest.err; then
3751 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3752 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3753 else
3754 ac_cpp_err=
3755 fi
3756else
3757 ac_cpp_err=yes
3758fi
3759if test -z "$ac_cpp_err"; then
3760 # Broken: success on invalid input.
3761continue
c4bb2108 3762else
503d2be0 3763 echo "$as_me: failed program was:" >&5
19650fd6
AS
3764sed 's/^/| /' conftest.$ac_ext >&5
3765
503d2be0
AS
3766 # Passes both tests.
3767ac_preproc_ok=:
3768break
3769fi
3770rm -f conftest.err conftest.$ac_ext
3771
3772done
3773# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3774rm -f conftest.err conftest.$ac_ext
3775if $ac_preproc_ok; then
3776 break
3777fi
3778
3779 done
3780 ac_cv_prog_CPP=$CPP
3781
3782fi
3783 CPP=$ac_cv_prog_CPP
3784else
3785 ac_cv_prog_CPP=$CPP
3786fi
c0d27fcc 3787echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3788echo "${ECHO_T}$CPP" >&6
3789ac_preproc_ok=false
3790for ac_c_preproc_warn_flag in '' yes
3791do
3792 # Use a header file that comes with gcc, so configuring glibc
3793 # with a fresh cross-compiler works.
19650fd6
AS
3794 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3795 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3796 # On the NeXT, cc -E runs the code through the compiler's parser,
3797 # not just through cpp. "Syntax error" is here to catch this case.
3798 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3799/* confdefs.h. */
3800_ACEOF
3801cat confdefs.h >>conftest.$ac_ext
3802cat >>conftest.$ac_ext <<_ACEOF
3803/* end confdefs.h. */
3804#ifdef __STDC__
3805# include <limits.h>
3806#else
3807# include <assert.h>
3808#endif
35996d22 3809 Syntax error
503d2be0 3810_ACEOF
c0d27fcc 3811if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3812 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3813 ac_status=$?
6bae0ccf 3814 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3815 rm -f conftest.er1
3816 cat conftest.err >&5
c0d27fcc 3817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3818 (exit $ac_status); } >/dev/null; then
3819 if test -s conftest.err; then
3820 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3821 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3822 else
3823 ac_cpp_err=
3824 fi
3825else
3826 ac_cpp_err=yes
3827fi
3828if test -z "$ac_cpp_err"; then
ba4481b5
DL
3829 :
3830else
503d2be0 3831 echo "$as_me: failed program was:" >&5
19650fd6
AS
3832sed 's/^/| /' conftest.$ac_ext >&5
3833
503d2be0
AS
3834 # Broken: fails on valid input.
3835continue
3836fi
3837rm -f conftest.err conftest.$ac_ext
3838
3839 # OK, works on sane cases. Now check whether non-existent headers
3840 # can be detected and how.
3841 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3842/* confdefs.h. */
3843_ACEOF
3844cat confdefs.h >>conftest.$ac_ext
3845cat >>conftest.$ac_ext <<_ACEOF
3846/* end confdefs.h. */
503d2be0
AS
3847#include <ac_nonexistent.h>
3848_ACEOF
c0d27fcc 3849if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3850 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3851 ac_status=$?
6bae0ccf 3852 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3853 rm -f conftest.er1
3854 cat conftest.err >&5
c0d27fcc 3855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3856 (exit $ac_status); } >/dev/null; then
3857 if test -s conftest.err; then
3858 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3859 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3860 else
3861 ac_cpp_err=
3862 fi
3863else
3864 ac_cpp_err=yes
c4bb2108 3865fi
503d2be0
AS
3866if test -z "$ac_cpp_err"; then
3867 # Broken: success on invalid input.
3868continue
3869else
3870 echo "$as_me: failed program was:" >&5
19650fd6
AS
3871sed 's/^/| /' conftest.$ac_ext >&5
3872
503d2be0
AS
3873 # Passes both tests.
3874ac_preproc_ok=:
3875break
ba4481b5 3876fi
503d2be0
AS
3877rm -f conftest.err conftest.$ac_ext
3878
3879done
3880# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3881rm -f conftest.err conftest.$ac_ext
3882if $ac_preproc_ok; then
3883 :
ba4481b5 3884else
19650fd6
AS
3885 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3886See \`config.log' for more details." >&5
3887echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3888See \`config.log' for more details." >&2;}
503d2be0 3889 { (exit 1); exit 1; }; }
ba4481b5 3890fi
503d2be0
AS
3891
3892ac_ext=c
3893ac_cpp='$CPP $CPPFLAGS'
3894ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3895ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3896ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3897
3898# Find a good install program. We prefer a C program (faster),
3899# so one script is as good as another. But avoid the broken or
3900# incompatible versions:
3901# SysV /etc/install, /usr/sbin/install
3902# SunOS /usr/etc/install
3903# IRIX /sbin/install
3904# AIX /bin/install
503d2be0 3905# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3906# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3907# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3908# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
35996d22 3909# OS/2's system install, which has a completely different semantic
ba4481b5 3910# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3911echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3912echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3913if test -z "$INSTALL"; then
503d2be0
AS
3914if test "${ac_cv_path_install+set}" = set; then
3915 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3916else
c0d27fcc
MR
3917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3918for as_dir in $PATH
3919do
3920 IFS=$as_save_IFS
3921 test -z "$as_dir" && as_dir=.
3922 # Account for people who put trailing slashes in PATH elements.
3923case $as_dir/ in
3924 ./ | .// | /cC/* | \
3925 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
35996d22 3926 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
c0d27fcc
MR
3927 /usr/ucb/* ) ;;
3928 *)
3929 # OSF1 and SCO ODT 3.0 have their own names for install.
3930 # Don't use installbsd from OSF since it installs stuff as root
3931 # by default.
3932 for ac_prog in ginstall scoinst install; do
3933 for ac_exec_ext in '' $ac_executable_extensions; do
35996d22
AS
3934 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3935 if test $ac_prog = install &&
3936 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3937 # AIX install. It has an incompatible calling convention.
3938 :
3939 elif test $ac_prog = install &&
3940 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3941 # program-specific install script used by HP pwplus--don't use.
3942 :
3943 else
3944 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3945 break 3
3946 fi
3947 fi
ba4481b5 3948 done
c0d27fcc
MR
3949 done
3950 ;;
3951esac
3952done
3953
ba4481b5
DL
3954
3955fi
3956 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3957 INSTALL=$ac_cv_path_install
ba4481b5
DL
3958 else
3959 # As a last resort, use the slow shell script. We don't cache a
3960 # path for INSTALL within a source directory, because that will
3961 # break other packages using the cache if that directory is
3962 # removed, or if the path is relative.
503d2be0 3963 INSTALL=$ac_install_sh
ba4481b5
DL
3964 fi
3965fi
c0d27fcc 3966echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3967echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3968
3969# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3970# It thinks the first close brace ends the variable substitution.
3971test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3972
503d2be0 3973test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3974
ba4481b5
DL
3975test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3976
c0d27fcc
MR
3977if test "x$RANLIB" = x; then
3978 if test -n "$ac_tool_prefix"; then
3979 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3980set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3981echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3982echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3983if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3984 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3985else
3986 if test -n "$RANLIB"; then
3987 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3988else
c0d27fcc
MR
3989as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3990for as_dir in $PATH
3991do
3992 IFS=$as_save_IFS
3993 test -z "$as_dir" && as_dir=.
3994 for ac_exec_ext in '' $ac_executable_extensions; do
3995 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3996 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3997 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3998 break 2
3999 fi
4000done
503d2be0
AS
4001done
4002
7397acc4
DL
4003fi
4004fi
503d2be0 4005RANLIB=$ac_cv_prog_RANLIB
7397acc4 4006if test -n "$RANLIB"; then
c0d27fcc 4007 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
4008echo "${ECHO_T}$RANLIB" >&6
4009else
c0d27fcc 4010 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4011echo "${ECHO_T}no" >&6
4012fi
4013
4014fi
4015if test -z "$ac_cv_prog_RANLIB"; then
4016 ac_ct_RANLIB=$RANLIB
4017 # Extract the first word of "ranlib", so it can be a program name with args.
4018set dummy ranlib; ac_word=$2
c0d27fcc 4019echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
4020echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4021if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4022 echo $ECHO_N "(cached) $ECHO_C" >&6
4023else
4024 if test -n "$ac_ct_RANLIB"; then
4025 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4026else
c0d27fcc
MR
4027as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4028for as_dir in $PATH
4029do
4030 IFS=$as_save_IFS
4031 test -z "$as_dir" && as_dir=.
4032 for ac_exec_ext in '' $ac_executable_extensions; do
4033 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4034 ac_cv_prog_ac_ct_RANLIB="ranlib"
4035 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4036 break 2
4037 fi
4038done
503d2be0
AS
4039done
4040
4041 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4042fi
4043fi
4044ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4045if test -n "$ac_ct_RANLIB"; then
c0d27fcc 4046 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
4047echo "${ECHO_T}$ac_ct_RANLIB" >&6
4048else
c0d27fcc 4049 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4050echo "${ECHO_T}no" >&6
4051fi
4052
4053 RANLIB=$ac_ct_RANLIB
7397acc4 4054else
503d2be0 4055 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
4056fi
4057
4058fi
9e71690e
DK
4059# Extract the first word of "install-info", so it can be a program name with args.
4060set dummy install-info; ac_word=$2
4061echo "$as_me:$LINENO: checking for $ac_word" >&5
4062echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4063if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4064 echo $ECHO_N "(cached) $ECHO_C" >&6
4065else
4066 case $INSTALL_INFO in
4067 [\\/]* | ?:[\\/]*)
4068 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4069 ;;
4070 *)
4071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4072for as_dir in $PATH
4073do
4074 IFS=$as_save_IFS
4075 test -z "$as_dir" && as_dir=.
4076 for ac_exec_ext in '' $ac_executable_extensions; do
4077 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4078 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4079 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4080 break 2
4081 fi
4082done
4083done
4084
4085 ;;
4086esac
4087fi
4088INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4089
4090if test -n "$INSTALL_INFO"; then
4091 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4092echo "${ECHO_T}$INSTALL_INFO" >&6
4093else
4094 echo "$as_me:$LINENO: result: no" >&5
4095echo "${ECHO_T}no" >&6
4096fi
4097
4098# Extract the first word of "install-info", so it can be a program name with args.
4099set dummy install-info; ac_word=$2
4100echo "$as_me:$LINENO: checking for $ac_word" >&5
4101echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4102if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4103 echo $ECHO_N "(cached) $ECHO_C" >&6
4104else
4105 case $INSTALL_INFO in
4106 [\\/]* | ?:[\\/]*)
4107 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4108 ;;
4109 *)
4110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4111for as_dir in /usr/sbin
4112do
4113 IFS=$as_save_IFS
4114 test -z "$as_dir" && as_dir=.
4115 for ac_exec_ext in '' $ac_executable_extensions; do
4116 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4117 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4118 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4119 break 2
4120 fi
4121done
4122done
4123
4124 ;;
4125esac
4126fi
4127INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4128
4129if test -n "$INSTALL_INFO"; then
4130 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4131echo "${ECHO_T}$INSTALL_INFO" >&6
4132else
4133 echo "$as_me:$LINENO: result: no" >&5
4134echo "${ECHO_T}no" >&6
4135fi
4136
4137# Extract the first word of "install-info", so it can be a program name with args.
4138set dummy install-info; ac_word=$2
4139echo "$as_me:$LINENO: checking for $ac_word" >&5
4140echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4141if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4142 echo $ECHO_N "(cached) $ECHO_C" >&6
4143else
4144 case $INSTALL_INFO in
4145 [\\/]* | ?:[\\/]*)
4146 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4147 ;;
4148 *)
4149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4150for as_dir in /sbin
4151do
4152 IFS=$as_save_IFS
4153 test -z "$as_dir" && as_dir=.
4154 for ac_exec_ext in '' $ac_executable_extensions; do
4155 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4156 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4157 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4158 break 2
4159 fi
4160done
4161done
4162
4163 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4164 ;;
4165esac
4166fi
4167INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4168
4169if test -n "$INSTALL_INFO"; then
4170 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4171echo "${ECHO_T}$INSTALL_INFO" >&6
4172else
4173 echo "$as_me:$LINENO: result: no" >&5
4174echo "${ECHO_T}no" >&6
4175fi
4176
ba4481b5 4177
c0d27fcc 4178
8e967cf7
MR
4179if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4180then
4181 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4182fi
4183
4184if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4185then
4186 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4187fi
4188
c0d27fcc
MR
4189
4190
6bae0ccf
DL
4191echo "$as_me:$LINENO: checking for egrep" >&5
4192echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4193if test "${ac_cv_prog_egrep+set}" = set; then
4194 echo $ECHO_N "(cached) $ECHO_C" >&6
4195else
4196 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4197 then ac_cv_prog_egrep='grep -E'
4198 else ac_cv_prog_egrep='egrep'
4199 fi
4200fi
4201echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4202echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4203 EGREP=$ac_cv_prog_egrep
4204
4205
c0d27fcc
MR
4206
4207echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4208echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4209cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4210/* confdefs.h. */
4211_ACEOF
4212cat confdefs.h >>conftest.$ac_ext
4213cat >>conftest.$ac_ext <<_ACEOF
4214/* end confdefs.h. */
ba4481b5
DL
4215#ifdef _AIX
4216 yes
4217#endif
4218
503d2be0 4219_ACEOF
ba4481b5 4220if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4221 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4222 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4223echo "${ECHO_T}yes" >&6
c0d27fcc 4224cat >>confdefs.h <<\_ACEOF
ba4481b5 4225#define _ALL_SOURCE 1
c0d27fcc 4226_ACEOF
ba4481b5
DL
4227
4228else
c0d27fcc 4229 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4230echo "${ECHO_T}no" >&6
ba4481b5
DL
4231fi
4232rm -f conftest*
4233
c0d27fcc
MR
4234
4235
3b33a005
DL
4236#### Extract some information from the operating system and machine files.
4237
c0d27fcc 4238{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4239 - which libraries the lib-src programs will want, and
503d2be0
AS
4240 - whether the GNU malloc routines are usable..." >&5
4241echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4242 - which libraries the lib-src programs will want, and
503d2be0 4243 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4244
4245### First figure out CFLAGS (which we use for running the compiler here)
4246### and REAL_CFLAGS (which we use for real compilation).
4247### The two are the same except on a few systems, where they are made
4248### different to work around various lossages. For example,
4249### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4250### as implying static linking.
4251
4252### If the CFLAGS env var is specified, we use that value
4253### instead of the default.
4254
4255### It's not important that this name contain the PID; you can't run
4256### two configures in the same directory and have anything work
4257### anyway.
4258tempcname="conftest.c"
4259
4260echo '
4261#include "'${srcdir}'/src/'${opsysfile}'"
4262#include "'${srcdir}'/src/'${machfile}'"
4263#ifndef LIBS_MACHINE
4264#define LIBS_MACHINE
4265#endif
4266#ifndef LIBS_SYSTEM
4267#define LIBS_SYSTEM
4268#endif
4269#ifndef C_SWITCH_SYSTEM
4270#define C_SWITCH_SYSTEM
4271#endif
4272#ifndef C_SWITCH_MACHINE
4273#define C_SWITCH_MACHINE
4274#endif
4275configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4276configure___ c_switch_system=C_SWITCH_SYSTEM
4277configure___ c_switch_machine=C_SWITCH_MACHINE
4278
4279#ifndef LIB_X11_LIB
4280#define LIB_X11_LIB -lX11
4281#endif
4282
4283#ifndef LIBX11_MACHINE
4284#define LIBX11_MACHINE
4285#endif
4286
4287#ifndef LIBX11_SYSTEM
4288#define LIBX11_SYSTEM
4289#endif
4290configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4291
4292#ifdef UNEXEC
4293configure___ unexec=UNEXEC
4294#else
4295configure___ unexec=unexec.o
4296#endif
4297
4298#ifdef SYSTEM_MALLOC
4299configure___ system_malloc=yes
4300#else
4301configure___ system_malloc=no
4302#endif
4303
ef9e4345
GM
4304#ifdef USE_MMAP_FOR_BUFFERS
4305configure___ use_mmap_for_buffers=yes
73b77ee5 4306#else
ef9e4345 4307configure___ use_mmap_for_buffers=no
73b77ee5
GM
4308#endif
4309
3b33a005
DL
4310#ifndef C_DEBUG_SWITCH
4311#define C_DEBUG_SWITCH -g
4312#endif
4313
4314#ifndef C_OPTIMIZE_SWITCH
4315#ifdef __GNUC__
4316#define C_OPTIMIZE_SWITCH -O2
4317#else
4318#define C_OPTIMIZE_SWITCH -O
4319#endif
4320#endif
4321
4322#ifndef LD_SWITCH_MACHINE
4323#define LD_SWITCH_MACHINE
4324#endif
4325
4326#ifndef LD_SWITCH_SYSTEM
4327#define LD_SWITCH_SYSTEM
4328#endif
4329
4330#ifndef LD_SWITCH_X_SITE_AUX
4331#define LD_SWITCH_X_SITE_AUX
503d2be0 4332#endif
3b33a005
DL
4333
4334configure___ ld_switch_system=LD_SWITCH_SYSTEM
4335configure___ ld_switch_machine=LD_SWITCH_MACHINE
4336
4337#ifdef THIS_IS_CONFIGURE
4338
4339/* Get the CFLAGS for tests in configure. */
4340#ifdef __GNUC__
4341configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4342#else
4343configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4344#endif
4345
4346#else /* not THIS_IS_CONFIGURE */
4347
4348/* Get the CFLAGS for real compilation. */
4349#ifdef __GNUC__
4350configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4351#else
4352configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4353#endif
4354
4355#endif /* not THIS_IS_CONFIGURE */
4356' > ${tempcname}
4357
4358# The value of CPP is a quoted variable reference, so we need to do this
4359# to get its actual value...
4360CPP=`eval "echo $CPP"`
4361eval `${CPP} -Isrc ${tempcname} \
4362 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4363if test "x$SPECIFIED_CFLAGS" = x; then
4364 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4365 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4366else
4367 REAL_CFLAGS="$CFLAGS"
4368fi
4369rm ${tempcname}
4370
4371ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4372
4373### Make sure subsequent tests use flags consistent with the build flags.
4374
4375if test x"${OVERRIDE_CPPFLAGS}" != x; then
4376 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4377else
4378 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4379fi
4380
6bae0ccf
DL
4381
4382
22044edf
DL
4383
4384cat >>confdefs.h <<\_ACEOF
4385#define _GNU_SOURCE 1
4386_ACEOF
4387
4388
4389
503d2be0 4390# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4391if test "${enable_largefile+set}" = set; then
4392 enableval="$enable_largefile"
f4988be7 4393
503d2be0
AS
4394fi;
4395if test "$enable_largefile" != no; then
f4988be7 4396
c0d27fcc 4397 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4398echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4399if test "${ac_cv_sys_largefile_CC+set}" = set; then
4400 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4401else
f4988be7 4402 ac_cv_sys_largefile_CC=no
503d2be0
AS
4403 if test "$GCC" != yes; then
4404 ac_save_CC=$CC
4405 while :; do
4406 # IRIX 6.2 and later do not support large files by default,
4407 # so use the C compiler's -n32 option if that helps.
35996d22 4408 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4409/* confdefs.h. */
4410_ACEOF
4411cat confdefs.h >>conftest.$ac_ext
4412cat >>conftest.$ac_ext <<_ACEOF
4413/* end confdefs.h. */
f4988be7 4414#include <sys/types.h>
503d2be0
AS
4415 /* Check that off_t can represent 2**63 - 1 correctly.
4416 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4417 since some C++ compilers masquerading as C compilers
4418 incorrectly reject 9223372036854775807. */
4419#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4420 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4421 && LARGE_OFF_T % 2147483647 == 1)
4422 ? 1 : -1];
4423int
4424main ()
4425{
f4988be7 4426
503d2be0
AS
4427 ;
4428 return 0;
4429}
4430_ACEOF
4431 rm -f conftest.$ac_objext
c0d27fcc 4432if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4433 (eval $ac_compile) 2>conftest.er1
503d2be0 4434 ac_status=$?
35996d22
AS
4435 grep -v '^ *+' conftest.er1 >conftest.err
4436 rm -f conftest.er1
4437 cat conftest.err >&5
c0d27fcc 4438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4439 (exit $ac_status); } &&
35996d22
AS
4440 { ac_try='test -z "$ac_c_werror_flag"
4441 || test ! -s conftest.err'
4442 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4443 (eval $ac_try) 2>&5
4444 ac_status=$?
4445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4446 (exit $ac_status); }; } &&
4447 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4448 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4449 (eval $ac_try) 2>&5
4450 ac_status=$?
c0d27fcc 4451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4452 (exit $ac_status); }; }; then
4453 break
b192d653 4454else
503d2be0 4455 echo "$as_me: failed program was:" >&5
19650fd6
AS
4456sed 's/^/| /' conftest.$ac_ext >&5
4457
503d2be0 4458fi
35996d22 4459rm -f conftest.err conftest.$ac_objext
503d2be0
AS
4460 CC="$CC -n32"
4461 rm -f conftest.$ac_objext
c0d27fcc 4462if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4463 (eval $ac_compile) 2>conftest.er1
503d2be0 4464 ac_status=$?
35996d22
AS
4465 grep -v '^ *+' conftest.er1 >conftest.err
4466 rm -f conftest.er1
4467 cat conftest.err >&5
c0d27fcc 4468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4469 (exit $ac_status); } &&
35996d22
AS
4470 { ac_try='test -z "$ac_c_werror_flag"
4471 || test ! -s conftest.err'
4472 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4473 (eval $ac_try) 2>&5
4474 ac_status=$?
4475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4476 (exit $ac_status); }; } &&
4477 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4478 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4479 (eval $ac_try) 2>&5
4480 ac_status=$?
c0d27fcc 4481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4482 (exit $ac_status); }; }; then
4483 ac_cv_sys_largefile_CC=' -n32'; break
4484else
4485 echo "$as_me: failed program was:" >&5
19650fd6
AS
4486sed 's/^/| /' conftest.$ac_ext >&5
4487
503d2be0 4488fi
35996d22
AS
4489rm -f conftest.err conftest.$ac_objext
4490 break
503d2be0
AS
4491 done
4492 CC=$ac_save_CC
4493 rm -f conftest.$ac_ext
4494 fi
b192d653 4495fi
c0d27fcc 4496echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4497echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4498 if test "$ac_cv_sys_largefile_CC" != no; then
4499 CC=$CC$ac_cv_sys_largefile_CC
4500 fi
b192d653 4501
c0d27fcc 4502 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4503echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4504if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4505 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4506else
503d2be0 4507 while :; do
f4988be7 4508 ac_cv_sys_file_offset_bits=no
503d2be0 4509 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4510/* confdefs.h. */
4511_ACEOF
4512cat confdefs.h >>conftest.$ac_ext
4513cat >>conftest.$ac_ext <<_ACEOF
4514/* end confdefs.h. */
f4988be7 4515#include <sys/types.h>
503d2be0
AS
4516 /* Check that off_t can represent 2**63 - 1 correctly.
4517 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4518 since some C++ compilers masquerading as C compilers
4519 incorrectly reject 9223372036854775807. */
4520#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4521 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4522 && LARGE_OFF_T % 2147483647 == 1)
4523 ? 1 : -1];
4524int
4525main ()
4526{
f4988be7 4527
503d2be0
AS
4528 ;
4529 return 0;
4530}
4531_ACEOF
4532rm -f conftest.$ac_objext
c0d27fcc 4533if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4534 (eval $ac_compile) 2>conftest.er1
503d2be0 4535 ac_status=$?
35996d22
AS
4536 grep -v '^ *+' conftest.er1 >conftest.err
4537 rm -f conftest.er1
4538 cat conftest.err >&5
c0d27fcc 4539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4540 (exit $ac_status); } &&
35996d22
AS
4541 { ac_try='test -z "$ac_c_werror_flag"
4542 || test ! -s conftest.err'
4543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4544 (eval $ac_try) 2>&5
4545 ac_status=$?
4546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4547 (exit $ac_status); }; } &&
4548 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4549 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4550 (eval $ac_try) 2>&5
4551 ac_status=$?
c0d27fcc 4552 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4553 (exit $ac_status); }; }; then
4554 break
f4988be7 4555else
503d2be0 4556 echo "$as_me: failed program was:" >&5
19650fd6
AS
4557sed 's/^/| /' conftest.$ac_ext >&5
4558
503d2be0 4559fi
35996d22 4560rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4561 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4562/* confdefs.h. */
4563_ACEOF
4564cat confdefs.h >>conftest.$ac_ext
4565cat >>conftest.$ac_ext <<_ACEOF
4566/* end confdefs.h. */
f4988be7
GM
4567#define _FILE_OFFSET_BITS 64
4568#include <sys/types.h>
503d2be0
AS
4569 /* Check that off_t can represent 2**63 - 1 correctly.
4570 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4571 since some C++ compilers masquerading as C compilers
4572 incorrectly reject 9223372036854775807. */
4573#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4574 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4575 && LARGE_OFF_T % 2147483647 == 1)
4576 ? 1 : -1];
4577int
4578main ()
4579{
4580
4581 ;
4582 return 0;
4583}
4584_ACEOF
4585rm -f conftest.$ac_objext
c0d27fcc 4586if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4587 (eval $ac_compile) 2>conftest.er1
503d2be0 4588 ac_status=$?
35996d22
AS
4589 grep -v '^ *+' conftest.er1 >conftest.err
4590 rm -f conftest.er1
4591 cat conftest.err >&5
c0d27fcc 4592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4593 (exit $ac_status); } &&
35996d22
AS
4594 { ac_try='test -z "$ac_c_werror_flag"
4595 || test ! -s conftest.err'
4596 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4597 (eval $ac_try) 2>&5
4598 ac_status=$?
4599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4600 (exit $ac_status); }; } &&
4601 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4602 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4603 (eval $ac_try) 2>&5
4604 ac_status=$?
c0d27fcc 4605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4606 (exit $ac_status); }; }; then
4607 ac_cv_sys_file_offset_bits=64; break
4608else
4609 echo "$as_me: failed program was:" >&5
19650fd6
AS
4610sed 's/^/| /' conftest.$ac_ext >&5
4611
503d2be0 4612fi
35996d22 4613rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4614 break
4615done
ba4481b5 4616fi
c0d27fcc 4617echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4618echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4619if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4620
c0d27fcc 4621cat >>confdefs.h <<_ACEOF
f4988be7 4622#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4623_ACEOF
f4988be7 4624
503d2be0
AS
4625fi
4626rm -f conftest*
c0d27fcc 4627 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4628echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4629if test "${ac_cv_sys_large_files+set}" = set; then
4630 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4631else
503d2be0 4632 while :; do
f4988be7 4633 ac_cv_sys_large_files=no
503d2be0 4634 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4635/* confdefs.h. */
4636_ACEOF
4637cat confdefs.h >>conftest.$ac_ext
4638cat >>conftest.$ac_ext <<_ACEOF
4639/* end confdefs.h. */
503d2be0
AS
4640#include <sys/types.h>
4641 /* Check that off_t can represent 2**63 - 1 correctly.
4642 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4643 since some C++ compilers masquerading as C compilers
4644 incorrectly reject 9223372036854775807. */
4645#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4646 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4647 && LARGE_OFF_T % 2147483647 == 1)
4648 ? 1 : -1];
4649int
4650main ()
4651{
ba4481b5 4652
503d2be0
AS
4653 ;
4654 return 0;
4655}
4656_ACEOF
4657rm -f conftest.$ac_objext
c0d27fcc 4658if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4659 (eval $ac_compile) 2>conftest.er1
503d2be0 4660 ac_status=$?
35996d22
AS
4661 grep -v '^ *+' conftest.er1 >conftest.err
4662 rm -f conftest.er1
4663 cat conftest.err >&5
c0d27fcc 4664 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4665 (exit $ac_status); } &&
35996d22
AS
4666 { ac_try='test -z "$ac_c_werror_flag"
4667 || test ! -s conftest.err'
4668 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4669 (eval $ac_try) 2>&5
4670 ac_status=$?
4671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4672 (exit $ac_status); }; } &&
4673 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4674 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4675 (eval $ac_try) 2>&5
4676 ac_status=$?
c0d27fcc 4677 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4678 (exit $ac_status); }; }; then
4679 break
ba4481b5 4680else
503d2be0 4681 echo "$as_me: failed program was:" >&5
19650fd6
AS
4682sed 's/^/| /' conftest.$ac_ext >&5
4683
503d2be0 4684fi
35996d22 4685rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4686 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4687/* confdefs.h. */
4688_ACEOF
4689cat confdefs.h >>conftest.$ac_ext
4690cat >>conftest.$ac_ext <<_ACEOF
4691/* end confdefs.h. */
f4988be7 4692#define _LARGE_FILES 1
503d2be0
AS
4693#include <sys/types.h>
4694 /* Check that off_t can represent 2**63 - 1 correctly.
4695 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4696 since some C++ compilers masquerading as C compilers
4697 incorrectly reject 9223372036854775807. */
4698#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4699 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4700 && LARGE_OFF_T % 2147483647 == 1)
4701 ? 1 : -1];
4702int
4703main ()
4704{
f4988be7 4705
503d2be0
AS
4706 ;
4707 return 0;
4708}
4709_ACEOF
4710rm -f conftest.$ac_objext
c0d27fcc 4711if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4712 (eval $ac_compile) 2>conftest.er1
503d2be0 4713 ac_status=$?
35996d22
AS
4714 grep -v '^ *+' conftest.er1 >conftest.err
4715 rm -f conftest.er1
4716 cat conftest.err >&5
c0d27fcc 4717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4718 (exit $ac_status); } &&
35996d22
AS
4719 { ac_try='test -z "$ac_c_werror_flag"
4720 || test ! -s conftest.err'
4721 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4722 (eval $ac_try) 2>&5
4723 ac_status=$?
4724 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4725 (exit $ac_status); }; } &&
4726 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4727 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4728 (eval $ac_try) 2>&5
4729 ac_status=$?
c0d27fcc 4730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4731 (exit $ac_status); }; }; then
4732 ac_cv_sys_large_files=1; break
4733else
4734 echo "$as_me: failed program was:" >&5
19650fd6
AS
4735sed 's/^/| /' conftest.$ac_ext >&5
4736
503d2be0 4737fi
35996d22 4738rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4739 break
4740done
ba4481b5 4741fi
c0d27fcc 4742echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4743echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4744if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4745
c0d27fcc 4746cat >>confdefs.h <<_ACEOF
f4988be7 4747#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4748_ACEOF
ba4481b5 4749
503d2be0
AS
4750fi
4751rm -f conftest*
4752fi
ba4481b5 4753
c0d27fcc 4754
2c9dccc9
PJ
4755if test "${with_sound}" != "no"; then
4756 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4757 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4758echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4759if test "${ac_cv_header_stdc+set}" = set; then
4760 echo $ECHO_N "(cached) $ECHO_C" >&6
4761else
4762 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4763/* confdefs.h. */
4764_ACEOF
4765cat confdefs.h >>conftest.$ac_ext
4766cat >>conftest.$ac_ext <<_ACEOF
4767/* end confdefs.h. */
c0d27fcc
MR
4768#include <stdlib.h>
4769#include <stdarg.h>
4770#include <string.h>
4771#include <float.h>
98418dba 4772
19650fd6
AS
4773int
4774main ()
4775{
4776
4777 ;
4778 return 0;
4779}
c0d27fcc 4780_ACEOF
19650fd6
AS
4781rm -f conftest.$ac_objext
4782if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4783 (eval $ac_compile) 2>conftest.er1
cd958eb3 4784 ac_status=$?
35996d22
AS
4785 grep -v '^ *+' conftest.er1 >conftest.err
4786 rm -f conftest.er1
4787 cat conftest.err >&5
cd958eb3 4788 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 4789 (exit $ac_status); } &&
35996d22
AS
4790 { ac_try='test -z "$ac_c_werror_flag"
4791 || test ! -s conftest.err'
4792 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4793 (eval $ac_try) 2>&5
4794 ac_status=$?
4795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4796 (exit $ac_status); }; } &&
4797 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
4798 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4799 (eval $ac_try) 2>&5
4800 ac_status=$?
4801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4802 (exit $ac_status); }; }; then
c0d27fcc
MR
4803 ac_cv_header_stdc=yes
4804else
4805 echo "$as_me: failed program was:" >&5
19650fd6
AS
4806sed 's/^/| /' conftest.$ac_ext >&5
4807
4808ac_cv_header_stdc=no
c0d27fcc 4809fi
35996d22 4810rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4811
4812if test $ac_cv_header_stdc = yes; then
4813 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4814 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4815/* confdefs.h. */
4816_ACEOF
4817cat confdefs.h >>conftest.$ac_ext
4818cat >>conftest.$ac_ext <<_ACEOF
4819/* end confdefs.h. */
c0d27fcc
MR
4820#include <string.h>
4821
4822_ACEOF
4823if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4824 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4825 :
4826else
4827 ac_cv_header_stdc=no
4828fi
4829rm -f conftest*
4830
4831fi
4832
4833if test $ac_cv_header_stdc = yes; then
4834 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4835 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4836/* confdefs.h. */
4837_ACEOF
4838cat confdefs.h >>conftest.$ac_ext
4839cat >>conftest.$ac_ext <<_ACEOF
4840/* end confdefs.h. */
c0d27fcc
MR
4841#include <stdlib.h>
4842
4843_ACEOF
4844if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4845 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4846 :
4847else
4848 ac_cv_header_stdc=no
4849fi
4850rm -f conftest*
4851
4852fi
4853
4854if test $ac_cv_header_stdc = yes; then
4855 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4856 if test "$cross_compiling" = yes; then
4857 :
4858else
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 <ctype.h>
4866#if ((' ' & 0x0FF) == 0x020)
4867# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4868# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4869#else
19650fd6 4870# define ISLOWER(c) \
35996d22
AS
4871 (('a' <= (c) && (c) <= 'i') \
4872 || ('j' <= (c) && (c) <= 'r') \
4873 || ('s' <= (c) && (c) <= 'z'))
c0d27fcc
MR
4874# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4875#endif
4876
4877#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4878int
4879main ()
4880{
4881 int i;
4882 for (i = 0; i < 256; i++)
4883 if (XOR (islower (i), ISLOWER (i))
35996d22 4884 || toupper (i) != TOUPPER (i))
c0d27fcc
MR
4885 exit(2);
4886 exit (0);
4887}
4888_ACEOF
4889rm -f conftest$ac_exeext
4890if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4891 (eval $ac_link) 2>&5
4892 ac_status=$?
4893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4894 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4895 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4896 (eval $ac_try) 2>&5
4897 ac_status=$?
4898 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4899 (exit $ac_status); }; }; then
4900 :
4901else
4902 echo "$as_me: program exited with status $ac_status" >&5
4903echo "$as_me: failed program was:" >&5
19650fd6
AS
4904sed 's/^/| /' conftest.$ac_ext >&5
4905
c0d27fcc
MR
4906( exit $ac_status )
4907ac_cv_header_stdc=no
4908fi
35996d22 4909rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4910fi
4911fi
4912fi
4913echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4914echo "${ECHO_T}$ac_cv_header_stdc" >&6
4915if test $ac_cv_header_stdc = yes; then
4916
4917cat >>confdefs.h <<\_ACEOF
4918#define STDC_HEADERS 1
4919_ACEOF
4920
4921fi
4922
4923# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
35996d22 4934 inttypes.h stdint.h unistd.h
98418dba
CW
4935do
4936as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4937echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4938echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4939if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4940 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4941else
925c2f3f 4942 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4943/* confdefs.h. */
4944_ACEOF
4945cat confdefs.h >>conftest.$ac_ext
4946cat >>conftest.$ac_ext <<_ACEOF
4947/* end confdefs.h. */
c0d27fcc
MR
4948$ac_includes_default
4949
4950#include <$ac_header>
4951_ACEOF
4952rm -f conftest.$ac_objext
4953if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4954 (eval $ac_compile) 2>conftest.er1
c0d27fcc 4955 ac_status=$?
35996d22
AS
4956 grep -v '^ *+' conftest.er1 >conftest.err
4957 rm -f conftest.er1
4958 cat conftest.err >&5
c0d27fcc
MR
4959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4960 (exit $ac_status); } &&
35996d22
AS
4961 { ac_try='test -z "$ac_c_werror_flag"
4962 || test ! -s conftest.err'
4963 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4964 (eval $ac_try) 2>&5
4965 ac_status=$?
4966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4967 (exit $ac_status); }; } &&
4968 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
4969 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4970 (eval $ac_try) 2>&5
4971 ac_status=$?
4972 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4973 (exit $ac_status); }; }; then
4974 eval "$as_ac_Header=yes"
4975else
4976 echo "$as_me: failed program was:" >&5
19650fd6
AS
4977sed 's/^/| /' conftest.$ac_ext >&5
4978
c0d27fcc
MR
4979eval "$as_ac_Header=no"
4980fi
35996d22 4981rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4982fi
4983echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4984echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4985if test `eval echo '${'$as_ac_Header'}'` = yes; then
4986 cat >>confdefs.h <<_ACEOF
4987#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4988_ACEOF
4989
4990fi
4991
4992done
4993
4994
4995
4996
4997
4998for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
4999do
5000as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5001if eval "test \"\${$as_ac_Header+set}\" = set"; then
5002 echo "$as_me:$LINENO: checking for $ac_header" >&5
5003echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5004if eval "test \"\${$as_ac_Header+set}\" = set"; then
5005 echo $ECHO_N "(cached) $ECHO_C" >&6
5006fi
5007echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5008echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5009else
5010 # Is the header compilable?
5011echo "$as_me:$LINENO: checking $ac_header usability" >&5
5012echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5013cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5014/* confdefs.h. */
5015_ACEOF
5016cat confdefs.h >>conftest.$ac_ext
5017cat >>conftest.$ac_ext <<_ACEOF
5018/* end confdefs.h. */
c0d27fcc 5019$ac_includes_default
98418dba 5020#include <$ac_header>
503d2be0 5021_ACEOF
c0d27fcc
MR
5022rm -f conftest.$ac_objext
5023if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5024 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5025 ac_status=$?
35996d22
AS
5026 grep -v '^ *+' conftest.er1 >conftest.err
5027 rm -f conftest.er1
5028 cat conftest.err >&5
c0d27fcc
MR
5029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5030 (exit $ac_status); } &&
35996d22
AS
5031 { ac_try='test -z "$ac_c_werror_flag"
5032 || test ! -s conftest.err'
5033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5034 (eval $ac_try) 2>&5
5035 ac_status=$?
5036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5037 (exit $ac_status); }; } &&
5038 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5039 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5040 (eval $ac_try) 2>&5
5041 ac_status=$?
5042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5043 (exit $ac_status); }; }; then
5044 ac_header_compiler=yes
5045else
5046 echo "$as_me: failed program was:" >&5
19650fd6
AS
5047sed 's/^/| /' conftest.$ac_ext >&5
5048
c0d27fcc
MR
5049ac_header_compiler=no
5050fi
35996d22 5051rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5052echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5053echo "${ECHO_T}$ac_header_compiler" >&6
5054
5055# Is the header present?
5056echo "$as_me:$LINENO: checking $ac_header presence" >&5
5057echo $ECHO_N "checking $ac_header presence... $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
MR
5064#include <$ac_header>
5065_ACEOF
5066if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5067 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5068 ac_status=$?
6bae0ccf 5069 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5070 rm -f conftest.er1
5071 cat conftest.err >&5
c0d27fcc 5072 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5073 (exit $ac_status); } >/dev/null; then
5074 if test -s conftest.err; then
5075 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5076 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5077 else
5078 ac_cpp_err=
5079 fi
5080else
5081 ac_cpp_err=yes
5082fi
5083if test -z "$ac_cpp_err"; then
c0d27fcc 5084 ac_header_preproc=yes
f4988be7 5085else
503d2be0 5086 echo "$as_me: failed program was:" >&5
19650fd6
AS
5087sed 's/^/| /' conftest.$ac_ext >&5
5088
c0d27fcc 5089 ac_header_preproc=no
f4988be7 5090fi
98418dba 5091rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5092echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5093echo "${ECHO_T}$ac_header_preproc" >&6
5094
5095# So? What about this header?
35996d22
AS
5096case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5097 yes:no: )
c0d27fcc
MR
5098 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5099echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5100 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5101echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5102 ac_header_preproc=yes
19650fd6 5103 ;;
35996d22 5104 no:yes:* )
c0d27fcc
MR
5105 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5106echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5107 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5108echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5109 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5110echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5111 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5112echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5113 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5114echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5115 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5116echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5117 (
5118 cat <<\_ASBOX
35996d22
AS
5119## ------------------------------------------ ##
5120## Report this to the AC_PACKAGE_NAME lists. ##
5121## ------------------------------------------ ##
19650fd6
AS
5122_ASBOX
5123 ) |
5124 sed "s/^/$as_me: WARNING: /" >&2
5125 ;;
c0d27fcc
MR
5126esac
5127echo "$as_me:$LINENO: checking for $ac_header" >&5
5128echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5129if eval "test \"\${$as_ac_Header+set}\" = set"; then
5130 echo $ECHO_N "(cached) $ECHO_C" >&6
5131else
35996d22 5132 eval "$as_ac_Header=\$ac_header_preproc"
f4988be7 5133fi
c0d27fcc 5134echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5135echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5136
5137fi
98418dba 5138if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5139 cat >>confdefs.h <<_ACEOF
98418dba 5140#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5141_ACEOF
f4988be7
GM
5142
5143fi
c0d27fcc 5144
98418dba
CW
5145done
5146
5147 # Emulation library used on NetBSD.
c0d27fcc 5148 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
5149echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
5150if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 5151 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5152else
98418dba
CW
5153 ac_check_lib_save_LIBS=$LIBS
5154LIBS="-lossaudio $LIBS"
5155cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5156/* confdefs.h. */
5157_ACEOF
5158cat confdefs.h >>conftest.$ac_ext
5159cat >>conftest.$ac_ext <<_ACEOF
5160/* end confdefs.h. */
98418dba
CW
5161
5162/* Override any gcc2 internal prototype to avoid an error. */
5163#ifdef __cplusplus
5164extern "C"
f4988be7 5165#endif
98418dba
CW
5166/* We use char because int might match the return type of a gcc2
5167 builtin and then its argument prototype would still apply. */
5168char _oss_ioctl ();
503d2be0
AS
5169int
5170main ()
5171{
98418dba 5172_oss_ioctl ();
503d2be0
AS
5173 ;
5174 return 0;
5175}
5176_ACEOF
98418dba 5177rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 5178if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 5179 (eval $ac_link) 2>conftest.er1
503d2be0 5180 ac_status=$?
35996d22
AS
5181 grep -v '^ *+' conftest.er1 >conftest.err
5182 rm -f conftest.er1
5183 cat conftest.err >&5
c0d27fcc 5184 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5185 (exit $ac_status); } &&
35996d22
AS
5186 { ac_try='test -z "$ac_c_werror_flag"
5187 || test ! -s conftest.err'
5188 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5189 (eval $ac_try) 2>&5
5190 ac_status=$?
5191 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5192 (exit $ac_status); }; } &&
5193 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 5194 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5195 (eval $ac_try) 2>&5
5196 ac_status=$?
c0d27fcc 5197 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5198 (exit $ac_status); }; }; then
98418dba 5199 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 5200else
503d2be0 5201 echo "$as_me: failed program was:" >&5
19650fd6
AS
5202sed 's/^/| /' conftest.$ac_ext >&5
5203
98418dba 5204ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 5205fi
35996d22
AS
5206rm -f conftest.err conftest.$ac_objext \
5207 conftest$ac_exeext conftest.$ac_ext
98418dba 5208LIBS=$ac_check_lib_save_LIBS
f4988be7 5209fi
c0d27fcc 5210echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
5211echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5212if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5213 LIBSOUND=-lossaudio
5214else
5215 LIBSOUND=
5216fi
5217
c0d27fcc 5218
f4988be7 5219fi
c0d27fcc
MR
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
22044edf
DL
5238
5239
973a76b1 5240
cffcede7 5241
c0d27fcc 5242
f4988be7 5243
98418dba
CW
5244for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5245 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
25ca0bca 5246 termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
cffcede7 5247 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h
98418dba
CW
5248do
5249as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5250if eval "test \"\${$as_ac_Header+set}\" = set"; then
5251 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5252echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5253if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5254 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5255fi
5256echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5257echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5258else
c0d27fcc
MR
5259 # Is the header compilable?
5260echo "$as_me:$LINENO: checking $ac_header usability" >&5
5261echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5262cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5263/* confdefs.h. */
5264_ACEOF
5265cat confdefs.h >>conftest.$ac_ext
5266cat >>conftest.$ac_ext <<_ACEOF
5267/* end confdefs.h. */
c0d27fcc
MR
5268$ac_includes_default
5269#include <$ac_header>
5270_ACEOF
5271rm -f conftest.$ac_objext
5272if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5273 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5274 ac_status=$?
35996d22
AS
5275 grep -v '^ *+' conftest.er1 >conftest.err
5276 rm -f conftest.er1
5277 cat conftest.err >&5
c0d27fcc
MR
5278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5279 (exit $ac_status); } &&
35996d22
AS
5280 { ac_try='test -z "$ac_c_werror_flag"
5281 || test ! -s conftest.err'
5282 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5283 (eval $ac_try) 2>&5
5284 ac_status=$?
5285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5286 (exit $ac_status); }; } &&
5287 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5288 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5289 (eval $ac_try) 2>&5
5290 ac_status=$?
5291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5292 (exit $ac_status); }; }; then
5293 ac_header_compiler=yes
5294else
5295 echo "$as_me: failed program was:" >&5
19650fd6
AS
5296sed 's/^/| /' conftest.$ac_ext >&5
5297
c0d27fcc
MR
5298ac_header_compiler=no
5299fi
35996d22 5300rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5301echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5302echo "${ECHO_T}$ac_header_compiler" >&6
5303
5304# Is the header present?
5305echo "$as_me:$LINENO: checking $ac_header presence" >&5
5306echo $ECHO_N "checking $ac_header presence... $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. */
98418dba 5313#include <$ac_header>
503d2be0 5314_ACEOF
c0d27fcc 5315if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5316 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5317 ac_status=$?
6bae0ccf 5318 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5319 rm -f conftest.er1
5320 cat conftest.err >&5
c0d27fcc 5321 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5322 (exit $ac_status); } >/dev/null; then
5323 if test -s conftest.err; then
5324 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5325 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5326 else
5327 ac_cpp_err=
5328 fi
5329else
5330 ac_cpp_err=yes
5331fi
5332if test -z "$ac_cpp_err"; then
c0d27fcc 5333 ac_header_preproc=yes
34ec9ebe 5334else
503d2be0 5335 echo "$as_me: failed program was:" >&5
19650fd6
AS
5336sed 's/^/| /' conftest.$ac_ext >&5
5337
c0d27fcc 5338 ac_header_preproc=no
34ec9ebe 5339fi
98418dba 5340rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5341echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5342echo "${ECHO_T}$ac_header_preproc" >&6
5343
5344# So? What about this header?
35996d22
AS
5345case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5346 yes:no: )
c0d27fcc
MR
5347 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5348echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5349 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5350echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5351 ac_header_preproc=yes
19650fd6 5352 ;;
35996d22 5353 no:yes:* )
c0d27fcc
MR
5354 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5355echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5356 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5357echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5358 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5359echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5360 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5361echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5362 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5363echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5364 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5365echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5366 (
5367 cat <<\_ASBOX
35996d22
AS
5368## ------------------------------------------ ##
5369## Report this to the AC_PACKAGE_NAME lists. ##
5370## ------------------------------------------ ##
19650fd6
AS
5371_ASBOX
5372 ) |
5373 sed "s/^/$as_me: WARNING: /" >&2
5374 ;;
c0d27fcc
MR
5375esac
5376echo "$as_me:$LINENO: checking for $ac_header" >&5
5377echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5378if eval "test \"\${$as_ac_Header+set}\" = set"; then
5379 echo $ECHO_N "(cached) $ECHO_C" >&6
5380else
35996d22 5381 eval "$as_ac_Header=\$ac_header_preproc"
34ec9ebe 5382fi
c0d27fcc 5383echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5384echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5385
5386fi
98418dba 5387if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5388 cat >>confdefs.h <<_ACEOF
98418dba 5389#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5390_ACEOF
34ec9ebe 5391
98418dba 5392fi
c0d27fcc 5393
98418dba
CW
5394done
5395
22044edf
DL
5396
5397for ac_header in term.h
5398do
5399as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5400echo "$as_me:$LINENO: checking for $ac_header" >&5
5401echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5402if eval "test \"\${$as_ac_Header+set}\" = set"; then
5403 echo $ECHO_N "(cached) $ECHO_C" >&6
5404else
5405 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5406/* confdefs.h. */
5407_ACEOF
5408cat confdefs.h >>conftest.$ac_ext
5409cat >>conftest.$ac_ext <<_ACEOF
5410/* end confdefs.h. */
22044edf
DL
5411#include <$ac_header>
5412_ACEOF
5413if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5414 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5415 ac_status=$?
5416 grep -v '^ *+' conftest.er1 >conftest.err
5417 rm -f conftest.er1
5418 cat conftest.err >&5
5419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5420 (exit $ac_status); } >/dev/null; then
5421 if test -s conftest.err; then
5422 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5423 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22044edf
DL
5424 else
5425 ac_cpp_err=
5426 fi
5427else
5428 ac_cpp_err=yes
5429fi
5430if test -z "$ac_cpp_err"; then
5431 eval "$as_ac_Header=yes"
5432else
5433 echo "$as_me: failed program was:" >&5
19650fd6
AS
5434sed 's/^/| /' conftest.$ac_ext >&5
5435
22044edf
DL
5436 eval "$as_ac_Header=no"
5437fi
5438rm -f conftest.err conftest.$ac_ext
5439fi
5440echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5441echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5442if test `eval echo '${'$as_ac_Header'}'` = yes; then
5443 cat >>confdefs.h <<_ACEOF
5444#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5445_ACEOF
5446
5447fi
5448
5449done
5450
c0d27fcc 5451echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5452echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5453if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5454 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5455else
503d2be0 5456 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5457/* confdefs.h. */
5458_ACEOF
5459cat confdefs.h >>conftest.$ac_ext
5460cat >>conftest.$ac_ext <<_ACEOF
5461/* end confdefs.h. */
98418dba
CW
5462#include <stdlib.h>
5463#include <stdarg.h>
5464#include <string.h>
5465#include <float.h>
5466
19650fd6
AS
5467int
5468main ()
5469{
5470
5471 ;
5472 return 0;
5473}
98418dba 5474_ACEOF
19650fd6
AS
5475rm -f conftest.$ac_objext
5476if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5477 (eval $ac_compile) 2>conftest.er1
cd958eb3 5478 ac_status=$?
35996d22
AS
5479 grep -v '^ *+' conftest.er1 >conftest.err
5480 rm -f conftest.er1
5481 cat conftest.err >&5
cd958eb3 5482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 5483 (exit $ac_status); } &&
35996d22
AS
5484 { ac_try='test -z "$ac_c_werror_flag"
5485 || test ! -s conftest.err'
5486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5487 (eval $ac_try) 2>&5
5488 ac_status=$?
5489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5490 (exit $ac_status); }; } &&
5491 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
5492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5493 (eval $ac_try) 2>&5
5494 ac_status=$?
5495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5496 (exit $ac_status); }; }; then
98418dba 5497 ac_cv_header_stdc=yes
ba4481b5 5498else
503d2be0 5499 echo "$as_me: failed program was:" >&5
19650fd6
AS
5500sed 's/^/| /' conftest.$ac_ext >&5
5501
5502ac_cv_header_stdc=no
ba4481b5 5503fi
35996d22 5504rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5505
5506if test $ac_cv_header_stdc = yes; then
5507 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5508 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5509/* confdefs.h. */
5510_ACEOF
5511cat confdefs.h >>conftest.$ac_ext
5512cat >>conftest.$ac_ext <<_ACEOF
5513/* end confdefs.h. */
98418dba
CW
5514#include <string.h>
5515
5516_ACEOF
5517if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5518 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5519 :
5520else
5521 ac_cv_header_stdc=no
ba4481b5 5522fi
98418dba 5523rm -f conftest*
ba4481b5
DL
5524
5525fi
5526
98418dba
CW
5527if test $ac_cv_header_stdc = yes; then
5528 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5529 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5530/* confdefs.h. */
5531_ACEOF
5532cat confdefs.h >>conftest.$ac_ext
5533cat >>conftest.$ac_ext <<_ACEOF
5534/* end confdefs.h. */
98418dba
CW
5535#include <stdlib.h>
5536
5537_ACEOF
5538if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5539 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5540 :
5541else
5542 ac_cv_header_stdc=no
5543fi
5544rm -f conftest*
5545
5546fi
5547
5548if test $ac_cv_header_stdc = yes; then
5549 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5550 if test "$cross_compiling" = yes; then
5551 :
d42122a3 5552else
503d2be0 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 <ctype.h>
5560#if ((' ' & 0x0FF) == 0x020)
5561# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5562# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5563#else
19650fd6 5564# define ISLOWER(c) \
35996d22
AS
5565 (('a' <= (c) && (c) <= 'i') \
5566 || ('j' <= (c) && (c) <= 'r') \
5567 || ('s' <= (c) && (c) <= 'z'))
98418dba
CW
5568# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5569#endif
5570
5571#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5572int
5573main ()
5574{
98418dba
CW
5575 int i;
5576 for (i = 0; i < 256; i++)
5577 if (XOR (islower (i), ISLOWER (i))
35996d22 5578 || toupper (i) != TOUPPER (i))
98418dba
CW
5579 exit(2);
5580 exit (0);
503d2be0
AS
5581}
5582_ACEOF
98418dba 5583rm -f conftest$ac_exeext
c0d27fcc 5584if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5585 (eval $ac_link) 2>&5
503d2be0 5586 ac_status=$?
c0d27fcc 5587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5588 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5590 (eval $ac_try) 2>&5
5591 ac_status=$?
c0d27fcc 5592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5593 (exit $ac_status); }; }; then
98418dba 5594 :
d42122a3 5595else
98418dba
CW
5596 echo "$as_me: program exited with status $ac_status" >&5
5597echo "$as_me: failed program was:" >&5
19650fd6
AS
5598sed 's/^/| /' conftest.$ac_ext >&5
5599
c0d27fcc 5600( exit $ac_status )
98418dba 5601ac_cv_header_stdc=no
d42122a3 5602fi
35996d22 5603rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5604fi
98418dba
CW
5605fi
5606fi
c0d27fcc 5607echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5608echo "${ECHO_T}$ac_cv_header_stdc" >&6
5609if test $ac_cv_header_stdc = yes; then
5610
c0d27fcc 5611cat >>confdefs.h <<\_ACEOF
98418dba 5612#define STDC_HEADERS 1
c0d27fcc 5613_ACEOF
d42122a3
DL
5614
5615fi
5616
c0d27fcc 5617echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5618echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5619if test "${ac_cv_header_time+set}" = set; then
503d2be0 5620 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5621else
503d2be0 5622 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5623/* confdefs.h. */
5624_ACEOF
5625cat confdefs.h >>conftest.$ac_ext
5626cat >>conftest.$ac_ext <<_ACEOF
5627/* end confdefs.h. */
ba4481b5 5628#include <sys/types.h>
98418dba 5629#include <sys/time.h>
ba4481b5 5630#include <time.h>
503d2be0
AS
5631
5632int
5633main ()
5634{
98418dba
CW
5635if ((struct tm *) 0)
5636return 0;
503d2be0
AS
5637 ;
5638 return 0;
5639}
5640_ACEOF
5641rm -f conftest.$ac_objext
c0d27fcc 5642if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5643 (eval $ac_compile) 2>conftest.er1
503d2be0 5644 ac_status=$?
35996d22
AS
5645 grep -v '^ *+' conftest.er1 >conftest.err
5646 rm -f conftest.er1
5647 cat conftest.err >&5
c0d27fcc 5648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5649 (exit $ac_status); } &&
35996d22
AS
5650 { ac_try='test -z "$ac_c_werror_flag"
5651 || test ! -s conftest.err'
5652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5653 (eval $ac_try) 2>&5
5654 ac_status=$?
5655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5656 (exit $ac_status); }; } &&
5657 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5658 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5659 (eval $ac_try) 2>&5
5660 ac_status=$?
c0d27fcc 5661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5662 (exit $ac_status); }; }; then
98418dba 5663 ac_cv_header_time=yes
ba4481b5 5664else
503d2be0 5665 echo "$as_me: failed program was:" >&5
19650fd6
AS
5666sed 's/^/| /' conftest.$ac_ext >&5
5667
98418dba 5668ac_cv_header_time=no
ba4481b5 5669fi
35996d22 5670rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5671fi
c0d27fcc 5672echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5673echo "${ECHO_T}$ac_cv_header_time" >&6
5674if test $ac_cv_header_time = yes; then
503d2be0 5675
c0d27fcc 5676cat >>confdefs.h <<\_ACEOF
98418dba 5677#define TIME_WITH_SYS_TIME 1
c0d27fcc 5678_ACEOF
ba4481b5
DL
5679
5680fi
5681
cd958eb3
MB
5682echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5683echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5684if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5685 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5686else
503d2be0 5687 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5688/* confdefs.h. */
5689_ACEOF
5690cat confdefs.h >>conftest.$ac_ext
5691cat >>conftest.$ac_ext <<_ACEOF
5692/* end confdefs.h. */
cd958eb3
MB
5693$ac_includes_default
5694int
5695main ()
5696{
5697#ifndef sys_siglist
5698 char *p = (char *) sys_siglist;
98418dba 5699#endif
503d2be0 5700
cd958eb3
MB
5701 ;
5702 return 0;
5703}
5704_ACEOF
5705rm -f conftest.$ac_objext
5706if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5707 (eval $ac_compile) 2>conftest.er1
cd958eb3 5708 ac_status=$?
35996d22
AS
5709 grep -v '^ *+' conftest.er1 >conftest.err
5710 rm -f conftest.er1
5711 cat conftest.err >&5
cd958eb3
MB
5712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5713 (exit $ac_status); } &&
35996d22
AS
5714 { ac_try='test -z "$ac_c_werror_flag"
5715 || test ! -s conftest.err'
5716 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5717 (eval $ac_try) 2>&5
5718 ac_status=$?
5719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5720 (exit $ac_status); }; } &&
5721 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
5722 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5723 (eval $ac_try) 2>&5
5724 ac_status=$?
5725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5726 (exit $ac_status); }; }; then
5727 ac_cv_have_decl_sys_siglist=yes
5728else
5729 echo "$as_me: failed program was:" >&5
19650fd6
AS
5730sed 's/^/| /' conftest.$ac_ext >&5
5731
cd958eb3
MB
5732ac_cv_have_decl_sys_siglist=no
5733fi
35996d22 5734rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
5735fi
5736echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5737echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5738if test $ac_cv_have_decl_sys_siglist = yes; then
5739
5740cat >>confdefs.h <<_ACEOF
5741#define HAVE_DECL_SYS_SIGLIST 1
5742_ACEOF
5743
5744
5745else
5746 cat >>confdefs.h <<_ACEOF
5747#define HAVE_DECL_SYS_SIGLIST 0
5748_ACEOF
5749
5750
5751fi
5752
5753
5754if test $ac_cv_have_decl_sys_siglist != yes; then
5755 # For Tru64, at least:
5756 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5757echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5758if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5759 echo $ECHO_N "(cached) $ECHO_C" >&6
5760else
5761 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5762/* confdefs.h. */
5763_ACEOF
5764cat confdefs.h >>conftest.$ac_ext
5765cat >>conftest.$ac_ext <<_ACEOF
5766/* end confdefs.h. */
cd958eb3 5767$ac_includes_default
503d2be0
AS
5768int
5769main ()
5770{
cd958eb3
MB
5771#ifndef __sys_siglist
5772 char *p = (char *) __sys_siglist;
5773#endif
5774
503d2be0
AS
5775 ;
5776 return 0;
5777}
5778_ACEOF
5779rm -f conftest.$ac_objext
c0d27fcc 5780if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5781 (eval $ac_compile) 2>conftest.er1
503d2be0 5782 ac_status=$?
35996d22
AS
5783 grep -v '^ *+' conftest.er1 >conftest.err
5784 rm -f conftest.er1
5785 cat conftest.err >&5
c0d27fcc 5786 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5787 (exit $ac_status); } &&
35996d22
AS
5788 { ac_try='test -z "$ac_c_werror_flag"
5789 || test ! -s conftest.err'
5790 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5791 (eval $ac_try) 2>&5
5792 ac_status=$?
5793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5794 (exit $ac_status); }; } &&
5795 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5797 (eval $ac_try) 2>&5
5798 ac_status=$?
c0d27fcc 5799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5800 (exit $ac_status); }; }; then
cd958eb3 5801 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5802else
503d2be0 5803 echo "$as_me: failed program was:" >&5
19650fd6
AS
5804sed 's/^/| /' conftest.$ac_ext >&5
5805
cd958eb3 5806ac_cv_have_decl___sys_siglist=no
ba4481b5 5807fi
35996d22 5808rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 5809fi
cd958eb3
MB
5810echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5811echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5812if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5813
cd958eb3
MB
5814cat >>confdefs.h <<_ACEOF
5815#define HAVE_DECL___SYS_SIGLIST 1
5816_ACEOF
5817
5818
5819else
5820 cat >>confdefs.h <<_ACEOF
5821#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5822_ACEOF
503d2be0 5823
cd958eb3 5824
ba4481b5
DL
5825fi
5826
cd958eb3
MB
5827
5828 if test $ac_cv_have_decl___sys_siglist = yes; then
5829
5830cat >>confdefs.h <<\_ACEOF
5831#define sys_siglist __sys_siglist
5832_ACEOF
5833
5834 fi
5835fi
c0d27fcc 5836echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5837echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5838if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5839 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5840else
503d2be0 5841 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5842/* confdefs.h. */
5843_ACEOF
5844cat confdefs.h >>conftest.$ac_ext
5845cat >>conftest.$ac_ext <<_ACEOF
5846/* end confdefs.h. */
98418dba
CW
5847#include <sys/types.h>
5848#include <sys/wait.h>
5849#ifndef WEXITSTATUS
5850# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5851#endif
5852#ifndef WIFEXITED
5853# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5854#endif
503d2be0
AS
5855
5856int
5857main ()
5858{
98418dba
CW
5859 int s;
5860 wait (&s);
5861 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5862 ;
5863 return 0;
5864}
5865_ACEOF
98418dba 5866rm -f conftest.$ac_objext
c0d27fcc 5867if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5868 (eval $ac_compile) 2>conftest.er1
503d2be0 5869 ac_status=$?
35996d22
AS
5870 grep -v '^ *+' conftest.er1 >conftest.err
5871 rm -f conftest.er1
5872 cat conftest.err >&5
c0d27fcc 5873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5874 (exit $ac_status); } &&
35996d22
AS
5875 { ac_try='test -z "$ac_c_werror_flag"
5876 || test ! -s conftest.err'
5877 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5878 (eval $ac_try) 2>&5
5879 ac_status=$?
5880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5881 (exit $ac_status); }; } &&
5882 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5883 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5884 (eval $ac_try) 2>&5
5885 ac_status=$?
c0d27fcc 5886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5887 (exit $ac_status); }; }; then
98418dba 5888 ac_cv_header_sys_wait_h=yes
ba4481b5 5889else
503d2be0 5890 echo "$as_me: failed program was:" >&5
19650fd6
AS
5891sed 's/^/| /' conftest.$ac_ext >&5
5892
98418dba 5893ac_cv_header_sys_wait_h=no
ba4481b5 5894fi
35996d22 5895rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5896fi
c0d27fcc 5897echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5898echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5899if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5900
c0d27fcc 5901cat >>confdefs.h <<\_ACEOF
98418dba 5902#define HAVE_SYS_WAIT_H 1
c0d27fcc 5903_ACEOF
ba4481b5 5904
ba4481b5
DL
5905fi
5906
c0d27fcc
MR
5907
5908echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5909echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5910if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5911 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5912else
503d2be0 5913 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5914/* confdefs.h. */
5915_ACEOF
5916cat confdefs.h >>conftest.$ac_ext
5917cat >>conftest.$ac_ext <<_ACEOF
5918/* end confdefs.h. */
98418dba
CW
5919#ifdef TIME_WITH_SYS_TIME
5920#include <sys/time.h>
5921#include <time.h>
5922#else
5923#ifdef HAVE_SYS_TIME_H
5924#include <sys/time.h>
5925#else
1113b624 5926#include <time.h>
98418dba
CW
5927#endif
5928#endif
5929#ifdef HAVE_UTIME_H
5930#include <utime.h>
5931#endif
503d2be0
AS
5932int
5933main ()
5934{
98418dba 5935static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5936 ;
5937 return 0;
5938}
5939_ACEOF
98418dba 5940rm -f conftest.$ac_objext
c0d27fcc 5941if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5942 (eval $ac_compile) 2>conftest.er1
503d2be0 5943 ac_status=$?
35996d22
AS
5944 grep -v '^ *+' conftest.er1 >conftest.err
5945 rm -f conftest.er1
5946 cat conftest.err >&5
c0d27fcc 5947 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5948 (exit $ac_status); } &&
35996d22
AS
5949 { ac_try='test -z "$ac_c_werror_flag"
5950 || test ! -s conftest.err'
5951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5952 (eval $ac_try) 2>&5
5953 ac_status=$?
5954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5955 (exit $ac_status); }; } &&
5956 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5957 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5958 (eval $ac_try) 2>&5
5959 ac_status=$?
c0d27fcc 5960 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5961 (exit $ac_status); }; }; then
98418dba 5962 emacs_cv_struct_utimbuf=yes
1113b624 5963else
503d2be0 5964 echo "$as_me: failed program was:" >&5
19650fd6
AS
5965sed 's/^/| /' conftest.$ac_ext >&5
5966
98418dba 5967emacs_cv_struct_utimbuf=no
1113b624 5968fi
35996d22 5969rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1113b624 5970fi
c0d27fcc 5971echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
5972echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
5973if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 5974
c0d27fcc 5975cat >>confdefs.h <<\_ACEOF
98418dba 5976#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 5977_ACEOF
1113b624
PE
5978
5979fi
ba4481b5 5980
c0d27fcc 5981echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
5982echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5983if test "${ac_cv_type_signal+set}" = set; then
503d2be0 5984 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5985else
98418dba 5986 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5987/* confdefs.h. */
5988_ACEOF
5989cat confdefs.h >>conftest.$ac_ext
5990cat >>conftest.$ac_ext <<_ACEOF
5991/* end confdefs.h. */
7397acc4 5992#include <sys/types.h>
98418dba
CW
5993#include <signal.h>
5994#ifdef signal
5995# undef signal
5996#endif
5997#ifdef __cplusplus
5998extern "C" void (*signal (int, void (*)(int)))(int);
5999#else
6000void (*signal ()) ();
6001#endif
6002
503d2be0
AS
6003int
6004main ()
6005{
98418dba 6006int i;
503d2be0
AS
6007 ;
6008 return 0;
6009}
6010_ACEOF
98418dba 6011rm -f conftest.$ac_objext
c0d27fcc 6012if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6013 (eval $ac_compile) 2>conftest.er1
503d2be0 6014 ac_status=$?
35996d22
AS
6015 grep -v '^ *+' conftest.er1 >conftest.err
6016 rm -f conftest.er1
6017 cat conftest.err >&5
c0d27fcc 6018 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6019 (exit $ac_status); } &&
35996d22
AS
6020 { ac_try='test -z "$ac_c_werror_flag"
6021 || test ! -s conftest.err'
6022 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6023 (eval $ac_try) 2>&5
6024 ac_status=$?
6025 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6026 (exit $ac_status); }; } &&
6027 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6029 (eval $ac_try) 2>&5
6030 ac_status=$?
c0d27fcc 6031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6032 (exit $ac_status); }; }; then
98418dba 6033 ac_cv_type_signal=void
503d2be0
AS
6034else
6035 echo "$as_me: failed program was:" >&5
19650fd6
AS
6036sed 's/^/| /' conftest.$ac_ext >&5
6037
98418dba 6038ac_cv_type_signal=int
503d2be0 6039fi
35996d22 6040rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6041fi
c0d27fcc 6042echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 6043echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 6044
c0d27fcc 6045cat >>confdefs.h <<_ACEOF
98418dba 6046#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
6047_ACEOF
6048
503d2be0 6049
c0d27fcc
MR
6050
6051echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
6052echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
6053if test "${emacs_cv_speed_t+set}" = set; then
6054 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6055else
98418dba 6056 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6057/* confdefs.h. */
6058_ACEOF
6059cat confdefs.h >>conftest.$ac_ext
6060cat >>conftest.$ac_ext <<_ACEOF
6061/* end confdefs.h. */
98418dba 6062#include <termios.h>
98418dba
CW
6063int
6064main ()
6065{
6066speed_t x = 1;
6067 ;
6068 return 0;
6069}
6070_ACEOF
6071rm -f conftest.$ac_objext
c0d27fcc 6072if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6073 (eval $ac_compile) 2>conftest.er1
98418dba 6074 ac_status=$?
35996d22
AS
6075 grep -v '^ *+' conftest.er1 >conftest.err
6076 rm -f conftest.er1
6077 cat conftest.err >&5
c0d27fcc 6078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6079 (exit $ac_status); } &&
35996d22
AS
6080 { ac_try='test -z "$ac_c_werror_flag"
6081 || test ! -s conftest.err'
6082 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6083 (eval $ac_try) 2>&5
6084 ac_status=$?
6085 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6086 (exit $ac_status); }; } &&
6087 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6088 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6089 (eval $ac_try) 2>&5
6090 ac_status=$?
c0d27fcc 6091 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6092 (exit $ac_status); }; }; then
6093 emacs_cv_speed_t=yes
6094else
6095 echo "$as_me: failed program was:" >&5
19650fd6
AS
6096sed 's/^/| /' conftest.$ac_ext >&5
6097
98418dba
CW
6098emacs_cv_speed_t=no
6099fi
35996d22 6100rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 6101fi
c0d27fcc 6102echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
6103echo "${ECHO_T}$emacs_cv_speed_t" >&6
6104if test $emacs_cv_speed_t = yes; then
b936fae4 6105
c0d27fcc 6106cat >>confdefs.h <<\_ACEOF
98418dba 6107#define HAVE_SPEED_T 1
c0d27fcc 6108_ACEOF
98418dba 6109
7397acc4
DL
6110fi
6111
c0d27fcc 6112echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
6113echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
6114if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 6115 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6116else
503d2be0 6117 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6118/* confdefs.h. */
6119_ACEOF
6120cat confdefs.h >>conftest.$ac_ext
6121cat >>conftest.$ac_ext <<_ACEOF
6122/* end confdefs.h. */
98418dba
CW
6123#ifdef TIME_WITH_SYS_TIME
6124#include <sys/time.h>
6125#include <time.h>
6126#else
6127#ifdef HAVE_SYS_TIME_H
6128#include <sys/time.h>
6129#else
6130#include <time.h>
6131#endif
6132#endif
503d2be0
AS
6133int
6134main ()
6135{
98418dba 6136static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
6137 ;
6138 return 0;
6139}
6140_ACEOF
6141rm -f conftest.$ac_objext
c0d27fcc 6142if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6143 (eval $ac_compile) 2>conftest.er1
503d2be0 6144 ac_status=$?
35996d22
AS
6145 grep -v '^ *+' conftest.er1 >conftest.err
6146 rm -f conftest.er1
6147 cat conftest.err >&5
c0d27fcc 6148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6149 (exit $ac_status); } &&
35996d22
AS
6150 { ac_try='test -z "$ac_c_werror_flag"
6151 || test ! -s conftest.err'
6152 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6153 (eval $ac_try) 2>&5
6154 ac_status=$?
6155 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6156 (exit $ac_status); }; } &&
6157 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6158 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6159 (eval $ac_try) 2>&5
6160 ac_status=$?
c0d27fcc 6161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6162 (exit $ac_status); }; }; then
98418dba 6163 emacs_cv_struct_timeval=yes
7397acc4 6164else
503d2be0 6165 echo "$as_me: failed program was:" >&5
19650fd6
AS
6166sed 's/^/| /' conftest.$ac_ext >&5
6167
98418dba 6168emacs_cv_struct_timeval=no
7397acc4 6169fi
35996d22 6170rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6171fi
c0d27fcc 6172echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
6173echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
6174HAVE_TIMEVAL=$emacs_cv_struct_timeval
6175if test $emacs_cv_struct_timeval = yes; then
b936fae4 6176
c0d27fcc 6177cat >>confdefs.h <<\_ACEOF
98418dba 6178#define HAVE_TIMEVAL 1
c0d27fcc 6179_ACEOF
7397acc4
DL
6180
6181fi
6182
c0d27fcc 6183echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
6184echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
6185if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 6186 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6187else
503d2be0 6188 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6189/* confdefs.h. */
6190_ACEOF
6191cat confdefs.h >>conftest.$ac_ext
6192cat >>conftest.$ac_ext <<_ACEOF
6193/* end confdefs.h. */
98418dba 6194#include <math.h>
503d2be0
AS
6195int
6196main ()
6197{
98418dba 6198static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
6199 ;
6200 return 0;
ba4481b5 6201}
503d2be0
AS
6202_ACEOF
6203rm -f conftest.$ac_objext
c0d27fcc 6204if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6205 (eval $ac_compile) 2>conftest.er1
503d2be0 6206 ac_status=$?
35996d22
AS
6207 grep -v '^ *+' conftest.er1 >conftest.err
6208 rm -f conftest.er1
6209 cat conftest.err >&5
c0d27fcc 6210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6211 (exit $ac_status); } &&
35996d22
AS
6212 { ac_try='test -z "$ac_c_werror_flag"
6213 || test ! -s conftest.err'
6214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6215 (eval $ac_try) 2>&5
6216 ac_status=$?
6217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6218 (exit $ac_status); }; } &&
6219 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6221 (eval $ac_try) 2>&5
6222 ac_status=$?
c0d27fcc 6223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6224 (exit $ac_status); }; }; then
98418dba 6225 emacs_cv_struct_exception=yes
ba4481b5 6226else
503d2be0 6227 echo "$as_me: failed program was:" >&5
19650fd6
AS
6228sed 's/^/| /' conftest.$ac_ext >&5
6229
98418dba 6230emacs_cv_struct_exception=no
ba4481b5 6231fi
35996d22 6232rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6233fi
c0d27fcc 6234echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
6235echo "${ECHO_T}$emacs_cv_struct_exception" >&6
6236HAVE_EXCEPTION=$emacs_cv_struct_exception
6237if test $emacs_cv_struct_exception != yes; then
b936fae4 6238
c0d27fcc 6239cat >>confdefs.h <<\_ACEOF
98418dba 6240#define NO_MATHERR 1
c0d27fcc 6241_ACEOF
ba4481b5
DL
6242
6243fi
6244
7862d3a8
AS
6245
6246for ac_header in sys/socket.h
6247do
6248as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6249if eval "test \"\${$as_ac_Header+set}\" = set"; then
6250 echo "$as_me:$LINENO: checking for $ac_header" >&5
6251echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6252if eval "test \"\${$as_ac_Header+set}\" = set"; then
6253 echo $ECHO_N "(cached) $ECHO_C" >&6
6254fi
6255echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6256echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6257else
6258 # Is the header compilable?
6259echo "$as_me:$LINENO: checking $ac_header usability" >&5
6260echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6261cat >conftest.$ac_ext <<_ACEOF
6262/* confdefs.h. */
6263_ACEOF
6264cat confdefs.h >>conftest.$ac_ext
6265cat >>conftest.$ac_ext <<_ACEOF
6266/* end confdefs.h. */
6267$ac_includes_default
6268#include <$ac_header>
6269_ACEOF
6270rm -f conftest.$ac_objext
6271if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6272 (eval $ac_compile) 2>conftest.er1
6273 ac_status=$?
6274 grep -v '^ *+' conftest.er1 >conftest.err
6275 rm -f conftest.er1
6276 cat conftest.err >&5
6277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6278 (exit $ac_status); } &&
6279 { ac_try='test -z "$ac_c_werror_flag"
6280 || test ! -s conftest.err'
6281 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6282 (eval $ac_try) 2>&5
6283 ac_status=$?
6284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6285 (exit $ac_status); }; } &&
6286 { ac_try='test -s conftest.$ac_objext'
6287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6288 (eval $ac_try) 2>&5
6289 ac_status=$?
6290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6291 (exit $ac_status); }; }; then
6292 ac_header_compiler=yes
6293else
6294 echo "$as_me: failed program was:" >&5
6295sed 's/^/| /' conftest.$ac_ext >&5
6296
6297ac_header_compiler=no
6298fi
6299rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6300echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6301echo "${ECHO_T}$ac_header_compiler" >&6
6302
6303# Is the header present?
6304echo "$as_me:$LINENO: checking $ac_header presence" >&5
6305echo $ECHO_N "checking $ac_header presence... $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#include <$ac_header>
6313_ACEOF
6314if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6315 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6316 ac_status=$?
6317 grep -v '^ *+' conftest.er1 >conftest.err
6318 rm -f conftest.er1
6319 cat conftest.err >&5
6320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6321 (exit $ac_status); } >/dev/null; then
6322 if test -s conftest.err; then
6323 ac_cpp_err=$ac_c_preproc_warn_flag
6324 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6325 else
6326 ac_cpp_err=
6327 fi
6328else
6329 ac_cpp_err=yes
6330fi
6331if test -z "$ac_cpp_err"; then
6332 ac_header_preproc=yes
6333else
6334 echo "$as_me: failed program was:" >&5
6335sed 's/^/| /' conftest.$ac_ext >&5
6336
6337 ac_header_preproc=no
6338fi
6339rm -f conftest.err conftest.$ac_ext
6340echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6341echo "${ECHO_T}$ac_header_preproc" >&6
6342
6343# So? What about this header?
6344case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6345 yes:no: )
6346 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6347echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6348 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6349echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6350 ac_header_preproc=yes
6351 ;;
6352 no:yes:* )
6353 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6354echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6355 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6356echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6357 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6358echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6359 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6360echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6361 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6362echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6363 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6364echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6365 (
6366 cat <<\_ASBOX
6367## ------------------------------------------ ##
6368## Report this to the AC_PACKAGE_NAME lists. ##
6369## ------------------------------------------ ##
6370_ASBOX
6371 ) |
6372 sed "s/^/$as_me: WARNING: /" >&2
6373 ;;
6374esac
6375echo "$as_me:$LINENO: checking for $ac_header" >&5
6376echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6377if eval "test \"\${$as_ac_Header+set}\" = set"; then
6378 echo $ECHO_N "(cached) $ECHO_C" >&6
6379else
6380 eval "$as_ac_Header=\$ac_header_preproc"
6381fi
6382echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6383echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6384
6385fi
6386if test `eval echo '${'$as_ac_Header'}'` = yes; then
6387 cat >>confdefs.h <<_ACEOF
6388#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6389_ACEOF
6390
6391fi
6392
6393done
6394
6395
6396for ac_header in net/if.h
6397do
6398as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6399echo "$as_me:$LINENO: checking for $ac_header" >&5
6400echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6401if eval "test \"\${$as_ac_Header+set}\" = set"; then
6402 echo $ECHO_N "(cached) $ECHO_C" >&6
6403else
6404 cat >conftest.$ac_ext <<_ACEOF
6405/* confdefs.h. */
6406_ACEOF
6407cat confdefs.h >>conftest.$ac_ext
6408cat >>conftest.$ac_ext <<_ACEOF
6409/* end confdefs.h. */
6410$ac_includes_default
6411#if HAVE_SYS_SOCKET_H
6412#include <sys/socket.h>
6413#endif
6414
6415#include <$ac_header>
6416_ACEOF
6417rm -f conftest.$ac_objext
6418if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6419 (eval $ac_compile) 2>conftest.er1
6420 ac_status=$?
6421 grep -v '^ *+' conftest.er1 >conftest.err
6422 rm -f conftest.er1
6423 cat conftest.err >&5
6424 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6425 (exit $ac_status); } &&
6426 { ac_try='test -z "$ac_c_werror_flag"
6427 || test ! -s conftest.err'
6428 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6429 (eval $ac_try) 2>&5
6430 ac_status=$?
6431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6432 (exit $ac_status); }; } &&
6433 { ac_try='test -s conftest.$ac_objext'
6434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6435 (eval $ac_try) 2>&5
6436 ac_status=$?
6437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6438 (exit $ac_status); }; }; then
6439 eval "$as_ac_Header=yes"
6440else
6441 echo "$as_me: failed program was:" >&5
6442sed 's/^/| /' conftest.$ac_ext >&5
6443
6444eval "$as_ac_Header=no"
6445fi
6446rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6447fi
6448echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6449echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6450if test `eval echo '${'$as_ac_Header'}'` = yes; then
6451 cat >>confdefs.h <<_ACEOF
6452#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6453_ACEOF
6454
6455fi
6456
6457done
6458
6459
c0d27fcc 6460echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
6461echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
6462if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 6463 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6464else
503d2be0 6465 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6466/* confdefs.h. */
6467_ACEOF
6468cat confdefs.h >>conftest.$ac_ext
6469cat >>conftest.$ac_ext <<_ACEOF
6470/* end confdefs.h. */
98418dba
CW
6471#include <sys/types.h>
6472#include <time.h>
7397acc4 6473
503d2be0
AS
6474int
6475main ()
6476{
98418dba 6477struct tm *tp; tp->tm_sec;
503d2be0
AS
6478 ;
6479 return 0;
6480}
6481_ACEOF
6482rm -f conftest.$ac_objext
c0d27fcc 6483if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6484 (eval $ac_compile) 2>conftest.er1
503d2be0 6485 ac_status=$?
35996d22
AS
6486 grep -v '^ *+' conftest.er1 >conftest.err
6487 rm -f conftest.er1
6488 cat conftest.err >&5
c0d27fcc 6489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6490 (exit $ac_status); } &&
35996d22
AS
6491 { ac_try='test -z "$ac_c_werror_flag"
6492 || test ! -s conftest.err'
c0d27fcc 6493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6494 (eval $ac_try) 2>&5
6495 ac_status=$?
c0d27fcc 6496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
6497 (exit $ac_status); }; } &&
6498 { ac_try='test -s conftest.$ac_objext'
6499 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6500 (eval $ac_try) 2>&5
6501 ac_status=$?
6502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6503 (exit $ac_status); }; }; then
6504 ac_cv_struct_tm=time.h
6505else
503d2be0 6506 echo "$as_me: failed program was:" >&5
19650fd6
AS
6507sed 's/^/| /' conftest.$ac_ext >&5
6508
98418dba 6509ac_cv_struct_tm=sys/time.h
7397acc4 6510fi
35996d22 6511rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6512fi
c0d27fcc 6513echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
6514echo "${ECHO_T}$ac_cv_struct_tm" >&6
6515if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 6516
c0d27fcc 6517cat >>confdefs.h <<\_ACEOF
98418dba 6518#define TM_IN_SYS_TIME 1
c0d27fcc 6519_ACEOF
7397acc4
DL
6520
6521fi
ba4481b5 6522
c0d27fcc 6523echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
6524echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
6525if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 6526 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6527else
98418dba 6528 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6529/* confdefs.h. */
6530_ACEOF
6531cat confdefs.h >>conftest.$ac_ext
6532cat >>conftest.$ac_ext <<_ACEOF
6533/* end confdefs.h. */
98418dba
CW
6534#include <sys/types.h>
6535#include <$ac_cv_struct_tm>
ba4481b5 6536
c0d27fcc 6537
98418dba
CW
6538int
6539main ()
6540{
6541static struct tm ac_aggr;
6542if (ac_aggr.tm_zone)
6543return 0;
6544 ;
6545 return 0;
6546}
6547_ACEOF
6548rm -f conftest.$ac_objext
c0d27fcc 6549if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6550 (eval $ac_compile) 2>conftest.er1
98418dba 6551 ac_status=$?
35996d22
AS
6552 grep -v '^ *+' conftest.er1 >conftest.err
6553 rm -f conftest.er1
6554 cat conftest.err >&5
c0d27fcc 6555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6556 (exit $ac_status); } &&
35996d22
AS
6557 { ac_try='test -z "$ac_c_werror_flag"
6558 || test ! -s conftest.err'
6559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6560 (eval $ac_try) 2>&5
6561 ac_status=$?
6562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6563 (exit $ac_status); }; } &&
6564 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6565 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6566 (eval $ac_try) 2>&5
6567 ac_status=$?
c0d27fcc 6568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6569 (exit $ac_status); }; }; then
6570 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6571else
98418dba 6572 echo "$as_me: failed program was:" >&5
19650fd6
AS
6573sed 's/^/| /' conftest.$ac_ext >&5
6574
6bae0ccf 6575cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6576/* confdefs.h. */
6577_ACEOF
6578cat confdefs.h >>conftest.$ac_ext
6579cat >>conftest.$ac_ext <<_ACEOF
6580/* end confdefs.h. */
6bae0ccf
DL
6581#include <sys/types.h>
6582#include <$ac_cv_struct_tm>
6583
6584
6585int
6586main ()
6587{
6588static struct tm ac_aggr;
6589if (sizeof ac_aggr.tm_zone)
6590return 0;
6591 ;
6592 return 0;
6593}
6594_ACEOF
6595rm -f conftest.$ac_objext
6596if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6597 (eval $ac_compile) 2>conftest.er1
6bae0ccf 6598 ac_status=$?
35996d22
AS
6599 grep -v '^ *+' conftest.er1 >conftest.err
6600 rm -f conftest.er1
6601 cat conftest.err >&5
6bae0ccf
DL
6602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6603 (exit $ac_status); } &&
35996d22
AS
6604 { ac_try='test -z "$ac_c_werror_flag"
6605 || test ! -s conftest.err'
6606 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6607 (eval $ac_try) 2>&5
6608 ac_status=$?
6609 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6610 (exit $ac_status); }; } &&
6611 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
6612 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6613 (eval $ac_try) 2>&5
6614 ac_status=$?
6615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6616 (exit $ac_status); }; }; then
6617 ac_cv_member_struct_tm_tm_zone=yes
6618else
6619 echo "$as_me: failed program was:" >&5
19650fd6
AS
6620sed 's/^/| /' conftest.$ac_ext >&5
6621
98418dba 6622ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6623fi
35996d22 6624rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6625fi
35996d22 6626rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6627fi
c0d27fcc 6628echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6629echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6630if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6631
c0d27fcc 6632cat >>confdefs.h <<_ACEOF
98418dba 6633#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6634_ACEOF
6635
ba4481b5 6636
98418dba 6637fi
ba4481b5 6638
98418dba 6639if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6640
c0d27fcc 6641cat >>confdefs.h <<\_ACEOF
98418dba 6642#define HAVE_TM_ZONE 1
c0d27fcc 6643_ACEOF
ba4481b5 6644
ba4481b5 6645else
c0d27fcc 6646 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6647echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6648if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6649 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6650else
98418dba 6651 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6652/* confdefs.h. */
6653_ACEOF
6654cat confdefs.h >>conftest.$ac_ext
6655cat >>conftest.$ac_ext <<_ACEOF
6656/* end confdefs.h. */
98418dba
CW
6657#include <time.h>
6658#ifndef tzname /* For SGI. */
6659extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6660#endif
6661
98418dba
CW
6662int
6663main ()
6664{
6665atoi(*tzname);
6666 ;
6667 return 0;
6668}
6669_ACEOF
6670rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6671if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 6672 (eval $ac_link) 2>conftest.er1
98418dba 6673 ac_status=$?
35996d22
AS
6674 grep -v '^ *+' conftest.er1 >conftest.err
6675 rm -f conftest.er1
6676 cat conftest.err >&5
c0d27fcc 6677 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6678 (exit $ac_status); } &&
35996d22
AS
6679 { ac_try='test -z "$ac_c_werror_flag"
6680 || test ! -s conftest.err'
6681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6682 (eval $ac_try) 2>&5
6683 ac_status=$?
6684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6685 (exit $ac_status); }; } &&
6686 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6688 (eval $ac_try) 2>&5
6689 ac_status=$?
c0d27fcc 6690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6691 (exit $ac_status); }; }; then
6692 ac_cv_var_tzname=yes
6693else
6694 echo "$as_me: failed program was:" >&5
19650fd6
AS
6695sed 's/^/| /' conftest.$ac_ext >&5
6696
98418dba 6697ac_cv_var_tzname=no
ba4481b5 6698fi
35996d22
AS
6699rm -f conftest.err conftest.$ac_objext \
6700 conftest$ac_exeext conftest.$ac_ext
98418dba 6701fi
c0d27fcc 6702echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6703echo "${ECHO_T}$ac_cv_var_tzname" >&6
6704 if test $ac_cv_var_tzname = yes; then
ba4481b5 6705
c0d27fcc 6706cat >>confdefs.h <<\_ACEOF
98418dba 6707#define HAVE_TZNAME 1
c0d27fcc 6708_ACEOF
503d2be0 6709
98418dba
CW
6710 fi
6711fi
503d2be0 6712
c0d27fcc 6713echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6714echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6715if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6716 echo $ECHO_N "(cached) $ECHO_C" >&6
6717else
6718 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6719/* confdefs.h. */
6720_ACEOF
6721cat confdefs.h >>conftest.$ac_ext
6722cat >>conftest.$ac_ext <<_ACEOF
6723/* end confdefs.h. */
98418dba 6724#include <time.h>
b936fae4 6725
98418dba
CW
6726int
6727main ()
6728{
b936fae4
AS
6729static struct tm ac_aggr;
6730if (ac_aggr.tm_gmtoff)
6731return 0;
98418dba
CW
6732 ;
6733 return 0;
6734}
6735_ACEOF
b936fae4 6736rm -f conftest.$ac_objext
c0d27fcc 6737if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6738 (eval $ac_compile) 2>conftest.er1
98418dba 6739 ac_status=$?
35996d22
AS
6740 grep -v '^ *+' conftest.er1 >conftest.err
6741 rm -f conftest.er1
6742 cat conftest.err >&5
c0d27fcc 6743 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6744 (exit $ac_status); } &&
35996d22
AS
6745 { ac_try='test -z "$ac_c_werror_flag"
6746 || test ! -s conftest.err'
6747 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6748 (eval $ac_try) 2>&5
6749 ac_status=$?
6750 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6751 (exit $ac_status); }; } &&
6752 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6753 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6754 (eval $ac_try) 2>&5
6755 ac_status=$?
c0d27fcc 6756 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6757 (exit $ac_status); }; }; then
b936fae4 6758 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6759else
6760 echo "$as_me: failed program was:" >&5
19650fd6
AS
6761sed 's/^/| /' conftest.$ac_ext >&5
6762
8799b3e4 6763cat >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. */
6bae0ccf
DL
6769#include <time.h>
6770
8799b3e4
CW
6771int
6772main ()
6773{
6bae0ccf
DL
6774static struct tm ac_aggr;
6775if (sizeof ac_aggr.tm_gmtoff)
6776return 0;
8799b3e4
CW
6777 ;
6778 return 0;
6779}
6780_ACEOF
6bae0ccf 6781rm -f conftest.$ac_objext
c0d27fcc 6782if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6783 (eval $ac_compile) 2>conftest.er1
8799b3e4 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
8799b3e4 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
8799b3e4
CW
6799 (eval $ac_try) 2>&5
6800 ac_status=$?
c0d27fcc 6801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6802 (exit $ac_status); }; }; then
6bae0ccf 6803 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6804else
6805 echo "$as_me: failed program was:" >&5
19650fd6
AS
6806sed 's/^/| /' conftest.$ac_ext >&5
6807
6bae0ccf 6808ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6809fi
35996d22 6810rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6811fi
35996d22 6812rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8799b3e4 6813fi
6bae0ccf
DL
6814echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6815echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6816if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6817
6818cat >>confdefs.h <<\_ACEOF
6819#define HAVE_TM_GMTOFF 1
6820_ACEOF
6821
6822fi
6823
96f3a036
DL
6824echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
6825echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6
6826if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
6827 echo $ECHO_N "(cached) $ECHO_C" >&6
6828else
6829 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6830/* confdefs.h. */
6831_ACEOF
6832cat confdefs.h >>conftest.$ac_ext
6833cat >>conftest.$ac_ext <<_ACEOF
6834/* end confdefs.h. */
7862d3a8
AS
6835$ac_includes_default
6836#if HAVE_SYS_SOCKET_H
6837#include <sys/socket.h>
6838#endif
6839#if HAVE_NET_IF_H
96f3a036 6840#include <net/if.h>
7862d3a8 6841#endif
96f3a036
DL
6842
6843int
6844main ()
6845{
6846static struct ifreq ac_aggr;
6847if (ac_aggr.ifr_flags)
6848return 0;
6849 ;
6850 return 0;
6851}
6852_ACEOF
6853rm -f conftest.$ac_objext
6854if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6855 (eval $ac_compile) 2>conftest.er1
96f3a036 6856 ac_status=$?
35996d22
AS
6857 grep -v '^ *+' conftest.er1 >conftest.err
6858 rm -f conftest.er1
6859 cat conftest.err >&5
96f3a036
DL
6860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6861 (exit $ac_status); } &&
35996d22
AS
6862 { ac_try='test -z "$ac_c_werror_flag"
6863 || test ! -s conftest.err'
6864 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6865 (eval $ac_try) 2>&5
6866 ac_status=$?
6867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6868 (exit $ac_status); }; } &&
6869 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6870 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6871 (eval $ac_try) 2>&5
6872 ac_status=$?
6873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6874 (exit $ac_status); }; }; then
6875 ac_cv_member_struct_ifreq_ifr_flags=yes
6876else
6877 echo "$as_me: failed program was:" >&5
6878sed 's/^/| /' conftest.$ac_ext >&5
6879
6880cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6881/* confdefs.h. */
6882_ACEOF
6883cat confdefs.h >>conftest.$ac_ext
6884cat >>conftest.$ac_ext <<_ACEOF
6885/* end confdefs.h. */
7862d3a8
AS
6886$ac_includes_default
6887#if HAVE_SYS_SOCKET_H
6888#include <sys/socket.h>
6889#endif
6890#if HAVE_NET_IF_H
96f3a036 6891#include <net/if.h>
7862d3a8 6892#endif
96f3a036
DL
6893
6894int
6895main ()
6896{
6897static struct ifreq ac_aggr;
6898if (sizeof ac_aggr.ifr_flags)
6899return 0;
6900 ;
6901 return 0;
6902}
6903_ACEOF
6904rm -f conftest.$ac_objext
6905if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6906 (eval $ac_compile) 2>conftest.er1
96f3a036 6907 ac_status=$?
35996d22
AS
6908 grep -v '^ *+' conftest.er1 >conftest.err
6909 rm -f conftest.er1
6910 cat conftest.err >&5
96f3a036
DL
6911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6912 (exit $ac_status); } &&
35996d22
AS
6913 { ac_try='test -z "$ac_c_werror_flag"
6914 || test ! -s conftest.err'
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); }; } &&
6920 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6921 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6922 (eval $ac_try) 2>&5
6923 ac_status=$?
6924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6925 (exit $ac_status); }; }; then
6926 ac_cv_member_struct_ifreq_ifr_flags=yes
6927else
6928 echo "$as_me: failed program was:" >&5
6929sed 's/^/| /' conftest.$ac_ext >&5
6930
6931ac_cv_member_struct_ifreq_ifr_flags=no
6932fi
35996d22 6933rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 6934fi
35996d22 6935rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6936fi
6937echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
6938echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6
6939if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
6940
6941cat >>confdefs.h <<_ACEOF
6942#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6943_ACEOF
6944
6945
6946fi
6947echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
6948echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
6949if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
6950 echo $ECHO_N "(cached) $ECHO_C" >&6
6951else
6952 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6953/* confdefs.h. */
6954_ACEOF
6955cat confdefs.h >>conftest.$ac_ext
6956cat >>conftest.$ac_ext <<_ACEOF
6957/* end confdefs.h. */
7862d3a8
AS
6958$ac_includes_default
6959#if HAVE_SYS_SOCKET_H
6960#include <sys/socket.h>
6961#endif
6962#if HAVE_NET_IF_H
96f3a036 6963#include <net/if.h>
7862d3a8 6964#endif
96f3a036
DL
6965
6966int
6967main ()
6968{
6969static struct ifreq ac_aggr;
6970if (ac_aggr.ifr_hwaddr)
6971return 0;
6972 ;
6973 return 0;
6974}
6975_ACEOF
6976rm -f conftest.$ac_objext
6977if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6978 (eval $ac_compile) 2>conftest.er1
96f3a036 6979 ac_status=$?
35996d22
AS
6980 grep -v '^ *+' conftest.er1 >conftest.err
6981 rm -f conftest.er1
6982 cat conftest.err >&5
96f3a036
DL
6983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6984 (exit $ac_status); } &&
35996d22
AS
6985 { ac_try='test -z "$ac_c_werror_flag"
6986 || test ! -s conftest.err'
6987 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6988 (eval $ac_try) 2>&5
6989 ac_status=$?
6990 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6991 (exit $ac_status); }; } &&
6992 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6993 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6994 (eval $ac_try) 2>&5
6995 ac_status=$?
6996 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6997 (exit $ac_status); }; }; then
6998 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
6999else
7000 echo "$as_me: failed program was:" >&5
7001sed 's/^/| /' conftest.$ac_ext >&5
7002
7003cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7004/* confdefs.h. */
7005_ACEOF
7006cat confdefs.h >>conftest.$ac_ext
7007cat >>conftest.$ac_ext <<_ACEOF
7008/* end confdefs.h. */
7862d3a8
AS
7009$ac_includes_default
7010#if HAVE_SYS_SOCKET_H
7011#include <sys/socket.h>
7012#endif
7013#if HAVE_NET_IF_H
96f3a036 7014#include <net/if.h>
7862d3a8 7015#endif
96f3a036
DL
7016
7017int
7018main ()
7019{
7020static struct ifreq ac_aggr;
7021if (sizeof ac_aggr.ifr_hwaddr)
7022return 0;
7023 ;
7024 return 0;
7025}
7026_ACEOF
7027rm -f conftest.$ac_objext
7028if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7029 (eval $ac_compile) 2>conftest.er1
96f3a036 7030 ac_status=$?
35996d22
AS
7031 grep -v '^ *+' conftest.er1 >conftest.err
7032 rm -f conftest.er1
7033 cat conftest.err >&5
96f3a036
DL
7034 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7035 (exit $ac_status); } &&
35996d22
AS
7036 { ac_try='test -z "$ac_c_werror_flag"
7037 || test ! -s conftest.err'
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); }; } &&
7043 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7044 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7045 (eval $ac_try) 2>&5
7046 ac_status=$?
7047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7048 (exit $ac_status); }; }; then
7049 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7050else
7051 echo "$as_me: failed program was:" >&5
7052sed 's/^/| /' conftest.$ac_ext >&5
7053
7054ac_cv_member_struct_ifreq_ifr_hwaddr=no
7055fi
35996d22 7056rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7057fi
35996d22 7058rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7059fi
7060echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
7061echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
7062if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
7063
7064cat >>confdefs.h <<_ACEOF
7065#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
7066_ACEOF
7067
7068
7069fi
7070echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
7071echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6
7072if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
7073 echo $ECHO_N "(cached) $ECHO_C" >&6
7074else
7075 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7076/* confdefs.h. */
7077_ACEOF
7078cat confdefs.h >>conftest.$ac_ext
7079cat >>conftest.$ac_ext <<_ACEOF
7080/* end confdefs.h. */
7862d3a8
AS
7081$ac_includes_default
7082#if HAVE_SYS_SOCKET_H
7083#include <sys/socket.h>
7084#endif
7085#if HAVE_NET_IF_H
96f3a036 7086#include <net/if.h>
7862d3a8 7087#endif
96f3a036
DL
7088
7089int
7090main ()
7091{
7092static struct ifreq ac_aggr;
7093if (ac_aggr.ifr_netmask)
7094return 0;
7095 ;
7096 return 0;
7097}
7098_ACEOF
7099rm -f conftest.$ac_objext
7100if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7101 (eval $ac_compile) 2>conftest.er1
96f3a036 7102 ac_status=$?
35996d22
AS
7103 grep -v '^ *+' conftest.er1 >conftest.err
7104 rm -f conftest.er1
7105 cat conftest.err >&5
96f3a036
DL
7106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7107 (exit $ac_status); } &&
35996d22
AS
7108 { ac_try='test -z "$ac_c_werror_flag"
7109 || test ! -s conftest.err'
7110 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7111 (eval $ac_try) 2>&5
7112 ac_status=$?
7113 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7114 (exit $ac_status); }; } &&
7115 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7116 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7117 (eval $ac_try) 2>&5
7118 ac_status=$?
7119 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7120 (exit $ac_status); }; }; then
7121 ac_cv_member_struct_ifreq_ifr_netmask=yes
7122else
7123 echo "$as_me: failed program was:" >&5
7124sed 's/^/| /' conftest.$ac_ext >&5
7125
7126cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7127/* confdefs.h. */
7128_ACEOF
7129cat confdefs.h >>conftest.$ac_ext
7130cat >>conftest.$ac_ext <<_ACEOF
7131/* end confdefs.h. */
7862d3a8
AS
7132$ac_includes_default
7133#if HAVE_SYS_SOCKET_H
7134#include <sys/socket.h>
7135#endif
7136#if HAVE_NET_IF_H
96f3a036 7137#include <net/if.h>
7862d3a8 7138#endif
96f3a036
DL
7139
7140int
7141main ()
7142{
7143static struct ifreq ac_aggr;
7144if (sizeof ac_aggr.ifr_netmask)
7145return 0;
7146 ;
7147 return 0;
7148}
7149_ACEOF
7150rm -f conftest.$ac_objext
7151if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7152 (eval $ac_compile) 2>conftest.er1
96f3a036 7153 ac_status=$?
35996d22
AS
7154 grep -v '^ *+' conftest.er1 >conftest.err
7155 rm -f conftest.er1
7156 cat conftest.err >&5
96f3a036
DL
7157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7158 (exit $ac_status); } &&
35996d22
AS
7159 { ac_try='test -z "$ac_c_werror_flag"
7160 || test ! -s conftest.err'
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); }; } &&
7166 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7167 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7168 (eval $ac_try) 2>&5
7169 ac_status=$?
7170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7171 (exit $ac_status); }; }; then
7172 ac_cv_member_struct_ifreq_ifr_netmask=yes
7173else
7174 echo "$as_me: failed program was:" >&5
7175sed 's/^/| /' conftest.$ac_ext >&5
7176
7177ac_cv_member_struct_ifreq_ifr_netmask=no
7178fi
35996d22 7179rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7180fi
35996d22 7181rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7182fi
7183echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
7184echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6
7185if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
7186
7187cat >>confdefs.h <<_ACEOF
7188#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
7189_ACEOF
7190
7191
7192fi
7193echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
7194echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6
7195if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
7196 echo $ECHO_N "(cached) $ECHO_C" >&6
7197else
7198 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7199/* confdefs.h. */
7200_ACEOF
7201cat confdefs.h >>conftest.$ac_ext
7202cat >>conftest.$ac_ext <<_ACEOF
7203/* end confdefs.h. */
7862d3a8
AS
7204$ac_includes_default
7205#if HAVE_SYS_SOCKET_H
7206#include <sys/socket.h>
7207#endif
7208#if HAVE_NET_IF_H
96f3a036 7209#include <net/if.h>
7862d3a8 7210#endif
96f3a036
DL
7211
7212int
7213main ()
7214{
7215static struct ifreq ac_aggr;
7216if (ac_aggr.ifr_broadaddr)
7217return 0;
7218 ;
7219 return 0;
7220}
7221_ACEOF
7222rm -f conftest.$ac_objext
7223if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7224 (eval $ac_compile) 2>conftest.er1
96f3a036 7225 ac_status=$?
35996d22
AS
7226 grep -v '^ *+' conftest.er1 >conftest.err
7227 rm -f conftest.er1
7228 cat conftest.err >&5
96f3a036
DL
7229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7230 (exit $ac_status); } &&
35996d22
AS
7231 { ac_try='test -z "$ac_c_werror_flag"
7232 || test ! -s conftest.err'
7233 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7234 (eval $ac_try) 2>&5
7235 ac_status=$?
7236 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7237 (exit $ac_status); }; } &&
7238 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7239 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7240 (eval $ac_try) 2>&5
7241 ac_status=$?
7242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7243 (exit $ac_status); }; }; then
7244 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7245else
7246 echo "$as_me: failed program was:" >&5
7247sed 's/^/| /' conftest.$ac_ext >&5
7248
7249cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7250/* confdefs.h. */
7251_ACEOF
7252cat confdefs.h >>conftest.$ac_ext
7253cat >>conftest.$ac_ext <<_ACEOF
7254/* end confdefs.h. */
7862d3a8
AS
7255$ac_includes_default
7256#if HAVE_SYS_SOCKET_H
7257#include <sys/socket.h>
7258#endif
7259#if HAVE_NET_IF_H
96f3a036 7260#include <net/if.h>
7862d3a8 7261#endif
96f3a036
DL
7262
7263int
7264main ()
7265{
7266static struct ifreq ac_aggr;
7267if (sizeof ac_aggr.ifr_broadaddr)
7268return 0;
7269 ;
7270 return 0;
7271}
7272_ACEOF
7273rm -f conftest.$ac_objext
7274if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7275 (eval $ac_compile) 2>conftest.er1
96f3a036 7276 ac_status=$?
35996d22
AS
7277 grep -v '^ *+' conftest.er1 >conftest.err
7278 rm -f conftest.er1
7279 cat conftest.err >&5
96f3a036
DL
7280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7281 (exit $ac_status); } &&
35996d22
AS
7282 { ac_try='test -z "$ac_c_werror_flag"
7283 || test ! -s conftest.err'
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); }; } &&
7289 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7290 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7291 (eval $ac_try) 2>&5
7292 ac_status=$?
7293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7294 (exit $ac_status); }; }; then
7295 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7296else
7297 echo "$as_me: failed program was:" >&5
7298sed 's/^/| /' conftest.$ac_ext >&5
7299
7300ac_cv_member_struct_ifreq_ifr_broadaddr=no
7301fi
35996d22 7302rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7303fi
35996d22 7304rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7305fi
7306echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
7307echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6
7308if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
7309
7310cat >>confdefs.h <<_ACEOF
7311#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
7312_ACEOF
7313
7314
7315fi
7316echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
7317echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6
7318if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
7319 echo $ECHO_N "(cached) $ECHO_C" >&6
7320else
7321 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7322/* confdefs.h. */
7323_ACEOF
7324cat confdefs.h >>conftest.$ac_ext
7325cat >>conftest.$ac_ext <<_ACEOF
7326/* end confdefs.h. */
7862d3a8
AS
7327$ac_includes_default
7328#if HAVE_SYS_SOCKET_H
7329#include <sys/socket.h>
7330#endif
7331#if HAVE_NET_IF_H
96f3a036 7332#include <net/if.h>
7862d3a8 7333#endif
96f3a036
DL
7334
7335int
7336main ()
7337{
7338static struct ifreq ac_aggr;
7339if (ac_aggr.ifr_addr)
7340return 0;
7341 ;
7342 return 0;
7343}
7344_ACEOF
7345rm -f conftest.$ac_objext
7346if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7347 (eval $ac_compile) 2>conftest.er1
96f3a036 7348 ac_status=$?
35996d22
AS
7349 grep -v '^ *+' conftest.er1 >conftest.err
7350 rm -f conftest.er1
7351 cat conftest.err >&5
96f3a036
DL
7352 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7353 (exit $ac_status); } &&
35996d22
AS
7354 { ac_try='test -z "$ac_c_werror_flag"
7355 || test ! -s conftest.err'
7356 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7357 (eval $ac_try) 2>&5
7358 ac_status=$?
7359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7360 (exit $ac_status); }; } &&
7361 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7362 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7363 (eval $ac_try) 2>&5
7364 ac_status=$?
7365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7366 (exit $ac_status); }; }; then
7367 ac_cv_member_struct_ifreq_ifr_addr=yes
7368else
7369 echo "$as_me: failed program was:" >&5
7370sed 's/^/| /' conftest.$ac_ext >&5
7371
7372cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7373/* confdefs.h. */
7374_ACEOF
7375cat confdefs.h >>conftest.$ac_ext
7376cat >>conftest.$ac_ext <<_ACEOF
7377/* end confdefs.h. */
7862d3a8
AS
7378$ac_includes_default
7379#if HAVE_SYS_SOCKET_H
7380#include <sys/socket.h>
7381#endif
7382#if HAVE_NET_IF_H
96f3a036 7383#include <net/if.h>
7862d3a8 7384#endif
96f3a036
DL
7385
7386int
7387main ()
7388{
7389static struct ifreq ac_aggr;
7390if (sizeof ac_aggr.ifr_addr)
7391return 0;
7392 ;
7393 return 0;
7394}
7395_ACEOF
7396rm -f conftest.$ac_objext
7397if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7398 (eval $ac_compile) 2>conftest.er1
96f3a036 7399 ac_status=$?
35996d22
AS
7400 grep -v '^ *+' conftest.er1 >conftest.err
7401 rm -f conftest.er1
7402 cat conftest.err >&5
96f3a036
DL
7403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7404 (exit $ac_status); } &&
35996d22
AS
7405 { ac_try='test -z "$ac_c_werror_flag"
7406 || test ! -s conftest.err'
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); }; } &&
7412 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7413 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7414 (eval $ac_try) 2>&5
7415 ac_status=$?
7416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7417 (exit $ac_status); }; }; then
7418 ac_cv_member_struct_ifreq_ifr_addr=yes
7419else
7420 echo "$as_me: failed program was:" >&5
7421sed 's/^/| /' conftest.$ac_ext >&5
7422
7423ac_cv_member_struct_ifreq_ifr_addr=no
7424fi
35996d22 7425rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7426fi
35996d22 7427rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7428fi
7429echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
7430echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6
7431if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
7432
7433cat >>confdefs.h <<_ACEOF
7434#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
7435_ACEOF
7436
7437
7438fi
7439
8799b3e4 7440
8799b3e4 7441
c0d27fcc 7442echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
7443echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
7444if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 7445 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7446echo "${ECHO_T}yes" >&6
7447
c0d27fcc 7448cat >>confdefs.h <<\_ACEOF
98418dba 7449#define PROTOTYPES 1
c0d27fcc
MR
7450_ACEOF
7451
7452
7453cat >>confdefs.h <<\_ACEOF
7454#define __PROTOTYPES 1
7455_ACEOF
98418dba
CW
7456
7457else
c0d27fcc 7458 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7459echo "${ECHO_T}no" >&6
7460fi
7461
c0d27fcc 7462echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
7463echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
7464if test "${ac_cv_c_volatile+set}" = set; then
7465 echo $ECHO_N "(cached) $ECHO_C" >&6
7466else
7467 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7468/* confdefs.h. */
7469_ACEOF
7470cat confdefs.h >>conftest.$ac_ext
7471cat >>conftest.$ac_ext <<_ACEOF
7472/* end confdefs.h. */
98418dba 7473
98418dba
CW
7474int
7475main ()
7476{
7477
7478volatile int x;
7479int * volatile y;
7480 ;
7481 return 0;
7482}
7483_ACEOF
7484rm -f conftest.$ac_objext
c0d27fcc 7485if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7486 (eval $ac_compile) 2>conftest.er1
98418dba 7487 ac_status=$?
35996d22
AS
7488 grep -v '^ *+' conftest.er1 >conftest.err
7489 rm -f conftest.er1
7490 cat conftest.err >&5
c0d27fcc 7491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7492 (exit $ac_status); } &&
35996d22
AS
7493 { ac_try='test -z "$ac_c_werror_flag"
7494 || test ! -s conftest.err'
7495 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7496 (eval $ac_try) 2>&5
7497 ac_status=$?
7498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7499 (exit $ac_status); }; } &&
7500 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7501 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7502 (eval $ac_try) 2>&5
7503 ac_status=$?
c0d27fcc 7504 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7505 (exit $ac_status); }; }; then
7506 ac_cv_c_volatile=yes
7507else
7508 echo "$as_me: failed program was:" >&5
19650fd6
AS
7509sed 's/^/| /' conftest.$ac_ext >&5
7510
98418dba
CW
7511ac_cv_c_volatile=no
7512fi
35996d22 7513rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7514fi
c0d27fcc 7515echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
7516echo "${ECHO_T}$ac_cv_c_volatile" >&6
7517if test $ac_cv_c_volatile = no; then
7518
c0d27fcc 7519cat >>confdefs.h <<\_ACEOF
98418dba 7520#define volatile
c0d27fcc 7521_ACEOF
98418dba
CW
7522
7523fi
7524
c0d27fcc 7525echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
7526echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
7527if test "${ac_cv_c_const+set}" = set; then
7528 echo $ECHO_N "(cached) $ECHO_C" >&6
7529else
7530 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7531/* confdefs.h. */
7532_ACEOF
7533cat confdefs.h >>conftest.$ac_ext
7534cat >>conftest.$ac_ext <<_ACEOF
7535/* end confdefs.h. */
98418dba 7536
98418dba
CW
7537int
7538main ()
7539{
7540/* FIXME: Include the comments suggested by Paul. */
7541#ifndef __cplusplus
7542 /* Ultrix mips cc rejects this. */
7543 typedef int charset[2];
7544 const charset x;
7545 /* SunOS 4.1.1 cc rejects this. */
7546 char const *const *ccp;
7547 char **p;
7548 /* NEC SVR4.0.2 mips cc rejects this. */
7549 struct point {int x, y;};
7550 static struct point const zero = {0,0};
7551 /* AIX XL C 1.02.0.0 rejects this.
7552 It does not let you subtract one const X* pointer from another in
7553 an arm of an if-expression whose if-part is not a constant
7554 expression */
7555 const char *g = "string";
7556 ccp = &g + (g ? g-g : 0);
7557 /* HPUX 7.0 cc rejects these. */
7558 ++ccp;
7559 p = (char**) ccp;
7560 ccp = (char const *const *) p;
7561 { /* SCO 3.2v4 cc rejects this. */
7562 char *t;
7563 char const *s = 0 ? (char *) 0 : (char const *) 0;
7564
7565 *t++ = 0;
7566 }
7567 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7568 int x[] = {25, 17};
7569 const int *foo = &x[0];
7570 ++foo;
7571 }
7572 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7573 typedef const int *iptr;
7574 iptr p = 0;
7575 ++p;
7576 }
7577 { /* AIX XL C 1.02.0.0 rejects this saying
7578 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7579 struct s { int j; const int *ap[3]; };
7580 struct s *b; b->j = 5;
7581 }
7582 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7583 const int foo = 10;
7584 }
7585#endif
7586
7587 ;
7588 return 0;
7589}
7590_ACEOF
7591rm -f conftest.$ac_objext
c0d27fcc 7592if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7593 (eval $ac_compile) 2>conftest.er1
98418dba 7594 ac_status=$?
35996d22
AS
7595 grep -v '^ *+' conftest.er1 >conftest.err
7596 rm -f conftest.er1
7597 cat conftest.err >&5
c0d27fcc 7598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7599 (exit $ac_status); } &&
35996d22
AS
7600 { ac_try='test -z "$ac_c_werror_flag"
7601 || test ! -s conftest.err'
7602 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7603 (eval $ac_try) 2>&5
7604 ac_status=$?
7605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7606 (exit $ac_status); }; } &&
7607 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7608 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7609 (eval $ac_try) 2>&5
7610 ac_status=$?
c0d27fcc 7611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7612 (exit $ac_status); }; }; then
7613 ac_cv_c_const=yes
7614else
7615 echo "$as_me: failed program was:" >&5
19650fd6
AS
7616sed 's/^/| /' conftest.$ac_ext >&5
7617
98418dba
CW
7618ac_cv_c_const=no
7619fi
35996d22 7620rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7621fi
c0d27fcc 7622echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
7623echo "${ECHO_T}$ac_cv_c_const" >&6
7624if test $ac_cv_c_const = no; then
7625
c0d27fcc 7626cat >>confdefs.h <<\_ACEOF
98418dba 7627#define const
c0d27fcc 7628_ACEOF
98418dba
CW
7629
7630fi
7631
c0d27fcc 7632echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
7633echo $ECHO_N "checking for void * support... $ECHO_C" >&6
7634if test "${emacs_cv_void_star+set}" = set; then
7635 echo $ECHO_N "(cached) $ECHO_C" >&6
7636else
7637 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7638/* confdefs.h. */
7639_ACEOF
7640cat confdefs.h >>conftest.$ac_ext
7641cat >>conftest.$ac_ext <<_ACEOF
7642/* end confdefs.h. */
98418dba 7643
98418dba
CW
7644int
7645main ()
7646{
7647void * foo;
7648 ;
7649 return 0;
7650}
7651_ACEOF
7652rm -f conftest.$ac_objext
c0d27fcc 7653if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7654 (eval $ac_compile) 2>conftest.er1
98418dba 7655 ac_status=$?
35996d22
AS
7656 grep -v '^ *+' conftest.er1 >conftest.err
7657 rm -f conftest.er1
7658 cat conftest.err >&5
c0d27fcc 7659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7660 (exit $ac_status); } &&
35996d22
AS
7661 { ac_try='test -z "$ac_c_werror_flag"
7662 || test ! -s conftest.err'
7663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7664 (eval $ac_try) 2>&5
7665 ac_status=$?
7666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7667 (exit $ac_status); }; } &&
7668 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7670 (eval $ac_try) 2>&5
7671 ac_status=$?
c0d27fcc 7672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7673 (exit $ac_status); }; }; then
7674 emacs_cv_void_star=yes
7675else
7676 echo "$as_me: failed program was:" >&5
19650fd6
AS
7677sed 's/^/| /' conftest.$ac_ext >&5
7678
98418dba
CW
7679emacs_cv_void_star=no
7680fi
35996d22 7681rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7682fi
c0d27fcc 7683echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
7684echo "${ECHO_T}$emacs_cv_void_star" >&6
7685if test $emacs_cv_void_star = yes; then
c0d27fcc 7686 cat >>confdefs.h <<\_ACEOF
98418dba 7687#define POINTER_TYPE void
c0d27fcc 7688_ACEOF
98418dba
CW
7689
7690else
c0d27fcc 7691 cat >>confdefs.h <<\_ACEOF
98418dba 7692#define POINTER_TYPE char
c0d27fcc 7693_ACEOF
98418dba
CW
7694
7695fi
7696
c0d27fcc 7697
cd958eb3 7698
19650fd6
AS
7699echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7700echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
35996d22 7701set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
98418dba
CW
7702if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
7703 echo $ECHO_N "(cached) $ECHO_C" >&6
7704else
c0d27fcc 7705 cat >conftest.make <<\_ACEOF
98418dba 7706all:
19650fd6 7707 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 7708_ACEOF
98418dba
CW
7709# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7710eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
7711if test -n "$ac_maketemp"; then
7712 eval ac_cv_prog_make_${ac_make}_set=yes
7713else
7714 eval ac_cv_prog_make_${ac_make}_set=no
7715fi
7716rm -f conftest.make
7717fi
7718if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 7719 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7720echo "${ECHO_T}yes" >&6
7721 SET_MAKE=
7722else
c0d27fcc 7723 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7724echo "${ECHO_T}no" >&6
7725 SET_MAKE="MAKE=${MAKE-make}"
7726fi
7727
c0d27fcc
MR
7728
7729echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
7730echo $ECHO_N "checking for long file names... $ECHO_C" >&6
7731if test "${ac_cv_sys_long_file_names+set}" = set; then
7732 echo $ECHO_N "(cached) $ECHO_C" >&6
7733else
7734 ac_cv_sys_long_file_names=yes
7735# Test for long file names in all the places we know might matter:
7736# . the current directory, where building will happen
7737# $prefix/lib where we will be installing things
7738# $exec_prefix/lib likewise
7739# eval it to expand exec_prefix.
7740# $TMPDIR if set, where it might want to write temporary files
7741# if $TMPDIR is not set:
7742# /tmp where it might want to write temporary files
7743# /var/tmp likewise
7744# /usr/tmp likewise
7745if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
7746 ac_tmpdirs=$TMPDIR
7747else
7748 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
7749fi
7750for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
7751 test -d $ac_dir || continue
7752 test -w $ac_dir || continue # It is less confusing to not echo anything here.
7753 ac_xdir=$ac_dir/cf$$
7754 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
7755 ac_tf1=$ac_xdir/conftest9012345
7756 ac_tf2=$ac_xdir/conftest9012346
7757 (echo 1 >$ac_tf1) 2>/dev/null
7758 (echo 2 >$ac_tf2) 2>/dev/null
7759 ac_val=`cat $ac_tf1 2>/dev/null`
7760 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
7761 ac_cv_sys_long_file_names=no
7762 rm -rf $ac_xdir 2>/dev/null
7763 break
7764 fi
7765 rm -rf $ac_xdir 2>/dev/null
7766done
7767fi
c0d27fcc 7768echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
7769echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
7770if test $ac_cv_sys_long_file_names = yes; then
7771
c0d27fcc 7772cat >>confdefs.h <<\_ACEOF
98418dba 7773#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 7774_ACEOF
98418dba
CW
7775
7776fi
7777
c0d27fcc 7778
98418dba
CW
7779#### Choose a window system.
7780
c0d27fcc 7781echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
7782echo $ECHO_N "checking for X... $ECHO_C" >&6
7783
c0d27fcc 7784
98418dba
CW
7785# Check whether --with-x or --without-x was given.
7786if test "${with_x+set}" = set; then
7787 withval="$with_x"
7788
7789fi;
7790# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7791if test "x$with_x" = xno; then
7792 # The user explicitly disabled X.
7793 have_x=disabled
7794else
7795 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7796 # Both variables are already set.
7797 have_x=yes
7798 else
7799 if test "${ac_cv_have_x+set}" = set; then
7800 echo $ECHO_N "(cached) $ECHO_C" >&6
7801else
7802 # One or both of the vars are not set, and there is no cached value.
7803ac_x_includes=no ac_x_libraries=no
7804rm -fr conftest.dir
7805if mkdir conftest.dir; then
7806 cd conftest.dir
7807 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 7808 cat >Imakefile <<'_ACEOF'
98418dba
CW
7809acfindx:
7810 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 7811_ACEOF
98418dba
CW
7812 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7813 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7814 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7815 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7816 for ac_extension in a so sl; do
7817 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
35996d22
AS
7818 test -f $ac_im_libdir/libX11.$ac_extension; then
7819 ac_im_usrlibdir=$ac_im_libdir; break
98418dba
CW
7820 fi
7821 done
7822 # Screen out bogus values from the imake configuration. They are
7823 # bogus both because they are the default anyway, and because
7824 # using them would break gcc on systems where it needs fixed includes.
7825 case $ac_im_incroot in
7826 /usr/include) ;;
7827 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7828 esac
7829 case $ac_im_usrlibdir in
7830 /usr/lib | /lib) ;;
7831 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7832 esac
7833 fi
7834 cd ..
7835 rm -fr conftest.dir
7836fi
7837
7838# Standard set of common directories for X headers.
7839# Check X11 before X11Rn because it is often a symlink to the current release.
7840ac_x_header_dirs='
7841/usr/X11/include
7842/usr/X11R6/include
7843/usr/X11R5/include
7844/usr/X11R4/include
7845
7846/usr/include/X11
7847/usr/include/X11R6
7848/usr/include/X11R5
7849/usr/include/X11R4
7850
7851/usr/local/X11/include
7852/usr/local/X11R6/include
7853/usr/local/X11R5/include
7854/usr/local/X11R4/include
7855
7856/usr/local/include/X11
7857/usr/local/include/X11R6
7858/usr/local/include/X11R5
7859/usr/local/include/X11R4
7860
7861/usr/X386/include
7862/usr/x386/include
7863/usr/XFree86/include/X11
7864
7865/usr/include
7866/usr/local/include
7867/usr/unsupported/include
7868/usr/athena/include
7869/usr/local/x11r5/include
7870/usr/lpp/Xamples/include
7871
7872/usr/openwin/include
7873/usr/openwin/share/include'
7874
7875if test "$ac_x_includes" = no; then
7876 # Guess where to find include files, by looking for Intrinsic.h.
7877 # First, try using that file with no special directory specified.
7878 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7879/* confdefs.h. */
7880_ACEOF
7881cat confdefs.h >>conftest.$ac_ext
7882cat >>conftest.$ac_ext <<_ACEOF
7883/* end confdefs.h. */
98418dba
CW
7884#include <X11/Intrinsic.h>
7885_ACEOF
c0d27fcc 7886if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
7887 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7888 ac_status=$?
6bae0ccf 7889 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
7890 rm -f conftest.er1
7891 cat conftest.err >&5
c0d27fcc 7892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7893 (exit $ac_status); } >/dev/null; then
7894 if test -s conftest.err; then
7895 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 7896 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
7897 else
7898 ac_cpp_err=
7899 fi
7900else
7901 ac_cpp_err=yes
7902fi
7903if test -z "$ac_cpp_err"; then
7904 # We can compile using X headers with no special include directory.
7905ac_x_includes=
7906else
7907 echo "$as_me: failed program was:" >&5
19650fd6
AS
7908sed 's/^/| /' conftest.$ac_ext >&5
7909
98418dba
CW
7910 for ac_dir in $ac_x_header_dirs; do
7911 if test -r "$ac_dir/X11/Intrinsic.h"; then
7912 ac_x_includes=$ac_dir
7913 break
7914 fi
7915done
7916fi
7917rm -f conftest.err conftest.$ac_ext
7918fi # $ac_x_includes = no
7919
7920if test "$ac_x_libraries" = no; then
7921 # Check for the libraries.
7922 # See if we find them without any special options.
7923 # Don't add to $LIBS permanently.
7924 ac_save_LIBS=$LIBS
7925 LIBS="-lXt $LIBS"
7926 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7927/* confdefs.h. */
7928_ACEOF
7929cat confdefs.h >>conftest.$ac_ext
7930cat >>conftest.$ac_ext <<_ACEOF
7931/* end confdefs.h. */
98418dba 7932#include <X11/Intrinsic.h>
98418dba
CW
7933int
7934main ()
7935{
7936XtMalloc (0)
7937 ;
7938 return 0;
7939}
7940_ACEOF
7941rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7942if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 7943 (eval $ac_link) 2>conftest.er1
98418dba 7944 ac_status=$?
35996d22
AS
7945 grep -v '^ *+' conftest.er1 >conftest.err
7946 rm -f conftest.er1
7947 cat conftest.err >&5
c0d27fcc 7948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7949 (exit $ac_status); } &&
35996d22
AS
7950 { ac_try='test -z "$ac_c_werror_flag"
7951 || test ! -s conftest.err'
7952 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7953 (eval $ac_try) 2>&5
7954 ac_status=$?
7955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7956 (exit $ac_status); }; } &&
7957 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7958 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7959 (eval $ac_try) 2>&5
7960 ac_status=$?
c0d27fcc 7961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7962 (exit $ac_status); }; }; then
7963 LIBS=$ac_save_LIBS
7964# We can link X programs with no special library path.
7965ac_x_libraries=
7966else
7967 echo "$as_me: failed program was:" >&5
19650fd6
AS
7968sed 's/^/| /' conftest.$ac_ext >&5
7969
98418dba
CW
7970LIBS=$ac_save_LIBS
7971for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7972do
7973 # Don't even attempt the hair of trying to link an X program!
7974 for ac_extension in a so sl; do
7975 if test -r $ac_dir/libXt.$ac_extension; then
7976 ac_x_libraries=$ac_dir
7977 break 2
7978 fi
7979 done
7980done
7981fi
35996d22
AS
7982rm -f conftest.err conftest.$ac_objext \
7983 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
7984fi # $ac_x_libraries = no
7985
7986if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
7987 # Didn't find X anywhere. Cache the known absence of X.
7988 ac_cv_have_x="have_x=no"
7989else
7990 # Record where we found X for the cache.
7991 ac_cv_have_x="have_x=yes \
35996d22 7992 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
98418dba
CW
7993fi
7994fi
7995
7996 fi
7997 eval "$ac_cv_have_x"
7998fi # $with_x != no
7999
8000if test "$have_x" != yes; then
c0d27fcc 8001 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
8002echo "${ECHO_T}$have_x" >&6
8003 no_x=yes
8004else
8005 # If each of the values was on the command line, it overrides each guess.
8006 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8007 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8008 # Update the cache value to reflect the command line values.
8009 ac_cv_have_x="have_x=yes \
8010 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
c0d27fcc 8011 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
98418dba
CW
8012echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
8013fi
8014
8015if test "$no_x" = yes; then
8016 window_system=none
8017else
8018 window_system=x11
8019fi
8020
8021if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8022 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
8023 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
8024 x_default_search_path=""
8025 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
8026 x_search_path="\
8027${x_library}/X11/%L/%T/%N%C%S:\
8028${x_library}/X11/%l/%T/%N%C%S:\
8029${x_library}/X11/%T/%N%C%S:\
8030${x_library}/X11/%L/%T/%N%S:\
8031${x_library}/X11/%l/%T/%N%S:\
8032${x_library}/X11/%T/%N%S"
8033 if test x"${x_default_search_path}" = x; then
8034 x_default_search_path=${x_search_path}
8035 else
8036 x_default_search_path="${x_search_path}:${x_default_search_path}"
8037 fi
8038 done
8039fi
8040if test "${x_includes}" != NONE && test -n "${x_includes}"; then
8041 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
8042fi
8043
8044if test x"${x_includes}" = x; then
8045 bitmapdir=/usr/include/X11/bitmaps
8046else
8047 # accumulate include directories that have X11 bitmap subdirectories
8048 bmd_acc="dummyval"
8049 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
8050 if test -d "${bmd}/X11/bitmaps"; then
8051 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
8052 fi
8053 if test -d "${bmd}/bitmaps"; then
8054 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
8055 fi
8056 done
8057 if test ${bmd_acc} != "dummyval"; then
8058 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
8059 fi
8060fi
8061
8062case "${window_system}" in
8063 x11 )
8064 HAVE_X_WINDOWS=yes
8065 HAVE_X11=yes
8066 case "${with_x_toolkit}" in
8067 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
8068 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
8069 gtk ) with_gtk=yes
8070 USE_X_TOOLKIT=none ;;
98418dba
CW
8071 no ) USE_X_TOOLKIT=none ;;
8072 * ) USE_X_TOOLKIT=maybe ;;
8073 esac
8074 ;;
8075 none )
8076 HAVE_X_WINDOWS=no
8077 HAVE_X11=no
8078 USE_X_TOOLKIT=none
8079 ;;
8080esac
8081
8082### If we're using X11, we should use the X menu package.
8083HAVE_MENUS=no
8084case ${HAVE_X11} in
8085 yes ) HAVE_MENUS=yes ;;
8086esac
8087
8088if test "${opsys}" = "hpux9"; then
8089 case "${x_libraries}" in
8090 *X11R4* )
8091 opsysfile="s/hpux9-x11r4.h"
8092 ;;
8093 esac
8094fi
8095
8096if test "${opsys}" = "hpux9shr"; then
8097 case "${x_libraries}" in
8098 *X11R4* )
8099 opsysfile="s/hpux9shxr4.h"
8100 ;;
8101 esac
8102fi
8103
8104### Compute the unexec source name from the object name.
8105UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
8106
8107# Do the opsystem or machine files prohibit the use of the GNU malloc?
8108# Assume not, until told otherwise.
8109GNU_MALLOC=yes
8110doug_lea_malloc=yes
c0d27fcc 8111echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
8112echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
8113if test "${ac_cv_func_malloc_get_state+set}" = set; then
8114 echo $ECHO_N "(cached) $ECHO_C" >&6
8115else
8116 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8117/* confdefs.h. */
8118_ACEOF
8119cat confdefs.h >>conftest.$ac_ext
8120cat >>conftest.$ac_ext <<_ACEOF
8121/* end confdefs.h. */
35996d22
AS
8122/* Define malloc_get_state to an innocuous variant, in case <limits.h> declares malloc_get_state.
8123 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8124#define malloc_get_state innocuous_malloc_get_state
8125
98418dba 8126/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8127 which can conflict with char malloc_get_state (); below.
8128 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8129 <limits.h> exists even on freestanding compilers. */
35996d22 8130
19650fd6
AS
8131#ifdef __STDC__
8132# include <limits.h>
8133#else
8134# include <assert.h>
8135#endif
35996d22
AS
8136
8137#undef malloc_get_state
8138
98418dba
CW
8139/* Override any gcc2 internal prototype to avoid an error. */
8140#ifdef __cplusplus
8141extern "C"
19650fd6 8142{
98418dba
CW
8143#endif
8144/* We use char because int might match the return type of a gcc2
8145 builtin and then its argument prototype would still apply. */
8146char malloc_get_state ();
98418dba
CW
8147/* The GNU C library defines this for functions which it implements
8148 to always fail with ENOSYS. Some functions are actually named
8149 something starting with __ and the normal name is an alias. */
8150#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
8151choke me
8152#else
19650fd6
AS
8153char (*f) () = malloc_get_state;
8154#endif
8155#ifdef __cplusplus
8156}
98418dba
CW
8157#endif
8158
19650fd6
AS
8159int
8160main ()
8161{
8162return f != malloc_get_state;
98418dba
CW
8163 ;
8164 return 0;
8165}
8166_ACEOF
8167rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8168if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8169 (eval $ac_link) 2>conftest.er1
98418dba 8170 ac_status=$?
35996d22
AS
8171 grep -v '^ *+' conftest.er1 >conftest.err
8172 rm -f conftest.er1
8173 cat conftest.err >&5
c0d27fcc 8174 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8175 (exit $ac_status); } &&
35996d22
AS
8176 { ac_try='test -z "$ac_c_werror_flag"
8177 || test ! -s conftest.err'
8178 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8179 (eval $ac_try) 2>&5
8180 ac_status=$?
8181 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8182 (exit $ac_status); }; } &&
8183 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8184 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8185 (eval $ac_try) 2>&5
8186 ac_status=$?
c0d27fcc 8187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8188 (exit $ac_status); }; }; then
8189 ac_cv_func_malloc_get_state=yes
8190else
8191 echo "$as_me: failed program was:" >&5
19650fd6
AS
8192sed 's/^/| /' conftest.$ac_ext >&5
8193
98418dba
CW
8194ac_cv_func_malloc_get_state=no
8195fi
35996d22
AS
8196rm -f conftest.err conftest.$ac_objext \
8197 conftest$ac_exeext conftest.$ac_ext
98418dba 8198fi
c0d27fcc 8199echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
8200echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
8201if test $ac_cv_func_malloc_get_state = yes; then
8202 :
8203else
8204 doug_lea_malloc=no
8205fi
8206
c0d27fcc 8207echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
8208echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
8209if test "${ac_cv_func_malloc_set_state+set}" = set; then
8210 echo $ECHO_N "(cached) $ECHO_C" >&6
8211else
8212 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8213/* confdefs.h. */
8214_ACEOF
8215cat confdefs.h >>conftest.$ac_ext
8216cat >>conftest.$ac_ext <<_ACEOF
8217/* end confdefs.h. */
35996d22
AS
8218/* Define malloc_set_state to an innocuous variant, in case <limits.h> declares malloc_set_state.
8219 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8220#define malloc_set_state innocuous_malloc_set_state
8221
98418dba 8222/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8223 which can conflict with char malloc_set_state (); below.
8224 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8225 <limits.h> exists even on freestanding compilers. */
35996d22 8226
19650fd6
AS
8227#ifdef __STDC__
8228# include <limits.h>
8229#else
8230# include <assert.h>
8231#endif
35996d22
AS
8232
8233#undef malloc_set_state
8234
98418dba
CW
8235/* Override any gcc2 internal prototype to avoid an error. */
8236#ifdef __cplusplus
8237extern "C"
19650fd6 8238{
98418dba
CW
8239#endif
8240/* We use char because int might match the return type of a gcc2
8241 builtin and then its argument prototype would still apply. */
8242char malloc_set_state ();
98418dba
CW
8243/* The GNU C library defines this for functions which it implements
8244 to always fail with ENOSYS. Some functions are actually named
8245 something starting with __ and the normal name is an alias. */
8246#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
8247choke me
8248#else
19650fd6
AS
8249char (*f) () = malloc_set_state;
8250#endif
8251#ifdef __cplusplus
8252}
98418dba
CW
8253#endif
8254
19650fd6
AS
8255int
8256main ()
8257{
8258return f != malloc_set_state;
98418dba
CW
8259 ;
8260 return 0;
8261}
8262_ACEOF
8263rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8264if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8265 (eval $ac_link) 2>conftest.er1
98418dba 8266 ac_status=$?
35996d22
AS
8267 grep -v '^ *+' conftest.er1 >conftest.err
8268 rm -f conftest.er1
8269 cat conftest.err >&5
c0d27fcc 8270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8271 (exit $ac_status); } &&
35996d22
AS
8272 { ac_try='test -z "$ac_c_werror_flag"
8273 || test ! -s conftest.err'
8274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8275 (eval $ac_try) 2>&5
8276 ac_status=$?
8277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8278 (exit $ac_status); }; } &&
8279 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8280 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8281 (eval $ac_try) 2>&5
8282 ac_status=$?
c0d27fcc 8283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8284 (exit $ac_status); }; }; then
8285 ac_cv_func_malloc_set_state=yes
8286else
8287 echo "$as_me: failed program was:" >&5
19650fd6
AS
8288sed 's/^/| /' conftest.$ac_ext >&5
8289
98418dba
CW
8290ac_cv_func_malloc_set_state=no
8291fi
35996d22
AS
8292rm -f conftest.err conftest.$ac_objext \
8293 conftest$ac_exeext conftest.$ac_ext
98418dba 8294fi
c0d27fcc 8295echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
8296echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
8297if test $ac_cv_func_malloc_set_state = yes; then
8298 :
8299else
8300 doug_lea_malloc=no
8301fi
8302
c0d27fcc 8303echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
8304echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
8305if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
8306 echo $ECHO_N "(cached) $ECHO_C" >&6
8307else
8308 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8309/* confdefs.h. */
8310_ACEOF
8311cat confdefs.h >>conftest.$ac_ext
8312cat >>conftest.$ac_ext <<_ACEOF
8313/* end confdefs.h. */
98418dba 8314extern void (* __after_morecore_hook)();
98418dba
CW
8315int
8316main ()
8317{
8318__after_morecore_hook = 0
8319 ;
8320 return 0;
8321}
8322_ACEOF
8323rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8324if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8325 (eval $ac_link) 2>conftest.er1
98418dba 8326 ac_status=$?
35996d22
AS
8327 grep -v '^ *+' conftest.er1 >conftest.err
8328 rm -f conftest.er1
8329 cat conftest.err >&5
c0d27fcc 8330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8331 (exit $ac_status); } &&
35996d22
AS
8332 { ac_try='test -z "$ac_c_werror_flag"
8333 || test ! -s conftest.err'
8334 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8335 (eval $ac_try) 2>&5
8336 ac_status=$?
8337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8338 (exit $ac_status); }; } &&
8339 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8340 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8341 (eval $ac_try) 2>&5
8342 ac_status=$?
c0d27fcc 8343 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8344 (exit $ac_status); }; }; then
8345 emacs_cv_var___after_morecore_hook=yes
8346else
8347 echo "$as_me: failed program was:" >&5
19650fd6
AS
8348sed 's/^/| /' conftest.$ac_ext >&5
8349
98418dba
CW
8350emacs_cv_var___after_morecore_hook=no
8351fi
35996d22
AS
8352rm -f conftest.err conftest.$ac_objext \
8353 conftest$ac_exeext conftest.$ac_ext
98418dba 8354fi
c0d27fcc 8355echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
8356echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
8357if test $emacs_cv_var___after_morecore_hook = no; then
8358 doug_lea_malloc=no
8359fi
8360if test "${system_malloc}" = "yes"; then
8361 GNU_MALLOC=no
8362 GNU_MALLOC_reason="
8363 (The GNU allocators don't work with this system configuration.)"
8364fi
8365if test "$doug_lea_malloc" = "yes" ; then
8366 if test "$GNU_MALLOC" = yes ; then
8367 GNU_MALLOC_reason="
8368 (Using Doug Lea's new malloc from the GNU C Library.)"
8369 fi
b936fae4 8370
c0d27fcc 8371cat >>confdefs.h <<\_ACEOF
98418dba 8372#define DOUG_LEA_MALLOC 1
c0d27fcc 8373_ACEOF
98418dba
CW
8374
8375fi
8376
8377if test x"${REL_ALLOC}" = x; then
8378 REL_ALLOC=${GNU_MALLOC}
8379fi
8380
8381
c0d27fcc
MR
8382
8383
8384for ac_header in stdlib.h unistd.h
98418dba
CW
8385do
8386as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
8387if eval "test \"\${$as_ac_Header+set}\" = set"; then
8388 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
8389echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8390if eval "test \"\${$as_ac_Header+set}\" = set"; then
8391 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8392fi
8393echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8394echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 8395else
c0d27fcc
MR
8396 # Is the header compilable?
8397echo "$as_me:$LINENO: checking $ac_header usability" >&5
8398echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8399cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8400/* confdefs.h. */
8401_ACEOF
8402cat confdefs.h >>conftest.$ac_ext
8403cat >>conftest.$ac_ext <<_ACEOF
8404/* end confdefs.h. */
98418dba
CW
8405$ac_includes_default
8406#include <$ac_header>
8407_ACEOF
8408rm -f conftest.$ac_objext
c0d27fcc 8409if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 8410 (eval $ac_compile) 2>conftest.er1
98418dba 8411 ac_status=$?
35996d22
AS
8412 grep -v '^ *+' conftest.er1 >conftest.err
8413 rm -f conftest.er1
8414 cat conftest.err >&5
c0d27fcc 8415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8416 (exit $ac_status); } &&
35996d22
AS
8417 { ac_try='test -z "$ac_c_werror_flag"
8418 || test ! -s conftest.err'
8419 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8420 (eval $ac_try) 2>&5
8421 ac_status=$?
8422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8423 (exit $ac_status); }; } &&
8424 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8425 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8426 (eval $ac_try) 2>&5
8427 ac_status=$?
c0d27fcc 8428 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8429 (exit $ac_status); }; }; then
c0d27fcc 8430 ac_header_compiler=yes
98418dba
CW
8431else
8432 echo "$as_me: failed program was:" >&5
19650fd6
AS
8433sed 's/^/| /' conftest.$ac_ext >&5
8434
c0d27fcc 8435ac_header_compiler=no
98418dba 8436fi
35996d22 8437rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
8438echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8439echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 8440
c0d27fcc
MR
8441# Is the header present?
8442echo "$as_me:$LINENO: checking $ac_header presence" >&5
8443echo $ECHO_N "checking $ac_header presence... $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#include <$ac_header>
8451_ACEOF
c0d27fcc 8452if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8453 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8454 ac_status=$?
6bae0ccf 8455 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8456 rm -f conftest.er1
8457 cat conftest.err >&5
c0d27fcc 8458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8459 (exit $ac_status); } >/dev/null; then
8460 if test -s conftest.err; then
8461 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 8462 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8463 else
8464 ac_cpp_err=
8465 fi
8466else
8467 ac_cpp_err=yes
8468fi
8469if test -z "$ac_cpp_err"; then
c0d27fcc 8470 ac_header_preproc=yes
98418dba
CW
8471else
8472 echo "$as_me: failed program was:" >&5
19650fd6
AS
8473sed 's/^/| /' conftest.$ac_ext >&5
8474
c0d27fcc 8475 ac_header_preproc=no
98418dba
CW
8476fi
8477rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8478echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8479echo "${ECHO_T}$ac_header_preproc" >&6
8480
8481# So? What about this header?
35996d22
AS
8482case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8483 yes:no: )
c0d27fcc
MR
8484 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8485echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
8486 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8487echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8488 ac_header_preproc=yes
19650fd6 8489 ;;
35996d22 8490 no:yes:* )
c0d27fcc
MR
8491 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8492echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
8493 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8494echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8495 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8496echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8497 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
8498echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 8499 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 8500echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
8501 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8502echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
8503 (
8504 cat <<\_ASBOX
35996d22
AS
8505## ------------------------------------------ ##
8506## Report this to the AC_PACKAGE_NAME lists. ##
8507## ------------------------------------------ ##
19650fd6
AS
8508_ASBOX
8509 ) |
8510 sed "s/^/$as_me: WARNING: /" >&2
8511 ;;
c0d27fcc
MR
8512esac
8513echo "$as_me:$LINENO: checking for $ac_header" >&5
8514echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8515if eval "test \"\${$as_ac_Header+set}\" = set"; then
8516 echo $ECHO_N "(cached) $ECHO_C" >&6
8517else
35996d22 8518 eval "$as_ac_Header=\$ac_header_preproc"
98418dba 8519fi
c0d27fcc 8520echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 8521echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
8522
8523fi
98418dba 8524if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 8525 cat >>confdefs.h <<_ACEOF
98418dba 8526#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 8527_ACEOF
98418dba
CW
8528
8529fi
c0d27fcc 8530
98418dba
CW
8531done
8532
c0d27fcc 8533
98418dba
CW
8534for ac_func in getpagesize
8535do
8536as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8537echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8538echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8539if eval "test \"\${$as_ac_var+set}\" = set"; then
8540 echo $ECHO_N "(cached) $ECHO_C" >&6
8541else
8542 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8543/* confdefs.h. */
8544_ACEOF
8545cat confdefs.h >>conftest.$ac_ext
8546cat >>conftest.$ac_ext <<_ACEOF
8547/* end confdefs.h. */
35996d22
AS
8548/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8549 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8550#define $ac_func innocuous_$ac_func
8551
98418dba 8552/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8553 which can conflict with char $ac_func (); below.
8554 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8555 <limits.h> exists even on freestanding compilers. */
35996d22 8556
19650fd6
AS
8557#ifdef __STDC__
8558# include <limits.h>
8559#else
8560# include <assert.h>
8561#endif
35996d22
AS
8562
8563#undef $ac_func
8564
98418dba
CW
8565/* Override any gcc2 internal prototype to avoid an error. */
8566#ifdef __cplusplus
8567extern "C"
19650fd6 8568{
98418dba
CW
8569#endif
8570/* We use char because int might match the return type of a gcc2
8571 builtin and then its argument prototype would still apply. */
8572char $ac_func ();
98418dba
CW
8573/* The GNU C library defines this for functions which it implements
8574 to always fail with ENOSYS. Some functions are actually named
8575 something starting with __ and the normal name is an alias. */
8576#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8577choke me
8578#else
19650fd6
AS
8579char (*f) () = $ac_func;
8580#endif
8581#ifdef __cplusplus
8582}
98418dba
CW
8583#endif
8584
19650fd6
AS
8585int
8586main ()
8587{
8588return f != $ac_func;
98418dba
CW
8589 ;
8590 return 0;
8591}
8592_ACEOF
8593rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8594if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8595 (eval $ac_link) 2>conftest.er1
98418dba 8596 ac_status=$?
35996d22
AS
8597 grep -v '^ *+' conftest.er1 >conftest.err
8598 rm -f conftest.er1
8599 cat conftest.err >&5
c0d27fcc 8600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8601 (exit $ac_status); } &&
35996d22
AS
8602 { ac_try='test -z "$ac_c_werror_flag"
8603 || test ! -s conftest.err'
8604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8605 (eval $ac_try) 2>&5
8606 ac_status=$?
8607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8608 (exit $ac_status); }; } &&
8609 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8610 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8611 (eval $ac_try) 2>&5
8612 ac_status=$?
c0d27fcc 8613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8614 (exit $ac_status); }; }; then
8615 eval "$as_ac_var=yes"
8616else
8617 echo "$as_me: failed program was:" >&5
19650fd6
AS
8618sed 's/^/| /' conftest.$ac_ext >&5
8619
98418dba
CW
8620eval "$as_ac_var=no"
8621fi
35996d22
AS
8622rm -f conftest.err conftest.$ac_objext \
8623 conftest$ac_exeext conftest.$ac_ext
98418dba 8624fi
c0d27fcc 8625echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
8626echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8627if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 8628 cat >>confdefs.h <<_ACEOF
98418dba 8629#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 8630_ACEOF
98418dba
CW
8631
8632fi
8633done
8634
c0d27fcc 8635echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
8636echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
8637if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8638 echo $ECHO_N "(cached) $ECHO_C" >&6
8639else
8640 if test "$cross_compiling" = yes; then
8641 ac_cv_func_mmap_fixed_mapped=no
8642else
8643 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8644/* confdefs.h. */
8645_ACEOF
8646cat confdefs.h >>conftest.$ac_ext
8647cat >>conftest.$ac_ext <<_ACEOF
8648/* end confdefs.h. */
98418dba 8649$ac_includes_default
c0d27fcc
MR
8650/* malloc might have been renamed as rpl_malloc. */
8651#undef malloc
8652
98418dba
CW
8653/* Thanks to Mike Haertel and Jim Avera for this test.
8654 Here is a matrix of mmap possibilities:
8655 mmap private not fixed
8656 mmap private fixed at somewhere currently unmapped
8657 mmap private fixed at somewhere already mapped
8658 mmap shared not fixed
8659 mmap shared fixed at somewhere currently unmapped
8660 mmap shared fixed at somewhere already mapped
8661 For private mappings, we should verify that changes cannot be read()
8662 back from the file, nor mmap's back from the file at a different
8663 address. (There have been systems where private was not correctly
8664 implemented like the infamous i386 svr4.0, and systems where the
8665 VM page cache was not coherent with the file system buffer cache
8666 like early versions of FreeBSD and possibly contemporary NetBSD.)
8667 For shared mappings, we should conversely verify that changes get
c0d27fcc 8668 propagated back to all the places they're supposed to be.
98418dba
CW
8669
8670 Grep wants private fixed already mapped.
8671 The main things grep needs to know about mmap are:
8672 * does it exist and is it safe to write into the mmap'd area
8673 * how to use it (BSD variants) */
8674
8675#include <fcntl.h>
8676#include <sys/mman.h>
8677
8678#if !STDC_HEADERS && !HAVE_STDLIB_H
8679char *malloc ();
8680#endif
8681
8682/* This mess was copied from the GNU getpagesize.h. */
8683#if !HAVE_GETPAGESIZE
8684/* Assume that all systems that can run configure have sys/param.h. */
8685# if !HAVE_SYS_PARAM_H
8686# define HAVE_SYS_PARAM_H 1
8687# endif
8688
8689# ifdef _SC_PAGESIZE
8690# define getpagesize() sysconf(_SC_PAGESIZE)
8691# else /* no _SC_PAGESIZE */
8692# if HAVE_SYS_PARAM_H
8693# include <sys/param.h>
8694# ifdef EXEC_PAGESIZE
8695# define getpagesize() EXEC_PAGESIZE
8696# else /* no EXEC_PAGESIZE */
8697# ifdef NBPG
8698# define getpagesize() NBPG * CLSIZE
8699# ifndef CLSIZE
8700# define CLSIZE 1
8701# endif /* no CLSIZE */
8702# else /* no NBPG */
8703# ifdef NBPC
8704# define getpagesize() NBPC
8705# else /* no NBPC */
8706# ifdef PAGESIZE
8707# define getpagesize() PAGESIZE
8708# endif /* PAGESIZE */
8709# endif /* no NBPC */
8710# endif /* no NBPG */
8711# endif /* no EXEC_PAGESIZE */
8712# else /* no HAVE_SYS_PARAM_H */
8713# define getpagesize() 8192 /* punt totally */
8714# endif /* no HAVE_SYS_PARAM_H */
8715# endif /* no _SC_PAGESIZE */
8716
8717#endif /* no HAVE_GETPAGESIZE */
8718
8719int
8720main ()
8721{
8722 char *data, *data2, *data3;
8723 int i, pagesize;
8724 int fd;
8725
8726 pagesize = getpagesize ();
8727
8728 /* First, make a file with some known garbage in it. */
8729 data = (char *) malloc (pagesize);
8730 if (!data)
8731 exit (1);
8732 for (i = 0; i < pagesize; ++i)
8733 *(data + i) = rand ();
8734 umask (0);
8735 fd = creat ("conftest.mmap", 0600);
8736 if (fd < 0)
8737 exit (1);
8738 if (write (fd, data, pagesize) != pagesize)
8739 exit (1);
8740 close (fd);
8741
8742 /* Next, try to mmap the file at a fixed address which already has
8743 something else allocated at it. If we can, also make sure that
8744 we see the same garbage. */
8745 fd = open ("conftest.mmap", O_RDWR);
8746 if (fd < 0)
8747 exit (1);
8748 data2 = (char *) malloc (2 * pagesize);
8749 if (!data2)
8750 exit (1);
35996d22 8751 data2 += (pagesize - ((long) data2 & (pagesize - 1))) & (pagesize - 1);
98418dba 8752 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
35996d22 8753 MAP_PRIVATE | MAP_FIXED, fd, 0L))
98418dba
CW
8754 exit (1);
8755 for (i = 0; i < pagesize; ++i)
8756 if (*(data + i) != *(data2 + i))
8757 exit (1);
8758
8759 /* Finally, make sure that changes to the mapped area do not
8760 percolate back to the file as seen by read(). (This is a bug on
8761 some variants of i386 svr4.0.) */
8762 for (i = 0; i < pagesize; ++i)
8763 *(data2 + i) = *(data2 + i) + 1;
8764 data3 = (char *) malloc (pagesize);
8765 if (!data3)
8766 exit (1);
8767 if (read (fd, data3, pagesize) != pagesize)
8768 exit (1);
8769 for (i = 0; i < pagesize; ++i)
8770 if (*(data + i) != *(data3 + i))
8771 exit (1);
8772 close (fd);
8773 exit (0);
8774}
8775_ACEOF
8776rm -f conftest$ac_exeext
c0d27fcc 8777if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8778 (eval $ac_link) 2>&5
8779 ac_status=$?
c0d27fcc 8780 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8781 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 8782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8783 (eval $ac_try) 2>&5
8784 ac_status=$?
c0d27fcc 8785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8786 (exit $ac_status); }; }; then
8787 ac_cv_func_mmap_fixed_mapped=yes
8788else
8789 echo "$as_me: program exited with status $ac_status" >&5
8790echo "$as_me: failed program was:" >&5
19650fd6
AS
8791sed 's/^/| /' conftest.$ac_ext >&5
8792
c0d27fcc 8793( exit $ac_status )
98418dba
CW
8794ac_cv_func_mmap_fixed_mapped=no
8795fi
35996d22 8796rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
8797fi
8798fi
c0d27fcc 8799echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
8800echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
8801if test $ac_cv_func_mmap_fixed_mapped = yes; then
8802
c0d27fcc 8803cat >>confdefs.h <<\_ACEOF
98418dba 8804#define HAVE_MMAP 1
c0d27fcc 8805_ACEOF
98418dba
CW
8806
8807fi
8808rm -f conftest.mmap
8809
8810if test $use_mmap_for_buffers = yes; then
8811 REL_ALLOC=no
8812fi
8813
8814LIBS="$libsrc_libs $LIBS"
8815
c0d27fcc
MR
8816
8817echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
8818echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
8819if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
8820 echo $ECHO_N "(cached) $ECHO_C" >&6
8821else
8822 ac_check_lib_save_LIBS=$LIBS
8823LIBS="-ldnet $LIBS"
8824cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8825/* confdefs.h. */
8826_ACEOF
8827cat confdefs.h >>conftest.$ac_ext
8828cat >>conftest.$ac_ext <<_ACEOF
8829/* end confdefs.h. */
98418dba
CW
8830
8831/* Override any gcc2 internal prototype to avoid an error. */
8832#ifdef __cplusplus
8833extern "C"
8834#endif
8835/* We use char because int might match the return type of a gcc2
8836 builtin and then its argument prototype would still apply. */
8837char dnet_ntoa ();
98418dba
CW
8838int
8839main ()
8840{
8841dnet_ntoa ();
8842 ;
8843 return 0;
8844}
8845_ACEOF
8846rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8847if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8848 (eval $ac_link) 2>conftest.er1
98418dba 8849 ac_status=$?
35996d22
AS
8850 grep -v '^ *+' conftest.er1 >conftest.err
8851 rm -f conftest.er1
8852 cat conftest.err >&5
c0d27fcc 8853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8854 (exit $ac_status); } &&
35996d22
AS
8855 { ac_try='test -z "$ac_c_werror_flag"
8856 || test ! -s conftest.err'
8857 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8858 (eval $ac_try) 2>&5
8859 ac_status=$?
8860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8861 (exit $ac_status); }; } &&
8862 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8864 (eval $ac_try) 2>&5
8865 ac_status=$?
c0d27fcc 8866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8867 (exit $ac_status); }; }; then
8868 ac_cv_lib_dnet_dnet_ntoa=yes
8869else
8870 echo "$as_me: failed program was:" >&5
19650fd6
AS
8871sed 's/^/| /' conftest.$ac_ext >&5
8872
98418dba
CW
8873ac_cv_lib_dnet_dnet_ntoa=no
8874fi
35996d22
AS
8875rm -f conftest.err conftest.$ac_objext \
8876 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8877LIBS=$ac_check_lib_save_LIBS
8878fi
c0d27fcc 8879echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
8880echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
8881if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 8882 cat >>confdefs.h <<_ACEOF
98418dba 8883#define HAVE_LIBDNET 1
c0d27fcc 8884_ACEOF
98418dba
CW
8885
8886 LIBS="-ldnet $LIBS"
8887
8888fi
8889
c0d27fcc
MR
8890
8891echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
8892echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
8893if test "${ac_cv_lib_Xbsd_main+set}" = set; then
8894 echo $ECHO_N "(cached) $ECHO_C" >&6
8895else
8896 ac_check_lib_save_LIBS=$LIBS
8897LIBS="-lXbsd $LIBS"
8898cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8899/* confdefs.h. */
8900_ACEOF
8901cat confdefs.h >>conftest.$ac_ext
8902cat >>conftest.$ac_ext <<_ACEOF
8903/* end confdefs.h. */
98418dba 8904
c0d27fcc 8905
98418dba
CW
8906int
8907main ()
8908{
8909main ();
8910 ;
8911 return 0;
8912}
8913_ACEOF
8914rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8915if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8916 (eval $ac_link) 2>conftest.er1
98418dba 8917 ac_status=$?
35996d22
AS
8918 grep -v '^ *+' conftest.er1 >conftest.err
8919 rm -f conftest.er1
8920 cat conftest.err >&5
c0d27fcc 8921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8922 (exit $ac_status); } &&
35996d22
AS
8923 { ac_try='test -z "$ac_c_werror_flag"
8924 || test ! -s conftest.err'
8925 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8926 (eval $ac_try) 2>&5
8927 ac_status=$?
8928 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8929 (exit $ac_status); }; } &&
8930 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8931 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8932 (eval $ac_try) 2>&5
8933 ac_status=$?
c0d27fcc 8934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8935 (exit $ac_status); }; }; then
8936 ac_cv_lib_Xbsd_main=yes
8937else
8938 echo "$as_me: failed program was:" >&5
19650fd6
AS
8939sed 's/^/| /' conftest.$ac_ext >&5
8940
98418dba
CW
8941ac_cv_lib_Xbsd_main=no
8942fi
35996d22
AS
8943rm -f conftest.err conftest.$ac_objext \
8944 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8945LIBS=$ac_check_lib_save_LIBS
8946fi
c0d27fcc 8947echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
8948echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
8949if test $ac_cv_lib_Xbsd_main = yes; then
8950 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
8951fi
8952
c0d27fcc
MR
8953
8954
8955echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
8956echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
8957if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
8958 echo $ECHO_N "(cached) $ECHO_C" >&6
8959else
8960 ac_check_lib_save_LIBS=$LIBS
8961LIBS="-lpthreads $LIBS"
8962cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8963/* confdefs.h. */
8964_ACEOF
8965cat confdefs.h >>conftest.$ac_ext
8966cat >>conftest.$ac_ext <<_ACEOF
8967/* end confdefs.h. */
98418dba
CW
8968
8969/* Override any gcc2 internal prototype to avoid an error. */
8970#ifdef __cplusplus
8971extern "C"
8972#endif
8973/* We use char because int might match the return type of a gcc2
8974 builtin and then its argument prototype would still apply. */
8975char cma_open ();
98418dba
CW
8976int
8977main ()
8978{
8979cma_open ();
8980 ;
8981 return 0;
8982}
8983_ACEOF
8984rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8985if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8986 (eval $ac_link) 2>conftest.er1
98418dba 8987 ac_status=$?
35996d22
AS
8988 grep -v '^ *+' conftest.er1 >conftest.err
8989 rm -f conftest.er1
8990 cat conftest.err >&5
c0d27fcc 8991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8992 (exit $ac_status); } &&
35996d22
AS
8993 { ac_try='test -z "$ac_c_werror_flag"
8994 || test ! -s conftest.err'
8995 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8996 (eval $ac_try) 2>&5
8997 ac_status=$?
8998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8999 (exit $ac_status); }; } &&
9000 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9001 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9002 (eval $ac_try) 2>&5
9003 ac_status=$?
c0d27fcc 9004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9005 (exit $ac_status); }; }; then
9006 ac_cv_lib_pthreads_cma_open=yes
9007else
9008 echo "$as_me: failed program was:" >&5
19650fd6
AS
9009sed 's/^/| /' conftest.$ac_ext >&5
9010
98418dba
CW
9011ac_cv_lib_pthreads_cma_open=no
9012fi
35996d22
AS
9013rm -f conftest.err conftest.$ac_objext \
9014 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9015LIBS=$ac_check_lib_save_LIBS
9016fi
c0d27fcc 9017echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
9018echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
9019if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 9020 cat >>confdefs.h <<_ACEOF
98418dba 9021#define HAVE_LIBPTHREADS 1
c0d27fcc 9022_ACEOF
98418dba
CW
9023
9024 LIBS="-lpthreads $LIBS"
9025
9026fi
9027
c0d27fcc
MR
9028
9029echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
9030echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
9031if test -d /usr/X386/include; then
9032 HAVE_XFREE386=yes
9033 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
9034else
9035 HAVE_XFREE386=no
9036fi
c0d27fcc 9037echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
9038echo "${ECHO_T}$HAVE_XFREE386" >&6
9039
55597d70
DL
9040
9041case ${host_os} in
9042aix*)
9043 echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
9044echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
9045if test "${gdb_cv_bigtoc+set}" = set; then
9046 echo $ECHO_N "(cached) $ECHO_C" >&6
9047else
9048
9049 case $GCC in
9050 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
9051 *) gdb_cv_bigtoc=-bbigtoc ;;
9052 esac
9053
9054 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
9055 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9056/* confdefs.h. */
9057_ACEOF
9058cat confdefs.h >>conftest.$ac_ext
9059cat >>conftest.$ac_ext <<_ACEOF
9060/* end confdefs.h. */
55597d70
DL
9061
9062int
9063main ()
9064{
9065int i;
9066 ;
9067 return 0;
9068}
9069_ACEOF
9070rm -f conftest.$ac_objext conftest$ac_exeext
9071if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9072 (eval $ac_link) 2>conftest.er1
55597d70 9073 ac_status=$?
35996d22
AS
9074 grep -v '^ *+' conftest.er1 >conftest.err
9075 rm -f conftest.er1
9076 cat conftest.err >&5
55597d70
DL
9077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9078 (exit $ac_status); } &&
35996d22
AS
9079 { ac_try='test -z "$ac_c_werror_flag"
9080 || test ! -s conftest.err'
9081 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9082 (eval $ac_try) 2>&5
9083 ac_status=$?
9084 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9085 (exit $ac_status); }; } &&
9086 { ac_try='test -s conftest$ac_exeext'
55597d70
DL
9087 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9088 (eval $ac_try) 2>&5
9089 ac_status=$?
9090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9091 (exit $ac_status); }; }; then
9092 :
9093else
9094 echo "$as_me: failed program was:" >&5
19650fd6
AS
9095sed 's/^/| /' conftest.$ac_ext >&5
9096
55597d70
DL
9097gdb_cv_bigtoc=
9098fi
35996d22
AS
9099rm -f conftest.err conftest.$ac_objext \
9100 conftest$ac_exeext conftest.$ac_ext
55597d70
DL
9101
9102fi
9103echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
9104echo "${ECHO_T}$gdb_cv_bigtoc" >&6
9105 ;;
9106esac
9107
ae1a998c
RS
9108# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
9109# used for the tests that follow. We set them back to REAL_CFLAGS and
9110# REAL_CPPFLAGS later on.
98418dba
CW
9111
9112REAL_CPPFLAGS="$CPPFLAGS"
9113
9114if test "${HAVE_X11}" = "yes"; then
9115 DEFS="$C_SWITCH_X_SITE $DEFS"
9116 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
9117 LIBS="$LIBX $LIBS"
9118 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
9119 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
9120
9121 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
9122 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
9123 # but it's more convenient here to set LD_RUN_PATH
9124 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
9125 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
9126 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
9127 export LD_RUN_PATH
9128 fi
9129
9130 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 9131 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
9132echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
9133 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9134/* confdefs.h. */
9135_ACEOF
9136cat confdefs.h >>conftest.$ac_ext
9137cat >>conftest.$ac_ext <<_ACEOF
9138/* end confdefs.h. */
98418dba 9139
98418dba
CW
9140int
9141main ()
9142{
9143XOpenDisplay ("foo");
9144 ;
9145 return 0;
9146}
9147_ACEOF
9148rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9149if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9150 (eval $ac_link) 2>conftest.er1
98418dba 9151 ac_status=$?
35996d22
AS
9152 grep -v '^ *+' conftest.er1 >conftest.err
9153 rm -f conftest.er1
9154 cat conftest.err >&5
c0d27fcc 9155 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9156 (exit $ac_status); } &&
35996d22
AS
9157 { ac_try='test -z "$ac_c_werror_flag"
9158 || test ! -s conftest.err'
c0d27fcc 9159 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9160 (eval $ac_try) 2>&5
9161 ac_status=$?
c0d27fcc 9162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
9163 (exit $ac_status); }; } &&
9164 { ac_try='test -s conftest$ac_exeext'
9165 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9166 (eval $ac_try) 2>&5
9167 ac_status=$?
9168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9169 (exit $ac_status); }; }; then
9170 xlinux_first_failure=no
98418dba
CW
9171else
9172 echo "$as_me: failed program was:" >&5
19650fd6
AS
9173sed 's/^/| /' conftest.$ac_ext >&5
9174
98418dba
CW
9175xlinux_first_failure=yes
9176fi
35996d22
AS
9177rm -f conftest.err conftest.$ac_objext \
9178 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9179 if test "${xlinux_first_failure}" = "yes"; then
9180 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
9181 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
9182 OLD_CPPFLAGS="$CPPFLAGS"
9183 OLD_LIBS="$LIBS"
9184 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
9185 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
9186 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
9187 LIBS="$LIBS -b i486-linuxaout"
9188 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9189/* confdefs.h. */
9190_ACEOF
9191cat confdefs.h >>conftest.$ac_ext
9192cat >>conftest.$ac_ext <<_ACEOF
9193/* end confdefs.h. */
98418dba 9194
98418dba
CW
9195int
9196main ()
9197{
9198XOpenDisplay ("foo");
9199 ;
9200 return 0;
9201}
9202_ACEOF
9203rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9204if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9205 (eval $ac_link) 2>conftest.er1
98418dba 9206 ac_status=$?
35996d22
AS
9207 grep -v '^ *+' conftest.er1 >conftest.err
9208 rm -f conftest.er1
9209 cat conftest.err >&5
c0d27fcc 9210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9211 (exit $ac_status); } &&
35996d22
AS
9212 { ac_try='test -z "$ac_c_werror_flag"
9213 || test ! -s conftest.err'
9214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9215 (eval $ac_try) 2>&5
9216 ac_status=$?
9217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9218 (exit $ac_status); }; } &&
9219 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9221 (eval $ac_try) 2>&5
9222 ac_status=$?
c0d27fcc 9223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9224 (exit $ac_status); }; }; then
9225 xlinux_second_failure=no
9226else
9227 echo "$as_me: failed program was:" >&5
19650fd6
AS
9228sed 's/^/| /' conftest.$ac_ext >&5
9229
98418dba
CW
9230xlinux_second_failure=yes
9231fi
35996d22
AS
9232rm -f conftest.err conftest.$ac_objext \
9233 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9234 if test "${xlinux_second_failure}" = "yes"; then
9235 # If we get the same failure with -b, there is no use adding -b.
9236 # So take it out. This plays safe.
9237 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
9238 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
9239 CPPFLAGS="$OLD_CPPFLAGS"
9240 LIBS="$OLD_LIBS"
c0d27fcc 9241 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9242echo "${ECHO_T}no" >&6
9243 else
c0d27fcc 9244 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9245echo "${ECHO_T}yes" >&6
9246 fi
9247 else
c0d27fcc 9248 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9249echo "${ECHO_T}no" >&6
9250 fi
9251 fi
9252
9253 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
9254 # header files included from there.
c0d27fcc 9255 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
9256echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
9257 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9258/* confdefs.h. */
9259_ACEOF
9260cat confdefs.h >>conftest.$ac_ext
9261cat >>conftest.$ac_ext <<_ACEOF
9262/* end confdefs.h. */
98418dba
CW
9263#include <X11/Xlib.h>
9264#include <X11/XKBlib.h>
98418dba
CW
9265int
9266main ()
9267{
9268XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
9269 ;
9270 return 0;
9271}
9272_ACEOF
9273rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9274if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9275 (eval $ac_link) 2>conftest.er1
98418dba 9276 ac_status=$?
35996d22
AS
9277 grep -v '^ *+' conftest.er1 >conftest.err
9278 rm -f conftest.er1
9279 cat conftest.err >&5
c0d27fcc 9280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9281 (exit $ac_status); } &&
35996d22
AS
9282 { ac_try='test -z "$ac_c_werror_flag"
9283 || test ! -s conftest.err'
9284 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9285 (eval $ac_try) 2>&5
9286 ac_status=$?
9287 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9288 (exit $ac_status); }; } &&
9289 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9290 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9291 (eval $ac_try) 2>&5
9292 ac_status=$?
c0d27fcc 9293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9294 (exit $ac_status); }; }; then
9295 emacs_xkb=yes
9296else
9297 echo "$as_me: failed program was:" >&5
19650fd6
AS
9298sed 's/^/| /' conftest.$ac_ext >&5
9299
98418dba
CW
9300emacs_xkb=no
9301fi
35996d22
AS
9302rm -f conftest.err conftest.$ac_objext \
9303 conftest$ac_exeext conftest.$ac_ext
c0d27fcc 9304 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
9305echo "${ECHO_T}$emacs_xkb" >&6
9306 if test $emacs_xkb = yes; then
b936fae4 9307
c0d27fcc 9308cat >>confdefs.h <<\_ACEOF
98418dba 9309#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 9310_ACEOF
98418dba
CW
9311
9312 fi
9313
c0d27fcc
MR
9314
9315
9316
9317
98418dba
CW
9318for ac_func in XrmSetDatabase XScreenResourceString \
9319XScreenNumberOfScreen XSetWMProtocols
9320do
9321as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 9322echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
9323echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9324if eval "test \"\${$as_ac_var+set}\" = set"; then
9325 echo $ECHO_N "(cached) $ECHO_C" >&6
9326else
9327 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9328/* confdefs.h. */
9329_ACEOF
9330cat confdefs.h >>conftest.$ac_ext
9331cat >>conftest.$ac_ext <<_ACEOF
9332/* end confdefs.h. */
35996d22
AS
9333/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9334 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9335#define $ac_func innocuous_$ac_func
9336
98418dba 9337/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
9338 which can conflict with char $ac_func (); below.
9339 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9340 <limits.h> exists even on freestanding compilers. */
35996d22 9341
19650fd6
AS
9342#ifdef __STDC__
9343# include <limits.h>
9344#else
9345# include <assert.h>
9346#endif
35996d22
AS
9347
9348#undef $ac_func
9349
98418dba
CW
9350/* Override any gcc2 internal prototype to avoid an error. */
9351#ifdef __cplusplus
9352extern "C"
19650fd6 9353{
98418dba
CW
9354#endif
9355/* We use char because int might match the return type of a gcc2
9356 builtin and then its argument prototype would still apply. */
9357char $ac_func ();
98418dba
CW
9358/* The GNU C library defines this for functions which it implements
9359 to always fail with ENOSYS. Some functions are actually named
9360 something starting with __ and the normal name is an alias. */
9361#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9362choke me
9363#else
19650fd6
AS
9364char (*f) () = $ac_func;
9365#endif
9366#ifdef __cplusplus
9367}
98418dba
CW
9368#endif
9369
19650fd6
AS
9370int
9371main ()
9372{
9373return f != $ac_func;
98418dba
CW
9374 ;
9375 return 0;
9376}
9377_ACEOF
9378rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9379if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9380 (eval $ac_link) 2>conftest.er1
98418dba 9381 ac_status=$?
35996d22
AS
9382 grep -v '^ *+' conftest.er1 >conftest.err
9383 rm -f conftest.er1
9384 cat conftest.err >&5
c0d27fcc 9385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9386 (exit $ac_status); } &&
35996d22
AS
9387 { ac_try='test -z "$ac_c_werror_flag"
9388 || test ! -s conftest.err'
9389 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9390 (eval $ac_try) 2>&5
9391 ac_status=$?
9392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9393 (exit $ac_status); }; } &&
9394 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9395 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9396 (eval $ac_try) 2>&5
9397 ac_status=$?
c0d27fcc 9398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9399 (exit $ac_status); }; }; then
9400 eval "$as_ac_var=yes"
9401else
9402 echo "$as_me: failed program was:" >&5
19650fd6
AS
9403sed 's/^/| /' conftest.$ac_ext >&5
9404
98418dba
CW
9405eval "$as_ac_var=no"
9406fi
35996d22
AS
9407rm -f conftest.err conftest.$ac_objext \
9408 conftest$ac_exeext conftest.$ac_ext
98418dba 9409fi
c0d27fcc 9410echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
9411echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9412if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 9413 cat >>confdefs.h <<_ACEOF
98418dba 9414#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 9415_ACEOF
98418dba
CW
9416
9417fi
9418done
9419
9420fi
9421
9422if test "${window_system}" = "x11"; then
c0d27fcc 9423 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
9424echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
9425 if test "${emacs_cv_x11_version_6+set}" = set; then
9426 echo $ECHO_N "(cached) $ECHO_C" >&6
9427else
9428 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9429/* confdefs.h. */
9430_ACEOF
9431cat confdefs.h >>conftest.$ac_ext
9432cat >>conftest.$ac_ext <<_ACEOF
9433/* end confdefs.h. */
98418dba 9434#include <X11/Xlib.h>
98418dba
CW
9435int
9436main ()
9437{
9438#if XlibSpecificationRelease < 6
9439fail;
9440#endif
9441
9442 ;
9443 return 0;
9444}
9445_ACEOF
9446rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9447if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9448 (eval $ac_link) 2>conftest.er1
98418dba 9449 ac_status=$?
35996d22
AS
9450 grep -v '^ *+' conftest.er1 >conftest.err
9451 rm -f conftest.er1
9452 cat conftest.err >&5
c0d27fcc 9453 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9454 (exit $ac_status); } &&
35996d22
AS
9455 { ac_try='test -z "$ac_c_werror_flag"
9456 || test ! -s conftest.err'
9457 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9458 (eval $ac_try) 2>&5
9459 ac_status=$?
9460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9461 (exit $ac_status); }; } &&
9462 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9463 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9464 (eval $ac_try) 2>&5
9465 ac_status=$?
c0d27fcc 9466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9467 (exit $ac_status); }; }; then
9468 emacs_cv_x11_version_6=yes
9469else
9470 echo "$as_me: failed program was:" >&5
19650fd6
AS
9471sed 's/^/| /' conftest.$ac_ext >&5
9472
98418dba
CW
9473emacs_cv_x11_version_6=no
9474fi
35996d22
AS
9475rm -f conftest.err conftest.$ac_objext \
9476 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9477fi
9478
9479 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 9480 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9481echo "${ECHO_T}6 or newer" >&6
b936fae4 9482
c0d27fcc 9483cat >>confdefs.h <<\_ACEOF
98418dba 9484#define HAVE_X11R6 1
c0d27fcc 9485_ACEOF
98418dba
CW
9486
9487 else
c0d27fcc 9488 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9489echo "${ECHO_T}before 6" >&6
9490 fi
9491fi
9492
9493if test "${window_system}" = "x11"; then
c0d27fcc 9494 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
9495echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
9496 if test "${emacs_cv_x11_version_5+set}" = set; then
9497 echo $ECHO_N "(cached) $ECHO_C" >&6
9498else
9499 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9500/* confdefs.h. */
9501_ACEOF
9502cat confdefs.h >>conftest.$ac_ext
9503cat >>conftest.$ac_ext <<_ACEOF
9504/* end confdefs.h. */
98418dba 9505#include <X11/Xlib.h>
98418dba
CW
9506int
9507main ()
9508{
9509#if XlibSpecificationRelease < 5
9510fail;
9511#endif
9512
9513 ;
9514 return 0;
9515}
9516_ACEOF
9517rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9518if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9519 (eval $ac_link) 2>conftest.er1
98418dba 9520 ac_status=$?
35996d22
AS
9521 grep -v '^ *+' conftest.er1 >conftest.err
9522 rm -f conftest.er1
9523 cat conftest.err >&5
c0d27fcc 9524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9525 (exit $ac_status); } &&
35996d22
AS
9526 { ac_try='test -z "$ac_c_werror_flag"
9527 || test ! -s conftest.err'
9528 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9529 (eval $ac_try) 2>&5
9530 ac_status=$?
9531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9532 (exit $ac_status); }; } &&
9533 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9534 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9535 (eval $ac_try) 2>&5
9536 ac_status=$?
c0d27fcc 9537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9538 (exit $ac_status); }; }; then
9539 emacs_cv_x11_version_5=yes
9540else
9541 echo "$as_me: failed program was:" >&5
19650fd6
AS
9542sed 's/^/| /' conftest.$ac_ext >&5
9543
98418dba
CW
9544emacs_cv_x11_version_5=no
9545fi
35996d22
AS
9546rm -f conftest.err conftest.$ac_objext \
9547 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9548fi
9549
9550 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 9551 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
9552echo "${ECHO_T}5 or newer" >&6
9553 HAVE_X11R5=yes
b936fae4 9554
c0d27fcc 9555cat >>confdefs.h <<\_ACEOF
98418dba 9556#define HAVE_X11R5 1
c0d27fcc 9557_ACEOF
98418dba
CW
9558
9559 else
9560 HAVE_X11R5=no
c0d27fcc 9561 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
9562echo "${ECHO_T}before 5" >&6
9563 fi
9564fi
9565
488dd4c4
JD
9566
9567
9568HAVE_GTK=no
9569if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 9570 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
9571 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
9572echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
9573 { (exit 1); exit 1; }; };
9574 fi
9575 GLIB_REQUIRED=2.0.1
e512ece1 9576 GTK_REQUIRED=2.0.1
488dd4c4
JD
9577 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
9578
9579 if test "X${with_pkg_config_prog}" != X; then
9580 PKG_CONFIG="${with_pkg_config_prog}"
9581 fi
9582
9583 succeeded=no
9584
9585 if test -z "$PKG_CONFIG"; then
9586 # Extract the first word of "pkg-config", so it can be a program name with args.
9587set dummy pkg-config; ac_word=$2
9588echo "$as_me:$LINENO: checking for $ac_word" >&5
9589echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9590if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9591 echo $ECHO_N "(cached) $ECHO_C" >&6
9592else
9593 case $PKG_CONFIG in
9594 [\\/]* | ?:[\\/]*)
9595 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9596 ;;
9597 *)
9598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9599for as_dir in $PATH
9600do
9601 IFS=$as_save_IFS
9602 test -z "$as_dir" && as_dir=.
9603 for ac_exec_ext in '' $ac_executable_extensions; do
9604 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9605 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9606 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9607 break 2
9608 fi
9609done
9610done
9611
9612 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9613 ;;
9614esac
9615fi
9616PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9617
9618if test -n "$PKG_CONFIG"; then
9619 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
9620echo "${ECHO_T}$PKG_CONFIG" >&6
9621else
9622 echo "$as_me:$LINENO: result: no" >&5
9623echo "${ECHO_T}no" >&6
9624fi
9625
9626 fi
9627
9628 if test "$PKG_CONFIG" = "no" ; then
9629 echo "*** The pkg-config script could not be found. Make sure it is"
9630 echo "*** in your path, or give the full path to pkg-config with"
9631 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
9632 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
9633 else
9634 PKG_CONFIG_MIN_VERSION=0.9.0
9635 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9636 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
9637echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
9638
9639 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
9640 echo "$as_me:$LINENO: result: yes" >&5
9641echo "${ECHO_T}yes" >&6
9642 succeeded=yes
9643
9644 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
9645echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
9646 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
9647 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
9648echo "${ECHO_T}$GTK_CFLAGS" >&6
9649
9650 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
9651echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
9652 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
9653 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
9654echo "${ECHO_T}$GTK_LIBS" >&6
9655 else
9656 GTK_CFLAGS=""
9657 GTK_LIBS=""
9658 ## If we have a custom action on failure, don't print errors, but
9659 ## do set a variable so people can do so.
9660 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
9661 echo $GTK_PKG_ERRORS
9662 fi
9663
9664
9665
9666 else
9667 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9668 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9669 fi
9670 fi
9671
9672 if test $succeeded = yes; then
9673 :
9674 else
9675 { { 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
9676echo "$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;}
9677 { (exit 1); exit 1; }; }
9678 fi
9679
9680
9681
9682 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
57669b57
JD
9683 CFLAGS="$CFLAGS $GTK_CFLAGS"
9684 LIBS="$GTK_LIBS $LIBS"
488dd4c4
JD
9685 HAVE_GTK=yes
9686
9687cat >>confdefs.h <<\_ACEOF
9688#define HAVE_GTK 1
9689_ACEOF
9690
9691 USE_X_TOOLKIT=none
9692
9693 with_toolkit_scroll_bars=yes
57669b57
JD
9694
9695 HAVE_GTK_MULTIDISPLAY=no
9696
9697for ac_func in gdk_display_open
9698do
9699as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9700echo "$as_me:$LINENO: checking for $ac_func" >&5
9701echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9702if eval "test \"\${$as_ac_var+set}\" = set"; then
9703 echo $ECHO_N "(cached) $ECHO_C" >&6
9704else
9705 cat >conftest.$ac_ext <<_ACEOF
57669b57
JD
9706/* confdefs.h. */
9707_ACEOF
9708cat confdefs.h >>conftest.$ac_ext
9709cat >>conftest.$ac_ext <<_ACEOF
9710/* end confdefs.h. */
35996d22
AS
9711/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9712 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9713#define $ac_func innocuous_$ac_func
9714
57669b57
JD
9715/* System header to define __stub macros and hopefully few prototypes,
9716 which can conflict with char $ac_func (); below.
9717 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9718 <limits.h> exists even on freestanding compilers. */
35996d22 9719
57669b57
JD
9720#ifdef __STDC__
9721# include <limits.h>
9722#else
9723# include <assert.h>
9724#endif
35996d22
AS
9725
9726#undef $ac_func
9727
57669b57
JD
9728/* Override any gcc2 internal prototype to avoid an error. */
9729#ifdef __cplusplus
9730extern "C"
9731{
9732#endif
9733/* We use char because int might match the return type of a gcc2
9734 builtin and then its argument prototype would still apply. */
9735char $ac_func ();
9736/* The GNU C library defines this for functions which it implements
9737 to always fail with ENOSYS. Some functions are actually named
9738 something starting with __ and the normal name is an alias. */
9739#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9740choke me
9741#else
9742char (*f) () = $ac_func;
9743#endif
9744#ifdef __cplusplus
9745}
9746#endif
9747
9748int
9749main ()
9750{
9751return f != $ac_func;
9752 ;
9753 return 0;
9754}
9755_ACEOF
9756rm -f conftest.$ac_objext conftest$ac_exeext
9757if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9758 (eval $ac_link) 2>conftest.er1
57669b57 9759 ac_status=$?
35996d22
AS
9760 grep -v '^ *+' conftest.er1 >conftest.err
9761 rm -f conftest.er1
9762 cat conftest.err >&5
57669b57
JD
9763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9764 (exit $ac_status); } &&
35996d22
AS
9765 { ac_try='test -z "$ac_c_werror_flag"
9766 || test ! -s conftest.err'
9767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9768 (eval $ac_try) 2>&5
9769 ac_status=$?
9770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9771 (exit $ac_status); }; } &&
9772 { ac_try='test -s conftest$ac_exeext'
57669b57
JD
9773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9774 (eval $ac_try) 2>&5
9775 ac_status=$?
9776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9777 (exit $ac_status); }; }; then
9778 eval "$as_ac_var=yes"
9779else
9780 echo "$as_me: failed program was:" >&5
9781sed 's/^/| /' conftest.$ac_ext >&5
9782
9783eval "$as_ac_var=no"
9784fi
35996d22
AS
9785rm -f conftest.err conftest.$ac_objext \
9786 conftest$ac_exeext conftest.$ac_ext
57669b57
JD
9787fi
9788echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9789echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9790if test `eval echo '${'$as_ac_var'}'` = yes; then
9791 cat >>confdefs.h <<_ACEOF
9792#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9793_ACEOF
9794 HAVE_GTK_MULTIDISPLAY=yes
9795fi
9796done
9797
9798 if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
9799
9800cat >>confdefs.h <<\_ACEOF
9801#define HAVE_GTK_MULTIDISPLAY 1
9802_ACEOF
9803
9804 fi
488dd4c4
JD
9805fi
9806
98418dba
CW
9807if test x"${USE_X_TOOLKIT}" = xmaybe; then
9808 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 9809 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
9810echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
9811 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
9812 echo $ECHO_N "(cached) $ECHO_C" >&6
9813else
9814 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9815/* confdefs.h. */
9816_ACEOF
9817cat confdefs.h >>conftest.$ac_ext
9818cat >>conftest.$ac_ext <<_ACEOF
9819/* end confdefs.h. */
98418dba
CW
9820
9821#include <X11/Intrinsic.h>
9822#include <X11/Xaw/Simple.h>
98418dba
CW
9823int
9824main ()
9825{
9826
9827 ;
9828 return 0;
9829}
9830_ACEOF
9831rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9832if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9833 (eval $ac_link) 2>conftest.er1
98418dba 9834 ac_status=$?
35996d22
AS
9835 grep -v '^ *+' conftest.er1 >conftest.err
9836 rm -f conftest.er1
9837 cat conftest.err >&5
c0d27fcc 9838 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9839 (exit $ac_status); } &&
35996d22
AS
9840 { ac_try='test -z "$ac_c_werror_flag"
9841 || test ! -s conftest.err'
9842 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9843 (eval $ac_try) 2>&5
9844 ac_status=$?
9845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9846 (exit $ac_status); }; } &&
9847 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9848 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9849 (eval $ac_try) 2>&5
9850 ac_status=$?
c0d27fcc 9851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9852 (exit $ac_status); }; }; then
9853 emacs_cv_x11_version_5_with_xaw=yes
9854else
9855 echo "$as_me: failed program was:" >&5
19650fd6
AS
9856sed 's/^/| /' conftest.$ac_ext >&5
9857
98418dba
CW
9858emacs_cv_x11_version_5_with_xaw=no
9859fi
35996d22
AS
9860rm -f conftest.err conftest.$ac_objext \
9861 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9862fi
9863
9864 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 9865 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
9866echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
9867 USE_X_TOOLKIT=LUCID
9868 else
c0d27fcc 9869 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
9870echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
9871 USE_X_TOOLKIT=none
9872 fi
9873 else
9874 USE_X_TOOLKIT=none
9875 fi
9876fi
9877
9878X_TOOLKIT_TYPE=$USE_X_TOOLKIT
9879
9880if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 9881 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
9882echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
9883 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
9884 echo $ECHO_N "(cached) $ECHO_C" >&6
9885else
9886 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9887/* confdefs.h. */
9888_ACEOF
9889cat confdefs.h >>conftest.$ac_ext
9890cat >>conftest.$ac_ext <<_ACEOF
9891/* end confdefs.h. */
98418dba 9892#include <X11/Intrinsic.h>
98418dba
CW
9893int
9894main ()
9895{
9896#if XtSpecificationRelease < 6
9897fail;
9898#endif
9899
9900 ;
9901 return 0;
9902}
9903_ACEOF
9904rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9905if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9906 (eval $ac_link) 2>conftest.er1
98418dba 9907 ac_status=$?
35996d22
AS
9908 grep -v '^ *+' conftest.er1 >conftest.err
9909 rm -f conftest.er1
9910 cat conftest.err >&5
c0d27fcc 9911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9912 (exit $ac_status); } &&
35996d22
AS
9913 { ac_try='test -z "$ac_c_werror_flag"
9914 || test ! -s conftest.err'
9915 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9916 (eval $ac_try) 2>&5
9917 ac_status=$?
9918 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9919 (exit $ac_status); }; } &&
9920 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9921 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9922 (eval $ac_try) 2>&5
9923 ac_status=$?
c0d27fcc 9924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9925 (exit $ac_status); }; }; then
9926 emacs_cv_x11_toolkit_version_6=yes
9927else
9928 echo "$as_me: failed program was:" >&5
19650fd6
AS
9929sed 's/^/| /' conftest.$ac_ext >&5
9930
98418dba
CW
9931emacs_cv_x11_toolkit_version_6=no
9932fi
35996d22
AS
9933rm -f conftest.err conftest.$ac_objext \
9934 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9935fi
9936
9937 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
9938 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 9939 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9940echo "${ECHO_T}6 or newer" >&6
b936fae4 9941
c0d27fcc 9942cat >>confdefs.h <<\_ACEOF
98418dba 9943#define HAVE_X11XTR6 1
c0d27fcc 9944_ACEOF
98418dba
CW
9945
9946 else
c0d27fcc 9947 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9948echo "${ECHO_T}before 6" >&6
9949 fi
9950
9951 OLDLIBS="$LIBS"
9952 if test x$HAVE_X11XTR6 = xyes; then
9953 LIBS="-lXt -lSM -lICE $LIBS"
9954 else
9955 LIBS="-lXt $LIBS"
9956 fi
9957
c0d27fcc 9958echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
9959echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
9960if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
9961 echo $ECHO_N "(cached) $ECHO_C" >&6
9962else
9963 ac_check_lib_save_LIBS=$LIBS
9964LIBS="-lXmu $LIBS"
9965cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9966/* confdefs.h. */
9967_ACEOF
9968cat confdefs.h >>conftest.$ac_ext
9969cat >>conftest.$ac_ext <<_ACEOF
9970/* end confdefs.h. */
98418dba
CW
9971
9972/* Override any gcc2 internal prototype to avoid an error. */
9973#ifdef __cplusplus
9974extern "C"
9975#endif
9976/* We use char because int might match the return type of a gcc2
9977 builtin and then its argument prototype would still apply. */
9978char XmuConvertStandardSelection ();
98418dba
CW
9979int
9980main ()
9981{
9982XmuConvertStandardSelection ();
9983 ;
9984 return 0;
9985}
9986_ACEOF
9987rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9988if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9989 (eval $ac_link) 2>conftest.er1
98418dba 9990 ac_status=$?
35996d22
AS
9991 grep -v '^ *+' conftest.er1 >conftest.err
9992 rm -f conftest.er1
9993 cat conftest.err >&5
c0d27fcc 9994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9995 (exit $ac_status); } &&
35996d22
AS
9996 { ac_try='test -z "$ac_c_werror_flag"
9997 || test ! -s conftest.err'
9998 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9999 (eval $ac_try) 2>&5
10000 ac_status=$?
10001 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10002 (exit $ac_status); }; } &&
10003 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10004 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10005 (eval $ac_try) 2>&5
10006 ac_status=$?
c0d27fcc 10007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10008 (exit $ac_status); }; }; then
10009 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
10010else
10011 echo "$as_me: failed program was:" >&5
19650fd6
AS
10012sed 's/^/| /' conftest.$ac_ext >&5
10013
98418dba
CW
10014ac_cv_lib_Xmu_XmuConvertStandardSelection=no
10015fi
35996d22
AS
10016rm -f conftest.err conftest.$ac_objext \
10017 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10018LIBS=$ac_check_lib_save_LIBS
10019fi
c0d27fcc 10020echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
10021echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
10022if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 10023 cat >>confdefs.h <<_ACEOF
98418dba 10024#define HAVE_LIBXMU 1
c0d27fcc 10025_ACEOF
98418dba
CW
10026
10027 LIBS="-lXmu $LIBS"
10028
10029fi
10030
10031 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
10032fi
10033
10034# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
10035if test "${HAVE_X11}" = "yes"; then
10036 if test "${USE_X_TOOLKIT}" != "none"; then
10037
c0d27fcc 10038echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
10039echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
10040if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
10041 echo $ECHO_N "(cached) $ECHO_C" >&6
10042else
10043 ac_check_lib_save_LIBS=$LIBS
10044LIBS="-lXext $LIBS"
10045cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10046/* confdefs.h. */
10047_ACEOF
10048cat confdefs.h >>conftest.$ac_ext
10049cat >>conftest.$ac_ext <<_ACEOF
10050/* end confdefs.h. */
98418dba
CW
10051
10052/* Override any gcc2 internal prototype to avoid an error. */
10053#ifdef __cplusplus
10054extern "C"
10055#endif
10056/* We use char because int might match the return type of a gcc2
10057 builtin and then its argument prototype would still apply. */
10058char XShapeQueryExtension ();
98418dba
CW
10059int
10060main ()
10061{
10062XShapeQueryExtension ();
10063 ;
10064 return 0;
10065}
10066_ACEOF
10067rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10068if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10069 (eval $ac_link) 2>conftest.er1
98418dba 10070 ac_status=$?
35996d22
AS
10071 grep -v '^ *+' conftest.er1 >conftest.err
10072 rm -f conftest.er1
10073 cat conftest.err >&5
c0d27fcc 10074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10075 (exit $ac_status); } &&
35996d22
AS
10076 { ac_try='test -z "$ac_c_werror_flag"
10077 || test ! -s conftest.err'
10078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10079 (eval $ac_try) 2>&5
10080 ac_status=$?
10081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10082 (exit $ac_status); }; } &&
10083 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10084 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10085 (eval $ac_try) 2>&5
10086 ac_status=$?
c0d27fcc 10087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10088 (exit $ac_status); }; }; then
10089 ac_cv_lib_Xext_XShapeQueryExtension=yes
10090else
10091 echo "$as_me: failed program was:" >&5
19650fd6
AS
10092sed 's/^/| /' conftest.$ac_ext >&5
10093
98418dba
CW
10094ac_cv_lib_Xext_XShapeQueryExtension=no
10095fi
35996d22
AS
10096rm -f conftest.err conftest.$ac_objext \
10097 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10098LIBS=$ac_check_lib_save_LIBS
10099fi
c0d27fcc 10100echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
10101echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
10102if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 10103 cat >>confdefs.h <<_ACEOF
98418dba 10104#define HAVE_LIBXEXT 1
c0d27fcc 10105_ACEOF
98418dba
CW
10106
10107 LIBS="-lXext $LIBS"
10108
10109fi
10110
10111 fi
10112fi
10113
10114if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10115 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
8e967cf7
MR
10116echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
10117if test "${emacs_cv_lesstif+set}" = set; then
10118 echo $ECHO_N "(cached) $ECHO_C" >&6
10119else
ae1a998c
RS
10120 # We put this in CFLAGS temporarily to precede other -I options
10121 # that might be in CFLAGS temporarily.
10122 # We put this in CPPFLAGS where it precedes the other -I options.
10123 OLD_CPPFLAGS=$CPPFLAGS
10124 OLD_CFLAGS=$CFLAGS
10125 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
10126 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
8e967cf7 10127 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10128/* confdefs.h. */
10129_ACEOF
10130cat confdefs.h >>conftest.$ac_ext
10131cat >>conftest.$ac_ext <<_ACEOF
10132/* end confdefs.h. */
8e967cf7
MR
10133#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
10134int
10135main ()
10136{
10137int x = 5;
10138 ;
10139 return 0;
10140}
10141_ACEOF
10142rm -f conftest.$ac_objext
c0d27fcc 10143if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10144 (eval $ac_compile) 2>conftest.er1
8e967cf7 10145 ac_status=$?
35996d22
AS
10146 grep -v '^ *+' conftest.er1 >conftest.err
10147 rm -f conftest.er1
10148 cat conftest.err >&5
c0d27fcc 10149 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7 10150 (exit $ac_status); } &&
35996d22
AS
10151 { ac_try='test -z "$ac_c_werror_flag"
10152 || test ! -s conftest.err'
10153 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10154 (eval $ac_try) 2>&5
10155 ac_status=$?
10156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10157 (exit $ac_status); }; } &&
10158 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10159 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8e967cf7
MR
10160 (eval $ac_try) 2>&5
10161 ac_status=$?
c0d27fcc 10162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
10163 (exit $ac_status); }; }; then
10164 emacs_cv_lesstif=yes
10165else
10166 echo "$as_me: failed program was:" >&5
19650fd6
AS
10167sed 's/^/| /' conftest.$ac_ext >&5
10168
8e967cf7
MR
10169emacs_cv_lesstif=no
10170fi
35996d22 10171rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8e967cf7 10172fi
c0d27fcc 10173echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
8e967cf7
MR
10174echo "${ECHO_T}$emacs_cv_lesstif" >&6
10175 if test $emacs_cv_lesstif = yes; then
ae1a998c
RS
10176 # Make sure this -I option remains in CPPFLAGS after it is set
10177 # back to REAL_CPPFLAGS.
10178 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
10179 # have those other -I options anyway. Ultimately, having this
10180 # directory ultimately in CPPFLAGS will be enough.
10181 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
8e967cf7 10182 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
ae1a998c
RS
10183 else
10184 CFLAGS=$OLD_CFLAGS
10185 CPPFLAGS=$OLD_CPPFLAGS
8e967cf7 10186 fi
c0d27fcc 10187 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
10188echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
10189if test "${emacs_cv_motif_version_2_1+set}" = set; then
10190 echo $ECHO_N "(cached) $ECHO_C" >&6
10191else
10192 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10193/* confdefs.h. */
10194_ACEOF
10195cat confdefs.h >>conftest.$ac_ext
10196cat >>conftest.$ac_ext <<_ACEOF
10197/* end confdefs.h. */
98418dba 10198#include <Xm/Xm.h>
98418dba
CW
10199int
10200main ()
10201{
10202#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
10203int x = 5;
10204#else
10205Motif version prior to 2.1.
10206#endif
10207 ;
10208 return 0;
10209}
10210_ACEOF
10211rm -f conftest.$ac_objext
c0d27fcc 10212if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10213 (eval $ac_compile) 2>conftest.er1
98418dba 10214 ac_status=$?
35996d22
AS
10215 grep -v '^ *+' conftest.er1 >conftest.err
10216 rm -f conftest.er1
10217 cat conftest.err >&5
c0d27fcc 10218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10219 (exit $ac_status); } &&
35996d22
AS
10220 { ac_try='test -z "$ac_c_werror_flag"
10221 || test ! -s conftest.err'
10222 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10223 (eval $ac_try) 2>&5
10224 ac_status=$?
10225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10226 (exit $ac_status); }; } &&
10227 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10228 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10229 (eval $ac_try) 2>&5
10230 ac_status=$?
c0d27fcc 10231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10232 (exit $ac_status); }; }; then
10233 emacs_cv_motif_version_2_1=yes
10234else
10235 echo "$as_me: failed program was:" >&5
19650fd6
AS
10236sed 's/^/| /' conftest.$ac_ext >&5
10237
98418dba
CW
10238emacs_cv_motif_version_2_1=no
10239fi
35996d22 10240rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 10241fi
c0d27fcc 10242echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
10243echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
10244 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
10245 if test $emacs_cv_motif_version_2_1 = yes; then
10246 HAVE_LIBXP=no
b936fae4 10247
c0d27fcc 10248cat >>confdefs.h <<\_ACEOF
98418dba 10249#define HAVE_MOTIF_2_1 1
c0d27fcc 10250_ACEOF
98418dba 10251
c0d27fcc 10252 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
10253echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
10254if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
10255 echo $ECHO_N "(cached) $ECHO_C" >&6
10256else
10257 ac_check_lib_save_LIBS=$LIBS
10258LIBS="-lXp $LIBS"
10259cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10260/* confdefs.h. */
10261_ACEOF
10262cat confdefs.h >>conftest.$ac_ext
10263cat >>conftest.$ac_ext <<_ACEOF
10264/* end confdefs.h. */
98418dba
CW
10265
10266/* Override any gcc2 internal prototype to avoid an error. */
10267#ifdef __cplusplus
10268extern "C"
10269#endif
10270/* We use char because int might match the return type of a gcc2
10271 builtin and then its argument prototype would still apply. */
10272char XpCreateContext ();
98418dba
CW
10273int
10274main ()
10275{
10276XpCreateContext ();
10277 ;
10278 return 0;
10279}
10280_ACEOF
10281rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10282if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10283 (eval $ac_link) 2>conftest.er1
98418dba 10284 ac_status=$?
35996d22
AS
10285 grep -v '^ *+' conftest.er1 >conftest.err
10286 rm -f conftest.er1
10287 cat conftest.err >&5
c0d27fcc 10288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10289 (exit $ac_status); } &&
35996d22
AS
10290 { ac_try='test -z "$ac_c_werror_flag"
10291 || test ! -s conftest.err'
10292 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10293 (eval $ac_try) 2>&5
10294 ac_status=$?
10295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10296 (exit $ac_status); }; } &&
10297 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10298 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10299 (eval $ac_try) 2>&5
10300 ac_status=$?
c0d27fcc 10301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10302 (exit $ac_status); }; }; then
10303 ac_cv_lib_Xp_XpCreateContext=yes
10304else
10305 echo "$as_me: failed program was:" >&5
19650fd6
AS
10306sed 's/^/| /' conftest.$ac_ext >&5
10307
98418dba
CW
10308ac_cv_lib_Xp_XpCreateContext=no
10309fi
35996d22
AS
10310rm -f conftest.err conftest.$ac_objext \
10311 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10312LIBS=$ac_check_lib_save_LIBS
10313fi
c0d27fcc 10314echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
10315echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
10316if test $ac_cv_lib_Xp_XpCreateContext = yes; then
10317 HAVE_LIBXP=yes
10318fi
503d2be0 10319
98418dba 10320 if test ${HAVE_LIBXP} = yes; then
b936fae4 10321
c0d27fcc 10322cat >>confdefs.h <<\_ACEOF
98418dba 10323#define HAVE_LIBXP 1
c0d27fcc 10324_ACEOF
503d2be0 10325
98418dba
CW
10326 fi
10327 fi
10328fi
10329
10330### Is -lXaw3d available?
10331HAVE_XAW3D=no
10332if test "${HAVE_X11}" = "yes"; then
10333 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 10334 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
10335echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
10336if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
10337 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 10338else
22044edf 10339 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10340/* confdefs.h. */
10341_ACEOF
10342cat confdefs.h >>conftest.$ac_ext
10343cat >>conftest.$ac_ext <<_ACEOF
10344/* end confdefs.h. */
98418dba 10345#include <X11/Xaw3d/Scrollbar.h>
503d2be0 10346_ACEOF
c0d27fcc 10347if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
10348 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10349 ac_status=$?
6bae0ccf 10350 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
10351 rm -f conftest.er1
10352 cat conftest.err >&5
c0d27fcc 10353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10354 (exit $ac_status); } >/dev/null; then
10355 if test -s conftest.err; then
10356 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10357 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
10358 else
10359 ac_cpp_err=
10360 fi
10361else
10362 ac_cpp_err=yes
10363fi
10364if test -z "$ac_cpp_err"; then
22044edf 10365 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 10366else
503d2be0 10367 echo "$as_me: failed program was:" >&5
19650fd6
AS
10368sed 's/^/| /' conftest.$ac_ext >&5
10369
22044edf 10370 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 10371fi
503d2be0 10372rm -f conftest.err conftest.$ac_ext
98418dba 10373fi
c0d27fcc 10374echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 10375echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 10376if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 10377 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
10378echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
10379if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
10380 echo $ECHO_N "(cached) $ECHO_C" >&6
10381else
10382 ac_check_lib_save_LIBS=$LIBS
10383LIBS="-lXaw3d $LIBS"
10384cat >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
CW
10390
10391/* Override any gcc2 internal prototype to avoid an error. */
10392#ifdef __cplusplus
10393extern "C"
10394#endif
10395/* We use char because int might match the return type of a gcc2
10396 builtin and then its argument prototype would still apply. */
10397char XawScrollbarSetThumb ();
503d2be0
AS
10398int
10399main ()
10400{
98418dba 10401XawScrollbarSetThumb ();
503d2be0
AS
10402 ;
10403 return 0;
10404}
10405_ACEOF
10406rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10407if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10408 (eval $ac_link) 2>conftest.er1
503d2be0 10409 ac_status=$?
35996d22
AS
10410 grep -v '^ *+' conftest.er1 >conftest.err
10411 rm -f conftest.er1
10412 cat conftest.err >&5
c0d27fcc 10413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10414 (exit $ac_status); } &&
35996d22
AS
10415 { ac_try='test -z "$ac_c_werror_flag"
10416 || test ! -s conftest.err'
10417 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10418 (eval $ac_try) 2>&5
10419 ac_status=$?
10420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10421 (exit $ac_status); }; } &&
10422 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10424 (eval $ac_try) 2>&5
10425 ac_status=$?
c0d27fcc 10426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10427 (exit $ac_status); }; }; then
98418dba 10428 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 10429else
503d2be0 10430 echo "$as_me: failed program was:" >&5
19650fd6
AS
10431sed 's/^/| /' conftest.$ac_ext >&5
10432
98418dba 10433ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 10434fi
35996d22
AS
10435rm -f conftest.err conftest.$ac_objext \
10436 conftest$ac_exeext conftest.$ac_ext
98418dba 10437LIBS=$ac_check_lib_save_LIBS
ba4481b5 10438fi
c0d27fcc 10439echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
10440echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
10441if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
10442 HAVE_XAW3D=yes
ba4481b5 10443fi
503d2be0 10444
ba4481b5
DL
10445fi
10446
c0d27fcc 10447
98418dba 10448 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 10449
c0d27fcc 10450cat >>confdefs.h <<\_ACEOF
98418dba 10451#define HAVE_XAW3D 1
c0d27fcc 10452_ACEOF
98418dba 10453
ba4481b5 10454 fi
98418dba 10455 fi
ba4481b5
DL
10456fi
10457
c0d27fcc
MR
10458
10459
98418dba
CW
10460USE_TOOLKIT_SCROLL_BARS=no
10461if test "${with_toolkit_scroll_bars}" != "no"; then
10462 if test "${USE_X_TOOLKIT}" != "none"; then
10463 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10464 cat >>confdefs.h <<\_ACEOF
98418dba 10465#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10466_ACEOF
98418dba
CW
10467
10468 HAVE_XAW3D=no
10469 USE_TOOLKIT_SCROLL_BARS=yes
10470 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 10471 cat >>confdefs.h <<\_ACEOF
98418dba 10472#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10473_ACEOF
98418dba
CW
10474
10475 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 10476 fi
488dd4c4
JD
10477 elif test "${HAVE_GTK}" = "yes"; then
10478 cat >>confdefs.h <<\_ACEOF
10479#define USE_TOOLKIT_SCROLL_BARS 1
10480_ACEOF
10481
10482 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
10483 fi
10484fi
10485
abd39b57 10486cat >conftest.$ac_ext <<_ACEOF
abd39b57
AC
10487/* confdefs.h. */
10488_ACEOF
10489cat confdefs.h >>conftest.$ac_ext
10490cat >>conftest.$ac_ext <<_ACEOF
10491/* end confdefs.h. */
10492
10493 #include <X11/Xlib.h>
10494 #include <X11/Xresource.h>
10495int
10496main ()
10497{
10498XIMProc callback;
10499 ;
10500 return 0;
10501}
10502_ACEOF
10503rm -f conftest.$ac_objext
10504if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10505 (eval $ac_compile) 2>conftest.er1
abd39b57 10506 ac_status=$?
35996d22
AS
10507 grep -v '^ *+' conftest.er1 >conftest.err
10508 rm -f conftest.er1
10509 cat conftest.err >&5
abd39b57
AC
10510 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10511 (exit $ac_status); } &&
35996d22
AS
10512 { ac_try='test -z "$ac_c_werror_flag"
10513 || test ! -s conftest.err'
10514 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10515 (eval $ac_try) 2>&5
10516 ac_status=$?
10517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10518 (exit $ac_status); }; } &&
10519 { ac_try='test -s conftest.$ac_objext'
abd39b57
AC
10520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10521 (eval $ac_try) 2>&5
10522 ac_status=$?
10523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10524 (exit $ac_status); }; }; then
10525 HAVE_XIM=yes
10526
10527cat >>confdefs.h <<\_ACEOF
10528#define HAVE_XIM 1
10529_ACEOF
10530
10531else
10532 echo "$as_me: failed program was:" >&5
10533sed 's/^/| /' conftest.$ac_ext >&5
10534
10535HAVE_XIM=no
10536fi
35996d22 10537rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
abd39b57 10538
c0d27fcc 10539
98418dba 10540if test "${with_xim}" != "no"; then
b936fae4 10541
c0d27fcc 10542cat >>confdefs.h <<\_ACEOF
98418dba 10543#define USE_XIM 1
c0d27fcc 10544_ACEOF
98418dba 10545
793fa0d7 10546fi
abd39b57
AC
10547
10548
10549if test "${HAVE_XIM}" != "no"; then
849d80cf
DL
10550 late_CFLAGS=$CFLAGS
10551 if test "$GCC" = yes; then
10552 CFLAGS="$CFLAGS --pedantic-errors"
10553 fi
cffcede7 10554 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10555/* confdefs.h. */
10556_ACEOF
10557cat confdefs.h >>conftest.$ac_ext
10558cat >>conftest.$ac_ext <<_ACEOF
10559/* end confdefs.h. */
cffcede7
JD
10560
10561#include <X11/Xlib.h>
10562#include <X11/Xresource.h>
10563int
10564main ()
10565{
10566Display *display;
10567XrmDatabase db;
10568char *res_name;
10569char *res_class;
10570XIMProc callback;
10571XPointer *client_data;
849d80cf
DL
10572#ifndef __GNUC__
10573/* If we're not using GCC, it's probably not XFree86, and this is
10574 probably right, but we can't use something like --pedantic-errors. */
10575extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
10576 char*, XIMProc, XPointer*);
10577#endif
cffcede7
JD
10578(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
10579 client_data);
10580 ;
10581 return 0;
10582}
10583_ACEOF
10584rm -f conftest.$ac_objext
10585if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10586 (eval $ac_compile) 2>conftest.er1
cffcede7 10587 ac_status=$?
35996d22
AS
10588 grep -v '^ *+' conftest.er1 >conftest.err
10589 rm -f conftest.er1
10590 cat conftest.err >&5
cffcede7
JD
10591 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10592 (exit $ac_status); } &&
35996d22
AS
10593 { ac_try='test -z "$ac_c_werror_flag"
10594 || test ! -s conftest.err'
10595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10596 (eval $ac_try) 2>&5
10597 ac_status=$?
10598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10599 (exit $ac_status); }; } &&
10600 { ac_try='test -s conftest.$ac_objext'
cffcede7
JD
10601 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10602 (eval $ac_try) 2>&5
10603 ac_status=$?
10604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10605 (exit $ac_status); }; }; then
10606 emacs_cv_arg6_star=yes
10607else
10608 echo "$as_me: failed program was:" >&5
19650fd6
AS
10609sed 's/^/| /' conftest.$ac_ext >&5
10610
cffcede7 10611fi
35996d22 10612rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cffcede7
JD
10613
10614 if test "$emacs_cv_arg6_star" = yes; then
f57bd967 10615 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10616#define XRegisterIMInstantiateCallback_arg6 XPointer*
10617_ACEOF
10618
10619 else
f57bd967 10620 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10621#define XRegisterIMInstantiateCallback_arg6 XPointer
10622_ACEOF
10623
10624 fi
849d80cf 10625 CFLAGS=$late_CFLAGS
98418dba
CW
10626fi
10627
10628### Use -lXpm if available, unless `--with-xpm=no'.
10629HAVE_XPM=no
10630if test "${HAVE_X11}" = "yes"; then
10631 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
10632 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10633 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
10634echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10635if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10636 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10637fi
10638echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
10639echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 10640else
c0d27fcc
MR
10641 # Is the header compilable?
10642echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
10643echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
10644cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10645/* confdefs.h. */
10646_ACEOF
10647cat confdefs.h >>conftest.$ac_ext
10648cat >>conftest.$ac_ext <<_ACEOF
10649/* end confdefs.h. */
c0d27fcc
MR
10650$ac_includes_default
10651#include <X11/xpm.h>
10652_ACEOF
10653rm -f conftest.$ac_objext
10654if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10655 (eval $ac_compile) 2>conftest.er1
c0d27fcc 10656 ac_status=$?
35996d22
AS
10657 grep -v '^ *+' conftest.er1 >conftest.err
10658 rm -f conftest.er1
10659 cat conftest.err >&5
c0d27fcc
MR
10660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10661 (exit $ac_status); } &&
35996d22
AS
10662 { ac_try='test -z "$ac_c_werror_flag"
10663 || test ! -s conftest.err'
10664 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10665 (eval $ac_try) 2>&5
10666 ac_status=$?
10667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10668 (exit $ac_status); }; } &&
10669 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10670 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10671 (eval $ac_try) 2>&5
10672 ac_status=$?
10673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10674 (exit $ac_status); }; }; then
10675 ac_header_compiler=yes
10676else
10677 echo "$as_me: failed program was:" >&5
19650fd6
AS
10678sed 's/^/| /' conftest.$ac_ext >&5
10679
c0d27fcc
MR
10680ac_header_compiler=no
10681fi
35996d22 10682rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10683echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10684echo "${ECHO_T}$ac_header_compiler" >&6
10685
10686# Is the header present?
10687echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
10688echo $ECHO_N "checking X11/xpm.h presence... $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. */
98418dba
CW
10695#include <X11/xpm.h>
10696_ACEOF
c0d27fcc 10697if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10698 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10699 ac_status=$?
6bae0ccf 10700 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10701 rm -f conftest.er1
10702 cat conftest.err >&5
c0d27fcc 10703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10704 (exit $ac_status); } >/dev/null; then
10705 if test -s conftest.err; then
10706 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10707 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
10708 else
10709 ac_cpp_err=
10710 fi
10711else
10712 ac_cpp_err=yes
10713fi
10714if test -z "$ac_cpp_err"; then
c0d27fcc 10715 ac_header_preproc=yes
98418dba
CW
10716else
10717 echo "$as_me: failed program was:" >&5
19650fd6
AS
10718sed 's/^/| /' conftest.$ac_ext >&5
10719
c0d27fcc 10720 ac_header_preproc=no
98418dba
CW
10721fi
10722rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10723echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10724echo "${ECHO_T}$ac_header_preproc" >&6
10725
10726# So? What about this header?
35996d22
AS
10727case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10728 yes:no: )
c0d27fcc
MR
10729 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
10730echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
10731 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the compiler's result" >&5
10732echo "$as_me: WARNING: X11/xpm.h: proceeding with the compiler's result" >&2;}
10733 ac_header_preproc=yes
19650fd6 10734 ;;
35996d22 10735 no:yes:* )
c0d27fcc
MR
10736 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
10737echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
35996d22
AS
10738 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
10739echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
10740 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: see the Autoconf documentation" >&5
10741echo "$as_me: WARNING: X11/xpm.h: see the Autoconf documentation" >&2;}
10742 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&5
10743echo "$as_me: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 10744 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
19650fd6 10745echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
10746 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&5
10747echo "$as_me: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
10748 (
10749 cat <<\_ASBOX
35996d22
AS
10750## ------------------------------------------ ##
10751## Report this to the AC_PACKAGE_NAME lists. ##
10752## ------------------------------------------ ##
19650fd6
AS
10753_ASBOX
10754 ) |
10755 sed "s/^/$as_me: WARNING: /" >&2
10756 ;;
c0d27fcc
MR
10757esac
10758echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
10759echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10760if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10761 echo $ECHO_N "(cached) $ECHO_C" >&6
10762else
10763 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 10764fi
c0d27fcc 10765echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 10766echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
10767
10768fi
98418dba 10769if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 10770 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
10771echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
10772if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 10773 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10774else
98418dba
CW
10775 ac_check_lib_save_LIBS=$LIBS
10776LIBS="-lXpm -lX11 $LIBS"
10777cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10778/* confdefs.h. */
10779_ACEOF
10780cat confdefs.h >>conftest.$ac_ext
10781cat >>conftest.$ac_ext <<_ACEOF
10782/* end confdefs.h. */
98418dba 10783
ba4481b5 10784/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10785#ifdef __cplusplus
10786extern "C"
10787#endif
ba4481b5 10788/* We use char because int might match the return type of a gcc2
503d2be0 10789 builtin and then its argument prototype would still apply. */
98418dba 10790char XpmReadFileToPixmap ();
503d2be0
AS
10791int
10792main ()
10793{
98418dba 10794XpmReadFileToPixmap ();
503d2be0
AS
10795 ;
10796 return 0;
10797}
10798_ACEOF
10799rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10800if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10801 (eval $ac_link) 2>conftest.er1
503d2be0 10802 ac_status=$?
35996d22
AS
10803 grep -v '^ *+' conftest.er1 >conftest.err
10804 rm -f conftest.er1
10805 cat conftest.err >&5
c0d27fcc 10806 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10807 (exit $ac_status); } &&
35996d22
AS
10808 { ac_try='test -z "$ac_c_werror_flag"
10809 || test ! -s conftest.err'
10810 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10811 (eval $ac_try) 2>&5
10812 ac_status=$?
10813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10814 (exit $ac_status); }; } &&
10815 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10816 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10817 (eval $ac_try) 2>&5
10818 ac_status=$?
c0d27fcc 10819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10820 (exit $ac_status); }; }; then
98418dba 10821 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
10822else
10823 echo "$as_me: failed program was:" >&5
19650fd6
AS
10824sed 's/^/| /' conftest.$ac_ext >&5
10825
98418dba 10826ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0 10827fi
35996d22
AS
10828rm -f conftest.err conftest.$ac_objext \
10829 conftest$ac_exeext conftest.$ac_ext
98418dba 10830LIBS=$ac_check_lib_save_LIBS
503d2be0 10831fi
c0d27fcc 10832echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
10833echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
10834if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
10835 HAVE_XPM=yes
ba4481b5
DL
10836fi
10837
98418dba
CW
10838fi
10839
c0d27fcc 10840
98418dba 10841 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10842 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
10843echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
10844 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10845/* confdefs.h. */
10846_ACEOF
10847cat confdefs.h >>conftest.$ac_ext
10848cat >>conftest.$ac_ext <<_ACEOF
10849/* end confdefs.h. */
98418dba
CW
10850#include "X11/xpm.h"
10851#ifndef XpmReturnAllocPixels
10852no_return_alloc_pixels
503d2be0 10853#endif
ba4481b5 10854
98418dba
CW
10855_ACEOF
10856if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10857 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
10858 HAVE_XPM=no
10859else
10860 HAVE_XPM=yes
10861fi
10862rm -f conftest*
ba4481b5 10863
c0d27fcc 10864
98418dba 10865 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10866 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
10867echo "${ECHO_T}yes" >&6
10868 else
c0d27fcc 10869 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
10870echo "${ECHO_T}no" >&6
10871 fi
10872 fi
10873 fi
10874
10875 if test "${HAVE_XPM}" = "yes"; then
b936fae4 10876
c0d27fcc 10877cat >>confdefs.h <<\_ACEOF
98418dba 10878#define HAVE_XPM 1
c0d27fcc 10879_ACEOF
98418dba
CW
10880
10881 fi
10882fi
10883
10884### Use -ljpeg if available, unless `--with-jpeg=no'.
10885HAVE_JPEG=no
10886if test "${HAVE_X11}" = "yes"; then
10887 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
10888 if test "${ac_cv_header_jerror_h+set}" = set; then
10889 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
10890echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
10891if test "${ac_cv_header_jerror_h+set}" = set; then
10892 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10893fi
10894echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
10895echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 10896else
c0d27fcc
MR
10897 # Is the header compilable?
10898echo "$as_me:$LINENO: checking jerror.h usability" >&5
10899echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
10900cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10901/* confdefs.h. */
10902_ACEOF
10903cat confdefs.h >>conftest.$ac_ext
10904cat >>conftest.$ac_ext <<_ACEOF
10905/* end confdefs.h. */
c0d27fcc
MR
10906$ac_includes_default
10907#include <jerror.h>
10908_ACEOF
10909rm -f conftest.$ac_objext
10910if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10911 (eval $ac_compile) 2>conftest.er1
c0d27fcc 10912 ac_status=$?
35996d22
AS
10913 grep -v '^ *+' conftest.er1 >conftest.err
10914 rm -f conftest.er1
10915 cat conftest.err >&5
c0d27fcc
MR
10916 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10917 (exit $ac_status); } &&
35996d22
AS
10918 { ac_try='test -z "$ac_c_werror_flag"
10919 || test ! -s conftest.err'
10920 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10921 (eval $ac_try) 2>&5
10922 ac_status=$?
10923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10924 (exit $ac_status); }; } &&
10925 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10926 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10927 (eval $ac_try) 2>&5
10928 ac_status=$?
10929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10930 (exit $ac_status); }; }; then
10931 ac_header_compiler=yes
10932else
10933 echo "$as_me: failed program was:" >&5
19650fd6
AS
10934sed 's/^/| /' conftest.$ac_ext >&5
10935
c0d27fcc
MR
10936ac_header_compiler=no
10937fi
35996d22 10938rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10939echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10940echo "${ECHO_T}$ac_header_compiler" >&6
10941
10942# Is the header present?
10943echo "$as_me:$LINENO: checking jerror.h presence" >&5
10944echo $ECHO_N "checking jerror.h presence... $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. */
98418dba
CW
10951#include <jerror.h>
10952_ACEOF
c0d27fcc 10953if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10954 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10955 ac_status=$?
6bae0ccf 10956 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10957 rm -f conftest.er1
10958 cat conftest.err >&5
c0d27fcc 10959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10960 (exit $ac_status); } >/dev/null; then
10961 if test -s conftest.err; then
10962 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10963 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
10964 else
10965 ac_cpp_err=
10966 fi
10967else
10968 ac_cpp_err=yes
503d2be0 10969fi
98418dba 10970if test -z "$ac_cpp_err"; then
c0d27fcc 10971 ac_header_preproc=yes
ba4481b5 10972else
98418dba 10973 echo "$as_me: failed program was:" >&5
19650fd6
AS
10974sed 's/^/| /' conftest.$ac_ext >&5
10975
c0d27fcc 10976 ac_header_preproc=no
98418dba
CW
10977fi
10978rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10979echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10980echo "${ECHO_T}$ac_header_preproc" >&6
10981
10982# So? What about this header?
35996d22
AS
10983case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10984 yes:no: )
c0d27fcc
MR
10985 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
10986echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
10987 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the compiler's result" >&5
10988echo "$as_me: WARNING: jerror.h: proceeding with the compiler's result" >&2;}
10989 ac_header_preproc=yes
19650fd6 10990 ;;
35996d22 10991 no:yes:* )
c0d27fcc
MR
10992 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
10993echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
35996d22
AS
10994 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
10995echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
10996 { echo "$as_me:$LINENO: WARNING: jerror.h: see the Autoconf documentation" >&5
10997echo "$as_me: WARNING: jerror.h: see the Autoconf documentation" >&2;}
10998 { echo "$as_me:$LINENO: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&5
10999echo "$as_me: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11000 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
19650fd6 11001echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11002 { echo "$as_me:$LINENO: WARNING: jerror.h: in the future, the compiler will take precedence" >&5
11003echo "$as_me: WARNING: jerror.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11004 (
11005 cat <<\_ASBOX
35996d22
AS
11006## ------------------------------------------ ##
11007## Report this to the AC_PACKAGE_NAME lists. ##
11008## ------------------------------------------ ##
19650fd6
AS
11009_ASBOX
11010 ) |
11011 sed "s/^/$as_me: WARNING: /" >&2
11012 ;;
c0d27fcc
MR
11013esac
11014echo "$as_me:$LINENO: checking for jerror.h" >&5
11015echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11016if test "${ac_cv_header_jerror_h+set}" = set; then
11017 echo $ECHO_N "(cached) $ECHO_C" >&6
11018else
11019 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 11020fi
c0d27fcc 11021echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 11022echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
11023
11024fi
98418dba 11025if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 11026 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
11027echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
11028if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 11029 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11030else
98418dba
CW
11031 ac_check_lib_save_LIBS=$LIBS
11032LIBS="-ljpeg $LIBS"
11033cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11034/* confdefs.h. */
11035_ACEOF
11036cat confdefs.h >>conftest.$ac_ext
11037cat >>conftest.$ac_ext <<_ACEOF
11038/* end confdefs.h. */
98418dba
CW
11039
11040/* Override any gcc2 internal prototype to avoid an error. */
11041#ifdef __cplusplus
11042extern "C"
11043#endif
11044/* We use char because int might match the return type of a gcc2
11045 builtin and then its argument prototype would still apply. */
11046char jpeg_destroy_compress ();
503d2be0
AS
11047int
11048main ()
11049{
98418dba 11050jpeg_destroy_compress ();
503d2be0
AS
11051 ;
11052 return 0;
11053}
11054_ACEOF
11055rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11056if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11057 (eval $ac_link) 2>conftest.er1
503d2be0 11058 ac_status=$?
35996d22
AS
11059 grep -v '^ *+' conftest.er1 >conftest.err
11060 rm -f conftest.er1
11061 cat conftest.err >&5
c0d27fcc 11062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11063 (exit $ac_status); } &&
35996d22
AS
11064 { ac_try='test -z "$ac_c_werror_flag"
11065 || test ! -s conftest.err'
11066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11067 (eval $ac_try) 2>&5
11068 ac_status=$?
11069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11070 (exit $ac_status); }; } &&
11071 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11073 (eval $ac_try) 2>&5
11074 ac_status=$?
c0d27fcc 11075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11076 (exit $ac_status); }; }; then
98418dba 11077 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 11078else
503d2be0 11079 echo "$as_me: failed program was:" >&5
19650fd6
AS
11080sed 's/^/| /' conftest.$ac_ext >&5
11081
98418dba 11082ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 11083fi
35996d22
AS
11084rm -f conftest.err conftest.$ac_objext \
11085 conftest$ac_exeext conftest.$ac_ext
98418dba 11086LIBS=$ac_check_lib_save_LIBS
ba4481b5 11087fi
c0d27fcc 11088echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
11089echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
11090if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
11091 HAVE_JPEG=yes
ba4481b5 11092fi
98418dba 11093
ba4481b5 11094fi
98418dba 11095
c0d27fcc 11096
ba4481b5 11097 fi
ba4481b5 11098
c0d27fcc 11099
98418dba 11100 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 11101 cat >>confdefs.h <<\_ACEOF
98418dba 11102#define HAVE_JPEG 1
c0d27fcc 11103_ACEOF
98418dba
CW
11104
11105 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11106/* confdefs.h. */
11107_ACEOF
11108cat confdefs.h >>conftest.$ac_ext
11109cat >>conftest.$ac_ext <<_ACEOF
11110/* end confdefs.h. */
22044edf 11111#include <jpeglib.h>
98418dba
CW
11112 version=JPEG_LIB_VERSION
11113
11114_ACEOF
11115if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11116 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 11117 cat >>confdefs.h <<\_ACEOF
98418dba 11118#define HAVE_JPEG 1
c0d27fcc 11119_ACEOF
ba4481b5 11120
98418dba 11121else
c0d27fcc 11122 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
11123echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
11124 HAVE_JPEG=no
ba4481b5 11125fi
98418dba 11126rm -f conftest*
ba4481b5 11127
98418dba
CW
11128 fi
11129fi
503d2be0 11130
98418dba
CW
11131### Use -lpng if available, unless `--with-png=no'.
11132HAVE_PNG=no
11133if test "${HAVE_X11}" = "yes"; then
11134 if test "${with_png}" != "no"; then
f57bd967
DL
11135 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
11136 # in /usr/include/libpng.
11137
11138
11139for ac_header in png.h libpng/png.h
11140do
11141as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11142if eval "test \"\${$as_ac_Header+set}\" = set"; then
11143 echo "$as_me:$LINENO: checking for $ac_header" >&5
11144echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11145if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11146 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc 11147fi
f57bd967
DL
11148echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11149echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
503d2be0 11150else
c0d27fcc 11151 # Is the header compilable?
f57bd967
DL
11152echo "$as_me:$LINENO: checking $ac_header usability" >&5
11153echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
c0d27fcc 11154cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11155/* confdefs.h. */
11156_ACEOF
11157cat confdefs.h >>conftest.$ac_ext
11158cat >>conftest.$ac_ext <<_ACEOF
11159/* end confdefs.h. */
c0d27fcc 11160$ac_includes_default
f57bd967 11161#include <$ac_header>
c0d27fcc
MR
11162_ACEOF
11163rm -f conftest.$ac_objext
11164if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11165 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11166 ac_status=$?
35996d22
AS
11167 grep -v '^ *+' conftest.er1 >conftest.err
11168 rm -f conftest.er1
11169 cat conftest.err >&5
c0d27fcc
MR
11170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11171 (exit $ac_status); } &&
35996d22
AS
11172 { ac_try='test -z "$ac_c_werror_flag"
11173 || test ! -s conftest.err'
11174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11175 (eval $ac_try) 2>&5
11176 ac_status=$?
11177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11178 (exit $ac_status); }; } &&
11179 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11181 (eval $ac_try) 2>&5
11182 ac_status=$?
11183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11184 (exit $ac_status); }; }; then
11185 ac_header_compiler=yes
11186else
11187 echo "$as_me: failed program was:" >&5
19650fd6
AS
11188sed 's/^/| /' conftest.$ac_ext >&5
11189
c0d27fcc
MR
11190ac_header_compiler=no
11191fi
35996d22 11192rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11193echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11194echo "${ECHO_T}$ac_header_compiler" >&6
11195
11196# Is the header present?
f57bd967
DL
11197echo "$as_me:$LINENO: checking $ac_header presence" >&5
11198echo $ECHO_N "checking $ac_header presence... $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. */
f57bd967 11205#include <$ac_header>
503d2be0 11206_ACEOF
c0d27fcc 11207if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11208 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11209 ac_status=$?
6bae0ccf 11210 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11211 rm -f conftest.er1
11212 cat conftest.err >&5
c0d27fcc 11213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11214 (exit $ac_status); } >/dev/null; then
11215 if test -s conftest.err; then
11216 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11217 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
11218 else
11219 ac_cpp_err=
11220 fi
11221else
11222 ac_cpp_err=yes
11223fi
11224if test -z "$ac_cpp_err"; then
c0d27fcc 11225 ac_header_preproc=yes
503d2be0
AS
11226else
11227 echo "$as_me: failed program was:" >&5
19650fd6
AS
11228sed 's/^/| /' conftest.$ac_ext >&5
11229
c0d27fcc 11230 ac_header_preproc=no
ba4481b5 11231fi
503d2be0 11232rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11233echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11234echo "${ECHO_T}$ac_header_preproc" >&6
11235
11236# So? What about this header?
35996d22
AS
11237case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11238 yes:no: )
f57bd967
DL
11239 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11240echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11241 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11242echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11243 ac_header_preproc=yes
19650fd6 11244 ;;
35996d22 11245 no:yes:* )
f57bd967
DL
11246 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11247echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
11248 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11249echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11250 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11251echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11252 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11253echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
f57bd967 11254 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 11255echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11256 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11257echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11258 (
11259 cat <<\_ASBOX
35996d22
AS
11260## ------------------------------------------ ##
11261## Report this to the AC_PACKAGE_NAME lists. ##
11262## ------------------------------------------ ##
19650fd6
AS
11263_ASBOX
11264 ) |
11265 sed "s/^/$as_me: WARNING: /" >&2
11266 ;;
c0d27fcc 11267esac
f57bd967
DL
11268echo "$as_me:$LINENO: checking for $ac_header" >&5
11269echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11270if eval "test \"\${$as_ac_Header+set}\" = set"; then
c0d27fcc
MR
11271 echo $ECHO_N "(cached) $ECHO_C" >&6
11272else
35996d22 11273 eval "$as_ac_Header=\$ac_header_preproc"
f57bd967
DL
11274fi
11275echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11276echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11277
ba4481b5 11278fi
f57bd967
DL
11279if test `eval echo '${'$as_ac_Header'}'` = yes; then
11280 cat >>confdefs.h <<_ACEOF
11281#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11282_ACEOF
c0d27fcc
MR
11283
11284fi
f57bd967
DL
11285
11286done
11287
11288 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
11289 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
11290echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
11291if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 11292 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11293else
98418dba
CW
11294 ac_check_lib_save_LIBS=$LIBS
11295LIBS="-lpng -lz -lm $LIBS"
11296cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11297/* confdefs.h. */
11298_ACEOF
11299cat confdefs.h >>conftest.$ac_ext
11300cat >>conftest.$ac_ext <<_ACEOF
11301/* end confdefs.h. */
98418dba 11302
ba4481b5 11303/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11304#ifdef __cplusplus
11305extern "C"
11306#endif
ba4481b5 11307/* We use char because int might match the return type of a gcc2
503d2be0 11308 builtin and then its argument prototype would still apply. */
98418dba 11309char png_get_channels ();
503d2be0
AS
11310int
11311main ()
11312{
98418dba 11313png_get_channels ();
503d2be0
AS
11314 ;
11315 return 0;
11316}
11317_ACEOF
11318rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11319if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11320 (eval $ac_link) 2>conftest.er1
503d2be0 11321 ac_status=$?
35996d22
AS
11322 grep -v '^ *+' conftest.er1 >conftest.err
11323 rm -f conftest.er1
11324 cat conftest.err >&5
c0d27fcc 11325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11326 (exit $ac_status); } &&
35996d22
AS
11327 { ac_try='test -z "$ac_c_werror_flag"
11328 || test ! -s conftest.err'
11329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11330 (eval $ac_try) 2>&5
11331 ac_status=$?
11332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11333 (exit $ac_status); }; } &&
11334 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11336 (eval $ac_try) 2>&5
11337 ac_status=$?
c0d27fcc 11338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11339 (exit $ac_status); }; }; then
98418dba 11340 ac_cv_lib_png_png_get_channels=yes
73b77ee5 11341else
98418dba 11342 echo "$as_me: failed program was:" >&5
19650fd6
AS
11343sed 's/^/| /' conftest.$ac_ext >&5
11344
98418dba 11345ac_cv_lib_png_png_get_channels=no
73b77ee5 11346fi
35996d22
AS
11347rm -f conftest.err conftest.$ac_objext \
11348 conftest$ac_exeext conftest.$ac_ext
98418dba 11349LIBS=$ac_check_lib_save_LIBS
73b77ee5 11350fi
c0d27fcc 11351echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
11352echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
11353if test $ac_cv_lib_png_png_get_channels = yes; then
11354 HAVE_PNG=yes
73b77ee5 11355fi
503d2be0 11356
f57bd967 11357 fi
98418dba
CW
11358 fi
11359
11360 if test "${HAVE_PNG}" = "yes"; then
b936fae4 11361
c0d27fcc 11362cat >>confdefs.h <<\_ACEOF
98418dba 11363#define HAVE_PNG 1
c0d27fcc 11364_ACEOF
73b77ee5 11365
98418dba 11366 fi
73b77ee5
GM
11367fi
11368
98418dba
CW
11369### Use -ltiff if available, unless `--with-tiff=no'.
11370HAVE_TIFF=no
11371if test "${HAVE_X11}" = "yes"; then
11372 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
11373 if test "${ac_cv_header_tiffio_h+set}" = set; then
11374 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
11375echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11376if test "${ac_cv_header_tiffio_h+set}" = set; then
11377 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11378fi
11379echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
11380echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 11381else
c0d27fcc
MR
11382 # Is the header compilable?
11383echo "$as_me:$LINENO: checking tiffio.h usability" >&5
11384echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
11385cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11386/* confdefs.h. */
11387_ACEOF
11388cat confdefs.h >>conftest.$ac_ext
11389cat >>conftest.$ac_ext <<_ACEOF
11390/* end confdefs.h. */
c0d27fcc
MR
11391$ac_includes_default
11392#include <tiffio.h>
11393_ACEOF
11394rm -f conftest.$ac_objext
11395if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11396 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11397 ac_status=$?
35996d22
AS
11398 grep -v '^ *+' conftest.er1 >conftest.err
11399 rm -f conftest.er1
11400 cat conftest.err >&5
c0d27fcc
MR
11401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11402 (exit $ac_status); } &&
35996d22
AS
11403 { ac_try='test -z "$ac_c_werror_flag"
11404 || test ! -s conftest.err'
11405 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11406 (eval $ac_try) 2>&5
11407 ac_status=$?
11408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11409 (exit $ac_status); }; } &&
11410 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11411 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11412 (eval $ac_try) 2>&5
11413 ac_status=$?
11414 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11415 (exit $ac_status); }; }; then
11416 ac_header_compiler=yes
11417else
11418 echo "$as_me: failed program was:" >&5
19650fd6
AS
11419sed 's/^/| /' conftest.$ac_ext >&5
11420
c0d27fcc
MR
11421ac_header_compiler=no
11422fi
35996d22 11423rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11424echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11425echo "${ECHO_T}$ac_header_compiler" >&6
11426
11427# Is the header present?
11428echo "$as_me:$LINENO: checking tiffio.h presence" >&5
11429echo $ECHO_N "checking tiffio.h presence... $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. */
98418dba
CW
11436#include <tiffio.h>
11437_ACEOF
c0d27fcc 11438if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11439 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11440 ac_status=$?
6bae0ccf 11441 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11442 rm -f conftest.er1
11443 cat conftest.err >&5
c0d27fcc 11444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11445 (exit $ac_status); } >/dev/null; then
11446 if test -s conftest.err; then
11447 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11448 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11449 else
11450 ac_cpp_err=
11451 fi
11452else
11453 ac_cpp_err=yes
11454fi
11455if test -z "$ac_cpp_err"; then
c0d27fcc 11456 ac_header_preproc=yes
98418dba
CW
11457else
11458 echo "$as_me: failed program was:" >&5
19650fd6
AS
11459sed 's/^/| /' conftest.$ac_ext >&5
11460
c0d27fcc 11461 ac_header_preproc=no
98418dba
CW
11462fi
11463rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11464echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11465echo "${ECHO_T}$ac_header_preproc" >&6
11466
11467# So? What about this header?
35996d22
AS
11468case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11469 yes:no: )
c0d27fcc
MR
11470 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
11471echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11472 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the compiler's result" >&5
11473echo "$as_me: WARNING: tiffio.h: proceeding with the compiler's result" >&2;}
11474 ac_header_preproc=yes
19650fd6 11475 ;;
35996d22 11476 no:yes:* )
c0d27fcc
MR
11477 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
11478echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
35996d22
AS
11479 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
11480echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
11481 { echo "$as_me:$LINENO: WARNING: tiffio.h: see the Autoconf documentation" >&5
11482echo "$as_me: WARNING: tiffio.h: see the Autoconf documentation" >&2;}
11483 { echo "$as_me:$LINENO: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&5
11484echo "$as_me: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11485 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
19650fd6 11486echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11487 { echo "$as_me:$LINENO: WARNING: tiffio.h: in the future, the compiler will take precedence" >&5
11488echo "$as_me: WARNING: tiffio.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11489 (
11490 cat <<\_ASBOX
35996d22
AS
11491## ------------------------------------------ ##
11492## Report this to the AC_PACKAGE_NAME lists. ##
11493## ------------------------------------------ ##
19650fd6
AS
11494_ASBOX
11495 ) |
11496 sed "s/^/$as_me: WARNING: /" >&2
11497 ;;
c0d27fcc
MR
11498esac
11499echo "$as_me:$LINENO: checking for tiffio.h" >&5
11500echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11501if test "${ac_cv_header_tiffio_h+set}" = set; then
11502 echo $ECHO_N "(cached) $ECHO_C" >&6
11503else
11504 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 11505fi
c0d27fcc 11506echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 11507echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
11508
11509fi
98418dba
CW
11510if test $ac_cv_header_tiffio_h = yes; then
11511 tifflibs="-lz -lm"
11512 # At least one tiff package requires the jpeg library.
11513 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 11514 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
11515echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
11516if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 11517 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11518else
503d2be0 11519 ac_check_lib_save_LIBS=$LIBS
98418dba 11520LIBS="-ltiff $tifflibs $LIBS"
503d2be0 11521cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11522/* confdefs.h. */
11523_ACEOF
11524cat confdefs.h >>conftest.$ac_ext
11525cat >>conftest.$ac_ext <<_ACEOF
11526/* end confdefs.h. */
503d2be0 11527
73b77ee5 11528/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11529#ifdef __cplusplus
11530extern "C"
11531#endif
73b77ee5 11532/* We use char because int might match the return type of a gcc2
503d2be0 11533 builtin and then its argument prototype would still apply. */
98418dba 11534char TIFFGetVersion ();
503d2be0
AS
11535int
11536main ()
11537{
98418dba 11538TIFFGetVersion ();
503d2be0
AS
11539 ;
11540 return 0;
11541}
11542_ACEOF
11543rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11544if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11545 (eval $ac_link) 2>conftest.er1
503d2be0 11546 ac_status=$?
35996d22
AS
11547 grep -v '^ *+' conftest.er1 >conftest.err
11548 rm -f conftest.er1
11549 cat conftest.err >&5
c0d27fcc 11550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11551 (exit $ac_status); } &&
35996d22
AS
11552 { ac_try='test -z "$ac_c_werror_flag"
11553 || test ! -s conftest.err'
11554 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11555 (eval $ac_try) 2>&5
11556 ac_status=$?
11557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11558 (exit $ac_status); }; } &&
11559 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11561 (eval $ac_try) 2>&5
11562 ac_status=$?
c0d27fcc 11563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11564 (exit $ac_status); }; }; then
98418dba 11565 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
11566else
11567 echo "$as_me: failed program was:" >&5
19650fd6
AS
11568sed 's/^/| /' conftest.$ac_ext >&5
11569
98418dba 11570ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0 11571fi
35996d22
AS
11572rm -f conftest.err conftest.$ac_objext \
11573 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
11574LIBS=$ac_check_lib_save_LIBS
11575fi
c0d27fcc 11576echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
11577echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
11578if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
11579 HAVE_TIFF=yes
11580fi
11581
11582fi
73b77ee5 11583
c0d27fcc 11584
98418dba
CW
11585 fi
11586
11587 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 11588
c0d27fcc 11589cat >>confdefs.h <<\_ACEOF
98418dba 11590#define HAVE_TIFF 1
c0d27fcc 11591_ACEOF
98418dba
CW
11592
11593 fi
73b77ee5
GM
11594fi
11595
98418dba
CW
11596### Use -lgif if available, unless `--with-gif=no'.
11597HAVE_GIF=no
11598if test "${HAVE_X11}" = "yes"; then
11599 if test "${with_gif}" != "no"; then
c0d27fcc
MR
11600 if test "${ac_cv_header_gif_lib_h+set}" = set; then
11601 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
11602echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11603if test "${ac_cv_header_gif_lib_h+set}" = set; then
11604 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11605fi
11606echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
11607echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 11608else
c0d27fcc
MR
11609 # Is the header compilable?
11610echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
11611echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
11612cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11613/* confdefs.h. */
11614_ACEOF
11615cat confdefs.h >>conftest.$ac_ext
11616cat >>conftest.$ac_ext <<_ACEOF
11617/* end confdefs.h. */
c0d27fcc
MR
11618$ac_includes_default
11619#include <gif_lib.h>
11620_ACEOF
11621rm -f conftest.$ac_objext
11622if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11623 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11624 ac_status=$?
35996d22
AS
11625 grep -v '^ *+' conftest.er1 >conftest.err
11626 rm -f conftest.er1
11627 cat conftest.err >&5
c0d27fcc
MR
11628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11629 (exit $ac_status); } &&
35996d22
AS
11630 { ac_try='test -z "$ac_c_werror_flag"
11631 || test ! -s conftest.err'
11632 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11633 (eval $ac_try) 2>&5
11634 ac_status=$?
11635 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11636 (exit $ac_status); }; } &&
11637 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11638 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11639 (eval $ac_try) 2>&5
11640 ac_status=$?
11641 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11642 (exit $ac_status); }; }; then
11643 ac_header_compiler=yes
11644else
11645 echo "$as_me: failed program was:" >&5
19650fd6
AS
11646sed 's/^/| /' conftest.$ac_ext >&5
11647
c0d27fcc
MR
11648ac_header_compiler=no
11649fi
35996d22 11650rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11651echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11652echo "${ECHO_T}$ac_header_compiler" >&6
11653
11654# Is the header present?
11655echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
11656echo $ECHO_N "checking gif_lib.h presence... $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. */
98418dba
CW
11663#include <gif_lib.h>
11664_ACEOF
c0d27fcc 11665if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11666 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11667 ac_status=$?
6bae0ccf 11668 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11669 rm -f conftest.er1
11670 cat conftest.err >&5
c0d27fcc 11671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11672 (exit $ac_status); } >/dev/null; then
11673 if test -s conftest.err; then
11674 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11675 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11676 else
11677 ac_cpp_err=
11678 fi
11679else
11680 ac_cpp_err=yes
11681fi
11682if test -z "$ac_cpp_err"; then
c0d27fcc 11683 ac_header_preproc=yes
98418dba
CW
11684else
11685 echo "$as_me: failed program was:" >&5
19650fd6
AS
11686sed 's/^/| /' conftest.$ac_ext >&5
11687
c0d27fcc 11688 ac_header_preproc=no
98418dba
CW
11689fi
11690rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11691echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11692echo "${ECHO_T}$ac_header_preproc" >&6
11693
11694# So? What about this header?
35996d22
AS
11695case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11696 yes:no: )
c0d27fcc
MR
11697 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11698echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11699 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the compiler's result" >&5
11700echo "$as_me: WARNING: gif_lib.h: proceeding with the compiler's result" >&2;}
11701 ac_header_preproc=yes
19650fd6 11702 ;;
35996d22 11703 no:yes:* )
c0d27fcc
MR
11704 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
11705echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
35996d22
AS
11706 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
11707echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
11708 { echo "$as_me:$LINENO: WARNING: gif_lib.h: see the Autoconf documentation" >&5
11709echo "$as_me: WARNING: gif_lib.h: see the Autoconf documentation" >&2;}
11710 { echo "$as_me:$LINENO: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&5
11711echo "$as_me: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11712 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
19650fd6 11713echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11714 { echo "$as_me:$LINENO: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&5
11715echo "$as_me: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11716 (
11717 cat <<\_ASBOX
35996d22
AS
11718## ------------------------------------------ ##
11719## Report this to the AC_PACKAGE_NAME lists. ##
11720## ------------------------------------------ ##
19650fd6
AS
11721_ASBOX
11722 ) |
11723 sed "s/^/$as_me: WARNING: /" >&2
11724 ;;
c0d27fcc
MR
11725esac
11726echo "$as_me:$LINENO: checking for gif_lib.h" >&5
11727echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11728if test "${ac_cv_header_gif_lib_h+set}" = set; then
11729 echo $ECHO_N "(cached) $ECHO_C" >&6
11730else
11731 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 11732fi
c0d27fcc 11733echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 11734echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
11735
11736fi
98418dba
CW
11737if test $ac_cv_header_gif_lib_h = yes; then
11738 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
11739# Earlier versions can crash Emacs.
c0d27fcc 11740 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
11741echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
11742if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 11743 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11744else
503d2be0 11745 ac_check_lib_save_LIBS=$LIBS
98418dba 11746LIBS="-lungif $LIBS"
503d2be0 11747cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11748/* confdefs.h. */
11749_ACEOF
11750cat confdefs.h >>conftest.$ac_ext
11751cat >>conftest.$ac_ext <<_ACEOF
11752/* end confdefs.h. */
73b77ee5 11753
98418dba
CW
11754/* Override any gcc2 internal prototype to avoid an error. */
11755#ifdef __cplusplus
11756extern "C"
11757#endif
11758/* We use char because int might match the return type of a gcc2
11759 builtin and then its argument prototype would still apply. */
11760char EGifPutExtensionLast ();
503d2be0
AS
11761int
11762main ()
11763{
98418dba 11764EGifPutExtensionLast ();
503d2be0
AS
11765 ;
11766 return 0;
11767}
11768_ACEOF
11769rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11770if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11771 (eval $ac_link) 2>conftest.er1
503d2be0 11772 ac_status=$?
35996d22
AS
11773 grep -v '^ *+' conftest.er1 >conftest.err
11774 rm -f conftest.er1
11775 cat conftest.err >&5
c0d27fcc 11776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11777 (exit $ac_status); } &&
35996d22
AS
11778 { ac_try='test -z "$ac_c_werror_flag"
11779 || test ! -s conftest.err'
c0d27fcc 11780 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
11781 (eval $ac_try) 2>&5
11782 ac_status=$?
c0d27fcc 11783 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
11784 (exit $ac_status); }; } &&
11785 { ac_try='test -s conftest$ac_exeext'
11786 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11787 (eval $ac_try) 2>&5
11788 ac_status=$?
11789 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11790 (exit $ac_status); }; }; then
11791 ac_cv_lib_ungif_EGifPutExtensionLast=yes
11792else
98418dba 11793 echo "$as_me: failed program was:" >&5
19650fd6
AS
11794sed 's/^/| /' conftest.$ac_ext >&5
11795
98418dba
CW
11796ac_cv_lib_ungif_EGifPutExtensionLast=no
11797fi
35996d22
AS
11798rm -f conftest.err conftest.$ac_objext \
11799 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
11800LIBS=$ac_check_lib_save_LIBS
11801fi
c0d27fcc 11802echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
11803echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
11804if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
11805 HAVE_GIF=yes
11806fi
11807
11808fi
11809
c0d27fcc 11810
98418dba
CW
11811 fi
11812
11813 if test "${HAVE_GIF}" = "yes"; then
b936fae4 11814
c0d27fcc 11815cat >>confdefs.h <<\_ACEOF
98418dba 11816#define HAVE_GIF 1
c0d27fcc 11817_ACEOF
98418dba
CW
11818
11819 fi
11820fi
11821
c0d27fcc
MR
11822### Use Mac OS X Carbon API to implement GUI.
11823HAVE_CARBON=no
11824if test "${with_carbon}" != "no"; then
11825 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11826 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
11827echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
11828if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11829 echo $ECHO_N "(cached) $ECHO_C" >&6
11830fi
11831echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
11832echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
11833else
11834 # Is the header compilable?
11835echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
11836echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
11837cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11838/* confdefs.h. */
11839_ACEOF
11840cat confdefs.h >>conftest.$ac_ext
11841cat >>conftest.$ac_ext <<_ACEOF
11842/* end confdefs.h. */
c0d27fcc
MR
11843$ac_includes_default
11844#include <Carbon/Carbon.h>
11845_ACEOF
11846rm -f conftest.$ac_objext
11847if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11848 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11849 ac_status=$?
35996d22
AS
11850 grep -v '^ *+' conftest.er1 >conftest.err
11851 rm -f conftest.er1
11852 cat conftest.err >&5
c0d27fcc
MR
11853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11854 (exit $ac_status); } &&
35996d22
AS
11855 { ac_try='test -z "$ac_c_werror_flag"
11856 || test ! -s conftest.err'
11857 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11858 (eval $ac_try) 2>&5
11859 ac_status=$?
11860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11861 (exit $ac_status); }; } &&
11862 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11864 (eval $ac_try) 2>&5
11865 ac_status=$?
11866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11867 (exit $ac_status); }; }; then
11868 ac_header_compiler=yes
11869else
11870 echo "$as_me: failed program was:" >&5
19650fd6
AS
11871sed 's/^/| /' conftest.$ac_ext >&5
11872
c0d27fcc
MR
11873ac_header_compiler=no
11874fi
35996d22 11875rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11876echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11877echo "${ECHO_T}$ac_header_compiler" >&6
11878
11879# Is the header present?
11880echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
11881echo $ECHO_N "checking Carbon/Carbon.h presence... $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. */
e0f712ba
AC
11888#include <Carbon/Carbon.h>
11889_ACEOF
c0d27fcc 11890if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
e0f712ba
AC
11891 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11892 ac_status=$?
6bae0ccf 11893 grep -v '^ *+' conftest.er1 >conftest.err
e0f712ba
AC
11894 rm -f conftest.er1
11895 cat conftest.err >&5
c0d27fcc 11896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
e0f712ba
AC
11897 (exit $ac_status); } >/dev/null; then
11898 if test -s conftest.err; then
11899 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11900 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
e0f712ba
AC
11901 else
11902 ac_cpp_err=
11903 fi
11904else
11905 ac_cpp_err=yes
11906fi
11907if test -z "$ac_cpp_err"; then
c0d27fcc 11908 ac_header_preproc=yes
e0f712ba
AC
11909else
11910 echo "$as_me: failed program was:" >&5
19650fd6
AS
11911sed 's/^/| /' conftest.$ac_ext >&5
11912
c0d27fcc 11913 ac_header_preproc=no
e0f712ba
AC
11914fi
11915rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11916echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11917echo "${ECHO_T}$ac_header_preproc" >&6
11918
11919# So? What about this header?
35996d22
AS
11920case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11921 yes:no: )
c0d27fcc
MR
11922 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
11923echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11924 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&5
11925echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&2;}
11926 ac_header_preproc=yes
19650fd6 11927 ;;
35996d22 11928 no:yes:* )
c0d27fcc
MR
11929 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
11930echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
35996d22
AS
11931 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
11932echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
11933 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&5
11934echo "$as_me: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&2;}
11935 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&5
11936echo "$as_me: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11937 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
19650fd6 11938echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11939 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&5
11940echo "$as_me: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11941 (
11942 cat <<\_ASBOX
35996d22
AS
11943## ------------------------------------------ ##
11944## Report this to the AC_PACKAGE_NAME lists. ##
11945## ------------------------------------------ ##
19650fd6
AS
11946_ASBOX
11947 ) |
11948 sed "s/^/$as_me: WARNING: /" >&2
11949 ;;
c0d27fcc
MR
11950esac
11951echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
11952echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
11953if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11954 echo $ECHO_N "(cached) $ECHO_C" >&6
11955else
11956 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
e0f712ba 11957fi
c0d27fcc 11958echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
e0f712ba 11959echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
c0d27fcc
MR
11960
11961fi
e0f712ba
AC
11962if test $ac_cv_header_Carbon_Carbon_h = yes; then
11963 HAVE_CARBON=yes
11964fi
11965
c0d27fcc 11966
e0f712ba
AC
11967fi
11968
11969if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 11970
c0d27fcc 11971cat >>confdefs.h <<\_ACEOF
e0f712ba 11972#define HAVE_CARBON 1
c0d27fcc 11973_ACEOF
e0f712ba 11974
6a3a24fa
JD
11975 window_system=mac
11976 ## Specify the install directory
11977 carbon_appdir=
11978 if test "${carbon_appdir_x}" != ""; then
11979 case ${carbon_appdir_x} in
11980 y | ye | yes) carbon_appdir=/Applications ;;
11981 * ) carbon_appdir=${carbon_appdir_x} ;;
11982 esac
11983 fi
8f417b3b
AS
11984 # We also have mouse menus.
11985 HAVE_MENUS=yes
e0f712ba
AC
11986fi
11987
98418dba
CW
11988### Use session management (-lSM -lICE) if available
11989HAVE_X_SM=no
11990if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
11991 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
11992 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
11993echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
11994if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
11995 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11996fi
11997echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
11998echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 11999else
c0d27fcc
MR
12000 # Is the header compilable?
12001echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
12002echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
12003cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12004/* confdefs.h. */
12005_ACEOF
12006cat confdefs.h >>conftest.$ac_ext
12007cat >>conftest.$ac_ext <<_ACEOF
12008/* end confdefs.h. */
c0d27fcc
MR
12009$ac_includes_default
12010#include <X11/SM/SMlib.h>
12011_ACEOF
12012rm -f conftest.$ac_objext
12013if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 12014 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12015 ac_status=$?
35996d22
AS
12016 grep -v '^ *+' conftest.er1 >conftest.err
12017 rm -f conftest.er1
12018 cat conftest.err >&5
c0d27fcc
MR
12019 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12020 (exit $ac_status); } &&
35996d22
AS
12021 { ac_try='test -z "$ac_c_werror_flag"
12022 || test ! -s conftest.err'
12023 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12024 (eval $ac_try) 2>&5
12025 ac_status=$?
12026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12027 (exit $ac_status); }; } &&
12028 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12029 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12030 (eval $ac_try) 2>&5
12031 ac_status=$?
12032 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12033 (exit $ac_status); }; }; then
12034 ac_header_compiler=yes
12035else
12036 echo "$as_me: failed program was:" >&5
19650fd6
AS
12037sed 's/^/| /' conftest.$ac_ext >&5
12038
c0d27fcc
MR
12039ac_header_compiler=no
12040fi
35996d22 12041rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12042echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12043echo "${ECHO_T}$ac_header_compiler" >&6
12044
12045# Is the header present?
12046echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
12047echo $ECHO_N "checking X11/SM/SMlib.h presence... $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. */
98418dba
CW
12054#include <X11/SM/SMlib.h>
12055_ACEOF
c0d27fcc 12056if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12057 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12058 ac_status=$?
6bae0ccf 12059 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12060 rm -f conftest.er1
12061 cat conftest.err >&5
c0d27fcc 12062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12063 (exit $ac_status); } >/dev/null; then
12064 if test -s conftest.err; then
12065 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 12066 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12067 else
12068 ac_cpp_err=
12069 fi
12070else
12071 ac_cpp_err=yes
503d2be0 12072fi
98418dba 12073if test -z "$ac_cpp_err"; then
c0d27fcc 12074 ac_header_preproc=yes
98418dba
CW
12075else
12076 echo "$as_me: failed program was:" >&5
19650fd6
AS
12077sed 's/^/| /' conftest.$ac_ext >&5
12078
c0d27fcc 12079 ac_header_preproc=no
98418dba
CW
12080fi
12081rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12082echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12083echo "${ECHO_T}$ac_header_preproc" >&6
12084
12085# So? What about this header?
35996d22
AS
12086case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12087 yes:no: )
c0d27fcc
MR
12088 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12089echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
12090 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&5
12091echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&2;}
12092 ac_header_preproc=yes
19650fd6 12093 ;;
35996d22 12094 no:yes:* )
c0d27fcc
MR
12095 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
12096echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
35996d22
AS
12097 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
12098echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
12099 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&5
12100echo "$as_me: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&2;}
12101 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&5
12102echo "$as_me: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12103 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
19650fd6 12104echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
12105 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&5
12106echo "$as_me: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12107 (
12108 cat <<\_ASBOX
35996d22
AS
12109## ------------------------------------------ ##
12110## Report this to the AC_PACKAGE_NAME lists. ##
12111## ------------------------------------------ ##
19650fd6
AS
12112_ASBOX
12113 ) |
12114 sed "s/^/$as_me: WARNING: /" >&2
12115 ;;
c0d27fcc
MR
12116esac
12117echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
12118echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12119if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12120 echo $ECHO_N "(cached) $ECHO_C" >&6
12121else
12122 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 12123fi
c0d27fcc 12124echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 12125echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
12126
12127fi
98418dba 12128if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 12129 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
12130echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
12131if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 12132 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12133else
503d2be0 12134 ac_check_lib_save_LIBS=$LIBS
1660500f 12135LIBS="-lSM -lICE $LIBS"
503d2be0 12136cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12137/* confdefs.h. */
12138_ACEOF
12139cat confdefs.h >>conftest.$ac_ext
12140cat >>conftest.$ac_ext <<_ACEOF
12141/* end confdefs.h. */
503d2be0 12142
73b77ee5 12143/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12144#ifdef __cplusplus
12145extern "C"
12146#endif
73b77ee5 12147/* We use char because int might match the return type of a gcc2
503d2be0 12148 builtin and then its argument prototype would still apply. */
98418dba 12149char SmcOpenConnection ();
503d2be0
AS
12150int
12151main ()
12152{
98418dba 12153SmcOpenConnection ();
503d2be0
AS
12154 ;
12155 return 0;
12156}
12157_ACEOF
12158rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12159if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12160 (eval $ac_link) 2>conftest.er1
503d2be0 12161 ac_status=$?
35996d22
AS
12162 grep -v '^ *+' conftest.er1 >conftest.err
12163 rm -f conftest.er1
12164 cat conftest.err >&5
c0d27fcc 12165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12166 (exit $ac_status); } &&
35996d22
AS
12167 { ac_try='test -z "$ac_c_werror_flag"
12168 || test ! -s conftest.err'
12169 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12170 (eval $ac_try) 2>&5
12171 ac_status=$?
12172 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12173 (exit $ac_status); }; } &&
12174 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12175 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12176 (eval $ac_try) 2>&5
12177 ac_status=$?
c0d27fcc 12178 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12179 (exit $ac_status); }; }; then
98418dba 12180 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
12181else
12182 echo "$as_me: failed program was:" >&5
19650fd6
AS
12183sed 's/^/| /' conftest.$ac_ext >&5
12184
98418dba 12185ac_cv_lib_SM_SmcOpenConnection=no
503d2be0 12186fi
35996d22
AS
12187rm -f conftest.err conftest.$ac_objext \
12188 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
12189LIBS=$ac_check_lib_save_LIBS
12190fi
c0d27fcc 12191echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
12192echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
12193if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
12194 HAVE_X_SM=yes
73b77ee5
GM
12195fi
12196
73b77ee5 12197fi
73b77ee5 12198
c0d27fcc
MR
12199
12200
98418dba 12201 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 12202
c0d27fcc 12203cat >>confdefs.h <<\_ACEOF
98418dba 12204#define HAVE_X_SM 1
c0d27fcc 12205_ACEOF
73b77ee5 12206
98418dba
CW
12207 case "$LIBS" in
12208 *-lSM*) ;;
12209 *) LIBS="-lSM -lICE $LIBS" ;;
12210 esac
73b77ee5 12211 fi
98418dba 12212fi
73b77ee5 12213
98418dba 12214# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 12215echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
12216echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
12217if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
12218 echo $ECHO_N "(cached) $ECHO_C" >&6
12219else
12220 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12221/* confdefs.h. */
12222_ACEOF
12223cat confdefs.h >>conftest.$ac_ext
12224cat >>conftest.$ac_ext <<_ACEOF
12225/* end confdefs.h. */
98418dba 12226#include <netdb.h>
503d2be0
AS
12227int
12228main ()
12229{
98418dba 12230return h_errno;
503d2be0
AS
12231 ;
12232 return 0;
12233}
12234_ACEOF
12235rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12236if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12237 (eval $ac_link) 2>conftest.er1
503d2be0 12238 ac_status=$?
35996d22
AS
12239 grep -v '^ *+' conftest.er1 >conftest.err
12240 rm -f conftest.er1
12241 cat conftest.err >&5
c0d27fcc 12242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12243 (exit $ac_status); } &&
35996d22
AS
12244 { ac_try='test -z "$ac_c_werror_flag"
12245 || test ! -s conftest.err'
12246 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12247 (eval $ac_try) 2>&5
12248 ac_status=$?
12249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12250 (exit $ac_status); }; } &&
12251 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12253 (eval $ac_try) 2>&5
12254 ac_status=$?
c0d27fcc 12255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12256 (exit $ac_status); }; }; then
98418dba 12257 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 12258else
503d2be0 12259 echo "$as_me: failed program was:" >&5
19650fd6
AS
12260sed 's/^/| /' conftest.$ac_ext >&5
12261
98418dba 12262emacs_cv_netdb_declares_h_errno=no
73b77ee5 12263fi
35996d22
AS
12264rm -f conftest.err conftest.$ac_objext \
12265 conftest$ac_exeext conftest.$ac_ext
98418dba 12266fi
c0d27fcc 12267echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
12268echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
12269if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 12270
c0d27fcc 12271cat >>confdefs.h <<\_ACEOF
98418dba 12272#define HAVE_H_ERRNO 1
c0d27fcc 12273_ACEOF
73b77ee5 12274
98418dba
CW
12275fi
12276
12277# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
12278# for constant arguments. Useless!
c0d27fcc 12279echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
12280echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
12281if test "${ac_cv_working_alloca_h+set}" = set; then
12282 echo $ECHO_N "(cached) $ECHO_C" >&6
12283else
12284 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12285/* confdefs.h. */
12286_ACEOF
12287cat confdefs.h >>conftest.$ac_ext
12288cat >>conftest.$ac_ext <<_ACEOF
12289/* end confdefs.h. */
98418dba 12290#include <alloca.h>
503d2be0
AS
12291int
12292main ()
12293{
98418dba 12294char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
12295 ;
12296 return 0;
12297}
12298_ACEOF
12299rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12300if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12301 (eval $ac_link) 2>conftest.er1
503d2be0 12302 ac_status=$?
35996d22
AS
12303 grep -v '^ *+' conftest.er1 >conftest.err
12304 rm -f conftest.er1
12305 cat conftest.err >&5
c0d27fcc 12306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12307 (exit $ac_status); } &&
35996d22
AS
12308 { ac_try='test -z "$ac_c_werror_flag"
12309 || test ! -s conftest.err'
12310 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12311 (eval $ac_try) 2>&5
12312 ac_status=$?
12313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12314 (exit $ac_status); }; } &&
12315 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12316 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12317 (eval $ac_try) 2>&5
12318 ac_status=$?
c0d27fcc 12319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12320 (exit $ac_status); }; }; then
98418dba 12321 ac_cv_working_alloca_h=yes
73b77ee5 12322else
503d2be0 12323 echo "$as_me: failed program was:" >&5
19650fd6
AS
12324sed 's/^/| /' conftest.$ac_ext >&5
12325
98418dba 12326ac_cv_working_alloca_h=no
73b77ee5 12327fi
35996d22
AS
12328rm -f conftest.err conftest.$ac_objext \
12329 conftest$ac_exeext conftest.$ac_ext
98418dba 12330fi
c0d27fcc 12331echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
12332echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
12333if test $ac_cv_working_alloca_h = yes; then
73b77ee5 12334
c0d27fcc 12335cat >>confdefs.h <<\_ACEOF
98418dba 12336#define HAVE_ALLOCA_H 1
c0d27fcc 12337_ACEOF
98418dba
CW
12338
12339fi
12340
c0d27fcc 12341echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
12342echo $ECHO_N "checking for alloca... $ECHO_C" >&6
12343if test "${ac_cv_func_alloca_works+set}" = set; then
12344 echo $ECHO_N "(cached) $ECHO_C" >&6
12345else
503d2be0 12346 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12347/* confdefs.h. */
12348_ACEOF
12349cat confdefs.h >>conftest.$ac_ext
12350cat >>conftest.$ac_ext <<_ACEOF
12351/* end confdefs.h. */
98418dba
CW
12352#ifdef __GNUC__
12353# define alloca __builtin_alloca
12354#else
12355# ifdef _MSC_VER
12356# include <malloc.h>
12357# define alloca _alloca
12358# else
12359# if HAVE_ALLOCA_H
12360# include <alloca.h>
12361# else
12362# ifdef _AIX
12363 #pragma alloca
12364# else
12365# ifndef alloca /* predefined by HP cc +Olibcalls */
12366char *alloca ();
12367# endif
12368# endif
12369# endif
12370# endif
12371#endif
12372
503d2be0
AS
12373int
12374main ()
12375{
98418dba 12376char *p = (char *) alloca (1);
503d2be0
AS
12377 ;
12378 return 0;
12379}
12380_ACEOF
12381rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12382if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12383 (eval $ac_link) 2>conftest.er1
503d2be0 12384 ac_status=$?
35996d22
AS
12385 grep -v '^ *+' conftest.er1 >conftest.err
12386 rm -f conftest.er1
12387 cat conftest.err >&5
c0d27fcc 12388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12389 (exit $ac_status); } &&
35996d22
AS
12390 { ac_try='test -z "$ac_c_werror_flag"
12391 || test ! -s conftest.err'
12392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12393 (eval $ac_try) 2>&5
12394 ac_status=$?
12395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12396 (exit $ac_status); }; } &&
12397 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12398 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12399 (eval $ac_try) 2>&5
12400 ac_status=$?
c0d27fcc 12401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12402 (exit $ac_status); }; }; then
98418dba 12403 ac_cv_func_alloca_works=yes
ac95a621 12404else
503d2be0 12405 echo "$as_me: failed program was:" >&5
19650fd6
AS
12406sed 's/^/| /' conftest.$ac_ext >&5
12407
98418dba 12408ac_cv_func_alloca_works=no
ac95a621 12409fi
35996d22
AS
12410rm -f conftest.err conftest.$ac_objext \
12411 conftest$ac_exeext conftest.$ac_ext
98418dba 12412fi
c0d27fcc 12413echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 12414echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 12415
98418dba
CW
12416if test $ac_cv_func_alloca_works = yes; then
12417
c0d27fcc 12418cat >>confdefs.h <<\_ACEOF
98418dba 12419#define HAVE_ALLOCA 1
c0d27fcc 12420_ACEOF
98418dba
CW
12421
12422else
12423 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12424# that cause trouble. Some versions do not even contain alloca or
12425# contain a buggy version. If you still want to use their alloca,
12426# use ar to extract alloca.o from them instead of compiling alloca.c.
12427
12428ALLOCA=alloca.$ac_objext
12429
c0d27fcc 12430cat >>confdefs.h <<\_ACEOF
98418dba 12431#define C_ALLOCA 1
c0d27fcc 12432_ACEOF
98418dba 12433
c0d27fcc
MR
12434
12435echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
12436echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
12437if test "${ac_cv_os_cray+set}" = set; then
12438 echo $ECHO_N "(cached) $ECHO_C" >&6
12439else
12440 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12441/* confdefs.h. */
12442_ACEOF
12443cat confdefs.h >>conftest.$ac_ext
12444cat >>conftest.$ac_ext <<_ACEOF
12445/* end confdefs.h. */
98418dba
CW
12446#if defined(CRAY) && ! defined(CRAY2)
12447webecray
12448#else
12449wenotbecray
12450#endif
12451
12452_ACEOF
12453if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 12454 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
12455 ac_cv_os_cray=yes
12456else
12457 ac_cv_os_cray=no
12458fi
12459rm -f conftest*
ac95a621 12460
98418dba 12461fi
c0d27fcc 12462echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
12463echo "${ECHO_T}$ac_cv_os_cray" >&6
12464if test $ac_cv_os_cray = yes; then
12465 for ac_func in _getb67 GETB67 getb67; do
12466 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12467echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12468echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12469if eval "test \"\${$as_ac_var+set}\" = set"; then
12470 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12471else
503d2be0 12472 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12473/* confdefs.h. */
12474_ACEOF
12475cat confdefs.h >>conftest.$ac_ext
12476cat >>conftest.$ac_ext <<_ACEOF
12477/* end confdefs.h. */
35996d22
AS
12478/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12479 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12480#define $ac_func innocuous_$ac_func
12481
73b77ee5 12482/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12483 which can conflict with char $ac_func (); below.
12484 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12485 <limits.h> exists even on freestanding compilers. */
35996d22 12486
19650fd6
AS
12487#ifdef __STDC__
12488# include <limits.h>
12489#else
12490# include <assert.h>
12491#endif
35996d22
AS
12492
12493#undef $ac_func
12494
73b77ee5 12495/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12496#ifdef __cplusplus
12497extern "C"
19650fd6 12498{
503d2be0 12499#endif
73b77ee5 12500/* We use char because int might match the return type of a gcc2
503d2be0
AS
12501 builtin and then its argument prototype would still apply. */
12502char $ac_func ();
73b77ee5
GM
12503/* The GNU C library defines this for functions which it implements
12504 to always fail with ENOSYS. Some functions are actually named
12505 something starting with __ and the normal name is an alias. */
12506#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12507choke me
12508#else
19650fd6
AS
12509char (*f) () = $ac_func;
12510#endif
12511#ifdef __cplusplus
12512}
73b77ee5
GM
12513#endif
12514
19650fd6
AS
12515int
12516main ()
12517{
12518return f != $ac_func;
503d2be0
AS
12519 ;
12520 return 0;
12521}
12522_ACEOF
12523rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12524if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12525 (eval $ac_link) 2>conftest.er1
503d2be0 12526 ac_status=$?
35996d22
AS
12527 grep -v '^ *+' conftest.er1 >conftest.err
12528 rm -f conftest.er1
12529 cat conftest.err >&5
c0d27fcc 12530 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12531 (exit $ac_status); } &&
35996d22
AS
12532 { ac_try='test -z "$ac_c_werror_flag"
12533 || test ! -s conftest.err'
12534 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12535 (eval $ac_try) 2>&5
12536 ac_status=$?
12537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12538 (exit $ac_status); }; } &&
12539 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12541 (eval $ac_try) 2>&5
12542 ac_status=$?
c0d27fcc 12543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12544 (exit $ac_status); }; }; then
12545 eval "$as_ac_var=yes"
12546else
12547 echo "$as_me: failed program was:" >&5
19650fd6
AS
12548sed 's/^/| /' conftest.$ac_ext >&5
12549
503d2be0
AS
12550eval "$as_ac_var=no"
12551fi
35996d22
AS
12552rm -f conftest.err conftest.$ac_objext \
12553 conftest$ac_exeext conftest.$ac_ext
503d2be0 12554fi
c0d27fcc 12555echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12556echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12557if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 12558
c0d27fcc 12559cat >>confdefs.h <<_ACEOF
98418dba 12560#define CRAY_STACKSEG_END $ac_func
c0d27fcc 12561_ACEOF
98418dba
CW
12562
12563 break
73b77ee5 12564fi
73b77ee5 12565
98418dba 12566 done
73b77ee5
GM
12567fi
12568
c0d27fcc 12569echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
12570echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
12571if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 12572 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
12573else
12574 if test "$cross_compiling" = yes; then
12575 ac_cv_c_stack_direction=0
73b77ee5 12576else
503d2be0 12577 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12578/* confdefs.h. */
12579_ACEOF
12580cat confdefs.h >>conftest.$ac_ext
12581cat >>conftest.$ac_ext <<_ACEOF
12582/* end confdefs.h. */
503d2be0 12583int
98418dba 12584find_stack_direction ()
503d2be0 12585{
98418dba
CW
12586 static char *addr = 0;
12587 auto char dummy;
12588 if (addr == 0)
12589 {
12590 addr = &dummy;
12591 return find_stack_direction ();
12592 }
73b77ee5 12593 else
98418dba
CW
12594 return (&dummy > addr) ? 1 : -1;
12595}
ba4481b5 12596
503d2be0
AS
12597int
12598main ()
12599{
98418dba 12600 exit (find_stack_direction () < 0);
503d2be0
AS
12601}
12602_ACEOF
98418dba 12603rm -f conftest$ac_exeext
c0d27fcc 12604if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12605 (eval $ac_link) 2>&5
12606 ac_status=$?
c0d27fcc 12607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12608 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 12609 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12610 (eval $ac_try) 2>&5
12611 ac_status=$?
c0d27fcc 12612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12613 (exit $ac_status); }; }; then
98418dba 12614 ac_cv_c_stack_direction=1
ba4481b5 12615else
98418dba
CW
12616 echo "$as_me: program exited with status $ac_status" >&5
12617echo "$as_me: failed program was:" >&5
19650fd6
AS
12618sed 's/^/| /' conftest.$ac_ext >&5
12619
c0d27fcc 12620( exit $ac_status )
98418dba 12621ac_cv_c_stack_direction=-1
ba4481b5 12622fi
35996d22 12623rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 12624fi
98418dba 12625fi
c0d27fcc 12626echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
12627echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
12628
c0d27fcc 12629cat >>confdefs.h <<_ACEOF
98418dba 12630#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
12631_ACEOF
12632
ba4481b5 12633
ba4481b5
DL
12634fi
12635
c0d27fcc 12636
98418dba
CW
12637# fmod, logb, and frexp are found in -lm on most systems.
12638# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12639
c0d27fcc 12640echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
12641echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
12642if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 12643 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12644else
98418dba
CW
12645 ac_check_lib_save_LIBS=$LIBS
12646LIBS="-lm $LIBS"
12647cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12648/* confdefs.h. */
12649_ACEOF
12650cat confdefs.h >>conftest.$ac_ext
12651cat >>conftest.$ac_ext <<_ACEOF
12652/* end confdefs.h. */
ba4481b5 12653
98418dba
CW
12654/* Override any gcc2 internal prototype to avoid an error. */
12655#ifdef __cplusplus
12656extern "C"
12657#endif
12658/* We use char because int might match the return type of a gcc2
12659 builtin and then its argument prototype would still apply. */
12660char sqrt ();
503d2be0
AS
12661int
12662main ()
12663{
98418dba 12664sqrt ();
503d2be0
AS
12665 ;
12666 return 0;
12667}
12668_ACEOF
12669rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12670if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12671 (eval $ac_link) 2>conftest.er1
503d2be0 12672 ac_status=$?
35996d22
AS
12673 grep -v '^ *+' conftest.er1 >conftest.err
12674 rm -f conftest.er1
12675 cat conftest.err >&5
c0d27fcc 12676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12677 (exit $ac_status); } &&
35996d22
AS
12678 { ac_try='test -z "$ac_c_werror_flag"
12679 || test ! -s conftest.err'
12680 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12681 (eval $ac_try) 2>&5
12682 ac_status=$?
12683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12684 (exit $ac_status); }; } &&
12685 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12687 (eval $ac_try) 2>&5
12688 ac_status=$?
c0d27fcc 12689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12690 (exit $ac_status); }; }; then
98418dba 12691 ac_cv_lib_m_sqrt=yes
ba4481b5 12692else
503d2be0 12693 echo "$as_me: failed program was:" >&5
19650fd6
AS
12694sed 's/^/| /' conftest.$ac_ext >&5
12695
98418dba 12696ac_cv_lib_m_sqrt=no
ba4481b5 12697fi
35996d22
AS
12698rm -f conftest.err conftest.$ac_objext \
12699 conftest$ac_exeext conftest.$ac_ext
98418dba 12700LIBS=$ac_check_lib_save_LIBS
ba4481b5 12701fi
c0d27fcc 12702echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
12703echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
12704if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 12705 cat >>confdefs.h <<_ACEOF
98418dba 12706#define HAVE_LIBM 1
c0d27fcc 12707_ACEOF
98418dba
CW
12708
12709 LIBS="-lm $LIBS"
ba4481b5 12710
ba4481b5
DL
12711fi
12712
c0d27fcc 12713
55597d70
DL
12714# Check for mail-locking functions in a "mail" library. Probably this should
12715# have the same check as for liblockfile below.
98418dba 12716
c0d27fcc 12717echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
12718echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
12719if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 12720 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12721else
98418dba
CW
12722 ac_check_lib_save_LIBS=$LIBS
12723LIBS="-lmail $LIBS"
12724cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12725/* confdefs.h. */
12726_ACEOF
12727cat confdefs.h >>conftest.$ac_ext
12728cat >>conftest.$ac_ext <<_ACEOF
12729/* end confdefs.h. */
98418dba
CW
12730
12731/* Override any gcc2 internal prototype to avoid an error. */
12732#ifdef __cplusplus
12733extern "C"
12734#endif
12735/* We use char because int might match the return type of a gcc2
12736 builtin and then its argument prototype would still apply. */
12737char maillock ();
503d2be0
AS
12738int
12739main ()
12740{
98418dba 12741maillock ();
503d2be0
AS
12742 ;
12743 return 0;
12744}
12745_ACEOF
12746rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12747if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12748 (eval $ac_link) 2>conftest.er1
503d2be0 12749 ac_status=$?
35996d22
AS
12750 grep -v '^ *+' conftest.er1 >conftest.err
12751 rm -f conftest.er1
12752 cat conftest.err >&5
c0d27fcc 12753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12754 (exit $ac_status); } &&
35996d22
AS
12755 { ac_try='test -z "$ac_c_werror_flag"
12756 || test ! -s conftest.err'
12757 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12758 (eval $ac_try) 2>&5
12759 ac_status=$?
12760 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12761 (exit $ac_status); }; } &&
12762 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12763 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12764 (eval $ac_try) 2>&5
12765 ac_status=$?
c0d27fcc 12766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12767 (exit $ac_status); }; }; then
98418dba 12768 ac_cv_lib_mail_maillock=yes
ba4481b5 12769else
503d2be0 12770 echo "$as_me: failed program was:" >&5
19650fd6
AS
12771sed 's/^/| /' conftest.$ac_ext >&5
12772
98418dba 12773ac_cv_lib_mail_maillock=no
ba4481b5 12774fi
35996d22
AS
12775rm -f conftest.err conftest.$ac_objext \
12776 conftest$ac_exeext conftest.$ac_ext
98418dba 12777LIBS=$ac_check_lib_save_LIBS
ba4481b5 12778fi
c0d27fcc 12779echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
12780echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
12781if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 12782 cat >>confdefs.h <<_ACEOF
98418dba 12783#define HAVE_LIBMAIL 1
c0d27fcc 12784_ACEOF
ba4481b5 12785
98418dba 12786 LIBS="-lmail $LIBS"
ba4481b5 12787
98418dba 12788fi
ba4481b5 12789
c0d27fcc
MR
12790
12791echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
12792echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
12793if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 12794 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12795else
503d2be0 12796 ac_check_lib_save_LIBS=$LIBS
98418dba 12797LIBS="-llockfile $LIBS"
503d2be0 12798cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12799/* confdefs.h. */
12800_ACEOF
12801cat confdefs.h >>conftest.$ac_ext
12802cat >>conftest.$ac_ext <<_ACEOF
12803/* end confdefs.h. */
503d2be0 12804
ba4481b5 12805/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12806#ifdef __cplusplus
12807extern "C"
12808#endif
ba4481b5 12809/* We use char because int might match the return type of a gcc2
503d2be0 12810 builtin and then its argument prototype would still apply. */
98418dba 12811char maillock ();
503d2be0
AS
12812int
12813main ()
12814{
98418dba 12815maillock ();
503d2be0
AS
12816 ;
12817 return 0;
12818}
12819_ACEOF
12820rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12821if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12822 (eval $ac_link) 2>conftest.er1
503d2be0 12823 ac_status=$?
35996d22
AS
12824 grep -v '^ *+' conftest.er1 >conftest.err
12825 rm -f conftest.er1
12826 cat conftest.err >&5
c0d27fcc 12827 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12828 (exit $ac_status); } &&
35996d22
AS
12829 { ac_try='test -z "$ac_c_werror_flag"
12830 || test ! -s conftest.err'
12831 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12832 (eval $ac_try) 2>&5
12833 ac_status=$?
12834 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12835 (exit $ac_status); }; } &&
12836 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12837 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12838 (eval $ac_try) 2>&5
12839 ac_status=$?
c0d27fcc 12840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12841 (exit $ac_status); }; }; then
98418dba 12842 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
12843else
12844 echo "$as_me: failed program was:" >&5
19650fd6
AS
12845sed 's/^/| /' conftest.$ac_ext >&5
12846
98418dba
CW
12847ac_cv_lib_lockfile_maillock=no
12848fi
35996d22
AS
12849rm -f conftest.err conftest.$ac_objext \
12850 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12851LIBS=$ac_check_lib_save_LIBS
12852fi
c0d27fcc 12853echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
12854echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
12855if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 12856 cat >>confdefs.h <<_ACEOF
98418dba 12857#define HAVE_LIBLOCKFILE 1
c0d27fcc 12858_ACEOF
98418dba
CW
12859
12860 LIBS="-llockfile $LIBS"
12861
12862fi
12863
12864# If we have the shared liblockfile, assume we must use it for mail
12865# locking (e.g. Debian). If we couldn't link against liblockfile
12866# (no liblockfile.a installed), ensure that we don't need to.
12867if test "$ac_cv_lib_lockfile_maillock" = no; then
12868 # Extract the first word of "liblockfile.so", so it can be a program name with args.
12869set dummy liblockfile.so; ac_word=$2
c0d27fcc 12870echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
12871echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12872if test "${ac_cv_prog_liblockfile+set}" = set; then
12873 echo $ECHO_N "(cached) $ECHO_C" >&6
12874else
12875 if test -n "$liblockfile"; then
12876 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
12877else
c0d27fcc 12878as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
12879as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
12880for as_dir in $as_dummy
c0d27fcc
MR
12881do
12882 IFS=$as_save_IFS
12883 test -z "$as_dir" && as_dir=.
12884 for ac_exec_ext in '' $ac_executable_extensions; do
12885 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12886 ac_cv_prog_liblockfile="yes"
12887 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12888 break 2
12889 fi
12890done
98418dba
CW
12891done
12892
12893 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 12894fi
503d2be0 12895fi
98418dba
CW
12896liblockfile=$ac_cv_prog_liblockfile
12897if test -n "$liblockfile"; then
c0d27fcc 12898 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
12899echo "${ECHO_T}$liblockfile" >&6
12900else
c0d27fcc 12901 echo "$as_me:$LINENO: result: no" >&5
98418dba 12902echo "${ECHO_T}no" >&6
ba4481b5
DL
12903fi
12904
98418dba 12905 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 12906 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
12907This probably means that movemail could lose mail.
12908There may be a \`development' package to install containing liblockfile." >&5
12909echo "$as_me: error: Shared liblockfile found but can't link against it.
12910This probably means that movemail could lose mail.
12911There may be a \`development' package to install containing liblockfile." >&2;}
12912 { (exit 1); exit 1; }; }
98418dba 12913 else :
55597d70 12914 fi
98418dba 12915fi
503d2be0 12916
98418dba
CW
12917for ac_func in touchlock
12918do
12919as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12920echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
12921echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12922if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 12923 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 12924else
98418dba 12925 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12926/* confdefs.h. */
12927_ACEOF
12928cat confdefs.h >>conftest.$ac_ext
12929cat >>conftest.$ac_ext <<_ACEOF
12930/* end confdefs.h. */
35996d22
AS
12931/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12932 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12933#define $ac_func innocuous_$ac_func
12934
98418dba 12935/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12936 which can conflict with char $ac_func (); below.
12937 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12938 <limits.h> exists even on freestanding compilers. */
35996d22 12939
19650fd6
AS
12940#ifdef __STDC__
12941# include <limits.h>
12942#else
12943# include <assert.h>
12944#endif
35996d22
AS
12945
12946#undef $ac_func
12947
457b792c 12948/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12949#ifdef __cplusplus
12950extern "C"
19650fd6 12951{
503d2be0 12952#endif
457b792c 12953/* We use char because int might match the return type of a gcc2
503d2be0 12954 builtin and then its argument prototype would still apply. */
98418dba 12955char $ac_func ();
98418dba
CW
12956/* The GNU C library defines this for functions which it implements
12957 to always fail with ENOSYS. Some functions are actually named
12958 something starting with __ and the normal name is an alias. */
12959#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12960choke me
12961#else
19650fd6
AS
12962char (*f) () = $ac_func;
12963#endif
12964#ifdef __cplusplus
12965}
cd958eb3
MB
12966#endif
12967
19650fd6
AS
12968int
12969main ()
12970{
12971return f != $ac_func;
503d2be0
AS
12972 ;
12973 return 0;
12974}
12975_ACEOF
12976rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12977if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12978 (eval $ac_link) 2>conftest.er1
503d2be0 12979 ac_status=$?
35996d22
AS
12980 grep -v '^ *+' conftest.er1 >conftest.err
12981 rm -f conftest.er1
12982 cat conftest.err >&5
c0d27fcc 12983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12984 (exit $ac_status); } &&
35996d22
AS
12985 { ac_try='test -z "$ac_c_werror_flag"
12986 || test ! -s conftest.err'
12987 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12988 (eval $ac_try) 2>&5
12989 ac_status=$?
12990 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12991 (exit $ac_status); }; } &&
12992 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12993 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12994 (eval $ac_try) 2>&5
12995 ac_status=$?
c0d27fcc 12996 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12997 (exit $ac_status); }; }; then
98418dba 12998 eval "$as_ac_var=yes"
503d2be0
AS
12999else
13000 echo "$as_me: failed program was:" >&5
19650fd6
AS
13001sed 's/^/| /' conftest.$ac_ext >&5
13002
98418dba 13003eval "$as_ac_var=no"
503d2be0 13004fi
35996d22
AS
13005rm -f conftest.err conftest.$ac_objext \
13006 conftest$ac_exeext conftest.$ac_ext
503d2be0 13007fi
c0d27fcc 13008echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13009echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13010if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13011 cat >>confdefs.h <<_ACEOF
98418dba 13012#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13013_ACEOF
457b792c 13014
457b792c 13015fi
98418dba 13016done
457b792c 13017
c0d27fcc 13018
98418dba
CW
13019for ac_header in maillock.h
13020do
13021as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13022if eval "test \"\${$as_ac_Header+set}\" = set"; then
13023 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13024echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13025if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 13026 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13027fi
13028echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13029echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 13030else
c0d27fcc
MR
13031 # Is the header compilable?
13032echo "$as_me:$LINENO: checking $ac_header usability" >&5
13033echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13034cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13035/* confdefs.h. */
13036_ACEOF
13037cat confdefs.h >>conftest.$ac_ext
13038cat >>conftest.$ac_ext <<_ACEOF
13039/* end confdefs.h. */
c0d27fcc
MR
13040$ac_includes_default
13041#include <$ac_header>
13042_ACEOF
13043rm -f conftest.$ac_objext
13044if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13045 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13046 ac_status=$?
35996d22
AS
13047 grep -v '^ *+' conftest.er1 >conftest.err
13048 rm -f conftest.er1
13049 cat conftest.err >&5
c0d27fcc
MR
13050 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13051 (exit $ac_status); } &&
35996d22
AS
13052 { ac_try='test -z "$ac_c_werror_flag"
13053 || test ! -s conftest.err'
13054 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13055 (eval $ac_try) 2>&5
13056 ac_status=$?
13057 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13058 (exit $ac_status); }; } &&
13059 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13060 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13061 (eval $ac_try) 2>&5
13062 ac_status=$?
13063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13064 (exit $ac_status); }; }; then
13065 ac_header_compiler=yes
13066else
13067 echo "$as_me: failed program was:" >&5
19650fd6
AS
13068sed 's/^/| /' conftest.$ac_ext >&5
13069
c0d27fcc
MR
13070ac_header_compiler=no
13071fi
35996d22 13072rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13073echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13074echo "${ECHO_T}$ac_header_compiler" >&6
13075
13076# Is the header present?
13077echo "$as_me:$LINENO: checking $ac_header presence" >&5
13078echo $ECHO_N "checking $ac_header presence... $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. */
98418dba 13085#include <$ac_header>
503d2be0 13086_ACEOF
c0d27fcc 13087if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 13088 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 13089 ac_status=$?
6bae0ccf 13090 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13091 rm -f conftest.er1
13092 cat conftest.err >&5
c0d27fcc 13093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13094 (exit $ac_status); } >/dev/null; then
13095 if test -s conftest.err; then
13096 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13097 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
13098 else
13099 ac_cpp_err=
13100 fi
503d2be0 13101else
98418dba 13102 ac_cpp_err=yes
503d2be0 13103fi
98418dba 13104if test -z "$ac_cpp_err"; then
c0d27fcc 13105 ac_header_preproc=yes
98418dba
CW
13106else
13107 echo "$as_me: failed program was:" >&5
19650fd6
AS
13108sed 's/^/| /' conftest.$ac_ext >&5
13109
c0d27fcc 13110 ac_header_preproc=no
503d2be0 13111fi
98418dba 13112rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13113echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13114echo "${ECHO_T}$ac_header_preproc" >&6
13115
13116# So? What about this header?
35996d22
AS
13117case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13118 yes:no: )
c0d27fcc
MR
13119 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13120echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13121 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13122echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13123 ac_header_preproc=yes
19650fd6 13124 ;;
35996d22 13125 no:yes:* )
c0d27fcc
MR
13126 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13127echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13128 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13129echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13130 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13131echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13132 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13133echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13134 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13135echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13136 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13137echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13138 (
13139 cat <<\_ASBOX
35996d22
AS
13140## ------------------------------------------ ##
13141## Report this to the AC_PACKAGE_NAME lists. ##
13142## ------------------------------------------ ##
19650fd6
AS
13143_ASBOX
13144 ) |
13145 sed "s/^/$as_me: WARNING: /" >&2
13146 ;;
c0d27fcc
MR
13147esac
13148echo "$as_me:$LINENO: checking for $ac_header" >&5
13149echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13150if eval "test \"\${$as_ac_Header+set}\" = set"; then
13151 echo $ECHO_N "(cached) $ECHO_C" >&6
13152else
35996d22 13153 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13154fi
c0d27fcc 13155echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13156echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13157
13158fi
98418dba 13159if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13160 cat >>confdefs.h <<_ACEOF
98418dba 13161#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13162_ACEOF
48d4b120 13163
ba4481b5 13164fi
c0d27fcc 13165
98418dba
CW
13166done
13167
c0d27fcc
MR
13168
13169
13170
13171
13172
13173
13174
13175
13176
13177
13178
13179
13180
13181
13182
13183
13184
13185
13186
13187
13188
13189
13190
13191
13192
13193
13194
13195
13196
13197
13198
13199
13200
13201
13202
13203
13204
13205
13206
13207
13208
13209
13210
13211
13212
13213
13214
13215
13216
13217
13218
13219
13220
13221
13222
22044edf
DL
13223
13224
c0d27fcc 13225
b0e44248
RB
13226
13227
973a76b1
DL
13228
13229
13230
cd958eb3 13231
25ca0bca 13232
28127e47 13233
c0d27fcc
MR
13234
13235
98418dba
CW
13236for ac_func in gethostname getdomainname dup2 \
13237rename closedir mkdir rmdir sysinfo \
13238random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
13239strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
973a76b1 13240utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
98418dba
CW
13241__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
13242sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248 13243gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
28127e47 13244memset memcmp memmove difftime memcpy mempcpy mblen mbrlen posix_memalign
98418dba
CW
13245do
13246as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13247echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13248echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13249if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13250 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13251else
503d2be0 13252 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13253/* confdefs.h. */
13254_ACEOF
13255cat confdefs.h >>conftest.$ac_ext
13256cat >>conftest.$ac_ext <<_ACEOF
13257/* end confdefs.h. */
35996d22
AS
13258/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13259 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13260#define $ac_func innocuous_$ac_func
13261
98418dba 13262/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13263 which can conflict with char $ac_func (); below.
13264 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13265 <limits.h> exists even on freestanding compilers. */
35996d22 13266
19650fd6
AS
13267#ifdef __STDC__
13268# include <limits.h>
13269#else
13270# include <assert.h>
13271#endif
35996d22
AS
13272
13273#undef $ac_func
13274
ba4481b5 13275/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13276#ifdef __cplusplus
13277extern "C"
19650fd6 13278{
503d2be0 13279#endif
ba4481b5 13280/* We use char because int might match the return type of a gcc2
503d2be0 13281 builtin and then its argument prototype would still apply. */
98418dba 13282char $ac_func ();
98418dba
CW
13283/* The GNU C library defines this for functions which it implements
13284 to always fail with ENOSYS. Some functions are actually named
13285 something starting with __ and the normal name is an alias. */
13286#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13287choke me
13288#else
19650fd6
AS
13289char (*f) () = $ac_func;
13290#endif
13291#ifdef __cplusplus
13292}
98418dba
CW
13293#endif
13294
19650fd6
AS
13295int
13296main ()
13297{
13298return f != $ac_func;
503d2be0
AS
13299 ;
13300 return 0;
13301}
13302_ACEOF
13303rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13304if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13305 (eval $ac_link) 2>conftest.er1
503d2be0 13306 ac_status=$?
35996d22
AS
13307 grep -v '^ *+' conftest.er1 >conftest.err
13308 rm -f conftest.er1
13309 cat conftest.err >&5
c0d27fcc 13310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13311 (exit $ac_status); } &&
35996d22
AS
13312 { ac_try='test -z "$ac_c_werror_flag"
13313 || test ! -s conftest.err'
13314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13315 (eval $ac_try) 2>&5
13316 ac_status=$?
13317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13318 (exit $ac_status); }; } &&
13319 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13321 (eval $ac_try) 2>&5
13322 ac_status=$?
c0d27fcc 13323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13324 (exit $ac_status); }; }; then
98418dba 13325 eval "$as_ac_var=yes"
503d2be0
AS
13326else
13327 echo "$as_me: failed program was:" >&5
19650fd6
AS
13328sed 's/^/| /' conftest.$ac_ext >&5
13329
98418dba 13330eval "$as_ac_var=no"
503d2be0 13331fi
35996d22
AS
13332rm -f conftest.err conftest.$ac_objext \
13333 conftest$ac_exeext conftest.$ac_ext
ba4481b5 13334fi
c0d27fcc 13335echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13336echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13337if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13338 cat >>confdefs.h <<_ACEOF
98418dba 13339#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13340_ACEOF
ba4481b5 13341
ba4481b5 13342fi
98418dba 13343done
ba4481b5 13344
c0d27fcc
MR
13345
13346
98418dba
CW
13347for ac_header in sys/un.h
13348do
13349as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13350if eval "test \"\${$as_ac_Header+set}\" = set"; then
13351 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13352echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13353if eval "test \"\${$as_ac_Header+set}\" = set"; then
13354 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13355fi
13356echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13357echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13358else
c0d27fcc
MR
13359 # Is the header compilable?
13360echo "$as_me:$LINENO: checking $ac_header usability" >&5
13361echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13362cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13363/* confdefs.h. */
13364_ACEOF
13365cat confdefs.h >>conftest.$ac_ext
13366cat >>conftest.$ac_ext <<_ACEOF
13367/* end confdefs.h. */
c0d27fcc
MR
13368$ac_includes_default
13369#include <$ac_header>
13370_ACEOF
13371rm -f conftest.$ac_objext
13372if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13373 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13374 ac_status=$?
35996d22
AS
13375 grep -v '^ *+' conftest.er1 >conftest.err
13376 rm -f conftest.er1
13377 cat conftest.err >&5
c0d27fcc
MR
13378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13379 (exit $ac_status); } &&
35996d22
AS
13380 { ac_try='test -z "$ac_c_werror_flag"
13381 || test ! -s conftest.err'
13382 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13383 (eval $ac_try) 2>&5
13384 ac_status=$?
13385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13386 (exit $ac_status); }; } &&
13387 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13388 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13389 (eval $ac_try) 2>&5
13390 ac_status=$?
13391 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13392 (exit $ac_status); }; }; then
13393 ac_header_compiler=yes
13394else
13395 echo "$as_me: failed program was:" >&5
19650fd6
AS
13396sed 's/^/| /' conftest.$ac_ext >&5
13397
c0d27fcc
MR
13398ac_header_compiler=no
13399fi
35996d22 13400rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13401echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13402echo "${ECHO_T}$ac_header_compiler" >&6
13403
13404# Is the header present?
13405echo "$as_me:$LINENO: checking $ac_header presence" >&5
13406echo $ECHO_N "checking $ac_header presence... $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. */
98418dba 13413#include <$ac_header>
503d2be0 13414_ACEOF
c0d27fcc 13415if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13416 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13417 ac_status=$?
6bae0ccf 13418 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13419 rm -f conftest.er1
13420 cat conftest.err >&5
c0d27fcc 13421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13422 (exit $ac_status); } >/dev/null; then
13423 if test -s conftest.err; then
13424 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13425 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13426 else
13427 ac_cpp_err=
13428 fi
13429else
13430 ac_cpp_err=yes
13431fi
13432if test -z "$ac_cpp_err"; then
c0d27fcc 13433 ac_header_preproc=yes
ba4481b5 13434else
503d2be0 13435 echo "$as_me: failed program was:" >&5
19650fd6
AS
13436sed 's/^/| /' conftest.$ac_ext >&5
13437
c0d27fcc 13438 ac_header_preproc=no
ba4481b5 13439fi
503d2be0 13440rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13441echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13442echo "${ECHO_T}$ac_header_preproc" >&6
13443
13444# So? What about this header?
35996d22
AS
13445case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13446 yes:no: )
c0d27fcc
MR
13447 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13448echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13449 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13450echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13451 ac_header_preproc=yes
19650fd6 13452 ;;
35996d22 13453 no:yes:* )
c0d27fcc
MR
13454 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13455echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13456 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13457echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13458 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13459echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13460 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13461echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13462 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13463echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13464 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13465echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13466 (
13467 cat <<\_ASBOX
35996d22
AS
13468## ------------------------------------------ ##
13469## Report this to the AC_PACKAGE_NAME lists. ##
13470## ------------------------------------------ ##
19650fd6
AS
13471_ASBOX
13472 ) |
13473 sed "s/^/$as_me: WARNING: /" >&2
13474 ;;
c0d27fcc
MR
13475esac
13476echo "$as_me:$LINENO: checking for $ac_header" >&5
13477echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13478if eval "test \"\${$as_ac_Header+set}\" = set"; then
13479 echo $ECHO_N "(cached) $ECHO_C" >&6
13480else
35996d22 13481 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13482fi
c0d27fcc 13483echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 13484echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13485
13486fi
925c2f3f 13487if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13488 cat >>confdefs.h <<_ACEOF
925c2f3f 13489#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13490_ACEOF
503d2be0 13491
925c2f3f 13492fi
c0d27fcc 13493
925c2f3f
EZ
13494done
13495
c0d27fcc
MR
13496
13497
13498
35996d22
AS
13499
13500for ac_header in stdlib.h sys/time.h unistd.h
925c2f3f
EZ
13501do
13502as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13503if eval "test \"\${$as_ac_Header+set}\" = set"; then
13504 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
13505echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13506if eval "test \"\${$as_ac_Header+set}\" = set"; then
13507 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13508fi
13509echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13510echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 13511else
c0d27fcc
MR
13512 # Is the header compilable?
13513echo "$as_me:$LINENO: checking $ac_header usability" >&5
13514echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13515cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13516/* confdefs.h. */
13517_ACEOF
13518cat confdefs.h >>conftest.$ac_ext
13519cat >>conftest.$ac_ext <<_ACEOF
13520/* end confdefs.h. */
c0d27fcc
MR
13521$ac_includes_default
13522#include <$ac_header>
13523_ACEOF
13524rm -f conftest.$ac_objext
13525if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13526 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13527 ac_status=$?
35996d22
AS
13528 grep -v '^ *+' conftest.er1 >conftest.err
13529 rm -f conftest.er1
13530 cat conftest.err >&5
c0d27fcc
MR
13531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13532 (exit $ac_status); } &&
35996d22
AS
13533 { ac_try='test -z "$ac_c_werror_flag"
13534 || test ! -s conftest.err'
13535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13536 (eval $ac_try) 2>&5
13537 ac_status=$?
13538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13539 (exit $ac_status); }; } &&
13540 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13542 (eval $ac_try) 2>&5
13543 ac_status=$?
13544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13545 (exit $ac_status); }; }; then
13546 ac_header_compiler=yes
13547else
13548 echo "$as_me: failed program was:" >&5
19650fd6
AS
13549sed 's/^/| /' conftest.$ac_ext >&5
13550
c0d27fcc
MR
13551ac_header_compiler=no
13552fi
35996d22 13553rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13554echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13555echo "${ECHO_T}$ac_header_compiler" >&6
13556
13557# Is the header present?
13558echo "$as_me:$LINENO: checking $ac_header presence" >&5
13559echo $ECHO_N "checking $ac_header presence... $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. */
98418dba 13566#include <$ac_header>
503d2be0 13567_ACEOF
c0d27fcc 13568if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13569 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13570 ac_status=$?
6bae0ccf 13571 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13572 rm -f conftest.er1
13573 cat conftest.err >&5
c0d27fcc 13574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13575 (exit $ac_status); } >/dev/null; then
13576 if test -s conftest.err; then
13577 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13578 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13579 else
13580 ac_cpp_err=
13581 fi
13582else
13583 ac_cpp_err=yes
13584fi
13585if test -z "$ac_cpp_err"; then
c0d27fcc 13586 ac_header_preproc=yes
98418dba
CW
13587else
13588 echo "$as_me: failed program was:" >&5
19650fd6
AS
13589sed 's/^/| /' conftest.$ac_ext >&5
13590
c0d27fcc 13591 ac_header_preproc=no
98418dba
CW
13592fi
13593rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13594echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13595echo "${ECHO_T}$ac_header_preproc" >&6
13596
13597# So? What about this header?
35996d22
AS
13598case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13599 yes:no: )
c0d27fcc
MR
13600 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13601echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13602 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13603echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13604 ac_header_preproc=yes
19650fd6 13605 ;;
35996d22 13606 no:yes:* )
c0d27fcc
MR
13607 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13608echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13609 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13610echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13611 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13612echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13613 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13614echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13615 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13616echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13617 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13618echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13619 (
13620 cat <<\_ASBOX
35996d22
AS
13621## ------------------------------------------ ##
13622## Report this to the AC_PACKAGE_NAME lists. ##
13623## ------------------------------------------ ##
19650fd6
AS
13624_ASBOX
13625 ) |
13626 sed "s/^/$as_me: WARNING: /" >&2
13627 ;;
c0d27fcc
MR
13628esac
13629echo "$as_me:$LINENO: checking for $ac_header" >&5
13630echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13631if eval "test \"\${$as_ac_Header+set}\" = set"; then
13632 echo $ECHO_N "(cached) $ECHO_C" >&6
13633else
35996d22 13634 eval "$as_ac_Header=\$ac_header_preproc"
ffe36136 13635fi
c0d27fcc 13636echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13637echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13638
13639fi
98418dba 13640if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13641 cat >>confdefs.h <<_ACEOF
98418dba 13642#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13643_ACEOF
98418dba
CW
13644
13645fi
c0d27fcc 13646
98418dba
CW
13647done
13648
c0d27fcc 13649
98418dba
CW
13650for ac_func in alarm
13651do
13652as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13653echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13654echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13655if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13656 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13657else
98418dba 13658 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13659/* confdefs.h. */
13660_ACEOF
13661cat confdefs.h >>conftest.$ac_ext
13662cat >>conftest.$ac_ext <<_ACEOF
13663/* end confdefs.h. */
35996d22
AS
13664/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13665 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13666#define $ac_func innocuous_$ac_func
13667
98418dba 13668/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13669 which can conflict with char $ac_func (); below.
13670 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13671 <limits.h> exists even on freestanding compilers. */
35996d22 13672
19650fd6
AS
13673#ifdef __STDC__
13674# include <limits.h>
13675#else
13676# include <assert.h>
13677#endif
35996d22
AS
13678
13679#undef $ac_func
13680
ba4481b5 13681/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13682#ifdef __cplusplus
13683extern "C"
19650fd6 13684{
503d2be0 13685#endif
ba4481b5 13686/* We use char because int might match the return type of a gcc2
503d2be0 13687 builtin and then its argument prototype would still apply. */
98418dba 13688char $ac_func ();
98418dba
CW
13689/* The GNU C library defines this for functions which it implements
13690 to always fail with ENOSYS. Some functions are actually named
13691 something starting with __ and the normal name is an alias. */
13692#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13693choke me
13694#else
19650fd6
AS
13695char (*f) () = $ac_func;
13696#endif
13697#ifdef __cplusplus
13698}
98418dba
CW
13699#endif
13700
19650fd6
AS
13701int
13702main ()
13703{
13704return f != $ac_func;
503d2be0
AS
13705 ;
13706 return 0;
13707}
13708_ACEOF
13709rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13710if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13711 (eval $ac_link) 2>conftest.er1
503d2be0 13712 ac_status=$?
35996d22
AS
13713 grep -v '^ *+' conftest.er1 >conftest.err
13714 rm -f conftest.er1
13715 cat conftest.err >&5
c0d27fcc 13716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13717 (exit $ac_status); } &&
35996d22
AS
13718 { ac_try='test -z "$ac_c_werror_flag"
13719 || test ! -s conftest.err'
13720 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13721 (eval $ac_try) 2>&5
13722 ac_status=$?
13723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13724 (exit $ac_status); }; } &&
13725 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13726 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13727 (eval $ac_try) 2>&5
13728 ac_status=$?
c0d27fcc 13729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13730 (exit $ac_status); }; }; then
98418dba 13731 eval "$as_ac_var=yes"
503d2be0
AS
13732else
13733 echo "$as_me: failed program was:" >&5
19650fd6
AS
13734sed 's/^/| /' conftest.$ac_ext >&5
13735
98418dba 13736eval "$as_ac_var=no"
503d2be0 13737fi
35996d22
AS
13738rm -f conftest.err conftest.$ac_objext \
13739 conftest$ac_exeext conftest.$ac_ext
ffe36136 13740fi
c0d27fcc 13741echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13742echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13743if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13744 cat >>confdefs.h <<_ACEOF
98418dba 13745#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13746_ACEOF
ffe36136 13747
ba4481b5 13748fi
98418dba 13749done
ba4481b5 13750
c0d27fcc 13751echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
13752echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
13753if test "${ac_cv_func_working_mktime+set}" = set; then
13754 echo $ECHO_N "(cached) $ECHO_C" >&6
13755else
13756 if test "$cross_compiling" = yes; then
13757 ac_cv_func_working_mktime=no
13758else
13759 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13760/* confdefs.h. */
13761_ACEOF
13762cat confdefs.h >>conftest.$ac_ext
13763cat >>conftest.$ac_ext <<_ACEOF
13764/* end confdefs.h. */
98418dba
CW
13765/* Test program from Paul Eggert and Tony Leneis. */
13766#if TIME_WITH_SYS_TIME
13767# include <sys/time.h>
13768# include <time.h>
13769#else
13770# if HAVE_SYS_TIME_H
13771# include <sys/time.h>
13772# else
13773# include <time.h>
13774# endif
13775#endif
ba4481b5 13776
35996d22
AS
13777#if HAVE_STDLIB_H
13778# include <stdlib.h>
13779#endif
13780
98418dba
CW
13781#if HAVE_UNISTD_H
13782# include <unistd.h>
13783#endif
ba4481b5 13784
98418dba
CW
13785#if !HAVE_ALARM
13786# define alarm(X) /* empty */
13787#endif
df645f7c 13788
98418dba
CW
13789/* Work around redefinition to rpl_putenv by other config tests. */
13790#undef putenv
df645f7c 13791
98418dba 13792static time_t time_t_max;
35996d22 13793static time_t time_t_min;
df645f7c 13794
98418dba 13795/* Values we'll use to set the TZ environment variable. */
35996d22
AS
13796static char *tz_strings[] = {
13797 (char *) 0, "TZ=GMT0", "TZ=JST-9",
98418dba
CW
13798 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
13799};
13800#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 13801
98418dba
CW
13802/* Fail if mktime fails to convert a date in the spring-forward gap.
13803 Based on a problem report from Andreas Jaeger. */
13804static void
13805spring_forward_gap ()
13806{
13807 /* glibc (up to about 1998-10-07) failed this test. */
13808 struct tm tm;
13809
13810 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
13811 instead of "TZ=America/Vancouver" in order to detect the bug even
13812 on systems that don't support the Olson extension, or don't have the
13813 full zoneinfo tables installed. */
13814 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
13815
13816 tm.tm_year = 98;
13817 tm.tm_mon = 3;
13818 tm.tm_mday = 5;
13819 tm.tm_hour = 2;
13820 tm.tm_min = 0;
13821 tm.tm_sec = 0;
13822 tm.tm_isdst = -1;
13823 if (mktime (&tm) == (time_t)-1)
13824 exit (1);
13825}
13826
13827static void
35996d22 13828mktime_test1 (now)
98418dba
CW
13829 time_t now;
13830{
13831 struct tm *lt;
13832 if ((lt = localtime (&now)) && mktime (lt) != now)
13833 exit (1);
35996d22
AS
13834}
13835
13836static void
13837mktime_test (now)
13838 time_t now;
13839{
13840 mktime_test1 (now);
13841 mktime_test1 ((time_t) (time_t_max - now));
13842 mktime_test1 ((time_t) (time_t_min + now));
98418dba
CW
13843}
13844
13845static void
13846irix_6_4_bug ()
13847{
13848 /* Based on code from Ariel Faigon. */
13849 struct tm tm;
13850 tm.tm_year = 96;
13851 tm.tm_mon = 3;
13852 tm.tm_mday = 0;
13853 tm.tm_hour = 0;
13854 tm.tm_min = 0;
13855 tm.tm_sec = 0;
13856 tm.tm_isdst = -1;
13857 mktime (&tm);
13858 if (tm.tm_mon != 2 || tm.tm_mday != 31)
13859 exit (1);
13860}
13861
13862static void
13863bigtime_test (j)
13864 int j;
13865{
13866 struct tm tm;
13867 time_t now;
13868 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
13869 now = mktime (&tm);
13870 if (now != (time_t) -1)
13871 {
13872 struct tm *lt = localtime (&now);
13873 if (! (lt
13874 && lt->tm_year == tm.tm_year
13875 && lt->tm_mon == tm.tm_mon
13876 && lt->tm_mday == tm.tm_mday
13877 && lt->tm_hour == tm.tm_hour
13878 && lt->tm_min == tm.tm_min
13879 && lt->tm_sec == tm.tm_sec
13880 && lt->tm_yday == tm.tm_yday
13881 && lt->tm_wday == tm.tm_wday
13882 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
13883 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
13884 exit (1);
13885 }
13886}
13887
13888int
13889main ()
13890{
13891 time_t t, delta;
13892 int i, j;
13893
13894 /* This test makes some buggy mktime implementations loop.
13895 Give up after 60 seconds; a mktime slower than that
13896 isn't worth using anyway. */
13897 alarm (60);
13898
13899 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
13900 continue;
13901 time_t_max--;
35996d22
AS
13902 if ((time_t) -1 < 0)
13903 for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
13904 continue;
98418dba
CW
13905 delta = time_t_max / 997; /* a suitable prime number */
13906 for (i = 0; i < N_STRINGS; i++)
13907 {
13908 if (tz_strings[i])
13909 putenv (tz_strings[i]);
503d2be0 13910
98418dba
CW
13911 for (t = 0; t <= time_t_max - delta; t += delta)
13912 mktime_test (t);
35996d22
AS
13913 mktime_test ((time_t) 1);
13914 mktime_test ((time_t) (60 * 60));
13915 mktime_test ((time_t) (60 * 60 * 24));
98418dba
CW
13916
13917 for (j = 1; 0 < j; j *= 2)
35996d22 13918 bigtime_test (j);
98418dba
CW
13919 bigtime_test (j - 1);
13920 }
13921 irix_6_4_bug ();
13922 spring_forward_gap ();
13923 exit (0);
503d2be0
AS
13924}
13925_ACEOF
98418dba 13926rm -f conftest$ac_exeext
c0d27fcc 13927if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13928 (eval $ac_link) 2>&5
13929 ac_status=$?
c0d27fcc 13930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 13931 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 13932 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13933 (eval $ac_try) 2>&5
13934 ac_status=$?
c0d27fcc 13935 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13936 (exit $ac_status); }; }; then
98418dba 13937 ac_cv_func_working_mktime=yes
503d2be0 13938else
98418dba
CW
13939 echo "$as_me: program exited with status $ac_status" >&5
13940echo "$as_me: failed program was:" >&5
19650fd6
AS
13941sed 's/^/| /' conftest.$ac_ext >&5
13942
c0d27fcc 13943( exit $ac_status )
98418dba 13944ac_cv_func_working_mktime=no
503d2be0 13945fi
35996d22 13946rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 13947fi
ba4481b5 13948fi
c0d27fcc 13949echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
13950echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
13951if test $ac_cv_func_working_mktime = no; then
35996d22
AS
13952 case $LIBOBJS in
13953 "mktime.$ac_objext" | \
13954 *" mktime.$ac_objext" | \
13955 "mktime.$ac_objext "* | \
13956 *" mktime.$ac_objext "* ) ;;
13957 *) LIBOBJS="$LIBOBJS mktime.$ac_objext" ;;
13958esac
13959
ba4481b5
DL
13960fi
13961
98418dba 13962if test "$ac_cv_func_working_mktime" = no; then
b936fae4 13963
c0d27fcc 13964cat >>confdefs.h <<\_ACEOF
98418dba 13965#define BROKEN_MKTIME 1
c0d27fcc 13966_ACEOF
ba4481b5 13967
ba4481b5 13968fi
503d2be0 13969
98418dba
CW
13970ac_have_func=no # yes means we've found a way to get the load average.
13971
6bae0ccf
DL
13972# Make sure getloadavg.c is where it belongs, at configure-time.
13973test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
13974 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
13975echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
13976 { (exit 1); exit 1; }; }
13977
98418dba
CW
13978ac_save_LIBS=$LIBS
13979
13980# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 13981(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
13982echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
13983if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 13984 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13985else
503d2be0 13986 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13987/* confdefs.h. */
13988_ACEOF
13989cat confdefs.h >>conftest.$ac_ext
13990cat >>conftest.$ac_ext <<_ACEOF
13991/* end confdefs.h. */
35996d22
AS
13992/* Define getloadavg to an innocuous variant, in case <limits.h> declares getloadavg.
13993 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13994#define getloadavg innocuous_getloadavg
13995
98418dba 13996/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13997 which can conflict with char getloadavg (); below.
13998 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13999 <limits.h> exists even on freestanding compilers. */
35996d22 14000
19650fd6
AS
14001#ifdef __STDC__
14002# include <limits.h>
14003#else
14004# include <assert.h>
14005#endif
35996d22
AS
14006
14007#undef getloadavg
14008
ba4481b5 14009/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14010#ifdef __cplusplus
14011extern "C"
19650fd6 14012{
503d2be0 14013#endif
ba4481b5 14014/* We use char because int might match the return type of a gcc2
503d2be0 14015 builtin and then its argument prototype would still apply. */
98418dba 14016char getloadavg ();
98418dba
CW
14017/* The GNU C library defines this for functions which it implements
14018 to always fail with ENOSYS. Some functions are actually named
14019 something starting with __ and the normal name is an alias. */
14020#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
14021choke me
14022#else
19650fd6
AS
14023char (*f) () = getloadavg;
14024#endif
14025#ifdef __cplusplus
14026}
cd958eb3
MB
14027#endif
14028
19650fd6
AS
14029int
14030main ()
14031{
14032return f != getloadavg;
503d2be0
AS
14033 ;
14034 return 0;
14035}
14036_ACEOF
14037rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14038if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14039 (eval $ac_link) 2>conftest.er1
503d2be0 14040 ac_status=$?
35996d22
AS
14041 grep -v '^ *+' conftest.er1 >conftest.err
14042 rm -f conftest.er1
14043 cat conftest.err >&5
c0d27fcc 14044 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14045 (exit $ac_status); } &&
35996d22
AS
14046 { ac_try='test -z "$ac_c_werror_flag"
14047 || test ! -s conftest.err'
14048 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14049 (eval $ac_try) 2>&5
14050 ac_status=$?
14051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14052 (exit $ac_status); }; } &&
14053 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14054 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14055 (eval $ac_try) 2>&5
14056 ac_status=$?
c0d27fcc 14057 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14058 (exit $ac_status); }; }; then
98418dba 14059 ac_cv_func_getloadavg=yes
503d2be0
AS
14060else
14061 echo "$as_me: failed program was:" >&5
19650fd6
AS
14062sed 's/^/| /' conftest.$ac_ext >&5
14063
98418dba 14064ac_cv_func_getloadavg=no
503d2be0 14065fi
35996d22
AS
14066rm -f conftest.err conftest.$ac_objext \
14067 conftest$ac_exeext conftest.$ac_ext
ba4481b5 14068fi
c0d27fcc 14069echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
14070echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
14071if test $ac_cv_func_getloadavg = yes; then
14072 exit 0
14073else
14074 exit 1
ba4481b5 14075fi
98418dba 14076) && ac_have_func=yes
ba4481b5 14077
98418dba 14078# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 14079
98418dba
CW
14080for ac_func in pstat_getdynamic
14081do
14082as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14083echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14084echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14085if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14086 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14087else
503d2be0 14088 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14089/* confdefs.h. */
14090_ACEOF
14091cat confdefs.h >>conftest.$ac_ext
14092cat >>conftest.$ac_ext <<_ACEOF
14093/* end confdefs.h. */
35996d22
AS
14094/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14095 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14096#define $ac_func innocuous_$ac_func
14097
98418dba 14098/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14099 which can conflict with char $ac_func (); below.
14100 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14101 <limits.h> exists even on freestanding compilers. */
35996d22 14102
19650fd6
AS
14103#ifdef __STDC__
14104# include <limits.h>
14105#else
14106# include <assert.h>
14107#endif
35996d22
AS
14108
14109#undef $ac_func
14110
ba4481b5 14111/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14112#ifdef __cplusplus
14113extern "C"
19650fd6 14114{
503d2be0 14115#endif
ba4481b5 14116/* We use char because int might match the return type of a gcc2
503d2be0 14117 builtin and then its argument prototype would still apply. */
98418dba 14118char $ac_func ();
98418dba
CW
14119/* The GNU C library defines this for functions which it implements
14120 to always fail with ENOSYS. Some functions are actually named
14121 something starting with __ and the normal name is an alias. */
14122#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14123choke me
14124#else
19650fd6
AS
14125char (*f) () = $ac_func;
14126#endif
14127#ifdef __cplusplus
14128}
98418dba
CW
14129#endif
14130
19650fd6
AS
14131int
14132main ()
14133{
14134return f != $ac_func;
98418dba
CW
14135 ;
14136 return 0;
14137}
f21fadcc 14138_ACEOF
98418dba 14139rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14140if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14141 (eval $ac_link) 2>conftest.er1
f21fadcc 14142 ac_status=$?
35996d22
AS
14143 grep -v '^ *+' conftest.er1 >conftest.err
14144 rm -f conftest.er1
14145 cat conftest.err >&5
c0d27fcc 14146 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14147 (exit $ac_status); } &&
35996d22
AS
14148 { ac_try='test -z "$ac_c_werror_flag"
14149 || test ! -s conftest.err'
14150 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14151 (eval $ac_try) 2>&5
14152 ac_status=$?
14153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14154 (exit $ac_status); }; } &&
14155 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14156 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14157 (eval $ac_try) 2>&5
14158 ac_status=$?
c0d27fcc 14159 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14160 (exit $ac_status); }; }; then
14161 eval "$as_ac_var=yes"
f21fadcc
JD
14162else
14163 echo "$as_me: failed program was:" >&5
19650fd6
AS
14164sed 's/^/| /' conftest.$ac_ext >&5
14165
98418dba 14166eval "$as_ac_var=no"
f21fadcc 14167fi
35996d22
AS
14168rm -f conftest.err conftest.$ac_objext \
14169 conftest$ac_exeext conftest.$ac_ext
f21fadcc 14170fi
c0d27fcc 14171echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
14172echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14173if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14174 cat >>confdefs.h <<_ACEOF
98418dba 14175#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14176_ACEOF
98418dba
CW
14177
14178fi
14179done
14180
c0d27fcc 14181
98418dba
CW
14182# Solaris has libkstat which does not require root.
14183
c0d27fcc 14184echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
14185echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
14186if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
14187 echo $ECHO_N "(cached) $ECHO_C" >&6
14188else
14189 ac_check_lib_save_LIBS=$LIBS
98418dba 14190LIBS="-lkstat $LIBS"
f21fadcc 14191cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14192/* confdefs.h. */
14193_ACEOF
14194cat confdefs.h >>conftest.$ac_ext
14195cat >>conftest.$ac_ext <<_ACEOF
14196/* end confdefs.h. */
f21fadcc
JD
14197
14198/* Override any gcc2 internal prototype to avoid an error. */
14199#ifdef __cplusplus
14200extern "C"
14201#endif
14202/* We use char because int might match the return type of a gcc2
14203 builtin and then its argument prototype would still apply. */
98418dba 14204char kstat_open ();
f21fadcc
JD
14205int
14206main ()
14207{
98418dba 14208kstat_open ();
f21fadcc
JD
14209 ;
14210 return 0;
14211}
14212_ACEOF
14213rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14214if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14215 (eval $ac_link) 2>conftest.er1
f21fadcc 14216 ac_status=$?
35996d22
AS
14217 grep -v '^ *+' conftest.er1 >conftest.err
14218 rm -f conftest.er1
14219 cat conftest.err >&5
c0d27fcc 14220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14221 (exit $ac_status); } &&
35996d22
AS
14222 { ac_try='test -z "$ac_c_werror_flag"
14223 || test ! -s conftest.err'
14224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14225 (eval $ac_try) 2>&5
14226 ac_status=$?
14227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14228 (exit $ac_status); }; } &&
14229 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14230 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
14231 (eval $ac_try) 2>&5
14232 ac_status=$?
c0d27fcc 14233 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14234 (exit $ac_status); }; }; then
98418dba 14235 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
14236else
14237 echo "$as_me: failed program was:" >&5
19650fd6
AS
14238sed 's/^/| /' conftest.$ac_ext >&5
14239
98418dba 14240ac_cv_lib_kstat_kstat_open=no
f21fadcc 14241fi
35996d22
AS
14242rm -f conftest.err conftest.$ac_objext \
14243 conftest$ac_exeext conftest.$ac_ext
f21fadcc
JD
14244LIBS=$ac_check_lib_save_LIBS
14245fi
c0d27fcc 14246echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
14247echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
14248if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 14249 cat >>confdefs.h <<_ACEOF
98418dba 14250#define HAVE_LIBKSTAT 1
c0d27fcc 14251_ACEOF
f21fadcc 14252
98418dba 14253 LIBS="-lkstat $LIBS"
f21fadcc 14254
f21fadcc
JD
14255fi
14256
98418dba
CW
14257test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
14258
14259# Some systems with -lutil have (and need) -lkvm as well, some do not.
14260# On Solaris, -lkvm requires nlist from -lelf, so check that first
14261# to get the right answer into the cache.
14262# For kstat on solaris, we need libelf to force the definition of SVR4 below.
14263if test $ac_have_func = no; then
c0d27fcc 14264 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
14265echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
14266if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 14267 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14268else
98418dba
CW
14269 ac_check_lib_save_LIBS=$LIBS
14270LIBS="-lelf $LIBS"
14271cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14272/* confdefs.h. */
14273_ACEOF
14274cat confdefs.h >>conftest.$ac_ext
14275cat >>conftest.$ac_ext <<_ACEOF
14276/* end confdefs.h. */
98418dba
CW
14277
14278/* Override any gcc2 internal prototype to avoid an error. */
14279#ifdef __cplusplus
14280extern "C"
14281#endif
14282/* We use char because int might match the return type of a gcc2
14283 builtin and then its argument prototype would still apply. */
14284char elf_begin ();
503d2be0
AS
14285int
14286main ()
14287{
98418dba 14288elf_begin ();
503d2be0
AS
14289 ;
14290 return 0;
14291}
14292_ACEOF
14293rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14294if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14295 (eval $ac_link) 2>conftest.er1
503d2be0 14296 ac_status=$?
35996d22
AS
14297 grep -v '^ *+' conftest.er1 >conftest.err
14298 rm -f conftest.er1
14299 cat conftest.err >&5
c0d27fcc 14300 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14301 (exit $ac_status); } &&
35996d22
AS
14302 { ac_try='test -z "$ac_c_werror_flag"
14303 || test ! -s conftest.err'
14304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14305 (eval $ac_try) 2>&5
14306 ac_status=$?
14307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14308 (exit $ac_status); }; } &&
14309 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14310 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14311 (eval $ac_try) 2>&5
14312 ac_status=$?
c0d27fcc 14313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14314 (exit $ac_status); }; }; then
98418dba 14315 ac_cv_lib_elf_elf_begin=yes
ba4481b5 14316else
503d2be0 14317 echo "$as_me: failed program was:" >&5
19650fd6
AS
14318sed 's/^/| /' conftest.$ac_ext >&5
14319
98418dba 14320ac_cv_lib_elf_elf_begin=no
ba4481b5 14321fi
35996d22
AS
14322rm -f conftest.err conftest.$ac_objext \
14323 conftest$ac_exeext conftest.$ac_ext
98418dba 14324LIBS=$ac_check_lib_save_LIBS
ba4481b5 14325fi
c0d27fcc 14326echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
14327echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
14328if test $ac_cv_lib_elf_elf_begin = yes; then
14329 LIBS="-lelf $LIBS"
ba4481b5
DL
14330fi
14331
98418dba
CW
14332fi
14333if test $ac_have_func = no; then
c0d27fcc 14334 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
14335echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
14336if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 14337 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14338else
98418dba
CW
14339 ac_check_lib_save_LIBS=$LIBS
14340LIBS="-lkvm $LIBS"
14341cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14342/* confdefs.h. */
14343_ACEOF
14344cat confdefs.h >>conftest.$ac_ext
14345cat >>conftest.$ac_ext <<_ACEOF
14346/* end confdefs.h. */
98418dba
CW
14347
14348/* Override any gcc2 internal prototype to avoid an error. */
14349#ifdef __cplusplus
14350extern "C"
14351#endif
14352/* We use char because int might match the return type of a gcc2
14353 builtin and then its argument prototype would still apply. */
14354char kvm_open ();
503d2be0
AS
14355int
14356main ()
14357{
98418dba 14358kvm_open ();
503d2be0
AS
14359 ;
14360 return 0;
14361}
14362_ACEOF
14363rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14364if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14365 (eval $ac_link) 2>conftest.er1
503d2be0 14366 ac_status=$?
35996d22
AS
14367 grep -v '^ *+' conftest.er1 >conftest.err
14368 rm -f conftest.er1
14369 cat conftest.err >&5
c0d27fcc 14370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14371 (exit $ac_status); } &&
35996d22
AS
14372 { ac_try='test -z "$ac_c_werror_flag"
14373 || test ! -s conftest.err'
14374 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14375 (eval $ac_try) 2>&5
14376 ac_status=$?
14377 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14378 (exit $ac_status); }; } &&
14379 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14381 (eval $ac_try) 2>&5
14382 ac_status=$?
c0d27fcc 14383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14384 (exit $ac_status); }; }; then
98418dba 14385 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
14386else
14387 echo "$as_me: failed program was:" >&5
19650fd6
AS
14388sed 's/^/| /' conftest.$ac_ext >&5
14389
98418dba 14390ac_cv_lib_kvm_kvm_open=no
503d2be0 14391fi
35996d22
AS
14392rm -f conftest.err conftest.$ac_objext \
14393 conftest$ac_exeext conftest.$ac_ext
98418dba 14394LIBS=$ac_check_lib_save_LIBS
503d2be0 14395fi
c0d27fcc 14396echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
14397echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
14398if test $ac_cv_lib_kvm_kvm_open = yes; then
14399 LIBS="-lkvm $LIBS"
ba4481b5
DL
14400fi
14401
98418dba 14402 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 14403 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
14404echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
14405if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 14406 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14407else
98418dba
CW
14408 ac_check_lib_save_LIBS=$LIBS
14409LIBS="-lutil $LIBS"
14410cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14411/* confdefs.h. */
14412_ACEOF
14413cat confdefs.h >>conftest.$ac_ext
14414cat >>conftest.$ac_ext <<_ACEOF
14415/* end confdefs.h. */
98418dba
CW
14416
14417/* Override any gcc2 internal prototype to avoid an error. */
14418#ifdef __cplusplus
14419extern "C"
14420#endif
14421/* We use char because int might match the return type of a gcc2
14422 builtin and then its argument prototype would still apply. */
14423char getloadavg ();
503d2be0
AS
14424int
14425main ()
14426{
98418dba 14427getloadavg ();
503d2be0
AS
14428 ;
14429 return 0;
14430}
14431_ACEOF
14432rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14433if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14434 (eval $ac_link) 2>conftest.er1
503d2be0 14435 ac_status=$?
35996d22
AS
14436 grep -v '^ *+' conftest.er1 >conftest.err
14437 rm -f conftest.er1
14438 cat conftest.err >&5
c0d27fcc 14439 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14440 (exit $ac_status); } &&
35996d22
AS
14441 { ac_try='test -z "$ac_c_werror_flag"
14442 || test ! -s conftest.err'
c0d27fcc 14443 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14444 (eval $ac_try) 2>&5
14445 ac_status=$?
c0d27fcc 14446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
14447 (exit $ac_status); }; } &&
14448 { ac_try='test -s conftest$ac_exeext'
14449 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14450 (eval $ac_try) 2>&5
14451 ac_status=$?
14452 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14453 (exit $ac_status); }; }; then
14454 ac_cv_lib_util_getloadavg=yes
14455else
503d2be0 14456 echo "$as_me: failed program was:" >&5
19650fd6
AS
14457sed 's/^/| /' conftest.$ac_ext >&5
14458
98418dba 14459ac_cv_lib_util_getloadavg=no
ba4481b5 14460fi
35996d22
AS
14461rm -f conftest.err conftest.$ac_objext \
14462 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14463LIBS=$ac_check_lib_save_LIBS
14464fi
c0d27fcc 14465echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
14466echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
14467if test $ac_cv_lib_util_getloadavg = yes; then
14468 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 14469fi
503d2be0 14470
98418dba 14471fi
ba4481b5 14472
98418dba
CW
14473if test $ac_have_func = no; then
14474 # There is a commonly available library for RS/6000 AIX.
14475 # Since it is not a standard part of AIX, it might be installed locally.
14476 ac_getloadavg_LIBS=$LIBS
14477 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 14478 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
14479echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
14480if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 14481 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14482else
98418dba
CW
14483 ac_check_lib_save_LIBS=$LIBS
14484LIBS="-lgetloadavg $LIBS"
14485cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14486/* confdefs.h. */
14487_ACEOF
14488cat confdefs.h >>conftest.$ac_ext
14489cat >>conftest.$ac_ext <<_ACEOF
14490/* end confdefs.h. */
ba4481b5 14491
98418dba
CW
14492/* Override any gcc2 internal prototype to avoid an error. */
14493#ifdef __cplusplus
14494extern "C"
14495#endif
14496/* We use char because int might match the return type of a gcc2
14497 builtin and then its argument prototype would still apply. */
14498char getloadavg ();
98418dba
CW
14499int
14500main ()
14501{
14502getloadavg ();
14503 ;
14504 return 0;
14505}
503d2be0 14506_ACEOF
98418dba 14507rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14508if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14509 (eval $ac_link) 2>conftest.er1
98418dba 14510 ac_status=$?
35996d22
AS
14511 grep -v '^ *+' conftest.er1 >conftest.err
14512 rm -f conftest.er1
14513 cat conftest.err >&5
c0d27fcc 14514 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14515 (exit $ac_status); } &&
35996d22
AS
14516 { ac_try='test -z "$ac_c_werror_flag"
14517 || test ! -s conftest.err'
14518 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14519 (eval $ac_try) 2>&5
14520 ac_status=$?
14521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14522 (exit $ac_status); }; } &&
14523 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14524 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14525 (eval $ac_try) 2>&5
14526 ac_status=$?
c0d27fcc 14527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14528 (exit $ac_status); }; }; then
14529 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 14530else
98418dba 14531 echo "$as_me: failed program was:" >&5
19650fd6
AS
14532sed 's/^/| /' conftest.$ac_ext >&5
14533
98418dba
CW
14534ac_cv_lib_getloadavg_getloadavg=no
14535fi
35996d22
AS
14536rm -f conftest.err conftest.$ac_objext \
14537 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14538LIBS=$ac_check_lib_save_LIBS
14539fi
c0d27fcc 14540echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
14541echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
14542if test $ac_cv_lib_getloadavg_getloadavg = yes; then
14543 LIBS="-lgetloadavg $LIBS"
14544else
14545 LIBS=$ac_getloadavg_LIBS
ba4481b5 14546fi
ba4481b5
DL
14547
14548fi
98418dba
CW
14549
14550# Make sure it is really in the library, if we think we found it,
14551# otherwise set up the replacement function.
14552
14553for ac_func in getloadavg
14554do
14555as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14556echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
14557echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14558if eval "test \"\${$as_ac_var+set}\" = set"; then
14559 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14560else
503d2be0 14561 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14562/* confdefs.h. */
14563_ACEOF
14564cat confdefs.h >>conftest.$ac_ext
14565cat >>conftest.$ac_ext <<_ACEOF
14566/* end confdefs.h. */
35996d22
AS
14567/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14568 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14569#define $ac_func innocuous_$ac_func
14570
ba4481b5 14571/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14572 which can conflict with char $ac_func (); below.
14573 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14574 <limits.h> exists even on freestanding compilers. */
35996d22 14575
19650fd6
AS
14576#ifdef __STDC__
14577# include <limits.h>
14578#else
14579# include <assert.h>
14580#endif
35996d22
AS
14581
14582#undef $ac_func
14583
ba4481b5 14584/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14585#ifdef __cplusplus
14586extern "C"
19650fd6 14587{
503d2be0 14588#endif
ba4481b5 14589/* We use char because int might match the return type of a gcc2
503d2be0
AS
14590 builtin and then its argument prototype would still apply. */
14591char $ac_func ();
ba4481b5
DL
14592/* The GNU C library defines this for functions which it implements
14593 to always fail with ENOSYS. Some functions are actually named
14594 something starting with __ and the normal name is an alias. */
14595#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14596choke me
14597#else
19650fd6
AS
14598char (*f) () = $ac_func;
14599#endif
14600#ifdef __cplusplus
14601}
cd958eb3
MB
14602#endif
14603
19650fd6
AS
14604int
14605main ()
14606{
14607return f != $ac_func;
503d2be0
AS
14608 ;
14609 return 0;
14610}
14611_ACEOF
14612rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14613if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14614 (eval $ac_link) 2>conftest.er1
503d2be0 14615 ac_status=$?
35996d22
AS
14616 grep -v '^ *+' conftest.er1 >conftest.err
14617 rm -f conftest.er1
14618 cat conftest.err >&5
c0d27fcc 14619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14620 (exit $ac_status); } &&
35996d22
AS
14621 { ac_try='test -z "$ac_c_werror_flag"
14622 || test ! -s conftest.err'
14623 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14624 (eval $ac_try) 2>&5
14625 ac_status=$?
14626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14627 (exit $ac_status); }; } &&
14628 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14630 (eval $ac_try) 2>&5
14631 ac_status=$?
c0d27fcc 14632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14633 (exit $ac_status); }; }; then
14634 eval "$as_ac_var=yes"
14635else
14636 echo "$as_me: failed program was:" >&5
19650fd6
AS
14637sed 's/^/| /' conftest.$ac_ext >&5
14638
503d2be0
AS
14639eval "$as_ac_var=no"
14640fi
35996d22
AS
14641rm -f conftest.err conftest.$ac_objext \
14642 conftest$ac_exeext conftest.$ac_ext
503d2be0 14643fi
c0d27fcc 14644echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14645echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14646if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14647 cat >>confdefs.h <<_ACEOF
98418dba 14648#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14649_ACEOF
503d2be0 14650
98418dba 14651else
35996d22
AS
14652 case $LIBOBJS in
14653 "getloadavg.$ac_objext" | \
14654 *" getloadavg.$ac_objext" | \
14655 "getloadavg.$ac_objext "* | \
14656 *" getloadavg.$ac_objext "* ) ;;
14657 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext" ;;
14658esac
14659
ba4481b5 14660
c0d27fcc 14661cat >>confdefs.h <<\_ACEOF
98418dba 14662#define C_GETLOADAVG 1
c0d27fcc 14663_ACEOF
ba4481b5 14664
98418dba
CW
14665# Figure out what our getloadavg.c needs.
14666ac_have_func=no
c0d27fcc
MR
14667if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14668 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
14669echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14670if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 14671 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14672fi
14673echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
14674echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 14675else
c0d27fcc
MR
14676 # Is the header compilable?
14677echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
14678echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
14679cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14680/* confdefs.h. */
14681_ACEOF
14682cat confdefs.h >>conftest.$ac_ext
14683cat >>conftest.$ac_ext <<_ACEOF
14684/* end confdefs.h. */
c0d27fcc
MR
14685$ac_includes_default
14686#include <sys/dg_sys_info.h>
14687_ACEOF
14688rm -f conftest.$ac_objext
14689if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 14690 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14691 ac_status=$?
35996d22
AS
14692 grep -v '^ *+' conftest.er1 >conftest.err
14693 rm -f conftest.er1
14694 cat conftest.err >&5
c0d27fcc
MR
14695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14696 (exit $ac_status); } &&
35996d22
AS
14697 { ac_try='test -z "$ac_c_werror_flag"
14698 || test ! -s conftest.err'
14699 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14700 (eval $ac_try) 2>&5
14701 ac_status=$?
14702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14703 (exit $ac_status); }; } &&
14704 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14705 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14706 (eval $ac_try) 2>&5
14707 ac_status=$?
14708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14709 (exit $ac_status); }; }; then
14710 ac_header_compiler=yes
14711else
14712 echo "$as_me: failed program was:" >&5
19650fd6
AS
14713sed 's/^/| /' conftest.$ac_ext >&5
14714
c0d27fcc
MR
14715ac_header_compiler=no
14716fi
35996d22 14717rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14718echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14719echo "${ECHO_T}$ac_header_compiler" >&6
14720
14721# Is the header present?
14722echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
14723echo $ECHO_N "checking sys/dg_sys_info.h presence... $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. */
98418dba
CW
14730#include <sys/dg_sys_info.h>
14731_ACEOF
c0d27fcc 14732if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
14733 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14734 ac_status=$?
6bae0ccf 14735 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14736 rm -f conftest.er1
14737 cat conftest.err >&5
c0d27fcc 14738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14739 (exit $ac_status); } >/dev/null; then
14740 if test -s conftest.err; then
14741 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 14742 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
14743 else
14744 ac_cpp_err=
14745 fi
14746else
14747 ac_cpp_err=yes
ba4481b5 14748fi
98418dba 14749if test -z "$ac_cpp_err"; then
c0d27fcc 14750 ac_header_preproc=yes
98418dba
CW
14751else
14752 echo "$as_me: failed program was:" >&5
19650fd6
AS
14753sed 's/^/| /' conftest.$ac_ext >&5
14754
c0d27fcc 14755 ac_header_preproc=no
ba4481b5 14756fi
98418dba 14757rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14758echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14759echo "${ECHO_T}$ac_header_preproc" >&6
14760
14761# So? What about this header?
35996d22
AS
14762case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14763 yes:no: )
c0d27fcc
MR
14764 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
14765echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
14766 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&5
14767echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&2;}
14768 ac_header_preproc=yes
19650fd6 14769 ;;
35996d22 14770 no:yes:* )
c0d27fcc
MR
14771 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
14772echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
35996d22
AS
14773 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
14774echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
14775 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&5
14776echo "$as_me: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&2;}
14777 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&5
14778echo "$as_me: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 14779 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
19650fd6 14780echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
14781 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&5
14782echo "$as_me: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
14783 (
14784 cat <<\_ASBOX
35996d22
AS
14785## ------------------------------------------ ##
14786## Report this to the AC_PACKAGE_NAME lists. ##
14787## ------------------------------------------ ##
19650fd6
AS
14788_ASBOX
14789 ) |
14790 sed "s/^/$as_me: WARNING: /" >&2
14791 ;;
c0d27fcc
MR
14792esac
14793echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
14794echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14795if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14796 echo $ECHO_N "(cached) $ECHO_C" >&6
14797else
14798 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 14799fi
c0d27fcc 14800echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 14801echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
14802
14803fi
98418dba
CW
14804if test $ac_cv_header_sys_dg_sys_info_h = yes; then
14805 ac_have_func=yes
ba4481b5 14806
c0d27fcc 14807cat >>confdefs.h <<\_ACEOF
98418dba 14808#define DGUX 1
c0d27fcc
MR
14809_ACEOF
14810
503d2be0 14811
c0d27fcc 14812echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
14813echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
14814if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 14815 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14816else
503d2be0 14817 ac_check_lib_save_LIBS=$LIBS
98418dba 14818LIBS="-ldgc $LIBS"
503d2be0 14819cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14820/* confdefs.h. */
14821_ACEOF
14822cat confdefs.h >>conftest.$ac_ext
14823cat >>conftest.$ac_ext <<_ACEOF
14824/* end confdefs.h. */
503d2be0 14825
ba4481b5 14826/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14827#ifdef __cplusplus
14828extern "C"
14829#endif
ba4481b5 14830/* We use char because int might match the return type of a gcc2
503d2be0 14831 builtin and then its argument prototype would still apply. */
98418dba 14832char dg_sys_info ();
503d2be0
AS
14833int
14834main ()
14835{
98418dba 14836dg_sys_info ();
503d2be0
AS
14837 ;
14838 return 0;
14839}
14840_ACEOF
14841rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14842if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14843 (eval $ac_link) 2>conftest.er1
503d2be0 14844 ac_status=$?
35996d22
AS
14845 grep -v '^ *+' conftest.er1 >conftest.err
14846 rm -f conftest.er1
14847 cat conftest.err >&5
c0d27fcc 14848 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14849 (exit $ac_status); } &&
35996d22
AS
14850 { ac_try='test -z "$ac_c_werror_flag"
14851 || test ! -s conftest.err'
14852 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14853 (eval $ac_try) 2>&5
14854 ac_status=$?
14855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14856 (exit $ac_status); }; } &&
14857 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14858 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14859 (eval $ac_try) 2>&5
14860 ac_status=$?
c0d27fcc 14861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14862 (exit $ac_status); }; }; then
98418dba 14863 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
14864else
14865 echo "$as_me: failed program was:" >&5
19650fd6
AS
14866sed 's/^/| /' conftest.$ac_ext >&5
14867
98418dba 14868ac_cv_lib_dgc_dg_sys_info=no
503d2be0 14869fi
35996d22
AS
14870rm -f conftest.err conftest.$ac_objext \
14871 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
14872LIBS=$ac_check_lib_save_LIBS
14873fi
c0d27fcc 14874echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
14875echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
14876if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 14877 cat >>confdefs.h <<_ACEOF
98418dba 14878#define HAVE_LIBDGC 1
c0d27fcc 14879_ACEOF
ba4481b5 14880
98418dba 14881 LIBS="-ldgc $LIBS"
ba4481b5 14882
ba4481b5
DL
14883fi
14884
98418dba 14885fi
503d2be0 14886
c0d27fcc
MR
14887
14888
14889if test "${ac_cv_header_locale_h+set}" = set; then
14890 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
14891echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
14892if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 14893 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14894fi
14895echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
14896echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 14897else
c0d27fcc
MR
14898 # Is the header compilable?
14899echo "$as_me:$LINENO: checking locale.h usability" >&5
14900echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
14901cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14902/* confdefs.h. */
14903_ACEOF
14904cat confdefs.h >>conftest.$ac_ext
14905cat >>conftest.$ac_ext <<_ACEOF
14906/* end confdefs.h. */
c0d27fcc
MR
14907$ac_includes_default
14908#include <locale.h>
14909_ACEOF
14910rm -f conftest.$ac_objext
14911if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 14912 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14913 ac_status=$?
35996d22
AS
14914 grep -v '^ *+' conftest.er1 >conftest.err
14915 rm -f conftest.er1
14916 cat conftest.err >&5
c0d27fcc
MR
14917 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14918 (exit $ac_status); } &&
35996d22
AS
14919 { ac_try='test -z "$ac_c_werror_flag"
14920 || test ! -s conftest.err'
14921 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14922 (eval $ac_try) 2>&5
14923 ac_status=$?
14924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14925 (exit $ac_status); }; } &&
14926 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14927 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14928 (eval $ac_try) 2>&5
14929 ac_status=$?
14930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14931 (exit $ac_status); }; }; then
14932 ac_header_compiler=yes
14933else
14934 echo "$as_me: failed program was:" >&5
19650fd6
AS
14935sed 's/^/| /' conftest.$ac_ext >&5
14936
c0d27fcc
MR
14937ac_header_compiler=no
14938fi
35996d22 14939rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14940echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14941echo "${ECHO_T}$ac_header_compiler" >&6
14942
14943# Is the header present?
14944echo "$as_me:$LINENO: checking locale.h presence" >&5
14945echo $ECHO_N "checking locale.h presence... $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. */
98418dba 14952#include <locale.h>
503d2be0 14953_ACEOF
c0d27fcc 14954if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 14955 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 14956 ac_status=$?
6bae0ccf 14957 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14958 rm -f conftest.er1
14959 cat conftest.err >&5
c0d27fcc 14960 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14961 (exit $ac_status); } >/dev/null; then
14962 if test -s conftest.err; then
14963 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 14964 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
14965 else
14966 ac_cpp_err=
14967 fi
503d2be0 14968else
98418dba 14969 ac_cpp_err=yes
503d2be0 14970fi
98418dba 14971if test -z "$ac_cpp_err"; then
c0d27fcc 14972 ac_header_preproc=yes
98418dba
CW
14973else
14974 echo "$as_me: failed program was:" >&5
19650fd6
AS
14975sed 's/^/| /' conftest.$ac_ext >&5
14976
c0d27fcc 14977 ac_header_preproc=no
ba4481b5 14978fi
98418dba 14979rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14980echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14981echo "${ECHO_T}$ac_header_preproc" >&6
14982
14983# So? What about this header?
35996d22
AS
14984case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14985 yes:no: )
c0d27fcc
MR
14986 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
14987echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
14988 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the compiler's result" >&5
14989echo "$as_me: WARNING: locale.h: proceeding with the compiler's result" >&2;}
14990 ac_header_preproc=yes
19650fd6 14991 ;;
35996d22 14992 no:yes:* )
c0d27fcc
MR
14993 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
14994echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
35996d22
AS
14995 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
14996echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
14997 { echo "$as_me:$LINENO: WARNING: locale.h: see the Autoconf documentation" >&5
14998echo "$as_me: WARNING: locale.h: see the Autoconf documentation" >&2;}
14999 { echo "$as_me:$LINENO: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&5
15000echo "$as_me: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15001 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
19650fd6 15002echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15003 { echo "$as_me:$LINENO: WARNING: locale.h: in the future, the compiler will take precedence" >&5
15004echo "$as_me: WARNING: locale.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15005 (
15006 cat <<\_ASBOX
35996d22
AS
15007## ------------------------------------------ ##
15008## Report this to the AC_PACKAGE_NAME lists. ##
15009## ------------------------------------------ ##
19650fd6
AS
15010_ASBOX
15011 ) |
15012 sed "s/^/$as_me: WARNING: /" >&2
15013 ;;
c0d27fcc
MR
15014esac
15015echo "$as_me:$LINENO: checking for locale.h" >&5
15016echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15017if test "${ac_cv_header_locale_h+set}" = set; then
15018 echo $ECHO_N "(cached) $ECHO_C" >&6
15019else
15020 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 15021fi
c0d27fcc 15022echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
15023echo "${ECHO_T}$ac_cv_header_locale_h" >&6
15024
c0d27fcc
MR
15025fi
15026
15027
15028
98418dba 15029for ac_func in setlocale
ba4481b5 15030do
503d2be0 15031as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15032echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15033echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15034if eval "test \"\${$as_ac_var+set}\" = set"; then
15035 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15036else
503d2be0 15037 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15038/* confdefs.h. */
15039_ACEOF
15040cat confdefs.h >>conftest.$ac_ext
15041cat >>conftest.$ac_ext <<_ACEOF
15042/* end confdefs.h. */
35996d22
AS
15043/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15044 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15045#define $ac_func innocuous_$ac_func
15046
ba4481b5 15047/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15048 which can conflict with char $ac_func (); below.
15049 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15050 <limits.h> exists even on freestanding compilers. */
35996d22 15051
19650fd6
AS
15052#ifdef __STDC__
15053# include <limits.h>
15054#else
15055# include <assert.h>
15056#endif
35996d22
AS
15057
15058#undef $ac_func
15059
ba4481b5 15060/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15061#ifdef __cplusplus
15062extern "C"
19650fd6 15063{
503d2be0 15064#endif
ba4481b5 15065/* We use char because int might match the return type of a gcc2
503d2be0
AS
15066 builtin and then its argument prototype would still apply. */
15067char $ac_func ();
ba4481b5
DL
15068/* The GNU C library defines this for functions which it implements
15069 to always fail with ENOSYS. Some functions are actually named
15070 something starting with __ and the normal name is an alias. */
15071#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15072choke me
15073#else
19650fd6
AS
15074char (*f) () = $ac_func;
15075#endif
15076#ifdef __cplusplus
15077}
ba4481b5
DL
15078#endif
15079
19650fd6
AS
15080int
15081main ()
15082{
15083return f != $ac_func;
503d2be0
AS
15084 ;
15085 return 0;
15086}
15087_ACEOF
15088rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15089if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 15090 (eval $ac_link) 2>conftest.er1
503d2be0 15091 ac_status=$?
35996d22
AS
15092 grep -v '^ *+' conftest.er1 >conftest.err
15093 rm -f conftest.er1
15094 cat conftest.err >&5
c0d27fcc 15095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15096 (exit $ac_status); } &&
35996d22
AS
15097 { ac_try='test -z "$ac_c_werror_flag"
15098 || test ! -s conftest.err'
15099 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15100 (eval $ac_try) 2>&5
15101 ac_status=$?
15102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15103 (exit $ac_status); }; } &&
15104 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15105 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15106 (eval $ac_try) 2>&5
15107 ac_status=$?
c0d27fcc 15108 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15109 (exit $ac_status); }; }; then
15110 eval "$as_ac_var=yes"
15111else
15112 echo "$as_me: failed program was:" >&5
19650fd6
AS
15113sed 's/^/| /' conftest.$ac_ext >&5
15114
503d2be0
AS
15115eval "$as_ac_var=no"
15116fi
35996d22
AS
15117rm -f conftest.err conftest.$ac_objext \
15118 conftest$ac_exeext conftest.$ac_ext
503d2be0 15119fi
c0d27fcc 15120echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15121echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15122if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15123 cat >>confdefs.h <<_ACEOF
503d2be0 15124#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15125_ACEOF
ba4481b5 15126
ba4481b5
DL
15127fi
15128done
15129
c0d27fcc 15130
98418dba
CW
15131# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
15132# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
15133# Irix 4.0.5F has the header but not the library.
15134if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
15135 ac_have_func=yes
15136
c0d27fcc 15137cat >>confdefs.h <<\_ACEOF
98418dba 15138#define SVR4 1
c0d27fcc 15139_ACEOF
98418dba
CW
15140
15141fi
15142
15143if test $ac_have_func = no; then
c0d27fcc
MR
15144 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15145 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
15146echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15147if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 15148 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15149fi
15150echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
15151echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 15152else
c0d27fcc
MR
15153 # Is the header compilable?
15154echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
15155echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
15156cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15157/* confdefs.h. */
15158_ACEOF
15159cat confdefs.h >>conftest.$ac_ext
15160cat >>conftest.$ac_ext <<_ACEOF
15161/* end confdefs.h. */
c0d27fcc
MR
15162$ac_includes_default
15163#include <inq_stats/cpustats.h>
15164_ACEOF
15165rm -f conftest.$ac_objext
15166if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15167 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15168 ac_status=$?
35996d22
AS
15169 grep -v '^ *+' conftest.er1 >conftest.err
15170 rm -f conftest.er1
15171 cat conftest.err >&5
c0d27fcc
MR
15172 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15173 (exit $ac_status); } &&
35996d22
AS
15174 { ac_try='test -z "$ac_c_werror_flag"
15175 || test ! -s conftest.err'
15176 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15177 (eval $ac_try) 2>&5
15178 ac_status=$?
15179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15180 (exit $ac_status); }; } &&
15181 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15182 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15183 (eval $ac_try) 2>&5
15184 ac_status=$?
15185 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15186 (exit $ac_status); }; }; then
15187 ac_header_compiler=yes
15188else
15189 echo "$as_me: failed program was:" >&5
19650fd6
AS
15190sed 's/^/| /' conftest.$ac_ext >&5
15191
c0d27fcc
MR
15192ac_header_compiler=no
15193fi
35996d22 15194rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15195echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15196echo "${ECHO_T}$ac_header_compiler" >&6
15197
15198# Is the header present?
15199echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
15200echo $ECHO_N "checking inq_stats/cpustats.h presence... $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. */
98418dba 15207#include <inq_stats/cpustats.h>
503d2be0 15208_ACEOF
c0d27fcc 15209if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15210 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15211 ac_status=$?
6bae0ccf 15212 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15213 rm -f conftest.er1
15214 cat conftest.err >&5
c0d27fcc 15215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15216 (exit $ac_status); } >/dev/null; then
15217 if test -s conftest.err; then
15218 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15219 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15220 else
15221 ac_cpp_err=
15222 fi
15223else
15224 ac_cpp_err=yes
15225fi
15226if test -z "$ac_cpp_err"; then
c0d27fcc 15227 ac_header_preproc=yes
503d2be0
AS
15228else
15229 echo "$as_me: failed program was:" >&5
19650fd6
AS
15230sed 's/^/| /' conftest.$ac_ext >&5
15231
c0d27fcc 15232 ac_header_preproc=no
ba4481b5 15233fi
503d2be0 15234rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15235echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15236echo "${ECHO_T}$ac_header_preproc" >&6
15237
15238# So? What about this header?
35996d22
AS
15239case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15240 yes:no: )
c0d27fcc
MR
15241 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15242echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15243 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&5
15244echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&2;}
15245 ac_header_preproc=yes
19650fd6 15246 ;;
35996d22 15247 no:yes:* )
c0d27fcc
MR
15248 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
15249echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15250 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
15251echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
15252 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&5
15253echo "$as_me: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&2;}
15254 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15255echo "$as_me: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15256 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15257echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15258 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&5
15259echo "$as_me: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15260 (
15261 cat <<\_ASBOX
35996d22
AS
15262## ------------------------------------------ ##
15263## Report this to the AC_PACKAGE_NAME lists. ##
15264## ------------------------------------------ ##
19650fd6
AS
15265_ASBOX
15266 ) |
15267 sed "s/^/$as_me: WARNING: /" >&2
15268 ;;
c0d27fcc
MR
15269esac
15270echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
15271echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15272if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15273 echo $ECHO_N "(cached) $ECHO_C" >&6
15274else
15275 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 15276fi
c0d27fcc 15277echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 15278echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
15279
15280fi
98418dba
CW
15281if test $ac_cv_header_inq_stats_cpustats_h = yes; then
15282 ac_have_func=yes
ba4481b5 15283
c0d27fcc 15284cat >>confdefs.h <<\_ACEOF
98418dba 15285#define UMAX 1
c0d27fcc 15286_ACEOF
98418dba 15287
c0d27fcc
MR
15288
15289cat >>confdefs.h <<\_ACEOF
98418dba 15290#define UMAX4_3 1
c0d27fcc 15291_ACEOF
98418dba
CW
15292
15293fi
15294
c0d27fcc 15295
98418dba
CW
15296fi
15297
15298if test $ac_have_func = no; then
c0d27fcc
MR
15299 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15300 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
15301echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15302if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 15303 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15304fi
15305echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
15306echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 15307else
c0d27fcc
MR
15308 # Is the header compilable?
15309echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
15310echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
15311cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15312/* confdefs.h. */
15313_ACEOF
15314cat confdefs.h >>conftest.$ac_ext
15315cat >>conftest.$ac_ext <<_ACEOF
15316/* end confdefs.h. */
c0d27fcc
MR
15317$ac_includes_default
15318#include <sys/cpustats.h>
15319_ACEOF
15320rm -f conftest.$ac_objext
15321if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15322 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15323 ac_status=$?
35996d22
AS
15324 grep -v '^ *+' conftest.er1 >conftest.err
15325 rm -f conftest.er1
15326 cat conftest.err >&5
c0d27fcc
MR
15327 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15328 (exit $ac_status); } &&
35996d22
AS
15329 { ac_try='test -z "$ac_c_werror_flag"
15330 || test ! -s conftest.err'
15331 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15332 (eval $ac_try) 2>&5
15333 ac_status=$?
15334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15335 (exit $ac_status); }; } &&
15336 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15338 (eval $ac_try) 2>&5
15339 ac_status=$?
15340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15341 (exit $ac_status); }; }; then
15342 ac_header_compiler=yes
15343else
15344 echo "$as_me: failed program was:" >&5
19650fd6
AS
15345sed 's/^/| /' conftest.$ac_ext >&5
15346
c0d27fcc
MR
15347ac_header_compiler=no
15348fi
35996d22 15349rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15350echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15351echo "${ECHO_T}$ac_header_compiler" >&6
15352
15353# Is the header present?
15354echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
15355echo $ECHO_N "checking sys/cpustats.h presence... $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. */
98418dba
CW
15362#include <sys/cpustats.h>
15363_ACEOF
c0d27fcc 15364if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
15365 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15366 ac_status=$?
6bae0ccf 15367 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15368 rm -f conftest.er1
15369 cat conftest.err >&5
c0d27fcc 15370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15371 (exit $ac_status); } >/dev/null; then
15372 if test -s conftest.err; then
15373 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15374 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15375 else
15376 ac_cpp_err=
15377 fi
15378else
15379 ac_cpp_err=yes
503d2be0 15380fi
98418dba 15381if test -z "$ac_cpp_err"; then
c0d27fcc 15382 ac_header_preproc=yes
98418dba
CW
15383else
15384 echo "$as_me: failed program was:" >&5
19650fd6
AS
15385sed 's/^/| /' conftest.$ac_ext >&5
15386
c0d27fcc 15387 ac_header_preproc=no
98418dba
CW
15388fi
15389rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15390echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15391echo "${ECHO_T}$ac_header_preproc" >&6
15392
15393# So? What about this header?
35996d22
AS
15394case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15395 yes:no: )
c0d27fcc
MR
15396 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15397echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15398 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&5
15399echo "$as_me: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&2;}
15400 ac_header_preproc=yes
19650fd6 15401 ;;
35996d22 15402 no:yes:* )
c0d27fcc
MR
15403 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
15404echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15405 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
15406echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
15407 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: see the Autoconf documentation" >&5
15408echo "$as_me: WARNING: sys/cpustats.h: see the Autoconf documentation" >&2;}
15409 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15410echo "$as_me: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15411 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15412echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15413 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&5
15414echo "$as_me: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15415 (
15416 cat <<\_ASBOX
35996d22
AS
15417## ------------------------------------------ ##
15418## Report this to the AC_PACKAGE_NAME lists. ##
15419## ------------------------------------------ ##
19650fd6
AS
15420_ASBOX
15421 ) |
15422 sed "s/^/$as_me: WARNING: /" >&2
15423 ;;
c0d27fcc
MR
15424esac
15425echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
15426echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15427if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15428 echo $ECHO_N "(cached) $ECHO_C" >&6
15429else
15430 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 15431fi
c0d27fcc 15432echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 15433echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
15434
15435fi
98418dba 15436if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 15437 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 15438#define UMAX 1
c0d27fcc 15439_ACEOF
ba4481b5 15440
98418dba
CW
15441fi
15442
c0d27fcc 15443
98418dba
CW
15444fi
15445
15446if test $ac_have_func = no; then
15447
15448for ac_header in mach/mach.h
2c9dccc9
PJ
15449do
15450as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15451if eval "test \"\${$as_ac_Header+set}\" = set"; then
15452 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
15453echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15454if eval "test \"\${$as_ac_Header+set}\" = set"; then
15455 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15456fi
15457echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15458echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15459else
c0d27fcc
MR
15460 # Is the header compilable?
15461echo "$as_me:$LINENO: checking $ac_header usability" >&5
15462echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15463cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15464/* confdefs.h. */
15465_ACEOF
15466cat confdefs.h >>conftest.$ac_ext
15467cat >>conftest.$ac_ext <<_ACEOF
15468/* end confdefs.h. */
c0d27fcc
MR
15469$ac_includes_default
15470#include <$ac_header>
15471_ACEOF
15472rm -f conftest.$ac_objext
15473if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15474 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15475 ac_status=$?
35996d22
AS
15476 grep -v '^ *+' conftest.er1 >conftest.err
15477 rm -f conftest.er1
15478 cat conftest.err >&5
c0d27fcc
MR
15479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15480 (exit $ac_status); } &&
35996d22
AS
15481 { ac_try='test -z "$ac_c_werror_flag"
15482 || test ! -s conftest.err'
15483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15484 (eval $ac_try) 2>&5
15485 ac_status=$?
15486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15487 (exit $ac_status); }; } &&
15488 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15490 (eval $ac_try) 2>&5
15491 ac_status=$?
15492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15493 (exit $ac_status); }; }; then
15494 ac_header_compiler=yes
15495else
15496 echo "$as_me: failed program was:" >&5
19650fd6
AS
15497sed 's/^/| /' conftest.$ac_ext >&5
15498
c0d27fcc
MR
15499ac_header_compiler=no
15500fi
35996d22 15501rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15502echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15503echo "${ECHO_T}$ac_header_compiler" >&6
15504
15505# Is the header present?
15506echo "$as_me:$LINENO: checking $ac_header presence" >&5
15507echo $ECHO_N "checking $ac_header presence... $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. */
2c9dccc9
PJ
15514#include <$ac_header>
15515_ACEOF
c0d27fcc 15516if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
15517 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15518 ac_status=$?
6bae0ccf 15519 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
15520 rm -f conftest.er1
15521 cat conftest.err >&5
c0d27fcc 15522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
15523 (exit $ac_status); } >/dev/null; then
15524 if test -s conftest.err; then
15525 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15526 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2c9dccc9
PJ
15527 else
15528 ac_cpp_err=
15529 fi
15530else
15531 ac_cpp_err=yes
15532fi
15533if test -z "$ac_cpp_err"; then
c0d27fcc
MR
15534 ac_header_preproc=yes
15535else
15536 echo "$as_me: failed program was:" >&5
19650fd6
AS
15537sed 's/^/| /' conftest.$ac_ext >&5
15538
c0d27fcc
MR
15539 ac_header_preproc=no
15540fi
15541rm -f conftest.err conftest.$ac_ext
15542echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15543echo "${ECHO_T}$ac_header_preproc" >&6
15544
15545# So? What about this header?
35996d22
AS
15546case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15547 yes:no: )
c0d27fcc
MR
15548 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15549echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15550 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15551echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15552 ac_header_preproc=yes
19650fd6 15553 ;;
35996d22 15554 no:yes:* )
c0d27fcc
MR
15555 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15556echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15557 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15558echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15559 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15560echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15561 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15562echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15563 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15564echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15565 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15566echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15567 (
15568 cat <<\_ASBOX
35996d22
AS
15569## ------------------------------------------ ##
15570## Report this to the AC_PACKAGE_NAME lists. ##
15571## ------------------------------------------ ##
19650fd6
AS
15572_ASBOX
15573 ) |
15574 sed "s/^/$as_me: WARNING: /" >&2
15575 ;;
c0d27fcc
MR
15576esac
15577echo "$as_me:$LINENO: checking for $ac_header" >&5
15578echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15579if eval "test \"\${$as_ac_Header+set}\" = set"; then
15580 echo $ECHO_N "(cached) $ECHO_C" >&6
15581else
35996d22 15582 eval "$as_ac_Header=\$ac_header_preproc"
c0d27fcc
MR
15583fi
15584echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15585echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15586
15587fi
15588if test `eval echo '${'$as_ac_Header'}'` = yes; then
15589 cat >>confdefs.h <<_ACEOF
15590#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15591_ACEOF
15592
15593fi
15594
15595done
15596
15597fi
15598
15599
15600for ac_header in nlist.h
15601do
15602as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15603if eval "test \"\${$as_ac_Header+set}\" = set"; then
15604 echo "$as_me:$LINENO: checking for $ac_header" >&5
15605echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15606if eval "test \"\${$as_ac_Header+set}\" = set"; then
15607 echo $ECHO_N "(cached) $ECHO_C" >&6
15608fi
15609echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15610echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15611else
15612 # Is the header compilable?
15613echo "$as_me:$LINENO: checking $ac_header usability" >&5
15614echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15615cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15616/* confdefs.h. */
15617_ACEOF
15618cat confdefs.h >>conftest.$ac_ext
15619cat >>conftest.$ac_ext <<_ACEOF
15620/* end confdefs.h. */
c0d27fcc
MR
15621$ac_includes_default
15622#include <$ac_header>
15623_ACEOF
15624rm -f conftest.$ac_objext
15625if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15626 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15627 ac_status=$?
35996d22
AS
15628 grep -v '^ *+' conftest.er1 >conftest.err
15629 rm -f conftest.er1
15630 cat conftest.err >&5
c0d27fcc
MR
15631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15632 (exit $ac_status); } &&
35996d22
AS
15633 { ac_try='test -z "$ac_c_werror_flag"
15634 || test ! -s conftest.err'
15635 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15636 (eval $ac_try) 2>&5
15637 ac_status=$?
15638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15639 (exit $ac_status); }; } &&
15640 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15641 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15642 (eval $ac_try) 2>&5
15643 ac_status=$?
15644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15645 (exit $ac_status); }; }; then
15646 ac_header_compiler=yes
2c9dccc9
PJ
15647else
15648 echo "$as_me: failed program was:" >&5
19650fd6
AS
15649sed 's/^/| /' conftest.$ac_ext >&5
15650
c0d27fcc 15651ac_header_compiler=no
98418dba 15652fi
35996d22 15653rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15654echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15655echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 15656
c0d27fcc
MR
15657# Is the header present?
15658echo "$as_me:$LINENO: checking $ac_header presence" >&5
15659echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
15666#include <$ac_header>
15667_ACEOF
c0d27fcc 15668if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15669 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15670 ac_status=$?
6bae0ccf 15671 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15672 rm -f conftest.er1
15673 cat conftest.err >&5
c0d27fcc 15674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15675 (exit $ac_status); } >/dev/null; then
15676 if test -s conftest.err; then
15677 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15678 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15679 else
15680 ac_cpp_err=
15681 fi
15682else
15683 ac_cpp_err=yes
15684fi
15685if test -z "$ac_cpp_err"; then
c0d27fcc 15686 ac_header_preproc=yes
503d2be0
AS
15687else
15688 echo "$as_me: failed program was:" >&5
19650fd6
AS
15689sed 's/^/| /' conftest.$ac_ext >&5
15690
c0d27fcc 15691 ac_header_preproc=no
b5de8dc0 15692fi
503d2be0 15693rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15694echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15695echo "${ECHO_T}$ac_header_preproc" >&6
15696
15697# So? What about this header?
35996d22
AS
15698case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15699 yes:no: )
c0d27fcc
MR
15700 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15701echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15702 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15703echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15704 ac_header_preproc=yes
19650fd6 15705 ;;
35996d22 15706 no:yes:* )
c0d27fcc
MR
15707 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15708echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15709 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15710echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15711 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15712echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15713 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15714echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15715 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15716echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15717 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15718echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15719 (
15720 cat <<\_ASBOX
35996d22
AS
15721## ------------------------------------------ ##
15722## Report this to the AC_PACKAGE_NAME lists. ##
15723## ------------------------------------------ ##
19650fd6
AS
15724_ASBOX
15725 ) |
15726 sed "s/^/$as_me: WARNING: /" >&2
15727 ;;
c0d27fcc
MR
15728esac
15729echo "$as_me:$LINENO: checking for $ac_header" >&5
15730echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15731if eval "test \"\${$as_ac_Header+set}\" = set"; then
15732 echo $ECHO_N "(cached) $ECHO_C" >&6
15733else
35996d22 15734 eval "$as_ac_Header=\$ac_header_preproc"
b5de8dc0 15735fi
c0d27fcc 15736echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15737echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15738
15739fi
98418dba 15740if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15741 cat >>confdefs.h <<_ACEOF
98418dba 15742#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
15743_ACEOF
15744 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
15745echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
15746if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 15747 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 15748else
503d2be0 15749 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15750/* confdefs.h. */
15751_ACEOF
15752cat confdefs.h >>conftest.$ac_ext
15753cat >>conftest.$ac_ext <<_ACEOF
15754/* end confdefs.h. */
98418dba 15755#include <nlist.h>
b5de8dc0 15756
503d2be0
AS
15757int
15758main ()
15759{
98418dba
CW
15760static struct nlist ac_aggr;
15761if (ac_aggr.n_un.n_name)
15762return 0;
503d2be0
AS
15763 ;
15764 return 0;
15765}
15766_ACEOF
98418dba 15767rm -f conftest.$ac_objext
c0d27fcc 15768if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15769 (eval $ac_compile) 2>conftest.er1
503d2be0 15770 ac_status=$?
35996d22
AS
15771 grep -v '^ *+' conftest.er1 >conftest.err
15772 rm -f conftest.er1
15773 cat conftest.err >&5
c0d27fcc 15774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15775 (exit $ac_status); } &&
35996d22
AS
15776 { ac_try='test -z "$ac_c_werror_flag"
15777 || test ! -s conftest.err'
15778 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15779 (eval $ac_try) 2>&5
15780 ac_status=$?
15781 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15782 (exit $ac_status); }; } &&
15783 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15784 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15785 (eval $ac_try) 2>&5
15786 ac_status=$?
c0d27fcc 15787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15788 (exit $ac_status); }; }; then
98418dba 15789 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
15790else
15791 echo "$as_me: failed program was:" >&5
19650fd6
AS
15792sed 's/^/| /' conftest.$ac_ext >&5
15793
6bae0ccf 15794cat >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. */
6bae0ccf
DL
15800#include <nlist.h>
15801
15802int
15803main ()
15804{
15805static struct nlist ac_aggr;
15806if (sizeof ac_aggr.n_un.n_name)
15807return 0;
15808 ;
15809 return 0;
15810}
15811_ACEOF
15812rm -f conftest.$ac_objext
15813if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15814 (eval $ac_compile) 2>conftest.er1
6bae0ccf 15815 ac_status=$?
35996d22
AS
15816 grep -v '^ *+' conftest.er1 >conftest.err
15817 rm -f conftest.er1
15818 cat conftest.err >&5
6bae0ccf
DL
15819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
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'
6bae0ccf
DL
15829 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15830 (eval $ac_try) 2>&5
15831 ac_status=$?
15832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15833 (exit $ac_status); }; }; then
15834 ac_cv_member_struct_nlist_n_un_n_name=yes
15835else
15836 echo "$as_me: failed program was:" >&5
19650fd6
AS
15837sed 's/^/| /' conftest.$ac_ext >&5
15838
98418dba 15839ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 15840fi
35996d22 15841rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b5de8dc0 15842fi
35996d22 15843rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 15844fi
c0d27fcc 15845echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
15846echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
15847if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 15848
c0d27fcc 15849cat >>confdefs.h <<_ACEOF
98418dba 15850#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 15851_ACEOF
b5de8dc0 15852
c0d27fcc
MR
15853
15854cat >>confdefs.h <<\_ACEOF
98418dba 15855#define NLIST_NAME_UNION 1
c0d27fcc 15856_ACEOF
b5de8dc0 15857
98418dba 15858fi
b5de8dc0 15859
c0d27fcc 15860
98418dba 15861fi
c0d27fcc 15862
98418dba 15863done
b5de8dc0 15864
98418dba
CW
15865fi
15866done
b5de8dc0 15867
c0d27fcc 15868
98418dba 15869# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 15870echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
15871echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
15872if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
15873 echo $ECHO_N "(cached) $ECHO_C" >&6
15874else
15875 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15876/* confdefs.h. */
15877_ACEOF
15878cat confdefs.h >>conftest.$ac_ext
15879cat >>conftest.$ac_ext <<_ACEOF
15880/* end confdefs.h. */
6bae0ccf 15881#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
15882#ifdef LDAV_PRIVILEGED
15883Yowza Am I SETGID yet
15884#endif
15885_ACEOF
15886if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 15887 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
15888 ac_cv_func_getloadavg_setgid=yes
15889else
15890 ac_cv_func_getloadavg_setgid=no
15891fi
15892rm -f conftest*
b5de8dc0 15893
98418dba 15894fi
c0d27fcc 15895echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
15896echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
15897if test $ac_cv_func_getloadavg_setgid = yes; then
15898 NEED_SETGID=true
b5de8dc0 15899
c0d27fcc 15900cat >>confdefs.h <<\_ACEOF
98418dba 15901#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 15902_ACEOF
98418dba 15903
b5de8dc0 15904else
98418dba 15905 NEED_SETGID=false
b5de8dc0 15906fi
98418dba
CW
15907
15908if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 15909 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
15910echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
15911if test "${ac_cv_group_kmem+set}" = set; then
15912 echo $ECHO_N "(cached) $ECHO_C" >&6
15913else
15914 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
15915 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
15916 # If we got an error (system does not support symlinks), try without -L.
15917 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
15918 ac_cv_group_kmem=`echo $ac_ls_output \
35996d22 15919 | sed -ne 's/[ ][ ]*/ /g;
98418dba
CW
15920 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
15921 / /s/.* //;p;'`
15922
b5de8dc0 15923fi
c0d27fcc 15924echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
15925echo "${ECHO_T}$ac_cv_group_kmem" >&6
15926 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 15927fi
98418dba
CW
15928if test "x$ac_save_LIBS" = x; then
15929 GETLOADAVG_LIBS=$LIBS
15930else
15931 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 15932fi
98418dba 15933LIBS=$ac_save_LIBS
b5de8dc0 15934
c0d27fcc
MR
15935
15936
15937echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
15938echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
15939if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 15940 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 15941else
b936fae4
AS
15942 while :; do
15943 ac_cv_sys_largefile_source=no
503d2be0 15944 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15945/* confdefs.h. */
15946_ACEOF
15947cat confdefs.h >>conftest.$ac_ext
15948cat >>conftest.$ac_ext <<_ACEOF
15949/* end confdefs.h. */
b936fae4 15950#include <stdio.h>
503d2be0
AS
15951int
15952main ()
15953{
b936fae4
AS
15954return !fseeko;
15955 ;
15956 return 0;
15957}
15958_ACEOF
15959rm -f conftest.$ac_objext
c0d27fcc 15960if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15961 (eval $ac_compile) 2>conftest.er1
b936fae4 15962 ac_status=$?
35996d22
AS
15963 grep -v '^ *+' conftest.er1 >conftest.err
15964 rm -f conftest.er1
15965 cat conftest.err >&5
c0d27fcc 15966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 15967 (exit $ac_status); } &&
35996d22
AS
15968 { ac_try='test -z "$ac_c_werror_flag"
15969 || test ! -s conftest.err'
15970 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15971 (eval $ac_try) 2>&5
15972 ac_status=$?
15973 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15974 (exit $ac_status); }; } &&
15975 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15976 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
15977 (eval $ac_try) 2>&5
15978 ac_status=$?
c0d27fcc 15979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
15980 (exit $ac_status); }; }; then
15981 break
15982else
15983 echo "$as_me: failed program was:" >&5
19650fd6
AS
15984sed 's/^/| /' conftest.$ac_ext >&5
15985
b936fae4 15986fi
35996d22 15987rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4 15988 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15989/* confdefs.h. */
15990_ACEOF
15991cat confdefs.h >>conftest.$ac_ext
15992cat >>conftest.$ac_ext <<_ACEOF
15993/* end confdefs.h. */
b936fae4
AS
15994#define _LARGEFILE_SOURCE 1
15995#include <stdio.h>
b936fae4
AS
15996int
15997main ()
15998{
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 ac_cv_sys_largefile_source=1; 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
AS
16033 break
16034done
16035fi
c0d27fcc 16036echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
16037echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16038if test "$ac_cv_sys_largefile_source" != no; then
16039
c0d27fcc 16040cat >>confdefs.h <<_ACEOF
b936fae4 16041#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 16042_ACEOF
b936fae4
AS
16043
16044fi
16045rm -f conftest*
4c343001 16046
b936fae4
AS
16047# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16048# in glibc 2.1.3, but that breaks too many other things.
16049# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 16050echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
16051echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16052if test "${ac_cv_func_fseeko+set}" = set; then
16053 echo $ECHO_N "(cached) $ECHO_C" >&6
16054else
16055 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16056/* confdefs.h. */
16057_ACEOF
16058cat confdefs.h >>conftest.$ac_ext
16059cat >>conftest.$ac_ext <<_ACEOF
16060/* end confdefs.h. */
b936fae4 16061#include <stdio.h>
b936fae4
AS
16062int
16063main ()
16064{
16065return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
16066 ;
16067 return 0;
16068}
16069_ACEOF
16070rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16071if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16072 (eval $ac_link) 2>conftest.er1
503d2be0 16073 ac_status=$?
35996d22
AS
16074 grep -v '^ *+' conftest.er1 >conftest.err
16075 rm -f conftest.er1
16076 cat conftest.err >&5
c0d27fcc 16077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16078 (exit $ac_status); } &&
35996d22
AS
16079 { ac_try='test -z "$ac_c_werror_flag"
16080 || test ! -s conftest.err'
16081 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16082 (eval $ac_try) 2>&5
16083 ac_status=$?
16084 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16085 (exit $ac_status); }; } &&
16086 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16087 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16088 (eval $ac_try) 2>&5
16089 ac_status=$?
c0d27fcc 16090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16091 (exit $ac_status); }; }; then
b936fae4 16092 ac_cv_func_fseeko=yes
503d2be0
AS
16093else
16094 echo "$as_me: failed program was:" >&5
19650fd6
AS
16095sed 's/^/| /' conftest.$ac_ext >&5
16096
b936fae4 16097ac_cv_func_fseeko=no
503d2be0 16098fi
35996d22
AS
16099rm -f conftest.err conftest.$ac_objext \
16100 conftest$ac_exeext conftest.$ac_ext
503d2be0 16101fi
c0d27fcc 16102echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
16103echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16104if test $ac_cv_func_fseeko = yes; then
16105
c0d27fcc 16106cat >>confdefs.h <<\_ACEOF
b936fae4 16107#define HAVE_FSEEKO 1
c0d27fcc 16108_ACEOF
b936fae4 16109
4c343001
DL
16110fi
16111
c0d27fcc 16112
cd958eb3
MB
16113echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
16114echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
16115if test "${ac_cv_func_getpgrp_void+set}" = set; then
16116 echo $ECHO_N "(cached) $ECHO_C" >&6
16117else
16118 # Use it with a single arg.
16119cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16120/* confdefs.h. */
16121_ACEOF
16122cat confdefs.h >>conftest.$ac_ext
16123cat >>conftest.$ac_ext <<_ACEOF
16124/* end confdefs.h. */
cd958eb3
MB
16125$ac_includes_default
16126int
16127main ()
16128{
16129getpgrp (0);
16130 ;
16131 return 0;
16132}
16133_ACEOF
16134rm -f conftest.$ac_objext
16135if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16136 (eval $ac_compile) 2>conftest.er1
cd958eb3 16137 ac_status=$?
35996d22
AS
16138 grep -v '^ *+' conftest.er1 >conftest.err
16139 rm -f conftest.er1
16140 cat conftest.err >&5
cd958eb3
MB
16141 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16142 (exit $ac_status); } &&
35996d22
AS
16143 { ac_try='test -z "$ac_c_werror_flag"
16144 || test ! -s conftest.err'
16145 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16146 (eval $ac_try) 2>&5
16147 ac_status=$?
16148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16149 (exit $ac_status); }; } &&
16150 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
16151 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16152 (eval $ac_try) 2>&5
16153 ac_status=$?
16154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16155 (exit $ac_status); }; }; then
16156 ac_cv_func_getpgrp_void=no
16157else
16158 echo "$as_me: failed program was:" >&5
19650fd6
AS
16159sed 's/^/| /' conftest.$ac_ext >&5
16160
cd958eb3
MB
16161ac_cv_func_getpgrp_void=yes
16162fi
35996d22 16163rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
16164
16165fi
16166echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
16167echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
16168if test $ac_cv_func_getpgrp_void = yes; then
16169
16170cat >>confdefs.h <<\_ACEOF
16171#define GETPGRP_VOID 1
16172_ACEOF
16173
16174fi
16175
16176
973a76b1
DL
16177
16178for ac_func in strftime
16179do
16180as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16181echo "$as_me:$LINENO: checking for $ac_func" >&5
16182echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16183if eval "test \"\${$as_ac_var+set}\" = set"; then
16184 echo $ECHO_N "(cached) $ECHO_C" >&6
16185else
16186 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16187/* confdefs.h. */
16188_ACEOF
16189cat confdefs.h >>conftest.$ac_ext
16190cat >>conftest.$ac_ext <<_ACEOF
16191/* end confdefs.h. */
35996d22
AS
16192/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16193 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16194#define $ac_func innocuous_$ac_func
16195
973a76b1 16196/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16197 which can conflict with char $ac_func (); below.
16198 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16199 <limits.h> exists even on freestanding compilers. */
35996d22 16200
19650fd6
AS
16201#ifdef __STDC__
16202# include <limits.h>
16203#else
16204# include <assert.h>
16205#endif
35996d22
AS
16206
16207#undef $ac_func
16208
973a76b1
DL
16209/* Override any gcc2 internal prototype to avoid an error. */
16210#ifdef __cplusplus
16211extern "C"
19650fd6 16212{
973a76b1
DL
16213#endif
16214/* We use char because int might match the return type of a gcc2
16215 builtin and then its argument prototype would still apply. */
16216char $ac_func ();
16217/* The GNU C library defines this for functions which it implements
16218 to always fail with ENOSYS. Some functions are actually named
16219 something starting with __ and the normal name is an alias. */
16220#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16221choke me
16222#else
19650fd6
AS
16223char (*f) () = $ac_func;
16224#endif
16225#ifdef __cplusplus
16226}
973a76b1
DL
16227#endif
16228
19650fd6
AS
16229int
16230main ()
16231{
16232return f != $ac_func;
973a76b1
DL
16233 ;
16234 return 0;
16235}
16236_ACEOF
16237rm -f conftest.$ac_objext conftest$ac_exeext
16238if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16239 (eval $ac_link) 2>conftest.er1
973a76b1 16240 ac_status=$?
35996d22
AS
16241 grep -v '^ *+' conftest.er1 >conftest.err
16242 rm -f conftest.er1
16243 cat conftest.err >&5
973a76b1
DL
16244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16245 (exit $ac_status); } &&
35996d22
AS
16246 { ac_try='test -z "$ac_c_werror_flag"
16247 || test ! -s conftest.err'
16248 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16249 (eval $ac_try) 2>&5
16250 ac_status=$?
16251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16252 (exit $ac_status); }; } &&
16253 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
16254 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16255 (eval $ac_try) 2>&5
16256 ac_status=$?
16257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16258 (exit $ac_status); }; }; then
16259 eval "$as_ac_var=yes"
16260else
16261 echo "$as_me: failed program was:" >&5
19650fd6
AS
16262sed 's/^/| /' conftest.$ac_ext >&5
16263
973a76b1
DL
16264eval "$as_ac_var=no"
16265fi
35996d22
AS
16266rm -f conftest.err conftest.$ac_objext \
16267 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16268fi
16269echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16270echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16271if test `eval echo '${'$as_ac_var'}'` = yes; then
16272 cat >>confdefs.h <<_ACEOF
16273#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16274_ACEOF
16275
16276else
16277 # strftime is in -lintl on SCO UNIX.
16278echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
16279echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
16280if test "${ac_cv_lib_intl_strftime+set}" = set; then
16281 echo $ECHO_N "(cached) $ECHO_C" >&6
16282else
16283 ac_check_lib_save_LIBS=$LIBS
16284LIBS="-lintl $LIBS"
16285cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16286/* confdefs.h. */
16287_ACEOF
16288cat confdefs.h >>conftest.$ac_ext
16289cat >>conftest.$ac_ext <<_ACEOF
16290/* end confdefs.h. */
973a76b1
DL
16291
16292/* Override any gcc2 internal prototype to avoid an error. */
16293#ifdef __cplusplus
16294extern "C"
16295#endif
16296/* We use char because int might match the return type of a gcc2
16297 builtin and then its argument prototype would still apply. */
16298char strftime ();
16299int
16300main ()
16301{
16302strftime ();
16303 ;
16304 return 0;
16305}
16306_ACEOF
16307rm -f conftest.$ac_objext conftest$ac_exeext
16308if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16309 (eval $ac_link) 2>conftest.er1
973a76b1 16310 ac_status=$?
35996d22
AS
16311 grep -v '^ *+' conftest.er1 >conftest.err
16312 rm -f conftest.er1
16313 cat conftest.err >&5
973a76b1
DL
16314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16315 (exit $ac_status); } &&
35996d22
AS
16316 { ac_try='test -z "$ac_c_werror_flag"
16317 || test ! -s conftest.err'
16318 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16319 (eval $ac_try) 2>&5
16320 ac_status=$?
16321 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16322 (exit $ac_status); }; } &&
16323 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
16324 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16325 (eval $ac_try) 2>&5
16326 ac_status=$?
16327 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16328 (exit $ac_status); }; }; then
16329 ac_cv_lib_intl_strftime=yes
16330else
16331 echo "$as_me: failed program was:" >&5
19650fd6
AS
16332sed 's/^/| /' conftest.$ac_ext >&5
16333
973a76b1
DL
16334ac_cv_lib_intl_strftime=no
16335fi
35996d22
AS
16336rm -f conftest.err conftest.$ac_objext \
16337 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16338LIBS=$ac_check_lib_save_LIBS
16339fi
16340echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
16341echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
16342if test $ac_cv_lib_intl_strftime = yes; then
16343 cat >>confdefs.h <<\_ACEOF
16344#define HAVE_STRFTIME 1
16345_ACEOF
16346
16347LIBS="-lintl $LIBS"
16348fi
16349
16350fi
16351done
16352
16353
b936fae4
AS
16354# UNIX98 PTYs.
16355
16356for ac_func in grantpt
503d2be0
AS
16357do
16358as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16359echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
16360echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16361if eval "test \"\${$as_ac_var+set}\" = set"; then
16362 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16363else
503d2be0 16364 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16365/* confdefs.h. */
16366_ACEOF
16367cat confdefs.h >>conftest.$ac_ext
16368cat >>conftest.$ac_ext <<_ACEOF
16369/* end confdefs.h. */
35996d22
AS
16370/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16371 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16372#define $ac_func innocuous_$ac_func
16373
503d2be0 16374/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16375 which can conflict with char $ac_func (); below.
16376 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16377 <limits.h> exists even on freestanding compilers. */
35996d22 16378
19650fd6
AS
16379#ifdef __STDC__
16380# include <limits.h>
16381#else
16382# include <assert.h>
16383#endif
35996d22
AS
16384
16385#undef $ac_func
16386
4c343001 16387/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16388#ifdef __cplusplus
16389extern "C"
19650fd6 16390{
503d2be0 16391#endif
4c343001 16392/* We use char because int might match the return type of a gcc2
503d2be0
AS
16393 builtin and then its argument prototype would still apply. */
16394char $ac_func ();
503d2be0
AS
16395/* The GNU C library defines this for functions which it implements
16396 to always fail with ENOSYS. Some functions are actually named
16397 something starting with __ and the normal name is an alias. */
16398#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16399choke me
16400#else
19650fd6
AS
16401char (*f) () = $ac_func;
16402#endif
16403#ifdef __cplusplus
16404}
503d2be0 16405#endif
4c343001 16406
19650fd6
AS
16407int
16408main ()
16409{
16410return f != $ac_func;
503d2be0
AS
16411 ;
16412 return 0;
16413}
16414_ACEOF
16415rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16416if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16417 (eval $ac_link) 2>conftest.er1
503d2be0 16418 ac_status=$?
35996d22
AS
16419 grep -v '^ *+' conftest.er1 >conftest.err
16420 rm -f conftest.er1
16421 cat conftest.err >&5
c0d27fcc 16422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16423 (exit $ac_status); } &&
35996d22
AS
16424 { ac_try='test -z "$ac_c_werror_flag"
16425 || test ! -s conftest.err'
16426 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16427 (eval $ac_try) 2>&5
16428 ac_status=$?
16429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16430 (exit $ac_status); }; } &&
16431 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16432 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16433 (eval $ac_try) 2>&5
16434 ac_status=$?
c0d27fcc 16435 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16436 (exit $ac_status); }; }; then
16437 eval "$as_ac_var=yes"
16438else
16439 echo "$as_me: failed program was:" >&5
19650fd6
AS
16440sed 's/^/| /' conftest.$ac_ext >&5
16441
503d2be0
AS
16442eval "$as_ac_var=no"
16443fi
35996d22
AS
16444rm -f conftest.err conftest.$ac_objext \
16445 conftest$ac_exeext conftest.$ac_ext
503d2be0 16446fi
c0d27fcc 16447echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16448echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16449if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16450 cat >>confdefs.h <<_ACEOF
503d2be0 16451#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16452_ACEOF
4c343001
DL
16453
16454fi
503d2be0
AS
16455done
16456
c0d27fcc 16457
b936fae4 16458# PTY-related GNU extensions.
4c343001 16459
b936fae4
AS
16460for ac_func in getpt
16461do
16462as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16463echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
16464echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16465if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 16466 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16467else
b936fae4 16468 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16469/* confdefs.h. */
16470_ACEOF
16471cat confdefs.h >>conftest.$ac_ext
16472cat >>conftest.$ac_ext <<_ACEOF
16473/* end confdefs.h. */
35996d22
AS
16474/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16475 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16476#define $ac_func innocuous_$ac_func
16477
087121cc 16478/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16479 which can conflict with char $ac_func (); below.
16480 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16481 <limits.h> exists even on freestanding compilers. */
35996d22 16482
19650fd6
AS
16483#ifdef __STDC__
16484# include <limits.h>
16485#else
16486# include <assert.h>
16487#endif
35996d22
AS
16488
16489#undef $ac_func
16490
087121cc 16491/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16492#ifdef __cplusplus
16493extern "C"
19650fd6 16494{
503d2be0 16495#endif
087121cc 16496/* We use char because int might match the return type of a gcc2
503d2be0
AS
16497 builtin and then its argument prototype would still apply. */
16498char $ac_func ();
087121cc
GM
16499/* The GNU C library defines this for functions which it implements
16500 to always fail with ENOSYS. Some functions are actually named
16501 something starting with __ and the normal name is an alias. */
16502#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16503choke me
16504#else
19650fd6
AS
16505char (*f) () = $ac_func;
16506#endif
16507#ifdef __cplusplus
16508}
087121cc
GM
16509#endif
16510
19650fd6
AS
16511int
16512main ()
16513{
16514return f != $ac_func;
503d2be0
AS
16515 ;
16516 return 0;
16517}
16518_ACEOF
16519rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16520if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16521 (eval $ac_link) 2>conftest.er1
503d2be0 16522 ac_status=$?
35996d22
AS
16523 grep -v '^ *+' conftest.er1 >conftest.err
16524 rm -f conftest.er1
16525 cat conftest.err >&5
c0d27fcc 16526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16527 (exit $ac_status); } &&
35996d22
AS
16528 { ac_try='test -z "$ac_c_werror_flag"
16529 || test ! -s conftest.err'
16530 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16531 (eval $ac_try) 2>&5
16532 ac_status=$?
16533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16534 (exit $ac_status); }; } &&
16535 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16536 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16537 (eval $ac_try) 2>&5
16538 ac_status=$?
c0d27fcc 16539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16540 (exit $ac_status); }; }; then
16541 eval "$as_ac_var=yes"
16542else
16543 echo "$as_me: failed program was:" >&5
19650fd6
AS
16544sed 's/^/| /' conftest.$ac_ext >&5
16545
503d2be0
AS
16546eval "$as_ac_var=no"
16547fi
35996d22
AS
16548rm -f conftest.err conftest.$ac_objext \
16549 conftest$ac_exeext conftest.$ac_ext
503d2be0 16550fi
c0d27fcc 16551echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16552echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16553if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16554 cat >>confdefs.h <<_ACEOF
503d2be0 16555#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16556_ACEOF
087121cc 16557
087121cc
GM
16558fi
16559done
16560
c0d27fcc 16561
ba4481b5
DL
16562# Check this now, so that we will NOT find the above functions in ncurses.
16563# That is because we have not set up to link ncurses in lib-src.
16564# It's better to believe a function is not available
16565# than to expect to find it in ncurses.
503d2be0 16566
c0d27fcc 16567echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
16568echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
16569if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
16570 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16571else
503d2be0 16572 ac_check_lib_save_LIBS=$LIBS
ba4481b5 16573LIBS="-lncurses $LIBS"
503d2be0 16574cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16575/* confdefs.h. */
16576_ACEOF
16577cat confdefs.h >>conftest.$ac_ext
16578cat >>conftest.$ac_ext <<_ACEOF
16579/* end confdefs.h. */
503d2be0 16580
ba4481b5 16581/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16582#ifdef __cplusplus
16583extern "C"
16584#endif
ba4481b5 16585/* We use char because int might match the return type of a gcc2
503d2be0
AS
16586 builtin and then its argument prototype would still apply. */
16587char tparm ();
16588int
16589main ()
16590{
16591tparm ();
16592 ;
16593 return 0;
16594}
16595_ACEOF
16596rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16597if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16598 (eval $ac_link) 2>conftest.er1
503d2be0 16599 ac_status=$?
35996d22
AS
16600 grep -v '^ *+' conftest.er1 >conftest.err
16601 rm -f conftest.er1
16602 cat conftest.err >&5
c0d27fcc 16603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16604 (exit $ac_status); } &&
35996d22
AS
16605 { ac_try='test -z "$ac_c_werror_flag"
16606 || test ! -s conftest.err'
16607 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16608 (eval $ac_try) 2>&5
16609 ac_status=$?
16610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16611 (exit $ac_status); }; } &&
16612 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16613 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16614 (eval $ac_try) 2>&5
16615 ac_status=$?
c0d27fcc 16616 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16617 (exit $ac_status); }; }; then
16618 ac_cv_lib_ncurses_tparm=yes
16619else
16620 echo "$as_me: failed program was:" >&5
19650fd6
AS
16621sed 's/^/| /' conftest.$ac_ext >&5
16622
503d2be0
AS
16623ac_cv_lib_ncurses_tparm=no
16624fi
35996d22
AS
16625rm -f conftest.err conftest.$ac_objext \
16626 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16627LIBS=$ac_check_lib_save_LIBS
16628fi
c0d27fcc 16629echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
16630echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
16631if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 16632 cat >>confdefs.h <<_ACEOF
503d2be0 16633#define HAVE_LIBNCURSES 1
c0d27fcc 16634_ACEOF
ba4481b5
DL
16635
16636 LIBS="-lncurses $LIBS"
16637
ba4481b5
DL
16638fi
16639
c0d27fcc 16640
84e70f78
KR
16641# Do we need the Hesiod library to provide the support routines?
16642if test "$with_hesiod" = yes ; then
16643 # Don't set $LIBS here -- see comments above.
16644 resolv=no
c0d27fcc 16645 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
16646echo $ECHO_N "checking for res_send... $ECHO_C" >&6
16647if test "${ac_cv_func_res_send+set}" = set; then
16648 echo $ECHO_N "(cached) $ECHO_C" >&6
16649else
16650 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16651/* confdefs.h. */
16652_ACEOF
16653cat confdefs.h >>conftest.$ac_ext
16654cat >>conftest.$ac_ext <<_ACEOF
16655/* end confdefs.h. */
35996d22
AS
16656/* Define res_send to an innocuous variant, in case <limits.h> declares res_send.
16657 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16658#define res_send innocuous_res_send
16659
84e70f78 16660/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16661 which can conflict with char res_send (); below.
16662 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16663 <limits.h> exists even on freestanding compilers. */
35996d22 16664
19650fd6
AS
16665#ifdef __STDC__
16666# include <limits.h>
16667#else
16668# include <assert.h>
16669#endif
35996d22
AS
16670
16671#undef res_send
16672
84e70f78
KR
16673/* Override any gcc2 internal prototype to avoid an error. */
16674#ifdef __cplusplus
16675extern "C"
19650fd6 16676{
84e70f78
KR
16677#endif
16678/* We use char because int might match the return type of a gcc2
16679 builtin and then its argument prototype would still apply. */
16680char res_send ();
84e70f78
KR
16681/* The GNU C library defines this for functions which it implements
16682 to always fail with ENOSYS. Some functions are actually named
16683 something starting with __ and the normal name is an alias. */
16684#if defined (__stub_res_send) || defined (__stub___res_send)
16685choke me
16686#else
19650fd6
AS
16687char (*f) () = res_send;
16688#endif
16689#ifdef __cplusplus
16690}
cd958eb3
MB
16691#endif
16692
19650fd6
AS
16693int
16694main ()
16695{
16696return f != res_send;
84e70f78
KR
16697 ;
16698 return 0;
16699}
16700_ACEOF
16701rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16702if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16703 (eval $ac_link) 2>conftest.er1
84e70f78 16704 ac_status=$?
35996d22
AS
16705 grep -v '^ *+' conftest.er1 >conftest.err
16706 rm -f conftest.er1
16707 cat conftest.err >&5
c0d27fcc 16708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16709 (exit $ac_status); } &&
35996d22
AS
16710 { ac_try='test -z "$ac_c_werror_flag"
16711 || test ! -s conftest.err'
16712 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16713 (eval $ac_try) 2>&5
16714 ac_status=$?
16715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16716 (exit $ac_status); }; } &&
16717 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16718 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16719 (eval $ac_try) 2>&5
16720 ac_status=$?
c0d27fcc 16721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16722 (exit $ac_status); }; }; then
16723 ac_cv_func_res_send=yes
16724else
16725 echo "$as_me: failed program was:" >&5
19650fd6
AS
16726sed 's/^/| /' conftest.$ac_ext >&5
16727
84e70f78
KR
16728ac_cv_func_res_send=no
16729fi
35996d22
AS
16730rm -f conftest.err conftest.$ac_objext \
16731 conftest$ac_exeext conftest.$ac_ext
84e70f78 16732fi
c0d27fcc 16733echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
16734echo "${ECHO_T}$ac_cv_func_res_send" >&6
16735if test $ac_cv_func_res_send = yes; then
16736 :
16737else
c0d27fcc 16738 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
16739echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
16740if test "${ac_cv_func___res_send+set}" = set; then
16741 echo $ECHO_N "(cached) $ECHO_C" >&6
16742else
16743 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16744/* confdefs.h. */
16745_ACEOF
16746cat confdefs.h >>conftest.$ac_ext
16747cat >>conftest.$ac_ext <<_ACEOF
16748/* end confdefs.h. */
35996d22
AS
16749/* Define __res_send to an innocuous variant, in case <limits.h> declares __res_send.
16750 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16751#define __res_send innocuous___res_send
16752
84e70f78 16753/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16754 which can conflict with char __res_send (); below.
16755 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16756 <limits.h> exists even on freestanding compilers. */
35996d22 16757
19650fd6
AS
16758#ifdef __STDC__
16759# include <limits.h>
16760#else
16761# include <assert.h>
16762#endif
35996d22
AS
16763
16764#undef __res_send
16765
84e70f78
KR
16766/* Override any gcc2 internal prototype to avoid an error. */
16767#ifdef __cplusplus
16768extern "C"
19650fd6 16769{
84e70f78
KR
16770#endif
16771/* We use char because int might match the return type of a gcc2
16772 builtin and then its argument prototype would still apply. */
16773char __res_send ();
84e70f78
KR
16774/* The GNU C library defines this for functions which it implements
16775 to always fail with ENOSYS. Some functions are actually named
16776 something starting with __ and the normal name is an alias. */
16777#if defined (__stub___res_send) || defined (__stub_____res_send)
16778choke me
16779#else
19650fd6
AS
16780char (*f) () = __res_send;
16781#endif
16782#ifdef __cplusplus
16783}
84e70f78
KR
16784#endif
16785
19650fd6
AS
16786int
16787main ()
16788{
16789return f != __res_send;
84e70f78
KR
16790 ;
16791 return 0;
16792}
16793_ACEOF
16794rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16795if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16796 (eval $ac_link) 2>conftest.er1
84e70f78 16797 ac_status=$?
35996d22
AS
16798 grep -v '^ *+' conftest.er1 >conftest.err
16799 rm -f conftest.er1
16800 cat conftest.err >&5
c0d27fcc 16801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16802 (exit $ac_status); } &&
35996d22
AS
16803 { ac_try='test -z "$ac_c_werror_flag"
16804 || test ! -s conftest.err'
16805 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16806 (eval $ac_try) 2>&5
16807 ac_status=$?
16808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16809 (exit $ac_status); }; } &&
16810 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16811 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16812 (eval $ac_try) 2>&5
16813 ac_status=$?
c0d27fcc 16814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16815 (exit $ac_status); }; }; then
16816 ac_cv_func___res_send=yes
16817else
16818 echo "$as_me: failed program was:" >&5
19650fd6
AS
16819sed 's/^/| /' conftest.$ac_ext >&5
16820
84e70f78
KR
16821ac_cv_func___res_send=no
16822fi
35996d22
AS
16823rm -f conftest.err conftest.$ac_objext \
16824 conftest$ac_exeext conftest.$ac_ext
84e70f78 16825fi
c0d27fcc 16826echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
16827echo "${ECHO_T}$ac_cv_func___res_send" >&6
16828if test $ac_cv_func___res_send = yes; then
16829 :
16830else
c0d27fcc 16831 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
16832echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
16833if test "${ac_cv_lib_resolv_res_send+set}" = set; then
16834 echo $ECHO_N "(cached) $ECHO_C" >&6
16835else
16836 ac_check_lib_save_LIBS=$LIBS
16837LIBS="-lresolv $LIBS"
16838cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16839/* confdefs.h. */
16840_ACEOF
16841cat confdefs.h >>conftest.$ac_ext
16842cat >>conftest.$ac_ext <<_ACEOF
16843/* end confdefs.h. */
84e70f78
KR
16844
16845/* Override any gcc2 internal prototype to avoid an error. */
16846#ifdef __cplusplus
16847extern "C"
16848#endif
16849/* We use char because int might match the return type of a gcc2
16850 builtin and then its argument prototype would still apply. */
16851char res_send ();
16852int
16853main ()
16854{
16855res_send ();
16856 ;
16857 return 0;
16858}
16859_ACEOF
16860rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16861if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16862 (eval $ac_link) 2>conftest.er1
84e70f78 16863 ac_status=$?
35996d22
AS
16864 grep -v '^ *+' conftest.er1 >conftest.err
16865 rm -f conftest.er1
16866 cat conftest.err >&5
c0d27fcc 16867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16868 (exit $ac_status); } &&
35996d22
AS
16869 { ac_try='test -z "$ac_c_werror_flag"
16870 || test ! -s conftest.err'
16871 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16872 (eval $ac_try) 2>&5
16873 ac_status=$?
16874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16875 (exit $ac_status); }; } &&
16876 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16877 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16878 (eval $ac_try) 2>&5
16879 ac_status=$?
c0d27fcc 16880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16881 (exit $ac_status); }; }; then
16882 ac_cv_lib_resolv_res_send=yes
16883else
16884 echo "$as_me: failed program was:" >&5
19650fd6
AS
16885sed 's/^/| /' conftest.$ac_ext >&5
16886
84e70f78
KR
16887ac_cv_lib_resolv_res_send=no
16888fi
35996d22
AS
16889rm -f conftest.err conftest.$ac_objext \
16890 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16891LIBS=$ac_check_lib_save_LIBS
16892fi
c0d27fcc 16893echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
16894echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
16895if test $ac_cv_lib_resolv_res_send = yes; then
16896 resolv=yes
16897else
c0d27fcc 16898 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
16899echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
16900if test "${ac_cv_lib_resolv___res_send+set}" = set; then
16901 echo $ECHO_N "(cached) $ECHO_C" >&6
16902else
16903 ac_check_lib_save_LIBS=$LIBS
16904LIBS="-lresolv $LIBS"
16905cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16906/* confdefs.h. */
16907_ACEOF
16908cat confdefs.h >>conftest.$ac_ext
16909cat >>conftest.$ac_ext <<_ACEOF
16910/* end confdefs.h. */
84e70f78
KR
16911
16912/* Override any gcc2 internal prototype to avoid an error. */
16913#ifdef __cplusplus
16914extern "C"
16915#endif
16916/* We use char because int might match the return type of a gcc2
16917 builtin and then its argument prototype would still apply. */
16918char __res_send ();
16919int
16920main ()
16921{
16922__res_send ();
16923 ;
16924 return 0;
16925}
16926_ACEOF
16927rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16928if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16929 (eval $ac_link) 2>conftest.er1
84e70f78 16930 ac_status=$?
35996d22
AS
16931 grep -v '^ *+' conftest.er1 >conftest.err
16932 rm -f conftest.er1
16933 cat conftest.err >&5
c0d27fcc 16934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16935 (exit $ac_status); } &&
35996d22
AS
16936 { ac_try='test -z "$ac_c_werror_flag"
16937 || test ! -s conftest.err'
16938 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16939 (eval $ac_try) 2>&5
16940 ac_status=$?
16941 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16942 (exit $ac_status); }; } &&
16943 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16944 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16945 (eval $ac_try) 2>&5
16946 ac_status=$?
c0d27fcc 16947 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16948 (exit $ac_status); }; }; then
16949 ac_cv_lib_resolv___res_send=yes
16950else
16951 echo "$as_me: failed program was:" >&5
19650fd6
AS
16952sed 's/^/| /' conftest.$ac_ext >&5
16953
84e70f78
KR
16954ac_cv_lib_resolv___res_send=no
16955fi
35996d22
AS
16956rm -f conftest.err conftest.$ac_objext \
16957 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16958LIBS=$ac_check_lib_save_LIBS
16959fi
c0d27fcc 16960echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
16961echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
16962if test $ac_cv_lib_resolv___res_send = yes; then
16963 resolv=yes
16964fi
16965
16966fi
16967
16968fi
16969
16970fi
16971
16972 if test "$resolv" = yes ; then
16973 RESOLVLIB=-lresolv
b936fae4 16974
c0d27fcc 16975cat >>confdefs.h <<\_ACEOF
84e70f78 16976#define HAVE_LIBRESOLV 1
c0d27fcc 16977_ACEOF
84e70f78
KR
16978
16979 else
16980 RESOLVLIB=
16981 fi
c0d27fcc 16982 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
16983echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
16984if test "${ac_cv_func_hes_getmailhost+set}" = set; then
16985 echo $ECHO_N "(cached) $ECHO_C" >&6
16986else
16987 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16988/* confdefs.h. */
16989_ACEOF
16990cat confdefs.h >>conftest.$ac_ext
16991cat >>conftest.$ac_ext <<_ACEOF
16992/* end confdefs.h. */
35996d22
AS
16993/* Define hes_getmailhost to an innocuous variant, in case <limits.h> declares hes_getmailhost.
16994 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16995#define hes_getmailhost innocuous_hes_getmailhost
16996
84e70f78 16997/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16998 which can conflict with char hes_getmailhost (); below.
16999 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17000 <limits.h> exists even on freestanding compilers. */
35996d22 17001
19650fd6
AS
17002#ifdef __STDC__
17003# include <limits.h>
17004#else
17005# include <assert.h>
17006#endif
35996d22
AS
17007
17008#undef hes_getmailhost
17009
84e70f78
KR
17010/* Override any gcc2 internal prototype to avoid an error. */
17011#ifdef __cplusplus
17012extern "C"
19650fd6 17013{
84e70f78
KR
17014#endif
17015/* We use char because int might match the return type of a gcc2
17016 builtin and then its argument prototype would still apply. */
17017char hes_getmailhost ();
84e70f78
KR
17018/* The GNU C library defines this for functions which it implements
17019 to always fail with ENOSYS. Some functions are actually named
17020 something starting with __ and the normal name is an alias. */
17021#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
17022choke me
17023#else
19650fd6
AS
17024char (*f) () = hes_getmailhost;
17025#endif
17026#ifdef __cplusplus
17027}
cd958eb3
MB
17028#endif
17029
19650fd6
AS
17030int
17031main ()
17032{
17033return f != hes_getmailhost;
84e70f78
KR
17034 ;
17035 return 0;
17036}
17037_ACEOF
17038rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17039if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17040 (eval $ac_link) 2>conftest.er1
84e70f78 17041 ac_status=$?
35996d22
AS
17042 grep -v '^ *+' conftest.er1 >conftest.err
17043 rm -f conftest.er1
17044 cat conftest.err >&5
c0d27fcc 17045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17046 (exit $ac_status); } &&
35996d22
AS
17047 { ac_try='test -z "$ac_c_werror_flag"
17048 || test ! -s conftest.err'
17049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17050 (eval $ac_try) 2>&5
17051 ac_status=$?
17052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17053 (exit $ac_status); }; } &&
17054 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17055 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17056 (eval $ac_try) 2>&5
17057 ac_status=$?
c0d27fcc 17058 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17059 (exit $ac_status); }; }; then
17060 ac_cv_func_hes_getmailhost=yes
17061else
17062 echo "$as_me: failed program was:" >&5
19650fd6
AS
17063sed 's/^/| /' conftest.$ac_ext >&5
17064
84e70f78
KR
17065ac_cv_func_hes_getmailhost=no
17066fi
35996d22
AS
17067rm -f conftest.err conftest.$ac_objext \
17068 conftest$ac_exeext conftest.$ac_ext
84e70f78 17069fi
c0d27fcc 17070echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
17071echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
17072if test $ac_cv_func_hes_getmailhost = yes; then
17073 :
17074else
c0d27fcc 17075 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
17076echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
17077if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
17078 echo $ECHO_N "(cached) $ECHO_C" >&6
17079else
17080 ac_check_lib_save_LIBS=$LIBS
17081LIBS="-lhesiod $RESOLVLIB $LIBS"
17082cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17083/* confdefs.h. */
17084_ACEOF
17085cat confdefs.h >>conftest.$ac_ext
17086cat >>conftest.$ac_ext <<_ACEOF
17087/* end confdefs.h. */
84e70f78
KR
17088
17089/* Override any gcc2 internal prototype to avoid an error. */
17090#ifdef __cplusplus
17091extern "C"
17092#endif
17093/* We use char because int might match the return type of a gcc2
17094 builtin and then its argument prototype would still apply. */
17095char hes_getmailhost ();
17096int
17097main ()
17098{
17099hes_getmailhost ();
17100 ;
17101 return 0;
17102}
17103_ACEOF
17104rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17105if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17106 (eval $ac_link) 2>conftest.er1
84e70f78 17107 ac_status=$?
35996d22
AS
17108 grep -v '^ *+' conftest.er1 >conftest.err
17109 rm -f conftest.er1
17110 cat conftest.err >&5
c0d27fcc 17111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17112 (exit $ac_status); } &&
35996d22
AS
17113 { ac_try='test -z "$ac_c_werror_flag"
17114 || test ! -s conftest.err'
17115 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17116 (eval $ac_try) 2>&5
17117 ac_status=$?
17118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17119 (exit $ac_status); }; } &&
17120 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17121 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17122 (eval $ac_try) 2>&5
17123 ac_status=$?
c0d27fcc 17124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17125 (exit $ac_status); }; }; then
17126 ac_cv_lib_hesiod_hes_getmailhost=yes
17127else
17128 echo "$as_me: failed program was:" >&5
19650fd6
AS
17129sed 's/^/| /' conftest.$ac_ext >&5
17130
84e70f78
KR
17131ac_cv_lib_hesiod_hes_getmailhost=no
17132fi
35996d22
AS
17133rm -f conftest.err conftest.$ac_objext \
17134 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17135LIBS=$ac_check_lib_save_LIBS
17136fi
c0d27fcc 17137echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
17138echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
17139if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 17140
c0d27fcc 17141cat >>confdefs.h <<\_ACEOF
84e70f78 17142#define HAVE_LIBHESIOD 1
c0d27fcc 17143_ACEOF
84e70f78
KR
17144
17145else
17146 :
17147fi
17148
17149fi
17150
17151fi
17152
a21616bd
KR
17153# These tell us which Kerberos-related libraries to use.
17154if test "${with_kerberos+set}" = set; then
503d2be0 17155
c0d27fcc 17156echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
17157echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
17158if test "${ac_cv_lib_com_err_com_err+set}" = set; then
17159 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17160else
503d2be0 17161 ac_check_lib_save_LIBS=$LIBS
a21616bd 17162LIBS="-lcom_err $LIBS"
503d2be0 17163cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17164/* confdefs.h. */
17165_ACEOF
17166cat confdefs.h >>conftest.$ac_ext
17167cat >>conftest.$ac_ext <<_ACEOF
17168/* end confdefs.h. */
503d2be0 17169
a21616bd 17170/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17171#ifdef __cplusplus
17172extern "C"
17173#endif
a21616bd 17174/* We use char because int might match the return type of a gcc2
503d2be0
AS
17175 builtin and then its argument prototype would still apply. */
17176char com_err ();
17177int
17178main ()
17179{
17180com_err ();
17181 ;
17182 return 0;
17183}
17184_ACEOF
17185rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17186if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17187 (eval $ac_link) 2>conftest.er1
503d2be0 17188 ac_status=$?
35996d22
AS
17189 grep -v '^ *+' conftest.er1 >conftest.err
17190 rm -f conftest.er1
17191 cat conftest.err >&5
c0d27fcc 17192 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17193 (exit $ac_status); } &&
35996d22
AS
17194 { ac_try='test -z "$ac_c_werror_flag"
17195 || test ! -s conftest.err'
17196 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17197 (eval $ac_try) 2>&5
17198 ac_status=$?
17199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17200 (exit $ac_status); }; } &&
17201 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17202 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17203 (eval $ac_try) 2>&5
17204 ac_status=$?
c0d27fcc 17205 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17206 (exit $ac_status); }; }; then
17207 ac_cv_lib_com_err_com_err=yes
17208else
17209 echo "$as_me: failed program was:" >&5
19650fd6
AS
17210sed 's/^/| /' conftest.$ac_ext >&5
17211
503d2be0
AS
17212ac_cv_lib_com_err_com_err=no
17213fi
35996d22
AS
17214rm -f conftest.err conftest.$ac_objext \
17215 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17216LIBS=$ac_check_lib_save_LIBS
17217fi
c0d27fcc 17218echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
17219echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
17220if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 17221 cat >>confdefs.h <<_ACEOF
503d2be0 17222#define HAVE_LIBCOM_ERR 1
c0d27fcc 17223_ACEOF
a21616bd
KR
17224
17225 LIBS="-lcom_err $LIBS"
17226
a21616bd
KR
17227fi
17228
c0d27fcc
MR
17229
17230echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
17231echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
17232if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
17233 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17234else
503d2be0 17235 ac_check_lib_save_LIBS=$LIBS
a21616bd 17236LIBS="-lk5crypto $LIBS"
503d2be0 17237cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17238/* confdefs.h. */
17239_ACEOF
17240cat confdefs.h >>conftest.$ac_ext
17241cat >>conftest.$ac_ext <<_ACEOF
17242/* end confdefs.h. */
503d2be0 17243
a21616bd 17244/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17245#ifdef __cplusplus
17246extern "C"
17247#endif
a21616bd 17248/* We use char because int might match the return type of a gcc2
503d2be0
AS
17249 builtin and then its argument prototype would still apply. */
17250char mit_des_cbc_encrypt ();
17251int
17252main ()
17253{
17254mit_des_cbc_encrypt ();
17255 ;
17256 return 0;
17257}
17258_ACEOF
17259rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17260if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17261 (eval $ac_link) 2>conftest.er1
503d2be0 17262 ac_status=$?
35996d22
AS
17263 grep -v '^ *+' conftest.er1 >conftest.err
17264 rm -f conftest.er1
17265 cat conftest.err >&5
c0d27fcc 17266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17267 (exit $ac_status); } &&
35996d22
AS
17268 { ac_try='test -z "$ac_c_werror_flag"
17269 || test ! -s conftest.err'
17270 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17271 (eval $ac_try) 2>&5
17272 ac_status=$?
17273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17274 (exit $ac_status); }; } &&
17275 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17276 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17277 (eval $ac_try) 2>&5
17278 ac_status=$?
c0d27fcc 17279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17280 (exit $ac_status); }; }; then
17281 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
17282else
17283 echo "$as_me: failed program was:" >&5
19650fd6
AS
17284sed 's/^/| /' conftest.$ac_ext >&5
17285
503d2be0
AS
17286ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
17287fi
35996d22
AS
17288rm -f conftest.err conftest.$ac_objext \
17289 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17290LIBS=$ac_check_lib_save_LIBS
17291fi
c0d27fcc 17292echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17293echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
17294if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17295 cat >>confdefs.h <<_ACEOF
503d2be0 17296#define HAVE_LIBK5CRYPTO 1
c0d27fcc 17297_ACEOF
a21616bd
KR
17298
17299 LIBS="-lk5crypto $LIBS"
17300
a21616bd
KR
17301fi
17302
c0d27fcc
MR
17303
17304echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
17305echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
17306if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
17307 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17308else
503d2be0 17309 ac_check_lib_save_LIBS=$LIBS
a21616bd 17310LIBS="-lcrypto $LIBS"
503d2be0 17311cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17312/* confdefs.h. */
17313_ACEOF
17314cat confdefs.h >>conftest.$ac_ext
17315cat >>conftest.$ac_ext <<_ACEOF
17316/* end confdefs.h. */
503d2be0 17317
a21616bd 17318/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17319#ifdef __cplusplus
17320extern "C"
17321#endif
a21616bd 17322/* We use char because int might match the return type of a gcc2
503d2be0
AS
17323 builtin and then its argument prototype would still apply. */
17324char mit_des_cbc_encrypt ();
17325int
17326main ()
17327{
17328mit_des_cbc_encrypt ();
17329 ;
17330 return 0;
17331}
17332_ACEOF
17333rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17334if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17335 (eval $ac_link) 2>conftest.er1
503d2be0 17336 ac_status=$?
35996d22
AS
17337 grep -v '^ *+' conftest.er1 >conftest.err
17338 rm -f conftest.er1
17339 cat conftest.err >&5
c0d27fcc 17340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17341 (exit $ac_status); } &&
35996d22
AS
17342 { ac_try='test -z "$ac_c_werror_flag"
17343 || test ! -s conftest.err'
17344 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17345 (eval $ac_try) 2>&5
17346 ac_status=$?
17347 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17348 (exit $ac_status); }; } &&
17349 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17350 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17351 (eval $ac_try) 2>&5
17352 ac_status=$?
c0d27fcc 17353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17354 (exit $ac_status); }; }; then
17355 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
17356else
17357 echo "$as_me: failed program was:" >&5
19650fd6
AS
17358sed 's/^/| /' conftest.$ac_ext >&5
17359
503d2be0
AS
17360ac_cv_lib_crypto_mit_des_cbc_encrypt=no
17361fi
35996d22
AS
17362rm -f conftest.err conftest.$ac_objext \
17363 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17364LIBS=$ac_check_lib_save_LIBS
17365fi
c0d27fcc 17366echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17367echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
17368if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17369 cat >>confdefs.h <<_ACEOF
503d2be0 17370#define HAVE_LIBCRYPTO 1
c0d27fcc 17371_ACEOF
a21616bd
KR
17372
17373 LIBS="-lcrypto $LIBS"
17374
a21616bd
KR
17375fi
17376
c0d27fcc
MR
17377
17378echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
17379echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
17380if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
17381 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17382else
503d2be0 17383 ac_check_lib_save_LIBS=$LIBS
a21616bd 17384LIBS="-lkrb5 $LIBS"
503d2be0 17385cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17386/* confdefs.h. */
17387_ACEOF
17388cat confdefs.h >>conftest.$ac_ext
17389cat >>conftest.$ac_ext <<_ACEOF
17390/* end confdefs.h. */
a21616bd 17391
503d2be0
AS
17392/* Override any gcc2 internal prototype to avoid an error. */
17393#ifdef __cplusplus
17394extern "C"
17395#endif
17396/* We use char because int might match the return type of a gcc2
17397 builtin and then its argument prototype would still apply. */
17398char krb5_init_context ();
17399int
17400main ()
17401{
17402krb5_init_context ();
17403 ;
17404 return 0;
17405}
17406_ACEOF
17407rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17408if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17409 (eval $ac_link) 2>conftest.er1
503d2be0 17410 ac_status=$?
35996d22
AS
17411 grep -v '^ *+' conftest.er1 >conftest.err
17412 rm -f conftest.er1
17413 cat conftest.err >&5
c0d27fcc 17414 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17415 (exit $ac_status); } &&
35996d22
AS
17416 { ac_try='test -z "$ac_c_werror_flag"
17417 || test ! -s conftest.err'
17418 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17419 (eval $ac_try) 2>&5
17420 ac_status=$?
17421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17422 (exit $ac_status); }; } &&
17423 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17424 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17425 (eval $ac_try) 2>&5
17426 ac_status=$?
c0d27fcc 17427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17428 (exit $ac_status); }; }; then
17429 ac_cv_lib_krb5_krb5_init_context=yes
17430else
17431 echo "$as_me: failed program was:" >&5
19650fd6
AS
17432sed 's/^/| /' conftest.$ac_ext >&5
17433
503d2be0
AS
17434ac_cv_lib_krb5_krb5_init_context=no
17435fi
35996d22
AS
17436rm -f conftest.err conftest.$ac_objext \
17437 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17438LIBS=$ac_check_lib_save_LIBS
17439fi
c0d27fcc 17440echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
17441echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
17442if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 17443 cat >>confdefs.h <<_ACEOF
503d2be0 17444#define HAVE_LIBKRB5 1
c0d27fcc 17445_ACEOF
a21616bd
KR
17446
17447 LIBS="-lkrb5 $LIBS"
17448
a21616bd
KR
17449fi
17450
17451 if test "${with_kerberos5+set}" != set; then
503d2be0 17452
c0d27fcc 17453echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
17454echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
17455if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
17456 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17457else
503d2be0 17458 ac_check_lib_save_LIBS=$LIBS
a21616bd 17459LIBS="-ldes425 $LIBS"
503d2be0 17460cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17461/* confdefs.h. */
17462_ACEOF
17463cat confdefs.h >>conftest.$ac_ext
17464cat >>conftest.$ac_ext <<_ACEOF
17465/* end confdefs.h. */
503d2be0 17466
a21616bd 17467/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17468#ifdef __cplusplus
17469extern "C"
17470#endif
a21616bd 17471/* We use char because int might match the return type of a gcc2
503d2be0
AS
17472 builtin and then its argument prototype would still apply. */
17473char des_cbc_encrypt ();
17474int
17475main ()
17476{
17477des_cbc_encrypt ();
17478 ;
17479 return 0;
17480}
17481_ACEOF
17482rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17483if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17484 (eval $ac_link) 2>conftest.er1
503d2be0 17485 ac_status=$?
35996d22
AS
17486 grep -v '^ *+' conftest.er1 >conftest.err
17487 rm -f conftest.er1
17488 cat conftest.err >&5
c0d27fcc 17489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17490 (exit $ac_status); } &&
35996d22
AS
17491 { ac_try='test -z "$ac_c_werror_flag"
17492 || test ! -s conftest.err'
17493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17494 (eval $ac_try) 2>&5
17495 ac_status=$?
17496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17497 (exit $ac_status); }; } &&
17498 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17499 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17500 (eval $ac_try) 2>&5
17501 ac_status=$?
c0d27fcc 17502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17503 (exit $ac_status); }; }; then
17504 ac_cv_lib_des425_des_cbc_encrypt=yes
17505else
17506 echo "$as_me: failed program was:" >&5
19650fd6
AS
17507sed 's/^/| /' conftest.$ac_ext >&5
17508
503d2be0
AS
17509ac_cv_lib_des425_des_cbc_encrypt=no
17510fi
35996d22
AS
17511rm -f conftest.err conftest.$ac_objext \
17512 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17513LIBS=$ac_check_lib_save_LIBS
17514fi
c0d27fcc 17515echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
17516echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
17517if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 17518 cat >>confdefs.h <<_ACEOF
503d2be0 17519#define HAVE_LIBDES425 1
c0d27fcc 17520_ACEOF
a21616bd
KR
17521
17522 LIBS="-ldes425 $LIBS"
17523
17524else
503d2be0 17525
c0d27fcc 17526echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
17527echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
17528if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
17529 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17530else
503d2be0 17531 ac_check_lib_save_LIBS=$LIBS
a21616bd 17532LIBS="-ldes $LIBS"
503d2be0 17533cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17534/* confdefs.h. */
17535_ACEOF
17536cat confdefs.h >>conftest.$ac_ext
17537cat >>conftest.$ac_ext <<_ACEOF
17538/* end confdefs.h. */
503d2be0 17539
a21616bd 17540/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17541#ifdef __cplusplus
17542extern "C"
17543#endif
a21616bd 17544/* We use char because int might match the return type of a gcc2
503d2be0
AS
17545 builtin and then its argument prototype would still apply. */
17546char des_cbc_encrypt ();
17547int
17548main ()
17549{
17550des_cbc_encrypt ();
17551 ;
17552 return 0;
17553}
17554_ACEOF
17555rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17556if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17557 (eval $ac_link) 2>conftest.er1
503d2be0 17558 ac_status=$?
35996d22
AS
17559 grep -v '^ *+' conftest.er1 >conftest.err
17560 rm -f conftest.er1
17561 cat conftest.err >&5
c0d27fcc 17562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17563 (exit $ac_status); } &&
35996d22
AS
17564 { ac_try='test -z "$ac_c_werror_flag"
17565 || test ! -s conftest.err'
17566 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17567 (eval $ac_try) 2>&5
17568 ac_status=$?
17569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17570 (exit $ac_status); }; } &&
17571 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17572 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17573 (eval $ac_try) 2>&5
17574 ac_status=$?
c0d27fcc 17575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17576 (exit $ac_status); }; }; then
17577 ac_cv_lib_des_des_cbc_encrypt=yes
17578else
17579 echo "$as_me: failed program was:" >&5
19650fd6
AS
17580sed 's/^/| /' conftest.$ac_ext >&5
17581
503d2be0
AS
17582ac_cv_lib_des_des_cbc_encrypt=no
17583fi
35996d22
AS
17584rm -f conftest.err conftest.$ac_objext \
17585 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17586LIBS=$ac_check_lib_save_LIBS
17587fi
c0d27fcc 17588echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
17589echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
17590if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 17591 cat >>confdefs.h <<_ACEOF
503d2be0 17592#define HAVE_LIBDES 1
c0d27fcc 17593_ACEOF
a21616bd
KR
17594
17595 LIBS="-ldes $LIBS"
17596
a21616bd
KR
17597fi
17598
17599fi
17600
c0d27fcc
MR
17601
17602echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
17603echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
17604if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
17605 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17606else
503d2be0 17607 ac_check_lib_save_LIBS=$LIBS
a21616bd 17608LIBS="-lkrb4 $LIBS"
503d2be0 17609cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17610/* confdefs.h. */
17611_ACEOF
17612cat confdefs.h >>conftest.$ac_ext
17613cat >>conftest.$ac_ext <<_ACEOF
17614/* end confdefs.h. */
503d2be0 17615
a21616bd 17616/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17617#ifdef __cplusplus
17618extern "C"
17619#endif
a21616bd 17620/* We use char because int might match the return type of a gcc2
503d2be0
AS
17621 builtin and then its argument prototype would still apply. */
17622char krb_get_cred ();
17623int
17624main ()
17625{
17626krb_get_cred ();
17627 ;
17628 return 0;
17629}
17630_ACEOF
17631rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17632if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17633 (eval $ac_link) 2>conftest.er1
503d2be0 17634 ac_status=$?
35996d22
AS
17635 grep -v '^ *+' conftest.er1 >conftest.err
17636 rm -f conftest.er1
17637 cat conftest.err >&5
c0d27fcc 17638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17639 (exit $ac_status); } &&
35996d22
AS
17640 { ac_try='test -z "$ac_c_werror_flag"
17641 || test ! -s conftest.err'
17642 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17643 (eval $ac_try) 2>&5
17644 ac_status=$?
17645 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17646 (exit $ac_status); }; } &&
17647 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17648 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17649 (eval $ac_try) 2>&5
17650 ac_status=$?
c0d27fcc 17651 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17652 (exit $ac_status); }; }; then
17653 ac_cv_lib_krb4_krb_get_cred=yes
17654else
17655 echo "$as_me: failed program was:" >&5
19650fd6
AS
17656sed 's/^/| /' conftest.$ac_ext >&5
17657
503d2be0
AS
17658ac_cv_lib_krb4_krb_get_cred=no
17659fi
35996d22
AS
17660rm -f conftest.err conftest.$ac_objext \
17661 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17662LIBS=$ac_check_lib_save_LIBS
17663fi
c0d27fcc 17664echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
17665echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
17666if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 17667 cat >>confdefs.h <<_ACEOF
503d2be0 17668#define HAVE_LIBKRB4 1
c0d27fcc 17669_ACEOF
a21616bd
KR
17670
17671 LIBS="-lkrb4 $LIBS"
17672
17673else
503d2be0 17674
c0d27fcc 17675echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
17676echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
17677if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
17678 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17679else
503d2be0 17680 ac_check_lib_save_LIBS=$LIBS
a21616bd 17681LIBS="-lkrb $LIBS"
503d2be0 17682cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17683/* confdefs.h. */
17684_ACEOF
17685cat confdefs.h >>conftest.$ac_ext
17686cat >>conftest.$ac_ext <<_ACEOF
17687/* end confdefs.h. */
503d2be0 17688
a21616bd 17689/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17690#ifdef __cplusplus
17691extern "C"
17692#endif
a21616bd 17693/* We use char because int might match the return type of a gcc2
503d2be0
AS
17694 builtin and then its argument prototype would still apply. */
17695char krb_get_cred ();
17696int
17697main ()
17698{
17699krb_get_cred ();
17700 ;
17701 return 0;
17702}
17703_ACEOF
17704rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17705if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17706 (eval $ac_link) 2>conftest.er1
503d2be0 17707 ac_status=$?
35996d22
AS
17708 grep -v '^ *+' conftest.er1 >conftest.err
17709 rm -f conftest.er1
17710 cat conftest.err >&5
c0d27fcc 17711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17712 (exit $ac_status); } &&
35996d22
AS
17713 { ac_try='test -z "$ac_c_werror_flag"
17714 || test ! -s conftest.err'
17715 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17716 (eval $ac_try) 2>&5
17717 ac_status=$?
17718 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17719 (exit $ac_status); }; } &&
17720 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17721 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17722 (eval $ac_try) 2>&5
17723 ac_status=$?
c0d27fcc 17724 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17725 (exit $ac_status); }; }; then
17726 ac_cv_lib_krb_krb_get_cred=yes
17727else
17728 echo "$as_me: failed program was:" >&5
19650fd6
AS
17729sed 's/^/| /' conftest.$ac_ext >&5
17730
503d2be0
AS
17731ac_cv_lib_krb_krb_get_cred=no
17732fi
35996d22
AS
17733rm -f conftest.err conftest.$ac_objext \
17734 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17735LIBS=$ac_check_lib_save_LIBS
17736fi
c0d27fcc 17737echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
17738echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
17739if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 17740 cat >>confdefs.h <<_ACEOF
503d2be0 17741#define HAVE_LIBKRB 1
c0d27fcc 17742_ACEOF
a21616bd
KR
17743
17744 LIBS="-lkrb $LIBS"
17745
a21616bd
KR
17746fi
17747
17748fi
17749
17750 fi
17751
17752 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
17753
17754for ac_header in krb5.h
a21616bd 17755do
503d2be0 17756as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17757if eval "test \"\${$as_ac_Header+set}\" = set"; then
17758 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17759echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17760if eval "test \"\${$as_ac_Header+set}\" = set"; then
17761 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17762fi
17763echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17764echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17765else
c0d27fcc
MR
17766 # Is the header compilable?
17767echo "$as_me:$LINENO: checking $ac_header usability" >&5
17768echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17769cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17770/* confdefs.h. */
17771_ACEOF
17772cat confdefs.h >>conftest.$ac_ext
17773cat >>conftest.$ac_ext <<_ACEOF
17774/* end confdefs.h. */
c0d27fcc
MR
17775$ac_includes_default
17776#include <$ac_header>
17777_ACEOF
17778rm -f conftest.$ac_objext
17779if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 17780 (eval $ac_compile) 2>conftest.er1
c0d27fcc 17781 ac_status=$?
35996d22
AS
17782 grep -v '^ *+' conftest.er1 >conftest.err
17783 rm -f conftest.er1
17784 cat conftest.err >&5
c0d27fcc
MR
17785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17786 (exit $ac_status); } &&
35996d22
AS
17787 { ac_try='test -z "$ac_c_werror_flag"
17788 || test ! -s conftest.err'
17789 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17790 (eval $ac_try) 2>&5
17791 ac_status=$?
17792 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17793 (exit $ac_status); }; } &&
17794 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17795 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17796 (eval $ac_try) 2>&5
17797 ac_status=$?
17798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17799 (exit $ac_status); }; }; then
17800 ac_header_compiler=yes
17801else
17802 echo "$as_me: failed program was:" >&5
19650fd6
AS
17803sed 's/^/| /' conftest.$ac_ext >&5
17804
c0d27fcc
MR
17805ac_header_compiler=no
17806fi
35996d22 17807rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17808echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17809echo "${ECHO_T}$ac_header_compiler" >&6
17810
17811# Is the header present?
17812echo "$as_me:$LINENO: checking $ac_header presence" >&5
17813echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
17820#include <$ac_header>
17821_ACEOF
c0d27fcc 17822if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17823 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17824 ac_status=$?
6bae0ccf 17825 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17826 rm -f conftest.er1
17827 cat conftest.err >&5
c0d27fcc 17828 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17829 (exit $ac_status); } >/dev/null; then
17830 if test -s conftest.err; then
17831 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 17832 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
17833 else
17834 ac_cpp_err=
17835 fi
17836else
17837 ac_cpp_err=yes
17838fi
17839if test -z "$ac_cpp_err"; then
c0d27fcc 17840 ac_header_preproc=yes
503d2be0
AS
17841else
17842 echo "$as_me: failed program was:" >&5
19650fd6
AS
17843sed 's/^/| /' conftest.$ac_ext >&5
17844
c0d27fcc 17845 ac_header_preproc=no
a21616bd 17846fi
503d2be0 17847rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17848echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17849echo "${ECHO_T}$ac_header_preproc" >&6
17850
17851# So? What about this header?
35996d22
AS
17852case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17853 yes:no: )
c0d27fcc
MR
17854 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17855echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
17856 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17857echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17858 ac_header_preproc=yes
19650fd6 17859 ;;
35996d22 17860 no:yes:* )
c0d27fcc
MR
17861 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17862echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
17863 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17864echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17865 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17866echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17867 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
17868echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 17869 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17870echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
17871 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17872echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
17873 (
17874 cat <<\_ASBOX
35996d22
AS
17875## ------------------------------------------ ##
17876## Report this to the AC_PACKAGE_NAME lists. ##
17877## ------------------------------------------ ##
19650fd6
AS
17878_ASBOX
17879 ) |
17880 sed "s/^/$as_me: WARNING: /" >&2
17881 ;;
c0d27fcc
MR
17882esac
17883echo "$as_me:$LINENO: checking for $ac_header" >&5
17884echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17885if eval "test \"\${$as_ac_Header+set}\" = set"; then
17886 echo $ECHO_N "(cached) $ECHO_C" >&6
17887else
35996d22 17888 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 17889fi
c0d27fcc 17890echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17891echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17892
17893fi
503d2be0 17894if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17895 cat >>confdefs.h <<_ACEOF
503d2be0 17896#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17897_ACEOF
503d2be0 17898
a21616bd 17899fi
c0d27fcc 17900
a21616bd
KR
17901done
17902
17903 else
503d2be0
AS
17904
17905for ac_header in des.h
a21616bd 17906do
503d2be0 17907as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17908if eval "test \"\${$as_ac_Header+set}\" = set"; then
17909 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17910echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17911if eval "test \"\${$as_ac_Header+set}\" = set"; then
17912 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17913fi
17914echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17915echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17916else
c0d27fcc
MR
17917 # Is the header compilable?
17918echo "$as_me:$LINENO: checking $ac_header usability" >&5
17919echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17920cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17921/* confdefs.h. */
17922_ACEOF
17923cat confdefs.h >>conftest.$ac_ext
17924cat >>conftest.$ac_ext <<_ACEOF
17925/* end confdefs.h. */
c0d27fcc
MR
17926$ac_includes_default
17927#include <$ac_header>
17928_ACEOF
17929rm -f conftest.$ac_objext
17930if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 17931 (eval $ac_compile) 2>conftest.er1
c0d27fcc 17932 ac_status=$?
35996d22
AS
17933 grep -v '^ *+' conftest.er1 >conftest.err
17934 rm -f conftest.er1
17935 cat conftest.err >&5
c0d27fcc
MR
17936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17937 (exit $ac_status); } &&
35996d22
AS
17938 { ac_try='test -z "$ac_c_werror_flag"
17939 || test ! -s conftest.err'
17940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17941 (eval $ac_try) 2>&5
17942 ac_status=$?
17943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17944 (exit $ac_status); }; } &&
17945 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17946 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17947 (eval $ac_try) 2>&5
17948 ac_status=$?
17949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17950 (exit $ac_status); }; }; then
17951 ac_header_compiler=yes
17952else
17953 echo "$as_me: failed program was:" >&5
19650fd6
AS
17954sed 's/^/| /' conftest.$ac_ext >&5
17955
c0d27fcc
MR
17956ac_header_compiler=no
17957fi
35996d22 17958rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17959echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17960echo "${ECHO_T}$ac_header_compiler" >&6
17961
17962# Is the header present?
17963echo "$as_me:$LINENO: checking $ac_header presence" >&5
17964echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
17971#include <$ac_header>
17972_ACEOF
c0d27fcc 17973if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17974 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17975 ac_status=$?
6bae0ccf 17976 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17977 rm -f conftest.er1
17978 cat conftest.err >&5
c0d27fcc 17979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17980 (exit $ac_status); } >/dev/null; then
17981 if test -s conftest.err; then
17982 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 17983 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
17984 else
17985 ac_cpp_err=
17986 fi
17987else
17988 ac_cpp_err=yes
17989fi
17990if test -z "$ac_cpp_err"; then
c0d27fcc 17991 ac_header_preproc=yes
503d2be0
AS
17992else
17993 echo "$as_me: failed program was:" >&5
19650fd6
AS
17994sed 's/^/| /' conftest.$ac_ext >&5
17995
c0d27fcc 17996 ac_header_preproc=no
a21616bd 17997fi
503d2be0 17998rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17999echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18000echo "${ECHO_T}$ac_header_preproc" >&6
18001
18002# So? What about this header?
35996d22
AS
18003case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18004 yes:no: )
c0d27fcc
MR
18005 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18006echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18007 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18008echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18009 ac_header_preproc=yes
19650fd6 18010 ;;
35996d22 18011 no:yes:* )
c0d27fcc
MR
18012 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18013echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18014 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18015echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18016 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18017echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18018 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18019echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18020 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18021echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18022 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18023echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18024 (
18025 cat <<\_ASBOX
35996d22
AS
18026## ------------------------------------------ ##
18027## Report this to the AC_PACKAGE_NAME lists. ##
18028## ------------------------------------------ ##
19650fd6
AS
18029_ASBOX
18030 ) |
18031 sed "s/^/$as_me: WARNING: /" >&2
18032 ;;
c0d27fcc
MR
18033esac
18034echo "$as_me:$LINENO: checking for $ac_header" >&5
18035echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18036if eval "test \"\${$as_ac_Header+set}\" = set"; then
18037 echo $ECHO_N "(cached) $ECHO_C" >&6
18038else
35996d22 18039 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18040fi
c0d27fcc 18041echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18042echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18043
18044fi
503d2be0 18045if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18046 cat >>confdefs.h <<_ACEOF
503d2be0 18047#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18048_ACEOF
503d2be0 18049
a21616bd 18050else
503d2be0
AS
18051
18052for ac_header in kerberosIV/des.h
a21616bd 18053do
503d2be0 18054as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18055if eval "test \"\${$as_ac_Header+set}\" = set"; then
18056 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18057echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18058if eval "test \"\${$as_ac_Header+set}\" = set"; then
18059 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18060fi
18061echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18062echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18063else
c0d27fcc
MR
18064 # Is the header compilable?
18065echo "$as_me:$LINENO: checking $ac_header usability" >&5
18066echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18067cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18068/* confdefs.h. */
18069_ACEOF
18070cat confdefs.h >>conftest.$ac_ext
18071cat >>conftest.$ac_ext <<_ACEOF
18072/* end confdefs.h. */
c0d27fcc
MR
18073$ac_includes_default
18074#include <$ac_header>
18075_ACEOF
18076rm -f conftest.$ac_objext
18077if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18078 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18079 ac_status=$?
35996d22
AS
18080 grep -v '^ *+' conftest.er1 >conftest.err
18081 rm -f conftest.er1
18082 cat conftest.err >&5
c0d27fcc
MR
18083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18084 (exit $ac_status); } &&
35996d22
AS
18085 { ac_try='test -z "$ac_c_werror_flag"
18086 || test ! -s conftest.err'
18087 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18088 (eval $ac_try) 2>&5
18089 ac_status=$?
18090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18091 (exit $ac_status); }; } &&
18092 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18094 (eval $ac_try) 2>&5
18095 ac_status=$?
18096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18097 (exit $ac_status); }; }; then
18098 ac_header_compiler=yes
18099else
18100 echo "$as_me: failed program was:" >&5
19650fd6
AS
18101sed 's/^/| /' conftest.$ac_ext >&5
18102
c0d27fcc
MR
18103ac_header_compiler=no
18104fi
35996d22 18105rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18106echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18107echo "${ECHO_T}$ac_header_compiler" >&6
18108
18109# Is the header present?
18110echo "$as_me:$LINENO: checking $ac_header presence" >&5
18111echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18118#include <$ac_header>
18119_ACEOF
c0d27fcc 18120if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18121 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18122 ac_status=$?
6bae0ccf 18123 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18124 rm -f conftest.er1
18125 cat conftest.err >&5
c0d27fcc 18126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18127 (exit $ac_status); } >/dev/null; then
18128 if test -s conftest.err; then
18129 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18130 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18131 else
18132 ac_cpp_err=
18133 fi
18134else
18135 ac_cpp_err=yes
18136fi
18137if test -z "$ac_cpp_err"; then
c0d27fcc 18138 ac_header_preproc=yes
503d2be0
AS
18139else
18140 echo "$as_me: failed program was:" >&5
19650fd6
AS
18141sed 's/^/| /' conftest.$ac_ext >&5
18142
c0d27fcc 18143 ac_header_preproc=no
a21616bd 18144fi
503d2be0 18145rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18146echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18147echo "${ECHO_T}$ac_header_preproc" >&6
18148
18149# So? What about this header?
35996d22
AS
18150case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18151 yes:no: )
c0d27fcc
MR
18152 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18153echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18154 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18155echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18156 ac_header_preproc=yes
19650fd6 18157 ;;
35996d22 18158 no:yes:* )
c0d27fcc
MR
18159 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18160echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18161 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18162echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18163 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18164echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18165 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18166echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18167 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18168echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18169 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18170echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18171 (
18172 cat <<\_ASBOX
35996d22
AS
18173## ------------------------------------------ ##
18174## Report this to the AC_PACKAGE_NAME lists. ##
18175## ------------------------------------------ ##
19650fd6
AS
18176_ASBOX
18177 ) |
18178 sed "s/^/$as_me: WARNING: /" >&2
18179 ;;
c0d27fcc
MR
18180esac
18181echo "$as_me:$LINENO: checking for $ac_header" >&5
18182echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18183if eval "test \"\${$as_ac_Header+set}\" = set"; then
18184 echo $ECHO_N "(cached) $ECHO_C" >&6
18185else
35996d22 18186 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18187fi
c0d27fcc 18188echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18189echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18190
18191fi
503d2be0 18192if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18193 cat >>confdefs.h <<_ACEOF
503d2be0 18194#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18195_ACEOF
503d2be0 18196
a21616bd 18197else
503d2be0
AS
18198
18199for ac_header in kerberos/des.h
a21616bd 18200do
503d2be0 18201as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18202if eval "test \"\${$as_ac_Header+set}\" = set"; then
18203 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18204echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18205if eval "test \"\${$as_ac_Header+set}\" = set"; then
18206 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18207fi
18208echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18209echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18210else
c0d27fcc
MR
18211 # Is the header compilable?
18212echo "$as_me:$LINENO: checking $ac_header usability" >&5
18213echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18214cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18215/* confdefs.h. */
18216_ACEOF
18217cat confdefs.h >>conftest.$ac_ext
18218cat >>conftest.$ac_ext <<_ACEOF
18219/* end confdefs.h. */
c0d27fcc
MR
18220$ac_includes_default
18221#include <$ac_header>
18222_ACEOF
18223rm -f conftest.$ac_objext
18224if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18225 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18226 ac_status=$?
35996d22
AS
18227 grep -v '^ *+' conftest.er1 >conftest.err
18228 rm -f conftest.er1
18229 cat conftest.err >&5
c0d27fcc
MR
18230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18231 (exit $ac_status); } &&
35996d22
AS
18232 { ac_try='test -z "$ac_c_werror_flag"
18233 || test ! -s conftest.err'
18234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18235 (eval $ac_try) 2>&5
18236 ac_status=$?
18237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18238 (exit $ac_status); }; } &&
18239 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18241 (eval $ac_try) 2>&5
18242 ac_status=$?
18243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18244 (exit $ac_status); }; }; then
18245 ac_header_compiler=yes
18246else
18247 echo "$as_me: failed program was:" >&5
19650fd6
AS
18248sed 's/^/| /' conftest.$ac_ext >&5
18249
c0d27fcc
MR
18250ac_header_compiler=no
18251fi
35996d22 18252rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18253echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18254echo "${ECHO_T}$ac_header_compiler" >&6
18255
18256# Is the header present?
18257echo "$as_me:$LINENO: checking $ac_header presence" >&5
18258echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18265#include <$ac_header>
18266_ACEOF
c0d27fcc 18267if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18268 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18269 ac_status=$?
6bae0ccf 18270 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18271 rm -f conftest.er1
18272 cat conftest.err >&5
c0d27fcc 18273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18274 (exit $ac_status); } >/dev/null; then
18275 if test -s conftest.err; then
18276 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18277 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18278 else
18279 ac_cpp_err=
18280 fi
18281else
18282 ac_cpp_err=yes
18283fi
18284if test -z "$ac_cpp_err"; then
c0d27fcc 18285 ac_header_preproc=yes
503d2be0
AS
18286else
18287 echo "$as_me: failed program was:" >&5
19650fd6
AS
18288sed 's/^/| /' conftest.$ac_ext >&5
18289
c0d27fcc 18290 ac_header_preproc=no
a21616bd 18291fi
503d2be0 18292rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18293echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18294echo "${ECHO_T}$ac_header_preproc" >&6
18295
18296# So? What about this header?
35996d22
AS
18297case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18298 yes:no: )
c0d27fcc
MR
18299 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18300echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18301 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18302echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18303 ac_header_preproc=yes
19650fd6 18304 ;;
35996d22 18305 no:yes:* )
c0d27fcc
MR
18306 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18307echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18308 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18309echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18310 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18311echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18312 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18313echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18314 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18315echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18316 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18317echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18318 (
18319 cat <<\_ASBOX
35996d22
AS
18320## ------------------------------------------ ##
18321## Report this to the AC_PACKAGE_NAME lists. ##
18322## ------------------------------------------ ##
19650fd6
AS
18323_ASBOX
18324 ) |
18325 sed "s/^/$as_me: WARNING: /" >&2
18326 ;;
c0d27fcc
MR
18327esac
18328echo "$as_me:$LINENO: checking for $ac_header" >&5
18329echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18330if eval "test \"\${$as_ac_Header+set}\" = set"; then
18331 echo $ECHO_N "(cached) $ECHO_C" >&6
18332else
35996d22 18333 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18334fi
c0d27fcc 18335echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18336echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18337
18338fi
503d2be0 18339if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18340 cat >>confdefs.h <<_ACEOF
503d2be0 18341#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18342_ACEOF
a21616bd
KR
18343
18344fi
c0d27fcc 18345
a21616bd
KR
18346done
18347
98418dba 18348fi
c0d27fcc 18349
925c2f3f
EZ
18350done
18351
98418dba 18352fi
c0d27fcc 18353
925c2f3f 18354done
98418dba 18355
c0d27fcc 18356
925c2f3f
EZ
18357for ac_header in krb.h
18358do
18359as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18360if eval "test \"\${$as_ac_Header+set}\" = set"; then
18361 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
18362echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18363if eval "test \"\${$as_ac_Header+set}\" = set"; then
18364 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18365fi
18366echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18367echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18368else
18369 # Is the header compilable?
18370echo "$as_me:$LINENO: checking $ac_header usability" >&5
18371echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18372cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18373/* confdefs.h. */
18374_ACEOF
18375cat confdefs.h >>conftest.$ac_ext
18376cat >>conftest.$ac_ext <<_ACEOF
18377/* end confdefs.h. */
c0d27fcc
MR
18378$ac_includes_default
18379#include <$ac_header>
18380_ACEOF
18381rm -f conftest.$ac_objext
18382if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18383 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18384 ac_status=$?
35996d22
AS
18385 grep -v '^ *+' conftest.er1 >conftest.err
18386 rm -f conftest.er1
18387 cat conftest.err >&5
c0d27fcc
MR
18388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18389 (exit $ac_status); } &&
35996d22
AS
18390 { ac_try='test -z "$ac_c_werror_flag"
18391 || test ! -s conftest.err'
18392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18393 (eval $ac_try) 2>&5
18394 ac_status=$?
18395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18396 (exit $ac_status); }; } &&
18397 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18398 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18399 (eval $ac_try) 2>&5
18400 ac_status=$?
18401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18402 (exit $ac_status); }; }; then
18403 ac_header_compiler=yes
925c2f3f 18404else
c0d27fcc 18405 echo "$as_me: failed program was:" >&5
19650fd6
AS
18406sed 's/^/| /' conftest.$ac_ext >&5
18407
c0d27fcc
MR
18408ac_header_compiler=no
18409fi
35996d22 18410rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18411echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18412echo "${ECHO_T}$ac_header_compiler" >&6
18413
18414# Is the header present?
18415echo "$as_me:$LINENO: checking $ac_header presence" >&5
18416echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18423#include <$ac_header>
18424_ACEOF
c0d27fcc 18425if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18426 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18427 ac_status=$?
6bae0ccf 18428 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18429 rm -f conftest.er1
18430 cat conftest.err >&5
c0d27fcc 18431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18432 (exit $ac_status); } >/dev/null; then
18433 if test -s conftest.err; then
18434 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18435 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18436 else
18437 ac_cpp_err=
18438 fi
18439else
18440 ac_cpp_err=yes
18441fi
18442if test -z "$ac_cpp_err"; then
c0d27fcc 18443 ac_header_preproc=yes
503d2be0
AS
18444else
18445 echo "$as_me: failed program was:" >&5
19650fd6
AS
18446sed 's/^/| /' conftest.$ac_ext >&5
18447
c0d27fcc 18448 ac_header_preproc=no
a21616bd 18449fi
503d2be0 18450rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18451echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18452echo "${ECHO_T}$ac_header_preproc" >&6
18453
18454# So? What about this header?
35996d22
AS
18455case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18456 yes:no: )
c0d27fcc
MR
18457 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18458echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18459 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18460echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18461 ac_header_preproc=yes
19650fd6 18462 ;;
35996d22 18463 no:yes:* )
c0d27fcc
MR
18464 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18465echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18466 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18467echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18468 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18469echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18470 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18471echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18472 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18473echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18474 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18475echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18476 (
18477 cat <<\_ASBOX
35996d22
AS
18478## ------------------------------------------ ##
18479## Report this to the AC_PACKAGE_NAME lists. ##
18480## ------------------------------------------ ##
19650fd6
AS
18481_ASBOX
18482 ) |
18483 sed "s/^/$as_me: WARNING: /" >&2
18484 ;;
c0d27fcc
MR
18485esac
18486echo "$as_me:$LINENO: checking for $ac_header" >&5
18487echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18488if eval "test \"\${$as_ac_Header+set}\" = set"; then
18489 echo $ECHO_N "(cached) $ECHO_C" >&6
18490else
35996d22 18491 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18492fi
c0d27fcc 18493echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18494echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18495
18496fi
503d2be0 18497if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18498 cat >>confdefs.h <<_ACEOF
503d2be0 18499#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18500_ACEOF
503d2be0 18501
a21616bd 18502else
503d2be0
AS
18503
18504for ac_header in kerberosIV/krb.h
a21616bd 18505do
503d2be0 18506as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18507if eval "test \"\${$as_ac_Header+set}\" = set"; then
18508 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18509echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18510if eval "test \"\${$as_ac_Header+set}\" = set"; then
18511 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18512fi
18513echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18514echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18515else
c0d27fcc
MR
18516 # Is the header compilable?
18517echo "$as_me:$LINENO: checking $ac_header usability" >&5
18518echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18519cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18520/* confdefs.h. */
18521_ACEOF
18522cat confdefs.h >>conftest.$ac_ext
18523cat >>conftest.$ac_ext <<_ACEOF
18524/* end confdefs.h. */
c0d27fcc
MR
18525$ac_includes_default
18526#include <$ac_header>
18527_ACEOF
18528rm -f conftest.$ac_objext
18529if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18530 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18531 ac_status=$?
35996d22
AS
18532 grep -v '^ *+' conftest.er1 >conftest.err
18533 rm -f conftest.er1
18534 cat conftest.err >&5
c0d27fcc
MR
18535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18536 (exit $ac_status); } &&
35996d22
AS
18537 { ac_try='test -z "$ac_c_werror_flag"
18538 || test ! -s conftest.err'
18539 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18540 (eval $ac_try) 2>&5
18541 ac_status=$?
18542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18543 (exit $ac_status); }; } &&
18544 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18545 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18546 (eval $ac_try) 2>&5
18547 ac_status=$?
18548 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18549 (exit $ac_status); }; }; then
18550 ac_header_compiler=yes
18551else
18552 echo "$as_me: failed program was:" >&5
19650fd6
AS
18553sed 's/^/| /' conftest.$ac_ext >&5
18554
c0d27fcc
MR
18555ac_header_compiler=no
18556fi
35996d22 18557rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18558echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18559echo "${ECHO_T}$ac_header_compiler" >&6
18560
18561# Is the header present?
18562echo "$as_me:$LINENO: checking $ac_header presence" >&5
18563echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18570#include <$ac_header>
18571_ACEOF
c0d27fcc 18572if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18573 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18574 ac_status=$?
6bae0ccf 18575 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18576 rm -f conftest.er1
18577 cat conftest.err >&5
c0d27fcc 18578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18579 (exit $ac_status); } >/dev/null; then
18580 if test -s conftest.err; then
18581 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18582 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18583 else
18584 ac_cpp_err=
18585 fi
18586else
18587 ac_cpp_err=yes
18588fi
18589if test -z "$ac_cpp_err"; then
c0d27fcc 18590 ac_header_preproc=yes
503d2be0
AS
18591else
18592 echo "$as_me: failed program was:" >&5
19650fd6
AS
18593sed 's/^/| /' conftest.$ac_ext >&5
18594
c0d27fcc 18595 ac_header_preproc=no
a21616bd 18596fi
503d2be0 18597rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18598echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18599echo "${ECHO_T}$ac_header_preproc" >&6
18600
18601# So? What about this header?
35996d22
AS
18602case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18603 yes:no: )
c0d27fcc
MR
18604 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18605echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18606 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18607echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18608 ac_header_preproc=yes
19650fd6 18609 ;;
35996d22 18610 no:yes:* )
c0d27fcc
MR
18611 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18612echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18613 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18614echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18615 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18616echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18617 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18618echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18619 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18620echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18621 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18622echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18623 (
18624 cat <<\_ASBOX
35996d22
AS
18625## ------------------------------------------ ##
18626## Report this to the AC_PACKAGE_NAME lists. ##
18627## ------------------------------------------ ##
19650fd6
AS
18628_ASBOX
18629 ) |
18630 sed "s/^/$as_me: WARNING: /" >&2
18631 ;;
c0d27fcc
MR
18632esac
18633echo "$as_me:$LINENO: checking for $ac_header" >&5
18634echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18635if eval "test \"\${$as_ac_Header+set}\" = set"; then
18636 echo $ECHO_N "(cached) $ECHO_C" >&6
18637else
35996d22 18638 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18639fi
c0d27fcc 18640echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18641echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18642
18643fi
503d2be0 18644if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18645 cat >>confdefs.h <<_ACEOF
503d2be0 18646#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18647_ACEOF
503d2be0 18648
a21616bd 18649else
503d2be0
AS
18650
18651for ac_header in kerberos/krb.h
a21616bd 18652do
503d2be0 18653as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18654if eval "test \"\${$as_ac_Header+set}\" = set"; then
18655 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18656echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18657if eval "test \"\${$as_ac_Header+set}\" = set"; then
18658 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18659fi
18660echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18661echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18662else
c0d27fcc
MR
18663 # Is the header compilable?
18664echo "$as_me:$LINENO: checking $ac_header usability" >&5
18665echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18666cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18667/* confdefs.h. */
18668_ACEOF
18669cat confdefs.h >>conftest.$ac_ext
18670cat >>conftest.$ac_ext <<_ACEOF
18671/* end confdefs.h. */
c0d27fcc
MR
18672$ac_includes_default
18673#include <$ac_header>
18674_ACEOF
18675rm -f conftest.$ac_objext
18676if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18677 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18678 ac_status=$?
35996d22
AS
18679 grep -v '^ *+' conftest.er1 >conftest.err
18680 rm -f conftest.er1
18681 cat conftest.err >&5
c0d27fcc
MR
18682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18683 (exit $ac_status); } &&
35996d22
AS
18684 { ac_try='test -z "$ac_c_werror_flag"
18685 || test ! -s conftest.err'
18686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18687 (eval $ac_try) 2>&5
18688 ac_status=$?
18689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18690 (exit $ac_status); }; } &&
18691 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18692 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18693 (eval $ac_try) 2>&5
18694 ac_status=$?
18695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18696 (exit $ac_status); }; }; then
18697 ac_header_compiler=yes
18698else
18699 echo "$as_me: failed program was:" >&5
19650fd6
AS
18700sed 's/^/| /' conftest.$ac_ext >&5
18701
c0d27fcc
MR
18702ac_header_compiler=no
18703fi
35996d22 18704rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18705echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18706echo "${ECHO_T}$ac_header_compiler" >&6
18707
18708# Is the header present?
18709echo "$as_me:$LINENO: checking $ac_header presence" >&5
18710echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18717#include <$ac_header>
18718_ACEOF
c0d27fcc 18719if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18720 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18721 ac_status=$?
6bae0ccf 18722 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18723 rm -f conftest.er1
18724 cat conftest.err >&5
c0d27fcc 18725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18726 (exit $ac_status); } >/dev/null; then
18727 if test -s conftest.err; then
18728 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18729 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18730 else
18731 ac_cpp_err=
18732 fi
18733else
18734 ac_cpp_err=yes
18735fi
18736if test -z "$ac_cpp_err"; then
c0d27fcc 18737 ac_header_preproc=yes
503d2be0
AS
18738else
18739 echo "$as_me: failed program was:" >&5
19650fd6
AS
18740sed 's/^/| /' conftest.$ac_ext >&5
18741
c0d27fcc 18742 ac_header_preproc=no
a21616bd 18743fi
503d2be0 18744rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18745echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18746echo "${ECHO_T}$ac_header_preproc" >&6
35996d22
AS
18747
18748# So? What about this header?
18749case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18750 yes:no: )
18751 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18752echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18753 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18754echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18755 ac_header_preproc=yes
19650fd6 18756 ;;
35996d22 18757 no:yes:* )
c0d27fcc
MR
18758 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18759echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18760 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18761echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18762 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18763echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18764 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18765echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18766 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18767echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18768 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18769echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18770 (
18771 cat <<\_ASBOX
35996d22
AS
18772## ------------------------------------------ ##
18773## Report this to the AC_PACKAGE_NAME lists. ##
18774## ------------------------------------------ ##
19650fd6
AS
18775_ASBOX
18776 ) |
18777 sed "s/^/$as_me: WARNING: /" >&2
18778 ;;
c0d27fcc
MR
18779esac
18780echo "$as_me:$LINENO: checking for $ac_header" >&5
18781echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18782if eval "test \"\${$as_ac_Header+set}\" = set"; then
18783 echo $ECHO_N "(cached) $ECHO_C" >&6
18784else
35996d22 18785 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18786fi
c0d27fcc 18787echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18788echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18789
18790fi
503d2be0 18791if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18792 cat >>confdefs.h <<_ACEOF
503d2be0 18793#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18794_ACEOF
503d2be0 18795
a21616bd 18796fi
c0d27fcc 18797
a21616bd
KR
18798done
18799
18800fi
c0d27fcc 18801
a21616bd
KR
18802done
18803
18804fi
c0d27fcc 18805
a21616bd
KR
18806done
18807
18808 fi
503d2be0
AS
18809
18810for ac_header in com_err.h
a21616bd 18811do
503d2be0 18812as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18813if eval "test \"\${$as_ac_Header+set}\" = set"; then
18814 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18815echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18816if eval "test \"\${$as_ac_Header+set}\" = set"; then
18817 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18818fi
18819echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18820echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18821else
c0d27fcc
MR
18822 # Is the header compilable?
18823echo "$as_me:$LINENO: checking $ac_header usability" >&5
18824echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18825cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18826/* confdefs.h. */
18827_ACEOF
18828cat confdefs.h >>conftest.$ac_ext
18829cat >>conftest.$ac_ext <<_ACEOF
18830/* end confdefs.h. */
c0d27fcc
MR
18831$ac_includes_default
18832#include <$ac_header>
18833_ACEOF
18834rm -f conftest.$ac_objext
18835if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18836 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18837 ac_status=$?
35996d22
AS
18838 grep -v '^ *+' conftest.er1 >conftest.err
18839 rm -f conftest.er1
18840 cat conftest.err >&5
c0d27fcc
MR
18841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18842 (exit $ac_status); } &&
35996d22
AS
18843 { ac_try='test -z "$ac_c_werror_flag"
18844 || test ! -s conftest.err'
18845 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18846 (eval $ac_try) 2>&5
18847 ac_status=$?
18848 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18849 (exit $ac_status); }; } &&
18850 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18851 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18852 (eval $ac_try) 2>&5
18853 ac_status=$?
18854 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18855 (exit $ac_status); }; }; then
18856 ac_header_compiler=yes
18857else
18858 echo "$as_me: failed program was:" >&5
19650fd6
AS
18859sed 's/^/| /' conftest.$ac_ext >&5
18860
c0d27fcc
MR
18861ac_header_compiler=no
18862fi
35996d22 18863rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18864echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18865echo "${ECHO_T}$ac_header_compiler" >&6
18866
18867# Is the header present?
18868echo "$as_me:$LINENO: checking $ac_header presence" >&5
18869echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
18876#include <$ac_header>
18877_ACEOF
c0d27fcc 18878if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18879 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18880 ac_status=$?
6bae0ccf 18881 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18882 rm -f conftest.er1
18883 cat conftest.err >&5
c0d27fcc 18884 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18885 (exit $ac_status); } >/dev/null; then
18886 if test -s conftest.err; then
18887 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18888 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18889 else
18890 ac_cpp_err=
18891 fi
18892else
18893 ac_cpp_err=yes
18894fi
18895if test -z "$ac_cpp_err"; then
c0d27fcc 18896 ac_header_preproc=yes
503d2be0
AS
18897else
18898 echo "$as_me: failed program was:" >&5
19650fd6
AS
18899sed 's/^/| /' conftest.$ac_ext >&5
18900
c0d27fcc 18901 ac_header_preproc=no
a21616bd 18902fi
503d2be0 18903rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18904echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18905echo "${ECHO_T}$ac_header_preproc" >&6
18906
18907# So? What about this header?
35996d22
AS
18908case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18909 yes:no: )
c0d27fcc
MR
18910 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18911echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18912 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18913echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18914 ac_header_preproc=yes
19650fd6 18915 ;;
35996d22 18916 no:yes:* )
c0d27fcc
MR
18917 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18918echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18919 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18920echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18921 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18922echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18923 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18924echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18925 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18926echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18927 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18928echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18929 (
18930 cat <<\_ASBOX
35996d22
AS
18931## ------------------------------------------ ##
18932## Report this to the AC_PACKAGE_NAME lists. ##
18933## ------------------------------------------ ##
19650fd6
AS
18934_ASBOX
18935 ) |
18936 sed "s/^/$as_me: WARNING: /" >&2
18937 ;;
c0d27fcc
MR
18938esac
18939echo "$as_me:$LINENO: checking for $ac_header" >&5
18940echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18941if eval "test \"\${$as_ac_Header+set}\" = set"; then
18942 echo $ECHO_N "(cached) $ECHO_C" >&6
18943else
35996d22 18944 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18945fi
c0d27fcc 18946echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18947echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18948
18949fi
503d2be0 18950if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18951 cat >>confdefs.h <<_ACEOF
503d2be0 18952#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18953_ACEOF
503d2be0 18954
a21616bd 18955fi
c0d27fcc 18956
a21616bd
KR
18957done
18958
18959fi
18960
ba4481b5
DL
18961# Solaris requires -lintl if you want strerror (which calls dgettext)
18962# to return localized messages.
503d2be0 18963
c0d27fcc 18964echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
18965echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
18966if test "${ac_cv_lib_intl_dgettext+set}" = set; then
18967 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 18968else
503d2be0 18969 ac_check_lib_save_LIBS=$LIBS
ba4481b5 18970LIBS="-lintl $LIBS"
503d2be0 18971cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18972/* confdefs.h. */
18973_ACEOF
18974cat confdefs.h >>conftest.$ac_ext
18975cat >>conftest.$ac_ext <<_ACEOF
18976/* end confdefs.h. */
503d2be0 18977
ba4481b5 18978/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18979#ifdef __cplusplus
18980extern "C"
18981#endif
ba4481b5 18982/* We use char because int might match the return type of a gcc2
503d2be0
AS
18983 builtin and then its argument prototype would still apply. */
18984char dgettext ();
18985int
18986main ()
18987{
18988dgettext ();
18989 ;
18990 return 0;
18991}
18992_ACEOF
18993rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18994if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 18995 (eval $ac_link) 2>conftest.er1
503d2be0 18996 ac_status=$?
35996d22
AS
18997 grep -v '^ *+' conftest.er1 >conftest.err
18998 rm -f conftest.er1
18999 cat conftest.err >&5
c0d27fcc 19000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19001 (exit $ac_status); } &&
35996d22
AS
19002 { ac_try='test -z "$ac_c_werror_flag"
19003 || test ! -s conftest.err'
19004 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19005 (eval $ac_try) 2>&5
19006 ac_status=$?
19007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19008 (exit $ac_status); }; } &&
19009 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19011 (eval $ac_try) 2>&5
19012 ac_status=$?
c0d27fcc 19013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19014 (exit $ac_status); }; }; then
19015 ac_cv_lib_intl_dgettext=yes
19016else
19017 echo "$as_me: failed program was:" >&5
19650fd6
AS
19018sed 's/^/| /' conftest.$ac_ext >&5
19019
503d2be0
AS
19020ac_cv_lib_intl_dgettext=no
19021fi
35996d22
AS
19022rm -f conftest.err conftest.$ac_objext \
19023 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
19024LIBS=$ac_check_lib_save_LIBS
19025fi
c0d27fcc 19026echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
19027echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
19028if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 19029 cat >>confdefs.h <<_ACEOF
503d2be0 19030#define HAVE_LIBINTL 1
c0d27fcc 19031_ACEOF
ba4481b5
DL
19032
19033 LIBS="-lintl $LIBS"
19034
ba4481b5
DL
19035fi
19036
c0d27fcc
MR
19037
19038echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
19039echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
19040if test "${emacs_cv_localtime_cache+set}" = set; then
19041 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
19042else
19043 if test x$ac_cv_func_tzset = xyes; then
19044if test "$cross_compiling" = yes; then
19045 # If we have tzset, assume the worst when cross-compiling.
19046emacs_cv_localtime_cache=yes
19047else
503d2be0 19048 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19049/* confdefs.h. */
19050_ACEOF
19051cat confdefs.h >>conftest.$ac_ext
19052cat >>conftest.$ac_ext <<_ACEOF
19053/* end confdefs.h. */
ba4481b5 19054#include <time.h>
ba4481b5
DL
19055extern char **environ;
19056unset_TZ ()
19057{
19058 char **from, **to;
19059 for (to = from = environ; (*to = *from); from++)
19060 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
19061 to++;
19062}
19063char TZ_GMT0[] = "TZ=GMT0";
19064char TZ_PST8[] = "TZ=PST8";
19065main()
19066{
19067 time_t now = time ((time_t *) 0);
19068 int hour_GMT0, hour_unset;
19069 if (putenv (TZ_GMT0) != 0)
19070 exit (1);
19071 hour_GMT0 = localtime (&now)->tm_hour;
19072 unset_TZ ();
19073 hour_unset = localtime (&now)->tm_hour;
19074 if (putenv (TZ_PST8) != 0)
19075 exit (1);
19076 if (localtime (&now)->tm_hour == hour_GMT0)
19077 exit (1);
19078 unset_TZ ();
19079 if (localtime (&now)->tm_hour != hour_unset)
19080 exit (1);
19081 exit (0);
19082}
503d2be0
AS
19083_ACEOF
19084rm -f conftest$ac_exeext
c0d27fcc 19085if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19086 (eval $ac_link) 2>&5
19087 ac_status=$?
c0d27fcc 19088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19089 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19091 (eval $ac_try) 2>&5
19092 ac_status=$?
c0d27fcc 19093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19094 (exit $ac_status); }; }; then
ba4481b5
DL
19095 emacs_cv_localtime_cache=no
19096else
503d2be0
AS
19097 echo "$as_me: program exited with status $ac_status" >&5
19098echo "$as_me: failed program was:" >&5
19650fd6
AS
19099sed 's/^/| /' conftest.$ac_ext >&5
19100
c0d27fcc 19101( exit $ac_status )
503d2be0 19102emacs_cv_localtime_cache=yes
ba4481b5 19103fi
35996d22 19104rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 19105fi
ba4481b5
DL
19106else
19107 # If we lack tzset, report that localtime does not cache TZ,
19108 # since we can't invalidate the cache if we don't have tzset.
19109 emacs_cv_localtime_cache=no
19110fi
19111fi
c0d27fcc 19112echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 19113echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 19114if test $emacs_cv_localtime_cache = yes; then
b936fae4 19115
c0d27fcc 19116cat >>confdefs.h <<\_ACEOF
ba4481b5 19117#define LOCALTIME_CACHE 1
c0d27fcc 19118_ACEOF
ba4481b5
DL
19119
19120fi
19121
19122if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
19123
19124for ac_func in gettimeofday
48d4b120 19125do
503d2be0 19126as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 19127echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
19128echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19129if eval "test \"\${$as_ac_var+set}\" = set"; then
19130 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19131else
503d2be0 19132 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19133/* confdefs.h. */
19134_ACEOF
19135cat confdefs.h >>conftest.$ac_ext
19136cat >>conftest.$ac_ext <<_ACEOF
19137/* end confdefs.h. */
35996d22
AS
19138/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19139 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19140#define $ac_func innocuous_$ac_func
19141
48d4b120 19142/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19143 which can conflict with char $ac_func (); below.
19144 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19145 <limits.h> exists even on freestanding compilers. */
35996d22 19146
19650fd6
AS
19147#ifdef __STDC__
19148# include <limits.h>
19149#else
19150# include <assert.h>
19151#endif
35996d22
AS
19152
19153#undef $ac_func
19154
48d4b120 19155/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19156#ifdef __cplusplus
19157extern "C"
19650fd6 19158{
503d2be0 19159#endif
48d4b120 19160/* We use char because int might match the return type of a gcc2
503d2be0
AS
19161 builtin and then its argument prototype would still apply. */
19162char $ac_func ();
48d4b120
DL
19163/* The GNU C library defines this for functions which it implements
19164 to always fail with ENOSYS. Some functions are actually named
19165 something starting with __ and the normal name is an alias. */
19166#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19167choke me
19168#else
19650fd6
AS
19169char (*f) () = $ac_func;
19170#endif
19171#ifdef __cplusplus
19172}
cd958eb3
MB
19173#endif
19174
19650fd6
AS
19175int
19176main ()
19177{
19178return f != $ac_func;
503d2be0
AS
19179 ;
19180 return 0;
19181}
19182_ACEOF
19183rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19184if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19185 (eval $ac_link) 2>conftest.er1
503d2be0 19186 ac_status=$?
35996d22
AS
19187 grep -v '^ *+' conftest.er1 >conftest.err
19188 rm -f conftest.er1
19189 cat conftest.err >&5
c0d27fcc 19190 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19191 (exit $ac_status); } &&
35996d22
AS
19192 { ac_try='test -z "$ac_c_werror_flag"
19193 || test ! -s conftest.err'
19194 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19195 (eval $ac_try) 2>&5
19196 ac_status=$?
19197 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19198 (exit $ac_status); }; } &&
19199 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19200 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19201 (eval $ac_try) 2>&5
19202 ac_status=$?
c0d27fcc 19203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19204 (exit $ac_status); }; }; then
19205 eval "$as_ac_var=yes"
19206else
19207 echo "$as_me: failed program was:" >&5
19650fd6
AS
19208sed 's/^/| /' conftest.$ac_ext >&5
19209
503d2be0
AS
19210eval "$as_ac_var=no"
19211fi
35996d22
AS
19212rm -f conftest.err conftest.$ac_objext \
19213 conftest$ac_exeext conftest.$ac_ext
503d2be0 19214fi
c0d27fcc 19215echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
19216echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19217if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 19218 cat >>confdefs.h <<_ACEOF
503d2be0 19219#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 19220_ACEOF
48d4b120 19221
48d4b120
DL
19222fi
19223done
19224
b936fae4 19225 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 19226 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
19227echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
19228if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
19229 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19230else
503d2be0 19231 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19232/* confdefs.h. */
19233_ACEOF
19234cat confdefs.h >>conftest.$ac_ext
19235cat >>conftest.$ac_ext <<_ACEOF
19236/* end confdefs.h. */
ba4481b5 19237
a3f08d9e
DL
19238#ifdef TIME_WITH_SYS_TIME
19239#include <sys/time.h>
19240#include <time.h>
19241#else
19242#ifdef HAVE_SYS_TIME_H
19243#include <sys/time.h>
19244#else
19245#include <time.h>
19246#endif
19247#endif
503d2be0
AS
19248int
19249main ()
19250{
a3f08d9e 19251struct timeval time;
b936fae4 19252 gettimeofday (&time, 0);
503d2be0
AS
19253 ;
19254 return 0;
19255}
19256_ACEOF
19257rm -f conftest.$ac_objext
c0d27fcc 19258if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19259 (eval $ac_compile) 2>conftest.er1
503d2be0 19260 ac_status=$?
35996d22
AS
19261 grep -v '^ *+' conftest.er1 >conftest.err
19262 rm -f conftest.er1
19263 cat conftest.err >&5
c0d27fcc 19264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19265 (exit $ac_status); } &&
35996d22
AS
19266 { ac_try='test -z "$ac_c_werror_flag"
19267 || test ! -s conftest.err'
19268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19269 (eval $ac_try) 2>&5
19270 ac_status=$?
19271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19272 (exit $ac_status); }; } &&
19273 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19275 (eval $ac_try) 2>&5
19276 ac_status=$?
c0d27fcc 19277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19278 (exit $ac_status); }; }; then
ba4481b5
DL
19279 emacs_cv_gettimeofday_two_arguments=yes
19280else
503d2be0 19281 echo "$as_me: failed program was:" >&5
19650fd6
AS
19282sed 's/^/| /' conftest.$ac_ext >&5
19283
503d2be0 19284emacs_cv_gettimeofday_two_arguments=no
ba4481b5 19285fi
35996d22 19286rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 19287fi
c0d27fcc 19288echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 19289echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
19290 if test $emacs_cv_gettimeofday_two_arguments = no; then
19291
c0d27fcc 19292cat >>confdefs.h <<\_ACEOF
ba4481b5 19293#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 19294_ACEOF
ba4481b5 19295
b936fae4 19296 fi
ba4481b5
DL
19297 fi
19298fi
19299
973a76b1
DL
19300# This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
19301echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
19302echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
19303if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
19304 echo $ECHO_N "(cached) $ECHO_C" >&6
19305else
19306 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19307/* confdefs.h. */
19308_ACEOF
19309cat confdefs.h >>conftest.$ac_ext
19310cat >>conftest.$ac_ext <<_ACEOF
19311/* end confdefs.h. */
973a76b1
DL
19312#include <sys/types.h>
19313#include <$ac_cv_struct_tm>
19314
19315
19316int
19317main ()
19318{
19319static struct tm ac_aggr;
19320if (ac_aggr.tm_zone)
19321return 0;
19322 ;
19323 return 0;
19324}
19325_ACEOF
19326rm -f conftest.$ac_objext
19327if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19328 (eval $ac_compile) 2>conftest.er1
973a76b1 19329 ac_status=$?
35996d22
AS
19330 grep -v '^ *+' conftest.er1 >conftest.err
19331 rm -f conftest.er1
19332 cat conftest.err >&5
973a76b1
DL
19333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19334 (exit $ac_status); } &&
35996d22
AS
19335 { ac_try='test -z "$ac_c_werror_flag"
19336 || test ! -s conftest.err'
19337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19338 (eval $ac_try) 2>&5
19339 ac_status=$?
19340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19341 (exit $ac_status); }; } &&
19342 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19343 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19344 (eval $ac_try) 2>&5
19345 ac_status=$?
19346 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19347 (exit $ac_status); }; }; then
19348 ac_cv_member_struct_tm_tm_zone=yes
19349else
19350 echo "$as_me: failed program was:" >&5
19650fd6
AS
19351sed 's/^/| /' conftest.$ac_ext >&5
19352
973a76b1 19353cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19354/* confdefs.h. */
19355_ACEOF
19356cat confdefs.h >>conftest.$ac_ext
19357cat >>conftest.$ac_ext <<_ACEOF
19358/* end confdefs.h. */
973a76b1
DL
19359#include <sys/types.h>
19360#include <$ac_cv_struct_tm>
19361
19362
19363int
19364main ()
19365{
19366static struct tm ac_aggr;
19367if (sizeof ac_aggr.tm_zone)
19368return 0;
19369 ;
19370 return 0;
19371}
19372_ACEOF
19373rm -f conftest.$ac_objext
19374if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19375 (eval $ac_compile) 2>conftest.er1
973a76b1 19376 ac_status=$?
35996d22
AS
19377 grep -v '^ *+' conftest.er1 >conftest.err
19378 rm -f conftest.er1
19379 cat conftest.err >&5
973a76b1
DL
19380 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19381 (exit $ac_status); } &&
35996d22
AS
19382 { ac_try='test -z "$ac_c_werror_flag"
19383 || test ! -s conftest.err'
19384 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19385 (eval $ac_try) 2>&5
19386 ac_status=$?
19387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19388 (exit $ac_status); }; } &&
19389 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19390 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19391 (eval $ac_try) 2>&5
19392 ac_status=$?
19393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19394 (exit $ac_status); }; }; then
19395 ac_cv_member_struct_tm_tm_zone=yes
19396else
19397 echo "$as_me: failed program was:" >&5
19650fd6
AS
19398sed 's/^/| /' conftest.$ac_ext >&5
19399
973a76b1
DL
19400ac_cv_member_struct_tm_tm_zone=no
19401fi
35996d22 19402rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1 19403fi
35996d22 19404rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
19405fi
19406echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
19407echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
19408if test $ac_cv_member_struct_tm_tm_zone = yes; then
19409
19410cat >>confdefs.h <<_ACEOF
19411#define HAVE_STRUCT_TM_TM_ZONE 1
19412_ACEOF
19413
19414
19415fi
19416
19417if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19418
19419cat >>confdefs.h <<\_ACEOF
19420#define HAVE_TM_ZONE 1
19421_ACEOF
19422
19423else
19424 echo "$as_me:$LINENO: checking for tzname" >&5
19425echo $ECHO_N "checking for tzname... $ECHO_C" >&6
19426if test "${ac_cv_var_tzname+set}" = set; then
19427 echo $ECHO_N "(cached) $ECHO_C" >&6
19428else
19429 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19430/* confdefs.h. */
19431_ACEOF
19432cat confdefs.h >>conftest.$ac_ext
19433cat >>conftest.$ac_ext <<_ACEOF
19434/* end confdefs.h. */
973a76b1
DL
19435#include <time.h>
19436#ifndef tzname /* For SGI. */
19437extern char *tzname[]; /* RS6000 and others reject char **tzname. */
19438#endif
19439
19440int
19441main ()
19442{
19443atoi(*tzname);
19444 ;
19445 return 0;
19446}
19447_ACEOF
19448rm -f conftest.$ac_objext conftest$ac_exeext
19449if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19450 (eval $ac_link) 2>conftest.er1
973a76b1 19451 ac_status=$?
35996d22
AS
19452 grep -v '^ *+' conftest.er1 >conftest.err
19453 rm -f conftest.er1
19454 cat conftest.err >&5
973a76b1
DL
19455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19456 (exit $ac_status); } &&
35996d22
AS
19457 { ac_try='test -z "$ac_c_werror_flag"
19458 || test ! -s conftest.err'
19459 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19460 (eval $ac_try) 2>&5
19461 ac_status=$?
19462 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19463 (exit $ac_status); }; } &&
19464 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
19465 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19466 (eval $ac_try) 2>&5
19467 ac_status=$?
19468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19469 (exit $ac_status); }; }; then
19470 ac_cv_var_tzname=yes
19471else
19472 echo "$as_me: failed program was:" >&5
19650fd6
AS
19473sed 's/^/| /' conftest.$ac_ext >&5
19474
973a76b1
DL
19475ac_cv_var_tzname=no
19476fi
35996d22
AS
19477rm -f conftest.err conftest.$ac_objext \
19478 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
19479fi
19480echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
19481echo "${ECHO_T}$ac_cv_var_tzname" >&6
19482 if test $ac_cv_var_tzname = yes; then
19483
19484cat >>confdefs.h <<\_ACEOF
19485#define HAVE_TZNAME 1
19486_ACEOF
19487
19488 fi
19489fi
19490
19491
48d4b120 19492if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 19493 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
19494echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
19495if test "${emacs_cv_struct_timezone+set}" = set; then
19496 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19497else
503d2be0 19498 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19499/* confdefs.h. */
19500_ACEOF
19501cat confdefs.h >>conftest.$ac_ext
19502cat >>conftest.$ac_ext <<_ACEOF
19503/* end confdefs.h. */
48d4b120 19504#include <sys/time.h>
503d2be0
AS
19505int
19506main ()
19507{
48d4b120 19508struct timezone tz;
503d2be0
AS
19509 ;
19510 return 0;
19511}
19512_ACEOF
19513rm -f conftest.$ac_objext
c0d27fcc 19514if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19515 (eval $ac_compile) 2>conftest.er1
503d2be0 19516 ac_status=$?
35996d22
AS
19517 grep -v '^ *+' conftest.er1 >conftest.err
19518 rm -f conftest.er1
19519 cat conftest.err >&5
c0d27fcc 19520 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19521 (exit $ac_status); } &&
35996d22
AS
19522 { ac_try='test -z "$ac_c_werror_flag"
19523 || test ! -s conftest.err'
19524 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19525 (eval $ac_try) 2>&5
19526 ac_status=$?
19527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19528 (exit $ac_status); }; } &&
19529 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19530 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19531 (eval $ac_try) 2>&5
19532 ac_status=$?
c0d27fcc 19533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19534 (exit $ac_status); }; }; then
48d4b120
DL
19535 if test "$cross_compiling" = yes; then
19536 emacs_cv_struct_timezone=yes
19537else
503d2be0 19538 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19539/* confdefs.h. */
19540_ACEOF
19541cat confdefs.h >>conftest.$ac_ext
19542cat >>conftest.$ac_ext <<_ACEOF
19543/* end confdefs.h. */
48d4b120
DL
19544
19545#ifdef TIME_WITH_SYS_TIME
19546#include <sys/time.h>
19547#include <time.h>
19548#else
19549#ifdef HAVE_SYS_TIME_H
19550#include <sys/time.h>
19551#else
19552#include <time.h>
19553#endif
19554#endif
19555main () {
19556 struct timeval time;
19557 struct timezone dummy;
19558 exit (gettimeofday (&time, &dummy));
19559}
503d2be0
AS
19560_ACEOF
19561rm -f conftest$ac_exeext
c0d27fcc 19562if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19563 (eval $ac_link) 2>&5
19564 ac_status=$?
c0d27fcc 19565 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19566 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19567 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19568 (eval $ac_try) 2>&5
19569 ac_status=$?
c0d27fcc 19570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19571 (exit $ac_status); }; }; then
48d4b120
DL
19572 emacs_cv_struct_timezone=yes
19573else
503d2be0
AS
19574 echo "$as_me: program exited with status $ac_status" >&5
19575echo "$as_me: failed program was:" >&5
19650fd6
AS
19576sed 's/^/| /' conftest.$ac_ext >&5
19577
c0d27fcc 19578( exit $ac_status )
503d2be0 19579emacs_cv_struct_timezone=no
48d4b120 19580fi
35996d22 19581rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 19582fi
48d4b120 19583else
503d2be0 19584 echo "$as_me: failed program was:" >&5
19650fd6
AS
19585sed 's/^/| /' conftest.$ac_ext >&5
19586
503d2be0 19587emacs_cv_struct_timezone=no
48d4b120 19588fi
35996d22 19589rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
48d4b120 19590fi
c0d27fcc 19591echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 19592echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
19593fi
19594
ba4481b5 19595ok_so_far=yes
c0d27fcc 19596echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
19597echo $ECHO_N "checking for socket... $ECHO_C" >&6
19598if test "${ac_cv_func_socket+set}" = set; then
19599 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19600else
503d2be0 19601 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19602/* confdefs.h. */
19603_ACEOF
19604cat confdefs.h >>conftest.$ac_ext
19605cat >>conftest.$ac_ext <<_ACEOF
19606/* end confdefs.h. */
35996d22
AS
19607/* Define socket to an innocuous variant, in case <limits.h> declares socket.
19608 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19609#define socket innocuous_socket
19610
ba4481b5 19611/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19612 which can conflict with char socket (); below.
19613 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19614 <limits.h> exists even on freestanding compilers. */
35996d22 19615
19650fd6
AS
19616#ifdef __STDC__
19617# include <limits.h>
19618#else
19619# include <assert.h>
19620#endif
35996d22
AS
19621
19622#undef socket
19623
ba4481b5 19624/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19625#ifdef __cplusplus
19626extern "C"
19650fd6 19627{
503d2be0 19628#endif
ba4481b5 19629/* We use char because int might match the return type of a gcc2
503d2be0
AS
19630 builtin and then its argument prototype would still apply. */
19631char socket ();
ba4481b5
DL
19632/* The GNU C library defines this for functions which it implements
19633 to always fail with ENOSYS. Some functions are actually named
19634 something starting with __ and the normal name is an alias. */
19635#if defined (__stub_socket) || defined (__stub___socket)
19636choke me
19637#else
19650fd6
AS
19638char (*f) () = socket;
19639#endif
19640#ifdef __cplusplus
19641}
cd958eb3
MB
19642#endif
19643
19650fd6
AS
19644int
19645main ()
19646{
19647return f != socket;
503d2be0
AS
19648 ;
19649 return 0;
19650}
19651_ACEOF
19652rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19653if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19654 (eval $ac_link) 2>conftest.er1
503d2be0 19655 ac_status=$?
35996d22
AS
19656 grep -v '^ *+' conftest.er1 >conftest.err
19657 rm -f conftest.er1
19658 cat conftest.err >&5
c0d27fcc 19659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19660 (exit $ac_status); } &&
35996d22
AS
19661 { ac_try='test -z "$ac_c_werror_flag"
19662 || test ! -s conftest.err'
19663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19664 (eval $ac_try) 2>&5
19665 ac_status=$?
19666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19667 (exit $ac_status); }; } &&
19668 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19670 (eval $ac_try) 2>&5
19671 ac_status=$?
c0d27fcc 19672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19673 (exit $ac_status); }; }; then
19674 ac_cv_func_socket=yes
19675else
19676 echo "$as_me: failed program was:" >&5
19650fd6
AS
19677sed 's/^/| /' conftest.$ac_ext >&5
19678
503d2be0
AS
19679ac_cv_func_socket=no
19680fi
35996d22
AS
19681rm -f conftest.err conftest.$ac_objext \
19682 conftest$ac_exeext conftest.$ac_ext
503d2be0 19683fi
c0d27fcc 19684echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
19685echo "${ECHO_T}$ac_cv_func_socket" >&6
19686if test $ac_cv_func_socket = yes; then
ba4481b5
DL
19687 :
19688else
503d2be0 19689 ok_so_far=no
ba4481b5
DL
19690fi
19691
19692if test $ok_so_far = yes; then
c0d27fcc
MR
19693 if test "${ac_cv_header_netinet_in_h+set}" = set; then
19694 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
19695echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19696if test "${ac_cv_header_netinet_in_h+set}" = set; then
19697 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19698fi
19699echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
19700echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 19701else
c0d27fcc
MR
19702 # Is the header compilable?
19703echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
19704echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
19705cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19706/* confdefs.h. */
19707_ACEOF
19708cat confdefs.h >>conftest.$ac_ext
19709cat >>conftest.$ac_ext <<_ACEOF
19710/* end confdefs.h. */
c0d27fcc
MR
19711$ac_includes_default
19712#include <netinet/in.h>
19713_ACEOF
19714rm -f conftest.$ac_objext
19715if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19716 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19717 ac_status=$?
35996d22
AS
19718 grep -v '^ *+' conftest.er1 >conftest.err
19719 rm -f conftest.er1
19720 cat conftest.err >&5
c0d27fcc
MR
19721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19722 (exit $ac_status); } &&
35996d22
AS
19723 { ac_try='test -z "$ac_c_werror_flag"
19724 || test ! -s conftest.err'
19725 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19726 (eval $ac_try) 2>&5
19727 ac_status=$?
19728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19729 (exit $ac_status); }; } &&
19730 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19731 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19732 (eval $ac_try) 2>&5
19733 ac_status=$?
19734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19735 (exit $ac_status); }; }; then
19736 ac_header_compiler=yes
19737else
19738 echo "$as_me: failed program was:" >&5
19650fd6
AS
19739sed 's/^/| /' conftest.$ac_ext >&5
19740
c0d27fcc
MR
19741ac_header_compiler=no
19742fi
35996d22 19743rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19744echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19745echo "${ECHO_T}$ac_header_compiler" >&6
19746
19747# Is the header present?
19748echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
19749echo $ECHO_N "checking netinet/in.h presence... $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. */
ba4481b5 19756#include <netinet/in.h>
503d2be0 19757_ACEOF
c0d27fcc 19758if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19759 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19760 ac_status=$?
6bae0ccf 19761 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19762 rm -f conftest.er1
19763 cat conftest.err >&5
c0d27fcc 19764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19765 (exit $ac_status); } >/dev/null; then
19766 if test -s conftest.err; then
19767 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19768 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19769 else
19770 ac_cpp_err=
19771 fi
19772else
19773 ac_cpp_err=yes
19774fi
19775if test -z "$ac_cpp_err"; then
c0d27fcc 19776 ac_header_preproc=yes
ba4481b5 19777else
503d2be0 19778 echo "$as_me: failed program was:" >&5
19650fd6
AS
19779sed 's/^/| /' conftest.$ac_ext >&5
19780
c0d27fcc 19781 ac_header_preproc=no
ba4481b5 19782fi
503d2be0 19783rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19784echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19785echo "${ECHO_T}$ac_header_preproc" >&6
19786
19787# So? What about this header?
35996d22
AS
19788case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19789 yes:no: )
c0d27fcc
MR
19790 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
19791echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19792 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the compiler's result" >&5
19793echo "$as_me: WARNING: netinet/in.h: proceeding with the compiler's result" >&2;}
19794 ac_header_preproc=yes
19650fd6 19795 ;;
35996d22 19796 no:yes:* )
c0d27fcc
MR
19797 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
19798echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
35996d22
AS
19799 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
19800echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
19801 { echo "$as_me:$LINENO: WARNING: netinet/in.h: see the Autoconf documentation" >&5
19802echo "$as_me: WARNING: netinet/in.h: see the Autoconf documentation" >&2;}
19803 { echo "$as_me:$LINENO: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&5
19804echo "$as_me: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19805 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
19650fd6 19806echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19807 { echo "$as_me:$LINENO: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&5
19808echo "$as_me: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19809 (
19810 cat <<\_ASBOX
35996d22
AS
19811## ------------------------------------------ ##
19812## Report this to the AC_PACKAGE_NAME lists. ##
19813## ------------------------------------------ ##
19650fd6
AS
19814_ASBOX
19815 ) |
19816 sed "s/^/$as_me: WARNING: /" >&2
19817 ;;
c0d27fcc
MR
19818esac
19819echo "$as_me:$LINENO: checking for netinet/in.h" >&5
19820echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19821if test "${ac_cv_header_netinet_in_h+set}" = set; then
19822 echo $ECHO_N "(cached) $ECHO_C" >&6
19823else
19824 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 19825fi
c0d27fcc 19826echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 19827echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
19828
19829fi
503d2be0 19830if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
19831 :
19832else
503d2be0 19833 ok_so_far=no
ba4481b5
DL
19834fi
19835
c0d27fcc 19836
ba4481b5
DL
19837fi
19838if test $ok_so_far = yes; then
c0d27fcc
MR
19839 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19840 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
19841echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
19842if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19843 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19844fi
19845echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
19846echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 19847else
c0d27fcc
MR
19848 # Is the header compilable?
19849echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
19850echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
19851cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19852/* confdefs.h. */
19853_ACEOF
19854cat confdefs.h >>conftest.$ac_ext
19855cat >>conftest.$ac_ext <<_ACEOF
19856/* end confdefs.h. */
c0d27fcc
MR
19857$ac_includes_default
19858#include <arpa/inet.h>
19859_ACEOF
19860rm -f conftest.$ac_objext
19861if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19862 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19863 ac_status=$?
35996d22
AS
19864 grep -v '^ *+' conftest.er1 >conftest.err
19865 rm -f conftest.er1
19866 cat conftest.err >&5
c0d27fcc
MR
19867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19868 (exit $ac_status); } &&
35996d22
AS
19869 { ac_try='test -z "$ac_c_werror_flag"
19870 || test ! -s conftest.err'
19871 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19872 (eval $ac_try) 2>&5
19873 ac_status=$?
19874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19875 (exit $ac_status); }; } &&
19876 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19877 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19878 (eval $ac_try) 2>&5
19879 ac_status=$?
19880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19881 (exit $ac_status); }; }; then
19882 ac_header_compiler=yes
19883else
19884 echo "$as_me: failed program was:" >&5
19650fd6
AS
19885sed 's/^/| /' conftest.$ac_ext >&5
19886
c0d27fcc
MR
19887ac_header_compiler=no
19888fi
35996d22 19889rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19890echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19891echo "${ECHO_T}$ac_header_compiler" >&6
19892
19893# Is the header present?
19894echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
19895echo $ECHO_N "checking arpa/inet.h presence... $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. */
ba4481b5 19902#include <arpa/inet.h>
503d2be0 19903_ACEOF
c0d27fcc 19904if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19905 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19906 ac_status=$?
6bae0ccf 19907 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19908 rm -f conftest.er1
19909 cat conftest.err >&5
c0d27fcc 19910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19911 (exit $ac_status); } >/dev/null; then
19912 if test -s conftest.err; then
19913 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19914 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19915 else
19916 ac_cpp_err=
19917 fi
19918else
19919 ac_cpp_err=yes
19920fi
19921if test -z "$ac_cpp_err"; then
c0d27fcc 19922 ac_header_preproc=yes
ba4481b5 19923else
503d2be0 19924 echo "$as_me: failed program was:" >&5
19650fd6
AS
19925sed 's/^/| /' conftest.$ac_ext >&5
19926
c0d27fcc 19927 ac_header_preproc=no
ba4481b5 19928fi
503d2be0 19929rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19930echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19931echo "${ECHO_T}$ac_header_preproc" >&6
19932
19933# So? What about this header?
35996d22
AS
19934case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19935 yes:no: )
c0d27fcc
MR
19936 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
19937echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19938 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the compiler's result" >&5
19939echo "$as_me: WARNING: arpa/inet.h: proceeding with the compiler's result" >&2;}
19940 ac_header_preproc=yes
19650fd6 19941 ;;
35996d22 19942 no:yes:* )
c0d27fcc
MR
19943 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
19944echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
35996d22
AS
19945 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
19946echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
19947 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: see the Autoconf documentation" >&5
19948echo "$as_me: WARNING: arpa/inet.h: see the Autoconf documentation" >&2;}
19949 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&5
19950echo "$as_me: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19951 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
19650fd6 19952echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19953 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&5
19954echo "$as_me: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19955 (
19956 cat <<\_ASBOX
35996d22
AS
19957## ------------------------------------------ ##
19958## Report this to the AC_PACKAGE_NAME lists. ##
19959## ------------------------------------------ ##
19650fd6
AS
19960_ASBOX
19961 ) |
19962 sed "s/^/$as_me: WARNING: /" >&2
19963 ;;
c0d27fcc
MR
19964esac
19965echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
19966echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
19967if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19968 echo $ECHO_N "(cached) $ECHO_C" >&6
19969else
19970 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 19971fi
c0d27fcc 19972echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 19973echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
19974
19975fi
503d2be0 19976if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
19977 :
19978else
503d2be0 19979 ok_so_far=no
ba4481b5
DL
19980fi
19981
c0d27fcc 19982
ba4481b5
DL
19983fi
19984if test $ok_so_far = yes; then
b936fae4 19985
c0d27fcc 19986cat >>confdefs.h <<\_ACEOF
ba4481b5 19987#define HAVE_INET_SOCKETS 1
c0d27fcc 19988_ACEOF
ba4481b5
DL
19989
19990fi
19991
2d2b6695 19992
7862d3a8 19993for ac_header in sys/ioctl.h
2d2b6695
KS
19994do
19995as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19996if eval "test \"\${$as_ac_Header+set}\" = set"; then
19997 echo "$as_me:$LINENO: checking for $ac_header" >&5
19998echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19999if eval "test \"\${$as_ac_Header+set}\" = set"; then
20000 echo $ECHO_N "(cached) $ECHO_C" >&6
20001fi
20002echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20003echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20004else
20005 # Is the header compilable?
20006echo "$as_me:$LINENO: checking $ac_header usability" >&5
20007echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20008cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
20009/* confdefs.h. */
20010_ACEOF
20011cat confdefs.h >>conftest.$ac_ext
20012cat >>conftest.$ac_ext <<_ACEOF
20013/* end confdefs.h. */
20014$ac_includes_default
20015#include <$ac_header>
20016_ACEOF
20017rm -f conftest.$ac_objext
20018if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20019 (eval $ac_compile) 2>conftest.er1
2d2b6695 20020 ac_status=$?
35996d22
AS
20021 grep -v '^ *+' conftest.er1 >conftest.err
20022 rm -f conftest.er1
20023 cat conftest.err >&5
2d2b6695
KS
20024 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20025 (exit $ac_status); } &&
35996d22
AS
20026 { ac_try='test -z "$ac_c_werror_flag"
20027 || test ! -s conftest.err'
20028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20029 (eval $ac_try) 2>&5
20030 ac_status=$?
20031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20032 (exit $ac_status); }; } &&
20033 { ac_try='test -s conftest.$ac_objext'
2d2b6695
KS
20034 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20035 (eval $ac_try) 2>&5
20036 ac_status=$?
20037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20038 (exit $ac_status); }; }; then
20039 ac_header_compiler=yes
20040else
20041 echo "$as_me: failed program was:" >&5
20042sed 's/^/| /' conftest.$ac_ext >&5
20043
20044ac_header_compiler=no
20045fi
35996d22 20046rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2d2b6695
KS
20047echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20048echo "${ECHO_T}$ac_header_compiler" >&6
20049
20050# Is the header present?
20051echo "$as_me:$LINENO: checking $ac_header presence" >&5
20052echo $ECHO_N "checking $ac_header presence... $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#include <$ac_header>
20060_ACEOF
20061if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20062 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20063 ac_status=$?
20064 grep -v '^ *+' conftest.er1 >conftest.err
20065 rm -f conftest.er1
20066 cat conftest.err >&5
20067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20068 (exit $ac_status); } >/dev/null; then
20069 if test -s conftest.err; then
20070 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20071 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2d2b6695
KS
20072 else
20073 ac_cpp_err=
20074 fi
20075else
20076 ac_cpp_err=yes
20077fi
20078if test -z "$ac_cpp_err"; then
20079 ac_header_preproc=yes
20080else
20081 echo "$as_me: failed program was:" >&5
20082sed 's/^/| /' conftest.$ac_ext >&5
20083
20084 ac_header_preproc=no
20085fi
20086rm -f conftest.err conftest.$ac_ext
20087echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20088echo "${ECHO_T}$ac_header_preproc" >&6
20089
20090# So? What about this header?
35996d22
AS
20091case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20092 yes:no: )
2d2b6695
KS
20093 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20094echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20095 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20096echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20097 ac_header_preproc=yes
2d2b6695 20098 ;;
35996d22 20099 no:yes:* )
2d2b6695
KS
20100 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20101echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20102 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20103echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20104 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20105echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20106 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20107echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
2d2b6695
KS
20108 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20109echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20110 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20111echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
2d2b6695
KS
20112 (
20113 cat <<\_ASBOX
35996d22
AS
20114## ------------------------------------------ ##
20115## Report this to the AC_PACKAGE_NAME lists. ##
20116## ------------------------------------------ ##
2d2b6695
KS
20117_ASBOX
20118 ) |
20119 sed "s/^/$as_me: WARNING: /" >&2
20120 ;;
20121esac
20122echo "$as_me:$LINENO: checking for $ac_header" >&5
20123echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20124if eval "test \"\${$as_ac_Header+set}\" = set"; then
20125 echo $ECHO_N "(cached) $ECHO_C" >&6
20126else
35996d22 20127 eval "$as_ac_Header=\$ac_header_preproc"
2d2b6695
KS
20128fi
20129echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20130echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20131
20132fi
20133if test `eval echo '${'$as_ac_Header'}'` = yes; then
20134 cat >>confdefs.h <<_ACEOF
20135#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20136_ACEOF
20137
20138fi
20139
20140done
20141
20142
ba4481b5 20143if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 20144
c0d27fcc 20145cat >>confdefs.h <<\_ACEOF
ba4481b5 20146#define HAVE_AIX_SMT_EXP 1
c0d27fcc 20147_ACEOF
ba4481b5
DL
20148
20149fi
20150
c0d27fcc 20151echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 20152echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 20153if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 20154 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 20155echo "${ECHO_T}yes" >&6
b936fae4 20156
c0d27fcc 20157cat >>confdefs.h <<\_ACEOF
3d9fec71 20158#define HAVE_DEV_PTMX 1
c0d27fcc 20159_ACEOF
3d9fec71
DL
20160
20161else
c0d27fcc 20162 echo "$as_me:$LINENO: result: no" >&5
503d2be0 20163echo "${ECHO_T}no" >&6
3d9fec71
DL
20164fi
20165
c0d27fcc 20166echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
20167echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
20168if test "${ac_cv_type_pid_t+set}" = set; then
20169 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 20170else
503d2be0 20171 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20172/* confdefs.h. */
20173_ACEOF
20174cat confdefs.h >>conftest.$ac_ext
20175cat >>conftest.$ac_ext <<_ACEOF
20176/* end confdefs.h. */
503d2be0
AS
20177$ac_includes_default
20178int
20179main ()
20180{
20181if ((pid_t *) 0)
20182 return 0;
20183if (sizeof (pid_t))
20184 return 0;
20185 ;
20186 return 0;
20187}
20188_ACEOF
20189rm -f conftest.$ac_objext
c0d27fcc 20190if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20191 (eval $ac_compile) 2>conftest.er1
503d2be0 20192 ac_status=$?
35996d22
AS
20193 grep -v '^ *+' conftest.er1 >conftest.err
20194 rm -f conftest.er1
20195 cat conftest.err >&5
c0d27fcc 20196 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20197 (exit $ac_status); } &&
35996d22
AS
20198 { ac_try='test -z "$ac_c_werror_flag"
20199 || test ! -s conftest.err'
20200 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20201 (eval $ac_try) 2>&5
20202 ac_status=$?
20203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20204 (exit $ac_status); }; } &&
20205 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20206 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20207 (eval $ac_try) 2>&5
20208 ac_status=$?
c0d27fcc 20209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20210 (exit $ac_status); }; }; then
647847ea
DL
20211 ac_cv_type_pid_t=yes
20212else
503d2be0 20213 echo "$as_me: failed program was:" >&5
19650fd6
AS
20214sed 's/^/| /' conftest.$ac_ext >&5
20215
503d2be0 20216ac_cv_type_pid_t=no
647847ea 20217fi
35996d22 20218rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
647847ea 20219fi
c0d27fcc 20220echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
20221echo "${ECHO_T}$ac_cv_type_pid_t" >&6
20222if test $ac_cv_type_pid_t = yes; then
20223 :
20224else
20225
c0d27fcc 20226cat >>confdefs.h <<_ACEOF
647847ea 20227#define pid_t int
c0d27fcc 20228_ACEOF
647847ea
DL
20229
20230fi
20231
c0d27fcc
MR
20232
20233
503d2be0
AS
20234for ac_header in unistd.h vfork.h
20235do
20236as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
20237if eval "test \"\${$as_ac_Header+set}\" = set"; then
20238 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
20239echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20240if eval "test \"\${$as_ac_Header+set}\" = set"; then
20241 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20242fi
20243echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20244echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 20245else
c0d27fcc
MR
20246 # Is the header compilable?
20247echo "$as_me:$LINENO: checking $ac_header usability" >&5
20248echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20249cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20250/* confdefs.h. */
20251_ACEOF
20252cat confdefs.h >>conftest.$ac_ext
20253cat >>conftest.$ac_ext <<_ACEOF
20254/* end confdefs.h. */
c0d27fcc
MR
20255$ac_includes_default
20256#include <$ac_header>
20257_ACEOF
20258rm -f conftest.$ac_objext
20259if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20260 (eval $ac_compile) 2>conftest.er1
c0d27fcc 20261 ac_status=$?
35996d22
AS
20262 grep -v '^ *+' conftest.er1 >conftest.err
20263 rm -f conftest.er1
20264 cat conftest.err >&5
c0d27fcc
MR
20265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20266 (exit $ac_status); } &&
35996d22
AS
20267 { ac_try='test -z "$ac_c_werror_flag"
20268 || test ! -s conftest.err'
20269 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20270 (eval $ac_try) 2>&5
20271 ac_status=$?
20272 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20273 (exit $ac_status); }; } &&
20274 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20275 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20276 (eval $ac_try) 2>&5
20277 ac_status=$?
20278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20279 (exit $ac_status); }; }; then
20280 ac_header_compiler=yes
20281else
20282 echo "$as_me: failed program was:" >&5
19650fd6
AS
20283sed 's/^/| /' conftest.$ac_ext >&5
20284
c0d27fcc
MR
20285ac_header_compiler=no
20286fi
35996d22 20287rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20288echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20289echo "${ECHO_T}$ac_header_compiler" >&6
20290
20291# Is the header present?
20292echo "$as_me:$LINENO: checking $ac_header presence" >&5
20293echo $ECHO_N "checking $ac_header presence... $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. */
503d2be0
AS
20300#include <$ac_header>
20301_ACEOF
c0d27fcc 20302if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20303 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20304 ac_status=$?
6bae0ccf 20305 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20306 rm -f conftest.er1
20307 cat conftest.err >&5
c0d27fcc 20308 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20309 (exit $ac_status); } >/dev/null; then
20310 if test -s conftest.err; then
20311 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20312 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20313 else
20314 ac_cpp_err=
20315 fi
647847ea 20316else
503d2be0
AS
20317 ac_cpp_err=yes
20318fi
20319if test -z "$ac_cpp_err"; then
c0d27fcc 20320 ac_header_preproc=yes
647847ea 20321else
503d2be0 20322 echo "$as_me: failed program was:" >&5
19650fd6
AS
20323sed 's/^/| /' conftest.$ac_ext >&5
20324
c0d27fcc 20325 ac_header_preproc=no
647847ea 20326fi
503d2be0 20327rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20328echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20329echo "${ECHO_T}$ac_header_preproc" >&6
20330
20331# So? What about this header?
35996d22
AS
20332case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20333 yes:no: )
c0d27fcc
MR
20334 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20335echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20336 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20337echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20338 ac_header_preproc=yes
19650fd6 20339 ;;
35996d22 20340 no:yes:* )
c0d27fcc
MR
20341 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20342echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20343 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20344echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20345 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20346echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20347 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20348echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20349 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 20350echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20351 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20352echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20353 (
20354 cat <<\_ASBOX
35996d22
AS
20355## ------------------------------------------ ##
20356## Report this to the AC_PACKAGE_NAME lists. ##
20357## ------------------------------------------ ##
19650fd6
AS
20358_ASBOX
20359 ) |
20360 sed "s/^/$as_me: WARNING: /" >&2
20361 ;;
c0d27fcc
MR
20362esac
20363echo "$as_me:$LINENO: checking for $ac_header" >&5
20364echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20365if eval "test \"\${$as_ac_Header+set}\" = set"; then
20366 echo $ECHO_N "(cached) $ECHO_C" >&6
20367else
35996d22 20368 eval "$as_ac_Header=\$ac_header_preproc"
647847ea 20369fi
c0d27fcc 20370echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 20371echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
20372
20373fi
503d2be0 20374if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 20375 cat >>confdefs.h <<_ACEOF
503d2be0 20376#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 20377_ACEOF
647847ea 20378
73b77ee5 20379fi
c0d27fcc 20380
503d2be0 20381done
73b77ee5 20382
c0d27fcc
MR
20383
20384
503d2be0
AS
20385for ac_func in fork vfork
20386do
20387as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 20388echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
20389echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
20390if eval "test \"\${$as_ac_var+set}\" = set"; then
20391 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20392else
503d2be0 20393 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20394/* confdefs.h. */
20395_ACEOF
20396cat confdefs.h >>conftest.$ac_ext
20397cat >>conftest.$ac_ext <<_ACEOF
20398/* end confdefs.h. */
35996d22
AS
20399/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20400 For example, HP-UX 11i <limits.h> declares gettimeofday. */
20401#define $ac_func innocuous_$ac_func
20402
fa0b693c 20403/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
20404 which can conflict with char $ac_func (); below.
20405 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20406 <limits.h> exists even on freestanding compilers. */
35996d22 20407
19650fd6
AS
20408#ifdef __STDC__
20409# include <limits.h>
20410#else
20411# include <assert.h>
20412#endif
35996d22
AS
20413
20414#undef $ac_func
20415
fa0b693c 20416/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20417#ifdef __cplusplus
20418extern "C"
19650fd6 20419{
503d2be0 20420#endif
fa0b693c 20421/* We use char because int might match the return type of a gcc2
503d2be0
AS
20422 builtin and then its argument prototype would still apply. */
20423char $ac_func ();
fa0b693c
GM
20424/* The GNU C library defines this for functions which it implements
20425 to always fail with ENOSYS. Some functions are actually named
20426 something starting with __ and the normal name is an alias. */
503d2be0 20427#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
20428choke me
20429#else
19650fd6
AS
20430char (*f) () = $ac_func;
20431#endif
20432#ifdef __cplusplus
20433}
fa0b693c
GM
20434#endif
20435
19650fd6
AS
20436int
20437main ()
20438{
20439return f != $ac_func;
503d2be0
AS
20440 ;
20441 return 0;
20442}
20443_ACEOF
20444rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20445if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20446 (eval $ac_link) 2>conftest.er1
503d2be0 20447 ac_status=$?
35996d22
AS
20448 grep -v '^ *+' conftest.er1 >conftest.err
20449 rm -f conftest.er1
20450 cat conftest.err >&5
c0d27fcc 20451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20452 (exit $ac_status); } &&
35996d22
AS
20453 { ac_try='test -z "$ac_c_werror_flag"
20454 || test ! -s conftest.err'
20455 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20456 (eval $ac_try) 2>&5
20457 ac_status=$?
20458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20459 (exit $ac_status); }; } &&
20460 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 20461 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20462 (eval $ac_try) 2>&5
20463 ac_status=$?
c0d27fcc 20464 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20465 (exit $ac_status); }; }; then
20466 eval "$as_ac_var=yes"
20467else
20468 echo "$as_me: failed program was:" >&5
19650fd6
AS
20469sed 's/^/| /' conftest.$ac_ext >&5
20470
503d2be0
AS
20471eval "$as_ac_var=no"
20472fi
35996d22
AS
20473rm -f conftest.err conftest.$ac_objext \
20474 conftest$ac_exeext conftest.$ac_ext
503d2be0 20475fi
c0d27fcc 20476echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
20477echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
20478if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 20479 cat >>confdefs.h <<_ACEOF
503d2be0 20480#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 20481_ACEOF
503d2be0 20482
fa0b693c 20483fi
503d2be0 20484done
fa0b693c 20485
503d2be0 20486if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 20487 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
20488echo $ECHO_N "checking for working fork... $ECHO_C" >&6
20489if test "${ac_cv_func_fork_works+set}" = set; then
20490 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20491else
503d2be0
AS
20492 if test "$cross_compiling" = yes; then
20493 ac_cv_func_fork_works=cross
20494else
20495 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 20496/* By Ruediger Kuhlmann. */
503d2be0
AS
20497 #include <sys/types.h>
20498 #if HAVE_UNISTD_H
20499 # include <unistd.h>
20500 #endif
20501 /* Some systems only have a dummy stub for fork() */
20502 int main ()
20503 {
35996d22
AS
20504 if (fork() < 0)
20505 exit (1);
20506 exit (0);
503d2be0
AS
20507 }
20508_ACEOF
20509rm -f conftest$ac_exeext
c0d27fcc 20510if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20511 (eval $ac_link) 2>&5
20512 ac_status=$?
c0d27fcc 20513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20514 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20515 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20516 (eval $ac_try) 2>&5
20517 ac_status=$?
c0d27fcc 20518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20519 (exit $ac_status); }; }; then
20520 ac_cv_func_fork_works=yes
20521else
20522 echo "$as_me: program exited with status $ac_status" >&5
20523echo "$as_me: failed program was:" >&5
19650fd6
AS
20524sed 's/^/| /' conftest.$ac_ext >&5
20525
c0d27fcc 20526( exit $ac_status )
503d2be0
AS
20527ac_cv_func_fork_works=no
20528fi
35996d22 20529rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
20530fi
20531fi
c0d27fcc 20532echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
20533echo "${ECHO_T}$ac_cv_func_fork_works" >&6
20534
6bae0ccf
DL
20535else
20536 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
20537fi
20538if test "x$ac_cv_func_fork_works" = xcross; then
20539 case $host in
20540 *-*-amigaos* | *-*-msdosdjgpp*)
20541 # Override, as these systems have only a dummy fork() stub
20542 ac_cv_func_fork_works=no
20543 ;;
20544 *)
20545 ac_cv_func_fork_works=yes
20546 ;;
20547 esac
c0d27fcc
MR
20548 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
20549echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 20550fi
73b77ee5 20551ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 20552if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 20553 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
20554echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
20555if test "${ac_cv_func_vfork_works+set}" = set; then
20556 echo $ECHO_N "(cached) $ECHO_C" >&6
20557else
20558 if test "$cross_compiling" = yes; then
20559 ac_cv_func_vfork_works=cross
fa0b693c 20560else
503d2be0 20561 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20562/* confdefs.h. */
20563_ACEOF
20564cat confdefs.h >>conftest.$ac_ext
20565cat >>conftest.$ac_ext <<_ACEOF
20566/* end confdefs.h. */
73b77ee5
GM
20567/* Thanks to Paul Eggert for this test. */
20568#include <stdio.h>
19650fd6 20569#include <stdlib.h>
fa0b693c 20570#include <sys/types.h>
73b77ee5 20571#include <sys/stat.h>
19650fd6 20572#include <sys/wait.h>
503d2be0
AS
20573#if HAVE_UNISTD_H
20574# include <unistd.h>
73b77ee5 20575#endif
503d2be0
AS
20576#if HAVE_VFORK_H
20577# include <vfork.h>
73b77ee5
GM
20578#endif
20579/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
20580 argument registers are propagated back to the parent. The compiler
20581 is told about this with #include <vfork.h>, but some compilers
20582 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
20583 static variable whose address is put into a register that is
20584 clobbered by the vfork. */
19650fd6 20585static void
fa0b693c 20586#ifdef __cplusplus
73b77ee5 20587sparc_address_test (int arg)
503d2be0 20588# else
73b77ee5 20589sparc_address_test (arg) int arg;
fa0b693c 20590#endif
fa0b693c 20591{
73b77ee5
GM
20592 static pid_t child;
20593 if (!child) {
20594 child = vfork ();
20595 if (child < 0) {
20596 perror ("vfork");
20597 _exit(2);
20598 }
20599 if (!child) {
20600 arg = getpid();
20601 write(-1, "", 0);
20602 _exit (arg);
20603 }
20604 }
20605}
503d2be0
AS
20606
20607int
20608main ()
20609{
73b77ee5
GM
20610 pid_t parent = getpid ();
20611 pid_t child;
fa0b693c 20612
19650fd6 20613 sparc_address_test (0);
fa0b693c 20614
73b77ee5 20615 child = vfork ();
fa0b693c 20616
73b77ee5 20617 if (child == 0) {
503d2be0
AS
20618 /* Here is another test for sparc vfork register problems. This
20619 test uses lots of local variables, at least as many local
20620 variables as main has allocated so far including compiler
20621 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
20622 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
20623 reuse the register of parent for one of the local variables,
20624 since it will think that parent can't possibly be used any more
20625 in this routine. Assigning to the local variable will thus
20626 munge parent in the parent process. */
73b77ee5
GM
20627 pid_t
20628 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
20629 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
20630 /* Convince the compiler that p..p7 are live; otherwise, it might
20631 use the same hardware register for all 8 local variables. */
20632 if (p != p1 || p != p2 || p != p3 || p != p4
20633 || p != p5 || p != p6 || p != p7)
20634 _exit(1);
fa0b693c 20635
503d2be0
AS
20636 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
20637 from child file descriptors. If the child closes a descriptor
20638 before it execs or exits, this munges the parent's descriptor
20639 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
20640 _exit(close(fileno(stdout)) != 0);
20641 } else {
20642 int status;
20643 struct stat st;
20644
20645 while (wait(&status) != child)
20646 ;
20647 exit(
20648 /* Was there some problem with vforking? */
20649 child < 0
20650
20651 /* Did the child fail? (This shouldn't happen.) */
20652 || status
20653
20654 /* Did the vfork/compiler bug occur? */
20655 || parent != getpid()
fa0b693c 20656
73b77ee5
GM
20657 /* Did the file descriptor bug occur? */
20658 || fstat(fileno(stdout), &st) != 0
20659 );
20660 }
20661}
503d2be0
AS
20662_ACEOF
20663rm -f conftest$ac_exeext
c0d27fcc 20664if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20665 (eval $ac_link) 2>&5
20666 ac_status=$?
c0d27fcc 20667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20668 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20670 (eval $ac_try) 2>&5
20671 ac_status=$?
c0d27fcc 20672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20673 (exit $ac_status); }; }; then
73b77ee5 20674 ac_cv_func_vfork_works=yes
fa0b693c 20675else
503d2be0
AS
20676 echo "$as_me: program exited with status $ac_status" >&5
20677echo "$as_me: failed program was:" >&5
19650fd6
AS
20678sed 's/^/| /' conftest.$ac_ext >&5
20679
c0d27fcc 20680( exit $ac_status )
503d2be0
AS
20681ac_cv_func_vfork_works=no
20682fi
35996d22 20683rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 20684fi
fa0b693c 20685fi
c0d27fcc 20686echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 20687echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 20688
503d2be0
AS
20689fi;
20690if test "x$ac_cv_func_fork_works" = xcross; then
35996d22 20691 ac_cv_func_vfork_works=$ac_cv_func_vfork
c0d27fcc
MR
20692 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
20693echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
20694fi
20695
503d2be0
AS
20696if test "x$ac_cv_func_vfork_works" = xyes; then
20697
c0d27fcc 20698cat >>confdefs.h <<\_ACEOF
503d2be0 20699#define HAVE_WORKING_VFORK 1
c0d27fcc 20700_ACEOF
503d2be0
AS
20701
20702else
20703
c0d27fcc 20704cat >>confdefs.h <<\_ACEOF
73b77ee5 20705#define vfork fork
c0d27fcc 20706_ACEOF
fa0b693c
GM
20707
20708fi
503d2be0
AS
20709if test "x$ac_cv_func_fork_works" = xyes; then
20710
c0d27fcc 20711cat >>confdefs.h <<\_ACEOF
503d2be0 20712#define HAVE_WORKING_FORK 1
c0d27fcc 20713_ACEOF
fa0b693c 20714
503d2be0 20715fi
647847ea 20716
c0d27fcc 20717
6a3a24fa
JD
20718echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
20719echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
20720if test "${emacs_cv_langinfo_codeset+set}" = set; then
20721 echo $ECHO_N "(cached) $ECHO_C" >&6
20722else
20723 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20724/* confdefs.h. */
20725_ACEOF
20726cat confdefs.h >>conftest.$ac_ext
20727cat >>conftest.$ac_ext <<_ACEOF
20728/* end confdefs.h. */
6a3a24fa
JD
20729#include <langinfo.h>
20730int
20731main ()
20732{
20733char* cs = nl_langinfo(CODESET);
20734 ;
20735 return 0;
20736}
20737_ACEOF
20738rm -f conftest.$ac_objext conftest$ac_exeext
20739if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20740 (eval $ac_link) 2>conftest.er1
6a3a24fa 20741 ac_status=$?
35996d22
AS
20742 grep -v '^ *+' conftest.er1 >conftest.err
20743 rm -f conftest.er1
20744 cat conftest.err >&5
6a3a24fa
JD
20745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20746 (exit $ac_status); } &&
35996d22
AS
20747 { ac_try='test -z "$ac_c_werror_flag"
20748 || test ! -s conftest.err'
20749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20750 (eval $ac_try) 2>&5
20751 ac_status=$?
20752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20753 (exit $ac_status); }; } &&
20754 { ac_try='test -s conftest$ac_exeext'
6a3a24fa
JD
20755 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20756 (eval $ac_try) 2>&5
20757 ac_status=$?
20758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20759 (exit $ac_status); }; }; then
20760 emacs_cv_langinfo_codeset=yes
20761else
20762 echo "$as_me: failed program was:" >&5
19650fd6
AS
20763sed 's/^/| /' conftest.$ac_ext >&5
20764
6a3a24fa
JD
20765emacs_cv_langinfo_codeset=no
20766fi
35996d22
AS
20767rm -f conftest.err conftest.$ac_objext \
20768 conftest$ac_exeext conftest.$ac_ext
6a3a24fa
JD
20769
20770fi
20771echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
20772echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
20773if test $emacs_cv_langinfo_codeset = yes; then
20774
20775cat >>confdefs.h <<\_ACEOF
20776#define HAVE_LANGINFO_CODESET 1
20777_ACEOF
20778
20779fi
20780
c0d27fcc 20781echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
20782echo $ECHO_N "checking for size_t... $ECHO_C" >&6
20783if test "${ac_cv_type_size_t+set}" = set; then
20784 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 20785else
503d2be0 20786 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20787/* confdefs.h. */
20788_ACEOF
20789cat confdefs.h >>conftest.$ac_ext
20790cat >>conftest.$ac_ext <<_ACEOF
20791/* end confdefs.h. */
503d2be0
AS
20792$ac_includes_default
20793int
20794main ()
20795{
20796if ((size_t *) 0)
20797 return 0;
20798if (sizeof (size_t))
20799 return 0;
20800 ;
20801 return 0;
20802}
20803_ACEOF
20804rm -f conftest.$ac_objext
c0d27fcc 20805if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20806 (eval $ac_compile) 2>conftest.er1
503d2be0 20807 ac_status=$?
35996d22
AS
20808 grep -v '^ *+' conftest.er1 >conftest.err
20809 rm -f conftest.er1
20810 cat conftest.err >&5
c0d27fcc 20811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20812 (exit $ac_status); } &&
35996d22
AS
20813 { ac_try='test -z "$ac_c_werror_flag"
20814 || test ! -s conftest.err'
20815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20816 (eval $ac_try) 2>&5
20817 ac_status=$?
20818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20819 (exit $ac_status); }; } &&
20820 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20821 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20822 (eval $ac_try) 2>&5
20823 ac_status=$?
c0d27fcc 20824 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20825 (exit $ac_status); }; }; then
8730a8da
DL
20826 ac_cv_type_size_t=yes
20827else
503d2be0 20828 echo "$as_me: failed program was:" >&5
19650fd6
AS
20829sed 's/^/| /' conftest.$ac_ext >&5
20830
503d2be0 20831ac_cv_type_size_t=no
8730a8da 20832fi
35996d22 20833rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8730a8da 20834fi
c0d27fcc 20835echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
20836echo "${ECHO_T}$ac_cv_type_size_t" >&6
20837if test $ac_cv_type_size_t = yes; then
503d2be0 20838
c0d27fcc
MR
20839cat >>confdefs.h <<_ACEOF
20840#define HAVE_SIZE_T 1
20841_ACEOF
20842
8730a8da
DL
20843
20844fi
20845
c0d27fcc 20846
973a76b1
DL
20847echo "$as_me:$LINENO: checking for mbstate_t" >&5
20848echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
20849if test "${ac_cv_type_mbstate_t+set}" = set; then
20850 echo $ECHO_N "(cached) $ECHO_C" >&6
20851else
20852 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20853/* confdefs.h. */
20854_ACEOF
20855cat confdefs.h >>conftest.$ac_ext
20856cat >>conftest.$ac_ext <<_ACEOF
20857/* end confdefs.h. */
973a76b1
DL
20858$ac_includes_default
20859# include <wchar.h>
20860int
20861main ()
20862{
20863mbstate_t x; return sizeof x;
20864 ;
20865 return 0;
20866}
20867_ACEOF
20868rm -f conftest.$ac_objext
20869if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20870 (eval $ac_compile) 2>conftest.er1
973a76b1 20871 ac_status=$?
35996d22
AS
20872 grep -v '^ *+' conftest.er1 >conftest.err
20873 rm -f conftest.er1
20874 cat conftest.err >&5
973a76b1
DL
20875 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20876 (exit $ac_status); } &&
35996d22
AS
20877 { ac_try='test -z "$ac_c_werror_flag"
20878 || test ! -s conftest.err'
20879 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20880 (eval $ac_try) 2>&5
20881 ac_status=$?
20882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20883 (exit $ac_status); }; } &&
20884 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
20885 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20886 (eval $ac_try) 2>&5
20887 ac_status=$?
20888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20889 (exit $ac_status); }; }; then
20890 ac_cv_type_mbstate_t=yes
20891else
20892 echo "$as_me: failed program was:" >&5
19650fd6
AS
20893sed 's/^/| /' conftest.$ac_ext >&5
20894
973a76b1
DL
20895ac_cv_type_mbstate_t=no
20896fi
35996d22 20897rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
20898fi
20899echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
20900echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6
20901 if test $ac_cv_type_mbstate_t = yes; then
20902
20903cat >>confdefs.h <<\_ACEOF
20904#define HAVE_MBSTATE_T 1
20905_ACEOF
20906
20907 else
20908
20909cat >>confdefs.h <<\_ACEOF
20910#define mbstate_t int
20911_ACEOF
20912
20913 fi
20914
22044edf
DL
20915echo "$as_me:$LINENO: checking for C restrict keyword" >&5
20916echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
20917if test "${emacs_cv_c_restrict+set}" = set; then
20918 echo $ECHO_N "(cached) $ECHO_C" >&6
20919else
20920 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20921/* confdefs.h. */
20922_ACEOF
20923cat confdefs.h >>conftest.$ac_ext
20924cat >>conftest.$ac_ext <<_ACEOF
20925/* end confdefs.h. */
22044edf
DL
20926void fred (int *restrict x);
20927int
20928main ()
20929{
b936fae4 20930
22044edf
DL
20931 ;
20932 return 0;
20933}
c0d27fcc 20934_ACEOF
22044edf
DL
20935rm -f conftest.$ac_objext
20936if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20937 (eval $ac_compile) 2>conftest.er1
22044edf 20938 ac_status=$?
35996d22
AS
20939 grep -v '^ *+' conftest.er1 >conftest.err
20940 rm -f conftest.er1
20941 cat conftest.err >&5
22044edf
DL
20942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20943 (exit $ac_status); } &&
35996d22
AS
20944 { ac_try='test -z "$ac_c_werror_flag"
20945 || test ! -s conftest.err'
20946 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20947 (eval $ac_try) 2>&5
20948 ac_status=$?
20949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20950 (exit $ac_status); }; } &&
20951 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
20952 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20953 (eval $ac_try) 2>&5
20954 ac_status=$?
20955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20956 (exit $ac_status); }; }; then
20957 emacs_cv_c_restrict=yes
20958else
20959 echo "$as_me: failed program was:" >&5
19650fd6
AS
20960sed 's/^/| /' conftest.$ac_ext >&5
20961
22044edf 20962cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20963/* confdefs.h. */
20964_ACEOF
20965cat confdefs.h >>conftest.$ac_ext
20966cat >>conftest.$ac_ext <<_ACEOF
20967/* end confdefs.h. */
22044edf
DL
20968void fred (int *__restrict x);
20969int
20970main ()
20971{
c0d27fcc 20972
22044edf
DL
20973 ;
20974 return 0;
20975}
c0d27fcc 20976_ACEOF
22044edf
DL
20977rm -f conftest.$ac_objext
20978if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20979 (eval $ac_compile) 2>conftest.er1
22044edf 20980 ac_status=$?
35996d22
AS
20981 grep -v '^ *+' conftest.er1 >conftest.err
20982 rm -f conftest.er1
20983 cat conftest.err >&5
22044edf
DL
20984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20985 (exit $ac_status); } &&
35996d22
AS
20986 { ac_try='test -z "$ac_c_werror_flag"
20987 || test ! -s conftest.err'
20988 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20989 (eval $ac_try) 2>&5
20990 ac_status=$?
20991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20992 (exit $ac_status); }; } &&
20993 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
20994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20995 (eval $ac_try) 2>&5
20996 ac_status=$?
20997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20998 (exit $ac_status); }; }; then
20999 emacs_cv_c_restrict=__restrict
21000else
21001 echo "$as_me: failed program was:" >&5
19650fd6
AS
21002sed 's/^/| /' conftest.$ac_ext >&5
21003
22044edf 21004emacs_cv_c_restrict=no
ba4481b5 21005fi
35996d22 21006rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21007fi
35996d22 21008rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21009fi
22044edf
DL
21010echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
21011echo "${ECHO_T}$emacs_cv_c_restrict" >&6
21012case "$emacs_cv_c_restrict" in
21013 yes) emacs_restrict=restrict;;
21014 no) emacs_restrict="";;
21015 *) emacs_restrict="$emacs_cv_c_restrict";;
21016esac
21017if test "$emacs_restrict" != __restrict; then
b936fae4 21018
22044edf
DL
21019cat >>confdefs.h <<_ACEOF
21020#define __restrict $emacs_restrict
c0d27fcc 21021_ACEOF
ba4481b5
DL
21022
21023fi
ba4481b5 21024
22044edf
DL
21025echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
21026echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
21027if test "${emacs_cv_c_restrict_arr+set}" = set; then
21028 echo $ECHO_N "(cached) $ECHO_C" >&6
21029else
21030 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21031/* confdefs.h. */
21032_ACEOF
21033cat confdefs.h >>conftest.$ac_ext
21034cat >>conftest.$ac_ext <<_ACEOF
21035/* end confdefs.h. */
22044edf
DL
21036void fred (int x[__restrict]);
21037int
21038main ()
21039{
b936fae4 21040
22044edf
DL
21041 ;
21042 return 0;
21043}
c0d27fcc 21044_ACEOF
22044edf
DL
21045rm -f conftest.$ac_objext
21046if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21047 (eval $ac_compile) 2>conftest.er1
22044edf 21048 ac_status=$?
35996d22
AS
21049 grep -v '^ *+' conftest.er1 >conftest.err
21050 rm -f conftest.er1
21051 cat conftest.err >&5
22044edf
DL
21052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21053 (exit $ac_status); } &&
35996d22
AS
21054 { ac_try='test -z "$ac_c_werror_flag"
21055 || test ! -s conftest.err'
21056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21057 (eval $ac_try) 2>&5
21058 ac_status=$?
21059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21060 (exit $ac_status); }; } &&
21061 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21062 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21063 (eval $ac_try) 2>&5
21064 ac_status=$?
21065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21066 (exit $ac_status); }; }; then
21067 emacs_cv_c_restrict_arr=yes
21068else
21069 echo "$as_me: failed program was:" >&5
19650fd6
AS
21070sed 's/^/| /' conftest.$ac_ext >&5
21071
22044edf 21072emacs_cv_c_restrict_arr=no
ba4481b5 21073fi
35996d22 21074rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22044edf
DL
21075fi
21076echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
21077echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
21078if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 21079
c0d27fcc 21080cat >>confdefs.h <<\_ACEOF
22044edf 21081#define __restrict_arr __restrict
c0d27fcc 21082_ACEOF
ba4481b5 21083
ba4481b5
DL
21084fi
21085
c0d27fcc 21086
c0d27fcc 21087
22044edf
DL
21088# Set up the CFLAGS for real compilation, so we can substitute it.
21089CFLAGS="$REAL_CFLAGS"
21090CPPFLAGS="$REAL_CPPFLAGS"
21091
21092#### Find out which version of Emacs this is.
21093version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
21094 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
21095if test x"${version}" = x; then
21096 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
21097echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
21098 { (exit 1); exit 1; }; }
21099fi
21100
21101### Specify what sort of things we'll be editing into Makefile and config.h.
21102### Use configuration here uncanonicalized to avoid exceeding size limits.
21103
21104
21105
21106
21107
21108
21109
21110
21111
21112
21113
21114
21115
21116
21117
21118
21119
21120
21121
21122
21123
21124
21125
21126
21127
21128
21129
21130
21131
21132
21133
21134
6a3a24fa 21135
22044edf
DL
21136
21137
21138cat >>confdefs.h <<_ACEOF
21139#define EMACS_CONFIGURATION "${canonical}"
21140_ACEOF
21141
21142
21143cat >>confdefs.h <<_ACEOF
21144#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
21145_ACEOF
21146
21147
21148cat >>confdefs.h <<_ACEOF
21149#define config_machfile "${machfile}"
21150_ACEOF
21151
21152
21153cat >>confdefs.h <<_ACEOF
21154#define config_opsysfile "${opsysfile}"
21155_ACEOF
21156
21157
21158cat >>confdefs.h <<_ACEOF
21159#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
21160_ACEOF
21161
21162
21163cat >>confdefs.h <<_ACEOF
21164#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
21165_ACEOF
21166
21167
21168cat >>confdefs.h <<_ACEOF
21169#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
21170_ACEOF
21171
21172
21173cat >>confdefs.h <<_ACEOF
21174#define UNEXEC_SRC ${UNEXEC_SRC}
21175_ACEOF
21176
21177
21178if test "${HAVE_X_WINDOWS}" = "yes" ; then
21179
21180cat >>confdefs.h <<\_ACEOF
21181#define HAVE_X_WINDOWS 1
21182_ACEOF
21183
21184fi
21185if test "${USE_X_TOOLKIT}" != "none" ; then
21186
21187cat >>confdefs.h <<\_ACEOF
21188#define USE_X_TOOLKIT 1
21189_ACEOF
21190
21191fi
21192if test "${HAVE_X11}" = "yes" ; then
21193
21194cat >>confdefs.h <<\_ACEOF
21195#define HAVE_X11 1
21196_ACEOF
21197
21198fi
21199if test "${HAVE_XFREE386}" = "yes" ; then
21200
21201cat >>confdefs.h <<\_ACEOF
21202#define HAVE_XFREE386 1
21203_ACEOF
21204
21205fi
21206if test "${HAVE_MENUS}" = "yes" ; then
21207
21208cat >>confdefs.h <<\_ACEOF
21209#define HAVE_MENUS 1
21210_ACEOF
21211
21212fi
21213if test "${GNU_MALLOC}" = "yes" ; then
21214
21215cat >>confdefs.h <<\_ACEOF
21216#define GNU_MALLOC 1
21217_ACEOF
21218
21219fi
21220if test "${REL_ALLOC}" = "yes" ; then
21221
21222cat >>confdefs.h <<\_ACEOF
21223#define REL_ALLOC 1
21224_ACEOF
21225
21226fi
21227
21228
21229
c0d27fcc
MR
21230
21231
ba4481b5 21232#### Report on what we decided to do.
488dd4c4
JD
21233#### Report GTK as a toolkit, even if it doesn't use Xt.
21234#### It makes printing result more understandable as using GTK sets
21235#### toolkit_scroll_bars to yes by default.
21236if test "${HAVE_GTK}" = "yes"; then
21237 USE_X_TOOLKIT=GTK
21238fi
21239
ba4481b5
DL
21240echo "
21241Configured for \`${canonical}'.
21242
21243 Where should the build process find the source code? ${srcdir}
21244 What operating system and machine description files should Emacs use?
21245 \`${opsysfile}' and \`${machfile}'
21246 What compiler should emacs be built with? ${CC} ${CFLAGS}
21247 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 21248 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 21249 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 21250 What window system should Emacs use? ${window_system}
8e967cf7 21251 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
21252
21253if test -n "${x_includes}"; then
21254echo " Where do we find X Windows header files? ${x_includes}"
21255else
21256echo " Where do we find X Windows header files? Standard dirs"
21257fi
21258if test -n "${x_libraries}"; then
21259echo " Where do we find X Windows libraries? ${x_libraries}"
21260else
21261echo " Where do we find X Windows libraries? Standard dirs"
21262fi
21263
21264echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
21265echo " Does Emacs use -lXpm? ${HAVE_XPM}"
21266echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
21267echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
21268echo " Does Emacs use -lungif? ${HAVE_GIF}"
21269echo " Does Emacs use -lpng? ${HAVE_PNG}"
21270echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
21271echo
21272
21273# Remove any trailing slashes in these variables.
21274test "${prefix}" != NONE &&
21275 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
21276test "${exec_prefix}" != NONE &&
21277 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
21278
d0e9bfd2
GM
21279## Check if the C preprocessor will convert `..' to `. .'. If so, set
21280## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
21281## from Makefile.c can correctly provide the arg `-traditional' to the
21282## C preprocessor.
21283
503d2be0 21284cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21285/* confdefs.h. */
21286_ACEOF
21287cat confdefs.h >>conftest.$ac_ext
21288cat >>conftest.$ac_ext <<_ACEOF
21289/* end confdefs.h. */
d0e9bfd2 21290yes..yes
503d2be0 21291_ACEOF
d0e9bfd2 21292if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 21293 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
21294 CPP_NEED_TRADITIONAL=no
21295else
d0e9bfd2
GM
21296 CPP_NEED_TRADITIONAL=yes
21297fi
21298rm -f conftest*
21299
c0d27fcc 21300
6bae0ccf
DL
21301 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"
21302 ac_config_commands="$ac_config_commands default"
503d2be0 21303cat >confcache <<\_ACEOF
ba4481b5
DL
21304# This file is a shell script that caches the results of configure
21305# tests run on this system so they can be shared between configure
503d2be0
AS
21306# scripts and configure runs, see configure's option --config-cache.
21307# It is not useful on other systems. If it contains results you don't
21308# want to keep, you may remove or edit it.
ba4481b5 21309#
503d2be0
AS
21310# config.status only pays attention to the cache file if you give it
21311# the --recheck option to rerun configure.
ba4481b5 21312#
6bae0ccf 21313# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
21314# loading this file, other *unset* `ac_cv_foo' will be assigned the
21315# following values.
21316
21317_ACEOF
21318
ba4481b5
DL
21319# The following way of writing the cache mishandles newlines in values,
21320# but we know of no workaround that is simple, portable, and efficient.
21321# So, don't put newlines in cache variables' values.
21322# Ultrix sh set writes to stderr and can't be redirected directly,
21323# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
21324{
21325 (set) 2>&1 |
21326 case `(ac_space=' '; set | grep ac_space) 2>&1` in
21327 *ac_space=\ *)
21328 # `set' does not quote correctly, so add quotes (double-quote
21329 # substitution turns \\\\ into \\, and sed turns \\ into \).
21330 sed -n \
35996d22
AS
21331 "s/'/'\\\\''/g;
21332 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
503d2be0
AS
21333 ;;
21334 *)
21335 # `set' quotes correctly as required by POSIX, so do not add quotes.
21336 sed -n \
35996d22 21337 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
21338 ;;
21339 esac;
21340} |
21341 sed '
21342 t clear
21343 : clear
21344 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21345 t end
21346 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21347 : end' >>confcache
19650fd6 21348if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 21349 if test -w $cache_file; then
503d2be0
AS
21350 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
21351 cat confcache >$cache_file
ba4481b5
DL
21352 else
21353 echo "not updating unwritable cache $cache_file"
21354 fi
21355fi
21356rm -f confcache
21357
ba4481b5
DL
21358test "x$prefix" = xNONE && prefix=$ac_default_prefix
21359# Let make expand exec_prefix.
21360test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21361
503d2be0
AS
21362# VPATH may cause trouble with some makes, so we remove $(srcdir),
21363# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
21364# trailing colons and then remove the whole line if VPATH becomes empty
21365# (actually we leave an empty line to preserve line numbers).
ba4481b5 21366if test "x$srcdir" = x.; then
35996d22 21367 ac_vpsub='/^[ ]*VPATH[ ]*=/{
503d2be0
AS
21368s/:*\$(srcdir):*/:/;
21369s/:*\${srcdir}:*/:/;
21370s/:*@srcdir@:*/:/;
35996d22 21371s/^\([^=]*=[ ]*\):*/\1/;
503d2be0 21372s/:*$//;
35996d22 21373s/^[^=]*=[ ]*$//;
503d2be0 21374}'
ba4481b5
DL
21375fi
21376
ba4481b5
DL
21377DEFS=-DHAVE_CONFIG_H
21378
6bae0ccf
DL
21379ac_libobjs=
21380ac_ltlibobjs=
21381for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21382 # 1. Remove the extension, and $U if already installed.
21383 ac_i=`echo "$ac_i" |
35996d22 21384 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
6bae0ccf
DL
21385 # 2. Add them.
21386 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
21387 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
21388done
21389LIBOBJS=$ac_libobjs
21390
21391LTLIBOBJS=$ac_ltlibobjs
21392
21393
c0d27fcc 21394
ba4481b5 21395: ${CONFIG_STATUS=./config.status}
503d2be0
AS
21396ac_clean_files_save=$ac_clean_files
21397ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 21398{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
21399echo "$as_me: creating $CONFIG_STATUS" >&6;}
21400cat >$CONFIG_STATUS <<_ACEOF
21401#! $SHELL
c0d27fcc 21402# Generated by $as_me.
ba4481b5 21403# Run this file to recreate the current configuration.
ba4481b5 21404# Compiler output produced by configure, useful for debugging
503d2be0 21405# configure, is in config.log if it exists.
ba4481b5 21406
503d2be0 21407debug=false
19650fd6
AS
21408ac_cs_recheck=false
21409ac_cs_silent=false
503d2be0 21410SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
21411_ACEOF
21412
21413cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
21414## --------------------- ##
21415## M4sh Initialization. ##
21416## --------------------- ##
21417
503d2be0
AS
21418# Be Bourne compatible
21419if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
21420 emulate sh
21421 NULLCMD=:
6bae0ccf
DL
21422 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21423 # is contrary to our usage. Disable this feature.
21424 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
21425elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21426 set -o posix
21427fi
35996d22 21428DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 21429
c0d27fcc 21430# Support unset when possible.
35996d22 21431if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
21432 as_unset=unset
21433else
21434 as_unset=false
21435fi
21436
6bae0ccf
DL
21437
21438# Work around bugs in pre-3.0 UWIN ksh.
21439$as_unset ENV MAIL MAILPATH
21440PS1='$ '
21441PS2='> '
21442PS4='+ '
21443
21444# NLS nuisances.
19650fd6
AS
21445for as_var in \
21446 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
21447 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
21448 LC_TELEPHONE LC_TIME
6bae0ccf 21449do
35996d22 21450 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
21451 eval $as_var=C; export $as_var
21452 else
21453 $as_unset $as_var
21454 fi
21455done
21456
21457# Required to use basename.
21458if expr a : '\(a\)' >/dev/null 2>&1; then
21459 as_expr=expr
21460else
21461 as_expr=false
21462fi
21463
21464if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
21465 as_basename=basename
21466else
21467 as_basename=false
21468fi
c0d27fcc
MR
21469
21470
503d2be0 21471# Name of the executable.
6bae0ccf 21472as_me=`$as_basename "$0" ||
c0d27fcc
MR
21473$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21474 X"$0" : 'X\(//\)$' \| \
21475 X"$0" : 'X\(/\)$' \| \
21476 . : '\(.\)' 2>/dev/null ||
21477echo X/"$0" |
21478 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
21479 /^X\/\(\/\/\)$/{ s//\1/; q; }
21480 /^X\/\(\/\).*/{ s//\1/; q; }
21481 s/.*/./; q'`
21482
6bae0ccf 21483
c0d27fcc
MR
21484# PATH needs CR, and LINENO needs CR and PATH.
21485# Avoid depending upon Character Ranges.
21486as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21487as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21488as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21489as_cr_digits='0123456789'
21490as_cr_alnum=$as_cr_Letters$as_cr_digits
21491
21492# The user is always right.
21493if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
21494 echo "#! /bin/sh" >conf$$.sh
21495 echo "exit 0" >>conf$$.sh
21496 chmod +x conf$$.sh
21497 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
21498 PATH_SEPARATOR=';'
21499 else
21500 PATH_SEPARATOR=:
21501 fi
19650fd6 21502 rm -f conf$$.sh
c0d27fcc
MR
21503fi
21504
21505
21506 as_lineno_1=$LINENO
21507 as_lineno_2=$LINENO
21508 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21509 test "x$as_lineno_1" != "x$as_lineno_2" &&
21510 test "x$as_lineno_3" = "x$as_lineno_2" || {
21511 # Find who we are. Look in the path if we contain no path at all
21512 # relative or not.
21513 case $0 in
21514 *[\\/]* ) as_myself=$0 ;;
21515 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21516for as_dir in $PATH
21517do
21518 IFS=$as_save_IFS
21519 test -z "$as_dir" && as_dir=.
21520 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21521done
21522
21523 ;;
21524 esac
21525 # We did not find ourselves, most probably we were run as `sh COMMAND'
21526 # in which case we are not to be found in the path.
21527 if test "x$as_myself" = x; then
21528 as_myself=$0
21529 fi
21530 if test ! -f "$as_myself"; then
21531 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
21532echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
21533 { (exit 1); exit 1; }; }
21534 fi
21535 case $CONFIG_SHELL in
21536 '')
21537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21538for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
21539do
21540 IFS=$as_save_IFS
21541 test -z "$as_dir" && as_dir=.
21542 for as_base in sh bash ksh sh5; do
21543 case $as_dir in
21544 /*)
21545 if ("$as_dir/$as_base" -c '
21546 as_lineno_1=$LINENO
21547 as_lineno_2=$LINENO
21548 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21549 test "x$as_lineno_1" != "x$as_lineno_2" &&
21550 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
21551 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
21552 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
21553 CONFIG_SHELL=$as_dir/$as_base
21554 export CONFIG_SHELL
21555 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
21556 fi;;
21557 esac
21558 done
21559done
21560;;
21561 esac
21562
21563 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
21564 # uniformly replaced by the line number. The first 'sed' inserts a
21565 # line-number line before each line; the second 'sed' does the real
21566 # work. The second script uses 'N' to pair each line-number line
21567 # with the numbered line, and appends trailing '-' during
21568 # substitution so that $LINENO is not a special case at line end.
21569 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
21570 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
21571 sed '=' <$as_myself |
21572 sed '
21573 N
21574 s,$,-,
21575 : loop
21576 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
21577 t loop
21578 s,-$,,
21579 s,^['$as_cr_digits']*\n,,
21580 ' >$as_me.lineno &&
21581 chmod +x $as_me.lineno ||
21582 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
21583echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
21584 { (exit 1); exit 1; }; }
21585
21586 # Don't try to exec as it changes $[0], causing all sort of problems
21587 # (the dirname of $[0] is not the place where we might find the
21588 # original and so on. Autoconf is especially sensible to this).
21589 . ./$as_me.lineno
21590 # Exit status is that of the last command.
21591 exit
21592}
21593
21594
21595case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
21596 *c*,-n*) ECHO_N= ECHO_C='
21597' ECHO_T=' ' ;;
21598 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
21599 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
21600esac
503d2be0
AS
21601
21602if expr a : '\(a\)' >/dev/null 2>&1; then
21603 as_expr=expr
21604else
21605 as_expr=false
21606fi
21607
21608rm -f conf$$ conf$$.exe conf$$.file
21609echo >conf$$.file
21610if ln -s conf$$.file conf$$ 2>/dev/null; then
21611 # We could just check for DJGPP; but this test a) works b) is more generic
21612 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
21613 if test -f conf$$.exe; then
21614 # Don't use ln at all; we don't have any links
21615 as_ln_s='cp -p'
21616 else
21617 as_ln_s='ln -s'
21618 fi
21619elif ln conf$$.file conf$$ 2>/dev/null; then
21620 as_ln_s=ln
21621else
21622 as_ln_s='cp -p'
21623fi
21624rm -f conf$$ conf$$.exe conf$$.file
21625
6bae0ccf
DL
21626if mkdir -p . 2>/dev/null; then
21627 as_mkdir_p=:
21628else
35996d22 21629 test -d ./-p && rmdir ./-p
6bae0ccf
DL
21630 as_mkdir_p=false
21631fi
21632
503d2be0
AS
21633as_executable_p="test -f"
21634
c0d27fcc 21635# Sed expression to map a string onto a valid CPP name.
35996d22 21636as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
21637
21638# Sed expression to map a string onto a valid variable name.
35996d22 21639as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 21640
503d2be0
AS
21641
21642# IFS
21643# We need space, tab and new line, in precisely that order.
21644as_nl='
21645'
21646IFS=" $as_nl"
21647
21648# CDPATH.
6bae0ccf 21649$as_unset CDPATH
503d2be0
AS
21650
21651exec 6>&1
21652
c0d27fcc
MR
21653# Open the log real soon, to keep \$[0] and so on meaningful, and to
21654# report actual input values of CONFIG_FILES etc. instead of their
21655# values after options handling. Logging --version etc. is OK.
21656exec 5>>config.log
21657{
21658 echo
21659 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
21660## Running $as_me. ##
21661_ASBOX
21662} >&5
21663cat >&5 <<_CSEOF
21664
21665This file was extended by $as_me, which was
35996d22 21666generated by GNU Autoconf 2.59. Invocation command line was
c0d27fcc
MR
21667
21668 CONFIG_FILES = $CONFIG_FILES
21669 CONFIG_HEADERS = $CONFIG_HEADERS
21670 CONFIG_LINKS = $CONFIG_LINKS
21671 CONFIG_COMMANDS = $CONFIG_COMMANDS
21672 $ $0 $@
21673
21674_CSEOF
21675echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
21676echo >&5
503d2be0
AS
21677_ACEOF
21678
21679# Files that config.status was made for.
21680if test -n "$ac_config_files"; then
21681 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
21682fi
21683
21684if test -n "$ac_config_headers"; then
21685 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
21686fi
21687
21688if test -n "$ac_config_links"; then
21689 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
21690fi
21691
21692if test -n "$ac_config_commands"; then
21693 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
21694fi
21695
c0d27fcc 21696cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21697
21698ac_cs_usage="\
21699\`$as_me' instantiates files from templates according to the
21700current configuration.
21701
21702Usage: $0 [OPTIONS] [FILE]...
21703
21704 -h, --help print this help, then exit
21705 -V, --version print version number, then exit
19650fd6 21706 -q, --quiet do not print progress messages
503d2be0
AS
21707 -d, --debug don't remove temporary files
21708 --recheck update $as_me by reconfiguring in the same conditions
21709 --file=FILE[:TEMPLATE]
35996d22 21710 instantiate the configuration file FILE
503d2be0 21711 --header=FILE[:TEMPLATE]
35996d22 21712 instantiate the configuration header FILE
503d2be0
AS
21713
21714Configuration files:
21715$config_files
21716
21717Configuration headers:
21718$config_headers
21719
21720Configuration commands:
21721$config_commands
21722
21723Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 21724_ACEOF
503d2be0 21725
c0d27fcc 21726cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21727ac_cs_version="\\
21728config.status
35996d22 21729configured by $0, generated by GNU Autoconf 2.59,
503d2be0
AS
21730 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
21731
35996d22 21732Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
21733This config.status script is free software; the Free Software Foundation
21734gives unlimited permission to copy, distribute and modify it."
21735srcdir=$srcdir
21736INSTALL="$INSTALL"
c0d27fcc 21737_ACEOF
503d2be0 21738
c0d27fcc 21739cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21740# If no file are specified by the user, then we need to provide default
21741# value. By we need to know if files were specified by the user.
21742ac_need_defaults=:
21743while test $# != 0
ba4481b5 21744do
503d2be0
AS
21745 case $1 in
21746 --*=*)
21747 ac_option=`expr "x$1" : 'x\([^=]*\)='`
21748 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
21749 ac_shift=:
21750 ;;
21751 -*)
21752 ac_option=$1
21753 ac_optarg=$2
21754 ac_shift=shift
503d2be0 21755 ;;
503d2be0
AS
21756 *) # This is not an option, so the user has probably given explicit
21757 # arguments.
6bae0ccf 21758 ac_option=$1
503d2be0
AS
21759 ac_need_defaults=false;;
21760 esac
21761
6bae0ccf 21762 case $ac_option in
503d2be0 21763 # Handling of the options.
c0d27fcc 21764_ACEOF
f57bd967 21765cat >>$CONFIG_STATUS <<\_ACEOF
19650fd6
AS
21766 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
21767 ac_cs_recheck=: ;;
503d2be0
AS
21768 --version | --vers* | -V )
21769 echo "$ac_cs_version"; exit 0 ;;
21770 --he | --h)
21771 # Conflict between --help and --header
c0d27fcc 21772 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
21773Try \`$0 --help' for more information." >&5
21774echo "$as_me: error: ambiguous option: $1
21775Try \`$0 --help' for more information." >&2;}
21776 { (exit 1); exit 1; }; };;
21777 --help | --hel | -h )
21778 echo "$ac_cs_usage"; exit 0 ;;
21779 --debug | --d* | -d )
21780 debug=: ;;
21781 --file | --fil | --fi | --f )
6bae0ccf
DL
21782 $ac_shift
21783 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
21784 ac_need_defaults=false;;
21785 --header | --heade | --head | --hea )
6bae0ccf
DL
21786 $ac_shift
21787 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 21788 ac_need_defaults=false;;
19650fd6
AS
21789 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
21790 | -silent | --silent | --silen | --sile | --sil | --si | --s)
21791 ac_cs_silent=: ;;
503d2be0
AS
21792
21793 # This is an error.
c0d27fcc 21794 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
21795Try \`$0 --help' for more information." >&5
21796echo "$as_me: error: unrecognized option: $1
21797Try \`$0 --help' for more information." >&2;}
21798 { (exit 1); exit 1; }; } ;;
21799
21800 *) ac_config_targets="$ac_config_targets $1" ;;
21801
ba4481b5 21802 esac
503d2be0 21803 shift
ba4481b5
DL
21804done
21805
19650fd6
AS
21806ac_configure_extra_args=
21807
21808if $ac_cs_silent; then
21809 exec 6>/dev/null
21810 ac_configure_extra_args="$ac_configure_extra_args --silent"
21811fi
21812
21813_ACEOF
21814cat >>$CONFIG_STATUS <<_ACEOF
21815if \$ac_cs_recheck; then
21816 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
21817 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
21818fi
21819
503d2be0 21820_ACEOF
ba4481b5 21821
c0d27fcc 21822cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21823#
21824# INIT-COMMANDS section.
21825#
ba4481b5 21826
503d2be0
AS
21827GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
21828
c0d27fcc
MR
21829_ACEOF
21830
503d2be0 21831
c0d27fcc
MR
21832
21833cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21834for ac_config_target in $ac_config_targets
21835do
21836 case "$ac_config_target" in
21837 # Handling of arguments.
21838 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
21839 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
21840 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
21841 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
21842 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
21843 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
21844 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 21845 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 21846 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
21847 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
21848 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
21849 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 21850 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
21851echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
21852 { (exit 1); exit 1; }; };;
21853 esac
ba4481b5 21854done
503d2be0
AS
21855
21856# If the user did not use the arguments to specify the items to instantiate,
21857# then the envvar interface is used. Set only those that are not.
21858# We use the long form for the default assignment because of an extremely
21859# bizarre bug on SunOS 4.1.3.
21860if $ac_need_defaults; then
21861 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
21862 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
21863 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 21864fi
503d2be0 21865
19650fd6
AS
21866# Have a temporary directory for convenience. Make it in the build tree
21867# simply because there is no reason to put it here, and in addition,
21868# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
21869# Create a temporary directory, and hook for its removal unless debugging.
21870$debug ||
21871{
21872 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
21873 trap '{ (exit 1); exit 1; }' 1 2 13 15
21874}
21875
21876# Create a (secure) tmp directory for tmp files.
19650fd6 21877
503d2be0 21878{
19650fd6 21879 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
21880 test -n "$tmp" && test -d "$tmp"
21881} ||
21882{
19650fd6 21883 tmp=./confstat$$-$RANDOM
503d2be0
AS
21884 (umask 077 && mkdir $tmp)
21885} ||
21886{
19650fd6 21887 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
21888 { (exit 1); exit 1; }
21889}
21890
c0d27fcc 21891_ACEOF
503d2be0 21892
c0d27fcc 21893cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21894
21895#
21896# CONFIG_FILES section.
21897#
21898
21899# No need to generate the scripts if there are no CONFIG_FILES.
21900# This happens for instance when ./config.status config.h
21901if test -n "\$CONFIG_FILES"; then
21902 # Protect against being on the right side of a sed subst in config.status.
21903 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
21904 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
21905s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
21906s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
21907s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
21908s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
21909s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
21910s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
21911s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
21912s,@exec_prefix@,$exec_prefix,;t t
21913s,@prefix@,$prefix,;t t
21914s,@program_transform_name@,$program_transform_name,;t t
21915s,@bindir@,$bindir,;t t
21916s,@sbindir@,$sbindir,;t t
21917s,@libexecdir@,$libexecdir,;t t
21918s,@datadir@,$datadir,;t t
21919s,@sysconfdir@,$sysconfdir,;t t
21920s,@sharedstatedir@,$sharedstatedir,;t t
21921s,@localstatedir@,$localstatedir,;t t
21922s,@libdir@,$libdir,;t t
21923s,@includedir@,$includedir,;t t
21924s,@oldincludedir@,$oldincludedir,;t t
21925s,@infodir@,$infodir,;t t
21926s,@mandir@,$mandir,;t t
503d2be0
AS
21927s,@build_alias@,$build_alias,;t t
21928s,@host_alias@,$host_alias,;t t
21929s,@target_alias@,$target_alias,;t t
c0d27fcc 21930s,@DEFS@,$DEFS,;t t
503d2be0
AS
21931s,@ECHO_C@,$ECHO_C,;t t
21932s,@ECHO_N@,$ECHO_N,;t t
21933s,@ECHO_T@,$ECHO_T,;t t
503d2be0 21934s,@LIBS@,$LIBS,;t t
19650fd6 21935s,@MAINT@,$MAINT,;t t
503d2be0
AS
21936s,@build@,$build,;t t
21937s,@build_cpu@,$build_cpu,;t t
21938s,@build_vendor@,$build_vendor,;t t
21939s,@build_os@,$build_os,;t t
21940s,@host@,$host,;t t
21941s,@host_cpu@,$host_cpu,;t t
21942s,@host_vendor@,$host_vendor,;t t
21943s,@host_os@,$host_os,;t t
21944s,@CC@,$CC,;t t
21945s,@CFLAGS@,$CFLAGS,;t t
21946s,@LDFLAGS@,$LDFLAGS,;t t
21947s,@CPPFLAGS@,$CPPFLAGS,;t t
21948s,@ac_ct_CC@,$ac_ct_CC,;t t
21949s,@EXEEXT@,$EXEEXT,;t t
21950s,@OBJEXT@,$OBJEXT,;t t
21951s,@LN_S@,$LN_S,;t t
21952s,@CPP@,$CPP,;t t
21953s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
21954s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
21955s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
21956s,@RANLIB@,$RANLIB,;t t
21957s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 21958s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 21959s,@EGREP@,$EGREP,;t t
503d2be0
AS
21960s,@LIBSOUND@,$LIBSOUND,;t t
21961s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
21962s,@PKG_CONFIG@,$PKG_CONFIG,;t t
21963s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
21964s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
21965s,@ALLOCA@,$ALLOCA,;t t
21966s,@liblockfile@,$liblockfile,;t t
21967s,@LIBOBJS@,$LIBOBJS,;t t
21968s,@NEED_SETGID@,$NEED_SETGID,;t t
21969s,@KMEM_GROUP@,$KMEM_GROUP,;t t
21970s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
21971s,@version@,$version,;t t
21972s,@configuration@,$configuration,;t t
21973s,@canonical@,$canonical,;t t
21974s,@srcdir@,$srcdir,;t t
21975s,@lispdir@,$lispdir,;t t
21976s,@locallisppath@,$locallisppath,;t t
21977s,@lisppath@,$lisppath,;t t
21978s,@x_default_search_path@,$x_default_search_path,;t t
21979s,@etcdir@,$etcdir,;t t
21980s,@archlibdir@,$archlibdir,;t t
21981s,@docdir@,$docdir,;t t
21982s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
21983s,@gamedir@,$gamedir,;t t
21984s,@gameuser@,$gameuser,;t t
503d2be0
AS
21985s,@c_switch_system@,$c_switch_system,;t t
21986s,@c_switch_machine@,$c_switch_machine,;t t
21987s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
21988s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
21989s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
21990s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
21991s,@machfile@,$machfile,;t t
21992s,@opsysfile@,$opsysfile,;t t
6a3a24fa 21993s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 21994s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
21995CEOF
21996
c0d27fcc 21997_ACEOF
ba4481b5 21998
c0d27fcc 21999 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22000 # Split the substitutions into bite-sized pieces for seds with
22001 # small command number limits, like on Digital OSF/1 and HP-UX.
22002 ac_max_sed_lines=48
22003 ac_sed_frag=1 # Number of current file.
22004 ac_beg=1 # First line for current file.
22005 ac_end=$ac_max_sed_lines # Line after last line for current file.
22006 ac_more_lines=:
22007 ac_sed_cmds=
22008 while $ac_more_lines; do
22009 if test $ac_beg -gt 1; then
22010 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22011 else
22012 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22013 fi
22014 if test ! -s $tmp/subs.frag; then
22015 ac_more_lines=false
22016 else
22017 # The purpose of the label and of the branching condition is to
22018 # speed up the sed processing (if there are no `@' at all, there
22019 # is no need to browse any of the substitutions).
22020 # These are the two extra sed commands mentioned above.
22021 (echo ':t
22022 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22023 if test -z "$ac_sed_cmds"; then
35996d22 22024 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0 22025 else
35996d22 22026 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0
AS
22027 fi
22028 ac_sed_frag=`expr $ac_sed_frag + 1`
22029 ac_beg=$ac_end
22030 ac_end=`expr $ac_end + $ac_max_sed_lines`
22031 fi
22032 done
22033 if test -z "$ac_sed_cmds"; then
22034 ac_sed_cmds=cat
22035 fi
22036fi # test -n "$CONFIG_FILES"
ba4481b5 22037
c0d27fcc
MR
22038_ACEOF
22039cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 22040for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 22041 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22042 case $ac_file in
22043 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22044 cat >$tmp/stdin
22045 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22046 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22047 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22048 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22049 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22050 esac
22051
503d2be0 22052 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
22053 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22054$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22055 X"$ac_file" : 'X\(//\)[^/]' \| \
22056 X"$ac_file" : 'X\(//\)$' \| \
22057 X"$ac_file" : 'X\(/\)' \| \
22058 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22059echo X"$ac_file" |
22060 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22061 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22062 /^X\(\/\/\)$/{ s//\1/; q; }
22063 /^X\(\/\).*/{ s//\1/; q; }
22064 s/.*/./; q'`
6bae0ccf
DL
22065 { if $as_mkdir_p; then
22066 mkdir -p "$ac_dir"
22067 else
22068 as_dir="$ac_dir"
22069 as_dirs=
22070 while test ! -d "$as_dir"; do
22071 as_dirs="$as_dir $as_dirs"
22072 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22073$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22074 X"$as_dir" : 'X\(//\)[^/]' \| \
22075 X"$as_dir" : 'X\(//\)$' \| \
22076 X"$as_dir" : 'X\(/\)' \| \
22077 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22078echo X"$as_dir" |
22079 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22080 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22081 /^X\(\/\/\)$/{ s//\1/; q; }
22082 /^X\(\/\).*/{ s//\1/; q; }
22083 s/.*/./; q'`
22084 done
22085 test ! -n "$as_dirs" || mkdir $as_dirs
22086 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22087echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22088 { (exit 1); exit 1; }; }; }
503d2be0 22089
c0d27fcc 22090 ac_builddir=.
98418dba 22091
c0d27fcc
MR
22092if test "$ac_dir" != .; then
22093 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22094 # A "../" for each directory in $ac_dir_suffix.
22095 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22096else
22097 ac_dir_suffix= ac_top_builddir=
22098fi
22099
22100case $srcdir in
22101 .) # No --srcdir option. We are building in place.
22102 ac_srcdir=.
22103 if test -z "$ac_top_builddir"; then
22104 ac_top_srcdir=.
22105 else
22106 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22107 fi ;;
22108 [\\/]* | ?:[\\/]* ) # Absolute path.
22109 ac_srcdir=$srcdir$ac_dir_suffix;
22110 ac_top_srcdir=$srcdir ;;
ba4481b5 22111 *) # Relative path.
c0d27fcc
MR
22112 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22113 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22114esac
35996d22
AS
22115
22116# Do not use `cd foo && pwd` to compute absolute paths, because
22117# the directories may not exist.
22118case `pwd` in
22119.) ac_abs_builddir="$ac_dir";;
22120*)
22121 case "$ac_dir" in
22122 .) ac_abs_builddir=`pwd`;;
22123 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22124 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22125 esac;;
22126esac
22127case $ac_abs_builddir in
22128.) ac_abs_top_builddir=${ac_top_builddir}.;;
22129*)
22130 case ${ac_top_builddir}. in
22131 .) ac_abs_top_builddir=$ac_abs_builddir;;
22132 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22133 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22134 esac;;
22135esac
22136case $ac_abs_builddir in
22137.) ac_abs_srcdir=$ac_srcdir;;
22138*)
22139 case $ac_srcdir in
22140 .) ac_abs_srcdir=$ac_abs_builddir;;
22141 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22142 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22143 esac;;
22144esac
22145case $ac_abs_builddir in
22146.) ac_abs_top_srcdir=$ac_top_srcdir;;
22147*)
22148 case $ac_top_srcdir in
22149 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22150 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22151 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22152 esac;;
22153esac
c0d27fcc 22154
ba4481b5 22155
503d2be0
AS
22156 case $INSTALL in
22157 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 22158 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
22159 esac
22160
503d2be0 22161 if test x"$ac_file" != x-; then
c0d27fcc 22162 { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
22163echo "$as_me: creating $ac_file" >&6;}
22164 rm -f "$ac_file"
22165 fi
22166 # Let's still pretend it is `configure' which instantiates (i.e., don't
22167 # use $as_me), people would be surprised to read:
c0d27fcc
MR
22168 # /* config.h. Generated by config.status. */
22169 if test x"$ac_file" = x-; then
22170 configure_input=
22171 else
22172 configure_input="$ac_file. "
22173 fi
22174 configure_input=$configure_input"Generated from `echo $ac_file_in |
35996d22 22175 sed 's,.*/,,'` by configure."
503d2be0
AS
22176
22177 # First look for the input files in the build tree, otherwise in the
22178 # src tree.
22179 ac_file_inputs=`IFS=:
22180 for f in $ac_file_in; do
22181 case $f in
22182 -) echo $tmp/stdin ;;
22183 [\\/$]*)
35996d22
AS
22184 # Absolute (can't be DOS-style, as IFS=:)
22185 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22186echo "$as_me: error: cannot find input file: $f" >&2;}
22187 { (exit 1); exit 1; }; }
35996d22 22188 echo "$f";;
503d2be0 22189 *) # Relative
35996d22
AS
22190 if test -f "$f"; then
22191 # Build tree
22192 echo "$f"
22193 elif test -f "$srcdir/$f"; then
22194 # Source tree
22195 echo "$srcdir/$f"
22196 else
22197 # /dev/null tree
22198 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22199echo "$as_me: error: cannot find input file: $f" >&2;}
22200 { (exit 1); exit 1; }; }
35996d22 22201 fi;;
503d2be0
AS
22202 esac
22203 done` || { (exit 1); exit 1; }
c0d27fcc
MR
22204_ACEOF
22205cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
22206 sed "$ac_vpsub
22207$extrasub
c0d27fcc
MR
22208_ACEOF
22209cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22210:t
22211/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22212s,@configure_input@,$configure_input,;t t
22213s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 22214s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 22215s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
22216s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
22217s,@builddir@,$ac_builddir,;t t
22218s,@abs_builddir@,$ac_abs_builddir,;t t
22219s,@top_builddir@,$ac_top_builddir,;t t
22220s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
22221s,@INSTALL@,$ac_INSTALL,;t t
22222" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
22223 rm -f $tmp/stdin
22224 if test x"$ac_file" != x-; then
22225 mv $tmp/out $ac_file
22226 else
22227 cat $tmp/out
22228 rm -f $tmp/out
22229 fi
22230
22231done
c0d27fcc
MR
22232_ACEOF
22233cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22234
503d2be0
AS
22235#
22236# CONFIG_HEADER section.
22237#
ba4481b5
DL
22238
22239# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
22240# NAME is the cpp macro being defined and VALUE is the value it is being given.
22241#
22242# ac_d sets the value in "#define NAME VALUE" lines.
35996d22
AS
22243ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
22244ac_dB='[ ].*$,\1#\2'
503d2be0
AS
22245ac_dC=' '
22246ac_dD=',;t'
22247# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
35996d22 22248ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
503d2be0 22249ac_uB='$,\1#\2define\3'
ba4481b5 22250ac_uC=' '
503d2be0 22251ac_uD=',;t'
ba4481b5 22252
503d2be0 22253for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 22254 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22255 case $ac_file in
22256 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22257 cat >$tmp/stdin
22258 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22259 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22260 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22261 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22262 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22263 esac
22264
c0d27fcc 22265 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
22266echo "$as_me: creating $ac_file" >&6;}
22267
22268 # First look for the input files in the build tree, otherwise in the
22269 # src tree.
22270 ac_file_inputs=`IFS=:
22271 for f in $ac_file_in; do
22272 case $f in
22273 -) echo $tmp/stdin ;;
22274 [\\/$]*)
35996d22
AS
22275 # Absolute (can't be DOS-style, as IFS=:)
22276 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22277echo "$as_me: error: cannot find input file: $f" >&2;}
22278 { (exit 1); exit 1; }; }
35996d22
AS
22279 # Do quote $f, to prevent DOS paths from being IFS'd.
22280 echo "$f";;
503d2be0 22281 *) # Relative
35996d22
AS
22282 if test -f "$f"; then
22283 # Build tree
22284 echo "$f"
22285 elif test -f "$srcdir/$f"; then
22286 # Source tree
22287 echo "$srcdir/$f"
22288 else
22289 # /dev/null tree
22290 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22291echo "$as_me: error: cannot find input file: $f" >&2;}
22292 { (exit 1); exit 1; }; }
35996d22 22293 fi;;
503d2be0
AS
22294 esac
22295 done` || { (exit 1); exit 1; }
22296 # Remove the trailing spaces.
35996d22 22297 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
503d2be0 22298
c0d27fcc 22299_ACEOF
503d2be0
AS
22300
22301# Transform confdefs.h into two sed scripts, `conftest.defines' and
22302# `conftest.undefs', that substitutes the proper values into
22303# config.h.in to produce config.h. The first handles `#define'
22304# templates, and the second `#undef' templates.
22305# And first: Protect against being on the right side of a sed subst in
22306# config.status. Protect against being in an unquoted here document
22307# in config.status.
22308rm -f conftest.defines conftest.undefs
22309# Using a here document instead of a string reduces the quoting nightmare.
22310# Putting comments in sed scripts is not portable.
22311#
22312# `end' is used to avoid that the second main sed command (meant for
22313# 0-ary CPP macros) applies to n-ary macro definitions.
22314# See the Autoconf documentation for `clear'.
c0d27fcc 22315cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
22316s/[\\&,]/\\&/g
22317s,[\\$`],\\&,g
22318t clear
22319: clear
35996d22 22320s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0 22321t end
35996d22 22322s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
503d2be0 22323: end
c0d27fcc 22324_ACEOF
503d2be0
AS
22325# If some macros were called several times there might be several times
22326# the same #defines, which is useless. Nevertheless, we may not want to
22327# sort them, since we want the *last* AC-DEFINE to be honored.
22328uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
22329sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
22330rm -f confdef2sed.sed
ba4481b5
DL
22331
22332# This sed command replaces #undef with comments. This is necessary, for
22333# example, in the case of _POSIX_SOURCE, which is predefined and required
22334# on some systems where configure will not decide to define it.
c0d27fcc 22335cat >>conftest.undefs <<\_ACEOF
35996d22 22336s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 22337_ACEOF
ba4481b5 22338
503d2be0
AS
22339# Break up conftest.defines because some shells have a limit on the size
22340# of here documents, and old seds have small limits too (100 cmds).
22341echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
35996d22 22342echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
22343echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
22344echo ' :' >>$CONFIG_STATUS
22345rm -f conftest.tail
22346while grep . conftest.defines >/dev/null
22347do
22348 # Write a limited-size here document to $tmp/defines.sed.
22349 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
22350 # Speed up: don't consider the non `#define' lines.
35996d22 22351 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
503d2be0
AS
22352 # Work around the forget-to-reset-the-flag bug.
22353 echo 't clr' >>$CONFIG_STATUS
22354 echo ': clr' >>$CONFIG_STATUS
22355 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
22356 echo 'CEOF
22357 sed -f $tmp/defines.sed $tmp/in >$tmp/out
22358 rm -f $tmp/in
22359 mv $tmp/out $tmp/in
22360' >>$CONFIG_STATUS
22361 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
22362 rm -f conftest.defines
22363 mv conftest.tail conftest.defines
22364done
22365rm -f conftest.defines
6bae0ccf 22366echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 22367echo >>$CONFIG_STATUS
ba4481b5 22368
503d2be0
AS
22369# Break up conftest.undefs because some shells have a limit on the size
22370# of here documents, and old seds have small limits too (100 cmds).
22371echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 22372rm -f conftest.tail
503d2be0 22373while grep . conftest.undefs >/dev/null
ba4481b5 22374do
503d2be0
AS
22375 # Write a limited-size here document to $tmp/undefs.sed.
22376 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
22377 # Speed up: don't consider the non `#undef'
35996d22 22378 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
503d2be0
AS
22379 # Work around the forget-to-reset-the-flag bug.
22380 echo 't clr' >>$CONFIG_STATUS
22381 echo ': clr' >>$CONFIG_STATUS
22382 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 22383 echo 'CEOF
503d2be0
AS
22384 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
22385 rm -f $tmp/in
22386 mv $tmp/out $tmp/in
22387' >>$CONFIG_STATUS
22388 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
22389 rm -f conftest.undefs
22390 mv conftest.tail conftest.undefs
ba4481b5 22391done
503d2be0
AS
22392rm -f conftest.undefs
22393
c0d27fcc 22394cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22395 # Let's still pretend it is `configure' which instantiates (i.e., don't
22396 # use $as_me), people would be surprised to read:
c0d27fcc 22397 # /* config.h. Generated by config.status. */
503d2be0 22398 if test x"$ac_file" = x-; then
c0d27fcc 22399 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 22400 else
c0d27fcc 22401 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
22402 fi
22403 cat $tmp/in >>$tmp/config.h
22404 rm -f $tmp/in
22405 if test x"$ac_file" != x-; then
19650fd6 22406 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 22407 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
22408echo "$as_me: $ac_file is unchanged" >&6;}
22409 else
c0d27fcc
MR
22410 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22411$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22412 X"$ac_file" : 'X\(//\)[^/]' \| \
22413 X"$ac_file" : 'X\(//\)$' \| \
22414 X"$ac_file" : 'X\(/\)' \| \
22415 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22416echo X"$ac_file" |
22417 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22418 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22419 /^X\(\/\/\)$/{ s//\1/; q; }
22420 /^X\(\/\).*/{ s//\1/; q; }
22421 s/.*/./; q'`
6bae0ccf
DL
22422 { if $as_mkdir_p; then
22423 mkdir -p "$ac_dir"
22424 else
22425 as_dir="$ac_dir"
22426 as_dirs=
22427 while test ! -d "$as_dir"; do
22428 as_dirs="$as_dir $as_dirs"
22429 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22430$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22431 X"$as_dir" : 'X\(//\)[^/]' \| \
22432 X"$as_dir" : 'X\(//\)$' \| \
22433 X"$as_dir" : 'X\(/\)' \| \
22434 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22435echo X"$as_dir" |
22436 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22437 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22438 /^X\(\/\/\)$/{ s//\1/; q; }
22439 /^X\(\/\).*/{ s//\1/; q; }
22440 s/.*/./; q'`
22441 done
22442 test ! -n "$as_dirs" || mkdir $as_dirs
22443 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22444echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22445 { (exit 1); exit 1; }; }; }
503d2be0 22446
503d2be0
AS
22447 rm -f $ac_file
22448 mv $tmp/config.h $ac_file
ba4481b5 22449 fi
503d2be0
AS
22450 else
22451 cat $tmp/config.h
22452 rm -f $tmp/config.h
ba4481b5 22453 fi
503d2be0 22454done
c0d27fcc
MR
22455_ACEOF
22456cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22457
22458#
22459# CONFIG_COMMANDS section.
22460#
22461for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
22462 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
22463 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
22464 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
22465$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22466 X"$ac_dest" : 'X\(//\)[^/]' \| \
22467 X"$ac_dest" : 'X\(//\)$' \| \
22468 X"$ac_dest" : 'X\(/\)' \| \
22469 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
22470echo X"$ac_dest" |
22471 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22472 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22473 /^X\(\/\/\)$/{ s//\1/; q; }
22474 /^X\(\/\).*/{ s//\1/; q; }
22475 s/.*/./; q'`
35996d22
AS
22476 { if $as_mkdir_p; then
22477 mkdir -p "$ac_dir"
22478 else
22479 as_dir="$ac_dir"
22480 as_dirs=
22481 while test ! -d "$as_dir"; do
22482 as_dirs="$as_dir $as_dirs"
22483 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22484$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22485 X"$as_dir" : 'X\(//\)[^/]' \| \
22486 X"$as_dir" : 'X\(//\)$' \| \
22487 X"$as_dir" : 'X\(/\)' \| \
22488 . : '\(.\)' 2>/dev/null ||
22489echo X"$as_dir" |
22490 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22491 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22492 /^X\(\/\/\)$/{ s//\1/; q; }
22493 /^X\(\/\).*/{ s//\1/; q; }
22494 s/.*/./; q'`
22495 done
22496 test ! -n "$as_dirs" || mkdir $as_dirs
22497 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22498echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22499 { (exit 1); exit 1; }; }; }
22500
c0d27fcc
MR
22501 ac_builddir=.
22502
22503if test "$ac_dir" != .; then
22504 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22505 # A "../" for each directory in $ac_dir_suffix.
22506 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22507else
22508 ac_dir_suffix= ac_top_builddir=
22509fi
22510
22511case $srcdir in
22512 .) # No --srcdir option. We are building in place.
22513 ac_srcdir=.
22514 if test -z "$ac_top_builddir"; then
22515 ac_top_srcdir=.
22516 else
22517 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22518 fi ;;
22519 [\\/]* | ?:[\\/]* ) # Absolute path.
22520 ac_srcdir=$srcdir$ac_dir_suffix;
22521 ac_top_srcdir=$srcdir ;;
22522 *) # Relative path.
22523 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22524 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22525esac
35996d22
AS
22526
22527# Do not use `cd foo && pwd` to compute absolute paths, because
22528# the directories may not exist.
22529case `pwd` in
22530.) ac_abs_builddir="$ac_dir";;
22531*)
22532 case "$ac_dir" in
22533 .) ac_abs_builddir=`pwd`;;
22534 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22535 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22536 esac;;
22537esac
22538case $ac_abs_builddir in
22539.) ac_abs_top_builddir=${ac_top_builddir}.;;
22540*)
22541 case ${ac_top_builddir}. in
22542 .) ac_abs_top_builddir=$ac_abs_builddir;;
22543 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22544 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22545 esac;;
22546esac
22547case $ac_abs_builddir in
22548.) ac_abs_srcdir=$ac_srcdir;;
22549*)
22550 case $ac_srcdir in
22551 .) ac_abs_srcdir=$ac_abs_builddir;;
22552 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22553 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22554 esac;;
22555esac
22556case $ac_abs_builddir in
22557.) ac_abs_top_srcdir=$ac_top_srcdir;;
22558*)
22559 case $ac_top_srcdir in
22560 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22561 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22562 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22563 esac;;
22564esac
ba4481b5 22565
c0d27fcc
MR
22566
22567 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
22568echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
22569 case $ac_dest in
22570 default )
ba4481b5
DL
22571
22572### Make the necessary directories, if they don't exist.
22573for dir in etc lisp ; do
22574 test -d ${dir} || mkdir ${dir}
22575done
22576
22577# Build src/Makefile from ${srcdir}/src/Makefile.c
22578# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
22579# This must be done after src/config.h is built, since we rely on that file.
22580
22581# Now get this: Some word that is part of the ${srcdir} directory name
22582# or the ${configuration} value might, just might, happen to be an
22583# identifier like `sun4' or `i386' or something, and be predefined by
22584# the C preprocessor to some helpful value like 1, or maybe the empty
22585# string. Needless to say consequent macro substitutions are less
22586# than conducive to the makefile finding the correct directory.
22587undefs="`echo $top_srcdir $configuration $canonical |
22588sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
22589 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
22590`"
22591
22592echo creating src/epaths.h
4aa6b955 22593${MAKE-make} epaths-force
ba4481b5 22594
1c203d4c
DL
22595# As of 2000-11-19, newest development versions of GNU cpp preprocess
22596# `..' to `. .' unless invoked with -traditional
22597
d0e9bfd2 22598if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
22599 CPPFLAGS="$CPPFLAGS -traditional"
22600fi
22601
ba4481b5
DL
22602echo creating lib-src/Makefile
22603( cd lib-src
22604 rm -f junk.c junk1.c junk2.c
22605 sed -e '/start of cpp stuff/q' \
22606 < Makefile.c > junk1.c
22607 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22608 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22609 < Makefile.c > junk.c
503d2be0 22610 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22611 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22612 cat junk1.c junk2.c > Makefile.new
22613 rm -f junk.c junk1.c junk2.c
22614 chmod 444 Makefile.new
22615 mv -f Makefile.new Makefile
22616)
22617
22618echo creating src/Makefile
22619( cd src
22620 rm -f junk.c junk1.c junk2.c
22621 sed -e '/start of cpp stuff/q' \
22622 < Makefile.c > junk1.c
22623 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22624 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22625 < Makefile.c > junk.c
503d2be0 22626 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22627 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22628 cat junk1.c junk2.c > Makefile.new
22629 rm -f junk.c junk1.c junk2.c
22630 chmod 444 Makefile.new
22631 mv -f Makefile.new Makefile
22632)
22633
503d2be0 22634if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 22635 echo creating src/.gdbinit
503d2be0 22636 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
22637fi
22638
22639# This is how we know whether to re-run configure in certain cases.
22640touch src/config.stamp
22641
503d2be0
AS
22642 ;;
22643 esac
22644done
c0d27fcc 22645_ACEOF
503d2be0 22646
c0d27fcc 22647cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22648
503d2be0 22649{ (exit 0); exit 0; }
c0d27fcc 22650_ACEOF
ba4481b5 22651chmod +x $CONFIG_STATUS
503d2be0
AS
22652ac_clean_files=$ac_clean_files_save
22653
c0d27fcc 22654
503d2be0
AS
22655# configure is writing to config.log, and then calls config.status.
22656# config.status does its own redirection, appending to config.log.
22657# Unfortunately, on DOS this fails, as config.log is still kept open
22658# by configure, so config.status won't be able to write to it; its
22659# output is simply discarded. So we exec the FD to /dev/null,
22660# effectively closing config.log, so it can be properly (re)opened and
22661# appended to by config.status. When coming back to configure, we
22662# need to make the FD available again.
22663if test "$no_create" != yes; then
22664 ac_cs_success=:
19650fd6
AS
22665 ac_config_status_args=
22666 test "$silent" = yes &&
22667 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 22668 exec 5>/dev/null
19650fd6 22669 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
22670 exec 5>>config.log
22671 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
22672 # would make configure fail if this is the last instruction.
22673 $ac_cs_success || { (exit 1); exit 1; }
22674fi
f5f47add 22675
c0d27fcc 22676