(init_jpeg_functions, jpeg_resync_to_restart_wrapper):
[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 ;;
cc227489 2013 hppa*-hp-hpux10* )
ba4481b5
DL
2014 machine=hp800 opsys=hpux10
2015 ;;
cc227489
MB
2016 hppa*-hp-hpux1[1-9]* )
2017 machine=hp800 opsys=hpux11
2018 ;;
ba4481b5 2019
409d9577
GM
2020 hppa*-*-linux-gnu* )
2021 machine=hp800 opsys=gnu-linux
2022 ;;
2023
ba4481b5
DL
2024 ## HP 9000 series 700 and 800, running HP/UX
2025 hppa*-hp-hpux* )
2026 ## Cross-compilation? Nah!
2027 case "`uname -r`" in
2028 ## Someone's system reports A.B8.05 for this.
2029 ## I wonder what other possibilities there are.
2030 *.B8.* ) machine=hp800 opsys=hpux8 ;;
2031 *.08.* ) machine=hp800 opsys=hpux8 ;;
2032 *.09.* ) machine=hp800 opsys=hpux9 ;;
2033 *) machine=hp800 opsys=hpux10 ;;
2034 esac
2035 ;;
2036 hppa*-*-nextstep* )
2037 machine=hp800 opsys=nextstep
2038 ;;
2039
2040 ## Orion machines
2041 orion-orion-bsd* )
2042 machine=orion opsys=bsd4-2
2043 ;;
2044 clipper-orion-bsd* )
2045 machine=orion105 opsys=bsd4-2
2046 ;;
2047
2048 ## IBM machines
2049 i[3456]86-ibm-aix1.1* )
2050 machine=ibmps2-aix opsys=usg5-2-2
2051 ;;
2052 i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* )
2053 machine=ibmps2-aix opsys=usg5-3
2054 ;;
2055 i370-ibm-aix*)
2056 machine=ibm370aix opsys=usg5-3
2057 ;;
138f0859
GM
2058 s390-*-linux-gnu)
2059 machine=ibms390 opsys=gnu-linux
2060 ;;
ba4481b5
DL
2061 rs6000-ibm-aix3.1* | powerpc-ibm-aix3.1* )
2062 machine=ibmrs6000 opsys=aix3-1
2063 ;;
2064 rs6000-ibm-aix3.2.5 | powerpc-ibm-aix3.2.5 )
2065 machine=ibmrs6000 opsys=aix3-2-5
2066 ;;
2067 rs6000-ibm-aix4.1* | powerpc-ibm-aix4.1* )
2068 machine=ibmrs6000 opsys=aix4-1
2069 ;;
2070 rs6000-ibm-aix4.2* | powerpc-ibm-aix4.2* )
2071 machine=ibmrs6000 opsys=aix4-2
2072 ;;
d6b82250
EZ
2073 rs6000-ibm-aix5.1* | powerpc-ibm-aix5.1* )
2074 machine=ibmrs6000 opsys=aix4-2
2075 ;;
ba4481b5
DL
2076 rs6000-ibm-aix4.0* | powerpc-ibm-aix4.0* )
2077 machine=ibmrs6000 opsys=aix4
2078 ;;
2079 rs6000-ibm-aix4* | powerpc-ibm-aix4* )
2080 machine=ibmrs6000 opsys=aix4-1
2081 ;;
2082 rs6000-ibm-aix* | powerpc-ibm-aix* )
2083 machine=ibmrs6000 opsys=aix3-2
2084 ;;
2085 romp-ibm-bsd4.3* )
2086 machine=ibmrt opsys=bsd4-3
2087 ;;
2088 romp-ibm-bsd4.2* )
2089 machine=ibmrt opsys=bsd4-2
2090 ;;
2091 romp-ibm-aos4.3* )
2092 machine=ibmrt opsys=bsd4-3
2093 ;;
2094 romp-ibm-aos4.2* )
2095 machine=ibmrt opsys=bsd4-2
2096 ;;
2097 romp-ibm-aos* )
2098 machine=ibmrt opsys=bsd4-3
2099 ;;
2100 romp-ibm-bsd* )
2101 machine=ibmrt opsys=bsd4-3
2102 ;;
2103 romp-ibm-aix* )
2104 machine=ibmrt-aix opsys=usg5-2-2
2105 ;;
2106
2107 ## Integrated Solutions `Optimum V'
2108 m68*-isi-bsd4.2* )
2109 machine=isi-ov opsys=bsd4-2
2110 ;;
2111 m68*-isi-bsd4.3* )
2112 machine=isi-ov opsys=bsd4-3
2113 ;;
2114
2115 ## Intel 386 machines where we do care about the manufacturer
2116 i[3456]86-intsys-sysv* )
2117 machine=is386 opsys=usg5-2-2
2118 ;;
2119
2120 ## Prime EXL
2121 i[3456]86-prime-sysv* )
2122 machine=i386 opsys=usg5-3
2123 ;;
2124
2125 ## Sequent Symmetry running Dynix
2126 i[3456]86-sequent-bsd* )
2127 machine=symmetry opsys=bsd4-3
2128 ;;
2129
2130 ## Sequent Symmetry running ptx 4, which is a modified SVR4.
2131 i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* )
2132 machine=sequent-ptx opsys=ptx4
2133 NON_GNU_CPP=/lib/cpp
2134 ;;
2135
2136 ## Sequent Symmetry running DYNIX/ptx
2137 ## Use the old cpp rather than the newer ANSI one.
2138 i[3456]86-sequent-ptx* )
2139 machine=sequent-ptx opsys=ptx
2140 NON_GNU_CPP="/lib/cpp"
2141 ;;
2142
2143 ## ncr machine running svr4.3.
2144 i[3456]86-ncr-sysv4.3 )
2145 machine=ncr386 opsys=usg5-4-3
2146 ;;
2147
2148 ## Unspecified sysv on an ncr machine defaults to svr4.2.
2149 ## (Plain usg5-4 doesn't turn on POSIX signals, which we need.)
2150 i[3456]86-ncr-sysv* )
2151 machine=ncr386 opsys=usg5-4-2
2152 ;;
2153
2154 ## Intel Paragon OSF/1
2155 i860-intel-osf1* )
2156 machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp
2157 ;;
2158
2159 ## Intel 860
2160 i860-*-sysv4* )
2161 machine=i860 opsys=usg5-4
2162 NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc.
2163 NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion.
2164 ;;
2165
c76e04a8
GM
2166 ## Macintosh PowerPC
2167 powerpc*-*-linux-gnu* )
2168 machine=macppc opsys=gnu-linux
2169 ;;
2170
ba4481b5
DL
2171 ## Masscomp machines
2172 m68*-masscomp-rtu* )
2173 machine=masscomp opsys=rtu
2174 ;;
2175
2176 ## Megatest machines
2177 m68*-megatest-bsd* )
2178 machine=mega68 opsys=bsd4-2
2179 ;;
2180
2181 ## Workstations sold by MIPS
2182 ## This is not necessarily all workstations using the MIPS processor -
2183 ## Irises are produced by SGI, and DECstations by DEC.
2184
2185 ## etc/MACHINES lists mips.h and mips4.h as possible machine files,
2186 ## and usg5-2-2 and bsd4-3 as possible OS files. The only guidance
2187 ## it gives for choosing between the alternatives seems to be "Use
2188 ## -machine=mips4 for RISCOS version 4; use -opsystem=bsd4-3 with
2189 ## the BSD world." I'll assume that these are instructions for
2190 ## handling two odd situations, and that every other situation
2191 ## should use mips.h and usg5-2-2, they being listed first.
2192 mips-mips-usg* )
2193 machine=mips4
2194 ## Fall through to the general code at the bottom to decide on the OS.
2195 ;;
2196 mips-mips-riscos4* )
2197 machine=mips4 opsys=bsd4-3
2198 NON_GNU_CC="cc -systype bsd43"
2199 NON_GNU_CPP="cc -systype bsd43 -E"
2200 ;;
2201 mips-mips-riscos5* )
2202 machine=mips4 opsys=riscos5
2203 NON_GNU_CC="cc -systype bsd43"
2204 NON_GNU_CPP="cc -systype bsd43 -E"
2205 ;;
2206 mips-mips-bsd* )
2207 machine=mips opsys=bsd4-3
2208 ;;
2209 mips-mips-* )
2210 machine=mips opsys=usg5-2-2
2211 ;;
2212
2213 ## NeXT
2214 m68*-next-* | m68k-*-nextstep* )
2215 machine=m68k opsys=nextstep
2216 ;;
2217
2218 ## The complete machine from National Semiconductor
2219 ns32k-ns-genix* )
2220 machine=ns32000 opsys=usg5-2
2221 ;;
2222
2223 ## NCR machines
2224 m68*-ncr-sysv2* | m68*-ncr-sysvr2* )
2225 machine=tower32 opsys=usg5-2-2
2226 ;;
2227 m68*-ncr-sysv3* | m68*-ncr-sysvr3* )
2228 machine=tower32v3 opsys=usg5-3
2229 ;;
2230
2231 ## NEC EWS4800
2232 mips-nec-sysv4*)
2233 machine=ews4800 opsys=ux4800
2234 ;;
2235
2236 ## Nixdorf Targon 31
2237 m68*-nixdorf-sysv* )
2238 machine=targon31 opsys=usg5-2-2
2239 ;;
2240
2241 ## Nu (TI or LMI)
2242 m68*-nu-sysv* )
2243 machine=nu opsys=usg5-2
2244 ;;
2245
2246 ## Plexus
2247 m68*-plexus-sysv* )
2248 machine=plexus opsys=usg5-2
2249 ;;
2250
ba4481b5
DL
2251 ## Pyramid machines
2252 ## I don't really have any idea what sort of processor the Pyramid has,
2253 ## so I'm assuming it is its own architecture.
2254 pyramid-pyramid-bsd* )
2255 machine=pyramid opsys=bsd4-2
2256 ;;
2257
2258 ## Sequent Balance
2259 ns32k-sequent-bsd4.2* )
2260 machine=sequent opsys=bsd4-2
2261 ;;
2262 ns32k-sequent-bsd4.3* )
2263 machine=sequent opsys=bsd4-3
2264 ;;
2265
2266 ## Siemens Nixdorf
2267 mips-siemens-sysv* | mips-sni-sysv*)
2268 machine=mips-siemens opsys=usg5-4
2269 NON_GNU_CC=/usr/ccs/bin/cc
2270 NON_GNU_CPP=/usr/ccs/lib/cpp
2271 ;;
2272
2273 ## Silicon Graphics machines
2274 ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
2275 m68*-sgi-iris3.5* )
2276 machine=irist opsys=iris3-5
2277 ;;
2278 m68*-sgi-iris3.6* | m68*-sgi-iris*)
2279 machine=irist opsys=iris3-6
2280 ;;
2281 ## Iris 4D
2282 mips-sgi-irix3* )
2283 machine=iris4d opsys=irix3-3
2284 ;;
2285 mips-sgi-irix4* )
2286 machine=iris4d opsys=irix4-0
2287 ;;
2288 mips-sgi-irix6.5 )
2289 machine=iris4d opsys=irix6-5
946173ad
DL
2290 # Without defining _LANGUAGE_C, things get masked out in the headers
2291 # so that, for instance, grepping for `free' in stdlib.h fails and
2292 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
2293 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2294 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
ba4481b5
DL
2295 ;;
2296 mips-sgi-irix6* )
2297 machine=iris4d opsys=irix6-0
c4bb2108 2298 # It's not clear whether -D_LANGUAGE_C is necessary as it is for 6.5,
946173ad
DL
2299 # but presumably it does no harm.
2300 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
d42122a3 2301 # -32 probably isn't necessary in later v.6s -- anyone know which?
ba4481b5
DL
2302 NON_GCC_TEST_OPTIONS=-32
2303 ;;
2304 mips-sgi-irix5.[01]* )
2305 machine=iris4d opsys=irix5-0
2306 ;;
2307 mips-sgi-irix5* | mips-sgi-irix* )
2308 machine=iris4d opsys=irix5-2
2309 ;;
2310
2311 ## SONY machines
2312 m68*-sony-bsd4.2* )
2313 machine=news opsys=bsd4-2
2314 ;;
2315 m68*-sony-bsd4.3* )
2316 machine=news opsys=bsd4-3
2317 ;;
2318 m68*-sony-newsos3* | m68*-sony-news3*)
2319 machine=news opsys=bsd4-3
2320 ;;
2321 mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*)
2322 machine=news-risc opsys=bsd4-3
2323 ;;
2324 mips-sony-newsos6* )
2325 machine=news-r6 opsys=newsos6
2326 ;;
2327 mips-sony-news* )
2328 machine=news-risc opsys=newsos5
2329 ;;
2330
2331 ## Stride
2332 m68*-stride-sysv* )
2333 machine=stride opsys=usg5-2
2334 ;;
2335
2336 ## Suns
2337 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
2338 machine=sparc opsys=gnu-linux
2339 ;;
2340
d054101f 2341 *-auspex-sunos* | *-sun-sunos* | *-sun-bsd* | *-sun-solaris* \
ba4481b5
DL
2342 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \
2343 | rs6000-*-solaris2*)
2344 case "${canonical}" in
2345 m68*-sunos1* ) machine=sun1 ;;
2346 m68*-sunos2* ) machine=sun2 ;;
2347 m68* ) machine=sun3 ;;
2348 i[3456]86-sun-sunos[34]* ) machine=sun386 ;;
2349 i[3456]86-*-* ) machine=intel386 ;;
2350 powerpcle* ) machine=powerpcle ;;
2351 powerpc* | rs6000* ) machine=ibmrs6000 ;;
2352 sparc* ) machine=sparc ;;
2353 * ) unported=yes ;;
2354 esac
2355 case "${canonical}" in
2356 ## The Sun386 didn't get past 4.0.
2357 i[3456]86-*-sunos4 ) opsys=sunos4-0 ;;
2358 *-sunos4.0* ) opsys=sunos4-0 ;;
2359 *-sunos4.1.[3-9]*noshare )
2360 ## This name is sunos413 instead of sunos4-1-3
2361 ## to avoid a file name conflict on MSDOS.
2362 opsys=sunos413
2363 NON_GNU_CPP=/usr/lib/cpp
2364 NON_GCC_TEST_OPTIONS=-Bstatic
2365 GCC_TEST_OPTIONS=-static
2366 ;;
2367 *-sunos4.1.[3-9]* | *-sunos4shr*)
2368 opsys=sunos4shr
2369 NON_GNU_CPP=/usr/lib/cpp
2370 ;;
2371 *-sunos4* | *-sunos )
2372 opsys=sunos4-1
2373 NON_GCC_TEST_OPTIONS=-Bstatic
2374 GCC_TEST_OPTIONS=-static
2375 ;;
2376 *-sunos5.3* | *-solaris2.3* )
2377 opsys=sol2-3
2378 NON_GNU_CPP=/usr/ccs/lib/cpp
2379 ;;
2380 *-sunos5.4* | *-solaris2.4* )
2381 opsys=sol2-4
2382 NON_GNU_CPP=/usr/ccs/lib/cpp
2383 RANLIB="ar -ts"
2384 ;;
2385 *-sunos5.5* | *-solaris2.5* )
2386 opsys=sol2-5
2387 NON_GNU_CPP=/usr/ccs/lib/cpp
2388 RANLIB="ar -ts"
2389 ;;
8e967cf7
MR
2390 *-sunos5.6* | *-solaris2.6* )
2391 opsys=sol2-6
2392 NON_GNU_CPP=/usr/ccs/lib/cpp
2393 RANLIB="ar -ts"
2394 ;;
ba4481b5 2395 *-sunos5* | *-solaris* )
9e71690e 2396 opsys=sol2-6
ba4481b5
DL
2397 NON_GNU_CPP=/usr/ccs/lib/cpp
2398 ;;
2399 * ) opsys=bsd4-2 ;;
2400 esac
2401 ## Watch out for a compiler that we know will not work.
2402 case "${canonical}" in
2403 *-solaris* | *-sunos5* )
2404 if [ "x$CC" = x/usr/ucb/cc ]; then
2405 ## /usr/ucb/cc doesn't work;
2406 ## we should find some other compiler that does work.
2407 unset CC
2408 fi
2409 ;;
2410 *) ;;
2411 esac
2412 ;;
2413 sparc-*-nextstep* )
2414 machine=sparc opsys=nextstep
2415 ;;
2416
2417 ## Tadpole 68k
2418 m68*-tadpole-sysv* )
2419 machine=tad68k opsys=usg5-3
2420 ;;
2421
2422 ## Tahoe machines
2423 tahoe-tahoe-bsd4.2* )
2424 machine=tahoe opsys=bsd4-2
2425 ;;
2426 tahoe-tahoe-bsd4.3* )
2427 machine=tahoe opsys=bsd4-3
2428 ;;
2429
2430 ## Tandem Integrity S2
2431 mips-tandem-sysv* )
2432 machine=tandem-s2 opsys=usg5-3
2433 ;;
2434
2435 ## Tektronix XD88
2436 m88k-tektronix-sysv3* )
2437 machine=tekxd88 opsys=usg5-3
2438 ;;
2439
2440 ## Tektronix 16000 box (6130?)
2441 ns16k-tektronix-bsd* )
2442 machine=ns16000 opsys=bsd4-2
2443 ;;
2444 ## Tektronix 4300
2445 ## src/m/tek4300.h hints that this is a m68k machine.
2446 m68*-tektronix-bsd* )
2447 machine=tek4300 opsys=bsd4-3
2448 ;;
2449
2450 ## Titan P2 or P3
2451 ## We seem to have lost the machine-description file titan.h!
2452 titan-titan-sysv* )
2453 machine=titan opsys=usg5-3
2454 ;;
2455
2456 ## Ustation E30 (SS5E)
2457 m68*-unisys-uniplus* )
2458 machine=ustation opsystem=unipl5-2
2459 ;;
2460
2461 ## Vaxen.
2462 vax-dec-* )
2463 machine=vax
2464 case "${canonical}" in
2465 *-bsd4.1* ) opsys=bsd4-1 ;;
2466 *-bsd4.2* | *-ultrix[0-3].* | *-ultrix4.0* ) opsys=bsd4-2 ;;
2467 *-bsd4.3* | *-ultrix* ) opsys=bsd4-3 ;;
2468 *-sysv[01]* | *-sysvr[01]* ) opsys=usg5-0 ;;
2469 *-sysv2* | *-sysvr2* ) opsys=usg5-2 ;;
2470 *-vms* ) opsys=vms ;;
2471 * ) unported=yes
2472 esac
2473 ;;
2474
2475 ## Whitechapel MG1
2476 ns16k-whitechapel-* )
2477 machine=mg1
2478 ## We don't know what sort of OS runs on these; we'll let the
2479 ## operating system guessing code below try.
2480 ;;
2481
2482 ## Wicat
2483 m68*-wicat-sysv* )
2484 machine=wicat opsys=usg5-2
2485 ;;
2486
f4988be7
GM
2487 ## IA-64
2488 ia64*-*-linux* )
2489 machine=ia64 opsys=gnu-linux
2490 ;;
2491
ba4481b5
DL
2492 ## Intel 386 machines where we don't care about the manufacturer
2493 i[3456]86-*-* )
2494 machine=intel386
2495 case "${canonical}" in
9f817ea4 2496 *-lynxos* ) opsys=lynxos ;;
ba4481b5
DL
2497 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2498 *-isc2.2* ) opsys=isc2-2 ;;
2499 *-isc4.0* ) opsys=isc4-0 ;;
2500 *-isc4.* ) opsys=isc4-1
2501 GCC_TEST_OPTIONS=-posix
2502 NON_GCC_TEST_OPTIONS=-Xp
2503 ;;
2504 *-isc* ) opsys=isc3-0 ;;
2505 *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;;
2506 *-esix* ) opsys=esix ;;
2507 *-xenix* ) opsys=xenix ;;
2508 *-linux-gnu* ) opsys=gnu-linux ;;
2509 *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;;
503d2be0 2510 *-sco3.2v5* ) opsys=sco5
ba4481b5
DL
2511 NON_GNU_CPP=/lib/cpp
2512 # Prevent -belf from being passed to $CPP.
2513 # /lib/cpp does not accept it.
2514 OVERRIDE_CPPFLAGS=" "
2515 ;;
2516 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
2517 *-386bsd* ) opsys=386bsd ;;
ba4481b5
DL
2518 *-nextstep* ) opsys=nextstep ;;
2519 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2520 esac
2521 ;;
2522
2523 ## m68k Linux-based GNU system
2524 m68k-*-linux-gnu* )
2525 machine=m68k opsys=gnu-linux
2526 ;;
2527
2528 ## Mips Linux-based GNU system
cd958eb3 2529 mips-*-linux-gnu* | mipsel-*-linux-gnu* )
ba4481b5
DL
2530 machine=mips opsys=gnu-linux
2531 ;;
2532
2533 ## UXP/DS
2534 sparc-fujitsu-sysv4* )
2535 machine=sparc opsys=uxpds
2536 NON_GNU_CPP=/usr/ccs/lib/cpp
2537 RANLIB="ar -ts"
2538 ;;
2539
2540 ## UXP/V
2541 f301-fujitsu-uxpv4.1)
2542 machine=f301 opsys=uxpv
2543 ;;
2544
e0f712ba
AC
2545 ## Darwin / Mac OS X
2546 powerpc-apple-darwin* )
2547 machine=powermac opsys=darwin
2548 # Define CPP as follows to make autoconf work correctly.
2549 CPP="cc -E -traditional-cpp"
2550 ;;
2551
598a2813
AS
2552 ## AMD x86-64 Linux-based GNU system
2553 x86_64-*-linux-gnu* )
24b01ec4 2554 machine=amdx86-64 opsys=gnu-linux
598a2813
AS
2555 ;;
2556
ba4481b5
DL
2557 * )
2558 unported=yes
2559 ;;
2560esac
2561
2562### If the code above didn't choose an operating system, just choose
2563### an operating system based on the configuration name. You really
2564### only want to use this when you have no idea what the right
2565### operating system is; if you know what operating systems a machine
2566### runs, it's cleaner to make it explicit in the case statement
2567### above.
2568if test x"${opsys}" = x; then
2569 case "${canonical}" in
2570 *-gnu* ) opsys=gnu ;;
2571 *-bsd4.[01] ) opsys=bsd4-1 ;;
2572 *-bsd4.2 ) opsys=bsd4-2 ;;
2573 *-bsd4.3 ) opsys=bsd4-3 ;;
2574 *-sysv0 | *-sysvr0 ) opsys=usg5-0 ;;
2575 *-sysv2 | *-sysvr2 ) opsys=usg5-2 ;;
2576 *-sysv2.2 | *-sysvr2.2 ) opsys=usg5-2-2 ;;
2577 *-sysv3* | *-sysvr3* ) opsys=usg5-3 ;;
2578 *-sysv4.2uw* ) opsys=unixware ;;
2579 *-sysv4.1* | *-sysvr4.1* )
2580 NON_GNU_CPP=/usr/lib/cpp
2581 opsys=usg5-4 ;;
2582 *-sysv4.[2-9]* | *-sysvr4.[2-9]* )
2583 if [ x$NON_GNU_CPP = x ]; then
2584 if [ -f /usr/ccs/lib/cpp ]; then
2585 NON_GNU_CPP=/usr/ccs/lib/cpp
2586 else
2587 NON_GNU_CPP=/lib/cpp
2588 fi
2589 fi
2590 opsys=usg5-4-2 ;;
2591 *-sysv4* | *-sysvr4* ) opsys=usg5-4 ;;
2592 * )
2593 unported=yes
2594 ;;
2595 esac
2596fi
2597
c0d27fcc 2598
22044edf 2599
ba4481b5 2600if test $unported = yes; then
c0d27fcc 2601 { { echo "$as_me:$LINENO: error: Emacs hasn't been ported to \`${canonical}' systems.
503d2be0
AS
2602Check \`etc/MACHINES' for recognized configuration names." >&5
2603echo "$as_me: error: Emacs hasn't been ported to \`${canonical}' systems.
2604Check \`etc/MACHINES' for recognized configuration names." >&2;}
2605 { (exit 1); exit 1; }; }
ba4481b5
DL
2606fi
2607
2608machfile="m/${machine}.h"
2609opsysfile="s/${opsys}.h"
2610
c0d27fcc 2611
ba4481b5
DL
2612#### Choose a compiler.
2613test -n "$CC" && cc_specified=yes
2614
2615# Save the value of CFLAGS that the user specified.
2616SPECIFIED_CFLAGS="$CFLAGS"
2617
2618case ${with_gcc} in
2619 "yes" ) CC="gcc" GCC=yes ;;
2620 "no" ) : ${CC=cc} ;;
503d2be0
AS
2621 * )
2622esac
2623ac_ext=c
2624ac_cpp='$CPP $CPPFLAGS'
2625ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2626ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2627ac_compiler_gnu=$ac_cv_c_compiler_gnu
2628if test -n "$ac_tool_prefix"; then
2629 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2630set dummy ${ac_tool_prefix}gcc; ac_word=$2
c0d27fcc 2631echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2632echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2633if test "${ac_cv_prog_CC+set}" = set; then
2634 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2635else
2636 if test -n "$CC"; then
2637 ac_cv_prog_CC="$CC" # Let the user override the test.
2638else
c0d27fcc
MR
2639as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2640for as_dir in $PATH
2641do
2642 IFS=$as_save_IFS
2643 test -z "$as_dir" && as_dir=.
2644 for ac_exec_ext in '' $ac_executable_extensions; do
2645 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2646 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2647 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2648 break 2
2649 fi
2650done
503d2be0
AS
2651done
2652
ba4481b5
DL
2653fi
2654fi
503d2be0 2655CC=$ac_cv_prog_CC
ba4481b5 2656if test -n "$CC"; then
c0d27fcc 2657 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2658echo "${ECHO_T}$CC" >&6
2659else
c0d27fcc 2660 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2661echo "${ECHO_T}no" >&6
2662fi
2663
2664fi
2665if test -z "$ac_cv_prog_CC"; then
2666 ac_ct_CC=$CC
2667 # Extract the first word of "gcc", so it can be a program name with args.
2668set dummy gcc; ac_word=$2
c0d27fcc 2669echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2670echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2671if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2672 echo $ECHO_N "(cached) $ECHO_C" >&6
2673else
2674 if test -n "$ac_ct_CC"; then
2675 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2676else
c0d27fcc
MR
2677as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2678for as_dir in $PATH
2679do
2680 IFS=$as_save_IFS
2681 test -z "$as_dir" && as_dir=.
2682 for ac_exec_ext in '' $ac_executable_extensions; do
2683 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2684 ac_cv_prog_ac_ct_CC="gcc"
2685 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2686 break 2
2687 fi
2688done
503d2be0
AS
2689done
2690
2691fi
2692fi
2693ac_ct_CC=$ac_cv_prog_ac_ct_CC
2694if test -n "$ac_ct_CC"; then
c0d27fcc 2695 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0 2696echo "${ECHO_T}$ac_ct_CC" >&6
ba4481b5 2697else
c0d27fcc 2698 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2699echo "${ECHO_T}no" >&6
2700fi
2701
2702 CC=$ac_ct_CC
2703else
2704 CC="$ac_cv_prog_CC"
ba4481b5
DL
2705fi
2706
2707if test -z "$CC"; then
503d2be0
AS
2708 if test -n "$ac_tool_prefix"; then
2709 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2710set dummy ${ac_tool_prefix}cc; ac_word=$2
c0d27fcc 2711echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2712echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2713if test "${ac_cv_prog_CC+set}" = set; then
2714 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
2715else
2716 if test -n "$CC"; then
2717 ac_cv_prog_CC="$CC" # Let the user override the test.
2718else
c0d27fcc
MR
2719as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2720for as_dir in $PATH
2721do
2722 IFS=$as_save_IFS
2723 test -z "$as_dir" && as_dir=.
2724 for ac_exec_ext in '' $ac_executable_extensions; do
2725 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2726 ac_cv_prog_CC="${ac_tool_prefix}cc"
2727 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2728 break 2
2729 fi
2730done
503d2be0
AS
2731done
2732
2733fi
2734fi
2735CC=$ac_cv_prog_CC
2736if test -n "$CC"; then
c0d27fcc 2737 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0
AS
2738echo "${ECHO_T}$CC" >&6
2739else
c0d27fcc 2740 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2741echo "${ECHO_T}no" >&6
2742fi
2743
2744fi
2745if test -z "$ac_cv_prog_CC"; then
2746 ac_ct_CC=$CC
2747 # Extract the first word of "cc", so it can be a program name with args.
2748set dummy cc; ac_word=$2
c0d27fcc 2749echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2750echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2751if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2752 echo $ECHO_N "(cached) $ECHO_C" >&6
2753else
2754 if test -n "$ac_ct_CC"; then
2755 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2756else
c0d27fcc
MR
2757as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2758for as_dir in $PATH
2759do
2760 IFS=$as_save_IFS
2761 test -z "$as_dir" && as_dir=.
2762 for ac_exec_ext in '' $ac_executable_extensions; do
2763 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2764 ac_cv_prog_ac_ct_CC="cc"
2765 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2766 break 2
2767 fi
2768done
503d2be0
AS
2769done
2770
2771fi
2772fi
2773ac_ct_CC=$ac_cv_prog_ac_ct_CC
2774if test -n "$ac_ct_CC"; then
c0d27fcc 2775 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2776echo "${ECHO_T}$ac_ct_CC" >&6
2777else
c0d27fcc 2778 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2779echo "${ECHO_T}no" >&6
2780fi
2781
2782 CC=$ac_ct_CC
2783else
2784 CC="$ac_cv_prog_CC"
2785fi
2786
2787fi
2788if test -z "$CC"; then
2789 # Extract the first word of "cc", so it can be a program name with args.
2790set dummy cc; ac_word=$2
c0d27fcc 2791echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2792echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2793if test "${ac_cv_prog_CC+set}" = set; then
2794 echo $ECHO_N "(cached) $ECHO_C" >&6
2795else
2796 if test -n "$CC"; then
2797 ac_cv_prog_CC="$CC" # Let the user override the test.
2798else
2799 ac_prog_rejected=no
c0d27fcc
MR
2800as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2801for as_dir in $PATH
2802do
2803 IFS=$as_save_IFS
2804 test -z "$as_dir" && as_dir=.
2805 for ac_exec_ext in '' $ac_executable_extensions; do
2806 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2807 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2808 ac_prog_rejected=yes
2809 continue
2810 fi
2811 ac_cv_prog_CC="cc"
2812 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2813 break 2
2814 fi
2815done
503d2be0
AS
2816done
2817
ba4481b5
DL
2818if test $ac_prog_rejected = yes; then
2819 # We found a bogon in the path, so make sure we never use it.
2820 set dummy $ac_cv_prog_CC
2821 shift
503d2be0 2822 if test $# != 0; then
ba4481b5
DL
2823 # We chose a different compiler from the bogus one.
2824 # However, it has the same basename, so the bogon will be chosen
2825 # first if we set CC to just the basename; use the full file name.
2826 shift
6bae0ccf 2827 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
ba4481b5
DL
2828 fi
2829fi
2830fi
2831fi
503d2be0 2832CC=$ac_cv_prog_CC
ba4481b5 2833if test -n "$CC"; then
c0d27fcc 2834 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2835echo "${ECHO_T}$CC" >&6
ba4481b5 2836else
c0d27fcc 2837 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2838echo "${ECHO_T}no" >&6
ba4481b5
DL
2839fi
2840
503d2be0
AS
2841fi
2842if test -z "$CC"; then
2843 if test -n "$ac_tool_prefix"; then
2844 for ac_prog in cl
2845 do
2846 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2847set dummy $ac_tool_prefix$ac_prog; ac_word=$2
c0d27fcc 2848echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2849echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2850if test "${ac_cv_prog_CC+set}" = set; then
2851 echo $ECHO_N "(cached) $ECHO_C" >&6
c4bb2108
DL
2852else
2853 if test -n "$CC"; then
2854 ac_cv_prog_CC="$CC" # Let the user override the test.
2855else
c0d27fcc
MR
2856as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2857for as_dir in $PATH
2858do
2859 IFS=$as_save_IFS
2860 test -z "$as_dir" && as_dir=.
2861 for ac_exec_ext in '' $ac_executable_extensions; do
2862 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2863 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2864 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2865 break 2
2866 fi
2867done
503d2be0
AS
2868done
2869
c4bb2108
DL
2870fi
2871fi
503d2be0 2872CC=$ac_cv_prog_CC
c4bb2108 2873if test -n "$CC"; then
c0d27fcc 2874 echo "$as_me:$LINENO: result: $CC" >&5
503d2be0 2875echo "${ECHO_T}$CC" >&6
c4bb2108 2876else
c0d27fcc 2877 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
2878echo "${ECHO_T}no" >&6
2879fi
2880
2881 test -n "$CC" && break
2882 done
2883fi
2884if test -z "$CC"; then
2885 ac_ct_CC=$CC
2886 for ac_prog in cl
2887do
2888 # Extract the first word of "$ac_prog", so it can be a program name with args.
2889set dummy $ac_prog; ac_word=$2
c0d27fcc 2890echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
2891echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2892if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2893 echo $ECHO_N "(cached) $ECHO_C" >&6
2894else
2895 if test -n "$ac_ct_CC"; then
2896 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2897else
c0d27fcc
MR
2898as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2899for as_dir in $PATH
2900do
2901 IFS=$as_save_IFS
2902 test -z "$as_dir" && as_dir=.
2903 for ac_exec_ext in '' $ac_executable_extensions; do
2904 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2905 ac_cv_prog_ac_ct_CC="$ac_prog"
2906 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2907 break 2
2908 fi
2909done
503d2be0
AS
2910done
2911
c4bb2108 2912fi
503d2be0
AS
2913fi
2914ac_ct_CC=$ac_cv_prog_ac_ct_CC
2915if test -n "$ac_ct_CC"; then
c0d27fcc 2916 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
503d2be0
AS
2917echo "${ECHO_T}$ac_ct_CC" >&6
2918else
c0d27fcc 2919 echo "$as_me:$LINENO: result: no" >&5
503d2be0 2920echo "${ECHO_T}no" >&6
ba4481b5
DL
2921fi
2922
503d2be0
AS
2923 test -n "$ac_ct_CC" && break
2924done
ba4481b5 2925
503d2be0
AS
2926 CC=$ac_ct_CC
2927fi
2928
2929fi
ba4481b5 2930
c0d27fcc 2931
cd958eb3
MB
2932test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2933See \`config.log' for more details." >&5
2934echo "$as_me: error: no acceptable C compiler found in \$PATH
2935See \`config.log' for more details." >&2;}
503d2be0 2936 { (exit 1); exit 1; }; }
c4bb2108 2937
503d2be0 2938# Provide some information about the compiler.
c0d27fcc 2939echo "$as_me:$LINENO:" \
503d2be0
AS
2940 "checking for C compiler version" >&5
2941ac_compiler=`set X $ac_compile; echo $2`
c0d27fcc 2942{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
503d2be0
AS
2943 (eval $ac_compiler --version </dev/null >&5) 2>&5
2944 ac_status=$?
c0d27fcc 2945 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 2946 (exit $ac_status); }
c0d27fcc 2947{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
503d2be0
AS
2948 (eval $ac_compiler -v </dev/null >&5) 2>&5
2949 ac_status=$?
c0d27fcc 2950 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 2951 (exit $ac_status); }
c0d27fcc 2952{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
503d2be0
AS
2953 (eval $ac_compiler -V </dev/null >&5) 2>&5
2954 ac_status=$?
c0d27fcc 2955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
2956 (exit $ac_status); }
2957
2958cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 2959#line $LINENO "configure"
cd958eb3
MB
2960/* confdefs.h. */
2961_ACEOF
2962cat confdefs.h >>conftest.$ac_ext
2963cat >>conftest.$ac_ext <<_ACEOF
2964/* end confdefs.h. */
c4bb2108 2965
503d2be0
AS
2966int
2967main ()
2968{
2969
2970 ;
2971 return 0;
2972}
2973_ACEOF
2974ac_clean_files_save=$ac_clean_files
cd958eb3 2975ac_clean_files="$ac_clean_files a.out a.exe b.out"
503d2be0
AS
2976# Try to create an executable without -o first, disregard a.out.
2977# It will help us diagnose broken compilers, and finding out an intuition
2978# of exeext.
c0d27fcc 2979echo "$as_me:$LINENO: checking for C compiler default output" >&5
503d2be0
AS
2980echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2981ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
c0d27fcc 2982if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
503d2be0
AS
2983 (eval $ac_link_default) 2>&5
2984 ac_status=$?
c0d27fcc 2985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
2986 (exit $ac_status); }; then
2987 # Find the output, starting from the most likely. This scheme is
2988# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2989# resort.
c0d27fcc
MR
2990
2991# Be careful to initialize this variable, since it used to be cached.
2992# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2993ac_cv_exeext=
cd958eb3
MB
2994# b.out is created by i960 compilers.
2995for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2996do
6bae0ccf 2997 test -f "$ac_file" || continue
503d2be0 2998 case $ac_file in
cd958eb3
MB
2999 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
3000 ;;
3001 conftest.$ac_ext )
3002 # This is the source file.
3003 ;;
3004 [ab].out )
3005 # We found the default executable, but exeext='' is most
3006 # certainly right.
3007 break;;
3008 *.* )
3009 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3010 # FIXME: I believe we export ac_cv_exeext for Libtool,
3011 # but it would be cool to find out if it's true. Does anybody
3012 # maintain Libtool? --akim.
3013 export ac_cv_exeext
3014 break;;
3015 * )
3016 break;;
503d2be0
AS
3017 esac
3018done
3019else
3020 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3021sed 's/^/| /' conftest.$ac_ext >&5
3022
6bae0ccf 3023{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
cd958eb3 3024See \`config.log' for more details." >&5
6bae0ccf 3025echo "$as_me: error: C compiler cannot create executables
cd958eb3 3026See \`config.log' for more details." >&2;}
503d2be0
AS
3027 { (exit 77); exit 77; }; }
3028fi
3029
3030ac_exeext=$ac_cv_exeext
c0d27fcc 3031echo "$as_me:$LINENO: result: $ac_file" >&5
503d2be0
AS
3032echo "${ECHO_T}$ac_file" >&6
3033
3034# Check the compiler produces executables we can run. If not, either
3035# the compiler is broken, or we cross compile.
c0d27fcc 3036echo "$as_me:$LINENO: checking whether the C compiler works" >&5
503d2be0
AS
3037echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
3038# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3039# If not cross compiling, check that we can run a simple program.
3040if test "$cross_compiling" != yes; then
3041 if { ac_try='./$ac_file'
c0d27fcc 3042 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3043 (eval $ac_try) 2>&5
3044 ac_status=$?
c0d27fcc 3045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3046 (exit $ac_status); }; }; then
3047 cross_compiling=no
ba4481b5 3048 else
503d2be0
AS
3049 if test "$cross_compiling" = maybe; then
3050 cross_compiling=yes
3051 else
c0d27fcc 3052 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
cd958eb3
MB
3053If you meant to cross compile, use \`--host'.
3054See \`config.log' for more details." >&5
503d2be0 3055echo "$as_me: error: cannot run C compiled programs.
cd958eb3
MB
3056If you meant to cross compile, use \`--host'.
3057See \`config.log' for more details." >&2;}
503d2be0
AS
3058 { (exit 1); exit 1; }; }
3059 fi
ba4481b5 3060 fi
503d2be0 3061fi
c0d27fcc 3062echo "$as_me:$LINENO: result: yes" >&5
503d2be0
AS
3063echo "${ECHO_T}yes" >&6
3064
cd958eb3 3065rm -f a.out a.exe conftest$ac_cv_exeext b.out
503d2be0
AS
3066ac_clean_files=$ac_clean_files_save
3067# Check the compiler produces executables we can run. If not, either
3068# the compiler is broken, or we cross compile.
c0d27fcc 3069echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
503d2be0 3070echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
c0d27fcc 3071echo "$as_me:$LINENO: result: $cross_compiling" >&5
503d2be0
AS
3072echo "${ECHO_T}$cross_compiling" >&6
3073
c0d27fcc
MR
3074echo "$as_me:$LINENO: checking for suffix of executables" >&5
3075echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
3076if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
3077 (eval $ac_link) 2>&5
3078 ac_status=$?
c0d27fcc 3079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3080 (exit $ac_status); }; then
3081 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3082# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3083# work properly (i.e., refer to `conftest.exe'), while it won't with
3084# `rm'.
6bae0ccf
DL
3085for ac_file in conftest.exe conftest conftest.*; do
3086 test -f "$ac_file" || continue
503d2be0 3087 case $ac_file in
6bae0ccf 3088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
503d2be0
AS
3089 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3090 export ac_cv_exeext
3091 break;;
3092 * ) break;;
3093 esac
3094done
ba4481b5 3095else
cd958eb3
MB
3096 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3097See \`config.log' for more details." >&5
3098echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3099See \`config.log' for more details." >&2;}
503d2be0 3100 { (exit 1); exit 1; }; }
ba4481b5 3101fi
ba4481b5 3102
503d2be0 3103rm -f conftest$ac_cv_exeext
c0d27fcc 3104echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
503d2be0 3105echo "${ECHO_T}$ac_cv_exeext" >&6
ba4481b5 3106
503d2be0
AS
3107rm -f conftest.$ac_ext
3108EXEEXT=$ac_cv_exeext
3109ac_exeext=$EXEEXT
c0d27fcc
MR
3110echo "$as_me:$LINENO: checking for suffix of object files" >&5
3111echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
503d2be0
AS
3112if test "${ac_cv_objext+set}" = set; then
3113 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3114else
503d2be0 3115 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3116#line $LINENO "configure"
cd958eb3
MB
3117/* confdefs.h. */
3118_ACEOF
3119cat confdefs.h >>conftest.$ac_ext
3120cat >>conftest.$ac_ext <<_ACEOF
3121/* end confdefs.h. */
ba4481b5 3122
503d2be0
AS
3123int
3124main ()
3125{
ba4481b5 3126
503d2be0
AS
3127 ;
3128 return 0;
3129}
3130_ACEOF
3131rm -f conftest.o conftest.obj
c0d27fcc 3132if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3133 (eval $ac_compile) 2>&5
3134 ac_status=$?
c0d27fcc 3135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3136 (exit $ac_status); }; then
3137 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
3138 case $ac_file in
6bae0ccf 3139 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
503d2be0
AS
3140 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3141 break;;
3142 esac
3143done
c4bb2108 3144else
503d2be0 3145 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3146sed 's/^/| /' conftest.$ac_ext >&5
3147
3148{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3149See \`config.log' for more details." >&5
3150echo "$as_me: error: cannot compute suffix of object files: cannot compile
3151See \`config.log' for more details." >&2;}
503d2be0 3152 { (exit 1); exit 1; }; }
c4bb2108
DL
3153fi
3154
503d2be0
AS
3155rm -f conftest.$ac_cv_objext conftest.$ac_ext
3156fi
c0d27fcc 3157echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
503d2be0
AS
3158echo "${ECHO_T}$ac_cv_objext" >&6
3159OBJEXT=$ac_cv_objext
3160ac_objext=$OBJEXT
c0d27fcc 3161echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
503d2be0
AS
3162echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
3163if test "${ac_cv_c_compiler_gnu+set}" = set; then
3164 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3165else
503d2be0 3166 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3167#line $LINENO "configure"
cd958eb3
MB
3168/* confdefs.h. */
3169_ACEOF
3170cat confdefs.h >>conftest.$ac_ext
3171cat >>conftest.$ac_ext <<_ACEOF
3172/* end confdefs.h. */
503d2be0
AS
3173
3174int
3175main ()
3176{
3177#ifndef __GNUC__
3178 choke me
3179#endif
3180
3181 ;
3182 return 0;
3183}
3184_ACEOF
3185rm -f conftest.$ac_objext
c0d27fcc 3186if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3187 (eval $ac_compile) 2>&5
3188 ac_status=$?
c0d27fcc 3189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3190 (exit $ac_status); } &&
3191 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3192 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3193 (eval $ac_try) 2>&5
3194 ac_status=$?
c0d27fcc 3195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3196 (exit $ac_status); }; }; then
3197 ac_compiler_gnu=yes
3198else
3199 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3200sed 's/^/| /' conftest.$ac_ext >&5
3201
503d2be0
AS
3202ac_compiler_gnu=no
3203fi
3204rm -f conftest.$ac_objext conftest.$ac_ext
3205ac_cv_c_compiler_gnu=$ac_compiler_gnu
3206
3207fi
c0d27fcc 3208echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
503d2be0
AS
3209echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
3210GCC=`test $ac_compiler_gnu = yes && echo yes`
3211ac_test_CFLAGS=${CFLAGS+set}
3212ac_save_CFLAGS=$CFLAGS
3213CFLAGS="-g"
c0d27fcc 3214echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
503d2be0
AS
3215echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
3216if test "${ac_cv_prog_cc_g+set}" = set; then
3217 echo $ECHO_N "(cached) $ECHO_C" >&6
3218else
3219 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3220#line $LINENO "configure"
cd958eb3
MB
3221/* confdefs.h. */
3222_ACEOF
3223cat confdefs.h >>conftest.$ac_ext
3224cat >>conftest.$ac_ext <<_ACEOF
3225/* end confdefs.h. */
503d2be0
AS
3226
3227int
3228main ()
3229{
3230
3231 ;
3232 return 0;
3233}
3234_ACEOF
3235rm -f conftest.$ac_objext
c0d27fcc 3236if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3237 (eval $ac_compile) 2>&5
3238 ac_status=$?
c0d27fcc 3239 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3240 (exit $ac_status); } &&
3241 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3242 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3243 (eval $ac_try) 2>&5
3244 ac_status=$?
c0d27fcc 3245 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 3246 (exit $ac_status); }; }; then
ba4481b5
DL
3247 ac_cv_prog_cc_g=yes
3248else
503d2be0 3249 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3250sed 's/^/| /' conftest.$ac_ext >&5
3251
503d2be0 3252ac_cv_prog_cc_g=no
ba4481b5 3253fi
503d2be0 3254rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 3255fi
c0d27fcc 3256echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
503d2be0 3257echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
c4bb2108 3258if test "$ac_test_CFLAGS" = set; then
503d2be0 3259 CFLAGS=$ac_save_CFLAGS
c4bb2108
DL
3260elif test $ac_cv_prog_cc_g = yes; then
3261 if test "$GCC" = yes; then
ba4481b5
DL
3262 CFLAGS="-g -O2"
3263 else
c4bb2108 3264 CFLAGS="-g"
ba4481b5 3265 fi
22afa6e8 3266else
c4bb2108
DL
3267 if test "$GCC" = yes; then
3268 CFLAGS="-O2"
3269 else
3270 CFLAGS=
3271 fi
ba4481b5 3272fi
6bae0ccf
DL
3273echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
3274echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
3275if test "${ac_cv_prog_cc_stdc+set}" = set; then
3276 echo $ECHO_N "(cached) $ECHO_C" >&6
3277else
3278 ac_cv_prog_cc_stdc=no
3279ac_save_CC=$CC
3280cat >conftest.$ac_ext <<_ACEOF
3281#line $LINENO "configure"
cd958eb3
MB
3282/* confdefs.h. */
3283_ACEOF
3284cat confdefs.h >>conftest.$ac_ext
3285cat >>conftest.$ac_ext <<_ACEOF
3286/* end confdefs.h. */
6bae0ccf
DL
3287#include <stdarg.h>
3288#include <stdio.h>
3289#include <sys/types.h>
3290#include <sys/stat.h>
3291/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3292struct buf { int x; };
3293FILE * (*rcsopen) (struct buf *, struct stat *, int);
3294static char *e (p, i)
3295 char **p;
3296 int i;
3297{
3298 return p[i];
3299}
3300static char *f (char * (*g) (char **, int), char **p, ...)
3301{
3302 char *s;
3303 va_list v;
3304 va_start (v,p);
3305 s = g (p, va_arg (v,int));
3306 va_end (v);
3307 return s;
3308}
3309int test (int i, double x);
3310struct s1 {int (*f) (int a);};
3311struct s2 {int (*f) (double a);};
3312int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3313int argc;
3314char **argv;
3315int
3316main ()
3317{
3318return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3319 ;
3320 return 0;
3321}
3322_ACEOF
3323# Don't try gcc -ansi; that turns off useful extensions and
3324# breaks some systems' header files.
3325# AIX -qlanglvl=ansi
3326# Ultrix and OSF/1 -std1
3327# HP-UX 10.20 and later -Ae
3328# HP-UX older versions -Aa -D_HPUX_SOURCE
3329# SVR4 -Xc -D__EXTENSIONS__
3330for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3331do
3332 CC="$ac_save_CC $ac_arg"
3333 rm -f conftest.$ac_objext
3334if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3335 (eval $ac_compile) 2>&5
3336 ac_status=$?
3337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3338 (exit $ac_status); } &&
3339 { ac_try='test -s conftest.$ac_objext'
3340 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3341 (eval $ac_try) 2>&5
3342 ac_status=$?
3343 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3344 (exit $ac_status); }; }; then
3345 ac_cv_prog_cc_stdc=$ac_arg
3346break
3347else
3348 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3349sed 's/^/| /' conftest.$ac_ext >&5
3350
6bae0ccf
DL
3351fi
3352rm -f conftest.$ac_objext
3353done
3354rm -f conftest.$ac_ext conftest.$ac_objext
3355CC=$ac_save_CC
3356
3357fi
3358
3359case "x$ac_cv_prog_cc_stdc" in
3360 x|xno)
3361 echo "$as_me:$LINENO: result: none needed" >&5
3362echo "${ECHO_T}none needed" >&6 ;;
3363 *)
3364 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
3365echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
3366 CC="$CC $ac_cv_prog_cc_stdc" ;;
3367esac
3368
503d2be0
AS
3369# Some people use a C++ compiler to compile C. Since we use `exit',
3370# in C++ we need to declare it. In case someone uses the same compiler
3371# for both compiling C and C++ we need to have the C++ compiler decide
3372# the declaration of exit, since it's the most demanding environment.
3373cat >conftest.$ac_ext <<_ACEOF
3374#ifndef __cplusplus
3375 choke me
3376#endif
3377_ACEOF
3378rm -f conftest.$ac_objext
c0d27fcc 3379if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3380 (eval $ac_compile) 2>&5
3381 ac_status=$?
c0d27fcc 3382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3383 (exit $ac_status); } &&
3384 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3385 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3386 (eval $ac_try) 2>&5
3387 ac_status=$?
c0d27fcc 3388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3389 (exit $ac_status); }; }; then
3390 for ac_declaration in \
3391 ''\
3392 '#include <stdlib.h>' \
3393 'extern "C" void std::exit (int) throw (); using std::exit;' \
3394 'extern "C" void std::exit (int); using std::exit;' \
3395 'extern "C" void exit (int) throw ();' \
3396 'extern "C" void exit (int);' \
3397 'void exit (int);'
3398do
3399 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3400#line $LINENO "configure"
cd958eb3
MB
3401/* confdefs.h. */
3402_ACEOF
3403cat confdefs.h >>conftest.$ac_ext
3404cat >>conftest.$ac_ext <<_ACEOF
3405/* end confdefs.h. */
503d2be0
AS
3406#include <stdlib.h>
3407$ac_declaration
3408int
3409main ()
3410{
3411exit (42);
3412 ;
3413 return 0;
3414}
3415_ACEOF
3416rm -f conftest.$ac_objext
c0d27fcc 3417if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3418 (eval $ac_compile) 2>&5
3419 ac_status=$?
c0d27fcc 3420 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3421 (exit $ac_status); } &&
3422 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3423 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3424 (eval $ac_try) 2>&5
3425 ac_status=$?
c0d27fcc 3426 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3427 (exit $ac_status); }; }; then
3428 :
3429else
3430 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3431sed 's/^/| /' conftest.$ac_ext >&5
3432
503d2be0
AS
3433continue
3434fi
3435rm -f conftest.$ac_objext conftest.$ac_ext
3436 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3437#line $LINENO "configure"
cd958eb3
MB
3438/* confdefs.h. */
3439_ACEOF
3440cat confdefs.h >>conftest.$ac_ext
3441cat >>conftest.$ac_ext <<_ACEOF
3442/* end confdefs.h. */
503d2be0
AS
3443$ac_declaration
3444int
3445main ()
3446{
3447exit (42);
3448 ;
3449 return 0;
3450}
3451_ACEOF
3452rm -f conftest.$ac_objext
c0d27fcc 3453if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
3454 (eval $ac_compile) 2>&5
3455 ac_status=$?
c0d27fcc 3456 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3457 (exit $ac_status); } &&
3458 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 3459 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
3460 (eval $ac_try) 2>&5
3461 ac_status=$?
c0d27fcc 3462 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3463 (exit $ac_status); }; }; then
3464 break
3465else
3466 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3467sed 's/^/| /' conftest.$ac_ext >&5
3468
503d2be0
AS
3469fi
3470rm -f conftest.$ac_objext conftest.$ac_ext
3471done
3472rm -f conftest*
3473if test -n "$ac_declaration"; then
3474 echo '#ifdef __cplusplus' >>confdefs.h
3475 echo $ac_declaration >>confdefs.h
3476 echo '#endif' >>confdefs.h
3477fi
ba4481b5 3478
503d2be0
AS
3479else
3480 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3481sed 's/^/| /' conftest.$ac_ext >&5
3482
503d2be0
AS
3483fi
3484rm -f conftest.$ac_objext conftest.$ac_ext
3485ac_ext=c
3486ac_cpp='$CPP $CPPFLAGS'
3487ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3488ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3489ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5 3490
c0d27fcc 3491
ba4481b5
DL
3492# On Suns, sometimes $CPP names a directory.
3493if test -n "$CPP" && test -d "$CPP"; then
3494 CPP=
3495fi
3496
3497#### Some systems specify a CPP to use unless we are using GCC.
3498#### Now that we know whether we are using GCC, we can decide whether
3499#### to use that one.
3500if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
3501then
3502 CPP="$NON_GNU_CPP"
3503fi
3504
3505#### Some systems specify a CC to use unless we are using GCC.
3506#### Now that we know whether we are using GCC, we can decide whether
3507#### to use that one.
3508if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
3509 test x$cc_specified != xyes
3510then
3511 CC="$NON_GNU_CC"
3512fi
3513
3514if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
3515then
3516 CC="$CC $GCC_TEST_OPTIONS"
3517fi
3518
3519if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
3520then
3521 CC="$CC $NON_GCC_TEST_OPTIONS"
3522fi
3523
6a3a24fa 3524#### Some other nice autoconf tests.
ba4481b5 3525
c0d27fcc 3526echo "$as_me:$LINENO: checking whether ln -s works" >&5
503d2be0
AS
3527echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3528LN_S=$as_ln_s
3529if test "$LN_S" = "ln -s"; then
c0d27fcc 3530 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 3531echo "${ECHO_T}yes" >&6
ba4481b5 3532else
c0d27fcc 3533 echo "$as_me:$LINENO: result: no, using $LN_S" >&5
503d2be0 3534echo "${ECHO_T}no, using $LN_S" >&6
ba4481b5
DL
3535fi
3536
503d2be0
AS
3537ac_ext=c
3538ac_cpp='$CPP $CPPFLAGS'
3539ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3540ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3541ac_compiler_gnu=$ac_cv_c_compiler_gnu
c0d27fcc 3542echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
503d2be0 3543echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
ba4481b5
DL
3544# On Suns, sometimes $CPP names a directory.
3545if test -n "$CPP" && test -d "$CPP"; then
3546 CPP=
3547fi
3548if test -z "$CPP"; then
503d2be0
AS
3549 if test "${ac_cv_prog_CPP+set}" = set; then
3550 echo $ECHO_N "(cached) $ECHO_C" >&6
3551else
3552 # Double quotes because CPP needs to be expanded
3553 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3554 do
3555 ac_preproc_ok=false
3556for ac_c_preproc_warn_flag in '' yes
3557do
3558 # Use a header file that comes with gcc, so configuring glibc
3559 # with a fresh cross-compiler works.
9e71690e
DK
3560 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3561 # <limits.h> exists even on freestanding compilers.
ba4481b5 3562 # On the NeXT, cc -E runs the code through the compiler's parser,
503d2be0
AS
3563 # not just through cpp. "Syntax error" is here to catch this case.
3564 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3565#line $LINENO "configure"
cd958eb3
MB
3566/* confdefs.h. */
3567_ACEOF
3568cat confdefs.h >>conftest.$ac_ext
3569cat >>conftest.$ac_ext <<_ACEOF
3570/* end confdefs.h. */
9e71690e
DK
3571#ifdef __STDC__
3572# include <limits.h>
3573#else
3574# include <assert.h>
3575#endif
503d2be0
AS
3576 Syntax error
3577_ACEOF
c0d27fcc 3578if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3579 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3580 ac_status=$?
6bae0ccf 3581 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3582 rm -f conftest.er1
3583 cat conftest.err >&5
c0d27fcc 3584 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3585 (exit $ac_status); } >/dev/null; then
3586 if test -s conftest.err; then
3587 ac_cpp_err=$ac_c_preproc_warn_flag
3588 else
3589 ac_cpp_err=
3590 fi
3591else
3592 ac_cpp_err=yes
3593fi
3594if test -z "$ac_cpp_err"; then
ba4481b5
DL
3595 :
3596else
503d2be0 3597 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3598sed 's/^/| /' conftest.$ac_ext >&5
3599
503d2be0
AS
3600 # Broken: fails on valid input.
3601continue
3602fi
3603rm -f conftest.err conftest.$ac_ext
3604
3605 # OK, works on sane cases. Now check whether non-existent headers
3606 # can be detected and how.
3607 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3608#line $LINENO "configure"
cd958eb3
MB
3609/* confdefs.h. */
3610_ACEOF
3611cat confdefs.h >>conftest.$ac_ext
3612cat >>conftest.$ac_ext <<_ACEOF
3613/* end confdefs.h. */
503d2be0
AS
3614#include <ac_nonexistent.h>
3615_ACEOF
c0d27fcc 3616if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3617 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3618 ac_status=$?
6bae0ccf 3619 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3620 rm -f conftest.er1
3621 cat conftest.err >&5
c0d27fcc 3622 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3623 (exit $ac_status); } >/dev/null; then
3624 if test -s conftest.err; then
3625 ac_cpp_err=$ac_c_preproc_warn_flag
3626 else
3627 ac_cpp_err=
3628 fi
3629else
3630 ac_cpp_err=yes
3631fi
3632if test -z "$ac_cpp_err"; then
3633 # Broken: success on invalid input.
3634continue
c4bb2108 3635else
503d2be0 3636 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3637sed 's/^/| /' conftest.$ac_ext >&5
3638
503d2be0
AS
3639 # Passes both tests.
3640ac_preproc_ok=:
3641break
3642fi
3643rm -f conftest.err conftest.$ac_ext
3644
3645done
3646# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3647rm -f conftest.err conftest.$ac_ext
3648if $ac_preproc_ok; then
3649 break
3650fi
3651
3652 done
3653 ac_cv_prog_CPP=$CPP
3654
3655fi
3656 CPP=$ac_cv_prog_CPP
3657else
3658 ac_cv_prog_CPP=$CPP
3659fi
c0d27fcc 3660echo "$as_me:$LINENO: result: $CPP" >&5
503d2be0
AS
3661echo "${ECHO_T}$CPP" >&6
3662ac_preproc_ok=false
3663for ac_c_preproc_warn_flag in '' yes
3664do
3665 # Use a header file that comes with gcc, so configuring glibc
3666 # with a fresh cross-compiler works.
9e71690e
DK
3667 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3668 # <limits.h> exists even on freestanding compilers.
503d2be0
AS
3669 # On the NeXT, cc -E runs the code through the compiler's parser,
3670 # not just through cpp. "Syntax error" is here to catch this case.
3671 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3672#line $LINENO "configure"
cd958eb3
MB
3673/* confdefs.h. */
3674_ACEOF
3675cat confdefs.h >>conftest.$ac_ext
3676cat >>conftest.$ac_ext <<_ACEOF
3677/* end confdefs.h. */
9e71690e
DK
3678#ifdef __STDC__
3679# include <limits.h>
3680#else
3681# include <assert.h>
3682#endif
503d2be0
AS
3683 Syntax error
3684_ACEOF
c0d27fcc 3685if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3686 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3687 ac_status=$?
6bae0ccf 3688 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3689 rm -f conftest.er1
3690 cat conftest.err >&5
c0d27fcc 3691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3692 (exit $ac_status); } >/dev/null; then
3693 if test -s conftest.err; then
3694 ac_cpp_err=$ac_c_preproc_warn_flag
3695 else
3696 ac_cpp_err=
3697 fi
3698else
3699 ac_cpp_err=yes
3700fi
3701if test -z "$ac_cpp_err"; then
ba4481b5
DL
3702 :
3703else
503d2be0 3704 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3705sed 's/^/| /' conftest.$ac_ext >&5
3706
503d2be0
AS
3707 # Broken: fails on valid input.
3708continue
3709fi
3710rm -f conftest.err conftest.$ac_ext
3711
3712 # OK, works on sane cases. Now check whether non-existent headers
3713 # can be detected and how.
3714 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 3715#line $LINENO "configure"
cd958eb3
MB
3716/* confdefs.h. */
3717_ACEOF
3718cat confdefs.h >>conftest.$ac_ext
3719cat >>conftest.$ac_ext <<_ACEOF
3720/* end confdefs.h. */
503d2be0
AS
3721#include <ac_nonexistent.h>
3722_ACEOF
c0d27fcc 3723if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
3724 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3725 ac_status=$?
6bae0ccf 3726 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
3727 rm -f conftest.er1
3728 cat conftest.err >&5
c0d27fcc 3729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
3730 (exit $ac_status); } >/dev/null; then
3731 if test -s conftest.err; then
3732 ac_cpp_err=$ac_c_preproc_warn_flag
3733 else
3734 ac_cpp_err=
3735 fi
3736else
3737 ac_cpp_err=yes
c4bb2108 3738fi
503d2be0
AS
3739if test -z "$ac_cpp_err"; then
3740 # Broken: success on invalid input.
3741continue
3742else
3743 echo "$as_me: failed program was:" >&5
cd958eb3
MB
3744sed 's/^/| /' conftest.$ac_ext >&5
3745
503d2be0
AS
3746 # Passes both tests.
3747ac_preproc_ok=:
3748break
ba4481b5 3749fi
503d2be0
AS
3750rm -f conftest.err conftest.$ac_ext
3751
3752done
3753# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3754rm -f conftest.err conftest.$ac_ext
3755if $ac_preproc_ok; then
3756 :
ba4481b5 3757else
cd958eb3
MB
3758 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3759See \`config.log' for more details." >&5
3760echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3761See \`config.log' for more details." >&2;}
503d2be0 3762 { (exit 1); exit 1; }; }
ba4481b5 3763fi
503d2be0
AS
3764
3765ac_ext=c
3766ac_cpp='$CPP $CPPFLAGS'
3767ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3768ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3769ac_compiler_gnu=$ac_cv_c_compiler_gnu
ba4481b5
DL
3770
3771# Find a good install program. We prefer a C program (faster),
3772# so one script is as good as another. But avoid the broken or
3773# incompatible versions:
3774# SysV /etc/install, /usr/sbin/install
3775# SunOS /usr/etc/install
3776# IRIX /sbin/install
3777# AIX /bin/install
503d2be0 3778# AmigaOS /C/install, which installs bootblocks on floppy discs
c4bb2108 3779# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
ba4481b5
DL
3780# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3781# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3782# ./install, which can be erroneously created by make from ./install.sh.
c0d27fcc
MR
3783echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3784echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
ba4481b5 3785if test -z "$INSTALL"; then
503d2be0
AS
3786if test "${ac_cv_path_install+set}" = set; then
3787 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 3788else
c0d27fcc
MR
3789 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3790for as_dir in $PATH
3791do
3792 IFS=$as_save_IFS
3793 test -z "$as_dir" && as_dir=.
3794 # Account for people who put trailing slashes in PATH elements.
3795case $as_dir/ in
3796 ./ | .// | /cC/* | \
3797 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3798 /usr/ucb/* ) ;;
3799 *)
3800 # OSF1 and SCO ODT 3.0 have their own names for install.
3801 # Don't use installbsd from OSF since it installs stuff as root
3802 # by default.
3803 for ac_prog in ginstall scoinst install; do
3804 for ac_exec_ext in '' $ac_executable_extensions; do
3805 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3806 if test $ac_prog = install &&
3807 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3808 # AIX install. It has an incompatible calling convention.
3809 :
3810 elif test $ac_prog = install &&
3811 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3812 # program-specific install script used by HP pwplus--don't use.
3813 :
3814 else
3815 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3816 break 3
3817 fi
3818 fi
ba4481b5 3819 done
c0d27fcc
MR
3820 done
3821 ;;
3822esac
3823done
3824
ba4481b5
DL
3825
3826fi
3827 if test "${ac_cv_path_install+set}" = set; then
503d2be0 3828 INSTALL=$ac_cv_path_install
ba4481b5
DL
3829 else
3830 # As a last resort, use the slow shell script. We don't cache a
3831 # path for INSTALL within a source directory, because that will
3832 # break other packages using the cache if that directory is
3833 # removed, or if the path is relative.
503d2be0 3834 INSTALL=$ac_install_sh
ba4481b5
DL
3835 fi
3836fi
c0d27fcc 3837echo "$as_me:$LINENO: result: $INSTALL" >&5
503d2be0 3838echo "${ECHO_T}$INSTALL" >&6
ba4481b5
DL
3839
3840# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3841# It thinks the first close brace ends the variable substitution.
3842test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3843
503d2be0 3844test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
c4bb2108 3845
ba4481b5
DL
3846test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3847
c0d27fcc
MR
3848if test "x$RANLIB" = x; then
3849 if test -n "$ac_tool_prefix"; then
3850 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3851set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3852echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0 3853echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
c0d27fcc 3854if test "${ac_cv_prog_RANLIB+set}" = set; then
503d2be0 3855 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4
DL
3856else
3857 if test -n "$RANLIB"; then
3858 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3859else
c0d27fcc
MR
3860as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3861for as_dir in $PATH
3862do
3863 IFS=$as_save_IFS
3864 test -z "$as_dir" && as_dir=.
3865 for ac_exec_ext in '' $ac_executable_extensions; do
3866 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3867 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3868 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3869 break 2
3870 fi
3871done
503d2be0
AS
3872done
3873
7397acc4
DL
3874fi
3875fi
503d2be0 3876RANLIB=$ac_cv_prog_RANLIB
7397acc4 3877if test -n "$RANLIB"; then
c0d27fcc 3878 echo "$as_me:$LINENO: result: $RANLIB" >&5
503d2be0
AS
3879echo "${ECHO_T}$RANLIB" >&6
3880else
c0d27fcc 3881 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3882echo "${ECHO_T}no" >&6
3883fi
3884
3885fi
3886if test -z "$ac_cv_prog_RANLIB"; then
3887 ac_ct_RANLIB=$RANLIB
3888 # Extract the first word of "ranlib", so it can be a program name with args.
3889set dummy ranlib; ac_word=$2
c0d27fcc 3890echo "$as_me:$LINENO: checking for $ac_word" >&5
503d2be0
AS
3891echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3892if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3893 echo $ECHO_N "(cached) $ECHO_C" >&6
3894else
3895 if test -n "$ac_ct_RANLIB"; then
3896 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3897else
c0d27fcc
MR
3898as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3899for as_dir in $PATH
3900do
3901 IFS=$as_save_IFS
3902 test -z "$as_dir" && as_dir=.
3903 for ac_exec_ext in '' $ac_executable_extensions; do
3904 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3905 ac_cv_prog_ac_ct_RANLIB="ranlib"
3906 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3907 break 2
3908 fi
3909done
503d2be0
AS
3910done
3911
3912 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3913fi
3914fi
3915ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3916if test -n "$ac_ct_RANLIB"; then
c0d27fcc 3917 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
503d2be0
AS
3918echo "${ECHO_T}$ac_ct_RANLIB" >&6
3919else
c0d27fcc 3920 echo "$as_me:$LINENO: result: no" >&5
503d2be0
AS
3921echo "${ECHO_T}no" >&6
3922fi
3923
3924 RANLIB=$ac_ct_RANLIB
7397acc4 3925else
503d2be0 3926 RANLIB="$ac_cv_prog_RANLIB"
7397acc4
DL
3927fi
3928
3929fi
9e71690e
DK
3930# Extract the first word of "install-info", so it can be a program name with args.
3931set dummy install-info; ac_word=$2
3932echo "$as_me:$LINENO: checking for $ac_word" >&5
3933echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3934if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
3935 echo $ECHO_N "(cached) $ECHO_C" >&6
3936else
3937 case $INSTALL_INFO in
3938 [\\/]* | ?:[\\/]*)
3939 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
3940 ;;
3941 *)
3942 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3943for as_dir in $PATH
3944do
3945 IFS=$as_save_IFS
3946 test -z "$as_dir" && as_dir=.
3947 for ac_exec_ext in '' $ac_executable_extensions; do
3948 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3949 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
3950 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3951 break 2
3952 fi
3953done
3954done
3955
3956 ;;
3957esac
3958fi
3959INSTALL_INFO=$ac_cv_path_INSTALL_INFO
3960
3961if test -n "$INSTALL_INFO"; then
3962 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
3963echo "${ECHO_T}$INSTALL_INFO" >&6
3964else
3965 echo "$as_me:$LINENO: result: no" >&5
3966echo "${ECHO_T}no" >&6
3967fi
3968
3969# Extract the first word of "install-info", so it can be a program name with args.
3970set dummy install-info; ac_word=$2
3971echo "$as_me:$LINENO: checking for $ac_word" >&5
3972echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3973if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
3974 echo $ECHO_N "(cached) $ECHO_C" >&6
3975else
3976 case $INSTALL_INFO in
3977 [\\/]* | ?:[\\/]*)
3978 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
3979 ;;
3980 *)
3981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3982for as_dir in /usr/sbin
3983do
3984 IFS=$as_save_IFS
3985 test -z "$as_dir" && as_dir=.
3986 for ac_exec_ext in '' $ac_executable_extensions; do
3987 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3988 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
3989 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3990 break 2
3991 fi
3992done
3993done
3994
3995 ;;
3996esac
3997fi
3998INSTALL_INFO=$ac_cv_path_INSTALL_INFO
3999
4000if test -n "$INSTALL_INFO"; then
4001 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4002echo "${ECHO_T}$INSTALL_INFO" >&6
4003else
4004 echo "$as_me:$LINENO: result: no" >&5
4005echo "${ECHO_T}no" >&6
4006fi
4007
4008# Extract the first word of "install-info", so it can be a program name with args.
4009set dummy install-info; ac_word=$2
4010echo "$as_me:$LINENO: checking for $ac_word" >&5
4011echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4012if test "${ac_cv_path_INSTALL_INFO+set}" = set; then
4013 echo $ECHO_N "(cached) $ECHO_C" >&6
4014else
4015 case $INSTALL_INFO in
4016 [\\/]* | ?:[\\/]*)
4017 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
4018 ;;
4019 *)
4020 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4021for as_dir in /sbin
4022do
4023 IFS=$as_save_IFS
4024 test -z "$as_dir" && as_dir=.
4025 for ac_exec_ext in '' $ac_executable_extensions; do
4026 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4027 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
4028 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4029 break 2
4030 fi
4031done
4032done
4033
4034 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
4035 ;;
4036esac
4037fi
4038INSTALL_INFO=$ac_cv_path_INSTALL_INFO
4039
4040if test -n "$INSTALL_INFO"; then
4041 echo "$as_me:$LINENO: result: $INSTALL_INFO" >&5
4042echo "${ECHO_T}$INSTALL_INFO" >&6
4043else
4044 echo "$as_me:$LINENO: result: no" >&5
4045echo "${ECHO_T}no" >&6
4046fi
4047
ba4481b5 4048
c0d27fcc 4049
8e967cf7
MR
4050if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
4051then
4052 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
4053fi
4054
4055if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
4056then
4057 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
4058fi
4059
c0d27fcc
MR
4060
4061
6bae0ccf
DL
4062echo "$as_me:$LINENO: checking for egrep" >&5
4063echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4064if test "${ac_cv_prog_egrep+set}" = set; then
4065 echo $ECHO_N "(cached) $ECHO_C" >&6
4066else
4067 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4068 then ac_cv_prog_egrep='grep -E'
4069 else ac_cv_prog_egrep='egrep'
4070 fi
4071fi
4072echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4073echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4074 EGREP=$ac_cv_prog_egrep
4075
4076
c0d27fcc
MR
4077
4078echo "$as_me:$LINENO: checking for AIX" >&5
503d2be0
AS
4079echo $ECHO_N "checking for AIX... $ECHO_C" >&6
4080cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4081#line $LINENO "configure"
cd958eb3
MB
4082/* confdefs.h. */
4083_ACEOF
4084cat confdefs.h >>conftest.$ac_ext
4085cat >>conftest.$ac_ext <<_ACEOF
4086/* end confdefs.h. */
ba4481b5
DL
4087#ifdef _AIX
4088 yes
4089#endif
4090
503d2be0 4091_ACEOF
ba4481b5 4092if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4093 $EGREP "yes" >/dev/null 2>&1; then
c0d27fcc 4094 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 4095echo "${ECHO_T}yes" >&6
c0d27fcc 4096cat >>confdefs.h <<\_ACEOF
ba4481b5 4097#define _ALL_SOURCE 1
c0d27fcc 4098_ACEOF
ba4481b5
DL
4099
4100else
c0d27fcc 4101 echo "$as_me:$LINENO: result: no" >&5
503d2be0 4102echo "${ECHO_T}no" >&6
ba4481b5
DL
4103fi
4104rm -f conftest*
4105
c0d27fcc
MR
4106
4107
3b33a005
DL
4108#### Extract some information from the operating system and machine files.
4109
c0d27fcc 4110{ echo "$as_me:$LINENO: checking the machine- and system-dependent files to find out
3b33a005 4111 - which libraries the lib-src programs will want, and
503d2be0
AS
4112 - whether the GNU malloc routines are usable..." >&5
4113echo "$as_me: checking the machine- and system-dependent files to find out
3b33a005 4114 - which libraries the lib-src programs will want, and
503d2be0 4115 - whether the GNU malloc routines are usable..." >&6;}
3b33a005
DL
4116
4117### First figure out CFLAGS (which we use for running the compiler here)
4118### and REAL_CFLAGS (which we use for real compilation).
4119### The two are the same except on a few systems, where they are made
4120### different to work around various lossages. For example,
4121### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
4122### as implying static linking.
4123
4124### If the CFLAGS env var is specified, we use that value
4125### instead of the default.
4126
4127### It's not important that this name contain the PID; you can't run
4128### two configures in the same directory and have anything work
4129### anyway.
4130tempcname="conftest.c"
4131
4132echo '
4133#include "'${srcdir}'/src/'${opsysfile}'"
4134#include "'${srcdir}'/src/'${machfile}'"
4135#ifndef LIBS_MACHINE
4136#define LIBS_MACHINE
4137#endif
4138#ifndef LIBS_SYSTEM
4139#define LIBS_SYSTEM
4140#endif
4141#ifndef C_SWITCH_SYSTEM
4142#define C_SWITCH_SYSTEM
4143#endif
4144#ifndef C_SWITCH_MACHINE
4145#define C_SWITCH_MACHINE
4146#endif
4147configure___ libsrc_libs=LIBS_MACHINE LIBS_SYSTEM
4148configure___ c_switch_system=C_SWITCH_SYSTEM
4149configure___ c_switch_machine=C_SWITCH_MACHINE
4150
4151#ifndef LIB_X11_LIB
4152#define LIB_X11_LIB -lX11
4153#endif
4154
4155#ifndef LIBX11_MACHINE
4156#define LIBX11_MACHINE
4157#endif
4158
4159#ifndef LIBX11_SYSTEM
4160#define LIBX11_SYSTEM
4161#endif
4162configure___ LIBX=LIB_X11_LIB LIBX11_MACHINE LIBX11_SYSTEM
4163
4164#ifdef UNEXEC
4165configure___ unexec=UNEXEC
4166#else
4167configure___ unexec=unexec.o
4168#endif
4169
4170#ifdef SYSTEM_MALLOC
4171configure___ system_malloc=yes
4172#else
4173configure___ system_malloc=no
4174#endif
4175
ef9e4345
GM
4176#ifdef USE_MMAP_FOR_BUFFERS
4177configure___ use_mmap_for_buffers=yes
73b77ee5 4178#else
ef9e4345 4179configure___ use_mmap_for_buffers=no
73b77ee5
GM
4180#endif
4181
3b33a005
DL
4182#ifndef C_DEBUG_SWITCH
4183#define C_DEBUG_SWITCH -g
4184#endif
4185
4186#ifndef C_OPTIMIZE_SWITCH
4187#ifdef __GNUC__
4188#define C_OPTIMIZE_SWITCH -O2
4189#else
4190#define C_OPTIMIZE_SWITCH -O
4191#endif
4192#endif
4193
4194#ifndef LD_SWITCH_MACHINE
4195#define LD_SWITCH_MACHINE
4196#endif
4197
4198#ifndef LD_SWITCH_SYSTEM
4199#define LD_SWITCH_SYSTEM
4200#endif
4201
4202#ifndef LD_SWITCH_X_SITE_AUX
4203#define LD_SWITCH_X_SITE_AUX
503d2be0 4204#endif
3b33a005
DL
4205
4206configure___ ld_switch_system=LD_SWITCH_SYSTEM
4207configure___ ld_switch_machine=LD_SWITCH_MACHINE
4208
4209#ifdef THIS_IS_CONFIGURE
4210
4211/* Get the CFLAGS for tests in configure. */
4212#ifdef __GNUC__
4213configure___ CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4214#else
4215configure___ CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4216#endif
4217
4218#else /* not THIS_IS_CONFIGURE */
4219
4220/* Get the CFLAGS for real compilation. */
4221#ifdef __GNUC__
4222configure___ REAL_CFLAGS=C_DEBUG_SWITCH C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
4223#else
4224configure___ REAL_CFLAGS=C_DEBUG_SWITCH '${SPECIFIED_CFLAGS}'
4225#endif
4226
4227#endif /* not THIS_IS_CONFIGURE */
4228' > ${tempcname}
4229
4230# The value of CPP is a quoted variable reference, so we need to do this
4231# to get its actual value...
4232CPP=`eval "echo $CPP"`
4233eval `${CPP} -Isrc ${tempcname} \
4234 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4235if test "x$SPECIFIED_CFLAGS" = x; then
4236 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
4237 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
4238else
4239 REAL_CFLAGS="$CFLAGS"
4240fi
4241rm ${tempcname}
4242
4243ac_link="$ac_link $ld_switch_machine $ld_switch_system"
4244
4245### Make sure subsequent tests use flags consistent with the build flags.
4246
4247if test x"${OVERRIDE_CPPFLAGS}" != x; then
4248 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
4249else
4250 CPPFLAGS="$c_switch_system $c_switch_machine $CPPFLAGS"
4251fi
4252
6bae0ccf
DL
4253
4254
22044edf
DL
4255
4256cat >>confdefs.h <<\_ACEOF
4257#define _GNU_SOURCE 1
4258_ACEOF
4259
4260
4261
503d2be0 4262# Check whether --enable-largefile or --disable-largefile was given.
f4988be7
GM
4263if test "${enable_largefile+set}" = set; then
4264 enableval="$enable_largefile"
f4988be7 4265
503d2be0
AS
4266fi;
4267if test "$enable_largefile" != no; then
f4988be7 4268
c0d27fcc 4269 echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
503d2be0
AS
4270echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
4271if test "${ac_cv_sys_largefile_CC+set}" = set; then
4272 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4273else
f4988be7 4274 ac_cv_sys_largefile_CC=no
503d2be0
AS
4275 if test "$GCC" != yes; then
4276 ac_save_CC=$CC
4277 while :; do
4278 # IRIX 6.2 and later do not support large files by default,
4279 # so use the C compiler's -n32 option if that helps.
4280 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4281#line $LINENO "configure"
cd958eb3
MB
4282/* confdefs.h. */
4283_ACEOF
4284cat confdefs.h >>conftest.$ac_ext
4285cat >>conftest.$ac_ext <<_ACEOF
4286/* end confdefs.h. */
f4988be7 4287#include <sys/types.h>
503d2be0
AS
4288 /* Check that off_t can represent 2**63 - 1 correctly.
4289 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4290 since some C++ compilers masquerading as C compilers
4291 incorrectly reject 9223372036854775807. */
4292#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4293 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4294 && LARGE_OFF_T % 2147483647 == 1)
4295 ? 1 : -1];
4296int
4297main ()
4298{
f4988be7 4299
503d2be0
AS
4300 ;
4301 return 0;
4302}
4303_ACEOF
4304 rm -f conftest.$ac_objext
c0d27fcc 4305if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4306 (eval $ac_compile) 2>&5
4307 ac_status=$?
c0d27fcc 4308 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4309 (exit $ac_status); } &&
4310 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4311 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4312 (eval $ac_try) 2>&5
4313 ac_status=$?
c0d27fcc 4314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4315 (exit $ac_status); }; }; then
4316 break
b192d653 4317else
503d2be0 4318 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4319sed 's/^/| /' conftest.$ac_ext >&5
4320
503d2be0
AS
4321fi
4322rm -f conftest.$ac_objext
4323 CC="$CC -n32"
4324 rm -f conftest.$ac_objext
c0d27fcc 4325if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4326 (eval $ac_compile) 2>&5
4327 ac_status=$?
c0d27fcc 4328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4329 (exit $ac_status); } &&
4330 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4331 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4332 (eval $ac_try) 2>&5
4333 ac_status=$?
c0d27fcc 4334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4335 (exit $ac_status); }; }; then
4336 ac_cv_sys_largefile_CC=' -n32'; break
4337else
4338 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4339sed 's/^/| /' conftest.$ac_ext >&5
4340
503d2be0
AS
4341fi
4342rm -f conftest.$ac_objext
4343 break
4344 done
4345 CC=$ac_save_CC
4346 rm -f conftest.$ac_ext
4347 fi
b192d653 4348fi
c0d27fcc 4349echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
503d2be0
AS
4350echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
4351 if test "$ac_cv_sys_largefile_CC" != no; then
4352 CC=$CC$ac_cv_sys_largefile_CC
4353 fi
b192d653 4354
c0d27fcc 4355 echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
503d2be0
AS
4356echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
4357if test "${ac_cv_sys_file_offset_bits+set}" = set; then
4358 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4359else
503d2be0 4360 while :; do
f4988be7 4361 ac_cv_sys_file_offset_bits=no
503d2be0 4362 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4363#line $LINENO "configure"
cd958eb3
MB
4364/* confdefs.h. */
4365_ACEOF
4366cat confdefs.h >>conftest.$ac_ext
4367cat >>conftest.$ac_ext <<_ACEOF
4368/* end confdefs.h. */
f4988be7 4369#include <sys/types.h>
503d2be0
AS
4370 /* Check that off_t can represent 2**63 - 1 correctly.
4371 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4372 since some C++ compilers masquerading as C compilers
4373 incorrectly reject 9223372036854775807. */
4374#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4375 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4376 && LARGE_OFF_T % 2147483647 == 1)
4377 ? 1 : -1];
4378int
4379main ()
4380{
f4988be7 4381
503d2be0
AS
4382 ;
4383 return 0;
4384}
4385_ACEOF
4386rm -f conftest.$ac_objext
c0d27fcc 4387if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4388 (eval $ac_compile) 2>&5
4389 ac_status=$?
c0d27fcc 4390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4391 (exit $ac_status); } &&
4392 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4393 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4394 (eval $ac_try) 2>&5
4395 ac_status=$?
c0d27fcc 4396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4397 (exit $ac_status); }; }; then
4398 break
f4988be7 4399else
503d2be0 4400 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4401sed 's/^/| /' conftest.$ac_ext >&5
4402
503d2be0
AS
4403fi
4404rm -f conftest.$ac_objext conftest.$ac_ext
4405 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4406#line $LINENO "configure"
cd958eb3
MB
4407/* confdefs.h. */
4408_ACEOF
4409cat confdefs.h >>conftest.$ac_ext
4410cat >>conftest.$ac_ext <<_ACEOF
4411/* end confdefs.h. */
f4988be7
GM
4412#define _FILE_OFFSET_BITS 64
4413#include <sys/types.h>
503d2be0
AS
4414 /* Check that off_t can represent 2**63 - 1 correctly.
4415 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4416 since some C++ compilers masquerading as C compilers
4417 incorrectly reject 9223372036854775807. */
4418#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4419 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4420 && LARGE_OFF_T % 2147483647 == 1)
4421 ? 1 : -1];
4422int
4423main ()
4424{
4425
4426 ;
4427 return 0;
4428}
4429_ACEOF
4430rm -f conftest.$ac_objext
c0d27fcc 4431if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4432 (eval $ac_compile) 2>&5
4433 ac_status=$?
c0d27fcc 4434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4435 (exit $ac_status); } &&
4436 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4437 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4438 (eval $ac_try) 2>&5
4439 ac_status=$?
c0d27fcc 4440 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4441 (exit $ac_status); }; }; then
4442 ac_cv_sys_file_offset_bits=64; break
4443else
4444 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4445sed 's/^/| /' conftest.$ac_ext >&5
4446
503d2be0
AS
4447fi
4448rm -f conftest.$ac_objext conftest.$ac_ext
4449 break
4450done
ba4481b5 4451fi
c0d27fcc 4452echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
503d2be0
AS
4453echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
4454if test "$ac_cv_sys_file_offset_bits" != no; then
ba4481b5 4455
c0d27fcc 4456cat >>confdefs.h <<_ACEOF
f4988be7 4457#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
c0d27fcc 4458_ACEOF
f4988be7 4459
503d2be0
AS
4460fi
4461rm -f conftest*
c0d27fcc 4462 echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
503d2be0
AS
4463echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
4464if test "${ac_cv_sys_large_files+set}" = set; then
4465 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 4466else
503d2be0 4467 while :; do
f4988be7 4468 ac_cv_sys_large_files=no
503d2be0 4469 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4470#line $LINENO "configure"
cd958eb3
MB
4471/* confdefs.h. */
4472_ACEOF
4473cat confdefs.h >>conftest.$ac_ext
4474cat >>conftest.$ac_ext <<_ACEOF
4475/* end confdefs.h. */
503d2be0
AS
4476#include <sys/types.h>
4477 /* Check that off_t can represent 2**63 - 1 correctly.
4478 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4479 since some C++ compilers masquerading as C compilers
4480 incorrectly reject 9223372036854775807. */
4481#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4482 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4483 && LARGE_OFF_T % 2147483647 == 1)
4484 ? 1 : -1];
4485int
4486main ()
4487{
ba4481b5 4488
503d2be0
AS
4489 ;
4490 return 0;
4491}
4492_ACEOF
4493rm -f conftest.$ac_objext
c0d27fcc 4494if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4495 (eval $ac_compile) 2>&5
4496 ac_status=$?
c0d27fcc 4497 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4498 (exit $ac_status); } &&
4499 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4500 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4501 (eval $ac_try) 2>&5
4502 ac_status=$?
c0d27fcc 4503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4504 (exit $ac_status); }; }; then
4505 break
ba4481b5 4506else
503d2be0 4507 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4508sed 's/^/| /' conftest.$ac_ext >&5
4509
503d2be0
AS
4510fi
4511rm -f conftest.$ac_objext conftest.$ac_ext
4512 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4513#line $LINENO "configure"
cd958eb3
MB
4514/* confdefs.h. */
4515_ACEOF
4516cat confdefs.h >>conftest.$ac_ext
4517cat >>conftest.$ac_ext <<_ACEOF
4518/* end confdefs.h. */
f4988be7 4519#define _LARGE_FILES 1
503d2be0
AS
4520#include <sys/types.h>
4521 /* Check that off_t can represent 2**63 - 1 correctly.
4522 We can't simply define LARGE_OFF_T to be 9223372036854775807,
4523 since some C++ compilers masquerading as C compilers
4524 incorrectly reject 9223372036854775807. */
4525#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4526 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4527 && LARGE_OFF_T % 2147483647 == 1)
4528 ? 1 : -1];
4529int
4530main ()
4531{
f4988be7 4532
503d2be0
AS
4533 ;
4534 return 0;
4535}
4536_ACEOF
4537rm -f conftest.$ac_objext
c0d27fcc 4538if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
4539 (eval $ac_compile) 2>&5
4540 ac_status=$?
c0d27fcc 4541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4542 (exit $ac_status); } &&
4543 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 4544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4545 (eval $ac_try) 2>&5
4546 ac_status=$?
c0d27fcc 4547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
4548 (exit $ac_status); }; }; then
4549 ac_cv_sys_large_files=1; break
4550else
4551 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4552sed 's/^/| /' conftest.$ac_ext >&5
4553
503d2be0
AS
4554fi
4555rm -f conftest.$ac_objext conftest.$ac_ext
4556 break
4557done
ba4481b5 4558fi
c0d27fcc 4559echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
503d2be0
AS
4560echo "${ECHO_T}$ac_cv_sys_large_files" >&6
4561if test "$ac_cv_sys_large_files" != no; then
ba4481b5 4562
c0d27fcc 4563cat >>confdefs.h <<_ACEOF
f4988be7 4564#define _LARGE_FILES $ac_cv_sys_large_files
c0d27fcc 4565_ACEOF
ba4481b5 4566
503d2be0
AS
4567fi
4568rm -f conftest*
4569fi
ba4481b5 4570
c0d27fcc 4571
2c9dccc9
PJ
4572if test "${with_sound}" != "no"; then
4573 # Sound support for GNU/Linux and the free BSDs.
c0d27fcc
MR
4574 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4575echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4576if test "${ac_cv_header_stdc+set}" = set; then
4577 echo $ECHO_N "(cached) $ECHO_C" >&6
4578else
4579 cat >conftest.$ac_ext <<_ACEOF
4580#line $LINENO "configure"
cd958eb3
MB
4581/* confdefs.h. */
4582_ACEOF
4583cat confdefs.h >>conftest.$ac_ext
4584cat >>conftest.$ac_ext <<_ACEOF
4585/* end confdefs.h. */
c0d27fcc
MR
4586#include <stdlib.h>
4587#include <stdarg.h>
4588#include <string.h>
4589#include <float.h>
98418dba 4590
cd958eb3
MB
4591int
4592main ()
4593{
4594
4595 ;
4596 return 0;
4597}
c0d27fcc 4598_ACEOF
cd958eb3
MB
4599rm -f conftest.$ac_objext
4600if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4601 (eval $ac_compile) 2>&5
c0d27fcc 4602 ac_status=$?
c0d27fcc 4603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
cd958eb3
MB
4604 (exit $ac_status); } &&
4605 { ac_try='test -s conftest.$ac_objext'
4606 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4607 (eval $ac_try) 2>&5
4608 ac_status=$?
4609 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4610 (exit $ac_status); }; }; then
c0d27fcc
MR
4611 ac_cv_header_stdc=yes
4612else
4613 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4614sed 's/^/| /' conftest.$ac_ext >&5
4615
4616ac_cv_header_stdc=no
c0d27fcc 4617fi
cd958eb3 4618rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4619
4620if test $ac_cv_header_stdc = yes; then
4621 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4622 cat >conftest.$ac_ext <<_ACEOF
4623#line $LINENO "configure"
cd958eb3
MB
4624/* confdefs.h. */
4625_ACEOF
4626cat confdefs.h >>conftest.$ac_ext
4627cat >>conftest.$ac_ext <<_ACEOF
4628/* end confdefs.h. */
c0d27fcc
MR
4629#include <string.h>
4630
4631_ACEOF
4632if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4633 $EGREP "memchr" >/dev/null 2>&1; then
c0d27fcc
MR
4634 :
4635else
4636 ac_cv_header_stdc=no
4637fi
4638rm -f conftest*
4639
4640fi
4641
4642if test $ac_cv_header_stdc = yes; then
4643 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4644 cat >conftest.$ac_ext <<_ACEOF
4645#line $LINENO "configure"
cd958eb3
MB
4646/* confdefs.h. */
4647_ACEOF
4648cat confdefs.h >>conftest.$ac_ext
4649cat >>conftest.$ac_ext <<_ACEOF
4650/* end confdefs.h. */
c0d27fcc
MR
4651#include <stdlib.h>
4652
4653_ACEOF
4654if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 4655 $EGREP "free" >/dev/null 2>&1; then
c0d27fcc
MR
4656 :
4657else
4658 ac_cv_header_stdc=no
4659fi
4660rm -f conftest*
4661
4662fi
4663
4664if test $ac_cv_header_stdc = yes; then
4665 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4666 if test "$cross_compiling" = yes; then
4667 :
4668else
4669 cat >conftest.$ac_ext <<_ACEOF
4670#line $LINENO "configure"
cd958eb3
MB
4671/* confdefs.h. */
4672_ACEOF
4673cat confdefs.h >>conftest.$ac_ext
4674cat >>conftest.$ac_ext <<_ACEOF
4675/* end confdefs.h. */
c0d27fcc
MR
4676#include <ctype.h>
4677#if ((' ' & 0x0FF) == 0x020)
4678# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4679# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4680#else
cd958eb3
MB
4681# define ISLOWER(c) \
4682 (('a' <= (c) && (c) <= 'i') \
c0d27fcc
MR
4683 || ('j' <= (c) && (c) <= 'r') \
4684 || ('s' <= (c) && (c) <= 'z'))
4685# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4686#endif
4687
4688#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4689int
4690main ()
4691{
4692 int i;
4693 for (i = 0; i < 256; i++)
4694 if (XOR (islower (i), ISLOWER (i))
4695 || toupper (i) != TOUPPER (i))
4696 exit(2);
4697 exit (0);
4698}
4699_ACEOF
4700rm -f conftest$ac_exeext
4701if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4702 (eval $ac_link) 2>&5
4703 ac_status=$?
4704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4705 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4706 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4707 (eval $ac_try) 2>&5
4708 ac_status=$?
4709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4710 (exit $ac_status); }; }; then
4711 :
4712else
4713 echo "$as_me: program exited with status $ac_status" >&5
4714echo "$as_me: failed program was:" >&5
cd958eb3
MB
4715sed 's/^/| /' conftest.$ac_ext >&5
4716
c0d27fcc
MR
4717( exit $ac_status )
4718ac_cv_header_stdc=no
4719fi
6bae0ccf 4720rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
4721fi
4722fi
4723fi
4724echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4725echo "${ECHO_T}$ac_cv_header_stdc" >&6
4726if test $ac_cv_header_stdc = yes; then
4727
4728cat >>confdefs.h <<\_ACEOF
4729#define STDC_HEADERS 1
4730_ACEOF
4731
4732fi
4733
4734# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4745 inttypes.h stdint.h unistd.h
98418dba
CW
4746do
4747as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc 4748echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
4749echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4750if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 4751 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4752else
925c2f3f 4753 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4754#line $LINENO "configure"
cd958eb3
MB
4755/* confdefs.h. */
4756_ACEOF
4757cat confdefs.h >>conftest.$ac_ext
4758cat >>conftest.$ac_ext <<_ACEOF
4759/* end confdefs.h. */
c0d27fcc
MR
4760$ac_includes_default
4761
4762#include <$ac_header>
4763_ACEOF
4764rm -f conftest.$ac_objext
4765if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4766 (eval $ac_compile) 2>&5
4767 ac_status=$?
4768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4769 (exit $ac_status); } &&
4770 { ac_try='test -s conftest.$ac_objext'
4771 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4772 (eval $ac_try) 2>&5
4773 ac_status=$?
4774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4775 (exit $ac_status); }; }; then
4776 eval "$as_ac_Header=yes"
4777else
4778 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4779sed 's/^/| /' conftest.$ac_ext >&5
4780
c0d27fcc
MR
4781eval "$as_ac_Header=no"
4782fi
4783rm -f conftest.$ac_objext conftest.$ac_ext
4784fi
4785echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4786echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4787if test `eval echo '${'$as_ac_Header'}'` = yes; then
4788 cat >>confdefs.h <<_ACEOF
4789#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4790_ACEOF
4791
4792fi
4793
4794done
4795
4796
4797
4798
4799
4800for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
4801do
4802as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4803if eval "test \"\${$as_ac_Header+set}\" = set"; then
4804 echo "$as_me:$LINENO: checking for $ac_header" >&5
4805echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4806if eval "test \"\${$as_ac_Header+set}\" = set"; then
4807 echo $ECHO_N "(cached) $ECHO_C" >&6
4808fi
4809echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4810echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4811else
4812 # Is the header compilable?
4813echo "$as_me:$LINENO: checking $ac_header usability" >&5
4814echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4815cat >conftest.$ac_ext <<_ACEOF
4816#line $LINENO "configure"
cd958eb3
MB
4817/* confdefs.h. */
4818_ACEOF
4819cat confdefs.h >>conftest.$ac_ext
4820cat >>conftest.$ac_ext <<_ACEOF
4821/* end confdefs.h. */
c0d27fcc 4822$ac_includes_default
98418dba 4823#include <$ac_header>
503d2be0 4824_ACEOF
c0d27fcc
MR
4825rm -f conftest.$ac_objext
4826if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4827 (eval $ac_compile) 2>&5
4828 ac_status=$?
4829 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4830 (exit $ac_status); } &&
4831 { ac_try='test -s conftest.$ac_objext'
4832 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4833 (eval $ac_try) 2>&5
4834 ac_status=$?
4835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4836 (exit $ac_status); }; }; then
4837 ac_header_compiler=yes
4838else
4839 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4840sed 's/^/| /' conftest.$ac_ext >&5
4841
c0d27fcc
MR
4842ac_header_compiler=no
4843fi
4844rm -f conftest.$ac_objext conftest.$ac_ext
4845echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4846echo "${ECHO_T}$ac_header_compiler" >&6
4847
4848# Is the header present?
4849echo "$as_me:$LINENO: checking $ac_header presence" >&5
4850echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4851cat >conftest.$ac_ext <<_ACEOF
4852#line $LINENO "configure"
cd958eb3
MB
4853/* confdefs.h. */
4854_ACEOF
4855cat confdefs.h >>conftest.$ac_ext
4856cat >>conftest.$ac_ext <<_ACEOF
4857/* end confdefs.h. */
c0d27fcc
MR
4858#include <$ac_header>
4859_ACEOF
4860if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 4861 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 4862 ac_status=$?
6bae0ccf 4863 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
4864 rm -f conftest.er1
4865 cat conftest.err >&5
c0d27fcc 4866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
4867 (exit $ac_status); } >/dev/null; then
4868 if test -s conftest.err; then
4869 ac_cpp_err=$ac_c_preproc_warn_flag
4870 else
4871 ac_cpp_err=
4872 fi
4873else
4874 ac_cpp_err=yes
4875fi
4876if test -z "$ac_cpp_err"; then
c0d27fcc 4877 ac_header_preproc=yes
f4988be7 4878else
503d2be0 4879 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4880sed 's/^/| /' conftest.$ac_ext >&5
4881
c0d27fcc 4882 ac_header_preproc=no
f4988be7 4883fi
98418dba 4884rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
4885echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4886echo "${ECHO_T}$ac_header_preproc" >&6
4887
4888# So? What about this header?
4889case $ac_header_compiler:$ac_header_preproc in
4890 yes:no )
4891 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4892echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4893 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
4894echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4895 (
4896 cat <<\_ASBOX
4897## ------------------------------------ ##
4898## Report this to bug-autoconf@gnu.org. ##
4899## ------------------------------------ ##
4900_ASBOX
4901 ) |
4902 sed "s/^/$as_me: WARNING: /" >&2
4903 ;;
c0d27fcc
MR
4904 no:yes )
4905 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4906echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4907 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4908echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
4909 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
4910echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4911 (
4912 cat <<\_ASBOX
4913## ------------------------------------ ##
4914## Report this to bug-autoconf@gnu.org. ##
4915## ------------------------------------ ##
4916_ASBOX
4917 ) |
4918 sed "s/^/$as_me: WARNING: /" >&2
4919 ;;
c0d27fcc
MR
4920esac
4921echo "$as_me:$LINENO: checking for $ac_header" >&5
4922echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4923if eval "test \"\${$as_ac_Header+set}\" = set"; then
4924 echo $ECHO_N "(cached) $ECHO_C" >&6
4925else
4926 eval "$as_ac_Header=$ac_header_preproc"
f4988be7 4927fi
c0d27fcc 4928echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 4929echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
4930
4931fi
98418dba 4932if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 4933 cat >>confdefs.h <<_ACEOF
98418dba 4934#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 4935_ACEOF
f4988be7
GM
4936
4937fi
c0d27fcc 4938
98418dba
CW
4939done
4940
4941 # Emulation library used on NetBSD.
c0d27fcc 4942 echo "$as_me:$LINENO: checking for _oss_ioctl in -lossaudio" >&5
98418dba
CW
4943echo $ECHO_N "checking for _oss_ioctl in -lossaudio... $ECHO_C" >&6
4944if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then
503d2be0 4945 echo $ECHO_N "(cached) $ECHO_C" >&6
f4988be7 4946else
98418dba
CW
4947 ac_check_lib_save_LIBS=$LIBS
4948LIBS="-lossaudio $LIBS"
4949cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 4950#line $LINENO "configure"
cd958eb3
MB
4951/* confdefs.h. */
4952_ACEOF
4953cat confdefs.h >>conftest.$ac_ext
4954cat >>conftest.$ac_ext <<_ACEOF
4955/* end confdefs.h. */
98418dba
CW
4956
4957/* Override any gcc2 internal prototype to avoid an error. */
4958#ifdef __cplusplus
4959extern "C"
f4988be7 4960#endif
98418dba
CW
4961/* We use char because int might match the return type of a gcc2
4962 builtin and then its argument prototype would still apply. */
4963char _oss_ioctl ();
503d2be0
AS
4964int
4965main ()
4966{
98418dba 4967_oss_ioctl ();
503d2be0
AS
4968 ;
4969 return 0;
4970}
4971_ACEOF
98418dba 4972rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 4973if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 4974 (eval $ac_link) 2>&5
503d2be0 4975 ac_status=$?
c0d27fcc 4976 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4977 (exit $ac_status); } &&
98418dba 4978 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 4979 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
4980 (eval $ac_try) 2>&5
4981 ac_status=$?
c0d27fcc 4982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 4983 (exit $ac_status); }; }; then
98418dba 4984 ac_cv_lib_ossaudio__oss_ioctl=yes
f4988be7 4985else
503d2be0 4986 echo "$as_me: failed program was:" >&5
cd958eb3
MB
4987sed 's/^/| /' conftest.$ac_ext >&5
4988
98418dba 4989ac_cv_lib_ossaudio__oss_ioctl=no
f4988be7 4990fi
98418dba
CW
4991rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4992LIBS=$ac_check_lib_save_LIBS
f4988be7 4993fi
c0d27fcc 4994echo "$as_me:$LINENO: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
98418dba
CW
4995echo "${ECHO_T}$ac_cv_lib_ossaudio__oss_ioctl" >&6
4996if test $ac_cv_lib_ossaudio__oss_ioctl = yes; then
4997 LIBSOUND=-lossaudio
4998else
4999 LIBSOUND=
5000fi
5001
c0d27fcc 5002
f4988be7 5003fi
c0d27fcc
MR
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
22044edf
DL
5022
5023
c0d27fcc
MR
5024
5025
f4988be7 5026
98418dba
CW
5027for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
5028 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
c0d27fcc 5029 termcap.h stdio_ext.h fcntl.h term.h strings.h coff.h pty.h sys/mman.h \
22044edf 5030 sys/param.h sys/vlimit.h sys/resource.h
98418dba
CW
5031do
5032as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
5033if eval "test \"\${$as_ac_Header+set}\" = set"; then
5034 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
5035echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5036if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 5037 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
5038fi
5039echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5040echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
f4988be7 5041else
c0d27fcc
MR
5042 # Is the header compilable?
5043echo "$as_me:$LINENO: checking $ac_header usability" >&5
5044echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
5045cat >conftest.$ac_ext <<_ACEOF
5046#line $LINENO "configure"
cd958eb3
MB
5047/* confdefs.h. */
5048_ACEOF
5049cat confdefs.h >>conftest.$ac_ext
5050cat >>conftest.$ac_ext <<_ACEOF
5051/* end confdefs.h. */
c0d27fcc
MR
5052$ac_includes_default
5053#include <$ac_header>
5054_ACEOF
5055rm -f conftest.$ac_objext
5056if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5057 (eval $ac_compile) 2>&5
5058 ac_status=$?
5059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5060 (exit $ac_status); } &&
5061 { ac_try='test -s conftest.$ac_objext'
5062 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5063 (eval $ac_try) 2>&5
5064 ac_status=$?
5065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5066 (exit $ac_status); }; }; then
5067 ac_header_compiler=yes
5068else
5069 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5070sed 's/^/| /' conftest.$ac_ext >&5
5071
c0d27fcc
MR
5072ac_header_compiler=no
5073fi
5074rm -f conftest.$ac_objext conftest.$ac_ext
5075echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5076echo "${ECHO_T}$ac_header_compiler" >&6
5077
5078# Is the header present?
5079echo "$as_me:$LINENO: checking $ac_header presence" >&5
5080echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
5081cat >conftest.$ac_ext <<_ACEOF
5082#line $LINENO "configure"
cd958eb3
MB
5083/* confdefs.h. */
5084_ACEOF
5085cat confdefs.h >>conftest.$ac_ext
5086cat >>conftest.$ac_ext <<_ACEOF
5087/* end confdefs.h. */
98418dba 5088#include <$ac_header>
503d2be0 5089_ACEOF
c0d27fcc 5090if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 5091 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 5092 ac_status=$?
6bae0ccf 5093 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
5094 rm -f conftest.er1
5095 cat conftest.err >&5
c0d27fcc 5096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5097 (exit $ac_status); } >/dev/null; then
5098 if test -s conftest.err; then
5099 ac_cpp_err=$ac_c_preproc_warn_flag
5100 else
5101 ac_cpp_err=
5102 fi
5103else
5104 ac_cpp_err=yes
5105fi
5106if test -z "$ac_cpp_err"; then
c0d27fcc 5107 ac_header_preproc=yes
34ec9ebe 5108else
503d2be0 5109 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5110sed 's/^/| /' conftest.$ac_ext >&5
5111
c0d27fcc 5112 ac_header_preproc=no
34ec9ebe 5113fi
98418dba 5114rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
5115echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5116echo "${ECHO_T}$ac_header_preproc" >&6
5117
5118# So? What about this header?
5119case $ac_header_compiler:$ac_header_preproc in
5120 yes:no )
5121 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5122echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
5123 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
5124echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5125 (
5126 cat <<\_ASBOX
5127## ------------------------------------ ##
5128## Report this to bug-autoconf@gnu.org. ##
5129## ------------------------------------ ##
5130_ASBOX
5131 ) |
5132 sed "s/^/$as_me: WARNING: /" >&2
5133 ;;
c0d27fcc
MR
5134 no:yes )
5135 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5136echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
5137 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5138echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5139 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
5140echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5141 (
5142 cat <<\_ASBOX
5143## ------------------------------------ ##
5144## Report this to bug-autoconf@gnu.org. ##
5145## ------------------------------------ ##
5146_ASBOX
5147 ) |
5148 sed "s/^/$as_me: WARNING: /" >&2
5149 ;;
c0d27fcc
MR
5150esac
5151echo "$as_me:$LINENO: checking for $ac_header" >&5
5152echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5153if eval "test \"\${$as_ac_Header+set}\" = set"; then
5154 echo $ECHO_N "(cached) $ECHO_C" >&6
5155else
5156 eval "$as_ac_Header=$ac_header_preproc"
34ec9ebe 5157fi
c0d27fcc 5158echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 5159echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
5160
5161fi
98418dba 5162if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 5163 cat >>confdefs.h <<_ACEOF
98418dba 5164#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 5165_ACEOF
34ec9ebe 5166
98418dba 5167fi
c0d27fcc 5168
98418dba
CW
5169done
5170
22044edf
DL
5171
5172for ac_header in term.h
5173do
5174as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5175echo "$as_me:$LINENO: checking for $ac_header" >&5
5176echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5177if eval "test \"\${$as_ac_Header+set}\" = set"; then
5178 echo $ECHO_N "(cached) $ECHO_C" >&6
5179else
5180 cat >conftest.$ac_ext <<_ACEOF
5181#line $LINENO "configure"
cd958eb3
MB
5182/* confdefs.h. */
5183_ACEOF
5184cat confdefs.h >>conftest.$ac_ext
5185cat >>conftest.$ac_ext <<_ACEOF
5186/* end confdefs.h. */
22044edf
DL
5187#include <$ac_header>
5188_ACEOF
5189if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5190 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5191 ac_status=$?
5192 grep -v '^ *+' conftest.er1 >conftest.err
5193 rm -f conftest.er1
5194 cat conftest.err >&5
5195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5196 (exit $ac_status); } >/dev/null; then
5197 if test -s conftest.err; then
5198 ac_cpp_err=$ac_c_preproc_warn_flag
5199 else
5200 ac_cpp_err=
5201 fi
5202else
5203 ac_cpp_err=yes
5204fi
5205if test -z "$ac_cpp_err"; then
5206 eval "$as_ac_Header=yes"
5207else
5208 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5209sed 's/^/| /' conftest.$ac_ext >&5
5210
22044edf
DL
5211 eval "$as_ac_Header=no"
5212fi
5213rm -f conftest.err conftest.$ac_ext
5214fi
5215echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
5216echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
5217if test `eval echo '${'$as_ac_Header'}'` = yes; then
5218 cat >>confdefs.h <<_ACEOF
5219#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5220_ACEOF
5221
5222fi
5223
5224done
5225
c0d27fcc 5226echo "$as_me:$LINENO: checking for ANSI C header files" >&5
98418dba
CW
5227echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5228if test "${ac_cv_header_stdc+set}" = set; then
503d2be0 5229 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5230else
503d2be0 5231 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5232#line $LINENO "configure"
cd958eb3
MB
5233/* confdefs.h. */
5234_ACEOF
5235cat confdefs.h >>conftest.$ac_ext
5236cat >>conftest.$ac_ext <<_ACEOF
5237/* end confdefs.h. */
98418dba
CW
5238#include <stdlib.h>
5239#include <stdarg.h>
5240#include <string.h>
5241#include <float.h>
5242
cd958eb3
MB
5243int
5244main ()
5245{
5246
5247 ;
5248 return 0;
5249}
98418dba 5250_ACEOF
cd958eb3
MB
5251rm -f conftest.$ac_objext
5252if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5253 (eval $ac_compile) 2>&5
503d2be0 5254 ac_status=$?
c0d27fcc 5255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
cd958eb3
MB
5256 (exit $ac_status); } &&
5257 { ac_try='test -s conftest.$ac_objext'
5258 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5259 (eval $ac_try) 2>&5
5260 ac_status=$?
5261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5262 (exit $ac_status); }; }; then
98418dba 5263 ac_cv_header_stdc=yes
ba4481b5 5264else
503d2be0 5265 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5266sed 's/^/| /' conftest.$ac_ext >&5
5267
5268ac_cv_header_stdc=no
ba4481b5 5269fi
cd958eb3 5270rm -f conftest.$ac_objext conftest.$ac_ext
98418dba
CW
5271
5272if test $ac_cv_header_stdc = yes; then
5273 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5274 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5275#line $LINENO "configure"
cd958eb3
MB
5276/* confdefs.h. */
5277_ACEOF
5278cat confdefs.h >>conftest.$ac_ext
5279cat >>conftest.$ac_ext <<_ACEOF
5280/* end confdefs.h. */
98418dba
CW
5281#include <string.h>
5282
5283_ACEOF
5284if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5285 $EGREP "memchr" >/dev/null 2>&1; then
98418dba
CW
5286 :
5287else
5288 ac_cv_header_stdc=no
ba4481b5 5289fi
98418dba 5290rm -f conftest*
ba4481b5
DL
5291
5292fi
5293
98418dba
CW
5294if test $ac_cv_header_stdc = yes; then
5295 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5296 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5297#line $LINENO "configure"
cd958eb3
MB
5298/* confdefs.h. */
5299_ACEOF
5300cat confdefs.h >>conftest.$ac_ext
5301cat >>conftest.$ac_ext <<_ACEOF
5302/* end confdefs.h. */
98418dba
CW
5303#include <stdlib.h>
5304
5305_ACEOF
5306if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 5307 $EGREP "free" >/dev/null 2>&1; then
98418dba
CW
5308 :
5309else
5310 ac_cv_header_stdc=no
5311fi
5312rm -f conftest*
5313
5314fi
5315
5316if test $ac_cv_header_stdc = yes; then
5317 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5318 if test "$cross_compiling" = yes; then
5319 :
d42122a3 5320else
503d2be0 5321 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5322#line $LINENO "configure"
cd958eb3
MB
5323/* confdefs.h. */
5324_ACEOF
5325cat confdefs.h >>conftest.$ac_ext
5326cat >>conftest.$ac_ext <<_ACEOF
5327/* end confdefs.h. */
98418dba
CW
5328#include <ctype.h>
5329#if ((' ' & 0x0FF) == 0x020)
5330# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5331# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5332#else
cd958eb3
MB
5333# define ISLOWER(c) \
5334 (('a' <= (c) && (c) <= 'i') \
98418dba
CW
5335 || ('j' <= (c) && (c) <= 'r') \
5336 || ('s' <= (c) && (c) <= 'z'))
5337# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5338#endif
5339
5340#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
503d2be0
AS
5341int
5342main ()
5343{
98418dba
CW
5344 int i;
5345 for (i = 0; i < 256; i++)
5346 if (XOR (islower (i), ISLOWER (i))
5347 || toupper (i) != TOUPPER (i))
5348 exit(2);
5349 exit (0);
503d2be0
AS
5350}
5351_ACEOF
98418dba 5352rm -f conftest$ac_exeext
c0d27fcc 5353if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 5354 (eval $ac_link) 2>&5
503d2be0 5355 ac_status=$?
c0d27fcc 5356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 5357 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 5358 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5359 (eval $ac_try) 2>&5
5360 ac_status=$?
c0d27fcc 5361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5362 (exit $ac_status); }; }; then
98418dba 5363 :
d42122a3 5364else
98418dba
CW
5365 echo "$as_me: program exited with status $ac_status" >&5
5366echo "$as_me: failed program was:" >&5
cd958eb3
MB
5367sed 's/^/| /' conftest.$ac_ext >&5
5368
c0d27fcc 5369( exit $ac_status )
98418dba 5370ac_cv_header_stdc=no
d42122a3 5371fi
6bae0ccf 5372rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
d42122a3 5373fi
98418dba
CW
5374fi
5375fi
c0d27fcc 5376echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
98418dba
CW
5377echo "${ECHO_T}$ac_cv_header_stdc" >&6
5378if test $ac_cv_header_stdc = yes; then
5379
c0d27fcc 5380cat >>confdefs.h <<\_ACEOF
98418dba 5381#define STDC_HEADERS 1
c0d27fcc 5382_ACEOF
d42122a3
DL
5383
5384fi
5385
c0d27fcc 5386echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
98418dba
CW
5387echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5388if test "${ac_cv_header_time+set}" = set; then
503d2be0 5389 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5390else
503d2be0 5391 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5392#line $LINENO "configure"
cd958eb3
MB
5393/* confdefs.h. */
5394_ACEOF
5395cat confdefs.h >>conftest.$ac_ext
5396cat >>conftest.$ac_ext <<_ACEOF
5397/* end confdefs.h. */
ba4481b5 5398#include <sys/types.h>
98418dba 5399#include <sys/time.h>
ba4481b5 5400#include <time.h>
503d2be0
AS
5401
5402int
5403main ()
5404{
98418dba
CW
5405if ((struct tm *) 0)
5406return 0;
503d2be0
AS
5407 ;
5408 return 0;
5409}
5410_ACEOF
5411rm -f conftest.$ac_objext
c0d27fcc 5412if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5413 (eval $ac_compile) 2>&5
5414 ac_status=$?
c0d27fcc 5415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5416 (exit $ac_status); } &&
5417 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5418 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5419 (eval $ac_try) 2>&5
5420 ac_status=$?
c0d27fcc 5421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5422 (exit $ac_status); }; }; then
98418dba 5423 ac_cv_header_time=yes
ba4481b5 5424else
503d2be0 5425 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5426sed 's/^/| /' conftest.$ac_ext >&5
5427
98418dba 5428ac_cv_header_time=no
ba4481b5 5429fi
503d2be0 5430rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5431fi
c0d27fcc 5432echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
98418dba
CW
5433echo "${ECHO_T}$ac_cv_header_time" >&6
5434if test $ac_cv_header_time = yes; then
503d2be0 5435
c0d27fcc 5436cat >>confdefs.h <<\_ACEOF
98418dba 5437#define TIME_WITH_SYS_TIME 1
c0d27fcc 5438_ACEOF
ba4481b5
DL
5439
5440fi
5441
cd958eb3
MB
5442echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
5443echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6
5444if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
503d2be0 5445 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5446else
503d2be0 5447 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5448#line $LINENO "configure"
cd958eb3
MB
5449/* confdefs.h. */
5450_ACEOF
5451cat confdefs.h >>conftest.$ac_ext
5452cat >>conftest.$ac_ext <<_ACEOF
5453/* end confdefs.h. */
5454$ac_includes_default
5455int
5456main ()
5457{
5458#ifndef sys_siglist
5459 char *p = (char *) sys_siglist;
98418dba 5460#endif
503d2be0 5461
cd958eb3
MB
5462 ;
5463 return 0;
5464}
5465_ACEOF
5466rm -f conftest.$ac_objext
5467if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5468 (eval $ac_compile) 2>&5
5469 ac_status=$?
5470 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5471 (exit $ac_status); } &&
5472 { ac_try='test -s conftest.$ac_objext'
5473 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5474 (eval $ac_try) 2>&5
5475 ac_status=$?
5476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5477 (exit $ac_status); }; }; then
5478 ac_cv_have_decl_sys_siglist=yes
5479else
5480 echo "$as_me: failed program was:" >&5
5481sed 's/^/| /' conftest.$ac_ext >&5
5482
5483ac_cv_have_decl_sys_siglist=no
5484fi
5485rm -f conftest.$ac_objext conftest.$ac_ext
5486fi
5487echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
5488echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6
5489if test $ac_cv_have_decl_sys_siglist = yes; then
5490
5491cat >>confdefs.h <<_ACEOF
5492#define HAVE_DECL_SYS_SIGLIST 1
5493_ACEOF
5494
5495
5496else
5497 cat >>confdefs.h <<_ACEOF
5498#define HAVE_DECL_SYS_SIGLIST 0
5499_ACEOF
5500
5501
5502fi
5503
5504
5505if test $ac_cv_have_decl_sys_siglist != yes; then
5506 # For Tru64, at least:
5507 echo "$as_me:$LINENO: checking whether __sys_siglist is declared" >&5
5508echo $ECHO_N "checking whether __sys_siglist is declared... $ECHO_C" >&6
5509if test "${ac_cv_have_decl___sys_siglist+set}" = set; then
5510 echo $ECHO_N "(cached) $ECHO_C" >&6
5511else
5512 cat >conftest.$ac_ext <<_ACEOF
5513#line $LINENO "configure"
5514/* confdefs.h. */
5515_ACEOF
5516cat confdefs.h >>conftest.$ac_ext
5517cat >>conftest.$ac_ext <<_ACEOF
5518/* end confdefs.h. */
5519$ac_includes_default
503d2be0
AS
5520int
5521main ()
5522{
cd958eb3
MB
5523#ifndef __sys_siglist
5524 char *p = (char *) __sys_siglist;
5525#endif
5526
503d2be0
AS
5527 ;
5528 return 0;
5529}
5530_ACEOF
5531rm -f conftest.$ac_objext
c0d27fcc 5532if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5533 (eval $ac_compile) 2>&5
5534 ac_status=$?
c0d27fcc 5535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5536 (exit $ac_status); } &&
5537 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5539 (eval $ac_try) 2>&5
5540 ac_status=$?
c0d27fcc 5541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5542 (exit $ac_status); }; }; then
cd958eb3 5543 ac_cv_have_decl___sys_siglist=yes
ba4481b5 5544else
503d2be0 5545 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5546sed 's/^/| /' conftest.$ac_ext >&5
5547
5548ac_cv_have_decl___sys_siglist=no
ba4481b5 5549fi
503d2be0
AS
5550rm -f conftest.$ac_objext conftest.$ac_ext
5551fi
cd958eb3
MB
5552echo "$as_me:$LINENO: result: $ac_cv_have_decl___sys_siglist" >&5
5553echo "${ECHO_T}$ac_cv_have_decl___sys_siglist" >&6
5554if test $ac_cv_have_decl___sys_siglist = yes; then
503d2be0 5555
cd958eb3
MB
5556cat >>confdefs.h <<_ACEOF
5557#define HAVE_DECL___SYS_SIGLIST 1
5558_ACEOF
5559
5560
5561else
5562 cat >>confdefs.h <<_ACEOF
5563#define HAVE_DECL___SYS_SIGLIST 0
c0d27fcc 5564_ACEOF
503d2be0 5565
cd958eb3 5566
ba4481b5
DL
5567fi
5568
cd958eb3
MB
5569
5570 if test $ac_cv_have_decl___sys_siglist = yes; then
5571
5572cat >>confdefs.h <<\_ACEOF
5573#define sys_siglist __sys_siglist
5574_ACEOF
5575
5576 fi
5577fi
c0d27fcc 5578echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
98418dba
CW
5579echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
5580if test "${ac_cv_header_sys_wait_h+set}" = set; then
503d2be0 5581 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5582else
503d2be0 5583 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5584#line $LINENO "configure"
cd958eb3
MB
5585/* confdefs.h. */
5586_ACEOF
5587cat confdefs.h >>conftest.$ac_ext
5588cat >>conftest.$ac_ext <<_ACEOF
5589/* end confdefs.h. */
98418dba
CW
5590#include <sys/types.h>
5591#include <sys/wait.h>
5592#ifndef WEXITSTATUS
5593# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5594#endif
5595#ifndef WIFEXITED
5596# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
ba4481b5 5597#endif
503d2be0
AS
5598
5599int
5600main ()
5601{
98418dba
CW
5602 int s;
5603 wait (&s);
5604 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
503d2be0
AS
5605 ;
5606 return 0;
5607}
5608_ACEOF
98418dba 5609rm -f conftest.$ac_objext
c0d27fcc 5610if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 5611 (eval $ac_compile) 2>&5
503d2be0 5612 ac_status=$?
c0d27fcc 5613 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5614 (exit $ac_status); } &&
98418dba 5615 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5616 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5617 (eval $ac_try) 2>&5
5618 ac_status=$?
c0d27fcc 5619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5620 (exit $ac_status); }; }; then
98418dba 5621 ac_cv_header_sys_wait_h=yes
ba4481b5 5622else
503d2be0 5623 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5624sed 's/^/| /' conftest.$ac_ext >&5
5625
98418dba 5626ac_cv_header_sys_wait_h=no
ba4481b5 5627fi
98418dba 5628rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5629fi
c0d27fcc 5630echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
98418dba
CW
5631echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
5632if test $ac_cv_header_sys_wait_h = yes; then
503d2be0 5633
c0d27fcc 5634cat >>confdefs.h <<\_ACEOF
98418dba 5635#define HAVE_SYS_WAIT_H 1
c0d27fcc 5636_ACEOF
ba4481b5 5637
ba4481b5
DL
5638fi
5639
c0d27fcc
MR
5640
5641echo "$as_me:$LINENO: checking for struct utimbuf" >&5
98418dba
CW
5642echo $ECHO_N "checking for struct utimbuf... $ECHO_C" >&6
5643if test "${emacs_cv_struct_utimbuf+set}" = set; then
503d2be0 5644 echo $ECHO_N "(cached) $ECHO_C" >&6
1113b624 5645else
503d2be0 5646 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5647#line $LINENO "configure"
cd958eb3
MB
5648/* confdefs.h. */
5649_ACEOF
5650cat confdefs.h >>conftest.$ac_ext
5651cat >>conftest.$ac_ext <<_ACEOF
5652/* end confdefs.h. */
98418dba
CW
5653#ifdef TIME_WITH_SYS_TIME
5654#include <sys/time.h>
5655#include <time.h>
5656#else
5657#ifdef HAVE_SYS_TIME_H
5658#include <sys/time.h>
5659#else
1113b624 5660#include <time.h>
98418dba
CW
5661#endif
5662#endif
5663#ifdef HAVE_UTIME_H
5664#include <utime.h>
5665#endif
503d2be0
AS
5666int
5667main ()
5668{
98418dba 5669static struct utimbuf x; x.actime = x.modtime;
503d2be0
AS
5670 ;
5671 return 0;
5672}
5673_ACEOF
98418dba 5674rm -f conftest.$ac_objext
c0d27fcc 5675if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 5676 (eval $ac_compile) 2>&5
503d2be0 5677 ac_status=$?
c0d27fcc 5678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5679 (exit $ac_status); } &&
98418dba 5680 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5682 (eval $ac_try) 2>&5
5683 ac_status=$?
c0d27fcc 5684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5685 (exit $ac_status); }; }; then
98418dba 5686 emacs_cv_struct_utimbuf=yes
1113b624 5687else
503d2be0 5688 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5689sed 's/^/| /' conftest.$ac_ext >&5
5690
98418dba 5691emacs_cv_struct_utimbuf=no
1113b624 5692fi
98418dba 5693rm -f conftest.$ac_objext conftest.$ac_ext
1113b624 5694fi
c0d27fcc 5695echo "$as_me:$LINENO: result: $emacs_cv_struct_utimbuf" >&5
98418dba
CW
5696echo "${ECHO_T}$emacs_cv_struct_utimbuf" >&6
5697if test $emacs_cv_struct_utimbuf = yes; then
b936fae4 5698
c0d27fcc 5699cat >>confdefs.h <<\_ACEOF
98418dba 5700#define HAVE_STRUCT_UTIMBUF 1
c0d27fcc 5701_ACEOF
1113b624
PE
5702
5703fi
ba4481b5 5704
c0d27fcc 5705echo "$as_me:$LINENO: checking return type of signal handlers" >&5
98418dba
CW
5706echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5707if test "${ac_cv_type_signal+set}" = set; then
503d2be0 5708 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5709else
98418dba 5710 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5711#line $LINENO "configure"
cd958eb3
MB
5712/* confdefs.h. */
5713_ACEOF
5714cat confdefs.h >>conftest.$ac_ext
5715cat >>conftest.$ac_ext <<_ACEOF
5716/* end confdefs.h. */
7397acc4 5717#include <sys/types.h>
98418dba
CW
5718#include <signal.h>
5719#ifdef signal
5720# undef signal
5721#endif
5722#ifdef __cplusplus
5723extern "C" void (*signal (int, void (*)(int)))(int);
5724#else
5725void (*signal ()) ();
5726#endif
5727
503d2be0
AS
5728int
5729main ()
5730{
98418dba 5731int i;
503d2be0
AS
5732 ;
5733 return 0;
5734}
5735_ACEOF
98418dba 5736rm -f conftest.$ac_objext
c0d27fcc 5737if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5738 (eval $ac_compile) 2>&5
5739 ac_status=$?
c0d27fcc 5740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5741 (exit $ac_status); } &&
5742 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5744 (eval $ac_try) 2>&5
5745 ac_status=$?
c0d27fcc 5746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5747 (exit $ac_status); }; }; then
98418dba 5748 ac_cv_type_signal=void
503d2be0
AS
5749else
5750 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5751sed 's/^/| /' conftest.$ac_ext >&5
5752
98418dba 5753ac_cv_type_signal=int
503d2be0 5754fi
98418dba 5755rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5756fi
c0d27fcc 5757echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
98418dba 5758echo "${ECHO_T}$ac_cv_type_signal" >&6
7397acc4 5759
c0d27fcc 5760cat >>confdefs.h <<_ACEOF
98418dba 5761#define RETSIGTYPE $ac_cv_type_signal
c0d27fcc
MR
5762_ACEOF
5763
503d2be0 5764
c0d27fcc
MR
5765
5766echo "$as_me:$LINENO: checking for speed_t" >&5
98418dba
CW
5767echo $ECHO_N "checking for speed_t... $ECHO_C" >&6
5768if test "${emacs_cv_speed_t+set}" = set; then
5769 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5770else
98418dba 5771 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5772#line $LINENO "configure"
cd958eb3
MB
5773/* confdefs.h. */
5774_ACEOF
5775cat confdefs.h >>conftest.$ac_ext
5776cat >>conftest.$ac_ext <<_ACEOF
5777/* end confdefs.h. */
98418dba 5778#include <termios.h>
98418dba
CW
5779int
5780main ()
5781{
5782speed_t x = 1;
5783 ;
5784 return 0;
5785}
5786_ACEOF
5787rm -f conftest.$ac_objext
c0d27fcc 5788if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
5789 (eval $ac_compile) 2>&5
5790 ac_status=$?
c0d27fcc 5791 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5792 (exit $ac_status); } &&
5793 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5794 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
5795 (eval $ac_try) 2>&5
5796 ac_status=$?
c0d27fcc 5797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
5798 (exit $ac_status); }; }; then
5799 emacs_cv_speed_t=yes
5800else
5801 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5802sed 's/^/| /' conftest.$ac_ext >&5
5803
98418dba
CW
5804emacs_cv_speed_t=no
5805fi
5806rm -f conftest.$ac_objext conftest.$ac_ext
5807fi
c0d27fcc 5808echo "$as_me:$LINENO: result: $emacs_cv_speed_t" >&5
98418dba
CW
5809echo "${ECHO_T}$emacs_cv_speed_t" >&6
5810if test $emacs_cv_speed_t = yes; then
b936fae4 5811
c0d27fcc 5812cat >>confdefs.h <<\_ACEOF
98418dba 5813#define HAVE_SPEED_T 1
c0d27fcc 5814_ACEOF
98418dba 5815
7397acc4
DL
5816fi
5817
c0d27fcc 5818echo "$as_me:$LINENO: checking for struct timeval" >&5
98418dba
CW
5819echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6
5820if test "${emacs_cv_struct_timeval+set}" = set; then
503d2be0 5821 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5822else
503d2be0 5823 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5824#line $LINENO "configure"
cd958eb3
MB
5825/* confdefs.h. */
5826_ACEOF
5827cat confdefs.h >>conftest.$ac_ext
5828cat >>conftest.$ac_ext <<_ACEOF
5829/* end confdefs.h. */
98418dba
CW
5830#ifdef TIME_WITH_SYS_TIME
5831#include <sys/time.h>
5832#include <time.h>
5833#else
5834#ifdef HAVE_SYS_TIME_H
5835#include <sys/time.h>
5836#else
5837#include <time.h>
5838#endif
5839#endif
503d2be0
AS
5840int
5841main ()
5842{
98418dba 5843static struct timeval x; x.tv_sec = x.tv_usec;
503d2be0
AS
5844 ;
5845 return 0;
5846}
5847_ACEOF
5848rm -f conftest.$ac_objext
c0d27fcc 5849if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5850 (eval $ac_compile) 2>&5
5851 ac_status=$?
c0d27fcc 5852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5853 (exit $ac_status); } &&
5854 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5855 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5856 (eval $ac_try) 2>&5
5857 ac_status=$?
c0d27fcc 5858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5859 (exit $ac_status); }; }; then
98418dba 5860 emacs_cv_struct_timeval=yes
7397acc4 5861else
503d2be0 5862 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5863sed 's/^/| /' conftest.$ac_ext >&5
5864
98418dba 5865emacs_cv_struct_timeval=no
7397acc4 5866fi
503d2be0 5867rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5868fi
c0d27fcc 5869echo "$as_me:$LINENO: result: $emacs_cv_struct_timeval" >&5
98418dba
CW
5870echo "${ECHO_T}$emacs_cv_struct_timeval" >&6
5871HAVE_TIMEVAL=$emacs_cv_struct_timeval
5872if test $emacs_cv_struct_timeval = yes; then
b936fae4 5873
c0d27fcc 5874cat >>confdefs.h <<\_ACEOF
98418dba 5875#define HAVE_TIMEVAL 1
c0d27fcc 5876_ACEOF
7397acc4
DL
5877
5878fi
5879
c0d27fcc 5880echo "$as_me:$LINENO: checking for struct exception" >&5
98418dba
CW
5881echo $ECHO_N "checking for struct exception... $ECHO_C" >&6
5882if test "${emacs_cv_struct_exception+set}" = set; then
503d2be0 5883 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5884else
503d2be0 5885 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5886#line $LINENO "configure"
cd958eb3
MB
5887/* confdefs.h. */
5888_ACEOF
5889cat confdefs.h >>conftest.$ac_ext
5890cat >>conftest.$ac_ext <<_ACEOF
5891/* end confdefs.h. */
98418dba 5892#include <math.h>
503d2be0
AS
5893int
5894main ()
5895{
98418dba 5896static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
503d2be0
AS
5897 ;
5898 return 0;
ba4481b5 5899}
503d2be0
AS
5900_ACEOF
5901rm -f conftest.$ac_objext
c0d27fcc 5902if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5903 (eval $ac_compile) 2>&5
5904 ac_status=$?
c0d27fcc 5905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5906 (exit $ac_status); } &&
5907 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5908 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5909 (eval $ac_try) 2>&5
5910 ac_status=$?
c0d27fcc 5911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5912 (exit $ac_status); }; }; then
98418dba 5913 emacs_cv_struct_exception=yes
ba4481b5 5914else
503d2be0 5915 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5916sed 's/^/| /' conftest.$ac_ext >&5
5917
98418dba 5918emacs_cv_struct_exception=no
ba4481b5 5919fi
503d2be0 5920rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 5921fi
c0d27fcc 5922echo "$as_me:$LINENO: result: $emacs_cv_struct_exception" >&5
98418dba
CW
5923echo "${ECHO_T}$emacs_cv_struct_exception" >&6
5924HAVE_EXCEPTION=$emacs_cv_struct_exception
5925if test $emacs_cv_struct_exception != yes; then
b936fae4 5926
c0d27fcc 5927cat >>confdefs.h <<\_ACEOF
98418dba 5928#define NO_MATHERR 1
c0d27fcc 5929_ACEOF
ba4481b5
DL
5930
5931fi
5932
c0d27fcc 5933echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
98418dba
CW
5934echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
5935if test "${ac_cv_struct_tm+set}" = set; then
503d2be0 5936 echo $ECHO_N "(cached) $ECHO_C" >&6
7397acc4 5937else
503d2be0 5938 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5939#line $LINENO "configure"
cd958eb3
MB
5940/* confdefs.h. */
5941_ACEOF
5942cat confdefs.h >>conftest.$ac_ext
5943cat >>conftest.$ac_ext <<_ACEOF
5944/* end confdefs.h. */
98418dba
CW
5945#include <sys/types.h>
5946#include <time.h>
7397acc4 5947
503d2be0
AS
5948int
5949main ()
5950{
98418dba 5951struct tm *tp; tp->tm_sec;
503d2be0
AS
5952 ;
5953 return 0;
5954}
5955_ACEOF
5956rm -f conftest.$ac_objext
c0d27fcc 5957if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
5958 (eval $ac_compile) 2>&5
5959 ac_status=$?
c0d27fcc 5960 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
5961 (exit $ac_status); } &&
5962 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 5963 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
5964 (eval $ac_try) 2>&5
5965 ac_status=$?
c0d27fcc 5966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 5967 (exit $ac_status); }; }; then
98418dba 5968 ac_cv_struct_tm=time.h
7397acc4 5969else
503d2be0 5970 echo "$as_me: failed program was:" >&5
cd958eb3
MB
5971sed 's/^/| /' conftest.$ac_ext >&5
5972
98418dba 5973ac_cv_struct_tm=sys/time.h
7397acc4 5974fi
503d2be0 5975rm -f conftest.$ac_objext conftest.$ac_ext
7397acc4 5976fi
c0d27fcc 5977echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
98418dba
CW
5978echo "${ECHO_T}$ac_cv_struct_tm" >&6
5979if test $ac_cv_struct_tm = sys/time.h; then
7397acc4 5980
c0d27fcc 5981cat >>confdefs.h <<\_ACEOF
98418dba 5982#define TM_IN_SYS_TIME 1
c0d27fcc 5983_ACEOF
7397acc4
DL
5984
5985fi
ba4481b5 5986
c0d27fcc 5987echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
98418dba
CW
5988echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
5989if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
503d2be0 5990 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 5991else
98418dba 5992 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 5993#line $LINENO "configure"
cd958eb3
MB
5994/* confdefs.h. */
5995_ACEOF
5996cat confdefs.h >>conftest.$ac_ext
5997cat >>conftest.$ac_ext <<_ACEOF
5998/* end confdefs.h. */
98418dba
CW
5999#include <sys/types.h>
6000#include <$ac_cv_struct_tm>
ba4481b5 6001
c0d27fcc 6002
98418dba
CW
6003int
6004main ()
6005{
6006static struct tm ac_aggr;
6007if (ac_aggr.tm_zone)
6008return 0;
6009 ;
6010 return 0;
6011}
6012_ACEOF
6013rm -f conftest.$ac_objext
c0d27fcc 6014if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6015 (eval $ac_compile) 2>&5
6016 ac_status=$?
c0d27fcc 6017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6018 (exit $ac_status); } &&
6019 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6020 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6021 (eval $ac_try) 2>&5
6022 ac_status=$?
c0d27fcc 6023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6024 (exit $ac_status); }; }; then
6025 ac_cv_member_struct_tm_tm_zone=yes
ba4481b5 6026else
98418dba 6027 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6028sed 's/^/| /' conftest.$ac_ext >&5
6029
6bae0ccf
DL
6030cat >conftest.$ac_ext <<_ACEOF
6031#line $LINENO "configure"
cd958eb3
MB
6032/* confdefs.h. */
6033_ACEOF
6034cat confdefs.h >>conftest.$ac_ext
6035cat >>conftest.$ac_ext <<_ACEOF
6036/* end confdefs.h. */
6bae0ccf
DL
6037#include <sys/types.h>
6038#include <$ac_cv_struct_tm>
6039
6040
6041int
6042main ()
6043{
6044static struct tm ac_aggr;
6045if (sizeof ac_aggr.tm_zone)
6046return 0;
6047 ;
6048 return 0;
6049}
6050_ACEOF
6051rm -f conftest.$ac_objext
6052if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6053 (eval $ac_compile) 2>&5
6054 ac_status=$?
6055 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6056 (exit $ac_status); } &&
6057 { ac_try='test -s conftest.$ac_objext'
6058 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6059 (eval $ac_try) 2>&5
6060 ac_status=$?
6061 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6062 (exit $ac_status); }; }; then
6063 ac_cv_member_struct_tm_tm_zone=yes
6064else
6065 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6066sed 's/^/| /' conftest.$ac_ext >&5
6067
98418dba 6068ac_cv_member_struct_tm_tm_zone=no
ba4481b5 6069fi
98418dba 6070rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 6071fi
6bae0ccf
DL
6072rm -f conftest.$ac_objext conftest.$ac_ext
6073fi
c0d27fcc 6074echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
98418dba
CW
6075echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
6076if test $ac_cv_member_struct_tm_tm_zone = yes; then
503d2be0 6077
c0d27fcc 6078cat >>confdefs.h <<_ACEOF
98418dba 6079#define HAVE_STRUCT_TM_TM_ZONE 1
c0d27fcc
MR
6080_ACEOF
6081
ba4481b5 6082
98418dba 6083fi
ba4481b5 6084
98418dba 6085if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
ba4481b5 6086
c0d27fcc 6087cat >>confdefs.h <<\_ACEOF
98418dba 6088#define HAVE_TM_ZONE 1
c0d27fcc 6089_ACEOF
ba4481b5 6090
ba4481b5 6091else
c0d27fcc 6092 echo "$as_me:$LINENO: checking for tzname" >&5
98418dba
CW
6093echo $ECHO_N "checking for tzname... $ECHO_C" >&6
6094if test "${ac_cv_var_tzname+set}" = set; then
503d2be0 6095 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 6096else
98418dba 6097 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6098#line $LINENO "configure"
cd958eb3
MB
6099/* confdefs.h. */
6100_ACEOF
6101cat confdefs.h >>conftest.$ac_ext
6102cat >>conftest.$ac_ext <<_ACEOF
6103/* end confdefs.h. */
98418dba
CW
6104#include <time.h>
6105#ifndef tzname /* For SGI. */
6106extern char *tzname[]; /* RS6000 and others reject char **tzname. */
6107#endif
6108
98418dba
CW
6109int
6110main ()
6111{
6112atoi(*tzname);
6113 ;
6114 return 0;
6115}
6116_ACEOF
6117rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6118if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6119 (eval $ac_link) 2>&5
6120 ac_status=$?
c0d27fcc 6121 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6122 (exit $ac_status); } &&
6123 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6124 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6125 (eval $ac_try) 2>&5
6126 ac_status=$?
c0d27fcc 6127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6128 (exit $ac_status); }; }; then
6129 ac_cv_var_tzname=yes
6130else
6131 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6132sed 's/^/| /' conftest.$ac_ext >&5
6133
98418dba 6134ac_cv_var_tzname=no
ba4481b5 6135fi
98418dba
CW
6136rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6137fi
c0d27fcc 6138echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
98418dba
CW
6139echo "${ECHO_T}$ac_cv_var_tzname" >&6
6140 if test $ac_cv_var_tzname = yes; then
ba4481b5 6141
c0d27fcc 6142cat >>confdefs.h <<\_ACEOF
98418dba 6143#define HAVE_TZNAME 1
c0d27fcc 6144_ACEOF
503d2be0 6145
98418dba
CW
6146 fi
6147fi
503d2be0 6148
c0d27fcc 6149echo "$as_me:$LINENO: checking for struct tm.tm_gmtoff" >&5
b936fae4
AS
6150echo $ECHO_N "checking for struct tm.tm_gmtoff... $ECHO_C" >&6
6151if test "${ac_cv_member_struct_tm_tm_gmtoff+set}" = set; then
98418dba
CW
6152 echo $ECHO_N "(cached) $ECHO_C" >&6
6153else
6154 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6155#line $LINENO "configure"
cd958eb3
MB
6156/* confdefs.h. */
6157_ACEOF
6158cat confdefs.h >>conftest.$ac_ext
6159cat >>conftest.$ac_ext <<_ACEOF
6160/* end confdefs.h. */
98418dba 6161#include <time.h>
b936fae4 6162
98418dba
CW
6163int
6164main ()
6165{
b936fae4
AS
6166static struct tm ac_aggr;
6167if (ac_aggr.tm_gmtoff)
6168return 0;
98418dba
CW
6169 ;
6170 return 0;
6171}
6172_ACEOF
b936fae4 6173rm -f conftest.$ac_objext
c0d27fcc 6174if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4 6175 (eval $ac_compile) 2>&5
98418dba 6176 ac_status=$?
c0d27fcc 6177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6178 (exit $ac_status); } &&
b936fae4 6179 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6181 (eval $ac_try) 2>&5
6182 ac_status=$?
c0d27fcc 6183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 6184 (exit $ac_status); }; }; then
b936fae4 6185 ac_cv_member_struct_tm_tm_gmtoff=yes
98418dba
CW
6186else
6187 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6188sed 's/^/| /' conftest.$ac_ext >&5
6189
8799b3e4 6190cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6191#line $LINENO "configure"
cd958eb3
MB
6192/* confdefs.h. */
6193_ACEOF
6194cat confdefs.h >>conftest.$ac_ext
6195cat >>conftest.$ac_ext <<_ACEOF
6196/* end confdefs.h. */
6bae0ccf
DL
6197#include <time.h>
6198
8799b3e4
CW
6199int
6200main ()
6201{
6bae0ccf
DL
6202static struct tm ac_aggr;
6203if (sizeof ac_aggr.tm_gmtoff)
6204return 0;
8799b3e4
CW
6205 ;
6206 return 0;
6207}
6208_ACEOF
6bae0ccf 6209rm -f conftest.$ac_objext
c0d27fcc 6210if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8799b3e4
CW
6211 (eval $ac_compile) 2>&5
6212 ac_status=$?
c0d27fcc 6213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4
CW
6214 (exit $ac_status); } &&
6215 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6216 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8799b3e4
CW
6217 (eval $ac_try) 2>&5
6218 ac_status=$?
c0d27fcc 6219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799b3e4 6220 (exit $ac_status); }; }; then
6bae0ccf 6221 ac_cv_member_struct_tm_tm_gmtoff=yes
8799b3e4
CW
6222else
6223 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6224sed 's/^/| /' conftest.$ac_ext >&5
6225
6bae0ccf 6226ac_cv_member_struct_tm_tm_gmtoff=no
8799b3e4 6227fi
6bae0ccf
DL
6228rm -f conftest.$ac_objext conftest.$ac_ext
6229fi
6230rm -f conftest.$ac_objext conftest.$ac_ext
8799b3e4 6231fi
6bae0ccf
DL
6232echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_gmtoff" >&5
6233echo "${ECHO_T}$ac_cv_member_struct_tm_tm_gmtoff" >&6
6234if test $ac_cv_member_struct_tm_tm_gmtoff = yes; then
6235
6236cat >>confdefs.h <<\_ACEOF
6237#define HAVE_TM_GMTOFF 1
6238_ACEOF
6239
6240fi
6241
8799b3e4 6242
8799b3e4 6243
c0d27fcc 6244echo "$as_me:$LINENO: checking for function prototypes" >&5
98418dba
CW
6245echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6
6246if test "$ac_cv_prog_cc_stdc" != no; then
c0d27fcc 6247 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
6248echo "${ECHO_T}yes" >&6
6249
c0d27fcc 6250cat >>confdefs.h <<\_ACEOF
98418dba 6251#define PROTOTYPES 1
c0d27fcc
MR
6252_ACEOF
6253
6254
6255cat >>confdefs.h <<\_ACEOF
6256#define __PROTOTYPES 1
6257_ACEOF
98418dba
CW
6258
6259else
c0d27fcc 6260 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
6261echo "${ECHO_T}no" >&6
6262fi
6263
c0d27fcc 6264echo "$as_me:$LINENO: checking for working volatile" >&5
98418dba
CW
6265echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
6266if test "${ac_cv_c_volatile+set}" = set; then
6267 echo $ECHO_N "(cached) $ECHO_C" >&6
6268else
6269 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6270#line $LINENO "configure"
cd958eb3
MB
6271/* confdefs.h. */
6272_ACEOF
6273cat confdefs.h >>conftest.$ac_ext
6274cat >>conftest.$ac_ext <<_ACEOF
6275/* end confdefs.h. */
98418dba 6276
98418dba
CW
6277int
6278main ()
6279{
6280
6281volatile int x;
6282int * volatile y;
6283 ;
6284 return 0;
6285}
6286_ACEOF
6287rm -f conftest.$ac_objext
c0d27fcc 6288if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6289 (eval $ac_compile) 2>&5
6290 ac_status=$?
c0d27fcc 6291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6292 (exit $ac_status); } &&
6293 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6294 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6295 (eval $ac_try) 2>&5
6296 ac_status=$?
c0d27fcc 6297 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6298 (exit $ac_status); }; }; then
6299 ac_cv_c_volatile=yes
6300else
6301 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6302sed 's/^/| /' conftest.$ac_ext >&5
6303
98418dba
CW
6304ac_cv_c_volatile=no
6305fi
6306rm -f conftest.$ac_objext conftest.$ac_ext
6307fi
c0d27fcc 6308echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
98418dba
CW
6309echo "${ECHO_T}$ac_cv_c_volatile" >&6
6310if test $ac_cv_c_volatile = no; then
6311
c0d27fcc 6312cat >>confdefs.h <<\_ACEOF
98418dba 6313#define volatile
c0d27fcc 6314_ACEOF
98418dba
CW
6315
6316fi
6317
c0d27fcc 6318echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
98418dba
CW
6319echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
6320if test "${ac_cv_c_const+set}" = set; then
6321 echo $ECHO_N "(cached) $ECHO_C" >&6
6322else
6323 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6324#line $LINENO "configure"
cd958eb3
MB
6325/* confdefs.h. */
6326_ACEOF
6327cat confdefs.h >>conftest.$ac_ext
6328cat >>conftest.$ac_ext <<_ACEOF
6329/* end confdefs.h. */
98418dba 6330
98418dba
CW
6331int
6332main ()
6333{
6334/* FIXME: Include the comments suggested by Paul. */
6335#ifndef __cplusplus
6336 /* Ultrix mips cc rejects this. */
6337 typedef int charset[2];
6338 const charset x;
6339 /* SunOS 4.1.1 cc rejects this. */
6340 char const *const *ccp;
6341 char **p;
6342 /* NEC SVR4.0.2 mips cc rejects this. */
6343 struct point {int x, y;};
6344 static struct point const zero = {0,0};
6345 /* AIX XL C 1.02.0.0 rejects this.
6346 It does not let you subtract one const X* pointer from another in
6347 an arm of an if-expression whose if-part is not a constant
6348 expression */
6349 const char *g = "string";
6350 ccp = &g + (g ? g-g : 0);
6351 /* HPUX 7.0 cc rejects these. */
6352 ++ccp;
6353 p = (char**) ccp;
6354 ccp = (char const *const *) p;
6355 { /* SCO 3.2v4 cc rejects this. */
6356 char *t;
6357 char const *s = 0 ? (char *) 0 : (char const *) 0;
6358
6359 *t++ = 0;
6360 }
6361 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
6362 int x[] = {25, 17};
6363 const int *foo = &x[0];
6364 ++foo;
6365 }
6366 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
6367 typedef const int *iptr;
6368 iptr p = 0;
6369 ++p;
6370 }
6371 { /* AIX XL C 1.02.0.0 rejects this saying
6372 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
6373 struct s { int j; const int *ap[3]; };
6374 struct s *b; b->j = 5;
6375 }
6376 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
6377 const int foo = 10;
6378 }
6379#endif
6380
6381 ;
6382 return 0;
6383}
6384_ACEOF
6385rm -f conftest.$ac_objext
c0d27fcc 6386if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6387 (eval $ac_compile) 2>&5
6388 ac_status=$?
c0d27fcc 6389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6390 (exit $ac_status); } &&
6391 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6393 (eval $ac_try) 2>&5
6394 ac_status=$?
c0d27fcc 6395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6396 (exit $ac_status); }; }; then
6397 ac_cv_c_const=yes
6398else
6399 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6400sed 's/^/| /' conftest.$ac_ext >&5
6401
98418dba
CW
6402ac_cv_c_const=no
6403fi
6404rm -f conftest.$ac_objext conftest.$ac_ext
6405fi
c0d27fcc 6406echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
98418dba
CW
6407echo "${ECHO_T}$ac_cv_c_const" >&6
6408if test $ac_cv_c_const = no; then
6409
c0d27fcc 6410cat >>confdefs.h <<\_ACEOF
98418dba 6411#define const
c0d27fcc 6412_ACEOF
98418dba
CW
6413
6414fi
6415
c0d27fcc 6416echo "$as_me:$LINENO: checking for void * support" >&5
98418dba
CW
6417echo $ECHO_N "checking for void * support... $ECHO_C" >&6
6418if test "${emacs_cv_void_star+set}" = set; then
6419 echo $ECHO_N "(cached) $ECHO_C" >&6
6420else
6421 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6422#line $LINENO "configure"
cd958eb3
MB
6423/* confdefs.h. */
6424_ACEOF
6425cat confdefs.h >>conftest.$ac_ext
6426cat >>conftest.$ac_ext <<_ACEOF
6427/* end confdefs.h. */
98418dba 6428
98418dba
CW
6429int
6430main ()
6431{
6432void * foo;
6433 ;
6434 return 0;
6435}
6436_ACEOF
6437rm -f conftest.$ac_objext
c0d27fcc 6438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
6439 (eval $ac_compile) 2>&5
6440 ac_status=$?
c0d27fcc 6441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6442 (exit $ac_status); } &&
6443 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 6444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6445 (eval $ac_try) 2>&5
6446 ac_status=$?
c0d27fcc 6447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6448 (exit $ac_status); }; }; then
6449 emacs_cv_void_star=yes
6450else
6451 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6452sed 's/^/| /' conftest.$ac_ext >&5
6453
98418dba
CW
6454emacs_cv_void_star=no
6455fi
6456rm -f conftest.$ac_objext conftest.$ac_ext
6457fi
c0d27fcc 6458echo "$as_me:$LINENO: result: $emacs_cv_void_star" >&5
98418dba
CW
6459echo "${ECHO_T}$emacs_cv_void_star" >&6
6460if test $emacs_cv_void_star = yes; then
c0d27fcc 6461 cat >>confdefs.h <<\_ACEOF
98418dba 6462#define POINTER_TYPE void
c0d27fcc 6463_ACEOF
98418dba
CW
6464
6465else
c0d27fcc 6466 cat >>confdefs.h <<\_ACEOF
98418dba 6467#define POINTER_TYPE char
c0d27fcc 6468_ACEOF
98418dba
CW
6469
6470fi
6471
c0d27fcc 6472
cd958eb3
MB
6473
6474echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
6475echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6
98418dba
CW
6476set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
6477if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
6478 echo $ECHO_N "(cached) $ECHO_C" >&6
6479else
c0d27fcc 6480 cat >conftest.make <<\_ACEOF
98418dba 6481all:
cd958eb3 6482 @echo 'ac_maketemp="$(MAKE)"'
c0d27fcc 6483_ACEOF
98418dba
CW
6484# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6485eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
6486if test -n "$ac_maketemp"; then
6487 eval ac_cv_prog_make_${ac_make}_set=yes
6488else
6489 eval ac_cv_prog_make_${ac_make}_set=no
6490fi
6491rm -f conftest.make
6492fi
6493if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
c0d27fcc 6494 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
6495echo "${ECHO_T}yes" >&6
6496 SET_MAKE=
6497else
c0d27fcc 6498 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
6499echo "${ECHO_T}no" >&6
6500 SET_MAKE="MAKE=${MAKE-make}"
6501fi
6502
c0d27fcc
MR
6503
6504echo "$as_me:$LINENO: checking for long file names" >&5
98418dba
CW
6505echo $ECHO_N "checking for long file names... $ECHO_C" >&6
6506if test "${ac_cv_sys_long_file_names+set}" = set; then
6507 echo $ECHO_N "(cached) $ECHO_C" >&6
6508else
6509 ac_cv_sys_long_file_names=yes
6510# Test for long file names in all the places we know might matter:
6511# . the current directory, where building will happen
6512# $prefix/lib where we will be installing things
6513# $exec_prefix/lib likewise
6514# eval it to expand exec_prefix.
6515# $TMPDIR if set, where it might want to write temporary files
6516# if $TMPDIR is not set:
6517# /tmp where it might want to write temporary files
6518# /var/tmp likewise
6519# /usr/tmp likewise
6520if test -n "$TMPDIR" && test -d "$TMPDIR" && test -w "$TMPDIR"; then
6521 ac_tmpdirs=$TMPDIR
6522else
6523 ac_tmpdirs='/tmp /var/tmp /usr/tmp'
6524fi
6525for ac_dir in . $ac_tmpdirs `eval echo $prefix/lib $exec_prefix/lib` ; do
6526 test -d $ac_dir || continue
6527 test -w $ac_dir || continue # It is less confusing to not echo anything here.
6528 ac_xdir=$ac_dir/cf$$
6529 (umask 077 && mkdir $ac_xdir 2>/dev/null) || continue
6530 ac_tf1=$ac_xdir/conftest9012345
6531 ac_tf2=$ac_xdir/conftest9012346
6532 (echo 1 >$ac_tf1) 2>/dev/null
6533 (echo 2 >$ac_tf2) 2>/dev/null
6534 ac_val=`cat $ac_tf1 2>/dev/null`
6535 if test ! -f $ac_tf1 || test "$ac_val" != 1; then
6536 ac_cv_sys_long_file_names=no
6537 rm -rf $ac_xdir 2>/dev/null
6538 break
6539 fi
6540 rm -rf $ac_xdir 2>/dev/null
6541done
6542fi
c0d27fcc 6543echo "$as_me:$LINENO: result: $ac_cv_sys_long_file_names" >&5
98418dba
CW
6544echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
6545if test $ac_cv_sys_long_file_names = yes; then
6546
c0d27fcc 6547cat >>confdefs.h <<\_ACEOF
98418dba 6548#define HAVE_LONG_FILE_NAMES 1
c0d27fcc 6549_ACEOF
98418dba
CW
6550
6551fi
6552
c0d27fcc 6553
98418dba
CW
6554#### Choose a window system.
6555
c0d27fcc 6556echo "$as_me:$LINENO: checking for X" >&5
98418dba
CW
6557echo $ECHO_N "checking for X... $ECHO_C" >&6
6558
c0d27fcc 6559
98418dba
CW
6560# Check whether --with-x or --without-x was given.
6561if test "${with_x+set}" = set; then
6562 withval="$with_x"
6563
6564fi;
6565# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
6566if test "x$with_x" = xno; then
6567 # The user explicitly disabled X.
6568 have_x=disabled
6569else
6570 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
6571 # Both variables are already set.
6572 have_x=yes
6573 else
6574 if test "${ac_cv_have_x+set}" = set; then
6575 echo $ECHO_N "(cached) $ECHO_C" >&6
6576else
6577 # One or both of the vars are not set, and there is no cached value.
6578ac_x_includes=no ac_x_libraries=no
6579rm -fr conftest.dir
6580if mkdir conftest.dir; then
6581 cd conftest.dir
6582 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
c0d27fcc 6583 cat >Imakefile <<'_ACEOF'
98418dba
CW
6584acfindx:
6585 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
c0d27fcc 6586_ACEOF
98418dba
CW
6587 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
6588 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
6589 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
6590 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
6591 for ac_extension in a so sl; do
6592 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
6593 test -f $ac_im_libdir/libX11.$ac_extension; then
6594 ac_im_usrlibdir=$ac_im_libdir; break
6595 fi
6596 done
6597 # Screen out bogus values from the imake configuration. They are
6598 # bogus both because they are the default anyway, and because
6599 # using them would break gcc on systems where it needs fixed includes.
6600 case $ac_im_incroot in
6601 /usr/include) ;;
6602 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
6603 esac
6604 case $ac_im_usrlibdir in
6605 /usr/lib | /lib) ;;
6606 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
6607 esac
6608 fi
6609 cd ..
6610 rm -fr conftest.dir
6611fi
6612
6613# Standard set of common directories for X headers.
6614# Check X11 before X11Rn because it is often a symlink to the current release.
6615ac_x_header_dirs='
6616/usr/X11/include
6617/usr/X11R6/include
6618/usr/X11R5/include
6619/usr/X11R4/include
6620
6621/usr/include/X11
6622/usr/include/X11R6
6623/usr/include/X11R5
6624/usr/include/X11R4
6625
6626/usr/local/X11/include
6627/usr/local/X11R6/include
6628/usr/local/X11R5/include
6629/usr/local/X11R4/include
6630
6631/usr/local/include/X11
6632/usr/local/include/X11R6
6633/usr/local/include/X11R5
6634/usr/local/include/X11R4
6635
6636/usr/X386/include
6637/usr/x386/include
6638/usr/XFree86/include/X11
6639
6640/usr/include
6641/usr/local/include
6642/usr/unsupported/include
6643/usr/athena/include
6644/usr/local/x11r5/include
6645/usr/lpp/Xamples/include
6646
6647/usr/openwin/include
6648/usr/openwin/share/include'
6649
6650if test "$ac_x_includes" = no; then
6651 # Guess where to find include files, by looking for Intrinsic.h.
6652 # First, try using that file with no special directory specified.
6653 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6654#line $LINENO "configure"
cd958eb3
MB
6655/* confdefs.h. */
6656_ACEOF
6657cat confdefs.h >>conftest.$ac_ext
6658cat >>conftest.$ac_ext <<_ACEOF
6659/* end confdefs.h. */
98418dba
CW
6660#include <X11/Intrinsic.h>
6661_ACEOF
c0d27fcc 6662if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
6663 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6664 ac_status=$?
6bae0ccf 6665 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
6666 rm -f conftest.er1
6667 cat conftest.err >&5
c0d27fcc 6668 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6669 (exit $ac_status); } >/dev/null; then
6670 if test -s conftest.err; then
6671 ac_cpp_err=$ac_c_preproc_warn_flag
6672 else
6673 ac_cpp_err=
6674 fi
6675else
6676 ac_cpp_err=yes
6677fi
6678if test -z "$ac_cpp_err"; then
6679 # We can compile using X headers with no special include directory.
6680ac_x_includes=
6681else
6682 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6683sed 's/^/| /' conftest.$ac_ext >&5
6684
98418dba
CW
6685 for ac_dir in $ac_x_header_dirs; do
6686 if test -r "$ac_dir/X11/Intrinsic.h"; then
6687 ac_x_includes=$ac_dir
6688 break
6689 fi
6690done
6691fi
6692rm -f conftest.err conftest.$ac_ext
6693fi # $ac_x_includes = no
6694
6695if test "$ac_x_libraries" = no; then
6696 # Check for the libraries.
6697 # See if we find them without any special options.
6698 # Don't add to $LIBS permanently.
6699 ac_save_LIBS=$LIBS
6700 LIBS="-lXt $LIBS"
6701 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6702#line $LINENO "configure"
cd958eb3
MB
6703/* confdefs.h. */
6704_ACEOF
6705cat confdefs.h >>conftest.$ac_ext
6706cat >>conftest.$ac_ext <<_ACEOF
6707/* end confdefs.h. */
98418dba 6708#include <X11/Intrinsic.h>
98418dba
CW
6709int
6710main ()
6711{
6712XtMalloc (0)
6713 ;
6714 return 0;
6715}
6716_ACEOF
6717rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6718if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6719 (eval $ac_link) 2>&5
6720 ac_status=$?
c0d27fcc 6721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6722 (exit $ac_status); } &&
6723 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6724 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6725 (eval $ac_try) 2>&5
6726 ac_status=$?
c0d27fcc 6727 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6728 (exit $ac_status); }; }; then
6729 LIBS=$ac_save_LIBS
6730# We can link X programs with no special library path.
6731ac_x_libraries=
6732else
6733 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6734sed 's/^/| /' conftest.$ac_ext >&5
6735
98418dba
CW
6736LIBS=$ac_save_LIBS
6737for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
6738do
6739 # Don't even attempt the hair of trying to link an X program!
6740 for ac_extension in a so sl; do
6741 if test -r $ac_dir/libXt.$ac_extension; then
6742 ac_x_libraries=$ac_dir
6743 break 2
6744 fi
6745 done
6746done
6747fi
6748rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6749fi # $ac_x_libraries = no
6750
6751if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
6752 # Didn't find X anywhere. Cache the known absence of X.
6753 ac_cv_have_x="have_x=no"
6754else
6755 # Record where we found X for the cache.
6756 ac_cv_have_x="have_x=yes \
6757 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
6758fi
6759fi
6760
6761 fi
6762 eval "$ac_cv_have_x"
6763fi # $with_x != no
6764
6765if test "$have_x" != yes; then
c0d27fcc 6766 echo "$as_me:$LINENO: result: $have_x" >&5
98418dba
CW
6767echo "${ECHO_T}$have_x" >&6
6768 no_x=yes
6769else
6770 # If each of the values was on the command line, it overrides each guess.
6771 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
6772 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
6773 # Update the cache value to reflect the command line values.
6774 ac_cv_have_x="have_x=yes \
6775 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
c0d27fcc 6776 echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5
98418dba
CW
6777echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
6778fi
6779
6780if test "$no_x" = yes; then
6781 window_system=none
6782else
6783 window_system=x11
6784fi
6785
6786if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
6787 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
6788 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
6789 x_default_search_path=""
6790 for x_library in `echo ${x_libraries} | sed -e "s/:/ /g"`; do
6791 x_search_path="\
6792${x_library}/X11/%L/%T/%N%C%S:\
6793${x_library}/X11/%l/%T/%N%C%S:\
6794${x_library}/X11/%T/%N%C%S:\
6795${x_library}/X11/%L/%T/%N%S:\
6796${x_library}/X11/%l/%T/%N%S:\
6797${x_library}/X11/%T/%N%S"
6798 if test x"${x_default_search_path}" = x; then
6799 x_default_search_path=${x_search_path}
6800 else
6801 x_default_search_path="${x_search_path}:${x_default_search_path}"
6802 fi
6803 done
6804fi
6805if test "${x_includes}" != NONE && test -n "${x_includes}"; then
6806 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
6807fi
6808
6809if test x"${x_includes}" = x; then
6810 bitmapdir=/usr/include/X11/bitmaps
6811else
6812 # accumulate include directories that have X11 bitmap subdirectories
6813 bmd_acc="dummyval"
6814 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
6815 if test -d "${bmd}/X11/bitmaps"; then
6816 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
6817 fi
6818 if test -d "${bmd}/bitmaps"; then
6819 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
6820 fi
6821 done
6822 if test ${bmd_acc} != "dummyval"; then
6823 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
6824 fi
6825fi
6826
6827case "${window_system}" in
6828 x11 )
6829 HAVE_X_WINDOWS=yes
6830 HAVE_X11=yes
6831 case "${with_x_toolkit}" in
6832 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
6833 motif ) USE_X_TOOLKIT=MOTIF ;;
488dd4c4
JD
6834 gtk ) with_gtk=yes
6835 USE_X_TOOLKIT=none ;;
98418dba
CW
6836 no ) USE_X_TOOLKIT=none ;;
6837 * ) USE_X_TOOLKIT=maybe ;;
6838 esac
6839 ;;
6840 none )
6841 HAVE_X_WINDOWS=no
6842 HAVE_X11=no
6843 USE_X_TOOLKIT=none
6844 ;;
6845esac
6846
6847### If we're using X11, we should use the X menu package.
6848HAVE_MENUS=no
6849case ${HAVE_X11} in
6850 yes ) HAVE_MENUS=yes ;;
6851esac
6852
6853if test "${opsys}" = "hpux9"; then
6854 case "${x_libraries}" in
6855 *X11R4* )
6856 opsysfile="s/hpux9-x11r4.h"
6857 ;;
6858 esac
6859fi
6860
6861if test "${opsys}" = "hpux9shr"; then
6862 case "${x_libraries}" in
6863 *X11R4* )
6864 opsysfile="s/hpux9shxr4.h"
6865 ;;
6866 esac
6867fi
6868
6869### Compute the unexec source name from the object name.
6870UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`"
6871
6872# Do the opsystem or machine files prohibit the use of the GNU malloc?
6873# Assume not, until told otherwise.
6874GNU_MALLOC=yes
6875doug_lea_malloc=yes
c0d27fcc 6876echo "$as_me:$LINENO: checking for malloc_get_state" >&5
98418dba
CW
6877echo $ECHO_N "checking for malloc_get_state... $ECHO_C" >&6
6878if test "${ac_cv_func_malloc_get_state+set}" = set; then
6879 echo $ECHO_N "(cached) $ECHO_C" >&6
6880else
6881 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6882#line $LINENO "configure"
cd958eb3
MB
6883/* confdefs.h. */
6884_ACEOF
6885cat confdefs.h >>conftest.$ac_ext
6886cat >>conftest.$ac_ext <<_ACEOF
6887/* end confdefs.h. */
98418dba 6888/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
6889 which can conflict with char malloc_get_state (); below.
6890 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6891 <limits.h> exists even on freestanding compilers. */
6892#ifdef __STDC__
6893# include <limits.h>
6894#else
6895# include <assert.h>
6896#endif
98418dba
CW
6897/* Override any gcc2 internal prototype to avoid an error. */
6898#ifdef __cplusplus
6899extern "C"
cd958eb3 6900{
98418dba
CW
6901#endif
6902/* We use char because int might match the return type of a gcc2
6903 builtin and then its argument prototype would still apply. */
6904char malloc_get_state ();
98418dba
CW
6905/* The GNU C library defines this for functions which it implements
6906 to always fail with ENOSYS. Some functions are actually named
6907 something starting with __ and the normal name is an alias. */
6908#if defined (__stub_malloc_get_state) || defined (__stub___malloc_get_state)
6909choke me
6910#else
cd958eb3
MB
6911char (*f) () = malloc_get_state;
6912#endif
6913#ifdef __cplusplus
6914}
98418dba
CW
6915#endif
6916
cd958eb3
MB
6917int
6918main ()
6919{
9e71690e 6920return f != malloc_get_state;
98418dba
CW
6921 ;
6922 return 0;
6923}
6924_ACEOF
6925rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 6926if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
6927 (eval $ac_link) 2>&5
6928 ac_status=$?
c0d27fcc 6929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6930 (exit $ac_status); } &&
6931 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 6932 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
6933 (eval $ac_try) 2>&5
6934 ac_status=$?
c0d27fcc 6935 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
6936 (exit $ac_status); }; }; then
6937 ac_cv_func_malloc_get_state=yes
6938else
6939 echo "$as_me: failed program was:" >&5
cd958eb3
MB
6940sed 's/^/| /' conftest.$ac_ext >&5
6941
98418dba
CW
6942ac_cv_func_malloc_get_state=no
6943fi
6944rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6945fi
c0d27fcc 6946echo "$as_me:$LINENO: result: $ac_cv_func_malloc_get_state" >&5
98418dba
CW
6947echo "${ECHO_T}$ac_cv_func_malloc_get_state" >&6
6948if test $ac_cv_func_malloc_get_state = yes; then
6949 :
6950else
6951 doug_lea_malloc=no
6952fi
6953
c0d27fcc 6954echo "$as_me:$LINENO: checking for malloc_set_state" >&5
98418dba
CW
6955echo $ECHO_N "checking for malloc_set_state... $ECHO_C" >&6
6956if test "${ac_cv_func_malloc_set_state+set}" = set; then
6957 echo $ECHO_N "(cached) $ECHO_C" >&6
6958else
6959 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 6960#line $LINENO "configure"
cd958eb3
MB
6961/* confdefs.h. */
6962_ACEOF
6963cat confdefs.h >>conftest.$ac_ext
6964cat >>conftest.$ac_ext <<_ACEOF
6965/* end confdefs.h. */
98418dba 6966/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
6967 which can conflict with char malloc_set_state (); below.
6968 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6969 <limits.h> exists even on freestanding compilers. */
6970#ifdef __STDC__
6971# include <limits.h>
6972#else
6973# include <assert.h>
6974#endif
98418dba
CW
6975/* Override any gcc2 internal prototype to avoid an error. */
6976#ifdef __cplusplus
6977extern "C"
cd958eb3 6978{
98418dba
CW
6979#endif
6980/* We use char because int might match the return type of a gcc2
6981 builtin and then its argument prototype would still apply. */
6982char malloc_set_state ();
98418dba
CW
6983/* The GNU C library defines this for functions which it implements
6984 to always fail with ENOSYS. Some functions are actually named
6985 something starting with __ and the normal name is an alias. */
6986#if defined (__stub_malloc_set_state) || defined (__stub___malloc_set_state)
6987choke me
6988#else
cd958eb3
MB
6989char (*f) () = malloc_set_state;
6990#endif
6991#ifdef __cplusplus
6992}
98418dba
CW
6993#endif
6994
cd958eb3
MB
6995int
6996main ()
6997{
9e71690e 6998return f != malloc_set_state;
98418dba
CW
6999 ;
7000 return 0;
7001}
7002_ACEOF
7003rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7004if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7005 (eval $ac_link) 2>&5
7006 ac_status=$?
c0d27fcc 7007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7008 (exit $ac_status); } &&
7009 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7011 (eval $ac_try) 2>&5
7012 ac_status=$?
c0d27fcc 7013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7014 (exit $ac_status); }; }; then
7015 ac_cv_func_malloc_set_state=yes
7016else
7017 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7018sed 's/^/| /' conftest.$ac_ext >&5
7019
98418dba
CW
7020ac_cv_func_malloc_set_state=no
7021fi
7022rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7023fi
c0d27fcc 7024echo "$as_me:$LINENO: result: $ac_cv_func_malloc_set_state" >&5
98418dba
CW
7025echo "${ECHO_T}$ac_cv_func_malloc_set_state" >&6
7026if test $ac_cv_func_malloc_set_state = yes; then
7027 :
7028else
7029 doug_lea_malloc=no
7030fi
7031
c0d27fcc 7032echo "$as_me:$LINENO: checking whether __after_morecore_hook exists" >&5
98418dba
CW
7033echo $ECHO_N "checking whether __after_morecore_hook exists... $ECHO_C" >&6
7034if test "${emacs_cv_var___after_morecore_hook+set}" = set; then
7035 echo $ECHO_N "(cached) $ECHO_C" >&6
7036else
7037 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7038#line $LINENO "configure"
cd958eb3
MB
7039/* confdefs.h. */
7040_ACEOF
7041cat confdefs.h >>conftest.$ac_ext
7042cat >>conftest.$ac_ext <<_ACEOF
7043/* end confdefs.h. */
98418dba 7044extern void (* __after_morecore_hook)();
98418dba
CW
7045int
7046main ()
7047{
7048__after_morecore_hook = 0
7049 ;
7050 return 0;
7051}
7052_ACEOF
7053rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7054if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7055 (eval $ac_link) 2>&5
7056 ac_status=$?
c0d27fcc 7057 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7058 (exit $ac_status); } &&
7059 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7060 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7061 (eval $ac_try) 2>&5
7062 ac_status=$?
c0d27fcc 7063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7064 (exit $ac_status); }; }; then
7065 emacs_cv_var___after_morecore_hook=yes
7066else
7067 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7068sed 's/^/| /' conftest.$ac_ext >&5
7069
98418dba
CW
7070emacs_cv_var___after_morecore_hook=no
7071fi
7072rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7073fi
c0d27fcc 7074echo "$as_me:$LINENO: result: $emacs_cv_var___after_morecore_hook" >&5
98418dba
CW
7075echo "${ECHO_T}$emacs_cv_var___after_morecore_hook" >&6
7076if test $emacs_cv_var___after_morecore_hook = no; then
7077 doug_lea_malloc=no
7078fi
7079if test "${system_malloc}" = "yes"; then
7080 GNU_MALLOC=no
7081 GNU_MALLOC_reason="
7082 (The GNU allocators don't work with this system configuration.)"
7083fi
7084if test "$doug_lea_malloc" = "yes" ; then
7085 if test "$GNU_MALLOC" = yes ; then
7086 GNU_MALLOC_reason="
7087 (Using Doug Lea's new malloc from the GNU C Library.)"
7088 fi
b936fae4 7089
c0d27fcc 7090cat >>confdefs.h <<\_ACEOF
98418dba 7091#define DOUG_LEA_MALLOC 1
c0d27fcc 7092_ACEOF
98418dba
CW
7093
7094fi
7095
7096if test x"${REL_ALLOC}" = x; then
7097 REL_ALLOC=${GNU_MALLOC}
7098fi
7099
7100
c0d27fcc
MR
7101
7102
7103for ac_header in stdlib.h unistd.h
98418dba
CW
7104do
7105as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
7106if eval "test \"\${$as_ac_Header+set}\" = set"; then
7107 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
7108echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7109if eval "test \"\${$as_ac_Header+set}\" = set"; then
7110 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
7111fi
7112echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7113echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 7114else
c0d27fcc
MR
7115 # Is the header compilable?
7116echo "$as_me:$LINENO: checking $ac_header usability" >&5
7117echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7118cat >conftest.$ac_ext <<_ACEOF
7119#line $LINENO "configure"
cd958eb3
MB
7120/* confdefs.h. */
7121_ACEOF
7122cat confdefs.h >>conftest.$ac_ext
7123cat >>conftest.$ac_ext <<_ACEOF
7124/* end confdefs.h. */
98418dba
CW
7125$ac_includes_default
7126#include <$ac_header>
7127_ACEOF
7128rm -f conftest.$ac_objext
c0d27fcc 7129if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
7130 (eval $ac_compile) 2>&5
7131 ac_status=$?
c0d27fcc 7132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7133 (exit $ac_status); } &&
7134 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 7135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7136 (eval $ac_try) 2>&5
7137 ac_status=$?
c0d27fcc 7138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7139 (exit $ac_status); }; }; then
c0d27fcc 7140 ac_header_compiler=yes
98418dba
CW
7141else
7142 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7143sed 's/^/| /' conftest.$ac_ext >&5
7144
c0d27fcc 7145ac_header_compiler=no
98418dba
CW
7146fi
7147rm -f conftest.$ac_objext conftest.$ac_ext
c0d27fcc
MR
7148echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7149echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 7150
c0d27fcc
MR
7151# Is the header present?
7152echo "$as_me:$LINENO: checking $ac_header presence" >&5
7153echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7154cat >conftest.$ac_ext <<_ACEOF
7155#line $LINENO "configure"
cd958eb3
MB
7156/* confdefs.h. */
7157_ACEOF
7158cat confdefs.h >>conftest.$ac_ext
7159cat >>conftest.$ac_ext <<_ACEOF
7160/* end confdefs.h. */
98418dba
CW
7161#include <$ac_header>
7162_ACEOF
c0d27fcc 7163if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
7164 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7165 ac_status=$?
6bae0ccf 7166 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
7167 rm -f conftest.er1
7168 cat conftest.err >&5
c0d27fcc 7169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7170 (exit $ac_status); } >/dev/null; then
7171 if test -s conftest.err; then
7172 ac_cpp_err=$ac_c_preproc_warn_flag
7173 else
7174 ac_cpp_err=
7175 fi
7176else
7177 ac_cpp_err=yes
7178fi
7179if test -z "$ac_cpp_err"; then
c0d27fcc 7180 ac_header_preproc=yes
98418dba
CW
7181else
7182 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7183sed 's/^/| /' conftest.$ac_ext >&5
7184
c0d27fcc 7185 ac_header_preproc=no
98418dba
CW
7186fi
7187rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
7188echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7189echo "${ECHO_T}$ac_header_preproc" >&6
7190
7191# So? What about this header?
7192case $ac_header_compiler:$ac_header_preproc in
7193 yes:no )
7194 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7195echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7196 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
7197echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7198 (
7199 cat <<\_ASBOX
7200## ------------------------------------ ##
7201## Report this to bug-autoconf@gnu.org. ##
7202## ------------------------------------ ##
7203_ASBOX
7204 ) |
7205 sed "s/^/$as_me: WARNING: /" >&2
7206 ;;
c0d27fcc
MR
7207 no:yes )
7208 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7209echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7210 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7211echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7212 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
7213echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7214 (
7215 cat <<\_ASBOX
7216## ------------------------------------ ##
7217## Report this to bug-autoconf@gnu.org. ##
7218## ------------------------------------ ##
7219_ASBOX
7220 ) |
7221 sed "s/^/$as_me: WARNING: /" >&2
7222 ;;
c0d27fcc
MR
7223esac
7224echo "$as_me:$LINENO: checking for $ac_header" >&5
7225echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7226if eval "test \"\${$as_ac_Header+set}\" = set"; then
7227 echo $ECHO_N "(cached) $ECHO_C" >&6
7228else
7229 eval "$as_ac_Header=$ac_header_preproc"
98418dba 7230fi
c0d27fcc 7231echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 7232echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
7233
7234fi
98418dba 7235if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 7236 cat >>confdefs.h <<_ACEOF
98418dba 7237#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 7238_ACEOF
98418dba
CW
7239
7240fi
c0d27fcc 7241
98418dba
CW
7242done
7243
c0d27fcc 7244
98418dba
CW
7245for ac_func in getpagesize
7246do
7247as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 7248echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
7249echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7250if eval "test \"\${$as_ac_var+set}\" = set"; then
7251 echo $ECHO_N "(cached) $ECHO_C" >&6
7252else
7253 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7254#line $LINENO "configure"
cd958eb3
MB
7255/* confdefs.h. */
7256_ACEOF
7257cat confdefs.h >>conftest.$ac_ext
7258cat >>conftest.$ac_ext <<_ACEOF
7259/* end confdefs.h. */
98418dba 7260/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
7261 which can conflict with char $ac_func (); below.
7262 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7263 <limits.h> exists even on freestanding compilers. */
7264#ifdef __STDC__
7265# include <limits.h>
7266#else
7267# include <assert.h>
7268#endif
98418dba
CW
7269/* Override any gcc2 internal prototype to avoid an error. */
7270#ifdef __cplusplus
7271extern "C"
cd958eb3 7272{
98418dba
CW
7273#endif
7274/* We use char because int might match the return type of a gcc2
7275 builtin and then its argument prototype would still apply. */
7276char $ac_func ();
98418dba
CW
7277/* The GNU C library defines this for functions which it implements
7278 to always fail with ENOSYS. Some functions are actually named
7279 something starting with __ and the normal name is an alias. */
7280#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7281choke me
7282#else
cd958eb3
MB
7283char (*f) () = $ac_func;
7284#endif
7285#ifdef __cplusplus
7286}
98418dba
CW
7287#endif
7288
cd958eb3
MB
7289int
7290main ()
7291{
9e71690e 7292return f != $ac_func;
98418dba
CW
7293 ;
7294 return 0;
7295}
7296_ACEOF
7297rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7298if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7299 (eval $ac_link) 2>&5
7300 ac_status=$?
c0d27fcc 7301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7302 (exit $ac_status); } &&
7303 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7305 (eval $ac_try) 2>&5
7306 ac_status=$?
c0d27fcc 7307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7308 (exit $ac_status); }; }; then
7309 eval "$as_ac_var=yes"
7310else
7311 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7312sed 's/^/| /' conftest.$ac_ext >&5
7313
98418dba
CW
7314eval "$as_ac_var=no"
7315fi
7316rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7317fi
c0d27fcc 7318echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
7319echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7320if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 7321 cat >>confdefs.h <<_ACEOF
98418dba 7322#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 7323_ACEOF
98418dba
CW
7324
7325fi
7326done
7327
c0d27fcc 7328echo "$as_me:$LINENO: checking for working mmap" >&5
98418dba
CW
7329echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
7330if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
7331 echo $ECHO_N "(cached) $ECHO_C" >&6
7332else
7333 if test "$cross_compiling" = yes; then
7334 ac_cv_func_mmap_fixed_mapped=no
7335else
7336 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7337#line $LINENO "configure"
cd958eb3
MB
7338/* confdefs.h. */
7339_ACEOF
7340cat confdefs.h >>conftest.$ac_ext
7341cat >>conftest.$ac_ext <<_ACEOF
7342/* end confdefs.h. */
98418dba 7343$ac_includes_default
c0d27fcc
MR
7344/* malloc might have been renamed as rpl_malloc. */
7345#undef malloc
7346
98418dba
CW
7347/* Thanks to Mike Haertel and Jim Avera for this test.
7348 Here is a matrix of mmap possibilities:
7349 mmap private not fixed
7350 mmap private fixed at somewhere currently unmapped
7351 mmap private fixed at somewhere already mapped
7352 mmap shared not fixed
7353 mmap shared fixed at somewhere currently unmapped
7354 mmap shared fixed at somewhere already mapped
7355 For private mappings, we should verify that changes cannot be read()
7356 back from the file, nor mmap's back from the file at a different
7357 address. (There have been systems where private was not correctly
7358 implemented like the infamous i386 svr4.0, and systems where the
7359 VM page cache was not coherent with the file system buffer cache
7360 like early versions of FreeBSD and possibly contemporary NetBSD.)
7361 For shared mappings, we should conversely verify that changes get
c0d27fcc 7362 propagated back to all the places they're supposed to be.
98418dba
CW
7363
7364 Grep wants private fixed already mapped.
7365 The main things grep needs to know about mmap are:
7366 * does it exist and is it safe to write into the mmap'd area
7367 * how to use it (BSD variants) */
7368
7369#include <fcntl.h>
7370#include <sys/mman.h>
7371
7372#if !STDC_HEADERS && !HAVE_STDLIB_H
7373char *malloc ();
7374#endif
7375
7376/* This mess was copied from the GNU getpagesize.h. */
7377#if !HAVE_GETPAGESIZE
7378/* Assume that all systems that can run configure have sys/param.h. */
7379# if !HAVE_SYS_PARAM_H
7380# define HAVE_SYS_PARAM_H 1
7381# endif
7382
7383# ifdef _SC_PAGESIZE
7384# define getpagesize() sysconf(_SC_PAGESIZE)
7385# else /* no _SC_PAGESIZE */
7386# if HAVE_SYS_PARAM_H
7387# include <sys/param.h>
7388# ifdef EXEC_PAGESIZE
7389# define getpagesize() EXEC_PAGESIZE
7390# else /* no EXEC_PAGESIZE */
7391# ifdef NBPG
7392# define getpagesize() NBPG * CLSIZE
7393# ifndef CLSIZE
7394# define CLSIZE 1
7395# endif /* no CLSIZE */
7396# else /* no NBPG */
7397# ifdef NBPC
7398# define getpagesize() NBPC
7399# else /* no NBPC */
7400# ifdef PAGESIZE
7401# define getpagesize() PAGESIZE
7402# endif /* PAGESIZE */
7403# endif /* no NBPC */
7404# endif /* no NBPG */
7405# endif /* no EXEC_PAGESIZE */
7406# else /* no HAVE_SYS_PARAM_H */
7407# define getpagesize() 8192 /* punt totally */
7408# endif /* no HAVE_SYS_PARAM_H */
7409# endif /* no _SC_PAGESIZE */
7410
7411#endif /* no HAVE_GETPAGESIZE */
7412
7413int
7414main ()
7415{
7416 char *data, *data2, *data3;
7417 int i, pagesize;
7418 int fd;
7419
7420 pagesize = getpagesize ();
7421
7422 /* First, make a file with some known garbage in it. */
7423 data = (char *) malloc (pagesize);
7424 if (!data)
7425 exit (1);
7426 for (i = 0; i < pagesize; ++i)
7427 *(data + i) = rand ();
7428 umask (0);
7429 fd = creat ("conftest.mmap", 0600);
7430 if (fd < 0)
7431 exit (1);
7432 if (write (fd, data, pagesize) != pagesize)
7433 exit (1);
7434 close (fd);
7435
7436 /* Next, try to mmap the file at a fixed address which already has
7437 something else allocated at it. If we can, also make sure that
7438 we see the same garbage. */
7439 fd = open ("conftest.mmap", O_RDWR);
7440 if (fd < 0)
7441 exit (1);
7442 data2 = (char *) malloc (2 * pagesize);
7443 if (!data2)
7444 exit (1);
7445 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
7446 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
7447 MAP_PRIVATE | MAP_FIXED, fd, 0L))
7448 exit (1);
7449 for (i = 0; i < pagesize; ++i)
7450 if (*(data + i) != *(data2 + i))
7451 exit (1);
7452
7453 /* Finally, make sure that changes to the mapped area do not
7454 percolate back to the file as seen by read(). (This is a bug on
7455 some variants of i386 svr4.0.) */
7456 for (i = 0; i < pagesize; ++i)
7457 *(data2 + i) = *(data2 + i) + 1;
7458 data3 = (char *) malloc (pagesize);
7459 if (!data3)
7460 exit (1);
7461 if (read (fd, data3, pagesize) != pagesize)
7462 exit (1);
7463 for (i = 0; i < pagesize; ++i)
7464 if (*(data + i) != *(data3 + i))
7465 exit (1);
7466 close (fd);
7467 exit (0);
7468}
7469_ACEOF
7470rm -f conftest$ac_exeext
c0d27fcc 7471if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7472 (eval $ac_link) 2>&5
7473 ac_status=$?
c0d27fcc 7474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 7475 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 7476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7477 (eval $ac_try) 2>&5
7478 ac_status=$?
c0d27fcc 7479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7480 (exit $ac_status); }; }; then
7481 ac_cv_func_mmap_fixed_mapped=yes
7482else
7483 echo "$as_me: program exited with status $ac_status" >&5
7484echo "$as_me: failed program was:" >&5
cd958eb3
MB
7485sed 's/^/| /' conftest.$ac_ext >&5
7486
c0d27fcc 7487( exit $ac_status )
98418dba
CW
7488ac_cv_func_mmap_fixed_mapped=no
7489fi
6bae0ccf 7490rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
98418dba
CW
7491fi
7492fi
c0d27fcc 7493echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
98418dba
CW
7494echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
7495if test $ac_cv_func_mmap_fixed_mapped = yes; then
7496
c0d27fcc 7497cat >>confdefs.h <<\_ACEOF
98418dba 7498#define HAVE_MMAP 1
c0d27fcc 7499_ACEOF
98418dba
CW
7500
7501fi
7502rm -f conftest.mmap
7503
7504if test $use_mmap_for_buffers = yes; then
7505 REL_ALLOC=no
7506fi
7507
7508LIBS="$libsrc_libs $LIBS"
7509
c0d27fcc
MR
7510
7511echo "$as_me:$LINENO: checking for dnet_ntoa in -ldnet" >&5
98418dba
CW
7512echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
7513if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
7514 echo $ECHO_N "(cached) $ECHO_C" >&6
7515else
7516 ac_check_lib_save_LIBS=$LIBS
7517LIBS="-ldnet $LIBS"
7518cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7519#line $LINENO "configure"
cd958eb3
MB
7520/* confdefs.h. */
7521_ACEOF
7522cat confdefs.h >>conftest.$ac_ext
7523cat >>conftest.$ac_ext <<_ACEOF
7524/* end confdefs.h. */
98418dba
CW
7525
7526/* Override any gcc2 internal prototype to avoid an error. */
7527#ifdef __cplusplus
7528extern "C"
7529#endif
7530/* We use char because int might match the return type of a gcc2
7531 builtin and then its argument prototype would still apply. */
7532char dnet_ntoa ();
98418dba
CW
7533int
7534main ()
7535{
7536dnet_ntoa ();
7537 ;
7538 return 0;
7539}
7540_ACEOF
7541rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7542if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7543 (eval $ac_link) 2>&5
7544 ac_status=$?
c0d27fcc 7545 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7546 (exit $ac_status); } &&
7547 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7548 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7549 (eval $ac_try) 2>&5
7550 ac_status=$?
c0d27fcc 7551 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7552 (exit $ac_status); }; }; then
7553 ac_cv_lib_dnet_dnet_ntoa=yes
7554else
7555 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7556sed 's/^/| /' conftest.$ac_ext >&5
7557
98418dba
CW
7558ac_cv_lib_dnet_dnet_ntoa=no
7559fi
7560rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7561LIBS=$ac_check_lib_save_LIBS
7562fi
c0d27fcc 7563echo "$as_me:$LINENO: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
98418dba
CW
7564echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
7565if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
c0d27fcc 7566 cat >>confdefs.h <<_ACEOF
98418dba 7567#define HAVE_LIBDNET 1
c0d27fcc 7568_ACEOF
98418dba
CW
7569
7570 LIBS="-ldnet $LIBS"
7571
7572fi
7573
c0d27fcc
MR
7574
7575echo "$as_me:$LINENO: checking for main in -lXbsd" >&5
98418dba
CW
7576echo $ECHO_N "checking for main in -lXbsd... $ECHO_C" >&6
7577if test "${ac_cv_lib_Xbsd_main+set}" = set; then
7578 echo $ECHO_N "(cached) $ECHO_C" >&6
7579else
7580 ac_check_lib_save_LIBS=$LIBS
7581LIBS="-lXbsd $LIBS"
7582cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7583#line $LINENO "configure"
cd958eb3
MB
7584/* confdefs.h. */
7585_ACEOF
7586cat confdefs.h >>conftest.$ac_ext
7587cat >>conftest.$ac_ext <<_ACEOF
7588/* end confdefs.h. */
98418dba 7589
c0d27fcc 7590
98418dba
CW
7591int
7592main ()
7593{
7594main ();
7595 ;
7596 return 0;
7597}
7598_ACEOF
7599rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7600if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7601 (eval $ac_link) 2>&5
7602 ac_status=$?
c0d27fcc 7603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7604 (exit $ac_status); } &&
7605 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7606 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7607 (eval $ac_try) 2>&5
7608 ac_status=$?
c0d27fcc 7609 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7610 (exit $ac_status); }; }; then
7611 ac_cv_lib_Xbsd_main=yes
7612else
7613 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7614sed 's/^/| /' conftest.$ac_ext >&5
7615
98418dba
CW
7616ac_cv_lib_Xbsd_main=no
7617fi
7618rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7619LIBS=$ac_check_lib_save_LIBS
7620fi
c0d27fcc 7621echo "$as_me:$LINENO: result: $ac_cv_lib_Xbsd_main" >&5
98418dba
CW
7622echo "${ECHO_T}$ac_cv_lib_Xbsd_main" >&6
7623if test $ac_cv_lib_Xbsd_main = yes; then
7624 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
7625fi
7626
c0d27fcc
MR
7627
7628
7629echo "$as_me:$LINENO: checking for cma_open in -lpthreads" >&5
98418dba
CW
7630echo $ECHO_N "checking for cma_open in -lpthreads... $ECHO_C" >&6
7631if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then
7632 echo $ECHO_N "(cached) $ECHO_C" >&6
7633else
7634 ac_check_lib_save_LIBS=$LIBS
7635LIBS="-lpthreads $LIBS"
7636cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7637#line $LINENO "configure"
cd958eb3
MB
7638/* confdefs.h. */
7639_ACEOF
7640cat confdefs.h >>conftest.$ac_ext
7641cat >>conftest.$ac_ext <<_ACEOF
7642/* end confdefs.h. */
98418dba
CW
7643
7644/* Override any gcc2 internal prototype to avoid an error. */
7645#ifdef __cplusplus
7646extern "C"
7647#endif
7648/* We use char because int might match the return type of a gcc2
7649 builtin and then its argument prototype would still apply. */
7650char cma_open ();
98418dba
CW
7651int
7652main ()
7653{
7654cma_open ();
7655 ;
7656 return 0;
7657}
7658_ACEOF
7659rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7660if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7661 (eval $ac_link) 2>&5
7662 ac_status=$?
c0d27fcc 7663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7664 (exit $ac_status); } &&
7665 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7666 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7667 (eval $ac_try) 2>&5
7668 ac_status=$?
c0d27fcc 7669 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7670 (exit $ac_status); }; }; then
7671 ac_cv_lib_pthreads_cma_open=yes
7672else
7673 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7674sed 's/^/| /' conftest.$ac_ext >&5
7675
98418dba
CW
7676ac_cv_lib_pthreads_cma_open=no
7677fi
7678rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7679LIBS=$ac_check_lib_save_LIBS
7680fi
c0d27fcc 7681echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_cma_open" >&5
98418dba
CW
7682echo "${ECHO_T}$ac_cv_lib_pthreads_cma_open" >&6
7683if test $ac_cv_lib_pthreads_cma_open = yes; then
c0d27fcc 7684 cat >>confdefs.h <<_ACEOF
98418dba 7685#define HAVE_LIBPTHREADS 1
c0d27fcc 7686_ACEOF
98418dba
CW
7687
7688 LIBS="-lpthreads $LIBS"
7689
7690fi
7691
c0d27fcc
MR
7692
7693echo "$as_me:$LINENO: checking for XFree86 in /usr/X386" >&5
98418dba
CW
7694echo $ECHO_N "checking for XFree86 in /usr/X386... $ECHO_C" >&6
7695if test -d /usr/X386/include; then
7696 HAVE_XFREE386=yes
7697 : ${C_SWITCH_X_SITE="-I/usr/X386/include"}
7698else
7699 HAVE_XFREE386=no
7700fi
c0d27fcc 7701echo "$as_me:$LINENO: result: $HAVE_XFREE386" >&5
98418dba
CW
7702echo "${ECHO_T}$HAVE_XFREE386" >&6
7703
ae1a998c
RS
7704# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
7705# used for the tests that follow. We set them back to REAL_CFLAGS and
7706# REAL_CPPFLAGS later on.
98418dba
CW
7707
7708REAL_CPPFLAGS="$CPPFLAGS"
7709
7710if test "${HAVE_X11}" = "yes"; then
7711 DEFS="$C_SWITCH_X_SITE $DEFS"
7712 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
7713 LIBS="$LIBX $LIBS"
7714 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
7715 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
7716
7717 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
7718 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
7719 # but it's more convenient here to set LD_RUN_PATH
7720 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
7721 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
7722 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
7723 export LD_RUN_PATH
7724 fi
7725
7726 if test "${opsys}" = "gnu-linux"; then
c0d27fcc 7727 echo "$as_me:$LINENO: checking whether X on GNU/Linux needs -b to link" >&5
98418dba
CW
7728echo $ECHO_N "checking whether X on GNU/Linux needs -b to link... $ECHO_C" >&6
7729 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7730#line $LINENO "configure"
cd958eb3
MB
7731/* confdefs.h. */
7732_ACEOF
7733cat confdefs.h >>conftest.$ac_ext
7734cat >>conftest.$ac_ext <<_ACEOF
7735/* end confdefs.h. */
98418dba 7736
98418dba
CW
7737int
7738main ()
7739{
7740XOpenDisplay ("foo");
7741 ;
7742 return 0;
7743}
7744_ACEOF
7745rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7746if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7747 (eval $ac_link) 2>&5
7748 ac_status=$?
c0d27fcc 7749 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7750 (exit $ac_status); } &&
7751 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7752 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7753 (eval $ac_try) 2>&5
7754 ac_status=$?
c0d27fcc 7755 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7756 (exit $ac_status); }; }; then
7757 xlinux_first_failure=no
7758else
7759 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7760sed 's/^/| /' conftest.$ac_ext >&5
7761
98418dba
CW
7762xlinux_first_failure=yes
7763fi
7764rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7765 if test "${xlinux_first_failure}" = "yes"; then
7766 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
7767 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
7768 OLD_CPPFLAGS="$CPPFLAGS"
7769 OLD_LIBS="$LIBS"
7770 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
7771 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
7772 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
7773 LIBS="$LIBS -b i486-linuxaout"
7774 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7775#line $LINENO "configure"
cd958eb3
MB
7776/* confdefs.h. */
7777_ACEOF
7778cat confdefs.h >>conftest.$ac_ext
7779cat >>conftest.$ac_ext <<_ACEOF
7780/* end confdefs.h. */
98418dba 7781
98418dba
CW
7782int
7783main ()
7784{
7785XOpenDisplay ("foo");
7786 ;
7787 return 0;
7788}
7789_ACEOF
7790rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7791if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7792 (eval $ac_link) 2>&5
7793 ac_status=$?
c0d27fcc 7794 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7795 (exit $ac_status); } &&
7796 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7797 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7798 (eval $ac_try) 2>&5
7799 ac_status=$?
c0d27fcc 7800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7801 (exit $ac_status); }; }; then
7802 xlinux_second_failure=no
7803else
7804 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7805sed 's/^/| /' conftest.$ac_ext >&5
7806
98418dba
CW
7807xlinux_second_failure=yes
7808fi
7809rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7810 if test "${xlinux_second_failure}" = "yes"; then
7811 # If we get the same failure with -b, there is no use adding -b.
7812 # So take it out. This plays safe.
7813 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
7814 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
7815 CPPFLAGS="$OLD_CPPFLAGS"
7816 LIBS="$OLD_LIBS"
c0d27fcc 7817 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7818echo "${ECHO_T}no" >&6
7819 else
c0d27fcc 7820 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
7821echo "${ECHO_T}yes" >&6
7822 fi
7823 else
c0d27fcc 7824 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
7825echo "${ECHO_T}no" >&6
7826 fi
7827 fi
7828
7829 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
7830 # header files included from there.
c0d27fcc 7831 echo "$as_me:$LINENO: checking for Xkb" >&5
98418dba
CW
7832echo $ECHO_N "checking for Xkb... $ECHO_C" >&6
7833 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7834#line $LINENO "configure"
cd958eb3
MB
7835/* confdefs.h. */
7836_ACEOF
7837cat confdefs.h >>conftest.$ac_ext
7838cat >>conftest.$ac_ext <<_ACEOF
7839/* end confdefs.h. */
98418dba
CW
7840#include <X11/Xlib.h>
7841#include <X11/XKBlib.h>
98418dba
CW
7842int
7843main ()
7844{
7845XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
7846 ;
7847 return 0;
7848}
7849_ACEOF
7850rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7851if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7852 (eval $ac_link) 2>&5
7853 ac_status=$?
c0d27fcc 7854 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7855 (exit $ac_status); } &&
7856 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7857 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7858 (eval $ac_try) 2>&5
7859 ac_status=$?
c0d27fcc 7860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7861 (exit $ac_status); }; }; then
7862 emacs_xkb=yes
7863else
7864 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7865sed 's/^/| /' conftest.$ac_ext >&5
7866
98418dba
CW
7867emacs_xkb=no
7868fi
7869rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
c0d27fcc 7870 echo "$as_me:$LINENO: result: $emacs_xkb" >&5
98418dba
CW
7871echo "${ECHO_T}$emacs_xkb" >&6
7872 if test $emacs_xkb = yes; then
b936fae4 7873
c0d27fcc 7874cat >>confdefs.h <<\_ACEOF
98418dba 7875#define HAVE_XKBGETKEYBOARD 1
c0d27fcc 7876_ACEOF
98418dba
CW
7877
7878 fi
7879
c0d27fcc
MR
7880
7881
7882
7883
98418dba
CW
7884for ac_func in XrmSetDatabase XScreenResourceString \
7885XScreenNumberOfScreen XSetWMProtocols
7886do
7887as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 7888echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
7889echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7890if eval "test \"\${$as_ac_var+set}\" = set"; then
7891 echo $ECHO_N "(cached) $ECHO_C" >&6
7892else
7893 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7894#line $LINENO "configure"
cd958eb3
MB
7895/* confdefs.h. */
7896_ACEOF
7897cat confdefs.h >>conftest.$ac_ext
7898cat >>conftest.$ac_ext <<_ACEOF
7899/* end confdefs.h. */
98418dba 7900/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
7901 which can conflict with char $ac_func (); below.
7902 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7903 <limits.h> exists even on freestanding compilers. */
7904#ifdef __STDC__
7905# include <limits.h>
7906#else
7907# include <assert.h>
7908#endif
98418dba
CW
7909/* Override any gcc2 internal prototype to avoid an error. */
7910#ifdef __cplusplus
7911extern "C"
cd958eb3 7912{
98418dba
CW
7913#endif
7914/* We use char because int might match the return type of a gcc2
7915 builtin and then its argument prototype would still apply. */
7916char $ac_func ();
98418dba
CW
7917/* The GNU C library defines this for functions which it implements
7918 to always fail with ENOSYS. Some functions are actually named
7919 something starting with __ and the normal name is an alias. */
7920#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7921choke me
7922#else
cd958eb3
MB
7923char (*f) () = $ac_func;
7924#endif
7925#ifdef __cplusplus
7926}
98418dba
CW
7927#endif
7928
cd958eb3
MB
7929int
7930main ()
7931{
9e71690e 7932return f != $ac_func;
98418dba
CW
7933 ;
7934 return 0;
7935}
7936_ACEOF
7937rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7938if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7939 (eval $ac_link) 2>&5
7940 ac_status=$?
c0d27fcc 7941 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7942 (exit $ac_status); } &&
7943 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 7944 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
7945 (eval $ac_try) 2>&5
7946 ac_status=$?
c0d27fcc 7947 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
7948 (exit $ac_status); }; }; then
7949 eval "$as_ac_var=yes"
7950else
7951 echo "$as_me: failed program was:" >&5
cd958eb3
MB
7952sed 's/^/| /' conftest.$ac_ext >&5
7953
98418dba
CW
7954eval "$as_ac_var=no"
7955fi
7956rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7957fi
c0d27fcc 7958echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
7959echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7960if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 7961 cat >>confdefs.h <<_ACEOF
98418dba 7962#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 7963_ACEOF
98418dba
CW
7964
7965fi
7966done
7967
7968fi
7969
7970if test "${window_system}" = "x11"; then
c0d27fcc 7971 echo "$as_me:$LINENO: checking X11 version 6" >&5
98418dba
CW
7972echo $ECHO_N "checking X11 version 6... $ECHO_C" >&6
7973 if test "${emacs_cv_x11_version_6+set}" = set; then
7974 echo $ECHO_N "(cached) $ECHO_C" >&6
7975else
7976 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 7977#line $LINENO "configure"
cd958eb3
MB
7978/* confdefs.h. */
7979_ACEOF
7980cat confdefs.h >>conftest.$ac_ext
7981cat >>conftest.$ac_ext <<_ACEOF
7982/* end confdefs.h. */
98418dba 7983#include <X11/Xlib.h>
98418dba
CW
7984int
7985main ()
7986{
7987#if XlibSpecificationRelease < 6
7988fail;
7989#endif
7990
7991 ;
7992 return 0;
7993}
7994_ACEOF
7995rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 7996if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
7997 (eval $ac_link) 2>&5
7998 ac_status=$?
c0d27fcc 7999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8000 (exit $ac_status); } &&
8001 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8002 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8003 (eval $ac_try) 2>&5
8004 ac_status=$?
c0d27fcc 8005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8006 (exit $ac_status); }; }; then
8007 emacs_cv_x11_version_6=yes
8008else
8009 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8010sed 's/^/| /' conftest.$ac_ext >&5
8011
98418dba
CW
8012emacs_cv_x11_version_6=no
8013fi
8014rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8015fi
8016
8017 if test $emacs_cv_x11_version_6 = yes; then
c0d27fcc 8018 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 8019echo "${ECHO_T}6 or newer" >&6
b936fae4 8020
c0d27fcc 8021cat >>confdefs.h <<\_ACEOF
98418dba 8022#define HAVE_X11R6 1
c0d27fcc 8023_ACEOF
98418dba
CW
8024
8025 else
c0d27fcc 8026 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
8027echo "${ECHO_T}before 6" >&6
8028 fi
8029fi
8030
8031if test "${window_system}" = "x11"; then
c0d27fcc 8032 echo "$as_me:$LINENO: checking X11 version 5" >&5
98418dba
CW
8033echo $ECHO_N "checking X11 version 5... $ECHO_C" >&6
8034 if test "${emacs_cv_x11_version_5+set}" = set; then
8035 echo $ECHO_N "(cached) $ECHO_C" >&6
8036else
8037 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8038#line $LINENO "configure"
cd958eb3
MB
8039/* confdefs.h. */
8040_ACEOF
8041cat confdefs.h >>conftest.$ac_ext
8042cat >>conftest.$ac_ext <<_ACEOF
8043/* end confdefs.h. */
98418dba 8044#include <X11/Xlib.h>
98418dba
CW
8045int
8046main ()
8047{
8048#if XlibSpecificationRelease < 5
8049fail;
8050#endif
8051
8052 ;
8053 return 0;
8054}
8055_ACEOF
8056rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8057if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8058 (eval $ac_link) 2>&5
8059 ac_status=$?
c0d27fcc 8060 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8061 (exit $ac_status); } &&
8062 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8063 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8064 (eval $ac_try) 2>&5
8065 ac_status=$?
c0d27fcc 8066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8067 (exit $ac_status); }; }; then
8068 emacs_cv_x11_version_5=yes
8069else
8070 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8071sed 's/^/| /' conftest.$ac_ext >&5
8072
98418dba
CW
8073emacs_cv_x11_version_5=no
8074fi
8075rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8076fi
8077
8078 if test $emacs_cv_x11_version_5 = yes; then
c0d27fcc 8079 echo "$as_me:$LINENO: result: 5 or newer" >&5
98418dba
CW
8080echo "${ECHO_T}5 or newer" >&6
8081 HAVE_X11R5=yes
b936fae4 8082
c0d27fcc 8083cat >>confdefs.h <<\_ACEOF
98418dba 8084#define HAVE_X11R5 1
c0d27fcc 8085_ACEOF
98418dba
CW
8086
8087 else
8088 HAVE_X11R5=no
c0d27fcc 8089 echo "$as_me:$LINENO: result: before 5" >&5
98418dba
CW
8090echo "${ECHO_T}before 5" >&6
8091 fi
8092fi
8093
488dd4c4
JD
8094
8095
8096HAVE_GTK=no
8097if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk"; then
cd890796 8098 if test "$USE_X_TOOLKIT" != "none" && test "$USE_X_TOOLKIT" != "maybe"; then
488dd4c4
JD
8099 { { echo "$as_me:$LINENO: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&5
8100echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with-x-toolkit=${with_x_toolkit}" >&2;}
8101 { (exit 1); exit 1; }; };
8102 fi
8103 GLIB_REQUIRED=2.0.1
8104 GTK_REQUIRED=2.0.1
8105 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8106
8107 if test "X${with_pkg_config_prog}" != X; then
8108 PKG_CONFIG="${with_pkg_config_prog}"
8109 fi
8110
8111 succeeded=no
8112
8113 if test -z "$PKG_CONFIG"; then
8114 # Extract the first word of "pkg-config", so it can be a program name with args.
8115set dummy pkg-config; ac_word=$2
8116echo "$as_me:$LINENO: checking for $ac_word" >&5
8117echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8118if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
8119 echo $ECHO_N "(cached) $ECHO_C" >&6
8120else
8121 case $PKG_CONFIG in
8122 [\\/]* | ?:[\\/]*)
8123 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8124 ;;
8125 *)
8126 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8127for as_dir in $PATH
8128do
8129 IFS=$as_save_IFS
8130 test -z "$as_dir" && as_dir=.
8131 for ac_exec_ext in '' $ac_executable_extensions; do
8132 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8133 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8134 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8135 break 2
8136 fi
8137done
8138done
8139
8140 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8141 ;;
8142esac
8143fi
8144PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8145
8146if test -n "$PKG_CONFIG"; then
8147 echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
8148echo "${ECHO_T}$PKG_CONFIG" >&6
8149else
8150 echo "$as_me:$LINENO: result: no" >&5
8151echo "${ECHO_T}no" >&6
8152fi
8153
8154 fi
8155
8156 if test "$PKG_CONFIG" = "no" ; then
8157 echo "*** The pkg-config script could not be found. Make sure it is"
8158 echo "*** in your path, or give the full path to pkg-config with"
8159 echo "*** the PKG_CONFIG environment variable or --with-pkg-config-prog."
8160 echo "*** Or see http://www.freedesktop.org/software/pkgconfig to get pkg-config."
8161 else
8162 PKG_CONFIG_MIN_VERSION=0.9.0
8163 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8164 echo "$as_me:$LINENO: checking for $GTK_MODULES" >&5
8165echo $ECHO_N "checking for $GTK_MODULES... $ECHO_C" >&6
8166
8167 if $PKG_CONFIG --exists "$GTK_MODULES" ; then
8168 echo "$as_me:$LINENO: result: yes" >&5
8169echo "${ECHO_T}yes" >&6
8170 succeeded=yes
8171
8172 echo "$as_me:$LINENO: checking GTK_CFLAGS" >&5
8173echo $ECHO_N "checking GTK_CFLAGS... $ECHO_C" >&6
8174 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"`
8175 echo "$as_me:$LINENO: result: $GTK_CFLAGS" >&5
8176echo "${ECHO_T}$GTK_CFLAGS" >&6
8177
8178 echo "$as_me:$LINENO: checking GTK_LIBS" >&5
8179echo $ECHO_N "checking GTK_LIBS... $ECHO_C" >&6
8180 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"`
8181 echo "$as_me:$LINENO: result: $GTK_LIBS" >&5
8182echo "${ECHO_T}$GTK_LIBS" >&6
8183 else
8184 GTK_CFLAGS=""
8185 GTK_LIBS=""
8186 ## If we have a custom action on failure, don't print errors, but
8187 ## do set a variable so people can do so.
8188 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8189 echo $GTK_PKG_ERRORS
8190 fi
8191
8192
8193
8194 else
8195 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8196 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8197 fi
8198 fi
8199
8200 if test $succeeded = yes; then
8201 :
8202 else
8203 { { 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
8204echo "$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;}
8205 { (exit 1); exit 1; }; }
8206 fi
8207
8208
8209
8210 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
8211 HAVE_GTK=yes
8212
8213cat >>confdefs.h <<\_ACEOF
8214#define HAVE_GTK 1
8215_ACEOF
8216
8217 USE_X_TOOLKIT=none
8218
8219 with_toolkit_scroll_bars=yes
8220fi
8221
98418dba
CW
8222if test x"${USE_X_TOOLKIT}" = xmaybe; then
8223 if test x"${HAVE_X11R5}" = xyes; then
c0d27fcc 8224 echo "$as_me:$LINENO: checking X11 version 5 with Xaw" >&5
98418dba
CW
8225echo $ECHO_N "checking X11 version 5 with Xaw... $ECHO_C" >&6
8226 if test "${emacs_cv_x11_version_5_with_xaw+set}" = set; then
8227 echo $ECHO_N "(cached) $ECHO_C" >&6
8228else
8229 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8230#line $LINENO "configure"
cd958eb3
MB
8231/* confdefs.h. */
8232_ACEOF
8233cat confdefs.h >>conftest.$ac_ext
8234cat >>conftest.$ac_ext <<_ACEOF
8235/* end confdefs.h. */
98418dba
CW
8236
8237#include <X11/Intrinsic.h>
8238#include <X11/Xaw/Simple.h>
98418dba
CW
8239int
8240main ()
8241{
8242
8243 ;
8244 return 0;
8245}
8246_ACEOF
8247rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8248if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8249 (eval $ac_link) 2>&5
8250 ac_status=$?
c0d27fcc 8251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8252 (exit $ac_status); } &&
8253 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8254 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8255 (eval $ac_try) 2>&5
8256 ac_status=$?
c0d27fcc 8257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8258 (exit $ac_status); }; }; then
8259 emacs_cv_x11_version_5_with_xaw=yes
8260else
8261 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8262sed 's/^/| /' conftest.$ac_ext >&5
8263
98418dba
CW
8264emacs_cv_x11_version_5_with_xaw=no
8265fi
8266rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8267fi
8268
8269 if test $emacs_cv_x11_version_5_with_xaw = yes; then
c0d27fcc 8270 echo "$as_me:$LINENO: result: 5 or newer, with Xaw; use toolkit by default" >&5
98418dba
CW
8271echo "${ECHO_T}5 or newer, with Xaw; use toolkit by default" >&6
8272 USE_X_TOOLKIT=LUCID
8273 else
c0d27fcc 8274 echo "$as_me:$LINENO: result: before 5 or no Xaw; do not use toolkit by default" >&5
98418dba
CW
8275echo "${ECHO_T}before 5 or no Xaw; do not use toolkit by default" >&6
8276 USE_X_TOOLKIT=none
8277 fi
8278 else
8279 USE_X_TOOLKIT=none
8280 fi
8281fi
8282
8283X_TOOLKIT_TYPE=$USE_X_TOOLKIT
8284
8285if test "${USE_X_TOOLKIT}" != "none"; then
c0d27fcc 8286 echo "$as_me:$LINENO: checking X11 toolkit version" >&5
98418dba
CW
8287echo $ECHO_N "checking X11 toolkit version... $ECHO_C" >&6
8288 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then
8289 echo $ECHO_N "(cached) $ECHO_C" >&6
8290else
8291 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8292#line $LINENO "configure"
cd958eb3
MB
8293/* confdefs.h. */
8294_ACEOF
8295cat confdefs.h >>conftest.$ac_ext
8296cat >>conftest.$ac_ext <<_ACEOF
8297/* end confdefs.h. */
98418dba 8298#include <X11/Intrinsic.h>
98418dba
CW
8299int
8300main ()
8301{
8302#if XtSpecificationRelease < 6
8303fail;
8304#endif
8305
8306 ;
8307 return 0;
8308}
8309_ACEOF
8310rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8311if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8312 (eval $ac_link) 2>&5
8313 ac_status=$?
c0d27fcc 8314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8315 (exit $ac_status); } &&
8316 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8318 (eval $ac_try) 2>&5
8319 ac_status=$?
c0d27fcc 8320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8321 (exit $ac_status); }; }; then
8322 emacs_cv_x11_toolkit_version_6=yes
8323else
8324 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8325sed 's/^/| /' conftest.$ac_ext >&5
8326
98418dba
CW
8327emacs_cv_x11_toolkit_version_6=no
8328fi
8329rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8330fi
8331
8332 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
8333 if test $emacs_cv_x11_toolkit_version_6 = yes; then
c0d27fcc 8334 echo "$as_me:$LINENO: result: 6 or newer" >&5
98418dba 8335echo "${ECHO_T}6 or newer" >&6
b936fae4 8336
c0d27fcc 8337cat >>confdefs.h <<\_ACEOF
98418dba 8338#define HAVE_X11XTR6 1
c0d27fcc 8339_ACEOF
98418dba
CW
8340
8341 else
c0d27fcc 8342 echo "$as_me:$LINENO: result: before 6" >&5
98418dba
CW
8343echo "${ECHO_T}before 6" >&6
8344 fi
8345
8346 OLDLIBS="$LIBS"
8347 if test x$HAVE_X11XTR6 = xyes; then
8348 LIBS="-lXt -lSM -lICE $LIBS"
8349 else
8350 LIBS="-lXt $LIBS"
8351 fi
8352
c0d27fcc 8353echo "$as_me:$LINENO: checking for XmuConvertStandardSelection in -lXmu" >&5
98418dba
CW
8354echo $ECHO_N "checking for XmuConvertStandardSelection in -lXmu... $ECHO_C" >&6
8355if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then
8356 echo $ECHO_N "(cached) $ECHO_C" >&6
8357else
8358 ac_check_lib_save_LIBS=$LIBS
8359LIBS="-lXmu $LIBS"
8360cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8361#line $LINENO "configure"
cd958eb3
MB
8362/* confdefs.h. */
8363_ACEOF
8364cat confdefs.h >>conftest.$ac_ext
8365cat >>conftest.$ac_ext <<_ACEOF
8366/* end confdefs.h. */
98418dba
CW
8367
8368/* Override any gcc2 internal prototype to avoid an error. */
8369#ifdef __cplusplus
8370extern "C"
8371#endif
8372/* We use char because int might match the return type of a gcc2
8373 builtin and then its argument prototype would still apply. */
8374char XmuConvertStandardSelection ();
98418dba
CW
8375int
8376main ()
8377{
8378XmuConvertStandardSelection ();
8379 ;
8380 return 0;
8381}
8382_ACEOF
8383rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8384if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8385 (eval $ac_link) 2>&5
8386 ac_status=$?
c0d27fcc 8387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8388 (exit $ac_status); } &&
8389 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8390 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8391 (eval $ac_try) 2>&5
8392 ac_status=$?
c0d27fcc 8393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8394 (exit $ac_status); }; }; then
8395 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
8396else
8397 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8398sed 's/^/| /' conftest.$ac_ext >&5
8399
98418dba
CW
8400ac_cv_lib_Xmu_XmuConvertStandardSelection=no
8401fi
8402rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8403LIBS=$ac_check_lib_save_LIBS
8404fi
c0d27fcc 8405echo "$as_me:$LINENO: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
98418dba
CW
8406echo "${ECHO_T}$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6
8407if test $ac_cv_lib_Xmu_XmuConvertStandardSelection = yes; then
c0d27fcc 8408 cat >>confdefs.h <<_ACEOF
98418dba 8409#define HAVE_LIBXMU 1
c0d27fcc 8410_ACEOF
98418dba
CW
8411
8412 LIBS="-lXmu $LIBS"
8413
8414fi
8415
8416 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
8417fi
8418
8419# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
8420if test "${HAVE_X11}" = "yes"; then
8421 if test "${USE_X_TOOLKIT}" != "none"; then
8422
c0d27fcc 8423echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
98418dba
CW
8424echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6
8425if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
8426 echo $ECHO_N "(cached) $ECHO_C" >&6
8427else
8428 ac_check_lib_save_LIBS=$LIBS
8429LIBS="-lXext $LIBS"
8430cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8431#line $LINENO "configure"
cd958eb3
MB
8432/* confdefs.h. */
8433_ACEOF
8434cat confdefs.h >>conftest.$ac_ext
8435cat >>conftest.$ac_ext <<_ACEOF
8436/* end confdefs.h. */
98418dba
CW
8437
8438/* Override any gcc2 internal prototype to avoid an error. */
8439#ifdef __cplusplus
8440extern "C"
8441#endif
8442/* We use char because int might match the return type of a gcc2
8443 builtin and then its argument prototype would still apply. */
8444char XShapeQueryExtension ();
98418dba
CW
8445int
8446main ()
8447{
8448XShapeQueryExtension ();
8449 ;
8450 return 0;
8451}
8452_ACEOF
8453rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8454if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8455 (eval $ac_link) 2>&5
8456 ac_status=$?
c0d27fcc 8457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8458 (exit $ac_status); } &&
8459 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8460 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8461 (eval $ac_try) 2>&5
8462 ac_status=$?
c0d27fcc 8463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8464 (exit $ac_status); }; }; then
8465 ac_cv_lib_Xext_XShapeQueryExtension=yes
8466else
8467 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8468sed 's/^/| /' conftest.$ac_ext >&5
8469
98418dba
CW
8470ac_cv_lib_Xext_XShapeQueryExtension=no
8471fi
8472rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8473LIBS=$ac_check_lib_save_LIBS
8474fi
c0d27fcc 8475echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
98418dba
CW
8476echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6
8477if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
c0d27fcc 8478 cat >>confdefs.h <<_ACEOF
98418dba 8479#define HAVE_LIBXEXT 1
c0d27fcc 8480_ACEOF
98418dba
CW
8481
8482 LIBS="-lXext $LIBS"
8483
8484fi
8485
8486 fi
8487fi
8488
8489if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 8490 echo "$as_me:$LINENO: checking for LessTif where some systems put it" >&5
8e967cf7
MR
8491echo $ECHO_N "checking for LessTif where some systems put it... $ECHO_C" >&6
8492if test "${emacs_cv_lesstif+set}" = set; then
8493 echo $ECHO_N "(cached) $ECHO_C" >&6
8494else
ae1a998c
RS
8495 # We put this in CFLAGS temporarily to precede other -I options
8496 # that might be in CFLAGS temporarily.
8497 # We put this in CPPFLAGS where it precedes the other -I options.
8498 OLD_CPPFLAGS=$CPPFLAGS
8499 OLD_CFLAGS=$CFLAGS
8500 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
8501 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
8e967cf7 8502 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8503#line $LINENO "configure"
cd958eb3
MB
8504/* confdefs.h. */
8505_ACEOF
8506cat confdefs.h >>conftest.$ac_ext
8507cat >>conftest.$ac_ext <<_ACEOF
8508/* end confdefs.h. */
8e967cf7
MR
8509#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
8510int
8511main ()
8512{
8513int x = 5;
8514 ;
8515 return 0;
8516}
8517_ACEOF
8518rm -f conftest.$ac_objext
c0d27fcc 8519if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8e967cf7
MR
8520 (eval $ac_compile) 2>&5
8521 ac_status=$?
c0d27fcc 8522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
8523 (exit $ac_status); } &&
8524 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8525 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8e967cf7
MR
8526 (eval $ac_try) 2>&5
8527 ac_status=$?
c0d27fcc 8528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8e967cf7
MR
8529 (exit $ac_status); }; }; then
8530 emacs_cv_lesstif=yes
8531else
8532 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8533sed 's/^/| /' conftest.$ac_ext >&5
8534
8e967cf7
MR
8535emacs_cv_lesstif=no
8536fi
8537rm -f conftest.$ac_objext conftest.$ac_ext
8538fi
c0d27fcc 8539echo "$as_me:$LINENO: result: $emacs_cv_lesstif" >&5
8e967cf7
MR
8540echo "${ECHO_T}$emacs_cv_lesstif" >&6
8541 if test $emacs_cv_lesstif = yes; then
ae1a998c
RS
8542 # Make sure this -I option remains in CPPFLAGS after it is set
8543 # back to REAL_CPPFLAGS.
8544 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
8545 # have those other -I options anyway. Ultimately, having this
8546 # directory ultimately in CPPFLAGS will be enough.
8547 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
8e967cf7 8548 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
ae1a998c
RS
8549 else
8550 CFLAGS=$OLD_CFLAGS
8551 CPPFLAGS=$OLD_CPPFLAGS
8e967cf7 8552 fi
c0d27fcc 8553 echo "$as_me:$LINENO: checking for Motif version 2.1" >&5
98418dba
CW
8554echo $ECHO_N "checking for Motif version 2.1... $ECHO_C" >&6
8555if test "${emacs_cv_motif_version_2_1+set}" = set; then
8556 echo $ECHO_N "(cached) $ECHO_C" >&6
8557else
8558 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8559#line $LINENO "configure"
cd958eb3
MB
8560/* confdefs.h. */
8561_ACEOF
8562cat confdefs.h >>conftest.$ac_ext
8563cat >>conftest.$ac_ext <<_ACEOF
8564/* end confdefs.h. */
98418dba 8565#include <Xm/Xm.h>
98418dba
CW
8566int
8567main ()
8568{
8569#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
8570int x = 5;
8571#else
8572Motif version prior to 2.1.
8573#endif
8574 ;
8575 return 0;
8576}
8577_ACEOF
8578rm -f conftest.$ac_objext
c0d27fcc 8579if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba
CW
8580 (eval $ac_compile) 2>&5
8581 ac_status=$?
c0d27fcc 8582 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8583 (exit $ac_status); } &&
8584 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 8585 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8586 (eval $ac_try) 2>&5
8587 ac_status=$?
c0d27fcc 8588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8589 (exit $ac_status); }; }; then
8590 emacs_cv_motif_version_2_1=yes
8591else
8592 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8593sed 's/^/| /' conftest.$ac_ext >&5
8594
98418dba
CW
8595emacs_cv_motif_version_2_1=no
8596fi
8597rm -f conftest.$ac_objext conftest.$ac_ext
8598fi
c0d27fcc 8599echo "$as_me:$LINENO: result: $emacs_cv_motif_version_2_1" >&5
98418dba
CW
8600echo "${ECHO_T}$emacs_cv_motif_version_2_1" >&6
8601 HAVE_MOTIF_2_1=$emacs_cv_motif_version_2_1
8602 if test $emacs_cv_motif_version_2_1 = yes; then
8603 HAVE_LIBXP=no
b936fae4 8604
c0d27fcc 8605cat >>confdefs.h <<\_ACEOF
98418dba 8606#define HAVE_MOTIF_2_1 1
c0d27fcc 8607_ACEOF
98418dba 8608
c0d27fcc 8609 echo "$as_me:$LINENO: checking for XpCreateContext in -lXp" >&5
98418dba
CW
8610echo $ECHO_N "checking for XpCreateContext in -lXp... $ECHO_C" >&6
8611if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then
8612 echo $ECHO_N "(cached) $ECHO_C" >&6
8613else
8614 ac_check_lib_save_LIBS=$LIBS
8615LIBS="-lXp $LIBS"
8616cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8617#line $LINENO "configure"
cd958eb3
MB
8618/* confdefs.h. */
8619_ACEOF
8620cat confdefs.h >>conftest.$ac_ext
8621cat >>conftest.$ac_ext <<_ACEOF
8622/* end confdefs.h. */
98418dba
CW
8623
8624/* Override any gcc2 internal prototype to avoid an error. */
8625#ifdef __cplusplus
8626extern "C"
8627#endif
8628/* We use char because int might match the return type of a gcc2
8629 builtin and then its argument prototype would still apply. */
8630char XpCreateContext ();
98418dba
CW
8631int
8632main ()
8633{
8634XpCreateContext ();
8635 ;
8636 return 0;
8637}
8638_ACEOF
8639rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8640if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
8641 (eval $ac_link) 2>&5
8642 ac_status=$?
c0d27fcc 8643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8644 (exit $ac_status); } &&
8645 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
8647 (eval $ac_try) 2>&5
8648 ac_status=$?
c0d27fcc 8649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8650 (exit $ac_status); }; }; then
8651 ac_cv_lib_Xp_XpCreateContext=yes
8652else
8653 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8654sed 's/^/| /' conftest.$ac_ext >&5
8655
98418dba
CW
8656ac_cv_lib_Xp_XpCreateContext=no
8657fi
8658rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8659LIBS=$ac_check_lib_save_LIBS
8660fi
c0d27fcc 8661echo "$as_me:$LINENO: result: $ac_cv_lib_Xp_XpCreateContext" >&5
98418dba
CW
8662echo "${ECHO_T}$ac_cv_lib_Xp_XpCreateContext" >&6
8663if test $ac_cv_lib_Xp_XpCreateContext = yes; then
8664 HAVE_LIBXP=yes
8665fi
503d2be0 8666
98418dba 8667 if test ${HAVE_LIBXP} = yes; then
b936fae4 8668
c0d27fcc 8669cat >>confdefs.h <<\_ACEOF
98418dba 8670#define HAVE_LIBXP 1
c0d27fcc 8671_ACEOF
503d2be0 8672
98418dba
CW
8673 fi
8674 fi
8675fi
8676
8677### Is -lXaw3d available?
8678HAVE_XAW3D=no
8679if test "${HAVE_X11}" = "yes"; then
8680 if test "${USE_X_TOOLKIT}" != "none"; then
22044edf 8681 echo "$as_me:$LINENO: checking for X11/Xaw3d/Scrollbar.h" >&5
98418dba
CW
8682echo $ECHO_N "checking for X11/Xaw3d/Scrollbar.h... $ECHO_C" >&6
8683if test "${ac_cv_header_X11_Xaw3d_Scrollbar_h+set}" = set; then
8684 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba 8685else
22044edf 8686 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8687#line $LINENO "configure"
cd958eb3
MB
8688/* confdefs.h. */
8689_ACEOF
8690cat confdefs.h >>conftest.$ac_ext
8691cat >>conftest.$ac_ext <<_ACEOF
8692/* end confdefs.h. */
98418dba 8693#include <X11/Xaw3d/Scrollbar.h>
503d2be0 8694_ACEOF
c0d27fcc 8695if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
8696 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8697 ac_status=$?
6bae0ccf 8698 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
8699 rm -f conftest.er1
8700 cat conftest.err >&5
c0d27fcc 8701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
8702 (exit $ac_status); } >/dev/null; then
8703 if test -s conftest.err; then
8704 ac_cpp_err=$ac_c_preproc_warn_flag
8705 else
8706 ac_cpp_err=
8707 fi
8708else
8709 ac_cpp_err=yes
8710fi
8711if test -z "$ac_cpp_err"; then
22044edf 8712 ac_cv_header_X11_Xaw3d_Scrollbar_h=yes
ba4481b5 8713else
503d2be0 8714 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8715sed 's/^/| /' conftest.$ac_ext >&5
8716
22044edf 8717 ac_cv_header_X11_Xaw3d_Scrollbar_h=no
ba4481b5 8718fi
503d2be0 8719rm -f conftest.err conftest.$ac_ext
98418dba 8720fi
c0d27fcc 8721echo "$as_me:$LINENO: result: $ac_cv_header_X11_Xaw3d_Scrollbar_h" >&5
98418dba 8722echo "${ECHO_T}$ac_cv_header_X11_Xaw3d_Scrollbar_h" >&6
98418dba 8723if test $ac_cv_header_X11_Xaw3d_Scrollbar_h = yes; then
c0d27fcc 8724 echo "$as_me:$LINENO: checking for XawScrollbarSetThumb in -lXaw3d" >&5
98418dba
CW
8725echo $ECHO_N "checking for XawScrollbarSetThumb in -lXaw3d... $ECHO_C" >&6
8726if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then
8727 echo $ECHO_N "(cached) $ECHO_C" >&6
8728else
8729 ac_check_lib_save_LIBS=$LIBS
8730LIBS="-lXaw3d $LIBS"
8731cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8732#line $LINENO "configure"
cd958eb3
MB
8733/* confdefs.h. */
8734_ACEOF
8735cat confdefs.h >>conftest.$ac_ext
8736cat >>conftest.$ac_ext <<_ACEOF
8737/* end confdefs.h. */
98418dba
CW
8738
8739/* Override any gcc2 internal prototype to avoid an error. */
8740#ifdef __cplusplus
8741extern "C"
8742#endif
8743/* We use char because int might match the return type of a gcc2
8744 builtin and then its argument prototype would still apply. */
8745char XawScrollbarSetThumb ();
503d2be0
AS
8746int
8747main ()
8748{
98418dba 8749XawScrollbarSetThumb ();
503d2be0
AS
8750 ;
8751 return 0;
8752}
8753_ACEOF
8754rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8755if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
8756 (eval $ac_link) 2>&5
8757 ac_status=$?
c0d27fcc 8758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
8759 (exit $ac_status); } &&
8760 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 8761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
8762 (eval $ac_try) 2>&5
8763 ac_status=$?
c0d27fcc 8764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 8765 (exit $ac_status); }; }; then
98418dba 8766 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ba4481b5 8767else
503d2be0 8768 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8769sed 's/^/| /' conftest.$ac_ext >&5
8770
98418dba 8771ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ba4481b5 8772fi
503d2be0 8773rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 8774LIBS=$ac_check_lib_save_LIBS
ba4481b5 8775fi
c0d27fcc 8776echo "$as_me:$LINENO: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
98418dba
CW
8777echo "${ECHO_T}$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6
8778if test $ac_cv_lib_Xaw3d_XawScrollbarSetThumb = yes; then
8779 HAVE_XAW3D=yes
ba4481b5 8780fi
503d2be0 8781
ba4481b5
DL
8782fi
8783
c0d27fcc 8784
98418dba 8785 if test "${HAVE_XAW3D}" = "yes"; then
b936fae4 8786
c0d27fcc 8787cat >>confdefs.h <<\_ACEOF
98418dba 8788#define HAVE_XAW3D 1
c0d27fcc 8789_ACEOF
98418dba 8790
ba4481b5 8791 fi
98418dba 8792 fi
ba4481b5
DL
8793fi
8794
c0d27fcc
MR
8795
8796
98418dba
CW
8797USE_TOOLKIT_SCROLL_BARS=no
8798if test "${with_toolkit_scroll_bars}" != "no"; then
8799 if test "${USE_X_TOOLKIT}" != "none"; then
8800 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
c0d27fcc 8801 cat >>confdefs.h <<\_ACEOF
98418dba 8802#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 8803_ACEOF
98418dba
CW
8804
8805 HAVE_XAW3D=no
8806 USE_TOOLKIT_SCROLL_BARS=yes
8807 elif test "${HAVE_XAW3D}" = "yes"; then
c0d27fcc 8808 cat >>confdefs.h <<\_ACEOF
98418dba 8809#define USE_TOOLKIT_SCROLL_BARS 1
c0d27fcc 8810_ACEOF
98418dba
CW
8811
8812 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5 8813 fi
488dd4c4
JD
8814 elif test "${HAVE_GTK}" = "yes"; then
8815 cat >>confdefs.h <<\_ACEOF
8816#define USE_TOOLKIT_SCROLL_BARS 1
8817_ACEOF
8818
8819 USE_TOOLKIT_SCROLL_BARS=yes
ba4481b5
DL
8820 fi
8821fi
8822
c0d27fcc 8823
98418dba 8824if test "${with_xim}" != "no"; then
b936fae4 8825
c0d27fcc 8826cat >>confdefs.h <<\_ACEOF
98418dba 8827#define USE_XIM 1
c0d27fcc 8828_ACEOF
98418dba
CW
8829
8830fi
8831
8832### Use -lXpm if available, unless `--with-xpm=no'.
8833HAVE_XPM=no
8834if test "${HAVE_X11}" = "yes"; then
8835 if test "${with_xpm}" != "no"; then
c0d27fcc
MR
8836 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8837 echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
98418dba
CW
8838echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
8839if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8840 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
8841fi
8842echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
8843echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
98418dba 8844else
c0d27fcc
MR
8845 # Is the header compilable?
8846echo "$as_me:$LINENO: checking X11/xpm.h usability" >&5
8847echo $ECHO_N "checking X11/xpm.h usability... $ECHO_C" >&6
8848cat >conftest.$ac_ext <<_ACEOF
8849#line $LINENO "configure"
cd958eb3
MB
8850/* confdefs.h. */
8851_ACEOF
8852cat confdefs.h >>conftest.$ac_ext
8853cat >>conftest.$ac_ext <<_ACEOF
8854/* end confdefs.h. */
c0d27fcc
MR
8855$ac_includes_default
8856#include <X11/xpm.h>
8857_ACEOF
8858rm -f conftest.$ac_objext
8859if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8860 (eval $ac_compile) 2>&5
8861 ac_status=$?
8862 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8863 (exit $ac_status); } &&
8864 { ac_try='test -s conftest.$ac_objext'
8865 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8866 (eval $ac_try) 2>&5
8867 ac_status=$?
8868 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8869 (exit $ac_status); }; }; then
8870 ac_header_compiler=yes
8871else
8872 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8873sed 's/^/| /' conftest.$ac_ext >&5
8874
c0d27fcc
MR
8875ac_header_compiler=no
8876fi
8877rm -f conftest.$ac_objext conftest.$ac_ext
8878echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8879echo "${ECHO_T}$ac_header_compiler" >&6
8880
8881# Is the header present?
8882echo "$as_me:$LINENO: checking X11/xpm.h presence" >&5
8883echo $ECHO_N "checking X11/xpm.h presence... $ECHO_C" >&6
8884cat >conftest.$ac_ext <<_ACEOF
8885#line $LINENO "configure"
cd958eb3
MB
8886/* confdefs.h. */
8887_ACEOF
8888cat confdefs.h >>conftest.$ac_ext
8889cat >>conftest.$ac_ext <<_ACEOF
8890/* end confdefs.h. */
98418dba
CW
8891#include <X11/xpm.h>
8892_ACEOF
c0d27fcc 8893if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
8894 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8895 ac_status=$?
6bae0ccf 8896 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
8897 rm -f conftest.er1
8898 cat conftest.err >&5
c0d27fcc 8899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
8900 (exit $ac_status); } >/dev/null; then
8901 if test -s conftest.err; then
8902 ac_cpp_err=$ac_c_preproc_warn_flag
8903 else
8904 ac_cpp_err=
8905 fi
8906else
8907 ac_cpp_err=yes
8908fi
8909if test -z "$ac_cpp_err"; then
c0d27fcc 8910 ac_header_preproc=yes
98418dba
CW
8911else
8912 echo "$as_me: failed program was:" >&5
cd958eb3
MB
8913sed 's/^/| /' conftest.$ac_ext >&5
8914
c0d27fcc 8915 ac_header_preproc=no
98418dba
CW
8916fi
8917rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
8918echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8919echo "${ECHO_T}$ac_header_preproc" >&6
8920
8921# So? What about this header?
8922case $ac_header_compiler:$ac_header_preproc in
8923 yes:no )
8924 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&5
8925echo "$as_me: WARNING: X11/xpm.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
8926 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
8927echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
8928 (
8929 cat <<\_ASBOX
8930## ------------------------------------ ##
8931## Report this to bug-autoconf@gnu.org. ##
8932## ------------------------------------ ##
8933_ASBOX
8934 ) |
8935 sed "s/^/$as_me: WARNING: /" >&2
8936 ;;
c0d27fcc
MR
8937 no:yes )
8938 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: present but cannot be compiled" >&5
8939echo "$as_me: WARNING: X11/xpm.h: present but cannot be compiled" >&2;}
8940 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&5
8941echo "$as_me: WARNING: X11/xpm.h: check for missing prerequisite headers?" >&2;}
8942 { echo "$as_me:$LINENO: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
8943echo "$as_me: WARNING: X11/xpm.h: proceeding with the preprocessor's result" >&2;}
8944 (
8945 cat <<\_ASBOX
8946## ------------------------------------ ##
8947## Report this to bug-autoconf@gnu.org. ##
8948## ------------------------------------ ##
8949_ASBOX
8950 ) |
8951 sed "s/^/$as_me: WARNING: /" >&2
8952 ;;
c0d27fcc
MR
8953esac
8954echo "$as_me:$LINENO: checking for X11/xpm.h" >&5
8955echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
8956if test "${ac_cv_header_X11_xpm_h+set}" = set; then
8957 echo $ECHO_N "(cached) $ECHO_C" >&6
8958else
8959 ac_cv_header_X11_xpm_h=$ac_header_preproc
ba4481b5 8960fi
c0d27fcc 8961echo "$as_me:$LINENO: result: $ac_cv_header_X11_xpm_h" >&5
98418dba 8962echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
c0d27fcc
MR
8963
8964fi
98418dba 8965if test $ac_cv_header_X11_xpm_h = yes; then
c0d27fcc 8966 echo "$as_me:$LINENO: checking for XpmReadFileToPixmap in -lXpm" >&5
98418dba
CW
8967echo $ECHO_N "checking for XpmReadFileToPixmap in -lXpm... $ECHO_C" >&6
8968if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then
503d2be0 8969 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 8970else
98418dba
CW
8971 ac_check_lib_save_LIBS=$LIBS
8972LIBS="-lXpm -lX11 $LIBS"
8973cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 8974#line $LINENO "configure"
cd958eb3
MB
8975/* confdefs.h. */
8976_ACEOF
8977cat confdefs.h >>conftest.$ac_ext
8978cat >>conftest.$ac_ext <<_ACEOF
8979/* end confdefs.h. */
98418dba 8980
ba4481b5 8981/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
8982#ifdef __cplusplus
8983extern "C"
8984#endif
ba4481b5 8985/* We use char because int might match the return type of a gcc2
503d2be0 8986 builtin and then its argument prototype would still apply. */
98418dba 8987char XpmReadFileToPixmap ();
503d2be0
AS
8988int
8989main ()
8990{
98418dba 8991XpmReadFileToPixmap ();
503d2be0
AS
8992 ;
8993 return 0;
8994}
8995_ACEOF
8996rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 8997if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
8998 (eval $ac_link) 2>&5
8999 ac_status=$?
c0d27fcc 9000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9001 (exit $ac_status); } &&
9002 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9003 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9004 (eval $ac_try) 2>&5
9005 ac_status=$?
c0d27fcc 9006 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9007 (exit $ac_status); }; }; then
98418dba 9008 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
503d2be0
AS
9009else
9010 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9011sed 's/^/| /' conftest.$ac_ext >&5
9012
98418dba 9013ac_cv_lib_Xpm_XpmReadFileToPixmap=no
503d2be0
AS
9014fi
9015rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 9016LIBS=$ac_check_lib_save_LIBS
503d2be0 9017fi
c0d27fcc 9018echo "$as_me:$LINENO: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
98418dba
CW
9019echo "${ECHO_T}$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6
9020if test $ac_cv_lib_Xpm_XpmReadFileToPixmap = yes; then
9021 HAVE_XPM=yes
ba4481b5
DL
9022fi
9023
98418dba
CW
9024fi
9025
c0d27fcc 9026
98418dba 9027 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 9028 echo "$as_me:$LINENO: checking for XpmReturnAllocPixels preprocessor define" >&5
98418dba
CW
9029echo $ECHO_N "checking for XpmReturnAllocPixels preprocessor define... $ECHO_C" >&6
9030 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9031#line $LINENO "configure"
cd958eb3
MB
9032/* confdefs.h. */
9033_ACEOF
9034cat confdefs.h >>conftest.$ac_ext
9035cat >>conftest.$ac_ext <<_ACEOF
9036/* end confdefs.h. */
98418dba
CW
9037#include "X11/xpm.h"
9038#ifndef XpmReturnAllocPixels
9039no_return_alloc_pixels
503d2be0 9040#endif
ba4481b5 9041
98418dba
CW
9042_ACEOF
9043if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 9044 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then
98418dba
CW
9045 HAVE_XPM=no
9046else
9047 HAVE_XPM=yes
9048fi
9049rm -f conftest*
ba4481b5 9050
c0d27fcc 9051
98418dba 9052 if test "${HAVE_XPM}" = "yes"; then
c0d27fcc 9053 echo "$as_me:$LINENO: result: yes" >&5
98418dba
CW
9054echo "${ECHO_T}yes" >&6
9055 else
c0d27fcc 9056 echo "$as_me:$LINENO: result: no" >&5
98418dba
CW
9057echo "${ECHO_T}no" >&6
9058 fi
9059 fi
9060 fi
9061
9062 if test "${HAVE_XPM}" = "yes"; then
b936fae4 9063
c0d27fcc 9064cat >>confdefs.h <<\_ACEOF
98418dba 9065#define HAVE_XPM 1
c0d27fcc 9066_ACEOF
98418dba
CW
9067
9068 fi
9069fi
9070
9071### Use -ljpeg if available, unless `--with-jpeg=no'.
9072HAVE_JPEG=no
9073if test "${HAVE_X11}" = "yes"; then
9074 if test "${with_jpeg}" != "no"; then
c0d27fcc
MR
9075 if test "${ac_cv_header_jerror_h+set}" = set; then
9076 echo "$as_me:$LINENO: checking for jerror.h" >&5
98418dba
CW
9077echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
9078if test "${ac_cv_header_jerror_h+set}" = set; then
9079 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9080fi
9081echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
9082echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
503d2be0 9083else
c0d27fcc
MR
9084 # Is the header compilable?
9085echo "$as_me:$LINENO: checking jerror.h usability" >&5
9086echo $ECHO_N "checking jerror.h usability... $ECHO_C" >&6
9087cat >conftest.$ac_ext <<_ACEOF
9088#line $LINENO "configure"
cd958eb3
MB
9089/* confdefs.h. */
9090_ACEOF
9091cat confdefs.h >>conftest.$ac_ext
9092cat >>conftest.$ac_ext <<_ACEOF
9093/* end confdefs.h. */
c0d27fcc
MR
9094$ac_includes_default
9095#include <jerror.h>
9096_ACEOF
9097rm -f conftest.$ac_objext
9098if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9099 (eval $ac_compile) 2>&5
9100 ac_status=$?
9101 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9102 (exit $ac_status); } &&
9103 { ac_try='test -s conftest.$ac_objext'
9104 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9105 (eval $ac_try) 2>&5
9106 ac_status=$?
9107 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9108 (exit $ac_status); }; }; then
9109 ac_header_compiler=yes
9110else
9111 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9112sed 's/^/| /' conftest.$ac_ext >&5
9113
c0d27fcc
MR
9114ac_header_compiler=no
9115fi
9116rm -f conftest.$ac_objext conftest.$ac_ext
9117echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9118echo "${ECHO_T}$ac_header_compiler" >&6
9119
9120# Is the header present?
9121echo "$as_me:$LINENO: checking jerror.h presence" >&5
9122echo $ECHO_N "checking jerror.h presence... $ECHO_C" >&6
9123cat >conftest.$ac_ext <<_ACEOF
9124#line $LINENO "configure"
cd958eb3
MB
9125/* confdefs.h. */
9126_ACEOF
9127cat confdefs.h >>conftest.$ac_ext
9128cat >>conftest.$ac_ext <<_ACEOF
9129/* end confdefs.h. */
98418dba
CW
9130#include <jerror.h>
9131_ACEOF
c0d27fcc 9132if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9133 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9134 ac_status=$?
6bae0ccf 9135 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9136 rm -f conftest.er1
9137 cat conftest.err >&5
c0d27fcc 9138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9139 (exit $ac_status); } >/dev/null; then
9140 if test -s conftest.err; then
9141 ac_cpp_err=$ac_c_preproc_warn_flag
9142 else
9143 ac_cpp_err=
9144 fi
9145else
9146 ac_cpp_err=yes
503d2be0 9147fi
98418dba 9148if test -z "$ac_cpp_err"; then
c0d27fcc 9149 ac_header_preproc=yes
ba4481b5 9150else
98418dba 9151 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9152sed 's/^/| /' conftest.$ac_ext >&5
9153
c0d27fcc 9154 ac_header_preproc=no
98418dba
CW
9155fi
9156rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9157echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9158echo "${ECHO_T}$ac_header_preproc" >&6
9159
9160# So? What about this header?
9161case $ac_header_compiler:$ac_header_preproc in
9162 yes:no )
9163 { echo "$as_me:$LINENO: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&5
9164echo "$as_me: WARNING: jerror.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9165 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9166echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
9167 (
9168 cat <<\_ASBOX
9169## ------------------------------------ ##
9170## Report this to bug-autoconf@gnu.org. ##
9171## ------------------------------------ ##
9172_ASBOX
9173 ) |
9174 sed "s/^/$as_me: WARNING: /" >&2
9175 ;;
c0d27fcc
MR
9176 no:yes )
9177 { echo "$as_me:$LINENO: WARNING: jerror.h: present but cannot be compiled" >&5
9178echo "$as_me: WARNING: jerror.h: present but cannot be compiled" >&2;}
9179 { echo "$as_me:$LINENO: WARNING: jerror.h: check for missing prerequisite headers?" >&5
9180echo "$as_me: WARNING: jerror.h: check for missing prerequisite headers?" >&2;}
9181 { echo "$as_me:$LINENO: WARNING: jerror.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9182echo "$as_me: WARNING: jerror.h: proceeding with the preprocessor's result" >&2;}
9183 (
9184 cat <<\_ASBOX
9185## ------------------------------------ ##
9186## Report this to bug-autoconf@gnu.org. ##
9187## ------------------------------------ ##
9188_ASBOX
9189 ) |
9190 sed "s/^/$as_me: WARNING: /" >&2
9191 ;;
c0d27fcc
MR
9192esac
9193echo "$as_me:$LINENO: checking for jerror.h" >&5
9194echo $ECHO_N "checking for jerror.h... $ECHO_C" >&6
9195if test "${ac_cv_header_jerror_h+set}" = set; then
9196 echo $ECHO_N "(cached) $ECHO_C" >&6
9197else
9198 ac_cv_header_jerror_h=$ac_header_preproc
ba4481b5 9199fi
c0d27fcc 9200echo "$as_me:$LINENO: result: $ac_cv_header_jerror_h" >&5
98418dba 9201echo "${ECHO_T}$ac_cv_header_jerror_h" >&6
c0d27fcc
MR
9202
9203fi
98418dba 9204if test $ac_cv_header_jerror_h = yes; then
c0d27fcc 9205 echo "$as_me:$LINENO: checking for jpeg_destroy_compress in -ljpeg" >&5
98418dba
CW
9206echo $ECHO_N "checking for jpeg_destroy_compress in -ljpeg... $ECHO_C" >&6
9207if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then
503d2be0 9208 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 9209else
98418dba
CW
9210 ac_check_lib_save_LIBS=$LIBS
9211LIBS="-ljpeg $LIBS"
9212cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9213#line $LINENO "configure"
cd958eb3
MB
9214/* confdefs.h. */
9215_ACEOF
9216cat confdefs.h >>conftest.$ac_ext
9217cat >>conftest.$ac_ext <<_ACEOF
9218/* end confdefs.h. */
98418dba
CW
9219
9220/* Override any gcc2 internal prototype to avoid an error. */
9221#ifdef __cplusplus
9222extern "C"
9223#endif
9224/* We use char because int might match the return type of a gcc2
9225 builtin and then its argument prototype would still apply. */
9226char jpeg_destroy_compress ();
503d2be0
AS
9227int
9228main ()
9229{
98418dba 9230jpeg_destroy_compress ();
503d2be0
AS
9231 ;
9232 return 0;
9233}
9234_ACEOF
9235rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9236if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9237 (eval $ac_link) 2>&5
9238 ac_status=$?
c0d27fcc 9239 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9240 (exit $ac_status); } &&
9241 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9242 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9243 (eval $ac_try) 2>&5
9244 ac_status=$?
c0d27fcc 9245 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9246 (exit $ac_status); }; }; then
98418dba 9247 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
ba4481b5 9248else
503d2be0 9249 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9250sed 's/^/| /' conftest.$ac_ext >&5
9251
98418dba 9252ac_cv_lib_jpeg_jpeg_destroy_compress=no
ba4481b5 9253fi
503d2be0 9254rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 9255LIBS=$ac_check_lib_save_LIBS
ba4481b5 9256fi
c0d27fcc 9257echo "$as_me:$LINENO: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
98418dba
CW
9258echo "${ECHO_T}$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6
9259if test $ac_cv_lib_jpeg_jpeg_destroy_compress = yes; then
9260 HAVE_JPEG=yes
ba4481b5 9261fi
98418dba 9262
ba4481b5 9263fi
98418dba 9264
c0d27fcc 9265
ba4481b5 9266 fi
ba4481b5 9267
c0d27fcc 9268
98418dba 9269 if test "${HAVE_JPEG}" = "yes"; then
c0d27fcc 9270 cat >>confdefs.h <<\_ACEOF
98418dba 9271#define HAVE_JPEG 1
c0d27fcc 9272_ACEOF
98418dba
CW
9273
9274 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9275#line $LINENO "configure"
cd958eb3
MB
9276/* confdefs.h. */
9277_ACEOF
9278cat confdefs.h >>conftest.$ac_ext
9279cat >>conftest.$ac_ext <<_ACEOF
9280/* end confdefs.h. */
22044edf 9281#include <jpeglib.h>
98418dba
CW
9282 version=JPEG_LIB_VERSION
9283
9284_ACEOF
9285if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 9286 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then
c0d27fcc 9287 cat >>confdefs.h <<\_ACEOF
98418dba 9288#define HAVE_JPEG 1
c0d27fcc 9289_ACEOF
ba4481b5 9290
98418dba 9291else
c0d27fcc 9292 { echo "$as_me:$LINENO: WARNING: libjpeg found, but not version 6b or later" >&5
98418dba
CW
9293echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
9294 HAVE_JPEG=no
ba4481b5 9295fi
98418dba 9296rm -f conftest*
ba4481b5 9297
98418dba
CW
9298 fi
9299fi
503d2be0 9300
98418dba
CW
9301### Use -lpng if available, unless `--with-png=no'.
9302HAVE_PNG=no
9303if test "${HAVE_X11}" = "yes"; then
9304 if test "${with_png}" != "no"; then
c0d27fcc
MR
9305 if test "${ac_cv_header_png_h+set}" = set; then
9306 echo "$as_me:$LINENO: checking for png.h" >&5
98418dba
CW
9307echo $ECHO_N "checking for png.h... $ECHO_C" >&6
9308if test "${ac_cv_header_png_h+set}" = set; then
503d2be0 9309 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9310fi
9311echo "$as_me:$LINENO: result: $ac_cv_header_png_h" >&5
9312echo "${ECHO_T}$ac_cv_header_png_h" >&6
503d2be0 9313else
c0d27fcc
MR
9314 # Is the header compilable?
9315echo "$as_me:$LINENO: checking png.h usability" >&5
9316echo $ECHO_N "checking png.h usability... $ECHO_C" >&6
9317cat >conftest.$ac_ext <<_ACEOF
9318#line $LINENO "configure"
cd958eb3
MB
9319/* confdefs.h. */
9320_ACEOF
9321cat confdefs.h >>conftest.$ac_ext
9322cat >>conftest.$ac_ext <<_ACEOF
9323/* end confdefs.h. */
c0d27fcc
MR
9324$ac_includes_default
9325#include <png.h>
9326_ACEOF
9327rm -f conftest.$ac_objext
9328if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9329 (eval $ac_compile) 2>&5
9330 ac_status=$?
9331 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9332 (exit $ac_status); } &&
9333 { ac_try='test -s conftest.$ac_objext'
9334 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9335 (eval $ac_try) 2>&5
9336 ac_status=$?
9337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9338 (exit $ac_status); }; }; then
9339 ac_header_compiler=yes
9340else
9341 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9342sed 's/^/| /' conftest.$ac_ext >&5
9343
c0d27fcc
MR
9344ac_header_compiler=no
9345fi
9346rm -f conftest.$ac_objext conftest.$ac_ext
9347echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9348echo "${ECHO_T}$ac_header_compiler" >&6
9349
9350# Is the header present?
9351echo "$as_me:$LINENO: checking png.h presence" >&5
9352echo $ECHO_N "checking png.h presence... $ECHO_C" >&6
9353cat >conftest.$ac_ext <<_ACEOF
9354#line $LINENO "configure"
cd958eb3
MB
9355/* confdefs.h. */
9356_ACEOF
9357cat confdefs.h >>conftest.$ac_ext
9358cat >>conftest.$ac_ext <<_ACEOF
9359/* end confdefs.h. */
98418dba 9360#include <png.h>
503d2be0 9361_ACEOF
c0d27fcc 9362if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
9363 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9364 ac_status=$?
6bae0ccf 9365 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
9366 rm -f conftest.er1
9367 cat conftest.err >&5
c0d27fcc 9368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9369 (exit $ac_status); } >/dev/null; then
9370 if test -s conftest.err; then
9371 ac_cpp_err=$ac_c_preproc_warn_flag
9372 else
9373 ac_cpp_err=
9374 fi
9375else
9376 ac_cpp_err=yes
9377fi
9378if test -z "$ac_cpp_err"; then
c0d27fcc 9379 ac_header_preproc=yes
503d2be0
AS
9380else
9381 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9382sed 's/^/| /' conftest.$ac_ext >&5
9383
c0d27fcc 9384 ac_header_preproc=no
ba4481b5 9385fi
503d2be0 9386rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9387echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9388echo "${ECHO_T}$ac_header_preproc" >&6
9389
9390# So? What about this header?
9391case $ac_header_compiler:$ac_header_preproc in
9392 yes:no )
9393 { echo "$as_me:$LINENO: WARNING: png.h: accepted by the compiler, rejected by the preprocessor!" >&5
9394echo "$as_me: WARNING: png.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9395 { echo "$as_me:$LINENO: WARNING: png.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9396echo "$as_me: WARNING: png.h: proceeding with the preprocessor's result" >&2;}
9397 (
9398 cat <<\_ASBOX
9399## ------------------------------------ ##
9400## Report this to bug-autoconf@gnu.org. ##
9401## ------------------------------------ ##
9402_ASBOX
9403 ) |
9404 sed "s/^/$as_me: WARNING: /" >&2
9405 ;;
c0d27fcc
MR
9406 no:yes )
9407 { echo "$as_me:$LINENO: WARNING: png.h: present but cannot be compiled" >&5
9408echo "$as_me: WARNING: png.h: present but cannot be compiled" >&2;}
9409 { echo "$as_me:$LINENO: WARNING: png.h: check for missing prerequisite headers?" >&5
9410echo "$as_me: WARNING: png.h: check for missing prerequisite headers?" >&2;}
9411 { echo "$as_me:$LINENO: WARNING: png.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9412echo "$as_me: WARNING: png.h: proceeding with the preprocessor's result" >&2;}
9413 (
9414 cat <<\_ASBOX
9415## ------------------------------------ ##
9416## Report this to bug-autoconf@gnu.org. ##
9417## ------------------------------------ ##
9418_ASBOX
9419 ) |
9420 sed "s/^/$as_me: WARNING: /" >&2
9421 ;;
c0d27fcc
MR
9422esac
9423echo "$as_me:$LINENO: checking for png.h" >&5
9424echo $ECHO_N "checking for png.h... $ECHO_C" >&6
9425if test "${ac_cv_header_png_h+set}" = set; then
9426 echo $ECHO_N "(cached) $ECHO_C" >&6
9427else
9428 ac_cv_header_png_h=$ac_header_preproc
ba4481b5 9429fi
c0d27fcc 9430echo "$as_me:$LINENO: result: $ac_cv_header_png_h" >&5
98418dba 9431echo "${ECHO_T}$ac_cv_header_png_h" >&6
c0d27fcc
MR
9432
9433fi
98418dba 9434if test $ac_cv_header_png_h = yes; then
c0d27fcc 9435 echo "$as_me:$LINENO: checking for png_get_channels in -lpng" >&5
98418dba
CW
9436echo $ECHO_N "checking for png_get_channels in -lpng... $ECHO_C" >&6
9437if test "${ac_cv_lib_png_png_get_channels+set}" = set; then
503d2be0 9438 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 9439else
98418dba
CW
9440 ac_check_lib_save_LIBS=$LIBS
9441LIBS="-lpng -lz -lm $LIBS"
9442cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9443#line $LINENO "configure"
cd958eb3
MB
9444/* confdefs.h. */
9445_ACEOF
9446cat confdefs.h >>conftest.$ac_ext
9447cat >>conftest.$ac_ext <<_ACEOF
9448/* end confdefs.h. */
98418dba 9449
ba4481b5 9450/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
9451#ifdef __cplusplus
9452extern "C"
9453#endif
ba4481b5 9454/* We use char because int might match the return type of a gcc2
503d2be0 9455 builtin and then its argument prototype would still apply. */
98418dba 9456char png_get_channels ();
503d2be0
AS
9457int
9458main ()
9459{
98418dba 9460png_get_channels ();
503d2be0
AS
9461 ;
9462 return 0;
9463}
9464_ACEOF
9465rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9466if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9467 (eval $ac_link) 2>&5
9468 ac_status=$?
c0d27fcc 9469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9470 (exit $ac_status); } &&
9471 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9472 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9473 (eval $ac_try) 2>&5
9474 ac_status=$?
c0d27fcc 9475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9476 (exit $ac_status); }; }; then
98418dba 9477 ac_cv_lib_png_png_get_channels=yes
73b77ee5 9478else
98418dba 9479 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9480sed 's/^/| /' conftest.$ac_ext >&5
9481
98418dba 9482ac_cv_lib_png_png_get_channels=no
73b77ee5 9483fi
98418dba
CW
9484rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9485LIBS=$ac_check_lib_save_LIBS
73b77ee5 9486fi
c0d27fcc 9487echo "$as_me:$LINENO: result: $ac_cv_lib_png_png_get_channels" >&5
98418dba
CW
9488echo "${ECHO_T}$ac_cv_lib_png_png_get_channels" >&6
9489if test $ac_cv_lib_png_png_get_channels = yes; then
9490 HAVE_PNG=yes
73b77ee5 9491fi
503d2be0 9492
98418dba
CW
9493fi
9494
c0d27fcc 9495
98418dba
CW
9496 fi
9497
9498 if test "${HAVE_PNG}" = "yes"; then
b936fae4 9499
c0d27fcc 9500cat >>confdefs.h <<\_ACEOF
98418dba 9501#define HAVE_PNG 1
c0d27fcc 9502_ACEOF
73b77ee5 9503
98418dba 9504 fi
73b77ee5
GM
9505fi
9506
98418dba
CW
9507### Use -ltiff if available, unless `--with-tiff=no'.
9508HAVE_TIFF=no
9509if test "${HAVE_X11}" = "yes"; then
9510 if test "${with_tiff}" != "no"; then
c0d27fcc
MR
9511 if test "${ac_cv_header_tiffio_h+set}" = set; then
9512 echo "$as_me:$LINENO: checking for tiffio.h" >&5
98418dba
CW
9513echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
9514if test "${ac_cv_header_tiffio_h+set}" = set; then
9515 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9516fi
9517echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
9518echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
98418dba 9519else
c0d27fcc
MR
9520 # Is the header compilable?
9521echo "$as_me:$LINENO: checking tiffio.h usability" >&5
9522echo $ECHO_N "checking tiffio.h usability... $ECHO_C" >&6
9523cat >conftest.$ac_ext <<_ACEOF
9524#line $LINENO "configure"
cd958eb3
MB
9525/* confdefs.h. */
9526_ACEOF
9527cat confdefs.h >>conftest.$ac_ext
9528cat >>conftest.$ac_ext <<_ACEOF
9529/* end confdefs.h. */
c0d27fcc
MR
9530$ac_includes_default
9531#include <tiffio.h>
9532_ACEOF
9533rm -f conftest.$ac_objext
9534if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9535 (eval $ac_compile) 2>&5
9536 ac_status=$?
9537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9538 (exit $ac_status); } &&
9539 { ac_try='test -s conftest.$ac_objext'
9540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9541 (eval $ac_try) 2>&5
9542 ac_status=$?
9543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9544 (exit $ac_status); }; }; then
9545 ac_header_compiler=yes
9546else
9547 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9548sed 's/^/| /' conftest.$ac_ext >&5
9549
c0d27fcc
MR
9550ac_header_compiler=no
9551fi
9552rm -f conftest.$ac_objext conftest.$ac_ext
9553echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9554echo "${ECHO_T}$ac_header_compiler" >&6
9555
9556# Is the header present?
9557echo "$as_me:$LINENO: checking tiffio.h presence" >&5
9558echo $ECHO_N "checking tiffio.h presence... $ECHO_C" >&6
9559cat >conftest.$ac_ext <<_ACEOF
9560#line $LINENO "configure"
cd958eb3
MB
9561/* confdefs.h. */
9562_ACEOF
9563cat confdefs.h >>conftest.$ac_ext
9564cat >>conftest.$ac_ext <<_ACEOF
9565/* end confdefs.h. */
98418dba
CW
9566#include <tiffio.h>
9567_ACEOF
c0d27fcc 9568if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9569 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9570 ac_status=$?
6bae0ccf 9571 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9572 rm -f conftest.er1
9573 cat conftest.err >&5
c0d27fcc 9574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9575 (exit $ac_status); } >/dev/null; then
9576 if test -s conftest.err; then
9577 ac_cpp_err=$ac_c_preproc_warn_flag
9578 else
9579 ac_cpp_err=
9580 fi
9581else
9582 ac_cpp_err=yes
9583fi
9584if test -z "$ac_cpp_err"; then
c0d27fcc 9585 ac_header_preproc=yes
98418dba
CW
9586else
9587 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9588sed 's/^/| /' conftest.$ac_ext >&5
9589
c0d27fcc 9590 ac_header_preproc=no
98418dba
CW
9591fi
9592rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9593echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9594echo "${ECHO_T}$ac_header_preproc" >&6
9595
9596# So? What about this header?
9597case $ac_header_compiler:$ac_header_preproc in
9598 yes:no )
9599 { echo "$as_me:$LINENO: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&5
9600echo "$as_me: WARNING: tiffio.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9601 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9602echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
9603 (
9604 cat <<\_ASBOX
9605## ------------------------------------ ##
9606## Report this to bug-autoconf@gnu.org. ##
9607## ------------------------------------ ##
9608_ASBOX
9609 ) |
9610 sed "s/^/$as_me: WARNING: /" >&2
9611 ;;
c0d27fcc
MR
9612 no:yes )
9613 { echo "$as_me:$LINENO: WARNING: tiffio.h: present but cannot be compiled" >&5
9614echo "$as_me: WARNING: tiffio.h: present but cannot be compiled" >&2;}
9615 { echo "$as_me:$LINENO: WARNING: tiffio.h: check for missing prerequisite headers?" >&5
9616echo "$as_me: WARNING: tiffio.h: check for missing prerequisite headers?" >&2;}
9617 { echo "$as_me:$LINENO: WARNING: tiffio.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9618echo "$as_me: WARNING: tiffio.h: proceeding with the preprocessor's result" >&2;}
9619 (
9620 cat <<\_ASBOX
9621## ------------------------------------ ##
9622## Report this to bug-autoconf@gnu.org. ##
9623## ------------------------------------ ##
9624_ASBOX
9625 ) |
9626 sed "s/^/$as_me: WARNING: /" >&2
9627 ;;
c0d27fcc
MR
9628esac
9629echo "$as_me:$LINENO: checking for tiffio.h" >&5
9630echo $ECHO_N "checking for tiffio.h... $ECHO_C" >&6
9631if test "${ac_cv_header_tiffio_h+set}" = set; then
9632 echo $ECHO_N "(cached) $ECHO_C" >&6
9633else
9634 ac_cv_header_tiffio_h=$ac_header_preproc
98418dba 9635fi
c0d27fcc 9636echo "$as_me:$LINENO: result: $ac_cv_header_tiffio_h" >&5
98418dba 9637echo "${ECHO_T}$ac_cv_header_tiffio_h" >&6
c0d27fcc
MR
9638
9639fi
98418dba
CW
9640if test $ac_cv_header_tiffio_h = yes; then
9641 tifflibs="-lz -lm"
9642 # At least one tiff package requires the jpeg library.
9643 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
c0d27fcc 9644 echo "$as_me:$LINENO: checking for TIFFGetVersion in -ltiff" >&5
98418dba
CW
9645echo $ECHO_N "checking for TIFFGetVersion in -ltiff... $ECHO_C" >&6
9646if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then
503d2be0 9647 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 9648else
503d2be0 9649 ac_check_lib_save_LIBS=$LIBS
98418dba 9650LIBS="-ltiff $tifflibs $LIBS"
503d2be0 9651cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9652#line $LINENO "configure"
cd958eb3
MB
9653/* confdefs.h. */
9654_ACEOF
9655cat confdefs.h >>conftest.$ac_ext
9656cat >>conftest.$ac_ext <<_ACEOF
9657/* end confdefs.h. */
503d2be0 9658
73b77ee5 9659/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
9660#ifdef __cplusplus
9661extern "C"
9662#endif
73b77ee5 9663/* We use char because int might match the return type of a gcc2
503d2be0 9664 builtin and then its argument prototype would still apply. */
98418dba 9665char TIFFGetVersion ();
503d2be0
AS
9666int
9667main ()
9668{
98418dba 9669TIFFGetVersion ();
503d2be0
AS
9670 ;
9671 return 0;
9672}
9673_ACEOF
9674rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9675if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9676 (eval $ac_link) 2>&5
9677 ac_status=$?
c0d27fcc 9678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
9679 (exit $ac_status); } &&
9680 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9681 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
9682 (eval $ac_try) 2>&5
9683 ac_status=$?
c0d27fcc 9684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 9685 (exit $ac_status); }; }; then
98418dba 9686 ac_cv_lib_tiff_TIFFGetVersion=yes
503d2be0
AS
9687else
9688 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9689sed 's/^/| /' conftest.$ac_ext >&5
9690
98418dba 9691ac_cv_lib_tiff_TIFFGetVersion=no
503d2be0
AS
9692fi
9693rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9694LIBS=$ac_check_lib_save_LIBS
9695fi
c0d27fcc 9696echo "$as_me:$LINENO: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
98418dba
CW
9697echo "${ECHO_T}$ac_cv_lib_tiff_TIFFGetVersion" >&6
9698if test $ac_cv_lib_tiff_TIFFGetVersion = yes; then
9699 HAVE_TIFF=yes
9700fi
9701
9702fi
73b77ee5 9703
c0d27fcc 9704
98418dba
CW
9705 fi
9706
9707 if test "${HAVE_TIFF}" = "yes"; then
b936fae4 9708
c0d27fcc 9709cat >>confdefs.h <<\_ACEOF
98418dba 9710#define HAVE_TIFF 1
c0d27fcc 9711_ACEOF
98418dba
CW
9712
9713 fi
73b77ee5
GM
9714fi
9715
98418dba
CW
9716### Use -lgif if available, unless `--with-gif=no'.
9717HAVE_GIF=no
9718if test "${HAVE_X11}" = "yes"; then
9719 if test "${with_gif}" != "no"; then
c0d27fcc
MR
9720 if test "${ac_cv_header_gif_lib_h+set}" = set; then
9721 echo "$as_me:$LINENO: checking for gif_lib.h" >&5
98418dba
CW
9722echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
9723if test "${ac_cv_header_gif_lib_h+set}" = set; then
9724 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
9725fi
9726echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
9727echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
98418dba 9728else
c0d27fcc
MR
9729 # Is the header compilable?
9730echo "$as_me:$LINENO: checking gif_lib.h usability" >&5
9731echo $ECHO_N "checking gif_lib.h usability... $ECHO_C" >&6
9732cat >conftest.$ac_ext <<_ACEOF
9733#line $LINENO "configure"
cd958eb3
MB
9734/* confdefs.h. */
9735_ACEOF
9736cat confdefs.h >>conftest.$ac_ext
9737cat >>conftest.$ac_ext <<_ACEOF
9738/* end confdefs.h. */
c0d27fcc
MR
9739$ac_includes_default
9740#include <gif_lib.h>
9741_ACEOF
9742rm -f conftest.$ac_objext
9743if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9744 (eval $ac_compile) 2>&5
9745 ac_status=$?
9746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9747 (exit $ac_status); } &&
9748 { ac_try='test -s conftest.$ac_objext'
9749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9750 (eval $ac_try) 2>&5
9751 ac_status=$?
9752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9753 (exit $ac_status); }; }; then
9754 ac_header_compiler=yes
9755else
9756 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9757sed 's/^/| /' conftest.$ac_ext >&5
9758
c0d27fcc
MR
9759ac_header_compiler=no
9760fi
9761rm -f conftest.$ac_objext conftest.$ac_ext
9762echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9763echo "${ECHO_T}$ac_header_compiler" >&6
9764
9765# Is the header present?
9766echo "$as_me:$LINENO: checking gif_lib.h presence" >&5
9767echo $ECHO_N "checking gif_lib.h presence... $ECHO_C" >&6
9768cat >conftest.$ac_ext <<_ACEOF
9769#line $LINENO "configure"
cd958eb3
MB
9770/* confdefs.h. */
9771_ACEOF
9772cat confdefs.h >>conftest.$ac_ext
9773cat >>conftest.$ac_ext <<_ACEOF
9774/* end confdefs.h. */
98418dba
CW
9775#include <gif_lib.h>
9776_ACEOF
c0d27fcc 9777if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
9778 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9779 ac_status=$?
6bae0ccf 9780 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
9781 rm -f conftest.er1
9782 cat conftest.err >&5
c0d27fcc 9783 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9784 (exit $ac_status); } >/dev/null; then
9785 if test -s conftest.err; then
9786 ac_cpp_err=$ac_c_preproc_warn_flag
9787 else
9788 ac_cpp_err=
9789 fi
9790else
9791 ac_cpp_err=yes
9792fi
9793if test -z "$ac_cpp_err"; then
c0d27fcc 9794 ac_header_preproc=yes
98418dba
CW
9795else
9796 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9797sed 's/^/| /' conftest.$ac_ext >&5
9798
c0d27fcc 9799 ac_header_preproc=no
98418dba
CW
9800fi
9801rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
9802echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9803echo "${ECHO_T}$ac_header_preproc" >&6
9804
9805# So? What about this header?
9806case $ac_header_compiler:$ac_header_preproc in
9807 yes:no )
9808 { echo "$as_me:$LINENO: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9809echo "$as_me: WARNING: gif_lib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9810 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9811echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
9812 (
9813 cat <<\_ASBOX
9814## ------------------------------------ ##
9815## Report this to bug-autoconf@gnu.org. ##
9816## ------------------------------------ ##
9817_ASBOX
9818 ) |
9819 sed "s/^/$as_me: WARNING: /" >&2
9820 ;;
c0d27fcc
MR
9821 no:yes )
9822 { echo "$as_me:$LINENO: WARNING: gif_lib.h: present but cannot be compiled" >&5
9823echo "$as_me: WARNING: gif_lib.h: present but cannot be compiled" >&2;}
9824 { echo "$as_me:$LINENO: WARNING: gif_lib.h: check for missing prerequisite headers?" >&5
9825echo "$as_me: WARNING: gif_lib.h: check for missing prerequisite headers?" >&2;}
9826 { echo "$as_me:$LINENO: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
9827echo "$as_me: WARNING: gif_lib.h: proceeding with the preprocessor's result" >&2;}
9828 (
9829 cat <<\_ASBOX
9830## ------------------------------------ ##
9831## Report this to bug-autoconf@gnu.org. ##
9832## ------------------------------------ ##
9833_ASBOX
9834 ) |
9835 sed "s/^/$as_me: WARNING: /" >&2
9836 ;;
c0d27fcc
MR
9837esac
9838echo "$as_me:$LINENO: checking for gif_lib.h" >&5
9839echo $ECHO_N "checking for gif_lib.h... $ECHO_C" >&6
9840if test "${ac_cv_header_gif_lib_h+set}" = set; then
9841 echo $ECHO_N "(cached) $ECHO_C" >&6
9842else
9843 ac_cv_header_gif_lib_h=$ac_header_preproc
98418dba 9844fi
c0d27fcc 9845echo "$as_me:$LINENO: result: $ac_cv_header_gif_lib_h" >&5
98418dba 9846echo "${ECHO_T}$ac_cv_header_gif_lib_h" >&6
c0d27fcc
MR
9847
9848fi
98418dba
CW
9849if test $ac_cv_header_gif_lib_h = yes; then
9850 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
9851# Earlier versions can crash Emacs.
c0d27fcc 9852 echo "$as_me:$LINENO: checking for EGifPutExtensionLast in -lungif" >&5
98418dba
CW
9853echo $ECHO_N "checking for EGifPutExtensionLast in -lungif... $ECHO_C" >&6
9854if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then
503d2be0 9855 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 9856else
503d2be0 9857 ac_check_lib_save_LIBS=$LIBS
98418dba 9858LIBS="-lungif $LIBS"
503d2be0 9859cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 9860#line $LINENO "configure"
cd958eb3
MB
9861/* confdefs.h. */
9862_ACEOF
9863cat confdefs.h >>conftest.$ac_ext
9864cat >>conftest.$ac_ext <<_ACEOF
9865/* end confdefs.h. */
73b77ee5 9866
98418dba
CW
9867/* Override any gcc2 internal prototype to avoid an error. */
9868#ifdef __cplusplus
9869extern "C"
9870#endif
9871/* We use char because int might match the return type of a gcc2
9872 builtin and then its argument prototype would still apply. */
9873char EGifPutExtensionLast ();
503d2be0
AS
9874int
9875main ()
9876{
98418dba 9877EGifPutExtensionLast ();
503d2be0
AS
9878 ;
9879 return 0;
9880}
9881_ACEOF
9882rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 9883if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
9884 (eval $ac_link) 2>&5
9885 ac_status=$?
c0d27fcc 9886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9887 (exit $ac_status); } &&
9888 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 9889 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
9890 (eval $ac_try) 2>&5
9891 ac_status=$?
c0d27fcc 9892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
9893 (exit $ac_status); }; }; then
9894 ac_cv_lib_ungif_EGifPutExtensionLast=yes
9895else
9896 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9897sed 's/^/| /' conftest.$ac_ext >&5
9898
98418dba
CW
9899ac_cv_lib_ungif_EGifPutExtensionLast=no
9900fi
9901rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9902LIBS=$ac_check_lib_save_LIBS
9903fi
c0d27fcc 9904echo "$as_me:$LINENO: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
98418dba
CW
9905echo "${ECHO_T}$ac_cv_lib_ungif_EGifPutExtensionLast" >&6
9906if test $ac_cv_lib_ungif_EGifPutExtensionLast = yes; then
9907 HAVE_GIF=yes
9908fi
9909
9910fi
9911
c0d27fcc 9912
98418dba
CW
9913 fi
9914
9915 if test "${HAVE_GIF}" = "yes"; then
b936fae4 9916
c0d27fcc 9917cat >>confdefs.h <<\_ACEOF
98418dba 9918#define HAVE_GIF 1
c0d27fcc 9919_ACEOF
98418dba
CW
9920
9921 fi
9922fi
9923
c0d27fcc
MR
9924### Use Mac OS X Carbon API to implement GUI.
9925HAVE_CARBON=no
9926if test "${with_carbon}" != "no"; then
9927 if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9928 echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
9929echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
9930if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
9931 echo $ECHO_N "(cached) $ECHO_C" >&6
9932fi
9933echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
9934echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
9935else
9936 # Is the header compilable?
9937echo "$as_me:$LINENO: checking Carbon/Carbon.h usability" >&5
9938echo $ECHO_N "checking Carbon/Carbon.h usability... $ECHO_C" >&6
9939cat >conftest.$ac_ext <<_ACEOF
9940#line $LINENO "configure"
cd958eb3
MB
9941/* confdefs.h. */
9942_ACEOF
9943cat confdefs.h >>conftest.$ac_ext
9944cat >>conftest.$ac_ext <<_ACEOF
9945/* end confdefs.h. */
c0d27fcc
MR
9946$ac_includes_default
9947#include <Carbon/Carbon.h>
9948_ACEOF
9949rm -f conftest.$ac_objext
9950if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9951 (eval $ac_compile) 2>&5
9952 ac_status=$?
9953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9954 (exit $ac_status); } &&
9955 { ac_try='test -s conftest.$ac_objext'
9956 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9957 (eval $ac_try) 2>&5
9958 ac_status=$?
9959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9960 (exit $ac_status); }; }; then
9961 ac_header_compiler=yes
9962else
9963 echo "$as_me: failed program was:" >&5
cd958eb3
MB
9964sed 's/^/| /' conftest.$ac_ext >&5
9965
c0d27fcc
MR
9966ac_header_compiler=no
9967fi
9968rm -f conftest.$ac_objext conftest.$ac_ext
9969echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9970echo "${ECHO_T}$ac_header_compiler" >&6
9971
9972# Is the header present?
9973echo "$as_me:$LINENO: checking Carbon/Carbon.h presence" >&5
9974echo $ECHO_N "checking Carbon/Carbon.h presence... $ECHO_C" >&6
9975cat >conftest.$ac_ext <<_ACEOF
9976#line $LINENO "configure"
cd958eb3
MB
9977/* confdefs.h. */
9978_ACEOF
9979cat confdefs.h >>conftest.$ac_ext
9980cat >>conftest.$ac_ext <<_ACEOF
9981/* end confdefs.h. */
e0f712ba
AC
9982#include <Carbon/Carbon.h>
9983_ACEOF
c0d27fcc 9984if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
e0f712ba
AC
9985 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9986 ac_status=$?
6bae0ccf 9987 grep -v '^ *+' conftest.er1 >conftest.err
e0f712ba
AC
9988 rm -f conftest.er1
9989 cat conftest.err >&5
c0d27fcc 9990 echo "$as_me:$LINENO: \$? = $ac_status" >&5
e0f712ba
AC
9991 (exit $ac_status); } >/dev/null; then
9992 if test -s conftest.err; then
9993 ac_cpp_err=$ac_c_preproc_warn_flag
9994 else
9995 ac_cpp_err=
9996 fi
9997else
9998 ac_cpp_err=yes
9999fi
10000if test -z "$ac_cpp_err"; then
c0d27fcc 10001 ac_header_preproc=yes
e0f712ba
AC
10002else
10003 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10004sed 's/^/| /' conftest.$ac_ext >&5
10005
c0d27fcc 10006 ac_header_preproc=no
e0f712ba
AC
10007fi
10008rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10009echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10010echo "${ECHO_T}$ac_header_preproc" >&6
10011
10012# So? What about this header?
10013case $ac_header_compiler:$ac_header_preproc in
10014 yes:no )
10015 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&5
10016echo "$as_me: WARNING: Carbon/Carbon.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10017 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10018echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
10019 (
10020 cat <<\_ASBOX
10021## ------------------------------------ ##
10022## Report this to bug-autoconf@gnu.org. ##
10023## ------------------------------------ ##
10024_ASBOX
10025 ) |
10026 sed "s/^/$as_me: WARNING: /" >&2
10027 ;;
c0d27fcc
MR
10028 no:yes )
10029 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&5
10030echo "$as_me: WARNING: Carbon/Carbon.h: present but cannot be compiled" >&2;}
10031 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&5
10032echo "$as_me: WARNING: Carbon/Carbon.h: check for missing prerequisite headers?" >&2;}
10033 { echo "$as_me:$LINENO: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10034echo "$as_me: WARNING: Carbon/Carbon.h: proceeding with the preprocessor's result" >&2;}
10035 (
10036 cat <<\_ASBOX
10037## ------------------------------------ ##
10038## Report this to bug-autoconf@gnu.org. ##
10039## ------------------------------------ ##
10040_ASBOX
10041 ) |
10042 sed "s/^/$as_me: WARNING: /" >&2
10043 ;;
c0d27fcc
MR
10044esac
10045echo "$as_me:$LINENO: checking for Carbon/Carbon.h" >&5
10046echo $ECHO_N "checking for Carbon/Carbon.h... $ECHO_C" >&6
10047if test "${ac_cv_header_Carbon_Carbon_h+set}" = set; then
10048 echo $ECHO_N "(cached) $ECHO_C" >&6
10049else
10050 ac_cv_header_Carbon_Carbon_h=$ac_header_preproc
e0f712ba 10051fi
c0d27fcc 10052echo "$as_me:$LINENO: result: $ac_cv_header_Carbon_Carbon_h" >&5
e0f712ba 10053echo "${ECHO_T}$ac_cv_header_Carbon_Carbon_h" >&6
c0d27fcc
MR
10054
10055fi
e0f712ba
AC
10056if test $ac_cv_header_Carbon_Carbon_h = yes; then
10057 HAVE_CARBON=yes
10058fi
10059
c0d27fcc 10060
e0f712ba
AC
10061fi
10062
10063if test "${HAVE_CARBON}" = "yes"; then
e3ba1015 10064
c0d27fcc 10065cat >>confdefs.h <<\_ACEOF
e0f712ba 10066#define HAVE_CARBON 1
c0d27fcc 10067_ACEOF
e0f712ba 10068
6a3a24fa
JD
10069 window_system=mac
10070 ## Specify the install directory
10071 carbon_appdir=
10072 if test "${carbon_appdir_x}" != ""; then
10073 case ${carbon_appdir_x} in
10074 y | ye | yes) carbon_appdir=/Applications ;;
10075 * ) carbon_appdir=${carbon_appdir_x} ;;
10076 esac
10077 fi
8f417b3b
AS
10078 # We also have mouse menus.
10079 HAVE_MENUS=yes
e0f712ba
AC
10080fi
10081
98418dba
CW
10082### Use session management (-lSM -lICE) if available
10083HAVE_X_SM=no
10084if test "${HAVE_X11}" = "yes"; then
c0d27fcc
MR
10085 if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10086 echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
98418dba
CW
10087echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
10088if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10089 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
10090fi
10091echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
10092echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
503d2be0 10093else
c0d27fcc
MR
10094 # Is the header compilable?
10095echo "$as_me:$LINENO: checking X11/SM/SMlib.h usability" >&5
10096echo $ECHO_N "checking X11/SM/SMlib.h usability... $ECHO_C" >&6
10097cat >conftest.$ac_ext <<_ACEOF
10098#line $LINENO "configure"
cd958eb3
MB
10099/* confdefs.h. */
10100_ACEOF
10101cat confdefs.h >>conftest.$ac_ext
10102cat >>conftest.$ac_ext <<_ACEOF
10103/* end confdefs.h. */
c0d27fcc
MR
10104$ac_includes_default
10105#include <X11/SM/SMlib.h>
10106_ACEOF
10107rm -f conftest.$ac_objext
10108if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10109 (eval $ac_compile) 2>&5
10110 ac_status=$?
10111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10112 (exit $ac_status); } &&
10113 { ac_try='test -s conftest.$ac_objext'
10114 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10115 (eval $ac_try) 2>&5
10116 ac_status=$?
10117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10118 (exit $ac_status); }; }; then
10119 ac_header_compiler=yes
10120else
10121 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10122sed 's/^/| /' conftest.$ac_ext >&5
10123
c0d27fcc
MR
10124ac_header_compiler=no
10125fi
10126rm -f conftest.$ac_objext conftest.$ac_ext
10127echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10128echo "${ECHO_T}$ac_header_compiler" >&6
10129
10130# Is the header present?
10131echo "$as_me:$LINENO: checking X11/SM/SMlib.h presence" >&5
10132echo $ECHO_N "checking X11/SM/SMlib.h presence... $ECHO_C" >&6
10133cat >conftest.$ac_ext <<_ACEOF
10134#line $LINENO "configure"
cd958eb3
MB
10135/* confdefs.h. */
10136_ACEOF
10137cat confdefs.h >>conftest.$ac_ext
10138cat >>conftest.$ac_ext <<_ACEOF
10139/* end confdefs.h. */
98418dba
CW
10140#include <X11/SM/SMlib.h>
10141_ACEOF
c0d27fcc 10142if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
10143 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10144 ac_status=$?
6bae0ccf 10145 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
10146 rm -f conftest.er1
10147 cat conftest.err >&5
c0d27fcc 10148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
10149 (exit $ac_status); } >/dev/null; then
10150 if test -s conftest.err; then
10151 ac_cpp_err=$ac_c_preproc_warn_flag
10152 else
10153 ac_cpp_err=
10154 fi
10155else
10156 ac_cpp_err=yes
503d2be0 10157fi
98418dba 10158if test -z "$ac_cpp_err"; then
c0d27fcc 10159 ac_header_preproc=yes
98418dba
CW
10160else
10161 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10162sed 's/^/| /' conftest.$ac_ext >&5
10163
c0d27fcc 10164 ac_header_preproc=no
98418dba
CW
10165fi
10166rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
10167echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10168echo "${ECHO_T}$ac_header_preproc" >&6
10169
10170# So? What about this header?
10171case $ac_header_compiler:$ac_header_preproc in
10172 yes:no )
10173 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
10174echo "$as_me: WARNING: X11/SM/SMlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10175 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10176echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
10177 (
10178 cat <<\_ASBOX
10179## ------------------------------------ ##
10180## Report this to bug-autoconf@gnu.org. ##
10181## ------------------------------------ ##
10182_ASBOX
10183 ) |
10184 sed "s/^/$as_me: WARNING: /" >&2
10185 ;;
c0d27fcc
MR
10186 no:yes )
10187 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&5
10188echo "$as_me: WARNING: X11/SM/SMlib.h: present but cannot be compiled" >&2;}
10189 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&5
10190echo "$as_me: WARNING: X11/SM/SMlib.h: check for missing prerequisite headers?" >&2;}
10191 { echo "$as_me:$LINENO: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
10192echo "$as_me: WARNING: X11/SM/SMlib.h: proceeding with the preprocessor's result" >&2;}
10193 (
10194 cat <<\_ASBOX
10195## ------------------------------------ ##
10196## Report this to bug-autoconf@gnu.org. ##
10197## ------------------------------------ ##
10198_ASBOX
10199 ) |
10200 sed "s/^/$as_me: WARNING: /" >&2
10201 ;;
c0d27fcc
MR
10202esac
10203echo "$as_me:$LINENO: checking for X11/SM/SMlib.h" >&5
10204echo $ECHO_N "checking for X11/SM/SMlib.h... $ECHO_C" >&6
10205if test "${ac_cv_header_X11_SM_SMlib_h+set}" = set; then
10206 echo $ECHO_N "(cached) $ECHO_C" >&6
10207else
10208 ac_cv_header_X11_SM_SMlib_h=$ac_header_preproc
73b77ee5 10209fi
c0d27fcc 10210echo "$as_me:$LINENO: result: $ac_cv_header_X11_SM_SMlib_h" >&5
98418dba 10211echo "${ECHO_T}$ac_cv_header_X11_SM_SMlib_h" >&6
c0d27fcc
MR
10212
10213fi
98418dba 10214if test $ac_cv_header_X11_SM_SMlib_h = yes; then
c0d27fcc 10215 echo "$as_me:$LINENO: checking for SmcOpenConnection in -lSM" >&5
98418dba
CW
10216echo $ECHO_N "checking for SmcOpenConnection in -lSM... $ECHO_C" >&6
10217if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then
503d2be0 10218 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 10219else
503d2be0 10220 ac_check_lib_save_LIBS=$LIBS
98418dba 10221LIBS="-lSM $LIBS"
503d2be0 10222cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10223#line $LINENO "configure"
cd958eb3
MB
10224/* confdefs.h. */
10225_ACEOF
10226cat confdefs.h >>conftest.$ac_ext
10227cat >>conftest.$ac_ext <<_ACEOF
10228/* end confdefs.h. */
503d2be0 10229
73b77ee5 10230/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10231#ifdef __cplusplus
10232extern "C"
10233#endif
73b77ee5 10234/* We use char because int might match the return type of a gcc2
503d2be0 10235 builtin and then its argument prototype would still apply. */
98418dba 10236char SmcOpenConnection ();
503d2be0
AS
10237int
10238main ()
10239{
98418dba 10240SmcOpenConnection ();
503d2be0
AS
10241 ;
10242 return 0;
10243}
10244_ACEOF
10245rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10246if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10247 (eval $ac_link) 2>&5
10248 ac_status=$?
c0d27fcc 10249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10250 (exit $ac_status); } &&
10251 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10253 (eval $ac_try) 2>&5
10254 ac_status=$?
c0d27fcc 10255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10256 (exit $ac_status); }; }; then
98418dba 10257 ac_cv_lib_SM_SmcOpenConnection=yes
503d2be0
AS
10258else
10259 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10260sed 's/^/| /' conftest.$ac_ext >&5
10261
98418dba 10262ac_cv_lib_SM_SmcOpenConnection=no
503d2be0
AS
10263fi
10264rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10265LIBS=$ac_check_lib_save_LIBS
10266fi
c0d27fcc 10267echo "$as_me:$LINENO: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
98418dba
CW
10268echo "${ECHO_T}$ac_cv_lib_SM_SmcOpenConnection" >&6
10269if test $ac_cv_lib_SM_SmcOpenConnection = yes; then
10270 HAVE_X_SM=yes
10271else
10272 -lICE
73b77ee5
GM
10273fi
10274
73b77ee5 10275fi
73b77ee5 10276
c0d27fcc
MR
10277
10278
98418dba 10279 if test "${HAVE_X_SM}" = "yes"; then
b936fae4 10280
c0d27fcc 10281cat >>confdefs.h <<\_ACEOF
98418dba 10282#define HAVE_X_SM 1
c0d27fcc 10283_ACEOF
73b77ee5 10284
98418dba
CW
10285 case "$LIBS" in
10286 *-lSM*) ;;
10287 *) LIBS="-lSM -lICE $LIBS" ;;
10288 esac
73b77ee5 10289 fi
98418dba 10290fi
73b77ee5 10291
98418dba 10292# If netdb.h doesn't declare h_errno, we must declare it by hand.
c0d27fcc 10293echo "$as_me:$LINENO: checking whether netdb declares h_errno" >&5
98418dba
CW
10294echo $ECHO_N "checking whether netdb declares h_errno... $ECHO_C" >&6
10295if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then
10296 echo $ECHO_N "(cached) $ECHO_C" >&6
10297else
10298 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10299#line $LINENO "configure"
cd958eb3
MB
10300/* confdefs.h. */
10301_ACEOF
10302cat confdefs.h >>conftest.$ac_ext
10303cat >>conftest.$ac_ext <<_ACEOF
10304/* end confdefs.h. */
98418dba 10305#include <netdb.h>
503d2be0
AS
10306int
10307main ()
10308{
98418dba 10309return h_errno;
503d2be0
AS
10310 ;
10311 return 0;
10312}
10313_ACEOF
10314rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10315if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10316 (eval $ac_link) 2>&5
10317 ac_status=$?
c0d27fcc 10318 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10319 (exit $ac_status); } &&
10320 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10321 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10322 (eval $ac_try) 2>&5
10323 ac_status=$?
c0d27fcc 10324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10325 (exit $ac_status); }; }; then
98418dba 10326 emacs_cv_netdb_declares_h_errno=yes
73b77ee5 10327else
503d2be0 10328 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10329sed 's/^/| /' conftest.$ac_ext >&5
10330
98418dba 10331emacs_cv_netdb_declares_h_errno=no
73b77ee5 10332fi
503d2be0 10333rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10334fi
c0d27fcc 10335echo "$as_me:$LINENO: result: $emacs_cv_netdb_declares_h_errno" >&5
98418dba
CW
10336echo "${ECHO_T}$emacs_cv_netdb_declares_h_errno" >&6
10337if test $emacs_cv_netdb_declares_h_errno = yes; then
b936fae4 10338
c0d27fcc 10339cat >>confdefs.h <<\_ACEOF
98418dba 10340#define HAVE_H_ERRNO 1
c0d27fcc 10341_ACEOF
73b77ee5 10342
98418dba
CW
10343fi
10344
10345# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
10346# for constant arguments. Useless!
c0d27fcc 10347echo "$as_me:$LINENO: checking for working alloca.h" >&5
98418dba
CW
10348echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6
10349if test "${ac_cv_working_alloca_h+set}" = set; then
10350 echo $ECHO_N "(cached) $ECHO_C" >&6
10351else
10352 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10353#line $LINENO "configure"
cd958eb3
MB
10354/* confdefs.h. */
10355_ACEOF
10356cat confdefs.h >>conftest.$ac_ext
10357cat >>conftest.$ac_ext <<_ACEOF
10358/* end confdefs.h. */
98418dba 10359#include <alloca.h>
503d2be0
AS
10360int
10361main ()
10362{
98418dba 10363char *p = (char *) alloca (2 * sizeof (int));
503d2be0
AS
10364 ;
10365 return 0;
10366}
10367_ACEOF
10368rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10369if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10370 (eval $ac_link) 2>&5
10371 ac_status=$?
c0d27fcc 10372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10373 (exit $ac_status); } &&
10374 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10375 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10376 (eval $ac_try) 2>&5
10377 ac_status=$?
c0d27fcc 10378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10379 (exit $ac_status); }; }; then
98418dba 10380 ac_cv_working_alloca_h=yes
73b77ee5 10381else
503d2be0 10382 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10383sed 's/^/| /' conftest.$ac_ext >&5
10384
98418dba 10385ac_cv_working_alloca_h=no
73b77ee5 10386fi
503d2be0 10387rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10388fi
c0d27fcc 10389echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5
98418dba
CW
10390echo "${ECHO_T}$ac_cv_working_alloca_h" >&6
10391if test $ac_cv_working_alloca_h = yes; then
73b77ee5 10392
c0d27fcc 10393cat >>confdefs.h <<\_ACEOF
98418dba 10394#define HAVE_ALLOCA_H 1
c0d27fcc 10395_ACEOF
98418dba
CW
10396
10397fi
10398
c0d27fcc 10399echo "$as_me:$LINENO: checking for alloca" >&5
98418dba
CW
10400echo $ECHO_N "checking for alloca... $ECHO_C" >&6
10401if test "${ac_cv_func_alloca_works+set}" = set; then
10402 echo $ECHO_N "(cached) $ECHO_C" >&6
10403else
503d2be0 10404 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10405#line $LINENO "configure"
cd958eb3
MB
10406/* confdefs.h. */
10407_ACEOF
10408cat confdefs.h >>conftest.$ac_ext
10409cat >>conftest.$ac_ext <<_ACEOF
10410/* end confdefs.h. */
98418dba
CW
10411#ifdef __GNUC__
10412# define alloca __builtin_alloca
10413#else
10414# ifdef _MSC_VER
10415# include <malloc.h>
10416# define alloca _alloca
10417# else
10418# if HAVE_ALLOCA_H
10419# include <alloca.h>
10420# else
10421# ifdef _AIX
10422 #pragma alloca
10423# else
10424# ifndef alloca /* predefined by HP cc +Olibcalls */
10425char *alloca ();
10426# endif
10427# endif
10428# endif
10429# endif
10430#endif
10431
503d2be0
AS
10432int
10433main ()
10434{
98418dba 10435char *p = (char *) alloca (1);
503d2be0
AS
10436 ;
10437 return 0;
10438}
10439_ACEOF
10440rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10441if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10442 (eval $ac_link) 2>&5
10443 ac_status=$?
c0d27fcc 10444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10445 (exit $ac_status); } &&
10446 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10447 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10448 (eval $ac_try) 2>&5
10449 ac_status=$?
c0d27fcc 10450 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10451 (exit $ac_status); }; }; then
98418dba 10452 ac_cv_func_alloca_works=yes
ac95a621 10453else
503d2be0 10454 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10455sed 's/^/| /' conftest.$ac_ext >&5
10456
98418dba 10457ac_cv_func_alloca_works=no
ac95a621 10458fi
503d2be0 10459rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10460fi
c0d27fcc 10461echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5
98418dba 10462echo "${ECHO_T}$ac_cv_func_alloca_works" >&6
ac95a621 10463
98418dba
CW
10464if test $ac_cv_func_alloca_works = yes; then
10465
c0d27fcc 10466cat >>confdefs.h <<\_ACEOF
98418dba 10467#define HAVE_ALLOCA 1
c0d27fcc 10468_ACEOF
98418dba
CW
10469
10470else
10471 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
10472# that cause trouble. Some versions do not even contain alloca or
10473# contain a buggy version. If you still want to use their alloca,
10474# use ar to extract alloca.o from them instead of compiling alloca.c.
10475
10476ALLOCA=alloca.$ac_objext
10477
c0d27fcc 10478cat >>confdefs.h <<\_ACEOF
98418dba 10479#define C_ALLOCA 1
c0d27fcc 10480_ACEOF
98418dba 10481
c0d27fcc
MR
10482
10483echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5
98418dba
CW
10484echo $ECHO_N "checking whether \`alloca.c' needs Cray hooks... $ECHO_C" >&6
10485if test "${ac_cv_os_cray+set}" = set; then
10486 echo $ECHO_N "(cached) $ECHO_C" >&6
10487else
10488 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10489#line $LINENO "configure"
cd958eb3
MB
10490/* confdefs.h. */
10491_ACEOF
10492cat confdefs.h >>conftest.$ac_ext
10493cat >>conftest.$ac_ext <<_ACEOF
10494/* end confdefs.h. */
98418dba
CW
10495#if defined(CRAY) && ! defined(CRAY2)
10496webecray
10497#else
10498wenotbecray
10499#endif
10500
10501_ACEOF
10502if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 10503 $EGREP "webecray" >/dev/null 2>&1; then
98418dba
CW
10504 ac_cv_os_cray=yes
10505else
10506 ac_cv_os_cray=no
10507fi
10508rm -f conftest*
ac95a621 10509
98418dba 10510fi
c0d27fcc 10511echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
98418dba
CW
10512echo "${ECHO_T}$ac_cv_os_cray" >&6
10513if test $ac_cv_os_cray = yes; then
10514 for ac_func in _getb67 GETB67 getb67; do
10515 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 10516echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
10517echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10518if eval "test \"\${$as_ac_var+set}\" = set"; then
10519 echo $ECHO_N "(cached) $ECHO_C" >&6
73b77ee5 10520else
503d2be0 10521 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10522#line $LINENO "configure"
cd958eb3
MB
10523/* confdefs.h. */
10524_ACEOF
10525cat confdefs.h >>conftest.$ac_ext
10526cat >>conftest.$ac_ext <<_ACEOF
10527/* end confdefs.h. */
73b77ee5 10528/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
10529 which can conflict with char $ac_func (); below.
10530 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10531 <limits.h> exists even on freestanding compilers. */
10532#ifdef __STDC__
10533# include <limits.h>
10534#else
10535# include <assert.h>
10536#endif
73b77ee5 10537/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10538#ifdef __cplusplus
10539extern "C"
cd958eb3 10540{
503d2be0 10541#endif
73b77ee5 10542/* We use char because int might match the return type of a gcc2
503d2be0
AS
10543 builtin and then its argument prototype would still apply. */
10544char $ac_func ();
73b77ee5
GM
10545/* The GNU C library defines this for functions which it implements
10546 to always fail with ENOSYS. Some functions are actually named
10547 something starting with __ and the normal name is an alias. */
10548#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10549choke me
10550#else
cd958eb3
MB
10551char (*f) () = $ac_func;
10552#endif
10553#ifdef __cplusplus
10554}
73b77ee5
GM
10555#endif
10556
cd958eb3
MB
10557int
10558main ()
10559{
9e71690e 10560return f != $ac_func;
503d2be0
AS
10561 ;
10562 return 0;
10563}
10564_ACEOF
10565rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10566if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10567 (eval $ac_link) 2>&5
10568 ac_status=$?
c0d27fcc 10569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10570 (exit $ac_status); } &&
10571 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10572 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10573 (eval $ac_try) 2>&5
10574 ac_status=$?
c0d27fcc 10575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10576 (exit $ac_status); }; }; then
10577 eval "$as_ac_var=yes"
10578else
10579 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10580sed 's/^/| /' conftest.$ac_ext >&5
10581
503d2be0
AS
10582eval "$as_ac_var=no"
10583fi
10584rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10585fi
c0d27fcc 10586echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
10587echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10588if test `eval echo '${'$as_ac_var'}'` = yes; then
73b77ee5 10589
c0d27fcc 10590cat >>confdefs.h <<_ACEOF
98418dba 10591#define CRAY_STACKSEG_END $ac_func
c0d27fcc 10592_ACEOF
98418dba
CW
10593
10594 break
73b77ee5 10595fi
73b77ee5 10596
98418dba 10597 done
73b77ee5
GM
10598fi
10599
c0d27fcc 10600echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
98418dba
CW
10601echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
10602if test "${ac_cv_c_stack_direction+set}" = set; then
503d2be0 10603 echo $ECHO_N "(cached) $ECHO_C" >&6
98418dba
CW
10604else
10605 if test "$cross_compiling" = yes; then
10606 ac_cv_c_stack_direction=0
73b77ee5 10607else
503d2be0 10608 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10609#line $LINENO "configure"
cd958eb3
MB
10610/* confdefs.h. */
10611_ACEOF
10612cat confdefs.h >>conftest.$ac_ext
10613cat >>conftest.$ac_ext <<_ACEOF
10614/* end confdefs.h. */
503d2be0 10615int
98418dba 10616find_stack_direction ()
503d2be0 10617{
98418dba
CW
10618 static char *addr = 0;
10619 auto char dummy;
10620 if (addr == 0)
10621 {
10622 addr = &dummy;
10623 return find_stack_direction ();
10624 }
73b77ee5 10625 else
98418dba
CW
10626 return (&dummy > addr) ? 1 : -1;
10627}
ba4481b5 10628
503d2be0
AS
10629int
10630main ()
10631{
98418dba 10632 exit (find_stack_direction () < 0);
503d2be0
AS
10633}
10634_ACEOF
98418dba 10635rm -f conftest$ac_exeext
c0d27fcc 10636if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10637 (eval $ac_link) 2>&5
10638 ac_status=$?
c0d27fcc 10639 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 10640 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 10641 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10642 (eval $ac_try) 2>&5
10643 ac_status=$?
c0d27fcc 10644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10645 (exit $ac_status); }; }; then
98418dba 10646 ac_cv_c_stack_direction=1
ba4481b5 10647else
98418dba
CW
10648 echo "$as_me: program exited with status $ac_status" >&5
10649echo "$as_me: failed program was:" >&5
cd958eb3
MB
10650sed 's/^/| /' conftest.$ac_ext >&5
10651
c0d27fcc 10652( exit $ac_status )
98418dba 10653ac_cv_c_stack_direction=-1
ba4481b5 10654fi
6bae0ccf 10655rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 10656fi
98418dba 10657fi
c0d27fcc 10658echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
98418dba
CW
10659echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
10660
c0d27fcc 10661cat >>confdefs.h <<_ACEOF
98418dba 10662#define STACK_DIRECTION $ac_cv_c_stack_direction
c0d27fcc
MR
10663_ACEOF
10664
ba4481b5 10665
ba4481b5
DL
10666fi
10667
c0d27fcc 10668
98418dba
CW
10669# fmod, logb, and frexp are found in -lm on most systems.
10670# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
10671
c0d27fcc 10672echo "$as_me:$LINENO: checking for sqrt in -lm" >&5
98418dba
CW
10673echo $ECHO_N "checking for sqrt in -lm... $ECHO_C" >&6
10674if test "${ac_cv_lib_m_sqrt+set}" = set; then
503d2be0 10675 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10676else
98418dba
CW
10677 ac_check_lib_save_LIBS=$LIBS
10678LIBS="-lm $LIBS"
10679cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10680#line $LINENO "configure"
cd958eb3
MB
10681/* confdefs.h. */
10682_ACEOF
10683cat confdefs.h >>conftest.$ac_ext
10684cat >>conftest.$ac_ext <<_ACEOF
10685/* end confdefs.h. */
ba4481b5 10686
98418dba
CW
10687/* Override any gcc2 internal prototype to avoid an error. */
10688#ifdef __cplusplus
10689extern "C"
10690#endif
10691/* We use char because int might match the return type of a gcc2
10692 builtin and then its argument prototype would still apply. */
10693char sqrt ();
503d2be0
AS
10694int
10695main ()
10696{
98418dba 10697sqrt ();
503d2be0
AS
10698 ;
10699 return 0;
10700}
10701_ACEOF
10702rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10703if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10704 (eval $ac_link) 2>&5
10705 ac_status=$?
c0d27fcc 10706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10707 (exit $ac_status); } &&
10708 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10709 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10710 (eval $ac_try) 2>&5
10711 ac_status=$?
c0d27fcc 10712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10713 (exit $ac_status); }; }; then
98418dba 10714 ac_cv_lib_m_sqrt=yes
ba4481b5 10715else
503d2be0 10716 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10717sed 's/^/| /' conftest.$ac_ext >&5
10718
98418dba 10719ac_cv_lib_m_sqrt=no
ba4481b5 10720fi
503d2be0 10721rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10722LIBS=$ac_check_lib_save_LIBS
ba4481b5 10723fi
c0d27fcc 10724echo "$as_me:$LINENO: result: $ac_cv_lib_m_sqrt" >&5
98418dba
CW
10725echo "${ECHO_T}$ac_cv_lib_m_sqrt" >&6
10726if test $ac_cv_lib_m_sqrt = yes; then
c0d27fcc 10727 cat >>confdefs.h <<_ACEOF
98418dba 10728#define HAVE_LIBM 1
c0d27fcc 10729_ACEOF
98418dba
CW
10730
10731 LIBS="-lm $LIBS"
ba4481b5 10732
ba4481b5
DL
10733fi
10734
c0d27fcc 10735
98418dba
CW
10736# Check for mail-locking functions in a "mail" library
10737
c0d27fcc 10738echo "$as_me:$LINENO: checking for maillock in -lmail" >&5
98418dba
CW
10739echo $ECHO_N "checking for maillock in -lmail... $ECHO_C" >&6
10740if test "${ac_cv_lib_mail_maillock+set}" = set; then
503d2be0 10741 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10742else
98418dba
CW
10743 ac_check_lib_save_LIBS=$LIBS
10744LIBS="-lmail $LIBS"
10745cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10746#line $LINENO "configure"
cd958eb3
MB
10747/* confdefs.h. */
10748_ACEOF
10749cat confdefs.h >>conftest.$ac_ext
10750cat >>conftest.$ac_ext <<_ACEOF
10751/* end confdefs.h. */
98418dba
CW
10752
10753/* Override any gcc2 internal prototype to avoid an error. */
10754#ifdef __cplusplus
10755extern "C"
10756#endif
10757/* We use char because int might match the return type of a gcc2
10758 builtin and then its argument prototype would still apply. */
10759char maillock ();
503d2be0
AS
10760int
10761main ()
10762{
98418dba 10763maillock ();
503d2be0
AS
10764 ;
10765 return 0;
10766}
10767_ACEOF
10768rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10769if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10770 (eval $ac_link) 2>&5
10771 ac_status=$?
c0d27fcc 10772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10773 (exit $ac_status); } &&
10774 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10775 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10776 (eval $ac_try) 2>&5
10777 ac_status=$?
c0d27fcc 10778 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10779 (exit $ac_status); }; }; then
98418dba 10780 ac_cv_lib_mail_maillock=yes
ba4481b5 10781else
503d2be0 10782 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10783sed 's/^/| /' conftest.$ac_ext >&5
10784
98418dba 10785ac_cv_lib_mail_maillock=no
ba4481b5 10786fi
503d2be0 10787rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 10788LIBS=$ac_check_lib_save_LIBS
ba4481b5 10789fi
c0d27fcc 10790echo "$as_me:$LINENO: result: $ac_cv_lib_mail_maillock" >&5
98418dba
CW
10791echo "${ECHO_T}$ac_cv_lib_mail_maillock" >&6
10792if test $ac_cv_lib_mail_maillock = yes; then
c0d27fcc 10793 cat >>confdefs.h <<_ACEOF
98418dba 10794#define HAVE_LIBMAIL 1
c0d27fcc 10795_ACEOF
ba4481b5 10796
98418dba 10797 LIBS="-lmail $LIBS"
ba4481b5 10798
98418dba 10799fi
ba4481b5 10800
c0d27fcc
MR
10801
10802echo "$as_me:$LINENO: checking for maillock in -llockfile" >&5
98418dba
CW
10803echo $ECHO_N "checking for maillock in -llockfile... $ECHO_C" >&6
10804if test "${ac_cv_lib_lockfile_maillock+set}" = set; then
503d2be0 10805 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 10806else
503d2be0 10807 ac_check_lib_save_LIBS=$LIBS
98418dba 10808LIBS="-llockfile $LIBS"
503d2be0 10809cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10810#line $LINENO "configure"
cd958eb3
MB
10811/* confdefs.h. */
10812_ACEOF
10813cat confdefs.h >>conftest.$ac_ext
10814cat >>conftest.$ac_ext <<_ACEOF
10815/* end confdefs.h. */
503d2be0 10816
ba4481b5 10817/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10818#ifdef __cplusplus
10819extern "C"
10820#endif
ba4481b5 10821/* We use char because int might match the return type of a gcc2
503d2be0 10822 builtin and then its argument prototype would still apply. */
98418dba 10823char maillock ();
503d2be0
AS
10824int
10825main ()
10826{
98418dba 10827maillock ();
503d2be0
AS
10828 ;
10829 return 0;
10830}
10831_ACEOF
10832rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10833if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10834 (eval $ac_link) 2>&5
10835 ac_status=$?
c0d27fcc 10836 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10837 (exit $ac_status); } &&
10838 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10839 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10840 (eval $ac_try) 2>&5
10841 ac_status=$?
c0d27fcc 10842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10843 (exit $ac_status); }; }; then
98418dba 10844 ac_cv_lib_lockfile_maillock=yes
503d2be0
AS
10845else
10846 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10847sed 's/^/| /' conftest.$ac_ext >&5
10848
98418dba
CW
10849ac_cv_lib_lockfile_maillock=no
10850fi
10851rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10852LIBS=$ac_check_lib_save_LIBS
10853fi
c0d27fcc 10854echo "$as_me:$LINENO: result: $ac_cv_lib_lockfile_maillock" >&5
98418dba
CW
10855echo "${ECHO_T}$ac_cv_lib_lockfile_maillock" >&6
10856if test $ac_cv_lib_lockfile_maillock = yes; then
c0d27fcc 10857 cat >>confdefs.h <<_ACEOF
98418dba 10858#define HAVE_LIBLOCKFILE 1
c0d27fcc 10859_ACEOF
98418dba
CW
10860
10861 LIBS="-llockfile $LIBS"
10862
10863fi
10864
10865# If we have the shared liblockfile, assume we must use it for mail
10866# locking (e.g. Debian). If we couldn't link against liblockfile
10867# (no liblockfile.a installed), ensure that we don't need to.
10868if test "$ac_cv_lib_lockfile_maillock" = no; then
10869 # Extract the first word of "liblockfile.so", so it can be a program name with args.
10870set dummy liblockfile.so; ac_word=$2
c0d27fcc 10871echo "$as_me:$LINENO: checking for $ac_word" >&5
98418dba
CW
10872echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
10873if test "${ac_cv_prog_liblockfile+set}" = set; then
10874 echo $ECHO_N "(cached) $ECHO_C" >&6
10875else
10876 if test -n "$liblockfile"; then
10877 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
10878else
c0d27fcc 10879as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6bae0ccf
DL
10880as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
10881for as_dir in $as_dummy
c0d27fcc
MR
10882do
10883 IFS=$as_save_IFS
10884 test -z "$as_dir" && as_dir=.
10885 for ac_exec_ext in '' $ac_executable_extensions; do
10886 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10887 ac_cv_prog_liblockfile="yes"
10888 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10889 break 2
10890 fi
10891done
98418dba
CW
10892done
10893
10894 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
503d2be0 10895fi
503d2be0 10896fi
98418dba
CW
10897liblockfile=$ac_cv_prog_liblockfile
10898if test -n "$liblockfile"; then
c0d27fcc 10899 echo "$as_me:$LINENO: result: $liblockfile" >&5
98418dba
CW
10900echo "${ECHO_T}$liblockfile" >&6
10901else
c0d27fcc 10902 echo "$as_me:$LINENO: result: no" >&5
98418dba 10903echo "${ECHO_T}no" >&6
ba4481b5
DL
10904fi
10905
98418dba 10906 if test $ac_cv_prog_liblockfile = yes; then
c0d27fcc 10907 { { echo "$as_me:$LINENO: error: Shared liblockfile found but can't link against it.
98418dba
CW
10908This probably means that movemail could lose mail.
10909There may be a \`development' package to install containing liblockfile." >&5
10910echo "$as_me: error: Shared liblockfile found but can't link against it.
10911This probably means that movemail could lose mail.
10912There may be a \`development' package to install containing liblockfile." >&2;}
10913 { (exit 1); exit 1; }; }
b936fae4 10914 else
c0d27fcc 10915cat >>confdefs.h <<\_ACEOF
98418dba 10916#define LIBMAIL -llockfile
c0d27fcc 10917_ACEOF
457b792c 10918
98418dba
CW
10919 fi
10920 else :
10921fi
503d2be0 10922
98418dba
CW
10923for ac_func in touchlock
10924do
10925as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 10926echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
10927echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10928if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 10929 echo $ECHO_N "(cached) $ECHO_C" >&6
457b792c 10930else
98418dba 10931 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 10932#line $LINENO "configure"
cd958eb3
MB
10933/* confdefs.h. */
10934_ACEOF
10935cat confdefs.h >>conftest.$ac_ext
10936cat >>conftest.$ac_ext <<_ACEOF
10937/* end confdefs.h. */
98418dba 10938/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
10939 which can conflict with char $ac_func (); below.
10940 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10941 <limits.h> exists even on freestanding compilers. */
10942#ifdef __STDC__
10943# include <limits.h>
10944#else
10945# include <assert.h>
10946#endif
457b792c 10947/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
10948#ifdef __cplusplus
10949extern "C"
cd958eb3 10950{
503d2be0 10951#endif
457b792c 10952/* We use char because int might match the return type of a gcc2
503d2be0 10953 builtin and then its argument prototype would still apply. */
98418dba 10954char $ac_func ();
98418dba
CW
10955/* The GNU C library defines this for functions which it implements
10956 to always fail with ENOSYS. Some functions are actually named
10957 something starting with __ and the normal name is an alias. */
10958#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10959choke me
10960#else
cd958eb3 10961char (*f) () = $ac_func;
98418dba 10962#endif
cd958eb3
MB
10963#ifdef __cplusplus
10964}
10965#endif
10966
10967int
10968main ()
10969{
9e71690e 10970return f != $ac_func;
503d2be0
AS
10971 ;
10972 return 0;
10973}
10974_ACEOF
10975rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 10976if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
10977 (eval $ac_link) 2>&5
10978 ac_status=$?
c0d27fcc 10979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
10980 (exit $ac_status); } &&
10981 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 10982 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
10983 (eval $ac_try) 2>&5
10984 ac_status=$?
c0d27fcc 10985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 10986 (exit $ac_status); }; }; then
98418dba 10987 eval "$as_ac_var=yes"
503d2be0
AS
10988else
10989 echo "$as_me: failed program was:" >&5
cd958eb3
MB
10990sed 's/^/| /' conftest.$ac_ext >&5
10991
98418dba 10992eval "$as_ac_var=no"
503d2be0
AS
10993fi
10994rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
503d2be0 10995fi
c0d27fcc 10996echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
10997echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10998if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 10999 cat >>confdefs.h <<_ACEOF
98418dba 11000#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11001_ACEOF
457b792c 11002
457b792c 11003fi
98418dba 11004done
457b792c 11005
c0d27fcc 11006
98418dba
CW
11007for ac_header in maillock.h
11008do
11009as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11010if eval "test \"\${$as_ac_Header+set}\" = set"; then
11011 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
11012echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11013if eval "test \"\${$as_ac_Header+set}\" = set"; then
503d2be0 11014 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11015fi
11016echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11017echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
ba4481b5 11018else
c0d27fcc
MR
11019 # Is the header compilable?
11020echo "$as_me:$LINENO: checking $ac_header usability" >&5
11021echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11022cat >conftest.$ac_ext <<_ACEOF
11023#line $LINENO "configure"
cd958eb3
MB
11024/* confdefs.h. */
11025_ACEOF
11026cat confdefs.h >>conftest.$ac_ext
11027cat >>conftest.$ac_ext <<_ACEOF
11028/* end confdefs.h. */
c0d27fcc
MR
11029$ac_includes_default
11030#include <$ac_header>
11031_ACEOF
11032rm -f conftest.$ac_objext
11033if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11034 (eval $ac_compile) 2>&5
11035 ac_status=$?
11036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11037 (exit $ac_status); } &&
11038 { ac_try='test -s conftest.$ac_objext'
11039 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11040 (eval $ac_try) 2>&5
11041 ac_status=$?
11042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11043 (exit $ac_status); }; }; then
11044 ac_header_compiler=yes
11045else
11046 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11047sed 's/^/| /' conftest.$ac_ext >&5
11048
c0d27fcc
MR
11049ac_header_compiler=no
11050fi
11051rm -f conftest.$ac_objext conftest.$ac_ext
11052echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11053echo "${ECHO_T}$ac_header_compiler" >&6
11054
11055# Is the header present?
11056echo "$as_me:$LINENO: checking $ac_header presence" >&5
11057echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11058cat >conftest.$ac_ext <<_ACEOF
11059#line $LINENO "configure"
cd958eb3
MB
11060/* confdefs.h. */
11061_ACEOF
11062cat confdefs.h >>conftest.$ac_ext
11063cat >>conftest.$ac_ext <<_ACEOF
11064/* end confdefs.h. */
98418dba 11065#include <$ac_header>
503d2be0 11066_ACEOF
c0d27fcc 11067if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 11068 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 11069 ac_status=$?
6bae0ccf 11070 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
11071 rm -f conftest.er1
11072 cat conftest.err >&5
c0d27fcc 11073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
11074 (exit $ac_status); } >/dev/null; then
11075 if test -s conftest.err; then
11076 ac_cpp_err=$ac_c_preproc_warn_flag
11077 else
11078 ac_cpp_err=
11079 fi
503d2be0 11080else
98418dba 11081 ac_cpp_err=yes
503d2be0 11082fi
98418dba 11083if test -z "$ac_cpp_err"; then
c0d27fcc 11084 ac_header_preproc=yes
98418dba
CW
11085else
11086 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11087sed 's/^/| /' conftest.$ac_ext >&5
11088
c0d27fcc 11089 ac_header_preproc=no
503d2be0 11090fi
98418dba 11091rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11092echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11093echo "${ECHO_T}$ac_header_preproc" >&6
11094
11095# So? What about this header?
11096case $ac_header_compiler:$ac_header_preproc in
11097 yes:no )
11098 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11099echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11100 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11101echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11102 (
11103 cat <<\_ASBOX
11104## ------------------------------------ ##
11105## Report this to bug-autoconf@gnu.org. ##
11106## ------------------------------------ ##
11107_ASBOX
11108 ) |
11109 sed "s/^/$as_me: WARNING: /" >&2
11110 ;;
c0d27fcc
MR
11111 no:yes )
11112 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11113echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11114 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11115echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11116 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11117echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11118 (
11119 cat <<\_ASBOX
11120## ------------------------------------ ##
11121## Report this to bug-autoconf@gnu.org. ##
11122## ------------------------------------ ##
11123_ASBOX
11124 ) |
11125 sed "s/^/$as_me: WARNING: /" >&2
11126 ;;
c0d27fcc
MR
11127esac
11128echo "$as_me:$LINENO: checking for $ac_header" >&5
11129echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11130if eval "test \"\${$as_ac_Header+set}\" = set"; then
11131 echo $ECHO_N "(cached) $ECHO_C" >&6
11132else
11133 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 11134fi
c0d27fcc 11135echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 11136echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11137
11138fi
98418dba 11139if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11140 cat >>confdefs.h <<_ACEOF
98418dba 11141#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11142_ACEOF
48d4b120 11143
ba4481b5 11144fi
c0d27fcc 11145
98418dba
CW
11146done
11147
c0d27fcc
MR
11148
11149
11150
11151
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
22044edf
DL
11203
11204
c0d27fcc 11205
cd958eb3 11206
c0d27fcc
MR
11207
11208
98418dba
CW
11209for ac_func in gethostname getdomainname dup2 \
11210rename closedir mkdir rmdir sysinfo \
11211random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime res_init setsid \
11212strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
11213utimes setrlimit setpgid getcwd getwd shutdown strftime getaddrinfo \
11214__fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
11215sendto recvfrom getsockopt setsockopt getsockname getpeername \
cd958eb3 11216gai_strerror mkstemp getline getdelim mremap memmove fsync bzero memset
98418dba
CW
11217do
11218as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11219echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11220echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11221if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11222 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11223else
503d2be0 11224 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11225#line $LINENO "configure"
cd958eb3
MB
11226/* confdefs.h. */
11227_ACEOF
11228cat confdefs.h >>conftest.$ac_ext
11229cat >>conftest.$ac_ext <<_ACEOF
11230/* end confdefs.h. */
98418dba 11231/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11232 which can conflict with char $ac_func (); below.
11233 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11234 <limits.h> exists even on freestanding compilers. */
11235#ifdef __STDC__
11236# include <limits.h>
11237#else
11238# include <assert.h>
11239#endif
ba4481b5 11240/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11241#ifdef __cplusplus
11242extern "C"
cd958eb3 11243{
503d2be0 11244#endif
ba4481b5 11245/* We use char because int might match the return type of a gcc2
503d2be0 11246 builtin and then its argument prototype would still apply. */
98418dba 11247char $ac_func ();
98418dba
CW
11248/* The GNU C library defines this for functions which it implements
11249 to always fail with ENOSYS. Some functions are actually named
11250 something starting with __ and the normal name is an alias. */
11251#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11252choke me
11253#else
cd958eb3
MB
11254char (*f) () = $ac_func;
11255#endif
11256#ifdef __cplusplus
11257}
98418dba
CW
11258#endif
11259
cd958eb3
MB
11260int
11261main ()
11262{
9e71690e 11263return f != $ac_func;
503d2be0
AS
11264 ;
11265 return 0;
11266}
11267_ACEOF
11268rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11269if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11270 (eval $ac_link) 2>&5
11271 ac_status=$?
c0d27fcc 11272 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11273 (exit $ac_status); } &&
11274 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11275 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11276 (eval $ac_try) 2>&5
11277 ac_status=$?
c0d27fcc 11278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11279 (exit $ac_status); }; }; then
98418dba 11280 eval "$as_ac_var=yes"
503d2be0
AS
11281else
11282 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11283sed 's/^/| /' conftest.$ac_ext >&5
11284
98418dba 11285eval "$as_ac_var=no"
503d2be0
AS
11286fi
11287rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 11288fi
c0d27fcc 11289echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
11290echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11291if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 11292 cat >>confdefs.h <<_ACEOF
98418dba 11293#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11294_ACEOF
ba4481b5 11295
ba4481b5 11296fi
98418dba 11297done
ba4481b5 11298
c0d27fcc
MR
11299
11300
98418dba
CW
11301for ac_header in sys/un.h
11302do
11303as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11304if eval "test \"\${$as_ac_Header+set}\" = set"; then
11305 echo "$as_me:$LINENO: checking for $ac_header" >&5
98418dba
CW
11306echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11307if eval "test \"\${$as_ac_Header+set}\" = set"; then
11308 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11309fi
11310echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11311echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 11312else
c0d27fcc
MR
11313 # Is the header compilable?
11314echo "$as_me:$LINENO: checking $ac_header usability" >&5
11315echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11316cat >conftest.$ac_ext <<_ACEOF
11317#line $LINENO "configure"
cd958eb3
MB
11318/* confdefs.h. */
11319_ACEOF
11320cat confdefs.h >>conftest.$ac_ext
11321cat >>conftest.$ac_ext <<_ACEOF
11322/* end confdefs.h. */
c0d27fcc
MR
11323$ac_includes_default
11324#include <$ac_header>
11325_ACEOF
11326rm -f conftest.$ac_objext
11327if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11328 (eval $ac_compile) 2>&5
11329 ac_status=$?
11330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11331 (exit $ac_status); } &&
11332 { ac_try='test -s conftest.$ac_objext'
11333 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11334 (eval $ac_try) 2>&5
11335 ac_status=$?
11336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11337 (exit $ac_status); }; }; then
11338 ac_header_compiler=yes
11339else
11340 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11341sed 's/^/| /' conftest.$ac_ext >&5
11342
c0d27fcc
MR
11343ac_header_compiler=no
11344fi
11345rm -f conftest.$ac_objext conftest.$ac_ext
11346echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11347echo "${ECHO_T}$ac_header_compiler" >&6
11348
11349# Is the header present?
11350echo "$as_me:$LINENO: checking $ac_header presence" >&5
11351echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11352cat >conftest.$ac_ext <<_ACEOF
11353#line $LINENO "configure"
cd958eb3
MB
11354/* confdefs.h. */
11355_ACEOF
11356cat confdefs.h >>conftest.$ac_ext
11357cat >>conftest.$ac_ext <<_ACEOF
11358/* end confdefs.h. */
98418dba 11359#include <$ac_header>
503d2be0 11360_ACEOF
c0d27fcc 11361if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11362 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11363 ac_status=$?
6bae0ccf 11364 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11365 rm -f conftest.er1
11366 cat conftest.err >&5
c0d27fcc 11367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11368 (exit $ac_status); } >/dev/null; then
11369 if test -s conftest.err; then
11370 ac_cpp_err=$ac_c_preproc_warn_flag
11371 else
11372 ac_cpp_err=
11373 fi
11374else
11375 ac_cpp_err=yes
11376fi
11377if test -z "$ac_cpp_err"; then
c0d27fcc 11378 ac_header_preproc=yes
ba4481b5 11379else
503d2be0 11380 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11381sed 's/^/| /' conftest.$ac_ext >&5
11382
c0d27fcc 11383 ac_header_preproc=no
ba4481b5 11384fi
503d2be0 11385rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11386echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11387echo "${ECHO_T}$ac_header_preproc" >&6
11388
11389# So? What about this header?
11390case $ac_header_compiler:$ac_header_preproc in
11391 yes:no )
11392 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11393echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11394 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11395echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11396 (
11397 cat <<\_ASBOX
11398## ------------------------------------ ##
11399## Report this to bug-autoconf@gnu.org. ##
11400## ------------------------------------ ##
11401_ASBOX
11402 ) |
11403 sed "s/^/$as_me: WARNING: /" >&2
11404 ;;
c0d27fcc
MR
11405 no:yes )
11406 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11407echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11408 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11409echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11410 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11411echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11412 (
11413 cat <<\_ASBOX
11414## ------------------------------------ ##
11415## Report this to bug-autoconf@gnu.org. ##
11416## ------------------------------------ ##
11417_ASBOX
11418 ) |
11419 sed "s/^/$as_me: WARNING: /" >&2
11420 ;;
c0d27fcc
MR
11421esac
11422echo "$as_me:$LINENO: checking for $ac_header" >&5
11423echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11424if eval "test \"\${$as_ac_Header+set}\" = set"; then
11425 echo $ECHO_N "(cached) $ECHO_C" >&6
11426else
11427 eval "$as_ac_Header=$ac_header_preproc"
ba4481b5 11428fi
c0d27fcc 11429echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
925c2f3f 11430echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11431
11432fi
925c2f3f 11433if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11434 cat >>confdefs.h <<_ACEOF
925c2f3f 11435#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11436_ACEOF
503d2be0 11437
925c2f3f 11438fi
c0d27fcc 11439
925c2f3f
EZ
11440done
11441
c0d27fcc
MR
11442
11443
11444
925c2f3f
EZ
11445for ac_header in sys/time.h unistd.h
11446do
11447as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
11448if eval "test \"\${$as_ac_Header+set}\" = set"; then
11449 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
11450echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11451if eval "test \"\${$as_ac_Header+set}\" = set"; then
11452 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
11453fi
11454echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
11455echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
925c2f3f 11456else
c0d27fcc
MR
11457 # Is the header compilable?
11458echo "$as_me:$LINENO: checking $ac_header usability" >&5
11459echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
11460cat >conftest.$ac_ext <<_ACEOF
11461#line $LINENO "configure"
cd958eb3
MB
11462/* confdefs.h. */
11463_ACEOF
11464cat confdefs.h >>conftest.$ac_ext
11465cat >>conftest.$ac_ext <<_ACEOF
11466/* end confdefs.h. */
c0d27fcc
MR
11467$ac_includes_default
11468#include <$ac_header>
11469_ACEOF
11470rm -f conftest.$ac_objext
11471if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11472 (eval $ac_compile) 2>&5
11473 ac_status=$?
11474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11475 (exit $ac_status); } &&
11476 { ac_try='test -s conftest.$ac_objext'
11477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11478 (eval $ac_try) 2>&5
11479 ac_status=$?
11480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11481 (exit $ac_status); }; }; then
11482 ac_header_compiler=yes
11483else
11484 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11485sed 's/^/| /' conftest.$ac_ext >&5
11486
c0d27fcc
MR
11487ac_header_compiler=no
11488fi
11489rm -f conftest.$ac_objext conftest.$ac_ext
11490echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11491echo "${ECHO_T}$ac_header_compiler" >&6
11492
11493# Is the header present?
11494echo "$as_me:$LINENO: checking $ac_header presence" >&5
11495echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
11496cat >conftest.$ac_ext <<_ACEOF
11497#line $LINENO "configure"
cd958eb3
MB
11498/* confdefs.h. */
11499_ACEOF
11500cat confdefs.h >>conftest.$ac_ext
11501cat >>conftest.$ac_ext <<_ACEOF
11502/* end confdefs.h. */
98418dba 11503#include <$ac_header>
503d2be0 11504_ACEOF
c0d27fcc 11505if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
11506 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11507 ac_status=$?
6bae0ccf 11508 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
11509 rm -f conftest.er1
11510 cat conftest.err >&5
c0d27fcc 11511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11512 (exit $ac_status); } >/dev/null; then
11513 if test -s conftest.err; then
11514 ac_cpp_err=$ac_c_preproc_warn_flag
11515 else
11516 ac_cpp_err=
11517 fi
11518else
11519 ac_cpp_err=yes
11520fi
11521if test -z "$ac_cpp_err"; then
c0d27fcc 11522 ac_header_preproc=yes
98418dba
CW
11523else
11524 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11525sed 's/^/| /' conftest.$ac_ext >&5
11526
c0d27fcc 11527 ac_header_preproc=no
98418dba
CW
11528fi
11529rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
11530echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11531echo "${ECHO_T}$ac_header_preproc" >&6
11532
11533# So? What about this header?
11534case $ac_header_compiler:$ac_header_preproc in
11535 yes:no )
11536 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11537echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11538 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11539echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11540 (
11541 cat <<\_ASBOX
11542## ------------------------------------ ##
11543## Report this to bug-autoconf@gnu.org. ##
11544## ------------------------------------ ##
11545_ASBOX
11546 ) |
11547 sed "s/^/$as_me: WARNING: /" >&2
11548 ;;
c0d27fcc
MR
11549 no:yes )
11550 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11551echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11552 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
11553echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
11554 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
11555echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11556 (
11557 cat <<\_ASBOX
11558## ------------------------------------ ##
11559## Report this to bug-autoconf@gnu.org. ##
11560## ------------------------------------ ##
11561_ASBOX
11562 ) |
11563 sed "s/^/$as_me: WARNING: /" >&2
11564 ;;
c0d27fcc
MR
11565esac
11566echo "$as_me:$LINENO: checking for $ac_header" >&5
11567echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
11568if eval "test \"\${$as_ac_Header+set}\" = set"; then
11569 echo $ECHO_N "(cached) $ECHO_C" >&6
11570else
11571 eval "$as_ac_Header=$ac_header_preproc"
ffe36136 11572fi
c0d27fcc 11573echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
98418dba 11574echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
11575
11576fi
98418dba 11577if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 11578 cat >>confdefs.h <<_ACEOF
98418dba 11579#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 11580_ACEOF
98418dba
CW
11581
11582fi
c0d27fcc 11583
98418dba
CW
11584done
11585
c0d27fcc 11586
98418dba
CW
11587for ac_func in alarm
11588do
11589as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11590echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11591echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11592if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11593 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11594else
98418dba 11595 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11596#line $LINENO "configure"
cd958eb3
MB
11597/* confdefs.h. */
11598_ACEOF
11599cat confdefs.h >>conftest.$ac_ext
11600cat >>conftest.$ac_ext <<_ACEOF
11601/* end confdefs.h. */
98418dba 11602/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11603 which can conflict with char $ac_func (); below.
11604 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11605 <limits.h> exists even on freestanding compilers. */
11606#ifdef __STDC__
11607# include <limits.h>
11608#else
11609# include <assert.h>
11610#endif
ba4481b5 11611/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11612#ifdef __cplusplus
11613extern "C"
cd958eb3 11614{
503d2be0 11615#endif
ba4481b5 11616/* We use char because int might match the return type of a gcc2
503d2be0 11617 builtin and then its argument prototype would still apply. */
98418dba 11618char $ac_func ();
98418dba
CW
11619/* The GNU C library defines this for functions which it implements
11620 to always fail with ENOSYS. Some functions are actually named
11621 something starting with __ and the normal name is an alias. */
11622#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11623choke me
11624#else
cd958eb3
MB
11625char (*f) () = $ac_func;
11626#endif
11627#ifdef __cplusplus
11628}
98418dba
CW
11629#endif
11630
cd958eb3
MB
11631int
11632main ()
11633{
9e71690e 11634return f != $ac_func;
503d2be0
AS
11635 ;
11636 return 0;
11637}
11638_ACEOF
11639rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11640if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11641 (eval $ac_link) 2>&5
11642 ac_status=$?
c0d27fcc 11643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11644 (exit $ac_status); } &&
11645 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11647 (eval $ac_try) 2>&5
11648 ac_status=$?
c0d27fcc 11649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11650 (exit $ac_status); }; }; then
98418dba 11651 eval "$as_ac_var=yes"
503d2be0
AS
11652else
11653 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11654sed 's/^/| /' conftest.$ac_ext >&5
11655
98418dba 11656eval "$as_ac_var=no"
503d2be0
AS
11657fi
11658rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ffe36136 11659fi
c0d27fcc 11660echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
11661echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11662if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 11663 cat >>confdefs.h <<_ACEOF
98418dba 11664#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 11665_ACEOF
ffe36136 11666
ba4481b5 11667fi
98418dba 11668done
ba4481b5 11669
c0d27fcc 11670echo "$as_me:$LINENO: checking for working mktime" >&5
98418dba
CW
11671echo $ECHO_N "checking for working mktime... $ECHO_C" >&6
11672if test "${ac_cv_func_working_mktime+set}" = set; then
11673 echo $ECHO_N "(cached) $ECHO_C" >&6
11674else
11675 if test "$cross_compiling" = yes; then
11676 ac_cv_func_working_mktime=no
11677else
11678 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11679#line $LINENO "configure"
cd958eb3
MB
11680/* confdefs.h. */
11681_ACEOF
11682cat confdefs.h >>conftest.$ac_ext
11683cat >>conftest.$ac_ext <<_ACEOF
11684/* end confdefs.h. */
98418dba
CW
11685/* Test program from Paul Eggert and Tony Leneis. */
11686#if TIME_WITH_SYS_TIME
11687# include <sys/time.h>
11688# include <time.h>
11689#else
11690# if HAVE_SYS_TIME_H
11691# include <sys/time.h>
11692# else
11693# include <time.h>
11694# endif
11695#endif
ba4481b5 11696
98418dba
CW
11697#if HAVE_UNISTD_H
11698# include <unistd.h>
11699#endif
ba4481b5 11700
98418dba
CW
11701#if !HAVE_ALARM
11702# define alarm(X) /* empty */
11703#endif
df645f7c 11704
98418dba
CW
11705/* Work around redefinition to rpl_putenv by other config tests. */
11706#undef putenv
df645f7c 11707
98418dba 11708static time_t time_t_max;
df645f7c 11709
98418dba
CW
11710/* Values we'll use to set the TZ environment variable. */
11711static const char *const tz_strings[] = {
11712 (const char *) 0, "TZ=GMT0", "TZ=JST-9",
11713 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
11714};
11715#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
503d2be0 11716
98418dba
CW
11717/* Fail if mktime fails to convert a date in the spring-forward gap.
11718 Based on a problem report from Andreas Jaeger. */
11719static void
11720spring_forward_gap ()
11721{
11722 /* glibc (up to about 1998-10-07) failed this test. */
11723 struct tm tm;
11724
11725 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11726 instead of "TZ=America/Vancouver" in order to detect the bug even
11727 on systems that don't support the Olson extension, or don't have the
11728 full zoneinfo tables installed. */
11729 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11730
11731 tm.tm_year = 98;
11732 tm.tm_mon = 3;
11733 tm.tm_mday = 5;
11734 tm.tm_hour = 2;
11735 tm.tm_min = 0;
11736 tm.tm_sec = 0;
11737 tm.tm_isdst = -1;
11738 if (mktime (&tm) == (time_t)-1)
11739 exit (1);
11740}
11741
11742static void
11743mktime_test (now)
11744 time_t now;
11745{
11746 struct tm *lt;
11747 if ((lt = localtime (&now)) && mktime (lt) != now)
11748 exit (1);
11749 now = time_t_max - now;
11750 if ((lt = localtime (&now)) && mktime (lt) != now)
11751 exit (1);
11752}
11753
11754static void
11755irix_6_4_bug ()
11756{
11757 /* Based on code from Ariel Faigon. */
11758 struct tm tm;
11759 tm.tm_year = 96;
11760 tm.tm_mon = 3;
11761 tm.tm_mday = 0;
11762 tm.tm_hour = 0;
11763 tm.tm_min = 0;
11764 tm.tm_sec = 0;
11765 tm.tm_isdst = -1;
11766 mktime (&tm);
11767 if (tm.tm_mon != 2 || tm.tm_mday != 31)
11768 exit (1);
11769}
11770
11771static void
11772bigtime_test (j)
11773 int j;
11774{
11775 struct tm tm;
11776 time_t now;
11777 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
11778 now = mktime (&tm);
11779 if (now != (time_t) -1)
11780 {
11781 struct tm *lt = localtime (&now);
11782 if (! (lt
11783 && lt->tm_year == tm.tm_year
11784 && lt->tm_mon == tm.tm_mon
11785 && lt->tm_mday == tm.tm_mday
11786 && lt->tm_hour == tm.tm_hour
11787 && lt->tm_min == tm.tm_min
11788 && lt->tm_sec == tm.tm_sec
11789 && lt->tm_yday == tm.tm_yday
11790 && lt->tm_wday == tm.tm_wday
11791 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
11792 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
11793 exit (1);
11794 }
11795}
11796
11797int
11798main ()
11799{
11800 time_t t, delta;
11801 int i, j;
11802
11803 /* This test makes some buggy mktime implementations loop.
11804 Give up after 60 seconds; a mktime slower than that
11805 isn't worth using anyway. */
11806 alarm (60);
11807
11808 for (time_t_max = 1; 0 < time_t_max; time_t_max *= 2)
11809 continue;
11810 time_t_max--;
11811 delta = time_t_max / 997; /* a suitable prime number */
11812 for (i = 0; i < N_STRINGS; i++)
11813 {
11814 if (tz_strings[i])
11815 putenv (tz_strings[i]);
503d2be0 11816
98418dba
CW
11817 for (t = 0; t <= time_t_max - delta; t += delta)
11818 mktime_test (t);
11819 mktime_test ((time_t) 60 * 60);
11820 mktime_test ((time_t) 60 * 60 * 24);
11821
11822 for (j = 1; 0 < j; j *= 2)
11823 bigtime_test (j);
11824 bigtime_test (j - 1);
11825 }
11826 irix_6_4_bug ();
11827 spring_forward_gap ();
11828 exit (0);
503d2be0
AS
11829}
11830_ACEOF
98418dba 11831rm -f conftest$ac_exeext
c0d27fcc 11832if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11833 (eval $ac_link) 2>&5
11834 ac_status=$?
c0d27fcc 11835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba 11836 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 11837 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11838 (eval $ac_try) 2>&5
11839 ac_status=$?
c0d27fcc 11840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11841 (exit $ac_status); }; }; then
98418dba 11842 ac_cv_func_working_mktime=yes
503d2be0 11843else
98418dba
CW
11844 echo "$as_me: program exited with status $ac_status" >&5
11845echo "$as_me: failed program was:" >&5
cd958eb3
MB
11846sed 's/^/| /' conftest.$ac_ext >&5
11847
c0d27fcc 11848( exit $ac_status )
98418dba 11849ac_cv_func_working_mktime=no
503d2be0 11850fi
6bae0ccf 11851rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0 11852fi
ba4481b5 11853fi
c0d27fcc 11854echo "$as_me:$LINENO: result: $ac_cv_func_working_mktime" >&5
98418dba
CW
11855echo "${ECHO_T}$ac_cv_func_working_mktime" >&6
11856if test $ac_cv_func_working_mktime = no; then
11857 LIBOBJS="$LIBOBJS mktime.$ac_objext"
ba4481b5
DL
11858fi
11859
98418dba 11860if test "$ac_cv_func_working_mktime" = no; then
b936fae4 11861
c0d27fcc 11862cat >>confdefs.h <<\_ACEOF
98418dba 11863#define BROKEN_MKTIME 1
c0d27fcc 11864_ACEOF
ba4481b5 11865
ba4481b5 11866fi
503d2be0 11867
98418dba
CW
11868ac_have_func=no # yes means we've found a way to get the load average.
11869
6bae0ccf
DL
11870# Make sure getloadavg.c is where it belongs, at configure-time.
11871test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
11872 { { echo "$as_me:$LINENO: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&5
11873echo "$as_me: error: $srcdir/$ac_config_libobj_dir/getloadavg.c is missing" >&2;}
11874 { (exit 1); exit 1; }; }
11875
98418dba
CW
11876ac_save_LIBS=$LIBS
11877
11878# Check for getloadavg, but be sure not to touch the cache variable.
c0d27fcc 11879(echo "$as_me:$LINENO: checking for getloadavg" >&5
98418dba
CW
11880echo $ECHO_N "checking for getloadavg... $ECHO_C" >&6
11881if test "${ac_cv_func_getloadavg+set}" = set; then
503d2be0 11882 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11883else
503d2be0 11884 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11885#line $LINENO "configure"
cd958eb3
MB
11886/* confdefs.h. */
11887_ACEOF
11888cat confdefs.h >>conftest.$ac_ext
11889cat >>conftest.$ac_ext <<_ACEOF
11890/* end confdefs.h. */
98418dba 11891/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11892 which can conflict with char getloadavg (); below.
11893 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11894 <limits.h> exists even on freestanding compilers. */
11895#ifdef __STDC__
11896# include <limits.h>
11897#else
11898# include <assert.h>
11899#endif
ba4481b5 11900/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11901#ifdef __cplusplus
11902extern "C"
cd958eb3 11903{
503d2be0 11904#endif
ba4481b5 11905/* We use char because int might match the return type of a gcc2
503d2be0 11906 builtin and then its argument prototype would still apply. */
98418dba 11907char getloadavg ();
98418dba
CW
11908/* The GNU C library defines this for functions which it implements
11909 to always fail with ENOSYS. Some functions are actually named
11910 something starting with __ and the normal name is an alias. */
11911#if defined (__stub_getloadavg) || defined (__stub___getloadavg)
11912choke me
11913#else
cd958eb3 11914char (*f) () = getloadavg;
98418dba 11915#endif
cd958eb3
MB
11916#ifdef __cplusplus
11917}
11918#endif
11919
11920int
11921main ()
11922{
9e71690e 11923return f != getloadavg;
503d2be0
AS
11924 ;
11925 return 0;
11926}
11927_ACEOF
11928rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 11929if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
11930 (eval $ac_link) 2>&5
11931 ac_status=$?
c0d27fcc 11932 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
11933 (exit $ac_status); } &&
11934 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 11935 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
11936 (eval $ac_try) 2>&5
11937 ac_status=$?
c0d27fcc 11938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 11939 (exit $ac_status); }; }; then
98418dba 11940 ac_cv_func_getloadavg=yes
503d2be0
AS
11941else
11942 echo "$as_me: failed program was:" >&5
cd958eb3
MB
11943sed 's/^/| /' conftest.$ac_ext >&5
11944
98418dba 11945ac_cv_func_getloadavg=no
503d2be0
AS
11946fi
11947rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
ba4481b5 11948fi
c0d27fcc 11949echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg" >&5
98418dba
CW
11950echo "${ECHO_T}$ac_cv_func_getloadavg" >&6
11951if test $ac_cv_func_getloadavg = yes; then
11952 exit 0
11953else
11954 exit 1
ba4481b5 11955fi
98418dba 11956) && ac_have_func=yes
ba4481b5 11957
98418dba 11958# On HPUX9, an unprivileged user can get load averages through this function.
503d2be0 11959
98418dba
CW
11960for ac_func in pstat_getdynamic
11961do
11962as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 11963echo "$as_me:$LINENO: checking for $ac_func" >&5
98418dba
CW
11964echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11965if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 11966 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 11967else
503d2be0 11968 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 11969#line $LINENO "configure"
cd958eb3
MB
11970/* confdefs.h. */
11971_ACEOF
11972cat confdefs.h >>conftest.$ac_ext
11973cat >>conftest.$ac_ext <<_ACEOF
11974/* end confdefs.h. */
98418dba 11975/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
11976 which can conflict with char $ac_func (); below.
11977 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11978 <limits.h> exists even on freestanding compilers. */
11979#ifdef __STDC__
11980# include <limits.h>
11981#else
11982# include <assert.h>
11983#endif
ba4481b5 11984/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
11985#ifdef __cplusplus
11986extern "C"
cd958eb3 11987{
503d2be0 11988#endif
ba4481b5 11989/* We use char because int might match the return type of a gcc2
503d2be0 11990 builtin and then its argument prototype would still apply. */
98418dba 11991char $ac_func ();
98418dba
CW
11992/* The GNU C library defines this for functions which it implements
11993 to always fail with ENOSYS. Some functions are actually named
11994 something starting with __ and the normal name is an alias. */
11995#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11996choke me
11997#else
cd958eb3
MB
11998char (*f) () = $ac_func;
11999#endif
12000#ifdef __cplusplus
12001}
98418dba
CW
12002#endif
12003
cd958eb3
MB
12004int
12005main ()
12006{
9e71690e 12007return f != $ac_func;
98418dba
CW
12008 ;
12009 return 0;
12010}
f21fadcc 12011_ACEOF
98418dba 12012rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12013if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba 12014 (eval $ac_link) 2>&5
f21fadcc 12015 ac_status=$?
c0d27fcc 12016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12017 (exit $ac_status); } &&
12018 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12019 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
12020 (eval $ac_try) 2>&5
12021 ac_status=$?
c0d27fcc 12022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12023 (exit $ac_status); }; }; then
12024 eval "$as_ac_var=yes"
f21fadcc
JD
12025else
12026 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12027sed 's/^/| /' conftest.$ac_ext >&5
12028
98418dba 12029eval "$as_ac_var=no"
f21fadcc 12030fi
98418dba 12031rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
f21fadcc 12032fi
c0d27fcc 12033echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
98418dba
CW
12034echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12035if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12036 cat >>confdefs.h <<_ACEOF
98418dba 12037#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12038_ACEOF
98418dba
CW
12039
12040fi
12041done
12042
c0d27fcc 12043
98418dba
CW
12044# Solaris has libkstat which does not require root.
12045
c0d27fcc 12046echo "$as_me:$LINENO: checking for kstat_open in -lkstat" >&5
98418dba
CW
12047echo $ECHO_N "checking for kstat_open in -lkstat... $ECHO_C" >&6
12048if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then
f21fadcc
JD
12049 echo $ECHO_N "(cached) $ECHO_C" >&6
12050else
12051 ac_check_lib_save_LIBS=$LIBS
98418dba 12052LIBS="-lkstat $LIBS"
f21fadcc 12053cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12054#line $LINENO "configure"
cd958eb3
MB
12055/* confdefs.h. */
12056_ACEOF
12057cat confdefs.h >>conftest.$ac_ext
12058cat >>conftest.$ac_ext <<_ACEOF
12059/* end confdefs.h. */
f21fadcc
JD
12060
12061/* Override any gcc2 internal prototype to avoid an error. */
12062#ifdef __cplusplus
12063extern "C"
12064#endif
12065/* We use char because int might match the return type of a gcc2
12066 builtin and then its argument prototype would still apply. */
98418dba 12067char kstat_open ();
f21fadcc
JD
12068int
12069main ()
12070{
98418dba 12071kstat_open ();
f21fadcc
JD
12072 ;
12073 return 0;
12074}
12075_ACEOF
12076rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12077if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
f21fadcc
JD
12078 (eval $ac_link) 2>&5
12079 ac_status=$?
c0d27fcc 12080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc
JD
12081 (exit $ac_status); } &&
12082 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12083 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
f21fadcc
JD
12084 (eval $ac_try) 2>&5
12085 ac_status=$?
c0d27fcc 12086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f21fadcc 12087 (exit $ac_status); }; }; then
98418dba 12088 ac_cv_lib_kstat_kstat_open=yes
f21fadcc
JD
12089else
12090 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12091sed 's/^/| /' conftest.$ac_ext >&5
12092
98418dba 12093ac_cv_lib_kstat_kstat_open=no
f21fadcc
JD
12094fi
12095rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12096LIBS=$ac_check_lib_save_LIBS
12097fi
c0d27fcc 12098echo "$as_me:$LINENO: result: $ac_cv_lib_kstat_kstat_open" >&5
98418dba
CW
12099echo "${ECHO_T}$ac_cv_lib_kstat_kstat_open" >&6
12100if test $ac_cv_lib_kstat_kstat_open = yes; then
c0d27fcc 12101 cat >>confdefs.h <<_ACEOF
98418dba 12102#define HAVE_LIBKSTAT 1
c0d27fcc 12103_ACEOF
f21fadcc 12104
98418dba 12105 LIBS="-lkstat $LIBS"
f21fadcc 12106
f21fadcc
JD
12107fi
12108
98418dba
CW
12109test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
12110
12111# Some systems with -lutil have (and need) -lkvm as well, some do not.
12112# On Solaris, -lkvm requires nlist from -lelf, so check that first
12113# to get the right answer into the cache.
12114# For kstat on solaris, we need libelf to force the definition of SVR4 below.
12115if test $ac_have_func = no; then
c0d27fcc 12116 echo "$as_me:$LINENO: checking for elf_begin in -lelf" >&5
98418dba
CW
12117echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
12118if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
503d2be0 12119 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12120else
98418dba
CW
12121 ac_check_lib_save_LIBS=$LIBS
12122LIBS="-lelf $LIBS"
12123cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12124#line $LINENO "configure"
cd958eb3
MB
12125/* confdefs.h. */
12126_ACEOF
12127cat confdefs.h >>conftest.$ac_ext
12128cat >>conftest.$ac_ext <<_ACEOF
12129/* end confdefs.h. */
98418dba
CW
12130
12131/* Override any gcc2 internal prototype to avoid an error. */
12132#ifdef __cplusplus
12133extern "C"
12134#endif
12135/* We use char because int might match the return type of a gcc2
12136 builtin and then its argument prototype would still apply. */
12137char elf_begin ();
503d2be0
AS
12138int
12139main ()
12140{
98418dba 12141elf_begin ();
503d2be0
AS
12142 ;
12143 return 0;
12144}
12145_ACEOF
12146rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12147if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12148 (eval $ac_link) 2>&5
12149 ac_status=$?
c0d27fcc 12150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12151 (exit $ac_status); } &&
12152 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12153 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12154 (eval $ac_try) 2>&5
12155 ac_status=$?
c0d27fcc 12156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12157 (exit $ac_status); }; }; then
98418dba 12158 ac_cv_lib_elf_elf_begin=yes
ba4481b5 12159else
503d2be0 12160 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12161sed 's/^/| /' conftest.$ac_ext >&5
12162
98418dba 12163ac_cv_lib_elf_elf_begin=no
ba4481b5 12164fi
503d2be0 12165rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12166LIBS=$ac_check_lib_save_LIBS
ba4481b5 12167fi
c0d27fcc 12168echo "$as_me:$LINENO: result: $ac_cv_lib_elf_elf_begin" >&5
98418dba
CW
12169echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
12170if test $ac_cv_lib_elf_elf_begin = yes; then
12171 LIBS="-lelf $LIBS"
ba4481b5
DL
12172fi
12173
98418dba
CW
12174fi
12175if test $ac_have_func = no; then
c0d27fcc 12176 echo "$as_me:$LINENO: checking for kvm_open in -lkvm" >&5
98418dba
CW
12177echo $ECHO_N "checking for kvm_open in -lkvm... $ECHO_C" >&6
12178if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then
503d2be0 12179 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12180else
98418dba
CW
12181 ac_check_lib_save_LIBS=$LIBS
12182LIBS="-lkvm $LIBS"
12183cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12184#line $LINENO "configure"
cd958eb3
MB
12185/* confdefs.h. */
12186_ACEOF
12187cat confdefs.h >>conftest.$ac_ext
12188cat >>conftest.$ac_ext <<_ACEOF
12189/* end confdefs.h. */
98418dba
CW
12190
12191/* Override any gcc2 internal prototype to avoid an error. */
12192#ifdef __cplusplus
12193extern "C"
12194#endif
12195/* We use char because int might match the return type of a gcc2
12196 builtin and then its argument prototype would still apply. */
12197char kvm_open ();
503d2be0
AS
12198int
12199main ()
12200{
98418dba 12201kvm_open ();
503d2be0
AS
12202 ;
12203 return 0;
12204}
12205_ACEOF
12206rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12207if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12208 (eval $ac_link) 2>&5
12209 ac_status=$?
c0d27fcc 12210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12211 (exit $ac_status); } &&
12212 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12213 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12214 (eval $ac_try) 2>&5
12215 ac_status=$?
c0d27fcc 12216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12217 (exit $ac_status); }; }; then
98418dba 12218 ac_cv_lib_kvm_kvm_open=yes
503d2be0
AS
12219else
12220 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12221sed 's/^/| /' conftest.$ac_ext >&5
12222
98418dba 12223ac_cv_lib_kvm_kvm_open=no
503d2be0
AS
12224fi
12225rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba 12226LIBS=$ac_check_lib_save_LIBS
503d2be0 12227fi
c0d27fcc 12228echo "$as_me:$LINENO: result: $ac_cv_lib_kvm_kvm_open" >&5
98418dba
CW
12229echo "${ECHO_T}$ac_cv_lib_kvm_kvm_open" >&6
12230if test $ac_cv_lib_kvm_kvm_open = yes; then
12231 LIBS="-lkvm $LIBS"
ba4481b5
DL
12232fi
12233
98418dba 12234 # Check for the 4.4BSD definition of getloadavg.
c0d27fcc 12235 echo "$as_me:$LINENO: checking for getloadavg in -lutil" >&5
98418dba
CW
12236echo $ECHO_N "checking for getloadavg in -lutil... $ECHO_C" >&6
12237if test "${ac_cv_lib_util_getloadavg+set}" = set; then
503d2be0 12238 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12239else
98418dba
CW
12240 ac_check_lib_save_LIBS=$LIBS
12241LIBS="-lutil $LIBS"
12242cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12243#line $LINENO "configure"
cd958eb3
MB
12244/* confdefs.h. */
12245_ACEOF
12246cat confdefs.h >>conftest.$ac_ext
12247cat >>conftest.$ac_ext <<_ACEOF
12248/* end confdefs.h. */
98418dba
CW
12249
12250/* Override any gcc2 internal prototype to avoid an error. */
12251#ifdef __cplusplus
12252extern "C"
12253#endif
12254/* We use char because int might match the return type of a gcc2
12255 builtin and then its argument prototype would still apply. */
12256char getloadavg ();
503d2be0
AS
12257int
12258main ()
12259{
98418dba 12260getloadavg ();
503d2be0
AS
12261 ;
12262 return 0;
12263}
12264_ACEOF
12265rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12266if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12267 (eval $ac_link) 2>&5
12268 ac_status=$?
c0d27fcc 12269 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12270 (exit $ac_status); } &&
12271 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12272 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12273 (eval $ac_try) 2>&5
12274 ac_status=$?
c0d27fcc 12275 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12276 (exit $ac_status); }; }; then
98418dba 12277 ac_cv_lib_util_getloadavg=yes
ba4481b5 12278else
503d2be0 12279 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12280sed 's/^/| /' conftest.$ac_ext >&5
12281
98418dba 12282ac_cv_lib_util_getloadavg=no
ba4481b5 12283fi
503d2be0 12284rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
98418dba
CW
12285LIBS=$ac_check_lib_save_LIBS
12286fi
c0d27fcc 12287echo "$as_me:$LINENO: result: $ac_cv_lib_util_getloadavg" >&5
98418dba
CW
12288echo "${ECHO_T}$ac_cv_lib_util_getloadavg" >&6
12289if test $ac_cv_lib_util_getloadavg = yes; then
12290 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
ba4481b5 12291fi
503d2be0 12292
98418dba 12293fi
ba4481b5 12294
98418dba
CW
12295if test $ac_have_func = no; then
12296 # There is a commonly available library for RS/6000 AIX.
12297 # Since it is not a standard part of AIX, it might be installed locally.
12298 ac_getloadavg_LIBS=$LIBS
12299 LIBS="-L/usr/local/lib $LIBS"
c0d27fcc 12300 echo "$as_me:$LINENO: checking for getloadavg in -lgetloadavg" >&5
98418dba
CW
12301echo $ECHO_N "checking for getloadavg in -lgetloadavg... $ECHO_C" >&6
12302if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then
503d2be0 12303 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12304else
98418dba
CW
12305 ac_check_lib_save_LIBS=$LIBS
12306LIBS="-lgetloadavg $LIBS"
12307cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12308#line $LINENO "configure"
cd958eb3
MB
12309/* confdefs.h. */
12310_ACEOF
12311cat confdefs.h >>conftest.$ac_ext
12312cat >>conftest.$ac_ext <<_ACEOF
12313/* end confdefs.h. */
ba4481b5 12314
98418dba
CW
12315/* Override any gcc2 internal prototype to avoid an error. */
12316#ifdef __cplusplus
12317extern "C"
12318#endif
12319/* We use char because int might match the return type of a gcc2
12320 builtin and then its argument prototype would still apply. */
12321char getloadavg ();
98418dba
CW
12322int
12323main ()
12324{
12325getloadavg ();
12326 ;
12327 return 0;
12328}
503d2be0 12329_ACEOF
98418dba 12330rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12331if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
98418dba
CW
12332 (eval $ac_link) 2>&5
12333 ac_status=$?
c0d27fcc 12334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12335 (exit $ac_status); } &&
12336 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
98418dba
CW
12338 (eval $ac_try) 2>&5
12339 ac_status=$?
c0d27fcc 12340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12341 (exit $ac_status); }; }; then
12342 ac_cv_lib_getloadavg_getloadavg=yes
ba4481b5 12343else
98418dba 12344 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12345sed 's/^/| /' conftest.$ac_ext >&5
12346
98418dba
CW
12347ac_cv_lib_getloadavg_getloadavg=no
12348fi
12349rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12350LIBS=$ac_check_lib_save_LIBS
12351fi
c0d27fcc 12352echo "$as_me:$LINENO: result: $ac_cv_lib_getloadavg_getloadavg" >&5
98418dba
CW
12353echo "${ECHO_T}$ac_cv_lib_getloadavg_getloadavg" >&6
12354if test $ac_cv_lib_getloadavg_getloadavg = yes; then
12355 LIBS="-lgetloadavg $LIBS"
12356else
12357 LIBS=$ac_getloadavg_LIBS
ba4481b5 12358fi
ba4481b5
DL
12359
12360fi
98418dba
CW
12361
12362# Make sure it is really in the library, if we think we found it,
12363# otherwise set up the replacement function.
12364
12365for ac_func in getloadavg
12366do
12367as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12368echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12369echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12370if eval "test \"\${$as_ac_var+set}\" = set"; then
12371 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12372else
503d2be0 12373 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12374#line $LINENO "configure"
cd958eb3
MB
12375/* confdefs.h. */
12376_ACEOF
12377cat confdefs.h >>conftest.$ac_ext
12378cat >>conftest.$ac_ext <<_ACEOF
12379/* end confdefs.h. */
ba4481b5 12380/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
12381 which can conflict with char $ac_func (); below.
12382 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12383 <limits.h> exists even on freestanding compilers. */
12384#ifdef __STDC__
12385# include <limits.h>
12386#else
12387# include <assert.h>
12388#endif
ba4481b5 12389/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12390#ifdef __cplusplus
12391extern "C"
cd958eb3 12392{
503d2be0 12393#endif
ba4481b5 12394/* We use char because int might match the return type of a gcc2
503d2be0
AS
12395 builtin and then its argument prototype would still apply. */
12396char $ac_func ();
ba4481b5
DL
12397/* The GNU C library defines this for functions which it implements
12398 to always fail with ENOSYS. Some functions are actually named
12399 something starting with __ and the normal name is an alias. */
12400#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12401choke me
12402#else
cd958eb3 12403char (*f) () = $ac_func;
ba4481b5 12404#endif
cd958eb3
MB
12405#ifdef __cplusplus
12406}
12407#endif
12408
12409int
12410main ()
12411{
9e71690e 12412return f != $ac_func;
503d2be0
AS
12413 ;
12414 return 0;
12415}
12416_ACEOF
12417rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12418if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12419 (eval $ac_link) 2>&5
12420 ac_status=$?
c0d27fcc 12421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12422 (exit $ac_status); } &&
12423 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12424 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12425 (eval $ac_try) 2>&5
12426 ac_status=$?
c0d27fcc 12427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12428 (exit $ac_status); }; }; then
12429 eval "$as_ac_var=yes"
12430else
12431 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12432sed 's/^/| /' conftest.$ac_ext >&5
12433
503d2be0
AS
12434eval "$as_ac_var=no"
12435fi
12436rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12437fi
c0d27fcc 12438echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12439echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12440if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12441 cat >>confdefs.h <<_ACEOF
98418dba 12442#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12443_ACEOF
503d2be0 12444
98418dba
CW
12445else
12446 LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
ba4481b5 12447
c0d27fcc 12448cat >>confdefs.h <<\_ACEOF
98418dba 12449#define C_GETLOADAVG 1
c0d27fcc 12450_ACEOF
ba4481b5 12451
98418dba
CW
12452# Figure out what our getloadavg.c needs.
12453ac_have_func=no
c0d27fcc
MR
12454if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
12455 echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
98418dba
CW
12456echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
12457if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
503d2be0 12458 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12459fi
12460echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
12461echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
ba4481b5 12462else
c0d27fcc
MR
12463 # Is the header compilable?
12464echo "$as_me:$LINENO: checking sys/dg_sys_info.h usability" >&5
12465echo $ECHO_N "checking sys/dg_sys_info.h usability... $ECHO_C" >&6
12466cat >conftest.$ac_ext <<_ACEOF
12467#line $LINENO "configure"
cd958eb3
MB
12468/* confdefs.h. */
12469_ACEOF
12470cat confdefs.h >>conftest.$ac_ext
12471cat >>conftest.$ac_ext <<_ACEOF
12472/* end confdefs.h. */
c0d27fcc
MR
12473$ac_includes_default
12474#include <sys/dg_sys_info.h>
12475_ACEOF
12476rm -f conftest.$ac_objext
12477if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12478 (eval $ac_compile) 2>&5
12479 ac_status=$?
12480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12481 (exit $ac_status); } &&
12482 { ac_try='test -s conftest.$ac_objext'
12483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12484 (eval $ac_try) 2>&5
12485 ac_status=$?
12486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12487 (exit $ac_status); }; }; then
12488 ac_header_compiler=yes
12489else
12490 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12491sed 's/^/| /' conftest.$ac_ext >&5
12492
c0d27fcc
MR
12493ac_header_compiler=no
12494fi
12495rm -f conftest.$ac_objext conftest.$ac_ext
12496echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12497echo "${ECHO_T}$ac_header_compiler" >&6
12498
12499# Is the header present?
12500echo "$as_me:$LINENO: checking sys/dg_sys_info.h presence" >&5
12501echo $ECHO_N "checking sys/dg_sys_info.h presence... $ECHO_C" >&6
12502cat >conftest.$ac_ext <<_ACEOF
12503#line $LINENO "configure"
cd958eb3
MB
12504/* confdefs.h. */
12505_ACEOF
12506cat confdefs.h >>conftest.$ac_ext
12507cat >>conftest.$ac_ext <<_ACEOF
12508/* end confdefs.h. */
98418dba
CW
12509#include <sys/dg_sys_info.h>
12510_ACEOF
c0d27fcc 12511if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
12512 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12513 ac_status=$?
6bae0ccf 12514 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12515 rm -f conftest.er1
12516 cat conftest.err >&5
c0d27fcc 12517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12518 (exit $ac_status); } >/dev/null; then
12519 if test -s conftest.err; then
12520 ac_cpp_err=$ac_c_preproc_warn_flag
12521 else
12522 ac_cpp_err=
12523 fi
12524else
12525 ac_cpp_err=yes
ba4481b5 12526fi
98418dba 12527if test -z "$ac_cpp_err"; then
c0d27fcc 12528 ac_header_preproc=yes
98418dba
CW
12529else
12530 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12531sed 's/^/| /' conftest.$ac_ext >&5
12532
c0d27fcc 12533 ac_header_preproc=no
ba4481b5 12534fi
98418dba 12535rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12536echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12537echo "${ECHO_T}$ac_header_preproc" >&6
12538
12539# So? What about this header?
12540case $ac_header_compiler:$ac_header_preproc in
12541 yes:no )
12542 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&5
12543echo "$as_me: WARNING: sys/dg_sys_info.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12544 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12545echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
12546 (
12547 cat <<\_ASBOX
12548## ------------------------------------ ##
12549## Report this to bug-autoconf@gnu.org. ##
12550## ------------------------------------ ##
12551_ASBOX
12552 ) |
12553 sed "s/^/$as_me: WARNING: /" >&2
12554 ;;
c0d27fcc
MR
12555 no:yes )
12556 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&5
12557echo "$as_me: WARNING: sys/dg_sys_info.h: present but cannot be compiled" >&2;}
12558 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&5
12559echo "$as_me: WARNING: sys/dg_sys_info.h: check for missing prerequisite headers?" >&2;}
12560 { echo "$as_me:$LINENO: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12561echo "$as_me: WARNING: sys/dg_sys_info.h: proceeding with the preprocessor's result" >&2;}
12562 (
12563 cat <<\_ASBOX
12564## ------------------------------------ ##
12565## Report this to bug-autoconf@gnu.org. ##
12566## ------------------------------------ ##
12567_ASBOX
12568 ) |
12569 sed "s/^/$as_me: WARNING: /" >&2
12570 ;;
c0d27fcc
MR
12571esac
12572echo "$as_me:$LINENO: checking for sys/dg_sys_info.h" >&5
12573echo $ECHO_N "checking for sys/dg_sys_info.h... $ECHO_C" >&6
12574if test "${ac_cv_header_sys_dg_sys_info_h+set}" = set; then
12575 echo $ECHO_N "(cached) $ECHO_C" >&6
12576else
12577 ac_cv_header_sys_dg_sys_info_h=$ac_header_preproc
98418dba 12578fi
c0d27fcc 12579echo "$as_me:$LINENO: result: $ac_cv_header_sys_dg_sys_info_h" >&5
98418dba 12580echo "${ECHO_T}$ac_cv_header_sys_dg_sys_info_h" >&6
c0d27fcc
MR
12581
12582fi
98418dba
CW
12583if test $ac_cv_header_sys_dg_sys_info_h = yes; then
12584 ac_have_func=yes
ba4481b5 12585
c0d27fcc 12586cat >>confdefs.h <<\_ACEOF
98418dba 12587#define DGUX 1
c0d27fcc
MR
12588_ACEOF
12589
503d2be0 12590
c0d27fcc 12591echo "$as_me:$LINENO: checking for dg_sys_info in -ldgc" >&5
98418dba
CW
12592echo $ECHO_N "checking for dg_sys_info in -ldgc... $ECHO_C" >&6
12593if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then
503d2be0 12594 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12595else
503d2be0 12596 ac_check_lib_save_LIBS=$LIBS
98418dba 12597LIBS="-ldgc $LIBS"
503d2be0 12598cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12599#line $LINENO "configure"
cd958eb3
MB
12600/* confdefs.h. */
12601_ACEOF
12602cat confdefs.h >>conftest.$ac_ext
12603cat >>conftest.$ac_ext <<_ACEOF
12604/* end confdefs.h. */
503d2be0 12605
ba4481b5 12606/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12607#ifdef __cplusplus
12608extern "C"
12609#endif
ba4481b5 12610/* We use char because int might match the return type of a gcc2
503d2be0 12611 builtin and then its argument prototype would still apply. */
98418dba 12612char dg_sys_info ();
503d2be0
AS
12613int
12614main ()
12615{
98418dba 12616dg_sys_info ();
503d2be0
AS
12617 ;
12618 return 0;
12619}
12620_ACEOF
12621rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12622if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12623 (eval $ac_link) 2>&5
12624 ac_status=$?
c0d27fcc 12625 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12626 (exit $ac_status); } &&
12627 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12628 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12629 (eval $ac_try) 2>&5
12630 ac_status=$?
c0d27fcc 12631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 12632 (exit $ac_status); }; }; then
98418dba 12633 ac_cv_lib_dgc_dg_sys_info=yes
503d2be0
AS
12634else
12635 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12636sed 's/^/| /' conftest.$ac_ext >&5
12637
98418dba 12638ac_cv_lib_dgc_dg_sys_info=no
503d2be0
AS
12639fi
12640rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12641LIBS=$ac_check_lib_save_LIBS
12642fi
c0d27fcc 12643echo "$as_me:$LINENO: result: $ac_cv_lib_dgc_dg_sys_info" >&5
98418dba
CW
12644echo "${ECHO_T}$ac_cv_lib_dgc_dg_sys_info" >&6
12645if test $ac_cv_lib_dgc_dg_sys_info = yes; then
c0d27fcc 12646 cat >>confdefs.h <<_ACEOF
98418dba 12647#define HAVE_LIBDGC 1
c0d27fcc 12648_ACEOF
ba4481b5 12649
98418dba 12650 LIBS="-ldgc $LIBS"
ba4481b5 12651
ba4481b5
DL
12652fi
12653
98418dba 12654fi
503d2be0 12655
c0d27fcc
MR
12656
12657
12658if test "${ac_cv_header_locale_h+set}" = set; then
12659 echo "$as_me:$LINENO: checking for locale.h" >&5
98418dba
CW
12660echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
12661if test "${ac_cv_header_locale_h+set}" = set; then
503d2be0 12662 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12663fi
12664echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
12665echo "${ECHO_T}$ac_cv_header_locale_h" >&6
503d2be0 12666else
c0d27fcc
MR
12667 # Is the header compilable?
12668echo "$as_me:$LINENO: checking locale.h usability" >&5
12669echo $ECHO_N "checking locale.h usability... $ECHO_C" >&6
12670cat >conftest.$ac_ext <<_ACEOF
12671#line $LINENO "configure"
cd958eb3
MB
12672/* confdefs.h. */
12673_ACEOF
12674cat confdefs.h >>conftest.$ac_ext
12675cat >>conftest.$ac_ext <<_ACEOF
12676/* end confdefs.h. */
c0d27fcc
MR
12677$ac_includes_default
12678#include <locale.h>
12679_ACEOF
12680rm -f conftest.$ac_objext
12681if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12682 (eval $ac_compile) 2>&5
12683 ac_status=$?
12684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12685 (exit $ac_status); } &&
12686 { ac_try='test -s conftest.$ac_objext'
12687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12688 (eval $ac_try) 2>&5
12689 ac_status=$?
12690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12691 (exit $ac_status); }; }; then
12692 ac_header_compiler=yes
12693else
12694 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12695sed 's/^/| /' conftest.$ac_ext >&5
12696
c0d27fcc
MR
12697ac_header_compiler=no
12698fi
12699rm -f conftest.$ac_objext conftest.$ac_ext
12700echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12701echo "${ECHO_T}$ac_header_compiler" >&6
12702
12703# Is the header present?
12704echo "$as_me:$LINENO: checking locale.h presence" >&5
12705echo $ECHO_N "checking locale.h presence... $ECHO_C" >&6
12706cat >conftest.$ac_ext <<_ACEOF
12707#line $LINENO "configure"
cd958eb3
MB
12708/* confdefs.h. */
12709_ACEOF
12710cat confdefs.h >>conftest.$ac_ext
12711cat >>conftest.$ac_ext <<_ACEOF
12712/* end confdefs.h. */
98418dba 12713#include <locale.h>
503d2be0 12714_ACEOF
c0d27fcc 12715if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba 12716 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
503d2be0 12717 ac_status=$?
6bae0ccf 12718 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
12719 rm -f conftest.er1
12720 cat conftest.err >&5
c0d27fcc 12721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
12722 (exit $ac_status); } >/dev/null; then
12723 if test -s conftest.err; then
12724 ac_cpp_err=$ac_c_preproc_warn_flag
12725 else
12726 ac_cpp_err=
12727 fi
503d2be0 12728else
98418dba 12729 ac_cpp_err=yes
503d2be0 12730fi
98418dba 12731if test -z "$ac_cpp_err"; then
c0d27fcc 12732 ac_header_preproc=yes
98418dba
CW
12733else
12734 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12735sed 's/^/| /' conftest.$ac_ext >&5
12736
c0d27fcc 12737 ac_header_preproc=no
ba4481b5 12738fi
98418dba 12739rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12740echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12741echo "${ECHO_T}$ac_header_preproc" >&6
12742
12743# So? What about this header?
12744case $ac_header_compiler:$ac_header_preproc in
12745 yes:no )
12746 { echo "$as_me:$LINENO: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&5
12747echo "$as_me: WARNING: locale.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12748 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12749echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
12750 (
12751 cat <<\_ASBOX
12752## ------------------------------------ ##
12753## Report this to bug-autoconf@gnu.org. ##
12754## ------------------------------------ ##
12755_ASBOX
12756 ) |
12757 sed "s/^/$as_me: WARNING: /" >&2
12758 ;;
c0d27fcc
MR
12759 no:yes )
12760 { echo "$as_me:$LINENO: WARNING: locale.h: present but cannot be compiled" >&5
12761echo "$as_me: WARNING: locale.h: present but cannot be compiled" >&2;}
12762 { echo "$as_me:$LINENO: WARNING: locale.h: check for missing prerequisite headers?" >&5
12763echo "$as_me: WARNING: locale.h: check for missing prerequisite headers?" >&2;}
12764 { echo "$as_me:$LINENO: WARNING: locale.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12765echo "$as_me: WARNING: locale.h: proceeding with the preprocessor's result" >&2;}
12766 (
12767 cat <<\_ASBOX
12768## ------------------------------------ ##
12769## Report this to bug-autoconf@gnu.org. ##
12770## ------------------------------------ ##
12771_ASBOX
12772 ) |
12773 sed "s/^/$as_me: WARNING: /" >&2
12774 ;;
c0d27fcc
MR
12775esac
12776echo "$as_me:$LINENO: checking for locale.h" >&5
12777echo $ECHO_N "checking for locale.h... $ECHO_C" >&6
12778if test "${ac_cv_header_locale_h+set}" = set; then
12779 echo $ECHO_N "(cached) $ECHO_C" >&6
12780else
12781 ac_cv_header_locale_h=$ac_header_preproc
ba4481b5 12782fi
c0d27fcc 12783echo "$as_me:$LINENO: result: $ac_cv_header_locale_h" >&5
98418dba
CW
12784echo "${ECHO_T}$ac_cv_header_locale_h" >&6
12785
c0d27fcc
MR
12786fi
12787
12788
12789
98418dba 12790for ac_func in setlocale
ba4481b5 12791do
503d2be0 12792as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 12793echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
12794echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12795if eval "test \"\${$as_ac_var+set}\" = set"; then
12796 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 12797else
503d2be0 12798 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 12799#line $LINENO "configure"
cd958eb3
MB
12800/* confdefs.h. */
12801_ACEOF
12802cat confdefs.h >>conftest.$ac_ext
12803cat >>conftest.$ac_ext <<_ACEOF
12804/* end confdefs.h. */
ba4481b5 12805/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
12806 which can conflict with char $ac_func (); below.
12807 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12808 <limits.h> exists even on freestanding compilers. */
12809#ifdef __STDC__
12810# include <limits.h>
12811#else
12812# include <assert.h>
12813#endif
ba4481b5 12814/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
12815#ifdef __cplusplus
12816extern "C"
cd958eb3 12817{
503d2be0 12818#endif
ba4481b5 12819/* We use char because int might match the return type of a gcc2
503d2be0
AS
12820 builtin and then its argument prototype would still apply. */
12821char $ac_func ();
ba4481b5
DL
12822/* The GNU C library defines this for functions which it implements
12823 to always fail with ENOSYS. Some functions are actually named
12824 something starting with __ and the normal name is an alias. */
12825#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12826choke me
12827#else
cd958eb3
MB
12828char (*f) () = $ac_func;
12829#endif
12830#ifdef __cplusplus
12831}
ba4481b5
DL
12832#endif
12833
cd958eb3
MB
12834int
12835main ()
12836{
9e71690e 12837return f != $ac_func;
503d2be0
AS
12838 ;
12839 return 0;
12840}
12841_ACEOF
12842rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 12843if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
12844 (eval $ac_link) 2>&5
12845 ac_status=$?
c0d27fcc 12846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12847 (exit $ac_status); } &&
12848 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 12849 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
12850 (eval $ac_try) 2>&5
12851 ac_status=$?
c0d27fcc 12852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12853 (exit $ac_status); }; }; then
12854 eval "$as_ac_var=yes"
12855else
12856 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12857sed 's/^/| /' conftest.$ac_ext >&5
12858
503d2be0
AS
12859eval "$as_ac_var=no"
12860fi
12861rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12862fi
c0d27fcc 12863echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
12864echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12865if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 12866 cat >>confdefs.h <<_ACEOF
503d2be0 12867#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 12868_ACEOF
ba4481b5 12869
ba4481b5
DL
12870fi
12871done
12872
c0d27fcc 12873
98418dba
CW
12874# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
12875# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
12876# Irix 4.0.5F has the header but not the library.
12877if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
12878 ac_have_func=yes
12879
c0d27fcc 12880cat >>confdefs.h <<\_ACEOF
98418dba 12881#define SVR4 1
c0d27fcc 12882_ACEOF
98418dba
CW
12883
12884fi
12885
12886if test $ac_have_func = no; then
c0d27fcc
MR
12887 if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
12888 echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
98418dba
CW
12889echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
12890if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
503d2be0 12891 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
12892fi
12893echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
12894echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
98418dba 12895else
c0d27fcc
MR
12896 # Is the header compilable?
12897echo "$as_me:$LINENO: checking inq_stats/cpustats.h usability" >&5
12898echo $ECHO_N "checking inq_stats/cpustats.h usability... $ECHO_C" >&6
12899cat >conftest.$ac_ext <<_ACEOF
12900#line $LINENO "configure"
cd958eb3
MB
12901/* confdefs.h. */
12902_ACEOF
12903cat confdefs.h >>conftest.$ac_ext
12904cat >>conftest.$ac_ext <<_ACEOF
12905/* end confdefs.h. */
c0d27fcc
MR
12906$ac_includes_default
12907#include <inq_stats/cpustats.h>
12908_ACEOF
12909rm -f conftest.$ac_objext
12910if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12911 (eval $ac_compile) 2>&5
12912 ac_status=$?
12913 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12914 (exit $ac_status); } &&
12915 { ac_try='test -s conftest.$ac_objext'
12916 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12917 (eval $ac_try) 2>&5
12918 ac_status=$?
12919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12920 (exit $ac_status); }; }; then
12921 ac_header_compiler=yes
12922else
12923 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12924sed 's/^/| /' conftest.$ac_ext >&5
12925
c0d27fcc
MR
12926ac_header_compiler=no
12927fi
12928rm -f conftest.$ac_objext conftest.$ac_ext
12929echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12930echo "${ECHO_T}$ac_header_compiler" >&6
12931
12932# Is the header present?
12933echo "$as_me:$LINENO: checking inq_stats/cpustats.h presence" >&5
12934echo $ECHO_N "checking inq_stats/cpustats.h presence... $ECHO_C" >&6
12935cat >conftest.$ac_ext <<_ACEOF
12936#line $LINENO "configure"
cd958eb3
MB
12937/* confdefs.h. */
12938_ACEOF
12939cat confdefs.h >>conftest.$ac_ext
12940cat >>conftest.$ac_ext <<_ACEOF
12941/* end confdefs.h. */
98418dba 12942#include <inq_stats/cpustats.h>
503d2be0 12943_ACEOF
c0d27fcc 12944if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
12945 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12946 ac_status=$?
6bae0ccf 12947 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
12948 rm -f conftest.er1
12949 cat conftest.err >&5
c0d27fcc 12950 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
12951 (exit $ac_status); } >/dev/null; then
12952 if test -s conftest.err; then
12953 ac_cpp_err=$ac_c_preproc_warn_flag
12954 else
12955 ac_cpp_err=
12956 fi
12957else
12958 ac_cpp_err=yes
12959fi
12960if test -z "$ac_cpp_err"; then
c0d27fcc 12961 ac_header_preproc=yes
503d2be0
AS
12962else
12963 echo "$as_me: failed program was:" >&5
cd958eb3
MB
12964sed 's/^/| /' conftest.$ac_ext >&5
12965
c0d27fcc 12966 ac_header_preproc=no
ba4481b5 12967fi
503d2be0 12968rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
12969echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12970echo "${ECHO_T}$ac_header_preproc" >&6
12971
12972# So? What about this header?
12973case $ac_header_compiler:$ac_header_preproc in
12974 yes:no )
12975 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
12976echo "$as_me: WARNING: inq_stats/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12977 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12978echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
12979 (
12980 cat <<\_ASBOX
12981## ------------------------------------ ##
12982## Report this to bug-autoconf@gnu.org. ##
12983## ------------------------------------ ##
12984_ASBOX
12985 ) |
12986 sed "s/^/$as_me: WARNING: /" >&2
12987 ;;
c0d27fcc
MR
12988 no:yes )
12989 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&5
12990echo "$as_me: WARNING: inq_stats/cpustats.h: present but cannot be compiled" >&2;}
12991 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&5
12992echo "$as_me: WARNING: inq_stats/cpustats.h: check for missing prerequisite headers?" >&2;}
12993 { echo "$as_me:$LINENO: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
12994echo "$as_me: WARNING: inq_stats/cpustats.h: proceeding with the preprocessor's result" >&2;}
12995 (
12996 cat <<\_ASBOX
12997## ------------------------------------ ##
12998## Report this to bug-autoconf@gnu.org. ##
12999## ------------------------------------ ##
13000_ASBOX
13001 ) |
13002 sed "s/^/$as_me: WARNING: /" >&2
13003 ;;
c0d27fcc
MR
13004esac
13005echo "$as_me:$LINENO: checking for inq_stats/cpustats.h" >&5
13006echo $ECHO_N "checking for inq_stats/cpustats.h... $ECHO_C" >&6
13007if test "${ac_cv_header_inq_stats_cpustats_h+set}" = set; then
13008 echo $ECHO_N "(cached) $ECHO_C" >&6
13009else
13010 ac_cv_header_inq_stats_cpustats_h=$ac_header_preproc
ba4481b5 13011fi
c0d27fcc 13012echo "$as_me:$LINENO: result: $ac_cv_header_inq_stats_cpustats_h" >&5
98418dba 13013echo "${ECHO_T}$ac_cv_header_inq_stats_cpustats_h" >&6
c0d27fcc
MR
13014
13015fi
98418dba
CW
13016if test $ac_cv_header_inq_stats_cpustats_h = yes; then
13017 ac_have_func=yes
ba4481b5 13018
c0d27fcc 13019cat >>confdefs.h <<\_ACEOF
98418dba 13020#define UMAX 1
c0d27fcc 13021_ACEOF
98418dba 13022
c0d27fcc
MR
13023
13024cat >>confdefs.h <<\_ACEOF
98418dba 13025#define UMAX4_3 1
c0d27fcc 13026_ACEOF
98418dba
CW
13027
13028fi
13029
c0d27fcc 13030
98418dba
CW
13031fi
13032
13033if test $ac_have_func = no; then
c0d27fcc
MR
13034 if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
13035 echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
98418dba
CW
13036echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
13037if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
503d2be0 13038 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13039fi
13040echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
13041echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
503d2be0 13042else
c0d27fcc
MR
13043 # Is the header compilable?
13044echo "$as_me:$LINENO: checking sys/cpustats.h usability" >&5
13045echo $ECHO_N "checking sys/cpustats.h usability... $ECHO_C" >&6
13046cat >conftest.$ac_ext <<_ACEOF
13047#line $LINENO "configure"
cd958eb3
MB
13048/* confdefs.h. */
13049_ACEOF
13050cat confdefs.h >>conftest.$ac_ext
13051cat >>conftest.$ac_ext <<_ACEOF
13052/* end confdefs.h. */
c0d27fcc
MR
13053$ac_includes_default
13054#include <sys/cpustats.h>
13055_ACEOF
13056rm -f conftest.$ac_objext
13057if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13058 (eval $ac_compile) 2>&5
13059 ac_status=$?
13060 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13061 (exit $ac_status); } &&
13062 { ac_try='test -s conftest.$ac_objext'
13063 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13064 (eval $ac_try) 2>&5
13065 ac_status=$?
13066 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13067 (exit $ac_status); }; }; then
13068 ac_header_compiler=yes
13069else
13070 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13071sed 's/^/| /' conftest.$ac_ext >&5
13072
c0d27fcc
MR
13073ac_header_compiler=no
13074fi
13075rm -f conftest.$ac_objext conftest.$ac_ext
13076echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13077echo "${ECHO_T}$ac_header_compiler" >&6
13078
13079# Is the header present?
13080echo "$as_me:$LINENO: checking sys/cpustats.h presence" >&5
13081echo $ECHO_N "checking sys/cpustats.h presence... $ECHO_C" >&6
13082cat >conftest.$ac_ext <<_ACEOF
13083#line $LINENO "configure"
cd958eb3
MB
13084/* confdefs.h. */
13085_ACEOF
13086cat confdefs.h >>conftest.$ac_ext
13087cat >>conftest.$ac_ext <<_ACEOF
13088/* end confdefs.h. */
98418dba
CW
13089#include <sys/cpustats.h>
13090_ACEOF
c0d27fcc 13091if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
98418dba
CW
13092 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13093 ac_status=$?
6bae0ccf 13094 grep -v '^ *+' conftest.er1 >conftest.err
98418dba
CW
13095 rm -f conftest.er1
13096 cat conftest.err >&5
c0d27fcc 13097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
98418dba
CW
13098 (exit $ac_status); } >/dev/null; then
13099 if test -s conftest.err; then
13100 ac_cpp_err=$ac_c_preproc_warn_flag
13101 else
13102 ac_cpp_err=
13103 fi
13104else
13105 ac_cpp_err=yes
503d2be0 13106fi
98418dba 13107if test -z "$ac_cpp_err"; then
c0d27fcc 13108 ac_header_preproc=yes
98418dba
CW
13109else
13110 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13111sed 's/^/| /' conftest.$ac_ext >&5
13112
c0d27fcc 13113 ac_header_preproc=no
98418dba
CW
13114fi
13115rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13116echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13117echo "${ECHO_T}$ac_header_preproc" >&6
13118
13119# So? What about this header?
13120case $ac_header_compiler:$ac_header_preproc in
13121 yes:no )
13122 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&5
13123echo "$as_me: WARNING: sys/cpustats.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13124 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13125echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
13126 (
13127 cat <<\_ASBOX
13128## ------------------------------------ ##
13129## Report this to bug-autoconf@gnu.org. ##
13130## ------------------------------------ ##
13131_ASBOX
13132 ) |
13133 sed "s/^/$as_me: WARNING: /" >&2
13134 ;;
c0d27fcc
MR
13135 no:yes )
13136 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: present but cannot be compiled" >&5
13137echo "$as_me: WARNING: sys/cpustats.h: present but cannot be compiled" >&2;}
13138 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&5
13139echo "$as_me: WARNING: sys/cpustats.h: check for missing prerequisite headers?" >&2;}
13140 { echo "$as_me:$LINENO: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13141echo "$as_me: WARNING: sys/cpustats.h: proceeding with the preprocessor's result" >&2;}
13142 (
13143 cat <<\_ASBOX
13144## ------------------------------------ ##
13145## Report this to bug-autoconf@gnu.org. ##
13146## ------------------------------------ ##
13147_ASBOX
13148 ) |
13149 sed "s/^/$as_me: WARNING: /" >&2
13150 ;;
c0d27fcc
MR
13151esac
13152echo "$as_me:$LINENO: checking for sys/cpustats.h" >&5
13153echo $ECHO_N "checking for sys/cpustats.h... $ECHO_C" >&6
13154if test "${ac_cv_header_sys_cpustats_h+set}" = set; then
13155 echo $ECHO_N "(cached) $ECHO_C" >&6
13156else
13157 ac_cv_header_sys_cpustats_h=$ac_header_preproc
98418dba 13158fi
c0d27fcc 13159echo "$as_me:$LINENO: result: $ac_cv_header_sys_cpustats_h" >&5
98418dba 13160echo "${ECHO_T}$ac_cv_header_sys_cpustats_h" >&6
c0d27fcc
MR
13161
13162fi
98418dba 13163if test $ac_cv_header_sys_cpustats_h = yes; then
c0d27fcc 13164 ac_have_func=yes; cat >>confdefs.h <<\_ACEOF
98418dba 13165#define UMAX 1
c0d27fcc 13166_ACEOF
ba4481b5 13167
98418dba
CW
13168fi
13169
c0d27fcc 13170
98418dba
CW
13171fi
13172
13173if test $ac_have_func = no; then
13174
13175for ac_header in mach/mach.h
2c9dccc9
PJ
13176do
13177as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
13178if eval "test \"\${$as_ac_Header+set}\" = set"; then
13179 echo "$as_me:$LINENO: checking for $ac_header" >&5
2c9dccc9
PJ
13180echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13181if eval "test \"\${$as_ac_Header+set}\" = set"; then
13182 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
13183fi
13184echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13185echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 13186else
c0d27fcc
MR
13187 # Is the header compilable?
13188echo "$as_me:$LINENO: checking $ac_header usability" >&5
13189echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13190cat >conftest.$ac_ext <<_ACEOF
13191#line $LINENO "configure"
cd958eb3
MB
13192/* confdefs.h. */
13193_ACEOF
13194cat confdefs.h >>conftest.$ac_ext
13195cat >>conftest.$ac_ext <<_ACEOF
13196/* end confdefs.h. */
c0d27fcc
MR
13197$ac_includes_default
13198#include <$ac_header>
13199_ACEOF
13200rm -f conftest.$ac_objext
13201if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13202 (eval $ac_compile) 2>&5
13203 ac_status=$?
13204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13205 (exit $ac_status); } &&
13206 { ac_try='test -s conftest.$ac_objext'
13207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13208 (eval $ac_try) 2>&5
13209 ac_status=$?
13210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13211 (exit $ac_status); }; }; then
13212 ac_header_compiler=yes
13213else
13214 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13215sed 's/^/| /' conftest.$ac_ext >&5
13216
c0d27fcc
MR
13217ac_header_compiler=no
13218fi
13219rm -f conftest.$ac_objext conftest.$ac_ext
13220echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13221echo "${ECHO_T}$ac_header_compiler" >&6
13222
13223# Is the header present?
13224echo "$as_me:$LINENO: checking $ac_header presence" >&5
13225echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13226cat >conftest.$ac_ext <<_ACEOF
13227#line $LINENO "configure"
cd958eb3
MB
13228/* confdefs.h. */
13229_ACEOF
13230cat confdefs.h >>conftest.$ac_ext
13231cat >>conftest.$ac_ext <<_ACEOF
13232/* end confdefs.h. */
2c9dccc9
PJ
13233#include <$ac_header>
13234_ACEOF
c0d27fcc 13235if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2c9dccc9
PJ
13236 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13237 ac_status=$?
6bae0ccf 13238 grep -v '^ *+' conftest.er1 >conftest.err
2c9dccc9
PJ
13239 rm -f conftest.er1
13240 cat conftest.err >&5
c0d27fcc 13241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2c9dccc9
PJ
13242 (exit $ac_status); } >/dev/null; then
13243 if test -s conftest.err; then
13244 ac_cpp_err=$ac_c_preproc_warn_flag
13245 else
13246 ac_cpp_err=
13247 fi
13248else
13249 ac_cpp_err=yes
13250fi
13251if test -z "$ac_cpp_err"; then
c0d27fcc
MR
13252 ac_header_preproc=yes
13253else
13254 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13255sed 's/^/| /' conftest.$ac_ext >&5
13256
c0d27fcc
MR
13257 ac_header_preproc=no
13258fi
13259rm -f conftest.err conftest.$ac_ext
13260echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13261echo "${ECHO_T}$ac_header_preproc" >&6
13262
13263# So? What about this header?
13264case $ac_header_compiler:$ac_header_preproc in
13265 yes:no )
13266 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13267echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13268 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13269echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13270 (
13271 cat <<\_ASBOX
13272## ------------------------------------ ##
13273## Report this to bug-autoconf@gnu.org. ##
13274## ------------------------------------ ##
13275_ASBOX
13276 ) |
13277 sed "s/^/$as_me: WARNING: /" >&2
13278 ;;
c0d27fcc
MR
13279 no:yes )
13280 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13281echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13282 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13283echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13284 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13285echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13286 (
13287 cat <<\_ASBOX
13288## ------------------------------------ ##
13289## Report this to bug-autoconf@gnu.org. ##
13290## ------------------------------------ ##
13291_ASBOX
13292 ) |
13293 sed "s/^/$as_me: WARNING: /" >&2
13294 ;;
c0d27fcc
MR
13295esac
13296echo "$as_me:$LINENO: checking for $ac_header" >&5
13297echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13298if eval "test \"\${$as_ac_Header+set}\" = set"; then
13299 echo $ECHO_N "(cached) $ECHO_C" >&6
13300else
13301 eval "$as_ac_Header=$ac_header_preproc"
13302fi
13303echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13304echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13305
13306fi
13307if test `eval echo '${'$as_ac_Header'}'` = yes; then
13308 cat >>confdefs.h <<_ACEOF
13309#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13310_ACEOF
13311
13312fi
13313
13314done
13315
13316fi
13317
13318
13319for ac_header in nlist.h
13320do
13321as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13322if eval "test \"\${$as_ac_Header+set}\" = set"; then
13323 echo "$as_me:$LINENO: checking for $ac_header" >&5
13324echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13325if eval "test \"\${$as_ac_Header+set}\" = set"; then
13326 echo $ECHO_N "(cached) $ECHO_C" >&6
13327fi
13328echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
13329echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
13330else
13331 # Is the header compilable?
13332echo "$as_me:$LINENO: checking $ac_header usability" >&5
13333echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
13334cat >conftest.$ac_ext <<_ACEOF
13335#line $LINENO "configure"
cd958eb3
MB
13336/* confdefs.h. */
13337_ACEOF
13338cat confdefs.h >>conftest.$ac_ext
13339cat >>conftest.$ac_ext <<_ACEOF
13340/* end confdefs.h. */
c0d27fcc
MR
13341$ac_includes_default
13342#include <$ac_header>
13343_ACEOF
13344rm -f conftest.$ac_objext
13345if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13346 (eval $ac_compile) 2>&5
13347 ac_status=$?
13348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13349 (exit $ac_status); } &&
13350 { ac_try='test -s conftest.$ac_objext'
13351 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13352 (eval $ac_try) 2>&5
13353 ac_status=$?
13354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13355 (exit $ac_status); }; }; then
13356 ac_header_compiler=yes
2c9dccc9
PJ
13357else
13358 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13359sed 's/^/| /' conftest.$ac_ext >&5
13360
c0d27fcc 13361ac_header_compiler=no
98418dba 13362fi
c0d27fcc
MR
13363rm -f conftest.$ac_objext conftest.$ac_ext
13364echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13365echo "${ECHO_T}$ac_header_compiler" >&6
98418dba 13366
c0d27fcc
MR
13367# Is the header present?
13368echo "$as_me:$LINENO: checking $ac_header presence" >&5
13369echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
13370cat >conftest.$ac_ext <<_ACEOF
13371#line $LINENO "configure"
cd958eb3
MB
13372/* confdefs.h. */
13373_ACEOF
13374cat confdefs.h >>conftest.$ac_ext
13375cat >>conftest.$ac_ext <<_ACEOF
13376/* end confdefs.h. */
503d2be0
AS
13377#include <$ac_header>
13378_ACEOF
c0d27fcc 13379if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
13380 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13381 ac_status=$?
6bae0ccf 13382 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
13383 rm -f conftest.er1
13384 cat conftest.err >&5
c0d27fcc 13385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13386 (exit $ac_status); } >/dev/null; then
13387 if test -s conftest.err; then
13388 ac_cpp_err=$ac_c_preproc_warn_flag
13389 else
13390 ac_cpp_err=
13391 fi
13392else
13393 ac_cpp_err=yes
13394fi
13395if test -z "$ac_cpp_err"; then
c0d27fcc 13396 ac_header_preproc=yes
503d2be0
AS
13397else
13398 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13399sed 's/^/| /' conftest.$ac_ext >&5
13400
c0d27fcc 13401 ac_header_preproc=no
b5de8dc0 13402fi
503d2be0 13403rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
13404echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13405echo "${ECHO_T}$ac_header_preproc" >&6
13406
13407# So? What about this header?
13408case $ac_header_compiler:$ac_header_preproc in
13409 yes:no )
13410 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13411echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13412 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13413echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13414 (
13415 cat <<\_ASBOX
13416## ------------------------------------ ##
13417## Report this to bug-autoconf@gnu.org. ##
13418## ------------------------------------ ##
13419_ASBOX
13420 ) |
13421 sed "s/^/$as_me: WARNING: /" >&2
13422 ;;
c0d27fcc
MR
13423 no:yes )
13424 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13425echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13426 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
13427echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
13428 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
13429echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13430 (
13431 cat <<\_ASBOX
13432## ------------------------------------ ##
13433## Report this to bug-autoconf@gnu.org. ##
13434## ------------------------------------ ##
13435_ASBOX
13436 ) |
13437 sed "s/^/$as_me: WARNING: /" >&2
13438 ;;
c0d27fcc
MR
13439esac
13440echo "$as_me:$LINENO: checking for $ac_header" >&5
13441echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13442if eval "test \"\${$as_ac_Header+set}\" = set"; then
13443 echo $ECHO_N "(cached) $ECHO_C" >&6
13444else
13445 eval "$as_ac_Header=$ac_header_preproc"
b5de8dc0 13446fi
c0d27fcc 13447echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 13448echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
13449
13450fi
98418dba 13451if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 13452 cat >>confdefs.h <<_ACEOF
98418dba 13453#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc
MR
13454_ACEOF
13455 echo "$as_me:$LINENO: checking for struct nlist.n_un.n_name" >&5
98418dba
CW
13456echo $ECHO_N "checking for struct nlist.n_un.n_name... $ECHO_C" >&6
13457if test "${ac_cv_member_struct_nlist_n_un_n_name+set}" = set; then
503d2be0 13458 echo $ECHO_N "(cached) $ECHO_C" >&6
b5de8dc0 13459else
503d2be0 13460 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13461#line $LINENO "configure"
cd958eb3
MB
13462/* confdefs.h. */
13463_ACEOF
13464cat confdefs.h >>conftest.$ac_ext
13465cat >>conftest.$ac_ext <<_ACEOF
13466/* end confdefs.h. */
98418dba 13467#include <nlist.h>
b5de8dc0 13468
503d2be0
AS
13469int
13470main ()
13471{
98418dba
CW
13472static struct nlist ac_aggr;
13473if (ac_aggr.n_un.n_name)
13474return 0;
503d2be0
AS
13475 ;
13476 return 0;
13477}
13478_ACEOF
98418dba 13479rm -f conftest.$ac_objext
c0d27fcc 13480if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
98418dba 13481 (eval $ac_compile) 2>&5
503d2be0 13482 ac_status=$?
c0d27fcc 13483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13484 (exit $ac_status); } &&
98418dba 13485 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13487 (eval $ac_try) 2>&5
13488 ac_status=$?
c0d27fcc 13489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13490 (exit $ac_status); }; }; then
98418dba 13491 ac_cv_member_struct_nlist_n_un_n_name=yes
503d2be0
AS
13492else
13493 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13494sed 's/^/| /' conftest.$ac_ext >&5
13495
6bae0ccf
DL
13496cat >conftest.$ac_ext <<_ACEOF
13497#line $LINENO "configure"
cd958eb3
MB
13498/* confdefs.h. */
13499_ACEOF
13500cat confdefs.h >>conftest.$ac_ext
13501cat >>conftest.$ac_ext <<_ACEOF
13502/* end confdefs.h. */
6bae0ccf
DL
13503#include <nlist.h>
13504
13505int
13506main ()
13507{
13508static struct nlist ac_aggr;
13509if (sizeof ac_aggr.n_un.n_name)
13510return 0;
13511 ;
13512 return 0;
13513}
13514_ACEOF
13515rm -f conftest.$ac_objext
13516if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13517 (eval $ac_compile) 2>&5
13518 ac_status=$?
13519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13520 (exit $ac_status); } &&
13521 { ac_try='test -s conftest.$ac_objext'
13522 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13523 (eval $ac_try) 2>&5
13524 ac_status=$?
13525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13526 (exit $ac_status); }; }; then
13527 ac_cv_member_struct_nlist_n_un_n_name=yes
13528else
13529 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13530sed 's/^/| /' conftest.$ac_ext >&5
13531
98418dba 13532ac_cv_member_struct_nlist_n_un_n_name=no
503d2be0 13533fi
98418dba 13534rm -f conftest.$ac_objext conftest.$ac_ext
b5de8dc0 13535fi
6bae0ccf
DL
13536rm -f conftest.$ac_objext conftest.$ac_ext
13537fi
c0d27fcc 13538echo "$as_me:$LINENO: result: $ac_cv_member_struct_nlist_n_un_n_name" >&5
98418dba
CW
13539echo "${ECHO_T}$ac_cv_member_struct_nlist_n_un_n_name" >&6
13540if test $ac_cv_member_struct_nlist_n_un_n_name = yes; then
b5de8dc0 13541
c0d27fcc 13542cat >>confdefs.h <<_ACEOF
98418dba 13543#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
c0d27fcc 13544_ACEOF
b5de8dc0 13545
c0d27fcc
MR
13546
13547cat >>confdefs.h <<\_ACEOF
98418dba 13548#define NLIST_NAME_UNION 1
c0d27fcc 13549_ACEOF
b5de8dc0 13550
98418dba 13551fi
b5de8dc0 13552
c0d27fcc 13553
98418dba 13554fi
c0d27fcc 13555
98418dba 13556done
b5de8dc0 13557
98418dba
CW
13558fi
13559done
b5de8dc0 13560
c0d27fcc 13561
98418dba 13562# Some definitions of getloadavg require that the program be installed setgid.
c0d27fcc 13563echo "$as_me:$LINENO: checking whether getloadavg requires setgid" >&5
98418dba
CW
13564echo $ECHO_N "checking whether getloadavg requires setgid... $ECHO_C" >&6
13565if test "${ac_cv_func_getloadavg_setgid+set}" = set; then
13566 echo $ECHO_N "(cached) $ECHO_C" >&6
13567else
13568 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13569#line $LINENO "configure"
cd958eb3
MB
13570/* confdefs.h. */
13571_ACEOF
13572cat confdefs.h >>conftest.$ac_ext
13573cat >>conftest.$ac_ext <<_ACEOF
13574/* end confdefs.h. */
6bae0ccf 13575#include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
98418dba
CW
13576#ifdef LDAV_PRIVILEGED
13577Yowza Am I SETGID yet
13578#endif
13579_ACEOF
13580if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 13581 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then
98418dba
CW
13582 ac_cv_func_getloadavg_setgid=yes
13583else
13584 ac_cv_func_getloadavg_setgid=no
13585fi
13586rm -f conftest*
b5de8dc0 13587
98418dba 13588fi
c0d27fcc 13589echo "$as_me:$LINENO: result: $ac_cv_func_getloadavg_setgid" >&5
98418dba
CW
13590echo "${ECHO_T}$ac_cv_func_getloadavg_setgid" >&6
13591if test $ac_cv_func_getloadavg_setgid = yes; then
13592 NEED_SETGID=true
b5de8dc0 13593
c0d27fcc 13594cat >>confdefs.h <<\_ACEOF
98418dba 13595#define GETLOADAVG_PRIVILEGED 1
c0d27fcc 13596_ACEOF
98418dba 13597
b5de8dc0 13598else
98418dba 13599 NEED_SETGID=false
b5de8dc0 13600fi
98418dba
CW
13601
13602if test $ac_cv_func_getloadavg_setgid = yes; then
c0d27fcc 13603 echo "$as_me:$LINENO: checking group of /dev/kmem" >&5
98418dba
CW
13604echo $ECHO_N "checking group of /dev/kmem... $ECHO_C" >&6
13605if test "${ac_cv_group_kmem+set}" = set; then
13606 echo $ECHO_N "(cached) $ECHO_C" >&6
13607else
13608 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
13609 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
13610 # If we got an error (system does not support symlinks), try without -L.
13611 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
13612 ac_cv_group_kmem=`echo $ac_ls_output \
13613 | sed -ne 's/[ ][ ]*/ /g;
13614 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
13615 / /s/.* //;p;'`
13616
b5de8dc0 13617fi
c0d27fcc 13618echo "$as_me:$LINENO: result: $ac_cv_group_kmem" >&5
98418dba
CW
13619echo "${ECHO_T}$ac_cv_group_kmem" >&6
13620 KMEM_GROUP=$ac_cv_group_kmem
b5de8dc0 13621fi
98418dba
CW
13622if test "x$ac_save_LIBS" = x; then
13623 GETLOADAVG_LIBS=$LIBS
13624else
13625 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$ac_save_LIBS!!"`
b5de8dc0 13626fi
98418dba 13627LIBS=$ac_save_LIBS
b5de8dc0 13628
c0d27fcc
MR
13629
13630
13631echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
b936fae4
AS
13632echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
13633if test "${ac_cv_sys_largefile_source+set}" = set; then
503d2be0 13634 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13635else
b936fae4
AS
13636 while :; do
13637 ac_cv_sys_largefile_source=no
503d2be0 13638 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13639#line $LINENO "configure"
cd958eb3
MB
13640/* confdefs.h. */
13641_ACEOF
13642cat confdefs.h >>conftest.$ac_ext
13643cat >>conftest.$ac_ext <<_ACEOF
13644/* end confdefs.h. */
b936fae4 13645#include <stdio.h>
503d2be0
AS
13646int
13647main ()
13648{
b936fae4
AS
13649return !fseeko;
13650 ;
13651 return 0;
13652}
13653_ACEOF
13654rm -f conftest.$ac_objext
c0d27fcc 13655if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4
AS
13656 (eval $ac_compile) 2>&5
13657 ac_status=$?
c0d27fcc 13658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13659 (exit $ac_status); } &&
13660 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13661 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
13662 (eval $ac_try) 2>&5
13663 ac_status=$?
c0d27fcc 13664 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13665 (exit $ac_status); }; }; then
13666 break
13667else
13668 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13669sed 's/^/| /' conftest.$ac_ext >&5
13670
b936fae4
AS
13671fi
13672rm -f conftest.$ac_objext conftest.$ac_ext
13673 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13674#line $LINENO "configure"
cd958eb3
MB
13675/* confdefs.h. */
13676_ACEOF
13677cat confdefs.h >>conftest.$ac_ext
13678cat >>conftest.$ac_ext <<_ACEOF
13679/* end confdefs.h. */
b936fae4
AS
13680#define _LARGEFILE_SOURCE 1
13681#include <stdio.h>
b936fae4
AS
13682int
13683main ()
13684{
13685return !fseeko;
13686 ;
13687 return 0;
13688}
13689_ACEOF
13690rm -f conftest.$ac_objext
c0d27fcc 13691if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
b936fae4
AS
13692 (eval $ac_compile) 2>&5
13693 ac_status=$?
c0d27fcc 13694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13695 (exit $ac_status); } &&
13696 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 13697 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
b936fae4
AS
13698 (eval $ac_try) 2>&5
13699 ac_status=$?
c0d27fcc 13700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
b936fae4
AS
13701 (exit $ac_status); }; }; then
13702 ac_cv_sys_largefile_source=1; break
13703else
13704 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13705sed 's/^/| /' conftest.$ac_ext >&5
13706
b936fae4
AS
13707fi
13708rm -f conftest.$ac_objext conftest.$ac_ext
13709 break
13710done
13711fi
c0d27fcc 13712echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
b936fae4
AS
13713echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
13714if test "$ac_cv_sys_largefile_source" != no; then
13715
c0d27fcc 13716cat >>confdefs.h <<_ACEOF
b936fae4 13717#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
c0d27fcc 13718_ACEOF
b936fae4
AS
13719
13720fi
13721rm -f conftest*
4c343001 13722
b936fae4
AS
13723# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13724# in glibc 2.1.3, but that breaks too many other things.
13725# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
c0d27fcc 13726echo "$as_me:$LINENO: checking for fseeko" >&5
b936fae4
AS
13727echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
13728if test "${ac_cv_func_fseeko+set}" = set; then
13729 echo $ECHO_N "(cached) $ECHO_C" >&6
13730else
13731 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13732#line $LINENO "configure"
cd958eb3
MB
13733/* confdefs.h. */
13734_ACEOF
13735cat confdefs.h >>conftest.$ac_ext
13736cat >>conftest.$ac_ext <<_ACEOF
13737/* end confdefs.h. */
b936fae4 13738#include <stdio.h>
b936fae4
AS
13739int
13740main ()
13741{
13742return fseeko && fseeko (stdin, 0, 0);
503d2be0
AS
13743 ;
13744 return 0;
13745}
13746_ACEOF
13747rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13748if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13749 (eval $ac_link) 2>&5
13750 ac_status=$?
c0d27fcc 13751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13752 (exit $ac_status); } &&
13753 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13754 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13755 (eval $ac_try) 2>&5
13756 ac_status=$?
c0d27fcc 13757 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 13758 (exit $ac_status); }; }; then
b936fae4 13759 ac_cv_func_fseeko=yes
503d2be0
AS
13760else
13761 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13762sed 's/^/| /' conftest.$ac_ext >&5
13763
b936fae4 13764ac_cv_func_fseeko=no
503d2be0
AS
13765fi
13766rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13767fi
c0d27fcc 13768echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
b936fae4
AS
13769echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13770if test $ac_cv_func_fseeko = yes; then
13771
c0d27fcc 13772cat >>confdefs.h <<\_ACEOF
b936fae4 13773#define HAVE_FSEEKO 1
c0d27fcc 13774_ACEOF
b936fae4 13775
4c343001
DL
13776fi
13777
c0d27fcc 13778
cd958eb3
MB
13779echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
13780echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6
13781if test "${ac_cv_func_getpgrp_void+set}" = set; then
13782 echo $ECHO_N "(cached) $ECHO_C" >&6
13783else
13784 # Use it with a single arg.
13785cat >conftest.$ac_ext <<_ACEOF
13786#line $LINENO "configure"
13787/* confdefs.h. */
13788_ACEOF
13789cat confdefs.h >>conftest.$ac_ext
13790cat >>conftest.$ac_ext <<_ACEOF
13791/* end confdefs.h. */
13792$ac_includes_default
13793int
13794main ()
13795{
13796getpgrp (0);
13797 ;
13798 return 0;
13799}
13800_ACEOF
13801rm -f conftest.$ac_objext
13802if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13803 (eval $ac_compile) 2>&5
13804 ac_status=$?
13805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13806 (exit $ac_status); } &&
13807 { ac_try='test -s conftest.$ac_objext'
13808 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13809 (eval $ac_try) 2>&5
13810 ac_status=$?
13811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13812 (exit $ac_status); }; }; then
13813 ac_cv_func_getpgrp_void=no
13814else
13815 echo "$as_me: failed program was:" >&5
13816sed 's/^/| /' conftest.$ac_ext >&5
13817
13818ac_cv_func_getpgrp_void=yes
13819fi
13820rm -f conftest.$ac_objext conftest.$ac_ext
13821
13822fi
13823echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
13824echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6
13825if test $ac_cv_func_getpgrp_void = yes; then
13826
13827cat >>confdefs.h <<\_ACEOF
13828#define GETPGRP_VOID 1
13829_ACEOF
13830
13831fi
13832
13833
b936fae4
AS
13834# UNIX98 PTYs.
13835
13836for ac_func in grantpt
503d2be0
AS
13837do
13838as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13839echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
13840echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13841if eval "test \"\${$as_ac_var+set}\" = set"; then
13842 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13843else
503d2be0 13844 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13845#line $LINENO "configure"
cd958eb3
MB
13846/* confdefs.h. */
13847_ACEOF
13848cat confdefs.h >>conftest.$ac_ext
13849cat >>conftest.$ac_ext <<_ACEOF
13850/* end confdefs.h. */
503d2be0 13851/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
13852 which can conflict with char $ac_func (); below.
13853 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13854 <limits.h> exists even on freestanding compilers. */
13855#ifdef __STDC__
13856# include <limits.h>
13857#else
13858# include <assert.h>
13859#endif
4c343001 13860/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13861#ifdef __cplusplus
13862extern "C"
cd958eb3 13863{
503d2be0 13864#endif
4c343001 13865/* We use char because int might match the return type of a gcc2
503d2be0
AS
13866 builtin and then its argument prototype would still apply. */
13867char $ac_func ();
503d2be0
AS
13868/* The GNU C library defines this for functions which it implements
13869 to always fail with ENOSYS. Some functions are actually named
13870 something starting with __ and the normal name is an alias. */
13871#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13872choke me
13873#else
cd958eb3
MB
13874char (*f) () = $ac_func;
13875#endif
13876#ifdef __cplusplus
13877}
503d2be0 13878#endif
4c343001 13879
cd958eb3
MB
13880int
13881main ()
13882{
9e71690e 13883return f != $ac_func;
503d2be0
AS
13884 ;
13885 return 0;
13886}
13887_ACEOF
13888rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13889if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13890 (eval $ac_link) 2>&5
13891 ac_status=$?
c0d27fcc 13892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13893 (exit $ac_status); } &&
13894 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13895 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13896 (eval $ac_try) 2>&5
13897 ac_status=$?
c0d27fcc 13898 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13899 (exit $ac_status); }; }; then
13900 eval "$as_ac_var=yes"
13901else
13902 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13903sed 's/^/| /' conftest.$ac_ext >&5
13904
503d2be0
AS
13905eval "$as_ac_var=no"
13906fi
13907rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13908fi
c0d27fcc 13909echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
13910echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13911if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13912 cat >>confdefs.h <<_ACEOF
503d2be0 13913#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 13914_ACEOF
4c343001
DL
13915
13916fi
503d2be0
AS
13917done
13918
c0d27fcc 13919
b936fae4 13920# PTY-related GNU extensions.
4c343001 13921
b936fae4
AS
13922for ac_func in getpt
13923do
13924as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 13925echo "$as_me:$LINENO: checking for $ac_func" >&5
b936fae4
AS
13926echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13927if eval "test \"\${$as_ac_var+set}\" = set"; then
503d2be0 13928 echo $ECHO_N "(cached) $ECHO_C" >&6
4c343001 13929else
b936fae4 13930 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 13931#line $LINENO "configure"
cd958eb3
MB
13932/* confdefs.h. */
13933_ACEOF
13934cat confdefs.h >>conftest.$ac_ext
13935cat >>conftest.$ac_ext <<_ACEOF
13936/* end confdefs.h. */
087121cc 13937/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
13938 which can conflict with char $ac_func (); below.
13939 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13940 <limits.h> exists even on freestanding compilers. */
13941#ifdef __STDC__
13942# include <limits.h>
13943#else
13944# include <assert.h>
13945#endif
087121cc 13946/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
13947#ifdef __cplusplus
13948extern "C"
cd958eb3 13949{
503d2be0 13950#endif
087121cc 13951/* We use char because int might match the return type of a gcc2
503d2be0
AS
13952 builtin and then its argument prototype would still apply. */
13953char $ac_func ();
087121cc
GM
13954/* The GNU C library defines this for functions which it implements
13955 to always fail with ENOSYS. Some functions are actually named
13956 something starting with __ and the normal name is an alias. */
13957#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13958choke me
13959#else
cd958eb3
MB
13960char (*f) () = $ac_func;
13961#endif
13962#ifdef __cplusplus
13963}
087121cc
GM
13964#endif
13965
cd958eb3
MB
13966int
13967main ()
13968{
9e71690e 13969return f != $ac_func;
503d2be0
AS
13970 ;
13971 return 0;
13972}
13973_ACEOF
13974rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 13975if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
13976 (eval $ac_link) 2>&5
13977 ac_status=$?
c0d27fcc 13978 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13979 (exit $ac_status); } &&
13980 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 13981 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
13982 (eval $ac_try) 2>&5
13983 ac_status=$?
c0d27fcc 13984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
13985 (exit $ac_status); }; }; then
13986 eval "$as_ac_var=yes"
13987else
13988 echo "$as_me: failed program was:" >&5
cd958eb3
MB
13989sed 's/^/| /' conftest.$ac_ext >&5
13990
503d2be0
AS
13991eval "$as_ac_var=no"
13992fi
13993rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13994fi
c0d27fcc 13995echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
13996echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13997if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 13998 cat >>confdefs.h <<_ACEOF
503d2be0 13999#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 14000_ACEOF
087121cc 14001
087121cc
GM
14002fi
14003done
14004
c0d27fcc 14005
ba4481b5
DL
14006# Check this now, so that we will NOT find the above functions in ncurses.
14007# That is because we have not set up to link ncurses in lib-src.
14008# It's better to believe a function is not available
14009# than to expect to find it in ncurses.
503d2be0 14010
c0d27fcc 14011echo "$as_me:$LINENO: checking for tparm in -lncurses" >&5
503d2be0
AS
14012echo $ECHO_N "checking for tparm in -lncurses... $ECHO_C" >&6
14013if test "${ac_cv_lib_ncurses_tparm+set}" = set; then
14014 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 14015else
503d2be0 14016 ac_check_lib_save_LIBS=$LIBS
ba4481b5 14017LIBS="-lncurses $LIBS"
503d2be0 14018cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14019#line $LINENO "configure"
cd958eb3
MB
14020/* confdefs.h. */
14021_ACEOF
14022cat confdefs.h >>conftest.$ac_ext
14023cat >>conftest.$ac_ext <<_ACEOF
14024/* end confdefs.h. */
503d2be0 14025
ba4481b5 14026/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14027#ifdef __cplusplus
14028extern "C"
14029#endif
ba4481b5 14030/* We use char because int might match the return type of a gcc2
503d2be0
AS
14031 builtin and then its argument prototype would still apply. */
14032char tparm ();
14033int
14034main ()
14035{
14036tparm ();
14037 ;
14038 return 0;
14039}
14040_ACEOF
14041rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14042if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14043 (eval $ac_link) 2>&5
14044 ac_status=$?
c0d27fcc 14045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14046 (exit $ac_status); } &&
14047 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14048 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14049 (eval $ac_try) 2>&5
14050 ac_status=$?
c0d27fcc 14051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14052 (exit $ac_status); }; }; then
14053 ac_cv_lib_ncurses_tparm=yes
14054else
14055 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14056sed 's/^/| /' conftest.$ac_ext >&5
14057
503d2be0
AS
14058ac_cv_lib_ncurses_tparm=no
14059fi
14060rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14061LIBS=$ac_check_lib_save_LIBS
14062fi
c0d27fcc 14063echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tparm" >&5
503d2be0
AS
14064echo "${ECHO_T}$ac_cv_lib_ncurses_tparm" >&6
14065if test $ac_cv_lib_ncurses_tparm = yes; then
c0d27fcc 14066 cat >>confdefs.h <<_ACEOF
503d2be0 14067#define HAVE_LIBNCURSES 1
c0d27fcc 14068_ACEOF
ba4481b5
DL
14069
14070 LIBS="-lncurses $LIBS"
14071
ba4481b5
DL
14072fi
14073
c0d27fcc 14074
84e70f78
KR
14075# Do we need the Hesiod library to provide the support routines?
14076if test "$with_hesiod" = yes ; then
14077 # Don't set $LIBS here -- see comments above.
14078 resolv=no
c0d27fcc 14079 echo "$as_me:$LINENO: checking for res_send" >&5
84e70f78
KR
14080echo $ECHO_N "checking for res_send... $ECHO_C" >&6
14081if test "${ac_cv_func_res_send+set}" = set; then
14082 echo $ECHO_N "(cached) $ECHO_C" >&6
14083else
14084 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14085#line $LINENO "configure"
cd958eb3
MB
14086/* confdefs.h. */
14087_ACEOF
14088cat confdefs.h >>conftest.$ac_ext
14089cat >>conftest.$ac_ext <<_ACEOF
14090/* end confdefs.h. */
84e70f78 14091/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14092 which can conflict with char res_send (); below.
14093 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14094 <limits.h> exists even on freestanding compilers. */
14095#ifdef __STDC__
14096# include <limits.h>
14097#else
14098# include <assert.h>
14099#endif
84e70f78
KR
14100/* Override any gcc2 internal prototype to avoid an error. */
14101#ifdef __cplusplus
14102extern "C"
cd958eb3 14103{
84e70f78
KR
14104#endif
14105/* We use char because int might match the return type of a gcc2
14106 builtin and then its argument prototype would still apply. */
14107char res_send ();
84e70f78
KR
14108/* The GNU C library defines this for functions which it implements
14109 to always fail with ENOSYS. Some functions are actually named
14110 something starting with __ and the normal name is an alias. */
14111#if defined (__stub_res_send) || defined (__stub___res_send)
14112choke me
14113#else
cd958eb3 14114char (*f) () = res_send;
84e70f78 14115#endif
cd958eb3
MB
14116#ifdef __cplusplus
14117}
14118#endif
14119
14120int
14121main ()
14122{
9e71690e 14123return f != res_send;
84e70f78
KR
14124 ;
14125 return 0;
14126}
14127_ACEOF
14128rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14129if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14130 (eval $ac_link) 2>&5
14131 ac_status=$?
c0d27fcc 14132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14133 (exit $ac_status); } &&
14134 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14136 (eval $ac_try) 2>&5
14137 ac_status=$?
c0d27fcc 14138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14139 (exit $ac_status); }; }; then
14140 ac_cv_func_res_send=yes
14141else
14142 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14143sed 's/^/| /' conftest.$ac_ext >&5
14144
84e70f78
KR
14145ac_cv_func_res_send=no
14146fi
14147rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14148fi
c0d27fcc 14149echo "$as_me:$LINENO: result: $ac_cv_func_res_send" >&5
84e70f78
KR
14150echo "${ECHO_T}$ac_cv_func_res_send" >&6
14151if test $ac_cv_func_res_send = yes; then
14152 :
14153else
c0d27fcc 14154 echo "$as_me:$LINENO: checking for __res_send" >&5
84e70f78
KR
14155echo $ECHO_N "checking for __res_send... $ECHO_C" >&6
14156if test "${ac_cv_func___res_send+set}" = set; then
14157 echo $ECHO_N "(cached) $ECHO_C" >&6
14158else
14159 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14160#line $LINENO "configure"
cd958eb3
MB
14161/* confdefs.h. */
14162_ACEOF
14163cat confdefs.h >>conftest.$ac_ext
14164cat >>conftest.$ac_ext <<_ACEOF
14165/* end confdefs.h. */
84e70f78 14166/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14167 which can conflict with char __res_send (); below.
14168 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14169 <limits.h> exists even on freestanding compilers. */
14170#ifdef __STDC__
14171# include <limits.h>
14172#else
14173# include <assert.h>
14174#endif
84e70f78
KR
14175/* Override any gcc2 internal prototype to avoid an error. */
14176#ifdef __cplusplus
14177extern "C"
cd958eb3 14178{
84e70f78
KR
14179#endif
14180/* We use char because int might match the return type of a gcc2
14181 builtin and then its argument prototype would still apply. */
14182char __res_send ();
84e70f78
KR
14183/* The GNU C library defines this for functions which it implements
14184 to always fail with ENOSYS. Some functions are actually named
14185 something starting with __ and the normal name is an alias. */
14186#if defined (__stub___res_send) || defined (__stub_____res_send)
14187choke me
14188#else
cd958eb3
MB
14189char (*f) () = __res_send;
14190#endif
14191#ifdef __cplusplus
14192}
84e70f78
KR
14193#endif
14194
cd958eb3
MB
14195int
14196main ()
14197{
9e71690e 14198return f != __res_send;
84e70f78
KR
14199 ;
14200 return 0;
14201}
14202_ACEOF
14203rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14204if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14205 (eval $ac_link) 2>&5
14206 ac_status=$?
c0d27fcc 14207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14208 (exit $ac_status); } &&
14209 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14210 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14211 (eval $ac_try) 2>&5
14212 ac_status=$?
c0d27fcc 14213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14214 (exit $ac_status); }; }; then
14215 ac_cv_func___res_send=yes
14216else
14217 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14218sed 's/^/| /' conftest.$ac_ext >&5
14219
84e70f78
KR
14220ac_cv_func___res_send=no
14221fi
14222rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14223fi
c0d27fcc 14224echo "$as_me:$LINENO: result: $ac_cv_func___res_send" >&5
84e70f78
KR
14225echo "${ECHO_T}$ac_cv_func___res_send" >&6
14226if test $ac_cv_func___res_send = yes; then
14227 :
14228else
c0d27fcc 14229 echo "$as_me:$LINENO: checking for res_send in -lresolv" >&5
84e70f78
KR
14230echo $ECHO_N "checking for res_send in -lresolv... $ECHO_C" >&6
14231if test "${ac_cv_lib_resolv_res_send+set}" = set; then
14232 echo $ECHO_N "(cached) $ECHO_C" >&6
14233else
14234 ac_check_lib_save_LIBS=$LIBS
14235LIBS="-lresolv $LIBS"
14236cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14237#line $LINENO "configure"
cd958eb3
MB
14238/* confdefs.h. */
14239_ACEOF
14240cat confdefs.h >>conftest.$ac_ext
14241cat >>conftest.$ac_ext <<_ACEOF
14242/* end confdefs.h. */
84e70f78
KR
14243
14244/* Override any gcc2 internal prototype to avoid an error. */
14245#ifdef __cplusplus
14246extern "C"
14247#endif
14248/* We use char because int might match the return type of a gcc2
14249 builtin and then its argument prototype would still apply. */
14250char res_send ();
14251int
14252main ()
14253{
14254res_send ();
14255 ;
14256 return 0;
14257}
14258_ACEOF
14259rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14260if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14261 (eval $ac_link) 2>&5
14262 ac_status=$?
c0d27fcc 14263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14264 (exit $ac_status); } &&
14265 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14266 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14267 (eval $ac_try) 2>&5
14268 ac_status=$?
c0d27fcc 14269 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14270 (exit $ac_status); }; }; then
14271 ac_cv_lib_resolv_res_send=yes
14272else
14273 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14274sed 's/^/| /' conftest.$ac_ext >&5
14275
84e70f78
KR
14276ac_cv_lib_resolv_res_send=no
14277fi
14278rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14279LIBS=$ac_check_lib_save_LIBS
14280fi
c0d27fcc 14281echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_send" >&5
84e70f78
KR
14282echo "${ECHO_T}$ac_cv_lib_resolv_res_send" >&6
14283if test $ac_cv_lib_resolv_res_send = yes; then
14284 resolv=yes
14285else
c0d27fcc 14286 echo "$as_me:$LINENO: checking for __res_send in -lresolv" >&5
84e70f78
KR
14287echo $ECHO_N "checking for __res_send in -lresolv... $ECHO_C" >&6
14288if test "${ac_cv_lib_resolv___res_send+set}" = set; then
14289 echo $ECHO_N "(cached) $ECHO_C" >&6
14290else
14291 ac_check_lib_save_LIBS=$LIBS
14292LIBS="-lresolv $LIBS"
14293cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14294#line $LINENO "configure"
cd958eb3
MB
14295/* confdefs.h. */
14296_ACEOF
14297cat confdefs.h >>conftest.$ac_ext
14298cat >>conftest.$ac_ext <<_ACEOF
14299/* end confdefs.h. */
84e70f78
KR
14300
14301/* Override any gcc2 internal prototype to avoid an error. */
14302#ifdef __cplusplus
14303extern "C"
14304#endif
14305/* We use char because int might match the return type of a gcc2
14306 builtin and then its argument prototype would still apply. */
14307char __res_send ();
14308int
14309main ()
14310{
14311__res_send ();
14312 ;
14313 return 0;
14314}
14315_ACEOF
14316rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14317if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14318 (eval $ac_link) 2>&5
14319 ac_status=$?
c0d27fcc 14320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14321 (exit $ac_status); } &&
14322 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14323 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14324 (eval $ac_try) 2>&5
14325 ac_status=$?
c0d27fcc 14326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14327 (exit $ac_status); }; }; then
14328 ac_cv_lib_resolv___res_send=yes
14329else
14330 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14331sed 's/^/| /' conftest.$ac_ext >&5
14332
84e70f78
KR
14333ac_cv_lib_resolv___res_send=no
14334fi
14335rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14336LIBS=$ac_check_lib_save_LIBS
14337fi
c0d27fcc 14338echo "$as_me:$LINENO: result: $ac_cv_lib_resolv___res_send" >&5
84e70f78
KR
14339echo "${ECHO_T}$ac_cv_lib_resolv___res_send" >&6
14340if test $ac_cv_lib_resolv___res_send = yes; then
14341 resolv=yes
14342fi
14343
14344fi
14345
14346fi
14347
14348fi
14349
14350 if test "$resolv" = yes ; then
14351 RESOLVLIB=-lresolv
b936fae4 14352
c0d27fcc 14353cat >>confdefs.h <<\_ACEOF
84e70f78 14354#define HAVE_LIBRESOLV 1
c0d27fcc 14355_ACEOF
84e70f78
KR
14356
14357 else
14358 RESOLVLIB=
14359 fi
c0d27fcc 14360 echo "$as_me:$LINENO: checking for hes_getmailhost" >&5
84e70f78
KR
14361echo $ECHO_N "checking for hes_getmailhost... $ECHO_C" >&6
14362if test "${ac_cv_func_hes_getmailhost+set}" = set; then
14363 echo $ECHO_N "(cached) $ECHO_C" >&6
14364else
14365 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14366#line $LINENO "configure"
cd958eb3
MB
14367/* confdefs.h. */
14368_ACEOF
14369cat confdefs.h >>conftest.$ac_ext
14370cat >>conftest.$ac_ext <<_ACEOF
14371/* end confdefs.h. */
84e70f78 14372/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
14373 which can conflict with char hes_getmailhost (); below.
14374 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14375 <limits.h> exists even on freestanding compilers. */
14376#ifdef __STDC__
14377# include <limits.h>
14378#else
14379# include <assert.h>
14380#endif
84e70f78
KR
14381/* Override any gcc2 internal prototype to avoid an error. */
14382#ifdef __cplusplus
14383extern "C"
cd958eb3 14384{
84e70f78
KR
14385#endif
14386/* We use char because int might match the return type of a gcc2
14387 builtin and then its argument prototype would still apply. */
14388char hes_getmailhost ();
84e70f78
KR
14389/* The GNU C library defines this for functions which it implements
14390 to always fail with ENOSYS. Some functions are actually named
14391 something starting with __ and the normal name is an alias. */
14392#if defined (__stub_hes_getmailhost) || defined (__stub___hes_getmailhost)
14393choke me
14394#else
cd958eb3 14395char (*f) () = hes_getmailhost;
84e70f78 14396#endif
cd958eb3
MB
14397#ifdef __cplusplus
14398}
14399#endif
14400
14401int
14402main ()
14403{
9e71690e 14404return f != hes_getmailhost;
84e70f78
KR
14405 ;
14406 return 0;
14407}
14408_ACEOF
14409rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14410if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14411 (eval $ac_link) 2>&5
14412 ac_status=$?
c0d27fcc 14413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14414 (exit $ac_status); } &&
14415 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14416 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14417 (eval $ac_try) 2>&5
14418 ac_status=$?
c0d27fcc 14419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14420 (exit $ac_status); }; }; then
14421 ac_cv_func_hes_getmailhost=yes
14422else
14423 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14424sed 's/^/| /' conftest.$ac_ext >&5
14425
84e70f78
KR
14426ac_cv_func_hes_getmailhost=no
14427fi
14428rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14429fi
c0d27fcc 14430echo "$as_me:$LINENO: result: $ac_cv_func_hes_getmailhost" >&5
84e70f78
KR
14431echo "${ECHO_T}$ac_cv_func_hes_getmailhost" >&6
14432if test $ac_cv_func_hes_getmailhost = yes; then
14433 :
14434else
c0d27fcc 14435 echo "$as_me:$LINENO: checking for hes_getmailhost in -lhesiod" >&5
84e70f78
KR
14436echo $ECHO_N "checking for hes_getmailhost in -lhesiod... $ECHO_C" >&6
14437if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then
14438 echo $ECHO_N "(cached) $ECHO_C" >&6
14439else
14440 ac_check_lib_save_LIBS=$LIBS
14441LIBS="-lhesiod $RESOLVLIB $LIBS"
14442cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14443#line $LINENO "configure"
cd958eb3
MB
14444/* confdefs.h. */
14445_ACEOF
14446cat confdefs.h >>conftest.$ac_ext
14447cat >>conftest.$ac_ext <<_ACEOF
14448/* end confdefs.h. */
84e70f78
KR
14449
14450/* Override any gcc2 internal prototype to avoid an error. */
14451#ifdef __cplusplus
14452extern "C"
14453#endif
14454/* We use char because int might match the return type of a gcc2
14455 builtin and then its argument prototype would still apply. */
14456char hes_getmailhost ();
14457int
14458main ()
14459{
14460hes_getmailhost ();
14461 ;
14462 return 0;
14463}
14464_ACEOF
14465rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14466if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
84e70f78
KR
14467 (eval $ac_link) 2>&5
14468 ac_status=$?
c0d27fcc 14469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14470 (exit $ac_status); } &&
14471 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14472 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
84e70f78
KR
14473 (eval $ac_try) 2>&5
14474 ac_status=$?
c0d27fcc 14475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
84e70f78
KR
14476 (exit $ac_status); }; }; then
14477 ac_cv_lib_hesiod_hes_getmailhost=yes
14478else
14479 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14480sed 's/^/| /' conftest.$ac_ext >&5
14481
84e70f78
KR
14482ac_cv_lib_hesiod_hes_getmailhost=no
14483fi
14484rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14485LIBS=$ac_check_lib_save_LIBS
14486fi
c0d27fcc 14487echo "$as_me:$LINENO: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
84e70f78
KR
14488echo "${ECHO_T}$ac_cv_lib_hesiod_hes_getmailhost" >&6
14489if test $ac_cv_lib_hesiod_hes_getmailhost = yes; then
b936fae4 14490
c0d27fcc 14491cat >>confdefs.h <<\_ACEOF
84e70f78 14492#define HAVE_LIBHESIOD 1
c0d27fcc 14493_ACEOF
84e70f78
KR
14494
14495else
14496 :
14497fi
14498
14499fi
14500
14501fi
14502
a21616bd
KR
14503# These tell us which Kerberos-related libraries to use.
14504if test "${with_kerberos+set}" = set; then
503d2be0 14505
c0d27fcc 14506echo "$as_me:$LINENO: checking for com_err in -lcom_err" >&5
503d2be0
AS
14507echo $ECHO_N "checking for com_err in -lcom_err... $ECHO_C" >&6
14508if test "${ac_cv_lib_com_err_com_err+set}" = set; then
14509 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14510else
503d2be0 14511 ac_check_lib_save_LIBS=$LIBS
a21616bd 14512LIBS="-lcom_err $LIBS"
503d2be0 14513cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14514#line $LINENO "configure"
cd958eb3
MB
14515/* confdefs.h. */
14516_ACEOF
14517cat confdefs.h >>conftest.$ac_ext
14518cat >>conftest.$ac_ext <<_ACEOF
14519/* end confdefs.h. */
503d2be0 14520
a21616bd 14521/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14522#ifdef __cplusplus
14523extern "C"
14524#endif
a21616bd 14525/* We use char because int might match the return type of a gcc2
503d2be0
AS
14526 builtin and then its argument prototype would still apply. */
14527char com_err ();
14528int
14529main ()
14530{
14531com_err ();
14532 ;
14533 return 0;
14534}
14535_ACEOF
14536rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14537if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14538 (eval $ac_link) 2>&5
14539 ac_status=$?
c0d27fcc 14540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14541 (exit $ac_status); } &&
14542 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14544 (eval $ac_try) 2>&5
14545 ac_status=$?
c0d27fcc 14546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14547 (exit $ac_status); }; }; then
14548 ac_cv_lib_com_err_com_err=yes
14549else
14550 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14551sed 's/^/| /' conftest.$ac_ext >&5
14552
503d2be0
AS
14553ac_cv_lib_com_err_com_err=no
14554fi
14555rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14556LIBS=$ac_check_lib_save_LIBS
14557fi
c0d27fcc 14558echo "$as_me:$LINENO: result: $ac_cv_lib_com_err_com_err" >&5
503d2be0
AS
14559echo "${ECHO_T}$ac_cv_lib_com_err_com_err" >&6
14560if test $ac_cv_lib_com_err_com_err = yes; then
c0d27fcc 14561 cat >>confdefs.h <<_ACEOF
503d2be0 14562#define HAVE_LIBCOM_ERR 1
c0d27fcc 14563_ACEOF
a21616bd
KR
14564
14565 LIBS="-lcom_err $LIBS"
14566
a21616bd
KR
14567fi
14568
c0d27fcc
MR
14569
14570echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
503d2be0
AS
14571echo $ECHO_N "checking for mit_des_cbc_encrypt in -lk5crypto... $ECHO_C" >&6
14572if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then
14573 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14574else
503d2be0 14575 ac_check_lib_save_LIBS=$LIBS
a21616bd 14576LIBS="-lk5crypto $LIBS"
503d2be0 14577cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14578#line $LINENO "configure"
cd958eb3
MB
14579/* confdefs.h. */
14580_ACEOF
14581cat confdefs.h >>conftest.$ac_ext
14582cat >>conftest.$ac_ext <<_ACEOF
14583/* end confdefs.h. */
503d2be0 14584
a21616bd 14585/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14586#ifdef __cplusplus
14587extern "C"
14588#endif
a21616bd 14589/* We use char because int might match the return type of a gcc2
503d2be0
AS
14590 builtin and then its argument prototype would still apply. */
14591char mit_des_cbc_encrypt ();
14592int
14593main ()
14594{
14595mit_des_cbc_encrypt ();
14596 ;
14597 return 0;
14598}
14599_ACEOF
14600rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14601if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14602 (eval $ac_link) 2>&5
14603 ac_status=$?
c0d27fcc 14604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14605 (exit $ac_status); } &&
14606 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14607 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14608 (eval $ac_try) 2>&5
14609 ac_status=$?
c0d27fcc 14610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14611 (exit $ac_status); }; }; then
14612 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14613else
14614 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14615sed 's/^/| /' conftest.$ac_ext >&5
14616
503d2be0
AS
14617ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14618fi
14619rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14620LIBS=$ac_check_lib_save_LIBS
14621fi
c0d27fcc 14622echo "$as_me:$LINENO: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
14623echo "${ECHO_T}$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6
14624if test $ac_cv_lib_k5crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 14625 cat >>confdefs.h <<_ACEOF
503d2be0 14626#define HAVE_LIBK5CRYPTO 1
c0d27fcc 14627_ACEOF
a21616bd
KR
14628
14629 LIBS="-lk5crypto $LIBS"
14630
a21616bd
KR
14631fi
14632
c0d27fcc
MR
14633
14634echo "$as_me:$LINENO: checking for mit_des_cbc_encrypt in -lcrypto" >&5
503d2be0
AS
14635echo $ECHO_N "checking for mit_des_cbc_encrypt in -lcrypto... $ECHO_C" >&6
14636if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then
14637 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14638else
503d2be0 14639 ac_check_lib_save_LIBS=$LIBS
a21616bd 14640LIBS="-lcrypto $LIBS"
503d2be0 14641cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14642#line $LINENO "configure"
cd958eb3
MB
14643/* confdefs.h. */
14644_ACEOF
14645cat confdefs.h >>conftest.$ac_ext
14646cat >>conftest.$ac_ext <<_ACEOF
14647/* end confdefs.h. */
503d2be0 14648
a21616bd 14649/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14650#ifdef __cplusplus
14651extern "C"
14652#endif
a21616bd 14653/* We use char because int might match the return type of a gcc2
503d2be0
AS
14654 builtin and then its argument prototype would still apply. */
14655char mit_des_cbc_encrypt ();
14656int
14657main ()
14658{
14659mit_des_cbc_encrypt ();
14660 ;
14661 return 0;
14662}
14663_ACEOF
14664rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14665if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14666 (eval $ac_link) 2>&5
14667 ac_status=$?
c0d27fcc 14668 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14669 (exit $ac_status); } &&
14670 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14671 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14672 (eval $ac_try) 2>&5
14673 ac_status=$?
c0d27fcc 14674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14675 (exit $ac_status); }; }; then
14676 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14677else
14678 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14679sed 's/^/| /' conftest.$ac_ext >&5
14680
503d2be0
AS
14681ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14682fi
14683rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14684LIBS=$ac_check_lib_save_LIBS
14685fi
c0d27fcc 14686echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
503d2be0
AS
14687echo "${ECHO_T}$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6
14688if test $ac_cv_lib_crypto_mit_des_cbc_encrypt = yes; then
c0d27fcc 14689 cat >>confdefs.h <<_ACEOF
503d2be0 14690#define HAVE_LIBCRYPTO 1
c0d27fcc 14691_ACEOF
a21616bd
KR
14692
14693 LIBS="-lcrypto $LIBS"
14694
a21616bd
KR
14695fi
14696
c0d27fcc
MR
14697
14698echo "$as_me:$LINENO: checking for krb5_init_context in -lkrb5" >&5
503d2be0
AS
14699echo $ECHO_N "checking for krb5_init_context in -lkrb5... $ECHO_C" >&6
14700if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then
14701 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14702else
503d2be0 14703 ac_check_lib_save_LIBS=$LIBS
a21616bd 14704LIBS="-lkrb5 $LIBS"
503d2be0 14705cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14706#line $LINENO "configure"
cd958eb3
MB
14707/* confdefs.h. */
14708_ACEOF
14709cat confdefs.h >>conftest.$ac_ext
14710cat >>conftest.$ac_ext <<_ACEOF
14711/* end confdefs.h. */
a21616bd 14712
503d2be0
AS
14713/* Override any gcc2 internal prototype to avoid an error. */
14714#ifdef __cplusplus
14715extern "C"
14716#endif
14717/* We use char because int might match the return type of a gcc2
14718 builtin and then its argument prototype would still apply. */
14719char krb5_init_context ();
14720int
14721main ()
14722{
14723krb5_init_context ();
14724 ;
14725 return 0;
14726}
14727_ACEOF
14728rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14729if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14730 (eval $ac_link) 2>&5
14731 ac_status=$?
c0d27fcc 14732 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14733 (exit $ac_status); } &&
14734 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14735 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14736 (eval $ac_try) 2>&5
14737 ac_status=$?
c0d27fcc 14738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14739 (exit $ac_status); }; }; then
14740 ac_cv_lib_krb5_krb5_init_context=yes
14741else
14742 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14743sed 's/^/| /' conftest.$ac_ext >&5
14744
503d2be0
AS
14745ac_cv_lib_krb5_krb5_init_context=no
14746fi
14747rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14748LIBS=$ac_check_lib_save_LIBS
14749fi
c0d27fcc 14750echo "$as_me:$LINENO: result: $ac_cv_lib_krb5_krb5_init_context" >&5
503d2be0
AS
14751echo "${ECHO_T}$ac_cv_lib_krb5_krb5_init_context" >&6
14752if test $ac_cv_lib_krb5_krb5_init_context = yes; then
c0d27fcc 14753 cat >>confdefs.h <<_ACEOF
503d2be0 14754#define HAVE_LIBKRB5 1
c0d27fcc 14755_ACEOF
a21616bd
KR
14756
14757 LIBS="-lkrb5 $LIBS"
14758
a21616bd
KR
14759fi
14760
14761 if test "${with_kerberos5+set}" != set; then
503d2be0 14762
c0d27fcc 14763echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes425" >&5
503d2be0
AS
14764echo $ECHO_N "checking for des_cbc_encrypt in -ldes425... $ECHO_C" >&6
14765if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then
14766 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14767else
503d2be0 14768 ac_check_lib_save_LIBS=$LIBS
a21616bd 14769LIBS="-ldes425 $LIBS"
503d2be0 14770cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14771#line $LINENO "configure"
cd958eb3
MB
14772/* confdefs.h. */
14773_ACEOF
14774cat confdefs.h >>conftest.$ac_ext
14775cat >>conftest.$ac_ext <<_ACEOF
14776/* end confdefs.h. */
503d2be0 14777
a21616bd 14778/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14779#ifdef __cplusplus
14780extern "C"
14781#endif
a21616bd 14782/* We use char because int might match the return type of a gcc2
503d2be0
AS
14783 builtin and then its argument prototype would still apply. */
14784char des_cbc_encrypt ();
14785int
14786main ()
14787{
14788des_cbc_encrypt ();
14789 ;
14790 return 0;
14791}
14792_ACEOF
14793rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14794if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14795 (eval $ac_link) 2>&5
14796 ac_status=$?
c0d27fcc 14797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14798 (exit $ac_status); } &&
14799 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14801 (eval $ac_try) 2>&5
14802 ac_status=$?
c0d27fcc 14803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14804 (exit $ac_status); }; }; then
14805 ac_cv_lib_des425_des_cbc_encrypt=yes
14806else
14807 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14808sed 's/^/| /' conftest.$ac_ext >&5
14809
503d2be0
AS
14810ac_cv_lib_des425_des_cbc_encrypt=no
14811fi
14812rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14813LIBS=$ac_check_lib_save_LIBS
14814fi
c0d27fcc 14815echo "$as_me:$LINENO: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
503d2be0
AS
14816echo "${ECHO_T}$ac_cv_lib_des425_des_cbc_encrypt" >&6
14817if test $ac_cv_lib_des425_des_cbc_encrypt = yes; then
c0d27fcc 14818 cat >>confdefs.h <<_ACEOF
503d2be0 14819#define HAVE_LIBDES425 1
c0d27fcc 14820_ACEOF
a21616bd
KR
14821
14822 LIBS="-ldes425 $LIBS"
14823
14824else
503d2be0 14825
c0d27fcc 14826echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
503d2be0
AS
14827echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6
14828if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
14829 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14830else
503d2be0 14831 ac_check_lib_save_LIBS=$LIBS
a21616bd 14832LIBS="-ldes $LIBS"
503d2be0 14833cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14834#line $LINENO "configure"
cd958eb3
MB
14835/* confdefs.h. */
14836_ACEOF
14837cat confdefs.h >>conftest.$ac_ext
14838cat >>conftest.$ac_ext <<_ACEOF
14839/* end confdefs.h. */
503d2be0 14840
a21616bd 14841/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14842#ifdef __cplusplus
14843extern "C"
14844#endif
a21616bd 14845/* We use char because int might match the return type of a gcc2
503d2be0
AS
14846 builtin and then its argument prototype would still apply. */
14847char des_cbc_encrypt ();
14848int
14849main ()
14850{
14851des_cbc_encrypt ();
14852 ;
14853 return 0;
14854}
14855_ACEOF
14856rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14857if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14858 (eval $ac_link) 2>&5
14859 ac_status=$?
c0d27fcc 14860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14861 (exit $ac_status); } &&
14862 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14864 (eval $ac_try) 2>&5
14865 ac_status=$?
c0d27fcc 14866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14867 (exit $ac_status); }; }; then
14868 ac_cv_lib_des_des_cbc_encrypt=yes
14869else
14870 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14871sed 's/^/| /' conftest.$ac_ext >&5
14872
503d2be0
AS
14873ac_cv_lib_des_des_cbc_encrypt=no
14874fi
14875rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14876LIBS=$ac_check_lib_save_LIBS
14877fi
c0d27fcc 14878echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
503d2be0
AS
14879echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6
14880if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
c0d27fcc 14881 cat >>confdefs.h <<_ACEOF
503d2be0 14882#define HAVE_LIBDES 1
c0d27fcc 14883_ACEOF
a21616bd
KR
14884
14885 LIBS="-ldes $LIBS"
14886
a21616bd
KR
14887fi
14888
14889fi
14890
c0d27fcc
MR
14891
14892echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb4" >&5
503d2be0
AS
14893echo $ECHO_N "checking for krb_get_cred in -lkrb4... $ECHO_C" >&6
14894if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then
14895 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14896else
503d2be0 14897 ac_check_lib_save_LIBS=$LIBS
a21616bd 14898LIBS="-lkrb4 $LIBS"
503d2be0 14899cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14900#line $LINENO "configure"
cd958eb3
MB
14901/* confdefs.h. */
14902_ACEOF
14903cat confdefs.h >>conftest.$ac_ext
14904cat >>conftest.$ac_ext <<_ACEOF
14905/* end confdefs.h. */
503d2be0 14906
a21616bd 14907/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14908#ifdef __cplusplus
14909extern "C"
14910#endif
a21616bd 14911/* We use char because int might match the return type of a gcc2
503d2be0
AS
14912 builtin and then its argument prototype would still apply. */
14913char krb_get_cred ();
14914int
14915main ()
14916{
14917krb_get_cred ();
14918 ;
14919 return 0;
14920}
14921_ACEOF
14922rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14923if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14924 (eval $ac_link) 2>&5
14925 ac_status=$?
c0d27fcc 14926 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14927 (exit $ac_status); } &&
14928 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14929 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14930 (eval $ac_try) 2>&5
14931 ac_status=$?
c0d27fcc 14932 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14933 (exit $ac_status); }; }; then
14934 ac_cv_lib_krb4_krb_get_cred=yes
14935else
14936 echo "$as_me: failed program was:" >&5
cd958eb3
MB
14937sed 's/^/| /' conftest.$ac_ext >&5
14938
503d2be0
AS
14939ac_cv_lib_krb4_krb_get_cred=no
14940fi
14941rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14942LIBS=$ac_check_lib_save_LIBS
14943fi
c0d27fcc 14944echo "$as_me:$LINENO: result: $ac_cv_lib_krb4_krb_get_cred" >&5
503d2be0
AS
14945echo "${ECHO_T}$ac_cv_lib_krb4_krb_get_cred" >&6
14946if test $ac_cv_lib_krb4_krb_get_cred = yes; then
c0d27fcc 14947 cat >>confdefs.h <<_ACEOF
503d2be0 14948#define HAVE_LIBKRB4 1
c0d27fcc 14949_ACEOF
a21616bd
KR
14950
14951 LIBS="-lkrb4 $LIBS"
14952
14953else
503d2be0 14954
c0d27fcc 14955echo "$as_me:$LINENO: checking for krb_get_cred in -lkrb" >&5
503d2be0
AS
14956echo $ECHO_N "checking for krb_get_cred in -lkrb... $ECHO_C" >&6
14957if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then
14958 echo $ECHO_N "(cached) $ECHO_C" >&6
a21616bd 14959else
503d2be0 14960 ac_check_lib_save_LIBS=$LIBS
a21616bd 14961LIBS="-lkrb $LIBS"
503d2be0 14962cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 14963#line $LINENO "configure"
cd958eb3
MB
14964/* confdefs.h. */
14965_ACEOF
14966cat confdefs.h >>conftest.$ac_ext
14967cat >>conftest.$ac_ext <<_ACEOF
14968/* end confdefs.h. */
503d2be0 14969
a21616bd 14970/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
14971#ifdef __cplusplus
14972extern "C"
14973#endif
a21616bd 14974/* We use char because int might match the return type of a gcc2
503d2be0
AS
14975 builtin and then its argument prototype would still apply. */
14976char krb_get_cred ();
14977int
14978main ()
14979{
14980krb_get_cred ();
14981 ;
14982 return 0;
14983}
14984_ACEOF
14985rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 14986if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
14987 (eval $ac_link) 2>&5
14988 ac_status=$?
c0d27fcc 14989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14990 (exit $ac_status); } &&
14991 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 14992 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
14993 (eval $ac_try) 2>&5
14994 ac_status=$?
c0d27fcc 14995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
14996 (exit $ac_status); }; }; then
14997 ac_cv_lib_krb_krb_get_cred=yes
14998else
14999 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15000sed 's/^/| /' conftest.$ac_ext >&5
15001
503d2be0
AS
15002ac_cv_lib_krb_krb_get_cred=no
15003fi
15004rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15005LIBS=$ac_check_lib_save_LIBS
15006fi
c0d27fcc 15007echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_get_cred" >&5
503d2be0
AS
15008echo "${ECHO_T}$ac_cv_lib_krb_krb_get_cred" >&6
15009if test $ac_cv_lib_krb_krb_get_cred = yes; then
c0d27fcc 15010 cat >>confdefs.h <<_ACEOF
503d2be0 15011#define HAVE_LIBKRB 1
c0d27fcc 15012_ACEOF
a21616bd
KR
15013
15014 LIBS="-lkrb $LIBS"
15015
a21616bd
KR
15016fi
15017
15018fi
15019
15020 fi
15021
15022 if test "${with_kerberos5+set}" = set; then
503d2be0
AS
15023
15024for ac_header in krb5.h
a21616bd 15025do
503d2be0 15026as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15027if eval "test \"\${$as_ac_Header+set}\" = set"; then
15028 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15029echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15030if eval "test \"\${$as_ac_Header+set}\" = set"; then
15031 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15032fi
15033echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15034echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15035else
c0d27fcc
MR
15036 # Is the header compilable?
15037echo "$as_me:$LINENO: checking $ac_header usability" >&5
15038echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15039cat >conftest.$ac_ext <<_ACEOF
15040#line $LINENO "configure"
cd958eb3
MB
15041/* confdefs.h. */
15042_ACEOF
15043cat confdefs.h >>conftest.$ac_ext
15044cat >>conftest.$ac_ext <<_ACEOF
15045/* end confdefs.h. */
c0d27fcc
MR
15046$ac_includes_default
15047#include <$ac_header>
15048_ACEOF
15049rm -f conftest.$ac_objext
15050if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15051 (eval $ac_compile) 2>&5
15052 ac_status=$?
15053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15054 (exit $ac_status); } &&
15055 { ac_try='test -s conftest.$ac_objext'
15056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15057 (eval $ac_try) 2>&5
15058 ac_status=$?
15059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15060 (exit $ac_status); }; }; then
15061 ac_header_compiler=yes
15062else
15063 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15064sed 's/^/| /' conftest.$ac_ext >&5
15065
c0d27fcc
MR
15066ac_header_compiler=no
15067fi
15068rm -f conftest.$ac_objext conftest.$ac_ext
15069echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15070echo "${ECHO_T}$ac_header_compiler" >&6
15071
15072# Is the header present?
15073echo "$as_me:$LINENO: checking $ac_header presence" >&5
15074echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15075cat >conftest.$ac_ext <<_ACEOF
15076#line $LINENO "configure"
cd958eb3
MB
15077/* confdefs.h. */
15078_ACEOF
15079cat confdefs.h >>conftest.$ac_ext
15080cat >>conftest.$ac_ext <<_ACEOF
15081/* end confdefs.h. */
503d2be0
AS
15082#include <$ac_header>
15083_ACEOF
c0d27fcc 15084if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15085 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15086 ac_status=$?
6bae0ccf 15087 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15088 rm -f conftest.er1
15089 cat conftest.err >&5
c0d27fcc 15090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15091 (exit $ac_status); } >/dev/null; then
15092 if test -s conftest.err; then
15093 ac_cpp_err=$ac_c_preproc_warn_flag
15094 else
15095 ac_cpp_err=
15096 fi
15097else
15098 ac_cpp_err=yes
15099fi
15100if test -z "$ac_cpp_err"; then
c0d27fcc 15101 ac_header_preproc=yes
503d2be0
AS
15102else
15103 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15104sed 's/^/| /' conftest.$ac_ext >&5
15105
c0d27fcc 15106 ac_header_preproc=no
a21616bd 15107fi
503d2be0 15108rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15109echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15110echo "${ECHO_T}$ac_header_preproc" >&6
15111
15112# So? What about this header?
15113case $ac_header_compiler:$ac_header_preproc in
15114 yes:no )
15115 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15116echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15117 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15118echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15119 (
15120 cat <<\_ASBOX
15121## ------------------------------------ ##
15122## Report this to bug-autoconf@gnu.org. ##
15123## ------------------------------------ ##
15124_ASBOX
15125 ) |
15126 sed "s/^/$as_me: WARNING: /" >&2
15127 ;;
c0d27fcc
MR
15128 no:yes )
15129 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15130echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15131 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15132echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15133 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15134echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15135 (
15136 cat <<\_ASBOX
15137## ------------------------------------ ##
15138## Report this to bug-autoconf@gnu.org. ##
15139## ------------------------------------ ##
15140_ASBOX
15141 ) |
15142 sed "s/^/$as_me: WARNING: /" >&2
15143 ;;
c0d27fcc
MR
15144esac
15145echo "$as_me:$LINENO: checking for $ac_header" >&5
15146echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15147if eval "test \"\${$as_ac_Header+set}\" = set"; then
15148 echo $ECHO_N "(cached) $ECHO_C" >&6
15149else
15150 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15151fi
c0d27fcc 15152echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15153echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15154
15155fi
503d2be0 15156if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15157 cat >>confdefs.h <<_ACEOF
503d2be0 15158#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15159_ACEOF
503d2be0 15160
a21616bd 15161fi
c0d27fcc 15162
a21616bd
KR
15163done
15164
15165 else
503d2be0
AS
15166
15167for ac_header in des.h
a21616bd 15168do
503d2be0 15169as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15170if eval "test \"\${$as_ac_Header+set}\" = set"; then
15171 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15172echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15173if eval "test \"\${$as_ac_Header+set}\" = set"; then
15174 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15175fi
15176echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15177echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15178else
c0d27fcc
MR
15179 # Is the header compilable?
15180echo "$as_me:$LINENO: checking $ac_header usability" >&5
15181echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15182cat >conftest.$ac_ext <<_ACEOF
15183#line $LINENO "configure"
cd958eb3
MB
15184/* confdefs.h. */
15185_ACEOF
15186cat confdefs.h >>conftest.$ac_ext
15187cat >>conftest.$ac_ext <<_ACEOF
15188/* end confdefs.h. */
c0d27fcc
MR
15189$ac_includes_default
15190#include <$ac_header>
15191_ACEOF
15192rm -f conftest.$ac_objext
15193if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15194 (eval $ac_compile) 2>&5
15195 ac_status=$?
15196 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15197 (exit $ac_status); } &&
15198 { ac_try='test -s conftest.$ac_objext'
15199 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15200 (eval $ac_try) 2>&5
15201 ac_status=$?
15202 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15203 (exit $ac_status); }; }; then
15204 ac_header_compiler=yes
15205else
15206 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15207sed 's/^/| /' conftest.$ac_ext >&5
15208
c0d27fcc
MR
15209ac_header_compiler=no
15210fi
15211rm -f conftest.$ac_objext conftest.$ac_ext
15212echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15213echo "${ECHO_T}$ac_header_compiler" >&6
15214
15215# Is the header present?
15216echo "$as_me:$LINENO: checking $ac_header presence" >&5
15217echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15218cat >conftest.$ac_ext <<_ACEOF
15219#line $LINENO "configure"
cd958eb3
MB
15220/* confdefs.h. */
15221_ACEOF
15222cat confdefs.h >>conftest.$ac_ext
15223cat >>conftest.$ac_ext <<_ACEOF
15224/* end confdefs.h. */
503d2be0
AS
15225#include <$ac_header>
15226_ACEOF
c0d27fcc 15227if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15228 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15229 ac_status=$?
6bae0ccf 15230 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15231 rm -f conftest.er1
15232 cat conftest.err >&5
c0d27fcc 15233 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15234 (exit $ac_status); } >/dev/null; then
15235 if test -s conftest.err; then
15236 ac_cpp_err=$ac_c_preproc_warn_flag
15237 else
15238 ac_cpp_err=
15239 fi
15240else
15241 ac_cpp_err=yes
15242fi
15243if test -z "$ac_cpp_err"; then
c0d27fcc 15244 ac_header_preproc=yes
503d2be0
AS
15245else
15246 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15247sed 's/^/| /' conftest.$ac_ext >&5
15248
c0d27fcc 15249 ac_header_preproc=no
a21616bd 15250fi
503d2be0 15251rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15252echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15253echo "${ECHO_T}$ac_header_preproc" >&6
15254
15255# So? What about this header?
15256case $ac_header_compiler:$ac_header_preproc in
15257 yes:no )
15258 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15259echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15260 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15261echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15262 (
15263 cat <<\_ASBOX
15264## ------------------------------------ ##
15265## Report this to bug-autoconf@gnu.org. ##
15266## ------------------------------------ ##
15267_ASBOX
15268 ) |
15269 sed "s/^/$as_me: WARNING: /" >&2
15270 ;;
c0d27fcc
MR
15271 no:yes )
15272 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15273echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15274 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15275echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15276 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15277echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15278 (
15279 cat <<\_ASBOX
15280## ------------------------------------ ##
15281## Report this to bug-autoconf@gnu.org. ##
15282## ------------------------------------ ##
15283_ASBOX
15284 ) |
15285 sed "s/^/$as_me: WARNING: /" >&2
15286 ;;
c0d27fcc
MR
15287esac
15288echo "$as_me:$LINENO: checking for $ac_header" >&5
15289echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15290if eval "test \"\${$as_ac_Header+set}\" = set"; then
15291 echo $ECHO_N "(cached) $ECHO_C" >&6
15292else
15293 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15294fi
c0d27fcc 15295echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15296echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15297
15298fi
503d2be0 15299if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15300 cat >>confdefs.h <<_ACEOF
503d2be0 15301#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15302_ACEOF
503d2be0 15303
a21616bd 15304else
503d2be0
AS
15305
15306for ac_header in kerberosIV/des.h
a21616bd 15307do
503d2be0 15308as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15309if eval "test \"\${$as_ac_Header+set}\" = set"; then
15310 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15311echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15312if eval "test \"\${$as_ac_Header+set}\" = set"; then
15313 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15314fi
15315echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15316echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15317else
c0d27fcc
MR
15318 # Is the header compilable?
15319echo "$as_me:$LINENO: checking $ac_header usability" >&5
15320echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15321cat >conftest.$ac_ext <<_ACEOF
15322#line $LINENO "configure"
cd958eb3
MB
15323/* confdefs.h. */
15324_ACEOF
15325cat confdefs.h >>conftest.$ac_ext
15326cat >>conftest.$ac_ext <<_ACEOF
15327/* end confdefs.h. */
c0d27fcc
MR
15328$ac_includes_default
15329#include <$ac_header>
15330_ACEOF
15331rm -f conftest.$ac_objext
15332if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15333 (eval $ac_compile) 2>&5
15334 ac_status=$?
15335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15336 (exit $ac_status); } &&
15337 { ac_try='test -s conftest.$ac_objext'
15338 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15339 (eval $ac_try) 2>&5
15340 ac_status=$?
15341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15342 (exit $ac_status); }; }; then
15343 ac_header_compiler=yes
15344else
15345 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15346sed 's/^/| /' conftest.$ac_ext >&5
15347
c0d27fcc
MR
15348ac_header_compiler=no
15349fi
15350rm -f conftest.$ac_objext conftest.$ac_ext
15351echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15352echo "${ECHO_T}$ac_header_compiler" >&6
15353
15354# Is the header present?
15355echo "$as_me:$LINENO: checking $ac_header presence" >&5
15356echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15357cat >conftest.$ac_ext <<_ACEOF
15358#line $LINENO "configure"
cd958eb3
MB
15359/* confdefs.h. */
15360_ACEOF
15361cat confdefs.h >>conftest.$ac_ext
15362cat >>conftest.$ac_ext <<_ACEOF
15363/* end confdefs.h. */
503d2be0
AS
15364#include <$ac_header>
15365_ACEOF
c0d27fcc 15366if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15367 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15368 ac_status=$?
6bae0ccf 15369 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15370 rm -f conftest.er1
15371 cat conftest.err >&5
c0d27fcc 15372 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15373 (exit $ac_status); } >/dev/null; then
15374 if test -s conftest.err; then
15375 ac_cpp_err=$ac_c_preproc_warn_flag
15376 else
15377 ac_cpp_err=
15378 fi
15379else
15380 ac_cpp_err=yes
15381fi
15382if test -z "$ac_cpp_err"; then
c0d27fcc 15383 ac_header_preproc=yes
503d2be0
AS
15384else
15385 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15386sed 's/^/| /' conftest.$ac_ext >&5
15387
c0d27fcc 15388 ac_header_preproc=no
a21616bd 15389fi
503d2be0 15390rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15391echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15392echo "${ECHO_T}$ac_header_preproc" >&6
15393
15394# So? What about this header?
15395case $ac_header_compiler:$ac_header_preproc in
15396 yes:no )
15397 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15398echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15399 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15400echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15401 (
15402 cat <<\_ASBOX
15403## ------------------------------------ ##
15404## Report this to bug-autoconf@gnu.org. ##
15405## ------------------------------------ ##
15406_ASBOX
15407 ) |
15408 sed "s/^/$as_me: WARNING: /" >&2
15409 ;;
c0d27fcc
MR
15410 no:yes )
15411 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15412echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15413 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15414echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15415 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15416echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15417 (
15418 cat <<\_ASBOX
15419## ------------------------------------ ##
15420## Report this to bug-autoconf@gnu.org. ##
15421## ------------------------------------ ##
15422_ASBOX
15423 ) |
15424 sed "s/^/$as_me: WARNING: /" >&2
15425 ;;
c0d27fcc
MR
15426esac
15427echo "$as_me:$LINENO: checking for $ac_header" >&5
15428echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15429if eval "test \"\${$as_ac_Header+set}\" = set"; then
15430 echo $ECHO_N "(cached) $ECHO_C" >&6
15431else
15432 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15433fi
c0d27fcc 15434echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15435echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15436
15437fi
503d2be0 15438if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15439 cat >>confdefs.h <<_ACEOF
503d2be0 15440#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15441_ACEOF
503d2be0 15442
a21616bd 15443else
503d2be0
AS
15444
15445for ac_header in kerberos/des.h
a21616bd 15446do
503d2be0 15447as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15448if eval "test \"\${$as_ac_Header+set}\" = set"; then
15449 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15450echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15451if eval "test \"\${$as_ac_Header+set}\" = set"; then
15452 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15453fi
15454echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15455echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15456else
c0d27fcc
MR
15457 # Is the header compilable?
15458echo "$as_me:$LINENO: checking $ac_header usability" >&5
15459echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15460cat >conftest.$ac_ext <<_ACEOF
15461#line $LINENO "configure"
cd958eb3
MB
15462/* confdefs.h. */
15463_ACEOF
15464cat confdefs.h >>conftest.$ac_ext
15465cat >>conftest.$ac_ext <<_ACEOF
15466/* end confdefs.h. */
c0d27fcc
MR
15467$ac_includes_default
15468#include <$ac_header>
15469_ACEOF
15470rm -f conftest.$ac_objext
15471if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15472 (eval $ac_compile) 2>&5
15473 ac_status=$?
15474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15475 (exit $ac_status); } &&
15476 { ac_try='test -s conftest.$ac_objext'
15477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15478 (eval $ac_try) 2>&5
15479 ac_status=$?
15480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15481 (exit $ac_status); }; }; then
15482 ac_header_compiler=yes
15483else
15484 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15485sed 's/^/| /' conftest.$ac_ext >&5
15486
c0d27fcc
MR
15487ac_header_compiler=no
15488fi
15489rm -f conftest.$ac_objext conftest.$ac_ext
15490echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15491echo "${ECHO_T}$ac_header_compiler" >&6
15492
15493# Is the header present?
15494echo "$as_me:$LINENO: checking $ac_header presence" >&5
15495echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15496cat >conftest.$ac_ext <<_ACEOF
15497#line $LINENO "configure"
cd958eb3
MB
15498/* confdefs.h. */
15499_ACEOF
15500cat confdefs.h >>conftest.$ac_ext
15501cat >>conftest.$ac_ext <<_ACEOF
15502/* end confdefs.h. */
503d2be0
AS
15503#include <$ac_header>
15504_ACEOF
c0d27fcc 15505if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15506 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15507 ac_status=$?
6bae0ccf 15508 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15509 rm -f conftest.er1
15510 cat conftest.err >&5
c0d27fcc 15511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15512 (exit $ac_status); } >/dev/null; then
15513 if test -s conftest.err; then
15514 ac_cpp_err=$ac_c_preproc_warn_flag
15515 else
15516 ac_cpp_err=
15517 fi
15518else
15519 ac_cpp_err=yes
15520fi
15521if test -z "$ac_cpp_err"; then
c0d27fcc 15522 ac_header_preproc=yes
503d2be0
AS
15523else
15524 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15525sed 's/^/| /' conftest.$ac_ext >&5
15526
c0d27fcc 15527 ac_header_preproc=no
a21616bd 15528fi
503d2be0 15529rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15530echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15531echo "${ECHO_T}$ac_header_preproc" >&6
15532
15533# So? What about this header?
15534case $ac_header_compiler:$ac_header_preproc in
15535 yes:no )
15536 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15537echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15538 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15539echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15540 (
15541 cat <<\_ASBOX
15542## ------------------------------------ ##
15543## Report this to bug-autoconf@gnu.org. ##
15544## ------------------------------------ ##
15545_ASBOX
15546 ) |
15547 sed "s/^/$as_me: WARNING: /" >&2
15548 ;;
c0d27fcc
MR
15549 no:yes )
15550 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15551echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15552 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15553echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15554 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15555echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15556 (
15557 cat <<\_ASBOX
15558## ------------------------------------ ##
15559## Report this to bug-autoconf@gnu.org. ##
15560## ------------------------------------ ##
15561_ASBOX
15562 ) |
15563 sed "s/^/$as_me: WARNING: /" >&2
15564 ;;
c0d27fcc
MR
15565esac
15566echo "$as_me:$LINENO: checking for $ac_header" >&5
15567echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15568if eval "test \"\${$as_ac_Header+set}\" = set"; then
15569 echo $ECHO_N "(cached) $ECHO_C" >&6
15570else
15571 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15572fi
c0d27fcc 15573echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15574echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15575
15576fi
503d2be0 15577if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15578 cat >>confdefs.h <<_ACEOF
503d2be0 15579#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15580_ACEOF
a21616bd
KR
15581
15582fi
c0d27fcc 15583
a21616bd
KR
15584done
15585
98418dba 15586fi
c0d27fcc 15587
925c2f3f
EZ
15588done
15589
98418dba 15590fi
c0d27fcc 15591
925c2f3f 15592done
98418dba 15593
c0d27fcc 15594
925c2f3f
EZ
15595for ac_header in krb.h
15596do
15597as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15598if eval "test \"\${$as_ac_Header+set}\" = set"; then
15599 echo "$as_me:$LINENO: checking for $ac_header" >&5
925c2f3f
EZ
15600echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15601if eval "test \"\${$as_ac_Header+set}\" = set"; then
15602 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15603fi
15604echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15605echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
15606else
15607 # Is the header compilable?
15608echo "$as_me:$LINENO: checking $ac_header usability" >&5
15609echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15610cat >conftest.$ac_ext <<_ACEOF
15611#line $LINENO "configure"
cd958eb3
MB
15612/* confdefs.h. */
15613_ACEOF
15614cat confdefs.h >>conftest.$ac_ext
15615cat >>conftest.$ac_ext <<_ACEOF
15616/* end confdefs.h. */
c0d27fcc
MR
15617$ac_includes_default
15618#include <$ac_header>
15619_ACEOF
15620rm -f conftest.$ac_objext
15621if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15622 (eval $ac_compile) 2>&5
15623 ac_status=$?
15624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15625 (exit $ac_status); } &&
15626 { ac_try='test -s conftest.$ac_objext'
15627 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15628 (eval $ac_try) 2>&5
15629 ac_status=$?
15630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15631 (exit $ac_status); }; }; then
15632 ac_header_compiler=yes
925c2f3f 15633else
c0d27fcc 15634 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15635sed 's/^/| /' conftest.$ac_ext >&5
15636
c0d27fcc
MR
15637ac_header_compiler=no
15638fi
15639rm -f conftest.$ac_objext conftest.$ac_ext
15640echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15641echo "${ECHO_T}$ac_header_compiler" >&6
15642
15643# Is the header present?
15644echo "$as_me:$LINENO: checking $ac_header presence" >&5
15645echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15646cat >conftest.$ac_ext <<_ACEOF
15647#line $LINENO "configure"
cd958eb3
MB
15648/* confdefs.h. */
15649_ACEOF
15650cat confdefs.h >>conftest.$ac_ext
15651cat >>conftest.$ac_ext <<_ACEOF
15652/* end confdefs.h. */
503d2be0
AS
15653#include <$ac_header>
15654_ACEOF
c0d27fcc 15655if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15656 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15657 ac_status=$?
6bae0ccf 15658 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15659 rm -f conftest.er1
15660 cat conftest.err >&5
c0d27fcc 15661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15662 (exit $ac_status); } >/dev/null; then
15663 if test -s conftest.err; then
15664 ac_cpp_err=$ac_c_preproc_warn_flag
15665 else
15666 ac_cpp_err=
15667 fi
15668else
15669 ac_cpp_err=yes
15670fi
15671if test -z "$ac_cpp_err"; then
c0d27fcc 15672 ac_header_preproc=yes
503d2be0
AS
15673else
15674 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15675sed 's/^/| /' conftest.$ac_ext >&5
15676
c0d27fcc 15677 ac_header_preproc=no
a21616bd 15678fi
503d2be0 15679rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15680echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15681echo "${ECHO_T}$ac_header_preproc" >&6
15682
15683# So? What about this header?
15684case $ac_header_compiler:$ac_header_preproc in
15685 yes:no )
15686 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15687echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15688 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15689echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15690 (
15691 cat <<\_ASBOX
15692## ------------------------------------ ##
15693## Report this to bug-autoconf@gnu.org. ##
15694## ------------------------------------ ##
15695_ASBOX
15696 ) |
15697 sed "s/^/$as_me: WARNING: /" >&2
15698 ;;
c0d27fcc
MR
15699 no:yes )
15700 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15701echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15702 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15703echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15704 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15705echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15706 (
15707 cat <<\_ASBOX
15708## ------------------------------------ ##
15709## Report this to bug-autoconf@gnu.org. ##
15710## ------------------------------------ ##
15711_ASBOX
15712 ) |
15713 sed "s/^/$as_me: WARNING: /" >&2
15714 ;;
c0d27fcc
MR
15715esac
15716echo "$as_me:$LINENO: checking for $ac_header" >&5
15717echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15718if eval "test \"\${$as_ac_Header+set}\" = set"; then
15719 echo $ECHO_N "(cached) $ECHO_C" >&6
15720else
15721 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15722fi
c0d27fcc 15723echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15724echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15725
15726fi
503d2be0 15727if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15728 cat >>confdefs.h <<_ACEOF
503d2be0 15729#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15730_ACEOF
503d2be0 15731
a21616bd 15732else
503d2be0
AS
15733
15734for ac_header in kerberosIV/krb.h
a21616bd 15735do
503d2be0 15736as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15737if eval "test \"\${$as_ac_Header+set}\" = set"; then
15738 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15739echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15740if eval "test \"\${$as_ac_Header+set}\" = set"; then
15741 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15742fi
15743echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15744echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15745else
c0d27fcc
MR
15746 # Is the header compilable?
15747echo "$as_me:$LINENO: checking $ac_header usability" >&5
15748echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15749cat >conftest.$ac_ext <<_ACEOF
15750#line $LINENO "configure"
cd958eb3
MB
15751/* confdefs.h. */
15752_ACEOF
15753cat confdefs.h >>conftest.$ac_ext
15754cat >>conftest.$ac_ext <<_ACEOF
15755/* end confdefs.h. */
c0d27fcc
MR
15756$ac_includes_default
15757#include <$ac_header>
15758_ACEOF
15759rm -f conftest.$ac_objext
15760if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15761 (eval $ac_compile) 2>&5
15762 ac_status=$?
15763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15764 (exit $ac_status); } &&
15765 { ac_try='test -s conftest.$ac_objext'
15766 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15767 (eval $ac_try) 2>&5
15768 ac_status=$?
15769 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15770 (exit $ac_status); }; }; then
15771 ac_header_compiler=yes
15772else
15773 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15774sed 's/^/| /' conftest.$ac_ext >&5
15775
c0d27fcc
MR
15776ac_header_compiler=no
15777fi
15778rm -f conftest.$ac_objext conftest.$ac_ext
15779echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15780echo "${ECHO_T}$ac_header_compiler" >&6
15781
15782# Is the header present?
15783echo "$as_me:$LINENO: checking $ac_header presence" >&5
15784echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15785cat >conftest.$ac_ext <<_ACEOF
15786#line $LINENO "configure"
cd958eb3
MB
15787/* confdefs.h. */
15788_ACEOF
15789cat confdefs.h >>conftest.$ac_ext
15790cat >>conftest.$ac_ext <<_ACEOF
15791/* end confdefs.h. */
503d2be0
AS
15792#include <$ac_header>
15793_ACEOF
c0d27fcc 15794if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15795 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15796 ac_status=$?
6bae0ccf 15797 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15798 rm -f conftest.er1
15799 cat conftest.err >&5
c0d27fcc 15800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15801 (exit $ac_status); } >/dev/null; then
15802 if test -s conftest.err; then
15803 ac_cpp_err=$ac_c_preproc_warn_flag
15804 else
15805 ac_cpp_err=
15806 fi
15807else
15808 ac_cpp_err=yes
15809fi
15810if test -z "$ac_cpp_err"; then
c0d27fcc 15811 ac_header_preproc=yes
503d2be0
AS
15812else
15813 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15814sed 's/^/| /' conftest.$ac_ext >&5
15815
c0d27fcc 15816 ac_header_preproc=no
a21616bd 15817fi
503d2be0 15818rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15819echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15820echo "${ECHO_T}$ac_header_preproc" >&6
15821
15822# So? What about this header?
15823case $ac_header_compiler:$ac_header_preproc in
15824 yes:no )
15825 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15826echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15827 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15828echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15829 (
15830 cat <<\_ASBOX
15831## ------------------------------------ ##
15832## Report this to bug-autoconf@gnu.org. ##
15833## ------------------------------------ ##
15834_ASBOX
15835 ) |
15836 sed "s/^/$as_me: WARNING: /" >&2
15837 ;;
c0d27fcc
MR
15838 no:yes )
15839 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15840echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15841 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15842echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15843 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15844echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15845 (
15846 cat <<\_ASBOX
15847## ------------------------------------ ##
15848## Report this to bug-autoconf@gnu.org. ##
15849## ------------------------------------ ##
15850_ASBOX
15851 ) |
15852 sed "s/^/$as_me: WARNING: /" >&2
15853 ;;
c0d27fcc
MR
15854esac
15855echo "$as_me:$LINENO: checking for $ac_header" >&5
15856echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15857if eval "test \"\${$as_ac_Header+set}\" = set"; then
15858 echo $ECHO_N "(cached) $ECHO_C" >&6
15859else
15860 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 15861fi
c0d27fcc 15862echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 15863echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
15864
15865fi
503d2be0 15866if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 15867 cat >>confdefs.h <<_ACEOF
503d2be0 15868#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 15869_ACEOF
503d2be0 15870
a21616bd 15871else
503d2be0
AS
15872
15873for ac_header in kerberos/krb.h
a21616bd 15874do
503d2be0 15875as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
15876if eval "test \"\${$as_ac_Header+set}\" = set"; then
15877 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
15878echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15879if eval "test \"\${$as_ac_Header+set}\" = set"; then
15880 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
15881fi
15882echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
15883echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 15884else
c0d27fcc
MR
15885 # Is the header compilable?
15886echo "$as_me:$LINENO: checking $ac_header usability" >&5
15887echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
15888cat >conftest.$ac_ext <<_ACEOF
15889#line $LINENO "configure"
cd958eb3
MB
15890/* confdefs.h. */
15891_ACEOF
15892cat confdefs.h >>conftest.$ac_ext
15893cat >>conftest.$ac_ext <<_ACEOF
15894/* end confdefs.h. */
c0d27fcc
MR
15895$ac_includes_default
15896#include <$ac_header>
15897_ACEOF
15898rm -f conftest.$ac_objext
15899if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15900 (eval $ac_compile) 2>&5
15901 ac_status=$?
15902 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15903 (exit $ac_status); } &&
15904 { ac_try='test -s conftest.$ac_objext'
15905 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15906 (eval $ac_try) 2>&5
15907 ac_status=$?
15908 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15909 (exit $ac_status); }; }; then
15910 ac_header_compiler=yes
15911else
15912 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15913sed 's/^/| /' conftest.$ac_ext >&5
15914
c0d27fcc
MR
15915ac_header_compiler=no
15916fi
15917rm -f conftest.$ac_objext conftest.$ac_ext
15918echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15919echo "${ECHO_T}$ac_header_compiler" >&6
15920
15921# Is the header present?
15922echo "$as_me:$LINENO: checking $ac_header presence" >&5
15923echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
15924cat >conftest.$ac_ext <<_ACEOF
15925#line $LINENO "configure"
cd958eb3
MB
15926/* confdefs.h. */
15927_ACEOF
15928cat confdefs.h >>conftest.$ac_ext
15929cat >>conftest.$ac_ext <<_ACEOF
15930/* end confdefs.h. */
503d2be0
AS
15931#include <$ac_header>
15932_ACEOF
c0d27fcc 15933if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
15934 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15935 ac_status=$?
6bae0ccf 15936 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
15937 rm -f conftest.er1
15938 cat conftest.err >&5
c0d27fcc 15939 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
15940 (exit $ac_status); } >/dev/null; then
15941 if test -s conftest.err; then
15942 ac_cpp_err=$ac_c_preproc_warn_flag
15943 else
15944 ac_cpp_err=
15945 fi
15946else
15947 ac_cpp_err=yes
15948fi
15949if test -z "$ac_cpp_err"; then
c0d27fcc 15950 ac_header_preproc=yes
503d2be0
AS
15951else
15952 echo "$as_me: failed program was:" >&5
cd958eb3
MB
15953sed 's/^/| /' conftest.$ac_ext >&5
15954
c0d27fcc 15955 ac_header_preproc=no
a21616bd 15956fi
503d2be0 15957rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
15958echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15959echo "${ECHO_T}$ac_header_preproc" >&6
15960
15961# So? What about this header?
15962case $ac_header_compiler:$ac_header_preproc in
15963 yes:no )
15964 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
15965echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
15966 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15967echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15968 (
15969 cat <<\_ASBOX
15970## ------------------------------------ ##
15971## Report this to bug-autoconf@gnu.org. ##
15972## ------------------------------------ ##
15973_ASBOX
15974 ) |
15975 sed "s/^/$as_me: WARNING: /" >&2
15976 ;;
c0d27fcc
MR
15977 no:yes )
15978 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
15979echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
15980 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
15981echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
15982 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
15983echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
15984 (
15985 cat <<\_ASBOX
15986## ------------------------------------ ##
15987## Report this to bug-autoconf@gnu.org. ##
15988## ------------------------------------ ##
15989_ASBOX
15990 ) |
15991 sed "s/^/$as_me: WARNING: /" >&2
15992 ;;
c0d27fcc
MR
15993esac
15994echo "$as_me:$LINENO: checking for $ac_header" >&5
15995echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
15996if eval "test \"\${$as_ac_Header+set}\" = set"; then
15997 echo $ECHO_N "(cached) $ECHO_C" >&6
15998else
15999 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 16000fi
c0d27fcc 16001echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 16002echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
16003
16004fi
503d2be0 16005if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 16006 cat >>confdefs.h <<_ACEOF
503d2be0 16007#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 16008_ACEOF
503d2be0 16009
a21616bd 16010fi
c0d27fcc 16011
a21616bd
KR
16012done
16013
16014fi
c0d27fcc 16015
a21616bd
KR
16016done
16017
16018fi
c0d27fcc 16019
a21616bd
KR
16020done
16021
16022 fi
503d2be0
AS
16023
16024for ac_header in com_err.h
a21616bd 16025do
503d2be0 16026as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
16027if eval "test \"\${$as_ac_Header+set}\" = set"; then
16028 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
16029echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16030if eval "test \"\${$as_ac_Header+set}\" = set"; then
16031 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16032fi
16033echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
16034echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 16035else
c0d27fcc
MR
16036 # Is the header compilable?
16037echo "$as_me:$LINENO: checking $ac_header usability" >&5
16038echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
16039cat >conftest.$ac_ext <<_ACEOF
16040#line $LINENO "configure"
cd958eb3
MB
16041/* confdefs.h. */
16042_ACEOF
16043cat confdefs.h >>conftest.$ac_ext
16044cat >>conftest.$ac_ext <<_ACEOF
16045/* end confdefs.h. */
c0d27fcc
MR
16046$ac_includes_default
16047#include <$ac_header>
16048_ACEOF
16049rm -f conftest.$ac_objext
16050if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16051 (eval $ac_compile) 2>&5
16052 ac_status=$?
16053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16054 (exit $ac_status); } &&
16055 { ac_try='test -s conftest.$ac_objext'
16056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16057 (eval $ac_try) 2>&5
16058 ac_status=$?
16059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16060 (exit $ac_status); }; }; then
16061 ac_header_compiler=yes
16062else
16063 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16064sed 's/^/| /' conftest.$ac_ext >&5
16065
c0d27fcc
MR
16066ac_header_compiler=no
16067fi
16068rm -f conftest.$ac_objext conftest.$ac_ext
16069echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16070echo "${ECHO_T}$ac_header_compiler" >&6
16071
16072# Is the header present?
16073echo "$as_me:$LINENO: checking $ac_header presence" >&5
16074echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
16075cat >conftest.$ac_ext <<_ACEOF
16076#line $LINENO "configure"
cd958eb3
MB
16077/* confdefs.h. */
16078_ACEOF
16079cat confdefs.h >>conftest.$ac_ext
16080cat >>conftest.$ac_ext <<_ACEOF
16081/* end confdefs.h. */
503d2be0
AS
16082#include <$ac_header>
16083_ACEOF
c0d27fcc 16084if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16085 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16086 ac_status=$?
6bae0ccf 16087 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16088 rm -f conftest.er1
16089 cat conftest.err >&5
c0d27fcc 16090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16091 (exit $ac_status); } >/dev/null; then
16092 if test -s conftest.err; then
16093 ac_cpp_err=$ac_c_preproc_warn_flag
16094 else
16095 ac_cpp_err=
16096 fi
16097else
16098 ac_cpp_err=yes
16099fi
16100if test -z "$ac_cpp_err"; then
c0d27fcc 16101 ac_header_preproc=yes
503d2be0
AS
16102else
16103 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16104sed 's/^/| /' conftest.$ac_ext >&5
16105
c0d27fcc 16106 ac_header_preproc=no
a21616bd 16107fi
503d2be0 16108rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16109echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16110echo "${ECHO_T}$ac_header_preproc" >&6
16111
16112# So? What about this header?
16113case $ac_header_compiler:$ac_header_preproc in
16114 yes:no )
16115 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16116echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16117 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16118echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16119 (
16120 cat <<\_ASBOX
16121## ------------------------------------ ##
16122## Report this to bug-autoconf@gnu.org. ##
16123## ------------------------------------ ##
16124_ASBOX
16125 ) |
16126 sed "s/^/$as_me: WARNING: /" >&2
16127 ;;
c0d27fcc
MR
16128 no:yes )
16129 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16130echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16131 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
16132echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
16133 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16134echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16135 (
16136 cat <<\_ASBOX
16137## ------------------------------------ ##
16138## Report this to bug-autoconf@gnu.org. ##
16139## ------------------------------------ ##
16140_ASBOX
16141 ) |
16142 sed "s/^/$as_me: WARNING: /" >&2
16143 ;;
c0d27fcc
MR
16144esac
16145echo "$as_me:$LINENO: checking for $ac_header" >&5
16146echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16147if eval "test \"\${$as_ac_Header+set}\" = set"; then
16148 echo $ECHO_N "(cached) $ECHO_C" >&6
16149else
16150 eval "$as_ac_Header=$ac_header_preproc"
a21616bd 16151fi
c0d27fcc 16152echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 16153echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
16154
16155fi
503d2be0 16156if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 16157 cat >>confdefs.h <<_ACEOF
503d2be0 16158#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 16159_ACEOF
503d2be0 16160
a21616bd 16161fi
c0d27fcc 16162
a21616bd
KR
16163done
16164
16165fi
16166
ba4481b5
DL
16167# Solaris requires -lintl if you want strerror (which calls dgettext)
16168# to return localized messages.
503d2be0 16169
c0d27fcc 16170echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5
503d2be0
AS
16171echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6
16172if test "${ac_cv_lib_intl_dgettext+set}" = set; then
16173 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16174else
503d2be0 16175 ac_check_lib_save_LIBS=$LIBS
ba4481b5 16176LIBS="-lintl $LIBS"
503d2be0 16177cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16178#line $LINENO "configure"
cd958eb3
MB
16179/* confdefs.h. */
16180_ACEOF
16181cat confdefs.h >>conftest.$ac_ext
16182cat >>conftest.$ac_ext <<_ACEOF
16183/* end confdefs.h. */
503d2be0 16184
ba4481b5 16185/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16186#ifdef __cplusplus
16187extern "C"
16188#endif
ba4481b5 16189/* We use char because int might match the return type of a gcc2
503d2be0
AS
16190 builtin and then its argument prototype would still apply. */
16191char dgettext ();
16192int
16193main ()
16194{
16195dgettext ();
16196 ;
16197 return 0;
16198}
16199_ACEOF
16200rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16201if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16202 (eval $ac_link) 2>&5
16203 ac_status=$?
c0d27fcc 16204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16205 (exit $ac_status); } &&
16206 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16208 (eval $ac_try) 2>&5
16209 ac_status=$?
c0d27fcc 16210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16211 (exit $ac_status); }; }; then
16212 ac_cv_lib_intl_dgettext=yes
16213else
16214 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16215sed 's/^/| /' conftest.$ac_ext >&5
16216
503d2be0
AS
16217ac_cv_lib_intl_dgettext=no
16218fi
16219rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16220LIBS=$ac_check_lib_save_LIBS
16221fi
c0d27fcc 16222echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5
503d2be0
AS
16223echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6
16224if test $ac_cv_lib_intl_dgettext = yes; then
c0d27fcc 16225 cat >>confdefs.h <<_ACEOF
503d2be0 16226#define HAVE_LIBINTL 1
c0d27fcc 16227_ACEOF
ba4481b5
DL
16228
16229 LIBS="-lintl $LIBS"
16230
ba4481b5
DL
16231fi
16232
c0d27fcc
MR
16233
16234echo "$as_me:$LINENO: checking whether localtime caches TZ" >&5
503d2be0
AS
16235echo $ECHO_N "checking whether localtime caches TZ... $ECHO_C" >&6
16236if test "${emacs_cv_localtime_cache+set}" = set; then
16237 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5
DL
16238else
16239 if test x$ac_cv_func_tzset = xyes; then
16240if test "$cross_compiling" = yes; then
16241 # If we have tzset, assume the worst when cross-compiling.
16242emacs_cv_localtime_cache=yes
16243else
503d2be0 16244 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16245#line $LINENO "configure"
cd958eb3
MB
16246/* confdefs.h. */
16247_ACEOF
16248cat confdefs.h >>conftest.$ac_ext
16249cat >>conftest.$ac_ext <<_ACEOF
16250/* end confdefs.h. */
ba4481b5 16251#include <time.h>
ba4481b5
DL
16252extern char **environ;
16253unset_TZ ()
16254{
16255 char **from, **to;
16256 for (to = from = environ; (*to = *from); from++)
16257 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
16258 to++;
16259}
16260char TZ_GMT0[] = "TZ=GMT0";
16261char TZ_PST8[] = "TZ=PST8";
16262main()
16263{
16264 time_t now = time ((time_t *) 0);
16265 int hour_GMT0, hour_unset;
16266 if (putenv (TZ_GMT0) != 0)
16267 exit (1);
16268 hour_GMT0 = localtime (&now)->tm_hour;
16269 unset_TZ ();
16270 hour_unset = localtime (&now)->tm_hour;
16271 if (putenv (TZ_PST8) != 0)
16272 exit (1);
16273 if (localtime (&now)->tm_hour == hour_GMT0)
16274 exit (1);
16275 unset_TZ ();
16276 if (localtime (&now)->tm_hour != hour_unset)
16277 exit (1);
16278 exit (0);
16279}
503d2be0
AS
16280_ACEOF
16281rm -f conftest$ac_exeext
c0d27fcc 16282if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16283 (eval $ac_link) 2>&5
16284 ac_status=$?
c0d27fcc 16285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16286 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 16287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16288 (eval $ac_try) 2>&5
16289 ac_status=$?
c0d27fcc 16290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16291 (exit $ac_status); }; }; then
ba4481b5
DL
16292 emacs_cv_localtime_cache=no
16293else
503d2be0
AS
16294 echo "$as_me: program exited with status $ac_status" >&5
16295echo "$as_me: failed program was:" >&5
cd958eb3
MB
16296sed 's/^/| /' conftest.$ac_ext >&5
16297
c0d27fcc 16298( exit $ac_status )
503d2be0 16299emacs_cv_localtime_cache=yes
ba4481b5 16300fi
6bae0ccf 16301rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
ba4481b5 16302fi
ba4481b5
DL
16303else
16304 # If we lack tzset, report that localtime does not cache TZ,
16305 # since we can't invalidate the cache if we don't have tzset.
16306 emacs_cv_localtime_cache=no
16307fi
16308fi
c0d27fcc 16309echo "$as_me:$LINENO: result: $emacs_cv_localtime_cache" >&5
503d2be0 16310echo "${ECHO_T}$emacs_cv_localtime_cache" >&6
ba4481b5 16311if test $emacs_cv_localtime_cache = yes; then
b936fae4 16312
c0d27fcc 16313cat >>confdefs.h <<\_ACEOF
ba4481b5 16314#define LOCALTIME_CACHE 1
c0d27fcc 16315_ACEOF
ba4481b5
DL
16316
16317fi
16318
16319if test "x$HAVE_TIMEVAL" = xyes; then
503d2be0
AS
16320
16321for ac_func in gettimeofday
48d4b120 16322do
503d2be0 16323as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 16324echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
16325echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16326if eval "test \"\${$as_ac_var+set}\" = set"; then
16327 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 16328else
503d2be0 16329 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16330#line $LINENO "configure"
cd958eb3
MB
16331/* confdefs.h. */
16332_ACEOF
16333cat confdefs.h >>conftest.$ac_ext
16334cat >>conftest.$ac_ext <<_ACEOF
16335/* end confdefs.h. */
48d4b120 16336/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
16337 which can conflict with char $ac_func (); below.
16338 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16339 <limits.h> exists even on freestanding compilers. */
16340#ifdef __STDC__
16341# include <limits.h>
16342#else
16343# include <assert.h>
16344#endif
48d4b120 16345/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16346#ifdef __cplusplus
16347extern "C"
cd958eb3 16348{
503d2be0 16349#endif
48d4b120 16350/* We use char because int might match the return type of a gcc2
503d2be0
AS
16351 builtin and then its argument prototype would still apply. */
16352char $ac_func ();
48d4b120
DL
16353/* The GNU C library defines this for functions which it implements
16354 to always fail with ENOSYS. Some functions are actually named
16355 something starting with __ and the normal name is an alias. */
16356#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16357choke me
16358#else
cd958eb3 16359char (*f) () = $ac_func;
48d4b120 16360#endif
cd958eb3
MB
16361#ifdef __cplusplus
16362}
16363#endif
16364
16365int
16366main ()
16367{
9e71690e 16368return f != $ac_func;
503d2be0
AS
16369 ;
16370 return 0;
16371}
16372_ACEOF
16373rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16374if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16375 (eval $ac_link) 2>&5
16376 ac_status=$?
c0d27fcc 16377 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16378 (exit $ac_status); } &&
16379 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16381 (eval $ac_try) 2>&5
16382 ac_status=$?
c0d27fcc 16383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16384 (exit $ac_status); }; }; then
16385 eval "$as_ac_var=yes"
16386else
16387 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16388sed 's/^/| /' conftest.$ac_ext >&5
16389
503d2be0
AS
16390eval "$as_ac_var=no"
16391fi
16392rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16393fi
c0d27fcc 16394echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
16395echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16396if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 16397 cat >>confdefs.h <<_ACEOF
503d2be0 16398#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 16399_ACEOF
48d4b120 16400
48d4b120
DL
16401fi
16402done
16403
b936fae4 16404 if test $ac_cv_func_gettimeofday = yes; then
c0d27fcc 16405 echo "$as_me:$LINENO: checking whether gettimeofday can accept two arguments" >&5
503d2be0
AS
16406echo $ECHO_N "checking whether gettimeofday can accept two arguments... $ECHO_C" >&6
16407if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then
16408 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16409else
503d2be0 16410 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16411#line $LINENO "configure"
cd958eb3
MB
16412/* confdefs.h. */
16413_ACEOF
16414cat confdefs.h >>conftest.$ac_ext
16415cat >>conftest.$ac_ext <<_ACEOF
16416/* end confdefs.h. */
ba4481b5 16417
a3f08d9e
DL
16418#ifdef TIME_WITH_SYS_TIME
16419#include <sys/time.h>
16420#include <time.h>
16421#else
16422#ifdef HAVE_SYS_TIME_H
16423#include <sys/time.h>
16424#else
16425#include <time.h>
16426#endif
16427#endif
503d2be0
AS
16428int
16429main ()
16430{
a3f08d9e 16431struct timeval time;
b936fae4 16432 gettimeofday (&time, 0);
503d2be0
AS
16433 ;
16434 return 0;
16435}
16436_ACEOF
16437rm -f conftest.$ac_objext
c0d27fcc 16438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16439 (eval $ac_compile) 2>&5
16440 ac_status=$?
c0d27fcc 16441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16442 (exit $ac_status); } &&
16443 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16445 (eval $ac_try) 2>&5
16446 ac_status=$?
c0d27fcc 16447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16448 (exit $ac_status); }; }; then
ba4481b5
DL
16449 emacs_cv_gettimeofday_two_arguments=yes
16450else
503d2be0 16451 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16452sed 's/^/| /' conftest.$ac_ext >&5
16453
503d2be0 16454emacs_cv_gettimeofday_two_arguments=no
ba4481b5 16455fi
503d2be0 16456rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 16457fi
c0d27fcc 16458echo "$as_me:$LINENO: result: $emacs_cv_gettimeofday_two_arguments" >&5
503d2be0 16459echo "${ECHO_T}$emacs_cv_gettimeofday_two_arguments" >&6
b936fae4
AS
16460 if test $emacs_cv_gettimeofday_two_arguments = no; then
16461
c0d27fcc 16462cat >>confdefs.h <<\_ACEOF
ba4481b5 16463#define GETTIMEOFDAY_ONE_ARGUMENT 1
c0d27fcc 16464_ACEOF
ba4481b5 16465
b936fae4 16466 fi
ba4481b5
DL
16467 fi
16468fi
16469
48d4b120 16470if test "$ac_cv_func_gettimeofday" = yes; then
c0d27fcc 16471 echo "$as_me:$LINENO: checking for struct timezone" >&5
503d2be0
AS
16472echo $ECHO_N "checking for struct timezone... $ECHO_C" >&6
16473if test "${emacs_cv_struct_timezone+set}" = set; then
16474 echo $ECHO_N "(cached) $ECHO_C" >&6
48d4b120 16475else
503d2be0 16476 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16477#line $LINENO "configure"
cd958eb3
MB
16478/* confdefs.h. */
16479_ACEOF
16480cat confdefs.h >>conftest.$ac_ext
16481cat >>conftest.$ac_ext <<_ACEOF
16482/* end confdefs.h. */
48d4b120 16483#include <sys/time.h>
503d2be0
AS
16484int
16485main ()
16486{
48d4b120 16487struct timezone tz;
503d2be0
AS
16488 ;
16489 return 0;
16490}
16491_ACEOF
16492rm -f conftest.$ac_objext
c0d27fcc 16493if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16494 (eval $ac_compile) 2>&5
16495 ac_status=$?
c0d27fcc 16496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16497 (exit $ac_status); } &&
16498 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16499 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16500 (eval $ac_try) 2>&5
16501 ac_status=$?
c0d27fcc 16502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16503 (exit $ac_status); }; }; then
48d4b120
DL
16504 if test "$cross_compiling" = yes; then
16505 emacs_cv_struct_timezone=yes
16506else
503d2be0 16507 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16508#line $LINENO "configure"
cd958eb3
MB
16509/* confdefs.h. */
16510_ACEOF
16511cat confdefs.h >>conftest.$ac_ext
16512cat >>conftest.$ac_ext <<_ACEOF
16513/* end confdefs.h. */
48d4b120
DL
16514
16515#ifdef TIME_WITH_SYS_TIME
16516#include <sys/time.h>
16517#include <time.h>
16518#else
16519#ifdef HAVE_SYS_TIME_H
16520#include <sys/time.h>
16521#else
16522#include <time.h>
16523#endif
16524#endif
16525main () {
16526 struct timeval time;
16527 struct timezone dummy;
16528 exit (gettimeofday (&time, &dummy));
16529}
503d2be0
AS
16530_ACEOF
16531rm -f conftest$ac_exeext
c0d27fcc 16532if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16533 (eval $ac_link) 2>&5
16534 ac_status=$?
c0d27fcc 16535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16536 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 16537 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16538 (eval $ac_try) 2>&5
16539 ac_status=$?
c0d27fcc 16540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16541 (exit $ac_status); }; }; then
48d4b120
DL
16542 emacs_cv_struct_timezone=yes
16543else
503d2be0
AS
16544 echo "$as_me: program exited with status $ac_status" >&5
16545echo "$as_me: failed program was:" >&5
cd958eb3
MB
16546sed 's/^/| /' conftest.$ac_ext >&5
16547
c0d27fcc 16548( exit $ac_status )
503d2be0 16549emacs_cv_struct_timezone=no
48d4b120 16550fi
6bae0ccf 16551rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
48d4b120 16552fi
48d4b120 16553else
503d2be0 16554 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16555sed 's/^/| /' conftest.$ac_ext >&5
16556
503d2be0 16557emacs_cv_struct_timezone=no
48d4b120 16558fi
503d2be0 16559rm -f conftest.$ac_objext conftest.$ac_ext
48d4b120 16560fi
c0d27fcc 16561echo "$as_me:$LINENO: result: $emacs_cv_struct_timezone" >&5
503d2be0 16562echo "${ECHO_T}$emacs_cv_struct_timezone" >&6
48d4b120
DL
16563fi
16564
ba4481b5 16565ok_so_far=yes
c0d27fcc 16566echo "$as_me:$LINENO: checking for socket" >&5
503d2be0
AS
16567echo $ECHO_N "checking for socket... $ECHO_C" >&6
16568if test "${ac_cv_func_socket+set}" = set; then
16569 echo $ECHO_N "(cached) $ECHO_C" >&6
ba4481b5 16570else
503d2be0 16571 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16572#line $LINENO "configure"
cd958eb3
MB
16573/* confdefs.h. */
16574_ACEOF
16575cat confdefs.h >>conftest.$ac_ext
16576cat >>conftest.$ac_ext <<_ACEOF
16577/* end confdefs.h. */
ba4481b5 16578/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
16579 which can conflict with char socket (); below.
16580 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16581 <limits.h> exists even on freestanding compilers. */
16582#ifdef __STDC__
16583# include <limits.h>
16584#else
16585# include <assert.h>
16586#endif
ba4481b5 16587/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
16588#ifdef __cplusplus
16589extern "C"
cd958eb3 16590{
503d2be0 16591#endif
ba4481b5 16592/* We use char because int might match the return type of a gcc2
503d2be0
AS
16593 builtin and then its argument prototype would still apply. */
16594char socket ();
ba4481b5
DL
16595/* The GNU C library defines this for functions which it implements
16596 to always fail with ENOSYS. Some functions are actually named
16597 something starting with __ and the normal name is an alias. */
16598#if defined (__stub_socket) || defined (__stub___socket)
16599choke me
16600#else
cd958eb3 16601char (*f) () = socket;
ba4481b5 16602#endif
cd958eb3
MB
16603#ifdef __cplusplus
16604}
16605#endif
16606
16607int
16608main ()
16609{
9e71690e 16610return f != socket;
503d2be0
AS
16611 ;
16612 return 0;
16613}
16614_ACEOF
16615rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 16616if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
16617 (eval $ac_link) 2>&5
16618 ac_status=$?
c0d27fcc 16619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16620 (exit $ac_status); } &&
16621 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 16622 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16623 (eval $ac_try) 2>&5
16624 ac_status=$?
c0d27fcc 16625 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16626 (exit $ac_status); }; }; then
16627 ac_cv_func_socket=yes
16628else
16629 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16630sed 's/^/| /' conftest.$ac_ext >&5
16631
503d2be0
AS
16632ac_cv_func_socket=no
16633fi
16634rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16635fi
c0d27fcc 16636echo "$as_me:$LINENO: result: $ac_cv_func_socket" >&5
503d2be0
AS
16637echo "${ECHO_T}$ac_cv_func_socket" >&6
16638if test $ac_cv_func_socket = yes; then
ba4481b5
DL
16639 :
16640else
503d2be0 16641 ok_so_far=no
ba4481b5
DL
16642fi
16643
16644if test $ok_so_far = yes; then
c0d27fcc
MR
16645 if test "${ac_cv_header_netinet_in_h+set}" = set; then
16646 echo "$as_me:$LINENO: checking for netinet/in.h" >&5
503d2be0
AS
16647echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
16648if test "${ac_cv_header_netinet_in_h+set}" = set; then
16649 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16650fi
16651echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
16652echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
98418dba 16653else
c0d27fcc
MR
16654 # Is the header compilable?
16655echo "$as_me:$LINENO: checking netinet/in.h usability" >&5
16656echo $ECHO_N "checking netinet/in.h usability... $ECHO_C" >&6
16657cat >conftest.$ac_ext <<_ACEOF
16658#line $LINENO "configure"
cd958eb3
MB
16659/* confdefs.h. */
16660_ACEOF
16661cat confdefs.h >>conftest.$ac_ext
16662cat >>conftest.$ac_ext <<_ACEOF
16663/* end confdefs.h. */
c0d27fcc
MR
16664$ac_includes_default
16665#include <netinet/in.h>
16666_ACEOF
16667rm -f conftest.$ac_objext
16668if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16669 (eval $ac_compile) 2>&5
16670 ac_status=$?
16671 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16672 (exit $ac_status); } &&
16673 { ac_try='test -s conftest.$ac_objext'
16674 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16675 (eval $ac_try) 2>&5
16676 ac_status=$?
16677 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16678 (exit $ac_status); }; }; then
16679 ac_header_compiler=yes
16680else
16681 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16682sed 's/^/| /' conftest.$ac_ext >&5
16683
c0d27fcc
MR
16684ac_header_compiler=no
16685fi
16686rm -f conftest.$ac_objext conftest.$ac_ext
16687echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16688echo "${ECHO_T}$ac_header_compiler" >&6
16689
16690# Is the header present?
16691echo "$as_me:$LINENO: checking netinet/in.h presence" >&5
16692echo $ECHO_N "checking netinet/in.h presence... $ECHO_C" >&6
16693cat >conftest.$ac_ext <<_ACEOF
16694#line $LINENO "configure"
cd958eb3
MB
16695/* confdefs.h. */
16696_ACEOF
16697cat confdefs.h >>conftest.$ac_ext
16698cat >>conftest.$ac_ext <<_ACEOF
16699/* end confdefs.h. */
ba4481b5 16700#include <netinet/in.h>
503d2be0 16701_ACEOF
c0d27fcc 16702if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16703 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16704 ac_status=$?
6bae0ccf 16705 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16706 rm -f conftest.er1
16707 cat conftest.err >&5
c0d27fcc 16708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16709 (exit $ac_status); } >/dev/null; then
16710 if test -s conftest.err; then
16711 ac_cpp_err=$ac_c_preproc_warn_flag
16712 else
16713 ac_cpp_err=
16714 fi
16715else
16716 ac_cpp_err=yes
16717fi
16718if test -z "$ac_cpp_err"; then
c0d27fcc 16719 ac_header_preproc=yes
ba4481b5 16720else
503d2be0 16721 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16722sed 's/^/| /' conftest.$ac_ext >&5
16723
c0d27fcc 16724 ac_header_preproc=no
ba4481b5 16725fi
503d2be0 16726rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16727echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16728echo "${ECHO_T}$ac_header_preproc" >&6
16729
16730# So? What about this header?
16731case $ac_header_compiler:$ac_header_preproc in
16732 yes:no )
16733 { echo "$as_me:$LINENO: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&5
16734echo "$as_me: WARNING: netinet/in.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16735 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16736echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
16737 (
16738 cat <<\_ASBOX
16739## ------------------------------------ ##
16740## Report this to bug-autoconf@gnu.org. ##
16741## ------------------------------------ ##
16742_ASBOX
16743 ) |
16744 sed "s/^/$as_me: WARNING: /" >&2
16745 ;;
c0d27fcc
MR
16746 no:yes )
16747 { echo "$as_me:$LINENO: WARNING: netinet/in.h: present but cannot be compiled" >&5
16748echo "$as_me: WARNING: netinet/in.h: present but cannot be compiled" >&2;}
16749 { echo "$as_me:$LINENO: WARNING: netinet/in.h: check for missing prerequisite headers?" >&5
16750echo "$as_me: WARNING: netinet/in.h: check for missing prerequisite headers?" >&2;}
16751 { echo "$as_me:$LINENO: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16752echo "$as_me: WARNING: netinet/in.h: proceeding with the preprocessor's result" >&2;}
16753 (
16754 cat <<\_ASBOX
16755## ------------------------------------ ##
16756## Report this to bug-autoconf@gnu.org. ##
16757## ------------------------------------ ##
16758_ASBOX
16759 ) |
16760 sed "s/^/$as_me: WARNING: /" >&2
16761 ;;
c0d27fcc
MR
16762esac
16763echo "$as_me:$LINENO: checking for netinet/in.h" >&5
16764echo $ECHO_N "checking for netinet/in.h... $ECHO_C" >&6
16765if test "${ac_cv_header_netinet_in_h+set}" = set; then
16766 echo $ECHO_N "(cached) $ECHO_C" >&6
16767else
16768 ac_cv_header_netinet_in_h=$ac_header_preproc
ba4481b5 16769fi
c0d27fcc 16770echo "$as_me:$LINENO: result: $ac_cv_header_netinet_in_h" >&5
503d2be0 16771echo "${ECHO_T}$ac_cv_header_netinet_in_h" >&6
c0d27fcc
MR
16772
16773fi
503d2be0 16774if test $ac_cv_header_netinet_in_h = yes; then
ba4481b5
DL
16775 :
16776else
503d2be0 16777 ok_so_far=no
ba4481b5
DL
16778fi
16779
c0d27fcc 16780
ba4481b5
DL
16781fi
16782if test $ok_so_far = yes; then
c0d27fcc
MR
16783 if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16784 echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
503d2be0
AS
16785echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
16786if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16787 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
16788fi
16789echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
16790echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
98418dba 16791else
c0d27fcc
MR
16792 # Is the header compilable?
16793echo "$as_me:$LINENO: checking arpa/inet.h usability" >&5
16794echo $ECHO_N "checking arpa/inet.h usability... $ECHO_C" >&6
16795cat >conftest.$ac_ext <<_ACEOF
16796#line $LINENO "configure"
cd958eb3
MB
16797/* confdefs.h. */
16798_ACEOF
16799cat confdefs.h >>conftest.$ac_ext
16800cat >>conftest.$ac_ext <<_ACEOF
16801/* end confdefs.h. */
c0d27fcc
MR
16802$ac_includes_default
16803#include <arpa/inet.h>
16804_ACEOF
16805rm -f conftest.$ac_objext
16806if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16807 (eval $ac_compile) 2>&5
16808 ac_status=$?
16809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16810 (exit $ac_status); } &&
16811 { ac_try='test -s conftest.$ac_objext'
16812 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16813 (eval $ac_try) 2>&5
16814 ac_status=$?
16815 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16816 (exit $ac_status); }; }; then
16817 ac_header_compiler=yes
16818else
16819 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16820sed 's/^/| /' conftest.$ac_ext >&5
16821
c0d27fcc
MR
16822ac_header_compiler=no
16823fi
16824rm -f conftest.$ac_objext conftest.$ac_ext
16825echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16826echo "${ECHO_T}$ac_header_compiler" >&6
16827
16828# Is the header present?
16829echo "$as_me:$LINENO: checking arpa/inet.h presence" >&5
16830echo $ECHO_N "checking arpa/inet.h presence... $ECHO_C" >&6
16831cat >conftest.$ac_ext <<_ACEOF
16832#line $LINENO "configure"
cd958eb3
MB
16833/* confdefs.h. */
16834_ACEOF
16835cat confdefs.h >>conftest.$ac_ext
16836cat >>conftest.$ac_ext <<_ACEOF
16837/* end confdefs.h. */
ba4481b5 16838#include <arpa/inet.h>
503d2be0 16839_ACEOF
c0d27fcc 16840if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
16841 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16842 ac_status=$?
6bae0ccf 16843 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
16844 rm -f conftest.er1
16845 cat conftest.err >&5
c0d27fcc 16846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16847 (exit $ac_status); } >/dev/null; then
16848 if test -s conftest.err; then
16849 ac_cpp_err=$ac_c_preproc_warn_flag
16850 else
16851 ac_cpp_err=
16852 fi
16853else
16854 ac_cpp_err=yes
16855fi
16856if test -z "$ac_cpp_err"; then
c0d27fcc 16857 ac_header_preproc=yes
ba4481b5 16858else
503d2be0 16859 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16860sed 's/^/| /' conftest.$ac_ext >&5
16861
c0d27fcc 16862 ac_header_preproc=no
ba4481b5 16863fi
503d2be0 16864rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
16865echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16866echo "${ECHO_T}$ac_header_preproc" >&6
16867
16868# So? What about this header?
16869case $ac_header_compiler:$ac_header_preproc in
16870 yes:no )
16871 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&5
16872echo "$as_me: WARNING: arpa/inet.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16873 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16874echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
16875 (
16876 cat <<\_ASBOX
16877## ------------------------------------ ##
16878## Report this to bug-autoconf@gnu.org. ##
16879## ------------------------------------ ##
16880_ASBOX
16881 ) |
16882 sed "s/^/$as_me: WARNING: /" >&2
16883 ;;
c0d27fcc
MR
16884 no:yes )
16885 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: present but cannot be compiled" >&5
16886echo "$as_me: WARNING: arpa/inet.h: present but cannot be compiled" >&2;}
16887 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&5
16888echo "$as_me: WARNING: arpa/inet.h: check for missing prerequisite headers?" >&2;}
16889 { echo "$as_me:$LINENO: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&5
cd958eb3
MB
16890echo "$as_me: WARNING: arpa/inet.h: proceeding with the preprocessor's result" >&2;}
16891 (
16892 cat <<\_ASBOX
16893## ------------------------------------ ##
16894## Report this to bug-autoconf@gnu.org. ##
16895## ------------------------------------ ##
16896_ASBOX
16897 ) |
16898 sed "s/^/$as_me: WARNING: /" >&2
16899 ;;
c0d27fcc
MR
16900esac
16901echo "$as_me:$LINENO: checking for arpa/inet.h" >&5
16902echo $ECHO_N "checking for arpa/inet.h... $ECHO_C" >&6
16903if test "${ac_cv_header_arpa_inet_h+set}" = set; then
16904 echo $ECHO_N "(cached) $ECHO_C" >&6
16905else
16906 ac_cv_header_arpa_inet_h=$ac_header_preproc
ba4481b5 16907fi
c0d27fcc 16908echo "$as_me:$LINENO: result: $ac_cv_header_arpa_inet_h" >&5
503d2be0 16909echo "${ECHO_T}$ac_cv_header_arpa_inet_h" >&6
c0d27fcc
MR
16910
16911fi
503d2be0 16912if test $ac_cv_header_arpa_inet_h = yes; then
ba4481b5
DL
16913 :
16914else
503d2be0 16915 ok_so_far=no
ba4481b5
DL
16916fi
16917
c0d27fcc 16918
ba4481b5
DL
16919fi
16920if test $ok_so_far = yes; then
b936fae4 16921
c0d27fcc 16922cat >>confdefs.h <<\_ACEOF
ba4481b5 16923#define HAVE_INET_SOCKETS 1
c0d27fcc 16924_ACEOF
ba4481b5
DL
16925
16926fi
16927
16928if test -f /usr/lpp/X11/bin/smt.exp; then
b936fae4 16929
c0d27fcc 16930cat >>confdefs.h <<\_ACEOF
ba4481b5 16931#define HAVE_AIX_SMT_EXP 1
c0d27fcc 16932_ACEOF
ba4481b5
DL
16933
16934fi
16935
c0d27fcc 16936echo "$as_me:$LINENO: checking whether system supports dynamic ptys" >&5
503d2be0 16937echo $ECHO_N "checking whether system supports dynamic ptys... $ECHO_C" >&6
3d9fec71 16938if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
c0d27fcc 16939 echo "$as_me:$LINENO: result: yes" >&5
503d2be0 16940echo "${ECHO_T}yes" >&6
b936fae4 16941
c0d27fcc 16942cat >>confdefs.h <<\_ACEOF
3d9fec71 16943#define HAVE_DEV_PTMX 1
c0d27fcc 16944_ACEOF
3d9fec71
DL
16945
16946else
c0d27fcc 16947 echo "$as_me:$LINENO: result: no" >&5
503d2be0 16948echo "${ECHO_T}no" >&6
3d9fec71
DL
16949fi
16950
c0d27fcc 16951echo "$as_me:$LINENO: checking for pid_t" >&5
503d2be0
AS
16952echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
16953if test "${ac_cv_type_pid_t+set}" = set; then
16954 echo $ECHO_N "(cached) $ECHO_C" >&6
647847ea 16955else
503d2be0 16956 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 16957#line $LINENO "configure"
cd958eb3
MB
16958/* confdefs.h. */
16959_ACEOF
16960cat confdefs.h >>conftest.$ac_ext
16961cat >>conftest.$ac_ext <<_ACEOF
16962/* end confdefs.h. */
503d2be0
AS
16963$ac_includes_default
16964int
16965main ()
16966{
16967if ((pid_t *) 0)
16968 return 0;
16969if (sizeof (pid_t))
16970 return 0;
16971 ;
16972 return 0;
16973}
16974_ACEOF
16975rm -f conftest.$ac_objext
c0d27fcc 16976if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
16977 (eval $ac_compile) 2>&5
16978 ac_status=$?
c0d27fcc 16979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
16980 (exit $ac_status); } &&
16981 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 16982 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
16983 (eval $ac_try) 2>&5
16984 ac_status=$?
c0d27fcc 16985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 16986 (exit $ac_status); }; }; then
647847ea
DL
16987 ac_cv_type_pid_t=yes
16988else
503d2be0 16989 echo "$as_me: failed program was:" >&5
cd958eb3
MB
16990sed 's/^/| /' conftest.$ac_ext >&5
16991
503d2be0 16992ac_cv_type_pid_t=no
647847ea 16993fi
503d2be0 16994rm -f conftest.$ac_objext conftest.$ac_ext
647847ea 16995fi
c0d27fcc 16996echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
503d2be0
AS
16997echo "${ECHO_T}$ac_cv_type_pid_t" >&6
16998if test $ac_cv_type_pid_t = yes; then
16999 :
17000else
17001
c0d27fcc 17002cat >>confdefs.h <<_ACEOF
647847ea 17003#define pid_t int
c0d27fcc 17004_ACEOF
647847ea
DL
17005
17006fi
17007
c0d27fcc
MR
17008
17009
503d2be0
AS
17010for ac_header in unistd.h vfork.h
17011do
17012as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17013if eval "test \"\${$as_ac_Header+set}\" = set"; then
17014 echo "$as_me:$LINENO: checking for $ac_header" >&5
503d2be0
AS
17015echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17016if eval "test \"\${$as_ac_Header+set}\" = set"; then
17017 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17018fi
17019echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17020echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17021else
c0d27fcc
MR
17022 # Is the header compilable?
17023echo "$as_me:$LINENO: checking $ac_header usability" >&5
17024echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17025cat >conftest.$ac_ext <<_ACEOF
17026#line $LINENO "configure"
cd958eb3
MB
17027/* confdefs.h. */
17028_ACEOF
17029cat confdefs.h >>conftest.$ac_ext
17030cat >>conftest.$ac_ext <<_ACEOF
17031/* end confdefs.h. */
c0d27fcc
MR
17032$ac_includes_default
17033#include <$ac_header>
17034_ACEOF
17035rm -f conftest.$ac_objext
17036if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17037 (eval $ac_compile) 2>&5
17038 ac_status=$?
17039 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17040 (exit $ac_status); } &&
17041 { ac_try='test -s conftest.$ac_objext'
17042 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17043 (eval $ac_try) 2>&5
17044 ac_status=$?
17045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17046 (exit $ac_status); }; }; then
17047 ac_header_compiler=yes
17048else
17049 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17050sed 's/^/| /' conftest.$ac_ext >&5
17051
c0d27fcc
MR
17052ac_header_compiler=no
17053fi
17054rm -f conftest.$ac_objext conftest.$ac_ext
17055echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17056echo "${ECHO_T}$ac_header_compiler" >&6
17057
17058# Is the header present?
17059echo "$as_me:$LINENO: checking $ac_header presence" >&5
17060echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17061cat >conftest.$ac_ext <<_ACEOF
17062#line $LINENO "configure"
cd958eb3
MB
17063/* confdefs.h. */
17064_ACEOF
17065cat confdefs.h >>conftest.$ac_ext
17066cat >>conftest.$ac_ext <<_ACEOF
17067/* end confdefs.h. */
503d2be0
AS
17068#include <$ac_header>
17069_ACEOF
c0d27fcc 17070if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
503d2be0
AS
17071 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17072 ac_status=$?
6bae0ccf 17073 grep -v '^ *+' conftest.er1 >conftest.err
503d2be0
AS
17074 rm -f conftest.er1
17075 cat conftest.err >&5
c0d27fcc 17076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17077 (exit $ac_status); } >/dev/null; then
17078 if test -s conftest.err; then
17079 ac_cpp_err=$ac_c_preproc_warn_flag
17080 else
17081 ac_cpp_err=
17082 fi
647847ea 17083else
503d2be0
AS
17084 ac_cpp_err=yes
17085fi
17086if test -z "$ac_cpp_err"; then
c0d27fcc 17087 ac_header_preproc=yes
647847ea 17088else
503d2be0 17089 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17090sed 's/^/| /' conftest.$ac_ext >&5
17091
c0d27fcc 17092 ac_header_preproc=no
647847ea 17093fi
503d2be0 17094rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17095echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17096echo "${ECHO_T}$ac_header_preproc" >&6
17097
17098# So? What about this header?
17099case $ac_header_compiler:$ac_header_preproc in
17100 yes:no )
17101 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17102echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17103 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17104echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17105 (
17106 cat <<\_ASBOX
17107## ------------------------------------ ##
17108## Report this to bug-autoconf@gnu.org. ##
17109## ------------------------------------ ##
17110_ASBOX
17111 ) |
17112 sed "s/^/$as_me: WARNING: /" >&2
17113 ;;
c0d27fcc
MR
17114 no:yes )
17115 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17116echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17117 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17118echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17119 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17120echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17121 (
17122 cat <<\_ASBOX
17123## ------------------------------------ ##
17124## Report this to bug-autoconf@gnu.org. ##
17125## ------------------------------------ ##
17126_ASBOX
17127 ) |
17128 sed "s/^/$as_me: WARNING: /" >&2
17129 ;;
c0d27fcc
MR
17130esac
17131echo "$as_me:$LINENO: checking for $ac_header" >&5
17132echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17133if eval "test \"\${$as_ac_Header+set}\" = set"; then
17134 echo $ECHO_N "(cached) $ECHO_C" >&6
17135else
17136 eval "$as_ac_Header=$ac_header_preproc"
647847ea 17137fi
c0d27fcc 17138echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
503d2be0 17139echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17140
17141fi
503d2be0 17142if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17143 cat >>confdefs.h <<_ACEOF
503d2be0 17144#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17145_ACEOF
647847ea 17146
73b77ee5 17147fi
c0d27fcc 17148
503d2be0 17149done
73b77ee5 17150
c0d27fcc
MR
17151
17152
503d2be0
AS
17153for ac_func in fork vfork
17154do
17155as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
c0d27fcc 17156echo "$as_me:$LINENO: checking for $ac_func" >&5
503d2be0
AS
17157echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17158if eval "test \"\${$as_ac_var+set}\" = set"; then
17159 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 17160else
503d2be0 17161 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17162#line $LINENO "configure"
cd958eb3
MB
17163/* confdefs.h. */
17164_ACEOF
17165cat confdefs.h >>conftest.$ac_ext
17166cat >>conftest.$ac_ext <<_ACEOF
17167/* end confdefs.h. */
fa0b693c 17168/* System header to define __stub macros and hopefully few prototypes,
9e71690e
DK
17169 which can conflict with char $ac_func (); below.
17170 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17171 <limits.h> exists even on freestanding compilers. */
17172#ifdef __STDC__
17173# include <limits.h>
17174#else
17175# include <assert.h>
17176#endif
fa0b693c 17177/* Override any gcc2 internal prototype to avoid an error. */
503d2be0
AS
17178#ifdef __cplusplus
17179extern "C"
cd958eb3 17180{
503d2be0 17181#endif
fa0b693c 17182/* We use char because int might match the return type of a gcc2
503d2be0
AS
17183 builtin and then its argument prototype would still apply. */
17184char $ac_func ();
fa0b693c
GM
17185/* The GNU C library defines this for functions which it implements
17186 to always fail with ENOSYS. Some functions are actually named
17187 something starting with __ and the normal name is an alias. */
503d2be0 17188#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
fa0b693c
GM
17189choke me
17190#else
cd958eb3
MB
17191char (*f) () = $ac_func;
17192#endif
17193#ifdef __cplusplus
17194}
fa0b693c
GM
17195#endif
17196
cd958eb3
MB
17197int
17198main ()
17199{
9e71690e 17200return f != $ac_func;
503d2be0
AS
17201 ;
17202 return 0;
17203}
17204_ACEOF
17205rm -f conftest.$ac_objext conftest$ac_exeext
c0d27fcc 17206if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17207 (eval $ac_link) 2>&5
17208 ac_status=$?
c0d27fcc 17209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17210 (exit $ac_status); } &&
17211 { ac_try='test -s conftest$ac_exeext'
c0d27fcc 17212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17213 (eval $ac_try) 2>&5
17214 ac_status=$?
c0d27fcc 17215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17216 (exit $ac_status); }; }; then
17217 eval "$as_ac_var=yes"
17218else
17219 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17220sed 's/^/| /' conftest.$ac_ext >&5
17221
503d2be0
AS
17222eval "$as_ac_var=no"
17223fi
17224rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17225fi
c0d27fcc 17226echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
503d2be0
AS
17227echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17228if test `eval echo '${'$as_ac_var'}'` = yes; then
c0d27fcc 17229 cat >>confdefs.h <<_ACEOF
503d2be0 17230#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
c0d27fcc 17231_ACEOF
503d2be0 17232
fa0b693c 17233fi
503d2be0 17234done
fa0b693c 17235
503d2be0 17236if test "x$ac_cv_func_fork" = xyes; then
c0d27fcc 17237 echo "$as_me:$LINENO: checking for working fork" >&5
503d2be0
AS
17238echo $ECHO_N "checking for working fork... $ECHO_C" >&6
17239if test "${ac_cv_func_fork_works+set}" = set; then
17240 echo $ECHO_N "(cached) $ECHO_C" >&6
fa0b693c 17241else
503d2be0
AS
17242 if test "$cross_compiling" = yes; then
17243 ac_cv_func_fork_works=cross
17244else
17245 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17246/* By Ruediger Kuhlmann. */
503d2be0
AS
17247 #include <sys/types.h>
17248 #if HAVE_UNISTD_H
17249 # include <unistd.h>
17250 #endif
17251 /* Some systems only have a dummy stub for fork() */
17252 int main ()
17253 {
17254 if (fork() < 0)
17255 exit (1);
17256 exit (0);
17257 }
17258_ACEOF
17259rm -f conftest$ac_exeext
c0d27fcc 17260if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17261 (eval $ac_link) 2>&5
17262 ac_status=$?
c0d27fcc 17263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17264 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 17265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17266 (eval $ac_try) 2>&5
17267 ac_status=$?
c0d27fcc 17268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17269 (exit $ac_status); }; }; then
17270 ac_cv_func_fork_works=yes
17271else
17272 echo "$as_me: program exited with status $ac_status" >&5
17273echo "$as_me: failed program was:" >&5
cd958eb3
MB
17274sed 's/^/| /' conftest.$ac_ext >&5
17275
c0d27fcc 17276( exit $ac_status )
503d2be0
AS
17277ac_cv_func_fork_works=no
17278fi
6bae0ccf 17279rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
503d2be0
AS
17280fi
17281fi
c0d27fcc 17282echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
503d2be0
AS
17283echo "${ECHO_T}$ac_cv_func_fork_works" >&6
17284
6bae0ccf
DL
17285else
17286 ac_cv_func_fork_works=$ac_cv_func_fork
503d2be0
AS
17287fi
17288if test "x$ac_cv_func_fork_works" = xcross; then
17289 case $host in
17290 *-*-amigaos* | *-*-msdosdjgpp*)
17291 # Override, as these systems have only a dummy fork() stub
17292 ac_cv_func_fork_works=no
17293 ;;
17294 *)
17295 ac_cv_func_fork_works=yes
17296 ;;
17297 esac
c0d27fcc
MR
17298 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
17299echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fa0b693c 17300fi
73b77ee5 17301ac_cv_func_vfork_works=$ac_cv_func_vfork
503d2be0 17302if test "x$ac_cv_func_vfork" = xyes; then
c0d27fcc 17303 echo "$as_me:$LINENO: checking for working vfork" >&5
503d2be0
AS
17304echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
17305if test "${ac_cv_func_vfork_works+set}" = set; then
17306 echo $ECHO_N "(cached) $ECHO_C" >&6
17307else
17308 if test "$cross_compiling" = yes; then
17309 ac_cv_func_vfork_works=cross
fa0b693c 17310else
503d2be0 17311 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17312#line $LINENO "configure"
cd958eb3
MB
17313/* confdefs.h. */
17314_ACEOF
17315cat confdefs.h >>conftest.$ac_ext
17316cat >>conftest.$ac_ext <<_ACEOF
17317/* end confdefs.h. */
73b77ee5
GM
17318/* Thanks to Paul Eggert for this test. */
17319#include <stdio.h>
cd958eb3 17320#include <stdlib.h>
fa0b693c 17321#include <sys/types.h>
73b77ee5 17322#include <sys/stat.h>
cd958eb3 17323#include <sys/wait.h>
503d2be0
AS
17324#if HAVE_UNISTD_H
17325# include <unistd.h>
73b77ee5 17326#endif
503d2be0
AS
17327#if HAVE_VFORK_H
17328# include <vfork.h>
73b77ee5
GM
17329#endif
17330/* On some sparc systems, changes by the child to local and incoming
503d2be0
AS
17331 argument registers are propagated back to the parent. The compiler
17332 is told about this with #include <vfork.h>, but some compilers
17333 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
17334 static variable whose address is put into a register that is
17335 clobbered by the vfork. */
cd958eb3 17336static void
fa0b693c 17337#ifdef __cplusplus
73b77ee5 17338sparc_address_test (int arg)
503d2be0 17339# else
73b77ee5 17340sparc_address_test (arg) int arg;
fa0b693c 17341#endif
fa0b693c 17342{
73b77ee5
GM
17343 static pid_t child;
17344 if (!child) {
17345 child = vfork ();
17346 if (child < 0) {
17347 perror ("vfork");
17348 _exit(2);
17349 }
17350 if (!child) {
17351 arg = getpid();
17352 write(-1, "", 0);
17353 _exit (arg);
17354 }
17355 }
17356}
503d2be0
AS
17357
17358int
17359main ()
17360{
73b77ee5
GM
17361 pid_t parent = getpid ();
17362 pid_t child;
fa0b693c 17363
cd958eb3 17364 sparc_address_test (0);
fa0b693c 17365
73b77ee5 17366 child = vfork ();
fa0b693c 17367
73b77ee5 17368 if (child == 0) {
503d2be0
AS
17369 /* Here is another test for sparc vfork register problems. This
17370 test uses lots of local variables, at least as many local
17371 variables as main has allocated so far including compiler
17372 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
17373 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
17374 reuse the register of parent for one of the local variables,
17375 since it will think that parent can't possibly be used any more
17376 in this routine. Assigning to the local variable will thus
17377 munge parent in the parent process. */
73b77ee5
GM
17378 pid_t
17379 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
17380 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
17381 /* Convince the compiler that p..p7 are live; otherwise, it might
17382 use the same hardware register for all 8 local variables. */
17383 if (p != p1 || p != p2 || p != p3 || p != p4
17384 || p != p5 || p != p6 || p != p7)
17385 _exit(1);
fa0b693c 17386
503d2be0
AS
17387 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
17388 from child file descriptors. If the child closes a descriptor
17389 before it execs or exits, this munges the parent's descriptor
17390 as well. Test for this by closing stdout in the child. */
73b77ee5
GM
17391 _exit(close(fileno(stdout)) != 0);
17392 } else {
17393 int status;
17394 struct stat st;
17395
17396 while (wait(&status) != child)
17397 ;
17398 exit(
17399 /* Was there some problem with vforking? */
17400 child < 0
17401
17402 /* Did the child fail? (This shouldn't happen.) */
17403 || status
17404
17405 /* Did the vfork/compiler bug occur? */
17406 || parent != getpid()
fa0b693c 17407
73b77ee5
GM
17408 /* Did the file descriptor bug occur? */
17409 || fstat(fileno(stdout), &st) != 0
17410 );
17411 }
17412}
503d2be0
AS
17413_ACEOF
17414rm -f conftest$ac_exeext
c0d27fcc 17415if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
503d2be0
AS
17416 (eval $ac_link) 2>&5
17417 ac_status=$?
c0d27fcc 17418 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17419 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
c0d27fcc 17420 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17421 (eval $ac_try) 2>&5
17422 ac_status=$?
c0d27fcc 17423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17424 (exit $ac_status); }; }; then
73b77ee5 17425 ac_cv_func_vfork_works=yes
fa0b693c 17426else
503d2be0
AS
17427 echo "$as_me: program exited with status $ac_status" >&5
17428echo "$as_me: failed program was:" >&5
cd958eb3
MB
17429sed 's/^/| /' conftest.$ac_ext >&5
17430
c0d27fcc 17431( exit $ac_status )
503d2be0
AS
17432ac_cv_func_vfork_works=no
17433fi
6bae0ccf 17434rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fa0b693c 17435fi
fa0b693c 17436fi
c0d27fcc 17437echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
503d2be0 17438echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
fa0b693c 17439
503d2be0
AS
17440fi;
17441if test "x$ac_cv_func_fork_works" = xcross; then
17442 ac_cv_func_vfork_works=ac_cv_func_vfork
c0d27fcc
MR
17443 { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
17444echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fa0b693c
GM
17445fi
17446
503d2be0
AS
17447if test "x$ac_cv_func_vfork_works" = xyes; then
17448
c0d27fcc 17449cat >>confdefs.h <<\_ACEOF
503d2be0 17450#define HAVE_WORKING_VFORK 1
c0d27fcc 17451_ACEOF
503d2be0
AS
17452
17453else
17454
c0d27fcc 17455cat >>confdefs.h <<\_ACEOF
73b77ee5 17456#define vfork fork
c0d27fcc 17457_ACEOF
fa0b693c
GM
17458
17459fi
503d2be0
AS
17460if test "x$ac_cv_func_fork_works" = xyes; then
17461
c0d27fcc 17462cat >>confdefs.h <<\_ACEOF
503d2be0 17463#define HAVE_WORKING_FORK 1
c0d27fcc 17464_ACEOF
fa0b693c 17465
503d2be0 17466fi
647847ea 17467
c0d27fcc 17468
6a3a24fa
JD
17469echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5
17470echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
17471if test "${emacs_cv_langinfo_codeset+set}" = set; then
17472 echo $ECHO_N "(cached) $ECHO_C" >&6
17473else
17474 cat >conftest.$ac_ext <<_ACEOF
17475#line $LINENO "configure"
17476/* confdefs.h. */
17477_ACEOF
17478cat confdefs.h >>conftest.$ac_ext
17479cat >>conftest.$ac_ext <<_ACEOF
17480/* end confdefs.h. */
17481#include <langinfo.h>
17482int
17483main ()
17484{
17485char* cs = nl_langinfo(CODESET);
17486 ;
17487 return 0;
17488}
17489_ACEOF
17490rm -f conftest.$ac_objext conftest$ac_exeext
17491if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17492 (eval $ac_link) 2>&5
17493 ac_status=$?
17494 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17495 (exit $ac_status); } &&
17496 { ac_try='test -s conftest$ac_exeext'
17497 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17498 (eval $ac_try) 2>&5
17499 ac_status=$?
17500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17501 (exit $ac_status); }; }; then
17502 emacs_cv_langinfo_codeset=yes
17503else
17504 echo "$as_me: failed program was:" >&5
17505sed 's/^/| /' conftest.$ac_ext >&5
17506
17507emacs_cv_langinfo_codeset=no
17508fi
17509rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17510
17511fi
17512echo "$as_me:$LINENO: result: $emacs_cv_langinfo_codeset" >&5
17513echo "${ECHO_T}$emacs_cv_langinfo_codeset" >&6
17514if test $emacs_cv_langinfo_codeset = yes; then
17515
17516cat >>confdefs.h <<\_ACEOF
17517#define HAVE_LANGINFO_CODESET 1
17518_ACEOF
17519
17520fi
17521
c0d27fcc 17522echo "$as_me:$LINENO: checking for size_t" >&5
503d2be0
AS
17523echo $ECHO_N "checking for size_t... $ECHO_C" >&6
17524if test "${ac_cv_type_size_t+set}" = set; then
17525 echo $ECHO_N "(cached) $ECHO_C" >&6
8730a8da 17526else
503d2be0 17527 cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 17528#line $LINENO "configure"
cd958eb3
MB
17529/* confdefs.h. */
17530_ACEOF
17531cat confdefs.h >>conftest.$ac_ext
17532cat >>conftest.$ac_ext <<_ACEOF
17533/* end confdefs.h. */
503d2be0
AS
17534$ac_includes_default
17535int
17536main ()
17537{
17538if ((size_t *) 0)
17539 return 0;
17540if (sizeof (size_t))
17541 return 0;
17542 ;
17543 return 0;
17544}
17545_ACEOF
17546rm -f conftest.$ac_objext
c0d27fcc 17547if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
503d2be0
AS
17548 (eval $ac_compile) 2>&5
17549 ac_status=$?
c0d27fcc 17550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0
AS
17551 (exit $ac_status); } &&
17552 { ac_try='test -s conftest.$ac_objext'
c0d27fcc 17553 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
503d2be0
AS
17554 (eval $ac_try) 2>&5
17555 ac_status=$?
c0d27fcc 17556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
503d2be0 17557 (exit $ac_status); }; }; then
8730a8da
DL
17558 ac_cv_type_size_t=yes
17559else
503d2be0 17560 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17561sed 's/^/| /' conftest.$ac_ext >&5
17562
503d2be0 17563ac_cv_type_size_t=no
8730a8da 17564fi
503d2be0 17565rm -f conftest.$ac_objext conftest.$ac_ext
8730a8da 17566fi
c0d27fcc 17567echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
503d2be0
AS
17568echo "${ECHO_T}$ac_cv_type_size_t" >&6
17569if test $ac_cv_type_size_t = yes; then
503d2be0 17570
c0d27fcc
MR
17571cat >>confdefs.h <<_ACEOF
17572#define HAVE_SIZE_T 1
17573_ACEOF
17574
8730a8da
DL
17575
17576fi
17577
c0d27fcc 17578
22044edf
DL
17579echo "$as_me:$LINENO: checking for C restrict keyword" >&5
17580echo $ECHO_N "checking for C restrict keyword... $ECHO_C" >&6
17581if test "${emacs_cv_c_restrict+set}" = set; then
17582 echo $ECHO_N "(cached) $ECHO_C" >&6
17583else
17584 cat >conftest.$ac_ext <<_ACEOF
17585#line $LINENO "configure"
cd958eb3
MB
17586/* confdefs.h. */
17587_ACEOF
17588cat confdefs.h >>conftest.$ac_ext
17589cat >>conftest.$ac_ext <<_ACEOF
17590/* end confdefs.h. */
22044edf
DL
17591void fred (int *restrict x);
17592int
17593main ()
17594{
b936fae4 17595
22044edf
DL
17596 ;
17597 return 0;
17598}
c0d27fcc 17599_ACEOF
22044edf
DL
17600rm -f conftest.$ac_objext
17601if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17602 (eval $ac_compile) 2>&5
17603 ac_status=$?
17604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17605 (exit $ac_status); } &&
17606 { ac_try='test -s conftest.$ac_objext'
17607 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17608 (eval $ac_try) 2>&5
17609 ac_status=$?
17610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17611 (exit $ac_status); }; }; then
17612 emacs_cv_c_restrict=yes
17613else
17614 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17615sed 's/^/| /' conftest.$ac_ext >&5
17616
22044edf
DL
17617cat >conftest.$ac_ext <<_ACEOF
17618#line $LINENO "configure"
cd958eb3
MB
17619/* confdefs.h. */
17620_ACEOF
17621cat confdefs.h >>conftest.$ac_ext
17622cat >>conftest.$ac_ext <<_ACEOF
17623/* end confdefs.h. */
22044edf
DL
17624void fred (int *__restrict x);
17625int
17626main ()
17627{
c0d27fcc 17628
22044edf
DL
17629 ;
17630 return 0;
17631}
c0d27fcc 17632_ACEOF
22044edf
DL
17633rm -f conftest.$ac_objext
17634if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17635 (eval $ac_compile) 2>&5
17636 ac_status=$?
17637 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17638 (exit $ac_status); } &&
17639 { ac_try='test -s conftest.$ac_objext'
17640 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17641 (eval $ac_try) 2>&5
17642 ac_status=$?
17643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17644 (exit $ac_status); }; }; then
17645 emacs_cv_c_restrict=__restrict
17646else
17647 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17648sed 's/^/| /' conftest.$ac_ext >&5
17649
22044edf 17650emacs_cv_c_restrict=no
ba4481b5 17651fi
22044edf 17652rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 17653fi
22044edf 17654rm -f conftest.$ac_objext conftest.$ac_ext
ba4481b5 17655fi
22044edf
DL
17656echo "$as_me:$LINENO: result: $emacs_cv_c_restrict" >&5
17657echo "${ECHO_T}$emacs_cv_c_restrict" >&6
17658case "$emacs_cv_c_restrict" in
17659 yes) emacs_restrict=restrict;;
17660 no) emacs_restrict="";;
17661 *) emacs_restrict="$emacs_cv_c_restrict";;
17662esac
17663if test "$emacs_restrict" != __restrict; then
b936fae4 17664
22044edf
DL
17665cat >>confdefs.h <<_ACEOF
17666#define __restrict $emacs_restrict
c0d27fcc 17667_ACEOF
ba4481b5
DL
17668
17669fi
ba4481b5 17670
22044edf
DL
17671echo "$as_me:$LINENO: checking for C restricted array declarations" >&5
17672echo $ECHO_N "checking for C restricted array declarations... $ECHO_C" >&6
17673if test "${emacs_cv_c_restrict_arr+set}" = set; then
17674 echo $ECHO_N "(cached) $ECHO_C" >&6
17675else
17676 cat >conftest.$ac_ext <<_ACEOF
17677#line $LINENO "configure"
cd958eb3
MB
17678/* confdefs.h. */
17679_ACEOF
17680cat confdefs.h >>conftest.$ac_ext
17681cat >>conftest.$ac_ext <<_ACEOF
17682/* end confdefs.h. */
22044edf
DL
17683void fred (int x[__restrict]);
17684int
17685main ()
17686{
b936fae4 17687
22044edf
DL
17688 ;
17689 return 0;
17690}
c0d27fcc 17691_ACEOF
22044edf
DL
17692rm -f conftest.$ac_objext
17693if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17694 (eval $ac_compile) 2>&5
17695 ac_status=$?
17696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17697 (exit $ac_status); } &&
17698 { ac_try='test -s conftest.$ac_objext'
17699 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17700 (eval $ac_try) 2>&5
17701 ac_status=$?
17702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17703 (exit $ac_status); }; }; then
17704 emacs_cv_c_restrict_arr=yes
17705else
17706 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17707sed 's/^/| /' conftest.$ac_ext >&5
17708
22044edf 17709emacs_cv_c_restrict_arr=no
ba4481b5 17710fi
22044edf
DL
17711rm -f conftest.$ac_objext conftest.$ac_ext
17712fi
17713echo "$as_me:$LINENO: result: $emacs_cv_c_restrict_arr" >&5
17714echo "${ECHO_T}$emacs_cv_c_restrict_arr" >&6
17715if test "$emacs_cv_c_restrict_arr" = yes; then
b936fae4 17716
c0d27fcc 17717cat >>confdefs.h <<\_ACEOF
22044edf 17718#define __restrict_arr __restrict
c0d27fcc 17719_ACEOF
ba4481b5 17720
ba4481b5
DL
17721fi
17722
c0d27fcc 17723
f0f2756d
SS
17724for ac_header in nlist.h
17725do
17726as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
c0d27fcc
MR
17727if eval "test \"\${$as_ac_Header+set}\" = set"; then
17728 echo "$as_me:$LINENO: checking for $ac_header" >&5
f0f2756d
SS
17729echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17730if eval "test \"\${$as_ac_Header+set}\" = set"; then
17731 echo $ECHO_N "(cached) $ECHO_C" >&6
c0d27fcc
MR
17732fi
17733echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
17734echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
98418dba 17735else
c0d27fcc
MR
17736 # Is the header compilable?
17737echo "$as_me:$LINENO: checking $ac_header usability" >&5
17738echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
17739cat >conftest.$ac_ext <<_ACEOF
17740#line $LINENO "configure"
cd958eb3
MB
17741/* confdefs.h. */
17742_ACEOF
17743cat confdefs.h >>conftest.$ac_ext
17744cat >>conftest.$ac_ext <<_ACEOF
17745/* end confdefs.h. */
c0d27fcc
MR
17746$ac_includes_default
17747#include <$ac_header>
17748_ACEOF
17749rm -f conftest.$ac_objext
17750if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17751 (eval $ac_compile) 2>&5
17752 ac_status=$?
17753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17754 (exit $ac_status); } &&
17755 { ac_try='test -s conftest.$ac_objext'
17756 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17757 (eval $ac_try) 2>&5
17758 ac_status=$?
17759 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17760 (exit $ac_status); }; }; then
17761 ac_header_compiler=yes
17762else
17763 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17764sed 's/^/| /' conftest.$ac_ext >&5
17765
c0d27fcc
MR
17766ac_header_compiler=no
17767fi
17768rm -f conftest.$ac_objext conftest.$ac_ext
17769echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17770echo "${ECHO_T}$ac_header_compiler" >&6
17771
17772# Is the header present?
17773echo "$as_me:$LINENO: checking $ac_header presence" >&5
17774echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
17775cat >conftest.$ac_ext <<_ACEOF
17776#line $LINENO "configure"
cd958eb3
MB
17777/* confdefs.h. */
17778_ACEOF
17779cat confdefs.h >>conftest.$ac_ext
17780cat >>conftest.$ac_ext <<_ACEOF
17781/* end confdefs.h. */
f0f2756d
SS
17782#include <$ac_header>
17783_ACEOF
c0d27fcc 17784if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
f0f2756d
SS
17785 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17786 ac_status=$?
6bae0ccf 17787 grep -v '^ *+' conftest.er1 >conftest.err
f0f2756d
SS
17788 rm -f conftest.er1
17789 cat conftest.err >&5
c0d27fcc 17790 echo "$as_me:$LINENO: \$? = $ac_status" >&5
f0f2756d
SS
17791 (exit $ac_status); } >/dev/null; then
17792 if test -s conftest.err; then
17793 ac_cpp_err=$ac_c_preproc_warn_flag
17794 else
17795 ac_cpp_err=
17796 fi
17797else
17798 ac_cpp_err=yes
17799fi
17800if test -z "$ac_cpp_err"; then
c0d27fcc 17801 ac_header_preproc=yes
f0f2756d
SS
17802else
17803 echo "$as_me: failed program was:" >&5
cd958eb3
MB
17804sed 's/^/| /' conftest.$ac_ext >&5
17805
c0d27fcc 17806 ac_header_preproc=no
f0f2756d
SS
17807fi
17808rm -f conftest.err conftest.$ac_ext
c0d27fcc
MR
17809echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17810echo "${ECHO_T}$ac_header_preproc" >&6
17811
17812# So? What about this header?
17813case $ac_header_compiler:$ac_header_preproc in
17814 yes:no )
17815 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
17816echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
17817 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17818echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17819 (
17820 cat <<\_ASBOX
17821## ------------------------------------ ##
17822## Report this to bug-autoconf@gnu.org. ##
17823## ------------------------------------ ##
17824_ASBOX
17825 ) |
17826 sed "s/^/$as_me: WARNING: /" >&2
17827 ;;
c0d27fcc
MR
17828 no:yes )
17829 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
17830echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
17831 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
17832echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
17833 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
cd958eb3
MB
17834echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
17835 (
17836 cat <<\_ASBOX
17837## ------------------------------------ ##
17838## Report this to bug-autoconf@gnu.org. ##
17839## ------------------------------------ ##
17840_ASBOX
17841 ) |
17842 sed "s/^/$as_me: WARNING: /" >&2
17843 ;;
c0d27fcc
MR
17844esac
17845echo "$as_me:$LINENO: checking for $ac_header" >&5
17846echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17847if eval "test \"\${$as_ac_Header+set}\" = set"; then
17848 echo $ECHO_N "(cached) $ECHO_C" >&6
17849else
17850 eval "$as_ac_Header=$ac_header_preproc"
f0f2756d 17851fi
c0d27fcc 17852echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
f0f2756d 17853echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
c0d27fcc
MR
17854
17855fi
f0f2756d 17856if test `eval echo '${'$as_ac_Header'}'` = yes; then
c0d27fcc 17857 cat >>confdefs.h <<_ACEOF
f0f2756d 17858#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
c0d27fcc 17859_ACEOF
f0f2756d 17860
c0d27fcc 17861cat >>confdefs.h <<\_ACEOF
f0f2756d 17862#define NLIST_STRUCT 1
c0d27fcc 17863_ACEOF
f0f2756d
SS
17864
17865fi
c0d27fcc 17866
f0f2756d
SS
17867done
17868
c0d27fcc
MR
17869
17870
17871
22044edf
DL
17872# Set up the CFLAGS for real compilation, so we can substitute it.
17873CFLAGS="$REAL_CFLAGS"
17874CPPFLAGS="$REAL_CPPFLAGS"
17875
17876#### Find out which version of Emacs this is.
17877version=`grep 'defconst[ ]*emacs-version' ${srcdir}/lisp/version.el \
17878 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
17879if test x"${version}" = x; then
17880 { { echo "$as_me:$LINENO: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&5
17881echo "$as_me: error: can't find current emacs version in \`${srcdir}/lisp/version.el'." >&2;}
17882 { (exit 1); exit 1; }; }
17883fi
17884
17885### Specify what sort of things we'll be editing into Makefile and config.h.
17886### Use configuration here uncanonicalized to avoid exceeding size limits.
17887
17888
17889
17890
17891
17892
17893
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
6a3a24fa 17919
22044edf
DL
17920
17921
17922cat >>confdefs.h <<_ACEOF
17923#define EMACS_CONFIGURATION "${canonical}"
17924_ACEOF
17925
17926
17927cat >>confdefs.h <<_ACEOF
17928#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
17929_ACEOF
17930
17931
17932cat >>confdefs.h <<_ACEOF
17933#define config_machfile "${machfile}"
17934_ACEOF
17935
17936
17937cat >>confdefs.h <<_ACEOF
17938#define config_opsysfile "${opsysfile}"
17939_ACEOF
17940
17941
17942cat >>confdefs.h <<_ACEOF
17943#define LD_SWITCH_X_SITE ${LD_SWITCH_X_SITE}
17944_ACEOF
17945
17946
17947cat >>confdefs.h <<_ACEOF
17948#define LD_SWITCH_X_SITE_AUX ${LD_SWITCH_X_SITE_AUX}
17949_ACEOF
17950
17951
17952cat >>confdefs.h <<_ACEOF
17953#define C_SWITCH_X_SITE ${C_SWITCH_X_SITE}
17954_ACEOF
17955
17956
17957cat >>confdefs.h <<_ACEOF
17958#define UNEXEC_SRC ${UNEXEC_SRC}
17959_ACEOF
17960
17961
17962if test "${HAVE_X_WINDOWS}" = "yes" ; then
17963
17964cat >>confdefs.h <<\_ACEOF
17965#define HAVE_X_WINDOWS 1
17966_ACEOF
17967
17968fi
17969if test "${USE_X_TOOLKIT}" != "none" ; then
17970
17971cat >>confdefs.h <<\_ACEOF
17972#define USE_X_TOOLKIT 1
17973_ACEOF
17974
17975fi
17976if test "${HAVE_X11}" = "yes" ; then
17977
17978cat >>confdefs.h <<\_ACEOF
17979#define HAVE_X11 1
17980_ACEOF
17981
17982fi
17983if test "${HAVE_XFREE386}" = "yes" ; then
17984
17985cat >>confdefs.h <<\_ACEOF
17986#define HAVE_XFREE386 1
17987_ACEOF
17988
17989fi
17990if test "${HAVE_MENUS}" = "yes" ; then
17991
17992cat >>confdefs.h <<\_ACEOF
17993#define HAVE_MENUS 1
17994_ACEOF
17995
17996fi
17997if test "${GNU_MALLOC}" = "yes" ; then
17998
17999cat >>confdefs.h <<\_ACEOF
18000#define GNU_MALLOC 1
18001_ACEOF
18002
18003fi
18004if test "${REL_ALLOC}" = "yes" ; then
18005
18006cat >>confdefs.h <<\_ACEOF
18007#define REL_ALLOC 1
18008_ACEOF
18009
18010fi
18011
18012
18013
c0d27fcc
MR
18014
18015
ba4481b5 18016#### Report on what we decided to do.
488dd4c4
JD
18017#### Report GTK as a toolkit, even if it doesn't use Xt.
18018#### It makes printing result more understandable as using GTK sets
18019#### toolkit_scroll_bars to yes by default.
18020if test "${HAVE_GTK}" = "yes"; then
18021 USE_X_TOOLKIT=GTK
18022fi
18023
ba4481b5
DL
18024echo "
18025Configured for \`${canonical}'.
18026
18027 Where should the build process find the source code? ${srcdir}
18028 What operating system and machine description files should Emacs use?
18029 \`${opsysfile}' and \`${machfile}'
18030 What compiler should emacs be built with? ${CC} ${CFLAGS}
18031 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
73b77ee5 18032 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
ef9e4345 18033 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
ba4481b5 18034 What window system should Emacs use? ${window_system}
8e967cf7 18035 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
ba4481b5
DL
18036
18037if test -n "${x_includes}"; then
18038echo " Where do we find X Windows header files? ${x_includes}"
18039else
18040echo " Where do we find X Windows header files? Standard dirs"
18041fi
18042if test -n "${x_libraries}"; then
18043echo " Where do we find X Windows libraries? ${x_libraries}"
18044else
18045echo " Where do we find X Windows libraries? Standard dirs"
18046fi
18047
18048echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
18049echo " Does Emacs use -lXpm? ${HAVE_XPM}"
18050echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
18051echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
18052echo " Does Emacs use -lungif? ${HAVE_GIF}"
18053echo " Does Emacs use -lpng? ${HAVE_PNG}"
18054echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
18055echo
18056
18057# Remove any trailing slashes in these variables.
18058test "${prefix}" != NONE &&
18059 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
18060test "${exec_prefix}" != NONE &&
18061 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
18062
d0e9bfd2
GM
18063## Check if the C preprocessor will convert `..' to `. .'. If so, set
18064## CPP_NEED_TRADITIONAL to `yes' so that the code to generate Makefile
18065## from Makefile.c can correctly provide the arg `-traditional' to the
18066## C preprocessor.
18067
503d2be0 18068cat >conftest.$ac_ext <<_ACEOF
c0d27fcc 18069#line $LINENO "configure"
cd958eb3
MB
18070/* confdefs.h. */
18071_ACEOF
18072cat confdefs.h >>conftest.$ac_ext
18073cat >>conftest.$ac_ext <<_ACEOF
18074/* end confdefs.h. */
d0e9bfd2 18075yes..yes
503d2be0 18076_ACEOF
d0e9bfd2 18077if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6bae0ccf 18078 $EGREP "yes..yes" >/dev/null 2>&1; then
d0e9bfd2
GM
18079 CPP_NEED_TRADITIONAL=no
18080else
d0e9bfd2
GM
18081 CPP_NEED_TRADITIONAL=yes
18082fi
18083rm -f conftest*
18084
c0d27fcc 18085
6bae0ccf
DL
18086 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"
18087 ac_config_commands="$ac_config_commands default"
503d2be0 18088cat >confcache <<\_ACEOF
ba4481b5
DL
18089# This file is a shell script that caches the results of configure
18090# tests run on this system so they can be shared between configure
503d2be0
AS
18091# scripts and configure runs, see configure's option --config-cache.
18092# It is not useful on other systems. If it contains results you don't
18093# want to keep, you may remove or edit it.
ba4481b5 18094#
503d2be0
AS
18095# config.status only pays attention to the cache file if you give it
18096# the --recheck option to rerun configure.
ba4481b5 18097#
6bae0ccf 18098# `ac_cv_env_foo' variables (set or unset) will be overridden when
503d2be0
AS
18099# loading this file, other *unset* `ac_cv_foo' will be assigned the
18100# following values.
18101
18102_ACEOF
18103
ba4481b5
DL
18104# The following way of writing the cache mishandles newlines in values,
18105# but we know of no workaround that is simple, portable, and efficient.
18106# So, don't put newlines in cache variables' values.
18107# Ultrix sh set writes to stderr and can't be redirected directly,
18108# and sets the high bit in the cache file unless we assign to the vars.
503d2be0
AS
18109{
18110 (set) 2>&1 |
18111 case `(ac_space=' '; set | grep ac_space) 2>&1` in
18112 *ac_space=\ *)
18113 # `set' does not quote correctly, so add quotes (double-quote
18114 # substitution turns \\\\ into \\, and sed turns \\ into \).
18115 sed -n \
18116 "s/'/'\\\\''/g;
18117 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18118 ;;
18119 *)
18120 # `set' quotes correctly as required by POSIX, so do not add quotes.
18121 sed -n \
18122 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
18123 ;;
18124 esac;
18125} |
18126 sed '
18127 t clear
18128 : clear
18129 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18130 t end
18131 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18132 : end' >>confcache
cd958eb3 18133if diff $cache_file confcache >/dev/null 2>&1; then :; else
ba4481b5 18134 if test -w $cache_file; then
503d2be0
AS
18135 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
18136 cat confcache >$cache_file
ba4481b5
DL
18137 else
18138 echo "not updating unwritable cache $cache_file"
18139 fi
18140fi
18141rm -f confcache
18142
ba4481b5
DL
18143test "x$prefix" = xNONE && prefix=$ac_default_prefix
18144# Let make expand exec_prefix.
18145test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18146
503d2be0
AS
18147# VPATH may cause trouble with some makes, so we remove $(srcdir),
18148# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18149# trailing colons and then remove the whole line if VPATH becomes empty
18150# (actually we leave an empty line to preserve line numbers).
ba4481b5 18151if test "x$srcdir" = x.; then
503d2be0
AS
18152 ac_vpsub='/^[ ]*VPATH[ ]*=/{
18153s/:*\$(srcdir):*/:/;
18154s/:*\${srcdir}:*/:/;
18155s/:*@srcdir@:*/:/;
18156s/^\([^=]*=[ ]*\):*/\1/;
18157s/:*$//;
18158s/^[^=]*=[ ]*$//;
18159}'
ba4481b5
DL
18160fi
18161
ba4481b5
DL
18162DEFS=-DHAVE_CONFIG_H
18163
6bae0ccf
DL
18164ac_libobjs=
18165ac_ltlibobjs=
18166for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18167 # 1. Remove the extension, and $U if already installed.
18168 ac_i=`echo "$ac_i" |
18169 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
18170 # 2. Add them.
18171 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
18172 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
18173done
18174LIBOBJS=$ac_libobjs
18175
18176LTLIBOBJS=$ac_ltlibobjs
18177
18178
c0d27fcc 18179
ba4481b5 18180: ${CONFIG_STATUS=./config.status}
503d2be0
AS
18181ac_clean_files_save=$ac_clean_files
18182ac_clean_files="$ac_clean_files $CONFIG_STATUS"
c0d27fcc 18183{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
503d2be0
AS
18184echo "$as_me: creating $CONFIG_STATUS" >&6;}
18185cat >$CONFIG_STATUS <<_ACEOF
18186#! $SHELL
c0d27fcc 18187# Generated by $as_me.
ba4481b5 18188# Run this file to recreate the current configuration.
ba4481b5 18189# Compiler output produced by configure, useful for debugging
503d2be0 18190# configure, is in config.log if it exists.
ba4481b5 18191
503d2be0 18192debug=false
cd958eb3
MB
18193ac_cs_recheck=false
18194ac_cs_silent=false
503d2be0 18195SHELL=\${CONFIG_SHELL-$SHELL}
503d2be0
AS
18196_ACEOF
18197
18198cat >>$CONFIG_STATUS <<\_ACEOF
c0d27fcc
MR
18199## --------------------- ##
18200## M4sh Initialization. ##
18201## --------------------- ##
18202
503d2be0
AS
18203# Be Bourne compatible
18204if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18205 emulate sh
18206 NULLCMD=:
6bae0ccf
DL
18207 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
18208 # is contrary to our usage. Disable this feature.
18209 alias -g '${1+"$@"}'='"$@"'
503d2be0
AS
18210elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
18211 set -o posix
18212fi
18213
c0d27fcc
MR
18214# Support unset when possible.
18215if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
18216 as_unset=unset
18217else
18218 as_unset=false
18219fi
18220
6bae0ccf
DL
18221
18222# Work around bugs in pre-3.0 UWIN ksh.
18223$as_unset ENV MAIL MAILPATH
18224PS1='$ '
18225PS2='> '
18226PS4='+ '
18227
18228# NLS nuisances.
cd958eb3
MB
18229for as_var in \
18230 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
18231 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
18232 LC_TELEPHONE LC_TIME
6bae0ccf
DL
18233do
18234 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
18235 eval $as_var=C; export $as_var
18236 else
18237 $as_unset $as_var
18238 fi
18239done
18240
18241# Required to use basename.
18242if expr a : '\(a\)' >/dev/null 2>&1; then
18243 as_expr=expr
18244else
18245 as_expr=false
18246fi
18247
18248if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
18249 as_basename=basename
18250else
18251 as_basename=false
18252fi
c0d27fcc
MR
18253
18254
503d2be0 18255# Name of the executable.
6bae0ccf 18256as_me=`$as_basename "$0" ||
c0d27fcc
MR
18257$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18258 X"$0" : 'X\(//\)$' \| \
18259 X"$0" : 'X\(/\)$' \| \
18260 . : '\(.\)' 2>/dev/null ||
18261echo X/"$0" |
18262 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
18263 /^X\/\(\/\/\)$/{ s//\1/; q; }
18264 /^X\/\(\/\).*/{ s//\1/; q; }
18265 s/.*/./; q'`
18266
6bae0ccf 18267
c0d27fcc
MR
18268# PATH needs CR, and LINENO needs CR and PATH.
18269# Avoid depending upon Character Ranges.
18270as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18271as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18272as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18273as_cr_digits='0123456789'
18274as_cr_alnum=$as_cr_Letters$as_cr_digits
18275
18276# The user is always right.
18277if test "${PATH_SEPARATOR+set}" != set; then
cd958eb3
MB
18278 echo "#! /bin/sh" >conf$$.sh
18279 echo "exit 0" >>conf$$.sh
18280 chmod +x conf$$.sh
18281 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
c0d27fcc
MR
18282 PATH_SEPARATOR=';'
18283 else
18284 PATH_SEPARATOR=:
18285 fi
cd958eb3 18286 rm -f conf$$.sh
c0d27fcc
MR
18287fi
18288
18289
18290 as_lineno_1=$LINENO
18291 as_lineno_2=$LINENO
18292 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18293 test "x$as_lineno_1" != "x$as_lineno_2" &&
18294 test "x$as_lineno_3" = "x$as_lineno_2" || {
18295 # Find who we are. Look in the path if we contain no path at all
18296 # relative or not.
18297 case $0 in
18298 *[\\/]* ) as_myself=$0 ;;
18299 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18300for as_dir in $PATH
18301do
18302 IFS=$as_save_IFS
18303 test -z "$as_dir" && as_dir=.
18304 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18305done
18306
18307 ;;
18308 esac
18309 # We did not find ourselves, most probably we were run as `sh COMMAND'
18310 # in which case we are not to be found in the path.
18311 if test "x$as_myself" = x; then
18312 as_myself=$0
18313 fi
18314 if test ! -f "$as_myself"; then
18315 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
18316echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
18317 { (exit 1); exit 1; }; }
18318 fi
18319 case $CONFIG_SHELL in
18320 '')
18321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18322for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
18323do
18324 IFS=$as_save_IFS
18325 test -z "$as_dir" && as_dir=.
18326 for as_base in sh bash ksh sh5; do
18327 case $as_dir in
18328 /*)
18329 if ("$as_dir/$as_base" -c '
18330 as_lineno_1=$LINENO
18331 as_lineno_2=$LINENO
18332 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18333 test "x$as_lineno_1" != "x$as_lineno_2" &&
18334 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
6bae0ccf
DL
18335 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
18336 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
c0d27fcc
MR
18337 CONFIG_SHELL=$as_dir/$as_base
18338 export CONFIG_SHELL
18339 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
18340 fi;;
18341 esac
18342 done
18343done
18344;;
18345 esac
18346
18347 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
18348 # uniformly replaced by the line number. The first 'sed' inserts a
18349 # line-number line before each line; the second 'sed' does the real
18350 # work. The second script uses 'N' to pair each line-number line
18351 # with the numbered line, and appends trailing '-' during
18352 # substitution so that $LINENO is not a special case at line end.
18353 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
18354 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
18355 sed '=' <$as_myself |
18356 sed '
18357 N
18358 s,$,-,
18359 : loop
18360 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
18361 t loop
18362 s,-$,,
18363 s,^['$as_cr_digits']*\n,,
18364 ' >$as_me.lineno &&
18365 chmod +x $as_me.lineno ||
18366 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
18367echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
18368 { (exit 1); exit 1; }; }
18369
18370 # Don't try to exec as it changes $[0], causing all sort of problems
18371 # (the dirname of $[0] is not the place where we might find the
18372 # original and so on. Autoconf is especially sensible to this).
18373 . ./$as_me.lineno
18374 # Exit status is that of the last command.
18375 exit
18376}
18377
18378
18379case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
18380 *c*,-n*) ECHO_N= ECHO_C='
18381' ECHO_T=' ' ;;
18382 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
18383 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
18384esac
503d2be0
AS
18385
18386if expr a : '\(a\)' >/dev/null 2>&1; then
18387 as_expr=expr
18388else
18389 as_expr=false
18390fi
18391
18392rm -f conf$$ conf$$.exe conf$$.file
18393echo >conf$$.file
18394if ln -s conf$$.file conf$$ 2>/dev/null; then
18395 # We could just check for DJGPP; but this test a) works b) is more generic
18396 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
18397 if test -f conf$$.exe; then
18398 # Don't use ln at all; we don't have any links
18399 as_ln_s='cp -p'
18400 else
18401 as_ln_s='ln -s'
18402 fi
18403elif ln conf$$.file conf$$ 2>/dev/null; then
18404 as_ln_s=ln
18405else
18406 as_ln_s='cp -p'
18407fi
18408rm -f conf$$ conf$$.exe conf$$.file
18409
6bae0ccf
DL
18410if mkdir -p . 2>/dev/null; then
18411 as_mkdir_p=:
18412else
18413 as_mkdir_p=false
18414fi
18415
503d2be0
AS
18416as_executable_p="test -f"
18417
c0d27fcc
MR
18418# Sed expression to map a string onto a valid CPP name.
18419as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
18420
18421# Sed expression to map a string onto a valid variable name.
18422as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
503d2be0 18423
503d2be0
AS
18424
18425# IFS
18426# We need space, tab and new line, in precisely that order.
18427as_nl='
18428'
18429IFS=" $as_nl"
18430
18431# CDPATH.
6bae0ccf 18432$as_unset CDPATH
503d2be0
AS
18433
18434exec 6>&1
18435
c0d27fcc
MR
18436# Open the log real soon, to keep \$[0] and so on meaningful, and to
18437# report actual input values of CONFIG_FILES etc. instead of their
18438# values after options handling. Logging --version etc. is OK.
18439exec 5>>config.log
18440{
18441 echo
18442 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18443## Running $as_me. ##
18444_ASBOX
18445} >&5
18446cat >&5 <<_CSEOF
18447
18448This file was extended by $as_me, which was
9e71690e 18449generated by GNU Autoconf 2.57. Invocation command line was
c0d27fcc
MR
18450
18451 CONFIG_FILES = $CONFIG_FILES
18452 CONFIG_HEADERS = $CONFIG_HEADERS
18453 CONFIG_LINKS = $CONFIG_LINKS
18454 CONFIG_COMMANDS = $CONFIG_COMMANDS
18455 $ $0 $@
18456
18457_CSEOF
18458echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
18459echo >&5
503d2be0
AS
18460_ACEOF
18461
18462# Files that config.status was made for.
18463if test -n "$ac_config_files"; then
18464 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
18465fi
18466
18467if test -n "$ac_config_headers"; then
18468 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
18469fi
18470
18471if test -n "$ac_config_links"; then
18472 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
18473fi
18474
18475if test -n "$ac_config_commands"; then
18476 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
18477fi
18478
c0d27fcc 18479cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18480
18481ac_cs_usage="\
18482\`$as_me' instantiates files from templates according to the
18483current configuration.
18484
18485Usage: $0 [OPTIONS] [FILE]...
18486
18487 -h, --help print this help, then exit
18488 -V, --version print version number, then exit
cd958eb3 18489 -q, --quiet do not print progress messages
503d2be0
AS
18490 -d, --debug don't remove temporary files
18491 --recheck update $as_me by reconfiguring in the same conditions
18492 --file=FILE[:TEMPLATE]
18493 instantiate the configuration file FILE
18494 --header=FILE[:TEMPLATE]
18495 instantiate the configuration header FILE
18496
18497Configuration files:
18498$config_files
18499
18500Configuration headers:
18501$config_headers
18502
18503Configuration commands:
18504$config_commands
18505
18506Report bugs to <bug-autoconf@gnu.org>."
c0d27fcc 18507_ACEOF
503d2be0 18508
c0d27fcc 18509cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18510ac_cs_version="\\
18511config.status
9e71690e 18512configured by $0, generated by GNU Autoconf 2.57,
503d2be0
AS
18513 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18514
18515Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18516Free Software Foundation, Inc.
18517This config.status script is free software; the Free Software Foundation
18518gives unlimited permission to copy, distribute and modify it."
18519srcdir=$srcdir
18520INSTALL="$INSTALL"
c0d27fcc 18521_ACEOF
503d2be0 18522
c0d27fcc 18523cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18524# If no file are specified by the user, then we need to provide default
18525# value. By we need to know if files were specified by the user.
18526ac_need_defaults=:
18527while test $# != 0
ba4481b5 18528do
503d2be0
AS
18529 case $1 in
18530 --*=*)
18531 ac_option=`expr "x$1" : 'x\([^=]*\)='`
18532 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
6bae0ccf
DL
18533 ac_shift=:
18534 ;;
18535 -*)
18536 ac_option=$1
18537 ac_optarg=$2
18538 ac_shift=shift
503d2be0 18539 ;;
503d2be0
AS
18540 *) # This is not an option, so the user has probably given explicit
18541 # arguments.
6bae0ccf 18542 ac_option=$1
503d2be0
AS
18543 ac_need_defaults=false;;
18544 esac
18545
6bae0ccf 18546 case $ac_option in
503d2be0 18547 # Handling of the options.
c0d27fcc 18548_ACEOF
c0d27fcc 18549cat >>$CONFIG_STATUS <<\_ACEOF
cd958eb3
MB
18550 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18551 ac_cs_recheck=: ;;
503d2be0
AS
18552 --version | --vers* | -V )
18553 echo "$ac_cs_version"; exit 0 ;;
18554 --he | --h)
18555 # Conflict between --help and --header
c0d27fcc 18556 { { echo "$as_me:$LINENO: error: ambiguous option: $1
503d2be0
AS
18557Try \`$0 --help' for more information." >&5
18558echo "$as_me: error: ambiguous option: $1
18559Try \`$0 --help' for more information." >&2;}
18560 { (exit 1); exit 1; }; };;
18561 --help | --hel | -h )
18562 echo "$ac_cs_usage"; exit 0 ;;
18563 --debug | --d* | -d )
18564 debug=: ;;
18565 --file | --fil | --fi | --f )
6bae0ccf
DL
18566 $ac_shift
18567 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
503d2be0
AS
18568 ac_need_defaults=false;;
18569 --header | --heade | --head | --hea )
6bae0ccf
DL
18570 $ac_shift
18571 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
503d2be0 18572 ac_need_defaults=false;;
cd958eb3
MB
18573 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18574 | -silent | --silent | --silen | --sile | --sil | --si | --s)
18575 ac_cs_silent=: ;;
503d2be0
AS
18576
18577 # This is an error.
c0d27fcc 18578 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
503d2be0
AS
18579Try \`$0 --help' for more information." >&5
18580echo "$as_me: error: unrecognized option: $1
18581Try \`$0 --help' for more information." >&2;}
18582 { (exit 1); exit 1; }; } ;;
18583
18584 *) ac_config_targets="$ac_config_targets $1" ;;
18585
ba4481b5 18586 esac
503d2be0 18587 shift
ba4481b5
DL
18588done
18589
cd958eb3
MB
18590ac_configure_extra_args=
18591
18592if $ac_cs_silent; then
18593 exec 6>/dev/null
18594 ac_configure_extra_args="$ac_configure_extra_args --silent"
18595fi
18596
18597_ACEOF
18598cat >>$CONFIG_STATUS <<_ACEOF
18599if \$ac_cs_recheck; then
18600 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
18601 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18602fi
18603
503d2be0 18604_ACEOF
ba4481b5 18605
c0d27fcc 18606cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18607#
18608# INIT-COMMANDS section.
18609#
ba4481b5 18610
503d2be0
AS
18611GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPP_NEED_TRADITIONAL="$CPP_NEED_TRADITIONAL" CPPFLAGS="$CPPFLAGS"
18612
c0d27fcc
MR
18613_ACEOF
18614
503d2be0 18615
c0d27fcc
MR
18616
18617cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18618for ac_config_target in $ac_config_targets
18619do
18620 case "$ac_config_target" in
18621 # Handling of arguments.
18622 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
18623 "lib-src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES lib-src/Makefile.c:lib-src/Makefile.in" ;;
18624 "oldXMenu/Makefile" ) CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
18625 "man/Makefile" ) CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
18626 "lwlib/Makefile" ) CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
18627 "src/Makefile.c" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.c:src/Makefile.in" ;;
18628 "lisp/Makefile" ) CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23b24859 18629 "lispref/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispref/Makefile" ;;
981626b7 18630 "lispintro/Makefile" ) CONFIG_FILES="$CONFIG_FILES lispintro/Makefile" ;;
503d2be0
AS
18631 "leim/Makefile" ) CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
18632 "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
18633 "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
c0d27fcc 18634 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
503d2be0
AS
18635echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
18636 { (exit 1); exit 1; }; };;
18637 esac
ba4481b5 18638done
503d2be0
AS
18639
18640# If the user did not use the arguments to specify the items to instantiate,
18641# then the envvar interface is used. Set only those that are not.
18642# We use the long form for the default assignment because of an extremely
18643# bizarre bug on SunOS 4.1.3.
18644if $ac_need_defaults; then
18645 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18646 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18647 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
ba4481b5 18648fi
503d2be0 18649
cd958eb3
MB
18650# Have a temporary directory for convenience. Make it in the build tree
18651# simply because there is no reason to put it here, and in addition,
18652# creating and moving files from /tmp can sometimes cause problems.
503d2be0
AS
18653# Create a temporary directory, and hook for its removal unless debugging.
18654$debug ||
18655{
18656 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
18657 trap '{ (exit 1); exit 1; }' 1 2 13 15
18658}
18659
18660# Create a (secure) tmp directory for tmp files.
cd958eb3 18661
503d2be0 18662{
cd958eb3 18663 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
503d2be0
AS
18664 test -n "$tmp" && test -d "$tmp"
18665} ||
18666{
cd958eb3 18667 tmp=./confstat$$-$RANDOM
503d2be0
AS
18668 (umask 077 && mkdir $tmp)
18669} ||
18670{
cd958eb3 18671 echo "$me: cannot create a temporary directory in ." >&2
503d2be0
AS
18672 { (exit 1); exit 1; }
18673}
18674
c0d27fcc 18675_ACEOF
503d2be0 18676
c0d27fcc 18677cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18678
18679#
18680# CONFIG_FILES section.
18681#
18682
18683# No need to generate the scripts if there are no CONFIG_FILES.
18684# This happens for instance when ./config.status config.h
18685if test -n "\$CONFIG_FILES"; then
18686 # Protect against being on the right side of a sed subst in config.status.
18687 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
18688 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
18689s,@SHELL@,$SHELL,;t t
c0d27fcc
MR
18690s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
18691s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
18692s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
18693s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
18694s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
18695s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
503d2be0
AS
18696s,@exec_prefix@,$exec_prefix,;t t
18697s,@prefix@,$prefix,;t t
18698s,@program_transform_name@,$program_transform_name,;t t
18699s,@bindir@,$bindir,;t t
18700s,@sbindir@,$sbindir,;t t
18701s,@libexecdir@,$libexecdir,;t t
18702s,@datadir@,$datadir,;t t
18703s,@sysconfdir@,$sysconfdir,;t t
18704s,@sharedstatedir@,$sharedstatedir,;t t
18705s,@localstatedir@,$localstatedir,;t t
18706s,@libdir@,$libdir,;t t
18707s,@includedir@,$includedir,;t t
18708s,@oldincludedir@,$oldincludedir,;t t
18709s,@infodir@,$infodir,;t t
18710s,@mandir@,$mandir,;t t
503d2be0
AS
18711s,@build_alias@,$build_alias,;t t
18712s,@host_alias@,$host_alias,;t t
18713s,@target_alias@,$target_alias,;t t
c0d27fcc 18714s,@DEFS@,$DEFS,;t t
503d2be0
AS
18715s,@ECHO_C@,$ECHO_C,;t t
18716s,@ECHO_N@,$ECHO_N,;t t
18717s,@ECHO_T@,$ECHO_T,;t t
503d2be0
AS
18718s,@LIBS@,$LIBS,;t t
18719s,@build@,$build,;t t
18720s,@build_cpu@,$build_cpu,;t t
18721s,@build_vendor@,$build_vendor,;t t
18722s,@build_os@,$build_os,;t t
18723s,@host@,$host,;t t
18724s,@host_cpu@,$host_cpu,;t t
18725s,@host_vendor@,$host_vendor,;t t
18726s,@host_os@,$host_os,;t t
18727s,@CC@,$CC,;t t
18728s,@CFLAGS@,$CFLAGS,;t t
18729s,@LDFLAGS@,$LDFLAGS,;t t
18730s,@CPPFLAGS@,$CPPFLAGS,;t t
18731s,@ac_ct_CC@,$ac_ct_CC,;t t
18732s,@EXEEXT@,$EXEEXT,;t t
18733s,@OBJEXT@,$OBJEXT,;t t
18734s,@LN_S@,$LN_S,;t t
18735s,@CPP@,$CPP,;t t
18736s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
18737s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
18738s,@INSTALL_DATA@,$INSTALL_DATA,;t t
503d2be0
AS
18739s,@RANLIB@,$RANLIB,;t t
18740s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
9e71690e 18741s,@INSTALL_INFO@,$INSTALL_INFO,;t t
6bae0ccf 18742s,@EGREP@,$EGREP,;t t
503d2be0
AS
18743s,@LIBSOUND@,$LIBSOUND,;t t
18744s,@SET_MAKE@,$SET_MAKE,;t t
488dd4c4
JD
18745s,@PKG_CONFIG@,$PKG_CONFIG,;t t
18746s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
18747s,@GTK_LIBS@,$GTK_LIBS,;t t
503d2be0
AS
18748s,@ALLOCA@,$ALLOCA,;t t
18749s,@liblockfile@,$liblockfile,;t t
18750s,@LIBOBJS@,$LIBOBJS,;t t
18751s,@NEED_SETGID@,$NEED_SETGID,;t t
18752s,@KMEM_GROUP@,$KMEM_GROUP,;t t
18753s,@GETLOADAVG_LIBS@,$GETLOADAVG_LIBS,;t t
18754s,@version@,$version,;t t
18755s,@configuration@,$configuration,;t t
18756s,@canonical@,$canonical,;t t
18757s,@srcdir@,$srcdir,;t t
18758s,@lispdir@,$lispdir,;t t
18759s,@locallisppath@,$locallisppath,;t t
18760s,@lisppath@,$lisppath,;t t
18761s,@x_default_search_path@,$x_default_search_path,;t t
18762s,@etcdir@,$etcdir,;t t
18763s,@archlibdir@,$archlibdir,;t t
18764s,@docdir@,$docdir,;t t
18765s,@bitmapdir@,$bitmapdir,;t t
98418dba
CW
18766s,@gamedir@,$gamedir,;t t
18767s,@gameuser@,$gameuser,;t t
503d2be0
AS
18768s,@c_switch_system@,$c_switch_system,;t t
18769s,@c_switch_machine@,$c_switch_machine,;t t
18770s,@LD_SWITCH_X_SITE@,$LD_SWITCH_X_SITE,;t t
18771s,@LD_SWITCH_X_SITE_AUX@,$LD_SWITCH_X_SITE_AUX,;t t
18772s,@C_SWITCH_X_SITE@,$C_SWITCH_X_SITE,;t t
18773s,@X_TOOLKIT_TYPE@,$X_TOOLKIT_TYPE,;t t
18774s,@machfile@,$machfile,;t t
18775s,@opsysfile@,$opsysfile,;t t
6a3a24fa 18776s,@carbon_appdir@,$carbon_appdir,;t t
6bae0ccf 18777s,@LTLIBOBJS@,$LTLIBOBJS,;t t
503d2be0
AS
18778CEOF
18779
c0d27fcc 18780_ACEOF
ba4481b5 18781
c0d27fcc 18782 cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18783 # Split the substitutions into bite-sized pieces for seds with
18784 # small command number limits, like on Digital OSF/1 and HP-UX.
18785 ac_max_sed_lines=48
18786 ac_sed_frag=1 # Number of current file.
18787 ac_beg=1 # First line for current file.
18788 ac_end=$ac_max_sed_lines # Line after last line for current file.
18789 ac_more_lines=:
18790 ac_sed_cmds=
18791 while $ac_more_lines; do
18792 if test $ac_beg -gt 1; then
18793 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18794 else
18795 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
18796 fi
18797 if test ! -s $tmp/subs.frag; then
18798 ac_more_lines=false
18799 else
18800 # The purpose of the label and of the branching condition is to
18801 # speed up the sed processing (if there are no `@' at all, there
18802 # is no need to browse any of the substitutions).
18803 # These are the two extra sed commands mentioned above.
18804 (echo ':t
18805 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
18806 if test -z "$ac_sed_cmds"; then
18807 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
18808 else
18809 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
18810 fi
18811 ac_sed_frag=`expr $ac_sed_frag + 1`
18812 ac_beg=$ac_end
18813 ac_end=`expr $ac_end + $ac_max_sed_lines`
18814 fi
18815 done
18816 if test -z "$ac_sed_cmds"; then
18817 ac_sed_cmds=cat
18818 fi
18819fi # test -n "$CONFIG_FILES"
ba4481b5 18820
c0d27fcc
MR
18821_ACEOF
18822cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0 18823for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
ba4481b5 18824 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
18825 case $ac_file in
18826 - | *:- | *:-:* ) # input from stdin
18827 cat >$tmp/stdin
18828 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18829 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18830 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
18831 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
18832 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
18833 esac
18834
503d2be0 18835 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
c0d27fcc
MR
18836 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
18837$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
503d2be0
AS
18838 X"$ac_file" : 'X\(//\)[^/]' \| \
18839 X"$ac_file" : 'X\(//\)$' \| \
18840 X"$ac_file" : 'X\(/\)' \| \
18841 . : '\(.\)' 2>/dev/null ||
18842echo X"$ac_file" |
18843 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18844 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18845 /^X\(\/\/\)$/{ s//\1/; q; }
18846 /^X\(\/\).*/{ s//\1/; q; }
18847 s/.*/./; q'`
6bae0ccf
DL
18848 { if $as_mkdir_p; then
18849 mkdir -p "$ac_dir"
18850 else
18851 as_dir="$ac_dir"
18852 as_dirs=
18853 while test ! -d "$as_dir"; do
18854 as_dirs="$as_dir $as_dirs"
18855 as_dir=`(dirname "$as_dir") 2>/dev/null ||
18856$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18857 X"$as_dir" : 'X\(//\)[^/]' \| \
18858 X"$as_dir" : 'X\(//\)$' \| \
18859 X"$as_dir" : 'X\(/\)' \| \
18860 . : '\(.\)' 2>/dev/null ||
18861echo X"$as_dir" |
18862 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
18863 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
18864 /^X\(\/\/\)$/{ s//\1/; q; }
18865 /^X\(\/\).*/{ s//\1/; q; }
18866 s/.*/./; q'`
18867 done
18868 test ! -n "$as_dirs" || mkdir $as_dirs
18869 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
18870echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
18871 { (exit 1); exit 1; }; }; }
503d2be0 18872
c0d27fcc 18873 ac_builddir=.
98418dba 18874
c0d27fcc
MR
18875if test "$ac_dir" != .; then
18876 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
18877 # A "../" for each directory in $ac_dir_suffix.
18878 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
18879else
18880 ac_dir_suffix= ac_top_builddir=
18881fi
18882
18883case $srcdir in
18884 .) # No --srcdir option. We are building in place.
18885 ac_srcdir=.
18886 if test -z "$ac_top_builddir"; then
18887 ac_top_srcdir=.
18888 else
18889 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
18890 fi ;;
18891 [\\/]* | ?:[\\/]* ) # Absolute path.
18892 ac_srcdir=$srcdir$ac_dir_suffix;
18893 ac_top_srcdir=$srcdir ;;
ba4481b5 18894 *) # Relative path.
c0d27fcc
MR
18895 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
18896 ac_top_srcdir=$ac_top_builddir$srcdir ;;
18897esac
18898# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
18899# absolute.
18900ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
6bae0ccf 18901ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
c0d27fcc
MR
18902ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
18903ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
18904
ba4481b5 18905
503d2be0
AS
18906 case $INSTALL in
18907 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
c0d27fcc 18908 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
ba4481b5
DL
18909 esac
18910
503d2be0 18911 if test x"$ac_file" != x-; then
c0d27fcc 18912 { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
18913echo "$as_me: creating $ac_file" >&6;}
18914 rm -f "$ac_file"
18915 fi
18916 # Let's still pretend it is `configure' which instantiates (i.e., don't
18917 # use $as_me), people would be surprised to read:
c0d27fcc
MR
18918 # /* config.h. Generated by config.status. */
18919 if test x"$ac_file" = x-; then
18920 configure_input=
18921 else
18922 configure_input="$ac_file. "
18923 fi
18924 configure_input=$configure_input"Generated from `echo $ac_file_in |
18925 sed 's,.*/,,'` by configure."
503d2be0
AS
18926
18927 # First look for the input files in the build tree, otherwise in the
18928 # src tree.
18929 ac_file_inputs=`IFS=:
18930 for f in $ac_file_in; do
18931 case $f in
18932 -) echo $tmp/stdin ;;
18933 [\\/$]*)
18934 # Absolute (can't be DOS-style, as IFS=:)
c0d27fcc 18935 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
18936echo "$as_me: error: cannot find input file: $f" >&2;}
18937 { (exit 1); exit 1; }; }
18938 echo $f;;
18939 *) # Relative
18940 if test -f "$f"; then
18941 # Build tree
18942 echo $f
18943 elif test -f "$srcdir/$f"; then
18944 # Source tree
18945 echo $srcdir/$f
18946 else
18947 # /dev/null tree
c0d27fcc 18948 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
18949echo "$as_me: error: cannot find input file: $f" >&2;}
18950 { (exit 1); exit 1; }; }
18951 fi;;
18952 esac
18953 done` || { (exit 1); exit 1; }
c0d27fcc
MR
18954_ACEOF
18955cat >>$CONFIG_STATUS <<_ACEOF
503d2be0
AS
18956 sed "$ac_vpsub
18957$extrasub
c0d27fcc
MR
18958_ACEOF
18959cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
18960:t
18961/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
18962s,@configure_input@,$configure_input,;t t
18963s,@srcdir@,$ac_srcdir,;t t
c0d27fcc 18964s,@abs_srcdir@,$ac_abs_srcdir,;t t
503d2be0 18965s,@top_srcdir@,$ac_top_srcdir,;t t
c0d27fcc
MR
18966s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
18967s,@builddir@,$ac_builddir,;t t
18968s,@abs_builddir@,$ac_abs_builddir,;t t
18969s,@top_builddir@,$ac_top_builddir,;t t
18970s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
503d2be0
AS
18971s,@INSTALL@,$ac_INSTALL,;t t
18972" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
18973 rm -f $tmp/stdin
18974 if test x"$ac_file" != x-; then
18975 mv $tmp/out $ac_file
18976 else
18977 cat $tmp/out
18978 rm -f $tmp/out
18979 fi
18980
18981done
c0d27fcc
MR
18982_ACEOF
18983cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 18984
503d2be0
AS
18985#
18986# CONFIG_HEADER section.
18987#
ba4481b5
DL
18988
18989# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
18990# NAME is the cpp macro being defined and VALUE is the value it is being given.
18991#
18992# ac_d sets the value in "#define NAME VALUE" lines.
503d2be0
AS
18993ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
18994ac_dB='[ ].*$,\1#\2'
18995ac_dC=' '
18996ac_dD=',;t'
18997# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
18998ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
18999ac_uB='$,\1#\2define\3'
ba4481b5 19000ac_uC=' '
503d2be0 19001ac_uD=',;t'
ba4481b5 19002
503d2be0 19003for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
ba4481b5 19004 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
503d2be0
AS
19005 case $ac_file in
19006 - | *:- | *:-:* ) # input from stdin
19007 cat >$tmp/stdin
19008 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19009 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19010 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19011 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19012 * ) ac_file_in=$ac_file.in ;;
ba4481b5
DL
19013 esac
19014
c0d27fcc 19015 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
503d2be0
AS
19016echo "$as_me: creating $ac_file" >&6;}
19017
19018 # First look for the input files in the build tree, otherwise in the
19019 # src tree.
19020 ac_file_inputs=`IFS=:
19021 for f in $ac_file_in; do
19022 case $f in
19023 -) echo $tmp/stdin ;;
19024 [\\/$]*)
19025 # Absolute (can't be DOS-style, as IFS=:)
c0d27fcc 19026 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
19027echo "$as_me: error: cannot find input file: $f" >&2;}
19028 { (exit 1); exit 1; }; }
19029 echo $f;;
19030 *) # Relative
19031 if test -f "$f"; then
19032 # Build tree
19033 echo $f
19034 elif test -f "$srcdir/$f"; then
19035 # Source tree
19036 echo $srcdir/$f
19037 else
19038 # /dev/null tree
c0d27fcc 19039 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
503d2be0
AS
19040echo "$as_me: error: cannot find input file: $f" >&2;}
19041 { (exit 1); exit 1; }; }
19042 fi;;
19043 esac
19044 done` || { (exit 1); exit 1; }
19045 # Remove the trailing spaces.
19046 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
19047
c0d27fcc 19048_ACEOF
503d2be0
AS
19049
19050# Transform confdefs.h into two sed scripts, `conftest.defines' and
19051# `conftest.undefs', that substitutes the proper values into
19052# config.h.in to produce config.h. The first handles `#define'
19053# templates, and the second `#undef' templates.
19054# And first: Protect against being on the right side of a sed subst in
19055# config.status. Protect against being in an unquoted here document
19056# in config.status.
19057rm -f conftest.defines conftest.undefs
19058# Using a here document instead of a string reduces the quoting nightmare.
19059# Putting comments in sed scripts is not portable.
19060#
19061# `end' is used to avoid that the second main sed command (meant for
19062# 0-ary CPP macros) applies to n-ary macro definitions.
19063# See the Autoconf documentation for `clear'.
c0d27fcc 19064cat >confdef2sed.sed <<\_ACEOF
503d2be0
AS
19065s/[\\&,]/\\&/g
19066s,[\\$`],\\&,g
19067t clear
19068: clear
c0d27fcc 19069s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
503d2be0
AS
19070t end
19071s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
19072: end
c0d27fcc 19073_ACEOF
503d2be0
AS
19074# If some macros were called several times there might be several times
19075# the same #defines, which is useless. Nevertheless, we may not want to
19076# sort them, since we want the *last* AC-DEFINE to be honored.
19077uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
19078sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
19079rm -f confdef2sed.sed
ba4481b5
DL
19080
19081# This sed command replaces #undef with comments. This is necessary, for
19082# example, in the case of _POSIX_SOURCE, which is predefined and required
19083# on some systems where configure will not decide to define it.
c0d27fcc 19084cat >>conftest.undefs <<\_ACEOF
503d2be0 19085s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
c0d27fcc 19086_ACEOF
ba4481b5 19087
503d2be0
AS
19088# Break up conftest.defines because some shells have a limit on the size
19089# of here documents, and old seds have small limits too (100 cmds).
19090echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
6bae0ccf 19091echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
503d2be0
AS
19092echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
19093echo ' :' >>$CONFIG_STATUS
19094rm -f conftest.tail
19095while grep . conftest.defines >/dev/null
19096do
19097 # Write a limited-size here document to $tmp/defines.sed.
19098 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
19099 # Speed up: don't consider the non `#define' lines.
19100 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
19101 # Work around the forget-to-reset-the-flag bug.
19102 echo 't clr' >>$CONFIG_STATUS
19103 echo ': clr' >>$CONFIG_STATUS
19104 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
19105 echo 'CEOF
19106 sed -f $tmp/defines.sed $tmp/in >$tmp/out
19107 rm -f $tmp/in
19108 mv $tmp/out $tmp/in
19109' >>$CONFIG_STATUS
19110 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
19111 rm -f conftest.defines
19112 mv conftest.tail conftest.defines
19113done
19114rm -f conftest.defines
6bae0ccf 19115echo ' fi # grep' >>$CONFIG_STATUS
503d2be0 19116echo >>$CONFIG_STATUS
ba4481b5 19117
503d2be0
AS
19118# Break up conftest.undefs because some shells have a limit on the size
19119# of here documents, and old seds have small limits too (100 cmds).
19120echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
ba4481b5 19121rm -f conftest.tail
503d2be0 19122while grep . conftest.undefs >/dev/null
ba4481b5 19123do
503d2be0
AS
19124 # Write a limited-size here document to $tmp/undefs.sed.
19125 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
19126 # Speed up: don't consider the non `#undef'
19127 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
19128 # Work around the forget-to-reset-the-flag bug.
19129 echo 't clr' >>$CONFIG_STATUS
19130 echo ': clr' >>$CONFIG_STATUS
19131 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
ba4481b5 19132 echo 'CEOF
503d2be0
AS
19133 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
19134 rm -f $tmp/in
19135 mv $tmp/out $tmp/in
19136' >>$CONFIG_STATUS
19137 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
19138 rm -f conftest.undefs
19139 mv conftest.tail conftest.undefs
ba4481b5 19140done
503d2be0
AS
19141rm -f conftest.undefs
19142
c0d27fcc 19143cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
19144 # Let's still pretend it is `configure' which instantiates (i.e., don't
19145 # use $as_me), people would be surprised to read:
c0d27fcc 19146 # /* config.h. Generated by config.status. */
503d2be0 19147 if test x"$ac_file" = x-; then
c0d27fcc 19148 echo "/* Generated by configure. */" >$tmp/config.h
ba4481b5 19149 else
c0d27fcc 19150 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
503d2be0
AS
19151 fi
19152 cat $tmp/in >>$tmp/config.h
19153 rm -f $tmp/in
19154 if test x"$ac_file" != x-; then
cd958eb3 19155 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
c0d27fcc 19156 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
503d2be0
AS
19157echo "$as_me: $ac_file is unchanged" >&6;}
19158 else
c0d27fcc
MR
19159 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19160$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
503d2be0
AS
19161 X"$ac_file" : 'X\(//\)[^/]' \| \
19162 X"$ac_file" : 'X\(//\)$' \| \
19163 X"$ac_file" : 'X\(/\)' \| \
19164 . : '\(.\)' 2>/dev/null ||
19165echo X"$ac_file" |
19166 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19167 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19168 /^X\(\/\/\)$/{ s//\1/; q; }
19169 /^X\(\/\).*/{ s//\1/; q; }
19170 s/.*/./; q'`
6bae0ccf
DL
19171 { if $as_mkdir_p; then
19172 mkdir -p "$ac_dir"
19173 else
19174 as_dir="$ac_dir"
19175 as_dirs=
19176 while test ! -d "$as_dir"; do
19177 as_dirs="$as_dir $as_dirs"
19178 as_dir=`(dirname "$as_dir") 2>/dev/null ||
19179$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19180 X"$as_dir" : 'X\(//\)[^/]' \| \
19181 X"$as_dir" : 'X\(//\)$' \| \
19182 X"$as_dir" : 'X\(/\)' \| \
19183 . : '\(.\)' 2>/dev/null ||
19184echo X"$as_dir" |
19185 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19186 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19187 /^X\(\/\/\)$/{ s//\1/; q; }
19188 /^X\(\/\).*/{ s//\1/; q; }
19189 s/.*/./; q'`
19190 done
19191 test ! -n "$as_dirs" || mkdir $as_dirs
19192 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
19193echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
19194 { (exit 1); exit 1; }; }; }
503d2be0 19195
503d2be0
AS
19196 rm -f $ac_file
19197 mv $tmp/config.h $ac_file
ba4481b5 19198 fi
503d2be0
AS
19199 else
19200 cat $tmp/config.h
19201 rm -f $tmp/config.h
ba4481b5 19202 fi
503d2be0 19203done
c0d27fcc
MR
19204_ACEOF
19205cat >>$CONFIG_STATUS <<\_ACEOF
503d2be0
AS
19206
19207#
19208# CONFIG_COMMANDS section.
19209#
19210for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
19211 ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
19212 ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
c0d27fcc
MR
19213 ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
19214$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19215 X"$ac_dest" : 'X\(//\)[^/]' \| \
19216 X"$ac_dest" : 'X\(//\)$' \| \
19217 X"$ac_dest" : 'X\(/\)' \| \
19218 . : '\(.\)' 2>/dev/null ||
19219echo X"$ac_dest" |
19220 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19221 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19222 /^X\(\/\/\)$/{ s//\1/; q; }
19223 /^X\(\/\).*/{ s//\1/; q; }
19224 s/.*/./; q'`
19225 ac_builddir=.
19226
19227if test "$ac_dir" != .; then
19228 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19229 # A "../" for each directory in $ac_dir_suffix.
19230 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19231else
19232 ac_dir_suffix= ac_top_builddir=
19233fi
19234
19235case $srcdir in
19236 .) # No --srcdir option. We are building in place.
19237 ac_srcdir=.
19238 if test -z "$ac_top_builddir"; then
19239 ac_top_srcdir=.
19240 else
19241 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19242 fi ;;
19243 [\\/]* | ?:[\\/]* ) # Absolute path.
19244 ac_srcdir=$srcdir$ac_dir_suffix;
19245 ac_top_srcdir=$srcdir ;;
19246 *) # Relative path.
19247 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19248 ac_top_srcdir=$ac_top_builddir$srcdir ;;
19249esac
19250# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19251# absolute.
19252ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
6bae0ccf 19253ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
c0d27fcc
MR
19254ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19255ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
ba4481b5 19256
c0d27fcc
MR
19257
19258 { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
19259echo "$as_me: executing $ac_dest commands" >&6;}
503d2be0
AS
19260 case $ac_dest in
19261 default )
ba4481b5
DL
19262
19263### Make the necessary directories, if they don't exist.
19264for dir in etc lisp ; do
19265 test -d ${dir} || mkdir ${dir}
19266done
19267
19268# Build src/Makefile from ${srcdir}/src/Makefile.c
19269# and lib-src/Makefile from ${srcdir}/lib-src/Makefile.c
19270# This must be done after src/config.h is built, since we rely on that file.
19271
19272# Now get this: Some word that is part of the ${srcdir} directory name
19273# or the ${configuration} value might, just might, happen to be an
19274# identifier like `sun4' or `i386' or something, and be predefined by
19275# the C preprocessor to some helpful value like 1, or maybe the empty
19276# string. Needless to say consequent macro substitutions are less
19277# than conducive to the makefile finding the correct directory.
19278undefs="`echo $top_srcdir $configuration $canonical |
19279sed -e 's/[^a-zA-Z0-9_]/ /g' -e 's/^/ /' -e 's/ *$//' \
19280 -e 's/ */ -U/g' -e 's/-U[0-9][^ ]*//g' \
19281`"
19282
19283echo creating src/epaths.h
4aa6b955 19284${MAKE-make} epaths-force
ba4481b5 19285
1c203d4c
DL
19286# As of 2000-11-19, newest development versions of GNU cpp preprocess
19287# `..' to `. .' unless invoked with -traditional
19288
d0e9bfd2 19289if test "x$GCC" = xyes && test "x$CPP_NEED_TRADITIONAL" = xyes; then
1c203d4c
DL
19290 CPPFLAGS="$CPPFLAGS -traditional"
19291fi
19292
ba4481b5
DL
19293echo creating lib-src/Makefile
19294( cd lib-src
19295 rm -f junk.c junk1.c junk2.c
19296 sed -e '/start of cpp stuff/q' \
19297 < Makefile.c > junk1.c
19298 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 19299 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 19300 < Makefile.c > junk.c
503d2be0 19301 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
19302 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
19303 cat junk1.c junk2.c > Makefile.new
19304 rm -f junk.c junk1.c junk2.c
19305 chmod 444 Makefile.new
19306 mv -f Makefile.new Makefile
19307)
19308
19309echo creating src/Makefile
19310( cd src
19311 rm -f junk.c junk1.c junk2.c
19312 sed -e '/start of cpp stuff/q' \
19313 < Makefile.c > junk1.c
19314 sed -e '1,/start of cpp stuff/d'\
9a72e4c1 19315 -e 's,/\*\*/#\(.*\)$,/* \1 */,' \
ba4481b5 19316 < Makefile.c > junk.c
503d2be0 19317 $CPP $undefs -I. -I$srcdir/src $CPPFLAGS junk.c | \
ba4481b5
DL
19318 sed -e 's/^ / /' -e '/^#/d' -e '/^[ \f]*$/d' > junk2.c
19319 cat junk1.c junk2.c > Makefile.new
19320 rm -f junk.c junk1.c junk2.c
19321 chmod 444 Makefile.new
19322 mv -f Makefile.new Makefile
19323)
19324
503d2be0 19325if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
ba4481b5 19326 echo creating src/.gdbinit
503d2be0 19327 echo source $srcdir/src/.gdbinit > src/.gdbinit
ba4481b5
DL
19328fi
19329
19330# This is how we know whether to re-run configure in certain cases.
19331touch src/config.stamp
19332
503d2be0
AS
19333 ;;
19334 esac
19335done
c0d27fcc 19336_ACEOF
503d2be0 19337
c0d27fcc 19338cat >>$CONFIG_STATUS <<\_ACEOF
ba4481b5 19339
503d2be0 19340{ (exit 0); exit 0; }
c0d27fcc 19341_ACEOF
ba4481b5 19342chmod +x $CONFIG_STATUS
503d2be0
AS
19343ac_clean_files=$ac_clean_files_save
19344
c0d27fcc 19345
503d2be0
AS
19346# configure is writing to config.log, and then calls config.status.
19347# config.status does its own redirection, appending to config.log.
19348# Unfortunately, on DOS this fails, as config.log is still kept open
19349# by configure, so config.status won't be able to write to it; its
19350# output is simply discarded. So we exec the FD to /dev/null,
19351# effectively closing config.log, so it can be properly (re)opened and
19352# appended to by config.status. When coming back to configure, we
19353# need to make the FD available again.
19354if test "$no_create" != yes; then
19355 ac_cs_success=:
cd958eb3
MB
19356 ac_config_status_args=
19357 test "$silent" = yes &&
19358 ac_config_status_args="$ac_config_status_args --quiet"
503d2be0 19359 exec 5>/dev/null
cd958eb3 19360 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
503d2be0
AS
19361 exec 5>>config.log
19362 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19363 # would make configure fail if this is the last instruction.
19364 $ac_cs_success || { (exit 1); exit 1; }
19365fi
f5f47add 19366
c0d27fcc 19367