(ielm-dynamic-return, inferior-emacs-lisp-mode): Fix spellings in docstrings.
[bpt/emacs.git] / configure
CommitLineData
ba4481b5 1#! /bin/sh
ba4481b5 2# Guess values for system-dependent variables and create Makefiles.
7c9e5167 3# Generated by GNU Autoconf 2.57.
ba4481b5 4#
7c9e5167
JD
5# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
6# Free Software Foundation, Inc.
ba4481b5
DL
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
c0d27fcc
MR
9## --------------------- ##
10## M4sh Initialization. ##
11## --------------------- ##
503d2be0
AS
12
13# Be Bourne compatible
14if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
15 emulate sh
16 NULLCMD=:
6bae0ccf
DL
17 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
18 # is contrary to our usage. Disable this feature.
19 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
20elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
21 set -o posix
22fi
23
c0d27fcc 24# Support unset when possible.
7c9e5167 25if (FOO=FOO; unset FOO) >/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
7c9e5167 44 if (set +x; test -n "`(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
221 as_mkdir_p=false
222fi
223
503d2be0
AS
224as_executable_p="test -f"
225
c0d27fcc 226# Sed expression to map a string onto a valid CPP name.
7c9e5167 227as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
c0d27fcc
MR
228
229# Sed expression to map a string onto a valid variable name.
7c9e5167 230as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
503d2be0 231
503d2be0
AS
232
233# IFS
234# We need space, tab and new line, in precisely that order.
235as_nl='
236'
237IFS=" $as_nl"
238
239# CDPATH.
6bae0ccf 240$as_unset CDPATH
c0d27fcc 241
503d2be0
AS
242
243# Name of the host.
244# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
245# so uname gets run too.
246ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
247
248exec 6>&1
249
250#
251# Initializations.
252#
ba4481b5 253ac_default_prefix=/usr/local
6bae0ccf 254ac_config_libobj_dir=.
503d2be0
AS
255cross_compiling=no
256subdirs=
c0d27fcc
MR
257MFLAGS=
258MAKEFLAGS=
503d2be0
AS
259SHELL=${CONFIG_SHELL-/bin/sh}
260
261# Maximum number of lines to put in a shell here document.
262# This variable seems obsolete. It should probably be removed, and
263# only ac_max_sed_lines should be used.
264: ${ac_max_here_lines=38}
265
c0d27fcc
MR
266# Identity of this package.
267PACKAGE_NAME=
268PACKAGE_TARNAME=
269PACKAGE_VERSION=
270PACKAGE_STRING=
271PACKAGE_BUGREPORT=
272
503d2be0 273ac_unique_file="src/lisp.h"
6bae0ccf 274ac_config_libobj_dir=src
503d2be0
AS
275# Factoring default headers for most tests.
276ac_includes_default="\
277#include <stdio.h>
278#if HAVE_SYS_TYPES_H
279# include <sys/types.h>
280#endif
281#if HAVE_SYS_STAT_H
282# include <sys/stat.h>
283#endif
284#if STDC_HEADERS
285# include <stdlib.h>
286# include <stddef.h>
287#else
288# if HAVE_STDLIB_H
289# include <stdlib.h>
290# endif
291#endif
292#if HAVE_STRING_H
293# if !STDC_HEADERS && HAVE_MEMORY_H
294# include <memory.h>
295# endif
296# include <string.h>
297#endif
298#if HAVE_STRINGS_H
299# include <strings.h>
300#endif
301#if HAVE_INTTYPES_H
302# include <inttypes.h>
303#else
304# if HAVE_STDINT_H
305# include <stdint.h>
306# endif
307#endif
308#if HAVE_UNISTD_H
309# include <unistd.h>
310#endif"
ba4481b5 311
f17e308a 312ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MAINT build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA RANLIB ac_ct_RANLIB INSTALL_INFO EGREP LIBSOUND SET_MAKE PKG_CONFIG GTK_CFLAGS GTK_LIBS ALLOCA liblockfile LIBOBJS NEED_SETGID KMEM_GROUP GETLOADAVG_LIBS version configuration canonical srcdir lispdir locallisppath lisppath x_default_search_path etcdir archlibdir docdir bitmapdir gamedir gameuser c_switch_system c_switch_machine LD_SWITCH_X_SITE LD_SWITCH_X_SITE_AUX C_SWITCH_X_SITE X_TOOLKIT_TYPE machfile opsysfile carbon_appdir LTLIBOBJS'
6bae0ccf 313ac_subst_files=''
c0d27fcc 314
ba4481b5 315# Initialize some variables set by options.
503d2be0
AS
316ac_init_help=
317ac_init_version=false
ba4481b5
DL
318# The variables have the same names as the options, with
319# dashes changed to underlines.
503d2be0 320cache_file=/dev/null
ba4481b5 321exec_prefix=NONE
ba4481b5 322no_create=
ba4481b5
DL
323no_recursion=
324prefix=NONE
325program_prefix=NONE
326program_suffix=NONE
327program_transform_name=s,x,x,
328silent=
329site=
330srcdir=
ba4481b5
DL
331verbose=
332x_includes=NONE
333x_libraries=NONE
503d2be0
AS
334
335# Installation directory options.
336# These are left unexpanded so users can "make install exec_prefix=/foo"
337# and all the variables that are supposed to be based on exec_prefix
338# by default will actually change.
339# Use braces instead of parens because sh, perl, etc. also accept them.
ba4481b5
DL
340bindir='${exec_prefix}/bin'
341sbindir='${exec_prefix}/sbin'
342libexecdir='${exec_prefix}/libexec'
343datadir='${prefix}/share'
344sysconfdir='${prefix}/etc'
345sharedstatedir='${prefix}/com'
346localstatedir='${prefix}/var'
347libdir='${exec_prefix}/lib'
348includedir='${prefix}/include'
349oldincludedir='/usr/include'
350infodir='${prefix}/info'
351mandir='${prefix}/man'
352
ba4481b5
DL
353ac_prev=
354for ac_option
355do
ba4481b5
DL
356 # If the previous option needs an argument, assign it.
357 if test -n "$ac_prev"; then
358 eval "$ac_prev=\$ac_option"
359 ac_prev=
360 continue
361 fi
362
503d2be0 363 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
ba4481b5
DL
364
365 # Accept the important Cygnus configure options, so we can diagnose typos.
366
503d2be0 367 case $ac_option in
ba4481b5
DL
368
369 -bindir | --bindir | --bindi | --bind | --bin | --bi)
370 ac_prev=bindir ;;
371 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
503d2be0 372 bindir=$ac_optarg ;;
ba4481b5
DL
373
374 -build | --build | --buil | --bui | --bu)
503d2be0 375 ac_prev=build_alias ;;
ba4481b5 376 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
503d2be0 377 build_alias=$ac_optarg ;;
ba4481b5
DL
378
379 -cache-file | --cache-file | --cache-fil | --cache-fi \
380 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
381 ac_prev=cache_file ;;
382 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
383 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
503d2be0
AS
384 cache_file=$ac_optarg ;;
385
386 --config-cache | -C)
387 cache_file=config.cache ;;
ba4481b5
DL
388
389 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
390 ac_prev=datadir ;;
391 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
392 | --da=*)
503d2be0 393 datadir=$ac_optarg ;;
ba4481b5
DL
394
395 -disable-* | --disable-*)
503d2be0 396 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
ba4481b5 397 # Reject names that are not valid shell variable names.
503d2be0
AS
398 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
399 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
400 { (exit 1); exit 1; }; }
401 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
402 eval "enable_$ac_feature=no" ;;
ba4481b5
DL
403
404 -enable-* | --enable-*)
503d2be0 405 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
ba4481b5 406 # Reject names that are not valid shell variable names.
503d2be0
AS
407 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
408 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
409 { (exit 1); exit 1; }; }
410 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
411 case $ac_option in
412 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
413 *) ac_optarg=yes ;;
414 esac
503d2be0 415 eval "enable_$ac_feature='$ac_optarg'" ;;
ba4481b5
DL
416
417 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
418 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
419 | --exec | --exe | --ex)
420 ac_prev=exec_prefix ;;
421 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
422 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
423 | --exec=* | --exe=* | --ex=*)
503d2be0 424 exec_prefix=$ac_optarg ;;
ba4481b5
DL
425
426 -gas | --gas | --ga | --g)
427 # Obsolete; use --with-gas.
428 with_gas=yes ;;
429
503d2be0
AS
430 -help | --help | --hel | --he | -h)
431 ac_init_help=long ;;
432 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
433 ac_init_help=recursive ;;
434 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
435 ac_init_help=short ;;
ba4481b5
DL
436
437 -host | --host | --hos | --ho)
503d2be0 438 ac_prev=host_alias ;;
ba4481b5 439 -host=* | --host=* | --hos=* | --ho=*)
503d2be0 440 host_alias=$ac_optarg ;;
ba4481b5
DL
441
442 -includedir | --includedir | --includedi | --included | --include \
443 | --includ | --inclu | --incl | --inc)
444 ac_prev=includedir ;;
445 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
446 | --includ=* | --inclu=* | --incl=* | --inc=*)
503d2be0 447 includedir=$ac_optarg ;;
ba4481b5
DL
448
449 -infodir | --infodir | --infodi | --infod | --info | --inf)
450 ac_prev=infodir ;;
451 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
503d2be0 452 infodir=$ac_optarg ;;
ba4481b5
DL
453
454 -libdir | --libdir | --libdi | --libd)
455 ac_prev=libdir ;;
456 -libdir=* | --libdir=* | --libdi=* | --libd=*)
503d2be0 457 libdir=$ac_optarg ;;
ba4481b5
DL
458
459 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
460 | --libexe | --libex | --libe)
461 ac_prev=libexecdir ;;
462 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
463 | --libexe=* | --libex=* | --libe=*)
503d2be0 464 libexecdir=$ac_optarg ;;
ba4481b5
DL
465
466 -localstatedir | --localstatedir | --localstatedi | --localstated \
467 | --localstate | --localstat | --localsta | --localst \
468 | --locals | --local | --loca | --loc | --lo)
469 ac_prev=localstatedir ;;
470 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
471 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
472 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
503d2be0 473 localstatedir=$ac_optarg ;;
ba4481b5
DL
474
475 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
476 ac_prev=mandir ;;
477 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
503d2be0 478 mandir=$ac_optarg ;;
ba4481b5
DL
479
480 -nfp | --nfp | --nf)
481 # Obsolete; use --without-fp.
482 with_fp=no ;;
483
484 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
c0d27fcc 485 | --no-cr | --no-c | -n)
ba4481b5
DL
486 no_create=yes ;;
487
488 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
489 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
490 no_recursion=yes ;;
491
492 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
493 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
494 | --oldin | --oldi | --old | --ol | --o)
495 ac_prev=oldincludedir ;;
496 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
497 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
498 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
503d2be0 499 oldincludedir=$ac_optarg ;;
ba4481b5
DL
500
501 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
502 ac_prev=prefix ;;
503 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
503d2be0 504 prefix=$ac_optarg ;;
ba4481b5
DL
505
506 -program-prefix | --program-prefix | --program-prefi | --program-pref \
507 | --program-pre | --program-pr | --program-p)
508 ac_prev=program_prefix ;;
509 -program-prefix=* | --program-prefix=* | --program-prefi=* \
510 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
503d2be0 511 program_prefix=$ac_optarg ;;
ba4481b5
DL
512
513 -program-suffix | --program-suffix | --program-suffi | --program-suff \
514 | --program-suf | --program-su | --program-s)
515 ac_prev=program_suffix ;;
516 -program-suffix=* | --program-suffix=* | --program-suffi=* \
517 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
503d2be0 518 program_suffix=$ac_optarg ;;
ba4481b5
DL
519
520 -program-transform-name | --program-transform-name \
521 | --program-transform-nam | --program-transform-na \
522 | --program-transform-n | --program-transform- \
523 | --program-transform | --program-transfor \
524 | --program-transfo | --program-transf \
525 | --program-trans | --program-tran \
526 | --progr-tra | --program-tr | --program-t)
527 ac_prev=program_transform_name ;;
528 -program-transform-name=* | --program-transform-name=* \
529 | --program-transform-nam=* | --program-transform-na=* \
530 | --program-transform-n=* | --program-transform-=* \
531 | --program-transform=* | --program-transfor=* \
532 | --program-transfo=* | --program-transf=* \
533 | --program-trans=* | --program-tran=* \
534 | --progr-tra=* | --program-tr=* | --program-t=*)
503d2be0 535 program_transform_name=$ac_optarg ;;
ba4481b5
DL
536
537 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
538 | -silent | --silent | --silen | --sile | --sil)
539 silent=yes ;;
540
541 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
542 ac_prev=sbindir ;;
543 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
544 | --sbi=* | --sb=*)
503d2be0 545 sbindir=$ac_optarg ;;
ba4481b5
DL
546
547 -sharedstatedir | --sharedstatedir | --sharedstatedi \
548 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
549 | --sharedst | --shareds | --shared | --share | --shar \
550 | --sha | --sh)
551 ac_prev=sharedstatedir ;;
552 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
553 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
554 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
555 | --sha=* | --sh=*)
503d2be0 556 sharedstatedir=$ac_optarg ;;
ba4481b5
DL
557
558 -site | --site | --sit)
559 ac_prev=site ;;
560 -site=* | --site=* | --sit=*)
503d2be0 561 site=$ac_optarg ;;
ba4481b5
DL
562
563 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
564 ac_prev=srcdir ;;
565 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
503d2be0 566 srcdir=$ac_optarg ;;
ba4481b5
DL
567
568 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
569 | --syscon | --sysco | --sysc | --sys | --sy)
570 ac_prev=sysconfdir ;;
571 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
572 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
503d2be0 573 sysconfdir=$ac_optarg ;;
ba4481b5
DL
574
575 -target | --target | --targe | --targ | --tar | --ta | --t)
503d2be0 576 ac_prev=target_alias ;;
ba4481b5 577 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
503d2be0 578 target_alias=$ac_optarg ;;
ba4481b5
DL
579
580 -v | -verbose | --verbose | --verbos | --verbo | --verb)
581 verbose=yes ;;
582
503d2be0
AS
583 -version | --version | --versio | --versi | --vers | -V)
584 ac_init_version=: ;;
ba4481b5
DL
585
586 -with-* | --with-*)
503d2be0 587 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
ba4481b5 588 # Reject names that are not valid shell variable names.
503d2be0
AS
589 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
590 { echo "$as_me: error: invalid package name: $ac_package" >&2
591 { (exit 1); exit 1; }; }
ba4481b5 592 ac_package=`echo $ac_package| sed 's/-/_/g'`
503d2be0
AS
593 case $ac_option in
594 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
ba4481b5
DL
595 *) ac_optarg=yes ;;
596 esac
503d2be0 597 eval "with_$ac_package='$ac_optarg'" ;;
ba4481b5
DL
598
599 -without-* | --without-*)
503d2be0 600 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
ba4481b5 601 # Reject names that are not valid shell variable names.
503d2be0
AS
602 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
603 { echo "$as_me: error: invalid package name: $ac_package" >&2
604 { (exit 1); exit 1; }; }
605 ac_package=`echo $ac_package | sed 's/-/_/g'`
606 eval "with_$ac_package=no" ;;
ba4481b5
DL
607
608 --x)
609 # Obsolete; use --with-x.
610 with_x=yes ;;
611
612 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
613 | --x-incl | --x-inc | --x-in | --x-i)
614 ac_prev=x_includes ;;
615 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
616 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
503d2be0 617 x_includes=$ac_optarg ;;
ba4481b5
DL
618
619 -x-libraries | --x-libraries | --x-librarie | --x-librari \
620 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
621 ac_prev=x_libraries ;;
622 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
623 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
503d2be0 624 x_libraries=$ac_optarg ;;
ba4481b5 625
503d2be0
AS
626 -*) { echo "$as_me: error: unrecognized option: $ac_option
627Try \`$0 --help' for more information." >&2
628 { (exit 1); exit 1; }; }
ba4481b5
DL
629 ;;
630
503d2be0
AS
631 *=*)
632 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
633 # Reject names that are not valid shell variable names.
634 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
635 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
636 { (exit 1); exit 1; }; }
637 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
638 eval "$ac_envvar='$ac_optarg'"
639 export $ac_envvar ;;
640
ba4481b5 641 *)
503d2be0
AS
642 # FIXME: should be removed in autoconf 3.0.
643 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
644 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
645 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
646 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
ba4481b5
DL
647 ;;
648
649 esac
650done
651
652if test -n "$ac_prev"; then
503d2be0
AS
653 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
654 { echo "$as_me: error: missing argument to $ac_option" >&2
655 { (exit 1); exit 1; }; }
ba4481b5 656fi
ba4481b5 657
503d2be0
AS
658# Be sure to have absolute paths.
659for ac_var in exec_prefix prefix
660do
661 eval ac_val=$`echo $ac_var`
662 case $ac_val in
663 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
c0d27fcc 664 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0
AS
665 { (exit 1); exit 1; }; };;
666 esac
667done
ba4481b5 668
503d2be0
AS
669# Be sure to have absolute paths.
670for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
7c9e5167 671 localstatedir libdir includedir oldincludedir infodir mandir
ba4481b5 672do
503d2be0
AS
673 eval ac_val=$`echo $ac_var`
674 case $ac_val in
675 [\\/$]* | ?:[\\/]* ) ;;
c0d27fcc 676 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
503d2be0 677 { (exit 1); exit 1; }; };;
ba4481b5
DL
678 esac
679done
680
503d2be0
AS
681# There might be people who depend on the old broken behavior: `$host'
682# used to hold the argument of --host etc.
c0d27fcc 683# FIXME: To remove some day.
503d2be0
AS
684build=$build_alias
685host=$host_alias
686target=$target_alias
687
c0d27fcc 688# FIXME: To remove some day.
503d2be0
AS
689if test "x$host_alias" != x; then
690 if test "x$build_alias" = x; then
691 cross_compiling=maybe
692 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
693 If a cross compiler is detected then cross compile mode will be used." >&2
694 elif test "x$build_alias" != "x$host_alias"; then
695 cross_compiling=yes
696 fi
697fi
ba4481b5 698
503d2be0
AS
699ac_tool_prefix=
700test -n "$host_alias" && ac_tool_prefix=$host_alias-
ba4481b5 701
503d2be0 702test "$silent" = yes && exec 6>/dev/null
ba4481b5 703
c0d27fcc 704
ba4481b5
DL
705# Find the source files, if location was not specified.
706if test -z "$srcdir"; then
707 ac_srcdir_defaulted=yes
708 # Try the directory containing this script, then its parent.
c0d27fcc
MR
709 ac_confdir=`(dirname "$0") 2>/dev/null ||
710$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
711 X"$0" : 'X\(//\)[^/]' \| \
712 X"$0" : 'X\(//\)$' \| \
713 X"$0" : 'X\(/\)' \| \
714 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
715echo X"$0" |
716 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
717 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
718 /^X\(\/\/\)$/{ s//\1/; q; }
719 /^X\(\/\).*/{ s//\1/; q; }
720 s/.*/./; q'`
ba4481b5
DL
721 srcdir=$ac_confdir
722 if test ! -r $srcdir/$ac_unique_file; then
723 srcdir=..
724 fi
725else
726 ac_srcdir_defaulted=no
727fi
728if test ! -r $srcdir/$ac_unique_file; then
729 if test "$ac_srcdir_defaulted" = yes; then
c0d27fcc 730 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
503d2be0 731 { (exit 1); exit 1; }; }
ba4481b5 732 else
c0d27fcc 733 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
503d2be0 734 { (exit 1); exit 1; }; }
ba4481b5
DL
735 fi
736fi
6bae0ccf
DL
737(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
738 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
739 { (exit 1); exit 1; }; }
503d2be0
AS
740srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
741ac_env_build_alias_set=${build_alias+set}
742ac_env_build_alias_value=$build_alias
743ac_cv_env_build_alias_set=${build_alias+set}
744ac_cv_env_build_alias_value=$build_alias
745ac_env_host_alias_set=${host_alias+set}
746ac_env_host_alias_value=$host_alias
747ac_cv_env_host_alias_set=${host_alias+set}
748ac_cv_env_host_alias_value=$host_alias
749ac_env_target_alias_set=${target_alias+set}
750ac_env_target_alias_value=$target_alias
751ac_cv_env_target_alias_set=${target_alias+set}
752ac_cv_env_target_alias_value=$target_alias
753ac_env_CC_set=${CC+set}
754ac_env_CC_value=$CC
755ac_cv_env_CC_set=${CC+set}
756ac_cv_env_CC_value=$CC
757ac_env_CFLAGS_set=${CFLAGS+set}
758ac_env_CFLAGS_value=$CFLAGS
759ac_cv_env_CFLAGS_set=${CFLAGS+set}
760ac_cv_env_CFLAGS_value=$CFLAGS
761ac_env_LDFLAGS_set=${LDFLAGS+set}
762ac_env_LDFLAGS_value=$LDFLAGS
763ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
764ac_cv_env_LDFLAGS_value=$LDFLAGS
765ac_env_CPPFLAGS_set=${CPPFLAGS+set}
766ac_env_CPPFLAGS_value=$CPPFLAGS
767ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
768ac_cv_env_CPPFLAGS_value=$CPPFLAGS
769ac_env_CPP_set=${CPP+set}
770ac_env_CPP_value=$CPP
771ac_cv_env_CPP_set=${CPP+set}
772ac_cv_env_CPP_value=$CPP
773
774#
775# Report the --help message.
776#
777if test "$ac_init_help" = "long"; then
778 # Omit some internal or obsolete options to make the list less imposing.
779 # This message is too long to be a string in the A/UX 3.1 sh.
c0d27fcc 780 cat <<_ACEOF
503d2be0
AS
781\`configure' configures this package to adapt to many kinds of systems.
782
783Usage: $0 [OPTION]... [VAR=VALUE]...
784
785To assign environment variables (e.g., CC, CFLAGS...), specify them as
786VAR=VALUE. See below for descriptions of some of the useful variables.
787
788Defaults for the options are specified in brackets.
789
790Configuration:
791 -h, --help display this help and exit
792 --help=short display options specific to this package
793 --help=recursive display the short help of all the included packages
794 -V, --version display version information and exit
795 -q, --quiet, --silent do not print \`checking...' messages
796 --cache-file=FILE cache test results in FILE [disabled]
797 -C, --config-cache alias for \`--cache-file=config.cache'
798 -n, --no-create do not create output files
799 --srcdir=DIR find the sources in DIR [configure dir or \`..']
800
c0d27fcc 801_ACEOF
503d2be0 802
c0d27fcc 803 cat <<_ACEOF
503d2be0
AS
804Installation directories:
805 --prefix=PREFIX install architecture-independent files in PREFIX
7c9e5167 806 [$ac_default_prefix]
503d2be0 807 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
7c9e5167 808 [PREFIX]
503d2be0
AS
809
810By default, \`make install' will install all the files in
811\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
812an installation prefix other than \`$ac_default_prefix' using \`--prefix',
813for instance \`--prefix=\$HOME'.
814
815For better control, use the options below.
816
817Fine tuning of the installation directories:
818 --bindir=DIR user executables [EPREFIX/bin]
819 --sbindir=DIR system admin executables [EPREFIX/sbin]
820 --libexecdir=DIR program executables [EPREFIX/libexec]
821 --datadir=DIR read-only architecture-independent data [PREFIX/share]
822 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
823 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
824 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
825 --libdir=DIR object code libraries [EPREFIX/lib]
826 --includedir=DIR C header files [PREFIX/include]
827 --oldincludedir=DIR C header files for non-gcc [/usr/include]
828 --infodir=DIR info documentation [PREFIX/info]
829 --mandir=DIR man documentation [PREFIX/man]
c0d27fcc 830_ACEOF
503d2be0 831
c0d27fcc 832 cat <<\_ACEOF
503d2be0 833
ba5da88a
PJ
834Program names:
835 --program-prefix=PREFIX prepend PREFIX to installed program names
836 --program-suffix=SUFFIX append SUFFIX to installed program names
837 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
838
503d2be0
AS
839X features:
840 --x-includes=DIR X include files are in DIR
841 --x-libraries=DIR X library files are in DIR
842
843System types:
844 --build=BUILD configure for building on BUILD [guessed]
c0d27fcc
MR
845 --host=HOST cross-compile to build programs to run on HOST [BUILD]
846_ACEOF
503d2be0
AS
847fi
848
849if test -n "$ac_init_help"; then
850
c0d27fcc 851 cat <<\_ACEOF
503d2be0
AS
852
853Optional Features:
854 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
855 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
6a3a24fa
JD
856 --enable-carbon-app[=DIR] [DIR=/Application]
857 specify install directory for Emacs.app on Mac OS X
d0098f13 858 --enable-asserts compile code with asserts enabled
19650fd6
AS
859 --enable-maintainer-mode enable make rules and dependencies not useful
860 (and sometimes confusing) to the casual installer
9adfabc2
LK
861 --enable-locallisppath=PATH
862 directories Emacs should search for lisp files
863 specific to this site
503d2be0
AS
864 --disable-largefile omit support for large files
865
866Optional Packages:
867 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
868 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
869 --without-gcc don't use GCC to compile Emacs if GCC is found
870 --without-pop don't support POP mail retrieval with movemail
871 --with-kerberos support Kerberos-authenticated POP
872 --with-kerberos5 support Kerberos version 5 authenticated POP
873 --with-hesiod support Hesiod to get the POP server host
2c9dccc9 874 --without-sound don't compile with sound support
488dd4c4
JD
875 --with-x-toolkit=KIT use an X toolkit
876 (KIT = yes/lucid/athena/motif/gtk/no)
503d2be0
AS
877 --with-xpm use -lXpm for displaying XPM images
878 --with-jpeg use -ljpeg for displaying JPEG images
879 --with-tiff use -ltiff for displaying TIFF images
880 --with-gif use -lungif for displaying GIF images
881 --with-png use -lpng for displaying PNG images
488dd4c4
JD
882 --with-gtk use GTK (same as --with-x-toolkit=gtk)
883 --with-pkg-config-prog Path to pkg-config to use for finding GTK
503d2be0 884 --without-toolkit-scroll-bars
cc227489
MB
885 don't use Motif or Xaw3d scroll bars
886 --without-xim don't use X11 XIM
e0f712ba 887 --without-carbon don't use Carbon GUI on Mac OS X
503d2be0
AS
888 --with-x use the X Window System
889
890Some influential environment variables:
891 CC C compiler command
892 CFLAGS C compiler flags
893 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
894 nonstandard directory <lib dir>
895 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
896 headers in a nonstandard directory <include dir>
897 CPP C preprocessor
898
899Use these variables to override the choices made by `configure' or to help
900it to find libraries and programs with nonstandard names/locations.
901
c0d27fcc 902_ACEOF
503d2be0
AS
903fi
904
905if test "$ac_init_help" = "recursive"; then
906 # If there are subdirs, report their specific --help.
907 ac_popdir=`pwd`
c0d27fcc
MR
908 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
909 test -d $ac_dir || continue
910 ac_builddir=.
911
912if test "$ac_dir" != .; then
913 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
914 # A "../" for each directory in $ac_dir_suffix.
915 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
916else
917 ac_dir_suffix= ac_top_builddir=
918fi
503d2be0 919
c0d27fcc
MR
920case $srcdir in
921 .) # No --srcdir option. We are building in place.
922 ac_srcdir=.
923 if test -z "$ac_top_builddir"; then
924 ac_top_srcdir=.
925 else
926 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
927 fi ;;
928 [\\/]* | ?:[\\/]* ) # Absolute path.
929 ac_srcdir=$srcdir$ac_dir_suffix;
930 ac_top_srcdir=$srcdir ;;
931 *) # Relative path.
932 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
933 ac_top_srcdir=$ac_top_builddir$srcdir ;;
934esac
7c9e5167
JD
935# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
936# absolute.
937ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
938ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
939ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
940ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
c0d27fcc
MR
941
942 cd $ac_dir
503d2be0 943 # Check for guested configure; otherwise get Cygnus style configure.
c0d27fcc 944 if test -f $ac_srcdir/configure.gnu; then
503d2be0 945 echo
c0d27fcc
MR
946 $SHELL $ac_srcdir/configure.gnu --help=recursive
947 elif test -f $ac_srcdir/configure; then
503d2be0 948 echo
c0d27fcc
MR
949 $SHELL $ac_srcdir/configure --help=recursive
950 elif test -f $ac_srcdir/configure.ac ||
7c9e5167 951 test -f $ac_srcdir/configure.in; then
503d2be0
AS
952 echo
953 $ac_configure --help
954 else
c0d27fcc 955 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
503d2be0 956 fi
7c9e5167 957 cd $ac_popdir
503d2be0
AS
958 done
959fi
960
961test -n "$ac_init_help" && exit 0
962if $ac_init_version; then
c0d27fcc 963 cat <<\_ACEOF
503d2be0 964
7c9e5167
JD
965Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
966Free Software Foundation, Inc.
503d2be0
AS
967This configure script is free software; the Free Software Foundation
968gives unlimited permission to copy, distribute and modify it.
c0d27fcc 969_ACEOF
503d2be0
AS
970 exit 0
971fi
972exec 5>config.log
c0d27fcc 973cat >&5 <<_ACEOF
503d2be0
AS
974This file contains any messages produced by compilers while
975running configure, to aid debugging if configure makes a mistake.
976
977It was created by $as_me, which was
7c9e5167 978generated by GNU Autoconf 2.57. Invocation command line was
503d2be0
AS
979
980 $ $0 $@
981
c0d27fcc 982_ACEOF
503d2be0
AS
983{
984cat <<_ASUNAME
c0d27fcc
MR
985## --------- ##
986## Platform. ##
987## --------- ##
503d2be0
AS
988
989hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
990uname -m = `(uname -m) 2>/dev/null || echo unknown`
991uname -r = `(uname -r) 2>/dev/null || echo unknown`
992uname -s = `(uname -s) 2>/dev/null || echo unknown`
993uname -v = `(uname -v) 2>/dev/null || echo unknown`
994
995/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
996/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
997
998/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
999/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1000/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1001hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
1002/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1003/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1004/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1005
925c2f3f 1006_ASUNAME
c0d27fcc
MR
1007
1008as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1009for as_dir in $PATH
1010do
1011 IFS=$as_save_IFS
1012 test -z "$as_dir" && as_dir=.
1013 echo "PATH: $as_dir"
1014done
1015
503d2be0
AS
1016} >&5
1017
c0d27fcc
MR
1018cat >&5 <<_ACEOF
1019
1020
1021## ----------- ##
1022## Core tests. ##
1023## ----------- ##
1024
1025_ACEOF
503d2be0 1026
503d2be0
AS
1027
1028# Keep a trace of the command line.
1029# Strip out --no-create and --no-recursion so they do not pile up.
19650fd6 1030# Strip out --silent because we don't want to record it for future runs.
503d2be0 1031# Also quote any args containing shell meta-characters.
19650fd6 1032# Make two passes to allow for proper duplicate-argument suppression.
503d2be0 1033ac_configure_args=
19650fd6
AS
1034ac_configure_args0=
1035ac_configure_args1=
503d2be0 1036ac_sep=
19650fd6
AS
1037ac_must_keep_next=false
1038for ac_pass in 1 2
503d2be0 1039do
19650fd6
AS
1040 for ac_arg
1041 do
1042 case $ac_arg in
1043 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1044 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1045 | -silent | --silent | --silen | --sile | --sil)
1046 continue ;;
1047 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1048 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1049 esac
1050 case $ac_pass in
1051 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1052 2)
1053 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1054 if test $ac_must_keep_next = true; then
7c9e5167 1055 ac_must_keep_next=false # Got value, back to normal.
19650fd6 1056 else
7c9e5167
JD
1057 case $ac_arg in
1058 *=* | --config-cache | -C | -disable-* | --disable-* \
1059 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1060 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1061 | -with-* | --with-* | -without-* | --without-* | --x)
1062 case "$ac_configure_args0 " in
1063 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1064 esac
1065 ;;
1066 -* ) ac_must_keep_next=true ;;
1067 esac
19650fd6
AS
1068 fi
1069 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1070 # Get rid of the leading space.
1071 ac_sep=" "
1072 ;;
1073 esac
1074 done
503d2be0 1075done
19650fd6
AS
1076$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1077$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
503d2be0
AS
1078
1079# When interrupted or exit'd, cleanup temporary files, and complete
1080# config.log. We remove comments because anyway the quotes in there
1081# would cause problems or look ugly.
c0d27fcc
MR
1082# WARNING: Be sure not to use single quotes in there, as some shells,
1083# such as our DU 5.0 friend, will then `close' the trap.
503d2be0
AS
1084trap 'exit_status=$?
1085 # Save into config.log some information that might help in debugging.
c0d27fcc
MR
1086 {
1087 echo
6bae0ccf 1088
c0d27fcc
MR
1089 cat <<\_ASBOX
1090## ---------------- ##
1091## Cache variables. ##
1092## ---------------- ##
1093_ASBOX
1094 echo
1095 # The following way of writing the cache mishandles newlines in values,
503d2be0
AS
1096{
1097 (set) 2>&1 |
1098 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1099 *ac_space=\ *)
1100 sed -n \
7c9e5167
JD
1101 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1102 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
503d2be0
AS
1103 ;;
1104 *)
1105 sed -n \
7c9e5167 1106 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
1107 ;;
1108 esac;
c0d27fcc
MR
1109}
1110 echo
6bae0ccf
DL
1111
1112 cat <<\_ASBOX
1113## ----------------- ##
1114## Output variables. ##
1115## ----------------- ##
1116_ASBOX
1117 echo
1118 for ac_var in $ac_subst_vars
1119 do
1120 eval ac_val=$`echo $ac_var`
1121 echo "$ac_var='"'"'$ac_val'"'"'"
1122 done | sort
1123 echo
1124
1125 if test -n "$ac_subst_files"; then
1126 cat <<\_ASBOX
1127## ------------- ##
1128## Output files. ##
1129## ------------- ##
1130_ASBOX
1131 echo
1132 for ac_var in $ac_subst_files
1133 do
1134 eval ac_val=$`echo $ac_var`
7c9e5167 1135 echo "$ac_var='"'"'$ac_val'"'"'"
6bae0ccf
DL
1136 done | sort
1137 echo
1138 fi
1139
c0d27fcc
MR
1140 if test -s confdefs.h; then
1141 cat <<\_ASBOX
1142## ----------- ##
1143## confdefs.h. ##
1144## ----------- ##
1145_ASBOX
1146 echo
6bae0ccf 1147 sed "/^$/d" confdefs.h | sort
c0d27fcc
MR
1148 echo
1149 fi
1150 test "$ac_signal" != 0 &&
1151 echo "$as_me: caught signal $ac_signal"
1152 echo "$as_me: exit $exit_status"
1153 } >&5
7c9e5167 1154 rm -f core core.* *.core &&
c0d27fcc 1155 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
503d2be0
AS
1156 exit $exit_status
1157 ' 0
1158for ac_signal in 1 2 13 15; do
1159 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1160done
1161ac_signal=0
1162
1163# confdefs.h avoids OS command line length limits that DEFS can exceed.
1164rm -rf conftest* confdefs.h
1165# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1166echo >confdefs.h
ba4481b5 1167
c0d27fcc
MR
1168# Predefined preprocessor variables.
1169
1170cat >>confdefs.h <<_ACEOF
1171#define PACKAGE_NAME "$PACKAGE_NAME"
1172_ACEOF
1173
1174
1175cat >>confdefs.h <<_ACEOF
1176#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1177_ACEOF
1178
1179
1180cat >>confdefs.h <<_ACEOF
1181#define PACKAGE_VERSION "$PACKAGE_VERSION"
1182_ACEOF
1183
1184
1185cat >>confdefs.h <<_ACEOF
1186#define PACKAGE_STRING "$PACKAGE_STRING"
1187_ACEOF
1188
1189
1190cat >>confdefs.h <<_ACEOF
1191#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1192_ACEOF
1193
1194
503d2be0 1195# Let the site file select an alternate cache file if it wants to.
ba4481b5
DL
1196# Prefer explicitly selected file to automatically selected ones.
1197if test -z "$CONFIG_SITE"; then
1198 if test "x$prefix" != xNONE; then
1199 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1200 else
1201 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1202 fi
1203fi
1204for ac_site_file in $CONFIG_SITE; do
1205 if test -r "$ac_site_file"; then
c0d27fcc 1206 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
503d2be0 1207echo "$as_me: loading site script $ac_site_file" >&6;}
c0d27fcc 1208 sed 's/^/| /' "$ac_site_file" >&5
ba4481b5
DL
1209 . "$ac_site_file"
1210 fi
1211done
1212
1213if test -r "$cache_file"; then
503d2be0
AS
1214 # Some versions of bash will fail to source /dev/null (special
1215 # files actually), so we avoid doing that.
1216 if test -f "$cache_file"; then
c0d27fcc 1217 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
503d2be0
AS
1218echo "$as_me: loading cache $cache_file" >&6;}
1219 case $cache_file in
1220 [\\/]* | ?:[\\/]* ) . $cache_file;;
1221 *) . ./$cache_file;;
1222 esac
1223 fi
ba4481b5 1224else
c0d27fcc 1225 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
503d2be0
AS
1226echo "$as_me: creating cache $cache_file" >&6;}
1227 >$cache_file
1228fi
1229
1230# Check that the precious variables saved in the cache have kept the same
1231# value.
1232ac_cache_corrupted=false
1233for ac_var in `(set) 2>&1 |
7c9e5167 1234 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
503d2be0
AS
1235 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1236 eval ac_new_set=\$ac_env_${ac_var}_set
1237 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1238 eval ac_new_val="\$ac_env_${ac_var}_value"
1239 case $ac_old_set,$ac_new_set in
1240 set,)
c0d27fcc 1241 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
503d2be0
AS
1242echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1243 ac_cache_corrupted=: ;;
1244 ,set)
c0d27fcc 1245 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
503d2be0
AS
1246echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1247 ac_cache_corrupted=: ;;
1248 ,);;
1249 *)
1250 if test "x$ac_old_val" != "x$ac_new_val"; then
7c9e5167 1251 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
503d2be0 1252echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
7c9e5167 1253 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
503d2be0 1254echo "$as_me: former value: $ac_old_val" >&2;}
7c9e5167 1255 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
503d2be0 1256echo "$as_me: current value: $ac_new_val" >&2;}
7c9e5167 1257 ac_cache_corrupted=:
503d2be0
AS
1258 fi;;
1259 esac
c0d27fcc 1260 # Pass precious variables to config.status.
503d2be0
AS
1261 if test "$ac_new_set" = set; then
1262 case $ac_new_val in
1263 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
c0d27fcc
MR
1264 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1265 *) ac_arg=$ac_var=$ac_new_val ;;
1266 esac
1267 case " $ac_configure_args " in
1268 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1269 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
503d2be0
AS
1270 esac
1271 fi
1272done
1273if $ac_cache_corrupted; then
c0d27fcc 1274 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
503d2be0 1275echo "$as_me: error: changes in the environment can compromise the build" >&2;}
c0d27fcc 1276 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
503d2be0
AS
1277echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1278 { (exit 1); exit 1; }; }
ba4481b5
DL
1279fi
1280
1281ac_ext=c
ba4481b5 1282ac_cpp='$CPP $CPPFLAGS'
503d2be0
AS
1283ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1284ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1285ac_compiler_gnu=$ac_cv_c_compiler_gnu
1286
c0d27fcc
MR
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
ba4481b5 1303
6bae0ccf
DL
1304
1305 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
ba4481b5 1306
c0d27fcc 1307
ba5da88a
PJ
1308test "$program_prefix" != NONE &&
1309 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1310# Use a double $ so make ignores it.
1311test "$program_suffix" != NONE &&
1312 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1313# Double any \ or $. echo might interpret backslashes.
1314# By default was `s,x,x', remove it if useless.
1315cat <<\_ACEOF >conftest.sed
1316s/[\\$]/&&/g;s/;s,x,x,$//
1317_ACEOF
1318program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1319rm conftest.sed
1320
c0d27fcc 1321
ba4481b5
DL
1322lispdir='${datadir}/emacs/${version}/lisp'
1323locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1324'${datadir}/emacs/site-lisp:${datadir}/emacs/${version}/leim'
1325lisppath='${locallisppath}:${lispdir}'
1326etcdir='${datadir}/emacs/${version}/etc'
1327archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1328docdir='${datadir}/emacs/${version}/etc'
24b01ec4 1329gamedir='${localstatedir}/games/emacs'
98418dba
CW
1330
1331gameuser=games
1332
c0d27fcc 1333
ba4481b5
DL
1334# Check whether --with-gcc or --without-gcc was given.
1335if test "${with_gcc+set}" = set; then
1336 withval="$with_gcc"
503d2be0
AS
1337
1338fi;
ba4481b5
DL
1339
1340# Check whether --with-pop or --without-pop was given.
1341if test "${with_pop+set}" = set; then
1342 withval="$with_pop"
243cf185 1343 if test "$withval" = yes; then
c0d27fcc 1344 cat >>confdefs.h <<\_ACEOF
ba4481b5 1345#define MAIL_USE_POP 1
c0d27fcc 1346_ACEOF
ba4481b5 1347
243cf185
DL
1348else :
1349fi
3d9fec71 1350else
c0d27fcc 1351 cat >>confdefs.h <<\_ACEOF
3d9fec71 1352#define MAIL_USE_POP 1
c0d27fcc 1353_ACEOF
3d9fec71 1354
503d2be0 1355fi;
ba4481b5 1356
c0d27fcc 1357
a21616bd
KR
1358# Check whether --with-kerberos or --without-kerberos was given.
1359if test "${with_kerberos+set}" = set; then
1360 withval="$with_kerberos"
c0d27fcc 1361 cat >>confdefs.h <<\_ACEOF
a21616bd 1362#define KERBEROS 1
c0d27fcc 1363_ACEOF
a21616bd 1364
503d2be0 1365fi;
a21616bd 1366
c0d27fcc 1367
a21616bd
KR
1368# Check whether --with-kerberos5 or --without-kerberos5 was given.
1369if test "${with_kerberos5+set}" = set; then
1370 withval="$with_kerberos5"
1371 if test "${with_kerberos5+set}" = set; then
1372 if test "${with_kerberos+set}" != set; then
1373 with_kerberos=yes
c0d27fcc 1374 cat >>confdefs.h <<\_ACEOF
a21616bd 1375#define KERBEROS 1
c0d27fcc 1376_ACEOF
a21616bd
KR
1377
1378 fi
1379fi
b936fae4 1380
c0d27fcc 1381cat >>confdefs.h <<\_ACEOF
a21616bd 1382#define KERBEROS5 1
c0d27fcc 1383_ACEOF
a21616bd 1384
503d2be0 1385fi;
a21616bd 1386
ba4481b5
DL
1387# Check whether --with-hesiod or --without-hesiod was given.
1388if test "${with_hesiod+set}" = set; then
1389 withval="$with_hesiod"
b936fae4 1390
c0d27fcc 1391cat >>confdefs.h <<\_ACEOF
ba4481b5 1392#define HESIOD 1
c0d27fcc 1393_ACEOF
ba4481b5 1394
503d2be0 1395fi;
ba4481b5 1396
c0d27fcc 1397
2c9dccc9
PJ
1398# Check whether --with-sound or --without-sound was given.
1399if test "${with_sound+set}" = set; then
1400 withval="$with_sound"
1401
1402fi;
1403
c0d27fcc 1404
ba4481b5
DL
1405# Check whether --with-x-toolkit or --without-x-toolkit was given.
1406if test "${with_x_toolkit+set}" = set; then
1407 withval="$with_x_toolkit"
1408 case "${withval}" in
1409 y | ye | yes ) val=athena ;;
1410 n | no ) val=no ;;
1411 l | lu | luc | luci | lucid ) val=lucid ;;
1412 a | at | ath | athe | athen | athena ) val=athena ;;
1413 m | mo | mot | moti | motif ) val=motif ;;
488dd4c4 1414 g | gt | gtk ) val=gtk ;;
ba4481b5 1415 * )
c0d27fcc 1416{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1417this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1418Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1419echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1420this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1421Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1422 { (exit 1); exit 1; }; }
ba4481b5
DL
1423 ;;
1424 esac
1425 with_x_toolkit=$val
1426
503d2be0 1427fi;
ba4481b5
DL
1428
1429# Check whether --with-xpm or --without-xpm was given.
1430if test "${with_xpm+set}" = set; then
1431 withval="$with_xpm"
503d2be0
AS
1432
1433fi;
ba4481b5
DL
1434
1435# Check whether --with-jpeg or --without-jpeg was given.
1436if test "${with_jpeg+set}" = set; then
1437 withval="$with_jpeg"
503d2be0
AS
1438
1439fi;
ba4481b5
DL
1440
1441# Check whether --with-tiff or --without-tiff was given.
1442if test "${with_tiff+set}" = set; then
1443 withval="$with_tiff"
503d2be0
AS
1444
1445fi;
ba4481b5
DL
1446
1447# Check whether --with-gif or --without-gif was given.
1448if test "${with_gif+set}" = set; then
1449 withval="$with_gif"
503d2be0
AS
1450
1451fi;
ba4481b5
DL
1452
1453# Check whether --with-png or --without-png was given.
1454if test "${with_png+set}" = set; then
1455 withval="$with_png"
503d2be0
AS
1456
1457fi;
ba4481b5 1458
488dd4c4
JD
1459# Check whether --with-gtk or --without-gtk was given.
1460if test "${with_gtk+set}" = set; then
1461 withval="$with_gtk"
1462
1463fi;
1464
1465# Check whether --with-pkg-config-prog or --without-pkg-config-prog was given.
1466if test "${with_pkg_config_prog+set}" = set; then
1467 withval="$with_pkg_config_prog"
1468
1469fi;
1470
ba4481b5
DL
1471# Check whether --with-toolkit-scroll-bars or --without-toolkit-scroll-bars was given.
1472if test "${with_toolkit_scroll_bars+set}" = set; then
1473 withval="$with_toolkit_scroll_bars"
503d2be0
AS
1474
1475fi;
ba4481b5 1476
1d36487c
GM
1477# Check whether --with-xim or --without-xim was given.
1478if test "${with_xim+set}" = set; then
1479 withval="$with_xim"
1d36487c 1480
503d2be0 1481fi;
ba4481b5 1482
e0f712ba
AC
1483# Check whether --with-carbon or --without-carbon was given.
1484if test "${with_carbon+set}" = set; then
1485 withval="$with_carbon"
1486
1487fi;
6a3a24fa
JD
1488# Check whether --enable-carbon-app or --disable-carbon-app was given.
1489if test "${enable_carbon_app+set}" = set; then
1490 enableval="$enable_carbon_app"
1491 carbon_appdir_x=${enableval}
1492fi;
e0f712ba 1493
d0098f13
JD
1494# Check whether --enable-asserts or --disable-asserts was given.
1495if test "${enable_asserts+set}" = set; then
1496 enableval="$enable_asserts"
1497 USE_XASSERTS=$enableval
1498else
1499 USE_XASSERTS=no
1500fi;
1501
19650fd6
AS
1502# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
1503if test "${enable_maintainer_mode+set}" = set; then
1504 enableval="$enable_maintainer_mode"
1505 USE_MAINTAINER_MODE=$enableval
1506else
1507 USE_MAINTAINER_MODE=no
1508fi;
1509if test $USE_MAINTAINER_MODE = yes; then
1510 MAINT=
1511else
1512 MAINT=#
1513fi
1514
1515
9adfabc2
LK
1516# Check whether --enable-locallisppath or --disable-locallisppath was given.
1517if test "${enable_locallisppath+set}" = set; then
1518 enableval="$enable_locallisppath"
1519 if test "${enableval}" = "no"; then
1520 locallisppath=
1521elif test "${enableval}" != "yes"; then
1522 locallisppath=${enableval}
1523fi
1524fi;
1525
ba4481b5 1526#### Make srcdir absolute, if it isn't already. It's important to
17494071 1527#### avoid running the path through pwd unnecessarily, since pwd can
ba4481b5
DL
1528#### give you automounter prefixes, which can go away. We do all this
1529#### so Emacs can find its files when run uninstalled.
17494071
GM
1530## Make sure CDPATH doesn't affect cd (in case PWD is relative).
1531unset CDPATH
ba4481b5
DL
1532case "${srcdir}" in
1533 /* ) ;;
1534 . )
1535 ## We may be able to use the $PWD environment variable to make this
1536 ## absolute. But sometimes PWD is inaccurate.
df645f7c
AS
1537 ## Note: we used to use ${PWD} at the end instead of `pwd`,
1538 ## but that tested only for a well-formed and valid PWD,
1539 ## it did not object when PWD was well-formed and valid but just wrong.
1540 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
ba4481b5
DL
1541 then
1542 srcdir="$PWD"
1543 else
1544 srcdir="`(cd ${srcdir}; pwd)`"
1545 fi
1546 ;;
1547 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
1548esac
1549
1550#### Check if the source directory already has a configured system in it.
1551if test `pwd` != `(cd ${srcdir} && pwd)` \
1552 && test -f "${srcdir}/src/config.h" ; then
c0d27fcc 1553 { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
503d2be0
AS
1554 as a build directory right now; it has been configured in its own
1555 right. To configure in another directory as well, you MUST
1556 use GNU make. If you do not have GNU make, then you must
1557 now do \`make distclean' in ${srcdir},
1558 and then run $0 again." >&5
1559echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
ba4481b5
DL
1560 as a build directory right now; it has been configured in its own
1561 right. To configure in another directory as well, you MUST
1562 use GNU make. If you do not have GNU make, then you must
1563 now do \`make distclean' in ${srcdir},
503d2be0 1564 and then run $0 again." >&2;}
ba4481b5
DL
1565fi
1566
1567#### Given the configuration name, set machfile and opsysfile to the
1568#### names of the m/*.h and s/*.h files we should use.
1569
1570### Canonicalize the configuration name.
1571
1572ac_aux_dir=
1573for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1574 if test -f $ac_dir/install-sh; then
1575 ac_aux_dir=$ac_dir
1576 ac_install_sh="$ac_aux_dir/install-sh -c"
1577 break
1578 elif test -f $ac_dir/install.sh; then
1579 ac_aux_dir=$ac_dir
1580 ac_install_sh="$ac_aux_dir/install.sh -c"
1581 break
503d2be0
AS
1582 elif test -f $ac_dir/shtool; then
1583 ac_aux_dir=$ac_dir
1584 ac_install_sh="$ac_aux_dir/shtool install -c"
1585 break
ba4481b5
DL
1586 fi
1587done
1588if test -z "$ac_aux_dir"; then
c0d27fcc 1589 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1590echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1591 { (exit 1); exit 1; }; }
ba4481b5 1592fi
503d2be0
AS
1593ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1594ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1595ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1596
1597# Make sure we can run config.sub.
503d2be0 1598$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1599 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1600echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1601 { (exit 1); exit 1; }; }
1602
c0d27fcc 1603echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1604echo $ECHO_N "checking build system type... $ECHO_C" >&6
1605if test "${ac_cv_build+set}" = set; then
1606 echo $ECHO_N "(cached) $ECHO_C" >&6
1607else
1608 ac_cv_build_alias=$build_alias
1609test -z "$ac_cv_build_alias" &&
1610 ac_cv_build_alias=`$ac_config_guess`
1611test -z "$ac_cv_build_alias" &&
c0d27fcc 1612 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1613echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1614 { (exit 1); exit 1; }; }
1615ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1616 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1617echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1618 { (exit 1); exit 1; }; }
1619
1620fi
c0d27fcc 1621echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1622echo "${ECHO_T}$ac_cv_build" >&6
1623build=$ac_cv_build
1624build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1625build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1626build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1627
c0d27fcc
MR
1628
1629echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1630echo $ECHO_N "checking host system type... $ECHO_C" >&6
1631if test "${ac_cv_host+set}" = set; then
1632 echo $ECHO_N "(cached) $ECHO_C" >&6
1633else
1634 ac_cv_host_alias=$host_alias
1635test -z "$ac_cv_host_alias" &&
1636 ac_cv_host_alias=$ac_cv_build_alias
1637ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1638 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1639echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1640 { (exit 1); exit 1; }; }
1641
1642fi
c0d27fcc 1643echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1644echo "${ECHO_T}$ac_cv_host" >&6
1645host=$ac_cv_host
1646host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1647host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1648host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1649
c0d27fcc 1650
ba4481b5 1651canonical=$host
531a3336 1652configuration=${host_alias-$host}
ba4481b5 1653
c0d27fcc 1654
22044edf 1655
ba4481b5
DL
1656### If you add support for a new configuration, add code to this
1657### switch statement to recognize your configuration name and select
1658### the appropriate operating system and machine description files.
1659
1660### You would hope that you could choose an m/*.h file pretty much
1661### based on the machine portion of the configuration name, and an s-
1662### file based on the operating system portion. However, it turns out
1663### that each m/*.h file is pretty manufacturer-specific - for
1664### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1665### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1666### machines. So we basically have to have a special case for each
1667### configuration name.
1668###
1669### As far as handling version numbers on operating systems is
1670### concerned, make sure things will fail in a fixable way. If
1671### /etc/MACHINES doesn't say anything about version numbers, be
1672### prepared to handle anything reasonably. If version numbers
1673### matter, be sure /etc/MACHINES says something about it.
1674###
1675### Eric Raymond says we should accept strings like "sysvr4" to mean
1676### "System V Release 4"; he writes, "The old convention encouraged
1677### confusion between `system' and `release' levels'."
1678
1679machine='' opsys='' unported=no
1680case "${canonical}" in
1681
1096bcc0
GM
1682 ## FreeBSD ports
1683 *-*-freebsd* )
1684 opsys=freebsd
1685 case "${canonical}" in
1686 alpha*-*-freebsd*) machine=alpha ;;
1687 i[3456]86-*-freebsd*) machine=intel386 ;;
1688 esac
1689 ;;
1690
ba4481b5
DL
1691 ## NetBSD ports
1692 *-*-netbsd* )
1693 opsys=netbsd
dd038e26 1694 if test -f /usr/lib/crti.o; then
f57bd967
DL
1695
1696cat >>confdefs.h <<\_ACEOF
1697#define HAVE_CRTIN
dd038e26
AS
1698_ACEOF
1699
1700 fi
1701
ba4481b5
DL
1702 case "${canonical}" in
1703 alpha*-*-netbsd*) machine=alpha ;;
1704 i[3456]86-*-netbsd*) machine=intel386 ;;
1705 m68k-*-netbsd*)
1706 # This is somewhat bogus.
1707 machine=hp9000s300 ;;
1708 powerpc-apple-netbsd*) machine=macppc ;;
1709 mips-*-netbsd*) machine=pmax ;;
2df636f4 1710 mipsel-*-netbsd*) machine=pmax ;;
97836269 1711 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1712 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1713 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1714 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1715 vax-*-netbsd*) machine=vax ;;
2df636f4 1716 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1717 esac
1718 ;;
1719
1720 ## OpenBSD ports
1721 *-*-openbsd* )
1722 opsys=openbsd
1723 case "${canonical}" in
1724 alpha*-*-openbsd*) machine=alpha ;;
1725 i386-*-openbsd*) machine=intel386 ;;
1726 m68k-*-openbsd*) machine=hp9000s300 ;;
1727 mipsel-*-openbsd*) machine=pmax ;;
1728 ns32k-*-openbsd*) machine=ns32000 ;;
1729 sparc-*-openbsd*) machine=sparc ;;
1730 vax-*-openbsd*) machine=vax ;;
1731 esac
1732 ;;
1733
1734 ## Acorn RISCiX:
1735 arm-acorn-riscix1.1* )
1736 machine=acorn opsys=riscix1-1
1737 ;;
1738 arm-acorn-riscix1.2* | arm-acorn-riscix )
1739 ## This name is riscix12 instead of riscix1.2
1740 ## to avoid a file name conflict on MSDOS.
1741 machine=acorn opsys=riscix12
1742 ;;
1743
1744 ## BSDI ports
1745 *-*-bsdi* )
1746 opsys=bsdi
1747 case "${canonical}" in
1748 i[345]86-*-bsdi*) machine=intel386 ;;
1749 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1750 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1751 esac
1752 case "${canonical}" in
1753 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1754 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1755 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1756 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1757 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1758 esac
1759 ;;
1760
1761 ## Alliant machines
1762 ## Strictly speaking, we need the version of the alliant operating
1763 ## system to choose the right machine file, but currently the
1764 ## configuration name doesn't tell us enough to choose the right
1765 ## one; we need to give alliants their own operating system name to
1766 ## do this right. When someone cares, they can help us.
1767 fx80-alliant-* )
1768 machine=alliant4 opsys=bsd4-2
1769 ;;
1770 i860-alliant-* )
1771 machine=alliant-2800 opsys=bsd4-3
1772 ;;
1773
1774 ## Alpha (DEC) machines.
1775 alpha*-dec-osf* )
1776 machine=alpha opsys=osf1
1777 # This is needed to find X11R6.1 libraries for certain tests.
1778 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1779 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1780 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1781 # due to non-traditional preprocessing with the current compiler
1782 # defaults. OSF 4 can also have that compiler version, and there
1783 # seems always to have been a usable /usr/bin/cpp.
1784 NON_GNU_CPP=/usr/bin/cpp
ca512671 1785 case "${canonical}" in
a55b799a 1786 alpha*-dec-osf[5-9]*)
bb17930d 1787 opsys=osf5-0 ;;
ca512671 1788 esac
ba4481b5
DL
1789 ;;
1790
1791 alpha*-*-linux-gnu* )
1792 machine=alpha opsys=gnu-linux
1793 ;;
1794
c4bb2108
DL
1795 arm*-*-linux-gnu* )
1796 machine=arm opsys=gnu-linux
1797 ;;
1798
ba4481b5
DL
1799 ## Altos 3068
1800 m68*-altos-sysv* )
1801 machine=altos opsys=usg5-2
1802 ;;
1803
1804 ## Amdahl UTS
1805 580-amdahl-sysv* )
1806 machine=amdahl opsys=usg5-2-2
1807 ;;
1808
1809 ## Apollo, Domain/OS
1810 m68*-apollo-* )
1811 machine=apollo opsys=bsd4-3
1812 ;;
1813
1814 ## AT&T 3b2, 3b5, 3b15, 3b20
1815 we32k-att-sysv* )
1816 machine=att3b opsys=usg5-2-2
1817 ;;
1818
1819 ## AT&T 3b1 - The Mighty Unix PC!
1820 m68*-att-sysv* )
1821 machine=7300 opsys=usg5-2-2
1822 ;;
1823
1824 ## Bull dpx20
1825 rs6000-bull-bosx* )
1826 machine=ibmrs6000 opsys=aix3-2
1827 ;;
1828
1829 ## Bull dpx2
1830 m68*-bull-sysv3* )
1831 machine=dpx2 opsys=usg5-3
1832 ;;
1833
1834 ## Bull sps7
1835 m68*-bull-sysv2* )
1836 machine=sps7 opsys=usg5-2
1837 ;;
1838
1839 ## CCI 5/32, 6/32 -- see "Tahoe".
1840
1841 ## Celerity
1842 ## I don't know what configuration name to use for this; config.sub
1843 ## doesn't seem to know anything about it. Hey, Celerity users, get
1844 ## in touch with us!
1845 celerity-celerity-bsd* )
1846 machine=celerity opsys=bsd4-2
1847 ;;
1848
1849 ## Clipper
1850 ## What operating systems does this chip run that Emacs has been
1851 ## tested on?
1852 clipper-* )
1853 machine=clipper
1854 ## We'll use the catch-all code at the bottom to guess the
1855 ## operating system.
1856 ;;
1857
df645f7c
AS
1858 ## Compaq Nonstop
1859 mips-compaq-nonstopux* )
1860 machine=nonstopux opsys=nonstopux
1861 ;;
1862
ba4481b5
DL
1863 ## Convex
1864 *-convex-bsd* | *-convex-convexos* )
1865 machine=convex opsys=bsd4-3
1866 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1867 NON_GNU_CPP="cc -E -P"
1868 ;;
1869
1870 ## Cubix QBx/386
1871 i[3456]86-cubix-sysv* )
1872 machine=intel386 opsys=usg5-3
1873 ;;
1874
1875 ## Cydra 5
1876 cydra*-cydrome-sysv* )
1877 machine=cydra5 opsys=usg5-3
1878 ;;
1879
1880 ## Data General AViiON Machines
1881 ## DG changed naming conventions with the release of 5.4.4.10, they
1882 ## dropped the initial 5.4 but left the intervening R. Because of the
1883 ## R this shouldn't conflict with older versions of the OS (which I
1884 ## think were named like dgux4.*). In addition, DG new AViiONs series
1885 ## uses either Motorola M88k or Intel Pentium CPUs.
1886 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1887 machine=aviion opsys=dgux4
1888 ;;
1889 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1890 ## This name is dgux5-4-3 instead of dgux5-4r3
1891 ## to avoid a file name conflict on MSDOS.
1892 machine=aviion opsys=dgux5-4-3
1893 ;;
1894 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1895 machine=aviion opsys=dgux5-4r2
1896 ;;
1897 m88k-dg-dgux* )
1898 machine=aviion opsys=dgux
1899 ;;
1900
1901 ## Data General AViiON Intel (x86) Machines
1902 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1903 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1904 i[345]86-dg-dguxR4* )
1905 machine=aviion-intel opsys=dgux4
1906 ;;
1907
1908 ## DECstations
1909 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1910 machine=pmax opsys=bsd4-2
1911 ;;
1912 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1913 machine=pmax opsys=bsd4-3
1914 ;;
1915 mips-dec-ultrix* )
1916 machine=pmax opsys=ultrix4-3
1917 ;;
1918 mips-dec-osf* )
1919 machine=pmax opsys=osf1
1920 ;;
1921 mips-dec-mach_bsd4.3* )
1922 machine=pmax opsys=mach-bsd4-3
1923 ;;
1924
cd890796
JD
1925 ## Motorola Delta machines
1926 m68k-motorola-sysv* | m68000-motorola-sysv* )
1927 machine=delta opsys=usg5-3
1928 if test -z "`type gnucc | grep 'not found'`"
1929 then
1930 if test -s /etc/167config
1931 then CC="gnucc -m68040"
1932 else CC="gnucc -m68881"
1933 fi
1934 else
1935 if test -z "`type gcc | grep 'not found'`"
1936 then CC=gcc
1937 else CC=cc
1938 fi
1939 fi
1940 ;;
ba4481b5
DL
1941 m88k-motorola-sysv4* )
1942 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1943 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1944 # I hope there are not other 4.0 versions for this machine
1945 # which really need usg5-4 instead.
1946 machine=delta88k opsys=usg5-4-2
1947 ;;
1948 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1949 machine=delta88k opsys=usg5-3
1950 ;;
1951
1952 ## Dual machines
1953 m68*-dual-sysv* )
1954 machine=dual opsys=usg5-2
1955 ;;
1956 m68*-dual-uniplus* )
1957 machine=dual opsys=unipl5-2
1958 ;;
1959
1960 ## Elxsi 6400
1961 elxsi-elxsi-sysv* )
1962 machine=elxsi opsys=usg5-2
1963 ;;
1964
1965 ## Encore machines
1966 ns16k-encore-bsd* )
1967 machine=ns16000 opsys=umax
1968 ;;
1969
65171e3a
DL
1970 ## The GEC 63 - apparently, this port isn't really finished yet.
1971 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
1972
1973 ## Gould Power Node and NP1
1974 pn-gould-bsd4.2* )
1975 machine=gould opsys=bsd4-2
1976 ;;
1977 pn-gould-bsd4.3* )
1978 machine=gould opsys=bsd4-3
1979 ;;
1980 np1-gould-bsd* )
1981 machine=gould-np1 opsys=bsd4-3
1982 ;;
1983
1984 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
1985 ## as far as Emacs is concerned).
1986 m88k-harris-cxux* )
1987 # Build needs to be different on 7.0 and later releases
1988 case "`uname -r`" in
1989 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
1990 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
1991 esac
1992 NON_GNU_CPP="/lib/cpp"
1993 ;;
1994 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
1995 m68k-harris-cxux* )
1996 machine=nh3000 opsys=cxux
1997 ;;
1998 ## Harris power pc NightHawk running Power UNIX (Series 6000)
1999 powerpc-harris-powerunix )
2000 machine=nh6000 opsys=powerunix
2001 NON_GNU_CPP="cc -Xo -E -P"
2002 ;;
2003 ## SR2001/SR2201 running HI-UX/MPP
2004 hppa1.1-hitachi-hiuxmpp* )
2005 machine=sr2k opsys=hiuxmpp
2006 ;;
89a336fa
GM
2007 hppa1.1-hitachi-hiuxwe2* )
2008 machine=sr2k opsys=hiuxwe2
2009 ;;
ba4481b5
DL
2010 ## Honeywell XPS100
2011 xps*-honeywell-sysv* )
2012 machine=xps100 opsys=usg5-2
2013 ;;
2014
2015 ## HP 9000 series 200 or 300
2016 m68*-hp-bsd* )
2017 machine=hp9000s300 opsys=bsd4-3
2018 ;;
2019 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
2020 m68*-hp-hpux* )
2021 case "`uname -r`" in
2022 ## Someone's system reports A.B8.05 for this.
2023 ## I wonder what other possibilities there are.
2024 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
2025 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
2026 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
2027 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
2028 *) machine=hp9000s300 opsys=hpux ;;
2029 esac
2030 ;;
2031
2032 ## HP 9000 series 700 and 800, running HP/UX
2033 hppa*-hp-hpux7* )
2034 machine=hp800 opsys=hpux
2035 ;;
2036 hppa*-hp-hpux8* )
2037 machine=hp800 opsys=hpux8
2038 ;;
2039 hppa*-hp-hpux9shr* )
2040 machine=hp800 opsys=hpux9shr
2041 ;;
2042 hppa*-hp-hpux9* )
2043 machine=hp800 opsys=hpux9
2044 ;;
b0e44248
RB
2045 hppa*-hp-hpux10.2* )
2046 machine=hp800 opsys=hpux10-20
2047 ;;
cc227489 2048 hppa*-hp-hpux10* )
ba4481b5
DL
2049 machine=hp800 opsys=hpux10
2050 ;;
cc227489
MB
2051 hppa*-hp-hpux1[1-9]* )
2052 machine=hp800 opsys=hpux11
2053 ;;
ba4481b5 2054
409d9577
GM
2055 hppa*-*-linux-gnu* )
2056 machine=hp800 opsys=gnu-linux
2057 ;;
2058
ba4481b5
DL
2059 ## HP 9000 series 700 and 800, running HP/UX
2060 hppa*-hp-hpux* )
2061 ## Cross-compilation? Nah!
2062 case "`uname -r`" in
2063 ## Someone's system reports A.B8.05 for this.
2064 ## I wonder what other possibilities there are.
2065 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2066 *.08.* ) machine=hp800 opsys=hpux8 ;;
2067 *.09.* ) machine=hp800 opsys=hpux9 ;;
2068 *) machine=hp800 opsys=hpux10 ;;
2069 esac
2070 ;;
2071 hppa*-*-nextstep* )
2072 machine=hp800 opsys=nextstep
2073 ;;
2074
2075 ## Orion machines
2076 orion-orion-bsd* )
2077 machine=orion opsys=bsd4-2
2078 ;;
2079 clipper-orion-bsd* )
2080 machine=orion105 opsys=bsd4-2
2081 ;;
2082
2083 ## IBM machines
2084 i[3456]86-ibm-aix1.1* )
2085 machine=ibmps2-aix opsys=usg5-2-2
2086 ;;
2087 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2088 machine=ibmps2-aix opsys=usg5-3
2089 ;;
2090 i370-ibm-aix*)
2091 machine=ibm370aix opsys=usg5-3
2092 ;;
55597d70 2093 s390-*-linux-gnu* )
138f0859
GM
2094 machine=ibms390 opsys=gnu-linux
2095 ;;
ba4481b5
DL
2096 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2097 machine=ibmrs6000 opsys=aix3-1
2098 ;;
2099 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2100 machine=ibmrs6000 opsys=aix3-2-5
2101 ;;
2102 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2103 machine=ibmrs6000 opsys=aix4-1
2104 ;;
2105 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2106 machine=ibmrs6000 opsys=aix4-2
2107 ;;
55597d70 2108 rs6000-ibm-aix5* | powerpc-ibm-aix5* )
d6b82250
EZ
2109 machine=ibmrs6000 opsys=aix4-2
2110 ;;
ba4481b5
DL
2111 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2112 machine=ibmrs6000 opsys=aix4
2113 ;;
2114 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2115 machine=ibmrs6000 opsys=aix4-1
2116 ;;
2117 rs6000-ibm-aix* | powerpc-ibm-aix* )
2118 machine=ibmrs6000 opsys=aix3-2
2119 ;;
2120 romp-ibm-bsd4.3* )
2121 machine=ibmrt opsys=bsd4-3
2122 ;;
2123 romp-ibm-bsd4.2* )
2124 machine=ibmrt opsys=bsd4-2
2125 ;;
2126 romp-ibm-aos4.3* )
2127 machine=ibmrt opsys=bsd4-3
2128 ;;
2129 romp-ibm-aos4.2* )
2130 machine=ibmrt opsys=bsd4-2
2131 ;;
2132 romp-ibm-aos* )
2133 machine=ibmrt opsys=bsd4-3
2134 ;;
2135 romp-ibm-bsd* )
2136 machine=ibmrt opsys=bsd4-3
2137 ;;
2138 romp-ibm-aix* )
2139 machine=ibmrt-aix opsys=usg5-2-2
2140 ;;
2141
2142 ## Integrated Solutions `Optimum V'
2143 m68*-isi-bsd4.2* )
2144 machine=isi-ov opsys=bsd4-2
2145 ;;
2146 m68*-isi-bsd4.3* )
2147 machine=isi-ov opsys=bsd4-3
2148 ;;
2149
2150 ## Intel 386 machines where we do care about the manufacturer
2151 i[3456]86-intsys-sysv* )
2152 machine=is386 opsys=usg5-2-2
2153 ;;
2154
2155 ## Prime EXL
2156 i[3456]86-prime-sysv* )
2157 machine=i386 opsys=usg5-3
2158 ;;
2159
2160 ## Sequent Symmetry running Dynix
2161 i[3456]86-sequent-bsd* )
2162 machine=symmetry opsys=bsd4-3
2163 ;;
2164
2165 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2166 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2167 machine=sequent-ptx opsys=ptx4
2168 NON_GNU_CPP=/lib/cpp
2169 ;;
2170
2171 ## Sequent Symmetry running DYNIX/ptx
2172 ## Use the old cpp rather than the newer ANSI one.
2173 i[3456]86-sequent-ptx* )
2174 machine=sequent-ptx opsys=ptx
2175 NON_GNU_CPP="/lib/cpp"
2176 ;;
2177
2178 ## ncr machine running svr4.3.
2179 i[3456]86-ncr-sysv4.3 )
2180 machine=ncr386 opsys=usg5-4-3
2181 ;;
2182
2183 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2184 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2185 i[3456]86-ncr-sysv* )
2186 machine=ncr386 opsys=usg5-4-2
2187 ;;
2188
2189 ## Intel Paragon OSF/1
2190 i860-intel-osf1* )
2191 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2192 ;;
2193
2194 ## Intel 860
2195 i860-*-sysv4* )
2196 machine=i860 opsys=usg5-4
2197 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2198 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2199 ;;
2200
c76e04a8
GM
2201 ## Macintosh PowerPC
2202 powerpc*-*-linux-gnu* )
2203 machine=macppc opsys=gnu-linux
2204 ;;
2205
ba4481b5
DL
2206 ## Masscomp machines
2207 m68*-masscomp-rtu* )
2208 machine=masscomp opsys=rtu
2209 ;;
2210
2211 ## Megatest machines
2212 m68*-megatest-bsd* )
2213 machine=mega68 opsys=bsd4-2
2214 ;;
2215
2216 ## Workstations sold by MIPS
2217 ## This is not necessarily all workstations using the MIPS processor -
2218 ## Irises are produced by SGI, and DECstations by DEC.
2219
2220 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2221 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2222 ## it gives for choosing between the alternatives seems to be "Use
2223 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2224 ## the BSD world." I'll assume that these are instructions for
2225 ## handling two odd situations, and that every other situation
2226 ## should use mips.h and usg5-2-2, they being listed first.
2227 mips-mips-usg* )
2228 machine=mips4
2229 ## Fall through to the general code at the bottom to decide on the OS.
2230 ;;
2231 mips-mips-riscos4* )
2232 machine=mips4 opsys=bsd4-3
2233 NON_GNU_CC="cc -systype bsd43"
2234 NON_GNU_CPP="cc -systype bsd43 -E"
2235 ;;
2236 mips-mips-riscos5* )
2237 machine=mips4 opsys=riscos5
2238 NON_GNU_CC="cc -systype bsd43"
2239 NON_GNU_CPP="cc -systype bsd43 -E"
2240 ;;
2241 mips-mips-bsd* )
2242 machine=mips opsys=bsd4-3
2243 ;;
2244 mips-mips-* )
2245 machine=mips opsys=usg5-2-2
2246 ;;
2247
2248 ## NeXT
2249 m68*-next-* | m68k-*-nextstep* )
2250 machine=m68k opsys=nextstep
2251 ;;
2252
2253 ## The complete machine from National Semiconductor
2254 ns32k-ns-genix* )
2255 machine=ns32000 opsys=usg5-2
2256 ;;
2257
2258 ## NCR machines
2259 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2260 machine=tower32 opsys=usg5-2-2
2261 ;;
2262 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2263 machine=tower32v3 opsys=usg5-3
2264 ;;
2265
2266 ## NEC EWS4800
2267 mips-nec-sysv4*)
2268 machine=ews4800 opsys=ux4800
2269 ;;
2270
2271 ## Nixdorf Targon 31
2272 m68*-nixdorf-sysv* )
2273 machine=targon31 opsys=usg5-2-2
2274 ;;
2275
2276 ## Nu (TI or LMI)
2277 m68*-nu-sysv* )
2278 machine=nu opsys=usg5-2
2279 ;;
2280
2281 ## Plexus
2282 m68*-plexus-sysv* )
2283 machine=plexus opsys=usg5-2
2284 ;;
2285
ba4481b5
DL
2286 ## Pyramid machines
2287 ## I don't really have any idea what sort of processor the Pyramid has,
2288 ## so I'm assuming it is its own architecture.
2289 pyramid-pyramid-bsd* )
2290 machine=pyramid opsys=bsd4-2
2291 ;;
2292
2293 ## Sequent Balance
2294 ns32k-sequent-bsd4.2* )
2295 machine=sequent opsys=bsd4-2
2296 ;;
2297 ns32k-sequent-bsd4.3* )
2298 machine=sequent opsys=bsd4-3
2299 ;;
2300
2301 ## Siemens Nixdorf
2302 mips-siemens-sysv* | mips-sni-sysv*)
2303 machine=mips-siemens opsys=usg5-4
2304 NON_GNU_CC=/usr/ccs/bin/cc
2305 NON_GNU_CPP=/usr/ccs/lib/cpp
2306 ;;
2307
2308 ## Silicon Graphics machines
2309 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2310 m68*-sgi-iris3.5* )
2311 machine=irist opsys=iris3-5
2312 ;;
2313 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2314 machine=irist opsys=iris3-6
2315 ;;
2316 ## Iris 4D
2317 mips-sgi-irix3* )
2318 machine=iris4d opsys=irix3-3
2319 ;;
2320 mips-sgi-irix4* )
2321 machine=iris4d opsys=irix4-0
2322 ;;
2323 mips-sgi-irix6.5 )
2324 machine=iris4d opsys=irix6-5
946173ad
DL
2325 # Without defining _LANGUAGE_C, things get masked out in the headers
2326 # so that, for instance, grepping for `free' in stdlib.h fails and
2327 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2328 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2329 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2330 ;;
2331 mips-sgi-irix6* )
2332 machine=iris4d opsys=irix6-0
c4bb2108 2333 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2334 # but presumably it does no harm.
2335 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2336 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2337 NON_GCC_TEST_OPTIONS=-32
2338 ;;
2339 mips-sgi-irix5.[01]* )
2340 machine=iris4d opsys=irix5-0
2341 ;;
2342 mips-sgi-irix5* | mips-sgi-irix* )
2343 machine=iris4d opsys=irix5-2
2344 ;;
2345
2346 ## SONY machines
2347 m68*-sony-bsd4.2* )
2348 machine=news opsys=bsd4-2
2349 ;;
2350 m68*-sony-bsd4.3* )
2351 machine=news opsys=bsd4-3
2352 ;;
2353 m68*-sony-newsos3* | m68*-sony-news3*)
2354 machine=news opsys=bsd4-3
2355 ;;
2356 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2357 machine=news-risc opsys=bsd4-3
2358 ;;
2359 mips-sony-newsos6* )
2360 machine=news-r6 opsys=newsos6
2361 ;;
2362 mips-sony-news* )
2363 machine=news-risc opsys=newsos5
2364 ;;
2365
2366 ## Stride
2367 m68*-stride-sysv* )
2368 machine=stride opsys=usg5-2
2369 ;;
2370
2371 ## Suns
2372 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2373 machine=sparc opsys=gnu-linux
2374 ;;
2375
d054101f 2376 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2377 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2378 | rs6000-*-solaris2*)
2379 case "${canonical}" in
2380 m68*-sunos1* ) machine=sun1 ;;
2381 m68*-sunos2* ) machine=sun2 ;;
2382 m68* ) machine=sun3 ;;
2383 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2384 i[3456]86-*-* ) machine=intel386 ;;
2385 powerpcle* ) machine=powerpcle ;;
2386 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2387 sparc* ) machine=sparc ;;
2388 * ) unported=yes ;;
2389 esac
2390 case "${canonical}" in
2391 ## The Sun386 didn't get past 4.0.
2392 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2393 *-sunos4.0* ) opsys=sunos4-0 ;;
2394 *-sunos4.1.[3-9]*noshare )
2395 ## This name is sunos413 instead of sunos4-1-3
2396 ## to avoid a file name conflict on MSDOS.
2397 opsys=sunos413
2398 NON_GNU_CPP=/usr/lib/cpp
2399 NON_GCC_TEST_OPTIONS=-Bstatic
2400 GCC_TEST_OPTIONS=-static
2401 ;;
2402 *-sunos4.1.[3-9]* | *-sunos4shr*)
2403 opsys=sunos4shr
2404 NON_GNU_CPP=/usr/lib/cpp
2405 ;;
2406 *-sunos4* | *-sunos )
2407 opsys=sunos4-1
2408 NON_GCC_TEST_OPTIONS=-Bstatic
2409 GCC_TEST_OPTIONS=-static
2410 ;;
2411 *-sunos5.3* | *-solaris2.3* )
2412 opsys=sol2-3
2413 NON_GNU_CPP=/usr/ccs/lib/cpp
2414 ;;
2415 *-sunos5.4* | *-solaris2.4* )
2416 opsys=sol2-4
2417 NON_GNU_CPP=/usr/ccs/lib/cpp
2418 RANLIB="ar -ts"
2419 ;;
2420 *-sunos5.5* | *-solaris2.5* )
2421 opsys=sol2-5
2422 NON_GNU_CPP=/usr/ccs/lib/cpp
2423 RANLIB="ar -ts"
2424 ;;
8e967cf7
MR
2425 *-sunos5.6* | *-solaris2.6* )
2426 opsys=sol2-6
2427 NON_GNU_CPP=/usr/ccs/lib/cpp
2428 RANLIB="ar -ts"
2429 ;;
ba4481b5 2430 *-sunos5* | *-solaris* )
9e71690e 2431 opsys=sol2-6
ba4481b5
DL
2432 NON_GNU_CPP=/usr/ccs/lib/cpp
2433 ;;
2434 * ) opsys=bsd4-2 ;;
2435 esac
2436 ## Watch out for a compiler that we know will not work.
2437 case "${canonical}" in
2438 *-solaris* | *-sunos5* )
2439 if [ "x$CC" = x/usr/ucb/cc ]; then
2440 ## /usr/ucb/cc doesn't work;
2441 ## we should find some other compiler that does work.
2442 unset CC
2443 fi
2444 ;;
2445 *) ;;
2446 esac
2447 ;;
2448 sparc-*-nextstep* )
2449 machine=sparc opsys=nextstep
2450 ;;
2451
2452 ## Tadpole 68k
2453 m68*-tadpole-sysv* )
2454 machine=tad68k opsys=usg5-3
2455 ;;
2456
2457 ## Tahoe machines
2458 tahoe-tahoe-bsd4.2* )
2459 machine=tahoe opsys=bsd4-2
2460 ;;
2461 tahoe-tahoe-bsd4.3* )
2462 machine=tahoe opsys=bsd4-3
2463 ;;
2464
2465 ## Tandem Integrity S2
2466 mips-tandem-sysv* )
2467 machine=tandem-s2 opsys=usg5-3
2468 ;;
2469
2470 ## Tektronix XD88
2471 m88k-tektronix-sysv3* )
2472 machine=tekxd88 opsys=usg5-3
2473 ;;
2474
2475 ## Tektronix 16000 box (6130?)
2476 ns16k-tektronix-bsd* )
2477 machine=ns16000 opsys=bsd4-2
2478 ;;
2479 ## Tektronix 4300
2480 ## src/m/tek4300.h hints that this is a m68k machine.
2481 m68*-tektronix-bsd* )
2482 machine=tek4300 opsys=bsd4-3
2483 ;;
2484
2485 ## Titan P2 or P3
2486 ## We seem to have lost the machine-description file titan.h!
2487 titan-titan-sysv* )
2488 machine=titan opsys=usg5-3
2489 ;;
2490
2491 ## Ustation E30 (SS5E)
2492 m68*-unisys-uniplus* )
2493 machine=ustation opsystem=unipl5-2
2494 ;;
2495
2496 ## Vaxen.
2497 vax-dec-* )
2498 machine=vax
2499 case "${canonical}" in
2500 *-bsd4.1* ) opsys=bsd4-1 ;;
2501 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2502 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2503 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2504 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2505 *-vms* ) opsys=vms ;;
2506 * ) unported=yes
2507 esac
2508 ;;
2509
2510 ## Whitechapel MG1
2511 ns16k-whitechapel-* )
2512 machine=mg1
2513 ## We don't know what sort of OS runs on these; we'll let the
2514 ## operating system guessing code below try.
2515 ;;
2516
2517 ## Wicat
2518 m68*-wicat-sysv* )
2519 machine=wicat opsys=usg5-2
2520 ;;
2521
f4988be7
GM
2522 ## IA-64
2523 ia64*-*-linux* )
2524 machine=ia64 opsys=gnu-linux
2525 ;;
2526
ba4481b5
DL
2527 ## Intel 386 machines where we don't care about the manufacturer
2528 i[3456]86-*-* )
2529 machine=intel386
2530 case "${canonical}" in
c60ee5e7 2531 *-cygwin ) opsys=cygwin ;;
23fd4483
ST
2532 *-darwin ) opsys=darwin
2533 CPP="${CC-cc} -E -no-cpp-precomp"
2534 ;;
9f817ea4 2535 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2536 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2537 *-isc2.2* ) opsys=isc2-2 ;;
2538 *-isc4.0* ) opsys=isc4-0 ;;
2539 *-isc4.* ) opsys=isc4-1
2540 GCC_TEST_OPTIONS=-posix
2541 NON_GCC_TEST_OPTIONS=-Xp
2542 ;;
2543 *-isc* ) opsys=isc3-0 ;;
2544 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2545 *-esix* ) opsys=esix ;;
2546 *-xenix* ) opsys=xenix ;;
2547 *-linux-gnu* ) opsys=gnu-linux ;;
2548 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2549 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2550 NON_GNU_CPP=/lib/cpp
2551 # Prevent -belf from being passed to $CPP.
2552 # /lib/cpp does not accept it.
2553 OVERRIDE_CPPFLAGS=" "
2554 ;;
2555 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
55597d70
DL
2556 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2557 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
ba4481b5 2558 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2559 *-nextstep* ) opsys=nextstep ;;
2560 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2561 esac
2562 ;;
2563
2564 ## m68k Linux-based GNU system
2565 m68k-*-linux-gnu* )
2566 machine=m68k opsys=gnu-linux
2567 ;;
2568
2569 ## Mips Linux-based GNU system
cd958eb3 2570 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2571 machine=mips opsys=gnu-linux
2572 ;;
2573
2574 ## UXP/DS
2575 sparc-fujitsu-sysv4* )
2576 machine=sparc opsys=uxpds
2577 NON_GNU_CPP=/usr/ccs/lib/cpp
2578 RANLIB="ar -ts"
2579 ;;
2580
2581 ## UXP/V
2582 f301-fujitsu-uxpv4.1)
2583 machine=f301 opsys=uxpv
2584 ;;
2585
e0f712ba
AC
2586 ## Darwin / Mac OS X
2587 powerpc-apple-darwin* )
2588 machine=powermac opsys=darwin
2589 # Define CPP as follows to make autoconf work correctly.
2a75d75d 2590 CPP="${CC-cc} -E -no-cpp-precomp"
c14dc0ed
AS
2591 # Use fink packages if available.
2592 if test -d /sw/include && test -d /sw/lib; then
2593 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
2594 CPP="${CPP} ${GCC_TEST_OPTIONS}"
2595 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
2596 fi
e0f712ba
AC
2597 ;;
2598
598a2813
AS
2599 ## AMD x86-64 Linux-based GNU system
2600 x86_64-*-linux-gnu* )
24b01ec4 2601 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2602 ;;
2603
ba4481b5
DL
2604 * )
2605 unported=yes
2606 ;;
2607esac
2608
2609### If the code above didn't choose an operating system, just choose
2610### an operating system based on the configuration name. You really
2611### only want to use this when you have no idea what the right
2612### operating system is; if you know what operating systems a machine
2613### runs, it's cleaner to make it explicit in the case statement
2614### above.
2615if test x"${opsys}" = x; then
2616 case "${canonical}" in
2617 *-gnu* ) opsys=gnu ;;
2618 *-bsd4.[01] ) opsys=bsd4-1 ;;
2619 *-bsd4.2 ) opsys=bsd4-2 ;;
2620 *-bsd4.3 ) opsys=bsd4-3 ;;
2621 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2622 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2623 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2624 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2625 *-sysv4.2uw* ) opsys=unixware ;;
55597d70
DL
2626 *-sysv5uw* ) opsys=unixware ;;
2627 *-sysv5OpenUNIX* ) opsys=unixware ;;
ba4481b5
DL
2628 *-sysv4.1* | *-sysvr4.1* )
2629 NON_GNU_CPP=/usr/lib/cpp
2630 opsys=usg5-4 ;;
2631 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2632 if [ x$NON_GNU_CPP = x ]; then
2633 if [ -f /usr/ccs/lib/cpp ]; then
2634 NON_GNU_CPP=/usr/ccs/lib/cpp
2635 else
2636 NON_GNU_CPP=/lib/cpp
2637 fi
2638 fi
2639 opsys=usg5-4-2 ;;
2640 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2641 * )
2642 unported=yes
2643 ;;
2644 esac
2645fi
2646
c0d27fcc 2647
22044edf 2648
ba4481b5 2649if test $unported = yes; then
c0d27fcc 2650 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2651Check \`etc/MACHINES' for recognized configuration names." >&5
2652echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2653Check \`etc/MACHINES' for recognized configuration names." >&2;}
2654 { (exit 1); exit 1; }; }
ba4481b5
DL
2655fi
2656
2657machfile="m/${machine}.h"
2658opsysfile="s/${opsys}.h"
2659
c0d27fcc 2660
ba4481b5
DL
2661#### Choose a compiler.
2662test -n "$CC" && cc_specified=yes
2663
2664# Save the value of CFLAGS that the user specified.
2665SPECIFIED_CFLAGS="$CFLAGS"
2666
2667case ${with_gcc} in
2668 "yes" ) CC="gcc" GCC=yes ;;
2669 "no" ) : ${CC=cc} ;;
503d2be0
AS
2670 * )
2671esac
2672ac_ext=c
2673ac_cpp='$CPP $CPPFLAGS'
2674ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2675ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2676ac_compiler_gnu=$ac_cv_c_compiler_gnu
2677if test -n "$ac_tool_prefix"; then
2678 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2679set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2680echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2681echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2682if test "${ac_cv_prog_CC+set}" = set; then
2683 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2684else
2685 if test -n "$CC"; then
2686 ac_cv_prog_CC="$CC" # Let the user override the test.
2687else
c0d27fcc
MR
2688as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2689for as_dir in $PATH
2690do
2691 IFS=$as_save_IFS
2692 test -z "$as_dir" && as_dir=.
2693 for ac_exec_ext in '' $ac_executable_extensions; do
2694 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2695 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2696 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2697 break 2
2698 fi
2699done
503d2be0
AS
2700done
2701
ba4481b5
DL
2702fi
2703fi
503d2be0 2704CC=$ac_cv_prog_CC
ba4481b5 2705if test -n "$CC"; then
c0d27fcc 2706 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2707echo "${ECHO_T}$CC" >&6
2708else
c0d27fcc 2709 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2710echo "${ECHO_T}no" >&6
2711fi
2712
2713fi
2714if test -z "$ac_cv_prog_CC"; then
2715 ac_ct_CC=$CC
2716 # Extract the first word of "gcc", so it can be a program name with args.
2717set dummy gcc; ac_word=$2
c0d27fcc 2718echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2719echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2720if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2721 echo $ECHO_N "(cached) $ECHO_C" >&6
2722else
2723 if test -n "$ac_ct_CC"; then
2724 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2725else
c0d27fcc
MR
2726as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2727for as_dir in $PATH
2728do
2729 IFS=$as_save_IFS
2730 test -z "$as_dir" && as_dir=.
2731 for ac_exec_ext in '' $ac_executable_extensions; do
2732 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2733 ac_cv_prog_ac_ct_CC="gcc"
2734 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2735 break 2
2736 fi
2737done
503d2be0
AS
2738done
2739
2740fi
2741fi
2742ac_ct_CC=$ac_cv_prog_ac_ct_CC
2743if test -n "$ac_ct_CC"; then
c0d27fcc 2744 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2745echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2746else
c0d27fcc 2747 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2748echo "${ECHO_T}no" >&6
2749fi
2750
2751 CC=$ac_ct_CC
2752else
2753 CC="$ac_cv_prog_CC"
ba4481b5
DL
2754fi
2755
2756if test -z "$CC"; then
503d2be0
AS
2757 if test -n "$ac_tool_prefix"; then
2758 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2759set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2760echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2761echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2762if test "${ac_cv_prog_CC+set}" = set; then
2763 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2764else
2765 if test -n "$CC"; then
2766 ac_cv_prog_CC="$CC" # Let the user override the test.
2767else
c0d27fcc
MR
2768as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2769for as_dir in $PATH
2770do
2771 IFS=$as_save_IFS
2772 test -z "$as_dir" && as_dir=.
2773 for ac_exec_ext in '' $ac_executable_extensions; do
2774 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2775 ac_cv_prog_CC="${ac_tool_prefix}cc"
2776 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2777 break 2
2778 fi
2779done
503d2be0
AS
2780done
2781
2782fi
2783fi
2784CC=$ac_cv_prog_CC
2785if test -n "$CC"; then
c0d27fcc 2786 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2787echo "${ECHO_T}$CC" >&6
2788else
c0d27fcc 2789 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2790echo "${ECHO_T}no" >&6
2791fi
2792
2793fi
2794if test -z "$ac_cv_prog_CC"; then
2795 ac_ct_CC=$CC
2796 # Extract the first word of "cc", so it can be a program name with args.
2797set dummy cc; ac_word=$2
c0d27fcc 2798echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2799echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2800if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2801 echo $ECHO_N "(cached) $ECHO_C" >&6
2802else
2803 if test -n "$ac_ct_CC"; then
2804 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2805else
c0d27fcc
MR
2806as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2807for as_dir in $PATH
2808do
2809 IFS=$as_save_IFS
2810 test -z "$as_dir" && as_dir=.
2811 for ac_exec_ext in '' $ac_executable_extensions; do
2812 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2813 ac_cv_prog_ac_ct_CC="cc"
2814 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2815 break 2
2816 fi
2817done
503d2be0
AS
2818done
2819
2820fi
2821fi
2822ac_ct_CC=$ac_cv_prog_ac_ct_CC
2823if test -n "$ac_ct_CC"; then
c0d27fcc 2824 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2825echo "${ECHO_T}$ac_ct_CC" >&6
2826else
c0d27fcc 2827 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2828echo "${ECHO_T}no" >&6
2829fi
2830
2831 CC=$ac_ct_CC
2832else
2833 CC="$ac_cv_prog_CC"
2834fi
2835
2836fi
2837if test -z "$CC"; then
2838 # Extract the first word of "cc", so it can be a program name with args.
2839set dummy cc; ac_word=$2
c0d27fcc 2840echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2841echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2842if test "${ac_cv_prog_CC+set}" = set; then
2843 echo $ECHO_N "(cached) $ECHO_C" >&6
2844else
2845 if test -n "$CC"; then
2846 ac_cv_prog_CC="$CC" # Let the user override the test.
2847else
2848 ac_prog_rejected=no
c0d27fcc
MR
2849as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2850for as_dir in $PATH
2851do
2852 IFS=$as_save_IFS
2853 test -z "$as_dir" && as_dir=.
2854 for ac_exec_ext in '' $ac_executable_extensions; do
2855 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2856 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2857 ac_prog_rejected=yes
2858 continue
2859 fi
2860 ac_cv_prog_CC="cc"
2861 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2862 break 2
2863 fi
2864done
503d2be0
AS
2865done
2866
ba4481b5
DL
2867if test $ac_prog_rejected = yes; then
2868 # We found a bogon in the path, so make sure we never use it.
2869 set dummy $ac_cv_prog_CC
2870 shift
503d2be0 2871 if test $# != 0; then
ba4481b5
DL
2872 # We chose a different compiler from the bogus one.
2873 # However, it has the same basename, so the bogon will be chosen
2874 # first if we set CC to just the basename; use the full file name.
2875 shift
6bae0ccf 2876 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2877 fi
2878fi
2879fi
2880fi
503d2be0 2881CC=$ac_cv_prog_CC
ba4481b5 2882if test -n "$CC"; then
c0d27fcc 2883 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2884echo "${ECHO_T}$CC" >&6
ba4481b5 2885else
c0d27fcc 2886 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2887echo "${ECHO_T}no" >&6
ba4481b5
DL
2888fi
2889
503d2be0
AS
2890fi
2891if test -z "$CC"; then
2892 if test -n "$ac_tool_prefix"; then
2893 for ac_prog in cl
2894 do
2895 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2896set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2897echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2898echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2899if test "${ac_cv_prog_CC+set}" = set; then
2900 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2901else
2902 if test -n "$CC"; then
2903 ac_cv_prog_CC="$CC" # Let the user override the test.
2904else
c0d27fcc
MR
2905as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2906for as_dir in $PATH
2907do
2908 IFS=$as_save_IFS
2909 test -z "$as_dir" && as_dir=.
2910 for ac_exec_ext in '' $ac_executable_extensions; do
2911 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2912 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2913 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2914 break 2
2915 fi
2916done
503d2be0
AS
2917done
2918
c4bb2108
DL
2919fi
2920fi
503d2be0 2921CC=$ac_cv_prog_CC
c4bb2108 2922if test -n "$CC"; then
c0d27fcc 2923 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2924echo "${ECHO_T}$CC" >&6
c4bb2108 2925else
c0d27fcc 2926 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2927echo "${ECHO_T}no" >&6
2928fi
2929
2930 test -n "$CC" && break
2931 done
2932fi
2933if test -z "$CC"; then
2934 ac_ct_CC=$CC
2935 for ac_prog in cl
2936do
2937 # Extract the first word of "$ac_prog", so it can be a program name with args.
2938set dummy $ac_prog; ac_word=$2
c0d27fcc 2939echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2940echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2941if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2942 echo $ECHO_N "(cached) $ECHO_C" >&6
2943else
2944 if test -n "$ac_ct_CC"; then
2945 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2946else
c0d27fcc
MR
2947as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2948for as_dir in $PATH
2949do
2950 IFS=$as_save_IFS
2951 test -z "$as_dir" && as_dir=.
2952 for ac_exec_ext in '' $ac_executable_extensions; do
2953 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2954 ac_cv_prog_ac_ct_CC="$ac_prog"
2955 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2956 break 2
2957 fi
2958done
503d2be0
AS
2959done
2960
c4bb2108 2961fi
503d2be0
AS
2962fi
2963ac_ct_CC=$ac_cv_prog_ac_ct_CC
2964if test -n "$ac_ct_CC"; then
c0d27fcc 2965 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2966echo "${ECHO_T}$ac_ct_CC" >&6
2967else
c0d27fcc 2968 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2969echo "${ECHO_T}no" >&6
ba4481b5
DL
2970fi
2971
503d2be0
AS
2972 test -n "$ac_ct_CC" && break
2973done
ba4481b5 2974
503d2be0
AS
2975 CC=$ac_ct_CC
2976fi
2977
2978fi
ba4481b5 2979
c0d27fcc 2980
19650fd6
AS
2981test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2982See \`config.log' for more details." >&5
2983echo "$as_me: error: no acceptable C compiler found in \$PATH
2984See \`config.log' for more details." >&2;}
503d2be0 2985 { (exit 1); exit 1; }; }
c4bb2108 2986
503d2be0 2987# Provide some information about the compiler.
c0d27fcc 2988echo "$as_me:$LINENO:" \
503d2be0
AS
2989 "checking for C compiler version" >&5
2990ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 2991{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
2992 (eval $ac_compiler --version </dev/null >&5) 2>&5
2993 ac_status=$?
c0d27fcc 2994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 2995 (exit $ac_status); }
c0d27fcc 2996{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
2997 (eval $ac_compiler -v </dev/null >&5) 2>&5
2998 ac_status=$?
c0d27fcc 2999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3000 (exit $ac_status); }
c0d27fcc 3001{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
3002 (eval $ac_compiler -V </dev/null >&5) 2>&5
3003 ac_status=$?
c0d27fcc 3004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3005 (exit $ac_status); }
3006
3007cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3008#line $LINENO "configure"
19650fd6
AS
3009/* confdefs.h. */
3010_ACEOF
3011cat confdefs.h >>conftest.$ac_ext
3012cat >>conftest.$ac_ext <<_ACEOF
3013/* end confdefs.h. */
c4bb2108 3014
503d2be0
AS
3015int
3016main ()
3017{
3018
3019 ;
3020 return 0;
3021}
3022_ACEOF
3023ac_clean_files_save=$ac_clean_files
19650fd6 3024ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
3025# Try to create an executable without -o first, disregard a.out.
3026# It will help us diagnose broken compilers, and finding out an intuition
3027# of exeext.
7c9e5167
JD
3028echo "$as_me:$LINENO: checking for C compiler default output" >&5
3029echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
503d2be0 3030ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 3031if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
3032 (eval $ac_link_default) 2>&5
3033 ac_status=$?
c0d27fcc 3034 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3035 (exit $ac_status); }; then
3036 # Find the output, starting from the most likely. This scheme is
3037# not robust to junk in `.', hence go to wildcards (a.*) only as a last
3038# resort.
c0d27fcc
MR
3039
3040# Be careful to initialize this variable, since it used to be cached.
3041# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
3042ac_cv_exeext=
19650fd6
AS
3043# b.out is created by i960 compilers.
3044for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3045do
6bae0ccf 3046 test -f "$ac_file" || continue
503d2be0 3047 case $ac_file in
19650fd6 3048 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
7c9e5167 3049 ;;
19650fd6 3050 conftest.$ac_ext )
7c9e5167
JD
3051 # This is the source file.
3052 ;;
19650fd6 3053 [ab].out )
7c9e5167
JD
3054 # We found the default executable, but exeext='' is most
3055 # certainly right.
3056 break;;
19650fd6 3057 *.* )
7c9e5167
JD
3058 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3059 # FIXME: I believe we export ac_cv_exeext for Libtool,
3060 # but it would be cool to find out if it's true. Does anybody
3061 # maintain Libtool? --akim.
3062 export ac_cv_exeext
3063 break;;
19650fd6 3064 * )
7c9e5167 3065 break;;
503d2be0
AS
3066 esac
3067done
3068else
3069 echo "$as_me: failed program was:" >&5
19650fd6
AS
3070sed 's/^/| /' conftest.$ac_ext >&5
3071
6bae0ccf 3072{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
19650fd6 3073See \`config.log' for more details." >&5
6bae0ccf 3074echo "$as_me: error: C compiler cannot create executables
19650fd6 3075See \`config.log' for more details." >&2;}
503d2be0
AS
3076 { (exit 77); exit 77; }; }
3077fi
3078
3079ac_exeext=$ac_cv_exeext
c0d27fcc 3080echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3081echo "${ECHO_T}$ac_file" >&6
3082
3083# Check the compiler produces executables we can run. If not, either
3084# the compiler is broken, or we cross compile.
c0d27fcc 3085echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3086echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3087# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3088# If not cross compiling, check that we can run a simple program.
3089if test "$cross_compiling" != yes; then
3090 if { ac_try='./$ac_file'
c0d27fcc 3091 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3092 (eval $ac_try) 2>&5
3093 ac_status=$?
c0d27fcc 3094 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3095 (exit $ac_status); }; }; then
3096 cross_compiling=no
ba4481b5 3097 else
503d2be0
AS
3098 if test "$cross_compiling" = maybe; then
3099 cross_compiling=yes
3100 else
c0d27fcc 3101 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
19650fd6
AS
3102If you meant to cross compile, use \`--host'.
3103See \`config.log' for more details." >&5
503d2be0 3104echo "$as_me: error: cannot run C compiled programs.
19650fd6
AS
3105If you meant to cross compile, use \`--host'.
3106See \`config.log' for more details." >&2;}
503d2be0
AS
3107 { (exit 1); exit 1; }; }
3108 fi
ba4481b5 3109 fi
503d2be0 3110fi
c0d27fcc 3111echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3112echo "${ECHO_T}yes" >&6
3113
19650fd6 3114rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3115ac_clean_files=$ac_clean_files_save
3116# Check the compiler produces executables we can run. If not, either
3117# the compiler is broken, or we cross compile.
c0d27fcc 3118echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3119echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3120echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3121echo "${ECHO_T}$cross_compiling" >&6
3122
c0d27fcc
MR
3123echo "$as_me:$LINENO: checking for suffix of executables" >&5
3124echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3125if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3126 (eval $ac_link) 2>&5
3127 ac_status=$?
c0d27fcc 3128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3129 (exit $ac_status); }; then
3130 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3131# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3132# work properly (i.e., refer to `conftest.exe'), while it won't with
3133# `rm'.
6bae0ccf
DL
3134for ac_file in conftest.exe conftest conftest.*; do
3135 test -f "$ac_file" || continue
503d2be0 3136 case $ac_file in
6bae0ccf 3137 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0 3138 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
7c9e5167
JD
3139 export ac_cv_exeext
3140 break;;
503d2be0
AS
3141 * ) break;;
3142 esac
3143done
ba4481b5 3144else
19650fd6
AS
3145 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3146See \`config.log' for more details." >&5
3147echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3148See \`config.log' for more details." >&2;}
503d2be0 3149 { (exit 1); exit 1; }; }
ba4481b5 3150fi
ba4481b5 3151
503d2be0 3152rm -f conftest$ac_cv_exeext
c0d27fcc 3153echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3154echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3155
503d2be0
AS
3156rm -f conftest.$ac_ext
3157EXEEXT=$ac_cv_exeext
3158ac_exeext=$EXEEXT
c0d27fcc
MR
3159echo "$as_me:$LINENO: checking for suffix of object files" >&5
3160echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3161if test "${ac_cv_objext+set}" = set; then
3162 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3163else
503d2be0 3164 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3165#line $LINENO "configure"
19650fd6
AS
3166/* confdefs.h. */
3167_ACEOF
3168cat confdefs.h >>conftest.$ac_ext
3169cat >>conftest.$ac_ext <<_ACEOF
3170/* end confdefs.h. */
ba4481b5 3171
503d2be0
AS
3172int
3173main ()
3174{
ba4481b5 3175
503d2be0
AS
3176 ;
3177 return 0;
3178}
3179_ACEOF
3180rm -f conftest.o conftest.obj
c0d27fcc 3181if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3182 (eval $ac_compile) 2>&5
3183 ac_status=$?
c0d27fcc 3184 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3185 (exit $ac_status); }; then
3186 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3187 case $ac_file in
6bae0ccf 3188 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3189 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3190 break;;
3191 esac
3192done
c4bb2108 3193else
503d2be0 3194 echo "$as_me: failed program was:" >&5
19650fd6
AS
3195sed 's/^/| /' conftest.$ac_ext >&5
3196
3197{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3198See \`config.log' for more details." >&5
3199echo "$as_me: error: cannot compute suffix of object files: cannot compile
3200See \`config.log' for more details." >&2;}
503d2be0 3201 { (exit 1); exit 1; }; }
c4bb2108
DL
3202fi
3203
503d2be0
AS
3204rm -f conftest.$ac_cv_objext conftest.$ac_ext
3205fi
c0d27fcc 3206echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3207echo "${ECHO_T}$ac_cv_objext" >&6
3208OBJEXT=$ac_cv_objext
3209ac_objext=$OBJEXT
c0d27fcc 3210echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3211echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3212if test "${ac_cv_c_compiler_gnu+set}" = set; then
3213 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3214else
503d2be0 3215 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3216#line $LINENO "configure"
19650fd6
AS
3217/* confdefs.h. */
3218_ACEOF
3219cat confdefs.h >>conftest.$ac_ext
3220cat >>conftest.$ac_ext <<_ACEOF
3221/* end confdefs.h. */
503d2be0
AS
3222
3223int
3224main ()
3225{
3226#ifndef __GNUC__
3227 choke me
3228#endif
3229
3230 ;
3231 return 0;
3232}
3233_ACEOF
3234rm -f conftest.$ac_objext
c0d27fcc 3235if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3236 (eval $ac_compile) 2>&5
503d2be0 3237 ac_status=$?
c0d27fcc 3238 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3239 (exit $ac_status); } &&
7c9e5167 3240 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3241 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3242 (eval $ac_try) 2>&5
3243 ac_status=$?
c0d27fcc 3244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3245 (exit $ac_status); }; }; then
3246 ac_compiler_gnu=yes
3247else
3248 echo "$as_me: failed program was:" >&5
19650fd6
AS
3249sed 's/^/| /' conftest.$ac_ext >&5
3250
503d2be0
AS
3251ac_compiler_gnu=no
3252fi
7c9e5167 3253rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3254ac_cv_c_compiler_gnu=$ac_compiler_gnu
3255
3256fi
c0d27fcc 3257echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3258echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3259GCC=`test $ac_compiler_gnu = yes && echo yes`
3260ac_test_CFLAGS=${CFLAGS+set}
3261ac_save_CFLAGS=$CFLAGS
3262CFLAGS="-g"
c0d27fcc 3263echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3264echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3265if test "${ac_cv_prog_cc_g+set}" = set; then
3266 echo $ECHO_N "(cached) $ECHO_C" >&6
3267else
3268 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3269#line $LINENO "configure"
19650fd6
AS
3270/* confdefs.h. */
3271_ACEOF
3272cat confdefs.h >>conftest.$ac_ext
3273cat >>conftest.$ac_ext <<_ACEOF
3274/* end confdefs.h. */
503d2be0
AS
3275
3276int
3277main ()
3278{
3279
3280 ;
3281 return 0;
3282}
3283_ACEOF
3284rm -f conftest.$ac_objext
c0d27fcc 3285if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3286 (eval $ac_compile) 2>&5
503d2be0 3287 ac_status=$?
c0d27fcc 3288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3289 (exit $ac_status); } &&
7c9e5167 3290 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3291 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3292 (eval $ac_try) 2>&5
3293 ac_status=$?
c0d27fcc 3294 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3295 (exit $ac_status); }; }; then
ba4481b5
DL
3296 ac_cv_prog_cc_g=yes
3297else
503d2be0 3298 echo "$as_me: failed program was:" >&5
19650fd6
AS
3299sed 's/^/| /' conftest.$ac_ext >&5
3300
503d2be0 3301ac_cv_prog_cc_g=no
ba4481b5 3302fi
7c9e5167 3303rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 3304fi
c0d27fcc 3305echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3306echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3307if test "$ac_test_CFLAGS" = set; then
503d2be0 3308 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3309elif test $ac_cv_prog_cc_g = yes; then
3310 if test "$GCC" = yes; then
ba4481b5
DL
3311 CFLAGS="-g -O2"
3312 else
c4bb2108 3313 CFLAGS="-g"
ba4481b5 3314 fi
22afa6e8 3315else
c4bb2108
DL
3316 if test "$GCC" = yes; then
3317 CFLAGS="-O2"
3318 else
3319 CFLAGS=
3320 fi
ba4481b5 3321fi
6bae0ccf
DL
3322echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3323echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3324if test "${ac_cv_prog_cc_stdc+set}" = set; then
3325 echo $ECHO_N "(cached) $ECHO_C" >&6
3326else
3327 ac_cv_prog_cc_stdc=no
3328ac_save_CC=$CC
3329cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3330#line $LINENO "configure"
19650fd6
AS
3331/* confdefs.h. */
3332_ACEOF
3333cat confdefs.h >>conftest.$ac_ext
3334cat >>conftest.$ac_ext <<_ACEOF
3335/* end confdefs.h. */
6bae0ccf
DL
3336#include <stdarg.h>
3337#include <stdio.h>
3338#include <sys/types.h>
3339#include <sys/stat.h>
3340/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3341struct buf { int x; };
3342FILE * (*rcsopen) (struct buf *, struct stat *, int);
3343static char *e (p, i)
3344 char **p;
3345 int i;
3346{
3347 return p[i];
3348}
3349static char *f (char * (*g) (char **, int), char **p, ...)
3350{
3351 char *s;
3352 va_list v;
3353 va_start (v,p);
3354 s = g (p, va_arg (v,int));
3355 va_end (v);
3356 return s;
3357}
3358int test (int i, double x);
3359struct s1 {int (*f) (int a);};
3360struct s2 {int (*f) (double a);};
3361int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3362int argc;
3363char **argv;
3364int
3365main ()
3366{
3367return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3368 ;
3369 return 0;
3370}
3371_ACEOF
3372# Don't try gcc -ansi; that turns off useful extensions and
3373# breaks some systems' header files.
3374# AIX -qlanglvl=ansi
3375# Ultrix and OSF/1 -std1
3376# HP-UX 10.20 and later -Ae
3377# HP-UX older versions -Aa -D_HPUX_SOURCE
3378# SVR4 -Xc -D__EXTENSIONS__
3379for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3380do
3381 CC="$ac_save_CC $ac_arg"
3382 rm -f conftest.$ac_objext
3383if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3384 (eval $ac_compile) 2>&5
6bae0ccf
DL
3385 ac_status=$?
3386 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3387 (exit $ac_status); } &&
7c9e5167 3388 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
3389 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3390 (eval $ac_try) 2>&5
3391 ac_status=$?
3392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3393 (exit $ac_status); }; }; then
3394 ac_cv_prog_cc_stdc=$ac_arg
3395break
3396else
3397 echo "$as_me: failed program was:" >&5
19650fd6
AS
3398sed 's/^/| /' conftest.$ac_ext >&5
3399
6bae0ccf 3400fi
7c9e5167 3401rm -f conftest.$ac_objext
6bae0ccf
DL
3402done
3403rm -f conftest.$ac_ext conftest.$ac_objext
3404CC=$ac_save_CC
3405
3406fi
3407
3408case "x$ac_cv_prog_cc_stdc" in
3409 x|xno)
3410 echo "$as_me:$LINENO: result: none needed" >&5
3411echo "${ECHO_T}none needed" >&6 ;;
3412 *)
3413 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3414echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3415 CC="$CC $ac_cv_prog_cc_stdc" ;;
3416esac
3417
503d2be0
AS
3418# Some people use a C++ compiler to compile C. Since we use `exit',
3419# in C++ we need to declare it. In case someone uses the same compiler
3420# for both compiling C and C++ we need to have the C++ compiler decide
3421# the declaration of exit, since it's the most demanding environment.
3422cat >conftest.$ac_ext <<_ACEOF
3423#ifndef __cplusplus
3424 choke me
3425#endif
3426_ACEOF
3427rm -f conftest.$ac_objext
c0d27fcc 3428if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3429 (eval $ac_compile) 2>&5
503d2be0 3430 ac_status=$?
c0d27fcc 3431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3432 (exit $ac_status); } &&
7c9e5167 3433 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3435 (eval $ac_try) 2>&5
3436 ac_status=$?
c0d27fcc 3437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3438 (exit $ac_status); }; }; then
3439 for ac_declaration in \
7c9e5167
JD
3440 ''\
3441 '#include <stdlib.h>' \
503d2be0
AS
3442 'extern "C" void std::exit (int) throw (); using std::exit;' \
3443 'extern "C" void std::exit (int); using std::exit;' \
3444 'extern "C" void exit (int) throw ();' \
3445 'extern "C" void exit (int);' \
cffcede7 3446 'void exit (int);'
503d2be0
AS
3447do
3448 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3449#line $LINENO "configure"
19650fd6
AS
3450/* confdefs.h. */
3451_ACEOF
3452cat confdefs.h >>conftest.$ac_ext
3453cat >>conftest.$ac_ext <<_ACEOF
3454/* end confdefs.h. */
35996d22 3455#include <stdlib.h>
7c9e5167 3456$ac_declaration
503d2be0
AS
3457int
3458main ()
3459{
3460exit (42);
3461 ;
3462 return 0;
3463}
3464_ACEOF
3465rm -f conftest.$ac_objext
c0d27fcc 3466if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3467 (eval $ac_compile) 2>&5
503d2be0 3468 ac_status=$?
c0d27fcc 3469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3470 (exit $ac_status); } &&
7c9e5167 3471 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3472 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3473 (eval $ac_try) 2>&5
3474 ac_status=$?
c0d27fcc 3475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3476 (exit $ac_status); }; }; then
3477 :
3478else
3479 echo "$as_me: failed program was:" >&5
19650fd6
AS
3480sed 's/^/| /' conftest.$ac_ext >&5
3481
503d2be0
AS
3482continue
3483fi
7c9e5167 3484rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0 3485 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3486#line $LINENO "configure"
19650fd6
AS
3487/* confdefs.h. */
3488_ACEOF
3489cat confdefs.h >>conftest.$ac_ext
3490cat >>conftest.$ac_ext <<_ACEOF
3491/* end confdefs.h. */
503d2be0
AS
3492$ac_declaration
3493int
3494main ()
3495{
3496exit (42);
3497 ;
3498 return 0;
3499}
3500_ACEOF
3501rm -f conftest.$ac_objext
c0d27fcc 3502if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 3503 (eval $ac_compile) 2>&5
503d2be0 3504 ac_status=$?
c0d27fcc 3505 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3506 (exit $ac_status); } &&
7c9e5167 3507 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3508 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3509 (eval $ac_try) 2>&5
3510 ac_status=$?
c0d27fcc 3511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3512 (exit $ac_status); }; }; then
3513 break
3514else
3515 echo "$as_me: failed program was:" >&5
19650fd6
AS
3516sed 's/^/| /' conftest.$ac_ext >&5
3517
503d2be0 3518fi
7c9e5167 3519rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3520done
3521rm -f conftest*
3522if test -n "$ac_declaration"; then
3523 echo '#ifdef __cplusplus' >>confdefs.h
3524 echo $ac_declaration >>confdefs.h
3525 echo '#endif' >>confdefs.h
3526fi
ba4481b5 3527
503d2be0
AS
3528else
3529 echo "$as_me: failed program was:" >&5
19650fd6
AS
3530sed 's/^/| /' conftest.$ac_ext >&5
3531
503d2be0 3532fi
7c9e5167 3533rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
3534ac_ext=c
3535ac_cpp='$CPP $CPPFLAGS'
3536ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3537ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3538ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3539
c0d27fcc 3540
ba4481b5
DL
3541# On Suns, sometimes $CPP names a directory.
3542if test -n "$CPP" && test -d "$CPP"; then
3543 CPP=
3544fi
3545
3546#### Some systems specify a CPP to use unless we are using GCC.
3547#### Now that we know whether we are using GCC, we can decide whether
3548#### to use that one.
3549if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3550then
3551 CPP="$NON_GNU_CPP"
3552fi
3553
3554#### Some systems specify a CC to use unless we are using GCC.
3555#### Now that we know whether we are using GCC, we can decide whether
3556#### to use that one.
3557if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3558 test x$cc_specified != xyes
3559then
3560 CC="$NON_GNU_CC"
3561fi
3562
3563if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3564then
3565 CC="$CC $GCC_TEST_OPTIONS"
3566fi
3567
3568if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3569then
3570 CC="$CC $NON_GCC_TEST_OPTIONS"
3571fi
3572
6a3a24fa 3573#### Some other nice autoconf tests.
ba4481b5 3574
c0d27fcc 3575echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3576echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3577LN_S=$as_ln_s
3578if test "$LN_S" = "ln -s"; then
c0d27fcc 3579 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3580echo "${ECHO_T}yes" >&6
ba4481b5 3581else
c0d27fcc 3582 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3583echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3584fi
3585
503d2be0
AS
3586ac_ext=c
3587ac_cpp='$CPP $CPPFLAGS'
3588ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3589ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3590ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3591echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3592echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3593# On Suns, sometimes $CPP names a directory.
3594if test -n "$CPP" && test -d "$CPP"; then
3595 CPP=
3596fi
3597if test -z "$CPP"; then
503d2be0
AS
3598 if test "${ac_cv_prog_CPP+set}" = set; then
3599 echo $ECHO_N "(cached) $ECHO_C" >&6
3600else
3601 # Double quotes because CPP needs to be expanded
3602 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3603 do
3604 ac_preproc_ok=false
3605for ac_c_preproc_warn_flag in '' yes
3606do
3607 # Use a header file that comes with gcc, so configuring glibc
3608 # with a fresh cross-compiler works.
19650fd6
AS
3609 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3610 # <limits.h> exists even on freestanding compilers.
ba4481b5 3611 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3612 # not just through cpp. "Syntax error" is here to catch this case.
3613 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3614#line $LINENO "configure"
19650fd6
AS
3615/* confdefs.h. */
3616_ACEOF
3617cat confdefs.h >>conftest.$ac_ext
3618cat >>conftest.$ac_ext <<_ACEOF
3619/* end confdefs.h. */
3620#ifdef __STDC__
3621# include <limits.h>
3622#else
3623# include <assert.h>
3624#endif
7c9e5167 3625 Syntax error
503d2be0 3626_ACEOF
c0d27fcc 3627if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3628 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3629 ac_status=$?
6bae0ccf 3630 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3631 rm -f conftest.er1
3632 cat conftest.err >&5
c0d27fcc 3633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3634 (exit $ac_status); } >/dev/null; then
3635 if test -s conftest.err; then
3636 ac_cpp_err=$ac_c_preproc_warn_flag
3637 else
3638 ac_cpp_err=
3639 fi
3640else
3641 ac_cpp_err=yes
3642fi
3643if test -z "$ac_cpp_err"; then
ba4481b5
DL
3644 :
3645else
503d2be0 3646 echo "$as_me: failed program was:" >&5
19650fd6
AS
3647sed 's/^/| /' conftest.$ac_ext >&5
3648
503d2be0
AS
3649 # Broken: fails on valid input.
3650continue
3651fi
3652rm -f conftest.err conftest.$ac_ext
3653
3654 # OK, works on sane cases. Now check whether non-existent headers
3655 # can be detected and how.
3656 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3657#line $LINENO "configure"
19650fd6
AS
3658/* confdefs.h. */
3659_ACEOF
3660cat confdefs.h >>conftest.$ac_ext
3661cat >>conftest.$ac_ext <<_ACEOF
3662/* end confdefs.h. */
503d2be0
AS
3663#include <ac_nonexistent.h>
3664_ACEOF
c0d27fcc 3665if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3666 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3667 ac_status=$?
6bae0ccf 3668 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3669 rm -f conftest.er1
3670 cat conftest.err >&5
c0d27fcc 3671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3672 (exit $ac_status); } >/dev/null; then
3673 if test -s conftest.err; then
3674 ac_cpp_err=$ac_c_preproc_warn_flag
3675 else
3676 ac_cpp_err=
3677 fi
3678else
3679 ac_cpp_err=yes
3680fi
3681if test -z "$ac_cpp_err"; then
3682 # Broken: success on invalid input.
3683continue
c4bb2108 3684else
503d2be0 3685 echo "$as_me: failed program was:" >&5
19650fd6
AS
3686sed 's/^/| /' conftest.$ac_ext >&5
3687
503d2be0
AS
3688 # Passes both tests.
3689ac_preproc_ok=:
3690break
3691fi
3692rm -f conftest.err conftest.$ac_ext
3693
3694done
3695# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3696rm -f conftest.err conftest.$ac_ext
3697if $ac_preproc_ok; then
3698 break
3699fi
3700
3701 done
3702 ac_cv_prog_CPP=$CPP
3703
3704fi
3705 CPP=$ac_cv_prog_CPP
3706else
3707 ac_cv_prog_CPP=$CPP
3708fi
c0d27fcc 3709echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3710echo "${ECHO_T}$CPP" >&6
3711ac_preproc_ok=false
3712for ac_c_preproc_warn_flag in '' yes
3713do
3714 # Use a header file that comes with gcc, so configuring glibc
3715 # with a fresh cross-compiler works.
19650fd6
AS
3716 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3717 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3718 # On the NeXT, cc -E runs the code through the compiler's parser,
3719 # not just through cpp. "Syntax error" is here to catch this case.
3720 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3721#line $LINENO "configure"
19650fd6
AS
3722/* confdefs.h. */
3723_ACEOF
3724cat confdefs.h >>conftest.$ac_ext
3725cat >>conftest.$ac_ext <<_ACEOF
3726/* end confdefs.h. */
3727#ifdef __STDC__
3728# include <limits.h>
3729#else
3730# include <assert.h>
3731#endif
7c9e5167 3732 Syntax error
503d2be0 3733_ACEOF
c0d27fcc 3734if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3735 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3736 ac_status=$?
6bae0ccf 3737 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3738 rm -f conftest.er1
3739 cat conftest.err >&5
c0d27fcc 3740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3741 (exit $ac_status); } >/dev/null; then
3742 if test -s conftest.err; then
3743 ac_cpp_err=$ac_c_preproc_warn_flag
3744 else
3745 ac_cpp_err=
3746 fi
3747else
3748 ac_cpp_err=yes
3749fi
3750if test -z "$ac_cpp_err"; then
ba4481b5
DL
3751 :
3752else
503d2be0 3753 echo "$as_me: failed program was:" >&5
19650fd6
AS
3754sed 's/^/| /' conftest.$ac_ext >&5
3755
503d2be0
AS
3756 # Broken: fails on valid input.
3757continue
3758fi
3759rm -f conftest.err conftest.$ac_ext
3760
3761 # OK, works on sane cases. Now check whether non-existent headers
3762 # can be detected and how.
3763 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 3764#line $LINENO "configure"
19650fd6
AS
3765/* confdefs.h. */
3766_ACEOF
3767cat confdefs.h >>conftest.$ac_ext
3768cat >>conftest.$ac_ext <<_ACEOF
3769/* end confdefs.h. */
503d2be0
AS
3770#include <ac_nonexistent.h>
3771_ACEOF
c0d27fcc 3772if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3773 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3774 ac_status=$?
6bae0ccf 3775 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3776 rm -f conftest.er1
3777 cat conftest.err >&5
c0d27fcc 3778 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3779 (exit $ac_status); } >/dev/null; then
3780 if test -s conftest.err; then
3781 ac_cpp_err=$ac_c_preproc_warn_flag
3782 else
3783 ac_cpp_err=
3784 fi
3785else
3786 ac_cpp_err=yes
c4bb2108 3787fi
503d2be0
AS
3788if test -z "$ac_cpp_err"; then
3789 # Broken: success on invalid input.
3790continue
3791else
3792 echo "$as_me: failed program was:" >&5
19650fd6
AS
3793sed 's/^/| /' conftest.$ac_ext >&5
3794
503d2be0
AS
3795 # Passes both tests.
3796ac_preproc_ok=:
3797break
ba4481b5 3798fi
503d2be0
AS
3799rm -f conftest.err conftest.$ac_ext
3800
3801done
3802# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3803rm -f conftest.err conftest.$ac_ext
3804if $ac_preproc_ok; then
3805 :
ba4481b5 3806else
19650fd6
AS
3807 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3808See \`config.log' for more details." >&5
3809echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3810See \`config.log' for more details." >&2;}
503d2be0 3811 { (exit 1); exit 1; }; }
ba4481b5 3812fi
503d2be0
AS
3813
3814ac_ext=c
3815ac_cpp='$CPP $CPPFLAGS'
3816ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3817ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3818ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3819
3820# Find a good install program. We prefer a C program (faster),
3821# so one script is as good as another. But avoid the broken or
3822# incompatible versions:
3823# SysV /etc/install, /usr/sbin/install
3824# SunOS /usr/etc/install
3825# IRIX /sbin/install
3826# AIX /bin/install
503d2be0 3827# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3828# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3829# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3830# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3831# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3832echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3833echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3834if test -z "$INSTALL"; then
503d2be0
AS
3835if test "${ac_cv_path_install+set}" = set; then
3836 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3837else
c0d27fcc
MR
3838 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3839for as_dir in $PATH
3840do
3841 IFS=$as_save_IFS
3842 test -z "$as_dir" && as_dir=.
3843 # Account for people who put trailing slashes in PATH elements.
3844case $as_dir/ in
3845 ./ | .// | /cC/* | \
3846 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3847 /usr/ucb/* ) ;;
3848 *)
3849 # OSF1 and SCO ODT 3.0 have their own names for install.
3850 # Don't use installbsd from OSF since it installs stuff as root
3851 # by default.
3852 for ac_prog in ginstall scoinst install; do
3853 for ac_exec_ext in '' $ac_executable_extensions; do
7c9e5167
JD
3854 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3855 if test $ac_prog = install &&
3856 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3857 # AIX install. It has an incompatible calling convention.
3858 :
3859 elif test $ac_prog = install &&
3860 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3861 # program-specific install script used by HP pwplus--don't use.
3862 :
3863 else
3864 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3865 break 3
3866 fi
3867 fi
ba4481b5 3868 done
c0d27fcc
MR
3869 done
3870 ;;
3871esac
3872done
3873
ba4481b5
DL
3874
3875fi
3876 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3877 INSTALL=$ac_cv_path_install
ba4481b5
DL
3878 else
3879 # As a last resort, use the slow shell script. We don't cache a
3880 # path for INSTALL within a source directory, because that will
3881 # break other packages using the cache if that directory is
3882 # removed, or if the path is relative.
503d2be0 3883 INSTALL=$ac_install_sh
ba4481b5
DL
3884 fi
3885fi
c0d27fcc 3886echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3887echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3888
3889# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3890# It thinks the first close brace ends the variable substitution.
3891test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3892
503d2be0 3893test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3894
ba4481b5
DL
3895test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3896
c0d27fcc
MR
3897if test "x$RANLIB" = x; then
3898 if test -n "$ac_tool_prefix"; then
3899 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3900set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3901echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3902echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3903if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3904 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3905else
3906 if test -n "$RANLIB"; then
3907 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3908else
c0d27fcc
MR
3909as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3910for as_dir in $PATH
3911do
3912 IFS=$as_save_IFS
3913 test -z "$as_dir" && as_dir=.
3914 for ac_exec_ext in '' $ac_executable_extensions; do
3915 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3916 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3917 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3918 break 2
3919 fi
3920done
503d2be0
AS
3921done
3922
7397acc4
DL
3923fi
3924fi
503d2be0 3925RANLIB=$ac_cv_prog_RANLIB
7397acc4 3926if test -n "$RANLIB"; then
c0d27fcc 3927 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
3928echo "${ECHO_T}$RANLIB" >&6
3929else
c0d27fcc 3930 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3931echo "${ECHO_T}no" >&6
3932fi
3933
3934fi
3935if test -z "$ac_cv_prog_RANLIB"; then
3936 ac_ct_RANLIB=$RANLIB
3937 # Extract the first word of "ranlib", so it can be a program name with args.
3938set dummy ranlib; ac_word=$2
c0d27fcc 3939echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
3940echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3941if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3942 echo $ECHO_N "(cached) $ECHO_C" >&6
3943else
3944 if test -n "$ac_ct_RANLIB"; then
3945 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3946else
c0d27fcc
MR
3947as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3948for as_dir in $PATH
3949do
3950 IFS=$as_save_IFS
3951 test -z "$as_dir" && as_dir=.
3952 for ac_exec_ext in '' $ac_executable_extensions; do
3953 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3954 ac_cv_prog_ac_ct_RANLIB="ranlib"
3955 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3956 break 2
3957 fi
3958done
503d2be0
AS
3959done
3960
3961 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3962fi
3963fi
3964ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3965if test -n "$ac_ct_RANLIB"; then
c0d27fcc 3966 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
3967echo "${ECHO_T}$ac_ct_RANLIB" >&6
3968else
c0d27fcc 3969 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3970echo "${ECHO_T}no" >&6
3971fi
3972
3973 RANLIB=$ac_ct_RANLIB
7397acc4 3974else
503d2be0 3975 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
3976fi
3977
3978fi
9e71690e
DK
3979# Extract the first word of "install-info", so it can be a program name with args.
3980set dummy install-info; ac_word=$2
3981echo "$as_me:$LINENO: checking for $ac_word" >&5
3982echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3983if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
3984 echo $ECHO_N "(cached) $ECHO_C" >&6
3985else
3986 case $INSTALL_INFO in
3987 [\\/]* | ?:[\\/]*)
3988 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
3989 ;;
3990 *)
3991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3992for as_dir in $PATH
3993do
3994 IFS=$as_save_IFS
3995 test -z "$as_dir" && as_dir=.
3996 for ac_exec_ext in '' $ac_executable_extensions; do
3997 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3998 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
3999 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4000 break 2
4001 fi
4002done
4003done
4004
4005 ;;
4006esac
4007fi
4008INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4009
4010if test -n "$INSTALL_INFO"; then
4011 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4012echo "${ECHO_T}$INSTALL_INFO" >&6
4013else
4014 echo "$as_me:$LINENO: result: no" >&5
4015echo "${ECHO_T}no" >&6
4016fi
4017
4018# Extract the first word of "install-info", so it can be a program name with args.
4019set dummy install-info; ac_word=$2
4020echo "$as_me:$LINENO: checking for $ac_word" >&5
4021echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4022if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4023 echo $ECHO_N "(cached) $ECHO_C" >&6
4024else
4025 case $INSTALL_INFO in
4026 [\\/]* | ?:[\\/]*)
4027 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4028 ;;
4029 *)
4030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4031for as_dir in /usr/sbin
4032do
4033 IFS=$as_save_IFS
4034 test -z "$as_dir" && as_dir=.
4035 for ac_exec_ext in '' $ac_executable_extensions; do
4036 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4037 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4038 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4039 break 2
4040 fi
4041done
4042done
4043
4044 ;;
4045esac
4046fi
4047INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4048
4049if test -n "$INSTALL_INFO"; then
4050 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4051echo "${ECHO_T}$INSTALL_INFO" >&6
4052else
4053 echo "$as_me:$LINENO: result: no" >&5
4054echo "${ECHO_T}no" >&6
4055fi
4056
4057# Extract the first word of "install-info", so it can be a program name with args.
4058set dummy install-info; ac_word=$2
4059echo "$as_me:$LINENO: checking for $ac_word" >&5
4060echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4061if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4062 echo $ECHO_N "(cached) $ECHO_C" >&6
4063else
4064 case $INSTALL_INFO in
4065 [\\/]* | ?:[\\/]*)
4066 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4067 ;;
4068 *)
4069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4070for as_dir in /sbin
4071do
4072 IFS=$as_save_IFS
4073 test -z "$as_dir" && as_dir=.
4074 for ac_exec_ext in '' $ac_executable_extensions; do
4075 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4076 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4077 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4078 break 2
4079 fi
4080done
4081done
4082
4083 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4084 ;;
4085esac
4086fi
4087INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4088
4089if test -n "$INSTALL_INFO"; then
4090 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4091echo "${ECHO_T}$INSTALL_INFO" >&6
4092else
4093 echo "$as_me:$LINENO: result: no" >&5
4094echo "${ECHO_T}no" >&6
4095fi
4096
ba4481b5 4097
c0d27fcc 4098
8e967cf7
MR
4099if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4100then
4101 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4102fi
4103
4104if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4105then
4106 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4107fi
4108
c0d27fcc 4109
fe239f0f 4110late_LDFLAGS=$LDFLAGS
4af002d6 4111if test "$GCC" = yes; then
fe239f0f
AS
4112 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
4113else
4114 LDFLAGS="$LDFLAGS -znocombreloc"
4115fi
4116
4117echo "$as_me:$LINENO: checking For -znocombreloc" >&5
4118echo $ECHO_N "checking For -znocombreloc... $ECHO_C" >&6
4119
4120cat >conftest.$ac_ext <<_ACEOF
4121main(){return 0;}
4122_ACEOF
4123rm -f conftest.$ac_objext conftest$ac_exeext
4124if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 4125 (eval $ac_link) 2>&5
fe239f0f 4126 ac_status=$?
fe239f0f
AS
4127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4128 (exit $ac_status); } &&
7c9e5167 4129 { ac_try='test -s conftest$ac_exeext'
fe239f0f
AS
4130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4131 (eval $ac_try) 2>&5
4132 ac_status=$?
4133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4134 (exit $ac_status); }; }; then
4135 echo "$as_me:$LINENO: result: yes" >&5
4136echo "${ECHO_T}yes" >&6
4137else
4138 echo "$as_me: failed program was:" >&5
4139sed 's/^/| /' conftest.$ac_ext >&5
4140
4141LDFLAGS=$late_LDFLAGS
4142 echo "$as_me:$LINENO: result: no" >&5
4143echo "${ECHO_T}no" >&6
4144fi
7c9e5167 4145rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fe239f0f 4146
c0d27fcc 4147
6bae0ccf
DL
4148echo "$as_me:$LINENO: checking for egrep" >&5
4149echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4150if test "${ac_cv_prog_egrep+set}" = set; then
4151 echo $ECHO_N "(cached) $ECHO_C" >&6
4152else
4153 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4154 then ac_cv_prog_egrep='grep -E'
4155 else ac_cv_prog_egrep='egrep'
4156 fi
4157fi
4158echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4159echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4160 EGREP=$ac_cv_prog_egrep
4161
4162
c0d27fcc
MR
4163
4164echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4165echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4166cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4167#line $LINENO "configure"
19650fd6
AS
4168/* confdefs.h. */
4169_ACEOF
4170cat confdefs.h >>conftest.$ac_ext
4171cat >>conftest.$ac_ext <<_ACEOF
4172/* end confdefs.h. */
ba4481b5
DL
4173#ifdef _AIX
4174 yes
4175#endif
4176
503d2be0 4177_ACEOF
ba4481b5 4178if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4179 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4180 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4181echo "${ECHO_T}yes" >&6
c0d27fcc 4182cat >>confdefs.h <<\_ACEOF
ba4481b5 4183#define _ALL_SOURCE 1
c0d27fcc 4184_ACEOF
ba4481b5
DL
4185
4186else
c0d27fcc 4187 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4188echo "${ECHO_T}no" >&6
ba4481b5
DL
4189fi
4190rm -f conftest*
4191
c0d27fcc
MR
4192
4193
4489ece2 4194
3b33a005
DL
4195#### Extract some information from the operating system and machine files.
4196
c0d27fcc 4197{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4198 - which libraries the lib-src programs will want, and
503d2be0
AS
4199 - whether the GNU malloc routines are usable..." >&5
4200echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4201 - which libraries the lib-src programs will want, and
503d2be0 4202 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4203
4204### First figure out CFLAGS (which we use for running the compiler here)
4205### and REAL_CFLAGS (which we use for real compilation).
4206### The two are the same except on a few systems, where they are made
4207### different to work around various lossages. For example,
4208### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4209### as implying static linking.
4210
4211### If the CFLAGS env var is specified, we use that value
4212### instead of the default.
4213
4214### It's not important that this name contain the PID; you can't run
4215### two configures in the same directory and have anything work
4216### anyway.
4217tempcname="conftest.c"
4218
4219echo '
4220#include "'${srcdir}'/src/'${opsysfile}'"
4221#include "'${srcdir}'/src/'${machfile}'"
4222#ifndef LIBS_MACHINE
4223#define LIBS_MACHINE
4224#endif
4225#ifndef LIBS_SYSTEM
4226#define LIBS_SYSTEM
4227#endif
4228#ifndef C_SWITCH_SYSTEM
4229#define C_SWITCH_SYSTEM
4230#endif
4231#ifndef C_SWITCH_MACHINE
4232#define C_SWITCH_MACHINE
4233#endif
4234configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4235configure___ c_switch_system=C_SWITCH_SYSTEM
4236configure___ c_switch_machine=C_SWITCH_MACHINE
4237
4238#ifndef LIB_X11_LIB
4239#define LIB_X11_LIB -lX11
4240#endif
4241
4242#ifndef LIBX11_MACHINE
4243#define LIBX11_MACHINE
4244#endif
4245
4246#ifndef LIBX11_SYSTEM
4247#define LIBX11_SYSTEM
4248#endif
4249configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4250
4251#ifdef UNEXEC
4252configure___ unexec=UNEXEC
4253#else
4254configure___ unexec=unexec.o
4255#endif
4256
4257#ifdef SYSTEM_MALLOC
4258configure___ system_malloc=yes
4259#else
4260configure___ system_malloc=no
4261#endif
4262
ef9e4345
GM
4263#ifdef USE_MMAP_FOR_BUFFERS
4264configure___ use_mmap_for_buffers=yes
73b77ee5 4265#else
ef9e4345 4266configure___ use_mmap_for_buffers=no
73b77ee5
GM
4267#endif
4268
3b33a005
DL
4269#ifndef C_DEBUG_SWITCH
4270#define C_DEBUG_SWITCH -g
4271#endif
4272
4273#ifndef C_OPTIMIZE_SWITCH
4274#ifdef __GNUC__
4275#define C_OPTIMIZE_SWITCH -O2
4276#else
4277#define C_OPTIMIZE_SWITCH -O
4278#endif
4279#endif
4280
4281#ifndef LD_SWITCH_MACHINE
4282#define LD_SWITCH_MACHINE
4283#endif
4284
4285#ifndef LD_SWITCH_SYSTEM
4286#define LD_SWITCH_SYSTEM
4287#endif
4288
4289#ifndef LD_SWITCH_X_SITE_AUX
4290#define LD_SWITCH_X_SITE_AUX
503d2be0 4291#endif
3b33a005
DL
4292
4293configure___ ld_switch_system=LD_SWITCH_SYSTEM
4294configure___ ld_switch_machine=LD_SWITCH_MACHINE
4295
4296#ifdef THIS_IS_CONFIGURE
4297
4298/* Get the CFLAGS for tests in configure. */
4299#ifdef __GNUC__
4300configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4301#else
4302configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4303#endif
4304
4305#else /* not THIS_IS_CONFIGURE */
4306
4307/* Get the CFLAGS for real compilation. */
4308#ifdef __GNUC__
4309configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4310#else
4311configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4312#endif
4313
4314#endif /* not THIS_IS_CONFIGURE */
4315' > ${tempcname}
4316
4317# The value of CPP is a quoted variable reference, so we need to do this
4318# to get its actual value...
4319CPP=`eval "echo $CPP"`
4320eval `${CPP} -Isrc ${tempcname} \
4321 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4322if test "x$SPECIFIED_CFLAGS" = x; then
4323 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4324 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4325else
4326 REAL_CFLAGS="$CFLAGS"
4327fi
4328rm ${tempcname}
4329
4330ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4331
4332### Make sure subsequent tests use flags consistent with the build flags.
4333
4334if test x"${OVERRIDE_CPPFLAGS}" != x; then
4335 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4336else
4337 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4338fi
4339
6bae0ccf
DL
4340
4341
22044edf
DL
4342
4343cat >>confdefs.h <<\_ACEOF
4344#define _GNU_SOURCE 1
4345_ACEOF
4346
4347
4348
503d2be0 4349# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4350if test "${enable_largefile+set}" = set; then
4351 enableval="$enable_largefile"
f4988be7 4352
503d2be0
AS
4353fi;
4354if test "$enable_largefile" != no; then
f4988be7 4355
c0d27fcc 4356 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4357echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4358if test "${ac_cv_sys_largefile_CC+set}" = set; then
4359 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4360else
f4988be7 4361 ac_cv_sys_largefile_CC=no
503d2be0
AS
4362 if test "$GCC" != yes; then
4363 ac_save_CC=$CC
4364 while :; do
4365 # IRIX 6.2 and later do not support large files by default,
4366 # so use the C compiler's -n32 option if that helps.
7c9e5167
JD
4367 cat >conftest.$ac_ext <<_ACEOF
4368#line $LINENO "configure"
19650fd6
AS
4369/* confdefs.h. */
4370_ACEOF
4371cat confdefs.h >>conftest.$ac_ext
4372cat >>conftest.$ac_ext <<_ACEOF
4373/* end confdefs.h. */
f4988be7 4374#include <sys/types.h>
503d2be0
AS
4375 /* Check that off_t can represent 2**63 - 1 correctly.
4376 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4377 since some C++ compilers masquerading as C compilers
4378 incorrectly reject 9223372036854775807. */
4379#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4380 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4381 && LARGE_OFF_T % 2147483647 == 1)
4382 ? 1 : -1];
4383int
4384main ()
4385{
f4988be7 4386
503d2be0
AS
4387 ;
4388 return 0;
4389}
4390_ACEOF
4391 rm -f conftest.$ac_objext
c0d27fcc 4392if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4393 (eval $ac_compile) 2>&5
503d2be0 4394 ac_status=$?
c0d27fcc 4395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4396 (exit $ac_status); } &&
7c9e5167 4397 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4398 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4399 (eval $ac_try) 2>&5
4400 ac_status=$?
c0d27fcc 4401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4402 (exit $ac_status); }; }; then
4403 break
b192d653 4404else
503d2be0 4405 echo "$as_me: failed program was:" >&5
19650fd6
AS
4406sed 's/^/| /' conftest.$ac_ext >&5
4407
503d2be0 4408fi
7c9e5167 4409rm -f conftest.$ac_objext
503d2be0
AS
4410 CC="$CC -n32"
4411 rm -f conftest.$ac_objext
c0d27fcc 4412if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4413 (eval $ac_compile) 2>&5
503d2be0 4414 ac_status=$?
c0d27fcc 4415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4416 (exit $ac_status); } &&
7c9e5167 4417 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4418 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4419 (eval $ac_try) 2>&5
4420 ac_status=$?
c0d27fcc 4421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4422 (exit $ac_status); }; }; then
4423 ac_cv_sys_largefile_CC=' -n32'; break
4424else
4425 echo "$as_me: failed program was:" >&5
19650fd6
AS
4426sed 's/^/| /' conftest.$ac_ext >&5
4427
503d2be0 4428fi
7c9e5167
JD
4429rm -f conftest.$ac_objext
4430 break
503d2be0
AS
4431 done
4432 CC=$ac_save_CC
4433 rm -f conftest.$ac_ext
4434 fi
b192d653 4435fi
c0d27fcc 4436echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4437echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4438 if test "$ac_cv_sys_largefile_CC" != no; then
4439 CC=$CC$ac_cv_sys_largefile_CC
4440 fi
b192d653 4441
c0d27fcc 4442 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4443echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4444if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4445 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4446else
503d2be0 4447 while :; do
f4988be7 4448 ac_cv_sys_file_offset_bits=no
503d2be0 4449 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4450#line $LINENO "configure"
19650fd6
AS
4451/* confdefs.h. */
4452_ACEOF
4453cat confdefs.h >>conftest.$ac_ext
4454cat >>conftest.$ac_ext <<_ACEOF
4455/* end confdefs.h. */
f4988be7 4456#include <sys/types.h>
503d2be0
AS
4457 /* Check that off_t can represent 2**63 - 1 correctly.
4458 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4459 since some C++ compilers masquerading as C compilers
4460 incorrectly reject 9223372036854775807. */
4461#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4462 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4463 && LARGE_OFF_T % 2147483647 == 1)
4464 ? 1 : -1];
4465int
4466main ()
4467{
f4988be7 4468
503d2be0
AS
4469 ;
4470 return 0;
4471}
4472_ACEOF
4473rm -f conftest.$ac_objext
c0d27fcc 4474if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4475 (eval $ac_compile) 2>&5
503d2be0 4476 ac_status=$?
c0d27fcc 4477 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4478 (exit $ac_status); } &&
7c9e5167 4479 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4481 (eval $ac_try) 2>&5
4482 ac_status=$?
c0d27fcc 4483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4484 (exit $ac_status); }; }; then
4485 break
f4988be7 4486else
503d2be0 4487 echo "$as_me: failed program was:" >&5
19650fd6
AS
4488sed 's/^/| /' conftest.$ac_ext >&5
4489
503d2be0 4490fi
7c9e5167 4491rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0 4492 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4493#line $LINENO "configure"
19650fd6
AS
4494/* confdefs.h. */
4495_ACEOF
4496cat confdefs.h >>conftest.$ac_ext
4497cat >>conftest.$ac_ext <<_ACEOF
4498/* end confdefs.h. */
f4988be7
GM
4499#define _FILE_OFFSET_BITS 64
4500#include <sys/types.h>
503d2be0
AS
4501 /* Check that off_t can represent 2**63 - 1 correctly.
4502 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4503 since some C++ compilers masquerading as C compilers
4504 incorrectly reject 9223372036854775807. */
4505#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4506 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4507 && LARGE_OFF_T % 2147483647 == 1)
4508 ? 1 : -1];
4509int
4510main ()
4511{
4512
4513 ;
4514 return 0;
4515}
4516_ACEOF
4517rm -f conftest.$ac_objext
c0d27fcc 4518if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4519 (eval $ac_compile) 2>&5
503d2be0 4520 ac_status=$?
c0d27fcc 4521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4522 (exit $ac_status); } &&
7c9e5167 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_file_offset_bits=64; break
4530else
4531 echo "$as_me: failed program was:" >&5
19650fd6
AS
4532sed 's/^/| /' conftest.$ac_ext >&5
4533
503d2be0 4534fi
7c9e5167 4535rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4536 break
4537done
ba4481b5 4538fi
c0d27fcc 4539echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4540echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4541if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4542
c0d27fcc 4543cat >>confdefs.h <<_ACEOF
f4988be7 4544#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4545_ACEOF
f4988be7 4546
503d2be0
AS
4547fi
4548rm -f conftest*
c0d27fcc 4549 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4550echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4551if test "${ac_cv_sys_large_files+set}" = set; then
4552 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4553else
503d2be0 4554 while :; do
f4988be7 4555 ac_cv_sys_large_files=no
503d2be0 4556 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4557#line $LINENO "configure"
19650fd6
AS
4558/* confdefs.h. */
4559_ACEOF
4560cat confdefs.h >>conftest.$ac_ext
4561cat >>conftest.$ac_ext <<_ACEOF
4562/* end confdefs.h. */
503d2be0
AS
4563#include <sys/types.h>
4564 /* Check that off_t can represent 2**63 - 1 correctly.
4565 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4566 since some C++ compilers masquerading as C compilers
4567 incorrectly reject 9223372036854775807. */
4568#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4569 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4570 && LARGE_OFF_T % 2147483647 == 1)
4571 ? 1 : -1];
4572int
4573main ()
4574{
ba4481b5 4575
503d2be0
AS
4576 ;
4577 return 0;
4578}
4579_ACEOF
4580rm -f conftest.$ac_objext
c0d27fcc 4581if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4582 (eval $ac_compile) 2>&5
503d2be0 4583 ac_status=$?
c0d27fcc 4584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4585 (exit $ac_status); } &&
7c9e5167 4586 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4587 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4588 (eval $ac_try) 2>&5
4589 ac_status=$?
c0d27fcc 4590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4591 (exit $ac_status); }; }; then
4592 break
ba4481b5 4593else
503d2be0 4594 echo "$as_me: failed program was:" >&5
19650fd6
AS
4595sed 's/^/| /' conftest.$ac_ext >&5
4596
503d2be0 4597fi
7c9e5167 4598rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0 4599 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4600#line $LINENO "configure"
19650fd6
AS
4601/* confdefs.h. */
4602_ACEOF
4603cat confdefs.h >>conftest.$ac_ext
4604cat >>conftest.$ac_ext <<_ACEOF
4605/* end confdefs.h. */
f4988be7 4606#define _LARGE_FILES 1
503d2be0
AS
4607#include <sys/types.h>
4608 /* Check that off_t can represent 2**63 - 1 correctly.
4609 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4610 since some C++ compilers masquerading as C compilers
4611 incorrectly reject 9223372036854775807. */
4612#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4613 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4614 && LARGE_OFF_T % 2147483647 == 1)
4615 ? 1 : -1];
4616int
4617main ()
4618{
f4988be7 4619
503d2be0
AS
4620 ;
4621 return 0;
4622}
4623_ACEOF
4624rm -f conftest.$ac_objext
c0d27fcc 4625if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4626 (eval $ac_compile) 2>&5
503d2be0 4627 ac_status=$?
c0d27fcc 4628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4629 (exit $ac_status); } &&
7c9e5167 4630 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4631 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4632 (eval $ac_try) 2>&5
4633 ac_status=$?
c0d27fcc 4634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4635 (exit $ac_status); }; }; then
4636 ac_cv_sys_large_files=1; break
4637else
4638 echo "$as_me: failed program was:" >&5
19650fd6
AS
4639sed 's/^/| /' conftest.$ac_ext >&5
4640
503d2be0 4641fi
7c9e5167 4642rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
4643 break
4644done
ba4481b5 4645fi
c0d27fcc 4646echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4647echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4648if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4649
c0d27fcc 4650cat >>confdefs.h <<_ACEOF
f4988be7 4651#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4652_ACEOF
ba4481b5 4653
503d2be0
AS
4654fi
4655rm -f conftest*
4656fi
ba4481b5 4657
c0d27fcc 4658
2c9dccc9
PJ
4659if test "${with_sound}" != "no"; then
4660 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4661 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4662echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4663if test "${ac_cv_header_stdc+set}" = set; then
4664 echo $ECHO_N "(cached) $ECHO_C" >&6
4665else
4666 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4667#line $LINENO "configure"
19650fd6
AS
4668/* confdefs.h. */
4669_ACEOF
4670cat confdefs.h >>conftest.$ac_ext
4671cat >>conftest.$ac_ext <<_ACEOF
4672/* end confdefs.h. */
c0d27fcc
MR
4673#include <stdlib.h>
4674#include <stdarg.h>
4675#include <string.h>
4676#include <float.h>
98418dba 4677
19650fd6
AS
4678int
4679main ()
4680{
4681
4682 ;
4683 return 0;
4684}
c0d27fcc 4685_ACEOF
19650fd6
AS
4686rm -f conftest.$ac_objext
4687if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4688 (eval $ac_compile) 2>&5
cd958eb3
MB
4689 ac_status=$?
4690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 4691 (exit $ac_status); } &&
7c9e5167 4692 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
4693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4694 (eval $ac_try) 2>&5
4695 ac_status=$?
4696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4697 (exit $ac_status); }; }; then
c0d27fcc
MR
4698 ac_cv_header_stdc=yes
4699else
4700 echo "$as_me: failed program was:" >&5
19650fd6
AS
4701sed 's/^/| /' conftest.$ac_ext >&5
4702
4703ac_cv_header_stdc=no
c0d27fcc 4704fi
7c9e5167 4705rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4706
4707if test $ac_cv_header_stdc = yes; then
4708 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4709 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4710#line $LINENO "configure"
19650fd6
AS
4711/* confdefs.h. */
4712_ACEOF
4713cat confdefs.h >>conftest.$ac_ext
4714cat >>conftest.$ac_ext <<_ACEOF
4715/* end confdefs.h. */
c0d27fcc
MR
4716#include <string.h>
4717
4718_ACEOF
4719if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4720 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4721 :
4722else
4723 ac_cv_header_stdc=no
4724fi
4725rm -f conftest*
4726
4727fi
4728
4729if test $ac_cv_header_stdc = yes; then
4730 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4731 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4732#line $LINENO "configure"
19650fd6
AS
4733/* confdefs.h. */
4734_ACEOF
4735cat confdefs.h >>conftest.$ac_ext
4736cat >>conftest.$ac_ext <<_ACEOF
4737/* end confdefs.h. */
c0d27fcc
MR
4738#include <stdlib.h>
4739
4740_ACEOF
4741if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4742 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4743 :
4744else
4745 ac_cv_header_stdc=no
4746fi
4747rm -f conftest*
4748
4749fi
4750
4751if test $ac_cv_header_stdc = yes; then
4752 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4753 if test "$cross_compiling" = yes; then
4754 :
4755else
4756 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4757#line $LINENO "configure"
19650fd6
AS
4758/* confdefs.h. */
4759_ACEOF
4760cat confdefs.h >>conftest.$ac_ext
4761cat >>conftest.$ac_ext <<_ACEOF
4762/* end confdefs.h. */
c0d27fcc
MR
4763#include <ctype.h>
4764#if ((' ' & 0x0FF) == 0x020)
4765# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4766# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4767#else
19650fd6 4768# define ISLOWER(c) \
7c9e5167
JD
4769 (('a' <= (c) && (c) <= 'i') \
4770 || ('j' <= (c) && (c) <= 'r') \
4771 || ('s' <= (c) && (c) <= 'z'))
c0d27fcc
MR
4772# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4773#endif
4774
4775#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4776int
4777main ()
4778{
4779 int i;
4780 for (i = 0; i < 256; i++)
4781 if (XOR (islower (i), ISLOWER (i))
7c9e5167 4782 || toupper (i) != TOUPPER (i))
c0d27fcc
MR
4783 exit(2);
4784 exit (0);
4785}
4786_ACEOF
4787rm -f conftest$ac_exeext
4788if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4789 (eval $ac_link) 2>&5
4790 ac_status=$?
4791 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4792 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4793 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4794 (eval $ac_try) 2>&5
4795 ac_status=$?
4796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4797 (exit $ac_status); }; }; then
4798 :
4799else
4800 echo "$as_me: program exited with status $ac_status" >&5
4801echo "$as_me: failed program was:" >&5
19650fd6
AS
4802sed 's/^/| /' conftest.$ac_ext >&5
4803
c0d27fcc
MR
4804( exit $ac_status )
4805ac_cv_header_stdc=no
4806fi
7c9e5167 4807rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4808fi
4809fi
4810fi
4811echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4812echo "${ECHO_T}$ac_cv_header_stdc" >&6
4813if test $ac_cv_header_stdc = yes; then
4814
4815cat >>confdefs.h <<\_ACEOF
4816#define STDC_HEADERS 1
4817_ACEOF
4818
4819fi
4820
4821# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7c9e5167 4832 inttypes.h stdint.h unistd.h
98418dba
CW
4833do
4834as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4835echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4836echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4837if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4838 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4839else
925c2f3f 4840 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4841#line $LINENO "configure"
19650fd6
AS
4842/* confdefs.h. */
4843_ACEOF
4844cat confdefs.h >>conftest.$ac_ext
4845cat >>conftest.$ac_ext <<_ACEOF
4846/* end confdefs.h. */
c0d27fcc
MR
4847$ac_includes_default
4848
4849#include <$ac_header>
4850_ACEOF
4851rm -f conftest.$ac_objext
4852if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4853 (eval $ac_compile) 2>&5
c0d27fcc
MR
4854 ac_status=$?
4855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4856 (exit $ac_status); } &&
7c9e5167 4857 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
4858 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4859 (eval $ac_try) 2>&5
4860 ac_status=$?
4861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4862 (exit $ac_status); }; }; then
4863 eval "$as_ac_Header=yes"
4864else
4865 echo "$as_me: failed program was:" >&5
19650fd6
AS
4866sed 's/^/| /' conftest.$ac_ext >&5
4867
c0d27fcc
MR
4868eval "$as_ac_Header=no"
4869fi
7c9e5167 4870rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4871fi
4872echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4873echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4874if test `eval echo '${'$as_ac_Header'}'` = yes; then
4875 cat >>confdefs.h <<_ACEOF
4876#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4877_ACEOF
4878
4879fi
4880
4881done
4882
4883
4884
4885
4886
4887for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
4888do
4889as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4890if eval "test \"\${$as_ac_Header+set}\" = set"; then
4891 echo "$as_me:$LINENO: checking for $ac_header" >&5
4892echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4893if eval "test \"\${$as_ac_Header+set}\" = set"; then
4894 echo $ECHO_N "(cached) $ECHO_C" >&6
4895fi
4896echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4897echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4898else
4899 # Is the header compilable?
4900echo "$as_me:$LINENO: checking $ac_header usability" >&5
4901echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4902cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4903#line $LINENO "configure"
19650fd6
AS
4904/* confdefs.h. */
4905_ACEOF
4906cat confdefs.h >>conftest.$ac_ext
4907cat >>conftest.$ac_ext <<_ACEOF
4908/* end confdefs.h. */
c0d27fcc 4909$ac_includes_default
98418dba 4910#include <$ac_header>
503d2be0 4911_ACEOF
c0d27fcc
MR
4912rm -f conftest.$ac_objext
4913if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 4914 (eval $ac_compile) 2>&5
c0d27fcc
MR
4915 ac_status=$?
4916 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4917 (exit $ac_status); } &&
7c9e5167 4918 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
4919 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4920 (eval $ac_try) 2>&5
4921 ac_status=$?
4922 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4923 (exit $ac_status); }; }; then
4924 ac_header_compiler=yes
4925else
4926 echo "$as_me: failed program was:" >&5
19650fd6
AS
4927sed 's/^/| /' conftest.$ac_ext >&5
4928
c0d27fcc
MR
4929ac_header_compiler=no
4930fi
7c9e5167 4931rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4932echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4933echo "${ECHO_T}$ac_header_compiler" >&6
4934
4935# Is the header present?
4936echo "$as_me:$LINENO: checking $ac_header presence" >&5
4937echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4938cat >conftest.$ac_ext <<_ACEOF
7c9e5167 4939#line $LINENO "configure"
19650fd6
AS
4940/* confdefs.h. */
4941_ACEOF
4942cat confdefs.h >>conftest.$ac_ext
4943cat >>conftest.$ac_ext <<_ACEOF
4944/* end confdefs.h. */
c0d27fcc
MR
4945#include <$ac_header>
4946_ACEOF
4947if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 4948 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 4949 ac_status=$?
6bae0ccf 4950 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
4951 rm -f conftest.er1
4952 cat conftest.err >&5
c0d27fcc 4953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
4954 (exit $ac_status); } >/dev/null; then
4955 if test -s conftest.err; then
4956 ac_cpp_err=$ac_c_preproc_warn_flag
4957 else
4958 ac_cpp_err=
4959 fi
4960else
4961 ac_cpp_err=yes
4962fi
4963if test -z "$ac_cpp_err"; then
c0d27fcc 4964 ac_header_preproc=yes
f4988be7 4965else
503d2be0 4966 echo "$as_me: failed program was:" >&5
19650fd6
AS
4967sed 's/^/| /' conftest.$ac_ext >&5
4968
c0d27fcc 4969 ac_header_preproc=no
f4988be7 4970fi
98418dba 4971rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
4972echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4973echo "${ECHO_T}$ac_header_preproc" >&6
4974
4975# So? What about this header?
7c9e5167
JD
4976case $ac_header_compiler:$ac_header_preproc in
4977 yes:no )
c0d27fcc
MR
4978 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4979echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
4980 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4981echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4982 (
4983 cat <<\_ASBOX
4984## ------------------------------------ ##
4985## Report this to bug-autoconf@gnu.org. ##
4986## ------------------------------------ ##
4987_ASBOX
4988 ) |
4989 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 4990 ;;
7c9e5167 4991 no:yes )
c0d27fcc
MR
4992 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4993echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
4994 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4995echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 4996 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 4997echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
4998 (
4999 cat <<\_ASBOX
7c9e5167
JD
5000## ------------------------------------ ##
5001## Report this to bug-autoconf@gnu.org. ##
5002## ------------------------------------ ##
19650fd6
AS
5003_ASBOX
5004 ) |
5005 sed "s/^/$as_me: WARNING: /" >&2
5006 ;;
c0d27fcc
MR
5007esac
5008echo "$as_me:$LINENO: checking for $ac_header" >&5
5009echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5010if eval "test \"\${$as_ac_Header+set}\" = set"; then
5011 echo $ECHO_N "(cached) $ECHO_C" >&6
5012else
7c9e5167 5013 eval "$as_ac_Header=$ac_header_preproc"
f4988be7 5014fi
c0d27fcc 5015echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5016echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5017
5018fi
98418dba 5019if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5020 cat >>confdefs.h <<_ACEOF
98418dba 5021#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5022_ACEOF
f4988be7
GM
5023
5024fi
c0d27fcc 5025
98418dba
CW
5026done
5027
5028 # Emulation library used on NetBSD.
c0d27fcc 5029 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
5030echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
5031if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 5032 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 5033else
98418dba
CW
5034 ac_check_lib_save_LIBS=$LIBS
5035LIBS="-lossaudio $LIBS"
5036cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5037#line $LINENO "configure"
19650fd6
AS
5038/* confdefs.h. */
5039_ACEOF
5040cat confdefs.h >>conftest.$ac_ext
5041cat >>conftest.$ac_ext <<_ACEOF
5042/* end confdefs.h. */
98418dba
CW
5043
5044/* Override any gcc2 internal prototype to avoid an error. */
5045#ifdef __cplusplus
5046extern "C"
f4988be7 5047#endif
98418dba
CW
5048/* We use char because int might match the return type of a gcc2
5049 builtin and then its argument prototype would still apply. */
5050char _oss_ioctl ();
503d2be0
AS
5051int
5052main ()
5053{
98418dba 5054_oss_ioctl ();
503d2be0
AS
5055 ;
5056 return 0;
5057}
5058_ACEOF
98418dba 5059rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 5060if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 5061 (eval $ac_link) 2>&5
503d2be0 5062 ac_status=$?
c0d27fcc 5063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5064 (exit $ac_status); } &&
7c9e5167 5065 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 5066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5067 (eval $ac_try) 2>&5
5068 ac_status=$?
c0d27fcc 5069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5070 (exit $ac_status); }; }; then
98418dba 5071 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 5072else
503d2be0 5073 echo "$as_me: failed program was:" >&5
19650fd6
AS
5074sed 's/^/| /' conftest.$ac_ext >&5
5075
98418dba 5076ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 5077fi
7c9e5167 5078rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 5079LIBS=$ac_check_lib_save_LIBS
f4988be7 5080fi
c0d27fcc 5081echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
5082echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5083if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5084 LIBSOUND=-lossaudio
5085else
5086 LIBSOUND=
5087fi
5088
c0d27fcc 5089
f4988be7 5090fi
c0d27fcc
MR
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
22044edf
DL
5109
5110
973a76b1 5111
cffcede7 5112
551ffc27 5113
226e2359 5114
c0d27fcc 5115
f4988be7 5116
98418dba
CW
5117for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5118 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
25ca0bca 5119 termcap.h stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
551ffc27 5120 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
226e2359 5121 sys/utsname.h pwd.h
98418dba
CW
5122do
5123as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5124if eval "test \"\${$as_ac_Header+set}\" = set"; then
5125 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5126echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5127if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5128 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5129fi
5130echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5131echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5132else
c0d27fcc
MR
5133 # Is the header compilable?
5134echo "$as_me:$LINENO: checking $ac_header usability" >&5
5135echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5136cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5137#line $LINENO "configure"
19650fd6
AS
5138/* confdefs.h. */
5139_ACEOF
5140cat confdefs.h >>conftest.$ac_ext
5141cat >>conftest.$ac_ext <<_ACEOF
5142/* end confdefs.h. */
c0d27fcc
MR
5143$ac_includes_default
5144#include <$ac_header>
5145_ACEOF
5146rm -f conftest.$ac_objext
5147if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5148 (eval $ac_compile) 2>&5
c0d27fcc
MR
5149 ac_status=$?
5150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5151 (exit $ac_status); } &&
7c9e5167 5152 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
5153 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5154 (eval $ac_try) 2>&5
5155 ac_status=$?
5156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5157 (exit $ac_status); }; }; then
5158 ac_header_compiler=yes
5159else
5160 echo "$as_me: failed program was:" >&5
19650fd6
AS
5161sed 's/^/| /' conftest.$ac_ext >&5
5162
c0d27fcc
MR
5163ac_header_compiler=no
5164fi
7c9e5167 5165rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
5166echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5167echo "${ECHO_T}$ac_header_compiler" >&6
5168
5169# Is the header present?
5170echo "$as_me:$LINENO: checking $ac_header presence" >&5
5171echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5172cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5173#line $LINENO "configure"
19650fd6
AS
5174/* confdefs.h. */
5175_ACEOF
5176cat confdefs.h >>conftest.$ac_ext
5177cat >>conftest.$ac_ext <<_ACEOF
5178/* end confdefs.h. */
98418dba 5179#include <$ac_header>
503d2be0 5180_ACEOF
c0d27fcc 5181if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5182 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5183 ac_status=$?
6bae0ccf 5184 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5185 rm -f conftest.er1
5186 cat conftest.err >&5
c0d27fcc 5187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5188 (exit $ac_status); } >/dev/null; then
5189 if test -s conftest.err; then
5190 ac_cpp_err=$ac_c_preproc_warn_flag
5191 else
5192 ac_cpp_err=
5193 fi
5194else
5195 ac_cpp_err=yes
5196fi
5197if test -z "$ac_cpp_err"; then
c0d27fcc 5198 ac_header_preproc=yes
34ec9ebe 5199else
503d2be0 5200 echo "$as_me: failed program was:" >&5
19650fd6
AS
5201sed 's/^/| /' conftest.$ac_ext >&5
5202
c0d27fcc 5203 ac_header_preproc=no
34ec9ebe 5204fi
98418dba 5205rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5206echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5207echo "${ECHO_T}$ac_header_preproc" >&6
5208
5209# So? What about this header?
7c9e5167
JD
5210case $ac_header_compiler:$ac_header_preproc in
5211 yes:no )
c0d27fcc
MR
5212 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5213echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
5214 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
5215echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5216 (
5217 cat <<\_ASBOX
5218## ------------------------------------ ##
5219## Report this to bug-autoconf@gnu.org. ##
5220## ------------------------------------ ##
5221_ASBOX
5222 ) |
5223 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 5224 ;;
7c9e5167 5225 no:yes )
c0d27fcc
MR
5226 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5227echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
5228 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5229echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 5230 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 5231echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
5232 (
5233 cat <<\_ASBOX
7c9e5167
JD
5234## ------------------------------------ ##
5235## Report this to bug-autoconf@gnu.org. ##
5236## ------------------------------------ ##
19650fd6
AS
5237_ASBOX
5238 ) |
5239 sed "s/^/$as_me: WARNING: /" >&2
5240 ;;
c0d27fcc
MR
5241esac
5242echo "$as_me:$LINENO: checking for $ac_header" >&5
5243echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5244if eval "test \"\${$as_ac_Header+set}\" = set"; then
5245 echo $ECHO_N "(cached) $ECHO_C" >&6
5246else
7c9e5167 5247 eval "$as_ac_Header=$ac_header_preproc"
34ec9ebe 5248fi
c0d27fcc 5249echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5250echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5251
5252fi
98418dba 5253if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5254 cat >>confdefs.h <<_ACEOF
98418dba 5255#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5256_ACEOF
34ec9ebe 5257
98418dba 5258fi
c0d27fcc 5259
98418dba
CW
5260done
5261
22044edf 5262
f17e308a
JD
5263echo "$as_me:$LINENO: checking if personality LINUX32 can be set" >&5
5264echo $ECHO_N "checking if personality LINUX32 can be set... $ECHO_C" >&6
5265cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5266#line $LINENO "configure"
f17e308a
JD
5267/* confdefs.h. */
5268_ACEOF
5269cat confdefs.h >>conftest.$ac_ext
5270cat >>conftest.$ac_ext <<_ACEOF
5271/* end confdefs.h. */
5272#include <sys/personality.h>
5273int
5274main ()
5275{
5276personality (PER_LINUX32)
5277 ;
5278 return 0;
5279}
5280_ACEOF
5281rm -f conftest.$ac_objext
5282if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5283 (eval $ac_compile) 2>&5
f17e308a 5284 ac_status=$?
f17e308a
JD
5285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5286 (exit $ac_status); } &&
7c9e5167 5287 { ac_try='test -s conftest.$ac_objext'
f17e308a
JD
5288 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5289 (eval $ac_try) 2>&5
5290 ac_status=$?
5291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5292 (exit $ac_status); }; }; then
5293 emacs_cv_personality_linux32=yes
5294else
5295 echo "$as_me: failed program was:" >&5
5296sed 's/^/| /' conftest.$ac_ext >&5
5297
5298emacs_cv_personality_linux32=no
5299fi
7c9e5167 5300rm -f conftest.$ac_objext conftest.$ac_ext
f17e308a
JD
5301echo "$as_me:$LINENO: result: $emacs_cv_personality_linux32" >&5
5302echo "${ECHO_T}$emacs_cv_personality_linux32" >&6
5303
5304if test $emacs_cv_personality_linux32 = yes; then
5305
5306cat >>confdefs.h <<\_ACEOF
5307#define HAVE_PERSONALITY_LINUX32 1
5308_ACEOF
5309
5310fi
5311
5312
22044edf
DL
5313for ac_header in term.h
5314do
5315as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5316echo "$as_me:$LINENO: checking for $ac_header" >&5
5317echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5318if eval "test \"\${$as_ac_Header+set}\" = set"; then
5319 echo $ECHO_N "(cached) $ECHO_C" >&6
5320else
5321 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5322#line $LINENO "configure"
19650fd6
AS
5323/* confdefs.h. */
5324_ACEOF
5325cat confdefs.h >>conftest.$ac_ext
5326cat >>conftest.$ac_ext <<_ACEOF
5327/* end confdefs.h. */
22044edf
DL
5328#include <$ac_header>
5329_ACEOF
5330if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5331 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5332 ac_status=$?
5333 grep -v '^ *+' conftest.er1 >conftest.err
5334 rm -f conftest.er1
5335 cat conftest.err >&5
5336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5337 (exit $ac_status); } >/dev/null; then
5338 if test -s conftest.err; then
5339 ac_cpp_err=$ac_c_preproc_warn_flag
5340 else
5341 ac_cpp_err=
5342 fi
5343else
5344 ac_cpp_err=yes
5345fi
5346if test -z "$ac_cpp_err"; then
5347 eval "$as_ac_Header=yes"
5348else
5349 echo "$as_me: failed program was:" >&5
19650fd6
AS
5350sed 's/^/| /' conftest.$ac_ext >&5
5351
22044edf
DL
5352 eval "$as_ac_Header=no"
5353fi
5354rm -f conftest.err conftest.$ac_ext
5355fi
5356echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5357echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5358if test `eval echo '${'$as_ac_Header'}'` = yes; then
5359 cat >>confdefs.h <<_ACEOF
5360#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5361_ACEOF
5362
5363fi
5364
5365done
5366
c0d27fcc 5367echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5368echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5369if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5370 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5371else
503d2be0 5372 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5373#line $LINENO "configure"
19650fd6
AS
5374/* confdefs.h. */
5375_ACEOF
5376cat confdefs.h >>conftest.$ac_ext
5377cat >>conftest.$ac_ext <<_ACEOF
5378/* end confdefs.h. */
98418dba
CW
5379#include <stdlib.h>
5380#include <stdarg.h>
5381#include <string.h>
5382#include <float.h>
5383
19650fd6
AS
5384int
5385main ()
5386{
5387
5388 ;
5389 return 0;
5390}
98418dba 5391_ACEOF
19650fd6
AS
5392rm -f conftest.$ac_objext
5393if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5394 (eval $ac_compile) 2>&5
cd958eb3
MB
5395 ac_status=$?
5396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19650fd6 5397 (exit $ac_status); } &&
7c9e5167 5398 { ac_try='test -s conftest.$ac_objext'
19650fd6
AS
5399 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5400 (eval $ac_try) 2>&5
5401 ac_status=$?
5402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5403 (exit $ac_status); }; }; then
98418dba 5404 ac_cv_header_stdc=yes
ba4481b5 5405else
503d2be0 5406 echo "$as_me: failed program was:" >&5
19650fd6
AS
5407sed 's/^/| /' conftest.$ac_ext >&5
5408
5409ac_cv_header_stdc=no
ba4481b5 5410fi
7c9e5167 5411rm -f conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5412
5413if test $ac_cv_header_stdc = yes; then
5414 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5415 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5416#line $LINENO "configure"
19650fd6
AS
5417/* confdefs.h. */
5418_ACEOF
5419cat confdefs.h >>conftest.$ac_ext
5420cat >>conftest.$ac_ext <<_ACEOF
5421/* end confdefs.h. */
98418dba
CW
5422#include <string.h>
5423
5424_ACEOF
5425if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5426 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5427 :
5428else
5429 ac_cv_header_stdc=no
ba4481b5 5430fi
98418dba 5431rm -f conftest*
ba4481b5
DL
5432
5433fi
5434
98418dba
CW
5435if test $ac_cv_header_stdc = yes; then
5436 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5437 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5438#line $LINENO "configure"
19650fd6
AS
5439/* confdefs.h. */
5440_ACEOF
5441cat confdefs.h >>conftest.$ac_ext
5442cat >>conftest.$ac_ext <<_ACEOF
5443/* end confdefs.h. */
98418dba
CW
5444#include <stdlib.h>
5445
5446_ACEOF
5447if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5448 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5449 :
5450else
5451 ac_cv_header_stdc=no
5452fi
5453rm -f conftest*
5454
5455fi
5456
5457if test $ac_cv_header_stdc = yes; then
5458 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5459 if test "$cross_compiling" = yes; then
5460 :
d42122a3 5461else
503d2be0 5462 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5463#line $LINENO "configure"
19650fd6
AS
5464/* confdefs.h. */
5465_ACEOF
5466cat confdefs.h >>conftest.$ac_ext
5467cat >>conftest.$ac_ext <<_ACEOF
5468/* end confdefs.h. */
98418dba
CW
5469#include <ctype.h>
5470#if ((' ' & 0x0FF) == 0x020)
5471# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5472# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5473#else
19650fd6 5474# define ISLOWER(c) \
7c9e5167
JD
5475 (('a' <= (c) && (c) <= 'i') \
5476 || ('j' <= (c) && (c) <= 'r') \
5477 || ('s' <= (c) && (c) <= 'z'))
98418dba
CW
5478# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5479#endif
5480
5481#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5482int
5483main ()
5484{
98418dba
CW
5485 int i;
5486 for (i = 0; i < 256; i++)
5487 if (XOR (islower (i), ISLOWER (i))
7c9e5167 5488 || toupper (i) != TOUPPER (i))
98418dba
CW
5489 exit(2);
5490 exit (0);
503d2be0
AS
5491}
5492_ACEOF
98418dba 5493rm -f conftest$ac_exeext
c0d27fcc 5494if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5495 (eval $ac_link) 2>&5
503d2be0 5496 ac_status=$?
c0d27fcc 5497 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5498 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5499 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5500 (eval $ac_try) 2>&5
5501 ac_status=$?
c0d27fcc 5502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5503 (exit $ac_status); }; }; then
98418dba 5504 :
d42122a3 5505else
98418dba
CW
5506 echo "$as_me: program exited with status $ac_status" >&5
5507echo "$as_me: failed program was:" >&5
19650fd6
AS
5508sed 's/^/| /' conftest.$ac_ext >&5
5509
c0d27fcc 5510( exit $ac_status )
98418dba 5511ac_cv_header_stdc=no
d42122a3 5512fi
7c9e5167 5513rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5514fi
98418dba
CW
5515fi
5516fi
c0d27fcc 5517echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5518echo "${ECHO_T}$ac_cv_header_stdc" >&6
5519if test $ac_cv_header_stdc = yes; then
5520
c0d27fcc 5521cat >>confdefs.h <<\_ACEOF
98418dba 5522#define STDC_HEADERS 1
c0d27fcc 5523_ACEOF
d42122a3
DL
5524
5525fi
5526
c0d27fcc 5527echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5528echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5529if test "${ac_cv_header_time+set}" = set; then
503d2be0 5530 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5531else
503d2be0 5532 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5533#line $LINENO "configure"
19650fd6
AS
5534/* confdefs.h. */
5535_ACEOF
5536cat confdefs.h >>conftest.$ac_ext
5537cat >>conftest.$ac_ext <<_ACEOF
5538/* end confdefs.h. */
ba4481b5 5539#include <sys/types.h>
98418dba 5540#include <sys/time.h>
ba4481b5 5541#include <time.h>
503d2be0
AS
5542
5543int
5544main ()
5545{
98418dba
CW
5546if ((struct tm *) 0)
5547return 0;
503d2be0
AS
5548 ;
5549 return 0;
5550}
5551_ACEOF
5552rm -f conftest.$ac_objext
c0d27fcc 5553if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5554 (eval $ac_compile) 2>&5
503d2be0 5555 ac_status=$?
c0d27fcc 5556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5557 (exit $ac_status); } &&
7c9e5167 5558 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5559 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5560 (eval $ac_try) 2>&5
5561 ac_status=$?
c0d27fcc 5562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5563 (exit $ac_status); }; }; then
98418dba 5564 ac_cv_header_time=yes
ba4481b5 5565else
503d2be0 5566 echo "$as_me: failed program was:" >&5
19650fd6
AS
5567sed 's/^/| /' conftest.$ac_ext >&5
5568
98418dba 5569ac_cv_header_time=no
ba4481b5 5570fi
7c9e5167 5571rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5572fi
c0d27fcc 5573echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5574echo "${ECHO_T}$ac_cv_header_time" >&6
5575if test $ac_cv_header_time = yes; then
503d2be0 5576
c0d27fcc 5577cat >>confdefs.h <<\_ACEOF
98418dba 5578#define TIME_WITH_SYS_TIME 1
c0d27fcc 5579_ACEOF
ba4481b5
DL
5580
5581fi
5582
cd958eb3
MB
5583echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5584echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5585if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5586 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5587else
503d2be0 5588 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5589#line $LINENO "configure"
19650fd6
AS
5590/* confdefs.h. */
5591_ACEOF
5592cat confdefs.h >>conftest.$ac_ext
5593cat >>conftest.$ac_ext <<_ACEOF
5594/* end confdefs.h. */
cd958eb3
MB
5595$ac_includes_default
5596int
5597main ()
5598{
5599#ifndef sys_siglist
5600 char *p = (char *) sys_siglist;
98418dba 5601#endif
503d2be0 5602
cd958eb3
MB
5603 ;
5604 return 0;
5605}
5606_ACEOF
5607rm -f conftest.$ac_objext
5608if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5609 (eval $ac_compile) 2>&5
cd958eb3
MB
5610 ac_status=$?
5611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5612 (exit $ac_status); } &&
7c9e5167 5613 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
5614 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5615 (eval $ac_try) 2>&5
5616 ac_status=$?
5617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5618 (exit $ac_status); }; }; then
5619 ac_cv_have_decl_sys_siglist=yes
5620else
5621 echo "$as_me: failed program was:" >&5
19650fd6
AS
5622sed 's/^/| /' conftest.$ac_ext >&5
5623
cd958eb3
MB
5624ac_cv_have_decl_sys_siglist=no
5625fi
7c9e5167 5626rm -f conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
5627fi
5628echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5629echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5630if test $ac_cv_have_decl_sys_siglist = yes; then
5631
5632cat >>confdefs.h <<_ACEOF
5633#define HAVE_DECL_SYS_SIGLIST 1
5634_ACEOF
5635
5636
5637else
5638 cat >>confdefs.h <<_ACEOF
5639#define HAVE_DECL_SYS_SIGLIST 0
5640_ACEOF
5641
5642
5643fi
5644
5645
5646if test $ac_cv_have_decl_sys_siglist != yes; then
5647 # For Tru64, at least:
5648 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5649echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5650if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5651 echo $ECHO_N "(cached) $ECHO_C" >&6
5652else
5653 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5654#line $LINENO "configure"
19650fd6
AS
5655/* confdefs.h. */
5656_ACEOF
5657cat confdefs.h >>conftest.$ac_ext
5658cat >>conftest.$ac_ext <<_ACEOF
5659/* end confdefs.h. */
cd958eb3 5660$ac_includes_default
503d2be0
AS
5661int
5662main ()
5663{
cd958eb3
MB
5664#ifndef __sys_siglist
5665 char *p = (char *) __sys_siglist;
5666#endif
5667
503d2be0
AS
5668 ;
5669 return 0;
5670}
5671_ACEOF
5672rm -f conftest.$ac_objext
c0d27fcc 5673if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5674 (eval $ac_compile) 2>&5
503d2be0 5675 ac_status=$?
c0d27fcc 5676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5677 (exit $ac_status); } &&
7c9e5167 5678 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5679 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5680 (eval $ac_try) 2>&5
5681 ac_status=$?
c0d27fcc 5682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5683 (exit $ac_status); }; }; then
cd958eb3 5684 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5685else
503d2be0 5686 echo "$as_me: failed program was:" >&5
19650fd6
AS
5687sed 's/^/| /' conftest.$ac_ext >&5
5688
cd958eb3 5689ac_cv_have_decl___sys_siglist=no
ba4481b5 5690fi
7c9e5167 5691rm -f conftest.$ac_objext conftest.$ac_ext
503d2be0 5692fi
cd958eb3
MB
5693echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5694echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5695if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5696
cd958eb3
MB
5697cat >>confdefs.h <<_ACEOF
5698#define HAVE_DECL___SYS_SIGLIST 1
5699_ACEOF
5700
5701
5702else
5703 cat >>confdefs.h <<_ACEOF
5704#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5705_ACEOF
503d2be0 5706
cd958eb3 5707
ba4481b5
DL
5708fi
5709
cd958eb3
MB
5710
5711 if test $ac_cv_have_decl___sys_siglist = yes; then
5712
5713cat >>confdefs.h <<\_ACEOF
5714#define sys_siglist __sys_siglist
5715_ACEOF
5716
5717 fi
5718fi
c0d27fcc 5719echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5720echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5721if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5722 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5723else
503d2be0 5724 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5725#line $LINENO "configure"
19650fd6
AS
5726/* confdefs.h. */
5727_ACEOF
5728cat confdefs.h >>conftest.$ac_ext
5729cat >>conftest.$ac_ext <<_ACEOF
5730/* end confdefs.h. */
98418dba
CW
5731#include <sys/types.h>
5732#include <sys/wait.h>
5733#ifndef WEXITSTATUS
5734# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5735#endif
5736#ifndef WIFEXITED
5737# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5738#endif
503d2be0
AS
5739
5740int
5741main ()
5742{
98418dba
CW
5743 int s;
5744 wait (&s);
5745 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5746 ;
5747 return 0;
5748}
5749_ACEOF
98418dba 5750rm -f conftest.$ac_objext
c0d27fcc 5751if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5752 (eval $ac_compile) 2>&5
503d2be0 5753 ac_status=$?
c0d27fcc 5754 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5755 (exit $ac_status); } &&
7c9e5167 5756 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5757 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5758 (eval $ac_try) 2>&5
5759 ac_status=$?
c0d27fcc 5760 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5761 (exit $ac_status); }; }; then
98418dba 5762 ac_cv_header_sys_wait_h=yes
ba4481b5 5763else
503d2be0 5764 echo "$as_me: failed program was:" >&5
19650fd6
AS
5765sed 's/^/| /' conftest.$ac_ext >&5
5766
98418dba 5767ac_cv_header_sys_wait_h=no
ba4481b5 5768fi
7c9e5167 5769rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5770fi
c0d27fcc 5771echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5772echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5773if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5774
c0d27fcc 5775cat >>confdefs.h <<\_ACEOF
98418dba 5776#define HAVE_SYS_WAIT_H 1
c0d27fcc 5777_ACEOF
ba4481b5 5778
ba4481b5
DL
5779fi
5780
c0d27fcc
MR
5781
5782echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5783echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5784if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5785 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5786else
503d2be0 5787 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5788#line $LINENO "configure"
19650fd6
AS
5789/* confdefs.h. */
5790_ACEOF
5791cat confdefs.h >>conftest.$ac_ext
5792cat >>conftest.$ac_ext <<_ACEOF
5793/* end confdefs.h. */
98418dba
CW
5794#ifdef TIME_WITH_SYS_TIME
5795#include <sys/time.h>
5796#include <time.h>
5797#else
5798#ifdef HAVE_SYS_TIME_H
5799#include <sys/time.h>
5800#else
1113b624 5801#include <time.h>
98418dba
CW
5802#endif
5803#endif
5804#ifdef HAVE_UTIME_H
5805#include <utime.h>
5806#endif
503d2be0
AS
5807int
5808main ()
5809{
98418dba 5810static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5811 ;
5812 return 0;
5813}
5814_ACEOF
98418dba 5815rm -f conftest.$ac_objext
c0d27fcc 5816if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5817 (eval $ac_compile) 2>&5
503d2be0 5818 ac_status=$?
c0d27fcc 5819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5820 (exit $ac_status); } &&
7c9e5167 5821 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5822 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5823 (eval $ac_try) 2>&5
5824 ac_status=$?
c0d27fcc 5825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5826 (exit $ac_status); }; }; then
98418dba 5827 emacs_cv_struct_utimbuf=yes
1113b624 5828else
503d2be0 5829 echo "$as_me: failed program was:" >&5
19650fd6
AS
5830sed 's/^/| /' conftest.$ac_ext >&5
5831
98418dba 5832emacs_cv_struct_utimbuf=no
1113b624 5833fi
7c9e5167 5834rm -f conftest.$ac_objext conftest.$ac_ext
1113b624 5835fi
c0d27fcc 5836echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
5837echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
5838if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 5839
c0d27fcc 5840cat >>confdefs.h <<\_ACEOF
98418dba 5841#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 5842_ACEOF
1113b624
PE
5843
5844fi
ba4481b5 5845
c0d27fcc 5846echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
5847echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5848if test "${ac_cv_type_signal+set}" = set; then
503d2be0 5849 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5850else
98418dba 5851 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5852#line $LINENO "configure"
19650fd6
AS
5853/* confdefs.h. */
5854_ACEOF
5855cat confdefs.h >>conftest.$ac_ext
5856cat >>conftest.$ac_ext <<_ACEOF
5857/* end confdefs.h. */
7397acc4 5858#include <sys/types.h>
98418dba
CW
5859#include <signal.h>
5860#ifdef signal
5861# undef signal
5862#endif
5863#ifdef __cplusplus
5864extern "C" void (*signal (int, void (*)(int)))(int);
5865#else
5866void (*signal ()) ();
5867#endif
5868
503d2be0
AS
5869int
5870main ()
5871{
98418dba 5872int i;
503d2be0
AS
5873 ;
5874 return 0;
5875}
5876_ACEOF
98418dba 5877rm -f conftest.$ac_objext
c0d27fcc 5878if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5879 (eval $ac_compile) 2>&5
503d2be0 5880 ac_status=$?
c0d27fcc 5881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5882 (exit $ac_status); } &&
7c9e5167 5883 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5884 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5885 (eval $ac_try) 2>&5
5886 ac_status=$?
c0d27fcc 5887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5888 (exit $ac_status); }; }; then
98418dba 5889 ac_cv_type_signal=void
503d2be0
AS
5890else
5891 echo "$as_me: failed program was:" >&5
19650fd6
AS
5892sed 's/^/| /' conftest.$ac_ext >&5
5893
98418dba 5894ac_cv_type_signal=int
503d2be0 5895fi
7c9e5167 5896rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5897fi
c0d27fcc 5898echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 5899echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 5900
c0d27fcc 5901cat >>confdefs.h <<_ACEOF
98418dba 5902#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
5903_ACEOF
5904
503d2be0 5905
c0d27fcc
MR
5906
5907echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
5908echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
5909if test "${emacs_cv_speed_t+set}" = set; then
5910 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5911else
98418dba 5912 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5913#line $LINENO "configure"
19650fd6
AS
5914/* confdefs.h. */
5915_ACEOF
5916cat confdefs.h >>conftest.$ac_ext
5917cat >>conftest.$ac_ext <<_ACEOF
5918/* end confdefs.h. */
98418dba 5919#include <termios.h>
98418dba
CW
5920int
5921main ()
5922{
5923speed_t x = 1;
5924 ;
5925 return 0;
5926}
5927_ACEOF
5928rm -f conftest.$ac_objext
c0d27fcc 5929if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5930 (eval $ac_compile) 2>&5
98418dba 5931 ac_status=$?
c0d27fcc 5932 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5933 (exit $ac_status); } &&
7c9e5167 5934 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5935 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
5936 (eval $ac_try) 2>&5
5937 ac_status=$?
c0d27fcc 5938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5939 (exit $ac_status); }; }; then
5940 emacs_cv_speed_t=yes
5941else
5942 echo "$as_me: failed program was:" >&5
19650fd6
AS
5943sed 's/^/| /' conftest.$ac_ext >&5
5944
98418dba
CW
5945emacs_cv_speed_t=no
5946fi
7c9e5167 5947rm -f conftest.$ac_objext conftest.$ac_ext
98418dba 5948fi
c0d27fcc 5949echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
5950echo "${ECHO_T}$emacs_cv_speed_t" >&6
5951if test $emacs_cv_speed_t = yes; then
b936fae4 5952
c0d27fcc 5953cat >>confdefs.h <<\_ACEOF
98418dba 5954#define HAVE_SPEED_T 1
c0d27fcc 5955_ACEOF
98418dba 5956
7397acc4
DL
5957fi
5958
c0d27fcc 5959echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
5960echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
5961if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 5962 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5963else
503d2be0 5964 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 5965#line $LINENO "configure"
19650fd6
AS
5966/* confdefs.h. */
5967_ACEOF
5968cat confdefs.h >>conftest.$ac_ext
5969cat >>conftest.$ac_ext <<_ACEOF
5970/* end confdefs.h. */
98418dba
CW
5971#ifdef TIME_WITH_SYS_TIME
5972#include <sys/time.h>
5973#include <time.h>
5974#else
5975#ifdef HAVE_SYS_TIME_H
5976#include <sys/time.h>
5977#else
5978#include <time.h>
5979#endif
5980#endif
503d2be0
AS
5981int
5982main ()
5983{
98418dba 5984static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
5985 ;
5986 return 0;
5987}
5988_ACEOF
5989rm -f conftest.$ac_objext
c0d27fcc 5990if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 5991 (eval $ac_compile) 2>&5
503d2be0 5992 ac_status=$?
c0d27fcc 5993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5994 (exit $ac_status); } &&
7c9e5167 5995 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5996 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5997 (eval $ac_try) 2>&5
5998 ac_status=$?
c0d27fcc 5999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6000 (exit $ac_status); }; }; then
98418dba 6001 emacs_cv_struct_timeval=yes
7397acc4 6002else
503d2be0 6003 echo "$as_me: failed program was:" >&5
19650fd6
AS
6004sed 's/^/| /' conftest.$ac_ext >&5
6005
98418dba 6006emacs_cv_struct_timeval=no
7397acc4 6007fi
7c9e5167 6008rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 6009fi
c0d27fcc 6010echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
6011echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
6012HAVE_TIMEVAL=$emacs_cv_struct_timeval
6013if test $emacs_cv_struct_timeval = yes; then
b936fae4 6014
c0d27fcc 6015cat >>confdefs.h <<\_ACEOF
98418dba 6016#define HAVE_TIMEVAL 1
c0d27fcc 6017_ACEOF
7397acc4
DL
6018
6019fi
6020
c0d27fcc 6021echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
6022echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
6023if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 6024 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6025else
503d2be0 6026 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6027#line $LINENO "configure"
19650fd6
AS
6028/* confdefs.h. */
6029_ACEOF
6030cat confdefs.h >>conftest.$ac_ext
6031cat >>conftest.$ac_ext <<_ACEOF
6032/* end confdefs.h. */
98418dba 6033#include <math.h>
503d2be0
AS
6034int
6035main ()
6036{
98418dba 6037static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
6038 ;
6039 return 0;
ba4481b5 6040}
503d2be0
AS
6041_ACEOF
6042rm -f conftest.$ac_objext
c0d27fcc 6043if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6044 (eval $ac_compile) 2>&5
503d2be0 6045 ac_status=$?
c0d27fcc 6046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6047 (exit $ac_status); } &&
7c9e5167 6048 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
6050 (eval $ac_try) 2>&5
6051 ac_status=$?
c0d27fcc 6052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6053 (exit $ac_status); }; }; then
98418dba 6054 emacs_cv_struct_exception=yes
ba4481b5 6055else
503d2be0 6056 echo "$as_me: failed program was:" >&5
19650fd6
AS
6057sed 's/^/| /' conftest.$ac_ext >&5
6058
98418dba 6059emacs_cv_struct_exception=no
ba4481b5 6060fi
7c9e5167 6061rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 6062fi
c0d27fcc 6063echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
6064echo "${ECHO_T}$emacs_cv_struct_exception" >&6
6065HAVE_EXCEPTION=$emacs_cv_struct_exception
6066if test $emacs_cv_struct_exception != yes; then
b936fae4 6067
c0d27fcc 6068cat >>confdefs.h <<\_ACEOF
98418dba 6069#define NO_MATHERR 1
c0d27fcc 6070_ACEOF
ba4481b5
DL
6071
6072fi
6073
7862d3a8
AS
6074
6075for ac_header in sys/socket.h
6076do
6077as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6078if eval "test \"\${$as_ac_Header+set}\" = set"; then
6079 echo "$as_me:$LINENO: checking for $ac_header" >&5
6080echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6081if eval "test \"\${$as_ac_Header+set}\" = set"; then
6082 echo $ECHO_N "(cached) $ECHO_C" >&6
6083fi
6084echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6085echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6086else
6087 # Is the header compilable?
6088echo "$as_me:$LINENO: checking $ac_header usability" >&5
6089echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
6090cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6091#line $LINENO "configure"
7862d3a8
AS
6092/* confdefs.h. */
6093_ACEOF
6094cat confdefs.h >>conftest.$ac_ext
6095cat >>conftest.$ac_ext <<_ACEOF
6096/* end confdefs.h. */
6097$ac_includes_default
6098#include <$ac_header>
6099_ACEOF
6100rm -f conftest.$ac_objext
6101if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6102 (eval $ac_compile) 2>&5
7862d3a8 6103 ac_status=$?
7862d3a8
AS
6104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6105 (exit $ac_status); } &&
7c9e5167 6106 { ac_try='test -s conftest.$ac_objext'
7862d3a8
AS
6107 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6108 (eval $ac_try) 2>&5
6109 ac_status=$?
6110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6111 (exit $ac_status); }; }; then
6112 ac_header_compiler=yes
6113else
6114 echo "$as_me: failed program was:" >&5
6115sed 's/^/| /' conftest.$ac_ext >&5
6116
6117ac_header_compiler=no
6118fi
7c9e5167 6119rm -f conftest.$ac_objext conftest.$ac_ext
7862d3a8
AS
6120echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6121echo "${ECHO_T}$ac_header_compiler" >&6
6122
6123# Is the header present?
6124echo "$as_me:$LINENO: checking $ac_header presence" >&5
6125echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
6126cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6127#line $LINENO "configure"
7862d3a8
AS
6128/* confdefs.h. */
6129_ACEOF
6130cat confdefs.h >>conftest.$ac_ext
6131cat >>conftest.$ac_ext <<_ACEOF
6132/* end confdefs.h. */
6133#include <$ac_header>
6134_ACEOF
6135if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
6136 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6137 ac_status=$?
6138 grep -v '^ *+' conftest.er1 >conftest.err
6139 rm -f conftest.er1
6140 cat conftest.err >&5
6141 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6142 (exit $ac_status); } >/dev/null; then
6143 if test -s conftest.err; then
6144 ac_cpp_err=$ac_c_preproc_warn_flag
7862d3a8
AS
6145 else
6146 ac_cpp_err=
6147 fi
6148else
6149 ac_cpp_err=yes
6150fi
6151if test -z "$ac_cpp_err"; then
6152 ac_header_preproc=yes
6153else
6154 echo "$as_me: failed program was:" >&5
6155sed 's/^/| /' conftest.$ac_ext >&5
6156
6157 ac_header_preproc=no
6158fi
6159rm -f conftest.err conftest.$ac_ext
6160echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6161echo "${ECHO_T}$ac_header_preproc" >&6
6162
6163# So? What about this header?
7c9e5167
JD
6164case $ac_header_compiler:$ac_header_preproc in
6165 yes:no )
7862d3a8
AS
6166 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6167echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
6168 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6169echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6170 (
6171 cat <<\_ASBOX
6172## ------------------------------------ ##
6173## Report this to bug-autoconf@gnu.org. ##
6174## ------------------------------------ ##
6175_ASBOX
6176 ) |
6177 sed "s/^/$as_me: WARNING: /" >&2
7862d3a8 6178 ;;
7c9e5167 6179 no:yes )
7862d3a8
AS
6180 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6181echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
6182 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6183echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7862d3a8
AS
6184 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6185echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7862d3a8
AS
6186 (
6187 cat <<\_ASBOX
7c9e5167
JD
6188## ------------------------------------ ##
6189## Report this to bug-autoconf@gnu.org. ##
6190## ------------------------------------ ##
7862d3a8
AS
6191_ASBOX
6192 ) |
6193 sed "s/^/$as_me: WARNING: /" >&2
6194 ;;
6195esac
6196echo "$as_me:$LINENO: checking for $ac_header" >&5
6197echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6198if eval "test \"\${$as_ac_Header+set}\" = set"; then
6199 echo $ECHO_N "(cached) $ECHO_C" >&6
6200else
7c9e5167 6201 eval "$as_ac_Header=$ac_header_preproc"
7862d3a8
AS
6202fi
6203echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6204echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6205
6206fi
6207if test `eval echo '${'$as_ac_Header'}'` = yes; then
6208 cat >>confdefs.h <<_ACEOF
6209#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6210_ACEOF
6211
6212fi
6213
6214done
6215
6216
6217for ac_header in net/if.h
6218do
6219as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6220echo "$as_me:$LINENO: checking for $ac_header" >&5
6221echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6222if eval "test \"\${$as_ac_Header+set}\" = set"; then
6223 echo $ECHO_N "(cached) $ECHO_C" >&6
6224else
6225 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6226#line $LINENO "configure"
7862d3a8
AS
6227/* confdefs.h. */
6228_ACEOF
6229cat confdefs.h >>conftest.$ac_ext
6230cat >>conftest.$ac_ext <<_ACEOF
6231/* end confdefs.h. */
6232$ac_includes_default
6233#if HAVE_SYS_SOCKET_H
6234#include <sys/socket.h>
6235#endif
6236
6237#include <$ac_header>
6238_ACEOF
6239rm -f conftest.$ac_objext
6240if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6241 (eval $ac_compile) 2>&5
7862d3a8 6242 ac_status=$?
7862d3a8
AS
6243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6244 (exit $ac_status); } &&
7c9e5167 6245 { ac_try='test -s conftest.$ac_objext'
7862d3a8
AS
6246 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6247 (eval $ac_try) 2>&5
6248 ac_status=$?
6249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6250 (exit $ac_status); }; }; then
6251 eval "$as_ac_Header=yes"
6252else
6253 echo "$as_me: failed program was:" >&5
6254sed 's/^/| /' conftest.$ac_ext >&5
6255
6256eval "$as_ac_Header=no"
6257fi
7c9e5167 6258rm -f conftest.$ac_objext conftest.$ac_ext
7862d3a8
AS
6259fi
6260echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
6261echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6262if test `eval echo '${'$as_ac_Header'}'` = yes; then
6263 cat >>confdefs.h <<_ACEOF
6264#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6265_ACEOF
6266
6267fi
6268
6269done
6270
6271
c0d27fcc 6272echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
6273echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
6274if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 6275 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 6276else
503d2be0 6277 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6278#line $LINENO "configure"
19650fd6
AS
6279/* confdefs.h. */
6280_ACEOF
6281cat confdefs.h >>conftest.$ac_ext
6282cat >>conftest.$ac_ext <<_ACEOF
6283/* end confdefs.h. */
98418dba
CW
6284#include <sys/types.h>
6285#include <time.h>
7397acc4 6286
503d2be0
AS
6287int
6288main ()
6289{
98418dba 6290struct tm *tp; tp->tm_sec;
503d2be0
AS
6291 ;
6292 return 0;
6293}
6294_ACEOF
6295rm -f conftest.$ac_objext
c0d27fcc 6296if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6297 (eval $ac_compile) 2>&5
503d2be0 6298 ac_status=$?
c0d27fcc 6299 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 6300 (exit $ac_status); } &&
7c9e5167 6301 { ac_try='test -s conftest.$ac_objext'
35996d22
AS
6302 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6303 (eval $ac_try) 2>&5
6304 ac_status=$?
6305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6306 (exit $ac_status); }; }; then
6307 ac_cv_struct_tm=time.h
6308else
503d2be0 6309 echo "$as_me: failed program was:" >&5
19650fd6
AS
6310sed 's/^/| /' conftest.$ac_ext >&5
6311
98418dba 6312ac_cv_struct_tm=sys/time.h
7397acc4 6313fi
7c9e5167 6314rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 6315fi
c0d27fcc 6316echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
6317echo "${ECHO_T}$ac_cv_struct_tm" >&6
6318if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 6319
c0d27fcc 6320cat >>confdefs.h <<\_ACEOF
98418dba 6321#define TM_IN_SYS_TIME 1
c0d27fcc 6322_ACEOF
7397acc4
DL
6323
6324fi
ba4481b5 6325
c0d27fcc 6326echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
6327echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
6328if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 6329 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6330else
98418dba 6331 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6332#line $LINENO "configure"
19650fd6
AS
6333/* confdefs.h. */
6334_ACEOF
6335cat confdefs.h >>conftest.$ac_ext
6336cat >>conftest.$ac_ext <<_ACEOF
6337/* end confdefs.h. */
98418dba
CW
6338#include <sys/types.h>
6339#include <$ac_cv_struct_tm>
ba4481b5 6340
c0d27fcc 6341
98418dba
CW
6342int
6343main ()
6344{
6345static struct tm ac_aggr;
6346if (ac_aggr.tm_zone)
6347return 0;
6348 ;
6349 return 0;
6350}
6351_ACEOF
6352rm -f conftest.$ac_objext
c0d27fcc 6353if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6354 (eval $ac_compile) 2>&5
98418dba 6355 ac_status=$?
c0d27fcc 6356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6357 (exit $ac_status); } &&
7c9e5167 6358 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6360 (eval $ac_try) 2>&5
6361 ac_status=$?
c0d27fcc 6362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6363 (exit $ac_status); }; }; then
6364 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6365else
98418dba 6366 echo "$as_me: failed program was:" >&5
19650fd6
AS
6367sed 's/^/| /' conftest.$ac_ext >&5
6368
6bae0ccf 6369cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6370#line $LINENO "configure"
19650fd6
AS
6371/* confdefs.h. */
6372_ACEOF
6373cat confdefs.h >>conftest.$ac_ext
6374cat >>conftest.$ac_ext <<_ACEOF
6375/* end confdefs.h. */
6bae0ccf
DL
6376#include <sys/types.h>
6377#include <$ac_cv_struct_tm>
6378
6379
6380int
6381main ()
6382{
6383static struct tm ac_aggr;
6384if (sizeof ac_aggr.tm_zone)
6385return 0;
6386 ;
6387 return 0;
6388}
6389_ACEOF
6390rm -f conftest.$ac_objext
6391if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6392 (eval $ac_compile) 2>&5
6bae0ccf
DL
6393 ac_status=$?
6394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6395 (exit $ac_status); } &&
7c9e5167 6396 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
6397 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6398 (eval $ac_try) 2>&5
6399 ac_status=$?
6400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6401 (exit $ac_status); }; }; then
6402 ac_cv_member_struct_tm_tm_zone=yes
6403else
6404 echo "$as_me: failed program was:" >&5
19650fd6
AS
6405sed 's/^/| /' conftest.$ac_ext >&5
6406
98418dba 6407ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6408fi
7c9e5167 6409rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 6410fi
7c9e5167 6411rm -f conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6412fi
c0d27fcc 6413echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6414echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6415if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6416
c0d27fcc 6417cat >>confdefs.h <<_ACEOF
98418dba 6418#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6419_ACEOF
6420
ba4481b5 6421
98418dba 6422fi
ba4481b5 6423
98418dba 6424if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6425
c0d27fcc 6426cat >>confdefs.h <<\_ACEOF
98418dba 6427#define HAVE_TM_ZONE 1
c0d27fcc 6428_ACEOF
ba4481b5 6429
ba4481b5 6430else
c0d27fcc 6431 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6432echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6433if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6434 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6435else
98418dba 6436 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6437#line $LINENO "configure"
19650fd6
AS
6438/* confdefs.h. */
6439_ACEOF
6440cat confdefs.h >>conftest.$ac_ext
6441cat >>conftest.$ac_ext <<_ACEOF
6442/* end confdefs.h. */
98418dba
CW
6443#include <time.h>
6444#ifndef tzname /* For SGI. */
6445extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6446#endif
6447
98418dba
CW
6448int
6449main ()
6450{
6451atoi(*tzname);
6452 ;
6453 return 0;
6454}
6455_ACEOF
6456rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6457if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 6458 (eval $ac_link) 2>&5
98418dba 6459 ac_status=$?
c0d27fcc 6460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6461 (exit $ac_status); } &&
7c9e5167 6462 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6463 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6464 (eval $ac_try) 2>&5
6465 ac_status=$?
c0d27fcc 6466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6467 (exit $ac_status); }; }; then
6468 ac_cv_var_tzname=yes
6469else
6470 echo "$as_me: failed program was:" >&5
19650fd6
AS
6471sed 's/^/| /' conftest.$ac_ext >&5
6472
98418dba 6473ac_cv_var_tzname=no
ba4481b5 6474fi
7c9e5167 6475rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 6476fi
c0d27fcc 6477echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6478echo "${ECHO_T}$ac_cv_var_tzname" >&6
6479 if test $ac_cv_var_tzname = yes; then
ba4481b5 6480
c0d27fcc 6481cat >>confdefs.h <<\_ACEOF
98418dba 6482#define HAVE_TZNAME 1
c0d27fcc 6483_ACEOF
503d2be0 6484
98418dba
CW
6485 fi
6486fi
503d2be0 6487
c0d27fcc 6488echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6489echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6490if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6491 echo $ECHO_N "(cached) $ECHO_C" >&6
6492else
6493 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6494#line $LINENO "configure"
19650fd6
AS
6495/* confdefs.h. */
6496_ACEOF
6497cat confdefs.h >>conftest.$ac_ext
6498cat >>conftest.$ac_ext <<_ACEOF
6499/* end confdefs.h. */
98418dba 6500#include <time.h>
b936fae4 6501
98418dba
CW
6502int
6503main ()
6504{
b936fae4
AS
6505static struct tm ac_aggr;
6506if (ac_aggr.tm_gmtoff)
6507return 0;
98418dba
CW
6508 ;
6509 return 0;
6510}
6511_ACEOF
b936fae4 6512rm -f conftest.$ac_objext
c0d27fcc 6513if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6514 (eval $ac_compile) 2>&5
98418dba 6515 ac_status=$?
c0d27fcc 6516 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6517 (exit $ac_status); } &&
7c9e5167 6518 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6519 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6520 (eval $ac_try) 2>&5
6521 ac_status=$?
c0d27fcc 6522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6523 (exit $ac_status); }; }; then
b936fae4 6524 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6525else
6526 echo "$as_me: failed program was:" >&5
19650fd6
AS
6527sed 's/^/| /' conftest.$ac_ext >&5
6528
8799b3e4 6529cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6530#line $LINENO "configure"
19650fd6
AS
6531/* confdefs.h. */
6532_ACEOF
6533cat confdefs.h >>conftest.$ac_ext
6534cat >>conftest.$ac_ext <<_ACEOF
6535/* end confdefs.h. */
6bae0ccf
DL
6536#include <time.h>
6537
8799b3e4
CW
6538int
6539main ()
6540{
6bae0ccf
DL
6541static struct tm ac_aggr;
6542if (sizeof ac_aggr.tm_gmtoff)
6543return 0;
8799b3e4
CW
6544 ;
6545 return 0;
6546}
6547_ACEOF
6bae0ccf 6548rm -f conftest.$ac_objext
c0d27fcc 6549if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6550 (eval $ac_compile) 2>&5
8799b3e4 6551 ac_status=$?
c0d27fcc 6552 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6553 (exit $ac_status); } &&
7c9e5167 6554 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6555 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6556 (eval $ac_try) 2>&5
6557 ac_status=$?
c0d27fcc 6558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6559 (exit $ac_status); }; }; then
6bae0ccf 6560 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6561else
6562 echo "$as_me: failed program was:" >&5
19650fd6
AS
6563sed 's/^/| /' conftest.$ac_ext >&5
6564
6bae0ccf 6565ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6566fi
7c9e5167 6567rm -f conftest.$ac_objext conftest.$ac_ext
6bae0ccf 6568fi
7c9e5167 6569rm -f conftest.$ac_objext conftest.$ac_ext
8799b3e4 6570fi
6bae0ccf
DL
6571echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6572echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6573if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6574
6575cat >>confdefs.h <<\_ACEOF
6576#define HAVE_TM_GMTOFF 1
6577_ACEOF
6578
6579fi
6580
96f3a036
DL
6581echo "$as_me:$LINENO: checking for struct ifreq.ifr_flags" >&5
6582echo $ECHO_N "checking for struct ifreq.ifr_flags... $ECHO_C" >&6
6583if test "${ac_cv_member_struct_ifreq_ifr_flags+set}" = set; then
6584 echo $ECHO_N "(cached) $ECHO_C" >&6
6585else
6586 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6587#line $LINENO "configure"
96f3a036
DL
6588/* confdefs.h. */
6589_ACEOF
6590cat confdefs.h >>conftest.$ac_ext
6591cat >>conftest.$ac_ext <<_ACEOF
6592/* end confdefs.h. */
7862d3a8
AS
6593$ac_includes_default
6594#if HAVE_SYS_SOCKET_H
6595#include <sys/socket.h>
6596#endif
6597#if HAVE_NET_IF_H
96f3a036 6598#include <net/if.h>
7862d3a8 6599#endif
96f3a036
DL
6600
6601int
6602main ()
6603{
6604static struct ifreq ac_aggr;
6605if (ac_aggr.ifr_flags)
6606return 0;
6607 ;
6608 return 0;
6609}
6610_ACEOF
6611rm -f conftest.$ac_objext
6612if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6613 (eval $ac_compile) 2>&5
96f3a036
DL
6614 ac_status=$?
6615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6616 (exit $ac_status); } &&
7c9e5167 6617 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6618 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6619 (eval $ac_try) 2>&5
6620 ac_status=$?
6621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6622 (exit $ac_status); }; }; then
6623 ac_cv_member_struct_ifreq_ifr_flags=yes
6624else
6625 echo "$as_me: failed program was:" >&5
6626sed 's/^/| /' conftest.$ac_ext >&5
6627
6628cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6629#line $LINENO "configure"
96f3a036
DL
6630/* confdefs.h. */
6631_ACEOF
6632cat confdefs.h >>conftest.$ac_ext
6633cat >>conftest.$ac_ext <<_ACEOF
6634/* end confdefs.h. */
7862d3a8
AS
6635$ac_includes_default
6636#if HAVE_SYS_SOCKET_H
6637#include <sys/socket.h>
6638#endif
6639#if HAVE_NET_IF_H
96f3a036 6640#include <net/if.h>
7862d3a8 6641#endif
96f3a036
DL
6642
6643int
6644main ()
6645{
6646static struct ifreq ac_aggr;
6647if (sizeof ac_aggr.ifr_flags)
6648return 0;
6649 ;
6650 return 0;
6651}
6652_ACEOF
6653rm -f conftest.$ac_objext
6654if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6655 (eval $ac_compile) 2>&5
96f3a036
DL
6656 ac_status=$?
6657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6658 (exit $ac_status); } &&
7c9e5167 6659 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6660 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6661 (eval $ac_try) 2>&5
6662 ac_status=$?
6663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6664 (exit $ac_status); }; }; then
6665 ac_cv_member_struct_ifreq_ifr_flags=yes
6666else
6667 echo "$as_me: failed program was:" >&5
6668sed 's/^/| /' conftest.$ac_ext >&5
6669
6670ac_cv_member_struct_ifreq_ifr_flags=no
6671fi
7c9e5167 6672rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036 6673fi
7c9e5167 6674rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6675fi
6676echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_flags" >&5
6677echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_flags" >&6
6678if test $ac_cv_member_struct_ifreq_ifr_flags = yes; then
6679
6680cat >>confdefs.h <<_ACEOF
6681#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6682_ACEOF
6683
6684
6685fi
6686echo "$as_me:$LINENO: checking for struct ifreq.ifr_hwaddr" >&5
6687echo $ECHO_N "checking for struct ifreq.ifr_hwaddr... $ECHO_C" >&6
6688if test "${ac_cv_member_struct_ifreq_ifr_hwaddr+set}" = set; then
6689 echo $ECHO_N "(cached) $ECHO_C" >&6
6690else
6691 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6692#line $LINENO "configure"
96f3a036
DL
6693/* confdefs.h. */
6694_ACEOF
6695cat confdefs.h >>conftest.$ac_ext
6696cat >>conftest.$ac_ext <<_ACEOF
6697/* end confdefs.h. */
7862d3a8
AS
6698$ac_includes_default
6699#if HAVE_SYS_SOCKET_H
6700#include <sys/socket.h>
6701#endif
6702#if HAVE_NET_IF_H
96f3a036 6703#include <net/if.h>
7862d3a8 6704#endif
96f3a036
DL
6705
6706int
6707main ()
6708{
6709static struct ifreq ac_aggr;
6710if (ac_aggr.ifr_hwaddr)
6711return 0;
6712 ;
6713 return 0;
6714}
6715_ACEOF
6716rm -f conftest.$ac_objext
6717if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6718 (eval $ac_compile) 2>&5
96f3a036
DL
6719 ac_status=$?
6720 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6721 (exit $ac_status); } &&
7c9e5167 6722 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6723 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6724 (eval $ac_try) 2>&5
6725 ac_status=$?
6726 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6727 (exit $ac_status); }; }; then
6728 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
6729else
6730 echo "$as_me: failed program was:" >&5
6731sed 's/^/| /' conftest.$ac_ext >&5
6732
6733cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6734#line $LINENO "configure"
96f3a036
DL
6735/* confdefs.h. */
6736_ACEOF
6737cat confdefs.h >>conftest.$ac_ext
6738cat >>conftest.$ac_ext <<_ACEOF
6739/* end confdefs.h. */
7862d3a8
AS
6740$ac_includes_default
6741#if HAVE_SYS_SOCKET_H
6742#include <sys/socket.h>
6743#endif
6744#if HAVE_NET_IF_H
96f3a036 6745#include <net/if.h>
7862d3a8 6746#endif
96f3a036
DL
6747
6748int
6749main ()
6750{
6751static struct ifreq ac_aggr;
6752if (sizeof ac_aggr.ifr_hwaddr)
6753return 0;
6754 ;
6755 return 0;
6756}
6757_ACEOF
6758rm -f conftest.$ac_objext
6759if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6760 (eval $ac_compile) 2>&5
96f3a036
DL
6761 ac_status=$?
6762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6763 (exit $ac_status); } &&
7c9e5167 6764 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6766 (eval $ac_try) 2>&5
6767 ac_status=$?
6768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6769 (exit $ac_status); }; }; then
6770 ac_cv_member_struct_ifreq_ifr_hwaddr=yes
6771else
6772 echo "$as_me: failed program was:" >&5
6773sed 's/^/| /' conftest.$ac_ext >&5
6774
6775ac_cv_member_struct_ifreq_ifr_hwaddr=no
6776fi
7c9e5167 6777rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036 6778fi
7c9e5167 6779rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6780fi
6781echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_hwaddr" >&5
6782echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_hwaddr" >&6
6783if test $ac_cv_member_struct_ifreq_ifr_hwaddr = yes; then
6784
6785cat >>confdefs.h <<_ACEOF
6786#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
6787_ACEOF
6788
6789
6790fi
6791echo "$as_me:$LINENO: checking for struct ifreq.ifr_netmask" >&5
6792echo $ECHO_N "checking for struct ifreq.ifr_netmask... $ECHO_C" >&6
6793if test "${ac_cv_member_struct_ifreq_ifr_netmask+set}" = set; then
6794 echo $ECHO_N "(cached) $ECHO_C" >&6
6795else
6796 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6797#line $LINENO "configure"
96f3a036
DL
6798/* confdefs.h. */
6799_ACEOF
6800cat confdefs.h >>conftest.$ac_ext
6801cat >>conftest.$ac_ext <<_ACEOF
6802/* end confdefs.h. */
7862d3a8
AS
6803$ac_includes_default
6804#if HAVE_SYS_SOCKET_H
6805#include <sys/socket.h>
6806#endif
6807#if HAVE_NET_IF_H
96f3a036 6808#include <net/if.h>
7862d3a8 6809#endif
96f3a036
DL
6810
6811int
6812main ()
6813{
6814static struct ifreq ac_aggr;
6815if (ac_aggr.ifr_netmask)
6816return 0;
6817 ;
6818 return 0;
6819}
6820_ACEOF
6821rm -f conftest.$ac_objext
6822if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6823 (eval $ac_compile) 2>&5
96f3a036
DL
6824 ac_status=$?
6825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6826 (exit $ac_status); } &&
7c9e5167 6827 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6828 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6829 (eval $ac_try) 2>&5
6830 ac_status=$?
6831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6832 (exit $ac_status); }; }; then
6833 ac_cv_member_struct_ifreq_ifr_netmask=yes
6834else
6835 echo "$as_me: failed program was:" >&5
6836sed 's/^/| /' conftest.$ac_ext >&5
6837
6838cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6839#line $LINENO "configure"
96f3a036
DL
6840/* confdefs.h. */
6841_ACEOF
6842cat confdefs.h >>conftest.$ac_ext
6843cat >>conftest.$ac_ext <<_ACEOF
6844/* end confdefs.h. */
7862d3a8
AS
6845$ac_includes_default
6846#if HAVE_SYS_SOCKET_H
6847#include <sys/socket.h>
6848#endif
6849#if HAVE_NET_IF_H
96f3a036 6850#include <net/if.h>
7862d3a8 6851#endif
96f3a036
DL
6852
6853int
6854main ()
6855{
6856static struct ifreq ac_aggr;
6857if (sizeof ac_aggr.ifr_netmask)
6858return 0;
6859 ;
6860 return 0;
6861}
6862_ACEOF
6863rm -f conftest.$ac_objext
6864if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6865 (eval $ac_compile) 2>&5
96f3a036
DL
6866 ac_status=$?
6867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6868 (exit $ac_status); } &&
7c9e5167 6869 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6870 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6871 (eval $ac_try) 2>&5
6872 ac_status=$?
6873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6874 (exit $ac_status); }; }; then
6875 ac_cv_member_struct_ifreq_ifr_netmask=yes
6876else
6877 echo "$as_me: failed program was:" >&5
6878sed 's/^/| /' conftest.$ac_ext >&5
6879
6880ac_cv_member_struct_ifreq_ifr_netmask=no
6881fi
7c9e5167 6882rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036 6883fi
7c9e5167 6884rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6885fi
6886echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_netmask" >&5
6887echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_netmask" >&6
6888if test $ac_cv_member_struct_ifreq_ifr_netmask = yes; then
6889
6890cat >>confdefs.h <<_ACEOF
6891#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
6892_ACEOF
6893
6894
6895fi
6896echo "$as_me:$LINENO: checking for struct ifreq.ifr_broadaddr" >&5
6897echo $ECHO_N "checking for struct ifreq.ifr_broadaddr... $ECHO_C" >&6
6898if test "${ac_cv_member_struct_ifreq_ifr_broadaddr+set}" = set; then
6899 echo $ECHO_N "(cached) $ECHO_C" >&6
6900else
6901 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6902#line $LINENO "configure"
96f3a036
DL
6903/* confdefs.h. */
6904_ACEOF
6905cat confdefs.h >>conftest.$ac_ext
6906cat >>conftest.$ac_ext <<_ACEOF
6907/* end confdefs.h. */
7862d3a8
AS
6908$ac_includes_default
6909#if HAVE_SYS_SOCKET_H
6910#include <sys/socket.h>
6911#endif
6912#if HAVE_NET_IF_H
96f3a036 6913#include <net/if.h>
7862d3a8 6914#endif
96f3a036
DL
6915
6916int
6917main ()
6918{
6919static struct ifreq ac_aggr;
6920if (ac_aggr.ifr_broadaddr)
6921return 0;
6922 ;
6923 return 0;
6924}
6925_ACEOF
6926rm -f conftest.$ac_objext
6927if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6928 (eval $ac_compile) 2>&5
96f3a036
DL
6929 ac_status=$?
6930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6931 (exit $ac_status); } &&
7c9e5167 6932 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6933 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6934 (eval $ac_try) 2>&5
6935 ac_status=$?
6936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6937 (exit $ac_status); }; }; then
6938 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
6939else
6940 echo "$as_me: failed program was:" >&5
6941sed 's/^/| /' conftest.$ac_ext >&5
6942
6943cat >conftest.$ac_ext <<_ACEOF
7c9e5167 6944#line $LINENO "configure"
96f3a036
DL
6945/* confdefs.h. */
6946_ACEOF
6947cat confdefs.h >>conftest.$ac_ext
6948cat >>conftest.$ac_ext <<_ACEOF
6949/* end confdefs.h. */
7862d3a8
AS
6950$ac_includes_default
6951#if HAVE_SYS_SOCKET_H
6952#include <sys/socket.h>
6953#endif
6954#if HAVE_NET_IF_H
96f3a036 6955#include <net/if.h>
7862d3a8 6956#endif
96f3a036
DL
6957
6958int
6959main ()
6960{
6961static struct ifreq ac_aggr;
6962if (sizeof ac_aggr.ifr_broadaddr)
6963return 0;
6964 ;
6965 return 0;
6966}
6967_ACEOF
6968rm -f conftest.$ac_objext
6969if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 6970 (eval $ac_compile) 2>&5
96f3a036
DL
6971 ac_status=$?
6972 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6973 (exit $ac_status); } &&
7c9e5167 6974 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
6975 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6976 (eval $ac_try) 2>&5
6977 ac_status=$?
6978 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6979 (exit $ac_status); }; }; then
6980 ac_cv_member_struct_ifreq_ifr_broadaddr=yes
6981else
6982 echo "$as_me: failed program was:" >&5
6983sed 's/^/| /' conftest.$ac_ext >&5
6984
6985ac_cv_member_struct_ifreq_ifr_broadaddr=no
6986fi
7c9e5167 6987rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036 6988fi
7c9e5167 6989rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
6990fi
6991echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_broadaddr" >&5
6992echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_broadaddr" >&6
6993if test $ac_cv_member_struct_ifreq_ifr_broadaddr = yes; then
6994
6995cat >>confdefs.h <<_ACEOF
6996#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
6997_ACEOF
6998
6999
7000fi
7001echo "$as_me:$LINENO: checking for struct ifreq.ifr_addr" >&5
7002echo $ECHO_N "checking for struct ifreq.ifr_addr... $ECHO_C" >&6
7003if test "${ac_cv_member_struct_ifreq_ifr_addr+set}" = set; then
7004 echo $ECHO_N "(cached) $ECHO_C" >&6
7005else
7006 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7007#line $LINENO "configure"
96f3a036
DL
7008/* confdefs.h. */
7009_ACEOF
7010cat confdefs.h >>conftest.$ac_ext
7011cat >>conftest.$ac_ext <<_ACEOF
7012/* end confdefs.h. */
7862d3a8
AS
7013$ac_includes_default
7014#if HAVE_SYS_SOCKET_H
7015#include <sys/socket.h>
7016#endif
7017#if HAVE_NET_IF_H
96f3a036 7018#include <net/if.h>
7862d3a8 7019#endif
96f3a036
DL
7020
7021int
7022main ()
7023{
7024static struct ifreq ac_aggr;
7025if (ac_aggr.ifr_addr)
7026return 0;
7027 ;
7028 return 0;
7029}
7030_ACEOF
7031rm -f conftest.$ac_objext
7032if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7033 (eval $ac_compile) 2>&5
96f3a036
DL
7034 ac_status=$?
7035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7036 (exit $ac_status); } &&
7c9e5167 7037 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7038 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7039 (eval $ac_try) 2>&5
7040 ac_status=$?
7041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7042 (exit $ac_status); }; }; then
7043 ac_cv_member_struct_ifreq_ifr_addr=yes
7044else
7045 echo "$as_me: failed program was:" >&5
7046sed 's/^/| /' conftest.$ac_ext >&5
7047
7048cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7049#line $LINENO "configure"
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_addr)
7068return 0;
7069 ;
7070 return 0;
7071}
7072_ACEOF
7073rm -f conftest.$ac_objext
7074if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7075 (eval $ac_compile) 2>&5
96f3a036
DL
7076 ac_status=$?
7077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7078 (exit $ac_status); } &&
7c9e5167 7079 { ac_try='test -s conftest.$ac_objext'
96f3a036
DL
7080 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7081 (eval $ac_try) 2>&5
7082 ac_status=$?
7083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7084 (exit $ac_status); }; }; then
7085 ac_cv_member_struct_ifreq_ifr_addr=yes
7086else
7087 echo "$as_me: failed program was:" >&5
7088sed 's/^/| /' conftest.$ac_ext >&5
7089
7090ac_cv_member_struct_ifreq_ifr_addr=no
7091fi
7c9e5167 7092rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036 7093fi
7c9e5167 7094rm -f conftest.$ac_objext conftest.$ac_ext
96f3a036
DL
7095fi
7096echo "$as_me:$LINENO: result: $ac_cv_member_struct_ifreq_ifr_addr" >&5
7097echo "${ECHO_T}$ac_cv_member_struct_ifreq_ifr_addr" >&6
7098if test $ac_cv_member_struct_ifreq_ifr_addr = yes; then
7099
7100cat >>confdefs.h <<_ACEOF
7101#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
7102_ACEOF
7103
7104
7105fi
7106
8799b3e4 7107
8799b3e4 7108
c0d27fcc 7109echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
7110echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
7111if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 7112 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7113echo "${ECHO_T}yes" >&6
7114
c0d27fcc 7115cat >>confdefs.h <<\_ACEOF
98418dba 7116#define PROTOTYPES 1
c0d27fcc
MR
7117_ACEOF
7118
7119
7120cat >>confdefs.h <<\_ACEOF
7121#define __PROTOTYPES 1
7122_ACEOF
98418dba
CW
7123
7124else
c0d27fcc 7125 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7126echo "${ECHO_T}no" >&6
7127fi
7128
c0d27fcc 7129echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
7130echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
7131if test "${ac_cv_c_volatile+set}" = set; then
7132 echo $ECHO_N "(cached) $ECHO_C" >&6
7133else
7134 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7135#line $LINENO "configure"
19650fd6
AS
7136/* confdefs.h. */
7137_ACEOF
7138cat confdefs.h >>conftest.$ac_ext
7139cat >>conftest.$ac_ext <<_ACEOF
7140/* end confdefs.h. */
98418dba 7141
98418dba
CW
7142int
7143main ()
7144{
7145
7146volatile int x;
7147int * volatile y;
7148 ;
7149 return 0;
7150}
7151_ACEOF
7152rm -f conftest.$ac_objext
c0d27fcc 7153if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7154 (eval $ac_compile) 2>&5
98418dba 7155 ac_status=$?
c0d27fcc 7156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7157 (exit $ac_status); } &&
7c9e5167 7158 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7159 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7160 (eval $ac_try) 2>&5
7161 ac_status=$?
c0d27fcc 7162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7163 (exit $ac_status); }; }; then
7164 ac_cv_c_volatile=yes
7165else
7166 echo "$as_me: failed program was:" >&5
19650fd6
AS
7167sed 's/^/| /' conftest.$ac_ext >&5
7168
98418dba
CW
7169ac_cv_c_volatile=no
7170fi
7c9e5167 7171rm -f conftest.$ac_objext conftest.$ac_ext
98418dba 7172fi
c0d27fcc 7173echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
7174echo "${ECHO_T}$ac_cv_c_volatile" >&6
7175if test $ac_cv_c_volatile = no; then
7176
c0d27fcc 7177cat >>confdefs.h <<\_ACEOF
98418dba 7178#define volatile
c0d27fcc 7179_ACEOF
98418dba
CW
7180
7181fi
7182
c0d27fcc 7183echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
7184echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
7185if test "${ac_cv_c_const+set}" = set; then
7186 echo $ECHO_N "(cached) $ECHO_C" >&6
7187else
7188 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7189#line $LINENO "configure"
19650fd6
AS
7190/* confdefs.h. */
7191_ACEOF
7192cat confdefs.h >>conftest.$ac_ext
7193cat >>conftest.$ac_ext <<_ACEOF
7194/* end confdefs.h. */
98418dba 7195
98418dba
CW
7196int
7197main ()
7198{
7199/* FIXME: Include the comments suggested by Paul. */
7200#ifndef __cplusplus
7201 /* Ultrix mips cc rejects this. */
7202 typedef int charset[2];
7203 const charset x;
7204 /* SunOS 4.1.1 cc rejects this. */
7205 char const *const *ccp;
7206 char **p;
7207 /* NEC SVR4.0.2 mips cc rejects this. */
7208 struct point {int x, y;};
7209 static struct point const zero = {0,0};
7210 /* AIX XL C 1.02.0.0 rejects this.
7211 It does not let you subtract one const X* pointer from another in
7212 an arm of an if-expression whose if-part is not a constant
7213 expression */
7214 const char *g = "string";
7215 ccp = &g + (g ? g-g : 0);
7216 /* HPUX 7.0 cc rejects these. */
7217 ++ccp;
7218 p = (char**) ccp;
7219 ccp = (char const *const *) p;
7220 { /* SCO 3.2v4 cc rejects this. */
7221 char *t;
7222 char const *s = 0 ? (char *) 0 : (char const *) 0;
7223
7224 *t++ = 0;
7225 }
7226 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7227 int x[] = {25, 17};
7228 const int *foo = &x[0];
7229 ++foo;
7230 }
7231 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7232 typedef const int *iptr;
7233 iptr p = 0;
7234 ++p;
7235 }
7236 { /* AIX XL C 1.02.0.0 rejects this saying
7237 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7238 struct s { int j; const int *ap[3]; };
7239 struct s *b; b->j = 5;
7240 }
7241 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7242 const int foo = 10;
7243 }
7244#endif
7245
7246 ;
7247 return 0;
7248}
7249_ACEOF
7250rm -f conftest.$ac_objext
c0d27fcc 7251if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7252 (eval $ac_compile) 2>&5
98418dba 7253 ac_status=$?
c0d27fcc 7254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7255 (exit $ac_status); } &&
7c9e5167 7256 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7257 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7258 (eval $ac_try) 2>&5
7259 ac_status=$?
c0d27fcc 7260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7261 (exit $ac_status); }; }; then
7262 ac_cv_c_const=yes
7263else
7264 echo "$as_me: failed program was:" >&5
19650fd6
AS
7265sed 's/^/| /' conftest.$ac_ext >&5
7266
98418dba
CW
7267ac_cv_c_const=no
7268fi
7c9e5167 7269rm -f conftest.$ac_objext conftest.$ac_ext
98418dba 7270fi
c0d27fcc 7271echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
7272echo "${ECHO_T}$ac_cv_c_const" >&6
7273if test $ac_cv_c_const = no; then
7274
c0d27fcc 7275cat >>confdefs.h <<\_ACEOF
98418dba 7276#define const
c0d27fcc 7277_ACEOF
98418dba
CW
7278
7279fi
7280
c0d27fcc 7281echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
7282echo $ECHO_N "checking for void * support... $ECHO_C" >&6
7283if test "${emacs_cv_void_star+set}" = set; then
7284 echo $ECHO_N "(cached) $ECHO_C" >&6
7285else
7286 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7287#line $LINENO "configure"
19650fd6
AS
7288/* confdefs.h. */
7289_ACEOF
7290cat confdefs.h >>conftest.$ac_ext
7291cat >>conftest.$ac_ext <<_ACEOF
7292/* end confdefs.h. */
98418dba 7293
98418dba
CW
7294int
7295main ()
7296{
7297void * foo;
7298 ;
7299 return 0;
7300}
7301_ACEOF
7302rm -f conftest.$ac_objext
c0d27fcc 7303if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7304 (eval $ac_compile) 2>&5
98418dba 7305 ac_status=$?
c0d27fcc 7306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7307 (exit $ac_status); } &&
7c9e5167 7308 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7309 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7310 (eval $ac_try) 2>&5
7311 ac_status=$?
c0d27fcc 7312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7313 (exit $ac_status); }; }; then
7314 emacs_cv_void_star=yes
7315else
7316 echo "$as_me: failed program was:" >&5
19650fd6
AS
7317sed 's/^/| /' conftest.$ac_ext >&5
7318
98418dba
CW
7319emacs_cv_void_star=no
7320fi
7c9e5167 7321rm -f conftest.$ac_objext conftest.$ac_ext
98418dba 7322fi
c0d27fcc 7323echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
7324echo "${ECHO_T}$emacs_cv_void_star" >&6
7325if test $emacs_cv_void_star = yes; then
c0d27fcc 7326 cat >>confdefs.h <<\_ACEOF
98418dba 7327#define POINTER_TYPE void
c0d27fcc 7328_ACEOF
98418dba
CW
7329
7330else
c0d27fcc 7331 cat >>confdefs.h <<\_ACEOF
98418dba 7332#define POINTER_TYPE char
c0d27fcc 7333_ACEOF
98418dba
CW
7334
7335fi
7336
c0d27fcc 7337
4494a266
JD
7338
7339
cd958eb3 7340
19650fd6
AS
7341echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7342echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
7c9e5167 7343set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
98418dba
CW
7344if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
7345 echo $ECHO_N "(cached) $ECHO_C" >&6
7346else
c0d27fcc 7347 cat >conftest.make <<\_ACEOF
98418dba 7348all:
19650fd6 7349 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 7350_ACEOF
98418dba
CW
7351# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7352eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
7353if test -n "$ac_maketemp"; then
7354 eval ac_cv_prog_make_${ac_make}_set=yes
7355else
7356 eval ac_cv_prog_make_${ac_make}_set=no
7357fi
7358rm -f conftest.make
7359fi
7360if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 7361 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7362echo "${ECHO_T}yes" >&6
7363 SET_MAKE=
7364else
c0d27fcc 7365 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7366echo "${ECHO_T}no" >&6
7367 SET_MAKE="MAKE=${MAKE-make}"
7368fi
7369
c0d27fcc
MR
7370
7371echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
7372echo $ECHO_N "checking for long file names... $ECHO_C" >&6
7373if test "${ac_cv_sys_long_file_names+set}" = set; then
7374 echo $ECHO_N "(cached) $ECHO_C" >&6
7375else
7376 ac_cv_sys_long_file_names=yes
7377# Test for long file names in all the places we know might matter:
7378# . the current directory, where building will happen
7379# $prefix/lib where we will be installing things
7380# $exec_prefix/lib likewise
7381# eval it to expand exec_prefix.
7382# $TMPDIR if set, where it might want to write temporary files
7383# if $TMPDIR is not set:
7384# /tmp where it might want to write temporary files
7385# /var/tmp likewise
7386# /usr/tmp likewise
7387if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
7388 ac_tmpdirs=$TMPDIR
7389else
7390 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
7391fi
7392for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
7393 test -d $ac_dir || continue
7394 test -w $ac_dir || continue # It is less confusing to not echo anything here.
7395 ac_xdir=$ac_dir/cf$$
7396 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
7397 ac_tf1=$ac_xdir/conftest9012345
7398 ac_tf2=$ac_xdir/conftest9012346
7399 (echo 1 >$ac_tf1) 2>/dev/null
7400 (echo 2 >$ac_tf2) 2>/dev/null
7401 ac_val=`cat $ac_tf1 2>/dev/null`
7402 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
7403 ac_cv_sys_long_file_names=no
7404 rm -rf $ac_xdir 2>/dev/null
7405 break
7406 fi
7407 rm -rf $ac_xdir 2>/dev/null
7408done
7409fi
c0d27fcc 7410echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
7411echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
7412if test $ac_cv_sys_long_file_names = yes; then
7413
c0d27fcc 7414cat >>confdefs.h <<\_ACEOF
98418dba 7415#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 7416_ACEOF
98418dba
CW
7417
7418fi
7419
c0d27fcc 7420
98418dba
CW
7421#### Choose a window system.
7422
c0d27fcc 7423echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
7424echo $ECHO_N "checking for X... $ECHO_C" >&6
7425
c0d27fcc 7426
98418dba
CW
7427# Check whether --with-x or --without-x was given.
7428if test "${with_x+set}" = set; then
7429 withval="$with_x"
7430
7431fi;
7432# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7433if test "x$with_x" = xno; then
7434 # The user explicitly disabled X.
7435 have_x=disabled
7436else
7437 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7438 # Both variables are already set.
7439 have_x=yes
7440 else
7441 if test "${ac_cv_have_x+set}" = set; then
7442 echo $ECHO_N "(cached) $ECHO_C" >&6
7443else
7444 # One or both of the vars are not set, and there is no cached value.
7445ac_x_includes=no ac_x_libraries=no
7446rm -fr conftest.dir
7447if mkdir conftest.dir; then
7448 cd conftest.dir
7449 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 7450 cat >Imakefile <<'_ACEOF'
98418dba
CW
7451acfindx:
7452 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 7453_ACEOF
98418dba
CW
7454 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7455 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7456 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7457 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7458 for ac_extension in a so sl; do
7459 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
7c9e5167
JD
7460 test -f $ac_im_libdir/libX11.$ac_extension; then
7461 ac_im_usrlibdir=$ac_im_libdir; break
98418dba
CW
7462 fi
7463 done
7464 # Screen out bogus values from the imake configuration. They are
7465 # bogus both because they are the default anyway, and because
7466 # using them would break gcc on systems where it needs fixed includes.
7467 case $ac_im_incroot in
7468 /usr/include) ;;
7469 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7470 esac
7471 case $ac_im_usrlibdir in
7472 /usr/lib | /lib) ;;
7473 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7474 esac
7475 fi
7476 cd ..
7477 rm -fr conftest.dir
7478fi
7479
7480# Standard set of common directories for X headers.
7481# Check X11 before X11Rn because it is often a symlink to the current release.
7482ac_x_header_dirs='
7483/usr/X11/include
7484/usr/X11R6/include
7485/usr/X11R5/include
7486/usr/X11R4/include
7487
7488/usr/include/X11
7489/usr/include/X11R6
7490/usr/include/X11R5
7491/usr/include/X11R4
7492
7493/usr/local/X11/include
7494/usr/local/X11R6/include
7495/usr/local/X11R5/include
7496/usr/local/X11R4/include
7497
7498/usr/local/include/X11
7499/usr/local/include/X11R6
7500/usr/local/include/X11R5
7501/usr/local/include/X11R4
7502
7503/usr/X386/include
7504/usr/x386/include
7505/usr/XFree86/include/X11
7506
7507/usr/include
7508/usr/local/include
7509/usr/unsupported/include
7510/usr/athena/include
7511/usr/local/x11r5/include
7512/usr/lpp/Xamples/include
7513
7514/usr/openwin/include
7515/usr/openwin/share/include'
7516
7517if test "$ac_x_includes" = no; then
7c9e5167 7518 # Guess where to find include files, by looking for Intrinsic.h.
98418dba
CW
7519 # First, try using that file with no special directory specified.
7520 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7521#line $LINENO "configure"
19650fd6
AS
7522/* confdefs.h. */
7523_ACEOF
7524cat confdefs.h >>conftest.$ac_ext
7525cat >>conftest.$ac_ext <<_ACEOF
7526/* end confdefs.h. */
98418dba
CW
7527#include <X11/Intrinsic.h>
7528_ACEOF
c0d27fcc 7529if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
7530 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7531 ac_status=$?
6bae0ccf 7532 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
7533 rm -f conftest.er1
7534 cat conftest.err >&5
c0d27fcc 7535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7536 (exit $ac_status); } >/dev/null; then
7537 if test -s conftest.err; then
7538 ac_cpp_err=$ac_c_preproc_warn_flag
7539 else
7540 ac_cpp_err=
7541 fi
7542else
7543 ac_cpp_err=yes
7544fi
7545if test -z "$ac_cpp_err"; then
7546 # We can compile using X headers with no special include directory.
7547ac_x_includes=
7548else
7549 echo "$as_me: failed program was:" >&5
19650fd6
AS
7550sed 's/^/| /' conftest.$ac_ext >&5
7551
98418dba
CW
7552 for ac_dir in $ac_x_header_dirs; do
7553 if test -r "$ac_dir/X11/Intrinsic.h"; then
7554 ac_x_includes=$ac_dir
7555 break
7556 fi
7557done
7558fi
7559rm -f conftest.err conftest.$ac_ext
7560fi # $ac_x_includes = no
7561
7562if test "$ac_x_libraries" = no; then
7563 # Check for the libraries.
7564 # See if we find them without any special options.
7565 # Don't add to $LIBS permanently.
7566 ac_save_LIBS=$LIBS
7567 LIBS="-lXt $LIBS"
7568 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7569#line $LINENO "configure"
19650fd6
AS
7570/* confdefs.h. */
7571_ACEOF
7572cat confdefs.h >>conftest.$ac_ext
7573cat >>conftest.$ac_ext <<_ACEOF
7574/* end confdefs.h. */
98418dba 7575#include <X11/Intrinsic.h>
98418dba
CW
7576int
7577main ()
7578{
7579XtMalloc (0)
7580 ;
7581 return 0;
7582}
7583_ACEOF
7584rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7585if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 7586 (eval $ac_link) 2>&5
98418dba 7587 ac_status=$?
c0d27fcc 7588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7589 (exit $ac_status); } &&
7c9e5167 7590 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7591 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7592 (eval $ac_try) 2>&5
7593 ac_status=$?
c0d27fcc 7594 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7595 (exit $ac_status); }; }; then
7596 LIBS=$ac_save_LIBS
7597# We can link X programs with no special library path.
7598ac_x_libraries=
7599else
7600 echo "$as_me: failed program was:" >&5
19650fd6
AS
7601sed 's/^/| /' conftest.$ac_ext >&5
7602
98418dba
CW
7603LIBS=$ac_save_LIBS
7604for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7605do
7606 # Don't even attempt the hair of trying to link an X program!
7607 for ac_extension in a so sl; do
7608 if test -r $ac_dir/libXt.$ac_extension; then
7609 ac_x_libraries=$ac_dir
7610 break 2
7611 fi
7612 done
7613done
7614fi
7c9e5167 7615rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
7616fi # $ac_x_libraries = no
7617
7618if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
7619 # Didn't find X anywhere. Cache the known absence of X.
7620 ac_cv_have_x="have_x=no"
7621else
7622 # Record where we found X for the cache.
7623 ac_cv_have_x="have_x=yes \
7c9e5167 7624 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
98418dba
CW
7625fi
7626fi
7627
7628 fi
7629 eval "$ac_cv_have_x"
7630fi # $with_x != no
7631
7632if test "$have_x" != yes; then
c0d27fcc 7633 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
7634echo "${ECHO_T}$have_x" >&6
7635 no_x=yes
7636else
7637 # If each of the values was on the command line, it overrides each guess.
7638 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
7639 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
7640 # Update the cache value to reflect the command line values.
7641 ac_cv_have_x="have_x=yes \
7642 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
7c9e5167
JD
7643 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
7644echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
98418dba
CW
7645fi
7646
7647if test "$no_x" = yes; then
7648 window_system=none
7649else
7650 window_system=x11
7651fi
7652
7653if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
7654 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
7655 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
7656 x_default_search_path=""
7657 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
7658 x_search_path="\
7659${x_library}/X11/%L/%T/%N%C%S:\
7660${x_library}/X11/%l/%T/%N%C%S:\
7661${x_library}/X11/%T/%N%C%S:\
7662${x_library}/X11/%L/%T/%N%S:\
7663${x_library}/X11/%l/%T/%N%S:\
7664${x_library}/X11/%T/%N%S"
7665 if test x"${x_default_search_path}" = x; then
7666 x_default_search_path=${x_search_path}
7667 else
7668 x_default_search_path="${x_search_path}:${x_default_search_path}"
7669 fi
7670 done
7671fi
7672if test "${x_includes}" != NONE && test -n "${x_includes}"; then
7673 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
7674fi
7675
7676if test x"${x_includes}" = x; then
7677 bitmapdir=/usr/include/X11/bitmaps
7678else
7679 # accumulate include directories that have X11 bitmap subdirectories
7680 bmd_acc="dummyval"
7681 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
7682 if test -d "${bmd}/X11/bitmaps"; then
7683 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
7684 fi
7685 if test -d "${bmd}/bitmaps"; then
7686 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
7687 fi
7688 done
7689 if test ${bmd_acc} != "dummyval"; then
7690 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
7691 fi
7692fi
7693
7694case "${window_system}" in
7695 x11 )
7696 HAVE_X_WINDOWS=yes
7697 HAVE_X11=yes
7698 case "${with_x_toolkit}" in
7699 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
7700 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
7701 gtk ) with_gtk=yes
7702 USE_X_TOOLKIT=none ;;
98418dba
CW
7703 no ) USE_X_TOOLKIT=none ;;
7704 * ) USE_X_TOOLKIT=maybe ;;
7705 esac
7706 ;;
7707 none )
7708 HAVE_X_WINDOWS=no
7709 HAVE_X11=no
7710 USE_X_TOOLKIT=none
7711 ;;
7712esac
7713
7714### If we're using X11, we should use the X menu package.
7715HAVE_MENUS=no
7716case ${HAVE_X11} in
7717 yes ) HAVE_MENUS=yes ;;
7718esac
7719
7720if test "${opsys}" = "hpux9"; then
7721 case "${x_libraries}" in
7722 *X11R4* )
7723 opsysfile="s/hpux9-x11r4.h"
7724 ;;
7725 esac
7726fi
7727
7728if test "${opsys}" = "hpux9shr"; then
7729 case "${x_libraries}" in
7730 *X11R4* )
7731 opsysfile="s/hpux9shxr4.h"
7732 ;;
7733 esac
7734fi
7735
5d6da11e
YM
7736HAVE_CARBON=no
7737if test "${HAVE_X11}" != "yes"; then
7738 if test "${with_carbon}" != "no"; then
7739 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
7740 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
7741echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
7742if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
7743 echo $ECHO_N "(cached) $ECHO_C" >&6
7744fi
7745echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
7746echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
7747else
7748 # Is the header compilable?
7749echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
7750echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
7751cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7752#line $LINENO "configure"
5d6da11e
YM
7753/* confdefs.h. */
7754_ACEOF
7755cat confdefs.h >>conftest.$ac_ext
7756cat >>conftest.$ac_ext <<_ACEOF
7757/* end confdefs.h. */
7758$ac_includes_default
7759#include <Carbon/Carbon.h>
7760_ACEOF
7761rm -f conftest.$ac_objext
7762if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 7763 (eval $ac_compile) 2>&5
5d6da11e 7764 ac_status=$?
5d6da11e
YM
7765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7766 (exit $ac_status); } &&
7c9e5167 7767 { ac_try='test -s conftest.$ac_objext'
5d6da11e
YM
7768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7769 (eval $ac_try) 2>&5
7770 ac_status=$?
7771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7772 (exit $ac_status); }; }; then
7773 ac_header_compiler=yes
7774else
7775 echo "$as_me: failed program was:" >&5
7776sed 's/^/| /' conftest.$ac_ext >&5
7777
7778ac_header_compiler=no
7779fi
7c9e5167 7780rm -f conftest.$ac_objext conftest.$ac_ext
5d6da11e
YM
7781echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7782echo "${ECHO_T}$ac_header_compiler" >&6
7783
7784# Is the header present?
7785echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
7786echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
7787cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7788#line $LINENO "configure"
5d6da11e
YM
7789/* confdefs.h. */
7790_ACEOF
7791cat confdefs.h >>conftest.$ac_ext
7792cat >>conftest.$ac_ext <<_ACEOF
7793/* end confdefs.h. */
7794#include <Carbon/Carbon.h>
7795_ACEOF
7796if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7797 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7798 ac_status=$?
7799 grep -v '^ *+' conftest.er1 >conftest.err
7800 rm -f conftest.er1
7801 cat conftest.err >&5
7802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7803 (exit $ac_status); } >/dev/null; then
7804 if test -s conftest.err; then
7805 ac_cpp_err=$ac_c_preproc_warn_flag
5d6da11e
YM
7806 else
7807 ac_cpp_err=
7808 fi
7809else
7810 ac_cpp_err=yes
7811fi
7812if test -z "$ac_cpp_err"; then
7813 ac_header_preproc=yes
7814else
7815 echo "$as_me: failed program was:" >&5
7816sed 's/^/| /' conftest.$ac_ext >&5
7817
7818 ac_header_preproc=no
7819fi
7820rm -f conftest.err conftest.$ac_ext
7821echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7822echo "${ECHO_T}$ac_header_preproc" >&6
7823
7824# So? What about this header?
7c9e5167
JD
7825case $ac_header_compiler:$ac_header_preproc in
7826 yes:no )
5d6da11e
YM
7827 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
7828echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
7829 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
7830echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
7831 (
7832 cat <<\_ASBOX
7833## ------------------------------------ ##
7834## Report this to bug-autoconf@gnu.org. ##
7835## ------------------------------------ ##
7836_ASBOX
7837 ) |
7838 sed "s/^/$as_me: WARNING: /" >&2
5d6da11e 7839 ;;
7c9e5167 7840 no:yes )
5d6da11e
YM
7841 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
7842echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
7c9e5167
JD
7843 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
7844echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
5d6da11e
YM
7845 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
7846echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
5d6da11e
YM
7847 (
7848 cat <<\_ASBOX
7c9e5167
JD
7849## ------------------------------------ ##
7850## Report this to bug-autoconf@gnu.org. ##
7851## ------------------------------------ ##
5d6da11e
YM
7852_ASBOX
7853 ) |
7854 sed "s/^/$as_me: WARNING: /" >&2
7855 ;;
7856esac
7857echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
7858echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
7859if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
7860 echo $ECHO_N "(cached) $ECHO_C" >&6
7861else
7862 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
7863fi
7864echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
7865echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
7866
7867fi
7868if test $ac_cv_header_Carbon_Carbon_h = yes; then
7869 HAVE_CARBON=yes
7870fi
7871
7872
7873 fi
7874fi
7875
98418dba
CW
7876### Compute the unexec source name from the object name.
7877UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
7878
7879# Do the opsystem or machine files prohibit the use of the GNU malloc?
7880# Assume not, until told otherwise.
7881GNU_MALLOC=yes
7882doug_lea_malloc=yes
c0d27fcc 7883echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
7884echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
7885if test "${ac_cv_func_malloc_get_state+set}" = set; then
7886 echo $ECHO_N "(cached) $ECHO_C" >&6
7887else
7888 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7889#line $LINENO "configure"
19650fd6
AS
7890/* confdefs.h. */
7891_ACEOF
7892cat confdefs.h >>conftest.$ac_ext
7893cat >>conftest.$ac_ext <<_ACEOF
7894/* end confdefs.h. */
98418dba 7895/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
7896 which can conflict with char malloc_get_state (); below.
7897 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7898 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
7899#ifdef __STDC__
7900# include <limits.h>
7901#else
7902# include <assert.h>
7903#endif
98418dba
CW
7904/* Override any gcc2 internal prototype to avoid an error. */
7905#ifdef __cplusplus
7906extern "C"
19650fd6 7907{
98418dba
CW
7908#endif
7909/* We use char because int might match the return type of a gcc2
7910 builtin and then its argument prototype would still apply. */
7911char malloc_get_state ();
98418dba
CW
7912/* The GNU C library defines this for functions which it implements
7913 to always fail with ENOSYS. Some functions are actually named
7914 something starting with __ and the normal name is an alias. */
7915#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
7916choke me
7917#else
19650fd6
AS
7918char (*f) () = malloc_get_state;
7919#endif
7920#ifdef __cplusplus
7921}
98418dba
CW
7922#endif
7923
19650fd6
AS
7924int
7925main ()
7926{
7927return f != malloc_get_state;
98418dba
CW
7928 ;
7929 return 0;
7930}
7931_ACEOF
7932rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7933if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 7934 (eval $ac_link) 2>&5
98418dba 7935 ac_status=$?
c0d27fcc 7936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7937 (exit $ac_status); } &&
7c9e5167 7938 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7939 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7940 (eval $ac_try) 2>&5
7941 ac_status=$?
c0d27fcc 7942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7943 (exit $ac_status); }; }; then
7944 ac_cv_func_malloc_get_state=yes
7945else
7946 echo "$as_me: failed program was:" >&5
19650fd6
AS
7947sed 's/^/| /' conftest.$ac_ext >&5
7948
98418dba
CW
7949ac_cv_func_malloc_get_state=no
7950fi
7c9e5167 7951rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 7952fi
c0d27fcc 7953echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
7954echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
7955if test $ac_cv_func_malloc_get_state = yes; then
7956 :
7957else
7958 doug_lea_malloc=no
7959fi
7960
c0d27fcc 7961echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
7962echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
7963if test "${ac_cv_func_malloc_set_state+set}" = set; then
7964 echo $ECHO_N "(cached) $ECHO_C" >&6
7965else
7966 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 7967#line $LINENO "configure"
19650fd6
AS
7968/* confdefs.h. */
7969_ACEOF
7970cat confdefs.h >>conftest.$ac_ext
7971cat >>conftest.$ac_ext <<_ACEOF
7972/* end confdefs.h. */
98418dba 7973/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
7974 which can conflict with char malloc_set_state (); below.
7975 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7976 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
7977#ifdef __STDC__
7978# include <limits.h>
7979#else
7980# include <assert.h>
7981#endif
98418dba
CW
7982/* Override any gcc2 internal prototype to avoid an error. */
7983#ifdef __cplusplus
7984extern "C"
19650fd6 7985{
98418dba
CW
7986#endif
7987/* We use char because int might match the return type of a gcc2
7988 builtin and then its argument prototype would still apply. */
7989char malloc_set_state ();
98418dba
CW
7990/* The GNU C library defines this for functions which it implements
7991 to always fail with ENOSYS. Some functions are actually named
7992 something starting with __ and the normal name is an alias. */
7993#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
7994choke me
7995#else
19650fd6
AS
7996char (*f) () = malloc_set_state;
7997#endif
7998#ifdef __cplusplus
7999}
98418dba
CW
8000#endif
8001
19650fd6
AS
8002int
8003main ()
8004{
8005return f != malloc_set_state;
98418dba
CW
8006 ;
8007 return 0;
8008}
8009_ACEOF
8010rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8011if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8012 (eval $ac_link) 2>&5
98418dba 8013 ac_status=$?
c0d27fcc 8014 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8015 (exit $ac_status); } &&
7c9e5167 8016 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8017 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8018 (eval $ac_try) 2>&5
8019 ac_status=$?
c0d27fcc 8020 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8021 (exit $ac_status); }; }; then
8022 ac_cv_func_malloc_set_state=yes
8023else
8024 echo "$as_me: failed program was:" >&5
19650fd6
AS
8025sed 's/^/| /' conftest.$ac_ext >&5
8026
98418dba
CW
8027ac_cv_func_malloc_set_state=no
8028fi
7c9e5167 8029rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 8030fi
c0d27fcc 8031echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
8032echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
8033if test $ac_cv_func_malloc_set_state = yes; then
8034 :
8035else
8036 doug_lea_malloc=no
8037fi
8038
c0d27fcc 8039echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
8040echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
8041if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
8042 echo $ECHO_N "(cached) $ECHO_C" >&6
8043else
8044 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8045#line $LINENO "configure"
19650fd6
AS
8046/* confdefs.h. */
8047_ACEOF
8048cat confdefs.h >>conftest.$ac_ext
8049cat >>conftest.$ac_ext <<_ACEOF
8050/* end confdefs.h. */
98418dba 8051extern void (* __after_morecore_hook)();
98418dba
CW
8052int
8053main ()
8054{
8055__after_morecore_hook = 0
8056 ;
8057 return 0;
8058}
8059_ACEOF
8060rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8061if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8062 (eval $ac_link) 2>&5
98418dba 8063 ac_status=$?
c0d27fcc 8064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8065 (exit $ac_status); } &&
7c9e5167 8066 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8067 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8068 (eval $ac_try) 2>&5
8069 ac_status=$?
c0d27fcc 8070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8071 (exit $ac_status); }; }; then
8072 emacs_cv_var___after_morecore_hook=yes
8073else
8074 echo "$as_me: failed program was:" >&5
19650fd6
AS
8075sed 's/^/| /' conftest.$ac_ext >&5
8076
98418dba
CW
8077emacs_cv_var___after_morecore_hook=no
8078fi
7c9e5167 8079rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 8080fi
c0d27fcc 8081echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
8082echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
8083if test $emacs_cv_var___after_morecore_hook = no; then
8084 doug_lea_malloc=no
8085fi
8086if test "${system_malloc}" = "yes"; then
8087 GNU_MALLOC=no
8088 GNU_MALLOC_reason="
8089 (The GNU allocators don't work with this system configuration.)"
8090fi
8091if test "$doug_lea_malloc" = "yes" ; then
8092 if test "$GNU_MALLOC" = yes ; then
8093 GNU_MALLOC_reason="
8094 (Using Doug Lea's new malloc from the GNU C Library.)"
8095 fi
b936fae4 8096
c0d27fcc 8097cat >>confdefs.h <<\_ACEOF
98418dba 8098#define DOUG_LEA_MALLOC 1
c0d27fcc 8099_ACEOF
98418dba
CW
8100
8101fi
8102
8103if test x"${REL_ALLOC}" = x; then
8104 REL_ALLOC=${GNU_MALLOC}
8105fi
8106
8107
c0d27fcc
MR
8108
8109
8110for ac_header in stdlib.h unistd.h
98418dba
CW
8111do
8112as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
8113if eval "test \"\${$as_ac_Header+set}\" = set"; then
8114 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
8115echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8116if eval "test \"\${$as_ac_Header+set}\" = set"; then
8117 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8118fi
8119echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8120echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 8121else
c0d27fcc
MR
8122 # Is the header compilable?
8123echo "$as_me:$LINENO: checking $ac_header usability" >&5
8124echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8125cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8126#line $LINENO "configure"
19650fd6
AS
8127/* confdefs.h. */
8128_ACEOF
8129cat confdefs.h >>conftest.$ac_ext
8130cat >>conftest.$ac_ext <<_ACEOF
8131/* end confdefs.h. */
98418dba
CW
8132$ac_includes_default
8133#include <$ac_header>
8134_ACEOF
8135rm -f conftest.$ac_objext
c0d27fcc 8136if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 8137 (eval $ac_compile) 2>&5
98418dba 8138 ac_status=$?
c0d27fcc 8139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8140 (exit $ac_status); } &&
7c9e5167 8141 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8142 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8143 (eval $ac_try) 2>&5
8144 ac_status=$?
c0d27fcc 8145 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8146 (exit $ac_status); }; }; then
c0d27fcc 8147 ac_header_compiler=yes
98418dba
CW
8148else
8149 echo "$as_me: failed program was:" >&5
19650fd6
AS
8150sed 's/^/| /' conftest.$ac_ext >&5
8151
c0d27fcc 8152ac_header_compiler=no
98418dba 8153fi
7c9e5167 8154rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
8155echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8156echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 8157
c0d27fcc
MR
8158# Is the header present?
8159echo "$as_me:$LINENO: checking $ac_header presence" >&5
8160echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8161cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8162#line $LINENO "configure"
19650fd6
AS
8163/* confdefs.h. */
8164_ACEOF
8165cat confdefs.h >>conftest.$ac_ext
8166cat >>conftest.$ac_ext <<_ACEOF
8167/* end confdefs.h. */
98418dba
CW
8168#include <$ac_header>
8169_ACEOF
c0d27fcc 8170if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8171 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8172 ac_status=$?
6bae0ccf 8173 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8174 rm -f conftest.er1
8175 cat conftest.err >&5
c0d27fcc 8176 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8177 (exit $ac_status); } >/dev/null; then
8178 if test -s conftest.err; then
8179 ac_cpp_err=$ac_c_preproc_warn_flag
8180 else
8181 ac_cpp_err=
8182 fi
8183else
8184 ac_cpp_err=yes
8185fi
8186if test -z "$ac_cpp_err"; then
c0d27fcc 8187 ac_header_preproc=yes
98418dba
CW
8188else
8189 echo "$as_me: failed program was:" >&5
19650fd6
AS
8190sed 's/^/| /' conftest.$ac_ext >&5
8191
c0d27fcc 8192 ac_header_preproc=no
98418dba
CW
8193fi
8194rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8195echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8196echo "${ECHO_T}$ac_header_preproc" >&6
8197
8198# So? What about this header?
7c9e5167
JD
8199case $ac_header_compiler:$ac_header_preproc in
8200 yes:no )
c0d27fcc
MR
8201 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8202echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
8203 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8204echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8205 (
8206 cat <<\_ASBOX
8207## ------------------------------------ ##
8208## Report this to bug-autoconf@gnu.org. ##
8209## ------------------------------------ ##
8210_ASBOX
8211 ) |
8212 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 8213 ;;
7c9e5167 8214 no:yes )
c0d27fcc
MR
8215 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8216echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
8217 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8218echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 8219 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 8220echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
8221 (
8222 cat <<\_ASBOX
7c9e5167
JD
8223## ------------------------------------ ##
8224## Report this to bug-autoconf@gnu.org. ##
8225## ------------------------------------ ##
19650fd6
AS
8226_ASBOX
8227 ) |
8228 sed "s/^/$as_me: WARNING: /" >&2
8229 ;;
c0d27fcc
MR
8230esac
8231echo "$as_me:$LINENO: checking for $ac_header" >&5
8232echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8233if eval "test \"\${$as_ac_Header+set}\" = set"; then
8234 echo $ECHO_N "(cached) $ECHO_C" >&6
8235else
7c9e5167 8236 eval "$as_ac_Header=$ac_header_preproc"
98418dba 8237fi
c0d27fcc 8238echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 8239echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
8240
8241fi
98418dba 8242if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 8243 cat >>confdefs.h <<_ACEOF
98418dba 8244#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 8245_ACEOF
98418dba
CW
8246
8247fi
c0d27fcc 8248
98418dba
CW
8249done
8250
c0d27fcc 8251
98418dba
CW
8252for ac_func in getpagesize
8253do
8254as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8255echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8256echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8257if eval "test \"\${$as_ac_var+set}\" = set"; then
8258 echo $ECHO_N "(cached) $ECHO_C" >&6
8259else
8260 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8261#line $LINENO "configure"
19650fd6
AS
8262/* confdefs.h. */
8263_ACEOF
8264cat confdefs.h >>conftest.$ac_ext
8265cat >>conftest.$ac_ext <<_ACEOF
8266/* end confdefs.h. */
98418dba 8267/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8268 which can conflict with char $ac_func (); below.
8269 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8270 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
8271#ifdef __STDC__
8272# include <limits.h>
8273#else
8274# include <assert.h>
8275#endif
98418dba
CW
8276/* Override any gcc2 internal prototype to avoid an error. */
8277#ifdef __cplusplus
8278extern "C"
19650fd6 8279{
98418dba
CW
8280#endif
8281/* We use char because int might match the return type of a gcc2
8282 builtin and then its argument prototype would still apply. */
8283char $ac_func ();
98418dba
CW
8284/* The GNU C library defines this for functions which it implements
8285 to always fail with ENOSYS. Some functions are actually named
8286 something starting with __ and the normal name is an alias. */
8287#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8288choke me
8289#else
19650fd6
AS
8290char (*f) () = $ac_func;
8291#endif
8292#ifdef __cplusplus
8293}
98418dba
CW
8294#endif
8295
19650fd6
AS
8296int
8297main ()
8298{
8299return f != $ac_func;
98418dba
CW
8300 ;
8301 return 0;
8302}
8303_ACEOF
8304rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8305if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8306 (eval $ac_link) 2>&5
98418dba 8307 ac_status=$?
c0d27fcc 8308 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8309 (exit $ac_status); } &&
7c9e5167 8310 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8311 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8312 (eval $ac_try) 2>&5
8313 ac_status=$?
c0d27fcc 8314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8315 (exit $ac_status); }; }; then
8316 eval "$as_ac_var=yes"
8317else
8318 echo "$as_me: failed program was:" >&5
19650fd6
AS
8319sed 's/^/| /' conftest.$ac_ext >&5
8320
98418dba
CW
8321eval "$as_ac_var=no"
8322fi
7c9e5167 8323rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 8324fi
c0d27fcc 8325echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
8326echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
8327if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 8328 cat >>confdefs.h <<_ACEOF
98418dba 8329#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 8330_ACEOF
98418dba
CW
8331
8332fi
8333done
8334
c0d27fcc 8335echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
8336echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
8337if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
8338 echo $ECHO_N "(cached) $ECHO_C" >&6
8339else
8340 if test "$cross_compiling" = yes; then
8341 ac_cv_func_mmap_fixed_mapped=no
8342else
8343 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8344#line $LINENO "configure"
19650fd6
AS
8345/* confdefs.h. */
8346_ACEOF
8347cat confdefs.h >>conftest.$ac_ext
8348cat >>conftest.$ac_ext <<_ACEOF
8349/* end confdefs.h. */
98418dba 8350$ac_includes_default
c0d27fcc
MR
8351/* malloc might have been renamed as rpl_malloc. */
8352#undef malloc
8353
98418dba
CW
8354/* Thanks to Mike Haertel and Jim Avera for this test.
8355 Here is a matrix of mmap possibilities:
8356 mmap private not fixed
8357 mmap private fixed at somewhere currently unmapped
8358 mmap private fixed at somewhere already mapped
8359 mmap shared not fixed
8360 mmap shared fixed at somewhere currently unmapped
8361 mmap shared fixed at somewhere already mapped
8362 For private mappings, we should verify that changes cannot be read()
8363 back from the file, nor mmap's back from the file at a different
8364 address. (There have been systems where private was not correctly
8365 implemented like the infamous i386 svr4.0, and systems where the
8366 VM page cache was not coherent with the file system buffer cache
8367 like early versions of FreeBSD and possibly contemporary NetBSD.)
8368 For shared mappings, we should conversely verify that changes get
c0d27fcc 8369 propagated back to all the places they're supposed to be.
98418dba
CW
8370
8371 Grep wants private fixed already mapped.
8372 The main things grep needs to know about mmap are:
8373 * does it exist and is it safe to write into the mmap'd area
8374 * how to use it (BSD variants) */
8375
8376#include <fcntl.h>
8377#include <sys/mman.h>
8378
8379#if !STDC_HEADERS && !HAVE_STDLIB_H
8380char *malloc ();
8381#endif
8382
8383/* This mess was copied from the GNU getpagesize.h. */
8384#if !HAVE_GETPAGESIZE
8385/* Assume that all systems that can run configure have sys/param.h. */
8386# if !HAVE_SYS_PARAM_H
8387# define HAVE_SYS_PARAM_H 1
8388# endif
8389
8390# ifdef _SC_PAGESIZE
8391# define getpagesize() sysconf(_SC_PAGESIZE)
8392# else /* no _SC_PAGESIZE */
8393# if HAVE_SYS_PARAM_H
8394# include <sys/param.h>
8395# ifdef EXEC_PAGESIZE
8396# define getpagesize() EXEC_PAGESIZE
8397# else /* no EXEC_PAGESIZE */
8398# ifdef NBPG
8399# define getpagesize() NBPG * CLSIZE
8400# ifndef CLSIZE
8401# define CLSIZE 1
8402# endif /* no CLSIZE */
8403# else /* no NBPG */
8404# ifdef NBPC
8405# define getpagesize() NBPC
8406# else /* no NBPC */
8407# ifdef PAGESIZE
8408# define getpagesize() PAGESIZE
8409# endif /* PAGESIZE */
8410# endif /* no NBPC */
8411# endif /* no NBPG */
8412# endif /* no EXEC_PAGESIZE */
8413# else /* no HAVE_SYS_PARAM_H */
8414# define getpagesize() 8192 /* punt totally */
8415# endif /* no HAVE_SYS_PARAM_H */
8416# endif /* no _SC_PAGESIZE */
8417
8418#endif /* no HAVE_GETPAGESIZE */
8419
8420int
8421main ()
8422{
8423 char *data, *data2, *data3;
8424 int i, pagesize;
8425 int fd;
8426
8427 pagesize = getpagesize ();
8428
8429 /* First, make a file with some known garbage in it. */
8430 data = (char *) malloc (pagesize);
8431 if (!data)
8432 exit (1);
8433 for (i = 0; i < pagesize; ++i)
8434 *(data + i) = rand ();
8435 umask (0);
8436 fd = creat ("conftest.mmap", 0600);
8437 if (fd < 0)
8438 exit (1);
8439 if (write (fd, data, pagesize) != pagesize)
8440 exit (1);
8441 close (fd);
8442
8443 /* Next, try to mmap the file at a fixed address which already has
8444 something else allocated at it. If we can, also make sure that
8445 we see the same garbage. */
8446 fd = open ("conftest.mmap", O_RDWR);
8447 if (fd < 0)
8448 exit (1);
8449 data2 = (char *) malloc (2 * pagesize);
8450 if (!data2)
8451 exit (1);
7c9e5167 8452 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
98418dba 8453 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
7c9e5167 8454 MAP_PRIVATE | MAP_FIXED, fd, 0L))
98418dba
CW
8455 exit (1);
8456 for (i = 0; i < pagesize; ++i)
8457 if (*(data + i) != *(data2 + i))
8458 exit (1);
8459
8460 /* Finally, make sure that changes to the mapped area do not
8461 percolate back to the file as seen by read(). (This is a bug on
8462 some variants of i386 svr4.0.) */
8463 for (i = 0; i < pagesize; ++i)
8464 *(data2 + i) = *(data2 + i) + 1;
8465 data3 = (char *) malloc (pagesize);
8466 if (!data3)
8467 exit (1);
8468 if (read (fd, data3, pagesize) != pagesize)
8469 exit (1);
8470 for (i = 0; i < pagesize; ++i)
8471 if (*(data + i) != *(data3 + i))
8472 exit (1);
8473 close (fd);
8474 exit (0);
8475}
8476_ACEOF
8477rm -f conftest$ac_exeext
c0d27fcc 8478if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8479 (eval $ac_link) 2>&5
8480 ac_status=$?
c0d27fcc 8481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8482 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 8483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8484 (eval $ac_try) 2>&5
8485 ac_status=$?
c0d27fcc 8486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8487 (exit $ac_status); }; }; then
8488 ac_cv_func_mmap_fixed_mapped=yes
8489else
8490 echo "$as_me: program exited with status $ac_status" >&5
8491echo "$as_me: failed program was:" >&5
19650fd6
AS
8492sed 's/^/| /' conftest.$ac_ext >&5
8493
c0d27fcc 8494( exit $ac_status )
98418dba
CW
8495ac_cv_func_mmap_fixed_mapped=no
8496fi
7c9e5167 8497rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
8498fi
8499fi
c0d27fcc 8500echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
8501echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
8502if test $ac_cv_func_mmap_fixed_mapped = yes; then
8503
c0d27fcc 8504cat >>confdefs.h <<\_ACEOF
98418dba 8505#define HAVE_MMAP 1
c0d27fcc 8506_ACEOF
98418dba
CW
8507
8508fi
8509rm -f conftest.mmap
8510
8511if test $use_mmap_for_buffers = yes; then
8512 REL_ALLOC=no
8513fi
8514
8515LIBS="$libsrc_libs $LIBS"
8516
c0d27fcc
MR
8517
8518echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
8519echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
8520if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
8521 echo $ECHO_N "(cached) $ECHO_C" >&6
8522else
8523 ac_check_lib_save_LIBS=$LIBS
8524LIBS="-ldnet $LIBS"
8525cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8526#line $LINENO "configure"
19650fd6
AS
8527/* confdefs.h. */
8528_ACEOF
8529cat confdefs.h >>conftest.$ac_ext
8530cat >>conftest.$ac_ext <<_ACEOF
8531/* end confdefs.h. */
98418dba
CW
8532
8533/* Override any gcc2 internal prototype to avoid an error. */
8534#ifdef __cplusplus
8535extern "C"
8536#endif
8537/* We use char because int might match the return type of a gcc2
8538 builtin and then its argument prototype would still apply. */
8539char dnet_ntoa ();
98418dba
CW
8540int
8541main ()
8542{
8543dnet_ntoa ();
8544 ;
8545 return 0;
8546}
8547_ACEOF
8548rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8549if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8550 (eval $ac_link) 2>&5
98418dba 8551 ac_status=$?
c0d27fcc 8552 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8553 (exit $ac_status); } &&
7c9e5167 8554 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8555 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8556 (eval $ac_try) 2>&5
8557 ac_status=$?
c0d27fcc 8558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8559 (exit $ac_status); }; }; then
8560 ac_cv_lib_dnet_dnet_ntoa=yes
8561else
8562 echo "$as_me: failed program was:" >&5
19650fd6
AS
8563sed 's/^/| /' conftest.$ac_ext >&5
8564
98418dba
CW
8565ac_cv_lib_dnet_dnet_ntoa=no
8566fi
7c9e5167 8567rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8568LIBS=$ac_check_lib_save_LIBS
8569fi
c0d27fcc 8570echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
8571echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
8572if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 8573 cat >>confdefs.h <<_ACEOF
98418dba 8574#define HAVE_LIBDNET 1
c0d27fcc 8575_ACEOF
98418dba
CW
8576
8577 LIBS="-ldnet $LIBS"
8578
8579fi
8580
c0d27fcc
MR
8581
8582echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
8583echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
8584if test "${ac_cv_lib_Xbsd_main+set}" = set; then
8585 echo $ECHO_N "(cached) $ECHO_C" >&6
8586else
8587 ac_check_lib_save_LIBS=$LIBS
8588LIBS="-lXbsd $LIBS"
8589cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8590#line $LINENO "configure"
19650fd6
AS
8591/* confdefs.h. */
8592_ACEOF
8593cat confdefs.h >>conftest.$ac_ext
8594cat >>conftest.$ac_ext <<_ACEOF
8595/* end confdefs.h. */
98418dba 8596
c0d27fcc 8597
98418dba
CW
8598int
8599main ()
8600{
8601main ();
8602 ;
8603 return 0;
8604}
8605_ACEOF
8606rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8607if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8608 (eval $ac_link) 2>&5
98418dba 8609 ac_status=$?
c0d27fcc 8610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8611 (exit $ac_status); } &&
7c9e5167 8612 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8613 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8614 (eval $ac_try) 2>&5
8615 ac_status=$?
c0d27fcc 8616 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8617 (exit $ac_status); }; }; then
8618 ac_cv_lib_Xbsd_main=yes
8619else
8620 echo "$as_me: failed program was:" >&5
19650fd6
AS
8621sed 's/^/| /' conftest.$ac_ext >&5
8622
98418dba
CW
8623ac_cv_lib_Xbsd_main=no
8624fi
7c9e5167 8625rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8626LIBS=$ac_check_lib_save_LIBS
8627fi
c0d27fcc 8628echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
8629echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
8630if test $ac_cv_lib_Xbsd_main = yes; then
8631 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
8632fi
8633
c0d27fcc
MR
8634
8635
8636echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
8637echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
8638if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
8639 echo $ECHO_N "(cached) $ECHO_C" >&6
8640else
8641 ac_check_lib_save_LIBS=$LIBS
8642LIBS="-lpthreads $LIBS"
8643cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8644#line $LINENO "configure"
19650fd6
AS
8645/* confdefs.h. */
8646_ACEOF
8647cat confdefs.h >>conftest.$ac_ext
8648cat >>conftest.$ac_ext <<_ACEOF
8649/* end confdefs.h. */
98418dba
CW
8650
8651/* Override any gcc2 internal prototype to avoid an error. */
8652#ifdef __cplusplus
8653extern "C"
8654#endif
8655/* We use char because int might match the return type of a gcc2
8656 builtin and then its argument prototype would still apply. */
8657char cma_open ();
98418dba
CW
8658int
8659main ()
8660{
8661cma_open ();
8662 ;
8663 return 0;
8664}
8665_ACEOF
8666rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8667if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8668 (eval $ac_link) 2>&5
98418dba 8669 ac_status=$?
c0d27fcc 8670 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8671 (exit $ac_status); } &&
7c9e5167 8672 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8673 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8674 (eval $ac_try) 2>&5
8675 ac_status=$?
c0d27fcc 8676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8677 (exit $ac_status); }; }; then
8678 ac_cv_lib_pthreads_cma_open=yes
8679else
8680 echo "$as_me: failed program was:" >&5
19650fd6
AS
8681sed 's/^/| /' conftest.$ac_ext >&5
8682
98418dba
CW
8683ac_cv_lib_pthreads_cma_open=no
8684fi
7c9e5167 8685rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8686LIBS=$ac_check_lib_save_LIBS
8687fi
c0d27fcc 8688echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
8689echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
8690if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 8691 cat >>confdefs.h <<_ACEOF
98418dba 8692#define HAVE_LIBPTHREADS 1
c0d27fcc 8693_ACEOF
98418dba
CW
8694
8695 LIBS="-lpthreads $LIBS"
8696
8697fi
8698
c0d27fcc
MR
8699
8700echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
8701echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
8702if test -d /usr/X386/include; then
8703 HAVE_XFREE386=yes
8704 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
8705else
8706 HAVE_XFREE386=no
8707fi
c0d27fcc 8708echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
8709echo "${ECHO_T}$HAVE_XFREE386" >&6
8710
55597d70
DL
8711
8712case ${host_os} in
8713aix*)
8714 echo "$as_me:$LINENO: checking for -bbigtoc option" >&5
8715echo $ECHO_N "checking for -bbigtoc option... $ECHO_C" >&6
8716if test "${gdb_cv_bigtoc+set}" = set; then
8717 echo $ECHO_N "(cached) $ECHO_C" >&6
8718else
8719
8720 case $GCC in
8721 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
8722 *) gdb_cv_bigtoc=-bbigtoc ;;
8723 esac
8724
8725 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
8726 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8727#line $LINENO "configure"
19650fd6
AS
8728/* confdefs.h. */
8729_ACEOF
8730cat confdefs.h >>conftest.$ac_ext
8731cat >>conftest.$ac_ext <<_ACEOF
8732/* end confdefs.h. */
55597d70
DL
8733
8734int
8735main ()
8736{
8737int i;
8738 ;
8739 return 0;
8740}
8741_ACEOF
8742rm -f conftest.$ac_objext conftest$ac_exeext
8743if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8744 (eval $ac_link) 2>&5
55597d70
DL
8745 ac_status=$?
8746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8747 (exit $ac_status); } &&
7c9e5167 8748 { ac_try='test -s conftest$ac_exeext'
55597d70
DL
8749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8750 (eval $ac_try) 2>&5
8751 ac_status=$?
8752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8753 (exit $ac_status); }; }; then
8754 :
8755else
8756 echo "$as_me: failed program was:" >&5
19650fd6
AS
8757sed 's/^/| /' conftest.$ac_ext >&5
8758
55597d70
DL
8759gdb_cv_bigtoc=
8760fi
7c9e5167 8761rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
55597d70
DL
8762
8763fi
8764echo "$as_me:$LINENO: result: $gdb_cv_bigtoc" >&5
8765echo "${ECHO_T}$gdb_cv_bigtoc" >&6
8766 ;;
8767esac
8768
ae1a998c
RS
8769# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
8770# used for the tests that follow. We set them back to REAL_CFLAGS and
8771# REAL_CPPFLAGS later on.
98418dba
CW
8772
8773REAL_CPPFLAGS="$CPPFLAGS"
8774
8775if test "${HAVE_X11}" = "yes"; then
8776 DEFS="$C_SWITCH_X_SITE $DEFS"
8777 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
8778 LIBS="$LIBX $LIBS"
8779 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
8780 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
8781
8782 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
8783 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
8784 # but it's more convenient here to set LD_RUN_PATH
8785 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
8786 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8787 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
8788 export LD_RUN_PATH
8789 fi
8790
8791 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 8792 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
8793echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
8794 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8795#line $LINENO "configure"
19650fd6
AS
8796/* confdefs.h. */
8797_ACEOF
8798cat confdefs.h >>conftest.$ac_ext
8799cat >>conftest.$ac_ext <<_ACEOF
8800/* end confdefs.h. */
98418dba 8801
98418dba
CW
8802int
8803main ()
8804{
8805XOpenDisplay ("foo");
8806 ;
8807 return 0;
8808}
8809_ACEOF
8810rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8811if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8812 (eval $ac_link) 2>&5
98418dba 8813 ac_status=$?
c0d27fcc 8814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8815 (exit $ac_status); } &&
7c9e5167 8816 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
8817 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8818 (eval $ac_try) 2>&5
8819 ac_status=$?
8820 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8821 (exit $ac_status); }; }; then
8822 xlinux_first_failure=no
98418dba
CW
8823else
8824 echo "$as_me: failed program was:" >&5
19650fd6
AS
8825sed 's/^/| /' conftest.$ac_ext >&5
8826
98418dba
CW
8827xlinux_first_failure=yes
8828fi
7c9e5167 8829rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8830 if test "${xlinux_first_failure}" = "yes"; then
8831 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
8832 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
8833 OLD_CPPFLAGS="$CPPFLAGS"
8834 OLD_LIBS="$LIBS"
8835 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
8836 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
8837 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
8838 LIBS="$LIBS -b i486-linuxaout"
8839 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8840#line $LINENO "configure"
19650fd6
AS
8841/* confdefs.h. */
8842_ACEOF
8843cat confdefs.h >>conftest.$ac_ext
8844cat >>conftest.$ac_ext <<_ACEOF
8845/* end confdefs.h. */
98418dba 8846
98418dba
CW
8847int
8848main ()
8849{
8850XOpenDisplay ("foo");
8851 ;
8852 return 0;
8853}
8854_ACEOF
8855rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8856if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8857 (eval $ac_link) 2>&5
98418dba 8858 ac_status=$?
c0d27fcc 8859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8860 (exit $ac_status); } &&
7c9e5167 8861 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8862 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8863 (eval $ac_try) 2>&5
8864 ac_status=$?
c0d27fcc 8865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8866 (exit $ac_status); }; }; then
8867 xlinux_second_failure=no
8868else
8869 echo "$as_me: failed program was:" >&5
19650fd6
AS
8870sed 's/^/| /' conftest.$ac_ext >&5
8871
98418dba
CW
8872xlinux_second_failure=yes
8873fi
7c9e5167 8874rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
8875 if test "${xlinux_second_failure}" = "yes"; then
8876 # If we get the same failure with -b, there is no use adding -b.
8877 # So take it out. This plays safe.
8878 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
8879 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
8880 CPPFLAGS="$OLD_CPPFLAGS"
8881 LIBS="$OLD_LIBS"
c0d27fcc 8882 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
8883echo "${ECHO_T}no" >&6
8884 else
c0d27fcc 8885 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
8886echo "${ECHO_T}yes" >&6
8887 fi
8888 else
c0d27fcc 8889 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
8890echo "${ECHO_T}no" >&6
8891 fi
8892 fi
8893
8894 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
8895 # header files included from there.
c0d27fcc 8896 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
8897echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
8898 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8899#line $LINENO "configure"
19650fd6
AS
8900/* confdefs.h. */
8901_ACEOF
8902cat confdefs.h >>conftest.$ac_ext
8903cat >>conftest.$ac_ext <<_ACEOF
8904/* end confdefs.h. */
98418dba
CW
8905#include <X11/Xlib.h>
8906#include <X11/XKBlib.h>
98418dba
CW
8907int
8908main ()
8909{
8910XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
8911 ;
8912 return 0;
8913}
8914_ACEOF
8915rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8916if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 8917 (eval $ac_link) 2>&5
98418dba 8918 ac_status=$?
c0d27fcc 8919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 8920 (exit $ac_status); } &&
7c9e5167 8921 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8923 (eval $ac_try) 2>&5
8924 ac_status=$?
c0d27fcc 8925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8926 (exit $ac_status); }; }; then
8927 emacs_xkb=yes
8928else
8929 echo "$as_me: failed program was:" >&5
19650fd6
AS
8930sed 's/^/| /' conftest.$ac_ext >&5
8931
98418dba
CW
8932emacs_xkb=no
8933fi
7c9e5167 8934rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
c0d27fcc 8935 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
8936echo "${ECHO_T}$emacs_xkb" >&6
8937 if test $emacs_xkb = yes; then
b936fae4 8938
c0d27fcc 8939cat >>confdefs.h <<\_ACEOF
98418dba 8940#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 8941_ACEOF
98418dba
CW
8942
8943 fi
8944
c0d27fcc
MR
8945
8946
8947
8948
98418dba
CW
8949for ac_func in XrmSetDatabase XScreenResourceString \
8950XScreenNumberOfScreen XSetWMProtocols
8951do
8952as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 8953echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
8954echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
8955if eval "test \"\${$as_ac_var+set}\" = set"; then
8956 echo $ECHO_N "(cached) $ECHO_C" >&6
8957else
8958 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 8959#line $LINENO "configure"
19650fd6
AS
8960/* confdefs.h. */
8961_ACEOF
8962cat confdefs.h >>conftest.$ac_ext
8963cat >>conftest.$ac_ext <<_ACEOF
8964/* end confdefs.h. */
98418dba 8965/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
8966 which can conflict with char $ac_func (); below.
8967 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8968 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
8969#ifdef __STDC__
8970# include <limits.h>
8971#else
8972# include <assert.h>
8973#endif
98418dba
CW
8974/* Override any gcc2 internal prototype to avoid an error. */
8975#ifdef __cplusplus
8976extern "C"
19650fd6 8977{
98418dba
CW
8978#endif
8979/* We use char because int might match the return type of a gcc2
8980 builtin and then its argument prototype would still apply. */
8981char $ac_func ();
98418dba
CW
8982/* The GNU C library defines this for functions which it implements
8983 to always fail with ENOSYS. Some functions are actually named
8984 something starting with __ and the normal name is an alias. */
8985#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
8986choke me
8987#else
19650fd6
AS
8988char (*f) () = $ac_func;
8989#endif
8990#ifdef __cplusplus
8991}
98418dba
CW
8992#endif
8993
19650fd6
AS
8994int
8995main ()
8996{
8997return f != $ac_func;
98418dba
CW
8998 ;
8999 return 0;
9000}
9001_ACEOF
9002rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9003if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9004 (eval $ac_link) 2>&5
98418dba 9005 ac_status=$?
c0d27fcc 9006 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9007 (exit $ac_status); } &&
7c9e5167 9008 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9009 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9010 (eval $ac_try) 2>&5
9011 ac_status=$?
c0d27fcc 9012 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9013 (exit $ac_status); }; }; then
9014 eval "$as_ac_var=yes"
9015else
9016 echo "$as_me: failed program was:" >&5
19650fd6
AS
9017sed 's/^/| /' conftest.$ac_ext >&5
9018
98418dba
CW
9019eval "$as_ac_var=no"
9020fi
7c9e5167 9021rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 9022fi
c0d27fcc 9023echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
9024echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9025if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 9026 cat >>confdefs.h <<_ACEOF
98418dba 9027#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 9028_ACEOF
98418dba
CW
9029
9030fi
9031done
9032
9033fi
9034
9035if test "${window_system}" = "x11"; then
c0d27fcc 9036 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
9037echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
9038 if test "${emacs_cv_x11_version_6+set}" = set; then
9039 echo $ECHO_N "(cached) $ECHO_C" >&6
9040else
9041 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9042#line $LINENO "configure"
19650fd6
AS
9043/* confdefs.h. */
9044_ACEOF
9045cat confdefs.h >>conftest.$ac_ext
9046cat >>conftest.$ac_ext <<_ACEOF
9047/* end confdefs.h. */
98418dba 9048#include <X11/Xlib.h>
98418dba
CW
9049int
9050main ()
9051{
9052#if XlibSpecificationRelease < 6
9053fail;
9054#endif
9055
9056 ;
9057 return 0;
9058}
9059_ACEOF
9060rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9061if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9062 (eval $ac_link) 2>&5
98418dba 9063 ac_status=$?
c0d27fcc 9064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9065 (exit $ac_status); } &&
7c9e5167 9066 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9067 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9068 (eval $ac_try) 2>&5
9069 ac_status=$?
c0d27fcc 9070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9071 (exit $ac_status); }; }; then
9072 emacs_cv_x11_version_6=yes
9073else
9074 echo "$as_me: failed program was:" >&5
19650fd6
AS
9075sed 's/^/| /' conftest.$ac_ext >&5
9076
98418dba
CW
9077emacs_cv_x11_version_6=no
9078fi
7c9e5167 9079rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9080fi
9081
9082 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 9083 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9084echo "${ECHO_T}6 or newer" >&6
b936fae4 9085
c0d27fcc 9086cat >>confdefs.h <<\_ACEOF
98418dba 9087#define HAVE_X11R6 1
c0d27fcc 9088_ACEOF
98418dba
CW
9089
9090 else
c0d27fcc 9091 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9092echo "${ECHO_T}before 6" >&6
9093 fi
9094fi
9095
9096if test "${window_system}" = "x11"; then
c0d27fcc 9097 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
9098echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
9099 if test "${emacs_cv_x11_version_5+set}" = set; then
9100 echo $ECHO_N "(cached) $ECHO_C" >&6
9101else
9102 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9103#line $LINENO "configure"
19650fd6
AS
9104/* confdefs.h. */
9105_ACEOF
9106cat confdefs.h >>conftest.$ac_ext
9107cat >>conftest.$ac_ext <<_ACEOF
9108/* end confdefs.h. */
98418dba 9109#include <X11/Xlib.h>
98418dba
CW
9110int
9111main ()
9112{
9113#if XlibSpecificationRelease < 5
9114fail;
9115#endif
9116
9117 ;
9118 return 0;
9119}
9120_ACEOF
9121rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9122if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9123 (eval $ac_link) 2>&5
98418dba 9124 ac_status=$?
c0d27fcc 9125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9126 (exit $ac_status); } &&
7c9e5167 9127 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9128 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9129 (eval $ac_try) 2>&5
9130 ac_status=$?
c0d27fcc 9131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9132 (exit $ac_status); }; }; then
9133 emacs_cv_x11_version_5=yes
9134else
9135 echo "$as_me: failed program was:" >&5
19650fd6
AS
9136sed 's/^/| /' conftest.$ac_ext >&5
9137
98418dba
CW
9138emacs_cv_x11_version_5=no
9139fi
7c9e5167 9140rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9141fi
9142
9143 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 9144 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
9145echo "${ECHO_T}5 or newer" >&6
9146 HAVE_X11R5=yes
b936fae4 9147
c0d27fcc 9148cat >>confdefs.h <<\_ACEOF
98418dba 9149#define HAVE_X11R5 1
c0d27fcc 9150_ACEOF
98418dba
CW
9151
9152 else
9153 HAVE_X11R5=no
c0d27fcc 9154 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
9155echo "${ECHO_T}before 5" >&6
9156 fi
9157fi
9158
488dd4c4
JD
9159
9160
9161HAVE_GTK=no
9162if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 9163 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
9164 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
9165echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
9166 { (exit 1); exit 1; }; };
9167 fi
9168 GLIB_REQUIRED=2.0.1
e512ece1 9169 GTK_REQUIRED=2.0.1
488dd4c4
JD
9170 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
9171
9172 if test "X${with_pkg_config_prog}" != X; then
9173 PKG_CONFIG="${with_pkg_config_prog}"
9174 fi
9175
9176 succeeded=no
9177
9178 if test -z "$PKG_CONFIG"; then
9179 # Extract the first word of "pkg-config", so it can be a program name with args.
9180set dummy pkg-config; ac_word=$2
9181echo "$as_me:$LINENO: checking for $ac_word" >&5
9182echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
9183if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
9184 echo $ECHO_N "(cached) $ECHO_C" >&6
9185else
9186 case $PKG_CONFIG in
9187 [\\/]* | ?:[\\/]*)
9188 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9189 ;;
9190 *)
9191 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9192for as_dir in $PATH
9193do
9194 IFS=$as_save_IFS
9195 test -z "$as_dir" && as_dir=.
9196 for ac_exec_ext in '' $ac_executable_extensions; do
9197 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9198 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9199 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
9200 break 2
9201 fi
9202done
9203done
9204
9205 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9206 ;;
9207esac
9208fi
9209PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9210
9211if test -n "$PKG_CONFIG"; then
9212 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
9213echo "${ECHO_T}$PKG_CONFIG" >&6
9214else
9215 echo "$as_me:$LINENO: result: no" >&5
9216echo "${ECHO_T}no" >&6
9217fi
9218
9219 fi
9220
9221 if test "$PKG_CONFIG" = "no" ; then
9222 echo "*** The pkg-config script could not be found. Make sure it is"
9223 echo "*** in your path, or give the full path to pkg-config with"
9224 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
9225 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
9226 else
9227 PKG_CONFIG_MIN_VERSION=0.9.0
9228 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9229 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
9230echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
9231
9232 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
9233 echo "$as_me:$LINENO: result: yes" >&5
9234echo "${ECHO_T}yes" >&6
9235 succeeded=yes
9236
9237 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
9238echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
9239 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
9240 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
9241echo "${ECHO_T}$GTK_CFLAGS" >&6
9242
9243 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
9244echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
9245 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
9246 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
9247echo "${ECHO_T}$GTK_LIBS" >&6
9248 else
9249 GTK_CFLAGS=""
9250 GTK_LIBS=""
9251 ## If we have a custom action on failure, don't print errors, but
9252 ## do set a variable so people can do so.
9253 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
9254 echo $GTK_PKG_ERRORS
9255 fi
9256
9257
9258
9259 else
9260 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9261 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9262 fi
9263 fi
9264
9265 if test $succeeded = yes; then
9266 :
9267 else
9268 { { 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
9269echo "$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;}
9270 { (exit 1); exit 1; }; }
9271 fi
9272
9273
9274
9275 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
57669b57
JD
9276 CFLAGS="$CFLAGS $GTK_CFLAGS"
9277 LIBS="$GTK_LIBS $LIBS"
488dd4c4
JD
9278 HAVE_GTK=yes
9279
9280cat >>confdefs.h <<\_ACEOF
9281#define HAVE_GTK 1
9282_ACEOF
9283
9284 USE_X_TOOLKIT=none
9285
d0a80c21
JD
9286 if test "$with_toolkit_scroll_bars" != no; then
9287 with_toolkit_scroll_bars=yes
9288 fi
57669b57
JD
9289
9290 HAVE_GTK_MULTIDISPLAY=no
9291
9292for ac_func in gdk_display_open
9293do
9294as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9295echo "$as_me:$LINENO: checking for $ac_func" >&5
9296echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9297if eval "test \"\${$as_ac_var+set}\" = set"; then
9298 echo $ECHO_N "(cached) $ECHO_C" >&6
9299else
9300 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9301#line $LINENO "configure"
57669b57
JD
9302/* confdefs.h. */
9303_ACEOF
9304cat confdefs.h >>conftest.$ac_ext
9305cat >>conftest.$ac_ext <<_ACEOF
9306/* end confdefs.h. */
9307/* System header to define __stub macros and hopefully few prototypes,
9308 which can conflict with char $ac_func (); below.
9309 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9310 <limits.h> exists even on freestanding compilers. */
9311#ifdef __STDC__
9312# include <limits.h>
9313#else
9314# include <assert.h>
9315#endif
9316/* Override any gcc2 internal prototype to avoid an error. */
9317#ifdef __cplusplus
9318extern "C"
9319{
9320#endif
9321/* We use char because int might match the return type of a gcc2
9322 builtin and then its argument prototype would still apply. */
9323char $ac_func ();
9324/* The GNU C library defines this for functions which it implements
9325 to always fail with ENOSYS. Some functions are actually named
9326 something starting with __ and the normal name is an alias. */
9327#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9328choke me
9329#else
9330char (*f) () = $ac_func;
9331#endif
9332#ifdef __cplusplus
9333}
9334#endif
9335
9336int
9337main ()
9338{
9339return f != $ac_func;
9340 ;
9341 return 0;
9342}
9343_ACEOF
9344rm -f conftest.$ac_objext conftest$ac_exeext
9345if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9346 (eval $ac_link) 2>&5
57669b57
JD
9347 ac_status=$?
9348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9349 (exit $ac_status); } &&
7c9e5167 9350 { ac_try='test -s conftest$ac_exeext'
57669b57
JD
9351 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9352 (eval $ac_try) 2>&5
9353 ac_status=$?
9354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9355 (exit $ac_status); }; }; then
9356 eval "$as_ac_var=yes"
9357else
9358 echo "$as_me: failed program was:" >&5
9359sed 's/^/| /' conftest.$ac_ext >&5
9360
9361eval "$as_ac_var=no"
9362fi
7c9e5167 9363rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
57669b57
JD
9364fi
9365echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9366echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9367if test `eval echo '${'$as_ac_var'}'` = yes; then
9368 cat >>confdefs.h <<_ACEOF
9369#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9370_ACEOF
9371 HAVE_GTK_MULTIDISPLAY=yes
9372fi
9373done
9374
9375 if test "${HAVE_GTK_MULTIDISPLAY}" = "yes"; then
9376
9377cat >>confdefs.h <<\_ACEOF
9378#define HAVE_GTK_MULTIDISPLAY 1
572a3cc2
JD
9379_ACEOF
9380
9381 fi
9382 HAVE_GTK_FILE_SELECTION=no
9383
9384for ac_func in gtk_file_selection_new
9385do
9386as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9387echo "$as_me:$LINENO: checking for $ac_func" >&5
9388echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9389if eval "test \"\${$as_ac_var+set}\" = set"; then
9390 echo $ECHO_N "(cached) $ECHO_C" >&6
9391else
9392 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9393#line $LINENO "configure"
572a3cc2
JD
9394/* confdefs.h. */
9395_ACEOF
9396cat confdefs.h >>conftest.$ac_ext
9397cat >>conftest.$ac_ext <<_ACEOF
9398/* end confdefs.h. */
572a3cc2
JD
9399/* System header to define __stub macros and hopefully few prototypes,
9400 which can conflict with char $ac_func (); below.
9401 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9402 <limits.h> exists even on freestanding compilers. */
572a3cc2
JD
9403#ifdef __STDC__
9404# include <limits.h>
9405#else
9406# include <assert.h>
9407#endif
572a3cc2
JD
9408/* Override any gcc2 internal prototype to avoid an error. */
9409#ifdef __cplusplus
9410extern "C"
9411{
9412#endif
9413/* We use char because int might match the return type of a gcc2
9414 builtin and then its argument prototype would still apply. */
9415char $ac_func ();
9416/* The GNU C library defines this for functions which it implements
9417 to always fail with ENOSYS. Some functions are actually named
9418 something starting with __ and the normal name is an alias. */
9419#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9420choke me
9421#else
9422char (*f) () = $ac_func;
9423#endif
9424#ifdef __cplusplus
9425}
9426#endif
9427
9428int
9429main ()
9430{
9431return f != $ac_func;
9432 ;
9433 return 0;
9434}
9435_ACEOF
9436rm -f conftest.$ac_objext conftest$ac_exeext
9437if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9438 (eval $ac_link) 2>&5
572a3cc2 9439 ac_status=$?
572a3cc2
JD
9440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9441 (exit $ac_status); } &&
7c9e5167 9442 { ac_try='test -s conftest$ac_exeext'
572a3cc2
JD
9443 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9444 (eval $ac_try) 2>&5
9445 ac_status=$?
9446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9447 (exit $ac_status); }; }; then
9448 eval "$as_ac_var=yes"
9449else
9450 echo "$as_me: failed program was:" >&5
9451sed 's/^/| /' conftest.$ac_ext >&5
9452
9453eval "$as_ac_var=no"
9454fi
7c9e5167 9455rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
572a3cc2
JD
9456fi
9457echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9458echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9459if test `eval echo '${'$as_ac_var'}'` = yes; then
9460 cat >>confdefs.h <<_ACEOF
9461#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9462_ACEOF
9463 HAVE_GTK_FILE_SELECTION=yes
9464fi
9465done
9466
9467
9468 HAVE_GTK_FILE_CHOOSER=no
9469
9470for ac_func in gtk_file_chooser_dialog_new
9471do
9472as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9473echo "$as_me:$LINENO: checking for $ac_func" >&5
9474echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
9475if eval "test \"\${$as_ac_var+set}\" = set"; then
9476 echo $ECHO_N "(cached) $ECHO_C" >&6
9477else
9478 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9479#line $LINENO "configure"
572a3cc2
JD
9480/* confdefs.h. */
9481_ACEOF
9482cat confdefs.h >>conftest.$ac_ext
9483cat >>conftest.$ac_ext <<_ACEOF
9484/* end confdefs.h. */
572a3cc2
JD
9485/* System header to define __stub macros and hopefully few prototypes,
9486 which can conflict with char $ac_func (); below.
9487 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9488 <limits.h> exists even on freestanding compilers. */
572a3cc2
JD
9489#ifdef __STDC__
9490# include <limits.h>
9491#else
9492# include <assert.h>
9493#endif
572a3cc2
JD
9494/* Override any gcc2 internal prototype to avoid an error. */
9495#ifdef __cplusplus
9496extern "C"
9497{
9498#endif
9499/* We use char because int might match the return type of a gcc2
9500 builtin and then its argument prototype would still apply. */
9501char $ac_func ();
9502/* The GNU C library defines this for functions which it implements
9503 to always fail with ENOSYS. Some functions are actually named
9504 something starting with __ and the normal name is an alias. */
9505#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
9506choke me
9507#else
9508char (*f) () = $ac_func;
9509#endif
9510#ifdef __cplusplus
9511}
9512#endif
9513
9514int
9515main ()
9516{
9517return f != $ac_func;
9518 ;
9519 return 0;
9520}
9521_ACEOF
9522rm -f conftest.$ac_objext conftest$ac_exeext
9523if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9524 (eval $ac_link) 2>&5
572a3cc2 9525 ac_status=$?
572a3cc2
JD
9526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9527 (exit $ac_status); } &&
7c9e5167 9528 { ac_try='test -s conftest$ac_exeext'
572a3cc2
JD
9529 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9530 (eval $ac_try) 2>&5
9531 ac_status=$?
9532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9533 (exit $ac_status); }; }; then
9534 eval "$as_ac_var=yes"
9535else
9536 echo "$as_me: failed program was:" >&5
9537sed 's/^/| /' conftest.$ac_ext >&5
9538
9539eval "$as_ac_var=no"
9540fi
7c9e5167 9541rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
572a3cc2
JD
9542fi
9543echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
9544echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
9545if test `eval echo '${'$as_ac_var'}'` = yes; then
9546 cat >>confdefs.h <<_ACEOF
9547#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9548_ACEOF
9549 HAVE_GTK_FILE_CHOOSER=yes
9550fi
9551done
9552
9553
9554 if test "$HAVE_GTK_FILE_SELECTION" = yes \
9555 && test "$HAVE_GTK_FILE_CHOOSER" = yes; then
9556
9557cat >>confdefs.h <<\_ACEOF
9558#define HAVE_GTK_FILE_BOTH 1
57669b57
JD
9559_ACEOF
9560
b8bdffbe
JD
9561 fi
9562
9563 if test "$HAVE_GTK_FILE_CHOOSER" = yes; then
9564 HAVE_GTK_AND_PTHREAD=no
9565
9566for ac_header in pthread.h
9567do
9568as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9569if eval "test \"\${$as_ac_Header+set}\" = set"; then
9570 echo "$as_me:$LINENO: checking for $ac_header" >&5
9571echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9572if eval "test \"\${$as_ac_Header+set}\" = set"; then
9573 echo $ECHO_N "(cached) $ECHO_C" >&6
9574fi
9575echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9576echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9577else
9578 # Is the header compilable?
9579echo "$as_me:$LINENO: checking $ac_header usability" >&5
9580echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9581cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9582#line $LINENO "configure"
b8bdffbe
JD
9583/* confdefs.h. */
9584_ACEOF
9585cat confdefs.h >>conftest.$ac_ext
9586cat >>conftest.$ac_ext <<_ACEOF
9587/* end confdefs.h. */
9588$ac_includes_default
9589#include <$ac_header>
9590_ACEOF
9591rm -f conftest.$ac_objext
9592if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 9593 (eval $ac_compile) 2>&5
b8bdffbe 9594 ac_status=$?
b8bdffbe
JD
9595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9596 (exit $ac_status); } &&
7c9e5167 9597 { ac_try='test -s conftest.$ac_objext'
b8bdffbe
JD
9598 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9599 (eval $ac_try) 2>&5
9600 ac_status=$?
9601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9602 (exit $ac_status); }; }; then
9603 ac_header_compiler=yes
9604else
9605 echo "$as_me: failed program was:" >&5
9606sed 's/^/| /' conftest.$ac_ext >&5
9607
9608ac_header_compiler=no
9609fi
7c9e5167 9610rm -f conftest.$ac_objext conftest.$ac_ext
b8bdffbe
JD
9611echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9612echo "${ECHO_T}$ac_header_compiler" >&6
9613
9614# Is the header present?
9615echo "$as_me:$LINENO: checking $ac_header presence" >&5
9616echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9617cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9618#line $LINENO "configure"
b8bdffbe
JD
9619/* confdefs.h. */
9620_ACEOF
9621cat confdefs.h >>conftest.$ac_ext
9622cat >>conftest.$ac_ext <<_ACEOF
9623/* end confdefs.h. */
9624#include <$ac_header>
9625_ACEOF
9626if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9627 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9628 ac_status=$?
9629 grep -v '^ *+' conftest.er1 >conftest.err
9630 rm -f conftest.er1
9631 cat conftest.err >&5
9632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9633 (exit $ac_status); } >/dev/null; then
9634 if test -s conftest.err; then
9635 ac_cpp_err=$ac_c_preproc_warn_flag
b8bdffbe
JD
9636 else
9637 ac_cpp_err=
9638 fi
9639else
9640 ac_cpp_err=yes
9641fi
9642if test -z "$ac_cpp_err"; then
9643 ac_header_preproc=yes
9644else
9645 echo "$as_me: failed program was:" >&5
9646sed 's/^/| /' conftest.$ac_ext >&5
9647
9648 ac_header_preproc=no
9649fi
9650rm -f conftest.err conftest.$ac_ext
9651echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9652echo "${ECHO_T}$ac_header_preproc" >&6
9653
9654# So? What about this header?
7c9e5167
JD
9655case $ac_header_compiler:$ac_header_preproc in
9656 yes:no )
b8bdffbe
JD
9657 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9658echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
9659 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9660echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9661 (
9662 cat <<\_ASBOX
9663## ------------------------------------ ##
9664## Report this to bug-autoconf@gnu.org. ##
9665## ------------------------------------ ##
9666_ASBOX
9667 ) |
9668 sed "s/^/$as_me: WARNING: /" >&2
b8bdffbe 9669 ;;
7c9e5167 9670 no:yes )
b8bdffbe
JD
9671 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9672echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
9673 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
9674echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
b8bdffbe
JD
9675 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9676echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
b8bdffbe
JD
9677 (
9678 cat <<\_ASBOX
7c9e5167
JD
9679## ------------------------------------ ##
9680## Report this to bug-autoconf@gnu.org. ##
9681## ------------------------------------ ##
b8bdffbe
JD
9682_ASBOX
9683 ) |
9684 sed "s/^/$as_me: WARNING: /" >&2
9685 ;;
9686esac
9687echo "$as_me:$LINENO: checking for $ac_header" >&5
9688echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9689if eval "test \"\${$as_ac_Header+set}\" = set"; then
9690 echo $ECHO_N "(cached) $ECHO_C" >&6
9691else
7c9e5167 9692 eval "$as_ac_Header=$ac_header_preproc"
b8bdffbe
JD
9693fi
9694echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9695echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9696
9697fi
9698if test `eval echo '${'$as_ac_Header'}'` = yes; then
9699 cat >>confdefs.h <<_ACEOF
9700#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9701_ACEOF
9702
9703fi
9704
9705done
9706
9707 if test "$ac_cv_header_pthread_h"; then
9708 echo "$as_me:$LINENO: checking for pthread_self in -lpthread" >&5
9709echo $ECHO_N "checking for pthread_self in -lpthread... $ECHO_C" >&6
9710if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then
9711 echo $ECHO_N "(cached) $ECHO_C" >&6
9712else
9713 ac_check_lib_save_LIBS=$LIBS
9714LIBS="-lpthread $LIBS"
9715cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9716#line $LINENO "configure"
b8bdffbe
JD
9717/* confdefs.h. */
9718_ACEOF
9719cat confdefs.h >>conftest.$ac_ext
9720cat >>conftest.$ac_ext <<_ACEOF
9721/* end confdefs.h. */
9722
9723/* Override any gcc2 internal prototype to avoid an error. */
9724#ifdef __cplusplus
9725extern "C"
9726#endif
9727/* We use char because int might match the return type of a gcc2
9728 builtin and then its argument prototype would still apply. */
9729char pthread_self ();
9730int
9731main ()
9732{
9733pthread_self ();
9734 ;
9735 return 0;
9736}
9737_ACEOF
9738rm -f conftest.$ac_objext conftest$ac_exeext
9739if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9740 (eval $ac_link) 2>&5
b8bdffbe 9741 ac_status=$?
b8bdffbe
JD
9742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9743 (exit $ac_status); } &&
7c9e5167 9744 { ac_try='test -s conftest$ac_exeext'
b8bdffbe
JD
9745 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9746 (eval $ac_try) 2>&5
9747 ac_status=$?
9748 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9749 (exit $ac_status); }; }; then
9750 ac_cv_lib_pthread_pthread_self=yes
9751else
9752 echo "$as_me: failed program was:" >&5
9753sed 's/^/| /' conftest.$ac_ext >&5
9754
9755ac_cv_lib_pthread_pthread_self=no
9756fi
7c9e5167 9757rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
b8bdffbe
JD
9758LIBS=$ac_check_lib_save_LIBS
9759fi
9760echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_self" >&5
9761echo "${ECHO_T}$ac_cv_lib_pthread_pthread_self" >&6
9762if test $ac_cv_lib_pthread_pthread_self = yes; then
9763 HAVE_GTK_AND_PTHREAD=yes
9764fi
9765
9766 fi
9767 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
9768 GTK_LIBS="$GTK_LIBS -lpthread"
9769
9770cat >>confdefs.h <<\_ACEOF
9771#define HAVE_GTK_AND_PTHREAD 1
9772_ACEOF
9773
9774 fi
57669b57 9775 fi
488dd4c4
JD
9776fi
9777
98418dba
CW
9778if test x"${USE_X_TOOLKIT}" = xmaybe; then
9779 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 9780 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
9781echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
9782 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
9783 echo $ECHO_N "(cached) $ECHO_C" >&6
9784else
9785 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9786#line $LINENO "configure"
19650fd6
AS
9787/* confdefs.h. */
9788_ACEOF
9789cat confdefs.h >>conftest.$ac_ext
9790cat >>conftest.$ac_ext <<_ACEOF
9791/* end confdefs.h. */
98418dba
CW
9792
9793#include <X11/Intrinsic.h>
9794#include <X11/Xaw/Simple.h>
98418dba
CW
9795int
9796main ()
9797{
9798
9799 ;
9800 return 0;
9801}
9802_ACEOF
9803rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9804if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9805 (eval $ac_link) 2>&5
98418dba 9806 ac_status=$?
c0d27fcc 9807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9808 (exit $ac_status); } &&
7c9e5167 9809 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9810 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9811 (eval $ac_try) 2>&5
9812 ac_status=$?
c0d27fcc 9813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9814 (exit $ac_status); }; }; then
9815 emacs_cv_x11_version_5_with_xaw=yes
9816else
9817 echo "$as_me: failed program was:" >&5
19650fd6
AS
9818sed 's/^/| /' conftest.$ac_ext >&5
9819
98418dba
CW
9820emacs_cv_x11_version_5_with_xaw=no
9821fi
7c9e5167 9822rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9823fi
9824
9825 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 9826 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
9827echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
9828 USE_X_TOOLKIT=LUCID
9829 else
c0d27fcc 9830 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
9831echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
9832 USE_X_TOOLKIT=none
9833 fi
9834 else
9835 USE_X_TOOLKIT=none
9836 fi
9837fi
9838
9839X_TOOLKIT_TYPE=$USE_X_TOOLKIT
9840
9841if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 9842 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
9843echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
9844 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
9845 echo $ECHO_N "(cached) $ECHO_C" >&6
9846else
9847 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9848#line $LINENO "configure"
19650fd6
AS
9849/* confdefs.h. */
9850_ACEOF
9851cat confdefs.h >>conftest.$ac_ext
9852cat >>conftest.$ac_ext <<_ACEOF
9853/* end confdefs.h. */
98418dba 9854#include <X11/Intrinsic.h>
98418dba
CW
9855int
9856main ()
9857{
9858#if XtSpecificationRelease < 6
9859fail;
9860#endif
9861
9862 ;
9863 return 0;
9864}
9865_ACEOF
9866rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9867if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9868 (eval $ac_link) 2>&5
98418dba 9869 ac_status=$?
c0d27fcc 9870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9871 (exit $ac_status); } &&
7c9e5167 9872 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9873 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9874 (eval $ac_try) 2>&5
9875 ac_status=$?
c0d27fcc 9876 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9877 (exit $ac_status); }; }; then
9878 emacs_cv_x11_toolkit_version_6=yes
9879else
9880 echo "$as_me: failed program was:" >&5
19650fd6
AS
9881sed 's/^/| /' conftest.$ac_ext >&5
9882
98418dba
CW
9883emacs_cv_x11_toolkit_version_6=no
9884fi
7c9e5167 9885rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9886fi
9887
9888 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
9889 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 9890 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 9891echo "${ECHO_T}6 or newer" >&6
b936fae4 9892
c0d27fcc 9893cat >>confdefs.h <<\_ACEOF
98418dba 9894#define HAVE_X11XTR6 1
c0d27fcc 9895_ACEOF
98418dba
CW
9896
9897 else
c0d27fcc 9898 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
9899echo "${ECHO_T}before 6" >&6
9900 fi
9901
9902 OLDLIBS="$LIBS"
9903 if test x$HAVE_X11XTR6 = xyes; then
9904 LIBS="-lXt -lSM -lICE $LIBS"
9905 else
9906 LIBS="-lXt $LIBS"
9907 fi
9908
c0d27fcc 9909echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
9910echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
9911if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
9912 echo $ECHO_N "(cached) $ECHO_C" >&6
9913else
9914 ac_check_lib_save_LIBS=$LIBS
9915LIBS="-lXmu $LIBS"
9916cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9917#line $LINENO "configure"
19650fd6
AS
9918/* confdefs.h. */
9919_ACEOF
9920cat confdefs.h >>conftest.$ac_ext
9921cat >>conftest.$ac_ext <<_ACEOF
9922/* end confdefs.h. */
98418dba
CW
9923
9924/* Override any gcc2 internal prototype to avoid an error. */
9925#ifdef __cplusplus
9926extern "C"
9927#endif
9928/* We use char because int might match the return type of a gcc2
9929 builtin and then its argument prototype would still apply. */
9930char XmuConvertStandardSelection ();
98418dba
CW
9931int
9932main ()
9933{
9934XmuConvertStandardSelection ();
9935 ;
9936 return 0;
9937}
9938_ACEOF
9939rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9940if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 9941 (eval $ac_link) 2>&5
98418dba 9942 ac_status=$?
c0d27fcc 9943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 9944 (exit $ac_status); } &&
7c9e5167 9945 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9946 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9947 (eval $ac_try) 2>&5
9948 ac_status=$?
c0d27fcc 9949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9950 (exit $ac_status); }; }; then
9951 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
9952else
9953 echo "$as_me: failed program was:" >&5
19650fd6
AS
9954sed 's/^/| /' conftest.$ac_ext >&5
9955
98418dba
CW
9956ac_cv_lib_Xmu_XmuConvertStandardSelection=no
9957fi
7c9e5167 9958rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
9959LIBS=$ac_check_lib_save_LIBS
9960fi
c0d27fcc 9961echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
9962echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
9963if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 9964 cat >>confdefs.h <<_ACEOF
98418dba 9965#define HAVE_LIBXMU 1
c0d27fcc 9966_ACEOF
98418dba
CW
9967
9968 LIBS="-lXmu $LIBS"
9969
9970fi
9971
9972 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
9973fi
9974
9975# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
9976if test "${HAVE_X11}" = "yes"; then
9977 if test "${USE_X_TOOLKIT}" != "none"; then
9978
c0d27fcc 9979echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
9980echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
9981if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
9982 echo $ECHO_N "(cached) $ECHO_C" >&6
9983else
9984 ac_check_lib_save_LIBS=$LIBS
9985LIBS="-lXext $LIBS"
9986cat >conftest.$ac_ext <<_ACEOF
7c9e5167 9987#line $LINENO "configure"
19650fd6
AS
9988/* confdefs.h. */
9989_ACEOF
9990cat confdefs.h >>conftest.$ac_ext
9991cat >>conftest.$ac_ext <<_ACEOF
9992/* end confdefs.h. */
98418dba
CW
9993
9994/* Override any gcc2 internal prototype to avoid an error. */
9995#ifdef __cplusplus
9996extern "C"
9997#endif
9998/* We use char because int might match the return type of a gcc2
9999 builtin and then its argument prototype would still apply. */
10000char XShapeQueryExtension ();
98418dba
CW
10001int
10002main ()
10003{
10004XShapeQueryExtension ();
10005 ;
10006 return 0;
10007}
10008_ACEOF
10009rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10010if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 10011 (eval $ac_link) 2>&5
98418dba 10012 ac_status=$?
c0d27fcc 10013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10014 (exit $ac_status); } &&
7c9e5167 10015 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10016 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10017 (eval $ac_try) 2>&5
10018 ac_status=$?
c0d27fcc 10019 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10020 (exit $ac_status); }; }; then
10021 ac_cv_lib_Xext_XShapeQueryExtension=yes
10022else
10023 echo "$as_me: failed program was:" >&5
19650fd6
AS
10024sed 's/^/| /' conftest.$ac_ext >&5
10025
98418dba
CW
10026ac_cv_lib_Xext_XShapeQueryExtension=no
10027fi
7c9e5167 10028rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10029LIBS=$ac_check_lib_save_LIBS
10030fi
c0d27fcc 10031echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
10032echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
10033if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 10034 cat >>confdefs.h <<_ACEOF
98418dba 10035#define HAVE_LIBXEXT 1
c0d27fcc 10036_ACEOF
98418dba
CW
10037
10038 LIBS="-lXext $LIBS"
10039
10040fi
10041
10042 fi
10043fi
10044
10045if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10046 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
10047echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
10048if test "${emacs_cv_motif_version_2_1+set}" = set; then
10049 echo $ECHO_N "(cached) $ECHO_C" >&6
10050else
10051 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10052#line $LINENO "configure"
19650fd6
AS
10053/* confdefs.h. */
10054_ACEOF
10055cat confdefs.h >>conftest.$ac_ext
10056cat >>conftest.$ac_ext <<_ACEOF
10057/* end confdefs.h. */
98418dba 10058#include <Xm/Xm.h>
98418dba
CW
10059int
10060main ()
10061{
10062#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
10063int x = 5;
10064#else
10065Motif version prior to 2.1.
10066#endif
10067 ;
10068 return 0;
10069}
10070_ACEOF
10071rm -f conftest.$ac_objext
c0d27fcc 10072if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10073 (eval $ac_compile) 2>&5
98418dba 10074 ac_status=$?
c0d27fcc 10075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10076 (exit $ac_status); } &&
7c9e5167 10077 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 10078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10079 (eval $ac_try) 2>&5
10080 ac_status=$?
c0d27fcc 10081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10082 (exit $ac_status); }; }; then
10083 emacs_cv_motif_version_2_1=yes
10084else
10085 echo "$as_me: failed program was:" >&5
19650fd6
AS
10086sed 's/^/| /' conftest.$ac_ext >&5
10087
98418dba
CW
10088emacs_cv_motif_version_2_1=no
10089fi
7c9e5167 10090rm -f conftest.$ac_objext conftest.$ac_ext
98418dba 10091fi
c0d27fcc 10092echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
10093echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
10094 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
10095 if test $emacs_cv_motif_version_2_1 = yes; then
10096 HAVE_LIBXP=no
b936fae4 10097
c0d27fcc 10098cat >>confdefs.h <<\_ACEOF
98418dba 10099#define HAVE_MOTIF_2_1 1
c0d27fcc 10100_ACEOF
98418dba 10101
c0d27fcc 10102 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
10103echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
10104if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
10105 echo $ECHO_N "(cached) $ECHO_C" >&6
10106else
10107 ac_check_lib_save_LIBS=$LIBS
10108LIBS="-lXp $LIBS"
10109cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10110#line $LINENO "configure"
19650fd6
AS
10111/* confdefs.h. */
10112_ACEOF
10113cat confdefs.h >>conftest.$ac_ext
10114cat >>conftest.$ac_ext <<_ACEOF
10115/* end confdefs.h. */
98418dba
CW
10116
10117/* Override any gcc2 internal prototype to avoid an error. */
10118#ifdef __cplusplus
10119extern "C"
10120#endif
10121/* We use char because int might match the return type of a gcc2
10122 builtin and then its argument prototype would still apply. */
10123char XpCreateContext ();
98418dba
CW
10124int
10125main ()
10126{
10127XpCreateContext ();
10128 ;
10129 return 0;
10130}
10131_ACEOF
10132rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10133if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 10134 (eval $ac_link) 2>&5
98418dba 10135 ac_status=$?
c0d27fcc 10136 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10137 (exit $ac_status); } &&
7c9e5167 10138 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10139 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
10140 (eval $ac_try) 2>&5
10141 ac_status=$?
c0d27fcc 10142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10143 (exit $ac_status); }; }; then
10144 ac_cv_lib_Xp_XpCreateContext=yes
10145else
10146 echo "$as_me: failed program was:" >&5
19650fd6
AS
10147sed 's/^/| /' conftest.$ac_ext >&5
10148
98418dba
CW
10149ac_cv_lib_Xp_XpCreateContext=no
10150fi
7c9e5167 10151rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
10152LIBS=$ac_check_lib_save_LIBS
10153fi
c0d27fcc 10154echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
10155echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
10156if test $ac_cv_lib_Xp_XpCreateContext = yes; then
10157 HAVE_LIBXP=yes
10158fi
503d2be0 10159
98418dba 10160 if test ${HAVE_LIBXP} = yes; then
b936fae4 10161
c0d27fcc 10162cat >>confdefs.h <<\_ACEOF
98418dba 10163#define HAVE_LIBXP 1
c0d27fcc 10164_ACEOF
503d2be0 10165
98418dba 10166 fi
4693dbc9
SM
10167 else
10168 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
10169echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
10170if test "${emacs_cv_lesstif+set}" = set; then
10171 echo $ECHO_N "(cached) $ECHO_C" >&6
10172else
10173 # We put this in CFLAGS temporarily to precede other -I options
10174 # that might be in CFLAGS temporarily.
10175 # We put this in CPPFLAGS where it precedes the other -I options.
10176 OLD_CPPFLAGS=$CPPFLAGS
10177 OLD_CFLAGS=$CFLAGS
10178 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
10179 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
10180 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10181#line $LINENO "configure"
4693dbc9
SM
10182/* confdefs.h. */
10183_ACEOF
10184cat confdefs.h >>conftest.$ac_ext
10185cat >>conftest.$ac_ext <<_ACEOF
10186/* end confdefs.h. */
10187#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
10188int
10189main ()
10190{
10191int x = 5;
10192 ;
10193 return 0;
10194}
10195_ACEOF
10196rm -f conftest.$ac_objext
10197if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10198 (eval $ac_compile) 2>&5
4693dbc9 10199 ac_status=$?
4693dbc9
SM
10200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10201 (exit $ac_status); } &&
7c9e5167 10202 { ac_try='test -s conftest.$ac_objext'
4693dbc9
SM
10203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10204 (eval $ac_try) 2>&5
10205 ac_status=$?
10206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10207 (exit $ac_status); }; }; then
10208 emacs_cv_lesstif=yes
10209else
10210 echo "$as_me: failed program was:" >&5
10211sed 's/^/| /' conftest.$ac_ext >&5
10212
10213emacs_cv_lesstif=no
10214fi
7c9e5167 10215rm -f conftest.$ac_objext conftest.$ac_ext
4693dbc9
SM
10216fi
10217echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
10218echo "${ECHO_T}$emacs_cv_lesstif" >&6
10219 if test $emacs_cv_lesstif = yes; then
10220 # Make sure this -I option remains in CPPFLAGS after it is set
10221 # back to REAL_CPPFLAGS.
10222 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
10223 # have those other -I options anyway. Ultimately, having this
10224 # directory ultimately in CPPFLAGS will be enough.
10225 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
10226 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
10227 else
10228 CFLAGS=$OLD_CFLAGS
10229 CPPFLAGS=$OLD_CPPFLAGS
10230 fi
98418dba
CW
10231 fi
10232fi
10233
10234### Is -lXaw3d available?
10235HAVE_XAW3D=no
10236if test "${HAVE_X11}" = "yes"; then
10237 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 10238 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
10239echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
10240if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
10241 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 10242else
22044edf 10243 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10244#line $LINENO "configure"
19650fd6
AS
10245/* confdefs.h. */
10246_ACEOF
10247cat confdefs.h >>conftest.$ac_ext
10248cat >>conftest.$ac_ext <<_ACEOF
10249/* end confdefs.h. */
98418dba 10250#include <X11/Xaw3d/Scrollbar.h>
503d2be0 10251_ACEOF
c0d27fcc 10252if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
10253 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10254 ac_status=$?
6bae0ccf 10255 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
10256 rm -f conftest.er1
10257 cat conftest.err >&5
c0d27fcc 10258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10259 (exit $ac_status); } >/dev/null; then
10260 if test -s conftest.err; then
10261 ac_cpp_err=$ac_c_preproc_warn_flag
10262 else
10263 ac_cpp_err=
10264 fi
10265else
10266 ac_cpp_err=yes
10267fi
10268if test -z "$ac_cpp_err"; then
22044edf 10269 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 10270else
503d2be0 10271 echo "$as_me: failed program was:" >&5
19650fd6
AS
10272sed 's/^/| /' conftest.$ac_ext >&5
10273
22044edf 10274 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 10275fi
503d2be0 10276rm -f conftest.err conftest.$ac_ext
98418dba 10277fi
c0d27fcc 10278echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 10279echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 10280if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 10281 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
10282echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
10283if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
10284 echo $ECHO_N "(cached) $ECHO_C" >&6
10285else
10286 ac_check_lib_save_LIBS=$LIBS
10287LIBS="-lXaw3d $LIBS"
10288cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10289#line $LINENO "configure"
19650fd6
AS
10290/* confdefs.h. */
10291_ACEOF
10292cat confdefs.h >>conftest.$ac_ext
10293cat >>conftest.$ac_ext <<_ACEOF
10294/* end confdefs.h. */
98418dba
CW
10295
10296/* Override any gcc2 internal prototype to avoid an error. */
10297#ifdef __cplusplus
10298extern "C"
10299#endif
10300/* We use char because int might match the return type of a gcc2
10301 builtin and then its argument prototype would still apply. */
10302char XawScrollbarSetThumb ();
503d2be0
AS
10303int
10304main ()
10305{
98418dba 10306XawScrollbarSetThumb ();
503d2be0
AS
10307 ;
10308 return 0;
10309}
10310_ACEOF
10311rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10312if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 10313 (eval $ac_link) 2>&5
503d2be0 10314 ac_status=$?
c0d27fcc 10315 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10316 (exit $ac_status); } &&
7c9e5167 10317 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10318 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10319 (eval $ac_try) 2>&5
10320 ac_status=$?
c0d27fcc 10321 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10322 (exit $ac_status); }; }; then
98418dba 10323 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 10324else
503d2be0 10325 echo "$as_me: failed program was:" >&5
19650fd6
AS
10326sed 's/^/| /' conftest.$ac_ext >&5
10327
98418dba 10328ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 10329fi
7c9e5167 10330rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10331LIBS=$ac_check_lib_save_LIBS
ba4481b5 10332fi
c0d27fcc 10333echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
10334echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
10335if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
10336 HAVE_XAW3D=yes
ba4481b5 10337fi
503d2be0 10338
ba4481b5
DL
10339fi
10340
c0d27fcc 10341
98418dba 10342 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 10343
c0d27fcc 10344cat >>confdefs.h <<\_ACEOF
98418dba 10345#define HAVE_XAW3D 1
c0d27fcc 10346_ACEOF
98418dba 10347
ba4481b5 10348 fi
98418dba 10349 fi
ba4481b5
DL
10350fi
10351
c0d27fcc
MR
10352
10353
98418dba
CW
10354USE_TOOLKIT_SCROLL_BARS=no
10355if test "${with_toolkit_scroll_bars}" != "no"; then
10356 if test "${USE_X_TOOLKIT}" != "none"; then
10357 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 10358 cat >>confdefs.h <<\_ACEOF
98418dba 10359#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10360_ACEOF
98418dba
CW
10361
10362 HAVE_XAW3D=no
10363 USE_TOOLKIT_SCROLL_BARS=yes
10364 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 10365 cat >>confdefs.h <<\_ACEOF
98418dba 10366#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 10367_ACEOF
98418dba
CW
10368
10369 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 10370 fi
488dd4c4
JD
10371 elif test "${HAVE_GTK}" = "yes"; then
10372 cat >>confdefs.h <<\_ACEOF
10373#define USE_TOOLKIT_SCROLL_BARS 1
5d6da11e
YM
10374_ACEOF
10375
10376 USE_TOOLKIT_SCROLL_BARS=yes
10377 elif test "${HAVE_CARBON}" = "yes"; then
10378 cat >>confdefs.h <<\_ACEOF
10379#define USE_TOOLKIT_SCROLL_BARS 1
488dd4c4
JD
10380_ACEOF
10381
10382 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
10383 fi
10384fi
10385
abd39b57 10386cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10387#line $LINENO "configure"
abd39b57
AC
10388/* confdefs.h. */
10389_ACEOF
10390cat confdefs.h >>conftest.$ac_ext
10391cat >>conftest.$ac_ext <<_ACEOF
10392/* end confdefs.h. */
10393
10394 #include <X11/Xlib.h>
10395 #include <X11/Xresource.h>
10396int
10397main ()
10398{
10399XIMProc callback;
10400 ;
10401 return 0;
10402}
10403_ACEOF
10404rm -f conftest.$ac_objext
10405if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10406 (eval $ac_compile) 2>&5
abd39b57
AC
10407 ac_status=$?
10408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10409 (exit $ac_status); } &&
7c9e5167 10410 { ac_try='test -s conftest.$ac_objext'
abd39b57
AC
10411 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10412 (eval $ac_try) 2>&5
10413 ac_status=$?
10414 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10415 (exit $ac_status); }; }; then
10416 HAVE_XIM=yes
10417
10418cat >>confdefs.h <<\_ACEOF
10419#define HAVE_XIM 1
10420_ACEOF
10421
10422else
10423 echo "$as_me: failed program was:" >&5
10424sed 's/^/| /' conftest.$ac_ext >&5
10425
10426HAVE_XIM=no
10427fi
7c9e5167 10428rm -f conftest.$ac_objext conftest.$ac_ext
abd39b57 10429
c0d27fcc 10430
98418dba 10431if test "${with_xim}" != "no"; then
b936fae4 10432
c0d27fcc 10433cat >>confdefs.h <<\_ACEOF
98418dba 10434#define USE_XIM 1
c0d27fcc 10435_ACEOF
98418dba 10436
793fa0d7 10437fi
abd39b57
AC
10438
10439
10440if test "${HAVE_XIM}" != "no"; then
849d80cf
DL
10441 late_CFLAGS=$CFLAGS
10442 if test "$GCC" = yes; then
10443 CFLAGS="$CFLAGS --pedantic-errors"
10444 fi
cffcede7 10445 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10446#line $LINENO "configure"
19650fd6
AS
10447/* confdefs.h. */
10448_ACEOF
10449cat confdefs.h >>conftest.$ac_ext
10450cat >>conftest.$ac_ext <<_ACEOF
10451/* end confdefs.h. */
cffcede7
JD
10452
10453#include <X11/Xlib.h>
10454#include <X11/Xresource.h>
10455int
10456main ()
10457{
10458Display *display;
10459XrmDatabase db;
10460char *res_name;
10461char *res_class;
10462XIMProc callback;
10463XPointer *client_data;
849d80cf
DL
10464#ifndef __GNUC__
10465/* If we're not using GCC, it's probably not XFree86, and this is
10466 probably right, but we can't use something like --pedantic-errors. */
10467extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
10468 char*, XIMProc, XPointer*);
10469#endif
cffcede7
JD
10470(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
10471 client_data);
10472 ;
10473 return 0;
10474}
10475_ACEOF
10476rm -f conftest.$ac_objext
10477if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10478 (eval $ac_compile) 2>&5
cffcede7
JD
10479 ac_status=$?
10480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10481 (exit $ac_status); } &&
7c9e5167 10482 { ac_try='test -s conftest.$ac_objext'
cffcede7
JD
10483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10484 (eval $ac_try) 2>&5
10485 ac_status=$?
10486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10487 (exit $ac_status); }; }; then
10488 emacs_cv_arg6_star=yes
10489else
10490 echo "$as_me: failed program was:" >&5
19650fd6
AS
10491sed 's/^/| /' conftest.$ac_ext >&5
10492
cffcede7 10493fi
7c9e5167 10494rm -f conftest.$ac_objext conftest.$ac_ext
cffcede7
JD
10495
10496 if test "$emacs_cv_arg6_star" = yes; then
f57bd967 10497 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10498#define XRegisterIMInstantiateCallback_arg6 XPointer*
10499_ACEOF
10500
10501 else
f57bd967 10502 cat >>confdefs.h <<\_ACEOF
cffcede7
JD
10503#define XRegisterIMInstantiateCallback_arg6 XPointer
10504_ACEOF
10505
10506 fi
849d80cf 10507 CFLAGS=$late_CFLAGS
98418dba
CW
10508fi
10509
10510### Use -lXpm if available, unless `--with-xpm=no'.
10511HAVE_XPM=no
10512if test "${HAVE_X11}" = "yes"; then
10513 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
10514 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10515 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
10516echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10517if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10518 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10519fi
10520echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
10521echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 10522else
c0d27fcc
MR
10523 # Is the header compilable?
10524echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
10525echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
10526cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10527#line $LINENO "configure"
19650fd6
AS
10528/* confdefs.h. */
10529_ACEOF
10530cat confdefs.h >>conftest.$ac_ext
10531cat >>conftest.$ac_ext <<_ACEOF
10532/* end confdefs.h. */
c0d27fcc
MR
10533$ac_includes_default
10534#include <X11/xpm.h>
10535_ACEOF
10536rm -f conftest.$ac_objext
10537if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10538 (eval $ac_compile) 2>&5
c0d27fcc
MR
10539 ac_status=$?
10540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10541 (exit $ac_status); } &&
7c9e5167 10542 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10544 (eval $ac_try) 2>&5
10545 ac_status=$?
10546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10547 (exit $ac_status); }; }; then
10548 ac_header_compiler=yes
10549else
10550 echo "$as_me: failed program was:" >&5
19650fd6
AS
10551sed 's/^/| /' conftest.$ac_ext >&5
10552
c0d27fcc
MR
10553ac_header_compiler=no
10554fi
7c9e5167 10555rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10556echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10557echo "${ECHO_T}$ac_header_compiler" >&6
10558
10559# Is the header present?
10560echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
10561echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
10562cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10563#line $LINENO "configure"
19650fd6
AS
10564/* confdefs.h. */
10565_ACEOF
10566cat confdefs.h >>conftest.$ac_ext
10567cat >>conftest.$ac_ext <<_ACEOF
10568/* end confdefs.h. */
98418dba
CW
10569#include <X11/xpm.h>
10570_ACEOF
c0d27fcc 10571if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10572 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10573 ac_status=$?
6bae0ccf 10574 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10575 rm -f conftest.er1
10576 cat conftest.err >&5
c0d27fcc 10577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10578 (exit $ac_status); } >/dev/null; then
10579 if test -s conftest.err; then
10580 ac_cpp_err=$ac_c_preproc_warn_flag
10581 else
10582 ac_cpp_err=
10583 fi
10584else
10585 ac_cpp_err=yes
10586fi
10587if test -z "$ac_cpp_err"; then
c0d27fcc 10588 ac_header_preproc=yes
98418dba
CW
10589else
10590 echo "$as_me: failed program was:" >&5
19650fd6
AS
10591sed 's/^/| /' conftest.$ac_ext >&5
10592
c0d27fcc 10593 ac_header_preproc=no
98418dba
CW
10594fi
10595rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10596echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10597echo "${ECHO_T}$ac_header_preproc" >&6
10598
10599# So? What about this header?
7c9e5167
JD
10600case $ac_header_compiler:$ac_header_preproc in
10601 yes:no )
c0d27fcc
MR
10602 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
10603echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
10604 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
10605echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
10606 (
10607 cat <<\_ASBOX
10608## ------------------------------------ ##
10609## Report this to bug-autoconf@gnu.org. ##
10610## ------------------------------------ ##
10611_ASBOX
10612 ) |
10613 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 10614 ;;
7c9e5167 10615 no:yes )
c0d27fcc
MR
10616 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
10617echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
7c9e5167
JD
10618 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
10619echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 10620 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
19650fd6 10621echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
10622 (
10623 cat <<\_ASBOX
7c9e5167
JD
10624## ------------------------------------ ##
10625## Report this to bug-autoconf@gnu.org. ##
10626## ------------------------------------ ##
19650fd6
AS
10627_ASBOX
10628 ) |
10629 sed "s/^/$as_me: WARNING: /" >&2
10630 ;;
c0d27fcc
MR
10631esac
10632echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
10633echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
10634if test "${ac_cv_header_X11_xpm_h+set}" = set; then
10635 echo $ECHO_N "(cached) $ECHO_C" >&6
10636else
10637 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 10638fi
c0d27fcc 10639echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 10640echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
10641
10642fi
98418dba 10643if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 10644 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
10645echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
10646if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 10647 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10648else
98418dba
CW
10649 ac_check_lib_save_LIBS=$LIBS
10650LIBS="-lXpm -lX11 $LIBS"
10651cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10652#line $LINENO "configure"
19650fd6
AS
10653/* confdefs.h. */
10654_ACEOF
10655cat confdefs.h >>conftest.$ac_ext
10656cat >>conftest.$ac_ext <<_ACEOF
10657/* end confdefs.h. */
98418dba 10658
ba4481b5 10659/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10660#ifdef __cplusplus
10661extern "C"
10662#endif
ba4481b5 10663/* We use char because int might match the return type of a gcc2
503d2be0 10664 builtin and then its argument prototype would still apply. */
98418dba 10665char XpmReadFileToPixmap ();
503d2be0
AS
10666int
10667main ()
10668{
98418dba 10669XpmReadFileToPixmap ();
503d2be0
AS
10670 ;
10671 return 0;
10672}
10673_ACEOF
10674rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10675if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 10676 (eval $ac_link) 2>&5
503d2be0 10677 ac_status=$?
c0d27fcc 10678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10679 (exit $ac_status); } &&
7c9e5167 10680 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10682 (eval $ac_try) 2>&5
10683 ac_status=$?
c0d27fcc 10684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10685 (exit $ac_status); }; }; then
98418dba 10686 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
10687else
10688 echo "$as_me: failed program was:" >&5
19650fd6
AS
10689sed 's/^/| /' conftest.$ac_ext >&5
10690
98418dba 10691ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0 10692fi
7c9e5167 10693rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10694LIBS=$ac_check_lib_save_LIBS
503d2be0 10695fi
c0d27fcc 10696echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
10697echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
10698if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
10699 HAVE_XPM=yes
ba4481b5
DL
10700fi
10701
98418dba
CW
10702fi
10703
c0d27fcc 10704
98418dba 10705 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10706 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
10707echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
10708 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10709#line $LINENO "configure"
19650fd6
AS
10710/* confdefs.h. */
10711_ACEOF
10712cat confdefs.h >>conftest.$ac_ext
10713cat >>conftest.$ac_ext <<_ACEOF
10714/* end confdefs.h. */
98418dba
CW
10715#include "X11/xpm.h"
10716#ifndef XpmReturnAllocPixels
10717no_return_alloc_pixels
503d2be0 10718#endif
ba4481b5 10719
98418dba
CW
10720_ACEOF
10721if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10722 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
10723 HAVE_XPM=no
10724else
10725 HAVE_XPM=yes
10726fi
10727rm -f conftest*
ba4481b5 10728
c0d27fcc 10729
98418dba 10730 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 10731 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
10732echo "${ECHO_T}yes" >&6
10733 else
c0d27fcc 10734 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
10735echo "${ECHO_T}no" >&6
10736 fi
10737 fi
10738 fi
10739
10740 if test "${HAVE_XPM}" = "yes"; then
b936fae4 10741
c0d27fcc 10742cat >>confdefs.h <<\_ACEOF
98418dba 10743#define HAVE_XPM 1
c0d27fcc 10744_ACEOF
98418dba
CW
10745
10746 fi
10747fi
10748
10749### Use -ljpeg if available, unless `--with-jpeg=no'.
10750HAVE_JPEG=no
10751if test "${HAVE_X11}" = "yes"; then
10752 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
10753 if test "${ac_cv_header_jerror_h+set}" = set; then
10754 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
10755echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
10756if test "${ac_cv_header_jerror_h+set}" = set; then
10757 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10758fi
10759echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
10760echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 10761else
c0d27fcc
MR
10762 # Is the header compilable?
10763echo "$as_me:$LINENO: checking jerror.h usability" >&5
10764echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
10765cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10766#line $LINENO "configure"
19650fd6
AS
10767/* confdefs.h. */
10768_ACEOF
10769cat confdefs.h >>conftest.$ac_ext
10770cat >>conftest.$ac_ext <<_ACEOF
10771/* end confdefs.h. */
c0d27fcc
MR
10772$ac_includes_default
10773#include <jerror.h>
10774_ACEOF
10775rm -f conftest.$ac_objext
10776if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 10777 (eval $ac_compile) 2>&5
c0d27fcc
MR
10778 ac_status=$?
10779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10780 (exit $ac_status); } &&
7c9e5167 10781 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
10782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10783 (eval $ac_try) 2>&5
10784 ac_status=$?
10785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10786 (exit $ac_status); }; }; then
10787 ac_header_compiler=yes
10788else
10789 echo "$as_me: failed program was:" >&5
19650fd6
AS
10790sed 's/^/| /' conftest.$ac_ext >&5
10791
c0d27fcc
MR
10792ac_header_compiler=no
10793fi
7c9e5167 10794rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
10795echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10796echo "${ECHO_T}$ac_header_compiler" >&6
10797
10798# Is the header present?
10799echo "$as_me:$LINENO: checking jerror.h presence" >&5
10800echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
10801cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10802#line $LINENO "configure"
19650fd6
AS
10803/* confdefs.h. */
10804_ACEOF
10805cat confdefs.h >>conftest.$ac_ext
10806cat >>conftest.$ac_ext <<_ACEOF
10807/* end confdefs.h. */
98418dba
CW
10808#include <jerror.h>
10809_ACEOF
c0d27fcc 10810if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10811 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10812 ac_status=$?
6bae0ccf 10813 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10814 rm -f conftest.er1
10815 cat conftest.err >&5
c0d27fcc 10816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10817 (exit $ac_status); } >/dev/null; then
10818 if test -s conftest.err; then
10819 ac_cpp_err=$ac_c_preproc_warn_flag
10820 else
10821 ac_cpp_err=
10822 fi
10823else
10824 ac_cpp_err=yes
503d2be0 10825fi
98418dba 10826if test -z "$ac_cpp_err"; then
c0d27fcc 10827 ac_header_preproc=yes
ba4481b5 10828else
98418dba 10829 echo "$as_me: failed program was:" >&5
19650fd6
AS
10830sed 's/^/| /' conftest.$ac_ext >&5
10831
c0d27fcc 10832 ac_header_preproc=no
98418dba
CW
10833fi
10834rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10835echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10836echo "${ECHO_T}$ac_header_preproc" >&6
10837
10838# So? What about this header?
7c9e5167
JD
10839case $ac_header_compiler:$ac_header_preproc in
10840 yes:no )
c0d27fcc
MR
10841 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
10842echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
10843 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
10844echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
10845 (
10846 cat <<\_ASBOX
10847## ------------------------------------ ##
10848## Report this to bug-autoconf@gnu.org. ##
10849## ------------------------------------ ##
10850_ASBOX
10851 ) |
10852 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 10853 ;;
7c9e5167 10854 no:yes )
c0d27fcc
MR
10855 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
10856echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
7c9e5167
JD
10857 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
10858echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 10859 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
19650fd6 10860echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
10861 (
10862 cat <<\_ASBOX
7c9e5167
JD
10863## ------------------------------------ ##
10864## Report this to bug-autoconf@gnu.org. ##
10865## ------------------------------------ ##
19650fd6
AS
10866_ASBOX
10867 ) |
10868 sed "s/^/$as_me: WARNING: /" >&2
10869 ;;
c0d27fcc
MR
10870esac
10871echo "$as_me:$LINENO: checking for jerror.h" >&5
10872echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
10873if test "${ac_cv_header_jerror_h+set}" = set; then
10874 echo $ECHO_N "(cached) $ECHO_C" >&6
10875else
10876 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 10877fi
c0d27fcc 10878echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 10879echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
10880
10881fi
98418dba 10882if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 10883 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
10884echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
10885if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 10886 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10887else
98418dba
CW
10888 ac_check_lib_save_LIBS=$LIBS
10889LIBS="-ljpeg $LIBS"
10890cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10891#line $LINENO "configure"
19650fd6
AS
10892/* confdefs.h. */
10893_ACEOF
10894cat confdefs.h >>conftest.$ac_ext
10895cat >>conftest.$ac_ext <<_ACEOF
10896/* end confdefs.h. */
98418dba
CW
10897
10898/* Override any gcc2 internal prototype to avoid an error. */
10899#ifdef __cplusplus
10900extern "C"
10901#endif
10902/* We use char because int might match the return type of a gcc2
10903 builtin and then its argument prototype would still apply. */
10904char jpeg_destroy_compress ();
503d2be0
AS
10905int
10906main ()
10907{
98418dba 10908jpeg_destroy_compress ();
503d2be0
AS
10909 ;
10910 return 0;
10911}
10912_ACEOF
10913rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10914if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 10915 (eval $ac_link) 2>&5
503d2be0 10916 ac_status=$?
c0d27fcc 10917 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10918 (exit $ac_status); } &&
7c9e5167 10919 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10920 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10921 (eval $ac_try) 2>&5
10922 ac_status=$?
c0d27fcc 10923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10924 (exit $ac_status); }; }; then
98418dba 10925 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 10926else
503d2be0 10927 echo "$as_me: failed program was:" >&5
19650fd6
AS
10928sed 's/^/| /' conftest.$ac_ext >&5
10929
98418dba 10930ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 10931fi
7c9e5167 10932rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10933LIBS=$ac_check_lib_save_LIBS
ba4481b5 10934fi
c0d27fcc 10935echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
10936echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
10937if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
10938 HAVE_JPEG=yes
ba4481b5 10939fi
98418dba 10940
ba4481b5 10941fi
98418dba 10942
c0d27fcc 10943
ba4481b5 10944 fi
ba4481b5 10945
c0d27fcc 10946
98418dba 10947 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 10948 cat >>confdefs.h <<\_ACEOF
98418dba 10949#define HAVE_JPEG 1
c0d27fcc 10950_ACEOF
98418dba
CW
10951
10952 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 10953#line $LINENO "configure"
19650fd6
AS
10954/* confdefs.h. */
10955_ACEOF
10956cat confdefs.h >>conftest.$ac_ext
10957cat >>conftest.$ac_ext <<_ACEOF
10958/* end confdefs.h. */
22044edf 10959#include <jpeglib.h>
98418dba
CW
10960 version=JPEG_LIB_VERSION
10961
10962_ACEOF
10963if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10964 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 10965 cat >>confdefs.h <<\_ACEOF
98418dba 10966#define HAVE_JPEG 1
c0d27fcc 10967_ACEOF
ba4481b5 10968
98418dba 10969else
c0d27fcc 10970 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
10971echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
10972 HAVE_JPEG=no
ba4481b5 10973fi
98418dba 10974rm -f conftest*
ba4481b5 10975
98418dba
CW
10976 fi
10977fi
503d2be0 10978
98418dba
CW
10979### Use -lpng if available, unless `--with-png=no'.
10980HAVE_PNG=no
10981if test "${HAVE_X11}" = "yes"; then
10982 if test "${with_png}" != "no"; then
f57bd967
DL
10983 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
10984 # in /usr/include/libpng.
10985
10986
10987for ac_header in png.h libpng/png.h
10988do
10989as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10990if eval "test \"\${$as_ac_Header+set}\" = set"; then
10991 echo "$as_me:$LINENO: checking for $ac_header" >&5
10992echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10993if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 10994 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc 10995fi
f57bd967
DL
10996echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10997echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
503d2be0 10998else
c0d27fcc 10999 # Is the header compilable?
f57bd967
DL
11000echo "$as_me:$LINENO: checking $ac_header usability" >&5
11001echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
c0d27fcc 11002cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11003#line $LINENO "configure"
19650fd6
AS
11004/* confdefs.h. */
11005_ACEOF
11006cat confdefs.h >>conftest.$ac_ext
11007cat >>conftest.$ac_ext <<_ACEOF
11008/* end confdefs.h. */
c0d27fcc 11009$ac_includes_default
f57bd967 11010#include <$ac_header>
c0d27fcc
MR
11011_ACEOF
11012rm -f conftest.$ac_objext
11013if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 11014 (eval $ac_compile) 2>&5
c0d27fcc
MR
11015 ac_status=$?
11016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11017 (exit $ac_status); } &&
7c9e5167 11018 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11019 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11020 (eval $ac_try) 2>&5
11021 ac_status=$?
11022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11023 (exit $ac_status); }; }; then
11024 ac_header_compiler=yes
11025else
11026 echo "$as_me: failed program was:" >&5
19650fd6
AS
11027sed 's/^/| /' conftest.$ac_ext >&5
11028
c0d27fcc
MR
11029ac_header_compiler=no
11030fi
7c9e5167 11031rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11032echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11033echo "${ECHO_T}$ac_header_compiler" >&6
11034
11035# Is the header present?
f57bd967
DL
11036echo "$as_me:$LINENO: checking $ac_header presence" >&5
11037echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
c0d27fcc 11038cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11039#line $LINENO "configure"
19650fd6
AS
11040/* confdefs.h. */
11041_ACEOF
11042cat confdefs.h >>conftest.$ac_ext
11043cat >>conftest.$ac_ext <<_ACEOF
11044/* end confdefs.h. */
f57bd967 11045#include <$ac_header>
503d2be0 11046_ACEOF
c0d27fcc 11047if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11048 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11049 ac_status=$?
6bae0ccf 11050 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11051 rm -f conftest.er1
11052 cat conftest.err >&5
c0d27fcc 11053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11054 (exit $ac_status); } >/dev/null; then
11055 if test -s conftest.err; then
11056 ac_cpp_err=$ac_c_preproc_warn_flag
11057 else
11058 ac_cpp_err=
11059 fi
11060else
11061 ac_cpp_err=yes
11062fi
11063if test -z "$ac_cpp_err"; then
c0d27fcc 11064 ac_header_preproc=yes
503d2be0
AS
11065else
11066 echo "$as_me: failed program was:" >&5
19650fd6
AS
11067sed 's/^/| /' conftest.$ac_ext >&5
11068
c0d27fcc 11069 ac_header_preproc=no
ba4481b5 11070fi
503d2be0 11071rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11072echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11073echo "${ECHO_T}$ac_header_preproc" >&6
11074
11075# So? What about this header?
7c9e5167
JD
11076case $ac_header_compiler:$ac_header_preproc in
11077 yes:no )
f57bd967
DL
11078 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11079echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
11080 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11081echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11082 (
11083 cat <<\_ASBOX
11084## ------------------------------------ ##
11085## Report this to bug-autoconf@gnu.org. ##
11086## ------------------------------------ ##
11087_ASBOX
11088 ) |
11089 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 11090 ;;
7c9e5167 11091 no:yes )
f57bd967
DL
11092 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11093echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
11094 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11095echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
f57bd967 11096 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 11097echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
11098 (
11099 cat <<\_ASBOX
7c9e5167
JD
11100## ------------------------------------ ##
11101## Report this to bug-autoconf@gnu.org. ##
11102## ------------------------------------ ##
19650fd6
AS
11103_ASBOX
11104 ) |
11105 sed "s/^/$as_me: WARNING: /" >&2
11106 ;;
c0d27fcc 11107esac
f57bd967
DL
11108echo "$as_me:$LINENO: checking for $ac_header" >&5
11109echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11110if eval "test \"\${$as_ac_Header+set}\" = set"; then
c0d27fcc
MR
11111 echo $ECHO_N "(cached) $ECHO_C" >&6
11112else
7c9e5167 11113 eval "$as_ac_Header=$ac_header_preproc"
f57bd967
DL
11114fi
11115echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11116echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
11117
ba4481b5 11118fi
f57bd967
DL
11119if test `eval echo '${'$as_ac_Header'}'` = yes; then
11120 cat >>confdefs.h <<_ACEOF
11121#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11122_ACEOF
c0d27fcc
MR
11123
11124fi
f57bd967
DL
11125
11126done
11127
11128 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
11129 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
11130echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
11131if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 11132 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11133else
98418dba
CW
11134 ac_check_lib_save_LIBS=$LIBS
11135LIBS="-lpng -lz -lm $LIBS"
11136cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11137#line $LINENO "configure"
19650fd6
AS
11138/* confdefs.h. */
11139_ACEOF
11140cat confdefs.h >>conftest.$ac_ext
11141cat >>conftest.$ac_ext <<_ACEOF
11142/* end confdefs.h. */
98418dba 11143
ba4481b5 11144/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11145#ifdef __cplusplus
11146extern "C"
11147#endif
ba4481b5 11148/* We use char because int might match the return type of a gcc2
503d2be0 11149 builtin and then its argument prototype would still apply. */
98418dba 11150char png_get_channels ();
503d2be0
AS
11151int
11152main ()
11153{
98418dba 11154png_get_channels ();
503d2be0
AS
11155 ;
11156 return 0;
11157}
11158_ACEOF
11159rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11160if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 11161 (eval $ac_link) 2>&5
503d2be0 11162 ac_status=$?
c0d27fcc 11163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11164 (exit $ac_status); } &&
7c9e5167 11165 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11166 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11167 (eval $ac_try) 2>&5
11168 ac_status=$?
c0d27fcc 11169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11170 (exit $ac_status); }; }; then
98418dba 11171 ac_cv_lib_png_png_get_channels=yes
73b77ee5 11172else
98418dba 11173 echo "$as_me: failed program was:" >&5
19650fd6
AS
11174sed 's/^/| /' conftest.$ac_ext >&5
11175
98418dba 11176ac_cv_lib_png_png_get_channels=no
73b77ee5 11177fi
7c9e5167 11178rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 11179LIBS=$ac_check_lib_save_LIBS
73b77ee5 11180fi
c0d27fcc 11181echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
11182echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
11183if test $ac_cv_lib_png_png_get_channels = yes; then
11184 HAVE_PNG=yes
73b77ee5 11185fi
503d2be0 11186
f57bd967 11187 fi
98418dba
CW
11188 fi
11189
11190 if test "${HAVE_PNG}" = "yes"; then
b936fae4 11191
c0d27fcc 11192cat >>confdefs.h <<\_ACEOF
98418dba 11193#define HAVE_PNG 1
c0d27fcc 11194_ACEOF
73b77ee5 11195
98418dba 11196 fi
73b77ee5
GM
11197fi
11198
98418dba
CW
11199### Use -ltiff if available, unless `--with-tiff=no'.
11200HAVE_TIFF=no
11201if test "${HAVE_X11}" = "yes"; then
11202 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
11203 if test "${ac_cv_header_tiffio_h+set}" = set; then
11204 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
11205echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11206if test "${ac_cv_header_tiffio_h+set}" = set; then
11207 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11208fi
11209echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
11210echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 11211else
c0d27fcc
MR
11212 # Is the header compilable?
11213echo "$as_me:$LINENO: checking tiffio.h usability" >&5
11214echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
11215cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11216#line $LINENO "configure"
19650fd6
AS
11217/* confdefs.h. */
11218_ACEOF
11219cat confdefs.h >>conftest.$ac_ext
11220cat >>conftest.$ac_ext <<_ACEOF
11221/* end confdefs.h. */
c0d27fcc
MR
11222$ac_includes_default
11223#include <tiffio.h>
11224_ACEOF
11225rm -f conftest.$ac_objext
11226if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 11227 (eval $ac_compile) 2>&5
c0d27fcc
MR
11228 ac_status=$?
11229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11230 (exit $ac_status); } &&
7c9e5167 11231 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11232 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11233 (eval $ac_try) 2>&5
11234 ac_status=$?
11235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11236 (exit $ac_status); }; }; then
11237 ac_header_compiler=yes
11238else
11239 echo "$as_me: failed program was:" >&5
19650fd6
AS
11240sed 's/^/| /' conftest.$ac_ext >&5
11241
c0d27fcc
MR
11242ac_header_compiler=no
11243fi
7c9e5167 11244rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11245echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11246echo "${ECHO_T}$ac_header_compiler" >&6
11247
11248# Is the header present?
11249echo "$as_me:$LINENO: checking tiffio.h presence" >&5
11250echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
11251cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11252#line $LINENO "configure"
19650fd6
AS
11253/* confdefs.h. */
11254_ACEOF
11255cat confdefs.h >>conftest.$ac_ext
11256cat >>conftest.$ac_ext <<_ACEOF
11257/* end confdefs.h. */
98418dba
CW
11258#include <tiffio.h>
11259_ACEOF
c0d27fcc 11260if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11261 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11262 ac_status=$?
6bae0ccf 11263 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11264 rm -f conftest.er1
11265 cat conftest.err >&5
c0d27fcc 11266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11267 (exit $ac_status); } >/dev/null; then
11268 if test -s conftest.err; then
11269 ac_cpp_err=$ac_c_preproc_warn_flag
11270 else
11271 ac_cpp_err=
11272 fi
11273else
11274 ac_cpp_err=yes
11275fi
11276if test -z "$ac_cpp_err"; then
c0d27fcc 11277 ac_header_preproc=yes
98418dba
CW
11278else
11279 echo "$as_me: failed program was:" >&5
19650fd6
AS
11280sed 's/^/| /' conftest.$ac_ext >&5
11281
c0d27fcc 11282 ac_header_preproc=no
98418dba
CW
11283fi
11284rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11285echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11286echo "${ECHO_T}$ac_header_preproc" >&6
11287
11288# So? What about this header?
7c9e5167
JD
11289case $ac_header_compiler:$ac_header_preproc in
11290 yes:no )
c0d27fcc
MR
11291 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
11292echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
11293 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
11294echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
11295 (
11296 cat <<\_ASBOX
11297## ------------------------------------ ##
11298## Report this to bug-autoconf@gnu.org. ##
11299## ------------------------------------ ##
11300_ASBOX
11301 ) |
11302 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 11303 ;;
7c9e5167 11304 no:yes )
c0d27fcc
MR
11305 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
11306echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
7c9e5167
JD
11307 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
11308echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 11309 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
19650fd6 11310echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
11311 (
11312 cat <<\_ASBOX
7c9e5167
JD
11313## ------------------------------------ ##
11314## Report this to bug-autoconf@gnu.org. ##
11315## ------------------------------------ ##
19650fd6
AS
11316_ASBOX
11317 ) |
11318 sed "s/^/$as_me: WARNING: /" >&2
11319 ;;
c0d27fcc
MR
11320esac
11321echo "$as_me:$LINENO: checking for tiffio.h" >&5
11322echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
11323if test "${ac_cv_header_tiffio_h+set}" = set; then
11324 echo $ECHO_N "(cached) $ECHO_C" >&6
11325else
11326 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 11327fi
c0d27fcc 11328echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 11329echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
11330
11331fi
98418dba
CW
11332if test $ac_cv_header_tiffio_h = yes; then
11333 tifflibs="-lz -lm"
11334 # At least one tiff package requires the jpeg library.
11335 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 11336 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
11337echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
11338if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 11339 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11340else
503d2be0 11341 ac_check_lib_save_LIBS=$LIBS
98418dba 11342LIBS="-ltiff $tifflibs $LIBS"
503d2be0 11343cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11344#line $LINENO "configure"
19650fd6
AS
11345/* confdefs.h. */
11346_ACEOF
11347cat confdefs.h >>conftest.$ac_ext
11348cat >>conftest.$ac_ext <<_ACEOF
11349/* end confdefs.h. */
503d2be0 11350
73b77ee5 11351/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11352#ifdef __cplusplus
11353extern "C"
11354#endif
73b77ee5 11355/* We use char because int might match the return type of a gcc2
503d2be0 11356 builtin and then its argument prototype would still apply. */
98418dba 11357char TIFFGetVersion ();
503d2be0
AS
11358int
11359main ()
11360{
98418dba 11361TIFFGetVersion ();
503d2be0
AS
11362 ;
11363 return 0;
11364}
11365_ACEOF
11366rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11367if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 11368 (eval $ac_link) 2>&5
503d2be0 11369 ac_status=$?
c0d27fcc 11370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11371 (exit $ac_status); } &&
7c9e5167 11372 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11373 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11374 (eval $ac_try) 2>&5
11375 ac_status=$?
c0d27fcc 11376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11377 (exit $ac_status); }; }; then
98418dba 11378 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
11379else
11380 echo "$as_me: failed program was:" >&5
19650fd6
AS
11381sed 's/^/| /' conftest.$ac_ext >&5
11382
98418dba 11383ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0 11384fi
7c9e5167 11385rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
11386LIBS=$ac_check_lib_save_LIBS
11387fi
c0d27fcc 11388echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
11389echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
11390if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
11391 HAVE_TIFF=yes
11392fi
11393
11394fi
73b77ee5 11395
c0d27fcc 11396
98418dba
CW
11397 fi
11398
11399 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 11400
c0d27fcc 11401cat >>confdefs.h <<\_ACEOF
98418dba 11402#define HAVE_TIFF 1
c0d27fcc 11403_ACEOF
98418dba
CW
11404
11405 fi
73b77ee5
GM
11406fi
11407
98418dba
CW
11408### Use -lgif if available, unless `--with-gif=no'.
11409HAVE_GIF=no
11410if test "${HAVE_X11}" = "yes"; then
11411 if test "${with_gif}" != "no"; then
c0d27fcc
MR
11412 if test "${ac_cv_header_gif_lib_h+set}" = set; then
11413 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
11414echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11415if test "${ac_cv_header_gif_lib_h+set}" = set; then
11416 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11417fi
11418echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
11419echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 11420else
c0d27fcc
MR
11421 # Is the header compilable?
11422echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
11423echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
11424cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11425#line $LINENO "configure"
19650fd6
AS
11426/* confdefs.h. */
11427_ACEOF
11428cat confdefs.h >>conftest.$ac_ext
11429cat >>conftest.$ac_ext <<_ACEOF
11430/* end confdefs.h. */
c0d27fcc
MR
11431$ac_includes_default
11432#include <gif_lib.h>
11433_ACEOF
11434rm -f conftest.$ac_objext
11435if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 11436 (eval $ac_compile) 2>&5
c0d27fcc
MR
11437 ac_status=$?
11438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11439 (exit $ac_status); } &&
7c9e5167 11440 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11441 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11442 (eval $ac_try) 2>&5
11443 ac_status=$?
11444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11445 (exit $ac_status); }; }; then
11446 ac_header_compiler=yes
11447else
11448 echo "$as_me: failed program was:" >&5
19650fd6
AS
11449sed 's/^/| /' conftest.$ac_ext >&5
11450
c0d27fcc
MR
11451ac_header_compiler=no
11452fi
7c9e5167 11453rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11454echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11455echo "${ECHO_T}$ac_header_compiler" >&6
11456
11457# Is the header present?
11458echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
11459echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
11460cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11461#line $LINENO "configure"
19650fd6
AS
11462/* confdefs.h. */
11463_ACEOF
11464cat confdefs.h >>conftest.$ac_ext
11465cat >>conftest.$ac_ext <<_ACEOF
11466/* end confdefs.h. */
98418dba
CW
11467#include <gif_lib.h>
11468_ACEOF
c0d27fcc 11469if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11470 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11471 ac_status=$?
6bae0ccf 11472 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11473 rm -f conftest.er1
11474 cat conftest.err >&5
c0d27fcc 11475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11476 (exit $ac_status); } >/dev/null; then
11477 if test -s conftest.err; then
11478 ac_cpp_err=$ac_c_preproc_warn_flag
11479 else
11480 ac_cpp_err=
11481 fi
11482else
11483 ac_cpp_err=yes
11484fi
11485if test -z "$ac_cpp_err"; then
c0d27fcc 11486 ac_header_preproc=yes
98418dba
CW
11487else
11488 echo "$as_me: failed program was:" >&5
19650fd6
AS
11489sed 's/^/| /' conftest.$ac_ext >&5
11490
c0d27fcc 11491 ac_header_preproc=no
98418dba
CW
11492fi
11493rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11494echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11495echo "${ECHO_T}$ac_header_preproc" >&6
11496
11497# So? What about this header?
7c9e5167
JD
11498case $ac_header_compiler:$ac_header_preproc in
11499 yes:no )
c0d27fcc
MR
11500 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11501echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
11502 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
11503echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
11504 (
11505 cat <<\_ASBOX
11506## ------------------------------------ ##
11507## Report this to bug-autoconf@gnu.org. ##
11508## ------------------------------------ ##
11509_ASBOX
11510 ) |
11511 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 11512 ;;
7c9e5167 11513 no:yes )
c0d27fcc
MR
11514 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
11515echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
7c9e5167
JD
11516 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
11517echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 11518 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
19650fd6 11519echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
11520 (
11521 cat <<\_ASBOX
7c9e5167
JD
11522## ------------------------------------ ##
11523## Report this to bug-autoconf@gnu.org. ##
11524## ------------------------------------ ##
19650fd6
AS
11525_ASBOX
11526 ) |
11527 sed "s/^/$as_me: WARNING: /" >&2
11528 ;;
c0d27fcc
MR
11529esac
11530echo "$as_me:$LINENO: checking for gif_lib.h" >&5
11531echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
11532if test "${ac_cv_header_gif_lib_h+set}" = set; then
11533 echo $ECHO_N "(cached) $ECHO_C" >&6
11534else
11535 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 11536fi
c0d27fcc 11537echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 11538echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
11539
11540fi
98418dba
CW
11541if test $ac_cv_header_gif_lib_h = yes; then
11542 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
11543# Earlier versions can crash Emacs.
c0d27fcc 11544 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
11545echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
11546if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 11547 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 11548else
503d2be0 11549 ac_check_lib_save_LIBS=$LIBS
98418dba 11550LIBS="-lungif $LIBS"
503d2be0 11551cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11552#line $LINENO "configure"
19650fd6
AS
11553/* confdefs.h. */
11554_ACEOF
11555cat confdefs.h >>conftest.$ac_ext
11556cat >>conftest.$ac_ext <<_ACEOF
11557/* end confdefs.h. */
73b77ee5 11558
98418dba
CW
11559/* Override any gcc2 internal prototype to avoid an error. */
11560#ifdef __cplusplus
11561extern "C"
11562#endif
11563/* We use char because int might match the return type of a gcc2
11564 builtin and then its argument prototype would still apply. */
11565char EGifPutExtensionLast ();
503d2be0
AS
11566int
11567main ()
11568{
98418dba 11569EGifPutExtensionLast ();
503d2be0
AS
11570 ;
11571 return 0;
11572}
11573_ACEOF
11574rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11575if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 11576 (eval $ac_link) 2>&5
503d2be0 11577 ac_status=$?
c0d27fcc 11578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11579 (exit $ac_status); } &&
7c9e5167 11580 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
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_cv_lib_ungif_EGifPutExtensionLast=yes
11587else
98418dba 11588 echo "$as_me: failed program was:" >&5
19650fd6
AS
11589sed 's/^/| /' conftest.$ac_ext >&5
11590
98418dba
CW
11591ac_cv_lib_ungif_EGifPutExtensionLast=no
11592fi
7c9e5167 11593rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
11594LIBS=$ac_check_lib_save_LIBS
11595fi
c0d27fcc 11596echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
11597echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
11598if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
11599 HAVE_GIF=yes
11600fi
11601
11602fi
11603
c0d27fcc 11604
98418dba
CW
11605 fi
11606
11607 if test "${HAVE_GIF}" = "yes"; then
b936fae4 11608
c0d27fcc 11609cat >>confdefs.h <<\_ACEOF
98418dba 11610#define HAVE_GIF 1
c0d27fcc 11611_ACEOF
98418dba
CW
11612
11613 fi
11614fi
11615
cef11da2
ST
11616if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
11617 echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
11618echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6
11619if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
11620 echo $ECHO_N "(cached) $ECHO_C" >&6
11621fi
11622echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
11623echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6
11624else
11625 # Is the header compilable?
11626echo "$as_me:$LINENO: checking malloc/malloc.h usability" >&5
11627echo $ECHO_N "checking malloc/malloc.h usability... $ECHO_C" >&6
11628cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11629#line $LINENO "configure"
cef11da2
ST
11630/* confdefs.h. */
11631_ACEOF
11632cat confdefs.h >>conftest.$ac_ext
11633cat >>conftest.$ac_ext <<_ACEOF
11634/* end confdefs.h. */
11635$ac_includes_default
11636#include <malloc/malloc.h>
11637_ACEOF
11638rm -f conftest.$ac_objext
11639if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 11640 (eval $ac_compile) 2>&5
cef11da2 11641 ac_status=$?
cef11da2
ST
11642 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11643 (exit $ac_status); } &&
7c9e5167 11644 { ac_try='test -s conftest.$ac_objext'
cef11da2
ST
11645 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11646 (eval $ac_try) 2>&5
11647 ac_status=$?
11648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11649 (exit $ac_status); }; }; then
11650 ac_header_compiler=yes
11651else
11652 echo "$as_me: failed program was:" >&5
11653sed 's/^/| /' conftest.$ac_ext >&5
11654
11655ac_header_compiler=no
11656fi
7c9e5167 11657rm -f conftest.$ac_objext conftest.$ac_ext
cef11da2
ST
11658echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11659echo "${ECHO_T}$ac_header_compiler" >&6
11660
11661# Is the header present?
11662echo "$as_me:$LINENO: checking malloc/malloc.h presence" >&5
11663echo $ECHO_N "checking malloc/malloc.h presence... $ECHO_C" >&6
11664cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11665#line $LINENO "configure"
cef11da2
ST
11666/* confdefs.h. */
11667_ACEOF
11668cat confdefs.h >>conftest.$ac_ext
11669cat >>conftest.$ac_ext <<_ACEOF
11670/* end confdefs.h. */
11671#include <malloc/malloc.h>
11672_ACEOF
11673if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11674 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11675 ac_status=$?
11676 grep -v '^ *+' conftest.er1 >conftest.err
11677 rm -f conftest.er1
11678 cat conftest.err >&5
11679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11680 (exit $ac_status); } >/dev/null; then
11681 if test -s conftest.err; then
11682 ac_cpp_err=$ac_c_preproc_warn_flag
cef11da2
ST
11683 else
11684 ac_cpp_err=
11685 fi
11686else
11687 ac_cpp_err=yes
11688fi
11689if test -z "$ac_cpp_err"; then
11690 ac_header_preproc=yes
11691else
11692 echo "$as_me: failed program was:" >&5
11693sed 's/^/| /' conftest.$ac_ext >&5
11694
11695 ac_header_preproc=no
11696fi
11697rm -f conftest.err conftest.$ac_ext
11698echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11699echo "${ECHO_T}$ac_header_preproc" >&6
11700
11701# So? What about this header?
7c9e5167
JD
11702case $ac_header_compiler:$ac_header_preproc in
11703 yes:no )
cef11da2
ST
11704 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&5
11705echo "$as_me: WARNING: malloc/malloc.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
11706 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&5
11707echo "$as_me: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&2;}
11708 (
11709 cat <<\_ASBOX
11710## ------------------------------------ ##
11711## Report this to bug-autoconf@gnu.org. ##
11712## ------------------------------------ ##
11713_ASBOX
11714 ) |
11715 sed "s/^/$as_me: WARNING: /" >&2
cef11da2 11716 ;;
7c9e5167 11717 no:yes )
cef11da2
ST
11718 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: present but cannot be compiled" >&5
11719echo "$as_me: WARNING: malloc/malloc.h: present but cannot be compiled" >&2;}
7c9e5167
JD
11720 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: check for missing prerequisite headers?" >&5
11721echo "$as_me: WARNING: malloc/malloc.h: check for missing prerequisite headers?" >&2;}
cef11da2
ST
11722 { echo "$as_me:$LINENO: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&5
11723echo "$as_me: WARNING: malloc/malloc.h: proceeding with the preprocessor's result" >&2;}
cef11da2
ST
11724 (
11725 cat <<\_ASBOX
7c9e5167
JD
11726## ------------------------------------ ##
11727## Report this to bug-autoconf@gnu.org. ##
11728## ------------------------------------ ##
cef11da2
ST
11729_ASBOX
11730 ) |
11731 sed "s/^/$as_me: WARNING: /" >&2
11732 ;;
11733esac
11734echo "$as_me:$LINENO: checking for malloc/malloc.h" >&5
11735echo $ECHO_N "checking for malloc/malloc.h... $ECHO_C" >&6
11736if test "${ac_cv_header_malloc_malloc_h+set}" = set; then
11737 echo $ECHO_N "(cached) $ECHO_C" >&6
11738else
11739 ac_cv_header_malloc_malloc_h=$ac_header_preproc
11740fi
11741echo "$as_me:$LINENO: result: $ac_cv_header_malloc_malloc_h" >&5
11742echo "${ECHO_T}$ac_cv_header_malloc_malloc_h" >&6
11743
11744fi
11745if test $ac_cv_header_malloc_malloc_h = yes; then
11746
11747cat >>confdefs.h <<\_ACEOF
11748#define HAVE_MALLOC_MALLOC_H 1
11749_ACEOF
11750
11751fi
11752
11753
11754
5d6da11e 11755### Use Mac OS X Carbon API to implement GUI.
e0f712ba 11756if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 11757
c0d27fcc 11758cat >>confdefs.h <<\_ACEOF
e0f712ba 11759#define HAVE_CARBON 1
c0d27fcc 11760_ACEOF
e0f712ba 11761
6a3a24fa
JD
11762 window_system=mac
11763 ## Specify the install directory
11764 carbon_appdir=
11765 if test "${carbon_appdir_x}" != ""; then
11766 case ${carbon_appdir_x} in
11767 y | ye | yes) carbon_appdir=/Applications ;;
11768 * ) carbon_appdir=${carbon_appdir_x} ;;
11769 esac
11770 fi
8f417b3b
AS
11771 # We also have mouse menus.
11772 HAVE_MENUS=yes
7c9e5167
JD
11773
11774 tmp_CFLAGS="$CFLAGS"
11775 CFLAGS="$CFLAGS -framework Carbon"
11776 echo "$as_me:$LINENO: checking for CancelMenuTracking" >&5
11777echo $ECHO_N "checking for CancelMenuTracking... $ECHO_C" >&6
11778if test "${ac_cv_func_CancelMenuTracking+set}" = set; then
11779 echo $ECHO_N "(cached) $ECHO_C" >&6
11780else
11781 cat >conftest.$ac_ext <<_ACEOF
11782#line $LINENO "configure"
11783/* confdefs.h. */
11784_ACEOF
11785cat confdefs.h >>conftest.$ac_ext
11786cat >>conftest.$ac_ext <<_ACEOF
11787/* end confdefs.h. */
11788/* System header to define __stub macros and hopefully few prototypes,
11789 which can conflict with char CancelMenuTracking (); below.
11790 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11791 <limits.h> exists even on freestanding compilers. */
11792#ifdef __STDC__
11793# include <limits.h>
11794#else
11795# include <assert.h>
11796#endif
11797/* Override any gcc2 internal prototype to avoid an error. */
11798#ifdef __cplusplus
11799extern "C"
11800{
11801#endif
11802/* We use char because int might match the return type of a gcc2
11803 builtin and then its argument prototype would still apply. */
11804char CancelMenuTracking ();
11805/* The GNU C library defines this for functions which it implements
11806 to always fail with ENOSYS. Some functions are actually named
11807 something starting with __ and the normal name is an alias. */
11808#if defined (__stub_CancelMenuTracking) || defined (__stub___CancelMenuTracking)
11809choke me
11810#else
11811char (*f) () = CancelMenuTracking;
11812#endif
11813#ifdef __cplusplus
11814}
11815#endif
11816
11817int
11818main ()
11819{
11820return f != CancelMenuTracking;
11821 ;
11822 return 0;
11823}
11824_ACEOF
11825rm -f conftest.$ac_objext conftest$ac_exeext
11826if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11827 (eval $ac_link) 2>&5
11828 ac_status=$?
11829 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11830 (exit $ac_status); } &&
11831 { ac_try='test -s conftest$ac_exeext'
11832 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11833 (eval $ac_try) 2>&5
11834 ac_status=$?
11835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11836 (exit $ac_status); }; }; then
11837 ac_cv_func_CancelMenuTracking=yes
11838else
11839 echo "$as_me: failed program was:" >&5
11840sed 's/^/| /' conftest.$ac_ext >&5
11841
11842ac_cv_func_CancelMenuTracking=no
11843fi
11844rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11845fi
11846echo "$as_me:$LINENO: result: $ac_cv_func_CancelMenuTracking" >&5
11847echo "${ECHO_T}$ac_cv_func_CancelMenuTracking" >&6
11848if test $ac_cv_func_CancelMenuTracking = yes; then
11849 have_cmt=yes
11850else
11851 have_cmt=no
11852fi
11853
11854 if test "$have_cmt" = yes; then
11855
11856cat >>confdefs.h <<\_ACEOF
11857#define HAVE_CANCELMENUTRACKING 1
11858_ACEOF
11859
11860 fi
11861 CFLAGS="$tmp_CFLAGS"
e0f712ba
AC
11862fi
11863
98418dba
CW
11864### Use session management (-lSM -lICE) if available
11865HAVE_X_SM=no
11866if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
11867 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
11868 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
11869echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
11870if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
11871 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11872fi
11873echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
11874echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 11875else
c0d27fcc
MR
11876 # Is the header compilable?
11877echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
11878echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
11879cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11880#line $LINENO "configure"
19650fd6
AS
11881/* confdefs.h. */
11882_ACEOF
11883cat confdefs.h >>conftest.$ac_ext
11884cat >>conftest.$ac_ext <<_ACEOF
11885/* end confdefs.h. */
c0d27fcc
MR
11886$ac_includes_default
11887#include <X11/SM/SMlib.h>
11888_ACEOF
11889rm -f conftest.$ac_objext
11890if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 11891 (eval $ac_compile) 2>&5
c0d27fcc
MR
11892 ac_status=$?
11893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11894 (exit $ac_status); } &&
7c9e5167 11895 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
11896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11897 (eval $ac_try) 2>&5
11898 ac_status=$?
11899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11900 (exit $ac_status); }; }; then
11901 ac_header_compiler=yes
11902else
11903 echo "$as_me: failed program was:" >&5
19650fd6
AS
11904sed 's/^/| /' conftest.$ac_ext >&5
11905
c0d27fcc
MR
11906ac_header_compiler=no
11907fi
7c9e5167 11908rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
11909echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11910echo "${ECHO_T}$ac_header_compiler" >&6
11911
11912# Is the header present?
11913echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
11914echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
11915cat >conftest.$ac_ext <<_ACEOF
7c9e5167 11916#line $LINENO "configure"
19650fd6
AS
11917/* confdefs.h. */
11918_ACEOF
11919cat confdefs.h >>conftest.$ac_ext
11920cat >>conftest.$ac_ext <<_ACEOF
11921/* end confdefs.h. */
98418dba
CW
11922#include <X11/SM/SMlib.h>
11923_ACEOF
c0d27fcc 11924if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
11925 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11926 ac_status=$?
6bae0ccf 11927 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11928 rm -f conftest.er1
11929 cat conftest.err >&5
c0d27fcc 11930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11931 (exit $ac_status); } >/dev/null; then
11932 if test -s conftest.err; then
11933 ac_cpp_err=$ac_c_preproc_warn_flag
11934 else
11935 ac_cpp_err=
11936 fi
11937else
11938 ac_cpp_err=yes
503d2be0 11939fi
98418dba 11940if test -z "$ac_cpp_err"; then
c0d27fcc 11941 ac_header_preproc=yes
98418dba
CW
11942else
11943 echo "$as_me: failed program was:" >&5
19650fd6
AS
11944sed 's/^/| /' conftest.$ac_ext >&5
11945
c0d27fcc 11946 ac_header_preproc=no
98418dba
CW
11947fi
11948rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11949echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11950echo "${ECHO_T}$ac_header_preproc" >&6
11951
11952# So? What about this header?
7c9e5167
JD
11953case $ac_header_compiler:$ac_header_preproc in
11954 yes:no )
c0d27fcc
MR
11955 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11956echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
11957 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
11958echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
11959 (
11960 cat <<\_ASBOX
11961## ------------------------------------ ##
11962## Report this to bug-autoconf@gnu.org. ##
11963## ------------------------------------ ##
11964_ASBOX
11965 ) |
11966 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 11967 ;;
7c9e5167 11968 no:yes )
c0d27fcc
MR
11969 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
11970echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
7c9e5167
JD
11971 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
11972echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 11973 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
19650fd6 11974echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
11975 (
11976 cat <<\_ASBOX
7c9e5167
JD
11977## ------------------------------------ ##
11978## Report this to bug-autoconf@gnu.org. ##
11979## ------------------------------------ ##
19650fd6
AS
11980_ASBOX
11981 ) |
11982 sed "s/^/$as_me: WARNING: /" >&2
11983 ;;
c0d27fcc
MR
11984esac
11985echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
11986echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
11987if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
11988 echo $ECHO_N "(cached) $ECHO_C" >&6
11989else
11990 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 11991fi
c0d27fcc 11992echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 11993echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
11994
11995fi
98418dba 11996if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 11997 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
11998echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
11999if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 12000 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12001else
503d2be0 12002 ac_check_lib_save_LIBS=$LIBS
1660500f 12003LIBS="-lSM -lICE $LIBS"
503d2be0 12004cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12005#line $LINENO "configure"
19650fd6
AS
12006/* confdefs.h. */
12007_ACEOF
12008cat confdefs.h >>conftest.$ac_ext
12009cat >>conftest.$ac_ext <<_ACEOF
12010/* end confdefs.h. */
503d2be0 12011
73b77ee5 12012/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12013#ifdef __cplusplus
12014extern "C"
12015#endif
73b77ee5 12016/* We use char because int might match the return type of a gcc2
503d2be0 12017 builtin and then its argument prototype would still apply. */
98418dba 12018char SmcOpenConnection ();
503d2be0
AS
12019int
12020main ()
12021{
98418dba 12022SmcOpenConnection ();
503d2be0
AS
12023 ;
12024 return 0;
12025}
12026_ACEOF
12027rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12028if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12029 (eval $ac_link) 2>&5
503d2be0 12030 ac_status=$?
c0d27fcc 12031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12032 (exit $ac_status); } &&
7c9e5167 12033 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12034 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12035 (eval $ac_try) 2>&5
12036 ac_status=$?
c0d27fcc 12037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12038 (exit $ac_status); }; }; then
98418dba 12039 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
12040else
12041 echo "$as_me: failed program was:" >&5
19650fd6
AS
12042sed 's/^/| /' conftest.$ac_ext >&5
12043
98418dba 12044ac_cv_lib_SM_SmcOpenConnection=no
503d2be0 12045fi
7c9e5167 12046rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
12047LIBS=$ac_check_lib_save_LIBS
12048fi
c0d27fcc 12049echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
12050echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
12051if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
12052 HAVE_X_SM=yes
73b77ee5
GM
12053fi
12054
73b77ee5 12055fi
73b77ee5 12056
c0d27fcc
MR
12057
12058
98418dba 12059 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 12060
c0d27fcc 12061cat >>confdefs.h <<\_ACEOF
98418dba 12062#define HAVE_X_SM 1
c0d27fcc 12063_ACEOF
73b77ee5 12064
98418dba
CW
12065 case "$LIBS" in
12066 *-lSM*) ;;
12067 *) LIBS="-lSM -lICE $LIBS" ;;
12068 esac
73b77ee5 12069 fi
98418dba 12070fi
73b77ee5 12071
98418dba 12072# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 12073echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
12074echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
12075if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
12076 echo $ECHO_N "(cached) $ECHO_C" >&6
12077else
12078 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12079#line $LINENO "configure"
19650fd6
AS
12080/* confdefs.h. */
12081_ACEOF
12082cat confdefs.h >>conftest.$ac_ext
12083cat >>conftest.$ac_ext <<_ACEOF
12084/* end confdefs.h. */
98418dba 12085#include <netdb.h>
503d2be0
AS
12086int
12087main ()
12088{
98418dba 12089return h_errno;
503d2be0
AS
12090 ;
12091 return 0;
12092}
12093_ACEOF
12094rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12095if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12096 (eval $ac_link) 2>&5
503d2be0 12097 ac_status=$?
c0d27fcc 12098 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12099 (exit $ac_status); } &&
7c9e5167 12100 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12101 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12102 (eval $ac_try) 2>&5
12103 ac_status=$?
c0d27fcc 12104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12105 (exit $ac_status); }; }; then
98418dba 12106 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 12107else
503d2be0 12108 echo "$as_me: failed program was:" >&5
19650fd6
AS
12109sed 's/^/| /' conftest.$ac_ext >&5
12110
98418dba 12111emacs_cv_netdb_declares_h_errno=no
73b77ee5 12112fi
7c9e5167 12113rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12114fi
c0d27fcc 12115echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
12116echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
12117if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 12118
c0d27fcc 12119cat >>confdefs.h <<\_ACEOF
98418dba 12120#define HAVE_H_ERRNO 1
c0d27fcc 12121_ACEOF
73b77ee5 12122
98418dba
CW
12123fi
12124
12125# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
12126# for constant arguments. Useless!
c0d27fcc 12127echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
12128echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
12129if test "${ac_cv_working_alloca_h+set}" = set; then
12130 echo $ECHO_N "(cached) $ECHO_C" >&6
12131else
12132 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12133#line $LINENO "configure"
19650fd6
AS
12134/* confdefs.h. */
12135_ACEOF
12136cat confdefs.h >>conftest.$ac_ext
12137cat >>conftest.$ac_ext <<_ACEOF
12138/* end confdefs.h. */
98418dba 12139#include <alloca.h>
503d2be0
AS
12140int
12141main ()
12142{
98418dba 12143char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
12144 ;
12145 return 0;
12146}
12147_ACEOF
12148rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12149if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12150 (eval $ac_link) 2>&5
503d2be0 12151 ac_status=$?
c0d27fcc 12152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12153 (exit $ac_status); } &&
7c9e5167 12154 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12155 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12156 (eval $ac_try) 2>&5
12157 ac_status=$?
c0d27fcc 12158 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12159 (exit $ac_status); }; }; then
98418dba 12160 ac_cv_working_alloca_h=yes
73b77ee5 12161else
503d2be0 12162 echo "$as_me: failed program was:" >&5
19650fd6
AS
12163sed 's/^/| /' conftest.$ac_ext >&5
12164
98418dba 12165ac_cv_working_alloca_h=no
73b77ee5 12166fi
7c9e5167 12167rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12168fi
c0d27fcc 12169echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
12170echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
12171if test $ac_cv_working_alloca_h = yes; then
73b77ee5 12172
c0d27fcc 12173cat >>confdefs.h <<\_ACEOF
98418dba 12174#define HAVE_ALLOCA_H 1
c0d27fcc 12175_ACEOF
98418dba
CW
12176
12177fi
12178
c0d27fcc 12179echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
12180echo $ECHO_N "checking for alloca... $ECHO_C" >&6
12181if test "${ac_cv_func_alloca_works+set}" = set; then
12182 echo $ECHO_N "(cached) $ECHO_C" >&6
12183else
503d2be0 12184 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12185#line $LINENO "configure"
19650fd6
AS
12186/* confdefs.h. */
12187_ACEOF
12188cat confdefs.h >>conftest.$ac_ext
12189cat >>conftest.$ac_ext <<_ACEOF
12190/* end confdefs.h. */
98418dba
CW
12191#ifdef __GNUC__
12192# define alloca __builtin_alloca
12193#else
12194# ifdef _MSC_VER
12195# include <malloc.h>
12196# define alloca _alloca
12197# else
12198# if HAVE_ALLOCA_H
12199# include <alloca.h>
12200# else
12201# ifdef _AIX
12202 #pragma alloca
12203# else
12204# ifndef alloca /* predefined by HP cc +Olibcalls */
12205char *alloca ();
12206# endif
12207# endif
12208# endif
12209# endif
12210#endif
12211
503d2be0
AS
12212int
12213main ()
12214{
98418dba 12215char *p = (char *) alloca (1);
503d2be0
AS
12216 ;
12217 return 0;
12218}
12219_ACEOF
12220rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12221if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12222 (eval $ac_link) 2>&5
503d2be0 12223 ac_status=$?
c0d27fcc 12224 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12225 (exit $ac_status); } &&
7c9e5167 12226 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12227 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12228 (eval $ac_try) 2>&5
12229 ac_status=$?
c0d27fcc 12230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12231 (exit $ac_status); }; }; then
98418dba 12232 ac_cv_func_alloca_works=yes
ac95a621 12233else
503d2be0 12234 echo "$as_me: failed program was:" >&5
19650fd6
AS
12235sed 's/^/| /' conftest.$ac_ext >&5
12236
98418dba 12237ac_cv_func_alloca_works=no
ac95a621 12238fi
7c9e5167 12239rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12240fi
c0d27fcc 12241echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 12242echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 12243
98418dba
CW
12244if test $ac_cv_func_alloca_works = yes; then
12245
c0d27fcc 12246cat >>confdefs.h <<\_ACEOF
98418dba 12247#define HAVE_ALLOCA 1
c0d27fcc 12248_ACEOF
98418dba
CW
12249
12250else
12251 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12252# that cause trouble. Some versions do not even contain alloca or
12253# contain a buggy version. If you still want to use their alloca,
12254# use ar to extract alloca.o from them instead of compiling alloca.c.
12255
12256ALLOCA=alloca.$ac_objext
12257
c0d27fcc 12258cat >>confdefs.h <<\_ACEOF
98418dba 12259#define C_ALLOCA 1
c0d27fcc 12260_ACEOF
98418dba 12261
c0d27fcc
MR
12262
12263echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
12264echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
12265if test "${ac_cv_os_cray+set}" = set; then
12266 echo $ECHO_N "(cached) $ECHO_C" >&6
12267else
12268 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12269#line $LINENO "configure"
19650fd6
AS
12270/* confdefs.h. */
12271_ACEOF
12272cat confdefs.h >>conftest.$ac_ext
12273cat >>conftest.$ac_ext <<_ACEOF
12274/* end confdefs.h. */
98418dba
CW
12275#if defined(CRAY) && ! defined(CRAY2)
12276webecray
12277#else
12278wenotbecray
12279#endif
12280
12281_ACEOF
12282if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 12283 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
12284 ac_cv_os_cray=yes
12285else
12286 ac_cv_os_cray=no
12287fi
12288rm -f conftest*
ac95a621 12289
98418dba 12290fi
c0d27fcc 12291echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
12292echo "${ECHO_T}$ac_cv_os_cray" >&6
12293if test $ac_cv_os_cray = yes; then
12294 for ac_func in _getb67 GETB67 getb67; do
12295 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12296echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12297echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12298if eval "test \"\${$as_ac_var+set}\" = set"; then
12299 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 12300else
503d2be0 12301 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12302#line $LINENO "configure"
19650fd6
AS
12303/* confdefs.h. */
12304_ACEOF
12305cat confdefs.h >>conftest.$ac_ext
12306cat >>conftest.$ac_ext <<_ACEOF
12307/* end confdefs.h. */
73b77ee5 12308/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12309 which can conflict with char $ac_func (); below.
12310 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12311 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
12312#ifdef __STDC__
12313# include <limits.h>
12314#else
12315# include <assert.h>
12316#endif
73b77ee5 12317/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12318#ifdef __cplusplus
12319extern "C"
19650fd6 12320{
503d2be0 12321#endif
73b77ee5 12322/* We use char because int might match the return type of a gcc2
503d2be0
AS
12323 builtin and then its argument prototype would still apply. */
12324char $ac_func ();
73b77ee5
GM
12325/* The GNU C library defines this for functions which it implements
12326 to always fail with ENOSYS. Some functions are actually named
12327 something starting with __ and the normal name is an alias. */
12328#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12329choke me
12330#else
19650fd6
AS
12331char (*f) () = $ac_func;
12332#endif
12333#ifdef __cplusplus
12334}
73b77ee5
GM
12335#endif
12336
19650fd6
AS
12337int
12338main ()
12339{
12340return f != $ac_func;
503d2be0
AS
12341 ;
12342 return 0;
12343}
12344_ACEOF
12345rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12346if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12347 (eval $ac_link) 2>&5
503d2be0 12348 ac_status=$?
c0d27fcc 12349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12350 (exit $ac_status); } &&
7c9e5167 12351 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12352 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12353 (eval $ac_try) 2>&5
12354 ac_status=$?
c0d27fcc 12355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12356 (exit $ac_status); }; }; then
12357 eval "$as_ac_var=yes"
12358else
12359 echo "$as_me: failed program was:" >&5
19650fd6
AS
12360sed 's/^/| /' conftest.$ac_ext >&5
12361
503d2be0
AS
12362eval "$as_ac_var=no"
12363fi
7c9e5167 12364rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 12365fi
c0d27fcc 12366echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12367echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12368if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 12369
c0d27fcc 12370cat >>confdefs.h <<_ACEOF
98418dba 12371#define CRAY_STACKSEG_END $ac_func
c0d27fcc 12372_ACEOF
98418dba
CW
12373
12374 break
73b77ee5 12375fi
73b77ee5 12376
98418dba 12377 done
73b77ee5
GM
12378fi
12379
c0d27fcc 12380echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
12381echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
12382if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 12383 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
12384else
12385 if test "$cross_compiling" = yes; then
12386 ac_cv_c_stack_direction=0
73b77ee5 12387else
503d2be0 12388 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12389#line $LINENO "configure"
19650fd6
AS
12390/* confdefs.h. */
12391_ACEOF
12392cat confdefs.h >>conftest.$ac_ext
12393cat >>conftest.$ac_ext <<_ACEOF
12394/* end confdefs.h. */
503d2be0 12395int
98418dba 12396find_stack_direction ()
503d2be0 12397{
98418dba
CW
12398 static char *addr = 0;
12399 auto char dummy;
12400 if (addr == 0)
12401 {
12402 addr = &dummy;
12403 return find_stack_direction ();
12404 }
73b77ee5 12405 else
98418dba
CW
12406 return (&dummy > addr) ? 1 : -1;
12407}
ba4481b5 12408
503d2be0
AS
12409int
12410main ()
12411{
98418dba 12412 exit (find_stack_direction () < 0);
503d2be0
AS
12413}
12414_ACEOF
98418dba 12415rm -f conftest$ac_exeext
c0d27fcc 12416if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12417 (eval $ac_link) 2>&5
12418 ac_status=$?
c0d27fcc 12419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 12420 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 12421 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12422 (eval $ac_try) 2>&5
12423 ac_status=$?
c0d27fcc 12424 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12425 (exit $ac_status); }; }; then
98418dba 12426 ac_cv_c_stack_direction=1
ba4481b5 12427else
98418dba
CW
12428 echo "$as_me: program exited with status $ac_status" >&5
12429echo "$as_me: failed program was:" >&5
19650fd6
AS
12430sed 's/^/| /' conftest.$ac_ext >&5
12431
c0d27fcc 12432( exit $ac_status )
98418dba 12433ac_cv_c_stack_direction=-1
ba4481b5 12434fi
7c9e5167 12435rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 12436fi
98418dba 12437fi
c0d27fcc 12438echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
12439echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
12440
c0d27fcc 12441cat >>confdefs.h <<_ACEOF
98418dba 12442#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
12443_ACEOF
12444
ba4481b5 12445
ba4481b5
DL
12446fi
12447
c0d27fcc 12448
98418dba
CW
12449# fmod, logb, and frexp are found in -lm on most systems.
12450# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12451
c0d27fcc 12452echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
12453echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
12454if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 12455 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12456else
98418dba
CW
12457 ac_check_lib_save_LIBS=$LIBS
12458LIBS="-lm $LIBS"
12459cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12460#line $LINENO "configure"
19650fd6
AS
12461/* confdefs.h. */
12462_ACEOF
12463cat confdefs.h >>conftest.$ac_ext
12464cat >>conftest.$ac_ext <<_ACEOF
12465/* end confdefs.h. */
ba4481b5 12466
98418dba
CW
12467/* Override any gcc2 internal prototype to avoid an error. */
12468#ifdef __cplusplus
12469extern "C"
12470#endif
12471/* We use char because int might match the return type of a gcc2
12472 builtin and then its argument prototype would still apply. */
12473char sqrt ();
503d2be0
AS
12474int
12475main ()
12476{
98418dba 12477sqrt ();
503d2be0
AS
12478 ;
12479 return 0;
12480}
12481_ACEOF
12482rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12483if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12484 (eval $ac_link) 2>&5
503d2be0 12485 ac_status=$?
c0d27fcc 12486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12487 (exit $ac_status); } &&
7c9e5167 12488 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12490 (eval $ac_try) 2>&5
12491 ac_status=$?
c0d27fcc 12492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12493 (exit $ac_status); }; }; then
98418dba 12494 ac_cv_lib_m_sqrt=yes
ba4481b5 12495else
503d2be0 12496 echo "$as_me: failed program was:" >&5
19650fd6
AS
12497sed 's/^/| /' conftest.$ac_ext >&5
12498
98418dba 12499ac_cv_lib_m_sqrt=no
ba4481b5 12500fi
7c9e5167 12501rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12502LIBS=$ac_check_lib_save_LIBS
ba4481b5 12503fi
c0d27fcc 12504echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
12505echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
12506if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 12507 cat >>confdefs.h <<_ACEOF
98418dba 12508#define HAVE_LIBM 1
c0d27fcc 12509_ACEOF
98418dba
CW
12510
12511 LIBS="-lm $LIBS"
ba4481b5 12512
ba4481b5
DL
12513fi
12514
c0d27fcc 12515
55597d70
DL
12516# Check for mail-locking functions in a "mail" library. Probably this should
12517# have the same check as for liblockfile below.
98418dba 12518
c0d27fcc 12519echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
12520echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
12521if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 12522 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12523else
98418dba
CW
12524 ac_check_lib_save_LIBS=$LIBS
12525LIBS="-lmail $LIBS"
12526cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12527#line $LINENO "configure"
19650fd6
AS
12528/* confdefs.h. */
12529_ACEOF
12530cat confdefs.h >>conftest.$ac_ext
12531cat >>conftest.$ac_ext <<_ACEOF
12532/* end confdefs.h. */
98418dba
CW
12533
12534/* Override any gcc2 internal prototype to avoid an error. */
12535#ifdef __cplusplus
12536extern "C"
12537#endif
12538/* We use char because int might match the return type of a gcc2
12539 builtin and then its argument prototype would still apply. */
12540char maillock ();
503d2be0
AS
12541int
12542main ()
12543{
98418dba 12544maillock ();
503d2be0
AS
12545 ;
12546 return 0;
12547}
12548_ACEOF
12549rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12550if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12551 (eval $ac_link) 2>&5
503d2be0 12552 ac_status=$?
c0d27fcc 12553 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12554 (exit $ac_status); } &&
7c9e5167 12555 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12556 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12557 (eval $ac_try) 2>&5
12558 ac_status=$?
c0d27fcc 12559 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12560 (exit $ac_status); }; }; then
98418dba 12561 ac_cv_lib_mail_maillock=yes
ba4481b5 12562else
503d2be0 12563 echo "$as_me: failed program was:" >&5
19650fd6
AS
12564sed 's/^/| /' conftest.$ac_ext >&5
12565
98418dba 12566ac_cv_lib_mail_maillock=no
ba4481b5 12567fi
7c9e5167 12568rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12569LIBS=$ac_check_lib_save_LIBS
ba4481b5 12570fi
c0d27fcc 12571echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
12572echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
12573if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 12574 cat >>confdefs.h <<_ACEOF
98418dba 12575#define HAVE_LIBMAIL 1
c0d27fcc 12576_ACEOF
ba4481b5 12577
98418dba 12578 LIBS="-lmail $LIBS"
ba4481b5 12579
98418dba 12580fi
ba4481b5 12581
c0d27fcc
MR
12582
12583echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
12584echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
12585if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 12586 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12587else
503d2be0 12588 ac_check_lib_save_LIBS=$LIBS
98418dba 12589LIBS="-llockfile $LIBS"
503d2be0 12590cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12591#line $LINENO "configure"
19650fd6
AS
12592/* confdefs.h. */
12593_ACEOF
12594cat confdefs.h >>conftest.$ac_ext
12595cat >>conftest.$ac_ext <<_ACEOF
12596/* end confdefs.h. */
503d2be0 12597
ba4481b5 12598/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12599#ifdef __cplusplus
12600extern "C"
12601#endif
ba4481b5 12602/* We use char because int might match the return type of a gcc2
503d2be0 12603 builtin and then its argument prototype would still apply. */
98418dba 12604char maillock ();
503d2be0
AS
12605int
12606main ()
12607{
98418dba 12608maillock ();
503d2be0
AS
12609 ;
12610 return 0;
12611}
12612_ACEOF
12613rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12614if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12615 (eval $ac_link) 2>&5
503d2be0 12616 ac_status=$?
c0d27fcc 12617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12618 (exit $ac_status); } &&
7c9e5167 12619 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12620 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12621 (eval $ac_try) 2>&5
12622 ac_status=$?
c0d27fcc 12623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12624 (exit $ac_status); }; }; then
98418dba 12625 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
12626else
12627 echo "$as_me: failed program was:" >&5
19650fd6
AS
12628sed 's/^/| /' conftest.$ac_ext >&5
12629
98418dba
CW
12630ac_cv_lib_lockfile_maillock=no
12631fi
7c9e5167 12632rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12633LIBS=$ac_check_lib_save_LIBS
12634fi
c0d27fcc 12635echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
12636echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
12637if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 12638 cat >>confdefs.h <<_ACEOF
98418dba 12639#define HAVE_LIBLOCKFILE 1
c0d27fcc 12640_ACEOF
98418dba
CW
12641
12642 LIBS="-llockfile $LIBS"
12643
12644fi
12645
12646# If we have the shared liblockfile, assume we must use it for mail
12647# locking (e.g. Debian). If we couldn't link against liblockfile
12648# (no liblockfile.a installed), ensure that we don't need to.
12649if test "$ac_cv_lib_lockfile_maillock" = no; then
12650 # Extract the first word of "liblockfile.so", so it can be a program name with args.
12651set dummy liblockfile.so; ac_word=$2
c0d27fcc 12652echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
12653echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
12654if test "${ac_cv_prog_liblockfile+set}" = set; then
12655 echo $ECHO_N "(cached) $ECHO_C" >&6
12656else
12657 if test -n "$liblockfile"; then
12658 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
12659else
c0d27fcc 12660as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
12661as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
12662for as_dir in $as_dummy
c0d27fcc
MR
12663do
12664 IFS=$as_save_IFS
12665 test -z "$as_dir" && as_dir=.
12666 for ac_exec_ext in '' $ac_executable_extensions; do
12667 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12668 ac_cv_prog_liblockfile="yes"
12669 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12670 break 2
12671 fi
12672done
98418dba
CW
12673done
12674
12675 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 12676fi
503d2be0 12677fi
98418dba
CW
12678liblockfile=$ac_cv_prog_liblockfile
12679if test -n "$liblockfile"; then
c0d27fcc 12680 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
12681echo "${ECHO_T}$liblockfile" >&6
12682else
c0d27fcc 12683 echo "$as_me:$LINENO: result: no" >&5
98418dba 12684echo "${ECHO_T}no" >&6
ba4481b5
DL
12685fi
12686
98418dba 12687 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 12688 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
12689This probably means that movemail could lose mail.
12690There may be a \`development' package to install containing liblockfile." >&5
12691echo "$as_me: error: Shared liblockfile found but can't link against it.
12692This probably means that movemail could lose mail.
12693There may be a \`development' package to install containing liblockfile." >&2;}
12694 { (exit 1); exit 1; }; }
98418dba 12695 else :
55597d70 12696 fi
98418dba 12697fi
503d2be0 12698
98418dba
CW
12699for ac_func in touchlock
12700do
12701as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12702echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
12703echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12704if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 12705 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 12706else
98418dba 12707 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12708#line $LINENO "configure"
19650fd6
AS
12709/* confdefs.h. */
12710_ACEOF
12711cat confdefs.h >>conftest.$ac_ext
12712cat >>conftest.$ac_ext <<_ACEOF
12713/* end confdefs.h. */
98418dba 12714/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
12715 which can conflict with char $ac_func (); below.
12716 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12717 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
12718#ifdef __STDC__
12719# include <limits.h>
12720#else
12721# include <assert.h>
12722#endif
457b792c 12723/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12724#ifdef __cplusplus
12725extern "C"
19650fd6 12726{
503d2be0 12727#endif
457b792c 12728/* We use char because int might match the return type of a gcc2
503d2be0 12729 builtin and then its argument prototype would still apply. */
98418dba 12730char $ac_func ();
98418dba
CW
12731/* The GNU C library defines this for functions which it implements
12732 to always fail with ENOSYS. Some functions are actually named
12733 something starting with __ and the normal name is an alias. */
12734#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12735choke me
12736#else
19650fd6
AS
12737char (*f) () = $ac_func;
12738#endif
12739#ifdef __cplusplus
12740}
cd958eb3
MB
12741#endif
12742
19650fd6
AS
12743int
12744main ()
12745{
12746return f != $ac_func;
503d2be0
AS
12747 ;
12748 return 0;
12749}
12750_ACEOF
12751rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12752if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 12753 (eval $ac_link) 2>&5
503d2be0 12754 ac_status=$?
c0d27fcc 12755 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12756 (exit $ac_status); } &&
7c9e5167 12757 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12758 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12759 (eval $ac_try) 2>&5
12760 ac_status=$?
c0d27fcc 12761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12762 (exit $ac_status); }; }; then
98418dba 12763 eval "$as_ac_var=yes"
503d2be0
AS
12764else
12765 echo "$as_me: failed program was:" >&5
19650fd6
AS
12766sed 's/^/| /' conftest.$ac_ext >&5
12767
98418dba 12768eval "$as_ac_var=no"
503d2be0 12769fi
7c9e5167 12770rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 12771fi
c0d27fcc 12772echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
12773echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12774if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12775 cat >>confdefs.h <<_ACEOF
98418dba 12776#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12777_ACEOF
457b792c 12778
457b792c 12779fi
98418dba 12780done
457b792c 12781
c0d27fcc 12782
98418dba
CW
12783for ac_header in maillock.h
12784do
12785as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
12786if eval "test \"\${$as_ac_Header+set}\" = set"; then
12787 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
12788echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12789if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 12790 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12791fi
12792echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12793echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 12794else
c0d27fcc
MR
12795 # Is the header compilable?
12796echo "$as_me:$LINENO: checking $ac_header usability" >&5
12797echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12798cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12799#line $LINENO "configure"
19650fd6
AS
12800/* confdefs.h. */
12801_ACEOF
12802cat confdefs.h >>conftest.$ac_ext
12803cat >>conftest.$ac_ext <<_ACEOF
12804/* end confdefs.h. */
c0d27fcc
MR
12805$ac_includes_default
12806#include <$ac_header>
12807_ACEOF
12808rm -f conftest.$ac_objext
12809if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 12810 (eval $ac_compile) 2>&5
c0d27fcc
MR
12811 ac_status=$?
12812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12813 (exit $ac_status); } &&
7c9e5167 12814 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
12815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12816 (eval $ac_try) 2>&5
12817 ac_status=$?
12818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12819 (exit $ac_status); }; }; then
12820 ac_header_compiler=yes
12821else
12822 echo "$as_me: failed program was:" >&5
19650fd6
AS
12823sed 's/^/| /' conftest.$ac_ext >&5
12824
c0d27fcc
MR
12825ac_header_compiler=no
12826fi
7c9e5167 12827rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
12828echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12829echo "${ECHO_T}$ac_header_compiler" >&6
12830
12831# Is the header present?
12832echo "$as_me:$LINENO: checking $ac_header presence" >&5
12833echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12834cat >conftest.$ac_ext <<_ACEOF
7c9e5167 12835#line $LINENO "configure"
19650fd6
AS
12836/* confdefs.h. */
12837_ACEOF
12838cat confdefs.h >>conftest.$ac_ext
12839cat >>conftest.$ac_ext <<_ACEOF
12840/* end confdefs.h. */
98418dba 12841#include <$ac_header>
503d2be0 12842_ACEOF
c0d27fcc 12843if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 12844 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 12845 ac_status=$?
6bae0ccf 12846 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12847 rm -f conftest.er1
12848 cat conftest.err >&5
c0d27fcc 12849 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12850 (exit $ac_status); } >/dev/null; then
12851 if test -s conftest.err; then
12852 ac_cpp_err=$ac_c_preproc_warn_flag
12853 else
12854 ac_cpp_err=
12855 fi
503d2be0 12856else
98418dba 12857 ac_cpp_err=yes
503d2be0 12858fi
98418dba 12859if test -z "$ac_cpp_err"; then
c0d27fcc 12860 ac_header_preproc=yes
98418dba
CW
12861else
12862 echo "$as_me: failed program was:" >&5
19650fd6
AS
12863sed 's/^/| /' conftest.$ac_ext >&5
12864
c0d27fcc 12865 ac_header_preproc=no
503d2be0 12866fi
98418dba 12867rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12868echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12869echo "${ECHO_T}$ac_header_preproc" >&6
12870
12871# So? What about this header?
7c9e5167
JD
12872case $ac_header_compiler:$ac_header_preproc in
12873 yes:no )
c0d27fcc
MR
12874 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12875echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
12876 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12877echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12878 (
12879 cat <<\_ASBOX
12880## ------------------------------------ ##
12881## Report this to bug-autoconf@gnu.org. ##
12882## ------------------------------------ ##
12883_ASBOX
12884 ) |
12885 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 12886 ;;
7c9e5167 12887 no:yes )
c0d27fcc
MR
12888 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12889echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
12890 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12891echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 12892 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 12893echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
12894 (
12895 cat <<\_ASBOX
7c9e5167
JD
12896## ------------------------------------ ##
12897## Report this to bug-autoconf@gnu.org. ##
12898## ------------------------------------ ##
19650fd6
AS
12899_ASBOX
12900 ) |
12901 sed "s/^/$as_me: WARNING: /" >&2
12902 ;;
c0d27fcc
MR
12903esac
12904echo "$as_me:$LINENO: checking for $ac_header" >&5
12905echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12906if eval "test \"\${$as_ac_Header+set}\" = set"; then
12907 echo $ECHO_N "(cached) $ECHO_C" >&6
12908else
7c9e5167 12909 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 12910fi
c0d27fcc 12911echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 12912echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
12913
12914fi
98418dba 12915if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 12916 cat >>confdefs.h <<_ACEOF
98418dba 12917#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 12918_ACEOF
48d4b120 12919
ba4481b5 12920fi
c0d27fcc 12921
98418dba
CW
12922done
12923
c0d27fcc
MR
12924
12925
12926
12927
12928
12929
12930
12931
12932
12933
12934
12935
12936
12937
12938
12939
12940
12941
12942
12943
12944
12945
12946
12947
12948
12949
12950
12951
12952
12953
12954
12955
12956
12957
12958
12959
12960
12961
12962
12963
12964
12965
12966
12967
12968
12969
12970
12971
12972
12973
12974
12975
12976
12977
12978
22044edf
DL
12979
12980
c0d27fcc 12981
b0e44248
RB
12982
12983
973a76b1
DL
12984
12985
12986
cd958eb3 12987
25ca0bca 12988
ea92fc9f 12989
c0d27fcc
MR
12990
12991
98418dba 12992for ac_func in gethostname getdomainname dup2 \
ea92fc9f 12993rename closedir mkdir rmdir sysinfo getrusage \
98418dba
CW
12994random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
12995strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
973a76b1 12996utimes setrlimit setpgid getcwd getwd shutdown getaddrinfo \
98418dba
CW
12997__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
12998sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248 12999gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
4489ece2 13000memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign
98418dba
CW
13001do
13002as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13003echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13004echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13005if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13006 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13007else
503d2be0 13008 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13009#line $LINENO "configure"
19650fd6
AS
13010/* confdefs.h. */
13011_ACEOF
13012cat confdefs.h >>conftest.$ac_ext
13013cat >>conftest.$ac_ext <<_ACEOF
13014/* end confdefs.h. */
98418dba 13015/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13016 which can conflict with char $ac_func (); below.
13017 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13018 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
13019#ifdef __STDC__
13020# include <limits.h>
13021#else
13022# include <assert.h>
13023#endif
ba4481b5 13024/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13025#ifdef __cplusplus
13026extern "C"
19650fd6 13027{
503d2be0 13028#endif
ba4481b5 13029/* We use char because int might match the return type of a gcc2
503d2be0 13030 builtin and then its argument prototype would still apply. */
98418dba 13031char $ac_func ();
98418dba
CW
13032/* The GNU C library defines this for functions which it implements
13033 to always fail with ENOSYS. Some functions are actually named
13034 something starting with __ and the normal name is an alias. */
13035#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13036choke me
13037#else
19650fd6
AS
13038char (*f) () = $ac_func;
13039#endif
13040#ifdef __cplusplus
13041}
98418dba
CW
13042#endif
13043
19650fd6
AS
13044int
13045main ()
13046{
13047return f != $ac_func;
503d2be0
AS
13048 ;
13049 return 0;
13050}
13051_ACEOF
13052rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13053if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13054 (eval $ac_link) 2>&5
503d2be0 13055 ac_status=$?
c0d27fcc 13056 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13057 (exit $ac_status); } &&
7c9e5167 13058 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13059 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13060 (eval $ac_try) 2>&5
13061 ac_status=$?
c0d27fcc 13062 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13063 (exit $ac_status); }; }; then
98418dba 13064 eval "$as_ac_var=yes"
503d2be0
AS
13065else
13066 echo "$as_me: failed program was:" >&5
19650fd6
AS
13067sed 's/^/| /' conftest.$ac_ext >&5
13068
98418dba 13069eval "$as_ac_var=no"
503d2be0 13070fi
7c9e5167 13071rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 13072fi
c0d27fcc 13073echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13074echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13075if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13076 cat >>confdefs.h <<_ACEOF
98418dba 13077#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13078_ACEOF
ba4481b5 13079
ba4481b5 13080fi
98418dba 13081done
ba4481b5 13082
c0d27fcc
MR
13083
13084
98418dba
CW
13085for ac_header in sys/un.h
13086do
13087as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13088if eval "test \"\${$as_ac_Header+set}\" = set"; then
13089 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
13090echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13091if eval "test \"\${$as_ac_Header+set}\" = set"; then
13092 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13093fi
13094echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13095echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13096else
c0d27fcc
MR
13097 # Is the header compilable?
13098echo "$as_me:$LINENO: checking $ac_header usability" >&5
13099echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13100cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13101#line $LINENO "configure"
19650fd6
AS
13102/* confdefs.h. */
13103_ACEOF
13104cat confdefs.h >>conftest.$ac_ext
13105cat >>conftest.$ac_ext <<_ACEOF
13106/* end confdefs.h. */
c0d27fcc
MR
13107$ac_includes_default
13108#include <$ac_header>
13109_ACEOF
13110rm -f conftest.$ac_objext
13111if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 13112 (eval $ac_compile) 2>&5
c0d27fcc
MR
13113 ac_status=$?
13114 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13115 (exit $ac_status); } &&
7c9e5167 13116 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13117 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13118 (eval $ac_try) 2>&5
13119 ac_status=$?
13120 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13121 (exit $ac_status); }; }; then
13122 ac_header_compiler=yes
13123else
13124 echo "$as_me: failed program was:" >&5
19650fd6
AS
13125sed 's/^/| /' conftest.$ac_ext >&5
13126
c0d27fcc
MR
13127ac_header_compiler=no
13128fi
7c9e5167 13129rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13130echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13131echo "${ECHO_T}$ac_header_compiler" >&6
13132
13133# Is the header present?
13134echo "$as_me:$LINENO: checking $ac_header presence" >&5
13135echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13136cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13137#line $LINENO "configure"
19650fd6
AS
13138/* confdefs.h. */
13139_ACEOF
13140cat confdefs.h >>conftest.$ac_ext
13141cat >>conftest.$ac_ext <<_ACEOF
13142/* end confdefs.h. */
98418dba 13143#include <$ac_header>
503d2be0 13144_ACEOF
c0d27fcc 13145if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13146 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13147 ac_status=$?
6bae0ccf 13148 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13149 rm -f conftest.er1
13150 cat conftest.err >&5
c0d27fcc 13151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13152 (exit $ac_status); } >/dev/null; then
13153 if test -s conftest.err; then
13154 ac_cpp_err=$ac_c_preproc_warn_flag
13155 else
13156 ac_cpp_err=
13157 fi
13158else
13159 ac_cpp_err=yes
13160fi
13161if test -z "$ac_cpp_err"; then
c0d27fcc 13162 ac_header_preproc=yes
ba4481b5 13163else
503d2be0 13164 echo "$as_me: failed program was:" >&5
19650fd6
AS
13165sed 's/^/| /' conftest.$ac_ext >&5
13166
c0d27fcc 13167 ac_header_preproc=no
ba4481b5 13168fi
503d2be0 13169rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13170echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13171echo "${ECHO_T}$ac_header_preproc" >&6
13172
13173# So? What about this header?
7c9e5167
JD
13174case $ac_header_compiler:$ac_header_preproc in
13175 yes:no )
c0d27fcc
MR
13176 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13177echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
13178 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13179echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13180 (
13181 cat <<\_ASBOX
13182## ------------------------------------ ##
13183## Report this to bug-autoconf@gnu.org. ##
13184## ------------------------------------ ##
13185_ASBOX
13186 ) |
13187 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 13188 ;;
7c9e5167 13189 no:yes )
c0d27fcc
MR
13190 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13191echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
13192 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13193echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 13194 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13195echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
13196 (
13197 cat <<\_ASBOX
7c9e5167
JD
13198## ------------------------------------ ##
13199## Report this to bug-autoconf@gnu.org. ##
13200## ------------------------------------ ##
19650fd6
AS
13201_ASBOX
13202 ) |
13203 sed "s/^/$as_me: WARNING: /" >&2
13204 ;;
c0d27fcc
MR
13205esac
13206echo "$as_me:$LINENO: checking for $ac_header" >&5
13207echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13208if eval "test \"\${$as_ac_Header+set}\" = set"; then
13209 echo $ECHO_N "(cached) $ECHO_C" >&6
13210else
7c9e5167 13211 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 13212fi
c0d27fcc 13213echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 13214echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13215
13216fi
925c2f3f 13217if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13218 cat >>confdefs.h <<_ACEOF
925c2f3f 13219#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13220_ACEOF
503d2be0 13221
925c2f3f 13222fi
c0d27fcc 13223
925c2f3f
EZ
13224done
13225
c0d27fcc
MR
13226
13227
13228
7c9e5167 13229for ac_header in sys/time.h unistd.h
925c2f3f
EZ
13230do
13231as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13232if eval "test \"\${$as_ac_Header+set}\" = set"; then
13233 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
13234echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13235if eval "test \"\${$as_ac_Header+set}\" = set"; then
13236 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13237fi
13238echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13239echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 13240else
c0d27fcc
MR
13241 # Is the header compilable?
13242echo "$as_me:$LINENO: checking $ac_header usability" >&5
13243echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13244cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13245#line $LINENO "configure"
19650fd6
AS
13246/* confdefs.h. */
13247_ACEOF
13248cat confdefs.h >>conftest.$ac_ext
13249cat >>conftest.$ac_ext <<_ACEOF
13250/* end confdefs.h. */
c0d27fcc
MR
13251$ac_includes_default
13252#include <$ac_header>
13253_ACEOF
13254rm -f conftest.$ac_objext
13255if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 13256 (eval $ac_compile) 2>&5
c0d27fcc
MR
13257 ac_status=$?
13258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13259 (exit $ac_status); } &&
7c9e5167 13260 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
13261 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13262 (eval $ac_try) 2>&5
13263 ac_status=$?
13264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13265 (exit $ac_status); }; }; then
13266 ac_header_compiler=yes
13267else
13268 echo "$as_me: failed program was:" >&5
19650fd6
AS
13269sed 's/^/| /' conftest.$ac_ext >&5
13270
c0d27fcc
MR
13271ac_header_compiler=no
13272fi
7c9e5167 13273rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
13274echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13275echo "${ECHO_T}$ac_header_compiler" >&6
13276
13277# Is the header present?
13278echo "$as_me:$LINENO: checking $ac_header presence" >&5
13279echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13280cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13281#line $LINENO "configure"
19650fd6
AS
13282/* confdefs.h. */
13283_ACEOF
13284cat confdefs.h >>conftest.$ac_ext
13285cat >>conftest.$ac_ext <<_ACEOF
13286/* end confdefs.h. */
98418dba 13287#include <$ac_header>
503d2be0 13288_ACEOF
c0d27fcc 13289if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13290 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13291 ac_status=$?
6bae0ccf 13292 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13293 rm -f conftest.er1
13294 cat conftest.err >&5
c0d27fcc 13295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13296 (exit $ac_status); } >/dev/null; then
13297 if test -s conftest.err; then
13298 ac_cpp_err=$ac_c_preproc_warn_flag
13299 else
13300 ac_cpp_err=
13301 fi
13302else
13303 ac_cpp_err=yes
13304fi
13305if test -z "$ac_cpp_err"; then
c0d27fcc 13306 ac_header_preproc=yes
98418dba
CW
13307else
13308 echo "$as_me: failed program was:" >&5
19650fd6
AS
13309sed 's/^/| /' conftest.$ac_ext >&5
13310
c0d27fcc 13311 ac_header_preproc=no
98418dba
CW
13312fi
13313rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13314echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13315echo "${ECHO_T}$ac_header_preproc" >&6
13316
13317# So? What about this header?
7c9e5167
JD
13318case $ac_header_compiler:$ac_header_preproc in
13319 yes:no )
c0d27fcc
MR
13320 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13321echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
13322 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13323echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13324 (
13325 cat <<\_ASBOX
13326## ------------------------------------ ##
13327## Report this to bug-autoconf@gnu.org. ##
13328## ------------------------------------ ##
13329_ASBOX
13330 ) |
13331 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 13332 ;;
7c9e5167 13333 no:yes )
c0d27fcc
MR
13334 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13335echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
13336 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13337echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 13338 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 13339echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
13340 (
13341 cat <<\_ASBOX
7c9e5167
JD
13342## ------------------------------------ ##
13343## Report this to bug-autoconf@gnu.org. ##
13344## ------------------------------------ ##
19650fd6
AS
13345_ASBOX
13346 ) |
13347 sed "s/^/$as_me: WARNING: /" >&2
13348 ;;
c0d27fcc
MR
13349esac
13350echo "$as_me:$LINENO: checking for $ac_header" >&5
13351echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13352if eval "test \"\${$as_ac_Header+set}\" = set"; then
13353 echo $ECHO_N "(cached) $ECHO_C" >&6
13354else
7c9e5167 13355 eval "$as_ac_Header=$ac_header_preproc"
ffe36136 13356fi
c0d27fcc 13357echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 13358echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13359
13360fi
98418dba 13361if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13362 cat >>confdefs.h <<_ACEOF
98418dba 13363#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 13364_ACEOF
98418dba
CW
13365
13366fi
c0d27fcc 13367
98418dba
CW
13368done
13369
c0d27fcc 13370
98418dba
CW
13371for ac_func in alarm
13372do
13373as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13374echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13375echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13376if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13377 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13378else
98418dba 13379 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13380#line $LINENO "configure"
19650fd6
AS
13381/* confdefs.h. */
13382_ACEOF
13383cat confdefs.h >>conftest.$ac_ext
13384cat >>conftest.$ac_ext <<_ACEOF
13385/* end confdefs.h. */
98418dba 13386/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13387 which can conflict with char $ac_func (); below.
13388 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13389 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
13390#ifdef __STDC__
13391# include <limits.h>
13392#else
13393# include <assert.h>
13394#endif
ba4481b5 13395/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13396#ifdef __cplusplus
13397extern "C"
19650fd6 13398{
503d2be0 13399#endif
ba4481b5 13400/* We use char because int might match the return type of a gcc2
503d2be0 13401 builtin and then its argument prototype would still apply. */
98418dba 13402char $ac_func ();
98418dba
CW
13403/* The GNU C library defines this for functions which it implements
13404 to always fail with ENOSYS. Some functions are actually named
13405 something starting with __ and the normal name is an alias. */
13406#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13407choke me
13408#else
19650fd6
AS
13409char (*f) () = $ac_func;
13410#endif
13411#ifdef __cplusplus
13412}
98418dba
CW
13413#endif
13414
19650fd6
AS
13415int
13416main ()
13417{
13418return f != $ac_func;
503d2be0
AS
13419 ;
13420 return 0;
13421}
13422_ACEOF
13423rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13424if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13425 (eval $ac_link) 2>&5
503d2be0 13426 ac_status=$?
c0d27fcc 13427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13428 (exit $ac_status); } &&
7c9e5167 13429 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13430 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13431 (eval $ac_try) 2>&5
13432 ac_status=$?
c0d27fcc 13433 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13434 (exit $ac_status); }; }; then
98418dba 13435 eval "$as_ac_var=yes"
503d2be0
AS
13436else
13437 echo "$as_me: failed program was:" >&5
19650fd6
AS
13438sed 's/^/| /' conftest.$ac_ext >&5
13439
98418dba 13440eval "$as_ac_var=no"
503d2be0 13441fi
7c9e5167 13442rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ffe36136 13443fi
c0d27fcc 13444echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13445echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13446if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13447 cat >>confdefs.h <<_ACEOF
98418dba 13448#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13449_ACEOF
ffe36136 13450
ba4481b5 13451fi
98418dba 13452done
ba4481b5 13453
c0d27fcc 13454echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
13455echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
13456if test "${ac_cv_func_working_mktime+set}" = set; then
13457 echo $ECHO_N "(cached) $ECHO_C" >&6
13458else
13459 if test "$cross_compiling" = yes; then
13460 ac_cv_func_working_mktime=no
13461else
13462 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13463#line $LINENO "configure"
19650fd6
AS
13464/* confdefs.h. */
13465_ACEOF
13466cat confdefs.h >>conftest.$ac_ext
13467cat >>conftest.$ac_ext <<_ACEOF
13468/* end confdefs.h. */
98418dba
CW
13469/* Test program from Paul Eggert and Tony Leneis. */
13470#if TIME_WITH_SYS_TIME
13471# include <sys/time.h>
13472# include <time.h>
13473#else
13474# if HAVE_SYS_TIME_H
13475# include <sys/time.h>
13476# else
13477# include <time.h>
13478# endif
13479#endif
ba4481b5 13480
98418dba
CW
13481#if HAVE_UNISTD_H
13482# include <unistd.h>
13483#endif
ba4481b5 13484
98418dba
CW
13485#if !HAVE_ALARM
13486# define alarm(X) /* empty */
13487#endif
df645f7c 13488
98418dba
CW
13489/* Work around redefinition to rpl_putenv by other config tests. */
13490#undef putenv
df645f7c 13491
98418dba 13492static time_t time_t_max;
df645f7c 13493
98418dba 13494/* Values we'll use to set the TZ environment variable. */
7c9e5167
JD
13495static const char *const tz_strings[] = {
13496 (const char *) 0, "TZ=GMT0", "TZ=JST-9",
98418dba
CW
13497 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
13498};
13499#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 13500
98418dba
CW
13501/* Fail if mktime fails to convert a date in the spring-forward gap.
13502 Based on a problem report from Andreas Jaeger. */
13503static void
13504spring_forward_gap ()
13505{
13506 /* glibc (up to about 1998-10-07) failed this test. */
13507 struct tm tm;
13508
13509 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
13510 instead of "TZ=America/Vancouver" in order to detect the bug even
13511 on systems that don't support the Olson extension, or don't have the
13512 full zoneinfo tables installed. */
13513 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
13514
13515 tm.tm_year = 98;
13516 tm.tm_mon = 3;
13517 tm.tm_mday = 5;
13518 tm.tm_hour = 2;
13519 tm.tm_min = 0;
13520 tm.tm_sec = 0;
13521 tm.tm_isdst = -1;
13522 if (mktime (&tm) == (time_t)-1)
13523 exit (1);
13524}
13525
13526static void
7c9e5167 13527mktime_test (now)
98418dba
CW
13528 time_t now;
13529{
13530 struct tm *lt;
13531 if ((lt = localtime (&now)) && mktime (lt) != now)
13532 exit (1);
7c9e5167
JD
13533 now = time_t_max - now;
13534 if ((lt = localtime (&now)) && mktime (lt) != now)
13535 exit (1);
98418dba
CW
13536}
13537
13538static void
13539irix_6_4_bug ()
13540{
13541 /* Based on code from Ariel Faigon. */
13542 struct tm tm;
13543 tm.tm_year = 96;
13544 tm.tm_mon = 3;
13545 tm.tm_mday = 0;
13546 tm.tm_hour = 0;
13547 tm.tm_min = 0;
13548 tm.tm_sec = 0;
13549 tm.tm_isdst = -1;
13550 mktime (&tm);
13551 if (tm.tm_mon != 2 || tm.tm_mday != 31)
13552 exit (1);
13553}
13554
13555static void
13556bigtime_test (j)
13557 int j;
13558{
13559 struct tm tm;
13560 time_t now;
13561 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
13562 now = mktime (&tm);
13563 if (now != (time_t) -1)
13564 {
13565 struct tm *lt = localtime (&now);
13566 if (! (lt
13567 && lt->tm_year == tm.tm_year
13568 && lt->tm_mon == tm.tm_mon
13569 && lt->tm_mday == tm.tm_mday
13570 && lt->tm_hour == tm.tm_hour
13571 && lt->tm_min == tm.tm_min
13572 && lt->tm_sec == tm.tm_sec
13573 && lt->tm_yday == tm.tm_yday
13574 && lt->tm_wday == tm.tm_wday
13575 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
13576 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
13577 exit (1);
13578 }
13579}
13580
13581int
13582main ()
13583{
13584 time_t t, delta;
13585 int i, j;
13586
13587 /* This test makes some buggy mktime implementations loop.
13588 Give up after 60 seconds; a mktime slower than that
13589 isn't worth using anyway. */
13590 alarm (60);
13591
13592 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
13593 continue;
13594 time_t_max--;
13595 delta = time_t_max / 997; /* a suitable prime number */
13596 for (i = 0; i < N_STRINGS; i++)
13597 {
13598 if (tz_strings[i])
13599 putenv (tz_strings[i]);
503d2be0 13600
98418dba
CW
13601 for (t = 0; t <= time_t_max - delta; t += delta)
13602 mktime_test (t);
7c9e5167
JD
13603 mktime_test ((time_t) 60 * 60);
13604 mktime_test ((time_t) 60 * 60 * 24);
98418dba
CW
13605
13606 for (j = 1; 0 < j; j *= 2)
7c9e5167 13607 bigtime_test (j);
98418dba
CW
13608 bigtime_test (j - 1);
13609 }
13610 irix_6_4_bug ();
13611 spring_forward_gap ();
13612 exit (0);
503d2be0
AS
13613}
13614_ACEOF
98418dba 13615rm -f conftest$ac_exeext
c0d27fcc 13616if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13617 (eval $ac_link) 2>&5
13618 ac_status=$?
c0d27fcc 13619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 13620 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 13621 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13622 (eval $ac_try) 2>&5
13623 ac_status=$?
c0d27fcc 13624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13625 (exit $ac_status); }; }; then
98418dba 13626 ac_cv_func_working_mktime=yes
503d2be0 13627else
98418dba
CW
13628 echo "$as_me: program exited with status $ac_status" >&5
13629echo "$as_me: failed program was:" >&5
19650fd6
AS
13630sed 's/^/| /' conftest.$ac_ext >&5
13631
c0d27fcc 13632( exit $ac_status )
98418dba 13633ac_cv_func_working_mktime=no
503d2be0 13634fi
7c9e5167 13635rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 13636fi
ba4481b5 13637fi
c0d27fcc 13638echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
13639echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
13640if test $ac_cv_func_working_mktime = no; then
7c9e5167 13641 LIBOBJS="$LIBOBJS mktime.$ac_objext"
ba4481b5
DL
13642fi
13643
98418dba 13644if test "$ac_cv_func_working_mktime" = no; then
b936fae4 13645
c0d27fcc 13646cat >>confdefs.h <<\_ACEOF
98418dba 13647#define BROKEN_MKTIME 1
c0d27fcc 13648_ACEOF
ba4481b5 13649
ba4481b5 13650fi
503d2be0 13651
98418dba
CW
13652ac_have_func=no # yes means we've found a way to get the load average.
13653
6bae0ccf
DL
13654# Make sure getloadavg.c is where it belongs, at configure-time.
13655test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
13656 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
13657echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
13658 { (exit 1); exit 1; }; }
13659
98418dba
CW
13660ac_save_LIBS=$LIBS
13661
13662# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 13663(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
13664echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
13665if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 13666 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13667else
503d2be0 13668 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13669#line $LINENO "configure"
19650fd6
AS
13670/* confdefs.h. */
13671_ACEOF
13672cat confdefs.h >>conftest.$ac_ext
13673cat >>conftest.$ac_ext <<_ACEOF
13674/* end confdefs.h. */
98418dba 13675/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13676 which can conflict with char getloadavg (); below.
13677 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13678 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
13679#ifdef __STDC__
13680# include <limits.h>
13681#else
13682# include <assert.h>
13683#endif
ba4481b5 13684/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13685#ifdef __cplusplus
13686extern "C"
19650fd6 13687{
503d2be0 13688#endif
ba4481b5 13689/* We use char because int might match the return type of a gcc2
503d2be0 13690 builtin and then its argument prototype would still apply. */
98418dba 13691char getloadavg ();
98418dba
CW
13692/* The GNU C library defines this for functions which it implements
13693 to always fail with ENOSYS. Some functions are actually named
13694 something starting with __ and the normal name is an alias. */
13695#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
13696choke me
13697#else
19650fd6
AS
13698char (*f) () = getloadavg;
13699#endif
13700#ifdef __cplusplus
13701}
cd958eb3
MB
13702#endif
13703
19650fd6
AS
13704int
13705main ()
13706{
13707return f != getloadavg;
503d2be0
AS
13708 ;
13709 return 0;
13710}
13711_ACEOF
13712rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13713if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13714 (eval $ac_link) 2>&5
503d2be0 13715 ac_status=$?
c0d27fcc 13716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13717 (exit $ac_status); } &&
7c9e5167 13718 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13720 (eval $ac_try) 2>&5
13721 ac_status=$?
c0d27fcc 13722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13723 (exit $ac_status); }; }; then
98418dba 13724 ac_cv_func_getloadavg=yes
503d2be0
AS
13725else
13726 echo "$as_me: failed program was:" >&5
19650fd6
AS
13727sed 's/^/| /' conftest.$ac_ext >&5
13728
98418dba 13729ac_cv_func_getloadavg=no
503d2be0 13730fi
7c9e5167 13731rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 13732fi
c0d27fcc 13733echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
13734echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
13735if test $ac_cv_func_getloadavg = yes; then
13736 exit 0
13737else
13738 exit 1
ba4481b5 13739fi
98418dba 13740) && ac_have_func=yes
ba4481b5 13741
98418dba 13742# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 13743
98418dba
CW
13744for ac_func in pstat_getdynamic
13745do
13746as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13747echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
13748echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13749if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13750 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13751else
503d2be0 13752 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13753#line $LINENO "configure"
19650fd6
AS
13754/* confdefs.h. */
13755_ACEOF
13756cat confdefs.h >>conftest.$ac_ext
13757cat >>conftest.$ac_ext <<_ACEOF
13758/* end confdefs.h. */
98418dba 13759/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
13760 which can conflict with char $ac_func (); below.
13761 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13762 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
13763#ifdef __STDC__
13764# include <limits.h>
13765#else
13766# include <assert.h>
13767#endif
ba4481b5 13768/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13769#ifdef __cplusplus
13770extern "C"
19650fd6 13771{
503d2be0 13772#endif
ba4481b5 13773/* We use char because int might match the return type of a gcc2
503d2be0 13774 builtin and then its argument prototype would still apply. */
98418dba 13775char $ac_func ();
98418dba
CW
13776/* The GNU C library defines this for functions which it implements
13777 to always fail with ENOSYS. Some functions are actually named
13778 something starting with __ and the normal name is an alias. */
13779#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13780choke me
13781#else
19650fd6
AS
13782char (*f) () = $ac_func;
13783#endif
13784#ifdef __cplusplus
13785}
98418dba
CW
13786#endif
13787
19650fd6
AS
13788int
13789main ()
13790{
13791return f != $ac_func;
98418dba
CW
13792 ;
13793 return 0;
13794}
f21fadcc 13795_ACEOF
98418dba 13796rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13797if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13798 (eval $ac_link) 2>&5
f21fadcc 13799 ac_status=$?
c0d27fcc 13800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 13801 (exit $ac_status); } &&
7c9e5167 13802 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13803 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
13804 (eval $ac_try) 2>&5
13805 ac_status=$?
c0d27fcc 13806 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13807 (exit $ac_status); }; }; then
13808 eval "$as_ac_var=yes"
f21fadcc
JD
13809else
13810 echo "$as_me: failed program was:" >&5
19650fd6
AS
13811sed 's/^/| /' conftest.$ac_ext >&5
13812
98418dba 13813eval "$as_ac_var=no"
f21fadcc 13814fi
7c9e5167 13815rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
f21fadcc 13816fi
c0d27fcc 13817echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
13818echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13819if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13820 cat >>confdefs.h <<_ACEOF
98418dba 13821#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13822_ACEOF
98418dba
CW
13823
13824fi
13825done
13826
c0d27fcc 13827
98418dba
CW
13828# Solaris has libkstat which does not require root.
13829
c0d27fcc 13830echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
13831echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
13832if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
13833 echo $ECHO_N "(cached) $ECHO_C" >&6
13834else
13835 ac_check_lib_save_LIBS=$LIBS
98418dba 13836LIBS="-lkstat $LIBS"
f21fadcc 13837cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13838#line $LINENO "configure"
19650fd6
AS
13839/* confdefs.h. */
13840_ACEOF
13841cat confdefs.h >>conftest.$ac_ext
13842cat >>conftest.$ac_ext <<_ACEOF
13843/* end confdefs.h. */
f21fadcc
JD
13844
13845/* Override any gcc2 internal prototype to avoid an error. */
13846#ifdef __cplusplus
13847extern "C"
13848#endif
13849/* We use char because int might match the return type of a gcc2
13850 builtin and then its argument prototype would still apply. */
98418dba 13851char kstat_open ();
f21fadcc
JD
13852int
13853main ()
13854{
98418dba 13855kstat_open ();
f21fadcc
JD
13856 ;
13857 return 0;
13858}
13859_ACEOF
13860rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13861if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13862 (eval $ac_link) 2>&5
f21fadcc 13863 ac_status=$?
c0d27fcc 13864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 13865 (exit $ac_status); } &&
7c9e5167 13866 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13867 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
13868 (eval $ac_try) 2>&5
13869 ac_status=$?
c0d27fcc 13870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 13871 (exit $ac_status); }; }; then
98418dba 13872 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
13873else
13874 echo "$as_me: failed program was:" >&5
19650fd6
AS
13875sed 's/^/| /' conftest.$ac_ext >&5
13876
98418dba 13877ac_cv_lib_kstat_kstat_open=no
f21fadcc 13878fi
7c9e5167 13879rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
f21fadcc
JD
13880LIBS=$ac_check_lib_save_LIBS
13881fi
c0d27fcc 13882echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
13883echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
13884if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 13885 cat >>confdefs.h <<_ACEOF
98418dba 13886#define HAVE_LIBKSTAT 1
c0d27fcc 13887_ACEOF
f21fadcc 13888
98418dba 13889 LIBS="-lkstat $LIBS"
f21fadcc 13890
f21fadcc
JD
13891fi
13892
98418dba
CW
13893test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
13894
13895# Some systems with -lutil have (and need) -lkvm as well, some do not.
13896# On Solaris, -lkvm requires nlist from -lelf, so check that first
13897# to get the right answer into the cache.
13898# For kstat on solaris, we need libelf to force the definition of SVR4 below.
13899if test $ac_have_func = no; then
c0d27fcc 13900 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
13901echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
13902if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 13903 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13904else
98418dba
CW
13905 ac_check_lib_save_LIBS=$LIBS
13906LIBS="-lelf $LIBS"
13907cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13908#line $LINENO "configure"
19650fd6
AS
13909/* confdefs.h. */
13910_ACEOF
13911cat confdefs.h >>conftest.$ac_ext
13912cat >>conftest.$ac_ext <<_ACEOF
13913/* end confdefs.h. */
98418dba
CW
13914
13915/* Override any gcc2 internal prototype to avoid an error. */
13916#ifdef __cplusplus
13917extern "C"
13918#endif
13919/* We use char because int might match the return type of a gcc2
13920 builtin and then its argument prototype would still apply. */
13921char elf_begin ();
503d2be0
AS
13922int
13923main ()
13924{
98418dba 13925elf_begin ();
503d2be0
AS
13926 ;
13927 return 0;
13928}
13929_ACEOF
13930rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13931if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13932 (eval $ac_link) 2>&5
503d2be0 13933 ac_status=$?
c0d27fcc 13934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13935 (exit $ac_status); } &&
7c9e5167 13936 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13937 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13938 (eval $ac_try) 2>&5
13939 ac_status=$?
c0d27fcc 13940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13941 (exit $ac_status); }; }; then
98418dba 13942 ac_cv_lib_elf_elf_begin=yes
ba4481b5 13943else
503d2be0 13944 echo "$as_me: failed program was:" >&5
19650fd6
AS
13945sed 's/^/| /' conftest.$ac_ext >&5
13946
98418dba 13947ac_cv_lib_elf_elf_begin=no
ba4481b5 13948fi
7c9e5167 13949rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 13950LIBS=$ac_check_lib_save_LIBS
ba4481b5 13951fi
c0d27fcc 13952echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
13953echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
13954if test $ac_cv_lib_elf_elf_begin = yes; then
13955 LIBS="-lelf $LIBS"
ba4481b5
DL
13956fi
13957
98418dba
CW
13958fi
13959if test $ac_have_func = no; then
c0d27fcc 13960 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
13961echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
13962if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 13963 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 13964else
98418dba
CW
13965 ac_check_lib_save_LIBS=$LIBS
13966LIBS="-lkvm $LIBS"
13967cat >conftest.$ac_ext <<_ACEOF
7c9e5167 13968#line $LINENO "configure"
19650fd6
AS
13969/* confdefs.h. */
13970_ACEOF
13971cat confdefs.h >>conftest.$ac_ext
13972cat >>conftest.$ac_ext <<_ACEOF
13973/* end confdefs.h. */
98418dba
CW
13974
13975/* Override any gcc2 internal prototype to avoid an error. */
13976#ifdef __cplusplus
13977extern "C"
13978#endif
13979/* We use char because int might match the return type of a gcc2
13980 builtin and then its argument prototype would still apply. */
13981char kvm_open ();
503d2be0
AS
13982int
13983main ()
13984{
98418dba 13985kvm_open ();
503d2be0
AS
13986 ;
13987 return 0;
13988}
13989_ACEOF
13990rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13991if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 13992 (eval $ac_link) 2>&5
503d2be0 13993 ac_status=$?
c0d27fcc 13994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13995 (exit $ac_status); } &&
7c9e5167 13996 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13997 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13998 (eval $ac_try) 2>&5
13999 ac_status=$?
c0d27fcc 14000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14001 (exit $ac_status); }; }; then
98418dba 14002 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
14003else
14004 echo "$as_me: failed program was:" >&5
19650fd6
AS
14005sed 's/^/| /' conftest.$ac_ext >&5
14006
98418dba 14007ac_cv_lib_kvm_kvm_open=no
503d2be0 14008fi
7c9e5167 14009rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 14010LIBS=$ac_check_lib_save_LIBS
503d2be0 14011fi
c0d27fcc 14012echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
14013echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
14014if test $ac_cv_lib_kvm_kvm_open = yes; then
14015 LIBS="-lkvm $LIBS"
ba4481b5
DL
14016fi
14017
98418dba 14018 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 14019 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
14020echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
14021if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 14022 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14023else
98418dba
CW
14024 ac_check_lib_save_LIBS=$LIBS
14025LIBS="-lutil $LIBS"
14026cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14027#line $LINENO "configure"
19650fd6
AS
14028/* confdefs.h. */
14029_ACEOF
14030cat confdefs.h >>conftest.$ac_ext
14031cat >>conftest.$ac_ext <<_ACEOF
14032/* end confdefs.h. */
98418dba
CW
14033
14034/* Override any gcc2 internal prototype to avoid an error. */
14035#ifdef __cplusplus
14036extern "C"
14037#endif
14038/* We use char because int might match the return type of a gcc2
14039 builtin and then its argument prototype would still apply. */
14040char getloadavg ();
503d2be0
AS
14041int
14042main ()
14043{
98418dba 14044getloadavg ();
503d2be0
AS
14045 ;
14046 return 0;
14047}
14048_ACEOF
14049rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14050if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 14051 (eval $ac_link) 2>&5
503d2be0 14052 ac_status=$?
c0d27fcc 14053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14054 (exit $ac_status); } &&
7c9e5167 14055 { ac_try='test -s conftest$ac_exeext'
35996d22
AS
14056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14057 (eval $ac_try) 2>&5
14058 ac_status=$?
14059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14060 (exit $ac_status); }; }; then
14061 ac_cv_lib_util_getloadavg=yes
14062else
503d2be0 14063 echo "$as_me: failed program was:" >&5
19650fd6
AS
14064sed 's/^/| /' conftest.$ac_ext >&5
14065
98418dba 14066ac_cv_lib_util_getloadavg=no
ba4481b5 14067fi
7c9e5167 14068rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14069LIBS=$ac_check_lib_save_LIBS
14070fi
c0d27fcc 14071echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
14072echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
14073if test $ac_cv_lib_util_getloadavg = yes; then
14074 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 14075fi
503d2be0 14076
98418dba 14077fi
ba4481b5 14078
98418dba
CW
14079if test $ac_have_func = no; then
14080 # There is a commonly available library for RS/6000 AIX.
14081 # Since it is not a standard part of AIX, it might be installed locally.
14082 ac_getloadavg_LIBS=$LIBS
14083 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 14084 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
14085echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
14086if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 14087 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14088else
98418dba
CW
14089 ac_check_lib_save_LIBS=$LIBS
14090LIBS="-lgetloadavg $LIBS"
14091cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14092#line $LINENO "configure"
19650fd6
AS
14093/* confdefs.h. */
14094_ACEOF
14095cat confdefs.h >>conftest.$ac_ext
14096cat >>conftest.$ac_ext <<_ACEOF
14097/* end confdefs.h. */
ba4481b5 14098
98418dba
CW
14099/* Override any gcc2 internal prototype to avoid an error. */
14100#ifdef __cplusplus
14101extern "C"
14102#endif
14103/* We use char because int might match the return type of a gcc2
14104 builtin and then its argument prototype would still apply. */
14105char getloadavg ();
98418dba
CW
14106int
14107main ()
14108{
14109getloadavg ();
14110 ;
14111 return 0;
14112}
503d2be0 14113_ACEOF
98418dba 14114rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14115if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 14116 (eval $ac_link) 2>&5
98418dba 14117 ac_status=$?
c0d27fcc 14118 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 14119 (exit $ac_status); } &&
7c9e5167 14120 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14121 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
14122 (eval $ac_try) 2>&5
14123 ac_status=$?
c0d27fcc 14124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14125 (exit $ac_status); }; }; then
14126 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 14127else
98418dba 14128 echo "$as_me: failed program was:" >&5
19650fd6
AS
14129sed 's/^/| /' conftest.$ac_ext >&5
14130
98418dba
CW
14131ac_cv_lib_getloadavg_getloadavg=no
14132fi
7c9e5167 14133rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
14134LIBS=$ac_check_lib_save_LIBS
14135fi
c0d27fcc 14136echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
14137echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
14138if test $ac_cv_lib_getloadavg_getloadavg = yes; then
14139 LIBS="-lgetloadavg $LIBS"
14140else
14141 LIBS=$ac_getloadavg_LIBS
ba4481b5 14142fi
ba4481b5
DL
14143
14144fi
98418dba
CW
14145
14146# Make sure it is really in the library, if we think we found it,
14147# otherwise set up the replacement function.
14148
14149for ac_func in getloadavg
14150do
14151as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14152echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
14153echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14154if eval "test \"\${$as_ac_var+set}\" = set"; then
14155 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14156else
503d2be0 14157 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14158#line $LINENO "configure"
19650fd6
AS
14159/* confdefs.h. */
14160_ACEOF
14161cat confdefs.h >>conftest.$ac_ext
14162cat >>conftest.$ac_ext <<_ACEOF
14163/* end confdefs.h. */
ba4481b5 14164/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14165 which can conflict with char $ac_func (); below.
14166 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14167 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
14168#ifdef __STDC__
14169# include <limits.h>
14170#else
14171# include <assert.h>
14172#endif
ba4481b5 14173/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14174#ifdef __cplusplus
14175extern "C"
19650fd6 14176{
503d2be0 14177#endif
ba4481b5 14178/* We use char because int might match the return type of a gcc2
503d2be0
AS
14179 builtin and then its argument prototype would still apply. */
14180char $ac_func ();
ba4481b5
DL
14181/* The GNU C library defines this for functions which it implements
14182 to always fail with ENOSYS. Some functions are actually named
14183 something starting with __ and the normal name is an alias. */
14184#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14185choke me
14186#else
19650fd6
AS
14187char (*f) () = $ac_func;
14188#endif
14189#ifdef __cplusplus
14190}
cd958eb3
MB
14191#endif
14192
19650fd6
AS
14193int
14194main ()
14195{
14196return f != $ac_func;
503d2be0
AS
14197 ;
14198 return 0;
14199}
14200_ACEOF
14201rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14202if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 14203 (eval $ac_link) 2>&5
503d2be0 14204 ac_status=$?
c0d27fcc 14205 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14206 (exit $ac_status); } &&
7c9e5167 14207 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14208 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14209 (eval $ac_try) 2>&5
14210 ac_status=$?
c0d27fcc 14211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14212 (exit $ac_status); }; }; then
14213 eval "$as_ac_var=yes"
14214else
14215 echo "$as_me: failed program was:" >&5
19650fd6
AS
14216sed 's/^/| /' conftest.$ac_ext >&5
14217
503d2be0
AS
14218eval "$as_ac_var=no"
14219fi
7c9e5167 14220rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 14221fi
c0d27fcc 14222echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14223echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14224if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14225 cat >>confdefs.h <<_ACEOF
98418dba 14226#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14227_ACEOF
503d2be0 14228
98418dba 14229else
7c9e5167 14230 LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
ba4481b5 14231
c0d27fcc 14232cat >>confdefs.h <<\_ACEOF
98418dba 14233#define C_GETLOADAVG 1
c0d27fcc 14234_ACEOF
ba4481b5 14235
98418dba
CW
14236# Figure out what our getloadavg.c needs.
14237ac_have_func=no
c0d27fcc
MR
14238if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14239 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
14240echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14241if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 14242 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14243fi
14244echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
14245echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 14246else
c0d27fcc
MR
14247 # Is the header compilable?
14248echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
14249echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
14250cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14251#line $LINENO "configure"
19650fd6
AS
14252/* confdefs.h. */
14253_ACEOF
14254cat confdefs.h >>conftest.$ac_ext
14255cat >>conftest.$ac_ext <<_ACEOF
14256/* end confdefs.h. */
c0d27fcc
MR
14257$ac_includes_default
14258#include <sys/dg_sys_info.h>
14259_ACEOF
14260rm -f conftest.$ac_objext
14261if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 14262 (eval $ac_compile) 2>&5
c0d27fcc
MR
14263 ac_status=$?
14264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14265 (exit $ac_status); } &&
7c9e5167 14266 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14267 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14268 (eval $ac_try) 2>&5
14269 ac_status=$?
14270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14271 (exit $ac_status); }; }; then
14272 ac_header_compiler=yes
14273else
14274 echo "$as_me: failed program was:" >&5
19650fd6
AS
14275sed 's/^/| /' conftest.$ac_ext >&5
14276
c0d27fcc
MR
14277ac_header_compiler=no
14278fi
7c9e5167 14279rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14280echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14281echo "${ECHO_T}$ac_header_compiler" >&6
14282
14283# Is the header present?
14284echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
14285echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
14286cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14287#line $LINENO "configure"
19650fd6
AS
14288/* confdefs.h. */
14289_ACEOF
14290cat confdefs.h >>conftest.$ac_ext
14291cat >>conftest.$ac_ext <<_ACEOF
14292/* end confdefs.h. */
98418dba
CW
14293#include <sys/dg_sys_info.h>
14294_ACEOF
c0d27fcc 14295if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
14296 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14297 ac_status=$?
6bae0ccf 14298 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14299 rm -f conftest.er1
14300 cat conftest.err >&5
c0d27fcc 14301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14302 (exit $ac_status); } >/dev/null; then
14303 if test -s conftest.err; then
14304 ac_cpp_err=$ac_c_preproc_warn_flag
14305 else
14306 ac_cpp_err=
14307 fi
14308else
14309 ac_cpp_err=yes
ba4481b5 14310fi
98418dba 14311if test -z "$ac_cpp_err"; then
c0d27fcc 14312 ac_header_preproc=yes
98418dba
CW
14313else
14314 echo "$as_me: failed program was:" >&5
19650fd6
AS
14315sed 's/^/| /' conftest.$ac_ext >&5
14316
c0d27fcc 14317 ac_header_preproc=no
ba4481b5 14318fi
98418dba 14319rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14320echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14321echo "${ECHO_T}$ac_header_preproc" >&6
14322
14323# So? What about this header?
7c9e5167
JD
14324case $ac_header_compiler:$ac_header_preproc in
14325 yes:no )
c0d27fcc
MR
14326 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
14327echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
14328 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
14329echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
14330 (
14331 cat <<\_ASBOX
14332## ------------------------------------ ##
14333## Report this to bug-autoconf@gnu.org. ##
14334## ------------------------------------ ##
14335_ASBOX
14336 ) |
14337 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 14338 ;;
7c9e5167 14339 no:yes )
c0d27fcc
MR
14340 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
14341echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
7c9e5167
JD
14342 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
14343echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 14344 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
19650fd6 14345echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
14346 (
14347 cat <<\_ASBOX
7c9e5167
JD
14348## ------------------------------------ ##
14349## Report this to bug-autoconf@gnu.org. ##
14350## ------------------------------------ ##
19650fd6
AS
14351_ASBOX
14352 ) |
14353 sed "s/^/$as_me: WARNING: /" >&2
14354 ;;
c0d27fcc
MR
14355esac
14356echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
14357echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
14358if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
14359 echo $ECHO_N "(cached) $ECHO_C" >&6
14360else
14361 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 14362fi
c0d27fcc 14363echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 14364echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
14365
14366fi
98418dba
CW
14367if test $ac_cv_header_sys_dg_sys_info_h = yes; then
14368 ac_have_func=yes
ba4481b5 14369
c0d27fcc 14370cat >>confdefs.h <<\_ACEOF
98418dba 14371#define DGUX 1
c0d27fcc
MR
14372_ACEOF
14373
503d2be0 14374
c0d27fcc 14375echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
14376echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
14377if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 14378 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14379else
503d2be0 14380 ac_check_lib_save_LIBS=$LIBS
98418dba 14381LIBS="-ldgc $LIBS"
503d2be0 14382cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14383#line $LINENO "configure"
19650fd6
AS
14384/* confdefs.h. */
14385_ACEOF
14386cat confdefs.h >>conftest.$ac_ext
14387cat >>conftest.$ac_ext <<_ACEOF
14388/* end confdefs.h. */
503d2be0 14389
ba4481b5 14390/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14391#ifdef __cplusplus
14392extern "C"
14393#endif
ba4481b5 14394/* We use char because int might match the return type of a gcc2
503d2be0 14395 builtin and then its argument prototype would still apply. */
98418dba 14396char dg_sys_info ();
503d2be0
AS
14397int
14398main ()
14399{
98418dba 14400dg_sys_info ();
503d2be0
AS
14401 ;
14402 return 0;
14403}
14404_ACEOF
14405rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14406if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 14407 (eval $ac_link) 2>&5
503d2be0 14408 ac_status=$?
c0d27fcc 14409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14410 (exit $ac_status); } &&
7c9e5167 14411 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14412 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14413 (eval $ac_try) 2>&5
14414 ac_status=$?
c0d27fcc 14415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14416 (exit $ac_status); }; }; then
98418dba 14417 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
14418else
14419 echo "$as_me: failed program was:" >&5
19650fd6
AS
14420sed 's/^/| /' conftest.$ac_ext >&5
14421
98418dba 14422ac_cv_lib_dgc_dg_sys_info=no
503d2be0 14423fi
7c9e5167 14424rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
14425LIBS=$ac_check_lib_save_LIBS
14426fi
c0d27fcc 14427echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
14428echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
14429if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 14430 cat >>confdefs.h <<_ACEOF
98418dba 14431#define HAVE_LIBDGC 1
c0d27fcc 14432_ACEOF
ba4481b5 14433
98418dba 14434 LIBS="-ldgc $LIBS"
ba4481b5 14435
ba4481b5
DL
14436fi
14437
98418dba 14438fi
503d2be0 14439
c0d27fcc
MR
14440
14441
14442if test "${ac_cv_header_locale_h+set}" = set; then
14443 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
14444echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
14445if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 14446 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14447fi
14448echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
14449echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 14450else
c0d27fcc
MR
14451 # Is the header compilable?
14452echo "$as_me:$LINENO: checking locale.h usability" >&5
14453echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
14454cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14455#line $LINENO "configure"
19650fd6
AS
14456/* confdefs.h. */
14457_ACEOF
14458cat confdefs.h >>conftest.$ac_ext
14459cat >>conftest.$ac_ext <<_ACEOF
14460/* end confdefs.h. */
c0d27fcc
MR
14461$ac_includes_default
14462#include <locale.h>
14463_ACEOF
14464rm -f conftest.$ac_objext
14465if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 14466 (eval $ac_compile) 2>&5
c0d27fcc
MR
14467 ac_status=$?
14468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14469 (exit $ac_status); } &&
7c9e5167 14470 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14471 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14472 (eval $ac_try) 2>&5
14473 ac_status=$?
14474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14475 (exit $ac_status); }; }; then
14476 ac_header_compiler=yes
14477else
14478 echo "$as_me: failed program was:" >&5
19650fd6
AS
14479sed 's/^/| /' conftest.$ac_ext >&5
14480
c0d27fcc
MR
14481ac_header_compiler=no
14482fi
7c9e5167 14483rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14484echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14485echo "${ECHO_T}$ac_header_compiler" >&6
14486
14487# Is the header present?
14488echo "$as_me:$LINENO: checking locale.h presence" >&5
14489echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
14490cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14491#line $LINENO "configure"
19650fd6
AS
14492/* confdefs.h. */
14493_ACEOF
14494cat confdefs.h >>conftest.$ac_ext
14495cat >>conftest.$ac_ext <<_ACEOF
14496/* end confdefs.h. */
98418dba 14497#include <locale.h>
503d2be0 14498_ACEOF
c0d27fcc 14499if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 14500 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 14501 ac_status=$?
6bae0ccf 14502 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14503 rm -f conftest.er1
14504 cat conftest.err >&5
c0d27fcc 14505 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14506 (exit $ac_status); } >/dev/null; then
14507 if test -s conftest.err; then
14508 ac_cpp_err=$ac_c_preproc_warn_flag
14509 else
14510 ac_cpp_err=
14511 fi
503d2be0 14512else
98418dba 14513 ac_cpp_err=yes
503d2be0 14514fi
98418dba 14515if test -z "$ac_cpp_err"; then
c0d27fcc 14516 ac_header_preproc=yes
98418dba
CW
14517else
14518 echo "$as_me: failed program was:" >&5
19650fd6
AS
14519sed 's/^/| /' conftest.$ac_ext >&5
14520
c0d27fcc 14521 ac_header_preproc=no
ba4481b5 14522fi
98418dba 14523rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14524echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14525echo "${ECHO_T}$ac_header_preproc" >&6
14526
14527# So? What about this header?
7c9e5167
JD
14528case $ac_header_compiler:$ac_header_preproc in
14529 yes:no )
c0d27fcc
MR
14530 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
14531echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
14532 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
14533echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
14534 (
14535 cat <<\_ASBOX
14536## ------------------------------------ ##
14537## Report this to bug-autoconf@gnu.org. ##
14538## ------------------------------------ ##
14539_ASBOX
14540 ) |
14541 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 14542 ;;
7c9e5167 14543 no:yes )
c0d27fcc
MR
14544 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
14545echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
7c9e5167
JD
14546 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
14547echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 14548 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
19650fd6 14549echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
14550 (
14551 cat <<\_ASBOX
7c9e5167
JD
14552## ------------------------------------ ##
14553## Report this to bug-autoconf@gnu.org. ##
14554## ------------------------------------ ##
19650fd6
AS
14555_ASBOX
14556 ) |
14557 sed "s/^/$as_me: WARNING: /" >&2
14558 ;;
c0d27fcc
MR
14559esac
14560echo "$as_me:$LINENO: checking for locale.h" >&5
14561echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
14562if test "${ac_cv_header_locale_h+set}" = set; then
14563 echo $ECHO_N "(cached) $ECHO_C" >&6
14564else
14565 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 14566fi
c0d27fcc 14567echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
14568echo "${ECHO_T}$ac_cv_header_locale_h" >&6
14569
c0d27fcc
MR
14570fi
14571
14572
14573
98418dba 14574for ac_func in setlocale
ba4481b5 14575do
503d2be0 14576as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 14577echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
14578echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14579if eval "test \"\${$as_ac_var+set}\" = set"; then
14580 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14581else
503d2be0 14582 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14583#line $LINENO "configure"
19650fd6
AS
14584/* confdefs.h. */
14585_ACEOF
14586cat confdefs.h >>conftest.$ac_ext
14587cat >>conftest.$ac_ext <<_ACEOF
14588/* end confdefs.h. */
ba4481b5 14589/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
14590 which can conflict with char $ac_func (); below.
14591 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14592 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
14593#ifdef __STDC__
14594# include <limits.h>
14595#else
14596# include <assert.h>
14597#endif
ba4481b5 14598/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14599#ifdef __cplusplus
14600extern "C"
19650fd6 14601{
503d2be0 14602#endif
ba4481b5 14603/* We use char because int might match the return type of a gcc2
503d2be0
AS
14604 builtin and then its argument prototype would still apply. */
14605char $ac_func ();
ba4481b5
DL
14606/* The GNU C library defines this for functions which it implements
14607 to always fail with ENOSYS. Some functions are actually named
14608 something starting with __ and the normal name is an alias. */
14609#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14610choke me
14611#else
19650fd6
AS
14612char (*f) () = $ac_func;
14613#endif
14614#ifdef __cplusplus
14615}
ba4481b5
DL
14616#endif
14617
19650fd6
AS
14618int
14619main ()
14620{
14621return f != $ac_func;
503d2be0
AS
14622 ;
14623 return 0;
14624}
14625_ACEOF
14626rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14627if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 14628 (eval $ac_link) 2>&5
503d2be0 14629 ac_status=$?
c0d27fcc 14630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 14631 (exit $ac_status); } &&
7c9e5167 14632 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14633 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14634 (eval $ac_try) 2>&5
14635 ac_status=$?
c0d27fcc 14636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14637 (exit $ac_status); }; }; then
14638 eval "$as_ac_var=yes"
14639else
14640 echo "$as_me: failed program was:" >&5
19650fd6
AS
14641sed 's/^/| /' conftest.$ac_ext >&5
14642
503d2be0
AS
14643eval "$as_ac_var=no"
14644fi
7c9e5167 14645rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 14646fi
c0d27fcc 14647echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14648echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14649if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14650 cat >>confdefs.h <<_ACEOF
503d2be0 14651#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14652_ACEOF
ba4481b5 14653
ba4481b5
DL
14654fi
14655done
14656
c0d27fcc 14657
98418dba
CW
14658# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
14659# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
14660# Irix 4.0.5F has the header but not the library.
14661if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
14662 ac_have_func=yes
14663
c0d27fcc 14664cat >>confdefs.h <<\_ACEOF
98418dba 14665#define SVR4 1
c0d27fcc 14666_ACEOF
98418dba
CW
14667
14668fi
14669
14670if test $ac_have_func = no; then
c0d27fcc
MR
14671 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
14672 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
14673echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
14674if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 14675 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14676fi
14677echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
14678echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 14679else
c0d27fcc
MR
14680 # Is the header compilable?
14681echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
14682echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
14683cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14684#line $LINENO "configure"
19650fd6
AS
14685/* confdefs.h. */
14686_ACEOF
14687cat confdefs.h >>conftest.$ac_ext
14688cat >>conftest.$ac_ext <<_ACEOF
14689/* end confdefs.h. */
c0d27fcc
MR
14690$ac_includes_default
14691#include <inq_stats/cpustats.h>
14692_ACEOF
14693rm -f conftest.$ac_objext
14694if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 14695 (eval $ac_compile) 2>&5
c0d27fcc
MR
14696 ac_status=$?
14697 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14698 (exit $ac_status); } &&
7c9e5167 14699 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14700 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14701 (eval $ac_try) 2>&5
14702 ac_status=$?
14703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14704 (exit $ac_status); }; }; then
14705 ac_header_compiler=yes
14706else
14707 echo "$as_me: failed program was:" >&5
19650fd6
AS
14708sed 's/^/| /' conftest.$ac_ext >&5
14709
c0d27fcc
MR
14710ac_header_compiler=no
14711fi
7c9e5167 14712rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14713echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14714echo "${ECHO_T}$ac_header_compiler" >&6
14715
14716# Is the header present?
14717echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
14718echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
14719cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14720#line $LINENO "configure"
19650fd6
AS
14721/* confdefs.h. */
14722_ACEOF
14723cat confdefs.h >>conftest.$ac_ext
14724cat >>conftest.$ac_ext <<_ACEOF
14725/* end confdefs.h. */
98418dba 14726#include <inq_stats/cpustats.h>
503d2be0 14727_ACEOF
c0d27fcc 14728if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
14729 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14730 ac_status=$?
6bae0ccf 14731 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
14732 rm -f conftest.er1
14733 cat conftest.err >&5
c0d27fcc 14734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14735 (exit $ac_status); } >/dev/null; then
14736 if test -s conftest.err; then
14737 ac_cpp_err=$ac_c_preproc_warn_flag
14738 else
14739 ac_cpp_err=
14740 fi
14741else
14742 ac_cpp_err=yes
14743fi
14744if test -z "$ac_cpp_err"; then
c0d27fcc 14745 ac_header_preproc=yes
503d2be0
AS
14746else
14747 echo "$as_me: failed program was:" >&5
19650fd6
AS
14748sed 's/^/| /' conftest.$ac_ext >&5
14749
c0d27fcc 14750 ac_header_preproc=no
ba4481b5 14751fi
503d2be0 14752rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14753echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14754echo "${ECHO_T}$ac_header_preproc" >&6
14755
14756# So? What about this header?
7c9e5167
JD
14757case $ac_header_compiler:$ac_header_preproc in
14758 yes:no )
c0d27fcc
MR
14759 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
14760echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
14761 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
14762echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
14763 (
14764 cat <<\_ASBOX
14765## ------------------------------------ ##
14766## Report this to bug-autoconf@gnu.org. ##
14767## ------------------------------------ ##
14768_ASBOX
14769 ) |
14770 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 14771 ;;
7c9e5167 14772 no:yes )
c0d27fcc
MR
14773 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
14774echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
7c9e5167
JD
14775 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
14776echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 14777 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 14778echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
14779 (
14780 cat <<\_ASBOX
7c9e5167
JD
14781## ------------------------------------ ##
14782## Report this to bug-autoconf@gnu.org. ##
14783## ------------------------------------ ##
19650fd6
AS
14784_ASBOX
14785 ) |
14786 sed "s/^/$as_me: WARNING: /" >&2
14787 ;;
c0d27fcc
MR
14788esac
14789echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
14790echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
14791if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
14792 echo $ECHO_N "(cached) $ECHO_C" >&6
14793else
14794 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 14795fi
c0d27fcc 14796echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 14797echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
14798
14799fi
98418dba
CW
14800if test $ac_cv_header_inq_stats_cpustats_h = yes; then
14801 ac_have_func=yes
ba4481b5 14802
c0d27fcc 14803cat >>confdefs.h <<\_ACEOF
98418dba 14804#define UMAX 1
c0d27fcc 14805_ACEOF
98418dba 14806
c0d27fcc
MR
14807
14808cat >>confdefs.h <<\_ACEOF
98418dba 14809#define UMAX4_3 1
c0d27fcc 14810_ACEOF
98418dba
CW
14811
14812fi
14813
c0d27fcc 14814
98418dba
CW
14815fi
14816
14817if test $ac_have_func = no; then
c0d27fcc
MR
14818 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
14819 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
14820echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
14821if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 14822 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14823fi
14824echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
14825echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 14826else
c0d27fcc
MR
14827 # Is the header compilable?
14828echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
14829echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
14830cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14831#line $LINENO "configure"
19650fd6
AS
14832/* confdefs.h. */
14833_ACEOF
14834cat confdefs.h >>conftest.$ac_ext
14835cat >>conftest.$ac_ext <<_ACEOF
14836/* end confdefs.h. */
c0d27fcc
MR
14837$ac_includes_default
14838#include <sys/cpustats.h>
14839_ACEOF
14840rm -f conftest.$ac_objext
14841if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 14842 (eval $ac_compile) 2>&5
c0d27fcc
MR
14843 ac_status=$?
14844 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14845 (exit $ac_status); } &&
7c9e5167 14846 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14847 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14848 (eval $ac_try) 2>&5
14849 ac_status=$?
14850 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14851 (exit $ac_status); }; }; then
14852 ac_header_compiler=yes
14853else
14854 echo "$as_me: failed program was:" >&5
19650fd6
AS
14855sed 's/^/| /' conftest.$ac_ext >&5
14856
c0d27fcc
MR
14857ac_header_compiler=no
14858fi
7c9e5167 14859rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
14860echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14861echo "${ECHO_T}$ac_header_compiler" >&6
14862
14863# Is the header present?
14864echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
14865echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
14866cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14867#line $LINENO "configure"
19650fd6
AS
14868/* confdefs.h. */
14869_ACEOF
14870cat confdefs.h >>conftest.$ac_ext
14871cat >>conftest.$ac_ext <<_ACEOF
14872/* end confdefs.h. */
98418dba
CW
14873#include <sys/cpustats.h>
14874_ACEOF
c0d27fcc 14875if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
14876 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14877 ac_status=$?
6bae0ccf 14878 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
14879 rm -f conftest.er1
14880 cat conftest.err >&5
c0d27fcc 14881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
14882 (exit $ac_status); } >/dev/null; then
14883 if test -s conftest.err; then
14884 ac_cpp_err=$ac_c_preproc_warn_flag
14885 else
14886 ac_cpp_err=
14887 fi
14888else
14889 ac_cpp_err=yes
503d2be0 14890fi
98418dba 14891if test -z "$ac_cpp_err"; then
c0d27fcc 14892 ac_header_preproc=yes
98418dba
CW
14893else
14894 echo "$as_me: failed program was:" >&5
19650fd6
AS
14895sed 's/^/| /' conftest.$ac_ext >&5
14896
c0d27fcc 14897 ac_header_preproc=no
98418dba
CW
14898fi
14899rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
14900echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14901echo "${ECHO_T}$ac_header_preproc" >&6
14902
14903# So? What about this header?
7c9e5167
JD
14904case $ac_header_compiler:$ac_header_preproc in
14905 yes:no )
c0d27fcc
MR
14906 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
14907echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
14908 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
14909echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
14910 (
14911 cat <<\_ASBOX
14912## ------------------------------------ ##
14913## Report this to bug-autoconf@gnu.org. ##
14914## ------------------------------------ ##
14915_ASBOX
14916 ) |
14917 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 14918 ;;
7c9e5167 14919 no:yes )
c0d27fcc
MR
14920 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
14921echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
7c9e5167
JD
14922 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
14923echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 14924 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
19650fd6 14925echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
14926 (
14927 cat <<\_ASBOX
7c9e5167
JD
14928## ------------------------------------ ##
14929## Report this to bug-autoconf@gnu.org. ##
14930## ------------------------------------ ##
19650fd6
AS
14931_ASBOX
14932 ) |
14933 sed "s/^/$as_me: WARNING: /" >&2
14934 ;;
c0d27fcc
MR
14935esac
14936echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
14937echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
14938if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
14939 echo $ECHO_N "(cached) $ECHO_C" >&6
14940else
14941 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 14942fi
c0d27fcc 14943echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 14944echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
14945
14946fi
98418dba 14947if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 14948 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 14949#define UMAX 1
c0d27fcc 14950_ACEOF
ba4481b5 14951
98418dba
CW
14952fi
14953
c0d27fcc 14954
98418dba
CW
14955fi
14956
14957if test $ac_have_func = no; then
14958
14959for ac_header in mach/mach.h
2c9dccc9
PJ
14960do
14961as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
14962if eval "test \"\${$as_ac_Header+set}\" = set"; then
14963 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
14964echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
14965if eval "test \"\${$as_ac_Header+set}\" = set"; then
14966 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
14967fi
14968echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
14969echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 14970else
c0d27fcc
MR
14971 # Is the header compilable?
14972echo "$as_me:$LINENO: checking $ac_header usability" >&5
14973echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
14974cat >conftest.$ac_ext <<_ACEOF
7c9e5167 14975#line $LINENO "configure"
19650fd6
AS
14976/* confdefs.h. */
14977_ACEOF
14978cat confdefs.h >>conftest.$ac_ext
14979cat >>conftest.$ac_ext <<_ACEOF
14980/* end confdefs.h. */
c0d27fcc
MR
14981$ac_includes_default
14982#include <$ac_header>
14983_ACEOF
14984rm -f conftest.$ac_objext
14985if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 14986 (eval $ac_compile) 2>&5
c0d27fcc
MR
14987 ac_status=$?
14988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14989 (exit $ac_status); } &&
7c9e5167 14990 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
14991 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14992 (eval $ac_try) 2>&5
14993 ac_status=$?
14994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14995 (exit $ac_status); }; }; then
14996 ac_header_compiler=yes
14997else
14998 echo "$as_me: failed program was:" >&5
19650fd6
AS
14999sed 's/^/| /' conftest.$ac_ext >&5
15000
c0d27fcc
MR
15001ac_header_compiler=no
15002fi
7c9e5167 15003rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15004echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15005echo "${ECHO_T}$ac_header_compiler" >&6
15006
15007# Is the header present?
15008echo "$as_me:$LINENO: checking $ac_header presence" >&5
15009echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15010cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15011#line $LINENO "configure"
19650fd6
AS
15012/* confdefs.h. */
15013_ACEOF
15014cat confdefs.h >>conftest.$ac_ext
15015cat >>conftest.$ac_ext <<_ACEOF
15016/* end confdefs.h. */
2c9dccc9
PJ
15017#include <$ac_header>
15018_ACEOF
c0d27fcc 15019if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
15020 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15021 ac_status=$?
6bae0ccf 15022 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
15023 rm -f conftest.er1
15024 cat conftest.err >&5
c0d27fcc 15025 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
15026 (exit $ac_status); } >/dev/null; then
15027 if test -s conftest.err; then
15028 ac_cpp_err=$ac_c_preproc_warn_flag
15029 else
15030 ac_cpp_err=
15031 fi
15032else
15033 ac_cpp_err=yes
15034fi
15035if test -z "$ac_cpp_err"; then
c0d27fcc
MR
15036 ac_header_preproc=yes
15037else
15038 echo "$as_me: failed program was:" >&5
19650fd6
AS
15039sed 's/^/| /' conftest.$ac_ext >&5
15040
c0d27fcc
MR
15041 ac_header_preproc=no
15042fi
15043rm -f conftest.err conftest.$ac_ext
15044echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15045echo "${ECHO_T}$ac_header_preproc" >&6
15046
15047# So? What about this header?
7c9e5167
JD
15048case $ac_header_compiler:$ac_header_preproc in
15049 yes:no )
c0d27fcc
MR
15050 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15051echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
15052 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15053echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15054 (
15055 cat <<\_ASBOX
15056## ------------------------------------ ##
15057## Report this to bug-autoconf@gnu.org. ##
15058## ------------------------------------ ##
15059_ASBOX
15060 ) |
15061 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 15062 ;;
7c9e5167 15063 no:yes )
c0d27fcc
MR
15064 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15065echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
15066 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15067echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 15068 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15069echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
15070 (
15071 cat <<\_ASBOX
7c9e5167
JD
15072## ------------------------------------ ##
15073## Report this to bug-autoconf@gnu.org. ##
15074## ------------------------------------ ##
19650fd6
AS
15075_ASBOX
15076 ) |
15077 sed "s/^/$as_me: WARNING: /" >&2
15078 ;;
c0d27fcc
MR
15079esac
15080echo "$as_me:$LINENO: checking for $ac_header" >&5
15081echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15082if eval "test \"\${$as_ac_Header+set}\" = set"; then
15083 echo $ECHO_N "(cached) $ECHO_C" >&6
15084else
7c9e5167 15085 eval "$as_ac_Header=$ac_header_preproc"
c0d27fcc
MR
15086fi
15087echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15088echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15089
15090fi
15091if test `eval echo '${'$as_ac_Header'}'` = yes; then
15092 cat >>confdefs.h <<_ACEOF
15093#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15094_ACEOF
15095
15096fi
15097
15098done
15099
15100fi
15101
15102
15103for ac_header in nlist.h
15104do
15105as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15106if eval "test \"\${$as_ac_Header+set}\" = set"; then
15107 echo "$as_me:$LINENO: checking for $ac_header" >&5
15108echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15109if eval "test \"\${$as_ac_Header+set}\" = set"; then
15110 echo $ECHO_N "(cached) $ECHO_C" >&6
15111fi
15112echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15113echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15114else
15115 # Is the header compilable?
15116echo "$as_me:$LINENO: checking $ac_header usability" >&5
15117echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15118cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15119#line $LINENO "configure"
19650fd6
AS
15120/* confdefs.h. */
15121_ACEOF
15122cat confdefs.h >>conftest.$ac_ext
15123cat >>conftest.$ac_ext <<_ACEOF
15124/* end confdefs.h. */
c0d27fcc
MR
15125$ac_includes_default
15126#include <$ac_header>
15127_ACEOF
15128rm -f conftest.$ac_objext
15129if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15130 (eval $ac_compile) 2>&5
c0d27fcc
MR
15131 ac_status=$?
15132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15133 (exit $ac_status); } &&
7c9e5167 15134 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
15135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15136 (eval $ac_try) 2>&5
15137 ac_status=$?
15138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15139 (exit $ac_status); }; }; then
15140 ac_header_compiler=yes
2c9dccc9
PJ
15141else
15142 echo "$as_me: failed program was:" >&5
19650fd6
AS
15143sed 's/^/| /' conftest.$ac_ext >&5
15144
c0d27fcc 15145ac_header_compiler=no
98418dba 15146fi
7c9e5167 15147rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
15148echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15149echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 15150
c0d27fcc
MR
15151# Is the header present?
15152echo "$as_me:$LINENO: checking $ac_header presence" >&5
15153echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15154cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15155#line $LINENO "configure"
19650fd6
AS
15156/* confdefs.h. */
15157_ACEOF
15158cat confdefs.h >>conftest.$ac_ext
15159cat >>conftest.$ac_ext <<_ACEOF
15160/* end confdefs.h. */
503d2be0
AS
15161#include <$ac_header>
15162_ACEOF
c0d27fcc 15163if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15164 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15165 ac_status=$?
6bae0ccf 15166 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15167 rm -f conftest.er1
15168 cat conftest.err >&5
c0d27fcc 15169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15170 (exit $ac_status); } >/dev/null; then
15171 if test -s conftest.err; then
15172 ac_cpp_err=$ac_c_preproc_warn_flag
15173 else
15174 ac_cpp_err=
15175 fi
15176else
15177 ac_cpp_err=yes
15178fi
15179if test -z "$ac_cpp_err"; then
c0d27fcc 15180 ac_header_preproc=yes
503d2be0
AS
15181else
15182 echo "$as_me: failed program was:" >&5
19650fd6
AS
15183sed 's/^/| /' conftest.$ac_ext >&5
15184
c0d27fcc 15185 ac_header_preproc=no
b5de8dc0 15186fi
503d2be0 15187rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15188echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15189echo "${ECHO_T}$ac_header_preproc" >&6
15190
15191# So? What about this header?
7c9e5167
JD
15192case $ac_header_compiler:$ac_header_preproc in
15193 yes:no )
c0d27fcc
MR
15194 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15195echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
15196 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
15197echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15198 (
15199 cat <<\_ASBOX
15200## ------------------------------------ ##
15201## Report this to bug-autoconf@gnu.org. ##
15202## ------------------------------------ ##
15203_ASBOX
15204 ) |
15205 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 15206 ;;
7c9e5167 15207 no:yes )
c0d27fcc
MR
15208 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15209echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
15210 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15211echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 15212 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 15213echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
15214 (
15215 cat <<\_ASBOX
7c9e5167
JD
15216## ------------------------------------ ##
15217## Report this to bug-autoconf@gnu.org. ##
15218## ------------------------------------ ##
19650fd6
AS
15219_ASBOX
15220 ) |
15221 sed "s/^/$as_me: WARNING: /" >&2
15222 ;;
c0d27fcc
MR
15223esac
15224echo "$as_me:$LINENO: checking for $ac_header" >&5
15225echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15226if eval "test \"\${$as_ac_Header+set}\" = set"; then
15227 echo $ECHO_N "(cached) $ECHO_C" >&6
15228else
7c9e5167 15229 eval "$as_ac_Header=$ac_header_preproc"
b5de8dc0 15230fi
c0d27fcc 15231echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15232echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15233
15234fi
98418dba 15235if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15236 cat >>confdefs.h <<_ACEOF
98418dba 15237#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
15238_ACEOF
15239 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
15240echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
15241if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 15242 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 15243else
503d2be0 15244 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15245#line $LINENO "configure"
19650fd6
AS
15246/* confdefs.h. */
15247_ACEOF
15248cat confdefs.h >>conftest.$ac_ext
15249cat >>conftest.$ac_ext <<_ACEOF
15250/* end confdefs.h. */
98418dba 15251#include <nlist.h>
b5de8dc0 15252
503d2be0
AS
15253int
15254main ()
15255{
98418dba
CW
15256static struct nlist ac_aggr;
15257if (ac_aggr.n_un.n_name)
15258return 0;
503d2be0
AS
15259 ;
15260 return 0;
15261}
15262_ACEOF
98418dba 15263rm -f conftest.$ac_objext
c0d27fcc 15264if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15265 (eval $ac_compile) 2>&5
503d2be0 15266 ac_status=$?
c0d27fcc 15267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15268 (exit $ac_status); } &&
7c9e5167 15269 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15270 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15271 (eval $ac_try) 2>&5
15272 ac_status=$?
c0d27fcc 15273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15274 (exit $ac_status); }; }; then
98418dba 15275 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
15276else
15277 echo "$as_me: failed program was:" >&5
19650fd6
AS
15278sed 's/^/| /' conftest.$ac_ext >&5
15279
6bae0ccf 15280cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15281#line $LINENO "configure"
19650fd6
AS
15282/* confdefs.h. */
15283_ACEOF
15284cat confdefs.h >>conftest.$ac_ext
15285cat >>conftest.$ac_ext <<_ACEOF
15286/* end confdefs.h. */
6bae0ccf
DL
15287#include <nlist.h>
15288
15289int
15290main ()
15291{
15292static struct nlist ac_aggr;
15293if (sizeof ac_aggr.n_un.n_name)
15294return 0;
15295 ;
15296 return 0;
15297}
15298_ACEOF
15299rm -f conftest.$ac_objext
15300if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15301 (eval $ac_compile) 2>&5
6bae0ccf
DL
15302 ac_status=$?
15303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15304 (exit $ac_status); } &&
7c9e5167 15305 { ac_try='test -s conftest.$ac_objext'
6bae0ccf
DL
15306 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15307 (eval $ac_try) 2>&5
15308 ac_status=$?
15309 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15310 (exit $ac_status); }; }; then
15311 ac_cv_member_struct_nlist_n_un_n_name=yes
15312else
15313 echo "$as_me: failed program was:" >&5
19650fd6
AS
15314sed 's/^/| /' conftest.$ac_ext >&5
15315
98418dba 15316ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 15317fi
7c9e5167 15318rm -f conftest.$ac_objext conftest.$ac_ext
b5de8dc0 15319fi
7c9e5167 15320rm -f conftest.$ac_objext conftest.$ac_ext
6bae0ccf 15321fi
c0d27fcc 15322echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
15323echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
15324if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 15325
c0d27fcc 15326cat >>confdefs.h <<_ACEOF
98418dba 15327#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 15328_ACEOF
b5de8dc0 15329
c0d27fcc
MR
15330
15331cat >>confdefs.h <<\_ACEOF
98418dba 15332#define NLIST_NAME_UNION 1
c0d27fcc 15333_ACEOF
b5de8dc0 15334
98418dba 15335fi
b5de8dc0 15336
c0d27fcc 15337
98418dba 15338fi
c0d27fcc 15339
98418dba 15340done
b5de8dc0 15341
98418dba
CW
15342fi
15343done
b5de8dc0 15344
c0d27fcc 15345
98418dba 15346# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 15347echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
15348echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
15349if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
15350 echo $ECHO_N "(cached) $ECHO_C" >&6
15351else
15352 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15353#line $LINENO "configure"
19650fd6
AS
15354/* confdefs.h. */
15355_ACEOF
15356cat confdefs.h >>conftest.$ac_ext
15357cat >>conftest.$ac_ext <<_ACEOF
15358/* end confdefs.h. */
6bae0ccf 15359#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
15360#ifdef LDAV_PRIVILEGED
15361Yowza Am I SETGID yet
15362#endif
15363_ACEOF
15364if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 15365 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
15366 ac_cv_func_getloadavg_setgid=yes
15367else
15368 ac_cv_func_getloadavg_setgid=no
15369fi
15370rm -f conftest*
b5de8dc0 15371
98418dba 15372fi
c0d27fcc 15373echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
15374echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
15375if test $ac_cv_func_getloadavg_setgid = yes; then
15376 NEED_SETGID=true
b5de8dc0 15377
c0d27fcc 15378cat >>confdefs.h <<\_ACEOF
98418dba 15379#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 15380_ACEOF
98418dba 15381
b5de8dc0 15382else
98418dba 15383 NEED_SETGID=false
b5de8dc0 15384fi
98418dba
CW
15385
15386if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 15387 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
15388echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
15389if test "${ac_cv_group_kmem+set}" = set; then
15390 echo $ECHO_N "(cached) $ECHO_C" >&6
15391else
15392 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
15393 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
15394 # If we got an error (system does not support symlinks), try without -L.
15395 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
15396 ac_cv_group_kmem=`echo $ac_ls_output \
7c9e5167 15397 | sed -ne 's/[ ][ ]*/ /g;
98418dba
CW
15398 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
15399 / /s/.* //;p;'`
15400
b5de8dc0 15401fi
c0d27fcc 15402echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
15403echo "${ECHO_T}$ac_cv_group_kmem" >&6
15404 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 15405fi
98418dba
CW
15406if test "x$ac_save_LIBS" = x; then
15407 GETLOADAVG_LIBS=$LIBS
15408else
15409 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 15410fi
98418dba 15411LIBS=$ac_save_LIBS
b5de8dc0 15412
c0d27fcc
MR
15413
15414
15415echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
15416echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
15417if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 15418 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 15419else
b936fae4
AS
15420 while :; do
15421 ac_cv_sys_largefile_source=no
503d2be0 15422 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15423#line $LINENO "configure"
19650fd6
AS
15424/* confdefs.h. */
15425_ACEOF
15426cat confdefs.h >>conftest.$ac_ext
15427cat >>conftest.$ac_ext <<_ACEOF
15428/* end confdefs.h. */
b936fae4 15429#include <stdio.h>
503d2be0
AS
15430int
15431main ()
15432{
b936fae4
AS
15433return !fseeko;
15434 ;
15435 return 0;
15436}
15437_ACEOF
15438rm -f conftest.$ac_objext
c0d27fcc 15439if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15440 (eval $ac_compile) 2>&5
b936fae4 15441 ac_status=$?
c0d27fcc 15442 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 15443 (exit $ac_status); } &&
7c9e5167 15444 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15445 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
15446 (eval $ac_try) 2>&5
15447 ac_status=$?
c0d27fcc 15448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
15449 (exit $ac_status); }; }; then
15450 break
15451else
15452 echo "$as_me: failed program was:" >&5
19650fd6
AS
15453sed 's/^/| /' conftest.$ac_ext >&5
15454
b936fae4 15455fi
7c9e5167 15456rm -f conftest.$ac_objext conftest.$ac_ext
b936fae4 15457 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15458#line $LINENO "configure"
19650fd6
AS
15459/* confdefs.h. */
15460_ACEOF
15461cat confdefs.h >>conftest.$ac_ext
15462cat >>conftest.$ac_ext <<_ACEOF
15463/* end confdefs.h. */
b936fae4
AS
15464#define _LARGEFILE_SOURCE 1
15465#include <stdio.h>
b936fae4
AS
15466int
15467main ()
15468{
15469return !fseeko;
15470 ;
15471 return 0;
15472}
15473_ACEOF
15474rm -f conftest.$ac_objext
c0d27fcc 15475if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15476 (eval $ac_compile) 2>&5
b936fae4 15477 ac_status=$?
c0d27fcc 15478 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4 15479 (exit $ac_status); } &&
7c9e5167 15480 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 15481 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
15482 (eval $ac_try) 2>&5
15483 ac_status=$?
c0d27fcc 15484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
15485 (exit $ac_status); }; }; then
15486 ac_cv_sys_largefile_source=1; break
15487else
15488 echo "$as_me: failed program was:" >&5
19650fd6
AS
15489sed 's/^/| /' conftest.$ac_ext >&5
15490
b936fae4 15491fi
7c9e5167 15492rm -f conftest.$ac_objext conftest.$ac_ext
b936fae4
AS
15493 break
15494done
15495fi
c0d27fcc 15496echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
15497echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
15498if test "$ac_cv_sys_largefile_source" != no; then
15499
c0d27fcc 15500cat >>confdefs.h <<_ACEOF
b936fae4 15501#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 15502_ACEOF
b936fae4
AS
15503
15504fi
15505rm -f conftest*
4c343001 15506
b936fae4
AS
15507# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15508# in glibc 2.1.3, but that breaks too many other things.
15509# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 15510echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
15511echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
15512if test "${ac_cv_func_fseeko+set}" = set; then
15513 echo $ECHO_N "(cached) $ECHO_C" >&6
15514else
15515 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15516#line $LINENO "configure"
19650fd6
AS
15517/* confdefs.h. */
15518_ACEOF
15519cat confdefs.h >>conftest.$ac_ext
15520cat >>conftest.$ac_ext <<_ACEOF
15521/* end confdefs.h. */
b936fae4 15522#include <stdio.h>
b936fae4
AS
15523int
15524main ()
15525{
15526return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
15527 ;
15528 return 0;
15529}
15530_ACEOF
15531rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15532if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15533 (eval $ac_link) 2>&5
503d2be0 15534 ac_status=$?
c0d27fcc 15535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15536 (exit $ac_status); } &&
7c9e5167 15537 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15539 (eval $ac_try) 2>&5
15540 ac_status=$?
c0d27fcc 15541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15542 (exit $ac_status); }; }; then
b936fae4 15543 ac_cv_func_fseeko=yes
503d2be0
AS
15544else
15545 echo "$as_me: failed program was:" >&5
19650fd6
AS
15546sed 's/^/| /' conftest.$ac_ext >&5
15547
b936fae4 15548ac_cv_func_fseeko=no
503d2be0 15549fi
7c9e5167 15550rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 15551fi
c0d27fcc 15552echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
15553echo "${ECHO_T}$ac_cv_func_fseeko" >&6
15554if test $ac_cv_func_fseeko = yes; then
15555
c0d27fcc 15556cat >>confdefs.h <<\_ACEOF
b936fae4 15557#define HAVE_FSEEKO 1
c0d27fcc 15558_ACEOF
b936fae4 15559
4c343001
DL
15560fi
15561
c0d27fcc 15562
cd958eb3
MB
15563echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
15564echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
15565if test "${ac_cv_func_getpgrp_void+set}" = set; then
15566 echo $ECHO_N "(cached) $ECHO_C" >&6
15567else
15568 # Use it with a single arg.
15569cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15570#line $LINENO "configure"
19650fd6
AS
15571/* confdefs.h. */
15572_ACEOF
15573cat confdefs.h >>conftest.$ac_ext
15574cat >>conftest.$ac_ext <<_ACEOF
15575/* end confdefs.h. */
cd958eb3
MB
15576$ac_includes_default
15577int
15578main ()
15579{
15580getpgrp (0);
15581 ;
15582 return 0;
15583}
15584_ACEOF
15585rm -f conftest.$ac_objext
15586if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 15587 (eval $ac_compile) 2>&5
cd958eb3
MB
15588 ac_status=$?
15589 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15590 (exit $ac_status); } &&
7c9e5167 15591 { ac_try='test -s conftest.$ac_objext'
cd958eb3
MB
15592 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15593 (eval $ac_try) 2>&5
15594 ac_status=$?
15595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15596 (exit $ac_status); }; }; then
15597 ac_cv_func_getpgrp_void=no
15598else
15599 echo "$as_me: failed program was:" >&5
19650fd6
AS
15600sed 's/^/| /' conftest.$ac_ext >&5
15601
cd958eb3
MB
15602ac_cv_func_getpgrp_void=yes
15603fi
7c9e5167 15604rm -f conftest.$ac_objext conftest.$ac_ext
cd958eb3
MB
15605
15606fi
15607echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
15608echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
15609if test $ac_cv_func_getpgrp_void = yes; then
15610
15611cat >>confdefs.h <<\_ACEOF
15612#define GETPGRP_VOID 1
15613_ACEOF
15614
15615fi
15616
15617
973a76b1
DL
15618
15619for ac_func in strftime
15620do
15621as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15622echo "$as_me:$LINENO: checking for $ac_func" >&5
15623echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15624if eval "test \"\${$as_ac_var+set}\" = set"; then
15625 echo $ECHO_N "(cached) $ECHO_C" >&6
15626else
15627 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15628#line $LINENO "configure"
19650fd6
AS
15629/* confdefs.h. */
15630_ACEOF
15631cat confdefs.h >>conftest.$ac_ext
15632cat >>conftest.$ac_ext <<_ACEOF
15633/* end confdefs.h. */
973a76b1 15634/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15635 which can conflict with char $ac_func (); below.
15636 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15637 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
15638#ifdef __STDC__
15639# include <limits.h>
15640#else
15641# include <assert.h>
15642#endif
973a76b1
DL
15643/* Override any gcc2 internal prototype to avoid an error. */
15644#ifdef __cplusplus
15645extern "C"
19650fd6 15646{
973a76b1
DL
15647#endif
15648/* We use char because int might match the return type of a gcc2
15649 builtin and then its argument prototype would still apply. */
15650char $ac_func ();
15651/* The GNU C library defines this for functions which it implements
15652 to always fail with ENOSYS. Some functions are actually named
15653 something starting with __ and the normal name is an alias. */
15654#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15655choke me
15656#else
19650fd6
AS
15657char (*f) () = $ac_func;
15658#endif
15659#ifdef __cplusplus
15660}
973a76b1
DL
15661#endif
15662
19650fd6
AS
15663int
15664main ()
15665{
15666return f != $ac_func;
973a76b1
DL
15667 ;
15668 return 0;
15669}
15670_ACEOF
15671rm -f conftest.$ac_objext conftest$ac_exeext
15672if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15673 (eval $ac_link) 2>&5
973a76b1
DL
15674 ac_status=$?
15675 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15676 (exit $ac_status); } &&
7c9e5167 15677 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
15678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15679 (eval $ac_try) 2>&5
15680 ac_status=$?
15681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15682 (exit $ac_status); }; }; then
15683 eval "$as_ac_var=yes"
15684else
15685 echo "$as_me: failed program was:" >&5
19650fd6
AS
15686sed 's/^/| /' conftest.$ac_ext >&5
15687
973a76b1
DL
15688eval "$as_ac_var=no"
15689fi
7c9e5167 15690rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
15691fi
15692echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15693echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15694if test `eval echo '${'$as_ac_var'}'` = yes; then
15695 cat >>confdefs.h <<_ACEOF
15696#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15697_ACEOF
15698
15699else
15700 # strftime is in -lintl on SCO UNIX.
15701echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
15702echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6
15703if test "${ac_cv_lib_intl_strftime+set}" = set; then
15704 echo $ECHO_N "(cached) $ECHO_C" >&6
15705else
15706 ac_check_lib_save_LIBS=$LIBS
15707LIBS="-lintl $LIBS"
15708cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15709#line $LINENO "configure"
19650fd6
AS
15710/* confdefs.h. */
15711_ACEOF
15712cat confdefs.h >>conftest.$ac_ext
15713cat >>conftest.$ac_ext <<_ACEOF
15714/* end confdefs.h. */
973a76b1
DL
15715
15716/* Override any gcc2 internal prototype to avoid an error. */
15717#ifdef __cplusplus
15718extern "C"
15719#endif
15720/* We use char because int might match the return type of a gcc2
15721 builtin and then its argument prototype would still apply. */
15722char strftime ();
15723int
15724main ()
15725{
15726strftime ();
15727 ;
15728 return 0;
15729}
15730_ACEOF
15731rm -f conftest.$ac_objext conftest$ac_exeext
15732if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15733 (eval $ac_link) 2>&5
973a76b1
DL
15734 ac_status=$?
15735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15736 (exit $ac_status); } &&
7c9e5167 15737 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
15738 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15739 (eval $ac_try) 2>&5
15740 ac_status=$?
15741 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15742 (exit $ac_status); }; }; then
15743 ac_cv_lib_intl_strftime=yes
15744else
15745 echo "$as_me: failed program was:" >&5
19650fd6
AS
15746sed 's/^/| /' conftest.$ac_ext >&5
15747
973a76b1
DL
15748ac_cv_lib_intl_strftime=no
15749fi
7c9e5167 15750rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
15751LIBS=$ac_check_lib_save_LIBS
15752fi
15753echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
15754echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6
15755if test $ac_cv_lib_intl_strftime = yes; then
15756 cat >>confdefs.h <<\_ACEOF
15757#define HAVE_STRFTIME 1
15758_ACEOF
15759
15760LIBS="-lintl $LIBS"
15761fi
15762
15763fi
15764done
15765
15766
b936fae4
AS
15767# UNIX98 PTYs.
15768
15769for ac_func in grantpt
503d2be0
AS
15770do
15771as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15772echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
15773echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15774if eval "test \"\${$as_ac_var+set}\" = set"; then
15775 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 15776else
503d2be0 15777 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15778#line $LINENO "configure"
19650fd6
AS
15779/* confdefs.h. */
15780_ACEOF
15781cat confdefs.h >>conftest.$ac_ext
15782cat >>conftest.$ac_ext <<_ACEOF
15783/* end confdefs.h. */
503d2be0 15784/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15785 which can conflict with char $ac_func (); below.
15786 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15787 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
15788#ifdef __STDC__
15789# include <limits.h>
15790#else
15791# include <assert.h>
15792#endif
4c343001 15793/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15794#ifdef __cplusplus
15795extern "C"
19650fd6 15796{
503d2be0 15797#endif
4c343001 15798/* We use char because int might match the return type of a gcc2
503d2be0
AS
15799 builtin and then its argument prototype would still apply. */
15800char $ac_func ();
503d2be0
AS
15801/* The GNU C library defines this for functions which it implements
15802 to always fail with ENOSYS. Some functions are actually named
15803 something starting with __ and the normal name is an alias. */
15804#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15805choke me
15806#else
19650fd6
AS
15807char (*f) () = $ac_func;
15808#endif
15809#ifdef __cplusplus
15810}
503d2be0 15811#endif
4c343001 15812
19650fd6
AS
15813int
15814main ()
15815{
15816return f != $ac_func;
503d2be0
AS
15817 ;
15818 return 0;
15819}
15820_ACEOF
15821rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15822if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15823 (eval $ac_link) 2>&5
503d2be0 15824 ac_status=$?
c0d27fcc 15825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15826 (exit $ac_status); } &&
7c9e5167 15827 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15828 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15829 (eval $ac_try) 2>&5
15830 ac_status=$?
c0d27fcc 15831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15832 (exit $ac_status); }; }; then
15833 eval "$as_ac_var=yes"
15834else
15835 echo "$as_me: failed program was:" >&5
19650fd6
AS
15836sed 's/^/| /' conftest.$ac_ext >&5
15837
503d2be0
AS
15838eval "$as_ac_var=no"
15839fi
7c9e5167 15840rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 15841fi
c0d27fcc 15842echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15843echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15844if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15845 cat >>confdefs.h <<_ACEOF
503d2be0 15846#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15847_ACEOF
4c343001
DL
15848
15849fi
503d2be0
AS
15850done
15851
c0d27fcc 15852
b936fae4 15853# PTY-related GNU extensions.
4c343001 15854
b936fae4
AS
15855for ac_func in getpt
15856do
15857as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 15858echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
15859echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15860if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 15861 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 15862else
b936fae4 15863 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15864#line $LINENO "configure"
19650fd6
AS
15865/* confdefs.h. */
15866_ACEOF
15867cat confdefs.h >>conftest.$ac_ext
15868cat >>conftest.$ac_ext <<_ACEOF
15869/* end confdefs.h. */
087121cc 15870/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
15871 which can conflict with char $ac_func (); below.
15872 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15873 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
15874#ifdef __STDC__
15875# include <limits.h>
15876#else
15877# include <assert.h>
15878#endif
087121cc 15879/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15880#ifdef __cplusplus
15881extern "C"
19650fd6 15882{
503d2be0 15883#endif
087121cc 15884/* We use char because int might match the return type of a gcc2
503d2be0
AS
15885 builtin and then its argument prototype would still apply. */
15886char $ac_func ();
087121cc
GM
15887/* The GNU C library defines this for functions which it implements
15888 to always fail with ENOSYS. Some functions are actually named
15889 something starting with __ and the normal name is an alias. */
15890#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15891choke me
15892#else
19650fd6
AS
15893char (*f) () = $ac_func;
15894#endif
15895#ifdef __cplusplus
15896}
087121cc
GM
15897#endif
15898
19650fd6
AS
15899int
15900main ()
15901{
15902return f != $ac_func;
503d2be0
AS
15903 ;
15904 return 0;
15905}
15906_ACEOF
15907rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15908if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15909 (eval $ac_link) 2>&5
503d2be0 15910 ac_status=$?
c0d27fcc 15911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15912 (exit $ac_status); } &&
7c9e5167 15913 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15914 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15915 (eval $ac_try) 2>&5
15916 ac_status=$?
c0d27fcc 15917 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15918 (exit $ac_status); }; }; then
15919 eval "$as_ac_var=yes"
15920else
15921 echo "$as_me: failed program was:" >&5
19650fd6
AS
15922sed 's/^/| /' conftest.$ac_ext >&5
15923
503d2be0
AS
15924eval "$as_ac_var=no"
15925fi
7c9e5167 15926rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 15927fi
c0d27fcc 15928echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
15929echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15930if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 15931 cat >>confdefs.h <<_ACEOF
503d2be0 15932#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 15933_ACEOF
087121cc 15934
087121cc
GM
15935fi
15936done
15937
c0d27fcc 15938
ba4481b5
DL
15939# Check this now, so that we will NOT find the above functions in ncurses.
15940# That is because we have not set up to link ncurses in lib-src.
15941# It's better to believe a function is not available
15942# than to expect to find it in ncurses.
503d2be0 15943
c0d27fcc 15944echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
15945echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
15946if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
15947 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 15948else
503d2be0 15949 ac_check_lib_save_LIBS=$LIBS
ba4481b5 15950LIBS="-lncurses $LIBS"
503d2be0 15951cat >conftest.$ac_ext <<_ACEOF
7c9e5167 15952#line $LINENO "configure"
19650fd6
AS
15953/* confdefs.h. */
15954_ACEOF
15955cat confdefs.h >>conftest.$ac_ext
15956cat >>conftest.$ac_ext <<_ACEOF
15957/* end confdefs.h. */
503d2be0 15958
ba4481b5 15959/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
15960#ifdef __cplusplus
15961extern "C"
15962#endif
ba4481b5 15963/* We use char because int might match the return type of a gcc2
503d2be0
AS
15964 builtin and then its argument prototype would still apply. */
15965char tparm ();
15966int
15967main ()
15968{
15969tparm ();
15970 ;
15971 return 0;
15972}
15973_ACEOF
15974rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 15975if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 15976 (eval $ac_link) 2>&5
503d2be0 15977 ac_status=$?
c0d27fcc 15978 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 15979 (exit $ac_status); } &&
7c9e5167 15980 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 15981 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15982 (eval $ac_try) 2>&5
15983 ac_status=$?
c0d27fcc 15984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15985 (exit $ac_status); }; }; then
15986 ac_cv_lib_ncurses_tparm=yes
15987else
15988 echo "$as_me: failed program was:" >&5
19650fd6
AS
15989sed 's/^/| /' conftest.$ac_ext >&5
15990
503d2be0
AS
15991ac_cv_lib_ncurses_tparm=no
15992fi
7c9e5167 15993rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
15994LIBS=$ac_check_lib_save_LIBS
15995fi
c0d27fcc 15996echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
15997echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
15998if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 15999 cat >>confdefs.h <<_ACEOF
503d2be0 16000#define HAVE_LIBNCURSES 1
c0d27fcc 16001_ACEOF
ba4481b5
DL
16002
16003 LIBS="-lncurses $LIBS"
16004
ba4481b5
DL
16005fi
16006
c0d27fcc 16007
84e70f78
KR
16008# Do we need the Hesiod library to provide the support routines?
16009if test "$with_hesiod" = yes ; then
16010 # Don't set $LIBS here -- see comments above.
16011 resolv=no
c0d27fcc 16012 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
16013echo $ECHO_N "checking for res_send... $ECHO_C" >&6
16014if test "${ac_cv_func_res_send+set}" = set; then
16015 echo $ECHO_N "(cached) $ECHO_C" >&6
16016else
16017 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16018#line $LINENO "configure"
19650fd6
AS
16019/* confdefs.h. */
16020_ACEOF
16021cat confdefs.h >>conftest.$ac_ext
16022cat >>conftest.$ac_ext <<_ACEOF
16023/* end confdefs.h. */
84e70f78 16024/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16025 which can conflict with char res_send (); below.
16026 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16027 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
16028#ifdef __STDC__
16029# include <limits.h>
16030#else
16031# include <assert.h>
16032#endif
84e70f78
KR
16033/* Override any gcc2 internal prototype to avoid an error. */
16034#ifdef __cplusplus
16035extern "C"
19650fd6 16036{
84e70f78
KR
16037#endif
16038/* We use char because int might match the return type of a gcc2
16039 builtin and then its argument prototype would still apply. */
16040char res_send ();
84e70f78
KR
16041/* The GNU C library defines this for functions which it implements
16042 to always fail with ENOSYS. Some functions are actually named
16043 something starting with __ and the normal name is an alias. */
16044#if defined (__stub_res_send) || defined (__stub___res_send)
16045choke me
16046#else
19650fd6
AS
16047char (*f) () = res_send;
16048#endif
16049#ifdef __cplusplus
16050}
cd958eb3
MB
16051#endif
16052
19650fd6
AS
16053int
16054main ()
16055{
16056return f != res_send;
84e70f78
KR
16057 ;
16058 return 0;
16059}
16060_ACEOF
16061rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16062if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16063 (eval $ac_link) 2>&5
84e70f78 16064 ac_status=$?
c0d27fcc 16065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16066 (exit $ac_status); } &&
7c9e5167 16067 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16069 (eval $ac_try) 2>&5
16070 ac_status=$?
c0d27fcc 16071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16072 (exit $ac_status); }; }; then
16073 ac_cv_func_res_send=yes
16074else
16075 echo "$as_me: failed program was:" >&5
19650fd6
AS
16076sed 's/^/| /' conftest.$ac_ext >&5
16077
84e70f78
KR
16078ac_cv_func_res_send=no
16079fi
7c9e5167 16080rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78 16081fi
c0d27fcc 16082echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
16083echo "${ECHO_T}$ac_cv_func_res_send" >&6
16084if test $ac_cv_func_res_send = yes; then
16085 :
16086else
c0d27fcc 16087 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
16088echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
16089if test "${ac_cv_func___res_send+set}" = set; then
16090 echo $ECHO_N "(cached) $ECHO_C" >&6
16091else
16092 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16093#line $LINENO "configure"
19650fd6
AS
16094/* confdefs.h. */
16095_ACEOF
16096cat confdefs.h >>conftest.$ac_ext
16097cat >>conftest.$ac_ext <<_ACEOF
16098/* end confdefs.h. */
84e70f78 16099/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16100 which can conflict with char __res_send (); below.
16101 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16102 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
16103#ifdef __STDC__
16104# include <limits.h>
16105#else
16106# include <assert.h>
16107#endif
84e70f78
KR
16108/* Override any gcc2 internal prototype to avoid an error. */
16109#ifdef __cplusplus
16110extern "C"
19650fd6 16111{
84e70f78
KR
16112#endif
16113/* We use char because int might match the return type of a gcc2
16114 builtin and then its argument prototype would still apply. */
16115char __res_send ();
84e70f78
KR
16116/* The GNU C library defines this for functions which it implements
16117 to always fail with ENOSYS. Some functions are actually named
16118 something starting with __ and the normal name is an alias. */
16119#if defined (__stub___res_send) || defined (__stub_____res_send)
16120choke me
16121#else
19650fd6
AS
16122char (*f) () = __res_send;
16123#endif
16124#ifdef __cplusplus
16125}
84e70f78
KR
16126#endif
16127
19650fd6
AS
16128int
16129main ()
16130{
16131return f != __res_send;
84e70f78
KR
16132 ;
16133 return 0;
16134}
16135_ACEOF
16136rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16137if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16138 (eval $ac_link) 2>&5
84e70f78 16139 ac_status=$?
c0d27fcc 16140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16141 (exit $ac_status); } &&
7c9e5167 16142 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16143 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16144 (eval $ac_try) 2>&5
16145 ac_status=$?
c0d27fcc 16146 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16147 (exit $ac_status); }; }; then
16148 ac_cv_func___res_send=yes
16149else
16150 echo "$as_me: failed program was:" >&5
19650fd6
AS
16151sed 's/^/| /' conftest.$ac_ext >&5
16152
84e70f78
KR
16153ac_cv_func___res_send=no
16154fi
7c9e5167 16155rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78 16156fi
c0d27fcc 16157echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
16158echo "${ECHO_T}$ac_cv_func___res_send" >&6
16159if test $ac_cv_func___res_send = yes; then
16160 :
16161else
c0d27fcc 16162 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
16163echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
16164if test "${ac_cv_lib_resolv_res_send+set}" = set; then
16165 echo $ECHO_N "(cached) $ECHO_C" >&6
16166else
16167 ac_check_lib_save_LIBS=$LIBS
16168LIBS="-lresolv $LIBS"
16169cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16170#line $LINENO "configure"
19650fd6
AS
16171/* confdefs.h. */
16172_ACEOF
16173cat confdefs.h >>conftest.$ac_ext
16174cat >>conftest.$ac_ext <<_ACEOF
16175/* end confdefs.h. */
84e70f78
KR
16176
16177/* Override any gcc2 internal prototype to avoid an error. */
16178#ifdef __cplusplus
16179extern "C"
16180#endif
16181/* We use char because int might match the return type of a gcc2
16182 builtin and then its argument prototype would still apply. */
16183char res_send ();
16184int
16185main ()
16186{
16187res_send ();
16188 ;
16189 return 0;
16190}
16191_ACEOF
16192rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16193if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16194 (eval $ac_link) 2>&5
84e70f78 16195 ac_status=$?
c0d27fcc 16196 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16197 (exit $ac_status); } &&
7c9e5167 16198 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16199 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16200 (eval $ac_try) 2>&5
16201 ac_status=$?
c0d27fcc 16202 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16203 (exit $ac_status); }; }; then
16204 ac_cv_lib_resolv_res_send=yes
16205else
16206 echo "$as_me: failed program was:" >&5
19650fd6
AS
16207sed 's/^/| /' conftest.$ac_ext >&5
16208
84e70f78
KR
16209ac_cv_lib_resolv_res_send=no
16210fi
7c9e5167 16211rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16212LIBS=$ac_check_lib_save_LIBS
16213fi
c0d27fcc 16214echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
16215echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
16216if test $ac_cv_lib_resolv_res_send = yes; then
16217 resolv=yes
16218else
c0d27fcc 16219 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
16220echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
16221if test "${ac_cv_lib_resolv___res_send+set}" = set; then
16222 echo $ECHO_N "(cached) $ECHO_C" >&6
16223else
16224 ac_check_lib_save_LIBS=$LIBS
16225LIBS="-lresolv $LIBS"
16226cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16227#line $LINENO "configure"
19650fd6
AS
16228/* confdefs.h. */
16229_ACEOF
16230cat confdefs.h >>conftest.$ac_ext
16231cat >>conftest.$ac_ext <<_ACEOF
16232/* end confdefs.h. */
84e70f78
KR
16233
16234/* Override any gcc2 internal prototype to avoid an error. */
16235#ifdef __cplusplus
16236extern "C"
16237#endif
16238/* We use char because int might match the return type of a gcc2
16239 builtin and then its argument prototype would still apply. */
16240char __res_send ();
16241int
16242main ()
16243{
16244__res_send ();
16245 ;
16246 return 0;
16247}
16248_ACEOF
16249rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16250if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16251 (eval $ac_link) 2>&5
84e70f78 16252 ac_status=$?
c0d27fcc 16253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16254 (exit $ac_status); } &&
7c9e5167 16255 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16256 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16257 (eval $ac_try) 2>&5
16258 ac_status=$?
c0d27fcc 16259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16260 (exit $ac_status); }; }; then
16261 ac_cv_lib_resolv___res_send=yes
16262else
16263 echo "$as_me: failed program was:" >&5
19650fd6
AS
16264sed 's/^/| /' conftest.$ac_ext >&5
16265
84e70f78
KR
16266ac_cv_lib_resolv___res_send=no
16267fi
7c9e5167 16268rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16269LIBS=$ac_check_lib_save_LIBS
16270fi
c0d27fcc 16271echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
16272echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
16273if test $ac_cv_lib_resolv___res_send = yes; then
16274 resolv=yes
16275fi
16276
16277fi
16278
16279fi
16280
16281fi
16282
16283 if test "$resolv" = yes ; then
16284 RESOLVLIB=-lresolv
b936fae4 16285
c0d27fcc 16286cat >>confdefs.h <<\_ACEOF
84e70f78 16287#define HAVE_LIBRESOLV 1
c0d27fcc 16288_ACEOF
84e70f78
KR
16289
16290 else
16291 RESOLVLIB=
16292 fi
c0d27fcc 16293 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
16294echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
16295if test "${ac_cv_func_hes_getmailhost+set}" = set; then
16296 echo $ECHO_N "(cached) $ECHO_C" >&6
16297else
16298 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16299#line $LINENO "configure"
19650fd6
AS
16300/* confdefs.h. */
16301_ACEOF
16302cat confdefs.h >>conftest.$ac_ext
16303cat >>conftest.$ac_ext <<_ACEOF
16304/* end confdefs.h. */
84e70f78 16305/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
16306 which can conflict with char hes_getmailhost (); below.
16307 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16308 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
16309#ifdef __STDC__
16310# include <limits.h>
16311#else
16312# include <assert.h>
16313#endif
84e70f78
KR
16314/* Override any gcc2 internal prototype to avoid an error. */
16315#ifdef __cplusplus
16316extern "C"
19650fd6 16317{
84e70f78
KR
16318#endif
16319/* We use char because int might match the return type of a gcc2
16320 builtin and then its argument prototype would still apply. */
16321char hes_getmailhost ();
84e70f78
KR
16322/* The GNU C library defines this for functions which it implements
16323 to always fail with ENOSYS. Some functions are actually named
16324 something starting with __ and the normal name is an alias. */
16325#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
16326choke me
16327#else
19650fd6
AS
16328char (*f) () = hes_getmailhost;
16329#endif
16330#ifdef __cplusplus
16331}
cd958eb3
MB
16332#endif
16333
19650fd6
AS
16334int
16335main ()
16336{
16337return f != hes_getmailhost;
84e70f78
KR
16338 ;
16339 return 0;
16340}
16341_ACEOF
16342rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16343if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16344 (eval $ac_link) 2>&5
84e70f78 16345 ac_status=$?
c0d27fcc 16346 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16347 (exit $ac_status); } &&
7c9e5167 16348 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16349 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16350 (eval $ac_try) 2>&5
16351 ac_status=$?
c0d27fcc 16352 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16353 (exit $ac_status); }; }; then
16354 ac_cv_func_hes_getmailhost=yes
16355else
16356 echo "$as_me: failed program was:" >&5
19650fd6
AS
16357sed 's/^/| /' conftest.$ac_ext >&5
16358
84e70f78
KR
16359ac_cv_func_hes_getmailhost=no
16360fi
7c9e5167 16361rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78 16362fi
c0d27fcc 16363echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
16364echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
16365if test $ac_cv_func_hes_getmailhost = yes; then
16366 :
16367else
c0d27fcc 16368 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
16369echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
16370if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
16371 echo $ECHO_N "(cached) $ECHO_C" >&6
16372else
16373 ac_check_lib_save_LIBS=$LIBS
16374LIBS="-lhesiod $RESOLVLIB $LIBS"
16375cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16376#line $LINENO "configure"
19650fd6
AS
16377/* confdefs.h. */
16378_ACEOF
16379cat confdefs.h >>conftest.$ac_ext
16380cat >>conftest.$ac_ext <<_ACEOF
16381/* end confdefs.h. */
84e70f78
KR
16382
16383/* Override any gcc2 internal prototype to avoid an error. */
16384#ifdef __cplusplus
16385extern "C"
16386#endif
16387/* We use char because int might match the return type of a gcc2
16388 builtin and then its argument prototype would still apply. */
16389char hes_getmailhost ();
16390int
16391main ()
16392{
16393hes_getmailhost ();
16394 ;
16395 return 0;
16396}
16397_ACEOF
16398rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16399if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16400 (eval $ac_link) 2>&5
84e70f78 16401 ac_status=$?
c0d27fcc 16402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78 16403 (exit $ac_status); } &&
7c9e5167 16404 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16405 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
16406 (eval $ac_try) 2>&5
16407 ac_status=$?
c0d27fcc 16408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
16409 (exit $ac_status); }; }; then
16410 ac_cv_lib_hesiod_hes_getmailhost=yes
16411else
16412 echo "$as_me: failed program was:" >&5
19650fd6
AS
16413sed 's/^/| /' conftest.$ac_ext >&5
16414
84e70f78
KR
16415ac_cv_lib_hesiod_hes_getmailhost=no
16416fi
7c9e5167 16417rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
84e70f78
KR
16418LIBS=$ac_check_lib_save_LIBS
16419fi
c0d27fcc 16420echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
16421echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
16422if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 16423
c0d27fcc 16424cat >>confdefs.h <<\_ACEOF
84e70f78 16425#define HAVE_LIBHESIOD 1
c0d27fcc 16426_ACEOF
84e70f78
KR
16427
16428else
16429 :
16430fi
16431
16432fi
16433
16434fi
16435
a21616bd
KR
16436# These tell us which Kerberos-related libraries to use.
16437if test "${with_kerberos+set}" = set; then
503d2be0 16438
c0d27fcc 16439echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
16440echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
16441if test "${ac_cv_lib_com_err_com_err+set}" = set; then
16442 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16443else
503d2be0 16444 ac_check_lib_save_LIBS=$LIBS
a21616bd 16445LIBS="-lcom_err $LIBS"
503d2be0 16446cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16447#line $LINENO "configure"
19650fd6
AS
16448/* confdefs.h. */
16449_ACEOF
16450cat confdefs.h >>conftest.$ac_ext
16451cat >>conftest.$ac_ext <<_ACEOF
16452/* end confdefs.h. */
503d2be0 16453
a21616bd 16454/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16455#ifdef __cplusplus
16456extern "C"
16457#endif
a21616bd 16458/* We use char because int might match the return type of a gcc2
503d2be0
AS
16459 builtin and then its argument prototype would still apply. */
16460char com_err ();
16461int
16462main ()
16463{
16464com_err ();
16465 ;
16466 return 0;
16467}
16468_ACEOF
16469rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16470if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16471 (eval $ac_link) 2>&5
503d2be0 16472 ac_status=$?
c0d27fcc 16473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16474 (exit $ac_status); } &&
7c9e5167 16475 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16477 (eval $ac_try) 2>&5
16478 ac_status=$?
c0d27fcc 16479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16480 (exit $ac_status); }; }; then
16481 ac_cv_lib_com_err_com_err=yes
16482else
16483 echo "$as_me: failed program was:" >&5
19650fd6
AS
16484sed 's/^/| /' conftest.$ac_ext >&5
16485
503d2be0
AS
16486ac_cv_lib_com_err_com_err=no
16487fi
7c9e5167 16488rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16489LIBS=$ac_check_lib_save_LIBS
16490fi
c0d27fcc 16491echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
16492echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
16493if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 16494 cat >>confdefs.h <<_ACEOF
503d2be0 16495#define HAVE_LIBCOM_ERR 1
c0d27fcc 16496_ACEOF
a21616bd
KR
16497
16498 LIBS="-lcom_err $LIBS"
16499
a21616bd
KR
16500fi
16501
c0d27fcc
MR
16502
16503echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
16504echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
16505if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
16506 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16507else
503d2be0 16508 ac_check_lib_save_LIBS=$LIBS
a21616bd 16509LIBS="-lk5crypto $LIBS"
503d2be0 16510cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16511#line $LINENO "configure"
19650fd6
AS
16512/* confdefs.h. */
16513_ACEOF
16514cat confdefs.h >>conftest.$ac_ext
16515cat >>conftest.$ac_ext <<_ACEOF
16516/* end confdefs.h. */
503d2be0 16517
a21616bd 16518/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16519#ifdef __cplusplus
16520extern "C"
16521#endif
a21616bd 16522/* We use char because int might match the return type of a gcc2
503d2be0
AS
16523 builtin and then its argument prototype would still apply. */
16524char mit_des_cbc_encrypt ();
16525int
16526main ()
16527{
16528mit_des_cbc_encrypt ();
16529 ;
16530 return 0;
16531}
16532_ACEOF
16533rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16534if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16535 (eval $ac_link) 2>&5
503d2be0 16536 ac_status=$?
c0d27fcc 16537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16538 (exit $ac_status); } &&
7c9e5167 16539 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16541 (eval $ac_try) 2>&5
16542 ac_status=$?
c0d27fcc 16543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16544 (exit $ac_status); }; }; then
16545 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
16546else
16547 echo "$as_me: failed program was:" >&5
19650fd6
AS
16548sed 's/^/| /' conftest.$ac_ext >&5
16549
503d2be0
AS
16550ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
16551fi
7c9e5167 16552rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16553LIBS=$ac_check_lib_save_LIBS
16554fi
c0d27fcc 16555echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
16556echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
16557if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 16558 cat >>confdefs.h <<_ACEOF
503d2be0 16559#define HAVE_LIBK5CRYPTO 1
c0d27fcc 16560_ACEOF
a21616bd
KR
16561
16562 LIBS="-lk5crypto $LIBS"
16563
a21616bd
KR
16564fi
16565
c0d27fcc
MR
16566
16567echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
16568echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
16569if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
16570 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16571else
503d2be0 16572 ac_check_lib_save_LIBS=$LIBS
a21616bd 16573LIBS="-lcrypto $LIBS"
503d2be0 16574cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16575#line $LINENO "configure"
19650fd6
AS
16576/* confdefs.h. */
16577_ACEOF
16578cat confdefs.h >>conftest.$ac_ext
16579cat >>conftest.$ac_ext <<_ACEOF
16580/* end confdefs.h. */
503d2be0 16581
a21616bd 16582/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16583#ifdef __cplusplus
16584extern "C"
16585#endif
a21616bd 16586/* We use char because int might match the return type of a gcc2
503d2be0
AS
16587 builtin and then its argument prototype would still apply. */
16588char mit_des_cbc_encrypt ();
16589int
16590main ()
16591{
16592mit_des_cbc_encrypt ();
16593 ;
16594 return 0;
16595}
16596_ACEOF
16597rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16598if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16599 (eval $ac_link) 2>&5
503d2be0 16600 ac_status=$?
c0d27fcc 16601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16602 (exit $ac_status); } &&
7c9e5167 16603 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16605 (eval $ac_try) 2>&5
16606 ac_status=$?
c0d27fcc 16607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16608 (exit $ac_status); }; }; then
16609 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
16610else
16611 echo "$as_me: failed program was:" >&5
19650fd6
AS
16612sed 's/^/| /' conftest.$ac_ext >&5
16613
503d2be0
AS
16614ac_cv_lib_crypto_mit_des_cbc_encrypt=no
16615fi
7c9e5167 16616rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16617LIBS=$ac_check_lib_save_LIBS
16618fi
c0d27fcc 16619echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
16620echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
16621if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 16622 cat >>confdefs.h <<_ACEOF
503d2be0 16623#define HAVE_LIBCRYPTO 1
c0d27fcc 16624_ACEOF
a21616bd
KR
16625
16626 LIBS="-lcrypto $LIBS"
16627
a21616bd
KR
16628fi
16629
c0d27fcc
MR
16630
16631echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
16632echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
16633if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
16634 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16635else
503d2be0 16636 ac_check_lib_save_LIBS=$LIBS
a21616bd 16637LIBS="-lkrb5 $LIBS"
503d2be0 16638cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16639#line $LINENO "configure"
19650fd6
AS
16640/* confdefs.h. */
16641_ACEOF
16642cat confdefs.h >>conftest.$ac_ext
16643cat >>conftest.$ac_ext <<_ACEOF
16644/* end confdefs.h. */
a21616bd 16645
503d2be0
AS
16646/* Override any gcc2 internal prototype to avoid an error. */
16647#ifdef __cplusplus
16648extern "C"
16649#endif
16650/* We use char because int might match the return type of a gcc2
16651 builtin and then its argument prototype would still apply. */
16652char krb5_init_context ();
16653int
16654main ()
16655{
16656krb5_init_context ();
16657 ;
16658 return 0;
16659}
16660_ACEOF
16661rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16662if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16663 (eval $ac_link) 2>&5
503d2be0 16664 ac_status=$?
c0d27fcc 16665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16666 (exit $ac_status); } &&
7c9e5167 16667 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16668 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16669 (eval $ac_try) 2>&5
16670 ac_status=$?
c0d27fcc 16671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16672 (exit $ac_status); }; }; then
16673 ac_cv_lib_krb5_krb5_init_context=yes
16674else
16675 echo "$as_me: failed program was:" >&5
19650fd6
AS
16676sed 's/^/| /' conftest.$ac_ext >&5
16677
503d2be0
AS
16678ac_cv_lib_krb5_krb5_init_context=no
16679fi
7c9e5167 16680rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16681LIBS=$ac_check_lib_save_LIBS
16682fi
c0d27fcc 16683echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
16684echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
16685if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 16686 cat >>confdefs.h <<_ACEOF
503d2be0 16687#define HAVE_LIBKRB5 1
c0d27fcc 16688_ACEOF
a21616bd
KR
16689
16690 LIBS="-lkrb5 $LIBS"
16691
a21616bd
KR
16692fi
16693
16694 if test "${with_kerberos5+set}" != set; then
503d2be0 16695
c0d27fcc 16696echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
16697echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
16698if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
16699 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16700else
503d2be0 16701 ac_check_lib_save_LIBS=$LIBS
a21616bd 16702LIBS="-ldes425 $LIBS"
503d2be0 16703cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16704#line $LINENO "configure"
19650fd6
AS
16705/* confdefs.h. */
16706_ACEOF
16707cat confdefs.h >>conftest.$ac_ext
16708cat >>conftest.$ac_ext <<_ACEOF
16709/* end confdefs.h. */
503d2be0 16710
a21616bd 16711/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16712#ifdef __cplusplus
16713extern "C"
16714#endif
a21616bd 16715/* We use char because int might match the return type of a gcc2
503d2be0
AS
16716 builtin and then its argument prototype would still apply. */
16717char des_cbc_encrypt ();
16718int
16719main ()
16720{
16721des_cbc_encrypt ();
16722 ;
16723 return 0;
16724}
16725_ACEOF
16726rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16727if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16728 (eval $ac_link) 2>&5
503d2be0 16729 ac_status=$?
c0d27fcc 16730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16731 (exit $ac_status); } &&
7c9e5167 16732 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16733 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16734 (eval $ac_try) 2>&5
16735 ac_status=$?
c0d27fcc 16736 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16737 (exit $ac_status); }; }; then
16738 ac_cv_lib_des425_des_cbc_encrypt=yes
16739else
16740 echo "$as_me: failed program was:" >&5
19650fd6
AS
16741sed 's/^/| /' conftest.$ac_ext >&5
16742
503d2be0
AS
16743ac_cv_lib_des425_des_cbc_encrypt=no
16744fi
7c9e5167 16745rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16746LIBS=$ac_check_lib_save_LIBS
16747fi
c0d27fcc 16748echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
16749echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
16750if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 16751 cat >>confdefs.h <<_ACEOF
503d2be0 16752#define HAVE_LIBDES425 1
c0d27fcc 16753_ACEOF
a21616bd
KR
16754
16755 LIBS="-ldes425 $LIBS"
16756
16757else
503d2be0 16758
c0d27fcc 16759echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
16760echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
16761if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
16762 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16763else
503d2be0 16764 ac_check_lib_save_LIBS=$LIBS
a21616bd 16765LIBS="-ldes $LIBS"
503d2be0 16766cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16767#line $LINENO "configure"
19650fd6
AS
16768/* confdefs.h. */
16769_ACEOF
16770cat confdefs.h >>conftest.$ac_ext
16771cat >>conftest.$ac_ext <<_ACEOF
16772/* end confdefs.h. */
503d2be0 16773
a21616bd 16774/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16775#ifdef __cplusplus
16776extern "C"
16777#endif
a21616bd 16778/* We use char because int might match the return type of a gcc2
503d2be0
AS
16779 builtin and then its argument prototype would still apply. */
16780char des_cbc_encrypt ();
16781int
16782main ()
16783{
16784des_cbc_encrypt ();
16785 ;
16786 return 0;
16787}
16788_ACEOF
16789rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16790if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16791 (eval $ac_link) 2>&5
503d2be0 16792 ac_status=$?
c0d27fcc 16793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16794 (exit $ac_status); } &&
7c9e5167 16795 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16797 (eval $ac_try) 2>&5
16798 ac_status=$?
c0d27fcc 16799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16800 (exit $ac_status); }; }; then
16801 ac_cv_lib_des_des_cbc_encrypt=yes
16802else
16803 echo "$as_me: failed program was:" >&5
19650fd6
AS
16804sed 's/^/| /' conftest.$ac_ext >&5
16805
503d2be0
AS
16806ac_cv_lib_des_des_cbc_encrypt=no
16807fi
7c9e5167 16808rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16809LIBS=$ac_check_lib_save_LIBS
16810fi
c0d27fcc 16811echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
16812echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
16813if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 16814 cat >>confdefs.h <<_ACEOF
503d2be0 16815#define HAVE_LIBDES 1
c0d27fcc 16816_ACEOF
a21616bd
KR
16817
16818 LIBS="-ldes $LIBS"
16819
a21616bd
KR
16820fi
16821
16822fi
16823
c0d27fcc
MR
16824
16825echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
16826echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
16827if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
16828 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16829else
503d2be0 16830 ac_check_lib_save_LIBS=$LIBS
a21616bd 16831LIBS="-lkrb4 $LIBS"
503d2be0 16832cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16833#line $LINENO "configure"
19650fd6
AS
16834/* confdefs.h. */
16835_ACEOF
16836cat confdefs.h >>conftest.$ac_ext
16837cat >>conftest.$ac_ext <<_ACEOF
16838/* end confdefs.h. */
503d2be0 16839
a21616bd 16840/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16841#ifdef __cplusplus
16842extern "C"
16843#endif
a21616bd 16844/* We use char because int might match the return type of a gcc2
503d2be0
AS
16845 builtin and then its argument prototype would still apply. */
16846char krb_get_cred ();
16847int
16848main ()
16849{
16850krb_get_cred ();
16851 ;
16852 return 0;
16853}
16854_ACEOF
16855rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16856if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16857 (eval $ac_link) 2>&5
503d2be0 16858 ac_status=$?
c0d27fcc 16859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16860 (exit $ac_status); } &&
7c9e5167 16861 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16862 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16863 (eval $ac_try) 2>&5
16864 ac_status=$?
c0d27fcc 16865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16866 (exit $ac_status); }; }; then
16867 ac_cv_lib_krb4_krb_get_cred=yes
16868else
16869 echo "$as_me: failed program was:" >&5
19650fd6
AS
16870sed 's/^/| /' conftest.$ac_ext >&5
16871
503d2be0
AS
16872ac_cv_lib_krb4_krb_get_cred=no
16873fi
7c9e5167 16874rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16875LIBS=$ac_check_lib_save_LIBS
16876fi
c0d27fcc 16877echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
16878echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
16879if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 16880 cat >>confdefs.h <<_ACEOF
503d2be0 16881#define HAVE_LIBKRB4 1
c0d27fcc 16882_ACEOF
a21616bd
KR
16883
16884 LIBS="-lkrb4 $LIBS"
16885
16886else
503d2be0 16887
c0d27fcc 16888echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
16889echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
16890if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
16891 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 16892else
503d2be0 16893 ac_check_lib_save_LIBS=$LIBS
a21616bd 16894LIBS="-lkrb $LIBS"
503d2be0 16895cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16896#line $LINENO "configure"
19650fd6
AS
16897/* confdefs.h. */
16898_ACEOF
16899cat confdefs.h >>conftest.$ac_ext
16900cat >>conftest.$ac_ext <<_ACEOF
16901/* end confdefs.h. */
503d2be0 16902
a21616bd 16903/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16904#ifdef __cplusplus
16905extern "C"
16906#endif
a21616bd 16907/* We use char because int might match the return type of a gcc2
503d2be0
AS
16908 builtin and then its argument prototype would still apply. */
16909char krb_get_cred ();
16910int
16911main ()
16912{
16913krb_get_cred ();
16914 ;
16915 return 0;
16916}
16917_ACEOF
16918rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16919if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 16920 (eval $ac_link) 2>&5
503d2be0 16921 ac_status=$?
c0d27fcc 16922 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16923 (exit $ac_status); } &&
7c9e5167 16924 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16925 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16926 (eval $ac_try) 2>&5
16927 ac_status=$?
c0d27fcc 16928 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16929 (exit $ac_status); }; }; then
16930 ac_cv_lib_krb_krb_get_cred=yes
16931else
16932 echo "$as_me: failed program was:" >&5
19650fd6
AS
16933sed 's/^/| /' conftest.$ac_ext >&5
16934
503d2be0
AS
16935ac_cv_lib_krb_krb_get_cred=no
16936fi
7c9e5167 16937rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
16938LIBS=$ac_check_lib_save_LIBS
16939fi
c0d27fcc 16940echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
16941echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
16942if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 16943 cat >>confdefs.h <<_ACEOF
503d2be0 16944#define HAVE_LIBKRB 1
c0d27fcc 16945_ACEOF
a21616bd
KR
16946
16947 LIBS="-lkrb $LIBS"
16948
a21616bd
KR
16949fi
16950
16951fi
16952
16953 fi
16954
16955 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
16956
16957for ac_header in krb5.h
a21616bd 16958do
503d2be0 16959as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
16960if eval "test \"\${$as_ac_Header+set}\" = set"; then
16961 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
16962echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16963if eval "test \"\${$as_ac_Header+set}\" = set"; then
16964 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16965fi
16966echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16967echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 16968else
c0d27fcc
MR
16969 # Is the header compilable?
16970echo "$as_me:$LINENO: checking $ac_header usability" >&5
16971echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16972cat >conftest.$ac_ext <<_ACEOF
7c9e5167 16973#line $LINENO "configure"
19650fd6
AS
16974/* confdefs.h. */
16975_ACEOF
16976cat confdefs.h >>conftest.$ac_ext
16977cat >>conftest.$ac_ext <<_ACEOF
16978/* end confdefs.h. */
c0d27fcc
MR
16979$ac_includes_default
16980#include <$ac_header>
16981_ACEOF
16982rm -f conftest.$ac_objext
16983if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 16984 (eval $ac_compile) 2>&5
c0d27fcc
MR
16985 ac_status=$?
16986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16987 (exit $ac_status); } &&
7c9e5167 16988 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
16989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16990 (eval $ac_try) 2>&5
16991 ac_status=$?
16992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16993 (exit $ac_status); }; }; then
16994 ac_header_compiler=yes
16995else
16996 echo "$as_me: failed program was:" >&5
19650fd6
AS
16997sed 's/^/| /' conftest.$ac_ext >&5
16998
c0d27fcc
MR
16999ac_header_compiler=no
17000fi
7c9e5167 17001rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17002echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17003echo "${ECHO_T}$ac_header_compiler" >&6
17004
17005# Is the header present?
17006echo "$as_me:$LINENO: checking $ac_header presence" >&5
17007echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17008cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17009#line $LINENO "configure"
19650fd6
AS
17010/* confdefs.h. */
17011_ACEOF
17012cat confdefs.h >>conftest.$ac_ext
17013cat >>conftest.$ac_ext <<_ACEOF
17014/* end confdefs.h. */
503d2be0
AS
17015#include <$ac_header>
17016_ACEOF
c0d27fcc 17017if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17018 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17019 ac_status=$?
6bae0ccf 17020 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17021 rm -f conftest.er1
17022 cat conftest.err >&5
c0d27fcc 17023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17024 (exit $ac_status); } >/dev/null; then
17025 if test -s conftest.err; then
17026 ac_cpp_err=$ac_c_preproc_warn_flag
17027 else
17028 ac_cpp_err=
17029 fi
17030else
17031 ac_cpp_err=yes
17032fi
17033if test -z "$ac_cpp_err"; then
c0d27fcc 17034 ac_header_preproc=yes
503d2be0
AS
17035else
17036 echo "$as_me: failed program was:" >&5
19650fd6
AS
17037sed 's/^/| /' conftest.$ac_ext >&5
17038
c0d27fcc 17039 ac_header_preproc=no
a21616bd 17040fi
503d2be0 17041rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17042echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17043echo "${ECHO_T}$ac_header_preproc" >&6
17044
17045# So? What about this header?
7c9e5167
JD
17046case $ac_header_compiler:$ac_header_preproc in
17047 yes:no )
c0d27fcc
MR
17048 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17049echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17050 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17051echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17052 (
17053 cat <<\_ASBOX
17054## ------------------------------------ ##
17055## Report this to bug-autoconf@gnu.org. ##
17056## ------------------------------------ ##
17057_ASBOX
17058 ) |
17059 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17060 ;;
7c9e5167 17061 no:yes )
c0d27fcc
MR
17062 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17063echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17064 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17065echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17066 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17067echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17068 (
17069 cat <<\_ASBOX
7c9e5167
JD
17070## ------------------------------------ ##
17071## Report this to bug-autoconf@gnu.org. ##
17072## ------------------------------------ ##
19650fd6
AS
17073_ASBOX
17074 ) |
17075 sed "s/^/$as_me: WARNING: /" >&2
17076 ;;
c0d27fcc
MR
17077esac
17078echo "$as_me:$LINENO: checking for $ac_header" >&5
17079echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17080if eval "test \"\${$as_ac_Header+set}\" = set"; then
17081 echo $ECHO_N "(cached) $ECHO_C" >&6
17082else
7c9e5167 17083 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17084fi
c0d27fcc 17085echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17086echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17087
17088fi
503d2be0 17089if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17090 cat >>confdefs.h <<_ACEOF
503d2be0 17091#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17092_ACEOF
503d2be0 17093
a21616bd 17094fi
c0d27fcc 17095
a21616bd
KR
17096done
17097
17098 else
503d2be0
AS
17099
17100for ac_header in des.h
a21616bd 17101do
503d2be0 17102as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17103if eval "test \"\${$as_ac_Header+set}\" = set"; then
17104 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17105echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17106if eval "test \"\${$as_ac_Header+set}\" = set"; then
17107 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17108fi
17109echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17110echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17111else
c0d27fcc
MR
17112 # Is the header compilable?
17113echo "$as_me:$LINENO: checking $ac_header usability" >&5
17114echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17115cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17116#line $LINENO "configure"
19650fd6
AS
17117/* confdefs.h. */
17118_ACEOF
17119cat confdefs.h >>conftest.$ac_ext
17120cat >>conftest.$ac_ext <<_ACEOF
17121/* end confdefs.h. */
c0d27fcc
MR
17122$ac_includes_default
17123#include <$ac_header>
17124_ACEOF
17125rm -f conftest.$ac_objext
17126if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17127 (eval $ac_compile) 2>&5
c0d27fcc
MR
17128 ac_status=$?
17129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17130 (exit $ac_status); } &&
7c9e5167 17131 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17133 (eval $ac_try) 2>&5
17134 ac_status=$?
17135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17136 (exit $ac_status); }; }; then
17137 ac_header_compiler=yes
17138else
17139 echo "$as_me: failed program was:" >&5
19650fd6
AS
17140sed 's/^/| /' conftest.$ac_ext >&5
17141
c0d27fcc
MR
17142ac_header_compiler=no
17143fi
7c9e5167 17144rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17145echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17146echo "${ECHO_T}$ac_header_compiler" >&6
17147
17148# Is the header present?
17149echo "$as_me:$LINENO: checking $ac_header presence" >&5
17150echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17151cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17152#line $LINENO "configure"
19650fd6
AS
17153/* confdefs.h. */
17154_ACEOF
17155cat confdefs.h >>conftest.$ac_ext
17156cat >>conftest.$ac_ext <<_ACEOF
17157/* end confdefs.h. */
503d2be0
AS
17158#include <$ac_header>
17159_ACEOF
c0d27fcc 17160if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17161 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17162 ac_status=$?
6bae0ccf 17163 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17164 rm -f conftest.er1
17165 cat conftest.err >&5
c0d27fcc 17166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17167 (exit $ac_status); } >/dev/null; then
17168 if test -s conftest.err; then
17169 ac_cpp_err=$ac_c_preproc_warn_flag
17170 else
17171 ac_cpp_err=
17172 fi
17173else
17174 ac_cpp_err=yes
17175fi
17176if test -z "$ac_cpp_err"; then
c0d27fcc 17177 ac_header_preproc=yes
503d2be0
AS
17178else
17179 echo "$as_me: failed program was:" >&5
19650fd6
AS
17180sed 's/^/| /' conftest.$ac_ext >&5
17181
c0d27fcc 17182 ac_header_preproc=no
a21616bd 17183fi
503d2be0 17184rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17185echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17186echo "${ECHO_T}$ac_header_preproc" >&6
17187
17188# So? What about this header?
7c9e5167
JD
17189case $ac_header_compiler:$ac_header_preproc in
17190 yes:no )
c0d27fcc
MR
17191 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17192echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17193 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17194echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17195 (
17196 cat <<\_ASBOX
17197## ------------------------------------ ##
17198## Report this to bug-autoconf@gnu.org. ##
17199## ------------------------------------ ##
17200_ASBOX
17201 ) |
17202 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17203 ;;
7c9e5167 17204 no:yes )
c0d27fcc
MR
17205 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17206echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17207 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17208echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17209 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17210echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17211 (
17212 cat <<\_ASBOX
7c9e5167
JD
17213## ------------------------------------ ##
17214## Report this to bug-autoconf@gnu.org. ##
17215## ------------------------------------ ##
19650fd6
AS
17216_ASBOX
17217 ) |
17218 sed "s/^/$as_me: WARNING: /" >&2
17219 ;;
c0d27fcc
MR
17220esac
17221echo "$as_me:$LINENO: checking for $ac_header" >&5
17222echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17223if eval "test \"\${$as_ac_Header+set}\" = set"; then
17224 echo $ECHO_N "(cached) $ECHO_C" >&6
17225else
7c9e5167 17226 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17227fi
c0d27fcc 17228echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17229echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17230
17231fi
503d2be0 17232if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17233 cat >>confdefs.h <<_ACEOF
503d2be0 17234#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17235_ACEOF
503d2be0 17236
a21616bd 17237else
503d2be0
AS
17238
17239for ac_header in kerberosIV/des.h
a21616bd 17240do
503d2be0 17241as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17242if eval "test \"\${$as_ac_Header+set}\" = set"; then
17243 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17244echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17245if eval "test \"\${$as_ac_Header+set}\" = set"; then
17246 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17247fi
17248echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17249echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17250else
c0d27fcc
MR
17251 # Is the header compilable?
17252echo "$as_me:$LINENO: checking $ac_header usability" >&5
17253echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17254cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17255#line $LINENO "configure"
19650fd6
AS
17256/* confdefs.h. */
17257_ACEOF
17258cat confdefs.h >>conftest.$ac_ext
17259cat >>conftest.$ac_ext <<_ACEOF
17260/* end confdefs.h. */
c0d27fcc
MR
17261$ac_includes_default
17262#include <$ac_header>
17263_ACEOF
17264rm -f conftest.$ac_objext
17265if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17266 (eval $ac_compile) 2>&5
c0d27fcc
MR
17267 ac_status=$?
17268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17269 (exit $ac_status); } &&
7c9e5167 17270 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17271 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17272 (eval $ac_try) 2>&5
17273 ac_status=$?
17274 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17275 (exit $ac_status); }; }; then
17276 ac_header_compiler=yes
17277else
17278 echo "$as_me: failed program was:" >&5
19650fd6
AS
17279sed 's/^/| /' conftest.$ac_ext >&5
17280
c0d27fcc
MR
17281ac_header_compiler=no
17282fi
7c9e5167 17283rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17284echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17285echo "${ECHO_T}$ac_header_compiler" >&6
17286
17287# Is the header present?
17288echo "$as_me:$LINENO: checking $ac_header presence" >&5
17289echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17290cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17291#line $LINENO "configure"
19650fd6
AS
17292/* confdefs.h. */
17293_ACEOF
17294cat confdefs.h >>conftest.$ac_ext
17295cat >>conftest.$ac_ext <<_ACEOF
17296/* end confdefs.h. */
503d2be0
AS
17297#include <$ac_header>
17298_ACEOF
c0d27fcc 17299if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17300 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17301 ac_status=$?
6bae0ccf 17302 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17303 rm -f conftest.er1
17304 cat conftest.err >&5
c0d27fcc 17305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17306 (exit $ac_status); } >/dev/null; then
17307 if test -s conftest.err; then
17308 ac_cpp_err=$ac_c_preproc_warn_flag
17309 else
17310 ac_cpp_err=
17311 fi
17312else
17313 ac_cpp_err=yes
17314fi
17315if test -z "$ac_cpp_err"; then
c0d27fcc 17316 ac_header_preproc=yes
503d2be0
AS
17317else
17318 echo "$as_me: failed program was:" >&5
19650fd6
AS
17319sed 's/^/| /' conftest.$ac_ext >&5
17320
c0d27fcc 17321 ac_header_preproc=no
a21616bd 17322fi
503d2be0 17323rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17324echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17325echo "${ECHO_T}$ac_header_preproc" >&6
17326
17327# So? What about this header?
7c9e5167
JD
17328case $ac_header_compiler:$ac_header_preproc in
17329 yes:no )
c0d27fcc
MR
17330 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17331echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17332 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17333echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17334 (
17335 cat <<\_ASBOX
17336## ------------------------------------ ##
17337## Report this to bug-autoconf@gnu.org. ##
17338## ------------------------------------ ##
17339_ASBOX
17340 ) |
17341 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17342 ;;
7c9e5167 17343 no:yes )
c0d27fcc
MR
17344 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17345echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17346 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17347echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17348 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17349echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17350 (
17351 cat <<\_ASBOX
7c9e5167
JD
17352## ------------------------------------ ##
17353## Report this to bug-autoconf@gnu.org. ##
17354## ------------------------------------ ##
19650fd6
AS
17355_ASBOX
17356 ) |
17357 sed "s/^/$as_me: WARNING: /" >&2
17358 ;;
c0d27fcc
MR
17359esac
17360echo "$as_me:$LINENO: checking for $ac_header" >&5
17361echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17362if eval "test \"\${$as_ac_Header+set}\" = set"; then
17363 echo $ECHO_N "(cached) $ECHO_C" >&6
17364else
7c9e5167 17365 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17366fi
c0d27fcc 17367echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17368echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17369
17370fi
503d2be0 17371if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17372 cat >>confdefs.h <<_ACEOF
503d2be0 17373#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17374_ACEOF
503d2be0 17375
a21616bd 17376else
503d2be0
AS
17377
17378for ac_header in kerberos/des.h
a21616bd 17379do
503d2be0 17380as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17381if eval "test \"\${$as_ac_Header+set}\" = set"; then
17382 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17383echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17384if eval "test \"\${$as_ac_Header+set}\" = set"; then
17385 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17386fi
17387echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17388echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17389else
c0d27fcc
MR
17390 # Is the header compilable?
17391echo "$as_me:$LINENO: checking $ac_header usability" >&5
17392echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17393cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17394#line $LINENO "configure"
19650fd6
AS
17395/* confdefs.h. */
17396_ACEOF
17397cat confdefs.h >>conftest.$ac_ext
17398cat >>conftest.$ac_ext <<_ACEOF
17399/* end confdefs.h. */
c0d27fcc
MR
17400$ac_includes_default
17401#include <$ac_header>
17402_ACEOF
17403rm -f conftest.$ac_objext
17404if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17405 (eval $ac_compile) 2>&5
c0d27fcc
MR
17406 ac_status=$?
17407 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17408 (exit $ac_status); } &&
7c9e5167 17409 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17410 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17411 (eval $ac_try) 2>&5
17412 ac_status=$?
17413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17414 (exit $ac_status); }; }; then
17415 ac_header_compiler=yes
17416else
17417 echo "$as_me: failed program was:" >&5
19650fd6
AS
17418sed 's/^/| /' conftest.$ac_ext >&5
17419
c0d27fcc
MR
17420ac_header_compiler=no
17421fi
7c9e5167 17422rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17423echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17424echo "${ECHO_T}$ac_header_compiler" >&6
17425
17426# Is the header present?
17427echo "$as_me:$LINENO: checking $ac_header presence" >&5
17428echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17429cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17430#line $LINENO "configure"
19650fd6
AS
17431/* confdefs.h. */
17432_ACEOF
17433cat confdefs.h >>conftest.$ac_ext
17434cat >>conftest.$ac_ext <<_ACEOF
17435/* end confdefs.h. */
503d2be0
AS
17436#include <$ac_header>
17437_ACEOF
c0d27fcc 17438if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17439 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17440 ac_status=$?
6bae0ccf 17441 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17442 rm -f conftest.er1
17443 cat conftest.err >&5
c0d27fcc 17444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17445 (exit $ac_status); } >/dev/null; then
17446 if test -s conftest.err; then
17447 ac_cpp_err=$ac_c_preproc_warn_flag
17448 else
17449 ac_cpp_err=
17450 fi
17451else
17452 ac_cpp_err=yes
17453fi
17454if test -z "$ac_cpp_err"; then
c0d27fcc 17455 ac_header_preproc=yes
503d2be0
AS
17456else
17457 echo "$as_me: failed program was:" >&5
19650fd6
AS
17458sed 's/^/| /' conftest.$ac_ext >&5
17459
c0d27fcc 17460 ac_header_preproc=no
a21616bd 17461fi
503d2be0 17462rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17463echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17464echo "${ECHO_T}$ac_header_preproc" >&6
17465
17466# So? What about this header?
7c9e5167
JD
17467case $ac_header_compiler:$ac_header_preproc in
17468 yes:no )
c0d27fcc
MR
17469 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17470echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17471 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17472echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17473 (
17474 cat <<\_ASBOX
17475## ------------------------------------ ##
17476## Report this to bug-autoconf@gnu.org. ##
17477## ------------------------------------ ##
17478_ASBOX
17479 ) |
17480 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17481 ;;
7c9e5167 17482 no:yes )
c0d27fcc
MR
17483 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17484echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17485 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17486echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17487 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17488echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17489 (
17490 cat <<\_ASBOX
7c9e5167
JD
17491## ------------------------------------ ##
17492## Report this to bug-autoconf@gnu.org. ##
17493## ------------------------------------ ##
19650fd6
AS
17494_ASBOX
17495 ) |
17496 sed "s/^/$as_me: WARNING: /" >&2
17497 ;;
c0d27fcc
MR
17498esac
17499echo "$as_me:$LINENO: checking for $ac_header" >&5
17500echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17501if eval "test \"\${$as_ac_Header+set}\" = set"; then
17502 echo $ECHO_N "(cached) $ECHO_C" >&6
17503else
7c9e5167 17504 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17505fi
c0d27fcc 17506echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17507echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17508
17509fi
503d2be0 17510if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17511 cat >>confdefs.h <<_ACEOF
503d2be0 17512#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17513_ACEOF
a21616bd
KR
17514
17515fi
c0d27fcc 17516
a21616bd
KR
17517done
17518
98418dba 17519fi
c0d27fcc 17520
925c2f3f
EZ
17521done
17522
98418dba 17523fi
c0d27fcc 17524
925c2f3f 17525done
98418dba 17526
c0d27fcc 17527
925c2f3f
EZ
17528for ac_header in krb.h
17529do
17530as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17531if eval "test \"\${$as_ac_Header+set}\" = set"; then
17532 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
17533echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17534if eval "test \"\${$as_ac_Header+set}\" = set"; then
17535 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17536fi
17537echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17538echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
17539else
17540 # Is the header compilable?
17541echo "$as_me:$LINENO: checking $ac_header usability" >&5
17542echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17543cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17544#line $LINENO "configure"
19650fd6
AS
17545/* confdefs.h. */
17546_ACEOF
17547cat confdefs.h >>conftest.$ac_ext
17548cat >>conftest.$ac_ext <<_ACEOF
17549/* end confdefs.h. */
c0d27fcc
MR
17550$ac_includes_default
17551#include <$ac_header>
17552_ACEOF
17553rm -f conftest.$ac_objext
17554if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17555 (eval $ac_compile) 2>&5
c0d27fcc
MR
17556 ac_status=$?
17557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17558 (exit $ac_status); } &&
7c9e5167 17559 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17561 (eval $ac_try) 2>&5
17562 ac_status=$?
17563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17564 (exit $ac_status); }; }; then
17565 ac_header_compiler=yes
925c2f3f 17566else
c0d27fcc 17567 echo "$as_me: failed program was:" >&5
19650fd6
AS
17568sed 's/^/| /' conftest.$ac_ext >&5
17569
c0d27fcc
MR
17570ac_header_compiler=no
17571fi
7c9e5167 17572rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17573echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17574echo "${ECHO_T}$ac_header_compiler" >&6
17575
17576# Is the header present?
17577echo "$as_me:$LINENO: checking $ac_header presence" >&5
17578echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17579cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17580#line $LINENO "configure"
19650fd6
AS
17581/* confdefs.h. */
17582_ACEOF
17583cat confdefs.h >>conftest.$ac_ext
17584cat >>conftest.$ac_ext <<_ACEOF
17585/* end confdefs.h. */
503d2be0
AS
17586#include <$ac_header>
17587_ACEOF
c0d27fcc 17588if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17589 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17590 ac_status=$?
6bae0ccf 17591 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17592 rm -f conftest.er1
17593 cat conftest.err >&5
c0d27fcc 17594 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17595 (exit $ac_status); } >/dev/null; then
17596 if test -s conftest.err; then
17597 ac_cpp_err=$ac_c_preproc_warn_flag
17598 else
17599 ac_cpp_err=
17600 fi
17601else
17602 ac_cpp_err=yes
17603fi
17604if test -z "$ac_cpp_err"; then
c0d27fcc 17605 ac_header_preproc=yes
503d2be0
AS
17606else
17607 echo "$as_me: failed program was:" >&5
19650fd6
AS
17608sed 's/^/| /' conftest.$ac_ext >&5
17609
c0d27fcc 17610 ac_header_preproc=no
a21616bd 17611fi
503d2be0 17612rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17613echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17614echo "${ECHO_T}$ac_header_preproc" >&6
17615
17616# So? What about this header?
7c9e5167
JD
17617case $ac_header_compiler:$ac_header_preproc in
17618 yes:no )
c0d27fcc
MR
17619 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17620echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17621 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17622echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17623 (
17624 cat <<\_ASBOX
17625## ------------------------------------ ##
17626## Report this to bug-autoconf@gnu.org. ##
17627## ------------------------------------ ##
17628_ASBOX
17629 ) |
17630 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17631 ;;
7c9e5167 17632 no:yes )
c0d27fcc
MR
17633 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17634echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17635 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17636echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17637 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17638echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17639 (
17640 cat <<\_ASBOX
7c9e5167
JD
17641## ------------------------------------ ##
17642## Report this to bug-autoconf@gnu.org. ##
17643## ------------------------------------ ##
19650fd6
AS
17644_ASBOX
17645 ) |
17646 sed "s/^/$as_me: WARNING: /" >&2
17647 ;;
c0d27fcc
MR
17648esac
17649echo "$as_me:$LINENO: checking for $ac_header" >&5
17650echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17651if eval "test \"\${$as_ac_Header+set}\" = set"; then
17652 echo $ECHO_N "(cached) $ECHO_C" >&6
17653else
7c9e5167 17654 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17655fi
c0d27fcc 17656echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17657echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17658
17659fi
503d2be0 17660if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17661 cat >>confdefs.h <<_ACEOF
503d2be0 17662#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17663_ACEOF
503d2be0 17664
a21616bd 17665else
503d2be0
AS
17666
17667for ac_header in kerberosIV/krb.h
a21616bd 17668do
503d2be0 17669as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17670if eval "test \"\${$as_ac_Header+set}\" = set"; then
17671 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17672echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17673if eval "test \"\${$as_ac_Header+set}\" = set"; then
17674 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17675fi
17676echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17677echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17678else
c0d27fcc
MR
17679 # Is the header compilable?
17680echo "$as_me:$LINENO: checking $ac_header usability" >&5
17681echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17682cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17683#line $LINENO "configure"
19650fd6
AS
17684/* confdefs.h. */
17685_ACEOF
17686cat confdefs.h >>conftest.$ac_ext
17687cat >>conftest.$ac_ext <<_ACEOF
17688/* end confdefs.h. */
c0d27fcc
MR
17689$ac_includes_default
17690#include <$ac_header>
17691_ACEOF
17692rm -f conftest.$ac_objext
17693if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17694 (eval $ac_compile) 2>&5
c0d27fcc
MR
17695 ac_status=$?
17696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17697 (exit $ac_status); } &&
7c9e5167 17698 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17699 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17700 (eval $ac_try) 2>&5
17701 ac_status=$?
17702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17703 (exit $ac_status); }; }; then
17704 ac_header_compiler=yes
17705else
17706 echo "$as_me: failed program was:" >&5
19650fd6
AS
17707sed 's/^/| /' conftest.$ac_ext >&5
17708
c0d27fcc
MR
17709ac_header_compiler=no
17710fi
7c9e5167 17711rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17712echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17713echo "${ECHO_T}$ac_header_compiler" >&6
17714
17715# Is the header present?
17716echo "$as_me:$LINENO: checking $ac_header presence" >&5
17717echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17718cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17719#line $LINENO "configure"
19650fd6
AS
17720/* confdefs.h. */
17721_ACEOF
17722cat confdefs.h >>conftest.$ac_ext
17723cat >>conftest.$ac_ext <<_ACEOF
17724/* end confdefs.h. */
503d2be0
AS
17725#include <$ac_header>
17726_ACEOF
c0d27fcc 17727if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17728 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17729 ac_status=$?
6bae0ccf 17730 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17731 rm -f conftest.er1
17732 cat conftest.err >&5
c0d27fcc 17733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17734 (exit $ac_status); } >/dev/null; then
17735 if test -s conftest.err; then
17736 ac_cpp_err=$ac_c_preproc_warn_flag
17737 else
17738 ac_cpp_err=
17739 fi
17740else
17741 ac_cpp_err=yes
17742fi
17743if test -z "$ac_cpp_err"; then
c0d27fcc 17744 ac_header_preproc=yes
503d2be0
AS
17745else
17746 echo "$as_me: failed program was:" >&5
19650fd6
AS
17747sed 's/^/| /' conftest.$ac_ext >&5
17748
c0d27fcc 17749 ac_header_preproc=no
a21616bd 17750fi
503d2be0 17751rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17752echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17753echo "${ECHO_T}$ac_header_preproc" >&6
17754
17755# So? What about this header?
7c9e5167
JD
17756case $ac_header_compiler:$ac_header_preproc in
17757 yes:no )
c0d27fcc
MR
17758 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17759echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17760 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17761echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17762 (
17763 cat <<\_ASBOX
17764## ------------------------------------ ##
17765## Report this to bug-autoconf@gnu.org. ##
17766## ------------------------------------ ##
17767_ASBOX
17768 ) |
17769 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17770 ;;
7c9e5167 17771 no:yes )
c0d27fcc
MR
17772 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17773echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17774 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17775echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17776 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17777echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17778 (
17779 cat <<\_ASBOX
7c9e5167
JD
17780## ------------------------------------ ##
17781## Report this to bug-autoconf@gnu.org. ##
17782## ------------------------------------ ##
19650fd6
AS
17783_ASBOX
17784 ) |
17785 sed "s/^/$as_me: WARNING: /" >&2
17786 ;;
c0d27fcc
MR
17787esac
17788echo "$as_me:$LINENO: checking for $ac_header" >&5
17789echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17790if eval "test \"\${$as_ac_Header+set}\" = set"; then
17791 echo $ECHO_N "(cached) $ECHO_C" >&6
17792else
7c9e5167 17793 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17794fi
c0d27fcc 17795echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17796echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17797
17798fi
503d2be0 17799if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17800 cat >>confdefs.h <<_ACEOF
503d2be0 17801#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17802_ACEOF
503d2be0 17803
a21616bd 17804else
503d2be0
AS
17805
17806for ac_header in kerberos/krb.h
a21616bd 17807do
503d2be0 17808as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17809if eval "test \"\${$as_ac_Header+set}\" = set"; then
17810 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17811echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17812if eval "test \"\${$as_ac_Header+set}\" = set"; then
17813 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17814fi
17815echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17816echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17817else
c0d27fcc
MR
17818 # Is the header compilable?
17819echo "$as_me:$LINENO: checking $ac_header usability" >&5
17820echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17821cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17822#line $LINENO "configure"
19650fd6
AS
17823/* confdefs.h. */
17824_ACEOF
17825cat confdefs.h >>conftest.$ac_ext
17826cat >>conftest.$ac_ext <<_ACEOF
17827/* end confdefs.h. */
c0d27fcc
MR
17828$ac_includes_default
17829#include <$ac_header>
17830_ACEOF
17831rm -f conftest.$ac_objext
17832if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17833 (eval $ac_compile) 2>&5
c0d27fcc
MR
17834 ac_status=$?
17835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17836 (exit $ac_status); } &&
7c9e5167 17837 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17839 (eval $ac_try) 2>&5
17840 ac_status=$?
17841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17842 (exit $ac_status); }; }; then
17843 ac_header_compiler=yes
17844else
17845 echo "$as_me: failed program was:" >&5
19650fd6
AS
17846sed 's/^/| /' conftest.$ac_ext >&5
17847
c0d27fcc
MR
17848ac_header_compiler=no
17849fi
7c9e5167 17850rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
17851echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17852echo "${ECHO_T}$ac_header_compiler" >&6
17853
17854# Is the header present?
17855echo "$as_me:$LINENO: checking $ac_header presence" >&5
17856echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17857cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17858#line $LINENO "configure"
19650fd6
AS
17859/* confdefs.h. */
17860_ACEOF
17861cat confdefs.h >>conftest.$ac_ext
17862cat >>conftest.$ac_ext <<_ACEOF
17863/* end confdefs.h. */
503d2be0
AS
17864#include <$ac_header>
17865_ACEOF
c0d27fcc 17866if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17867 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17868 ac_status=$?
6bae0ccf 17869 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17870 rm -f conftest.er1
17871 cat conftest.err >&5
c0d27fcc 17872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17873 (exit $ac_status); } >/dev/null; then
17874 if test -s conftest.err; then
17875 ac_cpp_err=$ac_c_preproc_warn_flag
17876 else
17877 ac_cpp_err=
17878 fi
17879else
17880 ac_cpp_err=yes
17881fi
17882if test -z "$ac_cpp_err"; then
c0d27fcc 17883 ac_header_preproc=yes
503d2be0
AS
17884else
17885 echo "$as_me: failed program was:" >&5
19650fd6
AS
17886sed 's/^/| /' conftest.$ac_ext >&5
17887
c0d27fcc 17888 ac_header_preproc=no
a21616bd 17889fi
503d2be0 17890rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17891echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17892echo "${ECHO_T}$ac_header_preproc" >&6
35996d22
AS
17893
17894# So? What about this header?
7c9e5167
JD
17895case $ac_header_compiler:$ac_header_preproc in
17896 yes:no )
35996d22
AS
17897 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17898echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
17899 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
17900echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17901 (
17902 cat <<\_ASBOX
17903## ------------------------------------ ##
17904## Report this to bug-autoconf@gnu.org. ##
17905## ------------------------------------ ##
17906_ASBOX
17907 ) |
17908 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 17909 ;;
7c9e5167 17910 no:yes )
c0d27fcc
MR
17911 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17912echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
17913 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17914echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 17915 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 17916echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
17917 (
17918 cat <<\_ASBOX
7c9e5167
JD
17919## ------------------------------------ ##
17920## Report this to bug-autoconf@gnu.org. ##
17921## ------------------------------------ ##
19650fd6
AS
17922_ASBOX
17923 ) |
17924 sed "s/^/$as_me: WARNING: /" >&2
17925 ;;
c0d27fcc
MR
17926esac
17927echo "$as_me:$LINENO: checking for $ac_header" >&5
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
17931else
7c9e5167 17932 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 17933fi
c0d27fcc 17934echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17935echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17936
17937fi
503d2be0 17938if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17939 cat >>confdefs.h <<_ACEOF
503d2be0 17940#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17941_ACEOF
503d2be0 17942
a21616bd 17943fi
c0d27fcc 17944
a21616bd
KR
17945done
17946
17947fi
c0d27fcc 17948
a21616bd
KR
17949done
17950
17951fi
c0d27fcc 17952
a21616bd
KR
17953done
17954
17955 fi
503d2be0
AS
17956
17957for ac_header in com_err.h
a21616bd 17958do
503d2be0 17959as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17960if eval "test \"\${$as_ac_Header+set}\" = set"; then
17961 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17962echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17963if eval "test \"\${$as_ac_Header+set}\" = set"; then
17964 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17965fi
17966echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17967echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17968else
c0d27fcc
MR
17969 # Is the header compilable?
17970echo "$as_me:$LINENO: checking $ac_header usability" >&5
17971echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17972cat >conftest.$ac_ext <<_ACEOF
7c9e5167 17973#line $LINENO "configure"
19650fd6
AS
17974/* confdefs.h. */
17975_ACEOF
17976cat confdefs.h >>conftest.$ac_ext
17977cat >>conftest.$ac_ext <<_ACEOF
17978/* end confdefs.h. */
c0d27fcc
MR
17979$ac_includes_default
17980#include <$ac_header>
17981_ACEOF
17982rm -f conftest.$ac_objext
17983if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 17984 (eval $ac_compile) 2>&5
35996d22
AS
17985 ac_status=$?
17986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7c9e5167
JD
17987 (exit $ac_status); } &&
17988 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
17989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17990 (eval $ac_try) 2>&5
17991 ac_status=$?
17992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17993 (exit $ac_status); }; }; then
17994 ac_header_compiler=yes
17995else
17996 echo "$as_me: failed program was:" >&5
19650fd6
AS
17997sed 's/^/| /' conftest.$ac_ext >&5
17998
c0d27fcc
MR
17999ac_header_compiler=no
18000fi
7c9e5167 18001rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18002echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18003echo "${ECHO_T}$ac_header_compiler" >&6
18004
18005# Is the header present?
18006echo "$as_me:$LINENO: checking $ac_header presence" >&5
18007echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
18008cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18009#line $LINENO "configure"
19650fd6
AS
18010/* confdefs.h. */
18011_ACEOF
18012cat confdefs.h >>conftest.$ac_ext
18013cat >>conftest.$ac_ext <<_ACEOF
18014/* end confdefs.h. */
503d2be0
AS
18015#include <$ac_header>
18016_ACEOF
c0d27fcc 18017if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18018 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18019 ac_status=$?
6bae0ccf 18020 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18021 rm -f conftest.er1
18022 cat conftest.err >&5
c0d27fcc 18023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18024 (exit $ac_status); } >/dev/null; then
18025 if test -s conftest.err; then
18026 ac_cpp_err=$ac_c_preproc_warn_flag
18027 else
18028 ac_cpp_err=
18029 fi
18030else
18031 ac_cpp_err=yes
18032fi
18033if test -z "$ac_cpp_err"; then
c0d27fcc 18034 ac_header_preproc=yes
503d2be0
AS
18035else
18036 echo "$as_me: failed program was:" >&5
19650fd6
AS
18037sed 's/^/| /' conftest.$ac_ext >&5
18038
c0d27fcc 18039 ac_header_preproc=no
a21616bd 18040fi
503d2be0 18041rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18042echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18043echo "${ECHO_T}$ac_header_preproc" >&6
18044
18045# So? What about this header?
7c9e5167
JD
18046case $ac_header_compiler:$ac_header_preproc in
18047 yes:no )
c0d27fcc
MR
18048 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
18049echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
18050 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
18051echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
18052 (
18053 cat <<\_ASBOX
18054## ------------------------------------ ##
18055## Report this to bug-autoconf@gnu.org. ##
18056## ------------------------------------ ##
18057_ASBOX
18058 ) |
18059 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 18060 ;;
7c9e5167 18061 no:yes )
c0d27fcc
MR
18062 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
18063echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
18064 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
18065echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 18066 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 18067echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
18068 (
18069 cat <<\_ASBOX
7c9e5167
JD
18070## ------------------------------------ ##
18071## Report this to bug-autoconf@gnu.org. ##
18072## ------------------------------------ ##
19650fd6
AS
18073_ASBOX
18074 ) |
18075 sed "s/^/$as_me: WARNING: /" >&2
18076 ;;
c0d27fcc
MR
18077esac
18078echo "$as_me:$LINENO: checking for $ac_header" >&5
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
18082else
7c9e5167 18083 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 18084fi
c0d27fcc 18085echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 18086echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
18087
18088fi
503d2be0 18089if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 18090 cat >>confdefs.h <<_ACEOF
503d2be0 18091#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 18092_ACEOF
503d2be0 18093
a21616bd 18094fi
c0d27fcc 18095
a21616bd
KR
18096done
18097
18098fi
18099
ba4481b5
DL
18100# Solaris requires -lintl if you want strerror (which calls dgettext)
18101# to return localized messages.
503d2be0 18102
c0d27fcc 18103echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
18104echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
18105if test "${ac_cv_lib_intl_dgettext+set}" = set; then
18106 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 18107else
503d2be0 18108 ac_check_lib_save_LIBS=$LIBS
ba4481b5 18109LIBS="-lintl $LIBS"
503d2be0 18110cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18111#line $LINENO "configure"
19650fd6
AS
18112/* confdefs.h. */
18113_ACEOF
18114cat confdefs.h >>conftest.$ac_ext
18115cat >>conftest.$ac_ext <<_ACEOF
18116/* end confdefs.h. */
503d2be0 18117
ba4481b5 18118/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18119#ifdef __cplusplus
18120extern "C"
18121#endif
ba4481b5 18122/* We use char because int might match the return type of a gcc2
503d2be0
AS
18123 builtin and then its argument prototype would still apply. */
18124char dgettext ();
18125int
18126main ()
18127{
18128dgettext ();
18129 ;
18130 return 0;
18131}
18132_ACEOF
18133rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18134if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 18135 (eval $ac_link) 2>&5
503d2be0 18136 ac_status=$?
c0d27fcc 18137 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18138 (exit $ac_status); } &&
7c9e5167 18139 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18140 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18141 (eval $ac_try) 2>&5
18142 ac_status=$?
c0d27fcc 18143 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18144 (exit $ac_status); }; }; then
18145 ac_cv_lib_intl_dgettext=yes
18146else
18147 echo "$as_me: failed program was:" >&5
19650fd6
AS
18148sed 's/^/| /' conftest.$ac_ext >&5
18149
503d2be0
AS
18150ac_cv_lib_intl_dgettext=no
18151fi
7c9e5167 18152rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0
AS
18153LIBS=$ac_check_lib_save_LIBS
18154fi
c0d27fcc 18155echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
18156echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
18157if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 18158 cat >>confdefs.h <<_ACEOF
503d2be0 18159#define HAVE_LIBINTL 1
c0d27fcc 18160_ACEOF
ba4481b5
DL
18161
18162 LIBS="-lintl $LIBS"
18163
ba4481b5
DL
18164fi
18165
c0d27fcc
MR
18166
18167echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
18168echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
18169if test "${emacs_cv_localtime_cache+set}" = set; then
18170 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
18171else
18172 if test x$ac_cv_func_tzset = xyes; then
18173if test "$cross_compiling" = yes; then
18174 # If we have tzset, assume the worst when cross-compiling.
18175emacs_cv_localtime_cache=yes
18176else
503d2be0 18177 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18178#line $LINENO "configure"
19650fd6
AS
18179/* confdefs.h. */
18180_ACEOF
18181cat confdefs.h >>conftest.$ac_ext
18182cat >>conftest.$ac_ext <<_ACEOF
18183/* end confdefs.h. */
ba4481b5 18184#include <time.h>
ba4481b5
DL
18185extern char **environ;
18186unset_TZ ()
18187{
18188 char **from, **to;
18189 for (to = from = environ; (*to = *from); from++)
18190 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
18191 to++;
18192}
18193char TZ_GMT0[] = "TZ=GMT0";
18194char TZ_PST8[] = "TZ=PST8";
18195main()
18196{
18197 time_t now = time ((time_t *) 0);
18198 int hour_GMT0, hour_unset;
18199 if (putenv (TZ_GMT0) != 0)
18200 exit (1);
18201 hour_GMT0 = localtime (&now)->tm_hour;
18202 unset_TZ ();
18203 hour_unset = localtime (&now)->tm_hour;
18204 if (putenv (TZ_PST8) != 0)
18205 exit (1);
18206 if (localtime (&now)->tm_hour == hour_GMT0)
18207 exit (1);
18208 unset_TZ ();
18209 if (localtime (&now)->tm_hour != hour_unset)
18210 exit (1);
18211 exit (0);
18212}
503d2be0
AS
18213_ACEOF
18214rm -f conftest$ac_exeext
c0d27fcc 18215if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
18216 (eval $ac_link) 2>&5
18217 ac_status=$?
c0d27fcc 18218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18219 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 18220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18221 (eval $ac_try) 2>&5
18222 ac_status=$?
c0d27fcc 18223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18224 (exit $ac_status); }; }; then
ba4481b5
DL
18225 emacs_cv_localtime_cache=no
18226else
503d2be0
AS
18227 echo "$as_me: program exited with status $ac_status" >&5
18228echo "$as_me: failed program was:" >&5
19650fd6
AS
18229sed 's/^/| /' conftest.$ac_ext >&5
18230
c0d27fcc 18231( exit $ac_status )
503d2be0 18232emacs_cv_localtime_cache=yes
ba4481b5 18233fi
7c9e5167 18234rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 18235fi
ba4481b5
DL
18236else
18237 # If we lack tzset, report that localtime does not cache TZ,
18238 # since we can't invalidate the cache if we don't have tzset.
18239 emacs_cv_localtime_cache=no
18240fi
18241fi
c0d27fcc 18242echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 18243echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 18244if test $emacs_cv_localtime_cache = yes; then
b936fae4 18245
c0d27fcc 18246cat >>confdefs.h <<\_ACEOF
ba4481b5 18247#define LOCALTIME_CACHE 1
c0d27fcc 18248_ACEOF
ba4481b5
DL
18249
18250fi
18251
18252if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
18253
18254for ac_func in gettimeofday
48d4b120 18255do
503d2be0 18256as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 18257echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
18258echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18259if eval "test \"\${$as_ac_var+set}\" = set"; then
18260 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 18261else
503d2be0 18262 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18263#line $LINENO "configure"
19650fd6
AS
18264/* confdefs.h. */
18265_ACEOF
18266cat confdefs.h >>conftest.$ac_ext
18267cat >>conftest.$ac_ext <<_ACEOF
18268/* end confdefs.h. */
48d4b120 18269/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
18270 which can conflict with char $ac_func (); below.
18271 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18272 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
18273#ifdef __STDC__
18274# include <limits.h>
18275#else
18276# include <assert.h>
18277#endif
48d4b120 18278/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18279#ifdef __cplusplus
18280extern "C"
19650fd6 18281{
503d2be0 18282#endif
48d4b120 18283/* We use char because int might match the return type of a gcc2
503d2be0
AS
18284 builtin and then its argument prototype would still apply. */
18285char $ac_func ();
48d4b120
DL
18286/* The GNU C library defines this for functions which it implements
18287 to always fail with ENOSYS. Some functions are actually named
18288 something starting with __ and the normal name is an alias. */
18289#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18290choke me
18291#else
19650fd6
AS
18292char (*f) () = $ac_func;
18293#endif
18294#ifdef __cplusplus
18295}
cd958eb3
MB
18296#endif
18297
19650fd6
AS
18298int
18299main ()
18300{
18301return f != $ac_func;
503d2be0
AS
18302 ;
18303 return 0;
18304}
18305_ACEOF
18306rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18307if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 18308 (eval $ac_link) 2>&5
503d2be0 18309 ac_status=$?
c0d27fcc 18310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18311 (exit $ac_status); } &&
7c9e5167 18312 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18313 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18314 (eval $ac_try) 2>&5
18315 ac_status=$?
c0d27fcc 18316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18317 (exit $ac_status); }; }; then
18318 eval "$as_ac_var=yes"
18319else
18320 echo "$as_me: failed program was:" >&5
19650fd6
AS
18321sed 's/^/| /' conftest.$ac_ext >&5
18322
503d2be0
AS
18323eval "$as_ac_var=no"
18324fi
7c9e5167 18325rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 18326fi
c0d27fcc 18327echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
18328echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
18329if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 18330 cat >>confdefs.h <<_ACEOF
503d2be0 18331#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 18332_ACEOF
48d4b120 18333
48d4b120
DL
18334fi
18335done
18336
b936fae4 18337 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 18338 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
18339echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
18340if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
18341 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 18342else
503d2be0 18343 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18344#line $LINENO "configure"
19650fd6
AS
18345/* confdefs.h. */
18346_ACEOF
18347cat confdefs.h >>conftest.$ac_ext
18348cat >>conftest.$ac_ext <<_ACEOF
18349/* end confdefs.h. */
ba4481b5 18350
a3f08d9e
DL
18351#ifdef TIME_WITH_SYS_TIME
18352#include <sys/time.h>
18353#include <time.h>
18354#else
18355#ifdef HAVE_SYS_TIME_H
18356#include <sys/time.h>
18357#else
18358#include <time.h>
18359#endif
18360#endif
503d2be0
AS
18361int
18362main ()
18363{
a3f08d9e 18364struct timeval time;
b936fae4 18365 gettimeofday (&time, 0);
503d2be0
AS
18366 ;
18367 return 0;
18368}
18369_ACEOF
18370rm -f conftest.$ac_objext
c0d27fcc 18371if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18372 (eval $ac_compile) 2>&5
503d2be0 18373 ac_status=$?
c0d27fcc 18374 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18375 (exit $ac_status); } &&
7c9e5167 18376 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 18377 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18378 (eval $ac_try) 2>&5
18379 ac_status=$?
c0d27fcc 18380 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18381 (exit $ac_status); }; }; then
ba4481b5
DL
18382 emacs_cv_gettimeofday_two_arguments=yes
18383else
503d2be0 18384 echo "$as_me: failed program was:" >&5
19650fd6
AS
18385sed 's/^/| /' conftest.$ac_ext >&5
18386
503d2be0 18387emacs_cv_gettimeofday_two_arguments=no
ba4481b5 18388fi
7c9e5167 18389rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 18390fi
c0d27fcc 18391echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 18392echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
18393 if test $emacs_cv_gettimeofday_two_arguments = no; then
18394
c0d27fcc 18395cat >>confdefs.h <<\_ACEOF
ba4481b5 18396#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 18397_ACEOF
ba4481b5 18398
b936fae4 18399 fi
ba4481b5
DL
18400 fi
18401fi
18402
973a76b1
DL
18403# This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
18404echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
18405echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
18406if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
18407 echo $ECHO_N "(cached) $ECHO_C" >&6
18408else
18409 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18410#line $LINENO "configure"
19650fd6
AS
18411/* confdefs.h. */
18412_ACEOF
18413cat confdefs.h >>conftest.$ac_ext
18414cat >>conftest.$ac_ext <<_ACEOF
18415/* end confdefs.h. */
973a76b1
DL
18416#include <sys/types.h>
18417#include <$ac_cv_struct_tm>
18418
18419
18420int
18421main ()
18422{
18423static struct tm ac_aggr;
18424if (ac_aggr.tm_zone)
18425return 0;
18426 ;
18427 return 0;
18428}
18429_ACEOF
18430rm -f conftest.$ac_objext
18431if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18432 (eval $ac_compile) 2>&5
973a76b1
DL
18433 ac_status=$?
18434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18435 (exit $ac_status); } &&
7c9e5167 18436 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
18437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18438 (eval $ac_try) 2>&5
18439 ac_status=$?
18440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18441 (exit $ac_status); }; }; then
18442 ac_cv_member_struct_tm_tm_zone=yes
18443else
18444 echo "$as_me: failed program was:" >&5
19650fd6
AS
18445sed 's/^/| /' conftest.$ac_ext >&5
18446
973a76b1 18447cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18448#line $LINENO "configure"
19650fd6
AS
18449/* confdefs.h. */
18450_ACEOF
18451cat confdefs.h >>conftest.$ac_ext
18452cat >>conftest.$ac_ext <<_ACEOF
18453/* end confdefs.h. */
973a76b1
DL
18454#include <sys/types.h>
18455#include <$ac_cv_struct_tm>
18456
18457
18458int
18459main ()
18460{
18461static struct tm ac_aggr;
18462if (sizeof ac_aggr.tm_zone)
18463return 0;
18464 ;
18465 return 0;
18466}
18467_ACEOF
18468rm -f conftest.$ac_objext
18469if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18470 (eval $ac_compile) 2>&5
973a76b1
DL
18471 ac_status=$?
18472 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18473 (exit $ac_status); } &&
7c9e5167 18474 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
18475 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18476 (eval $ac_try) 2>&5
18477 ac_status=$?
18478 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18479 (exit $ac_status); }; }; then
18480 ac_cv_member_struct_tm_tm_zone=yes
18481else
18482 echo "$as_me: failed program was:" >&5
19650fd6
AS
18483sed 's/^/| /' conftest.$ac_ext >&5
18484
973a76b1
DL
18485ac_cv_member_struct_tm_tm_zone=no
18486fi
7c9e5167 18487rm -f conftest.$ac_objext conftest.$ac_ext
973a76b1 18488fi
7c9e5167 18489rm -f conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
18490fi
18491echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
18492echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
18493if test $ac_cv_member_struct_tm_tm_zone = yes; then
18494
18495cat >>confdefs.h <<_ACEOF
18496#define HAVE_STRUCT_TM_TM_ZONE 1
18497_ACEOF
18498
18499
18500fi
18501
18502if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
18503
18504cat >>confdefs.h <<\_ACEOF
18505#define HAVE_TM_ZONE 1
18506_ACEOF
18507
18508else
18509 echo "$as_me:$LINENO: checking for tzname" >&5
18510echo $ECHO_N "checking for tzname... $ECHO_C" >&6
18511if test "${ac_cv_var_tzname+set}" = set; then
18512 echo $ECHO_N "(cached) $ECHO_C" >&6
18513else
18514 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18515#line $LINENO "configure"
19650fd6
AS
18516/* confdefs.h. */
18517_ACEOF
18518cat confdefs.h >>conftest.$ac_ext
18519cat >>conftest.$ac_ext <<_ACEOF
18520/* end confdefs.h. */
973a76b1
DL
18521#include <time.h>
18522#ifndef tzname /* For SGI. */
18523extern char *tzname[]; /* RS6000 and others reject char **tzname. */
18524#endif
18525
18526int
18527main ()
18528{
18529atoi(*tzname);
18530 ;
18531 return 0;
18532}
18533_ACEOF
18534rm -f conftest.$ac_objext conftest$ac_exeext
18535if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 18536 (eval $ac_link) 2>&5
973a76b1
DL
18537 ac_status=$?
18538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18539 (exit $ac_status); } &&
7c9e5167 18540 { ac_try='test -s conftest$ac_exeext'
973a76b1
DL
18541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18542 (eval $ac_try) 2>&5
18543 ac_status=$?
18544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18545 (exit $ac_status); }; }; then
18546 ac_cv_var_tzname=yes
18547else
18548 echo "$as_me: failed program was:" >&5
19650fd6
AS
18549sed 's/^/| /' conftest.$ac_ext >&5
18550
973a76b1
DL
18551ac_cv_var_tzname=no
18552fi
7c9e5167 18553rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
973a76b1
DL
18554fi
18555echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
18556echo "${ECHO_T}$ac_cv_var_tzname" >&6
18557 if test $ac_cv_var_tzname = yes; then
18558
18559cat >>confdefs.h <<\_ACEOF
18560#define HAVE_TZNAME 1
18561_ACEOF
18562
18563 fi
18564fi
18565
18566
48d4b120 18567if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 18568 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
18569echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
18570if test "${emacs_cv_struct_timezone+set}" = set; then
18571 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 18572else
503d2be0 18573 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18574#line $LINENO "configure"
19650fd6
AS
18575/* confdefs.h. */
18576_ACEOF
18577cat confdefs.h >>conftest.$ac_ext
18578cat >>conftest.$ac_ext <<_ACEOF
18579/* end confdefs.h. */
48d4b120 18580#include <sys/time.h>
503d2be0
AS
18581int
18582main ()
18583{
48d4b120 18584struct timezone tz;
503d2be0
AS
18585 ;
18586 return 0;
18587}
18588_ACEOF
18589rm -f conftest.$ac_objext
c0d27fcc 18590if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18591 (eval $ac_compile) 2>&5
503d2be0 18592 ac_status=$?
c0d27fcc 18593 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18594 (exit $ac_status); } &&
7c9e5167 18595 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 18596 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18597 (eval $ac_try) 2>&5
18598 ac_status=$?
c0d27fcc 18599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18600 (exit $ac_status); }; }; then
48d4b120
DL
18601 if test "$cross_compiling" = yes; then
18602 emacs_cv_struct_timezone=yes
18603else
503d2be0 18604 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18605#line $LINENO "configure"
19650fd6
AS
18606/* confdefs.h. */
18607_ACEOF
18608cat confdefs.h >>conftest.$ac_ext
18609cat >>conftest.$ac_ext <<_ACEOF
18610/* end confdefs.h. */
48d4b120
DL
18611
18612#ifdef TIME_WITH_SYS_TIME
18613#include <sys/time.h>
18614#include <time.h>
18615#else
18616#ifdef HAVE_SYS_TIME_H
18617#include <sys/time.h>
18618#else
18619#include <time.h>
18620#endif
18621#endif
18622main () {
18623 struct timeval time;
18624 struct timezone dummy;
18625 exit (gettimeofday (&time, &dummy));
18626}
503d2be0
AS
18627_ACEOF
18628rm -f conftest$ac_exeext
c0d27fcc 18629if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
18630 (eval $ac_link) 2>&5
18631 ac_status=$?
c0d27fcc 18632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18633 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 18634 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18635 (eval $ac_try) 2>&5
18636 ac_status=$?
c0d27fcc 18637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18638 (exit $ac_status); }; }; then
48d4b120
DL
18639 emacs_cv_struct_timezone=yes
18640else
503d2be0
AS
18641 echo "$as_me: program exited with status $ac_status" >&5
18642echo "$as_me: failed program was:" >&5
19650fd6
AS
18643sed 's/^/| /' conftest.$ac_ext >&5
18644
c0d27fcc 18645( exit $ac_status )
503d2be0 18646emacs_cv_struct_timezone=no
48d4b120 18647fi
7c9e5167 18648rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 18649fi
48d4b120 18650else
503d2be0 18651 echo "$as_me: failed program was:" >&5
19650fd6
AS
18652sed 's/^/| /' conftest.$ac_ext >&5
18653
503d2be0 18654emacs_cv_struct_timezone=no
48d4b120 18655fi
7c9e5167 18656rm -f conftest.$ac_objext conftest.$ac_ext
48d4b120 18657fi
c0d27fcc 18658echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 18659echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
18660fi
18661
ba4481b5 18662ok_so_far=yes
c0d27fcc 18663echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
18664echo $ECHO_N "checking for socket... $ECHO_C" >&6
18665if test "${ac_cv_func_socket+set}" = set; then
18666 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 18667else
503d2be0 18668 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18669#line $LINENO "configure"
19650fd6
AS
18670/* confdefs.h. */
18671_ACEOF
18672cat confdefs.h >>conftest.$ac_ext
18673cat >>conftest.$ac_ext <<_ACEOF
18674/* end confdefs.h. */
ba4481b5 18675/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
18676 which can conflict with char socket (); below.
18677 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18678 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
18679#ifdef __STDC__
18680# include <limits.h>
18681#else
18682# include <assert.h>
18683#endif
ba4481b5 18684/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
18685#ifdef __cplusplus
18686extern "C"
19650fd6 18687{
503d2be0 18688#endif
ba4481b5 18689/* We use char because int might match the return type of a gcc2
503d2be0
AS
18690 builtin and then its argument prototype would still apply. */
18691char socket ();
ba4481b5
DL
18692/* The GNU C library defines this for functions which it implements
18693 to always fail with ENOSYS. Some functions are actually named
18694 something starting with __ and the normal name is an alias. */
18695#if defined (__stub_socket) || defined (__stub___socket)
18696choke me
18697#else
19650fd6
AS
18698char (*f) () = socket;
18699#endif
18700#ifdef __cplusplus
18701}
cd958eb3
MB
18702#endif
18703
19650fd6
AS
18704int
18705main ()
18706{
18707return f != socket;
503d2be0
AS
18708 ;
18709 return 0;
18710}
18711_ACEOF
18712rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 18713if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 18714 (eval $ac_link) 2>&5
503d2be0 18715 ac_status=$?
c0d27fcc 18716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 18717 (exit $ac_status); } &&
7c9e5167 18718 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 18719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
18720 (eval $ac_try) 2>&5
18721 ac_status=$?
c0d27fcc 18722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18723 (exit $ac_status); }; }; then
18724 ac_cv_func_socket=yes
18725else
18726 echo "$as_me: failed program was:" >&5
19650fd6
AS
18727sed 's/^/| /' conftest.$ac_ext >&5
18728
503d2be0
AS
18729ac_cv_func_socket=no
18730fi
7c9e5167 18731rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 18732fi
c0d27fcc 18733echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
18734echo "${ECHO_T}$ac_cv_func_socket" >&6
18735if test $ac_cv_func_socket = yes; then
ba4481b5
DL
18736 :
18737else
503d2be0 18738 ok_so_far=no
ba4481b5
DL
18739fi
18740
18741if test $ok_so_far = yes; then
c0d27fcc
MR
18742 if test "${ac_cv_header_netinet_in_h+set}" = set; then
18743 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
18744echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
18745if test "${ac_cv_header_netinet_in_h+set}" = set; then
18746 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18747fi
18748echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
18749echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 18750else
c0d27fcc
MR
18751 # Is the header compilable?
18752echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
18753echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
18754cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18755#line $LINENO "configure"
19650fd6
AS
18756/* confdefs.h. */
18757_ACEOF
18758cat confdefs.h >>conftest.$ac_ext
18759cat >>conftest.$ac_ext <<_ACEOF
18760/* end confdefs.h. */
c0d27fcc
MR
18761$ac_includes_default
18762#include <netinet/in.h>
18763_ACEOF
18764rm -f conftest.$ac_objext
18765if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18766 (eval $ac_compile) 2>&5
c0d27fcc
MR
18767 ac_status=$?
18768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18769 (exit $ac_status); } &&
7c9e5167 18770 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18771 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18772 (eval $ac_try) 2>&5
18773 ac_status=$?
18774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18775 (exit $ac_status); }; }; then
18776 ac_header_compiler=yes
18777else
18778 echo "$as_me: failed program was:" >&5
19650fd6
AS
18779sed 's/^/| /' conftest.$ac_ext >&5
18780
c0d27fcc
MR
18781ac_header_compiler=no
18782fi
7c9e5167 18783rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18784echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18785echo "${ECHO_T}$ac_header_compiler" >&6
18786
18787# Is the header present?
18788echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
18789echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
18790cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18791#line $LINENO "configure"
19650fd6
AS
18792/* confdefs.h. */
18793_ACEOF
18794cat confdefs.h >>conftest.$ac_ext
18795cat >>conftest.$ac_ext <<_ACEOF
18796/* end confdefs.h. */
ba4481b5 18797#include <netinet/in.h>
503d2be0 18798_ACEOF
c0d27fcc 18799if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18800 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18801 ac_status=$?
6bae0ccf 18802 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18803 rm -f conftest.er1
18804 cat conftest.err >&5
c0d27fcc 18805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18806 (exit $ac_status); } >/dev/null; then
18807 if test -s conftest.err; then
18808 ac_cpp_err=$ac_c_preproc_warn_flag
18809 else
18810 ac_cpp_err=
18811 fi
18812else
18813 ac_cpp_err=yes
18814fi
18815if test -z "$ac_cpp_err"; then
c0d27fcc 18816 ac_header_preproc=yes
ba4481b5 18817else
503d2be0 18818 echo "$as_me: failed program was:" >&5
19650fd6
AS
18819sed 's/^/| /' conftest.$ac_ext >&5
18820
c0d27fcc 18821 ac_header_preproc=no
ba4481b5 18822fi
503d2be0 18823rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18824echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18825echo "${ECHO_T}$ac_header_preproc" >&6
18826
18827# So? What about this header?
7c9e5167
JD
18828case $ac_header_compiler:$ac_header_preproc in
18829 yes:no )
c0d27fcc
MR
18830 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
18831echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
18832 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
18833echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
18834 (
18835 cat <<\_ASBOX
18836## ------------------------------------ ##
18837## Report this to bug-autoconf@gnu.org. ##
18838## ------------------------------------ ##
18839_ASBOX
18840 ) |
18841 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 18842 ;;
7c9e5167 18843 no:yes )
c0d27fcc
MR
18844 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
18845echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
7c9e5167
JD
18846 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
18847echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 18848 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
19650fd6 18849echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
18850 (
18851 cat <<\_ASBOX
7c9e5167
JD
18852## ------------------------------------ ##
18853## Report this to bug-autoconf@gnu.org. ##
18854## ------------------------------------ ##
19650fd6
AS
18855_ASBOX
18856 ) |
18857 sed "s/^/$as_me: WARNING: /" >&2
18858 ;;
c0d27fcc
MR
18859esac
18860echo "$as_me:$LINENO: checking for netinet/in.h" >&5
18861echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
18862if test "${ac_cv_header_netinet_in_h+set}" = set; then
18863 echo $ECHO_N "(cached) $ECHO_C" >&6
18864else
18865 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 18866fi
c0d27fcc 18867echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 18868echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
18869
18870fi
503d2be0 18871if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
18872 :
18873else
503d2be0 18874 ok_so_far=no
ba4481b5
DL
18875fi
18876
c0d27fcc 18877
ba4481b5
DL
18878fi
18879if test $ok_so_far = yes; then
c0d27fcc
MR
18880 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
18881 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
18882echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
18883if test "${ac_cv_header_arpa_inet_h+set}" = set; then
18884 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
18885fi
18886echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
18887echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 18888else
c0d27fcc
MR
18889 # Is the header compilable?
18890echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
18891echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
18892cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18893#line $LINENO "configure"
19650fd6
AS
18894/* confdefs.h. */
18895_ACEOF
18896cat confdefs.h >>conftest.$ac_ext
18897cat >>conftest.$ac_ext <<_ACEOF
18898/* end confdefs.h. */
c0d27fcc
MR
18899$ac_includes_default
18900#include <arpa/inet.h>
18901_ACEOF
18902rm -f conftest.$ac_objext
18903if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 18904 (eval $ac_compile) 2>&5
c0d27fcc
MR
18905 ac_status=$?
18906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18907 (exit $ac_status); } &&
7c9e5167 18908 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
18909 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18910 (eval $ac_try) 2>&5
18911 ac_status=$?
18912 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18913 (exit $ac_status); }; }; then
18914 ac_header_compiler=yes
18915else
18916 echo "$as_me: failed program was:" >&5
19650fd6
AS
18917sed 's/^/| /' conftest.$ac_ext >&5
18918
c0d27fcc
MR
18919ac_header_compiler=no
18920fi
7c9e5167 18921rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
18922echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18923echo "${ECHO_T}$ac_header_compiler" >&6
18924
18925# Is the header present?
18926echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
18927echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
18928cat >conftest.$ac_ext <<_ACEOF
7c9e5167 18929#line $LINENO "configure"
19650fd6
AS
18930/* confdefs.h. */
18931_ACEOF
18932cat confdefs.h >>conftest.$ac_ext
18933cat >>conftest.$ac_ext <<_ACEOF
18934/* end confdefs.h. */
ba4481b5 18935#include <arpa/inet.h>
503d2be0 18936_ACEOF
c0d27fcc 18937if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
18938 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18939 ac_status=$?
6bae0ccf 18940 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
18941 rm -f conftest.er1
18942 cat conftest.err >&5
c0d27fcc 18943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
18944 (exit $ac_status); } >/dev/null; then
18945 if test -s conftest.err; then
18946 ac_cpp_err=$ac_c_preproc_warn_flag
18947 else
18948 ac_cpp_err=
18949 fi
18950else
18951 ac_cpp_err=yes
18952fi
18953if test -z "$ac_cpp_err"; then
c0d27fcc 18954 ac_header_preproc=yes
ba4481b5 18955else
503d2be0 18956 echo "$as_me: failed program was:" >&5
19650fd6
AS
18957sed 's/^/| /' conftest.$ac_ext >&5
18958
c0d27fcc 18959 ac_header_preproc=no
ba4481b5 18960fi
503d2be0 18961rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
18962echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18963echo "${ECHO_T}$ac_header_preproc" >&6
18964
18965# So? What about this header?
7c9e5167
JD
18966case $ac_header_compiler:$ac_header_preproc in
18967 yes:no )
c0d27fcc
MR
18968 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
18969echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
18970 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
18971echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
18972 (
18973 cat <<\_ASBOX
18974## ------------------------------------ ##
18975## Report this to bug-autoconf@gnu.org. ##
18976## ------------------------------------ ##
18977_ASBOX
18978 ) |
18979 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 18980 ;;
7c9e5167 18981 no:yes )
c0d27fcc
MR
18982 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
18983echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
7c9e5167
JD
18984 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
18985echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
c0d27fcc 18986 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
19650fd6 18987echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
18988 (
18989 cat <<\_ASBOX
7c9e5167
JD
18990## ------------------------------------ ##
18991## Report this to bug-autoconf@gnu.org. ##
18992## ------------------------------------ ##
19650fd6
AS
18993_ASBOX
18994 ) |
18995 sed "s/^/$as_me: WARNING: /" >&2
18996 ;;
c0d27fcc
MR
18997esac
18998echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
18999echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
19000if test "${ac_cv_header_arpa_inet_h+set}" = set; then
19001 echo $ECHO_N "(cached) $ECHO_C" >&6
19002else
19003 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 19004fi
c0d27fcc 19005echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 19006echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
19007
19008fi
503d2be0 19009if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
19010 :
19011else
503d2be0 19012 ok_so_far=no
ba4481b5
DL
19013fi
19014
c0d27fcc 19015
ba4481b5
DL
19016fi
19017if test $ok_so_far = yes; then
b936fae4 19018
c0d27fcc 19019cat >>confdefs.h <<\_ACEOF
ba4481b5 19020#define HAVE_INET_SOCKETS 1
c0d27fcc 19021_ACEOF
ba4481b5
DL
19022
19023fi
19024
2d2b6695 19025
7862d3a8 19026for ac_header in sys/ioctl.h
2d2b6695
KS
19027do
19028as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
19029if eval "test \"\${$as_ac_Header+set}\" = set"; then
19030 echo "$as_me:$LINENO: checking for $ac_header" >&5
19031echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19032if eval "test \"\${$as_ac_Header+set}\" = set"; then
19033 echo $ECHO_N "(cached) $ECHO_C" >&6
19034fi
19035echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19036echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19037else
19038 # Is the header compilable?
19039echo "$as_me:$LINENO: checking $ac_header usability" >&5
19040echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19041cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19042#line $LINENO "configure"
2d2b6695
KS
19043/* confdefs.h. */
19044_ACEOF
19045cat confdefs.h >>conftest.$ac_ext
19046cat >>conftest.$ac_ext <<_ACEOF
19047/* end confdefs.h. */
19048$ac_includes_default
19049#include <$ac_header>
19050_ACEOF
19051rm -f conftest.$ac_objext
19052if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19053 (eval $ac_compile) 2>&5
2d2b6695
KS
19054 ac_status=$?
19055 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19056 (exit $ac_status); } &&
7c9e5167 19057 { ac_try='test -s conftest.$ac_objext'
2d2b6695
KS
19058 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19059 (eval $ac_try) 2>&5
19060 ac_status=$?
19061 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19062 (exit $ac_status); }; }; then
19063 ac_header_compiler=yes
19064else
19065 echo "$as_me: failed program was:" >&5
19066sed 's/^/| /' conftest.$ac_ext >&5
19067
19068ac_header_compiler=no
19069fi
7c9e5167 19070rm -f conftest.$ac_objext conftest.$ac_ext
2d2b6695
KS
19071echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19072echo "${ECHO_T}$ac_header_compiler" >&6
19073
19074# Is the header present?
19075echo "$as_me:$LINENO: checking $ac_header presence" >&5
19076echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19077cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19078#line $LINENO "configure"
2d2b6695
KS
19079/* confdefs.h. */
19080_ACEOF
19081cat confdefs.h >>conftest.$ac_ext
19082cat >>conftest.$ac_ext <<_ACEOF
19083/* end confdefs.h. */
19084#include <$ac_header>
19085_ACEOF
19086if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
19087 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19088 ac_status=$?
19089 grep -v '^ *+' conftest.er1 >conftest.err
19090 rm -f conftest.er1
19091 cat conftest.err >&5
19092 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19093 (exit $ac_status); } >/dev/null; then
19094 if test -s conftest.err; then
19095 ac_cpp_err=$ac_c_preproc_warn_flag
19096 else
19097 ac_cpp_err=
19098 fi
19099else
19100 ac_cpp_err=yes
19101fi
19102if test -z "$ac_cpp_err"; then
19103 ac_header_preproc=yes
19104else
19105 echo "$as_me: failed program was:" >&5
19106sed 's/^/| /' conftest.$ac_ext >&5
19107
19108 ac_header_preproc=no
19109fi
19110rm -f conftest.err conftest.$ac_ext
19111echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19112echo "${ECHO_T}$ac_header_preproc" >&6
19113
19114# So? What about this header?
7c9e5167
JD
19115case $ac_header_compiler:$ac_header_preproc in
19116 yes:no )
2d2b6695
KS
19117 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19118echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
19119 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19120echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19121 (
19122 cat <<\_ASBOX
19123## ------------------------------------ ##
19124## Report this to bug-autoconf@gnu.org. ##
19125## ------------------------------------ ##
19126_ASBOX
19127 ) |
19128 sed "s/^/$as_me: WARNING: /" >&2
2d2b6695 19129 ;;
7c9e5167 19130 no:yes )
2d2b6695
KS
19131 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19132echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
19133 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19134echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
2d2b6695
KS
19135 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19136echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19137 (
19138 cat <<\_ASBOX
7c9e5167
JD
19139## ------------------------------------ ##
19140## Report this to bug-autoconf@gnu.org. ##
19141## ------------------------------------ ##
2d2b6695
KS
19142_ASBOX
19143 ) |
19144 sed "s/^/$as_me: WARNING: /" >&2
19145 ;;
19146esac
19147echo "$as_me:$LINENO: checking for $ac_header" >&5
19148echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19149if eval "test \"\${$as_ac_Header+set}\" = set"; then
19150 echo $ECHO_N "(cached) $ECHO_C" >&6
19151else
7c9e5167 19152 eval "$as_ac_Header=$ac_header_preproc"
2d2b6695
KS
19153fi
19154echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19155echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
19156
19157fi
19158if test `eval echo '${'$as_ac_Header'}'` = yes; then
19159 cat >>confdefs.h <<_ACEOF
19160#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
19161_ACEOF
19162
19163fi
19164
19165done
19166
19167
ba4481b5 19168if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 19169
c0d27fcc 19170cat >>confdefs.h <<\_ACEOF
ba4481b5 19171#define HAVE_AIX_SMT_EXP 1
c0d27fcc 19172_ACEOF
ba4481b5
DL
19173
19174fi
19175
c0d27fcc 19176echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 19177echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 19178if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 19179 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 19180echo "${ECHO_T}yes" >&6
b936fae4 19181
c0d27fcc 19182cat >>confdefs.h <<\_ACEOF
3d9fec71 19183#define HAVE_DEV_PTMX 1
c0d27fcc 19184_ACEOF
3d9fec71
DL
19185
19186else
c0d27fcc 19187 echo "$as_me:$LINENO: result: no" >&5
503d2be0 19188echo "${ECHO_T}no" >&6
3d9fec71
DL
19189fi
19190
c0d27fcc 19191echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
19192echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
19193if test "${ac_cv_type_pid_t+set}" = set; then
19194 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 19195else
503d2be0 19196 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19197#line $LINENO "configure"
19650fd6
AS
19198/* confdefs.h. */
19199_ACEOF
19200cat confdefs.h >>conftest.$ac_ext
19201cat >>conftest.$ac_ext <<_ACEOF
19202/* end confdefs.h. */
503d2be0
AS
19203$ac_includes_default
19204int
19205main ()
19206{
19207if ((pid_t *) 0)
19208 return 0;
19209if (sizeof (pid_t))
19210 return 0;
19211 ;
19212 return 0;
19213}
19214_ACEOF
19215rm -f conftest.$ac_objext
c0d27fcc 19216if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19217 (eval $ac_compile) 2>&5
503d2be0 19218 ac_status=$?
c0d27fcc 19219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19220 (exit $ac_status); } &&
7c9e5167 19221 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19222 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19223 (eval $ac_try) 2>&5
19224 ac_status=$?
c0d27fcc 19225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19226 (exit $ac_status); }; }; then
647847ea
DL
19227 ac_cv_type_pid_t=yes
19228else
503d2be0 19229 echo "$as_me: failed program was:" >&5
19650fd6
AS
19230sed 's/^/| /' conftest.$ac_ext >&5
19231
503d2be0 19232ac_cv_type_pid_t=no
647847ea 19233fi
7c9e5167 19234rm -f conftest.$ac_objext conftest.$ac_ext
647847ea 19235fi
c0d27fcc 19236echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
19237echo "${ECHO_T}$ac_cv_type_pid_t" >&6
19238if test $ac_cv_type_pid_t = yes; then
19239 :
19240else
19241
c0d27fcc 19242cat >>confdefs.h <<_ACEOF
647847ea 19243#define pid_t int
c0d27fcc 19244_ACEOF
647847ea
DL
19245
19246fi
19247
c0d27fcc
MR
19248
19249
503d2be0
AS
19250for ac_header in unistd.h vfork.h
19251do
19252as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
19253if eval "test \"\${$as_ac_Header+set}\" = set"; then
19254 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
19255echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19256if eval "test \"\${$as_ac_Header+set}\" = set"; then
19257 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
19258fi
19259echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
19260echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 19261else
c0d27fcc
MR
19262 # Is the header compilable?
19263echo "$as_me:$LINENO: checking $ac_header usability" >&5
19264echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
19265cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19266#line $LINENO "configure"
19650fd6
AS
19267/* confdefs.h. */
19268_ACEOF
19269cat confdefs.h >>conftest.$ac_ext
19270cat >>conftest.$ac_ext <<_ACEOF
19271/* end confdefs.h. */
c0d27fcc
MR
19272$ac_includes_default
19273#include <$ac_header>
19274_ACEOF
19275rm -f conftest.$ac_objext
19276if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19277 (eval $ac_compile) 2>&5
c0d27fcc
MR
19278 ac_status=$?
19279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19280 (exit $ac_status); } &&
7c9e5167 19281 { ac_try='test -s conftest.$ac_objext'
c0d27fcc
MR
19282 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19283 (eval $ac_try) 2>&5
19284 ac_status=$?
19285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19286 (exit $ac_status); }; }; then
19287 ac_header_compiler=yes
19288else
19289 echo "$as_me: failed program was:" >&5
19650fd6
AS
19290sed 's/^/| /' conftest.$ac_ext >&5
19291
c0d27fcc
MR
19292ac_header_compiler=no
19293fi
7c9e5167 19294rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
19295echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19296echo "${ECHO_T}$ac_header_compiler" >&6
19297
19298# Is the header present?
19299echo "$as_me:$LINENO: checking $ac_header presence" >&5
19300echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
19301cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19302#line $LINENO "configure"
19650fd6
AS
19303/* confdefs.h. */
19304_ACEOF
19305cat confdefs.h >>conftest.$ac_ext
19306cat >>conftest.$ac_ext <<_ACEOF
19307/* end confdefs.h. */
503d2be0
AS
19308#include <$ac_header>
19309_ACEOF
c0d27fcc 19310if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
19311 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
19312 ac_status=$?
6bae0ccf 19313 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
19314 rm -f conftest.er1
19315 cat conftest.err >&5
c0d27fcc 19316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19317 (exit $ac_status); } >/dev/null; then
19318 if test -s conftest.err; then
19319 ac_cpp_err=$ac_c_preproc_warn_flag
19320 else
19321 ac_cpp_err=
19322 fi
647847ea 19323else
503d2be0
AS
19324 ac_cpp_err=yes
19325fi
19326if test -z "$ac_cpp_err"; then
c0d27fcc 19327 ac_header_preproc=yes
647847ea 19328else
503d2be0 19329 echo "$as_me: failed program was:" >&5
19650fd6
AS
19330sed 's/^/| /' conftest.$ac_ext >&5
19331
c0d27fcc 19332 ac_header_preproc=no
647847ea 19333fi
503d2be0 19334rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
19335echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19336echo "${ECHO_T}$ac_header_preproc" >&6
19337
19338# So? What about this header?
7c9e5167
JD
19339case $ac_header_compiler:$ac_header_preproc in
19340 yes:no )
c0d27fcc
MR
19341 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
19342echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7c9e5167
JD
19343 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19344echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19345 (
19346 cat <<\_ASBOX
19347## ------------------------------------ ##
19348## Report this to bug-autoconf@gnu.org. ##
19349## ------------------------------------ ##
19350_ASBOX
19351 ) |
19352 sed "s/^/$as_me: WARNING: /" >&2
19650fd6 19353 ;;
7c9e5167 19354 no:yes )
c0d27fcc
MR
19355 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
19356echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7c9e5167
JD
19357 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
19358echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
c0d27fcc 19359 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
19650fd6 19360echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
19650fd6
AS
19361 (
19362 cat <<\_ASBOX
7c9e5167
JD
19363## ------------------------------------ ##
19364## Report this to bug-autoconf@gnu.org. ##
19365## ------------------------------------ ##
19650fd6
AS
19366_ASBOX
19367 ) |
19368 sed "s/^/$as_me: WARNING: /" >&2
19369 ;;
c0d27fcc
MR
19370esac
19371echo "$as_me:$LINENO: checking for $ac_header" >&5
19372echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
19373if eval "test \"\${$as_ac_Header+set}\" = set"; then
19374 echo $ECHO_N "(cached) $ECHO_C" >&6
19375else
7c9e5167 19376 eval "$as_ac_Header=$ac_header_preproc"
647847ea 19377fi
c0d27fcc 19378echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 19379echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
19380
19381fi
503d2be0 19382if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 19383 cat >>confdefs.h <<_ACEOF
503d2be0 19384#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 19385_ACEOF
647847ea 19386
73b77ee5 19387fi
c0d27fcc 19388
503d2be0 19389done
73b77ee5 19390
c0d27fcc
MR
19391
19392
503d2be0
AS
19393for ac_func in fork vfork
19394do
19395as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 19396echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
19397echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
19398if eval "test \"\${$as_ac_var+set}\" = set"; then
19399 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 19400else
503d2be0 19401 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19402#line $LINENO "configure"
19650fd6
AS
19403/* confdefs.h. */
19404_ACEOF
19405cat confdefs.h >>conftest.$ac_ext
19406cat >>conftest.$ac_ext <<_ACEOF
19407/* end confdefs.h. */
fa0b693c 19408/* System header to define __stub macros and hopefully few prototypes,
19650fd6
AS
19409 which can conflict with char $ac_func (); below.
19410 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19411 <limits.h> exists even on freestanding compilers. */
19650fd6
AS
19412#ifdef __STDC__
19413# include <limits.h>
19414#else
19415# include <assert.h>
19416#endif
fa0b693c 19417/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
19418#ifdef __cplusplus
19419extern "C"
19650fd6 19420{
503d2be0 19421#endif
fa0b693c 19422/* We use char because int might match the return type of a gcc2
503d2be0
AS
19423 builtin and then its argument prototype would still apply. */
19424char $ac_func ();
fa0b693c
GM
19425/* The GNU C library defines this for functions which it implements
19426 to always fail with ENOSYS. Some functions are actually named
19427 something starting with __ and the normal name is an alias. */
503d2be0 19428#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
19429choke me
19430#else
19650fd6
AS
19431char (*f) () = $ac_func;
19432#endif
19433#ifdef __cplusplus
19434}
fa0b693c
GM
19435#endif
19436
19650fd6
AS
19437int
19438main ()
19439{
19440return f != $ac_func;
503d2be0
AS
19441 ;
19442 return 0;
19443}
19444_ACEOF
19445rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 19446if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 19447 (eval $ac_link) 2>&5
503d2be0 19448 ac_status=$?
c0d27fcc 19449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19450 (exit $ac_status); } &&
7c9e5167 19451 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 19452 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19453 (eval $ac_try) 2>&5
19454 ac_status=$?
c0d27fcc 19455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19456 (exit $ac_status); }; }; then
19457 eval "$as_ac_var=yes"
19458else
19459 echo "$as_me: failed program was:" >&5
19650fd6
AS
19460sed 's/^/| /' conftest.$ac_ext >&5
19461
503d2be0
AS
19462eval "$as_ac_var=no"
19463fi
7c9e5167 19464rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 19465fi
c0d27fcc 19466echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
19467echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
19468if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 19469 cat >>confdefs.h <<_ACEOF
503d2be0 19470#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 19471_ACEOF
503d2be0 19472
fa0b693c 19473fi
503d2be0 19474done
fa0b693c 19475
503d2be0 19476if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 19477 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
19478echo $ECHO_N "checking for working fork... $ECHO_C" >&6
19479if test "${ac_cv_func_fork_works+set}" = set; then
19480 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 19481else
503d2be0
AS
19482 if test "$cross_compiling" = yes; then
19483 ac_cv_func_fork_works=cross
19484else
19485 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 19486/* By Ruediger Kuhlmann. */
503d2be0
AS
19487 #include <sys/types.h>
19488 #if HAVE_UNISTD_H
19489 # include <unistd.h>
19490 #endif
19491 /* Some systems only have a dummy stub for fork() */
19492 int main ()
19493 {
7c9e5167
JD
19494 if (fork() < 0)
19495 exit (1);
19496 exit (0);
503d2be0
AS
19497 }
19498_ACEOF
19499rm -f conftest$ac_exeext
c0d27fcc 19500if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19501 (eval $ac_link) 2>&5
19502 ac_status=$?
c0d27fcc 19503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19504 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19505 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19506 (eval $ac_try) 2>&5
19507 ac_status=$?
c0d27fcc 19508 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
19509 (exit $ac_status); }; }; then
19510 ac_cv_func_fork_works=yes
19511else
19512 echo "$as_me: program exited with status $ac_status" >&5
19513echo "$as_me: failed program was:" >&5
19650fd6
AS
19514sed 's/^/| /' conftest.$ac_ext >&5
19515
c0d27fcc 19516( exit $ac_status )
503d2be0
AS
19517ac_cv_func_fork_works=no
19518fi
7c9e5167 19519rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
19520fi
19521fi
c0d27fcc 19522echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
19523echo "${ECHO_T}$ac_cv_func_fork_works" >&6
19524
6bae0ccf
DL
19525else
19526 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
19527fi
19528if test "x$ac_cv_func_fork_works" = xcross; then
19529 case $host in
19530 *-*-amigaos* | *-*-msdosdjgpp*)
19531 # Override, as these systems have only a dummy fork() stub
19532 ac_cv_func_fork_works=no
19533 ;;
19534 *)
19535 ac_cv_func_fork_works=yes
19536 ;;
19537 esac
c0d27fcc
MR
19538 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
19539echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 19540fi
73b77ee5 19541ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 19542if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 19543 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
19544echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
19545if test "${ac_cv_func_vfork_works+set}" = set; then
19546 echo $ECHO_N "(cached) $ECHO_C" >&6
19547else
19548 if test "$cross_compiling" = yes; then
19549 ac_cv_func_vfork_works=cross
fa0b693c 19550else
503d2be0 19551 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19552#line $LINENO "configure"
19650fd6
AS
19553/* confdefs.h. */
19554_ACEOF
19555cat confdefs.h >>conftest.$ac_ext
19556cat >>conftest.$ac_ext <<_ACEOF
19557/* end confdefs.h. */
73b77ee5
GM
19558/* Thanks to Paul Eggert for this test. */
19559#include <stdio.h>
19650fd6 19560#include <stdlib.h>
fa0b693c 19561#include <sys/types.h>
73b77ee5 19562#include <sys/stat.h>
19650fd6 19563#include <sys/wait.h>
503d2be0
AS
19564#if HAVE_UNISTD_H
19565# include <unistd.h>
73b77ee5 19566#endif
503d2be0
AS
19567#if HAVE_VFORK_H
19568# include <vfork.h>
73b77ee5
GM
19569#endif
19570/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
19571 argument registers are propagated back to the parent. The compiler
19572 is told about this with #include <vfork.h>, but some compilers
19573 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
19574 static variable whose address is put into a register that is
19575 clobbered by the vfork. */
19650fd6 19576static void
fa0b693c 19577#ifdef __cplusplus
73b77ee5 19578sparc_address_test (int arg)
503d2be0 19579# else
73b77ee5 19580sparc_address_test (arg) int arg;
fa0b693c 19581#endif
fa0b693c 19582{
73b77ee5
GM
19583 static pid_t child;
19584 if (!child) {
19585 child = vfork ();
19586 if (child < 0) {
19587 perror ("vfork");
19588 _exit(2);
19589 }
19590 if (!child) {
19591 arg = getpid();
19592 write(-1, "", 0);
19593 _exit (arg);
19594 }
19595 }
19596}
503d2be0
AS
19597
19598int
19599main ()
19600{
73b77ee5
GM
19601 pid_t parent = getpid ();
19602 pid_t child;
fa0b693c 19603
19650fd6 19604 sparc_address_test (0);
fa0b693c 19605
73b77ee5 19606 child = vfork ();
fa0b693c 19607
73b77ee5 19608 if (child == 0) {
503d2be0
AS
19609 /* Here is another test for sparc vfork register problems. This
19610 test uses lots of local variables, at least as many local
19611 variables as main has allocated so far including compiler
19612 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
19613 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
19614 reuse the register of parent for one of the local variables,
19615 since it will think that parent can't possibly be used any more
19616 in this routine. Assigning to the local variable will thus
19617 munge parent in the parent process. */
73b77ee5
GM
19618 pid_t
19619 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
19620 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
19621 /* Convince the compiler that p..p7 are live; otherwise, it might
19622 use the same hardware register for all 8 local variables. */
19623 if (p != p1 || p != p2 || p != p3 || p != p4
19624 || p != p5 || p != p6 || p != p7)
19625 _exit(1);
fa0b693c 19626
503d2be0
AS
19627 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
19628 from child file descriptors. If the child closes a descriptor
19629 before it execs or exits, this munges the parent's descriptor
19630 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
19631 _exit(close(fileno(stdout)) != 0);
19632 } else {
19633 int status;
19634 struct stat st;
19635
19636 while (wait(&status) != child)
19637 ;
19638 exit(
19639 /* Was there some problem with vforking? */
19640 child < 0
19641
19642 /* Did the child fail? (This shouldn't happen.) */
19643 || status
19644
19645 /* Did the vfork/compiler bug occur? */
19646 || parent != getpid()
fa0b693c 19647
73b77ee5
GM
19648 /* Did the file descriptor bug occur? */
19649 || fstat(fileno(stdout), &st) != 0
19650 );
19651 }
19652}
503d2be0
AS
19653_ACEOF
19654rm -f conftest$ac_exeext
c0d27fcc 19655if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
19656 (eval $ac_link) 2>&5
19657 ac_status=$?
c0d27fcc 19658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19659 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 19660 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19661 (eval $ac_try) 2>&5
19662 ac_status=$?
c0d27fcc 19663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19664 (exit $ac_status); }; }; then
73b77ee5 19665 ac_cv_func_vfork_works=yes
fa0b693c 19666else
503d2be0
AS
19667 echo "$as_me: program exited with status $ac_status" >&5
19668echo "$as_me: failed program was:" >&5
19650fd6
AS
19669sed 's/^/| /' conftest.$ac_ext >&5
19670
c0d27fcc 19671( exit $ac_status )
503d2be0
AS
19672ac_cv_func_vfork_works=no
19673fi
7c9e5167 19674rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 19675fi
fa0b693c 19676fi
c0d27fcc 19677echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 19678echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 19679
503d2be0
AS
19680fi;
19681if test "x$ac_cv_func_fork_works" = xcross; then
7c9e5167 19682 ac_cv_func_vfork_works=ac_cv_func_vfork
c0d27fcc
MR
19683 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
19684echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
19685fi
19686
503d2be0
AS
19687if test "x$ac_cv_func_vfork_works" = xyes; then
19688
c0d27fcc 19689cat >>confdefs.h <<\_ACEOF
503d2be0 19690#define HAVE_WORKING_VFORK 1
c0d27fcc 19691_ACEOF
503d2be0
AS
19692
19693else
19694
c0d27fcc 19695cat >>confdefs.h <<\_ACEOF
73b77ee5 19696#define vfork fork
c0d27fcc 19697_ACEOF
fa0b693c
GM
19698
19699fi
503d2be0
AS
19700if test "x$ac_cv_func_fork_works" = xyes; then
19701
c0d27fcc 19702cat >>confdefs.h <<\_ACEOF
503d2be0 19703#define HAVE_WORKING_FORK 1
c0d27fcc 19704_ACEOF
fa0b693c 19705
503d2be0 19706fi
647847ea 19707
c0d27fcc 19708
6a3a24fa
JD
19709echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
19710echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
19711if test "${emacs_cv_langinfo_codeset+set}" = set; then
19712 echo $ECHO_N "(cached) $ECHO_C" >&6
19713else
19714 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19715#line $LINENO "configure"
19650fd6
AS
19716/* confdefs.h. */
19717_ACEOF
19718cat confdefs.h >>conftest.$ac_ext
19719cat >>conftest.$ac_ext <<_ACEOF
19720/* end confdefs.h. */
6a3a24fa
JD
19721#include <langinfo.h>
19722int
19723main ()
19724{
19725char* cs = nl_langinfo(CODESET);
19726 ;
19727 return 0;
19728}
19729_ACEOF
19730rm -f conftest.$ac_objext conftest$ac_exeext
19731if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7c9e5167 19732 (eval $ac_link) 2>&5
6a3a24fa
JD
19733 ac_status=$?
19734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19735 (exit $ac_status); } &&
7c9e5167 19736 { ac_try='test -s conftest$ac_exeext'
6a3a24fa
JD
19737 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19738 (eval $ac_try) 2>&5
19739 ac_status=$?
19740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19741 (exit $ac_status); }; }; then
19742 emacs_cv_langinfo_codeset=yes
19743else
19744 echo "$as_me: failed program was:" >&5
19650fd6
AS
19745sed 's/^/| /' conftest.$ac_ext >&5
19746
6a3a24fa
JD
19747emacs_cv_langinfo_codeset=no
19748fi
7c9e5167 19749rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6a3a24fa
JD
19750
19751fi
19752echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
19753echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
19754if test $emacs_cv_langinfo_codeset = yes; then
19755
19756cat >>confdefs.h <<\_ACEOF
19757#define HAVE_LANGINFO_CODESET 1
19758_ACEOF
19759
19760fi
19761
c0d27fcc 19762echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
19763echo $ECHO_N "checking for size_t... $ECHO_C" >&6
19764if test "${ac_cv_type_size_t+set}" = set; then
19765 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 19766else
503d2be0 19767 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19768#line $LINENO "configure"
19650fd6
AS
19769/* confdefs.h. */
19770_ACEOF
19771cat confdefs.h >>conftest.$ac_ext
19772cat >>conftest.$ac_ext <<_ACEOF
19773/* end confdefs.h. */
503d2be0
AS
19774$ac_includes_default
19775int
19776main ()
19777{
19778if ((size_t *) 0)
19779 return 0;
19780if (sizeof (size_t))
19781 return 0;
19782 ;
19783 return 0;
19784}
19785_ACEOF
19786rm -f conftest.$ac_objext
c0d27fcc 19787if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19788 (eval $ac_compile) 2>&5
503d2be0 19789 ac_status=$?
c0d27fcc 19790 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19791 (exit $ac_status); } &&
7c9e5167 19792 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 19793 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
19794 (eval $ac_try) 2>&5
19795 ac_status=$?
c0d27fcc 19796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 19797 (exit $ac_status); }; }; then
8730a8da
DL
19798 ac_cv_type_size_t=yes
19799else
503d2be0 19800 echo "$as_me: failed program was:" >&5
19650fd6
AS
19801sed 's/^/| /' conftest.$ac_ext >&5
19802
503d2be0 19803ac_cv_type_size_t=no
8730a8da 19804fi
7c9e5167 19805rm -f conftest.$ac_objext conftest.$ac_ext
8730a8da 19806fi
c0d27fcc 19807echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
19808echo "${ECHO_T}$ac_cv_type_size_t" >&6
19809if test $ac_cv_type_size_t = yes; then
503d2be0 19810
c0d27fcc
MR
19811cat >>confdefs.h <<_ACEOF
19812#define HAVE_SIZE_T 1
19813_ACEOF
19814
8730a8da
DL
19815
19816fi
19817
c0d27fcc 19818
973a76b1
DL
19819echo "$as_me:$LINENO: checking for mbstate_t" >&5
19820echo $ECHO_N "checking for mbstate_t... $ECHO_C" >&6
19821if test "${ac_cv_type_mbstate_t+set}" = set; then
19822 echo $ECHO_N "(cached) $ECHO_C" >&6
19823else
19824 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19825#line $LINENO "configure"
19650fd6
AS
19826/* confdefs.h. */
19827_ACEOF
19828cat confdefs.h >>conftest.$ac_ext
19829cat >>conftest.$ac_ext <<_ACEOF
19830/* end confdefs.h. */
973a76b1
DL
19831$ac_includes_default
19832# include <wchar.h>
19833int
19834main ()
19835{
19836mbstate_t x; return sizeof x;
19837 ;
19838 return 0;
19839}
19840_ACEOF
19841rm -f conftest.$ac_objext
19842if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19843 (eval $ac_compile) 2>&5
973a76b1
DL
19844 ac_status=$?
19845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19846 (exit $ac_status); } &&
7c9e5167 19847 { ac_try='test -s conftest.$ac_objext'
973a76b1
DL
19848 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19849 (eval $ac_try) 2>&5
19850 ac_status=$?
19851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19852 (exit $ac_status); }; }; then
19853 ac_cv_type_mbstate_t=yes
19854else
19855 echo "$as_me: failed program was:" >&5
19650fd6
AS
19856sed 's/^/| /' conftest.$ac_ext >&5
19857
973a76b1
DL
19858ac_cv_type_mbstate_t=no
19859fi
7c9e5167 19860rm -f conftest.$ac_objext conftest.$ac_ext
973a76b1
DL
19861fi
19862echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5
19863echo "${ECHO_T}$ac_cv_type_mbstate_t" >&6
19864 if test $ac_cv_type_mbstate_t = yes; then
19865
19866cat >>confdefs.h <<\_ACEOF
19867#define HAVE_MBSTATE_T 1
19868_ACEOF
19869
19870 else
19871
19872cat >>confdefs.h <<\_ACEOF
19873#define mbstate_t int
19874_ACEOF
19875
19876 fi
19877
22044edf
DL
19878echo "$as_me:$LINENO: checking for C restrict keyword" >&5
19879echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
19880if test "${emacs_cv_c_restrict+set}" = set; then
19881 echo $ECHO_N "(cached) $ECHO_C" >&6
19882else
19883 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19884#line $LINENO "configure"
19650fd6
AS
19885/* confdefs.h. */
19886_ACEOF
19887cat confdefs.h >>conftest.$ac_ext
19888cat >>conftest.$ac_ext <<_ACEOF
19889/* end confdefs.h. */
22044edf
DL
19890void fred (int *restrict x);
19891int
19892main ()
19893{
b936fae4 19894
22044edf
DL
19895 ;
19896 return 0;
19897}
c0d27fcc 19898_ACEOF
22044edf
DL
19899rm -f conftest.$ac_objext
19900if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19901 (eval $ac_compile) 2>&5
22044edf
DL
19902 ac_status=$?
19903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19904 (exit $ac_status); } &&
7c9e5167 19905 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
19906 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19907 (eval $ac_try) 2>&5
19908 ac_status=$?
19909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19910 (exit $ac_status); }; }; then
19911 emacs_cv_c_restrict=yes
19912else
19913 echo "$as_me: failed program was:" >&5
19650fd6
AS
19914sed 's/^/| /' conftest.$ac_ext >&5
19915
22044edf 19916cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19917#line $LINENO "configure"
19650fd6
AS
19918/* confdefs.h. */
19919_ACEOF
19920cat confdefs.h >>conftest.$ac_ext
19921cat >>conftest.$ac_ext <<_ACEOF
19922/* end confdefs.h. */
22044edf
DL
19923void fred (int *__restrict x);
19924int
19925main ()
19926{
c0d27fcc 19927
22044edf
DL
19928 ;
19929 return 0;
19930}
c0d27fcc 19931_ACEOF
22044edf
DL
19932rm -f conftest.$ac_objext
19933if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19934 (eval $ac_compile) 2>&5
22044edf
DL
19935 ac_status=$?
19936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19937 (exit $ac_status); } &&
7c9e5167 19938 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
19939 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19940 (eval $ac_try) 2>&5
19941 ac_status=$?
19942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19943 (exit $ac_status); }; }; then
19944 emacs_cv_c_restrict=__restrict
19945else
19946 echo "$as_me: failed program was:" >&5
19650fd6
AS
19947sed 's/^/| /' conftest.$ac_ext >&5
19948
22044edf 19949emacs_cv_c_restrict=no
ba4481b5 19950fi
7c9e5167 19951rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 19952fi
7c9e5167 19953rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 19954fi
22044edf
DL
19955echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
19956echo "${ECHO_T}$emacs_cv_c_restrict" >&6
19957case "$emacs_cv_c_restrict" in
19958 yes) emacs_restrict=restrict;;
19959 no) emacs_restrict="";;
19960 *) emacs_restrict="$emacs_cv_c_restrict";;
19961esac
19962if test "$emacs_restrict" != __restrict; then
b936fae4 19963
22044edf
DL
19964cat >>confdefs.h <<_ACEOF
19965#define __restrict $emacs_restrict
c0d27fcc 19966_ACEOF
ba4481b5
DL
19967
19968fi
ba4481b5 19969
22044edf
DL
19970echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
19971echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
19972if test "${emacs_cv_c_restrict_arr+set}" = set; then
19973 echo $ECHO_N "(cached) $ECHO_C" >&6
19974else
19975 cat >conftest.$ac_ext <<_ACEOF
7c9e5167 19976#line $LINENO "configure"
19650fd6
AS
19977/* confdefs.h. */
19978_ACEOF
19979cat confdefs.h >>conftest.$ac_ext
19980cat >>conftest.$ac_ext <<_ACEOF
19981/* end confdefs.h. */
22044edf
DL
19982void fred (int x[__restrict]);
19983int
19984main ()
19985{
b936fae4 19986
22044edf
DL
19987 ;
19988 return 0;
19989}
c0d27fcc 19990_ACEOF
22044edf
DL
19991rm -f conftest.$ac_objext
19992if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7c9e5167 19993 (eval $ac_compile) 2>&5
22044edf
DL
19994 ac_status=$?
19995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
19996 (exit $ac_status); } &&
7c9e5167 19997 { ac_try='test -s conftest.$ac_objext'
22044edf
DL
19998 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19999 (eval $ac_try) 2>&5
20000 ac_status=$?
20001 echo "$as_me:$LINENO: \$? = $ac_status" >&5
20002 (exit $ac_status); }; }; then
20003 emacs_cv_c_restrict_arr=yes
20004else
20005 echo "$as_me: failed program was:" >&5
19650fd6
AS
20006sed 's/^/| /' conftest.$ac_ext >&5
20007
22044edf 20008emacs_cv_c_restrict_arr=no
ba4481b5 20009fi
7c9e5167 20010rm -f conftest.$ac_objext conftest.$ac_ext
22044edf
DL
20011fi
20012echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
20013echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
20014if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 20015
c0d27fcc 20016cat >>confdefs.h <<\_ACEOF
22044edf 20017#define __restrict_arr __restrict
c0d27fcc 20018_ACEOF
ba4481b5 20019
ba4481b5
DL
20020fi
20021
c0d27fcc 20022
c0d27fcc 20023
22044edf
DL
20024# Set up the CFLAGS for real compilation, so we can substitute it.
20025CFLAGS="$REAL_CFLAGS"
20026CPPFLAGS="$REAL_CPPFLAGS"
20027
20028#### Find out which version of Emacs this is.
20029version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
20030 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
20031if test x"${version}" = x; then
20032 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
20033echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
20034 { (exit 1); exit 1; }; }
20035fi
20036
20037### Specify what sort of things we'll be editing into Makefile and config.h.
20038### Use configuration here uncanonicalized to avoid exceeding size limits.
20039
20040
20041
20042
20043
20044
20045
20046
20047
20048
20049
20050
20051
20052
20053
20054
20055
20056
20057
20058
20059
20060
20061
20062
20063
20064
20065
20066
20067
20068
20069
20070
6a3a24fa 20071
22044edf
DL
20072
20073
20074cat >>confdefs.h <<_ACEOF
20075#define EMACS_CONFIGURATION "${canonical}"
20076_ACEOF
20077
20078
20079cat >>confdefs.h <<_ACEOF
20080#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
20081_ACEOF
20082
20083
20084cat >>confdefs.h <<_ACEOF
20085#define config_machfile "${machfile}"
20086_ACEOF
20087
20088
20089cat >>confdefs.h <<_ACEOF
20090#define config_opsysfile "${opsysfile}"
20091_ACEOF
20092
20093
20094cat >>confdefs.h <<_ACEOF
20095#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
20096_ACEOF
20097
20098
20099cat >>confdefs.h <<_ACEOF
20100#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
20101_ACEOF
20102
20103
20104cat >>confdefs.h <<_ACEOF
20105#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
20106_ACEOF
20107
20108
20109cat >>confdefs.h <<_ACEOF
20110#define UNEXEC_SRC ${UNEXEC_SRC}
20111_ACEOF
20112
20113
20114if test "${HAVE_X_WINDOWS}" = "yes" ; then
20115
20116cat >>confdefs.h <<\_ACEOF
20117#define HAVE_X_WINDOWS 1
20118_ACEOF
20119
20120fi
20121if test "${USE_X_TOOLKIT}" != "none" ; then
20122
20123cat >>confdefs.h <<\_ACEOF
20124#define USE_X_TOOLKIT 1
20125_ACEOF
20126
20127fi
20128if test "${HAVE_X11}" = "yes" ; then
20129
20130cat >>confdefs.h <<\_ACEOF
20131#define HAVE_X11 1
20132_ACEOF
20133
20134fi
20135if test "${HAVE_XFREE386}" = "yes" ; then
20136
20137cat >>confdefs.h <<\_ACEOF
20138#define HAVE_XFREE386 1
20139_ACEOF
20140
20141fi
20142if test "${HAVE_MENUS}" = "yes" ; then
20143
20144cat >>confdefs.h <<\_ACEOF
20145#define HAVE_MENUS 1
20146_ACEOF
20147
20148fi
20149if test "${GNU_MALLOC}" = "yes" ; then
20150
20151cat >>confdefs.h <<\_ACEOF
20152#define GNU_MALLOC 1
20153_ACEOF
20154
20155fi
20156if test "${REL_ALLOC}" = "yes" ; then
20157
20158cat >>confdefs.h <<\_ACEOF
20159#define REL_ALLOC 1
20160_ACEOF
20161
20162fi
20163
20164
20165
c0d27fcc
MR
20166
20167
ba4481b5 20168#### Report on what we decided to do.
488dd4c4
JD
20169#### Report GTK as a toolkit, even if it doesn't use Xt.
20170#### It makes printing result more understandable as using GTK sets
20171#### toolkit_scroll_bars to yes by default.
20172if test "${HAVE_GTK}" = "yes"; then
20173 USE_X_TOOLKIT=GTK
20174fi
20175
ba4481b5
DL
20176echo "
20177Configured for \`${canonical}'.
20178
20179 Where should the build process find the source code? ${srcdir}
20180 What operating system and machine description files should Emacs use?
20181 \`${opsysfile}' and \`${machfile}'
20182 What compiler should emacs be built with? ${CC} ${CFLAGS}
20183 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 20184 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 20185 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 20186 What window system should Emacs use? ${window_system}
8e967cf7 20187 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
20188
20189if test -n "${x_includes}"; then
20190echo " Where do we find X Windows header files? ${x_includes}"
20191else
20192echo " Where do we find X Windows header files? Standard dirs"
20193fi
20194if test -n "${x_libraries}"; then
20195echo " Where do we find X Windows libraries? ${x_libraries}"
20196else
20197echo " Where do we find X Windows libraries? Standard dirs"
20198fi
20199
20200echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
20201echo " Does Emacs use -lXpm? ${HAVE_XPM}"
20202echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
20203echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
20204echo " Does Emacs use -lungif? ${HAVE_GIF}"
20205echo " Does Emacs use -lpng? ${HAVE_PNG}"
20206echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
20207echo
20208
d0098f13
JD
20209if test $USE_XASSERTS = yes; then
20210 echo " Compiling with asserts turned on."
d0098f13
JD
20211 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
20212 echo
20213fi
05cf15c6 20214
05cf15c6 20215
05cf15c6 20216
ba4481b5
DL
20217# Remove any trailing slashes in these variables.
20218test "${prefix}" != NONE &&
20219 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
20220test "${exec_prefix}" != NONE &&
20221 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
20222
d0e9bfd2
GM
20223## Check if the C preprocessor will convert `..' to `. .'. If so, set
20224## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
20225## from Makefile.c can correctly provide the arg `-traditional' to the
20226## C preprocessor.
20227
503d2be0 20228cat >conftest.$ac_ext <<_ACEOF
7c9e5167 20229#line $LINENO "configure"
19650fd6
AS
20230/* confdefs.h. */
20231_ACEOF
20232cat confdefs.h >>conftest.$ac_ext
20233cat >>conftest.$ac_ext <<_ACEOF
20234/* end confdefs.h. */
d0e9bfd2 20235yes..yes
503d2be0 20236_ACEOF
d0e9bfd2 20237if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 20238 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
20239 CPP_NEED_TRADITIONAL=no
20240else
d0e9bfd2
GM
20241 CPP_NEED_TRADITIONAL=yes
20242fi
20243rm -f conftest*
20244
c0d27fcc 20245
6bae0ccf
DL
20246 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"
20247 ac_config_commands="$ac_config_commands default"
503d2be0 20248cat >confcache <<\_ACEOF
ba4481b5
DL
20249# This file is a shell script that caches the results of configure
20250# tests run on this system so they can be shared between configure
503d2be0
AS
20251# scripts and configure runs, see configure's option --config-cache.
20252# It is not useful on other systems. If it contains results you don't
20253# want to keep, you may remove or edit it.
ba4481b5 20254#
503d2be0
AS
20255# config.status only pays attention to the cache file if you give it
20256# the --recheck option to rerun configure.
ba4481b5 20257#
6bae0ccf 20258# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
20259# loading this file, other *unset* `ac_cv_foo' will be assigned the
20260# following values.
20261
20262_ACEOF
20263
ba4481b5
DL
20264# The following way of writing the cache mishandles newlines in values,
20265# but we know of no workaround that is simple, portable, and efficient.
20266# So, don't put newlines in cache variables' values.
20267# Ultrix sh set writes to stderr and can't be redirected directly,
20268# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
20269{
20270 (set) 2>&1 |
20271 case `(ac_space=' '; set | grep ac_space) 2>&1` in
20272 *ac_space=\ *)
20273 # `set' does not quote correctly, so add quotes (double-quote
20274 # substitution turns \\\\ into \\, and sed turns \\ into \).
20275 sed -n \
7c9e5167
JD
20276 "s/'/'\\\\''/g;
20277 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
503d2be0
AS
20278 ;;
20279 *)
20280 # `set' quotes correctly as required by POSIX, so do not add quotes.
20281 sed -n \
7c9e5167 20282 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
503d2be0
AS
20283 ;;
20284 esac;
20285} |
20286 sed '
20287 t clear
20288 : clear
20289 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
20290 t end
20291 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
20292 : end' >>confcache
19650fd6 20293if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 20294 if test -w $cache_file; then
503d2be0
AS
20295 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
20296 cat confcache >$cache_file
ba4481b5
DL
20297 else
20298 echo "not updating unwritable cache $cache_file"
20299 fi
20300fi
20301rm -f confcache
20302
ba4481b5
DL
20303test "x$prefix" = xNONE && prefix=$ac_default_prefix
20304# Let make expand exec_prefix.
20305test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
20306
503d2be0
AS
20307# VPATH may cause trouble with some makes, so we remove $(srcdir),
20308# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
20309# trailing colons and then remove the whole line if VPATH becomes empty
20310# (actually we leave an empty line to preserve line numbers).
ba4481b5 20311if test "x$srcdir" = x.; then
7c9e5167 20312 ac_vpsub='/^[ ]*VPATH[ ]*=/{
503d2be0
AS
20313s/:*\$(srcdir):*/:/;
20314s/:*\${srcdir}:*/:/;
20315s/:*@srcdir@:*/:/;
7c9e5167 20316s/^\([^=]*=[ ]*\):*/\1/;
503d2be0 20317s/:*$//;
7c9e5167 20318s/^[^=]*=[ ]*$//;
503d2be0 20319}'
ba4481b5
DL
20320fi
20321
ba4481b5
DL
20322DEFS=-DHAVE_CONFIG_H
20323
6bae0ccf
DL
20324ac_libobjs=
20325ac_ltlibobjs=
20326for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
20327 # 1. Remove the extension, and $U if already installed.
20328 ac_i=`echo "$ac_i" |
7c9e5167 20329 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
6bae0ccf
DL
20330 # 2. Add them.
20331 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
20332 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
20333done
20334LIBOBJS=$ac_libobjs
20335
20336LTLIBOBJS=$ac_ltlibobjs
20337
20338
c0d27fcc 20339
ba4481b5 20340: ${CONFIG_STATUS=./config.status}
503d2be0
AS
20341ac_clean_files_save=$ac_clean_files
20342ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 20343{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
20344echo "$as_me: creating $CONFIG_STATUS" >&6;}
20345cat >$CONFIG_STATUS <<_ACEOF
20346#! $SHELL
c0d27fcc 20347# Generated by $as_me.
ba4481b5 20348# Run this file to recreate the current configuration.
ba4481b5 20349# Compiler output produced by configure, useful for debugging
503d2be0 20350# configure, is in config.log if it exists.
ba4481b5 20351
503d2be0 20352debug=false
19650fd6
AS
20353ac_cs_recheck=false
20354ac_cs_silent=false
503d2be0 20355SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
20356_ACEOF
20357
20358cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
20359## --------------------- ##
20360## M4sh Initialization. ##
20361## --------------------- ##
20362
503d2be0
AS
20363# Be Bourne compatible
20364if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
20365 emulate sh
20366 NULLCMD=:
6bae0ccf
DL
20367 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
20368 # is contrary to our usage. Disable this feature.
20369 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
20370elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
20371 set -o posix
20372fi
20373
c0d27fcc 20374# Support unset when possible.
7c9e5167 20375if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
c0d27fcc
MR
20376 as_unset=unset
20377else
20378 as_unset=false
20379fi
20380
6bae0ccf
DL
20381
20382# Work around bugs in pre-3.0 UWIN ksh.
20383$as_unset ENV MAIL MAILPATH
20384PS1='$ '
20385PS2='> '
20386PS4='+ '
20387
20388# NLS nuisances.
19650fd6
AS
20389for as_var in \
20390 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
20391 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
20392 LC_TELEPHONE LC_TIME
6bae0ccf 20393do
7c9e5167 20394 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
6bae0ccf
DL
20395 eval $as_var=C; export $as_var
20396 else
20397 $as_unset $as_var
20398 fi
20399done
20400
20401# Required to use basename.
20402if expr a : '\(a\)' >/dev/null 2>&1; then
20403 as_expr=expr
20404else
20405 as_expr=false
20406fi
20407
20408if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
20409 as_basename=basename
20410else
20411 as_basename=false
20412fi
c0d27fcc
MR
20413
20414
503d2be0 20415# Name of the executable.
6bae0ccf 20416as_me=`$as_basename "$0" ||
c0d27fcc
MR
20417$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
20418 X"$0" : 'X\(//\)$' \| \
20419 X"$0" : 'X\(/\)$' \| \
20420 . : '\(.\)' 2>/dev/null ||
20421echo X/"$0" |
20422 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
20423 /^X\/\(\/\/\)$/{ s//\1/; q; }
20424 /^X\/\(\/\).*/{ s//\1/; q; }
20425 s/.*/./; q'`
20426
6bae0ccf 20427
c0d27fcc
MR
20428# PATH needs CR, and LINENO needs CR and PATH.
20429# Avoid depending upon Character Ranges.
20430as_cr_letters='abcdefghijklmnopqrstuvwxyz'
20431as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
20432as_cr_Letters=$as_cr_letters$as_cr_LETTERS
20433as_cr_digits='0123456789'
20434as_cr_alnum=$as_cr_Letters$as_cr_digits
20435
20436# The user is always right.
20437if test "${PATH_SEPARATOR+set}" != set; then
19650fd6
AS
20438 echo "#! /bin/sh" >conf$$.sh
20439 echo "exit 0" >>conf$$.sh
20440 chmod +x conf$$.sh
20441 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
20442 PATH_SEPARATOR=';'
20443 else
20444 PATH_SEPARATOR=:
20445 fi
19650fd6 20446 rm -f conf$$.sh
c0d27fcc
MR
20447fi
20448
20449
20450 as_lineno_1=$LINENO
20451 as_lineno_2=$LINENO
20452 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
20453 test "x$as_lineno_1" != "x$as_lineno_2" &&
20454 test "x$as_lineno_3" = "x$as_lineno_2" || {
20455 # Find who we are. Look in the path if we contain no path at all
20456 # relative or not.
20457 case $0 in
20458 *[\\/]* ) as_myself=$0 ;;
20459 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20460for as_dir in $PATH
20461do
20462 IFS=$as_save_IFS
20463 test -z "$as_dir" && as_dir=.
20464 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
20465done
20466
20467 ;;
20468 esac
20469 # We did not find ourselves, most probably we were run as `sh COMMAND'
20470 # in which case we are not to be found in the path.
20471 if test "x$as_myself" = x; then
20472 as_myself=$0
20473 fi
20474 if test ! -f "$as_myself"; then
20475 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
20476echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
20477 { (exit 1); exit 1; }; }
20478 fi
20479 case $CONFIG_SHELL in
20480 '')
20481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20482for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
20483do
20484 IFS=$as_save_IFS
20485 test -z "$as_dir" && as_dir=.
20486 for as_base in sh bash ksh sh5; do
20487 case $as_dir in
20488 /*)
20489 if ("$as_dir/$as_base" -c '
20490 as_lineno_1=$LINENO
20491 as_lineno_2=$LINENO
20492 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
20493 test "x$as_lineno_1" != "x$as_lineno_2" &&
20494 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
20495 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
20496 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
20497 CONFIG_SHELL=$as_dir/$as_base
20498 export CONFIG_SHELL
20499 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
20500 fi;;
20501 esac
20502 done
20503done
20504;;
20505 esac
20506
20507 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
20508 # uniformly replaced by the line number. The first 'sed' inserts a
20509 # line-number line before each line; the second 'sed' does the real
20510 # work. The second script uses 'N' to pair each line-number line
20511 # with the numbered line, and appends trailing '-' during
20512 # substitution so that $LINENO is not a special case at line end.
20513 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
20514 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
20515 sed '=' <$as_myself |
20516 sed '
20517 N
20518 s,$,-,
20519 : loop
20520 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
20521 t loop
20522 s,-$,,
20523 s,^['$as_cr_digits']*\n,,
20524 ' >$as_me.lineno &&
20525 chmod +x $as_me.lineno ||
20526 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
20527echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
20528 { (exit 1); exit 1; }; }
20529
20530 # Don't try to exec as it changes $[0], causing all sort of problems
20531 # (the dirname of $[0] is not the place where we might find the
20532 # original and so on. Autoconf is especially sensible to this).
20533 . ./$as_me.lineno
20534 # Exit status is that of the last command.
20535 exit
20536}
20537
20538
20539case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
20540 *c*,-n*) ECHO_N= ECHO_C='
20541' ECHO_T=' ' ;;
20542 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
20543 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
20544esac
503d2be0
AS
20545
20546if expr a : '\(a\)' >/dev/null 2>&1; then
20547 as_expr=expr
20548else
20549 as_expr=false
20550fi
20551
20552rm -f conf$$ conf$$.exe conf$$.file
20553echo >conf$$.file
20554if ln -s conf$$.file conf$$ 2>/dev/null; then
20555 # We could just check for DJGPP; but this test a) works b) is more generic
20556 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
20557 if test -f conf$$.exe; then
20558 # Don't use ln at all; we don't have any links
20559 as_ln_s='cp -p'
20560 else
20561 as_ln_s='ln -s'
20562 fi
20563elif ln conf$$.file conf$$ 2>/dev/null; then
20564 as_ln_s=ln
20565else
20566 as_ln_s='cp -p'
20567fi
20568rm -f conf$$ conf$$.exe conf$$.file
20569
6bae0ccf
DL
20570if mkdir -p . 2>/dev/null; then
20571 as_mkdir_p=:
20572else
20573 as_mkdir_p=false
20574fi
20575
503d2be0
AS
20576as_executable_p="test -f"
20577
c0d27fcc 20578# Sed expression to map a string onto a valid CPP name.
7c9e5167 20579as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
c0d27fcc
MR
20580
20581# Sed expression to map a string onto a valid variable name.
7c9e5167 20582as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
503d2be0 20583
503d2be0
AS
20584
20585# IFS
20586# We need space, tab and new line, in precisely that order.
20587as_nl='
20588'
20589IFS=" $as_nl"
20590
20591# CDPATH.
6bae0ccf 20592$as_unset CDPATH
503d2be0
AS
20593
20594exec 6>&1
20595
c0d27fcc
MR
20596# Open the log real soon, to keep \$[0] and so on meaningful, and to
20597# report actual input values of CONFIG_FILES etc. instead of their
20598# values after options handling. Logging --version etc. is OK.
20599exec 5>>config.log
20600{
20601 echo
20602 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
20603## Running $as_me. ##
20604_ASBOX
20605} >&5
20606cat >&5 <<_CSEOF
20607
20608This file was extended by $as_me, which was
7c9e5167 20609generated by GNU Autoconf 2.57. Invocation command line was
c0d27fcc
MR
20610
20611 CONFIG_FILES = $CONFIG_FILES
20612 CONFIG_HEADERS = $CONFIG_HEADERS
20613 CONFIG_LINKS = $CONFIG_LINKS
20614 CONFIG_COMMANDS = $CONFIG_COMMANDS
20615 $ $0 $@
20616
20617_CSEOF
20618echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
20619echo >&5
503d2be0
AS
20620_ACEOF
20621
20622# Files that config.status was made for.
20623if test -n "$ac_config_files"; then
20624 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
20625fi
20626
20627if test -n "$ac_config_headers"; then
20628 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
20629fi
20630
20631if test -n "$ac_config_links"; then
20632 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
20633fi
20634
20635if test -n "$ac_config_commands"; then
20636 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
20637fi
20638
c0d27fcc 20639cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
20640
20641ac_cs_usage="\
20642\`$as_me' instantiates files from templates according to the
20643current configuration.
20644
20645Usage: $0 [OPTIONS] [FILE]...
20646
20647 -h, --help print this help, then exit
20648 -V, --version print version number, then exit
19650fd6 20649 -q, --quiet do not print progress messages
503d2be0
AS
20650 -d, --debug don't remove temporary files
20651 --recheck update $as_me by reconfiguring in the same conditions
20652 --file=FILE[:TEMPLATE]
7c9e5167 20653 instantiate the configuration file FILE
503d2be0 20654 --header=FILE[:TEMPLATE]
7c9e5167 20655 instantiate the configuration header FILE
503d2be0
AS
20656
20657Configuration files:
20658$config_files
20659
20660Configuration headers:
20661$config_headers
20662
20663Configuration commands:
20664$config_commands
20665
20666Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 20667_ACEOF
503d2be0 20668
c0d27fcc 20669cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
20670ac_cs_version="\\
20671config.status
7c9e5167 20672configured by $0, generated by GNU Autoconf 2.57,
503d2be0
AS
20673 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
20674
7c9e5167
JD
20675Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
20676Free Software Foundation, Inc.
503d2be0
AS
20677This config.status script is free software; the Free Software Foundation
20678gives unlimited permission to copy, distribute and modify it."
20679srcdir=$srcdir
20680INSTALL="$INSTALL"
c0d27fcc 20681_ACEOF
503d2be0 20682
c0d27fcc 20683cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
20684# If no file are specified by the user, then we need to provide default
20685# value. By we need to know if files were specified by the user.
20686ac_need_defaults=:
20687while test $# != 0
ba4481b5 20688do
503d2be0
AS
20689 case $1 in
20690 --*=*)
20691 ac_option=`expr "x$1" : 'x\([^=]*\)='`
20692 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
20693 ac_shift=:
20694 ;;
20695 -*)
20696 ac_option=$1
20697 ac_optarg=$2
20698 ac_shift=shift
503d2be0 20699 ;;
503d2be0
AS
20700 *) # This is not an option, so the user has probably given explicit
20701 # arguments.
6bae0ccf 20702 ac_option=$1
503d2be0
AS
20703 ac_need_defaults=false;;
20704 esac
20705
6bae0ccf 20706 case $ac_option in
503d2be0 20707 # Handling of the options.
c0d27fcc 20708_ACEOF
f57bd967 20709cat >>$CONFIG_STATUS <<\_ACEOF
19650fd6
AS
20710 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
20711 ac_cs_recheck=: ;;
503d2be0
AS
20712 --version | --vers* | -V )
20713 echo "$ac_cs_version"; exit 0 ;;
20714 --he | --h)
20715 # Conflict between --help and --header
c0d27fcc 20716 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
20717Try \`$0 --help' for more information." >&5
20718echo "$as_me: error: ambiguous option: $1
20719Try \`$0 --help' for more information." >&2;}
20720 { (exit 1); exit 1; }; };;
20721 --help | --hel | -h )
20722 echo "$ac_cs_usage"; exit 0 ;;
20723 --debug | --d* | -d )
20724 debug=: ;;
20725 --file | --fil | --fi | --f )
6bae0ccf
DL
20726 $ac_shift
20727 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
20728 ac_need_defaults=false;;
20729 --header | --heade | --head | --hea )
6bae0ccf
DL
20730 $ac_shift
20731 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 20732 ac_need_defaults=false;;
19650fd6
AS
20733 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
20734 | -silent | --silent | --silen | --sile | --sil | --si | --s)
20735 ac_cs_silent=: ;;
503d2be0
AS
20736
20737 # This is an error.
c0d27fcc 20738 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
20739Try \`$0 --help' for more information." >&5
20740echo "$as_me: error: unrecognized option: $1
20741Try \`$0 --help' for more information." >&2;}
20742 { (exit 1); exit 1; }; } ;;
20743
20744 *) ac_config_targets="$ac_config_targets $1" ;;
20745
ba4481b5 20746 esac
503d2be0 20747 shift
ba4481b5
DL
20748done
20749
19650fd6
AS
20750ac_configure_extra_args=
20751
20752if $ac_cs_silent; then
20753 exec 6>/dev/null
20754 ac_configure_extra_args="$ac_configure_extra_args --silent"
20755fi
20756
20757_ACEOF
20758cat >>$CONFIG_STATUS <<_ACEOF
20759if \$ac_cs_recheck; then
20760 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
20761 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
20762fi
20763
503d2be0 20764_ACEOF
ba4481b5 20765
c0d27fcc 20766cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
20767#
20768# INIT-COMMANDS section.
20769#
ba4481b5 20770
503d2be0
AS
20771GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
20772
c0d27fcc
MR
20773_ACEOF
20774
503d2be0 20775
c0d27fcc
MR
20776
20777cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
20778for ac_config_target in $ac_config_targets
20779do
20780 case "$ac_config_target" in
20781 # Handling of arguments.
20782 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
20783 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
20784 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
20785 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
20786 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
20787 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
20788 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 20789 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 20790 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
20791 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
20792 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
20793 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 20794 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
20795echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
20796 { (exit 1); exit 1; }; };;
20797 esac
ba4481b5 20798done
503d2be0
AS
20799
20800# If the user did not use the arguments to specify the items to instantiate,
20801# then the envvar interface is used. Set only those that are not.
20802# We use the long form for the default assignment because of an extremely
20803# bizarre bug on SunOS 4.1.3.
20804if $ac_need_defaults; then
20805 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
20806 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
20807 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 20808fi
503d2be0 20809
19650fd6
AS
20810# Have a temporary directory for convenience. Make it in the build tree
20811# simply because there is no reason to put it here, and in addition,
20812# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
20813# Create a temporary directory, and hook for its removal unless debugging.
20814$debug ||
20815{
20816 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
20817 trap '{ (exit 1); exit 1; }' 1 2 13 15
20818}
20819
20820# Create a (secure) tmp directory for tmp files.
19650fd6 20821
503d2be0 20822{
19650fd6 20823 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
20824 test -n "$tmp" && test -d "$tmp"
20825} ||
20826{
19650fd6 20827 tmp=./confstat$$-$RANDOM
503d2be0
AS
20828 (umask 077 && mkdir $tmp)
20829} ||
20830{
19650fd6 20831 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
20832 { (exit 1); exit 1; }
20833}
20834
c0d27fcc 20835_ACEOF
503d2be0 20836
c0d27fcc 20837cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
20838
20839#
20840# CONFIG_FILES section.
20841#
20842
20843# No need to generate the scripts if there are no CONFIG_FILES.
20844# This happens for instance when ./config.status config.h
20845if test -n "\$CONFIG_FILES"; then
20846 # Protect against being on the right side of a sed subst in config.status.
20847 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
20848 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
20849s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
20850s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
20851s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
20852s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
20853s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
20854s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
20855s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
20856s,@exec_prefix@,$exec_prefix,;t t
20857s,@prefix@,$prefix,;t t
20858s,@program_transform_name@,$program_transform_name,;t t
20859s,@bindir@,$bindir,;t t
20860s,@sbindir@,$sbindir,;t t
20861s,@libexecdir@,$libexecdir,;t t
20862s,@datadir@,$datadir,;t t
20863s,@sysconfdir@,$sysconfdir,;t t
20864s,@sharedstatedir@,$sharedstatedir,;t t
20865s,@localstatedir@,$localstatedir,;t t
20866s,@libdir@,$libdir,;t t
20867s,@includedir@,$includedir,;t t
20868s,@oldincludedir@,$oldincludedir,;t t
20869s,@infodir@,$infodir,;t t
20870s,@mandir@,$mandir,;t t
503d2be0
AS
20871s,@build_alias@,$build_alias,;t t
20872s,@host_alias@,$host_alias,;t t
20873s,@target_alias@,$target_alias,;t t
c0d27fcc 20874s,@DEFS@,$DEFS,;t t
503d2be0
AS
20875s,@ECHO_C@,$ECHO_C,;t t
20876s,@ECHO_N@,$ECHO_N,;t t
20877s,@ECHO_T@,$ECHO_T,;t t
503d2be0 20878s,@LIBS@,$LIBS,;t t
19650fd6 20879s,@MAINT@,$MAINT,;t t
503d2be0
AS
20880s,@build@,$build,;t t
20881s,@build_cpu@,$build_cpu,;t t
20882s,@build_vendor@,$build_vendor,;t t
20883s,@build_os@,$build_os,;t t
20884s,@host@,$host,;t t
20885s,@host_cpu@,$host_cpu,;t t
20886s,@host_vendor@,$host_vendor,;t t
20887s,@host_os@,$host_os,;t t
20888s,@CC@,$CC,;t t
20889s,@CFLAGS@,$CFLAGS,;t t
20890s,@LDFLAGS@,$LDFLAGS,;t t
20891s,@CPPFLAGS@,$CPPFLAGS,;t t
20892s,@ac_ct_CC@,$ac_ct_CC,;t t
20893s,@EXEEXT@,$EXEEXT,;t t
20894s,@OBJEXT@,$OBJEXT,;t t
20895s,@LN_S@,$LN_S,;t t
20896s,@CPP@,$CPP,;t t
20897s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
20898s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
20899s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
20900s,@RANLIB@,$RANLIB,;t t
20901s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 20902s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 20903s,@EGREP@,$EGREP,;t t
503d2be0
AS
20904s,@LIBSOUND@,$LIBSOUND,;t t
20905s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
20906s,@PKG_CONFIG@,$PKG_CONFIG,;t t
20907s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
20908s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
20909s,@ALLOCA@,$ALLOCA,;t t
20910s,@liblockfile@,$liblockfile,;t t
20911s,@LIBOBJS@,$LIBOBJS,;t t
20912s,@NEED_SETGID@,$NEED_SETGID,;t t
20913s,@KMEM_GROUP@,$KMEM_GROUP,;t t
20914s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
20915s,@version@,$version,;t t
20916s,@configuration@,$configuration,;t t
20917s,@canonical@,$canonical,;t t
20918s,@srcdir@,$srcdir,;t t
20919s,@lispdir@,$lispdir,;t t
20920s,@locallisppath@,$locallisppath,;t t
20921s,@lisppath@,$lisppath,;t t
20922s,@x_default_search_path@,$x_default_search_path,;t t
20923s,@etcdir@,$etcdir,;t t
20924s,@archlibdir@,$archlibdir,;t t
20925s,@docdir@,$docdir,;t t
20926s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
20927s,@gamedir@,$gamedir,;t t
20928s,@gameuser@,$gameuser,;t t
503d2be0
AS
20929s,@c_switch_system@,$c_switch_system,;t t
20930s,@c_switch_machine@,$c_switch_machine,;t t
20931s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
20932s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
20933s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
20934s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
20935s,@machfile@,$machfile,;t t
20936s,@opsysfile@,$opsysfile,;t t
6a3a24fa 20937s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 20938s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
20939CEOF
20940
c0d27fcc 20941_ACEOF
ba4481b5 20942
c0d27fcc 20943 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
20944 # Split the substitutions into bite-sized pieces for seds with
20945 # small command number limits, like on Digital OSF/1 and HP-UX.
20946 ac_max_sed_lines=48
20947 ac_sed_frag=1 # Number of current file.
20948 ac_beg=1 # First line for current file.
20949 ac_end=$ac_max_sed_lines # Line after last line for current file.
20950 ac_more_lines=:
20951 ac_sed_cmds=
20952 while $ac_more_lines; do
20953 if test $ac_beg -gt 1; then
20954 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
20955 else
20956 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
20957 fi
20958 if test ! -s $tmp/subs.frag; then
20959 ac_more_lines=false
20960 else
20961 # The purpose of the label and of the branching condition is to
20962 # speed up the sed processing (if there are no `@' at all, there
20963 # is no need to browse any of the substitutions).
20964 # These are the two extra sed commands mentioned above.
20965 (echo ':t
20966 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
20967 if test -z "$ac_sed_cmds"; then
7c9e5167 20968 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0 20969 else
7c9e5167 20970 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
503d2be0
AS
20971 fi
20972 ac_sed_frag=`expr $ac_sed_frag + 1`
20973 ac_beg=$ac_end
20974 ac_end=`expr $ac_end + $ac_max_sed_lines`
20975 fi
20976 done
20977 if test -z "$ac_sed_cmds"; then
20978 ac_sed_cmds=cat
20979 fi
20980fi # test -n "$CONFIG_FILES"
ba4481b5 20981
c0d27fcc
MR
20982_ACEOF
20983cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 20984for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 20985 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
20986 case $ac_file in
20987 - | *:- | *:-:* ) # input from stdin
7c9e5167
JD
20988 cat >$tmp/stdin
20989 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20990 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 20991 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7c9e5167 20992 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 20993 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
20994 esac
20995
503d2be0 20996 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
20997 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
20998$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
20999 X"$ac_file" : 'X\(//\)[^/]' \| \
21000 X"$ac_file" : 'X\(//\)$' \| \
21001 X"$ac_file" : 'X\(/\)' \| \
21002 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
21003echo X"$ac_file" |
21004 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21005 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21006 /^X\(\/\/\)$/{ s//\1/; q; }
21007 /^X\(\/\).*/{ s//\1/; q; }
21008 s/.*/./; q'`
6bae0ccf
DL
21009 { if $as_mkdir_p; then
21010 mkdir -p "$ac_dir"
21011 else
21012 as_dir="$ac_dir"
21013 as_dirs=
21014 while test ! -d "$as_dir"; do
21015 as_dirs="$as_dir $as_dirs"
21016 as_dir=`(dirname "$as_dir") 2>/dev/null ||
21017$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
21018 X"$as_dir" : 'X\(//\)[^/]' \| \
21019 X"$as_dir" : 'X\(//\)$' \| \
21020 X"$as_dir" : 'X\(/\)' \| \
21021 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
21022echo X"$as_dir" |
21023 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21024 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21025 /^X\(\/\/\)$/{ s//\1/; q; }
21026 /^X\(\/\).*/{ s//\1/; q; }
21027 s/.*/./; q'`
21028 done
21029 test ! -n "$as_dirs" || mkdir $as_dirs
21030 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
21031echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
21032 { (exit 1); exit 1; }; }; }
503d2be0 21033
c0d27fcc 21034 ac_builddir=.
98418dba 21035
c0d27fcc
MR
21036if test "$ac_dir" != .; then
21037 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
21038 # A "../" for each directory in $ac_dir_suffix.
21039 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
21040else
21041 ac_dir_suffix= ac_top_builddir=
21042fi
21043
21044case $srcdir in
21045 .) # No --srcdir option. We are building in place.
21046 ac_srcdir=.
21047 if test -z "$ac_top_builddir"; then
21048 ac_top_srcdir=.
21049 else
21050 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
21051 fi ;;
21052 [\\/]* | ?:[\\/]* ) # Absolute path.
21053 ac_srcdir=$srcdir$ac_dir_suffix;
21054 ac_top_srcdir=$srcdir ;;
ba4481b5 21055 *) # Relative path.
c0d27fcc
MR
21056 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
21057 ac_top_srcdir=$ac_top_builddir$srcdir ;;
21058esac
7c9e5167
JD
21059# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
21060# absolute.
21061ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
21062ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
21063ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
21064ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
c0d27fcc 21065
ba4481b5 21066
503d2be0
AS
21067 case $INSTALL in
21068 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 21069 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
21070 esac
21071
7c9e5167
JD
21072 if test x"$ac_file" != x-; then
21073 { echo "$as_me:$LINENO: creating $ac_file" >&5
21074echo "$as_me: creating $ac_file" >&6;}
21075 rm -f "$ac_file"
21076 fi
503d2be0
AS
21077 # Let's still pretend it is `configure' which instantiates (i.e., don't
21078 # use $as_me), people would be surprised to read:
c0d27fcc
MR
21079 # /* config.h. Generated by config.status. */
21080 if test x"$ac_file" = x-; then
21081 configure_input=
21082 else
21083 configure_input="$ac_file. "
21084 fi
21085 configure_input=$configure_input"Generated from `echo $ac_file_in |
7c9e5167 21086 sed 's,.*/,,'` by configure."
503d2be0
AS
21087
21088 # First look for the input files in the build tree, otherwise in the
21089 # src tree.
21090 ac_file_inputs=`IFS=:
21091 for f in $ac_file_in; do
21092 case $f in
21093 -) echo $tmp/stdin ;;
21094 [\\/$]*)
7c9e5167
JD
21095 # Absolute (can't be DOS-style, as IFS=:)
21096 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
21097echo "$as_me: error: cannot find input file: $f" >&2;}
21098 { (exit 1); exit 1; }; }
7c9e5167 21099 echo $f;;
503d2be0 21100 *) # Relative
7c9e5167
JD
21101 if test -f "$f"; then
21102 # Build tree
21103 echo $f
21104 elif test -f "$srcdir/$f"; then
21105 # Source tree
21106 echo $srcdir/$f
21107 else
21108 # /dev/null tree
21109 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
21110echo "$as_me: error: cannot find input file: $f" >&2;}
21111 { (exit 1); exit 1; }; }
7c9e5167 21112 fi;;
503d2be0
AS
21113 esac
21114 done` || { (exit 1); exit 1; }
c0d27fcc
MR
21115_ACEOF
21116cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
21117 sed "$ac_vpsub
21118$extrasub
c0d27fcc
MR
21119_ACEOF
21120cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21121:t
21122/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
21123s,@configure_input@,$configure_input,;t t
21124s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 21125s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 21126s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
21127s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
21128s,@builddir@,$ac_builddir,;t t
21129s,@abs_builddir@,$ac_abs_builddir,;t t
21130s,@top_builddir@,$ac_top_builddir,;t t
21131s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
21132s,@INSTALL@,$ac_INSTALL,;t t
21133" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
21134 rm -f $tmp/stdin
21135 if test x"$ac_file" != x-; then
21136 mv $tmp/out $ac_file
21137 else
21138 cat $tmp/out
21139 rm -f $tmp/out
21140 fi
21141
21142done
c0d27fcc
MR
21143_ACEOF
21144cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 21145
503d2be0
AS
21146#
21147# CONFIG_HEADER section.
21148#
ba4481b5
DL
21149
21150# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
21151# NAME is the cpp macro being defined and VALUE is the value it is being given.
21152#
21153# ac_d sets the value in "#define NAME VALUE" lines.
7c9e5167
JD
21154ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
21155ac_dB='[ ].*$,\1#\2'
503d2be0
AS
21156ac_dC=' '
21157ac_dD=',;t'
21158# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
7c9e5167 21159ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
503d2be0 21160ac_uB='$,\1#\2define\3'
ba4481b5 21161ac_uC=' '
503d2be0 21162ac_uD=',;t'
ba4481b5 21163
503d2be0 21164for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 21165 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
21166 case $ac_file in
21167 - | *:- | *:-:* ) # input from stdin
7c9e5167
JD
21168 cat >$tmp/stdin
21169 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
21170 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 21171 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
7c9e5167 21172 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
503d2be0 21173 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
21174 esac
21175
c0d27fcc 21176 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
21177echo "$as_me: creating $ac_file" >&6;}
21178
21179 # First look for the input files in the build tree, otherwise in the
21180 # src tree.
21181 ac_file_inputs=`IFS=:
21182 for f in $ac_file_in; do
21183 case $f in
21184 -) echo $tmp/stdin ;;
21185 [\\/$]*)
7c9e5167
JD
21186 # Absolute (can't be DOS-style, as IFS=:)
21187 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
21188echo "$as_me: error: cannot find input file: $f" >&2;}
21189 { (exit 1); exit 1; }; }
7c9e5167 21190 echo $f;;
503d2be0 21191 *) # Relative
7c9e5167
JD
21192 if test -f "$f"; then
21193 # Build tree
21194 echo $f
21195 elif test -f "$srcdir/$f"; then
21196 # Source tree
21197 echo $srcdir/$f
21198 else
21199 # /dev/null tree
21200 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
21201echo "$as_me: error: cannot find input file: $f" >&2;}
21202 { (exit 1); exit 1; }; }
7c9e5167 21203 fi;;
503d2be0
AS
21204 esac
21205 done` || { (exit 1); exit 1; }
21206 # Remove the trailing spaces.
7c9e5167 21207 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
503d2be0 21208
c0d27fcc 21209_ACEOF
503d2be0
AS
21210
21211# Transform confdefs.h into two sed scripts, `conftest.defines' and
21212# `conftest.undefs', that substitutes the proper values into
21213# config.h.in to produce config.h. The first handles `#define'
21214# templates, and the second `#undef' templates.
21215# And first: Protect against being on the right side of a sed subst in
21216# config.status. Protect against being in an unquoted here document
21217# in config.status.
21218rm -f conftest.defines conftest.undefs
21219# Using a here document instead of a string reduces the quoting nightmare.
21220# Putting comments in sed scripts is not portable.
21221#
21222# `end' is used to avoid that the second main sed command (meant for
21223# 0-ary CPP macros) applies to n-ary macro definitions.
21224# See the Autoconf documentation for `clear'.
c0d27fcc 21225cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
21226s/[\\&,]/\\&/g
21227s,[\\$`],\\&,g
21228t clear
21229: clear
7c9e5167 21230s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0 21231t end
7c9e5167 21232s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
503d2be0 21233: end
c0d27fcc 21234_ACEOF
503d2be0
AS
21235# If some macros were called several times there might be several times
21236# the same #defines, which is useless. Nevertheless, we may not want to
21237# sort them, since we want the *last* AC-DEFINE to be honored.
21238uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
21239sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
21240rm -f confdef2sed.sed
ba4481b5
DL
21241
21242# This sed command replaces #undef with comments. This is necessary, for
21243# example, in the case of _POSIX_SOURCE, which is predefined and required
21244# on some systems where configure will not decide to define it.
c0d27fcc 21245cat >>conftest.undefs <<\_ACEOF
7c9e5167 21246s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 21247_ACEOF
ba4481b5 21248
503d2be0
AS
21249# Break up conftest.defines because some shells have a limit on the size
21250# of here documents, and old seds have small limits too (100 cmds).
21251echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
7c9e5167 21252echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
21253echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
21254echo ' :' >>$CONFIG_STATUS
21255rm -f conftest.tail
21256while grep . conftest.defines >/dev/null
21257do
21258 # Write a limited-size here document to $tmp/defines.sed.
21259 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
21260 # Speed up: don't consider the non `#define' lines.
7c9e5167 21261 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
503d2be0
AS
21262 # Work around the forget-to-reset-the-flag bug.
21263 echo 't clr' >>$CONFIG_STATUS
21264 echo ': clr' >>$CONFIG_STATUS
21265 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
21266 echo 'CEOF
21267 sed -f $tmp/defines.sed $tmp/in >$tmp/out
21268 rm -f $tmp/in
21269 mv $tmp/out $tmp/in
21270' >>$CONFIG_STATUS
21271 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
21272 rm -f conftest.defines
21273 mv conftest.tail conftest.defines
21274done
21275rm -f conftest.defines
6bae0ccf 21276echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 21277echo >>$CONFIG_STATUS
ba4481b5 21278
503d2be0
AS
21279# Break up conftest.undefs because some shells have a limit on the size
21280# of here documents, and old seds have small limits too (100 cmds).
21281echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 21282rm -f conftest.tail
503d2be0 21283while grep . conftest.undefs >/dev/null
ba4481b5 21284do
503d2be0
AS
21285 # Write a limited-size here document to $tmp/undefs.sed.
21286 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
21287 # Speed up: don't consider the non `#undef'
7c9e5167 21288 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
503d2be0
AS
21289 # Work around the forget-to-reset-the-flag bug.
21290 echo 't clr' >>$CONFIG_STATUS
21291 echo ': clr' >>$CONFIG_STATUS
21292 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 21293 echo 'CEOF
503d2be0
AS
21294 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
21295 rm -f $tmp/in
21296 mv $tmp/out $tmp/in
21297' >>$CONFIG_STATUS
21298 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
21299 rm -f conftest.undefs
21300 mv conftest.tail conftest.undefs
ba4481b5 21301done
503d2be0
AS
21302rm -f conftest.undefs
21303
c0d27fcc 21304cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21305 # Let's still pretend it is `configure' which instantiates (i.e., don't
21306 # use $as_me), people would be surprised to read:
c0d27fcc 21307 # /* config.h. Generated by config.status. */
503d2be0 21308 if test x"$ac_file" = x-; then
c0d27fcc 21309 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 21310 else
c0d27fcc 21311 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
21312 fi
21313 cat $tmp/in >>$tmp/config.h
21314 rm -f $tmp/in
21315 if test x"$ac_file" != x-; then
19650fd6 21316 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 21317 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
21318echo "$as_me: $ac_file is unchanged" >&6;}
21319 else
c0d27fcc
MR
21320 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
21321$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
21322 X"$ac_file" : 'X\(//\)[^/]' \| \
21323 X"$ac_file" : 'X\(//\)$' \| \
21324 X"$ac_file" : 'X\(/\)' \| \
21325 . : '\(.\)' 2>/dev/null ||
503d2be0
AS
21326echo X"$ac_file" |
21327 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21328 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21329 /^X\(\/\/\)$/{ s//\1/; q; }
21330 /^X\(\/\).*/{ s//\1/; q; }
21331 s/.*/./; q'`
6bae0ccf
DL
21332 { if $as_mkdir_p; then
21333 mkdir -p "$ac_dir"
21334 else
21335 as_dir="$ac_dir"
21336 as_dirs=
21337 while test ! -d "$as_dir"; do
21338 as_dirs="$as_dir $as_dirs"
21339 as_dir=`(dirname "$as_dir") 2>/dev/null ||
21340$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
21341 X"$as_dir" : 'X\(//\)[^/]' \| \
21342 X"$as_dir" : 'X\(//\)$' \| \
21343 X"$as_dir" : 'X\(/\)' \| \
21344 . : '\(.\)' 2>/dev/null ||
6bae0ccf
DL
21345echo X"$as_dir" |
21346 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21347 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21348 /^X\(\/\/\)$/{ s//\1/; q; }
21349 /^X\(\/\).*/{ s//\1/; q; }
21350 s/.*/./; q'`
21351 done
21352 test ! -n "$as_dirs" || mkdir $as_dirs
21353 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
21354echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
21355 { (exit 1); exit 1; }; }; }
503d2be0 21356
503d2be0
AS
21357 rm -f $ac_file
21358 mv $tmp/config.h $ac_file
ba4481b5 21359 fi
503d2be0
AS
21360 else
21361 cat $tmp/config.h
21362 rm -f $tmp/config.h
ba4481b5 21363 fi
503d2be0 21364done
c0d27fcc
MR
21365_ACEOF
21366cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
21367
21368#
21369# CONFIG_COMMANDS section.
21370#
21371for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
21372 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
21373 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
21374 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
21375$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7c9e5167
JD
21376 X"$ac_dest" : 'X\(//\)[^/]' \| \
21377 X"$ac_dest" : 'X\(//\)$' \| \
21378 X"$ac_dest" : 'X\(/\)' \| \
21379 . : '\(.\)' 2>/dev/null ||
c0d27fcc
MR
21380echo X"$ac_dest" |
21381 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
21382 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
21383 /^X\(\/\/\)$/{ s//\1/; q; }
21384 /^X\(\/\).*/{ s//\1/; q; }
21385 s/.*/./; q'`
21386 ac_builddir=.
21387
21388if test "$ac_dir" != .; then
21389 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
21390 # A "../" for each directory in $ac_dir_suffix.
21391 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
21392else
21393 ac_dir_suffix= ac_top_builddir=
21394fi
21395
21396case $srcdir in
21397 .) # No --srcdir option. We are building in place.
21398 ac_srcdir=.
21399 if test -z "$ac_top_builddir"; then
21400 ac_top_srcdir=.
21401 else
21402 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
21403 fi ;;
21404 [\\/]* | ?:[\\/]* ) # Absolute path.
21405 ac_srcdir=$srcdir$ac_dir_suffix;
21406 ac_top_srcdir=$srcdir ;;
21407 *) # Relative path.
21408 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
21409 ac_top_srcdir=$ac_top_builddir$srcdir ;;
21410esac
7c9e5167
JD
21411# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
21412# absolute.
21413ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
21414ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
21415ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
21416ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
ba4481b5 21417
c0d27fcc
MR
21418
21419 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
21420echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
21421 case $ac_dest in
21422 default )
ba4481b5
DL
21423
21424### Make the necessary directories, if they don't exist.
21425for dir in etc lisp ; do
21426 test -d ${dir} || mkdir ${dir}
21427done
21428
21429# Build src/Makefile from ${srcdir}/src/Makefile.c
21430# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
21431# This must be done after src/config.h is built, since we rely on that file.
21432
21433# Now get this: Some word that is part of the ${srcdir} directory name
21434# or the ${configuration} value might, just might, happen to be an
21435# identifier like `sun4' or `i386' or something, and be predefined by
21436# the C preprocessor to some helpful value like 1, or maybe the empty
21437# string. Needless to say consequent macro substitutions are less
21438# than conducive to the makefile finding the correct directory.
21439undefs="`echo $top_srcdir $configuration $canonical |
21440sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
21441 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
21442`"
21443
21444echo creating src/epaths.h
4aa6b955 21445${MAKE-make} epaths-force
ba4481b5 21446
1c203d4c
DL
21447# As of 2000-11-19, newest development versions of GNU cpp preprocess
21448# `..' to `. .' unless invoked with -traditional
21449
d0e9bfd2 21450if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
21451 CPPFLAGS="$CPPFLAGS -traditional"
21452fi
21453
ba4481b5
DL
21454echo creating lib-src/Makefile
21455( cd lib-src
21456 rm -f junk.c junk1.c junk2.c
21457 sed -e '/start of cpp stuff/q' \
21458 < Makefile.c > junk1.c
21459 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 21460 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 21461 < Makefile.c > junk.c
503d2be0 21462 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
21463 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
21464 cat junk1.c junk2.c > Makefile.new
21465 rm -f junk.c junk1.c junk2.c
21466 chmod 444 Makefile.new
21467 mv -f Makefile.new Makefile
21468)
21469
21470echo creating src/Makefile
21471( cd src
21472 rm -f junk.c junk1.c junk2.c
21473 sed -e '/start of cpp stuff/q' \
21474 < Makefile.c > junk1.c
21475 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 21476 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 21477 < Makefile.c > junk.c
503d2be0 21478 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
21479 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
21480 cat junk1.c junk2.c > Makefile.new
21481 rm -f junk.c junk1.c junk2.c
21482 chmod 444 Makefile.new
21483 mv -f Makefile.new Makefile
21484)
21485
503d2be0 21486if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 21487 echo creating src/.gdbinit
503d2be0 21488 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
21489fi
21490
21491# This is how we know whether to re-run configure in certain cases.
21492touch src/config.stamp
21493
503d2be0
AS
21494 ;;
21495 esac
21496done
c0d27fcc 21497_ACEOF
503d2be0 21498
c0d27fcc 21499cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 21500
503d2be0 21501{ (exit 0); exit 0; }
c0d27fcc 21502_ACEOF
ba4481b5 21503chmod +x $CONFIG_STATUS
503d2be0
AS
21504ac_clean_files=$ac_clean_files_save
21505
c0d27fcc 21506
503d2be0
AS
21507# configure is writing to config.log, and then calls config.status.
21508# config.status does its own redirection, appending to config.log.
21509# Unfortunately, on DOS this fails, as config.log is still kept open
21510# by configure, so config.status won't be able to write to it; its
21511# output is simply discarded. So we exec the FD to /dev/null,
21512# effectively closing config.log, so it can be properly (re)opened and
21513# appended to by config.status. When coming back to configure, we
21514# need to make the FD available again.
21515if test "$no_create" != yes; then
21516 ac_cs_success=:
19650fd6
AS
21517 ac_config_status_args=
21518 test "$silent" = yes &&
21519 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 21520 exec 5>/dev/null
19650fd6 21521 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
21522 exec 5>>config.log
21523 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
21524 # would make configure fail if this is the last instruction.
21525 $ac_cs_success || { (exit 1); exit 1; }
21526fi
f5f47add 21527
c0d27fcc 21528