(overlay_arrow_at_row): Add HAVE_WINDOW_SYSTEM conditional.
[bpt/emacs.git] / configure
CommitLineData
ba4481b5 1#! /bin/sh
ba4481b5 2# Guess values for system-dependent variables and create Makefiles.
edfaf76d 3# Generated by GNU Autoconf 2.59.
ba4481b5 4#
edfaf76d 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
edfaf76d 22DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 23
c0d27fcc 24# Support unset when possible.
edfaf76d 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
edfaf76d 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
edfaf76d 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.
edfaf76d 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.
edfaf76d 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
52dbaac8 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 GETOPT_H GETOPTOBJS 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 \
edfaf76d 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\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
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
edfaf76d 807 [$ac_default_prefix]
503d2be0 808 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
edfaf76d 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
d0098f13 859 --enable-asserts compile code with asserts enabled
19650fd6
AS
860 --enable-maintainer-mode enable make rules and dependencies not useful
861 (and sometimes confusing) to the casual installer
9adfabc2
LK
862 --enable-locallisppath=PATH
863 directories Emacs should search for lisp files
864 specific to this site
503d2be0
AS
865 --disable-largefile omit support for large files
866
867Optional Packages:
868 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
869 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
870 --without-gcc don't use GCC to compile Emacs if GCC is found
871 --without-pop don't support POP mail retrieval with movemail
872 --with-kerberos support Kerberos-authenticated POP
873 --with-kerberos5 support Kerberos version 5 authenticated POP
874 --with-hesiod support Hesiod to get the POP server host
2c9dccc9 875 --without-sound don't compile with sound support
488dd4c4
JD
876 --with-x-toolkit=KIT use an X toolkit
877 (KIT = yes/lucid/athena/motif/gtk/no)
503d2be0
AS
878 --with-xpm use -lXpm for displaying XPM images
879 --with-jpeg use -ljpeg for displaying JPEG images
880 --with-tiff use -ltiff for displaying TIFF images
881 --with-gif use -lungif for displaying GIF images
882 --with-png use -lpng for displaying PNG images
488dd4c4
JD
883 --with-gtk use GTK (same as --with-x-toolkit=gtk)
884 --with-pkg-config-prog Path to pkg-config to use for finding GTK
503d2be0 885 --without-toolkit-scroll-bars
cc227489
MB
886 don't use Motif or Xaw3d scroll bars
887 --without-xim don't use X11 XIM
e0f712ba 888 --without-carbon don't use Carbon GUI on Mac OS X
503d2be0
AS
889 --with-x use the X Window System
890
891Some influential environment variables:
892 CC C compiler command
893 CFLAGS C compiler flags
894 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
895 nonstandard directory <lib dir>
896 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
897 headers in a nonstandard directory <include dir>
898 CPP C preprocessor
899
900Use these variables to override the choices made by `configure' or to help
901it to find libraries and programs with nonstandard names/locations.
902
c0d27fcc 903_ACEOF
503d2be0
AS
904fi
905
906if test "$ac_init_help" = "recursive"; then
907 # If there are subdirs, report their specific --help.
908 ac_popdir=`pwd`
c0d27fcc
MR
909 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
910 test -d $ac_dir || continue
911 ac_builddir=.
912
913if test "$ac_dir" != .; then
914 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
915 # A "../" for each directory in $ac_dir_suffix.
916 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
917else
918 ac_dir_suffix= ac_top_builddir=
919fi
503d2be0 920
c0d27fcc
MR
921case $srcdir in
922 .) # No --srcdir option. We are building in place.
923 ac_srcdir=.
924 if test -z "$ac_top_builddir"; then
925 ac_top_srcdir=.
926 else
927 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
928 fi ;;
929 [\\/]* | ?:[\\/]* ) # Absolute path.
930 ac_srcdir=$srcdir$ac_dir_suffix;
931 ac_top_srcdir=$srcdir ;;
932 *) # Relative path.
933 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
934 ac_top_srcdir=$ac_top_builddir$srcdir ;;
935esac
edfaf76d
LK
936
937# Do not use `cd foo && pwd` to compute absolute paths, because
938# the directories may not exist.
939case `pwd` in
940.) ac_abs_builddir="$ac_dir";;
941*)
942 case "$ac_dir" in
943 .) ac_abs_builddir=`pwd`;;
944 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
945 *) ac_abs_builddir=`pwd`/"$ac_dir";;
946 esac;;
947esac
948case $ac_abs_builddir in
949.) ac_abs_top_builddir=${ac_top_builddir}.;;
950*)
951 case ${ac_top_builddir}. in
952 .) ac_abs_top_builddir=$ac_abs_builddir;;
953 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
954 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
955 esac;;
956esac
957case $ac_abs_builddir in
958.) ac_abs_srcdir=$ac_srcdir;;
959*)
960 case $ac_srcdir in
961 .) ac_abs_srcdir=$ac_abs_builddir;;
962 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
963 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
964 esac;;
965esac
966case $ac_abs_builddir in
967.) ac_abs_top_srcdir=$ac_top_srcdir;;
968*)
969 case $ac_top_srcdir in
970 .) ac_abs_top_srcdir=$ac_abs_builddir;;
971 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
972 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
973 esac;;
974esac
c0d27fcc
MR
975
976 cd $ac_dir
503d2be0 977 # Check for guested configure; otherwise get Cygnus style configure.
c0d27fcc 978 if test -f $ac_srcdir/configure.gnu; then
503d2be0 979 echo
c0d27fcc
MR
980 $SHELL $ac_srcdir/configure.gnu --help=recursive
981 elif test -f $ac_srcdir/configure; then
503d2be0 982 echo
c0d27fcc
MR
983 $SHELL $ac_srcdir/configure --help=recursive
984 elif test -f $ac_srcdir/configure.ac ||
edfaf76d 985 test -f $ac_srcdir/configure.in; then
503d2be0
AS
986 echo
987 $ac_configure --help
988 else
c0d27fcc 989 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
503d2be0 990 fi
10a3b1a1 991 cd $ac_popdir
503d2be0
AS
992 done
993fi
994
995test -n "$ac_init_help" && exit 0
996if $ac_init_version; then
c0d27fcc 997 cat <<\_ACEOF
503d2be0 998
edfaf76d 999Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
1000This configure script is free software; the Free Software Foundation
1001gives unlimited permission to copy, distribute and modify it.
c0d27fcc 1002_ACEOF
503d2be0
AS
1003 exit 0
1004fi
1005exec 5>config.log
c0d27fcc 1006cat >&5 <<_ACEOF
503d2be0
AS
1007This file contains any messages produced by compilers while
1008running configure, to aid debugging if configure makes a mistake.
1009
1010It was created by $as_me, which was
edfaf76d 1011generated by GNU Autoconf 2.59. Invocation command line was
503d2be0
AS
1012
1013 $ $0 $@
1014
c0d27fcc 1015_ACEOF
503d2be0
AS
1016{
1017cat <<_ASUNAME
c0d27fcc
MR
1018## --------- ##
1019## Platform. ##
1020## --------- ##
503d2be0
AS
1021
1022hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1023uname -m = `(uname -m) 2>/dev/null || echo unknown`
1024uname -r = `(uname -r) 2>/dev/null || echo unknown`
1025uname -s = `(uname -s) 2>/dev/null || echo unknown`
1026uname -v = `(uname -v) 2>/dev/null || echo unknown`
1027
1028/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1029/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1030
1031/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1032/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1033/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1034hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1035/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1036/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1037/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1038
925c2f3f 1039_ASUNAME
c0d27fcc
MR
1040
1041as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1042for as_dir in $PATH
1043do
1044 IFS=$as_save_IFS
1045 test -z "$as_dir" && as_dir=.
1046 echo "PATH: $as_dir"
1047done
1048
503d2be0
AS
1049} >&5
1050
c0d27fcc
MR
1051cat >&5 <<_ACEOF
1052
1053
1054## ----------- ##
1055## Core tests. ##
1056## ----------- ##
1057
1058_ACEOF
503d2be0 1059
503d2be0
AS
1060
1061# Keep a trace of the command line.
1062# Strip out --no-create and --no-recursion so they do not pile up.
19650fd6 1063# Strip out --silent because we don't want to record it for future runs.
503d2be0 1064# Also quote any args containing shell meta-characters.
19650fd6 1065# Make two passes to allow for proper duplicate-argument suppression.
503d2be0 1066ac_configure_args=
19650fd6
AS
1067ac_configure_args0=
1068ac_configure_args1=
503d2be0 1069ac_sep=
19650fd6
AS
1070ac_must_keep_next=false
1071for ac_pass in 1 2
503d2be0 1072do
19650fd6
AS
1073 for ac_arg
1074 do
1075 case $ac_arg in
1076 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1077 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1078 | -silent | --silent | --silen | --sile | --sil)
1079 continue ;;
1080 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1081 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1082 esac
1083 case $ac_pass in
1084 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1085 2)
1086 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1087 if test $ac_must_keep_next = true; then
edfaf76d 1088 ac_must_keep_next=false # Got value, back to normal.
19650fd6 1089 else
edfaf76d
LK
1090 case $ac_arg in
1091 *=* | --config-cache | -C | -disable-* | --disable-* \
1092 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1093 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1094 | -with-* | --with-* | -without-* | --without-* | --x)
1095 case "$ac_configure_args0 " in
1096 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1097 esac
1098 ;;
1099 -* ) ac_must_keep_next=true ;;
1100 esac
19650fd6
AS
1101 fi
1102 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1103 # Get rid of the leading space.
1104 ac_sep=" "
1105 ;;
1106 esac
1107 done
503d2be0 1108done
19650fd6
AS
1109$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1110$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
503d2be0
AS
1111
1112# When interrupted or exit'd, cleanup temporary files, and complete
1113# config.log. We remove comments because anyway the quotes in there
1114# would cause problems or look ugly.
c0d27fcc
MR
1115# WARNING: Be sure not to use single quotes in there, as some shells,
1116# such as our DU 5.0 friend, will then `close' the trap.
503d2be0
AS
1117trap 'exit_status=$?
1118 # Save into config.log some information that might help in debugging.
c0d27fcc
MR
1119 {
1120 echo
6bae0ccf 1121
c0d27fcc
MR
1122 cat <<\_ASBOX
1123## ---------------- ##
1124## Cache variables. ##
1125## ---------------- ##
1126_ASBOX
1127 echo
1128 # The following way of writing the cache mishandles newlines in values,
503d2be0
AS
1129{
1130 (set) 2>&1 |
1131 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1132 *ac_space=\ *)
1133 sed -n \
edfaf76d
LK
1134 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1135 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
503d2be0
AS
1136 ;;
1137 *)
1138 sed -n \
edfaf76d 1139 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
1140 ;;
1141 esac;
c0d27fcc
MR
1142}
1143 echo
6bae0ccf
DL
1144
1145 cat <<\_ASBOX
1146## ----------------- ##
1147## Output variables. ##
1148## ----------------- ##
1149_ASBOX
1150 echo
1151 for ac_var in $ac_subst_vars
1152 do
1153 eval ac_val=$`echo $ac_var`
1154 echo "$ac_var='"'"'$ac_val'"'"'"
1155 done | sort
1156 echo
1157
1158 if test -n "$ac_subst_files"; then
1159 cat <<\_ASBOX
1160## ------------- ##
1161## Output files. ##
1162## ------------- ##
1163_ASBOX
1164 echo
1165 for ac_var in $ac_subst_files
1166 do
1167 eval ac_val=$`echo $ac_var`
edfaf76d 1168 echo "$ac_var='"'"'$ac_val'"'"'"
6bae0ccf
DL
1169 done | sort
1170 echo
1171 fi
1172
c0d27fcc
MR
1173 if test -s confdefs.h; then
1174 cat <<\_ASBOX
1175## ----------- ##
1176## confdefs.h. ##
1177## ----------- ##
1178_ASBOX
1179 echo
6bae0ccf 1180 sed "/^$/d" confdefs.h | sort
c0d27fcc
MR
1181 echo
1182 fi
1183 test "$ac_signal" != 0 &&
1184 echo "$as_me: caught signal $ac_signal"
1185 echo "$as_me: exit $exit_status"
1186 } >&5
edfaf76d 1187 rm -f core *.core &&
c0d27fcc 1188 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
503d2be0
AS
1189 exit $exit_status
1190 ' 0
1191for ac_signal in 1 2 13 15; do
1192 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1193done
1194ac_signal=0
1195
1196# confdefs.h avoids OS command line length limits that DEFS can exceed.
1197rm -rf conftest* confdefs.h
1198# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1199echo >confdefs.h
ba4481b5 1200
c0d27fcc
MR
1201# Predefined preprocessor variables.
1202
1203cat >>confdefs.h <<_ACEOF
1204#define PACKAGE_NAME "$PACKAGE_NAME"
1205_ACEOF
1206
1207
1208cat >>confdefs.h <<_ACEOF
1209#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1210_ACEOF
1211
1212
1213cat >>confdefs.h <<_ACEOF
1214#define PACKAGE_VERSION "$PACKAGE_VERSION"
1215_ACEOF
1216
1217
1218cat >>confdefs.h <<_ACEOF
1219#define PACKAGE_STRING "$PACKAGE_STRING"
1220_ACEOF
1221
1222
1223cat >>confdefs.h <<_ACEOF
1224#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1225_ACEOF
1226
1227
503d2be0 1228# Let the site file select an alternate cache file if it wants to.
ba4481b5
DL
1229# Prefer explicitly selected file to automatically selected ones.
1230if test -z "$CONFIG_SITE"; then
1231 if test "x$prefix" != xNONE; then
1232 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1233 else
1234 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1235 fi
1236fi
1237for ac_site_file in $CONFIG_SITE; do
1238 if test -r "$ac_site_file"; then
c0d27fcc 1239 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
503d2be0 1240echo "$as_me: loading site script $ac_site_file" >&6;}
c0d27fcc 1241 sed 's/^/| /' "$ac_site_file" >&5
ba4481b5
DL
1242 . "$ac_site_file"
1243 fi
1244done
1245
1246if test -r "$cache_file"; then
503d2be0
AS
1247 # Some versions of bash will fail to source /dev/null (special
1248 # files actually), so we avoid doing that.
1249 if test -f "$cache_file"; then
c0d27fcc 1250 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
503d2be0
AS
1251echo "$as_me: loading cache $cache_file" >&6;}
1252 case $cache_file in
1253 [\\/]* | ?:[\\/]* ) . $cache_file;;
1254 *) . ./$cache_file;;
1255 esac
1256 fi
ba4481b5 1257else
c0d27fcc 1258 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
503d2be0
AS
1259echo "$as_me: creating cache $cache_file" >&6;}
1260 >$cache_file
1261fi
1262
1263# Check that the precious variables saved in the cache have kept the same
1264# value.
1265ac_cache_corrupted=false
1266for ac_var in `(set) 2>&1 |
edfaf76d 1267 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
503d2be0
AS
1268 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1269 eval ac_new_set=\$ac_env_${ac_var}_set
1270 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1271 eval ac_new_val="\$ac_env_${ac_var}_value"
1272 case $ac_old_set,$ac_new_set in
1273 set,)
c0d27fcc 1274 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
503d2be0
AS
1275echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1276 ac_cache_corrupted=: ;;
1277 ,set)
c0d27fcc 1278 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
503d2be0
AS
1279echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1280 ac_cache_corrupted=: ;;
1281 ,);;
1282 *)
1283 if test "x$ac_old_val" != "x$ac_new_val"; then
edfaf76d 1284 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
503d2be0 1285echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
edfaf76d 1286 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
503d2be0 1287echo "$as_me: former value: $ac_old_val" >&2;}
edfaf76d 1288 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
503d2be0 1289echo "$as_me: current value: $ac_new_val" >&2;}
edfaf76d 1290 ac_cache_corrupted=:
503d2be0
AS
1291 fi;;
1292 esac
c0d27fcc 1293 # Pass precious variables to config.status.
503d2be0
AS
1294 if test "$ac_new_set" = set; then
1295 case $ac_new_val in
1296 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
c0d27fcc
MR
1297 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1298 *) ac_arg=$ac_var=$ac_new_val ;;
1299 esac
1300 case " $ac_configure_args " in
1301 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1302 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
503d2be0
AS
1303 esac
1304 fi
1305done
1306if $ac_cache_corrupted; then
c0d27fcc 1307 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
503d2be0 1308echo "$as_me: error: changes in the environment can compromise the build" >&2;}
c0d27fcc 1309 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
503d2be0
AS
1310echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1311 { (exit 1); exit 1; }; }
ba4481b5
DL
1312fi
1313
1314ac_ext=c
ba4481b5 1315ac_cpp='$CPP $CPPFLAGS'
503d2be0
AS
1316ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1317ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1318ac_compiler_gnu=$ac_cv_c_compiler_gnu
1319
c0d27fcc
MR
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
ba4481b5 1336
6bae0ccf
DL
1337
1338 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
ba4481b5 1339
c0d27fcc 1340
ba5da88a
PJ
1341test "$program_prefix" != NONE &&
1342 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1343# Use a double $ so make ignores it.
1344test "$program_suffix" != NONE &&
1345 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1346# Double any \ or $. echo might interpret backslashes.
1347# By default was `s,x,x', remove it if useless.
1348cat <<\_ACEOF >conftest.sed
1349s/[\\$]/&&/g;s/;s,x,x,$//
1350_ACEOF
1351program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1352rm conftest.sed
1353
c0d27fcc 1354
ba4481b5
DL
1355lispdir='${datadir}/emacs/${version}/lisp'
1356locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1357'${datadir}/emacs/site-lisp:${datadir}/emacs/${version}/leim'
1358lisppath='${locallisppath}:${lispdir}'
1359etcdir='${datadir}/emacs/${version}/etc'
1360archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1361docdir='${datadir}/emacs/${version}/etc'
24b01ec4 1362gamedir='${localstatedir}/games/emacs'
98418dba
CW
1363
1364gameuser=games
1365
c0d27fcc 1366
ba4481b5
DL
1367# Check whether --with-gcc or --without-gcc was given.
1368if test "${with_gcc+set}" = set; then
1369 withval="$with_gcc"
503d2be0
AS
1370
1371fi;
ba4481b5
DL
1372
1373# Check whether --with-pop or --without-pop was given.
1374if test "${with_pop+set}" = set; then
1375 withval="$with_pop"
243cf185 1376 if test "$withval" = yes; then
c0d27fcc 1377 cat >>confdefs.h <<\_ACEOF
ba4481b5 1378#define MAIL_USE_POP 1
c0d27fcc 1379_ACEOF
ba4481b5 1380
243cf185
DL
1381else :
1382fi
3d9fec71 1383else
c0d27fcc 1384 cat >>confdefs.h <<\_ACEOF
3d9fec71 1385#define MAIL_USE_POP 1
c0d27fcc 1386_ACEOF
3d9fec71 1387
503d2be0 1388fi;
ba4481b5 1389
c0d27fcc 1390
a21616bd
KR
1391# Check whether --with-kerberos or --without-kerberos was given.
1392if test "${with_kerberos+set}" = set; then
1393 withval="$with_kerberos"
c0d27fcc 1394 cat >>confdefs.h <<\_ACEOF
a21616bd 1395#define KERBEROS 1
c0d27fcc 1396_ACEOF
a21616bd 1397
503d2be0 1398fi;
a21616bd 1399
c0d27fcc 1400
a21616bd
KR
1401# Check whether --with-kerberos5 or --without-kerberos5 was given.
1402if test "${with_kerberos5+set}" = set; then
1403 withval="$with_kerberos5"
1404 if test "${with_kerberos5+set}" = set; then
1405 if test "${with_kerberos+set}" != set; then
1406 with_kerberos=yes
c0d27fcc 1407 cat >>confdefs.h <<\_ACEOF
a21616bd 1408#define KERBEROS 1
c0d27fcc 1409_ACEOF
a21616bd
KR
1410
1411 fi
1412fi
b936fae4 1413
c0d27fcc 1414cat >>confdefs.h <<\_ACEOF
a21616bd 1415#define KERBEROS5 1
c0d27fcc 1416_ACEOF
a21616bd 1417
503d2be0 1418fi;
a21616bd 1419
ba4481b5
DL
1420# Check whether --with-hesiod or --without-hesiod was given.
1421if test "${with_hesiod+set}" = set; then
1422 withval="$with_hesiod"
b936fae4 1423
c0d27fcc 1424cat >>confdefs.h <<\_ACEOF
ba4481b5 1425#define HESIOD 1
c0d27fcc 1426_ACEOF
ba4481b5 1427
503d2be0 1428fi;
ba4481b5 1429
c0d27fcc 1430
2c9dccc9
PJ
1431# Check whether --with-sound or --without-sound was given.
1432if test "${with_sound+set}" = set; then
1433 withval="$with_sound"
1434
1435fi;
1436
c0d27fcc 1437
ba4481b5
DL
1438# Check whether --with-x-toolkit or --without-x-toolkit was given.
1439if test "${with_x_toolkit+set}" = set; then
1440 withval="$with_x_toolkit"
1441 case "${withval}" in
1442 y | ye | yes ) val=athena ;;
1443 n | no ) val=no ;;
1444 l | lu | luc | luci | lucid ) val=lucid ;;
1445 a | at | ath | athe | athen | athena ) val=athena ;;
1446 m | mo | mot | moti | motif ) val=motif ;;
488dd4c4 1447 g | gt | gtk ) val=gtk ;;
ba4481b5 1448 * )
c0d27fcc 1449{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1450this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1451Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1452echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1453this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1454Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1455 { (exit 1); exit 1; }; }
ba4481b5
DL
1456 ;;
1457 esac
1458 with_x_toolkit=$val
1459
503d2be0 1460fi;
ba4481b5
DL
1461
1462# Check whether --with-xpm or --without-xpm was given.
1463if test "${with_xpm+set}" = set; then
1464 withval="$with_xpm"
503d2be0
AS
1465
1466fi;
ba4481b5
DL
1467
1468# Check whether --with-jpeg or --without-jpeg was given.
1469if test "${with_jpeg+set}" = set; then
1470 withval="$with_jpeg"
503d2be0
AS
1471
1472fi;
ba4481b5
DL
1473
1474# Check whether --with-tiff or --without-tiff was given.
1475if test "${with_tiff+set}" = set; then
1476 withval="$with_tiff"
503d2be0
AS
1477
1478fi;
ba4481b5
DL
1479
1480# Check whether --with-gif or --without-gif was given.
1481if test "${with_gif+set}" = set; then
1482 withval="$with_gif"
503d2be0
AS
1483
1484fi;
ba4481b5
DL
1485
1486# Check whether --with-png or --without-png was given.
1487if test "${with_png+set}" = set; then
1488 withval="$with_png"
503d2be0
AS
1489
1490fi;
ba4481b5 1491
488dd4c4
JD
1492# Check whether --with-gtk or --without-gtk was given.
1493if test "${with_gtk+set}" = set; then
1494 withval="$with_gtk"
1495
1496fi;
1497
1498# Check whether --with-pkg-config-prog or --without-pkg-config-prog was given.
1499if test "${with_pkg_config_prog+set}" = set; then
1500 withval="$with_pkg_config_prog"
1501
1502fi;
1503
ba4481b5
DL
1504# Check whether --with-toolkit-scroll-bars or --without-toolkit-scroll-bars was given.
1505if test "${with_toolkit_scroll_bars+set}" = set; then
1506 withval="$with_toolkit_scroll_bars"
503d2be0
AS
1507
1508fi;
ba4481b5 1509
1d36487c
GM
1510# Check whether --with-xim or --without-xim was given.
1511if test "${with_xim+set}" = set; then
1512 withval="$with_xim"
1d36487c 1513
503d2be0 1514fi;
ba4481b5 1515
e0f712ba
AC
1516# Check whether --with-carbon or --without-carbon was given.
1517if test "${with_carbon+set}" = set; then
1518 withval="$with_carbon"
1519
1520fi;
6a3a24fa
JD
1521# Check whether --enable-carbon-app or --disable-carbon-app was given.
1522if test "${enable_carbon_app+set}" = set; then
1523 enableval="$enable_carbon_app"
1524 carbon_appdir_x=${enableval}
1525fi;
e0f712ba 1526
d0098f13
JD
1527# Check whether --enable-asserts or --disable-asserts was given.
1528if test "${enable_asserts+set}" = set; then
1529 enableval="$enable_asserts"
1530 USE_XASSERTS=$enableval
1531else
1532 USE_XASSERTS=no
1533fi;
1534
19650fd6
AS
1535# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1536if test "${enable_maintainer_mode+set}" = set; then
1537 enableval="$enable_maintainer_mode"
1538 USE_MAINTAINER_MODE=$enableval
1539else
1540 USE_MAINTAINER_MODE=no
1541fi;
1542if test $USE_MAINTAINER_MODE = yes; then
1543 MAINT=
1544else
1545 MAINT=#
1546fi
1547
1548
9adfabc2
LK
1549# Check whether --enable-locallisppath or --disable-locallisppath was given.
1550if test "${enable_locallisppath+set}" = set; then
1551 enableval="$enable_locallisppath"
1552 if test "${enableval}" = "no"; then
1553 locallisppath=
1554elif test "${enableval}" != "yes"; then
1555 locallisppath=${enableval}
1556fi
1557fi;
1558
ba4481b5 1559#### Make srcdir absolute, if it isn't already. It's important to
17494071 1560#### avoid running the path through pwd unnecessarily, since pwd can
ba4481b5
DL
1561#### give you automounter prefixes, which can go away. We do all this
1562#### so Emacs can find its files when run uninstalled.
17494071
GM
1563## Make sure CDPATH doesn't affect cd (in case PWD is relative).
1564unset CDPATH
ba4481b5
DL
1565case "${srcdir}" in
1566 /* ) ;;
1567 . )
1568 ## We may be able to use the $PWD environment variable to make this
1569 ## absolute. But sometimes PWD is inaccurate.
df645f7c
AS
1570 ## Note: we used to use ${PWD} at the end instead of `pwd`,
1571 ## but that tested only for a well-formed and valid PWD,
1572 ## it did not object when PWD was well-formed and valid but just wrong.
1573 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
ba4481b5
DL
1574 then
1575 srcdir="$PWD"
1576 else
1577 srcdir="`(cd ${srcdir}; pwd)`"
1578 fi
1579 ;;
1580 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
1581esac
1582
1583#### Check if the source directory already has a configured system in it.
1584if test `pwd` != `(cd ${srcdir} && pwd)` \
1585 && test -f "${srcdir}/src/config.h" ; then
c0d27fcc 1586 { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
503d2be0
AS
1587 as a build directory right now; it has been configured in its own
1588 right. To configure in another directory as well, you MUST
1589 use GNU make. If you do not have GNU make, then you must
1590 now do \`make distclean' in ${srcdir},
1591 and then run $0 again." >&5
1592echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
ba4481b5
DL
1593 as a build directory right now; it has been configured in its own
1594 right. To configure in another directory as well, you MUST
1595 use GNU make. If you do not have GNU make, then you must
1596 now do \`make distclean' in ${srcdir},
503d2be0 1597 and then run $0 again." >&2;}
ba4481b5
DL
1598fi
1599
1600#### Given the configuration name, set machfile and opsysfile to the
1601#### names of the m/*.h and s/*.h files we should use.
1602
1603### Canonicalize the configuration name.
1604
1605ac_aux_dir=
1606for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1607 if test -f $ac_dir/install-sh; then
1608 ac_aux_dir=$ac_dir
1609 ac_install_sh="$ac_aux_dir/install-sh -c"
1610 break
1611 elif test -f $ac_dir/install.sh; then
1612 ac_aux_dir=$ac_dir
1613 ac_install_sh="$ac_aux_dir/install.sh -c"
1614 break
503d2be0
AS
1615 elif test -f $ac_dir/shtool; then
1616 ac_aux_dir=$ac_dir
1617 ac_install_sh="$ac_aux_dir/shtool install -c"
1618 break
ba4481b5
DL
1619 fi
1620done
1621if test -z "$ac_aux_dir"; then
c0d27fcc 1622 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1623echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1624 { (exit 1); exit 1; }; }
ba4481b5 1625fi
503d2be0
AS
1626ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1627ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1628ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1629
1630# Make sure we can run config.sub.
503d2be0 1631$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1632 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1633echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1634 { (exit 1); exit 1; }; }
1635
c0d27fcc 1636echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1637echo $ECHO_N "checking build system type... $ECHO_C" >&6
1638if test "${ac_cv_build+set}" = set; then
1639 echo $ECHO_N "(cached) $ECHO_C" >&6
1640else
1641 ac_cv_build_alias=$build_alias
1642test -z "$ac_cv_build_alias" &&
1643 ac_cv_build_alias=`$ac_config_guess`
1644test -z "$ac_cv_build_alias" &&
c0d27fcc 1645 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1646echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1647 { (exit 1); exit 1; }; }
1648ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1649 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1650echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1651 { (exit 1); exit 1; }; }
1652
1653fi
c0d27fcc 1654echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1655echo "${ECHO_T}$ac_cv_build" >&6
1656build=$ac_cv_build
1657build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1658build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1659build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1660
c0d27fcc
MR
1661
1662echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1663echo $ECHO_N "checking host system type... $ECHO_C" >&6
1664if test "${ac_cv_host+set}" = set; then
1665 echo $ECHO_N "(cached) $ECHO_C" >&6
1666else
1667 ac_cv_host_alias=$host_alias
1668test -z "$ac_cv_host_alias" &&
1669 ac_cv_host_alias=$ac_cv_build_alias
1670ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1671 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1672echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1673 { (exit 1); exit 1; }; }
1674
1675fi
c0d27fcc 1676echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1677echo "${ECHO_T}$ac_cv_host" >&6
1678host=$ac_cv_host
1679host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1680host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1681host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1682
c0d27fcc 1683
ba4481b5 1684canonical=$host
531a3336 1685configuration=${host_alias-$host}
ba4481b5 1686
c0d27fcc 1687
22044edf 1688
ba4481b5
DL
1689### If you add support for a new configuration, add code to this
1690### switch statement to recognize your configuration name and select
1691### the appropriate operating system and machine description files.
1692
1693### You would hope that you could choose an m/*.h file pretty much
1694### based on the machine portion of the configuration name, and an s-
1695### file based on the operating system portion. However, it turns out
1696### that each m/*.h file is pretty manufacturer-specific - for
1697### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1698### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1699### machines. So we basically have to have a special case for each
1700### configuration name.
1701###
1702### As far as handling version numbers on operating systems is
1703### concerned, make sure things will fail in a fixable way. If
1704### /etc/MACHINES doesn't say anything about version numbers, be
1705### prepared to handle anything reasonably. If version numbers
1706### matter, be sure /etc/MACHINES says something about it.
1707###
1708### Eric Raymond says we should accept strings like "sysvr4" to mean
1709### "System V Release 4"; he writes, "The old convention encouraged
1710### confusion between `system' and `release' levels'."
1711
1712machine='' opsys='' unported=no
1713case "${canonical}" in
1714
1096bcc0
GM
1715 ## FreeBSD ports
1716 *-*-freebsd* )
1717 opsys=freebsd
1718 case "${canonical}" in
1719 alpha*-*-freebsd*) machine=alpha ;;
1720 i[3456]86-*-freebsd*) machine=intel386 ;;
1721 esac
1722 ;;
1723
ba4481b5
DL
1724 ## NetBSD ports
1725 *-*-netbsd* )
1726 opsys=netbsd
dd038e26 1727 if test -f /usr/lib/crti.o; then
f57bd967
DL
1728
1729cat >>confdefs.h <<\_ACEOF
1730#define HAVE_CRTIN
dd038e26
AS
1731_ACEOF
1732
1733 fi
1734
ba4481b5
DL
1735 case "${canonical}" in
1736 alpha*-*-netbsd*) machine=alpha ;;
1737 i[3456]86-*-netbsd*) machine=intel386 ;;
1738 m68k-*-netbsd*)
1739 # This is somewhat bogus.
1740 machine=hp9000s300 ;;
1741 powerpc-apple-netbsd*) machine=macppc ;;
1742 mips-*-netbsd*) machine=pmax ;;
2df636f4 1743 mipsel-*-netbsd*) machine=pmax ;;
97836269 1744 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1745 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1746 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1747 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1748 vax-*-netbsd*) machine=vax ;;
2df636f4 1749 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1750 esac
1751 ;;
1752
1753 ## OpenBSD ports
1754 *-*-openbsd* )
1755 opsys=openbsd
1756 case "${canonical}" in
1757 alpha*-*-openbsd*) machine=alpha ;;
1758 i386-*-openbsd*) machine=intel386 ;;
1759 m68k-*-openbsd*) machine=hp9000s300 ;;
1760 mipsel-*-openbsd*) machine=pmax ;;
1761 ns32k-*-openbsd*) machine=ns32000 ;;
1762 sparc-*-openbsd*) machine=sparc ;;
1763 vax-*-openbsd*) machine=vax ;;
1764 esac
1765 ;;
1766
10a3b1a1
EZ
1767 ## LynxOS ports
1768 *-*-lynxos* )
1769 opsys=lynxos
1770 case "${canonical}" in
1771 i[3456]86-*-lynxos*) machine=intel386 ;;
1772 powerpc-*-lynxos*) machine=powerpc ;;
1773 esac
1774 ;;
1775
ba4481b5
DL
1776 ## Acorn RISCiX:
1777 arm-acorn-riscix1.1* )
1778 machine=acorn opsys=riscix1-1
1779 ;;
1780 arm-acorn-riscix1.2* | arm-acorn-riscix )
1781 ## This name is riscix12 instead of riscix1.2
1782 ## to avoid a file name conflict on MSDOS.
1783 machine=acorn opsys=riscix12
1784 ;;
1785
1786 ## BSDI ports
1787 *-*-bsdi* )
1788 opsys=bsdi
1789 case "${canonical}" in
1790 i[345]86-*-bsdi*) machine=intel386 ;;
1791 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1792 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1793 esac
1794 case "${canonical}" in
1795 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1796 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1797 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1798 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1799 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1800 esac
1801 ;;
1802
1803 ## Alliant machines
1804 ## Strictly speaking, we need the version of the alliant operating
1805 ## system to choose the right machine file, but currently the
1806 ## configuration name doesn't tell us enough to choose the right
1807 ## one; we need to give alliants their own operating system name to
1808 ## do this right. When someone cares, they can help us.
1809 fx80-alliant-* )
1810 machine=alliant4 opsys=bsd4-2
1811 ;;
1812 i860-alliant-* )
1813 machine=alliant-2800 opsys=bsd4-3
1814 ;;
1815
1816 ## Alpha (DEC) machines.
1817 alpha*-dec-osf* )
1818 machine=alpha opsys=osf1
1819 # This is needed to find X11R6.1 libraries for certain tests.
1820 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1821 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1822 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1823 # due to non-traditional preprocessing with the current compiler
1824 # defaults. OSF 4 can also have that compiler version, and there
1825 # seems always to have been a usable /usr/bin/cpp.
1826 NON_GNU_CPP=/usr/bin/cpp
ca512671 1827 case "${canonical}" in
a55b799a 1828 alpha*-dec-osf[5-9]*)
bb17930d 1829 opsys=osf5-0 ;;
ca512671 1830 esac
ba4481b5
DL
1831 ;;
1832
1833 alpha*-*-linux-gnu* )
1834 machine=alpha opsys=gnu-linux
1835 ;;
1836
c4bb2108
DL
1837 arm*-*-linux-gnu* )
1838 machine=arm opsys=gnu-linux
1839 ;;
1840
ba4481b5
DL
1841 ## Altos 3068
1842 m68*-altos-sysv* )
1843 machine=altos opsys=usg5-2
1844 ;;
1845
1846 ## Amdahl UTS
1847 580-amdahl-sysv* )
1848 machine=amdahl opsys=usg5-2-2
1849 ;;
1850
1851 ## Apollo, Domain/OS
1852 m68*-apollo-* )
1853 machine=apollo opsys=bsd4-3
1854 ;;
1855
1856 ## AT&T 3b2, 3b5, 3b15, 3b20
1857 we32k-att-sysv* )
1858 machine=att3b opsys=usg5-2-2
1859 ;;
1860
1861 ## AT&T 3b1 - The Mighty Unix PC!
1862 m68*-att-sysv* )
1863 machine=7300 opsys=usg5-2-2
1864 ;;
1865
1866 ## Bull dpx20
1867 rs6000-bull-bosx* )
1868 machine=ibmrs6000 opsys=aix3-2
1869 ;;
1870
1871 ## Bull dpx2
1872 m68*-bull-sysv3* )
1873 machine=dpx2 opsys=usg5-3
1874 ;;
1875
1876 ## Bull sps7
1877 m68*-bull-sysv2* )
1878 machine=sps7 opsys=usg5-2
1879 ;;
1880
1881 ## CCI 5/32, 6/32 -- see "Tahoe".
1882
1883 ## Celerity
1884 ## I don't know what configuration name to use for this; config.sub
1885 ## doesn't seem to know anything about it. Hey, Celerity users, get
1886 ## in touch with us!
1887 celerity-celerity-bsd* )
1888 machine=celerity opsys=bsd4-2
1889 ;;
1890
1891 ## Clipper
1892 ## What operating systems does this chip run that Emacs has been
1893 ## tested on?
1894 clipper-* )
1895 machine=clipper
1896 ## We'll use the catch-all code at the bottom to guess the
1897 ## operating system.
1898 ;;
1899
df645f7c
AS
1900 ## Compaq Nonstop
1901 mips-compaq-nonstopux* )
1902 machine=nonstopux opsys=nonstopux
1903 ;;
1904
ba4481b5
DL
1905 ## Convex
1906 *-convex-bsd* | *-convex-convexos* )
1907 machine=convex opsys=bsd4-3
1908 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1909 NON_GNU_CPP="cc -E -P"
1910 ;;
1911
1912 ## Cubix QBx/386
1913 i[3456]86-cubix-sysv* )
1914 machine=intel386 opsys=usg5-3
1915 ;;
1916
1917 ## Cydra 5
1918 cydra*-cydrome-sysv* )
1919 machine=cydra5 opsys=usg5-3
1920 ;;
1921
1922 ## Data General AViiON Machines
1923 ## DG changed naming conventions with the release of 5.4.4.10, they
1924 ## dropped the initial 5.4 but left the intervening R. Because of the
1925 ## R this shouldn't conflict with older versions of the OS (which I
1926 ## think were named like dgux4.*). In addition, DG new AViiONs series
1927 ## uses either Motorola M88k or Intel Pentium CPUs.
1928 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1929 machine=aviion opsys=dgux4
1930 ;;
1931 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1932 ## This name is dgux5-4-3 instead of dgux5-4r3
1933 ## to avoid a file name conflict on MSDOS.
1934 machine=aviion opsys=dgux5-4-3
1935 ;;
1936 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1937 machine=aviion opsys=dgux5-4r2
1938 ;;
1939 m88k-dg-dgux* )
1940 machine=aviion opsys=dgux
1941 ;;
1942
1943 ## Data General AViiON Intel (x86) Machines
1944 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1945 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1946 i[345]86-dg-dguxR4* )
1947 machine=aviion-intel opsys=dgux4
1948 ;;
1949
1950 ## DECstations
1951 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1952 machine=pmax opsys=bsd4-2
1953 ;;
1954 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1955 machine=pmax opsys=bsd4-3
1956 ;;
1957 mips-dec-ultrix* )
1958 machine=pmax opsys=ultrix4-3
1959 ;;
1960 mips-dec-osf* )
1961 machine=pmax opsys=osf1
1962 ;;
1963 mips-dec-mach_bsd4.3* )
1964 machine=pmax opsys=mach-bsd4-3
1965 ;;
1966
cd890796
JD
1967 ## Motorola Delta machines
1968 m68k-motorola-sysv* | m68000-motorola-sysv* )
1969 machine=delta opsys=usg5-3
1970 if test -z "`type gnucc | grep 'not found'`"
1971 then
1972 if test -s /etc/167config
1973 then CC="gnucc -m68040"
1974 else CC="gnucc -m68881"
1975 fi
1976 else
1977 if test -z "`type gcc | grep 'not found'`"
1978 then CC=gcc
1979 else CC=cc
1980 fi
1981 fi
1982 ;;
ba4481b5
DL
1983 m88k-motorola-sysv4* )
1984 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1985 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1986 # I hope there are not other 4.0 versions for this machine
1987 # which really need usg5-4 instead.
1988 machine=delta88k opsys=usg5-4-2
1989 ;;
1990 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1991 machine=delta88k opsys=usg5-3
1992 ;;
1993
1994 ## Dual machines
1995 m68*-dual-sysv* )
1996 machine=dual opsys=usg5-2
1997 ;;
1998 m68*-dual-uniplus* )
1999 machine=dual opsys=unipl5-2
2000 ;;
2001
2002 ## Elxsi 6400
2003 elxsi-elxsi-sysv* )
2004 machine=elxsi opsys=usg5-2
2005 ;;
2006
2007 ## Encore machines
2008 ns16k-encore-bsd* )
2009 machine=ns16000 opsys=umax
2010 ;;
2011
65171e3a
DL
2012 ## The GEC 63 - apparently, this port isn't really finished yet.
2013 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
2014
2015 ## Gould Power Node and NP1
2016 pn-gould-bsd4.2* )
2017 machine=gould opsys=bsd4-2
2018 ;;
2019 pn-gould-bsd4.3* )
2020 machine=gould opsys=bsd4-3
2021 ;;
2022 np1-gould-bsd* )
2023 machine=gould-np1 opsys=bsd4-3
2024 ;;
2025
2026 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
2027 ## as far as Emacs is concerned).
2028 m88k-harris-cxux* )
2029 # Build needs to be different on 7.0 and later releases
2030 case "`uname -r`" in
2031 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
2032 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
2033 esac
2034 NON_GNU_CPP="/lib/cpp"
2035 ;;
2036 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
2037 m68k-harris-cxux* )
2038 machine=nh3000 opsys=cxux
2039 ;;
2040 ## Harris power pc NightHawk running Power UNIX (Series 6000)
2041 powerpc-harris-powerunix )
2042 machine=nh6000 opsys=powerunix
2043 NON_GNU_CPP="cc -Xo -E -P"
2044 ;;
2045 ## SR2001/SR2201 running HI-UX/MPP
2046 hppa1.1-hitachi-hiuxmpp* )
2047 machine=sr2k opsys=hiuxmpp
2048 ;;
89a336fa
GM
2049 hppa1.1-hitachi-hiuxwe2* )
2050 machine=sr2k opsys=hiuxwe2
2051 ;;
ba4481b5
DL
2052 ## Honeywell XPS100
2053 xps*-honeywell-sysv* )
2054 machine=xps100 opsys=usg5-2
2055 ;;
2056
2057 ## HP 9000 series 200 or 300
2058 m68*-hp-bsd* )
2059 machine=hp9000s300 opsys=bsd4-3
2060 ;;
2061 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2062 m68*-hp-hpux* )
2063 case "`uname -r`" in
2064 ## Someone's system reports A.B8.05 for this.
2065 ## I wonder what other possibilities there are.
2066 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2067 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2068 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2069 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2070 *) machine=hp9000s300 opsys=hpux ;;
2071 esac
2072 ;;
2073
2074 ## HP 9000 series 700 and 800, running HP/UX
2075 hppa*-hp-hpux7* )
2076 machine=hp800 opsys=hpux
2077 ;;
2078 hppa*-hp-hpux8* )
2079 machine=hp800 opsys=hpux8
2080 ;;
2081 hppa*-hp-hpux9shr* )
2082 machine=hp800 opsys=hpux9shr
2083 ;;
2084 hppa*-hp-hpux9* )
2085 machine=hp800 opsys=hpux9
2086 ;;
b0e44248
RB
2087 hppa*-hp-hpux10.2* )
2088 machine=hp800 opsys=hpux10-20
2089 ;;
cc227489 2090 hppa*-hp-hpux10* )
ba4481b5
DL
2091 machine=hp800 opsys=hpux10
2092 ;;
cc227489
MB
2093 hppa*-hp-hpux1[1-9]* )
2094 machine=hp800 opsys=hpux11
2095 ;;
ba4481b5 2096
409d9577
GM
2097 hppa*-*-linux-gnu* )
2098 machine=hp800 opsys=gnu-linux
2099 ;;
2100
ba4481b5
DL
2101 ## HP 9000 series 700 and 800, running HP/UX
2102 hppa*-hp-hpux* )
2103 ## Cross-compilation? Nah!
2104 case "`uname -r`" in
2105 ## Someone's system reports A.B8.05 for this.
2106 ## I wonder what other possibilities there are.
2107 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2108 *.08.* ) machine=hp800 opsys=hpux8 ;;
2109 *.09.* ) machine=hp800 opsys=hpux9 ;;
2110 *) machine=hp800 opsys=hpux10 ;;
2111 esac
2112 ;;
2113 hppa*-*-nextstep* )
2114 machine=hp800 opsys=nextstep
2115 ;;
2116
2117 ## Orion machines
2118 orion-orion-bsd* )
2119 machine=orion opsys=bsd4-2
2120 ;;
2121 clipper-orion-bsd* )
2122 machine=orion105 opsys=bsd4-2
2123 ;;
2124
2125 ## IBM machines
2126 i[3456]86-ibm-aix1.1* )
2127 machine=ibmps2-aix opsys=usg5-2-2
2128 ;;
2129 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2130 machine=ibmps2-aix opsys=usg5-3
2131 ;;
2132 i370-ibm-aix*)
2133 machine=ibm370aix opsys=usg5-3
2134 ;;
55597d70 2135 s390-*-linux-gnu* )
138f0859
GM
2136 machine=ibms390 opsys=gnu-linux
2137 ;;
ba4481b5
DL
2138 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2139 machine=ibmrs6000 opsys=aix3-1
2140 ;;
2141 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2142 machine=ibmrs6000 opsys=aix3-2-5
2143 ;;
2144 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2145 machine=ibmrs6000 opsys=aix4-1
2146 ;;
2147 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2148 machine=ibmrs6000 opsys=aix4-2
2149 ;;
55597d70 2150 rs6000-ibm-aix5* | powerpc-ibm-aix5* )
d6b82250
EZ
2151 machine=ibmrs6000 opsys=aix4-2
2152 ;;
ba4481b5
DL
2153 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2154 machine=ibmrs6000 opsys=aix4
2155 ;;
2156 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2157 machine=ibmrs6000 opsys=aix4-1
2158 ;;
2159 rs6000-ibm-aix* | powerpc-ibm-aix* )
2160 machine=ibmrs6000 opsys=aix3-2
2161 ;;
2162 romp-ibm-bsd4.3* )
2163 machine=ibmrt opsys=bsd4-3
2164 ;;
2165 romp-ibm-bsd4.2* )
2166 machine=ibmrt opsys=bsd4-2
2167 ;;
2168 romp-ibm-aos4.3* )
2169 machine=ibmrt opsys=bsd4-3
2170 ;;
2171 romp-ibm-aos4.2* )
2172 machine=ibmrt opsys=bsd4-2
2173 ;;
2174 romp-ibm-aos* )
2175 machine=ibmrt opsys=bsd4-3
2176 ;;
2177 romp-ibm-bsd* )
2178 machine=ibmrt opsys=bsd4-3
2179 ;;
2180 romp-ibm-aix* )
2181 machine=ibmrt-aix opsys=usg5-2-2
2182 ;;
2183
2184 ## Integrated Solutions `Optimum V'
2185 m68*-isi-bsd4.2* )
2186 machine=isi-ov opsys=bsd4-2
2187 ;;
2188 m68*-isi-bsd4.3* )
2189 machine=isi-ov opsys=bsd4-3
2190 ;;
2191
2192 ## Intel 386 machines where we do care about the manufacturer
2193 i[3456]86-intsys-sysv* )
2194 machine=is386 opsys=usg5-2-2
2195 ;;
2196
2197 ## Prime EXL
2198 i[3456]86-prime-sysv* )
2199 machine=i386 opsys=usg5-3
2200 ;;
2201
2202 ## Sequent Symmetry running Dynix
2203 i[3456]86-sequent-bsd* )
2204 machine=symmetry opsys=bsd4-3
2205 ;;
2206
2207 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2208 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2209 machine=sequent-ptx opsys=ptx4
2210 NON_GNU_CPP=/lib/cpp
2211 ;;
2212
2213 ## Sequent Symmetry running DYNIX/ptx
2214 ## Use the old cpp rather than the newer ANSI one.
2215 i[3456]86-sequent-ptx* )
2216 machine=sequent-ptx opsys=ptx
2217 NON_GNU_CPP="/lib/cpp"
2218 ;;
2219
2220 ## ncr machine running svr4.3.
2221 i[3456]86-ncr-sysv4.3 )
2222 machine=ncr386 opsys=usg5-4-3
2223 ;;
2224
2225 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2226 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2227 i[3456]86-ncr-sysv* )
2228 machine=ncr386 opsys=usg5-4-2
2229 ;;
2230
2231 ## Intel Paragon OSF/1
2232 i860-intel-osf1* )
2233 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2234 ;;
2235
2236 ## Intel 860
2237 i860-*-sysv4* )
2238 machine=i860 opsys=usg5-4
2239 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2240 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2241 ;;
2242
c76e04a8
GM
2243 ## Macintosh PowerPC
2244 powerpc*-*-linux-gnu* )
2245 machine=macppc opsys=gnu-linux
2246 ;;
2247
ba4481b5
DL
2248 ## Masscomp machines
2249 m68*-masscomp-rtu* )
2250 machine=masscomp opsys=rtu
2251 ;;
2252
2253 ## Megatest machines
2254 m68*-megatest-bsd* )
2255 machine=mega68 opsys=bsd4-2
2256 ;;
2257
2258 ## Workstations sold by MIPS
2259 ## This is not necessarily all workstations using the MIPS processor -
2260 ## Irises are produced by SGI, and DECstations by DEC.
2261
2262 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2263 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2264 ## it gives for choosing between the alternatives seems to be "Use
2265 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2266 ## the BSD world." I'll assume that these are instructions for
2267 ## handling two odd situations, and that every other situation
2268 ## should use mips.h and usg5-2-2, they being listed first.
2269 mips-mips-usg* )
2270 machine=mips4
2271 ## Fall through to the general code at the bottom to decide on the OS.
2272 ;;
2273 mips-mips-riscos4* )
2274 machine=mips4 opsys=bsd4-3
2275 NON_GNU_CC="cc -systype bsd43"
2276 NON_GNU_CPP="cc -systype bsd43 -E"
2277 ;;
2278 mips-mips-riscos5* )
2279 machine=mips4 opsys=riscos5
2280 NON_GNU_CC="cc -systype bsd43"
2281 NON_GNU_CPP="cc -systype bsd43 -E"
2282 ;;
2283 mips-mips-bsd* )
2284 machine=mips opsys=bsd4-3
2285 ;;
2286 mips-mips-* )
2287 machine=mips opsys=usg5-2-2
2288 ;;
2289
2290 ## NeXT
2291 m68*-next-* | m68k-*-nextstep* )
2292 machine=m68k opsys=nextstep
2293 ;;
2294
2295 ## The complete machine from National Semiconductor
2296 ns32k-ns-genix* )
2297 machine=ns32000 opsys=usg5-2
2298 ;;
2299
2300 ## NCR machines
2301 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2302 machine=tower32 opsys=usg5-2-2
2303 ;;
2304 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2305 machine=tower32v3 opsys=usg5-3
2306 ;;
2307
2308 ## NEC EWS4800
2309 mips-nec-sysv4*)
2310 machine=ews4800 opsys=ux4800
2311 ;;
2312
2313 ## Nixdorf Targon 31
2314 m68*-nixdorf-sysv* )
2315 machine=targon31 opsys=usg5-2-2
2316 ;;
2317
2318 ## Nu (TI or LMI)
2319 m68*-nu-sysv* )
2320 machine=nu opsys=usg5-2
2321 ;;
2322
2323 ## Plexus
2324 m68*-plexus-sysv* )
2325 machine=plexus opsys=usg5-2
2326 ;;
2327
ba4481b5
DL
2328 ## Pyramid machines
2329 ## I don't really have any idea what sort of processor the Pyramid has,
2330 ## so I'm assuming it is its own architecture.
2331 pyramid-pyramid-bsd* )
2332 machine=pyramid opsys=bsd4-2
2333 ;;
2334
2335 ## Sequent Balance
2336 ns32k-sequent-bsd4.2* )
2337 machine=sequent opsys=bsd4-2
2338 ;;
2339 ns32k-sequent-bsd4.3* )
2340 machine=sequent opsys=bsd4-3
2341 ;;
2342
2343 ## Siemens Nixdorf
2344 mips-siemens-sysv* | mips-sni-sysv*)
2345 machine=mips-siemens opsys=usg5-4
2346 NON_GNU_CC=/usr/ccs/bin/cc
2347 NON_GNU_CPP=/usr/ccs/lib/cpp
2348 ;;
2349
2350 ## Silicon Graphics machines
2351 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2352 m68*-sgi-iris3.5* )
2353 machine=irist opsys=iris3-5
2354 ;;
2355 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2356 machine=irist opsys=iris3-6
2357 ;;
2358 ## Iris 4D
2359 mips-sgi-irix3* )
2360 machine=iris4d opsys=irix3-3
2361 ;;
2362 mips-sgi-irix4* )
2363 machine=iris4d opsys=irix4-0
2364 ;;
2365 mips-sgi-irix6.5 )
2366 machine=iris4d opsys=irix6-5
946173ad
DL
2367 # Without defining _LANGUAGE_C, things get masked out in the headers
2368 # so that, for instance, grepping for `free' in stdlib.h fails and
2369 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2370 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2371 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2372 ;;
2373 mips-sgi-irix6* )
2374 machine=iris4d opsys=irix6-0
c4bb2108 2375 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2376 # but presumably it does no harm.
2377 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2378 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2379 NON_GCC_TEST_OPTIONS=-32
2380 ;;
2381 mips-sgi-irix5.[01]* )
2382 machine=iris4d opsys=irix5-0
2383 ;;
2384 mips-sgi-irix5* | mips-sgi-irix* )
2385 machine=iris4d opsys=irix5-2
2386 ;;
2387
2388 ## SONY machines
2389 m68*-sony-bsd4.2* )
2390 machine=news opsys=bsd4-2
2391 ;;
2392 m68*-sony-bsd4.3* )
2393 machine=news opsys=bsd4-3
2394 ;;
2395 m68*-sony-newsos3* | m68*-sony-news3*)
2396 machine=news opsys=bsd4-3
2397 ;;
2398 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2399 machine=news-risc opsys=bsd4-3
2400 ;;
2401 mips-sony-newsos6* )
2402 machine=news-r6 opsys=newsos6
2403 ;;
2404 mips-sony-news* )
2405 machine=news-risc opsys=newsos5
2406 ;;
2407
2408 ## Stride
2409 m68*-stride-sysv* )
2410 machine=stride opsys=usg5-2
2411 ;;
2412
2413 ## Suns
2414 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2415 machine=sparc opsys=gnu-linux
2416 ;;
2417
d054101f 2418 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2419 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2420 | rs6000-*-solaris2*)
2421 case "${canonical}" in
2422 m68*-sunos1* ) machine=sun1 ;;
2423 m68*-sunos2* ) machine=sun2 ;;
2424 m68* ) machine=sun3 ;;
2425 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2426 i[3456]86-*-* ) machine=intel386 ;;
2427 powerpcle* ) machine=powerpcle ;;
2428 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2429 sparc* ) machine=sparc ;;
2430 * ) unported=yes ;;
2431 esac
2432 case "${canonical}" in
2433 ## The Sun386 didn't get past 4.0.
2434 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2435 *-sunos4.0* ) opsys=sunos4-0 ;;
2436 *-sunos4.1.[3-9]*noshare )
2437 ## This name is sunos413 instead of sunos4-1-3
2438 ## to avoid a file name conflict on MSDOS.
2439 opsys=sunos413
2440 NON_GNU_CPP=/usr/lib/cpp
2441 NON_GCC_TEST_OPTIONS=-Bstatic
2442 GCC_TEST_OPTIONS=-static
2443 ;;
2444 *-sunos4.1.[3-9]* | *-sunos4shr*)
2445 opsys=sunos4shr
2446 NON_GNU_CPP=/usr/lib/cpp
2447 ;;
2448 *-sunos4* | *-sunos )
2449 opsys=sunos4-1
2450 NON_GCC_TEST_OPTIONS=-Bstatic
2451 GCC_TEST_OPTIONS=-static
2452 ;;
2453 *-sunos5.3* | *-solaris2.3* )
2454 opsys=sol2-3
2455 NON_GNU_CPP=/usr/ccs/lib/cpp
2456 ;;
2457 *-sunos5.4* | *-solaris2.4* )
2458 opsys=sol2-4
2459 NON_GNU_CPP=/usr/ccs/lib/cpp
2460 RANLIB="ar -ts"
2461 ;;
2462 *-sunos5.5* | *-solaris2.5* )
2463 opsys=sol2-5
2464 NON_GNU_CPP=/usr/ccs/lib/cpp
2465 RANLIB="ar -ts"
2466 ;;
8e967cf7
MR
2467 *-sunos5.6* | *-solaris2.6* )
2468 opsys=sol2-6
2469 NON_GNU_CPP=/usr/ccs/lib/cpp
2470 RANLIB="ar -ts"
2471 ;;
ba4481b5 2472 *-sunos5* | *-solaris* )
9e71690e 2473 opsys=sol2-6
ba4481b5
DL
2474 NON_GNU_CPP=/usr/ccs/lib/cpp
2475 ;;
2476 * ) opsys=bsd4-2 ;;
2477 esac
2478 ## Watch out for a compiler that we know will not work.
2479 case "${canonical}" in
2480 *-solaris* | *-sunos5* )
2481 if [ "x$CC" = x/usr/ucb/cc ]; then
2482 ## /usr/ucb/cc doesn't work;
2483 ## we should find some other compiler that does work.
2484 unset CC
2485 fi
2486 ;;
2487 *) ;;
2488 esac
2489 ;;
2490 sparc-*-nextstep* )
2491 machine=sparc opsys=nextstep
2492 ;;
2493
2494 ## Tadpole 68k
2495 m68*-tadpole-sysv* )
2496 machine=tad68k opsys=usg5-3
2497 ;;
2498
2499 ## Tahoe machines
2500 tahoe-tahoe-bsd4.2* )
2501 machine=tahoe opsys=bsd4-2
2502 ;;
2503 tahoe-tahoe-bsd4.3* )
2504 machine=tahoe opsys=bsd4-3
2505 ;;
2506
2507 ## Tandem Integrity S2
2508 mips-tandem-sysv* )
2509 machine=tandem-s2 opsys=usg5-3
2510 ;;
2511
2512 ## Tektronix XD88
2513 m88k-tektronix-sysv3* )
2514 machine=tekxd88 opsys=usg5-3
2515 ;;
2516
2517 ## Tektronix 16000 box (6130?)
2518 ns16k-tektronix-bsd* )
2519 machine=ns16000 opsys=bsd4-2
2520 ;;
2521 ## Tektronix 4300
2522 ## src/m/tek4300.h hints that this is a m68k machine.
2523 m68*-tektronix-bsd* )
2524 machine=tek4300 opsys=bsd4-3
2525 ;;
2526
2527 ## Titan P2 or P3
2528 ## We seem to have lost the machine-description file titan.h!
2529 titan-titan-sysv* )
2530 machine=titan opsys=usg5-3
2531 ;;
2532
2533 ## Ustation E30 (SS5E)
2534 m68*-unisys-uniplus* )
2535 machine=ustation opsystem=unipl5-2
2536 ;;
2537
2538 ## Vaxen.
2539 vax-dec-* )
2540 machine=vax
2541 case "${canonical}" in
2542 *-bsd4.1* ) opsys=bsd4-1 ;;
2543 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2544 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2545 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2546 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2547 *-vms* ) opsys=vms ;;
2548 * ) unported=yes
2549 esac
2550 ;;
2551
2552 ## Whitechapel MG1
2553 ns16k-whitechapel-* )
2554 machine=mg1
2555 ## We don't know what sort of OS runs on these; we'll let the
2556 ## operating system guessing code below try.
2557 ;;
2558
2559 ## Wicat
2560 m68*-wicat-sysv* )
2561 machine=wicat opsys=usg5-2
2562 ;;
2563
f4988be7
GM
2564 ## IA-64
2565 ia64*-*-linux* )
2566 machine=ia64 opsys=gnu-linux
2567 ;;
2568
ba4481b5
DL
2569 ## Intel 386 machines where we don't care about the manufacturer
2570 i[3456]86-*-* )
2571 machine=intel386
2572 case "${canonical}" in
c60ee5e7 2573 *-cygwin ) opsys=cygwin ;;
23fd4483
ST
2574 *-darwin ) opsys=darwin
2575 CPP="${CC-cc} -E -no-cpp-precomp"
2576 ;;
ba4481b5
DL
2577 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2578 *-isc2.2* ) opsys=isc2-2 ;;
2579 *-isc4.0* ) opsys=isc4-0 ;;
2580 *-isc4.* ) opsys=isc4-1
2581 GCC_TEST_OPTIONS=-posix
2582 NON_GCC_TEST_OPTIONS=-Xp
2583 ;;
2584 *-isc* ) opsys=isc3-0 ;;
2585 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2586 *-esix* ) opsys=esix ;;
2587 *-xenix* ) opsys=xenix ;;
2588 *-linux-gnu* ) opsys=gnu-linux ;;
2589 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2590 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2591 NON_GNU_CPP=/lib/cpp
2592 # Prevent -belf from being passed to $CPP.
2593 # /lib/cpp does not accept it.
2594 OVERRIDE_CPPFLAGS=" "
2595 ;;
2596 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
55597d70
DL
2597 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2598 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
ba4481b5 2599 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2600 *-nextstep* ) opsys=nextstep ;;
2601 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2602 esac
2603 ;;
2604
2605 ## m68k Linux-based GNU system
2606 m68k-*-linux-gnu* )
2607 machine=m68k opsys=gnu-linux
2608 ;;
2609
2610 ## Mips Linux-based GNU system
cd958eb3 2611 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2612 machine=mips opsys=gnu-linux
2613 ;;
2614
2615 ## UXP/DS
2616 sparc-fujitsu-sysv4* )
2617 machine=sparc opsys=uxpds
2618 NON_GNU_CPP=/usr/ccs/lib/cpp
2619 RANLIB="ar -ts"
2620 ;;
2621
2622 ## UXP/V
2623 f301-fujitsu-uxpv4.1)
2624 machine=f301 opsys=uxpv
2625 ;;
2626
e0f712ba
AC
2627 ## Darwin / Mac OS X
2628 powerpc-apple-darwin* )
2629 machine=powermac opsys=darwin
2630 # Define CPP as follows to make autoconf work correctly.
2a75d75d 2631 CPP="${CC-cc} -E -no-cpp-precomp"
c14dc0ed
AS
2632 # Use fink packages if available.
2633 if test -d /sw/include && test -d /sw/lib; then
2634 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
2635 CPP="${CPP} ${GCC_TEST_OPTIONS}"
2636 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
2637 fi
e0f712ba
AC
2638 ;;
2639
598a2813
AS
2640 ## AMD x86-64 Linux-based GNU system
2641 x86_64-*-linux-gnu* )
24b01ec4 2642 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2643 ;;
2644
ba4481b5
DL
2645 * )
2646 unported=yes
2647 ;;
2648esac
2649
2650### If the code above didn't choose an operating system, just choose
2651### an operating system based on the configuration name. You really
2652### only want to use this when you have no idea what the right
2653### operating system is; if you know what operating systems a machine
2654### runs, it's cleaner to make it explicit in the case statement
2655### above.
2656if test x"${opsys}" = x; then
2657 case "${canonical}" in
2658 *-gnu* ) opsys=gnu ;;
2659 *-bsd4.[01] ) opsys=bsd4-1 ;;
2660 *-bsd4.2 ) opsys=bsd4-2 ;;
2661 *-bsd4.3 ) opsys=bsd4-3 ;;
2662 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2663 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2664 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2665 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2666 *-sysv4.2uw* ) opsys=unixware ;;
55597d70
DL
2667 *-sysv5uw* ) opsys=unixware ;;
2668 *-sysv5OpenUNIX* ) opsys=unixware ;;
ba4481b5
DL
2669 *-sysv4.1* | *-sysvr4.1* )
2670 NON_GNU_CPP=/usr/lib/cpp
2671 opsys=usg5-4 ;;
2672 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2673 if [ x$NON_GNU_CPP = x ]; then
2674 if [ -f /usr/ccs/lib/cpp ]; then
2675 NON_GNU_CPP=/usr/ccs/lib/cpp
2676 else
2677 NON_GNU_CPP=/lib/cpp
2678 fi
2679 fi
2680 opsys=usg5-4-2 ;;
2681 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2682 * )
2683 unported=yes
2684 ;;
2685 esac
2686fi
2687
c0d27fcc 2688
22044edf 2689
ba4481b5 2690if test $unported = yes; then
c0d27fcc 2691 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2692Check \`etc/MACHINES' for recognized configuration names." >&5
2693echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2694Check \`etc/MACHINES' for recognized configuration names." >&2;}
2695 { (exit 1); exit 1; }; }
ba4481b5
DL
2696fi
2697
2698machfile="m/${machine}.h"
2699opsysfile="s/${opsys}.h"
2700
c0d27fcc 2701
ba4481b5
DL
2702#### Choose a compiler.
2703test -n "$CC" && cc_specified=yes
2704
2705# Save the value of CFLAGS that the user specified.
2706SPECIFIED_CFLAGS="$CFLAGS"
2707
2708case ${with_gcc} in
2709 "yes" ) CC="gcc" GCC=yes ;;
2710 "no" ) : ${CC=cc} ;;
503d2be0
AS
2711 * )
2712esac
2713ac_ext=c
2714ac_cpp='$CPP $CPPFLAGS'
2715ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2716ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2717ac_compiler_gnu=$ac_cv_c_compiler_gnu
2718if test -n "$ac_tool_prefix"; then
2719 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2720set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2721echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2722echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2723if test "${ac_cv_prog_CC+set}" = set; then
2724 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2725else
2726 if test -n "$CC"; then
2727 ac_cv_prog_CC="$CC" # Let the user override the test.
2728else
c0d27fcc
MR
2729as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2730for as_dir in $PATH
2731do
2732 IFS=$as_save_IFS
2733 test -z "$as_dir" && as_dir=.
2734 for ac_exec_ext in '' $ac_executable_extensions; do
2735 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2736 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2737 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2738 break 2
2739 fi
2740done
503d2be0
AS
2741done
2742
ba4481b5
DL
2743fi
2744fi
503d2be0 2745CC=$ac_cv_prog_CC
ba4481b5 2746if test -n "$CC"; then
c0d27fcc 2747 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2748echo "${ECHO_T}$CC" >&6
2749else
c0d27fcc 2750 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2751echo "${ECHO_T}no" >&6
2752fi
2753
2754fi
2755if test -z "$ac_cv_prog_CC"; then
2756 ac_ct_CC=$CC
2757 # Extract the first word of "gcc", so it can be a program name with args.
2758set dummy gcc; ac_word=$2
c0d27fcc 2759echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2760echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2761if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2762 echo $ECHO_N "(cached) $ECHO_C" >&6
2763else
2764 if test -n "$ac_ct_CC"; then
2765 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2766else
c0d27fcc
MR
2767as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2768for as_dir in $PATH
2769do
2770 IFS=$as_save_IFS
2771 test -z "$as_dir" && as_dir=.
2772 for ac_exec_ext in '' $ac_executable_extensions; do
2773 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2774 ac_cv_prog_ac_ct_CC="gcc"
2775 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2776 break 2
2777 fi
2778done
503d2be0
AS
2779done
2780
2781fi
2782fi
2783ac_ct_CC=$ac_cv_prog_ac_ct_CC
2784if test -n "$ac_ct_CC"; then
c0d27fcc 2785 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2786echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2787else
c0d27fcc 2788 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2789echo "${ECHO_T}no" >&6
2790fi
2791
2792 CC=$ac_ct_CC
2793else
2794 CC="$ac_cv_prog_CC"
ba4481b5
DL
2795fi
2796
2797if test -z "$CC"; then
503d2be0
AS
2798 if test -n "$ac_tool_prefix"; then
2799 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2800set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2801echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2802echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2803if test "${ac_cv_prog_CC+set}" = set; then
2804 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2805else
2806 if test -n "$CC"; then
2807 ac_cv_prog_CC="$CC" # Let the user override the test.
2808else
c0d27fcc
MR
2809as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2810for as_dir in $PATH
2811do
2812 IFS=$as_save_IFS
2813 test -z "$as_dir" && as_dir=.
2814 for ac_exec_ext in '' $ac_executable_extensions; do
2815 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2816 ac_cv_prog_CC="${ac_tool_prefix}cc"
2817 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2818 break 2
2819 fi
2820done
503d2be0
AS
2821done
2822
2823fi
2824fi
2825CC=$ac_cv_prog_CC
2826if test -n "$CC"; then
c0d27fcc 2827 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2828echo "${ECHO_T}$CC" >&6
2829else
c0d27fcc 2830 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2831echo "${ECHO_T}no" >&6
2832fi
2833
2834fi
2835if test -z "$ac_cv_prog_CC"; then
2836 ac_ct_CC=$CC
2837 # Extract the first word of "cc", so it can be a program name with args.
2838set dummy cc; ac_word=$2
c0d27fcc 2839echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2840echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2841if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2842 echo $ECHO_N "(cached) $ECHO_C" >&6
2843else
2844 if test -n "$ac_ct_CC"; then
2845 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2846else
c0d27fcc
MR
2847as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2848for as_dir in $PATH
2849do
2850 IFS=$as_save_IFS
2851 test -z "$as_dir" && as_dir=.
2852 for ac_exec_ext in '' $ac_executable_extensions; do
2853 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2854 ac_cv_prog_ac_ct_CC="cc"
2855 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2856 break 2
2857 fi
2858done
503d2be0
AS
2859done
2860
2861fi
2862fi
2863ac_ct_CC=$ac_cv_prog_ac_ct_CC
2864if test -n "$ac_ct_CC"; then
c0d27fcc 2865 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2866echo "${ECHO_T}$ac_ct_CC" >&6
2867else
c0d27fcc 2868 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2869echo "${ECHO_T}no" >&6
2870fi
2871
2872 CC=$ac_ct_CC
2873else
2874 CC="$ac_cv_prog_CC"
2875fi
2876
2877fi
2878if test -z "$CC"; then
2879 # Extract the first word of "cc", so it can be a program name with args.
2880set dummy cc; ac_word=$2
c0d27fcc 2881echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2882echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2883if test "${ac_cv_prog_CC+set}" = set; then
2884 echo $ECHO_N "(cached) $ECHO_C" >&6
2885else
2886 if test -n "$CC"; then
2887 ac_cv_prog_CC="$CC" # Let the user override the test.
2888else
2889 ac_prog_rejected=no
c0d27fcc
MR
2890as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2891for as_dir in $PATH
2892do
2893 IFS=$as_save_IFS
2894 test -z "$as_dir" && as_dir=.
2895 for ac_exec_ext in '' $ac_executable_extensions; do
2896 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2897 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2898 ac_prog_rejected=yes
2899 continue
2900 fi
2901 ac_cv_prog_CC="cc"
2902 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2903 break 2
2904 fi
2905done
503d2be0
AS
2906done
2907
ba4481b5
DL
2908if test $ac_prog_rejected = yes; then
2909 # We found a bogon in the path, so make sure we never use it.
2910 set dummy $ac_cv_prog_CC
2911 shift
503d2be0 2912 if test $# != 0; then
ba4481b5
DL
2913 # We chose a different compiler from the bogus one.
2914 # However, it has the same basename, so the bogon will be chosen
2915 # first if we set CC to just the basename; use the full file name.
2916 shift
6bae0ccf 2917 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2918 fi
2919fi
2920fi
2921fi
503d2be0 2922CC=$ac_cv_prog_CC
ba4481b5 2923if test -n "$CC"; then
c0d27fcc 2924 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2925echo "${ECHO_T}$CC" >&6
ba4481b5 2926else
c0d27fcc 2927 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2928echo "${ECHO_T}no" >&6
ba4481b5
DL
2929fi
2930
503d2be0
AS
2931fi
2932if test -z "$CC"; then
2933 if test -n "$ac_tool_prefix"; then
2934 for ac_prog in cl
2935 do
2936 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2937set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2938echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2939echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2940if test "${ac_cv_prog_CC+set}" = set; then
2941 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2942else
2943 if test -n "$CC"; then
2944 ac_cv_prog_CC="$CC" # Let the user override the test.
2945else
c0d27fcc
MR
2946as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2947for as_dir in $PATH
2948do
2949 IFS=$as_save_IFS
2950 test -z "$as_dir" && as_dir=.
2951 for ac_exec_ext in '' $ac_executable_extensions; do
2952 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2953 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2954 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2955 break 2
2956 fi
2957done
503d2be0
AS
2958done
2959
c4bb2108
DL
2960fi
2961fi
503d2be0 2962CC=$ac_cv_prog_CC
c4bb2108 2963if test -n "$CC"; then
c0d27fcc 2964 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2965echo "${ECHO_T}$CC" >&6
c4bb2108 2966else
c0d27fcc 2967 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2968echo "${ECHO_T}no" >&6
2969fi
2970
2971 test -n "$CC" && break
2972 done
2973fi
2974if test -z "$CC"; then
2975 ac_ct_CC=$CC
2976 for ac_prog in cl
2977do
2978 # Extract the first word of "$ac_prog", so it can be a program name with args.
2979set dummy $ac_prog; ac_word=$2
c0d27fcc 2980echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2981echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2982if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2983 echo $ECHO_N "(cached) $ECHO_C" >&6
2984else
2985 if test -n "$ac_ct_CC"; then
2986 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2987else
c0d27fcc
MR
2988as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2989for as_dir in $PATH
2990do
2991 IFS=$as_save_IFS
2992 test -z "$as_dir" && as_dir=.
2993 for ac_exec_ext in '' $ac_executable_extensions; do
2994 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2995 ac_cv_prog_ac_ct_CC="$ac_prog"
2996 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2997 break 2
2998 fi
2999done
503d2be0
AS
3000done
3001
c4bb2108 3002fi
503d2be0
AS
3003fi
3004ac_ct_CC=$ac_cv_prog_ac_ct_CC
3005if test -n "$ac_ct_CC"; then
c0d27fcc 3006 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
3007echo "${ECHO_T}$ac_ct_CC" >&6
3008else
c0d27fcc 3009 echo "$as_me:$LINENO: result: no" >&5
503d2be0 3010echo "${ECHO_T}no" >&6
ba4481b5
DL
3011fi
3012
503d2be0
AS
3013 test -n "$ac_ct_CC" && break
3014done
ba4481b5 3015
503d2be0
AS
3016 CC=$ac_ct_CC
3017fi
3018
3019fi
ba4481b5 3020
c0d27fcc 3021
19650fd6
AS
3022test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3023See \`config.log' for more details." >&5
3024echo "$as_me: error: no acceptable C compiler found in \$PATH
3025See \`config.log' for more details." >&2;}
503d2be0 3026 { (exit 1); exit 1; }; }
c4bb2108 3027
503d2be0 3028# Provide some information about the compiler.
c0d27fcc 3029echo "$as_me:$LINENO:" \
503d2be0
AS
3030 "checking for C compiler version" >&5
3031ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 3032{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
3033 (eval $ac_compiler --version </dev/null >&5) 2>&5
3034 ac_status=$?
c0d27fcc 3035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3036 (exit $ac_status); }
c0d27fcc 3037{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
3038 (eval $ac_compiler -v </dev/null >&5) 2>&5
3039 ac_status=$?
c0d27fcc 3040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3041 (exit $ac_status); }
c0d27fcc 3042{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
3043 (eval $ac_compiler -V </dev/null >&5) 2>&5
3044 ac_status=$?
c0d27fcc 3045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3046 (exit $ac_status); }
3047
3048cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3049/* confdefs.h. */
3050_ACEOF
3051cat confdefs.h >>conftest.$ac_ext
3052cat >>conftest.$ac_ext <<_ACEOF
3053/* end confdefs.h. */
c4bb2108 3054
503d2be0
AS
3055int
3056main ()
3057{
3058
3059 ;
3060 return 0;
3061}
3062_ACEOF
3063ac_clean_files_save=$ac_clean_files
19650fd6 3064ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
3065# Try to create an executable without -o first, disregard a.out.
3066# It will help us diagnose broken compilers, and finding out an intuition
3067# of exeext.
edfaf76d
LK
3068echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3069echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
503d2be0 3070ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 3071if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
3072 (eval $ac_link_default) 2>&5
3073 ac_status=$?
c0d27fcc 3074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3075 (exit $ac_status); }; then
3076 # Find the output, starting from the most likely. This scheme is
3077# not robust to junk in `.', hence go to wildcards (a.*) only as a last
3078# resort.
c0d27fcc
MR
3079
3080# Be careful to initialize this variable, since it used to be cached.
3081# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
3082ac_cv_exeext=
19650fd6
AS
3083# b.out is created by i960 compilers.
3084for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3085do
6bae0ccf 3086 test -f "$ac_file" || continue
503d2be0 3087 case $ac_file in
19650fd6 3088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
edfaf76d 3089 ;;
19650fd6 3090 conftest.$ac_ext )
edfaf76d
LK
3091 # This is the source file.
3092 ;;
19650fd6 3093 [ab].out )
edfaf76d
LK
3094 # We found the default executable, but exeext='' is most
3095 # certainly right.
3096 break;;
19650fd6 3097 *.* )
edfaf76d
LK
3098 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3099 # FIXME: I believe we export ac_cv_exeext for Libtool,
3100 # but it would be cool to find out if it's true. Does anybody
3101 # maintain Libtool? --akim.
3102 export ac_cv_exeext
3103 break;;
19650fd6 3104 * )
edfaf76d 3105 break;;
503d2be0
AS
3106 esac
3107done
3108else
3109 echo "$as_me: failed program was:" >&5
19650fd6
AS
3110sed 's/^/| /' conftest.$ac_ext >&5
3111
6bae0ccf 3112{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
19650fd6 3113See \`config.log' for more details." >&5
6bae0ccf 3114echo "$as_me: error: C compiler cannot create executables
19650fd6 3115See \`config.log' for more details." >&2;}
503d2be0
AS
3116 { (exit 77); exit 77; }; }
3117fi
3118
3119ac_exeext=$ac_cv_exeext
c0d27fcc 3120echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3121echo "${ECHO_T}$ac_file" >&6
3122
3123# Check the compiler produces executables we can run. If not, either
3124# the compiler is broken, or we cross compile.
c0d27fcc 3125echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3126echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3127# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3128# If not cross compiling, check that we can run a simple program.
3129if test "$cross_compiling" != yes; then
3130 if { ac_try='./$ac_file'
c0d27fcc 3131 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3132 (eval $ac_try) 2>&5
3133 ac_status=$?
c0d27fcc 3134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3135 (exit $ac_status); }; }; then
3136 cross_compiling=no
ba4481b5 3137 else
503d2be0
AS
3138 if test "$cross_compiling" = maybe; then
3139 cross_compiling=yes
3140 else
c0d27fcc 3141 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
19650fd6
AS
3142If you meant to cross compile, use \`--host'.
3143See \`config.log' for more details." >&5
503d2be0 3144echo "$as_me: error: cannot run C compiled programs.
19650fd6
AS
3145If you meant to cross compile, use \`--host'.
3146See \`config.log' for more details." >&2;}
503d2be0
AS
3147 { (exit 1); exit 1; }; }
3148 fi
ba4481b5 3149 fi
503d2be0 3150fi
c0d27fcc 3151echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3152echo "${ECHO_T}yes" >&6
3153
19650fd6 3154rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3155ac_clean_files=$ac_clean_files_save
3156# Check the compiler produces executables we can run. If not, either
3157# the compiler is broken, or we cross compile.
c0d27fcc 3158echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3159echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3160echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3161echo "${ECHO_T}$cross_compiling" >&6
3162
c0d27fcc
MR
3163echo "$as_me:$LINENO: checking for suffix of executables" >&5
3164echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3165if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3166 (eval $ac_link) 2>&5
3167 ac_status=$?
c0d27fcc 3168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3169 (exit $ac_status); }; then
3170 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3171# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3172# work properly (i.e., refer to `conftest.exe'), while it won't with
3173# `rm'.
6bae0ccf
DL
3174for ac_file in conftest.exe conftest conftest.*; do
3175 test -f "$ac_file" || continue
503d2be0 3176 case $ac_file in
6bae0ccf 3177 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0 3178 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
edfaf76d
LK
3179 export ac_cv_exeext
3180 break;;
503d2be0
AS
3181 * ) break;;
3182 esac
3183done
ba4481b5 3184else
19650fd6
AS
3185 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3186See \`config.log' for more details." >&5
3187echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3188See \`config.log' for more details." >&2;}
503d2be0 3189 { (exit 1); exit 1; }; }
ba4481b5 3190fi
ba4481b5 3191
503d2be0 3192rm -f conftest$ac_cv_exeext
c0d27fcc 3193echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3194echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3195
503d2be0
AS
3196rm -f conftest.$ac_ext
3197EXEEXT=$ac_cv_exeext
3198ac_exeext=$EXEEXT
c0d27fcc
MR
3199echo "$as_me:$LINENO: checking for suffix of object files" >&5
3200echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3201if test "${ac_cv_objext+set}" = set; then
3202 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3203else
503d2be0 3204 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3205/* confdefs.h. */
3206_ACEOF
3207cat confdefs.h >>conftest.$ac_ext
3208cat >>conftest.$ac_ext <<_ACEOF
3209/* end confdefs.h. */
ba4481b5 3210
503d2be0
AS
3211int
3212main ()
3213{
ba4481b5 3214
503d2be0
AS
3215 ;
3216 return 0;
3217}
3218_ACEOF
3219rm -f conftest.o conftest.obj
c0d27fcc 3220if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3221 (eval $ac_compile) 2>&5
3222 ac_status=$?
c0d27fcc 3223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3224 (exit $ac_status); }; then
3225 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3226 case $ac_file in
6bae0ccf 3227 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3228 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3229 break;;
3230 esac
3231done
c4bb2108 3232else
503d2be0 3233 echo "$as_me: failed program was:" >&5
19650fd6
AS
3234sed 's/^/| /' conftest.$ac_ext >&5
3235
3236{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3237See \`config.log' for more details." >&5
3238echo "$as_me: error: cannot compute suffix of object files: cannot compile
3239See \`config.log' for more details." >&2;}
503d2be0 3240 { (exit 1); exit 1; }; }
c4bb2108
DL
3241fi
3242
503d2be0
AS
3243rm -f conftest.$ac_cv_objext conftest.$ac_ext
3244fi
c0d27fcc 3245echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3246echo "${ECHO_T}$ac_cv_objext" >&6
3247OBJEXT=$ac_cv_objext
3248ac_objext=$OBJEXT
c0d27fcc 3249echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3250echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3251if test "${ac_cv_c_compiler_gnu+set}" = set; then
3252 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3253else
503d2be0 3254 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3255/* confdefs.h. */
3256_ACEOF
3257cat confdefs.h >>conftest.$ac_ext
3258cat >>conftest.$ac_ext <<_ACEOF
3259/* end confdefs.h. */
503d2be0
AS
3260
3261int
3262main ()
3263{
3264#ifndef __GNUC__
3265 choke me
3266#endif
3267
3268 ;
3269 return 0;
3270}
3271_ACEOF
3272rm -f conftest.$ac_objext
c0d27fcc 3273if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3274 (eval $ac_compile) 2>conftest.er1
503d2be0 3275 ac_status=$?
edfaf76d
LK
3276 grep -v '^ *+' conftest.er1 >conftest.err
3277 rm -f conftest.er1
3278 cat conftest.err >&5
c0d27fcc 3279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3280 (exit $ac_status); } &&
10a3b1a1
EZ
3281 { ac_try='test -z "$ac_c_werror_flag"
3282 || test ! -s conftest.err'
edfaf76d
LK
3283 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3284 (eval $ac_try) 2>&5
3285 ac_status=$?
3286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3287 (exit $ac_status); }; } &&
3288 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3289 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3290 (eval $ac_try) 2>&5
3291 ac_status=$?
c0d27fcc 3292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3293 (exit $ac_status); }; }; then
3294 ac_compiler_gnu=yes
3295else
3296 echo "$as_me: failed program was:" >&5
19650fd6
AS
3297sed 's/^/| /' conftest.$ac_ext >&5
3298
503d2be0
AS
3299ac_compiler_gnu=no
3300fi
edfaf76d 3301rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3302ac_cv_c_compiler_gnu=$ac_compiler_gnu
3303
3304fi
c0d27fcc 3305echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3306echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3307GCC=`test $ac_compiler_gnu = yes && echo yes`
3308ac_test_CFLAGS=${CFLAGS+set}
3309ac_save_CFLAGS=$CFLAGS
3310CFLAGS="-g"
c0d27fcc 3311echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3312echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3313if test "${ac_cv_prog_cc_g+set}" = set; then
3314 echo $ECHO_N "(cached) $ECHO_C" >&6
3315else
3316 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3317/* confdefs.h. */
3318_ACEOF
3319cat confdefs.h >>conftest.$ac_ext
3320cat >>conftest.$ac_ext <<_ACEOF
3321/* end confdefs.h. */
503d2be0
AS
3322
3323int
3324main ()
3325{
3326
3327 ;
3328 return 0;
3329}
3330_ACEOF
3331rm -f conftest.$ac_objext
c0d27fcc 3332if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3333 (eval $ac_compile) 2>conftest.er1
503d2be0 3334 ac_status=$?
edfaf76d
LK
3335 grep -v '^ *+' conftest.er1 >conftest.err
3336 rm -f conftest.er1
3337 cat conftest.err >&5
c0d27fcc 3338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3339 (exit $ac_status); } &&
10a3b1a1
EZ
3340 { ac_try='test -z "$ac_c_werror_flag"
3341 || test ! -s conftest.err'
edfaf76d
LK
3342 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3343 (eval $ac_try) 2>&5
3344 ac_status=$?
3345 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3346 (exit $ac_status); }; } &&
3347 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3348 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3349 (eval $ac_try) 2>&5
3350 ac_status=$?
c0d27fcc 3351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3352 (exit $ac_status); }; }; then
ba4481b5
DL
3353 ac_cv_prog_cc_g=yes
3354else
503d2be0 3355 echo "$as_me: failed program was:" >&5
19650fd6
AS
3356sed 's/^/| /' conftest.$ac_ext >&5
3357
503d2be0 3358ac_cv_prog_cc_g=no
ba4481b5 3359fi
edfaf76d 3360rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 3361fi
c0d27fcc 3362echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3363echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3364if test "$ac_test_CFLAGS" = set; then
503d2be0 3365 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3366elif test $ac_cv_prog_cc_g = yes; then
3367 if test "$GCC" = yes; then
ba4481b5
DL
3368 CFLAGS="-g -O2"
3369 else
c4bb2108 3370 CFLAGS="-g"
ba4481b5 3371 fi
22afa6e8 3372else
c4bb2108
DL
3373 if test "$GCC" = yes; then
3374 CFLAGS="-O2"
3375 else
3376 CFLAGS=
3377 fi
ba4481b5 3378fi
6bae0ccf
DL
3379echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3380echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3381if test "${ac_cv_prog_cc_stdc+set}" = set; then
3382 echo $ECHO_N "(cached) $ECHO_C" >&6
3383else
3384 ac_cv_prog_cc_stdc=no
3385ac_save_CC=$CC
3386cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3387/* confdefs.h. */
3388_ACEOF
3389cat confdefs.h >>conftest.$ac_ext
3390cat >>conftest.$ac_ext <<_ACEOF
3391/* end confdefs.h. */
6bae0ccf
DL
3392#include <stdarg.h>
3393#include <stdio.h>
3394#include <sys/types.h>
3395#include <sys/stat.h>
3396/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3397struct buf { int x; };
3398FILE * (*rcsopen) (struct buf *, struct stat *, int);
3399static char *e (p, i)
3400 char **p;
3401 int i;
3402{
3403 return p[i];
3404}
3405static char *f (char * (*g) (char **, int), char **p, ...)
3406{
3407 char *s;
3408 va_list v;
3409 va_start (v,p);
3410 s = g (p, va_arg (v,int));
3411 va_end (v);
3412 return s;
3413}
edfaf76d
LK
3414
3415/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3416 function prototypes and stuff, but not '\xHH' hex character constants.
3417 These don't provoke an error unfortunately, instead are silently treated
3418 as 'x'. The following induces an error, until -std1 is added to get
3419 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3420 array size at least. It's necessary to write '\x00'==0 to get something
3421 that's true only with -std1. */
3422int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3423
6bae0ccf
DL
3424int test (int i, double x);
3425struct s1 {int (*f) (int a);};
3426struct s2 {int (*f) (double a);};
3427int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3428int argc;
3429char **argv;
3430int
3431main ()
3432{
3433return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3434 ;
3435 return 0;
3436}
3437_ACEOF
3438# Don't try gcc -ansi; that turns off useful extensions and
3439# breaks some systems' header files.
3440# AIX -qlanglvl=ansi
3441# Ultrix and OSF/1 -std1
3442# HP-UX 10.20 and later -Ae
3443# HP-UX older versions -Aa -D_HPUX_SOURCE
3444# SVR4 -Xc -D__EXTENSIONS__
3445for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3446do
3447 CC="$ac_save_CC $ac_arg"
3448 rm -f conftest.$ac_objext
3449if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3450 (eval $ac_compile) 2>conftest.er1
6bae0ccf 3451 ac_status=$?
edfaf76d
LK
3452 grep -v '^ *+' conftest.er1 >conftest.err
3453 rm -f conftest.er1
3454 cat conftest.err >&5
6bae0ccf
DL
3455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3456 (exit $ac_status); } &&
10a3b1a1
EZ
3457 { ac_try='test -z "$ac_c_werror_flag"
3458 || test ! -s conftest.err'
edfaf76d
LK
3459 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3460 (eval $ac_try) 2>&5
3461 ac_status=$?
3462 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3463 (exit $ac_status); }; } &&
3464 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
3465 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3466 (eval $ac_try) 2>&5
3467 ac_status=$?
3468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3469 (exit $ac_status); }; }; then
3470 ac_cv_prog_cc_stdc=$ac_arg
3471break
3472else
3473 echo "$as_me: failed program was:" >&5
19650fd6
AS
3474sed 's/^/| /' conftest.$ac_ext >&5
3475
6bae0ccf 3476fi
edfaf76d 3477rm -f conftest.err conftest.$ac_objext
6bae0ccf
DL
3478done
3479rm -f conftest.$ac_ext conftest.$ac_objext
3480CC=$ac_save_CC
3481
3482fi
3483
3484case "x$ac_cv_prog_cc_stdc" in
3485 x|xno)
3486 echo "$as_me:$LINENO: result: none needed" >&5
3487echo "${ECHO_T}none needed" >&6 ;;
3488 *)
3489 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3490echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3491 CC="$CC $ac_cv_prog_cc_stdc" ;;
3492esac
3493
503d2be0
AS
3494# Some people use a C++ compiler to compile C. Since we use `exit',
3495# in C++ we need to declare it. In case someone uses the same compiler
3496# for both compiling C and C++ we need to have the C++ compiler decide
3497# the declaration of exit, since it's the most demanding environment.
3498cat >conftest.$ac_ext <<_ACEOF
3499#ifndef __cplusplus
3500 choke me
3501#endif
3502_ACEOF
3503rm -f conftest.$ac_objext
c0d27fcc 3504if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3505 (eval $ac_compile) 2>conftest.er1
503d2be0 3506 ac_status=$?
edfaf76d
LK
3507 grep -v '^ *+' conftest.er1 >conftest.err
3508 rm -f conftest.er1
3509 cat conftest.err >&5
c0d27fcc 3510 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3511 (exit $ac_status); } &&
10a3b1a1
EZ
3512 { ac_try='test -z "$ac_c_werror_flag"
3513 || test ! -s conftest.err'
edfaf76d
LK
3514 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3515 (eval $ac_try) 2>&5
3516 ac_status=$?
3517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3518 (exit $ac_status); }; } &&
3519 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3521 (eval $ac_try) 2>&5
3522 ac_status=$?
c0d27fcc 3523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3524 (exit $ac_status); }; }; then
3525 for ac_declaration in \
edfaf76d 3526 '' \
503d2be0
AS
3527 'extern "C" void std::exit (int) throw (); using std::exit;' \
3528 'extern "C" void std::exit (int); using std::exit;' \
3529 'extern "C" void exit (int) throw ();' \
3530 'extern "C" void exit (int);' \
cffcede7 3531 'void exit (int);'
503d2be0
AS
3532do
3533 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3534/* confdefs.h. */
3535_ACEOF
3536cat confdefs.h >>conftest.$ac_ext
3537cat >>conftest.$ac_ext <<_ACEOF
3538/* end confdefs.h. */
7c9e5167 3539$ac_declaration
edfaf76d 3540#include <stdlib.h>
503d2be0
AS
3541int
3542main ()
3543{
3544exit (42);
3545 ;
3546 return 0;
3547}
3548_ACEOF
3549rm -f conftest.$ac_objext
c0d27fcc 3550if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3551 (eval $ac_compile) 2>conftest.er1
503d2be0 3552 ac_status=$?
edfaf76d
LK
3553 grep -v '^ *+' conftest.er1 >conftest.err
3554 rm -f conftest.er1
3555 cat conftest.err >&5
c0d27fcc 3556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3557 (exit $ac_status); } &&
10a3b1a1
EZ
3558 { ac_try='test -z "$ac_c_werror_flag"
3559 || test ! -s conftest.err'
edfaf76d
LK
3560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3561 (eval $ac_try) 2>&5
3562 ac_status=$?
3563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3564 (exit $ac_status); }; } &&
3565 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3566 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3567 (eval $ac_try) 2>&5
3568 ac_status=$?
c0d27fcc 3569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3570 (exit $ac_status); }; }; then
3571 :
3572else
3573 echo "$as_me: failed program was:" >&5
19650fd6
AS
3574sed 's/^/| /' conftest.$ac_ext >&5
3575
503d2be0
AS
3576continue
3577fi
edfaf76d 3578rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 3579 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3580/* confdefs.h. */
3581_ACEOF
3582cat confdefs.h >>conftest.$ac_ext
3583cat >>conftest.$ac_ext <<_ACEOF
3584/* end confdefs.h. */
503d2be0
AS
3585$ac_declaration
3586int
3587main ()
3588{
3589exit (42);
3590 ;
3591 return 0;
3592}
3593_ACEOF
3594rm -f conftest.$ac_objext
c0d27fcc 3595if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 3596 (eval $ac_compile) 2>conftest.er1
503d2be0 3597 ac_status=$?
edfaf76d
LK
3598 grep -v '^ *+' conftest.er1 >conftest.err
3599 rm -f conftest.er1
3600 cat conftest.err >&5
c0d27fcc 3601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3602 (exit $ac_status); } &&
10a3b1a1
EZ
3603 { ac_try='test -z "$ac_c_werror_flag"
3604 || test ! -s conftest.err'
edfaf76d
LK
3605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3606 (eval $ac_try) 2>&5
3607 ac_status=$?
3608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3609 (exit $ac_status); }; } &&
3610 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3611 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3612 (eval $ac_try) 2>&5
3613 ac_status=$?
c0d27fcc 3614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3615 (exit $ac_status); }; }; then
3616 break
3617else
3618 echo "$as_me: failed program was:" >&5
19650fd6
AS
3619sed 's/^/| /' conftest.$ac_ext >&5
3620
503d2be0 3621fi
edfaf76d 3622rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3623done
3624rm -f conftest*
3625if test -n "$ac_declaration"; then
3626 echo '#ifdef __cplusplus' >>confdefs.h
3627 echo $ac_declaration >>confdefs.h
3628 echo '#endif' >>confdefs.h
3629fi
ba4481b5 3630
503d2be0
AS
3631else
3632 echo "$as_me: failed program was:" >&5
19650fd6
AS
3633sed 's/^/| /' conftest.$ac_ext >&5
3634
503d2be0 3635fi
edfaf76d 3636rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3637ac_ext=c
3638ac_cpp='$CPP $CPPFLAGS'
3639ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3640ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3641ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3642
c0d27fcc 3643
ba4481b5
DL
3644# On Suns, sometimes $CPP names a directory.
3645if test -n "$CPP" && test -d "$CPP"; then
3646 CPP=
3647fi
3648
3649#### Some systems specify a CPP to use unless we are using GCC.
3650#### Now that we know whether we are using GCC, we can decide whether
3651#### to use that one.
3652if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3653then
3654 CPP="$NON_GNU_CPP"
3655fi
3656
3657#### Some systems specify a CC to use unless we are using GCC.
3658#### Now that we know whether we are using GCC, we can decide whether
3659#### to use that one.
3660if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3661 test x$cc_specified != xyes
3662then
3663 CC="$NON_GNU_CC"
3664fi
3665
3666if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3667then
3668 CC="$CC $GCC_TEST_OPTIONS"
3669fi
3670
3671if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3672then
3673 CC="$CC $NON_GCC_TEST_OPTIONS"
3674fi
3675
6a3a24fa 3676#### Some other nice autoconf tests.
ba4481b5 3677
c0d27fcc 3678echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3679echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3680LN_S=$as_ln_s
3681if test "$LN_S" = "ln -s"; then
c0d27fcc 3682 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3683echo "${ECHO_T}yes" >&6
ba4481b5 3684else
c0d27fcc 3685 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3686echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3687fi
3688
503d2be0
AS
3689ac_ext=c
3690ac_cpp='$CPP $CPPFLAGS'
3691ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3692ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3693ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3694echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3695echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3696# On Suns, sometimes $CPP names a directory.
3697if test -n "$CPP" && test -d "$CPP"; then
3698 CPP=
3699fi
3700if test -z "$CPP"; then
503d2be0
AS
3701 if test "${ac_cv_prog_CPP+set}" = set; then
3702 echo $ECHO_N "(cached) $ECHO_C" >&6
3703else
3704 # Double quotes because CPP needs to be expanded
3705 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3706 do
3707 ac_preproc_ok=false
3708for ac_c_preproc_warn_flag in '' yes
3709do
3710 # Use a header file that comes with gcc, so configuring glibc
3711 # with a fresh cross-compiler works.
19650fd6
AS
3712 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3713 # <limits.h> exists even on freestanding compilers.
ba4481b5 3714 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3715 # not just through cpp. "Syntax error" is here to catch this case.
3716 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3717/* confdefs.h. */
3718_ACEOF
3719cat confdefs.h >>conftest.$ac_ext
3720cat >>conftest.$ac_ext <<_ACEOF
3721/* end confdefs.h. */
3722#ifdef __STDC__
3723# include <limits.h>
3724#else
3725# include <assert.h>
3726#endif
edfaf76d 3727 Syntax error
503d2be0 3728_ACEOF
c0d27fcc 3729if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3730 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3731 ac_status=$?
6bae0ccf 3732 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3733 rm -f conftest.er1
3734 cat conftest.err >&5
c0d27fcc 3735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3736 (exit $ac_status); } >/dev/null; then
3737 if test -s conftest.err; then
3738 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 3739 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3740 else
3741 ac_cpp_err=
3742 fi
3743else
3744 ac_cpp_err=yes
3745fi
3746if test -z "$ac_cpp_err"; then
ba4481b5
DL
3747 :
3748else
503d2be0 3749 echo "$as_me: failed program was:" >&5
19650fd6
AS
3750sed 's/^/| /' conftest.$ac_ext >&5
3751
503d2be0
AS
3752 # Broken: fails on valid input.
3753continue
3754fi
3755rm -f conftest.err conftest.$ac_ext
3756
3757 # OK, works on sane cases. Now check whether non-existent headers
3758 # can be detected and how.
3759 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3760/* confdefs.h. */
3761_ACEOF
3762cat confdefs.h >>conftest.$ac_ext
3763cat >>conftest.$ac_ext <<_ACEOF
3764/* end confdefs.h. */
503d2be0
AS
3765#include <ac_nonexistent.h>
3766_ACEOF
c0d27fcc 3767if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3768 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3769 ac_status=$?
6bae0ccf 3770 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3771 rm -f conftest.er1
3772 cat conftest.err >&5
c0d27fcc 3773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3774 (exit $ac_status); } >/dev/null; then
3775 if test -s conftest.err; then
3776 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 3777 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3778 else
3779 ac_cpp_err=
3780 fi
3781else
3782 ac_cpp_err=yes
3783fi
3784if test -z "$ac_cpp_err"; then
3785 # Broken: success on invalid input.
3786continue
c4bb2108 3787else
503d2be0 3788 echo "$as_me: failed program was:" >&5
19650fd6
AS
3789sed 's/^/| /' conftest.$ac_ext >&5
3790
503d2be0
AS
3791 # Passes both tests.
3792ac_preproc_ok=:
3793break
3794fi
3795rm -f conftest.err conftest.$ac_ext
3796
3797done
3798# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3799rm -f conftest.err conftest.$ac_ext
3800if $ac_preproc_ok; then
3801 break
3802fi
3803
3804 done
3805 ac_cv_prog_CPP=$CPP
3806
3807fi
3808 CPP=$ac_cv_prog_CPP
3809else
3810 ac_cv_prog_CPP=$CPP
3811fi
c0d27fcc 3812echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3813echo "${ECHO_T}$CPP" >&6
3814ac_preproc_ok=false
3815for ac_c_preproc_warn_flag in '' yes
3816do
3817 # Use a header file that comes with gcc, so configuring glibc
3818 # with a fresh cross-compiler works.
19650fd6
AS
3819 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3820 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3821 # On the NeXT, cc -E runs the code through the compiler's parser,
3822 # not just through cpp. "Syntax error" is here to catch this case.
3823 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3824/* confdefs.h. */
3825_ACEOF
3826cat confdefs.h >>conftest.$ac_ext
3827cat >>conftest.$ac_ext <<_ACEOF
3828/* end confdefs.h. */
3829#ifdef __STDC__
3830# include <limits.h>
3831#else
3832# include <assert.h>
3833#endif
edfaf76d 3834 Syntax error
503d2be0 3835_ACEOF
c0d27fcc 3836if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3837 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3838 ac_status=$?
6bae0ccf 3839 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3840 rm -f conftest.er1
3841 cat conftest.err >&5
c0d27fcc 3842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3843 (exit $ac_status); } >/dev/null; then
3844 if test -s conftest.err; then
3845 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 3846 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3847 else
3848 ac_cpp_err=
3849 fi
3850else
3851 ac_cpp_err=yes
3852fi
3853if test -z "$ac_cpp_err"; then
ba4481b5
DL
3854 :
3855else
503d2be0 3856 echo "$as_me: failed program was:" >&5
19650fd6
AS
3857sed 's/^/| /' conftest.$ac_ext >&5
3858
503d2be0
AS
3859 # Broken: fails on valid input.
3860continue
3861fi
3862rm -f conftest.err conftest.$ac_ext
3863
3864 # OK, works on sane cases. Now check whether non-existent headers
3865 # can be detected and how.
3866 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3867/* confdefs.h. */
3868_ACEOF
3869cat confdefs.h >>conftest.$ac_ext
3870cat >>conftest.$ac_ext <<_ACEOF
3871/* end confdefs.h. */
503d2be0
AS
3872#include <ac_nonexistent.h>
3873_ACEOF
c0d27fcc 3874if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3875 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3876 ac_status=$?
6bae0ccf 3877 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3878 rm -f conftest.er1
3879 cat conftest.err >&5
c0d27fcc 3880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3881 (exit $ac_status); } >/dev/null; then
3882 if test -s conftest.err; then
3883 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 3884 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3885 else
3886 ac_cpp_err=
3887 fi
3888else
3889 ac_cpp_err=yes
c4bb2108 3890fi
503d2be0
AS
3891if test -z "$ac_cpp_err"; then
3892 # Broken: success on invalid input.
3893continue
3894else
3895 echo "$as_me: failed program was:" >&5
19650fd6
AS
3896sed 's/^/| /' conftest.$ac_ext >&5
3897
503d2be0
AS
3898 # Passes both tests.
3899ac_preproc_ok=:
3900break
ba4481b5 3901fi
503d2be0
AS
3902rm -f conftest.err conftest.$ac_ext
3903
3904done
3905# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3906rm -f conftest.err conftest.$ac_ext
3907if $ac_preproc_ok; then
3908 :
ba4481b5 3909else
19650fd6
AS
3910 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3911See \`config.log' for more details." >&5
3912echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3913See \`config.log' for more details." >&2;}
503d2be0 3914 { (exit 1); exit 1; }; }
ba4481b5 3915fi
503d2be0
AS
3916
3917ac_ext=c
3918ac_cpp='$CPP $CPPFLAGS'
3919ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3920ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3921ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3922
3923# Find a good install program. We prefer a C program (faster),
3924# so one script is as good as another. But avoid the broken or
3925# incompatible versions:
3926# SysV /etc/install, /usr/sbin/install
3927# SunOS /usr/etc/install
3928# IRIX /sbin/install
3929# AIX /bin/install
503d2be0 3930# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3931# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3932# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3933# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
edfaf76d 3934# OS/2's system install, which has a completely different semantic
ba4481b5 3935# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3936echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3937echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3938if test -z "$INSTALL"; then
503d2be0
AS
3939if test "${ac_cv_path_install+set}" = set; then
3940 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3941else
c0d27fcc
MR
3942 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3943for as_dir in $PATH
3944do
3945 IFS=$as_save_IFS
3946 test -z "$as_dir" && as_dir=.
3947 # Account for people who put trailing slashes in PATH elements.
3948case $as_dir/ in
3949 ./ | .// | /cC/* | \
3950 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
edfaf76d 3951 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
c0d27fcc
MR
3952 /usr/ucb/* ) ;;
3953 *)
3954 # OSF1 and SCO ODT 3.0 have their own names for install.
3955 # Don't use installbsd from OSF since it installs stuff as root
3956 # by default.
3957 for ac_prog in ginstall scoinst install; do
3958 for ac_exec_ext in '' $ac_executable_extensions; do
edfaf76d
LK
3959 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3960 if test $ac_prog = install &&
3961 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3962 # AIX install. It has an incompatible calling convention.
3963 :
3964 elif test $ac_prog = install &&
3965 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3966 # program-specific install script used by HP pwplus--don't use.
3967 :
3968 else
3969 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3970 break 3
3971 fi
3972 fi
ba4481b5 3973 done
c0d27fcc
MR
3974 done
3975 ;;
3976esac
3977done
3978
ba4481b5
DL
3979
3980fi
3981 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3982 INSTALL=$ac_cv_path_install
ba4481b5
DL
3983 else
3984 # As a last resort, use the slow shell script. We don't cache a
3985 # path for INSTALL within a source directory, because that will
3986 # break other packages using the cache if that directory is
3987 # removed, or if the path is relative.
503d2be0 3988 INSTALL=$ac_install_sh
ba4481b5
DL
3989 fi
3990fi
c0d27fcc 3991echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3992echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3993
3994# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3995# It thinks the first close brace ends the variable substitution.
3996test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3997
503d2be0 3998test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3999
ba4481b5
DL
4000test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4001
c0d27fcc
MR
4002if test "x$RANLIB" = x; then
4003 if test -n "$ac_tool_prefix"; then
4004 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4005set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4006echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 4007echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 4008if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 4009 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
4010else
4011 if test -n "$RANLIB"; then
4012 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4013else
c0d27fcc
MR
4014as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4015for as_dir in $PATH
4016do
4017 IFS=$as_save_IFS
4018 test -z "$as_dir" && as_dir=.
4019 for ac_exec_ext in '' $ac_executable_extensions; do
4020 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4021 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4022 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4023 break 2
4024 fi
4025done
503d2be0
AS
4026done
4027
7397acc4
DL
4028fi
4029fi
503d2be0 4030RANLIB=$ac_cv_prog_RANLIB
7397acc4 4031if test -n "$RANLIB"; then
c0d27fcc 4032 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
4033echo "${ECHO_T}$RANLIB" >&6
4034else
c0d27fcc 4035 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4036echo "${ECHO_T}no" >&6
4037fi
4038
4039fi
4040if test -z "$ac_cv_prog_RANLIB"; then
4041 ac_ct_RANLIB=$RANLIB
4042 # Extract the first word of "ranlib", so it can be a program name with args.
4043set dummy ranlib; ac_word=$2
c0d27fcc 4044echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
4045echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4046if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4047 echo $ECHO_N "(cached) $ECHO_C" >&6
4048else
4049 if test -n "$ac_ct_RANLIB"; then
4050 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4051else
c0d27fcc
MR
4052as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4053for as_dir in $PATH
4054do
4055 IFS=$as_save_IFS
4056 test -z "$as_dir" && as_dir=.
4057 for ac_exec_ext in '' $ac_executable_extensions; do
4058 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4059 ac_cv_prog_ac_ct_RANLIB="ranlib"
4060 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4061 break 2
4062 fi
4063done
503d2be0
AS
4064done
4065
4066 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4067fi
4068fi
4069ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4070if test -n "$ac_ct_RANLIB"; then
c0d27fcc 4071 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
4072echo "${ECHO_T}$ac_ct_RANLIB" >&6
4073else
c0d27fcc 4074 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4075echo "${ECHO_T}no" >&6
4076fi
4077
4078 RANLIB=$ac_ct_RANLIB
7397acc4 4079else
503d2be0 4080 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
4081fi
4082
4083fi
9e71690e
DK
4084# Extract the first word of "install-info", so it can be a program name with args.
4085set dummy install-info; ac_word=$2
4086echo "$as_me:$LINENO: checking for $ac_word" >&5
4087echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4088if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4089 echo $ECHO_N "(cached) $ECHO_C" >&6
4090else
4091 case $INSTALL_INFO in
4092 [\\/]* | ?:[\\/]*)
4093 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4094 ;;
4095 *)
4096 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4097for as_dir in $PATH
4098do
4099 IFS=$as_save_IFS
4100 test -z "$as_dir" && as_dir=.
4101 for ac_exec_ext in '' $ac_executable_extensions; do
4102 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4103 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4104 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4105 break 2
4106 fi
4107done
4108done
4109
4110 ;;
4111esac
4112fi
4113INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4114
4115if test -n "$INSTALL_INFO"; then
4116 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4117echo "${ECHO_T}$INSTALL_INFO" >&6
4118else
4119 echo "$as_me:$LINENO: result: no" >&5
4120echo "${ECHO_T}no" >&6
4121fi
4122
4123# Extract the first word of "install-info", so it can be a program name with args.
4124set dummy install-info; ac_word=$2
4125echo "$as_me:$LINENO: checking for $ac_word" >&5
4126echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4127if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4128 echo $ECHO_N "(cached) $ECHO_C" >&6
4129else
4130 case $INSTALL_INFO in
4131 [\\/]* | ?:[\\/]*)
4132 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4133 ;;
4134 *)
4135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4136for as_dir in /usr/sbin
4137do
4138 IFS=$as_save_IFS
4139 test -z "$as_dir" && as_dir=.
4140 for ac_exec_ext in '' $ac_executable_extensions; do
4141 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4142 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4143 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4144 break 2
4145 fi
4146done
4147done
4148
4149 ;;
4150esac
4151fi
4152INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4153
4154if test -n "$INSTALL_INFO"; then
4155 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4156echo "${ECHO_T}$INSTALL_INFO" >&6
4157else
4158 echo "$as_me:$LINENO: result: no" >&5
4159echo "${ECHO_T}no" >&6
4160fi
4161
4162# Extract the first word of "install-info", so it can be a program name with args.
4163set dummy install-info; ac_word=$2
4164echo "$as_me:$LINENO: checking for $ac_word" >&5
4165echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4166if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4167 echo $ECHO_N "(cached) $ECHO_C" >&6
4168else
4169 case $INSTALL_INFO in
4170 [\\/]* | ?:[\\/]*)
4171 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4172 ;;
4173 *)
4174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4175for as_dir in /sbin
4176do
4177 IFS=$as_save_IFS
4178 test -z "$as_dir" && as_dir=.
4179 for ac_exec_ext in '' $ac_executable_extensions; do
4180 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4181 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4182 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4183 break 2
4184 fi
4185done
4186done
4187
4188 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4189 ;;
4190esac
4191fi
4192INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4193
4194if test -n "$INSTALL_INFO"; then
4195 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4196echo "${ECHO_T}$INSTALL_INFO" >&6
4197else
4198 echo "$as_me:$LINENO: result: no" >&5
4199echo "${ECHO_T}no" >&6
4200fi
4201
ba4481b5 4202
c0d27fcc 4203
8e967cf7
MR
4204if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4205then
4206 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4207fi
4208
4209if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4210then
4211 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4212fi
4213
c0d27fcc 4214
fe239f0f 4215late_LDFLAGS=$LDFLAGS
4af002d6 4216if test "$GCC" = yes; then
fe239f0f
AS
4217 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
4218else
4219 LDFLAGS="$LDFLAGS -znocombreloc"
4220fi
4221
edfaf76d
LK
4222echo "$as_me:$LINENO: checking for -znocombreloc" >&5
4223echo $ECHO_N "checking for -znocombreloc... $ECHO_C" >&6
fe239f0f
AS
4224
4225cat >conftest.$ac_ext <<_ACEOF
4226main(){return 0;}
4227_ACEOF
4228rm -f conftest.$ac_objext conftest$ac_exeext
4229if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 4230 (eval $ac_link) 2>conftest.er1
fe239f0f 4231 ac_status=$?
edfaf76d
LK
4232 grep -v '^ *+' conftest.er1 >conftest.err
4233 rm -f conftest.er1
4234 cat conftest.err >&5
fe239f0f
AS
4235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4236 (exit $ac_status); } &&
10a3b1a1
EZ
4237 { ac_try='test -z "$ac_c_werror_flag"
4238 || test ! -s conftest.err'
edfaf76d
LK
4239 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4240 (eval $ac_try) 2>&5
4241 ac_status=$?
4242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4243 (exit $ac_status); }; } &&
4244 { ac_try='test -s conftest$ac_exeext'
fe239f0f
AS
4245 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4246 (eval $ac_try) 2>&5
4247 ac_status=$?
4248 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4249 (exit $ac_status); }; }; then
4250 echo "$as_me:$LINENO: result: yes" >&5
4251echo "${ECHO_T}yes" >&6
4252else
4253 echo "$as_me: failed program was:" >&5
4254sed 's/^/| /' conftest.$ac_ext >&5
4255
4256LDFLAGS=$late_LDFLAGS
4257 echo "$as_me:$LINENO: result: no" >&5
4258echo "${ECHO_T}no" >&6
4259fi
edfaf76d
LK
4260rm -f conftest.err conftest.$ac_objext \
4261 conftest$ac_exeext conftest.$ac_ext
fe239f0f 4262
c0d27fcc 4263
6bae0ccf
DL
4264echo "$as_me:$LINENO: checking for egrep" >&5
4265echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4266if test "${ac_cv_prog_egrep+set}" = set; then
4267 echo $ECHO_N "(cached) $ECHO_C" >&6
4268else
4269 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4270 then ac_cv_prog_egrep='grep -E'
4271 else ac_cv_prog_egrep='egrep'
4272 fi
4273fi
4274echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4275echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4276 EGREP=$ac_cv_prog_egrep
4277
4278
c0d27fcc
MR
4279
4280echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4281echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4282cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4283/* confdefs.h. */
4284_ACEOF
4285cat confdefs.h >>conftest.$ac_ext
4286cat >>conftest.$ac_ext <<_ACEOF
4287/* end confdefs.h. */
ba4481b5
DL
4288#ifdef _AIX
4289 yes
4290#endif
4291
503d2be0 4292_ACEOF
ba4481b5 4293if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4294 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4295 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4296echo "${ECHO_T}yes" >&6
c0d27fcc 4297cat >>confdefs.h <<\_ACEOF
ba4481b5 4298#define _ALL_SOURCE 1
c0d27fcc 4299_ACEOF
ba4481b5
DL
4300
4301else
c0d27fcc 4302 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4303echo "${ECHO_T}no" >&6
ba4481b5
DL
4304fi
4305rm -f conftest*
4306
c0d27fcc
MR
4307
4308
4489ece2 4309
3b33a005
DL
4310#### Extract some information from the operating system and machine files.
4311
c0d27fcc 4312{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4313 - which libraries the lib-src programs will want, and
503d2be0
AS
4314 - whether the GNU malloc routines are usable..." >&5
4315echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4316 - which libraries the lib-src programs will want, and
503d2be0 4317 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4318
4319### First figure out CFLAGS (which we use for running the compiler here)
4320### and REAL_CFLAGS (which we use for real compilation).
4321### The two are the same except on a few systems, where they are made
4322### different to work around various lossages. For example,
4323### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4324### as implying static linking.
4325
4326### If the CFLAGS env var is specified, we use that value
4327### instead of the default.
4328
4329### It's not important that this name contain the PID; you can't run
4330### two configures in the same directory and have anything work
4331### anyway.
4332tempcname="conftest.c"
4333
4334echo '
4335#include "'${srcdir}'/src/'${opsysfile}'"
4336#include "'${srcdir}'/src/'${machfile}'"
4337#ifndef LIBS_MACHINE
4338#define LIBS_MACHINE
4339#endif
4340#ifndef LIBS_SYSTEM
4341#define LIBS_SYSTEM
4342#endif
4343#ifndef C_SWITCH_SYSTEM
4344#define C_SWITCH_SYSTEM
4345#endif
4346#ifndef C_SWITCH_MACHINE
4347#define C_SWITCH_MACHINE
4348#endif
4349configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4350configure___ c_switch_system=C_SWITCH_SYSTEM
4351configure___ c_switch_machine=C_SWITCH_MACHINE
4352
4353#ifndef LIB_X11_LIB
4354#define LIB_X11_LIB -lX11
4355#endif
4356
4357#ifndef LIBX11_MACHINE
4358#define LIBX11_MACHINE
4359#endif
4360
4361#ifndef LIBX11_SYSTEM
4362#define LIBX11_SYSTEM
4363#endif
4364configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4365
4366#ifdef UNEXEC
4367configure___ unexec=UNEXEC
4368#else
4369configure___ unexec=unexec.o
4370#endif
4371
4372#ifdef SYSTEM_MALLOC
4373configure___ system_malloc=yes
4374#else
4375configure___ system_malloc=no
4376#endif
4377
ef9e4345
GM
4378#ifdef USE_MMAP_FOR_BUFFERS
4379configure___ use_mmap_for_buffers=yes
73b77ee5 4380#else
ef9e4345 4381configure___ use_mmap_for_buffers=no
73b77ee5
GM
4382#endif
4383
3b33a005
DL
4384#ifndef C_DEBUG_SWITCH
4385#define C_DEBUG_SWITCH -g
4386#endif
4387
4388#ifndef C_OPTIMIZE_SWITCH
4389#ifdef __GNUC__
4390#define C_OPTIMIZE_SWITCH -O2
4391#else
4392#define C_OPTIMIZE_SWITCH -O
4393#endif
4394#endif
4395
4396#ifndef LD_SWITCH_MACHINE
4397#define LD_SWITCH_MACHINE
4398#endif
4399
4400#ifndef LD_SWITCH_SYSTEM
4401#define LD_SWITCH_SYSTEM
4402#endif
4403
4404#ifndef LD_SWITCH_X_SITE_AUX
4405#define LD_SWITCH_X_SITE_AUX
503d2be0 4406#endif
3b33a005
DL
4407
4408configure___ ld_switch_system=LD_SWITCH_SYSTEM
4409configure___ ld_switch_machine=LD_SWITCH_MACHINE
4410
4411#ifdef THIS_IS_CONFIGURE
4412
4413/* Get the CFLAGS for tests in configure. */
4414#ifdef __GNUC__
4415configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4416#else
4417configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4418#endif
4419
4420#else /* not THIS_IS_CONFIGURE */
4421
4422/* Get the CFLAGS for real compilation. */
4423#ifdef __GNUC__
4424configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4425#else
4426configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4427#endif
4428
4429#endif /* not THIS_IS_CONFIGURE */
4430' > ${tempcname}
4431
4432# The value of CPP is a quoted variable reference, so we need to do this
4433# to get its actual value...
4434CPP=`eval "echo $CPP"`
4435eval `${CPP} -Isrc ${tempcname} \
4436 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4437if test "x$SPECIFIED_CFLAGS" = x; then
4438 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4439 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4440else
4441 REAL_CFLAGS="$CFLAGS"
4442fi
4443rm ${tempcname}
4444
4445ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4446
4447### Make sure subsequent tests use flags consistent with the build flags.
4448
4449if test x"${OVERRIDE_CPPFLAGS}" != x; then
4450 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4451else
4452 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4453fi
4454
6bae0ccf
DL
4455
4456
22044edf
DL
4457
4458cat >>confdefs.h <<\_ACEOF
4459#define _GNU_SOURCE 1
4460_ACEOF
4461
4462
4463
503d2be0 4464# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4465if test "${enable_largefile+set}" = set; then
4466 enableval="$enable_largefile"
f4988be7 4467
503d2be0
AS
4468fi;
4469if test "$enable_largefile" != no; then
f4988be7 4470
c0d27fcc 4471 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4472echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4473if test "${ac_cv_sys_largefile_CC+set}" = set; then
4474 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4475else
f4988be7 4476 ac_cv_sys_largefile_CC=no
503d2be0
AS
4477 if test "$GCC" != yes; then
4478 ac_save_CC=$CC
4479 while :; do
4480 # IRIX 6.2 and later do not support large files by default,
4481 # so use the C compiler's -n32 option if that helps.
edfaf76d 4482 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4483/* confdefs.h. */
4484_ACEOF
4485cat confdefs.h >>conftest.$ac_ext
4486cat >>conftest.$ac_ext <<_ACEOF
4487/* end confdefs.h. */
f4988be7 4488#include <sys/types.h>
503d2be0
AS
4489 /* Check that off_t can represent 2**63 - 1 correctly.
4490 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4491 since some C++ compilers masquerading as C compilers
4492 incorrectly reject 9223372036854775807. */
4493#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4494 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4495 && LARGE_OFF_T % 2147483647 == 1)
4496 ? 1 : -1];
4497int
4498main ()
4499{
f4988be7 4500
503d2be0
AS
4501 ;
4502 return 0;
4503}
4504_ACEOF
4505 rm -f conftest.$ac_objext
c0d27fcc 4506if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4507 (eval $ac_compile) 2>conftest.er1
503d2be0 4508 ac_status=$?
edfaf76d
LK
4509 grep -v '^ *+' conftest.er1 >conftest.err
4510 rm -f conftest.er1
4511 cat conftest.err >&5
c0d27fcc 4512 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4513 (exit $ac_status); } &&
10a3b1a1
EZ
4514 { ac_try='test -z "$ac_c_werror_flag"
4515 || test ! -s conftest.err'
edfaf76d
LK
4516 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4517 (eval $ac_try) 2>&5
4518 ac_status=$?
4519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4520 (exit $ac_status); }; } &&
4521 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4522 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4523 (eval $ac_try) 2>&5
4524 ac_status=$?
c0d27fcc 4525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4526 (exit $ac_status); }; }; then
4527 break
b192d653 4528else
503d2be0 4529 echo "$as_me: failed program was:" >&5
19650fd6
AS
4530sed 's/^/| /' conftest.$ac_ext >&5
4531
503d2be0 4532fi
edfaf76d 4533rm -f conftest.err conftest.$ac_objext
503d2be0
AS
4534 CC="$CC -n32"
4535 rm -f conftest.$ac_objext
c0d27fcc 4536if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4537 (eval $ac_compile) 2>conftest.er1
503d2be0 4538 ac_status=$?
edfaf76d
LK
4539 grep -v '^ *+' conftest.er1 >conftest.err
4540 rm -f conftest.er1
4541 cat conftest.err >&5
c0d27fcc 4542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4543 (exit $ac_status); } &&
10a3b1a1
EZ
4544 { ac_try='test -z "$ac_c_werror_flag"
4545 || test ! -s conftest.err'
edfaf76d
LK
4546 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4547 (eval $ac_try) 2>&5
4548 ac_status=$?
4549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4550 (exit $ac_status); }; } &&
4551 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4552 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4553 (eval $ac_try) 2>&5
4554 ac_status=$?
c0d27fcc 4555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4556 (exit $ac_status); }; }; then
4557 ac_cv_sys_largefile_CC=' -n32'; break
4558else
4559 echo "$as_me: failed program was:" >&5
19650fd6
AS
4560sed 's/^/| /' conftest.$ac_ext >&5
4561
503d2be0 4562fi
edfaf76d
LK
4563rm -f conftest.err conftest.$ac_objext
4564 break
503d2be0
AS
4565 done
4566 CC=$ac_save_CC
4567 rm -f conftest.$ac_ext
4568 fi
b192d653 4569fi
c0d27fcc 4570echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4571echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4572 if test "$ac_cv_sys_largefile_CC" != no; then
4573 CC=$CC$ac_cv_sys_largefile_CC
4574 fi
b192d653 4575
c0d27fcc 4576 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4577echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4578if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4579 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4580else
503d2be0 4581 while :; do
f4988be7 4582 ac_cv_sys_file_offset_bits=no
503d2be0 4583 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4584/* confdefs.h. */
4585_ACEOF
4586cat confdefs.h >>conftest.$ac_ext
4587cat >>conftest.$ac_ext <<_ACEOF
4588/* end confdefs.h. */
f4988be7 4589#include <sys/types.h>
503d2be0
AS
4590 /* Check that off_t can represent 2**63 - 1 correctly.
4591 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4592 since some C++ compilers masquerading as C compilers
4593 incorrectly reject 9223372036854775807. */
4594#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4595 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4596 && LARGE_OFF_T % 2147483647 == 1)
4597 ? 1 : -1];
4598int
4599main ()
4600{
f4988be7 4601
503d2be0
AS
4602 ;
4603 return 0;
4604}
4605_ACEOF
4606rm -f conftest.$ac_objext
c0d27fcc 4607if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4608 (eval $ac_compile) 2>conftest.er1
503d2be0 4609 ac_status=$?
edfaf76d
LK
4610 grep -v '^ *+' conftest.er1 >conftest.err
4611 rm -f conftest.er1
4612 cat conftest.err >&5
c0d27fcc 4613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4614 (exit $ac_status); } &&
10a3b1a1
EZ
4615 { ac_try='test -z "$ac_c_werror_flag"
4616 || test ! -s conftest.err'
edfaf76d
LK
4617 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4618 (eval $ac_try) 2>&5
4619 ac_status=$?
4620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4621 (exit $ac_status); }; } &&
4622 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4623 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4624 (eval $ac_try) 2>&5
4625 ac_status=$?
c0d27fcc 4626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4627 (exit $ac_status); }; }; then
4628 break
f4988be7 4629else
503d2be0 4630 echo "$as_me: failed program was:" >&5
19650fd6
AS
4631sed 's/^/| /' conftest.$ac_ext >&5
4632
503d2be0 4633fi
edfaf76d 4634rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4635 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4636/* confdefs.h. */
4637_ACEOF
4638cat confdefs.h >>conftest.$ac_ext
4639cat >>conftest.$ac_ext <<_ACEOF
4640/* end confdefs.h. */
f4988be7
GM
4641#define _FILE_OFFSET_BITS 64
4642#include <sys/types.h>
503d2be0
AS
4643 /* Check that off_t can represent 2**63 - 1 correctly.
4644 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4645 since some C++ compilers masquerading as C compilers
4646 incorrectly reject 9223372036854775807. */
4647#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4648 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4649 && LARGE_OFF_T % 2147483647 == 1)
4650 ? 1 : -1];
4651int
4652main ()
4653{
4654
4655 ;
4656 return 0;
4657}
4658_ACEOF
4659rm -f conftest.$ac_objext
c0d27fcc 4660if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4661 (eval $ac_compile) 2>conftest.er1
503d2be0 4662 ac_status=$?
edfaf76d
LK
4663 grep -v '^ *+' conftest.er1 >conftest.err
4664 rm -f conftest.er1
4665 cat conftest.err >&5
c0d27fcc 4666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4667 (exit $ac_status); } &&
10a3b1a1
EZ
4668 { ac_try='test -z "$ac_c_werror_flag"
4669 || test ! -s conftest.err'
edfaf76d
LK
4670 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4671 (eval $ac_try) 2>&5
4672 ac_status=$?
4673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4674 (exit $ac_status); }; } &&
4675 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4676 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4677 (eval $ac_try) 2>&5
4678 ac_status=$?
c0d27fcc 4679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4680 (exit $ac_status); }; }; then
4681 ac_cv_sys_file_offset_bits=64; break
4682else
4683 echo "$as_me: failed program was:" >&5
19650fd6
AS
4684sed 's/^/| /' conftest.$ac_ext >&5
4685
503d2be0 4686fi
edfaf76d 4687rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4688 break
4689done
ba4481b5 4690fi
c0d27fcc 4691echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4692echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4693if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4694
c0d27fcc 4695cat >>confdefs.h <<_ACEOF
f4988be7 4696#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4697_ACEOF
f4988be7 4698
503d2be0
AS
4699fi
4700rm -f conftest*
c0d27fcc 4701 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4702echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4703if test "${ac_cv_sys_large_files+set}" = set; then
4704 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4705else
503d2be0 4706 while :; do
f4988be7 4707 ac_cv_sys_large_files=no
503d2be0 4708 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4709/* confdefs.h. */
4710_ACEOF
4711cat confdefs.h >>conftest.$ac_ext
4712cat >>conftest.$ac_ext <<_ACEOF
4713/* end confdefs.h. */
503d2be0
AS
4714#include <sys/types.h>
4715 /* Check that off_t can represent 2**63 - 1 correctly.
4716 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4717 since some C++ compilers masquerading as C compilers
4718 incorrectly reject 9223372036854775807. */
4719#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4720 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4721 && LARGE_OFF_T % 2147483647 == 1)
4722 ? 1 : -1];
4723int
4724main ()
4725{
ba4481b5 4726
503d2be0
AS
4727 ;
4728 return 0;
4729}
4730_ACEOF
4731rm -f conftest.$ac_objext
c0d27fcc 4732if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4733 (eval $ac_compile) 2>conftest.er1
503d2be0 4734 ac_status=$?
edfaf76d
LK
4735 grep -v '^ *+' conftest.er1 >conftest.err
4736 rm -f conftest.er1
4737 cat conftest.err >&5
c0d27fcc 4738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4739 (exit $ac_status); } &&
10a3b1a1
EZ
4740 { ac_try='test -z "$ac_c_werror_flag"
4741 || test ! -s conftest.err'
edfaf76d
LK
4742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4743 (eval $ac_try) 2>&5
4744 ac_status=$?
4745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4746 (exit $ac_status); }; } &&
4747 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4749 (eval $ac_try) 2>&5
4750 ac_status=$?
c0d27fcc 4751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4752 (exit $ac_status); }; }; then
4753 break
ba4481b5 4754else
503d2be0 4755 echo "$as_me: failed program was:" >&5
19650fd6
AS
4756sed 's/^/| /' conftest.$ac_ext >&5
4757
503d2be0 4758fi
edfaf76d 4759rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4760 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4761/* confdefs.h. */
4762_ACEOF
4763cat confdefs.h >>conftest.$ac_ext
4764cat >>conftest.$ac_ext <<_ACEOF
4765/* end confdefs.h. */
f4988be7 4766#define _LARGE_FILES 1
503d2be0
AS
4767#include <sys/types.h>
4768 /* Check that off_t can represent 2**63 - 1 correctly.
4769 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4770 since some C++ compilers masquerading as C compilers
4771 incorrectly reject 9223372036854775807. */
4772#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4773 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4774 && LARGE_OFF_T % 2147483647 == 1)
4775 ? 1 : -1];
4776int
4777main ()
4778{
f4988be7 4779
503d2be0
AS
4780 ;
4781 return 0;
4782}
4783_ACEOF
4784rm -f conftest.$ac_objext
c0d27fcc 4785if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4786 (eval $ac_compile) 2>conftest.er1
503d2be0 4787 ac_status=$?
edfaf76d
LK
4788 grep -v '^ *+' conftest.er1 >conftest.err
4789 rm -f conftest.er1
4790 cat conftest.err >&5
c0d27fcc 4791 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4792 (exit $ac_status); } &&
10a3b1a1
EZ
4793 { ac_try='test -z "$ac_c_werror_flag"
4794 || test ! -s conftest.err'
edfaf76d
LK
4795 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4796 (eval $ac_try) 2>&5
4797 ac_status=$?
4798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4799 (exit $ac_status); }; } &&
4800 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4802 (eval $ac_try) 2>&5
4803 ac_status=$?
c0d27fcc 4804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4805 (exit $ac_status); }; }; then
4806 ac_cv_sys_large_files=1; break
4807else
4808 echo "$as_me: failed program was:" >&5
19650fd6
AS
4809sed 's/^/| /' conftest.$ac_ext >&5
4810
503d2be0 4811fi
edfaf76d 4812rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4813 break
4814done
ba4481b5 4815fi
c0d27fcc 4816echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4817echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4818if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4819
c0d27fcc 4820cat >>confdefs.h <<_ACEOF
f4988be7 4821#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4822_ACEOF
ba4481b5 4823
503d2be0
AS
4824fi
4825rm -f conftest*
4826fi
ba4481b5 4827
c0d27fcc 4828
2c9dccc9
PJ
4829if test "${with_sound}" != "no"; then
4830 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4831 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4832echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4833if test "${ac_cv_header_stdc+set}" = set; then
4834 echo $ECHO_N "(cached) $ECHO_C" >&6
4835else
4836 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4837/* confdefs.h. */
4838_ACEOF
4839cat confdefs.h >>conftest.$ac_ext
4840cat >>conftest.$ac_ext <<_ACEOF
4841/* end confdefs.h. */
c0d27fcc
MR
4842#include <stdlib.h>
4843#include <stdarg.h>
4844#include <string.h>
4845#include <float.h>
98418dba 4846
19650fd6
AS
4847int
4848main ()
4849{
4850
4851 ;
4852 return 0;
4853}
c0d27fcc 4854_ACEOF
19650fd6
AS
4855rm -f conftest.$ac_objext
4856if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 4857 (eval $ac_compile) 2>conftest.er1
cd958eb3 4858 ac_status=$?
edfaf76d
LK
4859 grep -v '^ *+' conftest.er1 >conftest.err
4860 rm -f conftest.er1
4861 cat conftest.err >&5
cd958eb3 4862 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 4863 (exit $ac_status); } &&
10a3b1a1
EZ
4864 { ac_try='test -z "$ac_c_werror_flag"
4865 || test ! -s conftest.err'
edfaf76d
LK
4866 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4867 (eval $ac_try) 2>&5
4868 ac_status=$?
4869 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4870 (exit $ac_status); }; } &&
4871 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
4872 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4873 (eval $ac_try) 2>&5
4874 ac_status=$?
4875 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4876 (exit $ac_status); }; }; then
c0d27fcc
MR
4877 ac_cv_header_stdc=yes
4878else
4879 echo "$as_me: failed program was:" >&5
19650fd6
AS
4880sed 's/^/| /' conftest.$ac_ext >&5
4881
4882ac_cv_header_stdc=no
c0d27fcc 4883fi
edfaf76d 4884rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4885
4886if test $ac_cv_header_stdc = yes; then
4887 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4888 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4889/* confdefs.h. */
4890_ACEOF
4891cat confdefs.h >>conftest.$ac_ext
4892cat >>conftest.$ac_ext <<_ACEOF
4893/* end confdefs.h. */
c0d27fcc
MR
4894#include <string.h>
4895
4896_ACEOF
4897if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4898 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4899 :
4900else
4901 ac_cv_header_stdc=no
4902fi
4903rm -f conftest*
4904
4905fi
4906
4907if test $ac_cv_header_stdc = yes; then
4908 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4909 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4910/* confdefs.h. */
4911_ACEOF
4912cat confdefs.h >>conftest.$ac_ext
4913cat >>conftest.$ac_ext <<_ACEOF
4914/* end confdefs.h. */
c0d27fcc
MR
4915#include <stdlib.h>
4916
4917_ACEOF
4918if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4919 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4920 :
4921else
4922 ac_cv_header_stdc=no
4923fi
4924rm -f conftest*
4925
4926fi
4927
4928if test $ac_cv_header_stdc = yes; then
4929 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4930 if test "$cross_compiling" = yes; then
4931 :
4932else
4933 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4934/* confdefs.h. */
4935_ACEOF
4936cat confdefs.h >>conftest.$ac_ext
4937cat >>conftest.$ac_ext <<_ACEOF
4938/* end confdefs.h. */
c0d27fcc
MR
4939#include <ctype.h>
4940#if ((' ' & 0x0FF) == 0x020)
4941# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4942# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4943#else
19650fd6 4944# define ISLOWER(c) \
edfaf76d
LK
4945 (('a' <= (c) && (c) <= 'i') \
4946 || ('j' <= (c) && (c) <= 'r') \
4947 || ('s' <= (c) && (c) <= 'z'))
c0d27fcc
MR
4948# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4949#endif
4950
4951#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4952int
4953main ()
4954{
4955 int i;
4956 for (i = 0; i < 256; i++)
4957 if (XOR (islower (i), ISLOWER (i))
edfaf76d 4958 || toupper (i) != TOUPPER (i))
c0d27fcc
MR
4959 exit(2);
4960 exit (0);
4961}
4962_ACEOF
4963rm -f conftest$ac_exeext
4964if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4965 (eval $ac_link) 2>&5
4966 ac_status=$?
4967 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4968 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
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 :
4975else
4976 echo "$as_me: program exited with status $ac_status" >&5
4977echo "$as_me: failed program was:" >&5
19650fd6
AS
4978sed 's/^/| /' conftest.$ac_ext >&5
4979
c0d27fcc
MR
4980( exit $ac_status )
4981ac_cv_header_stdc=no
4982fi
edfaf76d 4983rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4984fi
4985fi
4986fi
4987echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4988echo "${ECHO_T}$ac_cv_header_stdc" >&6
4989if test $ac_cv_header_stdc = yes; then
4990
4991cat >>confdefs.h <<\_ACEOF
4992#define STDC_HEADERS 1
4993_ACEOF
4994
4995fi
4996
4997# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
edfaf76d 5008 inttypes.h stdint.h unistd.h
98418dba
CW
5009do
5010as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 5011echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5012echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5013if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5014 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5015else
925c2f3f 5016 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5017/* confdefs.h. */
5018_ACEOF
5019cat confdefs.h >>conftest.$ac_ext
5020cat >>conftest.$ac_ext <<_ACEOF
5021/* end confdefs.h. */
c0d27fcc
MR
5022$ac_includes_default
5023
5024#include <$ac_header>
5025_ACEOF
5026rm -f conftest.$ac_objext
5027if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5028 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5029 ac_status=$?
edfaf76d
LK
5030 grep -v '^ *+' conftest.er1 >conftest.err
5031 rm -f conftest.er1
5032 cat conftest.err >&5
c0d27fcc
MR
5033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5034 (exit $ac_status); } &&
10a3b1a1
EZ
5035 { ac_try='test -z "$ac_c_werror_flag"
5036 || test ! -s conftest.err'
edfaf76d
LK
5037 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5038 (eval $ac_try) 2>&5
5039 ac_status=$?
5040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5041 (exit $ac_status); }; } &&
5042 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5043 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5044 (eval $ac_try) 2>&5
5045 ac_status=$?
5046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5047 (exit $ac_status); }; }; then
5048 eval "$as_ac_Header=yes"
5049else
5050 echo "$as_me: failed program was:" >&5
19650fd6
AS
5051sed 's/^/| /' conftest.$ac_ext >&5
5052
c0d27fcc
MR
5053eval "$as_ac_Header=no"
5054fi
edfaf76d 5055rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5056fi
5057echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5058echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5059if test `eval echo '${'$as_ac_Header'}'` = yes; then
5060 cat >>confdefs.h <<_ACEOF
5061#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5062_ACEOF
5063
5064fi
5065
5066done
5067
5068
5069
5070
5071
5072for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
5073do
5074as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5075if eval "test \"\${$as_ac_Header+set}\" = set"; then
5076 echo "$as_me:$LINENO: checking for $ac_header" >&5
5077echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5078if eval "test \"\${$as_ac_Header+set}\" = set"; then
5079 echo $ECHO_N "(cached) $ECHO_C" >&6
5080fi
5081echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5082echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5083else
5084 # Is the header compilable?
5085echo "$as_me:$LINENO: checking $ac_header usability" >&5
5086echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5087cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5088/* confdefs.h. */
5089_ACEOF
5090cat confdefs.h >>conftest.$ac_ext
5091cat >>conftest.$ac_ext <<_ACEOF
5092/* end confdefs.h. */
c0d27fcc 5093$ac_includes_default
98418dba 5094#include <$ac_header>
503d2be0 5095_ACEOF
c0d27fcc
MR
5096rm -f conftest.$ac_objext
5097if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5098 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5099 ac_status=$?
edfaf76d
LK
5100 grep -v '^ *+' conftest.er1 >conftest.err
5101 rm -f conftest.er1
5102 cat conftest.err >&5
c0d27fcc
MR
5103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5104 (exit $ac_status); } &&
10a3b1a1
EZ
5105 { ac_try='test -z "$ac_c_werror_flag"
5106 || test ! -s conftest.err'
edfaf76d
LK
5107 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5108 (eval $ac_try) 2>&5
5109 ac_status=$?
5110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5111 (exit $ac_status); }; } &&
5112 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5113 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5114 (eval $ac_try) 2>&5
5115 ac_status=$?
5116 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5117 (exit $ac_status); }; }; then
5118 ac_header_compiler=yes
5119else
5120 echo "$as_me: failed program was:" >&5
19650fd6
AS
5121sed 's/^/| /' conftest.$ac_ext >&5
5122
c0d27fcc
MR
5123ac_header_compiler=no
5124fi
edfaf76d 5125rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5126echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5127echo "${ECHO_T}$ac_header_compiler" >&6
5128
5129# Is the header present?
5130echo "$as_me:$LINENO: checking $ac_header presence" >&5
5131echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5132cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5133/* confdefs.h. */
5134_ACEOF
5135cat confdefs.h >>conftest.$ac_ext
5136cat >>conftest.$ac_ext <<_ACEOF
5137/* end confdefs.h. */
c0d27fcc
MR
5138#include <$ac_header>
5139_ACEOF
5140if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5141 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5142 ac_status=$?
6bae0ccf 5143 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5144 rm -f conftest.er1
5145 cat conftest.err >&5
c0d27fcc 5146 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5147 (exit $ac_status); } >/dev/null; then
5148 if test -s conftest.err; then
5149 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 5150 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5151 else
5152 ac_cpp_err=
5153 fi
5154else
5155 ac_cpp_err=yes
5156fi
5157if test -z "$ac_cpp_err"; then
c0d27fcc 5158 ac_header_preproc=yes
f4988be7 5159else
503d2be0 5160 echo "$as_me: failed program was:" >&5
19650fd6
AS
5161sed 's/^/| /' conftest.$ac_ext >&5
5162
c0d27fcc 5163 ac_header_preproc=no
f4988be7 5164fi
98418dba 5165rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5166echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5167echo "${ECHO_T}$ac_header_preproc" >&6
5168
5169# So? What about this header?
edfaf76d
LK
5170case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5171 yes:no: )
c0d27fcc
MR
5172 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5173echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
5174 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5175echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5176 ac_header_preproc=yes
19650fd6 5177 ;;
edfaf76d 5178 no:yes:* )
c0d27fcc
MR
5179 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5180echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
5181 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5182echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5183 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5184echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5185 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5186echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5187 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5188echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
5189 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5190echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5191 (
5192 cat <<\_ASBOX
edfaf76d
LK
5193## ------------------------------------------ ##
5194## Report this to the AC_PACKAGE_NAME lists. ##
5195## ------------------------------------------ ##
19650fd6
AS
5196_ASBOX
5197 ) |
5198 sed "s/^/$as_me: WARNING: /" >&2
5199 ;;
c0d27fcc
MR
5200esac
5201echo "$as_me:$LINENO: checking for $ac_header" >&5
5202echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5203if eval "test \"\${$as_ac_Header+set}\" = set"; then
5204 echo $ECHO_N "(cached) $ECHO_C" >&6
5205else
edfaf76d 5206 eval "$as_ac_Header=\$ac_header_preproc"
f4988be7 5207fi
c0d27fcc 5208echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5209echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5210
5211fi
98418dba 5212if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5213 cat >>confdefs.h <<_ACEOF
98418dba 5214#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5215_ACEOF
f4988be7
GM
5216
5217fi
c0d27fcc 5218
98418dba
CW
5219done
5220
5221 # Emulation library used on NetBSD.
c0d27fcc 5222 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
5223echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
5224if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 5225 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5226else
98418dba
CW
5227 ac_check_lib_save_LIBS=$LIBS
5228LIBS="-lossaudio $LIBS"
5229cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5230/* confdefs.h. */
5231_ACEOF
5232cat confdefs.h >>conftest.$ac_ext
5233cat >>conftest.$ac_ext <<_ACEOF
5234/* end confdefs.h. */
98418dba
CW
5235
5236/* Override any gcc2 internal prototype to avoid an error. */
5237#ifdef __cplusplus
5238extern "C"
f4988be7 5239#endif
98418dba
CW
5240/* We use char because int might match the return type of a gcc2
5241 builtin and then its argument prototype would still apply. */
5242char _oss_ioctl ();
503d2be0
AS
5243int
5244main ()
5245{
98418dba 5246_oss_ioctl ();
503d2be0
AS
5247 ;
5248 return 0;
5249}
5250_ACEOF
98418dba 5251rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 5252if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 5253 (eval $ac_link) 2>conftest.er1
503d2be0 5254 ac_status=$?
edfaf76d
LK
5255 grep -v '^ *+' conftest.er1 >conftest.err
5256 rm -f conftest.er1
5257 cat conftest.err >&5
c0d27fcc 5258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5259 (exit $ac_status); } &&
10a3b1a1
EZ
5260 { ac_try='test -z "$ac_c_werror_flag"
5261 || test ! -s conftest.err'
edfaf76d
LK
5262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5263 (eval $ac_try) 2>&5
5264 ac_status=$?
5265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5266 (exit $ac_status); }; } &&
5267 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 5268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5269 (eval $ac_try) 2>&5
5270 ac_status=$?
c0d27fcc 5271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5272 (exit $ac_status); }; }; then
98418dba 5273 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 5274else
503d2be0 5275 echo "$as_me: failed program was:" >&5
19650fd6
AS
5276sed 's/^/| /' conftest.$ac_ext >&5
5277
98418dba 5278ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 5279fi
edfaf76d
LK
5280rm -f conftest.err conftest.$ac_objext \
5281 conftest$ac_exeext conftest.$ac_ext
98418dba 5282LIBS=$ac_check_lib_save_LIBS
f4988be7 5283fi
c0d27fcc 5284echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
5285echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5286if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5287 LIBSOUND=-lossaudio
5288else
5289 LIBSOUND=
5290fi
5291
c0d27fcc 5292
f4988be7 5293fi
c0d27fcc
MR
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
22044edf
DL
5312
5313
973a76b1 5314
cffcede7 5315
551ffc27 5316
226e2359 5317
c0d27fcc 5318
f4988be7 5319
98418dba
CW
5320for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5321 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
25ca0bca 5322 termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
551ffc27 5323 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
226e2359 5324 sys/utsname.h pwd.h
98418dba
CW
5325do
5326as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5327if eval "test \"\${$as_ac_Header+set}\" = set"; then
5328 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5329echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5330if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5331 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5332fi
5333echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5334echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5335else
c0d27fcc
MR
5336 # Is the header compilable?
5337echo "$as_me:$LINENO: checking $ac_header usability" >&5
5338echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5339cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5340/* confdefs.h. */
5341_ACEOF
5342cat confdefs.h >>conftest.$ac_ext
5343cat >>conftest.$ac_ext <<_ACEOF
5344/* end confdefs.h. */
c0d27fcc
MR
5345$ac_includes_default
5346#include <$ac_header>
5347_ACEOF
5348rm -f conftest.$ac_objext
5349if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5350 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5351 ac_status=$?
edfaf76d
LK
5352 grep -v '^ *+' conftest.er1 >conftest.err
5353 rm -f conftest.er1
5354 cat conftest.err >&5
c0d27fcc
MR
5355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5356 (exit $ac_status); } &&
10a3b1a1
EZ
5357 { ac_try='test -z "$ac_c_werror_flag"
5358 || test ! -s conftest.err'
edfaf76d
LK
5359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5360 (eval $ac_try) 2>&5
5361 ac_status=$?
5362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5363 (exit $ac_status); }; } &&
5364 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5366 (eval $ac_try) 2>&5
5367 ac_status=$?
5368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5369 (exit $ac_status); }; }; then
5370 ac_header_compiler=yes
5371else
5372 echo "$as_me: failed program was:" >&5
19650fd6
AS
5373sed 's/^/| /' conftest.$ac_ext >&5
5374
c0d27fcc
MR
5375ac_header_compiler=no
5376fi
edfaf76d 5377rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5378echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5379echo "${ECHO_T}$ac_header_compiler" >&6
5380
5381# Is the header present?
5382echo "$as_me:$LINENO: checking $ac_header presence" >&5
5383echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5384cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5385/* confdefs.h. */
5386_ACEOF
5387cat confdefs.h >>conftest.$ac_ext
5388cat >>conftest.$ac_ext <<_ACEOF
5389/* end confdefs.h. */
98418dba 5390#include <$ac_header>
503d2be0 5391_ACEOF
c0d27fcc 5392if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5393 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5394 ac_status=$?
6bae0ccf 5395 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5396 rm -f conftest.er1
5397 cat conftest.err >&5
c0d27fcc 5398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5399 (exit $ac_status); } >/dev/null; then
5400 if test -s conftest.err; then
5401 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 5402 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5403 else
5404 ac_cpp_err=
5405 fi
5406else
5407 ac_cpp_err=yes
5408fi
5409if test -z "$ac_cpp_err"; then
c0d27fcc 5410 ac_header_preproc=yes
34ec9ebe 5411else
503d2be0 5412 echo "$as_me: failed program was:" >&5
19650fd6
AS
5413sed 's/^/| /' conftest.$ac_ext >&5
5414
c0d27fcc 5415 ac_header_preproc=no
34ec9ebe 5416fi
98418dba 5417rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5418echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5419echo "${ECHO_T}$ac_header_preproc" >&6
5420
5421# So? What about this header?
edfaf76d
LK
5422case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5423 yes:no: )
c0d27fcc
MR
5424 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5425echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
5426 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5427echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5428 ac_header_preproc=yes
19650fd6 5429 ;;
edfaf76d 5430 no:yes:* )
c0d27fcc
MR
5431 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5432echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
5433 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5434echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5435 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5436echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5437 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5438echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5439 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5440echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
5441 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5442echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5443 (
5444 cat <<\_ASBOX
edfaf76d
LK
5445## ------------------------------------------ ##
5446## Report this to the AC_PACKAGE_NAME lists. ##
5447## ------------------------------------------ ##
19650fd6
AS
5448_ASBOX
5449 ) |
5450 sed "s/^/$as_me: WARNING: /" >&2
5451 ;;
c0d27fcc
MR
5452esac
5453echo "$as_me:$LINENO: checking for $ac_header" >&5
5454echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5455if eval "test \"\${$as_ac_Header+set}\" = set"; then
5456 echo $ECHO_N "(cached) $ECHO_C" >&6
5457else
edfaf76d 5458 eval "$as_ac_Header=\$ac_header_preproc"
34ec9ebe 5459fi
c0d27fcc 5460echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5461echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5462
5463fi
98418dba 5464if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5465 cat >>confdefs.h <<_ACEOF
98418dba 5466#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5467_ACEOF
34ec9ebe 5468
98418dba 5469fi
c0d27fcc 5470
98418dba
CW
5471done
5472
22044edf 5473
f17e308a
JD
5474echo "$as_me:$LINENO: checking if personality LINUX32 can be set" >&5
5475echo $ECHO_N "checking if personality LINUX32 can be set... $ECHO_C" >&6
5476cat >conftest.$ac_ext <<_ACEOF
5477/* confdefs.h. */
5478_ACEOF
5479cat confdefs.h >>conftest.$ac_ext
5480cat >>conftest.$ac_ext <<_ACEOF
5481/* end confdefs.h. */
5482#include <sys/personality.h>
5483int
5484main ()
5485{
5486personality (PER_LINUX32)
5487 ;
5488 return 0;
5489}
5490_ACEOF
5491rm -f conftest.$ac_objext
5492if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5493 (eval $ac_compile) 2>conftest.er1
f17e308a 5494 ac_status=$?
edfaf76d
LK
5495 grep -v '^ *+' conftest.er1 >conftest.err
5496 rm -f conftest.er1
5497 cat conftest.err >&5
f17e308a
JD
5498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5499 (exit $ac_status); } &&
10a3b1a1
EZ
5500 { ac_try='test -z "$ac_c_werror_flag"
5501 || test ! -s conftest.err'
edfaf76d
LK
5502 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5503 (eval $ac_try) 2>&5
5504 ac_status=$?
5505 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5506 (exit $ac_status); }; } &&
5507 { ac_try='test -s conftest.$ac_objext'
f17e308a
JD
5508 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5509 (eval $ac_try) 2>&5
5510 ac_status=$?
5511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5512 (exit $ac_status); }; }; then
5513 emacs_cv_personality_linux32=yes
5514else
5515 echo "$as_me: failed program was:" >&5
5516sed 's/^/| /' conftest.$ac_ext >&5
5517
5518emacs_cv_personality_linux32=no
5519fi
edfaf76d 5520rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
f17e308a
JD
5521echo "$as_me:$LINENO: result: $emacs_cv_personality_linux32" >&5
5522echo "${ECHO_T}$emacs_cv_personality_linux32" >&6
5523
5524if test $emacs_cv_personality_linux32 = yes; then
5525
5526cat >>confdefs.h <<\_ACEOF
5527#define HAVE_PERSONALITY_LINUX32 1
5528_ACEOF
5529
5530fi
5531
5532
22044edf
DL
5533for ac_header in term.h
5534do
5535as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5536echo "$as_me:$LINENO: checking for $ac_header" >&5
5537echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5538if eval "test \"\${$as_ac_Header+set}\" = set"; then
5539 echo $ECHO_N "(cached) $ECHO_C" >&6
5540else
5541 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5542/* confdefs.h. */
5543_ACEOF
5544cat confdefs.h >>conftest.$ac_ext
5545cat >>conftest.$ac_ext <<_ACEOF
5546/* end confdefs.h. */
22044edf
DL
5547#include <$ac_header>
5548_ACEOF
5549if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5550 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5551 ac_status=$?
5552 grep -v '^ *+' conftest.er1 >conftest.err
5553 rm -f conftest.er1
5554 cat conftest.err >&5
5555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5556 (exit $ac_status); } >/dev/null; then
5557 if test -s conftest.err; then
5558 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 5559 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22044edf
DL
5560 else
5561 ac_cpp_err=
5562 fi
5563else
5564 ac_cpp_err=yes
5565fi
5566if test -z "$ac_cpp_err"; then
5567 eval "$as_ac_Header=yes"
5568else
5569 echo "$as_me: failed program was:" >&5
19650fd6
AS
5570sed 's/^/| /' conftest.$ac_ext >&5
5571
22044edf
DL
5572 eval "$as_ac_Header=no"
5573fi
5574rm -f conftest.err conftest.$ac_ext
5575fi
5576echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5577echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5578if test `eval echo '${'$as_ac_Header'}'` = yes; then
5579 cat >>confdefs.h <<_ACEOF
5580#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5581_ACEOF
5582
5583fi
5584
5585done
5586
c0d27fcc 5587echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5588echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5589if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5590 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5591else
503d2be0 5592 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5593/* confdefs.h. */
5594_ACEOF
5595cat confdefs.h >>conftest.$ac_ext
5596cat >>conftest.$ac_ext <<_ACEOF
5597/* end confdefs.h. */
98418dba
CW
5598#include <stdlib.h>
5599#include <stdarg.h>
5600#include <string.h>
5601#include <float.h>
5602
19650fd6
AS
5603int
5604main ()
5605{
5606
5607 ;
5608 return 0;
5609}
98418dba 5610_ACEOF
19650fd6
AS
5611rm -f conftest.$ac_objext
5612if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5613 (eval $ac_compile) 2>conftest.er1
cd958eb3 5614 ac_status=$?
edfaf76d
LK
5615 grep -v '^ *+' conftest.er1 >conftest.err
5616 rm -f conftest.er1
5617 cat conftest.err >&5
cd958eb3 5618 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 5619 (exit $ac_status); } &&
10a3b1a1
EZ
5620 { ac_try='test -z "$ac_c_werror_flag"
5621 || test ! -s conftest.err'
edfaf76d
LK
5622 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5623 (eval $ac_try) 2>&5
5624 ac_status=$?
5625 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5626 (exit $ac_status); }; } &&
5627 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
5628 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5629 (eval $ac_try) 2>&5
5630 ac_status=$?
5631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5632 (exit $ac_status); }; }; then
98418dba 5633 ac_cv_header_stdc=yes
ba4481b5 5634else
503d2be0 5635 echo "$as_me: failed program was:" >&5
19650fd6
AS
5636sed 's/^/| /' conftest.$ac_ext >&5
5637
5638ac_cv_header_stdc=no
ba4481b5 5639fi
edfaf76d 5640rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5641
5642if test $ac_cv_header_stdc = yes; then
5643 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5644 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5645/* confdefs.h. */
5646_ACEOF
5647cat confdefs.h >>conftest.$ac_ext
5648cat >>conftest.$ac_ext <<_ACEOF
5649/* end confdefs.h. */
98418dba
CW
5650#include <string.h>
5651
5652_ACEOF
5653if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5654 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5655 :
5656else
5657 ac_cv_header_stdc=no
ba4481b5 5658fi
98418dba 5659rm -f conftest*
ba4481b5
DL
5660
5661fi
5662
98418dba
CW
5663if test $ac_cv_header_stdc = yes; then
5664 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5665 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5666/* confdefs.h. */
5667_ACEOF
5668cat confdefs.h >>conftest.$ac_ext
5669cat >>conftest.$ac_ext <<_ACEOF
5670/* end confdefs.h. */
98418dba
CW
5671#include <stdlib.h>
5672
5673_ACEOF
5674if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5675 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5676 :
5677else
5678 ac_cv_header_stdc=no
5679fi
5680rm -f conftest*
5681
5682fi
5683
5684if test $ac_cv_header_stdc = yes; then
5685 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5686 if test "$cross_compiling" = yes; then
5687 :
d42122a3 5688else
503d2be0 5689 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5690/* confdefs.h. */
5691_ACEOF
5692cat confdefs.h >>conftest.$ac_ext
5693cat >>conftest.$ac_ext <<_ACEOF
5694/* end confdefs.h. */
98418dba
CW
5695#include <ctype.h>
5696#if ((' ' & 0x0FF) == 0x020)
5697# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5698# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5699#else
19650fd6 5700# define ISLOWER(c) \
edfaf76d
LK
5701 (('a' <= (c) && (c) <= 'i') \
5702 || ('j' <= (c) && (c) <= 'r') \
5703 || ('s' <= (c) && (c) <= 'z'))
98418dba
CW
5704# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5705#endif
5706
5707#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5708int
5709main ()
5710{
98418dba
CW
5711 int i;
5712 for (i = 0; i < 256; i++)
5713 if (XOR (islower (i), ISLOWER (i))
edfaf76d 5714 || toupper (i) != TOUPPER (i))
98418dba
CW
5715 exit(2);
5716 exit (0);
503d2be0
AS
5717}
5718_ACEOF
98418dba 5719rm -f conftest$ac_exeext
c0d27fcc 5720if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5721 (eval $ac_link) 2>&5
503d2be0 5722 ac_status=$?
c0d27fcc 5723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5724 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5725 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5726 (eval $ac_try) 2>&5
5727 ac_status=$?
c0d27fcc 5728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5729 (exit $ac_status); }; }; then
98418dba 5730 :
d42122a3 5731else
98418dba
CW
5732 echo "$as_me: program exited with status $ac_status" >&5
5733echo "$as_me: failed program was:" >&5
19650fd6
AS
5734sed 's/^/| /' conftest.$ac_ext >&5
5735
c0d27fcc 5736( exit $ac_status )
98418dba 5737ac_cv_header_stdc=no
d42122a3 5738fi
edfaf76d 5739rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5740fi
98418dba
CW
5741fi
5742fi
c0d27fcc 5743echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5744echo "${ECHO_T}$ac_cv_header_stdc" >&6
5745if test $ac_cv_header_stdc = yes; then
5746
c0d27fcc 5747cat >>confdefs.h <<\_ACEOF
98418dba 5748#define STDC_HEADERS 1
c0d27fcc 5749_ACEOF
d42122a3
DL
5750
5751fi
5752
c0d27fcc 5753echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5754echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5755if test "${ac_cv_header_time+set}" = set; then
503d2be0 5756 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5757else
503d2be0 5758 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5759/* confdefs.h. */
5760_ACEOF
5761cat confdefs.h >>conftest.$ac_ext
5762cat >>conftest.$ac_ext <<_ACEOF
5763/* end confdefs.h. */
ba4481b5 5764#include <sys/types.h>
98418dba 5765#include <sys/time.h>
ba4481b5 5766#include <time.h>
503d2be0
AS
5767
5768int
5769main ()
5770{
98418dba
CW
5771if ((struct tm *) 0)
5772return 0;
503d2be0
AS
5773 ;
5774 return 0;
5775}
5776_ACEOF
5777rm -f conftest.$ac_objext
c0d27fcc 5778if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5779 (eval $ac_compile) 2>conftest.er1
503d2be0 5780 ac_status=$?
edfaf76d
LK
5781 grep -v '^ *+' conftest.er1 >conftest.err
5782 rm -f conftest.er1
5783 cat conftest.err >&5
c0d27fcc 5784 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5785 (exit $ac_status); } &&
10a3b1a1
EZ
5786 { ac_try='test -z "$ac_c_werror_flag"
5787 || test ! -s conftest.err'
edfaf76d
LK
5788 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5789 (eval $ac_try) 2>&5
5790 ac_status=$?
5791 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5792 (exit $ac_status); }; } &&
5793 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5794 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5795 (eval $ac_try) 2>&5
5796 ac_status=$?
c0d27fcc 5797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5798 (exit $ac_status); }; }; then
98418dba 5799 ac_cv_header_time=yes
ba4481b5 5800else
503d2be0 5801 echo "$as_me: failed program was:" >&5
19650fd6
AS
5802sed 's/^/| /' conftest.$ac_ext >&5
5803
98418dba 5804ac_cv_header_time=no
ba4481b5 5805fi
edfaf76d 5806rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5807fi
c0d27fcc 5808echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5809echo "${ECHO_T}$ac_cv_header_time" >&6
5810if test $ac_cv_header_time = yes; then
503d2be0 5811
c0d27fcc 5812cat >>confdefs.h <<\_ACEOF
98418dba 5813#define TIME_WITH_SYS_TIME 1
c0d27fcc 5814_ACEOF
ba4481b5
DL
5815
5816fi
5817
cd958eb3
MB
5818echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5819echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5820if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5821 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5822else
503d2be0 5823 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5824/* confdefs.h. */
5825_ACEOF
5826cat confdefs.h >>conftest.$ac_ext
5827cat >>conftest.$ac_ext <<_ACEOF
5828/* end confdefs.h. */
cd958eb3
MB
5829$ac_includes_default
5830int
5831main ()
5832{
5833#ifndef sys_siglist
5834 char *p = (char *) sys_siglist;
98418dba 5835#endif
503d2be0 5836
cd958eb3
MB
5837 ;
5838 return 0;
5839}
5840_ACEOF
5841rm -f conftest.$ac_objext
5842if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5843 (eval $ac_compile) 2>conftest.er1
cd958eb3 5844 ac_status=$?
edfaf76d
LK
5845 grep -v '^ *+' conftest.er1 >conftest.err
5846 rm -f conftest.er1
5847 cat conftest.err >&5
cd958eb3
MB
5848 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5849 (exit $ac_status); } &&
10a3b1a1
EZ
5850 { ac_try='test -z "$ac_c_werror_flag"
5851 || test ! -s conftest.err'
edfaf76d
LK
5852 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5853 (eval $ac_try) 2>&5
5854 ac_status=$?
5855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5856 (exit $ac_status); }; } &&
5857 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
5858 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5859 (eval $ac_try) 2>&5
5860 ac_status=$?
5861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5862 (exit $ac_status); }; }; then
5863 ac_cv_have_decl_sys_siglist=yes
5864else
5865 echo "$as_me: failed program was:" >&5
19650fd6
AS
5866sed 's/^/| /' conftest.$ac_ext >&5
5867
cd958eb3
MB
5868ac_cv_have_decl_sys_siglist=no
5869fi
edfaf76d 5870rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
5871fi
5872echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5873echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5874if test $ac_cv_have_decl_sys_siglist = yes; then
5875
5876cat >>confdefs.h <<_ACEOF
5877#define HAVE_DECL_SYS_SIGLIST 1
5878_ACEOF
5879
5880
5881else
5882 cat >>confdefs.h <<_ACEOF
5883#define HAVE_DECL_SYS_SIGLIST 0
5884_ACEOF
5885
5886
5887fi
5888
5889
5890if test $ac_cv_have_decl_sys_siglist != yes; then
5891 # For Tru64, at least:
5892 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5893echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5894if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5895 echo $ECHO_N "(cached) $ECHO_C" >&6
5896else
5897 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5898/* confdefs.h. */
5899_ACEOF
5900cat confdefs.h >>conftest.$ac_ext
5901cat >>conftest.$ac_ext <<_ACEOF
5902/* end confdefs.h. */
cd958eb3 5903$ac_includes_default
503d2be0
AS
5904int
5905main ()
5906{
cd958eb3
MB
5907#ifndef __sys_siglist
5908 char *p = (char *) __sys_siglist;
5909#endif
5910
503d2be0
AS
5911 ;
5912 return 0;
5913}
5914_ACEOF
5915rm -f conftest.$ac_objext
c0d27fcc 5916if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 5917 (eval $ac_compile) 2>conftest.er1
503d2be0 5918 ac_status=$?
edfaf76d
LK
5919 grep -v '^ *+' conftest.er1 >conftest.err
5920 rm -f conftest.er1
5921 cat conftest.err >&5
c0d27fcc 5922 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5923 (exit $ac_status); } &&
10a3b1a1
EZ
5924 { ac_try='test -z "$ac_c_werror_flag"
5925 || test ! -s conftest.err'
edfaf76d
LK
5926 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5927 (eval $ac_try) 2>&5
5928 ac_status=$?
5929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5930 (exit $ac_status); }; } &&
5931 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5932 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5933 (eval $ac_try) 2>&5
5934 ac_status=$?
c0d27fcc 5935 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5936 (exit $ac_status); }; }; then
cd958eb3 5937 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5938else
503d2be0 5939 echo "$as_me: failed program was:" >&5
19650fd6
AS
5940sed 's/^/| /' conftest.$ac_ext >&5
5941
cd958eb3 5942ac_cv_have_decl___sys_siglist=no
ba4481b5 5943fi
edfaf76d 5944rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 5945fi
cd958eb3
MB
5946echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5947echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5948if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5949
cd958eb3
MB
5950cat >>confdefs.h <<_ACEOF
5951#define HAVE_DECL___SYS_SIGLIST 1
5952_ACEOF
5953
5954
5955else
5956 cat >>confdefs.h <<_ACEOF
5957#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5958_ACEOF
503d2be0 5959
cd958eb3 5960
ba4481b5
DL
5961fi
5962
cd958eb3
MB
5963
5964 if test $ac_cv_have_decl___sys_siglist = yes; then
5965
5966cat >>confdefs.h <<\_ACEOF
5967#define sys_siglist __sys_siglist
5968_ACEOF
5969
5970 fi
5971fi
c0d27fcc 5972echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5973echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5974if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5975 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5976else
503d2be0 5977 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5978/* confdefs.h. */
5979_ACEOF
5980cat confdefs.h >>conftest.$ac_ext
5981cat >>conftest.$ac_ext <<_ACEOF
5982/* end confdefs.h. */
98418dba
CW
5983#include <sys/types.h>
5984#include <sys/wait.h>
5985#ifndef WEXITSTATUS
5986# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5987#endif
5988#ifndef WIFEXITED
5989# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5990#endif
503d2be0
AS
5991
5992int
5993main ()
5994{
98418dba
CW
5995 int s;
5996 wait (&s);
5997 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5998 ;
5999 return 0;
6000}
6001_ACEOF
98418dba 6002rm -f conftest.$ac_objext
c0d27fcc 6003if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6004 (eval $ac_compile) 2>conftest.er1
503d2be0 6005 ac_status=$?
edfaf76d
LK
6006 grep -v '^ *+' conftest.er1 >conftest.err
6007 rm -f conftest.er1
6008 cat conftest.err >&5
c0d27fcc 6009 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6010 (exit $ac_status); } &&
10a3b1a1
EZ
6011 { ac_try='test -z "$ac_c_werror_flag"
6012 || test ! -s conftest.err'
edfaf76d
LK
6013 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6014 (eval $ac_try) 2>&5
6015 ac_status=$?
6016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6017 (exit $ac_status); }; } &&
6018 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6019 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6020 (eval $ac_try) 2>&5
6021 ac_status=$?
c0d27fcc 6022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6023 (exit $ac_status); }; }; then
98418dba 6024 ac_cv_header_sys_wait_h=yes
ba4481b5 6025else
503d2be0 6026 echo "$as_me: failed program was:" >&5
19650fd6
AS
6027sed 's/^/| /' conftest.$ac_ext >&5
6028
98418dba 6029ac_cv_header_sys_wait_h=no
ba4481b5 6030fi
edfaf76d 6031rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6032fi
c0d27fcc 6033echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
6034echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
6035if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 6036
c0d27fcc 6037cat >>confdefs.h <<\_ACEOF
98418dba 6038#define HAVE_SYS_WAIT_H 1
c0d27fcc 6039_ACEOF
ba4481b5 6040
ba4481b5
DL
6041fi
6042
c0d27fcc
MR
6043
6044echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
6045echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
6046if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 6047 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 6048else
503d2be0 6049 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6050/* confdefs.h. */
6051_ACEOF
6052cat confdefs.h >>conftest.$ac_ext
6053cat >>conftest.$ac_ext <<_ACEOF
6054/* end confdefs.h. */
98418dba
CW
6055#ifdef TIME_WITH_SYS_TIME
6056#include <sys/time.h>
6057#include <time.h>
6058#else
6059#ifdef HAVE_SYS_TIME_H
6060#include <sys/time.h>
6061#else
1113b624 6062#include <time.h>
98418dba
CW
6063#endif
6064#endif
6065#ifdef HAVE_UTIME_H
6066#include <utime.h>
6067#endif
503d2be0
AS
6068int
6069main ()
6070{
98418dba 6071static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
6072 ;
6073 return 0;
6074}
6075_ACEOF
98418dba 6076rm -f conftest.$ac_objext
c0d27fcc 6077if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6078 (eval $ac_compile) 2>conftest.er1
503d2be0 6079 ac_status=$?
edfaf76d
LK
6080 grep -v '^ *+' conftest.er1 >conftest.err
6081 rm -f conftest.er1
6082 cat conftest.err >&5
c0d27fcc 6083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6084 (exit $ac_status); } &&
10a3b1a1
EZ
6085 { ac_try='test -z "$ac_c_werror_flag"
6086 || test ! -s conftest.err'
edfaf76d
LK
6087 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6088 (eval $ac_try) 2>&5
6089 ac_status=$?
6090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6091 (exit $ac_status); }; } &&
6092 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6094 (eval $ac_try) 2>&5
6095 ac_status=$?
c0d27fcc 6096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6097 (exit $ac_status); }; }; then
98418dba 6098 emacs_cv_struct_utimbuf=yes
1113b624 6099else
503d2be0 6100 echo "$as_me: failed program was:" >&5
19650fd6
AS
6101sed 's/^/| /' conftest.$ac_ext >&5
6102
98418dba 6103emacs_cv_struct_utimbuf=no
1113b624 6104fi
edfaf76d 6105rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1113b624 6106fi
c0d27fcc 6107echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
6108echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
6109if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 6110
c0d27fcc 6111cat >>confdefs.h <<\_ACEOF
98418dba 6112#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 6113_ACEOF
1113b624
PE
6114
6115fi
ba4481b5 6116
c0d27fcc 6117echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
6118echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
6119if test "${ac_cv_type_signal+set}" = set; then
503d2be0 6120 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6121else
98418dba 6122 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6123/* confdefs.h. */
6124_ACEOF
6125cat confdefs.h >>conftest.$ac_ext
6126cat >>conftest.$ac_ext <<_ACEOF
6127/* end confdefs.h. */
7397acc4 6128#include <sys/types.h>
98418dba
CW
6129#include <signal.h>
6130#ifdef signal
6131# undef signal
6132#endif
6133#ifdef __cplusplus
6134extern "C" void (*signal (int, void (*)(int)))(int);
6135#else
6136void (*signal ()) ();
6137#endif
6138
503d2be0
AS
6139int
6140main ()
6141{
98418dba 6142int i;
503d2be0
AS
6143 ;
6144 return 0;
6145}
6146_ACEOF
98418dba 6147rm -f conftest.$ac_objext
c0d27fcc 6148if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6149 (eval $ac_compile) 2>conftest.er1
503d2be0 6150 ac_status=$?
edfaf76d
LK
6151 grep -v '^ *+' conftest.er1 >conftest.err
6152 rm -f conftest.er1
6153 cat conftest.err >&5
c0d27fcc 6154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6155 (exit $ac_status); } &&
10a3b1a1
EZ
6156 { ac_try='test -z "$ac_c_werror_flag"
6157 || test ! -s conftest.err'
edfaf76d
LK
6158 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6159 (eval $ac_try) 2>&5
6160 ac_status=$?
6161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6162 (exit $ac_status); }; } &&
6163 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6164 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6165 (eval $ac_try) 2>&5
6166 ac_status=$?
c0d27fcc 6167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6168 (exit $ac_status); }; }; then
98418dba 6169 ac_cv_type_signal=void
503d2be0
AS
6170else
6171 echo "$as_me: failed program was:" >&5
19650fd6
AS
6172sed 's/^/| /' conftest.$ac_ext >&5
6173
98418dba 6174ac_cv_type_signal=int
503d2be0 6175fi
edfaf76d 6176rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6177fi
c0d27fcc 6178echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 6179echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 6180
c0d27fcc 6181cat >>confdefs.h <<_ACEOF
98418dba 6182#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
6183_ACEOF
6184
503d2be0 6185
c0d27fcc
MR
6186
6187echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
6188echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
6189if test "${emacs_cv_speed_t+set}" = set; then
6190 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6191else
98418dba 6192 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6193/* confdefs.h. */
6194_ACEOF
6195cat confdefs.h >>conftest.$ac_ext
6196cat >>conftest.$ac_ext <<_ACEOF
6197/* end confdefs.h. */
98418dba 6198#include <termios.h>
98418dba
CW
6199int
6200main ()
6201{
6202speed_t x = 1;
6203 ;
6204 return 0;
6205}
6206_ACEOF
6207rm -f conftest.$ac_objext
c0d27fcc 6208if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6209 (eval $ac_compile) 2>conftest.er1
98418dba 6210 ac_status=$?
edfaf76d
LK
6211 grep -v '^ *+' conftest.er1 >conftest.err
6212 rm -f conftest.er1
6213 cat conftest.err >&5
c0d27fcc 6214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6215 (exit $ac_status); } &&
10a3b1a1
EZ
6216 { ac_try='test -z "$ac_c_werror_flag"
6217 || test ! -s conftest.err'
edfaf76d
LK
6218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6219 (eval $ac_try) 2>&5
6220 ac_status=$?
6221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6222 (exit $ac_status); }; } &&
6223 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6225 (eval $ac_try) 2>&5
6226 ac_status=$?
c0d27fcc 6227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6228 (exit $ac_status); }; }; then
6229 emacs_cv_speed_t=yes
6230else
6231 echo "$as_me: failed program was:" >&5
19650fd6
AS
6232sed 's/^/| /' conftest.$ac_ext >&5
6233
98418dba
CW
6234emacs_cv_speed_t=no
6235fi
edfaf76d 6236rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 6237fi
c0d27fcc 6238echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
6239echo "${ECHO_T}$emacs_cv_speed_t" >&6
6240if test $emacs_cv_speed_t = yes; then
b936fae4 6241
c0d27fcc 6242cat >>confdefs.h <<\_ACEOF
98418dba 6243#define HAVE_SPEED_T 1
c0d27fcc 6244_ACEOF
98418dba 6245
7397acc4
DL
6246fi
6247
c0d27fcc 6248echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
6249echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
6250if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 6251 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6252else
503d2be0 6253 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6254/* confdefs.h. */
6255_ACEOF
6256cat confdefs.h >>conftest.$ac_ext
6257cat >>conftest.$ac_ext <<_ACEOF
6258/* end confdefs.h. */
98418dba
CW
6259#ifdef TIME_WITH_SYS_TIME
6260#include <sys/time.h>
6261#include <time.h>
6262#else
6263#ifdef HAVE_SYS_TIME_H
6264#include <sys/time.h>
6265#else
6266#include <time.h>
6267#endif
6268#endif
503d2be0
AS
6269int
6270main ()
6271{
98418dba 6272static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
6273 ;
6274 return 0;
6275}
6276_ACEOF
6277rm -f conftest.$ac_objext
c0d27fcc 6278if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6279 (eval $ac_compile) 2>conftest.er1
503d2be0 6280 ac_status=$?
edfaf76d
LK
6281 grep -v '^ *+' conftest.er1 >conftest.err
6282 rm -f conftest.er1
6283 cat conftest.err >&5
c0d27fcc 6284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6285 (exit $ac_status); } &&
10a3b1a1
EZ
6286 { ac_try='test -z "$ac_c_werror_flag"
6287 || test ! -s conftest.err'
c0d27fcc 6288 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6289 (eval $ac_try) 2>&5
6290 ac_status=$?
c0d27fcc 6291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
edfaf76d
LK
6292 (exit $ac_status); }; } &&
6293 { ac_try='test -s conftest.$ac_objext'
6294 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6295 (eval $ac_try) 2>&5
6296 ac_status=$?
6297 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6298 (exit $ac_status); }; }; then
6299 emacs_cv_struct_timeval=yes
6300else
503d2be0 6301 echo "$as_me: failed program was:" >&5
19650fd6
AS
6302sed 's/^/| /' conftest.$ac_ext >&5
6303
98418dba 6304emacs_cv_struct_timeval=no
7397acc4 6305fi
edfaf76d 6306rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6307fi
c0d27fcc 6308echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
6309echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
6310HAVE_TIMEVAL=$emacs_cv_struct_timeval
6311if test $emacs_cv_struct_timeval = yes; then
b936fae4 6312
c0d27fcc 6313cat >>confdefs.h <<\_ACEOF
98418dba 6314#define HAVE_TIMEVAL 1
c0d27fcc 6315_ACEOF
7397acc4
DL
6316
6317fi
6318
c0d27fcc 6319echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
6320echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
6321if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 6322 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6323else
503d2be0 6324 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6325/* confdefs.h. */
6326_ACEOF
6327cat confdefs.h >>conftest.$ac_ext
6328cat >>conftest.$ac_ext <<_ACEOF
6329/* end confdefs.h. */
98418dba 6330#include <math.h>
503d2be0
AS
6331int
6332main ()
6333{
98418dba 6334static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
6335 ;
6336 return 0;
ba4481b5 6337}
503d2be0
AS
6338_ACEOF
6339rm -f conftest.$ac_objext
c0d27fcc 6340if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6341 (eval $ac_compile) 2>conftest.er1
503d2be0 6342 ac_status=$?
edfaf76d
LK
6343 grep -v '^ *+' conftest.er1 >conftest.err
6344 rm -f conftest.er1
6345 cat conftest.err >&5
c0d27fcc 6346 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6347 (exit $ac_status); } &&
10a3b1a1
EZ
6348 { ac_try='test -z "$ac_c_werror_flag"
6349 || test ! -s conftest.err'
edfaf76d
LK
6350 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6351 (eval $ac_try) 2>&5
6352 ac_status=$?
6353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6354 (exit $ac_status); }; } &&
6355 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6356 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6357 (eval $ac_try) 2>&5
6358 ac_status=$?
c0d27fcc 6359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6360 (exit $ac_status); }; }; then
98418dba 6361 emacs_cv_struct_exception=yes
ba4481b5 6362else
503d2be0 6363 echo "$as_me: failed program was:" >&5
19650fd6
AS
6364sed 's/^/| /' conftest.$ac_ext >&5
6365
98418dba 6366emacs_cv_struct_exception=no
ba4481b5 6367fi
edfaf76d 6368rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6369fi
c0d27fcc 6370echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
6371echo "${ECHO_T}$emacs_cv_struct_exception" >&6
6372HAVE_EXCEPTION=$emacs_cv_struct_exception
6373if test $emacs_cv_struct_exception != yes; then
b936fae4 6374
c0d27fcc 6375cat >>confdefs.h <<\_ACEOF
98418dba 6376#define NO_MATHERR 1
c0d27fcc 6377_ACEOF
ba4481b5
DL
6378
6379fi
6380
7862d3a8
AS
6381
6382for ac_header in sys/socket.h
6383do
6384as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6385if eval "test \"\${$as_ac_Header+set}\" = set"; then
6386 echo "$as_me:$LINENO: checking for $ac_header" >&5
6387echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6388if eval "test \"\${$as_ac_Header+set}\" = set"; then
6389 echo $ECHO_N "(cached) $ECHO_C" >&6
6390fi
6391echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6392echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6393else
6394 # Is the header compilable?
6395echo "$as_me:$LINENO: checking $ac_header usability" >&5
6396echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6397cat >conftest.$ac_ext <<_ACEOF
6398/* confdefs.h. */
6399_ACEOF
6400cat confdefs.h >>conftest.$ac_ext
6401cat >>conftest.$ac_ext <<_ACEOF
6402/* end confdefs.h. */
6403$ac_includes_default
6404#include <$ac_header>
6405_ACEOF
6406rm -f conftest.$ac_objext
6407if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6408 (eval $ac_compile) 2>conftest.er1
7862d3a8 6409 ac_status=$?
edfaf76d
LK
6410 grep -v '^ *+' conftest.er1 >conftest.err
6411 rm -f conftest.er1
6412 cat conftest.err >&5
7862d3a8
AS
6413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6414 (exit $ac_status); } &&
10a3b1a1
EZ
6415 { ac_try='test -z "$ac_c_werror_flag"
6416 || test ! -s conftest.err'
edfaf76d
LK
6417 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6418 (eval $ac_try) 2>&5
6419 ac_status=$?
6420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6421 (exit $ac_status); }; } &&
6422 { ac_try='test -s conftest.$ac_objext'
7862d3a8
AS
6423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6424 (eval $ac_try) 2>&5
6425 ac_status=$?
6426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6427 (exit $ac_status); }; }; then
6428 ac_header_compiler=yes
6429else
6430 echo "$as_me: failed program was:" >&5
6431sed 's/^/| /' conftest.$ac_ext >&5
6432
6433ac_header_compiler=no
6434fi
edfaf76d 6435rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7862d3a8
AS
6436echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6437echo "${ECHO_T}$ac_header_compiler" >&6
6438
6439# Is the header present?
6440echo "$as_me:$LINENO: checking $ac_header presence" >&5
6441echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6442cat >conftest.$ac_ext <<_ACEOF
6443/* confdefs.h. */
6444_ACEOF
6445cat confdefs.h >>conftest.$ac_ext
6446cat >>conftest.$ac_ext <<_ACEOF
6447/* end confdefs.h. */
6448#include <$ac_header>
6449_ACEOF
6450if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6451 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6452 ac_status=$?
6453 grep -v '^ *+' conftest.er1 >conftest.err
6454 rm -f conftest.er1
6455 cat conftest.err >&5
6456 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6457 (exit $ac_status); } >/dev/null; then
6458 if test -s conftest.err; then
6459 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 6460 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7862d3a8
AS
6461 else
6462 ac_cpp_err=
6463 fi
6464else
6465 ac_cpp_err=yes
6466fi
6467if test -z "$ac_cpp_err"; then
6468 ac_header_preproc=yes
6469else
6470 echo "$as_me: failed program was:" >&5
6471sed 's/^/| /' conftest.$ac_ext >&5
6472
6473 ac_header_preproc=no
6474fi
6475rm -f conftest.err conftest.$ac_ext
6476echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6477echo "${ECHO_T}$ac_header_preproc" >&6
6478
6479# So? What about this header?
edfaf76d
LK
6480case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6481 yes:no: )
7862d3a8
AS
6482 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6483echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
6484 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6485echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6486 ac_header_preproc=yes
7862d3a8 6487 ;;
edfaf76d 6488 no:yes:* )
7862d3a8
AS
6489 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6490echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
6491 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6492echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6493 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6494echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6495 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6496echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
7862d3a8
AS
6497 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6498echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
6499 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6500echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7862d3a8
AS
6501 (
6502 cat <<\_ASBOX
edfaf76d
LK
6503## ------------------------------------------ ##
6504## Report this to the AC_PACKAGE_NAME lists. ##
6505## ------------------------------------------ ##
7862d3a8
AS
6506_ASBOX
6507 ) |
6508 sed "s/^/$as_me: WARNING: /" >&2
6509 ;;
6510esac
6511echo "$as_me:$LINENO: checking for $ac_header" >&5
6512echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6513if eval "test \"\${$as_ac_Header+set}\" = set"; then
6514 echo $ECHO_N "(cached) $ECHO_C" >&6
6515else
edfaf76d 6516 eval "$as_ac_Header=\$ac_header_preproc"
7862d3a8
AS
6517fi
6518echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6519echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6520
6521fi
6522if test `eval echo '${'$as_ac_Header'}'` = yes; then
6523 cat >>confdefs.h <<_ACEOF
6524#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6525_ACEOF
6526
6527fi
6528
6529done
6530
6531
6532for ac_header in net/if.h
6533do
6534as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6535echo "$as_me:$LINENO: checking for $ac_header" >&5
6536echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6537if eval "test \"\${$as_ac_Header+set}\" = set"; then
6538 echo $ECHO_N "(cached) $ECHO_C" >&6
6539else
6540 cat >conftest.$ac_ext <<_ACEOF
6541/* confdefs.h. */
6542_ACEOF
6543cat confdefs.h >>conftest.$ac_ext
6544cat >>conftest.$ac_ext <<_ACEOF
6545/* end confdefs.h. */
6546$ac_includes_default
6547#if HAVE_SYS_SOCKET_H
6548#include <sys/socket.h>
6549#endif
6550
6551#include <$ac_header>
6552_ACEOF
6553rm -f conftest.$ac_objext
6554if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6555 (eval $ac_compile) 2>conftest.er1
7862d3a8 6556 ac_status=$?
edfaf76d
LK
6557 grep -v '^ *+' conftest.er1 >conftest.err
6558 rm -f conftest.er1
6559 cat conftest.err >&5
7862d3a8
AS
6560 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6561 (exit $ac_status); } &&
10a3b1a1
EZ
6562 { ac_try='test -z "$ac_c_werror_flag"
6563 || test ! -s conftest.err'
edfaf76d
LK
6564 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6565 (eval $ac_try) 2>&5
6566 ac_status=$?
6567 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6568 (exit $ac_status); }; } &&
6569 { ac_try='test -s conftest.$ac_objext'
7862d3a8
AS
6570 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6571 (eval $ac_try) 2>&5
6572 ac_status=$?
6573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6574 (exit $ac_status); }; }; then
6575 eval "$as_ac_Header=yes"
6576else
6577 echo "$as_me: failed program was:" >&5
6578sed 's/^/| /' conftest.$ac_ext >&5
6579
6580eval "$as_ac_Header=no"
6581fi
edfaf76d 6582rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7862d3a8
AS
6583fi
6584echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6585echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6586if test `eval echo '${'$as_ac_Header'}'` = yes; then
6587 cat >>confdefs.h <<_ACEOF
6588#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6589_ACEOF
6590
6591fi
6592
6593done
6594
6595
c0d27fcc 6596echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
6597echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
6598if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 6599 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6600else
503d2be0 6601 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6602/* confdefs.h. */
6603_ACEOF
6604cat confdefs.h >>conftest.$ac_ext
6605cat >>conftest.$ac_ext <<_ACEOF
6606/* end confdefs.h. */
98418dba
CW
6607#include <sys/types.h>
6608#include <time.h>
7397acc4 6609
503d2be0
AS
6610int
6611main ()
6612{
98418dba 6613struct tm *tp; tp->tm_sec;
503d2be0
AS
6614 ;
6615 return 0;
6616}
6617_ACEOF
6618rm -f conftest.$ac_objext
c0d27fcc 6619if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6620 (eval $ac_compile) 2>conftest.er1
503d2be0 6621 ac_status=$?
edfaf76d
LK
6622 grep -v '^ *+' conftest.er1 >conftest.err
6623 rm -f conftest.er1
6624 cat conftest.err >&5
c0d27fcc 6625 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6626 (exit $ac_status); } &&
10a3b1a1
EZ
6627 { ac_try='test -z "$ac_c_werror_flag"
6628 || test ! -s conftest.err'
edfaf76d
LK
6629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6630 (eval $ac_try) 2>&5
6631 ac_status=$?
6632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6633 (exit $ac_status); }; } &&
6634 { ac_try='test -s conftest.$ac_objext'
35996d22
AS
6635 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6636 (eval $ac_try) 2>&5
6637 ac_status=$?
6638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6639 (exit $ac_status); }; }; then
6640 ac_cv_struct_tm=time.h
6641else
503d2be0 6642 echo "$as_me: failed program was:" >&5
19650fd6
AS
6643sed 's/^/| /' conftest.$ac_ext >&5
6644
98418dba 6645ac_cv_struct_tm=sys/time.h
7397acc4 6646fi
edfaf76d 6647rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6648fi
c0d27fcc 6649echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
6650echo "${ECHO_T}$ac_cv_struct_tm" >&6
6651if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 6652
c0d27fcc 6653cat >>confdefs.h <<\_ACEOF
98418dba 6654#define TM_IN_SYS_TIME 1
c0d27fcc 6655_ACEOF
7397acc4
DL
6656
6657fi
ba4481b5 6658
c0d27fcc 6659echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
6660echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
6661if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 6662 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6663else
98418dba 6664 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6665/* confdefs.h. */
6666_ACEOF
6667cat confdefs.h >>conftest.$ac_ext
6668cat >>conftest.$ac_ext <<_ACEOF
6669/* end confdefs.h. */
98418dba
CW
6670#include <sys/types.h>
6671#include <$ac_cv_struct_tm>
ba4481b5 6672
c0d27fcc 6673
98418dba
CW
6674int
6675main ()
6676{
6677static struct tm ac_aggr;
6678if (ac_aggr.tm_zone)
6679return 0;
6680 ;
6681 return 0;
6682}
6683_ACEOF
6684rm -f conftest.$ac_objext
c0d27fcc 6685if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6686 (eval $ac_compile) 2>conftest.er1
98418dba 6687 ac_status=$?
edfaf76d
LK
6688 grep -v '^ *+' conftest.er1 >conftest.err
6689 rm -f conftest.er1
6690 cat conftest.err >&5
c0d27fcc 6691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6692 (exit $ac_status); } &&
10a3b1a1
EZ
6693 { ac_try='test -z "$ac_c_werror_flag"
6694 || test ! -s conftest.err'
edfaf76d
LK
6695 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6696 (eval $ac_try) 2>&5
6697 ac_status=$?
6698 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6699 (exit $ac_status); }; } &&
6700 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6701 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6702 (eval $ac_try) 2>&5
6703 ac_status=$?
c0d27fcc 6704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6705 (exit $ac_status); }; }; then
6706 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6707else
98418dba 6708 echo "$as_me: failed program was:" >&5
19650fd6
AS
6709sed 's/^/| /' conftest.$ac_ext >&5
6710
6bae0ccf 6711cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6712/* confdefs.h. */
6713_ACEOF
6714cat confdefs.h >>conftest.$ac_ext
6715cat >>conftest.$ac_ext <<_ACEOF
6716/* end confdefs.h. */
6bae0ccf
DL
6717#include <sys/types.h>
6718#include <$ac_cv_struct_tm>
6719
6720
6721int
6722main ()
6723{
6724static struct tm ac_aggr;
6725if (sizeof ac_aggr.tm_zone)
6726return 0;
6727 ;
6728 return 0;
6729}
6730_ACEOF
6731rm -f conftest.$ac_objext
6732if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6733 (eval $ac_compile) 2>conftest.er1
6bae0ccf 6734 ac_status=$?
edfaf76d
LK
6735 grep -v '^ *+' conftest.er1 >conftest.err
6736 rm -f conftest.er1
6737 cat conftest.err >&5
6bae0ccf
DL
6738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6739 (exit $ac_status); } &&
10a3b1a1
EZ
6740 { ac_try='test -z "$ac_c_werror_flag"
6741 || test ! -s conftest.err'
edfaf76d
LK
6742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6743 (eval $ac_try) 2>&5
6744 ac_status=$?
6745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6746 (exit $ac_status); }; } &&
6747 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
6748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6749 (eval $ac_try) 2>&5
6750 ac_status=$?
6751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6752 (exit $ac_status); }; }; then
6753 ac_cv_member_struct_tm_tm_zone=yes
6754else
6755 echo "$as_me: failed program was:" >&5
19650fd6
AS
6756sed 's/^/| /' conftest.$ac_ext >&5
6757
98418dba 6758ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6759fi
edfaf76d 6760rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6761fi
edfaf76d 6762rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6763fi
c0d27fcc 6764echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6765echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6766if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6767
c0d27fcc 6768cat >>confdefs.h <<_ACEOF
98418dba 6769#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6770_ACEOF
6771
ba4481b5 6772
98418dba 6773fi
ba4481b5 6774
98418dba 6775if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6776
c0d27fcc 6777cat >>confdefs.h <<\_ACEOF
98418dba 6778#define HAVE_TM_ZONE 1
c0d27fcc 6779_ACEOF
ba4481b5 6780
ba4481b5 6781else
c0d27fcc 6782 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6783echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6784if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6785 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6786else
98418dba 6787 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6788/* confdefs.h. */
6789_ACEOF
6790cat confdefs.h >>conftest.$ac_ext
6791cat >>conftest.$ac_ext <<_ACEOF
6792/* end confdefs.h. */
98418dba
CW
6793#include <time.h>
6794#ifndef tzname /* For SGI. */
6795extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6796#endif
6797
98418dba
CW
6798int
6799main ()
6800{
6801atoi(*tzname);
6802 ;
6803 return 0;
6804}
6805_ACEOF
6806rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6807if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 6808 (eval $ac_link) 2>conftest.er1
98418dba 6809 ac_status=$?
edfaf76d
LK
6810 grep -v '^ *+' conftest.er1 >conftest.err
6811 rm -f conftest.er1
6812 cat conftest.err >&5
c0d27fcc 6813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6814 (exit $ac_status); } &&
10a3b1a1
EZ
6815 { ac_try='test -z "$ac_c_werror_flag"
6816 || test ! -s conftest.err'
edfaf76d
LK
6817 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6818 (eval $ac_try) 2>&5
6819 ac_status=$?
6820 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6821 (exit $ac_status); }; } &&
6822 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6823 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6824 (eval $ac_try) 2>&5
6825 ac_status=$?
c0d27fcc 6826 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6827 (exit $ac_status); }; }; then
6828 ac_cv_var_tzname=yes
6829else
6830 echo "$as_me: failed program was:" >&5
19650fd6
AS
6831sed 's/^/| /' conftest.$ac_ext >&5
6832
98418dba 6833ac_cv_var_tzname=no
ba4481b5 6834fi
edfaf76d
LK
6835rm -f conftest.err conftest.$ac_objext \
6836 conftest$ac_exeext conftest.$ac_ext
98418dba 6837fi
c0d27fcc 6838echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6839echo "${ECHO_T}$ac_cv_var_tzname" >&6
6840 if test $ac_cv_var_tzname = yes; then
ba4481b5 6841
c0d27fcc 6842cat >>confdefs.h <<\_ACEOF
98418dba 6843#define HAVE_TZNAME 1
c0d27fcc 6844_ACEOF
503d2be0 6845
98418dba
CW
6846 fi
6847fi
503d2be0 6848
c0d27fcc 6849echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6850echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6851if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6852 echo $ECHO_N "(cached) $ECHO_C" >&6
6853else
6854 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6855/* confdefs.h. */
6856_ACEOF
6857cat confdefs.h >>conftest.$ac_ext
6858cat >>conftest.$ac_ext <<_ACEOF
6859/* end confdefs.h. */
98418dba 6860#include <time.h>
b936fae4 6861
98418dba
CW
6862int
6863main ()
6864{
b936fae4
AS
6865static struct tm ac_aggr;
6866if (ac_aggr.tm_gmtoff)
6867return 0;
98418dba
CW
6868 ;
6869 return 0;
6870}
6871_ACEOF
b936fae4 6872rm -f conftest.$ac_objext
c0d27fcc 6873if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6874 (eval $ac_compile) 2>conftest.er1
98418dba 6875 ac_status=$?
edfaf76d
LK
6876 grep -v '^ *+' conftest.er1 >conftest.err
6877 rm -f conftest.er1
6878 cat conftest.err >&5
c0d27fcc 6879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6880 (exit $ac_status); } &&
10a3b1a1
EZ
6881 { ac_try='test -z "$ac_c_werror_flag"
6882 || test ! -s conftest.err'
edfaf76d
LK
6883 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6884 (eval $ac_try) 2>&5
6885 ac_status=$?
6886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6887 (exit $ac_status); }; } &&
6888 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6889 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6890 (eval $ac_try) 2>&5
6891 ac_status=$?
c0d27fcc 6892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6893 (exit $ac_status); }; }; then
b936fae4 6894 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6895else
6896 echo "$as_me: failed program was:" >&5
19650fd6
AS
6897sed 's/^/| /' conftest.$ac_ext >&5
6898
8799b3e4 6899cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6900/* confdefs.h. */
6901_ACEOF
6902cat confdefs.h >>conftest.$ac_ext
6903cat >>conftest.$ac_ext <<_ACEOF
6904/* end confdefs.h. */
6bae0ccf
DL
6905#include <time.h>
6906
8799b3e4
CW
6907int
6908main ()
6909{
6bae0ccf
DL
6910static struct tm ac_aggr;
6911if (sizeof ac_aggr.tm_gmtoff)
6912return 0;
8799b3e4
CW
6913 ;
6914 return 0;
6915}
6916_ACEOF
6bae0ccf 6917rm -f conftest.$ac_objext
c0d27fcc 6918if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6919 (eval $ac_compile) 2>conftest.er1
8799b3e4 6920 ac_status=$?
edfaf76d
LK
6921 grep -v '^ *+' conftest.er1 >conftest.err
6922 rm -f conftest.er1
6923 cat conftest.err >&5
c0d27fcc 6924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6925 (exit $ac_status); } &&
10a3b1a1
EZ
6926 { ac_try='test -z "$ac_c_werror_flag"
6927 || test ! -s conftest.err'
edfaf76d
LK
6928 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6929 (eval $ac_try) 2>&5
6930 ac_status=$?
6931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6932 (exit $ac_status); }; } &&
6933 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6934 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6935 (eval $ac_try) 2>&5
6936 ac_status=$?
c0d27fcc 6937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6938 (exit $ac_status); }; }; then
6bae0ccf 6939 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6940else
6941 echo "$as_me: failed program was:" >&5
19650fd6
AS
6942sed 's/^/| /' conftest.$ac_ext >&5
6943
6bae0ccf 6944ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6945fi
edfaf76d 6946rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6947fi
edfaf76d 6948rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8799b3e4 6949fi
6bae0ccf
DL
6950echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6951echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6952if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6953
6954cat >>confdefs.h <<\_ACEOF
6955#define HAVE_TM_GMTOFF 1
6956_ACEOF
6957
6958fi
6959
96f3a036
DL
6960echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
6961echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6
6962if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
6963 echo $ECHO_N "(cached) $ECHO_C" >&6
6964else
6965 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6966/* confdefs.h. */
6967_ACEOF
6968cat confdefs.h >>conftest.$ac_ext
6969cat >>conftest.$ac_ext <<_ACEOF
6970/* end confdefs.h. */
7862d3a8
AS
6971$ac_includes_default
6972#if HAVE_SYS_SOCKET_H
6973#include <sys/socket.h>
6974#endif
6975#if HAVE_NET_IF_H
96f3a036 6976#include <net/if.h>
7862d3a8 6977#endif
96f3a036
DL
6978
6979int
6980main ()
6981{
6982static struct ifreq ac_aggr;
6983if (ac_aggr.ifr_flags)
6984return 0;
6985 ;
6986 return 0;
6987}
6988_ACEOF
6989rm -f conftest.$ac_objext
6990if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 6991 (eval $ac_compile) 2>conftest.er1
96f3a036 6992 ac_status=$?
edfaf76d
LK
6993 grep -v '^ *+' conftest.er1 >conftest.err
6994 rm -f conftest.er1
6995 cat conftest.err >&5
96f3a036
DL
6996 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6997 (exit $ac_status); } &&
10a3b1a1
EZ
6998 { ac_try='test -z "$ac_c_werror_flag"
6999 || test ! -s conftest.err'
edfaf76d
LK
7000 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7001 (eval $ac_try) 2>&5
7002 ac_status=$?
7003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7004 (exit $ac_status); }; } &&
7005 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7006 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7007 (eval $ac_try) 2>&5
7008 ac_status=$?
7009 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7010 (exit $ac_status); }; }; then
7011 ac_cv_member_struct_ifreq_ifr_flags=yes
7012else
7013 echo "$as_me: failed program was:" >&5
7014sed 's/^/| /' conftest.$ac_ext >&5
7015
7016cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7017/* confdefs.h. */
7018_ACEOF
7019cat confdefs.h >>conftest.$ac_ext
7020cat >>conftest.$ac_ext <<_ACEOF
7021/* end confdefs.h. */
7862d3a8
AS
7022$ac_includes_default
7023#if HAVE_SYS_SOCKET_H
7024#include <sys/socket.h>
7025#endif
7026#if HAVE_NET_IF_H
96f3a036 7027#include <net/if.h>
7862d3a8 7028#endif
96f3a036
DL
7029
7030int
7031main ()
7032{
7033static struct ifreq ac_aggr;
7034if (sizeof ac_aggr.ifr_flags)
7035return 0;
7036 ;
7037 return 0;
7038}
7039_ACEOF
7040rm -f conftest.$ac_objext
7041if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7042 (eval $ac_compile) 2>conftest.er1
96f3a036 7043 ac_status=$?
edfaf76d
LK
7044 grep -v '^ *+' conftest.er1 >conftest.err
7045 rm -f conftest.er1
7046 cat conftest.err >&5
96f3a036
DL
7047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7048 (exit $ac_status); } &&
10a3b1a1
EZ
7049 { ac_try='test -z "$ac_c_werror_flag"
7050 || test ! -s conftest.err'
edfaf76d
LK
7051 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7052 (eval $ac_try) 2>&5
7053 ac_status=$?
7054 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7055 (exit $ac_status); }; } &&
7056 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7057 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7058 (eval $ac_try) 2>&5
7059 ac_status=$?
7060 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7061 (exit $ac_status); }; }; then
7062 ac_cv_member_struct_ifreq_ifr_flags=yes
7063else
7064 echo "$as_me: failed program was:" >&5
7065sed 's/^/| /' conftest.$ac_ext >&5
7066
7067ac_cv_member_struct_ifreq_ifr_flags=no
7068fi
edfaf76d 7069rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7070fi
edfaf76d 7071rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7072fi
7073echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
7074echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6
7075if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
7076
7077cat >>confdefs.h <<_ACEOF
7078#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
7079_ACEOF
7080
7081
7082fi
7083echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
7084echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
7085if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
7086 echo $ECHO_N "(cached) $ECHO_C" >&6
7087else
7088 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7089/* confdefs.h. */
7090_ACEOF
7091cat confdefs.h >>conftest.$ac_ext
7092cat >>conftest.$ac_ext <<_ACEOF
7093/* end confdefs.h. */
7862d3a8
AS
7094$ac_includes_default
7095#if HAVE_SYS_SOCKET_H
7096#include <sys/socket.h>
7097#endif
7098#if HAVE_NET_IF_H
96f3a036 7099#include <net/if.h>
7862d3a8 7100#endif
96f3a036
DL
7101
7102int
7103main ()
7104{
7105static struct ifreq ac_aggr;
7106if (ac_aggr.ifr_hwaddr)
7107return 0;
7108 ;
7109 return 0;
7110}
7111_ACEOF
7112rm -f conftest.$ac_objext
7113if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7114 (eval $ac_compile) 2>conftest.er1
96f3a036 7115 ac_status=$?
edfaf76d
LK
7116 grep -v '^ *+' conftest.er1 >conftest.err
7117 rm -f conftest.er1
7118 cat conftest.err >&5
96f3a036
DL
7119 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7120 (exit $ac_status); } &&
10a3b1a1
EZ
7121 { ac_try='test -z "$ac_c_werror_flag"
7122 || test ! -s conftest.err'
edfaf76d
LK
7123 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7124 (eval $ac_try) 2>&5
7125 ac_status=$?
7126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7127 (exit $ac_status); }; } &&
7128 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7129 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7130 (eval $ac_try) 2>&5
7131 ac_status=$?
7132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7133 (exit $ac_status); }; }; then
7134 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7135else
7136 echo "$as_me: failed program was:" >&5
7137sed 's/^/| /' conftest.$ac_ext >&5
7138
7139cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7140/* confdefs.h. */
7141_ACEOF
7142cat confdefs.h >>conftest.$ac_ext
7143cat >>conftest.$ac_ext <<_ACEOF
7144/* end confdefs.h. */
7862d3a8
AS
7145$ac_includes_default
7146#if HAVE_SYS_SOCKET_H
7147#include <sys/socket.h>
7148#endif
7149#if HAVE_NET_IF_H
96f3a036 7150#include <net/if.h>
7862d3a8 7151#endif
96f3a036
DL
7152
7153int
7154main ()
7155{
7156static struct ifreq ac_aggr;
7157if (sizeof ac_aggr.ifr_hwaddr)
7158return 0;
7159 ;
7160 return 0;
7161}
7162_ACEOF
7163rm -f conftest.$ac_objext
7164if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7165 (eval $ac_compile) 2>conftest.er1
96f3a036 7166 ac_status=$?
edfaf76d
LK
7167 grep -v '^ *+' conftest.er1 >conftest.err
7168 rm -f conftest.er1
7169 cat conftest.err >&5
96f3a036
DL
7170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7171 (exit $ac_status); } &&
10a3b1a1
EZ
7172 { ac_try='test -z "$ac_c_werror_flag"
7173 || test ! -s conftest.err'
edfaf76d
LK
7174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7175 (eval $ac_try) 2>&5
7176 ac_status=$?
7177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7178 (exit $ac_status); }; } &&
7179 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7181 (eval $ac_try) 2>&5
7182 ac_status=$?
7183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7184 (exit $ac_status); }; }; then
7185 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7186else
7187 echo "$as_me: failed program was:" >&5
7188sed 's/^/| /' conftest.$ac_ext >&5
7189
7190ac_cv_member_struct_ifreq_ifr_hwaddr=no
7191fi
edfaf76d 7192rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7193fi
edfaf76d 7194rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7195fi
7196echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
7197echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
7198if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
7199
7200cat >>confdefs.h <<_ACEOF
7201#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
7202_ACEOF
7203
7204
7205fi
7206echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
7207echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6
7208if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
7209 echo $ECHO_N "(cached) $ECHO_C" >&6
7210else
7211 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7212/* confdefs.h. */
7213_ACEOF
7214cat confdefs.h >>conftest.$ac_ext
7215cat >>conftest.$ac_ext <<_ACEOF
7216/* end confdefs.h. */
7862d3a8
AS
7217$ac_includes_default
7218#if HAVE_SYS_SOCKET_H
7219#include <sys/socket.h>
7220#endif
7221#if HAVE_NET_IF_H
96f3a036 7222#include <net/if.h>
7862d3a8 7223#endif
96f3a036
DL
7224
7225int
7226main ()
7227{
7228static struct ifreq ac_aggr;
7229if (ac_aggr.ifr_netmask)
7230return 0;
7231 ;
7232 return 0;
7233}
7234_ACEOF
7235rm -f conftest.$ac_objext
7236if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7237 (eval $ac_compile) 2>conftest.er1
96f3a036 7238 ac_status=$?
edfaf76d
LK
7239 grep -v '^ *+' conftest.er1 >conftest.err
7240 rm -f conftest.er1
7241 cat conftest.err >&5
96f3a036
DL
7242 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7243 (exit $ac_status); } &&
10a3b1a1
EZ
7244 { ac_try='test -z "$ac_c_werror_flag"
7245 || test ! -s conftest.err'
edfaf76d
LK
7246 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7247 (eval $ac_try) 2>&5
7248 ac_status=$?
7249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7250 (exit $ac_status); }; } &&
7251 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7253 (eval $ac_try) 2>&5
7254 ac_status=$?
7255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7256 (exit $ac_status); }; }; then
7257 ac_cv_member_struct_ifreq_ifr_netmask=yes
7258else
7259 echo "$as_me: failed program was:" >&5
7260sed 's/^/| /' conftest.$ac_ext >&5
7261
7262cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7263/* confdefs.h. */
7264_ACEOF
7265cat confdefs.h >>conftest.$ac_ext
7266cat >>conftest.$ac_ext <<_ACEOF
7267/* end confdefs.h. */
7862d3a8
AS
7268$ac_includes_default
7269#if HAVE_SYS_SOCKET_H
7270#include <sys/socket.h>
7271#endif
7272#if HAVE_NET_IF_H
96f3a036 7273#include <net/if.h>
7862d3a8 7274#endif
96f3a036
DL
7275
7276int
7277main ()
7278{
7279static struct ifreq ac_aggr;
7280if (sizeof ac_aggr.ifr_netmask)
7281return 0;
7282 ;
7283 return 0;
7284}
7285_ACEOF
7286rm -f conftest.$ac_objext
7287if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7288 (eval $ac_compile) 2>conftest.er1
96f3a036 7289 ac_status=$?
edfaf76d
LK
7290 grep -v '^ *+' conftest.er1 >conftest.err
7291 rm -f conftest.er1
7292 cat conftest.err >&5
96f3a036
DL
7293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7294 (exit $ac_status); } &&
10a3b1a1
EZ
7295 { ac_try='test -z "$ac_c_werror_flag"
7296 || test ! -s conftest.err'
edfaf76d
LK
7297 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7298 (eval $ac_try) 2>&5
7299 ac_status=$?
7300 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7301 (exit $ac_status); }; } &&
7302 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7303 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7304 (eval $ac_try) 2>&5
7305 ac_status=$?
7306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7307 (exit $ac_status); }; }; then
7308 ac_cv_member_struct_ifreq_ifr_netmask=yes
7309else
7310 echo "$as_me: failed program was:" >&5
7311sed 's/^/| /' conftest.$ac_ext >&5
7312
7313ac_cv_member_struct_ifreq_ifr_netmask=no
7314fi
edfaf76d 7315rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7316fi
edfaf76d 7317rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7318fi
7319echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
7320echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6
7321if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
7322
7323cat >>confdefs.h <<_ACEOF
7324#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
7325_ACEOF
7326
7327
7328fi
7329echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
7330echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6
7331if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
7332 echo $ECHO_N "(cached) $ECHO_C" >&6
7333else
7334 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7335/* confdefs.h. */
7336_ACEOF
7337cat confdefs.h >>conftest.$ac_ext
7338cat >>conftest.$ac_ext <<_ACEOF
7339/* end confdefs.h. */
7862d3a8
AS
7340$ac_includes_default
7341#if HAVE_SYS_SOCKET_H
7342#include <sys/socket.h>
7343#endif
7344#if HAVE_NET_IF_H
96f3a036 7345#include <net/if.h>
7862d3a8 7346#endif
96f3a036
DL
7347
7348int
7349main ()
7350{
7351static struct ifreq ac_aggr;
7352if (ac_aggr.ifr_broadaddr)
7353return 0;
7354 ;
7355 return 0;
7356}
7357_ACEOF
7358rm -f conftest.$ac_objext
7359if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7360 (eval $ac_compile) 2>conftest.er1
96f3a036 7361 ac_status=$?
edfaf76d
LK
7362 grep -v '^ *+' conftest.er1 >conftest.err
7363 rm -f conftest.er1
7364 cat conftest.err >&5
96f3a036
DL
7365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7366 (exit $ac_status); } &&
10a3b1a1
EZ
7367 { ac_try='test -z "$ac_c_werror_flag"
7368 || test ! -s conftest.err'
edfaf76d
LK
7369 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7370 (eval $ac_try) 2>&5
7371 ac_status=$?
7372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7373 (exit $ac_status); }; } &&
7374 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7375 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7376 (eval $ac_try) 2>&5
7377 ac_status=$?
7378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7379 (exit $ac_status); }; }; then
7380 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7381else
7382 echo "$as_me: failed program was:" >&5
7383sed 's/^/| /' conftest.$ac_ext >&5
7384
7385cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7386/* confdefs.h. */
7387_ACEOF
7388cat confdefs.h >>conftest.$ac_ext
7389cat >>conftest.$ac_ext <<_ACEOF
7390/* end confdefs.h. */
7862d3a8
AS
7391$ac_includes_default
7392#if HAVE_SYS_SOCKET_H
7393#include <sys/socket.h>
7394#endif
7395#if HAVE_NET_IF_H
96f3a036 7396#include <net/if.h>
7862d3a8 7397#endif
96f3a036
DL
7398
7399int
7400main ()
7401{
7402static struct ifreq ac_aggr;
7403if (sizeof ac_aggr.ifr_broadaddr)
7404return 0;
7405 ;
7406 return 0;
7407}
7408_ACEOF
7409rm -f conftest.$ac_objext
7410if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7411 (eval $ac_compile) 2>conftest.er1
96f3a036 7412 ac_status=$?
edfaf76d
LK
7413 grep -v '^ *+' conftest.er1 >conftest.err
7414 rm -f conftest.er1
7415 cat conftest.err >&5
96f3a036
DL
7416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7417 (exit $ac_status); } &&
10a3b1a1
EZ
7418 { ac_try='test -z "$ac_c_werror_flag"
7419 || test ! -s conftest.err'
edfaf76d
LK
7420 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7421 (eval $ac_try) 2>&5
7422 ac_status=$?
7423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7424 (exit $ac_status); }; } &&
7425 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7426 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7427 (eval $ac_try) 2>&5
7428 ac_status=$?
7429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7430 (exit $ac_status); }; }; then
7431 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7432else
7433 echo "$as_me: failed program was:" >&5
7434sed 's/^/| /' conftest.$ac_ext >&5
7435
7436ac_cv_member_struct_ifreq_ifr_broadaddr=no
7437fi
edfaf76d 7438rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7439fi
edfaf76d 7440rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7441fi
7442echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
7443echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6
7444if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
7445
7446cat >>confdefs.h <<_ACEOF
7447#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
7448_ACEOF
7449
7450
7451fi
7452echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
7453echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6
7454if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
7455 echo $ECHO_N "(cached) $ECHO_C" >&6
7456else
7457 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7458/* confdefs.h. */
7459_ACEOF
7460cat confdefs.h >>conftest.$ac_ext
7461cat >>conftest.$ac_ext <<_ACEOF
7462/* end confdefs.h. */
7862d3a8
AS
7463$ac_includes_default
7464#if HAVE_SYS_SOCKET_H
7465#include <sys/socket.h>
7466#endif
7467#if HAVE_NET_IF_H
96f3a036 7468#include <net/if.h>
7862d3a8 7469#endif
96f3a036
DL
7470
7471int
7472main ()
7473{
7474static struct ifreq ac_aggr;
7475if (ac_aggr.ifr_addr)
7476return 0;
7477 ;
7478 return 0;
7479}
7480_ACEOF
7481rm -f conftest.$ac_objext
7482if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7483 (eval $ac_compile) 2>conftest.er1
96f3a036 7484 ac_status=$?
edfaf76d
LK
7485 grep -v '^ *+' conftest.er1 >conftest.err
7486 rm -f conftest.er1
7487 cat conftest.err >&5
96f3a036
DL
7488 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7489 (exit $ac_status); } &&
10a3b1a1
EZ
7490 { ac_try='test -z "$ac_c_werror_flag"
7491 || test ! -s conftest.err'
edfaf76d
LK
7492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7493 (eval $ac_try) 2>&5
7494 ac_status=$?
7495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7496 (exit $ac_status); }; } &&
7497 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7498 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7499 (eval $ac_try) 2>&5
7500 ac_status=$?
7501 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7502 (exit $ac_status); }; }; then
7503 ac_cv_member_struct_ifreq_ifr_addr=yes
7504else
7505 echo "$as_me: failed program was:" >&5
7506sed 's/^/| /' conftest.$ac_ext >&5
7507
7508cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7509/* confdefs.h. */
7510_ACEOF
7511cat confdefs.h >>conftest.$ac_ext
7512cat >>conftest.$ac_ext <<_ACEOF
7513/* end confdefs.h. */
7862d3a8
AS
7514$ac_includes_default
7515#if HAVE_SYS_SOCKET_H
7516#include <sys/socket.h>
7517#endif
7518#if HAVE_NET_IF_H
96f3a036 7519#include <net/if.h>
7862d3a8 7520#endif
96f3a036
DL
7521
7522int
7523main ()
7524{
7525static struct ifreq ac_aggr;
7526if (sizeof ac_aggr.ifr_addr)
7527return 0;
7528 ;
7529 return 0;
7530}
7531_ACEOF
7532rm -f conftest.$ac_objext
7533if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7534 (eval $ac_compile) 2>conftest.er1
96f3a036 7535 ac_status=$?
edfaf76d
LK
7536 grep -v '^ *+' conftest.er1 >conftest.err
7537 rm -f conftest.er1
7538 cat conftest.err >&5
96f3a036
DL
7539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7540 (exit $ac_status); } &&
10a3b1a1
EZ
7541 { ac_try='test -z "$ac_c_werror_flag"
7542 || test ! -s conftest.err'
edfaf76d
LK
7543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7544 (eval $ac_try) 2>&5
7545 ac_status=$?
7546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7547 (exit $ac_status); }; } &&
7548 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7549 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7550 (eval $ac_try) 2>&5
7551 ac_status=$?
7552 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7553 (exit $ac_status); }; }; then
7554 ac_cv_member_struct_ifreq_ifr_addr=yes
7555else
7556 echo "$as_me: failed program was:" >&5
7557sed 's/^/| /' conftest.$ac_ext >&5
7558
7559ac_cv_member_struct_ifreq_ifr_addr=no
7560fi
edfaf76d 7561rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7562fi
edfaf76d 7563rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7564fi
7565echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
7566echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6
7567if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
7568
7569cat >>confdefs.h <<_ACEOF
7570#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
7571_ACEOF
7572
7573
7574fi
7575
8799b3e4 7576
8799b3e4 7577
c0d27fcc 7578echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
7579echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
7580if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 7581 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7582echo "${ECHO_T}yes" >&6
7583
c0d27fcc 7584cat >>confdefs.h <<\_ACEOF
98418dba 7585#define PROTOTYPES 1
c0d27fcc
MR
7586_ACEOF
7587
7588
7589cat >>confdefs.h <<\_ACEOF
7590#define __PROTOTYPES 1
7591_ACEOF
98418dba
CW
7592
7593else
c0d27fcc 7594 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7595echo "${ECHO_T}no" >&6
7596fi
7597
c0d27fcc 7598echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
7599echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
7600if test "${ac_cv_c_volatile+set}" = set; then
7601 echo $ECHO_N "(cached) $ECHO_C" >&6
7602else
7603 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7604/* confdefs.h. */
7605_ACEOF
7606cat confdefs.h >>conftest.$ac_ext
7607cat >>conftest.$ac_ext <<_ACEOF
7608/* end confdefs.h. */
98418dba 7609
98418dba
CW
7610int
7611main ()
7612{
7613
7614volatile int x;
7615int * volatile y;
7616 ;
7617 return 0;
7618}
7619_ACEOF
7620rm -f conftest.$ac_objext
c0d27fcc 7621if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7622 (eval $ac_compile) 2>conftest.er1
98418dba 7623 ac_status=$?
edfaf76d
LK
7624 grep -v '^ *+' conftest.er1 >conftest.err
7625 rm -f conftest.er1
7626 cat conftest.err >&5
c0d27fcc 7627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7628 (exit $ac_status); } &&
10a3b1a1
EZ
7629 { ac_try='test -z "$ac_c_werror_flag"
7630 || test ! -s conftest.err'
edfaf76d
LK
7631 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7632 (eval $ac_try) 2>&5
7633 ac_status=$?
7634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7635 (exit $ac_status); }; } &&
7636 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7637 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7638 (eval $ac_try) 2>&5
7639 ac_status=$?
c0d27fcc 7640 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7641 (exit $ac_status); }; }; then
7642 ac_cv_c_volatile=yes
7643else
7644 echo "$as_me: failed program was:" >&5
19650fd6
AS
7645sed 's/^/| /' conftest.$ac_ext >&5
7646
98418dba
CW
7647ac_cv_c_volatile=no
7648fi
edfaf76d 7649rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7650fi
c0d27fcc 7651echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
7652echo "${ECHO_T}$ac_cv_c_volatile" >&6
7653if test $ac_cv_c_volatile = no; then
7654
c0d27fcc 7655cat >>confdefs.h <<\_ACEOF
98418dba 7656#define volatile
c0d27fcc 7657_ACEOF
98418dba
CW
7658
7659fi
7660
c0d27fcc 7661echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
7662echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
7663if test "${ac_cv_c_const+set}" = set; then
7664 echo $ECHO_N "(cached) $ECHO_C" >&6
7665else
7666 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7667/* confdefs.h. */
7668_ACEOF
7669cat confdefs.h >>conftest.$ac_ext
7670cat >>conftest.$ac_ext <<_ACEOF
7671/* end confdefs.h. */
98418dba 7672
98418dba
CW
7673int
7674main ()
7675{
7676/* FIXME: Include the comments suggested by Paul. */
7677#ifndef __cplusplus
7678 /* Ultrix mips cc rejects this. */
7679 typedef int charset[2];
7680 const charset x;
7681 /* SunOS 4.1.1 cc rejects this. */
7682 char const *const *ccp;
7683 char **p;
7684 /* NEC SVR4.0.2 mips cc rejects this. */
7685 struct point {int x, y;};
7686 static struct point const zero = {0,0};
7687 /* AIX XL C 1.02.0.0 rejects this.
7688 It does not let you subtract one const X* pointer from another in
7689 an arm of an if-expression whose if-part is not a constant
7690 expression */
7691 const char *g = "string";
7692 ccp = &g + (g ? g-g : 0);
7693 /* HPUX 7.0 cc rejects these. */
7694 ++ccp;
7695 p = (char**) ccp;
7696 ccp = (char const *const *) p;
7697 { /* SCO 3.2v4 cc rejects this. */
7698 char *t;
7699 char const *s = 0 ? (char *) 0 : (char const *) 0;
7700
7701 *t++ = 0;
7702 }
7703 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7704 int x[] = {25, 17};
7705 const int *foo = &x[0];
7706 ++foo;
7707 }
7708 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7709 typedef const int *iptr;
7710 iptr p = 0;
7711 ++p;
7712 }
7713 { /* AIX XL C 1.02.0.0 rejects this saying
7714 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7715 struct s { int j; const int *ap[3]; };
7716 struct s *b; b->j = 5;
7717 }
7718 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7719 const int foo = 10;
7720 }
7721#endif
7722
7723 ;
7724 return 0;
7725}
7726_ACEOF
7727rm -f conftest.$ac_objext
c0d27fcc 7728if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7729 (eval $ac_compile) 2>conftest.er1
98418dba 7730 ac_status=$?
edfaf76d
LK
7731 grep -v '^ *+' conftest.er1 >conftest.err
7732 rm -f conftest.er1
7733 cat conftest.err >&5
c0d27fcc 7734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7735 (exit $ac_status); } &&
10a3b1a1
EZ
7736 { ac_try='test -z "$ac_c_werror_flag"
7737 || test ! -s conftest.err'
edfaf76d
LK
7738 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7739 (eval $ac_try) 2>&5
7740 ac_status=$?
7741 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7742 (exit $ac_status); }; } &&
7743 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7744 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7745 (eval $ac_try) 2>&5
7746 ac_status=$?
c0d27fcc 7747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7748 (exit $ac_status); }; }; then
7749 ac_cv_c_const=yes
7750else
7751 echo "$as_me: failed program was:" >&5
19650fd6
AS
7752sed 's/^/| /' conftest.$ac_ext >&5
7753
98418dba
CW
7754ac_cv_c_const=no
7755fi
edfaf76d 7756rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7757fi
c0d27fcc 7758echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
7759echo "${ECHO_T}$ac_cv_c_const" >&6
7760if test $ac_cv_c_const = no; then
7761
c0d27fcc 7762cat >>confdefs.h <<\_ACEOF
98418dba 7763#define const
c0d27fcc 7764_ACEOF
98418dba
CW
7765
7766fi
7767
c0d27fcc 7768echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
7769echo $ECHO_N "checking for void * support... $ECHO_C" >&6
7770if test "${emacs_cv_void_star+set}" = set; then
7771 echo $ECHO_N "(cached) $ECHO_C" >&6
7772else
7773 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7774/* confdefs.h. */
7775_ACEOF
7776cat confdefs.h >>conftest.$ac_ext
7777cat >>conftest.$ac_ext <<_ACEOF
7778/* end confdefs.h. */
98418dba 7779
98418dba
CW
7780int
7781main ()
7782{
7783void * foo;
7784 ;
7785 return 0;
7786}
7787_ACEOF
7788rm -f conftest.$ac_objext
c0d27fcc 7789if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 7790 (eval $ac_compile) 2>conftest.er1
98418dba 7791 ac_status=$?
edfaf76d
LK
7792 grep -v '^ *+' conftest.er1 >conftest.err
7793 rm -f conftest.er1
7794 cat conftest.err >&5
c0d27fcc 7795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7796 (exit $ac_status); } &&
10a3b1a1
EZ
7797 { ac_try='test -z "$ac_c_werror_flag"
7798 || test ! -s conftest.err'
edfaf76d
LK
7799 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7800 (eval $ac_try) 2>&5
7801 ac_status=$?
7802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7803 (exit $ac_status); }; } &&
7804 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7805 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7806 (eval $ac_try) 2>&5
7807 ac_status=$?
c0d27fcc 7808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7809 (exit $ac_status); }; }; then
7810 emacs_cv_void_star=yes
7811else
7812 echo "$as_me: failed program was:" >&5
19650fd6
AS
7813sed 's/^/| /' conftest.$ac_ext >&5
7814
98418dba
CW
7815emacs_cv_void_star=no
7816fi
edfaf76d 7817rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7818fi
c0d27fcc 7819echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
7820echo "${ECHO_T}$emacs_cv_void_star" >&6
7821if test $emacs_cv_void_star = yes; then
c0d27fcc 7822 cat >>confdefs.h <<\_ACEOF
98418dba 7823#define POINTER_TYPE void
c0d27fcc 7824_ACEOF
98418dba
CW
7825
7826else
c0d27fcc 7827 cat >>confdefs.h <<\_ACEOF
98418dba 7828#define POINTER_TYPE char
c0d27fcc 7829_ACEOF
98418dba
CW
7830
7831fi
7832
c0d27fcc 7833
4494a266
JD
7834
7835
cd958eb3 7836
19650fd6
AS
7837echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7838echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
edfaf76d 7839set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
98418dba
CW
7840if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
7841 echo $ECHO_N "(cached) $ECHO_C" >&6
7842else
c0d27fcc 7843 cat >conftest.make <<\_ACEOF
98418dba 7844all:
19650fd6 7845 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 7846_ACEOF
98418dba
CW
7847# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7848eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
7849if test -n "$ac_maketemp"; then
7850 eval ac_cv_prog_make_${ac_make}_set=yes
7851else
7852 eval ac_cv_prog_make_${ac_make}_set=no
7853fi
7854rm -f conftest.make
7855fi
7856if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 7857 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7858echo "${ECHO_T}yes" >&6
7859 SET_MAKE=
7860else
c0d27fcc 7861 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7862echo "${ECHO_T}no" >&6
7863 SET_MAKE="MAKE=${MAKE-make}"
7864fi
7865
c0d27fcc
MR
7866
7867echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
7868echo $ECHO_N "checking for long file names... $ECHO_C" >&6
7869if test "${ac_cv_sys_long_file_names+set}" = set; then
7870 echo $ECHO_N "(cached) $ECHO_C" >&6
7871else
7872 ac_cv_sys_long_file_names=yes
7873# Test for long file names in all the places we know might matter:
7874# . the current directory, where building will happen
7875# $prefix/lib where we will be installing things
7876# $exec_prefix/lib likewise
7877# eval it to expand exec_prefix.
7878# $TMPDIR if set, where it might want to write temporary files
7879# if $TMPDIR is not set:
7880# /tmp where it might want to write temporary files
7881# /var/tmp likewise
7882# /usr/tmp likewise
7883if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
7884 ac_tmpdirs=$TMPDIR
7885else
7886 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
7887fi
7888for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
7889 test -d $ac_dir || continue
7890 test -w $ac_dir || continue # It is less confusing to not echo anything here.
7891 ac_xdir=$ac_dir/cf$$
7892 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
7893 ac_tf1=$ac_xdir/conftest9012345
7894 ac_tf2=$ac_xdir/conftest9012346
7895 (echo 1 >$ac_tf1) 2>/dev/null
7896 (echo 2 >$ac_tf2) 2>/dev/null
7897 ac_val=`cat $ac_tf1 2>/dev/null`
7898 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
7899 ac_cv_sys_long_file_names=no
7900 rm -rf $ac_xdir 2>/dev/null
7901 break
7902 fi
7903 rm -rf $ac_xdir 2>/dev/null
7904done
7905fi
c0d27fcc 7906echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
7907echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
7908if test $ac_cv_sys_long_file_names = yes; then
7909
c0d27fcc 7910cat >>confdefs.h <<\_ACEOF
98418dba 7911#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 7912_ACEOF
98418dba
CW
7913
7914fi
7915
c0d27fcc 7916
98418dba
CW
7917#### Choose a window system.
7918
c0d27fcc 7919echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
7920echo $ECHO_N "checking for X... $ECHO_C" >&6
7921
c0d27fcc 7922
98418dba
CW
7923# Check whether --with-x or --without-x was given.
7924if test "${with_x+set}" = set; then
7925 withval="$with_x"
7926
7927fi;
7928# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7929if test "x$with_x" = xno; then
7930 # The user explicitly disabled X.
7931 have_x=disabled
7932else
7933 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7934 # Both variables are already set.
7935 have_x=yes
7936 else
7937 if test "${ac_cv_have_x+set}" = set; then
7938 echo $ECHO_N "(cached) $ECHO_C" >&6
7939else
7940 # One or both of the vars are not set, and there is no cached value.
7941ac_x_includes=no ac_x_libraries=no
7942rm -fr conftest.dir
7943if mkdir conftest.dir; then
7944 cd conftest.dir
7945 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 7946 cat >Imakefile <<'_ACEOF'
98418dba
CW
7947acfindx:
7948 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 7949_ACEOF
98418dba
CW
7950 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7951 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7952 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7953 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7954 for ac_extension in a so sl; do
7955 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
edfaf76d
LK
7956 test -f $ac_im_libdir/libX11.$ac_extension; then
7957 ac_im_usrlibdir=$ac_im_libdir; break
98418dba
CW
7958 fi
7959 done
7960 # Screen out bogus values from the imake configuration. They are
7961 # bogus both because they are the default anyway, and because
7962 # using them would break gcc on systems where it needs fixed includes.
7963 case $ac_im_incroot in
7964 /usr/include) ;;
7965 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7966 esac
7967 case $ac_im_usrlibdir in
7968 /usr/lib | /lib) ;;
7969 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7970 esac
7971 fi
7972 cd ..
7973 rm -fr conftest.dir
7974fi
7975
7976# Standard set of common directories for X headers.
7977# Check X11 before X11Rn because it is often a symlink to the current release.
7978ac_x_header_dirs='
7979/usr/X11/include
7980/usr/X11R6/include
7981/usr/X11R5/include
7982/usr/X11R4/include
7983
7984/usr/include/X11
7985/usr/include/X11R6
7986/usr/include/X11R5
7987/usr/include/X11R4
7988
7989/usr/local/X11/include
7990/usr/local/X11R6/include
7991/usr/local/X11R5/include
7992/usr/local/X11R4/include
7993
7994/usr/local/include/X11
7995/usr/local/include/X11R6
7996/usr/local/include/X11R5
7997/usr/local/include/X11R4
7998
7999/usr/X386/include
8000/usr/x386/include
8001/usr/XFree86/include/X11
8002
8003/usr/include
8004/usr/local/include
8005/usr/unsupported/include
8006/usr/athena/include
8007/usr/local/x11r5/include
8008/usr/lpp/Xamples/include
8009
8010/usr/openwin/include
8011/usr/openwin/share/include'
8012
8013if test "$ac_x_includes" = no; then
10a3b1a1 8014 # Guess where to find include files, by looking for Intrinsic.h.
98418dba
CW
8015 # First, try using that file with no special directory specified.
8016 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8017/* confdefs.h. */
8018_ACEOF
8019cat confdefs.h >>conftest.$ac_ext
8020cat >>conftest.$ac_ext <<_ACEOF
8021/* end confdefs.h. */
98418dba
CW
8022#include <X11/Intrinsic.h>
8023_ACEOF
c0d27fcc 8024if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8025 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8026 ac_status=$?
6bae0ccf 8027 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8028 rm -f conftest.er1
8029 cat conftest.err >&5
c0d27fcc 8030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8031 (exit $ac_status); } >/dev/null; then
8032 if test -s conftest.err; then
8033 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 8034 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8035 else
8036 ac_cpp_err=
8037 fi
8038else
8039 ac_cpp_err=yes
8040fi
8041if test -z "$ac_cpp_err"; then
8042 # We can compile using X headers with no special include directory.
8043ac_x_includes=
8044else
8045 echo "$as_me: failed program was:" >&5
19650fd6
AS
8046sed 's/^/| /' conftest.$ac_ext >&5
8047
98418dba
CW
8048 for ac_dir in $ac_x_header_dirs; do
8049 if test -r "$ac_dir/X11/Intrinsic.h"; then
8050 ac_x_includes=$ac_dir
8051 break
8052 fi
8053done
8054fi
8055rm -f conftest.err conftest.$ac_ext
8056fi # $ac_x_includes = no
8057
8058if test "$ac_x_libraries" = no; then
8059 # Check for the libraries.
8060 # See if we find them without any special options.
8061 # Don't add to $LIBS permanently.
8062 ac_save_LIBS=$LIBS
8063 LIBS="-lXt $LIBS"
8064 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8065/* confdefs.h. */
8066_ACEOF
8067cat confdefs.h >>conftest.$ac_ext
8068cat >>conftest.$ac_ext <<_ACEOF
8069/* end confdefs.h. */
98418dba 8070#include <X11/Intrinsic.h>
98418dba
CW
8071int
8072main ()
8073{
8074XtMalloc (0)
8075 ;
8076 return 0;
8077}
8078_ACEOF
8079rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8080if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 8081 (eval $ac_link) 2>conftest.er1
98418dba 8082 ac_status=$?
edfaf76d
LK
8083 grep -v '^ *+' conftest.er1 >conftest.err
8084 rm -f conftest.er1
8085 cat conftest.err >&5
c0d27fcc 8086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8087 (exit $ac_status); } &&
10a3b1a1
EZ
8088 { ac_try='test -z "$ac_c_werror_flag"
8089 || test ! -s conftest.err'
edfaf76d
LK
8090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8091 (eval $ac_try) 2>&5
8092 ac_status=$?
8093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8094 (exit $ac_status); }; } &&
8095 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8097 (eval $ac_try) 2>&5
8098 ac_status=$?
c0d27fcc 8099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8100 (exit $ac_status); }; }; then
8101 LIBS=$ac_save_LIBS
8102# We can link X programs with no special library path.
8103ac_x_libraries=
8104else
8105 echo "$as_me: failed program was:" >&5
19650fd6
AS
8106sed 's/^/| /' conftest.$ac_ext >&5
8107
98418dba
CW
8108LIBS=$ac_save_LIBS
8109for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8110do
8111 # Don't even attempt the hair of trying to link an X program!
8112 for ac_extension in a so sl; do
8113 if test -r $ac_dir/libXt.$ac_extension; then
8114 ac_x_libraries=$ac_dir
8115 break 2
8116 fi
8117 done
8118done
8119fi
edfaf76d
LK
8120rm -f conftest.err conftest.$ac_objext \
8121 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8122fi # $ac_x_libraries = no
8123
8124if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
8125 # Didn't find X anywhere. Cache the known absence of X.
8126 ac_cv_have_x="have_x=no"
8127else
8128 # Record where we found X for the cache.
8129 ac_cv_have_x="have_x=yes \
edfaf76d 8130 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
98418dba
CW
8131fi
8132fi
8133
8134 fi
8135 eval "$ac_cv_have_x"
8136fi # $with_x != no
8137
8138if test "$have_x" != yes; then
c0d27fcc 8139 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
8140echo "${ECHO_T}$have_x" >&6
8141 no_x=yes
8142else
8143 # If each of the values was on the command line, it overrides each guess.
8144 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8145 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8146 # Update the cache value to reflect the command line values.
8147 ac_cv_have_x="have_x=yes \
8148 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
10a3b1a1
EZ
8149 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
8150echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
98418dba
CW
8151fi
8152
8153if test "$no_x" = yes; then
8154 window_system=none
8155else
8156 window_system=x11
8157fi
8158
8159if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8160 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
8161 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
8162 x_default_search_path=""
8163 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
8164 x_search_path="\
8165${x_library}/X11/%L/%T/%N%C%S:\
8166${x_library}/X11/%l/%T/%N%C%S:\
8167${x_library}/X11/%T/%N%C%S:\
8168${x_library}/X11/%L/%T/%N%S:\
8169${x_library}/X11/%l/%T/%N%S:\
8170${x_library}/X11/%T/%N%S"
8171 if test x"${x_default_search_path}" = x; then
8172 x_default_search_path=${x_search_path}
8173 else
8174 x_default_search_path="${x_search_path}:${x_default_search_path}"
8175 fi
8176 done
8177fi
8178if test "${x_includes}" != NONE && test -n "${x_includes}"; then
8179 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
8180fi
8181
8182if test x"${x_includes}" = x; then
8183 bitmapdir=/usr/include/X11/bitmaps
8184else
8185 # accumulate include directories that have X11 bitmap subdirectories
8186 bmd_acc="dummyval"
8187 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
8188 if test -d "${bmd}/X11/bitmaps"; then
8189 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
8190 fi
8191 if test -d "${bmd}/bitmaps"; then
8192 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
8193 fi
8194 done
8195 if test ${bmd_acc} != "dummyval"; then
8196 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
8197 fi
8198fi
8199
8200case "${window_system}" in
8201 x11 )
8202 HAVE_X_WINDOWS=yes
8203 HAVE_X11=yes
8204 case "${with_x_toolkit}" in
8205 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
8206 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
8207 gtk ) with_gtk=yes
8208 USE_X_TOOLKIT=none ;;
98418dba
CW
8209 no ) USE_X_TOOLKIT=none ;;
8210 * ) USE_X_TOOLKIT=maybe ;;
8211 esac
8212 ;;
8213 none )
8214 HAVE_X_WINDOWS=no
8215 HAVE_X11=no
8216 USE_X_TOOLKIT=none
8217 ;;
8218esac
8219
8220### If we're using X11, we should use the X menu package.
8221HAVE_MENUS=no
8222case ${HAVE_X11} in
8223 yes ) HAVE_MENUS=yes ;;
8224esac
8225
8226if test "${opsys}" = "hpux9"; then
8227 case "${x_libraries}" in
8228 *X11R4* )
8229 opsysfile="s/hpux9-x11r4.h"
8230 ;;
8231 esac
8232fi
8233
8234if test "${opsys}" = "hpux9shr"; then
8235 case "${x_libraries}" in
8236 *X11R4* )
8237 opsysfile="s/hpux9shxr4.h"
8238 ;;
8239 esac
8240fi
8241
5d6da11e
YM
8242HAVE_CARBON=no
8243if test "${HAVE_X11}" != "yes"; then
8244 if test "${with_carbon}" != "no"; then
8245 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
8246 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
8247echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
8248if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
8249 echo $ECHO_N "(cached) $ECHO_C" >&6
8250fi
8251echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
8252echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
8253else
8254 # Is the header compilable?
8255echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
8256echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
8257cat >conftest.$ac_ext <<_ACEOF
8258/* confdefs.h. */
8259_ACEOF
8260cat confdefs.h >>conftest.$ac_ext
8261cat >>conftest.$ac_ext <<_ACEOF
8262/* end confdefs.h. */
8263$ac_includes_default
8264#include <Carbon/Carbon.h>
8265_ACEOF
8266rm -f conftest.$ac_objext
8267if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 8268 (eval $ac_compile) 2>conftest.er1
5d6da11e 8269 ac_status=$?
edfaf76d
LK
8270 grep -v '^ *+' conftest.er1 >conftest.err
8271 rm -f conftest.er1
8272 cat conftest.err >&5
5d6da11e
YM
8273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8274 (exit $ac_status); } &&
10a3b1a1
EZ
8275 { ac_try='test -z "$ac_c_werror_flag"
8276 || test ! -s conftest.err'
edfaf76d
LK
8277 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8278 (eval $ac_try) 2>&5
8279 ac_status=$?
8280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8281 (exit $ac_status); }; } &&
8282 { ac_try='test -s conftest.$ac_objext'
5d6da11e
YM
8283 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8284 (eval $ac_try) 2>&5
8285 ac_status=$?
8286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8287 (exit $ac_status); }; }; then
8288 ac_header_compiler=yes
8289else
8290 echo "$as_me: failed program was:" >&5
8291sed 's/^/| /' conftest.$ac_ext >&5
8292
8293ac_header_compiler=no
8294fi
edfaf76d 8295rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
5d6da11e
YM
8296echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8297echo "${ECHO_T}$ac_header_compiler" >&6
8298
8299# Is the header present?
8300echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
8301echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
8302cat >conftest.$ac_ext <<_ACEOF
8303/* confdefs.h. */
8304_ACEOF
8305cat confdefs.h >>conftest.$ac_ext
8306cat >>conftest.$ac_ext <<_ACEOF
8307/* end confdefs.h. */
8308#include <Carbon/Carbon.h>
8309_ACEOF
8310if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8311 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8312 ac_status=$?
8313 grep -v '^ *+' conftest.er1 >conftest.err
8314 rm -f conftest.er1
8315 cat conftest.err >&5
8316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8317 (exit $ac_status); } >/dev/null; then
8318 if test -s conftest.err; then
8319 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 8320 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
5d6da11e
YM
8321 else
8322 ac_cpp_err=
8323 fi
8324else
8325 ac_cpp_err=yes
8326fi
8327if test -z "$ac_cpp_err"; then
8328 ac_header_preproc=yes
8329else
8330 echo "$as_me: failed program was:" >&5
8331sed 's/^/| /' conftest.$ac_ext >&5
8332
8333 ac_header_preproc=no
8334fi
8335rm -f conftest.err conftest.$ac_ext
8336echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8337echo "${ECHO_T}$ac_header_preproc" >&6
8338
8339# So? What about this header?
edfaf76d
LK
8340case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8341 yes:no: )
5d6da11e
YM
8342 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
8343echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
8344 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&5
8345echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&2;}
8346 ac_header_preproc=yes
5d6da11e 8347 ;;
edfaf76d 8348 no:yes:* )
5d6da11e
YM
8349 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
8350echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
edfaf76d
LK
8351 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
8352echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
8353 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&5
8354echo "$as_me: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&2;}
8355 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&5
8356echo "$as_me: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&2;}
5d6da11e
YM
8357 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
8358echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
8359 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&5
8360echo "$as_me: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&2;}
5d6da11e
YM
8361 (
8362 cat <<\_ASBOX
edfaf76d
LK
8363## ------------------------------------------ ##
8364## Report this to the AC_PACKAGE_NAME lists. ##
8365## ------------------------------------------ ##
5d6da11e
YM
8366_ASBOX
8367 ) |
8368 sed "s/^/$as_me: WARNING: /" >&2
8369 ;;
8370esac
8371echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
8372echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
8373if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
8374 echo $ECHO_N "(cached) $ECHO_C" >&6
8375else
8376 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
8377fi
8378echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
8379echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
8380
8381fi
8382if test $ac_cv_header_Carbon_Carbon_h = yes; then
8383 HAVE_CARBON=yes
8384fi
8385
8386
8387 fi
8388fi
8389
98418dba
CW
8390### Compute the unexec source name from the object name.
8391UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
8392
8393# Do the opsystem or machine files prohibit the use of the GNU malloc?
8394# Assume not, until told otherwise.
8395GNU_MALLOC=yes
8396doug_lea_malloc=yes
c0d27fcc 8397echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
8398echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
8399if test "${ac_cv_func_malloc_get_state+set}" = set; then
8400 echo $ECHO_N "(cached) $ECHO_C" >&6
8401else
8402 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8403/* confdefs.h. */
8404_ACEOF
8405cat confdefs.h >>conftest.$ac_ext
8406cat >>conftest.$ac_ext <<_ACEOF
8407/* end confdefs.h. */
edfaf76d
LK
8408/* Define malloc_get_state to an innocuous variant, in case <limits.h> declares malloc_get_state.
8409 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8410#define malloc_get_state innocuous_malloc_get_state
8411
98418dba 8412/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8413 which can conflict with char malloc_get_state (); below.
8414 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8415 <limits.h> exists even on freestanding compilers. */
edfaf76d 8416
19650fd6
AS
8417#ifdef __STDC__
8418# include <limits.h>
8419#else
8420# include <assert.h>
8421#endif
edfaf76d
LK
8422
8423#undef malloc_get_state
8424
98418dba
CW
8425/* Override any gcc2 internal prototype to avoid an error. */
8426#ifdef __cplusplus
8427extern "C"
19650fd6 8428{
98418dba
CW
8429#endif
8430/* We use char because int might match the return type of a gcc2
8431 builtin and then its argument prototype would still apply. */
8432char malloc_get_state ();
98418dba
CW
8433/* The GNU C library defines this for functions which it implements
8434 to always fail with ENOSYS. Some functions are actually named
8435 something starting with __ and the normal name is an alias. */
8436#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
8437choke me
8438#else
19650fd6
AS
8439char (*f) () = malloc_get_state;
8440#endif
8441#ifdef __cplusplus
8442}
98418dba
CW
8443#endif
8444
19650fd6
AS
8445int
8446main ()
8447{
8448return f != malloc_get_state;
98418dba
CW
8449 ;
8450 return 0;
8451}
8452_ACEOF
8453rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8454if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 8455 (eval $ac_link) 2>conftest.er1
98418dba 8456 ac_status=$?
edfaf76d
LK
8457 grep -v '^ *+' conftest.er1 >conftest.err
8458 rm -f conftest.er1
8459 cat conftest.err >&5
c0d27fcc 8460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8461 (exit $ac_status); } &&
10a3b1a1
EZ
8462 { ac_try='test -z "$ac_c_werror_flag"
8463 || test ! -s conftest.err'
edfaf76d
LK
8464 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8465 (eval $ac_try) 2>&5
8466 ac_status=$?
8467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8468 (exit $ac_status); }; } &&
8469 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8470 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8471 (eval $ac_try) 2>&5
8472 ac_status=$?
c0d27fcc 8473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8474 (exit $ac_status); }; }; then
8475 ac_cv_func_malloc_get_state=yes
8476else
8477 echo "$as_me: failed program was:" >&5
19650fd6
AS
8478sed 's/^/| /' conftest.$ac_ext >&5
8479
98418dba
CW
8480ac_cv_func_malloc_get_state=no
8481fi
edfaf76d
LK
8482rm -f conftest.err conftest.$ac_objext \
8483 conftest$ac_exeext conftest.$ac_ext
98418dba 8484fi
c0d27fcc 8485echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
8486echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
8487if test $ac_cv_func_malloc_get_state = yes; then
8488 :
8489else
8490 doug_lea_malloc=no
8491fi
8492
c0d27fcc 8493echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
8494echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
8495if test "${ac_cv_func_malloc_set_state+set}" = set; then
8496 echo $ECHO_N "(cached) $ECHO_C" >&6
8497else
8498 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8499/* confdefs.h. */
8500_ACEOF
8501cat confdefs.h >>conftest.$ac_ext
8502cat >>conftest.$ac_ext <<_ACEOF
8503/* end confdefs.h. */
edfaf76d
LK
8504/* Define malloc_set_state to an innocuous variant, in case <limits.h> declares malloc_set_state.
8505 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8506#define malloc_set_state innocuous_malloc_set_state
8507
98418dba 8508/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8509 which can conflict with char malloc_set_state (); below.
8510 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8511 <limits.h> exists even on freestanding compilers. */
edfaf76d 8512
19650fd6
AS
8513#ifdef __STDC__
8514# include <limits.h>
8515#else
8516# include <assert.h>
8517#endif
edfaf76d
LK
8518
8519#undef malloc_set_state
8520
98418dba
CW
8521/* Override any gcc2 internal prototype to avoid an error. */
8522#ifdef __cplusplus
8523extern "C"
19650fd6 8524{
98418dba
CW
8525#endif
8526/* We use char because int might match the return type of a gcc2
8527 builtin and then its argument prototype would still apply. */
8528char malloc_set_state ();
98418dba
CW
8529/* The GNU C library defines this for functions which it implements
8530 to always fail with ENOSYS. Some functions are actually named
8531 something starting with __ and the normal name is an alias. */
8532#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
8533choke me
8534#else
19650fd6
AS
8535char (*f) () = malloc_set_state;
8536#endif
8537#ifdef __cplusplus
8538}
98418dba
CW
8539#endif
8540
19650fd6
AS
8541int
8542main ()
8543{
8544return f != malloc_set_state;
98418dba
CW
8545 ;
8546 return 0;
8547}
8548_ACEOF
8549rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8550if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 8551 (eval $ac_link) 2>conftest.er1
98418dba 8552 ac_status=$?
edfaf76d
LK
8553 grep -v '^ *+' conftest.er1 >conftest.err
8554 rm -f conftest.er1
8555 cat conftest.err >&5
c0d27fcc 8556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8557 (exit $ac_status); } &&
10a3b1a1
EZ
8558 { ac_try='test -z "$ac_c_werror_flag"
8559 || test ! -s conftest.err'
edfaf76d
LK
8560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8561 (eval $ac_try) 2>&5
8562 ac_status=$?
8563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8564 (exit $ac_status); }; } &&
8565 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8566 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8567 (eval $ac_try) 2>&5
8568 ac_status=$?
c0d27fcc 8569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8570 (exit $ac_status); }; }; then
8571 ac_cv_func_malloc_set_state=yes
8572else
8573 echo "$as_me: failed program was:" >&5
19650fd6
AS
8574sed 's/^/| /' conftest.$ac_ext >&5
8575
98418dba
CW
8576ac_cv_func_malloc_set_state=no
8577fi
edfaf76d
LK
8578rm -f conftest.err conftest.$ac_objext \
8579 conftest$ac_exeext conftest.$ac_ext
98418dba 8580fi
c0d27fcc 8581echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
8582echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
8583if test $ac_cv_func_malloc_set_state = yes; then
8584 :
8585else
8586 doug_lea_malloc=no
8587fi
8588
c0d27fcc 8589echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
8590echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
8591if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
8592 echo $ECHO_N "(cached) $ECHO_C" >&6
8593else
8594 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8595/* confdefs.h. */
8596_ACEOF
8597cat confdefs.h >>conftest.$ac_ext
8598cat >>conftest.$ac_ext <<_ACEOF
8599/* end confdefs.h. */
98418dba 8600extern void (* __after_morecore_hook)();
98418dba
CW
8601int
8602main ()
8603{
8604__after_morecore_hook = 0
8605 ;
8606 return 0;
8607}
8608_ACEOF
8609rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8610if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 8611 (eval $ac_link) 2>conftest.er1
98418dba 8612 ac_status=$?
edfaf76d
LK
8613 grep -v '^ *+' conftest.er1 >conftest.err
8614 rm -f conftest.er1
8615 cat conftest.err >&5
c0d27fcc 8616 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8617 (exit $ac_status); } &&
10a3b1a1
EZ
8618 { ac_try='test -z "$ac_c_werror_flag"
8619 || test ! -s conftest.err'
edfaf76d
LK
8620 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8621 (eval $ac_try) 2>&5
8622 ac_status=$?
8623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8624 (exit $ac_status); }; } &&
8625 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8626 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8627 (eval $ac_try) 2>&5
8628 ac_status=$?
c0d27fcc 8629 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8630 (exit $ac_status); }; }; then
8631 emacs_cv_var___after_morecore_hook=yes
8632else
8633 echo "$as_me: failed program was:" >&5
19650fd6
AS
8634sed 's/^/| /' conftest.$ac_ext >&5
8635
98418dba
CW
8636emacs_cv_var___after_morecore_hook=no
8637fi
edfaf76d
LK
8638rm -f conftest.err conftest.$ac_objext \
8639 conftest$ac_exeext conftest.$ac_ext
98418dba 8640fi
c0d27fcc 8641echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
8642echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
8643if test $emacs_cv_var___after_morecore_hook = no; then
8644 doug_lea_malloc=no
8645fi
8646if test "${system_malloc}" = "yes"; then
8647 GNU_MALLOC=no
8648 GNU_MALLOC_reason="
8649 (The GNU allocators don't work with this system configuration.)"
8650fi
8651if test "$doug_lea_malloc" = "yes" ; then
8652 if test "$GNU_MALLOC" = yes ; then
8653 GNU_MALLOC_reason="
8654 (Using Doug Lea's new malloc from the GNU C Library.)"
8655 fi
b936fae4 8656
c0d27fcc 8657cat >>confdefs.h <<\_ACEOF
98418dba 8658#define DOUG_LEA_MALLOC 1
c0d27fcc 8659_ACEOF
98418dba
CW
8660
8661fi
8662
8663if test x"${REL_ALLOC}" = x; then
8664 REL_ALLOC=${GNU_MALLOC}
8665fi
8666
8667
c0d27fcc
MR
8668
8669
8670for ac_header in stdlib.h unistd.h
98418dba
CW
8671do
8672as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
8673if eval "test \"\${$as_ac_Header+set}\" = set"; then
8674 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
8675echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8676if eval "test \"\${$as_ac_Header+set}\" = set"; then
8677 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8678fi
8679echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8680echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 8681else
c0d27fcc
MR
8682 # Is the header compilable?
8683echo "$as_me:$LINENO: checking $ac_header usability" >&5
8684echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8685cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8686/* confdefs.h. */
8687_ACEOF
8688cat confdefs.h >>conftest.$ac_ext
8689cat >>conftest.$ac_ext <<_ACEOF
8690/* end confdefs.h. */
98418dba
CW
8691$ac_includes_default
8692#include <$ac_header>
8693_ACEOF
8694rm -f conftest.$ac_objext
c0d27fcc 8695if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 8696 (eval $ac_compile) 2>conftest.er1
98418dba 8697 ac_status=$?
edfaf76d
LK
8698 grep -v '^ *+' conftest.er1 >conftest.err
8699 rm -f conftest.er1
8700 cat conftest.err >&5
c0d27fcc 8701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8702 (exit $ac_status); } &&
10a3b1a1
EZ
8703 { ac_try='test -z "$ac_c_werror_flag"
8704 || test ! -s conftest.err'
edfaf76d
LK
8705 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8706 (eval $ac_try) 2>&5
8707 ac_status=$?
8708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8709 (exit $ac_status); }; } &&
8710 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8711 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8712 (eval $ac_try) 2>&5
8713 ac_status=$?
c0d27fcc 8714 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8715 (exit $ac_status); }; }; then
c0d27fcc 8716 ac_header_compiler=yes
98418dba
CW
8717else
8718 echo "$as_me: failed program was:" >&5
19650fd6
AS
8719sed 's/^/| /' conftest.$ac_ext >&5
8720
c0d27fcc 8721ac_header_compiler=no
98418dba 8722fi
edfaf76d 8723rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
8724echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8725echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 8726
c0d27fcc
MR
8727# Is the header present?
8728echo "$as_me:$LINENO: checking $ac_header presence" >&5
8729echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8730cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8731/* confdefs.h. */
8732_ACEOF
8733cat confdefs.h >>conftest.$ac_ext
8734cat >>conftest.$ac_ext <<_ACEOF
8735/* end confdefs.h. */
98418dba
CW
8736#include <$ac_header>
8737_ACEOF
c0d27fcc 8738if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8739 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8740 ac_status=$?
6bae0ccf 8741 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8742 rm -f conftest.er1
8743 cat conftest.err >&5
c0d27fcc 8744 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8745 (exit $ac_status); } >/dev/null; then
8746 if test -s conftest.err; then
8747 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 8748 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8749 else
8750 ac_cpp_err=
8751 fi
8752else
8753 ac_cpp_err=yes
8754fi
8755if test -z "$ac_cpp_err"; then
c0d27fcc 8756 ac_header_preproc=yes
98418dba
CW
8757else
8758 echo "$as_me: failed program was:" >&5
19650fd6
AS
8759sed 's/^/| /' conftest.$ac_ext >&5
8760
c0d27fcc 8761 ac_header_preproc=no
98418dba
CW
8762fi
8763rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8764echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8765echo "${ECHO_T}$ac_header_preproc" >&6
8766
8767# So? What about this header?
edfaf76d
LK
8768case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8769 yes:no: )
c0d27fcc
MR
8770 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8771echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
8772 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8773echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8774 ac_header_preproc=yes
8775 ;;
8776 no:yes:* )
8777 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8778echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8779 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8780echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8781 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8782echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8783 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
8784echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
7c9e5167
JD
8785 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8786echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
8787 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8788echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7c9e5167
JD
8789 (
8790 cat <<\_ASBOX
edfaf76d
LK
8791## ------------------------------------------ ##
8792## Report this to the AC_PACKAGE_NAME lists. ##
8793## ------------------------------------------ ##
19650fd6
AS
8794_ASBOX
8795 ) |
8796 sed "s/^/$as_me: WARNING: /" >&2
8797 ;;
c0d27fcc
MR
8798esac
8799echo "$as_me:$LINENO: checking for $ac_header" >&5
8800echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8801if eval "test \"\${$as_ac_Header+set}\" = set"; then
8802 echo $ECHO_N "(cached) $ECHO_C" >&6
8803else
edfaf76d 8804 eval "$as_ac_Header=\$ac_header_preproc"
98418dba 8805fi
c0d27fcc 8806echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 8807echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
8808
8809fi
98418dba 8810if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 8811 cat >>confdefs.h <<_ACEOF
98418dba 8812#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 8813_ACEOF
98418dba
CW
8814
8815fi
c0d27fcc 8816
98418dba
CW
8817done
8818
c0d27fcc 8819
98418dba
CW
8820for ac_func in getpagesize
8821do
8822as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8823echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8824echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8825if eval "test \"\${$as_ac_var+set}\" = set"; then
8826 echo $ECHO_N "(cached) $ECHO_C" >&6
8827else
8828 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8829/* confdefs.h. */
8830_ACEOF
8831cat confdefs.h >>conftest.$ac_ext
8832cat >>conftest.$ac_ext <<_ACEOF
8833/* end confdefs.h. */
edfaf76d
LK
8834/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8835 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8836#define $ac_func innocuous_$ac_func
8837
98418dba 8838/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8839 which can conflict with char $ac_func (); below.
8840 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8841 <limits.h> exists even on freestanding compilers. */
edfaf76d 8842
19650fd6
AS
8843#ifdef __STDC__
8844# include <limits.h>
8845#else
8846# include <assert.h>
8847#endif
edfaf76d
LK
8848
8849#undef $ac_func
8850
98418dba
CW
8851/* Override any gcc2 internal prototype to avoid an error. */
8852#ifdef __cplusplus
8853extern "C"
19650fd6 8854{
98418dba
CW
8855#endif
8856/* We use char because int might match the return type of a gcc2
8857 builtin and then its argument prototype would still apply. */
8858char $ac_func ();
98418dba
CW
8859/* The GNU C library defines this for functions which it implements
8860 to always fail with ENOSYS. Some functions are actually named
8861 something starting with __ and the normal name is an alias. */
8862#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8863choke me
8864#else
19650fd6
AS
8865char (*f) () = $ac_func;
8866#endif
8867#ifdef __cplusplus
8868}
98418dba
CW
8869#endif
8870
19650fd6
AS
8871int
8872main ()
8873{
8874return f != $ac_func;
98418dba
CW
8875 ;
8876 return 0;
8877}
8878_ACEOF
8879rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8880if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 8881 (eval $ac_link) 2>conftest.er1
98418dba 8882 ac_status=$?
edfaf76d
LK
8883 grep -v '^ *+' conftest.er1 >conftest.err
8884 rm -f conftest.er1
8885 cat conftest.err >&5
c0d27fcc 8886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8887 (exit $ac_status); } &&
10a3b1a1
EZ
8888 { ac_try='test -z "$ac_c_werror_flag"
8889 || test ! -s conftest.err'
edfaf76d
LK
8890 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8891 (eval $ac_try) 2>&5
8892 ac_status=$?
8893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8894 (exit $ac_status); }; } &&
8895 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8897 (eval $ac_try) 2>&5
8898 ac_status=$?
c0d27fcc 8899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8900 (exit $ac_status); }; }; then
8901 eval "$as_ac_var=yes"
8902else
8903 echo "$as_me: failed program was:" >&5
19650fd6
AS
8904sed 's/^/| /' conftest.$ac_ext >&5
8905
98418dba
CW
8906eval "$as_ac_var=no"
8907fi
edfaf76d
LK
8908rm -f conftest.err conftest.$ac_objext \
8909 conftest$ac_exeext conftest.$ac_ext
98418dba 8910fi
c0d27fcc 8911echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
8912echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8913if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 8914 cat >>confdefs.h <<_ACEOF
98418dba 8915#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 8916_ACEOF
98418dba
CW
8917
8918fi
8919done
8920
c0d27fcc 8921echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
8922echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
8923if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8924 echo $ECHO_N "(cached) $ECHO_C" >&6
8925else
8926 if test "$cross_compiling" = yes; then
8927 ac_cv_func_mmap_fixed_mapped=no
8928else
8929 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8930/* confdefs.h. */
8931_ACEOF
8932cat confdefs.h >>conftest.$ac_ext
8933cat >>conftest.$ac_ext <<_ACEOF
8934/* end confdefs.h. */
98418dba 8935$ac_includes_default
c0d27fcc
MR
8936/* malloc might have been renamed as rpl_malloc. */
8937#undef malloc
8938
98418dba
CW
8939/* Thanks to Mike Haertel and Jim Avera for this test.
8940 Here is a matrix of mmap possibilities:
8941 mmap private not fixed
8942 mmap private fixed at somewhere currently unmapped
8943 mmap private fixed at somewhere already mapped
8944 mmap shared not fixed
8945 mmap shared fixed at somewhere currently unmapped
8946 mmap shared fixed at somewhere already mapped
8947 For private mappings, we should verify that changes cannot be read()
8948 back from the file, nor mmap's back from the file at a different
8949 address. (There have been systems where private was not correctly
8950 implemented like the infamous i386 svr4.0, and systems where the
8951 VM page cache was not coherent with the file system buffer cache
8952 like early versions of FreeBSD and possibly contemporary NetBSD.)
8953 For shared mappings, we should conversely verify that changes get
c0d27fcc 8954 propagated back to all the places they're supposed to be.
98418dba
CW
8955
8956 Grep wants private fixed already mapped.
8957 The main things grep needs to know about mmap are:
8958 * does it exist and is it safe to write into the mmap'd area
8959 * how to use it (BSD variants) */
8960
8961#include <fcntl.h>
8962#include <sys/mman.h>
8963
8964#if !STDC_HEADERS && !HAVE_STDLIB_H
8965char *malloc ();
8966#endif
8967
8968/* This mess was copied from the GNU getpagesize.h. */
8969#if !HAVE_GETPAGESIZE
8970/* Assume that all systems that can run configure have sys/param.h. */
8971# if !HAVE_SYS_PARAM_H
8972# define HAVE_SYS_PARAM_H 1
8973# endif
8974
8975# ifdef _SC_PAGESIZE
8976# define getpagesize() sysconf(_SC_PAGESIZE)
8977# else /* no _SC_PAGESIZE */
8978# if HAVE_SYS_PARAM_H
8979# include <sys/param.h>
8980# ifdef EXEC_PAGESIZE
8981# define getpagesize() EXEC_PAGESIZE
8982# else /* no EXEC_PAGESIZE */
8983# ifdef NBPG
8984# define getpagesize() NBPG * CLSIZE
8985# ifndef CLSIZE
8986# define CLSIZE 1
8987# endif /* no CLSIZE */
8988# else /* no NBPG */
8989# ifdef NBPC
8990# define getpagesize() NBPC
8991# else /* no NBPC */
8992# ifdef PAGESIZE
8993# define getpagesize() PAGESIZE
8994# endif /* PAGESIZE */
8995# endif /* no NBPC */
8996# endif /* no NBPG */
8997# endif /* no EXEC_PAGESIZE */
8998# else /* no HAVE_SYS_PARAM_H */
8999# define getpagesize() 8192 /* punt totally */
9000# endif /* no HAVE_SYS_PARAM_H */
9001# endif /* no _SC_PAGESIZE */
9002
9003#endif /* no HAVE_GETPAGESIZE */
9004
9005int
9006main ()
9007{
9008 char *data, *data2, *data3;
9009 int i, pagesize;
9010 int fd;
9011
9012 pagesize = getpagesize ();
9013
9014 /* First, make a file with some known garbage in it. */
9015 data = (char *) malloc (pagesize);
9016 if (!data)
9017 exit (1);
9018 for (i = 0; i < pagesize; ++i)
9019 *(data + i) = rand ();
9020 umask (0);
9021 fd = creat ("conftest.mmap", 0600);
9022 if (fd < 0)
9023 exit (1);
9024 if (write (fd, data, pagesize) != pagesize)
9025 exit (1);
9026 close (fd);
9027
9028 /* Next, try to mmap the file at a fixed address which already has
9029 something else allocated at it. If we can, also make sure that
9030 we see the same garbage. */
9031 fd = open ("conftest.mmap", O_RDWR);
9032 if (fd < 0)
9033 exit (1);
9034 data2 = (char *) malloc (2 * pagesize);
9035 if (!data2)
9036 exit (1);
edfaf76d 9037 data2 += (pagesize - ((long) data2 & (pagesize - 1))) & (pagesize - 1);
98418dba 9038 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
edfaf76d 9039 MAP_PRIVATE | MAP_FIXED, fd, 0L))
98418dba
CW
9040 exit (1);
9041 for (i = 0; i < pagesize; ++i)
9042 if (*(data + i) != *(data2 + i))
9043 exit (1);
9044
9045 /* Finally, make sure that changes to the mapped area do not
9046 percolate back to the file as seen by read(). (This is a bug on
9047 some variants of i386 svr4.0.) */
9048 for (i = 0; i < pagesize; ++i)
9049 *(data2 + i) = *(data2 + i) + 1;
9050 data3 = (char *) malloc (pagesize);
9051 if (!data3)
9052 exit (1);
9053 if (read (fd, data3, pagesize) != pagesize)
9054 exit (1);
9055 for (i = 0; i < pagesize; ++i)
9056 if (*(data + i) != *(data3 + i))
9057 exit (1);
9058 close (fd);
9059 exit (0);
9060}
9061_ACEOF
9062rm -f conftest$ac_exeext
c0d27fcc 9063if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
9064 (eval $ac_link) 2>&5
9065 ac_status=$?
c0d27fcc 9066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9067 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 9068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9069 (eval $ac_try) 2>&5
9070 ac_status=$?
c0d27fcc 9071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9072 (exit $ac_status); }; }; then
9073 ac_cv_func_mmap_fixed_mapped=yes
9074else
9075 echo "$as_me: program exited with status $ac_status" >&5
9076echo "$as_me: failed program was:" >&5
19650fd6
AS
9077sed 's/^/| /' conftest.$ac_ext >&5
9078
c0d27fcc 9079( exit $ac_status )
98418dba
CW
9080ac_cv_func_mmap_fixed_mapped=no
9081fi
edfaf76d 9082rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
9083fi
9084fi
c0d27fcc 9085echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
9086echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
9087if test $ac_cv_func_mmap_fixed_mapped = yes; then
9088
c0d27fcc 9089cat >>confdefs.h <<\_ACEOF
98418dba 9090#define HAVE_MMAP 1
c0d27fcc 9091_ACEOF
98418dba
CW
9092
9093fi
9094rm -f conftest.mmap
9095
9096if test $use_mmap_for_buffers = yes; then
9097 REL_ALLOC=no
9098fi
9099
9100LIBS="$libsrc_libs $LIBS"
9101
c0d27fcc
MR
9102
9103echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
9104echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9105if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9106 echo $ECHO_N "(cached) $ECHO_C" >&6
9107else
9108 ac_check_lib_save_LIBS=$LIBS
9109LIBS="-ldnet $LIBS"
9110cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9111/* confdefs.h. */
9112_ACEOF
9113cat confdefs.h >>conftest.$ac_ext
9114cat >>conftest.$ac_ext <<_ACEOF
9115/* end confdefs.h. */
98418dba
CW
9116
9117/* Override any gcc2 internal prototype to avoid an error. */
9118#ifdef __cplusplus
9119extern "C"
9120#endif
9121/* We use char because int might match the return type of a gcc2
9122 builtin and then its argument prototype would still apply. */
9123char dnet_ntoa ();
98418dba
CW
9124int
9125main ()
9126{
9127dnet_ntoa ();
9128 ;
9129 return 0;
9130}
9131_ACEOF
9132rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9133if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9134 (eval $ac_link) 2>conftest.er1
98418dba 9135 ac_status=$?
edfaf76d
LK
9136 grep -v '^ *+' conftest.er1 >conftest.err
9137 rm -f conftest.er1
9138 cat conftest.err >&5
c0d27fcc 9139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9140 (exit $ac_status); } &&
10a3b1a1
EZ
9141 { ac_try='test -z "$ac_c_werror_flag"
9142 || test ! -s conftest.err'
edfaf76d
LK
9143 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9144 (eval $ac_try) 2>&5
9145 ac_status=$?
9146 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9147 (exit $ac_status); }; } &&
9148 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9149 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9150 (eval $ac_try) 2>&5
9151 ac_status=$?
c0d27fcc 9152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9153 (exit $ac_status); }; }; then
9154 ac_cv_lib_dnet_dnet_ntoa=yes
9155else
9156 echo "$as_me: failed program was:" >&5
19650fd6
AS
9157sed 's/^/| /' conftest.$ac_ext >&5
9158
98418dba
CW
9159ac_cv_lib_dnet_dnet_ntoa=no
9160fi
edfaf76d
LK
9161rm -f conftest.err conftest.$ac_objext \
9162 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9163LIBS=$ac_check_lib_save_LIBS
9164fi
c0d27fcc 9165echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
9166echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9167if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 9168 cat >>confdefs.h <<_ACEOF
98418dba 9169#define HAVE_LIBDNET 1
c0d27fcc 9170_ACEOF
98418dba
CW
9171
9172 LIBS="-ldnet $LIBS"
9173
9174fi
9175
c0d27fcc
MR
9176
9177echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
9178echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
9179if test "${ac_cv_lib_Xbsd_main+set}" = set; then
9180 echo $ECHO_N "(cached) $ECHO_C" >&6
9181else
9182 ac_check_lib_save_LIBS=$LIBS
9183LIBS="-lXbsd $LIBS"
9184cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9185/* confdefs.h. */
9186_ACEOF
9187cat confdefs.h >>conftest.$ac_ext
9188cat >>conftest.$ac_ext <<_ACEOF
9189/* end confdefs.h. */
98418dba 9190
c0d27fcc 9191
98418dba
CW
9192int
9193main ()
9194{
9195main ();
9196 ;
9197 return 0;
9198}
9199_ACEOF
9200rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9201if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9202 (eval $ac_link) 2>conftest.er1
98418dba 9203 ac_status=$?
edfaf76d
LK
9204 grep -v '^ *+' conftest.er1 >conftest.err
9205 rm -f conftest.er1
9206 cat conftest.err >&5
c0d27fcc 9207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9208 (exit $ac_status); } &&
10a3b1a1
EZ
9209 { ac_try='test -z "$ac_c_werror_flag"
9210 || test ! -s conftest.err'
edfaf76d
LK
9211 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9212 (eval $ac_try) 2>&5
9213 ac_status=$?
9214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9215 (exit $ac_status); }; } &&
9216 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9218 (eval $ac_try) 2>&5
9219 ac_status=$?
c0d27fcc 9220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9221 (exit $ac_status); }; }; then
9222 ac_cv_lib_Xbsd_main=yes
9223else
9224 echo "$as_me: failed program was:" >&5
19650fd6
AS
9225sed 's/^/| /' conftest.$ac_ext >&5
9226
98418dba
CW
9227ac_cv_lib_Xbsd_main=no
9228fi
edfaf76d
LK
9229rm -f conftest.err conftest.$ac_objext \
9230 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9231LIBS=$ac_check_lib_save_LIBS
9232fi
c0d27fcc 9233echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
9234echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
9235if test $ac_cv_lib_Xbsd_main = yes; then
9236 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9237fi
9238
c0d27fcc
MR
9239
9240
9241echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
9242echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
9243if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
9244 echo $ECHO_N "(cached) $ECHO_C" >&6
9245else
9246 ac_check_lib_save_LIBS=$LIBS
9247LIBS="-lpthreads $LIBS"
9248cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9249/* confdefs.h. */
9250_ACEOF
9251cat confdefs.h >>conftest.$ac_ext
9252cat >>conftest.$ac_ext <<_ACEOF
9253/* end confdefs.h. */
98418dba
CW
9254
9255/* Override any gcc2 internal prototype to avoid an error. */
9256#ifdef __cplusplus
9257extern "C"
9258#endif
9259/* We use char because int might match the return type of a gcc2
9260 builtin and then its argument prototype would still apply. */
9261char cma_open ();
98418dba
CW
9262int
9263main ()
9264{
9265cma_open ();
9266 ;
9267 return 0;
9268}
9269_ACEOF
9270rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9271if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9272 (eval $ac_link) 2>conftest.er1
98418dba 9273 ac_status=$?
edfaf76d
LK
9274 grep -v '^ *+' conftest.er1 >conftest.err
9275 rm -f conftest.er1
9276 cat conftest.err >&5
c0d27fcc 9277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9278 (exit $ac_status); } &&
10a3b1a1
EZ
9279 { ac_try='test -z "$ac_c_werror_flag"
9280 || test ! -s conftest.err'
edfaf76d
LK
9281 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9282 (eval $ac_try) 2>&5
9283 ac_status=$?
9284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9285 (exit $ac_status); }; } &&
9286 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9288 (eval $ac_try) 2>&5
9289 ac_status=$?
c0d27fcc 9290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9291 (exit $ac_status); }; }; then
9292 ac_cv_lib_pthreads_cma_open=yes
9293else
9294 echo "$as_me: failed program was:" >&5
19650fd6
AS
9295sed 's/^/| /' conftest.$ac_ext >&5
9296
98418dba
CW
9297ac_cv_lib_pthreads_cma_open=no
9298fi
edfaf76d
LK
9299rm -f conftest.err conftest.$ac_objext \
9300 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9301LIBS=$ac_check_lib_save_LIBS
9302fi
c0d27fcc 9303echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
9304echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
9305if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 9306 cat >>confdefs.h <<_ACEOF
98418dba 9307#define HAVE_LIBPTHREADS 1
c0d27fcc 9308_ACEOF
98418dba
CW
9309
9310 LIBS="-lpthreads $LIBS"
9311
9312fi
9313
c0d27fcc
MR
9314
9315echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
9316echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
9317if test -d /usr/X386/include; then
9318 HAVE_XFREE386=yes
9319 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
9320else
9321 HAVE_XFREE386=no
9322fi
c0d27fcc 9323echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
9324echo "${ECHO_T}$HAVE_XFREE386" >&6
9325
55597d70
DL
9326
9327case ${host_os} in
9328aix*)
9329 echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
9330echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
9331if test "${gdb_cv_bigtoc+set}" = set; then
9332 echo $ECHO_N "(cached) $ECHO_C" >&6
9333else
9334
9335 case $GCC in
9336 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
9337 *) gdb_cv_bigtoc=-bbigtoc ;;
9338 esac
9339
9340 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
9341 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9342/* confdefs.h. */
9343_ACEOF
9344cat confdefs.h >>conftest.$ac_ext
9345cat >>conftest.$ac_ext <<_ACEOF
9346/* end confdefs.h. */
55597d70
DL
9347
9348int
9349main ()
9350{
9351int i;
9352 ;
9353 return 0;
9354}
9355_ACEOF
9356rm -f conftest.$ac_objext conftest$ac_exeext
9357if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9358 (eval $ac_link) 2>conftest.er1
55597d70 9359 ac_status=$?
edfaf76d
LK
9360 grep -v '^ *+' conftest.er1 >conftest.err
9361 rm -f conftest.er1
9362 cat conftest.err >&5
55597d70
DL
9363 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9364 (exit $ac_status); } &&
10a3b1a1
EZ
9365 { ac_try='test -z "$ac_c_werror_flag"
9366 || test ! -s conftest.err'
edfaf76d
LK
9367 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9368 (eval $ac_try) 2>&5
9369 ac_status=$?
9370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9371 (exit $ac_status); }; } &&
9372 { ac_try='test -s conftest$ac_exeext'
55597d70
DL
9373 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9374 (eval $ac_try) 2>&5
9375 ac_status=$?
9376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9377 (exit $ac_status); }; }; then
9378 :
9379else
9380 echo "$as_me: failed program was:" >&5
19650fd6
AS
9381sed 's/^/| /' conftest.$ac_ext >&5
9382
55597d70
DL
9383gdb_cv_bigtoc=
9384fi
edfaf76d
LK
9385rm -f conftest.err conftest.$ac_objext \
9386 conftest$ac_exeext conftest.$ac_ext
55597d70
DL
9387
9388fi
9389echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
9390echo "${ECHO_T}$gdb_cv_bigtoc" >&6
9391 ;;
9392esac
9393
ae1a998c
RS
9394# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
9395# used for the tests that follow. We set them back to REAL_CFLAGS and
9396# REAL_CPPFLAGS later on.
98418dba
CW
9397
9398REAL_CPPFLAGS="$CPPFLAGS"
9399
9400if test "${HAVE_X11}" = "yes"; then
9401 DEFS="$C_SWITCH_X_SITE $DEFS"
9402 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
9403 LIBS="$LIBX $LIBS"
9404 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
9405 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
9406
9407 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
9408 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
9409 # but it's more convenient here to set LD_RUN_PATH
9410 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
9411 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
9412 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
9413 export LD_RUN_PATH
9414 fi
9415
9416 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 9417 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
9418echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
9419 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9420/* confdefs.h. */
9421_ACEOF
9422cat confdefs.h >>conftest.$ac_ext
9423cat >>conftest.$ac_ext <<_ACEOF
9424/* end confdefs.h. */
98418dba 9425
98418dba
CW
9426int
9427main ()
9428{
9429XOpenDisplay ("foo");
9430 ;
9431 return 0;
9432}
9433_ACEOF
9434rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9435if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9436 (eval $ac_link) 2>conftest.er1
98418dba 9437 ac_status=$?
edfaf76d
LK
9438 grep -v '^ *+' conftest.er1 >conftest.err
9439 rm -f conftest.er1
9440 cat conftest.err >&5
c0d27fcc 9441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9442 (exit $ac_status); } &&
10a3b1a1
EZ
9443 { ac_try='test -z "$ac_c_werror_flag"
9444 || test ! -s conftest.err'
edfaf76d
LK
9445 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9446 (eval $ac_try) 2>&5
9447 ac_status=$?
9448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9449 (exit $ac_status); }; } &&
9450 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
9451 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9452 (eval $ac_try) 2>&5
9453 ac_status=$?
9454 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9455 (exit $ac_status); }; }; then
9456 xlinux_first_failure=no
98418dba
CW
9457else
9458 echo "$as_me: failed program was:" >&5
19650fd6
AS
9459sed 's/^/| /' conftest.$ac_ext >&5
9460
98418dba
CW
9461xlinux_first_failure=yes
9462fi
edfaf76d
LK
9463rm -f conftest.err conftest.$ac_objext \
9464 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9465 if test "${xlinux_first_failure}" = "yes"; then
9466 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
9467 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
9468 OLD_CPPFLAGS="$CPPFLAGS"
9469 OLD_LIBS="$LIBS"
9470 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
9471 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
9472 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
9473 LIBS="$LIBS -b i486-linuxaout"
9474 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9475/* confdefs.h. */
9476_ACEOF
9477cat confdefs.h >>conftest.$ac_ext
9478cat >>conftest.$ac_ext <<_ACEOF
9479/* end confdefs.h. */
98418dba 9480
98418dba
CW
9481int
9482main ()
9483{
9484XOpenDisplay ("foo");
9485 ;
9486 return 0;
9487}
9488_ACEOF
9489rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9490if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9491 (eval $ac_link) 2>conftest.er1
98418dba 9492 ac_status=$?
edfaf76d
LK
9493 grep -v '^ *+' conftest.er1 >conftest.err
9494 rm -f conftest.er1
9495 cat conftest.err >&5
c0d27fcc 9496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9497 (exit $ac_status); } &&
10a3b1a1
EZ
9498 { ac_try='test -z "$ac_c_werror_flag"
9499 || test ! -s conftest.err'
edfaf76d
LK
9500 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9501 (eval $ac_try) 2>&5
9502 ac_status=$?
9503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9504 (exit $ac_status); }; } &&
9505 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9507 (eval $ac_try) 2>&5
9508 ac_status=$?
c0d27fcc 9509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9510 (exit $ac_status); }; }; then
9511 xlinux_second_failure=no
9512else
9513 echo "$as_me: failed program was:" >&5
19650fd6
AS
9514sed 's/^/| /' conftest.$ac_ext >&5
9515
98418dba
CW
9516xlinux_second_failure=yes
9517fi
edfaf76d
LK
9518rm -f conftest.err conftest.$ac_objext \
9519 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9520 if test "${xlinux_second_failure}" = "yes"; then
9521 # If we get the same failure with -b, there is no use adding -b.
9522 # So take it out. This plays safe.
9523 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
9524 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
9525 CPPFLAGS="$OLD_CPPFLAGS"
9526 LIBS="$OLD_LIBS"
c0d27fcc 9527 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9528echo "${ECHO_T}no" >&6
9529 else
c0d27fcc 9530 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9531echo "${ECHO_T}yes" >&6
9532 fi
9533 else
c0d27fcc 9534 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9535echo "${ECHO_T}no" >&6
9536 fi
9537 fi
9538
9539 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
9540 # header files included from there.
c0d27fcc 9541 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
9542echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
9543 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9544/* confdefs.h. */
9545_ACEOF
9546cat confdefs.h >>conftest.$ac_ext
9547cat >>conftest.$ac_ext <<_ACEOF
9548/* end confdefs.h. */
98418dba
CW
9549#include <X11/Xlib.h>
9550#include <X11/XKBlib.h>
98418dba
CW
9551int
9552main ()
9553{
9554XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
9555 ;
9556 return 0;
9557}
9558_ACEOF
9559rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9560if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9561 (eval $ac_link) 2>conftest.er1
98418dba 9562 ac_status=$?
edfaf76d
LK
9563 grep -v '^ *+' conftest.er1 >conftest.err
9564 rm -f conftest.er1
9565 cat conftest.err >&5
c0d27fcc 9566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9567 (exit $ac_status); } &&
10a3b1a1
EZ
9568 { ac_try='test -z "$ac_c_werror_flag"
9569 || test ! -s conftest.err'
edfaf76d
LK
9570 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9571 (eval $ac_try) 2>&5
9572 ac_status=$?
9573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9574 (exit $ac_status); }; } &&
9575 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9576 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9577 (eval $ac_try) 2>&5
9578 ac_status=$?
c0d27fcc 9579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9580 (exit $ac_status); }; }; then
9581 emacs_xkb=yes
9582else
9583 echo "$as_me: failed program was:" >&5
19650fd6
AS
9584sed 's/^/| /' conftest.$ac_ext >&5
9585
98418dba
CW
9586emacs_xkb=no
9587fi
edfaf76d
LK
9588rm -f conftest.err conftest.$ac_objext \
9589 conftest$ac_exeext conftest.$ac_ext
c0d27fcc 9590 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
9591echo "${ECHO_T}$emacs_xkb" >&6
9592 if test $emacs_xkb = yes; then
b936fae4 9593
c0d27fcc 9594cat >>confdefs.h <<\_ACEOF
98418dba 9595#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 9596_ACEOF
98418dba
CW
9597
9598 fi
9599
c0d27fcc
MR
9600
9601
9602
9603
98418dba
CW
9604for ac_func in XrmSetDatabase XScreenResourceString \
9605XScreenNumberOfScreen XSetWMProtocols
9606do
9607as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 9608echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
9609echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9610if eval "test \"\${$as_ac_var+set}\" = set"; then
9611 echo $ECHO_N "(cached) $ECHO_C" >&6
9612else
9613 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9614/* confdefs.h. */
9615_ACEOF
9616cat confdefs.h >>conftest.$ac_ext
9617cat >>conftest.$ac_ext <<_ACEOF
9618/* end confdefs.h. */
edfaf76d
LK
9619/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9620 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9621#define $ac_func innocuous_$ac_func
9622
98418dba 9623/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
9624 which can conflict with char $ac_func (); below.
9625 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9626 <limits.h> exists even on freestanding compilers. */
edfaf76d 9627
19650fd6
AS
9628#ifdef __STDC__
9629# include <limits.h>
9630#else
9631# include <assert.h>
9632#endif
edfaf76d
LK
9633
9634#undef $ac_func
9635
98418dba
CW
9636/* Override any gcc2 internal prototype to avoid an error. */
9637#ifdef __cplusplus
9638extern "C"
19650fd6 9639{
98418dba
CW
9640#endif
9641/* We use char because int might match the return type of a gcc2
9642 builtin and then its argument prototype would still apply. */
9643char $ac_func ();
98418dba
CW
9644/* The GNU C library defines this for functions which it implements
9645 to always fail with ENOSYS. Some functions are actually named
9646 something starting with __ and the normal name is an alias. */
9647#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9648choke me
9649#else
19650fd6
AS
9650char (*f) () = $ac_func;
9651#endif
9652#ifdef __cplusplus
9653}
98418dba
CW
9654#endif
9655
19650fd6
AS
9656int
9657main ()
9658{
9659return f != $ac_func;
98418dba
CW
9660 ;
9661 return 0;
9662}
9663_ACEOF
9664rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9665if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9666 (eval $ac_link) 2>conftest.er1
98418dba 9667 ac_status=$?
edfaf76d
LK
9668 grep -v '^ *+' conftest.er1 >conftest.err
9669 rm -f conftest.er1
9670 cat conftest.err >&5
c0d27fcc 9671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9672 (exit $ac_status); } &&
10a3b1a1
EZ
9673 { ac_try='test -z "$ac_c_werror_flag"
9674 || test ! -s conftest.err'
edfaf76d
LK
9675 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9676 (eval $ac_try) 2>&5
9677 ac_status=$?
9678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9679 (exit $ac_status); }; } &&
9680 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9682 (eval $ac_try) 2>&5
9683 ac_status=$?
c0d27fcc 9684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9685 (exit $ac_status); }; }; then
9686 eval "$as_ac_var=yes"
9687else
9688 echo "$as_me: failed program was:" >&5
19650fd6
AS
9689sed 's/^/| /' conftest.$ac_ext >&5
9690
98418dba
CW
9691eval "$as_ac_var=no"
9692fi
edfaf76d
LK
9693rm -f conftest.err conftest.$ac_objext \
9694 conftest$ac_exeext conftest.$ac_ext
98418dba 9695fi
c0d27fcc 9696echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
9697echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9698if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 9699 cat >>confdefs.h <<_ACEOF
98418dba 9700#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 9701_ACEOF
98418dba
CW
9702
9703fi
9704done
9705
9706fi
9707
9708if test "${window_system}" = "x11"; then
c0d27fcc 9709 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
9710echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
9711 if test "${emacs_cv_x11_version_6+set}" = set; then
9712 echo $ECHO_N "(cached) $ECHO_C" >&6
9713else
9714 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9715/* confdefs.h. */
9716_ACEOF
9717cat confdefs.h >>conftest.$ac_ext
9718cat >>conftest.$ac_ext <<_ACEOF
9719/* end confdefs.h. */
98418dba 9720#include <X11/Xlib.h>
98418dba
CW
9721int
9722main ()
9723{
9724#if XlibSpecificationRelease < 6
9725fail;
9726#endif
9727
9728 ;
9729 return 0;
9730}
9731_ACEOF
9732rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9733if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9734 (eval $ac_link) 2>conftest.er1
98418dba 9735 ac_status=$?
edfaf76d
LK
9736 grep -v '^ *+' conftest.er1 >conftest.err
9737 rm -f conftest.er1
9738 cat conftest.err >&5
c0d27fcc 9739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9740 (exit $ac_status); } &&
10a3b1a1
EZ
9741 { ac_try='test -z "$ac_c_werror_flag"
9742 || test ! -s conftest.err'
edfaf76d
LK
9743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9744 (eval $ac_try) 2>&5
9745 ac_status=$?
9746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9747 (exit $ac_status); }; } &&
9748 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9750 (eval $ac_try) 2>&5
9751 ac_status=$?
c0d27fcc 9752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9753 (exit $ac_status); }; }; then
9754 emacs_cv_x11_version_6=yes
9755else
9756 echo "$as_me: failed program was:" >&5
19650fd6
AS
9757sed 's/^/| /' conftest.$ac_ext >&5
9758
98418dba
CW
9759emacs_cv_x11_version_6=no
9760fi
edfaf76d
LK
9761rm -f conftest.err conftest.$ac_objext \
9762 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9763fi
9764
9765 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 9766 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9767echo "${ECHO_T}6 or newer" >&6
b936fae4 9768
c0d27fcc 9769cat >>confdefs.h <<\_ACEOF
98418dba 9770#define HAVE_X11R6 1
c0d27fcc 9771_ACEOF
98418dba
CW
9772
9773 else
c0d27fcc 9774 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9775echo "${ECHO_T}before 6" >&6
9776 fi
9777fi
9778
9779if test "${window_system}" = "x11"; then
c0d27fcc 9780 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
9781echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
9782 if test "${emacs_cv_x11_version_5+set}" = set; then
9783 echo $ECHO_N "(cached) $ECHO_C" >&6
9784else
9785 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9786/* confdefs.h. */
9787_ACEOF
9788cat confdefs.h >>conftest.$ac_ext
9789cat >>conftest.$ac_ext <<_ACEOF
9790/* end confdefs.h. */
98418dba 9791#include <X11/Xlib.h>
98418dba
CW
9792int
9793main ()
9794{
9795#if XlibSpecificationRelease < 5
9796fail;
9797#endif
9798
9799 ;
9800 return 0;
9801}
9802_ACEOF
9803rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9804if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 9805 (eval $ac_link) 2>conftest.er1
98418dba 9806 ac_status=$?
edfaf76d
LK
9807 grep -v '^ *+' conftest.er1 >conftest.err
9808 rm -f conftest.er1
9809 cat conftest.err >&5
c0d27fcc 9810 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9811 (exit $ac_status); } &&
10a3b1a1
EZ
9812 { ac_try='test -z "$ac_c_werror_flag"
9813 || test ! -s conftest.err'
edfaf76d
LK
9814 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9815 (eval $ac_try) 2>&5
9816 ac_status=$?
9817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9818 (exit $ac_status); }; } &&
9819 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9820 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9821 (eval $ac_try) 2>&5
9822 ac_status=$?
c0d27fcc 9823 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9824 (exit $ac_status); }; }; then
9825 emacs_cv_x11_version_5=yes
9826else
9827 echo "$as_me: failed program was:" >&5
19650fd6
AS
9828sed 's/^/| /' conftest.$ac_ext >&5
9829
98418dba
CW
9830emacs_cv_x11_version_5=no
9831fi
edfaf76d
LK
9832rm -f conftest.err conftest.$ac_objext \
9833 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9834fi
9835
9836 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 9837 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
9838echo "${ECHO_T}5 or newer" >&6
9839 HAVE_X11R5=yes
b936fae4 9840
c0d27fcc 9841cat >>confdefs.h <<\_ACEOF
98418dba 9842#define HAVE_X11R5 1
c0d27fcc 9843_ACEOF
98418dba
CW
9844
9845 else
9846 HAVE_X11R5=no
c0d27fcc 9847 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
9848echo "${ECHO_T}before 5" >&6
9849 fi
9850fi
9851
488dd4c4
JD
9852
9853
9854HAVE_GTK=no
9855if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 9856 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
9857 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
9858echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
9859 { (exit 1); exit 1; }; };
9860 fi
9861 GLIB_REQUIRED=2.0.1
e512ece1 9862 GTK_REQUIRED=2.0.1
488dd4c4
JD
9863 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
9864
9865 if test "X${with_pkg_config_prog}" != X; then
9866 PKG_CONFIG="${with_pkg_config_prog}"
9867 fi
9868
9869 succeeded=no
9870
9871 if test -z "$PKG_CONFIG"; then
9872 # Extract the first word of "pkg-config", so it can be a program name with args.
9873set dummy pkg-config; ac_word=$2
9874echo "$as_me:$LINENO: checking for $ac_word" >&5
9875echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9876if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9877 echo $ECHO_N "(cached) $ECHO_C" >&6
9878else
9879 case $PKG_CONFIG in
9880 [\\/]* | ?:[\\/]*)
9881 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9882 ;;
9883 *)
9884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9885for as_dir in $PATH
9886do
9887 IFS=$as_save_IFS
9888 test -z "$as_dir" && as_dir=.
9889 for ac_exec_ext in '' $ac_executable_extensions; do
9890 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9891 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9892 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9893 break 2
9894 fi
9895done
9896done
9897
9898 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9899 ;;
9900esac
9901fi
9902PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9903
9904if test -n "$PKG_CONFIG"; then
9905 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
9906echo "${ECHO_T}$PKG_CONFIG" >&6
9907else
9908 echo "$as_me:$LINENO: result: no" >&5
9909echo "${ECHO_T}no" >&6
9910fi
9911
9912 fi
9913
9914 if test "$PKG_CONFIG" = "no" ; then
9915 echo "*** The pkg-config script could not be found. Make sure it is"
9916 echo "*** in your path, or give the full path to pkg-config with"
9917 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
9918 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
9919 else
9920 PKG_CONFIG_MIN_VERSION=0.9.0
9921 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9922 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
9923echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
9924
9925 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
9926 echo "$as_me:$LINENO: result: yes" >&5
9927echo "${ECHO_T}yes" >&6
9928 succeeded=yes
9929
9930 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
9931echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
9932 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
9933 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
9934echo "${ECHO_T}$GTK_CFLAGS" >&6
9935
9936 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
9937echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
9938 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
9939 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
9940echo "${ECHO_T}$GTK_LIBS" >&6
9941 else
9942 GTK_CFLAGS=""
9943 GTK_LIBS=""
9944 ## If we have a custom action on failure, don't print errors, but
9945 ## do set a variable so people can do so.
9946 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
9947 echo $GTK_PKG_ERRORS
9948 fi
9949
9950
9951
9952 else
9953 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9954 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9955 fi
9956 fi
9957
9958 if test $succeeded = yes; then
9959 :
9960 else
9961 { { 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
9962echo "$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;}
9963 { (exit 1); exit 1; }; }
9964 fi
9965
9966
9967
9968 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
57669b57
JD
9969 CFLAGS="$CFLAGS $GTK_CFLAGS"
9970 LIBS="$GTK_LIBS $LIBS"
488dd4c4
JD
9971 HAVE_GTK=yes
9972
9973cat >>confdefs.h <<\_ACEOF
9974#define HAVE_GTK 1
9975_ACEOF
9976
9977 USE_X_TOOLKIT=none
9978
d0a80c21
JD
9979 if test "$with_toolkit_scroll_bars" != no; then
9980 with_toolkit_scroll_bars=yes
9981 fi
57669b57
JD
9982
9983 HAVE_GTK_MULTIDISPLAY=no
9984
9985for ac_func in gdk_display_open
9986do
9987as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9988echo "$as_me:$LINENO: checking for $ac_func" >&5
9989echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9990if eval "test \"\${$as_ac_var+set}\" = set"; then
9991 echo $ECHO_N "(cached) $ECHO_C" >&6
9992else
9993 cat >conftest.$ac_ext <<_ACEOF
57669b57
JD
9994/* confdefs.h. */
9995_ACEOF
9996cat confdefs.h >>conftest.$ac_ext
9997cat >>conftest.$ac_ext <<_ACEOF
9998/* end confdefs.h. */
edfaf76d
LK
9999/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10000 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10001#define $ac_func innocuous_$ac_func
10002
57669b57
JD
10003/* System header to define __stub macros and hopefully few prototypes,
10004 which can conflict with char $ac_func (); below.
10005 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10006 <limits.h> exists even on freestanding compilers. */
edfaf76d 10007
57669b57
JD
10008#ifdef __STDC__
10009# include <limits.h>
10010#else
10011# include <assert.h>
10012#endif
edfaf76d
LK
10013
10014#undef $ac_func
10015
57669b57
JD
10016/* Override any gcc2 internal prototype to avoid an error. */
10017#ifdef __cplusplus
10018extern "C"
10019{
10020#endif
10021/* We use char because int might match the return type of a gcc2
10022 builtin and then its argument prototype would still apply. */
10023char $ac_func ();
10024/* The GNU C library defines this for functions which it implements
10025 to always fail with ENOSYS. Some functions are actually named
10026 something starting with __ and the normal name is an alias. */
10027#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10028choke me
10029#else
10030char (*f) () = $ac_func;
10031#endif
10032#ifdef __cplusplus
10033}
10034#endif
10035
10036int
10037main ()
10038{
10039return f != $ac_func;
10040 ;
10041 return 0;
10042}
10043_ACEOF
10044rm -f conftest.$ac_objext conftest$ac_exeext
10045if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10046 (eval $ac_link) 2>conftest.er1
57669b57 10047 ac_status=$?
edfaf76d
LK
10048 grep -v '^ *+' conftest.er1 >conftest.err
10049 rm -f conftest.er1
10050 cat conftest.err >&5
57669b57
JD
10051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10052 (exit $ac_status); } &&
10a3b1a1
EZ
10053 { ac_try='test -z "$ac_c_werror_flag"
10054 || test ! -s conftest.err'
edfaf76d
LK
10055 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10056 (eval $ac_try) 2>&5
10057 ac_status=$?
10058 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10059 (exit $ac_status); }; } &&
10060 { ac_try='test -s conftest$ac_exeext'
57669b57
JD
10061 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10062 (eval $ac_try) 2>&5
10063 ac_status=$?
10064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10065 (exit $ac_status); }; }; then
10066 eval "$as_ac_var=yes"
10067else
10068 echo "$as_me: failed program was:" >&5
10069sed 's/^/| /' conftest.$ac_ext >&5
10070
10071eval "$as_ac_var=no"
10072fi
edfaf76d
LK
10073rm -f conftest.err conftest.$ac_objext \
10074 conftest$ac_exeext conftest.$ac_ext
57669b57
JD
10075fi
10076echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10077echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10078if test `eval echo '${'$as_ac_var'}'` = yes; then
10079 cat >>confdefs.h <<_ACEOF
10080#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10081_ACEOF
10082 HAVE_GTK_MULTIDISPLAY=yes
10083fi
10084done
10085
10086 if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
10087
10088cat >>confdefs.h <<\_ACEOF
10089#define HAVE_GTK_MULTIDISPLAY 1
572a3cc2
JD
10090_ACEOF
10091
10092 fi
10093 HAVE_GTK_FILE_SELECTION=no
10094
10095for ac_func in gtk_file_selection_new
10096do
10097as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10098echo "$as_me:$LINENO: checking for $ac_func" >&5
10099echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10100if eval "test \"\${$as_ac_var+set}\" = set"; then
10101 echo $ECHO_N "(cached) $ECHO_C" >&6
10102else
10103 cat >conftest.$ac_ext <<_ACEOF
10104/* confdefs.h. */
10105_ACEOF
10106cat confdefs.h >>conftest.$ac_ext
10107cat >>conftest.$ac_ext <<_ACEOF
10108/* end confdefs.h. */
edfaf76d
LK
10109/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10110 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10111#define $ac_func innocuous_$ac_func
10112
572a3cc2
JD
10113/* System header to define __stub macros and hopefully few prototypes,
10114 which can conflict with char $ac_func (); below.
10115 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10116 <limits.h> exists even on freestanding compilers. */
edfaf76d 10117
572a3cc2
JD
10118#ifdef __STDC__
10119# include <limits.h>
10120#else
10121# include <assert.h>
10122#endif
edfaf76d
LK
10123
10124#undef $ac_func
10125
572a3cc2
JD
10126/* Override any gcc2 internal prototype to avoid an error. */
10127#ifdef __cplusplus
10128extern "C"
10129{
10130#endif
10131/* We use char because int might match the return type of a gcc2
10132 builtin and then its argument prototype would still apply. */
10133char $ac_func ();
10134/* The GNU C library defines this for functions which it implements
10135 to always fail with ENOSYS. Some functions are actually named
10136 something starting with __ and the normal name is an alias. */
10137#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10138choke me
10139#else
10140char (*f) () = $ac_func;
10141#endif
10142#ifdef __cplusplus
10143}
10144#endif
10145
10146int
10147main ()
10148{
10149return f != $ac_func;
10150 ;
10151 return 0;
10152}
10153_ACEOF
10154rm -f conftest.$ac_objext conftest$ac_exeext
10155if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10156 (eval $ac_link) 2>conftest.er1
572a3cc2 10157 ac_status=$?
edfaf76d
LK
10158 grep -v '^ *+' conftest.er1 >conftest.err
10159 rm -f conftest.er1
10160 cat conftest.err >&5
572a3cc2
JD
10161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10162 (exit $ac_status); } &&
10a3b1a1
EZ
10163 { ac_try='test -z "$ac_c_werror_flag"
10164 || test ! -s conftest.err'
edfaf76d
LK
10165 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10166 (eval $ac_try) 2>&5
10167 ac_status=$?
10168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10169 (exit $ac_status); }; } &&
10170 { ac_try='test -s conftest$ac_exeext'
572a3cc2
JD
10171 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10172 (eval $ac_try) 2>&5
10173 ac_status=$?
10174 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10175 (exit $ac_status); }; }; then
10176 eval "$as_ac_var=yes"
10177else
10178 echo "$as_me: failed program was:" >&5
10179sed 's/^/| /' conftest.$ac_ext >&5
10180
10181eval "$as_ac_var=no"
10182fi
edfaf76d
LK
10183rm -f conftest.err conftest.$ac_objext \
10184 conftest$ac_exeext conftest.$ac_ext
572a3cc2
JD
10185fi
10186echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10187echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10188if test `eval echo '${'$as_ac_var'}'` = yes; then
10189 cat >>confdefs.h <<_ACEOF
10190#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10191_ACEOF
10192 HAVE_GTK_FILE_SELECTION=yes
10193fi
10194done
10195
10196
10197 HAVE_GTK_FILE_CHOOSER=no
10198
10199for ac_func in gtk_file_chooser_dialog_new
10200do
10201as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10202echo "$as_me:$LINENO: checking for $ac_func" >&5
10203echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10204if eval "test \"\${$as_ac_var+set}\" = set"; then
10205 echo $ECHO_N "(cached) $ECHO_C" >&6
10206else
10207 cat >conftest.$ac_ext <<_ACEOF
10208/* confdefs.h. */
10209_ACEOF
10210cat confdefs.h >>conftest.$ac_ext
10211cat >>conftest.$ac_ext <<_ACEOF
10212/* end confdefs.h. */
edfaf76d
LK
10213/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10214 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10215#define $ac_func innocuous_$ac_func
10216
572a3cc2
JD
10217/* System header to define __stub macros and hopefully few prototypes,
10218 which can conflict with char $ac_func (); below.
10219 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10220 <limits.h> exists even on freestanding compilers. */
edfaf76d 10221
572a3cc2
JD
10222#ifdef __STDC__
10223# include <limits.h>
10224#else
10225# include <assert.h>
10226#endif
edfaf76d
LK
10227
10228#undef $ac_func
10229
572a3cc2
JD
10230/* Override any gcc2 internal prototype to avoid an error. */
10231#ifdef __cplusplus
10232extern "C"
10233{
10234#endif
10235/* We use char because int might match the return type of a gcc2
10236 builtin and then its argument prototype would still apply. */
10237char $ac_func ();
10238/* The GNU C library defines this for functions which it implements
10239 to always fail with ENOSYS. Some functions are actually named
10240 something starting with __ and the normal name is an alias. */
10241#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10242choke me
10243#else
10244char (*f) () = $ac_func;
10245#endif
10246#ifdef __cplusplus
10247}
10248#endif
10249
10250int
10251main ()
10252{
10253return f != $ac_func;
10254 ;
10255 return 0;
10256}
10257_ACEOF
10258rm -f conftest.$ac_objext conftest$ac_exeext
10259if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10260 (eval $ac_link) 2>conftest.er1
572a3cc2 10261 ac_status=$?
edfaf76d
LK
10262 grep -v '^ *+' conftest.er1 >conftest.err
10263 rm -f conftest.er1
10264 cat conftest.err >&5
572a3cc2
JD
10265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10266 (exit $ac_status); } &&
10a3b1a1
EZ
10267 { ac_try='test -z "$ac_c_werror_flag"
10268 || test ! -s conftest.err'
edfaf76d
LK
10269 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10270 (eval $ac_try) 2>&5
10271 ac_status=$?
10272 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10273 (exit $ac_status); }; } &&
10274 { ac_try='test -s conftest$ac_exeext'
572a3cc2
JD
10275 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10276 (eval $ac_try) 2>&5
10277 ac_status=$?
10278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10279 (exit $ac_status); }; }; then
10280 eval "$as_ac_var=yes"
10281else
10282 echo "$as_me: failed program was:" >&5
10283sed 's/^/| /' conftest.$ac_ext >&5
10284
10285eval "$as_ac_var=no"
10286fi
edfaf76d
LK
10287rm -f conftest.err conftest.$ac_objext \
10288 conftest$ac_exeext conftest.$ac_ext
572a3cc2
JD
10289fi
10290echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10291echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10292if test `eval echo '${'$as_ac_var'}'` = yes; then
10293 cat >>confdefs.h <<_ACEOF
10294#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10295_ACEOF
10296 HAVE_GTK_FILE_CHOOSER=yes
10297fi
10298done
10299
10300
10301 if test "$HAVE_GTK_FILE_SELECTION" = yes \
10302 && test "$HAVE_GTK_FILE_CHOOSER" = yes; then
10303
10304cat >>confdefs.h <<\_ACEOF
10305#define HAVE_GTK_FILE_BOTH 1
57669b57
JD
10306_ACEOF
10307
b8bdffbe
JD
10308 fi
10309
10310 if test "$HAVE_GTK_FILE_CHOOSER" = yes; then
10311 HAVE_GTK_AND_PTHREAD=no
10312
10313for ac_header in pthread.h
10314do
10315as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10316if eval "test \"\${$as_ac_Header+set}\" = set"; then
10317 echo "$as_me:$LINENO: checking for $ac_header" >&5
10318echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10319if eval "test \"\${$as_ac_Header+set}\" = set"; then
10320 echo $ECHO_N "(cached) $ECHO_C" >&6
10321fi
10322echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10323echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10324else
10325 # Is the header compilable?
10326echo "$as_me:$LINENO: checking $ac_header usability" >&5
10327echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10328cat >conftest.$ac_ext <<_ACEOF
10329/* confdefs.h. */
10330_ACEOF
10331cat confdefs.h >>conftest.$ac_ext
10332cat >>conftest.$ac_ext <<_ACEOF
10333/* end confdefs.h. */
10334$ac_includes_default
10335#include <$ac_header>
10336_ACEOF
10337rm -f conftest.$ac_objext
10338if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 10339 (eval $ac_compile) 2>conftest.er1
b8bdffbe 10340 ac_status=$?
edfaf76d
LK
10341 grep -v '^ *+' conftest.er1 >conftest.err
10342 rm -f conftest.er1
10343 cat conftest.err >&5
b8bdffbe
JD
10344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10345 (exit $ac_status); } &&
10a3b1a1
EZ
10346 { ac_try='test -z "$ac_c_werror_flag"
10347 || test ! -s conftest.err'
edfaf76d
LK
10348 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10349 (eval $ac_try) 2>&5
10350 ac_status=$?
10351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10352 (exit $ac_status); }; } &&
10353 { ac_try='test -s conftest.$ac_objext'
b8bdffbe
JD
10354 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10355 (eval $ac_try) 2>&5
10356 ac_status=$?
10357 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10358 (exit $ac_status); }; }; then
10359 ac_header_compiler=yes
10360else
10361 echo "$as_me: failed program was:" >&5
10362sed 's/^/| /' conftest.$ac_ext >&5
10363
10364ac_header_compiler=no
10365fi
edfaf76d 10366rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b8bdffbe
JD
10367echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10368echo "${ECHO_T}$ac_header_compiler" >&6
10369
10370# Is the header present?
10371echo "$as_me:$LINENO: checking $ac_header presence" >&5
10372echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10373cat >conftest.$ac_ext <<_ACEOF
10374/* confdefs.h. */
10375_ACEOF
10376cat confdefs.h >>conftest.$ac_ext
10377cat >>conftest.$ac_ext <<_ACEOF
10378/* end confdefs.h. */
10379#include <$ac_header>
10380_ACEOF
10381if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10382 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10383 ac_status=$?
10384 grep -v '^ *+' conftest.er1 >conftest.err
10385 rm -f conftest.er1
10386 cat conftest.err >&5
10387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10388 (exit $ac_status); } >/dev/null; then
10389 if test -s conftest.err; then
10390 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 10391 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
b8bdffbe
JD
10392 else
10393 ac_cpp_err=
10394 fi
10395else
10396 ac_cpp_err=yes
10397fi
10398if test -z "$ac_cpp_err"; then
10399 ac_header_preproc=yes
10400else
10401 echo "$as_me: failed program was:" >&5
10402sed 's/^/| /' conftest.$ac_ext >&5
10403
10404 ac_header_preproc=no
10405fi
10406rm -f conftest.err conftest.$ac_ext
10407echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10408echo "${ECHO_T}$ac_header_preproc" >&6
10409
10410# So? What about this header?
edfaf76d
LK
10411case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10412 yes:no: )
b8bdffbe
JD
10413 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10414echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
10415 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10416echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10417 ac_header_preproc=yes
b8bdffbe 10418 ;;
edfaf76d 10419 no:yes:* )
b8bdffbe
JD
10420 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10421echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
10422 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
10423echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
10424 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10425echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10426 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
10427echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
b8bdffbe
JD
10428 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10429echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
10430 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10431echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
b8bdffbe
JD
10432 (
10433 cat <<\_ASBOX
edfaf76d
LK
10434## ------------------------------------------ ##
10435## Report this to the AC_PACKAGE_NAME lists. ##
10436## ------------------------------------------ ##
b8bdffbe
JD
10437_ASBOX
10438 ) |
10439 sed "s/^/$as_me: WARNING: /" >&2
10440 ;;
10441esac
10442echo "$as_me:$LINENO: checking for $ac_header" >&5
10443echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10444if eval "test \"\${$as_ac_Header+set}\" = set"; then
10445 echo $ECHO_N "(cached) $ECHO_C" >&6
10446else
edfaf76d 10447 eval "$as_ac_Header=\$ac_header_preproc"
b8bdffbe
JD
10448fi
10449echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10450echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10451
10452fi
10453if test `eval echo '${'$as_ac_Header'}'` = yes; then
10454 cat >>confdefs.h <<_ACEOF
10455#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10456_ACEOF
10457
10458fi
10459
10460done
10461
10462 if test "$ac_cv_header_pthread_h"; then
10463 echo "$as_me:$LINENO: checking for pthread_self in -lpthread" >&5
10464echo $ECHO_N "checking for pthread_self in -lpthread... $ECHO_C" >&6
10465if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then
10466 echo $ECHO_N "(cached) $ECHO_C" >&6
10467else
10468 ac_check_lib_save_LIBS=$LIBS
10469LIBS="-lpthread $LIBS"
10470cat >conftest.$ac_ext <<_ACEOF
10471/* confdefs.h. */
10472_ACEOF
10473cat confdefs.h >>conftest.$ac_ext
10474cat >>conftest.$ac_ext <<_ACEOF
10475/* end confdefs.h. */
10476
10477/* Override any gcc2 internal prototype to avoid an error. */
10478#ifdef __cplusplus
10479extern "C"
10480#endif
10481/* We use char because int might match the return type of a gcc2
10482 builtin and then its argument prototype would still apply. */
10483char pthread_self ();
10484int
10485main ()
10486{
10487pthread_self ();
10488 ;
10489 return 0;
10490}
10491_ACEOF
10492rm -f conftest.$ac_objext conftest$ac_exeext
10493if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10494 (eval $ac_link) 2>conftest.er1
b8bdffbe 10495 ac_status=$?
edfaf76d
LK
10496 grep -v '^ *+' conftest.er1 >conftest.err
10497 rm -f conftest.er1
10498 cat conftest.err >&5
b8bdffbe
JD
10499 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10500 (exit $ac_status); } &&
10a3b1a1
EZ
10501 { ac_try='test -z "$ac_c_werror_flag"
10502 || test ! -s conftest.err'
edfaf76d
LK
10503 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10504 (eval $ac_try) 2>&5
10505 ac_status=$?
10506 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10507 (exit $ac_status); }; } &&
10508 { ac_try='test -s conftest$ac_exeext'
b8bdffbe
JD
10509 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10510 (eval $ac_try) 2>&5
10511 ac_status=$?
10512 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10513 (exit $ac_status); }; }; then
10514 ac_cv_lib_pthread_pthread_self=yes
10515else
10516 echo "$as_me: failed program was:" >&5
10517sed 's/^/| /' conftest.$ac_ext >&5
10518
10519ac_cv_lib_pthread_pthread_self=no
10520fi
edfaf76d
LK
10521rm -f conftest.err conftest.$ac_objext \
10522 conftest$ac_exeext conftest.$ac_ext
b8bdffbe
JD
10523LIBS=$ac_check_lib_save_LIBS
10524fi
10525echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_self" >&5
10526echo "${ECHO_T}$ac_cv_lib_pthread_pthread_self" >&6
10527if test $ac_cv_lib_pthread_pthread_self = yes; then
10528 HAVE_GTK_AND_PTHREAD=yes
10529fi
10530
10531 fi
10532 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
10533 GTK_LIBS="$GTK_LIBS -lpthread"
10534
10535cat >>confdefs.h <<\_ACEOF
10536#define HAVE_GTK_AND_PTHREAD 1
10537_ACEOF
10538
10539 fi
57669b57 10540 fi
488dd4c4
JD
10541fi
10542
98418dba
CW
10543if test x"${USE_X_TOOLKIT}" = xmaybe; then
10544 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 10545 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
10546echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
10547 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
10548 echo $ECHO_N "(cached) $ECHO_C" >&6
10549else
10550 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10551/* confdefs.h. */
10552_ACEOF
10553cat confdefs.h >>conftest.$ac_ext
10554cat >>conftest.$ac_ext <<_ACEOF
10555/* end confdefs.h. */
98418dba
CW
10556
10557#include <X11/Intrinsic.h>
10558#include <X11/Xaw/Simple.h>
98418dba
CW
10559int
10560main ()
10561{
10562
10563 ;
10564 return 0;
10565}
10566_ACEOF
10567rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10568if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10569 (eval $ac_link) 2>conftest.er1
98418dba 10570 ac_status=$?
edfaf76d
LK
10571 grep -v '^ *+' conftest.er1 >conftest.err
10572 rm -f conftest.er1
10573 cat conftest.err >&5
c0d27fcc 10574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10575 (exit $ac_status); } &&
10a3b1a1
EZ
10576 { ac_try='test -z "$ac_c_werror_flag"
10577 || test ! -s conftest.err'
edfaf76d
LK
10578 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10579 (eval $ac_try) 2>&5
10580 ac_status=$?
10581 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10582 (exit $ac_status); }; } &&
10583 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10584 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10585 (eval $ac_try) 2>&5
10586 ac_status=$?
c0d27fcc 10587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10588 (exit $ac_status); }; }; then
10589 emacs_cv_x11_version_5_with_xaw=yes
10590else
10591 echo "$as_me: failed program was:" >&5
19650fd6
AS
10592sed 's/^/| /' conftest.$ac_ext >&5
10593
98418dba
CW
10594emacs_cv_x11_version_5_with_xaw=no
10595fi
edfaf76d
LK
10596rm -f conftest.err conftest.$ac_objext \
10597 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10598fi
10599
10600 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 10601 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
10602echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
10603 USE_X_TOOLKIT=LUCID
10604 else
c0d27fcc 10605 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
10606echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
10607 USE_X_TOOLKIT=none
10608 fi
10609 else
10610 USE_X_TOOLKIT=none
10611 fi
10612fi
10613
10614X_TOOLKIT_TYPE=$USE_X_TOOLKIT
10615
10616if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 10617 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
10618echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
10619 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
10620 echo $ECHO_N "(cached) $ECHO_C" >&6
10621else
10622 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10623/* confdefs.h. */
10624_ACEOF
10625cat confdefs.h >>conftest.$ac_ext
10626cat >>conftest.$ac_ext <<_ACEOF
10627/* end confdefs.h. */
98418dba 10628#include <X11/Intrinsic.h>
98418dba
CW
10629int
10630main ()
10631{
10632#if XtSpecificationRelease < 6
10633fail;
10634#endif
10635
10636 ;
10637 return 0;
10638}
10639_ACEOF
10640rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10641if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10642 (eval $ac_link) 2>conftest.er1
98418dba 10643 ac_status=$?
edfaf76d
LK
10644 grep -v '^ *+' conftest.er1 >conftest.err
10645 rm -f conftest.er1
10646 cat conftest.err >&5
c0d27fcc 10647 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10648 (exit $ac_status); } &&
10a3b1a1
EZ
10649 { ac_try='test -z "$ac_c_werror_flag"
10650 || test ! -s conftest.err'
edfaf76d
LK
10651 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10652 (eval $ac_try) 2>&5
10653 ac_status=$?
10654 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10655 (exit $ac_status); }; } &&
10656 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10657 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10658 (eval $ac_try) 2>&5
10659 ac_status=$?
c0d27fcc 10660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10661 (exit $ac_status); }; }; then
10662 emacs_cv_x11_toolkit_version_6=yes
10663else
10664 echo "$as_me: failed program was:" >&5
19650fd6
AS
10665sed 's/^/| /' conftest.$ac_ext >&5
10666
98418dba
CW
10667emacs_cv_x11_toolkit_version_6=no
10668fi
edfaf76d
LK
10669rm -f conftest.err conftest.$ac_objext \
10670 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10671fi
10672
10673 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
10674 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 10675 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 10676echo "${ECHO_T}6 or newer" >&6
b936fae4 10677
c0d27fcc 10678cat >>confdefs.h <<\_ACEOF
98418dba 10679#define HAVE_X11XTR6 1
c0d27fcc 10680_ACEOF
98418dba
CW
10681
10682 else
c0d27fcc 10683 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
10684echo "${ECHO_T}before 6" >&6
10685 fi
10686
10687 OLDLIBS="$LIBS"
10688 if test x$HAVE_X11XTR6 = xyes; then
10689 LIBS="-lXt -lSM -lICE $LIBS"
10690 else
10691 LIBS="-lXt $LIBS"
10692 fi
10693
c0d27fcc 10694echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
10695echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
10696if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
10697 echo $ECHO_N "(cached) $ECHO_C" >&6
10698else
10699 ac_check_lib_save_LIBS=$LIBS
10700LIBS="-lXmu $LIBS"
10701cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10702/* confdefs.h. */
10703_ACEOF
10704cat confdefs.h >>conftest.$ac_ext
10705cat >>conftest.$ac_ext <<_ACEOF
10706/* end confdefs.h. */
98418dba
CW
10707
10708/* Override any gcc2 internal prototype to avoid an error. */
10709#ifdef __cplusplus
10710extern "C"
10711#endif
10712/* We use char because int might match the return type of a gcc2
10713 builtin and then its argument prototype would still apply. */
10714char XmuConvertStandardSelection ();
98418dba
CW
10715int
10716main ()
10717{
10718XmuConvertStandardSelection ();
10719 ;
10720 return 0;
10721}
10722_ACEOF
10723rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10724if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10725 (eval $ac_link) 2>conftest.er1
98418dba 10726 ac_status=$?
edfaf76d
LK
10727 grep -v '^ *+' conftest.er1 >conftest.err
10728 rm -f conftest.er1
10729 cat conftest.err >&5
c0d27fcc 10730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10731 (exit $ac_status); } &&
10a3b1a1
EZ
10732 { ac_try='test -z "$ac_c_werror_flag"
10733 || test ! -s conftest.err'
edfaf76d
LK
10734 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10735 (eval $ac_try) 2>&5
10736 ac_status=$?
10737 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10738 (exit $ac_status); }; } &&
10739 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10740 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10741 (eval $ac_try) 2>&5
10742 ac_status=$?
c0d27fcc 10743 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10744 (exit $ac_status); }; }; then
10745 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
10746else
10747 echo "$as_me: failed program was:" >&5
19650fd6
AS
10748sed 's/^/| /' conftest.$ac_ext >&5
10749
98418dba
CW
10750ac_cv_lib_Xmu_XmuConvertStandardSelection=no
10751fi
edfaf76d
LK
10752rm -f conftest.err conftest.$ac_objext \
10753 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10754LIBS=$ac_check_lib_save_LIBS
10755fi
c0d27fcc 10756echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
10757echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
10758if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 10759 cat >>confdefs.h <<_ACEOF
98418dba 10760#define HAVE_LIBXMU 1
c0d27fcc 10761_ACEOF
98418dba
CW
10762
10763 LIBS="-lXmu $LIBS"
10764
10765fi
10766
10767 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
10768fi
10769
10770# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
10771if test "${HAVE_X11}" = "yes"; then
10772 if test "${USE_X_TOOLKIT}" != "none"; then
10773
c0d27fcc 10774echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
10775echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
10776if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
10777 echo $ECHO_N "(cached) $ECHO_C" >&6
10778else
10779 ac_check_lib_save_LIBS=$LIBS
10780LIBS="-lXext $LIBS"
10781cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10782/* confdefs.h. */
10783_ACEOF
10784cat confdefs.h >>conftest.$ac_ext
10785cat >>conftest.$ac_ext <<_ACEOF
10786/* end confdefs.h. */
98418dba
CW
10787
10788/* Override any gcc2 internal prototype to avoid an error. */
10789#ifdef __cplusplus
10790extern "C"
10791#endif
10792/* We use char because int might match the return type of a gcc2
10793 builtin and then its argument prototype would still apply. */
10794char XShapeQueryExtension ();
98418dba
CW
10795int
10796main ()
10797{
10798XShapeQueryExtension ();
10799 ;
10800 return 0;
10801}
10802_ACEOF
10803rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10804if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10805 (eval $ac_link) 2>conftest.er1
98418dba 10806 ac_status=$?
edfaf76d
LK
10807 grep -v '^ *+' conftest.er1 >conftest.err
10808 rm -f conftest.er1
10809 cat conftest.err >&5
c0d27fcc 10810 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10811 (exit $ac_status); } &&
10a3b1a1
EZ
10812 { ac_try='test -z "$ac_c_werror_flag"
10813 || test ! -s conftest.err'
edfaf76d
LK
10814 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10815 (eval $ac_try) 2>&5
10816 ac_status=$?
10817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10818 (exit $ac_status); }; } &&
10819 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10820 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10821 (eval $ac_try) 2>&5
10822 ac_status=$?
c0d27fcc 10823 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10824 (exit $ac_status); }; }; then
10825 ac_cv_lib_Xext_XShapeQueryExtension=yes
10826else
10827 echo "$as_me: failed program was:" >&5
19650fd6
AS
10828sed 's/^/| /' conftest.$ac_ext >&5
10829
98418dba
CW
10830ac_cv_lib_Xext_XShapeQueryExtension=no
10831fi
edfaf76d
LK
10832rm -f conftest.err conftest.$ac_objext \
10833 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10834LIBS=$ac_check_lib_save_LIBS
10835fi
c0d27fcc 10836echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
10837echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
10838if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 10839 cat >>confdefs.h <<_ACEOF
98418dba 10840#define HAVE_LIBXEXT 1
c0d27fcc 10841_ACEOF
98418dba
CW
10842
10843 LIBS="-lXext $LIBS"
10844
10845fi
10846
10847 fi
10848fi
10849
10850if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10851 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
10852echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
10853if test "${emacs_cv_motif_version_2_1+set}" = set; then
10854 echo $ECHO_N "(cached) $ECHO_C" >&6
10855else
10856 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10857/* confdefs.h. */
10858_ACEOF
10859cat confdefs.h >>conftest.$ac_ext
10860cat >>conftest.$ac_ext <<_ACEOF
10861/* end confdefs.h. */
98418dba 10862#include <Xm/Xm.h>
98418dba
CW
10863int
10864main ()
10865{
10866#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
10867int x = 5;
10868#else
10869Motif version prior to 2.1.
10870#endif
10871 ;
10872 return 0;
10873}
10874_ACEOF
10875rm -f conftest.$ac_objext
c0d27fcc 10876if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 10877 (eval $ac_compile) 2>conftest.er1
98418dba 10878 ac_status=$?
edfaf76d
LK
10879 grep -v '^ *+' conftest.er1 >conftest.err
10880 rm -f conftest.er1
10881 cat conftest.err >&5
c0d27fcc 10882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10883 (exit $ac_status); } &&
10a3b1a1
EZ
10884 { ac_try='test -z "$ac_c_werror_flag"
10885 || test ! -s conftest.err'
edfaf76d
LK
10886 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10887 (eval $ac_try) 2>&5
10888 ac_status=$?
10889 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10890 (exit $ac_status); }; } &&
10891 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10892 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10893 (eval $ac_try) 2>&5
10894 ac_status=$?
c0d27fcc 10895 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10896 (exit $ac_status); }; }; then
10897 emacs_cv_motif_version_2_1=yes
10898else
10899 echo "$as_me: failed program was:" >&5
19650fd6
AS
10900sed 's/^/| /' conftest.$ac_ext >&5
10901
98418dba
CW
10902emacs_cv_motif_version_2_1=no
10903fi
edfaf76d 10904rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 10905fi
c0d27fcc 10906echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
10907echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
10908 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
10909 if test $emacs_cv_motif_version_2_1 = yes; then
10910 HAVE_LIBXP=no
b936fae4 10911
c0d27fcc 10912cat >>confdefs.h <<\_ACEOF
98418dba 10913#define HAVE_MOTIF_2_1 1
c0d27fcc 10914_ACEOF
98418dba 10915
c0d27fcc 10916 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
10917echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
10918if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
10919 echo $ECHO_N "(cached) $ECHO_C" >&6
10920else
10921 ac_check_lib_save_LIBS=$LIBS
10922LIBS="-lXp $LIBS"
10923cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10924/* confdefs.h. */
10925_ACEOF
10926cat confdefs.h >>conftest.$ac_ext
10927cat >>conftest.$ac_ext <<_ACEOF
10928/* end confdefs.h. */
98418dba
CW
10929
10930/* Override any gcc2 internal prototype to avoid an error. */
10931#ifdef __cplusplus
10932extern "C"
10933#endif
10934/* We use char because int might match the return type of a gcc2
10935 builtin and then its argument prototype would still apply. */
10936char XpCreateContext ();
98418dba
CW
10937int
10938main ()
10939{
10940XpCreateContext ();
10941 ;
10942 return 0;
10943}
10944_ACEOF
10945rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10946if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 10947 (eval $ac_link) 2>conftest.er1
98418dba 10948 ac_status=$?
edfaf76d
LK
10949 grep -v '^ *+' conftest.er1 >conftest.err
10950 rm -f conftest.er1
10951 cat conftest.err >&5
c0d27fcc 10952 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10953 (exit $ac_status); } &&
10a3b1a1
EZ
10954 { ac_try='test -z "$ac_c_werror_flag"
10955 || test ! -s conftest.err'
edfaf76d
LK
10956 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10957 (eval $ac_try) 2>&5
10958 ac_status=$?
10959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10960 (exit $ac_status); }; } &&
10961 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10962 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10963 (eval $ac_try) 2>&5
10964 ac_status=$?
c0d27fcc 10965 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10966 (exit $ac_status); }; }; then
10967 ac_cv_lib_Xp_XpCreateContext=yes
10968else
10969 echo "$as_me: failed program was:" >&5
19650fd6
AS
10970sed 's/^/| /' conftest.$ac_ext >&5
10971
98418dba
CW
10972ac_cv_lib_Xp_XpCreateContext=no
10973fi
edfaf76d
LK
10974rm -f conftest.err conftest.$ac_objext \
10975 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10976LIBS=$ac_check_lib_save_LIBS
10977fi
c0d27fcc 10978echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
10979echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
10980if test $ac_cv_lib_Xp_XpCreateContext = yes; then
10981 HAVE_LIBXP=yes
10982fi
503d2be0 10983
98418dba 10984 if test ${HAVE_LIBXP} = yes; then
b936fae4 10985
c0d27fcc 10986cat >>confdefs.h <<\_ACEOF
98418dba 10987#define HAVE_LIBXP 1
c0d27fcc 10988_ACEOF
503d2be0 10989
98418dba 10990 fi
4693dbc9
SM
10991 else
10992 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
10993echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
10994if test "${emacs_cv_lesstif+set}" = set; then
10995 echo $ECHO_N "(cached) $ECHO_C" >&6
10996else
10997 # We put this in CFLAGS temporarily to precede other -I options
10998 # that might be in CFLAGS temporarily.
10999 # We put this in CPPFLAGS where it precedes the other -I options.
11000 OLD_CPPFLAGS=$CPPFLAGS
11001 OLD_CFLAGS=$CFLAGS
11002 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11003 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11004 cat >conftest.$ac_ext <<_ACEOF
11005/* confdefs.h. */
11006_ACEOF
11007cat confdefs.h >>conftest.$ac_ext
11008cat >>conftest.$ac_ext <<_ACEOF
11009/* end confdefs.h. */
11010#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11011int
11012main ()
11013{
11014int x = 5;
11015 ;
11016 return 0;
11017}
11018_ACEOF
11019rm -f conftest.$ac_objext
11020if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11021 (eval $ac_compile) 2>conftest.er1
4693dbc9 11022 ac_status=$?
edfaf76d
LK
11023 grep -v '^ *+' conftest.er1 >conftest.err
11024 rm -f conftest.er1
11025 cat conftest.err >&5
4693dbc9
SM
11026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11027 (exit $ac_status); } &&
10a3b1a1
EZ
11028 { ac_try='test -z "$ac_c_werror_flag"
11029 || test ! -s conftest.err'
edfaf76d
LK
11030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11031 (eval $ac_try) 2>&5
11032 ac_status=$?
11033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11034 (exit $ac_status); }; } &&
11035 { ac_try='test -s conftest.$ac_objext'
4693dbc9
SM
11036 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11037 (eval $ac_try) 2>&5
11038 ac_status=$?
11039 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11040 (exit $ac_status); }; }; then
11041 emacs_cv_lesstif=yes
11042else
11043 echo "$as_me: failed program was:" >&5
11044sed 's/^/| /' conftest.$ac_ext >&5
11045
11046emacs_cv_lesstif=no
11047fi
edfaf76d 11048rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
4693dbc9
SM
11049fi
11050echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
11051echo "${ECHO_T}$emacs_cv_lesstif" >&6
11052 if test $emacs_cv_lesstif = yes; then
11053 # Make sure this -I option remains in CPPFLAGS after it is set
11054 # back to REAL_CPPFLAGS.
11055 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11056 # have those other -I options anyway. Ultimately, having this
11057 # directory ultimately in CPPFLAGS will be enough.
11058 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11059 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11060 else
11061 CFLAGS=$OLD_CFLAGS
11062 CPPFLAGS=$OLD_CPPFLAGS
11063 fi
98418dba
CW
11064 fi
11065fi
11066
11067### Is -lXaw3d available?
11068HAVE_XAW3D=no
11069if test "${HAVE_X11}" = "yes"; then
11070 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 11071 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
11072echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
11073if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
11074 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 11075else
22044edf 11076 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11077/* confdefs.h. */
11078_ACEOF
11079cat confdefs.h >>conftest.$ac_ext
11080cat >>conftest.$ac_ext <<_ACEOF
11081/* end confdefs.h. */
98418dba 11082#include <X11/Xaw3d/Scrollbar.h>
503d2be0 11083_ACEOF
c0d27fcc 11084if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11085 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11086 ac_status=$?
6bae0ccf 11087 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11088 rm -f conftest.er1
11089 cat conftest.err >&5
c0d27fcc 11090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11091 (exit $ac_status); } >/dev/null; then
11092 if test -s conftest.err; then
11093 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 11094 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
11095 else
11096 ac_cpp_err=
11097 fi
11098else
11099 ac_cpp_err=yes
11100fi
11101if test -z "$ac_cpp_err"; then
22044edf 11102 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 11103else
503d2be0 11104 echo "$as_me: failed program was:" >&5
19650fd6
AS
11105sed 's/^/| /' conftest.$ac_ext >&5
11106
22044edf 11107 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 11108fi
503d2be0 11109rm -f conftest.err conftest.$ac_ext
98418dba 11110fi
c0d27fcc 11111echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 11112echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 11113if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 11114 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
11115echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
11116if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
11117 echo $ECHO_N "(cached) $ECHO_C" >&6
11118else
11119 ac_check_lib_save_LIBS=$LIBS
11120LIBS="-lXaw3d $LIBS"
11121cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11122/* confdefs.h. */
11123_ACEOF
11124cat confdefs.h >>conftest.$ac_ext
11125cat >>conftest.$ac_ext <<_ACEOF
11126/* end confdefs.h. */
98418dba
CW
11127
11128/* Override any gcc2 internal prototype to avoid an error. */
11129#ifdef __cplusplus
11130extern "C"
11131#endif
11132/* We use char because int might match the return type of a gcc2
11133 builtin and then its argument prototype would still apply. */
11134char XawScrollbarSetThumb ();
503d2be0
AS
11135int
11136main ()
11137{
98418dba 11138XawScrollbarSetThumb ();
503d2be0
AS
11139 ;
11140 return 0;
11141}
11142_ACEOF
11143rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11144if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 11145 (eval $ac_link) 2>conftest.er1
503d2be0 11146 ac_status=$?
edfaf76d
LK
11147 grep -v '^ *+' conftest.er1 >conftest.err
11148 rm -f conftest.er1
11149 cat conftest.err >&5
c0d27fcc 11150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11151 (exit $ac_status); } &&
10a3b1a1
EZ
11152 { ac_try='test -z "$ac_c_werror_flag"
11153 || test ! -s conftest.err'
edfaf76d
LK
11154 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11155 (eval $ac_try) 2>&5
11156 ac_status=$?
11157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11158 (exit $ac_status); }; } &&
11159 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11160 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11161 (eval $ac_try) 2>&5
11162 ac_status=$?
c0d27fcc 11163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11164 (exit $ac_status); }; }; then
98418dba 11165 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 11166else
503d2be0 11167 echo "$as_me: failed program was:" >&5
19650fd6
AS
11168sed 's/^/| /' conftest.$ac_ext >&5
11169
98418dba 11170ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 11171fi
edfaf76d
LK
11172rm -f conftest.err conftest.$ac_objext \
11173 conftest$ac_exeext conftest.$ac_ext
98418dba 11174LIBS=$ac_check_lib_save_LIBS
ba4481b5 11175fi
c0d27fcc 11176echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
11177echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
11178if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
11179 HAVE_XAW3D=yes
ba4481b5 11180fi
503d2be0 11181
ba4481b5
DL
11182fi
11183
c0d27fcc 11184
98418dba 11185 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 11186
c0d27fcc 11187cat >>confdefs.h <<\_ACEOF
98418dba 11188#define HAVE_XAW3D 1
c0d27fcc 11189_ACEOF
98418dba 11190
ba4481b5 11191 fi
98418dba 11192 fi
ba4481b5
DL
11193fi
11194
c0d27fcc
MR
11195
11196
98418dba
CW
11197USE_TOOLKIT_SCROLL_BARS=no
11198if test "${with_toolkit_scroll_bars}" != "no"; then
11199 if test "${USE_X_TOOLKIT}" != "none"; then
11200 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 11201 cat >>confdefs.h <<\_ACEOF
98418dba 11202#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 11203_ACEOF
98418dba
CW
11204
11205 HAVE_XAW3D=no
11206 USE_TOOLKIT_SCROLL_BARS=yes
11207 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 11208 cat >>confdefs.h <<\_ACEOF
98418dba 11209#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 11210_ACEOF
98418dba
CW
11211
11212 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 11213 fi
488dd4c4
JD
11214 elif test "${HAVE_GTK}" = "yes"; then
11215 cat >>confdefs.h <<\_ACEOF
11216#define USE_TOOLKIT_SCROLL_BARS 1
5d6da11e
YM
11217_ACEOF
11218
11219 USE_TOOLKIT_SCROLL_BARS=yes
11220 elif test "${HAVE_CARBON}" = "yes"; then
11221 cat >>confdefs.h <<\_ACEOF
11222#define USE_TOOLKIT_SCROLL_BARS 1
488dd4c4
JD
11223_ACEOF
11224
11225 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
11226 fi
11227fi
11228
abd39b57 11229cat >conftest.$ac_ext <<_ACEOF
abd39b57
AC
11230/* confdefs.h. */
11231_ACEOF
11232cat confdefs.h >>conftest.$ac_ext
11233cat >>conftest.$ac_ext <<_ACEOF
11234/* end confdefs.h. */
11235
11236 #include <X11/Xlib.h>
11237 #include <X11/Xresource.h>
11238int
11239main ()
11240{
11241XIMProc callback;
11242 ;
11243 return 0;
11244}
11245_ACEOF
11246rm -f conftest.$ac_objext
11247if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11248 (eval $ac_compile) 2>conftest.er1
abd39b57 11249 ac_status=$?
edfaf76d
LK
11250 grep -v '^ *+' conftest.er1 >conftest.err
11251 rm -f conftest.er1
11252 cat conftest.err >&5
abd39b57
AC
11253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11254 (exit $ac_status); } &&
10a3b1a1
EZ
11255 { ac_try='test -z "$ac_c_werror_flag"
11256 || test ! -s conftest.err'
edfaf76d
LK
11257 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11258 (eval $ac_try) 2>&5
11259 ac_status=$?
11260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11261 (exit $ac_status); }; } &&
11262 { ac_try='test -s conftest.$ac_objext'
abd39b57
AC
11263 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11264 (eval $ac_try) 2>&5
11265 ac_status=$?
11266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11267 (exit $ac_status); }; }; then
11268 HAVE_XIM=yes
11269
11270cat >>confdefs.h <<\_ACEOF
11271#define HAVE_XIM 1
11272_ACEOF
11273
11274else
11275 echo "$as_me: failed program was:" >&5
11276sed 's/^/| /' conftest.$ac_ext >&5
11277
11278HAVE_XIM=no
11279fi
edfaf76d 11280rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
abd39b57 11281
c0d27fcc 11282
98418dba 11283if test "${with_xim}" != "no"; then
b936fae4 11284
c0d27fcc 11285cat >>confdefs.h <<\_ACEOF
98418dba 11286#define USE_XIM 1
c0d27fcc 11287_ACEOF
98418dba 11288
793fa0d7 11289fi
abd39b57
AC
11290
11291
11292if test "${HAVE_XIM}" != "no"; then
849d80cf
DL
11293 late_CFLAGS=$CFLAGS
11294 if test "$GCC" = yes; then
11295 CFLAGS="$CFLAGS --pedantic-errors"
11296 fi
cffcede7 11297 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11298/* confdefs.h. */
11299_ACEOF
11300cat confdefs.h >>conftest.$ac_ext
11301cat >>conftest.$ac_ext <<_ACEOF
11302/* end confdefs.h. */
cffcede7
JD
11303
11304#include <X11/Xlib.h>
11305#include <X11/Xresource.h>
11306int
11307main ()
11308{
11309Display *display;
11310XrmDatabase db;
11311char *res_name;
11312char *res_class;
11313XIMProc callback;
11314XPointer *client_data;
849d80cf
DL
11315#ifndef __GNUC__
11316/* If we're not using GCC, it's probably not XFree86, and this is
11317 probably right, but we can't use something like --pedantic-errors. */
11318extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11319 char*, XIMProc, XPointer*);
11320#endif
cffcede7
JD
11321(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11322 client_data);
11323 ;
11324 return 0;
11325}
11326_ACEOF
11327rm -f conftest.$ac_objext
11328if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11329 (eval $ac_compile) 2>conftest.er1
cffcede7 11330 ac_status=$?
edfaf76d
LK
11331 grep -v '^ *+' conftest.er1 >conftest.err
11332 rm -f conftest.er1
11333 cat conftest.err >&5
cffcede7
JD
11334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11335 (exit $ac_status); } &&
10a3b1a1
EZ
11336 { ac_try='test -z "$ac_c_werror_flag"
11337 || test ! -s conftest.err'
edfaf76d
LK
11338 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11339 (eval $ac_try) 2>&5
11340 ac_status=$?
11341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11342 (exit $ac_status); }; } &&
11343 { ac_try='test -s conftest.$ac_objext'
cffcede7
JD
11344 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11345 (eval $ac_try) 2>&5
11346 ac_status=$?
11347 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11348 (exit $ac_status); }; }; then
11349 emacs_cv_arg6_star=yes
11350else
11351 echo "$as_me: failed program was:" >&5
19650fd6
AS
11352sed 's/^/| /' conftest.$ac_ext >&5
11353
cffcede7 11354fi
edfaf76d 11355rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cffcede7
JD
11356
11357 if test "$emacs_cv_arg6_star" = yes; then
f57bd967 11358 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
11359#define XRegisterIMInstantiateCallback_arg6 XPointer*
11360_ACEOF
11361
11362 else
f57bd967 11363 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
11364#define XRegisterIMInstantiateCallback_arg6 XPointer
11365_ACEOF
11366
11367 fi
849d80cf 11368 CFLAGS=$late_CFLAGS
98418dba
CW
11369fi
11370
11371### Use -lXpm if available, unless `--with-xpm=no'.
11372HAVE_XPM=no
11373if test "${HAVE_X11}" = "yes"; then
11374 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
11375 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
11376 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
11377echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
11378if test "${ac_cv_header_X11_xpm_h+set}" = set; then
11379 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11380fi
11381echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
11382echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 11383else
c0d27fcc
MR
11384 # Is the header compilable?
11385echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
11386echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
11387cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11388/* confdefs.h. */
11389_ACEOF
11390cat confdefs.h >>conftest.$ac_ext
11391cat >>conftest.$ac_ext <<_ACEOF
11392/* end confdefs.h. */
c0d27fcc
MR
11393$ac_includes_default
11394#include <X11/xpm.h>
11395_ACEOF
11396rm -f conftest.$ac_objext
11397if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11398 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11399 ac_status=$?
edfaf76d
LK
11400 grep -v '^ *+' conftest.er1 >conftest.err
11401 rm -f conftest.er1
11402 cat conftest.err >&5
c0d27fcc
MR
11403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11404 (exit $ac_status); } &&
10a3b1a1
EZ
11405 { ac_try='test -z "$ac_c_werror_flag"
11406 || test ! -s conftest.err'
edfaf76d
LK
11407 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11408 (eval $ac_try) 2>&5
11409 ac_status=$?
11410 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11411 (exit $ac_status); }; } &&
11412 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11413 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11414 (eval $ac_try) 2>&5
11415 ac_status=$?
11416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11417 (exit $ac_status); }; }; then
11418 ac_header_compiler=yes
11419else
11420 echo "$as_me: failed program was:" >&5
19650fd6
AS
11421sed 's/^/| /' conftest.$ac_ext >&5
11422
c0d27fcc
MR
11423ac_header_compiler=no
11424fi
edfaf76d 11425rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11426echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11427echo "${ECHO_T}$ac_header_compiler" >&6
11428
11429# Is the header present?
11430echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
11431echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
11432cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11433/* confdefs.h. */
11434_ACEOF
11435cat confdefs.h >>conftest.$ac_ext
11436cat >>conftest.$ac_ext <<_ACEOF
11437/* end confdefs.h. */
98418dba
CW
11438#include <X11/xpm.h>
11439_ACEOF
c0d27fcc 11440if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11441 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11442 ac_status=$?
6bae0ccf 11443 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11444 rm -f conftest.er1
11445 cat conftest.err >&5
c0d27fcc 11446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11447 (exit $ac_status); } >/dev/null; then
11448 if test -s conftest.err; then
11449 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 11450 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11451 else
11452 ac_cpp_err=
11453 fi
11454else
11455 ac_cpp_err=yes
11456fi
11457if test -z "$ac_cpp_err"; then
c0d27fcc 11458 ac_header_preproc=yes
98418dba
CW
11459else
11460 echo "$as_me: failed program was:" >&5
19650fd6
AS
11461sed 's/^/| /' conftest.$ac_ext >&5
11462
c0d27fcc 11463 ac_header_preproc=no
98418dba
CW
11464fi
11465rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11466echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11467echo "${ECHO_T}$ac_header_preproc" >&6
11468
11469# So? What about this header?
edfaf76d
LK
11470case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11471 yes:no: )
c0d27fcc
MR
11472 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
11473echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
11474 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the compiler's result" >&5
11475echo "$as_me: WARNING: X11/xpm.h: proceeding with the compiler's result" >&2;}
11476 ac_header_preproc=yes
11477 ;;
11478 no:yes:* )
11479 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
11480echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
11481 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
11482echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
11483 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: see the Autoconf documentation" >&5
11484echo "$as_me: WARNING: X11/xpm.h: see the Autoconf documentation" >&2;}
11485 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&5
11486echo "$as_me: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&2;}
7c9e5167
JD
11487 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
11488echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
11489 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&5
11490echo "$as_me: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&2;}
7c9e5167
JD
11491 (
11492 cat <<\_ASBOX
edfaf76d
LK
11493## ------------------------------------------ ##
11494## Report this to the AC_PACKAGE_NAME lists. ##
11495## ------------------------------------------ ##
19650fd6
AS
11496_ASBOX
11497 ) |
11498 sed "s/^/$as_me: WARNING: /" >&2
11499 ;;
c0d27fcc
MR
11500esac
11501echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
11502echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
11503if test "${ac_cv_header_X11_xpm_h+set}" = set; then
11504 echo $ECHO_N "(cached) $ECHO_C" >&6
11505else
11506 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 11507fi
c0d27fcc 11508echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 11509echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
11510
11511fi
98418dba 11512if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 11513 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
11514echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
11515if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 11516 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11517else
98418dba
CW
11518 ac_check_lib_save_LIBS=$LIBS
11519LIBS="-lXpm -lX11 $LIBS"
11520cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11521/* confdefs.h. */
11522_ACEOF
11523cat confdefs.h >>conftest.$ac_ext
11524cat >>conftest.$ac_ext <<_ACEOF
11525/* end confdefs.h. */
98418dba 11526
ba4481b5 11527/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11528#ifdef __cplusplus
11529extern "C"
11530#endif
ba4481b5 11531/* We use char because int might match the return type of a gcc2
503d2be0 11532 builtin and then its argument prototype would still apply. */
98418dba 11533char XpmReadFileToPixmap ();
503d2be0
AS
11534int
11535main ()
11536{
98418dba 11537XpmReadFileToPixmap ();
503d2be0
AS
11538 ;
11539 return 0;
11540}
11541_ACEOF
11542rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11543if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 11544 (eval $ac_link) 2>conftest.er1
503d2be0 11545 ac_status=$?
edfaf76d
LK
11546 grep -v '^ *+' conftest.er1 >conftest.err
11547 rm -f conftest.er1
11548 cat conftest.err >&5
c0d27fcc 11549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11550 (exit $ac_status); } &&
10a3b1a1
EZ
11551 { ac_try='test -z "$ac_c_werror_flag"
11552 || test ! -s conftest.err'
edfaf76d
LK
11553 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11554 (eval $ac_try) 2>&5
11555 ac_status=$?
11556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11557 (exit $ac_status); }; } &&
11558 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11560 (eval $ac_try) 2>&5
11561 ac_status=$?
c0d27fcc 11562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11563 (exit $ac_status); }; }; then
98418dba 11564 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
11565else
11566 echo "$as_me: failed program was:" >&5
19650fd6
AS
11567sed 's/^/| /' conftest.$ac_ext >&5
11568
98418dba 11569ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0 11570fi
edfaf76d
LK
11571rm -f conftest.err conftest.$ac_objext \
11572 conftest$ac_exeext conftest.$ac_ext
98418dba 11573LIBS=$ac_check_lib_save_LIBS
503d2be0 11574fi
c0d27fcc 11575echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
11576echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
11577if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
11578 HAVE_XPM=yes
ba4481b5
DL
11579fi
11580
98418dba
CW
11581fi
11582
c0d27fcc 11583
98418dba 11584 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 11585 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
11586echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
11587 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11588/* confdefs.h. */
11589_ACEOF
11590cat confdefs.h >>conftest.$ac_ext
11591cat >>conftest.$ac_ext <<_ACEOF
11592/* end confdefs.h. */
98418dba
CW
11593#include "X11/xpm.h"
11594#ifndef XpmReturnAllocPixels
11595no_return_alloc_pixels
503d2be0 11596#endif
ba4481b5 11597
98418dba
CW
11598_ACEOF
11599if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11600 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
11601 HAVE_XPM=no
11602else
11603 HAVE_XPM=yes
11604fi
11605rm -f conftest*
ba4481b5 11606
c0d27fcc 11607
98418dba 11608 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 11609 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
11610echo "${ECHO_T}yes" >&6
11611 else
c0d27fcc 11612 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
11613echo "${ECHO_T}no" >&6
11614 fi
11615 fi
11616 fi
11617
11618 if test "${HAVE_XPM}" = "yes"; then
b936fae4 11619
c0d27fcc 11620cat >>confdefs.h <<\_ACEOF
98418dba 11621#define HAVE_XPM 1
c0d27fcc 11622_ACEOF
98418dba
CW
11623
11624 fi
11625fi
11626
11627### Use -ljpeg if available, unless `--with-jpeg=no'.
11628HAVE_JPEG=no
11629if test "${HAVE_X11}" = "yes"; then
11630 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
11631 if test "${ac_cv_header_jerror_h+set}" = set; then
11632 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
11633echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11634if test "${ac_cv_header_jerror_h+set}" = set; then
11635 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11636fi
11637echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
11638echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 11639else
c0d27fcc
MR
11640 # Is the header compilable?
11641echo "$as_me:$LINENO: checking jerror.h usability" >&5
11642echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
11643cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11644/* confdefs.h. */
11645_ACEOF
11646cat confdefs.h >>conftest.$ac_ext
11647cat >>conftest.$ac_ext <<_ACEOF
11648/* end confdefs.h. */
c0d27fcc
MR
11649$ac_includes_default
11650#include <jerror.h>
11651_ACEOF
11652rm -f conftest.$ac_objext
11653if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11654 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11655 ac_status=$?
edfaf76d
LK
11656 grep -v '^ *+' conftest.er1 >conftest.err
11657 rm -f conftest.er1
11658 cat conftest.err >&5
c0d27fcc
MR
11659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11660 (exit $ac_status); } &&
10a3b1a1
EZ
11661 { ac_try='test -z "$ac_c_werror_flag"
11662 || test ! -s conftest.err'
edfaf76d
LK
11663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11664 (eval $ac_try) 2>&5
11665 ac_status=$?
11666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11667 (exit $ac_status); }; } &&
11668 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11669 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11670 (eval $ac_try) 2>&5
11671 ac_status=$?
11672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11673 (exit $ac_status); }; }; then
11674 ac_header_compiler=yes
11675else
11676 echo "$as_me: failed program was:" >&5
19650fd6
AS
11677sed 's/^/| /' conftest.$ac_ext >&5
11678
c0d27fcc
MR
11679ac_header_compiler=no
11680fi
edfaf76d 11681rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11682echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11683echo "${ECHO_T}$ac_header_compiler" >&6
11684
11685# Is the header present?
11686echo "$as_me:$LINENO: checking jerror.h presence" >&5
11687echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
11688cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11689/* confdefs.h. */
11690_ACEOF
11691cat confdefs.h >>conftest.$ac_ext
11692cat >>conftest.$ac_ext <<_ACEOF
11693/* end confdefs.h. */
98418dba
CW
11694#include <jerror.h>
11695_ACEOF
c0d27fcc 11696if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11697 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11698 ac_status=$?
6bae0ccf 11699 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11700 rm -f conftest.er1
11701 cat conftest.err >&5
c0d27fcc 11702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11703 (exit $ac_status); } >/dev/null; then
11704 if test -s conftest.err; then
11705 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 11706 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11707 else
11708 ac_cpp_err=
11709 fi
11710else
11711 ac_cpp_err=yes
503d2be0 11712fi
98418dba 11713if test -z "$ac_cpp_err"; then
c0d27fcc 11714 ac_header_preproc=yes
ba4481b5 11715else
98418dba 11716 echo "$as_me: failed program was:" >&5
19650fd6
AS
11717sed 's/^/| /' conftest.$ac_ext >&5
11718
c0d27fcc 11719 ac_header_preproc=no
98418dba
CW
11720fi
11721rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11722echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11723echo "${ECHO_T}$ac_header_preproc" >&6
11724
11725# So? What about this header?
edfaf76d
LK
11726case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11727 yes:no: )
c0d27fcc
MR
11728 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
11729echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
11730 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the compiler's result" >&5
11731echo "$as_me: WARNING: jerror.h: proceeding with the compiler's result" >&2;}
11732 ac_header_preproc=yes
19650fd6 11733 ;;
edfaf76d 11734 no:yes:* )
c0d27fcc
MR
11735 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
11736echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
edfaf76d
LK
11737 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
11738echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
11739 { echo "$as_me:$LINENO: WARNING: jerror.h: see the Autoconf documentation" >&5
11740echo "$as_me: WARNING: jerror.h: see the Autoconf documentation" >&2;}
11741 { echo "$as_me:$LINENO: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&5
11742echo "$as_me: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11743 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
19650fd6 11744echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
11745 { echo "$as_me:$LINENO: WARNING: jerror.h: in the future, the compiler will take precedence" >&5
11746echo "$as_me: WARNING: jerror.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11747 (
11748 cat <<\_ASBOX
edfaf76d
LK
11749## ------------------------------------------ ##
11750## Report this to the AC_PACKAGE_NAME lists. ##
11751## ------------------------------------------ ##
19650fd6
AS
11752_ASBOX
11753 ) |
11754 sed "s/^/$as_me: WARNING: /" >&2
11755 ;;
c0d27fcc
MR
11756esac
11757echo "$as_me:$LINENO: checking for jerror.h" >&5
11758echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11759if test "${ac_cv_header_jerror_h+set}" = set; then
11760 echo $ECHO_N "(cached) $ECHO_C" >&6
11761else
11762 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 11763fi
c0d27fcc 11764echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 11765echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
11766
11767fi
98418dba 11768if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 11769 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
11770echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
11771if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 11772 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11773else
98418dba
CW
11774 ac_check_lib_save_LIBS=$LIBS
11775LIBS="-ljpeg $LIBS"
11776cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11777/* confdefs.h. */
11778_ACEOF
11779cat confdefs.h >>conftest.$ac_ext
11780cat >>conftest.$ac_ext <<_ACEOF
11781/* end confdefs.h. */
98418dba
CW
11782
11783/* Override any gcc2 internal prototype to avoid an error. */
11784#ifdef __cplusplus
11785extern "C"
11786#endif
11787/* We use char because int might match the return type of a gcc2
11788 builtin and then its argument prototype would still apply. */
11789char jpeg_destroy_compress ();
503d2be0
AS
11790int
11791main ()
11792{
98418dba 11793jpeg_destroy_compress ();
503d2be0
AS
11794 ;
11795 return 0;
11796}
11797_ACEOF
11798rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11799if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 11800 (eval $ac_link) 2>conftest.er1
503d2be0 11801 ac_status=$?
edfaf76d
LK
11802 grep -v '^ *+' conftest.er1 >conftest.err
11803 rm -f conftest.er1
11804 cat conftest.err >&5
c0d27fcc 11805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11806 (exit $ac_status); } &&
10a3b1a1
EZ
11807 { ac_try='test -z "$ac_c_werror_flag"
11808 || test ! -s conftest.err'
edfaf76d
LK
11809 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11810 (eval $ac_try) 2>&5
11811 ac_status=$?
11812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11813 (exit $ac_status); }; } &&
11814 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11816 (eval $ac_try) 2>&5
11817 ac_status=$?
c0d27fcc 11818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11819 (exit $ac_status); }; }; then
98418dba 11820 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 11821else
503d2be0 11822 echo "$as_me: failed program was:" >&5
19650fd6
AS
11823sed 's/^/| /' conftest.$ac_ext >&5
11824
98418dba 11825ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 11826fi
edfaf76d
LK
11827rm -f conftest.err conftest.$ac_objext \
11828 conftest$ac_exeext conftest.$ac_ext
98418dba 11829LIBS=$ac_check_lib_save_LIBS
ba4481b5 11830fi
c0d27fcc 11831echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
11832echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
11833if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
11834 HAVE_JPEG=yes
ba4481b5 11835fi
98418dba 11836
ba4481b5 11837fi
98418dba 11838
c0d27fcc 11839
ba4481b5 11840 fi
ba4481b5 11841
c0d27fcc 11842
98418dba 11843 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 11844 cat >>confdefs.h <<\_ACEOF
98418dba 11845#define HAVE_JPEG 1
c0d27fcc 11846_ACEOF
98418dba
CW
11847
11848 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11849/* confdefs.h. */
11850_ACEOF
11851cat confdefs.h >>conftest.$ac_ext
11852cat >>conftest.$ac_ext <<_ACEOF
11853/* end confdefs.h. */
22044edf 11854#include <jpeglib.h>
98418dba
CW
11855 version=JPEG_LIB_VERSION
11856
11857_ACEOF
11858if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11859 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 11860 cat >>confdefs.h <<\_ACEOF
98418dba 11861#define HAVE_JPEG 1
c0d27fcc 11862_ACEOF
ba4481b5 11863
98418dba 11864else
c0d27fcc 11865 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
11866echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
11867 HAVE_JPEG=no
ba4481b5 11868fi
98418dba 11869rm -f conftest*
ba4481b5 11870
98418dba
CW
11871 fi
11872fi
503d2be0 11873
98418dba
CW
11874### Use -lpng if available, unless `--with-png=no'.
11875HAVE_PNG=no
11876if test "${HAVE_X11}" = "yes"; then
11877 if test "${with_png}" != "no"; then
f57bd967
DL
11878 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
11879 # in /usr/include/libpng.
11880
11881
11882for ac_header in png.h libpng/png.h
11883do
11884as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11885if eval "test \"\${$as_ac_Header+set}\" = set"; then
11886 echo "$as_me:$LINENO: checking for $ac_header" >&5
11887echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11888if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11889 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc 11890fi
f57bd967
DL
11891echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11892echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
503d2be0 11893else
c0d27fcc 11894 # Is the header compilable?
f57bd967
DL
11895echo "$as_me:$LINENO: checking $ac_header usability" >&5
11896echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
c0d27fcc 11897cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11898/* confdefs.h. */
11899_ACEOF
11900cat confdefs.h >>conftest.$ac_ext
11901cat >>conftest.$ac_ext <<_ACEOF
11902/* end confdefs.h. */
c0d27fcc 11903$ac_includes_default
f57bd967 11904#include <$ac_header>
c0d27fcc
MR
11905_ACEOF
11906rm -f conftest.$ac_objext
11907if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 11908 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11909 ac_status=$?
edfaf76d
LK
11910 grep -v '^ *+' conftest.er1 >conftest.err
11911 rm -f conftest.er1
11912 cat conftest.err >&5
c0d27fcc
MR
11913 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11914 (exit $ac_status); } &&
10a3b1a1
EZ
11915 { ac_try='test -z "$ac_c_werror_flag"
11916 || test ! -s conftest.err'
edfaf76d
LK
11917 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11918 (eval $ac_try) 2>&5
11919 ac_status=$?
11920 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11921 (exit $ac_status); }; } &&
11922 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11923 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11924 (eval $ac_try) 2>&5
11925 ac_status=$?
11926 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11927 (exit $ac_status); }; }; then
11928 ac_header_compiler=yes
11929else
11930 echo "$as_me: failed program was:" >&5
19650fd6
AS
11931sed 's/^/| /' conftest.$ac_ext >&5
11932
c0d27fcc
MR
11933ac_header_compiler=no
11934fi
edfaf76d 11935rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11936echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11937echo "${ECHO_T}$ac_header_compiler" >&6
11938
11939# Is the header present?
f57bd967
DL
11940echo "$as_me:$LINENO: checking $ac_header presence" >&5
11941echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
c0d27fcc 11942cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11943/* confdefs.h. */
11944_ACEOF
11945cat confdefs.h >>conftest.$ac_ext
11946cat >>conftest.$ac_ext <<_ACEOF
11947/* end confdefs.h. */
f57bd967 11948#include <$ac_header>
503d2be0 11949_ACEOF
c0d27fcc 11950if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11951 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11952 ac_status=$?
6bae0ccf 11953 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11954 rm -f conftest.er1
11955 cat conftest.err >&5
c0d27fcc 11956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11957 (exit $ac_status); } >/dev/null; then
11958 if test -s conftest.err; then
11959 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 11960 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
11961 else
11962 ac_cpp_err=
11963 fi
11964else
11965 ac_cpp_err=yes
11966fi
11967if test -z "$ac_cpp_err"; then
c0d27fcc 11968 ac_header_preproc=yes
503d2be0
AS
11969else
11970 echo "$as_me: failed program was:" >&5
19650fd6
AS
11971sed 's/^/| /' conftest.$ac_ext >&5
11972
c0d27fcc 11973 ac_header_preproc=no
ba4481b5 11974fi
503d2be0 11975rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11976echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11977echo "${ECHO_T}$ac_header_preproc" >&6
11978
11979# So? What about this header?
edfaf76d
LK
11980case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11981 yes:no: )
f57bd967
DL
11982 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11983echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
11984 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11985echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11986 ac_header_preproc=yes
19650fd6 11987 ;;
edfaf76d 11988 no:yes:* )
f57bd967
DL
11989 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11990echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
11991 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11992echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11993 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11994echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11995 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11996echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
f57bd967 11997 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 11998echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
11999 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12000echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12001 (
12002 cat <<\_ASBOX
edfaf76d
LK
12003## ------------------------------------------ ##
12004## Report this to the AC_PACKAGE_NAME lists. ##
12005## ------------------------------------------ ##
19650fd6
AS
12006_ASBOX
12007 ) |
12008 sed "s/^/$as_me: WARNING: /" >&2
12009 ;;
c0d27fcc 12010esac
f57bd967
DL
12011echo "$as_me:$LINENO: checking for $ac_header" >&5
12012echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12013if eval "test \"\${$as_ac_Header+set}\" = set"; then
c0d27fcc
MR
12014 echo $ECHO_N "(cached) $ECHO_C" >&6
12015else
edfaf76d 12016 eval "$as_ac_Header=\$ac_header_preproc"
f57bd967
DL
12017fi
12018echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12019echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12020
ba4481b5 12021fi
f57bd967
DL
12022if test `eval echo '${'$as_ac_Header'}'` = yes; then
12023 cat >>confdefs.h <<_ACEOF
12024#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12025_ACEOF
c0d27fcc
MR
12026
12027fi
f57bd967
DL
12028
12029done
12030
12031 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12032 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
12033echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
12034if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 12035 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12036else
98418dba
CW
12037 ac_check_lib_save_LIBS=$LIBS
12038LIBS="-lpng -lz -lm $LIBS"
12039cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12040/* confdefs.h. */
12041_ACEOF
12042cat confdefs.h >>conftest.$ac_ext
12043cat >>conftest.$ac_ext <<_ACEOF
12044/* end confdefs.h. */
98418dba 12045
ba4481b5 12046/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12047#ifdef __cplusplus
12048extern "C"
12049#endif
ba4481b5 12050/* We use char because int might match the return type of a gcc2
503d2be0 12051 builtin and then its argument prototype would still apply. */
98418dba 12052char png_get_channels ();
503d2be0
AS
12053int
12054main ()
12055{
98418dba 12056png_get_channels ();
503d2be0
AS
12057 ;
12058 return 0;
12059}
12060_ACEOF
12061rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12062if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 12063 (eval $ac_link) 2>conftest.er1
503d2be0 12064 ac_status=$?
edfaf76d
LK
12065 grep -v '^ *+' conftest.er1 >conftest.err
12066 rm -f conftest.er1
12067 cat conftest.err >&5
c0d27fcc 12068 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12069 (exit $ac_status); } &&
10a3b1a1
EZ
12070 { ac_try='test -z "$ac_c_werror_flag"
12071 || test ! -s conftest.err'
edfaf76d
LK
12072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12073 (eval $ac_try) 2>&5
12074 ac_status=$?
12075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12076 (exit $ac_status); }; } &&
12077 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12079 (eval $ac_try) 2>&5
12080 ac_status=$?
c0d27fcc 12081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12082 (exit $ac_status); }; }; then
98418dba 12083 ac_cv_lib_png_png_get_channels=yes
73b77ee5 12084else
98418dba 12085 echo "$as_me: failed program was:" >&5
19650fd6
AS
12086sed 's/^/| /' conftest.$ac_ext >&5
12087
98418dba 12088ac_cv_lib_png_png_get_channels=no
73b77ee5 12089fi
edfaf76d
LK
12090rm -f conftest.err conftest.$ac_objext \
12091 conftest$ac_exeext conftest.$ac_ext
98418dba 12092LIBS=$ac_check_lib_save_LIBS
73b77ee5 12093fi
c0d27fcc 12094echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
12095echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
12096if test $ac_cv_lib_png_png_get_channels = yes; then
12097 HAVE_PNG=yes
73b77ee5 12098fi
503d2be0 12099
f57bd967 12100 fi
98418dba
CW
12101 fi
12102
12103 if test "${HAVE_PNG}" = "yes"; then
b936fae4 12104
c0d27fcc 12105cat >>confdefs.h <<\_ACEOF
98418dba 12106#define HAVE_PNG 1
c0d27fcc 12107_ACEOF
73b77ee5 12108
98418dba 12109 fi
73b77ee5
GM
12110fi
12111
98418dba
CW
12112### Use -ltiff if available, unless `--with-tiff=no'.
12113HAVE_TIFF=no
12114if test "${HAVE_X11}" = "yes"; then
12115 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
12116 if test "${ac_cv_header_tiffio_h+set}" = set; then
12117 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
12118echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
12119if test "${ac_cv_header_tiffio_h+set}" = set; then
12120 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12121fi
12122echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
12123echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 12124else
c0d27fcc
MR
12125 # Is the header compilable?
12126echo "$as_me:$LINENO: checking tiffio.h usability" >&5
12127echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
12128cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12129/* confdefs.h. */
12130_ACEOF
12131cat confdefs.h >>conftest.$ac_ext
12132cat >>conftest.$ac_ext <<_ACEOF
12133/* end confdefs.h. */
c0d27fcc
MR
12134$ac_includes_default
12135#include <tiffio.h>
12136_ACEOF
12137rm -f conftest.$ac_objext
12138if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 12139 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12140 ac_status=$?
edfaf76d
LK
12141 grep -v '^ *+' conftest.er1 >conftest.err
12142 rm -f conftest.er1
12143 cat conftest.err >&5
c0d27fcc
MR
12144 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12145 (exit $ac_status); } &&
10a3b1a1
EZ
12146 { ac_try='test -z "$ac_c_werror_flag"
12147 || test ! -s conftest.err'
edfaf76d
LK
12148 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12149 (eval $ac_try) 2>&5
12150 ac_status=$?
12151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12152 (exit $ac_status); }; } &&
12153 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12154 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12155 (eval $ac_try) 2>&5
12156 ac_status=$?
12157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12158 (exit $ac_status); }; }; then
12159 ac_header_compiler=yes
12160else
12161 echo "$as_me: failed program was:" >&5
19650fd6
AS
12162sed 's/^/| /' conftest.$ac_ext >&5
12163
c0d27fcc
MR
12164ac_header_compiler=no
12165fi
edfaf76d 12166rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12167echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12168echo "${ECHO_T}$ac_header_compiler" >&6
12169
12170# Is the header present?
12171echo "$as_me:$LINENO: checking tiffio.h presence" >&5
12172echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
12173cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12174/* confdefs.h. */
12175_ACEOF
12176cat confdefs.h >>conftest.$ac_ext
12177cat >>conftest.$ac_ext <<_ACEOF
12178/* end confdefs.h. */
98418dba
CW
12179#include <tiffio.h>
12180_ACEOF
c0d27fcc 12181if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12182 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12183 ac_status=$?
6bae0ccf 12184 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12185 rm -f conftest.er1
12186 cat conftest.err >&5
c0d27fcc 12187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12188 (exit $ac_status); } >/dev/null; then
12189 if test -s conftest.err; then
12190 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 12191 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12192 else
12193 ac_cpp_err=
12194 fi
12195else
12196 ac_cpp_err=yes
12197fi
12198if test -z "$ac_cpp_err"; then
c0d27fcc 12199 ac_header_preproc=yes
98418dba
CW
12200else
12201 echo "$as_me: failed program was:" >&5
19650fd6
AS
12202sed 's/^/| /' conftest.$ac_ext >&5
12203
c0d27fcc 12204 ac_header_preproc=no
98418dba
CW
12205fi
12206rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12207echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12208echo "${ECHO_T}$ac_header_preproc" >&6
12209
12210# So? What about this header?
edfaf76d
LK
12211case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12212 yes:no: )
c0d27fcc
MR
12213 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
12214echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
12215 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the compiler's result" >&5
12216echo "$as_me: WARNING: tiffio.h: proceeding with the compiler's result" >&2;}
12217 ac_header_preproc=yes
19650fd6 12218 ;;
edfaf76d 12219 no:yes:* )
c0d27fcc
MR
12220 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
12221echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
edfaf76d
LK
12222 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
12223echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
12224 { echo "$as_me:$LINENO: WARNING: tiffio.h: see the Autoconf documentation" >&5
12225echo "$as_me: WARNING: tiffio.h: see the Autoconf documentation" >&2;}
12226 { echo "$as_me:$LINENO: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&5
12227echo "$as_me: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12228 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
19650fd6 12229echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
12230 { echo "$as_me:$LINENO: WARNING: tiffio.h: in the future, the compiler will take precedence" >&5
12231echo "$as_me: WARNING: tiffio.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12232 (
12233 cat <<\_ASBOX
edfaf76d
LK
12234## ------------------------------------------ ##
12235## Report this to the AC_PACKAGE_NAME lists. ##
12236## ------------------------------------------ ##
19650fd6
AS
12237_ASBOX
12238 ) |
12239 sed "s/^/$as_me: WARNING: /" >&2
12240 ;;
c0d27fcc
MR
12241esac
12242echo "$as_me:$LINENO: checking for tiffio.h" >&5
12243echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
12244if test "${ac_cv_header_tiffio_h+set}" = set; then
12245 echo $ECHO_N "(cached) $ECHO_C" >&6
12246else
12247 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 12248fi
c0d27fcc 12249echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 12250echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
12251
12252fi
98418dba
CW
12253if test $ac_cv_header_tiffio_h = yes; then
12254 tifflibs="-lz -lm"
12255 # At least one tiff package requires the jpeg library.
12256 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 12257 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
12258echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
12259if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 12260 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12261else
503d2be0 12262 ac_check_lib_save_LIBS=$LIBS
98418dba 12263LIBS="-ltiff $tifflibs $LIBS"
503d2be0 12264cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12265/* confdefs.h. */
12266_ACEOF
12267cat confdefs.h >>conftest.$ac_ext
12268cat >>conftest.$ac_ext <<_ACEOF
12269/* end confdefs.h. */
503d2be0 12270
73b77ee5 12271/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12272#ifdef __cplusplus
12273extern "C"
12274#endif
73b77ee5 12275/* We use char because int might match the return type of a gcc2
503d2be0 12276 builtin and then its argument prototype would still apply. */
98418dba 12277char TIFFGetVersion ();
503d2be0
AS
12278int
12279main ()
12280{
98418dba 12281TIFFGetVersion ();
503d2be0
AS
12282 ;
12283 return 0;
12284}
12285_ACEOF
12286rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12287if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 12288 (eval $ac_link) 2>conftest.er1
503d2be0 12289 ac_status=$?
edfaf76d
LK
12290 grep -v '^ *+' conftest.er1 >conftest.err
12291 rm -f conftest.er1
12292 cat conftest.err >&5
c0d27fcc 12293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12294 (exit $ac_status); } &&
10a3b1a1
EZ
12295 { ac_try='test -z "$ac_c_werror_flag"
12296 || test ! -s conftest.err'
edfaf76d
LK
12297 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12298 (eval $ac_try) 2>&5
12299 ac_status=$?
12300 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12301 (exit $ac_status); }; } &&
12302 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12303 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12304 (eval $ac_try) 2>&5
12305 ac_status=$?
c0d27fcc 12306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12307 (exit $ac_status); }; }; then
98418dba 12308 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
12309else
12310 echo "$as_me: failed program was:" >&5
19650fd6
AS
12311sed 's/^/| /' conftest.$ac_ext >&5
12312
98418dba 12313ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0 12314fi
edfaf76d
LK
12315rm -f conftest.err conftest.$ac_objext \
12316 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
12317LIBS=$ac_check_lib_save_LIBS
12318fi
c0d27fcc 12319echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
12320echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
12321if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
12322 HAVE_TIFF=yes
12323fi
12324
12325fi
73b77ee5 12326
c0d27fcc 12327
98418dba
CW
12328 fi
12329
12330 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 12331
c0d27fcc 12332cat >>confdefs.h <<\_ACEOF
98418dba 12333#define HAVE_TIFF 1
c0d27fcc 12334_ACEOF
98418dba
CW
12335
12336 fi
73b77ee5
GM
12337fi
12338
98418dba
CW
12339### Use -lgif if available, unless `--with-gif=no'.
12340HAVE_GIF=no
12341if test "${HAVE_X11}" = "yes"; then
12342 if test "${with_gif}" != "no"; then
c0d27fcc
MR
12343 if test "${ac_cv_header_gif_lib_h+set}" = set; then
12344 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
12345echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
12346if test "${ac_cv_header_gif_lib_h+set}" = set; then
12347 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12348fi
12349echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
12350echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 12351else
c0d27fcc
MR
12352 # Is the header compilable?
12353echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
12354echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
12355cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12356/* confdefs.h. */
12357_ACEOF
12358cat confdefs.h >>conftest.$ac_ext
12359cat >>conftest.$ac_ext <<_ACEOF
12360/* end confdefs.h. */
c0d27fcc
MR
12361$ac_includes_default
12362#include <gif_lib.h>
12363_ACEOF
12364rm -f conftest.$ac_objext
12365if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 12366 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12367 ac_status=$?
edfaf76d
LK
12368 grep -v '^ *+' conftest.er1 >conftest.err
12369 rm -f conftest.er1
12370 cat conftest.err >&5
c0d27fcc
MR
12371 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12372 (exit $ac_status); } &&
10a3b1a1
EZ
12373 { ac_try='test -z "$ac_c_werror_flag"
12374 || test ! -s conftest.err'
edfaf76d
LK
12375 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12376 (eval $ac_try) 2>&5
12377 ac_status=$?
12378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12379 (exit $ac_status); }; } &&
12380 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12381 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12382 (eval $ac_try) 2>&5
12383 ac_status=$?
12384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12385 (exit $ac_status); }; }; then
12386 ac_header_compiler=yes
12387else
12388 echo "$as_me: failed program was:" >&5
19650fd6
AS
12389sed 's/^/| /' conftest.$ac_ext >&5
12390
c0d27fcc
MR
12391ac_header_compiler=no
12392fi
edfaf76d 12393rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12394echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12395echo "${ECHO_T}$ac_header_compiler" >&6
12396
12397# Is the header present?
12398echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
12399echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
12400cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12401/* confdefs.h. */
12402_ACEOF
12403cat confdefs.h >>conftest.$ac_ext
12404cat >>conftest.$ac_ext <<_ACEOF
12405/* end confdefs.h. */
98418dba
CW
12406#include <gif_lib.h>
12407_ACEOF
c0d27fcc 12408if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12409 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12410 ac_status=$?
6bae0ccf 12411 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12412 rm -f conftest.er1
12413 cat conftest.err >&5
c0d27fcc 12414 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12415 (exit $ac_status); } >/dev/null; then
12416 if test -s conftest.err; then
12417 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 12418 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12419 else
12420 ac_cpp_err=
12421 fi
12422else
12423 ac_cpp_err=yes
12424fi
12425if test -z "$ac_cpp_err"; then
c0d27fcc 12426 ac_header_preproc=yes
98418dba
CW
12427else
12428 echo "$as_me: failed program was:" >&5
19650fd6
AS
12429sed 's/^/| /' conftest.$ac_ext >&5
12430
c0d27fcc 12431 ac_header_preproc=no
98418dba
CW
12432fi
12433rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12434echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12435echo "${ECHO_T}$ac_header_preproc" >&6
12436
12437# So? What about this header?
edfaf76d
LK
12438case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12439 yes:no: )
c0d27fcc
MR
12440 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12441echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
12442 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the compiler's result" >&5
12443echo "$as_me: WARNING: gif_lib.h: proceeding with the compiler's result" >&2;}
12444 ac_header_preproc=yes
19650fd6 12445 ;;
edfaf76d 12446 no:yes:* )
c0d27fcc
MR
12447 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
12448echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
edfaf76d
LK
12449 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
12450echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
12451 { echo "$as_me:$LINENO: WARNING: gif_lib.h: see the Autoconf documentation" >&5
12452echo "$as_me: WARNING: gif_lib.h: see the Autoconf documentation" >&2;}
12453 { echo "$as_me:$LINENO: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&5
12454echo "$as_me: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12455 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
19650fd6 12456echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
12457 { echo "$as_me:$LINENO: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&5
12458echo "$as_me: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12459 (
12460 cat <<\_ASBOX
edfaf76d
LK
12461## ------------------------------------------ ##
12462## Report this to the AC_PACKAGE_NAME lists. ##
12463## ------------------------------------------ ##
19650fd6
AS
12464_ASBOX
12465 ) |
12466 sed "s/^/$as_me: WARNING: /" >&2
12467 ;;
c0d27fcc
MR
12468esac
12469echo "$as_me:$LINENO: checking for gif_lib.h" >&5
12470echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
12471if test "${ac_cv_header_gif_lib_h+set}" = set; then
12472 echo $ECHO_N "(cached) $ECHO_C" >&6
12473else
12474 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 12475fi
c0d27fcc 12476echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 12477echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
12478
12479fi
98418dba
CW
12480if test $ac_cv_header_gif_lib_h = yes; then
12481 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12482# Earlier versions can crash Emacs.
c0d27fcc 12483 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
12484echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
12485if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 12486 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12487else
503d2be0 12488 ac_check_lib_save_LIBS=$LIBS
98418dba 12489LIBS="-lungif $LIBS"
503d2be0 12490cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12491/* confdefs.h. */
12492_ACEOF
12493cat confdefs.h >>conftest.$ac_ext
12494cat >>conftest.$ac_ext <<_ACEOF
12495/* end confdefs.h. */
73b77ee5 12496
98418dba
CW
12497/* Override any gcc2 internal prototype to avoid an error. */
12498#ifdef __cplusplus
12499extern "C"
12500#endif
12501/* We use char because int might match the return type of a gcc2
12502 builtin and then its argument prototype would still apply. */
12503char EGifPutExtensionLast ();
503d2be0
AS
12504int
12505main ()
12506{
98418dba 12507EGifPutExtensionLast ();
503d2be0
AS
12508 ;
12509 return 0;
12510}
12511_ACEOF
12512rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12513if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 12514 (eval $ac_link) 2>conftest.er1
503d2be0 12515 ac_status=$?
edfaf76d
LK
12516 grep -v '^ *+' conftest.er1 >conftest.err
12517 rm -f conftest.er1
12518 cat conftest.err >&5
c0d27fcc 12519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12520 (exit $ac_status); } &&
10a3b1a1
EZ
12521 { ac_try='test -z "$ac_c_werror_flag"
12522 || test ! -s conftest.err'
edfaf76d
LK
12523 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12524 (eval $ac_try) 2>&5
12525 ac_status=$?
12526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12527 (exit $ac_status); }; } &&
12528 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
12529 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12530 (eval $ac_try) 2>&5
12531 ac_status=$?
12532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12533 (exit $ac_status); }; }; then
12534 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12535else
98418dba 12536 echo "$as_me: failed program was:" >&5
19650fd6
AS
12537sed 's/^/| /' conftest.$ac_ext >&5
12538
98418dba
CW
12539ac_cv_lib_ungif_EGifPutExtensionLast=no
12540fi
edfaf76d
LK
12541rm -f conftest.err conftest.$ac_objext \
12542 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12543LIBS=$ac_check_lib_save_LIBS
12544fi
c0d27fcc 12545echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
12546echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
12547if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
12548 HAVE_GIF=yes
12549fi
12550
12551fi
12552
c0d27fcc 12553
98418dba
CW
12554 fi
12555
12556 if test "${HAVE_GIF}" = "yes"; then
b936fae4 12557
c0d27fcc 12558cat >>confdefs.h <<\_ACEOF
98418dba 12559#define HAVE_GIF 1
c0d27fcc 12560_ACEOF
98418dba
CW
12561
12562 fi
12563fi
12564
cef11da2
ST
12565if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
12566 echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
12567echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6
12568if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
12569 echo $ECHO_N "(cached) $ECHO_C" >&6
12570fi
12571echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
12572echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6
12573else
12574 # Is the header compilable?
12575echo "$as_me:$LINENO: checking malloc/malloc.h usability" >&5
12576echo $ECHO_N "checking malloc/malloc.h usability... $ECHO_C" >&6
12577cat >conftest.$ac_ext <<_ACEOF
12578/* confdefs.h. */
12579_ACEOF
12580cat confdefs.h >>conftest.$ac_ext
12581cat >>conftest.$ac_ext <<_ACEOF
12582/* end confdefs.h. */
12583$ac_includes_default
12584#include <malloc/malloc.h>
12585_ACEOF
12586rm -f conftest.$ac_objext
12587if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 12588 (eval $ac_compile) 2>conftest.er1
cef11da2 12589 ac_status=$?
edfaf76d
LK
12590 grep -v '^ *+' conftest.er1 >conftest.err
12591 rm -f conftest.er1
12592 cat conftest.err >&5
cef11da2
ST
12593 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12594 (exit $ac_status); } &&
10a3b1a1
EZ
12595 { ac_try='test -z "$ac_c_werror_flag"
12596 || test ! -s conftest.err'
edfaf76d
LK
12597 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12598 (eval $ac_try) 2>&5
12599 ac_status=$?
12600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12601 (exit $ac_status); }; } &&
12602 { ac_try='test -s conftest.$ac_objext'
cef11da2
ST
12603 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12604 (eval $ac_try) 2>&5
12605 ac_status=$?
12606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12607 (exit $ac_status); }; }; then
12608 ac_header_compiler=yes
12609else
12610 echo "$as_me: failed program was:" >&5
12611sed 's/^/| /' conftest.$ac_ext >&5
12612
12613ac_header_compiler=no
12614fi
edfaf76d 12615rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cef11da2
ST
12616echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12617echo "${ECHO_T}$ac_header_compiler" >&6
12618
12619# Is the header present?
12620echo "$as_me:$LINENO: checking malloc/malloc.h presence" >&5
12621echo $ECHO_N "checking malloc/malloc.h presence... $ECHO_C" >&6
12622cat >conftest.$ac_ext <<_ACEOF
12623/* confdefs.h. */
12624_ACEOF
12625cat confdefs.h >>conftest.$ac_ext
12626cat >>conftest.$ac_ext <<_ACEOF
12627/* end confdefs.h. */
12628#include <malloc/malloc.h>
12629_ACEOF
12630if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12631 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12632 ac_status=$?
12633 grep -v '^ *+' conftest.er1 >conftest.err
12634 rm -f conftest.er1
12635 cat conftest.err >&5
12636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12637 (exit $ac_status); } >/dev/null; then
12638 if test -s conftest.err; then
12639 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 12640 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
cef11da2
ST
12641 else
12642 ac_cpp_err=
12643 fi
12644else
12645 ac_cpp_err=yes
12646fi
12647if test -z "$ac_cpp_err"; then
12648 ac_header_preproc=yes
12649else
12650 echo "$as_me: failed program was:" >&5
12651sed 's/^/| /' conftest.$ac_ext >&5
12652
12653 ac_header_preproc=no
12654fi
12655rm -f conftest.err conftest.$ac_ext
12656echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12657echo "${ECHO_T}$ac_header_preproc" >&6
12658
12659# So? What about this header?
edfaf76d
LK
12660case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12661 yes:no: )
cef11da2
ST
12662 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&5
12663echo "$as_me: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
12664 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the compiler's result" >&5
12665echo "$as_me: WARNING: malloc/malloc.h: proceeding with the compiler's result" >&2;}
12666 ac_header_preproc=yes
cef11da2 12667 ;;
edfaf76d 12668 no:yes:* )
cef11da2
ST
12669 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: present but cannot be compiled" >&5
12670echo "$as_me: WARNING: malloc/malloc.h: present but cannot be compiled" >&2;}
edfaf76d
LK
12671 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: check for missing prerequisite headers?" >&5
12672echo "$as_me: WARNING: malloc/malloc.h: check for missing prerequisite headers?" >&2;}
12673 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: see the Autoconf documentation" >&5
12674echo "$as_me: WARNING: malloc/malloc.h: see the Autoconf documentation" >&2;}
12675 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: section \"Present But Cannot Be Compiled\"" >&5
12676echo "$as_me: WARNING: malloc/malloc.h: section \"Present But Cannot Be Compiled\"" >&2;}
cef11da2
ST
12677 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&5
12678echo "$as_me: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
12679 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: in the future, the compiler will take precedence" >&5
12680echo "$as_me: WARNING: malloc/malloc.h: in the future, the compiler will take precedence" >&2;}
cef11da2
ST
12681 (
12682 cat <<\_ASBOX
edfaf76d
LK
12683## ------------------------------------------ ##
12684## Report this to the AC_PACKAGE_NAME lists. ##
12685## ------------------------------------------ ##
cef11da2
ST
12686_ASBOX
12687 ) |
12688 sed "s/^/$as_me: WARNING: /" >&2
12689 ;;
12690esac
12691echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
12692echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6
12693if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
12694 echo $ECHO_N "(cached) $ECHO_C" >&6
12695else
12696 ac_cv_header_malloc_malloc_h=$ac_header_preproc
12697fi
12698echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
12699echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6
12700
12701fi
12702if test $ac_cv_header_malloc_malloc_h = yes; then
12703
12704cat >>confdefs.h <<\_ACEOF
12705#define HAVE_MALLOC_MALLOC_H 1
12706_ACEOF
12707
12708fi
12709
12710
12711
5d6da11e 12712### Use Mac OS X Carbon API to implement GUI.
e0f712ba 12713if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 12714
c0d27fcc 12715cat >>confdefs.h <<\_ACEOF
e0f712ba 12716#define HAVE_CARBON 1
c0d27fcc 12717_ACEOF
e0f712ba 12718
6a3a24fa
JD
12719 window_system=mac
12720 ## Specify the install directory
12721 carbon_appdir=
12722 if test "${carbon_appdir_x}" != ""; then
12723 case ${carbon_appdir_x} in
12724 y | ye | yes) carbon_appdir=/Applications ;;
12725 * ) carbon_appdir=${carbon_appdir_x} ;;
12726 esac
12727 fi
8f417b3b
AS
12728 # We also have mouse menus.
12729 HAVE_MENUS=yes
7c9e5167
JD
12730
12731 tmp_CFLAGS="$CFLAGS"
12732 CFLAGS="$CFLAGS -framework Carbon"
12733 echo "$as_me:$LINENO: checking for CancelMenuTracking" >&5
12734echo $ECHO_N "checking for CancelMenuTracking... $ECHO_C" >&6
12735if test "${ac_cv_func_CancelMenuTracking+set}" = set; then
12736 echo $ECHO_N "(cached) $ECHO_C" >&6
12737else
12738 cat >conftest.$ac_ext <<_ACEOF
7c9e5167
JD
12739/* confdefs.h. */
12740_ACEOF
12741cat confdefs.h >>conftest.$ac_ext
12742cat >>conftest.$ac_ext <<_ACEOF
12743/* end confdefs.h. */
edfaf76d
LK
12744/* Define CancelMenuTracking to an innocuous variant, in case <limits.h> declares CancelMenuTracking.
12745 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12746#define CancelMenuTracking innocuous_CancelMenuTracking
12747
7c9e5167
JD
12748/* System header to define __stub macros and hopefully few prototypes,
12749 which can conflict with char CancelMenuTracking (); below.
12750 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12751 <limits.h> exists even on freestanding compilers. */
edfaf76d 12752
7c9e5167
JD
12753#ifdef __STDC__
12754# include <limits.h>
12755#else
12756# include <assert.h>
12757#endif
edfaf76d
LK
12758
12759#undef CancelMenuTracking
12760
7c9e5167
JD
12761/* Override any gcc2 internal prototype to avoid an error. */
12762#ifdef __cplusplus
12763extern "C"
12764{
12765#endif
12766/* We use char because int might match the return type of a gcc2
12767 builtin and then its argument prototype would still apply. */
12768char CancelMenuTracking ();
12769/* The GNU C library defines this for functions which it implements
12770 to always fail with ENOSYS. Some functions are actually named
12771 something starting with __ and the normal name is an alias. */
12772#if defined (__stub_CancelMenuTracking) || defined (__stub___CancelMenuTracking)
12773choke me
12774#else
12775char (*f) () = CancelMenuTracking;
12776#endif
12777#ifdef __cplusplus
12778}
12779#endif
12780
12781int
12782main ()
12783{
12784return f != CancelMenuTracking;
12785 ;
12786 return 0;
12787}
12788_ACEOF
12789rm -f conftest.$ac_objext conftest$ac_exeext
12790if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 12791 (eval $ac_link) 2>conftest.er1
7c9e5167 12792 ac_status=$?
edfaf76d
LK
12793 grep -v '^ *+' conftest.er1 >conftest.err
12794 rm -f conftest.er1
12795 cat conftest.err >&5
7c9e5167
JD
12796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12797 (exit $ac_status); } &&
10a3b1a1
EZ
12798 { ac_try='test -z "$ac_c_werror_flag"
12799 || test ! -s conftest.err'
edfaf76d
LK
12800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12801 (eval $ac_try) 2>&5
12802 ac_status=$?
12803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12804 (exit $ac_status); }; } &&
12805 { ac_try='test -s conftest$ac_exeext'
7c9e5167
JD
12806 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12807 (eval $ac_try) 2>&5
12808 ac_status=$?
12809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12810 (exit $ac_status); }; }; then
12811 ac_cv_func_CancelMenuTracking=yes
12812else
12813 echo "$as_me: failed program was:" >&5
12814sed 's/^/| /' conftest.$ac_ext >&5
12815
12816ac_cv_func_CancelMenuTracking=no
12817fi
edfaf76d
LK
12818rm -f conftest.err conftest.$ac_objext \
12819 conftest$ac_exeext conftest.$ac_ext
7c9e5167
JD
12820fi
12821echo "$as_me:$LINENO: result: $ac_cv_func_CancelMenuTracking" >&5
12822echo "${ECHO_T}$ac_cv_func_CancelMenuTracking" >&6
12823if test $ac_cv_func_CancelMenuTracking = yes; then
12824 have_cmt=yes
12825else
12826 have_cmt=no
12827fi
12828
12829 if test "$have_cmt" = yes; then
12830
12831cat >>confdefs.h <<\_ACEOF
12832#define HAVE_CANCELMENUTRACKING 1
12833_ACEOF
12834
12835 fi
12836 CFLAGS="$tmp_CFLAGS"
e0f712ba
AC
12837fi
12838
98418dba
CW
12839### Use session management (-lSM -lICE) if available
12840HAVE_X_SM=no
12841if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
12842 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12843 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
12844echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12845if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12846 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12847fi
12848echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
12849echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 12850else
c0d27fcc
MR
12851 # Is the header compilable?
12852echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
12853echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
12854cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12855/* confdefs.h. */
12856_ACEOF
12857cat confdefs.h >>conftest.$ac_ext
12858cat >>conftest.$ac_ext <<_ACEOF
12859/* end confdefs.h. */
c0d27fcc
MR
12860$ac_includes_default
12861#include <X11/SM/SMlib.h>
12862_ACEOF
12863rm -f conftest.$ac_objext
12864if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 12865 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12866 ac_status=$?
edfaf76d
LK
12867 grep -v '^ *+' conftest.er1 >conftest.err
12868 rm -f conftest.er1
12869 cat conftest.err >&5
c0d27fcc
MR
12870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12871 (exit $ac_status); } &&
10a3b1a1
EZ
12872 { ac_try='test -z "$ac_c_werror_flag"
12873 || test ! -s conftest.err'
edfaf76d
LK
12874 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12875 (eval $ac_try) 2>&5
12876 ac_status=$?
12877 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12878 (exit $ac_status); }; } &&
12879 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12880 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12881 (eval $ac_try) 2>&5
12882 ac_status=$?
12883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12884 (exit $ac_status); }; }; then
12885 ac_header_compiler=yes
12886else
12887 echo "$as_me: failed program was:" >&5
19650fd6
AS
12888sed 's/^/| /' conftest.$ac_ext >&5
12889
c0d27fcc
MR
12890ac_header_compiler=no
12891fi
edfaf76d 12892rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12893echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12894echo "${ECHO_T}$ac_header_compiler" >&6
12895
12896# Is the header present?
12897echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
12898echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
12899cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12900/* confdefs.h. */
12901_ACEOF
12902cat confdefs.h >>conftest.$ac_ext
12903cat >>conftest.$ac_ext <<_ACEOF
12904/* end confdefs.h. */
98418dba
CW
12905#include <X11/SM/SMlib.h>
12906_ACEOF
c0d27fcc 12907if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12908 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12909 ac_status=$?
6bae0ccf 12910 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12911 rm -f conftest.er1
12912 cat conftest.err >&5
c0d27fcc 12913 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12914 (exit $ac_status); } >/dev/null; then
12915 if test -s conftest.err; then
12916 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 12917 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12918 else
12919 ac_cpp_err=
12920 fi
12921else
12922 ac_cpp_err=yes
503d2be0 12923fi
98418dba 12924if test -z "$ac_cpp_err"; then
c0d27fcc 12925 ac_header_preproc=yes
98418dba
CW
12926else
12927 echo "$as_me: failed program was:" >&5
19650fd6
AS
12928sed 's/^/| /' conftest.$ac_ext >&5
12929
c0d27fcc 12930 ac_header_preproc=no
98418dba
CW
12931fi
12932rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12933echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12934echo "${ECHO_T}$ac_header_preproc" >&6
12935
12936# So? What about this header?
edfaf76d
LK
12937case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12938 yes:no: )
c0d27fcc
MR
12939 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12940echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
12941 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&5
12942echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&2;}
12943 ac_header_preproc=yes
19650fd6 12944 ;;
edfaf76d 12945 no:yes:* )
c0d27fcc
MR
12946 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
12947echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
edfaf76d
LK
12948 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
12949echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
12950 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&5
12951echo "$as_me: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&2;}
12952 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&5
12953echo "$as_me: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12954 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
19650fd6 12955echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
12956 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&5
12957echo "$as_me: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12958 (
12959 cat <<\_ASBOX
edfaf76d
LK
12960## ------------------------------------------ ##
12961## Report this to the AC_PACKAGE_NAME lists. ##
12962## ------------------------------------------ ##
19650fd6
AS
12963_ASBOX
12964 ) |
12965 sed "s/^/$as_me: WARNING: /" >&2
12966 ;;
c0d27fcc
MR
12967esac
12968echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
12969echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12970if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12971 echo $ECHO_N "(cached) $ECHO_C" >&6
12972else
12973 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 12974fi
c0d27fcc 12975echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 12976echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
12977
12978fi
98418dba 12979if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 12980 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
12981echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
12982if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 12983 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12984else
503d2be0 12985 ac_check_lib_save_LIBS=$LIBS
1660500f 12986LIBS="-lSM -lICE $LIBS"
503d2be0 12987cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12988/* confdefs.h. */
12989_ACEOF
12990cat confdefs.h >>conftest.$ac_ext
12991cat >>conftest.$ac_ext <<_ACEOF
12992/* end confdefs.h. */
503d2be0 12993
73b77ee5 12994/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12995#ifdef __cplusplus
12996extern "C"
12997#endif
73b77ee5 12998/* We use char because int might match the return type of a gcc2
503d2be0 12999 builtin and then its argument prototype would still apply. */
98418dba 13000char SmcOpenConnection ();
503d2be0
AS
13001int
13002main ()
13003{
98418dba 13004SmcOpenConnection ();
503d2be0
AS
13005 ;
13006 return 0;
13007}
13008_ACEOF
13009rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13010if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13011 (eval $ac_link) 2>conftest.er1
503d2be0 13012 ac_status=$?
edfaf76d
LK
13013 grep -v '^ *+' conftest.er1 >conftest.err
13014 rm -f conftest.er1
13015 cat conftest.err >&5
c0d27fcc 13016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13017 (exit $ac_status); } &&
10a3b1a1
EZ
13018 { ac_try='test -z "$ac_c_werror_flag"
13019 || test ! -s conftest.err'
edfaf76d
LK
13020 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13021 (eval $ac_try) 2>&5
13022 ac_status=$?
13023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13024 (exit $ac_status); }; } &&
13025 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13027 (eval $ac_try) 2>&5
13028 ac_status=$?
c0d27fcc 13029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13030 (exit $ac_status); }; }; then
98418dba 13031 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
13032else
13033 echo "$as_me: failed program was:" >&5
19650fd6
AS
13034sed 's/^/| /' conftest.$ac_ext >&5
13035
98418dba 13036ac_cv_lib_SM_SmcOpenConnection=no
503d2be0 13037fi
edfaf76d
LK
13038rm -f conftest.err conftest.$ac_objext \
13039 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
13040LIBS=$ac_check_lib_save_LIBS
13041fi
c0d27fcc 13042echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
13043echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
13044if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
13045 HAVE_X_SM=yes
73b77ee5
GM
13046fi
13047
73b77ee5 13048fi
73b77ee5 13049
c0d27fcc
MR
13050
13051
98418dba 13052 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 13053
c0d27fcc 13054cat >>confdefs.h <<\_ACEOF
98418dba 13055#define HAVE_X_SM 1
c0d27fcc 13056_ACEOF
73b77ee5 13057
98418dba
CW
13058 case "$LIBS" in
13059 *-lSM*) ;;
13060 *) LIBS="-lSM -lICE $LIBS" ;;
13061 esac
73b77ee5 13062 fi
98418dba 13063fi
73b77ee5 13064
98418dba 13065# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 13066echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
13067echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
13068if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
13069 echo $ECHO_N "(cached) $ECHO_C" >&6
13070else
13071 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13072/* confdefs.h. */
13073_ACEOF
13074cat confdefs.h >>conftest.$ac_ext
13075cat >>conftest.$ac_ext <<_ACEOF
13076/* end confdefs.h. */
98418dba 13077#include <netdb.h>
503d2be0
AS
13078int
13079main ()
13080{
98418dba 13081return h_errno;
503d2be0
AS
13082 ;
13083 return 0;
13084}
13085_ACEOF
13086rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13087if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13088 (eval $ac_link) 2>conftest.er1
503d2be0 13089 ac_status=$?
edfaf76d
LK
13090 grep -v '^ *+' conftest.er1 >conftest.err
13091 rm -f conftest.er1
13092 cat conftest.err >&5
c0d27fcc 13093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13094 (exit $ac_status); } &&
10a3b1a1
EZ
13095 { ac_try='test -z "$ac_c_werror_flag"
13096 || test ! -s conftest.err'
edfaf76d
LK
13097 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13098 (eval $ac_try) 2>&5
13099 ac_status=$?
13100 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13101 (exit $ac_status); }; } &&
13102 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13103 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13104 (eval $ac_try) 2>&5
13105 ac_status=$?
c0d27fcc 13106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13107 (exit $ac_status); }; }; then
98418dba 13108 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 13109else
503d2be0 13110 echo "$as_me: failed program was:" >&5
19650fd6
AS
13111sed 's/^/| /' conftest.$ac_ext >&5
13112
98418dba 13113emacs_cv_netdb_declares_h_errno=no
73b77ee5 13114fi
edfaf76d
LK
13115rm -f conftest.err conftest.$ac_objext \
13116 conftest$ac_exeext conftest.$ac_ext
98418dba 13117fi
c0d27fcc 13118echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
13119echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
13120if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 13121
c0d27fcc 13122cat >>confdefs.h <<\_ACEOF
98418dba 13123#define HAVE_H_ERRNO 1
c0d27fcc 13124_ACEOF
73b77ee5 13125
98418dba
CW
13126fi
13127
13128# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
13129# for constant arguments. Useless!
c0d27fcc 13130echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
13131echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
13132if test "${ac_cv_working_alloca_h+set}" = set; then
13133 echo $ECHO_N "(cached) $ECHO_C" >&6
13134else
13135 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13136/* confdefs.h. */
13137_ACEOF
13138cat confdefs.h >>conftest.$ac_ext
13139cat >>conftest.$ac_ext <<_ACEOF
13140/* end confdefs.h. */
98418dba 13141#include <alloca.h>
503d2be0
AS
13142int
13143main ()
13144{
98418dba 13145char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
13146 ;
13147 return 0;
13148}
13149_ACEOF
13150rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13151if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13152 (eval $ac_link) 2>conftest.er1
503d2be0 13153 ac_status=$?
edfaf76d
LK
13154 grep -v '^ *+' conftest.er1 >conftest.err
13155 rm -f conftest.er1
13156 cat conftest.err >&5
c0d27fcc 13157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13158 (exit $ac_status); } &&
10a3b1a1
EZ
13159 { ac_try='test -z "$ac_c_werror_flag"
13160 || test ! -s conftest.err'
edfaf76d
LK
13161 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13162 (eval $ac_try) 2>&5
13163 ac_status=$?
13164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13165 (exit $ac_status); }; } &&
13166 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13167 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13168 (eval $ac_try) 2>&5
13169 ac_status=$?
c0d27fcc 13170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13171 (exit $ac_status); }; }; then
98418dba 13172 ac_cv_working_alloca_h=yes
73b77ee5 13173else
503d2be0 13174 echo "$as_me: failed program was:" >&5
19650fd6
AS
13175sed 's/^/| /' conftest.$ac_ext >&5
13176
98418dba 13177ac_cv_working_alloca_h=no
73b77ee5 13178fi
edfaf76d
LK
13179rm -f conftest.err conftest.$ac_objext \
13180 conftest$ac_exeext conftest.$ac_ext
98418dba 13181fi
c0d27fcc 13182echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
13183echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
13184if test $ac_cv_working_alloca_h = yes; then
73b77ee5 13185
c0d27fcc 13186cat >>confdefs.h <<\_ACEOF
98418dba 13187#define HAVE_ALLOCA_H 1
c0d27fcc 13188_ACEOF
98418dba
CW
13189
13190fi
13191
c0d27fcc 13192echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
13193echo $ECHO_N "checking for alloca... $ECHO_C" >&6
13194if test "${ac_cv_func_alloca_works+set}" = set; then
13195 echo $ECHO_N "(cached) $ECHO_C" >&6
13196else
503d2be0 13197 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13198/* confdefs.h. */
13199_ACEOF
13200cat confdefs.h >>conftest.$ac_ext
13201cat >>conftest.$ac_ext <<_ACEOF
13202/* end confdefs.h. */
98418dba
CW
13203#ifdef __GNUC__
13204# define alloca __builtin_alloca
13205#else
13206# ifdef _MSC_VER
13207# include <malloc.h>
13208# define alloca _alloca
13209# else
13210# if HAVE_ALLOCA_H
13211# include <alloca.h>
13212# else
13213# ifdef _AIX
13214 #pragma alloca
13215# else
13216# ifndef alloca /* predefined by HP cc +Olibcalls */
13217char *alloca ();
13218# endif
13219# endif
13220# endif
13221# endif
13222#endif
13223
503d2be0
AS
13224int
13225main ()
13226{
98418dba 13227char *p = (char *) alloca (1);
503d2be0
AS
13228 ;
13229 return 0;
13230}
13231_ACEOF
13232rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13233if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13234 (eval $ac_link) 2>conftest.er1
503d2be0 13235 ac_status=$?
edfaf76d
LK
13236 grep -v '^ *+' conftest.er1 >conftest.err
13237 rm -f conftest.er1
13238 cat conftest.err >&5
c0d27fcc 13239 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13240 (exit $ac_status); } &&
10a3b1a1
EZ
13241 { ac_try='test -z "$ac_c_werror_flag"
13242 || test ! -s conftest.err'
edfaf76d
LK
13243 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13244 (eval $ac_try) 2>&5
13245 ac_status=$?
13246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13247 (exit $ac_status); }; } &&
13248 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13249 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13250 (eval $ac_try) 2>&5
13251 ac_status=$?
c0d27fcc 13252 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13253 (exit $ac_status); }; }; then
98418dba 13254 ac_cv_func_alloca_works=yes
ac95a621 13255else
503d2be0 13256 echo "$as_me: failed program was:" >&5
19650fd6
AS
13257sed 's/^/| /' conftest.$ac_ext >&5
13258
98418dba 13259ac_cv_func_alloca_works=no
ac95a621 13260fi
edfaf76d
LK
13261rm -f conftest.err conftest.$ac_objext \
13262 conftest$ac_exeext conftest.$ac_ext
98418dba 13263fi
c0d27fcc 13264echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 13265echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 13266
98418dba
CW
13267if test $ac_cv_func_alloca_works = yes; then
13268
c0d27fcc 13269cat >>confdefs.h <<\_ACEOF
98418dba 13270#define HAVE_ALLOCA 1
c0d27fcc 13271_ACEOF
98418dba
CW
13272
13273else
13274 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
13275# that cause trouble. Some versions do not even contain alloca or
13276# contain a buggy version. If you still want to use their alloca,
13277# use ar to extract alloca.o from them instead of compiling alloca.c.
13278
13279ALLOCA=alloca.$ac_objext
13280
c0d27fcc 13281cat >>confdefs.h <<\_ACEOF
98418dba 13282#define C_ALLOCA 1
c0d27fcc 13283_ACEOF
98418dba 13284
c0d27fcc
MR
13285
13286echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
13287echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
13288if test "${ac_cv_os_cray+set}" = set; then
13289 echo $ECHO_N "(cached) $ECHO_C" >&6
13290else
13291 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13292/* confdefs.h. */
13293_ACEOF
13294cat confdefs.h >>conftest.$ac_ext
13295cat >>conftest.$ac_ext <<_ACEOF
13296/* end confdefs.h. */
98418dba
CW
13297#if defined(CRAY) && ! defined(CRAY2)
13298webecray
13299#else
13300wenotbecray
13301#endif
13302
13303_ACEOF
13304if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 13305 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
13306 ac_cv_os_cray=yes
13307else
13308 ac_cv_os_cray=no
13309fi
13310rm -f conftest*
ac95a621 13311
98418dba 13312fi
c0d27fcc 13313echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
13314echo "${ECHO_T}$ac_cv_os_cray" >&6
13315if test $ac_cv_os_cray = yes; then
13316 for ac_func in _getb67 GETB67 getb67; do
13317 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13318echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
13319echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13320if eval "test \"\${$as_ac_var+set}\" = set"; then
13321 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 13322else
503d2be0 13323 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13324/* confdefs.h. */
13325_ACEOF
13326cat confdefs.h >>conftest.$ac_ext
13327cat >>conftest.$ac_ext <<_ACEOF
13328/* end confdefs.h. */
edfaf76d
LK
13329/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13330 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13331#define $ac_func innocuous_$ac_func
13332
73b77ee5 13333/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13334 which can conflict with char $ac_func (); below.
13335 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13336 <limits.h> exists even on freestanding compilers. */
edfaf76d 13337
19650fd6
AS
13338#ifdef __STDC__
13339# include <limits.h>
13340#else
13341# include <assert.h>
13342#endif
edfaf76d
LK
13343
13344#undef $ac_func
13345
73b77ee5 13346/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13347#ifdef __cplusplus
13348extern "C"
19650fd6 13349{
503d2be0 13350#endif
73b77ee5 13351/* We use char because int might match the return type of a gcc2
503d2be0
AS
13352 builtin and then its argument prototype would still apply. */
13353char $ac_func ();
73b77ee5
GM
13354/* The GNU C library defines this for functions which it implements
13355 to always fail with ENOSYS. Some functions are actually named
13356 something starting with __ and the normal name is an alias. */
13357#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13358choke me
13359#else
19650fd6
AS
13360char (*f) () = $ac_func;
13361#endif
13362#ifdef __cplusplus
13363}
73b77ee5
GM
13364#endif
13365
19650fd6
AS
13366int
13367main ()
13368{
13369return f != $ac_func;
503d2be0
AS
13370 ;
13371 return 0;
13372}
13373_ACEOF
13374rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13375if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13376 (eval $ac_link) 2>conftest.er1
503d2be0 13377 ac_status=$?
edfaf76d
LK
13378 grep -v '^ *+' conftest.er1 >conftest.err
13379 rm -f conftest.er1
13380 cat conftest.err >&5
c0d27fcc 13381 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13382 (exit $ac_status); } &&
10a3b1a1
EZ
13383 { ac_try='test -z "$ac_c_werror_flag"
13384 || test ! -s conftest.err'
edfaf76d
LK
13385 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13386 (eval $ac_try) 2>&5
13387 ac_status=$?
13388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13389 (exit $ac_status); }; } &&
13390 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13391 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13392 (eval $ac_try) 2>&5
13393 ac_status=$?
c0d27fcc 13394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13395 (exit $ac_status); }; }; then
13396 eval "$as_ac_var=yes"
13397else
13398 echo "$as_me: failed program was:" >&5
19650fd6
AS
13399sed 's/^/| /' conftest.$ac_ext >&5
13400
503d2be0
AS
13401eval "$as_ac_var=no"
13402fi
edfaf76d
LK
13403rm -f conftest.err conftest.$ac_objext \
13404 conftest$ac_exeext conftest.$ac_ext
503d2be0 13405fi
c0d27fcc 13406echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
13407echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13408if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 13409
c0d27fcc 13410cat >>confdefs.h <<_ACEOF
98418dba 13411#define CRAY_STACKSEG_END $ac_func
c0d27fcc 13412_ACEOF
98418dba
CW
13413
13414 break
73b77ee5 13415fi
73b77ee5 13416
98418dba 13417 done
73b77ee5
GM
13418fi
13419
c0d27fcc 13420echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
13421echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
13422if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 13423 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
13424else
13425 if test "$cross_compiling" = yes; then
13426 ac_cv_c_stack_direction=0
73b77ee5 13427else
503d2be0 13428 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13429/* confdefs.h. */
13430_ACEOF
13431cat confdefs.h >>conftest.$ac_ext
13432cat >>conftest.$ac_ext <<_ACEOF
13433/* end confdefs.h. */
503d2be0 13434int
98418dba 13435find_stack_direction ()
503d2be0 13436{
98418dba
CW
13437 static char *addr = 0;
13438 auto char dummy;
13439 if (addr == 0)
13440 {
13441 addr = &dummy;
13442 return find_stack_direction ();
13443 }
73b77ee5 13444 else
98418dba
CW
13445 return (&dummy > addr) ? 1 : -1;
13446}
ba4481b5 13447
503d2be0
AS
13448int
13449main ()
13450{
98418dba 13451 exit (find_stack_direction () < 0);
503d2be0
AS
13452}
13453_ACEOF
98418dba 13454rm -f conftest$ac_exeext
c0d27fcc 13455if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13456 (eval $ac_link) 2>&5
13457 ac_status=$?
c0d27fcc 13458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 13459 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 13460 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13461 (eval $ac_try) 2>&5
13462 ac_status=$?
c0d27fcc 13463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13464 (exit $ac_status); }; }; then
98418dba 13465 ac_cv_c_stack_direction=1
ba4481b5 13466else
98418dba
CW
13467 echo "$as_me: program exited with status $ac_status" >&5
13468echo "$as_me: failed program was:" >&5
19650fd6
AS
13469sed 's/^/| /' conftest.$ac_ext >&5
13470
c0d27fcc 13471( exit $ac_status )
98418dba 13472ac_cv_c_stack_direction=-1
ba4481b5 13473fi
edfaf76d 13474rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 13475fi
98418dba 13476fi
c0d27fcc 13477echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
13478echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
13479
c0d27fcc 13480cat >>confdefs.h <<_ACEOF
98418dba 13481#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
13482_ACEOF
13483
ba4481b5 13484
ba4481b5
DL
13485fi
13486
c0d27fcc 13487
98418dba
CW
13488# fmod, logb, and frexp are found in -lm on most systems.
13489# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
13490
c0d27fcc 13491echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
13492echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
13493if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 13494 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13495else
98418dba
CW
13496 ac_check_lib_save_LIBS=$LIBS
13497LIBS="-lm $LIBS"
13498cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13499/* confdefs.h. */
13500_ACEOF
13501cat confdefs.h >>conftest.$ac_ext
13502cat >>conftest.$ac_ext <<_ACEOF
13503/* end confdefs.h. */
ba4481b5 13504
98418dba
CW
13505/* Override any gcc2 internal prototype to avoid an error. */
13506#ifdef __cplusplus
13507extern "C"
13508#endif
13509/* We use char because int might match the return type of a gcc2
13510 builtin and then its argument prototype would still apply. */
13511char sqrt ();
503d2be0
AS
13512int
13513main ()
13514{
98418dba 13515sqrt ();
503d2be0
AS
13516 ;
13517 return 0;
13518}
13519_ACEOF
13520rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13521if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13522 (eval $ac_link) 2>conftest.er1
503d2be0 13523 ac_status=$?
edfaf76d
LK
13524 grep -v '^ *+' conftest.er1 >conftest.err
13525 rm -f conftest.er1
13526 cat conftest.err >&5
c0d27fcc 13527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13528 (exit $ac_status); } &&
10a3b1a1
EZ
13529 { ac_try='test -z "$ac_c_werror_flag"
13530 || test ! -s conftest.err'
edfaf76d
LK
13531 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13532 (eval $ac_try) 2>&5
13533 ac_status=$?
13534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13535 (exit $ac_status); }; } &&
13536 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13537 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13538 (eval $ac_try) 2>&5
13539 ac_status=$?
c0d27fcc 13540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13541 (exit $ac_status); }; }; then
98418dba 13542 ac_cv_lib_m_sqrt=yes
ba4481b5 13543else
503d2be0 13544 echo "$as_me: failed program was:" >&5
19650fd6
AS
13545sed 's/^/| /' conftest.$ac_ext >&5
13546
98418dba 13547ac_cv_lib_m_sqrt=no
ba4481b5 13548fi
edfaf76d
LK
13549rm -f conftest.err conftest.$ac_objext \
13550 conftest$ac_exeext conftest.$ac_ext
98418dba 13551LIBS=$ac_check_lib_save_LIBS
ba4481b5 13552fi
c0d27fcc 13553echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
13554echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
13555if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 13556 cat >>confdefs.h <<_ACEOF
98418dba 13557#define HAVE_LIBM 1
c0d27fcc 13558_ACEOF
98418dba
CW
13559
13560 LIBS="-lm $LIBS"
ba4481b5 13561
ba4481b5
DL
13562fi
13563
c0d27fcc 13564
55597d70
DL
13565# Check for mail-locking functions in a "mail" library. Probably this should
13566# have the same check as for liblockfile below.
98418dba 13567
c0d27fcc 13568echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
13569echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
13570if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 13571 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13572else
98418dba
CW
13573 ac_check_lib_save_LIBS=$LIBS
13574LIBS="-lmail $LIBS"
13575cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13576/* confdefs.h. */
13577_ACEOF
13578cat confdefs.h >>conftest.$ac_ext
13579cat >>conftest.$ac_ext <<_ACEOF
13580/* end confdefs.h. */
98418dba
CW
13581
13582/* Override any gcc2 internal prototype to avoid an error. */
13583#ifdef __cplusplus
13584extern "C"
13585#endif
13586/* We use char because int might match the return type of a gcc2
13587 builtin and then its argument prototype would still apply. */
13588char maillock ();
503d2be0
AS
13589int
13590main ()
13591{
98418dba 13592maillock ();
503d2be0
AS
13593 ;
13594 return 0;
13595}
13596_ACEOF
13597rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13598if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13599 (eval $ac_link) 2>conftest.er1
503d2be0 13600 ac_status=$?
edfaf76d
LK
13601 grep -v '^ *+' conftest.er1 >conftest.err
13602 rm -f conftest.er1
13603 cat conftest.err >&5
c0d27fcc 13604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13605 (exit $ac_status); } &&
10a3b1a1
EZ
13606 { ac_try='test -z "$ac_c_werror_flag"
13607 || test ! -s conftest.err'
edfaf76d
LK
13608 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13609 (eval $ac_try) 2>&5
13610 ac_status=$?
13611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13612 (exit $ac_status); }; } &&
13613 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13614 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13615 (eval $ac_try) 2>&5
13616 ac_status=$?
c0d27fcc 13617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13618 (exit $ac_status); }; }; then
98418dba 13619 ac_cv_lib_mail_maillock=yes
ba4481b5 13620else
503d2be0 13621 echo "$as_me: failed program was:" >&5
19650fd6
AS
13622sed 's/^/| /' conftest.$ac_ext >&5
13623
98418dba 13624ac_cv_lib_mail_maillock=no
ba4481b5 13625fi
edfaf76d
LK
13626rm -f conftest.err conftest.$ac_objext \
13627 conftest$ac_exeext conftest.$ac_ext
98418dba 13628LIBS=$ac_check_lib_save_LIBS
ba4481b5 13629fi
c0d27fcc 13630echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
13631echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
13632if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 13633 cat >>confdefs.h <<_ACEOF
98418dba 13634#define HAVE_LIBMAIL 1
c0d27fcc 13635_ACEOF
ba4481b5 13636
98418dba 13637 LIBS="-lmail $LIBS"
ba4481b5 13638
98418dba 13639fi
ba4481b5 13640
c0d27fcc
MR
13641
13642echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
13643echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
13644if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 13645 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13646else
503d2be0 13647 ac_check_lib_save_LIBS=$LIBS
98418dba 13648LIBS="-llockfile $LIBS"
503d2be0 13649cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13650/* confdefs.h. */
13651_ACEOF
13652cat confdefs.h >>conftest.$ac_ext
13653cat >>conftest.$ac_ext <<_ACEOF
13654/* end confdefs.h. */
503d2be0 13655
ba4481b5 13656/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13657#ifdef __cplusplus
13658extern "C"
13659#endif
ba4481b5 13660/* We use char because int might match the return type of a gcc2
503d2be0 13661 builtin and then its argument prototype would still apply. */
98418dba 13662char maillock ();
503d2be0
AS
13663int
13664main ()
13665{
98418dba 13666maillock ();
503d2be0
AS
13667 ;
13668 return 0;
13669}
13670_ACEOF
13671rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13672if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13673 (eval $ac_link) 2>conftest.er1
503d2be0 13674 ac_status=$?
edfaf76d
LK
13675 grep -v '^ *+' conftest.er1 >conftest.err
13676 rm -f conftest.er1
13677 cat conftest.err >&5
c0d27fcc 13678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13679 (exit $ac_status); } &&
10a3b1a1
EZ
13680 { ac_try='test -z "$ac_c_werror_flag"
13681 || test ! -s conftest.err'
edfaf76d
LK
13682 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13683 (eval $ac_try) 2>&5
13684 ac_status=$?
13685 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13686 (exit $ac_status); }; } &&
13687 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13688 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13689 (eval $ac_try) 2>&5
13690 ac_status=$?
c0d27fcc 13691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13692 (exit $ac_status); }; }; then
98418dba 13693 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
13694else
13695 echo "$as_me: failed program was:" >&5
19650fd6
AS
13696sed 's/^/| /' conftest.$ac_ext >&5
13697
98418dba
CW
13698ac_cv_lib_lockfile_maillock=no
13699fi
edfaf76d
LK
13700rm -f conftest.err conftest.$ac_objext \
13701 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
13702LIBS=$ac_check_lib_save_LIBS
13703fi
c0d27fcc 13704echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
13705echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
13706if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 13707 cat >>confdefs.h <<_ACEOF
98418dba 13708#define HAVE_LIBLOCKFILE 1
c0d27fcc 13709_ACEOF
98418dba
CW
13710
13711 LIBS="-llockfile $LIBS"
13712
13713fi
13714
13715# If we have the shared liblockfile, assume we must use it for mail
13716# locking (e.g. Debian). If we couldn't link against liblockfile
13717# (no liblockfile.a installed), ensure that we don't need to.
13718if test "$ac_cv_lib_lockfile_maillock" = no; then
13719 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13720set dummy liblockfile.so; ac_word=$2
c0d27fcc 13721echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
13722echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13723if test "${ac_cv_prog_liblockfile+set}" = set; then
13724 echo $ECHO_N "(cached) $ECHO_C" >&6
13725else
13726 if test -n "$liblockfile"; then
13727 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13728else
c0d27fcc 13729as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
13730as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13731for as_dir in $as_dummy
c0d27fcc
MR
13732do
13733 IFS=$as_save_IFS
13734 test -z "$as_dir" && as_dir=.
13735 for ac_exec_ext in '' $ac_executable_extensions; do
13736 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13737 ac_cv_prog_liblockfile="yes"
13738 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13739 break 2
13740 fi
13741done
98418dba
CW
13742done
13743
13744 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 13745fi
503d2be0 13746fi
98418dba
CW
13747liblockfile=$ac_cv_prog_liblockfile
13748if test -n "$liblockfile"; then
c0d27fcc 13749 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
13750echo "${ECHO_T}$liblockfile" >&6
13751else
c0d27fcc 13752 echo "$as_me:$LINENO: result: no" >&5
98418dba 13753echo "${ECHO_T}no" >&6
ba4481b5
DL
13754fi
13755
98418dba 13756 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 13757 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
13758This probably means that movemail could lose mail.
13759There may be a \`development' package to install containing liblockfile." >&5
13760echo "$as_me: error: Shared liblockfile found but can't link against it.
13761This probably means that movemail could lose mail.
13762There may be a \`development' package to install containing liblockfile." >&2;}
13763 { (exit 1); exit 1; }; }
98418dba 13764 else :
55597d70 13765 fi
98418dba 13766fi
503d2be0 13767
98418dba
CW
13768for ac_func in touchlock
13769do
13770as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13771echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13772echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13773if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13774 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 13775else
98418dba 13776 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13777/* confdefs.h. */
13778_ACEOF
13779cat confdefs.h >>conftest.$ac_ext
13780cat >>conftest.$ac_ext <<_ACEOF
13781/* end confdefs.h. */
edfaf76d
LK
13782/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13783 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13784#define $ac_func innocuous_$ac_func
13785
98418dba 13786/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13787 which can conflict with char $ac_func (); below.
13788 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13789 <limits.h> exists even on freestanding compilers. */
edfaf76d 13790
19650fd6
AS
13791#ifdef __STDC__
13792# include <limits.h>
13793#else
13794# include <assert.h>
13795#endif
edfaf76d
LK
13796
13797#undef $ac_func
13798
457b792c 13799/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13800#ifdef __cplusplus
13801extern "C"
19650fd6 13802{
503d2be0 13803#endif
457b792c 13804/* We use char because int might match the return type of a gcc2
503d2be0 13805 builtin and then its argument prototype would still apply. */
98418dba 13806char $ac_func ();
98418dba
CW
13807/* The GNU C library defines this for functions which it implements
13808 to always fail with ENOSYS. Some functions are actually named
13809 something starting with __ and the normal name is an alias. */
13810#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13811choke me
13812#else
19650fd6
AS
13813char (*f) () = $ac_func;
13814#endif
13815#ifdef __cplusplus
13816}
cd958eb3
MB
13817#endif
13818
19650fd6
AS
13819int
13820main ()
13821{
13822return f != $ac_func;
503d2be0
AS
13823 ;
13824 return 0;
13825}
13826_ACEOF
13827rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13828if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 13829 (eval $ac_link) 2>conftest.er1
503d2be0 13830 ac_status=$?
edfaf76d
LK
13831 grep -v '^ *+' conftest.er1 >conftest.err
13832 rm -f conftest.er1
13833 cat conftest.err >&5
c0d27fcc 13834 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13835 (exit $ac_status); } &&
10a3b1a1
EZ
13836 { ac_try='test -z "$ac_c_werror_flag"
13837 || test ! -s conftest.err'
edfaf76d
LK
13838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13839 (eval $ac_try) 2>&5
13840 ac_status=$?
13841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13842 (exit $ac_status); }; } &&
13843 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13844 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13845 (eval $ac_try) 2>&5
13846 ac_status=$?
c0d27fcc 13847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13848 (exit $ac_status); }; }; then
98418dba 13849 eval "$as_ac_var=yes"
503d2be0
AS
13850else
13851 echo "$as_me: failed program was:" >&5
19650fd6
AS
13852sed 's/^/| /' conftest.$ac_ext >&5
13853
98418dba 13854eval "$as_ac_var=no"
503d2be0 13855fi
edfaf76d
LK
13856rm -f conftest.err conftest.$ac_objext \
13857 conftest$ac_exeext conftest.$ac_ext
503d2be0 13858fi
c0d27fcc 13859echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13860echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13861if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13862 cat >>confdefs.h <<_ACEOF
98418dba 13863#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13864_ACEOF
457b792c 13865
457b792c 13866fi
98418dba 13867done
457b792c 13868
c0d27fcc 13869
98418dba
CW
13870for ac_header in maillock.h
13871do
13872as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13873if eval "test \"\${$as_ac_Header+set}\" = set"; then
13874 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13875echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13876if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 13877 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13878fi
13879echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13880echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 13881else
c0d27fcc
MR
13882 # Is the header compilable?
13883echo "$as_me:$LINENO: checking $ac_header usability" >&5
13884echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13885cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13886/* confdefs.h. */
13887_ACEOF
13888cat confdefs.h >>conftest.$ac_ext
13889cat >>conftest.$ac_ext <<_ACEOF
13890/* end confdefs.h. */
c0d27fcc
MR
13891$ac_includes_default
13892#include <$ac_header>
13893_ACEOF
13894rm -f conftest.$ac_objext
13895if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 13896 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13897 ac_status=$?
edfaf76d
LK
13898 grep -v '^ *+' conftest.er1 >conftest.err
13899 rm -f conftest.er1
13900 cat conftest.err >&5
c0d27fcc
MR
13901 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13902 (exit $ac_status); } &&
10a3b1a1
EZ
13903 { ac_try='test -z "$ac_c_werror_flag"
13904 || test ! -s conftest.err'
edfaf76d
LK
13905 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13906 (eval $ac_try) 2>&5
13907 ac_status=$?
13908 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13909 (exit $ac_status); }; } &&
13910 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13911 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13912 (eval $ac_try) 2>&5
13913 ac_status=$?
13914 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13915 (exit $ac_status); }; }; then
13916 ac_header_compiler=yes
13917else
13918 echo "$as_me: failed program was:" >&5
19650fd6
AS
13919sed 's/^/| /' conftest.$ac_ext >&5
13920
c0d27fcc
MR
13921ac_header_compiler=no
13922fi
edfaf76d 13923rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13924echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13925echo "${ECHO_T}$ac_header_compiler" >&6
13926
13927# Is the header present?
13928echo "$as_me:$LINENO: checking $ac_header presence" >&5
13929echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13930cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13931/* confdefs.h. */
13932_ACEOF
13933cat confdefs.h >>conftest.$ac_ext
13934cat >>conftest.$ac_ext <<_ACEOF
13935/* end confdefs.h. */
98418dba 13936#include <$ac_header>
503d2be0 13937_ACEOF
c0d27fcc 13938if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 13939 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 13940 ac_status=$?
6bae0ccf 13941 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13942 rm -f conftest.er1
13943 cat conftest.err >&5
c0d27fcc 13944 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13945 (exit $ac_status); } >/dev/null; then
13946 if test -s conftest.err; then
13947 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 13948 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
13949 else
13950 ac_cpp_err=
13951 fi
503d2be0 13952else
98418dba 13953 ac_cpp_err=yes
503d2be0 13954fi
98418dba 13955if test -z "$ac_cpp_err"; then
c0d27fcc 13956 ac_header_preproc=yes
98418dba
CW
13957else
13958 echo "$as_me: failed program was:" >&5
19650fd6
AS
13959sed 's/^/| /' conftest.$ac_ext >&5
13960
c0d27fcc 13961 ac_header_preproc=no
503d2be0 13962fi
98418dba 13963rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13964echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13965echo "${ECHO_T}$ac_header_preproc" >&6
13966
13967# So? What about this header?
edfaf76d
LK
13968case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13969 yes:no: )
c0d27fcc
MR
13970 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13971echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
13972 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13973echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13974 ac_header_preproc=yes
19650fd6 13975 ;;
edfaf76d 13976 no:yes:* )
c0d27fcc
MR
13977 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13978echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
13979 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13980echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13981 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13982echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13983 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13984echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13985 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13986echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
13987 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13988echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13989 (
13990 cat <<\_ASBOX
edfaf76d
LK
13991## ------------------------------------------ ##
13992## Report this to the AC_PACKAGE_NAME lists. ##
13993## ------------------------------------------ ##
19650fd6
AS
13994_ASBOX
13995 ) |
13996 sed "s/^/$as_me: WARNING: /" >&2
13997 ;;
c0d27fcc
MR
13998esac
13999echo "$as_me:$LINENO: checking for $ac_header" >&5
14000echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14001if eval "test \"\${$as_ac_Header+set}\" = set"; then
14002 echo $ECHO_N "(cached) $ECHO_C" >&6
14003else
edfaf76d 14004 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 14005fi
c0d27fcc 14006echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 14007echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
14008
14009fi
98418dba 14010if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 14011 cat >>confdefs.h <<_ACEOF
98418dba 14012#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 14013_ACEOF
48d4b120 14014
ba4481b5 14015fi
c0d27fcc 14016
98418dba
CW
14017done
14018
c0d27fcc
MR
14019
14020
14021
14022
14023
14024
14025
14026
14027
14028
14029
14030
14031
14032
14033
14034
14035
14036
14037
14038
14039
14040
14041
14042
14043
14044
14045
14046
14047
14048
14049
14050
14051
14052
14053
14054
14055
14056
14057
14058
14059
14060
14061
14062
14063
14064
14065
14066
14067
14068
14069
14070
14071
14072
14073
22044edf
DL
14074
14075
c0d27fcc 14076
b0e44248
RB
14077
14078
973a76b1
DL
14079
14080
14081
cd958eb3 14082
25ca0bca 14083
ea92fc9f 14084
e2fcf543 14085
c0d27fcc
MR
14086
14087
98418dba 14088for ac_func in gethostname getdomainname dup2 \
e2fcf543 14089rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
98418dba
CW
14090random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
14091strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
973a76b1 14092utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
98418dba
CW
14093__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
14094sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248 14095gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
4489ece2 14096memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign
98418dba
CW
14097do
14098as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14099echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14100echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14101if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14102 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14103else
503d2be0 14104 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14105/* confdefs.h. */
14106_ACEOF
14107cat confdefs.h >>conftest.$ac_ext
14108cat >>conftest.$ac_ext <<_ACEOF
14109/* end confdefs.h. */
edfaf76d
LK
14110/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14111 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14112#define $ac_func innocuous_$ac_func
14113
98418dba 14114/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14115 which can conflict with char $ac_func (); below.
14116 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14117 <limits.h> exists even on freestanding compilers. */
edfaf76d 14118
19650fd6
AS
14119#ifdef __STDC__
14120# include <limits.h>
14121#else
14122# include <assert.h>
14123#endif
edfaf76d
LK
14124
14125#undef $ac_func
14126
ba4481b5 14127/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14128#ifdef __cplusplus
14129extern "C"
19650fd6 14130{
503d2be0 14131#endif
ba4481b5 14132/* We use char because int might match the return type of a gcc2
503d2be0 14133 builtin and then its argument prototype would still apply. */
98418dba 14134char $ac_func ();
98418dba
CW
14135/* The GNU C library defines this for functions which it implements
14136 to always fail with ENOSYS. Some functions are actually named
14137 something starting with __ and the normal name is an alias. */
14138#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14139choke me
14140#else
19650fd6
AS
14141char (*f) () = $ac_func;
14142#endif
14143#ifdef __cplusplus
14144}
98418dba
CW
14145#endif
14146
19650fd6
AS
14147int
14148main ()
14149{
14150return f != $ac_func;
503d2be0
AS
14151 ;
14152 return 0;
14153}
14154_ACEOF
14155rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14156if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 14157 (eval $ac_link) 2>conftest.er1
503d2be0 14158 ac_status=$?
edfaf76d
LK
14159 grep -v '^ *+' conftest.er1 >conftest.err
14160 rm -f conftest.er1
14161 cat conftest.err >&5
c0d27fcc 14162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14163 (exit $ac_status); } &&
10a3b1a1
EZ
14164 { ac_try='test -z "$ac_c_werror_flag"
14165 || test ! -s conftest.err'
c0d27fcc 14166 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14167 (eval $ac_try) 2>&5
14168 ac_status=$?
c0d27fcc 14169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
edfaf76d
LK
14170 (exit $ac_status); }; } &&
14171 { ac_try='test -s conftest$ac_exeext'
14172 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14173 (eval $ac_try) 2>&5
14174 ac_status=$?
14175 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14176 (exit $ac_status); }; }; then
98418dba 14177 eval "$as_ac_var=yes"
503d2be0
AS
14178else
14179 echo "$as_me: failed program was:" >&5
19650fd6
AS
14180sed 's/^/| /' conftest.$ac_ext >&5
14181
98418dba 14182eval "$as_ac_var=no"
503d2be0 14183fi
edfaf76d
LK
14184rm -f conftest.err conftest.$ac_objext \
14185 conftest$ac_exeext conftest.$ac_ext
ba4481b5 14186fi
c0d27fcc 14187echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
14188echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14189if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14190 cat >>confdefs.h <<_ACEOF
98418dba 14191#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14192_ACEOF
ba4481b5 14193
ba4481b5 14194fi
98418dba 14195done
ba4481b5 14196
c0d27fcc
MR
14197
14198
98418dba
CW
14199for ac_header in sys/un.h
14200do
14201as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
14202if eval "test \"\${$as_ac_Header+set}\" = set"; then
14203 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
14204echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14205if eval "test \"\${$as_ac_Header+set}\" = set"; then
14206 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14207fi
14208echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14209echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 14210else
c0d27fcc
MR
14211 # Is the header compilable?
14212echo "$as_me:$LINENO: checking $ac_header usability" >&5
14213echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14214cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14215/* confdefs.h. */
14216_ACEOF
14217cat confdefs.h >>conftest.$ac_ext
14218cat >>conftest.$ac_ext <<_ACEOF
14219/* end confdefs.h. */
c0d27fcc
MR
14220$ac_includes_default
14221#include <$ac_header>
14222_ACEOF
14223rm -f conftest.$ac_objext
14224if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 14225 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14226 ac_status=$?
edfaf76d
LK
14227 grep -v '^ *+' conftest.er1 >conftest.err
14228 rm -f conftest.er1
14229 cat conftest.err >&5
c0d27fcc
MR
14230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14231 (exit $ac_status); } &&
10a3b1a1
EZ
14232 { ac_try='test -z "$ac_c_werror_flag"
14233 || test ! -s conftest.err'
edfaf76d
LK
14234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14235 (eval $ac_try) 2>&5
14236 ac_status=$?
14237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14238 (exit $ac_status); }; } &&
14239 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14241 (eval $ac_try) 2>&5
14242 ac_status=$?
14243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14244 (exit $ac_status); }; }; then
14245 ac_header_compiler=yes
14246else
14247 echo "$as_me: failed program was:" >&5
19650fd6
AS
14248sed 's/^/| /' conftest.$ac_ext >&5
14249
c0d27fcc
MR
14250ac_header_compiler=no
14251fi
edfaf76d 14252rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14253echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14254echo "${ECHO_T}$ac_header_compiler" >&6
14255
14256# Is the header present?
14257echo "$as_me:$LINENO: checking $ac_header presence" >&5
14258echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14259cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14260/* confdefs.h. */
14261_ACEOF
14262cat confdefs.h >>conftest.$ac_ext
14263cat >>conftest.$ac_ext <<_ACEOF
14264/* end confdefs.h. */
98418dba 14265#include <$ac_header>
503d2be0 14266_ACEOF
c0d27fcc 14267if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
14268 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14269 ac_status=$?
6bae0ccf 14270 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
14271 rm -f conftest.er1
14272 cat conftest.err >&5
c0d27fcc 14273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14274 (exit $ac_status); } >/dev/null; then
14275 if test -s conftest.err; then
14276 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 14277 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
14278 else
14279 ac_cpp_err=
14280 fi
14281else
14282 ac_cpp_err=yes
14283fi
14284if test -z "$ac_cpp_err"; then
c0d27fcc 14285 ac_header_preproc=yes
ba4481b5 14286else
503d2be0 14287 echo "$as_me: failed program was:" >&5
19650fd6
AS
14288sed 's/^/| /' conftest.$ac_ext >&5
14289
c0d27fcc 14290 ac_header_preproc=no
ba4481b5 14291fi
503d2be0 14292rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14293echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14294echo "${ECHO_T}$ac_header_preproc" >&6
14295
14296# So? What about this header?
edfaf76d
LK
14297case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14298 yes:no: )
c0d27fcc
MR
14299 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14300echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
14301 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14302echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14303 ac_header_preproc=yes
19650fd6 14304 ;;
edfaf76d 14305 no:yes:* )
c0d27fcc
MR
14306 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14307echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
14308 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14309echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14310 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14311echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14312 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
14313echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 14314 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 14315echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
14316 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14317echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
14318 (
14319 cat <<\_ASBOX
edfaf76d
LK
14320## ------------------------------------------ ##
14321## Report this to the AC_PACKAGE_NAME lists. ##
14322## ------------------------------------------ ##
19650fd6
AS
14323_ASBOX
14324 ) |
14325 sed "s/^/$as_me: WARNING: /" >&2
14326 ;;
c0d27fcc
MR
14327esac
14328echo "$as_me:$LINENO: checking for $ac_header" >&5
14329echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14330if eval "test \"\${$as_ac_Header+set}\" = set"; then
14331 echo $ECHO_N "(cached) $ECHO_C" >&6
14332else
edfaf76d 14333 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 14334fi
c0d27fcc 14335echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 14336echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
14337
14338fi
925c2f3f 14339if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 14340 cat >>confdefs.h <<_ACEOF
925c2f3f 14341#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 14342_ACEOF
503d2be0 14343
925c2f3f 14344fi
c0d27fcc 14345
925c2f3f
EZ
14346done
14347
c0d27fcc
MR
14348
14349
14350
edfaf76d
LK
14351
14352for ac_header in stdlib.h sys/time.h unistd.h
925c2f3f
EZ
14353do
14354as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
14355if eval "test \"\${$as_ac_Header+set}\" = set"; then
14356 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
14357echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14358if eval "test \"\${$as_ac_Header+set}\" = set"; then
14359 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14360fi
14361echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14362echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 14363else
c0d27fcc
MR
14364 # Is the header compilable?
14365echo "$as_me:$LINENO: checking $ac_header usability" >&5
14366echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14367cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14368/* confdefs.h. */
14369_ACEOF
14370cat confdefs.h >>conftest.$ac_ext
14371cat >>conftest.$ac_ext <<_ACEOF
14372/* end confdefs.h. */
c0d27fcc
MR
14373$ac_includes_default
14374#include <$ac_header>
14375_ACEOF
14376rm -f conftest.$ac_objext
14377if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 14378 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14379 ac_status=$?
edfaf76d
LK
14380 grep -v '^ *+' conftest.er1 >conftest.err
14381 rm -f conftest.er1
14382 cat conftest.err >&5
c0d27fcc
MR
14383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14384 (exit $ac_status); } &&
10a3b1a1
EZ
14385 { ac_try='test -z "$ac_c_werror_flag"
14386 || test ! -s conftest.err'
edfaf76d
LK
14387 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14388 (eval $ac_try) 2>&5
14389 ac_status=$?
14390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14391 (exit $ac_status); }; } &&
14392 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14393 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14394 (eval $ac_try) 2>&5
14395 ac_status=$?
14396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14397 (exit $ac_status); }; }; then
14398 ac_header_compiler=yes
14399else
14400 echo "$as_me: failed program was:" >&5
19650fd6
AS
14401sed 's/^/| /' conftest.$ac_ext >&5
14402
c0d27fcc
MR
14403ac_header_compiler=no
14404fi
edfaf76d 14405rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14406echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14407echo "${ECHO_T}$ac_header_compiler" >&6
14408
14409# Is the header present?
14410echo "$as_me:$LINENO: checking $ac_header presence" >&5
14411echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
14412cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14413/* confdefs.h. */
14414_ACEOF
14415cat confdefs.h >>conftest.$ac_ext
14416cat >>conftest.$ac_ext <<_ACEOF
14417/* end confdefs.h. */
98418dba 14418#include <$ac_header>
503d2be0 14419_ACEOF
c0d27fcc 14420if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
14421 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14422 ac_status=$?
6bae0ccf 14423 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
14424 rm -f conftest.er1
14425 cat conftest.err >&5
c0d27fcc 14426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14427 (exit $ac_status); } >/dev/null; then
14428 if test -s conftest.err; then
14429 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 14430 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
14431 else
14432 ac_cpp_err=
14433 fi
14434else
14435 ac_cpp_err=yes
14436fi
14437if test -z "$ac_cpp_err"; then
c0d27fcc 14438 ac_header_preproc=yes
98418dba
CW
14439else
14440 echo "$as_me: failed program was:" >&5
19650fd6
AS
14441sed 's/^/| /' conftest.$ac_ext >&5
14442
c0d27fcc 14443 ac_header_preproc=no
98418dba
CW
14444fi
14445rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14446echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14447echo "${ECHO_T}$ac_header_preproc" >&6
14448
14449# So? What about this header?
edfaf76d
LK
14450case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14451 yes:no: )
c0d27fcc
MR
14452 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14453echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
14454 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14455echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14456 ac_header_preproc=yes
19650fd6 14457 ;;
edfaf76d 14458 no:yes:* )
c0d27fcc
MR
14459 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14460echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
14461 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
14462echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
14463 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14464echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14465 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
14466echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 14467 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 14468echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
14469 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14470echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
14471 (
14472 cat <<\_ASBOX
edfaf76d
LK
14473## ------------------------------------------ ##
14474## Report this to the AC_PACKAGE_NAME lists. ##
14475## ------------------------------------------ ##
19650fd6
AS
14476_ASBOX
14477 ) |
14478 sed "s/^/$as_me: WARNING: /" >&2
14479 ;;
c0d27fcc
MR
14480esac
14481echo "$as_me:$LINENO: checking for $ac_header" >&5
14482echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14483if eval "test \"\${$as_ac_Header+set}\" = set"; then
14484 echo $ECHO_N "(cached) $ECHO_C" >&6
14485else
edfaf76d 14486 eval "$as_ac_Header=\$ac_header_preproc"
ffe36136 14487fi
c0d27fcc 14488echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 14489echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
14490
14491fi
98418dba 14492if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 14493 cat >>confdefs.h <<_ACEOF
98418dba 14494#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 14495_ACEOF
98418dba
CW
14496
14497fi
c0d27fcc 14498
98418dba
CW
14499done
14500
c0d27fcc 14501
98418dba
CW
14502for ac_func in alarm
14503do
14504as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14505echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14506echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14507if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14508 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14509else
98418dba 14510 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14511/* confdefs.h. */
14512_ACEOF
14513cat confdefs.h >>conftest.$ac_ext
14514cat >>conftest.$ac_ext <<_ACEOF
14515/* end confdefs.h. */
edfaf76d
LK
14516/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14517 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14518#define $ac_func innocuous_$ac_func
14519
98418dba 14520/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14521 which can conflict with char $ac_func (); below.
14522 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14523 <limits.h> exists even on freestanding compilers. */
edfaf76d 14524
19650fd6
AS
14525#ifdef __STDC__
14526# include <limits.h>
14527#else
14528# include <assert.h>
14529#endif
edfaf76d
LK
14530
14531#undef $ac_func
14532
ba4481b5 14533/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14534#ifdef __cplusplus
14535extern "C"
19650fd6 14536{
503d2be0 14537#endif
ba4481b5 14538/* We use char because int might match the return type of a gcc2
503d2be0 14539 builtin and then its argument prototype would still apply. */
98418dba 14540char $ac_func ();
98418dba
CW
14541/* The GNU C library defines this for functions which it implements
14542 to always fail with ENOSYS. Some functions are actually named
14543 something starting with __ and the normal name is an alias. */
14544#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14545choke me
14546#else
19650fd6
AS
14547char (*f) () = $ac_func;
14548#endif
14549#ifdef __cplusplus
14550}
98418dba
CW
14551#endif
14552
19650fd6
AS
14553int
14554main ()
14555{
14556return f != $ac_func;
503d2be0
AS
14557 ;
14558 return 0;
14559}
14560_ACEOF
14561rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14562if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 14563 (eval $ac_link) 2>conftest.er1
503d2be0 14564 ac_status=$?
edfaf76d
LK
14565 grep -v '^ *+' conftest.er1 >conftest.err
14566 rm -f conftest.er1
14567 cat conftest.err >&5
c0d27fcc 14568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14569 (exit $ac_status); } &&
10a3b1a1
EZ
14570 { ac_try='test -z "$ac_c_werror_flag"
14571 || test ! -s conftest.err'
edfaf76d
LK
14572 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14573 (eval $ac_try) 2>&5
14574 ac_status=$?
14575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14576 (exit $ac_status); }; } &&
14577 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14578 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14579 (eval $ac_try) 2>&5
14580 ac_status=$?
c0d27fcc 14581 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14582 (exit $ac_status); }; }; then
98418dba 14583 eval "$as_ac_var=yes"
503d2be0
AS
14584else
14585 echo "$as_me: failed program was:" >&5
19650fd6
AS
14586sed 's/^/| /' conftest.$ac_ext >&5
14587
98418dba 14588eval "$as_ac_var=no"
503d2be0 14589fi
edfaf76d
LK
14590rm -f conftest.err conftest.$ac_objext \
14591 conftest$ac_exeext conftest.$ac_ext
ffe36136 14592fi
c0d27fcc 14593echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
14594echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14595if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14596 cat >>confdefs.h <<_ACEOF
98418dba 14597#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14598_ACEOF
ffe36136 14599
ba4481b5 14600fi
98418dba 14601done
ba4481b5 14602
c0d27fcc 14603echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
14604echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
14605if test "${ac_cv_func_working_mktime+set}" = set; then
14606 echo $ECHO_N "(cached) $ECHO_C" >&6
14607else
14608 if test "$cross_compiling" = yes; then
14609 ac_cv_func_working_mktime=no
14610else
14611 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14612/* confdefs.h. */
14613_ACEOF
14614cat confdefs.h >>conftest.$ac_ext
14615cat >>conftest.$ac_ext <<_ACEOF
14616/* end confdefs.h. */
98418dba
CW
14617/* Test program from Paul Eggert and Tony Leneis. */
14618#if TIME_WITH_SYS_TIME
14619# include <sys/time.h>
14620# include <time.h>
14621#else
14622# if HAVE_SYS_TIME_H
14623# include <sys/time.h>
14624# else
14625# include <time.h>
14626# endif
14627#endif
ba4481b5 14628
edfaf76d
LK
14629#if HAVE_STDLIB_H
14630# include <stdlib.h>
14631#endif
14632
98418dba
CW
14633#if HAVE_UNISTD_H
14634# include <unistd.h>
14635#endif
ba4481b5 14636
98418dba
CW
14637#if !HAVE_ALARM
14638# define alarm(X) /* empty */
14639#endif
df645f7c 14640
98418dba
CW
14641/* Work around redefinition to rpl_putenv by other config tests. */
14642#undef putenv
df645f7c 14643
98418dba 14644static time_t time_t_max;
edfaf76d 14645static time_t time_t_min;
df645f7c 14646
98418dba 14647/* Values we'll use to set the TZ environment variable. */
edfaf76d
LK
14648static char *tz_strings[] = {
14649 (char *) 0, "TZ=GMT0", "TZ=JST-9",
98418dba
CW
14650 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
14651};
14652#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 14653
98418dba
CW
14654/* Fail if mktime fails to convert a date in the spring-forward gap.
14655 Based on a problem report from Andreas Jaeger. */
14656static void
14657spring_forward_gap ()
14658{
14659 /* glibc (up to about 1998-10-07) failed this test. */
14660 struct tm tm;
14661
14662 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
14663 instead of "TZ=America/Vancouver" in order to detect the bug even
14664 on systems that don't support the Olson extension, or don't have the
14665 full zoneinfo tables installed. */
14666 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
14667
14668 tm.tm_year = 98;
14669 tm.tm_mon = 3;
14670 tm.tm_mday = 5;
14671 tm.tm_hour = 2;
14672 tm.tm_min = 0;
14673 tm.tm_sec = 0;
14674 tm.tm_isdst = -1;
14675 if (mktime (&tm) == (time_t)-1)
14676 exit (1);
14677}
14678
14679static void
edfaf76d 14680mktime_test1 (now)
98418dba
CW
14681 time_t now;
14682{
14683 struct tm *lt;
14684 if ((lt = localtime (&now)) && mktime (lt) != now)
14685 exit (1);
edfaf76d
LK
14686}
14687
14688static void
14689mktime_test (now)
14690 time_t now;
14691{
14692 mktime_test1 (now);
14693 mktime_test1 ((time_t) (time_t_max - now));
14694 mktime_test1 ((time_t) (time_t_min + now));
98418dba
CW
14695}
14696
14697static void
14698irix_6_4_bug ()
14699{
14700 /* Based on code from Ariel Faigon. */
14701 struct tm tm;
14702 tm.tm_year = 96;
14703 tm.tm_mon = 3;
14704 tm.tm_mday = 0;
14705 tm.tm_hour = 0;
14706 tm.tm_min = 0;
14707 tm.tm_sec = 0;
14708 tm.tm_isdst = -1;
14709 mktime (&tm);
14710 if (tm.tm_mon != 2 || tm.tm_mday != 31)
14711 exit (1);
14712}
14713
14714static void
14715bigtime_test (j)
14716 int j;
14717{
14718 struct tm tm;
14719 time_t now;
14720 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
14721 now = mktime (&tm);
14722 if (now != (time_t) -1)
14723 {
14724 struct tm *lt = localtime (&now);
14725 if (! (lt
14726 && lt->tm_year == tm.tm_year
14727 && lt->tm_mon == tm.tm_mon
14728 && lt->tm_mday == tm.tm_mday
14729 && lt->tm_hour == tm.tm_hour
14730 && lt->tm_min == tm.tm_min
14731 && lt->tm_sec == tm.tm_sec
14732 && lt->tm_yday == tm.tm_yday
14733 && lt->tm_wday == tm.tm_wday
14734 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
14735 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
14736 exit (1);
14737 }
14738}
14739
14740int
14741main ()
14742{
14743 time_t t, delta;
14744 int i, j;
14745
14746 /* This test makes some buggy mktime implementations loop.
14747 Give up after 60 seconds; a mktime slower than that
14748 isn't worth using anyway. */
14749 alarm (60);
14750
14751 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
14752 continue;
14753 time_t_max--;
edfaf76d
LK
14754 if ((time_t) -1 < 0)
14755 for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
14756 continue;
98418dba
CW
14757 delta = time_t_max / 997; /* a suitable prime number */
14758 for (i = 0; i < N_STRINGS; i++)
14759 {
14760 if (tz_strings[i])
14761 putenv (tz_strings[i]);
503d2be0 14762
98418dba
CW
14763 for (t = 0; t <= time_t_max - delta; t += delta)
14764 mktime_test (t);
edfaf76d
LK
14765 mktime_test ((time_t) 1);
14766 mktime_test ((time_t) (60 * 60));
14767 mktime_test ((time_t) (60 * 60 * 24));
98418dba
CW
14768
14769 for (j = 1; 0 < j; j *= 2)
edfaf76d 14770 bigtime_test (j);
98418dba
CW
14771 bigtime_test (j - 1);
14772 }
14773 irix_6_4_bug ();
14774 spring_forward_gap ();
14775 exit (0);
503d2be0
AS
14776}
14777_ACEOF
98418dba 14778rm -f conftest$ac_exeext
c0d27fcc 14779if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14780 (eval $ac_link) 2>&5
14781 ac_status=$?
c0d27fcc 14782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14783 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 14784 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14785 (eval $ac_try) 2>&5
14786 ac_status=$?
c0d27fcc 14787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14788 (exit $ac_status); }; }; then
98418dba 14789 ac_cv_func_working_mktime=yes
503d2be0 14790else
98418dba
CW
14791 echo "$as_me: program exited with status $ac_status" >&5
14792echo "$as_me: failed program was:" >&5
19650fd6
AS
14793sed 's/^/| /' conftest.$ac_ext >&5
14794
c0d27fcc 14795( exit $ac_status )
98418dba 14796ac_cv_func_working_mktime=no
503d2be0 14797fi
edfaf76d 14798rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 14799fi
ba4481b5 14800fi
c0d27fcc 14801echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
14802echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
14803if test $ac_cv_func_working_mktime = no; then
edfaf76d
LK
14804 case $LIBOBJS in
14805 "mktime.$ac_objext" | \
14806 *" mktime.$ac_objext" | \
14807 "mktime.$ac_objext "* | \
14808 *" mktime.$ac_objext "* ) ;;
14809 *) LIBOBJS="$LIBOBJS mktime.$ac_objext" ;;
14810esac
14811
ba4481b5
DL
14812fi
14813
98418dba 14814if test "$ac_cv_func_working_mktime" = no; then
b936fae4 14815
c0d27fcc 14816cat >>confdefs.h <<\_ACEOF
98418dba 14817#define BROKEN_MKTIME 1
c0d27fcc 14818_ACEOF
ba4481b5 14819
ba4481b5 14820fi
503d2be0 14821
98418dba
CW
14822ac_have_func=no # yes means we've found a way to get the load average.
14823
6bae0ccf
DL
14824# Make sure getloadavg.c is where it belongs, at configure-time.
14825test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
14826 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
14827echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
14828 { (exit 1); exit 1; }; }
14829
98418dba
CW
14830ac_save_LIBS=$LIBS
14831
14832# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 14833(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
14834echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
14835if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 14836 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14837else
503d2be0 14838 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14839/* confdefs.h. */
14840_ACEOF
14841cat confdefs.h >>conftest.$ac_ext
14842cat >>conftest.$ac_ext <<_ACEOF
14843/* end confdefs.h. */
edfaf76d
LK
14844/* Define getloadavg to an innocuous variant, in case <limits.h> declares getloadavg.
14845 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14846#define getloadavg innocuous_getloadavg
14847
98418dba 14848/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14849 which can conflict with char getloadavg (); below.
14850 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14851 <limits.h> exists even on freestanding compilers. */
edfaf76d 14852
19650fd6
AS
14853#ifdef __STDC__
14854# include <limits.h>
14855#else
14856# include <assert.h>
14857#endif
edfaf76d
LK
14858
14859#undef getloadavg
14860
ba4481b5 14861/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14862#ifdef __cplusplus
14863extern "C"
19650fd6 14864{
503d2be0 14865#endif
ba4481b5 14866/* We use char because int might match the return type of a gcc2
503d2be0 14867 builtin and then its argument prototype would still apply. */
98418dba 14868char getloadavg ();
98418dba
CW
14869/* The GNU C library defines this for functions which it implements
14870 to always fail with ENOSYS. Some functions are actually named
14871 something starting with __ and the normal name is an alias. */
14872#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
14873choke me
14874#else
19650fd6
AS
14875char (*f) () = getloadavg;
14876#endif
14877#ifdef __cplusplus
14878}
cd958eb3
MB
14879#endif
14880
19650fd6
AS
14881int
14882main ()
14883{
14884return f != getloadavg;
503d2be0
AS
14885 ;
14886 return 0;
14887}
14888_ACEOF
14889rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14890if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 14891 (eval $ac_link) 2>conftest.er1
503d2be0 14892 ac_status=$?
edfaf76d
LK
14893 grep -v '^ *+' conftest.er1 >conftest.err
14894 rm -f conftest.er1
14895 cat conftest.err >&5
c0d27fcc 14896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14897 (exit $ac_status); } &&
10a3b1a1
EZ
14898 { ac_try='test -z "$ac_c_werror_flag"
14899 || test ! -s conftest.err'
edfaf76d
LK
14900 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14901 (eval $ac_try) 2>&5
14902 ac_status=$?
14903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14904 (exit $ac_status); }; } &&
14905 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14906 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14907 (eval $ac_try) 2>&5
14908 ac_status=$?
c0d27fcc 14909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14910 (exit $ac_status); }; }; then
98418dba 14911 ac_cv_func_getloadavg=yes
503d2be0
AS
14912else
14913 echo "$as_me: failed program was:" >&5
19650fd6
AS
14914sed 's/^/| /' conftest.$ac_ext >&5
14915
98418dba 14916ac_cv_func_getloadavg=no
503d2be0 14917fi
edfaf76d
LK
14918rm -f conftest.err conftest.$ac_objext \
14919 conftest$ac_exeext conftest.$ac_ext
ba4481b5 14920fi
c0d27fcc 14921echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
14922echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
14923if test $ac_cv_func_getloadavg = yes; then
14924 exit 0
14925else
14926 exit 1
ba4481b5 14927fi
98418dba 14928) && ac_have_func=yes
ba4481b5 14929
98418dba 14930# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 14931
98418dba
CW
14932for ac_func in pstat_getdynamic
14933do
14934as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14935echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14936echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14937if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14938 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14939else
503d2be0 14940 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14941/* confdefs.h. */
14942_ACEOF
14943cat confdefs.h >>conftest.$ac_ext
14944cat >>conftest.$ac_ext <<_ACEOF
14945/* end confdefs.h. */
edfaf76d
LK
14946/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14947 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14948#define $ac_func innocuous_$ac_func
14949
98418dba 14950/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14951 which can conflict with char $ac_func (); below.
14952 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14953 <limits.h> exists even on freestanding compilers. */
edfaf76d 14954
19650fd6
AS
14955#ifdef __STDC__
14956# include <limits.h>
14957#else
14958# include <assert.h>
14959#endif
edfaf76d
LK
14960
14961#undef $ac_func
14962
ba4481b5 14963/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14964#ifdef __cplusplus
14965extern "C"
19650fd6 14966{
503d2be0 14967#endif
ba4481b5 14968/* We use char because int might match the return type of a gcc2
503d2be0 14969 builtin and then its argument prototype would still apply. */
98418dba 14970char $ac_func ();
98418dba
CW
14971/* The GNU C library defines this for functions which it implements
14972 to always fail with ENOSYS. Some functions are actually named
14973 something starting with __ and the normal name is an alias. */
14974#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14975choke me
14976#else
19650fd6
AS
14977char (*f) () = $ac_func;
14978#endif
14979#ifdef __cplusplus
14980}
98418dba
CW
14981#endif
14982
19650fd6
AS
14983int
14984main ()
14985{
14986return f != $ac_func;
98418dba
CW
14987 ;
14988 return 0;
14989}
f21fadcc 14990_ACEOF
98418dba 14991rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14992if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 14993 (eval $ac_link) 2>conftest.er1
f21fadcc 14994 ac_status=$?
edfaf76d
LK
14995 grep -v '^ *+' conftest.er1 >conftest.err
14996 rm -f conftest.er1
14997 cat conftest.err >&5
c0d27fcc 14998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14999 (exit $ac_status); } &&
10a3b1a1
EZ
15000 { ac_try='test -z "$ac_c_werror_flag"
15001 || test ! -s conftest.err'
edfaf76d
LK
15002 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15003 (eval $ac_try) 2>&5
15004 ac_status=$?
15005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15006 (exit $ac_status); }; } &&
15007 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15008 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
15009 (eval $ac_try) 2>&5
15010 ac_status=$?
c0d27fcc 15011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15012 (exit $ac_status); }; }; then
15013 eval "$as_ac_var=yes"
f21fadcc
JD
15014else
15015 echo "$as_me: failed program was:" >&5
19650fd6
AS
15016sed 's/^/| /' conftest.$ac_ext >&5
15017
98418dba 15018eval "$as_ac_var=no"
f21fadcc 15019fi
edfaf76d
LK
15020rm -f conftest.err conftest.$ac_objext \
15021 conftest$ac_exeext conftest.$ac_ext
f21fadcc 15022fi
c0d27fcc 15023echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
15024echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15025if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15026 cat >>confdefs.h <<_ACEOF
98418dba 15027#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15028_ACEOF
98418dba
CW
15029
15030fi
15031done
15032
c0d27fcc 15033
98418dba
CW
15034# Solaris has libkstat which does not require root.
15035
c0d27fcc 15036echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
15037echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
15038if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
15039 echo $ECHO_N "(cached) $ECHO_C" >&6
15040else
15041 ac_check_lib_save_LIBS=$LIBS
98418dba 15042LIBS="-lkstat $LIBS"
f21fadcc 15043cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15044/* confdefs.h. */
15045_ACEOF
15046cat confdefs.h >>conftest.$ac_ext
15047cat >>conftest.$ac_ext <<_ACEOF
15048/* end confdefs.h. */
f21fadcc
JD
15049
15050/* Override any gcc2 internal prototype to avoid an error. */
15051#ifdef __cplusplus
15052extern "C"
15053#endif
15054/* We use char because int might match the return type of a gcc2
15055 builtin and then its argument prototype would still apply. */
98418dba 15056char kstat_open ();
f21fadcc
JD
15057int
15058main ()
15059{
98418dba 15060kstat_open ();
f21fadcc
JD
15061 ;
15062 return 0;
15063}
15064_ACEOF
15065rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15066if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15067 (eval $ac_link) 2>conftest.er1
f21fadcc 15068 ac_status=$?
edfaf76d
LK
15069 grep -v '^ *+' conftest.er1 >conftest.err
15070 rm -f conftest.er1
15071 cat conftest.err >&5
c0d27fcc 15072 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 15073 (exit $ac_status); } &&
10a3b1a1
EZ
15074 { ac_try='test -z "$ac_c_werror_flag"
15075 || test ! -s conftest.err'
edfaf76d
LK
15076 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15077 (eval $ac_try) 2>&5
15078 ac_status=$?
15079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15080 (exit $ac_status); }; } &&
15081 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15082 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
15083 (eval $ac_try) 2>&5
15084 ac_status=$?
c0d27fcc 15085 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 15086 (exit $ac_status); }; }; then
98418dba 15087 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
15088else
15089 echo "$as_me: failed program was:" >&5
19650fd6
AS
15090sed 's/^/| /' conftest.$ac_ext >&5
15091
98418dba 15092ac_cv_lib_kstat_kstat_open=no
f21fadcc 15093fi
edfaf76d
LK
15094rm -f conftest.err conftest.$ac_objext \
15095 conftest$ac_exeext conftest.$ac_ext
f21fadcc
JD
15096LIBS=$ac_check_lib_save_LIBS
15097fi
c0d27fcc 15098echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
15099echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
15100if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 15101 cat >>confdefs.h <<_ACEOF
98418dba 15102#define HAVE_LIBKSTAT 1
c0d27fcc 15103_ACEOF
f21fadcc 15104
98418dba 15105 LIBS="-lkstat $LIBS"
f21fadcc 15106
f21fadcc
JD
15107fi
15108
98418dba
CW
15109test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
15110
15111# Some systems with -lutil have (and need) -lkvm as well, some do not.
15112# On Solaris, -lkvm requires nlist from -lelf, so check that first
15113# to get the right answer into the cache.
15114# For kstat on solaris, we need libelf to force the definition of SVR4 below.
15115if test $ac_have_func = no; then
c0d27fcc 15116 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
15117echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
15118if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 15119 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15120else
98418dba
CW
15121 ac_check_lib_save_LIBS=$LIBS
15122LIBS="-lelf $LIBS"
15123cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15124/* confdefs.h. */
15125_ACEOF
15126cat confdefs.h >>conftest.$ac_ext
15127cat >>conftest.$ac_ext <<_ACEOF
15128/* end confdefs.h. */
98418dba
CW
15129
15130/* Override any gcc2 internal prototype to avoid an error. */
15131#ifdef __cplusplus
15132extern "C"
15133#endif
15134/* We use char because int might match the return type of a gcc2
15135 builtin and then its argument prototype would still apply. */
15136char elf_begin ();
503d2be0
AS
15137int
15138main ()
15139{
98418dba 15140elf_begin ();
503d2be0
AS
15141 ;
15142 return 0;
15143}
15144_ACEOF
15145rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15146if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15147 (eval $ac_link) 2>conftest.er1
503d2be0 15148 ac_status=$?
edfaf76d
LK
15149 grep -v '^ *+' conftest.er1 >conftest.err
15150 rm -f conftest.er1
15151 cat conftest.err >&5
c0d27fcc 15152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15153 (exit $ac_status); } &&
10a3b1a1
EZ
15154 { ac_try='test -z "$ac_c_werror_flag"
15155 || test ! -s conftest.err'
edfaf76d
LK
15156 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15157 (eval $ac_try) 2>&5
15158 ac_status=$?
15159 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15160 (exit $ac_status); }; } &&
15161 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15162 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15163 (eval $ac_try) 2>&5
15164 ac_status=$?
c0d27fcc 15165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15166 (exit $ac_status); }; }; then
98418dba 15167 ac_cv_lib_elf_elf_begin=yes
ba4481b5 15168else
503d2be0 15169 echo "$as_me: failed program was:" >&5
19650fd6
AS
15170sed 's/^/| /' conftest.$ac_ext >&5
15171
98418dba 15172ac_cv_lib_elf_elf_begin=no
ba4481b5 15173fi
edfaf76d
LK
15174rm -f conftest.err conftest.$ac_objext \
15175 conftest$ac_exeext conftest.$ac_ext
98418dba 15176LIBS=$ac_check_lib_save_LIBS
ba4481b5 15177fi
c0d27fcc 15178echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
15179echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
15180if test $ac_cv_lib_elf_elf_begin = yes; then
15181 LIBS="-lelf $LIBS"
ba4481b5
DL
15182fi
15183
98418dba
CW
15184fi
15185if test $ac_have_func = no; then
c0d27fcc 15186 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
15187echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
15188if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 15189 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15190else
98418dba
CW
15191 ac_check_lib_save_LIBS=$LIBS
15192LIBS="-lkvm $LIBS"
15193cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15194/* confdefs.h. */
15195_ACEOF
15196cat confdefs.h >>conftest.$ac_ext
15197cat >>conftest.$ac_ext <<_ACEOF
15198/* end confdefs.h. */
98418dba
CW
15199
15200/* Override any gcc2 internal prototype to avoid an error. */
15201#ifdef __cplusplus
15202extern "C"
15203#endif
15204/* We use char because int might match the return type of a gcc2
15205 builtin and then its argument prototype would still apply. */
15206char kvm_open ();
503d2be0
AS
15207int
15208main ()
15209{
98418dba 15210kvm_open ();
503d2be0
AS
15211 ;
15212 return 0;
15213}
15214_ACEOF
15215rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15216if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15217 (eval $ac_link) 2>conftest.er1
503d2be0 15218 ac_status=$?
edfaf76d
LK
15219 grep -v '^ *+' conftest.er1 >conftest.err
15220 rm -f conftest.er1
15221 cat conftest.err >&5
c0d27fcc 15222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15223 (exit $ac_status); } &&
10a3b1a1
EZ
15224 { ac_try='test -z "$ac_c_werror_flag"
15225 || test ! -s conftest.err'
edfaf76d
LK
15226 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15227 (eval $ac_try) 2>&5
15228 ac_status=$?
15229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15230 (exit $ac_status); }; } &&
15231 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15232 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15233 (eval $ac_try) 2>&5
15234 ac_status=$?
c0d27fcc 15235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15236 (exit $ac_status); }; }; then
98418dba 15237 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
15238else
15239 echo "$as_me: failed program was:" >&5
19650fd6
AS
15240sed 's/^/| /' conftest.$ac_ext >&5
15241
98418dba 15242ac_cv_lib_kvm_kvm_open=no
503d2be0 15243fi
edfaf76d
LK
15244rm -f conftest.err conftest.$ac_objext \
15245 conftest$ac_exeext conftest.$ac_ext
98418dba 15246LIBS=$ac_check_lib_save_LIBS
503d2be0 15247fi
c0d27fcc 15248echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
15249echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
15250if test $ac_cv_lib_kvm_kvm_open = yes; then
15251 LIBS="-lkvm $LIBS"
ba4481b5
DL
15252fi
15253
98418dba 15254 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 15255 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
15256echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
15257if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 15258 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15259else
98418dba
CW
15260 ac_check_lib_save_LIBS=$LIBS
15261LIBS="-lutil $LIBS"
15262cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15263/* confdefs.h. */
15264_ACEOF
15265cat confdefs.h >>conftest.$ac_ext
15266cat >>conftest.$ac_ext <<_ACEOF
15267/* end confdefs.h. */
98418dba
CW
15268
15269/* Override any gcc2 internal prototype to avoid an error. */
15270#ifdef __cplusplus
15271extern "C"
15272#endif
15273/* We use char because int might match the return type of a gcc2
15274 builtin and then its argument prototype would still apply. */
15275char getloadavg ();
503d2be0
AS
15276int
15277main ()
15278{
98418dba 15279getloadavg ();
503d2be0
AS
15280 ;
15281 return 0;
15282}
15283_ACEOF
15284rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15285if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15286 (eval $ac_link) 2>conftest.er1
503d2be0 15287 ac_status=$?
edfaf76d
LK
15288 grep -v '^ *+' conftest.er1 >conftest.err
15289 rm -f conftest.er1
15290 cat conftest.err >&5
c0d27fcc 15291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15292 (exit $ac_status); } &&
10a3b1a1
EZ
15293 { ac_try='test -z "$ac_c_werror_flag"
15294 || test ! -s conftest.err'
edfaf76d
LK
15295 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15296 (eval $ac_try) 2>&5
15297 ac_status=$?
15298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15299 (exit $ac_status); }; } &&
15300 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
15301 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15302 (eval $ac_try) 2>&5
15303 ac_status=$?
15304 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15305 (exit $ac_status); }; }; then
15306 ac_cv_lib_util_getloadavg=yes
15307else
503d2be0 15308 echo "$as_me: failed program was:" >&5
19650fd6
AS
15309sed 's/^/| /' conftest.$ac_ext >&5
15310
98418dba 15311ac_cv_lib_util_getloadavg=no
ba4481b5 15312fi
edfaf76d
LK
15313rm -f conftest.err conftest.$ac_objext \
15314 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
15315LIBS=$ac_check_lib_save_LIBS
15316fi
c0d27fcc 15317echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
15318echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
15319if test $ac_cv_lib_util_getloadavg = yes; then
15320 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 15321fi
503d2be0 15322
98418dba 15323fi
ba4481b5 15324
98418dba
CW
15325if test $ac_have_func = no; then
15326 # There is a commonly available library for RS/6000 AIX.
15327 # Since it is not a standard part of AIX, it might be installed locally.
15328 ac_getloadavg_LIBS=$LIBS
15329 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 15330 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
15331echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
15332if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 15333 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15334else
98418dba
CW
15335 ac_check_lib_save_LIBS=$LIBS
15336LIBS="-lgetloadavg $LIBS"
15337cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15338/* confdefs.h. */
15339_ACEOF
15340cat confdefs.h >>conftest.$ac_ext
15341cat >>conftest.$ac_ext <<_ACEOF
15342/* end confdefs.h. */
ba4481b5 15343
98418dba
CW
15344/* Override any gcc2 internal prototype to avoid an error. */
15345#ifdef __cplusplus
15346extern "C"
15347#endif
15348/* We use char because int might match the return type of a gcc2
15349 builtin and then its argument prototype would still apply. */
15350char getloadavg ();
98418dba
CW
15351int
15352main ()
15353{
15354getloadavg ();
15355 ;
15356 return 0;
15357}
503d2be0 15358_ACEOF
98418dba 15359rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15360if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15361 (eval $ac_link) 2>conftest.er1
98418dba 15362 ac_status=$?
edfaf76d
LK
15363 grep -v '^ *+' conftest.er1 >conftest.err
15364 rm -f conftest.er1
15365 cat conftest.err >&5
c0d27fcc 15366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 15367 (exit $ac_status); } &&
10a3b1a1
EZ
15368 { ac_try='test -z "$ac_c_werror_flag"
15369 || test ! -s conftest.err'
edfaf76d
LK
15370 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15371 (eval $ac_try) 2>&5
15372 ac_status=$?
15373 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15374 (exit $ac_status); }; } &&
15375 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15376 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
15377 (eval $ac_try) 2>&5
15378 ac_status=$?
c0d27fcc 15379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15380 (exit $ac_status); }; }; then
15381 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 15382else
98418dba 15383 echo "$as_me: failed program was:" >&5
19650fd6
AS
15384sed 's/^/| /' conftest.$ac_ext >&5
15385
98418dba
CW
15386ac_cv_lib_getloadavg_getloadavg=no
15387fi
edfaf76d
LK
15388rm -f conftest.err conftest.$ac_objext \
15389 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
15390LIBS=$ac_check_lib_save_LIBS
15391fi
c0d27fcc 15392echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
15393echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
15394if test $ac_cv_lib_getloadavg_getloadavg = yes; then
15395 LIBS="-lgetloadavg $LIBS"
15396else
15397 LIBS=$ac_getloadavg_LIBS
ba4481b5 15398fi
ba4481b5
DL
15399
15400fi
98418dba
CW
15401
15402# Make sure it is really in the library, if we think we found it,
15403# otherwise set up the replacement function.
15404
15405for ac_func in getloadavg
15406do
15407as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15408echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15409echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15410if eval "test \"\${$as_ac_var+set}\" = set"; then
15411 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15412else
503d2be0 15413 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15414/* confdefs.h. */
15415_ACEOF
15416cat confdefs.h >>conftest.$ac_ext
15417cat >>conftest.$ac_ext <<_ACEOF
15418/* end confdefs.h. */
edfaf76d
LK
15419/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15420 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15421#define $ac_func innocuous_$ac_func
15422
ba4481b5 15423/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15424 which can conflict with char $ac_func (); below.
15425 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15426 <limits.h> exists even on freestanding compilers. */
edfaf76d 15427
19650fd6
AS
15428#ifdef __STDC__
15429# include <limits.h>
15430#else
15431# include <assert.h>
15432#endif
edfaf76d
LK
15433
15434#undef $ac_func
15435
ba4481b5 15436/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15437#ifdef __cplusplus
15438extern "C"
19650fd6 15439{
503d2be0 15440#endif
ba4481b5 15441/* We use char because int might match the return type of a gcc2
503d2be0
AS
15442 builtin and then its argument prototype would still apply. */
15443char $ac_func ();
ba4481b5
DL
15444/* The GNU C library defines this for functions which it implements
15445 to always fail with ENOSYS. Some functions are actually named
15446 something starting with __ and the normal name is an alias. */
15447#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15448choke me
15449#else
19650fd6
AS
15450char (*f) () = $ac_func;
15451#endif
15452#ifdef __cplusplus
15453}
cd958eb3
MB
15454#endif
15455
19650fd6
AS
15456int
15457main ()
15458{
15459return f != $ac_func;
503d2be0
AS
15460 ;
15461 return 0;
15462}
15463_ACEOF
15464rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15465if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15466 (eval $ac_link) 2>conftest.er1
503d2be0 15467 ac_status=$?
edfaf76d
LK
15468 grep -v '^ *+' conftest.er1 >conftest.err
15469 rm -f conftest.er1
15470 cat conftest.err >&5
c0d27fcc 15471 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15472 (exit $ac_status); } &&
10a3b1a1
EZ
15473 { ac_try='test -z "$ac_c_werror_flag"
15474 || test ! -s conftest.err'
edfaf76d
LK
15475 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15476 (eval $ac_try) 2>&5
15477 ac_status=$?
15478 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15479 (exit $ac_status); }; } &&
15480 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15481 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15482 (eval $ac_try) 2>&5
15483 ac_status=$?
c0d27fcc 15484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15485 (exit $ac_status); }; }; then
15486 eval "$as_ac_var=yes"
15487else
15488 echo "$as_me: failed program was:" >&5
19650fd6
AS
15489sed 's/^/| /' conftest.$ac_ext >&5
15490
503d2be0
AS
15491eval "$as_ac_var=no"
15492fi
edfaf76d
LK
15493rm -f conftest.err conftest.$ac_objext \
15494 conftest$ac_exeext conftest.$ac_ext
503d2be0 15495fi
c0d27fcc 15496echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15497echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15498if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15499 cat >>confdefs.h <<_ACEOF
98418dba 15500#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15501_ACEOF
503d2be0 15502
98418dba 15503else
edfaf76d
LK
15504 case $LIBOBJS in
15505 "getloadavg.$ac_objext" | \
15506 *" getloadavg.$ac_objext" | \
15507 "getloadavg.$ac_objext "* | \
15508 *" getloadavg.$ac_objext "* ) ;;
15509 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext" ;;
15510esac
15511
ba4481b5 15512
c0d27fcc 15513cat >>confdefs.h <<\_ACEOF
98418dba 15514#define C_GETLOADAVG 1
c0d27fcc 15515_ACEOF
ba4481b5 15516
98418dba
CW
15517# Figure out what our getloadavg.c needs.
15518ac_have_func=no
c0d27fcc
MR
15519if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
15520 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
15521echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
15522if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 15523 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15524fi
15525echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
15526echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 15527else
c0d27fcc
MR
15528 # Is the header compilable?
15529echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
15530echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
15531cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15532/* confdefs.h. */
15533_ACEOF
15534cat confdefs.h >>conftest.$ac_ext
15535cat >>conftest.$ac_ext <<_ACEOF
15536/* end confdefs.h. */
c0d27fcc
MR
15537$ac_includes_default
15538#include <sys/dg_sys_info.h>
15539_ACEOF
15540rm -f conftest.$ac_objext
15541if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 15542 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15543 ac_status=$?
edfaf76d
LK
15544 grep -v '^ *+' conftest.er1 >conftest.err
15545 rm -f conftest.er1
15546 cat conftest.err >&5
c0d27fcc
MR
15547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15548 (exit $ac_status); } &&
10a3b1a1
EZ
15549 { ac_try='test -z "$ac_c_werror_flag"
15550 || test ! -s conftest.err'
edfaf76d
LK
15551 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15552 (eval $ac_try) 2>&5
15553 ac_status=$?
15554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15555 (exit $ac_status); }; } &&
15556 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15557 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15558 (eval $ac_try) 2>&5
15559 ac_status=$?
15560 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15561 (exit $ac_status); }; }; then
15562 ac_header_compiler=yes
15563else
15564 echo "$as_me: failed program was:" >&5
19650fd6
AS
15565sed 's/^/| /' conftest.$ac_ext >&5
15566
c0d27fcc
MR
15567ac_header_compiler=no
15568fi
edfaf76d 15569rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15570echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15571echo "${ECHO_T}$ac_header_compiler" >&6
15572
15573# Is the header present?
15574echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
15575echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
15576cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15577/* confdefs.h. */
15578_ACEOF
15579cat confdefs.h >>conftest.$ac_ext
15580cat >>conftest.$ac_ext <<_ACEOF
15581/* end confdefs.h. */
98418dba
CW
15582#include <sys/dg_sys_info.h>
15583_ACEOF
c0d27fcc 15584if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
15585 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15586 ac_status=$?
6bae0ccf 15587 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15588 rm -f conftest.er1
15589 cat conftest.err >&5
c0d27fcc 15590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15591 (exit $ac_status); } >/dev/null; then
15592 if test -s conftest.err; then
15593 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 15594 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15595 else
15596 ac_cpp_err=
15597 fi
15598else
15599 ac_cpp_err=yes
ba4481b5 15600fi
98418dba 15601if test -z "$ac_cpp_err"; then
c0d27fcc 15602 ac_header_preproc=yes
98418dba
CW
15603else
15604 echo "$as_me: failed program was:" >&5
19650fd6
AS
15605sed 's/^/| /' conftest.$ac_ext >&5
15606
c0d27fcc 15607 ac_header_preproc=no
ba4481b5 15608fi
98418dba 15609rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15610echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15611echo "${ECHO_T}$ac_header_preproc" >&6
15612
15613# So? What about this header?
edfaf76d
LK
15614case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15615 yes:no: )
c0d27fcc
MR
15616 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
15617echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
15618 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&5
15619echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&2;}
15620 ac_header_preproc=yes
19650fd6 15621 ;;
edfaf76d 15622 no:yes:* )
c0d27fcc
MR
15623 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
15624echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
edfaf76d
LK
15625 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
15626echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
15627 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&5
15628echo "$as_me: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&2;}
15629 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&5
15630echo "$as_me: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15631 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
19650fd6 15632echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
15633 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&5
15634echo "$as_me: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15635 (
15636 cat <<\_ASBOX
edfaf76d
LK
15637## ------------------------------------------ ##
15638## Report this to the AC_PACKAGE_NAME lists. ##
15639## ------------------------------------------ ##
19650fd6
AS
15640_ASBOX
15641 ) |
15642 sed "s/^/$as_me: WARNING: /" >&2
15643 ;;
c0d27fcc
MR
15644esac
15645echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
15646echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
15647if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
15648 echo $ECHO_N "(cached) $ECHO_C" >&6
15649else
15650 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 15651fi
c0d27fcc 15652echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 15653echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
15654
15655fi
98418dba
CW
15656if test $ac_cv_header_sys_dg_sys_info_h = yes; then
15657 ac_have_func=yes
ba4481b5 15658
c0d27fcc 15659cat >>confdefs.h <<\_ACEOF
98418dba 15660#define DGUX 1
c0d27fcc
MR
15661_ACEOF
15662
503d2be0 15663
c0d27fcc 15664echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
15665echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
15666if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 15667 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15668else
503d2be0 15669 ac_check_lib_save_LIBS=$LIBS
98418dba 15670LIBS="-ldgc $LIBS"
503d2be0 15671cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15672/* confdefs.h. */
15673_ACEOF
15674cat confdefs.h >>conftest.$ac_ext
15675cat >>conftest.$ac_ext <<_ACEOF
15676/* end confdefs.h. */
503d2be0 15677
ba4481b5 15678/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15679#ifdef __cplusplus
15680extern "C"
15681#endif
ba4481b5 15682/* We use char because int might match the return type of a gcc2
503d2be0 15683 builtin and then its argument prototype would still apply. */
98418dba 15684char dg_sys_info ();
503d2be0
AS
15685int
15686main ()
15687{
98418dba 15688dg_sys_info ();
503d2be0
AS
15689 ;
15690 return 0;
15691}
15692_ACEOF
15693rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15694if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15695 (eval $ac_link) 2>conftest.er1
503d2be0 15696 ac_status=$?
edfaf76d
LK
15697 grep -v '^ *+' conftest.er1 >conftest.err
15698 rm -f conftest.er1
15699 cat conftest.err >&5
c0d27fcc 15700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15701 (exit $ac_status); } &&
10a3b1a1
EZ
15702 { ac_try='test -z "$ac_c_werror_flag"
15703 || test ! -s conftest.err'
edfaf76d
LK
15704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15705 (eval $ac_try) 2>&5
15706 ac_status=$?
15707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15708 (exit $ac_status); }; } &&
15709 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15711 (eval $ac_try) 2>&5
15712 ac_status=$?
c0d27fcc 15713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15714 (exit $ac_status); }; }; then
98418dba 15715 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
15716else
15717 echo "$as_me: failed program was:" >&5
19650fd6
AS
15718sed 's/^/| /' conftest.$ac_ext >&5
15719
98418dba 15720ac_cv_lib_dgc_dg_sys_info=no
503d2be0 15721fi
edfaf76d
LK
15722rm -f conftest.err conftest.$ac_objext \
15723 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
15724LIBS=$ac_check_lib_save_LIBS
15725fi
c0d27fcc 15726echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
15727echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
15728if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 15729 cat >>confdefs.h <<_ACEOF
98418dba 15730#define HAVE_LIBDGC 1
c0d27fcc 15731_ACEOF
ba4481b5 15732
98418dba 15733 LIBS="-ldgc $LIBS"
ba4481b5 15734
ba4481b5
DL
15735fi
15736
98418dba 15737fi
503d2be0 15738
c0d27fcc
MR
15739
15740
15741if test "${ac_cv_header_locale_h+set}" = set; then
15742 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
15743echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15744if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 15745 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15746fi
15747echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
15748echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 15749else
c0d27fcc
MR
15750 # Is the header compilable?
15751echo "$as_me:$LINENO: checking locale.h usability" >&5
15752echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
15753cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15754/* confdefs.h. */
15755_ACEOF
15756cat confdefs.h >>conftest.$ac_ext
15757cat >>conftest.$ac_ext <<_ACEOF
15758/* end confdefs.h. */
c0d27fcc
MR
15759$ac_includes_default
15760#include <locale.h>
15761_ACEOF
15762rm -f conftest.$ac_objext
15763if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 15764 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15765 ac_status=$?
edfaf76d
LK
15766 grep -v '^ *+' conftest.er1 >conftest.err
15767 rm -f conftest.er1
15768 cat conftest.err >&5
c0d27fcc
MR
15769 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15770 (exit $ac_status); } &&
10a3b1a1
EZ
15771 { ac_try='test -z "$ac_c_werror_flag"
15772 || test ! -s conftest.err'
edfaf76d
LK
15773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15774 (eval $ac_try) 2>&5
15775 ac_status=$?
15776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15777 (exit $ac_status); }; } &&
15778 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15779 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15780 (eval $ac_try) 2>&5
15781 ac_status=$?
15782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15783 (exit $ac_status); }; }; then
15784 ac_header_compiler=yes
15785else
15786 echo "$as_me: failed program was:" >&5
19650fd6
AS
15787sed 's/^/| /' conftest.$ac_ext >&5
15788
c0d27fcc
MR
15789ac_header_compiler=no
15790fi
edfaf76d 15791rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15792echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15793echo "${ECHO_T}$ac_header_compiler" >&6
15794
15795# Is the header present?
15796echo "$as_me:$LINENO: checking locale.h presence" >&5
15797echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
15798cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15799/* confdefs.h. */
15800_ACEOF
15801cat confdefs.h >>conftest.$ac_ext
15802cat >>conftest.$ac_ext <<_ACEOF
15803/* end confdefs.h. */
98418dba 15804#include <locale.h>
503d2be0 15805_ACEOF
c0d27fcc 15806if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 15807 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 15808 ac_status=$?
6bae0ccf 15809 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15810 rm -f conftest.er1
15811 cat conftest.err >&5
c0d27fcc 15812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15813 (exit $ac_status); } >/dev/null; then
15814 if test -s conftest.err; then
15815 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 15816 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15817 else
15818 ac_cpp_err=
15819 fi
503d2be0 15820else
98418dba 15821 ac_cpp_err=yes
503d2be0 15822fi
98418dba 15823if test -z "$ac_cpp_err"; then
c0d27fcc 15824 ac_header_preproc=yes
98418dba
CW
15825else
15826 echo "$as_me: failed program was:" >&5
19650fd6
AS
15827sed 's/^/| /' conftest.$ac_ext >&5
15828
c0d27fcc 15829 ac_header_preproc=no
ba4481b5 15830fi
98418dba 15831rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15832echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15833echo "${ECHO_T}$ac_header_preproc" >&6
15834
15835# So? What about this header?
edfaf76d
LK
15836case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15837 yes:no: )
c0d27fcc
MR
15838 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
15839echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
15840 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the compiler's result" >&5
15841echo "$as_me: WARNING: locale.h: proceeding with the compiler's result" >&2;}
15842 ac_header_preproc=yes
19650fd6 15843 ;;
edfaf76d 15844 no:yes:* )
c0d27fcc
MR
15845 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
15846echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
edfaf76d
LK
15847 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
15848echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
15849 { echo "$as_me:$LINENO: WARNING: locale.h: see the Autoconf documentation" >&5
15850echo "$as_me: WARNING: locale.h: see the Autoconf documentation" >&2;}
15851 { echo "$as_me:$LINENO: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&5
15852echo "$as_me: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15853 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
19650fd6 15854echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
15855 { echo "$as_me:$LINENO: WARNING: locale.h: in the future, the compiler will take precedence" >&5
15856echo "$as_me: WARNING: locale.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15857 (
15858 cat <<\_ASBOX
edfaf76d
LK
15859## ------------------------------------------ ##
15860## Report this to the AC_PACKAGE_NAME lists. ##
15861## ------------------------------------------ ##
19650fd6
AS
15862_ASBOX
15863 ) |
15864 sed "s/^/$as_me: WARNING: /" >&2
15865 ;;
c0d27fcc
MR
15866esac
15867echo "$as_me:$LINENO: checking for locale.h" >&5
15868echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15869if test "${ac_cv_header_locale_h+set}" = set; then
15870 echo $ECHO_N "(cached) $ECHO_C" >&6
15871else
15872 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 15873fi
c0d27fcc 15874echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
15875echo "${ECHO_T}$ac_cv_header_locale_h" >&6
15876
c0d27fcc
MR
15877fi
15878
15879
15880
98418dba 15881for ac_func in setlocale
ba4481b5 15882do
503d2be0 15883as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15884echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15885echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15886if eval "test \"\${$as_ac_var+set}\" = set"; then
15887 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15888else
503d2be0 15889 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15890/* confdefs.h. */
15891_ACEOF
15892cat confdefs.h >>conftest.$ac_ext
15893cat >>conftest.$ac_ext <<_ACEOF
15894/* end confdefs.h. */
edfaf76d
LK
15895/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15896 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15897#define $ac_func innocuous_$ac_func
15898
ba4481b5 15899/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15900 which can conflict with char $ac_func (); below.
15901 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15902 <limits.h> exists even on freestanding compilers. */
edfaf76d 15903
19650fd6
AS
15904#ifdef __STDC__
15905# include <limits.h>
15906#else
15907# include <assert.h>
15908#endif
edfaf76d
LK
15909
15910#undef $ac_func
15911
ba4481b5 15912/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15913#ifdef __cplusplus
15914extern "C"
19650fd6 15915{
503d2be0 15916#endif
ba4481b5 15917/* We use char because int might match the return type of a gcc2
503d2be0
AS
15918 builtin and then its argument prototype would still apply. */
15919char $ac_func ();
ba4481b5
DL
15920/* The GNU C library defines this for functions which it implements
15921 to always fail with ENOSYS. Some functions are actually named
15922 something starting with __ and the normal name is an alias. */
15923#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15924choke me
15925#else
19650fd6
AS
15926char (*f) () = $ac_func;
15927#endif
15928#ifdef __cplusplus
15929}
ba4481b5
DL
15930#endif
15931
19650fd6
AS
15932int
15933main ()
15934{
15935return f != $ac_func;
503d2be0
AS
15936 ;
15937 return 0;
15938}
15939_ACEOF
15940rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15941if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 15942 (eval $ac_link) 2>conftest.er1
503d2be0 15943 ac_status=$?
edfaf76d
LK
15944 grep -v '^ *+' conftest.er1 >conftest.err
15945 rm -f conftest.er1
15946 cat conftest.err >&5
c0d27fcc 15947 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15948 (exit $ac_status); } &&
10a3b1a1
EZ
15949 { ac_try='test -z "$ac_c_werror_flag"
15950 || test ! -s conftest.err'
edfaf76d
LK
15951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15952 (eval $ac_try) 2>&5
15953 ac_status=$?
15954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15955 (exit $ac_status); }; } &&
15956 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15957 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15958 (eval $ac_try) 2>&5
15959 ac_status=$?
c0d27fcc 15960 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15961 (exit $ac_status); }; }; then
15962 eval "$as_ac_var=yes"
15963else
15964 echo "$as_me: failed program was:" >&5
19650fd6
AS
15965sed 's/^/| /' conftest.$ac_ext >&5
15966
503d2be0
AS
15967eval "$as_ac_var=no"
15968fi
edfaf76d
LK
15969rm -f conftest.err conftest.$ac_objext \
15970 conftest$ac_exeext conftest.$ac_ext
503d2be0 15971fi
c0d27fcc 15972echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15973echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15974if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15975 cat >>confdefs.h <<_ACEOF
503d2be0 15976#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15977_ACEOF
ba4481b5 15978
ba4481b5
DL
15979fi
15980done
15981
c0d27fcc 15982
98418dba
CW
15983# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
15984# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
15985# Irix 4.0.5F has the header but not the library.
15986if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
15987 ac_have_func=yes
15988
c0d27fcc 15989cat >>confdefs.h <<\_ACEOF
98418dba 15990#define SVR4 1
c0d27fcc 15991_ACEOF
98418dba
CW
15992
15993fi
15994
15995if test $ac_have_func = no; then
c0d27fcc
MR
15996 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15997 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
15998echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15999if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 16000 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16001fi
16002echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
16003echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 16004else
c0d27fcc
MR
16005 # Is the header compilable?
16006echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
16007echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
16008cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16009/* confdefs.h. */
16010_ACEOF
16011cat confdefs.h >>conftest.$ac_ext
16012cat >>conftest.$ac_ext <<_ACEOF
16013/* end confdefs.h. */
c0d27fcc
MR
16014$ac_includes_default
16015#include <inq_stats/cpustats.h>
16016_ACEOF
16017rm -f conftest.$ac_objext
16018if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16019 (eval $ac_compile) 2>conftest.er1
c0d27fcc 16020 ac_status=$?
edfaf76d
LK
16021 grep -v '^ *+' conftest.er1 >conftest.err
16022 rm -f conftest.er1
16023 cat conftest.err >&5
c0d27fcc
MR
16024 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16025 (exit $ac_status); } &&
10a3b1a1
EZ
16026 { ac_try='test -z "$ac_c_werror_flag"
16027 || test ! -s conftest.err'
edfaf76d
LK
16028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16029 (eval $ac_try) 2>&5
16030 ac_status=$?
16031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16032 (exit $ac_status); }; } &&
16033 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
16034 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16035 (eval $ac_try) 2>&5
16036 ac_status=$?
16037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16038 (exit $ac_status); }; }; then
16039 ac_header_compiler=yes
16040else
16041 echo "$as_me: failed program was:" >&5
19650fd6
AS
16042sed 's/^/| /' conftest.$ac_ext >&5
16043
c0d27fcc
MR
16044ac_header_compiler=no
16045fi
edfaf76d 16046rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
16047echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16048echo "${ECHO_T}$ac_header_compiler" >&6
16049
16050# Is the header present?
16051echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
16052echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
16053cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16054/* confdefs.h. */
16055_ACEOF
16056cat confdefs.h >>conftest.$ac_ext
16057cat >>conftest.$ac_ext <<_ACEOF
16058/* end confdefs.h. */
98418dba 16059#include <inq_stats/cpustats.h>
503d2be0 16060_ACEOF
c0d27fcc 16061if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16062 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16063 ac_status=$?
6bae0ccf 16064 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16065 rm -f conftest.er1
16066 cat conftest.err >&5
c0d27fcc 16067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16068 (exit $ac_status); } >/dev/null; then
16069 if test -s conftest.err; then
16070 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 16071 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
16072 else
16073 ac_cpp_err=
16074 fi
16075else
16076 ac_cpp_err=yes
16077fi
16078if test -z "$ac_cpp_err"; then
c0d27fcc 16079 ac_header_preproc=yes
503d2be0
AS
16080else
16081 echo "$as_me: failed program was:" >&5
19650fd6
AS
16082sed 's/^/| /' conftest.$ac_ext >&5
16083
c0d27fcc 16084 ac_header_preproc=no
ba4481b5 16085fi
503d2be0 16086rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16087echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16088echo "${ECHO_T}$ac_header_preproc" >&6
16089
16090# So? What about this header?
edfaf76d
LK
16091case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16092 yes:no: )
c0d27fcc
MR
16093 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
16094echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
16095 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&5
16096echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&2;}
16097 ac_header_preproc=yes
19650fd6 16098 ;;
edfaf76d 16099 no:yes:* )
c0d27fcc
MR
16100 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
16101echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
edfaf76d
LK
16102 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
16103echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
16104 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&5
16105echo "$as_me: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&2;}
16106 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
16107echo "$as_me: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 16108 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 16109echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
16110 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&5
16111echo "$as_me: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
16112 (
16113 cat <<\_ASBOX
edfaf76d
LK
16114## ------------------------------------------ ##
16115## Report this to the AC_PACKAGE_NAME lists. ##
16116## ------------------------------------------ ##
19650fd6
AS
16117_ASBOX
16118 ) |
16119 sed "s/^/$as_me: WARNING: /" >&2
16120 ;;
c0d27fcc
MR
16121esac
16122echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
16123echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
16124if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
16125 echo $ECHO_N "(cached) $ECHO_C" >&6
16126else
16127 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 16128fi
c0d27fcc 16129echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 16130echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
16131
16132fi
98418dba
CW
16133if test $ac_cv_header_inq_stats_cpustats_h = yes; then
16134 ac_have_func=yes
ba4481b5 16135
c0d27fcc 16136cat >>confdefs.h <<\_ACEOF
98418dba 16137#define UMAX 1
c0d27fcc 16138_ACEOF
98418dba 16139
c0d27fcc
MR
16140
16141cat >>confdefs.h <<\_ACEOF
98418dba 16142#define UMAX4_3 1
c0d27fcc 16143_ACEOF
98418dba
CW
16144
16145fi
16146
c0d27fcc 16147
98418dba
CW
16148fi
16149
16150if test $ac_have_func = no; then
c0d27fcc
MR
16151 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
16152 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
16153echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
16154if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 16155 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16156fi
16157echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
16158echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 16159else
c0d27fcc
MR
16160 # Is the header compilable?
16161echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
16162echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
16163cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16164/* confdefs.h. */
16165_ACEOF
16166cat confdefs.h >>conftest.$ac_ext
16167cat >>conftest.$ac_ext <<_ACEOF
16168/* end confdefs.h. */
c0d27fcc
MR
16169$ac_includes_default
16170#include <sys/cpustats.h>
16171_ACEOF
16172rm -f conftest.$ac_objext
16173if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16174 (eval $ac_compile) 2>conftest.er1
c0d27fcc 16175 ac_status=$?
edfaf76d
LK
16176 grep -v '^ *+' conftest.er1 >conftest.err
16177 rm -f conftest.er1
16178 cat conftest.err >&5
c0d27fcc
MR
16179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16180 (exit $ac_status); } &&
10a3b1a1
EZ
16181 { ac_try='test -z "$ac_c_werror_flag"
16182 || test ! -s conftest.err'
edfaf76d
LK
16183 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16184 (eval $ac_try) 2>&5
16185 ac_status=$?
16186 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16187 (exit $ac_status); }; } &&
16188 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
16189 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16190 (eval $ac_try) 2>&5
16191 ac_status=$?
16192 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16193 (exit $ac_status); }; }; then
16194 ac_header_compiler=yes
16195else
16196 echo "$as_me: failed program was:" >&5
19650fd6
AS
16197sed 's/^/| /' conftest.$ac_ext >&5
16198
c0d27fcc
MR
16199ac_header_compiler=no
16200fi
edfaf76d 16201rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
16202echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16203echo "${ECHO_T}$ac_header_compiler" >&6
16204
16205# Is the header present?
16206echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
16207echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
16208cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16209/* confdefs.h. */
16210_ACEOF
16211cat confdefs.h >>conftest.$ac_ext
16212cat >>conftest.$ac_ext <<_ACEOF
16213/* end confdefs.h. */
98418dba
CW
16214#include <sys/cpustats.h>
16215_ACEOF
c0d27fcc 16216if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
16217 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16218 ac_status=$?
6bae0ccf 16219 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
16220 rm -f conftest.er1
16221 cat conftest.err >&5
c0d27fcc 16222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
16223 (exit $ac_status); } >/dev/null; then
16224 if test -s conftest.err; then
16225 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 16226 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
16227 else
16228 ac_cpp_err=
16229 fi
16230else
16231 ac_cpp_err=yes
503d2be0 16232fi
98418dba 16233if test -z "$ac_cpp_err"; then
c0d27fcc 16234 ac_header_preproc=yes
98418dba
CW
16235else
16236 echo "$as_me: failed program was:" >&5
19650fd6
AS
16237sed 's/^/| /' conftest.$ac_ext >&5
16238
c0d27fcc 16239 ac_header_preproc=no
98418dba
CW
16240fi
16241rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16242echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16243echo "${ECHO_T}$ac_header_preproc" >&6
16244
16245# So? What about this header?
edfaf76d
LK
16246case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16247 yes:no: )
c0d27fcc
MR
16248 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
16249echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
16250 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&5
16251echo "$as_me: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&2;}
16252 ac_header_preproc=yes
19650fd6 16253 ;;
edfaf76d 16254 no:yes:* )
c0d27fcc
MR
16255 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
16256echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
edfaf76d
LK
16257 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
16258echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
16259 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: see the Autoconf documentation" >&5
16260echo "$as_me: WARNING: sys/cpustats.h: see the Autoconf documentation" >&2;}
16261 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
16262echo "$as_me: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 16263 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 16264echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
16265 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&5
16266echo "$as_me: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
16267 (
16268 cat <<\_ASBOX
edfaf76d
LK
16269## ------------------------------------------ ##
16270## Report this to the AC_PACKAGE_NAME lists. ##
16271## ------------------------------------------ ##
19650fd6
AS
16272_ASBOX
16273 ) |
16274 sed "s/^/$as_me: WARNING: /" >&2
16275 ;;
c0d27fcc
MR
16276esac
16277echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
16278echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
16279if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
16280 echo $ECHO_N "(cached) $ECHO_C" >&6
16281else
16282 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 16283fi
c0d27fcc 16284echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 16285echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
16286
16287fi
98418dba 16288if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 16289 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 16290#define UMAX 1
c0d27fcc 16291_ACEOF
ba4481b5 16292
98418dba
CW
16293fi
16294
c0d27fcc 16295
98418dba
CW
16296fi
16297
16298if test $ac_have_func = no; then
16299
16300for ac_header in mach/mach.h
2c9dccc9
PJ
16301do
16302as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
16303if eval "test \"\${$as_ac_Header+set}\" = set"; then
16304 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
16305echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16306if eval "test \"\${$as_ac_Header+set}\" = set"; then
16307 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16308fi
16309echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16310echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 16311else
c0d27fcc
MR
16312 # Is the header compilable?
16313echo "$as_me:$LINENO: checking $ac_header usability" >&5
16314echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16315cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16316/* confdefs.h. */
16317_ACEOF
16318cat confdefs.h >>conftest.$ac_ext
16319cat >>conftest.$ac_ext <<_ACEOF
16320/* end confdefs.h. */
c0d27fcc
MR
16321$ac_includes_default
16322#include <$ac_header>
16323_ACEOF
16324rm -f conftest.$ac_objext
16325if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16326 (eval $ac_compile) 2>conftest.er1
c0d27fcc 16327 ac_status=$?
edfaf76d
LK
16328 grep -v '^ *+' conftest.er1 >conftest.err
16329 rm -f conftest.er1
16330 cat conftest.err >&5
c0d27fcc
MR
16331 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16332 (exit $ac_status); } &&
10a3b1a1
EZ
16333 { ac_try='test -z "$ac_c_werror_flag"
16334 || test ! -s conftest.err'
edfaf76d
LK
16335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16336 (eval $ac_try) 2>&5
16337 ac_status=$?
16338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16339 (exit $ac_status); }; } &&
16340 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
16341 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16342 (eval $ac_try) 2>&5
16343 ac_status=$?
16344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16345 (exit $ac_status); }; }; then
16346 ac_header_compiler=yes
16347else
16348 echo "$as_me: failed program was:" >&5
19650fd6
AS
16349sed 's/^/| /' conftest.$ac_ext >&5
16350
c0d27fcc
MR
16351ac_header_compiler=no
16352fi
edfaf76d 16353rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
16354echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16355echo "${ECHO_T}$ac_header_compiler" >&6
16356
16357# Is the header present?
16358echo "$as_me:$LINENO: checking $ac_header presence" >&5
16359echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16360cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16361/* confdefs.h. */
16362_ACEOF
16363cat confdefs.h >>conftest.$ac_ext
16364cat >>conftest.$ac_ext <<_ACEOF
16365/* end confdefs.h. */
2c9dccc9
PJ
16366#include <$ac_header>
16367_ACEOF
c0d27fcc 16368if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
16369 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16370 ac_status=$?
6bae0ccf 16371 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
16372 rm -f conftest.er1
16373 cat conftest.err >&5
c0d27fcc 16374 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
16375 (exit $ac_status); } >/dev/null; then
16376 if test -s conftest.err; then
16377 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 16378 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2c9dccc9
PJ
16379 else
16380 ac_cpp_err=
16381 fi
16382else
16383 ac_cpp_err=yes
16384fi
16385if test -z "$ac_cpp_err"; then
c0d27fcc
MR
16386 ac_header_preproc=yes
16387else
16388 echo "$as_me: failed program was:" >&5
19650fd6
AS
16389sed 's/^/| /' conftest.$ac_ext >&5
16390
c0d27fcc
MR
16391 ac_header_preproc=no
16392fi
16393rm -f conftest.err conftest.$ac_ext
16394echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16395echo "${ECHO_T}$ac_header_preproc" >&6
16396
16397# So? What about this header?
edfaf76d
LK
16398case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16399 yes:no: )
c0d27fcc
MR
16400 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16401echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
16402 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16403echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16404 ac_header_preproc=yes
19650fd6 16405 ;;
edfaf76d 16406 no:yes:* )
c0d27fcc
MR
16407 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16408echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
16409 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16410echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16411 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16412echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16413 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
16414echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 16415 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 16416echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
16417 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16418echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
16419 (
16420 cat <<\_ASBOX
edfaf76d
LK
16421## ------------------------------------------ ##
16422## Report this to the AC_PACKAGE_NAME lists. ##
16423## ------------------------------------------ ##
19650fd6
AS
16424_ASBOX
16425 ) |
16426 sed "s/^/$as_me: WARNING: /" >&2
16427 ;;
c0d27fcc
MR
16428esac
16429echo "$as_me:$LINENO: checking for $ac_header" >&5
16430echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16431if eval "test \"\${$as_ac_Header+set}\" = set"; then
16432 echo $ECHO_N "(cached) $ECHO_C" >&6
16433else
edfaf76d 16434 eval "$as_ac_Header=\$ac_header_preproc"
c0d27fcc
MR
16435fi
16436echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16437echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16438
16439fi
16440if test `eval echo '${'$as_ac_Header'}'` = yes; then
16441 cat >>confdefs.h <<_ACEOF
16442#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16443_ACEOF
16444
16445fi
16446
16447done
16448
16449fi
16450
16451
16452for ac_header in nlist.h
16453do
16454as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16455if eval "test \"\${$as_ac_Header+set}\" = set"; then
16456 echo "$as_me:$LINENO: checking for $ac_header" >&5
16457echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16458if eval "test \"\${$as_ac_Header+set}\" = set"; then
16459 echo $ECHO_N "(cached) $ECHO_C" >&6
16460fi
16461echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16462echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
16463else
16464 # Is the header compilable?
16465echo "$as_me:$LINENO: checking $ac_header usability" >&5
16466echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16467cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16468/* confdefs.h. */
16469_ACEOF
16470cat confdefs.h >>conftest.$ac_ext
16471cat >>conftest.$ac_ext <<_ACEOF
16472/* end confdefs.h. */
c0d27fcc
MR
16473$ac_includes_default
16474#include <$ac_header>
16475_ACEOF
16476rm -f conftest.$ac_objext
16477if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16478 (eval $ac_compile) 2>conftest.er1
c0d27fcc 16479 ac_status=$?
edfaf76d
LK
16480 grep -v '^ *+' conftest.er1 >conftest.err
16481 rm -f conftest.er1
16482 cat conftest.err >&5
c0d27fcc
MR
16483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16484 (exit $ac_status); } &&
10a3b1a1
EZ
16485 { ac_try='test -z "$ac_c_werror_flag"
16486 || test ! -s conftest.err'
edfaf76d
LK
16487 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16488 (eval $ac_try) 2>&5
16489 ac_status=$?
16490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16491 (exit $ac_status); }; } &&
16492 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
16493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16494 (eval $ac_try) 2>&5
16495 ac_status=$?
16496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16497 (exit $ac_status); }; }; then
16498 ac_header_compiler=yes
2c9dccc9
PJ
16499else
16500 echo "$as_me: failed program was:" >&5
19650fd6
AS
16501sed 's/^/| /' conftest.$ac_ext >&5
16502
c0d27fcc 16503ac_header_compiler=no
98418dba 16504fi
edfaf76d 16505rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
16506echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16507echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 16508
c0d27fcc
MR
16509# Is the header present?
16510echo "$as_me:$LINENO: checking $ac_header presence" >&5
16511echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16512cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16513/* confdefs.h. */
16514_ACEOF
16515cat confdefs.h >>conftest.$ac_ext
16516cat >>conftest.$ac_ext <<_ACEOF
16517/* end confdefs.h. */
503d2be0
AS
16518#include <$ac_header>
16519_ACEOF
c0d27fcc 16520if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16521 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16522 ac_status=$?
6bae0ccf 16523 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16524 rm -f conftest.er1
16525 cat conftest.err >&5
c0d27fcc 16526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16527 (exit $ac_status); } >/dev/null; then
16528 if test -s conftest.err; then
16529 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 16530 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
16531 else
16532 ac_cpp_err=
16533 fi
16534else
16535 ac_cpp_err=yes
16536fi
16537if test -z "$ac_cpp_err"; then
c0d27fcc 16538 ac_header_preproc=yes
503d2be0
AS
16539else
16540 echo "$as_me: failed program was:" >&5
19650fd6
AS
16541sed 's/^/| /' conftest.$ac_ext >&5
16542
c0d27fcc 16543 ac_header_preproc=no
b5de8dc0 16544fi
503d2be0 16545rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16546echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16547echo "${ECHO_T}$ac_header_preproc" >&6
16548
16549# So? What about this header?
edfaf76d
LK
16550case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16551 yes:no: )
c0d27fcc
MR
16552 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16553echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
16554 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16555echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16556 ac_header_preproc=yes
19650fd6 16557 ;;
edfaf76d 16558 no:yes:* )
c0d27fcc
MR
16559 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16560echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
16561 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16562echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16563 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16564echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16565 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
16566echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 16567 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 16568echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
16569 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16570echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
16571 (
16572 cat <<\_ASBOX
edfaf76d
LK
16573## ------------------------------------------ ##
16574## Report this to the AC_PACKAGE_NAME lists. ##
16575## ------------------------------------------ ##
19650fd6
AS
16576_ASBOX
16577 ) |
16578 sed "s/^/$as_me: WARNING: /" >&2
16579 ;;
c0d27fcc
MR
16580esac
16581echo "$as_me:$LINENO: checking for $ac_header" >&5
16582echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16583if eval "test \"\${$as_ac_Header+set}\" = set"; then
16584 echo $ECHO_N "(cached) $ECHO_C" >&6
16585else
edfaf76d 16586 eval "$as_ac_Header=\$ac_header_preproc"
b5de8dc0 16587fi
c0d27fcc 16588echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 16589echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
16590
16591fi
98418dba 16592if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 16593 cat >>confdefs.h <<_ACEOF
98418dba 16594#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
16595_ACEOF
16596 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
16597echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
16598if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 16599 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 16600else
503d2be0 16601 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16602/* confdefs.h. */
16603_ACEOF
16604cat confdefs.h >>conftest.$ac_ext
16605cat >>conftest.$ac_ext <<_ACEOF
16606/* end confdefs.h. */
98418dba 16607#include <nlist.h>
b5de8dc0 16608
503d2be0
AS
16609int
16610main ()
16611{
98418dba
CW
16612static struct nlist ac_aggr;
16613if (ac_aggr.n_un.n_name)
16614return 0;
503d2be0
AS
16615 ;
16616 return 0;
16617}
16618_ACEOF
98418dba 16619rm -f conftest.$ac_objext
c0d27fcc 16620if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16621 (eval $ac_compile) 2>conftest.er1
503d2be0 16622 ac_status=$?
edfaf76d
LK
16623 grep -v '^ *+' conftest.er1 >conftest.err
16624 rm -f conftest.er1
16625 cat conftest.err >&5
c0d27fcc 16626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16627 (exit $ac_status); } &&
10a3b1a1
EZ
16628 { ac_try='test -z "$ac_c_werror_flag"
16629 || test ! -s conftest.err'
c0d27fcc 16630 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16631 (eval $ac_try) 2>&5
16632 ac_status=$?
c0d27fcc 16633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
edfaf76d
LK
16634 (exit $ac_status); }; } &&
16635 { ac_try='test -s conftest.$ac_objext'
16636 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16637 (eval $ac_try) 2>&5
16638 ac_status=$?
16639 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16640 (exit $ac_status); }; }; then
16641 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
16642else
16643 echo "$as_me: failed program was:" >&5
19650fd6
AS
16644sed 's/^/| /' conftest.$ac_ext >&5
16645
6bae0ccf 16646cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16647/* confdefs.h. */
16648_ACEOF
16649cat confdefs.h >>conftest.$ac_ext
16650cat >>conftest.$ac_ext <<_ACEOF
16651/* end confdefs.h. */
6bae0ccf
DL
16652#include <nlist.h>
16653
16654int
16655main ()
16656{
16657static struct nlist ac_aggr;
16658if (sizeof ac_aggr.n_un.n_name)
16659return 0;
16660 ;
16661 return 0;
16662}
16663_ACEOF
16664rm -f conftest.$ac_objext
16665if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16666 (eval $ac_compile) 2>conftest.er1
6bae0ccf 16667 ac_status=$?
edfaf76d
LK
16668 grep -v '^ *+' conftest.er1 >conftest.err
16669 rm -f conftest.er1
16670 cat conftest.err >&5
6bae0ccf
DL
16671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16672 (exit $ac_status); } &&
10a3b1a1
EZ
16673 { ac_try='test -z "$ac_c_werror_flag"
16674 || test ! -s conftest.err'
edfaf76d
LK
16675 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16676 (eval $ac_try) 2>&5
16677 ac_status=$?
16678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16679 (exit $ac_status); }; } &&
16680 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
16681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16682 (eval $ac_try) 2>&5
16683 ac_status=$?
16684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16685 (exit $ac_status); }; }; then
16686 ac_cv_member_struct_nlist_n_un_n_name=yes
16687else
16688 echo "$as_me: failed program was:" >&5
19650fd6
AS
16689sed 's/^/| /' conftest.$ac_ext >&5
16690
98418dba 16691ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 16692fi
edfaf76d 16693rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b5de8dc0 16694fi
edfaf76d 16695rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 16696fi
c0d27fcc 16697echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
16698echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
16699if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 16700
c0d27fcc 16701cat >>confdefs.h <<_ACEOF
98418dba 16702#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 16703_ACEOF
b5de8dc0 16704
c0d27fcc
MR
16705
16706cat >>confdefs.h <<\_ACEOF
98418dba 16707#define NLIST_NAME_UNION 1
c0d27fcc 16708_ACEOF
b5de8dc0 16709
98418dba 16710fi
b5de8dc0 16711
c0d27fcc 16712
98418dba 16713fi
c0d27fcc 16714
98418dba 16715done
b5de8dc0 16716
98418dba
CW
16717fi
16718done
b5de8dc0 16719
c0d27fcc 16720
98418dba 16721# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 16722echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
16723echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
16724if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
16725 echo $ECHO_N "(cached) $ECHO_C" >&6
16726else
16727 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16728/* confdefs.h. */
16729_ACEOF
16730cat confdefs.h >>conftest.$ac_ext
16731cat >>conftest.$ac_ext <<_ACEOF
16732/* end confdefs.h. */
6bae0ccf 16733#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
16734#ifdef LDAV_PRIVILEGED
16735Yowza Am I SETGID yet
16736#endif
16737_ACEOF
16738if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 16739 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
16740 ac_cv_func_getloadavg_setgid=yes
16741else
16742 ac_cv_func_getloadavg_setgid=no
16743fi
16744rm -f conftest*
b5de8dc0 16745
98418dba 16746fi
c0d27fcc 16747echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
16748echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
16749if test $ac_cv_func_getloadavg_setgid = yes; then
16750 NEED_SETGID=true
b5de8dc0 16751
c0d27fcc 16752cat >>confdefs.h <<\_ACEOF
98418dba 16753#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 16754_ACEOF
98418dba 16755
b5de8dc0 16756else
98418dba 16757 NEED_SETGID=false
b5de8dc0 16758fi
98418dba
CW
16759
16760if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 16761 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
16762echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
16763if test "${ac_cv_group_kmem+set}" = set; then
16764 echo $ECHO_N "(cached) $ECHO_C" >&6
16765else
16766 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
16767 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
16768 # If we got an error (system does not support symlinks), try without -L.
16769 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
16770 ac_cv_group_kmem=`echo $ac_ls_output \
edfaf76d 16771 | sed -ne 's/[ ][ ]*/ /g;
98418dba
CW
16772 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
16773 / /s/.* //;p;'`
16774
b5de8dc0 16775fi
c0d27fcc 16776echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
16777echo "${ECHO_T}$ac_cv_group_kmem" >&6
16778 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 16779fi
98418dba
CW
16780if test "x$ac_save_LIBS" = x; then
16781 GETLOADAVG_LIBS=$LIBS
16782else
16783 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 16784fi
98418dba 16785LIBS=$ac_save_LIBS
b5de8dc0 16786
c0d27fcc
MR
16787
16788
16789echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
16790echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
16791if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 16792 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16793else
b936fae4
AS
16794 while :; do
16795 ac_cv_sys_largefile_source=no
503d2be0 16796 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16797/* confdefs.h. */
16798_ACEOF
16799cat confdefs.h >>conftest.$ac_ext
16800cat >>conftest.$ac_ext <<_ACEOF
16801/* end confdefs.h. */
b936fae4 16802#include <stdio.h>
503d2be0
AS
16803int
16804main ()
16805{
b936fae4
AS
16806return !fseeko;
16807 ;
16808 return 0;
16809}
16810_ACEOF
16811rm -f conftest.$ac_objext
c0d27fcc 16812if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16813 (eval $ac_compile) 2>conftest.er1
b936fae4 16814 ac_status=$?
edfaf76d
LK
16815 grep -v '^ *+' conftest.er1 >conftest.err
16816 rm -f conftest.er1
16817 cat conftest.err >&5
c0d27fcc 16818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16819 (exit $ac_status); } &&
10a3b1a1
EZ
16820 { ac_try='test -z "$ac_c_werror_flag"
16821 || test ! -s conftest.err'
edfaf76d
LK
16822 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16823 (eval $ac_try) 2>&5
16824 ac_status=$?
16825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16826 (exit $ac_status); }; } &&
16827 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16828 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16829 (eval $ac_try) 2>&5
16830 ac_status=$?
c0d27fcc 16831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16832 (exit $ac_status); }; }; then
16833 break
16834else
16835 echo "$as_me: failed program was:" >&5
19650fd6
AS
16836sed 's/^/| /' conftest.$ac_ext >&5
16837
b936fae4 16838fi
edfaf76d 16839rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4 16840 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16841/* confdefs.h. */
16842_ACEOF
16843cat confdefs.h >>conftest.$ac_ext
16844cat >>conftest.$ac_ext <<_ACEOF
16845/* end confdefs.h. */
b936fae4
AS
16846#define _LARGEFILE_SOURCE 1
16847#include <stdio.h>
b936fae4
AS
16848int
16849main ()
16850{
16851return !fseeko;
16852 ;
16853 return 0;
16854}
16855_ACEOF
16856rm -f conftest.$ac_objext
c0d27fcc 16857if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 16858 (eval $ac_compile) 2>conftest.er1
b936fae4 16859 ac_status=$?
edfaf76d
LK
16860 grep -v '^ *+' conftest.er1 >conftest.err
16861 rm -f conftest.er1
16862 cat conftest.err >&5
c0d27fcc 16863 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16864 (exit $ac_status); } &&
10a3b1a1
EZ
16865 { ac_try='test -z "$ac_c_werror_flag"
16866 || test ! -s conftest.err'
edfaf76d
LK
16867 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16868 (eval $ac_try) 2>&5
16869 ac_status=$?
16870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16871 (exit $ac_status); }; } &&
16872 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16873 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16874 (eval $ac_try) 2>&5
16875 ac_status=$?
c0d27fcc 16876 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16877 (exit $ac_status); }; }; then
16878 ac_cv_sys_largefile_source=1; break
16879else
16880 echo "$as_me: failed program was:" >&5
19650fd6
AS
16881sed 's/^/| /' conftest.$ac_ext >&5
16882
b936fae4 16883fi
edfaf76d 16884rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4
AS
16885 break
16886done
16887fi
c0d27fcc 16888echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
16889echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16890if test "$ac_cv_sys_largefile_source" != no; then
16891
c0d27fcc 16892cat >>confdefs.h <<_ACEOF
b936fae4 16893#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 16894_ACEOF
b936fae4
AS
16895
16896fi
16897rm -f conftest*
4c343001 16898
b936fae4
AS
16899# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16900# in glibc 2.1.3, but that breaks too many other things.
16901# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 16902echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
16903echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16904if test "${ac_cv_func_fseeko+set}" = set; then
16905 echo $ECHO_N "(cached) $ECHO_C" >&6
16906else
16907 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16908/* confdefs.h. */
16909_ACEOF
16910cat confdefs.h >>conftest.$ac_ext
16911cat >>conftest.$ac_ext <<_ACEOF
16912/* end confdefs.h. */
b936fae4 16913#include <stdio.h>
b936fae4
AS
16914int
16915main ()
16916{
16917return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
16918 ;
16919 return 0;
16920}
16921_ACEOF
16922rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16923if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 16924 (eval $ac_link) 2>conftest.er1
503d2be0 16925 ac_status=$?
edfaf76d
LK
16926 grep -v '^ *+' conftest.er1 >conftest.err
16927 rm -f conftest.er1
16928 cat conftest.err >&5
c0d27fcc 16929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16930 (exit $ac_status); } &&
10a3b1a1
EZ
16931 { ac_try='test -z "$ac_c_werror_flag"
16932 || test ! -s conftest.err'
edfaf76d
LK
16933 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16934 (eval $ac_try) 2>&5
16935 ac_status=$?
16936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16937 (exit $ac_status); }; } &&
16938 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16939 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16940 (eval $ac_try) 2>&5
16941 ac_status=$?
c0d27fcc 16942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16943 (exit $ac_status); }; }; then
b936fae4 16944 ac_cv_func_fseeko=yes
503d2be0
AS
16945else
16946 echo "$as_me: failed program was:" >&5
19650fd6
AS
16947sed 's/^/| /' conftest.$ac_ext >&5
16948
b936fae4 16949ac_cv_func_fseeko=no
503d2be0 16950fi
edfaf76d
LK
16951rm -f conftest.err conftest.$ac_objext \
16952 conftest$ac_exeext conftest.$ac_ext
503d2be0 16953fi
c0d27fcc 16954echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
16955echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16956if test $ac_cv_func_fseeko = yes; then
16957
c0d27fcc 16958cat >>confdefs.h <<\_ACEOF
b936fae4 16959#define HAVE_FSEEKO 1
c0d27fcc 16960_ACEOF
b936fae4 16961
4c343001
DL
16962fi
16963
c0d27fcc 16964
52dbaac8
PE
16965# Configure getopt.
16966# getopt.m4 serial 10
16967
16968# The getopt module assume you want GNU getopt, with getopt_long etc,
16969# rather than vanilla POSIX getopt. This means your your code should
16970# always include <getopt.h> for the getopt prototypes.
16971
16972
16973
16974
16975
16976
16977
16978
16979
16980
16981
16982# Prerequisites of lib/getopt*.
16983
16984
16985
10a3b1a1 16986
52dbaac8
PE
16987 GETOPT_H=
16988
16989for ac_header in getopt.h
16990do
16991as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16992if eval "test \"\${$as_ac_Header+set}\" = set"; then
16993 echo "$as_me:$LINENO: checking for $ac_header" >&5
16994echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16995if eval "test \"\${$as_ac_Header+set}\" = set"; then
16996 echo $ECHO_N "(cached) $ECHO_C" >&6
16997fi
16998echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16999echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17000else
17001 # Is the header compilable?
17002echo "$as_me:$LINENO: checking $ac_header usability" >&5
17003echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17004cat >conftest.$ac_ext <<_ACEOF
17005/* confdefs.h. */
17006_ACEOF
17007cat confdefs.h >>conftest.$ac_ext
17008cat >>conftest.$ac_ext <<_ACEOF
17009/* end confdefs.h. */
17010$ac_includes_default
17011#include <$ac_header>
17012_ACEOF
17013rm -f conftest.$ac_objext
17014if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17015 (eval $ac_compile) 2>conftest.er1
17016 ac_status=$?
17017 grep -v '^ *+' conftest.er1 >conftest.err
17018 rm -f conftest.er1
17019 cat conftest.err >&5
17020 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17021 (exit $ac_status); } &&
10a3b1a1
EZ
17022 { ac_try='test -z "$ac_c_werror_flag"
17023 || test ! -s conftest.err'
52dbaac8
PE
17024 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17025 (eval $ac_try) 2>&5
17026 ac_status=$?
17027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17028 (exit $ac_status); }; } &&
17029 { ac_try='test -s conftest.$ac_objext'
17030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17031 (eval $ac_try) 2>&5
17032 ac_status=$?
17033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17034 (exit $ac_status); }; }; then
17035 ac_header_compiler=yes
17036else
17037 echo "$as_me: failed program was:" >&5
17038sed 's/^/| /' conftest.$ac_ext >&5
17039
17040ac_header_compiler=no
17041fi
17042rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17043echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17044echo "${ECHO_T}$ac_header_compiler" >&6
17045
17046# Is the header present?
17047echo "$as_me:$LINENO: checking $ac_header presence" >&5
17048echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17049cat >conftest.$ac_ext <<_ACEOF
17050/* confdefs.h. */
17051_ACEOF
17052cat confdefs.h >>conftest.$ac_ext
17053cat >>conftest.$ac_ext <<_ACEOF
17054/* end confdefs.h. */
17055#include <$ac_header>
17056_ACEOF
17057if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17058 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17059 ac_status=$?
17060 grep -v '^ *+' conftest.er1 >conftest.err
17061 rm -f conftest.er1
17062 cat conftest.err >&5
17063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17064 (exit $ac_status); } >/dev/null; then
17065 if test -s conftest.err; then
17066 ac_cpp_err=$ac_c_preproc_warn_flag
17067 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
17068 else
17069 ac_cpp_err=
17070 fi
17071else
17072 ac_cpp_err=yes
17073fi
17074if test -z "$ac_cpp_err"; then
17075 ac_header_preproc=yes
17076else
17077 echo "$as_me: failed program was:" >&5
17078sed 's/^/| /' conftest.$ac_ext >&5
17079
17080 ac_header_preproc=no
17081fi
17082rm -f conftest.err conftest.$ac_ext
17083echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17084echo "${ECHO_T}$ac_header_preproc" >&6
17085
17086# So? What about this header?
17087case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
17088 yes:no: )
17089 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17090echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17091 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
17092echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
17093 ac_header_preproc=yes
17094 ;;
17095 no:yes:* )
17096 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17097echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17098 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17099echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17100 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
17101echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
17102 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
17103echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
17104 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17105echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17106 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
17107echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
17108 (
17109 cat <<\_ASBOX
17110## ------------------------------------------ ##
17111## Report this to the AC_PACKAGE_NAME lists. ##
17112## ------------------------------------------ ##
17113_ASBOX
17114 ) |
17115 sed "s/^/$as_me: WARNING: /" >&2
17116 ;;
17117esac
17118echo "$as_me:$LINENO: checking for $ac_header" >&5
17119echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17120if eval "test \"\${$as_ac_Header+set}\" = set"; then
17121 echo $ECHO_N "(cached) $ECHO_C" >&6
17122else
17123 eval "$as_ac_Header=\$ac_header_preproc"
17124fi
17125echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17126echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17127
17128fi
17129if test `eval echo '${'$as_ac_Header'}'` = yes; then
17130 cat >>confdefs.h <<_ACEOF
17131#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17132_ACEOF
17133
17134else
17135 GETOPT_H=getopt.h
17136fi
17137
17138done
17139
17140 if test -z "$GETOPT_H"; then
17141
17142for ac_func in getopt_long_only
17143do
17144as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17145echo "$as_me:$LINENO: checking for $ac_func" >&5
17146echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17147if eval "test \"\${$as_ac_var+set}\" = set"; then
17148 echo $ECHO_N "(cached) $ECHO_C" >&6
17149else
17150 cat >conftest.$ac_ext <<_ACEOF
17151/* confdefs.h. */
17152_ACEOF
17153cat confdefs.h >>conftest.$ac_ext
17154cat >>conftest.$ac_ext <<_ACEOF
17155/* end confdefs.h. */
17156/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17157 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17158#define $ac_func innocuous_$ac_func
17159
17160/* System header to define __stub macros and hopefully few prototypes,
17161 which can conflict with char $ac_func (); below.
17162 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17163 <limits.h> exists even on freestanding compilers. */
17164
17165#ifdef __STDC__
17166# include <limits.h>
17167#else
17168# include <assert.h>
17169#endif
17170
17171#undef $ac_func
17172
17173/* Override any gcc2 internal prototype to avoid an error. */
17174#ifdef __cplusplus
17175extern "C"
17176{
17177#endif
17178/* We use char because int might match the return type of a gcc2
17179 builtin and then its argument prototype would still apply. */
17180char $ac_func ();
17181/* The GNU C library defines this for functions which it implements
17182 to always fail with ENOSYS. Some functions are actually named
17183 something starting with __ and the normal name is an alias. */
17184#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17185choke me
17186#else
17187char (*f) () = $ac_func;
17188#endif
17189#ifdef __cplusplus
17190}
17191#endif
17192
17193int
17194main ()
17195{
17196return f != $ac_func;
17197 ;
17198 return 0;
17199}
17200_ACEOF
17201rm -f conftest.$ac_objext conftest$ac_exeext
17202if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17203 (eval $ac_link) 2>conftest.er1
17204 ac_status=$?
17205 grep -v '^ *+' conftest.er1 >conftest.err
17206 rm -f conftest.er1
17207 cat conftest.err >&5
17208 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17209 (exit $ac_status); } &&
10a3b1a1
EZ
17210 { ac_try='test -z "$ac_c_werror_flag"
17211 || test ! -s conftest.err'
52dbaac8
PE
17212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17213 (eval $ac_try) 2>&5
17214 ac_status=$?
17215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17216 (exit $ac_status); }; } &&
17217 { ac_try='test -s conftest$ac_exeext'
17218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17219 (eval $ac_try) 2>&5
17220 ac_status=$?
17221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17222 (exit $ac_status); }; }; then
17223 eval "$as_ac_var=yes"
17224else
17225 echo "$as_me: failed program was:" >&5
17226sed 's/^/| /' conftest.$ac_ext >&5
17227
17228eval "$as_ac_var=no"
17229fi
17230rm -f conftest.err conftest.$ac_objext \
17231 conftest$ac_exeext conftest.$ac_ext
17232fi
17233echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
17234echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17235if test `eval echo '${'$as_ac_var'}'` = yes; then
17236 cat >>confdefs.h <<_ACEOF
17237#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17238_ACEOF
17239
17240else
17241 GETOPT_H=getopt.h
17242fi
17243done
17244
17245 fi
17246
17247 if test -z "$GETOPT_H"; then
17248 echo "$as_me:$LINENO: checking whether optreset is declared" >&5
17249echo $ECHO_N "checking whether optreset is declared... $ECHO_C" >&6
17250if test "${ac_cv_have_decl_optreset+set}" = set; then
17251 echo $ECHO_N "(cached) $ECHO_C" >&6
17252else
17253 cat >conftest.$ac_ext <<_ACEOF
17254/* confdefs.h. */
17255_ACEOF
17256cat confdefs.h >>conftest.$ac_ext
17257cat >>conftest.$ac_ext <<_ACEOF
17258/* end confdefs.h. */
17259#include <getopt.h>
17260
17261int
17262main ()
17263{
17264#ifndef optreset
17265 char *p = (char *) optreset;
17266#endif
17267
17268 ;
17269 return 0;
17270}
17271_ACEOF
17272rm -f conftest.$ac_objext
17273if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17274 (eval $ac_compile) 2>conftest.er1
17275 ac_status=$?
17276 grep -v '^ *+' conftest.er1 >conftest.err
17277 rm -f conftest.er1
17278 cat conftest.err >&5
17279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17280 (exit $ac_status); } &&
10a3b1a1
EZ
17281 { ac_try='test -z "$ac_c_werror_flag"
17282 || test ! -s conftest.err'
52dbaac8
PE
17283 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17284 (eval $ac_try) 2>&5
17285 ac_status=$?
17286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17287 (exit $ac_status); }; } &&
17288 { ac_try='test -s conftest.$ac_objext'
17289 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17290 (eval $ac_try) 2>&5
17291 ac_status=$?
17292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17293 (exit $ac_status); }; }; then
17294 ac_cv_have_decl_optreset=yes
17295else
17296 echo "$as_me: failed program was:" >&5
17297sed 's/^/| /' conftest.$ac_ext >&5
17298
17299ac_cv_have_decl_optreset=no
17300fi
17301rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17302fi
17303echo "$as_me:$LINENO: result: $ac_cv_have_decl_optreset" >&5
17304echo "${ECHO_T}$ac_cv_have_decl_optreset" >&6
17305if test $ac_cv_have_decl_optreset = yes; then
17306 GETOPT_H=getopt.h
17307fi
17308
17309 fi
17310
17311 if test -z "$GETOPT_H"; then
17312 echo "$as_me:$LINENO: checking for working GNU getopt function" >&5
17313echo $ECHO_N "checking for working GNU getopt function... $ECHO_C" >&6
17314if test "${gl_cv_func_gnu_getopt+set}" = set; then
17315 echo $ECHO_N "(cached) $ECHO_C" >&6
17316else
17317 if test "$cross_compiling" = yes; then
17318 echo "$as_me:$LINENO: checking whether getopt_clip is declared" >&5
17319echo $ECHO_N "checking whether getopt_clip is declared... $ECHO_C" >&6
17320if test "${ac_cv_have_decl_getopt_clip+set}" = set; then
17321 echo $ECHO_N "(cached) $ECHO_C" >&6
17322else
17323 cat >conftest.$ac_ext <<_ACEOF
17324/* confdefs.h. */
17325_ACEOF
17326cat confdefs.h >>conftest.$ac_ext
17327cat >>conftest.$ac_ext <<_ACEOF
17328/* end confdefs.h. */
17329#include <getopt.h>
17330
17331int
17332main ()
17333{
17334#ifndef getopt_clip
17335 char *p = (char *) getopt_clip;
17336#endif
17337
17338 ;
17339 return 0;
17340}
17341_ACEOF
17342rm -f conftest.$ac_objext
17343if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17344 (eval $ac_compile) 2>conftest.er1
17345 ac_status=$?
17346 grep -v '^ *+' conftest.er1 >conftest.err
17347 rm -f conftest.er1
17348 cat conftest.err >&5
17349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17350 (exit $ac_status); } &&
10a3b1a1
EZ
17351 { ac_try='test -z "$ac_c_werror_flag"
17352 || test ! -s conftest.err'
52dbaac8
PE
17353 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17354 (eval $ac_try) 2>&5
17355 ac_status=$?
17356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17357 (exit $ac_status); }; } &&
17358 { ac_try='test -s conftest.$ac_objext'
17359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17360 (eval $ac_try) 2>&5
17361 ac_status=$?
17362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17363 (exit $ac_status); }; }; then
17364 ac_cv_have_decl_getopt_clip=yes
17365else
17366 echo "$as_me: failed program was:" >&5
17367sed 's/^/| /' conftest.$ac_ext >&5
17368
17369ac_cv_have_decl_getopt_clip=no
17370fi
17371rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17372fi
17373echo "$as_me:$LINENO: result: $ac_cv_have_decl_getopt_clip" >&5
17374echo "${ECHO_T}$ac_cv_have_decl_getopt_clip" >&6
17375if test $ac_cv_have_decl_getopt_clip = yes; then
17376 gl_cv_func_gnu_getopt=no
17377else
17378 gl_cv_func_gnu_getopt=yes
17379fi
17380
17381else
17382 cat >conftest.$ac_ext <<_ACEOF
17383/* confdefs.h. */
17384_ACEOF
17385cat confdefs.h >>conftest.$ac_ext
17386cat >>conftest.$ac_ext <<_ACEOF
17387/* end confdefs.h. */
17388#include <getopt.h>
17389int
17390main ()
17391{
17392
17393 char *myargv[3];
17394 myargv[0] = "conftest";
17395 myargv[1] = "-+";
17396 myargv[2] = 0;
17397 return getopt (2, myargv, "+a") != '?';
17398
17399 ;
17400 return 0;
17401}
17402_ACEOF
17403rm -f conftest$ac_exeext
17404if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17405 (eval $ac_link) 2>&5
17406 ac_status=$?
17407 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17408 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17409 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17410 (eval $ac_try) 2>&5
17411 ac_status=$?
17412 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17413 (exit $ac_status); }; }; then
17414 gl_cv_func_gnu_getopt=yes
17415else
17416 echo "$as_me: program exited with status $ac_status" >&5
17417echo "$as_me: failed program was:" >&5
17418sed 's/^/| /' conftest.$ac_ext >&5
17419
17420( exit $ac_status )
17421gl_cv_func_gnu_getopt=no
17422fi
17423rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17424fi
17425fi
17426echo "$as_me:$LINENO: result: $gl_cv_func_gnu_getopt" >&5
17427echo "${ECHO_T}$gl_cv_func_gnu_getopt" >&6
17428 if test "$gl_cv_func_gnu_getopt" = "no"; then
17429 GETOPT_H=getopt.h
17430 fi
17431 fi
17432
17433
17434
17435 if test -n "$GETOPT_H"; then
17436
17437
17438 GETOPT_H=getopt.h
17439
17440cat >>confdefs.h <<\_ACEOF
17441#define __GETOPT_PREFIX rpl_
17442_ACEOF
17443
17444
17445
17446 :
17447 GETOPTOBJS='getopt.o getopt1.o'
17448
17449fi
17450
17451
17452
17453
cd958eb3
MB
17454echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
17455echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
17456if test "${ac_cv_func_getpgrp_void+set}" = set; then
17457 echo $ECHO_N "(cached) $ECHO_C" >&6
17458else
17459 # Use it with a single arg.
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. */
cd958eb3
MB
17466$ac_includes_default
17467int
17468main ()
17469{
17470getpgrp (0);
17471 ;
17472 return 0;
17473}
17474_ACEOF
17475rm -f conftest.$ac_objext
17476if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 17477 (eval $ac_compile) 2>conftest.er1
cd958eb3 17478 ac_status=$?
edfaf76d
LK
17479 grep -v '^ *+' conftest.er1 >conftest.err
17480 rm -f conftest.er1
17481 cat conftest.err >&5
cd958eb3
MB
17482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17483 (exit $ac_status); } &&
10a3b1a1
EZ
17484 { ac_try='test -z "$ac_c_werror_flag"
17485 || test ! -s conftest.err'
edfaf76d
LK
17486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17487 (eval $ac_try) 2>&5
17488 ac_status=$?
17489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17490 (exit $ac_status); }; } &&
17491 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
17492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17493 (eval $ac_try) 2>&5
17494 ac_status=$?
17495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17496 (exit $ac_status); }; }; then
17497 ac_cv_func_getpgrp_void=no
17498else
17499 echo "$as_me: failed program was:" >&5
19650fd6
AS
17500sed 's/^/| /' conftest.$ac_ext >&5
17501
cd958eb3
MB
17502ac_cv_func_getpgrp_void=yes
17503fi
edfaf76d 17504rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
17505
17506fi
17507echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
17508echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
17509if test $ac_cv_func_getpgrp_void = yes; then
17510
17511cat >>confdefs.h <<\_ACEOF
17512#define GETPGRP_VOID 1
17513_ACEOF
17514
17515fi
17516
17517
973a76b1
DL
17518
17519for ac_func in strftime
17520do
17521as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17522echo "$as_me:$LINENO: checking for $ac_func" >&5
17523echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17524if eval "test \"\${$as_ac_var+set}\" = set"; then
17525 echo $ECHO_N "(cached) $ECHO_C" >&6
17526else
17527 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17528/* confdefs.h. */
17529_ACEOF
17530cat confdefs.h >>conftest.$ac_ext
17531cat >>conftest.$ac_ext <<_ACEOF
17532/* end confdefs.h. */
edfaf76d
LK
17533/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17534 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17535#define $ac_func innocuous_$ac_func
17536
973a76b1 17537/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
17538 which can conflict with char $ac_func (); below.
17539 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17540 <limits.h> exists even on freestanding compilers. */
edfaf76d 17541
19650fd6
AS
17542#ifdef __STDC__
17543# include <limits.h>
17544#else
17545# include <assert.h>
17546#endif
edfaf76d
LK
17547
17548#undef $ac_func
17549
973a76b1
DL
17550/* Override any gcc2 internal prototype to avoid an error. */
17551#ifdef __cplusplus
17552extern "C"
19650fd6 17553{
973a76b1
DL
17554#endif
17555/* We use char because int might match the return type of a gcc2
17556 builtin and then its argument prototype would still apply. */
17557char $ac_func ();
17558/* The GNU C library defines this for functions which it implements
17559 to always fail with ENOSYS. Some functions are actually named
17560 something starting with __ and the normal name is an alias. */
17561#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17562choke me
17563#else
19650fd6
AS
17564char (*f) () = $ac_func;
17565#endif
17566#ifdef __cplusplus
17567}
973a76b1
DL
17568#endif
17569
19650fd6
AS
17570int
17571main ()
17572{
17573return f != $ac_func;
973a76b1
DL
17574 ;
17575 return 0;
17576}
17577_ACEOF
17578rm -f conftest.$ac_objext conftest$ac_exeext
17579if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 17580 (eval $ac_link) 2>conftest.er1
973a76b1 17581 ac_status=$?
edfaf76d
LK
17582 grep -v '^ *+' conftest.er1 >conftest.err
17583 rm -f conftest.er1
17584 cat conftest.err >&5
973a76b1
DL
17585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17586 (exit $ac_status); } &&
10a3b1a1
EZ
17587 { ac_try='test -z "$ac_c_werror_flag"
17588 || test ! -s conftest.err'
edfaf76d
LK
17589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17590 (eval $ac_try) 2>&5
17591 ac_status=$?
17592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17593 (exit $ac_status); }; } &&
17594 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
17595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17596 (eval $ac_try) 2>&5
17597 ac_status=$?
17598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17599 (exit $ac_status); }; }; then
17600 eval "$as_ac_var=yes"
17601else
17602 echo "$as_me: failed program was:" >&5
19650fd6
AS
17603sed 's/^/| /' conftest.$ac_ext >&5
17604
973a76b1
DL
17605eval "$as_ac_var=no"
17606fi
edfaf76d
LK
17607rm -f conftest.err conftest.$ac_objext \
17608 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
17609fi
17610echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
17611echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17612if test `eval echo '${'$as_ac_var'}'` = yes; then
17613 cat >>confdefs.h <<_ACEOF
17614#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17615_ACEOF
17616
17617else
17618 # strftime is in -lintl on SCO UNIX.
17619echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
17620echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
17621if test "${ac_cv_lib_intl_strftime+set}" = set; then
17622 echo $ECHO_N "(cached) $ECHO_C" >&6
17623else
17624 ac_check_lib_save_LIBS=$LIBS
17625LIBS="-lintl $LIBS"
17626cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17627/* confdefs.h. */
17628_ACEOF
17629cat confdefs.h >>conftest.$ac_ext
17630cat >>conftest.$ac_ext <<_ACEOF
17631/* end confdefs.h. */
973a76b1
DL
17632
17633/* Override any gcc2 internal prototype to avoid an error. */
17634#ifdef __cplusplus
17635extern "C"
17636#endif
17637/* We use char because int might match the return type of a gcc2
17638 builtin and then its argument prototype would still apply. */
17639char strftime ();
17640int
17641main ()
17642{
17643strftime ();
17644 ;
17645 return 0;
17646}
17647_ACEOF
17648rm -f conftest.$ac_objext conftest$ac_exeext
17649if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 17650 (eval $ac_link) 2>conftest.er1
973a76b1 17651 ac_status=$?
edfaf76d
LK
17652 grep -v '^ *+' conftest.er1 >conftest.err
17653 rm -f conftest.er1
17654 cat conftest.err >&5
973a76b1
DL
17655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17656 (exit $ac_status); } &&
10a3b1a1
EZ
17657 { ac_try='test -z "$ac_c_werror_flag"
17658 || test ! -s conftest.err'
edfaf76d
LK
17659 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17660 (eval $ac_try) 2>&5
17661 ac_status=$?
17662 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17663 (exit $ac_status); }; } &&
17664 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
17665 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17666 (eval $ac_try) 2>&5
17667 ac_status=$?
17668 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17669 (exit $ac_status); }; }; then
17670 ac_cv_lib_intl_strftime=yes
17671else
17672 echo "$as_me: failed program was:" >&5
19650fd6
AS
17673sed 's/^/| /' conftest.$ac_ext >&5
17674
973a76b1
DL
17675ac_cv_lib_intl_strftime=no
17676fi
edfaf76d
LK
17677rm -f conftest.err conftest.$ac_objext \
17678 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
17679LIBS=$ac_check_lib_save_LIBS
17680fi
17681echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
17682echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
17683if test $ac_cv_lib_intl_strftime = yes; then
17684 cat >>confdefs.h <<\_ACEOF
17685#define HAVE_STRFTIME 1
17686_ACEOF
17687
17688LIBS="-lintl $LIBS"
17689fi
17690
17691fi
17692done
17693
17694
b936fae4
AS
17695# UNIX98 PTYs.
17696
17697for ac_func in grantpt
503d2be0
AS
17698do
17699as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 17700echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
17701echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17702if eval "test \"\${$as_ac_var+set}\" = set"; then
17703 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 17704else
503d2be0 17705 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17706/* confdefs.h. */
17707_ACEOF
17708cat confdefs.h >>conftest.$ac_ext
17709cat >>conftest.$ac_ext <<_ACEOF
17710/* end confdefs.h. */
edfaf76d
LK
17711/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17712 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17713#define $ac_func innocuous_$ac_func
17714
503d2be0 17715/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
17716 which can conflict with char $ac_func (); below.
17717 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17718 <limits.h> exists even on freestanding compilers. */
edfaf76d 17719
19650fd6
AS
17720#ifdef __STDC__
17721# include <limits.h>
17722#else
17723# include <assert.h>
17724#endif
edfaf76d
LK
17725
17726#undef $ac_func
17727
4c343001 17728/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17729#ifdef __cplusplus
17730extern "C"
19650fd6 17731{
503d2be0 17732#endif
4c343001 17733/* We use char because int might match the return type of a gcc2
503d2be0
AS
17734 builtin and then its argument prototype would still apply. */
17735char $ac_func ();
503d2be0
AS
17736/* The GNU C library defines this for functions which it implements
17737 to always fail with ENOSYS. Some functions are actually named
17738 something starting with __ and the normal name is an alias. */
17739#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17740choke me
17741#else
19650fd6
AS
17742char (*f) () = $ac_func;
17743#endif
17744#ifdef __cplusplus
17745}
503d2be0 17746#endif
4c343001 17747
19650fd6
AS
17748int
17749main ()
17750{
17751return f != $ac_func;
503d2be0
AS
17752 ;
17753 return 0;
17754}
17755_ACEOF
17756rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17757if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 17758 (eval $ac_link) 2>conftest.er1
503d2be0 17759 ac_status=$?
edfaf76d
LK
17760 grep -v '^ *+' conftest.er1 >conftest.err
17761 rm -f conftest.er1
17762 cat conftest.err >&5
c0d27fcc 17763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17764 (exit $ac_status); } &&
10a3b1a1
EZ
17765 { ac_try='test -z "$ac_c_werror_flag"
17766 || test ! -s conftest.err'
edfaf76d
LK
17767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17768 (eval $ac_try) 2>&5
17769 ac_status=$?
17770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17771 (exit $ac_status); }; } &&
17772 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17774 (eval $ac_try) 2>&5
17775 ac_status=$?
c0d27fcc 17776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17777 (exit $ac_status); }; }; then
17778 eval "$as_ac_var=yes"
17779else
17780 echo "$as_me: failed program was:" >&5
19650fd6
AS
17781sed 's/^/| /' conftest.$ac_ext >&5
17782
503d2be0
AS
17783eval "$as_ac_var=no"
17784fi
edfaf76d
LK
17785rm -f conftest.err conftest.$ac_objext \
17786 conftest$ac_exeext conftest.$ac_ext
503d2be0 17787fi
c0d27fcc 17788echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
17789echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17790if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 17791 cat >>confdefs.h <<_ACEOF
503d2be0 17792#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 17793_ACEOF
4c343001
DL
17794
17795fi
503d2be0
AS
17796done
17797
c0d27fcc 17798
b936fae4 17799# PTY-related GNU extensions.
4c343001 17800
b936fae4
AS
17801for ac_func in getpt
17802do
17803as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 17804echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
17805echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17806if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 17807 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 17808else
b936fae4 17809 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17810/* confdefs.h. */
17811_ACEOF
17812cat confdefs.h >>conftest.$ac_ext
17813cat >>conftest.$ac_ext <<_ACEOF
17814/* end confdefs.h. */
edfaf76d
LK
17815/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17816 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17817#define $ac_func innocuous_$ac_func
17818
087121cc 17819/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
17820 which can conflict with char $ac_func (); below.
17821 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17822 <limits.h> exists even on freestanding compilers. */
edfaf76d 17823
19650fd6
AS
17824#ifdef __STDC__
17825# include <limits.h>
17826#else
17827# include <assert.h>
17828#endif
edfaf76d
LK
17829
17830#undef $ac_func
17831
087121cc 17832/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17833#ifdef __cplusplus
17834extern "C"
19650fd6 17835{
503d2be0 17836#endif
087121cc 17837/* We use char because int might match the return type of a gcc2
503d2be0
AS
17838 builtin and then its argument prototype would still apply. */
17839char $ac_func ();
087121cc
GM
17840/* The GNU C library defines this for functions which it implements
17841 to always fail with ENOSYS. Some functions are actually named
17842 something starting with __ and the normal name is an alias. */
17843#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17844choke me
17845#else
19650fd6
AS
17846char (*f) () = $ac_func;
17847#endif
17848#ifdef __cplusplus
17849}
087121cc
GM
17850#endif
17851
19650fd6
AS
17852int
17853main ()
17854{
17855return f != $ac_func;
503d2be0
AS
17856 ;
17857 return 0;
17858}
17859_ACEOF
17860rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17861if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 17862 (eval $ac_link) 2>conftest.er1
503d2be0 17863 ac_status=$?
edfaf76d
LK
17864 grep -v '^ *+' conftest.er1 >conftest.err
17865 rm -f conftest.er1
17866 cat conftest.err >&5
c0d27fcc 17867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17868 (exit $ac_status); } &&
10a3b1a1
EZ
17869 { ac_try='test -z "$ac_c_werror_flag"
17870 || test ! -s conftest.err'
edfaf76d
LK
17871 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17872 (eval $ac_try) 2>&5
17873 ac_status=$?
17874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17875 (exit $ac_status); }; } &&
17876 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17877 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17878 (eval $ac_try) 2>&5
17879 ac_status=$?
c0d27fcc 17880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17881 (exit $ac_status); }; }; then
17882 eval "$as_ac_var=yes"
17883else
17884 echo "$as_me: failed program was:" >&5
19650fd6
AS
17885sed 's/^/| /' conftest.$ac_ext >&5
17886
503d2be0
AS
17887eval "$as_ac_var=no"
17888fi
edfaf76d
LK
17889rm -f conftest.err conftest.$ac_objext \
17890 conftest$ac_exeext conftest.$ac_ext
503d2be0 17891fi
c0d27fcc 17892echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
17893echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17894if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 17895 cat >>confdefs.h <<_ACEOF
503d2be0 17896#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 17897_ACEOF
087121cc 17898
087121cc
GM
17899fi
17900done
17901
c0d27fcc 17902
ba4481b5
DL
17903# Check this now, so that we will NOT find the above functions in ncurses.
17904# That is because we have not set up to link ncurses in lib-src.
17905# It's better to believe a function is not available
17906# than to expect to find it in ncurses.
503d2be0 17907
c0d27fcc 17908echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
17909echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
17910if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
17911 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 17912else
503d2be0 17913 ac_check_lib_save_LIBS=$LIBS
ba4481b5 17914LIBS="-lncurses $LIBS"
503d2be0 17915cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17916/* confdefs.h. */
17917_ACEOF
17918cat confdefs.h >>conftest.$ac_ext
17919cat >>conftest.$ac_ext <<_ACEOF
17920/* end confdefs.h. */
503d2be0 17921
ba4481b5 17922/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17923#ifdef __cplusplus
17924extern "C"
17925#endif
ba4481b5 17926/* We use char because int might match the return type of a gcc2
503d2be0
AS
17927 builtin and then its argument prototype would still apply. */
17928char tparm ();
17929int
17930main ()
17931{
17932tparm ();
17933 ;
17934 return 0;
17935}
17936_ACEOF
17937rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17938if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 17939 (eval $ac_link) 2>conftest.er1
503d2be0 17940 ac_status=$?
edfaf76d
LK
17941 grep -v '^ *+' conftest.er1 >conftest.err
17942 rm -f conftest.er1
17943 cat conftest.err >&5
c0d27fcc 17944 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17945 (exit $ac_status); } &&
10a3b1a1
EZ
17946 { ac_try='test -z "$ac_c_werror_flag"
17947 || test ! -s conftest.err'
edfaf76d
LK
17948 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17949 (eval $ac_try) 2>&5
17950 ac_status=$?
17951 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17952 (exit $ac_status); }; } &&
17953 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17954 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17955 (eval $ac_try) 2>&5
17956 ac_status=$?
c0d27fcc 17957 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17958 (exit $ac_status); }; }; then
17959 ac_cv_lib_ncurses_tparm=yes
17960else
17961 echo "$as_me: failed program was:" >&5
19650fd6
AS
17962sed 's/^/| /' conftest.$ac_ext >&5
17963
503d2be0
AS
17964ac_cv_lib_ncurses_tparm=no
17965fi
edfaf76d
LK
17966rm -f conftest.err conftest.$ac_objext \
17967 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17968LIBS=$ac_check_lib_save_LIBS
17969fi
c0d27fcc 17970echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
17971echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
17972if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 17973 cat >>confdefs.h <<_ACEOF
503d2be0 17974#define HAVE_LIBNCURSES 1
c0d27fcc 17975_ACEOF
ba4481b5
DL
17976
17977 LIBS="-lncurses $LIBS"
17978
ba4481b5
DL
17979fi
17980
c0d27fcc 17981
84e70f78
KR
17982# Do we need the Hesiod library to provide the support routines?
17983if test "$with_hesiod" = yes ; then
17984 # Don't set $LIBS here -- see comments above.
17985 resolv=no
c0d27fcc 17986 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
17987echo $ECHO_N "checking for res_send... $ECHO_C" >&6
17988if test "${ac_cv_func_res_send+set}" = set; then
17989 echo $ECHO_N "(cached) $ECHO_C" >&6
17990else
17991 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17992/* confdefs.h. */
17993_ACEOF
17994cat confdefs.h >>conftest.$ac_ext
17995cat >>conftest.$ac_ext <<_ACEOF
17996/* end confdefs.h. */
edfaf76d
LK
17997/* Define res_send to an innocuous variant, in case <limits.h> declares res_send.
17998 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17999#define res_send innocuous_res_send
18000
84e70f78 18001/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
18002 which can conflict with char res_send (); below.
18003 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18004 <limits.h> exists even on freestanding compilers. */
edfaf76d 18005
19650fd6
AS
18006#ifdef __STDC__
18007# include <limits.h>
18008#else
18009# include <assert.h>
18010#endif
edfaf76d
LK
18011
18012#undef res_send
18013
84e70f78
KR
18014/* Override any gcc2 internal prototype to avoid an error. */
18015#ifdef __cplusplus
18016extern "C"
19650fd6 18017{
84e70f78
KR
18018#endif
18019/* We use char because int might match the return type of a gcc2
18020 builtin and then its argument prototype would still apply. */
18021char res_send ();
84e70f78
KR
18022/* The GNU C library defines this for functions which it implements
18023 to always fail with ENOSYS. Some functions are actually named
18024 something starting with __ and the normal name is an alias. */
18025#if defined (__stub_res_send) || defined (__stub___res_send)
18026choke me
18027#else
19650fd6
AS
18028char (*f) () = res_send;
18029#endif
18030#ifdef __cplusplus
18031}
cd958eb3
MB
18032#endif
18033
19650fd6
AS
18034int
18035main ()
18036{
18037return f != res_send;
84e70f78
KR
18038 ;
18039 return 0;
18040}
18041_ACEOF
18042rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18043if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18044 (eval $ac_link) 2>conftest.er1
84e70f78 18045 ac_status=$?
edfaf76d
LK
18046 grep -v '^ *+' conftest.er1 >conftest.err
18047 rm -f conftest.er1
18048 cat conftest.err >&5
c0d27fcc 18049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18050 (exit $ac_status); } &&
10a3b1a1
EZ
18051 { ac_try='test -z "$ac_c_werror_flag"
18052 || test ! -s conftest.err'
edfaf76d
LK
18053 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18054 (eval $ac_try) 2>&5
18055 ac_status=$?
18056 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18057 (exit $ac_status); }; } &&
18058 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18059 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18060 (eval $ac_try) 2>&5
18061 ac_status=$?
c0d27fcc 18062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18063 (exit $ac_status); }; }; then
18064 ac_cv_func_res_send=yes
18065else
18066 echo "$as_me: failed program was:" >&5
19650fd6
AS
18067sed 's/^/| /' conftest.$ac_ext >&5
18068
84e70f78
KR
18069ac_cv_func_res_send=no
18070fi
edfaf76d
LK
18071rm -f conftest.err conftest.$ac_objext \
18072 conftest$ac_exeext conftest.$ac_ext
84e70f78 18073fi
c0d27fcc 18074echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
18075echo "${ECHO_T}$ac_cv_func_res_send" >&6
18076if test $ac_cv_func_res_send = yes; then
18077 :
18078else
c0d27fcc 18079 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
18080echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
18081if test "${ac_cv_func___res_send+set}" = set; then
18082 echo $ECHO_N "(cached) $ECHO_C" >&6
18083else
18084 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18085/* confdefs.h. */
18086_ACEOF
18087cat confdefs.h >>conftest.$ac_ext
18088cat >>conftest.$ac_ext <<_ACEOF
18089/* end confdefs.h. */
edfaf76d
LK
18090/* Define __res_send to an innocuous variant, in case <limits.h> declares __res_send.
18091 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18092#define __res_send innocuous___res_send
18093
84e70f78 18094/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
18095 which can conflict with char __res_send (); below.
18096 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18097 <limits.h> exists even on freestanding compilers. */
edfaf76d 18098
19650fd6
AS
18099#ifdef __STDC__
18100# include <limits.h>
18101#else
18102# include <assert.h>
18103#endif
edfaf76d
LK
18104
18105#undef __res_send
18106
84e70f78
KR
18107/* Override any gcc2 internal prototype to avoid an error. */
18108#ifdef __cplusplus
18109extern "C"
19650fd6 18110{
84e70f78
KR
18111#endif
18112/* We use char because int might match the return type of a gcc2
18113 builtin and then its argument prototype would still apply. */
18114char __res_send ();
84e70f78
KR
18115/* The GNU C library defines this for functions which it implements
18116 to always fail with ENOSYS. Some functions are actually named
18117 something starting with __ and the normal name is an alias. */
18118#if defined (__stub___res_send) || defined (__stub_____res_send)
18119choke me
18120#else
19650fd6
AS
18121char (*f) () = __res_send;
18122#endif
18123#ifdef __cplusplus
18124}
84e70f78
KR
18125#endif
18126
19650fd6
AS
18127int
18128main ()
18129{
18130return f != __res_send;
84e70f78
KR
18131 ;
18132 return 0;
18133}
18134_ACEOF
18135rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18136if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18137 (eval $ac_link) 2>conftest.er1
84e70f78 18138 ac_status=$?
edfaf76d
LK
18139 grep -v '^ *+' conftest.er1 >conftest.err
18140 rm -f conftest.er1
18141 cat conftest.err >&5
c0d27fcc 18142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18143 (exit $ac_status); } &&
10a3b1a1
EZ
18144 { ac_try='test -z "$ac_c_werror_flag"
18145 || test ! -s conftest.err'
edfaf76d
LK
18146 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18147 (eval $ac_try) 2>&5
18148 ac_status=$?
18149 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18150 (exit $ac_status); }; } &&
18151 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18152 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18153 (eval $ac_try) 2>&5
18154 ac_status=$?
c0d27fcc 18155 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18156 (exit $ac_status); }; }; then
18157 ac_cv_func___res_send=yes
18158else
18159 echo "$as_me: failed program was:" >&5
19650fd6
AS
18160sed 's/^/| /' conftest.$ac_ext >&5
18161
84e70f78
KR
18162ac_cv_func___res_send=no
18163fi
edfaf76d
LK
18164rm -f conftest.err conftest.$ac_objext \
18165 conftest$ac_exeext conftest.$ac_ext
84e70f78 18166fi
c0d27fcc 18167echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
18168echo "${ECHO_T}$ac_cv_func___res_send" >&6
18169if test $ac_cv_func___res_send = yes; then
18170 :
18171else
c0d27fcc 18172 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
18173echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
18174if test "${ac_cv_lib_resolv_res_send+set}" = set; then
18175 echo $ECHO_N "(cached) $ECHO_C" >&6
18176else
18177 ac_check_lib_save_LIBS=$LIBS
18178LIBS="-lresolv $LIBS"
18179cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18180/* confdefs.h. */
18181_ACEOF
18182cat confdefs.h >>conftest.$ac_ext
18183cat >>conftest.$ac_ext <<_ACEOF
18184/* end confdefs.h. */
84e70f78
KR
18185
18186/* Override any gcc2 internal prototype to avoid an error. */
18187#ifdef __cplusplus
18188extern "C"
18189#endif
18190/* We use char because int might match the return type of a gcc2
18191 builtin and then its argument prototype would still apply. */
18192char res_send ();
18193int
18194main ()
18195{
18196res_send ();
18197 ;
18198 return 0;
18199}
18200_ACEOF
18201rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18202if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18203 (eval $ac_link) 2>conftest.er1
84e70f78 18204 ac_status=$?
edfaf76d
LK
18205 grep -v '^ *+' conftest.er1 >conftest.err
18206 rm -f conftest.er1
18207 cat conftest.err >&5
c0d27fcc 18208 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18209 (exit $ac_status); } &&
10a3b1a1
EZ
18210 { ac_try='test -z "$ac_c_werror_flag"
18211 || test ! -s conftest.err'
edfaf76d
LK
18212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18213 (eval $ac_try) 2>&5
18214 ac_status=$?
18215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18216 (exit $ac_status); }; } &&
18217 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18219 (eval $ac_try) 2>&5
18220 ac_status=$?
c0d27fcc 18221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18222 (exit $ac_status); }; }; then
18223 ac_cv_lib_resolv_res_send=yes
18224else
18225 echo "$as_me: failed program was:" >&5
19650fd6
AS
18226sed 's/^/| /' conftest.$ac_ext >&5
18227
84e70f78
KR
18228ac_cv_lib_resolv_res_send=no
18229fi
edfaf76d
LK
18230rm -f conftest.err conftest.$ac_objext \
18231 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
18232LIBS=$ac_check_lib_save_LIBS
18233fi
c0d27fcc 18234echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
18235echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
18236if test $ac_cv_lib_resolv_res_send = yes; then
18237 resolv=yes
18238else
c0d27fcc 18239 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
18240echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
18241if test "${ac_cv_lib_resolv___res_send+set}" = set; then
18242 echo $ECHO_N "(cached) $ECHO_C" >&6
18243else
18244 ac_check_lib_save_LIBS=$LIBS
18245LIBS="-lresolv $LIBS"
18246cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18247/* confdefs.h. */
18248_ACEOF
18249cat confdefs.h >>conftest.$ac_ext
18250cat >>conftest.$ac_ext <<_ACEOF
18251/* end confdefs.h. */
84e70f78
KR
18252
18253/* Override any gcc2 internal prototype to avoid an error. */
18254#ifdef __cplusplus
18255extern "C"
18256#endif
18257/* We use char because int might match the return type of a gcc2
18258 builtin and then its argument prototype would still apply. */
18259char __res_send ();
18260int
18261main ()
18262{
18263__res_send ();
18264 ;
18265 return 0;
18266}
18267_ACEOF
18268rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18269if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18270 (eval $ac_link) 2>conftest.er1
84e70f78 18271 ac_status=$?
edfaf76d
LK
18272 grep -v '^ *+' conftest.er1 >conftest.err
18273 rm -f conftest.er1
18274 cat conftest.err >&5
c0d27fcc 18275 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18276 (exit $ac_status); } &&
10a3b1a1
EZ
18277 { ac_try='test -z "$ac_c_werror_flag"
18278 || test ! -s conftest.err'
edfaf76d
LK
18279 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18280 (eval $ac_try) 2>&5
18281 ac_status=$?
18282 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18283 (exit $ac_status); }; } &&
18284 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18285 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18286 (eval $ac_try) 2>&5
18287 ac_status=$?
c0d27fcc 18288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18289 (exit $ac_status); }; }; then
18290 ac_cv_lib_resolv___res_send=yes
18291else
18292 echo "$as_me: failed program was:" >&5
19650fd6
AS
18293sed 's/^/| /' conftest.$ac_ext >&5
18294
84e70f78
KR
18295ac_cv_lib_resolv___res_send=no
18296fi
edfaf76d
LK
18297rm -f conftest.err conftest.$ac_objext \
18298 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
18299LIBS=$ac_check_lib_save_LIBS
18300fi
c0d27fcc 18301echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
18302echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
18303if test $ac_cv_lib_resolv___res_send = yes; then
18304 resolv=yes
18305fi
18306
18307fi
18308
18309fi
18310
18311fi
18312
18313 if test "$resolv" = yes ; then
18314 RESOLVLIB=-lresolv
b936fae4 18315
c0d27fcc 18316cat >>confdefs.h <<\_ACEOF
84e70f78 18317#define HAVE_LIBRESOLV 1
c0d27fcc 18318_ACEOF
84e70f78
KR
18319
18320 else
18321 RESOLVLIB=
18322 fi
c0d27fcc 18323 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
18324echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
18325if test "${ac_cv_func_hes_getmailhost+set}" = set; then
18326 echo $ECHO_N "(cached) $ECHO_C" >&6
18327else
18328 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18329/* confdefs.h. */
18330_ACEOF
18331cat confdefs.h >>conftest.$ac_ext
18332cat >>conftest.$ac_ext <<_ACEOF
18333/* end confdefs.h. */
edfaf76d
LK
18334/* Define hes_getmailhost to an innocuous variant, in case <limits.h> declares hes_getmailhost.
18335 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18336#define hes_getmailhost innocuous_hes_getmailhost
18337
84e70f78 18338/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
18339 which can conflict with char hes_getmailhost (); below.
18340 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18341 <limits.h> exists even on freestanding compilers. */
edfaf76d 18342
19650fd6
AS
18343#ifdef __STDC__
18344# include <limits.h>
18345#else
18346# include <assert.h>
18347#endif
edfaf76d
LK
18348
18349#undef hes_getmailhost
18350
84e70f78
KR
18351/* Override any gcc2 internal prototype to avoid an error. */
18352#ifdef __cplusplus
18353extern "C"
19650fd6 18354{
84e70f78
KR
18355#endif
18356/* We use char because int might match the return type of a gcc2
18357 builtin and then its argument prototype would still apply. */
18358char hes_getmailhost ();
84e70f78
KR
18359/* The GNU C library defines this for functions which it implements
18360 to always fail with ENOSYS. Some functions are actually named
18361 something starting with __ and the normal name is an alias. */
18362#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
18363choke me
18364#else
19650fd6
AS
18365char (*f) () = hes_getmailhost;
18366#endif
18367#ifdef __cplusplus
18368}
cd958eb3
MB
18369#endif
18370
19650fd6
AS
18371int
18372main ()
18373{
18374return f != hes_getmailhost;
84e70f78
KR
18375 ;
18376 return 0;
18377}
18378_ACEOF
18379rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18380if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18381 (eval $ac_link) 2>conftest.er1
84e70f78 18382 ac_status=$?
edfaf76d
LK
18383 grep -v '^ *+' conftest.er1 >conftest.err
18384 rm -f conftest.er1
18385 cat conftest.err >&5
c0d27fcc 18386 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18387 (exit $ac_status); } &&
10a3b1a1
EZ
18388 { ac_try='test -z "$ac_c_werror_flag"
18389 || test ! -s conftest.err'
edfaf76d
LK
18390 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18391 (eval $ac_try) 2>&5
18392 ac_status=$?
18393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18394 (exit $ac_status); }; } &&
18395 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18396 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18397 (eval $ac_try) 2>&5
18398 ac_status=$?
c0d27fcc 18399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18400 (exit $ac_status); }; }; then
18401 ac_cv_func_hes_getmailhost=yes
18402else
18403 echo "$as_me: failed program was:" >&5
19650fd6
AS
18404sed 's/^/| /' conftest.$ac_ext >&5
18405
84e70f78
KR
18406ac_cv_func_hes_getmailhost=no
18407fi
edfaf76d
LK
18408rm -f conftest.err conftest.$ac_objext \
18409 conftest$ac_exeext conftest.$ac_ext
84e70f78 18410fi
c0d27fcc 18411echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
18412echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
18413if test $ac_cv_func_hes_getmailhost = yes; then
18414 :
18415else
c0d27fcc 18416 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
18417echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
18418if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
18419 echo $ECHO_N "(cached) $ECHO_C" >&6
18420else
18421 ac_check_lib_save_LIBS=$LIBS
18422LIBS="-lhesiod $RESOLVLIB $LIBS"
18423cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18424/* confdefs.h. */
18425_ACEOF
18426cat confdefs.h >>conftest.$ac_ext
18427cat >>conftest.$ac_ext <<_ACEOF
18428/* end confdefs.h. */
84e70f78
KR
18429
18430/* Override any gcc2 internal prototype to avoid an error. */
18431#ifdef __cplusplus
18432extern "C"
18433#endif
18434/* We use char because int might match the return type of a gcc2
18435 builtin and then its argument prototype would still apply. */
18436char hes_getmailhost ();
18437int
18438main ()
18439{
18440hes_getmailhost ();
18441 ;
18442 return 0;
18443}
18444_ACEOF
18445rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18446if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18447 (eval $ac_link) 2>conftest.er1
84e70f78 18448 ac_status=$?
edfaf76d
LK
18449 grep -v '^ *+' conftest.er1 >conftest.err
18450 rm -f conftest.er1
18451 cat conftest.err >&5
c0d27fcc 18452 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 18453 (exit $ac_status); } &&
10a3b1a1
EZ
18454 { ac_try='test -z "$ac_c_werror_flag"
18455 || test ! -s conftest.err'
edfaf76d
LK
18456 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18457 (eval $ac_try) 2>&5
18458 ac_status=$?
18459 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18460 (exit $ac_status); }; } &&
18461 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18462 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
18463 (eval $ac_try) 2>&5
18464 ac_status=$?
c0d27fcc 18465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
18466 (exit $ac_status); }; }; then
18467 ac_cv_lib_hesiod_hes_getmailhost=yes
18468else
18469 echo "$as_me: failed program was:" >&5
19650fd6
AS
18470sed 's/^/| /' conftest.$ac_ext >&5
18471
84e70f78
KR
18472ac_cv_lib_hesiod_hes_getmailhost=no
18473fi
edfaf76d
LK
18474rm -f conftest.err conftest.$ac_objext \
18475 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
18476LIBS=$ac_check_lib_save_LIBS
18477fi
c0d27fcc 18478echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
18479echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
18480if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 18481
c0d27fcc 18482cat >>confdefs.h <<\_ACEOF
84e70f78 18483#define HAVE_LIBHESIOD 1
c0d27fcc 18484_ACEOF
84e70f78
KR
18485
18486else
18487 :
18488fi
18489
18490fi
18491
18492fi
18493
a21616bd
KR
18494# These tell us which Kerberos-related libraries to use.
18495if test "${with_kerberos+set}" = set; then
503d2be0 18496
c0d27fcc 18497echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
18498echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
18499if test "${ac_cv_lib_com_err_com_err+set}" = set; then
18500 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18501else
503d2be0 18502 ac_check_lib_save_LIBS=$LIBS
a21616bd 18503LIBS="-lcom_err $LIBS"
503d2be0 18504cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18505/* confdefs.h. */
18506_ACEOF
18507cat confdefs.h >>conftest.$ac_ext
18508cat >>conftest.$ac_ext <<_ACEOF
18509/* end confdefs.h. */
503d2be0 18510
a21616bd 18511/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18512#ifdef __cplusplus
18513extern "C"
18514#endif
a21616bd 18515/* We use char because int might match the return type of a gcc2
503d2be0
AS
18516 builtin and then its argument prototype would still apply. */
18517char com_err ();
18518int
18519main ()
18520{
18521com_err ();
18522 ;
18523 return 0;
18524}
18525_ACEOF
18526rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18527if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18528 (eval $ac_link) 2>conftest.er1
503d2be0 18529 ac_status=$?
edfaf76d
LK
18530 grep -v '^ *+' conftest.er1 >conftest.err
18531 rm -f conftest.er1
18532 cat conftest.err >&5
c0d27fcc 18533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18534 (exit $ac_status); } &&
10a3b1a1
EZ
18535 { ac_try='test -z "$ac_c_werror_flag"
18536 || test ! -s conftest.err'
edfaf76d
LK
18537 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18538 (eval $ac_try) 2>&5
18539 ac_status=$?
18540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18541 (exit $ac_status); }; } &&
18542 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18544 (eval $ac_try) 2>&5
18545 ac_status=$?
c0d27fcc 18546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18547 (exit $ac_status); }; }; then
18548 ac_cv_lib_com_err_com_err=yes
18549else
18550 echo "$as_me: failed program was:" >&5
19650fd6
AS
18551sed 's/^/| /' conftest.$ac_ext >&5
18552
503d2be0
AS
18553ac_cv_lib_com_err_com_err=no
18554fi
edfaf76d
LK
18555rm -f conftest.err conftest.$ac_objext \
18556 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18557LIBS=$ac_check_lib_save_LIBS
18558fi
c0d27fcc 18559echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
18560echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
18561if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 18562 cat >>confdefs.h <<_ACEOF
503d2be0 18563#define HAVE_LIBCOM_ERR 1
c0d27fcc 18564_ACEOF
a21616bd
KR
18565
18566 LIBS="-lcom_err $LIBS"
18567
a21616bd
KR
18568fi
18569
c0d27fcc
MR
18570
18571echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
18572echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
18573if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
18574 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18575else
503d2be0 18576 ac_check_lib_save_LIBS=$LIBS
a21616bd 18577LIBS="-lk5crypto $LIBS"
503d2be0 18578cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18579/* confdefs.h. */
18580_ACEOF
18581cat confdefs.h >>conftest.$ac_ext
18582cat >>conftest.$ac_ext <<_ACEOF
18583/* end confdefs.h. */
503d2be0 18584
a21616bd 18585/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18586#ifdef __cplusplus
18587extern "C"
18588#endif
a21616bd 18589/* We use char because int might match the return type of a gcc2
503d2be0
AS
18590 builtin and then its argument prototype would still apply. */
18591char mit_des_cbc_encrypt ();
18592int
18593main ()
18594{
18595mit_des_cbc_encrypt ();
18596 ;
18597 return 0;
18598}
18599_ACEOF
18600rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18601if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18602 (eval $ac_link) 2>conftest.er1
503d2be0 18603 ac_status=$?
edfaf76d
LK
18604 grep -v '^ *+' conftest.er1 >conftest.err
18605 rm -f conftest.er1
18606 cat conftest.err >&5
c0d27fcc 18607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18608 (exit $ac_status); } &&
10a3b1a1
EZ
18609 { ac_try='test -z "$ac_c_werror_flag"
18610 || test ! -s conftest.err'
edfaf76d
LK
18611 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18612 (eval $ac_try) 2>&5
18613 ac_status=$?
18614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18615 (exit $ac_status); }; } &&
18616 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18617 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18618 (eval $ac_try) 2>&5
18619 ac_status=$?
c0d27fcc 18620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18621 (exit $ac_status); }; }; then
18622 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
18623else
18624 echo "$as_me: failed program was:" >&5
19650fd6
AS
18625sed 's/^/| /' conftest.$ac_ext >&5
18626
503d2be0
AS
18627ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
18628fi
edfaf76d
LK
18629rm -f conftest.err conftest.$ac_objext \
18630 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18631LIBS=$ac_check_lib_save_LIBS
18632fi
c0d27fcc 18633echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
18634echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
18635if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 18636 cat >>confdefs.h <<_ACEOF
503d2be0 18637#define HAVE_LIBK5CRYPTO 1
c0d27fcc 18638_ACEOF
a21616bd
KR
18639
18640 LIBS="-lk5crypto $LIBS"
18641
a21616bd
KR
18642fi
18643
c0d27fcc
MR
18644
18645echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
18646echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
18647if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
18648 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18649else
503d2be0 18650 ac_check_lib_save_LIBS=$LIBS
a21616bd 18651LIBS="-lcrypto $LIBS"
503d2be0 18652cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18653/* confdefs.h. */
18654_ACEOF
18655cat confdefs.h >>conftest.$ac_ext
18656cat >>conftest.$ac_ext <<_ACEOF
18657/* end confdefs.h. */
503d2be0 18658
a21616bd 18659/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18660#ifdef __cplusplus
18661extern "C"
18662#endif
a21616bd 18663/* We use char because int might match the return type of a gcc2
503d2be0
AS
18664 builtin and then its argument prototype would still apply. */
18665char mit_des_cbc_encrypt ();
18666int
18667main ()
18668{
18669mit_des_cbc_encrypt ();
18670 ;
18671 return 0;
18672}
18673_ACEOF
18674rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18675if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18676 (eval $ac_link) 2>conftest.er1
503d2be0 18677 ac_status=$?
edfaf76d
LK
18678 grep -v '^ *+' conftest.er1 >conftest.err
18679 rm -f conftest.er1
18680 cat conftest.err >&5
c0d27fcc 18681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18682 (exit $ac_status); } &&
10a3b1a1
EZ
18683 { ac_try='test -z "$ac_c_werror_flag"
18684 || test ! -s conftest.err'
edfaf76d
LK
18685 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18686 (eval $ac_try) 2>&5
18687 ac_status=$?
18688 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18689 (exit $ac_status); }; } &&
18690 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18691 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18692 (eval $ac_try) 2>&5
18693 ac_status=$?
c0d27fcc 18694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18695 (exit $ac_status); }; }; then
18696 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
18697else
18698 echo "$as_me: failed program was:" >&5
19650fd6
AS
18699sed 's/^/| /' conftest.$ac_ext >&5
18700
503d2be0
AS
18701ac_cv_lib_crypto_mit_des_cbc_encrypt=no
18702fi
edfaf76d
LK
18703rm -f conftest.err conftest.$ac_objext \
18704 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18705LIBS=$ac_check_lib_save_LIBS
18706fi
c0d27fcc 18707echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
18708echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
18709if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 18710 cat >>confdefs.h <<_ACEOF
503d2be0 18711#define HAVE_LIBCRYPTO 1
c0d27fcc 18712_ACEOF
a21616bd
KR
18713
18714 LIBS="-lcrypto $LIBS"
18715
a21616bd
KR
18716fi
18717
c0d27fcc
MR
18718
18719echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
18720echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
18721if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
18722 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18723else
503d2be0 18724 ac_check_lib_save_LIBS=$LIBS
a21616bd 18725LIBS="-lkrb5 $LIBS"
503d2be0 18726cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18727/* confdefs.h. */
18728_ACEOF
18729cat confdefs.h >>conftest.$ac_ext
18730cat >>conftest.$ac_ext <<_ACEOF
18731/* end confdefs.h. */
a21616bd 18732
503d2be0
AS
18733/* Override any gcc2 internal prototype to avoid an error. */
18734#ifdef __cplusplus
18735extern "C"
18736#endif
18737/* We use char because int might match the return type of a gcc2
18738 builtin and then its argument prototype would still apply. */
18739char krb5_init_context ();
18740int
18741main ()
18742{
18743krb5_init_context ();
18744 ;
18745 return 0;
18746}
18747_ACEOF
18748rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18749if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18750 (eval $ac_link) 2>conftest.er1
503d2be0 18751 ac_status=$?
edfaf76d
LK
18752 grep -v '^ *+' conftest.er1 >conftest.err
18753 rm -f conftest.er1
18754 cat conftest.err >&5
c0d27fcc 18755 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18756 (exit $ac_status); } &&
10a3b1a1
EZ
18757 { ac_try='test -z "$ac_c_werror_flag"
18758 || test ! -s conftest.err'
edfaf76d
LK
18759 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18760 (eval $ac_try) 2>&5
18761 ac_status=$?
18762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18763 (exit $ac_status); }; } &&
18764 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18766 (eval $ac_try) 2>&5
18767 ac_status=$?
c0d27fcc 18768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18769 (exit $ac_status); }; }; then
18770 ac_cv_lib_krb5_krb5_init_context=yes
18771else
18772 echo "$as_me: failed program was:" >&5
19650fd6
AS
18773sed 's/^/| /' conftest.$ac_ext >&5
18774
503d2be0
AS
18775ac_cv_lib_krb5_krb5_init_context=no
18776fi
edfaf76d
LK
18777rm -f conftest.err conftest.$ac_objext \
18778 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18779LIBS=$ac_check_lib_save_LIBS
18780fi
c0d27fcc 18781echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
18782echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
18783if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 18784 cat >>confdefs.h <<_ACEOF
503d2be0 18785#define HAVE_LIBKRB5 1
c0d27fcc 18786_ACEOF
a21616bd
KR
18787
18788 LIBS="-lkrb5 $LIBS"
18789
a21616bd
KR
18790fi
18791
18792 if test "${with_kerberos5+set}" != set; then
503d2be0 18793
c0d27fcc 18794echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
18795echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
18796if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
18797 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18798else
503d2be0 18799 ac_check_lib_save_LIBS=$LIBS
a21616bd 18800LIBS="-ldes425 $LIBS"
503d2be0 18801cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18802/* confdefs.h. */
18803_ACEOF
18804cat confdefs.h >>conftest.$ac_ext
18805cat >>conftest.$ac_ext <<_ACEOF
18806/* end confdefs.h. */
503d2be0 18807
a21616bd 18808/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18809#ifdef __cplusplus
18810extern "C"
18811#endif
a21616bd 18812/* We use char because int might match the return type of a gcc2
503d2be0
AS
18813 builtin and then its argument prototype would still apply. */
18814char des_cbc_encrypt ();
18815int
18816main ()
18817{
18818des_cbc_encrypt ();
18819 ;
18820 return 0;
18821}
18822_ACEOF
18823rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18824if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18825 (eval $ac_link) 2>conftest.er1
503d2be0 18826 ac_status=$?
edfaf76d
LK
18827 grep -v '^ *+' conftest.er1 >conftest.err
18828 rm -f conftest.er1
18829 cat conftest.err >&5
c0d27fcc 18830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18831 (exit $ac_status); } &&
10a3b1a1
EZ
18832 { ac_try='test -z "$ac_c_werror_flag"
18833 || test ! -s conftest.err'
edfaf76d
LK
18834 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18835 (eval $ac_try) 2>&5
18836 ac_status=$?
18837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18838 (exit $ac_status); }; } &&
18839 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18841 (eval $ac_try) 2>&5
18842 ac_status=$?
c0d27fcc 18843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18844 (exit $ac_status); }; }; then
18845 ac_cv_lib_des425_des_cbc_encrypt=yes
18846else
18847 echo "$as_me: failed program was:" >&5
19650fd6
AS
18848sed 's/^/| /' conftest.$ac_ext >&5
18849
503d2be0
AS
18850ac_cv_lib_des425_des_cbc_encrypt=no
18851fi
edfaf76d
LK
18852rm -f conftest.err conftest.$ac_objext \
18853 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18854LIBS=$ac_check_lib_save_LIBS
18855fi
c0d27fcc 18856echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
18857echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
18858if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 18859 cat >>confdefs.h <<_ACEOF
503d2be0 18860#define HAVE_LIBDES425 1
c0d27fcc 18861_ACEOF
a21616bd
KR
18862
18863 LIBS="-ldes425 $LIBS"
18864
18865else
503d2be0 18866
c0d27fcc 18867echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
18868echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
18869if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
18870 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18871else
503d2be0 18872 ac_check_lib_save_LIBS=$LIBS
a21616bd 18873LIBS="-ldes $LIBS"
503d2be0 18874cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18875/* confdefs.h. */
18876_ACEOF
18877cat confdefs.h >>conftest.$ac_ext
18878cat >>conftest.$ac_ext <<_ACEOF
18879/* end confdefs.h. */
503d2be0 18880
a21616bd 18881/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18882#ifdef __cplusplus
18883extern "C"
18884#endif
a21616bd 18885/* We use char because int might match the return type of a gcc2
503d2be0
AS
18886 builtin and then its argument prototype would still apply. */
18887char des_cbc_encrypt ();
18888int
18889main ()
18890{
18891des_cbc_encrypt ();
18892 ;
18893 return 0;
18894}
18895_ACEOF
18896rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18897if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18898 (eval $ac_link) 2>conftest.er1
503d2be0 18899 ac_status=$?
edfaf76d
LK
18900 grep -v '^ *+' conftest.er1 >conftest.err
18901 rm -f conftest.er1
18902 cat conftest.err >&5
c0d27fcc 18903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18904 (exit $ac_status); } &&
10a3b1a1
EZ
18905 { ac_try='test -z "$ac_c_werror_flag"
18906 || test ! -s conftest.err'
edfaf76d
LK
18907 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18908 (eval $ac_try) 2>&5
18909 ac_status=$?
18910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18911 (exit $ac_status); }; } &&
18912 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18913 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18914 (eval $ac_try) 2>&5
18915 ac_status=$?
c0d27fcc 18916 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18917 (exit $ac_status); }; }; then
18918 ac_cv_lib_des_des_cbc_encrypt=yes
18919else
18920 echo "$as_me: failed program was:" >&5
19650fd6
AS
18921sed 's/^/| /' conftest.$ac_ext >&5
18922
503d2be0
AS
18923ac_cv_lib_des_des_cbc_encrypt=no
18924fi
edfaf76d
LK
18925rm -f conftest.err conftest.$ac_objext \
18926 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18927LIBS=$ac_check_lib_save_LIBS
18928fi
c0d27fcc 18929echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
18930echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
18931if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 18932 cat >>confdefs.h <<_ACEOF
503d2be0 18933#define HAVE_LIBDES 1
c0d27fcc 18934_ACEOF
a21616bd
KR
18935
18936 LIBS="-ldes $LIBS"
18937
a21616bd
KR
18938fi
18939
18940fi
18941
c0d27fcc
MR
18942
18943echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
18944echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
18945if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
18946 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 18947else
503d2be0 18948 ac_check_lib_save_LIBS=$LIBS
a21616bd 18949LIBS="-lkrb4 $LIBS"
503d2be0 18950cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18951/* confdefs.h. */
18952_ACEOF
18953cat confdefs.h >>conftest.$ac_ext
18954cat >>conftest.$ac_ext <<_ACEOF
18955/* end confdefs.h. */
503d2be0 18956
a21616bd 18957/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18958#ifdef __cplusplus
18959extern "C"
18960#endif
a21616bd 18961/* We use char because int might match the return type of a gcc2
503d2be0
AS
18962 builtin and then its argument prototype would still apply. */
18963char krb_get_cred ();
18964int
18965main ()
18966{
18967krb_get_cred ();
18968 ;
18969 return 0;
18970}
18971_ACEOF
18972rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18973if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 18974 (eval $ac_link) 2>conftest.er1
503d2be0 18975 ac_status=$?
edfaf76d
LK
18976 grep -v '^ *+' conftest.er1 >conftest.err
18977 rm -f conftest.er1
18978 cat conftest.err >&5
c0d27fcc 18979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18980 (exit $ac_status); } &&
10a3b1a1
EZ
18981 { ac_try='test -z "$ac_c_werror_flag"
18982 || test ! -s conftest.err'
edfaf76d
LK
18983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18984 (eval $ac_try) 2>&5
18985 ac_status=$?
18986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18987 (exit $ac_status); }; } &&
18988 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18990 (eval $ac_try) 2>&5
18991 ac_status=$?
c0d27fcc 18992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18993 (exit $ac_status); }; }; then
18994 ac_cv_lib_krb4_krb_get_cred=yes
18995else
18996 echo "$as_me: failed program was:" >&5
19650fd6
AS
18997sed 's/^/| /' conftest.$ac_ext >&5
18998
503d2be0
AS
18999ac_cv_lib_krb4_krb_get_cred=no
19000fi
edfaf76d
LK
19001rm -f conftest.err conftest.$ac_objext \
19002 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
19003LIBS=$ac_check_lib_save_LIBS
19004fi
c0d27fcc 19005echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
19006echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
19007if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 19008 cat >>confdefs.h <<_ACEOF
503d2be0 19009#define HAVE_LIBKRB4 1
c0d27fcc 19010_ACEOF
a21616bd
KR
19011
19012 LIBS="-lkrb4 $LIBS"
19013
19014else
503d2be0 19015
c0d27fcc 19016echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
19017echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
19018if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
19019 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 19020else
503d2be0 19021 ac_check_lib_save_LIBS=$LIBS
a21616bd 19022LIBS="-lkrb $LIBS"
503d2be0 19023cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19024/* confdefs.h. */
19025_ACEOF
19026cat confdefs.h >>conftest.$ac_ext
19027cat >>conftest.$ac_ext <<_ACEOF
19028/* end confdefs.h. */
503d2be0 19029
a21616bd 19030/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19031#ifdef __cplusplus
19032extern "C"
19033#endif
a21616bd 19034/* We use char because int might match the return type of a gcc2
503d2be0
AS
19035 builtin and then its argument prototype would still apply. */
19036char krb_get_cred ();
19037int
19038main ()
19039{
19040krb_get_cred ();
19041 ;
19042 return 0;
19043}
19044_ACEOF
19045rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19046if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 19047 (eval $ac_link) 2>conftest.er1
503d2be0 19048 ac_status=$?
edfaf76d
LK
19049 grep -v '^ *+' conftest.er1 >conftest.err
19050 rm -f conftest.er1
19051 cat conftest.err >&5
c0d27fcc 19052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19053 (exit $ac_status); } &&
10a3b1a1
EZ
19054 { ac_try='test -z "$ac_c_werror_flag"
19055 || test ! -s conftest.err'
edfaf76d
LK
19056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19057 (eval $ac_try) 2>&5
19058 ac_status=$?
19059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19060 (exit $ac_status); }; } &&
19061 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19062 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19063 (eval $ac_try) 2>&5
19064 ac_status=$?
c0d27fcc 19065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19066 (exit $ac_status); }; }; then
19067 ac_cv_lib_krb_krb_get_cred=yes
19068else
19069 echo "$as_me: failed program was:" >&5
19650fd6
AS
19070sed 's/^/| /' conftest.$ac_ext >&5
19071
503d2be0
AS
19072ac_cv_lib_krb_krb_get_cred=no
19073fi
edfaf76d
LK
19074rm -f conftest.err conftest.$ac_objext \
19075 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
19076LIBS=$ac_check_lib_save_LIBS
19077fi
c0d27fcc 19078echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
19079echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
19080if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 19081 cat >>confdefs.h <<_ACEOF
503d2be0 19082#define HAVE_LIBKRB 1
c0d27fcc 19083_ACEOF
a21616bd
KR
19084
19085 LIBS="-lkrb $LIBS"
19086
a21616bd
KR
19087fi
19088
19089fi
19090
19091 fi
19092
19093 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
19094
19095for ac_header in krb5.h
a21616bd 19096do
503d2be0 19097as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19098if eval "test \"\${$as_ac_Header+set}\" = set"; then
19099 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19100echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19101if eval "test \"\${$as_ac_Header+set}\" = set"; then
19102 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19103fi
19104echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19105echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19106else
c0d27fcc
MR
19107 # Is the header compilable?
19108echo "$as_me:$LINENO: checking $ac_header usability" >&5
19109echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19110cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19111/* confdefs.h. */
19112_ACEOF
19113cat confdefs.h >>conftest.$ac_ext
19114cat >>conftest.$ac_ext <<_ACEOF
19115/* end confdefs.h. */
c0d27fcc
MR
19116$ac_includes_default
19117#include <$ac_header>
19118_ACEOF
19119rm -f conftest.$ac_objext
19120if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19121 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19122 ac_status=$?
edfaf76d
LK
19123 grep -v '^ *+' conftest.er1 >conftest.err
19124 rm -f conftest.er1
19125 cat conftest.err >&5
c0d27fcc
MR
19126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19127 (exit $ac_status); } &&
10a3b1a1
EZ
19128 { ac_try='test -z "$ac_c_werror_flag"
19129 || test ! -s conftest.err'
edfaf76d
LK
19130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19131 (eval $ac_try) 2>&5
19132 ac_status=$?
19133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19134 (exit $ac_status); }; } &&
19135 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19136 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19137 (eval $ac_try) 2>&5
19138 ac_status=$?
19139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19140 (exit $ac_status); }; }; then
19141 ac_header_compiler=yes
19142else
19143 echo "$as_me: failed program was:" >&5
19650fd6
AS
19144sed 's/^/| /' conftest.$ac_ext >&5
19145
c0d27fcc
MR
19146ac_header_compiler=no
19147fi
edfaf76d 19148rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19149echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19150echo "${ECHO_T}$ac_header_compiler" >&6
19151
19152# Is the header present?
19153echo "$as_me:$LINENO: checking $ac_header presence" >&5
19154echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19155cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19156/* confdefs.h. */
19157_ACEOF
19158cat confdefs.h >>conftest.$ac_ext
19159cat >>conftest.$ac_ext <<_ACEOF
19160/* end confdefs.h. */
503d2be0
AS
19161#include <$ac_header>
19162_ACEOF
c0d27fcc 19163if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19164 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19165 ac_status=$?
6bae0ccf 19166 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19167 rm -f conftest.er1
19168 cat conftest.err >&5
c0d27fcc 19169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19170 (exit $ac_status); } >/dev/null; then
19171 if test -s conftest.err; then
19172 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19173 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19174 else
19175 ac_cpp_err=
19176 fi
19177else
19178 ac_cpp_err=yes
19179fi
19180if test -z "$ac_cpp_err"; then
c0d27fcc 19181 ac_header_preproc=yes
503d2be0
AS
19182else
19183 echo "$as_me: failed program was:" >&5
19650fd6
AS
19184sed 's/^/| /' conftest.$ac_ext >&5
19185
c0d27fcc 19186 ac_header_preproc=no
a21616bd 19187fi
503d2be0 19188rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19189echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19190echo "${ECHO_T}$ac_header_preproc" >&6
19191
19192# So? What about this header?
edfaf76d
LK
19193case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19194 yes:no: )
c0d27fcc
MR
19195 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19196echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19197 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19198echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19199 ac_header_preproc=yes
19650fd6 19200 ;;
edfaf76d 19201 no:yes:* )
c0d27fcc
MR
19202 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19203echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19204 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19205echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19206 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19207echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19208 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19209echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19210 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19211echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19212 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19213echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19214 (
19215 cat <<\_ASBOX
edfaf76d
LK
19216## ------------------------------------------ ##
19217## Report this to the AC_PACKAGE_NAME lists. ##
19218## ------------------------------------------ ##
19650fd6
AS
19219_ASBOX
19220 ) |
19221 sed "s/^/$as_me: WARNING: /" >&2
19222 ;;
c0d27fcc
MR
19223esac
19224echo "$as_me:$LINENO: checking for $ac_header" >&5
19225echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19226if eval "test \"\${$as_ac_Header+set}\" = set"; then
19227 echo $ECHO_N "(cached) $ECHO_C" >&6
19228else
edfaf76d 19229 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19230fi
c0d27fcc 19231echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19232echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19233
19234fi
503d2be0 19235if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19236 cat >>confdefs.h <<_ACEOF
503d2be0 19237#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19238_ACEOF
503d2be0 19239
a21616bd 19240fi
c0d27fcc 19241
a21616bd
KR
19242done
19243
19244 else
503d2be0
AS
19245
19246for ac_header in des.h
a21616bd 19247do
503d2be0 19248as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19249if eval "test \"\${$as_ac_Header+set}\" = set"; then
19250 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19251echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19252if eval "test \"\${$as_ac_Header+set}\" = set"; then
19253 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19254fi
19255echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19256echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19257else
c0d27fcc
MR
19258 # Is the header compilable?
19259echo "$as_me:$LINENO: checking $ac_header usability" >&5
19260echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19261cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19262/* confdefs.h. */
19263_ACEOF
19264cat confdefs.h >>conftest.$ac_ext
19265cat >>conftest.$ac_ext <<_ACEOF
19266/* end confdefs.h. */
c0d27fcc
MR
19267$ac_includes_default
19268#include <$ac_header>
19269_ACEOF
19270rm -f conftest.$ac_objext
19271if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19272 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19273 ac_status=$?
edfaf76d
LK
19274 grep -v '^ *+' conftest.er1 >conftest.err
19275 rm -f conftest.er1
19276 cat conftest.err >&5
c0d27fcc
MR
19277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19278 (exit $ac_status); } &&
10a3b1a1
EZ
19279 { ac_try='test -z "$ac_c_werror_flag"
19280 || test ! -s conftest.err'
edfaf76d
LK
19281 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19282 (eval $ac_try) 2>&5
19283 ac_status=$?
19284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19285 (exit $ac_status); }; } &&
19286 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19288 (eval $ac_try) 2>&5
19289 ac_status=$?
19290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19291 (exit $ac_status); }; }; then
19292 ac_header_compiler=yes
19293else
19294 echo "$as_me: failed program was:" >&5
19650fd6
AS
19295sed 's/^/| /' conftest.$ac_ext >&5
19296
c0d27fcc
MR
19297ac_header_compiler=no
19298fi
edfaf76d 19299rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19300echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19301echo "${ECHO_T}$ac_header_compiler" >&6
19302
19303# Is the header present?
19304echo "$as_me:$LINENO: checking $ac_header presence" >&5
19305echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19306cat >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. */
503d2be0
AS
19312#include <$ac_header>
19313_ACEOF
c0d27fcc 19314if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19315 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19316 ac_status=$?
6bae0ccf 19317 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19318 rm -f conftest.er1
19319 cat conftest.err >&5
c0d27fcc 19320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19321 (exit $ac_status); } >/dev/null; then
19322 if test -s conftest.err; then
19323 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19324 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19325 else
19326 ac_cpp_err=
19327 fi
19328else
19329 ac_cpp_err=yes
19330fi
19331if test -z "$ac_cpp_err"; then
c0d27fcc 19332 ac_header_preproc=yes
503d2be0
AS
19333else
19334 echo "$as_me: failed program was:" >&5
19650fd6
AS
19335sed 's/^/| /' conftest.$ac_ext >&5
19336
c0d27fcc 19337 ac_header_preproc=no
a21616bd 19338fi
503d2be0 19339rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19340echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19341echo "${ECHO_T}$ac_header_preproc" >&6
19342
19343# So? What about this header?
edfaf76d
LK
19344case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19345 yes:no: )
c0d27fcc
MR
19346 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19347echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19348 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19349echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19350 ac_header_preproc=yes
19650fd6 19351 ;;
edfaf76d 19352 no:yes:* )
c0d27fcc
MR
19353 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19354echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19355 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19356echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19357 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19358echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19359 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19360echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19361 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19362echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19363 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19364echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19365 (
19366 cat <<\_ASBOX
edfaf76d
LK
19367## ------------------------------------------ ##
19368## Report this to the AC_PACKAGE_NAME lists. ##
19369## ------------------------------------------ ##
19650fd6
AS
19370_ASBOX
19371 ) |
19372 sed "s/^/$as_me: WARNING: /" >&2
19373 ;;
c0d27fcc
MR
19374esac
19375echo "$as_me:$LINENO: checking for $ac_header" >&5
19376echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19377if eval "test \"\${$as_ac_Header+set}\" = set"; then
19378 echo $ECHO_N "(cached) $ECHO_C" >&6
19379else
edfaf76d 19380 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19381fi
c0d27fcc 19382echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19383echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19384
19385fi
503d2be0 19386if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19387 cat >>confdefs.h <<_ACEOF
503d2be0 19388#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19389_ACEOF
503d2be0 19390
a21616bd 19391else
503d2be0
AS
19392
19393for ac_header in kerberosIV/des.h
a21616bd 19394do
503d2be0 19395as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19396if eval "test \"\${$as_ac_Header+set}\" = set"; then
19397 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19398echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19399if eval "test \"\${$as_ac_Header+set}\" = set"; then
19400 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19401fi
19402echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19403echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19404else
c0d27fcc
MR
19405 # Is the header compilable?
19406echo "$as_me:$LINENO: checking $ac_header usability" >&5
19407echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19408cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19409/* confdefs.h. */
19410_ACEOF
19411cat confdefs.h >>conftest.$ac_ext
19412cat >>conftest.$ac_ext <<_ACEOF
19413/* end confdefs.h. */
c0d27fcc
MR
19414$ac_includes_default
19415#include <$ac_header>
19416_ACEOF
19417rm -f conftest.$ac_objext
19418if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19419 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19420 ac_status=$?
edfaf76d
LK
19421 grep -v '^ *+' conftest.er1 >conftest.err
19422 rm -f conftest.er1
19423 cat conftest.err >&5
c0d27fcc
MR
19424 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19425 (exit $ac_status); } &&
10a3b1a1
EZ
19426 { ac_try='test -z "$ac_c_werror_flag"
19427 || test ! -s conftest.err'
edfaf76d
LK
19428 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19429 (eval $ac_try) 2>&5
19430 ac_status=$?
19431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19432 (exit $ac_status); }; } &&
19433 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19435 (eval $ac_try) 2>&5
19436 ac_status=$?
19437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19438 (exit $ac_status); }; }; then
19439 ac_header_compiler=yes
19440else
19441 echo "$as_me: failed program was:" >&5
19650fd6
AS
19442sed 's/^/| /' conftest.$ac_ext >&5
19443
c0d27fcc
MR
19444ac_header_compiler=no
19445fi
edfaf76d 19446rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19447echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19448echo "${ECHO_T}$ac_header_compiler" >&6
19449
19450# Is the header present?
19451echo "$as_me:$LINENO: checking $ac_header presence" >&5
19452echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19453cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19454/* confdefs.h. */
19455_ACEOF
19456cat confdefs.h >>conftest.$ac_ext
19457cat >>conftest.$ac_ext <<_ACEOF
19458/* end confdefs.h. */
503d2be0
AS
19459#include <$ac_header>
19460_ACEOF
c0d27fcc 19461if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19462 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19463 ac_status=$?
6bae0ccf 19464 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19465 rm -f conftest.er1
19466 cat conftest.err >&5
c0d27fcc 19467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19468 (exit $ac_status); } >/dev/null; then
19469 if test -s conftest.err; then
19470 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19471 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19472 else
19473 ac_cpp_err=
19474 fi
19475else
19476 ac_cpp_err=yes
19477fi
19478if test -z "$ac_cpp_err"; then
c0d27fcc 19479 ac_header_preproc=yes
503d2be0
AS
19480else
19481 echo "$as_me: failed program was:" >&5
19650fd6
AS
19482sed 's/^/| /' conftest.$ac_ext >&5
19483
c0d27fcc 19484 ac_header_preproc=no
a21616bd 19485fi
503d2be0 19486rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19487echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19488echo "${ECHO_T}$ac_header_preproc" >&6
19489
19490# So? What about this header?
edfaf76d
LK
19491case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19492 yes:no: )
c0d27fcc
MR
19493 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19494echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19495 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19496echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19497 ac_header_preproc=yes
19650fd6 19498 ;;
edfaf76d 19499 no:yes:* )
c0d27fcc
MR
19500 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19501echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19502 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19503echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19504 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19505echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19506 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19507echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19508 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19509echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19510 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19511echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19512 (
19513 cat <<\_ASBOX
edfaf76d
LK
19514## ------------------------------------------ ##
19515## Report this to the AC_PACKAGE_NAME lists. ##
19516## ------------------------------------------ ##
19650fd6
AS
19517_ASBOX
19518 ) |
19519 sed "s/^/$as_me: WARNING: /" >&2
19520 ;;
c0d27fcc
MR
19521esac
19522echo "$as_me:$LINENO: checking for $ac_header" >&5
19523echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19524if eval "test \"\${$as_ac_Header+set}\" = set"; then
19525 echo $ECHO_N "(cached) $ECHO_C" >&6
19526else
edfaf76d 19527 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19528fi
c0d27fcc 19529echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19530echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19531
19532fi
503d2be0 19533if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19534 cat >>confdefs.h <<_ACEOF
503d2be0 19535#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19536_ACEOF
503d2be0 19537
a21616bd 19538else
503d2be0
AS
19539
19540for ac_header in kerberos/des.h
a21616bd 19541do
503d2be0 19542as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19543if eval "test \"\${$as_ac_Header+set}\" = set"; then
19544 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19545echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19546if eval "test \"\${$as_ac_Header+set}\" = set"; then
19547 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19548fi
19549echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19550echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19551else
c0d27fcc
MR
19552 # Is the header compilable?
19553echo "$as_me:$LINENO: checking $ac_header usability" >&5
19554echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19555cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19556/* confdefs.h. */
19557_ACEOF
19558cat confdefs.h >>conftest.$ac_ext
19559cat >>conftest.$ac_ext <<_ACEOF
19560/* end confdefs.h. */
c0d27fcc
MR
19561$ac_includes_default
19562#include <$ac_header>
19563_ACEOF
19564rm -f conftest.$ac_objext
19565if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19566 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19567 ac_status=$?
edfaf76d
LK
19568 grep -v '^ *+' conftest.er1 >conftest.err
19569 rm -f conftest.er1
19570 cat conftest.err >&5
c0d27fcc
MR
19571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19572 (exit $ac_status); } &&
10a3b1a1
EZ
19573 { ac_try='test -z "$ac_c_werror_flag"
19574 || test ! -s conftest.err'
edfaf76d
LK
19575 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19576 (eval $ac_try) 2>&5
19577 ac_status=$?
19578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19579 (exit $ac_status); }; } &&
19580 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19581 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19582 (eval $ac_try) 2>&5
19583 ac_status=$?
19584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19585 (exit $ac_status); }; }; then
19586 ac_header_compiler=yes
19587else
19588 echo "$as_me: failed program was:" >&5
19650fd6
AS
19589sed 's/^/| /' conftest.$ac_ext >&5
19590
c0d27fcc
MR
19591ac_header_compiler=no
19592fi
edfaf76d 19593rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19594echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19595echo "${ECHO_T}$ac_header_compiler" >&6
19596
19597# Is the header present?
19598echo "$as_me:$LINENO: checking $ac_header presence" >&5
19599echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19600cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19601/* confdefs.h. */
19602_ACEOF
19603cat confdefs.h >>conftest.$ac_ext
19604cat >>conftest.$ac_ext <<_ACEOF
19605/* end confdefs.h. */
503d2be0
AS
19606#include <$ac_header>
19607_ACEOF
c0d27fcc 19608if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19609 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19610 ac_status=$?
6bae0ccf 19611 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19612 rm -f conftest.er1
19613 cat conftest.err >&5
c0d27fcc 19614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19615 (exit $ac_status); } >/dev/null; then
19616 if test -s conftest.err; then
19617 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19618 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19619 else
19620 ac_cpp_err=
19621 fi
19622else
19623 ac_cpp_err=yes
19624fi
19625if test -z "$ac_cpp_err"; then
c0d27fcc 19626 ac_header_preproc=yes
503d2be0
AS
19627else
19628 echo "$as_me: failed program was:" >&5
19650fd6
AS
19629sed 's/^/| /' conftest.$ac_ext >&5
19630
c0d27fcc 19631 ac_header_preproc=no
a21616bd 19632fi
503d2be0 19633rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19634echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19635echo "${ECHO_T}$ac_header_preproc" >&6
19636
19637# So? What about this header?
edfaf76d
LK
19638case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19639 yes:no: )
c0d27fcc
MR
19640 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19641echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19642 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19643echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19644 ac_header_preproc=yes
19650fd6 19645 ;;
edfaf76d 19646 no:yes:* )
c0d27fcc
MR
19647 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19648echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19649 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19650echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19651 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19652echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19653 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19654echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19655 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19656echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19657 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19658echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19659 (
19660 cat <<\_ASBOX
edfaf76d
LK
19661## ------------------------------------------ ##
19662## Report this to the AC_PACKAGE_NAME lists. ##
19663## ------------------------------------------ ##
19650fd6
AS
19664_ASBOX
19665 ) |
19666 sed "s/^/$as_me: WARNING: /" >&2
19667 ;;
c0d27fcc
MR
19668esac
19669echo "$as_me:$LINENO: checking for $ac_header" >&5
19670echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19671if eval "test \"\${$as_ac_Header+set}\" = set"; then
19672 echo $ECHO_N "(cached) $ECHO_C" >&6
19673else
edfaf76d 19674 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19675fi
c0d27fcc 19676echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19677echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19678
19679fi
503d2be0 19680if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19681 cat >>confdefs.h <<_ACEOF
503d2be0 19682#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19683_ACEOF
a21616bd
KR
19684
19685fi
c0d27fcc 19686
a21616bd
KR
19687done
19688
98418dba 19689fi
c0d27fcc 19690
925c2f3f
EZ
19691done
19692
98418dba 19693fi
c0d27fcc 19694
925c2f3f 19695done
98418dba 19696
c0d27fcc 19697
925c2f3f
EZ
19698for ac_header in krb.h
19699do
19700as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19701if eval "test \"\${$as_ac_Header+set}\" = set"; then
19702 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
19703echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19704if eval "test \"\${$as_ac_Header+set}\" = set"; then
19705 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19706fi
19707echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19708echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19709else
19710 # Is the header compilable?
19711echo "$as_me:$LINENO: checking $ac_header usability" >&5
19712echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19713cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19714/* confdefs.h. */
19715_ACEOF
19716cat confdefs.h >>conftest.$ac_ext
19717cat >>conftest.$ac_ext <<_ACEOF
19718/* end confdefs.h. */
c0d27fcc
MR
19719$ac_includes_default
19720#include <$ac_header>
19721_ACEOF
19722rm -f conftest.$ac_objext
19723if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19724 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19725 ac_status=$?
edfaf76d
LK
19726 grep -v '^ *+' conftest.er1 >conftest.err
19727 rm -f conftest.er1
19728 cat conftest.err >&5
c0d27fcc
MR
19729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19730 (exit $ac_status); } &&
10a3b1a1
EZ
19731 { ac_try='test -z "$ac_c_werror_flag"
19732 || test ! -s conftest.err'
edfaf76d
LK
19733 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19734 (eval $ac_try) 2>&5
19735 ac_status=$?
19736 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19737 (exit $ac_status); }; } &&
19738 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19739 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19740 (eval $ac_try) 2>&5
19741 ac_status=$?
19742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19743 (exit $ac_status); }; }; then
19744 ac_header_compiler=yes
925c2f3f 19745else
c0d27fcc 19746 echo "$as_me: failed program was:" >&5
19650fd6
AS
19747sed 's/^/| /' conftest.$ac_ext >&5
19748
c0d27fcc
MR
19749ac_header_compiler=no
19750fi
edfaf76d 19751rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19752echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19753echo "${ECHO_T}$ac_header_compiler" >&6
19754
19755# Is the header present?
19756echo "$as_me:$LINENO: checking $ac_header presence" >&5
19757echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19758cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19759/* confdefs.h. */
19760_ACEOF
19761cat confdefs.h >>conftest.$ac_ext
19762cat >>conftest.$ac_ext <<_ACEOF
19763/* end confdefs.h. */
503d2be0
AS
19764#include <$ac_header>
19765_ACEOF
c0d27fcc 19766if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19767 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19768 ac_status=$?
6bae0ccf 19769 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19770 rm -f conftest.er1
19771 cat conftest.err >&5
c0d27fcc 19772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19773 (exit $ac_status); } >/dev/null; then
19774 if test -s conftest.err; then
19775 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19776 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19777 else
19778 ac_cpp_err=
19779 fi
19780else
19781 ac_cpp_err=yes
19782fi
19783if test -z "$ac_cpp_err"; then
c0d27fcc 19784 ac_header_preproc=yes
503d2be0
AS
19785else
19786 echo "$as_me: failed program was:" >&5
19650fd6
AS
19787sed 's/^/| /' conftest.$ac_ext >&5
19788
c0d27fcc 19789 ac_header_preproc=no
a21616bd 19790fi
503d2be0 19791rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19792echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19793echo "${ECHO_T}$ac_header_preproc" >&6
19794
19795# So? What about this header?
edfaf76d
LK
19796case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19797 yes:no: )
c0d27fcc
MR
19798 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19799echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19800 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19801echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19802 ac_header_preproc=yes
19650fd6 19803 ;;
edfaf76d 19804 no:yes:* )
c0d27fcc
MR
19805 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19806echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19807 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19808echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19809 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19810echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19811 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19812echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19813 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19814echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19815 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19816echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19817 (
19818 cat <<\_ASBOX
edfaf76d
LK
19819## ------------------------------------------ ##
19820## Report this to the AC_PACKAGE_NAME lists. ##
19821## ------------------------------------------ ##
19650fd6
AS
19822_ASBOX
19823 ) |
19824 sed "s/^/$as_me: WARNING: /" >&2
19825 ;;
c0d27fcc
MR
19826esac
19827echo "$as_me:$LINENO: checking for $ac_header" >&5
19828echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19829if eval "test \"\${$as_ac_Header+set}\" = set"; then
19830 echo $ECHO_N "(cached) $ECHO_C" >&6
19831else
edfaf76d 19832 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19833fi
c0d27fcc 19834echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19835echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19836
19837fi
503d2be0 19838if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19839 cat >>confdefs.h <<_ACEOF
503d2be0 19840#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19841_ACEOF
503d2be0 19842
a21616bd 19843else
503d2be0
AS
19844
19845for ac_header in kerberosIV/krb.h
a21616bd 19846do
503d2be0 19847as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19848if eval "test \"\${$as_ac_Header+set}\" = set"; then
19849 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19850echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19851if eval "test \"\${$as_ac_Header+set}\" = set"; then
19852 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19853fi
19854echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19855echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19856else
c0d27fcc
MR
19857 # Is the header compilable?
19858echo "$as_me:$LINENO: checking $ac_header usability" >&5
19859echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19860cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19861/* confdefs.h. */
19862_ACEOF
19863cat confdefs.h >>conftest.$ac_ext
19864cat >>conftest.$ac_ext <<_ACEOF
19865/* end confdefs.h. */
c0d27fcc
MR
19866$ac_includes_default
19867#include <$ac_header>
19868_ACEOF
19869rm -f conftest.$ac_objext
19870if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 19871 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19872 ac_status=$?
edfaf76d
LK
19873 grep -v '^ *+' conftest.er1 >conftest.err
19874 rm -f conftest.er1
19875 cat conftest.err >&5
c0d27fcc
MR
19876 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19877 (exit $ac_status); } &&
10a3b1a1
EZ
19878 { ac_try='test -z "$ac_c_werror_flag"
19879 || test ! -s conftest.err'
edfaf76d
LK
19880 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19881 (eval $ac_try) 2>&5
19882 ac_status=$?
19883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19884 (exit $ac_status); }; } &&
19885 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19886 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19887 (eval $ac_try) 2>&5
19888 ac_status=$?
19889 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19890 (exit $ac_status); }; }; then
19891 ac_header_compiler=yes
19892else
19893 echo "$as_me: failed program was:" >&5
19650fd6
AS
19894sed 's/^/| /' conftest.$ac_ext >&5
19895
c0d27fcc
MR
19896ac_header_compiler=no
19897fi
edfaf76d 19898rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19899echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19900echo "${ECHO_T}$ac_header_compiler" >&6
19901
19902# Is the header present?
19903echo "$as_me:$LINENO: checking $ac_header presence" >&5
19904echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19905cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19906/* confdefs.h. */
19907_ACEOF
19908cat confdefs.h >>conftest.$ac_ext
19909cat >>conftest.$ac_ext <<_ACEOF
19910/* end confdefs.h. */
503d2be0
AS
19911#include <$ac_header>
19912_ACEOF
c0d27fcc 19913if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19914 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19915 ac_status=$?
6bae0ccf 19916 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19917 rm -f conftest.er1
19918 cat conftest.err >&5
c0d27fcc 19919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19920 (exit $ac_status); } >/dev/null; then
19921 if test -s conftest.err; then
19922 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 19923 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19924 else
19925 ac_cpp_err=
19926 fi
19927else
19928 ac_cpp_err=yes
19929fi
19930if test -z "$ac_cpp_err"; then
c0d27fcc 19931 ac_header_preproc=yes
503d2be0
AS
19932else
19933 echo "$as_me: failed program was:" >&5
19650fd6
AS
19934sed 's/^/| /' conftest.$ac_ext >&5
19935
c0d27fcc 19936 ac_header_preproc=no
a21616bd 19937fi
503d2be0 19938rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19939echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19940echo "${ECHO_T}$ac_header_preproc" >&6
19941
19942# So? What about this header?
edfaf76d
LK
19943case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19944 yes:no: )
c0d27fcc
MR
19945 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19946echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
19947 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19948echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19949 ac_header_preproc=yes
19650fd6 19950 ;;
edfaf76d 19951 no:yes:* )
c0d27fcc
MR
19952 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19953echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
19954 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19955echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19956 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19957echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19958 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19959echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19960 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19961echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
19962 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19963echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19964 (
19965 cat <<\_ASBOX
edfaf76d
LK
19966## ------------------------------------------ ##
19967## Report this to the AC_PACKAGE_NAME lists. ##
19968## ------------------------------------------ ##
19650fd6
AS
19969_ASBOX
19970 ) |
19971 sed "s/^/$as_me: WARNING: /" >&2
19972 ;;
c0d27fcc
MR
19973esac
19974echo "$as_me:$LINENO: checking for $ac_header" >&5
19975echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19976if eval "test \"\${$as_ac_Header+set}\" = set"; then
19977 echo $ECHO_N "(cached) $ECHO_C" >&6
19978else
edfaf76d 19979 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19980fi
c0d27fcc 19981echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19982echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19983
19984fi
503d2be0 19985if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19986 cat >>confdefs.h <<_ACEOF
503d2be0 19987#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19988_ACEOF
503d2be0 19989
a21616bd 19990else
503d2be0
AS
19991
19992for ac_header in kerberos/krb.h
a21616bd 19993do
503d2be0 19994as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19995if eval "test \"\${$as_ac_Header+set}\" = set"; then
19996 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19997echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19998if eval "test \"\${$as_ac_Header+set}\" = set"; then
19999 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20000fi
20001echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20002echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 20003else
c0d27fcc
MR
20004 # Is the header compilable?
20005echo "$as_me:$LINENO: checking $ac_header usability" >&5
20006echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20007cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20008/* confdefs.h. */
20009_ACEOF
20010cat confdefs.h >>conftest.$ac_ext
20011cat >>conftest.$ac_ext <<_ACEOF
20012/* end confdefs.h. */
c0d27fcc
MR
20013$ac_includes_default
20014#include <$ac_header>
20015_ACEOF
20016rm -f conftest.$ac_objext
20017if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 20018 (eval $ac_compile) 2>conftest.er1
c0d27fcc 20019 ac_status=$?
edfaf76d
LK
20020 grep -v '^ *+' conftest.er1 >conftest.err
20021 rm -f conftest.er1
20022 cat conftest.err >&5
c0d27fcc
MR
20023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20024 (exit $ac_status); } &&
10a3b1a1
EZ
20025 { ac_try='test -z "$ac_c_werror_flag"
20026 || test ! -s conftest.err'
edfaf76d
LK
20027 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20028 (eval $ac_try) 2>&5
20029 ac_status=$?
20030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20031 (exit $ac_status); }; } &&
20032 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20034 (eval $ac_try) 2>&5
20035 ac_status=$?
20036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20037 (exit $ac_status); }; }; then
20038 ac_header_compiler=yes
20039else
20040 echo "$as_me: failed program was:" >&5
19650fd6
AS
20041sed 's/^/| /' conftest.$ac_ext >&5
20042
c0d27fcc
MR
20043ac_header_compiler=no
20044fi
edfaf76d 20045rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20046echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20047echo "${ECHO_T}$ac_header_compiler" >&6
20048
20049# Is the header present?
20050echo "$as_me:$LINENO: checking $ac_header presence" >&5
20051echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20052cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20053/* confdefs.h. */
20054_ACEOF
20055cat confdefs.h >>conftest.$ac_ext
20056cat >>conftest.$ac_ext <<_ACEOF
20057/* end confdefs.h. */
503d2be0
AS
20058#include <$ac_header>
20059_ACEOF
c0d27fcc 20060if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20061 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20062 ac_status=$?
6bae0ccf 20063 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20064 rm -f conftest.er1
20065 cat conftest.err >&5
c0d27fcc 20066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20067 (exit $ac_status); } >/dev/null; then
20068 if test -s conftest.err; then
20069 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 20070 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20071 else
20072 ac_cpp_err=
20073 fi
20074else
20075 ac_cpp_err=yes
20076fi
20077if test -z "$ac_cpp_err"; then
c0d27fcc 20078 ac_header_preproc=yes
503d2be0
AS
20079else
20080 echo "$as_me: failed program was:" >&5
19650fd6
AS
20081sed 's/^/| /' conftest.$ac_ext >&5
20082
c0d27fcc 20083 ac_header_preproc=no
a21616bd 20084fi
503d2be0 20085rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20086echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20087echo "${ECHO_T}$ac_header_preproc" >&6
35996d22
AS
20088
20089# So? What about this header?
edfaf76d
LK
20090case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20091 yes:no: )
35996d22
AS
20092 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20093echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
20094 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20095echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20096 ac_header_preproc=yes
19650fd6 20097 ;;
edfaf76d 20098 no:yes:* )
c0d27fcc
MR
20099 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20100echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
20101 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20102echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20103 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20104echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20105 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20106echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20107 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 20108echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
20109 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20110echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20111 (
20112 cat <<\_ASBOX
edfaf76d
LK
20113## ------------------------------------------ ##
20114## Report this to the AC_PACKAGE_NAME lists. ##
20115## ------------------------------------------ ##
19650fd6
AS
20116_ASBOX
20117 ) |
20118 sed "s/^/$as_me: WARNING: /" >&2
20119 ;;
c0d27fcc
MR
20120esac
20121echo "$as_me:$LINENO: checking for $ac_header" >&5
20122echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20123if eval "test \"\${$as_ac_Header+set}\" = set"; then
20124 echo $ECHO_N "(cached) $ECHO_C" >&6
20125else
edfaf76d 20126 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 20127fi
c0d27fcc 20128echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 20129echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
20130
20131fi
503d2be0 20132if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 20133 cat >>confdefs.h <<_ACEOF
503d2be0 20134#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 20135_ACEOF
503d2be0 20136
a21616bd 20137fi
c0d27fcc 20138
a21616bd
KR
20139done
20140
20141fi
c0d27fcc 20142
a21616bd
KR
20143done
20144
20145fi
c0d27fcc 20146
a21616bd
KR
20147done
20148
20149 fi
503d2be0
AS
20150
20151for ac_header in com_err.h
a21616bd 20152do
503d2be0 20153as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
20154if eval "test \"\${$as_ac_Header+set}\" = set"; then
20155 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
20156echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20157if eval "test \"\${$as_ac_Header+set}\" = set"; then
20158 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20159fi
20160echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20161echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 20162else
c0d27fcc
MR
20163 # Is the header compilable?
20164echo "$as_me:$LINENO: checking $ac_header usability" >&5
20165echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20166cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20167/* confdefs.h. */
20168_ACEOF
20169cat confdefs.h >>conftest.$ac_ext
20170cat >>conftest.$ac_ext <<_ACEOF
20171/* end confdefs.h. */
c0d27fcc
MR
20172$ac_includes_default
20173#include <$ac_header>
20174_ACEOF
20175rm -f conftest.$ac_objext
20176if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d
LK
20177 (eval $ac_compile) 2>conftest.er1
20178 ac_status=$?
20179 grep -v '^ *+' conftest.er1 >conftest.err
20180 rm -f conftest.er1
20181 cat conftest.err >&5
20182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20183 (exit $ac_status); } &&
10a3b1a1
EZ
20184 { ac_try='test -z "$ac_c_werror_flag"
20185 || test ! -s conftest.err'
edfaf76d
LK
20186 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20187 (eval $ac_try) 2>&5
35996d22
AS
20188 ac_status=$?
20189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
edfaf76d
LK
20190 (exit $ac_status); }; } &&
20191 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20192 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20193 (eval $ac_try) 2>&5
20194 ac_status=$?
20195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20196 (exit $ac_status); }; }; then
20197 ac_header_compiler=yes
20198else
20199 echo "$as_me: failed program was:" >&5
19650fd6
AS
20200sed 's/^/| /' conftest.$ac_ext >&5
20201
c0d27fcc
MR
20202ac_header_compiler=no
20203fi
edfaf76d 20204rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20205echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20206echo "${ECHO_T}$ac_header_compiler" >&6
20207
20208# Is the header present?
20209echo "$as_me:$LINENO: checking $ac_header presence" >&5
20210echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20211cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20212/* confdefs.h. */
20213_ACEOF
20214cat confdefs.h >>conftest.$ac_ext
20215cat >>conftest.$ac_ext <<_ACEOF
20216/* end confdefs.h. */
503d2be0
AS
20217#include <$ac_header>
20218_ACEOF
c0d27fcc 20219if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20220 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20221 ac_status=$?
6bae0ccf 20222 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20223 rm -f conftest.er1
20224 cat conftest.err >&5
c0d27fcc 20225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20226 (exit $ac_status); } >/dev/null; then
20227 if test -s conftest.err; then
20228 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 20229 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20230 else
20231 ac_cpp_err=
20232 fi
20233else
20234 ac_cpp_err=yes
20235fi
20236if test -z "$ac_cpp_err"; then
c0d27fcc 20237 ac_header_preproc=yes
503d2be0
AS
20238else
20239 echo "$as_me: failed program was:" >&5
19650fd6
AS
20240sed 's/^/| /' conftest.$ac_ext >&5
20241
c0d27fcc 20242 ac_header_preproc=no
a21616bd 20243fi
503d2be0 20244rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20245echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20246echo "${ECHO_T}$ac_header_preproc" >&6
20247
20248# So? What about this header?
edfaf76d
LK
20249case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20250 yes:no: )
c0d27fcc
MR
20251 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20252echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
20253 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20254echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20255 ac_header_preproc=yes
19650fd6 20256 ;;
edfaf76d 20257 no:yes:* )
c0d27fcc
MR
20258 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20259echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
20260 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20261echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20262 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20263echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20264 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20265echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20266 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 20267echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
20268 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20269echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20270 (
20271 cat <<\_ASBOX
edfaf76d
LK
20272## ------------------------------------------ ##
20273## Report this to the AC_PACKAGE_NAME lists. ##
20274## ------------------------------------------ ##
19650fd6
AS
20275_ASBOX
20276 ) |
20277 sed "s/^/$as_me: WARNING: /" >&2
20278 ;;
c0d27fcc
MR
20279esac
20280echo "$as_me:$LINENO: checking for $ac_header" >&5
20281echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20282if eval "test \"\${$as_ac_Header+set}\" = set"; then
20283 echo $ECHO_N "(cached) $ECHO_C" >&6
20284else
edfaf76d 20285 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 20286fi
c0d27fcc 20287echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 20288echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
20289
20290fi
503d2be0 20291if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 20292 cat >>confdefs.h <<_ACEOF
503d2be0 20293#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 20294_ACEOF
503d2be0 20295
a21616bd 20296fi
c0d27fcc 20297
a21616bd
KR
20298done
20299
20300fi
20301
ba4481b5
DL
20302# Solaris requires -lintl if you want strerror (which calls dgettext)
20303# to return localized messages.
503d2be0 20304
c0d27fcc 20305echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
20306echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
20307if test "${ac_cv_lib_intl_dgettext+set}" = set; then
20308 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 20309else
503d2be0 20310 ac_check_lib_save_LIBS=$LIBS
ba4481b5 20311LIBS="-lintl $LIBS"
503d2be0 20312cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20313/* confdefs.h. */
20314_ACEOF
20315cat confdefs.h >>conftest.$ac_ext
20316cat >>conftest.$ac_ext <<_ACEOF
20317/* end confdefs.h. */
503d2be0 20318
ba4481b5 20319/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20320#ifdef __cplusplus
20321extern "C"
20322#endif
ba4481b5 20323/* We use char because int might match the return type of a gcc2
503d2be0
AS
20324 builtin and then its argument prototype would still apply. */
20325char dgettext ();
20326int
20327main ()
20328{
20329dgettext ();
20330 ;
20331 return 0;
20332}
20333_ACEOF
20334rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20335if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 20336 (eval $ac_link) 2>conftest.er1
503d2be0 20337 ac_status=$?
edfaf76d
LK
20338 grep -v '^ *+' conftest.er1 >conftest.err
20339 rm -f conftest.er1
20340 cat conftest.err >&5
c0d27fcc 20341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20342 (exit $ac_status); } &&
10a3b1a1
EZ
20343 { ac_try='test -z "$ac_c_werror_flag"
20344 || test ! -s conftest.err'
edfaf76d
LK
20345 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20346 (eval $ac_try) 2>&5
20347 ac_status=$?
20348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20349 (exit $ac_status); }; } &&
20350 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 20351 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20352 (eval $ac_try) 2>&5
20353 ac_status=$?
c0d27fcc 20354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20355 (exit $ac_status); }; }; then
20356 ac_cv_lib_intl_dgettext=yes
20357else
20358 echo "$as_me: failed program was:" >&5
19650fd6
AS
20359sed 's/^/| /' conftest.$ac_ext >&5
20360
503d2be0
AS
20361ac_cv_lib_intl_dgettext=no
20362fi
edfaf76d
LK
20363rm -f conftest.err conftest.$ac_objext \
20364 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
20365LIBS=$ac_check_lib_save_LIBS
20366fi
c0d27fcc 20367echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
20368echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
20369if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 20370 cat >>confdefs.h <<_ACEOF
503d2be0 20371#define HAVE_LIBINTL 1
c0d27fcc 20372_ACEOF
ba4481b5
DL
20373
20374 LIBS="-lintl $LIBS"
20375
ba4481b5
DL
20376fi
20377
c0d27fcc
MR
20378
20379echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
20380echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
20381if test "${emacs_cv_localtime_cache+set}" = set; then
20382 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
20383else
20384 if test x$ac_cv_func_tzset = xyes; then
20385if test "$cross_compiling" = yes; then
20386 # If we have tzset, assume the worst when cross-compiling.
20387emacs_cv_localtime_cache=yes
20388else
503d2be0 20389 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20390/* confdefs.h. */
20391_ACEOF
20392cat confdefs.h >>conftest.$ac_ext
20393cat >>conftest.$ac_ext <<_ACEOF
20394/* end confdefs.h. */
ba4481b5 20395#include <time.h>
ba4481b5
DL
20396extern char **environ;
20397unset_TZ ()
20398{
20399 char **from, **to;
20400 for (to = from = environ; (*to = *from); from++)
20401 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
20402 to++;
20403}
20404char TZ_GMT0[] = "TZ=GMT0";
20405char TZ_PST8[] = "TZ=PST8";
20406main()
20407{
20408 time_t now = time ((time_t *) 0);
20409 int hour_GMT0, hour_unset;
20410 if (putenv (TZ_GMT0) != 0)
20411 exit (1);
20412 hour_GMT0 = localtime (&now)->tm_hour;
20413 unset_TZ ();
20414 hour_unset = localtime (&now)->tm_hour;
20415 if (putenv (TZ_PST8) != 0)
20416 exit (1);
20417 if (localtime (&now)->tm_hour == hour_GMT0)
20418 exit (1);
20419 unset_TZ ();
20420 if (localtime (&now)->tm_hour != hour_unset)
20421 exit (1);
20422 exit (0);
20423}
503d2be0
AS
20424_ACEOF
20425rm -f conftest$ac_exeext
c0d27fcc 20426if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20427 (eval $ac_link) 2>&5
20428 ac_status=$?
c0d27fcc 20429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20430 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20431 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20432 (eval $ac_try) 2>&5
20433 ac_status=$?
c0d27fcc 20434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20435 (exit $ac_status); }; }; then
ba4481b5
DL
20436 emacs_cv_localtime_cache=no
20437else
503d2be0
AS
20438 echo "$as_me: program exited with status $ac_status" >&5
20439echo "$as_me: failed program was:" >&5
19650fd6
AS
20440sed 's/^/| /' conftest.$ac_ext >&5
20441
c0d27fcc 20442( exit $ac_status )
503d2be0 20443emacs_cv_localtime_cache=yes
ba4481b5 20444fi
edfaf76d 20445rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 20446fi
ba4481b5
DL
20447else
20448 # If we lack tzset, report that localtime does not cache TZ,
20449 # since we can't invalidate the cache if we don't have tzset.
20450 emacs_cv_localtime_cache=no
20451fi
20452fi
c0d27fcc 20453echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 20454echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 20455if test $emacs_cv_localtime_cache = yes; then
b936fae4 20456
c0d27fcc 20457cat >>confdefs.h <<\_ACEOF
ba4481b5 20458#define LOCALTIME_CACHE 1
c0d27fcc 20459_ACEOF
ba4481b5
DL
20460
20461fi
20462
20463if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
20464
20465for ac_func in gettimeofday
48d4b120 20466do
503d2be0 20467as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 20468echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
20469echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
20470if eval "test \"\${$as_ac_var+set}\" = set"; then
20471 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 20472else
503d2be0 20473 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20474/* confdefs.h. */
20475_ACEOF
20476cat confdefs.h >>conftest.$ac_ext
20477cat >>conftest.$ac_ext <<_ACEOF
20478/* end confdefs.h. */
edfaf76d
LK
20479/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20480 For example, HP-UX 11i <limits.h> declares gettimeofday. */
20481#define $ac_func innocuous_$ac_func
20482
48d4b120 20483/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
20484 which can conflict with char $ac_func (); below.
20485 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20486 <limits.h> exists even on freestanding compilers. */
edfaf76d 20487
19650fd6
AS
20488#ifdef __STDC__
20489# include <limits.h>
20490#else
20491# include <assert.h>
20492#endif
edfaf76d
LK
20493
20494#undef $ac_func
20495
48d4b120 20496/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20497#ifdef __cplusplus
20498extern "C"
19650fd6 20499{
503d2be0 20500#endif
48d4b120 20501/* We use char because int might match the return type of a gcc2
503d2be0
AS
20502 builtin and then its argument prototype would still apply. */
20503char $ac_func ();
48d4b120
DL
20504/* The GNU C library defines this for functions which it implements
20505 to always fail with ENOSYS. Some functions are actually named
20506 something starting with __ and the normal name is an alias. */
20507#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
20508choke me
20509#else
19650fd6
AS
20510char (*f) () = $ac_func;
20511#endif
20512#ifdef __cplusplus
20513}
cd958eb3
MB
20514#endif
20515
19650fd6
AS
20516int
20517main ()
20518{
20519return f != $ac_func;
503d2be0
AS
20520 ;
20521 return 0;
20522}
20523_ACEOF
20524rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20525if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 20526 (eval $ac_link) 2>conftest.er1
503d2be0 20527 ac_status=$?
edfaf76d
LK
20528 grep -v '^ *+' conftest.er1 >conftest.err
20529 rm -f conftest.er1
20530 cat conftest.err >&5
c0d27fcc 20531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20532 (exit $ac_status); } &&
10a3b1a1
EZ
20533 { ac_try='test -z "$ac_c_werror_flag"
20534 || test ! -s conftest.err'
edfaf76d
LK
20535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20536 (eval $ac_try) 2>&5
20537 ac_status=$?
20538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20539 (exit $ac_status); }; } &&
20540 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 20541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20542 (eval $ac_try) 2>&5
20543 ac_status=$?
c0d27fcc 20544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20545 (exit $ac_status); }; }; then
20546 eval "$as_ac_var=yes"
20547else
20548 echo "$as_me: failed program was:" >&5
19650fd6
AS
20549sed 's/^/| /' conftest.$ac_ext >&5
20550
503d2be0
AS
20551eval "$as_ac_var=no"
20552fi
edfaf76d
LK
20553rm -f conftest.err conftest.$ac_objext \
20554 conftest$ac_exeext conftest.$ac_ext
503d2be0 20555fi
c0d27fcc 20556echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
20557echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
20558if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 20559 cat >>confdefs.h <<_ACEOF
503d2be0 20560#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 20561_ACEOF
48d4b120 20562
48d4b120
DL
20563fi
20564done
20565
b936fae4 20566 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 20567 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
20568echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
20569if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
20570 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 20571else
503d2be0 20572 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20573/* confdefs.h. */
20574_ACEOF
20575cat confdefs.h >>conftest.$ac_ext
20576cat >>conftest.$ac_ext <<_ACEOF
20577/* end confdefs.h. */
ba4481b5 20578
a3f08d9e
DL
20579#ifdef TIME_WITH_SYS_TIME
20580#include <sys/time.h>
20581#include <time.h>
20582#else
20583#ifdef HAVE_SYS_TIME_H
20584#include <sys/time.h>
20585#else
20586#include <time.h>
20587#endif
20588#endif
503d2be0
AS
20589int
20590main ()
20591{
a3f08d9e 20592struct timeval time;
b936fae4 20593 gettimeofday (&time, 0);
503d2be0
AS
20594 ;
20595 return 0;
20596}
20597_ACEOF
20598rm -f conftest.$ac_objext
c0d27fcc 20599if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 20600 (eval $ac_compile) 2>conftest.er1
503d2be0 20601 ac_status=$?
edfaf76d
LK
20602 grep -v '^ *+' conftest.er1 >conftest.err
20603 rm -f conftest.er1
20604 cat conftest.err >&5
c0d27fcc 20605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20606 (exit $ac_status); } &&
10a3b1a1
EZ
20607 { ac_try='test -z "$ac_c_werror_flag"
20608 || test ! -s conftest.err'
edfaf76d
LK
20609 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20610 (eval $ac_try) 2>&5
20611 ac_status=$?
20612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20613 (exit $ac_status); }; } &&
20614 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20615 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20616 (eval $ac_try) 2>&5
20617 ac_status=$?
c0d27fcc 20618 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20619 (exit $ac_status); }; }; then
ba4481b5
DL
20620 emacs_cv_gettimeofday_two_arguments=yes
20621else
503d2be0 20622 echo "$as_me: failed program was:" >&5
19650fd6
AS
20623sed 's/^/| /' conftest.$ac_ext >&5
20624
503d2be0 20625emacs_cv_gettimeofday_two_arguments=no
ba4481b5 20626fi
edfaf76d 20627rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 20628fi
c0d27fcc 20629echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 20630echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
20631 if test $emacs_cv_gettimeofday_two_arguments = no; then
20632
c0d27fcc 20633cat >>confdefs.h <<\_ACEOF
ba4481b5 20634#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 20635_ACEOF
ba4481b5 20636
b936fae4 20637 fi
ba4481b5
DL
20638 fi
20639fi
20640
973a76b1
DL
20641# This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
20642echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
20643echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
20644if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
20645 echo $ECHO_N "(cached) $ECHO_C" >&6
20646else
20647 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20648/* confdefs.h. */
20649_ACEOF
20650cat confdefs.h >>conftest.$ac_ext
20651cat >>conftest.$ac_ext <<_ACEOF
20652/* end confdefs.h. */
973a76b1
DL
20653#include <sys/types.h>
20654#include <$ac_cv_struct_tm>
20655
20656
20657int
20658main ()
20659{
20660static struct tm ac_aggr;
20661if (ac_aggr.tm_zone)
20662return 0;
20663 ;
20664 return 0;
20665}
20666_ACEOF
20667rm -f conftest.$ac_objext
20668if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 20669 (eval $ac_compile) 2>conftest.er1
973a76b1 20670 ac_status=$?
edfaf76d
LK
20671 grep -v '^ *+' conftest.er1 >conftest.err
20672 rm -f conftest.er1
20673 cat conftest.err >&5
973a76b1
DL
20674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20675 (exit $ac_status); } &&
10a3b1a1
EZ
20676 { ac_try='test -z "$ac_c_werror_flag"
20677 || test ! -s conftest.err'
edfaf76d
LK
20678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20679 (eval $ac_try) 2>&5
20680 ac_status=$?
20681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20682 (exit $ac_status); }; } &&
20683 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
20684 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20685 (eval $ac_try) 2>&5
20686 ac_status=$?
20687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20688 (exit $ac_status); }; }; then
20689 ac_cv_member_struct_tm_tm_zone=yes
20690else
20691 echo "$as_me: failed program was:" >&5
19650fd6
AS
20692sed 's/^/| /' conftest.$ac_ext >&5
20693
973a76b1 20694cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20695/* confdefs.h. */
20696_ACEOF
20697cat confdefs.h >>conftest.$ac_ext
20698cat >>conftest.$ac_ext <<_ACEOF
20699/* end confdefs.h. */
973a76b1
DL
20700#include <sys/types.h>
20701#include <$ac_cv_struct_tm>
20702
20703
20704int
20705main ()
20706{
20707static struct tm ac_aggr;
20708if (sizeof ac_aggr.tm_zone)
20709return 0;
20710 ;
20711 return 0;
20712}
20713_ACEOF
20714rm -f conftest.$ac_objext
20715if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 20716 (eval $ac_compile) 2>conftest.er1
973a76b1 20717 ac_status=$?
edfaf76d
LK
20718 grep -v '^ *+' conftest.er1 >conftest.err
20719 rm -f conftest.er1
20720 cat conftest.err >&5
973a76b1
DL
20721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20722 (exit $ac_status); } &&
10a3b1a1
EZ
20723 { ac_try='test -z "$ac_c_werror_flag"
20724 || test ! -s conftest.err'
edfaf76d
LK
20725 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20726 (eval $ac_try) 2>&5
20727 ac_status=$?
20728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20729 (exit $ac_status); }; } &&
20730 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
20731 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20732 (eval $ac_try) 2>&5
20733 ac_status=$?
20734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20735 (exit $ac_status); }; }; then
20736 ac_cv_member_struct_tm_tm_zone=yes
20737else
20738 echo "$as_me: failed program was:" >&5
19650fd6
AS
20739sed 's/^/| /' conftest.$ac_ext >&5
20740
973a76b1
DL
20741ac_cv_member_struct_tm_tm_zone=no
20742fi
edfaf76d 20743rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1 20744fi
edfaf76d 20745rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
20746fi
20747echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
20748echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
20749if test $ac_cv_member_struct_tm_tm_zone = yes; then
20750
20751cat >>confdefs.h <<_ACEOF
20752#define HAVE_STRUCT_TM_TM_ZONE 1
20753_ACEOF
20754
20755
20756fi
20757
20758if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
20759
20760cat >>confdefs.h <<\_ACEOF
20761#define HAVE_TM_ZONE 1
20762_ACEOF
20763
20764else
20765 echo "$as_me:$LINENO: checking for tzname" >&5
20766echo $ECHO_N "checking for tzname... $ECHO_C" >&6
20767if test "${ac_cv_var_tzname+set}" = set; then
20768 echo $ECHO_N "(cached) $ECHO_C" >&6
20769else
20770 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20771/* confdefs.h. */
20772_ACEOF
20773cat confdefs.h >>conftest.$ac_ext
20774cat >>conftest.$ac_ext <<_ACEOF
20775/* end confdefs.h. */
973a76b1
DL
20776#include <time.h>
20777#ifndef tzname /* For SGI. */
20778extern char *tzname[]; /* RS6000 and others reject char **tzname. */
20779#endif
20780
20781int
20782main ()
20783{
20784atoi(*tzname);
20785 ;
20786 return 0;
20787}
20788_ACEOF
20789rm -f conftest.$ac_objext conftest$ac_exeext
20790if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 20791 (eval $ac_link) 2>conftest.er1
973a76b1 20792 ac_status=$?
edfaf76d
LK
20793 grep -v '^ *+' conftest.er1 >conftest.err
20794 rm -f conftest.er1
20795 cat conftest.err >&5
973a76b1
DL
20796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20797 (exit $ac_status); } &&
10a3b1a1
EZ
20798 { ac_try='test -z "$ac_c_werror_flag"
20799 || test ! -s conftest.err'
edfaf76d
LK
20800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20801 (eval $ac_try) 2>&5
20802 ac_status=$?
20803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20804 (exit $ac_status); }; } &&
20805 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
20806 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20807 (eval $ac_try) 2>&5
20808 ac_status=$?
20809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20810 (exit $ac_status); }; }; then
20811 ac_cv_var_tzname=yes
20812else
20813 echo "$as_me: failed program was:" >&5
19650fd6
AS
20814sed 's/^/| /' conftest.$ac_ext >&5
20815
973a76b1
DL
20816ac_cv_var_tzname=no
20817fi
edfaf76d
LK
20818rm -f conftest.err conftest.$ac_objext \
20819 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
20820fi
20821echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
20822echo "${ECHO_T}$ac_cv_var_tzname" >&6
20823 if test $ac_cv_var_tzname = yes; then
20824
20825cat >>confdefs.h <<\_ACEOF
20826#define HAVE_TZNAME 1
20827_ACEOF
20828
20829 fi
20830fi
20831
20832
48d4b120 20833if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 20834 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
20835echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
20836if test "${emacs_cv_struct_timezone+set}" = set; then
20837 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 20838else
503d2be0 20839 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20840/* confdefs.h. */
20841_ACEOF
20842cat confdefs.h >>conftest.$ac_ext
20843cat >>conftest.$ac_ext <<_ACEOF
20844/* end confdefs.h. */
48d4b120 20845#include <sys/time.h>
503d2be0
AS
20846int
20847main ()
20848{
48d4b120 20849struct timezone tz;
503d2be0
AS
20850 ;
20851 return 0;
20852}
20853_ACEOF
20854rm -f conftest.$ac_objext
c0d27fcc 20855if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 20856 (eval $ac_compile) 2>conftest.er1
503d2be0 20857 ac_status=$?
edfaf76d
LK
20858 grep -v '^ *+' conftest.er1 >conftest.err
20859 rm -f conftest.er1
20860 cat conftest.err >&5
c0d27fcc 20861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20862 (exit $ac_status); } &&
10a3b1a1
EZ
20863 { ac_try='test -z "$ac_c_werror_flag"
20864 || test ! -s conftest.err'
edfaf76d
LK
20865 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20866 (eval $ac_try) 2>&5
20867 ac_status=$?
20868 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20869 (exit $ac_status); }; } &&
20870 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20871 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20872 (eval $ac_try) 2>&5
20873 ac_status=$?
c0d27fcc 20874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20875 (exit $ac_status); }; }; then
48d4b120
DL
20876 if test "$cross_compiling" = yes; then
20877 emacs_cv_struct_timezone=yes
20878else
503d2be0 20879 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20880/* confdefs.h. */
20881_ACEOF
20882cat confdefs.h >>conftest.$ac_ext
20883cat >>conftest.$ac_ext <<_ACEOF
20884/* end confdefs.h. */
48d4b120
DL
20885
20886#ifdef TIME_WITH_SYS_TIME
20887#include <sys/time.h>
20888#include <time.h>
20889#else
20890#ifdef HAVE_SYS_TIME_H
20891#include <sys/time.h>
20892#else
20893#include <time.h>
20894#endif
20895#endif
20896main () {
20897 struct timeval time;
20898 struct timezone dummy;
20899 exit (gettimeofday (&time, &dummy));
20900}
503d2be0
AS
20901_ACEOF
20902rm -f conftest$ac_exeext
c0d27fcc 20903if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20904 (eval $ac_link) 2>&5
20905 ac_status=$?
c0d27fcc 20906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20907 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20908 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20909 (eval $ac_try) 2>&5
20910 ac_status=$?
c0d27fcc 20911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20912 (exit $ac_status); }; }; then
48d4b120
DL
20913 emacs_cv_struct_timezone=yes
20914else
503d2be0
AS
20915 echo "$as_me: program exited with status $ac_status" >&5
20916echo "$as_me: failed program was:" >&5
19650fd6
AS
20917sed 's/^/| /' conftest.$ac_ext >&5
20918
c0d27fcc 20919( exit $ac_status )
503d2be0 20920emacs_cv_struct_timezone=no
48d4b120 20921fi
edfaf76d 20922rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 20923fi
48d4b120 20924else
503d2be0 20925 echo "$as_me: failed program was:" >&5
19650fd6
AS
20926sed 's/^/| /' conftest.$ac_ext >&5
20927
503d2be0 20928emacs_cv_struct_timezone=no
48d4b120 20929fi
edfaf76d 20930rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
48d4b120 20931fi
c0d27fcc 20932echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 20933echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
20934fi
20935
ba4481b5 20936ok_so_far=yes
c0d27fcc 20937echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
20938echo $ECHO_N "checking for socket... $ECHO_C" >&6
20939if test "${ac_cv_func_socket+set}" = set; then
20940 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 20941else
503d2be0 20942 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20943/* confdefs.h. */
20944_ACEOF
20945cat confdefs.h >>conftest.$ac_ext
20946cat >>conftest.$ac_ext <<_ACEOF
20947/* end confdefs.h. */
edfaf76d
LK
20948/* Define socket to an innocuous variant, in case <limits.h> declares socket.
20949 For example, HP-UX 11i <limits.h> declares gettimeofday. */
20950#define socket innocuous_socket
20951
ba4481b5 20952/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
20953 which can conflict with char socket (); below.
20954 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20955 <limits.h> exists even on freestanding compilers. */
edfaf76d 20956
19650fd6
AS
20957#ifdef __STDC__
20958# include <limits.h>
20959#else
20960# include <assert.h>
20961#endif
edfaf76d
LK
20962
20963#undef socket
20964
ba4481b5 20965/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20966#ifdef __cplusplus
20967extern "C"
19650fd6 20968{
503d2be0 20969#endif
ba4481b5 20970/* We use char because int might match the return type of a gcc2
503d2be0
AS
20971 builtin and then its argument prototype would still apply. */
20972char socket ();
ba4481b5
DL
20973/* The GNU C library defines this for functions which it implements
20974 to always fail with ENOSYS. Some functions are actually named
20975 something starting with __ and the normal name is an alias. */
20976#if defined (__stub_socket) || defined (__stub___socket)
20977choke me
20978#else
19650fd6
AS
20979char (*f) () = socket;
20980#endif
20981#ifdef __cplusplus
20982}
cd958eb3
MB
20983#endif
20984
19650fd6
AS
20985int
20986main ()
20987{
20988return f != socket;
503d2be0
AS
20989 ;
20990 return 0;
20991}
20992_ACEOF
20993rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20994if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 20995 (eval $ac_link) 2>conftest.er1
503d2be0 20996 ac_status=$?
edfaf76d
LK
20997 grep -v '^ *+' conftest.er1 >conftest.err
20998 rm -f conftest.er1
20999 cat conftest.err >&5
c0d27fcc 21000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 21001 (exit $ac_status); } &&
10a3b1a1
EZ
21002 { ac_try='test -z "$ac_c_werror_flag"
21003 || test ! -s conftest.err'
edfaf76d
LK
21004 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21005 (eval $ac_try) 2>&5
21006 ac_status=$?
21007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21008 (exit $ac_status); }; } &&
21009 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 21010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
21011 (eval $ac_try) 2>&5
21012 ac_status=$?
c0d27fcc 21013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21014 (exit $ac_status); }; }; then
21015 ac_cv_func_socket=yes
21016else
21017 echo "$as_me: failed program was:" >&5
19650fd6
AS
21018sed 's/^/| /' conftest.$ac_ext >&5
21019
503d2be0
AS
21020ac_cv_func_socket=no
21021fi
edfaf76d
LK
21022rm -f conftest.err conftest.$ac_objext \
21023 conftest$ac_exeext conftest.$ac_ext
503d2be0 21024fi
c0d27fcc 21025echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
21026echo "${ECHO_T}$ac_cv_func_socket" >&6
21027if test $ac_cv_func_socket = yes; then
ba4481b5
DL
21028 :
21029else
503d2be0 21030 ok_so_far=no
ba4481b5
DL
21031fi
21032
21033if test $ok_so_far = yes; then
c0d27fcc
MR
21034 if test "${ac_cv_header_netinet_in_h+set}" = set; then
21035 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
21036echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
21037if test "${ac_cv_header_netinet_in_h+set}" = set; then
21038 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
21039fi
21040echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
21041echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 21042else
c0d27fcc
MR
21043 # Is the header compilable?
21044echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
21045echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
21046cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21047/* confdefs.h. */
21048_ACEOF
21049cat confdefs.h >>conftest.$ac_ext
21050cat >>conftest.$ac_ext <<_ACEOF
21051/* end confdefs.h. */
c0d27fcc
MR
21052$ac_includes_default
21053#include <netinet/in.h>
21054_ACEOF
21055rm -f conftest.$ac_objext
21056if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 21057 (eval $ac_compile) 2>conftest.er1
c0d27fcc 21058 ac_status=$?
edfaf76d
LK
21059 grep -v '^ *+' conftest.er1 >conftest.err
21060 rm -f conftest.er1
21061 cat conftest.err >&5
c0d27fcc
MR
21062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21063 (exit $ac_status); } &&
10a3b1a1
EZ
21064 { ac_try='test -z "$ac_c_werror_flag"
21065 || test ! -s conftest.err'
edfaf76d
LK
21066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21067 (eval $ac_try) 2>&5
21068 ac_status=$?
21069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21070 (exit $ac_status); }; } &&
21071 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
21072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21073 (eval $ac_try) 2>&5
21074 ac_status=$?
21075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21076 (exit $ac_status); }; }; then
21077 ac_header_compiler=yes
21078else
21079 echo "$as_me: failed program was:" >&5
19650fd6
AS
21080sed 's/^/| /' conftest.$ac_ext >&5
21081
c0d27fcc
MR
21082ac_header_compiler=no
21083fi
edfaf76d 21084rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
21085echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21086echo "${ECHO_T}$ac_header_compiler" >&6
21087
21088# Is the header present?
21089echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
21090echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
21091cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21092/* confdefs.h. */
21093_ACEOF
21094cat confdefs.h >>conftest.$ac_ext
21095cat >>conftest.$ac_ext <<_ACEOF
21096/* end confdefs.h. */
ba4481b5 21097#include <netinet/in.h>
503d2be0 21098_ACEOF
c0d27fcc 21099if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
21100 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21101 ac_status=$?
6bae0ccf 21102 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
21103 rm -f conftest.er1
21104 cat conftest.err >&5
c0d27fcc 21105 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21106 (exit $ac_status); } >/dev/null; then
21107 if test -s conftest.err; then
21108 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 21109 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
21110 else
21111 ac_cpp_err=
21112 fi
21113else
21114 ac_cpp_err=yes
21115fi
21116if test -z "$ac_cpp_err"; then
c0d27fcc 21117 ac_header_preproc=yes
ba4481b5 21118else
503d2be0 21119 echo "$as_me: failed program was:" >&5
19650fd6
AS
21120sed 's/^/| /' conftest.$ac_ext >&5
21121
c0d27fcc 21122 ac_header_preproc=no
ba4481b5 21123fi
503d2be0 21124rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
21125echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21126echo "${ECHO_T}$ac_header_preproc" >&6
21127
21128# So? What about this header?
edfaf76d
LK
21129case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21130 yes:no: )
c0d27fcc
MR
21131 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
21132echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
21133 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the compiler's result" >&5
21134echo "$as_me: WARNING: netinet/in.h: proceeding with the compiler's result" >&2;}
21135 ac_header_preproc=yes
19650fd6 21136 ;;
edfaf76d 21137 no:yes:* )
c0d27fcc
MR
21138 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
21139echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
edfaf76d
LK
21140 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
21141echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
21142 { echo "$as_me:$LINENO: WARNING: netinet/in.h: see the Autoconf documentation" >&5
21143echo "$as_me: WARNING: netinet/in.h: see the Autoconf documentation" >&2;}
21144 { echo "$as_me:$LINENO: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&5
21145echo "$as_me: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 21146 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
19650fd6 21147echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
21148 { echo "$as_me:$LINENO: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&5
21149echo "$as_me: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
21150 (
21151 cat <<\_ASBOX
edfaf76d
LK
21152## ------------------------------------------ ##
21153## Report this to the AC_PACKAGE_NAME lists. ##
21154## ------------------------------------------ ##
19650fd6
AS
21155_ASBOX
21156 ) |
21157 sed "s/^/$as_me: WARNING: /" >&2
21158 ;;
c0d27fcc
MR
21159esac
21160echo "$as_me:$LINENO: checking for netinet/in.h" >&5
21161echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
21162if test "${ac_cv_header_netinet_in_h+set}" = set; then
21163 echo $ECHO_N "(cached) $ECHO_C" >&6
21164else
21165 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 21166fi
c0d27fcc 21167echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 21168echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
21169
21170fi
503d2be0 21171if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
21172 :
21173else
503d2be0 21174 ok_so_far=no
ba4481b5
DL
21175fi
21176
c0d27fcc 21177
ba4481b5
DL
21178fi
21179if test $ok_so_far = yes; then
c0d27fcc
MR
21180 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21181 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
21182echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
21183if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21184 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
21185fi
21186echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
21187echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 21188else
c0d27fcc
MR
21189 # Is the header compilable?
21190echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
21191echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
21192cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21193/* confdefs.h. */
21194_ACEOF
21195cat confdefs.h >>conftest.$ac_ext
21196cat >>conftest.$ac_ext <<_ACEOF
21197/* end confdefs.h. */
c0d27fcc
MR
21198$ac_includes_default
21199#include <arpa/inet.h>
21200_ACEOF
21201rm -f conftest.$ac_objext
21202if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 21203 (eval $ac_compile) 2>conftest.er1
c0d27fcc 21204 ac_status=$?
edfaf76d
LK
21205 grep -v '^ *+' conftest.er1 >conftest.err
21206 rm -f conftest.er1
21207 cat conftest.err >&5
c0d27fcc
MR
21208 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21209 (exit $ac_status); } &&
10a3b1a1
EZ
21210 { ac_try='test -z "$ac_c_werror_flag"
21211 || test ! -s conftest.err'
edfaf76d
LK
21212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21213 (eval $ac_try) 2>&5
21214 ac_status=$?
21215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21216 (exit $ac_status); }; } &&
21217 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
21218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21219 (eval $ac_try) 2>&5
21220 ac_status=$?
21221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21222 (exit $ac_status); }; }; then
21223 ac_header_compiler=yes
21224else
21225 echo "$as_me: failed program was:" >&5
19650fd6
AS
21226sed 's/^/| /' conftest.$ac_ext >&5
21227
c0d27fcc
MR
21228ac_header_compiler=no
21229fi
edfaf76d 21230rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
21231echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21232echo "${ECHO_T}$ac_header_compiler" >&6
21233
21234# Is the header present?
21235echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
21236echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
21237cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21238/* confdefs.h. */
21239_ACEOF
21240cat confdefs.h >>conftest.$ac_ext
21241cat >>conftest.$ac_ext <<_ACEOF
21242/* end confdefs.h. */
ba4481b5 21243#include <arpa/inet.h>
503d2be0 21244_ACEOF
c0d27fcc 21245if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
21246 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21247 ac_status=$?
6bae0ccf 21248 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
21249 rm -f conftest.er1
21250 cat conftest.err >&5
c0d27fcc 21251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21252 (exit $ac_status); } >/dev/null; then
21253 if test -s conftest.err; then
21254 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 21255 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
21256 else
21257 ac_cpp_err=
21258 fi
21259else
21260 ac_cpp_err=yes
21261fi
21262if test -z "$ac_cpp_err"; then
c0d27fcc 21263 ac_header_preproc=yes
ba4481b5 21264else
503d2be0 21265 echo "$as_me: failed program was:" >&5
19650fd6
AS
21266sed 's/^/| /' conftest.$ac_ext >&5
21267
c0d27fcc 21268 ac_header_preproc=no
ba4481b5 21269fi
503d2be0 21270rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
21271echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21272echo "${ECHO_T}$ac_header_preproc" >&6
21273
21274# So? What about this header?
edfaf76d
LK
21275case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21276 yes:no: )
c0d27fcc
MR
21277 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
21278echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
21279 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the compiler's result" >&5
21280echo "$as_me: WARNING: arpa/inet.h: proceeding with the compiler's result" >&2;}
21281 ac_header_preproc=yes
19650fd6 21282 ;;
edfaf76d 21283 no:yes:* )
c0d27fcc
MR
21284 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
21285echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
edfaf76d
LK
21286 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
21287echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
21288 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: see the Autoconf documentation" >&5
21289echo "$as_me: WARNING: arpa/inet.h: see the Autoconf documentation" >&2;}
21290 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&5
21291echo "$as_me: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 21292 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
19650fd6 21293echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
21294 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&5
21295echo "$as_me: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
21296 (
21297 cat <<\_ASBOX
edfaf76d
LK
21298## ------------------------------------------ ##
21299## Report this to the AC_PACKAGE_NAME lists. ##
21300## ------------------------------------------ ##
19650fd6
AS
21301_ASBOX
21302 ) |
21303 sed "s/^/$as_me: WARNING: /" >&2
21304 ;;
c0d27fcc
MR
21305esac
21306echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
21307echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
21308if test "${ac_cv_header_arpa_inet_h+set}" = set; then
21309 echo $ECHO_N "(cached) $ECHO_C" >&6
21310else
21311 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 21312fi
c0d27fcc 21313echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 21314echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
21315
21316fi
503d2be0 21317if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
21318 :
21319else
503d2be0 21320 ok_so_far=no
ba4481b5
DL
21321fi
21322
c0d27fcc 21323
ba4481b5
DL
21324fi
21325if test $ok_so_far = yes; then
b936fae4 21326
c0d27fcc 21327cat >>confdefs.h <<\_ACEOF
ba4481b5 21328#define HAVE_INET_SOCKETS 1
c0d27fcc 21329_ACEOF
ba4481b5
DL
21330
21331fi
21332
2d2b6695 21333
7862d3a8 21334for ac_header in sys/ioctl.h
2d2b6695
KS
21335do
21336as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
21337if eval "test \"\${$as_ac_Header+set}\" = set"; then
21338 echo "$as_me:$LINENO: checking for $ac_header" >&5
21339echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21340if eval "test \"\${$as_ac_Header+set}\" = set"; then
21341 echo $ECHO_N "(cached) $ECHO_C" >&6
21342fi
21343echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21344echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21345else
21346 # Is the header compilable?
21347echo "$as_me:$LINENO: checking $ac_header usability" >&5
21348echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21349cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
21350/* confdefs.h. */
21351_ACEOF
21352cat confdefs.h >>conftest.$ac_ext
21353cat >>conftest.$ac_ext <<_ACEOF
21354/* end confdefs.h. */
21355$ac_includes_default
21356#include <$ac_header>
21357_ACEOF
21358rm -f conftest.$ac_objext
21359if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 21360 (eval $ac_compile) 2>conftest.er1
2d2b6695 21361 ac_status=$?
edfaf76d
LK
21362 grep -v '^ *+' conftest.er1 >conftest.err
21363 rm -f conftest.er1
21364 cat conftest.err >&5
2d2b6695
KS
21365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21366 (exit $ac_status); } &&
10a3b1a1
EZ
21367 { ac_try='test -z "$ac_c_werror_flag"
21368 || test ! -s conftest.err'
edfaf76d
LK
21369 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21370 (eval $ac_try) 2>&5
21371 ac_status=$?
21372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21373 (exit $ac_status); }; } &&
21374 { ac_try='test -s conftest.$ac_objext'
2d2b6695
KS
21375 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21376 (eval $ac_try) 2>&5
21377 ac_status=$?
21378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21379 (exit $ac_status); }; }; then
21380 ac_header_compiler=yes
21381else
21382 echo "$as_me: failed program was:" >&5
21383sed 's/^/| /' conftest.$ac_ext >&5
21384
21385ac_header_compiler=no
21386fi
edfaf76d 21387rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2d2b6695
KS
21388echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21389echo "${ECHO_T}$ac_header_compiler" >&6
21390
21391# Is the header present?
21392echo "$as_me:$LINENO: checking $ac_header presence" >&5
21393echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21394cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
21395/* confdefs.h. */
21396_ACEOF
21397cat confdefs.h >>conftest.$ac_ext
21398cat >>conftest.$ac_ext <<_ACEOF
21399/* end confdefs.h. */
21400#include <$ac_header>
21401_ACEOF
21402if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21403 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21404 ac_status=$?
21405 grep -v '^ *+' conftest.er1 >conftest.err
21406 rm -f conftest.er1
21407 cat conftest.err >&5
21408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21409 (exit $ac_status); } >/dev/null; then
21410 if test -s conftest.err; then
21411 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 21412 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2d2b6695
KS
21413 else
21414 ac_cpp_err=
21415 fi
21416else
21417 ac_cpp_err=yes
21418fi
21419if test -z "$ac_cpp_err"; then
21420 ac_header_preproc=yes
21421else
21422 echo "$as_me: failed program was:" >&5
21423sed 's/^/| /' conftest.$ac_ext >&5
21424
21425 ac_header_preproc=no
21426fi
21427rm -f conftest.err conftest.$ac_ext
21428echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21429echo "${ECHO_T}$ac_header_preproc" >&6
21430
21431# So? What about this header?
edfaf76d
LK
21432case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21433 yes:no: )
2d2b6695
KS
21434 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21435echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
21436 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
21437echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
21438 ac_header_preproc=yes
2d2b6695 21439 ;;
edfaf76d 21440 no:yes:* )
2d2b6695
KS
21441 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21442echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
21443 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21444echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21445 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
21446echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
21447 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
21448echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
2d2b6695
KS
21449 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
21450echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
21451 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
21452echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
2d2b6695
KS
21453 (
21454 cat <<\_ASBOX
edfaf76d
LK
21455## ------------------------------------------ ##
21456## Report this to the AC_PACKAGE_NAME lists. ##
21457## ------------------------------------------ ##
2d2b6695
KS
21458_ASBOX
21459 ) |
21460 sed "s/^/$as_me: WARNING: /" >&2
21461 ;;
21462esac
21463echo "$as_me:$LINENO: checking for $ac_header" >&5
21464echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21465if eval "test \"\${$as_ac_Header+set}\" = set"; then
21466 echo $ECHO_N "(cached) $ECHO_C" >&6
21467else
edfaf76d 21468 eval "$as_ac_Header=\$ac_header_preproc"
2d2b6695
KS
21469fi
21470echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21471echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
21472
21473fi
21474if test `eval echo '${'$as_ac_Header'}'` = yes; then
21475 cat >>confdefs.h <<_ACEOF
21476#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
21477_ACEOF
21478
21479fi
21480
21481done
21482
21483
ba4481b5 21484if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 21485
c0d27fcc 21486cat >>confdefs.h <<\_ACEOF
ba4481b5 21487#define HAVE_AIX_SMT_EXP 1
c0d27fcc 21488_ACEOF
ba4481b5
DL
21489
21490fi
21491
c0d27fcc 21492echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 21493echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 21494if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 21495 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 21496echo "${ECHO_T}yes" >&6
b936fae4 21497
c0d27fcc 21498cat >>confdefs.h <<\_ACEOF
3d9fec71 21499#define HAVE_DEV_PTMX 1
c0d27fcc 21500_ACEOF
3d9fec71
DL
21501
21502else
c0d27fcc 21503 echo "$as_me:$LINENO: result: no" >&5
503d2be0 21504echo "${ECHO_T}no" >&6
3d9fec71
DL
21505fi
21506
c0d27fcc 21507echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
21508echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
21509if test "${ac_cv_type_pid_t+set}" = set; then
21510 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 21511else
503d2be0 21512 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21513/* confdefs.h. */
21514_ACEOF
21515cat confdefs.h >>conftest.$ac_ext
21516cat >>conftest.$ac_ext <<_ACEOF
21517/* end confdefs.h. */
503d2be0
AS
21518$ac_includes_default
21519int
21520main ()
21521{
21522if ((pid_t *) 0)
21523 return 0;
21524if (sizeof (pid_t))
21525 return 0;
21526 ;
21527 return 0;
21528}
21529_ACEOF
21530rm -f conftest.$ac_objext
c0d27fcc 21531if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 21532 (eval $ac_compile) 2>conftest.er1
503d2be0 21533 ac_status=$?
edfaf76d
LK
21534 grep -v '^ *+' conftest.er1 >conftest.err
21535 rm -f conftest.er1
21536 cat conftest.err >&5
c0d27fcc 21537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 21538 (exit $ac_status); } &&
10a3b1a1
EZ
21539 { ac_try='test -z "$ac_c_werror_flag"
21540 || test ! -s conftest.err'
edfaf76d
LK
21541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21542 (eval $ac_try) 2>&5
21543 ac_status=$?
21544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21545 (exit $ac_status); }; } &&
21546 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 21547 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
21548 (eval $ac_try) 2>&5
21549 ac_status=$?
c0d27fcc 21550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 21551 (exit $ac_status); }; }; then
647847ea
DL
21552 ac_cv_type_pid_t=yes
21553else
503d2be0 21554 echo "$as_me: failed program was:" >&5
19650fd6
AS
21555sed 's/^/| /' conftest.$ac_ext >&5
21556
503d2be0 21557ac_cv_type_pid_t=no
647847ea 21558fi
edfaf76d 21559rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
647847ea 21560fi
c0d27fcc 21561echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
21562echo "${ECHO_T}$ac_cv_type_pid_t" >&6
21563if test $ac_cv_type_pid_t = yes; then
21564 :
21565else
21566
c0d27fcc 21567cat >>confdefs.h <<_ACEOF
647847ea 21568#define pid_t int
c0d27fcc 21569_ACEOF
647847ea
DL
21570
21571fi
21572
c0d27fcc
MR
21573
21574
503d2be0
AS
21575for ac_header in unistd.h vfork.h
21576do
21577as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
21578if eval "test \"\${$as_ac_Header+set}\" = set"; then
21579 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
21580echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21581if eval "test \"\${$as_ac_Header+set}\" = set"; then
21582 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
21583fi
21584echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
21585echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 21586else
c0d27fcc
MR
21587 # Is the header compilable?
21588echo "$as_me:$LINENO: checking $ac_header usability" >&5
21589echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
21590cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21591/* confdefs.h. */
21592_ACEOF
21593cat confdefs.h >>conftest.$ac_ext
21594cat >>conftest.$ac_ext <<_ACEOF
21595/* end confdefs.h. */
c0d27fcc
MR
21596$ac_includes_default
21597#include <$ac_header>
21598_ACEOF
21599rm -f conftest.$ac_objext
21600if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 21601 (eval $ac_compile) 2>conftest.er1
c0d27fcc 21602 ac_status=$?
edfaf76d
LK
21603 grep -v '^ *+' conftest.er1 >conftest.err
21604 rm -f conftest.er1
21605 cat conftest.err >&5
c0d27fcc
MR
21606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21607 (exit $ac_status); } &&
10a3b1a1
EZ
21608 { ac_try='test -z "$ac_c_werror_flag"
21609 || test ! -s conftest.err'
edfaf76d
LK
21610 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21611 (eval $ac_try) 2>&5
21612 ac_status=$?
21613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21614 (exit $ac_status); }; } &&
21615 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
21616 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21617 (eval $ac_try) 2>&5
21618 ac_status=$?
21619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21620 (exit $ac_status); }; }; then
21621 ac_header_compiler=yes
21622else
21623 echo "$as_me: failed program was:" >&5
19650fd6
AS
21624sed 's/^/| /' conftest.$ac_ext >&5
21625
c0d27fcc
MR
21626ac_header_compiler=no
21627fi
edfaf76d 21628rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
21629echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21630echo "${ECHO_T}$ac_header_compiler" >&6
21631
21632# Is the header present?
21633echo "$as_me:$LINENO: checking $ac_header presence" >&5
21634echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
21635cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21636/* confdefs.h. */
21637_ACEOF
21638cat confdefs.h >>conftest.$ac_ext
21639cat >>conftest.$ac_ext <<_ACEOF
21640/* end confdefs.h. */
503d2be0
AS
21641#include <$ac_header>
21642_ACEOF
c0d27fcc 21643if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
21644 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21645 ac_status=$?
6bae0ccf 21646 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
21647 rm -f conftest.er1
21648 cat conftest.err >&5
c0d27fcc 21649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21650 (exit $ac_status); } >/dev/null; then
21651 if test -s conftest.err; then
21652 ac_cpp_err=$ac_c_preproc_warn_flag
edfaf76d 21653 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
21654 else
21655 ac_cpp_err=
21656 fi
647847ea 21657else
503d2be0
AS
21658 ac_cpp_err=yes
21659fi
21660if test -z "$ac_cpp_err"; then
c0d27fcc 21661 ac_header_preproc=yes
647847ea 21662else
503d2be0 21663 echo "$as_me: failed program was:" >&5
19650fd6
AS
21664sed 's/^/| /' conftest.$ac_ext >&5
21665
c0d27fcc 21666 ac_header_preproc=no
647847ea 21667fi
503d2be0 21668rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
21669echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21670echo "${ECHO_T}$ac_header_preproc" >&6
21671
21672# So? What about this header?
edfaf76d
LK
21673case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21674 yes:no: )
c0d27fcc
MR
21675 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
21676echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
edfaf76d
LK
21677 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
21678echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
21679 ac_header_preproc=yes
19650fd6 21680 ;;
edfaf76d 21681 no:yes:* )
c0d27fcc
MR
21682 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
21683echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
edfaf76d
LK
21684 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
21685echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
21686 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
21687echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
21688 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
21689echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 21690 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 21691echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
edfaf76d
LK
21692 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
21693echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
21694 (
21695 cat <<\_ASBOX
edfaf76d
LK
21696## ------------------------------------------ ##
21697## Report this to the AC_PACKAGE_NAME lists. ##
21698## ------------------------------------------ ##
19650fd6
AS
21699_ASBOX
21700 ) |
21701 sed "s/^/$as_me: WARNING: /" >&2
21702 ;;
c0d27fcc
MR
21703esac
21704echo "$as_me:$LINENO: checking for $ac_header" >&5
21705echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
21706if eval "test \"\${$as_ac_Header+set}\" = set"; then
21707 echo $ECHO_N "(cached) $ECHO_C" >&6
21708else
edfaf76d 21709 eval "$as_ac_Header=\$ac_header_preproc"
647847ea 21710fi
c0d27fcc 21711echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 21712echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
21713
21714fi
503d2be0 21715if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 21716 cat >>confdefs.h <<_ACEOF
503d2be0 21717#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 21718_ACEOF
647847ea 21719
73b77ee5 21720fi
c0d27fcc 21721
503d2be0 21722done
73b77ee5 21723
c0d27fcc
MR
21724
21725
503d2be0
AS
21726for ac_func in fork vfork
21727do
21728as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 21729echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
21730echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21731if eval "test \"\${$as_ac_var+set}\" = set"; then
21732 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 21733else
503d2be0 21734 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21735/* confdefs.h. */
21736_ACEOF
21737cat confdefs.h >>conftest.$ac_ext
21738cat >>conftest.$ac_ext <<_ACEOF
21739/* end confdefs.h. */
edfaf76d
LK
21740/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21741 For example, HP-UX 11i <limits.h> declares gettimeofday. */
21742#define $ac_func innocuous_$ac_func
21743
fa0b693c 21744/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
21745 which can conflict with char $ac_func (); below.
21746 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21747 <limits.h> exists even on freestanding compilers. */
edfaf76d 21748
19650fd6
AS
21749#ifdef __STDC__
21750# include <limits.h>
21751#else
21752# include <assert.h>
21753#endif
edfaf76d
LK
21754
21755#undef $ac_func
21756
fa0b693c 21757/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
21758#ifdef __cplusplus
21759extern "C"
19650fd6 21760{
503d2be0 21761#endif
fa0b693c 21762/* We use char because int might match the return type of a gcc2
503d2be0
AS
21763 builtin and then its argument prototype would still apply. */
21764char $ac_func ();
fa0b693c
GM
21765/* The GNU C library defines this for functions which it implements
21766 to always fail with ENOSYS. Some functions are actually named
21767 something starting with __ and the normal name is an alias. */
503d2be0 21768#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
21769choke me
21770#else
19650fd6
AS
21771char (*f) () = $ac_func;
21772#endif
21773#ifdef __cplusplus
21774}
fa0b693c
GM
21775#endif
21776
19650fd6
AS
21777int
21778main ()
21779{
21780return f != $ac_func;
503d2be0
AS
21781 ;
21782 return 0;
21783}
21784_ACEOF
21785rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 21786if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 21787 (eval $ac_link) 2>conftest.er1
503d2be0 21788 ac_status=$?
edfaf76d
LK
21789 grep -v '^ *+' conftest.er1 >conftest.err
21790 rm -f conftest.er1
21791 cat conftest.err >&5
c0d27fcc 21792 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 21793 (exit $ac_status); } &&
10a3b1a1
EZ
21794 { ac_try='test -z "$ac_c_werror_flag"
21795 || test ! -s conftest.err'
edfaf76d
LK
21796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21797 (eval $ac_try) 2>&5
21798 ac_status=$?
21799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21800 (exit $ac_status); }; } &&
21801 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 21802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
21803 (eval $ac_try) 2>&5
21804 ac_status=$?
c0d27fcc 21805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21806 (exit $ac_status); }; }; then
21807 eval "$as_ac_var=yes"
21808else
21809 echo "$as_me: failed program was:" >&5
19650fd6
AS
21810sed 's/^/| /' conftest.$ac_ext >&5
21811
503d2be0
AS
21812eval "$as_ac_var=no"
21813fi
edfaf76d
LK
21814rm -f conftest.err conftest.$ac_objext \
21815 conftest$ac_exeext conftest.$ac_ext
503d2be0 21816fi
c0d27fcc 21817echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
21818echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
21819if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 21820 cat >>confdefs.h <<_ACEOF
503d2be0 21821#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 21822_ACEOF
503d2be0 21823
fa0b693c 21824fi
503d2be0 21825done
fa0b693c 21826
503d2be0 21827if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 21828 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
21829echo $ECHO_N "checking for working fork... $ECHO_C" >&6
21830if test "${ac_cv_func_fork_works+set}" = set; then
21831 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 21832else
503d2be0
AS
21833 if test "$cross_compiling" = yes; then
21834 ac_cv_func_fork_works=cross
21835else
21836 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 21837/* By Ruediger Kuhlmann. */
503d2be0
AS
21838 #include <sys/types.h>
21839 #if HAVE_UNISTD_H
21840 # include <unistd.h>
21841 #endif
21842 /* Some systems only have a dummy stub for fork() */
21843 int main ()
21844 {
edfaf76d
LK
21845 if (fork() < 0)
21846 exit (1);
21847 exit (0);
503d2be0
AS
21848 }
21849_ACEOF
21850rm -f conftest$ac_exeext
c0d27fcc 21851if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
21852 (eval $ac_link) 2>&5
21853 ac_status=$?
c0d27fcc 21854 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 21855 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 21856 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
21857 (eval $ac_try) 2>&5
21858 ac_status=$?
c0d27fcc 21859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
21860 (exit $ac_status); }; }; then
21861 ac_cv_func_fork_works=yes
21862else
21863 echo "$as_me: program exited with status $ac_status" >&5
21864echo "$as_me: failed program was:" >&5
19650fd6
AS
21865sed 's/^/| /' conftest.$ac_ext >&5
21866
c0d27fcc 21867( exit $ac_status )
503d2be0
AS
21868ac_cv_func_fork_works=no
21869fi
edfaf76d 21870rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
21871fi
21872fi
c0d27fcc 21873echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
21874echo "${ECHO_T}$ac_cv_func_fork_works" >&6
21875
6bae0ccf
DL
21876else
21877 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
21878fi
21879if test "x$ac_cv_func_fork_works" = xcross; then
21880 case $host in
21881 *-*-amigaos* | *-*-msdosdjgpp*)
21882 # Override, as these systems have only a dummy fork() stub
21883 ac_cv_func_fork_works=no
21884 ;;
21885 *)
21886 ac_cv_func_fork_works=yes
21887 ;;
21888 esac
c0d27fcc
MR
21889 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
21890echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 21891fi
73b77ee5 21892ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 21893if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 21894 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
21895echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
21896if test "${ac_cv_func_vfork_works+set}" = set; then
21897 echo $ECHO_N "(cached) $ECHO_C" >&6
21898else
21899 if test "$cross_compiling" = yes; then
21900 ac_cv_func_vfork_works=cross
fa0b693c 21901else
503d2be0 21902 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21903/* confdefs.h. */
21904_ACEOF
21905cat confdefs.h >>conftest.$ac_ext
21906cat >>conftest.$ac_ext <<_ACEOF
21907/* end confdefs.h. */
73b77ee5
GM
21908/* Thanks to Paul Eggert for this test. */
21909#include <stdio.h>
19650fd6 21910#include <stdlib.h>
fa0b693c 21911#include <sys/types.h>
73b77ee5 21912#include <sys/stat.h>
19650fd6 21913#include <sys/wait.h>
503d2be0
AS
21914#if HAVE_UNISTD_H
21915# include <unistd.h>
73b77ee5 21916#endif
503d2be0
AS
21917#if HAVE_VFORK_H
21918# include <vfork.h>
73b77ee5
GM
21919#endif
21920/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
21921 argument registers are propagated back to the parent. The compiler
21922 is told about this with #include <vfork.h>, but some compilers
21923 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
21924 static variable whose address is put into a register that is
21925 clobbered by the vfork. */
19650fd6 21926static void
fa0b693c 21927#ifdef __cplusplus
73b77ee5 21928sparc_address_test (int arg)
503d2be0 21929# else
73b77ee5 21930sparc_address_test (arg) int arg;
fa0b693c 21931#endif
fa0b693c 21932{
73b77ee5
GM
21933 static pid_t child;
21934 if (!child) {
21935 child = vfork ();
21936 if (child < 0) {
21937 perror ("vfork");
21938 _exit(2);
21939 }
21940 if (!child) {
21941 arg = getpid();
21942 write(-1, "", 0);
21943 _exit (arg);
21944 }
21945 }
21946}
503d2be0
AS
21947
21948int
21949main ()
21950{
73b77ee5
GM
21951 pid_t parent = getpid ();
21952 pid_t child;
fa0b693c 21953
19650fd6 21954 sparc_address_test (0);
fa0b693c 21955
73b77ee5 21956 child = vfork ();
fa0b693c 21957
73b77ee5 21958 if (child == 0) {
503d2be0
AS
21959 /* Here is another test for sparc vfork register problems. This
21960 test uses lots of local variables, at least as many local
21961 variables as main has allocated so far including compiler
21962 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
21963 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
21964 reuse the register of parent for one of the local variables,
21965 since it will think that parent can't possibly be used any more
21966 in this routine. Assigning to the local variable will thus
21967 munge parent in the parent process. */
73b77ee5
GM
21968 pid_t
21969 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
21970 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
21971 /* Convince the compiler that p..p7 are live; otherwise, it might
21972 use the same hardware register for all 8 local variables. */
21973 if (p != p1 || p != p2 || p != p3 || p != p4
21974 || p != p5 || p != p6 || p != p7)
21975 _exit(1);
fa0b693c 21976
503d2be0
AS
21977 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
21978 from child file descriptors. If the child closes a descriptor
21979 before it execs or exits, this munges the parent's descriptor
21980 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
21981 _exit(close(fileno(stdout)) != 0);
21982 } else {
21983 int status;
21984 struct stat st;
21985
21986 while (wait(&status) != child)
21987 ;
21988 exit(
21989 /* Was there some problem with vforking? */
21990 child < 0
21991
21992 /* Did the child fail? (This shouldn't happen.) */
21993 || status
21994
21995 /* Did the vfork/compiler bug occur? */
21996 || parent != getpid()
fa0b693c 21997
73b77ee5
GM
21998 /* Did the file descriptor bug occur? */
21999 || fstat(fileno(stdout), &st) != 0
22000 );
22001 }
22002}
503d2be0
AS
22003_ACEOF
22004rm -f conftest$ac_exeext
c0d27fcc 22005if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
22006 (eval $ac_link) 2>&5
22007 ac_status=$?
c0d27fcc 22008 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 22009 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 22010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
22011 (eval $ac_try) 2>&5
22012 ac_status=$?
c0d27fcc 22013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 22014 (exit $ac_status); }; }; then
73b77ee5 22015 ac_cv_func_vfork_works=yes
fa0b693c 22016else
503d2be0
AS
22017 echo "$as_me: program exited with status $ac_status" >&5
22018echo "$as_me: failed program was:" >&5
19650fd6
AS
22019sed 's/^/| /' conftest.$ac_ext >&5
22020
c0d27fcc 22021( exit $ac_status )
503d2be0
AS
22022ac_cv_func_vfork_works=no
22023fi
edfaf76d 22024rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 22025fi
fa0b693c 22026fi
c0d27fcc 22027echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 22028echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 22029
503d2be0
AS
22030fi;
22031if test "x$ac_cv_func_fork_works" = xcross; then
edfaf76d 22032 ac_cv_func_vfork_works=$ac_cv_func_vfork
c0d27fcc
MR
22033 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
22034echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
22035fi
22036
503d2be0
AS
22037if test "x$ac_cv_func_vfork_works" = xyes; then
22038
c0d27fcc 22039cat >>confdefs.h <<\_ACEOF
503d2be0 22040#define HAVE_WORKING_VFORK 1
c0d27fcc 22041_ACEOF
503d2be0
AS
22042
22043else
22044
c0d27fcc 22045cat >>confdefs.h <<\_ACEOF
73b77ee5 22046#define vfork fork
c0d27fcc 22047_ACEOF
fa0b693c
GM
22048
22049fi
503d2be0
AS
22050if test "x$ac_cv_func_fork_works" = xyes; then
22051
c0d27fcc 22052cat >>confdefs.h <<\_ACEOF
503d2be0 22053#define HAVE_WORKING_FORK 1
c0d27fcc 22054_ACEOF
fa0b693c 22055
503d2be0 22056fi
647847ea 22057
c0d27fcc 22058
6a3a24fa
JD
22059echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
22060echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
22061if test "${emacs_cv_langinfo_codeset+set}" = set; then
22062 echo $ECHO_N "(cached) $ECHO_C" >&6
22063else
22064 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22065/* confdefs.h. */
22066_ACEOF
22067cat confdefs.h >>conftest.$ac_ext
22068cat >>conftest.$ac_ext <<_ACEOF
22069/* end confdefs.h. */
6a3a24fa
JD
22070#include <langinfo.h>
22071int
22072main ()
22073{
22074char* cs = nl_langinfo(CODESET);
22075 ;
22076 return 0;
22077}
22078_ACEOF
22079rm -f conftest.$ac_objext conftest$ac_exeext
22080if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
edfaf76d 22081 (eval $ac_link) 2>conftest.er1
6a3a24fa 22082 ac_status=$?
edfaf76d
LK
22083 grep -v '^ *+' conftest.er1 >conftest.err
22084 rm -f conftest.er1
22085 cat conftest.err >&5
6a3a24fa
JD
22086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22087 (exit $ac_status); } &&
10a3b1a1
EZ
22088 { ac_try='test -z "$ac_c_werror_flag"
22089 || test ! -s conftest.err'
edfaf76d
LK
22090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22091 (eval $ac_try) 2>&5
22092 ac_status=$?
22093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22094 (exit $ac_status); }; } &&
22095 { ac_try='test -s conftest$ac_exeext'
6a3a24fa
JD
22096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22097 (eval $ac_try) 2>&5
22098 ac_status=$?
22099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22100 (exit $ac_status); }; }; then
22101 emacs_cv_langinfo_codeset=yes
22102else
22103 echo "$as_me: failed program was:" >&5
19650fd6
AS
22104sed 's/^/| /' conftest.$ac_ext >&5
22105
6a3a24fa
JD
22106emacs_cv_langinfo_codeset=no
22107fi
edfaf76d
LK
22108rm -f conftest.err conftest.$ac_objext \
22109 conftest$ac_exeext conftest.$ac_ext
6a3a24fa
JD
22110
22111fi
22112echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
22113echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
22114if test $emacs_cv_langinfo_codeset = yes; then
22115
22116cat >>confdefs.h <<\_ACEOF
22117#define HAVE_LANGINFO_CODESET 1
22118_ACEOF
22119
22120fi
22121
c0d27fcc 22122echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
22123echo $ECHO_N "checking for size_t... $ECHO_C" >&6
22124if test "${ac_cv_type_size_t+set}" = set; then
22125 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 22126else
503d2be0 22127 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22128/* confdefs.h. */
22129_ACEOF
22130cat confdefs.h >>conftest.$ac_ext
22131cat >>conftest.$ac_ext <<_ACEOF
22132/* end confdefs.h. */
503d2be0
AS
22133$ac_includes_default
22134int
22135main ()
22136{
22137if ((size_t *) 0)
22138 return 0;
22139if (sizeof (size_t))
22140 return 0;
22141 ;
22142 return 0;
22143}
22144_ACEOF
22145rm -f conftest.$ac_objext
c0d27fcc 22146if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 22147 (eval $ac_compile) 2>conftest.er1
503d2be0 22148 ac_status=$?
edfaf76d
LK
22149 grep -v '^ *+' conftest.er1 >conftest.err
22150 rm -f conftest.er1
22151 cat conftest.err >&5
c0d27fcc 22152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 22153 (exit $ac_status); } &&
10a3b1a1
EZ
22154 { ac_try='test -z "$ac_c_werror_flag"
22155 || test ! -s conftest.err'
edfaf76d
LK
22156 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22157 (eval $ac_try) 2>&5
22158 ac_status=$?
22159 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22160 (exit $ac_status); }; } &&
22161 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 22162 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
22163 (eval $ac_try) 2>&5
22164 ac_status=$?
c0d27fcc 22165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 22166 (exit $ac_status); }; }; then
8730a8da
DL
22167 ac_cv_type_size_t=yes
22168else
503d2be0 22169 echo "$as_me: failed program was:" >&5
19650fd6
AS
22170sed 's/^/| /' conftest.$ac_ext >&5
22171
503d2be0 22172ac_cv_type_size_t=no
8730a8da 22173fi
edfaf76d 22174rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8730a8da 22175fi
c0d27fcc 22176echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
22177echo "${ECHO_T}$ac_cv_type_size_t" >&6
22178if test $ac_cv_type_size_t = yes; then
503d2be0 22179
c0d27fcc
MR
22180cat >>confdefs.h <<_ACEOF
22181#define HAVE_SIZE_T 1
22182_ACEOF
22183
8730a8da
DL
22184
22185fi
22186
c0d27fcc 22187
973a76b1
DL
22188echo "$as_me:$LINENO: checking for mbstate_t" >&5
22189echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
22190if test "${ac_cv_type_mbstate_t+set}" = set; then
22191 echo $ECHO_N "(cached) $ECHO_C" >&6
22192else
22193 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22194/* confdefs.h. */
22195_ACEOF
22196cat confdefs.h >>conftest.$ac_ext
22197cat >>conftest.$ac_ext <<_ACEOF
22198/* end confdefs.h. */
973a76b1
DL
22199$ac_includes_default
22200# include <wchar.h>
22201int
22202main ()
22203{
22204mbstate_t x; return sizeof x;
22205 ;
22206 return 0;
22207}
22208_ACEOF
22209rm -f conftest.$ac_objext
22210if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 22211 (eval $ac_compile) 2>conftest.er1
973a76b1 22212 ac_status=$?
edfaf76d
LK
22213 grep -v '^ *+' conftest.er1 >conftest.err
22214 rm -f conftest.er1
22215 cat conftest.err >&5
973a76b1
DL
22216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22217 (exit $ac_status); } &&
10a3b1a1
EZ
22218 { ac_try='test -z "$ac_c_werror_flag"
22219 || test ! -s conftest.err'
edfaf76d
LK
22220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22221 (eval $ac_try) 2>&5
22222 ac_status=$?
22223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22224 (exit $ac_status); }; } &&
22225 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
22226 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22227 (eval $ac_try) 2>&5
22228 ac_status=$?
22229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22230 (exit $ac_status); }; }; then
22231 ac_cv_type_mbstate_t=yes
22232else
22233 echo "$as_me: failed program was:" >&5
19650fd6
AS
22234sed 's/^/| /' conftest.$ac_ext >&5
22235
973a76b1
DL
22236ac_cv_type_mbstate_t=no
22237fi
edfaf76d 22238rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
22239fi
22240echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
22241echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6
22242 if test $ac_cv_type_mbstate_t = yes; then
22243
22244cat >>confdefs.h <<\_ACEOF
22245#define HAVE_MBSTATE_T 1
22246_ACEOF
22247
22248 else
22249
22250cat >>confdefs.h <<\_ACEOF
22251#define mbstate_t int
22252_ACEOF
22253
22254 fi
22255
22044edf
DL
22256echo "$as_me:$LINENO: checking for C restrict keyword" >&5
22257echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
22258if test "${emacs_cv_c_restrict+set}" = set; then
22259 echo $ECHO_N "(cached) $ECHO_C" >&6
22260else
22261 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22262/* confdefs.h. */
22263_ACEOF
22264cat confdefs.h >>conftest.$ac_ext
22265cat >>conftest.$ac_ext <<_ACEOF
22266/* end confdefs.h. */
22044edf
DL
22267void fred (int *restrict x);
22268int
22269main ()
22270{
b936fae4 22271
22044edf
DL
22272 ;
22273 return 0;
22274}
c0d27fcc 22275_ACEOF
22044edf
DL
22276rm -f conftest.$ac_objext
22277if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 22278 (eval $ac_compile) 2>conftest.er1
22044edf 22279 ac_status=$?
edfaf76d
LK
22280 grep -v '^ *+' conftest.er1 >conftest.err
22281 rm -f conftest.er1
22282 cat conftest.err >&5
22044edf
DL
22283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22284 (exit $ac_status); } &&
10a3b1a1
EZ
22285 { ac_try='test -z "$ac_c_werror_flag"
22286 || test ! -s conftest.err'
edfaf76d
LK
22287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22288 (eval $ac_try) 2>&5
22289 ac_status=$?
22290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22291 (exit $ac_status); }; } &&
22292 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
22293 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22294 (eval $ac_try) 2>&5
22295 ac_status=$?
22296 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22297 (exit $ac_status); }; }; then
22298 emacs_cv_c_restrict=yes
22299else
22300 echo "$as_me: failed program was:" >&5
19650fd6
AS
22301sed 's/^/| /' conftest.$ac_ext >&5
22302
22044edf 22303cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22304/* confdefs.h. */
22305_ACEOF
22306cat confdefs.h >>conftest.$ac_ext
22307cat >>conftest.$ac_ext <<_ACEOF
22308/* end confdefs.h. */
22044edf
DL
22309void fred (int *__restrict x);
22310int
22311main ()
22312{
c0d27fcc 22313
22044edf
DL
22314 ;
22315 return 0;
22316}
c0d27fcc 22317_ACEOF
22044edf
DL
22318rm -f conftest.$ac_objext
22319if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 22320 (eval $ac_compile) 2>conftest.er1
22044edf 22321 ac_status=$?
edfaf76d
LK
22322 grep -v '^ *+' conftest.er1 >conftest.err
22323 rm -f conftest.er1
22324 cat conftest.err >&5
22044edf
DL
22325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22326 (exit $ac_status); } &&
10a3b1a1
EZ
22327 { ac_try='test -z "$ac_c_werror_flag"
22328 || test ! -s conftest.err'
edfaf76d
LK
22329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22330 (eval $ac_try) 2>&5
22331 ac_status=$?
22332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22333 (exit $ac_status); }; } &&
22334 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
22335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22336 (eval $ac_try) 2>&5
22337 ac_status=$?
22338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22339 (exit $ac_status); }; }; then
22340 emacs_cv_c_restrict=__restrict
22341else
22342 echo "$as_me: failed program was:" >&5
19650fd6
AS
22343sed 's/^/| /' conftest.$ac_ext >&5
22344
22044edf 22345emacs_cv_c_restrict=no
ba4481b5 22346fi
edfaf76d 22347rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 22348fi
edfaf76d 22349rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 22350fi
22044edf
DL
22351echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
22352echo "${ECHO_T}$emacs_cv_c_restrict" >&6
22353case "$emacs_cv_c_restrict" in
22354 yes) emacs_restrict=restrict;;
22355 no) emacs_restrict="";;
22356 *) emacs_restrict="$emacs_cv_c_restrict";;
22357esac
22358if test "$emacs_restrict" != __restrict; then
b936fae4 22359
22044edf
DL
22360cat >>confdefs.h <<_ACEOF
22361#define __restrict $emacs_restrict
c0d27fcc 22362_ACEOF
ba4481b5
DL
22363
22364fi
ba4481b5 22365
22044edf
DL
22366echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
22367echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
22368if test "${emacs_cv_c_restrict_arr+set}" = set; then
22369 echo $ECHO_N "(cached) $ECHO_C" >&6
22370else
22371 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22372/* confdefs.h. */
22373_ACEOF
22374cat confdefs.h >>conftest.$ac_ext
22375cat >>conftest.$ac_ext <<_ACEOF
22376/* end confdefs.h. */
22044edf
DL
22377void fred (int x[__restrict]);
22378int
22379main ()
22380{
b936fae4 22381
22044edf
DL
22382 ;
22383 return 0;
22384}
c0d27fcc 22385_ACEOF
22044edf
DL
22386rm -f conftest.$ac_objext
22387if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
edfaf76d 22388 (eval $ac_compile) 2>conftest.er1
22044edf 22389 ac_status=$?
edfaf76d
LK
22390 grep -v '^ *+' conftest.er1 >conftest.err
22391 rm -f conftest.er1
22392 cat conftest.err >&5
22044edf
DL
22393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22394 (exit $ac_status); } &&
10a3b1a1
EZ
22395 { ac_try='test -z "$ac_c_werror_flag"
22396 || test ! -s conftest.err'
edfaf76d
LK
22397 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22398 (eval $ac_try) 2>&5
22399 ac_status=$?
22400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22401 (exit $ac_status); }; } &&
22402 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
22403 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22404 (eval $ac_try) 2>&5
22405 ac_status=$?
22406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22407 (exit $ac_status); }; }; then
22408 emacs_cv_c_restrict_arr=yes
22409else
22410 echo "$as_me: failed program was:" >&5
19650fd6
AS
22411sed 's/^/| /' conftest.$ac_ext >&5
22412
22044edf 22413emacs_cv_c_restrict_arr=no
ba4481b5 22414fi
edfaf76d 22415rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22044edf
DL
22416fi
22417echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
22418echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
22419if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 22420
c0d27fcc 22421cat >>confdefs.h <<\_ACEOF
22044edf 22422#define __restrict_arr __restrict
c0d27fcc 22423_ACEOF
ba4481b5 22424
ba4481b5
DL
22425fi
22426
c0d27fcc 22427
c0d27fcc 22428
22044edf
DL
22429# Set up the CFLAGS for real compilation, so we can substitute it.
22430CFLAGS="$REAL_CFLAGS"
22431CPPFLAGS="$REAL_CPPFLAGS"
22432
22433#### Find out which version of Emacs this is.
22434version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
22435 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
22436if test x"${version}" = x; then
22437 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
22438echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
22439 { (exit 1); exit 1; }; }
22440fi
22441
22442### Specify what sort of things we'll be editing into Makefile and config.h.
22443### Use configuration here uncanonicalized to avoid exceeding size limits.
22444
22445
22446
22447
22448
22449
22450
22451
22452
22453
22454
22455
22456
22457
22458
22459
22460
22461
22462
22463
22464
22465
22466
22467
22468
22469
22470
22471
22472
22473
22474
22475
6a3a24fa 22476
22044edf
DL
22477
22478
22479cat >>confdefs.h <<_ACEOF
22480#define EMACS_CONFIGURATION "${canonical}"
22481_ACEOF
22482
22483
22484cat >>confdefs.h <<_ACEOF
22485#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
22486_ACEOF
22487
22488
22489cat >>confdefs.h <<_ACEOF
22490#define config_machfile "${machfile}"
22491_ACEOF
22492
22493
22494cat >>confdefs.h <<_ACEOF
22495#define config_opsysfile "${opsysfile}"
22496_ACEOF
22497
22498
22499cat >>confdefs.h <<_ACEOF
22500#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
22501_ACEOF
22502
22503
22504cat >>confdefs.h <<_ACEOF
22505#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
22506_ACEOF
22507
22508
22509cat >>confdefs.h <<_ACEOF
22510#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
22511_ACEOF
22512
22513
22514cat >>confdefs.h <<_ACEOF
22515#define UNEXEC_SRC ${UNEXEC_SRC}
22516_ACEOF
22517
22518
22519if test "${HAVE_X_WINDOWS}" = "yes" ; then
22520
22521cat >>confdefs.h <<\_ACEOF
22522#define HAVE_X_WINDOWS 1
22523_ACEOF
22524
22525fi
22526if test "${USE_X_TOOLKIT}" != "none" ; then
22527
22528cat >>confdefs.h <<\_ACEOF
22529#define USE_X_TOOLKIT 1
22530_ACEOF
22531
22532fi
22533if test "${HAVE_X11}" = "yes" ; then
22534
22535cat >>confdefs.h <<\_ACEOF
22536#define HAVE_X11 1
22537_ACEOF
22538
22539fi
22540if test "${HAVE_XFREE386}" = "yes" ; then
22541
22542cat >>confdefs.h <<\_ACEOF
22543#define HAVE_XFREE386 1
22544_ACEOF
22545
22546fi
22547if test "${HAVE_MENUS}" = "yes" ; then
22548
22549cat >>confdefs.h <<\_ACEOF
22550#define HAVE_MENUS 1
22551_ACEOF
22552
22553fi
22554if test "${GNU_MALLOC}" = "yes" ; then
22555
22556cat >>confdefs.h <<\_ACEOF
22557#define GNU_MALLOC 1
22558_ACEOF
22559
22560fi
22561if test "${REL_ALLOC}" = "yes" ; then
22562
22563cat >>confdefs.h <<\_ACEOF
22564#define REL_ALLOC 1
22565_ACEOF
22566
22567fi
22568
22569
22570
c0d27fcc
MR
22571
22572
ba4481b5 22573#### Report on what we decided to do.
488dd4c4
JD
22574#### Report GTK as a toolkit, even if it doesn't use Xt.
22575#### It makes printing result more understandable as using GTK sets
22576#### toolkit_scroll_bars to yes by default.
22577if test "${HAVE_GTK}" = "yes"; then
22578 USE_X_TOOLKIT=GTK
22579fi
22580
ba4481b5
DL
22581echo "
22582Configured for \`${canonical}'.
22583
22584 Where should the build process find the source code? ${srcdir}
22585 What operating system and machine description files should Emacs use?
22586 \`${opsysfile}' and \`${machfile}'
22587 What compiler should emacs be built with? ${CC} ${CFLAGS}
22588 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 22589 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 22590 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 22591 What window system should Emacs use? ${window_system}
8e967cf7 22592 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
22593
22594if test -n "${x_includes}"; then
22595echo " Where do we find X Windows header files? ${x_includes}"
22596else
22597echo " Where do we find X Windows header files? Standard dirs"
22598fi
22599if test -n "${x_libraries}"; then
22600echo " Where do we find X Windows libraries? ${x_libraries}"
22601else
22602echo " Where do we find X Windows libraries? Standard dirs"
22603fi
22604
22605echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
22606echo " Does Emacs use -lXpm? ${HAVE_XPM}"
22607echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
22608echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
22609echo " Does Emacs use -lungif? ${HAVE_GIF}"
22610echo " Does Emacs use -lpng? ${HAVE_PNG}"
22611echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
22612echo
22613
d0098f13
JD
22614if test $USE_XASSERTS = yes; then
22615 echo " Compiling with asserts turned on."
d0098f13
JD
22616 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
22617 echo
22618fi
05cf15c6 22619
05cf15c6 22620
05cf15c6 22621
ba4481b5
DL
22622# Remove any trailing slashes in these variables.
22623test "${prefix}" != NONE &&
22624 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
22625test "${exec_prefix}" != NONE &&
22626 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
22627
d0e9bfd2
GM
22628## Check if the C preprocessor will convert `..' to `. .'. If so, set
22629## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
22630## from Makefile.c can correctly provide the arg `-traditional' to the
22631## C preprocessor.
22632
503d2be0 22633cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
22634/* confdefs.h. */
22635_ACEOF
22636cat confdefs.h >>conftest.$ac_ext
22637cat >>conftest.$ac_ext <<_ACEOF
22638/* end confdefs.h. */
d0e9bfd2 22639yes..yes
503d2be0 22640_ACEOF
d0e9bfd2 22641if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 22642 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
22643 CPP_NEED_TRADITIONAL=no
22644else
d0e9bfd2
GM
22645 CPP_NEED_TRADITIONAL=yes
22646fi
22647rm -f conftest*
22648
c0d27fcc 22649
6bae0ccf
DL
22650 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"
22651 ac_config_commands="$ac_config_commands default"
503d2be0 22652cat >confcache <<\_ACEOF
ba4481b5
DL
22653# This file is a shell script that caches the results of configure
22654# tests run on this system so they can be shared between configure
503d2be0
AS
22655# scripts and configure runs, see configure's option --config-cache.
22656# It is not useful on other systems. If it contains results you don't
22657# want to keep, you may remove or edit it.
ba4481b5 22658#
503d2be0
AS
22659# config.status only pays attention to the cache file if you give it
22660# the --recheck option to rerun configure.
ba4481b5 22661#
6bae0ccf 22662# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
22663# loading this file, other *unset* `ac_cv_foo' will be assigned the
22664# following values.
22665
22666_ACEOF
22667
ba4481b5
DL
22668# The following way of writing the cache mishandles newlines in values,
22669# but we know of no workaround that is simple, portable, and efficient.
22670# So, don't put newlines in cache variables' values.
22671# Ultrix sh set writes to stderr and can't be redirected directly,
22672# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
22673{
22674 (set) 2>&1 |
22675 case `(ac_space=' '; set | grep ac_space) 2>&1` in
22676 *ac_space=\ *)
22677 # `set' does not quote correctly, so add quotes (double-quote
22678 # substitution turns \\\\ into \\, and sed turns \\ into \).
22679 sed -n \
edfaf76d
LK
22680 "s/'/'\\\\''/g;
22681 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
503d2be0
AS
22682 ;;
22683 *)
22684 # `set' quotes correctly as required by POSIX, so do not add quotes.
22685 sed -n \
edfaf76d 22686 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
22687 ;;
22688 esac;
22689} |
22690 sed '
22691 t clear
22692 : clear
22693 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22694 t end
22695 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22696 : end' >>confcache
19650fd6 22697if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 22698 if test -w $cache_file; then
503d2be0
AS
22699 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22700 cat confcache >$cache_file
ba4481b5
DL
22701 else
22702 echo "not updating unwritable cache $cache_file"
22703 fi
22704fi
22705rm -f confcache
22706
ba4481b5
DL
22707test "x$prefix" = xNONE && prefix=$ac_default_prefix
22708# Let make expand exec_prefix.
22709test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22710
503d2be0
AS
22711# VPATH may cause trouble with some makes, so we remove $(srcdir),
22712# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22713# trailing colons and then remove the whole line if VPATH becomes empty
22714# (actually we leave an empty line to preserve line numbers).
ba4481b5 22715if test "x$srcdir" = x.; then
edfaf76d 22716 ac_vpsub='/^[ ]*VPATH[ ]*=/{
503d2be0
AS
22717s/:*\$(srcdir):*/:/;
22718s/:*\${srcdir}:*/:/;
22719s/:*@srcdir@:*/:/;
edfaf76d 22720s/^\([^=]*=[ ]*\):*/\1/;
503d2be0 22721s/:*$//;
edfaf76d 22722s/^[^=]*=[ ]*$//;
503d2be0 22723}'
ba4481b5
DL
22724fi
22725
ba4481b5
DL
22726DEFS=-DHAVE_CONFIG_H
22727
6bae0ccf
DL
22728ac_libobjs=
22729ac_ltlibobjs=
22730for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22731 # 1. Remove the extension, and $U if already installed.
22732 ac_i=`echo "$ac_i" |
edfaf76d 22733 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
6bae0ccf
DL
22734 # 2. Add them.
22735 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
22736 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
22737done
22738LIBOBJS=$ac_libobjs
22739
22740LTLIBOBJS=$ac_ltlibobjs
22741
22742
c0d27fcc 22743
ba4481b5 22744: ${CONFIG_STATUS=./config.status}
503d2be0
AS
22745ac_clean_files_save=$ac_clean_files
22746ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 22747{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
22748echo "$as_me: creating $CONFIG_STATUS" >&6;}
22749cat >$CONFIG_STATUS <<_ACEOF
22750#! $SHELL
c0d27fcc 22751# Generated by $as_me.
ba4481b5 22752# Run this file to recreate the current configuration.
ba4481b5 22753# Compiler output produced by configure, useful for debugging
503d2be0 22754# configure, is in config.log if it exists.
ba4481b5 22755
503d2be0 22756debug=false
19650fd6
AS
22757ac_cs_recheck=false
22758ac_cs_silent=false
503d2be0 22759SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
22760_ACEOF
22761
22762cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
22763## --------------------- ##
22764## M4sh Initialization. ##
22765## --------------------- ##
22766
503d2be0
AS
22767# Be Bourne compatible
22768if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22769 emulate sh
22770 NULLCMD=:
6bae0ccf
DL
22771 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
22772 # is contrary to our usage. Disable this feature.
22773 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
22774elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22775 set -o posix
22776fi
edfaf76d 22777DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 22778
c0d27fcc 22779# Support unset when possible.
edfaf76d 22780if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
22781 as_unset=unset
22782else
22783 as_unset=false
22784fi
22785
6bae0ccf
DL
22786
22787# Work around bugs in pre-3.0 UWIN ksh.
22788$as_unset ENV MAIL MAILPATH
22789PS1='$ '
22790PS2='> '
22791PS4='+ '
22792
22793# NLS nuisances.
19650fd6
AS
22794for as_var in \
22795 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
22796 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
22797 LC_TELEPHONE LC_TIME
6bae0ccf 22798do
edfaf76d 22799 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
22800 eval $as_var=C; export $as_var
22801 else
22802 $as_unset $as_var
22803 fi
22804done
22805
22806# Required to use basename.
22807if expr a : '\(a\)' >/dev/null 2>&1; then
22808 as_expr=expr
22809else
22810 as_expr=false
22811fi
22812
22813if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
22814 as_basename=basename
22815else
22816 as_basename=false
22817fi
c0d27fcc
MR
22818
22819
503d2be0 22820# Name of the executable.
6bae0ccf 22821as_me=`$as_basename "$0" ||
c0d27fcc
MR
22822$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22823 X"$0" : 'X\(//\)$' \| \
22824 X"$0" : 'X\(/\)$' \| \
22825 . : '\(.\)' 2>/dev/null ||
22826echo X/"$0" |
22827 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
22828 /^X\/\(\/\/\)$/{ s//\1/; q; }
22829 /^X\/\(\/\).*/{ s//\1/; q; }
22830 s/.*/./; q'`
22831
6bae0ccf 22832
c0d27fcc
MR
22833# PATH needs CR, and LINENO needs CR and PATH.
22834# Avoid depending upon Character Ranges.
22835as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22836as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22837as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22838as_cr_digits='0123456789'
22839as_cr_alnum=$as_cr_Letters$as_cr_digits
22840
22841# The user is always right.
22842if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
22843 echo "#! /bin/sh" >conf$$.sh
22844 echo "exit 0" >>conf$$.sh
22845 chmod +x conf$$.sh
22846 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
22847 PATH_SEPARATOR=';'
22848 else
22849 PATH_SEPARATOR=:
22850 fi
19650fd6 22851 rm -f conf$$.sh
c0d27fcc
MR
22852fi
22853
22854
22855 as_lineno_1=$LINENO
22856 as_lineno_2=$LINENO
22857 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22858 test "x$as_lineno_1" != "x$as_lineno_2" &&
22859 test "x$as_lineno_3" = "x$as_lineno_2" || {
22860 # Find who we are. Look in the path if we contain no path at all
22861 # relative or not.
22862 case $0 in
22863 *[\\/]* ) as_myself=$0 ;;
22864 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22865for as_dir in $PATH
22866do
22867 IFS=$as_save_IFS
22868 test -z "$as_dir" && as_dir=.
22869 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22870done
22871
22872 ;;
22873 esac
22874 # We did not find ourselves, most probably we were run as `sh COMMAND'
22875 # in which case we are not to be found in the path.
22876 if test "x$as_myself" = x; then
22877 as_myself=$0
22878 fi
22879 if test ! -f "$as_myself"; then
22880 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
22881echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
22882 { (exit 1); exit 1; }; }
22883 fi
22884 case $CONFIG_SHELL in
22885 '')
22886 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22887for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
22888do
22889 IFS=$as_save_IFS
22890 test -z "$as_dir" && as_dir=.
22891 for as_base in sh bash ksh sh5; do
22892 case $as_dir in
22893 /*)
22894 if ("$as_dir/$as_base" -c '
22895 as_lineno_1=$LINENO
22896 as_lineno_2=$LINENO
22897 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22898 test "x$as_lineno_1" != "x$as_lineno_2" &&
22899 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
22900 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
22901 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
22902 CONFIG_SHELL=$as_dir/$as_base
22903 export CONFIG_SHELL
22904 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
22905 fi;;
22906 esac
22907 done
22908done
22909;;
22910 esac
22911
22912 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
22913 # uniformly replaced by the line number. The first 'sed' inserts a
22914 # line-number line before each line; the second 'sed' does the real
22915 # work. The second script uses 'N' to pair each line-number line
22916 # with the numbered line, and appends trailing '-' during
22917 # substitution so that $LINENO is not a special case at line end.
22918 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
22919 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
22920 sed '=' <$as_myself |
22921 sed '
22922 N
22923 s,$,-,
22924 : loop
22925 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
22926 t loop
22927 s,-$,,
22928 s,^['$as_cr_digits']*\n,,
22929 ' >$as_me.lineno &&
22930 chmod +x $as_me.lineno ||
22931 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
22932echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
22933 { (exit 1); exit 1; }; }
22934
22935 # Don't try to exec as it changes $[0], causing all sort of problems
22936 # (the dirname of $[0] is not the place where we might find the
22937 # original and so on. Autoconf is especially sensible to this).
22938 . ./$as_me.lineno
22939 # Exit status is that of the last command.
22940 exit
22941}
22942
22943
22944case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
22945 *c*,-n*) ECHO_N= ECHO_C='
22946' ECHO_T=' ' ;;
22947 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
22948 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
22949esac
503d2be0
AS
22950
22951if expr a : '\(a\)' >/dev/null 2>&1; then
22952 as_expr=expr
22953else
22954 as_expr=false
22955fi
22956
22957rm -f conf$$ conf$$.exe conf$$.file
22958echo >conf$$.file
22959if ln -s conf$$.file conf$$ 2>/dev/null; then
22960 # We could just check for DJGPP; but this test a) works b) is more generic
22961 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22962 if test -f conf$$.exe; then
22963 # Don't use ln at all; we don't have any links
22964 as_ln_s='cp -p'
22965 else
22966 as_ln_s='ln -s'
22967 fi
22968elif ln conf$$.file conf$$ 2>/dev/null; then
22969 as_ln_s=ln
22970else
22971 as_ln_s='cp -p'
22972fi
22973rm -f conf$$ conf$$.exe conf$$.file
22974
6bae0ccf
DL
22975if mkdir -p . 2>/dev/null; then
22976 as_mkdir_p=:
22977else
edfaf76d 22978 test -d ./-p && rmdir ./-p
6bae0ccf
DL
22979 as_mkdir_p=false
22980fi
22981
503d2be0
AS
22982as_executable_p="test -f"
22983
c0d27fcc 22984# Sed expression to map a string onto a valid CPP name.
edfaf76d 22985as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
22986
22987# Sed expression to map a string onto a valid variable name.
edfaf76d 22988as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 22989
503d2be0
AS
22990
22991# IFS
22992# We need space, tab and new line, in precisely that order.
22993as_nl='
22994'
22995IFS=" $as_nl"
22996
22997# CDPATH.
6bae0ccf 22998$as_unset CDPATH
503d2be0
AS
22999
23000exec 6>&1
23001
c0d27fcc
MR
23002# Open the log real soon, to keep \$[0] and so on meaningful, and to
23003# report actual input values of CONFIG_FILES etc. instead of their
23004# values after options handling. Logging --version etc. is OK.
23005exec 5>>config.log
23006{
23007 echo
23008 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23009## Running $as_me. ##
23010_ASBOX
23011} >&5
23012cat >&5 <<_CSEOF
23013
23014This file was extended by $as_me, which was
edfaf76d 23015generated by GNU Autoconf 2.59. Invocation command line was
c0d27fcc
MR
23016
23017 CONFIG_FILES = $CONFIG_FILES
23018 CONFIG_HEADERS = $CONFIG_HEADERS
23019 CONFIG_LINKS = $CONFIG_LINKS
23020 CONFIG_COMMANDS = $CONFIG_COMMANDS
23021 $ $0 $@
23022
23023_CSEOF
23024echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
23025echo >&5
503d2be0
AS
23026_ACEOF
23027
23028# Files that config.status was made for.
23029if test -n "$ac_config_files"; then
23030 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
23031fi
23032
23033if test -n "$ac_config_headers"; then
23034 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
23035fi
23036
23037if test -n "$ac_config_links"; then
23038 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
23039fi
23040
23041if test -n "$ac_config_commands"; then
23042 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
23043fi
23044
c0d27fcc 23045cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23046
23047ac_cs_usage="\
23048\`$as_me' instantiates files from templates according to the
23049current configuration.
23050
23051Usage: $0 [OPTIONS] [FILE]...
23052
23053 -h, --help print this help, then exit
23054 -V, --version print version number, then exit
19650fd6 23055 -q, --quiet do not print progress messages
503d2be0
AS
23056 -d, --debug don't remove temporary files
23057 --recheck update $as_me by reconfiguring in the same conditions
23058 --file=FILE[:TEMPLATE]
edfaf76d 23059 instantiate the configuration file FILE
503d2be0 23060 --header=FILE[:TEMPLATE]
edfaf76d 23061 instantiate the configuration header FILE
503d2be0
AS
23062
23063Configuration files:
23064$config_files
23065
23066Configuration headers:
23067$config_headers
23068
23069Configuration commands:
23070$config_commands
23071
23072Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 23073_ACEOF
503d2be0 23074
c0d27fcc 23075cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
23076ac_cs_version="\\
23077config.status
edfaf76d 23078configured by $0, generated by GNU Autoconf 2.59,
503d2be0
AS
23079 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
23080
edfaf76d 23081Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
23082This config.status script is free software; the Free Software Foundation
23083gives unlimited permission to copy, distribute and modify it."
23084srcdir=$srcdir
23085INSTALL="$INSTALL"
c0d27fcc 23086_ACEOF
503d2be0 23087
c0d27fcc 23088cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23089# If no file are specified by the user, then we need to provide default
23090# value. By we need to know if files were specified by the user.
23091ac_need_defaults=:
23092while test $# != 0
ba4481b5 23093do
503d2be0
AS
23094 case $1 in
23095 --*=*)
23096 ac_option=`expr "x$1" : 'x\([^=]*\)='`
23097 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
23098 ac_shift=:
23099 ;;
23100 -*)
23101 ac_option=$1
23102 ac_optarg=$2
23103 ac_shift=shift
503d2be0 23104 ;;
503d2be0
AS
23105 *) # This is not an option, so the user has probably given explicit
23106 # arguments.
6bae0ccf 23107 ac_option=$1
503d2be0
AS
23108 ac_need_defaults=false;;
23109 esac
23110
6bae0ccf 23111 case $ac_option in
503d2be0 23112 # Handling of the options.
c0d27fcc 23113_ACEOF
f57bd967 23114cat >>$CONFIG_STATUS <<\_ACEOF
19650fd6
AS
23115 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23116 ac_cs_recheck=: ;;
503d2be0
AS
23117 --version | --vers* | -V )
23118 echo "$ac_cs_version"; exit 0 ;;
23119 --he | --h)
23120 # Conflict between --help and --header
c0d27fcc 23121 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
23122Try \`$0 --help' for more information." >&5
23123echo "$as_me: error: ambiguous option: $1
23124Try \`$0 --help' for more information." >&2;}
23125 { (exit 1); exit 1; }; };;
23126 --help | --hel | -h )
23127 echo "$ac_cs_usage"; exit 0 ;;
23128 --debug | --d* | -d )
23129 debug=: ;;
23130 --file | --fil | --fi | --f )
6bae0ccf
DL
23131 $ac_shift
23132 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
23133 ac_need_defaults=false;;
23134 --header | --heade | --head | --hea )
6bae0ccf
DL
23135 $ac_shift
23136 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 23137 ac_need_defaults=false;;
19650fd6
AS
23138 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23139 | -silent | --silent | --silen | --sile | --sil | --si | --s)
23140 ac_cs_silent=: ;;
503d2be0
AS
23141
23142 # This is an error.
c0d27fcc 23143 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
23144Try \`$0 --help' for more information." >&5
23145echo "$as_me: error: unrecognized option: $1
23146Try \`$0 --help' for more information." >&2;}
23147 { (exit 1); exit 1; }; } ;;
23148
23149 *) ac_config_targets="$ac_config_targets $1" ;;
23150
ba4481b5 23151 esac
503d2be0 23152 shift
ba4481b5
DL
23153done
23154
19650fd6
AS
23155ac_configure_extra_args=
23156
23157if $ac_cs_silent; then
23158 exec 6>/dev/null
23159 ac_configure_extra_args="$ac_configure_extra_args --silent"
23160fi
23161
23162_ACEOF
23163cat >>$CONFIG_STATUS <<_ACEOF
23164if \$ac_cs_recheck; then
23165 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
23166 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23167fi
23168
503d2be0 23169_ACEOF
ba4481b5 23170
c0d27fcc 23171cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
23172#
23173# INIT-COMMANDS section.
23174#
ba4481b5 23175
503d2be0
AS
23176GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
23177
c0d27fcc
MR
23178_ACEOF
23179
503d2be0 23180
c0d27fcc
MR
23181
23182cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23183for ac_config_target in $ac_config_targets
23184do
23185 case "$ac_config_target" in
23186 # Handling of arguments.
23187 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23188 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
23189 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
23190 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
23191 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
23192 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
23193 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 23194 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 23195 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
23196 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
23197 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
23198 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 23199 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
23200echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
23201 { (exit 1); exit 1; }; };;
23202 esac
ba4481b5 23203done
503d2be0
AS
23204
23205# If the user did not use the arguments to specify the items to instantiate,
23206# then the envvar interface is used. Set only those that are not.
23207# We use the long form for the default assignment because of an extremely
23208# bizarre bug on SunOS 4.1.3.
23209if $ac_need_defaults; then
23210 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23211 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23212 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 23213fi
503d2be0 23214
19650fd6
AS
23215# Have a temporary directory for convenience. Make it in the build tree
23216# simply because there is no reason to put it here, and in addition,
23217# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
23218# Create a temporary directory, and hook for its removal unless debugging.
23219$debug ||
23220{
23221 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
23222 trap '{ (exit 1); exit 1; }' 1 2 13 15
23223}
23224
23225# Create a (secure) tmp directory for tmp files.
19650fd6 23226
503d2be0 23227{
19650fd6 23228 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
23229 test -n "$tmp" && test -d "$tmp"
23230} ||
23231{
19650fd6 23232 tmp=./confstat$$-$RANDOM
503d2be0
AS
23233 (umask 077 && mkdir $tmp)
23234} ||
23235{
19650fd6 23236 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
23237 { (exit 1); exit 1; }
23238}
23239
c0d27fcc 23240_ACEOF
503d2be0 23241
c0d27fcc 23242cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
23243
23244#
23245# CONFIG_FILES section.
23246#
23247
23248# No need to generate the scripts if there are no CONFIG_FILES.
23249# This happens for instance when ./config.status config.h
23250if test -n "\$CONFIG_FILES"; then
23251 # Protect against being on the right side of a sed subst in config.status.
23252 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
23253 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
23254s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
23255s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
23256s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
23257s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
23258s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
23259s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
23260s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
23261s,@exec_prefix@,$exec_prefix,;t t
23262s,@prefix@,$prefix,;t t
23263s,@program_transform_name@,$program_transform_name,;t t
23264s,@bindir@,$bindir,;t t
23265s,@sbindir@,$sbindir,;t t
23266s,@libexecdir@,$libexecdir,;t t
23267s,@datadir@,$datadir,;t t
23268s,@sysconfdir@,$sysconfdir,;t t
23269s,@sharedstatedir@,$sharedstatedir,;t t
23270s,@localstatedir@,$localstatedir,;t t
23271s,@libdir@,$libdir,;t t
23272s,@includedir@,$includedir,;t t
23273s,@oldincludedir@,$oldincludedir,;t t
23274s,@infodir@,$infodir,;t t
23275s,@mandir@,$mandir,;t t
503d2be0
AS
23276s,@build_alias@,$build_alias,;t t
23277s,@host_alias@,$host_alias,;t t
23278s,@target_alias@,$target_alias,;t t
c0d27fcc 23279s,@DEFS@,$DEFS,;t t
503d2be0
AS
23280s,@ECHO_C@,$ECHO_C,;t t
23281s,@ECHO_N@,$ECHO_N,;t t
23282s,@ECHO_T@,$ECHO_T,;t t
503d2be0 23283s,@LIBS@,$LIBS,;t t
19650fd6 23284s,@MAINT@,$MAINT,;t t
503d2be0
AS
23285s,@build@,$build,;t t
23286s,@build_cpu@,$build_cpu,;t t
23287s,@build_vendor@,$build_vendor,;t t
23288s,@build_os@,$build_os,;t t
23289s,@host@,$host,;t t
23290s,@host_cpu@,$host_cpu,;t t
23291s,@host_vendor@,$host_vendor,;t t
23292s,@host_os@,$host_os,;t t
23293s,@CC@,$CC,;t t
23294s,@CFLAGS@,$CFLAGS,;t t
23295s,@LDFLAGS@,$LDFLAGS,;t t
23296s,@CPPFLAGS@,$CPPFLAGS,;t t
23297s,@ac_ct_CC@,$ac_ct_CC,;t t
23298s,@EXEEXT@,$EXEEXT,;t t
23299s,@OBJEXT@,$OBJEXT,;t t
23300s,@LN_S@,$LN_S,;t t
23301s,@CPP@,$CPP,;t t
23302s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
23303s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
23304s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
23305s,@RANLIB@,$RANLIB,;t t
23306s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 23307s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 23308s,@EGREP@,$EGREP,;t t
503d2be0
AS
23309s,@LIBSOUND@,$LIBSOUND,;t t
23310s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
23311s,@PKG_CONFIG@,$PKG_CONFIG,;t t
23312s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
23313s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
23314s,@ALLOCA@,$ALLOCA,;t t
23315s,@liblockfile@,$liblockfile,;t t
23316s,@LIBOBJS@,$LIBOBJS,;t t
23317s,@NEED_SETGID@,$NEED_SETGID,;t t
23318s,@KMEM_GROUP@,$KMEM_GROUP,;t t
23319s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
52dbaac8
PE
23320s,@GETOPT_H@,$GETOPT_H,;t t
23321s,@GETOPTOBJS@,$GETOPTOBJS,;t t
503d2be0
AS
23322s,@version@,$version,;t t
23323s,@configuration@,$configuration,;t t
23324s,@canonical@,$canonical,;t t
23325s,@srcdir@,$srcdir,;t t
23326s,@lispdir@,$lispdir,;t t
23327s,@locallisppath@,$locallisppath,;t t
23328s,@lisppath@,$lisppath,;t t
23329s,@x_default_search_path@,$x_default_search_path,;t t
23330s,@etcdir@,$etcdir,;t t
23331s,@archlibdir@,$archlibdir,;t t
23332s,@docdir@,$docdir,;t t
23333s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
23334s,@gamedir@,$gamedir,;t t
23335s,@gameuser@,$gameuser,;t t
503d2be0
AS
23336s,@c_switch_system@,$c_switch_system,;t t
23337s,@c_switch_machine@,$c_switch_machine,;t t
23338s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
23339s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
23340s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
23341s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
23342s,@machfile@,$machfile,;t t
23343s,@opsysfile@,$opsysfile,;t t
6a3a24fa 23344s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 23345s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
23346CEOF
23347
c0d27fcc 23348_ACEOF
ba4481b5 23349
c0d27fcc 23350 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23351 # Split the substitutions into bite-sized pieces for seds with
23352 # small command number limits, like on Digital OSF/1 and HP-UX.
23353 ac_max_sed_lines=48
23354 ac_sed_frag=1 # Number of current file.
23355 ac_beg=1 # First line for current file.
23356 ac_end=$ac_max_sed_lines # Line after last line for current file.
23357 ac_more_lines=:
23358 ac_sed_cmds=
23359 while $ac_more_lines; do
23360 if test $ac_beg -gt 1; then
23361 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23362 else
23363 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23364 fi
23365 if test ! -s $tmp/subs.frag; then
23366 ac_more_lines=false
23367 else
23368 # The purpose of the label and of the branching condition is to
23369 # speed up the sed processing (if there are no `@' at all, there
23370 # is no need to browse any of the substitutions).
23371 # These are the two extra sed commands mentioned above.
23372 (echo ':t
23373 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
23374 if test -z "$ac_sed_cmds"; then
edfaf76d 23375 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0 23376 else
edfaf76d 23377 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0
AS
23378 fi
23379 ac_sed_frag=`expr $ac_sed_frag + 1`
23380 ac_beg=$ac_end
23381 ac_end=`expr $ac_end + $ac_max_sed_lines`
23382 fi
23383 done
23384 if test -z "$ac_sed_cmds"; then
23385 ac_sed_cmds=cat
23386 fi
23387fi # test -n "$CONFIG_FILES"
ba4481b5 23388
c0d27fcc
MR
23389_ACEOF
23390cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 23391for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 23392 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
23393 case $ac_file in
23394 - | *:- | *:-:* ) # input from stdin
edfaf76d
LK
23395 cat >$tmp/stdin
23396 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23397 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 23398 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
edfaf76d 23399 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 23400 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
23401 esac
23402
503d2be0 23403 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
23404 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23405$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
23406 X"$ac_file" : 'X\(//\)[^/]' \| \
23407 X"$ac_file" : 'X\(//\)$' \| \
23408 X"$ac_file" : 'X\(/\)' \| \
23409 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
23410echo X"$ac_file" |
23411 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23412 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23413 /^X\(\/\/\)$/{ s//\1/; q; }
23414 /^X\(\/\).*/{ s//\1/; q; }
23415 s/.*/./; q'`
6bae0ccf
DL
23416 { if $as_mkdir_p; then
23417 mkdir -p "$ac_dir"
23418 else
23419 as_dir="$ac_dir"
23420 as_dirs=
23421 while test ! -d "$as_dir"; do
23422 as_dirs="$as_dir $as_dirs"
23423 as_dir=`(dirname "$as_dir") 2>/dev/null ||
23424$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
23425 X"$as_dir" : 'X\(//\)[^/]' \| \
23426 X"$as_dir" : 'X\(//\)$' \| \
23427 X"$as_dir" : 'X\(/\)' \| \
23428 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
23429echo X"$as_dir" |
23430 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23431 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23432 /^X\(\/\/\)$/{ s//\1/; q; }
23433 /^X\(\/\).*/{ s//\1/; q; }
23434 s/.*/./; q'`
23435 done
23436 test ! -n "$as_dirs" || mkdir $as_dirs
23437 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23438echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23439 { (exit 1); exit 1; }; }; }
503d2be0 23440
c0d27fcc 23441 ac_builddir=.
98418dba 23442
c0d27fcc
MR
23443if test "$ac_dir" != .; then
23444 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23445 # A "../" for each directory in $ac_dir_suffix.
23446 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23447else
23448 ac_dir_suffix= ac_top_builddir=
23449fi
23450
23451case $srcdir in
23452 .) # No --srcdir option. We are building in place.
23453 ac_srcdir=.
23454 if test -z "$ac_top_builddir"; then
23455 ac_top_srcdir=.
23456 else
23457 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23458 fi ;;
23459 [\\/]* | ?:[\\/]* ) # Absolute path.
23460 ac_srcdir=$srcdir$ac_dir_suffix;
23461 ac_top_srcdir=$srcdir ;;
ba4481b5 23462 *) # Relative path.
c0d27fcc
MR
23463 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23464 ac_top_srcdir=$ac_top_builddir$srcdir ;;
23465esac
edfaf76d
LK
23466
23467# Do not use `cd foo && pwd` to compute absolute paths, because
23468# the directories may not exist.
23469case `pwd` in
23470.) ac_abs_builddir="$ac_dir";;
23471*)
23472 case "$ac_dir" in
23473 .) ac_abs_builddir=`pwd`;;
23474 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23475 *) ac_abs_builddir=`pwd`/"$ac_dir";;
23476 esac;;
23477esac
23478case $ac_abs_builddir in
23479.) ac_abs_top_builddir=${ac_top_builddir}.;;
23480*)
23481 case ${ac_top_builddir}. in
23482 .) ac_abs_top_builddir=$ac_abs_builddir;;
23483 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23484 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23485 esac;;
23486esac
23487case $ac_abs_builddir in
23488.) ac_abs_srcdir=$ac_srcdir;;
23489*)
23490 case $ac_srcdir in
23491 .) ac_abs_srcdir=$ac_abs_builddir;;
23492 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23493 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23494 esac;;
23495esac
23496case $ac_abs_builddir in
23497.) ac_abs_top_srcdir=$ac_top_srcdir;;
23498*)
23499 case $ac_top_srcdir in
23500 .) ac_abs_top_srcdir=$ac_abs_builddir;;
23501 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23502 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23503 esac;;
23504esac
c0d27fcc 23505
ba4481b5 23506
503d2be0
AS
23507 case $INSTALL in
23508 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 23509 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
23510 esac
23511
10a3b1a1
EZ
23512 if test x"$ac_file" != x-; then
23513 { echo "$as_me:$LINENO: creating $ac_file" >&5
23514echo "$as_me: creating $ac_file" >&6;}
23515 rm -f "$ac_file"
23516 fi
503d2be0
AS
23517 # Let's still pretend it is `configure' which instantiates (i.e., don't
23518 # use $as_me), people would be surprised to read:
c0d27fcc
MR
23519 # /* config.h. Generated by config.status. */
23520 if test x"$ac_file" = x-; then
23521 configure_input=
23522 else
23523 configure_input="$ac_file. "
23524 fi
23525 configure_input=$configure_input"Generated from `echo $ac_file_in |
edfaf76d 23526 sed 's,.*/,,'` by configure."
503d2be0
AS
23527
23528 # First look for the input files in the build tree, otherwise in the
23529 # src tree.
23530 ac_file_inputs=`IFS=:
23531 for f in $ac_file_in; do
23532 case $f in
23533 -) echo $tmp/stdin ;;
23534 [\\/$]*)
edfaf76d
LK
23535 # Absolute (can't be DOS-style, as IFS=:)
23536 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
23537echo "$as_me: error: cannot find input file: $f" >&2;}
23538 { (exit 1); exit 1; }; }
edfaf76d 23539 echo "$f";;
503d2be0 23540 *) # Relative
edfaf76d
LK
23541 if test -f "$f"; then
23542 # Build tree
23543 echo "$f"
23544 elif test -f "$srcdir/$f"; then
23545 # Source tree
23546 echo "$srcdir/$f"
23547 else
23548 # /dev/null tree
23549 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
23550echo "$as_me: error: cannot find input file: $f" >&2;}
23551 { (exit 1); exit 1; }; }
edfaf76d 23552 fi;;
503d2be0
AS
23553 esac
23554 done` || { (exit 1); exit 1; }
c0d27fcc
MR
23555_ACEOF
23556cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
23557 sed "$ac_vpsub
23558$extrasub
c0d27fcc
MR
23559_ACEOF
23560cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23561:t
23562/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23563s,@configure_input@,$configure_input,;t t
23564s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 23565s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 23566s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
23567s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
23568s,@builddir@,$ac_builddir,;t t
23569s,@abs_builddir@,$ac_abs_builddir,;t t
23570s,@top_builddir@,$ac_top_builddir,;t t
23571s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
23572s,@INSTALL@,$ac_INSTALL,;t t
23573" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23574 rm -f $tmp/stdin
23575 if test x"$ac_file" != x-; then
23576 mv $tmp/out $ac_file
23577 else
23578 cat $tmp/out
23579 rm -f $tmp/out
23580 fi
23581
23582done
c0d27fcc
MR
23583_ACEOF
23584cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 23585
503d2be0
AS
23586#
23587# CONFIG_HEADER section.
23588#
ba4481b5
DL
23589
23590# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23591# NAME is the cpp macro being defined and VALUE is the value it is being given.
23592#
23593# ac_d sets the value in "#define NAME VALUE" lines.
edfaf76d
LK
23594ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
23595ac_dB='[ ].*$,\1#\2'
503d2be0
AS
23596ac_dC=' '
23597ac_dD=',;t'
23598# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
edfaf76d 23599ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
503d2be0 23600ac_uB='$,\1#\2define\3'
ba4481b5 23601ac_uC=' '
503d2be0 23602ac_uD=',;t'
ba4481b5 23603
503d2be0 23604for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 23605 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
23606 case $ac_file in
23607 - | *:- | *:-:* ) # input from stdin
edfaf76d
LK
23608 cat >$tmp/stdin
23609 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23610 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 23611 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
edfaf76d 23612 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 23613 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
23614 esac
23615
c0d27fcc 23616 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
23617echo "$as_me: creating $ac_file" >&6;}
23618
23619 # First look for the input files in the build tree, otherwise in the
23620 # src tree.
23621 ac_file_inputs=`IFS=:
23622 for f in $ac_file_in; do
23623 case $f in
23624 -) echo $tmp/stdin ;;
23625 [\\/$]*)
edfaf76d
LK
23626 # Absolute (can't be DOS-style, as IFS=:)
23627 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
23628echo "$as_me: error: cannot find input file: $f" >&2;}
23629 { (exit 1); exit 1; }; }
edfaf76d
LK
23630 # Do quote $f, to prevent DOS paths from being IFS'd.
23631 echo "$f";;
503d2be0 23632 *) # Relative
edfaf76d
LK
23633 if test -f "$f"; then
23634 # Build tree
23635 echo "$f"
23636 elif test -f "$srcdir/$f"; then
23637 # Source tree
23638 echo "$srcdir/$f"
23639 else
23640 # /dev/null tree
23641 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
23642echo "$as_me: error: cannot find input file: $f" >&2;}
23643 { (exit 1); exit 1; }; }
edfaf76d 23644 fi;;
503d2be0
AS
23645 esac
23646 done` || { (exit 1); exit 1; }
23647 # Remove the trailing spaces.
edfaf76d 23648 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
503d2be0 23649
c0d27fcc 23650_ACEOF
503d2be0
AS
23651
23652# Transform confdefs.h into two sed scripts, `conftest.defines' and
23653# `conftest.undefs', that substitutes the proper values into
23654# config.h.in to produce config.h. The first handles `#define'
23655# templates, and the second `#undef' templates.
23656# And first: Protect against being on the right side of a sed subst in
23657# config.status. Protect against being in an unquoted here document
23658# in config.status.
23659rm -f conftest.defines conftest.undefs
23660# Using a here document instead of a string reduces the quoting nightmare.
23661# Putting comments in sed scripts is not portable.
23662#
23663# `end' is used to avoid that the second main sed command (meant for
23664# 0-ary CPP macros) applies to n-ary macro definitions.
23665# See the Autoconf documentation for `clear'.
c0d27fcc 23666cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
23667s/[\\&,]/\\&/g
23668s,[\\$`],\\&,g
23669t clear
23670: clear
edfaf76d 23671s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0 23672t end
edfaf76d 23673s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
503d2be0 23674: end
c0d27fcc 23675_ACEOF
503d2be0
AS
23676# If some macros were called several times there might be several times
23677# the same #defines, which is useless. Nevertheless, we may not want to
23678# sort them, since we want the *last* AC-DEFINE to be honored.
23679uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
23680sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
23681rm -f confdef2sed.sed
ba4481b5
DL
23682
23683# This sed command replaces #undef with comments. This is necessary, for
23684# example, in the case of _POSIX_SOURCE, which is predefined and required
23685# on some systems where configure will not decide to define it.
c0d27fcc 23686cat >>conftest.undefs <<\_ACEOF
edfaf76d 23687s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 23688_ACEOF
ba4481b5 23689
503d2be0
AS
23690# Break up conftest.defines because some shells have a limit on the size
23691# of here documents, and old seds have small limits too (100 cmds).
23692echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
edfaf76d 23693echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
23694echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
23695echo ' :' >>$CONFIG_STATUS
23696rm -f conftest.tail
23697while grep . conftest.defines >/dev/null
23698do
23699 # Write a limited-size here document to $tmp/defines.sed.
23700 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
23701 # Speed up: don't consider the non `#define' lines.
edfaf76d 23702 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
503d2be0
AS
23703 # Work around the forget-to-reset-the-flag bug.
23704 echo 't clr' >>$CONFIG_STATUS
23705 echo ': clr' >>$CONFIG_STATUS
23706 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
23707 echo 'CEOF
23708 sed -f $tmp/defines.sed $tmp/in >$tmp/out
23709 rm -f $tmp/in
23710 mv $tmp/out $tmp/in
23711' >>$CONFIG_STATUS
23712 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
23713 rm -f conftest.defines
23714 mv conftest.tail conftest.defines
23715done
23716rm -f conftest.defines
6bae0ccf 23717echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 23718echo >>$CONFIG_STATUS
ba4481b5 23719
503d2be0
AS
23720# Break up conftest.undefs because some shells have a limit on the size
23721# of here documents, and old seds have small limits too (100 cmds).
23722echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 23723rm -f conftest.tail
503d2be0 23724while grep . conftest.undefs >/dev/null
ba4481b5 23725do
503d2be0
AS
23726 # Write a limited-size here document to $tmp/undefs.sed.
23727 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
23728 # Speed up: don't consider the non `#undef'
edfaf76d 23729 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
503d2be0
AS
23730 # Work around the forget-to-reset-the-flag bug.
23731 echo 't clr' >>$CONFIG_STATUS
23732 echo ': clr' >>$CONFIG_STATUS
23733 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 23734 echo 'CEOF
503d2be0
AS
23735 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
23736 rm -f $tmp/in
23737 mv $tmp/out $tmp/in
23738' >>$CONFIG_STATUS
23739 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
23740 rm -f conftest.undefs
23741 mv conftest.tail conftest.undefs
ba4481b5 23742done
503d2be0
AS
23743rm -f conftest.undefs
23744
c0d27fcc 23745cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23746 # Let's still pretend it is `configure' which instantiates (i.e., don't
23747 # use $as_me), people would be surprised to read:
c0d27fcc 23748 # /* config.h. Generated by config.status. */
503d2be0 23749 if test x"$ac_file" = x-; then
c0d27fcc 23750 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 23751 else
c0d27fcc 23752 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
23753 fi
23754 cat $tmp/in >>$tmp/config.h
23755 rm -f $tmp/in
23756 if test x"$ac_file" != x-; then
19650fd6 23757 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 23758 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
23759echo "$as_me: $ac_file is unchanged" >&6;}
23760 else
c0d27fcc
MR
23761 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23762$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
23763 X"$ac_file" : 'X\(//\)[^/]' \| \
23764 X"$ac_file" : 'X\(//\)$' \| \
23765 X"$ac_file" : 'X\(/\)' \| \
23766 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
23767echo X"$ac_file" |
23768 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23769 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23770 /^X\(\/\/\)$/{ s//\1/; q; }
23771 /^X\(\/\).*/{ s//\1/; q; }
23772 s/.*/./; q'`
6bae0ccf
DL
23773 { if $as_mkdir_p; then
23774 mkdir -p "$ac_dir"
23775 else
23776 as_dir="$ac_dir"
23777 as_dirs=
23778 while test ! -d "$as_dir"; do
23779 as_dirs="$as_dir $as_dirs"
23780 as_dir=`(dirname "$as_dir") 2>/dev/null ||
23781$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
23782 X"$as_dir" : 'X\(//\)[^/]' \| \
23783 X"$as_dir" : 'X\(//\)$' \| \
23784 X"$as_dir" : 'X\(/\)' \| \
23785 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
23786echo X"$as_dir" |
23787 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23788 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23789 /^X\(\/\/\)$/{ s//\1/; q; }
23790 /^X\(\/\).*/{ s//\1/; q; }
23791 s/.*/./; q'`
23792 done
23793 test ! -n "$as_dirs" || mkdir $as_dirs
23794 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23795echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23796 { (exit 1); exit 1; }; }; }
503d2be0 23797
503d2be0
AS
23798 rm -f $ac_file
23799 mv $tmp/config.h $ac_file
ba4481b5 23800 fi
503d2be0
AS
23801 else
23802 cat $tmp/config.h
23803 rm -f $tmp/config.h
ba4481b5 23804 fi
503d2be0 23805done
c0d27fcc
MR
23806_ACEOF
23807cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
23808
23809#
23810# CONFIG_COMMANDS section.
23811#
23812for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23813 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23814 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
23815 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
23816$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
edfaf76d
LK
23817 X"$ac_dest" : 'X\(//\)[^/]' \| \
23818 X"$ac_dest" : 'X\(//\)$' \| \
23819 X"$ac_dest" : 'X\(/\)' \| \
23820 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
23821echo X"$ac_dest" |
23822 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23823 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23824 /^X\(\/\/\)$/{ s//\1/; q; }
23825 /^X\(\/\).*/{ s//\1/; q; }
23826 s/.*/./; q'`
edfaf76d
LK
23827 { if $as_mkdir_p; then
23828 mkdir -p "$ac_dir"
23829 else
23830 as_dir="$ac_dir"
23831 as_dirs=
23832 while test ! -d "$as_dir"; do
23833 as_dirs="$as_dir $as_dirs"
23834 as_dir=`(dirname "$as_dir") 2>/dev/null ||
23835$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23836 X"$as_dir" : 'X\(//\)[^/]' \| \
23837 X"$as_dir" : 'X\(//\)$' \| \
23838 X"$as_dir" : 'X\(/\)' \| \
23839 . : '\(.\)' 2>/dev/null ||
23840echo X"$as_dir" |
23841 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23842 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23843 /^X\(\/\/\)$/{ s//\1/; q; }
23844 /^X\(\/\).*/{ s//\1/; q; }
23845 s/.*/./; q'`
23846 done
23847 test ! -n "$as_dirs" || mkdir $as_dirs
23848 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23849echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23850 { (exit 1); exit 1; }; }; }
23851
c0d27fcc
MR
23852 ac_builddir=.
23853
23854if test "$ac_dir" != .; then
23855 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23856 # A "../" for each directory in $ac_dir_suffix.
23857 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23858else
23859 ac_dir_suffix= ac_top_builddir=
23860fi
23861
23862case $srcdir in
23863 .) # No --srcdir option. We are building in place.
23864 ac_srcdir=.
23865 if test -z "$ac_top_builddir"; then
23866 ac_top_srcdir=.
23867 else
23868 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23869 fi ;;
23870 [\\/]* | ?:[\\/]* ) # Absolute path.
23871 ac_srcdir=$srcdir$ac_dir_suffix;
23872 ac_top_srcdir=$srcdir ;;
23873 *) # Relative path.
23874 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23875 ac_top_srcdir=$ac_top_builddir$srcdir ;;
23876esac
edfaf76d
LK
23877
23878# Do not use `cd foo && pwd` to compute absolute paths, because
23879# the directories may not exist.
23880case `pwd` in
23881.) ac_abs_builddir="$ac_dir";;
23882*)
23883 case "$ac_dir" in
23884 .) ac_abs_builddir=`pwd`;;
23885 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23886 *) ac_abs_builddir=`pwd`/"$ac_dir";;
23887 esac;;
23888esac
23889case $ac_abs_builddir in
23890.) ac_abs_top_builddir=${ac_top_builddir}.;;
23891*)
23892 case ${ac_top_builddir}. in
23893 .) ac_abs_top_builddir=$ac_abs_builddir;;
23894 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23895 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23896 esac;;
23897esac
23898case $ac_abs_builddir in
23899.) ac_abs_srcdir=$ac_srcdir;;
23900*)
23901 case $ac_srcdir in
23902 .) ac_abs_srcdir=$ac_abs_builddir;;
23903 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23904 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23905 esac;;
23906esac
23907case $ac_abs_builddir in
23908.) ac_abs_top_srcdir=$ac_top_srcdir;;
23909*)
23910 case $ac_top_srcdir in
23911 .) ac_abs_top_srcdir=$ac_abs_builddir;;
23912 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23913 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23914 esac;;
23915esac
ba4481b5 23916
c0d27fcc
MR
23917
23918 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
23919echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
23920 case $ac_dest in
23921 default )
ba4481b5
DL
23922
23923### Make the necessary directories, if they don't exist.
23924for dir in etc lisp ; do
23925 test -d ${dir} || mkdir ${dir}
23926done
23927
23928# Build src/Makefile from ${srcdir}/src/Makefile.c
23929# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
23930# This must be done after src/config.h is built, since we rely on that file.
23931
23932# Now get this: Some word that is part of the ${srcdir} directory name
23933# or the ${configuration} value might, just might, happen to be an
23934# identifier like `sun4' or `i386' or something, and be predefined by
23935# the C preprocessor to some helpful value like 1, or maybe the empty
23936# string. Needless to say consequent macro substitutions are less
23937# than conducive to the makefile finding the correct directory.
23938undefs="`echo $top_srcdir $configuration $canonical |
23939sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
23940 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
23941`"
23942
23943echo creating src/epaths.h
4aa6b955 23944${MAKE-make} epaths-force
ba4481b5 23945
1c203d4c
DL
23946# As of 2000-11-19, newest development versions of GNU cpp preprocess
23947# `..' to `. .' unless invoked with -traditional
23948
d0e9bfd2 23949if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
23950 CPPFLAGS="$CPPFLAGS -traditional"
23951fi
23952
ba4481b5
DL
23953echo creating lib-src/Makefile
23954( cd lib-src
23955 rm -f junk.c junk1.c junk2.c
23956 sed -e '/start of cpp stuff/q' \
23957 < Makefile.c > junk1.c
23958 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 23959 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 23960 < Makefile.c > junk.c
503d2be0 23961 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
23962 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
23963 cat junk1.c junk2.c > Makefile.new
23964 rm -f junk.c junk1.c junk2.c
23965 chmod 444 Makefile.new
23966 mv -f Makefile.new Makefile
23967)
23968
23969echo creating src/Makefile
23970( cd src
23971 rm -f junk.c junk1.c junk2.c
23972 sed -e '/start of cpp stuff/q' \
23973 < Makefile.c > junk1.c
23974 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 23975 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 23976 < Makefile.c > junk.c
503d2be0 23977 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
23978 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
23979 cat junk1.c junk2.c > Makefile.new
23980 rm -f junk.c junk1.c junk2.c
23981 chmod 444 Makefile.new
23982 mv -f Makefile.new Makefile
23983)
23984
503d2be0 23985if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 23986 echo creating src/.gdbinit
503d2be0 23987 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
23988fi
23989
23990# This is how we know whether to re-run configure in certain cases.
23991touch src/config.stamp
23992
503d2be0
AS
23993 ;;
23994 esac
23995done
c0d27fcc 23996_ACEOF
503d2be0 23997
c0d27fcc 23998cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 23999
503d2be0 24000{ (exit 0); exit 0; }
c0d27fcc 24001_ACEOF
ba4481b5 24002chmod +x $CONFIG_STATUS
503d2be0
AS
24003ac_clean_files=$ac_clean_files_save
24004
c0d27fcc 24005
503d2be0
AS
24006# configure is writing to config.log, and then calls config.status.
24007# config.status does its own redirection, appending to config.log.
24008# Unfortunately, on DOS this fails, as config.log is still kept open
24009# by configure, so config.status won't be able to write to it; its
24010# output is simply discarded. So we exec the FD to /dev/null,
24011# effectively closing config.log, so it can be properly (re)opened and
24012# appended to by config.status. When coming back to configure, we
24013# need to make the FD available again.
24014if test "$no_create" != yes; then
24015 ac_cs_success=:
19650fd6
AS
24016 ac_config_status_args=
24017 test "$silent" = yes &&
24018 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 24019 exec 5>/dev/null
19650fd6 24020 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
24021 exec 5>>config.log
24022 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24023 # would make configure fail if this is the last instruction.
24024 $ac_cs_success || { (exit 1); exit 1; }
24025fi
f5f47add 24026
c0d27fcc 24027