* simple.el (kill-whole-line): New function.
[bpt/emacs.git] / configure
CommitLineData
ba4481b5 1#! /bin/sh
ba4481b5 2# Guess values for system-dependent variables and create Makefiles.
9e71690e 3# Generated by GNU Autoconf 2.57.
ba4481b5 4#
c0d27fcc 5# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
503d2be0 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
MR
24# Support unset when possible.
25if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
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.
cd958eb3
MB
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
DL
43do
44 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
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
cd958eb3
MB
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
cd958eb3 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
MR
226# Sed expression to map a string onto a valid CPP name.
227as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
228
229# Sed expression to map a string onto a valid variable name.
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
488dd4c4 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 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 \
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\(.*[^/]\)//*[^/][^/]*/*$' \| \
711 X"$0" : 'X\(//\)[^/]' \| \
712 X"$0" : 'X\(//\)$' \| \
713 X"$0" : 'X\(/\)' \| \
714 . : '\(.\)' 2>/dev/null ||
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
806 [$ac_default_prefix]
807 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
808 [PREFIX]
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
503d2be0
AS
858 --disable-largefile omit support for large files
859
860Optional Packages:
861 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
862 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
863 --without-gcc don't use GCC to compile Emacs if GCC is found
864 --without-pop don't support POP mail retrieval with movemail
865 --with-kerberos support Kerberos-authenticated POP
866 --with-kerberos5 support Kerberos version 5 authenticated POP
867 --with-hesiod support Hesiod to get the POP server host
2c9dccc9 868 --without-sound don't compile with sound support
488dd4c4
JD
869 --with-x-toolkit=KIT use an X toolkit
870 (KIT = yes/lucid/athena/motif/gtk/no)
503d2be0
AS
871 --with-xpm use -lXpm for displaying XPM images
872 --with-jpeg use -ljpeg for displaying JPEG images
873 --with-tiff use -ltiff for displaying TIFF images
874 --with-gif use -lungif for displaying GIF images
875 --with-png use -lpng for displaying PNG images
488dd4c4
JD
876 --with-gtk use GTK (same as --with-x-toolkit=gtk)
877 --with-pkg-config-prog Path to pkg-config to use for finding GTK
503d2be0 878 --without-toolkit-scroll-bars
cc227489
MB
879 don't use Motif or Xaw3d scroll bars
880 --without-xim don't use X11 XIM
e0f712ba 881 --without-carbon don't use Carbon GUI on Mac OS X
503d2be0
AS
882 --with-x use the X Window System
883
884Some influential environment variables:
885 CC C compiler command
886 CFLAGS C compiler flags
887 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
888 nonstandard directory <lib dir>
889 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
890 headers in a nonstandard directory <include dir>
891 CPP C preprocessor
892
893Use these variables to override the choices made by `configure' or to help
894it to find libraries and programs with nonstandard names/locations.
895
c0d27fcc 896_ACEOF
503d2be0
AS
897fi
898
899if test "$ac_init_help" = "recursive"; then
900 # If there are subdirs, report their specific --help.
901 ac_popdir=`pwd`
c0d27fcc
MR
902 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
903 test -d $ac_dir || continue
904 ac_builddir=.
905
906if test "$ac_dir" != .; then
907 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
908 # A "../" for each directory in $ac_dir_suffix.
909 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
910else
911 ac_dir_suffix= ac_top_builddir=
912fi
503d2be0 913
c0d27fcc
MR
914case $srcdir in
915 .) # No --srcdir option. We are building in place.
916 ac_srcdir=.
917 if test -z "$ac_top_builddir"; then
918 ac_top_srcdir=.
919 else
920 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
921 fi ;;
922 [\\/]* | ?:[\\/]* ) # Absolute path.
923 ac_srcdir=$srcdir$ac_dir_suffix;
924 ac_top_srcdir=$srcdir ;;
925 *) # Relative path.
926 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
927 ac_top_srcdir=$ac_top_builddir$srcdir ;;
928esac
929# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
930# absolute.
931ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
6bae0ccf 932ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
c0d27fcc
MR
933ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
934ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
935
936 cd $ac_dir
503d2be0 937 # Check for guested configure; otherwise get Cygnus style configure.
c0d27fcc 938 if test -f $ac_srcdir/configure.gnu; then
503d2be0 939 echo
c0d27fcc
MR
940 $SHELL $ac_srcdir/configure.gnu --help=recursive
941 elif test -f $ac_srcdir/configure; then
503d2be0 942 echo
c0d27fcc
MR
943 $SHELL $ac_srcdir/configure --help=recursive
944 elif test -f $ac_srcdir/configure.ac ||
945 test -f $ac_srcdir/configure.in; then
503d2be0
AS
946 echo
947 $ac_configure --help
948 else
c0d27fcc 949 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
503d2be0
AS
950 fi
951 cd $ac_popdir
952 done
953fi
954
955test -n "$ac_init_help" && exit 0
956if $ac_init_version; then
c0d27fcc 957 cat <<\_ACEOF
503d2be0 958
c0d27fcc 959Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
503d2be0
AS
960Free Software Foundation, Inc.
961This configure script is free software; the Free Software Foundation
962gives unlimited permission to copy, distribute and modify it.
c0d27fcc 963_ACEOF
503d2be0
AS
964 exit 0
965fi
966exec 5>config.log
c0d27fcc 967cat >&5 <<_ACEOF
503d2be0
AS
968This file contains any messages produced by compilers while
969running configure, to aid debugging if configure makes a mistake.
970
971It was created by $as_me, which was
9e71690e 972generated by GNU Autoconf 2.57. Invocation command line was
503d2be0
AS
973
974 $ $0 $@
975
c0d27fcc 976_ACEOF
503d2be0
AS
977{
978cat <<_ASUNAME
c0d27fcc
MR
979## --------- ##
980## Platform. ##
981## --------- ##
503d2be0
AS
982
983hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
984uname -m = `(uname -m) 2>/dev/null || echo unknown`
985uname -r = `(uname -r) 2>/dev/null || echo unknown`
986uname -s = `(uname -s) 2>/dev/null || echo unknown`
987uname -v = `(uname -v) 2>/dev/null || echo unknown`
988
989/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
990/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
991
992/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
993/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
994/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
995hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
996/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
997/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
998/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
999
925c2f3f 1000_ASUNAME
c0d27fcc
MR
1001
1002as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1003for as_dir in $PATH
1004do
1005 IFS=$as_save_IFS
1006 test -z "$as_dir" && as_dir=.
1007 echo "PATH: $as_dir"
1008done
1009
503d2be0
AS
1010} >&5
1011
c0d27fcc
MR
1012cat >&5 <<_ACEOF
1013
1014
1015## ----------- ##
1016## Core tests. ##
1017## ----------- ##
1018
1019_ACEOF
503d2be0 1020
503d2be0
AS
1021
1022# Keep a trace of the command line.
1023# Strip out --no-create and --no-recursion so they do not pile up.
cd958eb3 1024# Strip out --silent because we don't want to record it for future runs.
503d2be0 1025# Also quote any args containing shell meta-characters.
cd958eb3 1026# Make two passes to allow for proper duplicate-argument suppression.
503d2be0 1027ac_configure_args=
cd958eb3
MB
1028ac_configure_args0=
1029ac_configure_args1=
503d2be0 1030ac_sep=
cd958eb3
MB
1031ac_must_keep_next=false
1032for ac_pass in 1 2
503d2be0 1033do
cd958eb3
MB
1034 for ac_arg
1035 do
1036 case $ac_arg in
1037 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1038 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1039 | -silent | --silent | --silen | --sile | --sil)
1040 continue ;;
1041 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1042 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1043 esac
1044 case $ac_pass in
1045 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1046 2)
1047 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1048 if test $ac_must_keep_next = true; then
1049 ac_must_keep_next=false # Got value, back to normal.
1050 else
1051 case $ac_arg in
1052 *=* | --config-cache | -C | -disable-* | --disable-* \
1053 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1054 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1055 | -with-* | --with-* | -without-* | --without-* | --x)
1056 case "$ac_configure_args0 " in
1057 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1058 esac
1059 ;;
1060 -* ) ac_must_keep_next=true ;;
1061 esac
1062 fi
1063 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1064 # Get rid of the leading space.
1065 ac_sep=" "
1066 ;;
1067 esac
1068 done
503d2be0 1069done
cd958eb3
MB
1070$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1071$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
503d2be0
AS
1072
1073# When interrupted or exit'd, cleanup temporary files, and complete
1074# config.log. We remove comments because anyway the quotes in there
1075# would cause problems or look ugly.
c0d27fcc
MR
1076# WARNING: Be sure not to use single quotes in there, as some shells,
1077# such as our DU 5.0 friend, will then `close' the trap.
503d2be0
AS
1078trap 'exit_status=$?
1079 # Save into config.log some information that might help in debugging.
c0d27fcc
MR
1080 {
1081 echo
6bae0ccf 1082
c0d27fcc
MR
1083 cat <<\_ASBOX
1084## ---------------- ##
1085## Cache variables. ##
1086## ---------------- ##
1087_ASBOX
1088 echo
1089 # The following way of writing the cache mishandles newlines in values,
503d2be0
AS
1090{
1091 (set) 2>&1 |
1092 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1093 *ac_space=\ *)
1094 sed -n \
1095 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1096 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1097 ;;
1098 *)
1099 sed -n \
1100 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1101 ;;
1102 esac;
c0d27fcc
MR
1103}
1104 echo
6bae0ccf
DL
1105
1106 cat <<\_ASBOX
1107## ----------------- ##
1108## Output variables. ##
1109## ----------------- ##
1110_ASBOX
1111 echo
1112 for ac_var in $ac_subst_vars
1113 do
1114 eval ac_val=$`echo $ac_var`
1115 echo "$ac_var='"'"'$ac_val'"'"'"
1116 done | sort
1117 echo
1118
1119 if test -n "$ac_subst_files"; then
1120 cat <<\_ASBOX
1121## ------------- ##
1122## Output files. ##
1123## ------------- ##
1124_ASBOX
1125 echo
1126 for ac_var in $ac_subst_files
1127 do
1128 eval ac_val=$`echo $ac_var`
1129 echo "$ac_var='"'"'$ac_val'"'"'"
1130 done | sort
1131 echo
1132 fi
1133
c0d27fcc
MR
1134 if test -s confdefs.h; then
1135 cat <<\_ASBOX
1136## ----------- ##
1137## confdefs.h. ##
1138## ----------- ##
1139_ASBOX
1140 echo
6bae0ccf 1141 sed "/^$/d" confdefs.h | sort
c0d27fcc
MR
1142 echo
1143 fi
1144 test "$ac_signal" != 0 &&
1145 echo "$as_me: caught signal $ac_signal"
1146 echo "$as_me: exit $exit_status"
1147 } >&5
1148 rm -f core core.* *.core &&
1149 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
503d2be0
AS
1150 exit $exit_status
1151 ' 0
1152for ac_signal in 1 2 13 15; do
1153 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1154done
1155ac_signal=0
1156
1157# confdefs.h avoids OS command line length limits that DEFS can exceed.
1158rm -rf conftest* confdefs.h
1159# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1160echo >confdefs.h
ba4481b5 1161
c0d27fcc
MR
1162# Predefined preprocessor variables.
1163
1164cat >>confdefs.h <<_ACEOF
1165#define PACKAGE_NAME "$PACKAGE_NAME"
1166_ACEOF
1167
1168
1169cat >>confdefs.h <<_ACEOF
1170#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1171_ACEOF
1172
1173
1174cat >>confdefs.h <<_ACEOF
1175#define PACKAGE_VERSION "$PACKAGE_VERSION"
1176_ACEOF
1177
1178
1179cat >>confdefs.h <<_ACEOF
1180#define PACKAGE_STRING "$PACKAGE_STRING"
1181_ACEOF
1182
1183
1184cat >>confdefs.h <<_ACEOF
1185#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1186_ACEOF
1187
1188
503d2be0 1189# Let the site file select an alternate cache file if it wants to.
ba4481b5
DL
1190# Prefer explicitly selected file to automatically selected ones.
1191if test -z "$CONFIG_SITE"; then
1192 if test "x$prefix" != xNONE; then
1193 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1194 else
1195 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1196 fi
1197fi
1198for ac_site_file in $CONFIG_SITE; do
1199 if test -r "$ac_site_file"; then
c0d27fcc 1200 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
503d2be0 1201echo "$as_me: loading site script $ac_site_file" >&6;}
c0d27fcc 1202 sed 's/^/| /' "$ac_site_file" >&5
ba4481b5
DL
1203 . "$ac_site_file"
1204 fi
1205done
1206
1207if test -r "$cache_file"; then
503d2be0
AS
1208 # Some versions of bash will fail to source /dev/null (special
1209 # files actually), so we avoid doing that.
1210 if test -f "$cache_file"; then
c0d27fcc 1211 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
503d2be0
AS
1212echo "$as_me: loading cache $cache_file" >&6;}
1213 case $cache_file in
1214 [\\/]* | ?:[\\/]* ) . $cache_file;;
1215 *) . ./$cache_file;;
1216 esac
1217 fi
ba4481b5 1218else
c0d27fcc 1219 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
503d2be0
AS
1220echo "$as_me: creating cache $cache_file" >&6;}
1221 >$cache_file
1222fi
1223
1224# Check that the precious variables saved in the cache have kept the same
1225# value.
1226ac_cache_corrupted=false
1227for ac_var in `(set) 2>&1 |
1228 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1229 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1230 eval ac_new_set=\$ac_env_${ac_var}_set
1231 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1232 eval ac_new_val="\$ac_env_${ac_var}_value"
1233 case $ac_old_set,$ac_new_set in
1234 set,)
c0d27fcc 1235 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
503d2be0
AS
1236echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1237 ac_cache_corrupted=: ;;
1238 ,set)
c0d27fcc 1239 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
503d2be0
AS
1240echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1241 ac_cache_corrupted=: ;;
1242 ,);;
1243 *)
1244 if test "x$ac_old_val" != "x$ac_new_val"; then
c0d27fcc 1245 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
503d2be0 1246echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
c0d27fcc 1247 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
503d2be0 1248echo "$as_me: former value: $ac_old_val" >&2;}
c0d27fcc 1249 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
503d2be0
AS
1250echo "$as_me: current value: $ac_new_val" >&2;}
1251 ac_cache_corrupted=:
1252 fi;;
1253 esac
c0d27fcc 1254 # Pass precious variables to config.status.
503d2be0
AS
1255 if test "$ac_new_set" = set; then
1256 case $ac_new_val in
1257 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
c0d27fcc
MR
1258 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1259 *) ac_arg=$ac_var=$ac_new_val ;;
1260 esac
1261 case " $ac_configure_args " in
1262 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1263 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
503d2be0
AS
1264 esac
1265 fi
1266done
1267if $ac_cache_corrupted; then
c0d27fcc 1268 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
503d2be0 1269echo "$as_me: error: changes in the environment can compromise the build" >&2;}
c0d27fcc 1270 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
503d2be0
AS
1271echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1272 { (exit 1); exit 1; }; }
ba4481b5
DL
1273fi
1274
1275ac_ext=c
ba4481b5 1276ac_cpp='$CPP $CPPFLAGS'
503d2be0
AS
1277ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1278ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1279ac_compiler_gnu=$ac_cv_c_compiler_gnu
1280
c0d27fcc
MR
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
ba4481b5 1297
6bae0ccf
DL
1298
1299 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
ba4481b5 1300
c0d27fcc 1301
ba5da88a
PJ
1302test "$program_prefix" != NONE &&
1303 program_transform_name="s,^,$program_prefix,;$program_transform_name"
1304# Use a double $ so make ignores it.
1305test "$program_suffix" != NONE &&
1306 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1307# Double any \ or $. echo might interpret backslashes.
1308# By default was `s,x,x', remove it if useless.
1309cat <<\_ACEOF >conftest.sed
1310s/[\\$]/&&/g;s/;s,x,x,$//
1311_ACEOF
1312program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1313rm conftest.sed
1314
c0d27fcc 1315
ba4481b5
DL
1316lispdir='${datadir}/emacs/${version}/lisp'
1317locallisppath='${datadir}/emacs/${version}/site-lisp:'\
1318'${datadir}/emacs/site-lisp:${datadir}/emacs/${version}/leim'
1319lisppath='${locallisppath}:${lispdir}'
1320etcdir='${datadir}/emacs/${version}/etc'
1321archlibdir='${libexecdir}/emacs/${version}/${configuration}'
1322docdir='${datadir}/emacs/${version}/etc'
24b01ec4 1323gamedir='${localstatedir}/games/emacs'
98418dba
CW
1324
1325gameuser=games
1326
c0d27fcc 1327
ba4481b5
DL
1328# Check whether --with-gcc or --without-gcc was given.
1329if test "${with_gcc+set}" = set; then
1330 withval="$with_gcc"
503d2be0
AS
1331
1332fi;
ba4481b5
DL
1333
1334# Check whether --with-pop or --without-pop was given.
1335if test "${with_pop+set}" = set; then
1336 withval="$with_pop"
243cf185 1337 if test "$withval" = yes; then
c0d27fcc 1338 cat >>confdefs.h <<\_ACEOF
ba4481b5 1339#define MAIL_USE_POP 1
c0d27fcc 1340_ACEOF
ba4481b5 1341
243cf185
DL
1342else :
1343fi
3d9fec71 1344else
c0d27fcc 1345 cat >>confdefs.h <<\_ACEOF
3d9fec71 1346#define MAIL_USE_POP 1
c0d27fcc 1347_ACEOF
3d9fec71 1348
503d2be0 1349fi;
ba4481b5 1350
c0d27fcc 1351
a21616bd
KR
1352# Check whether --with-kerberos or --without-kerberos was given.
1353if test "${with_kerberos+set}" = set; then
1354 withval="$with_kerberos"
c0d27fcc 1355 cat >>confdefs.h <<\_ACEOF
a21616bd 1356#define KERBEROS 1
c0d27fcc 1357_ACEOF
a21616bd 1358
503d2be0 1359fi;
a21616bd 1360
c0d27fcc 1361
a21616bd
KR
1362# Check whether --with-kerberos5 or --without-kerberos5 was given.
1363if test "${with_kerberos5+set}" = set; then
1364 withval="$with_kerberos5"
1365 if test "${with_kerberos5+set}" = set; then
1366 if test "${with_kerberos+set}" != set; then
1367 with_kerberos=yes
c0d27fcc 1368 cat >>confdefs.h <<\_ACEOF
a21616bd 1369#define KERBEROS 1
c0d27fcc 1370_ACEOF
a21616bd
KR
1371
1372 fi
1373fi
b936fae4 1374
c0d27fcc 1375cat >>confdefs.h <<\_ACEOF
a21616bd 1376#define KERBEROS5 1
c0d27fcc 1377_ACEOF
a21616bd 1378
503d2be0 1379fi;
a21616bd 1380
ba4481b5
DL
1381# Check whether --with-hesiod or --without-hesiod was given.
1382if test "${with_hesiod+set}" = set; then
1383 withval="$with_hesiod"
b936fae4 1384
c0d27fcc 1385cat >>confdefs.h <<\_ACEOF
ba4481b5 1386#define HESIOD 1
c0d27fcc 1387_ACEOF
ba4481b5 1388
503d2be0 1389fi;
ba4481b5 1390
c0d27fcc 1391
2c9dccc9
PJ
1392# Check whether --with-sound or --without-sound was given.
1393if test "${with_sound+set}" = set; then
1394 withval="$with_sound"
1395
1396fi;
1397
c0d27fcc 1398
ba4481b5
DL
1399# Check whether --with-x-toolkit or --without-x-toolkit was given.
1400if test "${with_x_toolkit+set}" = set; then
1401 withval="$with_x_toolkit"
1402 case "${withval}" in
1403 y | ye | yes ) val=athena ;;
1404 n | no ) val=no ;;
1405 l | lu | luc | luci | lucid ) val=lucid ;;
1406 a | at | ath | athe | athen | athena ) val=athena ;;
1407 m | mo | mot | moti | motif ) val=motif ;;
488dd4c4 1408 g | gt | gtk ) val=gtk ;;
ba4481b5 1409 * )
c0d27fcc 1410{ { echo "$as_me:$LINENO: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1411this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1412Currently, \`yes', \`athena' and \`lucid' are synonyms." >&5
1413echo "$as_me: error: \`--with-x-toolkit=$withval' is invalid\;
488dd4c4 1414this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif' or \`gtk'.
503d2be0
AS
1415Currently, \`yes', \`athena' and \`lucid' are synonyms." >&2;}
1416 { (exit 1); exit 1; }; }
ba4481b5
DL
1417 ;;
1418 esac
1419 with_x_toolkit=$val
1420
503d2be0 1421fi;
ba4481b5
DL
1422
1423# Check whether --with-xpm or --without-xpm was given.
1424if test "${with_xpm+set}" = set; then
1425 withval="$with_xpm"
503d2be0
AS
1426
1427fi;
ba4481b5
DL
1428
1429# Check whether --with-jpeg or --without-jpeg was given.
1430if test "${with_jpeg+set}" = set; then
1431 withval="$with_jpeg"
503d2be0
AS
1432
1433fi;
ba4481b5
DL
1434
1435# Check whether --with-tiff or --without-tiff was given.
1436if test "${with_tiff+set}" = set; then
1437 withval="$with_tiff"
503d2be0
AS
1438
1439fi;
ba4481b5
DL
1440
1441# Check whether --with-gif or --without-gif was given.
1442if test "${with_gif+set}" = set; then
1443 withval="$with_gif"
503d2be0
AS
1444
1445fi;
ba4481b5
DL
1446
1447# Check whether --with-png or --without-png was given.
1448if test "${with_png+set}" = set; then
1449 withval="$with_png"
503d2be0
AS
1450
1451fi;
ba4481b5 1452
488dd4c4
JD
1453# Check whether --with-gtk or --without-gtk was given.
1454if test "${with_gtk+set}" = set; then
1455 withval="$with_gtk"
1456
1457fi;
1458
1459# Check whether --with-pkg-config-prog or --without-pkg-config-prog was given.
1460if test "${with_pkg_config_prog+set}" = set; then
1461 withval="$with_pkg_config_prog"
1462
1463fi;
1464
ba4481b5
DL
1465# Check whether --with-toolkit-scroll-bars or --without-toolkit-scroll-bars was given.
1466if test "${with_toolkit_scroll_bars+set}" = set; then
1467 withval="$with_toolkit_scroll_bars"
503d2be0
AS
1468
1469fi;
ba4481b5 1470
1d36487c
GM
1471# Check whether --with-xim or --without-xim was given.
1472if test "${with_xim+set}" = set; then
1473 withval="$with_xim"
1d36487c 1474
503d2be0 1475fi;
ba4481b5 1476
e0f712ba
AC
1477# Check whether --with-carbon or --without-carbon was given.
1478if test "${with_carbon+set}" = set; then
1479 withval="$with_carbon"
1480
1481fi;
6a3a24fa
JD
1482# Check whether --enable-carbon-app or --disable-carbon-app was given.
1483if test "${enable_carbon_app+set}" = set; then
1484 enableval="$enable_carbon_app"
1485 carbon_appdir_x=${enableval}
1486fi;
e0f712ba 1487
ba4481b5 1488#### Make srcdir absolute, if it isn't already. It's important to
17494071 1489#### avoid running the path through pwd unnecessarily, since pwd can
ba4481b5
DL
1490#### give you automounter prefixes, which can go away. We do all this
1491#### so Emacs can find its files when run uninstalled.
17494071
GM
1492## Make sure CDPATH doesn't affect cd (in case PWD is relative).
1493unset CDPATH
ba4481b5
DL
1494case "${srcdir}" in
1495 /* ) ;;
1496 . )
1497 ## We may be able to use the $PWD environment variable to make this
1498 ## absolute. But sometimes PWD is inaccurate.
df645f7c
AS
1499 ## Note: we used to use ${PWD} at the end instead of `pwd`,
1500 ## but that tested only for a well-formed and valid PWD,
1501 ## it did not object when PWD was well-formed and valid but just wrong.
1502 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
ba4481b5
DL
1503 then
1504 srcdir="$PWD"
1505 else
1506 srcdir="`(cd ${srcdir}; pwd)`"
1507 fi
1508 ;;
1509 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
1510esac
1511
1512#### Check if the source directory already has a configured system in it.
1513if test `pwd` != `(cd ${srcdir} && pwd)` \
1514 && test -f "${srcdir}/src/config.h" ; then
c0d27fcc 1515 { echo "$as_me:$LINENO: WARNING: The directory tree \`${srcdir}' is being used
503d2be0
AS
1516 as a build directory right now; it has been configured in its own
1517 right. To configure in another directory as well, you MUST
1518 use GNU make. If you do not have GNU make, then you must
1519 now do \`make distclean' in ${srcdir},
1520 and then run $0 again." >&5
1521echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
ba4481b5
DL
1522 as a build directory right now; it has been configured in its own
1523 right. To configure in another directory as well, you MUST
1524 use GNU make. If you do not have GNU make, then you must
1525 now do \`make distclean' in ${srcdir},
503d2be0 1526 and then run $0 again." >&2;}
ba4481b5 1527
22044edf 1528extrasub='/^VPATH[ ]*=/c\
ba4481b5
DL
1529vpath %.c $(srcdir)\
1530vpath %.h $(srcdir)\
1531vpath %.y $(srcdir)\
1532vpath %.l $(srcdir)\
1533vpath %.s $(srcdir)\
1534vpath %.in $(srcdir)\
1535vpath %.texi $(srcdir)'
1536fi
1537
1538#### Given the configuration name, set machfile and opsysfile to the
1539#### names of the m/*.h and s/*.h files we should use.
1540
1541### Canonicalize the configuration name.
1542
1543ac_aux_dir=
1544for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1545 if test -f $ac_dir/install-sh; then
1546 ac_aux_dir=$ac_dir
1547 ac_install_sh="$ac_aux_dir/install-sh -c"
1548 break
1549 elif test -f $ac_dir/install.sh; then
1550 ac_aux_dir=$ac_dir
1551 ac_install_sh="$ac_aux_dir/install.sh -c"
1552 break
503d2be0
AS
1553 elif test -f $ac_dir/shtool; then
1554 ac_aux_dir=$ac_dir
1555 ac_install_sh="$ac_aux_dir/shtool install -c"
1556 break
ba4481b5
DL
1557 fi
1558done
1559if test -z "$ac_aux_dir"; then
c0d27fcc 1560 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
503d2be0
AS
1561echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1562 { (exit 1); exit 1; }; }
ba4481b5 1563fi
503d2be0
AS
1564ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1565ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1566ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
ba4481b5
DL
1567
1568# Make sure we can run config.sub.
503d2be0 1569$ac_config_sub sun4 >/dev/null 2>&1 ||
c0d27fcc 1570 { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
503d2be0
AS
1571echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1572 { (exit 1); exit 1; }; }
1573
c0d27fcc 1574echo "$as_me:$LINENO: checking build system type" >&5
503d2be0
AS
1575echo $ECHO_N "checking build system type... $ECHO_C" >&6
1576if test "${ac_cv_build+set}" = set; then
1577 echo $ECHO_N "(cached) $ECHO_C" >&6
1578else
1579 ac_cv_build_alias=$build_alias
1580test -z "$ac_cv_build_alias" &&
1581 ac_cv_build_alias=`$ac_config_guess`
1582test -z "$ac_cv_build_alias" &&
c0d27fcc 1583 { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
503d2be0
AS
1584echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1585 { (exit 1); exit 1; }; }
1586ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
c0d27fcc
MR
1587 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1588echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
503d2be0
AS
1589 { (exit 1); exit 1; }; }
1590
1591fi
c0d27fcc 1592echo "$as_me:$LINENO: result: $ac_cv_build" >&5
503d2be0
AS
1593echo "${ECHO_T}$ac_cv_build" >&6
1594build=$ac_cv_build
1595build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1596build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1597build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1598
c0d27fcc
MR
1599
1600echo "$as_me:$LINENO: checking host system type" >&5
503d2be0
AS
1601echo $ECHO_N "checking host system type... $ECHO_C" >&6
1602if test "${ac_cv_host+set}" = set; then
1603 echo $ECHO_N "(cached) $ECHO_C" >&6
1604else
1605 ac_cv_host_alias=$host_alias
1606test -z "$ac_cv_host_alias" &&
1607 ac_cv_host_alias=$ac_cv_build_alias
1608ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
c0d27fcc 1609 { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
503d2be0
AS
1610echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1611 { (exit 1); exit 1; }; }
1612
1613fi
c0d27fcc 1614echo "$as_me:$LINENO: result: $ac_cv_host" >&5
503d2be0
AS
1615echo "${ECHO_T}$ac_cv_host" >&6
1616host=$ac_cv_host
1617host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1618host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1619host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
ba4481b5 1620
c0d27fcc 1621
ba4481b5 1622canonical=$host
531a3336 1623configuration=${host_alias-$host}
ba4481b5 1624
c0d27fcc 1625
22044edf 1626
ba4481b5
DL
1627### If you add support for a new configuration, add code to this
1628### switch statement to recognize your configuration name and select
1629### the appropriate operating system and machine description files.
1630
1631### You would hope that you could choose an m/*.h file pretty much
1632### based on the machine portion of the configuration name, and an s-
1633### file based on the operating system portion. However, it turns out
1634### that each m/*.h file is pretty manufacturer-specific - for
1635### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are
1636### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS
1637### machines. So we basically have to have a special case for each
1638### configuration name.
1639###
1640### As far as handling version numbers on operating systems is
1641### concerned, make sure things will fail in a fixable way. If
1642### /etc/MACHINES doesn't say anything about version numbers, be
1643### prepared to handle anything reasonably. If version numbers
1644### matter, be sure /etc/MACHINES says something about it.
1645###
1646### Eric Raymond says we should accept strings like "sysvr4" to mean
1647### "System V Release 4"; he writes, "The old convention encouraged
1648### confusion between `system' and `release' levels'."
1649
1650machine='' opsys='' unported=no
1651case "${canonical}" in
1652
1096bcc0
GM
1653 ## FreeBSD ports
1654 *-*-freebsd* )
1655 opsys=freebsd
1656 case "${canonical}" in
1657 alpha*-*-freebsd*) machine=alpha ;;
1658 i[3456]86-*-freebsd*) machine=intel386 ;;
1659 esac
1660 ;;
1661
ba4481b5
DL
1662 ## NetBSD ports
1663 *-*-netbsd* )
1664 opsys=netbsd
1665 case "${canonical}" in
1666 alpha*-*-netbsd*) machine=alpha ;;
1667 i[3456]86-*-netbsd*) machine=intel386 ;;
1668 m68k-*-netbsd*)
1669 # This is somewhat bogus.
1670 machine=hp9000s300 ;;
1671 powerpc-apple-netbsd*) machine=macppc ;;
1672 mips-*-netbsd*) machine=pmax ;;
2df636f4 1673 mipsel-*-netbsd*) machine=pmax ;;
97836269 1674 mipseb-*-netbsd*) machine=pmax ;;
ba4481b5 1675 ns32k-*-netbsd*) machine=ns32000 ;;
3a64eef5 1676 powerpc-*-netbsd*) machine=macppc ;;
71c9ec51 1677 sparc*-*-netbsd*) machine=sparc ;;
ba4481b5 1678 vax-*-netbsd*) machine=vax ;;
2df636f4 1679 arm-*-netbsd*) machine=arm ;;
ba4481b5
DL
1680 esac
1681 ;;
1682
1683 ## OpenBSD ports
1684 *-*-openbsd* )
1685 opsys=openbsd
1686 case "${canonical}" in
1687 alpha*-*-openbsd*) machine=alpha ;;
1688 i386-*-openbsd*) machine=intel386 ;;
1689 m68k-*-openbsd*) machine=hp9000s300 ;;
1690 mipsel-*-openbsd*) machine=pmax ;;
1691 ns32k-*-openbsd*) machine=ns32000 ;;
1692 sparc-*-openbsd*) machine=sparc ;;
1693 vax-*-openbsd*) machine=vax ;;
1694 esac
1695 ;;
1696
1697 ## Acorn RISCiX:
1698 arm-acorn-riscix1.1* )
1699 machine=acorn opsys=riscix1-1
1700 ;;
1701 arm-acorn-riscix1.2* | arm-acorn-riscix )
1702 ## This name is riscix12 instead of riscix1.2
1703 ## to avoid a file name conflict on MSDOS.
1704 machine=acorn opsys=riscix12
1705 ;;
1706
1707 ## BSDI ports
1708 *-*-bsdi* )
1709 opsys=bsdi
1710 case "${canonical}" in
1711 i[345]86-*-bsdi*) machine=intel386 ;;
1712 sparc-*-bsdi*) machine=sparc ;;
3aeecf97 1713 powerpc-*-bsdi*) machine=macppc ;;
ba4481b5
DL
1714 esac
1715 case "${canonical}" in
1716 *-*-bsd386* | *-*-bsdi1* ) opsys=bsd386 ;;
1717 *-*-bsdi2.0* ) opsys=bsdos2 ;;
1718 *-*-bsdi2* ) opsys=bsdos2-1 ;;
1719 *-*-bsdi3* ) opsys=bsdos3 ;;
1d06fc82 1720 *-*-bsdi[45]* ) opsys=bsdos4 ;;
ba4481b5
DL
1721 esac
1722 ;;
1723
1724 ## Alliant machines
1725 ## Strictly speaking, we need the version of the alliant operating
1726 ## system to choose the right machine file, but currently the
1727 ## configuration name doesn't tell us enough to choose the right
1728 ## one; we need to give alliants their own operating system name to
1729 ## do this right. When someone cares, they can help us.
1730 fx80-alliant-* )
1731 machine=alliant4 opsys=bsd4-2
1732 ;;
1733 i860-alliant-* )
1734 machine=alliant-2800 opsys=bsd4-3
1735 ;;
1736
1737 ## Alpha (DEC) machines.
1738 alpha*-dec-osf* )
1739 machine=alpha opsys=osf1
1740 # This is needed to find X11R6.1 libraries for certain tests.
1741 NON_GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
1742 GCC_LINK_TEST_OPTIONS=-Wl,-rpath,/usr/X11R6/lib
34979055
DL
1743 # NON_GNU_CPP is necessary on 5.0 to avoid mangling src/Makefile
1744 # due to non-traditional preprocessing with the current compiler
1745 # defaults. OSF 4 can also have that compiler version, and there
1746 # seems always to have been a usable /usr/bin/cpp.
1747 NON_GNU_CPP=/usr/bin/cpp
ca512671 1748 case "${canonical}" in
a55b799a 1749 alpha*-dec-osf[5-9]*)
bb17930d 1750 opsys=osf5-0 ;;
ca512671 1751 esac
ba4481b5
DL
1752 ;;
1753
1754 alpha*-*-linux-gnu* )
1755 machine=alpha opsys=gnu-linux
1756 ;;
1757
c4bb2108
DL
1758 arm*-*-linux-gnu* )
1759 machine=arm opsys=gnu-linux
1760 ;;
1761
1762 ppc-*-linux | \
1763 powerpc-*-linux* )
3aeecf97 1764 machine=macppc opsys=gnu-linux
c4bb2108
DL
1765 ;;
1766
ba4481b5
DL
1767 ## Altos 3068
1768 m68*-altos-sysv* )
1769 machine=altos opsys=usg5-2
1770 ;;
1771
1772 ## Amdahl UTS
1773 580-amdahl-sysv* )
1774 machine=amdahl opsys=usg5-2-2
1775 ;;
1776
1777 ## Apollo, Domain/OS
1778 m68*-apollo-* )
1779 machine=apollo opsys=bsd4-3
1780 ;;
1781
1782 ## AT&T 3b2, 3b5, 3b15, 3b20
1783 we32k-att-sysv* )
1784 machine=att3b opsys=usg5-2-2
1785 ;;
1786
1787 ## AT&T 3b1 - The Mighty Unix PC!
1788 m68*-att-sysv* )
1789 machine=7300 opsys=usg5-2-2
1790 ;;
1791
1792 ## Bull dpx20
1793 rs6000-bull-bosx* )
1794 machine=ibmrs6000 opsys=aix3-2
1795 ;;
1796
1797 ## Bull dpx2
1798 m68*-bull-sysv3* )
1799 machine=dpx2 opsys=usg5-3
1800 ;;
1801
1802 ## Bull sps7
1803 m68*-bull-sysv2* )
1804 machine=sps7 opsys=usg5-2
1805 ;;
1806
1807 ## CCI 5/32, 6/32 -- see "Tahoe".
1808
1809 ## Celerity
1810 ## I don't know what configuration name to use for this; config.sub
1811 ## doesn't seem to know anything about it. Hey, Celerity users, get
1812 ## in touch with us!
1813 celerity-celerity-bsd* )
1814 machine=celerity opsys=bsd4-2
1815 ;;
1816
1817 ## Clipper
1818 ## What operating systems does this chip run that Emacs has been
1819 ## tested on?
1820 clipper-* )
1821 machine=clipper
1822 ## We'll use the catch-all code at the bottom to guess the
1823 ## operating system.
1824 ;;
1825
df645f7c
AS
1826 ## Compaq Nonstop
1827 mips-compaq-nonstopux* )
1828 machine=nonstopux opsys=nonstopux
1829 ;;
1830
ba4481b5
DL
1831 ## Convex
1832 *-convex-bsd* | *-convex-convexos* )
1833 machine=convex opsys=bsd4-3
1834 ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov
1835 NON_GNU_CPP="cc -E -P"
1836 ;;
1837
1838 ## Cubix QBx/386
1839 i[3456]86-cubix-sysv* )
1840 machine=intel386 opsys=usg5-3
1841 ;;
1842
1843 ## Cydra 5
1844 cydra*-cydrome-sysv* )
1845 machine=cydra5 opsys=usg5-3
1846 ;;
1847
1848 ## Data General AViiON Machines
1849 ## DG changed naming conventions with the release of 5.4.4.10, they
1850 ## dropped the initial 5.4 but left the intervening R. Because of the
1851 ## R this shouldn't conflict with older versions of the OS (which I
1852 ## think were named like dgux4.*). In addition, DG new AViiONs series
1853 ## uses either Motorola M88k or Intel Pentium CPUs.
1854 m88k-dg-dguxR4.* | m88k-dg-dgux4* )
1855 machine=aviion opsys=dgux4
1856 ;;
1857 m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* )
1858 ## This name is dgux5-4-3 instead of dgux5-4r3
1859 ## to avoid a file name conflict on MSDOS.
1860 machine=aviion opsys=dgux5-4-3
1861 ;;
1862 m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* )
1863 machine=aviion opsys=dgux5-4r2
1864 ;;
1865 m88k-dg-dgux* )
1866 machine=aviion opsys=dgux
1867 ;;
1868
1869 ## Data General AViiON Intel (x86) Machines
1870 ## Exists from 5.4.3 (current i586-dg-dguxR4.11)
1871 ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il
1872 i[345]86-dg-dguxR4* )
1873 machine=aviion-intel opsys=dgux4
1874 ;;
1875
1876 ## DECstations
1877 mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* )
1878 machine=pmax opsys=bsd4-2
1879 ;;
1880 mips-dec-ultrix4.[12]* | mips-dec-bsd* )
1881 machine=pmax opsys=bsd4-3
1882 ;;
1883 mips-dec-ultrix* )
1884 machine=pmax opsys=ultrix4-3
1885 ;;
1886 mips-dec-osf* )
1887 machine=pmax opsys=osf1
1888 ;;
1889 mips-dec-mach_bsd4.3* )
1890 machine=pmax opsys=mach-bsd4-3
1891 ;;
1892
cd890796
JD
1893 ## Motorola Delta machines
1894 m68k-motorola-sysv* | m68000-motorola-sysv* )
1895 machine=delta opsys=usg5-3
1896 if test -z "`type gnucc | grep 'not found'`"
1897 then
1898 if test -s /etc/167config
1899 then CC="gnucc -m68040"
1900 else CC="gnucc -m68881"
1901 fi
1902 else
1903 if test -z "`type gcc | grep 'not found'`"
1904 then CC=gcc
1905 else CC=cc
1906 fi
1907 fi
1908 ;;
ba4481b5
DL
1909 m88k-motorola-sysv4* )
1910 # jbotte@bnr.ca says that UNIX_System_V <hostName> 4.0 R40V4.3 m88k mc88110
1911 # needs POSIX_SIGNALS and therefore needs usg5-4-2.
1912 # I hope there are not other 4.0 versions for this machine
1913 # which really need usg5-4 instead.
1914 machine=delta88k opsys=usg5-4-2
1915 ;;
1916 m88k-motorola-sysv* | m88k-motorola-m88kbcs* )
1917 machine=delta88k opsys=usg5-3
1918 ;;
1919
1920 ## Dual machines
1921 m68*-dual-sysv* )
1922 machine=dual opsys=usg5-2
1923 ;;
1924 m68*-dual-uniplus* )
1925 machine=dual opsys=unipl5-2
1926 ;;
1927
1928 ## Elxsi 6400
1929 elxsi-elxsi-sysv* )
1930 machine=elxsi opsys=usg5-2
1931 ;;
1932
1933 ## Encore machines
1934 ns16k-encore-bsd* )
1935 machine=ns16000 opsys=umax
1936 ;;
1937
65171e3a
DL
1938 ## The GEC 63 - apparently, this port isn't really finished yet.
1939 # I'm sure we finished off the last of the machines, though. -- fx
ba4481b5
DL
1940
1941 ## Gould Power Node and NP1
1942 pn-gould-bsd4.2* )
1943 machine=gould opsys=bsd4-2
1944 ;;
1945 pn-gould-bsd4.3* )
1946 machine=gould opsys=bsd4-3
1947 ;;
1948 np1-gould-bsd* )
1949 machine=gould-np1 opsys=bsd4-3
1950 ;;
1951
1952 ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000
1953 ## as far as Emacs is concerned).
1954 m88k-harris-cxux* )
1955 # Build needs to be different on 7.0 and later releases
1956 case "`uname -r`" in
1957 [56].[0-9] ) machine=nh4000 opsys=cxux ;;
1958 [7].[0-9] ) machine=nh4000 opsys=cxux7 ;;
1959 esac
1960 NON_GNU_CPP="/lib/cpp"
1961 ;;
1962 ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000)
1963 m68k-harris-cxux* )
1964 machine=nh3000 opsys=cxux
1965 ;;
1966 ## Harris power pc NightHawk running Power UNIX (Series 6000)
1967 powerpc-harris-powerunix )
1968 machine=nh6000 opsys=powerunix
1969 NON_GNU_CPP="cc -Xo -E -P"
1970 ;;
1971 ## SR2001/SR2201 running HI-UX/MPP
1972 hppa1.1-hitachi-hiuxmpp* )
1973 machine=sr2k opsys=hiuxmpp
1974 ;;
89a336fa
GM
1975 hppa1.1-hitachi-hiuxwe2* )
1976 machine=sr2k opsys=hiuxwe2
1977 ;;
ba4481b5
DL
1978 ## Honeywell XPS100
1979 xps*-honeywell-sysv* )
1980 machine=xps100 opsys=usg5-2
1981 ;;
1982
1983 ## HP 9000 series 200 or 300
1984 m68*-hp-bsd* )
1985 machine=hp9000s300 opsys=bsd4-3
1986 ;;
1987 ## HP/UX 7, 8, 9, and 10 are supported on these machines.
1988 m68*-hp-hpux* )
1989 case "`uname -r`" in
1990 ## Someone's system reports A.B8.05 for this.
1991 ## I wonder what other possibilities there are.
1992 *.B8.* ) machine=hp9000s300 opsys=hpux8 ;;
1993 *.08.* ) machine=hp9000s300 opsys=hpux8 ;;
1994 *.09.* ) machine=hp9000s300 opsys=hpux9 ;;
1995 *.1[0-9].* ) machine=hp9000s300 opsys=hpux9shr ;;
1996 *) machine=hp9000s300 opsys=hpux ;;
1997 esac
1998 ;;
1999
2000 ## HP 9000 series 700 and 800, running HP/UX
2001 hppa*-hp-hpux7* )
2002 machine=hp800 opsys=hpux
2003 ;;
2004 hppa*-hp-hpux8* )
2005 machine=hp800 opsys=hpux8
2006 ;;
2007 hppa*-hp-hpux9shr* )
2008 machine=hp800 opsys=hpux9shr
2009 ;;
2010 hppa*-hp-hpux9* )
2011 machine=hp800 opsys=hpux9
2012 ;;
b0e44248
RB
2013 hppa*-hp-hpux10.2* )
2014 machine=hp800 opsys=hpux10-20
2015 ;;
cc227489 2016 hppa*-hp-hpux10* )
ba4481b5
DL
2017 machine=hp800 opsys=hpux10
2018 ;;
cc227489
MB
2019 hppa*-hp-hpux1[1-9]* )
2020 machine=hp800 opsys=hpux11
2021 ;;
ba4481b5 2022
409d9577
GM
2023 hppa*-*-linux-gnu* )
2024 machine=hp800 opsys=gnu-linux
2025 ;;
2026
ba4481b5
DL
2027 ## HP 9000 series 700 and 800, running HP/UX
2028 hppa*-hp-hpux* )
2029 ## Cross-compilation? Nah!
2030 case "`uname -r`" in
2031 ## Someone's system reports A.B8.05 for this.
2032 ## I wonder what other possibilities there are.
2033 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2034 *.08.* ) machine=hp800 opsys=hpux8 ;;
2035 *.09.* ) machine=hp800 opsys=hpux9 ;;
2036 *) machine=hp800 opsys=hpux10 ;;
2037 esac
2038 ;;
2039 hppa*-*-nextstep* )
2040 machine=hp800 opsys=nextstep
2041 ;;
2042
2043 ## Orion machines
2044 orion-orion-bsd* )
2045 machine=orion opsys=bsd4-2
2046 ;;
2047 clipper-orion-bsd* )
2048 machine=orion105 opsys=bsd4-2
2049 ;;
2050
2051 ## IBM machines
2052 i[3456]86-ibm-aix1.1* )
2053 machine=ibmps2-aix opsys=usg5-2-2
2054 ;;
2055 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2056 machine=ibmps2-aix opsys=usg5-3
2057 ;;
2058 i370-ibm-aix*)
2059 machine=ibm370aix opsys=usg5-3
2060 ;;
138f0859
GM
2061 s390-*-linux-gnu)
2062 machine=ibms390 opsys=gnu-linux
2063 ;;
ba4481b5
DL
2064 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2065 machine=ibmrs6000 opsys=aix3-1
2066 ;;
2067 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2068 machine=ibmrs6000 opsys=aix3-2-5
2069 ;;
2070 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2071 machine=ibmrs6000 opsys=aix4-1
2072 ;;
2073 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2074 machine=ibmrs6000 opsys=aix4-2
2075 ;;
d6b82250
EZ
2076 rs6000-ibm-aix5.1* | powerpc-ibm-aix5.1* )
2077 machine=ibmrs6000 opsys=aix4-2
2078 ;;
ba4481b5
DL
2079 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2080 machine=ibmrs6000 opsys=aix4
2081 ;;
2082 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2083 machine=ibmrs6000 opsys=aix4-1
2084 ;;
2085 rs6000-ibm-aix* | powerpc-ibm-aix* )
2086 machine=ibmrs6000 opsys=aix3-2
2087 ;;
2088 romp-ibm-bsd4.3* )
2089 machine=ibmrt opsys=bsd4-3
2090 ;;
2091 romp-ibm-bsd4.2* )
2092 machine=ibmrt opsys=bsd4-2
2093 ;;
2094 romp-ibm-aos4.3* )
2095 machine=ibmrt opsys=bsd4-3
2096 ;;
2097 romp-ibm-aos4.2* )
2098 machine=ibmrt opsys=bsd4-2
2099 ;;
2100 romp-ibm-aos* )
2101 machine=ibmrt opsys=bsd4-3
2102 ;;
2103 romp-ibm-bsd* )
2104 machine=ibmrt opsys=bsd4-3
2105 ;;
2106 romp-ibm-aix* )
2107 machine=ibmrt-aix opsys=usg5-2-2
2108 ;;
2109
2110 ## Integrated Solutions `Optimum V'
2111 m68*-isi-bsd4.2* )
2112 machine=isi-ov opsys=bsd4-2
2113 ;;
2114 m68*-isi-bsd4.3* )
2115 machine=isi-ov opsys=bsd4-3
2116 ;;
2117
2118 ## Intel 386 machines where we do care about the manufacturer
2119 i[3456]86-intsys-sysv* )
2120 machine=is386 opsys=usg5-2-2
2121 ;;
2122
2123 ## Prime EXL
2124 i[3456]86-prime-sysv* )
2125 machine=i386 opsys=usg5-3
2126 ;;
2127
2128 ## Sequent Symmetry running Dynix
2129 i[3456]86-sequent-bsd* )
2130 machine=symmetry opsys=bsd4-3
2131 ;;
2132
2133 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2134 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2135 machine=sequent-ptx opsys=ptx4
2136 NON_GNU_CPP=/lib/cpp
2137 ;;
2138
2139 ## Sequent Symmetry running DYNIX/ptx
2140 ## Use the old cpp rather than the newer ANSI one.
2141 i[3456]86-sequent-ptx* )
2142 machine=sequent-ptx opsys=ptx
2143 NON_GNU_CPP="/lib/cpp"
2144 ;;
2145
2146 ## ncr machine running svr4.3.
2147 i[3456]86-ncr-sysv4.3 )
2148 machine=ncr386 opsys=usg5-4-3
2149 ;;
2150
2151 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2152 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2153 i[3456]86-ncr-sysv* )
2154 machine=ncr386 opsys=usg5-4-2
2155 ;;
2156
2157 ## Intel Paragon OSF/1
2158 i860-intel-osf1* )
2159 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2160 ;;
2161
2162 ## Intel 860
2163 i860-*-sysv4* )
2164 machine=i860 opsys=usg5-4
2165 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2166 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2167 ;;
2168
c76e04a8
GM
2169 ## Macintosh PowerPC
2170 powerpc*-*-linux-gnu* )
2171 machine=macppc opsys=gnu-linux
2172 ;;
2173
ba4481b5
DL
2174 ## Masscomp machines
2175 m68*-masscomp-rtu* )
2176 machine=masscomp opsys=rtu
2177 ;;
2178
2179 ## Megatest machines
2180 m68*-megatest-bsd* )
2181 machine=mega68 opsys=bsd4-2
2182 ;;
2183
2184 ## Workstations sold by MIPS
2185 ## This is not necessarily all workstations using the MIPS processor -
2186 ## Irises are produced by SGI, and DECstations by DEC.
2187
2188 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2189 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2190 ## it gives for choosing between the alternatives seems to be "Use
2191 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2192 ## the BSD world." I'll assume that these are instructions for
2193 ## handling two odd situations, and that every other situation
2194 ## should use mips.h and usg5-2-2, they being listed first.
2195 mips-mips-usg* )
2196 machine=mips4
2197 ## Fall through to the general code at the bottom to decide on the OS.
2198 ;;
2199 mips-mips-riscos4* )
2200 machine=mips4 opsys=bsd4-3
2201 NON_GNU_CC="cc -systype bsd43"
2202 NON_GNU_CPP="cc -systype bsd43 -E"
2203 ;;
2204 mips-mips-riscos5* )
2205 machine=mips4 opsys=riscos5
2206 NON_GNU_CC="cc -systype bsd43"
2207 NON_GNU_CPP="cc -systype bsd43 -E"
2208 ;;
2209 mips-mips-bsd* )
2210 machine=mips opsys=bsd4-3
2211 ;;
2212 mips-mips-* )
2213 machine=mips opsys=usg5-2-2
2214 ;;
2215
2216 ## NeXT
2217 m68*-next-* | m68k-*-nextstep* )
2218 machine=m68k opsys=nextstep
2219 ;;
2220
2221 ## The complete machine from National Semiconductor
2222 ns32k-ns-genix* )
2223 machine=ns32000 opsys=usg5-2
2224 ;;
2225
2226 ## NCR machines
2227 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2228 machine=tower32 opsys=usg5-2-2
2229 ;;
2230 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2231 machine=tower32v3 opsys=usg5-3
2232 ;;
2233
2234 ## NEC EWS4800
2235 mips-nec-sysv4*)
2236 machine=ews4800 opsys=ux4800
2237 ;;
2238
2239 ## Nixdorf Targon 31
2240 m68*-nixdorf-sysv* )
2241 machine=targon31 opsys=usg5-2-2
2242 ;;
2243
2244 ## Nu (TI or LMI)
2245 m68*-nu-sysv* )
2246 machine=nu opsys=usg5-2
2247 ;;
2248
2249 ## Plexus
2250 m68*-plexus-sysv* )
2251 machine=plexus opsys=usg5-2
2252 ;;
2253
ba4481b5
DL
2254 ## Pyramid machines
2255 ## I don't really have any idea what sort of processor the Pyramid has,
2256 ## so I'm assuming it is its own architecture.
2257 pyramid-pyramid-bsd* )
2258 machine=pyramid opsys=bsd4-2
2259 ;;
2260
2261 ## Sequent Balance
2262 ns32k-sequent-bsd4.2* )
2263 machine=sequent opsys=bsd4-2
2264 ;;
2265 ns32k-sequent-bsd4.3* )
2266 machine=sequent opsys=bsd4-3
2267 ;;
2268
2269 ## Siemens Nixdorf
2270 mips-siemens-sysv* | mips-sni-sysv*)
2271 machine=mips-siemens opsys=usg5-4
2272 NON_GNU_CC=/usr/ccs/bin/cc
2273 NON_GNU_CPP=/usr/ccs/lib/cpp
2274 ;;
2275
2276 ## Silicon Graphics machines
2277 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2278 m68*-sgi-iris3.5* )
2279 machine=irist opsys=iris3-5
2280 ;;
2281 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2282 machine=irist opsys=iris3-6
2283 ;;
2284 ## Iris 4D
2285 mips-sgi-irix3* )
2286 machine=iris4d opsys=irix3-3
2287 ;;
2288 mips-sgi-irix4* )
2289 machine=iris4d opsys=irix4-0
2290 ;;
2291 mips-sgi-irix6.5 )
2292 machine=iris4d opsys=irix6-5
946173ad
DL
2293 # Without defining _LANGUAGE_C, things get masked out in the headers
2294 # so that, for instance, grepping for `free' in stdlib.h fails and
2295 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2296 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2297 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2298 ;;
2299 mips-sgi-irix6* )
2300 machine=iris4d opsys=irix6-0
c4bb2108 2301 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2302 # but presumably it does no harm.
2303 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2304 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2305 NON_GCC_TEST_OPTIONS=-32
2306 ;;
2307 mips-sgi-irix5.[01]* )
2308 machine=iris4d opsys=irix5-0
2309 ;;
2310 mips-sgi-irix5* | mips-sgi-irix* )
2311 machine=iris4d opsys=irix5-2
2312 ;;
2313
2314 ## SONY machines
2315 m68*-sony-bsd4.2* )
2316 machine=news opsys=bsd4-2
2317 ;;
2318 m68*-sony-bsd4.3* )
2319 machine=news opsys=bsd4-3
2320 ;;
2321 m68*-sony-newsos3* | m68*-sony-news3*)
2322 machine=news opsys=bsd4-3
2323 ;;
2324 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2325 machine=news-risc opsys=bsd4-3
2326 ;;
2327 mips-sony-newsos6* )
2328 machine=news-r6 opsys=newsos6
2329 ;;
2330 mips-sony-news* )
2331 machine=news-risc opsys=newsos5
2332 ;;
2333
2334 ## Stride
2335 m68*-stride-sysv* )
2336 machine=stride opsys=usg5-2
2337 ;;
2338
2339 ## Suns
2340 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2341 machine=sparc opsys=gnu-linux
2342 ;;
2343
d054101f 2344 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2345 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2346 | rs6000-*-solaris2*)
2347 case "${canonical}" in
2348 m68*-sunos1* ) machine=sun1 ;;
2349 m68*-sunos2* ) machine=sun2 ;;
2350 m68* ) machine=sun3 ;;
2351 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2352 i[3456]86-*-* ) machine=intel386 ;;
2353 powerpcle* ) machine=powerpcle ;;
2354 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2355 sparc* ) machine=sparc ;;
2356 * ) unported=yes ;;
2357 esac
2358 case "${canonical}" in
2359 ## The Sun386 didn't get past 4.0.
2360 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2361 *-sunos4.0* ) opsys=sunos4-0 ;;
2362 *-sunos4.1.[3-9]*noshare )
2363 ## This name is sunos413 instead of sunos4-1-3
2364 ## to avoid a file name conflict on MSDOS.
2365 opsys=sunos413
2366 NON_GNU_CPP=/usr/lib/cpp
2367 NON_GCC_TEST_OPTIONS=-Bstatic
2368 GCC_TEST_OPTIONS=-static
2369 ;;
2370 *-sunos4.1.[3-9]* | *-sunos4shr*)
2371 opsys=sunos4shr
2372 NON_GNU_CPP=/usr/lib/cpp
2373 ;;
2374 *-sunos4* | *-sunos )
2375 opsys=sunos4-1
2376 NON_GCC_TEST_OPTIONS=-Bstatic
2377 GCC_TEST_OPTIONS=-static
2378 ;;
2379 *-sunos5.3* | *-solaris2.3* )
2380 opsys=sol2-3
2381 NON_GNU_CPP=/usr/ccs/lib/cpp
2382 ;;
2383 *-sunos5.4* | *-solaris2.4* )
2384 opsys=sol2-4
2385 NON_GNU_CPP=/usr/ccs/lib/cpp
2386 RANLIB="ar -ts"
2387 ;;
2388 *-sunos5.5* | *-solaris2.5* )
2389 opsys=sol2-5
2390 NON_GNU_CPP=/usr/ccs/lib/cpp
2391 RANLIB="ar -ts"
2392 ;;
8e967cf7
MR
2393 *-sunos5.6* | *-solaris2.6* )
2394 opsys=sol2-6
2395 NON_GNU_CPP=/usr/ccs/lib/cpp
2396 RANLIB="ar -ts"
2397 ;;
ba4481b5 2398 *-sunos5* | *-solaris* )
9e71690e 2399 opsys=sol2-6
ba4481b5
DL
2400 NON_GNU_CPP=/usr/ccs/lib/cpp
2401 ;;
2402 * ) opsys=bsd4-2 ;;
2403 esac
2404 ## Watch out for a compiler that we know will not work.
2405 case "${canonical}" in
2406 *-solaris* | *-sunos5* )
2407 if [ "x$CC" = x/usr/ucb/cc ]; then
2408 ## /usr/ucb/cc doesn't work;
2409 ## we should find some other compiler that does work.
2410 unset CC
2411 fi
2412 ;;
2413 *) ;;
2414 esac
2415 ;;
2416 sparc-*-nextstep* )
2417 machine=sparc opsys=nextstep
2418 ;;
2419
2420 ## Tadpole 68k
2421 m68*-tadpole-sysv* )
2422 machine=tad68k opsys=usg5-3
2423 ;;
2424
2425 ## Tahoe machines
2426 tahoe-tahoe-bsd4.2* )
2427 machine=tahoe opsys=bsd4-2
2428 ;;
2429 tahoe-tahoe-bsd4.3* )
2430 machine=tahoe opsys=bsd4-3
2431 ;;
2432
2433 ## Tandem Integrity S2
2434 mips-tandem-sysv* )
2435 machine=tandem-s2 opsys=usg5-3
2436 ;;
2437
2438 ## Tektronix XD88
2439 m88k-tektronix-sysv3* )
2440 machine=tekxd88 opsys=usg5-3
2441 ;;
2442
2443 ## Tektronix 16000 box (6130?)
2444 ns16k-tektronix-bsd* )
2445 machine=ns16000 opsys=bsd4-2
2446 ;;
2447 ## Tektronix 4300
2448 ## src/m/tek4300.h hints that this is a m68k machine.
2449 m68*-tektronix-bsd* )
2450 machine=tek4300 opsys=bsd4-3
2451 ;;
2452
2453 ## Titan P2 or P3
2454 ## We seem to have lost the machine-description file titan.h!
2455 titan-titan-sysv* )
2456 machine=titan opsys=usg5-3
2457 ;;
2458
2459 ## Ustation E30 (SS5E)
2460 m68*-unisys-uniplus* )
2461 machine=ustation opsystem=unipl5-2
2462 ;;
2463
2464 ## Vaxen.
2465 vax-dec-* )
2466 machine=vax
2467 case "${canonical}" in
2468 *-bsd4.1* ) opsys=bsd4-1 ;;
2469 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2470 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2471 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2472 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2473 *-vms* ) opsys=vms ;;
2474 * ) unported=yes
2475 esac
2476 ;;
2477
2478 ## Whitechapel MG1
2479 ns16k-whitechapel-* )
2480 machine=mg1
2481 ## We don't know what sort of OS runs on these; we'll let the
2482 ## operating system guessing code below try.
2483 ;;
2484
2485 ## Wicat
2486 m68*-wicat-sysv* )
2487 machine=wicat opsys=usg5-2
2488 ;;
2489
f4988be7
GM
2490 ## IA-64
2491 ia64*-*-linux* )
2492 machine=ia64 opsys=gnu-linux
2493 ;;
2494
ba4481b5
DL
2495 ## Intel 386 machines where we don't care about the manufacturer
2496 i[3456]86-*-* )
2497 machine=intel386
2498 case "${canonical}" in
c60ee5e7 2499 *-cygwin ) opsys=cygwin ;;
9f817ea4 2500 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2501 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2502 *-isc2.2* ) opsys=isc2-2 ;;
2503 *-isc4.0* ) opsys=isc4-0 ;;
2504 *-isc4.* ) opsys=isc4-1
2505 GCC_TEST_OPTIONS=-posix
2506 NON_GCC_TEST_OPTIONS=-Xp
2507 ;;
2508 *-isc* ) opsys=isc3-0 ;;
2509 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2510 *-esix* ) opsys=esix ;;
2511 *-xenix* ) opsys=xenix ;;
2512 *-linux-gnu* ) opsys=gnu-linux ;;
2513 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2514 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2515 NON_GNU_CPP=/lib/cpp
2516 # Prevent -belf from being passed to $CPP.
2517 # /lib/cpp does not accept it.
2518 OVERRIDE_CPPFLAGS=" "
2519 ;;
2520 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2521 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2522 *-nextstep* ) opsys=nextstep ;;
2523 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2524 esac
2525 ;;
2526
2527 ## m68k Linux-based GNU system
2528 m68k-*-linux-gnu* )
2529 machine=m68k opsys=gnu-linux
2530 ;;
2531
2532 ## Mips Linux-based GNU system
cd958eb3 2533 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2534 machine=mips opsys=gnu-linux
2535 ;;
2536
2537 ## UXP/DS
2538 sparc-fujitsu-sysv4* )
2539 machine=sparc opsys=uxpds
2540 NON_GNU_CPP=/usr/ccs/lib/cpp
2541 RANLIB="ar -ts"
2542 ;;
2543
2544 ## UXP/V
2545 f301-fujitsu-uxpv4.1)
2546 machine=f301 opsys=uxpv
2547 ;;
2548
e0f712ba
AC
2549 ## Darwin / Mac OS X
2550 powerpc-apple-darwin* )
2551 machine=powermac opsys=darwin
2552 # Define CPP as follows to make autoconf work correctly.
2553 CPP="cc -E -traditional-cpp"
2554 ;;
2555
598a2813
AS
2556 ## AMD x86-64 Linux-based GNU system
2557 x86_64-*-linux-gnu* )
24b01ec4 2558 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2559 ;;
2560
ba4481b5
DL
2561 * )
2562 unported=yes
2563 ;;
2564esac
2565
2566### If the code above didn't choose an operating system, just choose
2567### an operating system based on the configuration name. You really
2568### only want to use this when you have no idea what the right
2569### operating system is; if you know what operating systems a machine
2570### runs, it's cleaner to make it explicit in the case statement
2571### above.
2572if test x"${opsys}" = x; then
2573 case "${canonical}" in
2574 *-gnu* ) opsys=gnu ;;
2575 *-bsd4.[01] ) opsys=bsd4-1 ;;
2576 *-bsd4.2 ) opsys=bsd4-2 ;;
2577 *-bsd4.3 ) opsys=bsd4-3 ;;
2578 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2579 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2580 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2581 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2582 *-sysv4.2uw* ) opsys=unixware ;;
2583 *-sysv4.1* | *-sysvr4.1* )
2584 NON_GNU_CPP=/usr/lib/cpp
2585 opsys=usg5-4 ;;
2586 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2587 if [ x$NON_GNU_CPP = x ]; then
2588 if [ -f /usr/ccs/lib/cpp ]; then
2589 NON_GNU_CPP=/usr/ccs/lib/cpp
2590 else
2591 NON_GNU_CPP=/lib/cpp
2592 fi
2593 fi
2594 opsys=usg5-4-2 ;;
2595 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2596 * )
2597 unported=yes
2598 ;;
2599 esac
2600fi
2601
c0d27fcc 2602
22044edf 2603
ba4481b5 2604if test $unported = yes; then
c0d27fcc 2605 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2606Check \`etc/MACHINES' for recognized configuration names." >&5
2607echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2608Check \`etc/MACHINES' for recognized configuration names." >&2;}
2609 { (exit 1); exit 1; }; }
ba4481b5
DL
2610fi
2611
2612machfile="m/${machine}.h"
2613opsysfile="s/${opsys}.h"
2614
c0d27fcc 2615
ba4481b5
DL
2616#### Choose a compiler.
2617test -n "$CC" && cc_specified=yes
2618
2619# Save the value of CFLAGS that the user specified.
2620SPECIFIED_CFLAGS="$CFLAGS"
2621
2622case ${with_gcc} in
2623 "yes" ) CC="gcc" GCC=yes ;;
2624 "no" ) : ${CC=cc} ;;
503d2be0
AS
2625 * )
2626esac
2627ac_ext=c
2628ac_cpp='$CPP $CPPFLAGS'
2629ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2630ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2631ac_compiler_gnu=$ac_cv_c_compiler_gnu
2632if test -n "$ac_tool_prefix"; then
2633 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2634set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2635echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2636echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2637if test "${ac_cv_prog_CC+set}" = set; then
2638 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2639else
2640 if test -n "$CC"; then
2641 ac_cv_prog_CC="$CC" # Let the user override the test.
2642else
c0d27fcc
MR
2643as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2644for as_dir in $PATH
2645do
2646 IFS=$as_save_IFS
2647 test -z "$as_dir" && as_dir=.
2648 for ac_exec_ext in '' $ac_executable_extensions; do
2649 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2650 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2651 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2652 break 2
2653 fi
2654done
503d2be0
AS
2655done
2656
ba4481b5
DL
2657fi
2658fi
503d2be0 2659CC=$ac_cv_prog_CC
ba4481b5 2660if test -n "$CC"; then
c0d27fcc 2661 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2662echo "${ECHO_T}$CC" >&6
2663else
c0d27fcc 2664 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2665echo "${ECHO_T}no" >&6
2666fi
2667
2668fi
2669if test -z "$ac_cv_prog_CC"; then
2670 ac_ct_CC=$CC
2671 # Extract the first word of "gcc", so it can be a program name with args.
2672set dummy gcc; ac_word=$2
c0d27fcc 2673echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2674echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2675if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2676 echo $ECHO_N "(cached) $ECHO_C" >&6
2677else
2678 if test -n "$ac_ct_CC"; then
2679 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2680else
c0d27fcc
MR
2681as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2682for as_dir in $PATH
2683do
2684 IFS=$as_save_IFS
2685 test -z "$as_dir" && as_dir=.
2686 for ac_exec_ext in '' $ac_executable_extensions; do
2687 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2688 ac_cv_prog_ac_ct_CC="gcc"
2689 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2690 break 2
2691 fi
2692done
503d2be0
AS
2693done
2694
2695fi
2696fi
2697ac_ct_CC=$ac_cv_prog_ac_ct_CC
2698if test -n "$ac_ct_CC"; then
c0d27fcc 2699 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2700echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2701else
c0d27fcc 2702 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2703echo "${ECHO_T}no" >&6
2704fi
2705
2706 CC=$ac_ct_CC
2707else
2708 CC="$ac_cv_prog_CC"
ba4481b5
DL
2709fi
2710
2711if test -z "$CC"; then
503d2be0
AS
2712 if test -n "$ac_tool_prefix"; then
2713 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2714set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2715echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2716echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2717if test "${ac_cv_prog_CC+set}" = set; then
2718 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2719else
2720 if test -n "$CC"; then
2721 ac_cv_prog_CC="$CC" # Let the user override the test.
2722else
c0d27fcc
MR
2723as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2724for as_dir in $PATH
2725do
2726 IFS=$as_save_IFS
2727 test -z "$as_dir" && as_dir=.
2728 for ac_exec_ext in '' $ac_executable_extensions; do
2729 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2730 ac_cv_prog_CC="${ac_tool_prefix}cc"
2731 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2732 break 2
2733 fi
2734done
503d2be0
AS
2735done
2736
2737fi
2738fi
2739CC=$ac_cv_prog_CC
2740if test -n "$CC"; then
c0d27fcc 2741 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2742echo "${ECHO_T}$CC" >&6
2743else
c0d27fcc 2744 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2745echo "${ECHO_T}no" >&6
2746fi
2747
2748fi
2749if test -z "$ac_cv_prog_CC"; then
2750 ac_ct_CC=$CC
2751 # Extract the first word of "cc", so it can be a program name with args.
2752set dummy cc; ac_word=$2
c0d27fcc 2753echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2754echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2755if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2756 echo $ECHO_N "(cached) $ECHO_C" >&6
2757else
2758 if test -n "$ac_ct_CC"; then
2759 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2760else
c0d27fcc
MR
2761as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2762for as_dir in $PATH
2763do
2764 IFS=$as_save_IFS
2765 test -z "$as_dir" && as_dir=.
2766 for ac_exec_ext in '' $ac_executable_extensions; do
2767 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2768 ac_cv_prog_ac_ct_CC="cc"
2769 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2770 break 2
2771 fi
2772done
503d2be0
AS
2773done
2774
2775fi
2776fi
2777ac_ct_CC=$ac_cv_prog_ac_ct_CC
2778if test -n "$ac_ct_CC"; then
c0d27fcc 2779 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2780echo "${ECHO_T}$ac_ct_CC" >&6
2781else
c0d27fcc 2782 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2783echo "${ECHO_T}no" >&6
2784fi
2785
2786 CC=$ac_ct_CC
2787else
2788 CC="$ac_cv_prog_CC"
2789fi
2790
2791fi
2792if test -z "$CC"; then
2793 # Extract the first word of "cc", so it can be a program name with args.
2794set dummy cc; ac_word=$2
c0d27fcc 2795echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2796echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2797if test "${ac_cv_prog_CC+set}" = set; then
2798 echo $ECHO_N "(cached) $ECHO_C" >&6
2799else
2800 if test -n "$CC"; then
2801 ac_cv_prog_CC="$CC" # Let the user override the test.
2802else
2803 ac_prog_rejected=no
c0d27fcc
MR
2804as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2805for as_dir in $PATH
2806do
2807 IFS=$as_save_IFS
2808 test -z "$as_dir" && as_dir=.
2809 for ac_exec_ext in '' $ac_executable_extensions; do
2810 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2811 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2812 ac_prog_rejected=yes
2813 continue
2814 fi
2815 ac_cv_prog_CC="cc"
2816 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2817 break 2
2818 fi
2819done
503d2be0
AS
2820done
2821
ba4481b5
DL
2822if test $ac_prog_rejected = yes; then
2823 # We found a bogon in the path, so make sure we never use it.
2824 set dummy $ac_cv_prog_CC
2825 shift
503d2be0 2826 if test $# != 0; then
ba4481b5
DL
2827 # We chose a different compiler from the bogus one.
2828 # However, it has the same basename, so the bogon will be chosen
2829 # first if we set CC to just the basename; use the full file name.
2830 shift
6bae0ccf 2831 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2832 fi
2833fi
2834fi
2835fi
503d2be0 2836CC=$ac_cv_prog_CC
ba4481b5 2837if test -n "$CC"; then
c0d27fcc 2838 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2839echo "${ECHO_T}$CC" >&6
ba4481b5 2840else
c0d27fcc 2841 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2842echo "${ECHO_T}no" >&6
ba4481b5
DL
2843fi
2844
503d2be0
AS
2845fi
2846if test -z "$CC"; then
2847 if test -n "$ac_tool_prefix"; then
2848 for ac_prog in cl
2849 do
2850 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2851set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2852echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2853echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2854if test "${ac_cv_prog_CC+set}" = set; then
2855 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2856else
2857 if test -n "$CC"; then
2858 ac_cv_prog_CC="$CC" # Let the user override the test.
2859else
c0d27fcc
MR
2860as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2861for as_dir in $PATH
2862do
2863 IFS=$as_save_IFS
2864 test -z "$as_dir" && as_dir=.
2865 for ac_exec_ext in '' $ac_executable_extensions; do
2866 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2867 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2868 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2869 break 2
2870 fi
2871done
503d2be0
AS
2872done
2873
c4bb2108
DL
2874fi
2875fi
503d2be0 2876CC=$ac_cv_prog_CC
c4bb2108 2877if test -n "$CC"; then
c0d27fcc 2878 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2879echo "${ECHO_T}$CC" >&6
c4bb2108 2880else
c0d27fcc 2881 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2882echo "${ECHO_T}no" >&6
2883fi
2884
2885 test -n "$CC" && break
2886 done
2887fi
2888if test -z "$CC"; then
2889 ac_ct_CC=$CC
2890 for ac_prog in cl
2891do
2892 # Extract the first word of "$ac_prog", so it can be a program name with args.
2893set dummy $ac_prog; ac_word=$2
c0d27fcc 2894echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2895echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2896if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2897 echo $ECHO_N "(cached) $ECHO_C" >&6
2898else
2899 if test -n "$ac_ct_CC"; then
2900 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2901else
c0d27fcc
MR
2902as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2903for as_dir in $PATH
2904do
2905 IFS=$as_save_IFS
2906 test -z "$as_dir" && as_dir=.
2907 for ac_exec_ext in '' $ac_executable_extensions; do
2908 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2909 ac_cv_prog_ac_ct_CC="$ac_prog"
2910 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2911 break 2
2912 fi
2913done
503d2be0
AS
2914done
2915
c4bb2108 2916fi
503d2be0
AS
2917fi
2918ac_ct_CC=$ac_cv_prog_ac_ct_CC
2919if test -n "$ac_ct_CC"; then
c0d27fcc 2920 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2921echo "${ECHO_T}$ac_ct_CC" >&6
2922else
c0d27fcc 2923 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2924echo "${ECHO_T}no" >&6
ba4481b5
DL
2925fi
2926
503d2be0
AS
2927 test -n "$ac_ct_CC" && break
2928done
ba4481b5 2929
503d2be0
AS
2930 CC=$ac_ct_CC
2931fi
2932
2933fi
ba4481b5 2934
c0d27fcc 2935
cd958eb3
MB
2936test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2937See \`config.log' for more details." >&5
2938echo "$as_me: error: no acceptable C compiler found in \$PATH
2939See \`config.log' for more details." >&2;}
503d2be0 2940 { (exit 1); exit 1; }; }
c4bb2108 2941
503d2be0 2942# Provide some information about the compiler.
c0d27fcc 2943echo "$as_me:$LINENO:" \
503d2be0
AS
2944 "checking for C compiler version" >&5
2945ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 2946{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
2947 (eval $ac_compiler --version </dev/null >&5) 2>&5
2948 ac_status=$?
c0d27fcc 2949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 2950 (exit $ac_status); }
c0d27fcc 2951{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
2952 (eval $ac_compiler -v </dev/null >&5) 2>&5
2953 ac_status=$?
c0d27fcc 2954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 2955 (exit $ac_status); }
c0d27fcc 2956{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
2957 (eval $ac_compiler -V </dev/null >&5) 2>&5
2958 ac_status=$?
c0d27fcc 2959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
2960 (exit $ac_status); }
2961
2962cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 2963#line $LINENO "configure"
cd958eb3
MB
2964/* confdefs.h. */
2965_ACEOF
2966cat confdefs.h >>conftest.$ac_ext
2967cat >>conftest.$ac_ext <<_ACEOF
2968/* end confdefs.h. */
c4bb2108 2969
503d2be0
AS
2970int
2971main ()
2972{
2973
2974 ;
2975 return 0;
2976}
2977_ACEOF
2978ac_clean_files_save=$ac_clean_files
cd958eb3 2979ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
2980# Try to create an executable without -o first, disregard a.out.
2981# It will help us diagnose broken compilers, and finding out an intuition
2982# of exeext.
c0d27fcc 2983echo "$as_me:$LINENO: checking for C compiler default output" >&5
503d2be0
AS
2984echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2985ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 2986if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
2987 (eval $ac_link_default) 2>&5
2988 ac_status=$?
c0d27fcc 2989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
2990 (exit $ac_status); }; then
2991 # Find the output, starting from the most likely. This scheme is
2992# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2993# resort.
c0d27fcc
MR
2994
2995# Be careful to initialize this variable, since it used to be cached.
2996# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2997ac_cv_exeext=
cd958eb3
MB
2998# b.out is created by i960 compilers.
2999for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
3000do
6bae0ccf 3001 test -f "$ac_file" || continue
503d2be0 3002 case $ac_file in
cd958eb3
MB
3003 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
3004 ;;
3005 conftest.$ac_ext )
3006 # This is the source file.
3007 ;;
3008 [ab].out )
3009 # We found the default executable, but exeext='' is most
3010 # certainly right.
3011 break;;
3012 *.* )
3013 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3014 # FIXME: I believe we export ac_cv_exeext for Libtool,
3015 # but it would be cool to find out if it's true. Does anybody
3016 # maintain Libtool? --akim.
3017 export ac_cv_exeext
3018 break;;
3019 * )
3020 break;;
503d2be0
AS
3021 esac
3022done
3023else
3024 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3025sed 's/^/| /' conftest.$ac_ext >&5
3026
6bae0ccf 3027{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
cd958eb3 3028See \`config.log' for more details." >&5
6bae0ccf 3029echo "$as_me: error: C compiler cannot create executables
cd958eb3 3030See \`config.log' for more details." >&2;}
503d2be0
AS
3031 { (exit 77); exit 77; }; }
3032fi
3033
3034ac_exeext=$ac_cv_exeext
c0d27fcc 3035echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3036echo "${ECHO_T}$ac_file" >&6
3037
3038# Check the compiler produces executables we can run. If not, either
3039# the compiler is broken, or we cross compile.
c0d27fcc 3040echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3041echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3042# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3043# If not cross compiling, check that we can run a simple program.
3044if test "$cross_compiling" != yes; then
3045 if { ac_try='./$ac_file'
c0d27fcc 3046 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3047 (eval $ac_try) 2>&5
3048 ac_status=$?
c0d27fcc 3049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3050 (exit $ac_status); }; }; then
3051 cross_compiling=no
ba4481b5 3052 else
503d2be0
AS
3053 if test "$cross_compiling" = maybe; then
3054 cross_compiling=yes
3055 else
c0d27fcc 3056 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
cd958eb3
MB
3057If you meant to cross compile, use \`--host'.
3058See \`config.log' for more details." >&5
503d2be0 3059echo "$as_me: error: cannot run C compiled programs.
cd958eb3
MB
3060If you meant to cross compile, use \`--host'.
3061See \`config.log' for more details." >&2;}
503d2be0
AS
3062 { (exit 1); exit 1; }; }
3063 fi
ba4481b5 3064 fi
503d2be0 3065fi
c0d27fcc 3066echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3067echo "${ECHO_T}yes" >&6
3068
cd958eb3 3069rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3070ac_clean_files=$ac_clean_files_save
3071# Check the compiler produces executables we can run. If not, either
3072# the compiler is broken, or we cross compile.
c0d27fcc 3073echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3074echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3075echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3076echo "${ECHO_T}$cross_compiling" >&6
3077
c0d27fcc
MR
3078echo "$as_me:$LINENO: checking for suffix of executables" >&5
3079echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3080if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3081 (eval $ac_link) 2>&5
3082 ac_status=$?
c0d27fcc 3083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3084 (exit $ac_status); }; then
3085 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3086# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3087# work properly (i.e., refer to `conftest.exe'), while it won't with
3088# `rm'.
6bae0ccf
DL
3089for ac_file in conftest.exe conftest conftest.*; do
3090 test -f "$ac_file" || continue
503d2be0 3091 case $ac_file in
6bae0ccf 3092 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0
AS
3093 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3094 export ac_cv_exeext
3095 break;;
3096 * ) break;;
3097 esac
3098done
ba4481b5 3099else
cd958eb3
MB
3100 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3101See \`config.log' for more details." >&5
3102echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3103See \`config.log' for more details." >&2;}
503d2be0 3104 { (exit 1); exit 1; }; }
ba4481b5 3105fi
ba4481b5 3106
503d2be0 3107rm -f conftest$ac_cv_exeext
c0d27fcc 3108echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3109echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3110
503d2be0
AS
3111rm -f conftest.$ac_ext
3112EXEEXT=$ac_cv_exeext
3113ac_exeext=$EXEEXT
c0d27fcc
MR
3114echo "$as_me:$LINENO: checking for suffix of object files" >&5
3115echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3116if test "${ac_cv_objext+set}" = set; then
3117 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3118else
503d2be0 3119 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3120#line $LINENO "configure"
cd958eb3
MB
3121/* confdefs.h. */
3122_ACEOF
3123cat confdefs.h >>conftest.$ac_ext
3124cat >>conftest.$ac_ext <<_ACEOF
3125/* end confdefs.h. */
ba4481b5 3126
503d2be0
AS
3127int
3128main ()
3129{
ba4481b5 3130
503d2be0
AS
3131 ;
3132 return 0;
3133}
3134_ACEOF
3135rm -f conftest.o conftest.obj
c0d27fcc 3136if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3137 (eval $ac_compile) 2>&5
3138 ac_status=$?
c0d27fcc 3139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3140 (exit $ac_status); }; then
3141 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3142 case $ac_file in
6bae0ccf 3143 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3144 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3145 break;;
3146 esac
3147done
c4bb2108 3148else
503d2be0 3149 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3150sed 's/^/| /' conftest.$ac_ext >&5
3151
3152{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3153See \`config.log' for more details." >&5
3154echo "$as_me: error: cannot compute suffix of object files: cannot compile
3155See \`config.log' for more details." >&2;}
503d2be0 3156 { (exit 1); exit 1; }; }
c4bb2108
DL
3157fi
3158
503d2be0
AS
3159rm -f conftest.$ac_cv_objext conftest.$ac_ext
3160fi
c0d27fcc 3161echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3162echo "${ECHO_T}$ac_cv_objext" >&6
3163OBJEXT=$ac_cv_objext
3164ac_objext=$OBJEXT
c0d27fcc 3165echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3166echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3167if test "${ac_cv_c_compiler_gnu+set}" = set; then
3168 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3169else
503d2be0 3170 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3171#line $LINENO "configure"
cd958eb3
MB
3172/* confdefs.h. */
3173_ACEOF
3174cat confdefs.h >>conftest.$ac_ext
3175cat >>conftest.$ac_ext <<_ACEOF
3176/* end confdefs.h. */
503d2be0
AS
3177
3178int
3179main ()
3180{
3181#ifndef __GNUC__
3182 choke me
3183#endif
3184
3185 ;
3186 return 0;
3187}
3188_ACEOF
3189rm -f conftest.$ac_objext
c0d27fcc 3190if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3191 (eval $ac_compile) 2>&5
3192 ac_status=$?
c0d27fcc 3193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3194 (exit $ac_status); } &&
3195 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3196 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3197 (eval $ac_try) 2>&5
3198 ac_status=$?
c0d27fcc 3199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3200 (exit $ac_status); }; }; then
3201 ac_compiler_gnu=yes
3202else
3203 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3204sed 's/^/| /' conftest.$ac_ext >&5
3205
503d2be0
AS
3206ac_compiler_gnu=no
3207fi
3208rm -f conftest.$ac_objext conftest.$ac_ext
3209ac_cv_c_compiler_gnu=$ac_compiler_gnu
3210
3211fi
c0d27fcc 3212echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3213echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3214GCC=`test $ac_compiler_gnu = yes && echo yes`
3215ac_test_CFLAGS=${CFLAGS+set}
3216ac_save_CFLAGS=$CFLAGS
3217CFLAGS="-g"
c0d27fcc 3218echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3219echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3220if test "${ac_cv_prog_cc_g+set}" = set; then
3221 echo $ECHO_N "(cached) $ECHO_C" >&6
3222else
3223 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3224#line $LINENO "configure"
cd958eb3
MB
3225/* confdefs.h. */
3226_ACEOF
3227cat confdefs.h >>conftest.$ac_ext
3228cat >>conftest.$ac_ext <<_ACEOF
3229/* end confdefs.h. */
503d2be0
AS
3230
3231int
3232main ()
3233{
3234
3235 ;
3236 return 0;
3237}
3238_ACEOF
3239rm -f conftest.$ac_objext
c0d27fcc 3240if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3241 (eval $ac_compile) 2>&5
3242 ac_status=$?
c0d27fcc 3243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3244 (exit $ac_status); } &&
3245 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3246 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3247 (eval $ac_try) 2>&5
3248 ac_status=$?
c0d27fcc 3249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3250 (exit $ac_status); }; }; then
ba4481b5
DL
3251 ac_cv_prog_cc_g=yes
3252else
503d2be0 3253 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3254sed 's/^/| /' conftest.$ac_ext >&5
3255
503d2be0 3256ac_cv_prog_cc_g=no
ba4481b5 3257fi
503d2be0 3258rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 3259fi
c0d27fcc 3260echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3261echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3262if test "$ac_test_CFLAGS" = set; then
503d2be0 3263 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3264elif test $ac_cv_prog_cc_g = yes; then
3265 if test "$GCC" = yes; then
ba4481b5
DL
3266 CFLAGS="-g -O2"
3267 else
c4bb2108 3268 CFLAGS="-g"
ba4481b5 3269 fi
22afa6e8 3270else
c4bb2108
DL
3271 if test "$GCC" = yes; then
3272 CFLAGS="-O2"
3273 else
3274 CFLAGS=
3275 fi
ba4481b5 3276fi
6bae0ccf
DL
3277echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3278echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3279if test "${ac_cv_prog_cc_stdc+set}" = set; then
3280 echo $ECHO_N "(cached) $ECHO_C" >&6
3281else
3282 ac_cv_prog_cc_stdc=no
3283ac_save_CC=$CC
3284cat >conftest.$ac_ext <<_ACEOF
3285#line $LINENO "configure"
cd958eb3
MB
3286/* confdefs.h. */
3287_ACEOF
3288cat confdefs.h >>conftest.$ac_ext
3289cat >>conftest.$ac_ext <<_ACEOF
3290/* end confdefs.h. */
6bae0ccf
DL
3291#include <stdarg.h>
3292#include <stdio.h>
3293#include <sys/types.h>
3294#include <sys/stat.h>
3295/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3296struct buf { int x; };
3297FILE * (*rcsopen) (struct buf *, struct stat *, int);
3298static char *e (p, i)
3299 char **p;
3300 int i;
3301{
3302 return p[i];
3303}
3304static char *f (char * (*g) (char **, int), char **p, ...)
3305{
3306 char *s;
3307 va_list v;
3308 va_start (v,p);
3309 s = g (p, va_arg (v,int));
3310 va_end (v);
3311 return s;
3312}
3313int test (int i, double x);
3314struct s1 {int (*f) (int a);};
3315struct s2 {int (*f) (double a);};
3316int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3317int argc;
3318char **argv;
3319int
3320main ()
3321{
3322return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3323 ;
3324 return 0;
3325}
3326_ACEOF
3327# Don't try gcc -ansi; that turns off useful extensions and
3328# breaks some systems' header files.
3329# AIX -qlanglvl=ansi
3330# Ultrix and OSF/1 -std1
3331# HP-UX 10.20 and later -Ae
3332# HP-UX older versions -Aa -D_HPUX_SOURCE
3333# SVR4 -Xc -D__EXTENSIONS__
3334for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3335do
3336 CC="$ac_save_CC $ac_arg"
3337 rm -f conftest.$ac_objext
3338if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3339 (eval $ac_compile) 2>&5
3340 ac_status=$?
3341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3342 (exit $ac_status); } &&
3343 { ac_try='test -s conftest.$ac_objext'
3344 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3345 (eval $ac_try) 2>&5
3346 ac_status=$?
3347 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3348 (exit $ac_status); }; }; then
3349 ac_cv_prog_cc_stdc=$ac_arg
3350break
3351else
3352 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3353sed 's/^/| /' conftest.$ac_ext >&5
3354
6bae0ccf
DL
3355fi
3356rm -f conftest.$ac_objext
3357done
3358rm -f conftest.$ac_ext conftest.$ac_objext
3359CC=$ac_save_CC
3360
3361fi
3362
3363case "x$ac_cv_prog_cc_stdc" in
3364 x|xno)
3365 echo "$as_me:$LINENO: result: none needed" >&5
3366echo "${ECHO_T}none needed" >&6 ;;
3367 *)
3368 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3369echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3370 CC="$CC $ac_cv_prog_cc_stdc" ;;
3371esac
3372
503d2be0
AS
3373# Some people use a C++ compiler to compile C. Since we use `exit',
3374# in C++ we need to declare it. In case someone uses the same compiler
3375# for both compiling C and C++ we need to have the C++ compiler decide
3376# the declaration of exit, since it's the most demanding environment.
3377cat >conftest.$ac_ext <<_ACEOF
3378#ifndef __cplusplus
3379 choke me
3380#endif
3381_ACEOF
3382rm -f conftest.$ac_objext
c0d27fcc 3383if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3384 (eval $ac_compile) 2>&5
3385 ac_status=$?
c0d27fcc 3386 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3387 (exit $ac_status); } &&
3388 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3389 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3390 (eval $ac_try) 2>&5
3391 ac_status=$?
c0d27fcc 3392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3393 (exit $ac_status); }; }; then
3394 for ac_declaration in \
3395 ''\
3396 '#include <stdlib.h>' \
3397 'extern "C" void std::exit (int) throw (); using std::exit;' \
3398 'extern "C" void std::exit (int); using std::exit;' \
3399 'extern "C" void exit (int) throw ();' \
3400 'extern "C" void exit (int);' \
3401 'void exit (int);'
3402do
3403 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3404#line $LINENO "configure"
cd958eb3
MB
3405/* confdefs.h. */
3406_ACEOF
3407cat confdefs.h >>conftest.$ac_ext
3408cat >>conftest.$ac_ext <<_ACEOF
3409/* end confdefs.h. */
503d2be0
AS
3410#include <stdlib.h>
3411$ac_declaration
3412int
3413main ()
3414{
3415exit (42);
3416 ;
3417 return 0;
3418}
3419_ACEOF
3420rm -f conftest.$ac_objext
c0d27fcc 3421if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3422 (eval $ac_compile) 2>&5
3423 ac_status=$?
c0d27fcc 3424 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3425 (exit $ac_status); } &&
3426 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3427 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3428 (eval $ac_try) 2>&5
3429 ac_status=$?
c0d27fcc 3430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3431 (exit $ac_status); }; }; then
3432 :
3433else
3434 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3435sed 's/^/| /' conftest.$ac_ext >&5
3436
503d2be0
AS
3437continue
3438fi
3439rm -f conftest.$ac_objext conftest.$ac_ext
3440 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3441#line $LINENO "configure"
cd958eb3
MB
3442/* confdefs.h. */
3443_ACEOF
3444cat confdefs.h >>conftest.$ac_ext
3445cat >>conftest.$ac_ext <<_ACEOF
3446/* end confdefs.h. */
503d2be0
AS
3447$ac_declaration
3448int
3449main ()
3450{
3451exit (42);
3452 ;
3453 return 0;
3454}
3455_ACEOF
3456rm -f conftest.$ac_objext
c0d27fcc 3457if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3458 (eval $ac_compile) 2>&5
3459 ac_status=$?
c0d27fcc 3460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3461 (exit $ac_status); } &&
3462 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3463 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3464 (eval $ac_try) 2>&5
3465 ac_status=$?
c0d27fcc 3466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3467 (exit $ac_status); }; }; then
3468 break
3469else
3470 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3471sed 's/^/| /' conftest.$ac_ext >&5
3472
503d2be0
AS
3473fi
3474rm -f conftest.$ac_objext conftest.$ac_ext
3475done
3476rm -f conftest*
3477if test -n "$ac_declaration"; then
3478 echo '#ifdef __cplusplus' >>confdefs.h
3479 echo $ac_declaration >>confdefs.h
3480 echo '#endif' >>confdefs.h
3481fi
ba4481b5 3482
503d2be0
AS
3483else
3484 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3485sed 's/^/| /' conftest.$ac_ext >&5
3486
503d2be0
AS
3487fi
3488rm -f conftest.$ac_objext conftest.$ac_ext
3489ac_ext=c
3490ac_cpp='$CPP $CPPFLAGS'
3491ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3492ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3493ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3494
c0d27fcc 3495
ba4481b5
DL
3496# On Suns, sometimes $CPP names a directory.
3497if test -n "$CPP" && test -d "$CPP"; then
3498 CPP=
3499fi
3500
3501#### Some systems specify a CPP to use unless we are using GCC.
3502#### Now that we know whether we are using GCC, we can decide whether
3503#### to use that one.
3504if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3505then
3506 CPP="$NON_GNU_CPP"
3507fi
3508
3509#### Some systems specify a CC to use unless we are using GCC.
3510#### Now that we know whether we are using GCC, we can decide whether
3511#### to use that one.
3512if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3513 test x$cc_specified != xyes
3514then
3515 CC="$NON_GNU_CC"
3516fi
3517
3518if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3519then
3520 CC="$CC $GCC_TEST_OPTIONS"
3521fi
3522
3523if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3524then
3525 CC="$CC $NON_GCC_TEST_OPTIONS"
3526fi
3527
6a3a24fa 3528#### Some other nice autoconf tests.
ba4481b5 3529
c0d27fcc 3530echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3531echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3532LN_S=$as_ln_s
3533if test "$LN_S" = "ln -s"; then
c0d27fcc 3534 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3535echo "${ECHO_T}yes" >&6
ba4481b5 3536else
c0d27fcc 3537 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3538echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3539fi
3540
503d2be0
AS
3541ac_ext=c
3542ac_cpp='$CPP $CPPFLAGS'
3543ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3544ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3545ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3546echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3547echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3548# On Suns, sometimes $CPP names a directory.
3549if test -n "$CPP" && test -d "$CPP"; then
3550 CPP=
3551fi
3552if test -z "$CPP"; then
503d2be0
AS
3553 if test "${ac_cv_prog_CPP+set}" = set; then
3554 echo $ECHO_N "(cached) $ECHO_C" >&6
3555else
3556 # Double quotes because CPP needs to be expanded
3557 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3558 do
3559 ac_preproc_ok=false
3560for ac_c_preproc_warn_flag in '' yes
3561do
3562 # Use a header file that comes with gcc, so configuring glibc
3563 # with a fresh cross-compiler works.
9e71690e
DK
3564 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3565 # <limits.h> exists even on freestanding compilers.
ba4481b5 3566 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3567 # not just through cpp. "Syntax error" is here to catch this case.
3568 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3569#line $LINENO "configure"
cd958eb3
MB
3570/* confdefs.h. */
3571_ACEOF
3572cat confdefs.h >>conftest.$ac_ext
3573cat >>conftest.$ac_ext <<_ACEOF
3574/* end confdefs.h. */
9e71690e
DK
3575#ifdef __STDC__
3576# include <limits.h>
3577#else
3578# include <assert.h>
3579#endif
503d2be0
AS
3580 Syntax error
3581_ACEOF
c0d27fcc 3582if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3583 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3584 ac_status=$?
6bae0ccf 3585 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3586 rm -f conftest.er1
3587 cat conftest.err >&5
c0d27fcc 3588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3589 (exit $ac_status); } >/dev/null; then
3590 if test -s conftest.err; then
3591 ac_cpp_err=$ac_c_preproc_warn_flag
3592 else
3593 ac_cpp_err=
3594 fi
3595else
3596 ac_cpp_err=yes
3597fi
3598if test -z "$ac_cpp_err"; then
ba4481b5
DL
3599 :
3600else
503d2be0 3601 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3602sed 's/^/| /' conftest.$ac_ext >&5
3603
503d2be0
AS
3604 # Broken: fails on valid input.
3605continue
3606fi
3607rm -f conftest.err conftest.$ac_ext
3608
3609 # OK, works on sane cases. Now check whether non-existent headers
3610 # can be detected and how.
3611 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3612#line $LINENO "configure"
cd958eb3
MB
3613/* confdefs.h. */
3614_ACEOF
3615cat confdefs.h >>conftest.$ac_ext
3616cat >>conftest.$ac_ext <<_ACEOF
3617/* end confdefs.h. */
503d2be0
AS
3618#include <ac_nonexistent.h>
3619_ACEOF
c0d27fcc 3620if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3621 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3622 ac_status=$?
6bae0ccf 3623 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3624 rm -f conftest.er1
3625 cat conftest.err >&5
c0d27fcc 3626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3627 (exit $ac_status); } >/dev/null; then
3628 if test -s conftest.err; then
3629 ac_cpp_err=$ac_c_preproc_warn_flag
3630 else
3631 ac_cpp_err=
3632 fi
3633else
3634 ac_cpp_err=yes
3635fi
3636if test -z "$ac_cpp_err"; then
3637 # Broken: success on invalid input.
3638continue
c4bb2108 3639else
503d2be0 3640 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3641sed 's/^/| /' conftest.$ac_ext >&5
3642
503d2be0
AS
3643 # Passes both tests.
3644ac_preproc_ok=:
3645break
3646fi
3647rm -f conftest.err conftest.$ac_ext
3648
3649done
3650# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3651rm -f conftest.err conftest.$ac_ext
3652if $ac_preproc_ok; then
3653 break
3654fi
3655
3656 done
3657 ac_cv_prog_CPP=$CPP
3658
3659fi
3660 CPP=$ac_cv_prog_CPP
3661else
3662 ac_cv_prog_CPP=$CPP
3663fi
c0d27fcc 3664echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3665echo "${ECHO_T}$CPP" >&6
3666ac_preproc_ok=false
3667for ac_c_preproc_warn_flag in '' yes
3668do
3669 # Use a header file that comes with gcc, so configuring glibc
3670 # with a fresh cross-compiler works.
9e71690e
DK
3671 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3672 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3673 # On the NeXT, cc -E runs the code through the compiler's parser,
3674 # not just through cpp. "Syntax error" is here to catch this case.
3675 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3676#line $LINENO "configure"
cd958eb3
MB
3677/* confdefs.h. */
3678_ACEOF
3679cat confdefs.h >>conftest.$ac_ext
3680cat >>conftest.$ac_ext <<_ACEOF
3681/* end confdefs.h. */
9e71690e
DK
3682#ifdef __STDC__
3683# include <limits.h>
3684#else
3685# include <assert.h>
3686#endif
503d2be0
AS
3687 Syntax error
3688_ACEOF
c0d27fcc 3689if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3690 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3691 ac_status=$?
6bae0ccf 3692 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3693 rm -f conftest.er1
3694 cat conftest.err >&5
c0d27fcc 3695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3696 (exit $ac_status); } >/dev/null; then
3697 if test -s conftest.err; then
3698 ac_cpp_err=$ac_c_preproc_warn_flag
3699 else
3700 ac_cpp_err=
3701 fi
3702else
3703 ac_cpp_err=yes
3704fi
3705if test -z "$ac_cpp_err"; then
ba4481b5
DL
3706 :
3707else
503d2be0 3708 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3709sed 's/^/| /' conftest.$ac_ext >&5
3710
503d2be0
AS
3711 # Broken: fails on valid input.
3712continue
3713fi
3714rm -f conftest.err conftest.$ac_ext
3715
3716 # OK, works on sane cases. Now check whether non-existent headers
3717 # can be detected and how.
3718 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3719#line $LINENO "configure"
cd958eb3
MB
3720/* confdefs.h. */
3721_ACEOF
3722cat confdefs.h >>conftest.$ac_ext
3723cat >>conftest.$ac_ext <<_ACEOF
3724/* end confdefs.h. */
503d2be0
AS
3725#include <ac_nonexistent.h>
3726_ACEOF
c0d27fcc 3727if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3728 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3729 ac_status=$?
6bae0ccf 3730 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3731 rm -f conftest.er1
3732 cat conftest.err >&5
c0d27fcc 3733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3734 (exit $ac_status); } >/dev/null; then
3735 if test -s conftest.err; then
3736 ac_cpp_err=$ac_c_preproc_warn_flag
3737 else
3738 ac_cpp_err=
3739 fi
3740else
3741 ac_cpp_err=yes
c4bb2108 3742fi
503d2be0
AS
3743if test -z "$ac_cpp_err"; then
3744 # Broken: success on invalid input.
3745continue
3746else
3747 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3748sed 's/^/| /' conftest.$ac_ext >&5
3749
503d2be0
AS
3750 # Passes both tests.
3751ac_preproc_ok=:
3752break
ba4481b5 3753fi
503d2be0
AS
3754rm -f conftest.err conftest.$ac_ext
3755
3756done
3757# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3758rm -f conftest.err conftest.$ac_ext
3759if $ac_preproc_ok; then
3760 :
ba4481b5 3761else
cd958eb3
MB
3762 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3763See \`config.log' for more details." >&5
3764echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3765See \`config.log' for more details." >&2;}
503d2be0 3766 { (exit 1); exit 1; }; }
ba4481b5 3767fi
503d2be0
AS
3768
3769ac_ext=c
3770ac_cpp='$CPP $CPPFLAGS'
3771ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3772ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3773ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3774
3775# Find a good install program. We prefer a C program (faster),
3776# so one script is as good as another. But avoid the broken or
3777# incompatible versions:
3778# SysV /etc/install, /usr/sbin/install
3779# SunOS /usr/etc/install
3780# IRIX /sbin/install
3781# AIX /bin/install
503d2be0 3782# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3783# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3784# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3785# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3786# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3787echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3788echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3789if test -z "$INSTALL"; then
503d2be0
AS
3790if test "${ac_cv_path_install+set}" = set; then
3791 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3792else
c0d27fcc
MR
3793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3794for as_dir in $PATH
3795do
3796 IFS=$as_save_IFS
3797 test -z "$as_dir" && as_dir=.
3798 # Account for people who put trailing slashes in PATH elements.
3799case $as_dir/ in
3800 ./ | .// | /cC/* | \
3801 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3802 /usr/ucb/* ) ;;
3803 *)
3804 # OSF1 and SCO ODT 3.0 have their own names for install.
3805 # Don't use installbsd from OSF since it installs stuff as root
3806 # by default.
3807 for ac_prog in ginstall scoinst install; do
3808 for ac_exec_ext in '' $ac_executable_extensions; do
3809 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3810 if test $ac_prog = install &&
3811 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3812 # AIX install. It has an incompatible calling convention.
3813 :
3814 elif test $ac_prog = install &&
3815 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3816 # program-specific install script used by HP pwplus--don't use.
3817 :
3818 else
3819 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3820 break 3
3821 fi
3822 fi
ba4481b5 3823 done
c0d27fcc
MR
3824 done
3825 ;;
3826esac
3827done
3828
ba4481b5
DL
3829
3830fi
3831 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3832 INSTALL=$ac_cv_path_install
ba4481b5
DL
3833 else
3834 # As a last resort, use the slow shell script. We don't cache a
3835 # path for INSTALL within a source directory, because that will
3836 # break other packages using the cache if that directory is
3837 # removed, or if the path is relative.
503d2be0 3838 INSTALL=$ac_install_sh
ba4481b5
DL
3839 fi
3840fi
c0d27fcc 3841echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3842echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3843
3844# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3845# It thinks the first close brace ends the variable substitution.
3846test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3847
503d2be0 3848test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3849
ba4481b5
DL
3850test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3851
c0d27fcc
MR
3852if test "x$RANLIB" = x; then
3853 if test -n "$ac_tool_prefix"; then
3854 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3855set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3856echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3857echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3858if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3859 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3860else
3861 if test -n "$RANLIB"; then
3862 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3863else
c0d27fcc
MR
3864as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3865for as_dir in $PATH
3866do
3867 IFS=$as_save_IFS
3868 test -z "$as_dir" && as_dir=.
3869 for ac_exec_ext in '' $ac_executable_extensions; do
3870 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3871 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3872 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3873 break 2
3874 fi
3875done
503d2be0
AS
3876done
3877
7397acc4
DL
3878fi
3879fi
503d2be0 3880RANLIB=$ac_cv_prog_RANLIB
7397acc4 3881if test -n "$RANLIB"; then
c0d27fcc 3882 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
3883echo "${ECHO_T}$RANLIB" >&6
3884else
c0d27fcc 3885 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3886echo "${ECHO_T}no" >&6
3887fi
3888
3889fi
3890if test -z "$ac_cv_prog_RANLIB"; then
3891 ac_ct_RANLIB=$RANLIB
3892 # Extract the first word of "ranlib", so it can be a program name with args.
3893set dummy ranlib; ac_word=$2
c0d27fcc 3894echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
3895echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3896if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3897 echo $ECHO_N "(cached) $ECHO_C" >&6
3898else
3899 if test -n "$ac_ct_RANLIB"; then
3900 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3901else
c0d27fcc
MR
3902as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3903for as_dir in $PATH
3904do
3905 IFS=$as_save_IFS
3906 test -z "$as_dir" && as_dir=.
3907 for ac_exec_ext in '' $ac_executable_extensions; do
3908 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3909 ac_cv_prog_ac_ct_RANLIB="ranlib"
3910 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3911 break 2
3912 fi
3913done
503d2be0
AS
3914done
3915
3916 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3917fi
3918fi
3919ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3920if test -n "$ac_ct_RANLIB"; then
c0d27fcc 3921 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
3922echo "${ECHO_T}$ac_ct_RANLIB" >&6
3923else
c0d27fcc 3924 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3925echo "${ECHO_T}no" >&6
3926fi
3927
3928 RANLIB=$ac_ct_RANLIB
7397acc4 3929else
503d2be0 3930 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
3931fi
3932
3933fi
9e71690e
DK
3934# Extract the first word of "install-info", so it can be a program name with args.
3935set dummy install-info; ac_word=$2
3936echo "$as_me:$LINENO: checking for $ac_word" >&5
3937echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3938if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
3939 echo $ECHO_N "(cached) $ECHO_C" >&6
3940else
3941 case $INSTALL_INFO in
3942 [\\/]* | ?:[\\/]*)
3943 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
3944 ;;
3945 *)
3946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3947for as_dir in $PATH
3948do
3949 IFS=$as_save_IFS
3950 test -z "$as_dir" && as_dir=.
3951 for ac_exec_ext in '' $ac_executable_extensions; do
3952 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3953 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
3954 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3955 break 2
3956 fi
3957done
3958done
3959
3960 ;;
3961esac
3962fi
3963INSTALL_INFO=$ac_cv_path_INSTALL_INFO
3964
3965if test -n "$INSTALL_INFO"; then
3966 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
3967echo "${ECHO_T}$INSTALL_INFO" >&6
3968else
3969 echo "$as_me:$LINENO: result: no" >&5
3970echo "${ECHO_T}no" >&6
3971fi
3972
3973# Extract the first word of "install-info", so it can be a program name with args.
3974set dummy install-info; ac_word=$2
3975echo "$as_me:$LINENO: checking for $ac_word" >&5
3976echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3977if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
3978 echo $ECHO_N "(cached) $ECHO_C" >&6
3979else
3980 case $INSTALL_INFO in
3981 [\\/]* | ?:[\\/]*)
3982 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
3983 ;;
3984 *)
3985 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3986for as_dir in /usr/sbin
3987do
3988 IFS=$as_save_IFS
3989 test -z "$as_dir" && as_dir=.
3990 for ac_exec_ext in '' $ac_executable_extensions; do
3991 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3992 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
3993 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3994 break 2
3995 fi
3996done
3997done
3998
3999 ;;
4000esac
4001fi
4002INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4003
4004if test -n "$INSTALL_INFO"; then
4005 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4006echo "${ECHO_T}$INSTALL_INFO" >&6
4007else
4008 echo "$as_me:$LINENO: result: no" >&5
4009echo "${ECHO_T}no" >&6
4010fi
4011
4012# Extract the first word of "install-info", so it can be a program name with args.
4013set dummy install-info; ac_word=$2
4014echo "$as_me:$LINENO: checking for $ac_word" >&5
4015echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4016if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4017 echo $ECHO_N "(cached) $ECHO_C" >&6
4018else
4019 case $INSTALL_INFO in
4020 [\\/]* | ?:[\\/]*)
4021 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4022 ;;
4023 *)
4024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4025for as_dir in /sbin
4026do
4027 IFS=$as_save_IFS
4028 test -z "$as_dir" && as_dir=.
4029 for ac_exec_ext in '' $ac_executable_extensions; do
4030 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4031 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4032 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4033 break 2
4034 fi
4035done
4036done
4037
4038 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4039 ;;
4040esac
4041fi
4042INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4043
4044if test -n "$INSTALL_INFO"; then
4045 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4046echo "${ECHO_T}$INSTALL_INFO" >&6
4047else
4048 echo "$as_me:$LINENO: result: no" >&5
4049echo "${ECHO_T}no" >&6
4050fi
4051
ba4481b5 4052
c0d27fcc 4053
8e967cf7
MR
4054if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4055then
4056 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4057fi
4058
4059if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4060then
4061 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4062fi
4063
c0d27fcc
MR
4064
4065
6bae0ccf
DL
4066echo "$as_me:$LINENO: checking for egrep" >&5
4067echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4068if test "${ac_cv_prog_egrep+set}" = set; then
4069 echo $ECHO_N "(cached) $ECHO_C" >&6
4070else
4071 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4072 then ac_cv_prog_egrep='grep -E'
4073 else ac_cv_prog_egrep='egrep'
4074 fi
4075fi
4076echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4077echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4078 EGREP=$ac_cv_prog_egrep
4079
4080
c0d27fcc
MR
4081
4082echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4083echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4084cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4085#line $LINENO "configure"
cd958eb3
MB
4086/* confdefs.h. */
4087_ACEOF
4088cat confdefs.h >>conftest.$ac_ext
4089cat >>conftest.$ac_ext <<_ACEOF
4090/* end confdefs.h. */
ba4481b5
DL
4091#ifdef _AIX
4092 yes
4093#endif
4094
503d2be0 4095_ACEOF
ba4481b5 4096if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4097 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4098 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4099echo "${ECHO_T}yes" >&6
c0d27fcc 4100cat >>confdefs.h <<\_ACEOF
ba4481b5 4101#define _ALL_SOURCE 1
c0d27fcc 4102_ACEOF
ba4481b5
DL
4103
4104else
c0d27fcc 4105 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4106echo "${ECHO_T}no" >&6
ba4481b5
DL
4107fi
4108rm -f conftest*
4109
c0d27fcc
MR
4110
4111
3b33a005
DL
4112#### Extract some information from the operating system and machine files.
4113
c0d27fcc 4114{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4115 - which libraries the lib-src programs will want, and
503d2be0
AS
4116 - whether the GNU malloc routines are usable..." >&5
4117echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4118 - which libraries the lib-src programs will want, and
503d2be0 4119 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4120
4121### First figure out CFLAGS (which we use for running the compiler here)
4122### and REAL_CFLAGS (which we use for real compilation).
4123### The two are the same except on a few systems, where they are made
4124### different to work around various lossages. For example,
4125### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4126### as implying static linking.
4127
4128### If the CFLAGS env var is specified, we use that value
4129### instead of the default.
4130
4131### It's not important that this name contain the PID; you can't run
4132### two configures in the same directory and have anything work
4133### anyway.
4134tempcname="conftest.c"
4135
4136echo '
4137#include "'${srcdir}'/src/'${opsysfile}'"
4138#include "'${srcdir}'/src/'${machfile}'"
4139#ifndef LIBS_MACHINE
4140#define LIBS_MACHINE
4141#endif
4142#ifndef LIBS_SYSTEM
4143#define LIBS_SYSTEM
4144#endif
4145#ifndef C_SWITCH_SYSTEM
4146#define C_SWITCH_SYSTEM
4147#endif
4148#ifndef C_SWITCH_MACHINE
4149#define C_SWITCH_MACHINE
4150#endif
4151configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4152configure___ c_switch_system=C_SWITCH_SYSTEM
4153configure___ c_switch_machine=C_SWITCH_MACHINE
4154
4155#ifndef LIB_X11_LIB
4156#define LIB_X11_LIB -lX11
4157#endif
4158
4159#ifndef LIBX11_MACHINE
4160#define LIBX11_MACHINE
4161#endif
4162
4163#ifndef LIBX11_SYSTEM
4164#define LIBX11_SYSTEM
4165#endif
4166configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4167
4168#ifdef UNEXEC
4169configure___ unexec=UNEXEC
4170#else
4171configure___ unexec=unexec.o
4172#endif
4173
4174#ifdef SYSTEM_MALLOC
4175configure___ system_malloc=yes
4176#else
4177configure___ system_malloc=no
4178#endif
4179
ef9e4345
GM
4180#ifdef USE_MMAP_FOR_BUFFERS
4181configure___ use_mmap_for_buffers=yes
73b77ee5 4182#else
ef9e4345 4183configure___ use_mmap_for_buffers=no
73b77ee5
GM
4184#endif
4185
3b33a005
DL
4186#ifndef C_DEBUG_SWITCH
4187#define C_DEBUG_SWITCH -g
4188#endif
4189
4190#ifndef C_OPTIMIZE_SWITCH
4191#ifdef __GNUC__
4192#define C_OPTIMIZE_SWITCH -O2
4193#else
4194#define C_OPTIMIZE_SWITCH -O
4195#endif
4196#endif
4197
4198#ifndef LD_SWITCH_MACHINE
4199#define LD_SWITCH_MACHINE
4200#endif
4201
4202#ifndef LD_SWITCH_SYSTEM
4203#define LD_SWITCH_SYSTEM
4204#endif
4205
4206#ifndef LD_SWITCH_X_SITE_AUX
4207#define LD_SWITCH_X_SITE_AUX
503d2be0 4208#endif
3b33a005
DL
4209
4210configure___ ld_switch_system=LD_SWITCH_SYSTEM
4211configure___ ld_switch_machine=LD_SWITCH_MACHINE
4212
4213#ifdef THIS_IS_CONFIGURE
4214
4215/* Get the CFLAGS for tests in configure. */
4216#ifdef __GNUC__
4217configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4218#else
4219configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4220#endif
4221
4222#else /* not THIS_IS_CONFIGURE */
4223
4224/* Get the CFLAGS for real compilation. */
4225#ifdef __GNUC__
4226configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4227#else
4228configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4229#endif
4230
4231#endif /* not THIS_IS_CONFIGURE */
4232' > ${tempcname}
4233
4234# The value of CPP is a quoted variable reference, so we need to do this
4235# to get its actual value...
4236CPP=`eval "echo $CPP"`
4237eval `${CPP} -Isrc ${tempcname} \
4238 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4239if test "x$SPECIFIED_CFLAGS" = x; then
4240 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4241 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4242else
4243 REAL_CFLAGS="$CFLAGS"
4244fi
4245rm ${tempcname}
4246
4247ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4248
4249### Make sure subsequent tests use flags consistent with the build flags.
4250
4251if test x"${OVERRIDE_CPPFLAGS}" != x; then
4252 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4253else
4254 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4255fi
4256
6bae0ccf
DL
4257
4258
22044edf
DL
4259
4260cat >>confdefs.h <<\_ACEOF
4261#define _GNU_SOURCE 1
4262_ACEOF
4263
4264
4265
503d2be0 4266# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4267if test "${enable_largefile+set}" = set; then
4268 enableval="$enable_largefile"
f4988be7 4269
503d2be0
AS
4270fi;
4271if test "$enable_largefile" != no; then
f4988be7 4272
c0d27fcc 4273 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4274echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4275if test "${ac_cv_sys_largefile_CC+set}" = set; then
4276 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4277else
f4988be7 4278 ac_cv_sys_largefile_CC=no
503d2be0
AS
4279 if test "$GCC" != yes; then
4280 ac_save_CC=$CC
4281 while :; do
4282 # IRIX 6.2 and later do not support large files by default,
4283 # so use the C compiler's -n32 option if that helps.
4284 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4285#line $LINENO "configure"
cd958eb3
MB
4286/* confdefs.h. */
4287_ACEOF
4288cat confdefs.h >>conftest.$ac_ext
4289cat >>conftest.$ac_ext <<_ACEOF
4290/* end confdefs.h. */
f4988be7 4291#include <sys/types.h>
503d2be0
AS
4292 /* Check that off_t can represent 2**63 - 1 correctly.
4293 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4294 since some C++ compilers masquerading as C compilers
4295 incorrectly reject 9223372036854775807. */
4296#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4297 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4298 && LARGE_OFF_T % 2147483647 == 1)
4299 ? 1 : -1];
4300int
4301main ()
4302{
f4988be7 4303
503d2be0
AS
4304 ;
4305 return 0;
4306}
4307_ACEOF
4308 rm -f conftest.$ac_objext
c0d27fcc 4309if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4310 (eval $ac_compile) 2>&5
4311 ac_status=$?
c0d27fcc 4312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4313 (exit $ac_status); } &&
4314 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4315 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4316 (eval $ac_try) 2>&5
4317 ac_status=$?
c0d27fcc 4318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4319 (exit $ac_status); }; }; then
4320 break
b192d653 4321else
503d2be0 4322 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4323sed 's/^/| /' conftest.$ac_ext >&5
4324
503d2be0
AS
4325fi
4326rm -f conftest.$ac_objext
4327 CC="$CC -n32"
4328 rm -f conftest.$ac_objext
c0d27fcc 4329if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4330 (eval $ac_compile) 2>&5
4331 ac_status=$?
c0d27fcc 4332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4333 (exit $ac_status); } &&
4334 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4335 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4336 (eval $ac_try) 2>&5
4337 ac_status=$?
c0d27fcc 4338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4339 (exit $ac_status); }; }; then
4340 ac_cv_sys_largefile_CC=' -n32'; break
4341else
4342 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4343sed 's/^/| /' conftest.$ac_ext >&5
4344
503d2be0
AS
4345fi
4346rm -f conftest.$ac_objext
4347 break
4348 done
4349 CC=$ac_save_CC
4350 rm -f conftest.$ac_ext
4351 fi
b192d653 4352fi
c0d27fcc 4353echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4354echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4355 if test "$ac_cv_sys_largefile_CC" != no; then
4356 CC=$CC$ac_cv_sys_largefile_CC
4357 fi
b192d653 4358
c0d27fcc 4359 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4360echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4361if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4362 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4363else
503d2be0 4364 while :; do
f4988be7 4365 ac_cv_sys_file_offset_bits=no
503d2be0 4366 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4367#line $LINENO "configure"
cd958eb3
MB
4368/* confdefs.h. */
4369_ACEOF
4370cat confdefs.h >>conftest.$ac_ext
4371cat >>conftest.$ac_ext <<_ACEOF
4372/* end confdefs.h. */
f4988be7 4373#include <sys/types.h>
503d2be0
AS
4374 /* Check that off_t can represent 2**63 - 1 correctly.
4375 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4376 since some C++ compilers masquerading as C compilers
4377 incorrectly reject 9223372036854775807. */
4378#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4379 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4380 && LARGE_OFF_T % 2147483647 == 1)
4381 ? 1 : -1];
4382int
4383main ()
4384{
f4988be7 4385
503d2be0
AS
4386 ;
4387 return 0;
4388}
4389_ACEOF
4390rm -f conftest.$ac_objext
c0d27fcc 4391if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4392 (eval $ac_compile) 2>&5
4393 ac_status=$?
c0d27fcc 4394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4395 (exit $ac_status); } &&
4396 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4397 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4398 (eval $ac_try) 2>&5
4399 ac_status=$?
c0d27fcc 4400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4401 (exit $ac_status); }; }; then
4402 break
f4988be7 4403else
503d2be0 4404 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4405sed 's/^/| /' conftest.$ac_ext >&5
4406
503d2be0
AS
4407fi
4408rm -f conftest.$ac_objext conftest.$ac_ext
4409 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4410#line $LINENO "configure"
cd958eb3
MB
4411/* confdefs.h. */
4412_ACEOF
4413cat confdefs.h >>conftest.$ac_ext
4414cat >>conftest.$ac_ext <<_ACEOF
4415/* end confdefs.h. */
f4988be7
GM
4416#define _FILE_OFFSET_BITS 64
4417#include <sys/types.h>
503d2be0
AS
4418 /* Check that off_t can represent 2**63 - 1 correctly.
4419 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4420 since some C++ compilers masquerading as C compilers
4421 incorrectly reject 9223372036854775807. */
4422#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4423 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4424 && LARGE_OFF_T % 2147483647 == 1)
4425 ? 1 : -1];
4426int
4427main ()
4428{
4429
4430 ;
4431 return 0;
4432}
4433_ACEOF
4434rm -f conftest.$ac_objext
c0d27fcc 4435if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4436 (eval $ac_compile) 2>&5
4437 ac_status=$?
c0d27fcc 4438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4439 (exit $ac_status); } &&
4440 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4441 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4442 (eval $ac_try) 2>&5
4443 ac_status=$?
c0d27fcc 4444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4445 (exit $ac_status); }; }; then
4446 ac_cv_sys_file_offset_bits=64; break
4447else
4448 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4449sed 's/^/| /' conftest.$ac_ext >&5
4450
503d2be0
AS
4451fi
4452rm -f conftest.$ac_objext conftest.$ac_ext
4453 break
4454done
ba4481b5 4455fi
c0d27fcc 4456echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4457echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4458if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4459
c0d27fcc 4460cat >>confdefs.h <<_ACEOF
f4988be7 4461#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4462_ACEOF
f4988be7 4463
503d2be0
AS
4464fi
4465rm -f conftest*
c0d27fcc 4466 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4467echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4468if test "${ac_cv_sys_large_files+set}" = set; then
4469 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4470else
503d2be0 4471 while :; do
f4988be7 4472 ac_cv_sys_large_files=no
503d2be0 4473 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4474#line $LINENO "configure"
cd958eb3
MB
4475/* confdefs.h. */
4476_ACEOF
4477cat confdefs.h >>conftest.$ac_ext
4478cat >>conftest.$ac_ext <<_ACEOF
4479/* end confdefs.h. */
503d2be0
AS
4480#include <sys/types.h>
4481 /* Check that off_t can represent 2**63 - 1 correctly.
4482 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4483 since some C++ compilers masquerading as C compilers
4484 incorrectly reject 9223372036854775807. */
4485#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4486 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4487 && LARGE_OFF_T % 2147483647 == 1)
4488 ? 1 : -1];
4489int
4490main ()
4491{
ba4481b5 4492
503d2be0
AS
4493 ;
4494 return 0;
4495}
4496_ACEOF
4497rm -f conftest.$ac_objext
c0d27fcc 4498if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4499 (eval $ac_compile) 2>&5
4500 ac_status=$?
c0d27fcc 4501 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4502 (exit $ac_status); } &&
4503 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4504 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4505 (eval $ac_try) 2>&5
4506 ac_status=$?
c0d27fcc 4507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4508 (exit $ac_status); }; }; then
4509 break
ba4481b5 4510else
503d2be0 4511 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4512sed 's/^/| /' conftest.$ac_ext >&5
4513
503d2be0
AS
4514fi
4515rm -f conftest.$ac_objext conftest.$ac_ext
4516 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4517#line $LINENO "configure"
cd958eb3
MB
4518/* confdefs.h. */
4519_ACEOF
4520cat confdefs.h >>conftest.$ac_ext
4521cat >>conftest.$ac_ext <<_ACEOF
4522/* end confdefs.h. */
f4988be7 4523#define _LARGE_FILES 1
503d2be0
AS
4524#include <sys/types.h>
4525 /* Check that off_t can represent 2**63 - 1 correctly.
4526 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4527 since some C++ compilers masquerading as C compilers
4528 incorrectly reject 9223372036854775807. */
4529#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4530 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4531 && LARGE_OFF_T % 2147483647 == 1)
4532 ? 1 : -1];
4533int
4534main ()
4535{
f4988be7 4536
503d2be0
AS
4537 ;
4538 return 0;
4539}
4540_ACEOF
4541rm -f conftest.$ac_objext
c0d27fcc 4542if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4543 (eval $ac_compile) 2>&5
4544 ac_status=$?
c0d27fcc 4545 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4546 (exit $ac_status); } &&
4547 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4548 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4549 (eval $ac_try) 2>&5
4550 ac_status=$?
c0d27fcc 4551 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4552 (exit $ac_status); }; }; then
4553 ac_cv_sys_large_files=1; break
4554else
4555 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4556sed 's/^/| /' conftest.$ac_ext >&5
4557
503d2be0
AS
4558fi
4559rm -f conftest.$ac_objext conftest.$ac_ext
4560 break
4561done
ba4481b5 4562fi
c0d27fcc 4563echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4564echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4565if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4566
c0d27fcc 4567cat >>confdefs.h <<_ACEOF
f4988be7 4568#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4569_ACEOF
ba4481b5 4570
503d2be0
AS
4571fi
4572rm -f conftest*
4573fi
ba4481b5 4574
c0d27fcc 4575
2c9dccc9
PJ
4576if test "${with_sound}" != "no"; then
4577 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4578 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4579echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4580if test "${ac_cv_header_stdc+set}" = set; then
4581 echo $ECHO_N "(cached) $ECHO_C" >&6
4582else
4583 cat >conftest.$ac_ext <<_ACEOF
4584#line $LINENO "configure"
cd958eb3
MB
4585/* confdefs.h. */
4586_ACEOF
4587cat confdefs.h >>conftest.$ac_ext
4588cat >>conftest.$ac_ext <<_ACEOF
4589/* end confdefs.h. */
c0d27fcc
MR
4590#include <stdlib.h>
4591#include <stdarg.h>
4592#include <string.h>
4593#include <float.h>
98418dba 4594
cd958eb3
MB
4595int
4596main ()
4597{
4598
4599 ;
4600 return 0;
4601}
c0d27fcc 4602_ACEOF
cd958eb3
MB
4603rm -f conftest.$ac_objext
4604if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4605 (eval $ac_compile) 2>&5
c0d27fcc 4606 ac_status=$?
c0d27fcc 4607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
cd958eb3
MB
4608 (exit $ac_status); } &&
4609 { ac_try='test -s conftest.$ac_objext'
4610 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4611 (eval $ac_try) 2>&5
4612 ac_status=$?
4613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4614 (exit $ac_status); }; }; then
c0d27fcc
MR
4615 ac_cv_header_stdc=yes
4616else
4617 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4618sed 's/^/| /' conftest.$ac_ext >&5
4619
4620ac_cv_header_stdc=no
c0d27fcc 4621fi
cd958eb3 4622rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4623
4624if test $ac_cv_header_stdc = yes; then
4625 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4626 cat >conftest.$ac_ext <<_ACEOF
4627#line $LINENO "configure"
cd958eb3
MB
4628/* confdefs.h. */
4629_ACEOF
4630cat confdefs.h >>conftest.$ac_ext
4631cat >>conftest.$ac_ext <<_ACEOF
4632/* end confdefs.h. */
c0d27fcc
MR
4633#include <string.h>
4634
4635_ACEOF
4636if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4637 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4638 :
4639else
4640 ac_cv_header_stdc=no
4641fi
4642rm -f conftest*
4643
4644fi
4645
4646if test $ac_cv_header_stdc = yes; then
4647 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4648 cat >conftest.$ac_ext <<_ACEOF
4649#line $LINENO "configure"
cd958eb3
MB
4650/* confdefs.h. */
4651_ACEOF
4652cat confdefs.h >>conftest.$ac_ext
4653cat >>conftest.$ac_ext <<_ACEOF
4654/* end confdefs.h. */
c0d27fcc
MR
4655#include <stdlib.h>
4656
4657_ACEOF
4658if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4659 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4660 :
4661else
4662 ac_cv_header_stdc=no
4663fi
4664rm -f conftest*
4665
4666fi
4667
4668if test $ac_cv_header_stdc = yes; then
4669 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4670 if test "$cross_compiling" = yes; then
4671 :
4672else
4673 cat >conftest.$ac_ext <<_ACEOF
4674#line $LINENO "configure"
cd958eb3
MB
4675/* confdefs.h. */
4676_ACEOF
4677cat confdefs.h >>conftest.$ac_ext
4678cat >>conftest.$ac_ext <<_ACEOF
4679/* end confdefs.h. */
c0d27fcc
MR
4680#include <ctype.h>
4681#if ((' ' & 0x0FF) == 0x020)
4682# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4683# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4684#else
cd958eb3
MB
4685# define ISLOWER(c) \
4686 (('a' <= (c) && (c) <= 'i') \
c0d27fcc
MR
4687 || ('j' <= (c) && (c) <= 'r') \
4688 || ('s' <= (c) && (c) <= 'z'))
4689# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4690#endif
4691
4692#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4693int
4694main ()
4695{
4696 int i;
4697 for (i = 0; i < 256; i++)
4698 if (XOR (islower (i), ISLOWER (i))
4699 || toupper (i) != TOUPPER (i))
4700 exit(2);
4701 exit (0);
4702}
4703_ACEOF
4704rm -f conftest$ac_exeext
4705if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4706 (eval $ac_link) 2>&5
4707 ac_status=$?
4708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4709 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4711 (eval $ac_try) 2>&5
4712 ac_status=$?
4713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4714 (exit $ac_status); }; }; then
4715 :
4716else
4717 echo "$as_me: program exited with status $ac_status" >&5
4718echo "$as_me: failed program was:" >&5
cd958eb3
MB
4719sed 's/^/| /' conftest.$ac_ext >&5
4720
c0d27fcc
MR
4721( exit $ac_status )
4722ac_cv_header_stdc=no
4723fi
6bae0ccf 4724rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4725fi
4726fi
4727fi
4728echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4729echo "${ECHO_T}$ac_cv_header_stdc" >&6
4730if test $ac_cv_header_stdc = yes; then
4731
4732cat >>confdefs.h <<\_ACEOF
4733#define STDC_HEADERS 1
4734_ACEOF
4735
4736fi
4737
4738# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4749 inttypes.h stdint.h unistd.h
98418dba
CW
4750do
4751as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4752echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4753echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4754if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4755 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4756else
925c2f3f 4757 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4758#line $LINENO "configure"
cd958eb3
MB
4759/* confdefs.h. */
4760_ACEOF
4761cat confdefs.h >>conftest.$ac_ext
4762cat >>conftest.$ac_ext <<_ACEOF
4763/* end confdefs.h. */
c0d27fcc
MR
4764$ac_includes_default
4765
4766#include <$ac_header>
4767_ACEOF
4768rm -f conftest.$ac_objext
4769if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4770 (eval $ac_compile) 2>&5
4771 ac_status=$?
4772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4773 (exit $ac_status); } &&
4774 { ac_try='test -s conftest.$ac_objext'
4775 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4776 (eval $ac_try) 2>&5
4777 ac_status=$?
4778 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4779 (exit $ac_status); }; }; then
4780 eval "$as_ac_Header=yes"
4781else
4782 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4783sed 's/^/| /' conftest.$ac_ext >&5
4784
c0d27fcc
MR
4785eval "$as_ac_Header=no"
4786fi
4787rm -f conftest.$ac_objext conftest.$ac_ext
4788fi
4789echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4790echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4791if test `eval echo '${'$as_ac_Header'}'` = yes; then
4792 cat >>confdefs.h <<_ACEOF
4793#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4794_ACEOF
4795
4796fi
4797
4798done
4799
4800
4801
4802
4803
4804for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
4805do
4806as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4807if eval "test \"\${$as_ac_Header+set}\" = set"; then
4808 echo "$as_me:$LINENO: checking for $ac_header" >&5
4809echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4810if eval "test \"\${$as_ac_Header+set}\" = set"; then
4811 echo $ECHO_N "(cached) $ECHO_C" >&6
4812fi
4813echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4814echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4815else
4816 # Is the header compilable?
4817echo "$as_me:$LINENO: checking $ac_header usability" >&5
4818echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4819cat >conftest.$ac_ext <<_ACEOF
4820#line $LINENO "configure"
cd958eb3
MB
4821/* confdefs.h. */
4822_ACEOF
4823cat confdefs.h >>conftest.$ac_ext
4824cat >>conftest.$ac_ext <<_ACEOF
4825/* end confdefs.h. */
c0d27fcc 4826$ac_includes_default
98418dba 4827#include <$ac_header>
503d2be0 4828_ACEOF
c0d27fcc
MR
4829rm -f conftest.$ac_objext
4830if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4831 (eval $ac_compile) 2>&5
4832 ac_status=$?
4833 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4834 (exit $ac_status); } &&
4835 { ac_try='test -s conftest.$ac_objext'
4836 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4837 (eval $ac_try) 2>&5
4838 ac_status=$?
4839 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4840 (exit $ac_status); }; }; then
4841 ac_header_compiler=yes
4842else
4843 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4844sed 's/^/| /' conftest.$ac_ext >&5
4845
c0d27fcc
MR
4846ac_header_compiler=no
4847fi
4848rm -f conftest.$ac_objext conftest.$ac_ext
4849echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4850echo "${ECHO_T}$ac_header_compiler" >&6
4851
4852# Is the header present?
4853echo "$as_me:$LINENO: checking $ac_header presence" >&5
4854echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4855cat >conftest.$ac_ext <<_ACEOF
4856#line $LINENO "configure"
cd958eb3
MB
4857/* confdefs.h. */
4858_ACEOF
4859cat confdefs.h >>conftest.$ac_ext
4860cat >>conftest.$ac_ext <<_ACEOF
4861/* end confdefs.h. */
c0d27fcc
MR
4862#include <$ac_header>
4863_ACEOF
4864if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 4865 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 4866 ac_status=$?
6bae0ccf 4867 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
4868 rm -f conftest.er1
4869 cat conftest.err >&5
c0d27fcc 4870 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
4871 (exit $ac_status); } >/dev/null; then
4872 if test -s conftest.err; then
4873 ac_cpp_err=$ac_c_preproc_warn_flag
4874 else
4875 ac_cpp_err=
4876 fi
4877else
4878 ac_cpp_err=yes
4879fi
4880if test -z "$ac_cpp_err"; then
c0d27fcc 4881 ac_header_preproc=yes
f4988be7 4882else
503d2be0 4883 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4884sed 's/^/| /' conftest.$ac_ext >&5
4885
c0d27fcc 4886 ac_header_preproc=no
f4988be7 4887fi
98418dba 4888rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
4889echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4890echo "${ECHO_T}$ac_header_preproc" >&6
4891
4892# So? What about this header?
4893case $ac_header_compiler:$ac_header_preproc in
4894 yes:no )
4895 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4896echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4897 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
4898echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4899 (
4900 cat <<\_ASBOX
4901## ------------------------------------ ##
4902## Report this to bug-autoconf@gnu.org. ##
4903## ------------------------------------ ##
4904_ASBOX
4905 ) |
4906 sed "s/^/$as_me: WARNING: /" >&2
4907 ;;
c0d27fcc
MR
4908 no:yes )
4909 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4910echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4911 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4912echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
4913 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
4914echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4915 (
4916 cat <<\_ASBOX
4917## ------------------------------------ ##
4918## Report this to bug-autoconf@gnu.org. ##
4919## ------------------------------------ ##
4920_ASBOX
4921 ) |
4922 sed "s/^/$as_me: WARNING: /" >&2
4923 ;;
c0d27fcc
MR
4924esac
4925echo "$as_me:$LINENO: checking for $ac_header" >&5
4926echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4927if eval "test \"\${$as_ac_Header+set}\" = set"; then
4928 echo $ECHO_N "(cached) $ECHO_C" >&6
4929else
4930 eval "$as_ac_Header=$ac_header_preproc"
f4988be7 4931fi
c0d27fcc 4932echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 4933echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
4934
4935fi
98418dba 4936if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 4937 cat >>confdefs.h <<_ACEOF
98418dba 4938#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 4939_ACEOF
f4988be7
GM
4940
4941fi
c0d27fcc 4942
98418dba
CW
4943done
4944
4945 # Emulation library used on NetBSD.
c0d27fcc 4946 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
4947echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
4948if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 4949 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4950else
98418dba
CW
4951 ac_check_lib_save_LIBS=$LIBS
4952LIBS="-lossaudio $LIBS"
4953cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4954#line $LINENO "configure"
cd958eb3
MB
4955/* confdefs.h. */
4956_ACEOF
4957cat confdefs.h >>conftest.$ac_ext
4958cat >>conftest.$ac_ext <<_ACEOF
4959/* end confdefs.h. */
98418dba
CW
4960
4961/* Override any gcc2 internal prototype to avoid an error. */
4962#ifdef __cplusplus
4963extern "C"
f4988be7 4964#endif
98418dba
CW
4965/* We use char because int might match the return type of a gcc2
4966 builtin and then its argument prototype would still apply. */
4967char _oss_ioctl ();
503d2be0
AS
4968int
4969main ()
4970{
98418dba 4971_oss_ioctl ();
503d2be0
AS
4972 ;
4973 return 0;
4974}
4975_ACEOF
98418dba 4976rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 4977if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 4978 (eval $ac_link) 2>&5
503d2be0 4979 ac_status=$?
c0d27fcc 4980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4981 (exit $ac_status); } &&
98418dba 4982 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 4983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4984 (eval $ac_try) 2>&5
4985 ac_status=$?
c0d27fcc 4986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4987 (exit $ac_status); }; }; then
98418dba 4988 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 4989else
503d2be0 4990 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4991sed 's/^/| /' conftest.$ac_ext >&5
4992
98418dba 4993ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 4994fi
98418dba
CW
4995rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4996LIBS=$ac_check_lib_save_LIBS
f4988be7 4997fi
c0d27fcc 4998echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
4999echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
5000if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
5001 LIBSOUND=-lossaudio
5002else
5003 LIBSOUND=
5004fi
5005
c0d27fcc 5006
f4988be7 5007fi
c0d27fcc
MR
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
22044edf
DL
5026
5027
c0d27fcc
MR
5028
5029
f4988be7 5030
98418dba
CW
5031for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5032 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
c0d27fcc 5033 termcap.h stdio_ext.h fcntl.h term.h strings.h coff.h pty.h sys/mman.h \
22044edf 5034 sys/param.h sys/vlimit.h sys/resource.h
98418dba
CW
5035do
5036as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5037if eval "test \"\${$as_ac_Header+set}\" = set"; then
5038 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5039echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5040if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5041 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5042fi
5043echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5044echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5045else
c0d27fcc
MR
5046 # Is the header compilable?
5047echo "$as_me:$LINENO: checking $ac_header usability" >&5
5048echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5049cat >conftest.$ac_ext <<_ACEOF
5050#line $LINENO "configure"
cd958eb3
MB
5051/* confdefs.h. */
5052_ACEOF
5053cat confdefs.h >>conftest.$ac_ext
5054cat >>conftest.$ac_ext <<_ACEOF
5055/* end confdefs.h. */
c0d27fcc
MR
5056$ac_includes_default
5057#include <$ac_header>
5058_ACEOF
5059rm -f conftest.$ac_objext
5060if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5061 (eval $ac_compile) 2>&5
5062 ac_status=$?
5063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5064 (exit $ac_status); } &&
5065 { ac_try='test -s conftest.$ac_objext'
5066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5067 (eval $ac_try) 2>&5
5068 ac_status=$?
5069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5070 (exit $ac_status); }; }; then
5071 ac_header_compiler=yes
5072else
5073 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5074sed 's/^/| /' conftest.$ac_ext >&5
5075
c0d27fcc
MR
5076ac_header_compiler=no
5077fi
5078rm -f conftest.$ac_objext conftest.$ac_ext
5079echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5080echo "${ECHO_T}$ac_header_compiler" >&6
5081
5082# Is the header present?
5083echo "$as_me:$LINENO: checking $ac_header presence" >&5
5084echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5085cat >conftest.$ac_ext <<_ACEOF
5086#line $LINENO "configure"
cd958eb3
MB
5087/* confdefs.h. */
5088_ACEOF
5089cat confdefs.h >>conftest.$ac_ext
5090cat >>conftest.$ac_ext <<_ACEOF
5091/* end confdefs.h. */
98418dba 5092#include <$ac_header>
503d2be0 5093_ACEOF
c0d27fcc 5094if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5095 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5096 ac_status=$?
6bae0ccf 5097 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5098 rm -f conftest.er1
5099 cat conftest.err >&5
c0d27fcc 5100 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5101 (exit $ac_status); } >/dev/null; then
5102 if test -s conftest.err; then
5103 ac_cpp_err=$ac_c_preproc_warn_flag
5104 else
5105 ac_cpp_err=
5106 fi
5107else
5108 ac_cpp_err=yes
5109fi
5110if test -z "$ac_cpp_err"; then
c0d27fcc 5111 ac_header_preproc=yes
34ec9ebe 5112else
503d2be0 5113 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5114sed 's/^/| /' conftest.$ac_ext >&5
5115
c0d27fcc 5116 ac_header_preproc=no
34ec9ebe 5117fi
98418dba 5118rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5119echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5120echo "${ECHO_T}$ac_header_preproc" >&6
5121
5122# So? What about this header?
5123case $ac_header_compiler:$ac_header_preproc in
5124 yes:no )
5125 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5126echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
5127 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
5128echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5129 (
5130 cat <<\_ASBOX
5131## ------------------------------------ ##
5132## Report this to bug-autoconf@gnu.org. ##
5133## ------------------------------------ ##
5134_ASBOX
5135 ) |
5136 sed "s/^/$as_me: WARNING: /" >&2
5137 ;;
c0d27fcc
MR
5138 no:yes )
5139 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5140echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
5141 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5142echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5143 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
5144echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5145 (
5146 cat <<\_ASBOX
5147## ------------------------------------ ##
5148## Report this to bug-autoconf@gnu.org. ##
5149## ------------------------------------ ##
5150_ASBOX
5151 ) |
5152 sed "s/^/$as_me: WARNING: /" >&2
5153 ;;
c0d27fcc
MR
5154esac
5155echo "$as_me:$LINENO: checking for $ac_header" >&5
5156echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5157if eval "test \"\${$as_ac_Header+set}\" = set"; then
5158 echo $ECHO_N "(cached) $ECHO_C" >&6
5159else
5160 eval "$as_ac_Header=$ac_header_preproc"
34ec9ebe 5161fi
c0d27fcc 5162echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5163echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5164
5165fi
98418dba 5166if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5167 cat >>confdefs.h <<_ACEOF
98418dba 5168#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5169_ACEOF
34ec9ebe 5170
98418dba 5171fi
c0d27fcc 5172
98418dba
CW
5173done
5174
22044edf
DL
5175
5176for ac_header in term.h
5177do
5178as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5179echo "$as_me:$LINENO: checking for $ac_header" >&5
5180echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5181if eval "test \"\${$as_ac_Header+set}\" = set"; then
5182 echo $ECHO_N "(cached) $ECHO_C" >&6
5183else
5184 cat >conftest.$ac_ext <<_ACEOF
5185#line $LINENO "configure"
cd958eb3
MB
5186/* confdefs.h. */
5187_ACEOF
5188cat confdefs.h >>conftest.$ac_ext
5189cat >>conftest.$ac_ext <<_ACEOF
5190/* end confdefs.h. */
22044edf
DL
5191#include <$ac_header>
5192_ACEOF
5193if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5194 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5195 ac_status=$?
5196 grep -v '^ *+' conftest.er1 >conftest.err
5197 rm -f conftest.er1
5198 cat conftest.err >&5
5199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5200 (exit $ac_status); } >/dev/null; then
5201 if test -s conftest.err; then
5202 ac_cpp_err=$ac_c_preproc_warn_flag
5203 else
5204 ac_cpp_err=
5205 fi
5206else
5207 ac_cpp_err=yes
5208fi
5209if test -z "$ac_cpp_err"; then
5210 eval "$as_ac_Header=yes"
5211else
5212 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5213sed 's/^/| /' conftest.$ac_ext >&5
5214
22044edf
DL
5215 eval "$as_ac_Header=no"
5216fi
5217rm -f conftest.err conftest.$ac_ext
5218fi
5219echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5220echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5221if test `eval echo '${'$as_ac_Header'}'` = yes; then
5222 cat >>confdefs.h <<_ACEOF
5223#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5224_ACEOF
5225
5226fi
5227
5228done
5229
c0d27fcc 5230echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5231echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5232if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5233 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5234else
503d2be0 5235 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5236#line $LINENO "configure"
cd958eb3
MB
5237/* confdefs.h. */
5238_ACEOF
5239cat confdefs.h >>conftest.$ac_ext
5240cat >>conftest.$ac_ext <<_ACEOF
5241/* end confdefs.h. */
98418dba
CW
5242#include <stdlib.h>
5243#include <stdarg.h>
5244#include <string.h>
5245#include <float.h>
5246
cd958eb3
MB
5247int
5248main ()
5249{
5250
5251 ;
5252 return 0;
5253}
98418dba 5254_ACEOF
cd958eb3
MB
5255rm -f conftest.$ac_objext
5256if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5257 (eval $ac_compile) 2>&5
503d2be0 5258 ac_status=$?
c0d27fcc 5259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
cd958eb3
MB
5260 (exit $ac_status); } &&
5261 { ac_try='test -s conftest.$ac_objext'
5262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5263 (eval $ac_try) 2>&5
5264 ac_status=$?
5265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5266 (exit $ac_status); }; }; then
98418dba 5267 ac_cv_header_stdc=yes
ba4481b5 5268else
503d2be0 5269 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5270sed 's/^/| /' conftest.$ac_ext >&5
5271
5272ac_cv_header_stdc=no
ba4481b5 5273fi
cd958eb3 5274rm -f conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5275
5276if test $ac_cv_header_stdc = yes; then
5277 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5278 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5279#line $LINENO "configure"
cd958eb3
MB
5280/* confdefs.h. */
5281_ACEOF
5282cat confdefs.h >>conftest.$ac_ext
5283cat >>conftest.$ac_ext <<_ACEOF
5284/* end confdefs.h. */
98418dba
CW
5285#include <string.h>
5286
5287_ACEOF
5288if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5289 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5290 :
5291else
5292 ac_cv_header_stdc=no
ba4481b5 5293fi
98418dba 5294rm -f conftest*
ba4481b5
DL
5295
5296fi
5297
98418dba
CW
5298if test $ac_cv_header_stdc = yes; then
5299 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5300 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5301#line $LINENO "configure"
cd958eb3
MB
5302/* confdefs.h. */
5303_ACEOF
5304cat confdefs.h >>conftest.$ac_ext
5305cat >>conftest.$ac_ext <<_ACEOF
5306/* end confdefs.h. */
98418dba
CW
5307#include <stdlib.h>
5308
5309_ACEOF
5310if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5311 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5312 :
5313else
5314 ac_cv_header_stdc=no
5315fi
5316rm -f conftest*
5317
5318fi
5319
5320if test $ac_cv_header_stdc = yes; then
5321 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5322 if test "$cross_compiling" = yes; then
5323 :
d42122a3 5324else
503d2be0 5325 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5326#line $LINENO "configure"
cd958eb3
MB
5327/* confdefs.h. */
5328_ACEOF
5329cat confdefs.h >>conftest.$ac_ext
5330cat >>conftest.$ac_ext <<_ACEOF
5331/* end confdefs.h. */
98418dba
CW
5332#include <ctype.h>
5333#if ((' ' & 0x0FF) == 0x020)
5334# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5335# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5336#else
cd958eb3
MB
5337# define ISLOWER(c) \
5338 (('a' <= (c) && (c) <= 'i') \
98418dba
CW
5339 || ('j' <= (c) && (c) <= 'r') \
5340 || ('s' <= (c) && (c) <= 'z'))
5341# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5342#endif
5343
5344#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5345int
5346main ()
5347{
98418dba
CW
5348 int i;
5349 for (i = 0; i < 256; i++)
5350 if (XOR (islower (i), ISLOWER (i))
5351 || toupper (i) != TOUPPER (i))
5352 exit(2);
5353 exit (0);
503d2be0
AS
5354}
5355_ACEOF
98418dba 5356rm -f conftest$ac_exeext
c0d27fcc 5357if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5358 (eval $ac_link) 2>&5
503d2be0 5359 ac_status=$?
c0d27fcc 5360 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5361 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5362 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5363 (eval $ac_try) 2>&5
5364 ac_status=$?
c0d27fcc 5365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5366 (exit $ac_status); }; }; then
98418dba 5367 :
d42122a3 5368else
98418dba
CW
5369 echo "$as_me: program exited with status $ac_status" >&5
5370echo "$as_me: failed program was:" >&5
cd958eb3
MB
5371sed 's/^/| /' conftest.$ac_ext >&5
5372
c0d27fcc 5373( exit $ac_status )
98418dba 5374ac_cv_header_stdc=no
d42122a3 5375fi
6bae0ccf 5376rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5377fi
98418dba
CW
5378fi
5379fi
c0d27fcc 5380echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5381echo "${ECHO_T}$ac_cv_header_stdc" >&6
5382if test $ac_cv_header_stdc = yes; then
5383
c0d27fcc 5384cat >>confdefs.h <<\_ACEOF
98418dba 5385#define STDC_HEADERS 1
c0d27fcc 5386_ACEOF
d42122a3
DL
5387
5388fi
5389
c0d27fcc 5390echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5391echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5392if test "${ac_cv_header_time+set}" = set; then
503d2be0 5393 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5394else
503d2be0 5395 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5396#line $LINENO "configure"
cd958eb3
MB
5397/* confdefs.h. */
5398_ACEOF
5399cat confdefs.h >>conftest.$ac_ext
5400cat >>conftest.$ac_ext <<_ACEOF
5401/* end confdefs.h. */
ba4481b5 5402#include <sys/types.h>
98418dba 5403#include <sys/time.h>
ba4481b5 5404#include <time.h>
503d2be0
AS
5405
5406int
5407main ()
5408{
98418dba
CW
5409if ((struct tm *) 0)
5410return 0;
503d2be0
AS
5411 ;
5412 return 0;
5413}
5414_ACEOF
5415rm -f conftest.$ac_objext
c0d27fcc 5416if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5417 (eval $ac_compile) 2>&5
5418 ac_status=$?
c0d27fcc 5419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5420 (exit $ac_status); } &&
5421 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5422 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5423 (eval $ac_try) 2>&5
5424 ac_status=$?
c0d27fcc 5425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5426 (exit $ac_status); }; }; then
98418dba 5427 ac_cv_header_time=yes
ba4481b5 5428else
503d2be0 5429 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5430sed 's/^/| /' conftest.$ac_ext >&5
5431
98418dba 5432ac_cv_header_time=no
ba4481b5 5433fi
503d2be0 5434rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5435fi
c0d27fcc 5436echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5437echo "${ECHO_T}$ac_cv_header_time" >&6
5438if test $ac_cv_header_time = yes; then
503d2be0 5439
c0d27fcc 5440cat >>confdefs.h <<\_ACEOF
98418dba 5441#define TIME_WITH_SYS_TIME 1
c0d27fcc 5442_ACEOF
ba4481b5
DL
5443
5444fi
5445
cd958eb3
MB
5446echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5447echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5448if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5449 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5450else
503d2be0 5451 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5452#line $LINENO "configure"
cd958eb3
MB
5453/* confdefs.h. */
5454_ACEOF
5455cat confdefs.h >>conftest.$ac_ext
5456cat >>conftest.$ac_ext <<_ACEOF
5457/* end confdefs.h. */
5458$ac_includes_default
5459int
5460main ()
5461{
5462#ifndef sys_siglist
5463 char *p = (char *) sys_siglist;
98418dba 5464#endif
503d2be0 5465
cd958eb3
MB
5466 ;
5467 return 0;
5468}
5469_ACEOF
5470rm -f conftest.$ac_objext
5471if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5472 (eval $ac_compile) 2>&5
5473 ac_status=$?
5474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5475 (exit $ac_status); } &&
5476 { ac_try='test -s conftest.$ac_objext'
5477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5478 (eval $ac_try) 2>&5
5479 ac_status=$?
5480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5481 (exit $ac_status); }; }; then
5482 ac_cv_have_decl_sys_siglist=yes
5483else
5484 echo "$as_me: failed program was:" >&5
5485sed 's/^/| /' conftest.$ac_ext >&5
5486
5487ac_cv_have_decl_sys_siglist=no
5488fi
5489rm -f conftest.$ac_objext conftest.$ac_ext
5490fi
5491echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5492echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5493if test $ac_cv_have_decl_sys_siglist = yes; then
5494
5495cat >>confdefs.h <<_ACEOF
5496#define HAVE_DECL_SYS_SIGLIST 1
5497_ACEOF
5498
5499
5500else
5501 cat >>confdefs.h <<_ACEOF
5502#define HAVE_DECL_SYS_SIGLIST 0
5503_ACEOF
5504
5505
5506fi
5507
5508
5509if test $ac_cv_have_decl_sys_siglist != yes; then
5510 # For Tru64, at least:
5511 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5512echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5513if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5514 echo $ECHO_N "(cached) $ECHO_C" >&6
5515else
5516 cat >conftest.$ac_ext <<_ACEOF
5517#line $LINENO "configure"
5518/* confdefs.h. */
5519_ACEOF
5520cat confdefs.h >>conftest.$ac_ext
5521cat >>conftest.$ac_ext <<_ACEOF
5522/* end confdefs.h. */
5523$ac_includes_default
503d2be0
AS
5524int
5525main ()
5526{
cd958eb3
MB
5527#ifndef __sys_siglist
5528 char *p = (char *) __sys_siglist;
5529#endif
5530
503d2be0
AS
5531 ;
5532 return 0;
5533}
5534_ACEOF
5535rm -f conftest.$ac_objext
c0d27fcc 5536if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5537 (eval $ac_compile) 2>&5
5538 ac_status=$?
c0d27fcc 5539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5540 (exit $ac_status); } &&
5541 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5542 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5543 (eval $ac_try) 2>&5
5544 ac_status=$?
c0d27fcc 5545 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5546 (exit $ac_status); }; }; then
cd958eb3 5547 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5548else
503d2be0 5549 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5550sed 's/^/| /' conftest.$ac_ext >&5
5551
5552ac_cv_have_decl___sys_siglist=no
ba4481b5 5553fi
503d2be0
AS
5554rm -f conftest.$ac_objext conftest.$ac_ext
5555fi
cd958eb3
MB
5556echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5557echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5558if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5559
cd958eb3
MB
5560cat >>confdefs.h <<_ACEOF
5561#define HAVE_DECL___SYS_SIGLIST 1
5562_ACEOF
5563
5564
5565else
5566 cat >>confdefs.h <<_ACEOF
5567#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5568_ACEOF
503d2be0 5569
cd958eb3 5570
ba4481b5
DL
5571fi
5572
cd958eb3
MB
5573
5574 if test $ac_cv_have_decl___sys_siglist = yes; then
5575
5576cat >>confdefs.h <<\_ACEOF
5577#define sys_siglist __sys_siglist
5578_ACEOF
5579
5580 fi
5581fi
c0d27fcc 5582echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5583echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5584if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5585 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5586else
503d2be0 5587 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5588#line $LINENO "configure"
cd958eb3
MB
5589/* confdefs.h. */
5590_ACEOF
5591cat confdefs.h >>conftest.$ac_ext
5592cat >>conftest.$ac_ext <<_ACEOF
5593/* end confdefs.h. */
98418dba
CW
5594#include <sys/types.h>
5595#include <sys/wait.h>
5596#ifndef WEXITSTATUS
5597# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5598#endif
5599#ifndef WIFEXITED
5600# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5601#endif
503d2be0
AS
5602
5603int
5604main ()
5605{
98418dba
CW
5606 int s;
5607 wait (&s);
5608 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5609 ;
5610 return 0;
5611}
5612_ACEOF
98418dba 5613rm -f conftest.$ac_objext
c0d27fcc 5614if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 5615 (eval $ac_compile) 2>&5
503d2be0 5616 ac_status=$?
c0d27fcc 5617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5618 (exit $ac_status); } &&
98418dba 5619 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5620 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5621 (eval $ac_try) 2>&5
5622 ac_status=$?
c0d27fcc 5623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5624 (exit $ac_status); }; }; then
98418dba 5625 ac_cv_header_sys_wait_h=yes
ba4481b5 5626else
503d2be0 5627 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5628sed 's/^/| /' conftest.$ac_ext >&5
5629
98418dba 5630ac_cv_header_sys_wait_h=no
ba4481b5 5631fi
98418dba 5632rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5633fi
c0d27fcc 5634echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5635echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5636if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5637
c0d27fcc 5638cat >>confdefs.h <<\_ACEOF
98418dba 5639#define HAVE_SYS_WAIT_H 1
c0d27fcc 5640_ACEOF
ba4481b5 5641
ba4481b5
DL
5642fi
5643
c0d27fcc
MR
5644
5645echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5646echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5647if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5648 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5649else
503d2be0 5650 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5651#line $LINENO "configure"
cd958eb3
MB
5652/* confdefs.h. */
5653_ACEOF
5654cat confdefs.h >>conftest.$ac_ext
5655cat >>conftest.$ac_ext <<_ACEOF
5656/* end confdefs.h. */
98418dba
CW
5657#ifdef TIME_WITH_SYS_TIME
5658#include <sys/time.h>
5659#include <time.h>
5660#else
5661#ifdef HAVE_SYS_TIME_H
5662#include <sys/time.h>
5663#else
1113b624 5664#include <time.h>
98418dba
CW
5665#endif
5666#endif
5667#ifdef HAVE_UTIME_H
5668#include <utime.h>
5669#endif
503d2be0
AS
5670int
5671main ()
5672{
98418dba 5673static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5674 ;
5675 return 0;
5676}
5677_ACEOF
98418dba 5678rm -f conftest.$ac_objext
c0d27fcc 5679if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 5680 (eval $ac_compile) 2>&5
503d2be0 5681 ac_status=$?
c0d27fcc 5682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5683 (exit $ac_status); } &&
98418dba 5684 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5685 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5686 (eval $ac_try) 2>&5
5687 ac_status=$?
c0d27fcc 5688 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5689 (exit $ac_status); }; }; then
98418dba 5690 emacs_cv_struct_utimbuf=yes
1113b624 5691else
503d2be0 5692 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5693sed 's/^/| /' conftest.$ac_ext >&5
5694
98418dba 5695emacs_cv_struct_utimbuf=no
1113b624 5696fi
98418dba 5697rm -f conftest.$ac_objext conftest.$ac_ext
1113b624 5698fi
c0d27fcc 5699echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
5700echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
5701if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 5702
c0d27fcc 5703cat >>confdefs.h <<\_ACEOF
98418dba 5704#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 5705_ACEOF
1113b624
PE
5706
5707fi
ba4481b5 5708
c0d27fcc 5709echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
5710echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5711if test "${ac_cv_type_signal+set}" = set; then
503d2be0 5712 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5713else
98418dba 5714 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5715#line $LINENO "configure"
cd958eb3
MB
5716/* confdefs.h. */
5717_ACEOF
5718cat confdefs.h >>conftest.$ac_ext
5719cat >>conftest.$ac_ext <<_ACEOF
5720/* end confdefs.h. */
7397acc4 5721#include <sys/types.h>
98418dba
CW
5722#include <signal.h>
5723#ifdef signal
5724# undef signal
5725#endif
5726#ifdef __cplusplus
5727extern "C" void (*signal (int, void (*)(int)))(int);
5728#else
5729void (*signal ()) ();
5730#endif
5731
503d2be0
AS
5732int
5733main ()
5734{
98418dba 5735int i;
503d2be0
AS
5736 ;
5737 return 0;
5738}
5739_ACEOF
98418dba 5740rm -f conftest.$ac_objext
c0d27fcc 5741if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5742 (eval $ac_compile) 2>&5
5743 ac_status=$?
c0d27fcc 5744 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5745 (exit $ac_status); } &&
5746 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5747 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5748 (eval $ac_try) 2>&5
5749 ac_status=$?
c0d27fcc 5750 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5751 (exit $ac_status); }; }; then
98418dba 5752 ac_cv_type_signal=void
503d2be0
AS
5753else
5754 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5755sed 's/^/| /' conftest.$ac_ext >&5
5756
98418dba 5757ac_cv_type_signal=int
503d2be0 5758fi
98418dba 5759rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5760fi
c0d27fcc 5761echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 5762echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 5763
c0d27fcc 5764cat >>confdefs.h <<_ACEOF
98418dba 5765#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
5766_ACEOF
5767
503d2be0 5768
c0d27fcc
MR
5769
5770echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
5771echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
5772if test "${emacs_cv_speed_t+set}" = set; then
5773 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5774else
98418dba 5775 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5776#line $LINENO "configure"
cd958eb3
MB
5777/* confdefs.h. */
5778_ACEOF
5779cat confdefs.h >>conftest.$ac_ext
5780cat >>conftest.$ac_ext <<_ACEOF
5781/* end confdefs.h. */
98418dba 5782#include <termios.h>
98418dba
CW
5783int
5784main ()
5785{
5786speed_t x = 1;
5787 ;
5788 return 0;
5789}
5790_ACEOF
5791rm -f conftest.$ac_objext
c0d27fcc 5792if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
5793 (eval $ac_compile) 2>&5
5794 ac_status=$?
c0d27fcc 5795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5796 (exit $ac_status); } &&
5797 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5798 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
5799 (eval $ac_try) 2>&5
5800 ac_status=$?
c0d27fcc 5801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5802 (exit $ac_status); }; }; then
5803 emacs_cv_speed_t=yes
5804else
5805 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5806sed 's/^/| /' conftest.$ac_ext >&5
5807
98418dba
CW
5808emacs_cv_speed_t=no
5809fi
5810rm -f conftest.$ac_objext conftest.$ac_ext
5811fi
c0d27fcc 5812echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
5813echo "${ECHO_T}$emacs_cv_speed_t" >&6
5814if test $emacs_cv_speed_t = yes; then
b936fae4 5815
c0d27fcc 5816cat >>confdefs.h <<\_ACEOF
98418dba 5817#define HAVE_SPEED_T 1
c0d27fcc 5818_ACEOF
98418dba 5819
7397acc4
DL
5820fi
5821
c0d27fcc 5822echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
5823echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
5824if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 5825 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5826else
503d2be0 5827 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5828#line $LINENO "configure"
cd958eb3
MB
5829/* confdefs.h. */
5830_ACEOF
5831cat confdefs.h >>conftest.$ac_ext
5832cat >>conftest.$ac_ext <<_ACEOF
5833/* end confdefs.h. */
98418dba
CW
5834#ifdef TIME_WITH_SYS_TIME
5835#include <sys/time.h>
5836#include <time.h>
5837#else
5838#ifdef HAVE_SYS_TIME_H
5839#include <sys/time.h>
5840#else
5841#include <time.h>
5842#endif
5843#endif
503d2be0
AS
5844int
5845main ()
5846{
98418dba 5847static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
5848 ;
5849 return 0;
5850}
5851_ACEOF
5852rm -f conftest.$ac_objext
c0d27fcc 5853if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5854 (eval $ac_compile) 2>&5
5855 ac_status=$?
c0d27fcc 5856 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5857 (exit $ac_status); } &&
5858 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5859 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5860 (eval $ac_try) 2>&5
5861 ac_status=$?
c0d27fcc 5862 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5863 (exit $ac_status); }; }; then
98418dba 5864 emacs_cv_struct_timeval=yes
7397acc4 5865else
503d2be0 5866 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5867sed 's/^/| /' conftest.$ac_ext >&5
5868
98418dba 5869emacs_cv_struct_timeval=no
7397acc4 5870fi
503d2be0 5871rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5872fi
c0d27fcc 5873echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
5874echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
5875HAVE_TIMEVAL=$emacs_cv_struct_timeval
5876if test $emacs_cv_struct_timeval = yes; then
b936fae4 5877
c0d27fcc 5878cat >>confdefs.h <<\_ACEOF
98418dba 5879#define HAVE_TIMEVAL 1
c0d27fcc 5880_ACEOF
7397acc4
DL
5881
5882fi
5883
c0d27fcc 5884echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
5885echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
5886if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 5887 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5888else
503d2be0 5889 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5890#line $LINENO "configure"
cd958eb3
MB
5891/* confdefs.h. */
5892_ACEOF
5893cat confdefs.h >>conftest.$ac_ext
5894cat >>conftest.$ac_ext <<_ACEOF
5895/* end confdefs.h. */
98418dba 5896#include <math.h>
503d2be0
AS
5897int
5898main ()
5899{
98418dba 5900static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
5901 ;
5902 return 0;
ba4481b5 5903}
503d2be0
AS
5904_ACEOF
5905rm -f conftest.$ac_objext
c0d27fcc 5906if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5907 (eval $ac_compile) 2>&5
5908 ac_status=$?
c0d27fcc 5909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5910 (exit $ac_status); } &&
5911 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5912 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5913 (eval $ac_try) 2>&5
5914 ac_status=$?
c0d27fcc 5915 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5916 (exit $ac_status); }; }; then
98418dba 5917 emacs_cv_struct_exception=yes
ba4481b5 5918else
503d2be0 5919 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5920sed 's/^/| /' conftest.$ac_ext >&5
5921
98418dba 5922emacs_cv_struct_exception=no
ba4481b5 5923fi
503d2be0 5924rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5925fi
c0d27fcc 5926echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
5927echo "${ECHO_T}$emacs_cv_struct_exception" >&6
5928HAVE_EXCEPTION=$emacs_cv_struct_exception
5929if test $emacs_cv_struct_exception != yes; then
b936fae4 5930
c0d27fcc 5931cat >>confdefs.h <<\_ACEOF
98418dba 5932#define NO_MATHERR 1
c0d27fcc 5933_ACEOF
ba4481b5
DL
5934
5935fi
5936
c0d27fcc 5937echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
5938echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
5939if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 5940 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5941else
503d2be0 5942 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5943#line $LINENO "configure"
cd958eb3
MB
5944/* confdefs.h. */
5945_ACEOF
5946cat confdefs.h >>conftest.$ac_ext
5947cat >>conftest.$ac_ext <<_ACEOF
5948/* end confdefs.h. */
98418dba
CW
5949#include <sys/types.h>
5950#include <time.h>
7397acc4 5951
503d2be0
AS
5952int
5953main ()
5954{
98418dba 5955struct tm *tp; tp->tm_sec;
503d2be0
AS
5956 ;
5957 return 0;
5958}
5959_ACEOF
5960rm -f conftest.$ac_objext
c0d27fcc 5961if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5962 (eval $ac_compile) 2>&5
5963 ac_status=$?
c0d27fcc 5964 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5965 (exit $ac_status); } &&
5966 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5967 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5968 (eval $ac_try) 2>&5
5969 ac_status=$?
c0d27fcc 5970 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5971 (exit $ac_status); }; }; then
98418dba 5972 ac_cv_struct_tm=time.h
7397acc4 5973else
503d2be0 5974 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5975sed 's/^/| /' conftest.$ac_ext >&5
5976
98418dba 5977ac_cv_struct_tm=sys/time.h
7397acc4 5978fi
503d2be0 5979rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5980fi
c0d27fcc 5981echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
5982echo "${ECHO_T}$ac_cv_struct_tm" >&6
5983if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 5984
c0d27fcc 5985cat >>confdefs.h <<\_ACEOF
98418dba 5986#define TM_IN_SYS_TIME 1
c0d27fcc 5987_ACEOF
7397acc4
DL
5988
5989fi
ba4481b5 5990
c0d27fcc 5991echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
5992echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
5993if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 5994 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5995else
98418dba 5996 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5997#line $LINENO "configure"
cd958eb3
MB
5998/* confdefs.h. */
5999_ACEOF
6000cat confdefs.h >>conftest.$ac_ext
6001cat >>conftest.$ac_ext <<_ACEOF
6002/* end confdefs.h. */
98418dba
CW
6003#include <sys/types.h>
6004#include <$ac_cv_struct_tm>
ba4481b5 6005
c0d27fcc 6006
98418dba
CW
6007int
6008main ()
6009{
6010static struct tm ac_aggr;
6011if (ac_aggr.tm_zone)
6012return 0;
6013 ;
6014 return 0;
6015}
6016_ACEOF
6017rm -f conftest.$ac_objext
c0d27fcc 6018if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6019 (eval $ac_compile) 2>&5
6020 ac_status=$?
c0d27fcc 6021 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6022 (exit $ac_status); } &&
6023 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6024 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6025 (eval $ac_try) 2>&5
6026 ac_status=$?
c0d27fcc 6027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6028 (exit $ac_status); }; }; then
6029 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6030else
98418dba 6031 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6032sed 's/^/| /' conftest.$ac_ext >&5
6033
6bae0ccf
DL
6034cat >conftest.$ac_ext <<_ACEOF
6035#line $LINENO "configure"
cd958eb3
MB
6036/* confdefs.h. */
6037_ACEOF
6038cat confdefs.h >>conftest.$ac_ext
6039cat >>conftest.$ac_ext <<_ACEOF
6040/* end confdefs.h. */
6bae0ccf
DL
6041#include <sys/types.h>
6042#include <$ac_cv_struct_tm>
6043
6044
6045int
6046main ()
6047{
6048static struct tm ac_aggr;
6049if (sizeof ac_aggr.tm_zone)
6050return 0;
6051 ;
6052 return 0;
6053}
6054_ACEOF
6055rm -f conftest.$ac_objext
6056if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6057 (eval $ac_compile) 2>&5
6058 ac_status=$?
6059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6060 (exit $ac_status); } &&
6061 { ac_try='test -s conftest.$ac_objext'
6062 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6063 (eval $ac_try) 2>&5
6064 ac_status=$?
6065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6066 (exit $ac_status); }; }; then
6067 ac_cv_member_struct_tm_tm_zone=yes
6068else
6069 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6070sed 's/^/| /' conftest.$ac_ext >&5
6071
98418dba 6072ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6073fi
98418dba 6074rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 6075fi
6bae0ccf
DL
6076rm -f conftest.$ac_objext conftest.$ac_ext
6077fi
c0d27fcc 6078echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6079echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6080if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6081
c0d27fcc 6082cat >>confdefs.h <<_ACEOF
98418dba 6083#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6084_ACEOF
6085
ba4481b5 6086
98418dba 6087fi
ba4481b5 6088
98418dba 6089if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6090
c0d27fcc 6091cat >>confdefs.h <<\_ACEOF
98418dba 6092#define HAVE_TM_ZONE 1
c0d27fcc 6093_ACEOF
ba4481b5 6094
ba4481b5 6095else
c0d27fcc 6096 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6097echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6098if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6099 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6100else
98418dba 6101 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6102#line $LINENO "configure"
cd958eb3
MB
6103/* confdefs.h. */
6104_ACEOF
6105cat confdefs.h >>conftest.$ac_ext
6106cat >>conftest.$ac_ext <<_ACEOF
6107/* end confdefs.h. */
98418dba
CW
6108#include <time.h>
6109#ifndef tzname /* For SGI. */
6110extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6111#endif
6112
98418dba
CW
6113int
6114main ()
6115{
6116atoi(*tzname);
6117 ;
6118 return 0;
6119}
6120_ACEOF
6121rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6122if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6123 (eval $ac_link) 2>&5
6124 ac_status=$?
c0d27fcc 6125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6126 (exit $ac_status); } &&
6127 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6128 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6129 (eval $ac_try) 2>&5
6130 ac_status=$?
c0d27fcc 6131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6132 (exit $ac_status); }; }; then
6133 ac_cv_var_tzname=yes
6134else
6135 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6136sed 's/^/| /' conftest.$ac_ext >&5
6137
98418dba 6138ac_cv_var_tzname=no
ba4481b5 6139fi
98418dba
CW
6140rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6141fi
c0d27fcc 6142echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6143echo "${ECHO_T}$ac_cv_var_tzname" >&6
6144 if test $ac_cv_var_tzname = yes; then
ba4481b5 6145
c0d27fcc 6146cat >>confdefs.h <<\_ACEOF
98418dba 6147#define HAVE_TZNAME 1
c0d27fcc 6148_ACEOF
503d2be0 6149
98418dba
CW
6150 fi
6151fi
503d2be0 6152
c0d27fcc 6153echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6154echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6155if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6156 echo $ECHO_N "(cached) $ECHO_C" >&6
6157else
6158 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6159#line $LINENO "configure"
cd958eb3
MB
6160/* confdefs.h. */
6161_ACEOF
6162cat confdefs.h >>conftest.$ac_ext
6163cat >>conftest.$ac_ext <<_ACEOF
6164/* end confdefs.h. */
98418dba 6165#include <time.h>
b936fae4 6166
98418dba
CW
6167int
6168main ()
6169{
b936fae4
AS
6170static struct tm ac_aggr;
6171if (ac_aggr.tm_gmtoff)
6172return 0;
98418dba
CW
6173 ;
6174 return 0;
6175}
6176_ACEOF
b936fae4 6177rm -f conftest.$ac_objext
c0d27fcc 6178if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4 6179 (eval $ac_compile) 2>&5
98418dba 6180 ac_status=$?
c0d27fcc 6181 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6182 (exit $ac_status); } &&
b936fae4 6183 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6184 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6185 (eval $ac_try) 2>&5
6186 ac_status=$?
c0d27fcc 6187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6188 (exit $ac_status); }; }; then
b936fae4 6189 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6190else
6191 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6192sed 's/^/| /' conftest.$ac_ext >&5
6193
8799b3e4 6194cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6195#line $LINENO "configure"
cd958eb3
MB
6196/* confdefs.h. */
6197_ACEOF
6198cat confdefs.h >>conftest.$ac_ext
6199cat >>conftest.$ac_ext <<_ACEOF
6200/* end confdefs.h. */
6bae0ccf
DL
6201#include <time.h>
6202
8799b3e4
CW
6203int
6204main ()
6205{
6bae0ccf
DL
6206static struct tm ac_aggr;
6207if (sizeof ac_aggr.tm_gmtoff)
6208return 0;
8799b3e4
CW
6209 ;
6210 return 0;
6211}
6212_ACEOF
6bae0ccf 6213rm -f conftest.$ac_objext
c0d27fcc 6214if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8799b3e4
CW
6215 (eval $ac_compile) 2>&5
6216 ac_status=$?
c0d27fcc 6217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4
CW
6218 (exit $ac_status); } &&
6219 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6221 (eval $ac_try) 2>&5
6222 ac_status=$?
c0d27fcc 6223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6224 (exit $ac_status); }; }; then
6bae0ccf 6225 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6226else
6227 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6228sed 's/^/| /' conftest.$ac_ext >&5
6229
6bae0ccf 6230ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6231fi
6bae0ccf
DL
6232rm -f conftest.$ac_objext conftest.$ac_ext
6233fi
6234rm -f conftest.$ac_objext conftest.$ac_ext
8799b3e4 6235fi
6bae0ccf
DL
6236echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6237echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6238if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6239
6240cat >>confdefs.h <<\_ACEOF
6241#define HAVE_TM_GMTOFF 1
6242_ACEOF
6243
6244fi
6245
8799b3e4 6246
8799b3e4 6247
c0d27fcc 6248echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
6249echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
6250if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 6251 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
6252echo "${ECHO_T}yes" >&6
6253
c0d27fcc 6254cat >>confdefs.h <<\_ACEOF
98418dba 6255#define PROTOTYPES 1
c0d27fcc
MR
6256_ACEOF
6257
6258
6259cat >>confdefs.h <<\_ACEOF
6260#define __PROTOTYPES 1
6261_ACEOF
98418dba
CW
6262
6263else
c0d27fcc 6264 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
6265echo "${ECHO_T}no" >&6
6266fi
6267
c0d27fcc 6268echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
6269echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
6270if test "${ac_cv_c_volatile+set}" = set; then
6271 echo $ECHO_N "(cached) $ECHO_C" >&6
6272else
6273 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6274#line $LINENO "configure"
cd958eb3
MB
6275/* confdefs.h. */
6276_ACEOF
6277cat confdefs.h >>conftest.$ac_ext
6278cat >>conftest.$ac_ext <<_ACEOF
6279/* end confdefs.h. */
98418dba 6280
98418dba
CW
6281int
6282main ()
6283{
6284
6285volatile int x;
6286int * volatile y;
6287 ;
6288 return 0;
6289}
6290_ACEOF
6291rm -f conftest.$ac_objext
c0d27fcc 6292if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6293 (eval $ac_compile) 2>&5
6294 ac_status=$?
c0d27fcc 6295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6296 (exit $ac_status); } &&
6297 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6298 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6299 (eval $ac_try) 2>&5
6300 ac_status=$?
c0d27fcc 6301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6302 (exit $ac_status); }; }; then
6303 ac_cv_c_volatile=yes
6304else
6305 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6306sed 's/^/| /' conftest.$ac_ext >&5
6307
98418dba
CW
6308ac_cv_c_volatile=no
6309fi
6310rm -f conftest.$ac_objext conftest.$ac_ext
6311fi
c0d27fcc 6312echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
6313echo "${ECHO_T}$ac_cv_c_volatile" >&6
6314if test $ac_cv_c_volatile = no; then
6315
c0d27fcc 6316cat >>confdefs.h <<\_ACEOF
98418dba 6317#define volatile
c0d27fcc 6318_ACEOF
98418dba
CW
6319
6320fi
6321
c0d27fcc 6322echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
6323echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
6324if test "${ac_cv_c_const+set}" = set; then
6325 echo $ECHO_N "(cached) $ECHO_C" >&6
6326else
6327 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6328#line $LINENO "configure"
cd958eb3
MB
6329/* confdefs.h. */
6330_ACEOF
6331cat confdefs.h >>conftest.$ac_ext
6332cat >>conftest.$ac_ext <<_ACEOF
6333/* end confdefs.h. */
98418dba 6334
98418dba
CW
6335int
6336main ()
6337{
6338/* FIXME: Include the comments suggested by Paul. */
6339#ifndef __cplusplus
6340 /* Ultrix mips cc rejects this. */
6341 typedef int charset[2];
6342 const charset x;
6343 /* SunOS 4.1.1 cc rejects this. */
6344 char const *const *ccp;
6345 char **p;
6346 /* NEC SVR4.0.2 mips cc rejects this. */
6347 struct point {int x, y;};
6348 static struct point const zero = {0,0};
6349 /* AIX XL C 1.02.0.0 rejects this.
6350 It does not let you subtract one const X* pointer from another in
6351 an arm of an if-expression whose if-part is not a constant
6352 expression */
6353 const char *g = "string";
6354 ccp = &g + (g ? g-g : 0);
6355 /* HPUX 7.0 cc rejects these. */
6356 ++ccp;
6357 p = (char**) ccp;
6358 ccp = (char const *const *) p;
6359 { /* SCO 3.2v4 cc rejects this. */
6360 char *t;
6361 char const *s = 0 ? (char *) 0 : (char const *) 0;
6362
6363 *t++ = 0;
6364 }
6365 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
6366 int x[] = {25, 17};
6367 const int *foo = &x[0];
6368 ++foo;
6369 }
6370 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
6371 typedef const int *iptr;
6372 iptr p = 0;
6373 ++p;
6374 }
6375 { /* AIX XL C 1.02.0.0 rejects this saying
6376 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
6377 struct s { int j; const int *ap[3]; };
6378 struct s *b; b->j = 5;
6379 }
6380 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
6381 const int foo = 10;
6382 }
6383#endif
6384
6385 ;
6386 return 0;
6387}
6388_ACEOF
6389rm -f conftest.$ac_objext
c0d27fcc 6390if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6391 (eval $ac_compile) 2>&5
6392 ac_status=$?
c0d27fcc 6393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6394 (exit $ac_status); } &&
6395 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6396 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6397 (eval $ac_try) 2>&5
6398 ac_status=$?
c0d27fcc 6399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6400 (exit $ac_status); }; }; then
6401 ac_cv_c_const=yes
6402else
6403 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6404sed 's/^/| /' conftest.$ac_ext >&5
6405
98418dba
CW
6406ac_cv_c_const=no
6407fi
6408rm -f conftest.$ac_objext conftest.$ac_ext
6409fi
c0d27fcc 6410echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
6411echo "${ECHO_T}$ac_cv_c_const" >&6
6412if test $ac_cv_c_const = no; then
6413
c0d27fcc 6414cat >>confdefs.h <<\_ACEOF
98418dba 6415#define const
c0d27fcc 6416_ACEOF
98418dba
CW
6417
6418fi
6419
c0d27fcc 6420echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
6421echo $ECHO_N "checking for void * support... $ECHO_C" >&6
6422if test "${emacs_cv_void_star+set}" = set; then
6423 echo $ECHO_N "(cached) $ECHO_C" >&6
6424else
6425 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6426#line $LINENO "configure"
cd958eb3
MB
6427/* confdefs.h. */
6428_ACEOF
6429cat confdefs.h >>conftest.$ac_ext
6430cat >>conftest.$ac_ext <<_ACEOF
6431/* end confdefs.h. */
98418dba 6432
98418dba
CW
6433int
6434main ()
6435{
6436void * foo;
6437 ;
6438 return 0;
6439}
6440_ACEOF
6441rm -f conftest.$ac_objext
c0d27fcc 6442if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6443 (eval $ac_compile) 2>&5
6444 ac_status=$?
c0d27fcc 6445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6446 (exit $ac_status); } &&
6447 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6448 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6449 (eval $ac_try) 2>&5
6450 ac_status=$?
c0d27fcc 6451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6452 (exit $ac_status); }; }; then
6453 emacs_cv_void_star=yes
6454else
6455 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6456sed 's/^/| /' conftest.$ac_ext >&5
6457
98418dba
CW
6458emacs_cv_void_star=no
6459fi
6460rm -f conftest.$ac_objext conftest.$ac_ext
6461fi
c0d27fcc 6462echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
6463echo "${ECHO_T}$emacs_cv_void_star" >&6
6464if test $emacs_cv_void_star = yes; then
c0d27fcc 6465 cat >>confdefs.h <<\_ACEOF
98418dba 6466#define POINTER_TYPE void
c0d27fcc 6467_ACEOF
98418dba
CW
6468
6469else
c0d27fcc 6470 cat >>confdefs.h <<\_ACEOF
98418dba 6471#define POINTER_TYPE char
c0d27fcc 6472_ACEOF
98418dba
CW
6473
6474fi
6475
c0d27fcc 6476
cd958eb3
MB
6477
6478echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
6479echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
98418dba
CW
6480set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
6481if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
6482 echo $ECHO_N "(cached) $ECHO_C" >&6
6483else
c0d27fcc 6484 cat >conftest.make <<\_ACEOF
98418dba 6485all:
cd958eb3 6486 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 6487_ACEOF
98418dba
CW
6488# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6489eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
6490if test -n "$ac_maketemp"; then
6491 eval ac_cv_prog_make_${ac_make}_set=yes
6492else
6493 eval ac_cv_prog_make_${ac_make}_set=no
6494fi
6495rm -f conftest.make
6496fi
6497if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 6498 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
6499echo "${ECHO_T}yes" >&6
6500 SET_MAKE=
6501else
c0d27fcc 6502 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
6503echo "${ECHO_T}no" >&6
6504 SET_MAKE="MAKE=${MAKE-make}"
6505fi
6506
c0d27fcc
MR
6507
6508echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
6509echo $ECHO_N "checking for long file names... $ECHO_C" >&6
6510if test "${ac_cv_sys_long_file_names+set}" = set; then
6511 echo $ECHO_N "(cached) $ECHO_C" >&6
6512else
6513 ac_cv_sys_long_file_names=yes
6514# Test for long file names in all the places we know might matter:
6515# . the current directory, where building will happen
6516# $prefix/lib where we will be installing things
6517# $exec_prefix/lib likewise
6518# eval it to expand exec_prefix.
6519# $TMPDIR if set, where it might want to write temporary files
6520# if $TMPDIR is not set:
6521# /tmp where it might want to write temporary files
6522# /var/tmp likewise
6523# /usr/tmp likewise
6524if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
6525 ac_tmpdirs=$TMPDIR
6526else
6527 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
6528fi
6529for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
6530 test -d $ac_dir || continue
6531 test -w $ac_dir || continue # It is less confusing to not echo anything here.
6532 ac_xdir=$ac_dir/cf$$
6533 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
6534 ac_tf1=$ac_xdir/conftest9012345
6535 ac_tf2=$ac_xdir/conftest9012346
6536 (echo 1 >$ac_tf1) 2>/dev/null
6537 (echo 2 >$ac_tf2) 2>/dev/null
6538 ac_val=`cat $ac_tf1 2>/dev/null`
6539 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
6540 ac_cv_sys_long_file_names=no
6541 rm -rf $ac_xdir 2>/dev/null
6542 break
6543 fi
6544 rm -rf $ac_xdir 2>/dev/null
6545done
6546fi
c0d27fcc 6547echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
6548echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
6549if test $ac_cv_sys_long_file_names = yes; then
6550
c0d27fcc 6551cat >>confdefs.h <<\_ACEOF
98418dba 6552#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 6553_ACEOF
98418dba
CW
6554
6555fi
6556
c0d27fcc 6557
98418dba
CW
6558#### Choose a window system.
6559
c0d27fcc 6560echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
6561echo $ECHO_N "checking for X... $ECHO_C" >&6
6562
c0d27fcc 6563
98418dba
CW
6564# Check whether --with-x or --without-x was given.
6565if test "${with_x+set}" = set; then
6566 withval="$with_x"
6567
6568fi;
6569# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
6570if test "x$with_x" = xno; then
6571 # The user explicitly disabled X.
6572 have_x=disabled
6573else
6574 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
6575 # Both variables are already set.
6576 have_x=yes
6577 else
6578 if test "${ac_cv_have_x+set}" = set; then
6579 echo $ECHO_N "(cached) $ECHO_C" >&6
6580else
6581 # One or both of the vars are not set, and there is no cached value.
6582ac_x_includes=no ac_x_libraries=no
6583rm -fr conftest.dir
6584if mkdir conftest.dir; then
6585 cd conftest.dir
6586 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 6587 cat >Imakefile <<'_ACEOF'
98418dba
CW
6588acfindx:
6589 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 6590_ACEOF
98418dba
CW
6591 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
6592 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6593 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
6594 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
6595 for ac_extension in a so sl; do
6596 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
6597 test -f $ac_im_libdir/libX11.$ac_extension; then
6598 ac_im_usrlibdir=$ac_im_libdir; break
6599 fi
6600 done
6601 # Screen out bogus values from the imake configuration. They are
6602 # bogus both because they are the default anyway, and because
6603 # using them would break gcc on systems where it needs fixed includes.
6604 case $ac_im_incroot in
6605 /usr/include) ;;
6606 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
6607 esac
6608 case $ac_im_usrlibdir in
6609 /usr/lib | /lib) ;;
6610 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
6611 esac
6612 fi
6613 cd ..
6614 rm -fr conftest.dir
6615fi
6616
6617# Standard set of common directories for X headers.
6618# Check X11 before X11Rn because it is often a symlink to the current release.
6619ac_x_header_dirs='
6620/usr/X11/include
6621/usr/X11R6/include
6622/usr/X11R5/include
6623/usr/X11R4/include
6624
6625/usr/include/X11
6626/usr/include/X11R6
6627/usr/include/X11R5
6628/usr/include/X11R4
6629
6630/usr/local/X11/include
6631/usr/local/X11R6/include
6632/usr/local/X11R5/include
6633/usr/local/X11R4/include
6634
6635/usr/local/include/X11
6636/usr/local/include/X11R6
6637/usr/local/include/X11R5
6638/usr/local/include/X11R4
6639
6640/usr/X386/include
6641/usr/x386/include
6642/usr/XFree86/include/X11
6643
6644/usr/include
6645/usr/local/include
6646/usr/unsupported/include
6647/usr/athena/include
6648/usr/local/x11r5/include
6649/usr/lpp/Xamples/include
6650
6651/usr/openwin/include
6652/usr/openwin/share/include'
6653
6654if test "$ac_x_includes" = no; then
6655 # Guess where to find include files, by looking for Intrinsic.h.
6656 # First, try using that file with no special directory specified.
6657 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6658#line $LINENO "configure"
cd958eb3
MB
6659/* confdefs.h. */
6660_ACEOF
6661cat confdefs.h >>conftest.$ac_ext
6662cat >>conftest.$ac_ext <<_ACEOF
6663/* end confdefs.h. */
98418dba
CW
6664#include <X11/Intrinsic.h>
6665_ACEOF
c0d27fcc 6666if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
6667 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6668 ac_status=$?
6bae0ccf 6669 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
6670 rm -f conftest.er1
6671 cat conftest.err >&5
c0d27fcc 6672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6673 (exit $ac_status); } >/dev/null; then
6674 if test -s conftest.err; then
6675 ac_cpp_err=$ac_c_preproc_warn_flag
6676 else
6677 ac_cpp_err=
6678 fi
6679else
6680 ac_cpp_err=yes
6681fi
6682if test -z "$ac_cpp_err"; then
6683 # We can compile using X headers with no special include directory.
6684ac_x_includes=
6685else
6686 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6687sed 's/^/| /' conftest.$ac_ext >&5
6688
98418dba
CW
6689 for ac_dir in $ac_x_header_dirs; do
6690 if test -r "$ac_dir/X11/Intrinsic.h"; then
6691 ac_x_includes=$ac_dir
6692 break
6693 fi
6694done
6695fi
6696rm -f conftest.err conftest.$ac_ext
6697fi # $ac_x_includes = no
6698
6699if test "$ac_x_libraries" = no; then
6700 # Check for the libraries.
6701 # See if we find them without any special options.
6702 # Don't add to $LIBS permanently.
6703 ac_save_LIBS=$LIBS
6704 LIBS="-lXt $LIBS"
6705 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6706#line $LINENO "configure"
cd958eb3
MB
6707/* confdefs.h. */
6708_ACEOF
6709cat confdefs.h >>conftest.$ac_ext
6710cat >>conftest.$ac_ext <<_ACEOF
6711/* end confdefs.h. */
98418dba 6712#include <X11/Intrinsic.h>
98418dba
CW
6713int
6714main ()
6715{
6716XtMalloc (0)
6717 ;
6718 return 0;
6719}
6720_ACEOF
6721rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6722if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6723 (eval $ac_link) 2>&5
6724 ac_status=$?
c0d27fcc 6725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6726 (exit $ac_status); } &&
6727 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6728 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6729 (eval $ac_try) 2>&5
6730 ac_status=$?
c0d27fcc 6731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6732 (exit $ac_status); }; }; then
6733 LIBS=$ac_save_LIBS
6734# We can link X programs with no special library path.
6735ac_x_libraries=
6736else
6737 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6738sed 's/^/| /' conftest.$ac_ext >&5
6739
98418dba
CW
6740LIBS=$ac_save_LIBS
6741for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
6742do
6743 # Don't even attempt the hair of trying to link an X program!
6744 for ac_extension in a so sl; do
6745 if test -r $ac_dir/libXt.$ac_extension; then
6746 ac_x_libraries=$ac_dir
6747 break 2
6748 fi
6749 done
6750done
6751fi
6752rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6753fi # $ac_x_libraries = no
6754
6755if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
6756 # Didn't find X anywhere. Cache the known absence of X.
6757 ac_cv_have_x="have_x=no"
6758else
6759 # Record where we found X for the cache.
6760 ac_cv_have_x="have_x=yes \
6761 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
6762fi
6763fi
6764
6765 fi
6766 eval "$ac_cv_have_x"
6767fi # $with_x != no
6768
6769if test "$have_x" != yes; then
c0d27fcc 6770 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
6771echo "${ECHO_T}$have_x" >&6
6772 no_x=yes
6773else
6774 # If each of the values was on the command line, it overrides each guess.
6775 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
6776 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
6777 # Update the cache value to reflect the command line values.
6778 ac_cv_have_x="have_x=yes \
6779 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
c0d27fcc 6780 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
98418dba
CW
6781echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
6782fi
6783
6784if test "$no_x" = yes; then
6785 window_system=none
6786else
6787 window_system=x11
6788fi
6789
6790if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
6791 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
6792 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
6793 x_default_search_path=""
6794 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
6795 x_search_path="\
6796${x_library}/X11/%L/%T/%N%C%S:\
6797${x_library}/X11/%l/%T/%N%C%S:\
6798${x_library}/X11/%T/%N%C%S:\
6799${x_library}/X11/%L/%T/%N%S:\
6800${x_library}/X11/%l/%T/%N%S:\
6801${x_library}/X11/%T/%N%S"
6802 if test x"${x_default_search_path}" = x; then
6803 x_default_search_path=${x_search_path}
6804 else
6805 x_default_search_path="${x_search_path}:${x_default_search_path}"
6806 fi
6807 done
6808fi
6809if test "${x_includes}" != NONE && test -n "${x_includes}"; then
6810 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
6811fi
6812
6813if test x"${x_includes}" = x; then
6814 bitmapdir=/usr/include/X11/bitmaps
6815else
6816 # accumulate include directories that have X11 bitmap subdirectories
6817 bmd_acc="dummyval"
6818 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
6819 if test -d "${bmd}/X11/bitmaps"; then
6820 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
6821 fi
6822 if test -d "${bmd}/bitmaps"; then
6823 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
6824 fi
6825 done
6826 if test ${bmd_acc} != "dummyval"; then
6827 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
6828 fi
6829fi
6830
6831case "${window_system}" in
6832 x11 )
6833 HAVE_X_WINDOWS=yes
6834 HAVE_X11=yes
6835 case "${with_x_toolkit}" in
6836 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
6837 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
6838 gtk ) with_gtk=yes
6839 USE_X_TOOLKIT=none ;;
98418dba
CW
6840 no ) USE_X_TOOLKIT=none ;;
6841 * ) USE_X_TOOLKIT=maybe ;;
6842 esac
6843 ;;
6844 none )
6845 HAVE_X_WINDOWS=no
6846 HAVE_X11=no
6847 USE_X_TOOLKIT=none
6848 ;;
6849esac
6850
6851### If we're using X11, we should use the X menu package.
6852HAVE_MENUS=no
6853case ${HAVE_X11} in
6854 yes ) HAVE_MENUS=yes ;;
6855esac
6856
6857if test "${opsys}" = "hpux9"; then
6858 case "${x_libraries}" in
6859 *X11R4* )
6860 opsysfile="s/hpux9-x11r4.h"
6861 ;;
6862 esac
6863fi
6864
6865if test "${opsys}" = "hpux9shr"; then
6866 case "${x_libraries}" in
6867 *X11R4* )
6868 opsysfile="s/hpux9shxr4.h"
6869 ;;
6870 esac
6871fi
6872
6873### Compute the unexec source name from the object name.
6874UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
6875
6876# Do the opsystem or machine files prohibit the use of the GNU malloc?
6877# Assume not, until told otherwise.
6878GNU_MALLOC=yes
6879doug_lea_malloc=yes
c0d27fcc 6880echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
6881echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
6882if test "${ac_cv_func_malloc_get_state+set}" = set; then
6883 echo $ECHO_N "(cached) $ECHO_C" >&6
6884else
6885 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6886#line $LINENO "configure"
cd958eb3
MB
6887/* confdefs.h. */
6888_ACEOF
6889cat confdefs.h >>conftest.$ac_ext
6890cat >>conftest.$ac_ext <<_ACEOF
6891/* end confdefs.h. */
98418dba 6892/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
6893 which can conflict with char malloc_get_state (); below.
6894 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6895 <limits.h> exists even on freestanding compilers. */
6896#ifdef __STDC__
6897# include <limits.h>
6898#else
6899# include <assert.h>
6900#endif
98418dba
CW
6901/* Override any gcc2 internal prototype to avoid an error. */
6902#ifdef __cplusplus
6903extern "C"
cd958eb3 6904{
98418dba
CW
6905#endif
6906/* We use char because int might match the return type of a gcc2
6907 builtin and then its argument prototype would still apply. */
6908char malloc_get_state ();
98418dba
CW
6909/* The GNU C library defines this for functions which it implements
6910 to always fail with ENOSYS. Some functions are actually named
6911 something starting with __ and the normal name is an alias. */
6912#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
6913choke me
6914#else
cd958eb3
MB
6915char (*f) () = malloc_get_state;
6916#endif
6917#ifdef __cplusplus
6918}
98418dba
CW
6919#endif
6920
cd958eb3
MB
6921int
6922main ()
6923{
9e71690e 6924return f != malloc_get_state;
98418dba
CW
6925 ;
6926 return 0;
6927}
6928_ACEOF
6929rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6930if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6931 (eval $ac_link) 2>&5
6932 ac_status=$?
c0d27fcc 6933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6934 (exit $ac_status); } &&
6935 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6936 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6937 (eval $ac_try) 2>&5
6938 ac_status=$?
c0d27fcc 6939 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6940 (exit $ac_status); }; }; then
6941 ac_cv_func_malloc_get_state=yes
6942else
6943 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6944sed 's/^/| /' conftest.$ac_ext >&5
6945
98418dba
CW
6946ac_cv_func_malloc_get_state=no
6947fi
6948rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6949fi
c0d27fcc 6950echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
6951echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
6952if test $ac_cv_func_malloc_get_state = yes; then
6953 :
6954else
6955 doug_lea_malloc=no
6956fi
6957
c0d27fcc 6958echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
6959echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
6960if test "${ac_cv_func_malloc_set_state+set}" = set; then
6961 echo $ECHO_N "(cached) $ECHO_C" >&6
6962else
6963 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6964#line $LINENO "configure"
cd958eb3
MB
6965/* confdefs.h. */
6966_ACEOF
6967cat confdefs.h >>conftest.$ac_ext
6968cat >>conftest.$ac_ext <<_ACEOF
6969/* end confdefs.h. */
98418dba 6970/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
6971 which can conflict with char malloc_set_state (); below.
6972 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6973 <limits.h> exists even on freestanding compilers. */
6974#ifdef __STDC__
6975# include <limits.h>
6976#else
6977# include <assert.h>
6978#endif
98418dba
CW
6979/* Override any gcc2 internal prototype to avoid an error. */
6980#ifdef __cplusplus
6981extern "C"
cd958eb3 6982{
98418dba
CW
6983#endif
6984/* We use char because int might match the return type of a gcc2
6985 builtin and then its argument prototype would still apply. */
6986char malloc_set_state ();
98418dba
CW
6987/* The GNU C library defines this for functions which it implements
6988 to always fail with ENOSYS. Some functions are actually named
6989 something starting with __ and the normal name is an alias. */
6990#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
6991choke me
6992#else
cd958eb3
MB
6993char (*f) () = malloc_set_state;
6994#endif
6995#ifdef __cplusplus
6996}
98418dba
CW
6997#endif
6998
cd958eb3
MB
6999int
7000main ()
7001{
9e71690e 7002return f != malloc_set_state;
98418dba
CW
7003 ;
7004 return 0;
7005}
7006_ACEOF
7007rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7008if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7009 (eval $ac_link) 2>&5
7010 ac_status=$?
c0d27fcc 7011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7012 (exit $ac_status); } &&
7013 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7014 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7015 (eval $ac_try) 2>&5
7016 ac_status=$?
c0d27fcc 7017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7018 (exit $ac_status); }; }; then
7019 ac_cv_func_malloc_set_state=yes
7020else
7021 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7022sed 's/^/| /' conftest.$ac_ext >&5
7023
98418dba
CW
7024ac_cv_func_malloc_set_state=no
7025fi
7026rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7027fi
c0d27fcc 7028echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
7029echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
7030if test $ac_cv_func_malloc_set_state = yes; then
7031 :
7032else
7033 doug_lea_malloc=no
7034fi
7035
c0d27fcc 7036echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
7037echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
7038if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
7039 echo $ECHO_N "(cached) $ECHO_C" >&6
7040else
7041 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7042#line $LINENO "configure"
cd958eb3
MB
7043/* confdefs.h. */
7044_ACEOF
7045cat confdefs.h >>conftest.$ac_ext
7046cat >>conftest.$ac_ext <<_ACEOF
7047/* end confdefs.h. */
98418dba 7048extern void (* __after_morecore_hook)();
98418dba
CW
7049int
7050main ()
7051{
7052__after_morecore_hook = 0
7053 ;
7054 return 0;
7055}
7056_ACEOF
7057rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7058if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7059 (eval $ac_link) 2>&5
7060 ac_status=$?
c0d27fcc 7061 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7062 (exit $ac_status); } &&
7063 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7064 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7065 (eval $ac_try) 2>&5
7066 ac_status=$?
c0d27fcc 7067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7068 (exit $ac_status); }; }; then
7069 emacs_cv_var___after_morecore_hook=yes
7070else
7071 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7072sed 's/^/| /' conftest.$ac_ext >&5
7073
98418dba
CW
7074emacs_cv_var___after_morecore_hook=no
7075fi
7076rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7077fi
c0d27fcc 7078echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
7079echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
7080if test $emacs_cv_var___after_morecore_hook = no; then
7081 doug_lea_malloc=no
7082fi
7083if test "${system_malloc}" = "yes"; then
7084 GNU_MALLOC=no
7085 GNU_MALLOC_reason="
7086 (The GNU allocators don't work with this system configuration.)"
7087fi
7088if test "$doug_lea_malloc" = "yes" ; then
7089 if test "$GNU_MALLOC" = yes ; then
7090 GNU_MALLOC_reason="
7091 (Using Doug Lea's new malloc from the GNU C Library.)"
7092 fi
b936fae4 7093
c0d27fcc 7094cat >>confdefs.h <<\_ACEOF
98418dba 7095#define DOUG_LEA_MALLOC 1
c0d27fcc 7096_ACEOF
98418dba
CW
7097
7098fi
7099
7100if test x"${REL_ALLOC}" = x; then
7101 REL_ALLOC=${GNU_MALLOC}
7102fi
7103
7104
c0d27fcc
MR
7105
7106
7107for ac_header in stdlib.h unistd.h
98418dba
CW
7108do
7109as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
7110if eval "test \"\${$as_ac_Header+set}\" = set"; then
7111 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
7112echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7113if eval "test \"\${$as_ac_Header+set}\" = set"; then
7114 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
7115fi
7116echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7117echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 7118else
c0d27fcc
MR
7119 # Is the header compilable?
7120echo "$as_me:$LINENO: checking $ac_header usability" >&5
7121echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7122cat >conftest.$ac_ext <<_ACEOF
7123#line $LINENO "configure"
cd958eb3
MB
7124/* confdefs.h. */
7125_ACEOF
7126cat confdefs.h >>conftest.$ac_ext
7127cat >>conftest.$ac_ext <<_ACEOF
7128/* end confdefs.h. */
98418dba
CW
7129$ac_includes_default
7130#include <$ac_header>
7131_ACEOF
7132rm -f conftest.$ac_objext
c0d27fcc 7133if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
7134 (eval $ac_compile) 2>&5
7135 ac_status=$?
c0d27fcc 7136 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7137 (exit $ac_status); } &&
7138 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7139 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7140 (eval $ac_try) 2>&5
7141 ac_status=$?
c0d27fcc 7142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7143 (exit $ac_status); }; }; then
c0d27fcc 7144 ac_header_compiler=yes
98418dba
CW
7145else
7146 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7147sed 's/^/| /' conftest.$ac_ext >&5
7148
c0d27fcc 7149ac_header_compiler=no
98418dba
CW
7150fi
7151rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
7152echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7153echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 7154
c0d27fcc
MR
7155# Is the header present?
7156echo "$as_me:$LINENO: checking $ac_header presence" >&5
7157echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7158cat >conftest.$ac_ext <<_ACEOF
7159#line $LINENO "configure"
cd958eb3
MB
7160/* confdefs.h. */
7161_ACEOF
7162cat confdefs.h >>conftest.$ac_ext
7163cat >>conftest.$ac_ext <<_ACEOF
7164/* end confdefs.h. */
98418dba
CW
7165#include <$ac_header>
7166_ACEOF
c0d27fcc 7167if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
7168 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7169 ac_status=$?
6bae0ccf 7170 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
7171 rm -f conftest.er1
7172 cat conftest.err >&5
c0d27fcc 7173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7174 (exit $ac_status); } >/dev/null; then
7175 if test -s conftest.err; then
7176 ac_cpp_err=$ac_c_preproc_warn_flag
7177 else
7178 ac_cpp_err=
7179 fi
7180else
7181 ac_cpp_err=yes
7182fi
7183if test -z "$ac_cpp_err"; then
c0d27fcc 7184 ac_header_preproc=yes
98418dba
CW
7185else
7186 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7187sed 's/^/| /' conftest.$ac_ext >&5
7188
c0d27fcc 7189 ac_header_preproc=no
98418dba
CW
7190fi
7191rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
7192echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7193echo "${ECHO_T}$ac_header_preproc" >&6
7194
7195# So? What about this header?
7196case $ac_header_compiler:$ac_header_preproc in
7197 yes:no )
7198 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7199echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7200 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
7201echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7202 (
7203 cat <<\_ASBOX
7204## ------------------------------------ ##
7205## Report this to bug-autoconf@gnu.org. ##
7206## ------------------------------------ ##
7207_ASBOX
7208 ) |
7209 sed "s/^/$as_me: WARNING: /" >&2
7210 ;;
c0d27fcc
MR
7211 no:yes )
7212 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7213echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7214 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7215echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7216 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
7217echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7218 (
7219 cat <<\_ASBOX
7220## ------------------------------------ ##
7221## Report this to bug-autoconf@gnu.org. ##
7222## ------------------------------------ ##
7223_ASBOX
7224 ) |
7225 sed "s/^/$as_me: WARNING: /" >&2
7226 ;;
c0d27fcc
MR
7227esac
7228echo "$as_me:$LINENO: checking for $ac_header" >&5
7229echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7230if eval "test \"\${$as_ac_Header+set}\" = set"; then
7231 echo $ECHO_N "(cached) $ECHO_C" >&6
7232else
7233 eval "$as_ac_Header=$ac_header_preproc"
98418dba 7234fi
c0d27fcc 7235echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 7236echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
7237
7238fi
98418dba 7239if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 7240 cat >>confdefs.h <<_ACEOF
98418dba 7241#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 7242_ACEOF
98418dba
CW
7243
7244fi
c0d27fcc 7245
98418dba
CW
7246done
7247
c0d27fcc 7248
98418dba
CW
7249for ac_func in getpagesize
7250do
7251as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 7252echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
7253echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7254if eval "test \"\${$as_ac_var+set}\" = set"; then
7255 echo $ECHO_N "(cached) $ECHO_C" >&6
7256else
7257 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7258#line $LINENO "configure"
cd958eb3
MB
7259/* confdefs.h. */
7260_ACEOF
7261cat confdefs.h >>conftest.$ac_ext
7262cat >>conftest.$ac_ext <<_ACEOF
7263/* end confdefs.h. */
98418dba 7264/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
7265 which can conflict with char $ac_func (); below.
7266 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7267 <limits.h> exists even on freestanding compilers. */
7268#ifdef __STDC__
7269# include <limits.h>
7270#else
7271# include <assert.h>
7272#endif
98418dba
CW
7273/* Override any gcc2 internal prototype to avoid an error. */
7274#ifdef __cplusplus
7275extern "C"
cd958eb3 7276{
98418dba
CW
7277#endif
7278/* We use char because int might match the return type of a gcc2
7279 builtin and then its argument prototype would still apply. */
7280char $ac_func ();
98418dba
CW
7281/* The GNU C library defines this for functions which it implements
7282 to always fail with ENOSYS. Some functions are actually named
7283 something starting with __ and the normal name is an alias. */
7284#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7285choke me
7286#else
cd958eb3
MB
7287char (*f) () = $ac_func;
7288#endif
7289#ifdef __cplusplus
7290}
98418dba
CW
7291#endif
7292
cd958eb3
MB
7293int
7294main ()
7295{
9e71690e 7296return f != $ac_func;
98418dba
CW
7297 ;
7298 return 0;
7299}
7300_ACEOF
7301rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7302if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7303 (eval $ac_link) 2>&5
7304 ac_status=$?
c0d27fcc 7305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7306 (exit $ac_status); } &&
7307 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7308 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7309 (eval $ac_try) 2>&5
7310 ac_status=$?
c0d27fcc 7311 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7312 (exit $ac_status); }; }; then
7313 eval "$as_ac_var=yes"
7314else
7315 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7316sed 's/^/| /' conftest.$ac_ext >&5
7317
98418dba
CW
7318eval "$as_ac_var=no"
7319fi
7320rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7321fi
c0d27fcc 7322echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
7323echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7324if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 7325 cat >>confdefs.h <<_ACEOF
98418dba 7326#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 7327_ACEOF
98418dba
CW
7328
7329fi
7330done
7331
c0d27fcc 7332echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
7333echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
7334if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
7335 echo $ECHO_N "(cached) $ECHO_C" >&6
7336else
7337 if test "$cross_compiling" = yes; then
7338 ac_cv_func_mmap_fixed_mapped=no
7339else
7340 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7341#line $LINENO "configure"
cd958eb3
MB
7342/* confdefs.h. */
7343_ACEOF
7344cat confdefs.h >>conftest.$ac_ext
7345cat >>conftest.$ac_ext <<_ACEOF
7346/* end confdefs.h. */
98418dba 7347$ac_includes_default
c0d27fcc
MR
7348/* malloc might have been renamed as rpl_malloc. */
7349#undef malloc
7350
98418dba
CW
7351/* Thanks to Mike Haertel and Jim Avera for this test.
7352 Here is a matrix of mmap possibilities:
7353 mmap private not fixed
7354 mmap private fixed at somewhere currently unmapped
7355 mmap private fixed at somewhere already mapped
7356 mmap shared not fixed
7357 mmap shared fixed at somewhere currently unmapped
7358 mmap shared fixed at somewhere already mapped
7359 For private mappings, we should verify that changes cannot be read()
7360 back from the file, nor mmap's back from the file at a different
7361 address. (There have been systems where private was not correctly
7362 implemented like the infamous i386 svr4.0, and systems where the
7363 VM page cache was not coherent with the file system buffer cache
7364 like early versions of FreeBSD and possibly contemporary NetBSD.)
7365 For shared mappings, we should conversely verify that changes get
c0d27fcc 7366 propagated back to all the places they're supposed to be.
98418dba
CW
7367
7368 Grep wants private fixed already mapped.
7369 The main things grep needs to know about mmap are:
7370 * does it exist and is it safe to write into the mmap'd area
7371 * how to use it (BSD variants) */
7372
7373#include <fcntl.h>
7374#include <sys/mman.h>
7375
7376#if !STDC_HEADERS && !HAVE_STDLIB_H
7377char *malloc ();
7378#endif
7379
7380/* This mess was copied from the GNU getpagesize.h. */
7381#if !HAVE_GETPAGESIZE
7382/* Assume that all systems that can run configure have sys/param.h. */
7383# if !HAVE_SYS_PARAM_H
7384# define HAVE_SYS_PARAM_H 1
7385# endif
7386
7387# ifdef _SC_PAGESIZE
7388# define getpagesize() sysconf(_SC_PAGESIZE)
7389# else /* no _SC_PAGESIZE */
7390# if HAVE_SYS_PARAM_H
7391# include <sys/param.h>
7392# ifdef EXEC_PAGESIZE
7393# define getpagesize() EXEC_PAGESIZE
7394# else /* no EXEC_PAGESIZE */
7395# ifdef NBPG
7396# define getpagesize() NBPG * CLSIZE
7397# ifndef CLSIZE
7398# define CLSIZE 1
7399# endif /* no CLSIZE */
7400# else /* no NBPG */
7401# ifdef NBPC
7402# define getpagesize() NBPC
7403# else /* no NBPC */
7404# ifdef PAGESIZE
7405# define getpagesize() PAGESIZE
7406# endif /* PAGESIZE */
7407# endif /* no NBPC */
7408# endif /* no NBPG */
7409# endif /* no EXEC_PAGESIZE */
7410# else /* no HAVE_SYS_PARAM_H */
7411# define getpagesize() 8192 /* punt totally */
7412# endif /* no HAVE_SYS_PARAM_H */
7413# endif /* no _SC_PAGESIZE */
7414
7415#endif /* no HAVE_GETPAGESIZE */
7416
7417int
7418main ()
7419{
7420 char *data, *data2, *data3;
7421 int i, pagesize;
7422 int fd;
7423
7424 pagesize = getpagesize ();
7425
7426 /* First, make a file with some known garbage in it. */
7427 data = (char *) malloc (pagesize);
7428 if (!data)
7429 exit (1);
7430 for (i = 0; i < pagesize; ++i)
7431 *(data + i) = rand ();
7432 umask (0);
7433 fd = creat ("conftest.mmap", 0600);
7434 if (fd < 0)
7435 exit (1);
7436 if (write (fd, data, pagesize) != pagesize)
7437 exit (1);
7438 close (fd);
7439
7440 /* Next, try to mmap the file at a fixed address which already has
7441 something else allocated at it. If we can, also make sure that
7442 we see the same garbage. */
7443 fd = open ("conftest.mmap", O_RDWR);
7444 if (fd < 0)
7445 exit (1);
7446 data2 = (char *) malloc (2 * pagesize);
7447 if (!data2)
7448 exit (1);
7449 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
7450 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
7451 MAP_PRIVATE | MAP_FIXED, fd, 0L))
7452 exit (1);
7453 for (i = 0; i < pagesize; ++i)
7454 if (*(data + i) != *(data2 + i))
7455 exit (1);
7456
7457 /* Finally, make sure that changes to the mapped area do not
7458 percolate back to the file as seen by read(). (This is a bug on
7459 some variants of i386 svr4.0.) */
7460 for (i = 0; i < pagesize; ++i)
7461 *(data2 + i) = *(data2 + i) + 1;
7462 data3 = (char *) malloc (pagesize);
7463 if (!data3)
7464 exit (1);
7465 if (read (fd, data3, pagesize) != pagesize)
7466 exit (1);
7467 for (i = 0; i < pagesize; ++i)
7468 if (*(data + i) != *(data3 + i))
7469 exit (1);
7470 close (fd);
7471 exit (0);
7472}
7473_ACEOF
7474rm -f conftest$ac_exeext
c0d27fcc 7475if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7476 (eval $ac_link) 2>&5
7477 ac_status=$?
c0d27fcc 7478 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7479 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 7480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7481 (eval $ac_try) 2>&5
7482 ac_status=$?
c0d27fcc 7483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7484 (exit $ac_status); }; }; then
7485 ac_cv_func_mmap_fixed_mapped=yes
7486else
7487 echo "$as_me: program exited with status $ac_status" >&5
7488echo "$as_me: failed program was:" >&5
cd958eb3
MB
7489sed 's/^/| /' conftest.$ac_ext >&5
7490
c0d27fcc 7491( exit $ac_status )
98418dba
CW
7492ac_cv_func_mmap_fixed_mapped=no
7493fi
6bae0ccf 7494rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
7495fi
7496fi
c0d27fcc 7497echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
7498echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
7499if test $ac_cv_func_mmap_fixed_mapped = yes; then
7500
c0d27fcc 7501cat >>confdefs.h <<\_ACEOF
98418dba 7502#define HAVE_MMAP 1
c0d27fcc 7503_ACEOF
98418dba
CW
7504
7505fi
7506rm -f conftest.mmap
7507
7508if test $use_mmap_for_buffers = yes; then
7509 REL_ALLOC=no
7510fi
7511
7512LIBS="$libsrc_libs $LIBS"
7513
c0d27fcc
MR
7514
7515echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
7516echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
7517if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
7518 echo $ECHO_N "(cached) $ECHO_C" >&6
7519else
7520 ac_check_lib_save_LIBS=$LIBS
7521LIBS="-ldnet $LIBS"
7522cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7523#line $LINENO "configure"
cd958eb3
MB
7524/* confdefs.h. */
7525_ACEOF
7526cat confdefs.h >>conftest.$ac_ext
7527cat >>conftest.$ac_ext <<_ACEOF
7528/* end confdefs.h. */
98418dba
CW
7529
7530/* Override any gcc2 internal prototype to avoid an error. */
7531#ifdef __cplusplus
7532extern "C"
7533#endif
7534/* We use char because int might match the return type of a gcc2
7535 builtin and then its argument prototype would still apply. */
7536char dnet_ntoa ();
98418dba
CW
7537int
7538main ()
7539{
7540dnet_ntoa ();
7541 ;
7542 return 0;
7543}
7544_ACEOF
7545rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7546if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7547 (eval $ac_link) 2>&5
7548 ac_status=$?
c0d27fcc 7549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7550 (exit $ac_status); } &&
7551 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7552 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7553 (eval $ac_try) 2>&5
7554 ac_status=$?
c0d27fcc 7555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7556 (exit $ac_status); }; }; then
7557 ac_cv_lib_dnet_dnet_ntoa=yes
7558else
7559 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7560sed 's/^/| /' conftest.$ac_ext >&5
7561
98418dba
CW
7562ac_cv_lib_dnet_dnet_ntoa=no
7563fi
7564rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7565LIBS=$ac_check_lib_save_LIBS
7566fi
c0d27fcc 7567echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
7568echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
7569if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 7570 cat >>confdefs.h <<_ACEOF
98418dba 7571#define HAVE_LIBDNET 1
c0d27fcc 7572_ACEOF
98418dba
CW
7573
7574 LIBS="-ldnet $LIBS"
7575
7576fi
7577
c0d27fcc
MR
7578
7579echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
7580echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
7581if test "${ac_cv_lib_Xbsd_main+set}" = set; then
7582 echo $ECHO_N "(cached) $ECHO_C" >&6
7583else
7584 ac_check_lib_save_LIBS=$LIBS
7585LIBS="-lXbsd $LIBS"
7586cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7587#line $LINENO "configure"
cd958eb3
MB
7588/* confdefs.h. */
7589_ACEOF
7590cat confdefs.h >>conftest.$ac_ext
7591cat >>conftest.$ac_ext <<_ACEOF
7592/* end confdefs.h. */
98418dba 7593
c0d27fcc 7594
98418dba
CW
7595int
7596main ()
7597{
7598main ();
7599 ;
7600 return 0;
7601}
7602_ACEOF
7603rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7604if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7605 (eval $ac_link) 2>&5
7606 ac_status=$?
c0d27fcc 7607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7608 (exit $ac_status); } &&
7609 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7610 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7611 (eval $ac_try) 2>&5
7612 ac_status=$?
c0d27fcc 7613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7614 (exit $ac_status); }; }; then
7615 ac_cv_lib_Xbsd_main=yes
7616else
7617 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7618sed 's/^/| /' conftest.$ac_ext >&5
7619
98418dba
CW
7620ac_cv_lib_Xbsd_main=no
7621fi
7622rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7623LIBS=$ac_check_lib_save_LIBS
7624fi
c0d27fcc 7625echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
7626echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
7627if test $ac_cv_lib_Xbsd_main = yes; then
7628 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
7629fi
7630
c0d27fcc
MR
7631
7632
7633echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
7634echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
7635if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
7636 echo $ECHO_N "(cached) $ECHO_C" >&6
7637else
7638 ac_check_lib_save_LIBS=$LIBS
7639LIBS="-lpthreads $LIBS"
7640cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7641#line $LINENO "configure"
cd958eb3
MB
7642/* confdefs.h. */
7643_ACEOF
7644cat confdefs.h >>conftest.$ac_ext
7645cat >>conftest.$ac_ext <<_ACEOF
7646/* end confdefs.h. */
98418dba
CW
7647
7648/* Override any gcc2 internal prototype to avoid an error. */
7649#ifdef __cplusplus
7650extern "C"
7651#endif
7652/* We use char because int might match the return type of a gcc2
7653 builtin and then its argument prototype would still apply. */
7654char cma_open ();
98418dba
CW
7655int
7656main ()
7657{
7658cma_open ();
7659 ;
7660 return 0;
7661}
7662_ACEOF
7663rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7664if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7665 (eval $ac_link) 2>&5
7666 ac_status=$?
c0d27fcc 7667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7668 (exit $ac_status); } &&
7669 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7670 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7671 (eval $ac_try) 2>&5
7672 ac_status=$?
c0d27fcc 7673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7674 (exit $ac_status); }; }; then
7675 ac_cv_lib_pthreads_cma_open=yes
7676else
7677 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7678sed 's/^/| /' conftest.$ac_ext >&5
7679
98418dba
CW
7680ac_cv_lib_pthreads_cma_open=no
7681fi
7682rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7683LIBS=$ac_check_lib_save_LIBS
7684fi
c0d27fcc 7685echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
7686echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
7687if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 7688 cat >>confdefs.h <<_ACEOF
98418dba 7689#define HAVE_LIBPTHREADS 1
c0d27fcc 7690_ACEOF
98418dba
CW
7691
7692 LIBS="-lpthreads $LIBS"
7693
7694fi
7695
c0d27fcc
MR
7696
7697echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
7698echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
7699if test -d /usr/X386/include; then
7700 HAVE_XFREE386=yes
7701 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
7702else
7703 HAVE_XFREE386=no
7704fi
c0d27fcc 7705echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
7706echo "${ECHO_T}$HAVE_XFREE386" >&6
7707
ae1a998c
RS
7708# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
7709# used for the tests that follow. We set them back to REAL_CFLAGS and
7710# REAL_CPPFLAGS later on.
98418dba
CW
7711
7712REAL_CPPFLAGS="$CPPFLAGS"
7713
7714if test "${HAVE_X11}" = "yes"; then
7715 DEFS="$C_SWITCH_X_SITE $DEFS"
7716 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
7717 LIBS="$LIBX $LIBS"
7718 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
7719 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
7720
7721 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
7722 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
7723 # but it's more convenient here to set LD_RUN_PATH
7724 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
7725 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
7726 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
7727 export LD_RUN_PATH
7728 fi
7729
7730 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 7731 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
7732echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
7733 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7734#line $LINENO "configure"
cd958eb3
MB
7735/* confdefs.h. */
7736_ACEOF
7737cat confdefs.h >>conftest.$ac_ext
7738cat >>conftest.$ac_ext <<_ACEOF
7739/* end confdefs.h. */
98418dba 7740
98418dba
CW
7741int
7742main ()
7743{
7744XOpenDisplay ("foo");
7745 ;
7746 return 0;
7747}
7748_ACEOF
7749rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7750if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7751 (eval $ac_link) 2>&5
7752 ac_status=$?
c0d27fcc 7753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7754 (exit $ac_status); } &&
7755 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7756 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7757 (eval $ac_try) 2>&5
7758 ac_status=$?
c0d27fcc 7759 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7760 (exit $ac_status); }; }; then
7761 xlinux_first_failure=no
7762else
7763 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7764sed 's/^/| /' conftest.$ac_ext >&5
7765
98418dba
CW
7766xlinux_first_failure=yes
7767fi
7768rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7769 if test "${xlinux_first_failure}" = "yes"; then
7770 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
7771 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
7772 OLD_CPPFLAGS="$CPPFLAGS"
7773 OLD_LIBS="$LIBS"
7774 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
7775 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
7776 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
7777 LIBS="$LIBS -b i486-linuxaout"
7778 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7779#line $LINENO "configure"
cd958eb3
MB
7780/* confdefs.h. */
7781_ACEOF
7782cat confdefs.h >>conftest.$ac_ext
7783cat >>conftest.$ac_ext <<_ACEOF
7784/* end confdefs.h. */
98418dba 7785
98418dba
CW
7786int
7787main ()
7788{
7789XOpenDisplay ("foo");
7790 ;
7791 return 0;
7792}
7793_ACEOF
7794rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7795if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7796 (eval $ac_link) 2>&5
7797 ac_status=$?
c0d27fcc 7798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7799 (exit $ac_status); } &&
7800 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7802 (eval $ac_try) 2>&5
7803 ac_status=$?
c0d27fcc 7804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7805 (exit $ac_status); }; }; then
7806 xlinux_second_failure=no
7807else
7808 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7809sed 's/^/| /' conftest.$ac_ext >&5
7810
98418dba
CW
7811xlinux_second_failure=yes
7812fi
7813rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7814 if test "${xlinux_second_failure}" = "yes"; then
7815 # If we get the same failure with -b, there is no use adding -b.
7816 # So take it out. This plays safe.
7817 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
7818 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
7819 CPPFLAGS="$OLD_CPPFLAGS"
7820 LIBS="$OLD_LIBS"
c0d27fcc 7821 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7822echo "${ECHO_T}no" >&6
7823 else
c0d27fcc 7824 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7825echo "${ECHO_T}yes" >&6
7826 fi
7827 else
c0d27fcc 7828 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7829echo "${ECHO_T}no" >&6
7830 fi
7831 fi
7832
7833 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
7834 # header files included from there.
c0d27fcc 7835 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
7836echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
7837 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7838#line $LINENO "configure"
cd958eb3
MB
7839/* confdefs.h. */
7840_ACEOF
7841cat confdefs.h >>conftest.$ac_ext
7842cat >>conftest.$ac_ext <<_ACEOF
7843/* end confdefs.h. */
98418dba
CW
7844#include <X11/Xlib.h>
7845#include <X11/XKBlib.h>
98418dba
CW
7846int
7847main ()
7848{
7849XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
7850 ;
7851 return 0;
7852}
7853_ACEOF
7854rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7855if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7856 (eval $ac_link) 2>&5
7857 ac_status=$?
c0d27fcc 7858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7859 (exit $ac_status); } &&
7860 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7861 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7862 (eval $ac_try) 2>&5
7863 ac_status=$?
c0d27fcc 7864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7865 (exit $ac_status); }; }; then
7866 emacs_xkb=yes
7867else
7868 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7869sed 's/^/| /' conftest.$ac_ext >&5
7870
98418dba
CW
7871emacs_xkb=no
7872fi
7873rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
c0d27fcc 7874 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
7875echo "${ECHO_T}$emacs_xkb" >&6
7876 if test $emacs_xkb = yes; then
b936fae4 7877
c0d27fcc 7878cat >>confdefs.h <<\_ACEOF
98418dba 7879#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 7880_ACEOF
98418dba
CW
7881
7882 fi
7883
c0d27fcc
MR
7884
7885
7886
7887
98418dba
CW
7888for ac_func in XrmSetDatabase XScreenResourceString \
7889XScreenNumberOfScreen XSetWMProtocols
7890do
7891as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 7892echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
7893echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7894if eval "test \"\${$as_ac_var+set}\" = set"; then
7895 echo $ECHO_N "(cached) $ECHO_C" >&6
7896else
7897 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7898#line $LINENO "configure"
cd958eb3
MB
7899/* confdefs.h. */
7900_ACEOF
7901cat confdefs.h >>conftest.$ac_ext
7902cat >>conftest.$ac_ext <<_ACEOF
7903/* end confdefs.h. */
98418dba 7904/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
7905 which can conflict with char $ac_func (); below.
7906 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7907 <limits.h> exists even on freestanding compilers. */
7908#ifdef __STDC__
7909# include <limits.h>
7910#else
7911# include <assert.h>
7912#endif
98418dba
CW
7913/* Override any gcc2 internal prototype to avoid an error. */
7914#ifdef __cplusplus
7915extern "C"
cd958eb3 7916{
98418dba
CW
7917#endif
7918/* We use char because int might match the return type of a gcc2
7919 builtin and then its argument prototype would still apply. */
7920char $ac_func ();
98418dba
CW
7921/* The GNU C library defines this for functions which it implements
7922 to always fail with ENOSYS. Some functions are actually named
7923 something starting with __ and the normal name is an alias. */
7924#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7925choke me
7926#else
cd958eb3
MB
7927char (*f) () = $ac_func;
7928#endif
7929#ifdef __cplusplus
7930}
98418dba
CW
7931#endif
7932
cd958eb3
MB
7933int
7934main ()
7935{
9e71690e 7936return f != $ac_func;
98418dba
CW
7937 ;
7938 return 0;
7939}
7940_ACEOF
7941rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7942if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7943 (eval $ac_link) 2>&5
7944 ac_status=$?
c0d27fcc 7945 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7946 (exit $ac_status); } &&
7947 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7948 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7949 (eval $ac_try) 2>&5
7950 ac_status=$?
c0d27fcc 7951 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7952 (exit $ac_status); }; }; then
7953 eval "$as_ac_var=yes"
7954else
7955 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7956sed 's/^/| /' conftest.$ac_ext >&5
7957
98418dba
CW
7958eval "$as_ac_var=no"
7959fi
7960rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7961fi
c0d27fcc 7962echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
7963echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7964if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 7965 cat >>confdefs.h <<_ACEOF
98418dba 7966#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 7967_ACEOF
98418dba
CW
7968
7969fi
7970done
7971
7972fi
7973
7974if test "${window_system}" = "x11"; then
c0d27fcc 7975 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
7976echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
7977 if test "${emacs_cv_x11_version_6+set}" = set; then
7978 echo $ECHO_N "(cached) $ECHO_C" >&6
7979else
7980 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7981#line $LINENO "configure"
cd958eb3
MB
7982/* confdefs.h. */
7983_ACEOF
7984cat confdefs.h >>conftest.$ac_ext
7985cat >>conftest.$ac_ext <<_ACEOF
7986/* end confdefs.h. */
98418dba 7987#include <X11/Xlib.h>
98418dba
CW
7988int
7989main ()
7990{
7991#if XlibSpecificationRelease < 6
7992fail;
7993#endif
7994
7995 ;
7996 return 0;
7997}
7998_ACEOF
7999rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8000if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8001 (eval $ac_link) 2>&5
8002 ac_status=$?
c0d27fcc 8003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8004 (exit $ac_status); } &&
8005 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8006 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8007 (eval $ac_try) 2>&5
8008 ac_status=$?
c0d27fcc 8009 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8010 (exit $ac_status); }; }; then
8011 emacs_cv_x11_version_6=yes
8012else
8013 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8014sed 's/^/| /' conftest.$ac_ext >&5
8015
98418dba
CW
8016emacs_cv_x11_version_6=no
8017fi
8018rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8019fi
8020
8021 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 8022 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 8023echo "${ECHO_T}6 or newer" >&6
b936fae4 8024
c0d27fcc 8025cat >>confdefs.h <<\_ACEOF
98418dba 8026#define HAVE_X11R6 1
c0d27fcc 8027_ACEOF
98418dba
CW
8028
8029 else
c0d27fcc 8030 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
8031echo "${ECHO_T}before 6" >&6
8032 fi
8033fi
8034
8035if test "${window_system}" = "x11"; then
c0d27fcc 8036 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
8037echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
8038 if test "${emacs_cv_x11_version_5+set}" = set; then
8039 echo $ECHO_N "(cached) $ECHO_C" >&6
8040else
8041 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8042#line $LINENO "configure"
cd958eb3
MB
8043/* confdefs.h. */
8044_ACEOF
8045cat confdefs.h >>conftest.$ac_ext
8046cat >>conftest.$ac_ext <<_ACEOF
8047/* end confdefs.h. */
98418dba 8048#include <X11/Xlib.h>
98418dba
CW
8049int
8050main ()
8051{
8052#if XlibSpecificationRelease < 5
8053fail;
8054#endif
8055
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
98418dba
CW
8062 (eval $ac_link) 2>&5
8063 ac_status=$?
c0d27fcc 8064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8065 (exit $ac_status); } &&
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_x11_version_5=yes
8073else
8074 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8075sed 's/^/| /' conftest.$ac_ext >&5
8076
98418dba
CW
8077emacs_cv_x11_version_5=no
8078fi
8079rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8080fi
8081
8082 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 8083 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
8084echo "${ECHO_T}5 or newer" >&6
8085 HAVE_X11R5=yes
b936fae4 8086
c0d27fcc 8087cat >>confdefs.h <<\_ACEOF
98418dba 8088#define HAVE_X11R5 1
c0d27fcc 8089_ACEOF
98418dba
CW
8090
8091 else
8092 HAVE_X11R5=no
c0d27fcc 8093 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
8094echo "${ECHO_T}before 5" >&6
8095 fi
8096fi
8097
488dd4c4
JD
8098
8099
8100HAVE_GTK=no
8101if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 8102 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
8103 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
8104echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
8105 { (exit 1); exit 1; }; };
8106 fi
8107 GLIB_REQUIRED=2.0.1
8108 GTK_REQUIRED=2.0.1
8109 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8110
8111 if test "X${with_pkg_config_prog}" != X; then
8112 PKG_CONFIG="${with_pkg_config_prog}"
8113 fi
8114
8115 succeeded=no
8116
8117 if test -z "$PKG_CONFIG"; then
8118 # Extract the first word of "pkg-config", so it can be a program name with args.
8119set dummy pkg-config; ac_word=$2
8120echo "$as_me:$LINENO: checking for $ac_word" >&5
8121echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8122if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
8123 echo $ECHO_N "(cached) $ECHO_C" >&6
8124else
8125 case $PKG_CONFIG in
8126 [\\/]* | ?:[\\/]*)
8127 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8128 ;;
8129 *)
8130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8131for as_dir in $PATH
8132do
8133 IFS=$as_save_IFS
8134 test -z "$as_dir" && as_dir=.
8135 for ac_exec_ext in '' $ac_executable_extensions; do
8136 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8137 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8138 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8139 break 2
8140 fi
8141done
8142done
8143
8144 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8145 ;;
8146esac
8147fi
8148PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8149
8150if test -n "$PKG_CONFIG"; then
8151 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
8152echo "${ECHO_T}$PKG_CONFIG" >&6
8153else
8154 echo "$as_me:$LINENO: result: no" >&5
8155echo "${ECHO_T}no" >&6
8156fi
8157
8158 fi
8159
8160 if test "$PKG_CONFIG" = "no" ; then
8161 echo "*** The pkg-config script could not be found. Make sure it is"
8162 echo "*** in your path, or give the full path to pkg-config with"
8163 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
8164 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
8165 else
8166 PKG_CONFIG_MIN_VERSION=0.9.0
8167 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8168 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
8169echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
8170
8171 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
8172 echo "$as_me:$LINENO: result: yes" >&5
8173echo "${ECHO_T}yes" >&6
8174 succeeded=yes
8175
8176 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
8177echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
8178 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
8179 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
8180echo "${ECHO_T}$GTK_CFLAGS" >&6
8181
8182 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
8183echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
8184 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
8185 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
8186echo "${ECHO_T}$GTK_LIBS" >&6
8187 else
8188 GTK_CFLAGS=""
8189 GTK_LIBS=""
8190 ## If we have a custom action on failure, don't print errors, but
8191 ## do set a variable so people can do so.
8192 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8193 echo $GTK_PKG_ERRORS
8194 fi
8195
8196
8197
8198 else
8199 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8200 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8201 fi
8202 fi
8203
8204 if test $succeeded = yes; then
8205 :
8206 else
8207 { { 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
8208echo "$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;}
8209 { (exit 1); exit 1; }; }
8210 fi
8211
8212
8213
8214 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
8215 HAVE_GTK=yes
8216
8217cat >>confdefs.h <<\_ACEOF
8218#define HAVE_GTK 1
8219_ACEOF
8220
8221 USE_X_TOOLKIT=none
8222
8223 with_toolkit_scroll_bars=yes
8224fi
8225
98418dba
CW
8226if test x"${USE_X_TOOLKIT}" = xmaybe; then
8227 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 8228 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
8229echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
8230 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
8231 echo $ECHO_N "(cached) $ECHO_C" >&6
8232else
8233 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8234#line $LINENO "configure"
cd958eb3
MB
8235/* confdefs.h. */
8236_ACEOF
8237cat confdefs.h >>conftest.$ac_ext
8238cat >>conftest.$ac_ext <<_ACEOF
8239/* end confdefs.h. */
98418dba
CW
8240
8241#include <X11/Intrinsic.h>
8242#include <X11/Xaw/Simple.h>
98418dba
CW
8243int
8244main ()
8245{
8246
8247 ;
8248 return 0;
8249}
8250_ACEOF
8251rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8252if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8253 (eval $ac_link) 2>&5
8254 ac_status=$?
c0d27fcc 8255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8256 (exit $ac_status); } &&
8257 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8258 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8259 (eval $ac_try) 2>&5
8260 ac_status=$?
c0d27fcc 8261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8262 (exit $ac_status); }; }; then
8263 emacs_cv_x11_version_5_with_xaw=yes
8264else
8265 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8266sed 's/^/| /' conftest.$ac_ext >&5
8267
98418dba
CW
8268emacs_cv_x11_version_5_with_xaw=no
8269fi
8270rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8271fi
8272
8273 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 8274 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
8275echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
8276 USE_X_TOOLKIT=LUCID
8277 else
c0d27fcc 8278 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
8279echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
8280 USE_X_TOOLKIT=none
8281 fi
8282 else
8283 USE_X_TOOLKIT=none
8284 fi
8285fi
8286
8287X_TOOLKIT_TYPE=$USE_X_TOOLKIT
8288
8289if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 8290 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
8291echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
8292 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
8293 echo $ECHO_N "(cached) $ECHO_C" >&6
8294else
8295 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8296#line $LINENO "configure"
cd958eb3
MB
8297/* confdefs.h. */
8298_ACEOF
8299cat confdefs.h >>conftest.$ac_ext
8300cat >>conftest.$ac_ext <<_ACEOF
8301/* end confdefs.h. */
98418dba 8302#include <X11/Intrinsic.h>
98418dba
CW
8303int
8304main ()
8305{
8306#if XtSpecificationRelease < 6
8307fail;
8308#endif
8309
8310 ;
8311 return 0;
8312}
8313_ACEOF
8314rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8315if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8316 (eval $ac_link) 2>&5
8317 ac_status=$?
c0d27fcc 8318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8319 (exit $ac_status); } &&
8320 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8321 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8322 (eval $ac_try) 2>&5
8323 ac_status=$?
c0d27fcc 8324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8325 (exit $ac_status); }; }; then
8326 emacs_cv_x11_toolkit_version_6=yes
8327else
8328 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8329sed 's/^/| /' conftest.$ac_ext >&5
8330
98418dba
CW
8331emacs_cv_x11_toolkit_version_6=no
8332fi
8333rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8334fi
8335
8336 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
8337 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 8338 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 8339echo "${ECHO_T}6 or newer" >&6
b936fae4 8340
c0d27fcc 8341cat >>confdefs.h <<\_ACEOF
98418dba 8342#define HAVE_X11XTR6 1
c0d27fcc 8343_ACEOF
98418dba
CW
8344
8345 else
c0d27fcc 8346 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
8347echo "${ECHO_T}before 6" >&6
8348 fi
8349
8350 OLDLIBS="$LIBS"
8351 if test x$HAVE_X11XTR6 = xyes; then
8352 LIBS="-lXt -lSM -lICE $LIBS"
8353 else
8354 LIBS="-lXt $LIBS"
8355 fi
8356
c0d27fcc 8357echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
8358echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
8359if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
8360 echo $ECHO_N "(cached) $ECHO_C" >&6
8361else
8362 ac_check_lib_save_LIBS=$LIBS
8363LIBS="-lXmu $LIBS"
8364cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8365#line $LINENO "configure"
cd958eb3
MB
8366/* confdefs.h. */
8367_ACEOF
8368cat confdefs.h >>conftest.$ac_ext
8369cat >>conftest.$ac_ext <<_ACEOF
8370/* end confdefs.h. */
98418dba
CW
8371
8372/* Override any gcc2 internal prototype to avoid an error. */
8373#ifdef __cplusplus
8374extern "C"
8375#endif
8376/* We use char because int might match the return type of a gcc2
8377 builtin and then its argument prototype would still apply. */
8378char XmuConvertStandardSelection ();
98418dba
CW
8379int
8380main ()
8381{
8382XmuConvertStandardSelection ();
8383 ;
8384 return 0;
8385}
8386_ACEOF
8387rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8388if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8389 (eval $ac_link) 2>&5
8390 ac_status=$?
c0d27fcc 8391 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8392 (exit $ac_status); } &&
8393 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8394 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8395 (eval $ac_try) 2>&5
8396 ac_status=$?
c0d27fcc 8397 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8398 (exit $ac_status); }; }; then
8399 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
8400else
8401 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8402sed 's/^/| /' conftest.$ac_ext >&5
8403
98418dba
CW
8404ac_cv_lib_Xmu_XmuConvertStandardSelection=no
8405fi
8406rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8407LIBS=$ac_check_lib_save_LIBS
8408fi
c0d27fcc 8409echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
8410echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
8411if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 8412 cat >>confdefs.h <<_ACEOF
98418dba 8413#define HAVE_LIBXMU 1
c0d27fcc 8414_ACEOF
98418dba
CW
8415
8416 LIBS="-lXmu $LIBS"
8417
8418fi
8419
8420 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
8421fi
8422
8423# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
8424if test "${HAVE_X11}" = "yes"; then
8425 if test "${USE_X_TOOLKIT}" != "none"; then
8426
c0d27fcc 8427echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
8428echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
8429if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
8430 echo $ECHO_N "(cached) $ECHO_C" >&6
8431else
8432 ac_check_lib_save_LIBS=$LIBS
8433LIBS="-lXext $LIBS"
8434cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8435#line $LINENO "configure"
cd958eb3
MB
8436/* confdefs.h. */
8437_ACEOF
8438cat confdefs.h >>conftest.$ac_ext
8439cat >>conftest.$ac_ext <<_ACEOF
8440/* end confdefs.h. */
98418dba
CW
8441
8442/* Override any gcc2 internal prototype to avoid an error. */
8443#ifdef __cplusplus
8444extern "C"
8445#endif
8446/* We use char because int might match the return type of a gcc2
8447 builtin and then its argument prototype would still apply. */
8448char XShapeQueryExtension ();
98418dba
CW
8449int
8450main ()
8451{
8452XShapeQueryExtension ();
8453 ;
8454 return 0;
8455}
8456_ACEOF
8457rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8458if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8459 (eval $ac_link) 2>&5
8460 ac_status=$?
c0d27fcc 8461 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8462 (exit $ac_status); } &&
8463 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8464 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8465 (eval $ac_try) 2>&5
8466 ac_status=$?
c0d27fcc 8467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8468 (exit $ac_status); }; }; then
8469 ac_cv_lib_Xext_XShapeQueryExtension=yes
8470else
8471 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8472sed 's/^/| /' conftest.$ac_ext >&5
8473
98418dba
CW
8474ac_cv_lib_Xext_XShapeQueryExtension=no
8475fi
8476rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8477LIBS=$ac_check_lib_save_LIBS
8478fi
c0d27fcc 8479echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
8480echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
8481if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 8482 cat >>confdefs.h <<_ACEOF
98418dba 8483#define HAVE_LIBXEXT 1
c0d27fcc 8484_ACEOF
98418dba
CW
8485
8486 LIBS="-lXext $LIBS"
8487
8488fi
8489
8490 fi
8491fi
8492
8493if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 8494 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
8e967cf7
MR
8495echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
8496if test "${emacs_cv_lesstif+set}" = set; then
8497 echo $ECHO_N "(cached) $ECHO_C" >&6
8498else
ae1a998c
RS
8499 # We put this in CFLAGS temporarily to precede other -I options
8500 # that might be in CFLAGS temporarily.
8501 # We put this in CPPFLAGS where it precedes the other -I options.
8502 OLD_CPPFLAGS=$CPPFLAGS
8503 OLD_CFLAGS=$CFLAGS
8504 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
8505 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
8e967cf7 8506 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8507#line $LINENO "configure"
cd958eb3
MB
8508/* confdefs.h. */
8509_ACEOF
8510cat confdefs.h >>conftest.$ac_ext
8511cat >>conftest.$ac_ext <<_ACEOF
8512/* end confdefs.h. */
8e967cf7
MR
8513#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
8514int
8515main ()
8516{
8517int x = 5;
8518 ;
8519 return 0;
8520}
8521_ACEOF
8522rm -f conftest.$ac_objext
c0d27fcc 8523if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8e967cf7
MR
8524 (eval $ac_compile) 2>&5
8525 ac_status=$?
c0d27fcc 8526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
8527 (exit $ac_status); } &&
8528 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8529 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8e967cf7
MR
8530 (eval $ac_try) 2>&5
8531 ac_status=$?
c0d27fcc 8532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
8533 (exit $ac_status); }; }; then
8534 emacs_cv_lesstif=yes
8535else
8536 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8537sed 's/^/| /' conftest.$ac_ext >&5
8538
8e967cf7
MR
8539emacs_cv_lesstif=no
8540fi
8541rm -f conftest.$ac_objext conftest.$ac_ext
8542fi
c0d27fcc 8543echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
8e967cf7
MR
8544echo "${ECHO_T}$emacs_cv_lesstif" >&6
8545 if test $emacs_cv_lesstif = yes; then
ae1a998c
RS
8546 # Make sure this -I option remains in CPPFLAGS after it is set
8547 # back to REAL_CPPFLAGS.
8548 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
8549 # have those other -I options anyway. Ultimately, having this
8550 # directory ultimately in CPPFLAGS will be enough.
8551 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
8e967cf7 8552 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
ae1a998c
RS
8553 else
8554 CFLAGS=$OLD_CFLAGS
8555 CPPFLAGS=$OLD_CPPFLAGS
8e967cf7 8556 fi
c0d27fcc 8557 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
8558echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
8559if test "${emacs_cv_motif_version_2_1+set}" = set; then
8560 echo $ECHO_N "(cached) $ECHO_C" >&6
8561else
8562 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8563#line $LINENO "configure"
cd958eb3
MB
8564/* confdefs.h. */
8565_ACEOF
8566cat confdefs.h >>conftest.$ac_ext
8567cat >>conftest.$ac_ext <<_ACEOF
8568/* end confdefs.h. */
98418dba 8569#include <Xm/Xm.h>
98418dba
CW
8570int
8571main ()
8572{
8573#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
8574int x = 5;
8575#else
8576Motif version prior to 2.1.
8577#endif
8578 ;
8579 return 0;
8580}
8581_ACEOF
8582rm -f conftest.$ac_objext
c0d27fcc 8583if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
8584 (eval $ac_compile) 2>&5
8585 ac_status=$?
c0d27fcc 8586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8587 (exit $ac_status); } &&
8588 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8590 (eval $ac_try) 2>&5
8591 ac_status=$?
c0d27fcc 8592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8593 (exit $ac_status); }; }; then
8594 emacs_cv_motif_version_2_1=yes
8595else
8596 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8597sed 's/^/| /' conftest.$ac_ext >&5
8598
98418dba
CW
8599emacs_cv_motif_version_2_1=no
8600fi
8601rm -f conftest.$ac_objext conftest.$ac_ext
8602fi
c0d27fcc 8603echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
8604echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
8605 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
8606 if test $emacs_cv_motif_version_2_1 = yes; then
8607 HAVE_LIBXP=no
b936fae4 8608
c0d27fcc 8609cat >>confdefs.h <<\_ACEOF
98418dba 8610#define HAVE_MOTIF_2_1 1
c0d27fcc 8611_ACEOF
98418dba 8612
c0d27fcc 8613 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
8614echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
8615if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
8616 echo $ECHO_N "(cached) $ECHO_C" >&6
8617else
8618 ac_check_lib_save_LIBS=$LIBS
8619LIBS="-lXp $LIBS"
8620cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8621#line $LINENO "configure"
cd958eb3
MB
8622/* confdefs.h. */
8623_ACEOF
8624cat confdefs.h >>conftest.$ac_ext
8625cat >>conftest.$ac_ext <<_ACEOF
8626/* end confdefs.h. */
98418dba
CW
8627
8628/* Override any gcc2 internal prototype to avoid an error. */
8629#ifdef __cplusplus
8630extern "C"
8631#endif
8632/* We use char because int might match the return type of a gcc2
8633 builtin and then its argument prototype would still apply. */
8634char XpCreateContext ();
98418dba
CW
8635int
8636main ()
8637{
8638XpCreateContext ();
8639 ;
8640 return 0;
8641}
8642_ACEOF
8643rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8644if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8645 (eval $ac_link) 2>&5
8646 ac_status=$?
c0d27fcc 8647 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8648 (exit $ac_status); } &&
8649 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8650 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8651 (eval $ac_try) 2>&5
8652 ac_status=$?
c0d27fcc 8653 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8654 (exit $ac_status); }; }; then
8655 ac_cv_lib_Xp_XpCreateContext=yes
8656else
8657 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8658sed 's/^/| /' conftest.$ac_ext >&5
8659
98418dba
CW
8660ac_cv_lib_Xp_XpCreateContext=no
8661fi
8662rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8663LIBS=$ac_check_lib_save_LIBS
8664fi
c0d27fcc 8665echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
8666echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
8667if test $ac_cv_lib_Xp_XpCreateContext = yes; then
8668 HAVE_LIBXP=yes
8669fi
503d2be0 8670
98418dba 8671 if test ${HAVE_LIBXP} = yes; then
b936fae4 8672
c0d27fcc 8673cat >>confdefs.h <<\_ACEOF
98418dba 8674#define HAVE_LIBXP 1
c0d27fcc 8675_ACEOF
503d2be0 8676
98418dba
CW
8677 fi
8678 fi
8679fi
8680
8681### Is -lXaw3d available?
8682HAVE_XAW3D=no
8683if test "${HAVE_X11}" = "yes"; then
8684 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 8685 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
8686echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
8687if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
8688 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 8689else
22044edf 8690 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8691#line $LINENO "configure"
cd958eb3
MB
8692/* confdefs.h. */
8693_ACEOF
8694cat confdefs.h >>conftest.$ac_ext
8695cat >>conftest.$ac_ext <<_ACEOF
8696/* end confdefs.h. */
98418dba 8697#include <X11/Xaw3d/Scrollbar.h>
503d2be0 8698_ACEOF
c0d27fcc 8699if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
8700 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8701 ac_status=$?
6bae0ccf 8702 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
8703 rm -f conftest.er1
8704 cat conftest.err >&5
c0d27fcc 8705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
8706 (exit $ac_status); } >/dev/null; then
8707 if test -s conftest.err; then
8708 ac_cpp_err=$ac_c_preproc_warn_flag
8709 else
8710 ac_cpp_err=
8711 fi
8712else
8713 ac_cpp_err=yes
8714fi
8715if test -z "$ac_cpp_err"; then
22044edf 8716 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 8717else
503d2be0 8718 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8719sed 's/^/| /' conftest.$ac_ext >&5
8720
22044edf 8721 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 8722fi
503d2be0 8723rm -f conftest.err conftest.$ac_ext
98418dba 8724fi
c0d27fcc 8725echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 8726echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 8727if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 8728 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
8729echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
8730if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
8731 echo $ECHO_N "(cached) $ECHO_C" >&6
8732else
8733 ac_check_lib_save_LIBS=$LIBS
8734LIBS="-lXaw3d $LIBS"
8735cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8736#line $LINENO "configure"
cd958eb3
MB
8737/* confdefs.h. */
8738_ACEOF
8739cat confdefs.h >>conftest.$ac_ext
8740cat >>conftest.$ac_ext <<_ACEOF
8741/* end confdefs.h. */
98418dba
CW
8742
8743/* Override any gcc2 internal prototype to avoid an error. */
8744#ifdef __cplusplus
8745extern "C"
8746#endif
8747/* We use char because int might match the return type of a gcc2
8748 builtin and then its argument prototype would still apply. */
8749char XawScrollbarSetThumb ();
503d2be0
AS
8750int
8751main ()
8752{
98418dba 8753XawScrollbarSetThumb ();
503d2be0
AS
8754 ;
8755 return 0;
8756}
8757_ACEOF
8758rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8759if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
8760 (eval $ac_link) 2>&5
8761 ac_status=$?
c0d27fcc 8762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
8763 (exit $ac_status); } &&
8764 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
8766 (eval $ac_try) 2>&5
8767 ac_status=$?
c0d27fcc 8768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 8769 (exit $ac_status); }; }; then
98418dba 8770 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 8771else
503d2be0 8772 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8773sed 's/^/| /' conftest.$ac_ext >&5
8774
98418dba 8775ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 8776fi
503d2be0 8777rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 8778LIBS=$ac_check_lib_save_LIBS
ba4481b5 8779fi
c0d27fcc 8780echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
8781echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
8782if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
8783 HAVE_XAW3D=yes
ba4481b5 8784fi
503d2be0 8785
ba4481b5
DL
8786fi
8787
c0d27fcc 8788
98418dba 8789 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 8790
c0d27fcc 8791cat >>confdefs.h <<\_ACEOF
98418dba 8792#define HAVE_XAW3D 1
c0d27fcc 8793_ACEOF
98418dba 8794
ba4481b5 8795 fi
98418dba 8796 fi
ba4481b5
DL
8797fi
8798
c0d27fcc
MR
8799
8800
98418dba
CW
8801USE_TOOLKIT_SCROLL_BARS=no
8802if test "${with_toolkit_scroll_bars}" != "no"; then
8803 if test "${USE_X_TOOLKIT}" != "none"; then
8804 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 8805 cat >>confdefs.h <<\_ACEOF
98418dba 8806#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 8807_ACEOF
98418dba
CW
8808
8809 HAVE_XAW3D=no
8810 USE_TOOLKIT_SCROLL_BARS=yes
8811 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 8812 cat >>confdefs.h <<\_ACEOF
98418dba 8813#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 8814_ACEOF
98418dba
CW
8815
8816 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 8817 fi
488dd4c4
JD
8818 elif test "${HAVE_GTK}" = "yes"; then
8819 cat >>confdefs.h <<\_ACEOF
8820#define USE_TOOLKIT_SCROLL_BARS 1
8821_ACEOF
8822
8823 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
8824 fi
8825fi
8826
c0d27fcc 8827
98418dba 8828if test "${with_xim}" != "no"; then
b936fae4 8829
c0d27fcc 8830cat >>confdefs.h <<\_ACEOF
98418dba 8831#define USE_XIM 1
c0d27fcc 8832_ACEOF
98418dba
CW
8833
8834fi
8835
8836### Use -lXpm if available, unless `--with-xpm=no'.
8837HAVE_XPM=no
8838if test "${HAVE_X11}" = "yes"; then
8839 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
8840 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8841 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
8842echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
8843if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8844 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8845fi
8846echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
8847echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 8848else
c0d27fcc
MR
8849 # Is the header compilable?
8850echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
8851echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
8852cat >conftest.$ac_ext <<_ACEOF
8853#line $LINENO "configure"
cd958eb3
MB
8854/* confdefs.h. */
8855_ACEOF
8856cat confdefs.h >>conftest.$ac_ext
8857cat >>conftest.$ac_ext <<_ACEOF
8858/* end confdefs.h. */
c0d27fcc
MR
8859$ac_includes_default
8860#include <X11/xpm.h>
8861_ACEOF
8862rm -f conftest.$ac_objext
8863if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8864 (eval $ac_compile) 2>&5
8865 ac_status=$?
8866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8867 (exit $ac_status); } &&
8868 { ac_try='test -s conftest.$ac_objext'
8869 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8870 (eval $ac_try) 2>&5
8871 ac_status=$?
8872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8873 (exit $ac_status); }; }; then
8874 ac_header_compiler=yes
8875else
8876 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8877sed 's/^/| /' conftest.$ac_ext >&5
8878
c0d27fcc
MR
8879ac_header_compiler=no
8880fi
8881rm -f conftest.$ac_objext conftest.$ac_ext
8882echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8883echo "${ECHO_T}$ac_header_compiler" >&6
8884
8885# Is the header present?
8886echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
8887echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
8888cat >conftest.$ac_ext <<_ACEOF
8889#line $LINENO "configure"
cd958eb3
MB
8890/* confdefs.h. */
8891_ACEOF
8892cat confdefs.h >>conftest.$ac_ext
8893cat >>conftest.$ac_ext <<_ACEOF
8894/* end confdefs.h. */
98418dba
CW
8895#include <X11/xpm.h>
8896_ACEOF
c0d27fcc 8897if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8898 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8899 ac_status=$?
6bae0ccf 8900 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8901 rm -f conftest.er1
8902 cat conftest.err >&5
c0d27fcc 8903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8904 (exit $ac_status); } >/dev/null; then
8905 if test -s conftest.err; then
8906 ac_cpp_err=$ac_c_preproc_warn_flag
8907 else
8908 ac_cpp_err=
8909 fi
8910else
8911 ac_cpp_err=yes
8912fi
8913if test -z "$ac_cpp_err"; then
c0d27fcc 8914 ac_header_preproc=yes
98418dba
CW
8915else
8916 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8917sed 's/^/| /' conftest.$ac_ext >&5
8918
c0d27fcc 8919 ac_header_preproc=no
98418dba
CW
8920fi
8921rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8922echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8923echo "${ECHO_T}$ac_header_preproc" >&6
8924
8925# So? What about this header?
8926case $ac_header_compiler:$ac_header_preproc in
8927 yes:no )
8928 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
8929echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8930 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
8931echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
8932 (
8933 cat <<\_ASBOX
8934## ------------------------------------ ##
8935## Report this to bug-autoconf@gnu.org. ##
8936## ------------------------------------ ##
8937_ASBOX
8938 ) |
8939 sed "s/^/$as_me: WARNING: /" >&2
8940 ;;
c0d27fcc
MR
8941 no:yes )
8942 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
8943echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
8944 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
8945echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
8946 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
8947echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
8948 (
8949 cat <<\_ASBOX
8950## ------------------------------------ ##
8951## Report this to bug-autoconf@gnu.org. ##
8952## ------------------------------------ ##
8953_ASBOX
8954 ) |
8955 sed "s/^/$as_me: WARNING: /" >&2
8956 ;;
c0d27fcc
MR
8957esac
8958echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
8959echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
8960if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8961 echo $ECHO_N "(cached) $ECHO_C" >&6
8962else
8963 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 8964fi
c0d27fcc 8965echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 8966echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
8967
8968fi
98418dba 8969if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 8970 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
8971echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
8972if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 8973 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 8974else
98418dba
CW
8975 ac_check_lib_save_LIBS=$LIBS
8976LIBS="-lXpm -lX11 $LIBS"
8977cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8978#line $LINENO "configure"
cd958eb3
MB
8979/* confdefs.h. */
8980_ACEOF
8981cat confdefs.h >>conftest.$ac_ext
8982cat >>conftest.$ac_ext <<_ACEOF
8983/* end confdefs.h. */
98418dba 8984
ba4481b5 8985/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
8986#ifdef __cplusplus
8987extern "C"
8988#endif
ba4481b5 8989/* We use char because int might match the return type of a gcc2
503d2be0 8990 builtin and then its argument prototype would still apply. */
98418dba 8991char XpmReadFileToPixmap ();
503d2be0
AS
8992int
8993main ()
8994{
98418dba 8995XpmReadFileToPixmap ();
503d2be0
AS
8996 ;
8997 return 0;
8998}
8999_ACEOF
9000rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9001if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9002 (eval $ac_link) 2>&5
9003 ac_status=$?
c0d27fcc 9004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9005 (exit $ac_status); } &&
9006 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9007 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9008 (eval $ac_try) 2>&5
9009 ac_status=$?
c0d27fcc 9010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9011 (exit $ac_status); }; }; then
98418dba 9012 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
9013else
9014 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9015sed 's/^/| /' conftest.$ac_ext >&5
9016
98418dba 9017ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0
AS
9018fi
9019rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 9020LIBS=$ac_check_lib_save_LIBS
503d2be0 9021fi
c0d27fcc 9022echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
9023echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
9024if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
9025 HAVE_XPM=yes
ba4481b5
DL
9026fi
9027
98418dba
CW
9028fi
9029
c0d27fcc 9030
98418dba 9031 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 9032 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
9033echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
9034 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9035#line $LINENO "configure"
cd958eb3
MB
9036/* confdefs.h. */
9037_ACEOF
9038cat confdefs.h >>conftest.$ac_ext
9039cat >>conftest.$ac_ext <<_ACEOF
9040/* end confdefs.h. */
98418dba
CW
9041#include "X11/xpm.h"
9042#ifndef XpmReturnAllocPixels
9043no_return_alloc_pixels
503d2be0 9044#endif
ba4481b5 9045
98418dba
CW
9046_ACEOF
9047if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 9048 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
9049 HAVE_XPM=no
9050else
9051 HAVE_XPM=yes
9052fi
9053rm -f conftest*
ba4481b5 9054
c0d27fcc 9055
98418dba 9056 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 9057 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9058echo "${ECHO_T}yes" >&6
9059 else
c0d27fcc 9060 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9061echo "${ECHO_T}no" >&6
9062 fi
9063 fi
9064 fi
9065
9066 if test "${HAVE_XPM}" = "yes"; then
b936fae4 9067
c0d27fcc 9068cat >>confdefs.h <<\_ACEOF
98418dba 9069#define HAVE_XPM 1
c0d27fcc 9070_ACEOF
98418dba
CW
9071
9072 fi
9073fi
9074
9075### Use -ljpeg if available, unless `--with-jpeg=no'.
9076HAVE_JPEG=no
9077if test "${HAVE_X11}" = "yes"; then
9078 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
9079 if test "${ac_cv_header_jerror_h+set}" = set; then
9080 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
9081echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
9082if test "${ac_cv_header_jerror_h+set}" = set; then
9083 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9084fi
9085echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
9086echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 9087else
c0d27fcc
MR
9088 # Is the header compilable?
9089echo "$as_me:$LINENO: checking jerror.h usability" >&5
9090echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
9091cat >conftest.$ac_ext <<_ACEOF
9092#line $LINENO "configure"
cd958eb3
MB
9093/* confdefs.h. */
9094_ACEOF
9095cat confdefs.h >>conftest.$ac_ext
9096cat >>conftest.$ac_ext <<_ACEOF
9097/* end confdefs.h. */
c0d27fcc
MR
9098$ac_includes_default
9099#include <jerror.h>
9100_ACEOF
9101rm -f conftest.$ac_objext
9102if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9103 (eval $ac_compile) 2>&5
9104 ac_status=$?
9105 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9106 (exit $ac_status); } &&
9107 { ac_try='test -s conftest.$ac_objext'
9108 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9109 (eval $ac_try) 2>&5
9110 ac_status=$?
9111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9112 (exit $ac_status); }; }; then
9113 ac_header_compiler=yes
9114else
9115 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9116sed 's/^/| /' conftest.$ac_ext >&5
9117
c0d27fcc
MR
9118ac_header_compiler=no
9119fi
9120rm -f conftest.$ac_objext conftest.$ac_ext
9121echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9122echo "${ECHO_T}$ac_header_compiler" >&6
9123
9124# Is the header present?
9125echo "$as_me:$LINENO: checking jerror.h presence" >&5
9126echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
9127cat >conftest.$ac_ext <<_ACEOF
9128#line $LINENO "configure"
cd958eb3
MB
9129/* confdefs.h. */
9130_ACEOF
9131cat confdefs.h >>conftest.$ac_ext
9132cat >>conftest.$ac_ext <<_ACEOF
9133/* end confdefs.h. */
98418dba
CW
9134#include <jerror.h>
9135_ACEOF
c0d27fcc 9136if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9137 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9138 ac_status=$?
6bae0ccf 9139 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9140 rm -f conftest.er1
9141 cat conftest.err >&5
c0d27fcc 9142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9143 (exit $ac_status); } >/dev/null; then
9144 if test -s conftest.err; then
9145 ac_cpp_err=$ac_c_preproc_warn_flag
9146 else
9147 ac_cpp_err=
9148 fi
9149else
9150 ac_cpp_err=yes
503d2be0 9151fi
98418dba 9152if test -z "$ac_cpp_err"; then
c0d27fcc 9153 ac_header_preproc=yes
ba4481b5 9154else
98418dba 9155 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9156sed 's/^/| /' conftest.$ac_ext >&5
9157
c0d27fcc 9158 ac_header_preproc=no
98418dba
CW
9159fi
9160rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9161echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9162echo "${ECHO_T}$ac_header_preproc" >&6
9163
9164# So? What about this header?
9165case $ac_header_compiler:$ac_header_preproc in
9166 yes:no )
9167 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
9168echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9169 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9170echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
9171 (
9172 cat <<\_ASBOX
9173## ------------------------------------ ##
9174## Report this to bug-autoconf@gnu.org. ##
9175## ------------------------------------ ##
9176_ASBOX
9177 ) |
9178 sed "s/^/$as_me: WARNING: /" >&2
9179 ;;
c0d27fcc
MR
9180 no:yes )
9181 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
9182echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
9183 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
9184echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
9185 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9186echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
9187 (
9188 cat <<\_ASBOX
9189## ------------------------------------ ##
9190## Report this to bug-autoconf@gnu.org. ##
9191## ------------------------------------ ##
9192_ASBOX
9193 ) |
9194 sed "s/^/$as_me: WARNING: /" >&2
9195 ;;
c0d27fcc
MR
9196esac
9197echo "$as_me:$LINENO: checking for jerror.h" >&5
9198echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
9199if test "${ac_cv_header_jerror_h+set}" = set; then
9200 echo $ECHO_N "(cached) $ECHO_C" >&6
9201else
9202 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 9203fi
c0d27fcc 9204echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 9205echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
9206
9207fi
98418dba 9208if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 9209 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
9210echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
9211if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 9212 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 9213else
98418dba
CW
9214 ac_check_lib_save_LIBS=$LIBS
9215LIBS="-ljpeg $LIBS"
9216cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9217#line $LINENO "configure"
cd958eb3
MB
9218/* confdefs.h. */
9219_ACEOF
9220cat confdefs.h >>conftest.$ac_ext
9221cat >>conftest.$ac_ext <<_ACEOF
9222/* end confdefs.h. */
98418dba
CW
9223
9224/* Override any gcc2 internal prototype to avoid an error. */
9225#ifdef __cplusplus
9226extern "C"
9227#endif
9228/* We use char because int might match the return type of a gcc2
9229 builtin and then its argument prototype would still apply. */
9230char jpeg_destroy_compress ();
503d2be0
AS
9231int
9232main ()
9233{
98418dba 9234jpeg_destroy_compress ();
503d2be0
AS
9235 ;
9236 return 0;
9237}
9238_ACEOF
9239rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9240if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9241 (eval $ac_link) 2>&5
9242 ac_status=$?
c0d27fcc 9243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9244 (exit $ac_status); } &&
9245 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9246 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9247 (eval $ac_try) 2>&5
9248 ac_status=$?
c0d27fcc 9249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9250 (exit $ac_status); }; }; then
98418dba 9251 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 9252else
503d2be0 9253 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9254sed 's/^/| /' conftest.$ac_ext >&5
9255
98418dba 9256ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 9257fi
503d2be0 9258rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 9259LIBS=$ac_check_lib_save_LIBS
ba4481b5 9260fi
c0d27fcc 9261echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
9262echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
9263if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
9264 HAVE_JPEG=yes
ba4481b5 9265fi
98418dba 9266
ba4481b5 9267fi
98418dba 9268
c0d27fcc 9269
ba4481b5 9270 fi
ba4481b5 9271
c0d27fcc 9272
98418dba 9273 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 9274 cat >>confdefs.h <<\_ACEOF
98418dba 9275#define HAVE_JPEG 1
c0d27fcc 9276_ACEOF
98418dba
CW
9277
9278 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9279#line $LINENO "configure"
cd958eb3
MB
9280/* confdefs.h. */
9281_ACEOF
9282cat confdefs.h >>conftest.$ac_ext
9283cat >>conftest.$ac_ext <<_ACEOF
9284/* end confdefs.h. */
22044edf 9285#include <jpeglib.h>
98418dba
CW
9286 version=JPEG_LIB_VERSION
9287
9288_ACEOF
9289if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 9290 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 9291 cat >>confdefs.h <<\_ACEOF
98418dba 9292#define HAVE_JPEG 1
c0d27fcc 9293_ACEOF
ba4481b5 9294
98418dba 9295else
c0d27fcc 9296 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
9297echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
9298 HAVE_JPEG=no
ba4481b5 9299fi
98418dba 9300rm -f conftest*
ba4481b5 9301
98418dba
CW
9302 fi
9303fi
503d2be0 9304
98418dba
CW
9305### Use -lpng if available, unless `--with-png=no'.
9306HAVE_PNG=no
9307if test "${HAVE_X11}" = "yes"; then
9308 if test "${with_png}" != "no"; then
c0d27fcc
MR
9309 if test "${ac_cv_header_png_h+set}" = set; then
9310 echo "$as_me:$LINENO: checking for png.h" >&5
98418dba
CW
9311echo $ECHO_N "checking for png.h... $ECHO_C" >&6
9312if test "${ac_cv_header_png_h+set}" = set; then
503d2be0 9313 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9314fi
9315echo "$as_me:$LINENO: result: $ac_cv_header_png_h" >&5
9316echo "${ECHO_T}$ac_cv_header_png_h" >&6
503d2be0 9317else
c0d27fcc
MR
9318 # Is the header compilable?
9319echo "$as_me:$LINENO: checking png.h usability" >&5
9320echo $ECHO_N "checking png.h usability... $ECHO_C" >&6
9321cat >conftest.$ac_ext <<_ACEOF
9322#line $LINENO "configure"
cd958eb3
MB
9323/* confdefs.h. */
9324_ACEOF
9325cat confdefs.h >>conftest.$ac_ext
9326cat >>conftest.$ac_ext <<_ACEOF
9327/* end confdefs.h. */
c0d27fcc
MR
9328$ac_includes_default
9329#include <png.h>
9330_ACEOF
9331rm -f conftest.$ac_objext
9332if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9333 (eval $ac_compile) 2>&5
9334 ac_status=$?
9335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9336 (exit $ac_status); } &&
9337 { ac_try='test -s conftest.$ac_objext'
9338 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9339 (eval $ac_try) 2>&5
9340 ac_status=$?
9341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9342 (exit $ac_status); }; }; then
9343 ac_header_compiler=yes
9344else
9345 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9346sed 's/^/| /' conftest.$ac_ext >&5
9347
c0d27fcc
MR
9348ac_header_compiler=no
9349fi
9350rm -f conftest.$ac_objext conftest.$ac_ext
9351echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9352echo "${ECHO_T}$ac_header_compiler" >&6
9353
9354# Is the header present?
9355echo "$as_me:$LINENO: checking png.h presence" >&5
9356echo $ECHO_N "checking png.h presence... $ECHO_C" >&6
9357cat >conftest.$ac_ext <<_ACEOF
9358#line $LINENO "configure"
cd958eb3
MB
9359/* confdefs.h. */
9360_ACEOF
9361cat confdefs.h >>conftest.$ac_ext
9362cat >>conftest.$ac_ext <<_ACEOF
9363/* end confdefs.h. */
98418dba 9364#include <png.h>
503d2be0 9365_ACEOF
c0d27fcc 9366if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
9367 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9368 ac_status=$?
6bae0ccf 9369 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
9370 rm -f conftest.er1
9371 cat conftest.err >&5
c0d27fcc 9372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9373 (exit $ac_status); } >/dev/null; then
9374 if test -s conftest.err; then
9375 ac_cpp_err=$ac_c_preproc_warn_flag
9376 else
9377 ac_cpp_err=
9378 fi
9379else
9380 ac_cpp_err=yes
9381fi
9382if test -z "$ac_cpp_err"; then
c0d27fcc 9383 ac_header_preproc=yes
503d2be0
AS
9384else
9385 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9386sed 's/^/| /' conftest.$ac_ext >&5
9387
c0d27fcc 9388 ac_header_preproc=no
ba4481b5 9389fi
503d2be0 9390rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9391echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9392echo "${ECHO_T}$ac_header_preproc" >&6
9393
9394# So? What about this header?
9395case $ac_header_compiler:$ac_header_preproc in
9396 yes:no )
9397 { echo "$as_me:$LINENO: WARNING: png.h: accepted by the compiler, rejected by the preprocessor!" >&5
9398echo "$as_me: WARNING: png.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9399 { echo "$as_me:$LINENO: WARNING: png.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9400echo "$as_me: WARNING: png.h: proceeding with the preprocessor's result" >&2;}
9401 (
9402 cat <<\_ASBOX
9403## ------------------------------------ ##
9404## Report this to bug-autoconf@gnu.org. ##
9405## ------------------------------------ ##
9406_ASBOX
9407 ) |
9408 sed "s/^/$as_me: WARNING: /" >&2
9409 ;;
c0d27fcc
MR
9410 no:yes )
9411 { echo "$as_me:$LINENO: WARNING: png.h: present but cannot be compiled" >&5
9412echo "$as_me: WARNING: png.h: present but cannot be compiled" >&2;}
9413 { echo "$as_me:$LINENO: WARNING: png.h: check for missing prerequisite headers?" >&5
9414echo "$as_me: WARNING: png.h: check for missing prerequisite headers?" >&2;}
9415 { echo "$as_me:$LINENO: WARNING: png.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9416echo "$as_me: WARNING: png.h: proceeding with the preprocessor's result" >&2;}
9417 (
9418 cat <<\_ASBOX
9419## ------------------------------------ ##
9420## Report this to bug-autoconf@gnu.org. ##
9421## ------------------------------------ ##
9422_ASBOX
9423 ) |
9424 sed "s/^/$as_me: WARNING: /" >&2
9425 ;;
c0d27fcc
MR
9426esac
9427echo "$as_me:$LINENO: checking for png.h" >&5
9428echo $ECHO_N "checking for png.h... $ECHO_C" >&6
9429if test "${ac_cv_header_png_h+set}" = set; then
9430 echo $ECHO_N "(cached) $ECHO_C" >&6
9431else
9432 ac_cv_header_png_h=$ac_header_preproc
ba4481b5 9433fi
c0d27fcc 9434echo "$as_me:$LINENO: result: $ac_cv_header_png_h" >&5
98418dba 9435echo "${ECHO_T}$ac_cv_header_png_h" >&6
c0d27fcc
MR
9436
9437fi
98418dba 9438if test $ac_cv_header_png_h = yes; then
c0d27fcc 9439 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
9440echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
9441if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 9442 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 9443else
98418dba
CW
9444 ac_check_lib_save_LIBS=$LIBS
9445LIBS="-lpng -lz -lm $LIBS"
9446cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9447#line $LINENO "configure"
cd958eb3
MB
9448/* confdefs.h. */
9449_ACEOF
9450cat confdefs.h >>conftest.$ac_ext
9451cat >>conftest.$ac_ext <<_ACEOF
9452/* end confdefs.h. */
98418dba 9453
ba4481b5 9454/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
9455#ifdef __cplusplus
9456extern "C"
9457#endif
ba4481b5 9458/* We use char because int might match the return type of a gcc2
503d2be0 9459 builtin and then its argument prototype would still apply. */
98418dba 9460char png_get_channels ();
503d2be0
AS
9461int
9462main ()
9463{
98418dba 9464png_get_channels ();
503d2be0
AS
9465 ;
9466 return 0;
9467}
9468_ACEOF
9469rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9470if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9471 (eval $ac_link) 2>&5
9472 ac_status=$?
c0d27fcc 9473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9474 (exit $ac_status); } &&
9475 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9477 (eval $ac_try) 2>&5
9478 ac_status=$?
c0d27fcc 9479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9480 (exit $ac_status); }; }; then
98418dba 9481 ac_cv_lib_png_png_get_channels=yes
73b77ee5 9482else
98418dba 9483 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9484sed 's/^/| /' conftest.$ac_ext >&5
9485
98418dba 9486ac_cv_lib_png_png_get_channels=no
73b77ee5 9487fi
98418dba
CW
9488rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9489LIBS=$ac_check_lib_save_LIBS
73b77ee5 9490fi
c0d27fcc 9491echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
9492echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
9493if test $ac_cv_lib_png_png_get_channels = yes; then
9494 HAVE_PNG=yes
73b77ee5 9495fi
503d2be0 9496
98418dba
CW
9497fi
9498
c0d27fcc 9499
98418dba
CW
9500 fi
9501
9502 if test "${HAVE_PNG}" = "yes"; then
b936fae4 9503
c0d27fcc 9504cat >>confdefs.h <<\_ACEOF
98418dba 9505#define HAVE_PNG 1
c0d27fcc 9506_ACEOF
73b77ee5 9507
98418dba 9508 fi
73b77ee5
GM
9509fi
9510
98418dba
CW
9511### Use -ltiff if available, unless `--with-tiff=no'.
9512HAVE_TIFF=no
9513if test "${HAVE_X11}" = "yes"; then
9514 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
9515 if test "${ac_cv_header_tiffio_h+set}" = set; then
9516 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
9517echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
9518if test "${ac_cv_header_tiffio_h+set}" = set; then
9519 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9520fi
9521echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
9522echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 9523else
c0d27fcc
MR
9524 # Is the header compilable?
9525echo "$as_me:$LINENO: checking tiffio.h usability" >&5
9526echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
9527cat >conftest.$ac_ext <<_ACEOF
9528#line $LINENO "configure"
cd958eb3
MB
9529/* confdefs.h. */
9530_ACEOF
9531cat confdefs.h >>conftest.$ac_ext
9532cat >>conftest.$ac_ext <<_ACEOF
9533/* end confdefs.h. */
c0d27fcc
MR
9534$ac_includes_default
9535#include <tiffio.h>
9536_ACEOF
9537rm -f conftest.$ac_objext
9538if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9539 (eval $ac_compile) 2>&5
9540 ac_status=$?
9541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9542 (exit $ac_status); } &&
9543 { ac_try='test -s conftest.$ac_objext'
9544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9545 (eval $ac_try) 2>&5
9546 ac_status=$?
9547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9548 (exit $ac_status); }; }; then
9549 ac_header_compiler=yes
9550else
9551 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9552sed 's/^/| /' conftest.$ac_ext >&5
9553
c0d27fcc
MR
9554ac_header_compiler=no
9555fi
9556rm -f conftest.$ac_objext conftest.$ac_ext
9557echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9558echo "${ECHO_T}$ac_header_compiler" >&6
9559
9560# Is the header present?
9561echo "$as_me:$LINENO: checking tiffio.h presence" >&5
9562echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
9563cat >conftest.$ac_ext <<_ACEOF
9564#line $LINENO "configure"
cd958eb3
MB
9565/* confdefs.h. */
9566_ACEOF
9567cat confdefs.h >>conftest.$ac_ext
9568cat >>conftest.$ac_ext <<_ACEOF
9569/* end confdefs.h. */
98418dba
CW
9570#include <tiffio.h>
9571_ACEOF
c0d27fcc 9572if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9573 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9574 ac_status=$?
6bae0ccf 9575 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9576 rm -f conftest.er1
9577 cat conftest.err >&5
c0d27fcc 9578 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9579 (exit $ac_status); } >/dev/null; then
9580 if test -s conftest.err; then
9581 ac_cpp_err=$ac_c_preproc_warn_flag
9582 else
9583 ac_cpp_err=
9584 fi
9585else
9586 ac_cpp_err=yes
9587fi
9588if test -z "$ac_cpp_err"; then
c0d27fcc 9589 ac_header_preproc=yes
98418dba
CW
9590else
9591 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9592sed 's/^/| /' conftest.$ac_ext >&5
9593
c0d27fcc 9594 ac_header_preproc=no
98418dba
CW
9595fi
9596rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9597echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9598echo "${ECHO_T}$ac_header_preproc" >&6
9599
9600# So? What about this header?
9601case $ac_header_compiler:$ac_header_preproc in
9602 yes:no )
9603 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
9604echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9605 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9606echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
9607 (
9608 cat <<\_ASBOX
9609## ------------------------------------ ##
9610## Report this to bug-autoconf@gnu.org. ##
9611## ------------------------------------ ##
9612_ASBOX
9613 ) |
9614 sed "s/^/$as_me: WARNING: /" >&2
9615 ;;
c0d27fcc
MR
9616 no:yes )
9617 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
9618echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
9619 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
9620echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
9621 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9622echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
9623 (
9624 cat <<\_ASBOX
9625## ------------------------------------ ##
9626## Report this to bug-autoconf@gnu.org. ##
9627## ------------------------------------ ##
9628_ASBOX
9629 ) |
9630 sed "s/^/$as_me: WARNING: /" >&2
9631 ;;
c0d27fcc
MR
9632esac
9633echo "$as_me:$LINENO: checking for tiffio.h" >&5
9634echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
9635if test "${ac_cv_header_tiffio_h+set}" = set; then
9636 echo $ECHO_N "(cached) $ECHO_C" >&6
9637else
9638 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 9639fi
c0d27fcc 9640echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 9641echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
9642
9643fi
98418dba
CW
9644if test $ac_cv_header_tiffio_h = yes; then
9645 tifflibs="-lz -lm"
9646 # At least one tiff package requires the jpeg library.
9647 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 9648 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
9649echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
9650if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 9651 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 9652else
503d2be0 9653 ac_check_lib_save_LIBS=$LIBS
98418dba 9654LIBS="-ltiff $tifflibs $LIBS"
503d2be0 9655cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9656#line $LINENO "configure"
cd958eb3
MB
9657/* confdefs.h. */
9658_ACEOF
9659cat confdefs.h >>conftest.$ac_ext
9660cat >>conftest.$ac_ext <<_ACEOF
9661/* end confdefs.h. */
503d2be0 9662
73b77ee5 9663/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
9664#ifdef __cplusplus
9665extern "C"
9666#endif
73b77ee5 9667/* We use char because int might match the return type of a gcc2
503d2be0 9668 builtin and then its argument prototype would still apply. */
98418dba 9669char TIFFGetVersion ();
503d2be0
AS
9670int
9671main ()
9672{
98418dba 9673TIFFGetVersion ();
503d2be0
AS
9674 ;
9675 return 0;
9676}
9677_ACEOF
9678rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9679if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9680 (eval $ac_link) 2>&5
9681 ac_status=$?
c0d27fcc 9682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9683 (exit $ac_status); } &&
9684 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9685 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9686 (eval $ac_try) 2>&5
9687 ac_status=$?
c0d27fcc 9688 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9689 (exit $ac_status); }; }; then
98418dba 9690 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
9691else
9692 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9693sed 's/^/| /' conftest.$ac_ext >&5
9694
98418dba 9695ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0
AS
9696fi
9697rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9698LIBS=$ac_check_lib_save_LIBS
9699fi
c0d27fcc 9700echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
9701echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
9702if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
9703 HAVE_TIFF=yes
9704fi
9705
9706fi
73b77ee5 9707
c0d27fcc 9708
98418dba
CW
9709 fi
9710
9711 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 9712
c0d27fcc 9713cat >>confdefs.h <<\_ACEOF
98418dba 9714#define HAVE_TIFF 1
c0d27fcc 9715_ACEOF
98418dba
CW
9716
9717 fi
73b77ee5
GM
9718fi
9719
98418dba
CW
9720### Use -lgif if available, unless `--with-gif=no'.
9721HAVE_GIF=no
9722if test "${HAVE_X11}" = "yes"; then
9723 if test "${with_gif}" != "no"; then
c0d27fcc
MR
9724 if test "${ac_cv_header_gif_lib_h+set}" = set; then
9725 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
9726echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
9727if test "${ac_cv_header_gif_lib_h+set}" = set; then
9728 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9729fi
9730echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
9731echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 9732else
c0d27fcc
MR
9733 # Is the header compilable?
9734echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
9735echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
9736cat >conftest.$ac_ext <<_ACEOF
9737#line $LINENO "configure"
cd958eb3
MB
9738/* confdefs.h. */
9739_ACEOF
9740cat confdefs.h >>conftest.$ac_ext
9741cat >>conftest.$ac_ext <<_ACEOF
9742/* end confdefs.h. */
c0d27fcc
MR
9743$ac_includes_default
9744#include <gif_lib.h>
9745_ACEOF
9746rm -f conftest.$ac_objext
9747if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9748 (eval $ac_compile) 2>&5
9749 ac_status=$?
9750 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9751 (exit $ac_status); } &&
9752 { ac_try='test -s conftest.$ac_objext'
9753 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9754 (eval $ac_try) 2>&5
9755 ac_status=$?
9756 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9757 (exit $ac_status); }; }; then
9758 ac_header_compiler=yes
9759else
9760 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9761sed 's/^/| /' conftest.$ac_ext >&5
9762
c0d27fcc
MR
9763ac_header_compiler=no
9764fi
9765rm -f conftest.$ac_objext conftest.$ac_ext
9766echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9767echo "${ECHO_T}$ac_header_compiler" >&6
9768
9769# Is the header present?
9770echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
9771echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
9772cat >conftest.$ac_ext <<_ACEOF
9773#line $LINENO "configure"
cd958eb3
MB
9774/* confdefs.h. */
9775_ACEOF
9776cat confdefs.h >>conftest.$ac_ext
9777cat >>conftest.$ac_ext <<_ACEOF
9778/* end confdefs.h. */
98418dba
CW
9779#include <gif_lib.h>
9780_ACEOF
c0d27fcc 9781if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9782 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9783 ac_status=$?
6bae0ccf 9784 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9785 rm -f conftest.er1
9786 cat conftest.err >&5
c0d27fcc 9787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9788 (exit $ac_status); } >/dev/null; then
9789 if test -s conftest.err; then
9790 ac_cpp_err=$ac_c_preproc_warn_flag
9791 else
9792 ac_cpp_err=
9793 fi
9794else
9795 ac_cpp_err=yes
9796fi
9797if test -z "$ac_cpp_err"; then
c0d27fcc 9798 ac_header_preproc=yes
98418dba
CW
9799else
9800 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9801sed 's/^/| /' conftest.$ac_ext >&5
9802
c0d27fcc 9803 ac_header_preproc=no
98418dba
CW
9804fi
9805rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9806echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9807echo "${ECHO_T}$ac_header_preproc" >&6
9808
9809# So? What about this header?
9810case $ac_header_compiler:$ac_header_preproc in
9811 yes:no )
9812 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9813echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9814 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9815echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
9816 (
9817 cat <<\_ASBOX
9818## ------------------------------------ ##
9819## Report this to bug-autoconf@gnu.org. ##
9820## ------------------------------------ ##
9821_ASBOX
9822 ) |
9823 sed "s/^/$as_me: WARNING: /" >&2
9824 ;;
c0d27fcc
MR
9825 no:yes )
9826 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
9827echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
9828 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
9829echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
9830 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9831echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
9832 (
9833 cat <<\_ASBOX
9834## ------------------------------------ ##
9835## Report this to bug-autoconf@gnu.org. ##
9836## ------------------------------------ ##
9837_ASBOX
9838 ) |
9839 sed "s/^/$as_me: WARNING: /" >&2
9840 ;;
c0d27fcc
MR
9841esac
9842echo "$as_me:$LINENO: checking for gif_lib.h" >&5
9843echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
9844if test "${ac_cv_header_gif_lib_h+set}" = set; then
9845 echo $ECHO_N "(cached) $ECHO_C" >&6
9846else
9847 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 9848fi
c0d27fcc 9849echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 9850echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
9851
9852fi
98418dba
CW
9853if test $ac_cv_header_gif_lib_h = yes; then
9854 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
9855# Earlier versions can crash Emacs.
c0d27fcc 9856 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
9857echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
9858if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 9859 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 9860else
503d2be0 9861 ac_check_lib_save_LIBS=$LIBS
98418dba 9862LIBS="-lungif $LIBS"
503d2be0 9863cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9864#line $LINENO "configure"
cd958eb3
MB
9865/* confdefs.h. */
9866_ACEOF
9867cat confdefs.h >>conftest.$ac_ext
9868cat >>conftest.$ac_ext <<_ACEOF
9869/* end confdefs.h. */
73b77ee5 9870
98418dba
CW
9871/* Override any gcc2 internal prototype to avoid an error. */
9872#ifdef __cplusplus
9873extern "C"
9874#endif
9875/* We use char because int might match the return type of a gcc2
9876 builtin and then its argument prototype would still apply. */
9877char EGifPutExtensionLast ();
503d2be0
AS
9878int
9879main ()
9880{
98418dba 9881EGifPutExtensionLast ();
503d2be0
AS
9882 ;
9883 return 0;
9884}
9885_ACEOF
9886rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9887if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9888 (eval $ac_link) 2>&5
9889 ac_status=$?
c0d27fcc 9890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9891 (exit $ac_status); } &&
9892 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9893 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9894 (eval $ac_try) 2>&5
9895 ac_status=$?
c0d27fcc 9896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9897 (exit $ac_status); }; }; then
9898 ac_cv_lib_ungif_EGifPutExtensionLast=yes
9899else
9900 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9901sed 's/^/| /' conftest.$ac_ext >&5
9902
98418dba
CW
9903ac_cv_lib_ungif_EGifPutExtensionLast=no
9904fi
9905rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9906LIBS=$ac_check_lib_save_LIBS
9907fi
c0d27fcc 9908echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
9909echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
9910if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
9911 HAVE_GIF=yes
9912fi
9913
9914fi
9915
c0d27fcc 9916
98418dba
CW
9917 fi
9918
9919 if test "${HAVE_GIF}" = "yes"; then
b936fae4 9920
c0d27fcc 9921cat >>confdefs.h <<\_ACEOF
98418dba 9922#define HAVE_GIF 1
c0d27fcc 9923_ACEOF
98418dba
CW
9924
9925 fi
9926fi
9927
c0d27fcc
MR
9928### Use Mac OS X Carbon API to implement GUI.
9929HAVE_CARBON=no
9930if test "${with_carbon}" != "no"; then
9931 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9932 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
9933echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
9934if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9935 echo $ECHO_N "(cached) $ECHO_C" >&6
9936fi
9937echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
9938echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
9939else
9940 # Is the header compilable?
9941echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
9942echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
9943cat >conftest.$ac_ext <<_ACEOF
9944#line $LINENO "configure"
cd958eb3
MB
9945/* confdefs.h. */
9946_ACEOF
9947cat confdefs.h >>conftest.$ac_ext
9948cat >>conftest.$ac_ext <<_ACEOF
9949/* end confdefs.h. */
c0d27fcc
MR
9950$ac_includes_default
9951#include <Carbon/Carbon.h>
9952_ACEOF
9953rm -f conftest.$ac_objext
9954if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9955 (eval $ac_compile) 2>&5
9956 ac_status=$?
9957 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9958 (exit $ac_status); } &&
9959 { ac_try='test -s conftest.$ac_objext'
9960 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9961 (eval $ac_try) 2>&5
9962 ac_status=$?
9963 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9964 (exit $ac_status); }; }; then
9965 ac_header_compiler=yes
9966else
9967 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9968sed 's/^/| /' conftest.$ac_ext >&5
9969
c0d27fcc
MR
9970ac_header_compiler=no
9971fi
9972rm -f conftest.$ac_objext conftest.$ac_ext
9973echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9974echo "${ECHO_T}$ac_header_compiler" >&6
9975
9976# Is the header present?
9977echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
9978echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
9979cat >conftest.$ac_ext <<_ACEOF
9980#line $LINENO "configure"
cd958eb3
MB
9981/* confdefs.h. */
9982_ACEOF
9983cat confdefs.h >>conftest.$ac_ext
9984cat >>conftest.$ac_ext <<_ACEOF
9985/* end confdefs.h. */
e0f712ba
AC
9986#include <Carbon/Carbon.h>
9987_ACEOF
c0d27fcc 9988if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
e0f712ba
AC
9989 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9990 ac_status=$?
6bae0ccf 9991 grep -v '^ *+' conftest.er1 >conftest.err
e0f712ba
AC
9992 rm -f conftest.er1
9993 cat conftest.err >&5
c0d27fcc 9994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
e0f712ba
AC
9995 (exit $ac_status); } >/dev/null; then
9996 if test -s conftest.err; then
9997 ac_cpp_err=$ac_c_preproc_warn_flag
9998 else
9999 ac_cpp_err=
10000 fi
10001else
10002 ac_cpp_err=yes
10003fi
10004if test -z "$ac_cpp_err"; then
c0d27fcc 10005 ac_header_preproc=yes
e0f712ba
AC
10006else
10007 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10008sed 's/^/| /' conftest.$ac_ext >&5
10009
c0d27fcc 10010 ac_header_preproc=no
e0f712ba
AC
10011fi
10012rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10013echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10014echo "${ECHO_T}$ac_header_preproc" >&6
10015
10016# So? What about this header?
10017case $ac_header_compiler:$ac_header_preproc in
10018 yes:no )
10019 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
10020echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10021 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10022echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
10023 (
10024 cat <<\_ASBOX
10025## ------------------------------------ ##
10026## Report this to bug-autoconf@gnu.org. ##
10027## ------------------------------------ ##
10028_ASBOX
10029 ) |
10030 sed "s/^/$as_me: WARNING: /" >&2
10031 ;;
c0d27fcc
MR
10032 no:yes )
10033 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
10034echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
10035 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
10036echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
10037 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10038echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
10039 (
10040 cat <<\_ASBOX
10041## ------------------------------------ ##
10042## Report this to bug-autoconf@gnu.org. ##
10043## ------------------------------------ ##
10044_ASBOX
10045 ) |
10046 sed "s/^/$as_me: WARNING: /" >&2
10047 ;;
c0d27fcc
MR
10048esac
10049echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
10050echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
10051if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
10052 echo $ECHO_N "(cached) $ECHO_C" >&6
10053else
10054 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
e0f712ba 10055fi
c0d27fcc 10056echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
e0f712ba 10057echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
c0d27fcc
MR
10058
10059fi
e0f712ba
AC
10060if test $ac_cv_header_Carbon_Carbon_h = yes; then
10061 HAVE_CARBON=yes
10062fi
10063
c0d27fcc 10064
e0f712ba
AC
10065fi
10066
10067if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 10068
c0d27fcc 10069cat >>confdefs.h <<\_ACEOF
e0f712ba 10070#define HAVE_CARBON 1
c0d27fcc 10071_ACEOF
e0f712ba 10072
6a3a24fa
JD
10073 window_system=mac
10074 ## Specify the install directory
10075 carbon_appdir=
10076 if test "${carbon_appdir_x}" != ""; then
10077 case ${carbon_appdir_x} in
10078 y | ye | yes) carbon_appdir=/Applications ;;
10079 * ) carbon_appdir=${carbon_appdir_x} ;;
10080 esac
10081 fi
8f417b3b
AS
10082 # We also have mouse menus.
10083 HAVE_MENUS=yes
e0f712ba
AC
10084fi
10085
98418dba
CW
10086### Use session management (-lSM -lICE) if available
10087HAVE_X_SM=no
10088if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
10089 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10090 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
10091echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
10092if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10093 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10094fi
10095echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
10096echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 10097else
c0d27fcc
MR
10098 # Is the header compilable?
10099echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
10100echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
10101cat >conftest.$ac_ext <<_ACEOF
10102#line $LINENO "configure"
cd958eb3
MB
10103/* confdefs.h. */
10104_ACEOF
10105cat confdefs.h >>conftest.$ac_ext
10106cat >>conftest.$ac_ext <<_ACEOF
10107/* end confdefs.h. */
c0d27fcc
MR
10108$ac_includes_default
10109#include <X11/SM/SMlib.h>
10110_ACEOF
10111rm -f conftest.$ac_objext
10112if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10113 (eval $ac_compile) 2>&5
10114 ac_status=$?
10115 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10116 (exit $ac_status); } &&
10117 { ac_try='test -s conftest.$ac_objext'
10118 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10119 (eval $ac_try) 2>&5
10120 ac_status=$?
10121 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10122 (exit $ac_status); }; }; then
10123 ac_header_compiler=yes
10124else
10125 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10126sed 's/^/| /' conftest.$ac_ext >&5
10127
c0d27fcc
MR
10128ac_header_compiler=no
10129fi
10130rm -f conftest.$ac_objext conftest.$ac_ext
10131echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10132echo "${ECHO_T}$ac_header_compiler" >&6
10133
10134# Is the header present?
10135echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
10136echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
10137cat >conftest.$ac_ext <<_ACEOF
10138#line $LINENO "configure"
cd958eb3
MB
10139/* confdefs.h. */
10140_ACEOF
10141cat confdefs.h >>conftest.$ac_ext
10142cat >>conftest.$ac_ext <<_ACEOF
10143/* end confdefs.h. */
98418dba
CW
10144#include <X11/SM/SMlib.h>
10145_ACEOF
c0d27fcc 10146if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10147 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10148 ac_status=$?
6bae0ccf 10149 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10150 rm -f conftest.er1
10151 cat conftest.err >&5
c0d27fcc 10152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10153 (exit $ac_status); } >/dev/null; then
10154 if test -s conftest.err; then
10155 ac_cpp_err=$ac_c_preproc_warn_flag
10156 else
10157 ac_cpp_err=
10158 fi
10159else
10160 ac_cpp_err=yes
503d2be0 10161fi
98418dba 10162if test -z "$ac_cpp_err"; then
c0d27fcc 10163 ac_header_preproc=yes
98418dba
CW
10164else
10165 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10166sed 's/^/| /' conftest.$ac_ext >&5
10167
c0d27fcc 10168 ac_header_preproc=no
98418dba
CW
10169fi
10170rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10171echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10172echo "${ECHO_T}$ac_header_preproc" >&6
10173
10174# So? What about this header?
10175case $ac_header_compiler:$ac_header_preproc in
10176 yes:no )
10177 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
10178echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10179 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10180echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
10181 (
10182 cat <<\_ASBOX
10183## ------------------------------------ ##
10184## Report this to bug-autoconf@gnu.org. ##
10185## ------------------------------------ ##
10186_ASBOX
10187 ) |
10188 sed "s/^/$as_me: WARNING: /" >&2
10189 ;;
c0d27fcc
MR
10190 no:yes )
10191 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
10192echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
10193 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
10194echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
10195 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10196echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
10197 (
10198 cat <<\_ASBOX
10199## ------------------------------------ ##
10200## Report this to bug-autoconf@gnu.org. ##
10201## ------------------------------------ ##
10202_ASBOX
10203 ) |
10204 sed "s/^/$as_me: WARNING: /" >&2
10205 ;;
c0d27fcc
MR
10206esac
10207echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
10208echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
10209if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10210 echo $ECHO_N "(cached) $ECHO_C" >&6
10211else
10212 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 10213fi
c0d27fcc 10214echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 10215echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
10216
10217fi
98418dba 10218if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 10219 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
10220echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
10221if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 10222 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 10223else
503d2be0 10224 ac_check_lib_save_LIBS=$LIBS
98418dba 10225LIBS="-lSM $LIBS"
503d2be0 10226cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10227#line $LINENO "configure"
cd958eb3
MB
10228/* confdefs.h. */
10229_ACEOF
10230cat confdefs.h >>conftest.$ac_ext
10231cat >>conftest.$ac_ext <<_ACEOF
10232/* end confdefs.h. */
503d2be0 10233
73b77ee5 10234/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10235#ifdef __cplusplus
10236extern "C"
10237#endif
73b77ee5 10238/* We use char because int might match the return type of a gcc2
503d2be0 10239 builtin and then its argument prototype would still apply. */
98418dba 10240char SmcOpenConnection ();
503d2be0
AS
10241int
10242main ()
10243{
98418dba 10244SmcOpenConnection ();
503d2be0
AS
10245 ;
10246 return 0;
10247}
10248_ACEOF
10249rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10250if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10251 (eval $ac_link) 2>&5
10252 ac_status=$?
c0d27fcc 10253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10254 (exit $ac_status); } &&
10255 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10256 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10257 (eval $ac_try) 2>&5
10258 ac_status=$?
c0d27fcc 10259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10260 (exit $ac_status); }; }; then
98418dba 10261 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
10262else
10263 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10264sed 's/^/| /' conftest.$ac_ext >&5
10265
98418dba 10266ac_cv_lib_SM_SmcOpenConnection=no
503d2be0
AS
10267fi
10268rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10269LIBS=$ac_check_lib_save_LIBS
10270fi
c0d27fcc 10271echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
10272echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
10273if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
10274 HAVE_X_SM=yes
10275else
10276 -lICE
73b77ee5
GM
10277fi
10278
73b77ee5 10279fi
73b77ee5 10280
c0d27fcc
MR
10281
10282
98418dba 10283 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 10284
c0d27fcc 10285cat >>confdefs.h <<\_ACEOF
98418dba 10286#define HAVE_X_SM 1
c0d27fcc 10287_ACEOF
73b77ee5 10288
98418dba
CW
10289 case "$LIBS" in
10290 *-lSM*) ;;
10291 *) LIBS="-lSM -lICE $LIBS" ;;
10292 esac
73b77ee5 10293 fi
98418dba 10294fi
73b77ee5 10295
98418dba 10296# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 10297echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
10298echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
10299if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
10300 echo $ECHO_N "(cached) $ECHO_C" >&6
10301else
10302 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10303#line $LINENO "configure"
cd958eb3
MB
10304/* confdefs.h. */
10305_ACEOF
10306cat confdefs.h >>conftest.$ac_ext
10307cat >>conftest.$ac_ext <<_ACEOF
10308/* end confdefs.h. */
98418dba 10309#include <netdb.h>
503d2be0
AS
10310int
10311main ()
10312{
98418dba 10313return h_errno;
503d2be0
AS
10314 ;
10315 return 0;
10316}
10317_ACEOF
10318rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10319if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10320 (eval $ac_link) 2>&5
10321 ac_status=$?
c0d27fcc 10322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10323 (exit $ac_status); } &&
10324 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10325 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10326 (eval $ac_try) 2>&5
10327 ac_status=$?
c0d27fcc 10328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10329 (exit $ac_status); }; }; then
98418dba 10330 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 10331else
503d2be0 10332 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10333sed 's/^/| /' conftest.$ac_ext >&5
10334
98418dba 10335emacs_cv_netdb_declares_h_errno=no
73b77ee5 10336fi
503d2be0 10337rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10338fi
c0d27fcc 10339echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
10340echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
10341if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 10342
c0d27fcc 10343cat >>confdefs.h <<\_ACEOF
98418dba 10344#define HAVE_H_ERRNO 1
c0d27fcc 10345_ACEOF
73b77ee5 10346
98418dba
CW
10347fi
10348
10349# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
10350# for constant arguments. Useless!
c0d27fcc 10351echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
10352echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
10353if test "${ac_cv_working_alloca_h+set}" = set; then
10354 echo $ECHO_N "(cached) $ECHO_C" >&6
10355else
10356 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10357#line $LINENO "configure"
cd958eb3
MB
10358/* confdefs.h. */
10359_ACEOF
10360cat confdefs.h >>conftest.$ac_ext
10361cat >>conftest.$ac_ext <<_ACEOF
10362/* end confdefs.h. */
98418dba 10363#include <alloca.h>
503d2be0
AS
10364int
10365main ()
10366{
98418dba 10367char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
10368 ;
10369 return 0;
10370}
10371_ACEOF
10372rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10373if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10374 (eval $ac_link) 2>&5
10375 ac_status=$?
c0d27fcc 10376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10377 (exit $ac_status); } &&
10378 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10379 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10380 (eval $ac_try) 2>&5
10381 ac_status=$?
c0d27fcc 10382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10383 (exit $ac_status); }; }; then
98418dba 10384 ac_cv_working_alloca_h=yes
73b77ee5 10385else
503d2be0 10386 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10387sed 's/^/| /' conftest.$ac_ext >&5
10388
98418dba 10389ac_cv_working_alloca_h=no
73b77ee5 10390fi
503d2be0 10391rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10392fi
c0d27fcc 10393echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
10394echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
10395if test $ac_cv_working_alloca_h = yes; then
73b77ee5 10396
c0d27fcc 10397cat >>confdefs.h <<\_ACEOF
98418dba 10398#define HAVE_ALLOCA_H 1
c0d27fcc 10399_ACEOF
98418dba
CW
10400
10401fi
10402
c0d27fcc 10403echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
10404echo $ECHO_N "checking for alloca... $ECHO_C" >&6
10405if test "${ac_cv_func_alloca_works+set}" = set; then
10406 echo $ECHO_N "(cached) $ECHO_C" >&6
10407else
503d2be0 10408 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10409#line $LINENO "configure"
cd958eb3
MB
10410/* confdefs.h. */
10411_ACEOF
10412cat confdefs.h >>conftest.$ac_ext
10413cat >>conftest.$ac_ext <<_ACEOF
10414/* end confdefs.h. */
98418dba
CW
10415#ifdef __GNUC__
10416# define alloca __builtin_alloca
10417#else
10418# ifdef _MSC_VER
10419# include <malloc.h>
10420# define alloca _alloca
10421# else
10422# if HAVE_ALLOCA_H
10423# include <alloca.h>
10424# else
10425# ifdef _AIX
10426 #pragma alloca
10427# else
10428# ifndef alloca /* predefined by HP cc +Olibcalls */
10429char *alloca ();
10430# endif
10431# endif
10432# endif
10433# endif
10434#endif
10435
503d2be0
AS
10436int
10437main ()
10438{
98418dba 10439char *p = (char *) alloca (1);
503d2be0
AS
10440 ;
10441 return 0;
10442}
10443_ACEOF
10444rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10445if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10446 (eval $ac_link) 2>&5
10447 ac_status=$?
c0d27fcc 10448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10449 (exit $ac_status); } &&
10450 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10451 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10452 (eval $ac_try) 2>&5
10453 ac_status=$?
c0d27fcc 10454 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10455 (exit $ac_status); }; }; then
98418dba 10456 ac_cv_func_alloca_works=yes
ac95a621 10457else
503d2be0 10458 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10459sed 's/^/| /' conftest.$ac_ext >&5
10460
98418dba 10461ac_cv_func_alloca_works=no
ac95a621 10462fi
503d2be0 10463rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10464fi
c0d27fcc 10465echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 10466echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 10467
98418dba
CW
10468if test $ac_cv_func_alloca_works = yes; then
10469
c0d27fcc 10470cat >>confdefs.h <<\_ACEOF
98418dba 10471#define HAVE_ALLOCA 1
c0d27fcc 10472_ACEOF
98418dba
CW
10473
10474else
10475 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
10476# that cause trouble. Some versions do not even contain alloca or
10477# contain a buggy version. If you still want to use their alloca,
10478# use ar to extract alloca.o from them instead of compiling alloca.c.
10479
10480ALLOCA=alloca.$ac_objext
10481
c0d27fcc 10482cat >>confdefs.h <<\_ACEOF
98418dba 10483#define C_ALLOCA 1
c0d27fcc 10484_ACEOF
98418dba 10485
c0d27fcc
MR
10486
10487echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
10488echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
10489if test "${ac_cv_os_cray+set}" = set; then
10490 echo $ECHO_N "(cached) $ECHO_C" >&6
10491else
10492 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10493#line $LINENO "configure"
cd958eb3
MB
10494/* confdefs.h. */
10495_ACEOF
10496cat confdefs.h >>conftest.$ac_ext
10497cat >>conftest.$ac_ext <<_ACEOF
10498/* end confdefs.h. */
98418dba
CW
10499#if defined(CRAY) && ! defined(CRAY2)
10500webecray
10501#else
10502wenotbecray
10503#endif
10504
10505_ACEOF
10506if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10507 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
10508 ac_cv_os_cray=yes
10509else
10510 ac_cv_os_cray=no
10511fi
10512rm -f conftest*
ac95a621 10513
98418dba 10514fi
c0d27fcc 10515echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
10516echo "${ECHO_T}$ac_cv_os_cray" >&6
10517if test $ac_cv_os_cray = yes; then
10518 for ac_func in _getb67 GETB67 getb67; do
10519 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 10520echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
10521echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10522if eval "test \"\${$as_ac_var+set}\" = set"; then
10523 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 10524else
503d2be0 10525 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10526#line $LINENO "configure"
cd958eb3
MB
10527/* confdefs.h. */
10528_ACEOF
10529cat confdefs.h >>conftest.$ac_ext
10530cat >>conftest.$ac_ext <<_ACEOF
10531/* end confdefs.h. */
73b77ee5 10532/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
10533 which can conflict with char $ac_func (); below.
10534 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10535 <limits.h> exists even on freestanding compilers. */
10536#ifdef __STDC__
10537# include <limits.h>
10538#else
10539# include <assert.h>
10540#endif
73b77ee5 10541/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10542#ifdef __cplusplus
10543extern "C"
cd958eb3 10544{
503d2be0 10545#endif
73b77ee5 10546/* We use char because int might match the return type of a gcc2
503d2be0
AS
10547 builtin and then its argument prototype would still apply. */
10548char $ac_func ();
73b77ee5
GM
10549/* The GNU C library defines this for functions which it implements
10550 to always fail with ENOSYS. Some functions are actually named
10551 something starting with __ and the normal name is an alias. */
10552#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10553choke me
10554#else
cd958eb3
MB
10555char (*f) () = $ac_func;
10556#endif
10557#ifdef __cplusplus
10558}
73b77ee5
GM
10559#endif
10560
cd958eb3
MB
10561int
10562main ()
10563{
9e71690e 10564return f != $ac_func;
503d2be0
AS
10565 ;
10566 return 0;
10567}
10568_ACEOF
10569rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10570if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10571 (eval $ac_link) 2>&5
10572 ac_status=$?
c0d27fcc 10573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10574 (exit $ac_status); } &&
10575 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10576 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10577 (eval $ac_try) 2>&5
10578 ac_status=$?
c0d27fcc 10579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10580 (exit $ac_status); }; }; then
10581 eval "$as_ac_var=yes"
10582else
10583 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10584sed 's/^/| /' conftest.$ac_ext >&5
10585
503d2be0
AS
10586eval "$as_ac_var=no"
10587fi
10588rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10589fi
c0d27fcc 10590echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
10591echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10592if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 10593
c0d27fcc 10594cat >>confdefs.h <<_ACEOF
98418dba 10595#define CRAY_STACKSEG_END $ac_func
c0d27fcc 10596_ACEOF
98418dba
CW
10597
10598 break
73b77ee5 10599fi
73b77ee5 10600
98418dba 10601 done
73b77ee5
GM
10602fi
10603
c0d27fcc 10604echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
10605echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
10606if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 10607 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
10608else
10609 if test "$cross_compiling" = yes; then
10610 ac_cv_c_stack_direction=0
73b77ee5 10611else
503d2be0 10612 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10613#line $LINENO "configure"
cd958eb3
MB
10614/* confdefs.h. */
10615_ACEOF
10616cat confdefs.h >>conftest.$ac_ext
10617cat >>conftest.$ac_ext <<_ACEOF
10618/* end confdefs.h. */
503d2be0 10619int
98418dba 10620find_stack_direction ()
503d2be0 10621{
98418dba
CW
10622 static char *addr = 0;
10623 auto char dummy;
10624 if (addr == 0)
10625 {
10626 addr = &dummy;
10627 return find_stack_direction ();
10628 }
73b77ee5 10629 else
98418dba
CW
10630 return (&dummy > addr) ? 1 : -1;
10631}
ba4481b5 10632
503d2be0
AS
10633int
10634main ()
10635{
98418dba 10636 exit (find_stack_direction () < 0);
503d2be0
AS
10637}
10638_ACEOF
98418dba 10639rm -f conftest$ac_exeext
c0d27fcc 10640if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10641 (eval $ac_link) 2>&5
10642 ac_status=$?
c0d27fcc 10643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10644 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 10645 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10646 (eval $ac_try) 2>&5
10647 ac_status=$?
c0d27fcc 10648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10649 (exit $ac_status); }; }; then
98418dba 10650 ac_cv_c_stack_direction=1
ba4481b5 10651else
98418dba
CW
10652 echo "$as_me: program exited with status $ac_status" >&5
10653echo "$as_me: failed program was:" >&5
cd958eb3
MB
10654sed 's/^/| /' conftest.$ac_ext >&5
10655
c0d27fcc 10656( exit $ac_status )
98418dba 10657ac_cv_c_stack_direction=-1
ba4481b5 10658fi
6bae0ccf 10659rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 10660fi
98418dba 10661fi
c0d27fcc 10662echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
10663echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
10664
c0d27fcc 10665cat >>confdefs.h <<_ACEOF
98418dba 10666#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
10667_ACEOF
10668
ba4481b5 10669
ba4481b5
DL
10670fi
10671
c0d27fcc 10672
98418dba
CW
10673# fmod, logb, and frexp are found in -lm on most systems.
10674# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
10675
c0d27fcc 10676echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
10677echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
10678if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 10679 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10680else
98418dba
CW
10681 ac_check_lib_save_LIBS=$LIBS
10682LIBS="-lm $LIBS"
10683cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10684#line $LINENO "configure"
cd958eb3
MB
10685/* confdefs.h. */
10686_ACEOF
10687cat confdefs.h >>conftest.$ac_ext
10688cat >>conftest.$ac_ext <<_ACEOF
10689/* end confdefs.h. */
ba4481b5 10690
98418dba
CW
10691/* Override any gcc2 internal prototype to avoid an error. */
10692#ifdef __cplusplus
10693extern "C"
10694#endif
10695/* We use char because int might match the return type of a gcc2
10696 builtin and then its argument prototype would still apply. */
10697char sqrt ();
503d2be0
AS
10698int
10699main ()
10700{
98418dba 10701sqrt ();
503d2be0
AS
10702 ;
10703 return 0;
10704}
10705_ACEOF
10706rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10707if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10708 (eval $ac_link) 2>&5
10709 ac_status=$?
c0d27fcc 10710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10711 (exit $ac_status); } &&
10712 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10713 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10714 (eval $ac_try) 2>&5
10715 ac_status=$?
c0d27fcc 10716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10717 (exit $ac_status); }; }; then
98418dba 10718 ac_cv_lib_m_sqrt=yes
ba4481b5 10719else
503d2be0 10720 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10721sed 's/^/| /' conftest.$ac_ext >&5
10722
98418dba 10723ac_cv_lib_m_sqrt=no
ba4481b5 10724fi
503d2be0 10725rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10726LIBS=$ac_check_lib_save_LIBS
ba4481b5 10727fi
c0d27fcc 10728echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
10729echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
10730if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 10731 cat >>confdefs.h <<_ACEOF
98418dba 10732#define HAVE_LIBM 1
c0d27fcc 10733_ACEOF
98418dba
CW
10734
10735 LIBS="-lm $LIBS"
ba4481b5 10736
ba4481b5
DL
10737fi
10738
c0d27fcc 10739
98418dba
CW
10740# Check for mail-locking functions in a "mail" library
10741
c0d27fcc 10742echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
10743echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
10744if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 10745 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10746else
98418dba
CW
10747 ac_check_lib_save_LIBS=$LIBS
10748LIBS="-lmail $LIBS"
10749cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10750#line $LINENO "configure"
cd958eb3
MB
10751/* confdefs.h. */
10752_ACEOF
10753cat confdefs.h >>conftest.$ac_ext
10754cat >>conftest.$ac_ext <<_ACEOF
10755/* end confdefs.h. */
98418dba
CW
10756
10757/* Override any gcc2 internal prototype to avoid an error. */
10758#ifdef __cplusplus
10759extern "C"
10760#endif
10761/* We use char because int might match the return type of a gcc2
10762 builtin and then its argument prototype would still apply. */
10763char maillock ();
503d2be0
AS
10764int
10765main ()
10766{
98418dba 10767maillock ();
503d2be0
AS
10768 ;
10769 return 0;
10770}
10771_ACEOF
10772rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10773if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10774 (eval $ac_link) 2>&5
10775 ac_status=$?
c0d27fcc 10776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10777 (exit $ac_status); } &&
10778 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10779 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10780 (eval $ac_try) 2>&5
10781 ac_status=$?
c0d27fcc 10782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10783 (exit $ac_status); }; }; then
98418dba 10784 ac_cv_lib_mail_maillock=yes
ba4481b5 10785else
503d2be0 10786 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10787sed 's/^/| /' conftest.$ac_ext >&5
10788
98418dba 10789ac_cv_lib_mail_maillock=no
ba4481b5 10790fi
503d2be0 10791rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10792LIBS=$ac_check_lib_save_LIBS
ba4481b5 10793fi
c0d27fcc 10794echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
10795echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
10796if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 10797 cat >>confdefs.h <<_ACEOF
98418dba 10798#define HAVE_LIBMAIL 1
c0d27fcc 10799_ACEOF
ba4481b5 10800
98418dba 10801 LIBS="-lmail $LIBS"
ba4481b5 10802
98418dba 10803fi
ba4481b5 10804
c0d27fcc
MR
10805
10806echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
10807echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
10808if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 10809 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10810else
503d2be0 10811 ac_check_lib_save_LIBS=$LIBS
98418dba 10812LIBS="-llockfile $LIBS"
503d2be0 10813cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10814#line $LINENO "configure"
cd958eb3
MB
10815/* confdefs.h. */
10816_ACEOF
10817cat confdefs.h >>conftest.$ac_ext
10818cat >>conftest.$ac_ext <<_ACEOF
10819/* end confdefs.h. */
503d2be0 10820
ba4481b5 10821/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10822#ifdef __cplusplus
10823extern "C"
10824#endif
ba4481b5 10825/* We use char because int might match the return type of a gcc2
503d2be0 10826 builtin and then its argument prototype would still apply. */
98418dba 10827char maillock ();
503d2be0
AS
10828int
10829main ()
10830{
98418dba 10831maillock ();
503d2be0
AS
10832 ;
10833 return 0;
10834}
10835_ACEOF
10836rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10837if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10838 (eval $ac_link) 2>&5
10839 ac_status=$?
c0d27fcc 10840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10841 (exit $ac_status); } &&
10842 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10844 (eval $ac_try) 2>&5
10845 ac_status=$?
c0d27fcc 10846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10847 (exit $ac_status); }; }; then
98418dba 10848 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
10849else
10850 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10851sed 's/^/| /' conftest.$ac_ext >&5
10852
98418dba
CW
10853ac_cv_lib_lockfile_maillock=no
10854fi
10855rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10856LIBS=$ac_check_lib_save_LIBS
10857fi
c0d27fcc 10858echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
10859echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
10860if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 10861 cat >>confdefs.h <<_ACEOF
98418dba 10862#define HAVE_LIBLOCKFILE 1
c0d27fcc 10863_ACEOF
98418dba
CW
10864
10865 LIBS="-llockfile $LIBS"
10866
10867fi
10868
10869# If we have the shared liblockfile, assume we must use it for mail
10870# locking (e.g. Debian). If we couldn't link against liblockfile
10871# (no liblockfile.a installed), ensure that we don't need to.
10872if test "$ac_cv_lib_lockfile_maillock" = no; then
10873 # Extract the first word of "liblockfile.so", so it can be a program name with args.
10874set dummy liblockfile.so; ac_word=$2
c0d27fcc 10875echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
10876echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10877if test "${ac_cv_prog_liblockfile+set}" = set; then
10878 echo $ECHO_N "(cached) $ECHO_C" >&6
10879else
10880 if test -n "$liblockfile"; then
10881 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
10882else
c0d27fcc 10883as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
10884as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
10885for as_dir in $as_dummy
c0d27fcc
MR
10886do
10887 IFS=$as_save_IFS
10888 test -z "$as_dir" && as_dir=.
10889 for ac_exec_ext in '' $ac_executable_extensions; do
10890 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10891 ac_cv_prog_liblockfile="yes"
10892 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10893 break 2
10894 fi
10895done
98418dba
CW
10896done
10897
10898 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 10899fi
503d2be0 10900fi
98418dba
CW
10901liblockfile=$ac_cv_prog_liblockfile
10902if test -n "$liblockfile"; then
c0d27fcc 10903 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
10904echo "${ECHO_T}$liblockfile" >&6
10905else
c0d27fcc 10906 echo "$as_me:$LINENO: result: no" >&5
98418dba 10907echo "${ECHO_T}no" >&6
ba4481b5
DL
10908fi
10909
98418dba 10910 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 10911 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
10912This probably means that movemail could lose mail.
10913There may be a \`development' package to install containing liblockfile." >&5
10914echo "$as_me: error: Shared liblockfile found but can't link against it.
10915This probably means that movemail could lose mail.
10916There may be a \`development' package to install containing liblockfile." >&2;}
10917 { (exit 1); exit 1; }; }
b936fae4 10918 else
c0d27fcc 10919cat >>confdefs.h <<\_ACEOF
98418dba 10920#define LIBMAIL -llockfile
c0d27fcc 10921_ACEOF
457b792c 10922
98418dba
CW
10923 fi
10924 else :
10925fi
503d2be0 10926
98418dba
CW
10927for ac_func in touchlock
10928do
10929as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 10930echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
10931echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10932if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 10933 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 10934else
98418dba 10935 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10936#line $LINENO "configure"
cd958eb3
MB
10937/* confdefs.h. */
10938_ACEOF
10939cat confdefs.h >>conftest.$ac_ext
10940cat >>conftest.$ac_ext <<_ACEOF
10941/* end confdefs.h. */
98418dba 10942/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
10943 which can conflict with char $ac_func (); below.
10944 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10945 <limits.h> exists even on freestanding compilers. */
10946#ifdef __STDC__
10947# include <limits.h>
10948#else
10949# include <assert.h>
10950#endif
457b792c 10951/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10952#ifdef __cplusplus
10953extern "C"
cd958eb3 10954{
503d2be0 10955#endif
457b792c 10956/* We use char because int might match the return type of a gcc2
503d2be0 10957 builtin and then its argument prototype would still apply. */
98418dba 10958char $ac_func ();
98418dba
CW
10959/* The GNU C library defines this for functions which it implements
10960 to always fail with ENOSYS. Some functions are actually named
10961 something starting with __ and the normal name is an alias. */
10962#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10963choke me
10964#else
cd958eb3 10965char (*f) () = $ac_func;
98418dba 10966#endif
cd958eb3
MB
10967#ifdef __cplusplus
10968}
10969#endif
10970
10971int
10972main ()
10973{
9e71690e 10974return f != $ac_func;
503d2be0
AS
10975 ;
10976 return 0;
10977}
10978_ACEOF
10979rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10980if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10981 (eval $ac_link) 2>&5
10982 ac_status=$?
c0d27fcc 10983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10984 (exit $ac_status); } &&
10985 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10986 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10987 (eval $ac_try) 2>&5
10988 ac_status=$?
c0d27fcc 10989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10990 (exit $ac_status); }; }; then
98418dba 10991 eval "$as_ac_var=yes"
503d2be0
AS
10992else
10993 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10994sed 's/^/| /' conftest.$ac_ext >&5
10995
98418dba 10996eval "$as_ac_var=no"
503d2be0
AS
10997fi
10998rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 10999fi
c0d27fcc 11000echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
11001echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11002if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 11003 cat >>confdefs.h <<_ACEOF
98418dba 11004#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11005_ACEOF
457b792c 11006
457b792c 11007fi
98418dba 11008done
457b792c 11009
c0d27fcc 11010
98418dba
CW
11011for ac_header in maillock.h
11012do
11013as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11014if eval "test \"\${$as_ac_Header+set}\" = set"; then
11015 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
11016echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11017if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11018 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11019fi
11020echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11021echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 11022else
c0d27fcc
MR
11023 # Is the header compilable?
11024echo "$as_me:$LINENO: checking $ac_header usability" >&5
11025echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11026cat >conftest.$ac_ext <<_ACEOF
11027#line $LINENO "configure"
cd958eb3
MB
11028/* confdefs.h. */
11029_ACEOF
11030cat confdefs.h >>conftest.$ac_ext
11031cat >>conftest.$ac_ext <<_ACEOF
11032/* end confdefs.h. */
c0d27fcc
MR
11033$ac_includes_default
11034#include <$ac_header>
11035_ACEOF
11036rm -f conftest.$ac_objext
11037if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11038 (eval $ac_compile) 2>&5
11039 ac_status=$?
11040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11041 (exit $ac_status); } &&
11042 { ac_try='test -s conftest.$ac_objext'
11043 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11044 (eval $ac_try) 2>&5
11045 ac_status=$?
11046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11047 (exit $ac_status); }; }; then
11048 ac_header_compiler=yes
11049else
11050 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11051sed 's/^/| /' conftest.$ac_ext >&5
11052
c0d27fcc
MR
11053ac_header_compiler=no
11054fi
11055rm -f conftest.$ac_objext conftest.$ac_ext
11056echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11057echo "${ECHO_T}$ac_header_compiler" >&6
11058
11059# Is the header present?
11060echo "$as_me:$LINENO: checking $ac_header presence" >&5
11061echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11062cat >conftest.$ac_ext <<_ACEOF
11063#line $LINENO "configure"
cd958eb3
MB
11064/* confdefs.h. */
11065_ACEOF
11066cat confdefs.h >>conftest.$ac_ext
11067cat >>conftest.$ac_ext <<_ACEOF
11068/* end confdefs.h. */
98418dba 11069#include <$ac_header>
503d2be0 11070_ACEOF
c0d27fcc 11071if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 11072 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 11073 ac_status=$?
6bae0ccf 11074 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11075 rm -f conftest.er1
11076 cat conftest.err >&5
c0d27fcc 11077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11078 (exit $ac_status); } >/dev/null; then
11079 if test -s conftest.err; then
11080 ac_cpp_err=$ac_c_preproc_warn_flag
11081 else
11082 ac_cpp_err=
11083 fi
503d2be0 11084else
98418dba 11085 ac_cpp_err=yes
503d2be0 11086fi
98418dba 11087if test -z "$ac_cpp_err"; then
c0d27fcc 11088 ac_header_preproc=yes
98418dba
CW
11089else
11090 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11091sed 's/^/| /' conftest.$ac_ext >&5
11092
c0d27fcc 11093 ac_header_preproc=no
503d2be0 11094fi
98418dba 11095rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11096echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11097echo "${ECHO_T}$ac_header_preproc" >&6
11098
11099# So? What about this header?
11100case $ac_header_compiler:$ac_header_preproc in
11101 yes:no )
11102 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11103echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11104 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11105echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11106 (
11107 cat <<\_ASBOX
11108## ------------------------------------ ##
11109## Report this to bug-autoconf@gnu.org. ##
11110## ------------------------------------ ##
11111_ASBOX
11112 ) |
11113 sed "s/^/$as_me: WARNING: /" >&2
11114 ;;
c0d27fcc
MR
11115 no:yes )
11116 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11117echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11118 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11119echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11120 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11121echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11122 (
11123 cat <<\_ASBOX
11124## ------------------------------------ ##
11125## Report this to bug-autoconf@gnu.org. ##
11126## ------------------------------------ ##
11127_ASBOX
11128 ) |
11129 sed "s/^/$as_me: WARNING: /" >&2
11130 ;;
c0d27fcc
MR
11131esac
11132echo "$as_me:$LINENO: checking for $ac_header" >&5
11133echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11134if eval "test \"\${$as_ac_Header+set}\" = set"; then
11135 echo $ECHO_N "(cached) $ECHO_C" >&6
11136else
11137 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 11138fi
c0d27fcc 11139echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 11140echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11141
11142fi
98418dba 11143if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11144 cat >>confdefs.h <<_ACEOF
98418dba 11145#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11146_ACEOF
48d4b120 11147
ba4481b5 11148fi
c0d27fcc 11149
98418dba
CW
11150done
11151
c0d27fcc
MR
11152
11153
11154
11155
11156
11157
11158
11159
11160
11161
11162
11163
11164
11165
11166
11167
11168
11169
11170
11171
11172
11173
11174
11175
11176
11177
11178
11179
11180
11181
11182
11183
11184
11185
11186
11187
11188
11189
11190
11191
11192
11193
11194
11195
11196
11197
11198
11199
11200
11201
11202
11203
11204
11205
11206
22044edf
DL
11207
11208
c0d27fcc 11209
b0e44248
RB
11210
11211
cd958eb3 11212
c0d27fcc
MR
11213
11214
98418dba
CW
11215for ac_func in gethostname getdomainname dup2 \
11216rename closedir mkdir rmdir sysinfo \
11217random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
11218strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
11219utimes setrlimit setpgid getcwd getwd shutdown strftime getaddrinfo \
11220__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
11221sendto recvfrom getsockopt setsockopt getsockname getpeername \
b0e44248
RB
11222gai_strerror mkstemp getline getdelim mremap memmove fsync bzero \
11223memset memcmp memmove
98418dba
CW
11224do
11225as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11226echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11227echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11228if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11229 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11230else
503d2be0 11231 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11232#line $LINENO "configure"
cd958eb3
MB
11233/* confdefs.h. */
11234_ACEOF
11235cat confdefs.h >>conftest.$ac_ext
11236cat >>conftest.$ac_ext <<_ACEOF
11237/* end confdefs.h. */
98418dba 11238/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11239 which can conflict with char $ac_func (); below.
11240 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11241 <limits.h> exists even on freestanding compilers. */
11242#ifdef __STDC__
11243# include <limits.h>
11244#else
11245# include <assert.h>
11246#endif
ba4481b5 11247/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11248#ifdef __cplusplus
11249extern "C"
cd958eb3 11250{
503d2be0 11251#endif
ba4481b5 11252/* We use char because int might match the return type of a gcc2
503d2be0 11253 builtin and then its argument prototype would still apply. */
98418dba 11254char $ac_func ();
98418dba
CW
11255/* The GNU C library defines this for functions which it implements
11256 to always fail with ENOSYS. Some functions are actually named
11257 something starting with __ and the normal name is an alias. */
11258#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11259choke me
11260#else
cd958eb3
MB
11261char (*f) () = $ac_func;
11262#endif
11263#ifdef __cplusplus
11264}
98418dba
CW
11265#endif
11266
cd958eb3
MB
11267int
11268main ()
11269{
9e71690e 11270return f != $ac_func;
503d2be0
AS
11271 ;
11272 return 0;
11273}
11274_ACEOF
11275rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11276if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11277 (eval $ac_link) 2>&5
11278 ac_status=$?
c0d27fcc 11279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11280 (exit $ac_status); } &&
11281 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11282 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11283 (eval $ac_try) 2>&5
11284 ac_status=$?
c0d27fcc 11285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11286 (exit $ac_status); }; }; then
98418dba 11287 eval "$as_ac_var=yes"
503d2be0
AS
11288else
11289 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11290sed 's/^/| /' conftest.$ac_ext >&5
11291
98418dba 11292eval "$as_ac_var=no"
503d2be0
AS
11293fi
11294rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 11295fi
c0d27fcc 11296echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
11297echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11298if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 11299 cat >>confdefs.h <<_ACEOF
98418dba 11300#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11301_ACEOF
ba4481b5 11302
ba4481b5 11303fi
98418dba 11304done
ba4481b5 11305
c0d27fcc
MR
11306
11307
98418dba
CW
11308for ac_header in sys/un.h
11309do
11310as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11311if eval "test \"\${$as_ac_Header+set}\" = set"; then
11312 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
11313echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11314if eval "test \"\${$as_ac_Header+set}\" = set"; then
11315 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11316fi
11317echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11318echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 11319else
c0d27fcc
MR
11320 # Is the header compilable?
11321echo "$as_me:$LINENO: checking $ac_header usability" >&5
11322echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11323cat >conftest.$ac_ext <<_ACEOF
11324#line $LINENO "configure"
cd958eb3
MB
11325/* confdefs.h. */
11326_ACEOF
11327cat confdefs.h >>conftest.$ac_ext
11328cat >>conftest.$ac_ext <<_ACEOF
11329/* end confdefs.h. */
c0d27fcc
MR
11330$ac_includes_default
11331#include <$ac_header>
11332_ACEOF
11333rm -f conftest.$ac_objext
11334if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11335 (eval $ac_compile) 2>&5
11336 ac_status=$?
11337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11338 (exit $ac_status); } &&
11339 { ac_try='test -s conftest.$ac_objext'
11340 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11341 (eval $ac_try) 2>&5
11342 ac_status=$?
11343 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11344 (exit $ac_status); }; }; then
11345 ac_header_compiler=yes
11346else
11347 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11348sed 's/^/| /' conftest.$ac_ext >&5
11349
c0d27fcc
MR
11350ac_header_compiler=no
11351fi
11352rm -f conftest.$ac_objext conftest.$ac_ext
11353echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11354echo "${ECHO_T}$ac_header_compiler" >&6
11355
11356# Is the header present?
11357echo "$as_me:$LINENO: checking $ac_header presence" >&5
11358echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11359cat >conftest.$ac_ext <<_ACEOF
11360#line $LINENO "configure"
cd958eb3
MB
11361/* confdefs.h. */
11362_ACEOF
11363cat confdefs.h >>conftest.$ac_ext
11364cat >>conftest.$ac_ext <<_ACEOF
11365/* end confdefs.h. */
98418dba 11366#include <$ac_header>
503d2be0 11367_ACEOF
c0d27fcc 11368if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11369 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11370 ac_status=$?
6bae0ccf 11371 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11372 rm -f conftest.er1
11373 cat conftest.err >&5
c0d27fcc 11374 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11375 (exit $ac_status); } >/dev/null; then
11376 if test -s conftest.err; then
11377 ac_cpp_err=$ac_c_preproc_warn_flag
11378 else
11379 ac_cpp_err=
11380 fi
11381else
11382 ac_cpp_err=yes
11383fi
11384if test -z "$ac_cpp_err"; then
c0d27fcc 11385 ac_header_preproc=yes
ba4481b5 11386else
503d2be0 11387 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11388sed 's/^/| /' conftest.$ac_ext >&5
11389
c0d27fcc 11390 ac_header_preproc=no
ba4481b5 11391fi
503d2be0 11392rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11393echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11394echo "${ECHO_T}$ac_header_preproc" >&6
11395
11396# So? What about this header?
11397case $ac_header_compiler:$ac_header_preproc in
11398 yes:no )
11399 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11400echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11401 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11402echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11403 (
11404 cat <<\_ASBOX
11405## ------------------------------------ ##
11406## Report this to bug-autoconf@gnu.org. ##
11407## ------------------------------------ ##
11408_ASBOX
11409 ) |
11410 sed "s/^/$as_me: WARNING: /" >&2
11411 ;;
c0d27fcc
MR
11412 no:yes )
11413 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11414echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11415 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11416echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11417 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11418echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11419 (
11420 cat <<\_ASBOX
11421## ------------------------------------ ##
11422## Report this to bug-autoconf@gnu.org. ##
11423## ------------------------------------ ##
11424_ASBOX
11425 ) |
11426 sed "s/^/$as_me: WARNING: /" >&2
11427 ;;
c0d27fcc
MR
11428esac
11429echo "$as_me:$LINENO: checking for $ac_header" >&5
11430echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11431if eval "test \"\${$as_ac_Header+set}\" = set"; then
11432 echo $ECHO_N "(cached) $ECHO_C" >&6
11433else
11434 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 11435fi
c0d27fcc 11436echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 11437echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11438
11439fi
925c2f3f 11440if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11441 cat >>confdefs.h <<_ACEOF
925c2f3f 11442#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11443_ACEOF
503d2be0 11444
925c2f3f 11445fi
c0d27fcc 11446
925c2f3f
EZ
11447done
11448
c0d27fcc
MR
11449
11450
11451
925c2f3f
EZ
11452for ac_header in sys/time.h unistd.h
11453do
11454as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11455if eval "test \"\${$as_ac_Header+set}\" = set"; then
11456 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
11457echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11458if eval "test \"\${$as_ac_Header+set}\" = set"; then
11459 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11460fi
11461echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11462echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 11463else
c0d27fcc
MR
11464 # Is the header compilable?
11465echo "$as_me:$LINENO: checking $ac_header usability" >&5
11466echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11467cat >conftest.$ac_ext <<_ACEOF
11468#line $LINENO "configure"
cd958eb3
MB
11469/* confdefs.h. */
11470_ACEOF
11471cat confdefs.h >>conftest.$ac_ext
11472cat >>conftest.$ac_ext <<_ACEOF
11473/* end confdefs.h. */
c0d27fcc
MR
11474$ac_includes_default
11475#include <$ac_header>
11476_ACEOF
11477rm -f conftest.$ac_objext
11478if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11479 (eval $ac_compile) 2>&5
11480 ac_status=$?
11481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11482 (exit $ac_status); } &&
11483 { ac_try='test -s conftest.$ac_objext'
11484 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11485 (eval $ac_try) 2>&5
11486 ac_status=$?
11487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11488 (exit $ac_status); }; }; then
11489 ac_header_compiler=yes
11490else
11491 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11492sed 's/^/| /' conftest.$ac_ext >&5
11493
c0d27fcc
MR
11494ac_header_compiler=no
11495fi
11496rm -f conftest.$ac_objext conftest.$ac_ext
11497echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11498echo "${ECHO_T}$ac_header_compiler" >&6
11499
11500# Is the header present?
11501echo "$as_me:$LINENO: checking $ac_header presence" >&5
11502echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11503cat >conftest.$ac_ext <<_ACEOF
11504#line $LINENO "configure"
cd958eb3
MB
11505/* confdefs.h. */
11506_ACEOF
11507cat confdefs.h >>conftest.$ac_ext
11508cat >>conftest.$ac_ext <<_ACEOF
11509/* end confdefs.h. */
98418dba 11510#include <$ac_header>
503d2be0 11511_ACEOF
c0d27fcc 11512if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11513 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11514 ac_status=$?
6bae0ccf 11515 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11516 rm -f conftest.er1
11517 cat conftest.err >&5
c0d27fcc 11518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11519 (exit $ac_status); } >/dev/null; then
11520 if test -s conftest.err; then
11521 ac_cpp_err=$ac_c_preproc_warn_flag
11522 else
11523 ac_cpp_err=
11524 fi
11525else
11526 ac_cpp_err=yes
11527fi
11528if test -z "$ac_cpp_err"; then
c0d27fcc 11529 ac_header_preproc=yes
98418dba
CW
11530else
11531 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11532sed 's/^/| /' conftest.$ac_ext >&5
11533
c0d27fcc 11534 ac_header_preproc=no
98418dba
CW
11535fi
11536rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11537echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11538echo "${ECHO_T}$ac_header_preproc" >&6
11539
11540# So? What about this header?
11541case $ac_header_compiler:$ac_header_preproc in
11542 yes:no )
11543 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11544echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11545 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11546echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11547 (
11548 cat <<\_ASBOX
11549## ------------------------------------ ##
11550## Report this to bug-autoconf@gnu.org. ##
11551## ------------------------------------ ##
11552_ASBOX
11553 ) |
11554 sed "s/^/$as_me: WARNING: /" >&2
11555 ;;
c0d27fcc
MR
11556 no:yes )
11557 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11558echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11559 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11560echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11561 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11562echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11563 (
11564 cat <<\_ASBOX
11565## ------------------------------------ ##
11566## Report this to bug-autoconf@gnu.org. ##
11567## ------------------------------------ ##
11568_ASBOX
11569 ) |
11570 sed "s/^/$as_me: WARNING: /" >&2
11571 ;;
c0d27fcc
MR
11572esac
11573echo "$as_me:$LINENO: checking for $ac_header" >&5
11574echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11575if eval "test \"\${$as_ac_Header+set}\" = set"; then
11576 echo $ECHO_N "(cached) $ECHO_C" >&6
11577else
11578 eval "$as_ac_Header=$ac_header_preproc"
ffe36136 11579fi
c0d27fcc 11580echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 11581echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11582
11583fi
98418dba 11584if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11585 cat >>confdefs.h <<_ACEOF
98418dba 11586#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11587_ACEOF
98418dba
CW
11588
11589fi
c0d27fcc 11590
98418dba
CW
11591done
11592
c0d27fcc 11593
98418dba
CW
11594for ac_func in alarm
11595do
11596as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11597echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11598echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11599if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11600 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11601else
98418dba 11602 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11603#line $LINENO "configure"
cd958eb3
MB
11604/* confdefs.h. */
11605_ACEOF
11606cat confdefs.h >>conftest.$ac_ext
11607cat >>conftest.$ac_ext <<_ACEOF
11608/* end confdefs.h. */
98418dba 11609/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11610 which can conflict with char $ac_func (); below.
11611 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11612 <limits.h> exists even on freestanding compilers. */
11613#ifdef __STDC__
11614# include <limits.h>
11615#else
11616# include <assert.h>
11617#endif
ba4481b5 11618/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11619#ifdef __cplusplus
11620extern "C"
cd958eb3 11621{
503d2be0 11622#endif
ba4481b5 11623/* We use char because int might match the return type of a gcc2
503d2be0 11624 builtin and then its argument prototype would still apply. */
98418dba 11625char $ac_func ();
98418dba
CW
11626/* The GNU C library defines this for functions which it implements
11627 to always fail with ENOSYS. Some functions are actually named
11628 something starting with __ and the normal name is an alias. */
11629#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11630choke me
11631#else
cd958eb3
MB
11632char (*f) () = $ac_func;
11633#endif
11634#ifdef __cplusplus
11635}
98418dba
CW
11636#endif
11637
cd958eb3
MB
11638int
11639main ()
11640{
9e71690e 11641return f != $ac_func;
503d2be0
AS
11642 ;
11643 return 0;
11644}
11645_ACEOF
11646rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11647if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11648 (eval $ac_link) 2>&5
11649 ac_status=$?
c0d27fcc 11650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11651 (exit $ac_status); } &&
11652 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11653 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11654 (eval $ac_try) 2>&5
11655 ac_status=$?
c0d27fcc 11656 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11657 (exit $ac_status); }; }; then
98418dba 11658 eval "$as_ac_var=yes"
503d2be0
AS
11659else
11660 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11661sed 's/^/| /' conftest.$ac_ext >&5
11662
98418dba 11663eval "$as_ac_var=no"
503d2be0
AS
11664fi
11665rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ffe36136 11666fi
c0d27fcc 11667echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
11668echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11669if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 11670 cat >>confdefs.h <<_ACEOF
98418dba 11671#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11672_ACEOF
ffe36136 11673
ba4481b5 11674fi
98418dba 11675done
ba4481b5 11676
c0d27fcc 11677echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
11678echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
11679if test "${ac_cv_func_working_mktime+set}" = set; then
11680 echo $ECHO_N "(cached) $ECHO_C" >&6
11681else
11682 if test "$cross_compiling" = yes; then
11683 ac_cv_func_working_mktime=no
11684else
11685 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11686#line $LINENO "configure"
cd958eb3
MB
11687/* confdefs.h. */
11688_ACEOF
11689cat confdefs.h >>conftest.$ac_ext
11690cat >>conftest.$ac_ext <<_ACEOF
11691/* end confdefs.h. */
98418dba
CW
11692/* Test program from Paul Eggert and Tony Leneis. */
11693#if TIME_WITH_SYS_TIME
11694# include <sys/time.h>
11695# include <time.h>
11696#else
11697# if HAVE_SYS_TIME_H
11698# include <sys/time.h>
11699# else
11700# include <time.h>
11701# endif
11702#endif
ba4481b5 11703
98418dba
CW
11704#if HAVE_UNISTD_H
11705# include <unistd.h>
11706#endif
ba4481b5 11707
98418dba
CW
11708#if !HAVE_ALARM
11709# define alarm(X) /* empty */
11710#endif
df645f7c 11711
98418dba
CW
11712/* Work around redefinition to rpl_putenv by other config tests. */
11713#undef putenv
df645f7c 11714
98418dba 11715static time_t time_t_max;
df645f7c 11716
98418dba
CW
11717/* Values we'll use to set the TZ environment variable. */
11718static const char *const tz_strings[] = {
11719 (const char *) 0, "TZ=GMT0", "TZ=JST-9",
11720 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
11721};
11722#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 11723
98418dba
CW
11724/* Fail if mktime fails to convert a date in the spring-forward gap.
11725 Based on a problem report from Andreas Jaeger. */
11726static void
11727spring_forward_gap ()
11728{
11729 /* glibc (up to about 1998-10-07) failed this test. */
11730 struct tm tm;
11731
11732 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11733 instead of "TZ=America/Vancouver" in order to detect the bug even
11734 on systems that don't support the Olson extension, or don't have the
11735 full zoneinfo tables installed. */
11736 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11737
11738 tm.tm_year = 98;
11739 tm.tm_mon = 3;
11740 tm.tm_mday = 5;
11741 tm.tm_hour = 2;
11742 tm.tm_min = 0;
11743 tm.tm_sec = 0;
11744 tm.tm_isdst = -1;
11745 if (mktime (&tm) == (time_t)-1)
11746 exit (1);
11747}
11748
11749static void
11750mktime_test (now)
11751 time_t now;
11752{
11753 struct tm *lt;
11754 if ((lt = localtime (&now)) && mktime (lt) != now)
11755 exit (1);
11756 now = time_t_max - now;
11757 if ((lt = localtime (&now)) && mktime (lt) != now)
11758 exit (1);
11759}
11760
11761static void
11762irix_6_4_bug ()
11763{
11764 /* Based on code from Ariel Faigon. */
11765 struct tm tm;
11766 tm.tm_year = 96;
11767 tm.tm_mon = 3;
11768 tm.tm_mday = 0;
11769 tm.tm_hour = 0;
11770 tm.tm_min = 0;
11771 tm.tm_sec = 0;
11772 tm.tm_isdst = -1;
11773 mktime (&tm);
11774 if (tm.tm_mon != 2 || tm.tm_mday != 31)
11775 exit (1);
11776}
11777
11778static void
11779bigtime_test (j)
11780 int j;
11781{
11782 struct tm tm;
11783 time_t now;
11784 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
11785 now = mktime (&tm);
11786 if (now != (time_t) -1)
11787 {
11788 struct tm *lt = localtime (&now);
11789 if (! (lt
11790 && lt->tm_year == tm.tm_year
11791 && lt->tm_mon == tm.tm_mon
11792 && lt->tm_mday == tm.tm_mday
11793 && lt->tm_hour == tm.tm_hour
11794 && lt->tm_min == tm.tm_min
11795 && lt->tm_sec == tm.tm_sec
11796 && lt->tm_yday == tm.tm_yday
11797 && lt->tm_wday == tm.tm_wday
11798 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
11799 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
11800 exit (1);
11801 }
11802}
11803
11804int
11805main ()
11806{
11807 time_t t, delta;
11808 int i, j;
11809
11810 /* This test makes some buggy mktime implementations loop.
11811 Give up after 60 seconds; a mktime slower than that
11812 isn't worth using anyway. */
11813 alarm (60);
11814
11815 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
11816 continue;
11817 time_t_max--;
11818 delta = time_t_max / 997; /* a suitable prime number */
11819 for (i = 0; i < N_STRINGS; i++)
11820 {
11821 if (tz_strings[i])
11822 putenv (tz_strings[i]);
503d2be0 11823
98418dba
CW
11824 for (t = 0; t <= time_t_max - delta; t += delta)
11825 mktime_test (t);
11826 mktime_test ((time_t) 60 * 60);
11827 mktime_test ((time_t) 60 * 60 * 24);
11828
11829 for (j = 1; 0 < j; j *= 2)
11830 bigtime_test (j);
11831 bigtime_test (j - 1);
11832 }
11833 irix_6_4_bug ();
11834 spring_forward_gap ();
11835 exit (0);
503d2be0
AS
11836}
11837_ACEOF
98418dba 11838rm -f conftest$ac_exeext
c0d27fcc 11839if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11840 (eval $ac_link) 2>&5
11841 ac_status=$?
c0d27fcc 11842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11843 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 11844 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11845 (eval $ac_try) 2>&5
11846 ac_status=$?
c0d27fcc 11847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11848 (exit $ac_status); }; }; then
98418dba 11849 ac_cv_func_working_mktime=yes
503d2be0 11850else
98418dba
CW
11851 echo "$as_me: program exited with status $ac_status" >&5
11852echo "$as_me: failed program was:" >&5
cd958eb3
MB
11853sed 's/^/| /' conftest.$ac_ext >&5
11854
c0d27fcc 11855( exit $ac_status )
98418dba 11856ac_cv_func_working_mktime=no
503d2be0 11857fi
6bae0ccf 11858rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 11859fi
ba4481b5 11860fi
c0d27fcc 11861echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
11862echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
11863if test $ac_cv_func_working_mktime = no; then
11864 LIBOBJS="$LIBOBJS mktime.$ac_objext"
ba4481b5
DL
11865fi
11866
98418dba 11867if test "$ac_cv_func_working_mktime" = no; then
b936fae4 11868
c0d27fcc 11869cat >>confdefs.h <<\_ACEOF
98418dba 11870#define BROKEN_MKTIME 1
c0d27fcc 11871_ACEOF
ba4481b5 11872
ba4481b5 11873fi
503d2be0 11874
98418dba
CW
11875ac_have_func=no # yes means we've found a way to get the load average.
11876
6bae0ccf
DL
11877# Make sure getloadavg.c is where it belongs, at configure-time.
11878test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
11879 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
11880echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
11881 { (exit 1); exit 1; }; }
11882
98418dba
CW
11883ac_save_LIBS=$LIBS
11884
11885# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 11886(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
11887echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
11888if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 11889 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11890else
503d2be0 11891 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11892#line $LINENO "configure"
cd958eb3
MB
11893/* confdefs.h. */
11894_ACEOF
11895cat confdefs.h >>conftest.$ac_ext
11896cat >>conftest.$ac_ext <<_ACEOF
11897/* end confdefs.h. */
98418dba 11898/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11899 which can conflict with char getloadavg (); below.
11900 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11901 <limits.h> exists even on freestanding compilers. */
11902#ifdef __STDC__
11903# include <limits.h>
11904#else
11905# include <assert.h>
11906#endif
ba4481b5 11907/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11908#ifdef __cplusplus
11909extern "C"
cd958eb3 11910{
503d2be0 11911#endif
ba4481b5 11912/* We use char because int might match the return type of a gcc2
503d2be0 11913 builtin and then its argument prototype would still apply. */
98418dba 11914char getloadavg ();
98418dba
CW
11915/* The GNU C library defines this for functions which it implements
11916 to always fail with ENOSYS. Some functions are actually named
11917 something starting with __ and the normal name is an alias. */
11918#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
11919choke me
11920#else
cd958eb3 11921char (*f) () = getloadavg;
98418dba 11922#endif
cd958eb3
MB
11923#ifdef __cplusplus
11924}
11925#endif
11926
11927int
11928main ()
11929{
9e71690e 11930return f != getloadavg;
503d2be0
AS
11931 ;
11932 return 0;
11933}
11934_ACEOF
11935rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11936if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11937 (eval $ac_link) 2>&5
11938 ac_status=$?
c0d27fcc 11939 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11940 (exit $ac_status); } &&
11941 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11942 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11943 (eval $ac_try) 2>&5
11944 ac_status=$?
c0d27fcc 11945 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11946 (exit $ac_status); }; }; then
98418dba 11947 ac_cv_func_getloadavg=yes
503d2be0
AS
11948else
11949 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11950sed 's/^/| /' conftest.$ac_ext >&5
11951
98418dba 11952ac_cv_func_getloadavg=no
503d2be0
AS
11953fi
11954rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 11955fi
c0d27fcc 11956echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
11957echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
11958if test $ac_cv_func_getloadavg = yes; then
11959 exit 0
11960else
11961 exit 1
ba4481b5 11962fi
98418dba 11963) && ac_have_func=yes
ba4481b5 11964
98418dba 11965# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 11966
98418dba
CW
11967for ac_func in pstat_getdynamic
11968do
11969as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11970echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11971echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11972if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11973 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11974else
503d2be0 11975 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11976#line $LINENO "configure"
cd958eb3
MB
11977/* confdefs.h. */
11978_ACEOF
11979cat confdefs.h >>conftest.$ac_ext
11980cat >>conftest.$ac_ext <<_ACEOF
11981/* end confdefs.h. */
98418dba 11982/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11983 which can conflict with char $ac_func (); below.
11984 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11985 <limits.h> exists even on freestanding compilers. */
11986#ifdef __STDC__
11987# include <limits.h>
11988#else
11989# include <assert.h>
11990#endif
ba4481b5 11991/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11992#ifdef __cplusplus
11993extern "C"
cd958eb3 11994{
503d2be0 11995#endif
ba4481b5 11996/* We use char because int might match the return type of a gcc2
503d2be0 11997 builtin and then its argument prototype would still apply. */
98418dba 11998char $ac_func ();
98418dba
CW
11999/* The GNU C library defines this for functions which it implements
12000 to always fail with ENOSYS. Some functions are actually named
12001 something starting with __ and the normal name is an alias. */
12002#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12003choke me
12004#else
cd958eb3
MB
12005char (*f) () = $ac_func;
12006#endif
12007#ifdef __cplusplus
12008}
98418dba
CW
12009#endif
12010
cd958eb3
MB
12011int
12012main ()
12013{
9e71690e 12014return f != $ac_func;
98418dba
CW
12015 ;
12016 return 0;
12017}
f21fadcc 12018_ACEOF
98418dba 12019rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12020if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 12021 (eval $ac_link) 2>&5
f21fadcc 12022 ac_status=$?
c0d27fcc 12023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12024 (exit $ac_status); } &&
12025 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
12027 (eval $ac_try) 2>&5
12028 ac_status=$?
c0d27fcc 12029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12030 (exit $ac_status); }; }; then
12031 eval "$as_ac_var=yes"
f21fadcc
JD
12032else
12033 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12034sed 's/^/| /' conftest.$ac_ext >&5
12035
98418dba 12036eval "$as_ac_var=no"
f21fadcc 12037fi
98418dba 12038rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
f21fadcc 12039fi
c0d27fcc 12040echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
12041echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12042if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12043 cat >>confdefs.h <<_ACEOF
98418dba 12044#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12045_ACEOF
98418dba
CW
12046
12047fi
12048done
12049
c0d27fcc 12050
98418dba
CW
12051# Solaris has libkstat which does not require root.
12052
c0d27fcc 12053echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
12054echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
12055if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
12056 echo $ECHO_N "(cached) $ECHO_C" >&6
12057else
12058 ac_check_lib_save_LIBS=$LIBS
98418dba 12059LIBS="-lkstat $LIBS"
f21fadcc 12060cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12061#line $LINENO "configure"
cd958eb3
MB
12062/* confdefs.h. */
12063_ACEOF
12064cat confdefs.h >>conftest.$ac_ext
12065cat >>conftest.$ac_ext <<_ACEOF
12066/* end confdefs.h. */
f21fadcc
JD
12067
12068/* Override any gcc2 internal prototype to avoid an error. */
12069#ifdef __cplusplus
12070extern "C"
12071#endif
12072/* We use char because int might match the return type of a gcc2
12073 builtin and then its argument prototype would still apply. */
98418dba 12074char kstat_open ();
f21fadcc
JD
12075int
12076main ()
12077{
98418dba 12078kstat_open ();
f21fadcc
JD
12079 ;
12080 return 0;
12081}
12082_ACEOF
12083rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12084if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
f21fadcc
JD
12085 (eval $ac_link) 2>&5
12086 ac_status=$?
c0d27fcc 12087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc
JD
12088 (exit $ac_status); } &&
12089 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
12091 (eval $ac_try) 2>&5
12092 ac_status=$?
c0d27fcc 12093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 12094 (exit $ac_status); }; }; then
98418dba 12095 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
12096else
12097 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12098sed 's/^/| /' conftest.$ac_ext >&5
12099
98418dba 12100ac_cv_lib_kstat_kstat_open=no
f21fadcc
JD
12101fi
12102rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12103LIBS=$ac_check_lib_save_LIBS
12104fi
c0d27fcc 12105echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
12106echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
12107if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 12108 cat >>confdefs.h <<_ACEOF
98418dba 12109#define HAVE_LIBKSTAT 1
c0d27fcc 12110_ACEOF
f21fadcc 12111
98418dba 12112 LIBS="-lkstat $LIBS"
f21fadcc 12113
f21fadcc
JD
12114fi
12115
98418dba
CW
12116test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
12117
12118# Some systems with -lutil have (and need) -lkvm as well, some do not.
12119# On Solaris, -lkvm requires nlist from -lelf, so check that first
12120# to get the right answer into the cache.
12121# For kstat on solaris, we need libelf to force the definition of SVR4 below.
12122if test $ac_have_func = no; then
c0d27fcc 12123 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
12124echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
12125if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 12126 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12127else
98418dba
CW
12128 ac_check_lib_save_LIBS=$LIBS
12129LIBS="-lelf $LIBS"
12130cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12131#line $LINENO "configure"
cd958eb3
MB
12132/* confdefs.h. */
12133_ACEOF
12134cat confdefs.h >>conftest.$ac_ext
12135cat >>conftest.$ac_ext <<_ACEOF
12136/* end confdefs.h. */
98418dba
CW
12137
12138/* Override any gcc2 internal prototype to avoid an error. */
12139#ifdef __cplusplus
12140extern "C"
12141#endif
12142/* We use char because int might match the return type of a gcc2
12143 builtin and then its argument prototype would still apply. */
12144char elf_begin ();
503d2be0
AS
12145int
12146main ()
12147{
98418dba 12148elf_begin ();
503d2be0
AS
12149 ;
12150 return 0;
12151}
12152_ACEOF
12153rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12154if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12155 (eval $ac_link) 2>&5
12156 ac_status=$?
c0d27fcc 12157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12158 (exit $ac_status); } &&
12159 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12160 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12161 (eval $ac_try) 2>&5
12162 ac_status=$?
c0d27fcc 12163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12164 (exit $ac_status); }; }; then
98418dba 12165 ac_cv_lib_elf_elf_begin=yes
ba4481b5 12166else
503d2be0 12167 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12168sed 's/^/| /' conftest.$ac_ext >&5
12169
98418dba 12170ac_cv_lib_elf_elf_begin=no
ba4481b5 12171fi
503d2be0 12172rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12173LIBS=$ac_check_lib_save_LIBS
ba4481b5 12174fi
c0d27fcc 12175echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
12176echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
12177if test $ac_cv_lib_elf_elf_begin = yes; then
12178 LIBS="-lelf $LIBS"
ba4481b5
DL
12179fi
12180
98418dba
CW
12181fi
12182if test $ac_have_func = no; then
c0d27fcc 12183 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
12184echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
12185if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 12186 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12187else
98418dba
CW
12188 ac_check_lib_save_LIBS=$LIBS
12189LIBS="-lkvm $LIBS"
12190cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12191#line $LINENO "configure"
cd958eb3
MB
12192/* confdefs.h. */
12193_ACEOF
12194cat confdefs.h >>conftest.$ac_ext
12195cat >>conftest.$ac_ext <<_ACEOF
12196/* end confdefs.h. */
98418dba
CW
12197
12198/* Override any gcc2 internal prototype to avoid an error. */
12199#ifdef __cplusplus
12200extern "C"
12201#endif
12202/* We use char because int might match the return type of a gcc2
12203 builtin and then its argument prototype would still apply. */
12204char kvm_open ();
503d2be0
AS
12205int
12206main ()
12207{
98418dba 12208kvm_open ();
503d2be0
AS
12209 ;
12210 return 0;
12211}
12212_ACEOF
12213rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12214if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12215 (eval $ac_link) 2>&5
12216 ac_status=$?
c0d27fcc 12217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12218 (exit $ac_status); } &&
12219 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12220 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12221 (eval $ac_try) 2>&5
12222 ac_status=$?
c0d27fcc 12223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12224 (exit $ac_status); }; }; then
98418dba 12225 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
12226else
12227 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12228sed 's/^/| /' conftest.$ac_ext >&5
12229
98418dba 12230ac_cv_lib_kvm_kvm_open=no
503d2be0
AS
12231fi
12232rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12233LIBS=$ac_check_lib_save_LIBS
503d2be0 12234fi
c0d27fcc 12235echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
12236echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
12237if test $ac_cv_lib_kvm_kvm_open = yes; then
12238 LIBS="-lkvm $LIBS"
ba4481b5
DL
12239fi
12240
98418dba 12241 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 12242 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
12243echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
12244if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 12245 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12246else
98418dba
CW
12247 ac_check_lib_save_LIBS=$LIBS
12248LIBS="-lutil $LIBS"
12249cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12250#line $LINENO "configure"
cd958eb3
MB
12251/* confdefs.h. */
12252_ACEOF
12253cat confdefs.h >>conftest.$ac_ext
12254cat >>conftest.$ac_ext <<_ACEOF
12255/* end confdefs.h. */
98418dba
CW
12256
12257/* Override any gcc2 internal prototype to avoid an error. */
12258#ifdef __cplusplus
12259extern "C"
12260#endif
12261/* We use char because int might match the return type of a gcc2
12262 builtin and then its argument prototype would still apply. */
12263char getloadavg ();
503d2be0
AS
12264int
12265main ()
12266{
98418dba 12267getloadavg ();
503d2be0
AS
12268 ;
12269 return 0;
12270}
12271_ACEOF
12272rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12273if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12274 (eval $ac_link) 2>&5
12275 ac_status=$?
c0d27fcc 12276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12277 (exit $ac_status); } &&
12278 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12279 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12280 (eval $ac_try) 2>&5
12281 ac_status=$?
c0d27fcc 12282 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12283 (exit $ac_status); }; }; then
98418dba 12284 ac_cv_lib_util_getloadavg=yes
ba4481b5 12285else
503d2be0 12286 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12287sed 's/^/| /' conftest.$ac_ext >&5
12288
98418dba 12289ac_cv_lib_util_getloadavg=no
ba4481b5 12290fi
503d2be0 12291rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12292LIBS=$ac_check_lib_save_LIBS
12293fi
c0d27fcc 12294echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
12295echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
12296if test $ac_cv_lib_util_getloadavg = yes; then
12297 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 12298fi
503d2be0 12299
98418dba 12300fi
ba4481b5 12301
98418dba
CW
12302if test $ac_have_func = no; then
12303 # There is a commonly available library for RS/6000 AIX.
12304 # Since it is not a standard part of AIX, it might be installed locally.
12305 ac_getloadavg_LIBS=$LIBS
12306 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 12307 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
12308echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
12309if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 12310 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12311else
98418dba
CW
12312 ac_check_lib_save_LIBS=$LIBS
12313LIBS="-lgetloadavg $LIBS"
12314cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12315#line $LINENO "configure"
cd958eb3
MB
12316/* confdefs.h. */
12317_ACEOF
12318cat confdefs.h >>conftest.$ac_ext
12319cat >>conftest.$ac_ext <<_ACEOF
12320/* end confdefs.h. */
ba4481b5 12321
98418dba
CW
12322/* Override any gcc2 internal prototype to avoid an error. */
12323#ifdef __cplusplus
12324extern "C"
12325#endif
12326/* We use char because int might match the return type of a gcc2
12327 builtin and then its argument prototype would still apply. */
12328char getloadavg ();
98418dba
CW
12329int
12330main ()
12331{
12332getloadavg ();
12333 ;
12334 return 0;
12335}
503d2be0 12336_ACEOF
98418dba 12337rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12338if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
12339 (eval $ac_link) 2>&5
12340 ac_status=$?
c0d27fcc 12341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12342 (exit $ac_status); } &&
12343 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12344 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
12345 (eval $ac_try) 2>&5
12346 ac_status=$?
c0d27fcc 12347 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12348 (exit $ac_status); }; }; then
12349 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 12350else
98418dba 12351 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12352sed 's/^/| /' conftest.$ac_ext >&5
12353
98418dba
CW
12354ac_cv_lib_getloadavg_getloadavg=no
12355fi
12356rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12357LIBS=$ac_check_lib_save_LIBS
12358fi
c0d27fcc 12359echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
12360echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
12361if test $ac_cv_lib_getloadavg_getloadavg = yes; then
12362 LIBS="-lgetloadavg $LIBS"
12363else
12364 LIBS=$ac_getloadavg_LIBS
ba4481b5 12365fi
ba4481b5
DL
12366
12367fi
98418dba
CW
12368
12369# Make sure it is really in the library, if we think we found it,
12370# otherwise set up the replacement function.
12371
12372for ac_func in getloadavg
12373do
12374as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12375echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12376echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12377if eval "test \"\${$as_ac_var+set}\" = set"; then
12378 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12379else
503d2be0 12380 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12381#line $LINENO "configure"
cd958eb3
MB
12382/* confdefs.h. */
12383_ACEOF
12384cat confdefs.h >>conftest.$ac_ext
12385cat >>conftest.$ac_ext <<_ACEOF
12386/* end confdefs.h. */
ba4481b5 12387/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
12388 which can conflict with char $ac_func (); below.
12389 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12390 <limits.h> exists even on freestanding compilers. */
12391#ifdef __STDC__
12392# include <limits.h>
12393#else
12394# include <assert.h>
12395#endif
ba4481b5 12396/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12397#ifdef __cplusplus
12398extern "C"
cd958eb3 12399{
503d2be0 12400#endif
ba4481b5 12401/* We use char because int might match the return type of a gcc2
503d2be0
AS
12402 builtin and then its argument prototype would still apply. */
12403char $ac_func ();
ba4481b5
DL
12404/* The GNU C library defines this for functions which it implements
12405 to always fail with ENOSYS. Some functions are actually named
12406 something starting with __ and the normal name is an alias. */
12407#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12408choke me
12409#else
cd958eb3 12410char (*f) () = $ac_func;
ba4481b5 12411#endif
cd958eb3
MB
12412#ifdef __cplusplus
12413}
12414#endif
12415
12416int
12417main ()
12418{
9e71690e 12419return f != $ac_func;
503d2be0
AS
12420 ;
12421 return 0;
12422}
12423_ACEOF
12424rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12425if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12426 (eval $ac_link) 2>&5
12427 ac_status=$?
c0d27fcc 12428 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12429 (exit $ac_status); } &&
12430 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12431 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12432 (eval $ac_try) 2>&5
12433 ac_status=$?
c0d27fcc 12434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12435 (exit $ac_status); }; }; then
12436 eval "$as_ac_var=yes"
12437else
12438 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12439sed 's/^/| /' conftest.$ac_ext >&5
12440
503d2be0
AS
12441eval "$as_ac_var=no"
12442fi
12443rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12444fi
c0d27fcc 12445echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12446echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12447if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12448 cat >>confdefs.h <<_ACEOF
98418dba 12449#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12450_ACEOF
503d2be0 12451
98418dba
CW
12452else
12453 LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
ba4481b5 12454
c0d27fcc 12455cat >>confdefs.h <<\_ACEOF
98418dba 12456#define C_GETLOADAVG 1
c0d27fcc 12457_ACEOF
ba4481b5 12458
98418dba
CW
12459# Figure out what our getloadavg.c needs.
12460ac_have_func=no
c0d27fcc
MR
12461if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
12462 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
12463echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
12464if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 12465 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12466fi
12467echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
12468echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 12469else
c0d27fcc
MR
12470 # Is the header compilable?
12471echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
12472echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
12473cat >conftest.$ac_ext <<_ACEOF
12474#line $LINENO "configure"
cd958eb3
MB
12475/* confdefs.h. */
12476_ACEOF
12477cat confdefs.h >>conftest.$ac_ext
12478cat >>conftest.$ac_ext <<_ACEOF
12479/* end confdefs.h. */
c0d27fcc
MR
12480$ac_includes_default
12481#include <sys/dg_sys_info.h>
12482_ACEOF
12483rm -f conftest.$ac_objext
12484if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12485 (eval $ac_compile) 2>&5
12486 ac_status=$?
12487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12488 (exit $ac_status); } &&
12489 { ac_try='test -s conftest.$ac_objext'
12490 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12491 (eval $ac_try) 2>&5
12492 ac_status=$?
12493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12494 (exit $ac_status); }; }; then
12495 ac_header_compiler=yes
12496else
12497 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12498sed 's/^/| /' conftest.$ac_ext >&5
12499
c0d27fcc
MR
12500ac_header_compiler=no
12501fi
12502rm -f conftest.$ac_objext conftest.$ac_ext
12503echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12504echo "${ECHO_T}$ac_header_compiler" >&6
12505
12506# Is the header present?
12507echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
12508echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
12509cat >conftest.$ac_ext <<_ACEOF
12510#line $LINENO "configure"
cd958eb3
MB
12511/* confdefs.h. */
12512_ACEOF
12513cat confdefs.h >>conftest.$ac_ext
12514cat >>conftest.$ac_ext <<_ACEOF
12515/* end confdefs.h. */
98418dba
CW
12516#include <sys/dg_sys_info.h>
12517_ACEOF
c0d27fcc 12518if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12519 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12520 ac_status=$?
6bae0ccf 12521 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12522 rm -f conftest.er1
12523 cat conftest.err >&5
c0d27fcc 12524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12525 (exit $ac_status); } >/dev/null; then
12526 if test -s conftest.err; then
12527 ac_cpp_err=$ac_c_preproc_warn_flag
12528 else
12529 ac_cpp_err=
12530 fi
12531else
12532 ac_cpp_err=yes
ba4481b5 12533fi
98418dba 12534if test -z "$ac_cpp_err"; then
c0d27fcc 12535 ac_header_preproc=yes
98418dba
CW
12536else
12537 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12538sed 's/^/| /' conftest.$ac_ext >&5
12539
c0d27fcc 12540 ac_header_preproc=no
ba4481b5 12541fi
98418dba 12542rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12543echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12544echo "${ECHO_T}$ac_header_preproc" >&6
12545
12546# So? What about this header?
12547case $ac_header_compiler:$ac_header_preproc in
12548 yes:no )
12549 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
12550echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12551 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12552echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
12553 (
12554 cat <<\_ASBOX
12555## ------------------------------------ ##
12556## Report this to bug-autoconf@gnu.org. ##
12557## ------------------------------------ ##
12558_ASBOX
12559 ) |
12560 sed "s/^/$as_me: WARNING: /" >&2
12561 ;;
c0d27fcc
MR
12562 no:yes )
12563 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
12564echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
12565 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
12566echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
12567 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12568echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
12569 (
12570 cat <<\_ASBOX
12571## ------------------------------------ ##
12572## Report this to bug-autoconf@gnu.org. ##
12573## ------------------------------------ ##
12574_ASBOX
12575 ) |
12576 sed "s/^/$as_me: WARNING: /" >&2
12577 ;;
c0d27fcc
MR
12578esac
12579echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
12580echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
12581if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
12582 echo $ECHO_N "(cached) $ECHO_C" >&6
12583else
12584 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 12585fi
c0d27fcc 12586echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 12587echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
12588
12589fi
98418dba
CW
12590if test $ac_cv_header_sys_dg_sys_info_h = yes; then
12591 ac_have_func=yes
ba4481b5 12592
c0d27fcc 12593cat >>confdefs.h <<\_ACEOF
98418dba 12594#define DGUX 1
c0d27fcc
MR
12595_ACEOF
12596
503d2be0 12597
c0d27fcc 12598echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
12599echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
12600if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 12601 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12602else
503d2be0 12603 ac_check_lib_save_LIBS=$LIBS
98418dba 12604LIBS="-ldgc $LIBS"
503d2be0 12605cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12606#line $LINENO "configure"
cd958eb3
MB
12607/* confdefs.h. */
12608_ACEOF
12609cat confdefs.h >>conftest.$ac_ext
12610cat >>conftest.$ac_ext <<_ACEOF
12611/* end confdefs.h. */
503d2be0 12612
ba4481b5 12613/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12614#ifdef __cplusplus
12615extern "C"
12616#endif
ba4481b5 12617/* We use char because int might match the return type of a gcc2
503d2be0 12618 builtin and then its argument prototype would still apply. */
98418dba 12619char dg_sys_info ();
503d2be0
AS
12620int
12621main ()
12622{
98418dba 12623dg_sys_info ();
503d2be0
AS
12624 ;
12625 return 0;
12626}
12627_ACEOF
12628rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12629if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12630 (eval $ac_link) 2>&5
12631 ac_status=$?
c0d27fcc 12632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12633 (exit $ac_status); } &&
12634 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12635 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12636 (eval $ac_try) 2>&5
12637 ac_status=$?
c0d27fcc 12638 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12639 (exit $ac_status); }; }; then
98418dba 12640 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
12641else
12642 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12643sed 's/^/| /' conftest.$ac_ext >&5
12644
98418dba 12645ac_cv_lib_dgc_dg_sys_info=no
503d2be0
AS
12646fi
12647rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12648LIBS=$ac_check_lib_save_LIBS
12649fi
c0d27fcc 12650echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
12651echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
12652if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 12653 cat >>confdefs.h <<_ACEOF
98418dba 12654#define HAVE_LIBDGC 1
c0d27fcc 12655_ACEOF
ba4481b5 12656
98418dba 12657 LIBS="-ldgc $LIBS"
ba4481b5 12658
ba4481b5
DL
12659fi
12660
98418dba 12661fi
503d2be0 12662
c0d27fcc
MR
12663
12664
12665if test "${ac_cv_header_locale_h+set}" = set; then
12666 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
12667echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
12668if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 12669 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12670fi
12671echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
12672echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 12673else
c0d27fcc
MR
12674 # Is the header compilable?
12675echo "$as_me:$LINENO: checking locale.h usability" >&5
12676echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
12677cat >conftest.$ac_ext <<_ACEOF
12678#line $LINENO "configure"
cd958eb3
MB
12679/* confdefs.h. */
12680_ACEOF
12681cat confdefs.h >>conftest.$ac_ext
12682cat >>conftest.$ac_ext <<_ACEOF
12683/* end confdefs.h. */
c0d27fcc
MR
12684$ac_includes_default
12685#include <locale.h>
12686_ACEOF
12687rm -f conftest.$ac_objext
12688if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12689 (eval $ac_compile) 2>&5
12690 ac_status=$?
12691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12692 (exit $ac_status); } &&
12693 { ac_try='test -s conftest.$ac_objext'
12694 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12695 (eval $ac_try) 2>&5
12696 ac_status=$?
12697 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12698 (exit $ac_status); }; }; then
12699 ac_header_compiler=yes
12700else
12701 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12702sed 's/^/| /' conftest.$ac_ext >&5
12703
c0d27fcc
MR
12704ac_header_compiler=no
12705fi
12706rm -f conftest.$ac_objext conftest.$ac_ext
12707echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12708echo "${ECHO_T}$ac_header_compiler" >&6
12709
12710# Is the header present?
12711echo "$as_me:$LINENO: checking locale.h presence" >&5
12712echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
12713cat >conftest.$ac_ext <<_ACEOF
12714#line $LINENO "configure"
cd958eb3
MB
12715/* confdefs.h. */
12716_ACEOF
12717cat confdefs.h >>conftest.$ac_ext
12718cat >>conftest.$ac_ext <<_ACEOF
12719/* end confdefs.h. */
98418dba 12720#include <locale.h>
503d2be0 12721_ACEOF
c0d27fcc 12722if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 12723 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 12724 ac_status=$?
6bae0ccf 12725 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12726 rm -f conftest.er1
12727 cat conftest.err >&5
c0d27fcc 12728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12729 (exit $ac_status); } >/dev/null; then
12730 if test -s conftest.err; then
12731 ac_cpp_err=$ac_c_preproc_warn_flag
12732 else
12733 ac_cpp_err=
12734 fi
503d2be0 12735else
98418dba 12736 ac_cpp_err=yes
503d2be0 12737fi
98418dba 12738if test -z "$ac_cpp_err"; then
c0d27fcc 12739 ac_header_preproc=yes
98418dba
CW
12740else
12741 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12742sed 's/^/| /' conftest.$ac_ext >&5
12743
c0d27fcc 12744 ac_header_preproc=no
ba4481b5 12745fi
98418dba 12746rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12747echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12748echo "${ECHO_T}$ac_header_preproc" >&6
12749
12750# So? What about this header?
12751case $ac_header_compiler:$ac_header_preproc in
12752 yes:no )
12753 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
12754echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12755 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12756echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
12757 (
12758 cat <<\_ASBOX
12759## ------------------------------------ ##
12760## Report this to bug-autoconf@gnu.org. ##
12761## ------------------------------------ ##
12762_ASBOX
12763 ) |
12764 sed "s/^/$as_me: WARNING: /" >&2
12765 ;;
c0d27fcc
MR
12766 no:yes )
12767 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
12768echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
12769 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
12770echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
12771 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12772echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
12773 (
12774 cat <<\_ASBOX
12775## ------------------------------------ ##
12776## Report this to bug-autoconf@gnu.org. ##
12777## ------------------------------------ ##
12778_ASBOX
12779 ) |
12780 sed "s/^/$as_me: WARNING: /" >&2
12781 ;;
c0d27fcc
MR
12782esac
12783echo "$as_me:$LINENO: checking for locale.h" >&5
12784echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
12785if test "${ac_cv_header_locale_h+set}" = set; then
12786 echo $ECHO_N "(cached) $ECHO_C" >&6
12787else
12788 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 12789fi
c0d27fcc 12790echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
12791echo "${ECHO_T}$ac_cv_header_locale_h" >&6
12792
c0d27fcc
MR
12793fi
12794
12795
12796
98418dba 12797for ac_func in setlocale
ba4481b5 12798do
503d2be0 12799as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12800echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12801echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12802if eval "test \"\${$as_ac_var+set}\" = set"; then
12803 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12804else
503d2be0 12805 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12806#line $LINENO "configure"
cd958eb3
MB
12807/* confdefs.h. */
12808_ACEOF
12809cat confdefs.h >>conftest.$ac_ext
12810cat >>conftest.$ac_ext <<_ACEOF
12811/* end confdefs.h. */
ba4481b5 12812/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
12813 which can conflict with char $ac_func (); below.
12814 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12815 <limits.h> exists even on freestanding compilers. */
12816#ifdef __STDC__
12817# include <limits.h>
12818#else
12819# include <assert.h>
12820#endif
ba4481b5 12821/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12822#ifdef __cplusplus
12823extern "C"
cd958eb3 12824{
503d2be0 12825#endif
ba4481b5 12826/* We use char because int might match the return type of a gcc2
503d2be0
AS
12827 builtin and then its argument prototype would still apply. */
12828char $ac_func ();
ba4481b5
DL
12829/* The GNU C library defines this for functions which it implements
12830 to always fail with ENOSYS. Some functions are actually named
12831 something starting with __ and the normal name is an alias. */
12832#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12833choke me
12834#else
cd958eb3
MB
12835char (*f) () = $ac_func;
12836#endif
12837#ifdef __cplusplus
12838}
ba4481b5
DL
12839#endif
12840
cd958eb3
MB
12841int
12842main ()
12843{
9e71690e 12844return f != $ac_func;
503d2be0
AS
12845 ;
12846 return 0;
12847}
12848_ACEOF
12849rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12850if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12851 (eval $ac_link) 2>&5
12852 ac_status=$?
c0d27fcc 12853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12854 (exit $ac_status); } &&
12855 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12856 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12857 (eval $ac_try) 2>&5
12858 ac_status=$?
c0d27fcc 12859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12860 (exit $ac_status); }; }; then
12861 eval "$as_ac_var=yes"
12862else
12863 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12864sed 's/^/| /' conftest.$ac_ext >&5
12865
503d2be0
AS
12866eval "$as_ac_var=no"
12867fi
12868rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12869fi
c0d27fcc 12870echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12871echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12872if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12873 cat >>confdefs.h <<_ACEOF
503d2be0 12874#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12875_ACEOF
ba4481b5 12876
ba4481b5
DL
12877fi
12878done
12879
c0d27fcc 12880
98418dba
CW
12881# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
12882# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
12883# Irix 4.0.5F has the header but not the library.
12884if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
12885 ac_have_func=yes
12886
c0d27fcc 12887cat >>confdefs.h <<\_ACEOF
98418dba 12888#define SVR4 1
c0d27fcc 12889_ACEOF
98418dba
CW
12890
12891fi
12892
12893if test $ac_have_func = no; then
c0d27fcc
MR
12894 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
12895 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
12896echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
12897if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 12898 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12899fi
12900echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
12901echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 12902else
c0d27fcc
MR
12903 # Is the header compilable?
12904echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
12905echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
12906cat >conftest.$ac_ext <<_ACEOF
12907#line $LINENO "configure"
cd958eb3
MB
12908/* confdefs.h. */
12909_ACEOF
12910cat confdefs.h >>conftest.$ac_ext
12911cat >>conftest.$ac_ext <<_ACEOF
12912/* end confdefs.h. */
c0d27fcc
MR
12913$ac_includes_default
12914#include <inq_stats/cpustats.h>
12915_ACEOF
12916rm -f conftest.$ac_objext
12917if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12918 (eval $ac_compile) 2>&5
12919 ac_status=$?
12920 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12921 (exit $ac_status); } &&
12922 { ac_try='test -s conftest.$ac_objext'
12923 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12924 (eval $ac_try) 2>&5
12925 ac_status=$?
12926 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12927 (exit $ac_status); }; }; then
12928 ac_header_compiler=yes
12929else
12930 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12931sed 's/^/| /' conftest.$ac_ext >&5
12932
c0d27fcc
MR
12933ac_header_compiler=no
12934fi
12935rm -f conftest.$ac_objext conftest.$ac_ext
12936echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12937echo "${ECHO_T}$ac_header_compiler" >&6
12938
12939# Is the header present?
12940echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
12941echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
12942cat >conftest.$ac_ext <<_ACEOF
12943#line $LINENO "configure"
cd958eb3
MB
12944/* confdefs.h. */
12945_ACEOF
12946cat confdefs.h >>conftest.$ac_ext
12947cat >>conftest.$ac_ext <<_ACEOF
12948/* end confdefs.h. */
98418dba 12949#include <inq_stats/cpustats.h>
503d2be0 12950_ACEOF
c0d27fcc 12951if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
12952 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12953 ac_status=$?
6bae0ccf 12954 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
12955 rm -f conftest.er1
12956 cat conftest.err >&5
c0d27fcc 12957 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12958 (exit $ac_status); } >/dev/null; then
12959 if test -s conftest.err; then
12960 ac_cpp_err=$ac_c_preproc_warn_flag
12961 else
12962 ac_cpp_err=
12963 fi
12964else
12965 ac_cpp_err=yes
12966fi
12967if test -z "$ac_cpp_err"; then
c0d27fcc 12968 ac_header_preproc=yes
503d2be0
AS
12969else
12970 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12971sed 's/^/| /' conftest.$ac_ext >&5
12972
c0d27fcc 12973 ac_header_preproc=no
ba4481b5 12974fi
503d2be0 12975rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12976echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12977echo "${ECHO_T}$ac_header_preproc" >&6
12978
12979# So? What about this header?
12980case $ac_header_compiler:$ac_header_preproc in
12981 yes:no )
12982 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
12983echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12984 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12985echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
12986 (
12987 cat <<\_ASBOX
12988## ------------------------------------ ##
12989## Report this to bug-autoconf@gnu.org. ##
12990## ------------------------------------ ##
12991_ASBOX
12992 ) |
12993 sed "s/^/$as_me: WARNING: /" >&2
12994 ;;
c0d27fcc
MR
12995 no:yes )
12996 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
12997echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
12998 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
12999echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
13000 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13001echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
13002 (
13003 cat <<\_ASBOX
13004## ------------------------------------ ##
13005## Report this to bug-autoconf@gnu.org. ##
13006## ------------------------------------ ##
13007_ASBOX
13008 ) |
13009 sed "s/^/$as_me: WARNING: /" >&2
13010 ;;
c0d27fcc
MR
13011esac
13012echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
13013echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
13014if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
13015 echo $ECHO_N "(cached) $ECHO_C" >&6
13016else
13017 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 13018fi
c0d27fcc 13019echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 13020echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
13021
13022fi
98418dba
CW
13023if test $ac_cv_header_inq_stats_cpustats_h = yes; then
13024 ac_have_func=yes
ba4481b5 13025
c0d27fcc 13026cat >>confdefs.h <<\_ACEOF
98418dba 13027#define UMAX 1
c0d27fcc 13028_ACEOF
98418dba 13029
c0d27fcc
MR
13030
13031cat >>confdefs.h <<\_ACEOF
98418dba 13032#define UMAX4_3 1
c0d27fcc 13033_ACEOF
98418dba
CW
13034
13035fi
13036
c0d27fcc 13037
98418dba
CW
13038fi
13039
13040if test $ac_have_func = no; then
c0d27fcc
MR
13041 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
13042 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
13043echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
13044if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 13045 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13046fi
13047echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
13048echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 13049else
c0d27fcc
MR
13050 # Is the header compilable?
13051echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
13052echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
13053cat >conftest.$ac_ext <<_ACEOF
13054#line $LINENO "configure"
cd958eb3
MB
13055/* confdefs.h. */
13056_ACEOF
13057cat confdefs.h >>conftest.$ac_ext
13058cat >>conftest.$ac_ext <<_ACEOF
13059/* end confdefs.h. */
c0d27fcc
MR
13060$ac_includes_default
13061#include <sys/cpustats.h>
13062_ACEOF
13063rm -f conftest.$ac_objext
13064if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13065 (eval $ac_compile) 2>&5
13066 ac_status=$?
13067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13068 (exit $ac_status); } &&
13069 { ac_try='test -s conftest.$ac_objext'
13070 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13071 (eval $ac_try) 2>&5
13072 ac_status=$?
13073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13074 (exit $ac_status); }; }; then
13075 ac_header_compiler=yes
13076else
13077 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13078sed 's/^/| /' conftest.$ac_ext >&5
13079
c0d27fcc
MR
13080ac_header_compiler=no
13081fi
13082rm -f conftest.$ac_objext conftest.$ac_ext
13083echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13084echo "${ECHO_T}$ac_header_compiler" >&6
13085
13086# Is the header present?
13087echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
13088echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
13089cat >conftest.$ac_ext <<_ACEOF
13090#line $LINENO "configure"
cd958eb3
MB
13091/* confdefs.h. */
13092_ACEOF
13093cat confdefs.h >>conftest.$ac_ext
13094cat >>conftest.$ac_ext <<_ACEOF
13095/* end confdefs.h. */
98418dba
CW
13096#include <sys/cpustats.h>
13097_ACEOF
c0d27fcc 13098if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
13099 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13100 ac_status=$?
6bae0ccf 13101 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13102 rm -f conftest.er1
13103 cat conftest.err >&5
c0d27fcc 13104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13105 (exit $ac_status); } >/dev/null; then
13106 if test -s conftest.err; then
13107 ac_cpp_err=$ac_c_preproc_warn_flag
13108 else
13109 ac_cpp_err=
13110 fi
13111else
13112 ac_cpp_err=yes
503d2be0 13113fi
98418dba 13114if test -z "$ac_cpp_err"; then
c0d27fcc 13115 ac_header_preproc=yes
98418dba
CW
13116else
13117 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13118sed 's/^/| /' conftest.$ac_ext >&5
13119
c0d27fcc 13120 ac_header_preproc=no
98418dba
CW
13121fi
13122rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13123echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13124echo "${ECHO_T}$ac_header_preproc" >&6
13125
13126# So? What about this header?
13127case $ac_header_compiler:$ac_header_preproc in
13128 yes:no )
13129 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
13130echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13131 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13132echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
13133 (
13134 cat <<\_ASBOX
13135## ------------------------------------ ##
13136## Report this to bug-autoconf@gnu.org. ##
13137## ------------------------------------ ##
13138_ASBOX
13139 ) |
13140 sed "s/^/$as_me: WARNING: /" >&2
13141 ;;
c0d27fcc
MR
13142 no:yes )
13143 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
13144echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
13145 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
13146echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
13147 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13148echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
13149 (
13150 cat <<\_ASBOX
13151## ------------------------------------ ##
13152## Report this to bug-autoconf@gnu.org. ##
13153## ------------------------------------ ##
13154_ASBOX
13155 ) |
13156 sed "s/^/$as_me: WARNING: /" >&2
13157 ;;
c0d27fcc
MR
13158esac
13159echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
13160echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
13161if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
13162 echo $ECHO_N "(cached) $ECHO_C" >&6
13163else
13164 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 13165fi
c0d27fcc 13166echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 13167echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
13168
13169fi
98418dba 13170if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 13171 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 13172#define UMAX 1
c0d27fcc 13173_ACEOF
ba4481b5 13174
98418dba
CW
13175fi
13176
c0d27fcc 13177
98418dba
CW
13178fi
13179
13180if test $ac_have_func = no; then
13181
13182for ac_header in mach/mach.h
2c9dccc9
PJ
13183do
13184as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13185if eval "test \"\${$as_ac_Header+set}\" = set"; then
13186 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
13187echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13188if eval "test \"\${$as_ac_Header+set}\" = set"; then
13189 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13190fi
13191echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13192echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13193else
c0d27fcc
MR
13194 # Is the header compilable?
13195echo "$as_me:$LINENO: checking $ac_header usability" >&5
13196echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13197cat >conftest.$ac_ext <<_ACEOF
13198#line $LINENO "configure"
cd958eb3
MB
13199/* confdefs.h. */
13200_ACEOF
13201cat confdefs.h >>conftest.$ac_ext
13202cat >>conftest.$ac_ext <<_ACEOF
13203/* end confdefs.h. */
c0d27fcc
MR
13204$ac_includes_default
13205#include <$ac_header>
13206_ACEOF
13207rm -f conftest.$ac_objext
13208if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13209 (eval $ac_compile) 2>&5
13210 ac_status=$?
13211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13212 (exit $ac_status); } &&
13213 { ac_try='test -s conftest.$ac_objext'
13214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13215 (eval $ac_try) 2>&5
13216 ac_status=$?
13217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13218 (exit $ac_status); }; }; then
13219 ac_header_compiler=yes
13220else
13221 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13222sed 's/^/| /' conftest.$ac_ext >&5
13223
c0d27fcc
MR
13224ac_header_compiler=no
13225fi
13226rm -f conftest.$ac_objext conftest.$ac_ext
13227echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13228echo "${ECHO_T}$ac_header_compiler" >&6
13229
13230# Is the header present?
13231echo "$as_me:$LINENO: checking $ac_header presence" >&5
13232echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13233cat >conftest.$ac_ext <<_ACEOF
13234#line $LINENO "configure"
cd958eb3
MB
13235/* confdefs.h. */
13236_ACEOF
13237cat confdefs.h >>conftest.$ac_ext
13238cat >>conftest.$ac_ext <<_ACEOF
13239/* end confdefs.h. */
2c9dccc9
PJ
13240#include <$ac_header>
13241_ACEOF
c0d27fcc 13242if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
13243 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13244 ac_status=$?
6bae0ccf 13245 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
13246 rm -f conftest.er1
13247 cat conftest.err >&5
c0d27fcc 13248 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
13249 (exit $ac_status); } >/dev/null; then
13250 if test -s conftest.err; then
13251 ac_cpp_err=$ac_c_preproc_warn_flag
13252 else
13253 ac_cpp_err=
13254 fi
13255else
13256 ac_cpp_err=yes
13257fi
13258if test -z "$ac_cpp_err"; then
c0d27fcc
MR
13259 ac_header_preproc=yes
13260else
13261 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13262sed 's/^/| /' conftest.$ac_ext >&5
13263
c0d27fcc
MR
13264 ac_header_preproc=no
13265fi
13266rm -f conftest.err conftest.$ac_ext
13267echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13268echo "${ECHO_T}$ac_header_preproc" >&6
13269
13270# So? What about this header?
13271case $ac_header_compiler:$ac_header_preproc in
13272 yes:no )
13273 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13274echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13275 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13276echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13277 (
13278 cat <<\_ASBOX
13279## ------------------------------------ ##
13280## Report this to bug-autoconf@gnu.org. ##
13281## ------------------------------------ ##
13282_ASBOX
13283 ) |
13284 sed "s/^/$as_me: WARNING: /" >&2
13285 ;;
c0d27fcc
MR
13286 no:yes )
13287 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13288echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13289 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13290echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13291 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13292echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13293 (
13294 cat <<\_ASBOX
13295## ------------------------------------ ##
13296## Report this to bug-autoconf@gnu.org. ##
13297## ------------------------------------ ##
13298_ASBOX
13299 ) |
13300 sed "s/^/$as_me: WARNING: /" >&2
13301 ;;
c0d27fcc
MR
13302esac
13303echo "$as_me:$LINENO: checking for $ac_header" >&5
13304echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13305if eval "test \"\${$as_ac_Header+set}\" = set"; then
13306 echo $ECHO_N "(cached) $ECHO_C" >&6
13307else
13308 eval "$as_ac_Header=$ac_header_preproc"
13309fi
13310echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13311echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13312
13313fi
13314if test `eval echo '${'$as_ac_Header'}'` = yes; then
13315 cat >>confdefs.h <<_ACEOF
13316#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13317_ACEOF
13318
13319fi
13320
13321done
13322
13323fi
13324
13325
13326for ac_header in nlist.h
13327do
13328as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13329if eval "test \"\${$as_ac_Header+set}\" = set"; then
13330 echo "$as_me:$LINENO: checking for $ac_header" >&5
13331echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13332if eval "test \"\${$as_ac_Header+set}\" = set"; then
13333 echo $ECHO_N "(cached) $ECHO_C" >&6
13334fi
13335echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13336echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13337else
13338 # Is the header compilable?
13339echo "$as_me:$LINENO: checking $ac_header usability" >&5
13340echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13341cat >conftest.$ac_ext <<_ACEOF
13342#line $LINENO "configure"
cd958eb3
MB
13343/* confdefs.h. */
13344_ACEOF
13345cat confdefs.h >>conftest.$ac_ext
13346cat >>conftest.$ac_ext <<_ACEOF
13347/* end confdefs.h. */
c0d27fcc
MR
13348$ac_includes_default
13349#include <$ac_header>
13350_ACEOF
13351rm -f conftest.$ac_objext
13352if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13353 (eval $ac_compile) 2>&5
13354 ac_status=$?
13355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13356 (exit $ac_status); } &&
13357 { ac_try='test -s conftest.$ac_objext'
13358 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13359 (eval $ac_try) 2>&5
13360 ac_status=$?
13361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13362 (exit $ac_status); }; }; then
13363 ac_header_compiler=yes
2c9dccc9
PJ
13364else
13365 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13366sed 's/^/| /' conftest.$ac_ext >&5
13367
c0d27fcc 13368ac_header_compiler=no
98418dba 13369fi
c0d27fcc
MR
13370rm -f conftest.$ac_objext conftest.$ac_ext
13371echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13372echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 13373
c0d27fcc
MR
13374# Is the header present?
13375echo "$as_me:$LINENO: checking $ac_header presence" >&5
13376echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13377cat >conftest.$ac_ext <<_ACEOF
13378#line $LINENO "configure"
cd958eb3
MB
13379/* confdefs.h. */
13380_ACEOF
13381cat confdefs.h >>conftest.$ac_ext
13382cat >>conftest.$ac_ext <<_ACEOF
13383/* end confdefs.h. */
503d2be0
AS
13384#include <$ac_header>
13385_ACEOF
c0d27fcc 13386if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13387 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13388 ac_status=$?
6bae0ccf 13389 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13390 rm -f conftest.er1
13391 cat conftest.err >&5
c0d27fcc 13392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13393 (exit $ac_status); } >/dev/null; then
13394 if test -s conftest.err; then
13395 ac_cpp_err=$ac_c_preproc_warn_flag
13396 else
13397 ac_cpp_err=
13398 fi
13399else
13400 ac_cpp_err=yes
13401fi
13402if test -z "$ac_cpp_err"; then
c0d27fcc 13403 ac_header_preproc=yes
503d2be0
AS
13404else
13405 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13406sed 's/^/| /' conftest.$ac_ext >&5
13407
c0d27fcc 13408 ac_header_preproc=no
b5de8dc0 13409fi
503d2be0 13410rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13411echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13412echo "${ECHO_T}$ac_header_preproc" >&6
13413
13414# So? What about this header?
13415case $ac_header_compiler:$ac_header_preproc in
13416 yes:no )
13417 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13418echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13419 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13420echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13421 (
13422 cat <<\_ASBOX
13423## ------------------------------------ ##
13424## Report this to bug-autoconf@gnu.org. ##
13425## ------------------------------------ ##
13426_ASBOX
13427 ) |
13428 sed "s/^/$as_me: WARNING: /" >&2
13429 ;;
c0d27fcc
MR
13430 no:yes )
13431 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13432echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13433 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13434echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13435 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13436echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13437 (
13438 cat <<\_ASBOX
13439## ------------------------------------ ##
13440## Report this to bug-autoconf@gnu.org. ##
13441## ------------------------------------ ##
13442_ASBOX
13443 ) |
13444 sed "s/^/$as_me: WARNING: /" >&2
13445 ;;
c0d27fcc
MR
13446esac
13447echo "$as_me:$LINENO: checking for $ac_header" >&5
13448echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13449if eval "test \"\${$as_ac_Header+set}\" = set"; then
13450 echo $ECHO_N "(cached) $ECHO_C" >&6
13451else
13452 eval "$as_ac_Header=$ac_header_preproc"
b5de8dc0 13453fi
c0d27fcc 13454echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 13455echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13456
13457fi
98418dba 13458if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13459 cat >>confdefs.h <<_ACEOF
98418dba 13460#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
13461_ACEOF
13462 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
13463echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
13464if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 13465 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 13466else
503d2be0 13467 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13468#line $LINENO "configure"
cd958eb3
MB
13469/* confdefs.h. */
13470_ACEOF
13471cat confdefs.h >>conftest.$ac_ext
13472cat >>conftest.$ac_ext <<_ACEOF
13473/* end confdefs.h. */
98418dba 13474#include <nlist.h>
b5de8dc0 13475
503d2be0
AS
13476int
13477main ()
13478{
98418dba
CW
13479static struct nlist ac_aggr;
13480if (ac_aggr.n_un.n_name)
13481return 0;
503d2be0
AS
13482 ;
13483 return 0;
13484}
13485_ACEOF
98418dba 13486rm -f conftest.$ac_objext
c0d27fcc 13487if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 13488 (eval $ac_compile) 2>&5
503d2be0 13489 ac_status=$?
c0d27fcc 13490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13491 (exit $ac_status); } &&
98418dba 13492 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13494 (eval $ac_try) 2>&5
13495 ac_status=$?
c0d27fcc 13496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13497 (exit $ac_status); }; }; then
98418dba 13498 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
13499else
13500 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13501sed 's/^/| /' conftest.$ac_ext >&5
13502
6bae0ccf
DL
13503cat >conftest.$ac_ext <<_ACEOF
13504#line $LINENO "configure"
cd958eb3
MB
13505/* confdefs.h. */
13506_ACEOF
13507cat confdefs.h >>conftest.$ac_ext
13508cat >>conftest.$ac_ext <<_ACEOF
13509/* end confdefs.h. */
6bae0ccf
DL
13510#include <nlist.h>
13511
13512int
13513main ()
13514{
13515static struct nlist ac_aggr;
13516if (sizeof ac_aggr.n_un.n_name)
13517return 0;
13518 ;
13519 return 0;
13520}
13521_ACEOF
13522rm -f conftest.$ac_objext
13523if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13524 (eval $ac_compile) 2>&5
13525 ac_status=$?
13526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13527 (exit $ac_status); } &&
13528 { ac_try='test -s conftest.$ac_objext'
13529 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13530 (eval $ac_try) 2>&5
13531 ac_status=$?
13532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13533 (exit $ac_status); }; }; then
13534 ac_cv_member_struct_nlist_n_un_n_name=yes
13535else
13536 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13537sed 's/^/| /' conftest.$ac_ext >&5
13538
98418dba 13539ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 13540fi
98418dba 13541rm -f conftest.$ac_objext conftest.$ac_ext
b5de8dc0 13542fi
6bae0ccf
DL
13543rm -f conftest.$ac_objext conftest.$ac_ext
13544fi
c0d27fcc 13545echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
13546echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
13547if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 13548
c0d27fcc 13549cat >>confdefs.h <<_ACEOF
98418dba 13550#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 13551_ACEOF
b5de8dc0 13552
c0d27fcc
MR
13553
13554cat >>confdefs.h <<\_ACEOF
98418dba 13555#define NLIST_NAME_UNION 1
c0d27fcc 13556_ACEOF
b5de8dc0 13557
98418dba 13558fi
b5de8dc0 13559
c0d27fcc 13560
98418dba 13561fi
c0d27fcc 13562
98418dba 13563done
b5de8dc0 13564
98418dba
CW
13565fi
13566done
b5de8dc0 13567
c0d27fcc 13568
98418dba 13569# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 13570echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
13571echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
13572if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
13573 echo $ECHO_N "(cached) $ECHO_C" >&6
13574else
13575 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13576#line $LINENO "configure"
cd958eb3
MB
13577/* confdefs.h. */
13578_ACEOF
13579cat confdefs.h >>conftest.$ac_ext
13580cat >>conftest.$ac_ext <<_ACEOF
13581/* end confdefs.h. */
6bae0ccf 13582#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
13583#ifdef LDAV_PRIVILEGED
13584Yowza Am I SETGID yet
13585#endif
13586_ACEOF
13587if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 13588 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
13589 ac_cv_func_getloadavg_setgid=yes
13590else
13591 ac_cv_func_getloadavg_setgid=no
13592fi
13593rm -f conftest*
b5de8dc0 13594
98418dba 13595fi
c0d27fcc 13596echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
13597echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
13598if test $ac_cv_func_getloadavg_setgid = yes; then
13599 NEED_SETGID=true
b5de8dc0 13600
c0d27fcc 13601cat >>confdefs.h <<\_ACEOF
98418dba 13602#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 13603_ACEOF
98418dba 13604
b5de8dc0 13605else
98418dba 13606 NEED_SETGID=false
b5de8dc0 13607fi
98418dba
CW
13608
13609if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 13610 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
13611echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
13612if test "${ac_cv_group_kmem+set}" = set; then
13613 echo $ECHO_N "(cached) $ECHO_C" >&6
13614else
13615 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
13616 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
13617 # If we got an error (system does not support symlinks), try without -L.
13618 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
13619 ac_cv_group_kmem=`echo $ac_ls_output \
13620 | sed -ne 's/[ ][ ]*/ /g;
13621 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
13622 / /s/.* //;p;'`
13623
b5de8dc0 13624fi
c0d27fcc 13625echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
13626echo "${ECHO_T}$ac_cv_group_kmem" >&6
13627 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 13628fi
98418dba
CW
13629if test "x$ac_save_LIBS" = x; then
13630 GETLOADAVG_LIBS=$LIBS
13631else
13632 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 13633fi
98418dba 13634LIBS=$ac_save_LIBS
b5de8dc0 13635
c0d27fcc
MR
13636
13637
13638echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
13639echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
13640if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 13641 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13642else
b936fae4
AS
13643 while :; do
13644 ac_cv_sys_largefile_source=no
503d2be0 13645 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13646#line $LINENO "configure"
cd958eb3
MB
13647/* confdefs.h. */
13648_ACEOF
13649cat confdefs.h >>conftest.$ac_ext
13650cat >>conftest.$ac_ext <<_ACEOF
13651/* end confdefs.h. */
b936fae4 13652#include <stdio.h>
503d2be0
AS
13653int
13654main ()
13655{
b936fae4
AS
13656return !fseeko;
13657 ;
13658 return 0;
13659}
13660_ACEOF
13661rm -f conftest.$ac_objext
c0d27fcc 13662if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4
AS
13663 (eval $ac_compile) 2>&5
13664 ac_status=$?
c0d27fcc 13665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13666 (exit $ac_status); } &&
13667 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13668 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
13669 (eval $ac_try) 2>&5
13670 ac_status=$?
c0d27fcc 13671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13672 (exit $ac_status); }; }; then
13673 break
13674else
13675 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13676sed 's/^/| /' conftest.$ac_ext >&5
13677
b936fae4
AS
13678fi
13679rm -f conftest.$ac_objext conftest.$ac_ext
13680 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13681#line $LINENO "configure"
cd958eb3
MB
13682/* confdefs.h. */
13683_ACEOF
13684cat confdefs.h >>conftest.$ac_ext
13685cat >>conftest.$ac_ext <<_ACEOF
13686/* end confdefs.h. */
b936fae4
AS
13687#define _LARGEFILE_SOURCE 1
13688#include <stdio.h>
b936fae4
AS
13689int
13690main ()
13691{
13692return !fseeko;
13693 ;
13694 return 0;
13695}
13696_ACEOF
13697rm -f conftest.$ac_objext
c0d27fcc 13698if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4
AS
13699 (eval $ac_compile) 2>&5
13700 ac_status=$?
c0d27fcc 13701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13702 (exit $ac_status); } &&
13703 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
13705 (eval $ac_try) 2>&5
13706 ac_status=$?
c0d27fcc 13707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13708 (exit $ac_status); }; }; then
13709 ac_cv_sys_largefile_source=1; break
13710else
13711 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13712sed 's/^/| /' conftest.$ac_ext >&5
13713
b936fae4
AS
13714fi
13715rm -f conftest.$ac_objext conftest.$ac_ext
13716 break
13717done
13718fi
c0d27fcc 13719echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
13720echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
13721if test "$ac_cv_sys_largefile_source" != no; then
13722
c0d27fcc 13723cat >>confdefs.h <<_ACEOF
b936fae4 13724#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 13725_ACEOF
b936fae4
AS
13726
13727fi
13728rm -f conftest*
4c343001 13729
b936fae4
AS
13730# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13731# in glibc 2.1.3, but that breaks too many other things.
13732# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 13733echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
13734echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
13735if test "${ac_cv_func_fseeko+set}" = set; then
13736 echo $ECHO_N "(cached) $ECHO_C" >&6
13737else
13738 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13739#line $LINENO "configure"
cd958eb3
MB
13740/* confdefs.h. */
13741_ACEOF
13742cat confdefs.h >>conftest.$ac_ext
13743cat >>conftest.$ac_ext <<_ACEOF
13744/* end confdefs.h. */
b936fae4 13745#include <stdio.h>
b936fae4
AS
13746int
13747main ()
13748{
13749return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
13750 ;
13751 return 0;
13752}
13753_ACEOF
13754rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13755if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13756 (eval $ac_link) 2>&5
13757 ac_status=$?
c0d27fcc 13758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13759 (exit $ac_status); } &&
13760 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13762 (eval $ac_try) 2>&5
13763 ac_status=$?
c0d27fcc 13764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13765 (exit $ac_status); }; }; then
b936fae4 13766 ac_cv_func_fseeko=yes
503d2be0
AS
13767else
13768 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13769sed 's/^/| /' conftest.$ac_ext >&5
13770
b936fae4 13771ac_cv_func_fseeko=no
503d2be0
AS
13772fi
13773rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13774fi
c0d27fcc 13775echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
13776echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13777if test $ac_cv_func_fseeko = yes; then
13778
c0d27fcc 13779cat >>confdefs.h <<\_ACEOF
b936fae4 13780#define HAVE_FSEEKO 1
c0d27fcc 13781_ACEOF
b936fae4 13782
4c343001
DL
13783fi
13784
c0d27fcc 13785
cd958eb3
MB
13786echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
13787echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
13788if test "${ac_cv_func_getpgrp_void+set}" = set; then
13789 echo $ECHO_N "(cached) $ECHO_C" >&6
13790else
13791 # Use it with a single arg.
13792cat >conftest.$ac_ext <<_ACEOF
13793#line $LINENO "configure"
13794/* confdefs.h. */
13795_ACEOF
13796cat confdefs.h >>conftest.$ac_ext
13797cat >>conftest.$ac_ext <<_ACEOF
13798/* end confdefs.h. */
13799$ac_includes_default
13800int
13801main ()
13802{
13803getpgrp (0);
13804 ;
13805 return 0;
13806}
13807_ACEOF
13808rm -f conftest.$ac_objext
13809if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13810 (eval $ac_compile) 2>&5
13811 ac_status=$?
13812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13813 (exit $ac_status); } &&
13814 { ac_try='test -s conftest.$ac_objext'
13815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13816 (eval $ac_try) 2>&5
13817 ac_status=$?
13818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13819 (exit $ac_status); }; }; then
13820 ac_cv_func_getpgrp_void=no
13821else
13822 echo "$as_me: failed program was:" >&5
13823sed 's/^/| /' conftest.$ac_ext >&5
13824
13825ac_cv_func_getpgrp_void=yes
13826fi
13827rm -f conftest.$ac_objext conftest.$ac_ext
13828
13829fi
13830echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
13831echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
13832if test $ac_cv_func_getpgrp_void = yes; then
13833
13834cat >>confdefs.h <<\_ACEOF
13835#define GETPGRP_VOID 1
13836_ACEOF
13837
13838fi
13839
13840
b936fae4
AS
13841# UNIX98 PTYs.
13842
13843for ac_func in grantpt
503d2be0
AS
13844do
13845as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13846echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
13847echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13848if eval "test \"\${$as_ac_var+set}\" = set"; then
13849 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13850else
503d2be0 13851 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13852#line $LINENO "configure"
cd958eb3
MB
13853/* confdefs.h. */
13854_ACEOF
13855cat confdefs.h >>conftest.$ac_ext
13856cat >>conftest.$ac_ext <<_ACEOF
13857/* end confdefs.h. */
503d2be0 13858/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
13859 which can conflict with char $ac_func (); below.
13860 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13861 <limits.h> exists even on freestanding compilers. */
13862#ifdef __STDC__
13863# include <limits.h>
13864#else
13865# include <assert.h>
13866#endif
4c343001 13867/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13868#ifdef __cplusplus
13869extern "C"
cd958eb3 13870{
503d2be0 13871#endif
4c343001 13872/* We use char because int might match the return type of a gcc2
503d2be0
AS
13873 builtin and then its argument prototype would still apply. */
13874char $ac_func ();
503d2be0
AS
13875/* The GNU C library defines this for functions which it implements
13876 to always fail with ENOSYS. Some functions are actually named
13877 something starting with __ and the normal name is an alias. */
13878#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13879choke me
13880#else
cd958eb3
MB
13881char (*f) () = $ac_func;
13882#endif
13883#ifdef __cplusplus
13884}
503d2be0 13885#endif
4c343001 13886
cd958eb3
MB
13887int
13888main ()
13889{
9e71690e 13890return f != $ac_func;
503d2be0
AS
13891 ;
13892 return 0;
13893}
13894_ACEOF
13895rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13896if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13897 (eval $ac_link) 2>&5
13898 ac_status=$?
c0d27fcc 13899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13900 (exit $ac_status); } &&
13901 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13903 (eval $ac_try) 2>&5
13904 ac_status=$?
c0d27fcc 13905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13906 (exit $ac_status); }; }; then
13907 eval "$as_ac_var=yes"
13908else
13909 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13910sed 's/^/| /' conftest.$ac_ext >&5
13911
503d2be0
AS
13912eval "$as_ac_var=no"
13913fi
13914rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13915fi
c0d27fcc 13916echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
13917echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13918if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13919 cat >>confdefs.h <<_ACEOF
503d2be0 13920#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13921_ACEOF
4c343001
DL
13922
13923fi
503d2be0
AS
13924done
13925
c0d27fcc 13926
b936fae4 13927# PTY-related GNU extensions.
4c343001 13928
b936fae4
AS
13929for ac_func in getpt
13930do
13931as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13932echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
13933echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13934if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13935 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13936else
b936fae4 13937 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13938#line $LINENO "configure"
cd958eb3
MB
13939/* confdefs.h. */
13940_ACEOF
13941cat confdefs.h >>conftest.$ac_ext
13942cat >>conftest.$ac_ext <<_ACEOF
13943/* end confdefs.h. */
087121cc 13944/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
13945 which can conflict with char $ac_func (); below.
13946 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13947 <limits.h> exists even on freestanding compilers. */
13948#ifdef __STDC__
13949# include <limits.h>
13950#else
13951# include <assert.h>
13952#endif
087121cc 13953/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13954#ifdef __cplusplus
13955extern "C"
cd958eb3 13956{
503d2be0 13957#endif
087121cc 13958/* We use char because int might match the return type of a gcc2
503d2be0
AS
13959 builtin and then its argument prototype would still apply. */
13960char $ac_func ();
087121cc
GM
13961/* The GNU C library defines this for functions which it implements
13962 to always fail with ENOSYS. Some functions are actually named
13963 something starting with __ and the normal name is an alias. */
13964#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13965choke me
13966#else
cd958eb3
MB
13967char (*f) () = $ac_func;
13968#endif
13969#ifdef __cplusplus
13970}
087121cc
GM
13971#endif
13972
cd958eb3
MB
13973int
13974main ()
13975{
9e71690e 13976return f != $ac_func;
503d2be0
AS
13977 ;
13978 return 0;
13979}
13980_ACEOF
13981rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13982if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13983 (eval $ac_link) 2>&5
13984 ac_status=$?
c0d27fcc 13985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13986 (exit $ac_status); } &&
13987 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13988 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13989 (eval $ac_try) 2>&5
13990 ac_status=$?
c0d27fcc 13991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13992 (exit $ac_status); }; }; then
13993 eval "$as_ac_var=yes"
13994else
13995 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13996sed 's/^/| /' conftest.$ac_ext >&5
13997
503d2be0
AS
13998eval "$as_ac_var=no"
13999fi
14000rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14001fi
c0d27fcc 14002echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
14003echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14004if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 14005 cat >>confdefs.h <<_ACEOF
503d2be0 14006#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14007_ACEOF
087121cc 14008
087121cc
GM
14009fi
14010done
14011
c0d27fcc 14012
ba4481b5
DL
14013# Check this now, so that we will NOT find the above functions in ncurses.
14014# That is because we have not set up to link ncurses in lib-src.
14015# It's better to believe a function is not available
14016# than to expect to find it in ncurses.
503d2be0 14017
c0d27fcc 14018echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
14019echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
14020if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
14021 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14022else
503d2be0 14023 ac_check_lib_save_LIBS=$LIBS
ba4481b5 14024LIBS="-lncurses $LIBS"
503d2be0 14025cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14026#line $LINENO "configure"
cd958eb3
MB
14027/* confdefs.h. */
14028_ACEOF
14029cat confdefs.h >>conftest.$ac_ext
14030cat >>conftest.$ac_ext <<_ACEOF
14031/* end confdefs.h. */
503d2be0 14032
ba4481b5 14033/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14034#ifdef __cplusplus
14035extern "C"
14036#endif
ba4481b5 14037/* We use char because int might match the return type of a gcc2
503d2be0
AS
14038 builtin and then its argument prototype would still apply. */
14039char tparm ();
14040int
14041main ()
14042{
14043tparm ();
14044 ;
14045 return 0;
14046}
14047_ACEOF
14048rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14049if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14050 (eval $ac_link) 2>&5
14051 ac_status=$?
c0d27fcc 14052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14053 (exit $ac_status); } &&
14054 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14055 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14056 (eval $ac_try) 2>&5
14057 ac_status=$?
c0d27fcc 14058 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14059 (exit $ac_status); }; }; then
14060 ac_cv_lib_ncurses_tparm=yes
14061else
14062 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14063sed 's/^/| /' conftest.$ac_ext >&5
14064
503d2be0
AS
14065ac_cv_lib_ncurses_tparm=no
14066fi
14067rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14068LIBS=$ac_check_lib_save_LIBS
14069fi
c0d27fcc 14070echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
14071echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
14072if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 14073 cat >>confdefs.h <<_ACEOF
503d2be0 14074#define HAVE_LIBNCURSES 1
c0d27fcc 14075_ACEOF
ba4481b5
DL
14076
14077 LIBS="-lncurses $LIBS"
14078
ba4481b5
DL
14079fi
14080
c0d27fcc 14081
84e70f78
KR
14082# Do we need the Hesiod library to provide the support routines?
14083if test "$with_hesiod" = yes ; then
14084 # Don't set $LIBS here -- see comments above.
14085 resolv=no
c0d27fcc 14086 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
14087echo $ECHO_N "checking for res_send... $ECHO_C" >&6
14088if test "${ac_cv_func_res_send+set}" = set; then
14089 echo $ECHO_N "(cached) $ECHO_C" >&6
14090else
14091 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14092#line $LINENO "configure"
cd958eb3
MB
14093/* confdefs.h. */
14094_ACEOF
14095cat confdefs.h >>conftest.$ac_ext
14096cat >>conftest.$ac_ext <<_ACEOF
14097/* end confdefs.h. */
84e70f78 14098/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14099 which can conflict with char res_send (); below.
14100 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14101 <limits.h> exists even on freestanding compilers. */
14102#ifdef __STDC__
14103# include <limits.h>
14104#else
14105# include <assert.h>
14106#endif
84e70f78
KR
14107/* Override any gcc2 internal prototype to avoid an error. */
14108#ifdef __cplusplus
14109extern "C"
cd958eb3 14110{
84e70f78
KR
14111#endif
14112/* We use char because int might match the return type of a gcc2
14113 builtin and then its argument prototype would still apply. */
14114char res_send ();
84e70f78
KR
14115/* The GNU C library defines this for functions which it implements
14116 to always fail with ENOSYS. Some functions are actually named
14117 something starting with __ and the normal name is an alias. */
14118#if defined (__stub_res_send) || defined (__stub___res_send)
14119choke me
14120#else
cd958eb3 14121char (*f) () = res_send;
84e70f78 14122#endif
cd958eb3
MB
14123#ifdef __cplusplus
14124}
14125#endif
14126
14127int
14128main ()
14129{
9e71690e 14130return f != res_send;
84e70f78
KR
14131 ;
14132 return 0;
14133}
14134_ACEOF
14135rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14136if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14137 (eval $ac_link) 2>&5
14138 ac_status=$?
c0d27fcc 14139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14140 (exit $ac_status); } &&
14141 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14142 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14143 (eval $ac_try) 2>&5
14144 ac_status=$?
c0d27fcc 14145 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14146 (exit $ac_status); }; }; then
14147 ac_cv_func_res_send=yes
14148else
14149 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14150sed 's/^/| /' conftest.$ac_ext >&5
14151
84e70f78
KR
14152ac_cv_func_res_send=no
14153fi
14154rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14155fi
c0d27fcc 14156echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
14157echo "${ECHO_T}$ac_cv_func_res_send" >&6
14158if test $ac_cv_func_res_send = yes; then
14159 :
14160else
c0d27fcc 14161 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
14162echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
14163if test "${ac_cv_func___res_send+set}" = set; then
14164 echo $ECHO_N "(cached) $ECHO_C" >&6
14165else
14166 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14167#line $LINENO "configure"
cd958eb3
MB
14168/* confdefs.h. */
14169_ACEOF
14170cat confdefs.h >>conftest.$ac_ext
14171cat >>conftest.$ac_ext <<_ACEOF
14172/* end confdefs.h. */
84e70f78 14173/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14174 which can conflict with char __res_send (); below.
14175 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14176 <limits.h> exists even on freestanding compilers. */
14177#ifdef __STDC__
14178# include <limits.h>
14179#else
14180# include <assert.h>
14181#endif
84e70f78
KR
14182/* Override any gcc2 internal prototype to avoid an error. */
14183#ifdef __cplusplus
14184extern "C"
cd958eb3 14185{
84e70f78
KR
14186#endif
14187/* We use char because int might match the return type of a gcc2
14188 builtin and then its argument prototype would still apply. */
14189char __res_send ();
84e70f78
KR
14190/* The GNU C library defines this for functions which it implements
14191 to always fail with ENOSYS. Some functions are actually named
14192 something starting with __ and the normal name is an alias. */
14193#if defined (__stub___res_send) || defined (__stub_____res_send)
14194choke me
14195#else
cd958eb3
MB
14196char (*f) () = __res_send;
14197#endif
14198#ifdef __cplusplus
14199}
84e70f78
KR
14200#endif
14201
cd958eb3
MB
14202int
14203main ()
14204{
9e71690e 14205return f != __res_send;
84e70f78
KR
14206 ;
14207 return 0;
14208}
14209_ACEOF
14210rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14211if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14212 (eval $ac_link) 2>&5
14213 ac_status=$?
c0d27fcc 14214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14215 (exit $ac_status); } &&
14216 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14218 (eval $ac_try) 2>&5
14219 ac_status=$?
c0d27fcc 14220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14221 (exit $ac_status); }; }; then
14222 ac_cv_func___res_send=yes
14223else
14224 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14225sed 's/^/| /' conftest.$ac_ext >&5
14226
84e70f78
KR
14227ac_cv_func___res_send=no
14228fi
14229rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14230fi
c0d27fcc 14231echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
14232echo "${ECHO_T}$ac_cv_func___res_send" >&6
14233if test $ac_cv_func___res_send = yes; then
14234 :
14235else
c0d27fcc 14236 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
14237echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
14238if test "${ac_cv_lib_resolv_res_send+set}" = set; then
14239 echo $ECHO_N "(cached) $ECHO_C" >&6
14240else
14241 ac_check_lib_save_LIBS=$LIBS
14242LIBS="-lresolv $LIBS"
14243cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14244#line $LINENO "configure"
cd958eb3
MB
14245/* confdefs.h. */
14246_ACEOF
14247cat confdefs.h >>conftest.$ac_ext
14248cat >>conftest.$ac_ext <<_ACEOF
14249/* end confdefs.h. */
84e70f78
KR
14250
14251/* Override any gcc2 internal prototype to avoid an error. */
14252#ifdef __cplusplus
14253extern "C"
14254#endif
14255/* We use char because int might match the return type of a gcc2
14256 builtin and then its argument prototype would still apply. */
14257char res_send ();
14258int
14259main ()
14260{
14261res_send ();
14262 ;
14263 return 0;
14264}
14265_ACEOF
14266rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14267if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14268 (eval $ac_link) 2>&5
14269 ac_status=$?
c0d27fcc 14270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14271 (exit $ac_status); } &&
14272 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14273 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14274 (eval $ac_try) 2>&5
14275 ac_status=$?
c0d27fcc 14276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14277 (exit $ac_status); }; }; then
14278 ac_cv_lib_resolv_res_send=yes
14279else
14280 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14281sed 's/^/| /' conftest.$ac_ext >&5
14282
84e70f78
KR
14283ac_cv_lib_resolv_res_send=no
14284fi
14285rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14286LIBS=$ac_check_lib_save_LIBS
14287fi
c0d27fcc 14288echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
14289echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
14290if test $ac_cv_lib_resolv_res_send = yes; then
14291 resolv=yes
14292else
c0d27fcc 14293 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
14294echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
14295if test "${ac_cv_lib_resolv___res_send+set}" = set; then
14296 echo $ECHO_N "(cached) $ECHO_C" >&6
14297else
14298 ac_check_lib_save_LIBS=$LIBS
14299LIBS="-lresolv $LIBS"
14300cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14301#line $LINENO "configure"
cd958eb3
MB
14302/* confdefs.h. */
14303_ACEOF
14304cat confdefs.h >>conftest.$ac_ext
14305cat >>conftest.$ac_ext <<_ACEOF
14306/* end confdefs.h. */
84e70f78
KR
14307
14308/* Override any gcc2 internal prototype to avoid an error. */
14309#ifdef __cplusplus
14310extern "C"
14311#endif
14312/* We use char because int might match the return type of a gcc2
14313 builtin and then its argument prototype would still apply. */
14314char __res_send ();
14315int
14316main ()
14317{
14318__res_send ();
14319 ;
14320 return 0;
14321}
14322_ACEOF
14323rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14324if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14325 (eval $ac_link) 2>&5
14326 ac_status=$?
c0d27fcc 14327 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14328 (exit $ac_status); } &&
14329 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14330 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14331 (eval $ac_try) 2>&5
14332 ac_status=$?
c0d27fcc 14333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14334 (exit $ac_status); }; }; then
14335 ac_cv_lib_resolv___res_send=yes
14336else
14337 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14338sed 's/^/| /' conftest.$ac_ext >&5
14339
84e70f78
KR
14340ac_cv_lib_resolv___res_send=no
14341fi
14342rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14343LIBS=$ac_check_lib_save_LIBS
14344fi
c0d27fcc 14345echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
14346echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
14347if test $ac_cv_lib_resolv___res_send = yes; then
14348 resolv=yes
14349fi
14350
14351fi
14352
14353fi
14354
14355fi
14356
14357 if test "$resolv" = yes ; then
14358 RESOLVLIB=-lresolv
b936fae4 14359
c0d27fcc 14360cat >>confdefs.h <<\_ACEOF
84e70f78 14361#define HAVE_LIBRESOLV 1
c0d27fcc 14362_ACEOF
84e70f78
KR
14363
14364 else
14365 RESOLVLIB=
14366 fi
c0d27fcc 14367 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
14368echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
14369if test "${ac_cv_func_hes_getmailhost+set}" = set; then
14370 echo $ECHO_N "(cached) $ECHO_C" >&6
14371else
14372 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14373#line $LINENO "configure"
cd958eb3
MB
14374/* confdefs.h. */
14375_ACEOF
14376cat confdefs.h >>conftest.$ac_ext
14377cat >>conftest.$ac_ext <<_ACEOF
14378/* end confdefs.h. */
84e70f78 14379/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14380 which can conflict with char hes_getmailhost (); below.
14381 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14382 <limits.h> exists even on freestanding compilers. */
14383#ifdef __STDC__
14384# include <limits.h>
14385#else
14386# include <assert.h>
14387#endif
84e70f78
KR
14388/* Override any gcc2 internal prototype to avoid an error. */
14389#ifdef __cplusplus
14390extern "C"
cd958eb3 14391{
84e70f78
KR
14392#endif
14393/* We use char because int might match the return type of a gcc2
14394 builtin and then its argument prototype would still apply. */
14395char hes_getmailhost ();
84e70f78
KR
14396/* The GNU C library defines this for functions which it implements
14397 to always fail with ENOSYS. Some functions are actually named
14398 something starting with __ and the normal name is an alias. */
14399#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
14400choke me
14401#else
cd958eb3 14402char (*f) () = hes_getmailhost;
84e70f78 14403#endif
cd958eb3
MB
14404#ifdef __cplusplus
14405}
14406#endif
14407
14408int
14409main ()
14410{
9e71690e 14411return f != hes_getmailhost;
84e70f78
KR
14412 ;
14413 return 0;
14414}
14415_ACEOF
14416rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14417if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14418 (eval $ac_link) 2>&5
14419 ac_status=$?
c0d27fcc 14420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14421 (exit $ac_status); } &&
14422 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14424 (eval $ac_try) 2>&5
14425 ac_status=$?
c0d27fcc 14426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14427 (exit $ac_status); }; }; then
14428 ac_cv_func_hes_getmailhost=yes
14429else
14430 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14431sed 's/^/| /' conftest.$ac_ext >&5
14432
84e70f78
KR
14433ac_cv_func_hes_getmailhost=no
14434fi
14435rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14436fi
c0d27fcc 14437echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
14438echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
14439if test $ac_cv_func_hes_getmailhost = yes; then
14440 :
14441else
c0d27fcc 14442 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
14443echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
14444if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
14445 echo $ECHO_N "(cached) $ECHO_C" >&6
14446else
14447 ac_check_lib_save_LIBS=$LIBS
14448LIBS="-lhesiod $RESOLVLIB $LIBS"
14449cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14450#line $LINENO "configure"
cd958eb3
MB
14451/* confdefs.h. */
14452_ACEOF
14453cat confdefs.h >>conftest.$ac_ext
14454cat >>conftest.$ac_ext <<_ACEOF
14455/* end confdefs.h. */
84e70f78
KR
14456
14457/* Override any gcc2 internal prototype to avoid an error. */
14458#ifdef __cplusplus
14459extern "C"
14460#endif
14461/* We use char because int might match the return type of a gcc2
14462 builtin and then its argument prototype would still apply. */
14463char hes_getmailhost ();
14464int
14465main ()
14466{
14467hes_getmailhost ();
14468 ;
14469 return 0;
14470}
14471_ACEOF
14472rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14473if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14474 (eval $ac_link) 2>&5
14475 ac_status=$?
c0d27fcc 14476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14477 (exit $ac_status); } &&
14478 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14479 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14480 (eval $ac_try) 2>&5
14481 ac_status=$?
c0d27fcc 14482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14483 (exit $ac_status); }; }; then
14484 ac_cv_lib_hesiod_hes_getmailhost=yes
14485else
14486 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14487sed 's/^/| /' conftest.$ac_ext >&5
14488
84e70f78
KR
14489ac_cv_lib_hesiod_hes_getmailhost=no
14490fi
14491rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14492LIBS=$ac_check_lib_save_LIBS
14493fi
c0d27fcc 14494echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
14495echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
14496if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 14497
c0d27fcc 14498cat >>confdefs.h <<\_ACEOF
84e70f78 14499#define HAVE_LIBHESIOD 1
c0d27fcc 14500_ACEOF
84e70f78
KR
14501
14502else
14503 :
14504fi
14505
14506fi
14507
14508fi
14509
a21616bd
KR
14510# These tell us which Kerberos-related libraries to use.
14511if test "${with_kerberos+set}" = set; then
503d2be0 14512
c0d27fcc 14513echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
14514echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
14515if test "${ac_cv_lib_com_err_com_err+set}" = set; then
14516 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14517else
503d2be0 14518 ac_check_lib_save_LIBS=$LIBS
a21616bd 14519LIBS="-lcom_err $LIBS"
503d2be0 14520cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14521#line $LINENO "configure"
cd958eb3
MB
14522/* confdefs.h. */
14523_ACEOF
14524cat confdefs.h >>conftest.$ac_ext
14525cat >>conftest.$ac_ext <<_ACEOF
14526/* end confdefs.h. */
503d2be0 14527
a21616bd 14528/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14529#ifdef __cplusplus
14530extern "C"
14531#endif
a21616bd 14532/* We use char because int might match the return type of a gcc2
503d2be0
AS
14533 builtin and then its argument prototype would still apply. */
14534char com_err ();
14535int
14536main ()
14537{
14538com_err ();
14539 ;
14540 return 0;
14541}
14542_ACEOF
14543rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14544if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14545 (eval $ac_link) 2>&5
14546 ac_status=$?
c0d27fcc 14547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14548 (exit $ac_status); } &&
14549 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14550 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14551 (eval $ac_try) 2>&5
14552 ac_status=$?
c0d27fcc 14553 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14554 (exit $ac_status); }; }; then
14555 ac_cv_lib_com_err_com_err=yes
14556else
14557 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14558sed 's/^/| /' conftest.$ac_ext >&5
14559
503d2be0
AS
14560ac_cv_lib_com_err_com_err=no
14561fi
14562rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14563LIBS=$ac_check_lib_save_LIBS
14564fi
c0d27fcc 14565echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
14566echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
14567if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 14568 cat >>confdefs.h <<_ACEOF
503d2be0 14569#define HAVE_LIBCOM_ERR 1
c0d27fcc 14570_ACEOF
a21616bd
KR
14571
14572 LIBS="-lcom_err $LIBS"
14573
a21616bd
KR
14574fi
14575
c0d27fcc
MR
14576
14577echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
14578echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
14579if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
14580 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14581else
503d2be0 14582 ac_check_lib_save_LIBS=$LIBS
a21616bd 14583LIBS="-lk5crypto $LIBS"
503d2be0 14584cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14585#line $LINENO "configure"
cd958eb3
MB
14586/* confdefs.h. */
14587_ACEOF
14588cat confdefs.h >>conftest.$ac_ext
14589cat >>conftest.$ac_ext <<_ACEOF
14590/* end confdefs.h. */
503d2be0 14591
a21616bd 14592/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14593#ifdef __cplusplus
14594extern "C"
14595#endif
a21616bd 14596/* We use char because int might match the return type of a gcc2
503d2be0
AS
14597 builtin and then its argument prototype would still apply. */
14598char mit_des_cbc_encrypt ();
14599int
14600main ()
14601{
14602mit_des_cbc_encrypt ();
14603 ;
14604 return 0;
14605}
14606_ACEOF
14607rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14608if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14609 (eval $ac_link) 2>&5
14610 ac_status=$?
c0d27fcc 14611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14612 (exit $ac_status); } &&
14613 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14614 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14615 (eval $ac_try) 2>&5
14616 ac_status=$?
c0d27fcc 14617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14618 (exit $ac_status); }; }; then
14619 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14620else
14621 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14622sed 's/^/| /' conftest.$ac_ext >&5
14623
503d2be0
AS
14624ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14625fi
14626rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14627LIBS=$ac_check_lib_save_LIBS
14628fi
c0d27fcc 14629echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
14630echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
14631if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 14632 cat >>confdefs.h <<_ACEOF
503d2be0 14633#define HAVE_LIBK5CRYPTO 1
c0d27fcc 14634_ACEOF
a21616bd
KR
14635
14636 LIBS="-lk5crypto $LIBS"
14637
a21616bd
KR
14638fi
14639
c0d27fcc
MR
14640
14641echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
14642echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
14643if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
14644 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14645else
503d2be0 14646 ac_check_lib_save_LIBS=$LIBS
a21616bd 14647LIBS="-lcrypto $LIBS"
503d2be0 14648cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14649#line $LINENO "configure"
cd958eb3
MB
14650/* confdefs.h. */
14651_ACEOF
14652cat confdefs.h >>conftest.$ac_ext
14653cat >>conftest.$ac_ext <<_ACEOF
14654/* end confdefs.h. */
503d2be0 14655
a21616bd 14656/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14657#ifdef __cplusplus
14658extern "C"
14659#endif
a21616bd 14660/* We use char because int might match the return type of a gcc2
503d2be0
AS
14661 builtin and then its argument prototype would still apply. */
14662char mit_des_cbc_encrypt ();
14663int
14664main ()
14665{
14666mit_des_cbc_encrypt ();
14667 ;
14668 return 0;
14669}
14670_ACEOF
14671rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14672if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14673 (eval $ac_link) 2>&5
14674 ac_status=$?
c0d27fcc 14675 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14676 (exit $ac_status); } &&
14677 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14679 (eval $ac_try) 2>&5
14680 ac_status=$?
c0d27fcc 14681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14682 (exit $ac_status); }; }; then
14683 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14684else
14685 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14686sed 's/^/| /' conftest.$ac_ext >&5
14687
503d2be0
AS
14688ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14689fi
14690rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14691LIBS=$ac_check_lib_save_LIBS
14692fi
c0d27fcc 14693echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
14694echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
14695if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 14696 cat >>confdefs.h <<_ACEOF
503d2be0 14697#define HAVE_LIBCRYPTO 1
c0d27fcc 14698_ACEOF
a21616bd
KR
14699
14700 LIBS="-lcrypto $LIBS"
14701
a21616bd
KR
14702fi
14703
c0d27fcc
MR
14704
14705echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
14706echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
14707if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
14708 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14709else
503d2be0 14710 ac_check_lib_save_LIBS=$LIBS
a21616bd 14711LIBS="-lkrb5 $LIBS"
503d2be0 14712cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14713#line $LINENO "configure"
cd958eb3
MB
14714/* confdefs.h. */
14715_ACEOF
14716cat confdefs.h >>conftest.$ac_ext
14717cat >>conftest.$ac_ext <<_ACEOF
14718/* end confdefs.h. */
a21616bd 14719
503d2be0
AS
14720/* Override any gcc2 internal prototype to avoid an error. */
14721#ifdef __cplusplus
14722extern "C"
14723#endif
14724/* We use char because int might match the return type of a gcc2
14725 builtin and then its argument prototype would still apply. */
14726char krb5_init_context ();
14727int
14728main ()
14729{
14730krb5_init_context ();
14731 ;
14732 return 0;
14733}
14734_ACEOF
14735rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14736if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14737 (eval $ac_link) 2>&5
14738 ac_status=$?
c0d27fcc 14739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14740 (exit $ac_status); } &&
14741 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14743 (eval $ac_try) 2>&5
14744 ac_status=$?
c0d27fcc 14745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14746 (exit $ac_status); }; }; then
14747 ac_cv_lib_krb5_krb5_init_context=yes
14748else
14749 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14750sed 's/^/| /' conftest.$ac_ext >&5
14751
503d2be0
AS
14752ac_cv_lib_krb5_krb5_init_context=no
14753fi
14754rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14755LIBS=$ac_check_lib_save_LIBS
14756fi
c0d27fcc 14757echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
14758echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
14759if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 14760 cat >>confdefs.h <<_ACEOF
503d2be0 14761#define HAVE_LIBKRB5 1
c0d27fcc 14762_ACEOF
a21616bd
KR
14763
14764 LIBS="-lkrb5 $LIBS"
14765
a21616bd
KR
14766fi
14767
14768 if test "${with_kerberos5+set}" != set; then
503d2be0 14769
c0d27fcc 14770echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
14771echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
14772if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
14773 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14774else
503d2be0 14775 ac_check_lib_save_LIBS=$LIBS
a21616bd 14776LIBS="-ldes425 $LIBS"
503d2be0 14777cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14778#line $LINENO "configure"
cd958eb3
MB
14779/* confdefs.h. */
14780_ACEOF
14781cat confdefs.h >>conftest.$ac_ext
14782cat >>conftest.$ac_ext <<_ACEOF
14783/* end confdefs.h. */
503d2be0 14784
a21616bd 14785/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14786#ifdef __cplusplus
14787extern "C"
14788#endif
a21616bd 14789/* We use char because int might match the return type of a gcc2
503d2be0
AS
14790 builtin and then its argument prototype would still apply. */
14791char des_cbc_encrypt ();
14792int
14793main ()
14794{
14795des_cbc_encrypt ();
14796 ;
14797 return 0;
14798}
14799_ACEOF
14800rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14801if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14802 (eval $ac_link) 2>&5
14803 ac_status=$?
c0d27fcc 14804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14805 (exit $ac_status); } &&
14806 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14807 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14808 (eval $ac_try) 2>&5
14809 ac_status=$?
c0d27fcc 14810 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14811 (exit $ac_status); }; }; then
14812 ac_cv_lib_des425_des_cbc_encrypt=yes
14813else
14814 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14815sed 's/^/| /' conftest.$ac_ext >&5
14816
503d2be0
AS
14817ac_cv_lib_des425_des_cbc_encrypt=no
14818fi
14819rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14820LIBS=$ac_check_lib_save_LIBS
14821fi
c0d27fcc 14822echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
14823echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
14824if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 14825 cat >>confdefs.h <<_ACEOF
503d2be0 14826#define HAVE_LIBDES425 1
c0d27fcc 14827_ACEOF
a21616bd
KR
14828
14829 LIBS="-ldes425 $LIBS"
14830
14831else
503d2be0 14832
c0d27fcc 14833echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
14834echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
14835if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
14836 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14837else
503d2be0 14838 ac_check_lib_save_LIBS=$LIBS
a21616bd 14839LIBS="-ldes $LIBS"
503d2be0 14840cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14841#line $LINENO "configure"
cd958eb3
MB
14842/* confdefs.h. */
14843_ACEOF
14844cat confdefs.h >>conftest.$ac_ext
14845cat >>conftest.$ac_ext <<_ACEOF
14846/* end confdefs.h. */
503d2be0 14847
a21616bd 14848/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14849#ifdef __cplusplus
14850extern "C"
14851#endif
a21616bd 14852/* We use char because int might match the return type of a gcc2
503d2be0
AS
14853 builtin and then its argument prototype would still apply. */
14854char des_cbc_encrypt ();
14855int
14856main ()
14857{
14858des_cbc_encrypt ();
14859 ;
14860 return 0;
14861}
14862_ACEOF
14863rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14864if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14865 (eval $ac_link) 2>&5
14866 ac_status=$?
c0d27fcc 14867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14868 (exit $ac_status); } &&
14869 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14870 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14871 (eval $ac_try) 2>&5
14872 ac_status=$?
c0d27fcc 14873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14874 (exit $ac_status); }; }; then
14875 ac_cv_lib_des_des_cbc_encrypt=yes
14876else
14877 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14878sed 's/^/| /' conftest.$ac_ext >&5
14879
503d2be0
AS
14880ac_cv_lib_des_des_cbc_encrypt=no
14881fi
14882rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14883LIBS=$ac_check_lib_save_LIBS
14884fi
c0d27fcc 14885echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
14886echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
14887if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 14888 cat >>confdefs.h <<_ACEOF
503d2be0 14889#define HAVE_LIBDES 1
c0d27fcc 14890_ACEOF
a21616bd
KR
14891
14892 LIBS="-ldes $LIBS"
14893
a21616bd
KR
14894fi
14895
14896fi
14897
c0d27fcc
MR
14898
14899echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
14900echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
14901if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
14902 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14903else
503d2be0 14904 ac_check_lib_save_LIBS=$LIBS
a21616bd 14905LIBS="-lkrb4 $LIBS"
503d2be0 14906cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14907#line $LINENO "configure"
cd958eb3
MB
14908/* confdefs.h. */
14909_ACEOF
14910cat confdefs.h >>conftest.$ac_ext
14911cat >>conftest.$ac_ext <<_ACEOF
14912/* end confdefs.h. */
503d2be0 14913
a21616bd 14914/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14915#ifdef __cplusplus
14916extern "C"
14917#endif
a21616bd 14918/* We use char because int might match the return type of a gcc2
503d2be0
AS
14919 builtin and then its argument prototype would still apply. */
14920char krb_get_cred ();
14921int
14922main ()
14923{
14924krb_get_cred ();
14925 ;
14926 return 0;
14927}
14928_ACEOF
14929rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14930if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14931 (eval $ac_link) 2>&5
14932 ac_status=$?
c0d27fcc 14933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14934 (exit $ac_status); } &&
14935 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14936 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14937 (eval $ac_try) 2>&5
14938 ac_status=$?
c0d27fcc 14939 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14940 (exit $ac_status); }; }; then
14941 ac_cv_lib_krb4_krb_get_cred=yes
14942else
14943 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14944sed 's/^/| /' conftest.$ac_ext >&5
14945
503d2be0
AS
14946ac_cv_lib_krb4_krb_get_cred=no
14947fi
14948rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14949LIBS=$ac_check_lib_save_LIBS
14950fi
c0d27fcc 14951echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
14952echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
14953if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 14954 cat >>confdefs.h <<_ACEOF
503d2be0 14955#define HAVE_LIBKRB4 1
c0d27fcc 14956_ACEOF
a21616bd
KR
14957
14958 LIBS="-lkrb4 $LIBS"
14959
14960else
503d2be0 14961
c0d27fcc 14962echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
14963echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
14964if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
14965 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14966else
503d2be0 14967 ac_check_lib_save_LIBS=$LIBS
a21616bd 14968LIBS="-lkrb $LIBS"
503d2be0 14969cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14970#line $LINENO "configure"
cd958eb3
MB
14971/* confdefs.h. */
14972_ACEOF
14973cat confdefs.h >>conftest.$ac_ext
14974cat >>conftest.$ac_ext <<_ACEOF
14975/* end confdefs.h. */
503d2be0 14976
a21616bd 14977/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14978#ifdef __cplusplus
14979extern "C"
14980#endif
a21616bd 14981/* We use char because int might match the return type of a gcc2
503d2be0
AS
14982 builtin and then its argument prototype would still apply. */
14983char krb_get_cred ();
14984int
14985main ()
14986{
14987krb_get_cred ();
14988 ;
14989 return 0;
14990}
14991_ACEOF
14992rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14993if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14994 (eval $ac_link) 2>&5
14995 ac_status=$?
c0d27fcc 14996 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14997 (exit $ac_status); } &&
14998 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14999 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
15000 (eval $ac_try) 2>&5
15001 ac_status=$?
c0d27fcc 15002 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15003 (exit $ac_status); }; }; then
15004 ac_cv_lib_krb_krb_get_cred=yes
15005else
15006 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15007sed 's/^/| /' conftest.$ac_ext >&5
15008
503d2be0
AS
15009ac_cv_lib_krb_krb_get_cred=no
15010fi
15011rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15012LIBS=$ac_check_lib_save_LIBS
15013fi
c0d27fcc 15014echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
15015echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
15016if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 15017 cat >>confdefs.h <<_ACEOF
503d2be0 15018#define HAVE_LIBKRB 1
c0d27fcc 15019_ACEOF
a21616bd
KR
15020
15021 LIBS="-lkrb $LIBS"
15022
a21616bd
KR
15023fi
15024
15025fi
15026
15027 fi
15028
15029 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
15030
15031for ac_header in krb5.h
a21616bd 15032do
503d2be0 15033as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15034if eval "test \"\${$as_ac_Header+set}\" = set"; then
15035 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15036echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15037if eval "test \"\${$as_ac_Header+set}\" = set"; then
15038 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15039fi
15040echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15041echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15042else
c0d27fcc
MR
15043 # Is the header compilable?
15044echo "$as_me:$LINENO: checking $ac_header usability" >&5
15045echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15046cat >conftest.$ac_ext <<_ACEOF
15047#line $LINENO "configure"
cd958eb3
MB
15048/* confdefs.h. */
15049_ACEOF
15050cat confdefs.h >>conftest.$ac_ext
15051cat >>conftest.$ac_ext <<_ACEOF
15052/* end confdefs.h. */
c0d27fcc
MR
15053$ac_includes_default
15054#include <$ac_header>
15055_ACEOF
15056rm -f conftest.$ac_objext
15057if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15058 (eval $ac_compile) 2>&5
15059 ac_status=$?
15060 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15061 (exit $ac_status); } &&
15062 { ac_try='test -s conftest.$ac_objext'
15063 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15064 (eval $ac_try) 2>&5
15065 ac_status=$?
15066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15067 (exit $ac_status); }; }; then
15068 ac_header_compiler=yes
15069else
15070 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15071sed 's/^/| /' conftest.$ac_ext >&5
15072
c0d27fcc
MR
15073ac_header_compiler=no
15074fi
15075rm -f conftest.$ac_objext conftest.$ac_ext
15076echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15077echo "${ECHO_T}$ac_header_compiler" >&6
15078
15079# Is the header present?
15080echo "$as_me:$LINENO: checking $ac_header presence" >&5
15081echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15082cat >conftest.$ac_ext <<_ACEOF
15083#line $LINENO "configure"
cd958eb3
MB
15084/* confdefs.h. */
15085_ACEOF
15086cat confdefs.h >>conftest.$ac_ext
15087cat >>conftest.$ac_ext <<_ACEOF
15088/* end confdefs.h. */
503d2be0
AS
15089#include <$ac_header>
15090_ACEOF
c0d27fcc 15091if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15092 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15093 ac_status=$?
6bae0ccf 15094 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15095 rm -f conftest.er1
15096 cat conftest.err >&5
c0d27fcc 15097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15098 (exit $ac_status); } >/dev/null; then
15099 if test -s conftest.err; then
15100 ac_cpp_err=$ac_c_preproc_warn_flag
15101 else
15102 ac_cpp_err=
15103 fi
15104else
15105 ac_cpp_err=yes
15106fi
15107if test -z "$ac_cpp_err"; then
c0d27fcc 15108 ac_header_preproc=yes
503d2be0
AS
15109else
15110 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15111sed 's/^/| /' conftest.$ac_ext >&5
15112
c0d27fcc 15113 ac_header_preproc=no
a21616bd 15114fi
503d2be0 15115rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15116echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15117echo "${ECHO_T}$ac_header_preproc" >&6
15118
15119# So? What about this header?
15120case $ac_header_compiler:$ac_header_preproc in
15121 yes:no )
15122 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15123echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15124 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15125echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15126 (
15127 cat <<\_ASBOX
15128## ------------------------------------ ##
15129## Report this to bug-autoconf@gnu.org. ##
15130## ------------------------------------ ##
15131_ASBOX
15132 ) |
15133 sed "s/^/$as_me: WARNING: /" >&2
15134 ;;
c0d27fcc
MR
15135 no:yes )
15136 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15137echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15138 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15139echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15140 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15141echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15142 (
15143 cat <<\_ASBOX
15144## ------------------------------------ ##
15145## Report this to bug-autoconf@gnu.org. ##
15146## ------------------------------------ ##
15147_ASBOX
15148 ) |
15149 sed "s/^/$as_me: WARNING: /" >&2
15150 ;;
c0d27fcc
MR
15151esac
15152echo "$as_me:$LINENO: checking for $ac_header" >&5
15153echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15154if eval "test \"\${$as_ac_Header+set}\" = set"; then
15155 echo $ECHO_N "(cached) $ECHO_C" >&6
15156else
15157 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15158fi
c0d27fcc 15159echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15160echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15161
15162fi
503d2be0 15163if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15164 cat >>confdefs.h <<_ACEOF
503d2be0 15165#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15166_ACEOF
503d2be0 15167
a21616bd 15168fi
c0d27fcc 15169
a21616bd
KR
15170done
15171
15172 else
503d2be0
AS
15173
15174for ac_header in des.h
a21616bd 15175do
503d2be0 15176as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15177if eval "test \"\${$as_ac_Header+set}\" = set"; then
15178 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15179echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15180if eval "test \"\${$as_ac_Header+set}\" = set"; then
15181 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15182fi
15183echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15184echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15185else
c0d27fcc
MR
15186 # Is the header compilable?
15187echo "$as_me:$LINENO: checking $ac_header usability" >&5
15188echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15189cat >conftest.$ac_ext <<_ACEOF
15190#line $LINENO "configure"
cd958eb3
MB
15191/* confdefs.h. */
15192_ACEOF
15193cat confdefs.h >>conftest.$ac_ext
15194cat >>conftest.$ac_ext <<_ACEOF
15195/* end confdefs.h. */
c0d27fcc
MR
15196$ac_includes_default
15197#include <$ac_header>
15198_ACEOF
15199rm -f conftest.$ac_objext
15200if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15201 (eval $ac_compile) 2>&5
15202 ac_status=$?
15203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15204 (exit $ac_status); } &&
15205 { ac_try='test -s conftest.$ac_objext'
15206 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15207 (eval $ac_try) 2>&5
15208 ac_status=$?
15209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15210 (exit $ac_status); }; }; then
15211 ac_header_compiler=yes
15212else
15213 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15214sed 's/^/| /' conftest.$ac_ext >&5
15215
c0d27fcc
MR
15216ac_header_compiler=no
15217fi
15218rm -f conftest.$ac_objext conftest.$ac_ext
15219echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15220echo "${ECHO_T}$ac_header_compiler" >&6
15221
15222# Is the header present?
15223echo "$as_me:$LINENO: checking $ac_header presence" >&5
15224echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15225cat >conftest.$ac_ext <<_ACEOF
15226#line $LINENO "configure"
cd958eb3
MB
15227/* confdefs.h. */
15228_ACEOF
15229cat confdefs.h >>conftest.$ac_ext
15230cat >>conftest.$ac_ext <<_ACEOF
15231/* end confdefs.h. */
503d2be0
AS
15232#include <$ac_header>
15233_ACEOF
c0d27fcc 15234if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15235 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15236 ac_status=$?
6bae0ccf 15237 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15238 rm -f conftest.er1
15239 cat conftest.err >&5
c0d27fcc 15240 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15241 (exit $ac_status); } >/dev/null; then
15242 if test -s conftest.err; then
15243 ac_cpp_err=$ac_c_preproc_warn_flag
15244 else
15245 ac_cpp_err=
15246 fi
15247else
15248 ac_cpp_err=yes
15249fi
15250if test -z "$ac_cpp_err"; then
c0d27fcc 15251 ac_header_preproc=yes
503d2be0
AS
15252else
15253 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15254sed 's/^/| /' conftest.$ac_ext >&5
15255
c0d27fcc 15256 ac_header_preproc=no
a21616bd 15257fi
503d2be0 15258rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15259echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15260echo "${ECHO_T}$ac_header_preproc" >&6
15261
15262# So? What about this header?
15263case $ac_header_compiler:$ac_header_preproc in
15264 yes:no )
15265 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15266echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15267 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15268echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15269 (
15270 cat <<\_ASBOX
15271## ------------------------------------ ##
15272## Report this to bug-autoconf@gnu.org. ##
15273## ------------------------------------ ##
15274_ASBOX
15275 ) |
15276 sed "s/^/$as_me: WARNING: /" >&2
15277 ;;
c0d27fcc
MR
15278 no:yes )
15279 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15280echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15281 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15282echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15283 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15284echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15285 (
15286 cat <<\_ASBOX
15287## ------------------------------------ ##
15288## Report this to bug-autoconf@gnu.org. ##
15289## ------------------------------------ ##
15290_ASBOX
15291 ) |
15292 sed "s/^/$as_me: WARNING: /" >&2
15293 ;;
c0d27fcc
MR
15294esac
15295echo "$as_me:$LINENO: checking for $ac_header" >&5
15296echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15297if eval "test \"\${$as_ac_Header+set}\" = set"; then
15298 echo $ECHO_N "(cached) $ECHO_C" >&6
15299else
15300 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15301fi
c0d27fcc 15302echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15303echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15304
15305fi
503d2be0 15306if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15307 cat >>confdefs.h <<_ACEOF
503d2be0 15308#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15309_ACEOF
503d2be0 15310
a21616bd 15311else
503d2be0
AS
15312
15313for ac_header in kerberosIV/des.h
a21616bd 15314do
503d2be0 15315as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15316if eval "test \"\${$as_ac_Header+set}\" = set"; then
15317 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15318echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15319if eval "test \"\${$as_ac_Header+set}\" = set"; then
15320 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15321fi
15322echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15323echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15324else
c0d27fcc
MR
15325 # Is the header compilable?
15326echo "$as_me:$LINENO: checking $ac_header usability" >&5
15327echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15328cat >conftest.$ac_ext <<_ACEOF
15329#line $LINENO "configure"
cd958eb3
MB
15330/* confdefs.h. */
15331_ACEOF
15332cat confdefs.h >>conftest.$ac_ext
15333cat >>conftest.$ac_ext <<_ACEOF
15334/* end confdefs.h. */
c0d27fcc
MR
15335$ac_includes_default
15336#include <$ac_header>
15337_ACEOF
15338rm -f conftest.$ac_objext
15339if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15340 (eval $ac_compile) 2>&5
15341 ac_status=$?
15342 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15343 (exit $ac_status); } &&
15344 { ac_try='test -s conftest.$ac_objext'
15345 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15346 (eval $ac_try) 2>&5
15347 ac_status=$?
15348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15349 (exit $ac_status); }; }; then
15350 ac_header_compiler=yes
15351else
15352 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15353sed 's/^/| /' conftest.$ac_ext >&5
15354
c0d27fcc
MR
15355ac_header_compiler=no
15356fi
15357rm -f conftest.$ac_objext conftest.$ac_ext
15358echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15359echo "${ECHO_T}$ac_header_compiler" >&6
15360
15361# Is the header present?
15362echo "$as_me:$LINENO: checking $ac_header presence" >&5
15363echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15364cat >conftest.$ac_ext <<_ACEOF
15365#line $LINENO "configure"
cd958eb3
MB
15366/* confdefs.h. */
15367_ACEOF
15368cat confdefs.h >>conftest.$ac_ext
15369cat >>conftest.$ac_ext <<_ACEOF
15370/* end confdefs.h. */
503d2be0
AS
15371#include <$ac_header>
15372_ACEOF
c0d27fcc 15373if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15374 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15375 ac_status=$?
6bae0ccf 15376 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15377 rm -f conftest.er1
15378 cat conftest.err >&5
c0d27fcc 15379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15380 (exit $ac_status); } >/dev/null; then
15381 if test -s conftest.err; then
15382 ac_cpp_err=$ac_c_preproc_warn_flag
15383 else
15384 ac_cpp_err=
15385 fi
15386else
15387 ac_cpp_err=yes
15388fi
15389if test -z "$ac_cpp_err"; then
c0d27fcc 15390 ac_header_preproc=yes
503d2be0
AS
15391else
15392 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15393sed 's/^/| /' conftest.$ac_ext >&5
15394
c0d27fcc 15395 ac_header_preproc=no
a21616bd 15396fi
503d2be0 15397rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15398echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15399echo "${ECHO_T}$ac_header_preproc" >&6
15400
15401# So? What about this header?
15402case $ac_header_compiler:$ac_header_preproc in
15403 yes:no )
15404 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15405echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15406 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15407echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15408 (
15409 cat <<\_ASBOX
15410## ------------------------------------ ##
15411## Report this to bug-autoconf@gnu.org. ##
15412## ------------------------------------ ##
15413_ASBOX
15414 ) |
15415 sed "s/^/$as_me: WARNING: /" >&2
15416 ;;
c0d27fcc
MR
15417 no:yes )
15418 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15419echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15420 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15421echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15422 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15423echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15424 (
15425 cat <<\_ASBOX
15426## ------------------------------------ ##
15427## Report this to bug-autoconf@gnu.org. ##
15428## ------------------------------------ ##
15429_ASBOX
15430 ) |
15431 sed "s/^/$as_me: WARNING: /" >&2
15432 ;;
c0d27fcc
MR
15433esac
15434echo "$as_me:$LINENO: checking for $ac_header" >&5
15435echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15436if eval "test \"\${$as_ac_Header+set}\" = set"; then
15437 echo $ECHO_N "(cached) $ECHO_C" >&6
15438else
15439 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15440fi
c0d27fcc 15441echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15442echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15443
15444fi
503d2be0 15445if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15446 cat >>confdefs.h <<_ACEOF
503d2be0 15447#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15448_ACEOF
503d2be0 15449
a21616bd 15450else
503d2be0
AS
15451
15452for ac_header in kerberos/des.h
a21616bd 15453do
503d2be0 15454as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15455if eval "test \"\${$as_ac_Header+set}\" = set"; then
15456 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15457echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15458if eval "test \"\${$as_ac_Header+set}\" = set"; then
15459 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15460fi
15461echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15462echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15463else
c0d27fcc
MR
15464 # Is the header compilable?
15465echo "$as_me:$LINENO: checking $ac_header usability" >&5
15466echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15467cat >conftest.$ac_ext <<_ACEOF
15468#line $LINENO "configure"
cd958eb3
MB
15469/* confdefs.h. */
15470_ACEOF
15471cat confdefs.h >>conftest.$ac_ext
15472cat >>conftest.$ac_ext <<_ACEOF
15473/* end confdefs.h. */
c0d27fcc
MR
15474$ac_includes_default
15475#include <$ac_header>
15476_ACEOF
15477rm -f conftest.$ac_objext
15478if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15479 (eval $ac_compile) 2>&5
15480 ac_status=$?
15481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15482 (exit $ac_status); } &&
15483 { ac_try='test -s conftest.$ac_objext'
15484 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15485 (eval $ac_try) 2>&5
15486 ac_status=$?
15487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15488 (exit $ac_status); }; }; then
15489 ac_header_compiler=yes
15490else
15491 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15492sed 's/^/| /' conftest.$ac_ext >&5
15493
c0d27fcc
MR
15494ac_header_compiler=no
15495fi
15496rm -f conftest.$ac_objext conftest.$ac_ext
15497echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15498echo "${ECHO_T}$ac_header_compiler" >&6
15499
15500# Is the header present?
15501echo "$as_me:$LINENO: checking $ac_header presence" >&5
15502echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15503cat >conftest.$ac_ext <<_ACEOF
15504#line $LINENO "configure"
cd958eb3
MB
15505/* confdefs.h. */
15506_ACEOF
15507cat confdefs.h >>conftest.$ac_ext
15508cat >>conftest.$ac_ext <<_ACEOF
15509/* end confdefs.h. */
503d2be0
AS
15510#include <$ac_header>
15511_ACEOF
c0d27fcc 15512if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15513 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15514 ac_status=$?
6bae0ccf 15515 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15516 rm -f conftest.er1
15517 cat conftest.err >&5
c0d27fcc 15518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15519 (exit $ac_status); } >/dev/null; then
15520 if test -s conftest.err; then
15521 ac_cpp_err=$ac_c_preproc_warn_flag
15522 else
15523 ac_cpp_err=
15524 fi
15525else
15526 ac_cpp_err=yes
15527fi
15528if test -z "$ac_cpp_err"; then
c0d27fcc 15529 ac_header_preproc=yes
503d2be0
AS
15530else
15531 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15532sed 's/^/| /' conftest.$ac_ext >&5
15533
c0d27fcc 15534 ac_header_preproc=no
a21616bd 15535fi
503d2be0 15536rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15537echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15538echo "${ECHO_T}$ac_header_preproc" >&6
15539
15540# So? What about this header?
15541case $ac_header_compiler:$ac_header_preproc in
15542 yes:no )
15543 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15544echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15545 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15546echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15547 (
15548 cat <<\_ASBOX
15549## ------------------------------------ ##
15550## Report this to bug-autoconf@gnu.org. ##
15551## ------------------------------------ ##
15552_ASBOX
15553 ) |
15554 sed "s/^/$as_me: WARNING: /" >&2
15555 ;;
c0d27fcc
MR
15556 no:yes )
15557 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15558echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15559 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15560echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15561 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15562echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15563 (
15564 cat <<\_ASBOX
15565## ------------------------------------ ##
15566## Report this to bug-autoconf@gnu.org. ##
15567## ------------------------------------ ##
15568_ASBOX
15569 ) |
15570 sed "s/^/$as_me: WARNING: /" >&2
15571 ;;
c0d27fcc
MR
15572esac
15573echo "$as_me:$LINENO: checking for $ac_header" >&5
15574echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15575if eval "test \"\${$as_ac_Header+set}\" = set"; then
15576 echo $ECHO_N "(cached) $ECHO_C" >&6
15577else
15578 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15579fi
c0d27fcc 15580echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15581echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15582
15583fi
503d2be0 15584if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15585 cat >>confdefs.h <<_ACEOF
503d2be0 15586#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15587_ACEOF
a21616bd
KR
15588
15589fi
c0d27fcc 15590
a21616bd
KR
15591done
15592
98418dba 15593fi
c0d27fcc 15594
925c2f3f
EZ
15595done
15596
98418dba 15597fi
c0d27fcc 15598
925c2f3f 15599done
98418dba 15600
c0d27fcc 15601
925c2f3f
EZ
15602for ac_header in krb.h
15603do
15604as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15605if eval "test \"\${$as_ac_Header+set}\" = set"; then
15606 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
15607echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15608if eval "test \"\${$as_ac_Header+set}\" = set"; then
15609 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15610fi
15611echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15612echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15613else
15614 # Is the header compilable?
15615echo "$as_me:$LINENO: checking $ac_header usability" >&5
15616echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15617cat >conftest.$ac_ext <<_ACEOF
15618#line $LINENO "configure"
cd958eb3
MB
15619/* confdefs.h. */
15620_ACEOF
15621cat confdefs.h >>conftest.$ac_ext
15622cat >>conftest.$ac_ext <<_ACEOF
15623/* end confdefs.h. */
c0d27fcc
MR
15624$ac_includes_default
15625#include <$ac_header>
15626_ACEOF
15627rm -f conftest.$ac_objext
15628if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15629 (eval $ac_compile) 2>&5
15630 ac_status=$?
15631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15632 (exit $ac_status); } &&
15633 { ac_try='test -s conftest.$ac_objext'
15634 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15635 (eval $ac_try) 2>&5
15636 ac_status=$?
15637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15638 (exit $ac_status); }; }; then
15639 ac_header_compiler=yes
925c2f3f 15640else
c0d27fcc 15641 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15642sed 's/^/| /' conftest.$ac_ext >&5
15643
c0d27fcc
MR
15644ac_header_compiler=no
15645fi
15646rm -f conftest.$ac_objext conftest.$ac_ext
15647echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15648echo "${ECHO_T}$ac_header_compiler" >&6
15649
15650# Is the header present?
15651echo "$as_me:$LINENO: checking $ac_header presence" >&5
15652echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15653cat >conftest.$ac_ext <<_ACEOF
15654#line $LINENO "configure"
cd958eb3
MB
15655/* confdefs.h. */
15656_ACEOF
15657cat confdefs.h >>conftest.$ac_ext
15658cat >>conftest.$ac_ext <<_ACEOF
15659/* end confdefs.h. */
503d2be0
AS
15660#include <$ac_header>
15661_ACEOF
c0d27fcc 15662if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15663 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15664 ac_status=$?
6bae0ccf 15665 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15666 rm -f conftest.er1
15667 cat conftest.err >&5
c0d27fcc 15668 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15669 (exit $ac_status); } >/dev/null; then
15670 if test -s conftest.err; then
15671 ac_cpp_err=$ac_c_preproc_warn_flag
15672 else
15673 ac_cpp_err=
15674 fi
15675else
15676 ac_cpp_err=yes
15677fi
15678if test -z "$ac_cpp_err"; then
c0d27fcc 15679 ac_header_preproc=yes
503d2be0
AS
15680else
15681 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15682sed 's/^/| /' conftest.$ac_ext >&5
15683
c0d27fcc 15684 ac_header_preproc=no
a21616bd 15685fi
503d2be0 15686rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15687echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15688echo "${ECHO_T}$ac_header_preproc" >&6
15689
15690# So? What about this header?
15691case $ac_header_compiler:$ac_header_preproc in
15692 yes:no )
15693 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15694echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15695 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15696echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15697 (
15698 cat <<\_ASBOX
15699## ------------------------------------ ##
15700## Report this to bug-autoconf@gnu.org. ##
15701## ------------------------------------ ##
15702_ASBOX
15703 ) |
15704 sed "s/^/$as_me: WARNING: /" >&2
15705 ;;
c0d27fcc
MR
15706 no:yes )
15707 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15708echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15709 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15710echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15711 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15712echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15713 (
15714 cat <<\_ASBOX
15715## ------------------------------------ ##
15716## Report this to bug-autoconf@gnu.org. ##
15717## ------------------------------------ ##
15718_ASBOX
15719 ) |
15720 sed "s/^/$as_me: WARNING: /" >&2
15721 ;;
c0d27fcc
MR
15722esac
15723echo "$as_me:$LINENO: checking for $ac_header" >&5
15724echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15725if eval "test \"\${$as_ac_Header+set}\" = set"; then
15726 echo $ECHO_N "(cached) $ECHO_C" >&6
15727else
15728 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15729fi
c0d27fcc 15730echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15731echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15732
15733fi
503d2be0 15734if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15735 cat >>confdefs.h <<_ACEOF
503d2be0 15736#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15737_ACEOF
503d2be0 15738
a21616bd 15739else
503d2be0
AS
15740
15741for ac_header in kerberosIV/krb.h
a21616bd 15742do
503d2be0 15743as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15744if eval "test \"\${$as_ac_Header+set}\" = set"; then
15745 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15746echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15747if eval "test \"\${$as_ac_Header+set}\" = set"; then
15748 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15749fi
15750echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15751echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15752else
c0d27fcc
MR
15753 # Is the header compilable?
15754echo "$as_me:$LINENO: checking $ac_header usability" >&5
15755echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15756cat >conftest.$ac_ext <<_ACEOF
15757#line $LINENO "configure"
cd958eb3
MB
15758/* confdefs.h. */
15759_ACEOF
15760cat confdefs.h >>conftest.$ac_ext
15761cat >>conftest.$ac_ext <<_ACEOF
15762/* end confdefs.h. */
c0d27fcc
MR
15763$ac_includes_default
15764#include <$ac_header>
15765_ACEOF
15766rm -f conftest.$ac_objext
15767if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15768 (eval $ac_compile) 2>&5
15769 ac_status=$?
15770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15771 (exit $ac_status); } &&
15772 { ac_try='test -s conftest.$ac_objext'
15773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15774 (eval $ac_try) 2>&5
15775 ac_status=$?
15776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15777 (exit $ac_status); }; }; then
15778 ac_header_compiler=yes
15779else
15780 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15781sed 's/^/| /' conftest.$ac_ext >&5
15782
c0d27fcc
MR
15783ac_header_compiler=no
15784fi
15785rm -f conftest.$ac_objext conftest.$ac_ext
15786echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15787echo "${ECHO_T}$ac_header_compiler" >&6
15788
15789# Is the header present?
15790echo "$as_me:$LINENO: checking $ac_header presence" >&5
15791echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15792cat >conftest.$ac_ext <<_ACEOF
15793#line $LINENO "configure"
cd958eb3
MB
15794/* confdefs.h. */
15795_ACEOF
15796cat confdefs.h >>conftest.$ac_ext
15797cat >>conftest.$ac_ext <<_ACEOF
15798/* end confdefs.h. */
503d2be0
AS
15799#include <$ac_header>
15800_ACEOF
c0d27fcc 15801if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15802 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15803 ac_status=$?
6bae0ccf 15804 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15805 rm -f conftest.er1
15806 cat conftest.err >&5
c0d27fcc 15807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15808 (exit $ac_status); } >/dev/null; then
15809 if test -s conftest.err; then
15810 ac_cpp_err=$ac_c_preproc_warn_flag
15811 else
15812 ac_cpp_err=
15813 fi
15814else
15815 ac_cpp_err=yes
15816fi
15817if test -z "$ac_cpp_err"; then
c0d27fcc 15818 ac_header_preproc=yes
503d2be0
AS
15819else
15820 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15821sed 's/^/| /' conftest.$ac_ext >&5
15822
c0d27fcc 15823 ac_header_preproc=no
a21616bd 15824fi
503d2be0 15825rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15826echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15827echo "${ECHO_T}$ac_header_preproc" >&6
15828
15829# So? What about this header?
15830case $ac_header_compiler:$ac_header_preproc in
15831 yes:no )
15832 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15833echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15834 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15835echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15836 (
15837 cat <<\_ASBOX
15838## ------------------------------------ ##
15839## Report this to bug-autoconf@gnu.org. ##
15840## ------------------------------------ ##
15841_ASBOX
15842 ) |
15843 sed "s/^/$as_me: WARNING: /" >&2
15844 ;;
c0d27fcc
MR
15845 no:yes )
15846 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15847echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15848 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15849echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15850 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15851echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15852 (
15853 cat <<\_ASBOX
15854## ------------------------------------ ##
15855## Report this to bug-autoconf@gnu.org. ##
15856## ------------------------------------ ##
15857_ASBOX
15858 ) |
15859 sed "s/^/$as_me: WARNING: /" >&2
15860 ;;
c0d27fcc
MR
15861esac
15862echo "$as_me:$LINENO: checking for $ac_header" >&5
15863echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15864if eval "test \"\${$as_ac_Header+set}\" = set"; then
15865 echo $ECHO_N "(cached) $ECHO_C" >&6
15866else
15867 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15868fi
c0d27fcc 15869echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15870echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15871
15872fi
503d2be0 15873if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15874 cat >>confdefs.h <<_ACEOF
503d2be0 15875#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15876_ACEOF
503d2be0 15877
a21616bd 15878else
503d2be0
AS
15879
15880for ac_header in kerberos/krb.h
a21616bd 15881do
503d2be0 15882as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15883if eval "test \"\${$as_ac_Header+set}\" = set"; then
15884 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15885echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15886if eval "test \"\${$as_ac_Header+set}\" = set"; then
15887 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15888fi
15889echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15890echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15891else
c0d27fcc
MR
15892 # Is the header compilable?
15893echo "$as_me:$LINENO: checking $ac_header usability" >&5
15894echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15895cat >conftest.$ac_ext <<_ACEOF
15896#line $LINENO "configure"
cd958eb3
MB
15897/* confdefs.h. */
15898_ACEOF
15899cat confdefs.h >>conftest.$ac_ext
15900cat >>conftest.$ac_ext <<_ACEOF
15901/* end confdefs.h. */
c0d27fcc
MR
15902$ac_includes_default
15903#include <$ac_header>
15904_ACEOF
15905rm -f conftest.$ac_objext
15906if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15907 (eval $ac_compile) 2>&5
15908 ac_status=$?
15909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15910 (exit $ac_status); } &&
15911 { ac_try='test -s conftest.$ac_objext'
15912 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15913 (eval $ac_try) 2>&5
15914 ac_status=$?
15915 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15916 (exit $ac_status); }; }; then
15917 ac_header_compiler=yes
15918else
15919 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15920sed 's/^/| /' conftest.$ac_ext >&5
15921
c0d27fcc
MR
15922ac_header_compiler=no
15923fi
15924rm -f conftest.$ac_objext conftest.$ac_ext
15925echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15926echo "${ECHO_T}$ac_header_compiler" >&6
15927
15928# Is the header present?
15929echo "$as_me:$LINENO: checking $ac_header presence" >&5
15930echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15931cat >conftest.$ac_ext <<_ACEOF
15932#line $LINENO "configure"
cd958eb3
MB
15933/* confdefs.h. */
15934_ACEOF
15935cat confdefs.h >>conftest.$ac_ext
15936cat >>conftest.$ac_ext <<_ACEOF
15937/* end confdefs.h. */
503d2be0
AS
15938#include <$ac_header>
15939_ACEOF
c0d27fcc 15940if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15941 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15942 ac_status=$?
6bae0ccf 15943 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15944 rm -f conftest.er1
15945 cat conftest.err >&5
c0d27fcc 15946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15947 (exit $ac_status); } >/dev/null; then
15948 if test -s conftest.err; then
15949 ac_cpp_err=$ac_c_preproc_warn_flag
15950 else
15951 ac_cpp_err=
15952 fi
15953else
15954 ac_cpp_err=yes
15955fi
15956if test -z "$ac_cpp_err"; then
c0d27fcc 15957 ac_header_preproc=yes
503d2be0
AS
15958else
15959 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15960sed 's/^/| /' conftest.$ac_ext >&5
15961
c0d27fcc 15962 ac_header_preproc=no
a21616bd 15963fi
503d2be0 15964rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15965echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15966echo "${ECHO_T}$ac_header_preproc" >&6
15967
15968# So? What about this header?
15969case $ac_header_compiler:$ac_header_preproc in
15970 yes:no )
15971 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15972echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15973 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15974echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15975 (
15976 cat <<\_ASBOX
15977## ------------------------------------ ##
15978## Report this to bug-autoconf@gnu.org. ##
15979## ------------------------------------ ##
15980_ASBOX
15981 ) |
15982 sed "s/^/$as_me: WARNING: /" >&2
15983 ;;
c0d27fcc
MR
15984 no:yes )
15985 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15986echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15987 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15988echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15989 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15990echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15991 (
15992 cat <<\_ASBOX
15993## ------------------------------------ ##
15994## Report this to bug-autoconf@gnu.org. ##
15995## ------------------------------------ ##
15996_ASBOX
15997 ) |
15998 sed "s/^/$as_me: WARNING: /" >&2
15999 ;;
c0d27fcc
MR
16000esac
16001echo "$as_me:$LINENO: checking for $ac_header" >&5
16002echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16003if eval "test \"\${$as_ac_Header+set}\" = set"; then
16004 echo $ECHO_N "(cached) $ECHO_C" >&6
16005else
16006 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 16007fi
c0d27fcc 16008echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 16009echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
16010
16011fi
503d2be0 16012if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 16013 cat >>confdefs.h <<_ACEOF
503d2be0 16014#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 16015_ACEOF
503d2be0 16016
a21616bd 16017fi
c0d27fcc 16018
a21616bd
KR
16019done
16020
16021fi
c0d27fcc 16022
a21616bd
KR
16023done
16024
16025fi
c0d27fcc 16026
a21616bd
KR
16027done
16028
16029 fi
503d2be0
AS
16030
16031for ac_header in com_err.h
a21616bd 16032do
503d2be0 16033as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
16034if eval "test \"\${$as_ac_Header+set}\" = set"; then
16035 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
16036echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16037if eval "test \"\${$as_ac_Header+set}\" = set"; then
16038 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16039fi
16040echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16041echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 16042else
c0d27fcc
MR
16043 # Is the header compilable?
16044echo "$as_me:$LINENO: checking $ac_header usability" >&5
16045echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16046cat >conftest.$ac_ext <<_ACEOF
16047#line $LINENO "configure"
cd958eb3
MB
16048/* confdefs.h. */
16049_ACEOF
16050cat confdefs.h >>conftest.$ac_ext
16051cat >>conftest.$ac_ext <<_ACEOF
16052/* end confdefs.h. */
c0d27fcc
MR
16053$ac_includes_default
16054#include <$ac_header>
16055_ACEOF
16056rm -f conftest.$ac_objext
16057if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16058 (eval $ac_compile) 2>&5
16059 ac_status=$?
16060 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16061 (exit $ac_status); } &&
16062 { ac_try='test -s conftest.$ac_objext'
16063 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16064 (eval $ac_try) 2>&5
16065 ac_status=$?
16066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16067 (exit $ac_status); }; }; then
16068 ac_header_compiler=yes
16069else
16070 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16071sed 's/^/| /' conftest.$ac_ext >&5
16072
c0d27fcc
MR
16073ac_header_compiler=no
16074fi
16075rm -f conftest.$ac_objext conftest.$ac_ext
16076echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16077echo "${ECHO_T}$ac_header_compiler" >&6
16078
16079# Is the header present?
16080echo "$as_me:$LINENO: checking $ac_header presence" >&5
16081echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16082cat >conftest.$ac_ext <<_ACEOF
16083#line $LINENO "configure"
cd958eb3
MB
16084/* confdefs.h. */
16085_ACEOF
16086cat confdefs.h >>conftest.$ac_ext
16087cat >>conftest.$ac_ext <<_ACEOF
16088/* end confdefs.h. */
503d2be0
AS
16089#include <$ac_header>
16090_ACEOF
c0d27fcc 16091if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16092 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16093 ac_status=$?
6bae0ccf 16094 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16095 rm -f conftest.er1
16096 cat conftest.err >&5
c0d27fcc 16097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16098 (exit $ac_status); } >/dev/null; then
16099 if test -s conftest.err; then
16100 ac_cpp_err=$ac_c_preproc_warn_flag
16101 else
16102 ac_cpp_err=
16103 fi
16104else
16105 ac_cpp_err=yes
16106fi
16107if test -z "$ac_cpp_err"; then
c0d27fcc 16108 ac_header_preproc=yes
503d2be0
AS
16109else
16110 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16111sed 's/^/| /' conftest.$ac_ext >&5
16112
c0d27fcc 16113 ac_header_preproc=no
a21616bd 16114fi
503d2be0 16115rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16116echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16117echo "${ECHO_T}$ac_header_preproc" >&6
16118
16119# So? What about this header?
16120case $ac_header_compiler:$ac_header_preproc in
16121 yes:no )
16122 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16123echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16124 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16125echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16126 (
16127 cat <<\_ASBOX
16128## ------------------------------------ ##
16129## Report this to bug-autoconf@gnu.org. ##
16130## ------------------------------------ ##
16131_ASBOX
16132 ) |
16133 sed "s/^/$as_me: WARNING: /" >&2
16134 ;;
c0d27fcc
MR
16135 no:yes )
16136 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16137echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16138 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16139echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16140 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16141echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16142 (
16143 cat <<\_ASBOX
16144## ------------------------------------ ##
16145## Report this to bug-autoconf@gnu.org. ##
16146## ------------------------------------ ##
16147_ASBOX
16148 ) |
16149 sed "s/^/$as_me: WARNING: /" >&2
16150 ;;
c0d27fcc
MR
16151esac
16152echo "$as_me:$LINENO: checking for $ac_header" >&5
16153echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16154if eval "test \"\${$as_ac_Header+set}\" = set"; then
16155 echo $ECHO_N "(cached) $ECHO_C" >&6
16156else
16157 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 16158fi
c0d27fcc 16159echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 16160echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
16161
16162fi
503d2be0 16163if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 16164 cat >>confdefs.h <<_ACEOF
503d2be0 16165#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 16166_ACEOF
503d2be0 16167
a21616bd 16168fi
c0d27fcc 16169
a21616bd
KR
16170done
16171
16172fi
16173
ba4481b5
DL
16174# Solaris requires -lintl if you want strerror (which calls dgettext)
16175# to return localized messages.
503d2be0 16176
c0d27fcc 16177echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
16178echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
16179if test "${ac_cv_lib_intl_dgettext+set}" = set; then
16180 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16181else
503d2be0 16182 ac_check_lib_save_LIBS=$LIBS
ba4481b5 16183LIBS="-lintl $LIBS"
503d2be0 16184cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16185#line $LINENO "configure"
cd958eb3
MB
16186/* confdefs.h. */
16187_ACEOF
16188cat confdefs.h >>conftest.$ac_ext
16189cat >>conftest.$ac_ext <<_ACEOF
16190/* end confdefs.h. */
503d2be0 16191
ba4481b5 16192/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16193#ifdef __cplusplus
16194extern "C"
16195#endif
ba4481b5 16196/* We use char because int might match the return type of a gcc2
503d2be0
AS
16197 builtin and then its argument prototype would still apply. */
16198char dgettext ();
16199int
16200main ()
16201{
16202dgettext ();
16203 ;
16204 return 0;
16205}
16206_ACEOF
16207rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16208if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16209 (eval $ac_link) 2>&5
16210 ac_status=$?
c0d27fcc 16211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16212 (exit $ac_status); } &&
16213 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16215 (eval $ac_try) 2>&5
16216 ac_status=$?
c0d27fcc 16217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16218 (exit $ac_status); }; }; then
16219 ac_cv_lib_intl_dgettext=yes
16220else
16221 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16222sed 's/^/| /' conftest.$ac_ext >&5
16223
503d2be0
AS
16224ac_cv_lib_intl_dgettext=no
16225fi
16226rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16227LIBS=$ac_check_lib_save_LIBS
16228fi
c0d27fcc 16229echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
16230echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
16231if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 16232 cat >>confdefs.h <<_ACEOF
503d2be0 16233#define HAVE_LIBINTL 1
c0d27fcc 16234_ACEOF
ba4481b5
DL
16235
16236 LIBS="-lintl $LIBS"
16237
ba4481b5
DL
16238fi
16239
c0d27fcc
MR
16240
16241echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
16242echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
16243if test "${emacs_cv_localtime_cache+set}" = set; then
16244 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
16245else
16246 if test x$ac_cv_func_tzset = xyes; then
16247if test "$cross_compiling" = yes; then
16248 # If we have tzset, assume the worst when cross-compiling.
16249emacs_cv_localtime_cache=yes
16250else
503d2be0 16251 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16252#line $LINENO "configure"
cd958eb3
MB
16253/* confdefs.h. */
16254_ACEOF
16255cat confdefs.h >>conftest.$ac_ext
16256cat >>conftest.$ac_ext <<_ACEOF
16257/* end confdefs.h. */
ba4481b5 16258#include <time.h>
ba4481b5
DL
16259extern char **environ;
16260unset_TZ ()
16261{
16262 char **from, **to;
16263 for (to = from = environ; (*to = *from); from++)
16264 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
16265 to++;
16266}
16267char TZ_GMT0[] = "TZ=GMT0";
16268char TZ_PST8[] = "TZ=PST8";
16269main()
16270{
16271 time_t now = time ((time_t *) 0);
16272 int hour_GMT0, hour_unset;
16273 if (putenv (TZ_GMT0) != 0)
16274 exit (1);
16275 hour_GMT0 = localtime (&now)->tm_hour;
16276 unset_TZ ();
16277 hour_unset = localtime (&now)->tm_hour;
16278 if (putenv (TZ_PST8) != 0)
16279 exit (1);
16280 if (localtime (&now)->tm_hour == hour_GMT0)
16281 exit (1);
16282 unset_TZ ();
16283 if (localtime (&now)->tm_hour != hour_unset)
16284 exit (1);
16285 exit (0);
16286}
503d2be0
AS
16287_ACEOF
16288rm -f conftest$ac_exeext
c0d27fcc 16289if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16290 (eval $ac_link) 2>&5
16291 ac_status=$?
c0d27fcc 16292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16293 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 16294 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16295 (eval $ac_try) 2>&5
16296 ac_status=$?
c0d27fcc 16297 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16298 (exit $ac_status); }; }; then
ba4481b5
DL
16299 emacs_cv_localtime_cache=no
16300else
503d2be0
AS
16301 echo "$as_me: program exited with status $ac_status" >&5
16302echo "$as_me: failed program was:" >&5
cd958eb3
MB
16303sed 's/^/| /' conftest.$ac_ext >&5
16304
c0d27fcc 16305( exit $ac_status )
503d2be0 16306emacs_cv_localtime_cache=yes
ba4481b5 16307fi
6bae0ccf 16308rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 16309fi
ba4481b5
DL
16310else
16311 # If we lack tzset, report that localtime does not cache TZ,
16312 # since we can't invalidate the cache if we don't have tzset.
16313 emacs_cv_localtime_cache=no
16314fi
16315fi
c0d27fcc 16316echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 16317echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 16318if test $emacs_cv_localtime_cache = yes; then
b936fae4 16319
c0d27fcc 16320cat >>confdefs.h <<\_ACEOF
ba4481b5 16321#define LOCALTIME_CACHE 1
c0d27fcc 16322_ACEOF
ba4481b5
DL
16323
16324fi
16325
16326if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
16327
16328for ac_func in gettimeofday
48d4b120 16329do
503d2be0 16330as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16331echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
16332echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16333if eval "test \"\${$as_ac_var+set}\" = set"; then
16334 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 16335else
503d2be0 16336 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16337#line $LINENO "configure"
cd958eb3
MB
16338/* confdefs.h. */
16339_ACEOF
16340cat confdefs.h >>conftest.$ac_ext
16341cat >>conftest.$ac_ext <<_ACEOF
16342/* end confdefs.h. */
48d4b120 16343/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
16344 which can conflict with char $ac_func (); below.
16345 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16346 <limits.h> exists even on freestanding compilers. */
16347#ifdef __STDC__
16348# include <limits.h>
16349#else
16350# include <assert.h>
16351#endif
48d4b120 16352/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16353#ifdef __cplusplus
16354extern "C"
cd958eb3 16355{
503d2be0 16356#endif
48d4b120 16357/* We use char because int might match the return type of a gcc2
503d2be0
AS
16358 builtin and then its argument prototype would still apply. */
16359char $ac_func ();
48d4b120
DL
16360/* The GNU C library defines this for functions which it implements
16361 to always fail with ENOSYS. Some functions are actually named
16362 something starting with __ and the normal name is an alias. */
16363#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16364choke me
16365#else
cd958eb3 16366char (*f) () = $ac_func;
48d4b120 16367#endif
cd958eb3
MB
16368#ifdef __cplusplus
16369}
16370#endif
16371
16372int
16373main ()
16374{
9e71690e 16375return f != $ac_func;
503d2be0
AS
16376 ;
16377 return 0;
16378}
16379_ACEOF
16380rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16381if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16382 (eval $ac_link) 2>&5
16383 ac_status=$?
c0d27fcc 16384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16385 (exit $ac_status); } &&
16386 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16387 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16388 (eval $ac_try) 2>&5
16389 ac_status=$?
c0d27fcc 16390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16391 (exit $ac_status); }; }; then
16392 eval "$as_ac_var=yes"
16393else
16394 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16395sed 's/^/| /' conftest.$ac_ext >&5
16396
503d2be0
AS
16397eval "$as_ac_var=no"
16398fi
16399rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16400fi
c0d27fcc 16401echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16402echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16403if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16404 cat >>confdefs.h <<_ACEOF
503d2be0 16405#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16406_ACEOF
48d4b120 16407
48d4b120
DL
16408fi
16409done
16410
b936fae4 16411 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 16412 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
16413echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
16414if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
16415 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16416else
503d2be0 16417 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16418#line $LINENO "configure"
cd958eb3
MB
16419/* confdefs.h. */
16420_ACEOF
16421cat confdefs.h >>conftest.$ac_ext
16422cat >>conftest.$ac_ext <<_ACEOF
16423/* end confdefs.h. */
ba4481b5 16424
a3f08d9e
DL
16425#ifdef TIME_WITH_SYS_TIME
16426#include <sys/time.h>
16427#include <time.h>
16428#else
16429#ifdef HAVE_SYS_TIME_H
16430#include <sys/time.h>
16431#else
16432#include <time.h>
16433#endif
16434#endif
503d2be0
AS
16435int
16436main ()
16437{
a3f08d9e 16438struct timeval time;
b936fae4 16439 gettimeofday (&time, 0);
503d2be0
AS
16440 ;
16441 return 0;
16442}
16443_ACEOF
16444rm -f conftest.$ac_objext
c0d27fcc 16445if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16446 (eval $ac_compile) 2>&5
16447 ac_status=$?
c0d27fcc 16448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16449 (exit $ac_status); } &&
16450 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16451 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16452 (eval $ac_try) 2>&5
16453 ac_status=$?
c0d27fcc 16454 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16455 (exit $ac_status); }; }; then
ba4481b5
DL
16456 emacs_cv_gettimeofday_two_arguments=yes
16457else
503d2be0 16458 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16459sed 's/^/| /' conftest.$ac_ext >&5
16460
503d2be0 16461emacs_cv_gettimeofday_two_arguments=no
ba4481b5 16462fi
503d2be0 16463rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 16464fi
c0d27fcc 16465echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 16466echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
16467 if test $emacs_cv_gettimeofday_two_arguments = no; then
16468
c0d27fcc 16469cat >>confdefs.h <<\_ACEOF
ba4481b5 16470#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 16471_ACEOF
ba4481b5 16472
b936fae4 16473 fi
ba4481b5
DL
16474 fi
16475fi
16476
48d4b120 16477if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 16478 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
16479echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
16480if test "${emacs_cv_struct_timezone+set}" = set; then
16481 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 16482else
503d2be0 16483 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16484#line $LINENO "configure"
cd958eb3
MB
16485/* confdefs.h. */
16486_ACEOF
16487cat confdefs.h >>conftest.$ac_ext
16488cat >>conftest.$ac_ext <<_ACEOF
16489/* end confdefs.h. */
48d4b120 16490#include <sys/time.h>
503d2be0
AS
16491int
16492main ()
16493{
48d4b120 16494struct timezone tz;
503d2be0
AS
16495 ;
16496 return 0;
16497}
16498_ACEOF
16499rm -f conftest.$ac_objext
c0d27fcc 16500if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16501 (eval $ac_compile) 2>&5
16502 ac_status=$?
c0d27fcc 16503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16504 (exit $ac_status); } &&
16505 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16507 (eval $ac_try) 2>&5
16508 ac_status=$?
c0d27fcc 16509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16510 (exit $ac_status); }; }; then
48d4b120
DL
16511 if test "$cross_compiling" = yes; then
16512 emacs_cv_struct_timezone=yes
16513else
503d2be0 16514 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16515#line $LINENO "configure"
cd958eb3
MB
16516/* confdefs.h. */
16517_ACEOF
16518cat confdefs.h >>conftest.$ac_ext
16519cat >>conftest.$ac_ext <<_ACEOF
16520/* end confdefs.h. */
48d4b120
DL
16521
16522#ifdef TIME_WITH_SYS_TIME
16523#include <sys/time.h>
16524#include <time.h>
16525#else
16526#ifdef HAVE_SYS_TIME_H
16527#include <sys/time.h>
16528#else
16529#include <time.h>
16530#endif
16531#endif
16532main () {
16533 struct timeval time;
16534 struct timezone dummy;
16535 exit (gettimeofday (&time, &dummy));
16536}
503d2be0
AS
16537_ACEOF
16538rm -f conftest$ac_exeext
c0d27fcc 16539if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16540 (eval $ac_link) 2>&5
16541 ac_status=$?
c0d27fcc 16542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16543 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 16544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16545 (eval $ac_try) 2>&5
16546 ac_status=$?
c0d27fcc 16547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16548 (exit $ac_status); }; }; then
48d4b120
DL
16549 emacs_cv_struct_timezone=yes
16550else
503d2be0
AS
16551 echo "$as_me: program exited with status $ac_status" >&5
16552echo "$as_me: failed program was:" >&5
cd958eb3
MB
16553sed 's/^/| /' conftest.$ac_ext >&5
16554
c0d27fcc 16555( exit $ac_status )
503d2be0 16556emacs_cv_struct_timezone=no
48d4b120 16557fi
6bae0ccf 16558rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 16559fi
48d4b120 16560else
503d2be0 16561 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16562sed 's/^/| /' conftest.$ac_ext >&5
16563
503d2be0 16564emacs_cv_struct_timezone=no
48d4b120 16565fi
503d2be0 16566rm -f conftest.$ac_objext conftest.$ac_ext
48d4b120 16567fi
c0d27fcc 16568echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 16569echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
16570fi
16571
ba4481b5 16572ok_so_far=yes
c0d27fcc 16573echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
16574echo $ECHO_N "checking for socket... $ECHO_C" >&6
16575if test "${ac_cv_func_socket+set}" = set; then
16576 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16577else
503d2be0 16578 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16579#line $LINENO "configure"
cd958eb3
MB
16580/* confdefs.h. */
16581_ACEOF
16582cat confdefs.h >>conftest.$ac_ext
16583cat >>conftest.$ac_ext <<_ACEOF
16584/* end confdefs.h. */
ba4481b5 16585/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
16586 which can conflict with char socket (); below.
16587 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16588 <limits.h> exists even on freestanding compilers. */
16589#ifdef __STDC__
16590# include <limits.h>
16591#else
16592# include <assert.h>
16593#endif
ba4481b5 16594/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16595#ifdef __cplusplus
16596extern "C"
cd958eb3 16597{
503d2be0 16598#endif
ba4481b5 16599/* We use char because int might match the return type of a gcc2
503d2be0
AS
16600 builtin and then its argument prototype would still apply. */
16601char socket ();
ba4481b5
DL
16602/* The GNU C library defines this for functions which it implements
16603 to always fail with ENOSYS. Some functions are actually named
16604 something starting with __ and the normal name is an alias. */
16605#if defined (__stub_socket) || defined (__stub___socket)
16606choke me
16607#else
cd958eb3 16608char (*f) () = socket;
ba4481b5 16609#endif
cd958eb3
MB
16610#ifdef __cplusplus
16611}
16612#endif
16613
16614int
16615main ()
16616{
9e71690e 16617return f != socket;
503d2be0
AS
16618 ;
16619 return 0;
16620}
16621_ACEOF
16622rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16623if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16624 (eval $ac_link) 2>&5
16625 ac_status=$?
c0d27fcc 16626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16627 (exit $ac_status); } &&
16628 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16630 (eval $ac_try) 2>&5
16631 ac_status=$?
c0d27fcc 16632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16633 (exit $ac_status); }; }; then
16634 ac_cv_func_socket=yes
16635else
16636 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16637sed 's/^/| /' conftest.$ac_ext >&5
16638
503d2be0
AS
16639ac_cv_func_socket=no
16640fi
16641rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16642fi
c0d27fcc 16643echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
16644echo "${ECHO_T}$ac_cv_func_socket" >&6
16645if test $ac_cv_func_socket = yes; then
ba4481b5
DL
16646 :
16647else
503d2be0 16648 ok_so_far=no
ba4481b5
DL
16649fi
16650
16651if test $ok_so_far = yes; then
c0d27fcc
MR
16652 if test "${ac_cv_header_netinet_in_h+set}" = set; then
16653 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
16654echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
16655if test "${ac_cv_header_netinet_in_h+set}" = set; then
16656 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16657fi
16658echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
16659echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 16660else
c0d27fcc
MR
16661 # Is the header compilable?
16662echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
16663echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
16664cat >conftest.$ac_ext <<_ACEOF
16665#line $LINENO "configure"
cd958eb3
MB
16666/* confdefs.h. */
16667_ACEOF
16668cat confdefs.h >>conftest.$ac_ext
16669cat >>conftest.$ac_ext <<_ACEOF
16670/* end confdefs.h. */
c0d27fcc
MR
16671$ac_includes_default
16672#include <netinet/in.h>
16673_ACEOF
16674rm -f conftest.$ac_objext
16675if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16676 (eval $ac_compile) 2>&5
16677 ac_status=$?
16678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16679 (exit $ac_status); } &&
16680 { ac_try='test -s conftest.$ac_objext'
16681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16682 (eval $ac_try) 2>&5
16683 ac_status=$?
16684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16685 (exit $ac_status); }; }; then
16686 ac_header_compiler=yes
16687else
16688 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16689sed 's/^/| /' conftest.$ac_ext >&5
16690
c0d27fcc
MR
16691ac_header_compiler=no
16692fi
16693rm -f conftest.$ac_objext conftest.$ac_ext
16694echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16695echo "${ECHO_T}$ac_header_compiler" >&6
16696
16697# Is the header present?
16698echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
16699echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
16700cat >conftest.$ac_ext <<_ACEOF
16701#line $LINENO "configure"
cd958eb3
MB
16702/* confdefs.h. */
16703_ACEOF
16704cat confdefs.h >>conftest.$ac_ext
16705cat >>conftest.$ac_ext <<_ACEOF
16706/* end confdefs.h. */
ba4481b5 16707#include <netinet/in.h>
503d2be0 16708_ACEOF
c0d27fcc 16709if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16710 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16711 ac_status=$?
6bae0ccf 16712 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16713 rm -f conftest.er1
16714 cat conftest.err >&5
c0d27fcc 16715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16716 (exit $ac_status); } >/dev/null; then
16717 if test -s conftest.err; then
16718 ac_cpp_err=$ac_c_preproc_warn_flag
16719 else
16720 ac_cpp_err=
16721 fi
16722else
16723 ac_cpp_err=yes
16724fi
16725if test -z "$ac_cpp_err"; then
c0d27fcc 16726 ac_header_preproc=yes
ba4481b5 16727else
503d2be0 16728 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16729sed 's/^/| /' conftest.$ac_ext >&5
16730
c0d27fcc 16731 ac_header_preproc=no
ba4481b5 16732fi
503d2be0 16733rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16734echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16735echo "${ECHO_T}$ac_header_preproc" >&6
16736
16737# So? What about this header?
16738case $ac_header_compiler:$ac_header_preproc in
16739 yes:no )
16740 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
16741echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16742 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16743echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
16744 (
16745 cat <<\_ASBOX
16746## ------------------------------------ ##
16747## Report this to bug-autoconf@gnu.org. ##
16748## ------------------------------------ ##
16749_ASBOX
16750 ) |
16751 sed "s/^/$as_me: WARNING: /" >&2
16752 ;;
c0d27fcc
MR
16753 no:yes )
16754 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
16755echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
16756 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
16757echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
16758 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16759echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
16760 (
16761 cat <<\_ASBOX
16762## ------------------------------------ ##
16763## Report this to bug-autoconf@gnu.org. ##
16764## ------------------------------------ ##
16765_ASBOX
16766 ) |
16767 sed "s/^/$as_me: WARNING: /" >&2
16768 ;;
c0d27fcc
MR
16769esac
16770echo "$as_me:$LINENO: checking for netinet/in.h" >&5
16771echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
16772if test "${ac_cv_header_netinet_in_h+set}" = set; then
16773 echo $ECHO_N "(cached) $ECHO_C" >&6
16774else
16775 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 16776fi
c0d27fcc 16777echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 16778echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
16779
16780fi
503d2be0 16781if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
16782 :
16783else
503d2be0 16784 ok_so_far=no
ba4481b5
DL
16785fi
16786
c0d27fcc 16787
ba4481b5
DL
16788fi
16789if test $ok_so_far = yes; then
c0d27fcc
MR
16790 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16791 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
16792echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
16793if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16794 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16795fi
16796echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
16797echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 16798else
c0d27fcc
MR
16799 # Is the header compilable?
16800echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
16801echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
16802cat >conftest.$ac_ext <<_ACEOF
16803#line $LINENO "configure"
cd958eb3
MB
16804/* confdefs.h. */
16805_ACEOF
16806cat confdefs.h >>conftest.$ac_ext
16807cat >>conftest.$ac_ext <<_ACEOF
16808/* end confdefs.h. */
c0d27fcc
MR
16809$ac_includes_default
16810#include <arpa/inet.h>
16811_ACEOF
16812rm -f conftest.$ac_objext
16813if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16814 (eval $ac_compile) 2>&5
16815 ac_status=$?
16816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16817 (exit $ac_status); } &&
16818 { ac_try='test -s conftest.$ac_objext'
16819 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16820 (eval $ac_try) 2>&5
16821 ac_status=$?
16822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16823 (exit $ac_status); }; }; then
16824 ac_header_compiler=yes
16825else
16826 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16827sed 's/^/| /' conftest.$ac_ext >&5
16828
c0d27fcc
MR
16829ac_header_compiler=no
16830fi
16831rm -f conftest.$ac_objext conftest.$ac_ext
16832echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16833echo "${ECHO_T}$ac_header_compiler" >&6
16834
16835# Is the header present?
16836echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
16837echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
16838cat >conftest.$ac_ext <<_ACEOF
16839#line $LINENO "configure"
cd958eb3
MB
16840/* confdefs.h. */
16841_ACEOF
16842cat confdefs.h >>conftest.$ac_ext
16843cat >>conftest.$ac_ext <<_ACEOF
16844/* end confdefs.h. */
ba4481b5 16845#include <arpa/inet.h>
503d2be0 16846_ACEOF
c0d27fcc 16847if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16848 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16849 ac_status=$?
6bae0ccf 16850 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16851 rm -f conftest.er1
16852 cat conftest.err >&5
c0d27fcc 16853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16854 (exit $ac_status); } >/dev/null; then
16855 if test -s conftest.err; then
16856 ac_cpp_err=$ac_c_preproc_warn_flag
16857 else
16858 ac_cpp_err=
16859 fi
16860else
16861 ac_cpp_err=yes
16862fi
16863if test -z "$ac_cpp_err"; then
c0d27fcc 16864 ac_header_preproc=yes
ba4481b5 16865else
503d2be0 16866 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16867sed 's/^/| /' conftest.$ac_ext >&5
16868
c0d27fcc 16869 ac_header_preproc=no
ba4481b5 16870fi
503d2be0 16871rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16872echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16873echo "${ECHO_T}$ac_header_preproc" >&6
16874
16875# So? What about this header?
16876case $ac_header_compiler:$ac_header_preproc in
16877 yes:no )
16878 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
16879echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16880 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16881echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
16882 (
16883 cat <<\_ASBOX
16884## ------------------------------------ ##
16885## Report this to bug-autoconf@gnu.org. ##
16886## ------------------------------------ ##
16887_ASBOX
16888 ) |
16889 sed "s/^/$as_me: WARNING: /" >&2
16890 ;;
c0d27fcc
MR
16891 no:yes )
16892 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
16893echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
16894 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
16895echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
16896 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16897echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
16898 (
16899 cat <<\_ASBOX
16900## ------------------------------------ ##
16901## Report this to bug-autoconf@gnu.org. ##
16902## ------------------------------------ ##
16903_ASBOX
16904 ) |
16905 sed "s/^/$as_me: WARNING: /" >&2
16906 ;;
c0d27fcc
MR
16907esac
16908echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
16909echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
16910if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16911 echo $ECHO_N "(cached) $ECHO_C" >&6
16912else
16913 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 16914fi
c0d27fcc 16915echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 16916echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
16917
16918fi
503d2be0 16919if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
16920 :
16921else
503d2be0 16922 ok_so_far=no
ba4481b5
DL
16923fi
16924
c0d27fcc 16925
ba4481b5
DL
16926fi
16927if test $ok_so_far = yes; then
b936fae4 16928
c0d27fcc 16929cat >>confdefs.h <<\_ACEOF
ba4481b5 16930#define HAVE_INET_SOCKETS 1
c0d27fcc 16931_ACEOF
ba4481b5
DL
16932
16933fi
16934
16935if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 16936
c0d27fcc 16937cat >>confdefs.h <<\_ACEOF
ba4481b5 16938#define HAVE_AIX_SMT_EXP 1
c0d27fcc 16939_ACEOF
ba4481b5
DL
16940
16941fi
16942
c0d27fcc 16943echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 16944echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 16945if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 16946 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 16947echo "${ECHO_T}yes" >&6
b936fae4 16948
c0d27fcc 16949cat >>confdefs.h <<\_ACEOF
3d9fec71 16950#define HAVE_DEV_PTMX 1
c0d27fcc 16951_ACEOF
3d9fec71
DL
16952
16953else
c0d27fcc 16954 echo "$as_me:$LINENO: result: no" >&5
503d2be0 16955echo "${ECHO_T}no" >&6
3d9fec71
DL
16956fi
16957
c0d27fcc 16958echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
16959echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
16960if test "${ac_cv_type_pid_t+set}" = set; then
16961 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 16962else
503d2be0 16963 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16964#line $LINENO "configure"
cd958eb3
MB
16965/* confdefs.h. */
16966_ACEOF
16967cat confdefs.h >>conftest.$ac_ext
16968cat >>conftest.$ac_ext <<_ACEOF
16969/* end confdefs.h. */
503d2be0
AS
16970$ac_includes_default
16971int
16972main ()
16973{
16974if ((pid_t *) 0)
16975 return 0;
16976if (sizeof (pid_t))
16977 return 0;
16978 ;
16979 return 0;
16980}
16981_ACEOF
16982rm -f conftest.$ac_objext
c0d27fcc 16983if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16984 (eval $ac_compile) 2>&5
16985 ac_status=$?
c0d27fcc 16986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16987 (exit $ac_status); } &&
16988 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16990 (eval $ac_try) 2>&5
16991 ac_status=$?
c0d27fcc 16992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16993 (exit $ac_status); }; }; then
647847ea
DL
16994 ac_cv_type_pid_t=yes
16995else
503d2be0 16996 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16997sed 's/^/| /' conftest.$ac_ext >&5
16998
503d2be0 16999ac_cv_type_pid_t=no
647847ea 17000fi
503d2be0 17001rm -f conftest.$ac_objext conftest.$ac_ext
647847ea 17002fi
c0d27fcc 17003echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
17004echo "${ECHO_T}$ac_cv_type_pid_t" >&6
17005if test $ac_cv_type_pid_t = yes; then
17006 :
17007else
17008
c0d27fcc 17009cat >>confdefs.h <<_ACEOF
647847ea 17010#define pid_t int
c0d27fcc 17011_ACEOF
647847ea
DL
17012
17013fi
17014
c0d27fcc
MR
17015
17016
503d2be0
AS
17017for ac_header in unistd.h vfork.h
17018do
17019as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17020if eval "test \"\${$as_ac_Header+set}\" = set"; then
17021 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17022echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17023if eval "test \"\${$as_ac_Header+set}\" = set"; then
17024 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17025fi
17026echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17027echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17028else
c0d27fcc
MR
17029 # Is the header compilable?
17030echo "$as_me:$LINENO: checking $ac_header usability" >&5
17031echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17032cat >conftest.$ac_ext <<_ACEOF
17033#line $LINENO "configure"
cd958eb3
MB
17034/* confdefs.h. */
17035_ACEOF
17036cat confdefs.h >>conftest.$ac_ext
17037cat >>conftest.$ac_ext <<_ACEOF
17038/* end confdefs.h. */
c0d27fcc
MR
17039$ac_includes_default
17040#include <$ac_header>
17041_ACEOF
17042rm -f conftest.$ac_objext
17043if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17044 (eval $ac_compile) 2>&5
17045 ac_status=$?
17046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17047 (exit $ac_status); } &&
17048 { ac_try='test -s conftest.$ac_objext'
17049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17050 (eval $ac_try) 2>&5
17051 ac_status=$?
17052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17053 (exit $ac_status); }; }; then
17054 ac_header_compiler=yes
17055else
17056 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17057sed 's/^/| /' conftest.$ac_ext >&5
17058
c0d27fcc
MR
17059ac_header_compiler=no
17060fi
17061rm -f conftest.$ac_objext conftest.$ac_ext
17062echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17063echo "${ECHO_T}$ac_header_compiler" >&6
17064
17065# Is the header present?
17066echo "$as_me:$LINENO: checking $ac_header presence" >&5
17067echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17068cat >conftest.$ac_ext <<_ACEOF
17069#line $LINENO "configure"
cd958eb3
MB
17070/* confdefs.h. */
17071_ACEOF
17072cat confdefs.h >>conftest.$ac_ext
17073cat >>conftest.$ac_ext <<_ACEOF
17074/* end confdefs.h. */
503d2be0
AS
17075#include <$ac_header>
17076_ACEOF
c0d27fcc 17077if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17078 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17079 ac_status=$?
6bae0ccf 17080 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17081 rm -f conftest.er1
17082 cat conftest.err >&5
c0d27fcc 17083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17084 (exit $ac_status); } >/dev/null; then
17085 if test -s conftest.err; then
17086 ac_cpp_err=$ac_c_preproc_warn_flag
17087 else
17088 ac_cpp_err=
17089 fi
647847ea 17090else
503d2be0
AS
17091 ac_cpp_err=yes
17092fi
17093if test -z "$ac_cpp_err"; then
c0d27fcc 17094 ac_header_preproc=yes
647847ea 17095else
503d2be0 17096 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17097sed 's/^/| /' conftest.$ac_ext >&5
17098
c0d27fcc 17099 ac_header_preproc=no
647847ea 17100fi
503d2be0 17101rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17102echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17103echo "${ECHO_T}$ac_header_preproc" >&6
17104
17105# So? What about this header?
17106case $ac_header_compiler:$ac_header_preproc in
17107 yes:no )
17108 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17109echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17110 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17111echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17112 (
17113 cat <<\_ASBOX
17114## ------------------------------------ ##
17115## Report this to bug-autoconf@gnu.org. ##
17116## ------------------------------------ ##
17117_ASBOX
17118 ) |
17119 sed "s/^/$as_me: WARNING: /" >&2
17120 ;;
c0d27fcc
MR
17121 no:yes )
17122 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17123echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17124 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17125echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17126 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17127echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17128 (
17129 cat <<\_ASBOX
17130## ------------------------------------ ##
17131## Report this to bug-autoconf@gnu.org. ##
17132## ------------------------------------ ##
17133_ASBOX
17134 ) |
17135 sed "s/^/$as_me: WARNING: /" >&2
17136 ;;
c0d27fcc
MR
17137esac
17138echo "$as_me:$LINENO: checking for $ac_header" >&5
17139echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17140if eval "test \"\${$as_ac_Header+set}\" = set"; then
17141 echo $ECHO_N "(cached) $ECHO_C" >&6
17142else
17143 eval "$as_ac_Header=$ac_header_preproc"
647847ea 17144fi
c0d27fcc 17145echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17146echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17147
17148fi
503d2be0 17149if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17150 cat >>confdefs.h <<_ACEOF
503d2be0 17151#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17152_ACEOF
647847ea 17153
73b77ee5 17154fi
c0d27fcc 17155
503d2be0 17156done
73b77ee5 17157
c0d27fcc
MR
17158
17159
503d2be0
AS
17160for ac_func in fork vfork
17161do
17162as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 17163echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
17164echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17165if eval "test \"\${$as_ac_var+set}\" = set"; then
17166 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 17167else
503d2be0 17168 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17169#line $LINENO "configure"
cd958eb3
MB
17170/* confdefs.h. */
17171_ACEOF
17172cat confdefs.h >>conftest.$ac_ext
17173cat >>conftest.$ac_ext <<_ACEOF
17174/* end confdefs.h. */
fa0b693c 17175/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
17176 which can conflict with char $ac_func (); below.
17177 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17178 <limits.h> exists even on freestanding compilers. */
17179#ifdef __STDC__
17180# include <limits.h>
17181#else
17182# include <assert.h>
17183#endif
fa0b693c 17184/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17185#ifdef __cplusplus
17186extern "C"
cd958eb3 17187{
503d2be0 17188#endif
fa0b693c 17189/* We use char because int might match the return type of a gcc2
503d2be0
AS
17190 builtin and then its argument prototype would still apply. */
17191char $ac_func ();
fa0b693c
GM
17192/* The GNU C library defines this for functions which it implements
17193 to always fail with ENOSYS. Some functions are actually named
17194 something starting with __ and the normal name is an alias. */
503d2be0 17195#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
17196choke me
17197#else
cd958eb3
MB
17198char (*f) () = $ac_func;
17199#endif
17200#ifdef __cplusplus
17201}
fa0b693c
GM
17202#endif
17203
cd958eb3
MB
17204int
17205main ()
17206{
9e71690e 17207return f != $ac_func;
503d2be0
AS
17208 ;
17209 return 0;
17210}
17211_ACEOF
17212rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17213if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17214 (eval $ac_link) 2>&5
17215 ac_status=$?
c0d27fcc 17216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17217 (exit $ac_status); } &&
17218 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17219 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17220 (eval $ac_try) 2>&5
17221 ac_status=$?
c0d27fcc 17222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17223 (exit $ac_status); }; }; then
17224 eval "$as_ac_var=yes"
17225else
17226 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17227sed 's/^/| /' conftest.$ac_ext >&5
17228
503d2be0
AS
17229eval "$as_ac_var=no"
17230fi
17231rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17232fi
c0d27fcc 17233echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
17234echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17235if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 17236 cat >>confdefs.h <<_ACEOF
503d2be0 17237#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 17238_ACEOF
503d2be0 17239
fa0b693c 17240fi
503d2be0 17241done
fa0b693c 17242
503d2be0 17243if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 17244 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
17245echo $ECHO_N "checking for working fork... $ECHO_C" >&6
17246if test "${ac_cv_func_fork_works+set}" = set; then
17247 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 17248else
503d2be0
AS
17249 if test "$cross_compiling" = yes; then
17250 ac_cv_func_fork_works=cross
17251else
17252 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17253/* By Ruediger Kuhlmann. */
503d2be0
AS
17254 #include <sys/types.h>
17255 #if HAVE_UNISTD_H
17256 # include <unistd.h>
17257 #endif
17258 /* Some systems only have a dummy stub for fork() */
17259 int main ()
17260 {
17261 if (fork() < 0)
17262 exit (1);
17263 exit (0);
17264 }
17265_ACEOF
17266rm -f conftest$ac_exeext
c0d27fcc 17267if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17268 (eval $ac_link) 2>&5
17269 ac_status=$?
c0d27fcc 17270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17271 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 17272 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17273 (eval $ac_try) 2>&5
17274 ac_status=$?
c0d27fcc 17275 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17276 (exit $ac_status); }; }; then
17277 ac_cv_func_fork_works=yes
17278else
17279 echo "$as_me: program exited with status $ac_status" >&5
17280echo "$as_me: failed program was:" >&5
cd958eb3
MB
17281sed 's/^/| /' conftest.$ac_ext >&5
17282
c0d27fcc 17283( exit $ac_status )
503d2be0
AS
17284ac_cv_func_fork_works=no
17285fi
6bae0ccf 17286rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
17287fi
17288fi
c0d27fcc 17289echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
17290echo "${ECHO_T}$ac_cv_func_fork_works" >&6
17291
6bae0ccf
DL
17292else
17293 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
17294fi
17295if test "x$ac_cv_func_fork_works" = xcross; then
17296 case $host in
17297 *-*-amigaos* | *-*-msdosdjgpp*)
17298 # Override, as these systems have only a dummy fork() stub
17299 ac_cv_func_fork_works=no
17300 ;;
17301 *)
17302 ac_cv_func_fork_works=yes
17303 ;;
17304 esac
c0d27fcc
MR
17305 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
17306echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 17307fi
73b77ee5 17308ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 17309if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 17310 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
17311echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
17312if test "${ac_cv_func_vfork_works+set}" = set; then
17313 echo $ECHO_N "(cached) $ECHO_C" >&6
17314else
17315 if test "$cross_compiling" = yes; then
17316 ac_cv_func_vfork_works=cross
fa0b693c 17317else
503d2be0 17318 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17319#line $LINENO "configure"
cd958eb3
MB
17320/* confdefs.h. */
17321_ACEOF
17322cat confdefs.h >>conftest.$ac_ext
17323cat >>conftest.$ac_ext <<_ACEOF
17324/* end confdefs.h. */
73b77ee5
GM
17325/* Thanks to Paul Eggert for this test. */
17326#include <stdio.h>
cd958eb3 17327#include <stdlib.h>
fa0b693c 17328#include <sys/types.h>
73b77ee5 17329#include <sys/stat.h>
cd958eb3 17330#include <sys/wait.h>
503d2be0
AS
17331#if HAVE_UNISTD_H
17332# include <unistd.h>
73b77ee5 17333#endif
503d2be0
AS
17334#if HAVE_VFORK_H
17335# include <vfork.h>
73b77ee5
GM
17336#endif
17337/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
17338 argument registers are propagated back to the parent. The compiler
17339 is told about this with #include <vfork.h>, but some compilers
17340 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
17341 static variable whose address is put into a register that is
17342 clobbered by the vfork. */
cd958eb3 17343static void
fa0b693c 17344#ifdef __cplusplus
73b77ee5 17345sparc_address_test (int arg)
503d2be0 17346# else
73b77ee5 17347sparc_address_test (arg) int arg;
fa0b693c 17348#endif
fa0b693c 17349{
73b77ee5
GM
17350 static pid_t child;
17351 if (!child) {
17352 child = vfork ();
17353 if (child < 0) {
17354 perror ("vfork");
17355 _exit(2);
17356 }
17357 if (!child) {
17358 arg = getpid();
17359 write(-1, "", 0);
17360 _exit (arg);
17361 }
17362 }
17363}
503d2be0
AS
17364
17365int
17366main ()
17367{
73b77ee5
GM
17368 pid_t parent = getpid ();
17369 pid_t child;
fa0b693c 17370
cd958eb3 17371 sparc_address_test (0);
fa0b693c 17372
73b77ee5 17373 child = vfork ();
fa0b693c 17374
73b77ee5 17375 if (child == 0) {
503d2be0
AS
17376 /* Here is another test for sparc vfork register problems. This
17377 test uses lots of local variables, at least as many local
17378 variables as main has allocated so far including compiler
17379 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
17380 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
17381 reuse the register of parent for one of the local variables,
17382 since it will think that parent can't possibly be used any more
17383 in this routine. Assigning to the local variable will thus
17384 munge parent in the parent process. */
73b77ee5
GM
17385 pid_t
17386 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
17387 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
17388 /* Convince the compiler that p..p7 are live; otherwise, it might
17389 use the same hardware register for all 8 local variables. */
17390 if (p != p1 || p != p2 || p != p3 || p != p4
17391 || p != p5 || p != p6 || p != p7)
17392 _exit(1);
fa0b693c 17393
503d2be0
AS
17394 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
17395 from child file descriptors. If the child closes a descriptor
17396 before it execs or exits, this munges the parent's descriptor
17397 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
17398 _exit(close(fileno(stdout)) != 0);
17399 } else {
17400 int status;
17401 struct stat st;
17402
17403 while (wait(&status) != child)
17404 ;
17405 exit(
17406 /* Was there some problem with vforking? */
17407 child < 0
17408
17409 /* Did the child fail? (This shouldn't happen.) */
17410 || status
17411
17412 /* Did the vfork/compiler bug occur? */
17413 || parent != getpid()
fa0b693c 17414
73b77ee5
GM
17415 /* Did the file descriptor bug occur? */
17416 || fstat(fileno(stdout), &st) != 0
17417 );
17418 }
17419}
503d2be0
AS
17420_ACEOF
17421rm -f conftest$ac_exeext
c0d27fcc 17422if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17423 (eval $ac_link) 2>&5
17424 ac_status=$?
c0d27fcc 17425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17426 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 17427 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17428 (eval $ac_try) 2>&5
17429 ac_status=$?
c0d27fcc 17430 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17431 (exit $ac_status); }; }; then
73b77ee5 17432 ac_cv_func_vfork_works=yes
fa0b693c 17433else
503d2be0
AS
17434 echo "$as_me: program exited with status $ac_status" >&5
17435echo "$as_me: failed program was:" >&5
cd958eb3
MB
17436sed 's/^/| /' conftest.$ac_ext >&5
17437
c0d27fcc 17438( exit $ac_status )
503d2be0
AS
17439ac_cv_func_vfork_works=no
17440fi
6bae0ccf 17441rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 17442fi
fa0b693c 17443fi
c0d27fcc 17444echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 17445echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 17446
503d2be0
AS
17447fi;
17448if test "x$ac_cv_func_fork_works" = xcross; then
17449 ac_cv_func_vfork_works=ac_cv_func_vfork
c0d27fcc
MR
17450 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
17451echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
17452fi
17453
503d2be0
AS
17454if test "x$ac_cv_func_vfork_works" = xyes; then
17455
c0d27fcc 17456cat >>confdefs.h <<\_ACEOF
503d2be0 17457#define HAVE_WORKING_VFORK 1
c0d27fcc 17458_ACEOF
503d2be0
AS
17459
17460else
17461
c0d27fcc 17462cat >>confdefs.h <<\_ACEOF
73b77ee5 17463#define vfork fork
c0d27fcc 17464_ACEOF
fa0b693c
GM
17465
17466fi
503d2be0
AS
17467if test "x$ac_cv_func_fork_works" = xyes; then
17468
c0d27fcc 17469cat >>confdefs.h <<\_ACEOF
503d2be0 17470#define HAVE_WORKING_FORK 1
c0d27fcc 17471_ACEOF
fa0b693c 17472
503d2be0 17473fi
647847ea 17474
c0d27fcc 17475
6a3a24fa
JD
17476echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
17477echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
17478if test "${emacs_cv_langinfo_codeset+set}" = set; then
17479 echo $ECHO_N "(cached) $ECHO_C" >&6
17480else
17481 cat >conftest.$ac_ext <<_ACEOF
17482#line $LINENO "configure"
17483/* confdefs.h. */
17484_ACEOF
17485cat confdefs.h >>conftest.$ac_ext
17486cat >>conftest.$ac_ext <<_ACEOF
17487/* end confdefs.h. */
17488#include <langinfo.h>
17489int
17490main ()
17491{
17492char* cs = nl_langinfo(CODESET);
17493 ;
17494 return 0;
17495}
17496_ACEOF
17497rm -f conftest.$ac_objext conftest$ac_exeext
17498if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17499 (eval $ac_link) 2>&5
17500 ac_status=$?
17501 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17502 (exit $ac_status); } &&
17503 { ac_try='test -s conftest$ac_exeext'
17504 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17505 (eval $ac_try) 2>&5
17506 ac_status=$?
17507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17508 (exit $ac_status); }; }; then
17509 emacs_cv_langinfo_codeset=yes
17510else
17511 echo "$as_me: failed program was:" >&5
17512sed 's/^/| /' conftest.$ac_ext >&5
17513
17514emacs_cv_langinfo_codeset=no
17515fi
17516rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17517
17518fi
17519echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
17520echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
17521if test $emacs_cv_langinfo_codeset = yes; then
17522
17523cat >>confdefs.h <<\_ACEOF
17524#define HAVE_LANGINFO_CODESET 1
17525_ACEOF
17526
17527fi
17528
c0d27fcc 17529echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
17530echo $ECHO_N "checking for size_t... $ECHO_C" >&6
17531if test "${ac_cv_type_size_t+set}" = set; then
17532 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 17533else
503d2be0 17534 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17535#line $LINENO "configure"
cd958eb3
MB
17536/* confdefs.h. */
17537_ACEOF
17538cat confdefs.h >>conftest.$ac_ext
17539cat >>conftest.$ac_ext <<_ACEOF
17540/* end confdefs.h. */
503d2be0
AS
17541$ac_includes_default
17542int
17543main ()
17544{
17545if ((size_t *) 0)
17546 return 0;
17547if (sizeof (size_t))
17548 return 0;
17549 ;
17550 return 0;
17551}
17552_ACEOF
17553rm -f conftest.$ac_objext
c0d27fcc 17554if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
17555 (eval $ac_compile) 2>&5
17556 ac_status=$?
c0d27fcc 17557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17558 (exit $ac_status); } &&
17559 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 17560 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17561 (eval $ac_try) 2>&5
17562 ac_status=$?
c0d27fcc 17563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17564 (exit $ac_status); }; }; then
8730a8da
DL
17565 ac_cv_type_size_t=yes
17566else
503d2be0 17567 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17568sed 's/^/| /' conftest.$ac_ext >&5
17569
503d2be0 17570ac_cv_type_size_t=no
8730a8da 17571fi
503d2be0 17572rm -f conftest.$ac_objext conftest.$ac_ext
8730a8da 17573fi
c0d27fcc 17574echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
17575echo "${ECHO_T}$ac_cv_type_size_t" >&6
17576if test $ac_cv_type_size_t = yes; then
503d2be0 17577
c0d27fcc
MR
17578cat >>confdefs.h <<_ACEOF
17579#define HAVE_SIZE_T 1
17580_ACEOF
17581
8730a8da
DL
17582
17583fi
17584
c0d27fcc 17585
22044edf
DL
17586echo "$as_me:$LINENO: checking for C restrict keyword" >&5
17587echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
17588if test "${emacs_cv_c_restrict+set}" = set; then
17589 echo $ECHO_N "(cached) $ECHO_C" >&6
17590else
17591 cat >conftest.$ac_ext <<_ACEOF
17592#line $LINENO "configure"
cd958eb3
MB
17593/* confdefs.h. */
17594_ACEOF
17595cat confdefs.h >>conftest.$ac_ext
17596cat >>conftest.$ac_ext <<_ACEOF
17597/* end confdefs.h. */
22044edf
DL
17598void fred (int *restrict x);
17599int
17600main ()
17601{
b936fae4 17602
22044edf
DL
17603 ;
17604 return 0;
17605}
c0d27fcc 17606_ACEOF
22044edf
DL
17607rm -f conftest.$ac_objext
17608if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17609 (eval $ac_compile) 2>&5
17610 ac_status=$?
17611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17612 (exit $ac_status); } &&
17613 { ac_try='test -s conftest.$ac_objext'
17614 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17615 (eval $ac_try) 2>&5
17616 ac_status=$?
17617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17618 (exit $ac_status); }; }; then
17619 emacs_cv_c_restrict=yes
17620else
17621 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17622sed 's/^/| /' conftest.$ac_ext >&5
17623
22044edf
DL
17624cat >conftest.$ac_ext <<_ACEOF
17625#line $LINENO "configure"
cd958eb3
MB
17626/* confdefs.h. */
17627_ACEOF
17628cat confdefs.h >>conftest.$ac_ext
17629cat >>conftest.$ac_ext <<_ACEOF
17630/* end confdefs.h. */
22044edf
DL
17631void fred (int *__restrict x);
17632int
17633main ()
17634{
c0d27fcc 17635
22044edf
DL
17636 ;
17637 return 0;
17638}
c0d27fcc 17639_ACEOF
22044edf
DL
17640rm -f conftest.$ac_objext
17641if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17642 (eval $ac_compile) 2>&5
17643 ac_status=$?
17644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17645 (exit $ac_status); } &&
17646 { ac_try='test -s conftest.$ac_objext'
17647 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17648 (eval $ac_try) 2>&5
17649 ac_status=$?
17650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17651 (exit $ac_status); }; }; then
17652 emacs_cv_c_restrict=__restrict
17653else
17654 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17655sed 's/^/| /' conftest.$ac_ext >&5
17656
22044edf 17657emacs_cv_c_restrict=no
ba4481b5 17658fi
22044edf 17659rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 17660fi
22044edf 17661rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 17662fi
22044edf
DL
17663echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
17664echo "${ECHO_T}$emacs_cv_c_restrict" >&6
17665case "$emacs_cv_c_restrict" in
17666 yes) emacs_restrict=restrict;;
17667 no) emacs_restrict="";;
17668 *) emacs_restrict="$emacs_cv_c_restrict";;
17669esac
17670if test "$emacs_restrict" != __restrict; then
b936fae4 17671
22044edf
DL
17672cat >>confdefs.h <<_ACEOF
17673#define __restrict $emacs_restrict
c0d27fcc 17674_ACEOF
ba4481b5
DL
17675
17676fi
ba4481b5 17677
22044edf
DL
17678echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
17679echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
17680if test "${emacs_cv_c_restrict_arr+set}" = set; then
17681 echo $ECHO_N "(cached) $ECHO_C" >&6
17682else
17683 cat >conftest.$ac_ext <<_ACEOF
17684#line $LINENO "configure"
cd958eb3
MB
17685/* confdefs.h. */
17686_ACEOF
17687cat confdefs.h >>conftest.$ac_ext
17688cat >>conftest.$ac_ext <<_ACEOF
17689/* end confdefs.h. */
22044edf
DL
17690void fred (int x[__restrict]);
17691int
17692main ()
17693{
b936fae4 17694
22044edf
DL
17695 ;
17696 return 0;
17697}
c0d27fcc 17698_ACEOF
22044edf
DL
17699rm -f conftest.$ac_objext
17700if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17701 (eval $ac_compile) 2>&5
17702 ac_status=$?
17703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17704 (exit $ac_status); } &&
17705 { ac_try='test -s conftest.$ac_objext'
17706 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17707 (eval $ac_try) 2>&5
17708 ac_status=$?
17709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17710 (exit $ac_status); }; }; then
17711 emacs_cv_c_restrict_arr=yes
17712else
17713 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17714sed 's/^/| /' conftest.$ac_ext >&5
17715
22044edf 17716emacs_cv_c_restrict_arr=no
ba4481b5 17717fi
22044edf
DL
17718rm -f conftest.$ac_objext conftest.$ac_ext
17719fi
17720echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
17721echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
17722if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 17723
c0d27fcc 17724cat >>confdefs.h <<\_ACEOF
22044edf 17725#define __restrict_arr __restrict
c0d27fcc 17726_ACEOF
ba4481b5 17727
ba4481b5
DL
17728fi
17729
c0d27fcc 17730
f0f2756d
SS
17731for ac_header in nlist.h
17732do
17733as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17734if eval "test \"\${$as_ac_Header+set}\" = set"; then
17735 echo "$as_me:$LINENO: checking for $ac_header" >&5
f0f2756d
SS
17736echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17737if eval "test \"\${$as_ac_Header+set}\" = set"; then
17738 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17739fi
17740echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17741echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17742else
c0d27fcc
MR
17743 # Is the header compilable?
17744echo "$as_me:$LINENO: checking $ac_header usability" >&5
17745echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17746cat >conftest.$ac_ext <<_ACEOF
17747#line $LINENO "configure"
cd958eb3
MB
17748/* confdefs.h. */
17749_ACEOF
17750cat confdefs.h >>conftest.$ac_ext
17751cat >>conftest.$ac_ext <<_ACEOF
17752/* end confdefs.h. */
c0d27fcc
MR
17753$ac_includes_default
17754#include <$ac_header>
17755_ACEOF
17756rm -f conftest.$ac_objext
17757if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17758 (eval $ac_compile) 2>&5
17759 ac_status=$?
17760 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17761 (exit $ac_status); } &&
17762 { ac_try='test -s conftest.$ac_objext'
17763 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17764 (eval $ac_try) 2>&5
17765 ac_status=$?
17766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17767 (exit $ac_status); }; }; then
17768 ac_header_compiler=yes
17769else
17770 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17771sed 's/^/| /' conftest.$ac_ext >&5
17772
c0d27fcc
MR
17773ac_header_compiler=no
17774fi
17775rm -f conftest.$ac_objext conftest.$ac_ext
17776echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17777echo "${ECHO_T}$ac_header_compiler" >&6
17778
17779# Is the header present?
17780echo "$as_me:$LINENO: checking $ac_header presence" >&5
17781echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17782cat >conftest.$ac_ext <<_ACEOF
17783#line $LINENO "configure"
cd958eb3
MB
17784/* confdefs.h. */
17785_ACEOF
17786cat confdefs.h >>conftest.$ac_ext
17787cat >>conftest.$ac_ext <<_ACEOF
17788/* end confdefs.h. */
f0f2756d
SS
17789#include <$ac_header>
17790_ACEOF
c0d27fcc 17791if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
f0f2756d
SS
17792 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17793 ac_status=$?
6bae0ccf 17794 grep -v '^ *+' conftest.er1 >conftest.err
f0f2756d
SS
17795 rm -f conftest.er1
17796 cat conftest.err >&5
c0d27fcc 17797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f0f2756d
SS
17798 (exit $ac_status); } >/dev/null; then
17799 if test -s conftest.err; then
17800 ac_cpp_err=$ac_c_preproc_warn_flag
17801 else
17802 ac_cpp_err=
17803 fi
17804else
17805 ac_cpp_err=yes
17806fi
17807if test -z "$ac_cpp_err"; then
c0d27fcc 17808 ac_header_preproc=yes
f0f2756d
SS
17809else
17810 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17811sed 's/^/| /' conftest.$ac_ext >&5
17812
c0d27fcc 17813 ac_header_preproc=no
f0f2756d
SS
17814fi
17815rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17816echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17817echo "${ECHO_T}$ac_header_preproc" >&6
17818
17819# So? What about this header?
17820case $ac_header_compiler:$ac_header_preproc in
17821 yes:no )
17822 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17823echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17824 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17825echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17826 (
17827 cat <<\_ASBOX
17828## ------------------------------------ ##
17829## Report this to bug-autoconf@gnu.org. ##
17830## ------------------------------------ ##
17831_ASBOX
17832 ) |
17833 sed "s/^/$as_me: WARNING: /" >&2
17834 ;;
c0d27fcc
MR
17835 no:yes )
17836 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17837echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17838 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17839echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17840 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17841echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17842 (
17843 cat <<\_ASBOX
17844## ------------------------------------ ##
17845## Report this to bug-autoconf@gnu.org. ##
17846## ------------------------------------ ##
17847_ASBOX
17848 ) |
17849 sed "s/^/$as_me: WARNING: /" >&2
17850 ;;
c0d27fcc
MR
17851esac
17852echo "$as_me:$LINENO: checking for $ac_header" >&5
17853echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17854if eval "test \"\${$as_ac_Header+set}\" = set"; then
17855 echo $ECHO_N "(cached) $ECHO_C" >&6
17856else
17857 eval "$as_ac_Header=$ac_header_preproc"
f0f2756d 17858fi
c0d27fcc 17859echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
f0f2756d 17860echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17861
17862fi
f0f2756d 17863if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17864 cat >>confdefs.h <<_ACEOF
f0f2756d 17865#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17866_ACEOF
f0f2756d 17867
c0d27fcc 17868cat >>confdefs.h <<\_ACEOF
f0f2756d 17869#define NLIST_STRUCT 1
c0d27fcc 17870_ACEOF
f0f2756d
SS
17871
17872fi
c0d27fcc 17873
f0f2756d
SS
17874done
17875
c0d27fcc
MR
17876
17877
17878
22044edf
DL
17879# Set up the CFLAGS for real compilation, so we can substitute it.
17880CFLAGS="$REAL_CFLAGS"
17881CPPFLAGS="$REAL_CPPFLAGS"
17882
17883#### Find out which version of Emacs this is.
17884version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
17885 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
17886if test x"${version}" = x; then
17887 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
17888echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
17889 { (exit 1); exit 1; }; }
17890fi
17891
17892### Specify what sort of things we'll be editing into Makefile and config.h.
17893### Use configuration here uncanonicalized to avoid exceeding size limits.
17894
17895
17896
17897
17898
17899
17900
17901
17902
17903
17904
17905
17906
17907
17908
17909
17910
17911
17912
17913
17914
17915
17916
17917
17918
17919
17920
17921
17922
17923
17924
17925
6a3a24fa 17926
22044edf
DL
17927
17928
17929cat >>confdefs.h <<_ACEOF
17930#define EMACS_CONFIGURATION "${canonical}"
17931_ACEOF
17932
17933
17934cat >>confdefs.h <<_ACEOF
17935#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
17936_ACEOF
17937
17938
17939cat >>confdefs.h <<_ACEOF
17940#define config_machfile "${machfile}"
17941_ACEOF
17942
17943
17944cat >>confdefs.h <<_ACEOF
17945#define config_opsysfile "${opsysfile}"
17946_ACEOF
17947
17948
17949cat >>confdefs.h <<_ACEOF
17950#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
17951_ACEOF
17952
17953
17954cat >>confdefs.h <<_ACEOF
17955#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
17956_ACEOF
17957
17958
17959cat >>confdefs.h <<_ACEOF
17960#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
17961_ACEOF
17962
17963
17964cat >>confdefs.h <<_ACEOF
17965#define UNEXEC_SRC ${UNEXEC_SRC}
17966_ACEOF
17967
17968
17969if test "${HAVE_X_WINDOWS}" = "yes" ; then
17970
17971cat >>confdefs.h <<\_ACEOF
17972#define HAVE_X_WINDOWS 1
17973_ACEOF
17974
17975fi
17976if test "${USE_X_TOOLKIT}" != "none" ; then
17977
17978cat >>confdefs.h <<\_ACEOF
17979#define USE_X_TOOLKIT 1
17980_ACEOF
17981
17982fi
17983if test "${HAVE_X11}" = "yes" ; then
17984
17985cat >>confdefs.h <<\_ACEOF
17986#define HAVE_X11 1
17987_ACEOF
17988
17989fi
17990if test "${HAVE_XFREE386}" = "yes" ; then
17991
17992cat >>confdefs.h <<\_ACEOF
17993#define HAVE_XFREE386 1
17994_ACEOF
17995
17996fi
17997if test "${HAVE_MENUS}" = "yes" ; then
17998
17999cat >>confdefs.h <<\_ACEOF
18000#define HAVE_MENUS 1
18001_ACEOF
18002
18003fi
18004if test "${GNU_MALLOC}" = "yes" ; then
18005
18006cat >>confdefs.h <<\_ACEOF
18007#define GNU_MALLOC 1
18008_ACEOF
18009
18010fi
18011if test "${REL_ALLOC}" = "yes" ; then
18012
18013cat >>confdefs.h <<\_ACEOF
18014#define REL_ALLOC 1
18015_ACEOF
18016
18017fi
18018
18019
18020
c0d27fcc
MR
18021
18022
ba4481b5 18023#### Report on what we decided to do.
488dd4c4
JD
18024#### Report GTK as a toolkit, even if it doesn't use Xt.
18025#### It makes printing result more understandable as using GTK sets
18026#### toolkit_scroll_bars to yes by default.
18027if test "${HAVE_GTK}" = "yes"; then
18028 USE_X_TOOLKIT=GTK
18029fi
18030
ba4481b5
DL
18031echo "
18032Configured for \`${canonical}'.
18033
18034 Where should the build process find the source code? ${srcdir}
18035 What operating system and machine description files should Emacs use?
18036 \`${opsysfile}' and \`${machfile}'
18037 What compiler should emacs be built with? ${CC} ${CFLAGS}
18038 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 18039 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 18040 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 18041 What window system should Emacs use? ${window_system}
8e967cf7 18042 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
18043
18044if test -n "${x_includes}"; then
18045echo " Where do we find X Windows header files? ${x_includes}"
18046else
18047echo " Where do we find X Windows header files? Standard dirs"
18048fi
18049if test -n "${x_libraries}"; then
18050echo " Where do we find X Windows libraries? ${x_libraries}"
18051else
18052echo " Where do we find X Windows libraries? Standard dirs"
18053fi
18054
18055echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
18056echo " Does Emacs use -lXpm? ${HAVE_XPM}"
18057echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
18058echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
18059echo " Does Emacs use -lungif? ${HAVE_GIF}"
18060echo " Does Emacs use -lpng? ${HAVE_PNG}"
18061echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
18062echo
18063
18064# Remove any trailing slashes in these variables.
18065test "${prefix}" != NONE &&
18066 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
18067test "${exec_prefix}" != NONE &&
18068 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
18069
d0e9bfd2
GM
18070## Check if the C preprocessor will convert `..' to `. .'. If so, set
18071## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
18072## from Makefile.c can correctly provide the arg `-traditional' to the
18073## C preprocessor.
18074
503d2be0 18075cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 18076#line $LINENO "configure"
cd958eb3
MB
18077/* confdefs.h. */
18078_ACEOF
18079cat confdefs.h >>conftest.$ac_ext
18080cat >>conftest.$ac_ext <<_ACEOF
18081/* end confdefs.h. */
d0e9bfd2 18082yes..yes
503d2be0 18083_ACEOF
d0e9bfd2 18084if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 18085 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
18086 CPP_NEED_TRADITIONAL=no
18087else
d0e9bfd2
GM
18088 CPP_NEED_TRADITIONAL=yes
18089fi
18090rm -f conftest*
18091
c0d27fcc 18092
6bae0ccf
DL
18093 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"
18094 ac_config_commands="$ac_config_commands default"
503d2be0 18095cat >confcache <<\_ACEOF
ba4481b5
DL
18096# This file is a shell script that caches the results of configure
18097# tests run on this system so they can be shared between configure
503d2be0
AS
18098# scripts and configure runs, see configure's option --config-cache.
18099# It is not useful on other systems. If it contains results you don't
18100# want to keep, you may remove or edit it.
ba4481b5 18101#
503d2be0
AS
18102# config.status only pays attention to the cache file if you give it
18103# the --recheck option to rerun configure.
ba4481b5 18104#
6bae0ccf 18105# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
18106# loading this file, other *unset* `ac_cv_foo' will be assigned the
18107# following values.
18108
18109_ACEOF
18110
ba4481b5
DL
18111# The following way of writing the cache mishandles newlines in values,
18112# but we know of no workaround that is simple, portable, and efficient.
18113# So, don't put newlines in cache variables' values.
18114# Ultrix sh set writes to stderr and can't be redirected directly,
18115# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
18116{
18117 (set) 2>&1 |
18118 case `(ac_space=' '; set | grep ac_space) 2>&1` in
18119 *ac_space=\ *)
18120 # `set' does not quote correctly, so add quotes (double-quote
18121 # substitution turns \\\\ into \\, and sed turns \\ into \).
18122 sed -n \
18123 "s/'/'\\\\''/g;
18124 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18125 ;;
18126 *)
18127 # `set' quotes correctly as required by POSIX, so do not add quotes.
18128 sed -n \
18129 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
18130 ;;
18131 esac;
18132} |
18133 sed '
18134 t clear
18135 : clear
18136 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18137 t end
18138 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18139 : end' >>confcache
cd958eb3 18140if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 18141 if test -w $cache_file; then
503d2be0
AS
18142 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
18143 cat confcache >$cache_file
ba4481b5
DL
18144 else
18145 echo "not updating unwritable cache $cache_file"
18146 fi
18147fi
18148rm -f confcache
18149
ba4481b5
DL
18150test "x$prefix" = xNONE && prefix=$ac_default_prefix
18151# Let make expand exec_prefix.
18152test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18153
503d2be0
AS
18154# VPATH may cause trouble with some makes, so we remove $(srcdir),
18155# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18156# trailing colons and then remove the whole line if VPATH becomes empty
18157# (actually we leave an empty line to preserve line numbers).
ba4481b5 18158if test "x$srcdir" = x.; then
503d2be0
AS
18159 ac_vpsub='/^[ ]*VPATH[ ]*=/{
18160s/:*\$(srcdir):*/:/;
18161s/:*\${srcdir}:*/:/;
18162s/:*@srcdir@:*/:/;
18163s/^\([^=]*=[ ]*\):*/\1/;
18164s/:*$//;
18165s/^[^=]*=[ ]*$//;
18166}'
ba4481b5
DL
18167fi
18168
ba4481b5
DL
18169DEFS=-DHAVE_CONFIG_H
18170
6bae0ccf
DL
18171ac_libobjs=
18172ac_ltlibobjs=
18173for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18174 # 1. Remove the extension, and $U if already installed.
18175 ac_i=`echo "$ac_i" |
18176 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
18177 # 2. Add them.
18178 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
18179 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
18180done
18181LIBOBJS=$ac_libobjs
18182
18183LTLIBOBJS=$ac_ltlibobjs
18184
18185
c0d27fcc 18186
ba4481b5 18187: ${CONFIG_STATUS=./config.status}
503d2be0
AS
18188ac_clean_files_save=$ac_clean_files
18189ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 18190{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
18191echo "$as_me: creating $CONFIG_STATUS" >&6;}
18192cat >$CONFIG_STATUS <<_ACEOF
18193#! $SHELL
c0d27fcc 18194# Generated by $as_me.
ba4481b5 18195# Run this file to recreate the current configuration.
ba4481b5 18196# Compiler output produced by configure, useful for debugging
503d2be0 18197# configure, is in config.log if it exists.
ba4481b5 18198
503d2be0 18199debug=false
cd958eb3
MB
18200ac_cs_recheck=false
18201ac_cs_silent=false
503d2be0 18202SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
18203_ACEOF
18204
18205cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
18206## --------------------- ##
18207## M4sh Initialization. ##
18208## --------------------- ##
18209
503d2be0
AS
18210# Be Bourne compatible
18211if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18212 emulate sh
18213 NULLCMD=:
6bae0ccf
DL
18214 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
18215 # is contrary to our usage. Disable this feature.
18216 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
18217elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
18218 set -o posix
18219fi
18220
c0d27fcc
MR
18221# Support unset when possible.
18222if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
18223 as_unset=unset
18224else
18225 as_unset=false
18226fi
18227
6bae0ccf
DL
18228
18229# Work around bugs in pre-3.0 UWIN ksh.
18230$as_unset ENV MAIL MAILPATH
18231PS1='$ '
18232PS2='> '
18233PS4='+ '
18234
18235# NLS nuisances.
cd958eb3
MB
18236for as_var in \
18237 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
18238 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
18239 LC_TELEPHONE LC_TIME
6bae0ccf
DL
18240do
18241 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
18242 eval $as_var=C; export $as_var
18243 else
18244 $as_unset $as_var
18245 fi
18246done
18247
18248# Required to use basename.
18249if expr a : '\(a\)' >/dev/null 2>&1; then
18250 as_expr=expr
18251else
18252 as_expr=false
18253fi
18254
18255if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
18256 as_basename=basename
18257else
18258 as_basename=false
18259fi
c0d27fcc
MR
18260
18261
503d2be0 18262# Name of the executable.
6bae0ccf 18263as_me=`$as_basename "$0" ||
c0d27fcc
MR
18264$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18265 X"$0" : 'X\(//\)$' \| \
18266 X"$0" : 'X\(/\)$' \| \
18267 . : '\(.\)' 2>/dev/null ||
18268echo X/"$0" |
18269 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
18270 /^X\/\(\/\/\)$/{ s//\1/; q; }
18271 /^X\/\(\/\).*/{ s//\1/; q; }
18272 s/.*/./; q'`
18273
6bae0ccf 18274
c0d27fcc
MR
18275# PATH needs CR, and LINENO needs CR and PATH.
18276# Avoid depending upon Character Ranges.
18277as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18278as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18279as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18280as_cr_digits='0123456789'
18281as_cr_alnum=$as_cr_Letters$as_cr_digits
18282
18283# The user is always right.
18284if test "${PATH_SEPARATOR+set}" != set; then
cd958eb3
MB
18285 echo "#! /bin/sh" >conf$$.sh
18286 echo "exit 0" >>conf$$.sh
18287 chmod +x conf$$.sh
18288 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
18289 PATH_SEPARATOR=';'
18290 else
18291 PATH_SEPARATOR=:
18292 fi
cd958eb3 18293 rm -f conf$$.sh
c0d27fcc
MR
18294fi
18295
18296
18297 as_lineno_1=$LINENO
18298 as_lineno_2=$LINENO
18299 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18300 test "x$as_lineno_1" != "x$as_lineno_2" &&
18301 test "x$as_lineno_3" = "x$as_lineno_2" || {
18302 # Find who we are. Look in the path if we contain no path at all
18303 # relative or not.
18304 case $0 in
18305 *[\\/]* ) as_myself=$0 ;;
18306 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18307for as_dir in $PATH
18308do
18309 IFS=$as_save_IFS
18310 test -z "$as_dir" && as_dir=.
18311 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18312done
18313
18314 ;;
18315 esac
18316 # We did not find ourselves, most probably we were run as `sh COMMAND'
18317 # in which case we are not to be found in the path.
18318 if test "x$as_myself" = x; then
18319 as_myself=$0
18320 fi
18321 if test ! -f "$as_myself"; then
18322 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
18323echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
18324 { (exit 1); exit 1; }; }
18325 fi
18326 case $CONFIG_SHELL in
18327 '')
18328 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18329for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
18330do
18331 IFS=$as_save_IFS
18332 test -z "$as_dir" && as_dir=.
18333 for as_base in sh bash ksh sh5; do
18334 case $as_dir in
18335 /*)
18336 if ("$as_dir/$as_base" -c '
18337 as_lineno_1=$LINENO
18338 as_lineno_2=$LINENO
18339 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18340 test "x$as_lineno_1" != "x$as_lineno_2" &&
18341 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
18342 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
18343 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
18344 CONFIG_SHELL=$as_dir/$as_base
18345 export CONFIG_SHELL
18346 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
18347 fi;;
18348 esac
18349 done
18350done
18351;;
18352 esac
18353
18354 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
18355 # uniformly replaced by the line number. The first 'sed' inserts a
18356 # line-number line before each line; the second 'sed' does the real
18357 # work. The second script uses 'N' to pair each line-number line
18358 # with the numbered line, and appends trailing '-' during
18359 # substitution so that $LINENO is not a special case at line end.
18360 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
18361 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
18362 sed '=' <$as_myself |
18363 sed '
18364 N
18365 s,$,-,
18366 : loop
18367 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
18368 t loop
18369 s,-$,,
18370 s,^['$as_cr_digits']*\n,,
18371 ' >$as_me.lineno &&
18372 chmod +x $as_me.lineno ||
18373 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
18374echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
18375 { (exit 1); exit 1; }; }
18376
18377 # Don't try to exec as it changes $[0], causing all sort of problems
18378 # (the dirname of $[0] is not the place where we might find the
18379 # original and so on. Autoconf is especially sensible to this).
18380 . ./$as_me.lineno
18381 # Exit status is that of the last command.
18382 exit
18383}
18384
18385
18386case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
18387 *c*,-n*) ECHO_N= ECHO_C='
18388' ECHO_T=' ' ;;
18389 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
18390 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
18391esac
503d2be0
AS
18392
18393if expr a : '\(a\)' >/dev/null 2>&1; then
18394 as_expr=expr
18395else
18396 as_expr=false
18397fi
18398
18399rm -f conf$$ conf$$.exe conf$$.file
18400echo >conf$$.file
18401if ln -s conf$$.file conf$$ 2>/dev/null; then
18402 # We could just check for DJGPP; but this test a) works b) is more generic
18403 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
18404 if test -f conf$$.exe; then
18405 # Don't use ln at all; we don't have any links
18406 as_ln_s='cp -p'
18407 else
18408 as_ln_s='ln -s'
18409 fi
18410elif ln conf$$.file conf$$ 2>/dev/null; then
18411 as_ln_s=ln
18412else
18413 as_ln_s='cp -p'
18414fi
18415rm -f conf$$ conf$$.exe conf$$.file
18416
6bae0ccf
DL
18417if mkdir -p . 2>/dev/null; then
18418 as_mkdir_p=:
18419else
18420 as_mkdir_p=false
18421fi
18422
503d2be0
AS
18423as_executable_p="test -f"
18424
c0d27fcc
MR
18425# Sed expression to map a string onto a valid CPP name.
18426as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
18427
18428# Sed expression to map a string onto a valid variable name.
18429as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
503d2be0 18430
503d2be0
AS
18431
18432# IFS
18433# We need space, tab and new line, in precisely that order.
18434as_nl='
18435'
18436IFS=" $as_nl"
18437
18438# CDPATH.
6bae0ccf 18439$as_unset CDPATH
503d2be0
AS
18440
18441exec 6>&1
18442
c0d27fcc
MR
18443# Open the log real soon, to keep \$[0] and so on meaningful, and to
18444# report actual input values of CONFIG_FILES etc. instead of their
18445# values after options handling. Logging --version etc. is OK.
18446exec 5>>config.log
18447{
18448 echo
18449 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18450## Running $as_me. ##
18451_ASBOX
18452} >&5
18453cat >&5 <<_CSEOF
18454
18455This file was extended by $as_me, which was
9e71690e 18456generated by GNU Autoconf 2.57. Invocation command line was
c0d27fcc
MR
18457
18458 CONFIG_FILES = $CONFIG_FILES
18459 CONFIG_HEADERS = $CONFIG_HEADERS
18460 CONFIG_LINKS = $CONFIG_LINKS
18461 CONFIG_COMMANDS = $CONFIG_COMMANDS
18462 $ $0 $@
18463
18464_CSEOF
18465echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
18466echo >&5
503d2be0
AS
18467_ACEOF
18468
18469# Files that config.status was made for.
18470if test -n "$ac_config_files"; then
18471 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
18472fi
18473
18474if test -n "$ac_config_headers"; then
18475 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
18476fi
18477
18478if test -n "$ac_config_links"; then
18479 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
18480fi
18481
18482if test -n "$ac_config_commands"; then
18483 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
18484fi
18485
c0d27fcc 18486cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18487
18488ac_cs_usage="\
18489\`$as_me' instantiates files from templates according to the
18490current configuration.
18491
18492Usage: $0 [OPTIONS] [FILE]...
18493
18494 -h, --help print this help, then exit
18495 -V, --version print version number, then exit
cd958eb3 18496 -q, --quiet do not print progress messages
503d2be0
AS
18497 -d, --debug don't remove temporary files
18498 --recheck update $as_me by reconfiguring in the same conditions
18499 --file=FILE[:TEMPLATE]
18500 instantiate the configuration file FILE
18501 --header=FILE[:TEMPLATE]
18502 instantiate the configuration header FILE
18503
18504Configuration files:
18505$config_files
18506
18507Configuration headers:
18508$config_headers
18509
18510Configuration commands:
18511$config_commands
18512
18513Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 18514_ACEOF
503d2be0 18515
c0d27fcc 18516cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18517ac_cs_version="\\
18518config.status
9e71690e 18519configured by $0, generated by GNU Autoconf 2.57,
503d2be0
AS
18520 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18521
18522Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18523Free Software Foundation, Inc.
18524This config.status script is free software; the Free Software Foundation
18525gives unlimited permission to copy, distribute and modify it."
18526srcdir=$srcdir
18527INSTALL="$INSTALL"
c0d27fcc 18528_ACEOF
503d2be0 18529
c0d27fcc 18530cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18531# If no file are specified by the user, then we need to provide default
18532# value. By we need to know if files were specified by the user.
18533ac_need_defaults=:
18534while test $# != 0
ba4481b5 18535do
503d2be0
AS
18536 case $1 in
18537 --*=*)
18538 ac_option=`expr "x$1" : 'x\([^=]*\)='`
18539 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
18540 ac_shift=:
18541 ;;
18542 -*)
18543 ac_option=$1
18544 ac_optarg=$2
18545 ac_shift=shift
503d2be0 18546 ;;
503d2be0
AS
18547 *) # This is not an option, so the user has probably given explicit
18548 # arguments.
6bae0ccf 18549 ac_option=$1
503d2be0
AS
18550 ac_need_defaults=false;;
18551 esac
18552
6bae0ccf 18553 case $ac_option in
503d2be0 18554 # Handling of the options.
c0d27fcc 18555_ACEOF
c0d27fcc 18556cat >>$CONFIG_STATUS <<\_ACEOF
cd958eb3
MB
18557 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18558 ac_cs_recheck=: ;;
503d2be0
AS
18559 --version | --vers* | -V )
18560 echo "$ac_cs_version"; exit 0 ;;
18561 --he | --h)
18562 # Conflict between --help and --header
c0d27fcc 18563 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
18564Try \`$0 --help' for more information." >&5
18565echo "$as_me: error: ambiguous option: $1
18566Try \`$0 --help' for more information." >&2;}
18567 { (exit 1); exit 1; }; };;
18568 --help | --hel | -h )
18569 echo "$ac_cs_usage"; exit 0 ;;
18570 --debug | --d* | -d )
18571 debug=: ;;
18572 --file | --fil | --fi | --f )
6bae0ccf
DL
18573 $ac_shift
18574 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
18575 ac_need_defaults=false;;
18576 --header | --heade | --head | --hea )
6bae0ccf
DL
18577 $ac_shift
18578 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 18579 ac_need_defaults=false;;
cd958eb3
MB
18580 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18581 | -silent | --silent | --silen | --sile | --sil | --si | --s)
18582 ac_cs_silent=: ;;
503d2be0
AS
18583
18584 # This is an error.
c0d27fcc 18585 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
18586Try \`$0 --help' for more information." >&5
18587echo "$as_me: error: unrecognized option: $1
18588Try \`$0 --help' for more information." >&2;}
18589 { (exit 1); exit 1; }; } ;;
18590
18591 *) ac_config_targets="$ac_config_targets $1" ;;
18592
ba4481b5 18593 esac
503d2be0 18594 shift
ba4481b5
DL
18595done
18596
cd958eb3
MB
18597ac_configure_extra_args=
18598
18599if $ac_cs_silent; then
18600 exec 6>/dev/null
18601 ac_configure_extra_args="$ac_configure_extra_args --silent"
18602fi
18603
18604_ACEOF
18605cat >>$CONFIG_STATUS <<_ACEOF
18606if \$ac_cs_recheck; then
18607 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
18608 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18609fi
18610
503d2be0 18611_ACEOF
ba4481b5 18612
c0d27fcc 18613cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18614#
18615# INIT-COMMANDS section.
18616#
ba4481b5 18617
503d2be0
AS
18618GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
18619
c0d27fcc
MR
18620_ACEOF
18621
503d2be0 18622
c0d27fcc
MR
18623
18624cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18625for ac_config_target in $ac_config_targets
18626do
18627 case "$ac_config_target" in
18628 # Handling of arguments.
18629 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18630 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
18631 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
18632 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
18633 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
18634 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
18635 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 18636 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 18637 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
18638 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
18639 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
18640 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 18641 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
18642echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18643 { (exit 1); exit 1; }; };;
18644 esac
ba4481b5 18645done
503d2be0
AS
18646
18647# If the user did not use the arguments to specify the items to instantiate,
18648# then the envvar interface is used. Set only those that are not.
18649# We use the long form for the default assignment because of an extremely
18650# bizarre bug on SunOS 4.1.3.
18651if $ac_need_defaults; then
18652 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18653 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18654 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 18655fi
503d2be0 18656
cd958eb3
MB
18657# Have a temporary directory for convenience. Make it in the build tree
18658# simply because there is no reason to put it here, and in addition,
18659# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
18660# Create a temporary directory, and hook for its removal unless debugging.
18661$debug ||
18662{
18663 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
18664 trap '{ (exit 1); exit 1; }' 1 2 13 15
18665}
18666
18667# Create a (secure) tmp directory for tmp files.
cd958eb3 18668
503d2be0 18669{
cd958eb3 18670 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
18671 test -n "$tmp" && test -d "$tmp"
18672} ||
18673{
cd958eb3 18674 tmp=./confstat$$-$RANDOM
503d2be0
AS
18675 (umask 077 && mkdir $tmp)
18676} ||
18677{
cd958eb3 18678 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
18679 { (exit 1); exit 1; }
18680}
18681
c0d27fcc 18682_ACEOF
503d2be0 18683
c0d27fcc 18684cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18685
18686#
18687# CONFIG_FILES section.
18688#
18689
18690# No need to generate the scripts if there are no CONFIG_FILES.
18691# This happens for instance when ./config.status config.h
18692if test -n "\$CONFIG_FILES"; then
18693 # Protect against being on the right side of a sed subst in config.status.
18694 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
18695 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
18696s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
18697s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
18698s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
18699s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
18700s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
18701s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
18702s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
18703s,@exec_prefix@,$exec_prefix,;t t
18704s,@prefix@,$prefix,;t t
18705s,@program_transform_name@,$program_transform_name,;t t
18706s,@bindir@,$bindir,;t t
18707s,@sbindir@,$sbindir,;t t
18708s,@libexecdir@,$libexecdir,;t t
18709s,@datadir@,$datadir,;t t
18710s,@sysconfdir@,$sysconfdir,;t t
18711s,@sharedstatedir@,$sharedstatedir,;t t
18712s,@localstatedir@,$localstatedir,;t t
18713s,@libdir@,$libdir,;t t
18714s,@includedir@,$includedir,;t t
18715s,@oldincludedir@,$oldincludedir,;t t
18716s,@infodir@,$infodir,;t t
18717s,@mandir@,$mandir,;t t
503d2be0
AS
18718s,@build_alias@,$build_alias,;t t
18719s,@host_alias@,$host_alias,;t t
18720s,@target_alias@,$target_alias,;t t
c0d27fcc 18721s,@DEFS@,$DEFS,;t t
503d2be0
AS
18722s,@ECHO_C@,$ECHO_C,;t t
18723s,@ECHO_N@,$ECHO_N,;t t
18724s,@ECHO_T@,$ECHO_T,;t t
503d2be0
AS
18725s,@LIBS@,$LIBS,;t t
18726s,@build@,$build,;t t
18727s,@build_cpu@,$build_cpu,;t t
18728s,@build_vendor@,$build_vendor,;t t
18729s,@build_os@,$build_os,;t t
18730s,@host@,$host,;t t
18731s,@host_cpu@,$host_cpu,;t t
18732s,@host_vendor@,$host_vendor,;t t
18733s,@host_os@,$host_os,;t t
18734s,@CC@,$CC,;t t
18735s,@CFLAGS@,$CFLAGS,;t t
18736s,@LDFLAGS@,$LDFLAGS,;t t
18737s,@CPPFLAGS@,$CPPFLAGS,;t t
18738s,@ac_ct_CC@,$ac_ct_CC,;t t
18739s,@EXEEXT@,$EXEEXT,;t t
18740s,@OBJEXT@,$OBJEXT,;t t
18741s,@LN_S@,$LN_S,;t t
18742s,@CPP@,$CPP,;t t
18743s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
18744s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
18745s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
18746s,@RANLIB@,$RANLIB,;t t
18747s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 18748s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 18749s,@EGREP@,$EGREP,;t t
503d2be0
AS
18750s,@LIBSOUND@,$LIBSOUND,;t t
18751s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
18752s,@PKG_CONFIG@,$PKG_CONFIG,;t t
18753s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
18754s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
18755s,@ALLOCA@,$ALLOCA,;t t
18756s,@liblockfile@,$liblockfile,;t t
18757s,@LIBOBJS@,$LIBOBJS,;t t
18758s,@NEED_SETGID@,$NEED_SETGID,;t t
18759s,@KMEM_GROUP@,$KMEM_GROUP,;t t
18760s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
18761s,@version@,$version,;t t
18762s,@configuration@,$configuration,;t t
18763s,@canonical@,$canonical,;t t
18764s,@srcdir@,$srcdir,;t t
18765s,@lispdir@,$lispdir,;t t
18766s,@locallisppath@,$locallisppath,;t t
18767s,@lisppath@,$lisppath,;t t
18768s,@x_default_search_path@,$x_default_search_path,;t t
18769s,@etcdir@,$etcdir,;t t
18770s,@archlibdir@,$archlibdir,;t t
18771s,@docdir@,$docdir,;t t
18772s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
18773s,@gamedir@,$gamedir,;t t
18774s,@gameuser@,$gameuser,;t t
503d2be0
AS
18775s,@c_switch_system@,$c_switch_system,;t t
18776s,@c_switch_machine@,$c_switch_machine,;t t
18777s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
18778s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
18779s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
18780s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
18781s,@machfile@,$machfile,;t t
18782s,@opsysfile@,$opsysfile,;t t
6a3a24fa 18783s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 18784s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
18785CEOF
18786
c0d27fcc 18787_ACEOF
ba4481b5 18788
c0d27fcc 18789 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18790 # Split the substitutions into bite-sized pieces for seds with
18791 # small command number limits, like on Digital OSF/1 and HP-UX.
18792 ac_max_sed_lines=48
18793 ac_sed_frag=1 # Number of current file.
18794 ac_beg=1 # First line for current file.
18795 ac_end=$ac_max_sed_lines # Line after last line for current file.
18796 ac_more_lines=:
18797 ac_sed_cmds=
18798 while $ac_more_lines; do
18799 if test $ac_beg -gt 1; then
18800 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18801 else
18802 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18803 fi
18804 if test ! -s $tmp/subs.frag; then
18805 ac_more_lines=false
18806 else
18807 # The purpose of the label and of the branching condition is to
18808 # speed up the sed processing (if there are no `@' at all, there
18809 # is no need to browse any of the substitutions).
18810 # These are the two extra sed commands mentioned above.
18811 (echo ':t
18812 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
18813 if test -z "$ac_sed_cmds"; then
18814 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
18815 else
18816 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
18817 fi
18818 ac_sed_frag=`expr $ac_sed_frag + 1`
18819 ac_beg=$ac_end
18820 ac_end=`expr $ac_end + $ac_max_sed_lines`
18821 fi
18822 done
18823 if test -z "$ac_sed_cmds"; then
18824 ac_sed_cmds=cat
18825 fi
18826fi # test -n "$CONFIG_FILES"
ba4481b5 18827
c0d27fcc
MR
18828_ACEOF
18829cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 18830for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 18831 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
18832 case $ac_file in
18833 - | *:- | *:-:* ) # input from stdin
18834 cat >$tmp/stdin
18835 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18836 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18837 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18838 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18839 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
18840 esac
18841
503d2be0 18842 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
18843 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
18844$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
503d2be0
AS
18845 X"$ac_file" : 'X\(//\)[^/]' \| \
18846 X"$ac_file" : 'X\(//\)$' \| \
18847 X"$ac_file" : 'X\(/\)' \| \
18848 . : '\(.\)' 2>/dev/null ||
18849echo X"$ac_file" |
18850 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18851 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18852 /^X\(\/\/\)$/{ s//\1/; q; }
18853 /^X\(\/\).*/{ s//\1/; q; }
18854 s/.*/./; q'`
6bae0ccf
DL
18855 { if $as_mkdir_p; then
18856 mkdir -p "$ac_dir"
18857 else
18858 as_dir="$ac_dir"
18859 as_dirs=
18860 while test ! -d "$as_dir"; do
18861 as_dirs="$as_dir $as_dirs"
18862 as_dir=`(dirname "$as_dir") 2>/dev/null ||
18863$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18864 X"$as_dir" : 'X\(//\)[^/]' \| \
18865 X"$as_dir" : 'X\(//\)$' \| \
18866 X"$as_dir" : 'X\(/\)' \| \
18867 . : '\(.\)' 2>/dev/null ||
18868echo X"$as_dir" |
18869 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18870 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18871 /^X\(\/\/\)$/{ s//\1/; q; }
18872 /^X\(\/\).*/{ s//\1/; q; }
18873 s/.*/./; q'`
18874 done
18875 test ! -n "$as_dirs" || mkdir $as_dirs
18876 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
18877echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
18878 { (exit 1); exit 1; }; }; }
503d2be0 18879
c0d27fcc 18880 ac_builddir=.
98418dba 18881
c0d27fcc
MR
18882if test "$ac_dir" != .; then
18883 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
18884 # A "../" for each directory in $ac_dir_suffix.
18885 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
18886else
18887 ac_dir_suffix= ac_top_builddir=
18888fi
18889
18890case $srcdir in
18891 .) # No --srcdir option. We are building in place.
18892 ac_srcdir=.
18893 if test -z "$ac_top_builddir"; then
18894 ac_top_srcdir=.
18895 else
18896 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
18897 fi ;;
18898 [\\/]* | ?:[\\/]* ) # Absolute path.
18899 ac_srcdir=$srcdir$ac_dir_suffix;
18900 ac_top_srcdir=$srcdir ;;
ba4481b5 18901 *) # Relative path.
c0d27fcc
MR
18902 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
18903 ac_top_srcdir=$ac_top_builddir$srcdir ;;
18904esac
18905# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
18906# absolute.
18907ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
6bae0ccf 18908ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
c0d27fcc
MR
18909ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
18910ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
18911
ba4481b5 18912
503d2be0
AS
18913 case $INSTALL in
18914 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 18915 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
18916 esac
18917
503d2be0 18918 if test x"$ac_file" != x-; then
c0d27fcc 18919 { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
18920echo "$as_me: creating $ac_file" >&6;}
18921 rm -f "$ac_file"
18922 fi
18923 # Let's still pretend it is `configure' which instantiates (i.e., don't
18924 # use $as_me), people would be surprised to read:
c0d27fcc
MR
18925 # /* config.h. Generated by config.status. */
18926 if test x"$ac_file" = x-; then
18927 configure_input=
18928 else
18929 configure_input="$ac_file. "
18930 fi
18931 configure_input=$configure_input"Generated from `echo $ac_file_in |
18932 sed 's,.*/,,'` by configure."
503d2be0
AS
18933
18934 # First look for the input files in the build tree, otherwise in the
18935 # src tree.
18936 ac_file_inputs=`IFS=:
18937 for f in $ac_file_in; do
18938 case $f in
18939 -) echo $tmp/stdin ;;
18940 [\\/$]*)
18941 # Absolute (can't be DOS-style, as IFS=:)
c0d27fcc 18942 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
18943echo "$as_me: error: cannot find input file: $f" >&2;}
18944 { (exit 1); exit 1; }; }
18945 echo $f;;
18946 *) # Relative
18947 if test -f "$f"; then
18948 # Build tree
18949 echo $f
18950 elif test -f "$srcdir/$f"; then
18951 # Source tree
18952 echo $srcdir/$f
18953 else
18954 # /dev/null tree
c0d27fcc 18955 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
18956echo "$as_me: error: cannot find input file: $f" >&2;}
18957 { (exit 1); exit 1; }; }
18958 fi;;
18959 esac
18960 done` || { (exit 1); exit 1; }
c0d27fcc
MR
18961_ACEOF
18962cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18963 sed "$ac_vpsub
18964$extrasub
c0d27fcc
MR
18965_ACEOF
18966cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18967:t
18968/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18969s,@configure_input@,$configure_input,;t t
18970s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 18971s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 18972s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
18973s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
18974s,@builddir@,$ac_builddir,;t t
18975s,@abs_builddir@,$ac_abs_builddir,;t t
18976s,@top_builddir@,$ac_top_builddir,;t t
18977s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
18978s,@INSTALL@,$ac_INSTALL,;t t
18979" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
18980 rm -f $tmp/stdin
18981 if test x"$ac_file" != x-; then
18982 mv $tmp/out $ac_file
18983 else
18984 cat $tmp/out
18985 rm -f $tmp/out
18986 fi
18987
18988done
c0d27fcc
MR
18989_ACEOF
18990cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 18991
503d2be0
AS
18992#
18993# CONFIG_HEADER section.
18994#
ba4481b5
DL
18995
18996# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
18997# NAME is the cpp macro being defined and VALUE is the value it is being given.
18998#
18999# ac_d sets the value in "#define NAME VALUE" lines.
503d2be0
AS
19000ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
19001ac_dB='[ ].*$,\1#\2'
19002ac_dC=' '
19003ac_dD=',;t'
19004# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
19005ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
19006ac_uB='$,\1#\2define\3'
ba4481b5 19007ac_uC=' '
503d2be0 19008ac_uD=',;t'
ba4481b5 19009
503d2be0 19010for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 19011 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
19012 case $ac_file in
19013 - | *:- | *:-:* ) # input from stdin
19014 cat >$tmp/stdin
19015 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19016 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19017 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19018 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19019 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
19020 esac
19021
c0d27fcc 19022 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
19023echo "$as_me: creating $ac_file" >&6;}
19024
19025 # First look for the input files in the build tree, otherwise in the
19026 # src tree.
19027 ac_file_inputs=`IFS=:
19028 for f in $ac_file_in; do
19029 case $f in
19030 -) echo $tmp/stdin ;;
19031 [\\/$]*)
19032 # Absolute (can't be DOS-style, as IFS=:)
c0d27fcc 19033 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
19034echo "$as_me: error: cannot find input file: $f" >&2;}
19035 { (exit 1); exit 1; }; }
19036 echo $f;;
19037 *) # Relative
19038 if test -f "$f"; then
19039 # Build tree
19040 echo $f
19041 elif test -f "$srcdir/$f"; then
19042 # Source tree
19043 echo $srcdir/$f
19044 else
19045 # /dev/null tree
c0d27fcc 19046 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
19047echo "$as_me: error: cannot find input file: $f" >&2;}
19048 { (exit 1); exit 1; }; }
19049 fi;;
19050 esac
19051 done` || { (exit 1); exit 1; }
19052 # Remove the trailing spaces.
19053 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
19054
c0d27fcc 19055_ACEOF
503d2be0
AS
19056
19057# Transform confdefs.h into two sed scripts, `conftest.defines' and
19058# `conftest.undefs', that substitutes the proper values into
19059# config.h.in to produce config.h. The first handles `#define'
19060# templates, and the second `#undef' templates.
19061# And first: Protect against being on the right side of a sed subst in
19062# config.status. Protect against being in an unquoted here document
19063# in config.status.
19064rm -f conftest.defines conftest.undefs
19065# Using a here document instead of a string reduces the quoting nightmare.
19066# Putting comments in sed scripts is not portable.
19067#
19068# `end' is used to avoid that the second main sed command (meant for
19069# 0-ary CPP macros) applies to n-ary macro definitions.
19070# See the Autoconf documentation for `clear'.
c0d27fcc 19071cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
19072s/[\\&,]/\\&/g
19073s,[\\$`],\\&,g
19074t clear
19075: clear
c0d27fcc 19076s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0
AS
19077t end
19078s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
19079: end
c0d27fcc 19080_ACEOF
503d2be0
AS
19081# If some macros were called several times there might be several times
19082# the same #defines, which is useless. Nevertheless, we may not want to
19083# sort them, since we want the *last* AC-DEFINE to be honored.
19084uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
19085sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
19086rm -f confdef2sed.sed
ba4481b5
DL
19087
19088# This sed command replaces #undef with comments. This is necessary, for
19089# example, in the case of _POSIX_SOURCE, which is predefined and required
19090# on some systems where configure will not decide to define it.
c0d27fcc 19091cat >>conftest.undefs <<\_ACEOF
503d2be0 19092s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 19093_ACEOF
ba4481b5 19094
503d2be0
AS
19095# Break up conftest.defines because some shells have a limit on the size
19096# of here documents, and old seds have small limits too (100 cmds).
19097echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
6bae0ccf 19098echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
19099echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
19100echo ' :' >>$CONFIG_STATUS
19101rm -f conftest.tail
19102while grep . conftest.defines >/dev/null
19103do
19104 # Write a limited-size here document to $tmp/defines.sed.
19105 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
19106 # Speed up: don't consider the non `#define' lines.
19107 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
19108 # Work around the forget-to-reset-the-flag bug.
19109 echo 't clr' >>$CONFIG_STATUS
19110 echo ': clr' >>$CONFIG_STATUS
19111 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
19112 echo 'CEOF
19113 sed -f $tmp/defines.sed $tmp/in >$tmp/out
19114 rm -f $tmp/in
19115 mv $tmp/out $tmp/in
19116' >>$CONFIG_STATUS
19117 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
19118 rm -f conftest.defines
19119 mv conftest.tail conftest.defines
19120done
19121rm -f conftest.defines
6bae0ccf 19122echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 19123echo >>$CONFIG_STATUS
ba4481b5 19124
503d2be0
AS
19125# Break up conftest.undefs because some shells have a limit on the size
19126# of here documents, and old seds have small limits too (100 cmds).
19127echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 19128rm -f conftest.tail
503d2be0 19129while grep . conftest.undefs >/dev/null
ba4481b5 19130do
503d2be0
AS
19131 # Write a limited-size here document to $tmp/undefs.sed.
19132 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
19133 # Speed up: don't consider the non `#undef'
19134 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
19135 # Work around the forget-to-reset-the-flag bug.
19136 echo 't clr' >>$CONFIG_STATUS
19137 echo ': clr' >>$CONFIG_STATUS
19138 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 19139 echo 'CEOF
503d2be0
AS
19140 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
19141 rm -f $tmp/in
19142 mv $tmp/out $tmp/in
19143' >>$CONFIG_STATUS
19144 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
19145 rm -f conftest.undefs
19146 mv conftest.tail conftest.undefs
ba4481b5 19147done
503d2be0
AS
19148rm -f conftest.undefs
19149
c0d27fcc 19150cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
19151 # Let's still pretend it is `configure' which instantiates (i.e., don't
19152 # use $as_me), people would be surprised to read:
c0d27fcc 19153 # /* config.h. Generated by config.status. */
503d2be0 19154 if test x"$ac_file" = x-; then
c0d27fcc 19155 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 19156 else
c0d27fcc 19157 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
19158 fi
19159 cat $tmp/in >>$tmp/config.h
19160 rm -f $tmp/in
19161 if test x"$ac_file" != x-; then
cd958eb3 19162 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 19163 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
19164echo "$as_me: $ac_file is unchanged" >&6;}
19165 else
c0d27fcc
MR
19166 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19167$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
503d2be0
AS
19168 X"$ac_file" : 'X\(//\)[^/]' \| \
19169 X"$ac_file" : 'X\(//\)$' \| \
19170 X"$ac_file" : 'X\(/\)' \| \
19171 . : '\(.\)' 2>/dev/null ||
19172echo X"$ac_file" |
19173 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19174 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19175 /^X\(\/\/\)$/{ s//\1/; q; }
19176 /^X\(\/\).*/{ s//\1/; q; }
19177 s/.*/./; q'`
6bae0ccf
DL
19178 { if $as_mkdir_p; then
19179 mkdir -p "$ac_dir"
19180 else
19181 as_dir="$ac_dir"
19182 as_dirs=
19183 while test ! -d "$as_dir"; do
19184 as_dirs="$as_dir $as_dirs"
19185 as_dir=`(dirname "$as_dir") 2>/dev/null ||
19186$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19187 X"$as_dir" : 'X\(//\)[^/]' \| \
19188 X"$as_dir" : 'X\(//\)$' \| \
19189 X"$as_dir" : 'X\(/\)' \| \
19190 . : '\(.\)' 2>/dev/null ||
19191echo X"$as_dir" |
19192 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19193 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19194 /^X\(\/\/\)$/{ s//\1/; q; }
19195 /^X\(\/\).*/{ s//\1/; q; }
19196 s/.*/./; q'`
19197 done
19198 test ! -n "$as_dirs" || mkdir $as_dirs
19199 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
19200echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
19201 { (exit 1); exit 1; }; }; }
503d2be0 19202
503d2be0
AS
19203 rm -f $ac_file
19204 mv $tmp/config.h $ac_file
ba4481b5 19205 fi
503d2be0
AS
19206 else
19207 cat $tmp/config.h
19208 rm -f $tmp/config.h
ba4481b5 19209 fi
503d2be0 19210done
c0d27fcc
MR
19211_ACEOF
19212cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
19213
19214#
19215# CONFIG_COMMANDS section.
19216#
19217for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
19218 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
19219 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
19220 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
19221$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19222 X"$ac_dest" : 'X\(//\)[^/]' \| \
19223 X"$ac_dest" : 'X\(//\)$' \| \
19224 X"$ac_dest" : 'X\(/\)' \| \
19225 . : '\(.\)' 2>/dev/null ||
19226echo X"$ac_dest" |
19227 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19228 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19229 /^X\(\/\/\)$/{ s//\1/; q; }
19230 /^X\(\/\).*/{ s//\1/; q; }
19231 s/.*/./; q'`
19232 ac_builddir=.
19233
19234if test "$ac_dir" != .; then
19235 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19236 # A "../" for each directory in $ac_dir_suffix.
19237 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19238else
19239 ac_dir_suffix= ac_top_builddir=
19240fi
19241
19242case $srcdir in
19243 .) # No --srcdir option. We are building in place.
19244 ac_srcdir=.
19245 if test -z "$ac_top_builddir"; then
19246 ac_top_srcdir=.
19247 else
19248 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19249 fi ;;
19250 [\\/]* | ?:[\\/]* ) # Absolute path.
19251 ac_srcdir=$srcdir$ac_dir_suffix;
19252 ac_top_srcdir=$srcdir ;;
19253 *) # Relative path.
19254 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19255 ac_top_srcdir=$ac_top_builddir$srcdir ;;
19256esac
19257# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19258# absolute.
19259ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
6bae0ccf 19260ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
c0d27fcc
MR
19261ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19262ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
ba4481b5 19263
c0d27fcc
MR
19264
19265 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
19266echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
19267 case $ac_dest in
19268 default )
ba4481b5
DL
19269
19270### Make the necessary directories, if they don't exist.
19271for dir in etc lisp ; do
19272 test -d ${dir} || mkdir ${dir}
19273done
19274
19275# Build src/Makefile from ${srcdir}/src/Makefile.c
19276# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
19277# This must be done after src/config.h is built, since we rely on that file.
19278
19279# Now get this: Some word that is part of the ${srcdir} directory name
19280# or the ${configuration} value might, just might, happen to be an
19281# identifier like `sun4' or `i386' or something, and be predefined by
19282# the C preprocessor to some helpful value like 1, or maybe the empty
19283# string. Needless to say consequent macro substitutions are less
19284# than conducive to the makefile finding the correct directory.
19285undefs="`echo $top_srcdir $configuration $canonical |
19286sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
19287 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
19288`"
19289
19290echo creating src/epaths.h
4aa6b955 19291${MAKE-make} epaths-force
ba4481b5 19292
1c203d4c
DL
19293# As of 2000-11-19, newest development versions of GNU cpp preprocess
19294# `..' to `. .' unless invoked with -traditional
19295
d0e9bfd2 19296if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
19297 CPPFLAGS="$CPPFLAGS -traditional"
19298fi
19299
ba4481b5
DL
19300echo creating lib-src/Makefile
19301( cd lib-src
19302 rm -f junk.c junk1.c junk2.c
19303 sed -e '/start of cpp stuff/q' \
19304 < Makefile.c > junk1.c
19305 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 19306 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 19307 < Makefile.c > junk.c
503d2be0 19308 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
19309 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
19310 cat junk1.c junk2.c > Makefile.new
19311 rm -f junk.c junk1.c junk2.c
19312 chmod 444 Makefile.new
19313 mv -f Makefile.new Makefile
19314)
19315
19316echo creating src/Makefile
19317( cd src
19318 rm -f junk.c junk1.c junk2.c
19319 sed -e '/start of cpp stuff/q' \
19320 < Makefile.c > junk1.c
19321 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 19322 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 19323 < Makefile.c > junk.c
503d2be0 19324 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
19325 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
19326 cat junk1.c junk2.c > Makefile.new
19327 rm -f junk.c junk1.c junk2.c
19328 chmod 444 Makefile.new
19329 mv -f Makefile.new Makefile
19330)
19331
503d2be0 19332if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 19333 echo creating src/.gdbinit
503d2be0 19334 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
19335fi
19336
19337# This is how we know whether to re-run configure in certain cases.
19338touch src/config.stamp
19339
503d2be0
AS
19340 ;;
19341 esac
19342done
c0d27fcc 19343_ACEOF
503d2be0 19344
c0d27fcc 19345cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 19346
503d2be0 19347{ (exit 0); exit 0; }
c0d27fcc 19348_ACEOF
ba4481b5 19349chmod +x $CONFIG_STATUS
503d2be0
AS
19350ac_clean_files=$ac_clean_files_save
19351
c0d27fcc 19352
503d2be0
AS
19353# configure is writing to config.log, and then calls config.status.
19354# config.status does its own redirection, appending to config.log.
19355# Unfortunately, on DOS this fails, as config.log is still kept open
19356# by configure, so config.status won't be able to write to it; its
19357# output is simply discarded. So we exec the FD to /dev/null,
19358# effectively closing config.log, so it can be properly (re)opened and
19359# appended to by config.status. When coming back to configure, we
19360# need to make the FD available again.
19361if test "$no_create" != yes; then
19362 ac_cs_success=:
cd958eb3
MB
19363 ac_config_status_args=
19364 test "$silent" = yes &&
19365 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 19366 exec 5>/dev/null
cd958eb3 19367 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
19368 exec 5>>config.log
19369 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19370 # would make configure fail if this is the last instruction.
19371 $ac_cs_success || { (exit 1); exit 1; }
19372fi
f5f47add 19373
c0d27fcc 19374