* configure.in (HAVE_RANDOM_HEAPSTART): Renamed HAVE_EXECSHIELD.
[bpt/emacs.git] / configure
CommitLineData
ba4481b5 1#! /bin/sh
ba4481b5 2# Guess values for system-dependent variables and create Makefiles.
35996d22 3# Generated by GNU Autoconf 2.59.
ba4481b5 4#
35996d22 5# Copyright (C) 2003 Free Software Foundation, Inc.
ba4481b5
DL
6# This configure script is free software; the Free Software Foundation
7# gives unlimited permission to copy, distribute and modify it.
c0d27fcc
MR
8## --------------------- ##
9## M4sh Initialization. ##
10## --------------------- ##
503d2be0
AS
11
12# Be Bourne compatible
13if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
14 emulate sh
15 NULLCMD=:
6bae0ccf
DL
16 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
17 # is contrary to our usage. Disable this feature.
18 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
19elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20 set -o posix
21fi
35996d22 22DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 23
c0d27fcc 24# Support unset when possible.
35996d22 25if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
26 as_unset=unset
27else
28 as_unset=false
29fi
30
6bae0ccf
DL
31
32# Work around bugs in pre-3.0 UWIN ksh.
33$as_unset ENV MAIL MAILPATH
34PS1='$ '
35PS2='> '
36PS4='+ '
37
38# NLS nuisances.
19650fd6
AS
39for as_var in \
40 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
41 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
42 LC_TELEPHONE LC_TIME
6bae0ccf 43do
35996d22 44 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
45 eval $as_var=C; export $as_var
46 else
47 $as_unset $as_var
48 fi
49done
50
51# Required to use basename.
52if expr a : '\(a\)' >/dev/null 2>&1; then
53 as_expr=expr
54else
55 as_expr=false
56fi
57
58if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
59 as_basename=basename
60else
61 as_basename=false
62fi
c0d27fcc
MR
63
64
503d2be0 65# Name of the executable.
6bae0ccf 66as_me=`$as_basename "$0" ||
c0d27fcc
MR
67$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
68 X"$0" : 'X\(//\)$' \| \
69 X"$0" : 'X\(/\)$' \| \
70 . : '\(.\)' 2>/dev/null ||
71echo X/"$0" |
72 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
73 /^X\/\(\/\/\)$/{ s//\1/; q; }
74 /^X\/\(\/\).*/{ s//\1/; q; }
75 s/.*/./; q'`
76
6bae0ccf 77
c0d27fcc
MR
78# PATH needs CR, and LINENO needs CR and PATH.
79# Avoid depending upon Character Ranges.
80as_cr_letters='abcdefghijklmnopqrstuvwxyz'
81as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
82as_cr_Letters=$as_cr_letters$as_cr_LETTERS
83as_cr_digits='0123456789'
84as_cr_alnum=$as_cr_Letters$as_cr_digits
85
86# The user is always right.
87if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
88 echo "#! /bin/sh" >conf$$.sh
89 echo "exit 0" >>conf$$.sh
90 chmod +x conf$$.sh
91 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
92 PATH_SEPARATOR=';'
93 else
94 PATH_SEPARATOR=:
95 fi
19650fd6 96 rm -f conf$$.sh
c0d27fcc
MR
97fi
98
99
100 as_lineno_1=$LINENO
101 as_lineno_2=$LINENO
102 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
103 test "x$as_lineno_1" != "x$as_lineno_2" &&
104 test "x$as_lineno_3" = "x$as_lineno_2" || {
105 # Find who we are. Look in the path if we contain no path at all
106 # relative or not.
107 case $0 in
108 *[\\/]* ) as_myself=$0 ;;
109 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
110for as_dir in $PATH
111do
112 IFS=$as_save_IFS
113 test -z "$as_dir" && as_dir=.
114 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
115done
116
117 ;;
118 esac
119 # We did not find ourselves, most probably we were run as `sh COMMAND'
120 # in which case we are not to be found in the path.
121 if test "x$as_myself" = x; then
122 as_myself=$0
123 fi
124 if test ! -f "$as_myself"; then
125 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
126 { (exit 1); exit 1; }; }
127 fi
128 case $CONFIG_SHELL in
129 '')
130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
131for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
132do
133 IFS=$as_save_IFS
134 test -z "$as_dir" && as_dir=.
135 for as_base in sh bash ksh sh5; do
136 case $as_dir in
137 /*)
138 if ("$as_dir/$as_base" -c '
139 as_lineno_1=$LINENO
140 as_lineno_2=$LINENO
141 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
142 test "x$as_lineno_1" != "x$as_lineno_2" &&
143 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
144 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
145 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
146 CONFIG_SHELL=$as_dir/$as_base
147 export CONFIG_SHELL
148 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
149 fi;;
150 esac
151 done
152done
153;;
154 esac
155
156 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
157 # uniformly replaced by the line number. The first 'sed' inserts a
158 # line-number line before each line; the second 'sed' does the real
159 # work. The second script uses 'N' to pair each line-number line
160 # with the numbered line, and appends trailing '-' during
161 # substitution so that $LINENO is not a special case at line end.
162 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
163 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
164 sed '=' <$as_myself |
165 sed '
166 N
167 s,$,-,
168 : loop
169 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
170 t loop
171 s,-$,,
172 s,^['$as_cr_digits']*\n,,
173 ' >$as_me.lineno &&
174 chmod +x $as_me.lineno ||
175 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
176 { (exit 1); exit 1; }; }
177
178 # Don't try to exec as it changes $[0], causing all sort of problems
179 # (the dirname of $[0] is not the place where we might find the
180 # original and so on. Autoconf is especially sensible to this).
181 . ./$as_me.lineno
182 # Exit status is that of the last command.
183 exit
184}
185
186
187case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
188 *c*,-n*) ECHO_N= ECHO_C='
189' ECHO_T=' ' ;;
190 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
191 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
192esac
503d2be0
AS
193
194if expr a : '\(a\)' >/dev/null 2>&1; then
195 as_expr=expr
196else
197 as_expr=false
198fi
199
200rm -f conf$$ conf$$.exe conf$$.file
201echo >conf$$.file
202if ln -s conf$$.file conf$$ 2>/dev/null; then
203 # We could just check for DJGPP; but this test a) works b) is more generic
204 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
205 if test -f conf$$.exe; then
206 # Don't use ln at all; we don't have any links
207 as_ln_s='cp -p'
208 else
209 as_ln_s='ln -s'
210 fi
211elif ln conf$$.file conf$$ 2>/dev/null; then
212 as_ln_s=ln
213else
214 as_ln_s='cp -p'
215fi
216rm -f conf$$ conf$$.exe conf$$.file
217
6bae0ccf
DL
218if mkdir -p . 2>/dev/null; then
219 as_mkdir_p=:
220else
35996d22 221 test -d ./-p && rmdir ./-p
6bae0ccf
DL
222 as_mkdir_p=false
223fi
224
503d2be0
AS
225as_executable_p="test -f"
226
c0d27fcc 227# Sed expression to map a string onto a valid CPP name.
35996d22 228as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
229
230# Sed expression to map a string onto a valid variable name.
35996d22 231as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 232
503d2be0
AS
233
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" $as_nl"
239
240# CDPATH.
6bae0ccf 241$as_unset CDPATH
c0d27fcc 242
503d2be0
AS
243
244# Name of the host.
245# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246# so uname gets run too.
247ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249exec 6>&1
250
251#
252# Initializations.
253#
ba4481b5 254ac_default_prefix=/usr/local
6bae0ccf 255ac_config_libobj_dir=.
503d2be0
AS
256cross_compiling=no
257subdirs=
c0d27fcc
MR
258MFLAGS=
259MAKEFLAGS=
503d2be0
AS
260SHELL=${CONFIG_SHELL-/bin/sh}
261
262# Maximum number of lines to put in a shell here document.
263# This variable seems obsolete. It should probably be removed, and
264# only ac_max_sed_lines should be used.
265: ${ac_max_here_lines=38}
266
c0d27fcc
MR
267# Identity of this package.
268PACKAGE_NAME=
269PACKAGE_TARNAME=
270PACKAGE_VERSION=
271PACKAGE_STRING=
272PACKAGE_BUGREPORT=
273
503d2be0 274ac_unique_file="src/lisp.h"
6bae0ccf 275ac_config_libobj_dir=src
503d2be0
AS
276# Factoring default headers for most tests.
277ac_includes_default="\
278#include <stdio.h>
279#if HAVE_SYS_TYPES_H
280# include <sys/types.h>
281#endif
282#if HAVE_SYS_STAT_H
283# include <sys/stat.h>
284#endif
285#if STDC_HEADERS
286# include <stdlib.h>
287# include <stddef.h>
288#else
289# if HAVE_STDLIB_H
290# include <stdlib.h>
291# endif
292#endif
293#if HAVE_STRING_H
294# if !STDC_HEADERS && HAVE_MEMORY_H
295# include <memory.h>
296# endif
297# include <string.h>
298#endif
299#if HAVE_STRINGS_H
300# include <strings.h>
301#endif
302#if HAVE_INTTYPES_H
303# include <inttypes.h>
304#else
305# if HAVE_STDINT_H
306# include <stdint.h>
307# endif
308#endif
309#if HAVE_UNISTD_H
310# include <unistd.h>
311#endif"
ba4481b5 312
4494a266 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 SETARCH SET_MAKE PKG_CONFIG GTK_CFLAGS GTK_LIBS ALLOCA liblockfile LIBOBJS NEED_SETGID KMEM_GROUP GETLOADAVG_LIBS version configuration canonical srcdir lispdir locallisppath lisppath x_default_search_path etcdir archlibdir docdir bitmapdir gamedir gameuser c_switch_system c_switch_machine LD_SWITCH_X_SITE LD_SWITCH_X_SITE_AUX C_SWITCH_X_SITE X_TOOLKIT_TYPE machfile opsysfile carbon_appdir LTLIBOBJS'
6bae0ccf 314ac_subst_files=''
c0d27fcc 315
ba4481b5 316# Initialize some variables set by options.
503d2be0
AS
317ac_init_help=
318ac_init_version=false
ba4481b5
DL
319# The variables have the same names as the options, with
320# dashes changed to underlines.
503d2be0 321cache_file=/dev/null
ba4481b5 322exec_prefix=NONE
ba4481b5 323no_create=
ba4481b5
DL
324no_recursion=
325prefix=NONE
326program_prefix=NONE
327program_suffix=NONE
328program_transform_name=s,x,x,
329silent=
330site=
331srcdir=
ba4481b5
DL
332verbose=
333x_includes=NONE
334x_libraries=NONE
503d2be0
AS
335
336# Installation directory options.
337# These are left unexpanded so users can "make install exec_prefix=/foo"
338# and all the variables that are supposed to be based on exec_prefix
339# by default will actually change.
340# Use braces instead of parens because sh, perl, etc. also accept them.
ba4481b5
DL
341bindir='${exec_prefix}/bin'
342sbindir='${exec_prefix}/sbin'
343libexecdir='${exec_prefix}/libexec'
344datadir='${prefix}/share'
345sysconfdir='${prefix}/etc'
346sharedstatedir='${prefix}/com'
347localstatedir='${prefix}/var'
348libdir='${exec_prefix}/lib'
349includedir='${prefix}/include'
350oldincludedir='/usr/include'
351infodir='${prefix}/info'
352mandir='${prefix}/man'
353
ba4481b5
DL
354ac_prev=
355for ac_option
356do
ba4481b5
DL
357 # If the previous option needs an argument, assign it.
358 if test -n "$ac_prev"; then
359 eval "$ac_prev=\$ac_option"
360 ac_prev=
361 continue
362 fi
363
503d2be0 364 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
ba4481b5
DL
365
366 # Accept the important Cygnus configure options, so we can diagnose typos.
367
503d2be0 368 case $ac_option in
ba4481b5
DL
369
370 -bindir | --bindir | --bindi | --bind | --bin | --bi)
371 ac_prev=bindir ;;
372 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
503d2be0 373 bindir=$ac_optarg ;;
ba4481b5
DL
374
375 -build | --build | --buil | --bui | --bu)
503d2be0 376 ac_prev=build_alias ;;
ba4481b5 377 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
503d2be0 378 build_alias=$ac_optarg ;;
ba4481b5
DL
379
380 -cache-file | --cache-file | --cache-fil | --cache-fi \
381 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
382 ac_prev=cache_file ;;
383 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
384 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
503d2be0
AS
385 cache_file=$ac_optarg ;;
386
387 --config-cache | -C)
388 cache_file=config.cache ;;
ba4481b5
DL
389
390 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
391 ac_prev=datadir ;;
392 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
393 | --da=*)
503d2be0 394 datadir=$ac_optarg ;;
ba4481b5
DL
395
396 -disable-* | --disable-*)
503d2be0 397 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
ba4481b5 398 # Reject names that are not valid shell variable names.
503d2be0
AS
399 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
400 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
401 { (exit 1); exit 1; }; }
402 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
403 eval "enable_$ac_feature=no" ;;
ba4481b5
DL
404
405 -enable-* | --enable-*)
503d2be0 406 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
ba4481b5 407 # Reject names that are not valid shell variable names.
503d2be0
AS
408 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
409 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
410 { (exit 1); exit 1; }; }
411 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
412 case $ac_option in
413 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
414 *) ac_optarg=yes ;;
415 esac
503d2be0 416 eval "enable_$ac_feature='$ac_optarg'" ;;
ba4481b5
DL
417
418 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
419 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
420 | --exec | --exe | --ex)
421 ac_prev=exec_prefix ;;
422 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
423 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
424 | --exec=* | --exe=* | --ex=*)
503d2be0 425 exec_prefix=$ac_optarg ;;
ba4481b5
DL
426
427 -gas | --gas | --ga | --g)
428 # Obsolete; use --with-gas.
429 with_gas=yes ;;
430
503d2be0
AS
431 -help | --help | --hel | --he | -h)
432 ac_init_help=long ;;
433 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
434 ac_init_help=recursive ;;
435 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
436 ac_init_help=short ;;
ba4481b5
DL
437
438 -host | --host | --hos | --ho)
503d2be0 439 ac_prev=host_alias ;;
ba4481b5 440 -host=* | --host=* | --hos=* | --ho=*)
503d2be0 441 host_alias=$ac_optarg ;;
ba4481b5
DL
442
443 -includedir | --includedir | --includedi | --included | --include \
444 | --includ | --inclu | --incl | --inc)
445 ac_prev=includedir ;;
446 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
447 | --includ=* | --inclu=* | --incl=* | --inc=*)
503d2be0 448 includedir=$ac_optarg ;;
ba4481b5
DL
449
450 -infodir | --infodir | --infodi | --infod | --info | --inf)
451 ac_prev=infodir ;;
452 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
503d2be0 453 infodir=$ac_optarg ;;
ba4481b5
DL
454
455 -libdir | --libdir | --libdi | --libd)
456 ac_prev=libdir ;;
457 -libdir=* | --libdir=* | --libdi=* | --libd=*)
503d2be0 458 libdir=$ac_optarg ;;
ba4481b5
DL
459
460 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
461 | --libexe | --libex | --libe)
462 ac_prev=libexecdir ;;
463 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
464 | --libexe=* | --libex=* | --libe=*)
503d2be0 465 libexecdir=$ac_optarg ;;
ba4481b5
DL
466
467 -localstatedir | --localstatedir | --localstatedi | --localstated \
468 | --localstate | --localstat | --localsta | --localst \
469 | --locals | --local | --loca | --loc | --lo)
470 ac_prev=localstatedir ;;
471 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
472 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
473 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
503d2be0 474 localstatedir=$ac_optarg ;;
ba4481b5
DL
475
476 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
477 ac_prev=mandir ;;
478 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
503d2be0 479 mandir=$ac_optarg ;;
ba4481b5
DL
480
481 -nfp | --nfp | --nf)
482 # Obsolete; use --without-fp.
483 with_fp=no ;;
484
485 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
c0d27fcc 486 | --no-cr | --no-c | -n)
ba4481b5
DL
487 no_create=yes ;;
488
489 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
490 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
491 no_recursion=yes ;;
492
493 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
494 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
495 | --oldin | --oldi | --old | --ol | --o)
496 ac_prev=oldincludedir ;;
497 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
498 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
499 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
503d2be0 500 oldincludedir=$ac_optarg ;;
ba4481b5
DL
501
502 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
503 ac_prev=prefix ;;
504 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
503d2be0 505 prefix=$ac_optarg ;;
ba4481b5
DL
506
507 -program-prefix | --program-prefix | --program-prefi | --program-pref \
508 | --program-pre | --program-pr | --program-p)
509 ac_prev=program_prefix ;;
510 -program-prefix=* | --program-prefix=* | --program-prefi=* \
511 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
503d2be0 512 program_prefix=$ac_optarg ;;
ba4481b5
DL
513
514 -program-suffix | --program-suffix | --program-suffi | --program-suff \
515 | --program-suf | --program-su | --program-s)
516 ac_prev=program_suffix ;;
517 -program-suffix=* | --program-suffix=* | --program-suffi=* \
518 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
503d2be0 519 program_suffix=$ac_optarg ;;
ba4481b5
DL
520
521 -program-transform-name | --program-transform-name \
522 | --program-transform-nam | --program-transform-na \
523 | --program-transform-n | --program-transform- \
524 | --program-transform | --program-transfor \
525 | --program-transfo | --program-transf \
526 | --program-trans | --program-tran \
527 | --progr-tra | --program-tr | --program-t)
528 ac_prev=program_transform_name ;;
529 -program-transform-name=* | --program-transform-name=* \
530 | --program-transform-nam=* | --program-transform-na=* \
531 | --program-transform-n=* | --program-transform-=* \
532 | --program-transform=* | --program-transfor=* \
533 | --program-transfo=* | --program-transf=* \
534 | --program-trans=* | --program-tran=* \
535 | --progr-tra=* | --program-tr=* | --program-t=*)
503d2be0 536 program_transform_name=$ac_optarg ;;
ba4481b5
DL
537
538 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
539 | -silent | --silent | --silen | --sile | --sil)
540 silent=yes ;;
541
542 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
543 ac_prev=sbindir ;;
544 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
545 | --sbi=* | --sb=*)
503d2be0 546 sbindir=$ac_optarg ;;
ba4481b5
DL
547
548 -sharedstatedir | --sharedstatedir | --sharedstatedi \
549 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
550 | --sharedst | --shareds | --shared | --share | --shar \
551 | --sha | --sh)
552 ac_prev=sharedstatedir ;;
553 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
554 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
555 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
556 | --sha=* | --sh=*)
503d2be0 557 sharedstatedir=$ac_optarg ;;
ba4481b5
DL
558
559 -site | --site | --sit)
560 ac_prev=site ;;
561 -site=* | --site=* | --sit=*)
503d2be0 562 site=$ac_optarg ;;
ba4481b5
DL
563
564 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
565 ac_prev=srcdir ;;
566 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
503d2be0 567 srcdir=$ac_optarg ;;
ba4481b5
DL
568
569 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
570 | --syscon | --sysco | --sysc | --sys | --sy)
571 ac_prev=sysconfdir ;;
572 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
573 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
503d2be0 574 sysconfdir=$ac_optarg ;;
ba4481b5
DL
575
576 -target | --target | --targe | --targ | --tar | --ta | --t)
503d2be0 577 ac_prev=target_alias ;;
ba4481b5 578 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
503d2be0 579 target_alias=$ac_optarg ;;
ba4481b5
DL
580
581 -v | -verbose | --verbose | --verbos | --verbo | --verb)
582 verbose=yes ;;
583
503d2be0
AS
584 -version | --version | --versio | --versi | --vers | -V)
585 ac_init_version=: ;;
ba4481b5
DL
586
587 -with-* | --with-*)
503d2be0 588 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
ba4481b5 589 # Reject names that are not valid shell variable names.
503d2be0
AS
590 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
591 { echo "$as_me: error: invalid package name: $ac_package" >&2
592 { (exit 1); exit 1; }; }
ba4481b5 593 ac_package=`echo $ac_package| sed 's/-/_/g'`
503d2be0
AS
594 case $ac_option in
595 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
596 *) ac_optarg=yes ;;
597 esac
503d2be0 598 eval "with_$ac_package='$ac_optarg'" ;;
ba4481b5
DL
599
600 -without-* | --without-*)
503d2be0 601 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
ba4481b5 602 # Reject names that are not valid shell variable names.
503d2be0
AS
603 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
604 { echo "$as_me: error: invalid package name: $ac_package" >&2
605 { (exit 1); exit 1; }; }
606 ac_package=`echo $ac_package | sed 's/-/_/g'`
607 eval "with_$ac_package=no" ;;
ba4481b5
DL
608
609 --x)
610 # Obsolete; use --with-x.
611 with_x=yes ;;
612
613 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
614 | --x-incl | --x-inc | --x-in | --x-i)
615 ac_prev=x_includes ;;
616 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
617 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
503d2be0 618 x_includes=$ac_optarg ;;
ba4481b5
DL
619
620 -x-libraries | --x-libraries | --x-librarie | --x-librari \
621 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
622 ac_prev=x_libraries ;;
623 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
624 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
503d2be0 625 x_libraries=$ac_optarg ;;
ba4481b5 626
503d2be0
AS
627 -*) { echo "$as_me: error: unrecognized option: $ac_option
628Try \`$0 --help' for more information." >&2
629 { (exit 1); exit 1; }; }
ba4481b5
DL
630 ;;
631
503d2be0
AS
632 *=*)
633 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
634 # Reject names that are not valid shell variable names.
635 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
636 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
637 { (exit 1); exit 1; }; }
638 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
639 eval "$ac_envvar='$ac_optarg'"
640 export $ac_envvar ;;
641
ba4481b5 642 *)
503d2be0
AS
643 # FIXME: should be removed in autoconf 3.0.
644 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
645 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
646 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
647 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
ba4481b5
DL
648 ;;
649
650 esac
651done
652
653if test -n "$ac_prev"; then
503d2be0
AS
654 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
655 { echo "$as_me: error: missing argument to $ac_option" >&2
656 { (exit 1); exit 1; }; }
ba4481b5 657fi
ba4481b5 658
503d2be0
AS
659# Be sure to have absolute paths.
660for ac_var in exec_prefix prefix
661do
662 eval ac_val=$`echo $ac_var`
663 case $ac_val in
664 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
c0d27fcc 665 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0
AS
666 { (exit 1); exit 1; }; };;
667 esac
668done
ba4481b5 669
503d2be0
AS
670# Be sure to have absolute paths.
671for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
35996d22 672 localstatedir libdir includedir oldincludedir infodir mandir
ba4481b5 673do
503d2be0
AS
674 eval ac_val=$`echo $ac_var`
675 case $ac_val in
676 [\\/$]* | ?:[\\/]* ) ;;
c0d27fcc 677 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0 678 { (exit 1); exit 1; }; };;
ba4481b5
DL
679 esac
680done
681
503d2be0
AS
682# There might be people who depend on the old broken behavior: `$host'
683# used to hold the argument of --host etc.
c0d27fcc 684# FIXME: To remove some day.
503d2be0
AS
685build=$build_alias
686host=$host_alias
687target=$target_alias
688
c0d27fcc 689# FIXME: To remove some day.
503d2be0
AS
690if test "x$host_alias" != x; then
691 if test "x$build_alias" = x; then
692 cross_compiling=maybe
693 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
694 If a cross compiler is detected then cross compile mode will be used." >&2
695 elif test "x$build_alias" != "x$host_alias"; then
696 cross_compiling=yes
697 fi
698fi
ba4481b5 699
503d2be0
AS
700ac_tool_prefix=
701test -n "$host_alias" && ac_tool_prefix=$host_alias-
ba4481b5 702
503d2be0 703test "$silent" = yes && exec 6>/dev/null
ba4481b5 704
c0d27fcc 705
ba4481b5
DL
706# Find the source files, if location was not specified.
707if test -z "$srcdir"; then
708 ac_srcdir_defaulted=yes
709 # Try the directory containing this script, then its parent.
c0d27fcc
MR
710 ac_confdir=`(dirname "$0") 2>/dev/null ||
711$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
712 X"$0" : 'X\(//\)[^/]' \| \
713 X"$0" : 'X\(//\)$' \| \
714 X"$0" : 'X\(/\)' \| \
715 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
716echo X"$0" |
717 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
718 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
719 /^X\(\/\/\)$/{ s//\1/; q; }
720 /^X\(\/\).*/{ s//\1/; q; }
721 s/.*/./; q'`
ba4481b5
DL
722 srcdir=$ac_confdir
723 if test ! -r $srcdir/$ac_unique_file; then
724 srcdir=..
725 fi
726else
727 ac_srcdir_defaulted=no
728fi
729if test ! -r $srcdir/$ac_unique_file; then
730 if test "$ac_srcdir_defaulted" = yes; then
c0d27fcc 731 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
503d2be0 732 { (exit 1); exit 1; }; }
ba4481b5 733 else
c0d27fcc 734 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
503d2be0 735 { (exit 1); exit 1; }; }
ba4481b5
DL
736 fi
737fi
6bae0ccf
DL
738(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
739 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
740 { (exit 1); exit 1; }; }
503d2be0
AS
741srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
742ac_env_build_alias_set=${build_alias+set}
743ac_env_build_alias_value=$build_alias
744ac_cv_env_build_alias_set=${build_alias+set}
745ac_cv_env_build_alias_value=$build_alias
746ac_env_host_alias_set=${host_alias+set}
747ac_env_host_alias_value=$host_alias
748ac_cv_env_host_alias_set=${host_alias+set}
749ac_cv_env_host_alias_value=$host_alias
750ac_env_target_alias_set=${target_alias+set}
751ac_env_target_alias_value=$target_alias
752ac_cv_env_target_alias_set=${target_alias+set}
753ac_cv_env_target_alias_value=$target_alias
754ac_env_CC_set=${CC+set}
755ac_env_CC_value=$CC
756ac_cv_env_CC_set=${CC+set}
757ac_cv_env_CC_value=$CC
758ac_env_CFLAGS_set=${CFLAGS+set}
759ac_env_CFLAGS_value=$CFLAGS
760ac_cv_env_CFLAGS_set=${CFLAGS+set}
761ac_cv_env_CFLAGS_value=$CFLAGS
762ac_env_LDFLAGS_set=${LDFLAGS+set}
763ac_env_LDFLAGS_value=$LDFLAGS
764ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
765ac_cv_env_LDFLAGS_value=$LDFLAGS
766ac_env_CPPFLAGS_set=${CPPFLAGS+set}
767ac_env_CPPFLAGS_value=$CPPFLAGS
768ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
769ac_cv_env_CPPFLAGS_value=$CPPFLAGS
770ac_env_CPP_set=${CPP+set}
771ac_env_CPP_value=$CPP
772ac_cv_env_CPP_set=${CPP+set}
773ac_cv_env_CPP_value=$CPP
774
775#
776# Report the --help message.
777#
778if test "$ac_init_help" = "long"; then
779 # Omit some internal or obsolete options to make the list less imposing.
780 # This message is too long to be a string in the A/UX 3.1 sh.
c0d27fcc 781 cat <<_ACEOF
503d2be0
AS
782\`configure' configures this package to adapt to many kinds of systems.
783
784Usage: $0 [OPTION]... [VAR=VALUE]...
785
786To assign environment variables (e.g., CC, CFLAGS...), specify them as
787VAR=VALUE. See below for descriptions of some of the useful variables.
788
789Defaults for the options are specified in brackets.
790
791Configuration:
792 -h, --help display this help and exit
793 --help=short display options specific to this package
794 --help=recursive display the short help of all the included packages
795 -V, --version display version information and exit
796 -q, --quiet, --silent do not print \`checking...' messages
797 --cache-file=FILE cache test results in FILE [disabled]
798 -C, --config-cache alias for \`--cache-file=config.cache'
799 -n, --no-create do not create output files
800 --srcdir=DIR find the sources in DIR [configure dir or \`..']
801
c0d27fcc 802_ACEOF
503d2be0 803
c0d27fcc 804 cat <<_ACEOF
503d2be0
AS
805Installation directories:
806 --prefix=PREFIX install architecture-independent files in PREFIX
35996d22 807 [$ac_default_prefix]
503d2be0 808 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
35996d22 809 [PREFIX]
503d2be0
AS
810
811By default, \`make install' will install all the files in
812\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
813an installation prefix other than \`$ac_default_prefix' using \`--prefix',
814for instance \`--prefix=\$HOME'.
815
816For better control, use the options below.
817
818Fine tuning of the installation directories:
819 --bindir=DIR user executables [EPREFIX/bin]
820 --sbindir=DIR system admin executables [EPREFIX/sbin]
821 --libexecdir=DIR program executables [EPREFIX/libexec]
822 --datadir=DIR read-only architecture-independent data [PREFIX/share]
823 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
824 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
825 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
826 --libdir=DIR object code libraries [EPREFIX/lib]
827 --includedir=DIR C header files [PREFIX/include]
828 --oldincludedir=DIR C header files for non-gcc [/usr/include]
829 --infodir=DIR info documentation [PREFIX/info]
830 --mandir=DIR man documentation [PREFIX/man]
c0d27fcc 831_ACEOF
503d2be0 832
c0d27fcc 833 cat <<\_ACEOF
503d2be0 834
ba5da88a
PJ
835Program names:
836 --program-prefix=PREFIX prepend PREFIX to installed program names
837 --program-suffix=SUFFIX append SUFFIX to installed program names
838 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
839
503d2be0
AS
840X features:
841 --x-includes=DIR X include files are in DIR
842 --x-libraries=DIR X library files are in DIR
843
844System types:
845 --build=BUILD configure for building on BUILD [guessed]
c0d27fcc
MR
846 --host=HOST cross-compile to build programs to run on HOST [BUILD]
847_ACEOF
503d2be0
AS
848fi
849
850if test -n "$ac_init_help"; then
851
c0d27fcc 852 cat <<\_ACEOF
503d2be0
AS
853
854Optional Features:
855 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
856 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
6a3a24fa
JD
857 --enable-carbon-app[=DIR] [DIR=/Application]
858 specify install directory for Emacs.app on Mac OS X
19650fd6
AS
859 --enable-maintainer-mode enable make rules and dependencies not useful
860 (and sometimes confusing) to the casual installer
503d2be0
AS
861 --disable-largefile omit support for large files
862
863Optional Packages:
864 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
865 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
866 --without-gcc don't use GCC to compile Emacs if GCC is found
867 --without-pop don't support POP mail retrieval with movemail
868 --with-kerberos support Kerberos-authenticated POP
869 --with-kerberos5 support Kerberos version 5 authenticated POP
870 --with-hesiod support Hesiod to get the POP server host
2c9dccc9 871 --without-sound don't compile with sound support
488dd4c4
JD
872 --with-x-toolkit=KIT use an X toolkit
873 (KIT = yes/lucid/athena/motif/gtk/no)
503d2be0
AS
874 --with-xpm use -lXpm for displaying XPM images
875 --with-jpeg use -ljpeg for displaying JPEG images
876 --with-tiff use -ltiff for displaying TIFF images
877 --with-gif use -lungif for displaying GIF images
878 --with-png use -lpng for displaying PNG images
488dd4c4
JD
879 --with-gtk use GTK (same as --with-x-toolkit=gtk)
880 --with-pkg-config-prog Path to pkg-config to use for finding GTK
503d2be0 881 --without-toolkit-scroll-bars
cc227489
MB
882 don't use Motif or Xaw3d scroll bars
883 --without-xim don't use X11 XIM
e0f712ba 884 --without-carbon don't use Carbon GUI on Mac OS X
503d2be0
AS
885 --with-x use the X Window System
886
887Some influential environment variables:
888 CC C compiler command
889 CFLAGS C compiler flags
890 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
891 nonstandard directory <lib dir>
892 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
893 headers in a nonstandard directory <include dir>
894 CPP C preprocessor
895
896Use these variables to override the choices made by `configure' or to help
897it to find libraries and programs with nonstandard names/locations.
898
c0d27fcc 899_ACEOF
503d2be0
AS
900fi
901
902if test "$ac_init_help" = "recursive"; then
903 # If there are subdirs, report their specific --help.
904 ac_popdir=`pwd`
c0d27fcc
MR
905 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
906 test -d $ac_dir || continue
907 ac_builddir=.
908
909if test "$ac_dir" != .; then
910 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
911 # A "../" for each directory in $ac_dir_suffix.
912 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
913else
914 ac_dir_suffix= ac_top_builddir=
915fi
503d2be0 916
c0d27fcc
MR
917case $srcdir in
918 .) # No --srcdir option. We are building in place.
919 ac_srcdir=.
920 if test -z "$ac_top_builddir"; then
921 ac_top_srcdir=.
922 else
923 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
924 fi ;;
925 [\\/]* | ?:[\\/]* ) # Absolute path.
926 ac_srcdir=$srcdir$ac_dir_suffix;
927 ac_top_srcdir=$srcdir ;;
928 *) # Relative path.
929 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
930 ac_top_srcdir=$ac_top_builddir$srcdir ;;
931esac
35996d22
AS
932
933# Do not use `cd foo && pwd` to compute absolute paths, because
934# the directories may not exist.
935case `pwd` in
936.) ac_abs_builddir="$ac_dir";;
937*)
938 case "$ac_dir" in
939 .) ac_abs_builddir=`pwd`;;
940 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
941 *) ac_abs_builddir=`pwd`/"$ac_dir";;
942 esac;;
943esac
944case $ac_abs_builddir in
945.) ac_abs_top_builddir=${ac_top_builddir}.;;
946*)
947 case ${ac_top_builddir}. in
948 .) ac_abs_top_builddir=$ac_abs_builddir;;
949 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
950 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
951 esac;;
952esac
953case $ac_abs_builddir in
954.) ac_abs_srcdir=$ac_srcdir;;
955*)
956 case $ac_srcdir in
957 .) ac_abs_srcdir=$ac_abs_builddir;;
958 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
959 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
960 esac;;
961esac
962case $ac_abs_builddir in
963.) ac_abs_top_srcdir=$ac_top_srcdir;;
964*)
965 case $ac_top_srcdir in
966 .) ac_abs_top_srcdir=$ac_abs_builddir;;
967 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
968 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
969 esac;;
970esac
c0d27fcc
MR
971
972 cd $ac_dir
503d2be0 973 # Check for guested configure; otherwise get Cygnus style configure.
c0d27fcc 974 if test -f $ac_srcdir/configure.gnu; then
503d2be0 975 echo
c0d27fcc
MR
976 $SHELL $ac_srcdir/configure.gnu --help=recursive
977 elif test -f $ac_srcdir/configure; then
503d2be0 978 echo
c0d27fcc
MR
979 $SHELL $ac_srcdir/configure --help=recursive
980 elif test -f $ac_srcdir/configure.ac ||
35996d22 981 test -f $ac_srcdir/configure.in; then
503d2be0
AS
982 echo
983 $ac_configure --help
984 else
c0d27fcc 985 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
503d2be0 986 fi
4494a266 987 cd $ac_popdir
503d2be0
AS
988 done
989fi
990
991test -n "$ac_init_help" && exit 0
992if $ac_init_version; then
c0d27fcc 993 cat <<\_ACEOF
503d2be0 994
35996d22 995Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
996This configure script is free software; the Free Software Foundation
997gives unlimited permission to copy, distribute and modify it.
c0d27fcc 998_ACEOF
503d2be0
AS
999 exit 0
1000fi
1001exec 5>config.log
c0d27fcc 1002cat >&5 <<_ACEOF
503d2be0
AS
1003This file contains any messages produced by compilers while
1004running configure, to aid debugging if configure makes a mistake.
1005
1006It was created by $as_me, which was
35996d22 1007generated by GNU Autoconf 2.59. Invocation command line was
503d2be0
AS
1008
1009 $ $0 $@
1010
c0d27fcc 1011_ACEOF
503d2be0
AS
1012{
1013cat <<_ASUNAME
c0d27fcc
MR
1014## --------- ##
1015## Platform. ##
1016## --------- ##
503d2be0
AS
1017
1018hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1019uname -m = `(uname -m) 2>/dev/null || echo unknown`
1020uname -r = `(uname -r) 2>/dev/null || echo unknown`
1021uname -s = `(uname -s) 2>/dev/null || echo unknown`
1022uname -v = `(uname -v) 2>/dev/null || echo unknown`
1023
1024/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1025/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1026
1027/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1028/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1029/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1030hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1031/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1032/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1033/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1034
925c2f3f 1035_ASUNAME
c0d27fcc
MR
1036
1037as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1038for as_dir in $PATH
1039do
1040 IFS=$as_save_IFS
1041 test -z "$as_dir" && as_dir=.
1042 echo "PATH: $as_dir"
1043done
1044
503d2be0
AS
1045} >&5
1046
c0d27fcc
MR
1047cat >&5 <<_ACEOF
1048
1049
1050## ----------- ##
1051## Core tests. ##
1052## ----------- ##
1053
1054_ACEOF
503d2be0 1055
503d2be0
AS
1056
1057# Keep a trace of the command line.
1058# Strip out --no-create and --no-recursion so they do not pile up.
19650fd6 1059# Strip out --silent because we don't want to record it for future runs.
503d2be0 1060# Also quote any args containing shell meta-characters.
19650fd6 1061# Make two passes to allow for proper duplicate-argument suppression.
503d2be0 1062ac_configure_args=
19650fd6
AS
1063ac_configure_args0=
1064ac_configure_args1=
503d2be0 1065ac_sep=
19650fd6
AS
1066ac_must_keep_next=false
1067for ac_pass in 1 2
503d2be0 1068do
19650fd6
AS
1069 for ac_arg
1070 do
1071 case $ac_arg in
1072 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1073 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1074 | -silent | --silent | --silen | --sile | --sil)
1075 continue ;;
1076 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1077 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1078 esac
1079 case $ac_pass in
1080 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1081 2)
1082 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1083 if test $ac_must_keep_next = true; then
35996d22 1084 ac_must_keep_next=false # Got value, back to normal.
19650fd6 1085 else
35996d22
AS
1086 case $ac_arg in
1087 *=* | --config-cache | -C | -disable-* | --disable-* \
1088 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1089 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1090 | -with-* | --with-* | -without-* | --without-* | --x)
1091 case "$ac_configure_args0 " in
1092 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1093 esac
1094 ;;
1095 -* ) ac_must_keep_next=true ;;
1096 esac
19650fd6
AS
1097 fi
1098 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1099 # Get rid of the leading space.
1100 ac_sep=" "
1101 ;;
1102 esac
1103 done
503d2be0 1104done
19650fd6
AS
1105$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1106$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
503d2be0
AS
1107
1108# When interrupted or exit'd, cleanup temporary files, and complete
1109# config.log. We remove comments because anyway the quotes in there
1110# would cause problems or look ugly.
c0d27fcc
MR
1111# WARNING: Be sure not to use single quotes in there, as some shells,
1112# such as our DU 5.0 friend, will then `close' the trap.
503d2be0
AS
1113trap 'exit_status=$?
1114 # Save into config.log some information that might help in debugging.
c0d27fcc
MR
1115 {
1116 echo
6bae0ccf 1117
c0d27fcc
MR
1118 cat <<\_ASBOX
1119## ---------------- ##
1120## Cache variables. ##
1121## ---------------- ##
1122_ASBOX
1123 echo
1124 # The following way of writing the cache mishandles newlines in values,
503d2be0
AS
1125{
1126 (set) 2>&1 |
1127 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1128 *ac_space=\ *)
1129 sed -n \
35996d22
AS
1130 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1131 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
503d2be0
AS
1132 ;;
1133 *)
1134 sed -n \
35996d22 1135 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
1136 ;;
1137 esac;
c0d27fcc
MR
1138}
1139 echo
6bae0ccf
DL
1140
1141 cat <<\_ASBOX
1142## ----------------- ##
1143## Output variables. ##
1144## ----------------- ##
1145_ASBOX
1146 echo
1147 for ac_var in $ac_subst_vars
1148 do
1149 eval ac_val=$`echo $ac_var`
1150 echo "$ac_var='"'"'$ac_val'"'"'"
1151 done | sort
1152 echo
1153
1154 if test -n "$ac_subst_files"; then
1155 cat <<\_ASBOX
1156## ------------- ##
1157## Output files. ##
1158## ------------- ##
1159_ASBOX
1160 echo
1161 for ac_var in $ac_subst_files
1162 do
1163 eval ac_val=$`echo $ac_var`
35996d22 1164 echo "$ac_var='"'"'$ac_val'"'"'"
6bae0ccf
DL
1165 done | sort
1166 echo
1167 fi
1168
c0d27fcc
MR
1169 if test -s confdefs.h; then
1170 cat <<\_ASBOX
1171## ----------- ##
1172## confdefs.h. ##
1173## ----------- ##
1174_ASBOX
1175 echo
6bae0ccf 1176 sed "/^$/d" confdefs.h | sort
c0d27fcc
MR
1177 echo
1178 fi
1179 test "$ac_signal" != 0 &&
1180 echo "$as_me: caught signal $ac_signal"
1181 echo "$as_me: exit $exit_status"
1182 } >&5
35996d22 1183 rm -f core *.core &&
c0d27fcc 1184 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
503d2be0
AS
1185 exit $exit_status
1186 ' 0
1187for ac_signal in 1 2 13 15; do
1188 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1189done
1190ac_signal=0
1191
1192# confdefs.h avoids OS command line length limits that DEFS can exceed.
1193rm -rf conftest* confdefs.h
1194# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1195echo >confdefs.h
ba4481b5 1196
c0d27fcc
MR
1197# Predefined preprocessor variables.
1198
1199cat >>confdefs.h <<_ACEOF
1200#define PACKAGE_NAME "$PACKAGE_NAME"
1201_ACEOF
1202
1203
1204cat >>confdefs.h <<_ACEOF
1205#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1206_ACEOF
1207
1208
1209cat >>confdefs.h <<_ACEOF
1210#define PACKAGE_VERSION "$PACKAGE_VERSION"
1211_ACEOF
1212
1213
1214cat >>confdefs.h <<_ACEOF
1215#define PACKAGE_STRING "$PACKAGE_STRING"
1216_ACEOF
1217
1218
1219cat >>confdefs.h <<_ACEOF
1220#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1221_ACEOF
1222
1223
503d2be0 1224# Let the site file select an alternate cache file if it wants to.
ba4481b5
DL
1225# Prefer explicitly selected file to automatically selected ones.
1226if test -z "$CONFIG_SITE"; then
1227 if test "x$prefix" != xNONE; then
1228 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1229 else
1230 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1231 fi
1232fi
1233for ac_site_file in $CONFIG_SITE; do
1234 if test -r "$ac_site_file"; then
c0d27fcc 1235 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
503d2be0 1236echo "$as_me: loading site script $ac_site_file" >&6;}
c0d27fcc 1237 sed 's/^/| /' "$ac_site_file" >&5
ba4481b5
DL
1238 . "$ac_site_file"
1239 fi
1240done
1241
1242if test -r "$cache_file"; then
503d2be0
AS
1243 # Some versions of bash will fail to source /dev/null (special
1244 # files actually), so we avoid doing that.
1245 if test -f "$cache_file"; then
c0d27fcc 1246 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
503d2be0
AS
1247echo "$as_me: loading cache $cache_file" >&6;}
1248 case $cache_file in
1249 [\\/]* | ?:[\\/]* ) . $cache_file;;
1250 *) . ./$cache_file;;
1251 esac
1252 fi
ba4481b5 1253else
c0d27fcc 1254 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
503d2be0
AS
1255echo "$as_me: creating cache $cache_file" >&6;}
1256 >$cache_file
1257fi
1258
1259# Check that the precious variables saved in the cache have kept the same
1260# value.
1261ac_cache_corrupted=false
1262for ac_var in `(set) 2>&1 |
35996d22 1263 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
503d2be0
AS
1264 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1265 eval ac_new_set=\$ac_env_${ac_var}_set
1266 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1267 eval ac_new_val="\$ac_env_${ac_var}_value"
1268 case $ac_old_set,$ac_new_set in
1269 set,)
c0d27fcc 1270 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
503d2be0
AS
1271echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1272 ac_cache_corrupted=: ;;
1273 ,set)
c0d27fcc 1274 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
503d2be0
AS
1275echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1276 ac_cache_corrupted=: ;;
1277 ,);;
1278 *)
1279 if test "x$ac_old_val" != "x$ac_new_val"; then
35996d22 1280 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
503d2be0 1281echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
35996d22 1282 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
503d2be0 1283echo "$as_me: former value: $ac_old_val" >&2;}
35996d22 1284 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
503d2be0 1285echo "$as_me: current value: $ac_new_val" >&2;}
35996d22 1286 ac_cache_corrupted=:
503d2be0
AS
1287 fi;;
1288 esac
c0d27fcc 1289 # Pass precious variables to config.status.
503d2be0
AS
1290 if test "$ac_new_set" = set; then
1291 case $ac_new_val in
1292 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
c0d27fcc
MR
1293 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1294 *) ac_arg=$ac_var=$ac_new_val ;;
1295 esac
1296 case " $ac_configure_args " in
1297 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1298 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
503d2be0
AS
1299 esac
1300 fi
1301done
1302if $ac_cache_corrupted; then
c0d27fcc 1303 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
503d2be0 1304echo "$as_me: error: changes in the environment can compromise the build" >&2;}
c0d27fcc 1305 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
503d2be0
AS
1306echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1307 { (exit 1); exit 1; }; }
ba4481b5
DL
1308fi
1309
1310ac_ext=c
ba4481b5 1311ac_cpp='$CPP $CPPFLAGS'
503d2be0
AS
1312ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1313ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1314ac_compiler_gnu=$ac_cv_c_compiler_gnu
1315
c0d27fcc
MR
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
ba4481b5 1332
6bae0ccf
DL
1333
1334 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
ba4481b5 1335
c0d27fcc 1336
ba5da88a
PJ
1337test "$program_prefix" != NONE &&
1338 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1339# Use a double $ so make ignores it.
1340test "$program_suffix" != NONE &&
1341 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1342# Double any \ or $. echo might interpret backslashes.
1343# By default was `s,x,x', remove it if useless.
1344cat <<\_ACEOF >conftest.sed
1345s/[\\$]/&&/g;s/;s,x,x,$//
1346_ACEOF
1347program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1348rm conftest.sed
1349
c0d27fcc 1350
ba4481b5
DL
1351lispdir='${datadir}/emacs/${version}/lisp'
1352locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1353'${datadir}/emacs/site-lisp:${datadir}/emacs/${version}/leim'
1354lisppath='${locallisppath}:${lispdir}'
1355etcdir='${datadir}/emacs/${version}/etc'
1356archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1357docdir='${datadir}/emacs/${version}/etc'
24b01ec4 1358gamedir='${localstatedir}/games/emacs'
98418dba
CW
1359
1360gameuser=games
1361
c0d27fcc 1362
ba4481b5
DL
1363# Check whether --with-gcc or --without-gcc was given.
1364if test "${with_gcc+set}" = set; then
1365 withval="$with_gcc"
503d2be0
AS
1366
1367fi;
ba4481b5
DL
1368
1369# Check whether --with-pop or --without-pop was given.
1370if test "${with_pop+set}" = set; then
1371 withval="$with_pop"
243cf185 1372 if test "$withval" = yes; then
c0d27fcc 1373 cat >>confdefs.h <<\_ACEOF
ba4481b5 1374#define MAIL_USE_POP 1
c0d27fcc 1375_ACEOF
ba4481b5 1376
243cf185
DL
1377else :
1378fi
3d9fec71 1379else
c0d27fcc 1380 cat >>confdefs.h <<\_ACEOF
3d9fec71 1381#define MAIL_USE_POP 1
c0d27fcc 1382_ACEOF
3d9fec71 1383
503d2be0 1384fi;
ba4481b5 1385
c0d27fcc 1386
a21616bd
KR
1387# Check whether --with-kerberos or --without-kerberos was given.
1388if test "${with_kerberos+set}" = set; then
1389 withval="$with_kerberos"
c0d27fcc 1390 cat >>confdefs.h <<\_ACEOF
a21616bd 1391#define KERBEROS 1
c0d27fcc 1392_ACEOF
a21616bd 1393
503d2be0 1394fi;
a21616bd 1395
c0d27fcc 1396
a21616bd
KR
1397# Check whether --with-kerberos5 or --without-kerberos5 was given.
1398if test "${with_kerberos5+set}" = set; then
1399 withval="$with_kerberos5"
1400 if test "${with_kerberos5+set}" = set; then
1401 if test "${with_kerberos+set}" != set; then
1402 with_kerberos=yes
c0d27fcc 1403 cat >>confdefs.h <<\_ACEOF
a21616bd 1404#define KERBEROS 1
c0d27fcc 1405_ACEOF
a21616bd
KR
1406
1407 fi
1408fi
b936fae4 1409
c0d27fcc 1410cat >>confdefs.h <<\_ACEOF
a21616bd 1411#define KERBEROS5 1
c0d27fcc 1412_ACEOF
a21616bd 1413
503d2be0 1414fi;
a21616bd 1415
ba4481b5
DL
1416# Check whether --with-hesiod or --without-hesiod was given.
1417if test "${with_hesiod+set}" = set; then
1418 withval="$with_hesiod"
b936fae4 1419
c0d27fcc 1420cat >>confdefs.h <<\_ACEOF
ba4481b5 1421#define HESIOD 1
c0d27fcc 1422_ACEOF
ba4481b5 1423
503d2be0 1424fi;
ba4481b5 1425
c0d27fcc 1426
2c9dccc9
PJ
1427# Check whether --with-sound or --without-sound was given.
1428if test "${with_sound+set}" = set; then
1429 withval="$with_sound"
1430
1431fi;
1432
c0d27fcc 1433
ba4481b5
DL
1434# Check whether --with-x-toolkit or --without-x-toolkit was given.
1435if test "${with_x_toolkit+set}" = set; then
1436 withval="$with_x_toolkit"
1437 case "${withval}" in
1438 y | ye | yes ) val=athena ;;
1439 n | no ) val=no ;;
1440 l | lu | luc | luci | lucid ) val=lucid ;;
1441 a | at | ath | athe | athen | athena ) val=athena ;;
1442 m | mo | mot | moti | motif ) val=motif ;;
488dd4c4 1443 g | gt | gtk ) val=gtk ;;
ba4481b5 1444 * )
c0d27fcc 1445{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1446this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1447Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1448echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1449this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1450Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1451 { (exit 1); exit 1; }; }
ba4481b5
DL
1452 ;;
1453 esac
1454 with_x_toolkit=$val
1455
503d2be0 1456fi;
ba4481b5
DL
1457
1458# Check whether --with-xpm or --without-xpm was given.
1459if test "${with_xpm+set}" = set; then
1460 withval="$with_xpm"
503d2be0
AS
1461
1462fi;
ba4481b5
DL
1463
1464# Check whether --with-jpeg or --without-jpeg was given.
1465if test "${with_jpeg+set}" = set; then
1466 withval="$with_jpeg"
503d2be0
AS
1467
1468fi;
ba4481b5
DL
1469
1470# Check whether --with-tiff or --without-tiff was given.
1471if test "${with_tiff+set}" = set; then
1472 withval="$with_tiff"
503d2be0
AS
1473
1474fi;
ba4481b5
DL
1475
1476# Check whether --with-gif or --without-gif was given.
1477if test "${with_gif+set}" = set; then
1478 withval="$with_gif"
503d2be0
AS
1479
1480fi;
ba4481b5
DL
1481
1482# Check whether --with-png or --without-png was given.
1483if test "${with_png+set}" = set; then
1484 withval="$with_png"
503d2be0
AS
1485
1486fi;
ba4481b5 1487
488dd4c4
JD
1488# Check whether --with-gtk or --without-gtk was given.
1489if test "${with_gtk+set}" = set; then
1490 withval="$with_gtk"
1491
1492fi;
1493
1494# Check whether --with-pkg-config-prog or --without-pkg-config-prog was given.
1495if test "${with_pkg_config_prog+set}" = set; then
1496 withval="$with_pkg_config_prog"
1497
1498fi;
1499
ba4481b5
DL
1500# Check whether --with-toolkit-scroll-bars or --without-toolkit-scroll-bars was given.
1501if test "${with_toolkit_scroll_bars+set}" = set; then
1502 withval="$with_toolkit_scroll_bars"
503d2be0
AS
1503
1504fi;
ba4481b5 1505
1d36487c
GM
1506# Check whether --with-xim or --without-xim was given.
1507if test "${with_xim+set}" = set; then
1508 withval="$with_xim"
1d36487c 1509
503d2be0 1510fi;
ba4481b5 1511
e0f712ba
AC
1512# Check whether --with-carbon or --without-carbon was given.
1513if test "${with_carbon+set}" = set; then
1514 withval="$with_carbon"
1515
1516fi;
6a3a24fa
JD
1517# Check whether --enable-carbon-app or --disable-carbon-app was given.
1518if test "${enable_carbon_app+set}" = set; then
1519 enableval="$enable_carbon_app"
1520 carbon_appdir_x=${enableval}
1521fi;
e0f712ba 1522
19650fd6
AS
1523# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1524if test "${enable_maintainer_mode+set}" = set; then
1525 enableval="$enable_maintainer_mode"
1526 USE_MAINTAINER_MODE=$enableval
1527else
1528 USE_MAINTAINER_MODE=no
1529fi;
1530if test $USE_MAINTAINER_MODE = yes; then
1531 MAINT=
1532else
1533 MAINT=#
1534fi
1535
1536
ba4481b5 1537#### Make srcdir absolute, if it isn't already. It's important to
17494071 1538#### avoid running the path through pwd unnecessarily, since pwd can
ba4481b5
DL
1539#### give you automounter prefixes, which can go away. We do all this
1540#### so Emacs can find its files when run uninstalled.
17494071
GM
1541## Make sure CDPATH doesn't affect cd (in case PWD is relative).
1542unset CDPATH
ba4481b5
DL
1543case "${srcdir}" in
1544 /* ) ;;
1545 . )
1546 ## We may be able to use the $PWD environment variable to make this
1547 ## absolute. But sometimes PWD is inaccurate.
df645f7c
AS
1548 ## Note: we used to use ${PWD} at the end instead of `pwd`,
1549 ## but that tested only for a well-formed and valid PWD,
1550 ## it did not object when PWD was well-formed and valid but just wrong.
1551 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
ba4481b5
DL
1552 then
1553 srcdir="$PWD"
1554 else
1555 srcdir="`(cd ${srcdir}; pwd)`"
1556 fi
1557 ;;
1558 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
1559esac
1560
1561#### Check if the source directory already has a configured system in it.
1562if test `pwd` != `(cd ${srcdir} && pwd)` \
1563 && test -f "${srcdir}/src/config.h" ; then
c0d27fcc 1564 { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
503d2be0
AS
1565 as a build directory right now; it has been configured in its own
1566 right. To configure in another directory as well, you MUST
1567 use GNU make. If you do not have GNU make, then you must
1568 now do \`make distclean' in ${srcdir},
1569 and then run $0 again." >&5
1570echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
ba4481b5
DL
1571 as a build directory right now; it has been configured in its own
1572 right. To configure in another directory as well, you MUST
1573 use GNU make. If you do not have GNU make, then you must
1574 now do \`make distclean' in ${srcdir},
503d2be0 1575 and then run $0 again." >&2;}
ba4481b5
DL
1576fi
1577
1578#### Given the configuration name, set machfile and opsysfile to the
1579#### names of the m/*.h and s/*.h files we should use.
1580
1581### Canonicalize the configuration name.
1582
1583ac_aux_dir=
1584for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1585 if test -f $ac_dir/install-sh; then
1586 ac_aux_dir=$ac_dir
1587 ac_install_sh="$ac_aux_dir/install-sh -c"
1588 break
1589 elif test -f $ac_dir/install.sh; then
1590 ac_aux_dir=$ac_dir
1591 ac_install_sh="$ac_aux_dir/install.sh -c"
1592 break
503d2be0
AS
1593 elif test -f $ac_dir/shtool; then
1594 ac_aux_dir=$ac_dir
1595 ac_install_sh="$ac_aux_dir/shtool install -c"
1596 break
ba4481b5
DL
1597 fi
1598done
1599if test -z "$ac_aux_dir"; then
c0d27fcc 1600 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1601echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1602 { (exit 1); exit 1; }; }
ba4481b5 1603fi
503d2be0
AS
1604ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1605ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1606ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1607
1608# Make sure we can run config.sub.
503d2be0 1609$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1610 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1611echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1612 { (exit 1); exit 1; }; }
1613
c0d27fcc 1614echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1615echo $ECHO_N "checking build system type... $ECHO_C" >&6
1616if test "${ac_cv_build+set}" = set; then
1617 echo $ECHO_N "(cached) $ECHO_C" >&6
1618else
1619 ac_cv_build_alias=$build_alias
1620test -z "$ac_cv_build_alias" &&
1621 ac_cv_build_alias=`$ac_config_guess`
1622test -z "$ac_cv_build_alias" &&
c0d27fcc 1623 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1624echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1625 { (exit 1); exit 1; }; }
1626ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1627 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1628echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1629 { (exit 1); exit 1; }; }
1630
1631fi
c0d27fcc 1632echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1633echo "${ECHO_T}$ac_cv_build" >&6
1634build=$ac_cv_build
1635build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1636build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1637build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1638
c0d27fcc
MR
1639
1640echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1641echo $ECHO_N "checking host system type... $ECHO_C" >&6
1642if test "${ac_cv_host+set}" = set; then
1643 echo $ECHO_N "(cached) $ECHO_C" >&6
1644else
1645 ac_cv_host_alias=$host_alias
1646test -z "$ac_cv_host_alias" &&
1647 ac_cv_host_alias=$ac_cv_build_alias
1648ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1649 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1650echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1651 { (exit 1); exit 1; }; }
1652
1653fi
c0d27fcc 1654echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1655echo "${ECHO_T}$ac_cv_host" >&6
1656host=$ac_cv_host
1657host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1658host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1659host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1660
c0d27fcc 1661
ba4481b5 1662canonical=$host
531a3336 1663configuration=${host_alias-$host}
ba4481b5 1664
c0d27fcc 1665
22044edf 1666
ba4481b5
DL
1667### If you add support for a new configuration, add code to this
1668### switch statement to recognize your configuration name and select
1669### the appropriate operating system and machine description files.
1670
1671### You would hope that you could choose an m/*.h file pretty much
1672### based on the machine portion of the configuration name, and an s-
1673### file based on the operating system portion. However, it turns out
1674### that each m/*.h file is pretty manufacturer-specific - for
1675### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1676### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1677### machines. So we basically have to have a special case for each
1678### configuration name.
1679###
1680### As far as handling version numbers on operating systems is
1681### concerned, make sure things will fail in a fixable way. If
1682### /etc/MACHINES doesn't say anything about version numbers, be
1683### prepared to handle anything reasonably. If version numbers
1684### matter, be sure /etc/MACHINES says something about it.
1685###
1686### Eric Raymond says we should accept strings like "sysvr4" to mean
1687### "System V Release 4"; he writes, "The old convention encouraged
1688### confusion between `system' and `release' levels'."
1689
1690machine='' opsys='' unported=no
1691case "${canonical}" in
1692
1096bcc0
GM
1693 ## FreeBSD ports
1694 *-*-freebsd* )
1695 opsys=freebsd
1696 case "${canonical}" in
1697 alpha*-*-freebsd*) machine=alpha ;;
1698 i[3456]86-*-freebsd*) machine=intel386 ;;
1699 esac
1700 ;;
1701
ba4481b5
DL
1702 ## NetBSD ports
1703 *-*-netbsd* )
1704 opsys=netbsd
dd038e26 1705 if test -f /usr/lib/crti.o; then
f57bd967
DL
1706
1707cat >>confdefs.h <<\_ACEOF
1708#define HAVE_CRTIN
dd038e26
AS
1709_ACEOF
1710
1711 fi
1712
ba4481b5
DL
1713 case "${canonical}" in
1714 alpha*-*-netbsd*) machine=alpha ;;
1715 i[3456]86-*-netbsd*) machine=intel386 ;;
1716 m68k-*-netbsd*)
1717 # This is somewhat bogus.
1718 machine=hp9000s300 ;;
1719 powerpc-apple-netbsd*) machine=macppc ;;
1720 mips-*-netbsd*) machine=pmax ;;
2df636f4 1721 mipsel-*-netbsd*) machine=pmax ;;
97836269 1722 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1723 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1724 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1725 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1726 vax-*-netbsd*) machine=vax ;;
2df636f4 1727 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1728 esac
1729 ;;
1730
1731 ## OpenBSD ports
1732 *-*-openbsd* )
1733 opsys=openbsd
1734 case "${canonical}" in
1735 alpha*-*-openbsd*) machine=alpha ;;
1736 i386-*-openbsd*) machine=intel386 ;;
1737 m68k-*-openbsd*) machine=hp9000s300 ;;
1738 mipsel-*-openbsd*) machine=pmax ;;
1739 ns32k-*-openbsd*) machine=ns32000 ;;
1740 sparc-*-openbsd*) machine=sparc ;;
1741 vax-*-openbsd*) machine=vax ;;
1742 esac
1743 ;;
1744
1745 ## Acorn RISCiX:
1746 arm-acorn-riscix1.1* )
1747 machine=acorn opsys=riscix1-1
1748 ;;
1749 arm-acorn-riscix1.2* | arm-acorn-riscix )
1750 ## This name is riscix12 instead of riscix1.2
1751 ## to avoid a file name conflict on MSDOS.
1752 machine=acorn opsys=riscix12
1753 ;;
1754
1755 ## BSDI ports
1756 *-*-bsdi* )
1757 opsys=bsdi
1758 case "${canonical}" in
1759 i[345]86-*-bsdi*) machine=intel386 ;;
1760 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1761 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1762 esac
1763 case "${canonical}" in
1764 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1765 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1766 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1767 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1768 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1769 esac
1770 ;;
1771
1772 ## Alliant machines
1773 ## Strictly speaking, we need the version of the alliant operating
1774 ## system to choose the right machine file, but currently the
1775 ## configuration name doesn't tell us enough to choose the right
1776 ## one; we need to give alliants their own operating system name to
1777 ## do this right. When someone cares, they can help us.
1778 fx80-alliant-* )
1779 machine=alliant4 opsys=bsd4-2
1780 ;;
1781 i860-alliant-* )
1782 machine=alliant-2800 opsys=bsd4-3
1783 ;;
1784
1785 ## Alpha (DEC) machines.
1786 alpha*-dec-osf* )
1787 machine=alpha opsys=osf1
1788 # This is needed to find X11R6.1 libraries for certain tests.
1789 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1790 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1791 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1792 # due to non-traditional preprocessing with the current compiler
1793 # defaults. OSF 4 can also have that compiler version, and there
1794 # seems always to have been a usable /usr/bin/cpp.
1795 NON_GNU_CPP=/usr/bin/cpp
ca512671 1796 case "${canonical}" in
a55b799a 1797 alpha*-dec-osf[5-9]*)
bb17930d 1798 opsys=osf5-0 ;;
ca512671 1799 esac
ba4481b5
DL
1800 ;;
1801
1802 alpha*-*-linux-gnu* )
1803 machine=alpha opsys=gnu-linux
1804 ;;
1805
c4bb2108
DL
1806 arm*-*-linux-gnu* )
1807 machine=arm opsys=gnu-linux
1808 ;;
1809
1810 ppc-*-linux | \
1811 powerpc-*-linux* )
3aeecf97 1812 machine=macppc opsys=gnu-linux
c4bb2108
DL
1813 ;;
1814
ba4481b5
DL
1815 ## Altos 3068
1816 m68*-altos-sysv* )
1817 machine=altos opsys=usg5-2
1818 ;;
1819
1820 ## Amdahl UTS
1821 580-amdahl-sysv* )
1822 machine=amdahl opsys=usg5-2-2
1823 ;;
1824
1825 ## Apollo, Domain/OS
1826 m68*-apollo-* )
1827 machine=apollo opsys=bsd4-3
1828 ;;
1829
1830 ## AT&T 3b2, 3b5, 3b15, 3b20
1831 we32k-att-sysv* )
1832 machine=att3b opsys=usg5-2-2
1833 ;;
1834
1835 ## AT&T 3b1 - The Mighty Unix PC!
1836 m68*-att-sysv* )
1837 machine=7300 opsys=usg5-2-2
1838 ;;
1839
1840 ## Bull dpx20
1841 rs6000-bull-bosx* )
1842 machine=ibmrs6000 opsys=aix3-2
1843 ;;
1844
1845 ## Bull dpx2
1846 m68*-bull-sysv3* )
1847 machine=dpx2 opsys=usg5-3
1848 ;;
1849
1850 ## Bull sps7
1851 m68*-bull-sysv2* )
1852 machine=sps7 opsys=usg5-2
1853 ;;
1854
1855 ## CCI 5/32, 6/32 -- see "Tahoe".
1856
1857 ## Celerity
1858 ## I don't know what configuration name to use for this; config.sub
1859 ## doesn't seem to know anything about it. Hey, Celerity users, get
1860 ## in touch with us!
1861 celerity-celerity-bsd* )
1862 machine=celerity opsys=bsd4-2
1863 ;;
1864
1865 ## Clipper
1866 ## What operating systems does this chip run that Emacs has been
1867 ## tested on?
1868 clipper-* )
1869 machine=clipper
1870 ## We'll use the catch-all code at the bottom to guess the
1871 ## operating system.
1872 ;;
1873
df645f7c
AS
1874 ## Compaq Nonstop
1875 mips-compaq-nonstopux* )
1876 machine=nonstopux opsys=nonstopux
1877 ;;
1878
ba4481b5
DL
1879 ## Convex
1880 *-convex-bsd* | *-convex-convexos* )
1881 machine=convex opsys=bsd4-3
1882 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1883 NON_GNU_CPP="cc -E -P"
1884 ;;
1885
1886 ## Cubix QBx/386
1887 i[3456]86-cubix-sysv* )
1888 machine=intel386 opsys=usg5-3
1889 ;;
1890
1891 ## Cydra 5
1892 cydra*-cydrome-sysv* )
1893 machine=cydra5 opsys=usg5-3
1894 ;;
1895
1896 ## Data General AViiON Machines
1897 ## DG changed naming conventions with the release of 5.4.4.10, they
1898 ## dropped the initial 5.4 but left the intervening R. Because of the
1899 ## R this shouldn't conflict with older versions of the OS (which I
1900 ## think were named like dgux4.*). In addition, DG new AViiONs series
1901 ## uses either Motorola M88k or Intel Pentium CPUs.
1902 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1903 machine=aviion opsys=dgux4
1904 ;;
1905 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1906 ## This name is dgux5-4-3 instead of dgux5-4r3
1907 ## to avoid a file name conflict on MSDOS.
1908 machine=aviion opsys=dgux5-4-3
1909 ;;
1910 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1911 machine=aviion opsys=dgux5-4r2
1912 ;;
1913 m88k-dg-dgux* )
1914 machine=aviion opsys=dgux
1915 ;;
1916
1917 ## Data General AViiON Intel (x86) Machines
1918 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1919 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1920 i[345]86-dg-dguxR4* )
1921 machine=aviion-intel opsys=dgux4
1922 ;;
1923
1924 ## DECstations
1925 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1926 machine=pmax opsys=bsd4-2
1927 ;;
1928 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1929 machine=pmax opsys=bsd4-3
1930 ;;
1931 mips-dec-ultrix* )
1932 machine=pmax opsys=ultrix4-3
1933 ;;
1934 mips-dec-osf* )
1935 machine=pmax opsys=osf1
1936 ;;
1937 mips-dec-mach_bsd4.3* )
1938 machine=pmax opsys=mach-bsd4-3
1939 ;;
1940
cd890796
JD
1941 ## Motorola Delta machines
1942 m68k-motorola-sysv* | m68000-motorola-sysv* )
1943 machine=delta opsys=usg5-3
1944 if test -z "`type gnucc | grep 'not found'`"
1945 then
1946 if test -s /etc/167config
1947 then CC="gnucc -m68040"
1948 else CC="gnucc -m68881"
1949 fi
1950 else
1951 if test -z "`type gcc | grep 'not found'`"
1952 then CC=gcc
1953 else CC=cc
1954 fi
1955 fi
1956 ;;
ba4481b5
DL
1957 m88k-motorola-sysv4* )
1958 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1959 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1960 # I hope there are not other 4.0 versions for this machine
1961 # which really need usg5-4 instead.
1962 machine=delta88k opsys=usg5-4-2
1963 ;;
1964 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1965 machine=delta88k opsys=usg5-3
1966 ;;
1967
1968 ## Dual machines
1969 m68*-dual-sysv* )
1970 machine=dual opsys=usg5-2
1971 ;;
1972 m68*-dual-uniplus* )
1973 machine=dual opsys=unipl5-2
1974 ;;
1975
1976 ## Elxsi 6400
1977 elxsi-elxsi-sysv* )
1978 machine=elxsi opsys=usg5-2
1979 ;;
1980
1981 ## Encore machines
1982 ns16k-encore-bsd* )
1983 machine=ns16000 opsys=umax
1984 ;;
1985
65171e3a
DL
1986 ## The GEC 63 - apparently, this port isn't really finished yet.
1987 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
1988
1989 ## Gould Power Node and NP1
1990 pn-gould-bsd4.2* )
1991 machine=gould opsys=bsd4-2
1992 ;;
1993 pn-gould-bsd4.3* )
1994 machine=gould opsys=bsd4-3
1995 ;;
1996 np1-gould-bsd* )
1997 machine=gould-np1 opsys=bsd4-3
1998 ;;
1999
2000 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
2001 ## as far as Emacs is concerned).
2002 m88k-harris-cxux* )
2003 # Build needs to be different on 7.0 and later releases
2004 case "`uname -r`" in
2005 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
2006 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
2007 esac
2008 NON_GNU_CPP="/lib/cpp"
2009 ;;
2010 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
2011 m68k-harris-cxux* )
2012 machine=nh3000 opsys=cxux
2013 ;;
2014 ## Harris power pc NightHawk running Power UNIX (Series 6000)
2015 powerpc-harris-powerunix )
2016 machine=nh6000 opsys=powerunix
2017 NON_GNU_CPP="cc -Xo -E -P"
2018 ;;
2019 ## SR2001/SR2201 running HI-UX/MPP
2020 hppa1.1-hitachi-hiuxmpp* )
2021 machine=sr2k opsys=hiuxmpp
2022 ;;
89a336fa
GM
2023 hppa1.1-hitachi-hiuxwe2* )
2024 machine=sr2k opsys=hiuxwe2
2025 ;;
ba4481b5
DL
2026 ## Honeywell XPS100
2027 xps*-honeywell-sysv* )
2028 machine=xps100 opsys=usg5-2
2029 ;;
2030
2031 ## HP 9000 series 200 or 300
2032 m68*-hp-bsd* )
2033 machine=hp9000s300 opsys=bsd4-3
2034 ;;
2035 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2036 m68*-hp-hpux* )
2037 case "`uname -r`" in
2038 ## Someone's system reports A.B8.05 for this.
2039 ## I wonder what other possibilities there are.
2040 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2041 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2042 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2043 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2044 *) machine=hp9000s300 opsys=hpux ;;
2045 esac
2046 ;;
2047
2048 ## HP 9000 series 700 and 800, running HP/UX
2049 hppa*-hp-hpux7* )
2050 machine=hp800 opsys=hpux
2051 ;;
2052 hppa*-hp-hpux8* )
2053 machine=hp800 opsys=hpux8
2054 ;;
2055 hppa*-hp-hpux9shr* )
2056 machine=hp800 opsys=hpux9shr
2057 ;;
2058 hppa*-hp-hpux9* )
2059 machine=hp800 opsys=hpux9
2060 ;;
b0e44248
RB
2061 hppa*-hp-hpux10.2* )
2062 machine=hp800 opsys=hpux10-20
2063 ;;
cc227489 2064 hppa*-hp-hpux10* )
ba4481b5
DL
2065 machine=hp800 opsys=hpux10
2066 ;;
cc227489
MB
2067 hppa*-hp-hpux1[1-9]* )
2068 machine=hp800 opsys=hpux11
2069 ;;
ba4481b5 2070
409d9577
GM
2071 hppa*-*-linux-gnu* )
2072 machine=hp800 opsys=gnu-linux
2073 ;;
2074
ba4481b5
DL
2075 ## HP 9000 series 700 and 800, running HP/UX
2076 hppa*-hp-hpux* )
2077 ## Cross-compilation? Nah!
2078 case "`uname -r`" in
2079 ## Someone's system reports A.B8.05 for this.
2080 ## I wonder what other possibilities there are.
2081 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2082 *.08.* ) machine=hp800 opsys=hpux8 ;;
2083 *.09.* ) machine=hp800 opsys=hpux9 ;;
2084 *) machine=hp800 opsys=hpux10 ;;
2085 esac
2086 ;;
2087 hppa*-*-nextstep* )
2088 machine=hp800 opsys=nextstep
2089 ;;
2090
2091 ## Orion machines
2092 orion-orion-bsd* )
2093 machine=orion opsys=bsd4-2
2094 ;;
2095 clipper-orion-bsd* )
2096 machine=orion105 opsys=bsd4-2
2097 ;;
2098
2099 ## IBM machines
2100 i[3456]86-ibm-aix1.1* )
2101 machine=ibmps2-aix opsys=usg5-2-2
2102 ;;
2103 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2104 machine=ibmps2-aix opsys=usg5-3
2105 ;;
2106 i370-ibm-aix*)
2107 machine=ibm370aix opsys=usg5-3
2108 ;;
55597d70 2109 s390-*-linux-gnu* )
138f0859
GM
2110 machine=ibms390 opsys=gnu-linux
2111 ;;
ba4481b5
DL
2112 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2113 machine=ibmrs6000 opsys=aix3-1
2114 ;;
2115 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2116 machine=ibmrs6000 opsys=aix3-2-5
2117 ;;
2118 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2119 machine=ibmrs6000 opsys=aix4-1
2120 ;;
2121 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2122 machine=ibmrs6000 opsys=aix4-2
2123 ;;
55597d70 2124 rs6000-ibm-aix5* | powerpc-ibm-aix5* )
d6b82250
EZ
2125 machine=ibmrs6000 opsys=aix4-2
2126 ;;
ba4481b5
DL
2127 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2128 machine=ibmrs6000 opsys=aix4
2129 ;;
2130 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2131 machine=ibmrs6000 opsys=aix4-1
2132 ;;
2133 rs6000-ibm-aix* | powerpc-ibm-aix* )
2134 machine=ibmrs6000 opsys=aix3-2
2135 ;;
2136 romp-ibm-bsd4.3* )
2137 machine=ibmrt opsys=bsd4-3
2138 ;;
2139 romp-ibm-bsd4.2* )
2140 machine=ibmrt opsys=bsd4-2
2141 ;;
2142 romp-ibm-aos4.3* )
2143 machine=ibmrt opsys=bsd4-3
2144 ;;
2145 romp-ibm-aos4.2* )
2146 machine=ibmrt opsys=bsd4-2
2147 ;;
2148 romp-ibm-aos* )
2149 machine=ibmrt opsys=bsd4-3
2150 ;;
2151 romp-ibm-bsd* )
2152 machine=ibmrt opsys=bsd4-3
2153 ;;
2154 romp-ibm-aix* )
2155 machine=ibmrt-aix opsys=usg5-2-2
2156 ;;
2157
2158 ## Integrated Solutions `Optimum V'
2159 m68*-isi-bsd4.2* )
2160 machine=isi-ov opsys=bsd4-2
2161 ;;
2162 m68*-isi-bsd4.3* )
2163 machine=isi-ov opsys=bsd4-3
2164 ;;
2165
2166 ## Intel 386 machines where we do care about the manufacturer
2167 i[3456]86-intsys-sysv* )
2168 machine=is386 opsys=usg5-2-2
2169 ;;
2170
2171 ## Prime EXL
2172 i[3456]86-prime-sysv* )
2173 machine=i386 opsys=usg5-3
2174 ;;
2175
2176 ## Sequent Symmetry running Dynix
2177 i[3456]86-sequent-bsd* )
2178 machine=symmetry opsys=bsd4-3
2179 ;;
2180
2181 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2182 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2183 machine=sequent-ptx opsys=ptx4
2184 NON_GNU_CPP=/lib/cpp
2185 ;;
2186
2187 ## Sequent Symmetry running DYNIX/ptx
2188 ## Use the old cpp rather than the newer ANSI one.
2189 i[3456]86-sequent-ptx* )
2190 machine=sequent-ptx opsys=ptx
2191 NON_GNU_CPP="/lib/cpp"
2192 ;;
2193
2194 ## ncr machine running svr4.3.
2195 i[3456]86-ncr-sysv4.3 )
2196 machine=ncr386 opsys=usg5-4-3
2197 ;;
2198
2199 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2200 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2201 i[3456]86-ncr-sysv* )
2202 machine=ncr386 opsys=usg5-4-2
2203 ;;
2204
2205 ## Intel Paragon OSF/1
2206 i860-intel-osf1* )
2207 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2208 ;;
2209
2210 ## Intel 860
2211 i860-*-sysv4* )
2212 machine=i860 opsys=usg5-4
2213 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2214 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2215 ;;
2216
c76e04a8
GM
2217 ## Macintosh PowerPC
2218 powerpc*-*-linux-gnu* )
2219 machine=macppc opsys=gnu-linux
2220 ;;
2221
ba4481b5
DL
2222 ## Masscomp machines
2223 m68*-masscomp-rtu* )
2224 machine=masscomp opsys=rtu
2225 ;;
2226
2227 ## Megatest machines
2228 m68*-megatest-bsd* )
2229 machine=mega68 opsys=bsd4-2
2230 ;;
2231
2232 ## Workstations sold by MIPS
2233 ## This is not necessarily all workstations using the MIPS processor -
2234 ## Irises are produced by SGI, and DECstations by DEC.
2235
2236 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2237 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2238 ## it gives for choosing between the alternatives seems to be "Use
2239 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2240 ## the BSD world." I'll assume that these are instructions for
2241 ## handling two odd situations, and that every other situation
2242 ## should use mips.h and usg5-2-2, they being listed first.
2243 mips-mips-usg* )
2244 machine=mips4
2245 ## Fall through to the general code at the bottom to decide on the OS.
2246 ;;
2247 mips-mips-riscos4* )
2248 machine=mips4 opsys=bsd4-3
2249 NON_GNU_CC="cc -systype bsd43"
2250 NON_GNU_CPP="cc -systype bsd43 -E"
2251 ;;
2252 mips-mips-riscos5* )
2253 machine=mips4 opsys=riscos5
2254 NON_GNU_CC="cc -systype bsd43"
2255 NON_GNU_CPP="cc -systype bsd43 -E"
2256 ;;
2257 mips-mips-bsd* )
2258 machine=mips opsys=bsd4-3
2259 ;;
2260 mips-mips-* )
2261 machine=mips opsys=usg5-2-2
2262 ;;
2263
2264 ## NeXT
2265 m68*-next-* | m68k-*-nextstep* )
2266 machine=m68k opsys=nextstep
2267 ;;
2268
2269 ## The complete machine from National Semiconductor
2270 ns32k-ns-genix* )
2271 machine=ns32000 opsys=usg5-2
2272 ;;
2273
2274 ## NCR machines
2275 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2276 machine=tower32 opsys=usg5-2-2
2277 ;;
2278 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2279 machine=tower32v3 opsys=usg5-3
2280 ;;
2281
2282 ## NEC EWS4800
2283 mips-nec-sysv4*)
2284 machine=ews4800 opsys=ux4800
2285 ;;
2286
2287 ## Nixdorf Targon 31
2288 m68*-nixdorf-sysv* )
2289 machine=targon31 opsys=usg5-2-2
2290 ;;
2291
2292 ## Nu (TI or LMI)
2293 m68*-nu-sysv* )
2294 machine=nu opsys=usg5-2
2295 ;;
2296
2297 ## Plexus
2298 m68*-plexus-sysv* )
2299 machine=plexus opsys=usg5-2
2300 ;;
2301
ba4481b5
DL
2302 ## Pyramid machines
2303 ## I don't really have any idea what sort of processor the Pyramid has,
2304 ## so I'm assuming it is its own architecture.
2305 pyramid-pyramid-bsd* )
2306 machine=pyramid opsys=bsd4-2
2307 ;;
2308
2309 ## Sequent Balance
2310 ns32k-sequent-bsd4.2* )
2311 machine=sequent opsys=bsd4-2
2312 ;;
2313 ns32k-sequent-bsd4.3* )
2314 machine=sequent opsys=bsd4-3
2315 ;;
2316
2317 ## Siemens Nixdorf
2318 mips-siemens-sysv* | mips-sni-sysv*)
2319 machine=mips-siemens opsys=usg5-4
2320 NON_GNU_CC=/usr/ccs/bin/cc
2321 NON_GNU_CPP=/usr/ccs/lib/cpp
2322 ;;
2323
2324 ## Silicon Graphics machines
2325 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2326 m68*-sgi-iris3.5* )
2327 machine=irist opsys=iris3-5
2328 ;;
2329 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2330 machine=irist opsys=iris3-6
2331 ;;
2332 ## Iris 4D
2333 mips-sgi-irix3* )
2334 machine=iris4d opsys=irix3-3
2335 ;;
2336 mips-sgi-irix4* )
2337 machine=iris4d opsys=irix4-0
2338 ;;
2339 mips-sgi-irix6.5 )
2340 machine=iris4d opsys=irix6-5
946173ad
DL
2341 # Without defining _LANGUAGE_C, things get masked out in the headers
2342 # so that, for instance, grepping for `free' in stdlib.h fails and
2343 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2344 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2345 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2346 ;;
2347 mips-sgi-irix6* )
2348 machine=iris4d opsys=irix6-0
c4bb2108 2349 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2350 # but presumably it does no harm.
2351 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2352 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2353 NON_GCC_TEST_OPTIONS=-32
2354 ;;
2355 mips-sgi-irix5.[01]* )
2356 machine=iris4d opsys=irix5-0
2357 ;;
2358 mips-sgi-irix5* | mips-sgi-irix* )
2359 machine=iris4d opsys=irix5-2
2360 ;;
2361
2362 ## SONY machines
2363 m68*-sony-bsd4.2* )
2364 machine=news opsys=bsd4-2
2365 ;;
2366 m68*-sony-bsd4.3* )
2367 machine=news opsys=bsd4-3
2368 ;;
2369 m68*-sony-newsos3* | m68*-sony-news3*)
2370 machine=news opsys=bsd4-3
2371 ;;
2372 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2373 machine=news-risc opsys=bsd4-3
2374 ;;
2375 mips-sony-newsos6* )
2376 machine=news-r6 opsys=newsos6
2377 ;;
2378 mips-sony-news* )
2379 machine=news-risc opsys=newsos5
2380 ;;
2381
2382 ## Stride
2383 m68*-stride-sysv* )
2384 machine=stride opsys=usg5-2
2385 ;;
2386
2387 ## Suns
2388 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2389 machine=sparc opsys=gnu-linux
2390 ;;
2391
d054101f 2392 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2393 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2394 | rs6000-*-solaris2*)
2395 case "${canonical}" in
2396 m68*-sunos1* ) machine=sun1 ;;
2397 m68*-sunos2* ) machine=sun2 ;;
2398 m68* ) machine=sun3 ;;
2399 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2400 i[3456]86-*-* ) machine=intel386 ;;
2401 powerpcle* ) machine=powerpcle ;;
2402 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2403 sparc* ) machine=sparc ;;
2404 * ) unported=yes ;;
2405 esac
2406 case "${canonical}" in
2407 ## The Sun386 didn't get past 4.0.
2408 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2409 *-sunos4.0* ) opsys=sunos4-0 ;;
2410 *-sunos4.1.[3-9]*noshare )
2411 ## This name is sunos413 instead of sunos4-1-3
2412 ## to avoid a file name conflict on MSDOS.
2413 opsys=sunos413
2414 NON_GNU_CPP=/usr/lib/cpp
2415 NON_GCC_TEST_OPTIONS=-Bstatic
2416 GCC_TEST_OPTIONS=-static
2417 ;;
2418 *-sunos4.1.[3-9]* | *-sunos4shr*)
2419 opsys=sunos4shr
2420 NON_GNU_CPP=/usr/lib/cpp
2421 ;;
2422 *-sunos4* | *-sunos )
2423 opsys=sunos4-1
2424 NON_GCC_TEST_OPTIONS=-Bstatic
2425 GCC_TEST_OPTIONS=-static
2426 ;;
2427 *-sunos5.3* | *-solaris2.3* )
2428 opsys=sol2-3
2429 NON_GNU_CPP=/usr/ccs/lib/cpp
2430 ;;
2431 *-sunos5.4* | *-solaris2.4* )
2432 opsys=sol2-4
2433 NON_GNU_CPP=/usr/ccs/lib/cpp
2434 RANLIB="ar -ts"
2435 ;;
2436 *-sunos5.5* | *-solaris2.5* )
2437 opsys=sol2-5
2438 NON_GNU_CPP=/usr/ccs/lib/cpp
2439 RANLIB="ar -ts"
2440 ;;
8e967cf7
MR
2441 *-sunos5.6* | *-solaris2.6* )
2442 opsys=sol2-6
2443 NON_GNU_CPP=/usr/ccs/lib/cpp
2444 RANLIB="ar -ts"
2445 ;;
ba4481b5 2446 *-sunos5* | *-solaris* )
9e71690e 2447 opsys=sol2-6
ba4481b5
DL
2448 NON_GNU_CPP=/usr/ccs/lib/cpp
2449 ;;
2450 * ) opsys=bsd4-2 ;;
2451 esac
2452 ## Watch out for a compiler that we know will not work.
2453 case "${canonical}" in
2454 *-solaris* | *-sunos5* )
2455 if [ "x$CC" = x/usr/ucb/cc ]; then
2456 ## /usr/ucb/cc doesn't work;
2457 ## we should find some other compiler that does work.
2458 unset CC
2459 fi
2460 ;;
2461 *) ;;
2462 esac
2463 ;;
2464 sparc-*-nextstep* )
2465 machine=sparc opsys=nextstep
2466 ;;
2467
2468 ## Tadpole 68k
2469 m68*-tadpole-sysv* )
2470 machine=tad68k opsys=usg5-3
2471 ;;
2472
2473 ## Tahoe machines
2474 tahoe-tahoe-bsd4.2* )
2475 machine=tahoe opsys=bsd4-2
2476 ;;
2477 tahoe-tahoe-bsd4.3* )
2478 machine=tahoe opsys=bsd4-3
2479 ;;
2480
2481 ## Tandem Integrity S2
2482 mips-tandem-sysv* )
2483 machine=tandem-s2 opsys=usg5-3
2484 ;;
2485
2486 ## Tektronix XD88
2487 m88k-tektronix-sysv3* )
2488 machine=tekxd88 opsys=usg5-3
2489 ;;
2490
2491 ## Tektronix 16000 box (6130?)
2492 ns16k-tektronix-bsd* )
2493 machine=ns16000 opsys=bsd4-2
2494 ;;
2495 ## Tektronix 4300
2496 ## src/m/tek4300.h hints that this is a m68k machine.
2497 m68*-tektronix-bsd* )
2498 machine=tek4300 opsys=bsd4-3
2499 ;;
2500
2501 ## Titan P2 or P3
2502 ## We seem to have lost the machine-description file titan.h!
2503 titan-titan-sysv* )
2504 machine=titan opsys=usg5-3
2505 ;;
2506
2507 ## Ustation E30 (SS5E)
2508 m68*-unisys-uniplus* )
2509 machine=ustation opsystem=unipl5-2
2510 ;;
2511
2512 ## Vaxen.
2513 vax-dec-* )
2514 machine=vax
2515 case "${canonical}" in
2516 *-bsd4.1* ) opsys=bsd4-1 ;;
2517 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2518 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2519 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2520 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2521 *-vms* ) opsys=vms ;;
2522 * ) unported=yes
2523 esac
2524 ;;
2525
2526 ## Whitechapel MG1
2527 ns16k-whitechapel-* )
2528 machine=mg1
2529 ## We don't know what sort of OS runs on these; we'll let the
2530 ## operating system guessing code below try.
2531 ;;
2532
2533 ## Wicat
2534 m68*-wicat-sysv* )
2535 machine=wicat opsys=usg5-2
2536 ;;
2537
f4988be7
GM
2538 ## IA-64
2539 ia64*-*-linux* )
2540 machine=ia64 opsys=gnu-linux
2541 ;;
2542
ba4481b5
DL
2543 ## Intel 386 machines where we don't care about the manufacturer
2544 i[3456]86-*-* )
2545 machine=intel386
2546 case "${canonical}" in
c60ee5e7 2547 *-cygwin ) opsys=cygwin ;;
9f817ea4 2548 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2549 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2550 *-isc2.2* ) opsys=isc2-2 ;;
2551 *-isc4.0* ) opsys=isc4-0 ;;
2552 *-isc4.* ) opsys=isc4-1
2553 GCC_TEST_OPTIONS=-posix
2554 NON_GCC_TEST_OPTIONS=-Xp
2555 ;;
2556 *-isc* ) opsys=isc3-0 ;;
2557 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2558 *-esix* ) opsys=esix ;;
2559 *-xenix* ) opsys=xenix ;;
2560 *-linux-gnu* ) opsys=gnu-linux ;;
2561 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2562 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2563 NON_GNU_CPP=/lib/cpp
2564 # Prevent -belf from being passed to $CPP.
2565 # /lib/cpp does not accept it.
2566 OVERRIDE_CPPFLAGS=" "
2567 ;;
2568 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
55597d70
DL
2569 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2570 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
ba4481b5 2571 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2572 *-nextstep* ) opsys=nextstep ;;
2573 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2574 esac
2575 ;;
2576
2577 ## m68k Linux-based GNU system
2578 m68k-*-linux-gnu* )
2579 machine=m68k opsys=gnu-linux
2580 ;;
2581
2582 ## Mips Linux-based GNU system
cd958eb3 2583 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2584 machine=mips opsys=gnu-linux
2585 ;;
2586
2587 ## UXP/DS
2588 sparc-fujitsu-sysv4* )
2589 machine=sparc opsys=uxpds
2590 NON_GNU_CPP=/usr/ccs/lib/cpp
2591 RANLIB="ar -ts"
2592 ;;
2593
2594 ## UXP/V
2595 f301-fujitsu-uxpv4.1)
2596 machine=f301 opsys=uxpv
2597 ;;
2598
e0f712ba
AC
2599 ## Darwin / Mac OS X
2600 powerpc-apple-darwin* )
2601 machine=powermac opsys=darwin
2602 # Define CPP as follows to make autoconf work correctly.
2a75d75d 2603 CPP="${CC-cc} -E -no-cpp-precomp"
c14dc0ed
AS
2604 # Use fink packages if available.
2605 if test -d /sw/include && test -d /sw/lib; then
2606 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
2607 CPP="${CPP} ${GCC_TEST_OPTIONS}"
2608 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
2609 fi
e0f712ba
AC
2610 ;;
2611
598a2813
AS
2612 ## AMD x86-64 Linux-based GNU system
2613 x86_64-*-linux-gnu* )
24b01ec4 2614 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2615 ;;
2616
ba4481b5
DL
2617 * )
2618 unported=yes
2619 ;;
2620esac
2621
2622### If the code above didn't choose an operating system, just choose
2623### an operating system based on the configuration name. You really
2624### only want to use this when you have no idea what the right
2625### operating system is; if you know what operating systems a machine
2626### runs, it's cleaner to make it explicit in the case statement
2627### above.
2628if test x"${opsys}" = x; then
2629 case "${canonical}" in
2630 *-gnu* ) opsys=gnu ;;
2631 *-bsd4.[01] ) opsys=bsd4-1 ;;
2632 *-bsd4.2 ) opsys=bsd4-2 ;;
2633 *-bsd4.3 ) opsys=bsd4-3 ;;
2634 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2635 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2636 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2637 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2638 *-sysv4.2uw* ) opsys=unixware ;;
55597d70
DL
2639 *-sysv5uw* ) opsys=unixware ;;
2640 *-sysv5OpenUNIX* ) opsys=unixware ;;
ba4481b5
DL
2641 *-sysv4.1* | *-sysvr4.1* )
2642 NON_GNU_CPP=/usr/lib/cpp
2643 opsys=usg5-4 ;;
2644 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2645 if [ x$NON_GNU_CPP = x ]; then
2646 if [ -f /usr/ccs/lib/cpp ]; then
2647 NON_GNU_CPP=/usr/ccs/lib/cpp
2648 else
2649 NON_GNU_CPP=/lib/cpp
2650 fi
2651 fi
2652 opsys=usg5-4-2 ;;
2653 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2654 * )
2655 unported=yes
2656 ;;
2657 esac
2658fi
2659
c0d27fcc 2660
22044edf 2661
ba4481b5 2662if test $unported = yes; then
c0d27fcc 2663 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2664Check \`etc/MACHINES' for recognized configuration names." >&5
2665echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2666Check \`etc/MACHINES' for recognized configuration names." >&2;}
2667 { (exit 1); exit 1; }; }
ba4481b5
DL
2668fi
2669
2670machfile="m/${machine}.h"
2671opsysfile="s/${opsys}.h"
2672
c0d27fcc 2673
ba4481b5
DL
2674#### Choose a compiler.
2675test -n "$CC" && cc_specified=yes
2676
2677# Save the value of CFLAGS that the user specified.
2678SPECIFIED_CFLAGS="$CFLAGS"
2679
2680case ${with_gcc} in
2681 "yes" ) CC="gcc" GCC=yes ;;
2682 "no" ) : ${CC=cc} ;;
503d2be0
AS
2683 * )
2684esac
2685ac_ext=c
2686ac_cpp='$CPP $CPPFLAGS'
2687ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2688ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2689ac_compiler_gnu=$ac_cv_c_compiler_gnu
2690if test -n "$ac_tool_prefix"; then
2691 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2692set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2693echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2694echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2695if test "${ac_cv_prog_CC+set}" = set; then
2696 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2697else
2698 if test -n "$CC"; then
2699 ac_cv_prog_CC="$CC" # Let the user override the test.
2700else
c0d27fcc
MR
2701as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2702for as_dir in $PATH
2703do
2704 IFS=$as_save_IFS
2705 test -z "$as_dir" && as_dir=.
2706 for ac_exec_ext in '' $ac_executable_extensions; do
2707 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2708 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2709 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2710 break 2
2711 fi
2712done
503d2be0
AS
2713done
2714
ba4481b5
DL
2715fi
2716fi
503d2be0 2717CC=$ac_cv_prog_CC
ba4481b5 2718if test -n "$CC"; then
c0d27fcc 2719 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2720echo "${ECHO_T}$CC" >&6
2721else
c0d27fcc 2722 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2723echo "${ECHO_T}no" >&6
2724fi
2725
2726fi
2727if test -z "$ac_cv_prog_CC"; then
2728 ac_ct_CC=$CC
2729 # Extract the first word of "gcc", so it can be a program name with args.
2730set dummy gcc; ac_word=$2
c0d27fcc 2731echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2732echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2733if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2734 echo $ECHO_N "(cached) $ECHO_C" >&6
2735else
2736 if test -n "$ac_ct_CC"; then
2737 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2738else
c0d27fcc
MR
2739as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2740for as_dir in $PATH
2741do
2742 IFS=$as_save_IFS
2743 test -z "$as_dir" && as_dir=.
2744 for ac_exec_ext in '' $ac_executable_extensions; do
2745 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2746 ac_cv_prog_ac_ct_CC="gcc"
2747 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2748 break 2
2749 fi
2750done
503d2be0
AS
2751done
2752
2753fi
2754fi
2755ac_ct_CC=$ac_cv_prog_ac_ct_CC
2756if test -n "$ac_ct_CC"; then
c0d27fcc 2757 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2758echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2759else
c0d27fcc 2760 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2761echo "${ECHO_T}no" >&6
2762fi
2763
2764 CC=$ac_ct_CC
2765else
2766 CC="$ac_cv_prog_CC"
ba4481b5
DL
2767fi
2768
2769if test -z "$CC"; then
503d2be0
AS
2770 if test -n "$ac_tool_prefix"; then
2771 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2772set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2773echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2774echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2775if test "${ac_cv_prog_CC+set}" = set; then
2776 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2777else
2778 if test -n "$CC"; then
2779 ac_cv_prog_CC="$CC" # Let the user override the test.
2780else
c0d27fcc
MR
2781as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2782for as_dir in $PATH
2783do
2784 IFS=$as_save_IFS
2785 test -z "$as_dir" && as_dir=.
2786 for ac_exec_ext in '' $ac_executable_extensions; do
2787 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2788 ac_cv_prog_CC="${ac_tool_prefix}cc"
2789 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2790 break 2
2791 fi
2792done
503d2be0
AS
2793done
2794
2795fi
2796fi
2797CC=$ac_cv_prog_CC
2798if test -n "$CC"; then
c0d27fcc 2799 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2800echo "${ECHO_T}$CC" >&6
2801else
c0d27fcc 2802 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2803echo "${ECHO_T}no" >&6
2804fi
2805
2806fi
2807if test -z "$ac_cv_prog_CC"; then
2808 ac_ct_CC=$CC
2809 # Extract the first word of "cc", so it can be a program name with args.
2810set dummy cc; ac_word=$2
c0d27fcc 2811echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2813if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2814 echo $ECHO_N "(cached) $ECHO_C" >&6
2815else
2816 if test -n "$ac_ct_CC"; then
2817 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2818else
c0d27fcc
MR
2819as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2820for as_dir in $PATH
2821do
2822 IFS=$as_save_IFS
2823 test -z "$as_dir" && as_dir=.
2824 for ac_exec_ext in '' $ac_executable_extensions; do
2825 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2826 ac_cv_prog_ac_ct_CC="cc"
2827 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2828 break 2
2829 fi
2830done
503d2be0
AS
2831done
2832
2833fi
2834fi
2835ac_ct_CC=$ac_cv_prog_ac_ct_CC
2836if test -n "$ac_ct_CC"; then
c0d27fcc 2837 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2838echo "${ECHO_T}$ac_ct_CC" >&6
2839else
c0d27fcc 2840 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2841echo "${ECHO_T}no" >&6
2842fi
2843
2844 CC=$ac_ct_CC
2845else
2846 CC="$ac_cv_prog_CC"
2847fi
2848
2849fi
2850if test -z "$CC"; then
2851 # Extract the first word of "cc", so it can be a program name with args.
2852set dummy cc; ac_word=$2
c0d27fcc 2853echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2854echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2855if test "${ac_cv_prog_CC+set}" = set; then
2856 echo $ECHO_N "(cached) $ECHO_C" >&6
2857else
2858 if test -n "$CC"; then
2859 ac_cv_prog_CC="$CC" # Let the user override the test.
2860else
2861 ac_prog_rejected=no
c0d27fcc
MR
2862as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2863for as_dir in $PATH
2864do
2865 IFS=$as_save_IFS
2866 test -z "$as_dir" && as_dir=.
2867 for ac_exec_ext in '' $ac_executable_extensions; do
2868 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2869 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2870 ac_prog_rejected=yes
2871 continue
2872 fi
2873 ac_cv_prog_CC="cc"
2874 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2875 break 2
2876 fi
2877done
503d2be0
AS
2878done
2879
ba4481b5
DL
2880if test $ac_prog_rejected = yes; then
2881 # We found a bogon in the path, so make sure we never use it.
2882 set dummy $ac_cv_prog_CC
2883 shift
503d2be0 2884 if test $# != 0; then
ba4481b5
DL
2885 # We chose a different compiler from the bogus one.
2886 # However, it has the same basename, so the bogon will be chosen
2887 # first if we set CC to just the basename; use the full file name.
2888 shift
6bae0ccf 2889 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2890 fi
2891fi
2892fi
2893fi
503d2be0 2894CC=$ac_cv_prog_CC
ba4481b5 2895if test -n "$CC"; then
c0d27fcc 2896 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2897echo "${ECHO_T}$CC" >&6
ba4481b5 2898else
c0d27fcc 2899 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2900echo "${ECHO_T}no" >&6
ba4481b5
DL
2901fi
2902
503d2be0
AS
2903fi
2904if test -z "$CC"; then
2905 if test -n "$ac_tool_prefix"; then
2906 for ac_prog in cl
2907 do
2908 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2909set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2910echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2911echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2912if test "${ac_cv_prog_CC+set}" = set; then
2913 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2914else
2915 if test -n "$CC"; then
2916 ac_cv_prog_CC="$CC" # Let the user override the test.
2917else
c0d27fcc
MR
2918as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2919for as_dir in $PATH
2920do
2921 IFS=$as_save_IFS
2922 test -z "$as_dir" && as_dir=.
2923 for ac_exec_ext in '' $ac_executable_extensions; do
2924 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2925 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2926 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2927 break 2
2928 fi
2929done
503d2be0
AS
2930done
2931
c4bb2108
DL
2932fi
2933fi
503d2be0 2934CC=$ac_cv_prog_CC
c4bb2108 2935if test -n "$CC"; then
c0d27fcc 2936 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2937echo "${ECHO_T}$CC" >&6
c4bb2108 2938else
c0d27fcc 2939 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2940echo "${ECHO_T}no" >&6
2941fi
2942
2943 test -n "$CC" && break
2944 done
2945fi
2946if test -z "$CC"; then
2947 ac_ct_CC=$CC
2948 for ac_prog in cl
2949do
2950 # Extract the first word of "$ac_prog", so it can be a program name with args.
2951set dummy $ac_prog; ac_word=$2
c0d27fcc 2952echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2953echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2954if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2955 echo $ECHO_N "(cached) $ECHO_C" >&6
2956else
2957 if test -n "$ac_ct_CC"; then
2958 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2959else
c0d27fcc
MR
2960as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2961for as_dir in $PATH
2962do
2963 IFS=$as_save_IFS
2964 test -z "$as_dir" && as_dir=.
2965 for ac_exec_ext in '' $ac_executable_extensions; do
2966 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2967 ac_cv_prog_ac_ct_CC="$ac_prog"
2968 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2969 break 2
2970 fi
2971done
503d2be0
AS
2972done
2973
c4bb2108 2974fi
503d2be0
AS
2975fi
2976ac_ct_CC=$ac_cv_prog_ac_ct_CC
2977if test -n "$ac_ct_CC"; then
c0d27fcc 2978 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2979echo "${ECHO_T}$ac_ct_CC" >&6
2980else
c0d27fcc 2981 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2982echo "${ECHO_T}no" >&6
ba4481b5
DL
2983fi
2984
503d2be0
AS
2985 test -n "$ac_ct_CC" && break
2986done
ba4481b5 2987
503d2be0
AS
2988 CC=$ac_ct_CC
2989fi
2990
2991fi
ba4481b5 2992
c0d27fcc 2993
19650fd6
AS
2994test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2995See \`config.log' for more details." >&5
2996echo "$as_me: error: no acceptable C compiler found in \$PATH
2997See \`config.log' for more details." >&2;}
503d2be0 2998 { (exit 1); exit 1; }; }
c4bb2108 2999
503d2be0 3000# Provide some information about the compiler.
c0d27fcc 3001echo "$as_me:$LINENO:" \
503d2be0
AS
3002 "checking for C compiler version" >&5
3003ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 3004{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
3005 (eval $ac_compiler --version </dev/null >&5) 2>&5
3006 ac_status=$?
c0d27fcc 3007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3008 (exit $ac_status); }
c0d27fcc 3009{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
3010 (eval $ac_compiler -v </dev/null >&5) 2>&5
3011 ac_status=$?
c0d27fcc 3012 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3013 (exit $ac_status); }
c0d27fcc 3014{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
3015 (eval $ac_compiler -V </dev/null >&5) 2>&5
3016 ac_status=$?
c0d27fcc 3017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3018 (exit $ac_status); }
3019
3020cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3021/* confdefs.h. */
3022_ACEOF
3023cat confdefs.h >>conftest.$ac_ext
3024cat >>conftest.$ac_ext <<_ACEOF
3025/* end confdefs.h. */
c4bb2108 3026
503d2be0
AS
3027int
3028main ()
3029{
3030
3031 ;
3032 return 0;
3033}
3034_ACEOF
3035ac_clean_files_save=$ac_clean_files
19650fd6 3036ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
3037# Try to create an executable without -o first, disregard a.out.
3038# It will help us diagnose broken compilers, and finding out an intuition
3039# of exeext.
35996d22
AS
3040echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3041echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
503d2be0 3042ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 3043if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
3044 (eval $ac_link_default) 2>&5
3045 ac_status=$?
c0d27fcc 3046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3047 (exit $ac_status); }; then
3048 # Find the output, starting from the most likely. This scheme is
3049# not robust to junk in `.', hence go to wildcards (a.*) only as a last
3050# resort.
c0d27fcc
MR
3051
3052# Be careful to initialize this variable, since it used to be cached.
3053# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
3054ac_cv_exeext=
19650fd6
AS
3055# b.out is created by i960 compilers.
3056for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3057do
6bae0ccf 3058 test -f "$ac_file" || continue
503d2be0 3059 case $ac_file in
19650fd6 3060 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
35996d22 3061 ;;
19650fd6 3062 conftest.$ac_ext )
35996d22
AS
3063 # This is the source file.
3064 ;;
19650fd6 3065 [ab].out )
35996d22
AS
3066 # We found the default executable, but exeext='' is most
3067 # certainly right.
3068 break;;
19650fd6 3069 *.* )
35996d22
AS
3070 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3071 # FIXME: I believe we export ac_cv_exeext for Libtool,
3072 # but it would be cool to find out if it's true. Does anybody
3073 # maintain Libtool? --akim.
3074 export ac_cv_exeext
3075 break;;
19650fd6 3076 * )
35996d22 3077 break;;
503d2be0
AS
3078 esac
3079done
3080else
3081 echo "$as_me: failed program was:" >&5
19650fd6
AS
3082sed 's/^/| /' conftest.$ac_ext >&5
3083
6bae0ccf 3084{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
19650fd6 3085See \`config.log' for more details." >&5
6bae0ccf 3086echo "$as_me: error: C compiler cannot create executables
19650fd6 3087See \`config.log' for more details." >&2;}
503d2be0
AS
3088 { (exit 77); exit 77; }; }
3089fi
3090
3091ac_exeext=$ac_cv_exeext
c0d27fcc 3092echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3093echo "${ECHO_T}$ac_file" >&6
3094
3095# Check the compiler produces executables we can run. If not, either
3096# the compiler is broken, or we cross compile.
c0d27fcc 3097echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3098echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3099# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3100# If not cross compiling, check that we can run a simple program.
3101if test "$cross_compiling" != yes; then
3102 if { ac_try='./$ac_file'
c0d27fcc 3103 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3104 (eval $ac_try) 2>&5
3105 ac_status=$?
c0d27fcc 3106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3107 (exit $ac_status); }; }; then
3108 cross_compiling=no
ba4481b5 3109 else
503d2be0
AS
3110 if test "$cross_compiling" = maybe; then
3111 cross_compiling=yes
3112 else
c0d27fcc 3113 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
19650fd6
AS
3114If you meant to cross compile, use \`--host'.
3115See \`config.log' for more details." >&5
503d2be0 3116echo "$as_me: error: cannot run C compiled programs.
19650fd6
AS
3117If you meant to cross compile, use \`--host'.
3118See \`config.log' for more details." >&2;}
503d2be0
AS
3119 { (exit 1); exit 1; }; }
3120 fi
ba4481b5 3121 fi
503d2be0 3122fi
c0d27fcc 3123echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3124echo "${ECHO_T}yes" >&6
3125
19650fd6 3126rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3127ac_clean_files=$ac_clean_files_save
3128# Check the compiler produces executables we can run. If not, either
3129# the compiler is broken, or we cross compile.
c0d27fcc 3130echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3131echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3132echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3133echo "${ECHO_T}$cross_compiling" >&6
3134
c0d27fcc
MR
3135echo "$as_me:$LINENO: checking for suffix of executables" >&5
3136echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3137if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3138 (eval $ac_link) 2>&5
3139 ac_status=$?
c0d27fcc 3140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3141 (exit $ac_status); }; then
3142 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3143# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3144# work properly (i.e., refer to `conftest.exe'), while it won't with
3145# `rm'.
6bae0ccf
DL
3146for ac_file in conftest.exe conftest conftest.*; do
3147 test -f "$ac_file" || continue
503d2be0 3148 case $ac_file in
6bae0ccf 3149 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0 3150 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
35996d22
AS
3151 export ac_cv_exeext
3152 break;;
503d2be0
AS
3153 * ) break;;
3154 esac
3155done
ba4481b5 3156else
19650fd6
AS
3157 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3158See \`config.log' for more details." >&5
3159echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3160See \`config.log' for more details." >&2;}
503d2be0 3161 { (exit 1); exit 1; }; }
ba4481b5 3162fi
ba4481b5 3163
503d2be0 3164rm -f conftest$ac_cv_exeext
c0d27fcc 3165echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3166echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3167
503d2be0
AS
3168rm -f conftest.$ac_ext
3169EXEEXT=$ac_cv_exeext
3170ac_exeext=$EXEEXT
c0d27fcc
MR
3171echo "$as_me:$LINENO: checking for suffix of object files" >&5
3172echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3173if test "${ac_cv_objext+set}" = set; then
3174 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3175else
503d2be0 3176 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3177/* confdefs.h. */
3178_ACEOF
3179cat confdefs.h >>conftest.$ac_ext
3180cat >>conftest.$ac_ext <<_ACEOF
3181/* end confdefs.h. */
ba4481b5 3182
503d2be0
AS
3183int
3184main ()
3185{
ba4481b5 3186
503d2be0
AS
3187 ;
3188 return 0;
3189}
3190_ACEOF
3191rm -f conftest.o conftest.obj
c0d27fcc 3192if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3193 (eval $ac_compile) 2>&5
3194 ac_status=$?
c0d27fcc 3195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3196 (exit $ac_status); }; then
3197 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3198 case $ac_file in
6bae0ccf 3199 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3200 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3201 break;;
3202 esac
3203done
c4bb2108 3204else
503d2be0 3205 echo "$as_me: failed program was:" >&5
19650fd6
AS
3206sed 's/^/| /' conftest.$ac_ext >&5
3207
3208{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3209See \`config.log' for more details." >&5
3210echo "$as_me: error: cannot compute suffix of object files: cannot compile
3211See \`config.log' for more details." >&2;}
503d2be0 3212 { (exit 1); exit 1; }; }
c4bb2108
DL
3213fi
3214
503d2be0
AS
3215rm -f conftest.$ac_cv_objext conftest.$ac_ext
3216fi
c0d27fcc 3217echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3218echo "${ECHO_T}$ac_cv_objext" >&6
3219OBJEXT=$ac_cv_objext
3220ac_objext=$OBJEXT
c0d27fcc 3221echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3222echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3223if test "${ac_cv_c_compiler_gnu+set}" = set; then
3224 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3225else
503d2be0 3226 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3227/* confdefs.h. */
3228_ACEOF
3229cat confdefs.h >>conftest.$ac_ext
3230cat >>conftest.$ac_ext <<_ACEOF
3231/* end confdefs.h. */
503d2be0
AS
3232
3233int
3234main ()
3235{
3236#ifndef __GNUC__
3237 choke me
3238#endif
3239
3240 ;
3241 return 0;
3242}
3243_ACEOF
3244rm -f conftest.$ac_objext
c0d27fcc 3245if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3246 (eval $ac_compile) 2>conftest.er1
503d2be0 3247 ac_status=$?
35996d22
AS
3248 grep -v '^ *+' conftest.er1 >conftest.err
3249 rm -f conftest.er1
3250 cat conftest.err >&5
c0d27fcc 3251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3252 (exit $ac_status); } &&
4494a266
JD
3253 { ac_try='test -z "$ac_c_werror_flag"
3254 || test ! -s conftest.err'
35996d22
AS
3255 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3256 (eval $ac_try) 2>&5
3257 ac_status=$?
3258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3259 (exit $ac_status); }; } &&
3260 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3261 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3262 (eval $ac_try) 2>&5
3263 ac_status=$?
c0d27fcc 3264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3265 (exit $ac_status); }; }; then
3266 ac_compiler_gnu=yes
3267else
3268 echo "$as_me: failed program was:" >&5
19650fd6
AS
3269sed 's/^/| /' conftest.$ac_ext >&5
3270
503d2be0
AS
3271ac_compiler_gnu=no
3272fi
35996d22 3273rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3274ac_cv_c_compiler_gnu=$ac_compiler_gnu
3275
3276fi
c0d27fcc 3277echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3278echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3279GCC=`test $ac_compiler_gnu = yes && echo yes`
3280ac_test_CFLAGS=${CFLAGS+set}
3281ac_save_CFLAGS=$CFLAGS
3282CFLAGS="-g"
c0d27fcc 3283echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3284echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3285if test "${ac_cv_prog_cc_g+set}" = set; then
3286 echo $ECHO_N "(cached) $ECHO_C" >&6
3287else
3288 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3289/* confdefs.h. */
3290_ACEOF
3291cat confdefs.h >>conftest.$ac_ext
3292cat >>conftest.$ac_ext <<_ACEOF
3293/* end confdefs.h. */
503d2be0
AS
3294
3295int
3296main ()
3297{
3298
3299 ;
3300 return 0;
3301}
3302_ACEOF
3303rm -f conftest.$ac_objext
c0d27fcc 3304if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3305 (eval $ac_compile) 2>conftest.er1
503d2be0 3306 ac_status=$?
35996d22
AS
3307 grep -v '^ *+' conftest.er1 >conftest.err
3308 rm -f conftest.er1
3309 cat conftest.err >&5
c0d27fcc 3310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3311 (exit $ac_status); } &&
4494a266
JD
3312 { ac_try='test -z "$ac_c_werror_flag"
3313 || test ! -s conftest.err'
35996d22
AS
3314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3315 (eval $ac_try) 2>&5
3316 ac_status=$?
3317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3318 (exit $ac_status); }; } &&
3319 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3321 (eval $ac_try) 2>&5
3322 ac_status=$?
c0d27fcc 3323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3324 (exit $ac_status); }; }; then
ba4481b5
DL
3325 ac_cv_prog_cc_g=yes
3326else
503d2be0 3327 echo "$as_me: failed program was:" >&5
19650fd6
AS
3328sed 's/^/| /' conftest.$ac_ext >&5
3329
503d2be0 3330ac_cv_prog_cc_g=no
ba4481b5 3331fi
35996d22 3332rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 3333fi
c0d27fcc 3334echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3335echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3336if test "$ac_test_CFLAGS" = set; then
503d2be0 3337 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3338elif test $ac_cv_prog_cc_g = yes; then
3339 if test "$GCC" = yes; then
ba4481b5
DL
3340 CFLAGS="-g -O2"
3341 else
c4bb2108 3342 CFLAGS="-g"
ba4481b5 3343 fi
22afa6e8 3344else
c4bb2108
DL
3345 if test "$GCC" = yes; then
3346 CFLAGS="-O2"
3347 else
3348 CFLAGS=
3349 fi
ba4481b5 3350fi
6bae0ccf
DL
3351echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3352echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3353if test "${ac_cv_prog_cc_stdc+set}" = set; then
3354 echo $ECHO_N "(cached) $ECHO_C" >&6
3355else
3356 ac_cv_prog_cc_stdc=no
3357ac_save_CC=$CC
3358cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3359/* confdefs.h. */
3360_ACEOF
3361cat confdefs.h >>conftest.$ac_ext
3362cat >>conftest.$ac_ext <<_ACEOF
3363/* end confdefs.h. */
6bae0ccf
DL
3364#include <stdarg.h>
3365#include <stdio.h>
3366#include <sys/types.h>
3367#include <sys/stat.h>
3368/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3369struct buf { int x; };
3370FILE * (*rcsopen) (struct buf *, struct stat *, int);
3371static char *e (p, i)
3372 char **p;
3373 int i;
3374{
3375 return p[i];
3376}
3377static char *f (char * (*g) (char **, int), char **p, ...)
3378{
3379 char *s;
3380 va_list v;
3381 va_start (v,p);
3382 s = g (p, va_arg (v,int));
3383 va_end (v);
3384 return s;
3385}
35996d22
AS
3386
3387/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3388 function prototypes and stuff, but not '\xHH' hex character constants.
3389 These don't provoke an error unfortunately, instead are silently treated
3390 as 'x'. The following induces an error, until -std1 is added to get
3391 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3392 array size at least. It's necessary to write '\x00'==0 to get something
3393 that's true only with -std1. */
3394int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3395
6bae0ccf
DL
3396int test (int i, double x);
3397struct s1 {int (*f) (int a);};
3398struct s2 {int (*f) (double a);};
3399int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3400int argc;
3401char **argv;
3402int
3403main ()
3404{
3405return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3406 ;
3407 return 0;
3408}
3409_ACEOF
3410# Don't try gcc -ansi; that turns off useful extensions and
3411# breaks some systems' header files.
3412# AIX -qlanglvl=ansi
3413# Ultrix and OSF/1 -std1
3414# HP-UX 10.20 and later -Ae
3415# HP-UX older versions -Aa -D_HPUX_SOURCE
3416# SVR4 -Xc -D__EXTENSIONS__
3417for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3418do
3419 CC="$ac_save_CC $ac_arg"
3420 rm -f conftest.$ac_objext
3421if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3422 (eval $ac_compile) 2>conftest.er1
6bae0ccf 3423 ac_status=$?
35996d22
AS
3424 grep -v '^ *+' conftest.er1 >conftest.err
3425 rm -f conftest.er1
3426 cat conftest.err >&5
6bae0ccf
DL
3427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3428 (exit $ac_status); } &&
4494a266
JD
3429 { ac_try='test -z "$ac_c_werror_flag"
3430 || test ! -s conftest.err'
35996d22
AS
3431 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3432 (eval $ac_try) 2>&5
3433 ac_status=$?
3434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3435 (exit $ac_status); }; } &&
3436 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
3437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3438 (eval $ac_try) 2>&5
3439 ac_status=$?
3440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3441 (exit $ac_status); }; }; then
3442 ac_cv_prog_cc_stdc=$ac_arg
3443break
3444else
3445 echo "$as_me: failed program was:" >&5
19650fd6
AS
3446sed 's/^/| /' conftest.$ac_ext >&5
3447
6bae0ccf 3448fi
35996d22 3449rm -f conftest.err conftest.$ac_objext
6bae0ccf
DL
3450done
3451rm -f conftest.$ac_ext conftest.$ac_objext
3452CC=$ac_save_CC
3453
3454fi
3455
3456case "x$ac_cv_prog_cc_stdc" in
3457 x|xno)
3458 echo "$as_me:$LINENO: result: none needed" >&5
3459echo "${ECHO_T}none needed" >&6 ;;
3460 *)
3461 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3462echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3463 CC="$CC $ac_cv_prog_cc_stdc" ;;
3464esac
3465
503d2be0
AS
3466# Some people use a C++ compiler to compile C. Since we use `exit',
3467# in C++ we need to declare it. In case someone uses the same compiler
3468# for both compiling C and C++ we need to have the C++ compiler decide
3469# the declaration of exit, since it's the most demanding environment.
3470cat >conftest.$ac_ext <<_ACEOF
3471#ifndef __cplusplus
3472 choke me
3473#endif
3474_ACEOF
3475rm -f conftest.$ac_objext
c0d27fcc 3476if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3477 (eval $ac_compile) 2>conftest.er1
503d2be0 3478 ac_status=$?
35996d22
AS
3479 grep -v '^ *+' conftest.er1 >conftest.err
3480 rm -f conftest.er1
3481 cat conftest.err >&5
c0d27fcc 3482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3483 (exit $ac_status); } &&
4494a266
JD
3484 { ac_try='test -z "$ac_c_werror_flag"
3485 || test ! -s conftest.err'
35996d22
AS
3486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3487 (eval $ac_try) 2>&5
3488 ac_status=$?
3489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3490 (exit $ac_status); }; } &&
3491 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3493 (eval $ac_try) 2>&5
3494 ac_status=$?
c0d27fcc 3495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3496 (exit $ac_status); }; }; then
3497 for ac_declaration in \
35996d22 3498 '' \
503d2be0
AS
3499 'extern "C" void std::exit (int) throw (); using std::exit;' \
3500 'extern "C" void std::exit (int); using std::exit;' \
3501 'extern "C" void exit (int) throw ();' \
3502 'extern "C" void exit (int);' \
cffcede7 3503 'void exit (int);'
503d2be0
AS
3504do
3505 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3506/* confdefs.h. */
3507_ACEOF
3508cat confdefs.h >>conftest.$ac_ext
3509cat >>conftest.$ac_ext <<_ACEOF
3510/* end confdefs.h. */
57669b57 3511$ac_declaration
35996d22 3512#include <stdlib.h>
503d2be0
AS
3513int
3514main ()
3515{
3516exit (42);
3517 ;
3518 return 0;
3519}
3520_ACEOF
3521rm -f conftest.$ac_objext
c0d27fcc 3522if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3523 (eval $ac_compile) 2>conftest.er1
503d2be0 3524 ac_status=$?
35996d22
AS
3525 grep -v '^ *+' conftest.er1 >conftest.err
3526 rm -f conftest.er1
3527 cat conftest.err >&5
c0d27fcc 3528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3529 (exit $ac_status); } &&
4494a266
JD
3530 { ac_try='test -z "$ac_c_werror_flag"
3531 || test ! -s conftest.err'
35996d22
AS
3532 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3533 (eval $ac_try) 2>&5
3534 ac_status=$?
3535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3536 (exit $ac_status); }; } &&
3537 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3539 (eval $ac_try) 2>&5
3540 ac_status=$?
c0d27fcc 3541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3542 (exit $ac_status); }; }; then
3543 :
3544else
3545 echo "$as_me: failed program was:" >&5
19650fd6
AS
3546sed 's/^/| /' conftest.$ac_ext >&5
3547
503d2be0
AS
3548continue
3549fi
35996d22 3550rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 3551 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3552/* confdefs.h. */
3553_ACEOF
3554cat confdefs.h >>conftest.$ac_ext
3555cat >>conftest.$ac_ext <<_ACEOF
3556/* end confdefs.h. */
503d2be0
AS
3557$ac_declaration
3558int
3559main ()
3560{
3561exit (42);
3562 ;
3563 return 0;
3564}
3565_ACEOF
3566rm -f conftest.$ac_objext
c0d27fcc 3567if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 3568 (eval $ac_compile) 2>conftest.er1
503d2be0 3569 ac_status=$?
35996d22
AS
3570 grep -v '^ *+' conftest.er1 >conftest.err
3571 rm -f conftest.er1
3572 cat conftest.err >&5
c0d27fcc 3573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3574 (exit $ac_status); } &&
4494a266
JD
3575 { ac_try='test -z "$ac_c_werror_flag"
3576 || test ! -s conftest.err'
35996d22
AS
3577 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3578 (eval $ac_try) 2>&5
3579 ac_status=$?
3580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3581 (exit $ac_status); }; } &&
3582 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3583 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3584 (eval $ac_try) 2>&5
3585 ac_status=$?
c0d27fcc 3586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3587 (exit $ac_status); }; }; then
3588 break
3589else
3590 echo "$as_me: failed program was:" >&5
19650fd6
AS
3591sed 's/^/| /' conftest.$ac_ext >&5
3592
503d2be0 3593fi
35996d22 3594rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3595done
3596rm -f conftest*
3597if test -n "$ac_declaration"; then
3598 echo '#ifdef __cplusplus' >>confdefs.h
3599 echo $ac_declaration >>confdefs.h
3600 echo '#endif' >>confdefs.h
3601fi
ba4481b5 3602
503d2be0
AS
3603else
3604 echo "$as_me: failed program was:" >&5
19650fd6
AS
3605sed 's/^/| /' conftest.$ac_ext >&5
3606
503d2be0 3607fi
35996d22 3608rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3609ac_ext=c
3610ac_cpp='$CPP $CPPFLAGS'
3611ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3612ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3613ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3614
c0d27fcc 3615
ba4481b5
DL
3616# On Suns, sometimes $CPP names a directory.
3617if test -n "$CPP" && test -d "$CPP"; then
3618 CPP=
3619fi
3620
3621#### Some systems specify a CPP to use unless we are using GCC.
3622#### Now that we know whether we are using GCC, we can decide whether
3623#### to use that one.
3624if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3625then
3626 CPP="$NON_GNU_CPP"
3627fi
3628
3629#### Some systems specify a CC to use unless we are using GCC.
3630#### Now that we know whether we are using GCC, we can decide whether
3631#### to use that one.
3632if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3633 test x$cc_specified != xyes
3634then
3635 CC="$NON_GNU_CC"
3636fi
3637
3638if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3639then
3640 CC="$CC $GCC_TEST_OPTIONS"
3641fi
3642
3643if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3644then
3645 CC="$CC $NON_GCC_TEST_OPTIONS"
3646fi
3647
6a3a24fa 3648#### Some other nice autoconf tests.
ba4481b5 3649
c0d27fcc 3650echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3651echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3652LN_S=$as_ln_s
3653if test "$LN_S" = "ln -s"; then
c0d27fcc 3654 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3655echo "${ECHO_T}yes" >&6
ba4481b5 3656else
c0d27fcc 3657 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3658echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3659fi
3660
503d2be0
AS
3661ac_ext=c
3662ac_cpp='$CPP $CPPFLAGS'
3663ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3664ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3665ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3666echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3667echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3668# On Suns, sometimes $CPP names a directory.
3669if test -n "$CPP" && test -d "$CPP"; then
3670 CPP=
3671fi
3672if test -z "$CPP"; then
503d2be0
AS
3673 if test "${ac_cv_prog_CPP+set}" = set; then
3674 echo $ECHO_N "(cached) $ECHO_C" >&6
3675else
3676 # Double quotes because CPP needs to be expanded
3677 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3678 do
3679 ac_preproc_ok=false
3680for ac_c_preproc_warn_flag in '' yes
3681do
3682 # Use a header file that comes with gcc, so configuring glibc
3683 # with a fresh cross-compiler works.
19650fd6
AS
3684 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3685 # <limits.h> exists even on freestanding compilers.
ba4481b5 3686 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3687 # not just through cpp. "Syntax error" is here to catch this case.
3688 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3689/* confdefs.h. */
3690_ACEOF
3691cat confdefs.h >>conftest.$ac_ext
3692cat >>conftest.$ac_ext <<_ACEOF
3693/* end confdefs.h. */
3694#ifdef __STDC__
3695# include <limits.h>
3696#else
3697# include <assert.h>
3698#endif
35996d22 3699 Syntax error
503d2be0 3700_ACEOF
c0d27fcc 3701if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3702 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3703 ac_status=$?
6bae0ccf 3704 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3705 rm -f conftest.er1
3706 cat conftest.err >&5
c0d27fcc 3707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3708 (exit $ac_status); } >/dev/null; then
3709 if test -s conftest.err; then
3710 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3711 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3712 else
3713 ac_cpp_err=
3714 fi
3715else
3716 ac_cpp_err=yes
3717fi
3718if test -z "$ac_cpp_err"; then
ba4481b5
DL
3719 :
3720else
503d2be0 3721 echo "$as_me: failed program was:" >&5
19650fd6
AS
3722sed 's/^/| /' conftest.$ac_ext >&5
3723
503d2be0
AS
3724 # Broken: fails on valid input.
3725continue
3726fi
3727rm -f conftest.err conftest.$ac_ext
3728
3729 # OK, works on sane cases. Now check whether non-existent headers
3730 # can be detected and how.
3731 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3732/* confdefs.h. */
3733_ACEOF
3734cat confdefs.h >>conftest.$ac_ext
3735cat >>conftest.$ac_ext <<_ACEOF
3736/* end confdefs.h. */
503d2be0
AS
3737#include <ac_nonexistent.h>
3738_ACEOF
c0d27fcc 3739if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3740 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3741 ac_status=$?
6bae0ccf 3742 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3743 rm -f conftest.er1
3744 cat conftest.err >&5
c0d27fcc 3745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3746 (exit $ac_status); } >/dev/null; then
3747 if test -s conftest.err; then
3748 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3749 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3750 else
3751 ac_cpp_err=
3752 fi
3753else
3754 ac_cpp_err=yes
3755fi
3756if test -z "$ac_cpp_err"; then
3757 # Broken: success on invalid input.
3758continue
c4bb2108 3759else
503d2be0 3760 echo "$as_me: failed program was:" >&5
19650fd6
AS
3761sed 's/^/| /' conftest.$ac_ext >&5
3762
503d2be0
AS
3763 # Passes both tests.
3764ac_preproc_ok=:
3765break
3766fi
3767rm -f conftest.err conftest.$ac_ext
3768
3769done
3770# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3771rm -f conftest.err conftest.$ac_ext
3772if $ac_preproc_ok; then
3773 break
3774fi
3775
3776 done
3777 ac_cv_prog_CPP=$CPP
3778
3779fi
3780 CPP=$ac_cv_prog_CPP
3781else
3782 ac_cv_prog_CPP=$CPP
3783fi
c0d27fcc 3784echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3785echo "${ECHO_T}$CPP" >&6
3786ac_preproc_ok=false
3787for ac_c_preproc_warn_flag in '' yes
3788do
3789 # Use a header file that comes with gcc, so configuring glibc
3790 # with a fresh cross-compiler works.
19650fd6
AS
3791 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3792 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3793 # On the NeXT, cc -E runs the code through the compiler's parser,
3794 # not just through cpp. "Syntax error" is here to catch this case.
3795 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3796/* confdefs.h. */
3797_ACEOF
3798cat confdefs.h >>conftest.$ac_ext
3799cat >>conftest.$ac_ext <<_ACEOF
3800/* end confdefs.h. */
3801#ifdef __STDC__
3802# include <limits.h>
3803#else
3804# include <assert.h>
3805#endif
35996d22 3806 Syntax error
503d2be0 3807_ACEOF
c0d27fcc 3808if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3809 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3810 ac_status=$?
6bae0ccf 3811 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3812 rm -f conftest.er1
3813 cat conftest.err >&5
c0d27fcc 3814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3815 (exit $ac_status); } >/dev/null; then
3816 if test -s conftest.err; then
3817 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3818 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3819 else
3820 ac_cpp_err=
3821 fi
3822else
3823 ac_cpp_err=yes
3824fi
3825if test -z "$ac_cpp_err"; then
ba4481b5
DL
3826 :
3827else
503d2be0 3828 echo "$as_me: failed program was:" >&5
19650fd6
AS
3829sed 's/^/| /' conftest.$ac_ext >&5
3830
503d2be0
AS
3831 # Broken: fails on valid input.
3832continue
3833fi
3834rm -f conftest.err conftest.$ac_ext
3835
3836 # OK, works on sane cases. Now check whether non-existent headers
3837 # can be detected and how.
3838 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
3839/* confdefs.h. */
3840_ACEOF
3841cat confdefs.h >>conftest.$ac_ext
3842cat >>conftest.$ac_ext <<_ACEOF
3843/* end confdefs.h. */
503d2be0
AS
3844#include <ac_nonexistent.h>
3845_ACEOF
c0d27fcc 3846if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3847 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3848 ac_status=$?
6bae0ccf 3849 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3850 rm -f conftest.er1
3851 cat conftest.err >&5
c0d27fcc 3852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3853 (exit $ac_status); } >/dev/null; then
3854 if test -s conftest.err; then
3855 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 3856 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
3857 else
3858 ac_cpp_err=
3859 fi
3860else
3861 ac_cpp_err=yes
c4bb2108 3862fi
503d2be0
AS
3863if test -z "$ac_cpp_err"; then
3864 # Broken: success on invalid input.
3865continue
3866else
3867 echo "$as_me: failed program was:" >&5
19650fd6
AS
3868sed 's/^/| /' conftest.$ac_ext >&5
3869
503d2be0
AS
3870 # Passes both tests.
3871ac_preproc_ok=:
3872break
ba4481b5 3873fi
503d2be0
AS
3874rm -f conftest.err conftest.$ac_ext
3875
3876done
3877# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3878rm -f conftest.err conftest.$ac_ext
3879if $ac_preproc_ok; then
3880 :
ba4481b5 3881else
19650fd6
AS
3882 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3883See \`config.log' for more details." >&5
3884echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3885See \`config.log' for more details." >&2;}
503d2be0 3886 { (exit 1); exit 1; }; }
ba4481b5 3887fi
503d2be0
AS
3888
3889ac_ext=c
3890ac_cpp='$CPP $CPPFLAGS'
3891ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3892ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3893ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3894
3895# Find a good install program. We prefer a C program (faster),
3896# so one script is as good as another. But avoid the broken or
3897# incompatible versions:
3898# SysV /etc/install, /usr/sbin/install
3899# SunOS /usr/etc/install
3900# IRIX /sbin/install
3901# AIX /bin/install
503d2be0 3902# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3903# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3904# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3905# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
35996d22 3906# OS/2's system install, which has a completely different semantic
ba4481b5 3907# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3908echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3909echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3910if test -z "$INSTALL"; then
503d2be0
AS
3911if test "${ac_cv_path_install+set}" = set; then
3912 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3913else
c0d27fcc
MR
3914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3915for as_dir in $PATH
3916do
3917 IFS=$as_save_IFS
3918 test -z "$as_dir" && as_dir=.
3919 # Account for people who put trailing slashes in PATH elements.
3920case $as_dir/ in
3921 ./ | .// | /cC/* | \
3922 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
35996d22 3923 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
c0d27fcc
MR
3924 /usr/ucb/* ) ;;
3925 *)
3926 # OSF1 and SCO ODT 3.0 have their own names for install.
3927 # Don't use installbsd from OSF since it installs stuff as root
3928 # by default.
3929 for ac_prog in ginstall scoinst install; do
3930 for ac_exec_ext in '' $ac_executable_extensions; do
35996d22
AS
3931 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3932 if test $ac_prog = install &&
3933 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3934 # AIX install. It has an incompatible calling convention.
3935 :
3936 elif test $ac_prog = install &&
3937 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3938 # program-specific install script used by HP pwplus--don't use.
3939 :
3940 else
3941 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3942 break 3
3943 fi
3944 fi
ba4481b5 3945 done
c0d27fcc
MR
3946 done
3947 ;;
3948esac
3949done
3950
ba4481b5
DL
3951
3952fi
3953 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3954 INSTALL=$ac_cv_path_install
ba4481b5
DL
3955 else
3956 # As a last resort, use the slow shell script. We don't cache a
3957 # path for INSTALL within a source directory, because that will
3958 # break other packages using the cache if that directory is
3959 # removed, or if the path is relative.
503d2be0 3960 INSTALL=$ac_install_sh
ba4481b5
DL
3961 fi
3962fi
c0d27fcc 3963echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3964echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3965
3966# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3967# It thinks the first close brace ends the variable substitution.
3968test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3969
503d2be0 3970test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3971
ba4481b5
DL
3972test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3973
c0d27fcc
MR
3974if test "x$RANLIB" = x; then
3975 if test -n "$ac_tool_prefix"; then
3976 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3977set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3978echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3979echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3980if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3981 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3982else
3983 if test -n "$RANLIB"; then
3984 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3985else
c0d27fcc
MR
3986as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3987for as_dir in $PATH
3988do
3989 IFS=$as_save_IFS
3990 test -z "$as_dir" && as_dir=.
3991 for ac_exec_ext in '' $ac_executable_extensions; do
3992 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3993 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3994 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3995 break 2
3996 fi
3997done
503d2be0
AS
3998done
3999
7397acc4
DL
4000fi
4001fi
503d2be0 4002RANLIB=$ac_cv_prog_RANLIB
7397acc4 4003if test -n "$RANLIB"; then
c0d27fcc 4004 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
4005echo "${ECHO_T}$RANLIB" >&6
4006else
c0d27fcc 4007 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4008echo "${ECHO_T}no" >&6
4009fi
4010
4011fi
4012if test -z "$ac_cv_prog_RANLIB"; then
4013 ac_ct_RANLIB=$RANLIB
4014 # Extract the first word of "ranlib", so it can be a program name with args.
4015set dummy ranlib; ac_word=$2
c0d27fcc 4016echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
4017echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4018if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4019 echo $ECHO_N "(cached) $ECHO_C" >&6
4020else
4021 if test -n "$ac_ct_RANLIB"; then
4022 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4023else
c0d27fcc
MR
4024as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4025for as_dir in $PATH
4026do
4027 IFS=$as_save_IFS
4028 test -z "$as_dir" && as_dir=.
4029 for ac_exec_ext in '' $ac_executable_extensions; do
4030 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4031 ac_cv_prog_ac_ct_RANLIB="ranlib"
4032 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4033 break 2
4034 fi
4035done
503d2be0
AS
4036done
4037
4038 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4039fi
4040fi
4041ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4042if test -n "$ac_ct_RANLIB"; then
c0d27fcc 4043 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
4044echo "${ECHO_T}$ac_ct_RANLIB" >&6
4045else
c0d27fcc 4046 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
4047echo "${ECHO_T}no" >&6
4048fi
4049
4050 RANLIB=$ac_ct_RANLIB
7397acc4 4051else
503d2be0 4052 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
4053fi
4054
4055fi
9e71690e
DK
4056# Extract the first word of "install-info", so it can be a program name with args.
4057set dummy install-info; ac_word=$2
4058echo "$as_me:$LINENO: checking for $ac_word" >&5
4059echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4060if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4061 echo $ECHO_N "(cached) $ECHO_C" >&6
4062else
4063 case $INSTALL_INFO in
4064 [\\/]* | ?:[\\/]*)
4065 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4066 ;;
4067 *)
4068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4069for as_dir in $PATH
4070do
4071 IFS=$as_save_IFS
4072 test -z "$as_dir" && as_dir=.
4073 for ac_exec_ext in '' $ac_executable_extensions; do
4074 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4075 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4076 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4077 break 2
4078 fi
4079done
4080done
4081
4082 ;;
4083esac
4084fi
4085INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4086
4087if test -n "$INSTALL_INFO"; then
4088 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4089echo "${ECHO_T}$INSTALL_INFO" >&6
4090else
4091 echo "$as_me:$LINENO: result: no" >&5
4092echo "${ECHO_T}no" >&6
4093fi
4094
4095# Extract the first word of "install-info", so it can be a program name with args.
4096set dummy install-info; ac_word=$2
4097echo "$as_me:$LINENO: checking for $ac_word" >&5
4098echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4099if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4100 echo $ECHO_N "(cached) $ECHO_C" >&6
4101else
4102 case $INSTALL_INFO in
4103 [\\/]* | ?:[\\/]*)
4104 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4105 ;;
4106 *)
4107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4108for as_dir in /usr/sbin
4109do
4110 IFS=$as_save_IFS
4111 test -z "$as_dir" && as_dir=.
4112 for ac_exec_ext in '' $ac_executable_extensions; do
4113 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4114 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4115 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4116 break 2
4117 fi
4118done
4119done
4120
4121 ;;
4122esac
4123fi
4124INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4125
4126if test -n "$INSTALL_INFO"; then
4127 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4128echo "${ECHO_T}$INSTALL_INFO" >&6
4129else
4130 echo "$as_me:$LINENO: result: no" >&5
4131echo "${ECHO_T}no" >&6
4132fi
4133
4134# Extract the first word of "install-info", so it can be a program name with args.
4135set dummy install-info; ac_word=$2
4136echo "$as_me:$LINENO: checking for $ac_word" >&5
4137echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4138if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4139 echo $ECHO_N "(cached) $ECHO_C" >&6
4140else
4141 case $INSTALL_INFO in
4142 [\\/]* | ?:[\\/]*)
4143 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4144 ;;
4145 *)
4146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4147for as_dir in /sbin
4148do
4149 IFS=$as_save_IFS
4150 test -z "$as_dir" && as_dir=.
4151 for ac_exec_ext in '' $ac_executable_extensions; do
4152 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4153 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4154 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4155 break 2
4156 fi
4157done
4158done
4159
4160 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4161 ;;
4162esac
4163fi
4164INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4165
4166if test -n "$INSTALL_INFO"; then
4167 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4168echo "${ECHO_T}$INSTALL_INFO" >&6
4169else
4170 echo "$as_me:$LINENO: result: no" >&5
4171echo "${ECHO_T}no" >&6
4172fi
4173
ba4481b5 4174
c0d27fcc 4175
8e967cf7
MR
4176if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4177then
4178 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4179fi
4180
4181if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4182then
4183 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4184fi
4185
c0d27fcc 4186
fe239f0f 4187late_LDFLAGS=$LDFLAGS
4af002d6 4188if test "$GCC" = yes; then
fe239f0f
AS
4189 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
4190else
4191 LDFLAGS="$LDFLAGS -znocombreloc"
4192fi
4193
4194echo "$as_me:$LINENO: checking For -znocombreloc" >&5
4195echo $ECHO_N "checking For -znocombreloc... $ECHO_C" >&6
4196
4197cat >conftest.$ac_ext <<_ACEOF
4198main(){return 0;}
4199_ACEOF
4200rm -f conftest.$ac_objext conftest$ac_exeext
4201if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4202 (eval $ac_link) 2>conftest.er1
4203 ac_status=$?
4204 grep -v '^ *+' conftest.er1 >conftest.err
4205 rm -f conftest.er1
4206 cat conftest.err >&5
4207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4208 (exit $ac_status); } &&
4494a266
JD
4209 { ac_try='test -z "$ac_c_werror_flag"
4210 || test ! -s conftest.err'
fe239f0f
AS
4211 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4212 (eval $ac_try) 2>&5
4213 ac_status=$?
4214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4215 (exit $ac_status); }; } &&
4216 { ac_try='test -s conftest$ac_exeext'
4217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4218 (eval $ac_try) 2>&5
4219 ac_status=$?
4220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4221 (exit $ac_status); }; }; then
4222 echo "$as_me:$LINENO: result: yes" >&5
4223echo "${ECHO_T}yes" >&6
4224else
4225 echo "$as_me: failed program was:" >&5
4226sed 's/^/| /' conftest.$ac_ext >&5
4227
4228LDFLAGS=$late_LDFLAGS
4229 echo "$as_me:$LINENO: result: no" >&5
4230echo "${ECHO_T}no" >&6
4231fi
4232rm -f conftest.err conftest.$ac_objext \
4233 conftest$ac_exeext conftest.$ac_ext
4234
c0d27fcc 4235
6bae0ccf
DL
4236echo "$as_me:$LINENO: checking for egrep" >&5
4237echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4238if test "${ac_cv_prog_egrep+set}" = set; then
4239 echo $ECHO_N "(cached) $ECHO_C" >&6
4240else
4241 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4242 then ac_cv_prog_egrep='grep -E'
4243 else ac_cv_prog_egrep='egrep'
4244 fi
4245fi
4246echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4247echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4248 EGREP=$ac_cv_prog_egrep
4249
4250
c0d27fcc
MR
4251
4252echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4253echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4254cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4255/* confdefs.h. */
4256_ACEOF
4257cat confdefs.h >>conftest.$ac_ext
4258cat >>conftest.$ac_ext <<_ACEOF
4259/* end confdefs.h. */
ba4481b5
DL
4260#ifdef _AIX
4261 yes
4262#endif
4263
503d2be0 4264_ACEOF
ba4481b5 4265if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4266 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4267 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4268echo "${ECHO_T}yes" >&6
c0d27fcc 4269cat >>confdefs.h <<\_ACEOF
ba4481b5 4270#define _ALL_SOURCE 1
c0d27fcc 4271_ACEOF
ba4481b5
DL
4272
4273else
c0d27fcc 4274 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4275echo "${ECHO_T}no" >&6
ba4481b5
DL
4276fi
4277rm -f conftest*
4278
c0d27fcc
MR
4279
4280
4489ece2 4281
3b33a005
DL
4282#### Extract some information from the operating system and machine files.
4283
c0d27fcc 4284{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4285 - which libraries the lib-src programs will want, and
503d2be0
AS
4286 - whether the GNU malloc routines are usable..." >&5
4287echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4288 - which libraries the lib-src programs will want, and
503d2be0 4289 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4290
4291### First figure out CFLAGS (which we use for running the compiler here)
4292### and REAL_CFLAGS (which we use for real compilation).
4293### The two are the same except on a few systems, where they are made
4294### different to work around various lossages. For example,
4295### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4296### as implying static linking.
4297
4298### If the CFLAGS env var is specified, we use that value
4299### instead of the default.
4300
4301### It's not important that this name contain the PID; you can't run
4302### two configures in the same directory and have anything work
4303### anyway.
4304tempcname="conftest.c"
4305
4306echo '
4307#include "'${srcdir}'/src/'${opsysfile}'"
4308#include "'${srcdir}'/src/'${machfile}'"
4309#ifndef LIBS_MACHINE
4310#define LIBS_MACHINE
4311#endif
4312#ifndef LIBS_SYSTEM
4313#define LIBS_SYSTEM
4314#endif
4315#ifndef C_SWITCH_SYSTEM
4316#define C_SWITCH_SYSTEM
4317#endif
4318#ifndef C_SWITCH_MACHINE
4319#define C_SWITCH_MACHINE
4320#endif
4321configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4322configure___ c_switch_system=C_SWITCH_SYSTEM
4323configure___ c_switch_machine=C_SWITCH_MACHINE
4324
4325#ifndef LIB_X11_LIB
4326#define LIB_X11_LIB -lX11
4327#endif
4328
4329#ifndef LIBX11_MACHINE
4330#define LIBX11_MACHINE
4331#endif
4332
4333#ifndef LIBX11_SYSTEM
4334#define LIBX11_SYSTEM
4335#endif
4336configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4337
4338#ifdef UNEXEC
4339configure___ unexec=UNEXEC
4340#else
4341configure___ unexec=unexec.o
4342#endif
4343
4344#ifdef SYSTEM_MALLOC
4345configure___ system_malloc=yes
4346#else
4347configure___ system_malloc=no
4348#endif
4349
ef9e4345
GM
4350#ifdef USE_MMAP_FOR_BUFFERS
4351configure___ use_mmap_for_buffers=yes
73b77ee5 4352#else
ef9e4345 4353configure___ use_mmap_for_buffers=no
73b77ee5
GM
4354#endif
4355
3b33a005
DL
4356#ifndef C_DEBUG_SWITCH
4357#define C_DEBUG_SWITCH -g
4358#endif
4359
4360#ifndef C_OPTIMIZE_SWITCH
4361#ifdef __GNUC__
4362#define C_OPTIMIZE_SWITCH -O2
4363#else
4364#define C_OPTIMIZE_SWITCH -O
4365#endif
4366#endif
4367
4368#ifndef LD_SWITCH_MACHINE
4369#define LD_SWITCH_MACHINE
4370#endif
4371
4372#ifndef LD_SWITCH_SYSTEM
4373#define LD_SWITCH_SYSTEM
4374#endif
4375
4376#ifndef LD_SWITCH_X_SITE_AUX
4377#define LD_SWITCH_X_SITE_AUX
503d2be0 4378#endif
3b33a005
DL
4379
4380configure___ ld_switch_system=LD_SWITCH_SYSTEM
4381configure___ ld_switch_machine=LD_SWITCH_MACHINE
4382
4383#ifdef THIS_IS_CONFIGURE
4384
4385/* Get the CFLAGS for tests in configure. */
4386#ifdef __GNUC__
4387configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4388#else
4389configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4390#endif
4391
4392#else /* not THIS_IS_CONFIGURE */
4393
4394/* Get the CFLAGS for real compilation. */
4395#ifdef __GNUC__
4396configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4397#else
4398configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4399#endif
4400
4401#endif /* not THIS_IS_CONFIGURE */
4402' > ${tempcname}
4403
4404# The value of CPP is a quoted variable reference, so we need to do this
4405# to get its actual value...
4406CPP=`eval "echo $CPP"`
4407eval `${CPP} -Isrc ${tempcname} \
4408 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4409if test "x$SPECIFIED_CFLAGS" = x; then
4410 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4411 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4412else
4413 REAL_CFLAGS="$CFLAGS"
4414fi
4415rm ${tempcname}
4416
4417ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4418
4419### Make sure subsequent tests use flags consistent with the build flags.
4420
4421if test x"${OVERRIDE_CPPFLAGS}" != x; then
4422 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4423else
4424 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4425fi
4426
6bae0ccf
DL
4427
4428
22044edf
DL
4429
4430cat >>confdefs.h <<\_ACEOF
4431#define _GNU_SOURCE 1
4432_ACEOF
4433
4434
4435
503d2be0 4436# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4437if test "${enable_largefile+set}" = set; then
4438 enableval="$enable_largefile"
f4988be7 4439
503d2be0
AS
4440fi;
4441if test "$enable_largefile" != no; then
f4988be7 4442
c0d27fcc 4443 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4444echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4445if test "${ac_cv_sys_largefile_CC+set}" = set; then
4446 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4447else
f4988be7 4448 ac_cv_sys_largefile_CC=no
503d2be0
AS
4449 if test "$GCC" != yes; then
4450 ac_save_CC=$CC
4451 while :; do
4452 # IRIX 6.2 and later do not support large files by default,
4453 # so use the C compiler's -n32 option if that helps.
35996d22 4454 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4455/* confdefs.h. */
4456_ACEOF
4457cat confdefs.h >>conftest.$ac_ext
4458cat >>conftest.$ac_ext <<_ACEOF
4459/* end confdefs.h. */
f4988be7 4460#include <sys/types.h>
503d2be0
AS
4461 /* Check that off_t can represent 2**63 - 1 correctly.
4462 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4463 since some C++ compilers masquerading as C compilers
4464 incorrectly reject 9223372036854775807. */
4465#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4466 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4467 && LARGE_OFF_T % 2147483647 == 1)
4468 ? 1 : -1];
4469int
4470main ()
4471{
f4988be7 4472
503d2be0
AS
4473 ;
4474 return 0;
4475}
4476_ACEOF
4477 rm -f conftest.$ac_objext
c0d27fcc 4478if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4479 (eval $ac_compile) 2>conftest.er1
503d2be0 4480 ac_status=$?
35996d22
AS
4481 grep -v '^ *+' conftest.er1 >conftest.err
4482 rm -f conftest.er1
4483 cat conftest.err >&5
c0d27fcc 4484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4485 (exit $ac_status); } &&
4494a266
JD
4486 { ac_try='test -z "$ac_c_werror_flag"
4487 || test ! -s conftest.err'
35996d22
AS
4488 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4489 (eval $ac_try) 2>&5
4490 ac_status=$?
4491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4492 (exit $ac_status); }; } &&
4493 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4494 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4495 (eval $ac_try) 2>&5
4496 ac_status=$?
c0d27fcc 4497 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4498 (exit $ac_status); }; }; then
4499 break
b192d653 4500else
503d2be0 4501 echo "$as_me: failed program was:" >&5
19650fd6
AS
4502sed 's/^/| /' conftest.$ac_ext >&5
4503
503d2be0 4504fi
35996d22 4505rm -f conftest.err conftest.$ac_objext
503d2be0
AS
4506 CC="$CC -n32"
4507 rm -f conftest.$ac_objext
c0d27fcc 4508if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4509 (eval $ac_compile) 2>conftest.er1
503d2be0 4510 ac_status=$?
35996d22
AS
4511 grep -v '^ *+' conftest.er1 >conftest.err
4512 rm -f conftest.er1
4513 cat conftest.err >&5
c0d27fcc 4514 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4515 (exit $ac_status); } &&
4494a266
JD
4516 { ac_try='test -z "$ac_c_werror_flag"
4517 || test ! -s conftest.err'
35996d22
AS
4518 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4519 (eval $ac_try) 2>&5
4520 ac_status=$?
4521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4522 (exit $ac_status); }; } &&
4523 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4524 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4525 (eval $ac_try) 2>&5
4526 ac_status=$?
c0d27fcc 4527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4528 (exit $ac_status); }; }; then
4529 ac_cv_sys_largefile_CC=' -n32'; break
4530else
4531 echo "$as_me: failed program was:" >&5
19650fd6
AS
4532sed 's/^/| /' conftest.$ac_ext >&5
4533
503d2be0 4534fi
35996d22
AS
4535rm -f conftest.err conftest.$ac_objext
4536 break
503d2be0
AS
4537 done
4538 CC=$ac_save_CC
4539 rm -f conftest.$ac_ext
4540 fi
b192d653 4541fi
c0d27fcc 4542echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4543echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4544 if test "$ac_cv_sys_largefile_CC" != no; then
4545 CC=$CC$ac_cv_sys_largefile_CC
4546 fi
b192d653 4547
c0d27fcc 4548 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4549echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4550if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4551 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4552else
503d2be0 4553 while :; do
f4988be7 4554 ac_cv_sys_file_offset_bits=no
503d2be0 4555 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4556/* confdefs.h. */
4557_ACEOF
4558cat confdefs.h >>conftest.$ac_ext
4559cat >>conftest.$ac_ext <<_ACEOF
4560/* end confdefs.h. */
f4988be7 4561#include <sys/types.h>
503d2be0
AS
4562 /* Check that off_t can represent 2**63 - 1 correctly.
4563 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4564 since some C++ compilers masquerading as C compilers
4565 incorrectly reject 9223372036854775807. */
4566#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4567 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4568 && LARGE_OFF_T % 2147483647 == 1)
4569 ? 1 : -1];
4570int
4571main ()
4572{
f4988be7 4573
503d2be0
AS
4574 ;
4575 return 0;
4576}
4577_ACEOF
4578rm -f conftest.$ac_objext
c0d27fcc 4579if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4580 (eval $ac_compile) 2>conftest.er1
503d2be0 4581 ac_status=$?
35996d22
AS
4582 grep -v '^ *+' conftest.er1 >conftest.err
4583 rm -f conftest.er1
4584 cat conftest.err >&5
c0d27fcc 4585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4586 (exit $ac_status); } &&
4494a266
JD
4587 { ac_try='test -z "$ac_c_werror_flag"
4588 || test ! -s conftest.err'
35996d22
AS
4589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4590 (eval $ac_try) 2>&5
4591 ac_status=$?
4592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4593 (exit $ac_status); }; } &&
4594 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4596 (eval $ac_try) 2>&5
4597 ac_status=$?
c0d27fcc 4598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4599 (exit $ac_status); }; }; then
4600 break
f4988be7 4601else
503d2be0 4602 echo "$as_me: failed program was:" >&5
19650fd6
AS
4603sed 's/^/| /' conftest.$ac_ext >&5
4604
503d2be0 4605fi
35996d22 4606rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4607 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4608/* confdefs.h. */
4609_ACEOF
4610cat confdefs.h >>conftest.$ac_ext
4611cat >>conftest.$ac_ext <<_ACEOF
4612/* end confdefs.h. */
f4988be7
GM
4613#define _FILE_OFFSET_BITS 64
4614#include <sys/types.h>
503d2be0
AS
4615 /* Check that off_t can represent 2**63 - 1 correctly.
4616 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4617 since some C++ compilers masquerading as C compilers
4618 incorrectly reject 9223372036854775807. */
4619#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4620 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4621 && LARGE_OFF_T % 2147483647 == 1)
4622 ? 1 : -1];
4623int
4624main ()
4625{
4626
4627 ;
4628 return 0;
4629}
4630_ACEOF
4631rm -f conftest.$ac_objext
c0d27fcc 4632if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4633 (eval $ac_compile) 2>conftest.er1
503d2be0 4634 ac_status=$?
35996d22
AS
4635 grep -v '^ *+' conftest.er1 >conftest.err
4636 rm -f conftest.er1
4637 cat conftest.err >&5
c0d27fcc 4638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4639 (exit $ac_status); } &&
4494a266
JD
4640 { ac_try='test -z "$ac_c_werror_flag"
4641 || test ! -s conftest.err'
35996d22
AS
4642 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4643 (eval $ac_try) 2>&5
4644 ac_status=$?
4645 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4646 (exit $ac_status); }; } &&
4647 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4648 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4649 (eval $ac_try) 2>&5
4650 ac_status=$?
c0d27fcc 4651 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4652 (exit $ac_status); }; }; then
4653 ac_cv_sys_file_offset_bits=64; break
4654else
4655 echo "$as_me: failed program was:" >&5
19650fd6
AS
4656sed 's/^/| /' conftest.$ac_ext >&5
4657
503d2be0 4658fi
35996d22 4659rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4660 break
4661done
ba4481b5 4662fi
c0d27fcc 4663echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4664echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4665if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4666
c0d27fcc 4667cat >>confdefs.h <<_ACEOF
f4988be7 4668#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4669_ACEOF
f4988be7 4670
503d2be0
AS
4671fi
4672rm -f conftest*
c0d27fcc 4673 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4674echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4675if test "${ac_cv_sys_large_files+set}" = set; then
4676 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4677else
503d2be0 4678 while :; do
f4988be7 4679 ac_cv_sys_large_files=no
503d2be0 4680 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4681/* confdefs.h. */
4682_ACEOF
4683cat confdefs.h >>conftest.$ac_ext
4684cat >>conftest.$ac_ext <<_ACEOF
4685/* end confdefs.h. */
503d2be0
AS
4686#include <sys/types.h>
4687 /* Check that off_t can represent 2**63 - 1 correctly.
4688 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4689 since some C++ compilers masquerading as C compilers
4690 incorrectly reject 9223372036854775807. */
4691#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4692 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4693 && LARGE_OFF_T % 2147483647 == 1)
4694 ? 1 : -1];
4695int
4696main ()
4697{
ba4481b5 4698
503d2be0
AS
4699 ;
4700 return 0;
4701}
4702_ACEOF
4703rm -f conftest.$ac_objext
c0d27fcc 4704if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4705 (eval $ac_compile) 2>conftest.er1
503d2be0 4706 ac_status=$?
35996d22
AS
4707 grep -v '^ *+' conftest.er1 >conftest.err
4708 rm -f conftest.er1
4709 cat conftest.err >&5
c0d27fcc 4710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4711 (exit $ac_status); } &&
4494a266
JD
4712 { ac_try='test -z "$ac_c_werror_flag"
4713 || test ! -s conftest.err'
35996d22
AS
4714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4715 (eval $ac_try) 2>&5
4716 ac_status=$?
4717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4718 (exit $ac_status); }; } &&
4719 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4720 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4721 (eval $ac_try) 2>&5
4722 ac_status=$?
c0d27fcc 4723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4724 (exit $ac_status); }; }; then
4725 break
ba4481b5 4726else
503d2be0 4727 echo "$as_me: failed program was:" >&5
19650fd6
AS
4728sed 's/^/| /' conftest.$ac_ext >&5
4729
503d2be0 4730fi
35996d22 4731rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 4732 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4733/* confdefs.h. */
4734_ACEOF
4735cat confdefs.h >>conftest.$ac_ext
4736cat >>conftest.$ac_ext <<_ACEOF
4737/* end confdefs.h. */
f4988be7 4738#define _LARGE_FILES 1
503d2be0
AS
4739#include <sys/types.h>
4740 /* Check that off_t can represent 2**63 - 1 correctly.
4741 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4742 since some C++ compilers masquerading as C compilers
4743 incorrectly reject 9223372036854775807. */
4744#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4745 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4746 && LARGE_OFF_T % 2147483647 == 1)
4747 ? 1 : -1];
4748int
4749main ()
4750{
f4988be7 4751
503d2be0
AS
4752 ;
4753 return 0;
4754}
4755_ACEOF
4756rm -f conftest.$ac_objext
c0d27fcc 4757if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4758 (eval $ac_compile) 2>conftest.er1
503d2be0 4759 ac_status=$?
35996d22
AS
4760 grep -v '^ *+' conftest.er1 >conftest.err
4761 rm -f conftest.er1
4762 cat conftest.err >&5
c0d27fcc 4763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4764 (exit $ac_status); } &&
4494a266
JD
4765 { ac_try='test -z "$ac_c_werror_flag"
4766 || test ! -s conftest.err'
35996d22
AS
4767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4768 (eval $ac_try) 2>&5
4769 ac_status=$?
4770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4771 (exit $ac_status); }; } &&
4772 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4774 (eval $ac_try) 2>&5
4775 ac_status=$?
c0d27fcc 4776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4777 (exit $ac_status); }; }; then
4778 ac_cv_sys_large_files=1; break
4779else
4780 echo "$as_me: failed program was:" >&5
19650fd6
AS
4781sed 's/^/| /' conftest.$ac_ext >&5
4782
503d2be0 4783fi
35996d22 4784rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4785 break
4786done
ba4481b5 4787fi
c0d27fcc 4788echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4789echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4790if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4791
c0d27fcc 4792cat >>confdefs.h <<_ACEOF
f4988be7 4793#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4794_ACEOF
ba4481b5 4795
503d2be0
AS
4796fi
4797rm -f conftest*
4798fi
ba4481b5 4799
c0d27fcc 4800
2c9dccc9
PJ
4801if test "${with_sound}" != "no"; then
4802 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4803 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4804echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4805if test "${ac_cv_header_stdc+set}" = set; then
4806 echo $ECHO_N "(cached) $ECHO_C" >&6
4807else
4808 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4809/* confdefs.h. */
4810_ACEOF
4811cat confdefs.h >>conftest.$ac_ext
4812cat >>conftest.$ac_ext <<_ACEOF
4813/* end confdefs.h. */
c0d27fcc
MR
4814#include <stdlib.h>
4815#include <stdarg.h>
4816#include <string.h>
4817#include <float.h>
98418dba 4818
19650fd6
AS
4819int
4820main ()
4821{
4822
4823 ;
4824 return 0;
4825}
c0d27fcc 4826_ACEOF
19650fd6
AS
4827rm -f conftest.$ac_objext
4828if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 4829 (eval $ac_compile) 2>conftest.er1
cd958eb3 4830 ac_status=$?
35996d22
AS
4831 grep -v '^ *+' conftest.er1 >conftest.err
4832 rm -f conftest.er1
4833 cat conftest.err >&5
cd958eb3 4834 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 4835 (exit $ac_status); } &&
4494a266
JD
4836 { ac_try='test -z "$ac_c_werror_flag"
4837 || test ! -s conftest.err'
35996d22
AS
4838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4839 (eval $ac_try) 2>&5
4840 ac_status=$?
4841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4842 (exit $ac_status); }; } &&
4843 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
4844 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4845 (eval $ac_try) 2>&5
4846 ac_status=$?
4847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4848 (exit $ac_status); }; }; then
c0d27fcc
MR
4849 ac_cv_header_stdc=yes
4850else
4851 echo "$as_me: failed program was:" >&5
19650fd6
AS
4852sed 's/^/| /' conftest.$ac_ext >&5
4853
4854ac_cv_header_stdc=no
c0d27fcc 4855fi
35996d22 4856rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4857
4858if test $ac_cv_header_stdc = yes; then
4859 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4860 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4861/* confdefs.h. */
4862_ACEOF
4863cat confdefs.h >>conftest.$ac_ext
4864cat >>conftest.$ac_ext <<_ACEOF
4865/* end confdefs.h. */
c0d27fcc
MR
4866#include <string.h>
4867
4868_ACEOF
4869if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4870 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4871 :
4872else
4873 ac_cv_header_stdc=no
4874fi
4875rm -f conftest*
4876
4877fi
4878
4879if test $ac_cv_header_stdc = yes; then
4880 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4881 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4882/* confdefs.h. */
4883_ACEOF
4884cat confdefs.h >>conftest.$ac_ext
4885cat >>conftest.$ac_ext <<_ACEOF
4886/* end confdefs.h. */
c0d27fcc
MR
4887#include <stdlib.h>
4888
4889_ACEOF
4890if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4891 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4892 :
4893else
4894 ac_cv_header_stdc=no
4895fi
4896rm -f conftest*
4897
4898fi
4899
4900if test $ac_cv_header_stdc = yes; then
4901 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4902 if test "$cross_compiling" = yes; then
4903 :
4904else
4905 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4906/* confdefs.h. */
4907_ACEOF
4908cat confdefs.h >>conftest.$ac_ext
4909cat >>conftest.$ac_ext <<_ACEOF
4910/* end confdefs.h. */
c0d27fcc
MR
4911#include <ctype.h>
4912#if ((' ' & 0x0FF) == 0x020)
4913# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4914# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4915#else
19650fd6 4916# define ISLOWER(c) \
35996d22
AS
4917 (('a' <= (c) && (c) <= 'i') \
4918 || ('j' <= (c) && (c) <= 'r') \
4919 || ('s' <= (c) && (c) <= 'z'))
c0d27fcc
MR
4920# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4921#endif
4922
4923#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4924int
4925main ()
4926{
4927 int i;
4928 for (i = 0; i < 256; i++)
4929 if (XOR (islower (i), ISLOWER (i))
35996d22 4930 || toupper (i) != TOUPPER (i))
c0d27fcc
MR
4931 exit(2);
4932 exit (0);
4933}
4934_ACEOF
4935rm -f conftest$ac_exeext
4936if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4937 (eval $ac_link) 2>&5
4938 ac_status=$?
4939 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4940 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4941 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4942 (eval $ac_try) 2>&5
4943 ac_status=$?
4944 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4945 (exit $ac_status); }; }; then
4946 :
4947else
4948 echo "$as_me: program exited with status $ac_status" >&5
4949echo "$as_me: failed program was:" >&5
19650fd6
AS
4950sed 's/^/| /' conftest.$ac_ext >&5
4951
c0d27fcc
MR
4952( exit $ac_status )
4953ac_cv_header_stdc=no
4954fi
35996d22 4955rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4956fi
4957fi
4958fi
4959echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4960echo "${ECHO_T}$ac_cv_header_stdc" >&6
4961if test $ac_cv_header_stdc = yes; then
4962
4963cat >>confdefs.h <<\_ACEOF
4964#define STDC_HEADERS 1
4965_ACEOF
4966
4967fi
4968
4969# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
35996d22 4980 inttypes.h stdint.h unistd.h
98418dba
CW
4981do
4982as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4983echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4984echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4985if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4986 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4987else
925c2f3f 4988 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
4989/* confdefs.h. */
4990_ACEOF
4991cat confdefs.h >>conftest.$ac_ext
4992cat >>conftest.$ac_ext <<_ACEOF
4993/* end confdefs.h. */
c0d27fcc
MR
4994$ac_includes_default
4995
4996#include <$ac_header>
4997_ACEOF
4998rm -f conftest.$ac_objext
4999if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5000 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5001 ac_status=$?
35996d22
AS
5002 grep -v '^ *+' conftest.er1 >conftest.err
5003 rm -f conftest.er1
5004 cat conftest.err >&5
c0d27fcc
MR
5005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5006 (exit $ac_status); } &&
4494a266
JD
5007 { ac_try='test -z "$ac_c_werror_flag"
5008 || test ! -s conftest.err'
35996d22
AS
5009 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5010 (eval $ac_try) 2>&5
5011 ac_status=$?
5012 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5013 (exit $ac_status); }; } &&
5014 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5015 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5016 (eval $ac_try) 2>&5
5017 ac_status=$?
5018 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5019 (exit $ac_status); }; }; then
5020 eval "$as_ac_Header=yes"
5021else
5022 echo "$as_me: failed program was:" >&5
19650fd6
AS
5023sed 's/^/| /' conftest.$ac_ext >&5
5024
c0d27fcc
MR
5025eval "$as_ac_Header=no"
5026fi
35996d22 5027rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5028fi
5029echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5030echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5031if test `eval echo '${'$as_ac_Header'}'` = yes; then
5032 cat >>confdefs.h <<_ACEOF
5033#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5034_ACEOF
5035
5036fi
5037
5038done
5039
5040
5041
5042
5043
5044for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
5045do
5046as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5047if eval "test \"\${$as_ac_Header+set}\" = set"; then
5048 echo "$as_me:$LINENO: checking for $ac_header" >&5
5049echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5050if eval "test \"\${$as_ac_Header+set}\" = set"; then
5051 echo $ECHO_N "(cached) $ECHO_C" >&6
5052fi
5053echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5054echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5055else
5056 # Is the header compilable?
5057echo "$as_me:$LINENO: checking $ac_header usability" >&5
5058echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5059cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5060/* confdefs.h. */
5061_ACEOF
5062cat confdefs.h >>conftest.$ac_ext
5063cat >>conftest.$ac_ext <<_ACEOF
5064/* end confdefs.h. */
c0d27fcc 5065$ac_includes_default
98418dba 5066#include <$ac_header>
503d2be0 5067_ACEOF
c0d27fcc
MR
5068rm -f conftest.$ac_objext
5069if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5070 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5071 ac_status=$?
35996d22
AS
5072 grep -v '^ *+' conftest.er1 >conftest.err
5073 rm -f conftest.er1
5074 cat conftest.err >&5
c0d27fcc
MR
5075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5076 (exit $ac_status); } &&
4494a266
JD
5077 { ac_try='test -z "$ac_c_werror_flag"
5078 || test ! -s conftest.err'
35996d22
AS
5079 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5080 (eval $ac_try) 2>&5
5081 ac_status=$?
5082 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5083 (exit $ac_status); }; } &&
5084 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5085 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5086 (eval $ac_try) 2>&5
5087 ac_status=$?
5088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5089 (exit $ac_status); }; }; then
5090 ac_header_compiler=yes
5091else
5092 echo "$as_me: failed program was:" >&5
19650fd6
AS
5093sed 's/^/| /' conftest.$ac_ext >&5
5094
c0d27fcc
MR
5095ac_header_compiler=no
5096fi
35996d22 5097rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5098echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5099echo "${ECHO_T}$ac_header_compiler" >&6
5100
5101# Is the header present?
5102echo "$as_me:$LINENO: checking $ac_header presence" >&5
5103echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5104cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5105/* confdefs.h. */
5106_ACEOF
5107cat confdefs.h >>conftest.$ac_ext
5108cat >>conftest.$ac_ext <<_ACEOF
5109/* end confdefs.h. */
c0d27fcc
MR
5110#include <$ac_header>
5111_ACEOF
5112if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5113 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5114 ac_status=$?
6bae0ccf 5115 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5116 rm -f conftest.er1
5117 cat conftest.err >&5
c0d27fcc 5118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5119 (exit $ac_status); } >/dev/null; then
5120 if test -s conftest.err; then
5121 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5122 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5123 else
5124 ac_cpp_err=
5125 fi
5126else
5127 ac_cpp_err=yes
5128fi
5129if test -z "$ac_cpp_err"; then
c0d27fcc 5130 ac_header_preproc=yes
f4988be7 5131else
503d2be0 5132 echo "$as_me: failed program was:" >&5
19650fd6
AS
5133sed 's/^/| /' conftest.$ac_ext >&5
5134
c0d27fcc 5135 ac_header_preproc=no
f4988be7 5136fi
98418dba 5137rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5138echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5139echo "${ECHO_T}$ac_header_preproc" >&6
5140
5141# So? What about this header?
35996d22
AS
5142case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5143 yes:no: )
c0d27fcc
MR
5144 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5145echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5146 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5147echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5148 ac_header_preproc=yes
19650fd6 5149 ;;
35996d22 5150 no:yes:* )
c0d27fcc
MR
5151 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5152echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5153 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5154echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5155 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5156echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5157 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5158echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5159 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5160echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5161 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5162echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5163 (
5164 cat <<\_ASBOX
35996d22
AS
5165## ------------------------------------------ ##
5166## Report this to the AC_PACKAGE_NAME lists. ##
5167## ------------------------------------------ ##
19650fd6
AS
5168_ASBOX
5169 ) |
5170 sed "s/^/$as_me: WARNING: /" >&2
5171 ;;
c0d27fcc
MR
5172esac
5173echo "$as_me:$LINENO: checking for $ac_header" >&5
5174echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5175if eval "test \"\${$as_ac_Header+set}\" = set"; then
5176 echo $ECHO_N "(cached) $ECHO_C" >&6
5177else
35996d22 5178 eval "$as_ac_Header=\$ac_header_preproc"
f4988be7 5179fi
c0d27fcc 5180echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5181echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5182
5183fi
98418dba 5184if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5185 cat >>confdefs.h <<_ACEOF
98418dba 5186#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5187_ACEOF
f4988be7
GM
5188
5189fi
c0d27fcc 5190
98418dba
CW
5191done
5192
5193 # Emulation library used on NetBSD.
c0d27fcc 5194 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
5195echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
5196if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 5197 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5198else
98418dba
CW
5199 ac_check_lib_save_LIBS=$LIBS
5200LIBS="-lossaudio $LIBS"
5201cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5202/* confdefs.h. */
5203_ACEOF
5204cat confdefs.h >>conftest.$ac_ext
5205cat >>conftest.$ac_ext <<_ACEOF
5206/* end confdefs.h. */
98418dba
CW
5207
5208/* Override any gcc2 internal prototype to avoid an error. */
5209#ifdef __cplusplus
5210extern "C"
f4988be7 5211#endif
98418dba
CW
5212/* We use char because int might match the return type of a gcc2
5213 builtin and then its argument prototype would still apply. */
5214char _oss_ioctl ();
503d2be0
AS
5215int
5216main ()
5217{
98418dba 5218_oss_ioctl ();
503d2be0
AS
5219 ;
5220 return 0;
5221}
5222_ACEOF
98418dba 5223rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 5224if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 5225 (eval $ac_link) 2>conftest.er1
503d2be0 5226 ac_status=$?
35996d22
AS
5227 grep -v '^ *+' conftest.er1 >conftest.err
5228 rm -f conftest.er1
5229 cat conftest.err >&5
c0d27fcc 5230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5231 (exit $ac_status); } &&
4494a266
JD
5232 { ac_try='test -z "$ac_c_werror_flag"
5233 || test ! -s conftest.err'
35996d22
AS
5234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5235 (eval $ac_try) 2>&5
5236 ac_status=$?
5237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5238 (exit $ac_status); }; } &&
5239 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 5240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5241 (eval $ac_try) 2>&5
5242 ac_status=$?
c0d27fcc 5243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5244 (exit $ac_status); }; }; then
98418dba 5245 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 5246else
503d2be0 5247 echo "$as_me: failed program was:" >&5
19650fd6
AS
5248sed 's/^/| /' conftest.$ac_ext >&5
5249
98418dba 5250ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 5251fi
35996d22
AS
5252rm -f conftest.err conftest.$ac_objext \
5253 conftest$ac_exeext conftest.$ac_ext
98418dba 5254LIBS=$ac_check_lib_save_LIBS
f4988be7 5255fi
c0d27fcc 5256echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
5257echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5258if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5259 LIBSOUND=-lossaudio
5260else
5261 LIBSOUND=
5262fi
5263
c0d27fcc 5264
f4988be7 5265fi
c0d27fcc
MR
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
22044edf
DL
5284
5285
973a76b1 5286
cffcede7 5287
c0d27fcc 5288
f4988be7 5289
98418dba
CW
5290for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5291 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
25ca0bca 5292 termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
cffcede7 5293 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h
98418dba
CW
5294do
5295as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5296if eval "test \"\${$as_ac_Header+set}\" = set"; then
5297 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5298echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5299if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5300 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5301fi
5302echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5303echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5304else
c0d27fcc
MR
5305 # Is the header compilable?
5306echo "$as_me:$LINENO: checking $ac_header usability" >&5
5307echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5308cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5309/* confdefs.h. */
5310_ACEOF
5311cat confdefs.h >>conftest.$ac_ext
5312cat >>conftest.$ac_ext <<_ACEOF
5313/* end confdefs.h. */
c0d27fcc
MR
5314$ac_includes_default
5315#include <$ac_header>
5316_ACEOF
5317rm -f conftest.$ac_objext
5318if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5319 (eval $ac_compile) 2>conftest.er1
c0d27fcc 5320 ac_status=$?
35996d22
AS
5321 grep -v '^ *+' conftest.er1 >conftest.err
5322 rm -f conftest.er1
5323 cat conftest.err >&5
c0d27fcc
MR
5324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5325 (exit $ac_status); } &&
4494a266
JD
5326 { ac_try='test -z "$ac_c_werror_flag"
5327 || test ! -s conftest.err'
35996d22
AS
5328 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5329 (eval $ac_try) 2>&5
5330 ac_status=$?
5331 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5332 (exit $ac_status); }; } &&
5333 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5334 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5335 (eval $ac_try) 2>&5
5336 ac_status=$?
5337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5338 (exit $ac_status); }; }; then
5339 ac_header_compiler=yes
5340else
5341 echo "$as_me: failed program was:" >&5
19650fd6
AS
5342sed 's/^/| /' conftest.$ac_ext >&5
5343
c0d27fcc
MR
5344ac_header_compiler=no
5345fi
35996d22 5346rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5347echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5348echo "${ECHO_T}$ac_header_compiler" >&6
5349
5350# Is the header present?
5351echo "$as_me:$LINENO: checking $ac_header presence" >&5
5352echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5353cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5354/* confdefs.h. */
5355_ACEOF
5356cat confdefs.h >>conftest.$ac_ext
5357cat >>conftest.$ac_ext <<_ACEOF
5358/* end confdefs.h. */
98418dba 5359#include <$ac_header>
503d2be0 5360_ACEOF
c0d27fcc 5361if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5362 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5363 ac_status=$?
6bae0ccf 5364 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5365 rm -f conftest.er1
5366 cat conftest.err >&5
c0d27fcc 5367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5368 (exit $ac_status); } >/dev/null; then
5369 if test -s conftest.err; then
5370 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5371 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
5372 else
5373 ac_cpp_err=
5374 fi
5375else
5376 ac_cpp_err=yes
5377fi
5378if test -z "$ac_cpp_err"; then
c0d27fcc 5379 ac_header_preproc=yes
34ec9ebe 5380else
503d2be0 5381 echo "$as_me: failed program was:" >&5
19650fd6
AS
5382sed 's/^/| /' conftest.$ac_ext >&5
5383
c0d27fcc 5384 ac_header_preproc=no
34ec9ebe 5385fi
98418dba 5386rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5387echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5388echo "${ECHO_T}$ac_header_preproc" >&6
5389
5390# So? What about this header?
35996d22
AS
5391case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5392 yes:no: )
c0d27fcc
MR
5393 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5394echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
5395 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5396echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
5397 ac_header_preproc=yes
19650fd6 5398 ;;
35996d22 5399 no:yes:* )
c0d27fcc
MR
5400 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5401echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
5402 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5403echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5404 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5405echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5406 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5407echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 5408 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5409echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
5410 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5411echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
5412 (
5413 cat <<\_ASBOX
35996d22
AS
5414## ------------------------------------------ ##
5415## Report this to the AC_PACKAGE_NAME lists. ##
5416## ------------------------------------------ ##
19650fd6
AS
5417_ASBOX
5418 ) |
5419 sed "s/^/$as_me: WARNING: /" >&2
5420 ;;
c0d27fcc
MR
5421esac
5422echo "$as_me:$LINENO: checking for $ac_header" >&5
5423echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5424if eval "test \"\${$as_ac_Header+set}\" = set"; then
5425 echo $ECHO_N "(cached) $ECHO_C" >&6
5426else
35996d22 5427 eval "$as_ac_Header=\$ac_header_preproc"
34ec9ebe 5428fi
c0d27fcc 5429echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5430echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5431
5432fi
98418dba 5433if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5434 cat >>confdefs.h <<_ACEOF
98418dba 5435#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5436_ACEOF
34ec9ebe 5437
98418dba 5438fi
c0d27fcc 5439
98418dba
CW
5440done
5441
22044edf
DL
5442
5443for ac_header in term.h
5444do
5445as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5446echo "$as_me:$LINENO: checking for $ac_header" >&5
5447echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5448if eval "test \"\${$as_ac_Header+set}\" = set"; then
5449 echo $ECHO_N "(cached) $ECHO_C" >&6
5450else
5451 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5452/* confdefs.h. */
5453_ACEOF
5454cat confdefs.h >>conftest.$ac_ext
5455cat >>conftest.$ac_ext <<_ACEOF
5456/* end confdefs.h. */
22044edf
DL
5457#include <$ac_header>
5458_ACEOF
5459if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5460 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5461 ac_status=$?
5462 grep -v '^ *+' conftest.er1 >conftest.err
5463 rm -f conftest.er1
5464 cat conftest.err >&5
5465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5466 (exit $ac_status); } >/dev/null; then
5467 if test -s conftest.err; then
5468 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 5469 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22044edf
DL
5470 else
5471 ac_cpp_err=
5472 fi
5473else
5474 ac_cpp_err=yes
5475fi
5476if test -z "$ac_cpp_err"; then
5477 eval "$as_ac_Header=yes"
5478else
5479 echo "$as_me: failed program was:" >&5
19650fd6
AS
5480sed 's/^/| /' conftest.$ac_ext >&5
5481
22044edf
DL
5482 eval "$as_ac_Header=no"
5483fi
5484rm -f conftest.err conftest.$ac_ext
5485fi
5486echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5487echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5488if test `eval echo '${'$as_ac_Header'}'` = yes; then
5489 cat >>confdefs.h <<_ACEOF
5490#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5491_ACEOF
5492
5493fi
5494
5495done
5496
c0d27fcc 5497echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5498echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5499if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5500 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5501else
503d2be0 5502 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5503/* confdefs.h. */
5504_ACEOF
5505cat confdefs.h >>conftest.$ac_ext
5506cat >>conftest.$ac_ext <<_ACEOF
5507/* end confdefs.h. */
98418dba
CW
5508#include <stdlib.h>
5509#include <stdarg.h>
5510#include <string.h>
5511#include <float.h>
5512
19650fd6
AS
5513int
5514main ()
5515{
5516
5517 ;
5518 return 0;
5519}
98418dba 5520_ACEOF
19650fd6
AS
5521rm -f conftest.$ac_objext
5522if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5523 (eval $ac_compile) 2>conftest.er1
cd958eb3 5524 ac_status=$?
35996d22
AS
5525 grep -v '^ *+' conftest.er1 >conftest.err
5526 rm -f conftest.er1
5527 cat conftest.err >&5
cd958eb3 5528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 5529 (exit $ac_status); } &&
4494a266
JD
5530 { ac_try='test -z "$ac_c_werror_flag"
5531 || test ! -s conftest.err'
35996d22
AS
5532 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5533 (eval $ac_try) 2>&5
5534 ac_status=$?
5535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5536 (exit $ac_status); }; } &&
5537 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
5538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5539 (eval $ac_try) 2>&5
5540 ac_status=$?
5541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5542 (exit $ac_status); }; }; then
98418dba 5543 ac_cv_header_stdc=yes
ba4481b5 5544else
503d2be0 5545 echo "$as_me: failed program was:" >&5
19650fd6
AS
5546sed 's/^/| /' conftest.$ac_ext >&5
5547
5548ac_cv_header_stdc=no
ba4481b5 5549fi
35996d22 5550rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5551
5552if test $ac_cv_header_stdc = yes; then
5553 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5554 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5555/* confdefs.h. */
5556_ACEOF
5557cat confdefs.h >>conftest.$ac_ext
5558cat >>conftest.$ac_ext <<_ACEOF
5559/* end confdefs.h. */
98418dba
CW
5560#include <string.h>
5561
5562_ACEOF
5563if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5564 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5565 :
5566else
5567 ac_cv_header_stdc=no
ba4481b5 5568fi
98418dba 5569rm -f conftest*
ba4481b5
DL
5570
5571fi
5572
98418dba
CW
5573if test $ac_cv_header_stdc = yes; then
5574 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5575 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5576/* confdefs.h. */
5577_ACEOF
5578cat confdefs.h >>conftest.$ac_ext
5579cat >>conftest.$ac_ext <<_ACEOF
5580/* end confdefs.h. */
98418dba
CW
5581#include <stdlib.h>
5582
5583_ACEOF
5584if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5585 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5586 :
5587else
5588 ac_cv_header_stdc=no
5589fi
5590rm -f conftest*
5591
5592fi
5593
5594if test $ac_cv_header_stdc = yes; then
5595 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5596 if test "$cross_compiling" = yes; then
5597 :
d42122a3 5598else
503d2be0 5599 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5600/* confdefs.h. */
5601_ACEOF
5602cat confdefs.h >>conftest.$ac_ext
5603cat >>conftest.$ac_ext <<_ACEOF
5604/* end confdefs.h. */
98418dba
CW
5605#include <ctype.h>
5606#if ((' ' & 0x0FF) == 0x020)
5607# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5608# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5609#else
19650fd6 5610# define ISLOWER(c) \
35996d22
AS
5611 (('a' <= (c) && (c) <= 'i') \
5612 || ('j' <= (c) && (c) <= 'r') \
5613 || ('s' <= (c) && (c) <= 'z'))
98418dba
CW
5614# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5615#endif
5616
5617#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5618int
5619main ()
5620{
98418dba
CW
5621 int i;
5622 for (i = 0; i < 256; i++)
5623 if (XOR (islower (i), ISLOWER (i))
35996d22 5624 || toupper (i) != TOUPPER (i))
98418dba
CW
5625 exit(2);
5626 exit (0);
503d2be0
AS
5627}
5628_ACEOF
98418dba 5629rm -f conftest$ac_exeext
c0d27fcc 5630if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5631 (eval $ac_link) 2>&5
503d2be0 5632 ac_status=$?
c0d27fcc 5633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5634 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5635 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5636 (eval $ac_try) 2>&5
5637 ac_status=$?
c0d27fcc 5638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5639 (exit $ac_status); }; }; then
98418dba 5640 :
d42122a3 5641else
98418dba
CW
5642 echo "$as_me: program exited with status $ac_status" >&5
5643echo "$as_me: failed program was:" >&5
19650fd6
AS
5644sed 's/^/| /' conftest.$ac_ext >&5
5645
c0d27fcc 5646( exit $ac_status )
98418dba 5647ac_cv_header_stdc=no
d42122a3 5648fi
35996d22 5649rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5650fi
98418dba
CW
5651fi
5652fi
c0d27fcc 5653echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5654echo "${ECHO_T}$ac_cv_header_stdc" >&6
5655if test $ac_cv_header_stdc = yes; then
5656
c0d27fcc 5657cat >>confdefs.h <<\_ACEOF
98418dba 5658#define STDC_HEADERS 1
c0d27fcc 5659_ACEOF
d42122a3
DL
5660
5661fi
5662
c0d27fcc 5663echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5664echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5665if test "${ac_cv_header_time+set}" = set; then
503d2be0 5666 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5667else
503d2be0 5668 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5669/* confdefs.h. */
5670_ACEOF
5671cat confdefs.h >>conftest.$ac_ext
5672cat >>conftest.$ac_ext <<_ACEOF
5673/* end confdefs.h. */
ba4481b5 5674#include <sys/types.h>
98418dba 5675#include <sys/time.h>
ba4481b5 5676#include <time.h>
503d2be0
AS
5677
5678int
5679main ()
5680{
98418dba
CW
5681if ((struct tm *) 0)
5682return 0;
503d2be0
AS
5683 ;
5684 return 0;
5685}
5686_ACEOF
5687rm -f conftest.$ac_objext
c0d27fcc 5688if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5689 (eval $ac_compile) 2>conftest.er1
503d2be0 5690 ac_status=$?
35996d22
AS
5691 grep -v '^ *+' conftest.er1 >conftest.err
5692 rm -f conftest.er1
5693 cat conftest.err >&5
c0d27fcc 5694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5695 (exit $ac_status); } &&
4494a266
JD
5696 { ac_try='test -z "$ac_c_werror_flag"
5697 || test ! -s conftest.err'
35996d22
AS
5698 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5699 (eval $ac_try) 2>&5
5700 ac_status=$?
5701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5702 (exit $ac_status); }; } &&
5703 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5705 (eval $ac_try) 2>&5
5706 ac_status=$?
c0d27fcc 5707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5708 (exit $ac_status); }; }; then
98418dba 5709 ac_cv_header_time=yes
ba4481b5 5710else
503d2be0 5711 echo "$as_me: failed program was:" >&5
19650fd6
AS
5712sed 's/^/| /' conftest.$ac_ext >&5
5713
98418dba 5714ac_cv_header_time=no
ba4481b5 5715fi
35996d22 5716rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5717fi
c0d27fcc 5718echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5719echo "${ECHO_T}$ac_cv_header_time" >&6
5720if test $ac_cv_header_time = yes; then
503d2be0 5721
c0d27fcc 5722cat >>confdefs.h <<\_ACEOF
98418dba 5723#define TIME_WITH_SYS_TIME 1
c0d27fcc 5724_ACEOF
ba4481b5
DL
5725
5726fi
5727
cd958eb3
MB
5728echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5729echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5730if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5731 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5732else
503d2be0 5733 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5734/* confdefs.h. */
5735_ACEOF
5736cat confdefs.h >>conftest.$ac_ext
5737cat >>conftest.$ac_ext <<_ACEOF
5738/* end confdefs.h. */
cd958eb3
MB
5739$ac_includes_default
5740int
5741main ()
5742{
5743#ifndef sys_siglist
5744 char *p = (char *) sys_siglist;
98418dba 5745#endif
503d2be0 5746
cd958eb3
MB
5747 ;
5748 return 0;
5749}
5750_ACEOF
5751rm -f conftest.$ac_objext
5752if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5753 (eval $ac_compile) 2>conftest.er1
cd958eb3 5754 ac_status=$?
35996d22
AS
5755 grep -v '^ *+' conftest.er1 >conftest.err
5756 rm -f conftest.er1
5757 cat conftest.err >&5
cd958eb3
MB
5758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5759 (exit $ac_status); } &&
4494a266
JD
5760 { ac_try='test -z "$ac_c_werror_flag"
5761 || test ! -s conftest.err'
35996d22
AS
5762 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5763 (eval $ac_try) 2>&5
5764 ac_status=$?
5765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5766 (exit $ac_status); }; } &&
5767 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
5768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5769 (eval $ac_try) 2>&5
5770 ac_status=$?
5771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5772 (exit $ac_status); }; }; then
5773 ac_cv_have_decl_sys_siglist=yes
5774else
5775 echo "$as_me: failed program was:" >&5
19650fd6
AS
5776sed 's/^/| /' conftest.$ac_ext >&5
5777
cd958eb3
MB
5778ac_cv_have_decl_sys_siglist=no
5779fi
35996d22 5780rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
5781fi
5782echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5783echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5784if test $ac_cv_have_decl_sys_siglist = yes; then
5785
5786cat >>confdefs.h <<_ACEOF
5787#define HAVE_DECL_SYS_SIGLIST 1
5788_ACEOF
5789
5790
5791else
5792 cat >>confdefs.h <<_ACEOF
5793#define HAVE_DECL_SYS_SIGLIST 0
5794_ACEOF
5795
5796
5797fi
5798
5799
5800if test $ac_cv_have_decl_sys_siglist != yes; then
5801 # For Tru64, at least:
5802 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5803echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5804if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5805 echo $ECHO_N "(cached) $ECHO_C" >&6
5806else
5807 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5808/* confdefs.h. */
5809_ACEOF
5810cat confdefs.h >>conftest.$ac_ext
5811cat >>conftest.$ac_ext <<_ACEOF
5812/* end confdefs.h. */
cd958eb3 5813$ac_includes_default
503d2be0
AS
5814int
5815main ()
5816{
cd958eb3
MB
5817#ifndef __sys_siglist
5818 char *p = (char *) __sys_siglist;
5819#endif
5820
503d2be0
AS
5821 ;
5822 return 0;
5823}
5824_ACEOF
5825rm -f conftest.$ac_objext
c0d27fcc 5826if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5827 (eval $ac_compile) 2>conftest.er1
503d2be0 5828 ac_status=$?
35996d22
AS
5829 grep -v '^ *+' conftest.er1 >conftest.err
5830 rm -f conftest.er1
5831 cat conftest.err >&5
c0d27fcc 5832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5833 (exit $ac_status); } &&
4494a266
JD
5834 { ac_try='test -z "$ac_c_werror_flag"
5835 || test ! -s conftest.err'
35996d22
AS
5836 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5837 (eval $ac_try) 2>&5
5838 ac_status=$?
5839 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5840 (exit $ac_status); }; } &&
5841 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5842 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5843 (eval $ac_try) 2>&5
5844 ac_status=$?
c0d27fcc 5845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5846 (exit $ac_status); }; }; then
cd958eb3 5847 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5848else
503d2be0 5849 echo "$as_me: failed program was:" >&5
19650fd6
AS
5850sed 's/^/| /' conftest.$ac_ext >&5
5851
cd958eb3 5852ac_cv_have_decl___sys_siglist=no
ba4481b5 5853fi
35996d22 5854rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
503d2be0 5855fi
cd958eb3
MB
5856echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5857echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5858if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5859
cd958eb3
MB
5860cat >>confdefs.h <<_ACEOF
5861#define HAVE_DECL___SYS_SIGLIST 1
5862_ACEOF
5863
5864
5865else
5866 cat >>confdefs.h <<_ACEOF
5867#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5868_ACEOF
503d2be0 5869
cd958eb3 5870
ba4481b5
DL
5871fi
5872
cd958eb3
MB
5873
5874 if test $ac_cv_have_decl___sys_siglist = yes; then
5875
5876cat >>confdefs.h <<\_ACEOF
5877#define sys_siglist __sys_siglist
5878_ACEOF
5879
5880 fi
5881fi
c0d27fcc 5882echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5883echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5884if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5885 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5886else
503d2be0 5887 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5888/* confdefs.h. */
5889_ACEOF
5890cat confdefs.h >>conftest.$ac_ext
5891cat >>conftest.$ac_ext <<_ACEOF
5892/* end confdefs.h. */
98418dba
CW
5893#include <sys/types.h>
5894#include <sys/wait.h>
5895#ifndef WEXITSTATUS
5896# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5897#endif
5898#ifndef WIFEXITED
5899# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5900#endif
503d2be0
AS
5901
5902int
5903main ()
5904{
98418dba
CW
5905 int s;
5906 wait (&s);
5907 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5908 ;
5909 return 0;
5910}
5911_ACEOF
98418dba 5912rm -f conftest.$ac_objext
c0d27fcc 5913if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5914 (eval $ac_compile) 2>conftest.er1
503d2be0 5915 ac_status=$?
35996d22
AS
5916 grep -v '^ *+' conftest.er1 >conftest.err
5917 rm -f conftest.er1
5918 cat conftest.err >&5
c0d27fcc 5919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5920 (exit $ac_status); } &&
4494a266
JD
5921 { ac_try='test -z "$ac_c_werror_flag"
5922 || test ! -s conftest.err'
35996d22
AS
5923 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5924 (eval $ac_try) 2>&5
5925 ac_status=$?
5926 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5927 (exit $ac_status); }; } &&
5928 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5929 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5930 (eval $ac_try) 2>&5
5931 ac_status=$?
c0d27fcc 5932 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5933 (exit $ac_status); }; }; then
98418dba 5934 ac_cv_header_sys_wait_h=yes
ba4481b5 5935else
503d2be0 5936 echo "$as_me: failed program was:" >&5
19650fd6
AS
5937sed 's/^/| /' conftest.$ac_ext >&5
5938
98418dba 5939ac_cv_header_sys_wait_h=no
ba4481b5 5940fi
35996d22 5941rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 5942fi
c0d27fcc 5943echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5944echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5945if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5946
c0d27fcc 5947cat >>confdefs.h <<\_ACEOF
98418dba 5948#define HAVE_SYS_WAIT_H 1
c0d27fcc 5949_ACEOF
ba4481b5 5950
ba4481b5
DL
5951fi
5952
c0d27fcc
MR
5953
5954echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5955echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5956if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5957 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5958else
503d2be0 5959 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
5960/* confdefs.h. */
5961_ACEOF
5962cat confdefs.h >>conftest.$ac_ext
5963cat >>conftest.$ac_ext <<_ACEOF
5964/* end confdefs.h. */
98418dba
CW
5965#ifdef TIME_WITH_SYS_TIME
5966#include <sys/time.h>
5967#include <time.h>
5968#else
5969#ifdef HAVE_SYS_TIME_H
5970#include <sys/time.h>
5971#else
1113b624 5972#include <time.h>
98418dba
CW
5973#endif
5974#endif
5975#ifdef HAVE_UTIME_H
5976#include <utime.h>
5977#endif
503d2be0
AS
5978int
5979main ()
5980{
98418dba 5981static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5982 ;
5983 return 0;
5984}
5985_ACEOF
98418dba 5986rm -f conftest.$ac_objext
c0d27fcc 5987if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 5988 (eval $ac_compile) 2>conftest.er1
503d2be0 5989 ac_status=$?
35996d22
AS
5990 grep -v '^ *+' conftest.er1 >conftest.err
5991 rm -f conftest.er1
5992 cat conftest.err >&5
c0d27fcc 5993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5994 (exit $ac_status); } &&
4494a266
JD
5995 { ac_try='test -z "$ac_c_werror_flag"
5996 || test ! -s conftest.err'
35996d22
AS
5997 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5998 (eval $ac_try) 2>&5
5999 ac_status=$?
6000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6001 (exit $ac_status); }; } &&
6002 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6003 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6004 (eval $ac_try) 2>&5
6005 ac_status=$?
c0d27fcc 6006 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6007 (exit $ac_status); }; }; then
98418dba 6008 emacs_cv_struct_utimbuf=yes
1113b624 6009else
503d2be0 6010 echo "$as_me: failed program was:" >&5
19650fd6
AS
6011sed 's/^/| /' conftest.$ac_ext >&5
6012
98418dba 6013emacs_cv_struct_utimbuf=no
1113b624 6014fi
35996d22 6015rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
1113b624 6016fi
c0d27fcc 6017echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
6018echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
6019if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 6020
c0d27fcc 6021cat >>confdefs.h <<\_ACEOF
98418dba 6022#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 6023_ACEOF
1113b624
PE
6024
6025fi
ba4481b5 6026
c0d27fcc 6027echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
6028echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
6029if test "${ac_cv_type_signal+set}" = set; then
503d2be0 6030 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6031else
98418dba 6032 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6033/* confdefs.h. */
6034_ACEOF
6035cat confdefs.h >>conftest.$ac_ext
6036cat >>conftest.$ac_ext <<_ACEOF
6037/* end confdefs.h. */
7397acc4 6038#include <sys/types.h>
98418dba
CW
6039#include <signal.h>
6040#ifdef signal
6041# undef signal
6042#endif
6043#ifdef __cplusplus
6044extern "C" void (*signal (int, void (*)(int)))(int);
6045#else
6046void (*signal ()) ();
6047#endif
6048
503d2be0
AS
6049int
6050main ()
6051{
98418dba 6052int i;
503d2be0
AS
6053 ;
6054 return 0;
6055}
6056_ACEOF
98418dba 6057rm -f conftest.$ac_objext
c0d27fcc 6058if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6059 (eval $ac_compile) 2>conftest.er1
503d2be0 6060 ac_status=$?
35996d22
AS
6061 grep -v '^ *+' conftest.er1 >conftest.err
6062 rm -f conftest.er1
6063 cat conftest.err >&5
c0d27fcc 6064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6065 (exit $ac_status); } &&
4494a266
JD
6066 { ac_try='test -z "$ac_c_werror_flag"
6067 || test ! -s conftest.err'
35996d22
AS
6068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6069 (eval $ac_try) 2>&5
6070 ac_status=$?
6071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6072 (exit $ac_status); }; } &&
6073 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6075 (eval $ac_try) 2>&5
6076 ac_status=$?
c0d27fcc 6077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6078 (exit $ac_status); }; }; then
98418dba 6079 ac_cv_type_signal=void
503d2be0
AS
6080else
6081 echo "$as_me: failed program was:" >&5
19650fd6
AS
6082sed 's/^/| /' conftest.$ac_ext >&5
6083
98418dba 6084ac_cv_type_signal=int
503d2be0 6085fi
35996d22 6086rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6087fi
c0d27fcc 6088echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 6089echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 6090
c0d27fcc 6091cat >>confdefs.h <<_ACEOF
98418dba 6092#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
6093_ACEOF
6094
503d2be0 6095
c0d27fcc
MR
6096
6097echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
6098echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
6099if test "${emacs_cv_speed_t+set}" = set; then
6100 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6101else
98418dba 6102 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6103/* confdefs.h. */
6104_ACEOF
6105cat confdefs.h >>conftest.$ac_ext
6106cat >>conftest.$ac_ext <<_ACEOF
6107/* end confdefs.h. */
98418dba 6108#include <termios.h>
98418dba
CW
6109int
6110main ()
6111{
6112speed_t x = 1;
6113 ;
6114 return 0;
6115}
6116_ACEOF
6117rm -f conftest.$ac_objext
c0d27fcc 6118if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6119 (eval $ac_compile) 2>conftest.er1
98418dba 6120 ac_status=$?
35996d22
AS
6121 grep -v '^ *+' conftest.er1 >conftest.err
6122 rm -f conftest.er1
6123 cat conftest.err >&5
c0d27fcc 6124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6125 (exit $ac_status); } &&
4494a266
JD
6126 { ac_try='test -z "$ac_c_werror_flag"
6127 || test ! -s conftest.err'
35996d22
AS
6128 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6129 (eval $ac_try) 2>&5
6130 ac_status=$?
6131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6132 (exit $ac_status); }; } &&
6133 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6134 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6135 (eval $ac_try) 2>&5
6136 ac_status=$?
c0d27fcc 6137 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6138 (exit $ac_status); }; }; then
6139 emacs_cv_speed_t=yes
6140else
6141 echo "$as_me: failed program was:" >&5
19650fd6
AS
6142sed 's/^/| /' conftest.$ac_ext >&5
6143
98418dba
CW
6144emacs_cv_speed_t=no
6145fi
35996d22 6146rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 6147fi
c0d27fcc 6148echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
6149echo "${ECHO_T}$emacs_cv_speed_t" >&6
6150if test $emacs_cv_speed_t = yes; then
b936fae4 6151
c0d27fcc 6152cat >>confdefs.h <<\_ACEOF
98418dba 6153#define HAVE_SPEED_T 1
c0d27fcc 6154_ACEOF
98418dba 6155
7397acc4
DL
6156fi
6157
c0d27fcc 6158echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
6159echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
6160if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 6161 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6162else
503d2be0 6163 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6164/* confdefs.h. */
6165_ACEOF
6166cat confdefs.h >>conftest.$ac_ext
6167cat >>conftest.$ac_ext <<_ACEOF
6168/* end confdefs.h. */
98418dba
CW
6169#ifdef TIME_WITH_SYS_TIME
6170#include <sys/time.h>
6171#include <time.h>
6172#else
6173#ifdef HAVE_SYS_TIME_H
6174#include <sys/time.h>
6175#else
6176#include <time.h>
6177#endif
6178#endif
503d2be0
AS
6179int
6180main ()
6181{
98418dba 6182static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
6183 ;
6184 return 0;
6185}
6186_ACEOF
6187rm -f conftest.$ac_objext
c0d27fcc 6188if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6189 (eval $ac_compile) 2>conftest.er1
503d2be0 6190 ac_status=$?
35996d22
AS
6191 grep -v '^ *+' conftest.er1 >conftest.err
6192 rm -f conftest.er1
6193 cat conftest.err >&5
c0d27fcc 6194 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6195 (exit $ac_status); } &&
4494a266
JD
6196 { ac_try='test -z "$ac_c_werror_flag"
6197 || test ! -s conftest.err'
35996d22
AS
6198 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6199 (eval $ac_try) 2>&5
6200 ac_status=$?
6201 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6202 (exit $ac_status); }; } &&
6203 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6204 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6205 (eval $ac_try) 2>&5
6206 ac_status=$?
c0d27fcc 6207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6208 (exit $ac_status); }; }; then
98418dba 6209 emacs_cv_struct_timeval=yes
7397acc4 6210else
503d2be0 6211 echo "$as_me: failed program was:" >&5
19650fd6
AS
6212sed 's/^/| /' conftest.$ac_ext >&5
6213
98418dba 6214emacs_cv_struct_timeval=no
7397acc4 6215fi
35996d22 6216rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6217fi
c0d27fcc 6218echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
6219echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
6220HAVE_TIMEVAL=$emacs_cv_struct_timeval
6221if test $emacs_cv_struct_timeval = yes; then
b936fae4 6222
c0d27fcc 6223cat >>confdefs.h <<\_ACEOF
98418dba 6224#define HAVE_TIMEVAL 1
c0d27fcc 6225_ACEOF
7397acc4
DL
6226
6227fi
6228
c0d27fcc 6229echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
6230echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
6231if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 6232 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6233else
503d2be0 6234 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6235/* confdefs.h. */
6236_ACEOF
6237cat confdefs.h >>conftest.$ac_ext
6238cat >>conftest.$ac_ext <<_ACEOF
6239/* end confdefs.h. */
98418dba 6240#include <math.h>
503d2be0
AS
6241int
6242main ()
6243{
98418dba 6244static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
6245 ;
6246 return 0;
ba4481b5 6247}
503d2be0
AS
6248_ACEOF
6249rm -f conftest.$ac_objext
c0d27fcc 6250if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6251 (eval $ac_compile) 2>conftest.er1
503d2be0 6252 ac_status=$?
35996d22
AS
6253 grep -v '^ *+' conftest.er1 >conftest.err
6254 rm -f conftest.er1
6255 cat conftest.err >&5
c0d27fcc 6256 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6257 (exit $ac_status); } &&
4494a266
JD
6258 { ac_try='test -z "$ac_c_werror_flag"
6259 || test ! -s conftest.err'
35996d22
AS
6260 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6261 (eval $ac_try) 2>&5
6262 ac_status=$?
6263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6264 (exit $ac_status); }; } &&
6265 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6266 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6267 (eval $ac_try) 2>&5
6268 ac_status=$?
c0d27fcc 6269 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6270 (exit $ac_status); }; }; then
98418dba 6271 emacs_cv_struct_exception=yes
ba4481b5 6272else
503d2be0 6273 echo "$as_me: failed program was:" >&5
19650fd6
AS
6274sed 's/^/| /' conftest.$ac_ext >&5
6275
98418dba 6276emacs_cv_struct_exception=no
ba4481b5 6277fi
35996d22 6278rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6279fi
c0d27fcc 6280echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
6281echo "${ECHO_T}$emacs_cv_struct_exception" >&6
6282HAVE_EXCEPTION=$emacs_cv_struct_exception
6283if test $emacs_cv_struct_exception != yes; then
b936fae4 6284
c0d27fcc 6285cat >>confdefs.h <<\_ACEOF
98418dba 6286#define NO_MATHERR 1
c0d27fcc 6287_ACEOF
ba4481b5
DL
6288
6289fi
6290
7862d3a8
AS
6291
6292for ac_header in sys/socket.h
6293do
6294as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6295if eval "test \"\${$as_ac_Header+set}\" = set"; then
6296 echo "$as_me:$LINENO: checking for $ac_header" >&5
6297echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6298if eval "test \"\${$as_ac_Header+set}\" = set"; then
6299 echo $ECHO_N "(cached) $ECHO_C" >&6
6300fi
6301echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6302echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6303else
6304 # Is the header compilable?
6305echo "$as_me:$LINENO: checking $ac_header usability" >&5
6306echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6307cat >conftest.$ac_ext <<_ACEOF
6308/* confdefs.h. */
6309_ACEOF
6310cat confdefs.h >>conftest.$ac_ext
6311cat >>conftest.$ac_ext <<_ACEOF
6312/* end confdefs.h. */
6313$ac_includes_default
6314#include <$ac_header>
6315_ACEOF
6316rm -f conftest.$ac_objext
6317if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6318 (eval $ac_compile) 2>conftest.er1
6319 ac_status=$?
6320 grep -v '^ *+' conftest.er1 >conftest.err
6321 rm -f conftest.er1
6322 cat conftest.err >&5
6323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6324 (exit $ac_status); } &&
4494a266
JD
6325 { ac_try='test -z "$ac_c_werror_flag"
6326 || test ! -s conftest.err'
7862d3a8
AS
6327 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6328 (eval $ac_try) 2>&5
6329 ac_status=$?
6330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6331 (exit $ac_status); }; } &&
6332 { ac_try='test -s conftest.$ac_objext'
6333 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6334 (eval $ac_try) 2>&5
6335 ac_status=$?
6336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6337 (exit $ac_status); }; }; then
6338 ac_header_compiler=yes
6339else
6340 echo "$as_me: failed program was:" >&5
6341sed 's/^/| /' conftest.$ac_ext >&5
6342
6343ac_header_compiler=no
6344fi
6345rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6346echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6347echo "${ECHO_T}$ac_header_compiler" >&6
6348
6349# Is the header present?
6350echo "$as_me:$LINENO: checking $ac_header presence" >&5
6351echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6352cat >conftest.$ac_ext <<_ACEOF
6353/* confdefs.h. */
6354_ACEOF
6355cat confdefs.h >>conftest.$ac_ext
6356cat >>conftest.$ac_ext <<_ACEOF
6357/* end confdefs.h. */
6358#include <$ac_header>
6359_ACEOF
6360if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6361 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6362 ac_status=$?
6363 grep -v '^ *+' conftest.er1 >conftest.err
6364 rm -f conftest.er1
6365 cat conftest.err >&5
6366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6367 (exit $ac_status); } >/dev/null; then
6368 if test -s conftest.err; then
6369 ac_cpp_err=$ac_c_preproc_warn_flag
6370 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
6371 else
6372 ac_cpp_err=
6373 fi
6374else
6375 ac_cpp_err=yes
6376fi
6377if test -z "$ac_cpp_err"; then
6378 ac_header_preproc=yes
6379else
6380 echo "$as_me: failed program was:" >&5
6381sed 's/^/| /' conftest.$ac_ext >&5
6382
6383 ac_header_preproc=no
6384fi
6385rm -f conftest.err conftest.$ac_ext
6386echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6387echo "${ECHO_T}$ac_header_preproc" >&6
6388
6389# So? What about this header?
6390case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6391 yes:no: )
6392 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6393echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6394 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6395echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
6396 ac_header_preproc=yes
6397 ;;
6398 no:yes:* )
6399 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6400echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6401 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6402echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6403 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6404echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6405 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6406echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6407 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6408echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6409 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6410echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
6411 (
6412 cat <<\_ASBOX
6413## ------------------------------------------ ##
6414## Report this to the AC_PACKAGE_NAME lists. ##
6415## ------------------------------------------ ##
6416_ASBOX
6417 ) |
6418 sed "s/^/$as_me: WARNING: /" >&2
6419 ;;
6420esac
6421echo "$as_me:$LINENO: checking for $ac_header" >&5
6422echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6423if eval "test \"\${$as_ac_Header+set}\" = set"; then
6424 echo $ECHO_N "(cached) $ECHO_C" >&6
6425else
6426 eval "$as_ac_Header=\$ac_header_preproc"
6427fi
6428echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6429echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6430
6431fi
6432if test `eval echo '${'$as_ac_Header'}'` = yes; then
6433 cat >>confdefs.h <<_ACEOF
6434#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6435_ACEOF
6436
6437fi
6438
6439done
6440
6441
6442for ac_header in net/if.h
6443do
6444as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6445echo "$as_me:$LINENO: checking for $ac_header" >&5
6446echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6447if eval "test \"\${$as_ac_Header+set}\" = set"; then
6448 echo $ECHO_N "(cached) $ECHO_C" >&6
6449else
6450 cat >conftest.$ac_ext <<_ACEOF
6451/* confdefs.h. */
6452_ACEOF
6453cat confdefs.h >>conftest.$ac_ext
6454cat >>conftest.$ac_ext <<_ACEOF
6455/* end confdefs.h. */
6456$ac_includes_default
6457#if HAVE_SYS_SOCKET_H
6458#include <sys/socket.h>
6459#endif
6460
6461#include <$ac_header>
6462_ACEOF
6463rm -f conftest.$ac_objext
6464if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6465 (eval $ac_compile) 2>conftest.er1
6466 ac_status=$?
6467 grep -v '^ *+' conftest.er1 >conftest.err
6468 rm -f conftest.er1
6469 cat conftest.err >&5
6470 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6471 (exit $ac_status); } &&
4494a266
JD
6472 { ac_try='test -z "$ac_c_werror_flag"
6473 || test ! -s conftest.err'
7862d3a8
AS
6474 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6475 (eval $ac_try) 2>&5
6476 ac_status=$?
6477 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6478 (exit $ac_status); }; } &&
6479 { ac_try='test -s conftest.$ac_objext'
6480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6481 (eval $ac_try) 2>&5
6482 ac_status=$?
6483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6484 (exit $ac_status); }; }; then
6485 eval "$as_ac_Header=yes"
6486else
6487 echo "$as_me: failed program was:" >&5
6488sed 's/^/| /' conftest.$ac_ext >&5
6489
6490eval "$as_ac_Header=no"
6491fi
6492rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6493fi
6494echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6495echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6496if test `eval echo '${'$as_ac_Header'}'` = yes; then
6497 cat >>confdefs.h <<_ACEOF
6498#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6499_ACEOF
6500
6501fi
6502
6503done
6504
6505
c0d27fcc 6506echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
6507echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
6508if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 6509 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6510else
503d2be0 6511 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6512/* confdefs.h. */
6513_ACEOF
6514cat confdefs.h >>conftest.$ac_ext
6515cat >>conftest.$ac_ext <<_ACEOF
6516/* end confdefs.h. */
98418dba
CW
6517#include <sys/types.h>
6518#include <time.h>
7397acc4 6519
503d2be0
AS
6520int
6521main ()
6522{
98418dba 6523struct tm *tp; tp->tm_sec;
503d2be0
AS
6524 ;
6525 return 0;
6526}
6527_ACEOF
6528rm -f conftest.$ac_objext
c0d27fcc 6529if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6530 (eval $ac_compile) 2>conftest.er1
503d2be0 6531 ac_status=$?
35996d22
AS
6532 grep -v '^ *+' conftest.er1 >conftest.err
6533 rm -f conftest.er1
6534 cat conftest.err >&5
c0d27fcc 6535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6536 (exit $ac_status); } &&
4494a266
JD
6537 { ac_try='test -z "$ac_c_werror_flag"
6538 || test ! -s conftest.err'
c0d27fcc 6539 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6540 (eval $ac_try) 2>&5
6541 ac_status=$?
c0d27fcc 6542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
6543 (exit $ac_status); }; } &&
6544 { ac_try='test -s conftest.$ac_objext'
6545 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6546 (eval $ac_try) 2>&5
6547 ac_status=$?
6548 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6549 (exit $ac_status); }; }; then
6550 ac_cv_struct_tm=time.h
6551else
503d2be0 6552 echo "$as_me: failed program was:" >&5
19650fd6
AS
6553sed 's/^/| /' conftest.$ac_ext >&5
6554
98418dba 6555ac_cv_struct_tm=sys/time.h
7397acc4 6556fi
35996d22 6557rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7397acc4 6558fi
c0d27fcc 6559echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
6560echo "${ECHO_T}$ac_cv_struct_tm" >&6
6561if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 6562
c0d27fcc 6563cat >>confdefs.h <<\_ACEOF
98418dba 6564#define TM_IN_SYS_TIME 1
c0d27fcc 6565_ACEOF
7397acc4
DL
6566
6567fi
ba4481b5 6568
c0d27fcc 6569echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
6570echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
6571if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 6572 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6573else
98418dba 6574 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6575/* confdefs.h. */
6576_ACEOF
6577cat confdefs.h >>conftest.$ac_ext
6578cat >>conftest.$ac_ext <<_ACEOF
6579/* end confdefs.h. */
98418dba
CW
6580#include <sys/types.h>
6581#include <$ac_cv_struct_tm>
ba4481b5 6582
c0d27fcc 6583
98418dba
CW
6584int
6585main ()
6586{
6587static struct tm ac_aggr;
6588if (ac_aggr.tm_zone)
6589return 0;
6590 ;
6591 return 0;
6592}
6593_ACEOF
6594rm -f conftest.$ac_objext
c0d27fcc 6595if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6596 (eval $ac_compile) 2>conftest.er1
98418dba 6597 ac_status=$?
35996d22
AS
6598 grep -v '^ *+' conftest.er1 >conftest.err
6599 rm -f conftest.er1
6600 cat conftest.err >&5
c0d27fcc 6601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6602 (exit $ac_status); } &&
4494a266
JD
6603 { ac_try='test -z "$ac_c_werror_flag"
6604 || test ! -s conftest.err'
35996d22
AS
6605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6606 (eval $ac_try) 2>&5
6607 ac_status=$?
6608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6609 (exit $ac_status); }; } &&
6610 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6611 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6612 (eval $ac_try) 2>&5
6613 ac_status=$?
c0d27fcc 6614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6615 (exit $ac_status); }; }; then
6616 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6617else
98418dba 6618 echo "$as_me: failed program was:" >&5
19650fd6
AS
6619sed 's/^/| /' conftest.$ac_ext >&5
6620
6bae0ccf 6621cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6622/* confdefs.h. */
6623_ACEOF
6624cat confdefs.h >>conftest.$ac_ext
6625cat >>conftest.$ac_ext <<_ACEOF
6626/* end confdefs.h. */
6bae0ccf
DL
6627#include <sys/types.h>
6628#include <$ac_cv_struct_tm>
6629
6630
6631int
6632main ()
6633{
6634static struct tm ac_aggr;
6635if (sizeof ac_aggr.tm_zone)
6636return 0;
6637 ;
6638 return 0;
6639}
6640_ACEOF
6641rm -f conftest.$ac_objext
6642if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6643 (eval $ac_compile) 2>conftest.er1
6bae0ccf 6644 ac_status=$?
35996d22
AS
6645 grep -v '^ *+' conftest.er1 >conftest.err
6646 rm -f conftest.er1
6647 cat conftest.err >&5
6bae0ccf
DL
6648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6649 (exit $ac_status); } &&
4494a266
JD
6650 { ac_try='test -z "$ac_c_werror_flag"
6651 || test ! -s conftest.err'
35996d22
AS
6652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6653 (eval $ac_try) 2>&5
6654 ac_status=$?
6655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6656 (exit $ac_status); }; } &&
6657 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
6658 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6659 (eval $ac_try) 2>&5
6660 ac_status=$?
6661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6662 (exit $ac_status); }; }; then
6663 ac_cv_member_struct_tm_tm_zone=yes
6664else
6665 echo "$as_me: failed program was:" >&5
19650fd6
AS
6666sed 's/^/| /' conftest.$ac_ext >&5
6667
98418dba 6668ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6669fi
35996d22 6670rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 6671fi
35996d22 6672rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6673fi
c0d27fcc 6674echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6675echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6676if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6677
c0d27fcc 6678cat >>confdefs.h <<_ACEOF
98418dba 6679#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6680_ACEOF
6681
ba4481b5 6682
98418dba 6683fi
ba4481b5 6684
98418dba 6685if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6686
c0d27fcc 6687cat >>confdefs.h <<\_ACEOF
98418dba 6688#define HAVE_TM_ZONE 1
c0d27fcc 6689_ACEOF
ba4481b5 6690
ba4481b5 6691else
c0d27fcc 6692 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6693echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6694if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6695 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6696else
98418dba 6697 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6698/* confdefs.h. */
6699_ACEOF
6700cat confdefs.h >>conftest.$ac_ext
6701cat >>conftest.$ac_ext <<_ACEOF
6702/* end confdefs.h. */
98418dba
CW
6703#include <time.h>
6704#ifndef tzname /* For SGI. */
6705extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6706#endif
6707
98418dba
CW
6708int
6709main ()
6710{
6711atoi(*tzname);
6712 ;
6713 return 0;
6714}
6715_ACEOF
6716rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6717if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 6718 (eval $ac_link) 2>conftest.er1
98418dba 6719 ac_status=$?
35996d22
AS
6720 grep -v '^ *+' conftest.er1 >conftest.err
6721 rm -f conftest.er1
6722 cat conftest.err >&5
c0d27fcc 6723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6724 (exit $ac_status); } &&
4494a266
JD
6725 { ac_try='test -z "$ac_c_werror_flag"
6726 || test ! -s conftest.err'
35996d22
AS
6727 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6728 (eval $ac_try) 2>&5
6729 ac_status=$?
6730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6731 (exit $ac_status); }; } &&
6732 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6733 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6734 (eval $ac_try) 2>&5
6735 ac_status=$?
c0d27fcc 6736 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6737 (exit $ac_status); }; }; then
6738 ac_cv_var_tzname=yes
6739else
6740 echo "$as_me: failed program was:" >&5
19650fd6
AS
6741sed 's/^/| /' conftest.$ac_ext >&5
6742
98418dba 6743ac_cv_var_tzname=no
ba4481b5 6744fi
35996d22
AS
6745rm -f conftest.err conftest.$ac_objext \
6746 conftest$ac_exeext conftest.$ac_ext
98418dba 6747fi
c0d27fcc 6748echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6749echo "${ECHO_T}$ac_cv_var_tzname" >&6
6750 if test $ac_cv_var_tzname = yes; then
ba4481b5 6751
c0d27fcc 6752cat >>confdefs.h <<\_ACEOF
98418dba 6753#define HAVE_TZNAME 1
c0d27fcc 6754_ACEOF
503d2be0 6755
98418dba
CW
6756 fi
6757fi
503d2be0 6758
c0d27fcc 6759echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6760echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6761if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6762 echo $ECHO_N "(cached) $ECHO_C" >&6
6763else
6764 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6765/* confdefs.h. */
6766_ACEOF
6767cat confdefs.h >>conftest.$ac_ext
6768cat >>conftest.$ac_ext <<_ACEOF
6769/* end confdefs.h. */
98418dba 6770#include <time.h>
b936fae4 6771
98418dba
CW
6772int
6773main ()
6774{
b936fae4
AS
6775static struct tm ac_aggr;
6776if (ac_aggr.tm_gmtoff)
6777return 0;
98418dba
CW
6778 ;
6779 return 0;
6780}
6781_ACEOF
b936fae4 6782rm -f conftest.$ac_objext
c0d27fcc 6783if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6784 (eval $ac_compile) 2>conftest.er1
98418dba 6785 ac_status=$?
35996d22
AS
6786 grep -v '^ *+' conftest.er1 >conftest.err
6787 rm -f conftest.er1
6788 cat conftest.err >&5
c0d27fcc 6789 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6790 (exit $ac_status); } &&
4494a266
JD
6791 { ac_try='test -z "$ac_c_werror_flag"
6792 || test ! -s conftest.err'
35996d22
AS
6793 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6794 (eval $ac_try) 2>&5
6795 ac_status=$?
6796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6797 (exit $ac_status); }; } &&
6798 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6799 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6800 (eval $ac_try) 2>&5
6801 ac_status=$?
c0d27fcc 6802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6803 (exit $ac_status); }; }; then
b936fae4 6804 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6805else
6806 echo "$as_me: failed program was:" >&5
19650fd6
AS
6807sed 's/^/| /' conftest.$ac_ext >&5
6808
8799b3e4 6809cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
6810/* confdefs.h. */
6811_ACEOF
6812cat confdefs.h >>conftest.$ac_ext
6813cat >>conftest.$ac_ext <<_ACEOF
6814/* end confdefs.h. */
6bae0ccf
DL
6815#include <time.h>
6816
8799b3e4
CW
6817int
6818main ()
6819{
6bae0ccf
DL
6820static struct tm ac_aggr;
6821if (sizeof ac_aggr.tm_gmtoff)
6822return 0;
8799b3e4
CW
6823 ;
6824 return 0;
6825}
6826_ACEOF
6bae0ccf 6827rm -f conftest.$ac_objext
c0d27fcc 6828if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6829 (eval $ac_compile) 2>conftest.er1
8799b3e4 6830 ac_status=$?
35996d22
AS
6831 grep -v '^ *+' conftest.er1 >conftest.err
6832 rm -f conftest.er1
6833 cat conftest.err >&5
c0d27fcc 6834 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6835 (exit $ac_status); } &&
4494a266
JD
6836 { ac_try='test -z "$ac_c_werror_flag"
6837 || test ! -s conftest.err'
35996d22
AS
6838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6839 (eval $ac_try) 2>&5
6840 ac_status=$?
6841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6842 (exit $ac_status); }; } &&
6843 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6844 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6845 (eval $ac_try) 2>&5
6846 ac_status=$?
c0d27fcc 6847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6848 (exit $ac_status); }; }; then
6bae0ccf 6849 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6850else
6851 echo "$as_me: failed program was:" >&5
19650fd6
AS
6852sed 's/^/| /' conftest.$ac_ext >&5
6853
6bae0ccf 6854ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6855fi
35996d22 6856rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6857fi
35996d22 6858rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8799b3e4 6859fi
6bae0ccf
DL
6860echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6861echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6862if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6863
6864cat >>confdefs.h <<\_ACEOF
6865#define HAVE_TM_GMTOFF 1
6866_ACEOF
6867
6868fi
6869
96f3a036
DL
6870echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
6871echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6
6872if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
6873 echo $ECHO_N "(cached) $ECHO_C" >&6
6874else
6875 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6876/* confdefs.h. */
6877_ACEOF
6878cat confdefs.h >>conftest.$ac_ext
6879cat >>conftest.$ac_ext <<_ACEOF
6880/* end confdefs.h. */
7862d3a8
AS
6881$ac_includes_default
6882#if HAVE_SYS_SOCKET_H
6883#include <sys/socket.h>
6884#endif
6885#if HAVE_NET_IF_H
96f3a036 6886#include <net/if.h>
7862d3a8 6887#endif
96f3a036
DL
6888
6889int
6890main ()
6891{
6892static struct ifreq ac_aggr;
6893if (ac_aggr.ifr_flags)
6894return 0;
6895 ;
6896 return 0;
6897}
6898_ACEOF
6899rm -f conftest.$ac_objext
6900if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6901 (eval $ac_compile) 2>conftest.er1
96f3a036 6902 ac_status=$?
35996d22
AS
6903 grep -v '^ *+' conftest.er1 >conftest.err
6904 rm -f conftest.er1
6905 cat conftest.err >&5
96f3a036
DL
6906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6907 (exit $ac_status); } &&
4494a266
JD
6908 { ac_try='test -z "$ac_c_werror_flag"
6909 || test ! -s conftest.err'
35996d22
AS
6910 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6911 (eval $ac_try) 2>&5
6912 ac_status=$?
6913 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6914 (exit $ac_status); }; } &&
6915 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6916 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6917 (eval $ac_try) 2>&5
6918 ac_status=$?
6919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6920 (exit $ac_status); }; }; then
6921 ac_cv_member_struct_ifreq_ifr_flags=yes
6922else
6923 echo "$as_me: failed program was:" >&5
6924sed 's/^/| /' conftest.$ac_ext >&5
6925
6926cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6927/* confdefs.h. */
6928_ACEOF
6929cat confdefs.h >>conftest.$ac_ext
6930cat >>conftest.$ac_ext <<_ACEOF
6931/* end confdefs.h. */
7862d3a8
AS
6932$ac_includes_default
6933#if HAVE_SYS_SOCKET_H
6934#include <sys/socket.h>
6935#endif
6936#if HAVE_NET_IF_H
96f3a036 6937#include <net/if.h>
7862d3a8 6938#endif
96f3a036
DL
6939
6940int
6941main ()
6942{
6943static struct ifreq ac_aggr;
6944if (sizeof ac_aggr.ifr_flags)
6945return 0;
6946 ;
6947 return 0;
6948}
6949_ACEOF
6950rm -f conftest.$ac_objext
6951if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 6952 (eval $ac_compile) 2>conftest.er1
96f3a036 6953 ac_status=$?
35996d22
AS
6954 grep -v '^ *+' conftest.er1 >conftest.err
6955 rm -f conftest.er1
6956 cat conftest.err >&5
96f3a036
DL
6957 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6958 (exit $ac_status); } &&
4494a266
JD
6959 { ac_try='test -z "$ac_c_werror_flag"
6960 || test ! -s conftest.err'
35996d22
AS
6961 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6962 (eval $ac_try) 2>&5
6963 ac_status=$?
6964 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6965 (exit $ac_status); }; } &&
6966 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6967 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6968 (eval $ac_try) 2>&5
6969 ac_status=$?
6970 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6971 (exit $ac_status); }; }; then
6972 ac_cv_member_struct_ifreq_ifr_flags=yes
6973else
6974 echo "$as_me: failed program was:" >&5
6975sed 's/^/| /' conftest.$ac_ext >&5
6976
6977ac_cv_member_struct_ifreq_ifr_flags=no
6978fi
35996d22 6979rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 6980fi
35996d22 6981rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6982fi
6983echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
6984echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6
6985if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
6986
6987cat >>confdefs.h <<_ACEOF
6988#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6989_ACEOF
6990
6991
6992fi
6993echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
6994echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
6995if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
6996 echo $ECHO_N "(cached) $ECHO_C" >&6
6997else
6998 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
6999/* confdefs.h. */
7000_ACEOF
7001cat confdefs.h >>conftest.$ac_ext
7002cat >>conftest.$ac_ext <<_ACEOF
7003/* end confdefs.h. */
7862d3a8
AS
7004$ac_includes_default
7005#if HAVE_SYS_SOCKET_H
7006#include <sys/socket.h>
7007#endif
7008#if HAVE_NET_IF_H
96f3a036 7009#include <net/if.h>
7862d3a8 7010#endif
96f3a036
DL
7011
7012int
7013main ()
7014{
7015static struct ifreq ac_aggr;
7016if (ac_aggr.ifr_hwaddr)
7017return 0;
7018 ;
7019 return 0;
7020}
7021_ACEOF
7022rm -f conftest.$ac_objext
7023if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7024 (eval $ac_compile) 2>conftest.er1
96f3a036 7025 ac_status=$?
35996d22
AS
7026 grep -v '^ *+' conftest.er1 >conftest.err
7027 rm -f conftest.er1
7028 cat conftest.err >&5
96f3a036
DL
7029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7030 (exit $ac_status); } &&
4494a266
JD
7031 { ac_try='test -z "$ac_c_werror_flag"
7032 || test ! -s conftest.err'
35996d22
AS
7033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7034 (eval $ac_try) 2>&5
7035 ac_status=$?
7036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7037 (exit $ac_status); }; } &&
7038 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7039 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7040 (eval $ac_try) 2>&5
7041 ac_status=$?
7042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7043 (exit $ac_status); }; }; then
7044 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7045else
7046 echo "$as_me: failed program was:" >&5
7047sed 's/^/| /' conftest.$ac_ext >&5
7048
7049cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7050/* confdefs.h. */
7051_ACEOF
7052cat confdefs.h >>conftest.$ac_ext
7053cat >>conftest.$ac_ext <<_ACEOF
7054/* end confdefs.h. */
7862d3a8
AS
7055$ac_includes_default
7056#if HAVE_SYS_SOCKET_H
7057#include <sys/socket.h>
7058#endif
7059#if HAVE_NET_IF_H
96f3a036 7060#include <net/if.h>
7862d3a8 7061#endif
96f3a036
DL
7062
7063int
7064main ()
7065{
7066static struct ifreq ac_aggr;
7067if (sizeof ac_aggr.ifr_hwaddr)
7068return 0;
7069 ;
7070 return 0;
7071}
7072_ACEOF
7073rm -f conftest.$ac_objext
7074if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7075 (eval $ac_compile) 2>conftest.er1
96f3a036 7076 ac_status=$?
35996d22
AS
7077 grep -v '^ *+' conftest.er1 >conftest.err
7078 rm -f conftest.er1
7079 cat conftest.err >&5
96f3a036
DL
7080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7081 (exit $ac_status); } &&
4494a266
JD
7082 { ac_try='test -z "$ac_c_werror_flag"
7083 || test ! -s conftest.err'
35996d22
AS
7084 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7085 (eval $ac_try) 2>&5
7086 ac_status=$?
7087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7088 (exit $ac_status); }; } &&
7089 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7091 (eval $ac_try) 2>&5
7092 ac_status=$?
7093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7094 (exit $ac_status); }; }; then
7095 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
7096else
7097 echo "$as_me: failed program was:" >&5
7098sed 's/^/| /' conftest.$ac_ext >&5
7099
7100ac_cv_member_struct_ifreq_ifr_hwaddr=no
7101fi
35996d22 7102rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7103fi
35996d22 7104rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7105fi
7106echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
7107echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
7108if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
7109
7110cat >>confdefs.h <<_ACEOF
7111#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
7112_ACEOF
7113
7114
7115fi
7116echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
7117echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6
7118if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
7119 echo $ECHO_N "(cached) $ECHO_C" >&6
7120else
7121 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7122/* confdefs.h. */
7123_ACEOF
7124cat confdefs.h >>conftest.$ac_ext
7125cat >>conftest.$ac_ext <<_ACEOF
7126/* end confdefs.h. */
7862d3a8
AS
7127$ac_includes_default
7128#if HAVE_SYS_SOCKET_H
7129#include <sys/socket.h>
7130#endif
7131#if HAVE_NET_IF_H
96f3a036 7132#include <net/if.h>
7862d3a8 7133#endif
96f3a036
DL
7134
7135int
7136main ()
7137{
7138static struct ifreq ac_aggr;
7139if (ac_aggr.ifr_netmask)
7140return 0;
7141 ;
7142 return 0;
7143}
7144_ACEOF
7145rm -f conftest.$ac_objext
7146if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7147 (eval $ac_compile) 2>conftest.er1
96f3a036 7148 ac_status=$?
35996d22
AS
7149 grep -v '^ *+' conftest.er1 >conftest.err
7150 rm -f conftest.er1
7151 cat conftest.err >&5
96f3a036
DL
7152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7153 (exit $ac_status); } &&
4494a266
JD
7154 { ac_try='test -z "$ac_c_werror_flag"
7155 || test ! -s conftest.err'
35996d22
AS
7156 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7157 (eval $ac_try) 2>&5
7158 ac_status=$?
7159 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7160 (exit $ac_status); }; } &&
7161 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7162 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7163 (eval $ac_try) 2>&5
7164 ac_status=$?
7165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7166 (exit $ac_status); }; }; then
7167 ac_cv_member_struct_ifreq_ifr_netmask=yes
7168else
7169 echo "$as_me: failed program was:" >&5
7170sed 's/^/| /' conftest.$ac_ext >&5
7171
7172cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7173/* confdefs.h. */
7174_ACEOF
7175cat confdefs.h >>conftest.$ac_ext
7176cat >>conftest.$ac_ext <<_ACEOF
7177/* end confdefs.h. */
7862d3a8
AS
7178$ac_includes_default
7179#if HAVE_SYS_SOCKET_H
7180#include <sys/socket.h>
7181#endif
7182#if HAVE_NET_IF_H
96f3a036 7183#include <net/if.h>
7862d3a8 7184#endif
96f3a036
DL
7185
7186int
7187main ()
7188{
7189static struct ifreq ac_aggr;
7190if (sizeof ac_aggr.ifr_netmask)
7191return 0;
7192 ;
7193 return 0;
7194}
7195_ACEOF
7196rm -f conftest.$ac_objext
7197if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7198 (eval $ac_compile) 2>conftest.er1
96f3a036 7199 ac_status=$?
35996d22
AS
7200 grep -v '^ *+' conftest.er1 >conftest.err
7201 rm -f conftest.er1
7202 cat conftest.err >&5
96f3a036
DL
7203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7204 (exit $ac_status); } &&
4494a266
JD
7205 { ac_try='test -z "$ac_c_werror_flag"
7206 || test ! -s conftest.err'
35996d22
AS
7207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7208 (eval $ac_try) 2>&5
7209 ac_status=$?
7210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7211 (exit $ac_status); }; } &&
7212 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7213 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7214 (eval $ac_try) 2>&5
7215 ac_status=$?
7216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7217 (exit $ac_status); }; }; then
7218 ac_cv_member_struct_ifreq_ifr_netmask=yes
7219else
7220 echo "$as_me: failed program was:" >&5
7221sed 's/^/| /' conftest.$ac_ext >&5
7222
7223ac_cv_member_struct_ifreq_ifr_netmask=no
7224fi
35996d22 7225rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7226fi
35996d22 7227rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7228fi
7229echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
7230echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6
7231if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
7232
7233cat >>confdefs.h <<_ACEOF
7234#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
7235_ACEOF
7236
7237
7238fi
7239echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
7240echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6
7241if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
7242 echo $ECHO_N "(cached) $ECHO_C" >&6
7243else
7244 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7245/* confdefs.h. */
7246_ACEOF
7247cat confdefs.h >>conftest.$ac_ext
7248cat >>conftest.$ac_ext <<_ACEOF
7249/* end confdefs.h. */
7862d3a8
AS
7250$ac_includes_default
7251#if HAVE_SYS_SOCKET_H
7252#include <sys/socket.h>
7253#endif
7254#if HAVE_NET_IF_H
96f3a036 7255#include <net/if.h>
7862d3a8 7256#endif
96f3a036
DL
7257
7258int
7259main ()
7260{
7261static struct ifreq ac_aggr;
7262if (ac_aggr.ifr_broadaddr)
7263return 0;
7264 ;
7265 return 0;
7266}
7267_ACEOF
7268rm -f conftest.$ac_objext
7269if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7270 (eval $ac_compile) 2>conftest.er1
96f3a036 7271 ac_status=$?
35996d22
AS
7272 grep -v '^ *+' conftest.er1 >conftest.err
7273 rm -f conftest.er1
7274 cat conftest.err >&5
96f3a036
DL
7275 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7276 (exit $ac_status); } &&
4494a266
JD
7277 { ac_try='test -z "$ac_c_werror_flag"
7278 || test ! -s conftest.err'
35996d22
AS
7279 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7280 (eval $ac_try) 2>&5
7281 ac_status=$?
7282 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7283 (exit $ac_status); }; } &&
7284 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7285 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7286 (eval $ac_try) 2>&5
7287 ac_status=$?
7288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7289 (exit $ac_status); }; }; then
7290 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7291else
7292 echo "$as_me: failed program was:" >&5
7293sed 's/^/| /' conftest.$ac_ext >&5
7294
7295cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7296/* confdefs.h. */
7297_ACEOF
7298cat confdefs.h >>conftest.$ac_ext
7299cat >>conftest.$ac_ext <<_ACEOF
7300/* end confdefs.h. */
7862d3a8
AS
7301$ac_includes_default
7302#if HAVE_SYS_SOCKET_H
7303#include <sys/socket.h>
7304#endif
7305#if HAVE_NET_IF_H
96f3a036 7306#include <net/if.h>
7862d3a8 7307#endif
96f3a036
DL
7308
7309int
7310main ()
7311{
7312static struct ifreq ac_aggr;
7313if (sizeof ac_aggr.ifr_broadaddr)
7314return 0;
7315 ;
7316 return 0;
7317}
7318_ACEOF
7319rm -f conftest.$ac_objext
7320if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7321 (eval $ac_compile) 2>conftest.er1
96f3a036 7322 ac_status=$?
35996d22
AS
7323 grep -v '^ *+' conftest.er1 >conftest.err
7324 rm -f conftest.er1
7325 cat conftest.err >&5
96f3a036
DL
7326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7327 (exit $ac_status); } &&
4494a266
JD
7328 { ac_try='test -z "$ac_c_werror_flag"
7329 || test ! -s conftest.err'
35996d22
AS
7330 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7331 (eval $ac_try) 2>&5
7332 ac_status=$?
7333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7334 (exit $ac_status); }; } &&
7335 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7336 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7337 (eval $ac_try) 2>&5
7338 ac_status=$?
7339 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7340 (exit $ac_status); }; }; then
7341 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
7342else
7343 echo "$as_me: failed program was:" >&5
7344sed 's/^/| /' conftest.$ac_ext >&5
7345
7346ac_cv_member_struct_ifreq_ifr_broadaddr=no
7347fi
35996d22 7348rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7349fi
35996d22 7350rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7351fi
7352echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
7353echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6
7354if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
7355
7356cat >>confdefs.h <<_ACEOF
7357#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
7358_ACEOF
7359
7360
7361fi
7362echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
7363echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6
7364if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
7365 echo $ECHO_N "(cached) $ECHO_C" >&6
7366else
7367 cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7368/* confdefs.h. */
7369_ACEOF
7370cat confdefs.h >>conftest.$ac_ext
7371cat >>conftest.$ac_ext <<_ACEOF
7372/* end confdefs.h. */
7862d3a8
AS
7373$ac_includes_default
7374#if HAVE_SYS_SOCKET_H
7375#include <sys/socket.h>
7376#endif
7377#if HAVE_NET_IF_H
96f3a036 7378#include <net/if.h>
7862d3a8 7379#endif
96f3a036
DL
7380
7381int
7382main ()
7383{
7384static struct ifreq ac_aggr;
7385if (ac_aggr.ifr_addr)
7386return 0;
7387 ;
7388 return 0;
7389}
7390_ACEOF
7391rm -f conftest.$ac_objext
7392if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7393 (eval $ac_compile) 2>conftest.er1
96f3a036 7394 ac_status=$?
35996d22
AS
7395 grep -v '^ *+' conftest.er1 >conftest.err
7396 rm -f conftest.er1
7397 cat conftest.err >&5
96f3a036
DL
7398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7399 (exit $ac_status); } &&
4494a266
JD
7400 { ac_try='test -z "$ac_c_werror_flag"
7401 || test ! -s conftest.err'
35996d22
AS
7402 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7403 (eval $ac_try) 2>&5
7404 ac_status=$?
7405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7406 (exit $ac_status); }; } &&
7407 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7408 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7409 (eval $ac_try) 2>&5
7410 ac_status=$?
7411 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7412 (exit $ac_status); }; }; then
7413 ac_cv_member_struct_ifreq_ifr_addr=yes
7414else
7415 echo "$as_me: failed program was:" >&5
7416sed 's/^/| /' conftest.$ac_ext >&5
7417
7418cat >conftest.$ac_ext <<_ACEOF
96f3a036
DL
7419/* confdefs.h. */
7420_ACEOF
7421cat confdefs.h >>conftest.$ac_ext
7422cat >>conftest.$ac_ext <<_ACEOF
7423/* end confdefs.h. */
7862d3a8
AS
7424$ac_includes_default
7425#if HAVE_SYS_SOCKET_H
7426#include <sys/socket.h>
7427#endif
7428#if HAVE_NET_IF_H
96f3a036 7429#include <net/if.h>
7862d3a8 7430#endif
96f3a036
DL
7431
7432int
7433main ()
7434{
7435static struct ifreq ac_aggr;
7436if (sizeof ac_aggr.ifr_addr)
7437return 0;
7438 ;
7439 return 0;
7440}
7441_ACEOF
7442rm -f conftest.$ac_objext
7443if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7444 (eval $ac_compile) 2>conftest.er1
96f3a036 7445 ac_status=$?
35996d22
AS
7446 grep -v '^ *+' conftest.er1 >conftest.err
7447 rm -f conftest.er1
7448 cat conftest.err >&5
96f3a036
DL
7449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7450 (exit $ac_status); } &&
4494a266
JD
7451 { ac_try='test -z "$ac_c_werror_flag"
7452 || test ! -s conftest.err'
35996d22
AS
7453 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7454 (eval $ac_try) 2>&5
7455 ac_status=$?
7456 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7457 (exit $ac_status); }; } &&
7458 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7459 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7460 (eval $ac_try) 2>&5
7461 ac_status=$?
7462 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7463 (exit $ac_status); }; }; then
7464 ac_cv_member_struct_ifreq_ifr_addr=yes
7465else
7466 echo "$as_me: failed program was:" >&5
7467sed 's/^/| /' conftest.$ac_ext >&5
7468
7469ac_cv_member_struct_ifreq_ifr_addr=no
7470fi
35996d22 7471rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036 7472fi
35996d22 7473rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7474fi
7475echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
7476echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6
7477if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
7478
7479cat >>confdefs.h <<_ACEOF
7480#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
7481_ACEOF
7482
7483
7484fi
7485
8799b3e4 7486
8799b3e4 7487
c0d27fcc 7488echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
7489echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
7490if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 7491 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7492echo "${ECHO_T}yes" >&6
7493
c0d27fcc 7494cat >>confdefs.h <<\_ACEOF
98418dba 7495#define PROTOTYPES 1
c0d27fcc
MR
7496_ACEOF
7497
7498
7499cat >>confdefs.h <<\_ACEOF
7500#define __PROTOTYPES 1
7501_ACEOF
98418dba
CW
7502
7503else
c0d27fcc 7504 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7505echo "${ECHO_T}no" >&6
7506fi
7507
c0d27fcc 7508echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
7509echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
7510if test "${ac_cv_c_volatile+set}" = set; then
7511 echo $ECHO_N "(cached) $ECHO_C" >&6
7512else
7513 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7514/* confdefs.h. */
7515_ACEOF
7516cat confdefs.h >>conftest.$ac_ext
7517cat >>conftest.$ac_ext <<_ACEOF
7518/* end confdefs.h. */
98418dba 7519
98418dba
CW
7520int
7521main ()
7522{
7523
7524volatile int x;
7525int * volatile y;
7526 ;
7527 return 0;
7528}
7529_ACEOF
7530rm -f conftest.$ac_objext
c0d27fcc 7531if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7532 (eval $ac_compile) 2>conftest.er1
98418dba 7533 ac_status=$?
35996d22
AS
7534 grep -v '^ *+' conftest.er1 >conftest.err
7535 rm -f conftest.er1
7536 cat conftest.err >&5
c0d27fcc 7537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7538 (exit $ac_status); } &&
4494a266
JD
7539 { ac_try='test -z "$ac_c_werror_flag"
7540 || test ! -s conftest.err'
35996d22
AS
7541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7542 (eval $ac_try) 2>&5
7543 ac_status=$?
7544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7545 (exit $ac_status); }; } &&
7546 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7547 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7548 (eval $ac_try) 2>&5
7549 ac_status=$?
c0d27fcc 7550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7551 (exit $ac_status); }; }; then
7552 ac_cv_c_volatile=yes
7553else
7554 echo "$as_me: failed program was:" >&5
19650fd6
AS
7555sed 's/^/| /' conftest.$ac_ext >&5
7556
98418dba
CW
7557ac_cv_c_volatile=no
7558fi
35996d22 7559rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7560fi
c0d27fcc 7561echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
7562echo "${ECHO_T}$ac_cv_c_volatile" >&6
7563if test $ac_cv_c_volatile = no; then
7564
c0d27fcc 7565cat >>confdefs.h <<\_ACEOF
98418dba 7566#define volatile
c0d27fcc 7567_ACEOF
98418dba
CW
7568
7569fi
7570
c0d27fcc 7571echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
7572echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
7573if test "${ac_cv_c_const+set}" = set; then
7574 echo $ECHO_N "(cached) $ECHO_C" >&6
7575else
7576 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7577/* confdefs.h. */
7578_ACEOF
7579cat confdefs.h >>conftest.$ac_ext
7580cat >>conftest.$ac_ext <<_ACEOF
7581/* end confdefs.h. */
98418dba 7582
98418dba
CW
7583int
7584main ()
7585{
7586/* FIXME: Include the comments suggested by Paul. */
7587#ifndef __cplusplus
7588 /* Ultrix mips cc rejects this. */
7589 typedef int charset[2];
7590 const charset x;
7591 /* SunOS 4.1.1 cc rejects this. */
7592 char const *const *ccp;
7593 char **p;
7594 /* NEC SVR4.0.2 mips cc rejects this. */
7595 struct point {int x, y;};
7596 static struct point const zero = {0,0};
7597 /* AIX XL C 1.02.0.0 rejects this.
7598 It does not let you subtract one const X* pointer from another in
7599 an arm of an if-expression whose if-part is not a constant
7600 expression */
7601 const char *g = "string";
7602 ccp = &g + (g ? g-g : 0);
7603 /* HPUX 7.0 cc rejects these. */
7604 ++ccp;
7605 p = (char**) ccp;
7606 ccp = (char const *const *) p;
7607 { /* SCO 3.2v4 cc rejects this. */
7608 char *t;
7609 char const *s = 0 ? (char *) 0 : (char const *) 0;
7610
7611 *t++ = 0;
7612 }
7613 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7614 int x[] = {25, 17};
7615 const int *foo = &x[0];
7616 ++foo;
7617 }
7618 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7619 typedef const int *iptr;
7620 iptr p = 0;
7621 ++p;
7622 }
7623 { /* AIX XL C 1.02.0.0 rejects this saying
7624 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7625 struct s { int j; const int *ap[3]; };
7626 struct s *b; b->j = 5;
7627 }
7628 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7629 const int foo = 10;
7630 }
7631#endif
7632
7633 ;
7634 return 0;
7635}
7636_ACEOF
7637rm -f conftest.$ac_objext
c0d27fcc 7638if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7639 (eval $ac_compile) 2>conftest.er1
98418dba 7640 ac_status=$?
35996d22
AS
7641 grep -v '^ *+' conftest.er1 >conftest.err
7642 rm -f conftest.er1
7643 cat conftest.err >&5
c0d27fcc 7644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7645 (exit $ac_status); } &&
4494a266
JD
7646 { ac_try='test -z "$ac_c_werror_flag"
7647 || test ! -s conftest.err'
35996d22
AS
7648 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7649 (eval $ac_try) 2>&5
7650 ac_status=$?
7651 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7652 (exit $ac_status); }; } &&
7653 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7654 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7655 (eval $ac_try) 2>&5
7656 ac_status=$?
c0d27fcc 7657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7658 (exit $ac_status); }; }; then
7659 ac_cv_c_const=yes
7660else
7661 echo "$as_me: failed program was:" >&5
19650fd6
AS
7662sed 's/^/| /' conftest.$ac_ext >&5
7663
98418dba
CW
7664ac_cv_c_const=no
7665fi
35996d22 7666rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7667fi
c0d27fcc 7668echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
7669echo "${ECHO_T}$ac_cv_c_const" >&6
7670if test $ac_cv_c_const = no; then
7671
c0d27fcc 7672cat >>confdefs.h <<\_ACEOF
98418dba 7673#define const
c0d27fcc 7674_ACEOF
98418dba
CW
7675
7676fi
7677
c0d27fcc 7678echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
7679echo $ECHO_N "checking for void * support... $ECHO_C" >&6
7680if test "${emacs_cv_void_star+set}" = set; then
7681 echo $ECHO_N "(cached) $ECHO_C" >&6
7682else
7683 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
7684/* confdefs.h. */
7685_ACEOF
7686cat confdefs.h >>conftest.$ac_ext
7687cat >>conftest.$ac_ext <<_ACEOF
7688/* end confdefs.h. */
98418dba 7689
98418dba
CW
7690int
7691main ()
7692{
7693void * foo;
7694 ;
7695 return 0;
7696}
7697_ACEOF
7698rm -f conftest.$ac_objext
c0d27fcc 7699if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 7700 (eval $ac_compile) 2>conftest.er1
98418dba 7701 ac_status=$?
35996d22
AS
7702 grep -v '^ *+' conftest.er1 >conftest.err
7703 rm -f conftest.er1
7704 cat conftest.err >&5
c0d27fcc 7705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7706 (exit $ac_status); } &&
4494a266
JD
7707 { ac_try='test -z "$ac_c_werror_flag"
7708 || test ! -s conftest.err'
35996d22
AS
7709 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7710 (eval $ac_try) 2>&5
7711 ac_status=$?
7712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7713 (exit $ac_status); }; } &&
7714 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7715 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7716 (eval $ac_try) 2>&5
7717 ac_status=$?
c0d27fcc 7718 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7719 (exit $ac_status); }; }; then
7720 emacs_cv_void_star=yes
7721else
7722 echo "$as_me: failed program was:" >&5
19650fd6
AS
7723sed 's/^/| /' conftest.$ac_ext >&5
7724
98418dba
CW
7725emacs_cv_void_star=no
7726fi
35996d22 7727rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 7728fi
c0d27fcc 7729echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
7730echo "${ECHO_T}$emacs_cv_void_star" >&6
7731if test $emacs_cv_void_star = yes; then
c0d27fcc 7732 cat >>confdefs.h <<\_ACEOF
98418dba 7733#define POINTER_TYPE void
c0d27fcc 7734_ACEOF
98418dba
CW
7735
7736else
c0d27fcc 7737 cat >>confdefs.h <<\_ACEOF
98418dba 7738#define POINTER_TYPE char
c0d27fcc 7739_ACEOF
98418dba
CW
7740
7741fi
7742
c0d27fcc 7743
4494a266
JD
7744echo "$as_me:$LINENO: checking whether heap start address is randomized" >&5
7745echo $ECHO_N "checking whether heap start address is randomized... $ECHO_C" >&6
7746if test x"$ac_cv_header_unistd_h" != x && test x"$ac_cv_header_stdlib_h" != x
7747then
7748 if test "$cross_compiling" = yes; then
7749 emacs_cv_execshield='assuming no'
7750else
7751 cat >conftest.$ac_ext <<_ACEOF
7752/* confdefs.h. */
7753_ACEOF
7754cat confdefs.h >>conftest.$ac_ext
7755cat >>conftest.$ac_ext <<_ACEOF
7756/* end confdefs.h. */
7757#include <stdio.h>
7758#include <unistd.h>
7759#include <stdlib.h>
7760int main (int argc, char *argv[])
7761{
7762 unsigned long old_sbrk = 0;
7763 unsigned long this_sbrk = (unsigned long) sbrk(0);
7764 int nr = 1;
7765 if (argc != 1) {
7766 old_sbrk = strtoul (argv[1], 0, 0);
7767 nr = atoi (argv[2])+1;
7768 }
7769 if (argc == 1 || (old_sbrk == this_sbrk && nr < 3))
7770 {
7771 char buf1[32], buf2[32];
7772 sprintf (buf1, "%lu", this_sbrk);
7773 sprintf (buf2, "%d", nr);
7774 execl (argv[0], argv[0], buf1, buf2, 0);
7775 exit (-1);
7776 }
7777 exit (this_sbrk == old_sbrk);
7778}
7779_ACEOF
7780rm -f conftest$ac_exeext
7781if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7782 (eval $ac_link) 2>&5
7783 ac_status=$?
7784 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7785 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7786 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7787 (eval $ac_try) 2>&5
7788 ac_status=$?
7789 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7790 (exit $ac_status); }; }; then
7791 emacs_cv_execshield=yes
7792else
7793 echo "$as_me: program exited with status $ac_status" >&5
7794echo "$as_me: failed program was:" >&5
7795sed 's/^/| /' conftest.$ac_ext >&5
7796
7797( exit $ac_status )
7798emacs_cv_execshield=no
7799fi
7800rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7801fi
7802else
7803 emacs_cv_execshield='assuming no'
7804fi
7805echo "$as_me:$LINENO: result: $emacs_cv_execshield" >&5
7806echo "${ECHO_T}$emacs_cv_execshield" >&6
7807
7808if test "$emacs_cv_execshield" = yes; then
7809 # Extract the first word of "setarch", so it can be a program name with args.
7810set dummy setarch; ac_word=$2
7811echo "$as_me:$LINENO: checking for $ac_word" >&5
7812echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
7813if test "${ac_cv_path_SETARCH+set}" = set; then
7814 echo $ECHO_N "(cached) $ECHO_C" >&6
7815else
7816 case $SETARCH in
7817 [\\/]* | ?:[\\/]*)
7818 ac_cv_path_SETARCH="$SETARCH" # Let the user override the test with a path.
7819 ;;
7820 *)
7821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7822for as_dir in $PATH
7823do
7824 IFS=$as_save_IFS
7825 test -z "$as_dir" && as_dir=.
7826 for ac_exec_ext in '' $ac_executable_extensions; do
7827 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7828 ac_cv_path_SETARCH="$as_dir/$ac_word$ac_exec_ext"
7829 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7830 break 2
7831 fi
7832done
7833done
7834
7835 test -z "$ac_cv_path_SETARCH" && ac_cv_path_SETARCH="no"
7836 ;;
7837esac
7838fi
7839SETARCH=$ac_cv_path_SETARCH
7840
7841if test -n "$SETARCH"; then
7842 echo "$as_me:$LINENO: result: $SETARCH" >&5
7843echo "${ECHO_T}$SETARCH" >&6
7844else
7845 echo "$as_me:$LINENO: result: no" >&5
7846echo "${ECHO_T}no" >&6
7847fi
7848
7849
7850 if test "$SETARCH" != no && test "$machine" = "intel386"; then
7851
7852cat >>confdefs.h <<\_ACEOF
7853#define HAVE_RANDOM_HEAPSTART 1
7854_ACEOF
7855
7856 else
7857 { { echo "$as_me:$LINENO: error: Heap start address is randomized and no workaround is known.
7858Probably exec-shield is turned on. Emacs can not dump itself if this is the
7859case. Read about exec-shield in \`etc/PROBLEMS' for further information." >&5
7860echo "$as_me: error: Heap start address is randomized and no workaround is known.
7861Probably exec-shield is turned on. Emacs can not dump itself if this is the
7862case. Read about exec-shield in \`etc/PROBLEMS' for further information." >&2;}
7863 { (exit 1); exit 1; }; }
7864 fi
7865fi
7866
7867
cd958eb3 7868
19650fd6
AS
7869echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7870echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
35996d22 7871set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'`
98418dba
CW
7872if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
7873 echo $ECHO_N "(cached) $ECHO_C" >&6
7874else
c0d27fcc 7875 cat >conftest.make <<\_ACEOF
98418dba 7876all:
19650fd6 7877 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 7878_ACEOF
98418dba
CW
7879# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7880eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
7881if test -n "$ac_maketemp"; then
7882 eval ac_cv_prog_make_${ac_make}_set=yes
7883else
7884 eval ac_cv_prog_make_${ac_make}_set=no
7885fi
7886rm -f conftest.make
7887fi
7888if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 7889 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7890echo "${ECHO_T}yes" >&6
7891 SET_MAKE=
7892else
c0d27fcc 7893 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7894echo "${ECHO_T}no" >&6
7895 SET_MAKE="MAKE=${MAKE-make}"
7896fi
7897
c0d27fcc
MR
7898
7899echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
7900echo $ECHO_N "checking for long file names... $ECHO_C" >&6
7901if test "${ac_cv_sys_long_file_names+set}" = set; then
7902 echo $ECHO_N "(cached) $ECHO_C" >&6
7903else
7904 ac_cv_sys_long_file_names=yes
7905# Test for long file names in all the places we know might matter:
7906# . the current directory, where building will happen
7907# $prefix/lib where we will be installing things
7908# $exec_prefix/lib likewise
7909# eval it to expand exec_prefix.
7910# $TMPDIR if set, where it might want to write temporary files
7911# if $TMPDIR is not set:
7912# /tmp where it might want to write temporary files
7913# /var/tmp likewise
7914# /usr/tmp likewise
7915if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
7916 ac_tmpdirs=$TMPDIR
7917else
7918 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
7919fi
7920for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
7921 test -d $ac_dir || continue
7922 test -w $ac_dir || continue # It is less confusing to not echo anything here.
7923 ac_xdir=$ac_dir/cf$$
7924 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
7925 ac_tf1=$ac_xdir/conftest9012345
7926 ac_tf2=$ac_xdir/conftest9012346
7927 (echo 1 >$ac_tf1) 2>/dev/null
7928 (echo 2 >$ac_tf2) 2>/dev/null
7929 ac_val=`cat $ac_tf1 2>/dev/null`
7930 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
7931 ac_cv_sys_long_file_names=no
7932 rm -rf $ac_xdir 2>/dev/null
7933 break
7934 fi
7935 rm -rf $ac_xdir 2>/dev/null
7936done
7937fi
c0d27fcc 7938echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
7939echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
7940if test $ac_cv_sys_long_file_names = yes; then
7941
c0d27fcc 7942cat >>confdefs.h <<\_ACEOF
98418dba 7943#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 7944_ACEOF
98418dba
CW
7945
7946fi
7947
c0d27fcc 7948
98418dba
CW
7949#### Choose a window system.
7950
c0d27fcc 7951echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
7952echo $ECHO_N "checking for X... $ECHO_C" >&6
7953
c0d27fcc 7954
98418dba
CW
7955# Check whether --with-x or --without-x was given.
7956if test "${with_x+set}" = set; then
7957 withval="$with_x"
7958
7959fi;
7960# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7961if test "x$with_x" = xno; then
7962 # The user explicitly disabled X.
7963 have_x=disabled
7964else
7965 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7966 # Both variables are already set.
7967 have_x=yes
7968 else
7969 if test "${ac_cv_have_x+set}" = set; then
7970 echo $ECHO_N "(cached) $ECHO_C" >&6
7971else
7972 # One or both of the vars are not set, and there is no cached value.
7973ac_x_includes=no ac_x_libraries=no
7974rm -fr conftest.dir
7975if mkdir conftest.dir; then
7976 cd conftest.dir
7977 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 7978 cat >Imakefile <<'_ACEOF'
98418dba
CW
7979acfindx:
7980 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 7981_ACEOF
98418dba
CW
7982 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7983 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7984 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7985 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7986 for ac_extension in a so sl; do
7987 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
35996d22
AS
7988 test -f $ac_im_libdir/libX11.$ac_extension; then
7989 ac_im_usrlibdir=$ac_im_libdir; break
98418dba
CW
7990 fi
7991 done
7992 # Screen out bogus values from the imake configuration. They are
7993 # bogus both because they are the default anyway, and because
7994 # using them would break gcc on systems where it needs fixed includes.
7995 case $ac_im_incroot in
7996 /usr/include) ;;
7997 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7998 esac
7999 case $ac_im_usrlibdir in
8000 /usr/lib | /lib) ;;
8001 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
8002 esac
8003 fi
8004 cd ..
8005 rm -fr conftest.dir
8006fi
8007
8008# Standard set of common directories for X headers.
8009# Check X11 before X11Rn because it is often a symlink to the current release.
8010ac_x_header_dirs='
8011/usr/X11/include
8012/usr/X11R6/include
8013/usr/X11R5/include
8014/usr/X11R4/include
8015
8016/usr/include/X11
8017/usr/include/X11R6
8018/usr/include/X11R5
8019/usr/include/X11R4
8020
8021/usr/local/X11/include
8022/usr/local/X11R6/include
8023/usr/local/X11R5/include
8024/usr/local/X11R4/include
8025
8026/usr/local/include/X11
8027/usr/local/include/X11R6
8028/usr/local/include/X11R5
8029/usr/local/include/X11R4
8030
8031/usr/X386/include
8032/usr/x386/include
8033/usr/XFree86/include/X11
8034
8035/usr/include
8036/usr/local/include
8037/usr/unsupported/include
8038/usr/athena/include
8039/usr/local/x11r5/include
8040/usr/lpp/Xamples/include
8041
8042/usr/openwin/include
8043/usr/openwin/share/include'
8044
8045if test "$ac_x_includes" = no; then
4494a266 8046 # Guess where to find include files, by looking for Intrinsic.h.
98418dba
CW
8047 # First, try using that file with no special directory specified.
8048 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8049/* confdefs.h. */
8050_ACEOF
8051cat confdefs.h >>conftest.$ac_ext
8052cat >>conftest.$ac_ext <<_ACEOF
8053/* end confdefs.h. */
98418dba
CW
8054#include <X11/Intrinsic.h>
8055_ACEOF
c0d27fcc 8056if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8057 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8058 ac_status=$?
6bae0ccf 8059 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8060 rm -f conftest.er1
8061 cat conftest.err >&5
c0d27fcc 8062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8063 (exit $ac_status); } >/dev/null; then
8064 if test -s conftest.err; then
8065 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 8066 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8067 else
8068 ac_cpp_err=
8069 fi
8070else
8071 ac_cpp_err=yes
8072fi
8073if test -z "$ac_cpp_err"; then
8074 # We can compile using X headers with no special include directory.
8075ac_x_includes=
8076else
8077 echo "$as_me: failed program was:" >&5
19650fd6
AS
8078sed 's/^/| /' conftest.$ac_ext >&5
8079
98418dba
CW
8080 for ac_dir in $ac_x_header_dirs; do
8081 if test -r "$ac_dir/X11/Intrinsic.h"; then
8082 ac_x_includes=$ac_dir
8083 break
8084 fi
8085done
8086fi
8087rm -f conftest.err conftest.$ac_ext
8088fi # $ac_x_includes = no
8089
8090if test "$ac_x_libraries" = no; then
8091 # Check for the libraries.
8092 # See if we find them without any special options.
8093 # Don't add to $LIBS permanently.
8094 ac_save_LIBS=$LIBS
8095 LIBS="-lXt $LIBS"
8096 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8097/* confdefs.h. */
8098_ACEOF
8099cat confdefs.h >>conftest.$ac_ext
8100cat >>conftest.$ac_ext <<_ACEOF
8101/* end confdefs.h. */
98418dba 8102#include <X11/Intrinsic.h>
98418dba
CW
8103int
8104main ()
8105{
8106XtMalloc (0)
8107 ;
8108 return 0;
8109}
8110_ACEOF
8111rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8112if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8113 (eval $ac_link) 2>conftest.er1
98418dba 8114 ac_status=$?
35996d22
AS
8115 grep -v '^ *+' conftest.er1 >conftest.err
8116 rm -f conftest.er1
8117 cat conftest.err >&5
c0d27fcc 8118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8119 (exit $ac_status); } &&
4494a266
JD
8120 { ac_try='test -z "$ac_c_werror_flag"
8121 || test ! -s conftest.err'
35996d22
AS
8122 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8123 (eval $ac_try) 2>&5
8124 ac_status=$?
8125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8126 (exit $ac_status); }; } &&
8127 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8128 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8129 (eval $ac_try) 2>&5
8130 ac_status=$?
c0d27fcc 8131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8132 (exit $ac_status); }; }; then
8133 LIBS=$ac_save_LIBS
8134# We can link X programs with no special library path.
8135ac_x_libraries=
8136else
8137 echo "$as_me: failed program was:" >&5
19650fd6
AS
8138sed 's/^/| /' conftest.$ac_ext >&5
8139
98418dba
CW
8140LIBS=$ac_save_LIBS
8141for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8142do
8143 # Don't even attempt the hair of trying to link an X program!
8144 for ac_extension in a so sl; do
8145 if test -r $ac_dir/libXt.$ac_extension; then
8146 ac_x_libraries=$ac_dir
8147 break 2
8148 fi
8149 done
8150done
8151fi
35996d22
AS
8152rm -f conftest.err conftest.$ac_objext \
8153 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8154fi # $ac_x_libraries = no
8155
8156if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
8157 # Didn't find X anywhere. Cache the known absence of X.
8158 ac_cv_have_x="have_x=no"
8159else
8160 # Record where we found X for the cache.
8161 ac_cv_have_x="have_x=yes \
35996d22 8162 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
98418dba
CW
8163fi
8164fi
8165
8166 fi
8167 eval "$ac_cv_have_x"
8168fi # $with_x != no
8169
8170if test "$have_x" != yes; then
c0d27fcc 8171 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
8172echo "${ECHO_T}$have_x" >&6
8173 no_x=yes
8174else
8175 # If each of the values was on the command line, it overrides each guess.
8176 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8177 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8178 # Update the cache value to reflect the command line values.
8179 ac_cv_have_x="have_x=yes \
8180 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
4494a266
JD
8181 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
8182echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
98418dba
CW
8183fi
8184
8185if test "$no_x" = yes; then
8186 window_system=none
8187else
8188 window_system=x11
8189fi
8190
8191if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8192 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
8193 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
8194 x_default_search_path=""
8195 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
8196 x_search_path="\
8197${x_library}/X11/%L/%T/%N%C%S:\
8198${x_library}/X11/%l/%T/%N%C%S:\
8199${x_library}/X11/%T/%N%C%S:\
8200${x_library}/X11/%L/%T/%N%S:\
8201${x_library}/X11/%l/%T/%N%S:\
8202${x_library}/X11/%T/%N%S"
8203 if test x"${x_default_search_path}" = x; then
8204 x_default_search_path=${x_search_path}
8205 else
8206 x_default_search_path="${x_search_path}:${x_default_search_path}"
8207 fi
8208 done
8209fi
8210if test "${x_includes}" != NONE && test -n "${x_includes}"; then
8211 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
8212fi
8213
8214if test x"${x_includes}" = x; then
8215 bitmapdir=/usr/include/X11/bitmaps
8216else
8217 # accumulate include directories that have X11 bitmap subdirectories
8218 bmd_acc="dummyval"
8219 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
8220 if test -d "${bmd}/X11/bitmaps"; then
8221 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
8222 fi
8223 if test -d "${bmd}/bitmaps"; then
8224 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
8225 fi
8226 done
8227 if test ${bmd_acc} != "dummyval"; then
8228 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
8229 fi
8230fi
8231
8232case "${window_system}" in
8233 x11 )
8234 HAVE_X_WINDOWS=yes
8235 HAVE_X11=yes
8236 case "${with_x_toolkit}" in
8237 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
8238 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
8239 gtk ) with_gtk=yes
8240 USE_X_TOOLKIT=none ;;
98418dba
CW
8241 no ) USE_X_TOOLKIT=none ;;
8242 * ) USE_X_TOOLKIT=maybe ;;
8243 esac
8244 ;;
8245 none )
8246 HAVE_X_WINDOWS=no
8247 HAVE_X11=no
8248 USE_X_TOOLKIT=none
8249 ;;
8250esac
8251
8252### If we're using X11, we should use the X menu package.
8253HAVE_MENUS=no
8254case ${HAVE_X11} in
8255 yes ) HAVE_MENUS=yes ;;
8256esac
8257
8258if test "${opsys}" = "hpux9"; then
8259 case "${x_libraries}" in
8260 *X11R4* )
8261 opsysfile="s/hpux9-x11r4.h"
8262 ;;
8263 esac
8264fi
8265
8266if test "${opsys}" = "hpux9shr"; then
8267 case "${x_libraries}" in
8268 *X11R4* )
8269 opsysfile="s/hpux9shxr4.h"
8270 ;;
8271 esac
8272fi
8273
8274### Compute the unexec source name from the object name.
8275UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
8276
8277# Do the opsystem or machine files prohibit the use of the GNU malloc?
8278# Assume not, until told otherwise.
8279GNU_MALLOC=yes
8280doug_lea_malloc=yes
c0d27fcc 8281echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
8282echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
8283if test "${ac_cv_func_malloc_get_state+set}" = set; then
8284 echo $ECHO_N "(cached) $ECHO_C" >&6
8285else
8286 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8287/* confdefs.h. */
8288_ACEOF
8289cat confdefs.h >>conftest.$ac_ext
8290cat >>conftest.$ac_ext <<_ACEOF
8291/* end confdefs.h. */
35996d22
AS
8292/* Define malloc_get_state to an innocuous variant, in case <limits.h> declares malloc_get_state.
8293 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8294#define malloc_get_state innocuous_malloc_get_state
8295
98418dba 8296/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8297 which can conflict with char malloc_get_state (); below.
8298 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8299 <limits.h> exists even on freestanding compilers. */
35996d22 8300
19650fd6
AS
8301#ifdef __STDC__
8302# include <limits.h>
8303#else
8304# include <assert.h>
8305#endif
35996d22
AS
8306
8307#undef malloc_get_state
8308
98418dba
CW
8309/* Override any gcc2 internal prototype to avoid an error. */
8310#ifdef __cplusplus
8311extern "C"
19650fd6 8312{
98418dba
CW
8313#endif
8314/* We use char because int might match the return type of a gcc2
8315 builtin and then its argument prototype would still apply. */
8316char malloc_get_state ();
98418dba
CW
8317/* The GNU C library defines this for functions which it implements
8318 to always fail with ENOSYS. Some functions are actually named
8319 something starting with __ and the normal name is an alias. */
8320#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
8321choke me
8322#else
19650fd6
AS
8323char (*f) () = malloc_get_state;
8324#endif
8325#ifdef __cplusplus
8326}
98418dba
CW
8327#endif
8328
19650fd6
AS
8329int
8330main ()
8331{
8332return f != malloc_get_state;
98418dba
CW
8333 ;
8334 return 0;
8335}
8336_ACEOF
8337rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8338if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8339 (eval $ac_link) 2>conftest.er1
98418dba 8340 ac_status=$?
35996d22
AS
8341 grep -v '^ *+' conftest.er1 >conftest.err
8342 rm -f conftest.er1
8343 cat conftest.err >&5
c0d27fcc 8344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8345 (exit $ac_status); } &&
4494a266
JD
8346 { ac_try='test -z "$ac_c_werror_flag"
8347 || test ! -s conftest.err'
35996d22
AS
8348 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8349 (eval $ac_try) 2>&5
8350 ac_status=$?
8351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8352 (exit $ac_status); }; } &&
8353 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8354 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8355 (eval $ac_try) 2>&5
8356 ac_status=$?
c0d27fcc 8357 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8358 (exit $ac_status); }; }; then
8359 ac_cv_func_malloc_get_state=yes
8360else
8361 echo "$as_me: failed program was:" >&5
19650fd6
AS
8362sed 's/^/| /' conftest.$ac_ext >&5
8363
98418dba
CW
8364ac_cv_func_malloc_get_state=no
8365fi
35996d22
AS
8366rm -f conftest.err conftest.$ac_objext \
8367 conftest$ac_exeext conftest.$ac_ext
98418dba 8368fi
c0d27fcc 8369echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
8370echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
8371if test $ac_cv_func_malloc_get_state = yes; then
8372 :
8373else
8374 doug_lea_malloc=no
8375fi
8376
c0d27fcc 8377echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
8378echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
8379if test "${ac_cv_func_malloc_set_state+set}" = set; then
8380 echo $ECHO_N "(cached) $ECHO_C" >&6
8381else
8382 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8383/* confdefs.h. */
8384_ACEOF
8385cat confdefs.h >>conftest.$ac_ext
8386cat >>conftest.$ac_ext <<_ACEOF
8387/* end confdefs.h. */
35996d22
AS
8388/* Define malloc_set_state to an innocuous variant, in case <limits.h> declares malloc_set_state.
8389 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8390#define malloc_set_state innocuous_malloc_set_state
8391
98418dba 8392/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8393 which can conflict with char malloc_set_state (); below.
8394 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8395 <limits.h> exists even on freestanding compilers. */
35996d22 8396
19650fd6
AS
8397#ifdef __STDC__
8398# include <limits.h>
8399#else
8400# include <assert.h>
8401#endif
35996d22
AS
8402
8403#undef malloc_set_state
8404
98418dba
CW
8405/* Override any gcc2 internal prototype to avoid an error. */
8406#ifdef __cplusplus
8407extern "C"
19650fd6 8408{
98418dba
CW
8409#endif
8410/* We use char because int might match the return type of a gcc2
8411 builtin and then its argument prototype would still apply. */
8412char malloc_set_state ();
98418dba
CW
8413/* The GNU C library defines this for functions which it implements
8414 to always fail with ENOSYS. Some functions are actually named
8415 something starting with __ and the normal name is an alias. */
8416#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
8417choke me
8418#else
19650fd6
AS
8419char (*f) () = malloc_set_state;
8420#endif
8421#ifdef __cplusplus
8422}
98418dba
CW
8423#endif
8424
19650fd6
AS
8425int
8426main ()
8427{
8428return f != malloc_set_state;
98418dba
CW
8429 ;
8430 return 0;
8431}
8432_ACEOF
8433rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8434if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8435 (eval $ac_link) 2>conftest.er1
98418dba 8436 ac_status=$?
35996d22
AS
8437 grep -v '^ *+' conftest.er1 >conftest.err
8438 rm -f conftest.er1
8439 cat conftest.err >&5
c0d27fcc 8440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8441 (exit $ac_status); } &&
4494a266
JD
8442 { ac_try='test -z "$ac_c_werror_flag"
8443 || test ! -s conftest.err'
35996d22
AS
8444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8445 (eval $ac_try) 2>&5
8446 ac_status=$?
8447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8448 (exit $ac_status); }; } &&
8449 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8450 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8451 (eval $ac_try) 2>&5
8452 ac_status=$?
c0d27fcc 8453 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8454 (exit $ac_status); }; }; then
8455 ac_cv_func_malloc_set_state=yes
8456else
8457 echo "$as_me: failed program was:" >&5
19650fd6
AS
8458sed 's/^/| /' conftest.$ac_ext >&5
8459
98418dba
CW
8460ac_cv_func_malloc_set_state=no
8461fi
35996d22
AS
8462rm -f conftest.err conftest.$ac_objext \
8463 conftest$ac_exeext conftest.$ac_ext
98418dba 8464fi
c0d27fcc 8465echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
8466echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
8467if test $ac_cv_func_malloc_set_state = yes; then
8468 :
8469else
8470 doug_lea_malloc=no
8471fi
8472
c0d27fcc 8473echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
8474echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
8475if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
8476 echo $ECHO_N "(cached) $ECHO_C" >&6
8477else
8478 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8479/* confdefs.h. */
8480_ACEOF
8481cat confdefs.h >>conftest.$ac_ext
8482cat >>conftest.$ac_ext <<_ACEOF
8483/* end confdefs.h. */
98418dba 8484extern void (* __after_morecore_hook)();
98418dba
CW
8485int
8486main ()
8487{
8488__after_morecore_hook = 0
8489 ;
8490 return 0;
8491}
8492_ACEOF
8493rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8494if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8495 (eval $ac_link) 2>conftest.er1
98418dba 8496 ac_status=$?
35996d22
AS
8497 grep -v '^ *+' conftest.er1 >conftest.err
8498 rm -f conftest.er1
8499 cat conftest.err >&5
c0d27fcc 8500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8501 (exit $ac_status); } &&
4494a266
JD
8502 { ac_try='test -z "$ac_c_werror_flag"
8503 || test ! -s conftest.err'
35996d22
AS
8504 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8505 (eval $ac_try) 2>&5
8506 ac_status=$?
8507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8508 (exit $ac_status); }; } &&
8509 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8510 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8511 (eval $ac_try) 2>&5
8512 ac_status=$?
c0d27fcc 8513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8514 (exit $ac_status); }; }; then
8515 emacs_cv_var___after_morecore_hook=yes
8516else
8517 echo "$as_me: failed program was:" >&5
19650fd6
AS
8518sed 's/^/| /' conftest.$ac_ext >&5
8519
98418dba
CW
8520emacs_cv_var___after_morecore_hook=no
8521fi
35996d22
AS
8522rm -f conftest.err conftest.$ac_objext \
8523 conftest$ac_exeext conftest.$ac_ext
98418dba 8524fi
c0d27fcc 8525echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
8526echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
8527if test $emacs_cv_var___after_morecore_hook = no; then
8528 doug_lea_malloc=no
8529fi
8530if test "${system_malloc}" = "yes"; then
8531 GNU_MALLOC=no
8532 GNU_MALLOC_reason="
8533 (The GNU allocators don't work with this system configuration.)"
8534fi
8535if test "$doug_lea_malloc" = "yes" ; then
8536 if test "$GNU_MALLOC" = yes ; then
8537 GNU_MALLOC_reason="
8538 (Using Doug Lea's new malloc from the GNU C Library.)"
8539 fi
b936fae4 8540
c0d27fcc 8541cat >>confdefs.h <<\_ACEOF
98418dba 8542#define DOUG_LEA_MALLOC 1
c0d27fcc 8543_ACEOF
98418dba
CW
8544
8545fi
8546
8547if test x"${REL_ALLOC}" = x; then
8548 REL_ALLOC=${GNU_MALLOC}
8549fi
8550
8551
c0d27fcc
MR
8552
8553
8554for ac_header in stdlib.h unistd.h
98418dba
CW
8555do
8556as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
8557if eval "test \"\${$as_ac_Header+set}\" = set"; then
8558 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
8559echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8560if eval "test \"\${$as_ac_Header+set}\" = set"; then
8561 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8562fi
8563echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8564echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 8565else
c0d27fcc
MR
8566 # Is the header compilable?
8567echo "$as_me:$LINENO: checking $ac_header usability" >&5
8568echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8569cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8570/* confdefs.h. */
8571_ACEOF
8572cat confdefs.h >>conftest.$ac_ext
8573cat >>conftest.$ac_ext <<_ACEOF
8574/* end confdefs.h. */
98418dba
CW
8575$ac_includes_default
8576#include <$ac_header>
8577_ACEOF
8578rm -f conftest.$ac_objext
c0d27fcc 8579if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 8580 (eval $ac_compile) 2>conftest.er1
98418dba 8581 ac_status=$?
35996d22
AS
8582 grep -v '^ *+' conftest.er1 >conftest.err
8583 rm -f conftest.er1
8584 cat conftest.err >&5
c0d27fcc 8585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8586 (exit $ac_status); } &&
4494a266
JD
8587 { ac_try='test -z "$ac_c_werror_flag"
8588 || test ! -s conftest.err'
35996d22
AS
8589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8590 (eval $ac_try) 2>&5
8591 ac_status=$?
8592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8593 (exit $ac_status); }; } &&
8594 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8596 (eval $ac_try) 2>&5
8597 ac_status=$?
c0d27fcc 8598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8599 (exit $ac_status); }; }; then
c0d27fcc 8600 ac_header_compiler=yes
98418dba
CW
8601else
8602 echo "$as_me: failed program was:" >&5
19650fd6
AS
8603sed 's/^/| /' conftest.$ac_ext >&5
8604
c0d27fcc 8605ac_header_compiler=no
98418dba 8606fi
35996d22 8607rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
8608echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8609echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 8610
c0d27fcc
MR
8611# Is the header present?
8612echo "$as_me:$LINENO: checking $ac_header presence" >&5
8613echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8614cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8615/* confdefs.h. */
8616_ACEOF
8617cat confdefs.h >>conftest.$ac_ext
8618cat >>conftest.$ac_ext <<_ACEOF
8619/* end confdefs.h. */
98418dba
CW
8620#include <$ac_header>
8621_ACEOF
c0d27fcc 8622if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8623 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8624 ac_status=$?
6bae0ccf 8625 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8626 rm -f conftest.er1
8627 cat conftest.err >&5
c0d27fcc 8628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8629 (exit $ac_status); } >/dev/null; then
8630 if test -s conftest.err; then
8631 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 8632 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
8633 else
8634 ac_cpp_err=
8635 fi
8636else
8637 ac_cpp_err=yes
8638fi
8639if test -z "$ac_cpp_err"; then
c0d27fcc 8640 ac_header_preproc=yes
98418dba
CW
8641else
8642 echo "$as_me: failed program was:" >&5
19650fd6
AS
8643sed 's/^/| /' conftest.$ac_ext >&5
8644
c0d27fcc 8645 ac_header_preproc=no
98418dba
CW
8646fi
8647rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8648echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8649echo "${ECHO_T}$ac_header_preproc" >&6
8650
8651# So? What about this header?
35996d22
AS
8652case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8653 yes:no: )
c0d27fcc
MR
8654 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8655echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
8656 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8657echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8658 ac_header_preproc=yes
19650fd6 8659 ;;
35996d22 8660 no:yes:* )
c0d27fcc
MR
8661 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8662echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
8663 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8664echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8665 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8666echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8667 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
8668echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 8669 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 8670echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
8671 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8672echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
8673 (
8674 cat <<\_ASBOX
35996d22
AS
8675## ------------------------------------------ ##
8676## Report this to the AC_PACKAGE_NAME lists. ##
8677## ------------------------------------------ ##
19650fd6
AS
8678_ASBOX
8679 ) |
8680 sed "s/^/$as_me: WARNING: /" >&2
8681 ;;
c0d27fcc
MR
8682esac
8683echo "$as_me:$LINENO: checking for $ac_header" >&5
8684echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8685if eval "test \"\${$as_ac_Header+set}\" = set"; then
8686 echo $ECHO_N "(cached) $ECHO_C" >&6
8687else
35996d22 8688 eval "$as_ac_Header=\$ac_header_preproc"
98418dba 8689fi
c0d27fcc 8690echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 8691echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
8692
8693fi
98418dba 8694if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 8695 cat >>confdefs.h <<_ACEOF
98418dba 8696#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 8697_ACEOF
98418dba
CW
8698
8699fi
c0d27fcc 8700
98418dba
CW
8701done
8702
c0d27fcc 8703
98418dba
CW
8704for ac_func in getpagesize
8705do
8706as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8707echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8708echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8709if eval "test \"\${$as_ac_var+set}\" = set"; then
8710 echo $ECHO_N "(cached) $ECHO_C" >&6
8711else
8712 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8713/* confdefs.h. */
8714_ACEOF
8715cat confdefs.h >>conftest.$ac_ext
8716cat >>conftest.$ac_ext <<_ACEOF
8717/* end confdefs.h. */
35996d22
AS
8718/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8719 For example, HP-UX 11i <limits.h> declares gettimeofday. */
8720#define $ac_func innocuous_$ac_func
8721
98418dba 8722/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8723 which can conflict with char $ac_func (); below.
8724 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8725 <limits.h> exists even on freestanding compilers. */
35996d22 8726
19650fd6
AS
8727#ifdef __STDC__
8728# include <limits.h>
8729#else
8730# include <assert.h>
8731#endif
35996d22
AS
8732
8733#undef $ac_func
8734
98418dba
CW
8735/* Override any gcc2 internal prototype to avoid an error. */
8736#ifdef __cplusplus
8737extern "C"
19650fd6 8738{
98418dba
CW
8739#endif
8740/* We use char because int might match the return type of a gcc2
8741 builtin and then its argument prototype would still apply. */
8742char $ac_func ();
98418dba
CW
8743/* The GNU C library defines this for functions which it implements
8744 to always fail with ENOSYS. Some functions are actually named
8745 something starting with __ and the normal name is an alias. */
8746#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8747choke me
8748#else
19650fd6
AS
8749char (*f) () = $ac_func;
8750#endif
8751#ifdef __cplusplus
8752}
98418dba
CW
8753#endif
8754
19650fd6
AS
8755int
8756main ()
8757{
8758return f != $ac_func;
98418dba
CW
8759 ;
8760 return 0;
8761}
8762_ACEOF
8763rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8764if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 8765 (eval $ac_link) 2>conftest.er1
98418dba 8766 ac_status=$?
35996d22
AS
8767 grep -v '^ *+' conftest.er1 >conftest.err
8768 rm -f conftest.er1
8769 cat conftest.err >&5
c0d27fcc 8770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8771 (exit $ac_status); } &&
4494a266
JD
8772 { ac_try='test -z "$ac_c_werror_flag"
8773 || test ! -s conftest.err'
35996d22
AS
8774 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8775 (eval $ac_try) 2>&5
8776 ac_status=$?
8777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8778 (exit $ac_status); }; } &&
8779 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8780 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8781 (eval $ac_try) 2>&5
8782 ac_status=$?
c0d27fcc 8783 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8784 (exit $ac_status); }; }; then
8785 eval "$as_ac_var=yes"
8786else
8787 echo "$as_me: failed program was:" >&5
19650fd6
AS
8788sed 's/^/| /' conftest.$ac_ext >&5
8789
98418dba
CW
8790eval "$as_ac_var=no"
8791fi
35996d22
AS
8792rm -f conftest.err conftest.$ac_objext \
8793 conftest$ac_exeext conftest.$ac_ext
98418dba 8794fi
c0d27fcc 8795echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
8796echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8797if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 8798 cat >>confdefs.h <<_ACEOF
98418dba 8799#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 8800_ACEOF
98418dba
CW
8801
8802fi
8803done
8804
c0d27fcc 8805echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
8806echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
8807if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8808 echo $ECHO_N "(cached) $ECHO_C" >&6
8809else
8810 if test "$cross_compiling" = yes; then
8811 ac_cv_func_mmap_fixed_mapped=no
8812else
8813 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8814/* confdefs.h. */
8815_ACEOF
8816cat confdefs.h >>conftest.$ac_ext
8817cat >>conftest.$ac_ext <<_ACEOF
8818/* end confdefs.h. */
98418dba 8819$ac_includes_default
c0d27fcc
MR
8820/* malloc might have been renamed as rpl_malloc. */
8821#undef malloc
8822
98418dba
CW
8823/* Thanks to Mike Haertel and Jim Avera for this test.
8824 Here is a matrix of mmap possibilities:
8825 mmap private not fixed
8826 mmap private fixed at somewhere currently unmapped
8827 mmap private fixed at somewhere already mapped
8828 mmap shared not fixed
8829 mmap shared fixed at somewhere currently unmapped
8830 mmap shared fixed at somewhere already mapped
8831 For private mappings, we should verify that changes cannot be read()
8832 back from the file, nor mmap's back from the file at a different
8833 address. (There have been systems where private was not correctly
8834 implemented like the infamous i386 svr4.0, and systems where the
8835 VM page cache was not coherent with the file system buffer cache
8836 like early versions of FreeBSD and possibly contemporary NetBSD.)
8837 For shared mappings, we should conversely verify that changes get
c0d27fcc 8838 propagated back to all the places they're supposed to be.
98418dba
CW
8839
8840 Grep wants private fixed already mapped.
8841 The main things grep needs to know about mmap are:
8842 * does it exist and is it safe to write into the mmap'd area
8843 * how to use it (BSD variants) */
8844
8845#include <fcntl.h>
8846#include <sys/mman.h>
8847
8848#if !STDC_HEADERS && !HAVE_STDLIB_H
8849char *malloc ();
8850#endif
8851
8852/* This mess was copied from the GNU getpagesize.h. */
8853#if !HAVE_GETPAGESIZE
8854/* Assume that all systems that can run configure have sys/param.h. */
8855# if !HAVE_SYS_PARAM_H
8856# define HAVE_SYS_PARAM_H 1
8857# endif
8858
8859# ifdef _SC_PAGESIZE
8860# define getpagesize() sysconf(_SC_PAGESIZE)
8861# else /* no _SC_PAGESIZE */
8862# if HAVE_SYS_PARAM_H
8863# include <sys/param.h>
8864# ifdef EXEC_PAGESIZE
8865# define getpagesize() EXEC_PAGESIZE
8866# else /* no EXEC_PAGESIZE */
8867# ifdef NBPG
8868# define getpagesize() NBPG * CLSIZE
8869# ifndef CLSIZE
8870# define CLSIZE 1
8871# endif /* no CLSIZE */
8872# else /* no NBPG */
8873# ifdef NBPC
8874# define getpagesize() NBPC
8875# else /* no NBPC */
8876# ifdef PAGESIZE
8877# define getpagesize() PAGESIZE
8878# endif /* PAGESIZE */
8879# endif /* no NBPC */
8880# endif /* no NBPG */
8881# endif /* no EXEC_PAGESIZE */
8882# else /* no HAVE_SYS_PARAM_H */
8883# define getpagesize() 8192 /* punt totally */
8884# endif /* no HAVE_SYS_PARAM_H */
8885# endif /* no _SC_PAGESIZE */
8886
8887#endif /* no HAVE_GETPAGESIZE */
8888
8889int
8890main ()
8891{
8892 char *data, *data2, *data3;
8893 int i, pagesize;
8894 int fd;
8895
8896 pagesize = getpagesize ();
8897
8898 /* First, make a file with some known garbage in it. */
8899 data = (char *) malloc (pagesize);
8900 if (!data)
8901 exit (1);
8902 for (i = 0; i < pagesize; ++i)
8903 *(data + i) = rand ();
8904 umask (0);
8905 fd = creat ("conftest.mmap", 0600);
8906 if (fd < 0)
8907 exit (1);
8908 if (write (fd, data, pagesize) != pagesize)
8909 exit (1);
8910 close (fd);
8911
8912 /* Next, try to mmap the file at a fixed address which already has
8913 something else allocated at it. If we can, also make sure that
8914 we see the same garbage. */
8915 fd = open ("conftest.mmap", O_RDWR);
8916 if (fd < 0)
8917 exit (1);
8918 data2 = (char *) malloc (2 * pagesize);
8919 if (!data2)
8920 exit (1);
35996d22 8921 data2 += (pagesize - ((long) data2 & (pagesize - 1))) & (pagesize - 1);
98418dba 8922 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
35996d22 8923 MAP_PRIVATE | MAP_FIXED, fd, 0L))
98418dba
CW
8924 exit (1);
8925 for (i = 0; i < pagesize; ++i)
8926 if (*(data + i) != *(data2 + i))
8927 exit (1);
8928
8929 /* Finally, make sure that changes to the mapped area do not
8930 percolate back to the file as seen by read(). (This is a bug on
8931 some variants of i386 svr4.0.) */
8932 for (i = 0; i < pagesize; ++i)
8933 *(data2 + i) = *(data2 + i) + 1;
8934 data3 = (char *) malloc (pagesize);
8935 if (!data3)
8936 exit (1);
8937 if (read (fd, data3, pagesize) != pagesize)
8938 exit (1);
8939 for (i = 0; i < pagesize; ++i)
8940 if (*(data + i) != *(data3 + i))
8941 exit (1);
8942 close (fd);
8943 exit (0);
8944}
8945_ACEOF
8946rm -f conftest$ac_exeext
c0d27fcc 8947if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8948 (eval $ac_link) 2>&5
8949 ac_status=$?
c0d27fcc 8950 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8951 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 8952 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8953 (eval $ac_try) 2>&5
8954 ac_status=$?
c0d27fcc 8955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8956 (exit $ac_status); }; }; then
8957 ac_cv_func_mmap_fixed_mapped=yes
8958else
8959 echo "$as_me: program exited with status $ac_status" >&5
8960echo "$as_me: failed program was:" >&5
19650fd6
AS
8961sed 's/^/| /' conftest.$ac_ext >&5
8962
c0d27fcc 8963( exit $ac_status )
98418dba
CW
8964ac_cv_func_mmap_fixed_mapped=no
8965fi
35996d22 8966rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
8967fi
8968fi
c0d27fcc 8969echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
8970echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
8971if test $ac_cv_func_mmap_fixed_mapped = yes; then
8972
c0d27fcc 8973cat >>confdefs.h <<\_ACEOF
98418dba 8974#define HAVE_MMAP 1
c0d27fcc 8975_ACEOF
98418dba
CW
8976
8977fi
8978rm -f conftest.mmap
8979
8980if test $use_mmap_for_buffers = yes; then
8981 REL_ALLOC=no
8982fi
8983
8984LIBS="$libsrc_libs $LIBS"
8985
c0d27fcc
MR
8986
8987echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
8988echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
8989if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
8990 echo $ECHO_N "(cached) $ECHO_C" >&6
8991else
8992 ac_check_lib_save_LIBS=$LIBS
8993LIBS="-ldnet $LIBS"
8994cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
8995/* confdefs.h. */
8996_ACEOF
8997cat confdefs.h >>conftest.$ac_ext
8998cat >>conftest.$ac_ext <<_ACEOF
8999/* end confdefs.h. */
98418dba
CW
9000
9001/* Override any gcc2 internal prototype to avoid an error. */
9002#ifdef __cplusplus
9003extern "C"
9004#endif
9005/* We use char because int might match the return type of a gcc2
9006 builtin and then its argument prototype would still apply. */
9007char dnet_ntoa ();
98418dba
CW
9008int
9009main ()
9010{
9011dnet_ntoa ();
9012 ;
9013 return 0;
9014}
9015_ACEOF
9016rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9017if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9018 (eval $ac_link) 2>conftest.er1
98418dba 9019 ac_status=$?
35996d22
AS
9020 grep -v '^ *+' conftest.er1 >conftest.err
9021 rm -f conftest.er1
9022 cat conftest.err >&5
c0d27fcc 9023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9024 (exit $ac_status); } &&
4494a266
JD
9025 { ac_try='test -z "$ac_c_werror_flag"
9026 || test ! -s conftest.err'
35996d22
AS
9027 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9028 (eval $ac_try) 2>&5
9029 ac_status=$?
9030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9031 (exit $ac_status); }; } &&
9032 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9034 (eval $ac_try) 2>&5
9035 ac_status=$?
c0d27fcc 9036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9037 (exit $ac_status); }; }; then
9038 ac_cv_lib_dnet_dnet_ntoa=yes
9039else
9040 echo "$as_me: failed program was:" >&5
19650fd6
AS
9041sed 's/^/| /' conftest.$ac_ext >&5
9042
98418dba
CW
9043ac_cv_lib_dnet_dnet_ntoa=no
9044fi
35996d22
AS
9045rm -f conftest.err conftest.$ac_objext \
9046 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9047LIBS=$ac_check_lib_save_LIBS
9048fi
c0d27fcc 9049echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
9050echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9051if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 9052 cat >>confdefs.h <<_ACEOF
98418dba 9053#define HAVE_LIBDNET 1
c0d27fcc 9054_ACEOF
98418dba
CW
9055
9056 LIBS="-ldnet $LIBS"
9057
9058fi
9059
c0d27fcc
MR
9060
9061echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
9062echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
9063if test "${ac_cv_lib_Xbsd_main+set}" = set; then
9064 echo $ECHO_N "(cached) $ECHO_C" >&6
9065else
9066 ac_check_lib_save_LIBS=$LIBS
9067LIBS="-lXbsd $LIBS"
9068cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9069/* confdefs.h. */
9070_ACEOF
9071cat confdefs.h >>conftest.$ac_ext
9072cat >>conftest.$ac_ext <<_ACEOF
9073/* end confdefs.h. */
98418dba 9074
c0d27fcc 9075
98418dba
CW
9076int
9077main ()
9078{
9079main ();
9080 ;
9081 return 0;
9082}
9083_ACEOF
9084rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9085if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9086 (eval $ac_link) 2>conftest.er1
98418dba 9087 ac_status=$?
35996d22
AS
9088 grep -v '^ *+' conftest.er1 >conftest.err
9089 rm -f conftest.er1
9090 cat conftest.err >&5
c0d27fcc 9091 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9092 (exit $ac_status); } &&
4494a266
JD
9093 { ac_try='test -z "$ac_c_werror_flag"
9094 || test ! -s conftest.err'
35996d22
AS
9095 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9096 (eval $ac_try) 2>&5
9097 ac_status=$?
9098 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9099 (exit $ac_status); }; } &&
9100 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9101 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9102 (eval $ac_try) 2>&5
9103 ac_status=$?
c0d27fcc 9104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9105 (exit $ac_status); }; }; then
9106 ac_cv_lib_Xbsd_main=yes
9107else
9108 echo "$as_me: failed program was:" >&5
19650fd6
AS
9109sed 's/^/| /' conftest.$ac_ext >&5
9110
98418dba
CW
9111ac_cv_lib_Xbsd_main=no
9112fi
35996d22
AS
9113rm -f conftest.err conftest.$ac_objext \
9114 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9115LIBS=$ac_check_lib_save_LIBS
9116fi
c0d27fcc 9117echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
9118echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
9119if test $ac_cv_lib_Xbsd_main = yes; then
9120 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9121fi
9122
c0d27fcc
MR
9123
9124
9125echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
9126echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
9127if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
9128 echo $ECHO_N "(cached) $ECHO_C" >&6
9129else
9130 ac_check_lib_save_LIBS=$LIBS
9131LIBS="-lpthreads $LIBS"
9132cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9133/* confdefs.h. */
9134_ACEOF
9135cat confdefs.h >>conftest.$ac_ext
9136cat >>conftest.$ac_ext <<_ACEOF
9137/* end confdefs.h. */
98418dba
CW
9138
9139/* Override any gcc2 internal prototype to avoid an error. */
9140#ifdef __cplusplus
9141extern "C"
9142#endif
9143/* We use char because int might match the return type of a gcc2
9144 builtin and then its argument prototype would still apply. */
9145char cma_open ();
98418dba
CW
9146int
9147main ()
9148{
9149cma_open ();
9150 ;
9151 return 0;
9152}
9153_ACEOF
9154rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9155if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9156 (eval $ac_link) 2>conftest.er1
98418dba 9157 ac_status=$?
35996d22
AS
9158 grep -v '^ *+' conftest.er1 >conftest.err
9159 rm -f conftest.er1
9160 cat conftest.err >&5
c0d27fcc 9161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9162 (exit $ac_status); } &&
4494a266
JD
9163 { ac_try='test -z "$ac_c_werror_flag"
9164 || test ! -s conftest.err'
35996d22
AS
9165 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9166 (eval $ac_try) 2>&5
9167 ac_status=$?
9168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9169 (exit $ac_status); }; } &&
9170 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9171 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9172 (eval $ac_try) 2>&5
9173 ac_status=$?
c0d27fcc 9174 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9175 (exit $ac_status); }; }; then
9176 ac_cv_lib_pthreads_cma_open=yes
9177else
9178 echo "$as_me: failed program was:" >&5
19650fd6
AS
9179sed 's/^/| /' conftest.$ac_ext >&5
9180
98418dba
CW
9181ac_cv_lib_pthreads_cma_open=no
9182fi
35996d22
AS
9183rm -f conftest.err conftest.$ac_objext \
9184 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9185LIBS=$ac_check_lib_save_LIBS
9186fi
c0d27fcc 9187echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
9188echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
9189if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 9190 cat >>confdefs.h <<_ACEOF
98418dba 9191#define HAVE_LIBPTHREADS 1
c0d27fcc 9192_ACEOF
98418dba
CW
9193
9194 LIBS="-lpthreads $LIBS"
9195
9196fi
9197
c0d27fcc
MR
9198
9199echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
9200echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
9201if test -d /usr/X386/include; then
9202 HAVE_XFREE386=yes
9203 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
9204else
9205 HAVE_XFREE386=no
9206fi
c0d27fcc 9207echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
9208echo "${ECHO_T}$HAVE_XFREE386" >&6
9209
55597d70
DL
9210
9211case ${host_os} in
9212aix*)
9213 echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
9214echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
9215if test "${gdb_cv_bigtoc+set}" = set; then
9216 echo $ECHO_N "(cached) $ECHO_C" >&6
9217else
9218
9219 case $GCC in
9220 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
9221 *) gdb_cv_bigtoc=-bbigtoc ;;
9222 esac
9223
9224 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
9225 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9226/* confdefs.h. */
9227_ACEOF
9228cat confdefs.h >>conftest.$ac_ext
9229cat >>conftest.$ac_ext <<_ACEOF
9230/* end confdefs.h. */
55597d70
DL
9231
9232int
9233main ()
9234{
9235int i;
9236 ;
9237 return 0;
9238}
9239_ACEOF
9240rm -f conftest.$ac_objext conftest$ac_exeext
9241if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9242 (eval $ac_link) 2>conftest.er1
55597d70 9243 ac_status=$?
35996d22
AS
9244 grep -v '^ *+' conftest.er1 >conftest.err
9245 rm -f conftest.er1
9246 cat conftest.err >&5
55597d70
DL
9247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9248 (exit $ac_status); } &&
4494a266
JD
9249 { ac_try='test -z "$ac_c_werror_flag"
9250 || test ! -s conftest.err'
35996d22
AS
9251 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9252 (eval $ac_try) 2>&5
9253 ac_status=$?
9254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9255 (exit $ac_status); }; } &&
9256 { ac_try='test -s conftest$ac_exeext'
55597d70
DL
9257 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9258 (eval $ac_try) 2>&5
9259 ac_status=$?
9260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9261 (exit $ac_status); }; }; then
9262 :
9263else
9264 echo "$as_me: failed program was:" >&5
19650fd6
AS
9265sed 's/^/| /' conftest.$ac_ext >&5
9266
55597d70
DL
9267gdb_cv_bigtoc=
9268fi
35996d22
AS
9269rm -f conftest.err conftest.$ac_objext \
9270 conftest$ac_exeext conftest.$ac_ext
55597d70
DL
9271
9272fi
9273echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
9274echo "${ECHO_T}$gdb_cv_bigtoc" >&6
9275 ;;
9276esac
9277
ae1a998c
RS
9278# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
9279# used for the tests that follow. We set them back to REAL_CFLAGS and
9280# REAL_CPPFLAGS later on.
98418dba
CW
9281
9282REAL_CPPFLAGS="$CPPFLAGS"
9283
9284if test "${HAVE_X11}" = "yes"; then
9285 DEFS="$C_SWITCH_X_SITE $DEFS"
9286 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
9287 LIBS="$LIBX $LIBS"
9288 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
9289 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
9290
9291 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
9292 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
9293 # but it's more convenient here to set LD_RUN_PATH
9294 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
9295 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
9296 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
9297 export LD_RUN_PATH
9298 fi
9299
9300 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 9301 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
9302echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
9303 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9304/* confdefs.h. */
9305_ACEOF
9306cat confdefs.h >>conftest.$ac_ext
9307cat >>conftest.$ac_ext <<_ACEOF
9308/* end confdefs.h. */
98418dba 9309
98418dba
CW
9310int
9311main ()
9312{
9313XOpenDisplay ("foo");
9314 ;
9315 return 0;
9316}
9317_ACEOF
9318rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9319if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9320 (eval $ac_link) 2>conftest.er1
98418dba 9321 ac_status=$?
35996d22
AS
9322 grep -v '^ *+' conftest.er1 >conftest.err
9323 rm -f conftest.er1
9324 cat conftest.err >&5
c0d27fcc 9325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9326 (exit $ac_status); } &&
4494a266
JD
9327 { ac_try='test -z "$ac_c_werror_flag"
9328 || test ! -s conftest.err'
c0d27fcc 9329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9330 (eval $ac_try) 2>&5
9331 ac_status=$?
c0d27fcc 9332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
9333 (exit $ac_status); }; } &&
9334 { ac_try='test -s conftest$ac_exeext'
9335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9336 (eval $ac_try) 2>&5
9337 ac_status=$?
9338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9339 (exit $ac_status); }; }; then
9340 xlinux_first_failure=no
98418dba
CW
9341else
9342 echo "$as_me: failed program was:" >&5
19650fd6
AS
9343sed 's/^/| /' conftest.$ac_ext >&5
9344
98418dba
CW
9345xlinux_first_failure=yes
9346fi
35996d22
AS
9347rm -f conftest.err conftest.$ac_objext \
9348 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9349 if test "${xlinux_first_failure}" = "yes"; then
9350 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
9351 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
9352 OLD_CPPFLAGS="$CPPFLAGS"
9353 OLD_LIBS="$LIBS"
9354 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
9355 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
9356 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
9357 LIBS="$LIBS -b i486-linuxaout"
9358 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9359/* confdefs.h. */
9360_ACEOF
9361cat confdefs.h >>conftest.$ac_ext
9362cat >>conftest.$ac_ext <<_ACEOF
9363/* end confdefs.h. */
98418dba 9364
98418dba
CW
9365int
9366main ()
9367{
9368XOpenDisplay ("foo");
9369 ;
9370 return 0;
9371}
9372_ACEOF
9373rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9374if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9375 (eval $ac_link) 2>conftest.er1
98418dba 9376 ac_status=$?
35996d22
AS
9377 grep -v '^ *+' conftest.er1 >conftest.err
9378 rm -f conftest.er1
9379 cat conftest.err >&5
c0d27fcc 9380 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9381 (exit $ac_status); } &&
4494a266
JD
9382 { ac_try='test -z "$ac_c_werror_flag"
9383 || test ! -s conftest.err'
35996d22
AS
9384 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9385 (eval $ac_try) 2>&5
9386 ac_status=$?
9387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9388 (exit $ac_status); }; } &&
9389 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9390 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9391 (eval $ac_try) 2>&5
9392 ac_status=$?
c0d27fcc 9393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9394 (exit $ac_status); }; }; then
9395 xlinux_second_failure=no
9396else
9397 echo "$as_me: failed program was:" >&5
19650fd6
AS
9398sed 's/^/| /' conftest.$ac_ext >&5
9399
98418dba
CW
9400xlinux_second_failure=yes
9401fi
35996d22
AS
9402rm -f conftest.err conftest.$ac_objext \
9403 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9404 if test "${xlinux_second_failure}" = "yes"; then
9405 # If we get the same failure with -b, there is no use adding -b.
9406 # So take it out. This plays safe.
9407 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
9408 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
9409 CPPFLAGS="$OLD_CPPFLAGS"
9410 LIBS="$OLD_LIBS"
c0d27fcc 9411 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9412echo "${ECHO_T}no" >&6
9413 else
c0d27fcc 9414 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9415echo "${ECHO_T}yes" >&6
9416 fi
9417 else
c0d27fcc 9418 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9419echo "${ECHO_T}no" >&6
9420 fi
9421 fi
9422
9423 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
9424 # header files included from there.
c0d27fcc 9425 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
9426echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
9427 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9428/* confdefs.h. */
9429_ACEOF
9430cat confdefs.h >>conftest.$ac_ext
9431cat >>conftest.$ac_ext <<_ACEOF
9432/* end confdefs.h. */
98418dba
CW
9433#include <X11/Xlib.h>
9434#include <X11/XKBlib.h>
98418dba
CW
9435int
9436main ()
9437{
9438XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
9439 ;
9440 return 0;
9441}
9442_ACEOF
9443rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9444if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9445 (eval $ac_link) 2>conftest.er1
98418dba 9446 ac_status=$?
35996d22
AS
9447 grep -v '^ *+' conftest.er1 >conftest.err
9448 rm -f conftest.er1
9449 cat conftest.err >&5
c0d27fcc 9450 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9451 (exit $ac_status); } &&
4494a266
JD
9452 { ac_try='test -z "$ac_c_werror_flag"
9453 || test ! -s conftest.err'
35996d22
AS
9454 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9455 (eval $ac_try) 2>&5
9456 ac_status=$?
9457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9458 (exit $ac_status); }; } &&
9459 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9460 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9461 (eval $ac_try) 2>&5
9462 ac_status=$?
c0d27fcc 9463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9464 (exit $ac_status); }; }; then
9465 emacs_xkb=yes
9466else
9467 echo "$as_me: failed program was:" >&5
19650fd6
AS
9468sed 's/^/| /' conftest.$ac_ext >&5
9469
98418dba
CW
9470emacs_xkb=no
9471fi
35996d22
AS
9472rm -f conftest.err conftest.$ac_objext \
9473 conftest$ac_exeext conftest.$ac_ext
c0d27fcc 9474 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
9475echo "${ECHO_T}$emacs_xkb" >&6
9476 if test $emacs_xkb = yes; then
b936fae4 9477
c0d27fcc 9478cat >>confdefs.h <<\_ACEOF
98418dba 9479#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 9480_ACEOF
98418dba
CW
9481
9482 fi
9483
c0d27fcc
MR
9484
9485
9486
9487
98418dba
CW
9488for ac_func in XrmSetDatabase XScreenResourceString \
9489XScreenNumberOfScreen XSetWMProtocols
9490do
9491as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 9492echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
9493echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9494if eval "test \"\${$as_ac_var+set}\" = set"; then
9495 echo $ECHO_N "(cached) $ECHO_C" >&6
9496else
9497 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9498/* confdefs.h. */
9499_ACEOF
9500cat confdefs.h >>conftest.$ac_ext
9501cat >>conftest.$ac_ext <<_ACEOF
9502/* end confdefs.h. */
35996d22
AS
9503/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9504 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9505#define $ac_func innocuous_$ac_func
9506
98418dba 9507/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
9508 which can conflict with char $ac_func (); below.
9509 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9510 <limits.h> exists even on freestanding compilers. */
35996d22 9511
19650fd6
AS
9512#ifdef __STDC__
9513# include <limits.h>
9514#else
9515# include <assert.h>
9516#endif
35996d22
AS
9517
9518#undef $ac_func
9519
98418dba
CW
9520/* Override any gcc2 internal prototype to avoid an error. */
9521#ifdef __cplusplus
9522extern "C"
19650fd6 9523{
98418dba
CW
9524#endif
9525/* We use char because int might match the return type of a gcc2
9526 builtin and then its argument prototype would still apply. */
9527char $ac_func ();
98418dba
CW
9528/* The GNU C library defines this for functions which it implements
9529 to always fail with ENOSYS. Some functions are actually named
9530 something starting with __ and the normal name is an alias. */
9531#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9532choke me
9533#else
19650fd6
AS
9534char (*f) () = $ac_func;
9535#endif
9536#ifdef __cplusplus
9537}
98418dba
CW
9538#endif
9539
19650fd6
AS
9540int
9541main ()
9542{
9543return f != $ac_func;
98418dba
CW
9544 ;
9545 return 0;
9546}
9547_ACEOF
9548rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9549if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9550 (eval $ac_link) 2>conftest.er1
98418dba 9551 ac_status=$?
35996d22
AS
9552 grep -v '^ *+' conftest.er1 >conftest.err
9553 rm -f conftest.er1
9554 cat conftest.err >&5
c0d27fcc 9555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9556 (exit $ac_status); } &&
4494a266
JD
9557 { ac_try='test -z "$ac_c_werror_flag"
9558 || test ! -s conftest.err'
35996d22
AS
9559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9560 (eval $ac_try) 2>&5
9561 ac_status=$?
9562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9563 (exit $ac_status); }; } &&
9564 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9565 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9566 (eval $ac_try) 2>&5
9567 ac_status=$?
c0d27fcc 9568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9569 (exit $ac_status); }; }; then
9570 eval "$as_ac_var=yes"
9571else
9572 echo "$as_me: failed program was:" >&5
19650fd6
AS
9573sed 's/^/| /' conftest.$ac_ext >&5
9574
98418dba
CW
9575eval "$as_ac_var=no"
9576fi
35996d22
AS
9577rm -f conftest.err conftest.$ac_objext \
9578 conftest$ac_exeext conftest.$ac_ext
98418dba 9579fi
c0d27fcc 9580echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
9581echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9582if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 9583 cat >>confdefs.h <<_ACEOF
98418dba 9584#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 9585_ACEOF
98418dba
CW
9586
9587fi
9588done
9589
9590fi
9591
9592if test "${window_system}" = "x11"; then
c0d27fcc 9593 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
9594echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
9595 if test "${emacs_cv_x11_version_6+set}" = set; then
9596 echo $ECHO_N "(cached) $ECHO_C" >&6
9597else
9598 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9599/* confdefs.h. */
9600_ACEOF
9601cat confdefs.h >>conftest.$ac_ext
9602cat >>conftest.$ac_ext <<_ACEOF
9603/* end confdefs.h. */
98418dba 9604#include <X11/Xlib.h>
98418dba
CW
9605int
9606main ()
9607{
9608#if XlibSpecificationRelease < 6
9609fail;
9610#endif
9611
9612 ;
9613 return 0;
9614}
9615_ACEOF
9616rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9617if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9618 (eval $ac_link) 2>conftest.er1
98418dba 9619 ac_status=$?
35996d22
AS
9620 grep -v '^ *+' conftest.er1 >conftest.err
9621 rm -f conftest.er1
9622 cat conftest.err >&5
c0d27fcc 9623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9624 (exit $ac_status); } &&
4494a266
JD
9625 { ac_try='test -z "$ac_c_werror_flag"
9626 || test ! -s conftest.err'
35996d22
AS
9627 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9628 (eval $ac_try) 2>&5
9629 ac_status=$?
9630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9631 (exit $ac_status); }; } &&
9632 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9633 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9634 (eval $ac_try) 2>&5
9635 ac_status=$?
c0d27fcc 9636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9637 (exit $ac_status); }; }; then
9638 emacs_cv_x11_version_6=yes
9639else
9640 echo "$as_me: failed program was:" >&5
19650fd6
AS
9641sed 's/^/| /' conftest.$ac_ext >&5
9642
98418dba
CW
9643emacs_cv_x11_version_6=no
9644fi
35996d22
AS
9645rm -f conftest.err conftest.$ac_objext \
9646 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9647fi
9648
9649 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 9650 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9651echo "${ECHO_T}6 or newer" >&6
b936fae4 9652
c0d27fcc 9653cat >>confdefs.h <<\_ACEOF
98418dba 9654#define HAVE_X11R6 1
c0d27fcc 9655_ACEOF
98418dba
CW
9656
9657 else
c0d27fcc 9658 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9659echo "${ECHO_T}before 6" >&6
9660 fi
9661fi
9662
9663if test "${window_system}" = "x11"; then
c0d27fcc 9664 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
9665echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
9666 if test "${emacs_cv_x11_version_5+set}" = set; then
9667 echo $ECHO_N "(cached) $ECHO_C" >&6
9668else
9669 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9670/* confdefs.h. */
9671_ACEOF
9672cat confdefs.h >>conftest.$ac_ext
9673cat >>conftest.$ac_ext <<_ACEOF
9674/* end confdefs.h. */
98418dba 9675#include <X11/Xlib.h>
98418dba
CW
9676int
9677main ()
9678{
9679#if XlibSpecificationRelease < 5
9680fail;
9681#endif
9682
9683 ;
9684 return 0;
9685}
9686_ACEOF
9687rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9688if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9689 (eval $ac_link) 2>conftest.er1
98418dba 9690 ac_status=$?
35996d22
AS
9691 grep -v '^ *+' conftest.er1 >conftest.err
9692 rm -f conftest.er1
9693 cat conftest.err >&5
c0d27fcc 9694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9695 (exit $ac_status); } &&
4494a266
JD
9696 { ac_try='test -z "$ac_c_werror_flag"
9697 || test ! -s conftest.err'
35996d22
AS
9698 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9699 (eval $ac_try) 2>&5
9700 ac_status=$?
9701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9702 (exit $ac_status); }; } &&
9703 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9705 (eval $ac_try) 2>&5
9706 ac_status=$?
c0d27fcc 9707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9708 (exit $ac_status); }; }; then
9709 emacs_cv_x11_version_5=yes
9710else
9711 echo "$as_me: failed program was:" >&5
19650fd6
AS
9712sed 's/^/| /' conftest.$ac_ext >&5
9713
98418dba
CW
9714emacs_cv_x11_version_5=no
9715fi
35996d22
AS
9716rm -f conftest.err conftest.$ac_objext \
9717 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9718fi
9719
9720 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 9721 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
9722echo "${ECHO_T}5 or newer" >&6
9723 HAVE_X11R5=yes
b936fae4 9724
c0d27fcc 9725cat >>confdefs.h <<\_ACEOF
98418dba 9726#define HAVE_X11R5 1
c0d27fcc 9727_ACEOF
98418dba
CW
9728
9729 else
9730 HAVE_X11R5=no
c0d27fcc 9731 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
9732echo "${ECHO_T}before 5" >&6
9733 fi
9734fi
9735
488dd4c4
JD
9736
9737
9738HAVE_GTK=no
9739if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 9740 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
9741 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
9742echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
9743 { (exit 1); exit 1; }; };
9744 fi
9745 GLIB_REQUIRED=2.0.1
e512ece1 9746 GTK_REQUIRED=2.0.1
488dd4c4
JD
9747 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
9748
9749 if test "X${with_pkg_config_prog}" != X; then
9750 PKG_CONFIG="${with_pkg_config_prog}"
9751 fi
9752
9753 succeeded=no
9754
9755 if test -z "$PKG_CONFIG"; then
9756 # Extract the first word of "pkg-config", so it can be a program name with args.
9757set dummy pkg-config; ac_word=$2
9758echo "$as_me:$LINENO: checking for $ac_word" >&5
9759echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9760if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9761 echo $ECHO_N "(cached) $ECHO_C" >&6
9762else
9763 case $PKG_CONFIG in
9764 [\\/]* | ?:[\\/]*)
9765 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9766 ;;
9767 *)
9768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9769for as_dir in $PATH
9770do
9771 IFS=$as_save_IFS
9772 test -z "$as_dir" && as_dir=.
9773 for ac_exec_ext in '' $ac_executable_extensions; do
9774 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9775 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9776 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9777 break 2
9778 fi
9779done
9780done
9781
9782 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9783 ;;
9784esac
9785fi
9786PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9787
9788if test -n "$PKG_CONFIG"; then
9789 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
9790echo "${ECHO_T}$PKG_CONFIG" >&6
9791else
9792 echo "$as_me:$LINENO: result: no" >&5
9793echo "${ECHO_T}no" >&6
9794fi
9795
9796 fi
9797
9798 if test "$PKG_CONFIG" = "no" ; then
9799 echo "*** The pkg-config script could not be found. Make sure it is"
9800 echo "*** in your path, or give the full path to pkg-config with"
9801 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
9802 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
9803 else
9804 PKG_CONFIG_MIN_VERSION=0.9.0
9805 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9806 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
9807echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
9808
9809 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
9810 echo "$as_me:$LINENO: result: yes" >&5
9811echo "${ECHO_T}yes" >&6
9812 succeeded=yes
9813
9814 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
9815echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
9816 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
9817 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
9818echo "${ECHO_T}$GTK_CFLAGS" >&6
9819
9820 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
9821echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
9822 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
9823 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
9824echo "${ECHO_T}$GTK_LIBS" >&6
9825 else
9826 GTK_CFLAGS=""
9827 GTK_LIBS=""
9828 ## If we have a custom action on failure, don't print errors, but
9829 ## do set a variable so people can do so.
9830 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
9831 echo $GTK_PKG_ERRORS
9832 fi
9833
9834
9835
9836 else
9837 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9838 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9839 fi
9840 fi
9841
9842 if test $succeeded = yes; then
9843 :
9844 else
9845 { { 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
9846echo "$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;}
9847 { (exit 1); exit 1; }; }
9848 fi
9849
9850
9851
9852 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
57669b57
JD
9853 CFLAGS="$CFLAGS $GTK_CFLAGS"
9854 LIBS="$GTK_LIBS $LIBS"
488dd4c4
JD
9855 HAVE_GTK=yes
9856
9857cat >>confdefs.h <<\_ACEOF
9858#define HAVE_GTK 1
9859_ACEOF
9860
9861 USE_X_TOOLKIT=none
9862
9863 with_toolkit_scroll_bars=yes
57669b57
JD
9864
9865 HAVE_GTK_MULTIDISPLAY=no
9866
9867for ac_func in gdk_display_open
9868do
9869as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9870echo "$as_me:$LINENO: checking for $ac_func" >&5
9871echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9872if eval "test \"\${$as_ac_var+set}\" = set"; then
9873 echo $ECHO_N "(cached) $ECHO_C" >&6
9874else
9875 cat >conftest.$ac_ext <<_ACEOF
57669b57
JD
9876/* confdefs.h. */
9877_ACEOF
9878cat confdefs.h >>conftest.$ac_ext
9879cat >>conftest.$ac_ext <<_ACEOF
9880/* end confdefs.h. */
35996d22
AS
9881/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9882 For example, HP-UX 11i <limits.h> declares gettimeofday. */
9883#define $ac_func innocuous_$ac_func
9884
57669b57
JD
9885/* System header to define __stub macros and hopefully few prototypes,
9886 which can conflict with char $ac_func (); below.
9887 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9888 <limits.h> exists even on freestanding compilers. */
35996d22 9889
57669b57
JD
9890#ifdef __STDC__
9891# include <limits.h>
9892#else
9893# include <assert.h>
9894#endif
35996d22
AS
9895
9896#undef $ac_func
9897
57669b57
JD
9898/* Override any gcc2 internal prototype to avoid an error. */
9899#ifdef __cplusplus
9900extern "C"
9901{
9902#endif
9903/* We use char because int might match the return type of a gcc2
9904 builtin and then its argument prototype would still apply. */
9905char $ac_func ();
9906/* The GNU C library defines this for functions which it implements
9907 to always fail with ENOSYS. Some functions are actually named
9908 something starting with __ and the normal name is an alias. */
9909#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9910choke me
9911#else
9912char (*f) () = $ac_func;
9913#endif
9914#ifdef __cplusplus
9915}
9916#endif
9917
9918int
9919main ()
9920{
9921return f != $ac_func;
9922 ;
9923 return 0;
9924}
9925_ACEOF
9926rm -f conftest.$ac_objext conftest$ac_exeext
9927if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 9928 (eval $ac_link) 2>conftest.er1
57669b57 9929 ac_status=$?
35996d22
AS
9930 grep -v '^ *+' conftest.er1 >conftest.err
9931 rm -f conftest.er1
9932 cat conftest.err >&5
57669b57
JD
9933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9934 (exit $ac_status); } &&
4494a266
JD
9935 { ac_try='test -z "$ac_c_werror_flag"
9936 || test ! -s conftest.err'
35996d22
AS
9937 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9938 (eval $ac_try) 2>&5
9939 ac_status=$?
9940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9941 (exit $ac_status); }; } &&
9942 { ac_try='test -s conftest$ac_exeext'
57669b57
JD
9943 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9944 (eval $ac_try) 2>&5
9945 ac_status=$?
9946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9947 (exit $ac_status); }; }; then
9948 eval "$as_ac_var=yes"
9949else
9950 echo "$as_me: failed program was:" >&5
9951sed 's/^/| /' conftest.$ac_ext >&5
9952
9953eval "$as_ac_var=no"
9954fi
35996d22
AS
9955rm -f conftest.err conftest.$ac_objext \
9956 conftest$ac_exeext conftest.$ac_ext
57669b57
JD
9957fi
9958echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9959echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9960if test `eval echo '${'$as_ac_var'}'` = yes; then
9961 cat >>confdefs.h <<_ACEOF
9962#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9963_ACEOF
9964 HAVE_GTK_MULTIDISPLAY=yes
9965fi
9966done
9967
9968 if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
9969
9970cat >>confdefs.h <<\_ACEOF
9971#define HAVE_GTK_MULTIDISPLAY 1
9972_ACEOF
9973
9974 fi
488dd4c4
JD
9975fi
9976
98418dba
CW
9977if test x"${USE_X_TOOLKIT}" = xmaybe; then
9978 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 9979 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
9980echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
9981 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
9982 echo $ECHO_N "(cached) $ECHO_C" >&6
9983else
9984 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
9985/* confdefs.h. */
9986_ACEOF
9987cat confdefs.h >>conftest.$ac_ext
9988cat >>conftest.$ac_ext <<_ACEOF
9989/* end confdefs.h. */
98418dba
CW
9990
9991#include <X11/Intrinsic.h>
9992#include <X11/Xaw/Simple.h>
98418dba
CW
9993int
9994main ()
9995{
9996
9997 ;
9998 return 0;
9999}
10000_ACEOF
10001rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10002if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10003 (eval $ac_link) 2>conftest.er1
98418dba 10004 ac_status=$?
35996d22
AS
10005 grep -v '^ *+' conftest.er1 >conftest.err
10006 rm -f conftest.er1
10007 cat conftest.err >&5
c0d27fcc 10008 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10009 (exit $ac_status); } &&
4494a266
JD
10010 { ac_try='test -z "$ac_c_werror_flag"
10011 || test ! -s conftest.err'
35996d22
AS
10012 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10013 (eval $ac_try) 2>&5
10014 ac_status=$?
10015 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10016 (exit $ac_status); }; } &&
10017 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10018 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10019 (eval $ac_try) 2>&5
10020 ac_status=$?
c0d27fcc 10021 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10022 (exit $ac_status); }; }; then
10023 emacs_cv_x11_version_5_with_xaw=yes
10024else
10025 echo "$as_me: failed program was:" >&5
19650fd6
AS
10026sed 's/^/| /' conftest.$ac_ext >&5
10027
98418dba
CW
10028emacs_cv_x11_version_5_with_xaw=no
10029fi
35996d22
AS
10030rm -f conftest.err conftest.$ac_objext \
10031 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10032fi
10033
10034 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 10035 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
10036echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
10037 USE_X_TOOLKIT=LUCID
10038 else
c0d27fcc 10039 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
10040echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
10041 USE_X_TOOLKIT=none
10042 fi
10043 else
10044 USE_X_TOOLKIT=none
10045 fi
10046fi
10047
10048X_TOOLKIT_TYPE=$USE_X_TOOLKIT
10049
10050if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 10051 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
10052echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
10053 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
10054 echo $ECHO_N "(cached) $ECHO_C" >&6
10055else
10056 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10057/* confdefs.h. */
10058_ACEOF
10059cat confdefs.h >>conftest.$ac_ext
10060cat >>conftest.$ac_ext <<_ACEOF
10061/* end confdefs.h. */
98418dba 10062#include <X11/Intrinsic.h>
98418dba
CW
10063int
10064main ()
10065{
10066#if XtSpecificationRelease < 6
10067fail;
10068#endif
10069
10070 ;
10071 return 0;
10072}
10073_ACEOF
10074rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10075if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10076 (eval $ac_link) 2>conftest.er1
98418dba 10077 ac_status=$?
35996d22
AS
10078 grep -v '^ *+' conftest.er1 >conftest.err
10079 rm -f conftest.er1
10080 cat conftest.err >&5
c0d27fcc 10081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10082 (exit $ac_status); } &&
4494a266
JD
10083 { ac_try='test -z "$ac_c_werror_flag"
10084 || test ! -s conftest.err'
35996d22
AS
10085 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10086 (eval $ac_try) 2>&5
10087 ac_status=$?
10088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10089 (exit $ac_status); }; } &&
10090 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10091 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10092 (eval $ac_try) 2>&5
10093 ac_status=$?
c0d27fcc 10094 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10095 (exit $ac_status); }; }; then
10096 emacs_cv_x11_toolkit_version_6=yes
10097else
10098 echo "$as_me: failed program was:" >&5
19650fd6
AS
10099sed 's/^/| /' conftest.$ac_ext >&5
10100
98418dba
CW
10101emacs_cv_x11_toolkit_version_6=no
10102fi
35996d22
AS
10103rm -f conftest.err conftest.$ac_objext \
10104 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10105fi
10106
10107 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
10108 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 10109 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 10110echo "${ECHO_T}6 or newer" >&6
b936fae4 10111
c0d27fcc 10112cat >>confdefs.h <<\_ACEOF
98418dba 10113#define HAVE_X11XTR6 1
c0d27fcc 10114_ACEOF
98418dba
CW
10115
10116 else
c0d27fcc 10117 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
10118echo "${ECHO_T}before 6" >&6
10119 fi
10120
10121 OLDLIBS="$LIBS"
10122 if test x$HAVE_X11XTR6 = xyes; then
10123 LIBS="-lXt -lSM -lICE $LIBS"
10124 else
10125 LIBS="-lXt $LIBS"
10126 fi
10127
c0d27fcc 10128echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
10129echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
10130if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
10131 echo $ECHO_N "(cached) $ECHO_C" >&6
10132else
10133 ac_check_lib_save_LIBS=$LIBS
10134LIBS="-lXmu $LIBS"
10135cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10136/* confdefs.h. */
10137_ACEOF
10138cat confdefs.h >>conftest.$ac_ext
10139cat >>conftest.$ac_ext <<_ACEOF
10140/* end confdefs.h. */
98418dba
CW
10141
10142/* Override any gcc2 internal prototype to avoid an error. */
10143#ifdef __cplusplus
10144extern "C"
10145#endif
10146/* We use char because int might match the return type of a gcc2
10147 builtin and then its argument prototype would still apply. */
10148char XmuConvertStandardSelection ();
98418dba
CW
10149int
10150main ()
10151{
10152XmuConvertStandardSelection ();
10153 ;
10154 return 0;
10155}
10156_ACEOF
10157rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10158if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10159 (eval $ac_link) 2>conftest.er1
98418dba 10160 ac_status=$?
35996d22
AS
10161 grep -v '^ *+' conftest.er1 >conftest.err
10162 rm -f conftest.er1
10163 cat conftest.err >&5
c0d27fcc 10164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10165 (exit $ac_status); } &&
4494a266
JD
10166 { ac_try='test -z "$ac_c_werror_flag"
10167 || test ! -s conftest.err'
35996d22
AS
10168 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10169 (eval $ac_try) 2>&5
10170 ac_status=$?
10171 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10172 (exit $ac_status); }; } &&
10173 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10175 (eval $ac_try) 2>&5
10176 ac_status=$?
c0d27fcc 10177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10178 (exit $ac_status); }; }; then
10179 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
10180else
10181 echo "$as_me: failed program was:" >&5
19650fd6
AS
10182sed 's/^/| /' conftest.$ac_ext >&5
10183
98418dba
CW
10184ac_cv_lib_Xmu_XmuConvertStandardSelection=no
10185fi
35996d22
AS
10186rm -f conftest.err conftest.$ac_objext \
10187 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10188LIBS=$ac_check_lib_save_LIBS
10189fi
c0d27fcc 10190echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
10191echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
10192if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 10193 cat >>confdefs.h <<_ACEOF
98418dba 10194#define HAVE_LIBXMU 1
c0d27fcc 10195_ACEOF
98418dba
CW
10196
10197 LIBS="-lXmu $LIBS"
10198
10199fi
10200
10201 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
10202fi
10203
10204# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
10205if test "${HAVE_X11}" = "yes"; then
10206 if test "${USE_X_TOOLKIT}" != "none"; then
10207
c0d27fcc 10208echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
10209echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
10210if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
10211 echo $ECHO_N "(cached) $ECHO_C" >&6
10212else
10213 ac_check_lib_save_LIBS=$LIBS
10214LIBS="-lXext $LIBS"
10215cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10216/* confdefs.h. */
10217_ACEOF
10218cat confdefs.h >>conftest.$ac_ext
10219cat >>conftest.$ac_ext <<_ACEOF
10220/* end confdefs.h. */
98418dba
CW
10221
10222/* Override any gcc2 internal prototype to avoid an error. */
10223#ifdef __cplusplus
10224extern "C"
10225#endif
10226/* We use char because int might match the return type of a gcc2
10227 builtin and then its argument prototype would still apply. */
10228char XShapeQueryExtension ();
98418dba
CW
10229int
10230main ()
10231{
10232XShapeQueryExtension ();
10233 ;
10234 return 0;
10235}
10236_ACEOF
10237rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10238if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10239 (eval $ac_link) 2>conftest.er1
98418dba 10240 ac_status=$?
35996d22
AS
10241 grep -v '^ *+' conftest.er1 >conftest.err
10242 rm -f conftest.er1
10243 cat conftest.err >&5
c0d27fcc 10244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10245 (exit $ac_status); } &&
4494a266
JD
10246 { ac_try='test -z "$ac_c_werror_flag"
10247 || test ! -s conftest.err'
35996d22
AS
10248 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10249 (eval $ac_try) 2>&5
10250 ac_status=$?
10251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10252 (exit $ac_status); }; } &&
10253 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10254 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10255 (eval $ac_try) 2>&5
10256 ac_status=$?
c0d27fcc 10257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10258 (exit $ac_status); }; }; then
10259 ac_cv_lib_Xext_XShapeQueryExtension=yes
10260else
10261 echo "$as_me: failed program was:" >&5
19650fd6
AS
10262sed 's/^/| /' conftest.$ac_ext >&5
10263
98418dba
CW
10264ac_cv_lib_Xext_XShapeQueryExtension=no
10265fi
35996d22
AS
10266rm -f conftest.err conftest.$ac_objext \
10267 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10268LIBS=$ac_check_lib_save_LIBS
10269fi
c0d27fcc 10270echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
10271echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
10272if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 10273 cat >>confdefs.h <<_ACEOF
98418dba 10274#define HAVE_LIBXEXT 1
c0d27fcc 10275_ACEOF
98418dba
CW
10276
10277 LIBS="-lXext $LIBS"
10278
10279fi
10280
10281 fi
10282fi
10283
10284if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10285 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
8e967cf7
MR
10286echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
10287if test "${emacs_cv_lesstif+set}" = set; then
10288 echo $ECHO_N "(cached) $ECHO_C" >&6
10289else
ae1a998c
RS
10290 # We put this in CFLAGS temporarily to precede other -I options
10291 # that might be in CFLAGS temporarily.
10292 # We put this in CPPFLAGS where it precedes the other -I options.
10293 OLD_CPPFLAGS=$CPPFLAGS
10294 OLD_CFLAGS=$CFLAGS
10295 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
10296 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
8e967cf7 10297 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10298/* confdefs.h. */
10299_ACEOF
10300cat confdefs.h >>conftest.$ac_ext
10301cat >>conftest.$ac_ext <<_ACEOF
10302/* end confdefs.h. */
8e967cf7
MR
10303#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
10304int
10305main ()
10306{
10307int x = 5;
10308 ;
10309 return 0;
10310}
10311_ACEOF
10312rm -f conftest.$ac_objext
c0d27fcc 10313if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10314 (eval $ac_compile) 2>conftest.er1
8e967cf7 10315 ac_status=$?
35996d22
AS
10316 grep -v '^ *+' conftest.er1 >conftest.err
10317 rm -f conftest.er1
10318 cat conftest.err >&5
c0d27fcc 10319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7 10320 (exit $ac_status); } &&
4494a266
JD
10321 { ac_try='test -z "$ac_c_werror_flag"
10322 || test ! -s conftest.err'
35996d22
AS
10323 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10324 (eval $ac_try) 2>&5
10325 ac_status=$?
10326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10327 (exit $ac_status); }; } &&
10328 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8e967cf7
MR
10330 (eval $ac_try) 2>&5
10331 ac_status=$?
c0d27fcc 10332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
10333 (exit $ac_status); }; }; then
10334 emacs_cv_lesstif=yes
10335else
10336 echo "$as_me: failed program was:" >&5
19650fd6
AS
10337sed 's/^/| /' conftest.$ac_ext >&5
10338
8e967cf7
MR
10339emacs_cv_lesstif=no
10340fi
35996d22 10341rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8e967cf7 10342fi
c0d27fcc 10343echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
8e967cf7
MR
10344echo "${ECHO_T}$emacs_cv_lesstif" >&6
10345 if test $emacs_cv_lesstif = yes; then
ae1a998c
RS
10346 # Make sure this -I option remains in CPPFLAGS after it is set
10347 # back to REAL_CPPFLAGS.
10348 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
10349 # have those other -I options anyway. Ultimately, having this
10350 # directory ultimately in CPPFLAGS will be enough.
10351 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
8e967cf7 10352 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
ae1a998c
RS
10353 else
10354 CFLAGS=$OLD_CFLAGS
10355 CPPFLAGS=$OLD_CPPFLAGS
8e967cf7 10356 fi
c0d27fcc 10357 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
10358echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
10359if test "${emacs_cv_motif_version_2_1+set}" = set; then
10360 echo $ECHO_N "(cached) $ECHO_C" >&6
10361else
10362 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10363/* confdefs.h. */
10364_ACEOF
10365cat confdefs.h >>conftest.$ac_ext
10366cat >>conftest.$ac_ext <<_ACEOF
10367/* end confdefs.h. */
98418dba 10368#include <Xm/Xm.h>
98418dba
CW
10369int
10370main ()
10371{
10372#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
10373int x = 5;
10374#else
10375Motif version prior to 2.1.
10376#endif
10377 ;
10378 return 0;
10379}
10380_ACEOF
10381rm -f conftest.$ac_objext
c0d27fcc 10382if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10383 (eval $ac_compile) 2>conftest.er1
98418dba 10384 ac_status=$?
35996d22
AS
10385 grep -v '^ *+' conftest.er1 >conftest.err
10386 rm -f conftest.er1
10387 cat conftest.err >&5
c0d27fcc 10388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10389 (exit $ac_status); } &&
4494a266
JD
10390 { ac_try='test -z "$ac_c_werror_flag"
10391 || test ! -s conftest.err'
35996d22
AS
10392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10393 (eval $ac_try) 2>&5
10394 ac_status=$?
10395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10396 (exit $ac_status); }; } &&
10397 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10398 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10399 (eval $ac_try) 2>&5
10400 ac_status=$?
c0d27fcc 10401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10402 (exit $ac_status); }; }; then
10403 emacs_cv_motif_version_2_1=yes
10404else
10405 echo "$as_me: failed program was:" >&5
19650fd6
AS
10406sed 's/^/| /' conftest.$ac_ext >&5
10407
98418dba
CW
10408emacs_cv_motif_version_2_1=no
10409fi
35996d22 10410rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
98418dba 10411fi
c0d27fcc 10412echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
10413echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
10414 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
10415 if test $emacs_cv_motif_version_2_1 = yes; then
10416 HAVE_LIBXP=no
b936fae4 10417
c0d27fcc 10418cat >>confdefs.h <<\_ACEOF
98418dba 10419#define HAVE_MOTIF_2_1 1
c0d27fcc 10420_ACEOF
98418dba 10421
c0d27fcc 10422 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
10423echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
10424if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
10425 echo $ECHO_N "(cached) $ECHO_C" >&6
10426else
10427 ac_check_lib_save_LIBS=$LIBS
10428LIBS="-lXp $LIBS"
10429cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10430/* confdefs.h. */
10431_ACEOF
10432cat confdefs.h >>conftest.$ac_ext
10433cat >>conftest.$ac_ext <<_ACEOF
10434/* end confdefs.h. */
98418dba
CW
10435
10436/* Override any gcc2 internal prototype to avoid an error. */
10437#ifdef __cplusplus
10438extern "C"
10439#endif
10440/* We use char because int might match the return type of a gcc2
10441 builtin and then its argument prototype would still apply. */
10442char XpCreateContext ();
98418dba
CW
10443int
10444main ()
10445{
10446XpCreateContext ();
10447 ;
10448 return 0;
10449}
10450_ACEOF
10451rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10452if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10453 (eval $ac_link) 2>conftest.er1
98418dba 10454 ac_status=$?
35996d22
AS
10455 grep -v '^ *+' conftest.er1 >conftest.err
10456 rm -f conftest.er1
10457 cat conftest.err >&5
c0d27fcc 10458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10459 (exit $ac_status); } &&
4494a266
JD
10460 { ac_try='test -z "$ac_c_werror_flag"
10461 || test ! -s conftest.err'
35996d22
AS
10462 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10463 (eval $ac_try) 2>&5
10464 ac_status=$?
10465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10466 (exit $ac_status); }; } &&
10467 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10468 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10469 (eval $ac_try) 2>&5
10470 ac_status=$?
c0d27fcc 10471 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10472 (exit $ac_status); }; }; then
10473 ac_cv_lib_Xp_XpCreateContext=yes
10474else
10475 echo "$as_me: failed program was:" >&5
19650fd6
AS
10476sed 's/^/| /' conftest.$ac_ext >&5
10477
98418dba
CW
10478ac_cv_lib_Xp_XpCreateContext=no
10479fi
35996d22
AS
10480rm -f conftest.err conftest.$ac_objext \
10481 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10482LIBS=$ac_check_lib_save_LIBS
10483fi
c0d27fcc 10484echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
10485echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
10486if test $ac_cv_lib_Xp_XpCreateContext = yes; then
10487 HAVE_LIBXP=yes
10488fi
503d2be0 10489
98418dba 10490 if test ${HAVE_LIBXP} = yes; then
b936fae4 10491
c0d27fcc 10492cat >>confdefs.h <<\_ACEOF
98418dba 10493#define HAVE_LIBXP 1
c0d27fcc 10494_ACEOF
503d2be0 10495
98418dba
CW
10496 fi
10497 fi
10498fi
10499
10500### Is -lXaw3d available?
10501HAVE_XAW3D=no
10502if test "${HAVE_X11}" = "yes"; then
10503 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 10504 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
10505echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
10506if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
10507 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 10508else
22044edf 10509 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10510/* confdefs.h. */
10511_ACEOF
10512cat confdefs.h >>conftest.$ac_ext
10513cat >>conftest.$ac_ext <<_ACEOF
10514/* end confdefs.h. */
98418dba 10515#include <X11/Xaw3d/Scrollbar.h>
503d2be0 10516_ACEOF
c0d27fcc 10517if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
10518 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10519 ac_status=$?
6bae0ccf 10520 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
10521 rm -f conftest.er1
10522 cat conftest.err >&5
c0d27fcc 10523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10524 (exit $ac_status); } >/dev/null; then
10525 if test -s conftest.err; then
10526 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10527 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
10528 else
10529 ac_cpp_err=
10530 fi
10531else
10532 ac_cpp_err=yes
10533fi
10534if test -z "$ac_cpp_err"; then
22044edf 10535 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 10536else
503d2be0 10537 echo "$as_me: failed program was:" >&5
19650fd6
AS
10538sed 's/^/| /' conftest.$ac_ext >&5
10539
22044edf 10540 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 10541fi
503d2be0 10542rm -f conftest.err conftest.$ac_ext
98418dba 10543fi
c0d27fcc 10544echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 10545echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 10546if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 10547 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
10548echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
10549if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
10550 echo $ECHO_N "(cached) $ECHO_C" >&6
10551else
10552 ac_check_lib_save_LIBS=$LIBS
10553LIBS="-lXaw3d $LIBS"
10554cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10555/* confdefs.h. */
10556_ACEOF
10557cat confdefs.h >>conftest.$ac_ext
10558cat >>conftest.$ac_ext <<_ACEOF
10559/* end confdefs.h. */
98418dba
CW
10560
10561/* Override any gcc2 internal prototype to avoid an error. */
10562#ifdef __cplusplus
10563extern "C"
10564#endif
10565/* We use char because int might match the return type of a gcc2
10566 builtin and then its argument prototype would still apply. */
10567char XawScrollbarSetThumb ();
503d2be0
AS
10568int
10569main ()
10570{
98418dba 10571XawScrollbarSetThumb ();
503d2be0
AS
10572 ;
10573 return 0;
10574}
10575_ACEOF
10576rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10577if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10578 (eval $ac_link) 2>conftest.er1
503d2be0 10579 ac_status=$?
35996d22
AS
10580 grep -v '^ *+' conftest.er1 >conftest.err
10581 rm -f conftest.er1
10582 cat conftest.err >&5
c0d27fcc 10583 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10584 (exit $ac_status); } &&
4494a266
JD
10585 { ac_try='test -z "$ac_c_werror_flag"
10586 || test ! -s conftest.err'
35996d22
AS
10587 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10588 (eval $ac_try) 2>&5
10589 ac_status=$?
10590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10591 (exit $ac_status); }; } &&
10592 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10593 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10594 (eval $ac_try) 2>&5
10595 ac_status=$?
c0d27fcc 10596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10597 (exit $ac_status); }; }; then
98418dba 10598 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 10599else
503d2be0 10600 echo "$as_me: failed program was:" >&5
19650fd6
AS
10601sed 's/^/| /' conftest.$ac_ext >&5
10602
98418dba 10603ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 10604fi
35996d22
AS
10605rm -f conftest.err conftest.$ac_objext \
10606 conftest$ac_exeext conftest.$ac_ext
98418dba 10607LIBS=$ac_check_lib_save_LIBS
ba4481b5 10608fi
c0d27fcc 10609echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
10610echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
10611if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
10612 HAVE_XAW3D=yes
ba4481b5 10613fi
503d2be0 10614
ba4481b5
DL
10615fi
10616
c0d27fcc 10617
98418dba 10618 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 10619
c0d27fcc 10620cat >>confdefs.h <<\_ACEOF
98418dba 10621#define HAVE_XAW3D 1
c0d27fcc 10622_ACEOF
98418dba 10623
ba4481b5 10624 fi
98418dba 10625 fi
ba4481b5
DL
10626fi
10627
c0d27fcc
MR
10628
10629
98418dba
CW
10630USE_TOOLKIT_SCROLL_BARS=no
10631if test "${with_toolkit_scroll_bars}" != "no"; then
10632 if test "${USE_X_TOOLKIT}" != "none"; then
10633 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10634 cat >>confdefs.h <<\_ACEOF
98418dba 10635#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10636_ACEOF
98418dba
CW
10637
10638 HAVE_XAW3D=no
10639 USE_TOOLKIT_SCROLL_BARS=yes
10640 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 10641 cat >>confdefs.h <<\_ACEOF
98418dba 10642#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10643_ACEOF
98418dba
CW
10644
10645 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 10646 fi
488dd4c4
JD
10647 elif test "${HAVE_GTK}" = "yes"; then
10648 cat >>confdefs.h <<\_ACEOF
10649#define USE_TOOLKIT_SCROLL_BARS 1
10650_ACEOF
10651
10652 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
10653 fi
10654fi
10655
abd39b57 10656cat >conftest.$ac_ext <<_ACEOF
abd39b57
AC
10657/* confdefs.h. */
10658_ACEOF
10659cat confdefs.h >>conftest.$ac_ext
10660cat >>conftest.$ac_ext <<_ACEOF
10661/* end confdefs.h. */
10662
10663 #include <X11/Xlib.h>
10664 #include <X11/Xresource.h>
10665int
10666main ()
10667{
10668XIMProc callback;
10669 ;
10670 return 0;
10671}
10672_ACEOF
10673rm -f conftest.$ac_objext
10674if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10675 (eval $ac_compile) 2>conftest.er1
abd39b57 10676 ac_status=$?
35996d22
AS
10677 grep -v '^ *+' conftest.er1 >conftest.err
10678 rm -f conftest.er1
10679 cat conftest.err >&5
abd39b57
AC
10680 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10681 (exit $ac_status); } &&
4494a266
JD
10682 { ac_try='test -z "$ac_c_werror_flag"
10683 || test ! -s conftest.err'
35996d22
AS
10684 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10685 (eval $ac_try) 2>&5
10686 ac_status=$?
10687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10688 (exit $ac_status); }; } &&
10689 { ac_try='test -s conftest.$ac_objext'
abd39b57
AC
10690 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10691 (eval $ac_try) 2>&5
10692 ac_status=$?
10693 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10694 (exit $ac_status); }; }; then
10695 HAVE_XIM=yes
10696
10697cat >>confdefs.h <<\_ACEOF
10698#define HAVE_XIM 1
10699_ACEOF
10700
10701else
10702 echo "$as_me: failed program was:" >&5
10703sed 's/^/| /' conftest.$ac_ext >&5
10704
10705HAVE_XIM=no
10706fi
35996d22 10707rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
abd39b57 10708
c0d27fcc 10709
98418dba 10710if test "${with_xim}" != "no"; then
b936fae4 10711
c0d27fcc 10712cat >>confdefs.h <<\_ACEOF
98418dba 10713#define USE_XIM 1
c0d27fcc 10714_ACEOF
98418dba 10715
793fa0d7 10716fi
abd39b57
AC
10717
10718
10719if test "${HAVE_XIM}" != "no"; then
849d80cf
DL
10720 late_CFLAGS=$CFLAGS
10721 if test "$GCC" = yes; then
10722 CFLAGS="$CFLAGS --pedantic-errors"
10723 fi
cffcede7 10724 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10725/* confdefs.h. */
10726_ACEOF
10727cat confdefs.h >>conftest.$ac_ext
10728cat >>conftest.$ac_ext <<_ACEOF
10729/* end confdefs.h. */
cffcede7
JD
10730
10731#include <X11/Xlib.h>
10732#include <X11/Xresource.h>
10733int
10734main ()
10735{
10736Display *display;
10737XrmDatabase db;
10738char *res_name;
10739char *res_class;
10740XIMProc callback;
10741XPointer *client_data;
849d80cf
DL
10742#ifndef __GNUC__
10743/* If we're not using GCC, it's probably not XFree86, and this is
10744 probably right, but we can't use something like --pedantic-errors. */
10745extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
10746 char*, XIMProc, XPointer*);
10747#endif
cffcede7
JD
10748(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
10749 client_data);
10750 ;
10751 return 0;
10752}
10753_ACEOF
10754rm -f conftest.$ac_objext
10755if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10756 (eval $ac_compile) 2>conftest.er1
cffcede7 10757 ac_status=$?
35996d22
AS
10758 grep -v '^ *+' conftest.er1 >conftest.err
10759 rm -f conftest.er1
10760 cat conftest.err >&5
cffcede7
JD
10761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10762 (exit $ac_status); } &&
4494a266
JD
10763 { ac_try='test -z "$ac_c_werror_flag"
10764 || test ! -s conftest.err'
35996d22
AS
10765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10766 (eval $ac_try) 2>&5
10767 ac_status=$?
10768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10769 (exit $ac_status); }; } &&
10770 { ac_try='test -s conftest.$ac_objext'
cffcede7
JD
10771 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10772 (eval $ac_try) 2>&5
10773 ac_status=$?
10774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10775 (exit $ac_status); }; }; then
10776 emacs_cv_arg6_star=yes
10777else
10778 echo "$as_me: failed program was:" >&5
19650fd6
AS
10779sed 's/^/| /' conftest.$ac_ext >&5
10780
cffcede7 10781fi
35996d22 10782rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cffcede7
JD
10783
10784 if test "$emacs_cv_arg6_star" = yes; then
f57bd967 10785 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10786#define XRegisterIMInstantiateCallback_arg6 XPointer*
10787_ACEOF
10788
10789 else
f57bd967 10790 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10791#define XRegisterIMInstantiateCallback_arg6 XPointer
10792_ACEOF
10793
10794 fi
849d80cf 10795 CFLAGS=$late_CFLAGS
98418dba
CW
10796fi
10797
10798### Use -lXpm if available, unless `--with-xpm=no'.
10799HAVE_XPM=no
10800if test "${HAVE_X11}" = "yes"; then
10801 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
10802 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10803 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
10804echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10805if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10806 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10807fi
10808echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
10809echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 10810else
c0d27fcc
MR
10811 # Is the header compilable?
10812echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
10813echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
10814cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10815/* confdefs.h. */
10816_ACEOF
10817cat confdefs.h >>conftest.$ac_ext
10818cat >>conftest.$ac_ext <<_ACEOF
10819/* end confdefs.h. */
c0d27fcc
MR
10820$ac_includes_default
10821#include <X11/xpm.h>
10822_ACEOF
10823rm -f conftest.$ac_objext
10824if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 10825 (eval $ac_compile) 2>conftest.er1
c0d27fcc 10826 ac_status=$?
35996d22
AS
10827 grep -v '^ *+' conftest.er1 >conftest.err
10828 rm -f conftest.er1
10829 cat conftest.err >&5
c0d27fcc
MR
10830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10831 (exit $ac_status); } &&
4494a266
JD
10832 { ac_try='test -z "$ac_c_werror_flag"
10833 || test ! -s conftest.err'
35996d22
AS
10834 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10835 (eval $ac_try) 2>&5
10836 ac_status=$?
10837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10838 (exit $ac_status); }; } &&
10839 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10841 (eval $ac_try) 2>&5
10842 ac_status=$?
10843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10844 (exit $ac_status); }; }; then
10845 ac_header_compiler=yes
10846else
10847 echo "$as_me: failed program was:" >&5
19650fd6
AS
10848sed 's/^/| /' conftest.$ac_ext >&5
10849
c0d27fcc
MR
10850ac_header_compiler=no
10851fi
35996d22 10852rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10853echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10854echo "${ECHO_T}$ac_header_compiler" >&6
10855
10856# Is the header present?
10857echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
10858echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
10859cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10860/* confdefs.h. */
10861_ACEOF
10862cat confdefs.h >>conftest.$ac_ext
10863cat >>conftest.$ac_ext <<_ACEOF
10864/* end confdefs.h. */
98418dba
CW
10865#include <X11/xpm.h>
10866_ACEOF
c0d27fcc 10867if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10868 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10869 ac_status=$?
6bae0ccf 10870 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10871 rm -f conftest.er1
10872 cat conftest.err >&5
c0d27fcc 10873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10874 (exit $ac_status); } >/dev/null; then
10875 if test -s conftest.err; then
10876 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 10877 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
10878 else
10879 ac_cpp_err=
10880 fi
10881else
10882 ac_cpp_err=yes
10883fi
10884if test -z "$ac_cpp_err"; then
c0d27fcc 10885 ac_header_preproc=yes
98418dba
CW
10886else
10887 echo "$as_me: failed program was:" >&5
19650fd6
AS
10888sed 's/^/| /' conftest.$ac_ext >&5
10889
c0d27fcc 10890 ac_header_preproc=no
98418dba
CW
10891fi
10892rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10893echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10894echo "${ECHO_T}$ac_header_preproc" >&6
10895
10896# So? What about this header?
35996d22
AS
10897case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10898 yes:no: )
c0d27fcc
MR
10899 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
10900echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
10901 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the compiler's result" >&5
10902echo "$as_me: WARNING: X11/xpm.h: proceeding with the compiler's result" >&2;}
10903 ac_header_preproc=yes
19650fd6 10904 ;;
35996d22 10905 no:yes:* )
c0d27fcc
MR
10906 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
10907echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
35996d22
AS
10908 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
10909echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
10910 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: see the Autoconf documentation" >&5
10911echo "$as_me: WARNING: X11/xpm.h: see the Autoconf documentation" >&2;}
10912 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&5
10913echo "$as_me: WARNING: X11/xpm.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 10914 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
19650fd6 10915echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
10916 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&5
10917echo "$as_me: WARNING: X11/xpm.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
10918 (
10919 cat <<\_ASBOX
35996d22
AS
10920## ------------------------------------------ ##
10921## Report this to the AC_PACKAGE_NAME lists. ##
10922## ------------------------------------------ ##
19650fd6
AS
10923_ASBOX
10924 ) |
10925 sed "s/^/$as_me: WARNING: /" >&2
10926 ;;
c0d27fcc
MR
10927esac
10928echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
10929echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10930if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10931 echo $ECHO_N "(cached) $ECHO_C" >&6
10932else
10933 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 10934fi
c0d27fcc 10935echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 10936echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
10937
10938fi
98418dba 10939if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 10940 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
10941echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
10942if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 10943 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10944else
98418dba
CW
10945 ac_check_lib_save_LIBS=$LIBS
10946LIBS="-lXpm -lX11 $LIBS"
10947cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
10948/* confdefs.h. */
10949_ACEOF
10950cat confdefs.h >>conftest.$ac_ext
10951cat >>conftest.$ac_ext <<_ACEOF
10952/* end confdefs.h. */
98418dba 10953
ba4481b5 10954/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10955#ifdef __cplusplus
10956extern "C"
10957#endif
ba4481b5 10958/* We use char because int might match the return type of a gcc2
503d2be0 10959 builtin and then its argument prototype would still apply. */
98418dba 10960char XpmReadFileToPixmap ();
503d2be0
AS
10961int
10962main ()
10963{
98418dba 10964XpmReadFileToPixmap ();
503d2be0
AS
10965 ;
10966 return 0;
10967}
10968_ACEOF
10969rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10970if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 10971 (eval $ac_link) 2>conftest.er1
503d2be0 10972 ac_status=$?
35996d22
AS
10973 grep -v '^ *+' conftest.er1 >conftest.err
10974 rm -f conftest.er1
10975 cat conftest.err >&5
c0d27fcc 10976 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10977 (exit $ac_status); } &&
4494a266
JD
10978 { ac_try='test -z "$ac_c_werror_flag"
10979 || test ! -s conftest.err'
35996d22
AS
10980 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10981 (eval $ac_try) 2>&5
10982 ac_status=$?
10983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10984 (exit $ac_status); }; } &&
10985 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10986 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10987 (eval $ac_try) 2>&5
10988 ac_status=$?
c0d27fcc 10989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10990 (exit $ac_status); }; }; then
98418dba 10991 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
10992else
10993 echo "$as_me: failed program was:" >&5
19650fd6
AS
10994sed 's/^/| /' conftest.$ac_ext >&5
10995
98418dba 10996ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0 10997fi
35996d22
AS
10998rm -f conftest.err conftest.$ac_objext \
10999 conftest$ac_exeext conftest.$ac_ext
98418dba 11000LIBS=$ac_check_lib_save_LIBS
503d2be0 11001fi
c0d27fcc 11002echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
11003echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
11004if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
11005 HAVE_XPM=yes
ba4481b5
DL
11006fi
11007
98418dba
CW
11008fi
11009
c0d27fcc 11010
98418dba 11011 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 11012 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
11013echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
11014 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11015/* confdefs.h. */
11016_ACEOF
11017cat confdefs.h >>conftest.$ac_ext
11018cat >>conftest.$ac_ext <<_ACEOF
11019/* end confdefs.h. */
98418dba
CW
11020#include "X11/xpm.h"
11021#ifndef XpmReturnAllocPixels
11022no_return_alloc_pixels
503d2be0 11023#endif
ba4481b5 11024
98418dba
CW
11025_ACEOF
11026if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11027 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
11028 HAVE_XPM=no
11029else
11030 HAVE_XPM=yes
11031fi
11032rm -f conftest*
ba4481b5 11033
c0d27fcc 11034
98418dba 11035 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 11036 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
11037echo "${ECHO_T}yes" >&6
11038 else
c0d27fcc 11039 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
11040echo "${ECHO_T}no" >&6
11041 fi
11042 fi
11043 fi
11044
11045 if test "${HAVE_XPM}" = "yes"; then
b936fae4 11046
c0d27fcc 11047cat >>confdefs.h <<\_ACEOF
98418dba 11048#define HAVE_XPM 1
c0d27fcc 11049_ACEOF
98418dba
CW
11050
11051 fi
11052fi
11053
11054### Use -ljpeg if available, unless `--with-jpeg=no'.
11055HAVE_JPEG=no
11056if test "${HAVE_X11}" = "yes"; then
11057 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
11058 if test "${ac_cv_header_jerror_h+set}" = set; then
11059 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
11060echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11061if test "${ac_cv_header_jerror_h+set}" = set; then
11062 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11063fi
11064echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
11065echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 11066else
c0d27fcc
MR
11067 # Is the header compilable?
11068echo "$as_me:$LINENO: checking jerror.h usability" >&5
11069echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
11070cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11071/* confdefs.h. */
11072_ACEOF
11073cat confdefs.h >>conftest.$ac_ext
11074cat >>conftest.$ac_ext <<_ACEOF
11075/* end confdefs.h. */
c0d27fcc
MR
11076$ac_includes_default
11077#include <jerror.h>
11078_ACEOF
11079rm -f conftest.$ac_objext
11080if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11081 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11082 ac_status=$?
35996d22
AS
11083 grep -v '^ *+' conftest.er1 >conftest.err
11084 rm -f conftest.er1
11085 cat conftest.err >&5
c0d27fcc
MR
11086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11087 (exit $ac_status); } &&
4494a266
JD
11088 { ac_try='test -z "$ac_c_werror_flag"
11089 || test ! -s conftest.err'
35996d22
AS
11090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11091 (eval $ac_try) 2>&5
11092 ac_status=$?
11093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11094 (exit $ac_status); }; } &&
11095 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11097 (eval $ac_try) 2>&5
11098 ac_status=$?
11099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11100 (exit $ac_status); }; }; then
11101 ac_header_compiler=yes
11102else
11103 echo "$as_me: failed program was:" >&5
19650fd6
AS
11104sed 's/^/| /' conftest.$ac_ext >&5
11105
c0d27fcc
MR
11106ac_header_compiler=no
11107fi
35996d22 11108rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11109echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11110echo "${ECHO_T}$ac_header_compiler" >&6
11111
11112# Is the header present?
11113echo "$as_me:$LINENO: checking jerror.h presence" >&5
11114echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
11115cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11116/* confdefs.h. */
11117_ACEOF
11118cat confdefs.h >>conftest.$ac_ext
11119cat >>conftest.$ac_ext <<_ACEOF
11120/* end confdefs.h. */
98418dba
CW
11121#include <jerror.h>
11122_ACEOF
c0d27fcc 11123if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11124 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11125 ac_status=$?
6bae0ccf 11126 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11127 rm -f conftest.er1
11128 cat conftest.err >&5
c0d27fcc 11129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11130 (exit $ac_status); } >/dev/null; then
11131 if test -s conftest.err; then
11132 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11133 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11134 else
11135 ac_cpp_err=
11136 fi
11137else
11138 ac_cpp_err=yes
503d2be0 11139fi
98418dba 11140if test -z "$ac_cpp_err"; then
c0d27fcc 11141 ac_header_preproc=yes
ba4481b5 11142else
98418dba 11143 echo "$as_me: failed program was:" >&5
19650fd6
AS
11144sed 's/^/| /' conftest.$ac_ext >&5
11145
c0d27fcc 11146 ac_header_preproc=no
98418dba
CW
11147fi
11148rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11149echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11150echo "${ECHO_T}$ac_header_preproc" >&6
11151
11152# So? What about this header?
35996d22
AS
11153case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11154 yes:no: )
c0d27fcc
MR
11155 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
11156echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11157 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the compiler's result" >&5
11158echo "$as_me: WARNING: jerror.h: proceeding with the compiler's result" >&2;}
11159 ac_header_preproc=yes
19650fd6 11160 ;;
35996d22 11161 no:yes:* )
c0d27fcc
MR
11162 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
11163echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
35996d22
AS
11164 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
11165echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
11166 { echo "$as_me:$LINENO: WARNING: jerror.h: see the Autoconf documentation" >&5
11167echo "$as_me: WARNING: jerror.h: see the Autoconf documentation" >&2;}
11168 { echo "$as_me:$LINENO: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&5
11169echo "$as_me: WARNING: jerror.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11170 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
19650fd6 11171echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11172 { echo "$as_me:$LINENO: WARNING: jerror.h: in the future, the compiler will take precedence" >&5
11173echo "$as_me: WARNING: jerror.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11174 (
11175 cat <<\_ASBOX
35996d22
AS
11176## ------------------------------------------ ##
11177## Report this to the AC_PACKAGE_NAME lists. ##
11178## ------------------------------------------ ##
19650fd6
AS
11179_ASBOX
11180 ) |
11181 sed "s/^/$as_me: WARNING: /" >&2
11182 ;;
c0d27fcc
MR
11183esac
11184echo "$as_me:$LINENO: checking for jerror.h" >&5
11185echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
11186if test "${ac_cv_header_jerror_h+set}" = set; then
11187 echo $ECHO_N "(cached) $ECHO_C" >&6
11188else
11189 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 11190fi
c0d27fcc 11191echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 11192echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
11193
11194fi
98418dba 11195if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 11196 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
11197echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
11198if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 11199 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11200else
98418dba
CW
11201 ac_check_lib_save_LIBS=$LIBS
11202LIBS="-ljpeg $LIBS"
11203cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11204/* confdefs.h. */
11205_ACEOF
11206cat confdefs.h >>conftest.$ac_ext
11207cat >>conftest.$ac_ext <<_ACEOF
11208/* end confdefs.h. */
98418dba
CW
11209
11210/* Override any gcc2 internal prototype to avoid an error. */
11211#ifdef __cplusplus
11212extern "C"
11213#endif
11214/* We use char because int might match the return type of a gcc2
11215 builtin and then its argument prototype would still apply. */
11216char jpeg_destroy_compress ();
503d2be0
AS
11217int
11218main ()
11219{
98418dba 11220jpeg_destroy_compress ();
503d2be0
AS
11221 ;
11222 return 0;
11223}
11224_ACEOF
11225rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11226if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11227 (eval $ac_link) 2>conftest.er1
503d2be0 11228 ac_status=$?
35996d22
AS
11229 grep -v '^ *+' conftest.er1 >conftest.err
11230 rm -f conftest.er1
11231 cat conftest.err >&5
c0d27fcc 11232 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11233 (exit $ac_status); } &&
4494a266
JD
11234 { ac_try='test -z "$ac_c_werror_flag"
11235 || test ! -s conftest.err'
35996d22
AS
11236 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11237 (eval $ac_try) 2>&5
11238 ac_status=$?
11239 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11240 (exit $ac_status); }; } &&
11241 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11242 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11243 (eval $ac_try) 2>&5
11244 ac_status=$?
c0d27fcc 11245 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11246 (exit $ac_status); }; }; then
98418dba 11247 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 11248else
503d2be0 11249 echo "$as_me: failed program was:" >&5
19650fd6
AS
11250sed 's/^/| /' conftest.$ac_ext >&5
11251
98418dba 11252ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 11253fi
35996d22
AS
11254rm -f conftest.err conftest.$ac_objext \
11255 conftest$ac_exeext conftest.$ac_ext
98418dba 11256LIBS=$ac_check_lib_save_LIBS
ba4481b5 11257fi
c0d27fcc 11258echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
11259echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
11260if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
11261 HAVE_JPEG=yes
ba4481b5 11262fi
98418dba 11263
ba4481b5 11264fi
98418dba 11265
c0d27fcc 11266
ba4481b5 11267 fi
ba4481b5 11268
c0d27fcc 11269
98418dba 11270 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 11271 cat >>confdefs.h <<\_ACEOF
98418dba 11272#define HAVE_JPEG 1
c0d27fcc 11273_ACEOF
98418dba
CW
11274
11275 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11276/* confdefs.h. */
11277_ACEOF
11278cat confdefs.h >>conftest.$ac_ext
11279cat >>conftest.$ac_ext <<_ACEOF
11280/* end confdefs.h. */
22044edf 11281#include <jpeglib.h>
98418dba
CW
11282 version=JPEG_LIB_VERSION
11283
11284_ACEOF
11285if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 11286 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 11287 cat >>confdefs.h <<\_ACEOF
98418dba 11288#define HAVE_JPEG 1
c0d27fcc 11289_ACEOF
ba4481b5 11290
98418dba 11291else
c0d27fcc 11292 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
11293echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
11294 HAVE_JPEG=no
ba4481b5 11295fi
98418dba 11296rm -f conftest*
ba4481b5 11297
98418dba
CW
11298 fi
11299fi
503d2be0 11300
98418dba
CW
11301### Use -lpng if available, unless `--with-png=no'.
11302HAVE_PNG=no
11303if test "${HAVE_X11}" = "yes"; then
11304 if test "${with_png}" != "no"; then
f57bd967
DL
11305 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
11306 # in /usr/include/libpng.
11307
11308
11309for ac_header in png.h libpng/png.h
11310do
11311as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11312if eval "test \"\${$as_ac_Header+set}\" = set"; then
11313 echo "$as_me:$LINENO: checking for $ac_header" >&5
11314echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11315if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11316 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc 11317fi
f57bd967
DL
11318echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11319echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
503d2be0 11320else
c0d27fcc 11321 # Is the header compilable?
f57bd967
DL
11322echo "$as_me:$LINENO: checking $ac_header usability" >&5
11323echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
c0d27fcc 11324cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11325/* confdefs.h. */
11326_ACEOF
11327cat confdefs.h >>conftest.$ac_ext
11328cat >>conftest.$ac_ext <<_ACEOF
11329/* end confdefs.h. */
c0d27fcc 11330$ac_includes_default
f57bd967 11331#include <$ac_header>
c0d27fcc
MR
11332_ACEOF
11333rm -f conftest.$ac_objext
11334if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11335 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11336 ac_status=$?
35996d22
AS
11337 grep -v '^ *+' conftest.er1 >conftest.err
11338 rm -f conftest.er1
11339 cat conftest.err >&5
c0d27fcc
MR
11340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11341 (exit $ac_status); } &&
4494a266
JD
11342 { ac_try='test -z "$ac_c_werror_flag"
11343 || test ! -s conftest.err'
35996d22
AS
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); }; } &&
11349 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11350 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11351 (eval $ac_try) 2>&5
11352 ac_status=$?
11353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11354 (exit $ac_status); }; }; then
11355 ac_header_compiler=yes
11356else
11357 echo "$as_me: failed program was:" >&5
19650fd6
AS
11358sed 's/^/| /' conftest.$ac_ext >&5
11359
c0d27fcc
MR
11360ac_header_compiler=no
11361fi
35996d22 11362rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11363echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11364echo "${ECHO_T}$ac_header_compiler" >&6
11365
11366# Is the header present?
f57bd967
DL
11367echo "$as_me:$LINENO: checking $ac_header presence" >&5
11368echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
c0d27fcc 11369cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11370/* confdefs.h. */
11371_ACEOF
11372cat confdefs.h >>conftest.$ac_ext
11373cat >>conftest.$ac_ext <<_ACEOF
11374/* end confdefs.h. */
f57bd967 11375#include <$ac_header>
503d2be0 11376_ACEOF
c0d27fcc 11377if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11378 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11379 ac_status=$?
6bae0ccf 11380 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11381 rm -f conftest.er1
11382 cat conftest.err >&5
c0d27fcc 11383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11384 (exit $ac_status); } >/dev/null; then
11385 if test -s conftest.err; then
11386 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11387 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
11388 else
11389 ac_cpp_err=
11390 fi
11391else
11392 ac_cpp_err=yes
11393fi
11394if test -z "$ac_cpp_err"; then
c0d27fcc 11395 ac_header_preproc=yes
503d2be0
AS
11396else
11397 echo "$as_me: failed program was:" >&5
19650fd6
AS
11398sed 's/^/| /' conftest.$ac_ext >&5
11399
c0d27fcc 11400 ac_header_preproc=no
ba4481b5 11401fi
503d2be0 11402rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11403echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11404echo "${ECHO_T}$ac_header_preproc" >&6
11405
11406# So? What about this header?
35996d22
AS
11407case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11408 yes:no: )
f57bd967
DL
11409 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11410echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11411 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11412echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11413 ac_header_preproc=yes
19650fd6 11414 ;;
35996d22 11415 no:yes:* )
f57bd967
DL
11416 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11417echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
11418 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11419echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11420 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11421echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11422 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
11423echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
f57bd967 11424 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 11425echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11426 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11427echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11428 (
11429 cat <<\_ASBOX
35996d22
AS
11430## ------------------------------------------ ##
11431## Report this to the AC_PACKAGE_NAME lists. ##
11432## ------------------------------------------ ##
19650fd6
AS
11433_ASBOX
11434 ) |
11435 sed "s/^/$as_me: WARNING: /" >&2
11436 ;;
c0d27fcc 11437esac
f57bd967
DL
11438echo "$as_me:$LINENO: checking for $ac_header" >&5
11439echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11440if eval "test \"\${$as_ac_Header+set}\" = set"; then
c0d27fcc
MR
11441 echo $ECHO_N "(cached) $ECHO_C" >&6
11442else
35996d22 11443 eval "$as_ac_Header=\$ac_header_preproc"
f57bd967
DL
11444fi
11445echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11446echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11447
ba4481b5 11448fi
f57bd967
DL
11449if test `eval echo '${'$as_ac_Header'}'` = yes; then
11450 cat >>confdefs.h <<_ACEOF
11451#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11452_ACEOF
c0d27fcc
MR
11453
11454fi
f57bd967
DL
11455
11456done
11457
11458 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
11459 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
11460echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
11461if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 11462 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11463else
98418dba
CW
11464 ac_check_lib_save_LIBS=$LIBS
11465LIBS="-lpng -lz -lm $LIBS"
11466cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11467/* confdefs.h. */
11468_ACEOF
11469cat confdefs.h >>conftest.$ac_ext
11470cat >>conftest.$ac_ext <<_ACEOF
11471/* end confdefs.h. */
98418dba 11472
ba4481b5 11473/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11474#ifdef __cplusplus
11475extern "C"
11476#endif
ba4481b5 11477/* We use char because int might match the return type of a gcc2
503d2be0 11478 builtin and then its argument prototype would still apply. */
98418dba 11479char png_get_channels ();
503d2be0
AS
11480int
11481main ()
11482{
98418dba 11483png_get_channels ();
503d2be0
AS
11484 ;
11485 return 0;
11486}
11487_ACEOF
11488rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11489if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11490 (eval $ac_link) 2>conftest.er1
503d2be0 11491 ac_status=$?
35996d22
AS
11492 grep -v '^ *+' conftest.er1 >conftest.err
11493 rm -f conftest.er1
11494 cat conftest.err >&5
c0d27fcc 11495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11496 (exit $ac_status); } &&
4494a266
JD
11497 { ac_try='test -z "$ac_c_werror_flag"
11498 || test ! -s conftest.err'
35996d22
AS
11499 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11500 (eval $ac_try) 2>&5
11501 ac_status=$?
11502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11503 (exit $ac_status); }; } &&
11504 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11505 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11506 (eval $ac_try) 2>&5
11507 ac_status=$?
c0d27fcc 11508 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11509 (exit $ac_status); }; }; then
98418dba 11510 ac_cv_lib_png_png_get_channels=yes
73b77ee5 11511else
98418dba 11512 echo "$as_me: failed program was:" >&5
19650fd6
AS
11513sed 's/^/| /' conftest.$ac_ext >&5
11514
98418dba 11515ac_cv_lib_png_png_get_channels=no
73b77ee5 11516fi
35996d22
AS
11517rm -f conftest.err conftest.$ac_objext \
11518 conftest$ac_exeext conftest.$ac_ext
98418dba 11519LIBS=$ac_check_lib_save_LIBS
73b77ee5 11520fi
c0d27fcc 11521echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
11522echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
11523if test $ac_cv_lib_png_png_get_channels = yes; then
11524 HAVE_PNG=yes
73b77ee5 11525fi
503d2be0 11526
f57bd967 11527 fi
98418dba
CW
11528 fi
11529
11530 if test "${HAVE_PNG}" = "yes"; then
b936fae4 11531
c0d27fcc 11532cat >>confdefs.h <<\_ACEOF
98418dba 11533#define HAVE_PNG 1
c0d27fcc 11534_ACEOF
73b77ee5 11535
98418dba 11536 fi
73b77ee5
GM
11537fi
11538
98418dba
CW
11539### Use -ltiff if available, unless `--with-tiff=no'.
11540HAVE_TIFF=no
11541if test "${HAVE_X11}" = "yes"; then
11542 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
11543 if test "${ac_cv_header_tiffio_h+set}" = set; then
11544 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
11545echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11546if test "${ac_cv_header_tiffio_h+set}" = set; then
11547 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11548fi
11549echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
11550echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 11551else
c0d27fcc
MR
11552 # Is the header compilable?
11553echo "$as_me:$LINENO: checking tiffio.h usability" >&5
11554echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
11555cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11556/* confdefs.h. */
11557_ACEOF
11558cat confdefs.h >>conftest.$ac_ext
11559cat >>conftest.$ac_ext <<_ACEOF
11560/* end confdefs.h. */
c0d27fcc
MR
11561$ac_includes_default
11562#include <tiffio.h>
11563_ACEOF
11564rm -f conftest.$ac_objext
11565if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11566 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11567 ac_status=$?
35996d22
AS
11568 grep -v '^ *+' conftest.er1 >conftest.err
11569 rm -f conftest.er1
11570 cat conftest.err >&5
c0d27fcc
MR
11571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11572 (exit $ac_status); } &&
4494a266
JD
11573 { ac_try='test -z "$ac_c_werror_flag"
11574 || test ! -s conftest.err'
35996d22
AS
11575 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11576 (eval $ac_try) 2>&5
11577 ac_status=$?
11578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11579 (exit $ac_status); }; } &&
11580 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11581 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11582 (eval $ac_try) 2>&5
11583 ac_status=$?
11584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11585 (exit $ac_status); }; }; then
11586 ac_header_compiler=yes
11587else
11588 echo "$as_me: failed program was:" >&5
19650fd6
AS
11589sed 's/^/| /' conftest.$ac_ext >&5
11590
c0d27fcc
MR
11591ac_header_compiler=no
11592fi
35996d22 11593rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11594echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11595echo "${ECHO_T}$ac_header_compiler" >&6
11596
11597# Is the header present?
11598echo "$as_me:$LINENO: checking tiffio.h presence" >&5
11599echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
11600cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11601/* confdefs.h. */
11602_ACEOF
11603cat confdefs.h >>conftest.$ac_ext
11604cat >>conftest.$ac_ext <<_ACEOF
11605/* end confdefs.h. */
98418dba
CW
11606#include <tiffio.h>
11607_ACEOF
c0d27fcc 11608if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11609 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11610 ac_status=$?
6bae0ccf 11611 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11612 rm -f conftest.er1
11613 cat conftest.err >&5
c0d27fcc 11614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11615 (exit $ac_status); } >/dev/null; then
11616 if test -s conftest.err; then
11617 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11618 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11619 else
11620 ac_cpp_err=
11621 fi
11622else
11623 ac_cpp_err=yes
11624fi
11625if test -z "$ac_cpp_err"; then
c0d27fcc 11626 ac_header_preproc=yes
98418dba
CW
11627else
11628 echo "$as_me: failed program was:" >&5
19650fd6
AS
11629sed 's/^/| /' conftest.$ac_ext >&5
11630
c0d27fcc 11631 ac_header_preproc=no
98418dba
CW
11632fi
11633rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11634echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11635echo "${ECHO_T}$ac_header_preproc" >&6
11636
11637# So? What about this header?
35996d22
AS
11638case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11639 yes:no: )
c0d27fcc
MR
11640 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
11641echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11642 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the compiler's result" >&5
11643echo "$as_me: WARNING: tiffio.h: proceeding with the compiler's result" >&2;}
11644 ac_header_preproc=yes
19650fd6 11645 ;;
35996d22 11646 no:yes:* )
c0d27fcc
MR
11647 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
11648echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
35996d22
AS
11649 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
11650echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
11651 { echo "$as_me:$LINENO: WARNING: tiffio.h: see the Autoconf documentation" >&5
11652echo "$as_me: WARNING: tiffio.h: see the Autoconf documentation" >&2;}
11653 { echo "$as_me:$LINENO: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&5
11654echo "$as_me: WARNING: tiffio.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11655 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
19650fd6 11656echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11657 { echo "$as_me:$LINENO: WARNING: tiffio.h: in the future, the compiler will take precedence" >&5
11658echo "$as_me: WARNING: tiffio.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11659 (
11660 cat <<\_ASBOX
35996d22
AS
11661## ------------------------------------------ ##
11662## Report this to the AC_PACKAGE_NAME lists. ##
11663## ------------------------------------------ ##
19650fd6
AS
11664_ASBOX
11665 ) |
11666 sed "s/^/$as_me: WARNING: /" >&2
11667 ;;
c0d27fcc
MR
11668esac
11669echo "$as_me:$LINENO: checking for tiffio.h" >&5
11670echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11671if test "${ac_cv_header_tiffio_h+set}" = set; then
11672 echo $ECHO_N "(cached) $ECHO_C" >&6
11673else
11674 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 11675fi
c0d27fcc 11676echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 11677echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
11678
11679fi
98418dba
CW
11680if test $ac_cv_header_tiffio_h = yes; then
11681 tifflibs="-lz -lm"
11682 # At least one tiff package requires the jpeg library.
11683 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 11684 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
11685echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
11686if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 11687 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11688else
503d2be0 11689 ac_check_lib_save_LIBS=$LIBS
98418dba 11690LIBS="-ltiff $tifflibs $LIBS"
503d2be0 11691cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11692/* confdefs.h. */
11693_ACEOF
11694cat confdefs.h >>conftest.$ac_ext
11695cat >>conftest.$ac_ext <<_ACEOF
11696/* end confdefs.h. */
503d2be0 11697
73b77ee5 11698/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11699#ifdef __cplusplus
11700extern "C"
11701#endif
73b77ee5 11702/* We use char because int might match the return type of a gcc2
503d2be0 11703 builtin and then its argument prototype would still apply. */
98418dba 11704char TIFFGetVersion ();
503d2be0
AS
11705int
11706main ()
11707{
98418dba 11708TIFFGetVersion ();
503d2be0
AS
11709 ;
11710 return 0;
11711}
11712_ACEOF
11713rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11714if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11715 (eval $ac_link) 2>conftest.er1
503d2be0 11716 ac_status=$?
35996d22
AS
11717 grep -v '^ *+' conftest.er1 >conftest.err
11718 rm -f conftest.er1
11719 cat conftest.err >&5
c0d27fcc 11720 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11721 (exit $ac_status); } &&
4494a266
JD
11722 { ac_try='test -z "$ac_c_werror_flag"
11723 || test ! -s conftest.err'
35996d22
AS
11724 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11725 (eval $ac_try) 2>&5
11726 ac_status=$?
11727 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11728 (exit $ac_status); }; } &&
11729 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11730 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11731 (eval $ac_try) 2>&5
11732 ac_status=$?
c0d27fcc 11733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11734 (exit $ac_status); }; }; then
98418dba 11735 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
11736else
11737 echo "$as_me: failed program was:" >&5
19650fd6
AS
11738sed 's/^/| /' conftest.$ac_ext >&5
11739
98418dba 11740ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0 11741fi
35996d22
AS
11742rm -f conftest.err conftest.$ac_objext \
11743 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
11744LIBS=$ac_check_lib_save_LIBS
11745fi
c0d27fcc 11746echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
11747echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
11748if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
11749 HAVE_TIFF=yes
11750fi
11751
11752fi
73b77ee5 11753
c0d27fcc 11754
98418dba
CW
11755 fi
11756
11757 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 11758
c0d27fcc 11759cat >>confdefs.h <<\_ACEOF
98418dba 11760#define HAVE_TIFF 1
c0d27fcc 11761_ACEOF
98418dba
CW
11762
11763 fi
73b77ee5
GM
11764fi
11765
98418dba
CW
11766### Use -lgif if available, unless `--with-gif=no'.
11767HAVE_GIF=no
11768if test "${HAVE_X11}" = "yes"; then
11769 if test "${with_gif}" != "no"; then
c0d27fcc
MR
11770 if test "${ac_cv_header_gif_lib_h+set}" = set; then
11771 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
11772echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11773if test "${ac_cv_header_gif_lib_h+set}" = set; then
11774 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11775fi
11776echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
11777echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 11778else
c0d27fcc
MR
11779 # Is the header compilable?
11780echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
11781echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
11782cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11783/* confdefs.h. */
11784_ACEOF
11785cat confdefs.h >>conftest.$ac_ext
11786cat >>conftest.$ac_ext <<_ACEOF
11787/* end confdefs.h. */
c0d27fcc
MR
11788$ac_includes_default
11789#include <gif_lib.h>
11790_ACEOF
11791rm -f conftest.$ac_objext
11792if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 11793 (eval $ac_compile) 2>conftest.er1
c0d27fcc 11794 ac_status=$?
35996d22
AS
11795 grep -v '^ *+' conftest.er1 >conftest.err
11796 rm -f conftest.er1
11797 cat conftest.err >&5
c0d27fcc
MR
11798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11799 (exit $ac_status); } &&
4494a266
JD
11800 { ac_try='test -z "$ac_c_werror_flag"
11801 || test ! -s conftest.err'
35996d22
AS
11802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11803 (eval $ac_try) 2>&5
11804 ac_status=$?
11805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11806 (exit $ac_status); }; } &&
11807 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11808 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11809 (eval $ac_try) 2>&5
11810 ac_status=$?
11811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11812 (exit $ac_status); }; }; then
11813 ac_header_compiler=yes
11814else
11815 echo "$as_me: failed program was:" >&5
19650fd6
AS
11816sed 's/^/| /' conftest.$ac_ext >&5
11817
c0d27fcc
MR
11818ac_header_compiler=no
11819fi
35996d22 11820rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11821echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11822echo "${ECHO_T}$ac_header_compiler" >&6
11823
11824# Is the header present?
11825echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
11826echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
11827cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11828/* confdefs.h. */
11829_ACEOF
11830cat confdefs.h >>conftest.$ac_ext
11831cat >>conftest.$ac_ext <<_ACEOF
11832/* end confdefs.h. */
98418dba
CW
11833#include <gif_lib.h>
11834_ACEOF
c0d27fcc 11835if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11836 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11837 ac_status=$?
6bae0ccf 11838 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11839 rm -f conftest.er1
11840 cat conftest.err >&5
c0d27fcc 11841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11842 (exit $ac_status); } >/dev/null; then
11843 if test -s conftest.err; then
11844 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 11845 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
11846 else
11847 ac_cpp_err=
11848 fi
11849else
11850 ac_cpp_err=yes
11851fi
11852if test -z "$ac_cpp_err"; then
c0d27fcc 11853 ac_header_preproc=yes
98418dba
CW
11854else
11855 echo "$as_me: failed program was:" >&5
19650fd6
AS
11856sed 's/^/| /' conftest.$ac_ext >&5
11857
c0d27fcc 11858 ac_header_preproc=no
98418dba
CW
11859fi
11860rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11861echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11862echo "${ECHO_T}$ac_header_preproc" >&6
11863
11864# So? What about this header?
35996d22
AS
11865case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11866 yes:no: )
c0d27fcc
MR
11867 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11868echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
11869 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the compiler's result" >&5
11870echo "$as_me: WARNING: gif_lib.h: proceeding with the compiler's result" >&2;}
11871 ac_header_preproc=yes
19650fd6 11872 ;;
35996d22 11873 no:yes:* )
c0d27fcc
MR
11874 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
11875echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
35996d22
AS
11876 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
11877echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
11878 { echo "$as_me:$LINENO: WARNING: gif_lib.h: see the Autoconf documentation" >&5
11879echo "$as_me: WARNING: gif_lib.h: see the Autoconf documentation" >&2;}
11880 { echo "$as_me:$LINENO: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&5
11881echo "$as_me: WARNING: gif_lib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 11882 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
19650fd6 11883echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
11884 { echo "$as_me:$LINENO: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&5
11885echo "$as_me: WARNING: gif_lib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
11886 (
11887 cat <<\_ASBOX
35996d22
AS
11888## ------------------------------------------ ##
11889## Report this to the AC_PACKAGE_NAME lists. ##
11890## ------------------------------------------ ##
19650fd6
AS
11891_ASBOX
11892 ) |
11893 sed "s/^/$as_me: WARNING: /" >&2
11894 ;;
c0d27fcc
MR
11895esac
11896echo "$as_me:$LINENO: checking for gif_lib.h" >&5
11897echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11898if test "${ac_cv_header_gif_lib_h+set}" = set; then
11899 echo $ECHO_N "(cached) $ECHO_C" >&6
11900else
11901 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 11902fi
c0d27fcc 11903echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 11904echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
11905
11906fi
98418dba
CW
11907if test $ac_cv_header_gif_lib_h = yes; then
11908 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
11909# Earlier versions can crash Emacs.
c0d27fcc 11910 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
11911echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
11912if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 11913 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11914else
503d2be0 11915 ac_check_lib_save_LIBS=$LIBS
98418dba 11916LIBS="-lungif $LIBS"
503d2be0 11917cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
11918/* confdefs.h. */
11919_ACEOF
11920cat confdefs.h >>conftest.$ac_ext
11921cat >>conftest.$ac_ext <<_ACEOF
11922/* end confdefs.h. */
73b77ee5 11923
98418dba
CW
11924/* Override any gcc2 internal prototype to avoid an error. */
11925#ifdef __cplusplus
11926extern "C"
11927#endif
11928/* We use char because int might match the return type of a gcc2
11929 builtin and then its argument prototype would still apply. */
11930char EGifPutExtensionLast ();
503d2be0
AS
11931int
11932main ()
11933{
98418dba 11934EGifPutExtensionLast ();
503d2be0
AS
11935 ;
11936 return 0;
11937}
11938_ACEOF
11939rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11940if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 11941 (eval $ac_link) 2>conftest.er1
503d2be0 11942 ac_status=$?
35996d22
AS
11943 grep -v '^ *+' conftest.er1 >conftest.err
11944 rm -f conftest.er1
11945 cat conftest.err >&5
c0d27fcc 11946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11947 (exit $ac_status); } &&
4494a266
JD
11948 { ac_try='test -z "$ac_c_werror_flag"
11949 || test ! -s conftest.err'
c0d27fcc 11950 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
11951 (eval $ac_try) 2>&5
11952 ac_status=$?
c0d27fcc 11953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
11954 (exit $ac_status); }; } &&
11955 { ac_try='test -s conftest$ac_exeext'
11956 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11957 (eval $ac_try) 2>&5
11958 ac_status=$?
11959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11960 (exit $ac_status); }; }; then
11961 ac_cv_lib_ungif_EGifPutExtensionLast=yes
11962else
98418dba 11963 echo "$as_me: failed program was:" >&5
19650fd6
AS
11964sed 's/^/| /' conftest.$ac_ext >&5
11965
98418dba
CW
11966ac_cv_lib_ungif_EGifPutExtensionLast=no
11967fi
35996d22
AS
11968rm -f conftest.err conftest.$ac_objext \
11969 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
11970LIBS=$ac_check_lib_save_LIBS
11971fi
c0d27fcc 11972echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
11973echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
11974if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
11975 HAVE_GIF=yes
11976fi
11977
11978fi
11979
c0d27fcc 11980
98418dba
CW
11981 fi
11982
11983 if test "${HAVE_GIF}" = "yes"; then
b936fae4 11984
c0d27fcc 11985cat >>confdefs.h <<\_ACEOF
98418dba 11986#define HAVE_GIF 1
c0d27fcc 11987_ACEOF
98418dba
CW
11988
11989 fi
11990fi
11991
c0d27fcc
MR
11992### Use Mac OS X Carbon API to implement GUI.
11993HAVE_CARBON=no
11994if test "${with_carbon}" != "no"; then
11995 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11996 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
11997echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
11998if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
11999 echo $ECHO_N "(cached) $ECHO_C" >&6
12000fi
12001echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
12002echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
12003else
12004 # Is the header compilable?
12005echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
12006echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
12007cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12008/* confdefs.h. */
12009_ACEOF
12010cat confdefs.h >>conftest.$ac_ext
12011cat >>conftest.$ac_ext <<_ACEOF
12012/* end confdefs.h. */
c0d27fcc
MR
12013$ac_includes_default
12014#include <Carbon/Carbon.h>
12015_ACEOF
12016rm -f conftest.$ac_objext
12017if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 12018 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12019 ac_status=$?
35996d22
AS
12020 grep -v '^ *+' conftest.er1 >conftest.err
12021 rm -f conftest.er1
12022 cat conftest.err >&5
c0d27fcc
MR
12023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12024 (exit $ac_status); } &&
4494a266
JD
12025 { ac_try='test -z "$ac_c_werror_flag"
12026 || test ! -s conftest.err'
35996d22
AS
12027 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12028 (eval $ac_try) 2>&5
12029 ac_status=$?
12030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12031 (exit $ac_status); }; } &&
12032 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12033 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12034 (eval $ac_try) 2>&5
12035 ac_status=$?
12036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12037 (exit $ac_status); }; }; then
12038 ac_header_compiler=yes
12039else
12040 echo "$as_me: failed program was:" >&5
19650fd6
AS
12041sed 's/^/| /' conftest.$ac_ext >&5
12042
c0d27fcc
MR
12043ac_header_compiler=no
12044fi
35996d22 12045rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12046echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12047echo "${ECHO_T}$ac_header_compiler" >&6
12048
12049# Is the header present?
12050echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
12051echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
12052cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12053/* confdefs.h. */
12054_ACEOF
12055cat confdefs.h >>conftest.$ac_ext
12056cat >>conftest.$ac_ext <<_ACEOF
12057/* end confdefs.h. */
e0f712ba
AC
12058#include <Carbon/Carbon.h>
12059_ACEOF
c0d27fcc 12060if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
e0f712ba
AC
12061 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12062 ac_status=$?
6bae0ccf 12063 grep -v '^ *+' conftest.er1 >conftest.err
e0f712ba
AC
12064 rm -f conftest.er1
12065 cat conftest.err >&5
c0d27fcc 12066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
e0f712ba
AC
12067 (exit $ac_status); } >/dev/null; then
12068 if test -s conftest.err; then
12069 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 12070 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
e0f712ba
AC
12071 else
12072 ac_cpp_err=
12073 fi
12074else
12075 ac_cpp_err=yes
12076fi
12077if test -z "$ac_cpp_err"; then
c0d27fcc 12078 ac_header_preproc=yes
e0f712ba
AC
12079else
12080 echo "$as_me: failed program was:" >&5
19650fd6
AS
12081sed 's/^/| /' conftest.$ac_ext >&5
12082
c0d27fcc 12083 ac_header_preproc=no
e0f712ba
AC
12084fi
12085rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12086echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12087echo "${ECHO_T}$ac_header_preproc" >&6
12088
12089# So? What about this header?
35996d22
AS
12090case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12091 yes:no: )
c0d27fcc
MR
12092 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
12093echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
12094 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&5
12095echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the compiler's result" >&2;}
12096 ac_header_preproc=yes
19650fd6 12097 ;;
35996d22 12098 no:yes:* )
c0d27fcc
MR
12099 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
12100echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
35996d22
AS
12101 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
12102echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
12103 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&5
12104echo "$as_me: WARNING: Carbon/Carbon.h: see the Autoconf documentation" >&2;}
12105 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&5
12106echo "$as_me: WARNING: Carbon/Carbon.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12107 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
19650fd6 12108echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
12109 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&5
12110echo "$as_me: WARNING: Carbon/Carbon.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12111 (
12112 cat <<\_ASBOX
35996d22
AS
12113## ------------------------------------------ ##
12114## Report this to the AC_PACKAGE_NAME lists. ##
12115## ------------------------------------------ ##
19650fd6
AS
12116_ASBOX
12117 ) |
12118 sed "s/^/$as_me: WARNING: /" >&2
12119 ;;
c0d27fcc
MR
12120esac
12121echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
12122echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
12123if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
12124 echo $ECHO_N "(cached) $ECHO_C" >&6
12125else
12126 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
e0f712ba 12127fi
c0d27fcc 12128echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
e0f712ba 12129echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
c0d27fcc
MR
12130
12131fi
e0f712ba
AC
12132if test $ac_cv_header_Carbon_Carbon_h = yes; then
12133 HAVE_CARBON=yes
12134fi
12135
c0d27fcc 12136
e0f712ba
AC
12137fi
12138
12139if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 12140
c0d27fcc 12141cat >>confdefs.h <<\_ACEOF
e0f712ba 12142#define HAVE_CARBON 1
c0d27fcc 12143_ACEOF
e0f712ba 12144
6a3a24fa
JD
12145 window_system=mac
12146 ## Specify the install directory
12147 carbon_appdir=
12148 if test "${carbon_appdir_x}" != ""; then
12149 case ${carbon_appdir_x} in
12150 y | ye | yes) carbon_appdir=/Applications ;;
12151 * ) carbon_appdir=${carbon_appdir_x} ;;
12152 esac
12153 fi
8f417b3b
AS
12154 # We also have mouse menus.
12155 HAVE_MENUS=yes
e0f712ba
AC
12156fi
12157
98418dba
CW
12158### Use session management (-lSM -lICE) if available
12159HAVE_X_SM=no
12160if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
12161 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12162 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
12163echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12164if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12165 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12166fi
12167echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
12168echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 12169else
c0d27fcc
MR
12170 # Is the header compilable?
12171echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
12172echo $ECHO_N "checking X11/SM/SMlib.h usability... $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. */
c0d27fcc
MR
12179$ac_includes_default
12180#include <X11/SM/SMlib.h>
12181_ACEOF
12182rm -f conftest.$ac_objext
12183if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 12184 (eval $ac_compile) 2>conftest.er1
c0d27fcc 12185 ac_status=$?
35996d22
AS
12186 grep -v '^ *+' conftest.er1 >conftest.err
12187 rm -f conftest.er1
12188 cat conftest.err >&5
c0d27fcc
MR
12189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12190 (exit $ac_status); } &&
4494a266
JD
12191 { ac_try='test -z "$ac_c_werror_flag"
12192 || test ! -s conftest.err'
35996d22
AS
12193 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12194 (eval $ac_try) 2>&5
12195 ac_status=$?
12196 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12197 (exit $ac_status); }; } &&
12198 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12199 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12200 (eval $ac_try) 2>&5
12201 ac_status=$?
12202 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12203 (exit $ac_status); }; }; then
12204 ac_header_compiler=yes
12205else
12206 echo "$as_me: failed program was:" >&5
19650fd6
AS
12207sed 's/^/| /' conftest.$ac_ext >&5
12208
c0d27fcc
MR
12209ac_header_compiler=no
12210fi
35996d22 12211rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12212echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12213echo "${ECHO_T}$ac_header_compiler" >&6
12214
12215# Is the header present?
12216echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
12217echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
12218cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12219/* confdefs.h. */
12220_ACEOF
12221cat confdefs.h >>conftest.$ac_ext
12222cat >>conftest.$ac_ext <<_ACEOF
12223/* end confdefs.h. */
98418dba
CW
12224#include <X11/SM/SMlib.h>
12225_ACEOF
c0d27fcc 12226if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12227 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12228 ac_status=$?
6bae0ccf 12229 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12230 rm -f conftest.er1
12231 cat conftest.err >&5
c0d27fcc 12232 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12233 (exit $ac_status); } >/dev/null; then
12234 if test -s conftest.err; then
12235 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 12236 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
12237 else
12238 ac_cpp_err=
12239 fi
12240else
12241 ac_cpp_err=yes
503d2be0 12242fi
98418dba 12243if test -z "$ac_cpp_err"; then
c0d27fcc 12244 ac_header_preproc=yes
98418dba
CW
12245else
12246 echo "$as_me: failed program was:" >&5
19650fd6
AS
12247sed 's/^/| /' conftest.$ac_ext >&5
12248
c0d27fcc 12249 ac_header_preproc=no
98418dba
CW
12250fi
12251rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12252echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12253echo "${ECHO_T}$ac_header_preproc" >&6
12254
12255# So? What about this header?
35996d22
AS
12256case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12257 yes:no: )
c0d27fcc
MR
12258 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
12259echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
12260 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&5
12261echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the compiler's result" >&2;}
12262 ac_header_preproc=yes
19650fd6 12263 ;;
35996d22 12264 no:yes:* )
c0d27fcc
MR
12265 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
12266echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
35996d22
AS
12267 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
12268echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
12269 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&5
12270echo "$as_me: WARNING: X11/SM/SMlib.h: see the Autoconf documentation" >&2;}
12271 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&5
12272echo "$as_me: WARNING: X11/SM/SMlib.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 12273 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
19650fd6 12274echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
12275 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&5
12276echo "$as_me: WARNING: X11/SM/SMlib.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
12277 (
12278 cat <<\_ASBOX
35996d22
AS
12279## ------------------------------------------ ##
12280## Report this to the AC_PACKAGE_NAME lists. ##
12281## ------------------------------------------ ##
19650fd6
AS
12282_ASBOX
12283 ) |
12284 sed "s/^/$as_me: WARNING: /" >&2
12285 ;;
c0d27fcc
MR
12286esac
12287echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
12288echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
12289if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
12290 echo $ECHO_N "(cached) $ECHO_C" >&6
12291else
12292 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 12293fi
c0d27fcc 12294echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 12295echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
12296
12297fi
98418dba 12298if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 12299 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
12300echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
12301if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 12302 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12303else
503d2be0 12304 ac_check_lib_save_LIBS=$LIBS
1660500f 12305LIBS="-lSM -lICE $LIBS"
503d2be0 12306cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12307/* confdefs.h. */
12308_ACEOF
12309cat confdefs.h >>conftest.$ac_ext
12310cat >>conftest.$ac_ext <<_ACEOF
12311/* end confdefs.h. */
503d2be0 12312
73b77ee5 12313/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12314#ifdef __cplusplus
12315extern "C"
12316#endif
73b77ee5 12317/* We use char because int might match the return type of a gcc2
503d2be0 12318 builtin and then its argument prototype would still apply. */
98418dba 12319char SmcOpenConnection ();
503d2be0
AS
12320int
12321main ()
12322{
98418dba 12323SmcOpenConnection ();
503d2be0
AS
12324 ;
12325 return 0;
12326}
12327_ACEOF
12328rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12329if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12330 (eval $ac_link) 2>conftest.er1
503d2be0 12331 ac_status=$?
35996d22
AS
12332 grep -v '^ *+' conftest.er1 >conftest.err
12333 rm -f conftest.er1
12334 cat conftest.err >&5
c0d27fcc 12335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12336 (exit $ac_status); } &&
4494a266
JD
12337 { ac_try='test -z "$ac_c_werror_flag"
12338 || test ! -s conftest.err'
35996d22
AS
12339 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12340 (eval $ac_try) 2>&5
12341 ac_status=$?
12342 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12343 (exit $ac_status); }; } &&
12344 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12345 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12346 (eval $ac_try) 2>&5
12347 ac_status=$?
c0d27fcc 12348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12349 (exit $ac_status); }; }; then
98418dba 12350 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
12351else
12352 echo "$as_me: failed program was:" >&5
19650fd6
AS
12353sed 's/^/| /' conftest.$ac_ext >&5
12354
98418dba 12355ac_cv_lib_SM_SmcOpenConnection=no
503d2be0 12356fi
35996d22
AS
12357rm -f conftest.err conftest.$ac_objext \
12358 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
12359LIBS=$ac_check_lib_save_LIBS
12360fi
c0d27fcc 12361echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
12362echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
12363if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
12364 HAVE_X_SM=yes
73b77ee5
GM
12365fi
12366
73b77ee5 12367fi
73b77ee5 12368
c0d27fcc
MR
12369
12370
98418dba 12371 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 12372
c0d27fcc 12373cat >>confdefs.h <<\_ACEOF
98418dba 12374#define HAVE_X_SM 1
c0d27fcc 12375_ACEOF
73b77ee5 12376
98418dba
CW
12377 case "$LIBS" in
12378 *-lSM*) ;;
12379 *) LIBS="-lSM -lICE $LIBS" ;;
12380 esac
73b77ee5 12381 fi
98418dba 12382fi
73b77ee5 12383
98418dba 12384# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 12385echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
12386echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
12387if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
12388 echo $ECHO_N "(cached) $ECHO_C" >&6
12389else
12390 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12391/* confdefs.h. */
12392_ACEOF
12393cat confdefs.h >>conftest.$ac_ext
12394cat >>conftest.$ac_ext <<_ACEOF
12395/* end confdefs.h. */
98418dba 12396#include <netdb.h>
503d2be0
AS
12397int
12398main ()
12399{
98418dba 12400return h_errno;
503d2be0
AS
12401 ;
12402 return 0;
12403}
12404_ACEOF
12405rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12406if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12407 (eval $ac_link) 2>conftest.er1
503d2be0 12408 ac_status=$?
35996d22
AS
12409 grep -v '^ *+' conftest.er1 >conftest.err
12410 rm -f conftest.er1
12411 cat conftest.err >&5
c0d27fcc 12412 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12413 (exit $ac_status); } &&
4494a266
JD
12414 { ac_try='test -z "$ac_c_werror_flag"
12415 || test ! -s conftest.err'
35996d22
AS
12416 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12417 (eval $ac_try) 2>&5
12418 ac_status=$?
12419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12420 (exit $ac_status); }; } &&
12421 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12422 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12423 (eval $ac_try) 2>&5
12424 ac_status=$?
c0d27fcc 12425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12426 (exit $ac_status); }; }; then
98418dba 12427 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 12428else
503d2be0 12429 echo "$as_me: failed program was:" >&5
19650fd6
AS
12430sed 's/^/| /' conftest.$ac_ext >&5
12431
98418dba 12432emacs_cv_netdb_declares_h_errno=no
73b77ee5 12433fi
35996d22
AS
12434rm -f conftest.err conftest.$ac_objext \
12435 conftest$ac_exeext conftest.$ac_ext
98418dba 12436fi
c0d27fcc 12437echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
12438echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
12439if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 12440
c0d27fcc 12441cat >>confdefs.h <<\_ACEOF
98418dba 12442#define HAVE_H_ERRNO 1
c0d27fcc 12443_ACEOF
73b77ee5 12444
98418dba
CW
12445fi
12446
12447# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
12448# for constant arguments. Useless!
c0d27fcc 12449echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
12450echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
12451if test "${ac_cv_working_alloca_h+set}" = set; then
12452 echo $ECHO_N "(cached) $ECHO_C" >&6
12453else
12454 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12455/* confdefs.h. */
12456_ACEOF
12457cat confdefs.h >>conftest.$ac_ext
12458cat >>conftest.$ac_ext <<_ACEOF
12459/* end confdefs.h. */
98418dba 12460#include <alloca.h>
503d2be0
AS
12461int
12462main ()
12463{
98418dba 12464char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
12465 ;
12466 return 0;
12467}
12468_ACEOF
12469rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12470if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12471 (eval $ac_link) 2>conftest.er1
503d2be0 12472 ac_status=$?
35996d22
AS
12473 grep -v '^ *+' conftest.er1 >conftest.err
12474 rm -f conftest.er1
12475 cat conftest.err >&5
c0d27fcc 12476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12477 (exit $ac_status); } &&
4494a266
JD
12478 { ac_try='test -z "$ac_c_werror_flag"
12479 || test ! -s conftest.err'
35996d22
AS
12480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12481 (eval $ac_try) 2>&5
12482 ac_status=$?
12483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12484 (exit $ac_status); }; } &&
12485 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12487 (eval $ac_try) 2>&5
12488 ac_status=$?
c0d27fcc 12489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12490 (exit $ac_status); }; }; then
98418dba 12491 ac_cv_working_alloca_h=yes
73b77ee5 12492else
503d2be0 12493 echo "$as_me: failed program was:" >&5
19650fd6
AS
12494sed 's/^/| /' conftest.$ac_ext >&5
12495
98418dba 12496ac_cv_working_alloca_h=no
73b77ee5 12497fi
35996d22
AS
12498rm -f conftest.err conftest.$ac_objext \
12499 conftest$ac_exeext conftest.$ac_ext
98418dba 12500fi
c0d27fcc 12501echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
12502echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
12503if test $ac_cv_working_alloca_h = yes; then
73b77ee5 12504
c0d27fcc 12505cat >>confdefs.h <<\_ACEOF
98418dba 12506#define HAVE_ALLOCA_H 1
c0d27fcc 12507_ACEOF
98418dba
CW
12508
12509fi
12510
c0d27fcc 12511echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
12512echo $ECHO_N "checking for alloca... $ECHO_C" >&6
12513if test "${ac_cv_func_alloca_works+set}" = set; then
12514 echo $ECHO_N "(cached) $ECHO_C" >&6
12515else
503d2be0 12516 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12517/* confdefs.h. */
12518_ACEOF
12519cat confdefs.h >>conftest.$ac_ext
12520cat >>conftest.$ac_ext <<_ACEOF
12521/* end confdefs.h. */
98418dba
CW
12522#ifdef __GNUC__
12523# define alloca __builtin_alloca
12524#else
12525# ifdef _MSC_VER
12526# include <malloc.h>
12527# define alloca _alloca
12528# else
12529# if HAVE_ALLOCA_H
12530# include <alloca.h>
12531# else
12532# ifdef _AIX
12533 #pragma alloca
12534# else
12535# ifndef alloca /* predefined by HP cc +Olibcalls */
12536char *alloca ();
12537# endif
12538# endif
12539# endif
12540# endif
12541#endif
12542
503d2be0
AS
12543int
12544main ()
12545{
98418dba 12546char *p = (char *) alloca (1);
503d2be0
AS
12547 ;
12548 return 0;
12549}
12550_ACEOF
12551rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12552if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12553 (eval $ac_link) 2>conftest.er1
503d2be0 12554 ac_status=$?
35996d22
AS
12555 grep -v '^ *+' conftest.er1 >conftest.err
12556 rm -f conftest.er1
12557 cat conftest.err >&5
c0d27fcc 12558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12559 (exit $ac_status); } &&
4494a266
JD
12560 { ac_try='test -z "$ac_c_werror_flag"
12561 || test ! -s conftest.err'
35996d22
AS
12562 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12563 (eval $ac_try) 2>&5
12564 ac_status=$?
12565 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12566 (exit $ac_status); }; } &&
12567 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12568 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12569 (eval $ac_try) 2>&5
12570 ac_status=$?
c0d27fcc 12571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12572 (exit $ac_status); }; }; then
98418dba 12573 ac_cv_func_alloca_works=yes
ac95a621 12574else
503d2be0 12575 echo "$as_me: failed program was:" >&5
19650fd6
AS
12576sed 's/^/| /' conftest.$ac_ext >&5
12577
98418dba 12578ac_cv_func_alloca_works=no
ac95a621 12579fi
35996d22
AS
12580rm -f conftest.err conftest.$ac_objext \
12581 conftest$ac_exeext conftest.$ac_ext
98418dba 12582fi
c0d27fcc 12583echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 12584echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 12585
98418dba
CW
12586if test $ac_cv_func_alloca_works = yes; then
12587
c0d27fcc 12588cat >>confdefs.h <<\_ACEOF
98418dba 12589#define HAVE_ALLOCA 1
c0d27fcc 12590_ACEOF
98418dba
CW
12591
12592else
12593 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12594# that cause trouble. Some versions do not even contain alloca or
12595# contain a buggy version. If you still want to use their alloca,
12596# use ar to extract alloca.o from them instead of compiling alloca.c.
12597
12598ALLOCA=alloca.$ac_objext
12599
c0d27fcc 12600cat >>confdefs.h <<\_ACEOF
98418dba 12601#define C_ALLOCA 1
c0d27fcc 12602_ACEOF
98418dba 12603
c0d27fcc
MR
12604
12605echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
12606echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
12607if test "${ac_cv_os_cray+set}" = set; then
12608 echo $ECHO_N "(cached) $ECHO_C" >&6
12609else
12610 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12611/* confdefs.h. */
12612_ACEOF
12613cat confdefs.h >>conftest.$ac_ext
12614cat >>conftest.$ac_ext <<_ACEOF
12615/* end confdefs.h. */
98418dba
CW
12616#if defined(CRAY) && ! defined(CRAY2)
12617webecray
12618#else
12619wenotbecray
12620#endif
12621
12622_ACEOF
12623if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 12624 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
12625 ac_cv_os_cray=yes
12626else
12627 ac_cv_os_cray=no
12628fi
12629rm -f conftest*
ac95a621 12630
98418dba 12631fi
c0d27fcc 12632echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
12633echo "${ECHO_T}$ac_cv_os_cray" >&6
12634if test $ac_cv_os_cray = yes; then
12635 for ac_func in _getb67 GETB67 getb67; do
12636 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12637echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12638echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12639if eval "test \"\${$as_ac_var+set}\" = set"; then
12640 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12641else
503d2be0 12642 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12643/* confdefs.h. */
12644_ACEOF
12645cat confdefs.h >>conftest.$ac_ext
12646cat >>conftest.$ac_ext <<_ACEOF
12647/* end confdefs.h. */
35996d22
AS
12648/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12649 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12650#define $ac_func innocuous_$ac_func
12651
73b77ee5 12652/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12653 which can conflict with char $ac_func (); below.
12654 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12655 <limits.h> exists even on freestanding compilers. */
35996d22 12656
19650fd6
AS
12657#ifdef __STDC__
12658# include <limits.h>
12659#else
12660# include <assert.h>
12661#endif
35996d22
AS
12662
12663#undef $ac_func
12664
73b77ee5 12665/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12666#ifdef __cplusplus
12667extern "C"
19650fd6 12668{
503d2be0 12669#endif
73b77ee5 12670/* We use char because int might match the return type of a gcc2
503d2be0
AS
12671 builtin and then its argument prototype would still apply. */
12672char $ac_func ();
73b77ee5
GM
12673/* The GNU C library defines this for functions which it implements
12674 to always fail with ENOSYS. Some functions are actually named
12675 something starting with __ and the normal name is an alias. */
12676#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12677choke me
12678#else
19650fd6
AS
12679char (*f) () = $ac_func;
12680#endif
12681#ifdef __cplusplus
12682}
73b77ee5
GM
12683#endif
12684
19650fd6
AS
12685int
12686main ()
12687{
12688return f != $ac_func;
503d2be0
AS
12689 ;
12690 return 0;
12691}
12692_ACEOF
12693rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12694if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12695 (eval $ac_link) 2>conftest.er1
503d2be0 12696 ac_status=$?
35996d22
AS
12697 grep -v '^ *+' conftest.er1 >conftest.err
12698 rm -f conftest.er1
12699 cat conftest.err >&5
c0d27fcc 12700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12701 (exit $ac_status); } &&
4494a266
JD
12702 { ac_try='test -z "$ac_c_werror_flag"
12703 || test ! -s conftest.err'
35996d22
AS
12704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12705 (eval $ac_try) 2>&5
12706 ac_status=$?
12707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12708 (exit $ac_status); }; } &&
12709 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12711 (eval $ac_try) 2>&5
12712 ac_status=$?
c0d27fcc 12713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12714 (exit $ac_status); }; }; then
12715 eval "$as_ac_var=yes"
12716else
12717 echo "$as_me: failed program was:" >&5
19650fd6
AS
12718sed 's/^/| /' conftest.$ac_ext >&5
12719
503d2be0
AS
12720eval "$as_ac_var=no"
12721fi
35996d22
AS
12722rm -f conftest.err conftest.$ac_objext \
12723 conftest$ac_exeext conftest.$ac_ext
503d2be0 12724fi
c0d27fcc 12725echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12726echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12727if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 12728
c0d27fcc 12729cat >>confdefs.h <<_ACEOF
98418dba 12730#define CRAY_STACKSEG_END $ac_func
c0d27fcc 12731_ACEOF
98418dba
CW
12732
12733 break
73b77ee5 12734fi
73b77ee5 12735
98418dba 12736 done
73b77ee5
GM
12737fi
12738
c0d27fcc 12739echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
12740echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
12741if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 12742 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
12743else
12744 if test "$cross_compiling" = yes; then
12745 ac_cv_c_stack_direction=0
73b77ee5 12746else
503d2be0 12747 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12748/* confdefs.h. */
12749_ACEOF
12750cat confdefs.h >>conftest.$ac_ext
12751cat >>conftest.$ac_ext <<_ACEOF
12752/* end confdefs.h. */
503d2be0 12753int
98418dba 12754find_stack_direction ()
503d2be0 12755{
98418dba
CW
12756 static char *addr = 0;
12757 auto char dummy;
12758 if (addr == 0)
12759 {
12760 addr = &dummy;
12761 return find_stack_direction ();
12762 }
73b77ee5 12763 else
98418dba
CW
12764 return (&dummy > addr) ? 1 : -1;
12765}
ba4481b5 12766
503d2be0
AS
12767int
12768main ()
12769{
98418dba 12770 exit (find_stack_direction () < 0);
503d2be0
AS
12771}
12772_ACEOF
98418dba 12773rm -f conftest$ac_exeext
c0d27fcc 12774if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12775 (eval $ac_link) 2>&5
12776 ac_status=$?
c0d27fcc 12777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12778 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 12779 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12780 (eval $ac_try) 2>&5
12781 ac_status=$?
c0d27fcc 12782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12783 (exit $ac_status); }; }; then
98418dba 12784 ac_cv_c_stack_direction=1
ba4481b5 12785else
98418dba
CW
12786 echo "$as_me: program exited with status $ac_status" >&5
12787echo "$as_me: failed program was:" >&5
19650fd6
AS
12788sed 's/^/| /' conftest.$ac_ext >&5
12789
c0d27fcc 12790( exit $ac_status )
98418dba 12791ac_cv_c_stack_direction=-1
ba4481b5 12792fi
35996d22 12793rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 12794fi
98418dba 12795fi
c0d27fcc 12796echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
12797echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
12798
c0d27fcc 12799cat >>confdefs.h <<_ACEOF
98418dba 12800#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
12801_ACEOF
12802
ba4481b5 12803
ba4481b5
DL
12804fi
12805
c0d27fcc 12806
98418dba
CW
12807# fmod, logb, and frexp are found in -lm on most systems.
12808# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12809
c0d27fcc 12810echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
12811echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
12812if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 12813 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12814else
98418dba
CW
12815 ac_check_lib_save_LIBS=$LIBS
12816LIBS="-lm $LIBS"
12817cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12818/* confdefs.h. */
12819_ACEOF
12820cat confdefs.h >>conftest.$ac_ext
12821cat >>conftest.$ac_ext <<_ACEOF
12822/* end confdefs.h. */
ba4481b5 12823
98418dba
CW
12824/* Override any gcc2 internal prototype to avoid an error. */
12825#ifdef __cplusplus
12826extern "C"
12827#endif
12828/* We use char because int might match the return type of a gcc2
12829 builtin and then its argument prototype would still apply. */
12830char sqrt ();
503d2be0
AS
12831int
12832main ()
12833{
98418dba 12834sqrt ();
503d2be0
AS
12835 ;
12836 return 0;
12837}
12838_ACEOF
12839rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12840if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12841 (eval $ac_link) 2>conftest.er1
503d2be0 12842 ac_status=$?
35996d22
AS
12843 grep -v '^ *+' conftest.er1 >conftest.err
12844 rm -f conftest.er1
12845 cat conftest.err >&5
c0d27fcc 12846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12847 (exit $ac_status); } &&
4494a266
JD
12848 { ac_try='test -z "$ac_c_werror_flag"
12849 || test ! -s conftest.err'
35996d22
AS
12850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12851 (eval $ac_try) 2>&5
12852 ac_status=$?
12853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12854 (exit $ac_status); }; } &&
12855 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12856 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12857 (eval $ac_try) 2>&5
12858 ac_status=$?
c0d27fcc 12859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12860 (exit $ac_status); }; }; then
98418dba 12861 ac_cv_lib_m_sqrt=yes
ba4481b5 12862else
503d2be0 12863 echo "$as_me: failed program was:" >&5
19650fd6
AS
12864sed 's/^/| /' conftest.$ac_ext >&5
12865
98418dba 12866ac_cv_lib_m_sqrt=no
ba4481b5 12867fi
35996d22
AS
12868rm -f conftest.err conftest.$ac_objext \
12869 conftest$ac_exeext conftest.$ac_ext
98418dba 12870LIBS=$ac_check_lib_save_LIBS
ba4481b5 12871fi
c0d27fcc 12872echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
12873echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
12874if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 12875 cat >>confdefs.h <<_ACEOF
98418dba 12876#define HAVE_LIBM 1
c0d27fcc 12877_ACEOF
98418dba
CW
12878
12879 LIBS="-lm $LIBS"
ba4481b5 12880
ba4481b5
DL
12881fi
12882
c0d27fcc 12883
55597d70
DL
12884# Check for mail-locking functions in a "mail" library. Probably this should
12885# have the same check as for liblockfile below.
98418dba 12886
c0d27fcc 12887echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
12888echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
12889if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 12890 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12891else
98418dba
CW
12892 ac_check_lib_save_LIBS=$LIBS
12893LIBS="-lmail $LIBS"
12894cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12895/* confdefs.h. */
12896_ACEOF
12897cat confdefs.h >>conftest.$ac_ext
12898cat >>conftest.$ac_ext <<_ACEOF
12899/* end confdefs.h. */
98418dba
CW
12900
12901/* Override any gcc2 internal prototype to avoid an error. */
12902#ifdef __cplusplus
12903extern "C"
12904#endif
12905/* We use char because int might match the return type of a gcc2
12906 builtin and then its argument prototype would still apply. */
12907char maillock ();
503d2be0
AS
12908int
12909main ()
12910{
98418dba 12911maillock ();
503d2be0
AS
12912 ;
12913 return 0;
12914}
12915_ACEOF
12916rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12917if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12918 (eval $ac_link) 2>conftest.er1
503d2be0 12919 ac_status=$?
35996d22
AS
12920 grep -v '^ *+' conftest.er1 >conftest.err
12921 rm -f conftest.er1
12922 cat conftest.err >&5
c0d27fcc 12923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12924 (exit $ac_status); } &&
4494a266
JD
12925 { ac_try='test -z "$ac_c_werror_flag"
12926 || test ! -s conftest.err'
35996d22
AS
12927 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12928 (eval $ac_try) 2>&5
12929 ac_status=$?
12930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12931 (exit $ac_status); }; } &&
12932 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12933 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12934 (eval $ac_try) 2>&5
12935 ac_status=$?
c0d27fcc 12936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12937 (exit $ac_status); }; }; then
98418dba 12938 ac_cv_lib_mail_maillock=yes
ba4481b5 12939else
503d2be0 12940 echo "$as_me: failed program was:" >&5
19650fd6
AS
12941sed 's/^/| /' conftest.$ac_ext >&5
12942
98418dba 12943ac_cv_lib_mail_maillock=no
ba4481b5 12944fi
35996d22
AS
12945rm -f conftest.err conftest.$ac_objext \
12946 conftest$ac_exeext conftest.$ac_ext
98418dba 12947LIBS=$ac_check_lib_save_LIBS
ba4481b5 12948fi
c0d27fcc 12949echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
12950echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
12951if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 12952 cat >>confdefs.h <<_ACEOF
98418dba 12953#define HAVE_LIBMAIL 1
c0d27fcc 12954_ACEOF
ba4481b5 12955
98418dba 12956 LIBS="-lmail $LIBS"
ba4481b5 12957
98418dba 12958fi
ba4481b5 12959
c0d27fcc
MR
12960
12961echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
12962echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
12963if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 12964 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12965else
503d2be0 12966 ac_check_lib_save_LIBS=$LIBS
98418dba 12967LIBS="-llockfile $LIBS"
503d2be0 12968cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
12969/* confdefs.h. */
12970_ACEOF
12971cat confdefs.h >>conftest.$ac_ext
12972cat >>conftest.$ac_ext <<_ACEOF
12973/* end confdefs.h. */
503d2be0 12974
ba4481b5 12975/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12976#ifdef __cplusplus
12977extern "C"
12978#endif
ba4481b5 12979/* We use char because int might match the return type of a gcc2
503d2be0 12980 builtin and then its argument prototype would still apply. */
98418dba 12981char maillock ();
503d2be0
AS
12982int
12983main ()
12984{
98418dba 12985maillock ();
503d2be0
AS
12986 ;
12987 return 0;
12988}
12989_ACEOF
12990rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12991if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 12992 (eval $ac_link) 2>conftest.er1
503d2be0 12993 ac_status=$?
35996d22
AS
12994 grep -v '^ *+' conftest.er1 >conftest.err
12995 rm -f conftest.er1
12996 cat conftest.err >&5
c0d27fcc 12997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12998 (exit $ac_status); } &&
4494a266
JD
12999 { ac_try='test -z "$ac_c_werror_flag"
13000 || test ! -s conftest.err'
35996d22
AS
13001 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13002 (eval $ac_try) 2>&5
13003 ac_status=$?
13004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13005 (exit $ac_status); }; } &&
13006 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13007 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13008 (eval $ac_try) 2>&5
13009 ac_status=$?
c0d27fcc 13010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13011 (exit $ac_status); }; }; then
98418dba 13012 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
13013else
13014 echo "$as_me: failed program was:" >&5
19650fd6
AS
13015sed 's/^/| /' conftest.$ac_ext >&5
13016
98418dba
CW
13017ac_cv_lib_lockfile_maillock=no
13018fi
35996d22
AS
13019rm -f conftest.err conftest.$ac_objext \
13020 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
13021LIBS=$ac_check_lib_save_LIBS
13022fi
c0d27fcc 13023echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
13024echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
13025if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 13026 cat >>confdefs.h <<_ACEOF
98418dba 13027#define HAVE_LIBLOCKFILE 1
c0d27fcc 13028_ACEOF
98418dba
CW
13029
13030 LIBS="-llockfile $LIBS"
13031
13032fi
13033
13034# If we have the shared liblockfile, assume we must use it for mail
13035# locking (e.g. Debian). If we couldn't link against liblockfile
13036# (no liblockfile.a installed), ensure that we don't need to.
13037if test "$ac_cv_lib_lockfile_maillock" = no; then
13038 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13039set dummy liblockfile.so; ac_word=$2
c0d27fcc 13040echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
13041echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13042if test "${ac_cv_prog_liblockfile+set}" = set; then
13043 echo $ECHO_N "(cached) $ECHO_C" >&6
13044else
13045 if test -n "$liblockfile"; then
13046 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13047else
c0d27fcc 13048as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
13049as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13050for as_dir in $as_dummy
c0d27fcc
MR
13051do
13052 IFS=$as_save_IFS
13053 test -z "$as_dir" && as_dir=.
13054 for ac_exec_ext in '' $ac_executable_extensions; do
13055 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13056 ac_cv_prog_liblockfile="yes"
13057 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13058 break 2
13059 fi
13060done
98418dba
CW
13061done
13062
13063 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 13064fi
503d2be0 13065fi
98418dba
CW
13066liblockfile=$ac_cv_prog_liblockfile
13067if test -n "$liblockfile"; then
c0d27fcc 13068 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
13069echo "${ECHO_T}$liblockfile" >&6
13070else
c0d27fcc 13071 echo "$as_me:$LINENO: result: no" >&5
98418dba 13072echo "${ECHO_T}no" >&6
ba4481b5
DL
13073fi
13074
98418dba 13075 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 13076 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
13077This probably means that movemail could lose mail.
13078There may be a \`development' package to install containing liblockfile." >&5
13079echo "$as_me: error: Shared liblockfile found but can't link against it.
13080This probably means that movemail could lose mail.
13081There may be a \`development' package to install containing liblockfile." >&2;}
13082 { (exit 1); exit 1; }; }
98418dba 13083 else :
55597d70 13084 fi
98418dba 13085fi
503d2be0 13086
98418dba
CW
13087for ac_func in touchlock
13088do
13089as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13090echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13091echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13092if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13093 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 13094else
98418dba 13095 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13096/* confdefs.h. */
13097_ACEOF
13098cat confdefs.h >>conftest.$ac_ext
13099cat >>conftest.$ac_ext <<_ACEOF
13100/* end confdefs.h. */
35996d22
AS
13101/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13102 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13103#define $ac_func innocuous_$ac_func
13104
98418dba 13105/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13106 which can conflict with char $ac_func (); below.
13107 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13108 <limits.h> exists even on freestanding compilers. */
35996d22 13109
19650fd6
AS
13110#ifdef __STDC__
13111# include <limits.h>
13112#else
13113# include <assert.h>
13114#endif
35996d22
AS
13115
13116#undef $ac_func
13117
457b792c 13118/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13119#ifdef __cplusplus
13120extern "C"
19650fd6 13121{
503d2be0 13122#endif
457b792c 13123/* We use char because int might match the return type of a gcc2
503d2be0 13124 builtin and then its argument prototype would still apply. */
98418dba 13125char $ac_func ();
98418dba
CW
13126/* The GNU C library defines this for functions which it implements
13127 to always fail with ENOSYS. Some functions are actually named
13128 something starting with __ and the normal name is an alias. */
13129#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13130choke me
13131#else
19650fd6
AS
13132char (*f) () = $ac_func;
13133#endif
13134#ifdef __cplusplus
13135}
cd958eb3
MB
13136#endif
13137
19650fd6
AS
13138int
13139main ()
13140{
13141return f != $ac_func;
503d2be0
AS
13142 ;
13143 return 0;
13144}
13145_ACEOF
13146rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13147if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13148 (eval $ac_link) 2>conftest.er1
503d2be0 13149 ac_status=$?
35996d22
AS
13150 grep -v '^ *+' conftest.er1 >conftest.err
13151 rm -f conftest.er1
13152 cat conftest.err >&5
c0d27fcc 13153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13154 (exit $ac_status); } &&
4494a266
JD
13155 { ac_try='test -z "$ac_c_werror_flag"
13156 || test ! -s conftest.err'
35996d22
AS
13157 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13158 (eval $ac_try) 2>&5
13159 ac_status=$?
13160 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13161 (exit $ac_status); }; } &&
13162 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13163 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13164 (eval $ac_try) 2>&5
13165 ac_status=$?
c0d27fcc 13166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13167 (exit $ac_status); }; }; then
98418dba 13168 eval "$as_ac_var=yes"
503d2be0
AS
13169else
13170 echo "$as_me: failed program was:" >&5
19650fd6
AS
13171sed 's/^/| /' conftest.$ac_ext >&5
13172
98418dba 13173eval "$as_ac_var=no"
503d2be0 13174fi
35996d22
AS
13175rm -f conftest.err conftest.$ac_objext \
13176 conftest$ac_exeext conftest.$ac_ext
503d2be0 13177fi
c0d27fcc 13178echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13179echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13180if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13181 cat >>confdefs.h <<_ACEOF
98418dba 13182#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13183_ACEOF
457b792c 13184
457b792c 13185fi
98418dba 13186done
457b792c 13187
c0d27fcc 13188
98418dba
CW
13189for ac_header in maillock.h
13190do
13191as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13192if eval "test \"\${$as_ac_Header+set}\" = set"; then
13193 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13194echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13195if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 13196 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13197fi
13198echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13199echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 13200else
c0d27fcc
MR
13201 # Is the header compilable?
13202echo "$as_me:$LINENO: checking $ac_header usability" >&5
13203echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13204cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13205/* confdefs.h. */
13206_ACEOF
13207cat confdefs.h >>conftest.$ac_ext
13208cat >>conftest.$ac_ext <<_ACEOF
13209/* end confdefs.h. */
c0d27fcc
MR
13210$ac_includes_default
13211#include <$ac_header>
13212_ACEOF
13213rm -f conftest.$ac_objext
13214if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13215 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13216 ac_status=$?
35996d22
AS
13217 grep -v '^ *+' conftest.er1 >conftest.err
13218 rm -f conftest.er1
13219 cat conftest.err >&5
c0d27fcc
MR
13220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13221 (exit $ac_status); } &&
4494a266
JD
13222 { ac_try='test -z "$ac_c_werror_flag"
13223 || test ! -s conftest.err'
35996d22
AS
13224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13225 (eval $ac_try) 2>&5
13226 ac_status=$?
13227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13228 (exit $ac_status); }; } &&
13229 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13230 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13231 (eval $ac_try) 2>&5
13232 ac_status=$?
13233 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13234 (exit $ac_status); }; }; then
13235 ac_header_compiler=yes
13236else
13237 echo "$as_me: failed program was:" >&5
19650fd6
AS
13238sed 's/^/| /' conftest.$ac_ext >&5
13239
c0d27fcc
MR
13240ac_header_compiler=no
13241fi
35996d22 13242rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13243echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13244echo "${ECHO_T}$ac_header_compiler" >&6
13245
13246# Is the header present?
13247echo "$as_me:$LINENO: checking $ac_header presence" >&5
13248echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13249cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13250/* confdefs.h. */
13251_ACEOF
13252cat confdefs.h >>conftest.$ac_ext
13253cat >>conftest.$ac_ext <<_ACEOF
13254/* end confdefs.h. */
98418dba 13255#include <$ac_header>
503d2be0 13256_ACEOF
c0d27fcc 13257if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 13258 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 13259 ac_status=$?
6bae0ccf 13260 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13261 rm -f conftest.er1
13262 cat conftest.err >&5
c0d27fcc 13263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13264 (exit $ac_status); } >/dev/null; then
13265 if test -s conftest.err; then
13266 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13267 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
13268 else
13269 ac_cpp_err=
13270 fi
503d2be0 13271else
98418dba 13272 ac_cpp_err=yes
503d2be0 13273fi
98418dba 13274if test -z "$ac_cpp_err"; then
c0d27fcc 13275 ac_header_preproc=yes
98418dba
CW
13276else
13277 echo "$as_me: failed program was:" >&5
19650fd6
AS
13278sed 's/^/| /' conftest.$ac_ext >&5
13279
c0d27fcc 13280 ac_header_preproc=no
503d2be0 13281fi
98418dba 13282rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13283echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13284echo "${ECHO_T}$ac_header_preproc" >&6
13285
13286# So? What about this header?
35996d22
AS
13287case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13288 yes:no: )
c0d27fcc
MR
13289 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13290echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13291 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13292echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13293 ac_header_preproc=yes
19650fd6 13294 ;;
35996d22 13295 no:yes:* )
c0d27fcc
MR
13296 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13297echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13298 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13299echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13300 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13301echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13302 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13303echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13304 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13305echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13306 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13307echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13308 (
13309 cat <<\_ASBOX
35996d22
AS
13310## ------------------------------------------ ##
13311## Report this to the AC_PACKAGE_NAME lists. ##
13312## ------------------------------------------ ##
19650fd6
AS
13313_ASBOX
13314 ) |
13315 sed "s/^/$as_me: WARNING: /" >&2
13316 ;;
c0d27fcc
MR
13317esac
13318echo "$as_me:$LINENO: checking for $ac_header" >&5
13319echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13320if eval "test \"\${$as_ac_Header+set}\" = set"; then
13321 echo $ECHO_N "(cached) $ECHO_C" >&6
13322else
35996d22 13323 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13324fi
c0d27fcc 13325echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13326echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13327
13328fi
98418dba 13329if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13330 cat >>confdefs.h <<_ACEOF
98418dba 13331#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13332_ACEOF
48d4b120 13333
ba4481b5 13334fi
c0d27fcc 13335
98418dba
CW
13336done
13337
c0d27fcc
MR
13338
13339
13340
13341
13342
13343
13344
13345
13346
13347
13348
13349
13350
13351
13352
13353
13354
13355
13356
13357
13358
13359
13360
13361
13362
13363
13364
13365
13366
13367
13368
13369
13370
13371
13372
13373
13374
13375
13376
13377
13378
13379
13380
13381
13382
13383
13384
13385
13386
13387
13388
13389
13390
13391
13392
22044edf
DL
13393
13394
c0d27fcc 13395
b0e44248
RB
13396
13397
973a76b1
DL
13398
13399
13400
cd958eb3 13401
25ca0bca 13402
c0d27fcc
MR
13403
13404
98418dba
CW
13405for ac_func in gethostname getdomainname dup2 \
13406rename closedir mkdir rmdir sysinfo \
13407random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
13408strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
973a76b1 13409utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
98418dba
CW
13410__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
13411sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248 13412gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
4489ece2 13413memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign
98418dba
CW
13414do
13415as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13416echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13417echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13418if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13419 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13420else
503d2be0 13421 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13422/* confdefs.h. */
13423_ACEOF
13424cat confdefs.h >>conftest.$ac_ext
13425cat >>conftest.$ac_ext <<_ACEOF
13426/* end confdefs.h. */
35996d22
AS
13427/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13428 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13429#define $ac_func innocuous_$ac_func
13430
98418dba 13431/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13432 which can conflict with char $ac_func (); below.
13433 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13434 <limits.h> exists even on freestanding compilers. */
35996d22 13435
19650fd6
AS
13436#ifdef __STDC__
13437# include <limits.h>
13438#else
13439# include <assert.h>
13440#endif
35996d22
AS
13441
13442#undef $ac_func
13443
ba4481b5 13444/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13445#ifdef __cplusplus
13446extern "C"
19650fd6 13447{
503d2be0 13448#endif
ba4481b5 13449/* We use char because int might match the return type of a gcc2
503d2be0 13450 builtin and then its argument prototype would still apply. */
98418dba 13451char $ac_func ();
98418dba
CW
13452/* The GNU C library defines this for functions which it implements
13453 to always fail with ENOSYS. Some functions are actually named
13454 something starting with __ and the normal name is an alias. */
13455#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13456choke me
13457#else
19650fd6
AS
13458char (*f) () = $ac_func;
13459#endif
13460#ifdef __cplusplus
13461}
98418dba
CW
13462#endif
13463
19650fd6
AS
13464int
13465main ()
13466{
13467return f != $ac_func;
503d2be0
AS
13468 ;
13469 return 0;
13470}
13471_ACEOF
13472rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13473if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13474 (eval $ac_link) 2>conftest.er1
503d2be0 13475 ac_status=$?
35996d22
AS
13476 grep -v '^ *+' conftest.er1 >conftest.err
13477 rm -f conftest.er1
13478 cat conftest.err >&5
c0d27fcc 13479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13480 (exit $ac_status); } &&
4494a266
JD
13481 { ac_try='test -z "$ac_c_werror_flag"
13482 || test ! -s conftest.err'
35996d22
AS
13483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13484 (eval $ac_try) 2>&5
13485 ac_status=$?
13486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13487 (exit $ac_status); }; } &&
13488 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13490 (eval $ac_try) 2>&5
13491 ac_status=$?
c0d27fcc 13492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13493 (exit $ac_status); }; }; then
98418dba 13494 eval "$as_ac_var=yes"
503d2be0
AS
13495else
13496 echo "$as_me: failed program was:" >&5
19650fd6
AS
13497sed 's/^/| /' conftest.$ac_ext >&5
13498
98418dba 13499eval "$as_ac_var=no"
503d2be0 13500fi
35996d22
AS
13501rm -f conftest.err conftest.$ac_objext \
13502 conftest$ac_exeext conftest.$ac_ext
ba4481b5 13503fi
c0d27fcc 13504echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13505echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13506if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13507 cat >>confdefs.h <<_ACEOF
98418dba 13508#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13509_ACEOF
ba4481b5 13510
ba4481b5 13511fi
98418dba 13512done
ba4481b5 13513
c0d27fcc
MR
13514
13515
98418dba
CW
13516for ac_header in sys/un.h
13517do
13518as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13519if eval "test \"\${$as_ac_Header+set}\" = set"; then
13520 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13521echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13522if eval "test \"\${$as_ac_Header+set}\" = set"; then
13523 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13524fi
13525echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13526echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13527else
c0d27fcc
MR
13528 # Is the header compilable?
13529echo "$as_me:$LINENO: checking $ac_header usability" >&5
13530echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13531cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13532/* confdefs.h. */
13533_ACEOF
13534cat confdefs.h >>conftest.$ac_ext
13535cat >>conftest.$ac_ext <<_ACEOF
13536/* end confdefs.h. */
c0d27fcc
MR
13537$ac_includes_default
13538#include <$ac_header>
13539_ACEOF
13540rm -f conftest.$ac_objext
13541if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13542 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13543 ac_status=$?
35996d22
AS
13544 grep -v '^ *+' conftest.er1 >conftest.err
13545 rm -f conftest.er1
13546 cat conftest.err >&5
c0d27fcc
MR
13547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13548 (exit $ac_status); } &&
4494a266
JD
13549 { ac_try='test -z "$ac_c_werror_flag"
13550 || test ! -s conftest.err'
35996d22
AS
13551 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13552 (eval $ac_try) 2>&5
13553 ac_status=$?
13554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13555 (exit $ac_status); }; } &&
13556 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13557 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13558 (eval $ac_try) 2>&5
13559 ac_status=$?
13560 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13561 (exit $ac_status); }; }; then
13562 ac_header_compiler=yes
13563else
13564 echo "$as_me: failed program was:" >&5
19650fd6
AS
13565sed 's/^/| /' conftest.$ac_ext >&5
13566
c0d27fcc
MR
13567ac_header_compiler=no
13568fi
35996d22 13569rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13570echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13571echo "${ECHO_T}$ac_header_compiler" >&6
13572
13573# Is the header present?
13574echo "$as_me:$LINENO: checking $ac_header presence" >&5
13575echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13576cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13577/* confdefs.h. */
13578_ACEOF
13579cat confdefs.h >>conftest.$ac_ext
13580cat >>conftest.$ac_ext <<_ACEOF
13581/* end confdefs.h. */
98418dba 13582#include <$ac_header>
503d2be0 13583_ACEOF
c0d27fcc 13584if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13585 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13586 ac_status=$?
6bae0ccf 13587 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13588 rm -f conftest.er1
13589 cat conftest.err >&5
c0d27fcc 13590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13591 (exit $ac_status); } >/dev/null; then
13592 if test -s conftest.err; then
13593 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13594 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13595 else
13596 ac_cpp_err=
13597 fi
13598else
13599 ac_cpp_err=yes
13600fi
13601if test -z "$ac_cpp_err"; then
c0d27fcc 13602 ac_header_preproc=yes
ba4481b5 13603else
503d2be0 13604 echo "$as_me: failed program was:" >&5
19650fd6
AS
13605sed 's/^/| /' conftest.$ac_ext >&5
13606
c0d27fcc 13607 ac_header_preproc=no
ba4481b5 13608fi
503d2be0 13609rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13610echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13611echo "${ECHO_T}$ac_header_preproc" >&6
13612
13613# So? What about this header?
35996d22
AS
13614case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13615 yes:no: )
c0d27fcc
MR
13616 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13617echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13618 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13619echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13620 ac_header_preproc=yes
19650fd6 13621 ;;
35996d22 13622 no:yes:* )
c0d27fcc
MR
13623 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13624echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13625 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13626echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13627 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13628echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13629 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13630echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13631 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13632echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13633 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13634echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13635 (
13636 cat <<\_ASBOX
35996d22
AS
13637## ------------------------------------------ ##
13638## Report this to the AC_PACKAGE_NAME lists. ##
13639## ------------------------------------------ ##
19650fd6
AS
13640_ASBOX
13641 ) |
13642 sed "s/^/$as_me: WARNING: /" >&2
13643 ;;
c0d27fcc
MR
13644esac
13645echo "$as_me:$LINENO: checking for $ac_header" >&5
13646echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13647if eval "test \"\${$as_ac_Header+set}\" = set"; then
13648 echo $ECHO_N "(cached) $ECHO_C" >&6
13649else
35996d22 13650 eval "$as_ac_Header=\$ac_header_preproc"
ba4481b5 13651fi
c0d27fcc 13652echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 13653echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13654
13655fi
925c2f3f 13656if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13657 cat >>confdefs.h <<_ACEOF
925c2f3f 13658#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13659_ACEOF
503d2be0 13660
925c2f3f 13661fi
c0d27fcc 13662
925c2f3f
EZ
13663done
13664
c0d27fcc
MR
13665
13666
13667
35996d22
AS
13668
13669for ac_header in stdlib.h sys/time.h unistd.h
925c2f3f
EZ
13670do
13671as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13672if eval "test \"\${$as_ac_Header+set}\" = set"; then
13673 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
13674echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13675if eval "test \"\${$as_ac_Header+set}\" = set"; then
13676 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13677fi
13678echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13679echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 13680else
c0d27fcc
MR
13681 # Is the header compilable?
13682echo "$as_me:$LINENO: checking $ac_header usability" >&5
13683echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13684cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13685/* confdefs.h. */
13686_ACEOF
13687cat confdefs.h >>conftest.$ac_ext
13688cat >>conftest.$ac_ext <<_ACEOF
13689/* end confdefs.h. */
c0d27fcc
MR
13690$ac_includes_default
13691#include <$ac_header>
13692_ACEOF
13693rm -f conftest.$ac_objext
13694if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 13695 (eval $ac_compile) 2>conftest.er1
c0d27fcc 13696 ac_status=$?
35996d22
AS
13697 grep -v '^ *+' conftest.er1 >conftest.err
13698 rm -f conftest.er1
13699 cat conftest.err >&5
c0d27fcc
MR
13700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13701 (exit $ac_status); } &&
4494a266
JD
13702 { ac_try='test -z "$ac_c_werror_flag"
13703 || test ! -s conftest.err'
35996d22
AS
13704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13705 (eval $ac_try) 2>&5
13706 ac_status=$?
13707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13708 (exit $ac_status); }; } &&
13709 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13711 (eval $ac_try) 2>&5
13712 ac_status=$?
13713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13714 (exit $ac_status); }; }; then
13715 ac_header_compiler=yes
13716else
13717 echo "$as_me: failed program was:" >&5
19650fd6
AS
13718sed 's/^/| /' conftest.$ac_ext >&5
13719
c0d27fcc
MR
13720ac_header_compiler=no
13721fi
35996d22 13722rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13723echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13724echo "${ECHO_T}$ac_header_compiler" >&6
13725
13726# Is the header present?
13727echo "$as_me:$LINENO: checking $ac_header presence" >&5
13728echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13729cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13730/* confdefs.h. */
13731_ACEOF
13732cat confdefs.h >>conftest.$ac_ext
13733cat >>conftest.$ac_ext <<_ACEOF
13734/* end confdefs.h. */
98418dba 13735#include <$ac_header>
503d2be0 13736_ACEOF
c0d27fcc 13737if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13738 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13739 ac_status=$?
6bae0ccf 13740 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13741 rm -f conftest.er1
13742 cat conftest.err >&5
c0d27fcc 13743 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13744 (exit $ac_status); } >/dev/null; then
13745 if test -s conftest.err; then
13746 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 13747 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
13748 else
13749 ac_cpp_err=
13750 fi
13751else
13752 ac_cpp_err=yes
13753fi
13754if test -z "$ac_cpp_err"; then
c0d27fcc 13755 ac_header_preproc=yes
98418dba
CW
13756else
13757 echo "$as_me: failed program was:" >&5
19650fd6
AS
13758sed 's/^/| /' conftest.$ac_ext >&5
13759
c0d27fcc 13760 ac_header_preproc=no
98418dba
CW
13761fi
13762rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13763echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13764echo "${ECHO_T}$ac_header_preproc" >&6
13765
13766# So? What about this header?
35996d22
AS
13767case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13768 yes:no: )
c0d27fcc
MR
13769 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13770echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
13771 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13772echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13773 ac_header_preproc=yes
19650fd6 13774 ;;
35996d22 13775 no:yes:* )
c0d27fcc
MR
13776 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13777echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
13778 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13779echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13780 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13781echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13782 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
13783echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 13784 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13785echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
13786 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13787echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
13788 (
13789 cat <<\_ASBOX
35996d22
AS
13790## ------------------------------------------ ##
13791## Report this to the AC_PACKAGE_NAME lists. ##
13792## ------------------------------------------ ##
19650fd6
AS
13793_ASBOX
13794 ) |
13795 sed "s/^/$as_me: WARNING: /" >&2
13796 ;;
c0d27fcc
MR
13797esac
13798echo "$as_me:$LINENO: checking for $ac_header" >&5
13799echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13800if eval "test \"\${$as_ac_Header+set}\" = set"; then
13801 echo $ECHO_N "(cached) $ECHO_C" >&6
13802else
35996d22 13803 eval "$as_ac_Header=\$ac_header_preproc"
ffe36136 13804fi
c0d27fcc 13805echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13806echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13807
13808fi
98418dba 13809if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13810 cat >>confdefs.h <<_ACEOF
98418dba 13811#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13812_ACEOF
98418dba
CW
13813
13814fi
c0d27fcc 13815
98418dba
CW
13816done
13817
c0d27fcc 13818
98418dba
CW
13819for ac_func in alarm
13820do
13821as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13822echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13823echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13824if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13825 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13826else
98418dba 13827 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13828/* confdefs.h. */
13829_ACEOF
13830cat confdefs.h >>conftest.$ac_ext
13831cat >>conftest.$ac_ext <<_ACEOF
13832/* end confdefs.h. */
35996d22
AS
13833/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13834 For example, HP-UX 11i <limits.h> declares gettimeofday. */
13835#define $ac_func innocuous_$ac_func
13836
98418dba 13837/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13838 which can conflict with char $ac_func (); below.
13839 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13840 <limits.h> exists even on freestanding compilers. */
35996d22 13841
19650fd6
AS
13842#ifdef __STDC__
13843# include <limits.h>
13844#else
13845# include <assert.h>
13846#endif
35996d22
AS
13847
13848#undef $ac_func
13849
ba4481b5 13850/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13851#ifdef __cplusplus
13852extern "C"
19650fd6 13853{
503d2be0 13854#endif
ba4481b5 13855/* We use char because int might match the return type of a gcc2
503d2be0 13856 builtin and then its argument prototype would still apply. */
98418dba 13857char $ac_func ();
98418dba
CW
13858/* The GNU C library defines this for functions which it implements
13859 to always fail with ENOSYS. Some functions are actually named
13860 something starting with __ and the normal name is an alias. */
13861#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13862choke me
13863#else
19650fd6
AS
13864char (*f) () = $ac_func;
13865#endif
13866#ifdef __cplusplus
13867}
98418dba
CW
13868#endif
13869
19650fd6
AS
13870int
13871main ()
13872{
13873return f != $ac_func;
503d2be0
AS
13874 ;
13875 return 0;
13876}
13877_ACEOF
13878rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13879if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 13880 (eval $ac_link) 2>conftest.er1
503d2be0 13881 ac_status=$?
35996d22
AS
13882 grep -v '^ *+' conftest.er1 >conftest.err
13883 rm -f conftest.er1
13884 cat conftest.err >&5
c0d27fcc 13885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13886 (exit $ac_status); } &&
4494a266
JD
13887 { ac_try='test -z "$ac_c_werror_flag"
13888 || test ! -s conftest.err'
35996d22
AS
13889 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13890 (eval $ac_try) 2>&5
13891 ac_status=$?
13892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13893 (exit $ac_status); }; } &&
13894 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13895 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13896 (eval $ac_try) 2>&5
13897 ac_status=$?
c0d27fcc 13898 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13899 (exit $ac_status); }; }; then
98418dba 13900 eval "$as_ac_var=yes"
503d2be0
AS
13901else
13902 echo "$as_me: failed program was:" >&5
19650fd6
AS
13903sed 's/^/| /' conftest.$ac_ext >&5
13904
98418dba 13905eval "$as_ac_var=no"
503d2be0 13906fi
35996d22
AS
13907rm -f conftest.err conftest.$ac_objext \
13908 conftest$ac_exeext conftest.$ac_ext
ffe36136 13909fi
c0d27fcc 13910echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13911echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13912if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13913 cat >>confdefs.h <<_ACEOF
98418dba 13914#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13915_ACEOF
ffe36136 13916
ba4481b5 13917fi
98418dba 13918done
ba4481b5 13919
c0d27fcc 13920echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
13921echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
13922if test "${ac_cv_func_working_mktime+set}" = set; then
13923 echo $ECHO_N "(cached) $ECHO_C" >&6
13924else
13925 if test "$cross_compiling" = yes; then
13926 ac_cv_func_working_mktime=no
13927else
13928 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
13929/* confdefs.h. */
13930_ACEOF
13931cat confdefs.h >>conftest.$ac_ext
13932cat >>conftest.$ac_ext <<_ACEOF
13933/* end confdefs.h. */
98418dba
CW
13934/* Test program from Paul Eggert and Tony Leneis. */
13935#if TIME_WITH_SYS_TIME
13936# include <sys/time.h>
13937# include <time.h>
13938#else
13939# if HAVE_SYS_TIME_H
13940# include <sys/time.h>
13941# else
13942# include <time.h>
13943# endif
13944#endif
ba4481b5 13945
35996d22
AS
13946#if HAVE_STDLIB_H
13947# include <stdlib.h>
13948#endif
13949
98418dba
CW
13950#if HAVE_UNISTD_H
13951# include <unistd.h>
13952#endif
ba4481b5 13953
98418dba
CW
13954#if !HAVE_ALARM
13955# define alarm(X) /* empty */
13956#endif
df645f7c 13957
98418dba
CW
13958/* Work around redefinition to rpl_putenv by other config tests. */
13959#undef putenv
df645f7c 13960
98418dba 13961static time_t time_t_max;
35996d22 13962static time_t time_t_min;
df645f7c 13963
98418dba 13964/* Values we'll use to set the TZ environment variable. */
35996d22
AS
13965static char *tz_strings[] = {
13966 (char *) 0, "TZ=GMT0", "TZ=JST-9",
98418dba
CW
13967 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
13968};
13969#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 13970
98418dba
CW
13971/* Fail if mktime fails to convert a date in the spring-forward gap.
13972 Based on a problem report from Andreas Jaeger. */
13973static void
13974spring_forward_gap ()
13975{
13976 /* glibc (up to about 1998-10-07) failed this test. */
13977 struct tm tm;
13978
13979 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
13980 instead of "TZ=America/Vancouver" in order to detect the bug even
13981 on systems that don't support the Olson extension, or don't have the
13982 full zoneinfo tables installed. */
13983 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
13984
13985 tm.tm_year = 98;
13986 tm.tm_mon = 3;
13987 tm.tm_mday = 5;
13988 tm.tm_hour = 2;
13989 tm.tm_min = 0;
13990 tm.tm_sec = 0;
13991 tm.tm_isdst = -1;
13992 if (mktime (&tm) == (time_t)-1)
13993 exit (1);
13994}
13995
13996static void
35996d22 13997mktime_test1 (now)
98418dba
CW
13998 time_t now;
13999{
14000 struct tm *lt;
14001 if ((lt = localtime (&now)) && mktime (lt) != now)
14002 exit (1);
35996d22
AS
14003}
14004
14005static void
14006mktime_test (now)
14007 time_t now;
14008{
14009 mktime_test1 (now);
14010 mktime_test1 ((time_t) (time_t_max - now));
14011 mktime_test1 ((time_t) (time_t_min + now));
98418dba
CW
14012}
14013
14014static void
14015irix_6_4_bug ()
14016{
14017 /* Based on code from Ariel Faigon. */
14018 struct tm tm;
14019 tm.tm_year = 96;
14020 tm.tm_mon = 3;
14021 tm.tm_mday = 0;
14022 tm.tm_hour = 0;
14023 tm.tm_min = 0;
14024 tm.tm_sec = 0;
14025 tm.tm_isdst = -1;
14026 mktime (&tm);
14027 if (tm.tm_mon != 2 || tm.tm_mday != 31)
14028 exit (1);
14029}
14030
14031static void
14032bigtime_test (j)
14033 int j;
14034{
14035 struct tm tm;
14036 time_t now;
14037 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
14038 now = mktime (&tm);
14039 if (now != (time_t) -1)
14040 {
14041 struct tm *lt = localtime (&now);
14042 if (! (lt
14043 && lt->tm_year == tm.tm_year
14044 && lt->tm_mon == tm.tm_mon
14045 && lt->tm_mday == tm.tm_mday
14046 && lt->tm_hour == tm.tm_hour
14047 && lt->tm_min == tm.tm_min
14048 && lt->tm_sec == tm.tm_sec
14049 && lt->tm_yday == tm.tm_yday
14050 && lt->tm_wday == tm.tm_wday
14051 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
14052 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
14053 exit (1);
14054 }
14055}
14056
14057int
14058main ()
14059{
14060 time_t t, delta;
14061 int i, j;
14062
14063 /* This test makes some buggy mktime implementations loop.
14064 Give up after 60 seconds; a mktime slower than that
14065 isn't worth using anyway. */
14066 alarm (60);
14067
14068 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
14069 continue;
14070 time_t_max--;
35996d22
AS
14071 if ((time_t) -1 < 0)
14072 for (time_t_min = -1; (time_t) (time_t_min * 2) < 0; time_t_min *= 2)
14073 continue;
98418dba
CW
14074 delta = time_t_max / 997; /* a suitable prime number */
14075 for (i = 0; i < N_STRINGS; i++)
14076 {
14077 if (tz_strings[i])
14078 putenv (tz_strings[i]);
503d2be0 14079
98418dba
CW
14080 for (t = 0; t <= time_t_max - delta; t += delta)
14081 mktime_test (t);
35996d22
AS
14082 mktime_test ((time_t) 1);
14083 mktime_test ((time_t) (60 * 60));
14084 mktime_test ((time_t) (60 * 60 * 24));
98418dba
CW
14085
14086 for (j = 1; 0 < j; j *= 2)
35996d22 14087 bigtime_test (j);
98418dba
CW
14088 bigtime_test (j - 1);
14089 }
14090 irix_6_4_bug ();
14091 spring_forward_gap ();
14092 exit (0);
503d2be0
AS
14093}
14094_ACEOF
98418dba 14095rm -f conftest$ac_exeext
c0d27fcc 14096if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14097 (eval $ac_link) 2>&5
14098 ac_status=$?
c0d27fcc 14099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14100 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 14101 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14102 (eval $ac_try) 2>&5
14103 ac_status=$?
c0d27fcc 14104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14105 (exit $ac_status); }; }; then
98418dba 14106 ac_cv_func_working_mktime=yes
503d2be0 14107else
98418dba
CW
14108 echo "$as_me: program exited with status $ac_status" >&5
14109echo "$as_me: failed program was:" >&5
19650fd6
AS
14110sed 's/^/| /' conftest.$ac_ext >&5
14111
c0d27fcc 14112( exit $ac_status )
98418dba 14113ac_cv_func_working_mktime=no
503d2be0 14114fi
35996d22 14115rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 14116fi
ba4481b5 14117fi
c0d27fcc 14118echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
14119echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
14120if test $ac_cv_func_working_mktime = no; then
35996d22
AS
14121 case $LIBOBJS in
14122 "mktime.$ac_objext" | \
14123 *" mktime.$ac_objext" | \
14124 "mktime.$ac_objext "* | \
14125 *" mktime.$ac_objext "* ) ;;
14126 *) LIBOBJS="$LIBOBJS mktime.$ac_objext" ;;
14127esac
14128
ba4481b5
DL
14129fi
14130
98418dba 14131if test "$ac_cv_func_working_mktime" = no; then
b936fae4 14132
c0d27fcc 14133cat >>confdefs.h <<\_ACEOF
98418dba 14134#define BROKEN_MKTIME 1
c0d27fcc 14135_ACEOF
ba4481b5 14136
ba4481b5 14137fi
503d2be0 14138
98418dba
CW
14139ac_have_func=no # yes means we've found a way to get the load average.
14140
6bae0ccf
DL
14141# Make sure getloadavg.c is where it belongs, at configure-time.
14142test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
14143 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
14144echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
14145 { (exit 1); exit 1; }; }
14146
98418dba
CW
14147ac_save_LIBS=$LIBS
14148
14149# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 14150(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
14151echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
14152if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 14153 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14154else
503d2be0 14155 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14156/* confdefs.h. */
14157_ACEOF
14158cat confdefs.h >>conftest.$ac_ext
14159cat >>conftest.$ac_ext <<_ACEOF
14160/* end confdefs.h. */
35996d22
AS
14161/* Define getloadavg to an innocuous variant, in case <limits.h> declares getloadavg.
14162 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14163#define getloadavg innocuous_getloadavg
14164
98418dba 14165/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14166 which can conflict with char getloadavg (); below.
14167 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14168 <limits.h> exists even on freestanding compilers. */
35996d22 14169
19650fd6
AS
14170#ifdef __STDC__
14171# include <limits.h>
14172#else
14173# include <assert.h>
14174#endif
35996d22
AS
14175
14176#undef getloadavg
14177
ba4481b5 14178/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14179#ifdef __cplusplus
14180extern "C"
19650fd6 14181{
503d2be0 14182#endif
ba4481b5 14183/* We use char because int might match the return type of a gcc2
503d2be0 14184 builtin and then its argument prototype would still apply. */
98418dba 14185char getloadavg ();
98418dba
CW
14186/* The GNU C library defines this for functions which it implements
14187 to always fail with ENOSYS. Some functions are actually named
14188 something starting with __ and the normal name is an alias. */
14189#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
14190choke me
14191#else
19650fd6
AS
14192char (*f) () = getloadavg;
14193#endif
14194#ifdef __cplusplus
14195}
cd958eb3
MB
14196#endif
14197
19650fd6
AS
14198int
14199main ()
14200{
14201return f != getloadavg;
503d2be0
AS
14202 ;
14203 return 0;
14204}
14205_ACEOF
14206rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14207if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14208 (eval $ac_link) 2>conftest.er1
503d2be0 14209 ac_status=$?
35996d22
AS
14210 grep -v '^ *+' conftest.er1 >conftest.err
14211 rm -f conftest.er1
14212 cat conftest.err >&5
c0d27fcc 14213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14214 (exit $ac_status); } &&
4494a266
JD
14215 { ac_try='test -z "$ac_c_werror_flag"
14216 || test ! -s conftest.err'
35996d22
AS
14217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14218 (eval $ac_try) 2>&5
14219 ac_status=$?
14220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14221 (exit $ac_status); }; } &&
14222 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14223 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14224 (eval $ac_try) 2>&5
14225 ac_status=$?
c0d27fcc 14226 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14227 (exit $ac_status); }; }; then
98418dba 14228 ac_cv_func_getloadavg=yes
503d2be0
AS
14229else
14230 echo "$as_me: failed program was:" >&5
19650fd6
AS
14231sed 's/^/| /' conftest.$ac_ext >&5
14232
98418dba 14233ac_cv_func_getloadavg=no
503d2be0 14234fi
35996d22
AS
14235rm -f conftest.err conftest.$ac_objext \
14236 conftest$ac_exeext conftest.$ac_ext
ba4481b5 14237fi
c0d27fcc 14238echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
14239echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
14240if test $ac_cv_func_getloadavg = yes; then
14241 exit 0
14242else
14243 exit 1
ba4481b5 14244fi
98418dba 14245) && ac_have_func=yes
ba4481b5 14246
98418dba 14247# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 14248
98418dba
CW
14249for ac_func in pstat_getdynamic
14250do
14251as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14252echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
14253echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14254if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 14255 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14256else
503d2be0 14257 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14258/* confdefs.h. */
14259_ACEOF
14260cat confdefs.h >>conftest.$ac_ext
14261cat >>conftest.$ac_ext <<_ACEOF
14262/* end confdefs.h. */
35996d22
AS
14263/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14264 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14265#define $ac_func innocuous_$ac_func
14266
98418dba 14267/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14268 which can conflict with char $ac_func (); below.
14269 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14270 <limits.h> exists even on freestanding compilers. */
35996d22 14271
19650fd6
AS
14272#ifdef __STDC__
14273# include <limits.h>
14274#else
14275# include <assert.h>
14276#endif
35996d22
AS
14277
14278#undef $ac_func
14279
ba4481b5 14280/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14281#ifdef __cplusplus
14282extern "C"
19650fd6 14283{
503d2be0 14284#endif
ba4481b5 14285/* We use char because int might match the return type of a gcc2
503d2be0 14286 builtin and then its argument prototype would still apply. */
98418dba 14287char $ac_func ();
98418dba
CW
14288/* The GNU C library defines this for functions which it implements
14289 to always fail with ENOSYS. Some functions are actually named
14290 something starting with __ and the normal name is an alias. */
14291#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14292choke me
14293#else
19650fd6
AS
14294char (*f) () = $ac_func;
14295#endif
14296#ifdef __cplusplus
14297}
98418dba
CW
14298#endif
14299
19650fd6
AS
14300int
14301main ()
14302{
14303return f != $ac_func;
98418dba
CW
14304 ;
14305 return 0;
14306}
f21fadcc 14307_ACEOF
98418dba 14308rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14309if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14310 (eval $ac_link) 2>conftest.er1
f21fadcc 14311 ac_status=$?
35996d22
AS
14312 grep -v '^ *+' conftest.er1 >conftest.err
14313 rm -f conftest.er1
14314 cat conftest.err >&5
c0d27fcc 14315 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14316 (exit $ac_status); } &&
4494a266
JD
14317 { ac_try='test -z "$ac_c_werror_flag"
14318 || test ! -s conftest.err'
35996d22
AS
14319 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14320 (eval $ac_try) 2>&5
14321 ac_status=$?
14322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14323 (exit $ac_status); }; } &&
14324 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14325 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14326 (eval $ac_try) 2>&5
14327 ac_status=$?
c0d27fcc 14328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14329 (exit $ac_status); }; }; then
14330 eval "$as_ac_var=yes"
f21fadcc
JD
14331else
14332 echo "$as_me: failed program was:" >&5
19650fd6
AS
14333sed 's/^/| /' conftest.$ac_ext >&5
14334
98418dba 14335eval "$as_ac_var=no"
f21fadcc 14336fi
35996d22
AS
14337rm -f conftest.err conftest.$ac_objext \
14338 conftest$ac_exeext conftest.$ac_ext
f21fadcc 14339fi
c0d27fcc 14340echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
14341echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14342if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14343 cat >>confdefs.h <<_ACEOF
98418dba 14344#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14345_ACEOF
98418dba
CW
14346
14347fi
14348done
14349
c0d27fcc 14350
98418dba
CW
14351# Solaris has libkstat which does not require root.
14352
c0d27fcc 14353echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
14354echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
14355if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
14356 echo $ECHO_N "(cached) $ECHO_C" >&6
14357else
14358 ac_check_lib_save_LIBS=$LIBS
98418dba 14359LIBS="-lkstat $LIBS"
f21fadcc 14360cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14361/* confdefs.h. */
14362_ACEOF
14363cat confdefs.h >>conftest.$ac_ext
14364cat >>conftest.$ac_ext <<_ACEOF
14365/* end confdefs.h. */
f21fadcc
JD
14366
14367/* Override any gcc2 internal prototype to avoid an error. */
14368#ifdef __cplusplus
14369extern "C"
14370#endif
14371/* We use char because int might match the return type of a gcc2
14372 builtin and then its argument prototype would still apply. */
98418dba 14373char kstat_open ();
f21fadcc
JD
14374int
14375main ()
14376{
98418dba 14377kstat_open ();
f21fadcc
JD
14378 ;
14379 return 0;
14380}
14381_ACEOF
14382rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14383if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14384 (eval $ac_link) 2>conftest.er1
f21fadcc 14385 ac_status=$?
35996d22
AS
14386 grep -v '^ *+' conftest.er1 >conftest.err
14387 rm -f conftest.er1
14388 cat conftest.err >&5
c0d27fcc 14389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14390 (exit $ac_status); } &&
4494a266
JD
14391 { ac_try='test -z "$ac_c_werror_flag"
14392 || test ! -s conftest.err'
35996d22
AS
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); }; } &&
14398 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14399 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
14400 (eval $ac_try) 2>&5
14401 ac_status=$?
c0d27fcc 14402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 14403 (exit $ac_status); }; }; then
98418dba 14404 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
14405else
14406 echo "$as_me: failed program was:" >&5
19650fd6
AS
14407sed 's/^/| /' conftest.$ac_ext >&5
14408
98418dba 14409ac_cv_lib_kstat_kstat_open=no
f21fadcc 14410fi
35996d22
AS
14411rm -f conftest.err conftest.$ac_objext \
14412 conftest$ac_exeext conftest.$ac_ext
f21fadcc
JD
14413LIBS=$ac_check_lib_save_LIBS
14414fi
c0d27fcc 14415echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
14416echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
14417if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 14418 cat >>confdefs.h <<_ACEOF
98418dba 14419#define HAVE_LIBKSTAT 1
c0d27fcc 14420_ACEOF
f21fadcc 14421
98418dba 14422 LIBS="-lkstat $LIBS"
f21fadcc 14423
f21fadcc
JD
14424fi
14425
98418dba
CW
14426test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
14427
14428# Some systems with -lutil have (and need) -lkvm as well, some do not.
14429# On Solaris, -lkvm requires nlist from -lelf, so check that first
14430# to get the right answer into the cache.
14431# For kstat on solaris, we need libelf to force the definition of SVR4 below.
14432if test $ac_have_func = no; then
c0d27fcc 14433 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
14434echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
14435if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 14436 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14437else
98418dba
CW
14438 ac_check_lib_save_LIBS=$LIBS
14439LIBS="-lelf $LIBS"
14440cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14441/* confdefs.h. */
14442_ACEOF
14443cat confdefs.h >>conftest.$ac_ext
14444cat >>conftest.$ac_ext <<_ACEOF
14445/* end confdefs.h. */
98418dba
CW
14446
14447/* Override any gcc2 internal prototype to avoid an error. */
14448#ifdef __cplusplus
14449extern "C"
14450#endif
14451/* We use char because int might match the return type of a gcc2
14452 builtin and then its argument prototype would still apply. */
14453char elf_begin ();
503d2be0
AS
14454int
14455main ()
14456{
98418dba 14457elf_begin ();
503d2be0
AS
14458 ;
14459 return 0;
14460}
14461_ACEOF
14462rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14463if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14464 (eval $ac_link) 2>conftest.er1
503d2be0 14465 ac_status=$?
35996d22
AS
14466 grep -v '^ *+' conftest.er1 >conftest.err
14467 rm -f conftest.er1
14468 cat conftest.err >&5
c0d27fcc 14469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14470 (exit $ac_status); } &&
4494a266
JD
14471 { ac_try='test -z "$ac_c_werror_flag"
14472 || test ! -s conftest.err'
35996d22
AS
14473 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14474 (eval $ac_try) 2>&5
14475 ac_status=$?
14476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14477 (exit $ac_status); }; } &&
14478 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14479 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14480 (eval $ac_try) 2>&5
14481 ac_status=$?
c0d27fcc 14482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14483 (exit $ac_status); }; }; then
98418dba 14484 ac_cv_lib_elf_elf_begin=yes
ba4481b5 14485else
503d2be0 14486 echo "$as_me: failed program was:" >&5
19650fd6
AS
14487sed 's/^/| /' conftest.$ac_ext >&5
14488
98418dba 14489ac_cv_lib_elf_elf_begin=no
ba4481b5 14490fi
35996d22
AS
14491rm -f conftest.err conftest.$ac_objext \
14492 conftest$ac_exeext conftest.$ac_ext
98418dba 14493LIBS=$ac_check_lib_save_LIBS
ba4481b5 14494fi
c0d27fcc 14495echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
14496echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
14497if test $ac_cv_lib_elf_elf_begin = yes; then
14498 LIBS="-lelf $LIBS"
ba4481b5
DL
14499fi
14500
98418dba
CW
14501fi
14502if test $ac_have_func = no; then
c0d27fcc 14503 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
14504echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
14505if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 14506 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14507else
98418dba
CW
14508 ac_check_lib_save_LIBS=$LIBS
14509LIBS="-lkvm $LIBS"
14510cat >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. */
98418dba
CW
14516
14517/* Override any gcc2 internal prototype to avoid an error. */
14518#ifdef __cplusplus
14519extern "C"
14520#endif
14521/* We use char because int might match the return type of a gcc2
14522 builtin and then its argument prototype would still apply. */
14523char kvm_open ();
503d2be0
AS
14524int
14525main ()
14526{
98418dba 14527kvm_open ();
503d2be0
AS
14528 ;
14529 return 0;
14530}
14531_ACEOF
14532rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14533if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14534 (eval $ac_link) 2>conftest.er1
503d2be0 14535 ac_status=$?
35996d22
AS
14536 grep -v '^ *+' conftest.er1 >conftest.err
14537 rm -f conftest.er1
14538 cat conftest.err >&5
c0d27fcc 14539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14540 (exit $ac_status); } &&
4494a266
JD
14541 { ac_try='test -z "$ac_c_werror_flag"
14542 || test ! -s conftest.err'
35996d22
AS
14543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14544 (eval $ac_try) 2>&5
14545 ac_status=$?
14546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14547 (exit $ac_status); }; } &&
14548 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14549 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14550 (eval $ac_try) 2>&5
14551 ac_status=$?
c0d27fcc 14552 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14553 (exit $ac_status); }; }; then
98418dba 14554 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
14555else
14556 echo "$as_me: failed program was:" >&5
19650fd6
AS
14557sed 's/^/| /' conftest.$ac_ext >&5
14558
98418dba 14559ac_cv_lib_kvm_kvm_open=no
503d2be0 14560fi
35996d22
AS
14561rm -f conftest.err conftest.$ac_objext \
14562 conftest$ac_exeext conftest.$ac_ext
98418dba 14563LIBS=$ac_check_lib_save_LIBS
503d2be0 14564fi
c0d27fcc 14565echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
14566echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
14567if test $ac_cv_lib_kvm_kvm_open = yes; then
14568 LIBS="-lkvm $LIBS"
ba4481b5
DL
14569fi
14570
98418dba 14571 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 14572 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
14573echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
14574if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 14575 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14576else
98418dba
CW
14577 ac_check_lib_save_LIBS=$LIBS
14578LIBS="-lutil $LIBS"
14579cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14580/* confdefs.h. */
14581_ACEOF
14582cat confdefs.h >>conftest.$ac_ext
14583cat >>conftest.$ac_ext <<_ACEOF
14584/* end confdefs.h. */
98418dba
CW
14585
14586/* Override any gcc2 internal prototype to avoid an error. */
14587#ifdef __cplusplus
14588extern "C"
14589#endif
14590/* We use char because int might match the return type of a gcc2
14591 builtin and then its argument prototype would still apply. */
14592char getloadavg ();
503d2be0
AS
14593int
14594main ()
14595{
98418dba 14596getloadavg ();
503d2be0
AS
14597 ;
14598 return 0;
14599}
14600_ACEOF
14601rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14602if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14603 (eval $ac_link) 2>conftest.er1
503d2be0 14604 ac_status=$?
35996d22
AS
14605 grep -v '^ *+' conftest.er1 >conftest.err
14606 rm -f conftest.er1
14607 cat conftest.err >&5
c0d27fcc 14608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14609 (exit $ac_status); } &&
4494a266
JD
14610 { ac_try='test -z "$ac_c_werror_flag"
14611 || test ! -s conftest.err'
c0d27fcc 14612 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14613 (eval $ac_try) 2>&5
14614 ac_status=$?
c0d27fcc 14615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
35996d22
AS
14616 (exit $ac_status); }; } &&
14617 { ac_try='test -s conftest$ac_exeext'
14618 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14619 (eval $ac_try) 2>&5
14620 ac_status=$?
14621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14622 (exit $ac_status); }; }; then
14623 ac_cv_lib_util_getloadavg=yes
14624else
503d2be0 14625 echo "$as_me: failed program was:" >&5
19650fd6
AS
14626sed 's/^/| /' conftest.$ac_ext >&5
14627
98418dba 14628ac_cv_lib_util_getloadavg=no
ba4481b5 14629fi
35996d22
AS
14630rm -f conftest.err conftest.$ac_objext \
14631 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14632LIBS=$ac_check_lib_save_LIBS
14633fi
c0d27fcc 14634echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
14635echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
14636if test $ac_cv_lib_util_getloadavg = yes; then
14637 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 14638fi
503d2be0 14639
98418dba 14640fi
ba4481b5 14641
98418dba
CW
14642if test $ac_have_func = no; then
14643 # There is a commonly available library for RS/6000 AIX.
14644 # Since it is not a standard part of AIX, it might be installed locally.
14645 ac_getloadavg_LIBS=$LIBS
14646 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 14647 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
14648echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
14649if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 14650 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14651else
98418dba
CW
14652 ac_check_lib_save_LIBS=$LIBS
14653LIBS="-lgetloadavg $LIBS"
14654cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14655/* confdefs.h. */
14656_ACEOF
14657cat confdefs.h >>conftest.$ac_ext
14658cat >>conftest.$ac_ext <<_ACEOF
14659/* end confdefs.h. */
ba4481b5 14660
98418dba
CW
14661/* Override any gcc2 internal prototype to avoid an error. */
14662#ifdef __cplusplus
14663extern "C"
14664#endif
14665/* We use char because int might match the return type of a gcc2
14666 builtin and then its argument prototype would still apply. */
14667char getloadavg ();
98418dba
CW
14668int
14669main ()
14670{
14671getloadavg ();
14672 ;
14673 return 0;
14674}
503d2be0 14675_ACEOF
98418dba 14676rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14677if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14678 (eval $ac_link) 2>conftest.er1
98418dba 14679 ac_status=$?
35996d22
AS
14680 grep -v '^ *+' conftest.er1 >conftest.err
14681 rm -f conftest.er1
14682 cat conftest.err >&5
c0d27fcc 14683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14684 (exit $ac_status); } &&
4494a266
JD
14685 { ac_try='test -z "$ac_c_werror_flag"
14686 || test ! -s conftest.err'
35996d22
AS
14687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14688 (eval $ac_try) 2>&5
14689 ac_status=$?
14690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14691 (exit $ac_status); }; } &&
14692 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14694 (eval $ac_try) 2>&5
14695 ac_status=$?
c0d27fcc 14696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14697 (exit $ac_status); }; }; then
14698 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 14699else
98418dba 14700 echo "$as_me: failed program was:" >&5
19650fd6
AS
14701sed 's/^/| /' conftest.$ac_ext >&5
14702
98418dba
CW
14703ac_cv_lib_getloadavg_getloadavg=no
14704fi
35996d22
AS
14705rm -f conftest.err conftest.$ac_objext \
14706 conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14707LIBS=$ac_check_lib_save_LIBS
14708fi
c0d27fcc 14709echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
14710echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
14711if test $ac_cv_lib_getloadavg_getloadavg = yes; then
14712 LIBS="-lgetloadavg $LIBS"
14713else
14714 LIBS=$ac_getloadavg_LIBS
ba4481b5 14715fi
ba4481b5
DL
14716
14717fi
98418dba
CW
14718
14719# Make sure it is really in the library, if we think we found it,
14720# otherwise set up the replacement function.
14721
14722for ac_func in getloadavg
14723do
14724as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14725echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
14726echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14727if eval "test \"\${$as_ac_var+set}\" = set"; then
14728 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14729else
503d2be0 14730 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14731/* confdefs.h. */
14732_ACEOF
14733cat confdefs.h >>conftest.$ac_ext
14734cat >>conftest.$ac_ext <<_ACEOF
14735/* end confdefs.h. */
35996d22
AS
14736/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14737 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14738#define $ac_func innocuous_$ac_func
14739
ba4481b5 14740/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14741 which can conflict with char $ac_func (); below.
14742 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14743 <limits.h> exists even on freestanding compilers. */
35996d22 14744
19650fd6
AS
14745#ifdef __STDC__
14746# include <limits.h>
14747#else
14748# include <assert.h>
14749#endif
35996d22
AS
14750
14751#undef $ac_func
14752
ba4481b5 14753/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14754#ifdef __cplusplus
14755extern "C"
19650fd6 14756{
503d2be0 14757#endif
ba4481b5 14758/* We use char because int might match the return type of a gcc2
503d2be0
AS
14759 builtin and then its argument prototype would still apply. */
14760char $ac_func ();
ba4481b5
DL
14761/* The GNU C library defines this for functions which it implements
14762 to always fail with ENOSYS. Some functions are actually named
14763 something starting with __ and the normal name is an alias. */
14764#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14765choke me
14766#else
19650fd6
AS
14767char (*f) () = $ac_func;
14768#endif
14769#ifdef __cplusplus
14770}
cd958eb3
MB
14771#endif
14772
19650fd6
AS
14773int
14774main ()
14775{
14776return f != $ac_func;
503d2be0
AS
14777 ;
14778 return 0;
14779}
14780_ACEOF
14781rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14782if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 14783 (eval $ac_link) 2>conftest.er1
503d2be0 14784 ac_status=$?
35996d22
AS
14785 grep -v '^ *+' conftest.er1 >conftest.err
14786 rm -f conftest.er1
14787 cat conftest.err >&5
c0d27fcc 14788 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14789 (exit $ac_status); } &&
4494a266
JD
14790 { ac_try='test -z "$ac_c_werror_flag"
14791 || test ! -s conftest.err'
35996d22
AS
14792 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14793 (eval $ac_try) 2>&5
14794 ac_status=$?
14795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14796 (exit $ac_status); }; } &&
14797 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14798 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14799 (eval $ac_try) 2>&5
14800 ac_status=$?
c0d27fcc 14801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14802 (exit $ac_status); }; }; then
14803 eval "$as_ac_var=yes"
14804else
14805 echo "$as_me: failed program was:" >&5
19650fd6
AS
14806sed 's/^/| /' conftest.$ac_ext >&5
14807
503d2be0
AS
14808eval "$as_ac_var=no"
14809fi
35996d22
AS
14810rm -f conftest.err conftest.$ac_objext \
14811 conftest$ac_exeext conftest.$ac_ext
503d2be0 14812fi
c0d27fcc 14813echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14814echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14815if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14816 cat >>confdefs.h <<_ACEOF
98418dba 14817#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14818_ACEOF
503d2be0 14819
98418dba 14820else
35996d22
AS
14821 case $LIBOBJS in
14822 "getloadavg.$ac_objext" | \
14823 *" getloadavg.$ac_objext" | \
14824 "getloadavg.$ac_objext "* | \
14825 *" getloadavg.$ac_objext "* ) ;;
14826 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext" ;;
14827esac
14828
ba4481b5 14829
c0d27fcc 14830cat >>confdefs.h <<\_ACEOF
98418dba 14831#define C_GETLOADAVG 1
c0d27fcc 14832_ACEOF
ba4481b5 14833
98418dba
CW
14834# Figure out what our getloadavg.c needs.
14835ac_have_func=no
c0d27fcc
MR
14836if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14837 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
14838echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14839if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 14840 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14841fi
14842echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
14843echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 14844else
c0d27fcc
MR
14845 # Is the header compilable?
14846echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
14847echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
14848cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14849/* confdefs.h. */
14850_ACEOF
14851cat confdefs.h >>conftest.$ac_ext
14852cat >>conftest.$ac_ext <<_ACEOF
14853/* end confdefs.h. */
c0d27fcc
MR
14854$ac_includes_default
14855#include <sys/dg_sys_info.h>
14856_ACEOF
14857rm -f conftest.$ac_objext
14858if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 14859 (eval $ac_compile) 2>conftest.er1
c0d27fcc 14860 ac_status=$?
35996d22
AS
14861 grep -v '^ *+' conftest.er1 >conftest.err
14862 rm -f conftest.er1
14863 cat conftest.err >&5
c0d27fcc
MR
14864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14865 (exit $ac_status); } &&
4494a266
JD
14866 { ac_try='test -z "$ac_c_werror_flag"
14867 || test ! -s conftest.err'
35996d22
AS
14868 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14869 (eval $ac_try) 2>&5
14870 ac_status=$?
14871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14872 (exit $ac_status); }; } &&
14873 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14874 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14875 (eval $ac_try) 2>&5
14876 ac_status=$?
14877 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14878 (exit $ac_status); }; }; then
14879 ac_header_compiler=yes
14880else
14881 echo "$as_me: failed program was:" >&5
19650fd6
AS
14882sed 's/^/| /' conftest.$ac_ext >&5
14883
c0d27fcc
MR
14884ac_header_compiler=no
14885fi
35996d22 14886rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14887echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14888echo "${ECHO_T}$ac_header_compiler" >&6
14889
14890# Is the header present?
14891echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
14892echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
14893cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14894/* confdefs.h. */
14895_ACEOF
14896cat confdefs.h >>conftest.$ac_ext
14897cat >>conftest.$ac_ext <<_ACEOF
14898/* end confdefs.h. */
98418dba
CW
14899#include <sys/dg_sys_info.h>
14900_ACEOF
c0d27fcc 14901if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
14902 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14903 ac_status=$?
6bae0ccf 14904 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14905 rm -f conftest.er1
14906 cat conftest.err >&5
c0d27fcc 14907 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14908 (exit $ac_status); } >/dev/null; then
14909 if test -s conftest.err; then
14910 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 14911 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
14912 else
14913 ac_cpp_err=
14914 fi
14915else
14916 ac_cpp_err=yes
ba4481b5 14917fi
98418dba 14918if test -z "$ac_cpp_err"; then
c0d27fcc 14919 ac_header_preproc=yes
98418dba
CW
14920else
14921 echo "$as_me: failed program was:" >&5
19650fd6
AS
14922sed 's/^/| /' conftest.$ac_ext >&5
14923
c0d27fcc 14924 ac_header_preproc=no
ba4481b5 14925fi
98418dba 14926rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14927echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14928echo "${ECHO_T}$ac_header_preproc" >&6
14929
14930# So? What about this header?
35996d22
AS
14931case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14932 yes:no: )
c0d27fcc
MR
14933 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
14934echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
14935 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&5
14936echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the compiler's result" >&2;}
14937 ac_header_preproc=yes
19650fd6 14938 ;;
35996d22 14939 no:yes:* )
c0d27fcc
MR
14940 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
14941echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
35996d22
AS
14942 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
14943echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
14944 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&5
14945echo "$as_me: WARNING: sys/dg_sys_info.h: see the Autoconf documentation" >&2;}
14946 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&5
14947echo "$as_me: WARNING: sys/dg_sys_info.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 14948 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
19650fd6 14949echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
14950 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&5
14951echo "$as_me: WARNING: sys/dg_sys_info.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
14952 (
14953 cat <<\_ASBOX
35996d22
AS
14954## ------------------------------------------ ##
14955## Report this to the AC_PACKAGE_NAME lists. ##
14956## ------------------------------------------ ##
19650fd6
AS
14957_ASBOX
14958 ) |
14959 sed "s/^/$as_me: WARNING: /" >&2
14960 ;;
c0d27fcc
MR
14961esac
14962echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
14963echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14964if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14965 echo $ECHO_N "(cached) $ECHO_C" >&6
14966else
14967 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 14968fi
c0d27fcc 14969echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 14970echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
14971
14972fi
98418dba
CW
14973if test $ac_cv_header_sys_dg_sys_info_h = yes; then
14974 ac_have_func=yes
ba4481b5 14975
c0d27fcc 14976cat >>confdefs.h <<\_ACEOF
98418dba 14977#define DGUX 1
c0d27fcc
MR
14978_ACEOF
14979
503d2be0 14980
c0d27fcc 14981echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
14982echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
14983if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 14984 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14985else
503d2be0 14986 ac_check_lib_save_LIBS=$LIBS
98418dba 14987LIBS="-ldgc $LIBS"
503d2be0 14988cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
14989/* confdefs.h. */
14990_ACEOF
14991cat confdefs.h >>conftest.$ac_ext
14992cat >>conftest.$ac_ext <<_ACEOF
14993/* end confdefs.h. */
503d2be0 14994
ba4481b5 14995/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14996#ifdef __cplusplus
14997extern "C"
14998#endif
ba4481b5 14999/* We use char because int might match the return type of a gcc2
503d2be0 15000 builtin and then its argument prototype would still apply. */
98418dba 15001char dg_sys_info ();
503d2be0
AS
15002int
15003main ()
15004{
98418dba 15005dg_sys_info ();
503d2be0
AS
15006 ;
15007 return 0;
15008}
15009_ACEOF
15010rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15011if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 15012 (eval $ac_link) 2>conftest.er1
503d2be0 15013 ac_status=$?
35996d22
AS
15014 grep -v '^ *+' conftest.er1 >conftest.err
15015 rm -f conftest.er1
15016 cat conftest.err >&5
c0d27fcc 15017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15018 (exit $ac_status); } &&
4494a266
JD
15019 { ac_try='test -z "$ac_c_werror_flag"
15020 || test ! -s conftest.err'
35996d22
AS
15021 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15022 (eval $ac_try) 2>&5
15023 ac_status=$?
15024 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15025 (exit $ac_status); }; } &&
15026 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15027 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15028 (eval $ac_try) 2>&5
15029 ac_status=$?
c0d27fcc 15030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15031 (exit $ac_status); }; }; then
98418dba 15032 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
15033else
15034 echo "$as_me: failed program was:" >&5
19650fd6
AS
15035sed 's/^/| /' conftest.$ac_ext >&5
15036
98418dba 15037ac_cv_lib_dgc_dg_sys_info=no
503d2be0 15038fi
35996d22
AS
15039rm -f conftest.err conftest.$ac_objext \
15040 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
15041LIBS=$ac_check_lib_save_LIBS
15042fi
c0d27fcc 15043echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
15044echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
15045if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 15046 cat >>confdefs.h <<_ACEOF
98418dba 15047#define HAVE_LIBDGC 1
c0d27fcc 15048_ACEOF
ba4481b5 15049
98418dba 15050 LIBS="-ldgc $LIBS"
ba4481b5 15051
ba4481b5
DL
15052fi
15053
98418dba 15054fi
503d2be0 15055
c0d27fcc
MR
15056
15057
15058if test "${ac_cv_header_locale_h+set}" = set; then
15059 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
15060echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15061if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 15062 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15063fi
15064echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
15065echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 15066else
c0d27fcc
MR
15067 # Is the header compilable?
15068echo "$as_me:$LINENO: checking locale.h usability" >&5
15069echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
15070cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15071/* confdefs.h. */
15072_ACEOF
15073cat confdefs.h >>conftest.$ac_ext
15074cat >>conftest.$ac_ext <<_ACEOF
15075/* end confdefs.h. */
c0d27fcc
MR
15076$ac_includes_default
15077#include <locale.h>
15078_ACEOF
15079rm -f conftest.$ac_objext
15080if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15081 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15082 ac_status=$?
35996d22
AS
15083 grep -v '^ *+' conftest.er1 >conftest.err
15084 rm -f conftest.er1
15085 cat conftest.err >&5
c0d27fcc
MR
15086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15087 (exit $ac_status); } &&
4494a266
JD
15088 { ac_try='test -z "$ac_c_werror_flag"
15089 || test ! -s conftest.err'
35996d22
AS
15090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15091 (eval $ac_try) 2>&5
15092 ac_status=$?
15093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15094 (exit $ac_status); }; } &&
15095 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15097 (eval $ac_try) 2>&5
15098 ac_status=$?
15099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15100 (exit $ac_status); }; }; then
15101 ac_header_compiler=yes
15102else
15103 echo "$as_me: failed program was:" >&5
19650fd6
AS
15104sed 's/^/| /' conftest.$ac_ext >&5
15105
c0d27fcc
MR
15106ac_header_compiler=no
15107fi
35996d22 15108rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15109echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15110echo "${ECHO_T}$ac_header_compiler" >&6
15111
15112# Is the header present?
15113echo "$as_me:$LINENO: checking locale.h presence" >&5
15114echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
15115cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15116/* confdefs.h. */
15117_ACEOF
15118cat confdefs.h >>conftest.$ac_ext
15119cat >>conftest.$ac_ext <<_ACEOF
15120/* end confdefs.h. */
98418dba 15121#include <locale.h>
503d2be0 15122_ACEOF
c0d27fcc 15123if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 15124 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 15125 ac_status=$?
6bae0ccf 15126 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15127 rm -f conftest.er1
15128 cat conftest.err >&5
c0d27fcc 15129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15130 (exit $ac_status); } >/dev/null; then
15131 if test -s conftest.err; then
15132 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15133 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15134 else
15135 ac_cpp_err=
15136 fi
503d2be0 15137else
98418dba 15138 ac_cpp_err=yes
503d2be0 15139fi
98418dba 15140if test -z "$ac_cpp_err"; then
c0d27fcc 15141 ac_header_preproc=yes
98418dba
CW
15142else
15143 echo "$as_me: failed program was:" >&5
19650fd6
AS
15144sed 's/^/| /' conftest.$ac_ext >&5
15145
c0d27fcc 15146 ac_header_preproc=no
ba4481b5 15147fi
98418dba 15148rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15149echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15150echo "${ECHO_T}$ac_header_preproc" >&6
15151
15152# So? What about this header?
35996d22
AS
15153case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15154 yes:no: )
c0d27fcc
MR
15155 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
15156echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15157 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the compiler's result" >&5
15158echo "$as_me: WARNING: locale.h: proceeding with the compiler's result" >&2;}
15159 ac_header_preproc=yes
19650fd6 15160 ;;
35996d22 15161 no:yes:* )
c0d27fcc
MR
15162 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
15163echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
35996d22
AS
15164 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
15165echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
15166 { echo "$as_me:$LINENO: WARNING: locale.h: see the Autoconf documentation" >&5
15167echo "$as_me: WARNING: locale.h: see the Autoconf documentation" >&2;}
15168 { echo "$as_me:$LINENO: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&5
15169echo "$as_me: WARNING: locale.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15170 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
19650fd6 15171echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15172 { echo "$as_me:$LINENO: WARNING: locale.h: in the future, the compiler will take precedence" >&5
15173echo "$as_me: WARNING: locale.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15174 (
15175 cat <<\_ASBOX
35996d22
AS
15176## ------------------------------------------ ##
15177## Report this to the AC_PACKAGE_NAME lists. ##
15178## ------------------------------------------ ##
19650fd6
AS
15179_ASBOX
15180 ) |
15181 sed "s/^/$as_me: WARNING: /" >&2
15182 ;;
c0d27fcc
MR
15183esac
15184echo "$as_me:$LINENO: checking for locale.h" >&5
15185echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
15186if test "${ac_cv_header_locale_h+set}" = set; then
15187 echo $ECHO_N "(cached) $ECHO_C" >&6
15188else
15189 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 15190fi
c0d27fcc 15191echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
15192echo "${ECHO_T}$ac_cv_header_locale_h" >&6
15193
c0d27fcc
MR
15194fi
15195
15196
15197
98418dba 15198for ac_func in setlocale
ba4481b5 15199do
503d2be0 15200as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15201echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15202echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15203if eval "test \"\${$as_ac_var+set}\" = set"; then
15204 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15205else
503d2be0 15206 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15207/* confdefs.h. */
15208_ACEOF
15209cat confdefs.h >>conftest.$ac_ext
15210cat >>conftest.$ac_ext <<_ACEOF
15211/* end confdefs.h. */
35996d22
AS
15212/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15213 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15214#define $ac_func innocuous_$ac_func
15215
ba4481b5 15216/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15217 which can conflict with char $ac_func (); below.
15218 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15219 <limits.h> exists even on freestanding compilers. */
35996d22 15220
19650fd6
AS
15221#ifdef __STDC__
15222# include <limits.h>
15223#else
15224# include <assert.h>
15225#endif
35996d22
AS
15226
15227#undef $ac_func
15228
ba4481b5 15229/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15230#ifdef __cplusplus
15231extern "C"
19650fd6 15232{
503d2be0 15233#endif
ba4481b5 15234/* We use char because int might match the return type of a gcc2
503d2be0
AS
15235 builtin and then its argument prototype would still apply. */
15236char $ac_func ();
ba4481b5
DL
15237/* The GNU C library defines this for functions which it implements
15238 to always fail with ENOSYS. Some functions are actually named
15239 something starting with __ and the normal name is an alias. */
15240#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15241choke me
15242#else
19650fd6
AS
15243char (*f) () = $ac_func;
15244#endif
15245#ifdef __cplusplus
15246}
ba4481b5
DL
15247#endif
15248
19650fd6
AS
15249int
15250main ()
15251{
15252return f != $ac_func;
503d2be0
AS
15253 ;
15254 return 0;
15255}
15256_ACEOF
15257rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15258if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 15259 (eval $ac_link) 2>conftest.er1
503d2be0 15260 ac_status=$?
35996d22
AS
15261 grep -v '^ *+' conftest.er1 >conftest.err
15262 rm -f conftest.er1
15263 cat conftest.err >&5
c0d27fcc 15264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15265 (exit $ac_status); } &&
4494a266
JD
15266 { ac_try='test -z "$ac_c_werror_flag"
15267 || test ! -s conftest.err'
35996d22
AS
15268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15269 (eval $ac_try) 2>&5
15270 ac_status=$?
15271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15272 (exit $ac_status); }; } &&
15273 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15275 (eval $ac_try) 2>&5
15276 ac_status=$?
c0d27fcc 15277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15278 (exit $ac_status); }; }; then
15279 eval "$as_ac_var=yes"
15280else
15281 echo "$as_me: failed program was:" >&5
19650fd6
AS
15282sed 's/^/| /' conftest.$ac_ext >&5
15283
503d2be0
AS
15284eval "$as_ac_var=no"
15285fi
35996d22
AS
15286rm -f conftest.err conftest.$ac_objext \
15287 conftest$ac_exeext conftest.$ac_ext
503d2be0 15288fi
c0d27fcc 15289echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15290echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15291if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15292 cat >>confdefs.h <<_ACEOF
503d2be0 15293#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15294_ACEOF
ba4481b5 15295
ba4481b5
DL
15296fi
15297done
15298
c0d27fcc 15299
98418dba
CW
15300# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
15301# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
15302# Irix 4.0.5F has the header but not the library.
15303if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
15304 ac_have_func=yes
15305
c0d27fcc 15306cat >>confdefs.h <<\_ACEOF
98418dba 15307#define SVR4 1
c0d27fcc 15308_ACEOF
98418dba
CW
15309
15310fi
15311
15312if test $ac_have_func = no; then
c0d27fcc
MR
15313 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15314 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
15315echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15316if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 15317 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15318fi
15319echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
15320echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 15321else
c0d27fcc
MR
15322 # Is the header compilable?
15323echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
15324echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
15325cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15326/* confdefs.h. */
15327_ACEOF
15328cat confdefs.h >>conftest.$ac_ext
15329cat >>conftest.$ac_ext <<_ACEOF
15330/* end confdefs.h. */
c0d27fcc
MR
15331$ac_includes_default
15332#include <inq_stats/cpustats.h>
15333_ACEOF
15334rm -f conftest.$ac_objext
15335if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15336 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15337 ac_status=$?
35996d22
AS
15338 grep -v '^ *+' conftest.er1 >conftest.err
15339 rm -f conftest.er1
15340 cat conftest.err >&5
c0d27fcc
MR
15341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15342 (exit $ac_status); } &&
4494a266
JD
15343 { ac_try='test -z "$ac_c_werror_flag"
15344 || test ! -s conftest.err'
35996d22
AS
15345 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15346 (eval $ac_try) 2>&5
15347 ac_status=$?
15348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15349 (exit $ac_status); }; } &&
15350 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15351 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15352 (eval $ac_try) 2>&5
15353 ac_status=$?
15354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15355 (exit $ac_status); }; }; then
15356 ac_header_compiler=yes
15357else
15358 echo "$as_me: failed program was:" >&5
19650fd6
AS
15359sed 's/^/| /' conftest.$ac_ext >&5
15360
c0d27fcc
MR
15361ac_header_compiler=no
15362fi
35996d22 15363rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15364echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15365echo "${ECHO_T}$ac_header_compiler" >&6
15366
15367# Is the header present?
15368echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
15369echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
15370cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15371/* confdefs.h. */
15372_ACEOF
15373cat confdefs.h >>conftest.$ac_ext
15374cat >>conftest.$ac_ext <<_ACEOF
15375/* end confdefs.h. */
98418dba 15376#include <inq_stats/cpustats.h>
503d2be0 15377_ACEOF
c0d27fcc 15378if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15379 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15380 ac_status=$?
6bae0ccf 15381 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15382 rm -f conftest.er1
15383 cat conftest.err >&5
c0d27fcc 15384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15385 (exit $ac_status); } >/dev/null; then
15386 if test -s conftest.err; then
15387 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15388 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15389 else
15390 ac_cpp_err=
15391 fi
15392else
15393 ac_cpp_err=yes
15394fi
15395if test -z "$ac_cpp_err"; then
c0d27fcc 15396 ac_header_preproc=yes
503d2be0
AS
15397else
15398 echo "$as_me: failed program was:" >&5
19650fd6
AS
15399sed 's/^/| /' conftest.$ac_ext >&5
15400
c0d27fcc 15401 ac_header_preproc=no
ba4481b5 15402fi
503d2be0 15403rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15404echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15405echo "${ECHO_T}$ac_header_preproc" >&6
15406
15407# So? What about this header?
35996d22
AS
15408case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15409 yes:no: )
c0d27fcc
MR
15410 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15411echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15412 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&5
15413echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the compiler's result" >&2;}
15414 ac_header_preproc=yes
19650fd6 15415 ;;
35996d22 15416 no:yes:* )
c0d27fcc
MR
15417 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
15418echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15419 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
15420echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
15421 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&5
15422echo "$as_me: WARNING: inq_stats/cpustats.h: see the Autoconf documentation" >&2;}
15423 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15424echo "$as_me: WARNING: inq_stats/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15425 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15426echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15427 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&5
15428echo "$as_me: WARNING: inq_stats/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15429 (
15430 cat <<\_ASBOX
35996d22
AS
15431## ------------------------------------------ ##
15432## Report this to the AC_PACKAGE_NAME lists. ##
15433## ------------------------------------------ ##
19650fd6
AS
15434_ASBOX
15435 ) |
15436 sed "s/^/$as_me: WARNING: /" >&2
15437 ;;
c0d27fcc
MR
15438esac
15439echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
15440echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
15441if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
15442 echo $ECHO_N "(cached) $ECHO_C" >&6
15443else
15444 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 15445fi
c0d27fcc 15446echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 15447echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
15448
15449fi
98418dba
CW
15450if test $ac_cv_header_inq_stats_cpustats_h = yes; then
15451 ac_have_func=yes
ba4481b5 15452
c0d27fcc 15453cat >>confdefs.h <<\_ACEOF
98418dba 15454#define UMAX 1
c0d27fcc 15455_ACEOF
98418dba 15456
c0d27fcc
MR
15457
15458cat >>confdefs.h <<\_ACEOF
98418dba 15459#define UMAX4_3 1
c0d27fcc 15460_ACEOF
98418dba
CW
15461
15462fi
15463
c0d27fcc 15464
98418dba
CW
15465fi
15466
15467if test $ac_have_func = no; then
c0d27fcc
MR
15468 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15469 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
15470echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15471if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 15472 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15473fi
15474echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
15475echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 15476else
c0d27fcc
MR
15477 # Is the header compilable?
15478echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
15479echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
15480cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15481/* confdefs.h. */
15482_ACEOF
15483cat confdefs.h >>conftest.$ac_ext
15484cat >>conftest.$ac_ext <<_ACEOF
15485/* end confdefs.h. */
c0d27fcc
MR
15486$ac_includes_default
15487#include <sys/cpustats.h>
15488_ACEOF
15489rm -f conftest.$ac_objext
15490if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15491 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15492 ac_status=$?
35996d22
AS
15493 grep -v '^ *+' conftest.er1 >conftest.err
15494 rm -f conftest.er1
15495 cat conftest.err >&5
c0d27fcc
MR
15496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15497 (exit $ac_status); } &&
4494a266
JD
15498 { ac_try='test -z "$ac_c_werror_flag"
15499 || test ! -s conftest.err'
35996d22
AS
15500 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15501 (eval $ac_try) 2>&5
15502 ac_status=$?
15503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15504 (exit $ac_status); }; } &&
15505 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15507 (eval $ac_try) 2>&5
15508 ac_status=$?
15509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15510 (exit $ac_status); }; }; then
15511 ac_header_compiler=yes
15512else
15513 echo "$as_me: failed program was:" >&5
19650fd6
AS
15514sed 's/^/| /' conftest.$ac_ext >&5
15515
c0d27fcc
MR
15516ac_header_compiler=no
15517fi
35996d22 15518rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15519echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15520echo "${ECHO_T}$ac_header_compiler" >&6
15521
15522# Is the header present?
15523echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
15524echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
15525cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15526/* confdefs.h. */
15527_ACEOF
15528cat confdefs.h >>conftest.$ac_ext
15529cat >>conftest.$ac_ext <<_ACEOF
15530/* end confdefs.h. */
98418dba
CW
15531#include <sys/cpustats.h>
15532_ACEOF
c0d27fcc 15533if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
15534 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15535 ac_status=$?
6bae0ccf 15536 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
15537 rm -f conftest.er1
15538 cat conftest.err >&5
c0d27fcc 15539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
15540 (exit $ac_status); } >/dev/null; then
15541 if test -s conftest.err; then
15542 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15543 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
98418dba
CW
15544 else
15545 ac_cpp_err=
15546 fi
15547else
15548 ac_cpp_err=yes
503d2be0 15549fi
98418dba 15550if test -z "$ac_cpp_err"; then
c0d27fcc 15551 ac_header_preproc=yes
98418dba
CW
15552else
15553 echo "$as_me: failed program was:" >&5
19650fd6
AS
15554sed 's/^/| /' conftest.$ac_ext >&5
15555
c0d27fcc 15556 ac_header_preproc=no
98418dba
CW
15557fi
15558rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15559echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15560echo "${ECHO_T}$ac_header_preproc" >&6
15561
15562# So? What about this header?
35996d22
AS
15563case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15564 yes:no: )
c0d27fcc
MR
15565 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
15566echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15567 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&5
15568echo "$as_me: WARNING: sys/cpustats.h: proceeding with the compiler's result" >&2;}
15569 ac_header_preproc=yes
19650fd6 15570 ;;
35996d22 15571 no:yes:* )
c0d27fcc
MR
15572 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
15573echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
35996d22
AS
15574 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
15575echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
15576 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: see the Autoconf documentation" >&5
15577echo "$as_me: WARNING: sys/cpustats.h: see the Autoconf documentation" >&2;}
15578 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&5
15579echo "$as_me: WARNING: sys/cpustats.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15580 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 15581echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15582 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&5
15583echo "$as_me: WARNING: sys/cpustats.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15584 (
15585 cat <<\_ASBOX
35996d22
AS
15586## ------------------------------------------ ##
15587## Report this to the AC_PACKAGE_NAME lists. ##
15588## ------------------------------------------ ##
19650fd6
AS
15589_ASBOX
15590 ) |
15591 sed "s/^/$as_me: WARNING: /" >&2
15592 ;;
c0d27fcc
MR
15593esac
15594echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
15595echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
15596if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
15597 echo $ECHO_N "(cached) $ECHO_C" >&6
15598else
15599 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 15600fi
c0d27fcc 15601echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 15602echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
15603
15604fi
98418dba 15605if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 15606 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 15607#define UMAX 1
c0d27fcc 15608_ACEOF
ba4481b5 15609
98418dba
CW
15610fi
15611
c0d27fcc 15612
98418dba
CW
15613fi
15614
15615if test $ac_have_func = no; then
15616
15617for ac_header in mach/mach.h
2c9dccc9
PJ
15618do
15619as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15620if eval "test \"\${$as_ac_Header+set}\" = set"; then
15621 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
15622echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15623if eval "test \"\${$as_ac_Header+set}\" = set"; then
15624 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15625fi
15626echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15627echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15628else
c0d27fcc
MR
15629 # Is the header compilable?
15630echo "$as_me:$LINENO: checking $ac_header usability" >&5
15631echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15632cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15633/* confdefs.h. */
15634_ACEOF
15635cat confdefs.h >>conftest.$ac_ext
15636cat >>conftest.$ac_ext <<_ACEOF
15637/* end confdefs.h. */
c0d27fcc
MR
15638$ac_includes_default
15639#include <$ac_header>
15640_ACEOF
15641rm -f conftest.$ac_objext
15642if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15643 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15644 ac_status=$?
35996d22
AS
15645 grep -v '^ *+' conftest.er1 >conftest.err
15646 rm -f conftest.er1
15647 cat conftest.err >&5
c0d27fcc
MR
15648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15649 (exit $ac_status); } &&
4494a266
JD
15650 { ac_try='test -z "$ac_c_werror_flag"
15651 || test ! -s conftest.err'
35996d22
AS
15652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15653 (eval $ac_try) 2>&5
15654 ac_status=$?
15655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15656 (exit $ac_status); }; } &&
15657 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15658 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15659 (eval $ac_try) 2>&5
15660 ac_status=$?
15661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15662 (exit $ac_status); }; }; then
15663 ac_header_compiler=yes
15664else
15665 echo "$as_me: failed program was:" >&5
19650fd6
AS
15666sed 's/^/| /' conftest.$ac_ext >&5
15667
c0d27fcc
MR
15668ac_header_compiler=no
15669fi
35996d22 15670rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15671echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15672echo "${ECHO_T}$ac_header_compiler" >&6
15673
15674# Is the header present?
15675echo "$as_me:$LINENO: checking $ac_header presence" >&5
15676echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15677cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15678/* confdefs.h. */
15679_ACEOF
15680cat confdefs.h >>conftest.$ac_ext
15681cat >>conftest.$ac_ext <<_ACEOF
15682/* end confdefs.h. */
2c9dccc9
PJ
15683#include <$ac_header>
15684_ACEOF
c0d27fcc 15685if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
15686 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15687 ac_status=$?
6bae0ccf 15688 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
15689 rm -f conftest.er1
15690 cat conftest.err >&5
c0d27fcc 15691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
15692 (exit $ac_status); } >/dev/null; then
15693 if test -s conftest.err; then
15694 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15695 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2c9dccc9
PJ
15696 else
15697 ac_cpp_err=
15698 fi
15699else
15700 ac_cpp_err=yes
15701fi
15702if test -z "$ac_cpp_err"; then
c0d27fcc
MR
15703 ac_header_preproc=yes
15704else
15705 echo "$as_me: failed program was:" >&5
19650fd6
AS
15706sed 's/^/| /' conftest.$ac_ext >&5
15707
c0d27fcc
MR
15708 ac_header_preproc=no
15709fi
15710rm -f conftest.err conftest.$ac_ext
15711echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15712echo "${ECHO_T}$ac_header_preproc" >&6
15713
15714# So? What about this header?
35996d22
AS
15715case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15716 yes:no: )
c0d27fcc
MR
15717 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15718echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15719 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15720echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15721 ac_header_preproc=yes
19650fd6 15722 ;;
35996d22 15723 no:yes:* )
c0d27fcc
MR
15724 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15725echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15726 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15727echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15728 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15729echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15730 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15731echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15732 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15733echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15734 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15735echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15736 (
15737 cat <<\_ASBOX
35996d22
AS
15738## ------------------------------------------ ##
15739## Report this to the AC_PACKAGE_NAME lists. ##
15740## ------------------------------------------ ##
19650fd6
AS
15741_ASBOX
15742 ) |
15743 sed "s/^/$as_me: WARNING: /" >&2
15744 ;;
c0d27fcc
MR
15745esac
15746echo "$as_me:$LINENO: checking for $ac_header" >&5
15747echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15748if eval "test \"\${$as_ac_Header+set}\" = set"; then
15749 echo $ECHO_N "(cached) $ECHO_C" >&6
15750else
35996d22 15751 eval "$as_ac_Header=\$ac_header_preproc"
c0d27fcc
MR
15752fi
15753echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15754echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15755
15756fi
15757if test `eval echo '${'$as_ac_Header'}'` = yes; then
15758 cat >>confdefs.h <<_ACEOF
15759#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15760_ACEOF
15761
15762fi
15763
15764done
15765
15766fi
15767
15768
15769for ac_header in nlist.h
15770do
15771as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15772if eval "test \"\${$as_ac_Header+set}\" = set"; then
15773 echo "$as_me:$LINENO: checking for $ac_header" >&5
15774echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15775if eval "test \"\${$as_ac_Header+set}\" = set"; then
15776 echo $ECHO_N "(cached) $ECHO_C" >&6
15777fi
15778echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15779echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15780else
15781 # Is the header compilable?
15782echo "$as_me:$LINENO: checking $ac_header usability" >&5
15783echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15784cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15785/* confdefs.h. */
15786_ACEOF
15787cat confdefs.h >>conftest.$ac_ext
15788cat >>conftest.$ac_ext <<_ACEOF
15789/* end confdefs.h. */
c0d27fcc
MR
15790$ac_includes_default
15791#include <$ac_header>
15792_ACEOF
15793rm -f conftest.$ac_objext
15794if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15795 (eval $ac_compile) 2>conftest.er1
c0d27fcc 15796 ac_status=$?
35996d22
AS
15797 grep -v '^ *+' conftest.er1 >conftest.err
15798 rm -f conftest.er1
15799 cat conftest.err >&5
c0d27fcc
MR
15800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15801 (exit $ac_status); } &&
4494a266
JD
15802 { ac_try='test -z "$ac_c_werror_flag"
15803 || test ! -s conftest.err'
35996d22
AS
15804 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15805 (eval $ac_try) 2>&5
15806 ac_status=$?
15807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15808 (exit $ac_status); }; } &&
15809 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15810 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15811 (eval $ac_try) 2>&5
15812 ac_status=$?
15813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15814 (exit $ac_status); }; }; then
15815 ac_header_compiler=yes
2c9dccc9
PJ
15816else
15817 echo "$as_me: failed program was:" >&5
19650fd6
AS
15818sed 's/^/| /' conftest.$ac_ext >&5
15819
c0d27fcc 15820ac_header_compiler=no
98418dba 15821fi
35996d22 15822rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15823echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15824echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 15825
c0d27fcc
MR
15826# Is the header present?
15827echo "$as_me:$LINENO: checking $ac_header presence" >&5
15828echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15829cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15830/* confdefs.h. */
15831_ACEOF
15832cat confdefs.h >>conftest.$ac_ext
15833cat >>conftest.$ac_ext <<_ACEOF
15834/* end confdefs.h. */
503d2be0
AS
15835#include <$ac_header>
15836_ACEOF
c0d27fcc 15837if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15838 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15839 ac_status=$?
6bae0ccf 15840 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15841 rm -f conftest.er1
15842 cat conftest.err >&5
c0d27fcc 15843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15844 (exit $ac_status); } >/dev/null; then
15845 if test -s conftest.err; then
15846 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 15847 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
15848 else
15849 ac_cpp_err=
15850 fi
15851else
15852 ac_cpp_err=yes
15853fi
15854if test -z "$ac_cpp_err"; then
c0d27fcc 15855 ac_header_preproc=yes
503d2be0
AS
15856else
15857 echo "$as_me: failed program was:" >&5
19650fd6
AS
15858sed 's/^/| /' conftest.$ac_ext >&5
15859
c0d27fcc 15860 ac_header_preproc=no
b5de8dc0 15861fi
503d2be0 15862rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15863echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15864echo "${ECHO_T}$ac_header_preproc" >&6
15865
15866# So? What about this header?
35996d22
AS
15867case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15868 yes:no: )
c0d27fcc
MR
15869 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15870echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
15871 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
15872echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
15873 ac_header_preproc=yes
19650fd6 15874 ;;
35996d22 15875 no:yes:* )
c0d27fcc
MR
15876 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15877echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
15878 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15879echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15880 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
15881echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
15882 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
15883echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 15884 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15885echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
15886 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
15887echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
15888 (
15889 cat <<\_ASBOX
35996d22
AS
15890## ------------------------------------------ ##
15891## Report this to the AC_PACKAGE_NAME lists. ##
15892## ------------------------------------------ ##
19650fd6
AS
15893_ASBOX
15894 ) |
15895 sed "s/^/$as_me: WARNING: /" >&2
15896 ;;
c0d27fcc
MR
15897esac
15898echo "$as_me:$LINENO: checking for $ac_header" >&5
15899echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15900if eval "test \"\${$as_ac_Header+set}\" = set"; then
15901 echo $ECHO_N "(cached) $ECHO_C" >&6
15902else
35996d22 15903 eval "$as_ac_Header=\$ac_header_preproc"
b5de8dc0 15904fi
c0d27fcc 15905echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15906echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15907
15908fi
98418dba 15909if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15910 cat >>confdefs.h <<_ACEOF
98418dba 15911#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
15912_ACEOF
15913 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
15914echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
15915if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 15916 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 15917else
503d2be0 15918 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15919/* confdefs.h. */
15920_ACEOF
15921cat confdefs.h >>conftest.$ac_ext
15922cat >>conftest.$ac_ext <<_ACEOF
15923/* end confdefs.h. */
98418dba 15924#include <nlist.h>
b5de8dc0 15925
503d2be0
AS
15926int
15927main ()
15928{
98418dba
CW
15929static struct nlist ac_aggr;
15930if (ac_aggr.n_un.n_name)
15931return 0;
503d2be0
AS
15932 ;
15933 return 0;
15934}
15935_ACEOF
98418dba 15936rm -f conftest.$ac_objext
c0d27fcc 15937if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15938 (eval $ac_compile) 2>conftest.er1
503d2be0 15939 ac_status=$?
35996d22
AS
15940 grep -v '^ *+' conftest.er1 >conftest.err
15941 rm -f conftest.er1
15942 cat conftest.err >&5
c0d27fcc 15943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15944 (exit $ac_status); } &&
4494a266
JD
15945 { ac_try='test -z "$ac_c_werror_flag"
15946 || test ! -s conftest.err'
35996d22
AS
15947 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15948 (eval $ac_try) 2>&5
15949 ac_status=$?
15950 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15951 (exit $ac_status); }; } &&
15952 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15953 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15954 (eval $ac_try) 2>&5
15955 ac_status=$?
c0d27fcc 15956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15957 (exit $ac_status); }; }; then
98418dba 15958 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
15959else
15960 echo "$as_me: failed program was:" >&5
19650fd6
AS
15961sed 's/^/| /' conftest.$ac_ext >&5
15962
6bae0ccf 15963cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
15964/* confdefs.h. */
15965_ACEOF
15966cat confdefs.h >>conftest.$ac_ext
15967cat >>conftest.$ac_ext <<_ACEOF
15968/* end confdefs.h. */
6bae0ccf
DL
15969#include <nlist.h>
15970
15971int
15972main ()
15973{
15974static struct nlist ac_aggr;
15975if (sizeof ac_aggr.n_un.n_name)
15976return 0;
15977 ;
15978 return 0;
15979}
15980_ACEOF
15981rm -f conftest.$ac_objext
15982if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 15983 (eval $ac_compile) 2>conftest.er1
6bae0ccf 15984 ac_status=$?
35996d22
AS
15985 grep -v '^ *+' conftest.er1 >conftest.err
15986 rm -f conftest.er1
15987 cat conftest.err >&5
6bae0ccf
DL
15988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15989 (exit $ac_status); } &&
4494a266
JD
15990 { ac_try='test -z "$ac_c_werror_flag"
15991 || test ! -s conftest.err'
35996d22
AS
15992 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15993 (eval $ac_try) 2>&5
15994 ac_status=$?
15995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15996 (exit $ac_status); }; } &&
15997 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
15998 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15999 (eval $ac_try) 2>&5
16000 ac_status=$?
16001 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16002 (exit $ac_status); }; }; then
16003 ac_cv_member_struct_nlist_n_un_n_name=yes
16004else
16005 echo "$as_me: failed program was:" >&5
19650fd6
AS
16006sed 's/^/| /' conftest.$ac_ext >&5
16007
98418dba 16008ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 16009fi
35996d22 16010rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b5de8dc0 16011fi
35996d22 16012rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
6bae0ccf 16013fi
c0d27fcc 16014echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
16015echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
16016if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 16017
c0d27fcc 16018cat >>confdefs.h <<_ACEOF
98418dba 16019#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 16020_ACEOF
b5de8dc0 16021
c0d27fcc
MR
16022
16023cat >>confdefs.h <<\_ACEOF
98418dba 16024#define NLIST_NAME_UNION 1
c0d27fcc 16025_ACEOF
b5de8dc0 16026
98418dba 16027fi
b5de8dc0 16028
c0d27fcc 16029
98418dba 16030fi
c0d27fcc 16031
98418dba 16032done
b5de8dc0 16033
98418dba
CW
16034fi
16035done
b5de8dc0 16036
c0d27fcc 16037
98418dba 16038# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 16039echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
16040echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
16041if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
16042 echo $ECHO_N "(cached) $ECHO_C" >&6
16043else
16044 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16045/* confdefs.h. */
16046_ACEOF
16047cat confdefs.h >>conftest.$ac_ext
16048cat >>conftest.$ac_ext <<_ACEOF
16049/* end confdefs.h. */
6bae0ccf 16050#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
16051#ifdef LDAV_PRIVILEGED
16052Yowza Am I SETGID yet
16053#endif
16054_ACEOF
16055if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 16056 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
16057 ac_cv_func_getloadavg_setgid=yes
16058else
16059 ac_cv_func_getloadavg_setgid=no
16060fi
16061rm -f conftest*
b5de8dc0 16062
98418dba 16063fi
c0d27fcc 16064echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
16065echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
16066if test $ac_cv_func_getloadavg_setgid = yes; then
16067 NEED_SETGID=true
b5de8dc0 16068
c0d27fcc 16069cat >>confdefs.h <<\_ACEOF
98418dba 16070#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 16071_ACEOF
98418dba 16072
b5de8dc0 16073else
98418dba 16074 NEED_SETGID=false
b5de8dc0 16075fi
98418dba
CW
16076
16077if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 16078 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
16079echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
16080if test "${ac_cv_group_kmem+set}" = set; then
16081 echo $ECHO_N "(cached) $ECHO_C" >&6
16082else
16083 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
16084 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
16085 # If we got an error (system does not support symlinks), try without -L.
16086 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
16087 ac_cv_group_kmem=`echo $ac_ls_output \
35996d22 16088 | sed -ne 's/[ ][ ]*/ /g;
98418dba
CW
16089 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
16090 / /s/.* //;p;'`
16091
b5de8dc0 16092fi
c0d27fcc 16093echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
16094echo "${ECHO_T}$ac_cv_group_kmem" >&6
16095 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 16096fi
98418dba
CW
16097if test "x$ac_save_LIBS" = x; then
16098 GETLOADAVG_LIBS=$LIBS
16099else
16100 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 16101fi
98418dba 16102LIBS=$ac_save_LIBS
b5de8dc0 16103
c0d27fcc
MR
16104
16105
16106echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
16107echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
16108if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 16109 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16110else
b936fae4
AS
16111 while :; do
16112 ac_cv_sys_largefile_source=no
503d2be0 16113 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16114/* confdefs.h. */
16115_ACEOF
16116cat confdefs.h >>conftest.$ac_ext
16117cat >>conftest.$ac_ext <<_ACEOF
16118/* end confdefs.h. */
b936fae4 16119#include <stdio.h>
503d2be0
AS
16120int
16121main ()
16122{
b936fae4
AS
16123return !fseeko;
16124 ;
16125 return 0;
16126}
16127_ACEOF
16128rm -f conftest.$ac_objext
c0d27fcc 16129if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16130 (eval $ac_compile) 2>conftest.er1
b936fae4 16131 ac_status=$?
35996d22
AS
16132 grep -v '^ *+' conftest.er1 >conftest.err
16133 rm -f conftest.er1
16134 cat conftest.err >&5
c0d27fcc 16135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16136 (exit $ac_status); } &&
4494a266
JD
16137 { ac_try='test -z "$ac_c_werror_flag"
16138 || test ! -s conftest.err'
35996d22
AS
16139 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16140 (eval $ac_try) 2>&5
16141 ac_status=$?
16142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16143 (exit $ac_status); }; } &&
16144 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16145 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16146 (eval $ac_try) 2>&5
16147 ac_status=$?
c0d27fcc 16148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16149 (exit $ac_status); }; }; then
16150 break
16151else
16152 echo "$as_me: failed program was:" >&5
19650fd6
AS
16153sed 's/^/| /' conftest.$ac_ext >&5
16154
b936fae4 16155fi
35996d22 16156rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4 16157 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16158/* confdefs.h. */
16159_ACEOF
16160cat confdefs.h >>conftest.$ac_ext
16161cat >>conftest.$ac_ext <<_ACEOF
16162/* end confdefs.h. */
b936fae4
AS
16163#define _LARGEFILE_SOURCE 1
16164#include <stdio.h>
b936fae4
AS
16165int
16166main ()
16167{
16168return !fseeko;
16169 ;
16170 return 0;
16171}
16172_ACEOF
16173rm -f conftest.$ac_objext
c0d27fcc 16174if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16175 (eval $ac_compile) 2>conftest.er1
b936fae4 16176 ac_status=$?
35996d22
AS
16177 grep -v '^ *+' conftest.er1 >conftest.err
16178 rm -f conftest.er1
16179 cat conftest.err >&5
c0d27fcc 16180 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 16181 (exit $ac_status); } &&
4494a266
JD
16182 { ac_try='test -z "$ac_c_werror_flag"
16183 || test ! -s conftest.err'
35996d22
AS
16184 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16185 (eval $ac_try) 2>&5
16186 ac_status=$?
16187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16188 (exit $ac_status); }; } &&
16189 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16190 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
16191 (eval $ac_try) 2>&5
16192 ac_status=$?
c0d27fcc 16193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
16194 (exit $ac_status); }; }; then
16195 ac_cv_sys_largefile_source=1; break
16196else
16197 echo "$as_me: failed program was:" >&5
19650fd6
AS
16198sed 's/^/| /' conftest.$ac_ext >&5
16199
b936fae4 16200fi
35996d22 16201rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
b936fae4
AS
16202 break
16203done
16204fi
c0d27fcc 16205echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
16206echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16207if test "$ac_cv_sys_largefile_source" != no; then
16208
c0d27fcc 16209cat >>confdefs.h <<_ACEOF
b936fae4 16210#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 16211_ACEOF
b936fae4
AS
16212
16213fi
16214rm -f conftest*
4c343001 16215
b936fae4
AS
16216# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16217# in glibc 2.1.3, but that breaks too many other things.
16218# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 16219echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
16220echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16221if test "${ac_cv_func_fseeko+set}" = set; then
16222 echo $ECHO_N "(cached) $ECHO_C" >&6
16223else
16224 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16225/* confdefs.h. */
16226_ACEOF
16227cat confdefs.h >>conftest.$ac_ext
16228cat >>conftest.$ac_ext <<_ACEOF
16229/* end confdefs.h. */
b936fae4 16230#include <stdio.h>
b936fae4
AS
16231int
16232main ()
16233{
16234return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
16235 ;
16236 return 0;
16237}
16238_ACEOF
16239rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16240if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16241 (eval $ac_link) 2>conftest.er1
503d2be0 16242 ac_status=$?
35996d22
AS
16243 grep -v '^ *+' conftest.er1 >conftest.err
16244 rm -f conftest.er1
16245 cat conftest.err >&5
c0d27fcc 16246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16247 (exit $ac_status); } &&
4494a266
JD
16248 { ac_try='test -z "$ac_c_werror_flag"
16249 || test ! -s conftest.err'
35996d22
AS
16250 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16251 (eval $ac_try) 2>&5
16252 ac_status=$?
16253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16254 (exit $ac_status); }; } &&
16255 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16256 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16257 (eval $ac_try) 2>&5
16258 ac_status=$?
c0d27fcc 16259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16260 (exit $ac_status); }; }; then
b936fae4 16261 ac_cv_func_fseeko=yes
503d2be0
AS
16262else
16263 echo "$as_me: failed program was:" >&5
19650fd6
AS
16264sed 's/^/| /' conftest.$ac_ext >&5
16265
b936fae4 16266ac_cv_func_fseeko=no
503d2be0 16267fi
35996d22
AS
16268rm -f conftest.err conftest.$ac_objext \
16269 conftest$ac_exeext conftest.$ac_ext
503d2be0 16270fi
c0d27fcc 16271echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
16272echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16273if test $ac_cv_func_fseeko = yes; then
16274
c0d27fcc 16275cat >>confdefs.h <<\_ACEOF
b936fae4 16276#define HAVE_FSEEKO 1
c0d27fcc 16277_ACEOF
b936fae4 16278
4c343001
DL
16279fi
16280
c0d27fcc 16281
cd958eb3
MB
16282echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
16283echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
16284if test "${ac_cv_func_getpgrp_void+set}" = set; then
16285 echo $ECHO_N "(cached) $ECHO_C" >&6
16286else
16287 # Use it with a single arg.
16288cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16289/* confdefs.h. */
16290_ACEOF
16291cat confdefs.h >>conftest.$ac_ext
16292cat >>conftest.$ac_ext <<_ACEOF
16293/* end confdefs.h. */
cd958eb3
MB
16294$ac_includes_default
16295int
16296main ()
16297{
16298getpgrp (0);
16299 ;
16300 return 0;
16301}
16302_ACEOF
16303rm -f conftest.$ac_objext
16304if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 16305 (eval $ac_compile) 2>conftest.er1
cd958eb3 16306 ac_status=$?
35996d22
AS
16307 grep -v '^ *+' conftest.er1 >conftest.err
16308 rm -f conftest.er1
16309 cat conftest.err >&5
cd958eb3
MB
16310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16311 (exit $ac_status); } &&
4494a266
JD
16312 { ac_try='test -z "$ac_c_werror_flag"
16313 || test ! -s conftest.err'
35996d22
AS
16314 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16315 (eval $ac_try) 2>&5
16316 ac_status=$?
16317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16318 (exit $ac_status); }; } &&
16319 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
16320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16321 (eval $ac_try) 2>&5
16322 ac_status=$?
16323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16324 (exit $ac_status); }; }; then
16325 ac_cv_func_getpgrp_void=no
16326else
16327 echo "$as_me: failed program was:" >&5
19650fd6
AS
16328sed 's/^/| /' conftest.$ac_ext >&5
16329
cd958eb3
MB
16330ac_cv_func_getpgrp_void=yes
16331fi
35996d22 16332rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
16333
16334fi
16335echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
16336echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
16337if test $ac_cv_func_getpgrp_void = yes; then
16338
16339cat >>confdefs.h <<\_ACEOF
16340#define GETPGRP_VOID 1
16341_ACEOF
16342
16343fi
16344
16345
973a76b1
DL
16346
16347for ac_func in strftime
16348do
16349as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16350echo "$as_me:$LINENO: checking for $ac_func" >&5
16351echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16352if eval "test \"\${$as_ac_var+set}\" = set"; then
16353 echo $ECHO_N "(cached) $ECHO_C" >&6
16354else
16355 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16356/* confdefs.h. */
16357_ACEOF
16358cat confdefs.h >>conftest.$ac_ext
16359cat >>conftest.$ac_ext <<_ACEOF
16360/* end confdefs.h. */
35996d22
AS
16361/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16362 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16363#define $ac_func innocuous_$ac_func
16364
973a76b1 16365/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16366 which can conflict with char $ac_func (); below.
16367 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16368 <limits.h> exists even on freestanding compilers. */
35996d22 16369
19650fd6
AS
16370#ifdef __STDC__
16371# include <limits.h>
16372#else
16373# include <assert.h>
16374#endif
35996d22
AS
16375
16376#undef $ac_func
16377
973a76b1
DL
16378/* Override any gcc2 internal prototype to avoid an error. */
16379#ifdef __cplusplus
16380extern "C"
19650fd6 16381{
973a76b1
DL
16382#endif
16383/* We use char because int might match the return type of a gcc2
16384 builtin and then its argument prototype would still apply. */
16385char $ac_func ();
16386/* The GNU C library defines this for functions which it implements
16387 to always fail with ENOSYS. Some functions are actually named
16388 something starting with __ and the normal name is an alias. */
16389#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16390choke me
16391#else
19650fd6
AS
16392char (*f) () = $ac_func;
16393#endif
16394#ifdef __cplusplus
16395}
973a76b1
DL
16396#endif
16397
19650fd6
AS
16398int
16399main ()
16400{
16401return f != $ac_func;
973a76b1
DL
16402 ;
16403 return 0;
16404}
16405_ACEOF
16406rm -f conftest.$ac_objext conftest$ac_exeext
16407if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16408 (eval $ac_link) 2>conftest.er1
973a76b1 16409 ac_status=$?
35996d22
AS
16410 grep -v '^ *+' conftest.er1 >conftest.err
16411 rm -f conftest.er1
16412 cat conftest.err >&5
973a76b1
DL
16413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16414 (exit $ac_status); } &&
4494a266
JD
16415 { ac_try='test -z "$ac_c_werror_flag"
16416 || test ! -s conftest.err'
35996d22
AS
16417 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16418 (eval $ac_try) 2>&5
16419 ac_status=$?
16420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16421 (exit $ac_status); }; } &&
16422 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
16423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16424 (eval $ac_try) 2>&5
16425 ac_status=$?
16426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16427 (exit $ac_status); }; }; then
16428 eval "$as_ac_var=yes"
16429else
16430 echo "$as_me: failed program was:" >&5
19650fd6
AS
16431sed 's/^/| /' conftest.$ac_ext >&5
16432
973a76b1
DL
16433eval "$as_ac_var=no"
16434fi
35996d22
AS
16435rm -f conftest.err conftest.$ac_objext \
16436 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16437fi
16438echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16439echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16440if test `eval echo '${'$as_ac_var'}'` = yes; then
16441 cat >>confdefs.h <<_ACEOF
16442#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16443_ACEOF
16444
16445else
16446 # strftime is in -lintl on SCO UNIX.
16447echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
16448echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
16449if test "${ac_cv_lib_intl_strftime+set}" = set; then
16450 echo $ECHO_N "(cached) $ECHO_C" >&6
16451else
16452 ac_check_lib_save_LIBS=$LIBS
16453LIBS="-lintl $LIBS"
16454cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16455/* confdefs.h. */
16456_ACEOF
16457cat confdefs.h >>conftest.$ac_ext
16458cat >>conftest.$ac_ext <<_ACEOF
16459/* end confdefs.h. */
973a76b1
DL
16460
16461/* Override any gcc2 internal prototype to avoid an error. */
16462#ifdef __cplusplus
16463extern "C"
16464#endif
16465/* We use char because int might match the return type of a gcc2
16466 builtin and then its argument prototype would still apply. */
16467char strftime ();
16468int
16469main ()
16470{
16471strftime ();
16472 ;
16473 return 0;
16474}
16475_ACEOF
16476rm -f conftest.$ac_objext conftest$ac_exeext
16477if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16478 (eval $ac_link) 2>conftest.er1
973a76b1 16479 ac_status=$?
35996d22
AS
16480 grep -v '^ *+' conftest.er1 >conftest.err
16481 rm -f conftest.er1
16482 cat conftest.err >&5
973a76b1
DL
16483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16484 (exit $ac_status); } &&
4494a266
JD
16485 { ac_try='test -z "$ac_c_werror_flag"
16486 || test ! -s conftest.err'
35996d22
AS
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_exeext'
973a76b1
DL
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_cv_lib_intl_strftime=yes
16499else
16500 echo "$as_me: failed program was:" >&5
19650fd6
AS
16501sed 's/^/| /' conftest.$ac_ext >&5
16502
973a76b1
DL
16503ac_cv_lib_intl_strftime=no
16504fi
35996d22
AS
16505rm -f conftest.err conftest.$ac_objext \
16506 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
16507LIBS=$ac_check_lib_save_LIBS
16508fi
16509echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
16510echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
16511if test $ac_cv_lib_intl_strftime = yes; then
16512 cat >>confdefs.h <<\_ACEOF
16513#define HAVE_STRFTIME 1
16514_ACEOF
16515
16516LIBS="-lintl $LIBS"
16517fi
16518
16519fi
16520done
16521
16522
b936fae4
AS
16523# UNIX98 PTYs.
16524
16525for ac_func in grantpt
503d2be0
AS
16526do
16527as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16528echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
16529echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16530if eval "test \"\${$as_ac_var+set}\" = set"; then
16531 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16532else
503d2be0 16533 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16534/* confdefs.h. */
16535_ACEOF
16536cat confdefs.h >>conftest.$ac_ext
16537cat >>conftest.$ac_ext <<_ACEOF
16538/* end confdefs.h. */
35996d22
AS
16539/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16540 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16541#define $ac_func innocuous_$ac_func
16542
503d2be0 16543/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16544 which can conflict with char $ac_func (); below.
16545 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16546 <limits.h> exists even on freestanding compilers. */
35996d22 16547
19650fd6
AS
16548#ifdef __STDC__
16549# include <limits.h>
16550#else
16551# include <assert.h>
16552#endif
35996d22
AS
16553
16554#undef $ac_func
16555
4c343001 16556/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16557#ifdef __cplusplus
16558extern "C"
19650fd6 16559{
503d2be0 16560#endif
4c343001 16561/* We use char because int might match the return type of a gcc2
503d2be0
AS
16562 builtin and then its argument prototype would still apply. */
16563char $ac_func ();
503d2be0
AS
16564/* The GNU C library defines this for functions which it implements
16565 to always fail with ENOSYS. Some functions are actually named
16566 something starting with __ and the normal name is an alias. */
16567#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16568choke me
16569#else
19650fd6
AS
16570char (*f) () = $ac_func;
16571#endif
16572#ifdef __cplusplus
16573}
503d2be0 16574#endif
4c343001 16575
19650fd6
AS
16576int
16577main ()
16578{
16579return f != $ac_func;
503d2be0
AS
16580 ;
16581 return 0;
16582}
16583_ACEOF
16584rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16585if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16586 (eval $ac_link) 2>conftest.er1
503d2be0 16587 ac_status=$?
35996d22
AS
16588 grep -v '^ *+' conftest.er1 >conftest.err
16589 rm -f conftest.er1
16590 cat conftest.err >&5
c0d27fcc 16591 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16592 (exit $ac_status); } &&
4494a266
JD
16593 { ac_try='test -z "$ac_c_werror_flag"
16594 || test ! -s conftest.err'
35996d22
AS
16595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16596 (eval $ac_try) 2>&5
16597 ac_status=$?
16598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16599 (exit $ac_status); }; } &&
16600 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16601 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16602 (eval $ac_try) 2>&5
16603 ac_status=$?
c0d27fcc 16604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16605 (exit $ac_status); }; }; then
16606 eval "$as_ac_var=yes"
16607else
16608 echo "$as_me: failed program was:" >&5
19650fd6
AS
16609sed 's/^/| /' conftest.$ac_ext >&5
16610
503d2be0
AS
16611eval "$as_ac_var=no"
16612fi
35996d22
AS
16613rm -f conftest.err conftest.$ac_objext \
16614 conftest$ac_exeext conftest.$ac_ext
503d2be0 16615fi
c0d27fcc 16616echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16617echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16618if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16619 cat >>confdefs.h <<_ACEOF
503d2be0 16620#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16621_ACEOF
4c343001
DL
16622
16623fi
503d2be0
AS
16624done
16625
c0d27fcc 16626
b936fae4 16627# PTY-related GNU extensions.
4c343001 16628
b936fae4
AS
16629for ac_func in getpt
16630do
16631as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16632echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
16633echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16634if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 16635 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 16636else
b936fae4 16637 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16638/* confdefs.h. */
16639_ACEOF
16640cat confdefs.h >>conftest.$ac_ext
16641cat >>conftest.$ac_ext <<_ACEOF
16642/* end confdefs.h. */
35996d22
AS
16643/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16644 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16645#define $ac_func innocuous_$ac_func
16646
087121cc 16647/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16648 which can conflict with char $ac_func (); below.
16649 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16650 <limits.h> exists even on freestanding compilers. */
35996d22 16651
19650fd6
AS
16652#ifdef __STDC__
16653# include <limits.h>
16654#else
16655# include <assert.h>
16656#endif
35996d22
AS
16657
16658#undef $ac_func
16659
087121cc 16660/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16661#ifdef __cplusplus
16662extern "C"
19650fd6 16663{
503d2be0 16664#endif
087121cc 16665/* We use char because int might match the return type of a gcc2
503d2be0
AS
16666 builtin and then its argument prototype would still apply. */
16667char $ac_func ();
087121cc
GM
16668/* The GNU C library defines this for functions which it implements
16669 to always fail with ENOSYS. Some functions are actually named
16670 something starting with __ and the normal name is an alias. */
16671#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16672choke me
16673#else
19650fd6
AS
16674char (*f) () = $ac_func;
16675#endif
16676#ifdef __cplusplus
16677}
087121cc
GM
16678#endif
16679
19650fd6
AS
16680int
16681main ()
16682{
16683return f != $ac_func;
503d2be0
AS
16684 ;
16685 return 0;
16686}
16687_ACEOF
16688rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16689if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16690 (eval $ac_link) 2>conftest.er1
503d2be0 16691 ac_status=$?
35996d22
AS
16692 grep -v '^ *+' conftest.er1 >conftest.err
16693 rm -f conftest.er1
16694 cat conftest.err >&5
c0d27fcc 16695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16696 (exit $ac_status); } &&
4494a266
JD
16697 { ac_try='test -z "$ac_c_werror_flag"
16698 || test ! -s conftest.err'
35996d22
AS
16699 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16700 (eval $ac_try) 2>&5
16701 ac_status=$?
16702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16703 (exit $ac_status); }; } &&
16704 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16705 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16706 (eval $ac_try) 2>&5
16707 ac_status=$?
c0d27fcc 16708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16709 (exit $ac_status); }; }; then
16710 eval "$as_ac_var=yes"
16711else
16712 echo "$as_me: failed program was:" >&5
19650fd6
AS
16713sed 's/^/| /' conftest.$ac_ext >&5
16714
503d2be0
AS
16715eval "$as_ac_var=no"
16716fi
35996d22
AS
16717rm -f conftest.err conftest.$ac_objext \
16718 conftest$ac_exeext conftest.$ac_ext
503d2be0 16719fi
c0d27fcc 16720echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16721echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16722if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16723 cat >>confdefs.h <<_ACEOF
503d2be0 16724#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16725_ACEOF
087121cc 16726
087121cc
GM
16727fi
16728done
16729
c0d27fcc 16730
ba4481b5
DL
16731# Check this now, so that we will NOT find the above functions in ncurses.
16732# That is because we have not set up to link ncurses in lib-src.
16733# It's better to believe a function is not available
16734# than to expect to find it in ncurses.
503d2be0 16735
c0d27fcc 16736echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
16737echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
16738if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
16739 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16740else
503d2be0 16741 ac_check_lib_save_LIBS=$LIBS
ba4481b5 16742LIBS="-lncurses $LIBS"
503d2be0 16743cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16744/* confdefs.h. */
16745_ACEOF
16746cat confdefs.h >>conftest.$ac_ext
16747cat >>conftest.$ac_ext <<_ACEOF
16748/* end confdefs.h. */
503d2be0 16749
ba4481b5 16750/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16751#ifdef __cplusplus
16752extern "C"
16753#endif
ba4481b5 16754/* We use char because int might match the return type of a gcc2
503d2be0
AS
16755 builtin and then its argument prototype would still apply. */
16756char tparm ();
16757int
16758main ()
16759{
16760tparm ();
16761 ;
16762 return 0;
16763}
16764_ACEOF
16765rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16766if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16767 (eval $ac_link) 2>conftest.er1
503d2be0 16768 ac_status=$?
35996d22
AS
16769 grep -v '^ *+' conftest.er1 >conftest.err
16770 rm -f conftest.er1
16771 cat conftest.err >&5
c0d27fcc 16772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16773 (exit $ac_status); } &&
4494a266
JD
16774 { ac_try='test -z "$ac_c_werror_flag"
16775 || test ! -s conftest.err'
35996d22
AS
16776 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16777 (eval $ac_try) 2>&5
16778 ac_status=$?
16779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16780 (exit $ac_status); }; } &&
16781 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16783 (eval $ac_try) 2>&5
16784 ac_status=$?
c0d27fcc 16785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16786 (exit $ac_status); }; }; then
16787 ac_cv_lib_ncurses_tparm=yes
16788else
16789 echo "$as_me: failed program was:" >&5
19650fd6
AS
16790sed 's/^/| /' conftest.$ac_ext >&5
16791
503d2be0
AS
16792ac_cv_lib_ncurses_tparm=no
16793fi
35996d22
AS
16794rm -f conftest.err conftest.$ac_objext \
16795 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16796LIBS=$ac_check_lib_save_LIBS
16797fi
c0d27fcc 16798echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
16799echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
16800if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 16801 cat >>confdefs.h <<_ACEOF
503d2be0 16802#define HAVE_LIBNCURSES 1
c0d27fcc 16803_ACEOF
ba4481b5
DL
16804
16805 LIBS="-lncurses $LIBS"
16806
ba4481b5
DL
16807fi
16808
c0d27fcc 16809
84e70f78
KR
16810# Do we need the Hesiod library to provide the support routines?
16811if test "$with_hesiod" = yes ; then
16812 # Don't set $LIBS here -- see comments above.
16813 resolv=no
c0d27fcc 16814 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
16815echo $ECHO_N "checking for res_send... $ECHO_C" >&6
16816if test "${ac_cv_func_res_send+set}" = set; then
16817 echo $ECHO_N "(cached) $ECHO_C" >&6
16818else
16819 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16820/* confdefs.h. */
16821_ACEOF
16822cat confdefs.h >>conftest.$ac_ext
16823cat >>conftest.$ac_ext <<_ACEOF
16824/* end confdefs.h. */
35996d22
AS
16825/* Define res_send to an innocuous variant, in case <limits.h> declares res_send.
16826 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16827#define res_send innocuous_res_send
16828
84e70f78 16829/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16830 which can conflict with char res_send (); below.
16831 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16832 <limits.h> exists even on freestanding compilers. */
35996d22 16833
19650fd6
AS
16834#ifdef __STDC__
16835# include <limits.h>
16836#else
16837# include <assert.h>
16838#endif
35996d22
AS
16839
16840#undef res_send
16841
84e70f78
KR
16842/* Override any gcc2 internal prototype to avoid an error. */
16843#ifdef __cplusplus
16844extern "C"
19650fd6 16845{
84e70f78
KR
16846#endif
16847/* We use char because int might match the return type of a gcc2
16848 builtin and then its argument prototype would still apply. */
16849char res_send ();
84e70f78
KR
16850/* The GNU C library defines this for functions which it implements
16851 to always fail with ENOSYS. Some functions are actually named
16852 something starting with __ and the normal name is an alias. */
16853#if defined (__stub_res_send) || defined (__stub___res_send)
16854choke me
16855#else
19650fd6
AS
16856char (*f) () = res_send;
16857#endif
16858#ifdef __cplusplus
16859}
cd958eb3
MB
16860#endif
16861
19650fd6
AS
16862int
16863main ()
16864{
16865return f != res_send;
84e70f78
KR
16866 ;
16867 return 0;
16868}
16869_ACEOF
16870rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16871if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16872 (eval $ac_link) 2>conftest.er1
84e70f78 16873 ac_status=$?
35996d22
AS
16874 grep -v '^ *+' conftest.er1 >conftest.err
16875 rm -f conftest.er1
16876 cat conftest.err >&5
c0d27fcc 16877 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16878 (exit $ac_status); } &&
4494a266
JD
16879 { ac_try='test -z "$ac_c_werror_flag"
16880 || test ! -s conftest.err'
35996d22
AS
16881 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16882 (eval $ac_try) 2>&5
16883 ac_status=$?
16884 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16885 (exit $ac_status); }; } &&
16886 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16887 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16888 (eval $ac_try) 2>&5
16889 ac_status=$?
c0d27fcc 16890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16891 (exit $ac_status); }; }; then
16892 ac_cv_func_res_send=yes
16893else
16894 echo "$as_me: failed program was:" >&5
19650fd6
AS
16895sed 's/^/| /' conftest.$ac_ext >&5
16896
84e70f78
KR
16897ac_cv_func_res_send=no
16898fi
35996d22
AS
16899rm -f conftest.err conftest.$ac_objext \
16900 conftest$ac_exeext conftest.$ac_ext
84e70f78 16901fi
c0d27fcc 16902echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
16903echo "${ECHO_T}$ac_cv_func_res_send" >&6
16904if test $ac_cv_func_res_send = yes; then
16905 :
16906else
c0d27fcc 16907 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
16908echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
16909if test "${ac_cv_func___res_send+set}" = set; then
16910 echo $ECHO_N "(cached) $ECHO_C" >&6
16911else
16912 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
16913/* confdefs.h. */
16914_ACEOF
16915cat confdefs.h >>conftest.$ac_ext
16916cat >>conftest.$ac_ext <<_ACEOF
16917/* end confdefs.h. */
35996d22
AS
16918/* Define __res_send to an innocuous variant, in case <limits.h> declares __res_send.
16919 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16920#define __res_send innocuous___res_send
16921
84e70f78 16922/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16923 which can conflict with char __res_send (); below.
16924 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16925 <limits.h> exists even on freestanding compilers. */
35996d22 16926
19650fd6
AS
16927#ifdef __STDC__
16928# include <limits.h>
16929#else
16930# include <assert.h>
16931#endif
35996d22
AS
16932
16933#undef __res_send
16934
84e70f78
KR
16935/* Override any gcc2 internal prototype to avoid an error. */
16936#ifdef __cplusplus
16937extern "C"
19650fd6 16938{
84e70f78
KR
16939#endif
16940/* We use char because int might match the return type of a gcc2
16941 builtin and then its argument prototype would still apply. */
16942char __res_send ();
84e70f78
KR
16943/* The GNU C library defines this for functions which it implements
16944 to always fail with ENOSYS. Some functions are actually named
16945 something starting with __ and the normal name is an alias. */
16946#if defined (__stub___res_send) || defined (__stub_____res_send)
16947choke me
16948#else
19650fd6
AS
16949char (*f) () = __res_send;
16950#endif
16951#ifdef __cplusplus
16952}
84e70f78
KR
16953#endif
16954
19650fd6
AS
16955int
16956main ()
16957{
16958return f != __res_send;
84e70f78
KR
16959 ;
16960 return 0;
16961}
16962_ACEOF
16963rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16964if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 16965 (eval $ac_link) 2>conftest.er1
84e70f78 16966 ac_status=$?
35996d22
AS
16967 grep -v '^ *+' conftest.er1 >conftest.err
16968 rm -f conftest.er1
16969 cat conftest.err >&5
c0d27fcc 16970 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16971 (exit $ac_status); } &&
4494a266
JD
16972 { ac_try='test -z "$ac_c_werror_flag"
16973 || test ! -s conftest.err'
35996d22
AS
16974 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16975 (eval $ac_try) 2>&5
16976 ac_status=$?
16977 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16978 (exit $ac_status); }; } &&
16979 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16980 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16981 (eval $ac_try) 2>&5
16982 ac_status=$?
c0d27fcc 16983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16984 (exit $ac_status); }; }; then
16985 ac_cv_func___res_send=yes
16986else
16987 echo "$as_me: failed program was:" >&5
19650fd6
AS
16988sed 's/^/| /' conftest.$ac_ext >&5
16989
84e70f78
KR
16990ac_cv_func___res_send=no
16991fi
35996d22
AS
16992rm -f conftest.err conftest.$ac_objext \
16993 conftest$ac_exeext conftest.$ac_ext
84e70f78 16994fi
c0d27fcc 16995echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
16996echo "${ECHO_T}$ac_cv_func___res_send" >&6
16997if test $ac_cv_func___res_send = yes; then
16998 :
16999else
c0d27fcc 17000 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
17001echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
17002if test "${ac_cv_lib_resolv_res_send+set}" = set; then
17003 echo $ECHO_N "(cached) $ECHO_C" >&6
17004else
17005 ac_check_lib_save_LIBS=$LIBS
17006LIBS="-lresolv $LIBS"
17007cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17008/* confdefs.h. */
17009_ACEOF
17010cat confdefs.h >>conftest.$ac_ext
17011cat >>conftest.$ac_ext <<_ACEOF
17012/* end confdefs.h. */
84e70f78
KR
17013
17014/* Override any gcc2 internal prototype to avoid an error. */
17015#ifdef __cplusplus
17016extern "C"
17017#endif
17018/* We use char because int might match the return type of a gcc2
17019 builtin and then its argument prototype would still apply. */
17020char res_send ();
17021int
17022main ()
17023{
17024res_send ();
17025 ;
17026 return 0;
17027}
17028_ACEOF
17029rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17030if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17031 (eval $ac_link) 2>conftest.er1
84e70f78 17032 ac_status=$?
35996d22
AS
17033 grep -v '^ *+' conftest.er1 >conftest.err
17034 rm -f conftest.er1
17035 cat conftest.err >&5
c0d27fcc 17036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17037 (exit $ac_status); } &&
4494a266
JD
17038 { ac_try='test -z "$ac_c_werror_flag"
17039 || test ! -s conftest.err'
35996d22
AS
17040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17041 (eval $ac_try) 2>&5
17042 ac_status=$?
17043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17044 (exit $ac_status); }; } &&
17045 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17046 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17047 (eval $ac_try) 2>&5
17048 ac_status=$?
c0d27fcc 17049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17050 (exit $ac_status); }; }; then
17051 ac_cv_lib_resolv_res_send=yes
17052else
17053 echo "$as_me: failed program was:" >&5
19650fd6
AS
17054sed 's/^/| /' conftest.$ac_ext >&5
17055
84e70f78
KR
17056ac_cv_lib_resolv_res_send=no
17057fi
35996d22
AS
17058rm -f conftest.err conftest.$ac_objext \
17059 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17060LIBS=$ac_check_lib_save_LIBS
17061fi
c0d27fcc 17062echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
17063echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
17064if test $ac_cv_lib_resolv_res_send = yes; then
17065 resolv=yes
17066else
c0d27fcc 17067 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
17068echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
17069if test "${ac_cv_lib_resolv___res_send+set}" = set; then
17070 echo $ECHO_N "(cached) $ECHO_C" >&6
17071else
17072 ac_check_lib_save_LIBS=$LIBS
17073LIBS="-lresolv $LIBS"
17074cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17075/* confdefs.h. */
17076_ACEOF
17077cat confdefs.h >>conftest.$ac_ext
17078cat >>conftest.$ac_ext <<_ACEOF
17079/* end confdefs.h. */
84e70f78
KR
17080
17081/* Override any gcc2 internal prototype to avoid an error. */
17082#ifdef __cplusplus
17083extern "C"
17084#endif
17085/* We use char because int might match the return type of a gcc2
17086 builtin and then its argument prototype would still apply. */
17087char __res_send ();
17088int
17089main ()
17090{
17091__res_send ();
17092 ;
17093 return 0;
17094}
17095_ACEOF
17096rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17097if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17098 (eval $ac_link) 2>conftest.er1
84e70f78 17099 ac_status=$?
35996d22
AS
17100 grep -v '^ *+' conftest.er1 >conftest.err
17101 rm -f conftest.er1
17102 cat conftest.err >&5
c0d27fcc 17103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17104 (exit $ac_status); } &&
4494a266
JD
17105 { ac_try='test -z "$ac_c_werror_flag"
17106 || test ! -s conftest.err'
35996d22
AS
17107 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17108 (eval $ac_try) 2>&5
17109 ac_status=$?
17110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17111 (exit $ac_status); }; } &&
17112 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17113 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17114 (eval $ac_try) 2>&5
17115 ac_status=$?
c0d27fcc 17116 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17117 (exit $ac_status); }; }; then
17118 ac_cv_lib_resolv___res_send=yes
17119else
17120 echo "$as_me: failed program was:" >&5
19650fd6
AS
17121sed 's/^/| /' conftest.$ac_ext >&5
17122
84e70f78
KR
17123ac_cv_lib_resolv___res_send=no
17124fi
35996d22
AS
17125rm -f conftest.err conftest.$ac_objext \
17126 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17127LIBS=$ac_check_lib_save_LIBS
17128fi
c0d27fcc 17129echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
17130echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
17131if test $ac_cv_lib_resolv___res_send = yes; then
17132 resolv=yes
17133fi
17134
17135fi
17136
17137fi
17138
17139fi
17140
17141 if test "$resolv" = yes ; then
17142 RESOLVLIB=-lresolv
b936fae4 17143
c0d27fcc 17144cat >>confdefs.h <<\_ACEOF
84e70f78 17145#define HAVE_LIBRESOLV 1
c0d27fcc 17146_ACEOF
84e70f78
KR
17147
17148 else
17149 RESOLVLIB=
17150 fi
c0d27fcc 17151 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
17152echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
17153if test "${ac_cv_func_hes_getmailhost+set}" = set; then
17154 echo $ECHO_N "(cached) $ECHO_C" >&6
17155else
17156 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17157/* confdefs.h. */
17158_ACEOF
17159cat confdefs.h >>conftest.$ac_ext
17160cat >>conftest.$ac_ext <<_ACEOF
17161/* end confdefs.h. */
35996d22
AS
17162/* Define hes_getmailhost to an innocuous variant, in case <limits.h> declares hes_getmailhost.
17163 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17164#define hes_getmailhost innocuous_hes_getmailhost
17165
84e70f78 17166/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
17167 which can conflict with char hes_getmailhost (); below.
17168 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17169 <limits.h> exists even on freestanding compilers. */
35996d22 17170
19650fd6
AS
17171#ifdef __STDC__
17172# include <limits.h>
17173#else
17174# include <assert.h>
17175#endif
35996d22
AS
17176
17177#undef hes_getmailhost
17178
84e70f78
KR
17179/* Override any gcc2 internal prototype to avoid an error. */
17180#ifdef __cplusplus
17181extern "C"
19650fd6 17182{
84e70f78
KR
17183#endif
17184/* We use char because int might match the return type of a gcc2
17185 builtin and then its argument prototype would still apply. */
17186char hes_getmailhost ();
84e70f78
KR
17187/* The GNU C library defines this for functions which it implements
17188 to always fail with ENOSYS. Some functions are actually named
17189 something starting with __ and the normal name is an alias. */
17190#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
17191choke me
17192#else
19650fd6
AS
17193char (*f) () = hes_getmailhost;
17194#endif
17195#ifdef __cplusplus
17196}
cd958eb3
MB
17197#endif
17198
19650fd6
AS
17199int
17200main ()
17201{
17202return f != hes_getmailhost;
84e70f78
KR
17203 ;
17204 return 0;
17205}
17206_ACEOF
17207rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17208if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17209 (eval $ac_link) 2>conftest.er1
84e70f78 17210 ac_status=$?
35996d22
AS
17211 grep -v '^ *+' conftest.er1 >conftest.err
17212 rm -f conftest.er1
17213 cat conftest.err >&5
c0d27fcc 17214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17215 (exit $ac_status); } &&
4494a266
JD
17216 { ac_try='test -z "$ac_c_werror_flag"
17217 || test ! -s conftest.err'
35996d22
AS
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); }; } &&
17223 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17225 (eval $ac_try) 2>&5
17226 ac_status=$?
c0d27fcc 17227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17228 (exit $ac_status); }; }; then
17229 ac_cv_func_hes_getmailhost=yes
17230else
17231 echo "$as_me: failed program was:" >&5
19650fd6
AS
17232sed 's/^/| /' conftest.$ac_ext >&5
17233
84e70f78
KR
17234ac_cv_func_hes_getmailhost=no
17235fi
35996d22
AS
17236rm -f conftest.err conftest.$ac_objext \
17237 conftest$ac_exeext conftest.$ac_ext
84e70f78 17238fi
c0d27fcc 17239echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
17240echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
17241if test $ac_cv_func_hes_getmailhost = yes; then
17242 :
17243else
c0d27fcc 17244 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
17245echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
17246if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
17247 echo $ECHO_N "(cached) $ECHO_C" >&6
17248else
17249 ac_check_lib_save_LIBS=$LIBS
17250LIBS="-lhesiod $RESOLVLIB $LIBS"
17251cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17252/* confdefs.h. */
17253_ACEOF
17254cat confdefs.h >>conftest.$ac_ext
17255cat >>conftest.$ac_ext <<_ACEOF
17256/* end confdefs.h. */
84e70f78
KR
17257
17258/* Override any gcc2 internal prototype to avoid an error. */
17259#ifdef __cplusplus
17260extern "C"
17261#endif
17262/* We use char because int might match the return type of a gcc2
17263 builtin and then its argument prototype would still apply. */
17264char hes_getmailhost ();
17265int
17266main ()
17267{
17268hes_getmailhost ();
17269 ;
17270 return 0;
17271}
17272_ACEOF
17273rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17274if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17275 (eval $ac_link) 2>conftest.er1
84e70f78 17276 ac_status=$?
35996d22
AS
17277 grep -v '^ *+' conftest.er1 >conftest.err
17278 rm -f conftest.er1
17279 cat conftest.err >&5
c0d27fcc 17280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 17281 (exit $ac_status); } &&
4494a266
JD
17282 { ac_try='test -z "$ac_c_werror_flag"
17283 || test ! -s conftest.err'
35996d22
AS
17284 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17285 (eval $ac_try) 2>&5
17286 ac_status=$?
17287 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17288 (exit $ac_status); }; } &&
17289 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17290 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
17291 (eval $ac_try) 2>&5
17292 ac_status=$?
c0d27fcc 17293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
17294 (exit $ac_status); }; }; then
17295 ac_cv_lib_hesiod_hes_getmailhost=yes
17296else
17297 echo "$as_me: failed program was:" >&5
19650fd6
AS
17298sed 's/^/| /' conftest.$ac_ext >&5
17299
84e70f78
KR
17300ac_cv_lib_hesiod_hes_getmailhost=no
17301fi
35996d22
AS
17302rm -f conftest.err conftest.$ac_objext \
17303 conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
17304LIBS=$ac_check_lib_save_LIBS
17305fi
c0d27fcc 17306echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
17307echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
17308if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 17309
c0d27fcc 17310cat >>confdefs.h <<\_ACEOF
84e70f78 17311#define HAVE_LIBHESIOD 1
c0d27fcc 17312_ACEOF
84e70f78
KR
17313
17314else
17315 :
17316fi
17317
17318fi
17319
17320fi
17321
a21616bd
KR
17322# These tell us which Kerberos-related libraries to use.
17323if test "${with_kerberos+set}" = set; then
503d2be0 17324
c0d27fcc 17325echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
17326echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
17327if test "${ac_cv_lib_com_err_com_err+set}" = set; then
17328 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17329else
503d2be0 17330 ac_check_lib_save_LIBS=$LIBS
a21616bd 17331LIBS="-lcom_err $LIBS"
503d2be0 17332cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17333/* confdefs.h. */
17334_ACEOF
17335cat confdefs.h >>conftest.$ac_ext
17336cat >>conftest.$ac_ext <<_ACEOF
17337/* end confdefs.h. */
503d2be0 17338
a21616bd 17339/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17340#ifdef __cplusplus
17341extern "C"
17342#endif
a21616bd 17343/* We use char because int might match the return type of a gcc2
503d2be0
AS
17344 builtin and then its argument prototype would still apply. */
17345char com_err ();
17346int
17347main ()
17348{
17349com_err ();
17350 ;
17351 return 0;
17352}
17353_ACEOF
17354rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17355if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17356 (eval $ac_link) 2>conftest.er1
503d2be0 17357 ac_status=$?
35996d22
AS
17358 grep -v '^ *+' conftest.er1 >conftest.err
17359 rm -f conftest.er1
17360 cat conftest.err >&5
c0d27fcc 17361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17362 (exit $ac_status); } &&
4494a266
JD
17363 { ac_try='test -z "$ac_c_werror_flag"
17364 || test ! -s conftest.err'
35996d22
AS
17365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17366 (eval $ac_try) 2>&5
17367 ac_status=$?
17368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17369 (exit $ac_status); }; } &&
17370 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17371 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17372 (eval $ac_try) 2>&5
17373 ac_status=$?
c0d27fcc 17374 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17375 (exit $ac_status); }; }; then
17376 ac_cv_lib_com_err_com_err=yes
17377else
17378 echo "$as_me: failed program was:" >&5
19650fd6
AS
17379sed 's/^/| /' conftest.$ac_ext >&5
17380
503d2be0
AS
17381ac_cv_lib_com_err_com_err=no
17382fi
35996d22
AS
17383rm -f conftest.err conftest.$ac_objext \
17384 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17385LIBS=$ac_check_lib_save_LIBS
17386fi
c0d27fcc 17387echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
17388echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
17389if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 17390 cat >>confdefs.h <<_ACEOF
503d2be0 17391#define HAVE_LIBCOM_ERR 1
c0d27fcc 17392_ACEOF
a21616bd
KR
17393
17394 LIBS="-lcom_err $LIBS"
17395
a21616bd
KR
17396fi
17397
c0d27fcc
MR
17398
17399echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
17400echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
17401if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
17402 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17403else
503d2be0 17404 ac_check_lib_save_LIBS=$LIBS
a21616bd 17405LIBS="-lk5crypto $LIBS"
503d2be0 17406cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17407/* confdefs.h. */
17408_ACEOF
17409cat confdefs.h >>conftest.$ac_ext
17410cat >>conftest.$ac_ext <<_ACEOF
17411/* end confdefs.h. */
503d2be0 17412
a21616bd 17413/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17414#ifdef __cplusplus
17415extern "C"
17416#endif
a21616bd 17417/* We use char because int might match the return type of a gcc2
503d2be0
AS
17418 builtin and then its argument prototype would still apply. */
17419char mit_des_cbc_encrypt ();
17420int
17421main ()
17422{
17423mit_des_cbc_encrypt ();
17424 ;
17425 return 0;
17426}
17427_ACEOF
17428rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17429if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17430 (eval $ac_link) 2>conftest.er1
503d2be0 17431 ac_status=$?
35996d22
AS
17432 grep -v '^ *+' conftest.er1 >conftest.err
17433 rm -f conftest.er1
17434 cat conftest.err >&5
c0d27fcc 17435 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17436 (exit $ac_status); } &&
4494a266
JD
17437 { ac_try='test -z "$ac_c_werror_flag"
17438 || test ! -s conftest.err'
35996d22
AS
17439 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17440 (eval $ac_try) 2>&5
17441 ac_status=$?
17442 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17443 (exit $ac_status); }; } &&
17444 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17445 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17446 (eval $ac_try) 2>&5
17447 ac_status=$?
c0d27fcc 17448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17449 (exit $ac_status); }; }; then
17450 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
17451else
17452 echo "$as_me: failed program was:" >&5
19650fd6
AS
17453sed 's/^/| /' conftest.$ac_ext >&5
17454
503d2be0
AS
17455ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
17456fi
35996d22
AS
17457rm -f conftest.err conftest.$ac_objext \
17458 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17459LIBS=$ac_check_lib_save_LIBS
17460fi
c0d27fcc 17461echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17462echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
17463if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17464 cat >>confdefs.h <<_ACEOF
503d2be0 17465#define HAVE_LIBK5CRYPTO 1
c0d27fcc 17466_ACEOF
a21616bd
KR
17467
17468 LIBS="-lk5crypto $LIBS"
17469
a21616bd
KR
17470fi
17471
c0d27fcc
MR
17472
17473echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
17474echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
17475if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
17476 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17477else
503d2be0 17478 ac_check_lib_save_LIBS=$LIBS
a21616bd 17479LIBS="-lcrypto $LIBS"
503d2be0 17480cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17481/* confdefs.h. */
17482_ACEOF
17483cat confdefs.h >>conftest.$ac_ext
17484cat >>conftest.$ac_ext <<_ACEOF
17485/* end confdefs.h. */
503d2be0 17486
a21616bd 17487/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17488#ifdef __cplusplus
17489extern "C"
17490#endif
a21616bd 17491/* We use char because int might match the return type of a gcc2
503d2be0
AS
17492 builtin and then its argument prototype would still apply. */
17493char mit_des_cbc_encrypt ();
17494int
17495main ()
17496{
17497mit_des_cbc_encrypt ();
17498 ;
17499 return 0;
17500}
17501_ACEOF
17502rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17503if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17504 (eval $ac_link) 2>conftest.er1
503d2be0 17505 ac_status=$?
35996d22
AS
17506 grep -v '^ *+' conftest.er1 >conftest.err
17507 rm -f conftest.er1
17508 cat conftest.err >&5
c0d27fcc 17509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17510 (exit $ac_status); } &&
4494a266
JD
17511 { ac_try='test -z "$ac_c_werror_flag"
17512 || test ! -s conftest.err'
35996d22
AS
17513 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17514 (eval $ac_try) 2>&5
17515 ac_status=$?
17516 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17517 (exit $ac_status); }; } &&
17518 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17519 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17520 (eval $ac_try) 2>&5
17521 ac_status=$?
c0d27fcc 17522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17523 (exit $ac_status); }; }; then
17524 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
17525else
17526 echo "$as_me: failed program was:" >&5
19650fd6
AS
17527sed 's/^/| /' conftest.$ac_ext >&5
17528
503d2be0
AS
17529ac_cv_lib_crypto_mit_des_cbc_encrypt=no
17530fi
35996d22
AS
17531rm -f conftest.err conftest.$ac_objext \
17532 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17533LIBS=$ac_check_lib_save_LIBS
17534fi
c0d27fcc 17535echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
17536echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
17537if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 17538 cat >>confdefs.h <<_ACEOF
503d2be0 17539#define HAVE_LIBCRYPTO 1
c0d27fcc 17540_ACEOF
a21616bd
KR
17541
17542 LIBS="-lcrypto $LIBS"
17543
a21616bd
KR
17544fi
17545
c0d27fcc
MR
17546
17547echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
17548echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
17549if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
17550 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17551else
503d2be0 17552 ac_check_lib_save_LIBS=$LIBS
a21616bd 17553LIBS="-lkrb5 $LIBS"
503d2be0 17554cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17555/* confdefs.h. */
17556_ACEOF
17557cat confdefs.h >>conftest.$ac_ext
17558cat >>conftest.$ac_ext <<_ACEOF
17559/* end confdefs.h. */
a21616bd 17560
503d2be0
AS
17561/* Override any gcc2 internal prototype to avoid an error. */
17562#ifdef __cplusplus
17563extern "C"
17564#endif
17565/* We use char because int might match the return type of a gcc2
17566 builtin and then its argument prototype would still apply. */
17567char krb5_init_context ();
17568int
17569main ()
17570{
17571krb5_init_context ();
17572 ;
17573 return 0;
17574}
17575_ACEOF
17576rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17577if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17578 (eval $ac_link) 2>conftest.er1
503d2be0 17579 ac_status=$?
35996d22
AS
17580 grep -v '^ *+' conftest.er1 >conftest.err
17581 rm -f conftest.er1
17582 cat conftest.err >&5
c0d27fcc 17583 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17584 (exit $ac_status); } &&
4494a266
JD
17585 { ac_try='test -z "$ac_c_werror_flag"
17586 || test ! -s conftest.err'
35996d22
AS
17587 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17588 (eval $ac_try) 2>&5
17589 ac_status=$?
17590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17591 (exit $ac_status); }; } &&
17592 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17593 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17594 (eval $ac_try) 2>&5
17595 ac_status=$?
c0d27fcc 17596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17597 (exit $ac_status); }; }; then
17598 ac_cv_lib_krb5_krb5_init_context=yes
17599else
17600 echo "$as_me: failed program was:" >&5
19650fd6
AS
17601sed 's/^/| /' conftest.$ac_ext >&5
17602
503d2be0
AS
17603ac_cv_lib_krb5_krb5_init_context=no
17604fi
35996d22
AS
17605rm -f conftest.err conftest.$ac_objext \
17606 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17607LIBS=$ac_check_lib_save_LIBS
17608fi
c0d27fcc 17609echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
17610echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
17611if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 17612 cat >>confdefs.h <<_ACEOF
503d2be0 17613#define HAVE_LIBKRB5 1
c0d27fcc 17614_ACEOF
a21616bd
KR
17615
17616 LIBS="-lkrb5 $LIBS"
17617
a21616bd
KR
17618fi
17619
17620 if test "${with_kerberos5+set}" != set; then
503d2be0 17621
c0d27fcc 17622echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
17623echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
17624if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
17625 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17626else
503d2be0 17627 ac_check_lib_save_LIBS=$LIBS
a21616bd 17628LIBS="-ldes425 $LIBS"
503d2be0 17629cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17630/* confdefs.h. */
17631_ACEOF
17632cat confdefs.h >>conftest.$ac_ext
17633cat >>conftest.$ac_ext <<_ACEOF
17634/* end confdefs.h. */
503d2be0 17635
a21616bd 17636/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17637#ifdef __cplusplus
17638extern "C"
17639#endif
a21616bd 17640/* We use char because int might match the return type of a gcc2
503d2be0
AS
17641 builtin and then its argument prototype would still apply. */
17642char des_cbc_encrypt ();
17643int
17644main ()
17645{
17646des_cbc_encrypt ();
17647 ;
17648 return 0;
17649}
17650_ACEOF
17651rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17652if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17653 (eval $ac_link) 2>conftest.er1
503d2be0 17654 ac_status=$?
35996d22
AS
17655 grep -v '^ *+' conftest.er1 >conftest.err
17656 rm -f conftest.er1
17657 cat conftest.err >&5
c0d27fcc 17658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17659 (exit $ac_status); } &&
4494a266
JD
17660 { ac_try='test -z "$ac_c_werror_flag"
17661 || test ! -s conftest.err'
35996d22
AS
17662 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17663 (eval $ac_try) 2>&5
17664 ac_status=$?
17665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17666 (exit $ac_status); }; } &&
17667 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17668 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17669 (eval $ac_try) 2>&5
17670 ac_status=$?
c0d27fcc 17671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17672 (exit $ac_status); }; }; then
17673 ac_cv_lib_des425_des_cbc_encrypt=yes
17674else
17675 echo "$as_me: failed program was:" >&5
19650fd6
AS
17676sed 's/^/| /' conftest.$ac_ext >&5
17677
503d2be0
AS
17678ac_cv_lib_des425_des_cbc_encrypt=no
17679fi
35996d22
AS
17680rm -f conftest.err conftest.$ac_objext \
17681 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17682LIBS=$ac_check_lib_save_LIBS
17683fi
c0d27fcc 17684echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
17685echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
17686if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 17687 cat >>confdefs.h <<_ACEOF
503d2be0 17688#define HAVE_LIBDES425 1
c0d27fcc 17689_ACEOF
a21616bd
KR
17690
17691 LIBS="-ldes425 $LIBS"
17692
17693else
503d2be0 17694
c0d27fcc 17695echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
17696echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
17697if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
17698 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17699else
503d2be0 17700 ac_check_lib_save_LIBS=$LIBS
a21616bd 17701LIBS="-ldes $LIBS"
503d2be0 17702cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17703/* confdefs.h. */
17704_ACEOF
17705cat confdefs.h >>conftest.$ac_ext
17706cat >>conftest.$ac_ext <<_ACEOF
17707/* end confdefs.h. */
503d2be0 17708
a21616bd 17709/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17710#ifdef __cplusplus
17711extern "C"
17712#endif
a21616bd 17713/* We use char because int might match the return type of a gcc2
503d2be0
AS
17714 builtin and then its argument prototype would still apply. */
17715char des_cbc_encrypt ();
17716int
17717main ()
17718{
17719des_cbc_encrypt ();
17720 ;
17721 return 0;
17722}
17723_ACEOF
17724rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17725if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17726 (eval $ac_link) 2>conftest.er1
503d2be0 17727 ac_status=$?
35996d22
AS
17728 grep -v '^ *+' conftest.er1 >conftest.err
17729 rm -f conftest.er1
17730 cat conftest.err >&5
c0d27fcc 17731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17732 (exit $ac_status); } &&
4494a266
JD
17733 { ac_try='test -z "$ac_c_werror_flag"
17734 || test ! -s conftest.err'
35996d22
AS
17735 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17736 (eval $ac_try) 2>&5
17737 ac_status=$?
17738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17739 (exit $ac_status); }; } &&
17740 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17741 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17742 (eval $ac_try) 2>&5
17743 ac_status=$?
c0d27fcc 17744 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17745 (exit $ac_status); }; }; then
17746 ac_cv_lib_des_des_cbc_encrypt=yes
17747else
17748 echo "$as_me: failed program was:" >&5
19650fd6
AS
17749sed 's/^/| /' conftest.$ac_ext >&5
17750
503d2be0
AS
17751ac_cv_lib_des_des_cbc_encrypt=no
17752fi
35996d22
AS
17753rm -f conftest.err conftest.$ac_objext \
17754 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17755LIBS=$ac_check_lib_save_LIBS
17756fi
c0d27fcc 17757echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
17758echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
17759if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 17760 cat >>confdefs.h <<_ACEOF
503d2be0 17761#define HAVE_LIBDES 1
c0d27fcc 17762_ACEOF
a21616bd
KR
17763
17764 LIBS="-ldes $LIBS"
17765
a21616bd
KR
17766fi
17767
17768fi
17769
c0d27fcc
MR
17770
17771echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
17772echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
17773if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
17774 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17775else
503d2be0 17776 ac_check_lib_save_LIBS=$LIBS
a21616bd 17777LIBS="-lkrb4 $LIBS"
503d2be0 17778cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17779/* confdefs.h. */
17780_ACEOF
17781cat confdefs.h >>conftest.$ac_ext
17782cat >>conftest.$ac_ext <<_ACEOF
17783/* end confdefs.h. */
503d2be0 17784
a21616bd 17785/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17786#ifdef __cplusplus
17787extern "C"
17788#endif
a21616bd 17789/* We use char because int might match the return type of a gcc2
503d2be0
AS
17790 builtin and then its argument prototype would still apply. */
17791char krb_get_cred ();
17792int
17793main ()
17794{
17795krb_get_cred ();
17796 ;
17797 return 0;
17798}
17799_ACEOF
17800rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17801if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17802 (eval $ac_link) 2>conftest.er1
503d2be0 17803 ac_status=$?
35996d22
AS
17804 grep -v '^ *+' conftest.er1 >conftest.err
17805 rm -f conftest.er1
17806 cat conftest.err >&5
c0d27fcc 17807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17808 (exit $ac_status); } &&
4494a266
JD
17809 { ac_try='test -z "$ac_c_werror_flag"
17810 || test ! -s conftest.err'
35996d22
AS
17811 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17812 (eval $ac_try) 2>&5
17813 ac_status=$?
17814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17815 (exit $ac_status); }; } &&
17816 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17817 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17818 (eval $ac_try) 2>&5
17819 ac_status=$?
c0d27fcc 17820 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17821 (exit $ac_status); }; }; then
17822 ac_cv_lib_krb4_krb_get_cred=yes
17823else
17824 echo "$as_me: failed program was:" >&5
19650fd6
AS
17825sed 's/^/| /' conftest.$ac_ext >&5
17826
503d2be0
AS
17827ac_cv_lib_krb4_krb_get_cred=no
17828fi
35996d22
AS
17829rm -f conftest.err conftest.$ac_objext \
17830 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17831LIBS=$ac_check_lib_save_LIBS
17832fi
c0d27fcc 17833echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
17834echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
17835if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 17836 cat >>confdefs.h <<_ACEOF
503d2be0 17837#define HAVE_LIBKRB4 1
c0d27fcc 17838_ACEOF
a21616bd
KR
17839
17840 LIBS="-lkrb4 $LIBS"
17841
17842else
503d2be0 17843
c0d27fcc 17844echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
17845echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
17846if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
17847 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 17848else
503d2be0 17849 ac_check_lib_save_LIBS=$LIBS
a21616bd 17850LIBS="-lkrb $LIBS"
503d2be0 17851cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17852/* confdefs.h. */
17853_ACEOF
17854cat confdefs.h >>conftest.$ac_ext
17855cat >>conftest.$ac_ext <<_ACEOF
17856/* end confdefs.h. */
503d2be0 17857
a21616bd 17858/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17859#ifdef __cplusplus
17860extern "C"
17861#endif
a21616bd 17862/* We use char because int might match the return type of a gcc2
503d2be0
AS
17863 builtin and then its argument prototype would still apply. */
17864char krb_get_cred ();
17865int
17866main ()
17867{
17868krb_get_cred ();
17869 ;
17870 return 0;
17871}
17872_ACEOF
17873rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17874if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 17875 (eval $ac_link) 2>conftest.er1
503d2be0 17876 ac_status=$?
35996d22
AS
17877 grep -v '^ *+' conftest.er1 >conftest.err
17878 rm -f conftest.er1
17879 cat conftest.err >&5
c0d27fcc 17880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17881 (exit $ac_status); } &&
4494a266
JD
17882 { ac_try='test -z "$ac_c_werror_flag"
17883 || test ! -s conftest.err'
35996d22
AS
17884 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17885 (eval $ac_try) 2>&5
17886 ac_status=$?
17887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17888 (exit $ac_status); }; } &&
17889 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17890 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17891 (eval $ac_try) 2>&5
17892 ac_status=$?
c0d27fcc 17893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17894 (exit $ac_status); }; }; then
17895 ac_cv_lib_krb_krb_get_cred=yes
17896else
17897 echo "$as_me: failed program was:" >&5
19650fd6
AS
17898sed 's/^/| /' conftest.$ac_ext >&5
17899
503d2be0
AS
17900ac_cv_lib_krb_krb_get_cred=no
17901fi
35996d22
AS
17902rm -f conftest.err conftest.$ac_objext \
17903 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
17904LIBS=$ac_check_lib_save_LIBS
17905fi
c0d27fcc 17906echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
17907echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
17908if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 17909 cat >>confdefs.h <<_ACEOF
503d2be0 17910#define HAVE_LIBKRB 1
c0d27fcc 17911_ACEOF
a21616bd
KR
17912
17913 LIBS="-lkrb $LIBS"
17914
a21616bd
KR
17915fi
17916
17917fi
17918
17919 fi
17920
17921 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
17922
17923for ac_header in krb5.h
a21616bd 17924do
503d2be0 17925as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17926if eval "test \"\${$as_ac_Header+set}\" = set"; then
17927 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17928echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17929if eval "test \"\${$as_ac_Header+set}\" = set"; then
17930 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17931fi
17932echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17933echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17934else
c0d27fcc
MR
17935 # Is the header compilable?
17936echo "$as_me:$LINENO: checking $ac_header usability" >&5
17937echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17938cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17939/* confdefs.h. */
17940_ACEOF
17941cat confdefs.h >>conftest.$ac_ext
17942cat >>conftest.$ac_ext <<_ACEOF
17943/* end confdefs.h. */
c0d27fcc
MR
17944$ac_includes_default
17945#include <$ac_header>
17946_ACEOF
17947rm -f conftest.$ac_objext
17948if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 17949 (eval $ac_compile) 2>conftest.er1
c0d27fcc 17950 ac_status=$?
35996d22
AS
17951 grep -v '^ *+' conftest.er1 >conftest.err
17952 rm -f conftest.er1
17953 cat conftest.err >&5
c0d27fcc
MR
17954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17955 (exit $ac_status); } &&
4494a266
JD
17956 { ac_try='test -z "$ac_c_werror_flag"
17957 || test ! -s conftest.err'
35996d22
AS
17958 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17959 (eval $ac_try) 2>&5
17960 ac_status=$?
17961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17962 (exit $ac_status); }; } &&
17963 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17964 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17965 (eval $ac_try) 2>&5
17966 ac_status=$?
17967 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17968 (exit $ac_status); }; }; then
17969 ac_header_compiler=yes
17970else
17971 echo "$as_me: failed program was:" >&5
19650fd6
AS
17972sed 's/^/| /' conftest.$ac_ext >&5
17973
c0d27fcc
MR
17974ac_header_compiler=no
17975fi
35996d22 17976rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17977echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17978echo "${ECHO_T}$ac_header_compiler" >&6
17979
17980# Is the header present?
17981echo "$as_me:$LINENO: checking $ac_header presence" >&5
17982echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17983cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
17984/* confdefs.h. */
17985_ACEOF
17986cat confdefs.h >>conftest.$ac_ext
17987cat >>conftest.$ac_ext <<_ACEOF
17988/* end confdefs.h. */
503d2be0
AS
17989#include <$ac_header>
17990_ACEOF
c0d27fcc 17991if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17992 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17993 ac_status=$?
6bae0ccf 17994 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17995 rm -f conftest.er1
17996 cat conftest.err >&5
c0d27fcc 17997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17998 (exit $ac_status); } >/dev/null; then
17999 if test -s conftest.err; then
18000 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18001 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18002 else
18003 ac_cpp_err=
18004 fi
18005else
18006 ac_cpp_err=yes
18007fi
18008if test -z "$ac_cpp_err"; then
c0d27fcc 18009 ac_header_preproc=yes
503d2be0
AS
18010else
18011 echo "$as_me: failed program was:" >&5
19650fd6
AS
18012sed 's/^/| /' conftest.$ac_ext >&5
18013
c0d27fcc 18014 ac_header_preproc=no
a21616bd 18015fi
503d2be0 18016rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18017echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18018echo "${ECHO_T}$ac_header_preproc" >&6
18019
18020# So? What about this header?
35996d22
AS
18021case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18022 yes:no: )
c0d27fcc
MR
18023 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18024echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18025 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18026echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18027 ac_header_preproc=yes
19650fd6 18028 ;;
35996d22 18029 no:yes:* )
c0d27fcc
MR
18030 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18031echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18032 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18033echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18034 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18035echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18036 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18037echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18038 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18039echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18040 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18041echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18042 (
18043 cat <<\_ASBOX
35996d22
AS
18044## ------------------------------------------ ##
18045## Report this to the AC_PACKAGE_NAME lists. ##
18046## ------------------------------------------ ##
19650fd6
AS
18047_ASBOX
18048 ) |
18049 sed "s/^/$as_me: WARNING: /" >&2
18050 ;;
c0d27fcc
MR
18051esac
18052echo "$as_me:$LINENO: checking for $ac_header" >&5
18053echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18054if eval "test \"\${$as_ac_Header+set}\" = set"; then
18055 echo $ECHO_N "(cached) $ECHO_C" >&6
18056else
35996d22 18057 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18058fi
c0d27fcc 18059echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18060echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18061
18062fi
503d2be0 18063if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18064 cat >>confdefs.h <<_ACEOF
503d2be0 18065#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18066_ACEOF
503d2be0 18067
a21616bd 18068fi
c0d27fcc 18069
a21616bd
KR
18070done
18071
18072 else
503d2be0
AS
18073
18074for ac_header in des.h
a21616bd 18075do
503d2be0 18076as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18077if eval "test \"\${$as_ac_Header+set}\" = set"; then
18078 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18079echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18080if eval "test \"\${$as_ac_Header+set}\" = set"; then
18081 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18082fi
18083echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18084echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18085else
c0d27fcc
MR
18086 # Is the header compilable?
18087echo "$as_me:$LINENO: checking $ac_header usability" >&5
18088echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18089cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18090/* confdefs.h. */
18091_ACEOF
18092cat confdefs.h >>conftest.$ac_ext
18093cat >>conftest.$ac_ext <<_ACEOF
18094/* end confdefs.h. */
c0d27fcc
MR
18095$ac_includes_default
18096#include <$ac_header>
18097_ACEOF
18098rm -f conftest.$ac_objext
18099if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18100 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18101 ac_status=$?
35996d22
AS
18102 grep -v '^ *+' conftest.er1 >conftest.err
18103 rm -f conftest.er1
18104 cat conftest.err >&5
c0d27fcc
MR
18105 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18106 (exit $ac_status); } &&
4494a266
JD
18107 { ac_try='test -z "$ac_c_werror_flag"
18108 || test ! -s conftest.err'
35996d22
AS
18109 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18110 (eval $ac_try) 2>&5
18111 ac_status=$?
18112 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18113 (exit $ac_status); }; } &&
18114 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18115 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18116 (eval $ac_try) 2>&5
18117 ac_status=$?
18118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18119 (exit $ac_status); }; }; then
18120 ac_header_compiler=yes
18121else
18122 echo "$as_me: failed program was:" >&5
19650fd6
AS
18123sed 's/^/| /' conftest.$ac_ext >&5
18124
c0d27fcc
MR
18125ac_header_compiler=no
18126fi
35996d22 18127rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18128echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18129echo "${ECHO_T}$ac_header_compiler" >&6
18130
18131# Is the header present?
18132echo "$as_me:$LINENO: checking $ac_header presence" >&5
18133echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18134cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18135/* confdefs.h. */
18136_ACEOF
18137cat confdefs.h >>conftest.$ac_ext
18138cat >>conftest.$ac_ext <<_ACEOF
18139/* end confdefs.h. */
503d2be0
AS
18140#include <$ac_header>
18141_ACEOF
c0d27fcc 18142if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18143 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18144 ac_status=$?
6bae0ccf 18145 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18146 rm -f conftest.er1
18147 cat conftest.err >&5
c0d27fcc 18148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18149 (exit $ac_status); } >/dev/null; then
18150 if test -s conftest.err; then
18151 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18152 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18153 else
18154 ac_cpp_err=
18155 fi
18156else
18157 ac_cpp_err=yes
18158fi
18159if test -z "$ac_cpp_err"; then
c0d27fcc 18160 ac_header_preproc=yes
503d2be0
AS
18161else
18162 echo "$as_me: failed program was:" >&5
19650fd6
AS
18163sed 's/^/| /' conftest.$ac_ext >&5
18164
c0d27fcc 18165 ac_header_preproc=no
a21616bd 18166fi
503d2be0 18167rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18168echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18169echo "${ECHO_T}$ac_header_preproc" >&6
18170
18171# So? What about this header?
35996d22
AS
18172case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18173 yes:no: )
c0d27fcc
MR
18174 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18175echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18176 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18177echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18178 ac_header_preproc=yes
19650fd6 18179 ;;
35996d22 18180 no:yes:* )
c0d27fcc
MR
18181 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18182echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18183 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18184echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18185 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18186echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18187 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18188echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18189 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18190echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18191 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18192echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18193 (
18194 cat <<\_ASBOX
35996d22
AS
18195## ------------------------------------------ ##
18196## Report this to the AC_PACKAGE_NAME lists. ##
18197## ------------------------------------------ ##
19650fd6
AS
18198_ASBOX
18199 ) |
18200 sed "s/^/$as_me: WARNING: /" >&2
18201 ;;
c0d27fcc
MR
18202esac
18203echo "$as_me:$LINENO: checking for $ac_header" >&5
18204echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18205if eval "test \"\${$as_ac_Header+set}\" = set"; then
18206 echo $ECHO_N "(cached) $ECHO_C" >&6
18207else
35996d22 18208 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18209fi
c0d27fcc 18210echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18211echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18212
18213fi
503d2be0 18214if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18215 cat >>confdefs.h <<_ACEOF
503d2be0 18216#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18217_ACEOF
503d2be0 18218
a21616bd 18219else
503d2be0
AS
18220
18221for ac_header in kerberosIV/des.h
a21616bd 18222do
503d2be0 18223as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18224if eval "test \"\${$as_ac_Header+set}\" = set"; then
18225 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18226echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18227if eval "test \"\${$as_ac_Header+set}\" = set"; then
18228 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18229fi
18230echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18231echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18232else
c0d27fcc
MR
18233 # Is the header compilable?
18234echo "$as_me:$LINENO: checking $ac_header usability" >&5
18235echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18236cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18237/* confdefs.h. */
18238_ACEOF
18239cat confdefs.h >>conftest.$ac_ext
18240cat >>conftest.$ac_ext <<_ACEOF
18241/* end confdefs.h. */
c0d27fcc
MR
18242$ac_includes_default
18243#include <$ac_header>
18244_ACEOF
18245rm -f conftest.$ac_objext
18246if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18247 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18248 ac_status=$?
35996d22
AS
18249 grep -v '^ *+' conftest.er1 >conftest.err
18250 rm -f conftest.er1
18251 cat conftest.err >&5
c0d27fcc
MR
18252 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18253 (exit $ac_status); } &&
4494a266
JD
18254 { ac_try='test -z "$ac_c_werror_flag"
18255 || test ! -s conftest.err'
35996d22
AS
18256 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18257 (eval $ac_try) 2>&5
18258 ac_status=$?
18259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18260 (exit $ac_status); }; } &&
18261 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18263 (eval $ac_try) 2>&5
18264 ac_status=$?
18265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18266 (exit $ac_status); }; }; then
18267 ac_header_compiler=yes
18268else
18269 echo "$as_me: failed program was:" >&5
19650fd6
AS
18270sed 's/^/| /' conftest.$ac_ext >&5
18271
c0d27fcc
MR
18272ac_header_compiler=no
18273fi
35996d22 18274rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18275echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18276echo "${ECHO_T}$ac_header_compiler" >&6
18277
18278# Is the header present?
18279echo "$as_me:$LINENO: checking $ac_header presence" >&5
18280echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18281cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18282/* confdefs.h. */
18283_ACEOF
18284cat confdefs.h >>conftest.$ac_ext
18285cat >>conftest.$ac_ext <<_ACEOF
18286/* end confdefs.h. */
503d2be0
AS
18287#include <$ac_header>
18288_ACEOF
c0d27fcc 18289if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18290 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18291 ac_status=$?
6bae0ccf 18292 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18293 rm -f conftest.er1
18294 cat conftest.err >&5
c0d27fcc 18295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18296 (exit $ac_status); } >/dev/null; then
18297 if test -s conftest.err; then
18298 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18299 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18300 else
18301 ac_cpp_err=
18302 fi
18303else
18304 ac_cpp_err=yes
18305fi
18306if test -z "$ac_cpp_err"; then
c0d27fcc 18307 ac_header_preproc=yes
503d2be0
AS
18308else
18309 echo "$as_me: failed program was:" >&5
19650fd6
AS
18310sed 's/^/| /' conftest.$ac_ext >&5
18311
c0d27fcc 18312 ac_header_preproc=no
a21616bd 18313fi
503d2be0 18314rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18315echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18316echo "${ECHO_T}$ac_header_preproc" >&6
18317
18318# So? What about this header?
35996d22
AS
18319case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18320 yes:no: )
c0d27fcc
MR
18321 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18322echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18323 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18324echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18325 ac_header_preproc=yes
19650fd6 18326 ;;
35996d22 18327 no:yes:* )
c0d27fcc
MR
18328 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18329echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18330 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18331echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18332 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18333echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18334 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18335echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18336 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18337echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18338 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18339echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18340 (
18341 cat <<\_ASBOX
35996d22
AS
18342## ------------------------------------------ ##
18343## Report this to the AC_PACKAGE_NAME lists. ##
18344## ------------------------------------------ ##
19650fd6
AS
18345_ASBOX
18346 ) |
18347 sed "s/^/$as_me: WARNING: /" >&2
18348 ;;
c0d27fcc
MR
18349esac
18350echo "$as_me:$LINENO: checking for $ac_header" >&5
18351echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18352if eval "test \"\${$as_ac_Header+set}\" = set"; then
18353 echo $ECHO_N "(cached) $ECHO_C" >&6
18354else
35996d22 18355 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18356fi
c0d27fcc 18357echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18358echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18359
18360fi
503d2be0 18361if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18362 cat >>confdefs.h <<_ACEOF
503d2be0 18363#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18364_ACEOF
503d2be0 18365
a21616bd 18366else
503d2be0
AS
18367
18368for ac_header in kerberos/des.h
a21616bd 18369do
503d2be0 18370as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18371if eval "test \"\${$as_ac_Header+set}\" = set"; then
18372 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18373echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18374if eval "test \"\${$as_ac_Header+set}\" = set"; then
18375 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18376fi
18377echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18378echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18379else
c0d27fcc
MR
18380 # Is the header compilable?
18381echo "$as_me:$LINENO: checking $ac_header usability" >&5
18382echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18383cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18384/* confdefs.h. */
18385_ACEOF
18386cat confdefs.h >>conftest.$ac_ext
18387cat >>conftest.$ac_ext <<_ACEOF
18388/* end confdefs.h. */
c0d27fcc
MR
18389$ac_includes_default
18390#include <$ac_header>
18391_ACEOF
18392rm -f conftest.$ac_objext
18393if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18394 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18395 ac_status=$?
35996d22
AS
18396 grep -v '^ *+' conftest.er1 >conftest.err
18397 rm -f conftest.er1
18398 cat conftest.err >&5
c0d27fcc
MR
18399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18400 (exit $ac_status); } &&
4494a266
JD
18401 { ac_try='test -z "$ac_c_werror_flag"
18402 || test ! -s conftest.err'
35996d22
AS
18403 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18404 (eval $ac_try) 2>&5
18405 ac_status=$?
18406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18407 (exit $ac_status); }; } &&
18408 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18409 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18410 (eval $ac_try) 2>&5
18411 ac_status=$?
18412 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18413 (exit $ac_status); }; }; then
18414 ac_header_compiler=yes
18415else
18416 echo "$as_me: failed program was:" >&5
19650fd6
AS
18417sed 's/^/| /' conftest.$ac_ext >&5
18418
c0d27fcc
MR
18419ac_header_compiler=no
18420fi
35996d22 18421rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18422echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18423echo "${ECHO_T}$ac_header_compiler" >&6
18424
18425# Is the header present?
18426echo "$as_me:$LINENO: checking $ac_header presence" >&5
18427echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18428cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18429/* confdefs.h. */
18430_ACEOF
18431cat confdefs.h >>conftest.$ac_ext
18432cat >>conftest.$ac_ext <<_ACEOF
18433/* end confdefs.h. */
503d2be0
AS
18434#include <$ac_header>
18435_ACEOF
c0d27fcc 18436if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18437 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18438 ac_status=$?
6bae0ccf 18439 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18440 rm -f conftest.er1
18441 cat conftest.err >&5
c0d27fcc 18442 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18443 (exit $ac_status); } >/dev/null; then
18444 if test -s conftest.err; then
18445 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18446 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18447 else
18448 ac_cpp_err=
18449 fi
18450else
18451 ac_cpp_err=yes
18452fi
18453if test -z "$ac_cpp_err"; then
c0d27fcc 18454 ac_header_preproc=yes
503d2be0
AS
18455else
18456 echo "$as_me: failed program was:" >&5
19650fd6
AS
18457sed 's/^/| /' conftest.$ac_ext >&5
18458
c0d27fcc 18459 ac_header_preproc=no
a21616bd 18460fi
503d2be0 18461rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18462echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18463echo "${ECHO_T}$ac_header_preproc" >&6
18464
18465# So? What about this header?
35996d22
AS
18466case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18467 yes:no: )
c0d27fcc
MR
18468 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18469echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18470 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18471echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18472 ac_header_preproc=yes
19650fd6 18473 ;;
35996d22 18474 no:yes:* )
c0d27fcc
MR
18475 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18476echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18477 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18478echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18479 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18480echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18481 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18482echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18483 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18484echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18485 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18486echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18487 (
18488 cat <<\_ASBOX
35996d22
AS
18489## ------------------------------------------ ##
18490## Report this to the AC_PACKAGE_NAME lists. ##
18491## ------------------------------------------ ##
19650fd6
AS
18492_ASBOX
18493 ) |
18494 sed "s/^/$as_me: WARNING: /" >&2
18495 ;;
c0d27fcc
MR
18496esac
18497echo "$as_me:$LINENO: checking for $ac_header" >&5
18498echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18499if eval "test \"\${$as_ac_Header+set}\" = set"; then
18500 echo $ECHO_N "(cached) $ECHO_C" >&6
18501else
35996d22 18502 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18503fi
c0d27fcc 18504echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18505echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18506
18507fi
503d2be0 18508if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18509 cat >>confdefs.h <<_ACEOF
503d2be0 18510#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18511_ACEOF
a21616bd
KR
18512
18513fi
c0d27fcc 18514
a21616bd
KR
18515done
18516
98418dba 18517fi
c0d27fcc 18518
925c2f3f
EZ
18519done
18520
98418dba 18521fi
c0d27fcc 18522
925c2f3f 18523done
98418dba 18524
c0d27fcc 18525
925c2f3f
EZ
18526for ac_header in krb.h
18527do
18528as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18529if eval "test \"\${$as_ac_Header+set}\" = set"; then
18530 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
18531echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18532if eval "test \"\${$as_ac_Header+set}\" = set"; then
18533 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18534fi
18535echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18536echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
18537else
18538 # Is the header compilable?
18539echo "$as_me:$LINENO: checking $ac_header usability" >&5
18540echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18541cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18542/* confdefs.h. */
18543_ACEOF
18544cat confdefs.h >>conftest.$ac_ext
18545cat >>conftest.$ac_ext <<_ACEOF
18546/* end confdefs.h. */
c0d27fcc
MR
18547$ac_includes_default
18548#include <$ac_header>
18549_ACEOF
18550rm -f conftest.$ac_objext
18551if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18552 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18553 ac_status=$?
35996d22
AS
18554 grep -v '^ *+' conftest.er1 >conftest.err
18555 rm -f conftest.er1
18556 cat conftest.err >&5
c0d27fcc
MR
18557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18558 (exit $ac_status); } &&
4494a266
JD
18559 { ac_try='test -z "$ac_c_werror_flag"
18560 || test ! -s conftest.err'
35996d22
AS
18561 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18562 (eval $ac_try) 2>&5
18563 ac_status=$?
18564 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18565 (exit $ac_status); }; } &&
18566 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18567 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18568 (eval $ac_try) 2>&5
18569 ac_status=$?
18570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18571 (exit $ac_status); }; }; then
18572 ac_header_compiler=yes
925c2f3f 18573else
c0d27fcc 18574 echo "$as_me: failed program was:" >&5
19650fd6
AS
18575sed 's/^/| /' conftest.$ac_ext >&5
18576
c0d27fcc
MR
18577ac_header_compiler=no
18578fi
35996d22 18579rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18580echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18581echo "${ECHO_T}$ac_header_compiler" >&6
18582
18583# Is the header present?
18584echo "$as_me:$LINENO: checking $ac_header presence" >&5
18585echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18586cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18587/* confdefs.h. */
18588_ACEOF
18589cat confdefs.h >>conftest.$ac_ext
18590cat >>conftest.$ac_ext <<_ACEOF
18591/* end confdefs.h. */
503d2be0
AS
18592#include <$ac_header>
18593_ACEOF
c0d27fcc 18594if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18595 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18596 ac_status=$?
6bae0ccf 18597 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18598 rm -f conftest.er1
18599 cat conftest.err >&5
c0d27fcc 18600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18601 (exit $ac_status); } >/dev/null; then
18602 if test -s conftest.err; then
18603 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18604 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18605 else
18606 ac_cpp_err=
18607 fi
18608else
18609 ac_cpp_err=yes
18610fi
18611if test -z "$ac_cpp_err"; then
c0d27fcc 18612 ac_header_preproc=yes
503d2be0
AS
18613else
18614 echo "$as_me: failed program was:" >&5
19650fd6
AS
18615sed 's/^/| /' conftest.$ac_ext >&5
18616
c0d27fcc 18617 ac_header_preproc=no
a21616bd 18618fi
503d2be0 18619rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18620echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18621echo "${ECHO_T}$ac_header_preproc" >&6
18622
18623# So? What about this header?
35996d22
AS
18624case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18625 yes:no: )
c0d27fcc
MR
18626 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18627echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18628 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18629echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18630 ac_header_preproc=yes
19650fd6 18631 ;;
35996d22 18632 no:yes:* )
c0d27fcc
MR
18633 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18634echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18635 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18636echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18637 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18638echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18639 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18640echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18641 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18642echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18643 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18644echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18645 (
18646 cat <<\_ASBOX
35996d22
AS
18647## ------------------------------------------ ##
18648## Report this to the AC_PACKAGE_NAME lists. ##
18649## ------------------------------------------ ##
19650fd6
AS
18650_ASBOX
18651 ) |
18652 sed "s/^/$as_me: WARNING: /" >&2
18653 ;;
c0d27fcc
MR
18654esac
18655echo "$as_me:$LINENO: checking for $ac_header" >&5
18656echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18657if eval "test \"\${$as_ac_Header+set}\" = set"; then
18658 echo $ECHO_N "(cached) $ECHO_C" >&6
18659else
35996d22 18660 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18661fi
c0d27fcc 18662echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18663echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18664
18665fi
503d2be0 18666if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18667 cat >>confdefs.h <<_ACEOF
503d2be0 18668#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18669_ACEOF
503d2be0 18670
a21616bd 18671else
503d2be0
AS
18672
18673for ac_header in kerberosIV/krb.h
a21616bd 18674do
503d2be0 18675as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18676if eval "test \"\${$as_ac_Header+set}\" = set"; then
18677 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18678echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18679if eval "test \"\${$as_ac_Header+set}\" = set"; then
18680 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18681fi
18682echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18683echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18684else
c0d27fcc
MR
18685 # Is the header compilable?
18686echo "$as_me:$LINENO: checking $ac_header usability" >&5
18687echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18688cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18689/* confdefs.h. */
18690_ACEOF
18691cat confdefs.h >>conftest.$ac_ext
18692cat >>conftest.$ac_ext <<_ACEOF
18693/* end confdefs.h. */
c0d27fcc
MR
18694$ac_includes_default
18695#include <$ac_header>
18696_ACEOF
18697rm -f conftest.$ac_objext
18698if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18699 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18700 ac_status=$?
35996d22
AS
18701 grep -v '^ *+' conftest.er1 >conftest.err
18702 rm -f conftest.er1
18703 cat conftest.err >&5
c0d27fcc
MR
18704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18705 (exit $ac_status); } &&
4494a266
JD
18706 { ac_try='test -z "$ac_c_werror_flag"
18707 || test ! -s conftest.err'
35996d22
AS
18708 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18709 (eval $ac_try) 2>&5
18710 ac_status=$?
18711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18712 (exit $ac_status); }; } &&
18713 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18715 (eval $ac_try) 2>&5
18716 ac_status=$?
18717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18718 (exit $ac_status); }; }; then
18719 ac_header_compiler=yes
18720else
18721 echo "$as_me: failed program was:" >&5
19650fd6
AS
18722sed 's/^/| /' conftest.$ac_ext >&5
18723
c0d27fcc
MR
18724ac_header_compiler=no
18725fi
35996d22 18726rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18727echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18728echo "${ECHO_T}$ac_header_compiler" >&6
18729
18730# Is the header present?
18731echo "$as_me:$LINENO: checking $ac_header presence" >&5
18732echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18733cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18734/* confdefs.h. */
18735_ACEOF
18736cat confdefs.h >>conftest.$ac_ext
18737cat >>conftest.$ac_ext <<_ACEOF
18738/* end confdefs.h. */
503d2be0
AS
18739#include <$ac_header>
18740_ACEOF
c0d27fcc 18741if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18742 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18743 ac_status=$?
6bae0ccf 18744 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18745 rm -f conftest.er1
18746 cat conftest.err >&5
c0d27fcc 18747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18748 (exit $ac_status); } >/dev/null; then
18749 if test -s conftest.err; then
18750 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18751 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18752 else
18753 ac_cpp_err=
18754 fi
18755else
18756 ac_cpp_err=yes
18757fi
18758if test -z "$ac_cpp_err"; then
c0d27fcc 18759 ac_header_preproc=yes
503d2be0
AS
18760else
18761 echo "$as_me: failed program was:" >&5
19650fd6
AS
18762sed 's/^/| /' conftest.$ac_ext >&5
18763
c0d27fcc 18764 ac_header_preproc=no
a21616bd 18765fi
503d2be0 18766rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18767echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18768echo "${ECHO_T}$ac_header_preproc" >&6
18769
18770# So? What about this header?
35996d22
AS
18771case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18772 yes:no: )
c0d27fcc
MR
18773 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18774echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
18775 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18776echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18777 ac_header_preproc=yes
19650fd6 18778 ;;
35996d22 18779 no:yes:* )
c0d27fcc
MR
18780 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18781echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18782 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18783echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18784 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18785echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18786 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18787echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18788 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18789echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18790 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18791echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18792 (
18793 cat <<\_ASBOX
35996d22
AS
18794## ------------------------------------------ ##
18795## Report this to the AC_PACKAGE_NAME lists. ##
18796## ------------------------------------------ ##
19650fd6
AS
18797_ASBOX
18798 ) |
18799 sed "s/^/$as_me: WARNING: /" >&2
18800 ;;
c0d27fcc
MR
18801esac
18802echo "$as_me:$LINENO: checking for $ac_header" >&5
18803echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18804if eval "test \"\${$as_ac_Header+set}\" = set"; then
18805 echo $ECHO_N "(cached) $ECHO_C" >&6
18806else
35996d22 18807 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18808fi
c0d27fcc 18809echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18810echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18811
18812fi
503d2be0 18813if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18814 cat >>confdefs.h <<_ACEOF
503d2be0 18815#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18816_ACEOF
503d2be0 18817
a21616bd 18818else
503d2be0
AS
18819
18820for ac_header in kerberos/krb.h
a21616bd 18821do
503d2be0 18822as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18823if eval "test \"\${$as_ac_Header+set}\" = set"; then
18824 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18825echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18826if eval "test \"\${$as_ac_Header+set}\" = set"; then
18827 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18828fi
18829echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18830echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18831else
c0d27fcc
MR
18832 # Is the header compilable?
18833echo "$as_me:$LINENO: checking $ac_header usability" >&5
18834echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18835cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18836/* confdefs.h. */
18837_ACEOF
18838cat confdefs.h >>conftest.$ac_ext
18839cat >>conftest.$ac_ext <<_ACEOF
18840/* end confdefs.h. */
c0d27fcc
MR
18841$ac_includes_default
18842#include <$ac_header>
18843_ACEOF
18844rm -f conftest.$ac_objext
18845if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 18846 (eval $ac_compile) 2>conftest.er1
c0d27fcc 18847 ac_status=$?
35996d22
AS
18848 grep -v '^ *+' conftest.er1 >conftest.err
18849 rm -f conftest.er1
18850 cat conftest.err >&5
c0d27fcc
MR
18851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18852 (exit $ac_status); } &&
4494a266
JD
18853 { ac_try='test -z "$ac_c_werror_flag"
18854 || test ! -s conftest.err'
35996d22
AS
18855 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18856 (eval $ac_try) 2>&5
18857 ac_status=$?
18858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18859 (exit $ac_status); }; } &&
18860 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18861 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18862 (eval $ac_try) 2>&5
18863 ac_status=$?
18864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18865 (exit $ac_status); }; }; then
18866 ac_header_compiler=yes
18867else
18868 echo "$as_me: failed program was:" >&5
19650fd6
AS
18869sed 's/^/| /' conftest.$ac_ext >&5
18870
c0d27fcc
MR
18871ac_header_compiler=no
18872fi
35996d22 18873rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18874echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18875echo "${ECHO_T}$ac_header_compiler" >&6
18876
18877# Is the header present?
18878echo "$as_me:$LINENO: checking $ac_header presence" >&5
18879echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18880cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18881/* confdefs.h. */
18882_ACEOF
18883cat confdefs.h >>conftest.$ac_ext
18884cat >>conftest.$ac_ext <<_ACEOF
18885/* end confdefs.h. */
503d2be0
AS
18886#include <$ac_header>
18887_ACEOF
c0d27fcc 18888if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18889 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18890 ac_status=$?
6bae0ccf 18891 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18892 rm -f conftest.er1
18893 cat conftest.err >&5
c0d27fcc 18894 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18895 (exit $ac_status); } >/dev/null; then
18896 if test -s conftest.err; then
18897 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 18898 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
18899 else
18900 ac_cpp_err=
18901 fi
18902else
18903 ac_cpp_err=yes
18904fi
18905if test -z "$ac_cpp_err"; then
c0d27fcc 18906 ac_header_preproc=yes
503d2be0
AS
18907else
18908 echo "$as_me: failed program was:" >&5
19650fd6
AS
18909sed 's/^/| /' conftest.$ac_ext >&5
18910
c0d27fcc 18911 ac_header_preproc=no
a21616bd 18912fi
503d2be0 18913rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18914echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18915echo "${ECHO_T}$ac_header_preproc" >&6
35996d22
AS
18916
18917# So? What about this header?
18918case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18919 yes:no: )
18920 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18921echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
18922 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
18923echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
18924 ac_header_preproc=yes
19650fd6 18925 ;;
35996d22 18926 no:yes:* )
c0d27fcc
MR
18927 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18928echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
18929 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18930echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
18931 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
18932echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
18933 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
18934echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 18935 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18936echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
18937 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
18938echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
18939 (
18940 cat <<\_ASBOX
35996d22
AS
18941## ------------------------------------------ ##
18942## Report this to the AC_PACKAGE_NAME lists. ##
18943## ------------------------------------------ ##
19650fd6
AS
18944_ASBOX
18945 ) |
18946 sed "s/^/$as_me: WARNING: /" >&2
18947 ;;
c0d27fcc
MR
18948esac
18949echo "$as_me:$LINENO: checking for $ac_header" >&5
18950echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18951if eval "test \"\${$as_ac_Header+set}\" = set"; then
18952 echo $ECHO_N "(cached) $ECHO_C" >&6
18953else
35996d22 18954 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 18955fi
c0d27fcc 18956echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18957echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18958
18959fi
503d2be0 18960if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18961 cat >>confdefs.h <<_ACEOF
503d2be0 18962#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18963_ACEOF
503d2be0 18964
a21616bd 18965fi
c0d27fcc 18966
a21616bd
KR
18967done
18968
18969fi
c0d27fcc 18970
a21616bd
KR
18971done
18972
18973fi
c0d27fcc 18974
a21616bd
KR
18975done
18976
18977 fi
503d2be0
AS
18978
18979for ac_header in com_err.h
a21616bd 18980do
503d2be0 18981as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
18982if eval "test \"\${$as_ac_Header+set}\" = set"; then
18983 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
18984echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
18985if eval "test \"\${$as_ac_Header+set}\" = set"; then
18986 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18987fi
18988echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
18989echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 18990else
c0d27fcc
MR
18991 # Is the header compilable?
18992echo "$as_me:$LINENO: checking $ac_header usability" >&5
18993echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
18994cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
18995/* confdefs.h. */
18996_ACEOF
18997cat confdefs.h >>conftest.$ac_ext
18998cat >>conftest.$ac_ext <<_ACEOF
18999/* end confdefs.h. */
c0d27fcc
MR
19000$ac_includes_default
19001#include <$ac_header>
19002_ACEOF
19003rm -f conftest.$ac_objext
19004if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19005 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19006 ac_status=$?
35996d22
AS
19007 grep -v '^ *+' conftest.er1 >conftest.err
19008 rm -f conftest.er1
19009 cat conftest.err >&5
c0d27fcc
MR
19010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19011 (exit $ac_status); } &&
4494a266
JD
19012 { ac_try='test -z "$ac_c_werror_flag"
19013 || test ! -s conftest.err'
35996d22
AS
19014 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19015 (eval $ac_try) 2>&5
19016 ac_status=$?
19017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19018 (exit $ac_status); }; } &&
19019 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19020 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19021 (eval $ac_try) 2>&5
19022 ac_status=$?
19023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19024 (exit $ac_status); }; }; then
19025 ac_header_compiler=yes
19026else
19027 echo "$as_me: failed program was:" >&5
19650fd6
AS
19028sed 's/^/| /' conftest.$ac_ext >&5
19029
c0d27fcc
MR
19030ac_header_compiler=no
19031fi
35996d22 19032rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19033echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19034echo "${ECHO_T}$ac_header_compiler" >&6
19035
19036# Is the header present?
19037echo "$as_me:$LINENO: checking $ac_header presence" >&5
19038echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19039cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19040/* confdefs.h. */
19041_ACEOF
19042cat confdefs.h >>conftest.$ac_ext
19043cat >>conftest.$ac_ext <<_ACEOF
19044/* end confdefs.h. */
503d2be0
AS
19045#include <$ac_header>
19046_ACEOF
c0d27fcc 19047if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19048 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19049 ac_status=$?
6bae0ccf 19050 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19051 rm -f conftest.er1
19052 cat conftest.err >&5
c0d27fcc 19053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19054 (exit $ac_status); } >/dev/null; then
19055 if test -s conftest.err; then
19056 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19057 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19058 else
19059 ac_cpp_err=
19060 fi
19061else
19062 ac_cpp_err=yes
19063fi
19064if test -z "$ac_cpp_err"; then
c0d27fcc 19065 ac_header_preproc=yes
503d2be0
AS
19066else
19067 echo "$as_me: failed program was:" >&5
19650fd6
AS
19068sed 's/^/| /' conftest.$ac_ext >&5
19069
c0d27fcc 19070 ac_header_preproc=no
a21616bd 19071fi
503d2be0 19072rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19073echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19074echo "${ECHO_T}$ac_header_preproc" >&6
19075
19076# So? What about this header?
35996d22
AS
19077case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19078 yes:no: )
c0d27fcc
MR
19079 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19080echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19081 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
19082echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
19083 ac_header_preproc=yes
19650fd6 19084 ;;
35996d22 19085 no:yes:* )
c0d27fcc
MR
19086 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19087echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
19088 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19089echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
19090 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
19091echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
19092 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
19093echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19094 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19095echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19096 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
19097echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19098 (
19099 cat <<\_ASBOX
35996d22
AS
19100## ------------------------------------------ ##
19101## Report this to the AC_PACKAGE_NAME lists. ##
19102## ------------------------------------------ ##
19650fd6
AS
19103_ASBOX
19104 ) |
19105 sed "s/^/$as_me: WARNING: /" >&2
19106 ;;
c0d27fcc
MR
19107esac
19108echo "$as_me:$LINENO: checking for $ac_header" >&5
19109echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19110if eval "test \"\${$as_ac_Header+set}\" = set"; then
19111 echo $ECHO_N "(cached) $ECHO_C" >&6
19112else
35996d22 19113 eval "$as_ac_Header=\$ac_header_preproc"
a21616bd 19114fi
c0d27fcc 19115echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19116echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19117
19118fi
503d2be0 19119if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19120 cat >>confdefs.h <<_ACEOF
503d2be0 19121#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19122_ACEOF
503d2be0 19123
a21616bd 19124fi
c0d27fcc 19125
a21616bd
KR
19126done
19127
19128fi
19129
ba4481b5
DL
19130# Solaris requires -lintl if you want strerror (which calls dgettext)
19131# to return localized messages.
503d2be0 19132
c0d27fcc 19133echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
19134echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
19135if test "${ac_cv_lib_intl_dgettext+set}" = set; then
19136 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19137else
503d2be0 19138 ac_check_lib_save_LIBS=$LIBS
ba4481b5 19139LIBS="-lintl $LIBS"
503d2be0 19140cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19141/* confdefs.h. */
19142_ACEOF
19143cat confdefs.h >>conftest.$ac_ext
19144cat >>conftest.$ac_ext <<_ACEOF
19145/* end confdefs.h. */
503d2be0 19146
ba4481b5 19147/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19148#ifdef __cplusplus
19149extern "C"
19150#endif
ba4481b5 19151/* We use char because int might match the return type of a gcc2
503d2be0
AS
19152 builtin and then its argument prototype would still apply. */
19153char dgettext ();
19154int
19155main ()
19156{
19157dgettext ();
19158 ;
19159 return 0;
19160}
19161_ACEOF
19162rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19163if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19164 (eval $ac_link) 2>conftest.er1
503d2be0 19165 ac_status=$?
35996d22
AS
19166 grep -v '^ *+' conftest.er1 >conftest.err
19167 rm -f conftest.er1
19168 cat conftest.err >&5
c0d27fcc 19169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19170 (exit $ac_status); } &&
4494a266
JD
19171 { ac_try='test -z "$ac_c_werror_flag"
19172 || test ! -s conftest.err'
35996d22
AS
19173 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19174 (eval $ac_try) 2>&5
19175 ac_status=$?
19176 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19177 (exit $ac_status); }; } &&
19178 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19179 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19180 (eval $ac_try) 2>&5
19181 ac_status=$?
c0d27fcc 19182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19183 (exit $ac_status); }; }; then
19184 ac_cv_lib_intl_dgettext=yes
19185else
19186 echo "$as_me: failed program was:" >&5
19650fd6
AS
19187sed 's/^/| /' conftest.$ac_ext >&5
19188
503d2be0
AS
19189ac_cv_lib_intl_dgettext=no
19190fi
35996d22
AS
19191rm -f conftest.err conftest.$ac_objext \
19192 conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
19193LIBS=$ac_check_lib_save_LIBS
19194fi
c0d27fcc 19195echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
19196echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
19197if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 19198 cat >>confdefs.h <<_ACEOF
503d2be0 19199#define HAVE_LIBINTL 1
c0d27fcc 19200_ACEOF
ba4481b5
DL
19201
19202 LIBS="-lintl $LIBS"
19203
ba4481b5
DL
19204fi
19205
c0d27fcc
MR
19206
19207echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
19208echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
19209if test "${emacs_cv_localtime_cache+set}" = set; then
19210 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
19211else
19212 if test x$ac_cv_func_tzset = xyes; then
19213if test "$cross_compiling" = yes; then
19214 # If we have tzset, assume the worst when cross-compiling.
19215emacs_cv_localtime_cache=yes
19216else
503d2be0 19217 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19218/* confdefs.h. */
19219_ACEOF
19220cat confdefs.h >>conftest.$ac_ext
19221cat >>conftest.$ac_ext <<_ACEOF
19222/* end confdefs.h. */
ba4481b5 19223#include <time.h>
ba4481b5
DL
19224extern char **environ;
19225unset_TZ ()
19226{
19227 char **from, **to;
19228 for (to = from = environ; (*to = *from); from++)
19229 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
19230 to++;
19231}
19232char TZ_GMT0[] = "TZ=GMT0";
19233char TZ_PST8[] = "TZ=PST8";
19234main()
19235{
19236 time_t now = time ((time_t *) 0);
19237 int hour_GMT0, hour_unset;
19238 if (putenv (TZ_GMT0) != 0)
19239 exit (1);
19240 hour_GMT0 = localtime (&now)->tm_hour;
19241 unset_TZ ();
19242 hour_unset = localtime (&now)->tm_hour;
19243 if (putenv (TZ_PST8) != 0)
19244 exit (1);
19245 if (localtime (&now)->tm_hour == hour_GMT0)
19246 exit (1);
19247 unset_TZ ();
19248 if (localtime (&now)->tm_hour != hour_unset)
19249 exit (1);
19250 exit (0);
19251}
503d2be0
AS
19252_ACEOF
19253rm -f conftest$ac_exeext
c0d27fcc 19254if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19255 (eval $ac_link) 2>&5
19256 ac_status=$?
c0d27fcc 19257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19258 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19259 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19260 (eval $ac_try) 2>&5
19261 ac_status=$?
c0d27fcc 19262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19263 (exit $ac_status); }; }; then
ba4481b5
DL
19264 emacs_cv_localtime_cache=no
19265else
503d2be0
AS
19266 echo "$as_me: program exited with status $ac_status" >&5
19267echo "$as_me: failed program was:" >&5
19650fd6
AS
19268sed 's/^/| /' conftest.$ac_ext >&5
19269
c0d27fcc 19270( exit $ac_status )
503d2be0 19271emacs_cv_localtime_cache=yes
ba4481b5 19272fi
35996d22 19273rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 19274fi
ba4481b5
DL
19275else
19276 # If we lack tzset, report that localtime does not cache TZ,
19277 # since we can't invalidate the cache if we don't have tzset.
19278 emacs_cv_localtime_cache=no
19279fi
19280fi
c0d27fcc 19281echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 19282echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 19283if test $emacs_cv_localtime_cache = yes; then
b936fae4 19284
c0d27fcc 19285cat >>confdefs.h <<\_ACEOF
ba4481b5 19286#define LOCALTIME_CACHE 1
c0d27fcc 19287_ACEOF
ba4481b5
DL
19288
19289fi
19290
19291if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
19292
19293for ac_func in gettimeofday
48d4b120 19294do
503d2be0 19295as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 19296echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
19297echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19298if eval "test \"\${$as_ac_var+set}\" = set"; then
19299 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19300else
503d2be0 19301 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19302/* confdefs.h. */
19303_ACEOF
19304cat confdefs.h >>conftest.$ac_ext
19305cat >>conftest.$ac_ext <<_ACEOF
19306/* end confdefs.h. */
35996d22
AS
19307/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19308 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19309#define $ac_func innocuous_$ac_func
19310
48d4b120 19311/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19312 which can conflict with char $ac_func (); below.
19313 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19314 <limits.h> exists even on freestanding compilers. */
35996d22 19315
19650fd6
AS
19316#ifdef __STDC__
19317# include <limits.h>
19318#else
19319# include <assert.h>
19320#endif
35996d22
AS
19321
19322#undef $ac_func
19323
48d4b120 19324/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19325#ifdef __cplusplus
19326extern "C"
19650fd6 19327{
503d2be0 19328#endif
48d4b120 19329/* We use char because int might match the return type of a gcc2
503d2be0
AS
19330 builtin and then its argument prototype would still apply. */
19331char $ac_func ();
48d4b120
DL
19332/* The GNU C library defines this for functions which it implements
19333 to always fail with ENOSYS. Some functions are actually named
19334 something starting with __ and the normal name is an alias. */
19335#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
19336choke me
19337#else
19650fd6
AS
19338char (*f) () = $ac_func;
19339#endif
19340#ifdef __cplusplus
19341}
cd958eb3
MB
19342#endif
19343
19650fd6
AS
19344int
19345main ()
19346{
19347return f != $ac_func;
503d2be0
AS
19348 ;
19349 return 0;
19350}
19351_ACEOF
19352rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19353if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19354 (eval $ac_link) 2>conftest.er1
503d2be0 19355 ac_status=$?
35996d22
AS
19356 grep -v '^ *+' conftest.er1 >conftest.err
19357 rm -f conftest.er1
19358 cat conftest.err >&5
c0d27fcc 19359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19360 (exit $ac_status); } &&
4494a266
JD
19361 { ac_try='test -z "$ac_c_werror_flag"
19362 || test ! -s conftest.err'
35996d22
AS
19363 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19364 (eval $ac_try) 2>&5
19365 ac_status=$?
19366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19367 (exit $ac_status); }; } &&
19368 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19369 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19370 (eval $ac_try) 2>&5
19371 ac_status=$?
c0d27fcc 19372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19373 (exit $ac_status); }; }; then
19374 eval "$as_ac_var=yes"
19375else
19376 echo "$as_me: failed program was:" >&5
19650fd6
AS
19377sed 's/^/| /' conftest.$ac_ext >&5
19378
503d2be0
AS
19379eval "$as_ac_var=no"
19380fi
35996d22
AS
19381rm -f conftest.err conftest.$ac_objext \
19382 conftest$ac_exeext conftest.$ac_ext
503d2be0 19383fi
c0d27fcc 19384echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
19385echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19386if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 19387 cat >>confdefs.h <<_ACEOF
503d2be0 19388#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 19389_ACEOF
48d4b120 19390
48d4b120
DL
19391fi
19392done
19393
b936fae4 19394 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 19395 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
19396echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
19397if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
19398 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19399else
503d2be0 19400 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19401/* confdefs.h. */
19402_ACEOF
19403cat confdefs.h >>conftest.$ac_ext
19404cat >>conftest.$ac_ext <<_ACEOF
19405/* end confdefs.h. */
ba4481b5 19406
a3f08d9e
DL
19407#ifdef TIME_WITH_SYS_TIME
19408#include <sys/time.h>
19409#include <time.h>
19410#else
19411#ifdef HAVE_SYS_TIME_H
19412#include <sys/time.h>
19413#else
19414#include <time.h>
19415#endif
19416#endif
503d2be0
AS
19417int
19418main ()
19419{
a3f08d9e 19420struct timeval time;
b936fae4 19421 gettimeofday (&time, 0);
503d2be0
AS
19422 ;
19423 return 0;
19424}
19425_ACEOF
19426rm -f conftest.$ac_objext
c0d27fcc 19427if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19428 (eval $ac_compile) 2>conftest.er1
503d2be0 19429 ac_status=$?
35996d22
AS
19430 grep -v '^ *+' conftest.er1 >conftest.err
19431 rm -f conftest.er1
19432 cat conftest.err >&5
c0d27fcc 19433 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19434 (exit $ac_status); } &&
4494a266
JD
19435 { ac_try='test -z "$ac_c_werror_flag"
19436 || test ! -s conftest.err'
35996d22
AS
19437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19438 (eval $ac_try) 2>&5
19439 ac_status=$?
19440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19441 (exit $ac_status); }; } &&
19442 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19443 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19444 (eval $ac_try) 2>&5
19445 ac_status=$?
c0d27fcc 19446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19447 (exit $ac_status); }; }; then
ba4481b5
DL
19448 emacs_cv_gettimeofday_two_arguments=yes
19449else
503d2be0 19450 echo "$as_me: failed program was:" >&5
19650fd6
AS
19451sed 's/^/| /' conftest.$ac_ext >&5
19452
503d2be0 19453emacs_cv_gettimeofday_two_arguments=no
ba4481b5 19454fi
35996d22 19455rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 19456fi
c0d27fcc 19457echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 19458echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
19459 if test $emacs_cv_gettimeofday_two_arguments = no; then
19460
c0d27fcc 19461cat >>confdefs.h <<\_ACEOF
ba4481b5 19462#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 19463_ACEOF
ba4481b5 19464
b936fae4 19465 fi
ba4481b5
DL
19466 fi
19467fi
19468
973a76b1
DL
19469# This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
19470echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
19471echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
19472if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
19473 echo $ECHO_N "(cached) $ECHO_C" >&6
19474else
19475 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19476/* confdefs.h. */
19477_ACEOF
19478cat confdefs.h >>conftest.$ac_ext
19479cat >>conftest.$ac_ext <<_ACEOF
19480/* end confdefs.h. */
973a76b1
DL
19481#include <sys/types.h>
19482#include <$ac_cv_struct_tm>
19483
19484
19485int
19486main ()
19487{
19488static struct tm ac_aggr;
19489if (ac_aggr.tm_zone)
19490return 0;
19491 ;
19492 return 0;
19493}
19494_ACEOF
19495rm -f conftest.$ac_objext
19496if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19497 (eval $ac_compile) 2>conftest.er1
973a76b1 19498 ac_status=$?
35996d22
AS
19499 grep -v '^ *+' conftest.er1 >conftest.err
19500 rm -f conftest.er1
19501 cat conftest.err >&5
973a76b1
DL
19502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19503 (exit $ac_status); } &&
4494a266
JD
19504 { ac_try='test -z "$ac_c_werror_flag"
19505 || test ! -s conftest.err'
35996d22
AS
19506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19507 (eval $ac_try) 2>&5
19508 ac_status=$?
19509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19510 (exit $ac_status); }; } &&
19511 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19512 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19513 (eval $ac_try) 2>&5
19514 ac_status=$?
19515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19516 (exit $ac_status); }; }; then
19517 ac_cv_member_struct_tm_tm_zone=yes
19518else
19519 echo "$as_me: failed program was:" >&5
19650fd6
AS
19520sed 's/^/| /' conftest.$ac_ext >&5
19521
973a76b1 19522cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19523/* confdefs.h. */
19524_ACEOF
19525cat confdefs.h >>conftest.$ac_ext
19526cat >>conftest.$ac_ext <<_ACEOF
19527/* end confdefs.h. */
973a76b1
DL
19528#include <sys/types.h>
19529#include <$ac_cv_struct_tm>
19530
19531
19532int
19533main ()
19534{
19535static struct tm ac_aggr;
19536if (sizeof ac_aggr.tm_zone)
19537return 0;
19538 ;
19539 return 0;
19540}
19541_ACEOF
19542rm -f conftest.$ac_objext
19543if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19544 (eval $ac_compile) 2>conftest.er1
973a76b1 19545 ac_status=$?
35996d22
AS
19546 grep -v '^ *+' conftest.er1 >conftest.err
19547 rm -f conftest.er1
19548 cat conftest.err >&5
973a76b1
DL
19549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19550 (exit $ac_status); } &&
4494a266
JD
19551 { ac_try='test -z "$ac_c_werror_flag"
19552 || test ! -s conftest.err'
35996d22
AS
19553 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19554 (eval $ac_try) 2>&5
19555 ac_status=$?
19556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19557 (exit $ac_status); }; } &&
19558 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19560 (eval $ac_try) 2>&5
19561 ac_status=$?
19562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19563 (exit $ac_status); }; }; then
19564 ac_cv_member_struct_tm_tm_zone=yes
19565else
19566 echo "$as_me: failed program was:" >&5
19650fd6
AS
19567sed 's/^/| /' conftest.$ac_ext >&5
19568
973a76b1
DL
19569ac_cv_member_struct_tm_tm_zone=no
19570fi
35996d22 19571rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1 19572fi
35996d22 19573rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
19574fi
19575echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
19576echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
19577if test $ac_cv_member_struct_tm_tm_zone = yes; then
19578
19579cat >>confdefs.h <<_ACEOF
19580#define HAVE_STRUCT_TM_TM_ZONE 1
19581_ACEOF
19582
19583
19584fi
19585
19586if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19587
19588cat >>confdefs.h <<\_ACEOF
19589#define HAVE_TM_ZONE 1
19590_ACEOF
19591
19592else
19593 echo "$as_me:$LINENO: checking for tzname" >&5
19594echo $ECHO_N "checking for tzname... $ECHO_C" >&6
19595if test "${ac_cv_var_tzname+set}" = set; then
19596 echo $ECHO_N "(cached) $ECHO_C" >&6
19597else
19598 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19599/* confdefs.h. */
19600_ACEOF
19601cat confdefs.h >>conftest.$ac_ext
19602cat >>conftest.$ac_ext <<_ACEOF
19603/* end confdefs.h. */
973a76b1
DL
19604#include <time.h>
19605#ifndef tzname /* For SGI. */
19606extern char *tzname[]; /* RS6000 and others reject char **tzname. */
19607#endif
19608
19609int
19610main ()
19611{
19612atoi(*tzname);
19613 ;
19614 return 0;
19615}
19616_ACEOF
19617rm -f conftest.$ac_objext conftest$ac_exeext
19618if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19619 (eval $ac_link) 2>conftest.er1
973a76b1 19620 ac_status=$?
35996d22
AS
19621 grep -v '^ *+' conftest.er1 >conftest.err
19622 rm -f conftest.er1
19623 cat conftest.err >&5
973a76b1
DL
19624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19625 (exit $ac_status); } &&
4494a266
JD
19626 { ac_try='test -z "$ac_c_werror_flag"
19627 || test ! -s conftest.err'
35996d22
AS
19628 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19629 (eval $ac_try) 2>&5
19630 ac_status=$?
19631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19632 (exit $ac_status); }; } &&
19633 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
19634 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19635 (eval $ac_try) 2>&5
19636 ac_status=$?
19637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19638 (exit $ac_status); }; }; then
19639 ac_cv_var_tzname=yes
19640else
19641 echo "$as_me: failed program was:" >&5
19650fd6
AS
19642sed 's/^/| /' conftest.$ac_ext >&5
19643
973a76b1
DL
19644ac_cv_var_tzname=no
19645fi
35996d22
AS
19646rm -f conftest.err conftest.$ac_objext \
19647 conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
19648fi
19649echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
19650echo "${ECHO_T}$ac_cv_var_tzname" >&6
19651 if test $ac_cv_var_tzname = yes; then
19652
19653cat >>confdefs.h <<\_ACEOF
19654#define HAVE_TZNAME 1
19655_ACEOF
19656
19657 fi
19658fi
19659
19660
48d4b120 19661if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 19662 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
19663echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
19664if test "${emacs_cv_struct_timezone+set}" = set; then
19665 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 19666else
503d2be0 19667 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19668/* confdefs.h. */
19669_ACEOF
19670cat confdefs.h >>conftest.$ac_ext
19671cat >>conftest.$ac_ext <<_ACEOF
19672/* end confdefs.h. */
48d4b120 19673#include <sys/time.h>
503d2be0
AS
19674int
19675main ()
19676{
48d4b120 19677struct timezone tz;
503d2be0
AS
19678 ;
19679 return 0;
19680}
19681_ACEOF
19682rm -f conftest.$ac_objext
c0d27fcc 19683if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19684 (eval $ac_compile) 2>conftest.er1
503d2be0 19685 ac_status=$?
35996d22
AS
19686 grep -v '^ *+' conftest.er1 >conftest.err
19687 rm -f conftest.er1
19688 cat conftest.err >&5
c0d27fcc 19689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19690 (exit $ac_status); } &&
4494a266
JD
19691 { ac_try='test -z "$ac_c_werror_flag"
19692 || test ! -s conftest.err'
35996d22
AS
19693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19694 (eval $ac_try) 2>&5
19695 ac_status=$?
19696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19697 (exit $ac_status); }; } &&
19698 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19699 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19700 (eval $ac_try) 2>&5
19701 ac_status=$?
c0d27fcc 19702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19703 (exit $ac_status); }; }; then
48d4b120
DL
19704 if test "$cross_compiling" = yes; then
19705 emacs_cv_struct_timezone=yes
19706else
503d2be0 19707 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19708/* confdefs.h. */
19709_ACEOF
19710cat confdefs.h >>conftest.$ac_ext
19711cat >>conftest.$ac_ext <<_ACEOF
19712/* end confdefs.h. */
48d4b120
DL
19713
19714#ifdef TIME_WITH_SYS_TIME
19715#include <sys/time.h>
19716#include <time.h>
19717#else
19718#ifdef HAVE_SYS_TIME_H
19719#include <sys/time.h>
19720#else
19721#include <time.h>
19722#endif
19723#endif
19724main () {
19725 struct timeval time;
19726 struct timezone dummy;
19727 exit (gettimeofday (&time, &dummy));
19728}
503d2be0
AS
19729_ACEOF
19730rm -f conftest$ac_exeext
c0d27fcc 19731if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19732 (eval $ac_link) 2>&5
19733 ac_status=$?
c0d27fcc 19734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19735 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19736 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19737 (eval $ac_try) 2>&5
19738 ac_status=$?
c0d27fcc 19739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19740 (exit $ac_status); }; }; then
48d4b120
DL
19741 emacs_cv_struct_timezone=yes
19742else
503d2be0
AS
19743 echo "$as_me: program exited with status $ac_status" >&5
19744echo "$as_me: failed program was:" >&5
19650fd6
AS
19745sed 's/^/| /' conftest.$ac_ext >&5
19746
c0d27fcc 19747( exit $ac_status )
503d2be0 19748emacs_cv_struct_timezone=no
48d4b120 19749fi
35996d22 19750rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 19751fi
48d4b120 19752else
503d2be0 19753 echo "$as_me: failed program was:" >&5
19650fd6
AS
19754sed 's/^/| /' conftest.$ac_ext >&5
19755
503d2be0 19756emacs_cv_struct_timezone=no
48d4b120 19757fi
35996d22 19758rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
48d4b120 19759fi
c0d27fcc 19760echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 19761echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
19762fi
19763
ba4481b5 19764ok_so_far=yes
c0d27fcc 19765echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
19766echo $ECHO_N "checking for socket... $ECHO_C" >&6
19767if test "${ac_cv_func_socket+set}" = set; then
19768 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 19769else
503d2be0 19770 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19771/* confdefs.h. */
19772_ACEOF
19773cat confdefs.h >>conftest.$ac_ext
19774cat >>conftest.$ac_ext <<_ACEOF
19775/* end confdefs.h. */
35996d22
AS
19776/* Define socket to an innocuous variant, in case <limits.h> declares socket.
19777 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19778#define socket innocuous_socket
19779
ba4481b5 19780/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19781 which can conflict with char socket (); below.
19782 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19783 <limits.h> exists even on freestanding compilers. */
35996d22 19784
19650fd6
AS
19785#ifdef __STDC__
19786# include <limits.h>
19787#else
19788# include <assert.h>
19789#endif
35996d22
AS
19790
19791#undef socket
19792
ba4481b5 19793/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19794#ifdef __cplusplus
19795extern "C"
19650fd6 19796{
503d2be0 19797#endif
ba4481b5 19798/* We use char because int might match the return type of a gcc2
503d2be0
AS
19799 builtin and then its argument prototype would still apply. */
19800char socket ();
ba4481b5
DL
19801/* The GNU C library defines this for functions which it implements
19802 to always fail with ENOSYS. Some functions are actually named
19803 something starting with __ and the normal name is an alias. */
19804#if defined (__stub_socket) || defined (__stub___socket)
19805choke me
19806#else
19650fd6
AS
19807char (*f) () = socket;
19808#endif
19809#ifdef __cplusplus
19810}
cd958eb3
MB
19811#endif
19812
19650fd6
AS
19813int
19814main ()
19815{
19816return f != socket;
503d2be0
AS
19817 ;
19818 return 0;
19819}
19820_ACEOF
19821rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19822if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 19823 (eval $ac_link) 2>conftest.er1
503d2be0 19824 ac_status=$?
35996d22
AS
19825 grep -v '^ *+' conftest.er1 >conftest.err
19826 rm -f conftest.er1
19827 cat conftest.err >&5
c0d27fcc 19828 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19829 (exit $ac_status); } &&
4494a266
JD
19830 { ac_try='test -z "$ac_c_werror_flag"
19831 || test ! -s conftest.err'
35996d22
AS
19832 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19833 (eval $ac_try) 2>&5
19834 ac_status=$?
19835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19836 (exit $ac_status); }; } &&
19837 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19839 (eval $ac_try) 2>&5
19840 ac_status=$?
c0d27fcc 19841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19842 (exit $ac_status); }; }; then
19843 ac_cv_func_socket=yes
19844else
19845 echo "$as_me: failed program was:" >&5
19650fd6
AS
19846sed 's/^/| /' conftest.$ac_ext >&5
19847
503d2be0
AS
19848ac_cv_func_socket=no
19849fi
35996d22
AS
19850rm -f conftest.err conftest.$ac_objext \
19851 conftest$ac_exeext conftest.$ac_ext
503d2be0 19852fi
c0d27fcc 19853echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
19854echo "${ECHO_T}$ac_cv_func_socket" >&6
19855if test $ac_cv_func_socket = yes; then
ba4481b5
DL
19856 :
19857else
503d2be0 19858 ok_so_far=no
ba4481b5
DL
19859fi
19860
19861if test $ok_so_far = yes; then
c0d27fcc
MR
19862 if test "${ac_cv_header_netinet_in_h+set}" = set; then
19863 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
19864echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19865if test "${ac_cv_header_netinet_in_h+set}" = set; then
19866 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19867fi
19868echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
19869echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 19870else
c0d27fcc
MR
19871 # Is the header compilable?
19872echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
19873echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
19874cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19875/* confdefs.h. */
19876_ACEOF
19877cat confdefs.h >>conftest.$ac_ext
19878cat >>conftest.$ac_ext <<_ACEOF
19879/* end confdefs.h. */
c0d27fcc
MR
19880$ac_includes_default
19881#include <netinet/in.h>
19882_ACEOF
19883rm -f conftest.$ac_objext
19884if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 19885 (eval $ac_compile) 2>conftest.er1
c0d27fcc 19886 ac_status=$?
35996d22
AS
19887 grep -v '^ *+' conftest.er1 >conftest.err
19888 rm -f conftest.er1
19889 cat conftest.err >&5
c0d27fcc
MR
19890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19891 (exit $ac_status); } &&
4494a266
JD
19892 { ac_try='test -z "$ac_c_werror_flag"
19893 || test ! -s conftest.err'
35996d22
AS
19894 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19895 (eval $ac_try) 2>&5
19896 ac_status=$?
19897 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19898 (exit $ac_status); }; } &&
19899 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19900 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19901 (eval $ac_try) 2>&5
19902 ac_status=$?
19903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19904 (exit $ac_status); }; }; then
19905 ac_header_compiler=yes
19906else
19907 echo "$as_me: failed program was:" >&5
19650fd6
AS
19908sed 's/^/| /' conftest.$ac_ext >&5
19909
c0d27fcc
MR
19910ac_header_compiler=no
19911fi
35996d22 19912rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19913echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19914echo "${ECHO_T}$ac_header_compiler" >&6
19915
19916# Is the header present?
19917echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
19918echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
19919cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
19920/* confdefs.h. */
19921_ACEOF
19922cat confdefs.h >>conftest.$ac_ext
19923cat >>conftest.$ac_ext <<_ACEOF
19924/* end confdefs.h. */
ba4481b5 19925#include <netinet/in.h>
503d2be0 19926_ACEOF
c0d27fcc 19927if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19928 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19929 ac_status=$?
6bae0ccf 19930 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19931 rm -f conftest.er1
19932 cat conftest.err >&5
c0d27fcc 19933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19934 (exit $ac_status); } >/dev/null; then
19935 if test -s conftest.err; then
19936 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 19937 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
19938 else
19939 ac_cpp_err=
19940 fi
19941else
19942 ac_cpp_err=yes
19943fi
19944if test -z "$ac_cpp_err"; then
c0d27fcc 19945 ac_header_preproc=yes
ba4481b5 19946else
503d2be0 19947 echo "$as_me: failed program was:" >&5
19650fd6
AS
19948sed 's/^/| /' conftest.$ac_ext >&5
19949
c0d27fcc 19950 ac_header_preproc=no
ba4481b5 19951fi
503d2be0 19952rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19953echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19954echo "${ECHO_T}$ac_header_preproc" >&6
19955
19956# So? What about this header?
35996d22
AS
19957case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19958 yes:no: )
c0d27fcc
MR
19959 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
19960echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
19961 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the compiler's result" >&5
19962echo "$as_me: WARNING: netinet/in.h: proceeding with the compiler's result" >&2;}
19963 ac_header_preproc=yes
19650fd6 19964 ;;
35996d22 19965 no:yes:* )
c0d27fcc
MR
19966 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
19967echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
35996d22
AS
19968 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
19969echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
19970 { echo "$as_me:$LINENO: WARNING: netinet/in.h: see the Autoconf documentation" >&5
19971echo "$as_me: WARNING: netinet/in.h: see the Autoconf documentation" >&2;}
19972 { echo "$as_me:$LINENO: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&5
19973echo "$as_me: WARNING: netinet/in.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 19974 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
19650fd6 19975echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
19976 { echo "$as_me:$LINENO: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&5
19977echo "$as_me: WARNING: netinet/in.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
19978 (
19979 cat <<\_ASBOX
35996d22
AS
19980## ------------------------------------------ ##
19981## Report this to the AC_PACKAGE_NAME lists. ##
19982## ------------------------------------------ ##
19650fd6
AS
19983_ASBOX
19984 ) |
19985 sed "s/^/$as_me: WARNING: /" >&2
19986 ;;
c0d27fcc
MR
19987esac
19988echo "$as_me:$LINENO: checking for netinet/in.h" >&5
19989echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
19990if test "${ac_cv_header_netinet_in_h+set}" = set; then
19991 echo $ECHO_N "(cached) $ECHO_C" >&6
19992else
19993 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 19994fi
c0d27fcc 19995echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 19996echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
19997
19998fi
503d2be0 19999if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
20000 :
20001else
503d2be0 20002 ok_so_far=no
ba4481b5
DL
20003fi
20004
c0d27fcc 20005
ba4481b5
DL
20006fi
20007if test $ok_so_far = yes; then
c0d27fcc
MR
20008 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
20009 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
20010echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
20011if test "${ac_cv_header_arpa_inet_h+set}" = set; then
20012 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20013fi
20014echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
20015echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 20016else
c0d27fcc
MR
20017 # Is the header compilable?
20018echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
20019echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
20020cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20021/* confdefs.h. */
20022_ACEOF
20023cat confdefs.h >>conftest.$ac_ext
20024cat >>conftest.$ac_ext <<_ACEOF
20025/* end confdefs.h. */
c0d27fcc
MR
20026$ac_includes_default
20027#include <arpa/inet.h>
20028_ACEOF
20029rm -f conftest.$ac_objext
20030if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20031 (eval $ac_compile) 2>conftest.er1
c0d27fcc 20032 ac_status=$?
35996d22
AS
20033 grep -v '^ *+' conftest.er1 >conftest.err
20034 rm -f conftest.er1
20035 cat conftest.err >&5
c0d27fcc
MR
20036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20037 (exit $ac_status); } &&
4494a266
JD
20038 { ac_try='test -z "$ac_c_werror_flag"
20039 || test ! -s conftest.err'
35996d22
AS
20040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20041 (eval $ac_try) 2>&5
20042 ac_status=$?
20043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20044 (exit $ac_status); }; } &&
20045 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20046 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20047 (eval $ac_try) 2>&5
20048 ac_status=$?
20049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20050 (exit $ac_status); }; }; then
20051 ac_header_compiler=yes
20052else
20053 echo "$as_me: failed program was:" >&5
19650fd6
AS
20054sed 's/^/| /' conftest.$ac_ext >&5
20055
c0d27fcc
MR
20056ac_header_compiler=no
20057fi
35996d22 20058rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20059echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20060echo "${ECHO_T}$ac_header_compiler" >&6
20061
20062# Is the header present?
20063echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
20064echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
20065cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20066/* confdefs.h. */
20067_ACEOF
20068cat confdefs.h >>conftest.$ac_ext
20069cat >>conftest.$ac_ext <<_ACEOF
20070/* end confdefs.h. */
ba4481b5 20071#include <arpa/inet.h>
503d2be0 20072_ACEOF
c0d27fcc 20073if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20074 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20075 ac_status=$?
6bae0ccf 20076 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20077 rm -f conftest.er1
20078 cat conftest.err >&5
c0d27fcc 20079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20080 (exit $ac_status); } >/dev/null; then
20081 if test -s conftest.err; then
20082 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20083 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20084 else
20085 ac_cpp_err=
20086 fi
20087else
20088 ac_cpp_err=yes
20089fi
20090if test -z "$ac_cpp_err"; then
c0d27fcc 20091 ac_header_preproc=yes
ba4481b5 20092else
503d2be0 20093 echo "$as_me: failed program was:" >&5
19650fd6
AS
20094sed 's/^/| /' conftest.$ac_ext >&5
20095
c0d27fcc 20096 ac_header_preproc=no
ba4481b5 20097fi
503d2be0 20098rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20099echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20100echo "${ECHO_T}$ac_header_preproc" >&6
20101
20102# So? What about this header?
35996d22
AS
20103case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20104 yes:no: )
c0d27fcc
MR
20105 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
20106echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20107 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the compiler's result" >&5
20108echo "$as_me: WARNING: arpa/inet.h: proceeding with the compiler's result" >&2;}
20109 ac_header_preproc=yes
19650fd6 20110 ;;
35996d22 20111 no:yes:* )
c0d27fcc
MR
20112 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
20113echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
35996d22
AS
20114 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
20115echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
20116 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: see the Autoconf documentation" >&5
20117echo "$as_me: WARNING: arpa/inet.h: see the Autoconf documentation" >&2;}
20118 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&5
20119echo "$as_me: WARNING: arpa/inet.h: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20120 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
19650fd6 20121echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20122 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&5
20123echo "$as_me: WARNING: arpa/inet.h: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20124 (
20125 cat <<\_ASBOX
35996d22
AS
20126## ------------------------------------------ ##
20127## Report this to the AC_PACKAGE_NAME lists. ##
20128## ------------------------------------------ ##
19650fd6
AS
20129_ASBOX
20130 ) |
20131 sed "s/^/$as_me: WARNING: /" >&2
20132 ;;
c0d27fcc
MR
20133esac
20134echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
20135echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
20136if test "${ac_cv_header_arpa_inet_h+set}" = set; then
20137 echo $ECHO_N "(cached) $ECHO_C" >&6
20138else
20139 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 20140fi
c0d27fcc 20141echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 20142echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
20143
20144fi
503d2be0 20145if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
20146 :
20147else
503d2be0 20148 ok_so_far=no
ba4481b5
DL
20149fi
20150
c0d27fcc 20151
ba4481b5
DL
20152fi
20153if test $ok_so_far = yes; then
b936fae4 20154
c0d27fcc 20155cat >>confdefs.h <<\_ACEOF
ba4481b5 20156#define HAVE_INET_SOCKETS 1
c0d27fcc 20157_ACEOF
ba4481b5
DL
20158
20159fi
20160
2d2b6695 20161
7862d3a8 20162for ac_header in sys/ioctl.h
2d2b6695
KS
20163do
20164as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
20165if eval "test \"\${$as_ac_Header+set}\" = set"; then
20166 echo "$as_me:$LINENO: checking for $ac_header" >&5
20167echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20168if eval "test \"\${$as_ac_Header+set}\" = set"; then
20169 echo $ECHO_N "(cached) $ECHO_C" >&6
20170fi
20171echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20172echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20173else
20174 # Is the header compilable?
20175echo "$as_me:$LINENO: checking $ac_header usability" >&5
20176echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20177cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
20178/* confdefs.h. */
20179_ACEOF
20180cat confdefs.h >>conftest.$ac_ext
20181cat >>conftest.$ac_ext <<_ACEOF
20182/* end confdefs.h. */
20183$ac_includes_default
20184#include <$ac_header>
20185_ACEOF
20186rm -f conftest.$ac_objext
20187if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20188 (eval $ac_compile) 2>conftest.er1
2d2b6695 20189 ac_status=$?
35996d22
AS
20190 grep -v '^ *+' conftest.er1 >conftest.err
20191 rm -f conftest.er1
20192 cat conftest.err >&5
2d2b6695
KS
20193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20194 (exit $ac_status); } &&
4494a266
JD
20195 { ac_try='test -z "$ac_c_werror_flag"
20196 || test ! -s conftest.err'
35996d22
AS
20197 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20198 (eval $ac_try) 2>&5
20199 ac_status=$?
20200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20201 (exit $ac_status); }; } &&
20202 { ac_try='test -s conftest.$ac_objext'
2d2b6695
KS
20203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20204 (eval $ac_try) 2>&5
20205 ac_status=$?
20206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20207 (exit $ac_status); }; }; then
20208 ac_header_compiler=yes
20209else
20210 echo "$as_me: failed program was:" >&5
20211sed 's/^/| /' conftest.$ac_ext >&5
20212
20213ac_header_compiler=no
20214fi
35996d22 20215rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2d2b6695
KS
20216echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20217echo "${ECHO_T}$ac_header_compiler" >&6
20218
20219# Is the header present?
20220echo "$as_me:$LINENO: checking $ac_header presence" >&5
20221echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20222cat >conftest.$ac_ext <<_ACEOF
2d2b6695
KS
20223/* confdefs.h. */
20224_ACEOF
20225cat confdefs.h >>conftest.$ac_ext
20226cat >>conftest.$ac_ext <<_ACEOF
20227/* end confdefs.h. */
20228#include <$ac_header>
20229_ACEOF
20230if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
20231 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20232 ac_status=$?
20233 grep -v '^ *+' conftest.er1 >conftest.err
20234 rm -f conftest.er1
20235 cat conftest.err >&5
20236 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20237 (exit $ac_status); } >/dev/null; then
20238 if test -s conftest.err; then
20239 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20240 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
2d2b6695
KS
20241 else
20242 ac_cpp_err=
20243 fi
20244else
20245 ac_cpp_err=yes
20246fi
20247if test -z "$ac_cpp_err"; then
20248 ac_header_preproc=yes
20249else
20250 echo "$as_me: failed program was:" >&5
20251sed 's/^/| /' conftest.$ac_ext >&5
20252
20253 ac_header_preproc=no
20254fi
20255rm -f conftest.err conftest.$ac_ext
20256echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20257echo "${ECHO_T}$ac_header_preproc" >&6
20258
20259# So? What about this header?
35996d22
AS
20260case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20261 yes:no: )
2d2b6695
KS
20262 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20263echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20264 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20265echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20266 ac_header_preproc=yes
2d2b6695 20267 ;;
35996d22 20268 no:yes:* )
2d2b6695
KS
20269 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20270echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20271 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20272echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20273 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20274echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20275 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20276echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
2d2b6695
KS
20277 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
20278echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20279 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20280echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
2d2b6695
KS
20281 (
20282 cat <<\_ASBOX
35996d22
AS
20283## ------------------------------------------ ##
20284## Report this to the AC_PACKAGE_NAME lists. ##
20285## ------------------------------------------ ##
2d2b6695
KS
20286_ASBOX
20287 ) |
20288 sed "s/^/$as_me: WARNING: /" >&2
20289 ;;
20290esac
20291echo "$as_me:$LINENO: checking for $ac_header" >&5
20292echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20293if eval "test \"\${$as_ac_Header+set}\" = set"; then
20294 echo $ECHO_N "(cached) $ECHO_C" >&6
20295else
35996d22 20296 eval "$as_ac_Header=\$ac_header_preproc"
2d2b6695
KS
20297fi
20298echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20299echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
20300
20301fi
20302if test `eval echo '${'$as_ac_Header'}'` = yes; then
20303 cat >>confdefs.h <<_ACEOF
20304#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
20305_ACEOF
20306
20307fi
20308
20309done
20310
20311
ba4481b5 20312if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 20313
c0d27fcc 20314cat >>confdefs.h <<\_ACEOF
ba4481b5 20315#define HAVE_AIX_SMT_EXP 1
c0d27fcc 20316_ACEOF
ba4481b5
DL
20317
20318fi
20319
c0d27fcc 20320echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 20321echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 20322if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 20323 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 20324echo "${ECHO_T}yes" >&6
b936fae4 20325
c0d27fcc 20326cat >>confdefs.h <<\_ACEOF
3d9fec71 20327#define HAVE_DEV_PTMX 1
c0d27fcc 20328_ACEOF
3d9fec71
DL
20329
20330else
c0d27fcc 20331 echo "$as_me:$LINENO: result: no" >&5
503d2be0 20332echo "${ECHO_T}no" >&6
3d9fec71
DL
20333fi
20334
c0d27fcc 20335echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
20336echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
20337if test "${ac_cv_type_pid_t+set}" = set; then
20338 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 20339else
503d2be0 20340 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20341/* confdefs.h. */
20342_ACEOF
20343cat confdefs.h >>conftest.$ac_ext
20344cat >>conftest.$ac_ext <<_ACEOF
20345/* end confdefs.h. */
503d2be0
AS
20346$ac_includes_default
20347int
20348main ()
20349{
20350if ((pid_t *) 0)
20351 return 0;
20352if (sizeof (pid_t))
20353 return 0;
20354 ;
20355 return 0;
20356}
20357_ACEOF
20358rm -f conftest.$ac_objext
c0d27fcc 20359if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20360 (eval $ac_compile) 2>conftest.er1
503d2be0 20361 ac_status=$?
35996d22
AS
20362 grep -v '^ *+' conftest.er1 >conftest.err
20363 rm -f conftest.er1
20364 cat conftest.err >&5
c0d27fcc 20365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20366 (exit $ac_status); } &&
4494a266
JD
20367 { ac_try='test -z "$ac_c_werror_flag"
20368 || test ! -s conftest.err'
35996d22
AS
20369 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20370 (eval $ac_try) 2>&5
20371 ac_status=$?
20372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20373 (exit $ac_status); }; } &&
20374 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20375 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20376 (eval $ac_try) 2>&5
20377 ac_status=$?
c0d27fcc 20378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20379 (exit $ac_status); }; }; then
647847ea
DL
20380 ac_cv_type_pid_t=yes
20381else
503d2be0 20382 echo "$as_me: failed program was:" >&5
19650fd6
AS
20383sed 's/^/| /' conftest.$ac_ext >&5
20384
503d2be0 20385ac_cv_type_pid_t=no
647847ea 20386fi
35996d22 20387rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
647847ea 20388fi
c0d27fcc 20389echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
20390echo "${ECHO_T}$ac_cv_type_pid_t" >&6
20391if test $ac_cv_type_pid_t = yes; then
20392 :
20393else
20394
c0d27fcc 20395cat >>confdefs.h <<_ACEOF
647847ea 20396#define pid_t int
c0d27fcc 20397_ACEOF
647847ea
DL
20398
20399fi
20400
c0d27fcc
MR
20401
20402
503d2be0
AS
20403for ac_header in unistd.h vfork.h
20404do
20405as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
20406if eval "test \"\${$as_ac_Header+set}\" = set"; then
20407 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
20408echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20409if eval "test \"\${$as_ac_Header+set}\" = set"; then
20410 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
20411fi
20412echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
20413echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 20414else
c0d27fcc
MR
20415 # Is the header compilable?
20416echo "$as_me:$LINENO: checking $ac_header usability" >&5
20417echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
20418cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20419/* confdefs.h. */
20420_ACEOF
20421cat confdefs.h >>conftest.$ac_ext
20422cat >>conftest.$ac_ext <<_ACEOF
20423/* end confdefs.h. */
c0d27fcc
MR
20424$ac_includes_default
20425#include <$ac_header>
20426_ACEOF
20427rm -f conftest.$ac_objext
20428if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20429 (eval $ac_compile) 2>conftest.er1
c0d27fcc 20430 ac_status=$?
35996d22
AS
20431 grep -v '^ *+' conftest.er1 >conftest.err
20432 rm -f conftest.er1
20433 cat conftest.err >&5
c0d27fcc
MR
20434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20435 (exit $ac_status); } &&
4494a266
JD
20436 { ac_try='test -z "$ac_c_werror_flag"
20437 || test ! -s conftest.err'
35996d22
AS
20438 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20439 (eval $ac_try) 2>&5
20440 ac_status=$?
20441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20442 (exit $ac_status); }; } &&
20443 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
20444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20445 (eval $ac_try) 2>&5
20446 ac_status=$?
20447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20448 (exit $ac_status); }; }; then
20449 ac_header_compiler=yes
20450else
20451 echo "$as_me: failed program was:" >&5
19650fd6
AS
20452sed 's/^/| /' conftest.$ac_ext >&5
20453
c0d27fcc
MR
20454ac_header_compiler=no
20455fi
35996d22 20456rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
20457echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20458echo "${ECHO_T}$ac_header_compiler" >&6
20459
20460# Is the header present?
20461echo "$as_me:$LINENO: checking $ac_header presence" >&5
20462echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
20463cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20464/* confdefs.h. */
20465_ACEOF
20466cat confdefs.h >>conftest.$ac_ext
20467cat >>conftest.$ac_ext <<_ACEOF
20468/* end confdefs.h. */
503d2be0
AS
20469#include <$ac_header>
20470_ACEOF
c0d27fcc 20471if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
20472 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
20473 ac_status=$?
6bae0ccf 20474 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
20475 rm -f conftest.er1
20476 cat conftest.err >&5
c0d27fcc 20477 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20478 (exit $ac_status); } >/dev/null; then
20479 if test -s conftest.err; then
20480 ac_cpp_err=$ac_c_preproc_warn_flag
35996d22 20481 ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
503d2be0
AS
20482 else
20483 ac_cpp_err=
20484 fi
647847ea 20485else
503d2be0
AS
20486 ac_cpp_err=yes
20487fi
20488if test -z "$ac_cpp_err"; then
c0d27fcc 20489 ac_header_preproc=yes
647847ea 20490else
503d2be0 20491 echo "$as_me: failed program was:" >&5
19650fd6
AS
20492sed 's/^/| /' conftest.$ac_ext >&5
20493
c0d27fcc 20494 ac_header_preproc=no
647847ea 20495fi
503d2be0 20496rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
20497echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20498echo "${ECHO_T}$ac_header_preproc" >&6
20499
20500# So? What about this header?
35996d22
AS
20501case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20502 yes:no: )
c0d27fcc
MR
20503 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
20504echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
35996d22
AS
20505 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
20506echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
20507 ac_header_preproc=yes
19650fd6 20508 ;;
35996d22 20509 no:yes:* )
c0d27fcc
MR
20510 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
20511echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
35996d22
AS
20512 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
20513echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
20514 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
20515echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
20516 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
20517echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
c0d27fcc 20518 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 20519echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
35996d22
AS
20520 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
20521echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
19650fd6
AS
20522 (
20523 cat <<\_ASBOX
35996d22
AS
20524## ------------------------------------------ ##
20525## Report this to the AC_PACKAGE_NAME lists. ##
20526## ------------------------------------------ ##
19650fd6
AS
20527_ASBOX
20528 ) |
20529 sed "s/^/$as_me: WARNING: /" >&2
20530 ;;
c0d27fcc
MR
20531esac
20532echo "$as_me:$LINENO: checking for $ac_header" >&5
20533echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
20534if eval "test \"\${$as_ac_Header+set}\" = set"; then
20535 echo $ECHO_N "(cached) $ECHO_C" >&6
20536else
35996d22 20537 eval "$as_ac_Header=\$ac_header_preproc"
647847ea 20538fi
c0d27fcc 20539echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 20540echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
20541
20542fi
503d2be0 20543if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 20544 cat >>confdefs.h <<_ACEOF
503d2be0 20545#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 20546_ACEOF
647847ea 20547
73b77ee5 20548fi
c0d27fcc 20549
503d2be0 20550done
73b77ee5 20551
c0d27fcc
MR
20552
20553
503d2be0
AS
20554for ac_func in fork vfork
20555do
20556as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 20557echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
20558echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
20559if eval "test \"\${$as_ac_var+set}\" = set"; then
20560 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20561else
503d2be0 20562 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20563/* confdefs.h. */
20564_ACEOF
20565cat confdefs.h >>conftest.$ac_ext
20566cat >>conftest.$ac_ext <<_ACEOF
20567/* end confdefs.h. */
35996d22
AS
20568/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20569 For example, HP-UX 11i <limits.h> declares gettimeofday. */
20570#define $ac_func innocuous_$ac_func
20571
fa0b693c 20572/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
20573 which can conflict with char $ac_func (); below.
20574 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20575 <limits.h> exists even on freestanding compilers. */
35996d22 20576
19650fd6
AS
20577#ifdef __STDC__
20578# include <limits.h>
20579#else
20580# include <assert.h>
20581#endif
35996d22
AS
20582
20583#undef $ac_func
20584
fa0b693c 20585/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
20586#ifdef __cplusplus
20587extern "C"
19650fd6 20588{
503d2be0 20589#endif
fa0b693c 20590/* We use char because int might match the return type of a gcc2
503d2be0
AS
20591 builtin and then its argument prototype would still apply. */
20592char $ac_func ();
fa0b693c
GM
20593/* The GNU C library defines this for functions which it implements
20594 to always fail with ENOSYS. Some functions are actually named
20595 something starting with __ and the normal name is an alias. */
503d2be0 20596#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
20597choke me
20598#else
19650fd6
AS
20599char (*f) () = $ac_func;
20600#endif
20601#ifdef __cplusplus
20602}
fa0b693c
GM
20603#endif
20604
19650fd6
AS
20605int
20606main ()
20607{
20608return f != $ac_func;
503d2be0
AS
20609 ;
20610 return 0;
20611}
20612_ACEOF
20613rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 20614if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20615 (eval $ac_link) 2>conftest.er1
503d2be0 20616 ac_status=$?
35996d22
AS
20617 grep -v '^ *+' conftest.er1 >conftest.err
20618 rm -f conftest.er1
20619 cat conftest.err >&5
c0d27fcc 20620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20621 (exit $ac_status); } &&
4494a266
JD
20622 { ac_try='test -z "$ac_c_werror_flag"
20623 || test ! -s conftest.err'
35996d22
AS
20624 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20625 (eval $ac_try) 2>&5
20626 ac_status=$?
20627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20628 (exit $ac_status); }; } &&
20629 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 20630 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20631 (eval $ac_try) 2>&5
20632 ac_status=$?
c0d27fcc 20633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20634 (exit $ac_status); }; }; then
20635 eval "$as_ac_var=yes"
20636else
20637 echo "$as_me: failed program was:" >&5
19650fd6
AS
20638sed 's/^/| /' conftest.$ac_ext >&5
20639
503d2be0
AS
20640eval "$as_ac_var=no"
20641fi
35996d22
AS
20642rm -f conftest.err conftest.$ac_objext \
20643 conftest$ac_exeext conftest.$ac_ext
503d2be0 20644fi
c0d27fcc 20645echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
20646echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
20647if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 20648 cat >>confdefs.h <<_ACEOF
503d2be0 20649#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 20650_ACEOF
503d2be0 20651
fa0b693c 20652fi
503d2be0 20653done
fa0b693c 20654
503d2be0 20655if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 20656 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
20657echo $ECHO_N "checking for working fork... $ECHO_C" >&6
20658if test "${ac_cv_func_fork_works+set}" = set; then
20659 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 20660else
503d2be0
AS
20661 if test "$cross_compiling" = yes; then
20662 ac_cv_func_fork_works=cross
20663else
20664 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 20665/* By Ruediger Kuhlmann. */
503d2be0
AS
20666 #include <sys/types.h>
20667 #if HAVE_UNISTD_H
20668 # include <unistd.h>
20669 #endif
20670 /* Some systems only have a dummy stub for fork() */
20671 int main ()
20672 {
35996d22
AS
20673 if (fork() < 0)
20674 exit (1);
20675 exit (0);
503d2be0
AS
20676 }
20677_ACEOF
20678rm -f conftest$ac_exeext
c0d27fcc 20679if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20680 (eval $ac_link) 2>&5
20681 ac_status=$?
c0d27fcc 20682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20683 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20684 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20685 (eval $ac_try) 2>&5
20686 ac_status=$?
c0d27fcc 20687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
20688 (exit $ac_status); }; }; then
20689 ac_cv_func_fork_works=yes
20690else
20691 echo "$as_me: program exited with status $ac_status" >&5
20692echo "$as_me: failed program was:" >&5
19650fd6
AS
20693sed 's/^/| /' conftest.$ac_ext >&5
20694
c0d27fcc 20695( exit $ac_status )
503d2be0
AS
20696ac_cv_func_fork_works=no
20697fi
35996d22 20698rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
20699fi
20700fi
c0d27fcc 20701echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
20702echo "${ECHO_T}$ac_cv_func_fork_works" >&6
20703
6bae0ccf
DL
20704else
20705 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
20706fi
20707if test "x$ac_cv_func_fork_works" = xcross; then
20708 case $host in
20709 *-*-amigaos* | *-*-msdosdjgpp*)
20710 # Override, as these systems have only a dummy fork() stub
20711 ac_cv_func_fork_works=no
20712 ;;
20713 *)
20714 ac_cv_func_fork_works=yes
20715 ;;
20716 esac
c0d27fcc
MR
20717 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
20718echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 20719fi
73b77ee5 20720ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 20721if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 20722 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
20723echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
20724if test "${ac_cv_func_vfork_works+set}" = set; then
20725 echo $ECHO_N "(cached) $ECHO_C" >&6
20726else
20727 if test "$cross_compiling" = yes; then
20728 ac_cv_func_vfork_works=cross
fa0b693c 20729else
503d2be0 20730 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20731/* confdefs.h. */
20732_ACEOF
20733cat confdefs.h >>conftest.$ac_ext
20734cat >>conftest.$ac_ext <<_ACEOF
20735/* end confdefs.h. */
73b77ee5
GM
20736/* Thanks to Paul Eggert for this test. */
20737#include <stdio.h>
19650fd6 20738#include <stdlib.h>
fa0b693c 20739#include <sys/types.h>
73b77ee5 20740#include <sys/stat.h>
19650fd6 20741#include <sys/wait.h>
503d2be0
AS
20742#if HAVE_UNISTD_H
20743# include <unistd.h>
73b77ee5 20744#endif
503d2be0
AS
20745#if HAVE_VFORK_H
20746# include <vfork.h>
73b77ee5
GM
20747#endif
20748/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
20749 argument registers are propagated back to the parent. The compiler
20750 is told about this with #include <vfork.h>, but some compilers
20751 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
20752 static variable whose address is put into a register that is
20753 clobbered by the vfork. */
19650fd6 20754static void
fa0b693c 20755#ifdef __cplusplus
73b77ee5 20756sparc_address_test (int arg)
503d2be0 20757# else
73b77ee5 20758sparc_address_test (arg) int arg;
fa0b693c 20759#endif
fa0b693c 20760{
73b77ee5
GM
20761 static pid_t child;
20762 if (!child) {
20763 child = vfork ();
20764 if (child < 0) {
20765 perror ("vfork");
20766 _exit(2);
20767 }
20768 if (!child) {
20769 arg = getpid();
20770 write(-1, "", 0);
20771 _exit (arg);
20772 }
20773 }
20774}
503d2be0
AS
20775
20776int
20777main ()
20778{
73b77ee5
GM
20779 pid_t parent = getpid ();
20780 pid_t child;
fa0b693c 20781
19650fd6 20782 sparc_address_test (0);
fa0b693c 20783
73b77ee5 20784 child = vfork ();
fa0b693c 20785
73b77ee5 20786 if (child == 0) {
503d2be0
AS
20787 /* Here is another test for sparc vfork register problems. This
20788 test uses lots of local variables, at least as many local
20789 variables as main has allocated so far including compiler
20790 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
20791 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
20792 reuse the register of parent for one of the local variables,
20793 since it will think that parent can't possibly be used any more
20794 in this routine. Assigning to the local variable will thus
20795 munge parent in the parent process. */
73b77ee5
GM
20796 pid_t
20797 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
20798 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
20799 /* Convince the compiler that p..p7 are live; otherwise, it might
20800 use the same hardware register for all 8 local variables. */
20801 if (p != p1 || p != p2 || p != p3 || p != p4
20802 || p != p5 || p != p6 || p != p7)
20803 _exit(1);
fa0b693c 20804
503d2be0
AS
20805 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
20806 from child file descriptors. If the child closes a descriptor
20807 before it execs or exits, this munges the parent's descriptor
20808 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
20809 _exit(close(fileno(stdout)) != 0);
20810 } else {
20811 int status;
20812 struct stat st;
20813
20814 while (wait(&status) != child)
20815 ;
20816 exit(
20817 /* Was there some problem with vforking? */
20818 child < 0
20819
20820 /* Did the child fail? (This shouldn't happen.) */
20821 || status
20822
20823 /* Did the vfork/compiler bug occur? */
20824 || parent != getpid()
fa0b693c 20825
73b77ee5
GM
20826 /* Did the file descriptor bug occur? */
20827 || fstat(fileno(stdout), &st) != 0
20828 );
20829 }
20830}
503d2be0
AS
20831_ACEOF
20832rm -f conftest$ac_exeext
c0d27fcc 20833if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
20834 (eval $ac_link) 2>&5
20835 ac_status=$?
c0d27fcc 20836 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20837 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 20838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20839 (eval $ac_try) 2>&5
20840 ac_status=$?
c0d27fcc 20841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20842 (exit $ac_status); }; }; then
73b77ee5 20843 ac_cv_func_vfork_works=yes
fa0b693c 20844else
503d2be0
AS
20845 echo "$as_me: program exited with status $ac_status" >&5
20846echo "$as_me: failed program was:" >&5
19650fd6
AS
20847sed 's/^/| /' conftest.$ac_ext >&5
20848
c0d27fcc 20849( exit $ac_status )
503d2be0
AS
20850ac_cv_func_vfork_works=no
20851fi
35996d22 20852rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 20853fi
fa0b693c 20854fi
c0d27fcc 20855echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 20856echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 20857
503d2be0
AS
20858fi;
20859if test "x$ac_cv_func_fork_works" = xcross; then
35996d22 20860 ac_cv_func_vfork_works=$ac_cv_func_vfork
c0d27fcc
MR
20861 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
20862echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
20863fi
20864
503d2be0
AS
20865if test "x$ac_cv_func_vfork_works" = xyes; then
20866
c0d27fcc 20867cat >>confdefs.h <<\_ACEOF
503d2be0 20868#define HAVE_WORKING_VFORK 1
c0d27fcc 20869_ACEOF
503d2be0
AS
20870
20871else
20872
c0d27fcc 20873cat >>confdefs.h <<\_ACEOF
73b77ee5 20874#define vfork fork
c0d27fcc 20875_ACEOF
fa0b693c
GM
20876
20877fi
503d2be0
AS
20878if test "x$ac_cv_func_fork_works" = xyes; then
20879
c0d27fcc 20880cat >>confdefs.h <<\_ACEOF
503d2be0 20881#define HAVE_WORKING_FORK 1
c0d27fcc 20882_ACEOF
fa0b693c 20883
503d2be0 20884fi
647847ea 20885
c0d27fcc 20886
6a3a24fa
JD
20887echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
20888echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
20889if test "${emacs_cv_langinfo_codeset+set}" = set; then
20890 echo $ECHO_N "(cached) $ECHO_C" >&6
20891else
20892 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20893/* confdefs.h. */
20894_ACEOF
20895cat confdefs.h >>conftest.$ac_ext
20896cat >>conftest.$ac_ext <<_ACEOF
20897/* end confdefs.h. */
6a3a24fa
JD
20898#include <langinfo.h>
20899int
20900main ()
20901{
20902char* cs = nl_langinfo(CODESET);
20903 ;
20904 return 0;
20905}
20906_ACEOF
20907rm -f conftest.$ac_objext conftest$ac_exeext
20908if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
35996d22 20909 (eval $ac_link) 2>conftest.er1
6a3a24fa 20910 ac_status=$?
35996d22
AS
20911 grep -v '^ *+' conftest.er1 >conftest.err
20912 rm -f conftest.er1
20913 cat conftest.err >&5
6a3a24fa
JD
20914 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20915 (exit $ac_status); } &&
4494a266
JD
20916 { ac_try='test -z "$ac_c_werror_flag"
20917 || test ! -s conftest.err'
35996d22
AS
20918 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20919 (eval $ac_try) 2>&5
20920 ac_status=$?
20921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20922 (exit $ac_status); }; } &&
20923 { ac_try='test -s conftest$ac_exeext'
6a3a24fa
JD
20924 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20925 (eval $ac_try) 2>&5
20926 ac_status=$?
20927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20928 (exit $ac_status); }; }; then
20929 emacs_cv_langinfo_codeset=yes
20930else
20931 echo "$as_me: failed program was:" >&5
19650fd6
AS
20932sed 's/^/| /' conftest.$ac_ext >&5
20933
6a3a24fa
JD
20934emacs_cv_langinfo_codeset=no
20935fi
35996d22
AS
20936rm -f conftest.err conftest.$ac_objext \
20937 conftest$ac_exeext conftest.$ac_ext
6a3a24fa
JD
20938
20939fi
20940echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
20941echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
20942if test $emacs_cv_langinfo_codeset = yes; then
20943
20944cat >>confdefs.h <<\_ACEOF
20945#define HAVE_LANGINFO_CODESET 1
20946_ACEOF
20947
20948fi
20949
c0d27fcc 20950echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
20951echo $ECHO_N "checking for size_t... $ECHO_C" >&6
20952if test "${ac_cv_type_size_t+set}" = set; then
20953 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 20954else
503d2be0 20955 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
20956/* confdefs.h. */
20957_ACEOF
20958cat confdefs.h >>conftest.$ac_ext
20959cat >>conftest.$ac_ext <<_ACEOF
20960/* end confdefs.h. */
503d2be0
AS
20961$ac_includes_default
20962int
20963main ()
20964{
20965if ((size_t *) 0)
20966 return 0;
20967if (sizeof (size_t))
20968 return 0;
20969 ;
20970 return 0;
20971}
20972_ACEOF
20973rm -f conftest.$ac_objext
c0d27fcc 20974if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 20975 (eval $ac_compile) 2>conftest.er1
503d2be0 20976 ac_status=$?
35996d22
AS
20977 grep -v '^ *+' conftest.er1 >conftest.err
20978 rm -f conftest.er1
20979 cat conftest.err >&5
c0d27fcc 20980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20981 (exit $ac_status); } &&
4494a266
JD
20982 { ac_try='test -z "$ac_c_werror_flag"
20983 || test ! -s conftest.err'
35996d22
AS
20984 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20985 (eval $ac_try) 2>&5
20986 ac_status=$?
20987 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20988 (exit $ac_status); }; } &&
20989 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 20990 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
20991 (eval $ac_try) 2>&5
20992 ac_status=$?
c0d27fcc 20993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 20994 (exit $ac_status); }; }; then
8730a8da
DL
20995 ac_cv_type_size_t=yes
20996else
503d2be0 20997 echo "$as_me: failed program was:" >&5
19650fd6
AS
20998sed 's/^/| /' conftest.$ac_ext >&5
20999
503d2be0 21000ac_cv_type_size_t=no
8730a8da 21001fi
35996d22 21002rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8730a8da 21003fi
c0d27fcc 21004echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
21005echo "${ECHO_T}$ac_cv_type_size_t" >&6
21006if test $ac_cv_type_size_t = yes; then
503d2be0 21007
c0d27fcc
MR
21008cat >>confdefs.h <<_ACEOF
21009#define HAVE_SIZE_T 1
21010_ACEOF
21011
8730a8da
DL
21012
21013fi
21014
c0d27fcc 21015
973a76b1
DL
21016echo "$as_me:$LINENO: checking for mbstate_t" >&5
21017echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
21018if test "${ac_cv_type_mbstate_t+set}" = set; then
21019 echo $ECHO_N "(cached) $ECHO_C" >&6
21020else
21021 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21022/* confdefs.h. */
21023_ACEOF
21024cat confdefs.h >>conftest.$ac_ext
21025cat >>conftest.$ac_ext <<_ACEOF
21026/* end confdefs.h. */
973a76b1
DL
21027$ac_includes_default
21028# include <wchar.h>
21029int
21030main ()
21031{
21032mbstate_t x; return sizeof x;
21033 ;
21034 return 0;
21035}
21036_ACEOF
21037rm -f conftest.$ac_objext
21038if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21039 (eval $ac_compile) 2>conftest.er1
973a76b1 21040 ac_status=$?
35996d22
AS
21041 grep -v '^ *+' conftest.er1 >conftest.err
21042 rm -f conftest.er1
21043 cat conftest.err >&5
973a76b1
DL
21044 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21045 (exit $ac_status); } &&
4494a266
JD
21046 { ac_try='test -z "$ac_c_werror_flag"
21047 || test ! -s conftest.err'
35996d22
AS
21048 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21049 (eval $ac_try) 2>&5
21050 ac_status=$?
21051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21052 (exit $ac_status); }; } &&
21053 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
21054 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21055 (eval $ac_try) 2>&5
21056 ac_status=$?
21057 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21058 (exit $ac_status); }; }; then
21059 ac_cv_type_mbstate_t=yes
21060else
21061 echo "$as_me: failed program was:" >&5
19650fd6
AS
21062sed 's/^/| /' conftest.$ac_ext >&5
21063
973a76b1
DL
21064ac_cv_type_mbstate_t=no
21065fi
35996d22 21066rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
21067fi
21068echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
21069echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6
21070 if test $ac_cv_type_mbstate_t = yes; then
21071
21072cat >>confdefs.h <<\_ACEOF
21073#define HAVE_MBSTATE_T 1
21074_ACEOF
21075
21076 else
21077
21078cat >>confdefs.h <<\_ACEOF
21079#define mbstate_t int
21080_ACEOF
21081
21082 fi
21083
22044edf
DL
21084echo "$as_me:$LINENO: checking for C restrict keyword" >&5
21085echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
21086if test "${emacs_cv_c_restrict+set}" = set; then
21087 echo $ECHO_N "(cached) $ECHO_C" >&6
21088else
21089 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21090/* confdefs.h. */
21091_ACEOF
21092cat confdefs.h >>conftest.$ac_ext
21093cat >>conftest.$ac_ext <<_ACEOF
21094/* end confdefs.h. */
22044edf
DL
21095void fred (int *restrict x);
21096int
21097main ()
21098{
b936fae4 21099
22044edf
DL
21100 ;
21101 return 0;
21102}
c0d27fcc 21103_ACEOF
22044edf
DL
21104rm -f conftest.$ac_objext
21105if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21106 (eval $ac_compile) 2>conftest.er1
22044edf 21107 ac_status=$?
35996d22
AS
21108 grep -v '^ *+' conftest.er1 >conftest.err
21109 rm -f conftest.er1
21110 cat conftest.err >&5
22044edf
DL
21111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21112 (exit $ac_status); } &&
4494a266
JD
21113 { ac_try='test -z "$ac_c_werror_flag"
21114 || test ! -s conftest.err'
35996d22
AS
21115 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21116 (eval $ac_try) 2>&5
21117 ac_status=$?
21118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21119 (exit $ac_status); }; } &&
21120 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21121 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21122 (eval $ac_try) 2>&5
21123 ac_status=$?
21124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21125 (exit $ac_status); }; }; then
21126 emacs_cv_c_restrict=yes
21127else
21128 echo "$as_me: failed program was:" >&5
19650fd6
AS
21129sed 's/^/| /' conftest.$ac_ext >&5
21130
22044edf 21131cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21132/* confdefs.h. */
21133_ACEOF
21134cat confdefs.h >>conftest.$ac_ext
21135cat >>conftest.$ac_ext <<_ACEOF
21136/* end confdefs.h. */
22044edf
DL
21137void fred (int *__restrict x);
21138int
21139main ()
21140{
c0d27fcc 21141
22044edf
DL
21142 ;
21143 return 0;
21144}
c0d27fcc 21145_ACEOF
22044edf
DL
21146rm -f conftest.$ac_objext
21147if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21148 (eval $ac_compile) 2>conftest.er1
22044edf 21149 ac_status=$?
35996d22
AS
21150 grep -v '^ *+' conftest.er1 >conftest.err
21151 rm -f conftest.er1
21152 cat conftest.err >&5
22044edf
DL
21153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21154 (exit $ac_status); } &&
4494a266
JD
21155 { ac_try='test -z "$ac_c_werror_flag"
21156 || test ! -s conftest.err'
35996d22
AS
21157 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21158 (eval $ac_try) 2>&5
21159 ac_status=$?
21160 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21161 (exit $ac_status); }; } &&
21162 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21163 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21164 (eval $ac_try) 2>&5
21165 ac_status=$?
21166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21167 (exit $ac_status); }; }; then
21168 emacs_cv_c_restrict=__restrict
21169else
21170 echo "$as_me: failed program was:" >&5
19650fd6
AS
21171sed 's/^/| /' conftest.$ac_ext >&5
21172
22044edf 21173emacs_cv_c_restrict=no
ba4481b5 21174fi
35996d22 21175rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21176fi
35996d22 21177rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
ba4481b5 21178fi
22044edf
DL
21179echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
21180echo "${ECHO_T}$emacs_cv_c_restrict" >&6
21181case "$emacs_cv_c_restrict" in
21182 yes) emacs_restrict=restrict;;
21183 no) emacs_restrict="";;
21184 *) emacs_restrict="$emacs_cv_c_restrict";;
21185esac
21186if test "$emacs_restrict" != __restrict; then
b936fae4 21187
22044edf
DL
21188cat >>confdefs.h <<_ACEOF
21189#define __restrict $emacs_restrict
c0d27fcc 21190_ACEOF
ba4481b5
DL
21191
21192fi
ba4481b5 21193
22044edf
DL
21194echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
21195echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
21196if test "${emacs_cv_c_restrict_arr+set}" = set; then
21197 echo $ECHO_N "(cached) $ECHO_C" >&6
21198else
21199 cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21200/* confdefs.h. */
21201_ACEOF
21202cat confdefs.h >>conftest.$ac_ext
21203cat >>conftest.$ac_ext <<_ACEOF
21204/* end confdefs.h. */
22044edf
DL
21205void fred (int x[__restrict]);
21206int
21207main ()
21208{
b936fae4 21209
22044edf
DL
21210 ;
21211 return 0;
21212}
c0d27fcc 21213_ACEOF
22044edf
DL
21214rm -f conftest.$ac_objext
21215if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
35996d22 21216 (eval $ac_compile) 2>conftest.er1
22044edf 21217 ac_status=$?
35996d22
AS
21218 grep -v '^ *+' conftest.er1 >conftest.err
21219 rm -f conftest.er1
21220 cat conftest.err >&5
22044edf
DL
21221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21222 (exit $ac_status); } &&
4494a266
JD
21223 { ac_try='test -z "$ac_c_werror_flag"
21224 || test ! -s conftest.err'
35996d22
AS
21225 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21226 (eval $ac_try) 2>&5
21227 ac_status=$?
21228 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21229 (exit $ac_status); }; } &&
21230 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
21231 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21232 (eval $ac_try) 2>&5
21233 ac_status=$?
21234 echo "$as_me:$LINENO: \$? = $ac_status" >&5
21235 (exit $ac_status); }; }; then
21236 emacs_cv_c_restrict_arr=yes
21237else
21238 echo "$as_me: failed program was:" >&5
19650fd6
AS
21239sed 's/^/| /' conftest.$ac_ext >&5
21240
22044edf 21241emacs_cv_c_restrict_arr=no
ba4481b5 21242fi
35996d22 21243rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22044edf
DL
21244fi
21245echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
21246echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
21247if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 21248
c0d27fcc 21249cat >>confdefs.h <<\_ACEOF
22044edf 21250#define __restrict_arr __restrict
c0d27fcc 21251_ACEOF
ba4481b5 21252
ba4481b5
DL
21253fi
21254
c0d27fcc 21255
c0d27fcc 21256
22044edf
DL
21257# Set up the CFLAGS for real compilation, so we can substitute it.
21258CFLAGS="$REAL_CFLAGS"
21259CPPFLAGS="$REAL_CPPFLAGS"
21260
21261#### Find out which version of Emacs this is.
21262version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
21263 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
21264if test x"${version}" = x; then
21265 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
21266echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
21267 { (exit 1); exit 1; }; }
21268fi
21269
21270### Specify what sort of things we'll be editing into Makefile and config.h.
21271### Use configuration here uncanonicalized to avoid exceeding size limits.
21272
21273
21274
21275
21276
21277
21278
21279
21280
21281
21282
21283
21284
21285
21286
21287
21288
21289
21290
21291
21292
21293
21294
21295
21296
21297
21298
21299
21300
21301
21302
21303
6a3a24fa 21304
22044edf
DL
21305
21306
21307cat >>confdefs.h <<_ACEOF
21308#define EMACS_CONFIGURATION "${canonical}"
21309_ACEOF
21310
21311
21312cat >>confdefs.h <<_ACEOF
21313#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
21314_ACEOF
21315
21316
21317cat >>confdefs.h <<_ACEOF
21318#define config_machfile "${machfile}"
21319_ACEOF
21320
21321
21322cat >>confdefs.h <<_ACEOF
21323#define config_opsysfile "${opsysfile}"
21324_ACEOF
21325
21326
21327cat >>confdefs.h <<_ACEOF
21328#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
21329_ACEOF
21330
21331
21332cat >>confdefs.h <<_ACEOF
21333#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
21334_ACEOF
21335
21336
21337cat >>confdefs.h <<_ACEOF
21338#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
21339_ACEOF
21340
21341
21342cat >>confdefs.h <<_ACEOF
21343#define UNEXEC_SRC ${UNEXEC_SRC}
21344_ACEOF
21345
21346
21347if test "${HAVE_X_WINDOWS}" = "yes" ; then
21348
21349cat >>confdefs.h <<\_ACEOF
21350#define HAVE_X_WINDOWS 1
21351_ACEOF
21352
21353fi
21354if test "${USE_X_TOOLKIT}" != "none" ; then
21355
21356cat >>confdefs.h <<\_ACEOF
21357#define USE_X_TOOLKIT 1
21358_ACEOF
21359
21360fi
21361if test "${HAVE_X11}" = "yes" ; then
21362
21363cat >>confdefs.h <<\_ACEOF
21364#define HAVE_X11 1
21365_ACEOF
21366
21367fi
21368if test "${HAVE_XFREE386}" = "yes" ; then
21369
21370cat >>confdefs.h <<\_ACEOF
21371#define HAVE_XFREE386 1
21372_ACEOF
21373
21374fi
21375if test "${HAVE_MENUS}" = "yes" ; then
21376
21377cat >>confdefs.h <<\_ACEOF
21378#define HAVE_MENUS 1
21379_ACEOF
21380
21381fi
21382if test "${GNU_MALLOC}" = "yes" ; then
21383
21384cat >>confdefs.h <<\_ACEOF
21385#define GNU_MALLOC 1
21386_ACEOF
21387
21388fi
21389if test "${REL_ALLOC}" = "yes" ; then
21390
21391cat >>confdefs.h <<\_ACEOF
21392#define REL_ALLOC 1
21393_ACEOF
21394
21395fi
21396
21397
21398
c0d27fcc
MR
21399
21400
ba4481b5 21401#### Report on what we decided to do.
488dd4c4
JD
21402#### Report GTK as a toolkit, even if it doesn't use Xt.
21403#### It makes printing result more understandable as using GTK sets
21404#### toolkit_scroll_bars to yes by default.
21405if test "${HAVE_GTK}" = "yes"; then
21406 USE_X_TOOLKIT=GTK
21407fi
21408
ba4481b5
DL
21409echo "
21410Configured for \`${canonical}'.
21411
21412 Where should the build process find the source code? ${srcdir}
21413 What operating system and machine description files should Emacs use?
21414 \`${opsysfile}' and \`${machfile}'
21415 What compiler should emacs be built with? ${CC} ${CFLAGS}
21416 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 21417 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 21418 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 21419 What window system should Emacs use? ${window_system}
8e967cf7 21420 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
21421
21422if test -n "${x_includes}"; then
21423echo " Where do we find X Windows header files? ${x_includes}"
21424else
21425echo " Where do we find X Windows header files? Standard dirs"
21426fi
21427if test -n "${x_libraries}"; then
21428echo " Where do we find X Windows libraries? ${x_libraries}"
21429else
21430echo " Where do we find X Windows libraries? Standard dirs"
21431fi
21432
21433echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
21434echo " Does Emacs use -lXpm? ${HAVE_XPM}"
21435echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
21436echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
21437echo " Does Emacs use -lungif? ${HAVE_GIF}"
21438echo " Does Emacs use -lpng? ${HAVE_PNG}"
21439echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
21440echo
21441
21442# Remove any trailing slashes in these variables.
21443test "${prefix}" != NONE &&
21444 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
21445test "${exec_prefix}" != NONE &&
21446 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
21447
d0e9bfd2
GM
21448## Check if the C preprocessor will convert `..' to `. .'. If so, set
21449## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
21450## from Makefile.c can correctly provide the arg `-traditional' to the
21451## C preprocessor.
21452
503d2be0 21453cat >conftest.$ac_ext <<_ACEOF
19650fd6
AS
21454/* confdefs.h. */
21455_ACEOF
21456cat confdefs.h >>conftest.$ac_ext
21457cat >>conftest.$ac_ext <<_ACEOF
21458/* end confdefs.h. */
d0e9bfd2 21459yes..yes
503d2be0 21460_ACEOF
d0e9bfd2 21461if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 21462 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
21463 CPP_NEED_TRADITIONAL=no
21464else
d0e9bfd2
GM
21465 CPP_NEED_TRADITIONAL=yes
21466fi
21467rm -f conftest*
21468
c0d27fcc 21469
6bae0ccf
DL
21470 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"
21471 ac_config_commands="$ac_config_commands default"
503d2be0 21472cat >confcache <<\_ACEOF
ba4481b5
DL
21473# This file is a shell script that caches the results of configure
21474# tests run on this system so they can be shared between configure
503d2be0
AS
21475# scripts and configure runs, see configure's option --config-cache.
21476# It is not useful on other systems. If it contains results you don't
21477# want to keep, you may remove or edit it.
ba4481b5 21478#
503d2be0
AS
21479# config.status only pays attention to the cache file if you give it
21480# the --recheck option to rerun configure.
ba4481b5 21481#
6bae0ccf 21482# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
21483# loading this file, other *unset* `ac_cv_foo' will be assigned the
21484# following values.
21485
21486_ACEOF
21487
ba4481b5
DL
21488# The following way of writing the cache mishandles newlines in values,
21489# but we know of no workaround that is simple, portable, and efficient.
21490# So, don't put newlines in cache variables' values.
21491# Ultrix sh set writes to stderr and can't be redirected directly,
21492# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
21493{
21494 (set) 2>&1 |
21495 case `(ac_space=' '; set | grep ac_space) 2>&1` in
21496 *ac_space=\ *)
21497 # `set' does not quote correctly, so add quotes (double-quote
21498 # substitution turns \\\\ into \\, and sed turns \\ into \).
21499 sed -n \
35996d22
AS
21500 "s/'/'\\\\''/g;
21501 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
503d2be0
AS
21502 ;;
21503 *)
21504 # `set' quotes correctly as required by POSIX, so do not add quotes.
21505 sed -n \
35996d22 21506 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
21507 ;;
21508 esac;
21509} |
21510 sed '
21511 t clear
21512 : clear
21513 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21514 t end
21515 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21516 : end' >>confcache
19650fd6 21517if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 21518 if test -w $cache_file; then
503d2be0
AS
21519 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
21520 cat confcache >$cache_file
ba4481b5
DL
21521 else
21522 echo "not updating unwritable cache $cache_file"
21523 fi
21524fi
21525rm -f confcache
21526
ba4481b5
DL
21527test "x$prefix" = xNONE && prefix=$ac_default_prefix
21528# Let make expand exec_prefix.
21529test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21530
503d2be0
AS
21531# VPATH may cause trouble with some makes, so we remove $(srcdir),
21532# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
21533# trailing colons and then remove the whole line if VPATH becomes empty
21534# (actually we leave an empty line to preserve line numbers).
ba4481b5 21535if test "x$srcdir" = x.; then
35996d22 21536 ac_vpsub='/^[ ]*VPATH[ ]*=/{
503d2be0
AS
21537s/:*\$(srcdir):*/:/;
21538s/:*\${srcdir}:*/:/;
21539s/:*@srcdir@:*/:/;
35996d22 21540s/^\([^=]*=[ ]*\):*/\1/;
503d2be0 21541s/:*$//;
35996d22 21542s/^[^=]*=[ ]*$//;
503d2be0 21543}'
ba4481b5
DL
21544fi
21545
ba4481b5
DL
21546DEFS=-DHAVE_CONFIG_H
21547
6bae0ccf
DL
21548ac_libobjs=
21549ac_ltlibobjs=
21550for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21551 # 1. Remove the extension, and $U if already installed.
21552 ac_i=`echo "$ac_i" |
35996d22 21553 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
6bae0ccf
DL
21554 # 2. Add them.
21555 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
21556 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
21557done
21558LIBOBJS=$ac_libobjs
21559
21560LTLIBOBJS=$ac_ltlibobjs
21561
21562
c0d27fcc 21563
ba4481b5 21564: ${CONFIG_STATUS=./config.status}
503d2be0
AS
21565ac_clean_files_save=$ac_clean_files
21566ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 21567{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
21568echo "$as_me: creating $CONFIG_STATUS" >&6;}
21569cat >$CONFIG_STATUS <<_ACEOF
21570#! $SHELL
c0d27fcc 21571# Generated by $as_me.
ba4481b5 21572# Run this file to recreate the current configuration.
ba4481b5 21573# Compiler output produced by configure, useful for debugging
503d2be0 21574# configure, is in config.log if it exists.
ba4481b5 21575
503d2be0 21576debug=false
19650fd6
AS
21577ac_cs_recheck=false
21578ac_cs_silent=false
503d2be0 21579SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
21580_ACEOF
21581
21582cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
21583## --------------------- ##
21584## M4sh Initialization. ##
21585## --------------------- ##
21586
503d2be0
AS
21587# Be Bourne compatible
21588if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
21589 emulate sh
21590 NULLCMD=:
6bae0ccf
DL
21591 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21592 # is contrary to our usage. Disable this feature.
21593 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
21594elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21595 set -o posix
21596fi
35996d22 21597DUALCASE=1; export DUALCASE # for MKS sh
503d2be0 21598
c0d27fcc 21599# Support unset when possible.
35996d22 21600if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
c0d27fcc
MR
21601 as_unset=unset
21602else
21603 as_unset=false
21604fi
21605
6bae0ccf
DL
21606
21607# Work around bugs in pre-3.0 UWIN ksh.
21608$as_unset ENV MAIL MAILPATH
21609PS1='$ '
21610PS2='> '
21611PS4='+ '
21612
21613# NLS nuisances.
19650fd6
AS
21614for as_var in \
21615 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
21616 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
21617 LC_TELEPHONE LC_TIME
6bae0ccf 21618do
35996d22 21619 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
21620 eval $as_var=C; export $as_var
21621 else
21622 $as_unset $as_var
21623 fi
21624done
21625
21626# Required to use basename.
21627if expr a : '\(a\)' >/dev/null 2>&1; then
21628 as_expr=expr
21629else
21630 as_expr=false
21631fi
21632
21633if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
21634 as_basename=basename
21635else
21636 as_basename=false
21637fi
c0d27fcc
MR
21638
21639
503d2be0 21640# Name of the executable.
6bae0ccf 21641as_me=`$as_basename "$0" ||
c0d27fcc
MR
21642$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21643 X"$0" : 'X\(//\)$' \| \
21644 X"$0" : 'X\(/\)$' \| \
21645 . : '\(.\)' 2>/dev/null ||
21646echo X/"$0" |
21647 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
21648 /^X\/\(\/\/\)$/{ s//\1/; q; }
21649 /^X\/\(\/\).*/{ s//\1/; q; }
21650 s/.*/./; q'`
21651
6bae0ccf 21652
c0d27fcc
MR
21653# PATH needs CR, and LINENO needs CR and PATH.
21654# Avoid depending upon Character Ranges.
21655as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21656as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21657as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21658as_cr_digits='0123456789'
21659as_cr_alnum=$as_cr_Letters$as_cr_digits
21660
21661# The user is always right.
21662if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
21663 echo "#! /bin/sh" >conf$$.sh
21664 echo "exit 0" >>conf$$.sh
21665 chmod +x conf$$.sh
21666 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
21667 PATH_SEPARATOR=';'
21668 else
21669 PATH_SEPARATOR=:
21670 fi
19650fd6 21671 rm -f conf$$.sh
c0d27fcc
MR
21672fi
21673
21674
21675 as_lineno_1=$LINENO
21676 as_lineno_2=$LINENO
21677 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21678 test "x$as_lineno_1" != "x$as_lineno_2" &&
21679 test "x$as_lineno_3" = "x$as_lineno_2" || {
21680 # Find who we are. Look in the path if we contain no path at all
21681 # relative or not.
21682 case $0 in
21683 *[\\/]* ) as_myself=$0 ;;
21684 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21685for as_dir in $PATH
21686do
21687 IFS=$as_save_IFS
21688 test -z "$as_dir" && as_dir=.
21689 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21690done
21691
21692 ;;
21693 esac
21694 # We did not find ourselves, most probably we were run as `sh COMMAND'
21695 # in which case we are not to be found in the path.
21696 if test "x$as_myself" = x; then
21697 as_myself=$0
21698 fi
21699 if test ! -f "$as_myself"; then
21700 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
21701echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
21702 { (exit 1); exit 1; }; }
21703 fi
21704 case $CONFIG_SHELL in
21705 '')
21706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21707for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
21708do
21709 IFS=$as_save_IFS
21710 test -z "$as_dir" && as_dir=.
21711 for as_base in sh bash ksh sh5; do
21712 case $as_dir in
21713 /*)
21714 if ("$as_dir/$as_base" -c '
21715 as_lineno_1=$LINENO
21716 as_lineno_2=$LINENO
21717 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
21718 test "x$as_lineno_1" != "x$as_lineno_2" &&
21719 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
21720 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
21721 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
21722 CONFIG_SHELL=$as_dir/$as_base
21723 export CONFIG_SHELL
21724 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
21725 fi;;
21726 esac
21727 done
21728done
21729;;
21730 esac
21731
21732 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
21733 # uniformly replaced by the line number. The first 'sed' inserts a
21734 # line-number line before each line; the second 'sed' does the real
21735 # work. The second script uses 'N' to pair each line-number line
21736 # with the numbered line, and appends trailing '-' during
21737 # substitution so that $LINENO is not a special case at line end.
21738 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
21739 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
21740 sed '=' <$as_myself |
21741 sed '
21742 N
21743 s,$,-,
21744 : loop
21745 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
21746 t loop
21747 s,-$,,
21748 s,^['$as_cr_digits']*\n,,
21749 ' >$as_me.lineno &&
21750 chmod +x $as_me.lineno ||
21751 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
21752echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
21753 { (exit 1); exit 1; }; }
21754
21755 # Don't try to exec as it changes $[0], causing all sort of problems
21756 # (the dirname of $[0] is not the place where we might find the
21757 # original and so on. Autoconf is especially sensible to this).
21758 . ./$as_me.lineno
21759 # Exit status is that of the last command.
21760 exit
21761}
21762
21763
21764case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
21765 *c*,-n*) ECHO_N= ECHO_C='
21766' ECHO_T=' ' ;;
21767 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
21768 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
21769esac
503d2be0
AS
21770
21771if expr a : '\(a\)' >/dev/null 2>&1; then
21772 as_expr=expr
21773else
21774 as_expr=false
21775fi
21776
21777rm -f conf$$ conf$$.exe conf$$.file
21778echo >conf$$.file
21779if ln -s conf$$.file conf$$ 2>/dev/null; then
21780 # We could just check for DJGPP; but this test a) works b) is more generic
21781 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
21782 if test -f conf$$.exe; then
21783 # Don't use ln at all; we don't have any links
21784 as_ln_s='cp -p'
21785 else
21786 as_ln_s='ln -s'
21787 fi
21788elif ln conf$$.file conf$$ 2>/dev/null; then
21789 as_ln_s=ln
21790else
21791 as_ln_s='cp -p'
21792fi
21793rm -f conf$$ conf$$.exe conf$$.file
21794
6bae0ccf
DL
21795if mkdir -p . 2>/dev/null; then
21796 as_mkdir_p=:
21797else
35996d22 21798 test -d ./-p && rmdir ./-p
6bae0ccf
DL
21799 as_mkdir_p=false
21800fi
21801
503d2be0
AS
21802as_executable_p="test -f"
21803
c0d27fcc 21804# Sed expression to map a string onto a valid CPP name.
35996d22 21805as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
c0d27fcc
MR
21806
21807# Sed expression to map a string onto a valid variable name.
35996d22 21808as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
503d2be0 21809
503d2be0
AS
21810
21811# IFS
21812# We need space, tab and new line, in precisely that order.
21813as_nl='
21814'
21815IFS=" $as_nl"
21816
21817# CDPATH.
6bae0ccf 21818$as_unset CDPATH
503d2be0
AS
21819
21820exec 6>&1
21821
c0d27fcc
MR
21822# Open the log real soon, to keep \$[0] and so on meaningful, and to
21823# report actual input values of CONFIG_FILES etc. instead of their
21824# values after options handling. Logging --version etc. is OK.
21825exec 5>>config.log
21826{
21827 echo
21828 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
21829## Running $as_me. ##
21830_ASBOX
21831} >&5
21832cat >&5 <<_CSEOF
21833
21834This file was extended by $as_me, which was
35996d22 21835generated by GNU Autoconf 2.59. Invocation command line was
c0d27fcc
MR
21836
21837 CONFIG_FILES = $CONFIG_FILES
21838 CONFIG_HEADERS = $CONFIG_HEADERS
21839 CONFIG_LINKS = $CONFIG_LINKS
21840 CONFIG_COMMANDS = $CONFIG_COMMANDS
21841 $ $0 $@
21842
21843_CSEOF
21844echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
21845echo >&5
503d2be0
AS
21846_ACEOF
21847
21848# Files that config.status was made for.
21849if test -n "$ac_config_files"; then
21850 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
21851fi
21852
21853if test -n "$ac_config_headers"; then
21854 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
21855fi
21856
21857if test -n "$ac_config_links"; then
21858 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
21859fi
21860
21861if test -n "$ac_config_commands"; then
21862 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
21863fi
21864
c0d27fcc 21865cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21866
21867ac_cs_usage="\
21868\`$as_me' instantiates files from templates according to the
21869current configuration.
21870
21871Usage: $0 [OPTIONS] [FILE]...
21872
21873 -h, --help print this help, then exit
21874 -V, --version print version number, then exit
19650fd6 21875 -q, --quiet do not print progress messages
503d2be0
AS
21876 -d, --debug don't remove temporary files
21877 --recheck update $as_me by reconfiguring in the same conditions
21878 --file=FILE[:TEMPLATE]
35996d22 21879 instantiate the configuration file FILE
503d2be0 21880 --header=FILE[:TEMPLATE]
35996d22 21881 instantiate the configuration header FILE
503d2be0
AS
21882
21883Configuration files:
21884$config_files
21885
21886Configuration headers:
21887$config_headers
21888
21889Configuration commands:
21890$config_commands
21891
21892Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 21893_ACEOF
503d2be0 21894
c0d27fcc 21895cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21896ac_cs_version="\\
21897config.status
35996d22 21898configured by $0, generated by GNU Autoconf 2.59,
503d2be0
AS
21899 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
21900
35996d22 21901Copyright (C) 2003 Free Software Foundation, Inc.
503d2be0
AS
21902This config.status script is free software; the Free Software Foundation
21903gives unlimited permission to copy, distribute and modify it."
21904srcdir=$srcdir
21905INSTALL="$INSTALL"
c0d27fcc 21906_ACEOF
503d2be0 21907
c0d27fcc 21908cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21909# If no file are specified by the user, then we need to provide default
21910# value. By we need to know if files were specified by the user.
21911ac_need_defaults=:
21912while test $# != 0
ba4481b5 21913do
503d2be0
AS
21914 case $1 in
21915 --*=*)
21916 ac_option=`expr "x$1" : 'x\([^=]*\)='`
21917 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
21918 ac_shift=:
21919 ;;
21920 -*)
21921 ac_option=$1
21922 ac_optarg=$2
21923 ac_shift=shift
503d2be0 21924 ;;
503d2be0
AS
21925 *) # This is not an option, so the user has probably given explicit
21926 # arguments.
6bae0ccf 21927 ac_option=$1
503d2be0
AS
21928 ac_need_defaults=false;;
21929 esac
21930
6bae0ccf 21931 case $ac_option in
503d2be0 21932 # Handling of the options.
c0d27fcc 21933_ACEOF
f57bd967 21934cat >>$CONFIG_STATUS <<\_ACEOF
19650fd6
AS
21935 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
21936 ac_cs_recheck=: ;;
503d2be0
AS
21937 --version | --vers* | -V )
21938 echo "$ac_cs_version"; exit 0 ;;
21939 --he | --h)
21940 # Conflict between --help and --header
c0d27fcc 21941 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
21942Try \`$0 --help' for more information." >&5
21943echo "$as_me: error: ambiguous option: $1
21944Try \`$0 --help' for more information." >&2;}
21945 { (exit 1); exit 1; }; };;
21946 --help | --hel | -h )
21947 echo "$ac_cs_usage"; exit 0 ;;
21948 --debug | --d* | -d )
21949 debug=: ;;
21950 --file | --fil | --fi | --f )
6bae0ccf
DL
21951 $ac_shift
21952 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
21953 ac_need_defaults=false;;
21954 --header | --heade | --head | --hea )
6bae0ccf
DL
21955 $ac_shift
21956 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 21957 ac_need_defaults=false;;
19650fd6
AS
21958 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
21959 | -silent | --silent | --silen | --sile | --sil | --si | --s)
21960 ac_cs_silent=: ;;
503d2be0
AS
21961
21962 # This is an error.
c0d27fcc 21963 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
21964Try \`$0 --help' for more information." >&5
21965echo "$as_me: error: unrecognized option: $1
21966Try \`$0 --help' for more information." >&2;}
21967 { (exit 1); exit 1; }; } ;;
21968
21969 *) ac_config_targets="$ac_config_targets $1" ;;
21970
ba4481b5 21971 esac
503d2be0 21972 shift
ba4481b5
DL
21973done
21974
19650fd6
AS
21975ac_configure_extra_args=
21976
21977if $ac_cs_silent; then
21978 exec 6>/dev/null
21979 ac_configure_extra_args="$ac_configure_extra_args --silent"
21980fi
21981
21982_ACEOF
21983cat >>$CONFIG_STATUS <<_ACEOF
21984if \$ac_cs_recheck; then
21985 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
21986 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
21987fi
21988
503d2be0 21989_ACEOF
ba4481b5 21990
c0d27fcc 21991cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21992#
21993# INIT-COMMANDS section.
21994#
ba4481b5 21995
503d2be0
AS
21996GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
21997
c0d27fcc
MR
21998_ACEOF
21999
503d2be0 22000
c0d27fcc
MR
22001
22002cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22003for ac_config_target in $ac_config_targets
22004do
22005 case "$ac_config_target" in
22006 # Handling of arguments.
22007 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
22008 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
22009 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
22010 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
22011 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
22012 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
22013 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 22014 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 22015 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
22016 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
22017 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
22018 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 22019 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
22020echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
22021 { (exit 1); exit 1; }; };;
22022 esac
ba4481b5 22023done
503d2be0
AS
22024
22025# If the user did not use the arguments to specify the items to instantiate,
22026# then the envvar interface is used. Set only those that are not.
22027# We use the long form for the default assignment because of an extremely
22028# bizarre bug on SunOS 4.1.3.
22029if $ac_need_defaults; then
22030 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22031 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22032 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 22033fi
503d2be0 22034
19650fd6
AS
22035# Have a temporary directory for convenience. Make it in the build tree
22036# simply because there is no reason to put it here, and in addition,
22037# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
22038# Create a temporary directory, and hook for its removal unless debugging.
22039$debug ||
22040{
22041 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
22042 trap '{ (exit 1); exit 1; }' 1 2 13 15
22043}
22044
22045# Create a (secure) tmp directory for tmp files.
19650fd6 22046
503d2be0 22047{
19650fd6 22048 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
22049 test -n "$tmp" && test -d "$tmp"
22050} ||
22051{
19650fd6 22052 tmp=./confstat$$-$RANDOM
503d2be0
AS
22053 (umask 077 && mkdir $tmp)
22054} ||
22055{
19650fd6 22056 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
22057 { (exit 1); exit 1; }
22058}
22059
c0d27fcc 22060_ACEOF
503d2be0 22061
c0d27fcc 22062cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
22063
22064#
22065# CONFIG_FILES section.
22066#
22067
22068# No need to generate the scripts if there are no CONFIG_FILES.
22069# This happens for instance when ./config.status config.h
22070if test -n "\$CONFIG_FILES"; then
22071 # Protect against being on the right side of a sed subst in config.status.
22072 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
22073 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
22074s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
22075s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
22076s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
22077s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
22078s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
22079s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
22080s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
22081s,@exec_prefix@,$exec_prefix,;t t
22082s,@prefix@,$prefix,;t t
22083s,@program_transform_name@,$program_transform_name,;t t
22084s,@bindir@,$bindir,;t t
22085s,@sbindir@,$sbindir,;t t
22086s,@libexecdir@,$libexecdir,;t t
22087s,@datadir@,$datadir,;t t
22088s,@sysconfdir@,$sysconfdir,;t t
22089s,@sharedstatedir@,$sharedstatedir,;t t
22090s,@localstatedir@,$localstatedir,;t t
22091s,@libdir@,$libdir,;t t
22092s,@includedir@,$includedir,;t t
22093s,@oldincludedir@,$oldincludedir,;t t
22094s,@infodir@,$infodir,;t t
22095s,@mandir@,$mandir,;t t
503d2be0
AS
22096s,@build_alias@,$build_alias,;t t
22097s,@host_alias@,$host_alias,;t t
22098s,@target_alias@,$target_alias,;t t
c0d27fcc 22099s,@DEFS@,$DEFS,;t t
503d2be0
AS
22100s,@ECHO_C@,$ECHO_C,;t t
22101s,@ECHO_N@,$ECHO_N,;t t
22102s,@ECHO_T@,$ECHO_T,;t t
503d2be0 22103s,@LIBS@,$LIBS,;t t
19650fd6 22104s,@MAINT@,$MAINT,;t t
503d2be0
AS
22105s,@build@,$build,;t t
22106s,@build_cpu@,$build_cpu,;t t
22107s,@build_vendor@,$build_vendor,;t t
22108s,@build_os@,$build_os,;t t
22109s,@host@,$host,;t t
22110s,@host_cpu@,$host_cpu,;t t
22111s,@host_vendor@,$host_vendor,;t t
22112s,@host_os@,$host_os,;t t
22113s,@CC@,$CC,;t t
22114s,@CFLAGS@,$CFLAGS,;t t
22115s,@LDFLAGS@,$LDFLAGS,;t t
22116s,@CPPFLAGS@,$CPPFLAGS,;t t
22117s,@ac_ct_CC@,$ac_ct_CC,;t t
22118s,@EXEEXT@,$EXEEXT,;t t
22119s,@OBJEXT@,$OBJEXT,;t t
22120s,@LN_S@,$LN_S,;t t
22121s,@CPP@,$CPP,;t t
22122s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
22123s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
22124s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
22125s,@RANLIB@,$RANLIB,;t t
22126s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 22127s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 22128s,@EGREP@,$EGREP,;t t
503d2be0 22129s,@LIBSOUND@,$LIBSOUND,;t t
4494a266 22130s,@SETARCH@,$SETARCH,;t t
503d2be0 22131s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
22132s,@PKG_CONFIG@,$PKG_CONFIG,;t t
22133s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
22134s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
22135s,@ALLOCA@,$ALLOCA,;t t
22136s,@liblockfile@,$liblockfile,;t t
22137s,@LIBOBJS@,$LIBOBJS,;t t
22138s,@NEED_SETGID@,$NEED_SETGID,;t t
22139s,@KMEM_GROUP@,$KMEM_GROUP,;t t
22140s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
22141s,@version@,$version,;t t
22142s,@configuration@,$configuration,;t t
22143s,@canonical@,$canonical,;t t
22144s,@srcdir@,$srcdir,;t t
22145s,@lispdir@,$lispdir,;t t
22146s,@locallisppath@,$locallisppath,;t t
22147s,@lisppath@,$lisppath,;t t
22148s,@x_default_search_path@,$x_default_search_path,;t t
22149s,@etcdir@,$etcdir,;t t
22150s,@archlibdir@,$archlibdir,;t t
22151s,@docdir@,$docdir,;t t
22152s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
22153s,@gamedir@,$gamedir,;t t
22154s,@gameuser@,$gameuser,;t t
503d2be0
AS
22155s,@c_switch_system@,$c_switch_system,;t t
22156s,@c_switch_machine@,$c_switch_machine,;t t
22157s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
22158s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
22159s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
22160s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
22161s,@machfile@,$machfile,;t t
22162s,@opsysfile@,$opsysfile,;t t
6a3a24fa 22163s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 22164s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
22165CEOF
22166
c0d27fcc 22167_ACEOF
ba4481b5 22168
c0d27fcc 22169 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22170 # Split the substitutions into bite-sized pieces for seds with
22171 # small command number limits, like on Digital OSF/1 and HP-UX.
22172 ac_max_sed_lines=48
22173 ac_sed_frag=1 # Number of current file.
22174 ac_beg=1 # First line for current file.
22175 ac_end=$ac_max_sed_lines # Line after last line for current file.
22176 ac_more_lines=:
22177 ac_sed_cmds=
22178 while $ac_more_lines; do
22179 if test $ac_beg -gt 1; then
22180 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22181 else
22182 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22183 fi
22184 if test ! -s $tmp/subs.frag; then
22185 ac_more_lines=false
22186 else
22187 # The purpose of the label and of the branching condition is to
22188 # speed up the sed processing (if there are no `@' at all, there
22189 # is no need to browse any of the substitutions).
22190 # These are the two extra sed commands mentioned above.
22191 (echo ':t
22192 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22193 if test -z "$ac_sed_cmds"; then
35996d22 22194 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0 22195 else
35996d22 22196 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0
AS
22197 fi
22198 ac_sed_frag=`expr $ac_sed_frag + 1`
22199 ac_beg=$ac_end
22200 ac_end=`expr $ac_end + $ac_max_sed_lines`
22201 fi
22202 done
22203 if test -z "$ac_sed_cmds"; then
22204 ac_sed_cmds=cat
22205 fi
22206fi # test -n "$CONFIG_FILES"
ba4481b5 22207
c0d27fcc
MR
22208_ACEOF
22209cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 22210for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 22211 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22212 case $ac_file in
22213 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22214 cat >$tmp/stdin
22215 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22216 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22217 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22218 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22219 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22220 esac
22221
503d2be0 22222 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
22223 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22224$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22225 X"$ac_file" : 'X\(//\)[^/]' \| \
22226 X"$ac_file" : 'X\(//\)$' \| \
22227 X"$ac_file" : 'X\(/\)' \| \
22228 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22229echo X"$ac_file" |
22230 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22231 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22232 /^X\(\/\/\)$/{ s//\1/; q; }
22233 /^X\(\/\).*/{ s//\1/; q; }
22234 s/.*/./; q'`
6bae0ccf
DL
22235 { if $as_mkdir_p; then
22236 mkdir -p "$ac_dir"
22237 else
22238 as_dir="$ac_dir"
22239 as_dirs=
22240 while test ! -d "$as_dir"; do
22241 as_dirs="$as_dir $as_dirs"
22242 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22243$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22244 X"$as_dir" : 'X\(//\)[^/]' \| \
22245 X"$as_dir" : 'X\(//\)$' \| \
22246 X"$as_dir" : 'X\(/\)' \| \
22247 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22248echo X"$as_dir" |
22249 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22250 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22251 /^X\(\/\/\)$/{ s//\1/; q; }
22252 /^X\(\/\).*/{ s//\1/; q; }
22253 s/.*/./; q'`
22254 done
22255 test ! -n "$as_dirs" || mkdir $as_dirs
22256 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22257echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22258 { (exit 1); exit 1; }; }; }
503d2be0 22259
c0d27fcc 22260 ac_builddir=.
98418dba 22261
c0d27fcc
MR
22262if test "$ac_dir" != .; then
22263 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22264 # A "../" for each directory in $ac_dir_suffix.
22265 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22266else
22267 ac_dir_suffix= ac_top_builddir=
22268fi
22269
22270case $srcdir in
22271 .) # No --srcdir option. We are building in place.
22272 ac_srcdir=.
22273 if test -z "$ac_top_builddir"; then
22274 ac_top_srcdir=.
22275 else
22276 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22277 fi ;;
22278 [\\/]* | ?:[\\/]* ) # Absolute path.
22279 ac_srcdir=$srcdir$ac_dir_suffix;
22280 ac_top_srcdir=$srcdir ;;
ba4481b5 22281 *) # Relative path.
c0d27fcc
MR
22282 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22283 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22284esac
35996d22
AS
22285
22286# Do not use `cd foo && pwd` to compute absolute paths, because
22287# the directories may not exist.
22288case `pwd` in
22289.) ac_abs_builddir="$ac_dir";;
22290*)
22291 case "$ac_dir" in
22292 .) ac_abs_builddir=`pwd`;;
22293 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22294 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22295 esac;;
22296esac
22297case $ac_abs_builddir in
22298.) ac_abs_top_builddir=${ac_top_builddir}.;;
22299*)
22300 case ${ac_top_builddir}. in
22301 .) ac_abs_top_builddir=$ac_abs_builddir;;
22302 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22303 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22304 esac;;
22305esac
22306case $ac_abs_builddir in
22307.) ac_abs_srcdir=$ac_srcdir;;
22308*)
22309 case $ac_srcdir in
22310 .) ac_abs_srcdir=$ac_abs_builddir;;
22311 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22312 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22313 esac;;
22314esac
22315case $ac_abs_builddir in
22316.) ac_abs_top_srcdir=$ac_top_srcdir;;
22317*)
22318 case $ac_top_srcdir in
22319 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22320 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22321 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22322 esac;;
22323esac
c0d27fcc 22324
ba4481b5 22325
503d2be0
AS
22326 case $INSTALL in
22327 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 22328 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
22329 esac
22330
4494a266
JD
22331 if test x"$ac_file" != x-; then
22332 { echo "$as_me:$LINENO: creating $ac_file" >&5
22333echo "$as_me: creating $ac_file" >&6;}
22334 rm -f "$ac_file"
22335 fi
503d2be0
AS
22336 # Let's still pretend it is `configure' which instantiates (i.e., don't
22337 # use $as_me), people would be surprised to read:
c0d27fcc
MR
22338 # /* config.h. Generated by config.status. */
22339 if test x"$ac_file" = x-; then
22340 configure_input=
22341 else
22342 configure_input="$ac_file. "
22343 fi
22344 configure_input=$configure_input"Generated from `echo $ac_file_in |
35996d22 22345 sed 's,.*/,,'` by configure."
503d2be0
AS
22346
22347 # First look for the input files in the build tree, otherwise in the
22348 # src tree.
22349 ac_file_inputs=`IFS=:
22350 for f in $ac_file_in; do
22351 case $f in
22352 -) echo $tmp/stdin ;;
22353 [\\/$]*)
35996d22
AS
22354 # Absolute (can't be DOS-style, as IFS=:)
22355 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22356echo "$as_me: error: cannot find input file: $f" >&2;}
22357 { (exit 1); exit 1; }; }
35996d22 22358 echo "$f";;
503d2be0 22359 *) # Relative
35996d22
AS
22360 if test -f "$f"; then
22361 # Build tree
22362 echo "$f"
22363 elif test -f "$srcdir/$f"; then
22364 # Source tree
22365 echo "$srcdir/$f"
22366 else
22367 # /dev/null tree
22368 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22369echo "$as_me: error: cannot find input file: $f" >&2;}
22370 { (exit 1); exit 1; }; }
35996d22 22371 fi;;
503d2be0
AS
22372 esac
22373 done` || { (exit 1); exit 1; }
c0d27fcc
MR
22374_ACEOF
22375cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
22376 sed "$ac_vpsub
22377$extrasub
c0d27fcc
MR
22378_ACEOF
22379cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22380:t
22381/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22382s,@configure_input@,$configure_input,;t t
22383s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 22384s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 22385s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
22386s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
22387s,@builddir@,$ac_builddir,;t t
22388s,@abs_builddir@,$ac_abs_builddir,;t t
22389s,@top_builddir@,$ac_top_builddir,;t t
22390s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
22391s,@INSTALL@,$ac_INSTALL,;t t
22392" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
22393 rm -f $tmp/stdin
22394 if test x"$ac_file" != x-; then
22395 mv $tmp/out $ac_file
22396 else
22397 cat $tmp/out
22398 rm -f $tmp/out
22399 fi
22400
22401done
c0d27fcc
MR
22402_ACEOF
22403cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22404
503d2be0
AS
22405#
22406# CONFIG_HEADER section.
22407#
ba4481b5
DL
22408
22409# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
22410# NAME is the cpp macro being defined and VALUE is the value it is being given.
22411#
22412# ac_d sets the value in "#define NAME VALUE" lines.
35996d22
AS
22413ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
22414ac_dB='[ ].*$,\1#\2'
503d2be0
AS
22415ac_dC=' '
22416ac_dD=',;t'
22417# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
35996d22 22418ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
503d2be0 22419ac_uB='$,\1#\2define\3'
ba4481b5 22420ac_uC=' '
503d2be0 22421ac_uD=',;t'
ba4481b5 22422
503d2be0 22423for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 22424 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
22425 case $ac_file in
22426 - | *:- | *:-:* ) # input from stdin
35996d22
AS
22427 cat >$tmp/stdin
22428 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22429 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22430 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
35996d22 22431 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 22432 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
22433 esac
22434
c0d27fcc 22435 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
22436echo "$as_me: creating $ac_file" >&6;}
22437
22438 # First look for the input files in the build tree, otherwise in the
22439 # src tree.
22440 ac_file_inputs=`IFS=:
22441 for f in $ac_file_in; do
22442 case $f in
22443 -) echo $tmp/stdin ;;
22444 [\\/$]*)
35996d22
AS
22445 # Absolute (can't be DOS-style, as IFS=:)
22446 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22447echo "$as_me: error: cannot find input file: $f" >&2;}
22448 { (exit 1); exit 1; }; }
35996d22
AS
22449 # Do quote $f, to prevent DOS paths from being IFS'd.
22450 echo "$f";;
503d2be0 22451 *) # Relative
35996d22
AS
22452 if test -f "$f"; then
22453 # Build tree
22454 echo "$f"
22455 elif test -f "$srcdir/$f"; then
22456 # Source tree
22457 echo "$srcdir/$f"
22458 else
22459 # /dev/null tree
22460 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
22461echo "$as_me: error: cannot find input file: $f" >&2;}
22462 { (exit 1); exit 1; }; }
35996d22 22463 fi;;
503d2be0
AS
22464 esac
22465 done` || { (exit 1); exit 1; }
22466 # Remove the trailing spaces.
35996d22 22467 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
503d2be0 22468
c0d27fcc 22469_ACEOF
503d2be0
AS
22470
22471# Transform confdefs.h into two sed scripts, `conftest.defines' and
22472# `conftest.undefs', that substitutes the proper values into
22473# config.h.in to produce config.h. The first handles `#define'
22474# templates, and the second `#undef' templates.
22475# And first: Protect against being on the right side of a sed subst in
22476# config.status. Protect against being in an unquoted here document
22477# in config.status.
22478rm -f conftest.defines conftest.undefs
22479# Using a here document instead of a string reduces the quoting nightmare.
22480# Putting comments in sed scripts is not portable.
22481#
22482# `end' is used to avoid that the second main sed command (meant for
22483# 0-ary CPP macros) applies to n-ary macro definitions.
22484# See the Autoconf documentation for `clear'.
c0d27fcc 22485cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
22486s/[\\&,]/\\&/g
22487s,[\\$`],\\&,g
22488t clear
22489: clear
35996d22 22490s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0 22491t end
35996d22 22492s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
503d2be0 22493: end
c0d27fcc 22494_ACEOF
503d2be0
AS
22495# If some macros were called several times there might be several times
22496# the same #defines, which is useless. Nevertheless, we may not want to
22497# sort them, since we want the *last* AC-DEFINE to be honored.
22498uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
22499sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
22500rm -f confdef2sed.sed
ba4481b5
DL
22501
22502# This sed command replaces #undef with comments. This is necessary, for
22503# example, in the case of _POSIX_SOURCE, which is predefined and required
22504# on some systems where configure will not decide to define it.
c0d27fcc 22505cat >>conftest.undefs <<\_ACEOF
35996d22 22506s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 22507_ACEOF
ba4481b5 22508
503d2be0
AS
22509# Break up conftest.defines because some shells have a limit on the size
22510# of here documents, and old seds have small limits too (100 cmds).
22511echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
35996d22 22512echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
22513echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
22514echo ' :' >>$CONFIG_STATUS
22515rm -f conftest.tail
22516while grep . conftest.defines >/dev/null
22517do
22518 # Write a limited-size here document to $tmp/defines.sed.
22519 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
22520 # Speed up: don't consider the non `#define' lines.
35996d22 22521 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
503d2be0
AS
22522 # Work around the forget-to-reset-the-flag bug.
22523 echo 't clr' >>$CONFIG_STATUS
22524 echo ': clr' >>$CONFIG_STATUS
22525 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
22526 echo 'CEOF
22527 sed -f $tmp/defines.sed $tmp/in >$tmp/out
22528 rm -f $tmp/in
22529 mv $tmp/out $tmp/in
22530' >>$CONFIG_STATUS
22531 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
22532 rm -f conftest.defines
22533 mv conftest.tail conftest.defines
22534done
22535rm -f conftest.defines
6bae0ccf 22536echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 22537echo >>$CONFIG_STATUS
ba4481b5 22538
503d2be0
AS
22539# Break up conftest.undefs because some shells have a limit on the size
22540# of here documents, and old seds have small limits too (100 cmds).
22541echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 22542rm -f conftest.tail
503d2be0 22543while grep . conftest.undefs >/dev/null
ba4481b5 22544do
503d2be0
AS
22545 # Write a limited-size here document to $tmp/undefs.sed.
22546 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
22547 # Speed up: don't consider the non `#undef'
35996d22 22548 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
503d2be0
AS
22549 # Work around the forget-to-reset-the-flag bug.
22550 echo 't clr' >>$CONFIG_STATUS
22551 echo ': clr' >>$CONFIG_STATUS
22552 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 22553 echo 'CEOF
503d2be0
AS
22554 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
22555 rm -f $tmp/in
22556 mv $tmp/out $tmp/in
22557' >>$CONFIG_STATUS
22558 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
22559 rm -f conftest.undefs
22560 mv conftest.tail conftest.undefs
ba4481b5 22561done
503d2be0
AS
22562rm -f conftest.undefs
22563
c0d27fcc 22564cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22565 # Let's still pretend it is `configure' which instantiates (i.e., don't
22566 # use $as_me), people would be surprised to read:
c0d27fcc 22567 # /* config.h. Generated by config.status. */
503d2be0 22568 if test x"$ac_file" = x-; then
c0d27fcc 22569 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 22570 else
c0d27fcc 22571 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
22572 fi
22573 cat $tmp/in >>$tmp/config.h
22574 rm -f $tmp/in
22575 if test x"$ac_file" != x-; then
19650fd6 22576 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 22577 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
22578echo "$as_me: $ac_file is unchanged" >&6;}
22579 else
c0d27fcc
MR
22580 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22581$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22582 X"$ac_file" : 'X\(//\)[^/]' \| \
22583 X"$ac_file" : 'X\(//\)$' \| \
22584 X"$ac_file" : 'X\(/\)' \| \
22585 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
22586echo X"$ac_file" |
22587 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22588 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22589 /^X\(\/\/\)$/{ s//\1/; q; }
22590 /^X\(\/\).*/{ s//\1/; q; }
22591 s/.*/./; q'`
6bae0ccf
DL
22592 { if $as_mkdir_p; then
22593 mkdir -p "$ac_dir"
22594 else
22595 as_dir="$ac_dir"
22596 as_dirs=
22597 while test ! -d "$as_dir"; do
22598 as_dirs="$as_dir $as_dirs"
22599 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22600$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22601 X"$as_dir" : 'X\(//\)[^/]' \| \
22602 X"$as_dir" : 'X\(//\)$' \| \
22603 X"$as_dir" : 'X\(/\)' \| \
22604 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
22605echo X"$as_dir" |
22606 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22607 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22608 /^X\(\/\/\)$/{ s//\1/; q; }
22609 /^X\(\/\).*/{ s//\1/; q; }
22610 s/.*/./; q'`
22611 done
22612 test ! -n "$as_dirs" || mkdir $as_dirs
22613 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22614echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22615 { (exit 1); exit 1; }; }; }
503d2be0 22616
503d2be0
AS
22617 rm -f $ac_file
22618 mv $tmp/config.h $ac_file
ba4481b5 22619 fi
503d2be0
AS
22620 else
22621 cat $tmp/config.h
22622 rm -f $tmp/config.h
ba4481b5 22623 fi
503d2be0 22624done
c0d27fcc
MR
22625_ACEOF
22626cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
22627
22628#
22629# CONFIG_COMMANDS section.
22630#
22631for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
22632 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
22633 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
22634 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
22635$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35996d22
AS
22636 X"$ac_dest" : 'X\(//\)[^/]' \| \
22637 X"$ac_dest" : 'X\(//\)$' \| \
22638 X"$ac_dest" : 'X\(/\)' \| \
22639 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
22640echo X"$ac_dest" |
22641 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22642 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22643 /^X\(\/\/\)$/{ s//\1/; q; }
22644 /^X\(\/\).*/{ s//\1/; q; }
22645 s/.*/./; q'`
35996d22
AS
22646 { if $as_mkdir_p; then
22647 mkdir -p "$ac_dir"
22648 else
22649 as_dir="$ac_dir"
22650 as_dirs=
22651 while test ! -d "$as_dir"; do
22652 as_dirs="$as_dir $as_dirs"
22653 as_dir=`(dirname "$as_dir") 2>/dev/null ||
22654$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22655 X"$as_dir" : 'X\(//\)[^/]' \| \
22656 X"$as_dir" : 'X\(//\)$' \| \
22657 X"$as_dir" : 'X\(/\)' \| \
22658 . : '\(.\)' 2>/dev/null ||
22659echo X"$as_dir" |
22660 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22661 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22662 /^X\(\/\/\)$/{ s//\1/; q; }
22663 /^X\(\/\).*/{ s//\1/; q; }
22664 s/.*/./; q'`
22665 done
22666 test ! -n "$as_dirs" || mkdir $as_dirs
22667 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
22668echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
22669 { (exit 1); exit 1; }; }; }
22670
c0d27fcc
MR
22671 ac_builddir=.
22672
22673if test "$ac_dir" != .; then
22674 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
22675 # A "../" for each directory in $ac_dir_suffix.
22676 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
22677else
22678 ac_dir_suffix= ac_top_builddir=
22679fi
22680
22681case $srcdir in
22682 .) # No --srcdir option. We are building in place.
22683 ac_srcdir=.
22684 if test -z "$ac_top_builddir"; then
22685 ac_top_srcdir=.
22686 else
22687 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
22688 fi ;;
22689 [\\/]* | ?:[\\/]* ) # Absolute path.
22690 ac_srcdir=$srcdir$ac_dir_suffix;
22691 ac_top_srcdir=$srcdir ;;
22692 *) # Relative path.
22693 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
22694 ac_top_srcdir=$ac_top_builddir$srcdir ;;
22695esac
35996d22
AS
22696
22697# Do not use `cd foo && pwd` to compute absolute paths, because
22698# the directories may not exist.
22699case `pwd` in
22700.) ac_abs_builddir="$ac_dir";;
22701*)
22702 case "$ac_dir" in
22703 .) ac_abs_builddir=`pwd`;;
22704 [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
22705 *) ac_abs_builddir=`pwd`/"$ac_dir";;
22706 esac;;
22707esac
22708case $ac_abs_builddir in
22709.) ac_abs_top_builddir=${ac_top_builddir}.;;
22710*)
22711 case ${ac_top_builddir}. in
22712 .) ac_abs_top_builddir=$ac_abs_builddir;;
22713 [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
22714 *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
22715 esac;;
22716esac
22717case $ac_abs_builddir in
22718.) ac_abs_srcdir=$ac_srcdir;;
22719*)
22720 case $ac_srcdir in
22721 .) ac_abs_srcdir=$ac_abs_builddir;;
22722 [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
22723 *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
22724 esac;;
22725esac
22726case $ac_abs_builddir in
22727.) ac_abs_top_srcdir=$ac_top_srcdir;;
22728*)
22729 case $ac_top_srcdir in
22730 .) ac_abs_top_srcdir=$ac_abs_builddir;;
22731 [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
22732 *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
22733 esac;;
22734esac
ba4481b5 22735
c0d27fcc
MR
22736
22737 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
22738echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
22739 case $ac_dest in
22740 default )
ba4481b5
DL
22741
22742### Make the necessary directories, if they don't exist.
22743for dir in etc lisp ; do
22744 test -d ${dir} || mkdir ${dir}
22745done
22746
22747# Build src/Makefile from ${srcdir}/src/Makefile.c
22748# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
22749# This must be done after src/config.h is built, since we rely on that file.
22750
22751# Now get this: Some word that is part of the ${srcdir} directory name
22752# or the ${configuration} value might, just might, happen to be an
22753# identifier like `sun4' or `i386' or something, and be predefined by
22754# the C preprocessor to some helpful value like 1, or maybe the empty
22755# string. Needless to say consequent macro substitutions are less
22756# than conducive to the makefile finding the correct directory.
22757undefs="`echo $top_srcdir $configuration $canonical |
22758sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
22759 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
22760`"
22761
22762echo creating src/epaths.h
4aa6b955 22763${MAKE-make} epaths-force
ba4481b5 22764
1c203d4c
DL
22765# As of 2000-11-19, newest development versions of GNU cpp preprocess
22766# `..' to `. .' unless invoked with -traditional
22767
d0e9bfd2 22768if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
22769 CPPFLAGS="$CPPFLAGS -traditional"
22770fi
22771
ba4481b5
DL
22772echo creating lib-src/Makefile
22773( cd lib-src
22774 rm -f junk.c junk1.c junk2.c
22775 sed -e '/start of cpp stuff/q' \
22776 < Makefile.c > junk1.c
22777 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22778 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22779 < Makefile.c > junk.c
503d2be0 22780 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22781 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22782 cat junk1.c junk2.c > Makefile.new
22783 rm -f junk.c junk1.c junk2.c
22784 chmod 444 Makefile.new
22785 mv -f Makefile.new Makefile
22786)
22787
22788echo creating src/Makefile
22789( cd src
22790 rm -f junk.c junk1.c junk2.c
22791 sed -e '/start of cpp stuff/q' \
22792 < Makefile.c > junk1.c
22793 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 22794 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 22795 < Makefile.c > junk.c
503d2be0 22796 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
22797 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
22798 cat junk1.c junk2.c > Makefile.new
22799 rm -f junk.c junk1.c junk2.c
22800 chmod 444 Makefile.new
22801 mv -f Makefile.new Makefile
22802)
22803
503d2be0 22804if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 22805 echo creating src/.gdbinit
503d2be0 22806 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
22807fi
22808
22809# This is how we know whether to re-run configure in certain cases.
22810touch src/config.stamp
22811
503d2be0
AS
22812 ;;
22813 esac
22814done
c0d27fcc 22815_ACEOF
503d2be0 22816
c0d27fcc 22817cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 22818
503d2be0 22819{ (exit 0); exit 0; }
c0d27fcc 22820_ACEOF
ba4481b5 22821chmod +x $CONFIG_STATUS
503d2be0
AS
22822ac_clean_files=$ac_clean_files_save
22823
c0d27fcc 22824
503d2be0
AS
22825# configure is writing to config.log, and then calls config.status.
22826# config.status does its own redirection, appending to config.log.
22827# Unfortunately, on DOS this fails, as config.log is still kept open
22828# by configure, so config.status won't be able to write to it; its
22829# output is simply discarded. So we exec the FD to /dev/null,
22830# effectively closing config.log, so it can be properly (re)opened and
22831# appended to by config.status. When coming back to configure, we
22832# need to make the FD available again.
22833if test "$no_create" != yes; then
22834 ac_cs_success=:
19650fd6
AS
22835 ac_config_status_args=
22836 test "$silent" = yes &&
22837 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 22838 exec 5>/dev/null
19650fd6 22839 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
22840 exec 5>>config.log
22841 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
22842 # would make configure fail if this is the last instruction.
22843 $ac_cs_success || { (exit 1); exit 1; }
22844fi
f5f47add 22845
c0d27fcc 22846