Configure wording tweak.
[bpt/emacs.git] / autogen / configure
CommitLineData
067d23c9
KY
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
d570ce1c 3# Generated by GNU Autoconf 2.65 for emacs 24.0.93.
067d23c9
KY
4#
5#
6# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
a9bec17c
GM
7# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8# Inc.
067d23c9
KY
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81fi
82
83
84# IFS
85# We need space, tab and new line, in precisely that order. Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" "" $as_nl"
90
91# Find who we are. Look in the path if we contain no directory separator.
92case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95for as_dir in $PATH
96do
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101IFS=$as_save_IFS
102
103 ;;
104esac
105# We did not find ourselves, most probably we were run as `sh COMMAND'
106# in which case we are not to be found in the path.
107if test "x$as_myself" = x; then
108 as_myself=$0
109fi
110if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
113fi
114
115# Unset variables that we do not need and which cause bugs (e.g. in
116# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117# suppresses any "Segmentation fault" message there. '((' could
118# trigger a bug in pdksh 5.2.14.
119for as_var in BASH_ENV ENV MAIL MAILPATH
120do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122done
123PS1='$ '
124PS2='> '
125PS4='+ '
126
127# NLS nuisances.
128LC_ALL=C
129export LC_ALL
130LANGUAGE=C
131export LANGUAGE
132
133# CDPATH.
134(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
149 ;;
150esac
151fi
152"
153 as_required="as_fn_return () { (exit \$1); }
154as_fn_success () { as_fn_return 0; }
155as_fn_failure () { as_fn_return 1; }
156as_fn_ret_success () { return 0; }
157as_fn_ret_failure () { return 1; }
158
159exitcode=0
160as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
165
166else
167 exitcode=1; echo positional parameters were not saved.
168fi
169test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177else
178 as_have_required=no
179fi
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
182else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184as_found=false
185for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
186do
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
191 /*)
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
200fi
201fi
202 done;;
203 esac
204 as_found=false
205done
206$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209fi; }
210IFS=$as_save_IFS
211
212
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
a9bec17c 221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
067d23c9
KY
222fi
223
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232$0: including any error possibly output before this
233$0: message. Then install a modern shell, or manually run
234$0: the script under such a shell if you do have one."
235 fi
236 exit 1
237fi
238fi
239fi
240SHELL=${CONFIG_SHELL-/bin/sh}
241export SHELL
242# Unset more variables known to interfere with behavior of common tools.
243CLICOLOR_FORCE= GREP_OPTIONS=
244unset CLICOLOR_FORCE GREP_OPTIONS
245
246## --------------------- ##
247## M4sh Shell Functions. ##
248## --------------------- ##
249# as_fn_unset VAR
250# ---------------
251# Portably unset VAR.
252as_fn_unset ()
253{
254 { eval $1=; unset $1;}
255}
256as_unset=as_fn_unset
257
258# as_fn_set_status STATUS
259# -----------------------
260# Set $? to STATUS, without forking.
261as_fn_set_status ()
262{
263 return $1
264} # as_fn_set_status
265
266# as_fn_exit STATUS
267# -----------------
268# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269as_fn_exit ()
270{
271 set +e
272 as_fn_set_status $1
273 exit $1
274} # as_fn_exit
275
276# as_fn_mkdir_p
277# -------------
278# Create "$as_dir" as a directory, including parents if necessary.
279as_fn_mkdir_p ()
280{
281
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298$as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
301 q
302 }
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
305 q
306 }
307 /^X\(\/\/\)$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\).*/{
312 s//\1/
313 q
314 }
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
a9bec17c 319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
067d23c9
KY
320
321
322} # as_fn_mkdir_p
323# as_fn_append VAR VALUE
324# ----------------------
325# Append the text in VALUE to the end of the definition contained in VAR. Take
326# advantage of any shell optimizations that allow amortized linear growth over
327# repeated appends, instead of the typical quadratic growth present in naive
328# implementations.
329if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
331 {
332 eval $1+=\$2
333 }'
334else
335 as_fn_append ()
336 {
337 eval $1=\$$1\$2
338 }
339fi # as_fn_append
340
341# as_fn_arith ARG...
342# ------------------
343# Perform arithmetic evaluation on the ARGs, and store the result in the
344# global $as_val. Take advantage of shells that can avoid forks. The arguments
345# must be portable across $(()) and expr.
346if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
348 {
349 as_val=$(( $* ))
350 }'
351else
352 as_fn_arith ()
353 {
354 as_val=`expr "$@" || test $? -eq 1`
355 }
356fi # as_fn_arith
357
358
a9bec17c
GM
359# as_fn_error ERROR [LINENO LOG_FD]
360# ---------------------------------
067d23c9
KY
361# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
a9bec17c 363# script with status $?, using 1 if that was 0.
067d23c9
KY
364as_fn_error ()
365{
a9bec17c
GM
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
067d23c9 370 fi
a9bec17c 371 $as_echo "$as_me: error: $1" >&2
067d23c9
KY
372 as_fn_exit $as_status
373} # as_fn_error
374
375if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378else
379 as_expr=false
380fi
381
382if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384else
385 as_basename=false
386fi
387
388if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390else
391 as_dirname=false
392fi
393
394as_me=`$as_basename -- "$0" ||
395$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398$as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
401 q
402 }
403 /^X\/\(\/\/\)$/{
404 s//\1/
405 q
406 }
407 /^X\/\(\/\).*/{
408 s//\1/
409 q
410 }
411 s/.*/./; q'`
412
413# Avoid depending upon Character Ranges.
414as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417as_cr_digits='0123456789'
418as_cr_alnum=$as_cr_Letters$as_cr_digits
419
420
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
427 p
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
433 b
434 :lineno
435 N
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
443
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
450}
451
452ECHO_C= ECHO_N= ECHO_T=
453case `echo -n x` in #(((((
454-n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
461*)
462 ECHO_N='-n';;
463esac
464
465rm -f conf$$ conf$$.exe conf$$.file
466if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
471fi
472if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
485 fi
486else
487 as_ln_s='cp -p'
488fi
489rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490rmdir conf$$.dir 2>/dev/null
491
492if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
497fi
498
499if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
506 fi
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
518 '
519fi
520as_executable_p=$as_test_x
521
522# Sed expression to map a string onto a valid CPP name.
523as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525# Sed expression to map a string onto a valid variable name.
526as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529test -n "$DJDIR" || exec 7<&0 </dev/null
530exec 6>&1
531
532# Name of the host.
a9bec17c 533# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
067d23c9
KY
534# so uname gets run too.
535ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
536
537#
538# Initializations.
539#
540ac_default_prefix=/usr/local
541ac_clean_files=
542ac_config_libobj_dir=.
543LIBOBJS=
544cross_compiling=no
545subdirs=
546MFLAGS=
547MAKEFLAGS=
548
549# Identity of this package.
550PACKAGE_NAME='emacs'
551PACKAGE_TARNAME='emacs'
d570ce1c
GM
552PACKAGE_VERSION='24.0.93'
553PACKAGE_STRING='emacs 24.0.93'
067d23c9
KY
554PACKAGE_BUGREPORT=''
555PACKAGE_URL=''
556
557ac_unique_file="src/lisp.h"
558# Factoring default headers for most tests.
559ac_includes_default="\
560#include <stdio.h>
561#ifdef HAVE_SYS_TYPES_H
562# include <sys/types.h>
563#endif
564#ifdef HAVE_SYS_STAT_H
565# include <sys/stat.h>
566#endif
567#ifdef STDC_HEADERS
568# include <stdlib.h>
569# include <stddef.h>
570#else
571# ifdef HAVE_STDLIB_H
572# include <stdlib.h>
573# endif
574#endif
575#ifdef HAVE_STRING_H
576# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577# include <memory.h>
578# endif
579# include <string.h>
580#endif
581#ifdef HAVE_STRINGS_H
582# include <strings.h>
583#endif
584#ifdef HAVE_INTTYPES_H
585# include <inttypes.h>
586#endif
587#ifdef HAVE_STDINT_H
588# include <stdint.h>
589#endif
590#ifdef HAVE_UNISTD_H
591# include <unistd.h>
592#endif"
593
067d23c9 594ac_header_list=
6c051bab 595ac_func_list=
e275c824
PE
596gl_getopt_required=POSIX
597gl_getopt_required=POSIX
743c80a7
PE
598ac_subst_vars='gltests_LTLIBOBJS
599gltests_LIBOBJS
600gl_LTLIBOBJS
601gl_LIBOBJS
602am__EXEEXT_FALSE
603am__EXEEXT_TRUE
604LTLIBOBJS
1f5d53eb 605LIBOBJS
73b78882 606SUBDIR_MAKEFILES_IN
067d23c9
KY
607LIB_GCC
608LD_FIRSTFLAG
609LD_SWITCH_SYSTEM_TEMACS
743c80a7
PE
610LIBGNU_LTLIBDEPS
611LIBGNU_LIBDEPS
612gltests_WITNESS
6d153f56
GM
613gl_GNULIB_ENABLED_verify_FALSE
614gl_GNULIB_ENABLED_verify_TRUE
615gl_GNULIB_ENABLED_strtoull_FALSE
616gl_GNULIB_ENABLED_strtoull_TRUE
3e0be4ab
GM
617gl_GNULIB_ENABLED_strtoll_FALSE
618gl_GNULIB_ENABLED_strtoll_TRUE
6d153f56
GM
619gl_GNULIB_ENABLED_stat_FALSE
620gl_GNULIB_ENABLED_stat_TRUE
3e0be4ab
GM
621gl_GNULIB_ENABLED_sigprocmask_FALSE
622gl_GNULIB_ENABLED_sigprocmask_TRUE
a0a61e58
GM
623gl_GNULIB_ENABLED_pathmax_FALSE
624gl_GNULIB_ENABLED_pathmax_TRUE
6d153f56
GM
625gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
626gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
627gl_GNULIB_ENABLED_dosname_FALSE
628gl_GNULIB_ENABLED_dosname_TRUE
629LTLIBINTL
630LIBINTL
e275c824
PE
631HAVE_UNISTD_H
632NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
633NEXT_UNISTD_H
1fd182f0
PE
634PTHREAD_H_DEFINES_STRUCT_TIMESPEC
635SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
636TIME_H_DEFINES_STRUCT_TIMESPEC
637NEXT_AS_FIRST_DIRECTIVE_TIME_H
638NEXT_TIME_H
5fa4ac76
PE
639NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
640NEXT_SYS_STAT_H
1f5d53eb
PE
641NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
642NEXT_STDLIB_H
6ad6792b
GM
643NEXT_AS_FIRST_DIRECTIVE_STDIO_H
644NEXT_STDIO_H
645REPLACE_VSPRINTF
646REPLACE_VSNPRINTF
647REPLACE_VPRINTF
648REPLACE_VFPRINTF
649REPLACE_VDPRINTF
650REPLACE_VASPRINTF
651REPLACE_TMPFILE
652REPLACE_STDIO_WRITE_FUNCS
ca36e0ff 653REPLACE_STDIO_READ_FUNCS
6ad6792b
GM
654REPLACE_SPRINTF
655REPLACE_SNPRINTF
656REPLACE_RENAMEAT
657REPLACE_RENAME
658REPLACE_REMOVE
659REPLACE_PRINTF
660REPLACE_POPEN
661REPLACE_PERROR
662REPLACE_OBSTACK_PRINTF
663REPLACE_GETLINE
664REPLACE_GETDELIM
665REPLACE_FTELLO
666REPLACE_FTELL
667REPLACE_FSEEKO
668REPLACE_FSEEK
669REPLACE_FREOPEN
670REPLACE_FPURGE
671REPLACE_FPRINTF
672REPLACE_FOPEN
673REPLACE_FFLUSH
2b1928b8 674REPLACE_FDOPEN
6ad6792b
GM
675REPLACE_FCLOSE
676REPLACE_DPRINTF
677HAVE_VDPRINTF
678HAVE_VASPRINTF
679HAVE_RENAMEAT
2b1928b8
GM
680HAVE_POPEN
681HAVE_PCLOSE
6ad6792b
GM
682HAVE_FTELLO
683HAVE_FSEEKO
684HAVE_DPRINTF
685HAVE_DECL_VSNPRINTF
686HAVE_DECL_SNPRINTF
687HAVE_DECL_OBSTACK_PRINTF
688HAVE_DECL_GETLINE
689HAVE_DECL_GETDELIM
690HAVE_DECL_FTELLO
691HAVE_DECL_FSEEKO
692HAVE_DECL_FPURGE
693GNULIB_VSPRINTF_POSIX
694GNULIB_VSNPRINTF
695GNULIB_VPRINTF_POSIX
696GNULIB_VPRINTF
697GNULIB_VFPRINTF_POSIX
698GNULIB_VFPRINTF
699GNULIB_VDPRINTF
ca36e0ff
GM
700GNULIB_VSCANF
701GNULIB_VFSCANF
6ad6792b
GM
702GNULIB_VASPRINTF
703GNULIB_TMPFILE
704GNULIB_STDIO_H_SIGPIPE
ca36e0ff 705GNULIB_STDIO_H_NONBLOCKING
6ad6792b
GM
706GNULIB_SPRINTF_POSIX
707GNULIB_SNPRINTF
ca36e0ff 708GNULIB_SCANF
6ad6792b
GM
709GNULIB_RENAMEAT
710GNULIB_RENAME
711GNULIB_REMOVE
712GNULIB_PUTS
713GNULIB_PUTCHAR
714GNULIB_PUTC
715GNULIB_PRINTF_POSIX
716GNULIB_PRINTF
717GNULIB_POPEN
718GNULIB_PERROR
2b1928b8 719GNULIB_PCLOSE
6ad6792b
GM
720GNULIB_OBSTACK_PRINTF_POSIX
721GNULIB_OBSTACK_PRINTF
ca36e0ff 722GNULIB_GETS
6ad6792b
GM
723GNULIB_GETLINE
724GNULIB_GETDELIM
ca36e0ff
GM
725GNULIB_GETCHAR
726GNULIB_GETC
6ad6792b
GM
727GNULIB_FWRITE
728GNULIB_FTELLO
729GNULIB_FTELL
730GNULIB_FSEEKO
731GNULIB_FSEEK
ca36e0ff 732GNULIB_FSCANF
6ad6792b 733GNULIB_FREOPEN
ca36e0ff 734GNULIB_FREAD
6ad6792b
GM
735GNULIB_FPUTS
736GNULIB_FPUTC
737GNULIB_FPURGE
738GNULIB_FPRINTF_POSIX
739GNULIB_FPRINTF
740GNULIB_FOPEN
ca36e0ff
GM
741GNULIB_FGETS
742GNULIB_FGETC
6ad6792b 743GNULIB_FFLUSH
2b1928b8 744GNULIB_FDOPEN
6ad6792b
GM
745GNULIB_FCLOSE
746GNULIB_DPRINTF
1fd182f0
PE
747NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
748NEXT_STDDEF_H
6c051bab
GM
749GL_GENERATE_STDDEF_H_FALSE
750GL_GENERATE_STDDEF_H_TRUE
1fd182f0
PE
751STDDEF_H
752HAVE_WCHAR_T
753REPLACE_NULL
16c3e636 754HAVE__BOOL
6c051bab
GM
755GL_GENERATE_STDBOOL_H_FALSE
756GL_GENERATE_STDBOOL_H_TRUE
16c3e636 757STDBOOL_H
6d153f56
GM
758GL_GENERATE_STDARG_H_FALSE
759GL_GENERATE_STDARG_H_TRUE
760STDARG_H
761NEXT_AS_FIRST_DIRECTIVE_STDARG_H
762NEXT_STDARG_H
3e0be4ab
GM
763NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
764NEXT_SIGNAL_H
2b1928b8 765REPLACE_RAISE
3e0be4ab
GM
766REPLACE_PTHREAD_SIGMASK
767HAVE_SIGHANDLER_T
768HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
769HAVE_STRUCT_SIGACTION_SA_SIGACTION
770HAVE_SIGACTION
771HAVE_SIGINFO_T
772HAVE_SIGSET_T
2b1928b8 773HAVE_RAISE
3e0be4ab
GM
774HAVE_PTHREAD_SIGMASK
775HAVE_POSIX_SIGNALBLOCKING
776GNULIB_SIGACTION
777GNULIB_SIGPROCMASK
778GNULIB_SIGNAL_H_SIGPIPE
2b1928b8 779GNULIB_RAISE
3e0be4ab
GM
780GNULIB_PTHREAD_SIGMASK
781LIB_PTHREAD_SIGMASK
1fd182f0
PE
782REPLACE_TIMEGM
783REPLACE_NANOSLEEP
784REPLACE_MKTIME
785REPLACE_LOCALTIME_R
786HAVE_TIMEGM
787HAVE_STRPTIME
788HAVE_NANOSLEEP
789HAVE_DECL_LOCALTIME_R
790GNULIB_TIME_R
791GNULIB_TIMEGM
792GNULIB_STRPTIME
793GNULIB_NANOSLEEP
794GNULIB_MKTIME
ae0d7250
PE
795REPLACE_UTIMENSAT
796REPLACE_STAT
797REPLACE_MKNOD
798REPLACE_MKFIFO
799REPLACE_MKDIR
800REPLACE_LSTAT
801REPLACE_FUTIMENS
802REPLACE_FSTATAT
803REPLACE_FSTAT
804HAVE_UTIMENSAT
805HAVE_MKNODAT
806HAVE_MKNOD
807HAVE_MKFIFOAT
808HAVE_MKFIFO
809HAVE_MKDIRAT
810HAVE_LSTAT
811HAVE_LCHMOD
812HAVE_FUTIMENS
813HAVE_FSTATAT
814HAVE_FCHMODAT
815GNULIB_UTIMENSAT
816GNULIB_STAT
817GNULIB_MKNODAT
818GNULIB_MKNOD
819GNULIB_MKFIFOAT
820GNULIB_MKFIFO
821GNULIB_MKDIRAT
822GNULIB_LSTAT
823GNULIB_LCHMOD
824GNULIB_FUTIMENS
825GNULIB_FSTATAT
2b1928b8 826GNULIB_FSTAT
ae0d7250 827GNULIB_FCHMODAT
4fda9c95
GM
828NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
829NEXT_INTTYPES_H
830UINT64_MAX_EQ_ULONG_MAX
831UINT32_MAX_LT_UINTMAX_MAX
832PRIPTR_PREFIX
833PRI_MACROS_BROKEN
834INT64_MAX_EQ_LONG_MAX
835INT32_MAX_LT_INTMAX_MAX
836HAVE_DECL_STRTOUMAX
837HAVE_DECL_STRTOIMAX
838HAVE_DECL_IMAXDIV
839HAVE_DECL_IMAXABS
840GNULIB_STRTOUMAX
841GNULIB_STRTOIMAX
842GNULIB_IMAXDIV
843GNULIB_IMAXABS
844GL_GENERATE_STDINT_H_FALSE
845GL_GENERATE_STDINT_H_TRUE
846STDINT_H
847WINT_T_SUFFIX
848WCHAR_T_SUFFIX
849SIG_ATOMIC_T_SUFFIX
850SIZE_T_SUFFIX
851PTRDIFF_T_SUFFIX
852HAVE_SIGNED_WINT_T
853HAVE_SIGNED_WCHAR_T
854HAVE_SIGNED_SIG_ATOMIC_T
855BITSIZEOF_WINT_T
856BITSIZEOF_WCHAR_T
857BITSIZEOF_SIG_ATOMIC_T
858BITSIZEOF_SIZE_T
859BITSIZEOF_PTRDIFF_T
860APPLE_UNIVERSAL_BUILD
861HAVE_SYS_BITYPES_H
862HAVE_SYS_INTTYPES_H
863HAVE_STDINT_H
864NEXT_AS_FIRST_DIRECTIVE_STDINT_H
865NEXT_STDINT_H
866HAVE_SYS_TYPES_H
867HAVE_INTTYPES_H
868HAVE_WCHAR_H
869HAVE_UNSIGNED_LONG_LONG_INT
870HAVE_LONG_LONG_INT
e275c824
PE
871GETOPT_H
872HAVE_GETOPT_H
873NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
874NEXT_GETOPT_H
875PRAGMA_COLUMNS
876PRAGMA_SYSTEM_HEADER
877INCLUDE_NEXT_AS_FIRST_DIRECTIVE
878INCLUDE_NEXT
7d2a1c5e
GM
879GETLOADAVG_LIBS
880REPLACE_WCTOMB
881REPLACE_UNSETENV
882REPLACE_STRTOD
883REPLACE_SETENV
884REPLACE_REALPATH
885REPLACE_REALLOC
886REPLACE_PUTENV
887REPLACE_MKSTEMP
888REPLACE_MBTOWC
889REPLACE_MALLOC
890REPLACE_CANONICALIZE_FILE_NAME
891REPLACE_CALLOC
892HAVE_DECL_UNSETENV
893HAVE_UNLOCKPT
894HAVE_SYS_LOADAVG_H
895HAVE_STRUCT_RANDOM_DATA
896HAVE_STRTOULL
897HAVE_STRTOLL
898HAVE_STRTOD
899HAVE_DECL_SETENV
900HAVE_SETENV
901HAVE_RPMATCH
902HAVE_REALPATH
903HAVE_RANDOM_R
904HAVE_RANDOM_H
905HAVE_PTSNAME
906HAVE_MKSTEMPS
907HAVE_MKSTEMP
908HAVE_MKOSTEMPS
909HAVE_MKOSTEMP
910HAVE_MKDTEMP
911HAVE_GRANTPT
912HAVE_GETSUBOPT
913HAVE_DECL_GETLOADAVG
914HAVE_CANONICALIZE_FILE_NAME
915HAVE_ATOLL
916HAVE__EXIT
917GNULIB_WCTOMB
918GNULIB_UNSETENV
919GNULIB_UNLOCKPT
920GNULIB_SYSTEM_POSIX
921GNULIB_STRTOULL
922GNULIB_STRTOLL
923GNULIB_STRTOD
924GNULIB_SETENV
925GNULIB_RPMATCH
926GNULIB_REALPATH
927GNULIB_REALLOC_POSIX
928GNULIB_RANDOM_R
929GNULIB_PUTENV
930GNULIB_PTSNAME
931GNULIB_MKSTEMPS
932GNULIB_MKSTEMP
933GNULIB_MKOSTEMPS
934GNULIB_MKOSTEMP
935GNULIB_MKDTEMP
936GNULIB_MBTOWC
937GNULIB_MALLOC_POSIX
938GNULIB_GRANTPT
939GNULIB_GETSUBOPT
940GNULIB_GETLOADAVG
941GNULIB_CANONICALIZE_FILE_NAME
942GNULIB_CALLOC_POSIX
943GNULIB_ATOLL
944GNULIB__EXIT
e275c824
PE
945UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
946UNISTD_H_HAVE_WINSOCK2_H
947REPLACE_WRITE
948REPLACE_USLEEP
949REPLACE_UNLINKAT
950REPLACE_UNLINK
951REPLACE_TTYNAME_R
952REPLACE_SYMLINK
953REPLACE_SLEEP
954REPLACE_RMDIR
955REPLACE_READLINK
ca36e0ff 956REPLACE_READ
e275c824
PE
957REPLACE_PWRITE
958REPLACE_PREAD
959REPLACE_LSEEK
960REPLACE_LINKAT
961REPLACE_LINK
962REPLACE_LCHOWN
963REPLACE_GETPAGESIZE
964REPLACE_GETGROUPS
965REPLACE_GETLOGIN_R
966REPLACE_GETDOMAINNAME
967REPLACE_GETCWD
968REPLACE_FCHOWNAT
969REPLACE_DUP2
970REPLACE_DUP
971REPLACE_CLOSE
972REPLACE_CHOWN
973HAVE_SYS_PARAM_H
974HAVE_OS_H
975HAVE_DECL_TTYNAME_R
976HAVE_DECL_GETUSERSHELL
977HAVE_DECL_GETPAGESIZE
978HAVE_DECL_GETLOGIN_R
979HAVE_DECL_GETDOMAINNAME
2b1928b8 980HAVE_DECL_FDATASYNC
e275c824
PE
981HAVE_DECL_FCHDIR
982HAVE_DECL_ENVIRON
983HAVE_USLEEP
984HAVE_UNLINKAT
985HAVE_SYMLINKAT
986HAVE_SYMLINK
987HAVE_SLEEP
988HAVE_READLINKAT
989HAVE_READLINK
990HAVE_PWRITE
991HAVE_PREAD
992HAVE_PIPE2
993HAVE_PIPE
994HAVE_LINKAT
995HAVE_LINK
996HAVE_LCHOWN
da6c8463 997HAVE_GROUP_MEMBER
e275c824
PE
998HAVE_GETPAGESIZE
999HAVE_GETLOGIN
1000HAVE_GETHOSTNAME
1001HAVE_GETGROUPS
1002HAVE_GETDTABLESIZE
1003HAVE_FTRUNCATE
1004HAVE_FSYNC
2b1928b8 1005HAVE_FDATASYNC
e275c824
PE
1006HAVE_FCHOWNAT
1007HAVE_FCHDIR
1008HAVE_FACCESSAT
1009HAVE_EUIDACCESS
1010HAVE_DUP3
1011HAVE_DUP2
1012HAVE_CHOWN
1013GNULIB_WRITE
1014GNULIB_USLEEP
1015GNULIB_UNLINKAT
1016GNULIB_UNLINK
1017GNULIB_UNISTD_H_SIGPIPE
ca36e0ff 1018GNULIB_UNISTD_H_NONBLOCKING
e275c824
PE
1019GNULIB_UNISTD_H_GETOPT
1020GNULIB_TTYNAME_R
1021GNULIB_SYMLINKAT
1022GNULIB_SYMLINK
1023GNULIB_SLEEP
1024GNULIB_RMDIR
1025GNULIB_READLINKAT
1026GNULIB_READLINK
ca36e0ff 1027GNULIB_READ
e275c824
PE
1028GNULIB_PWRITE
1029GNULIB_PREAD
1030GNULIB_PIPE2
1031GNULIB_PIPE
1032GNULIB_LSEEK
1033GNULIB_LINKAT
1034GNULIB_LINK
1035GNULIB_LCHOWN
da6c8463 1036GNULIB_GROUP_MEMBER
e275c824
PE
1037GNULIB_GETUSERSHELL
1038GNULIB_GETPAGESIZE
1039GNULIB_GETLOGIN_R
1040GNULIB_GETLOGIN
1041GNULIB_GETHOSTNAME
1042GNULIB_GETGROUPS
1043GNULIB_GETDTABLESIZE
1044GNULIB_GETDOMAINNAME
1045GNULIB_GETCWD
1046GNULIB_FTRUNCATE
1047GNULIB_FSYNC
2b1928b8 1048GNULIB_FDATASYNC
e275c824
PE
1049GNULIB_FCHOWNAT
1050GNULIB_FCHDIR
1051GNULIB_FACCESSAT
1052GNULIB_EUIDACCESS
1053GNULIB_ENVIRON
1054GNULIB_DUP3
1055GNULIB_DUP2
2b1928b8 1056GNULIB_DUP
e275c824
PE
1057GNULIB_CLOSE
1058GNULIB_CHOWN
2b1928b8 1059GNULIB_CHDIR
4fc2b746
GM
1060GL_GENERATE_ALLOCA_H_FALSE
1061GL_GENERATE_ALLOCA_H_TRUE
1062ALLOCA_H
1063ALLOCA
743c80a7
PE
1064GL_COND_LIBTOOL_FALSE
1065GL_COND_LIBTOOL_TRUE
3e0be4ab
GM
1066POST_ALLOC_OBJ
1067PRE_ALLOC_OBJ
1068CYGWIN_OBJ
1069RALLOC_OBJ
1070OLDXMENU_DEPS
1071LIBX_OTHER
1072LIBXMENU
1073OLDXMENU
1074OLDXMENU_TARGET
1075LIBXT_OTHER
1076TOOLKIT_LIBW
1077WIDGET_OBJ
1078XOBJ
1079XMENU_OBJ
1080FONT_OBJ
1081OTHER_FILES
1082GNU_OBJC_CFLAGS
1083ns_appsrc
1084ns_appresdir
1085ns_appbindir
1086ns_appdir
1087S_FILE
1088M_FILE
1089X_TOOLKIT_TYPE
1090C_SWITCH_X_SYSTEM
1091C_SWITCH_X_SITE
1092LD_SWITCH_X_SITE
1093gameuser
1094gamedir
1095bitmapdir
1096archlibdir
1097etcdir
1098x_default_search_path
1099lisppath
1100locallisppath
1101lispdir
1102srcdir
1103canonical
1104configuration
1105version
1106KRB4LIB
1107DESLIB
1108KRB5LIB
1109CRYPTOLIB
1110COM_ERRLIB
1111LIBRESOLV
1112LIBHESIOD
1113TERMCAP_OBJ
1114LIBS_TERMCAP
067d23c9
KY
1115BLESSMAIL_TARGET
1116LIBS_MAIL
1117liblockfile
067d23c9
KY
1118LIBXML2_LIBS
1119LIBXML2_CFLAGS
1120LIBXSM
1121LIBGPM
1122LIBGIF
1123LIBTIFF
1124LIBPNG
1125LIBJPEG
1126LIBXPM
067d23c9
KY
1127M17N_FLT_LIBS
1128M17N_FLT_CFLAGS
1129LIBOTF_LIBS
1130LIBOTF_CFLAGS
7834125e
GM
1131FREETYPE_LIBS
1132FREETYPE_CFLAGS
067d23c9
KY
1133XFT_LIBS
1134XFT_CFLAGS
1135FONTCONFIG_LIBS
1136FONTCONFIG_CFLAGS
1137LIBXMU
1138LIBXTR6
1139LIBGNUTLS_LIBS
1140LIBGNUTLS_CFLAGS
1141LIBSELINUX_LIBS
f527bd02
GM
1142SETTINGS_LIBS
1143SETTINGS_CFLAGS
067d23c9
KY
1144GCONF_LIBS
1145GCONF_CFLAGS
f527bd02
GM
1146GSETTINGS_LIBS
1147GSETTINGS_CFLAGS
067d23c9
KY
1148DBUS_OBJ
1149DBUS_LIBS
1150DBUS_CFLAGS
1151GTK_OBJ
1152GTK_LIBS
1153GTK_CFLAGS
1154IMAGEMAGICK_LIBS
1155IMAGEMAGICK_CFLAGS
1156RSVG_LIBS
1157RSVG_CFLAGS
1abfdc54 1158LIB_PTHREAD
067d23c9
KY
1159VMLIMIT_OBJ
1160GMALLOC_OBJ
1161HAVE_XSERVER
1162LIB_STANDARD
00b3c7ac 1163NS_OBJC_OBJ
067d23c9
KY
1164NS_OBJ
1165TEMACS_LDFLAGS2
1166LD_SWITCH_X_SITE_AUX_RPATH
1167LD_SWITCH_X_SITE_AUX
1168XMKMF
1169DEPFLAGS
1170MKDEPDIR
067d23c9
KY
1171CFLAGS_SOUND
1172ALSA_LIBS
1173ALSA_CFLAGS
1174PKG_CONFIG
1175LIBSOUND
130f1dac 1176CRT_DIR
067d23c9
KY
1177START_FILES
1178LIB_MATH
067d23c9
KY
1179LIBS_SYSTEM
1180C_SWITCH_SYSTEM
1181UNEXEC_OBJ
1182C_SWITCH_MACHINE
1183LD_SWITCH_SYSTEM
1184CANNOT_DUMP
96f129d5 1185HAVE_MAKEINFO
067d23c9
KY
1186GZIP_PROG
1187INSTALL_INFO
067d23c9 1188C_WARNINGS_SWITCH
369e19fc
PE
1189RANLIB
1190ARFLAGS
1191AR
067d23c9
KY
1192EGREP
1193GREP
1194CPP
743c80a7
PE
1195am__fastdepCC_FALSE
1196am__fastdepCC_TRUE
1197CCDEPMODE
1198AMDEPBACKSLASH
1199AMDEP_FALSE
1200AMDEP_TRUE
1201am__quote
1202am__include
1203DEPDIR
067d23c9
KY
1204OBJEXT
1205EXEEXT
1206ac_ct_CC
1207CPPFLAGS
1208LDFLAGS
1209CFLAGS
1210CC
1211host_os
1212host_vendor
1213host_cpu
1214host
1215build_os
1216build_vendor
1217build_cpu
1218build
1219PROFILING_CFLAGS
1220MAINT
1221GZIP_INFO
c3a461a5 1222cache_file
743c80a7
PE
1223am__untar
1224am__tar
1225AMTAR
1226am__leading_dot
1227SET_MAKE
1228AWK
1229mkdir_p
1230MKDIR_P
1231INSTALL_STRIP_PROGRAM
1232STRIP
1233install_sh
1234MAKEINFO
1235AUTOHEADER
1236AUTOMAKE
1237AUTOCONF
1238ACLOCAL
1239VERSION
1240PACKAGE
1241CYGPATH_W
1242am__isrc
1243INSTALL_DATA
1244INSTALL_SCRIPT
1245INSTALL_PROGRAM
067d23c9
KY
1246target_alias
1247host_alias
1248build_alias
1249LIBS
1250ECHO_T
1251ECHO_N
1252ECHO_C
1253DEFS
1254mandir
1255localedir
1256libdir
1257psdir
1258pdfdir
1259dvidir
1260htmldir
1261infodir
1262docdir
1263oldincludedir
1264includedir
1265localstatedir
1266sharedstatedir
1267sysconfdir
1268datadir
1269datarootdir
1270libexecdir
1271sbindir
1272bindir
1273program_transform_name
1274prefix
1275exec_prefix
1276PACKAGE_URL
1277PACKAGE_BUGREPORT
1278PACKAGE_STRING
1279PACKAGE_VERSION
1280PACKAGE_TARNAME
1281PACKAGE_NAME
1282PATH_SEPARATOR
1283SHELL'
1284ac_subst_files='deps_frag
4d4b75e8 1285lisp_frag
067d23c9
KY
1286ns_frag'
1287ac_user_opts='
1288enable_option_checking
1289with_pop
1290with_kerberos
1291with_kerberos5
1292with_hesiod
1293with_mmdf
1294with_mail_unlink
1295with_mailhost
1296with_sound
1297with_sync_input
1298with_x_toolkit
0442dc7f 1299with_wide_int
067d23c9
KY
1300with_xpm
1301with_jpeg
1302with_tiff
1303with_gif
1304with_png
1305with_rsvg
1306with_xml2
1307with_imagemagick
1308with_xft
1309with_libotf
1310with_m17n_flt
1311with_toolkit_scroll_bars
1312with_xaw3d
1313with_xim
1314with_ns
1315with_gpm
1316with_dbus
1317with_gconf
f527bd02 1318with_gsettings
067d23c9
KY
1319with_selinux
1320with_gnutls
1321with_makeinfo
1322with_compress_info
1323with_pkg_config_prog
1324with_crt_dir
4fc5868a 1325with_gameuser
067d23c9
KY
1326with_gnustep_conf
1327enable_ns_self_contained
1328enable_asserts
1329enable_maintainer_mode
1330enable_locallisppath
1331enable_checking
1332enable_use_lisp_union_type
1333enable_profiling
1334enable_autodepend
743c80a7 1335enable_dependency_tracking
067d23c9
KY
1336enable_largefile
1337with_x
1338'
1339 ac_precious_vars='build_alias
1340host_alias
1341target_alias
1342CC
1343CFLAGS
1344LDFLAGS
1345LIBS
1346CPPFLAGS
1347CPP
1348XMKMF'
1349
1350
1351# Initialize some variables set by options.
1352ac_init_help=
1353ac_init_version=false
1354ac_unrecognized_opts=
1355ac_unrecognized_sep=
1356# The variables have the same names as the options, with
1357# dashes changed to underlines.
1358cache_file=/dev/null
1359exec_prefix=NONE
1360no_create=
1361no_recursion=
1362prefix=NONE
1363program_prefix=NONE
1364program_suffix=NONE
1365program_transform_name=s,x,x,
1366silent=
1367site=
1368srcdir=
1369verbose=
1370x_includes=NONE
1371x_libraries=NONE
1372
1373# Installation directory options.
1374# These are left unexpanded so users can "make install exec_prefix=/foo"
1375# and all the variables that are supposed to be based on exec_prefix
1376# by default will actually change.
1377# Use braces instead of parens because sh, perl, etc. also accept them.
1378# (The list follows the same order as the GNU Coding Standards.)
1379bindir='${exec_prefix}/bin'
1380sbindir='${exec_prefix}/sbin'
1381libexecdir='${exec_prefix}/libexec'
1382datarootdir='${prefix}/share'
1383datadir='${datarootdir}'
1384sysconfdir='${prefix}/etc'
1385sharedstatedir='${prefix}/com'
1386localstatedir='${prefix}/var'
1387includedir='${prefix}/include'
1388oldincludedir='/usr/include'
1389docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1390infodir='${datarootdir}/info'
1391htmldir='${docdir}'
1392dvidir='${docdir}'
1393pdfdir='${docdir}'
1394psdir='${docdir}'
1395libdir='${exec_prefix}/lib'
1396localedir='${datarootdir}/locale'
1397mandir='${datarootdir}/man'
1398
1399ac_prev=
1400ac_dashdash=
1401for ac_option
1402do
1403 # If the previous option needs an argument, assign it.
1404 if test -n "$ac_prev"; then
1405 eval $ac_prev=\$ac_option
1406 ac_prev=
1407 continue
1408 fi
1409
1410 case $ac_option in
a9bec17c
GM
1411 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1412 *) ac_optarg=yes ;;
067d23c9
KY
1413 esac
1414
1415 # Accept the important Cygnus configure options, so we can diagnose typos.
1416
1417 case $ac_dashdash$ac_option in
1418 --)
1419 ac_dashdash=yes ;;
1420
1421 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1422 ac_prev=bindir ;;
1423 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1424 bindir=$ac_optarg ;;
1425
1426 -build | --build | --buil | --bui | --bu)
1427 ac_prev=build_alias ;;
1428 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1429 build_alias=$ac_optarg ;;
1430
1431 -cache-file | --cache-file | --cache-fil | --cache-fi \
1432 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1433 ac_prev=cache_file ;;
1434 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1435 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1436 cache_file=$ac_optarg ;;
1437
1438 --config-cache | -C)
1439 cache_file=config.cache ;;
1440
1441 -datadir | --datadir | --datadi | --datad)
1442 ac_prev=datadir ;;
1443 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1444 datadir=$ac_optarg ;;
1445
1446 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1447 | --dataroo | --dataro | --datar)
1448 ac_prev=datarootdir ;;
1449 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1450 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1451 datarootdir=$ac_optarg ;;
1452
1453 -disable-* | --disable-*)
1454 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1455 # Reject names that are not valid shell variable names.
1456 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
a9bec17c 1457 as_fn_error "invalid feature name: $ac_useropt"
067d23c9
KY
1458 ac_useropt_orig=$ac_useropt
1459 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1460 case $ac_user_opts in
1461 *"
1462"enable_$ac_useropt"
1463"*) ;;
1464 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1465 ac_unrecognized_sep=', ';;
1466 esac
1467 eval enable_$ac_useropt=no ;;
1468
1469 -docdir | --docdir | --docdi | --doc | --do)
1470 ac_prev=docdir ;;
1471 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1472 docdir=$ac_optarg ;;
1473
1474 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1475 ac_prev=dvidir ;;
1476 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1477 dvidir=$ac_optarg ;;
1478
1479 -enable-* | --enable-*)
1480 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1481 # Reject names that are not valid shell variable names.
1482 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
a9bec17c 1483 as_fn_error "invalid feature name: $ac_useropt"
067d23c9
KY
1484 ac_useropt_orig=$ac_useropt
1485 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1486 case $ac_user_opts in
1487 *"
1488"enable_$ac_useropt"
1489"*) ;;
1490 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1491 ac_unrecognized_sep=', ';;
1492 esac
1493 eval enable_$ac_useropt=\$ac_optarg ;;
1494
1495 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1496 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1497 | --exec | --exe | --ex)
1498 ac_prev=exec_prefix ;;
1499 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1500 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1501 | --exec=* | --exe=* | --ex=*)
1502 exec_prefix=$ac_optarg ;;
1503
1504 -gas | --gas | --ga | --g)
1505 # Obsolete; use --with-gas.
1506 with_gas=yes ;;
1507
1508 -help | --help | --hel | --he | -h)
1509 ac_init_help=long ;;
1510 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1511 ac_init_help=recursive ;;
1512 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1513 ac_init_help=short ;;
1514
1515 -host | --host | --hos | --ho)
1516 ac_prev=host_alias ;;
1517 -host=* | --host=* | --hos=* | --ho=*)
1518 host_alias=$ac_optarg ;;
1519
1520 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1521 ac_prev=htmldir ;;
1522 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1523 | --ht=*)
1524 htmldir=$ac_optarg ;;
1525
1526 -includedir | --includedir | --includedi | --included | --include \
1527 | --includ | --inclu | --incl | --inc)
1528 ac_prev=includedir ;;
1529 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1530 | --includ=* | --inclu=* | --incl=* | --inc=*)
1531 includedir=$ac_optarg ;;
1532
1533 -infodir | --infodir | --infodi | --infod | --info | --inf)
1534 ac_prev=infodir ;;
1535 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1536 infodir=$ac_optarg ;;
1537
1538 -libdir | --libdir | --libdi | --libd)
1539 ac_prev=libdir ;;
1540 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1541 libdir=$ac_optarg ;;
1542
1543 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1544 | --libexe | --libex | --libe)
1545 ac_prev=libexecdir ;;
1546 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1547 | --libexe=* | --libex=* | --libe=*)
1548 libexecdir=$ac_optarg ;;
1549
1550 -localedir | --localedir | --localedi | --localed | --locale)
1551 ac_prev=localedir ;;
1552 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1553 localedir=$ac_optarg ;;
1554
1555 -localstatedir | --localstatedir | --localstatedi | --localstated \
1556 | --localstate | --localstat | --localsta | --localst | --locals)
1557 ac_prev=localstatedir ;;
1558 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1559 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1560 localstatedir=$ac_optarg ;;
1561
1562 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1563 ac_prev=mandir ;;
1564 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1565 mandir=$ac_optarg ;;
1566
1567 -nfp | --nfp | --nf)
1568 # Obsolete; use --without-fp.
1569 with_fp=no ;;
1570
1571 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1572 | --no-cr | --no-c | -n)
1573 no_create=yes ;;
1574
1575 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1576 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1577 no_recursion=yes ;;
1578
1579 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1580 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1581 | --oldin | --oldi | --old | --ol | --o)
1582 ac_prev=oldincludedir ;;
1583 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1584 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1585 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1586 oldincludedir=$ac_optarg ;;
1587
1588 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1589 ac_prev=prefix ;;
1590 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1591 prefix=$ac_optarg ;;
1592
1593 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1594 | --program-pre | --program-pr | --program-p)
1595 ac_prev=program_prefix ;;
1596 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1597 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1598 program_prefix=$ac_optarg ;;
1599
1600 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1601 | --program-suf | --program-su | --program-s)
1602 ac_prev=program_suffix ;;
1603 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1604 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1605 program_suffix=$ac_optarg ;;
1606
1607 -program-transform-name | --program-transform-name \
1608 | --program-transform-nam | --program-transform-na \
1609 | --program-transform-n | --program-transform- \
1610 | --program-transform | --program-transfor \
1611 | --program-transfo | --program-transf \
1612 | --program-trans | --program-tran \
1613 | --progr-tra | --program-tr | --program-t)
1614 ac_prev=program_transform_name ;;
1615 -program-transform-name=* | --program-transform-name=* \
1616 | --program-transform-nam=* | --program-transform-na=* \
1617 | --program-transform-n=* | --program-transform-=* \
1618 | --program-transform=* | --program-transfor=* \
1619 | --program-transfo=* | --program-transf=* \
1620 | --program-trans=* | --program-tran=* \
1621 | --progr-tra=* | --program-tr=* | --program-t=*)
1622 program_transform_name=$ac_optarg ;;
1623
1624 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1625 ac_prev=pdfdir ;;
1626 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1627 pdfdir=$ac_optarg ;;
1628
1629 -psdir | --psdir | --psdi | --psd | --ps)
1630 ac_prev=psdir ;;
1631 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1632 psdir=$ac_optarg ;;
1633
1634 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1635 | -silent | --silent | --silen | --sile | --sil)
1636 silent=yes ;;
1637
1638 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1639 ac_prev=sbindir ;;
1640 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1641 | --sbi=* | --sb=*)
1642 sbindir=$ac_optarg ;;
1643
1644 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1645 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1646 | --sharedst | --shareds | --shared | --share | --shar \
1647 | --sha | --sh)
1648 ac_prev=sharedstatedir ;;
1649 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1650 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1651 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1652 | --sha=* | --sh=*)
1653 sharedstatedir=$ac_optarg ;;
1654
1655 -site | --site | --sit)
1656 ac_prev=site ;;
1657 -site=* | --site=* | --sit=*)
1658 site=$ac_optarg ;;
1659
1660 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1661 ac_prev=srcdir ;;
1662 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1663 srcdir=$ac_optarg ;;
1664
1665 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1666 | --syscon | --sysco | --sysc | --sys | --sy)
1667 ac_prev=sysconfdir ;;
1668 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1669 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1670 sysconfdir=$ac_optarg ;;
1671
1672 -target | --target | --targe | --targ | --tar | --ta | --t)
1673 ac_prev=target_alias ;;
1674 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1675 target_alias=$ac_optarg ;;
1676
1677 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1678 verbose=yes ;;
1679
1680 -version | --version | --versio | --versi | --vers | -V)
1681 ac_init_version=: ;;
1682
1683 -with-* | --with-*)
1684 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1685 # Reject names that are not valid shell variable names.
1686 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
a9bec17c 1687 as_fn_error "invalid package name: $ac_useropt"
067d23c9
KY
1688 ac_useropt_orig=$ac_useropt
1689 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1690 case $ac_user_opts in
1691 *"
1692"with_$ac_useropt"
1693"*) ;;
1694 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1695 ac_unrecognized_sep=', ';;
1696 esac
1697 eval with_$ac_useropt=\$ac_optarg ;;
1698
1699 -without-* | --without-*)
1700 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1701 # Reject names that are not valid shell variable names.
1702 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
a9bec17c 1703 as_fn_error "invalid package name: $ac_useropt"
067d23c9
KY
1704 ac_useropt_orig=$ac_useropt
1705 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1706 case $ac_user_opts in
1707 *"
1708"with_$ac_useropt"
1709"*) ;;
1710 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1711 ac_unrecognized_sep=', ';;
1712 esac
1713 eval with_$ac_useropt=no ;;
1714
1715 --x)
1716 # Obsolete; use --with-x.
1717 with_x=yes ;;
1718
1719 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1720 | --x-incl | --x-inc | --x-in | --x-i)
1721 ac_prev=x_includes ;;
1722 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1723 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1724 x_includes=$ac_optarg ;;
1725
1726 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1727 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1728 ac_prev=x_libraries ;;
1729 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1730 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1731 x_libraries=$ac_optarg ;;
1732
a9bec17c
GM
1733 -*) as_fn_error "unrecognized option: \`$ac_option'
1734Try \`$0 --help' for more information."
067d23c9
KY
1735 ;;
1736
1737 *=*)
1738 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1739 # Reject names that are not valid shell variable names.
1740 case $ac_envvar in #(
1741 '' | [0-9]* | *[!_$as_cr_alnum]* )
a9bec17c 1742 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
067d23c9
KY
1743 esac
1744 eval $ac_envvar=\$ac_optarg
1745 export $ac_envvar ;;
1746
1747 *)
1748 # FIXME: should be removed in autoconf 3.0.
1749 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1750 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1751 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
a9bec17c 1752 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
067d23c9
KY
1753 ;;
1754
1755 esac
1756done
1757
1758if test -n "$ac_prev"; then
1759 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
a9bec17c 1760 as_fn_error "missing argument to $ac_option"
067d23c9
KY
1761fi
1762
1763if test -n "$ac_unrecognized_opts"; then
1764 case $enable_option_checking in
1765 no) ;;
a9bec17c 1766 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
067d23c9
KY
1767 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1768 esac
1769fi
1770
1771# Check all directory arguments for consistency.
1772for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1773 datadir sysconfdir sharedstatedir localstatedir includedir \
1774 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1775 libdir localedir mandir
1776do
1777 eval ac_val=\$$ac_var
1778 # Remove trailing slashes.
1779 case $ac_val in
1780 */ )
1781 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1782 eval $ac_var=\$ac_val;;
1783 esac
1784 # Be sure to have absolute directory names.
1785 case $ac_val in
1786 [\\/$]* | ?:[\\/]* ) continue;;
1787 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1788 esac
a9bec17c 1789 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
067d23c9
KY
1790done
1791
1792# There might be people who depend on the old broken behavior: `$host'
1793# used to hold the argument of --host etc.
1794# FIXME: To remove some day.
1795build=$build_alias
1796host=$host_alias
1797target=$target_alias
1798
1799# FIXME: To remove some day.
1800if test "x$host_alias" != x; then
1801 if test "x$build_alias" = x; then
1802 cross_compiling=maybe
a9bec17c
GM
1803 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1804 If a cross compiler is detected then cross compile mode will be used." >&2
067d23c9
KY
1805 elif test "x$build_alias" != "x$host_alias"; then
1806 cross_compiling=yes
1807 fi
1808fi
1809
1810ac_tool_prefix=
1811test -n "$host_alias" && ac_tool_prefix=$host_alias-
1812
1813test "$silent" = yes && exec 6>/dev/null
1814
1815
1816ac_pwd=`pwd` && test -n "$ac_pwd" &&
1817ac_ls_di=`ls -di .` &&
1818ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
a9bec17c 1819 as_fn_error "working directory cannot be determined"
067d23c9 1820test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
a9bec17c 1821 as_fn_error "pwd does not report name of working directory"
067d23c9
KY
1822
1823
1824# Find the source files, if location was not specified.
1825if test -z "$srcdir"; then
1826 ac_srcdir_defaulted=yes
1827 # Try the directory containing this script, then the parent directory.
1828 ac_confdir=`$as_dirname -- "$as_myself" ||
1829$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1830 X"$as_myself" : 'X\(//\)[^/]' \| \
1831 X"$as_myself" : 'X\(//\)$' \| \
1832 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1833$as_echo X"$as_myself" |
1834 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1835 s//\1/
1836 q
1837 }
1838 /^X\(\/\/\)[^/].*/{
1839 s//\1/
1840 q
1841 }
1842 /^X\(\/\/\)$/{
1843 s//\1/
1844 q
1845 }
1846 /^X\(\/\).*/{
1847 s//\1/
1848 q
1849 }
1850 s/.*/./; q'`
1851 srcdir=$ac_confdir
1852 if test ! -r "$srcdir/$ac_unique_file"; then
1853 srcdir=..
1854 fi
1855else
1856 ac_srcdir_defaulted=no
1857fi
1858if test ! -r "$srcdir/$ac_unique_file"; then
1859 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
a9bec17c 1860 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
067d23c9
KY
1861fi
1862ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1863ac_abs_confdir=`(
a9bec17c 1864 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
067d23c9
KY
1865 pwd)`
1866# When building in place, set srcdir=.
1867if test "$ac_abs_confdir" = "$ac_pwd"; then
1868 srcdir=.
1869fi
1870# Remove unnecessary trailing slashes from srcdir.
1871# Double slashes in file names in object file debugging info
1872# mess up M-x gdb in Emacs.
1873case $srcdir in
1874*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1875esac
1876for ac_var in $ac_precious_vars; do
1877 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1878 eval ac_env_${ac_var}_value=\$${ac_var}
1879 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1880 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1881done
1882
1883#
1884# Report the --help message.
1885#
1886if test "$ac_init_help" = "long"; then
1887 # Omit some internal or obsolete options to make the list less imposing.
1888 # This message is too long to be a string in the A/UX 3.1 sh.
1889 cat <<_ACEOF
d570ce1c 1890\`configure' configures emacs 24.0.93 to adapt to many kinds of systems.
067d23c9
KY
1891
1892Usage: $0 [OPTION]... [VAR=VALUE]...
1893
1894To assign environment variables (e.g., CC, CFLAGS...), specify them as
1895VAR=VALUE. See below for descriptions of some of the useful variables.
1896
1897Defaults for the options are specified in brackets.
1898
1899Configuration:
1900 -h, --help display this help and exit
1901 --help=short display options specific to this package
1902 --help=recursive display the short help of all the included packages
1903 -V, --version display version information and exit
a9bec17c 1904 -q, --quiet, --silent do not print \`checking...' messages
067d23c9
KY
1905 --cache-file=FILE cache test results in FILE [disabled]
1906 -C, --config-cache alias for \`--cache-file=config.cache'
1907 -n, --no-create do not create output files
1908 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1909
1910Installation directories:
1911 --prefix=PREFIX install architecture-independent files in PREFIX
1912 [$ac_default_prefix]
1913 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1914 [PREFIX]
1915
1916By default, \`make install' will install all the files in
1917\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1918an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1919for instance \`--prefix=\$HOME'.
1920
1921For better control, use the options below.
1922
1923Fine tuning of the installation directories:
1924 --bindir=DIR user executables [EPREFIX/bin]
1925 --sbindir=DIR system admin executables [EPREFIX/sbin]
1926 --libexecdir=DIR program executables [EPREFIX/libexec]
1927 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1928 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1929 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1930 --libdir=DIR object code libraries [EPREFIX/lib]
1931 --includedir=DIR C header files [PREFIX/include]
1932 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1933 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1934 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1935 --infodir=DIR info documentation [DATAROOTDIR/info]
1936 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1937 --mandir=DIR man documentation [DATAROOTDIR/man]
1938 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1939 --htmldir=DIR html documentation [DOCDIR]
1940 --dvidir=DIR dvi documentation [DOCDIR]
1941 --pdfdir=DIR pdf documentation [DOCDIR]
1942 --psdir=DIR ps documentation [DOCDIR]
1943_ACEOF
1944
1945 cat <<\_ACEOF
1946
1947Program names:
1948 --program-prefix=PREFIX prepend PREFIX to installed program names
1949 --program-suffix=SUFFIX append SUFFIX to installed program names
1950 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1951
1952X features:
1953 --x-includes=DIR X include files are in DIR
1954 --x-libraries=DIR X library files are in DIR
1955
1956System types:
1957 --build=BUILD configure for building on BUILD [guessed]
1958 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1959_ACEOF
1960fi
1961
1962if test -n "$ac_init_help"; then
1963 case $ac_init_help in
d570ce1c 1964 short | recursive ) echo "Configuration of emacs 24.0.93:";;
067d23c9
KY
1965 esac
1966 cat <<\_ACEOF
1967
1968Optional Features:
1969 --disable-option-checking ignore unrecognized --enable/--with options
1970 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1971 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1972 --disable-ns-self-contained
1973 disable self contained build under NeXTstep
1974 --enable-asserts compile code with asserts enabled
2b7f7d99
GM
1975 --disable-maintainer-mode
1976 disable make rules and dependencies not useful (and
067d23c9
KY
1977 sometimes confusing) to the casual installer
1978 --enable-locallisppath=PATH
1979 directories Emacs should search for lisp files
1980 specific to this site
1981 --enable-checking[=LIST]
1982 enable expensive run-time checks. With LIST, enable
1983 only specific categories of checks. Categories are:
1984 all,yes,no. Flags are: stringbytes, stringoverrun,
1985 stringfreelist, xmallocoverrun, conslist
1986 --enable-use-lisp-union-type
1987 use a union for the Lisp_Object data type. This is
1988 only useful for development for catching certain
1989 types of bugs.
1990 --enable-profiling build emacs with profiling support. This might not
1991 work on all platforms
1992 --enable-autodepend automatically generate dependencies to .h-files.
1993 Requires GNU Make and Gcc. Enabled if GNU Make and
1994 Gcc is found
743c80a7
PE
1995 --disable-dependency-tracking speeds up one-time build
1996 --enable-dependency-tracking do not reject slow dependency extractors
067d23c9
KY
1997 --disable-largefile omit support for large files
1998
1999Optional Packages:
2000 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2001 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2002 --without-pop don't support POP mail retrieval with movemail
2003 --with-kerberos support Kerberos-authenticated POP
2004 --with-kerberos5 support Kerberos version 5 authenticated POP
2005 --with-hesiod support Hesiod to get the POP server host
2006 --with-mmdf support MMDF mailboxes
2007 --with-mail-unlink unlink, rather than empty, mail spool after reading
2008 --with-mailhost=HOSTNAME
2009 string giving default POP mail host
2010 --without-sound don't compile with sound support
2011 --without-sync-input process async input synchronously
2012 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
2013 lucid or athena, motif, no)
0442dc7f 2014 --with-wide-int prefer wide Emacs integers (typically 62-bit)
067d23c9
KY
2015 --without-xpm don't compile with XPM image support
2016 --without-jpeg don't compile with JPEG image support
2017 --without-tiff don't compile with TIFF image support
2018 --without-gif don't compile with GIF image support
2019 --without-png don't compile with PNG image support
2020 --without-rsvg don't compile with SVG image support
2021 --without-xml2 don't compile with XML parsing support
2022 --without-imagemagick don't compile with ImageMagick image support
2023 --without-xft don't use XFT for anti aliased fonts
2024 --without-libotf don't use libotf for OpenType font support
2025 --without-m17n-flt don't use m17n-flt for text shaping
2026 --without-toolkit-scroll-bars
2027 don't use Motif or Xaw3d scroll bars
2028 --without-xaw3d don't use Xaw3d
2029 --without-xim don't use X11 XIM
7834125e 2030 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
067d23c9
KY
2031 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2032 console
2033 --without-dbus don't compile with D-Bus support
2034 --without-gconf don't compile with GConf support
f527bd02 2035 --without-gsettings don't compile with GSettings support
067d23c9
KY
2036 --without-selinux don't compile with SELinux support
2037 --without-gnutls don't use -lgnutls for SSL/TLS support
2038 --without-makeinfo don't require makeinfo for building manuals
2039 --without-compress-info don't compress the installed Info pages
2040 --with-pkg-config-prog=PATH
2041 path to pkg-config for finding GTK and librsvg
2042 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2043 /usr/lib, or /usr/lib64 on some platforms.
4fc5868a 2044 --with-gameuser=USER user for shared game score files
067d23c9
KY
2045 --with-gnustep-conf=PATH
2046 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2047 or /etc/GNUstep/GNUstep.conf
2048 --with-x use the X Window System
2049
2050Some influential environment variables:
2051 CC C compiler command
2052 CFLAGS C compiler flags
2053 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2054 nonstandard directory <lib dir>
2055 LIBS libraries to pass to the linker, e.g. -l<library>
2056 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2057 you have headers in a nonstandard directory <include dir>
2058 CPP C preprocessor
2059 XMKMF Path to xmkmf, Makefile generator for X Window System
2060
2061Use these variables to override the choices made by `configure' or to help
2062it to find libraries and programs with nonstandard names/locations.
2063
2064Report bugs to the package provider.
2065_ACEOF
2066ac_status=$?
2067fi
2068
2069if test "$ac_init_help" = "recursive"; then
2070 # If there are subdirs, report their specific --help.
2071 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2072 test -d "$ac_dir" ||
2073 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2074 continue
2075 ac_builddir=.
2076
2077case "$ac_dir" in
2078.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2079*)
2080 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2081 # A ".." for each directory in $ac_dir_suffix.
2082 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2083 case $ac_top_builddir_sub in
2084 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2085 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2086 esac ;;
2087esac
2088ac_abs_top_builddir=$ac_pwd
2089ac_abs_builddir=$ac_pwd$ac_dir_suffix
2090# for backward compatibility:
2091ac_top_builddir=$ac_top_build_prefix
2092
2093case $srcdir in
2094 .) # We are building in place.
2095 ac_srcdir=.
2096 ac_top_srcdir=$ac_top_builddir_sub
2097 ac_abs_top_srcdir=$ac_pwd ;;
2098 [\\/]* | ?:[\\/]* ) # Absolute name.
2099 ac_srcdir=$srcdir$ac_dir_suffix;
2100 ac_top_srcdir=$srcdir
2101 ac_abs_top_srcdir=$srcdir ;;
2102 *) # Relative name.
2103 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2104 ac_top_srcdir=$ac_top_build_prefix$srcdir
2105 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2106esac
2107ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2108
2109 cd "$ac_dir" || { ac_status=$?; continue; }
2110 # Check for guested configure.
2111 if test -f "$ac_srcdir/configure.gnu"; then
2112 echo &&
2113 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2114 elif test -f "$ac_srcdir/configure"; then
2115 echo &&
2116 $SHELL "$ac_srcdir/configure" --help=recursive
2117 else
2118 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2119 fi || ac_status=$?
2120 cd "$ac_pwd" || { ac_status=$?; break; }
2121 done
2122fi
2123
2124test -n "$ac_init_help" && exit $ac_status
2125if $ac_init_version; then
2126 cat <<\_ACEOF
d570ce1c 2127emacs configure 24.0.93
a9bec17c 2128generated by GNU Autoconf 2.65
067d23c9 2129
a9bec17c 2130Copyright (C) 2009 Free Software Foundation, Inc.
067d23c9
KY
2131This configure script is free software; the Free Software Foundation
2132gives unlimited permission to copy, distribute and modify it.
2133_ACEOF
2134 exit
2135fi
2136
2137## ------------------------ ##
2138## Autoconf initialization. ##
2139## ------------------------ ##
2140
2141# ac_fn_c_try_compile LINENO
2142# --------------------------
2143# Try to compile conftest.$ac_ext, and return whether this succeeded.
2144ac_fn_c_try_compile ()
2145{
2146 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2147 rm -f conftest.$ac_objext
2148 if { { ac_try="$ac_compile"
2149case "(($ac_try" in
2150 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2151 *) ac_try_echo=$ac_try;;
2152esac
2153eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2154$as_echo "$ac_try_echo"; } >&5
2155 (eval "$ac_compile") 2>conftest.err
2156 ac_status=$?
2157 if test -s conftest.err; then
2158 grep -v '^ *+' conftest.err >conftest.er1
2159 cat conftest.er1 >&5
2160 mv -f conftest.er1 conftest.err
2161 fi
2162 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2163 test $ac_status = 0; } && {
2164 test -z "$ac_c_werror_flag" ||
2165 test ! -s conftest.err
2166 } && test -s conftest.$ac_objext; then :
2167 ac_retval=0
2168else
2169 $as_echo "$as_me: failed program was:" >&5
2170sed 's/^/| /' conftest.$ac_ext >&5
2171
2172 ac_retval=1
2173fi
a9bec17c 2174 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2175 as_fn_set_status $ac_retval
2176
2177} # ac_fn_c_try_compile
2178
067d23c9
KY
2179# ac_fn_c_try_cpp LINENO
2180# ----------------------
2181# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2182ac_fn_c_try_cpp ()
2183{
2184 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2185 if { { ac_try="$ac_cpp conftest.$ac_ext"
2186case "(($ac_try" in
2187 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2188 *) ac_try_echo=$ac_try;;
2189esac
2190eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2191$as_echo "$ac_try_echo"; } >&5
2192 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2193 ac_status=$?
2194 if test -s conftest.err; then
2195 grep -v '^ *+' conftest.err >conftest.er1
2196 cat conftest.er1 >&5
2197 mv -f conftest.er1 conftest.err
2198 fi
2199 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
a9bec17c 2200 test $ac_status = 0; } >/dev/null && {
067d23c9
KY
2201 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2202 test ! -s conftest.err
2203 }; then :
2204 ac_retval=0
2205else
2206 $as_echo "$as_me: failed program was:" >&5
2207sed 's/^/| /' conftest.$ac_ext >&5
2208
2209 ac_retval=1
2210fi
a9bec17c 2211 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2212 as_fn_set_status $ac_retval
2213
2214} # ac_fn_c_try_cpp
2215
2216# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2217# -------------------------------------------------------
2218# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2219# the include files in INCLUDES and setting the cache variable VAR
2220# accordingly.
2221ac_fn_c_check_header_mongrel ()
2222{
2223 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
a9bec17c 2224 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2226$as_echo_n "checking for $2... " >&6; }
a9bec17c 2227if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2228 $as_echo_n "(cached) " >&6
2229fi
2230eval ac_res=\$$3
2231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2232$as_echo "$ac_res" >&6; }
2233else
2234 # Is the header compilable?
2235{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2236$as_echo_n "checking $2 usability... " >&6; }
2237cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2238/* end confdefs.h. */
2239$4
2240#include <$2>
2241_ACEOF
2242if ac_fn_c_try_compile "$LINENO"; then :
2243 ac_header_compiler=yes
2244else
2245 ac_header_compiler=no
2246fi
2247rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2248{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2249$as_echo "$ac_header_compiler" >&6; }
2250
2251# Is the header present?
2252{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2253$as_echo_n "checking $2 presence... " >&6; }
2254cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2255/* end confdefs.h. */
2256#include <$2>
2257_ACEOF
2258if ac_fn_c_try_cpp "$LINENO"; then :
2259 ac_header_preproc=yes
2260else
2261 ac_header_preproc=no
2262fi
a9bec17c 2263rm -f conftest.err conftest.$ac_ext
067d23c9
KY
2264{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2265$as_echo "$ac_header_preproc" >&6; }
2266
2267# So? What about this header?
2268case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2269 yes:no: )
2270 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2271$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2272 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2273$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2274 ;;
2275 no:yes:* )
2276 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2277$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2278 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2279$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2280 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2281$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2282 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2283$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2284 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2285$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2286 ;;
2287esac
2288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2289$as_echo_n "checking for $2... " >&6; }
a9bec17c 2290if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2291 $as_echo_n "(cached) " >&6
2292else
2293 eval "$3=\$ac_header_compiler"
2294fi
2295eval ac_res=\$$3
2296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2297$as_echo "$ac_res" >&6; }
2298fi
a9bec17c 2299 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2300
2301} # ac_fn_c_check_header_mongrel
2302
2303# ac_fn_c_try_run LINENO
2304# ----------------------
2305# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2306# that executables *can* be run.
2307ac_fn_c_try_run ()
2308{
2309 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2310 if { { ac_try="$ac_link"
2311case "(($ac_try" in
2312 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2313 *) ac_try_echo=$ac_try;;
2314esac
2315eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2316$as_echo "$ac_try_echo"; } >&5
2317 (eval "$ac_link") 2>&5
2318 ac_status=$?
2319 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2320 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2321 { { case "(($ac_try" in
2322 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2323 *) ac_try_echo=$ac_try;;
2324esac
2325eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2326$as_echo "$ac_try_echo"; } >&5
2327 (eval "$ac_try") 2>&5
2328 ac_status=$?
2329 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2330 test $ac_status = 0; }; }; then :
2331 ac_retval=0
2332else
2333 $as_echo "$as_me: program exited with status $ac_status" >&5
2334 $as_echo "$as_me: failed program was:" >&5
2335sed 's/^/| /' conftest.$ac_ext >&5
2336
2337 ac_retval=$ac_status
2338fi
2339 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
a9bec17c 2340 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2341 as_fn_set_status $ac_retval
2342
2343} # ac_fn_c_try_run
2344
2345# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2346# -------------------------------------------------------
2347# Tests whether HEADER exists and can be compiled using the include files in
2348# INCLUDES, setting the cache variable VAR accordingly.
2349ac_fn_c_check_header_compile ()
2350{
2351 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2353$as_echo_n "checking for $2... " >&6; }
a9bec17c 2354if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2355 $as_echo_n "(cached) " >&6
2356else
2357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2358/* end confdefs.h. */
2359$4
2360#include <$2>
2361_ACEOF
2362if ac_fn_c_try_compile "$LINENO"; then :
2363 eval "$3=yes"
2364else
2365 eval "$3=no"
2366fi
2367rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2368fi
2369eval ac_res=\$$3
2370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2371$as_echo "$ac_res" >&6; }
a9bec17c 2372 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2373
2374} # ac_fn_c_check_header_compile
2375
1fd182f0
PE
2376# ac_fn_c_try_link LINENO
2377# -----------------------
2378# Try to link conftest.$ac_ext, and return whether this succeeded.
2379ac_fn_c_try_link ()
2380{
2381 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2382 rm -f conftest.$ac_objext conftest$ac_exeext
2383 if { { ac_try="$ac_link"
2384case "(($ac_try" in
2385 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2386 *) ac_try_echo=$ac_try;;
2387esac
2388eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2389$as_echo "$ac_try_echo"; } >&5
2390 (eval "$ac_link") 2>conftest.err
2391 ac_status=$?
2392 if test -s conftest.err; then
2393 grep -v '^ *+' conftest.err >conftest.er1
2394 cat conftest.er1 >&5
2395 mv -f conftest.er1 conftest.err
2396 fi
2397 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2398 test $ac_status = 0; } && {
2399 test -z "$ac_c_werror_flag" ||
2400 test ! -s conftest.err
2401 } && test -s conftest$ac_exeext && {
2402 test "$cross_compiling" = yes ||
2403 $as_test_x conftest$ac_exeext
2404 }; then :
2405 ac_retval=0
2406else
2407 $as_echo "$as_me: failed program was:" >&5
2408sed 's/^/| /' conftest.$ac_ext >&5
2409
2410 ac_retval=1
2411fi
2412 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2413 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2414 # interfere with the next link command; also delete a directory that is
2415 # left behind by Apple's compiler. We do this before executing the actions.
2416 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
a9bec17c 2417 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1fd182f0
PE
2418 as_fn_set_status $ac_retval
2419
2420} # ac_fn_c_try_link
2421
a9bec17c
GM
2422# ac_fn_c_check_decl LINENO SYMBOL VAR
2423# ------------------------------------
2424# Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
067d23c9
KY
2425ac_fn_c_check_decl ()
2426{
2427 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
a9bec17c
GM
2428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2429$as_echo_n "checking whether $2 is declared... " >&6; }
2430if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2431 $as_echo_n "(cached) " >&6
2432else
2433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2434/* end confdefs.h. */
2435$4
2436int
2437main ()
2438{
a9bec17c
GM
2439#ifndef $2
2440 (void) $2;
067d23c9
KY
2441#endif
2442
2443 ;
2444 return 0;
2445}
2446_ACEOF
2447if ac_fn_c_try_compile "$LINENO"; then :
2448 eval "$3=yes"
2449else
2450 eval "$3=no"
2451fi
2452rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2453fi
2454eval ac_res=\$$3
2455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2456$as_echo "$ac_res" >&6; }
a9bec17c 2457 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2458
2459} # ac_fn_c_check_decl
2460
2461# ac_fn_c_check_header_preproc LINENO HEADER VAR
2462# ----------------------------------------------
2463# Tests whether HEADER is present, setting the cache variable VAR accordingly.
2464ac_fn_c_check_header_preproc ()
2465{
2466 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2468$as_echo_n "checking for $2... " >&6; }
a9bec17c 2469if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2470 $as_echo_n "(cached) " >&6
2471else
2472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2473/* end confdefs.h. */
2474#include <$2>
2475_ACEOF
2476if ac_fn_c_try_cpp "$LINENO"; then :
2477 eval "$3=yes"
2478else
2479 eval "$3=no"
2480fi
a9bec17c 2481rm -f conftest.err conftest.$ac_ext
067d23c9
KY
2482fi
2483eval ac_res=\$$3
2484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2485$as_echo "$ac_res" >&6; }
a9bec17c 2486 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2487
2488} # ac_fn_c_check_header_preproc
2489
067d23c9
KY
2490# ac_fn_c_check_func LINENO FUNC VAR
2491# ----------------------------------
2492# Tests whether FUNC exists, setting the cache variable VAR accordingly
2493ac_fn_c_check_func ()
2494{
2495 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2497$as_echo_n "checking for $2... " >&6; }
a9bec17c 2498if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
2499 $as_echo_n "(cached) " >&6
2500else
2501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2502/* end confdefs.h. */
2503/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2504 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2505#define $2 innocuous_$2
2506
2507/* System header to define __stub macros and hopefully few prototypes,
2508 which can conflict with char $2 (); below.
2509 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2510 <limits.h> exists even on freestanding compilers. */
2511
2512#ifdef __STDC__
2513# include <limits.h>
2514#else
2515# include <assert.h>
2516#endif
2517
2518#undef $2
2519
2520/* Override any GCC internal prototype to avoid an error.
2521 Use char because int might match the return type of a GCC
2522 builtin and then its argument prototype would still apply. */
2523#ifdef __cplusplus
2524extern "C"
2525#endif
2526char $2 ();
2527/* The GNU C library defines this for functions which it implements
2528 to always fail with ENOSYS. Some functions are actually named
2529 something starting with __ and the normal name is an alias. */
2530#if defined __stub_$2 || defined __stub___$2
2531choke me
2532#endif
2533
2534int
2535main ()
2536{
2537return $2 ();
2538 ;
2539 return 0;
2540}
2541_ACEOF
2542if ac_fn_c_try_link "$LINENO"; then :
2543 eval "$3=yes"
2544else
2545 eval "$3=no"
2546fi
2547rm -f core conftest.err conftest.$ac_objext \
2548 conftest$ac_exeext conftest.$ac_ext
2549fi
2550eval ac_res=\$$3
2551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2552$as_echo "$ac_res" >&6; }
a9bec17c 2553 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
067d23c9
KY
2554
2555} # ac_fn_c_check_func
2556
7417b37c
GM
2557# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2558# ----------------------------------------------------
2559# Tries to find if the field MEMBER exists in type AGGR, after including
2560# INCLUDES, setting cache variable VAR accordingly.
2561ac_fn_c_check_member ()
2562{
2563 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2565$as_echo_n "checking for $2.$3... " >&6; }
a9bec17c 2566if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
7417b37c
GM
2567 $as_echo_n "(cached) " >&6
2568else
2569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2570/* end confdefs.h. */
2571$5
2572int
2573main ()
2574{
2575static $2 ac_aggr;
2576if (ac_aggr.$3)
2577return 0;
2578 ;
2579 return 0;
2580}
2581_ACEOF
2582if ac_fn_c_try_compile "$LINENO"; then :
2583 eval "$4=yes"
2584else
2585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2586/* end confdefs.h. */
2587$5
2588int
2589main ()
2590{
2591static $2 ac_aggr;
2592if (sizeof ac_aggr.$3)
2593return 0;
2594 ;
2595 return 0;
2596}
2597_ACEOF
2598if ac_fn_c_try_compile "$LINENO"; then :
2599 eval "$4=yes"
2600else
2601 eval "$4=no"
2602fi
2603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2604fi
2605rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2606fi
2607eval ac_res=\$$4
2608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2609$as_echo "$ac_res" >&6; }
a9bec17c 2610 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
7417b37c
GM
2611
2612} # ac_fn_c_check_member
2613
3e0be4ab
GM
2614# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2615# -------------------------------------------
2616# Tests whether TYPE exists after having included INCLUDES, setting cache
2617# variable VAR accordingly.
2618ac_fn_c_check_type ()
2619{
2620 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2622$as_echo_n "checking for $2... " >&6; }
a9bec17c 2623if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
3e0be4ab
GM
2624 $as_echo_n "(cached) " >&6
2625else
2626 eval "$3=no"
2627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2628/* end confdefs.h. */
2629$4
2630int
2631main ()
2632{
2633if (sizeof ($2))
2634 return 0;
2635 ;
2636 return 0;
2637}
2638_ACEOF
2639if ac_fn_c_try_compile "$LINENO"; then :
2640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2641/* end confdefs.h. */
2642$4
2643int
2644main ()
2645{
2646if (sizeof (($2)))
2647 return 0;
2648 ;
2649 return 0;
2650}
2651_ACEOF
2652if ac_fn_c_try_compile "$LINENO"; then :
2653
2654else
2655 eval "$3=yes"
2656fi
2657rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2658fi
2659rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2660fi
2661eval ac_res=\$$3
2662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2663$as_echo "$ac_res" >&6; }
a9bec17c 2664 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3e0be4ab
GM
2665
2666} # ac_fn_c_check_type
2667
5f90be1b
PE
2668# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2669# --------------------------------------------
2670# Tries to find the compile-time value of EXPR in a program that includes
2671# INCLUDES, setting VAR accordingly. Returns whether the value could be
2672# computed
2673ac_fn_c_compute_int ()
2674{
2675 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2676 if test "$cross_compiling" = yes; then
2677 # Depending upon the size, compute the lo and hi bounds.
2678cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2679/* end confdefs.h. */
2680$4
2681int
2682main ()
2683{
2684static int test_array [1 - 2 * !(($2) >= 0)];
2685test_array [0] = 0
2686
2687 ;
2688 return 0;
2689}
2690_ACEOF
2691if ac_fn_c_try_compile "$LINENO"; then :
2692 ac_lo=0 ac_mid=0
2693 while :; do
2694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2695/* end confdefs.h. */
2696$4
2697int
2698main ()
2699{
2700static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2701test_array [0] = 0
2702
2703 ;
2704 return 0;
2705}
2706_ACEOF
2707if ac_fn_c_try_compile "$LINENO"; then :
2708 ac_hi=$ac_mid; break
2709else
2710 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2711 if test $ac_lo -le $ac_mid; then
2712 ac_lo= ac_hi=
2713 break
2714 fi
2715 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2716fi
2717rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2718 done
2719else
2720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2721/* end confdefs.h. */
2722$4
2723int
2724main ()
2725{
2726static int test_array [1 - 2 * !(($2) < 0)];
2727test_array [0] = 0
2728
2729 ;
2730 return 0;
2731}
2732_ACEOF
2733if ac_fn_c_try_compile "$LINENO"; then :
2734 ac_hi=-1 ac_mid=-1
2735 while :; do
2736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2737/* end confdefs.h. */
2738$4
2739int
2740main ()
2741{
2742static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2743test_array [0] = 0
2744
2745 ;
2746 return 0;
2747}
2748_ACEOF
2749if ac_fn_c_try_compile "$LINENO"; then :
2750 ac_lo=$ac_mid; break
2751else
2752 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2753 if test $ac_mid -le $ac_hi; then
2754 ac_lo= ac_hi=
2755 break
2756 fi
2757 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2758fi
2759rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2760 done
2761else
2762 ac_lo= ac_hi=
2763fi
2764rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2765fi
2766rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2767# Binary search between lo and hi bounds.
2768while test "x$ac_lo" != "x$ac_hi"; do
2769 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2771/* end confdefs.h. */
2772$4
2773int
2774main ()
2775{
2776static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2777test_array [0] = 0
2778
2779 ;
2780 return 0;
2781}
2782_ACEOF
2783if ac_fn_c_try_compile "$LINENO"; then :
2784 ac_hi=$ac_mid
2785else
2786 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2787fi
2788rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2789done
2790case $ac_lo in #((
2791?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2792'') ac_retval=1 ;;
2793esac
2794 else
2795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2796/* end confdefs.h. */
2797$4
2798static long int longval () { return $2; }
2799static unsigned long int ulongval () { return $2; }
2800#include <stdio.h>
2801#include <stdlib.h>
2802int
2803main ()
2804{
2805
2806 FILE *f = fopen ("conftest.val", "w");
2807 if (! f)
2808 return 1;
2809 if (($2) < 0)
2810 {
2811 long int i = longval ();
2812 if (i != ($2))
2813 return 1;
2814 fprintf (f, "%ld", i);
2815 }
2816 else
2817 {
2818 unsigned long int i = ulongval ();
2819 if (i != ($2))
2820 return 1;
2821 fprintf (f, "%lu", i);
2822 }
2823 /* Do not output a trailing newline, as this causes \r\n confusion
2824 on some platforms. */
2825 return ferror (f) || fclose (f) != 0;
2826
2827 ;
2828 return 0;
2829}
2830_ACEOF
2831if ac_fn_c_try_run "$LINENO"; then :
2832 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2833else
2834 ac_retval=1
2835fi
2836rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2837 conftest.$ac_objext conftest.beam conftest.$ac_ext
2838rm -f conftest.val
2839
2840 fi
a9bec17c 2841 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
5f90be1b
PE
2842 as_fn_set_status $ac_retval
2843
2844} # ac_fn_c_compute_int
067d23c9
KY
2845cat >config.log <<_ACEOF
2846This file contains any messages produced by compilers while
2847running configure, to aid debugging if configure makes a mistake.
2848
d570ce1c 2849It was created by emacs $as_me 24.0.93, which was
a9bec17c 2850generated by GNU Autoconf 2.65. Invocation command line was
067d23c9
KY
2851
2852 $ $0 $@
2853
2854_ACEOF
2855exec 5>>config.log
2856{
2857cat <<_ASUNAME
2858## --------- ##
2859## Platform. ##
2860## --------- ##
2861
2862hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2863uname -m = `(uname -m) 2>/dev/null || echo unknown`
2864uname -r = `(uname -r) 2>/dev/null || echo unknown`
2865uname -s = `(uname -s) 2>/dev/null || echo unknown`
2866uname -v = `(uname -v) 2>/dev/null || echo unknown`
2867
2868/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2869/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2870
2871/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2872/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2873/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2874/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2875/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2876/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2877/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2878
2879_ASUNAME
2880
2881as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2882for as_dir in $PATH
2883do
2884 IFS=$as_save_IFS
2885 test -z "$as_dir" && as_dir=.
2886 $as_echo "PATH: $as_dir"
2887 done
2888IFS=$as_save_IFS
2889
2890} >&5
2891
2892cat >&5 <<_ACEOF
2893
2894
2895## ----------- ##
2896## Core tests. ##
2897## ----------- ##
2898
2899_ACEOF
2900
2901
2902# Keep a trace of the command line.
2903# Strip out --no-create and --no-recursion so they do not pile up.
2904# Strip out --silent because we don't want to record it for future runs.
2905# Also quote any args containing shell meta-characters.
2906# Make two passes to allow for proper duplicate-argument suppression.
2907ac_configure_args=
2908ac_configure_args0=
2909ac_configure_args1=
2910ac_must_keep_next=false
2911for ac_pass in 1 2
2912do
2913 for ac_arg
2914 do
2915 case $ac_arg in
2916 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2917 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2918 | -silent | --silent | --silen | --sile | --sil)
2919 continue ;;
2920 *\'*)
2921 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2922 esac
2923 case $ac_pass in
2924 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2925 2)
2926 as_fn_append ac_configure_args1 " '$ac_arg'"
2927 if test $ac_must_keep_next = true; then
2928 ac_must_keep_next=false # Got value, back to normal.
2929 else
2930 case $ac_arg in
2931 *=* | --config-cache | -C | -disable-* | --disable-* \
2932 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2933 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2934 | -with-* | --with-* | -without-* | --without-* | --x)
2935 case "$ac_configure_args0 " in
2936 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2937 esac
2938 ;;
2939 -* ) ac_must_keep_next=true ;;
2940 esac
2941 fi
2942 as_fn_append ac_configure_args " '$ac_arg'"
2943 ;;
2944 esac
2945 done
2946done
2947{ ac_configure_args0=; unset ac_configure_args0;}
2948{ ac_configure_args1=; unset ac_configure_args1;}
2949
2950# When interrupted or exit'd, cleanup temporary files, and complete
2951# config.log. We remove comments because anyway the quotes in there
2952# would cause problems or look ugly.
2953# WARNING: Use '\'' to represent an apostrophe within the trap.
2954# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2955trap 'exit_status=$?
2956 # Save into config.log some information that might help in debugging.
2957 {
2958 echo
2959
a9bec17c
GM
2960 cat <<\_ASBOX
2961## ---------------- ##
067d23c9 2962## Cache variables. ##
a9bec17c
GM
2963## ---------------- ##
2964_ASBOX
067d23c9
KY
2965 echo
2966 # The following way of writing the cache mishandles newlines in values,
2967(
2968 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2969 eval ac_val=\$$ac_var
2970 case $ac_val in #(
2971 *${as_nl}*)
2972 case $ac_var in #(
2973 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2974$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2975 esac
2976 case $ac_var in #(
2977 _ | IFS | as_nl) ;; #(
2978 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2979 *) { eval $ac_var=; unset $ac_var;} ;;
2980 esac ;;
2981 esac
2982 done
2983 (set) 2>&1 |
2984 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2985 *${as_nl}ac_space=\ *)
2986 sed -n \
2987 "s/'\''/'\''\\\\'\'''\''/g;
2988 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2989 ;; #(
2990 *)
2991 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2992 ;;
2993 esac |
2994 sort
2995)
2996 echo
2997
a9bec17c
GM
2998 cat <<\_ASBOX
2999## ----------------- ##
067d23c9 3000## Output variables. ##
a9bec17c
GM
3001## ----------------- ##
3002_ASBOX
067d23c9
KY
3003 echo
3004 for ac_var in $ac_subst_vars
3005 do
3006 eval ac_val=\$$ac_var
3007 case $ac_val in
3008 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3009 esac
3010 $as_echo "$ac_var='\''$ac_val'\''"
3011 done | sort
3012 echo
3013
3014 if test -n "$ac_subst_files"; then
a9bec17c
GM
3015 cat <<\_ASBOX
3016## ------------------- ##
067d23c9 3017## File substitutions. ##
a9bec17c
GM
3018## ------------------- ##
3019_ASBOX
067d23c9
KY
3020 echo
3021 for ac_var in $ac_subst_files
3022 do
3023 eval ac_val=\$$ac_var
3024 case $ac_val in
3025 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3026 esac
3027 $as_echo "$ac_var='\''$ac_val'\''"
3028 done | sort
3029 echo
3030 fi
3031
3032 if test -s confdefs.h; then
a9bec17c
GM
3033 cat <<\_ASBOX
3034## ----------- ##
067d23c9 3035## confdefs.h. ##
a9bec17c
GM
3036## ----------- ##
3037_ASBOX
067d23c9
KY
3038 echo
3039 cat confdefs.h
3040 echo
3041 fi
3042 test "$ac_signal" != 0 &&
3043 $as_echo "$as_me: caught signal $ac_signal"
3044 $as_echo "$as_me: exit $exit_status"
3045 } >&5
3046 rm -f core *.core core.conftest.* &&
3047 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3048 exit $exit_status
3049' 0
3050for ac_signal in 1 2 13 15; do
3051 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3052done
3053ac_signal=0
3054
3055# confdefs.h avoids OS command line length limits that DEFS can exceed.
3056rm -f -r conftest* confdefs.h
3057
3058$as_echo "/* confdefs.h */" > confdefs.h
3059
3060# Predefined preprocessor variables.
3061
3062cat >>confdefs.h <<_ACEOF
3063#define PACKAGE_NAME "$PACKAGE_NAME"
3064_ACEOF
3065
3066cat >>confdefs.h <<_ACEOF
3067#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3068_ACEOF
3069
3070cat >>confdefs.h <<_ACEOF
3071#define PACKAGE_VERSION "$PACKAGE_VERSION"
3072_ACEOF
3073
3074cat >>confdefs.h <<_ACEOF
3075#define PACKAGE_STRING "$PACKAGE_STRING"
3076_ACEOF
3077
3078cat >>confdefs.h <<_ACEOF
3079#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3080_ACEOF
3081
3082cat >>confdefs.h <<_ACEOF
3083#define PACKAGE_URL "$PACKAGE_URL"
3084_ACEOF
3085
3086
3087# Let the site file select an alternate cache file if it wants to.
3088# Prefer an explicitly selected file to automatically selected ones.
3089ac_site_file1=NONE
3090ac_site_file2=NONE
3091if test -n "$CONFIG_SITE"; then
a9bec17c 3092 ac_site_file1=$CONFIG_SITE
067d23c9
KY
3093elif test "x$prefix" != xNONE; then
3094 ac_site_file1=$prefix/share/config.site
3095 ac_site_file2=$prefix/etc/config.site
3096else
3097 ac_site_file1=$ac_default_prefix/share/config.site
3098 ac_site_file2=$ac_default_prefix/etc/config.site
3099fi
3100for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3101do
3102 test "x$ac_site_file" = xNONE && continue
3103 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3104 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3105$as_echo "$as_me: loading site script $ac_site_file" >&6;}
3106 sed 's/^/| /' "$ac_site_file" >&5
a9bec17c 3107 . "$ac_site_file"
067d23c9
KY
3108 fi
3109done
3110
3111if test -r "$cache_file"; then
3112 # Some versions of bash will fail to source /dev/null (special files
3113 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3114 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3115 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3116$as_echo "$as_me: loading cache $cache_file" >&6;}
3117 case $cache_file in
3118 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3119 *) . "./$cache_file";;
3120 esac
3121 fi
3122else
3123 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3124$as_echo "$as_me: creating cache $cache_file" >&6;}
3125 >$cache_file
3126fi
3127
3128as_fn_append ac_header_list " stdlib.h"
3129as_fn_append ac_header_list " unistd.h"
3130as_fn_append ac_header_list " sys/param.h"
6c051bab 3131as_fn_append ac_func_list " readlinkat"
e275c824
PE
3132gl_getopt_required=GNU
3133as_fn_append ac_header_list " getopt.h"
4fda9c95
GM
3134as_fn_append ac_header_list " wchar.h"
3135as_fn_append ac_header_list " stdint.h"
3136as_fn_append ac_header_list " inttypes.h"
ae0d7250 3137as_fn_append ac_func_list " lstat"
067d23c9 3138as_fn_append ac_func_list " alarm"
3e0be4ab 3139as_fn_append ac_func_list " pthread_sigmask"
ae0d7250 3140as_fn_append ac_func_list " readlink"
6ad6792b 3141as_fn_append ac_header_list " sys/socket.h"
16c3e636 3142as_fn_append ac_func_list " tzset"
369e19fc
PE
3143as_fn_append ac_func_list " strtoimax"
3144as_fn_append ac_func_list " strtoumax"
ae0d7250 3145as_fn_append ac_func_list " symlink"
5fa4ac76 3146as_fn_append ac_header_list " sys/stat.h"
1fd182f0
PE
3147as_fn_append ac_header_list " sys/time.h"
3148as_fn_append ac_func_list " localtime_r"
067d23c9
KY
3149# Check that the precious variables saved in the cache have kept the same
3150# value.
3151ac_cache_corrupted=false
3152for ac_var in $ac_precious_vars; do
3153 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3154 eval ac_new_set=\$ac_env_${ac_var}_set
3155 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3156 eval ac_new_val=\$ac_env_${ac_var}_value
3157 case $ac_old_set,$ac_new_set in
3158 set,)
3159 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3160$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3161 ac_cache_corrupted=: ;;
3162 ,set)
3163 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3164$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3165 ac_cache_corrupted=: ;;
3166 ,);;
3167 *)
3168 if test "x$ac_old_val" != "x$ac_new_val"; then
3169 # differences in whitespace do not lead to failure.
3170 ac_old_val_w=`echo x $ac_old_val`
3171 ac_new_val_w=`echo x $ac_new_val`
3172 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3173 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3174$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3175 ac_cache_corrupted=:
3176 else
3177 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3178$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3179 eval $ac_var=\$ac_old_val
3180 fi
3181 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3182$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3183 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3184$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3185 fi;;
3186 esac
3187 # Pass precious variables to config.status.
3188 if test "$ac_new_set" = set; then
3189 case $ac_new_val in
3190 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3191 *) ac_arg=$ac_var=$ac_new_val ;;
3192 esac
3193 case " $ac_configure_args " in
3194 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3195 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3196 esac
3197 fi
3198done
3199if $ac_cache_corrupted; then
3200 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3201$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3202 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3203$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
a9bec17c 3204 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
067d23c9
KY
3205fi
3206## -------------------- ##
3207## Main body of script. ##
3208## -------------------- ##
3209
3210ac_ext=c
3211ac_cpp='$CPP $CPPFLAGS'
3212ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3213ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3214ac_compiler_gnu=$ac_cv_c_compiler_gnu
3215
3216
3217ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3218
3219
743c80a7 3220ac_aux_dir=
369e19fc 3221for ac_dir in build-aux "$srcdir"/build-aux; do
a9bec17c
GM
3222 for ac_t in install-sh install.sh shtool; do
3223 if test -f "$ac_dir/$ac_t"; then
3224 ac_aux_dir=$ac_dir
3225 ac_install_sh="$ac_aux_dir/$ac_t -c"
3226 break 2
3227 fi
3228 done
743c80a7
PE
3229done
3230if test -z "$ac_aux_dir"; then
a9bec17c 3231 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
743c80a7 3232fi
067d23c9 3233
743c80a7
PE
3234# These three variables are undocumented and unsupported,
3235# and are intended to be withdrawn in a future Autoconf release.
3236# They can cause serious problems if a builder's source tree is in a directory
3237# whose full name contains unusual characters.
3238ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3239ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3240ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
067d23c9 3241
067d23c9 3242
369e19fc
PE
3243am__api_version='1.11'
3244
743c80a7
PE
3245# Find a good install program. We prefer a C program (faster),
3246# so one script is as good as another. But avoid the broken or
3247# incompatible versions:
3248# SysV /etc/install, /usr/sbin/install
3249# SunOS /usr/etc/install
3250# IRIX /sbin/install
3251# AIX /bin/install
3252# AmigaOS /C/install, which installs bootblocks on floppy discs
3253# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3254# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3255# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3256# OS/2's system install, which has a completely different semantic
3257# ./install, which can be erroneously created by make from ./install.sh.
3258# Reject install programs that cannot install multiple files.
3259{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3260$as_echo_n "checking for a BSD-compatible install... " >&6; }
3261if test -z "$INSTALL"; then
a9bec17c 3262if test "${ac_cv_path_install+set}" = set; then :
743c80a7
PE
3263 $as_echo_n "(cached) " >&6
3264else
3265 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3266for as_dir in $PATH
3267do
3268 IFS=$as_save_IFS
3269 test -z "$as_dir" && as_dir=.
3270 # Account for people who put trailing slashes in PATH elements.
3271case $as_dir/ in #((
3272 ./ | .// | /[cC]/* | \
3273 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3274 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3275 /usr/ucb/* ) ;;
3276 *)
3277 # OSF1 and SCO ODT 3.0 have their own names for install.
3278 # Don't use installbsd from OSF since it installs stuff as root
3279 # by default.
3280 for ac_prog in ginstall scoinst install; do
3281 for ac_exec_ext in '' $ac_executable_extensions; do
3282 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3283 if test $ac_prog = install &&
3284 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3285 # AIX install. It has an incompatible calling convention.
3286 :
3287 elif test $ac_prog = install &&
3288 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3289 # program-specific install script used by HP pwplus--don't use.
3290 :
3291 else
3292 rm -rf conftest.one conftest.two conftest.dir
3293 echo one > conftest.one
3294 echo two > conftest.two
3295 mkdir conftest.dir
3296 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3297 test -s conftest.one && test -s conftest.two &&
3298 test -s conftest.dir/conftest.one &&
3299 test -s conftest.dir/conftest.two
3300 then
3301 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3302 break 3
3303 fi
3304 fi
3305 fi
3306 done
3307 done
3308 ;;
3309esac
067d23c9 3310
743c80a7
PE
3311 done
3312IFS=$as_save_IFS
067d23c9 3313
743c80a7 3314rm -rf conftest.one conftest.two conftest.dir
067d23c9 3315
067d23c9 3316fi
743c80a7
PE
3317 if test "${ac_cv_path_install+set}" = set; then
3318 INSTALL=$ac_cv_path_install
3319 else
3320 # As a last resort, use the slow shell script. Don't cache a
3321 # value for INSTALL within a source directory, because that will
3322 # break other packages using the cache if that directory is
3323 # removed, or if the value is a relative name.
3324 INSTALL=$ac_install_sh
3325 fi
067d23c9 3326fi
743c80a7
PE
3327{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3328$as_echo "$INSTALL" >&6; }
067d23c9 3329
743c80a7
PE
3330# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3331# It thinks the first close brace ends the variable substitution.
3332test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
067d23c9 3333
743c80a7 3334test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
067d23c9 3335
743c80a7 3336test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
067d23c9 3337
743c80a7
PE
3338{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3339$as_echo_n "checking whether build environment is sane... " >&6; }
3340# Just in case
3341sleep 1
3342echo timestamp > conftest.file
3343# Reject unsafe characters in $srcdir or the absolute working directory
3344# name. Accept space and tab only in the latter.
3345am_lf='
3346'
3347case `pwd` in
3348 *[\\\"\#\$\&\'\`$am_lf]*)
a9bec17c 3349 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
743c80a7
PE
3350esac
3351case $srcdir in
3352 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
a9bec17c 3353 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
743c80a7 3354esac
067d23c9 3355
743c80a7
PE
3356# Do `set' in a subshell so we don't clobber the current shell's
3357# arguments. Must try -L first in case configure is actually a
3358# symlink; some systems play weird games with the mod time of symlinks
3359# (eg FreeBSD returns the mod time of the symlink's containing
3360# directory).
3361if (
3362 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3363 if test "$*" = "X"; then
3364 # -L didn't work.
3365 set X `ls -t "$srcdir/configure" conftest.file`
3366 fi
3367 rm -f conftest.file
3368 if test "$*" != "X $srcdir/configure conftest.file" \
3369 && test "$*" != "X conftest.file $srcdir/configure"; then
3370
3371 # If neither matched, then we have a broken ls. This can happen
3372 # if, for instance, CONFIG_SHELL is bash and it inherits a
3373 # broken ls alias from the environment. This has actually
3374 # happened. Such a system could not be considered "sane".
a9bec17c 3375 as_fn_error "ls -t appears to fail. Make sure there is not a broken
743c80a7
PE
3376alias in your environment" "$LINENO" 5
3377 fi
067d23c9 3378
743c80a7
PE
3379 test "$2" = conftest.file
3380 )
3381then
3382 # Ok.
3383 :
067d23c9 3384else
a9bec17c 3385 as_fn_error "newly created file is older than distributed files!
743c80a7 3386Check your system clock" "$LINENO" 5
067d23c9 3387fi
743c80a7
PE
3388{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3389$as_echo "yes" >&6; }
3390test "$program_prefix" != NONE &&
3391 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3392# Use a double $ so make ignores it.
3393test "$program_suffix" != NONE &&
3394 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3395# Double any \ or $.
3396# By default was `s,x,x', remove it if useless.
3397ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3398program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
067d23c9 3399
743c80a7
PE
3400# expand $ac_aux_dir to an absolute path
3401am_aux_dir=`cd $ac_aux_dir && pwd`
067d23c9 3402
743c80a7
PE
3403if test x"${MISSING+set}" != xset; then
3404 case $am_aux_dir in
3405 *\ * | *\ *)
3406 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3407 *)
3408 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3409 esac
067d23c9 3410fi
743c80a7
PE
3411# Use eval to expand $SHELL
3412if eval "$MISSING --run true"; then
3413 am_missing_run="$MISSING --run "
067d23c9 3414else
743c80a7
PE
3415 am_missing_run=
3416 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3417$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
067d23c9
KY
3418fi
3419
743c80a7
PE
3420if test x"${install_sh}" != xset; then
3421 case $am_aux_dir in
3422 *\ * | *\ *)
3423 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3424 *)
3425 install_sh="\${SHELL} $am_aux_dir/install-sh"
3426 esac
067d23c9
KY
3427fi
3428
743c80a7
PE
3429# Installed binaries are usually stripped using `strip' when the user
3430# run `make install-strip'. However `strip' might not be the right
3431# tool to use in cross-compilation environments, therefore Automake
3432# will honor the `STRIP' environment variable to overrule this program.
3433if test "$cross_compiling" != no; then
3434 if test -n "$ac_tool_prefix"; then
3435 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3436set dummy ${ac_tool_prefix}strip; ac_word=$2
3437{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3438$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 3439if test "${ac_cv_prog_STRIP+set}" = set; then :
743c80a7 3440 $as_echo_n "(cached) " >&6
067d23c9 3441else
743c80a7
PE
3442 if test -n "$STRIP"; then
3443 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3444else
3445as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3446for as_dir in $PATH
3447do
3448 IFS=$as_save_IFS
3449 test -z "$as_dir" && as_dir=.
3450 for ac_exec_ext in '' $ac_executable_extensions; do
3451 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3452 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3454 break 2
3455 fi
3456done
3457 done
3458IFS=$as_save_IFS
067d23c9
KY
3459
3460fi
067d23c9 3461fi
743c80a7
PE
3462STRIP=$ac_cv_prog_STRIP
3463if test -n "$STRIP"; then
3464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3465$as_echo "$STRIP" >&6; }
3466else
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3468$as_echo "no" >&6; }
067d23c9
KY
3469fi
3470
3471
067d23c9 3472fi
743c80a7
PE
3473if test -z "$ac_cv_prog_STRIP"; then
3474 ac_ct_STRIP=$STRIP
3475 # Extract the first word of "strip", so it can be a program name with args.
3476set dummy strip; ac_word=$2
3477{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3478$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 3479if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
743c80a7
PE
3480 $as_echo_n "(cached) " >&6
3481else
3482 if test -n "$ac_ct_STRIP"; then
3483 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3484else
3485as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3486for as_dir in $PATH
3487do
3488 IFS=$as_save_IFS
3489 test -z "$as_dir" && as_dir=.
3490 for ac_exec_ext in '' $ac_executable_extensions; do
3491 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3492 ac_cv_prog_ac_ct_STRIP="strip"
3493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3494 break 2
3495 fi
3496done
3497 done
3498IFS=$as_save_IFS
3499
3500fi
3501fi
3502ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3503if test -n "$ac_ct_STRIP"; then
3504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3505$as_echo "$ac_ct_STRIP" >&6; }
3506else
3507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3508$as_echo "no" >&6; }
3509fi
3510
3511 if test "x$ac_ct_STRIP" = x; then
3512 STRIP=":"
3513 else
3514 case $cross_compiling:$ac_tool_warned in
3515yes:)
3516{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3517$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3518ac_tool_warned=yes ;;
3519esac
3520 STRIP=$ac_ct_STRIP
3521 fi
3522else
3523 STRIP="$ac_cv_prog_STRIP"
3524fi
3525
3526fi
3527INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3528
3529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3530$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3531if test -z "$MKDIR_P"; then
a9bec17c 3532 if test "${ac_cv_path_mkdir+set}" = set; then :
743c80a7
PE
3533 $as_echo_n "(cached) " >&6
3534else
3535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3536for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3537do
3538 IFS=$as_save_IFS
3539 test -z "$as_dir" && as_dir=.
3540 for ac_prog in mkdir gmkdir; do
3541 for ac_exec_ext in '' $ac_executable_extensions; do
3542 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3543 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3544 'mkdir (GNU coreutils) '* | \
3545 'mkdir (coreutils) '* | \
3546 'mkdir (fileutils) '4.1*)
3547 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3548 break 3;;
3549 esac
3550 done
3551 done
3552 done
3553IFS=$as_save_IFS
3554
3555fi
3556
3557 test -d ./--version && rmdir ./--version
3558 if test "${ac_cv_path_mkdir+set}" = set; then
3559 MKDIR_P="$ac_cv_path_mkdir -p"
3560 else
3561 # As a last resort, use the slow shell script. Don't cache a
3562 # value for MKDIR_P within a source directory, because that will
3563 # break other packages using the cache if that directory is
3564 # removed, or if the value is a relative name.
3565 MKDIR_P="$ac_install_sh -d"
3566 fi
3567fi
3568{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3569$as_echo "$MKDIR_P" >&6; }
3570
a451f14b 3571
743c80a7
PE
3572mkdir_p="$MKDIR_P"
3573case $mkdir_p in
3574 [\\/$]* | ?:[\\/]*) ;;
3575 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3576esac
3577
3578for ac_prog in gawk mawk nawk awk
3579do
3580 # Extract the first word of "$ac_prog", so it can be a program name with args.
3581set dummy $ac_prog; ac_word=$2
3582{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3583$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 3584if test "${ac_cv_prog_AWK+set}" = set; then :
743c80a7
PE
3585 $as_echo_n "(cached) " >&6
3586else
3587 if test -n "$AWK"; then
3588 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3589else
3590as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3591for as_dir in $PATH
3592do
3593 IFS=$as_save_IFS
3594 test -z "$as_dir" && as_dir=.
3595 for ac_exec_ext in '' $ac_executable_extensions; do
3596 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3597 ac_cv_prog_AWK="$ac_prog"
3598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3599 break 2
3600 fi
3601done
3602 done
3603IFS=$as_save_IFS
3604
3605fi
3606fi
3607AWK=$ac_cv_prog_AWK
3608if test -n "$AWK"; then
3609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3610$as_echo "$AWK" >&6; }
3611else
3612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3613$as_echo "no" >&6; }
3614fi
3615
3616
3617 test -n "$AWK" && break
3618done
3619
3620{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3621$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3622set x ${MAKE-make}
3623ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
a9bec17c 3624if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
743c80a7
PE
3625 $as_echo_n "(cached) " >&6
3626else
3627 cat >conftest.make <<\_ACEOF
3628SHELL = /bin/sh
3629all:
3630 @echo '@@@%%%=$(MAKE)=@@@%%%'
3631_ACEOF
a9bec17c 3632# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
743c80a7
PE
3633case `${MAKE-make} -f conftest.make 2>/dev/null` in
3634 *@@@%%%=?*=@@@%%%*)
3635 eval ac_cv_prog_make_${ac_make}_set=yes;;
3636 *)
3637 eval ac_cv_prog_make_${ac_make}_set=no;;
3638esac
3639rm -f conftest.make
3640fi
3641if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3643$as_echo "yes" >&6; }
3644 SET_MAKE=
3645else
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3647$as_echo "no" >&6; }
3648 SET_MAKE="MAKE=${MAKE-make}"
3649fi
3650
3651rm -rf .tst 2>/dev/null
3652mkdir .tst 2>/dev/null
3653if test -d .tst; then
3654 am__leading_dot=.
3655else
3656 am__leading_dot=_
3657fi
3658rmdir .tst 2>/dev/null
3659
3660if test "`cd $srcdir && pwd`" != "`pwd`"; then
3661 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3662 # is not polluted with repeated "-I."
3663 am__isrc=' -I$(srcdir)'
3664 # test to see if srcdir already configured
3665 if test -f $srcdir/config.status; then
a9bec17c 3666 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
743c80a7
PE
3667 fi
3668fi
3669
3670# test whether we have cygpath
3671if test -z "$CYGPATH_W"; then
3672 if (cygpath --version) >/dev/null 2>/dev/null; then
3673 CYGPATH_W='cygpath -w'
3674 else
3675 CYGPATH_W=echo
3676 fi
3677fi
3678
3679
3680# Define the identity of the package.
3681 PACKAGE='emacs'
d570ce1c 3682 VERSION='24.0.93'
743c80a7
PE
3683
3684
3685cat >>confdefs.h <<_ACEOF
3686#define PACKAGE "$PACKAGE"
3687_ACEOF
3688
3689
3690cat >>confdefs.h <<_ACEOF
3691#define VERSION "$VERSION"
3692_ACEOF
3693
3694# Some tools Automake needs.
3695
3696ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3697
3698
3699AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3700
3701
3702AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3703
3704
3705AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3706
3707
3708MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3709
3710# We need awk for the "check" target. The system "awk" is bad on
3711# some platforms.
3712# Always define AMTAR for backward compatibility.
3713
3714AMTAR=${AMTAR-"${am_missing_run}tar"}
3715
3716am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3717
3718
3719
3720
3721
3722
3723
3724
3725lispdir='${datadir}/emacs/${version}/lisp'
3726locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3727'${datadir}/emacs/site-lisp'
3728lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
3729etcdir='${datadir}/emacs/${version}/etc'
3730archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3731docdir='${datadir}/emacs/${version}/etc'
3732gamedir='${localstatedir}/games/emacs'
3733
3734
3735
3736
3737# Check whether --with-pop was given.
3738if test "${with_pop+set}" = set; then :
3739 withval=$with_pop;
3740else
3741 with_pop=yes
3742fi
3743
3744if test "$with_pop" = yes; then
3745 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3746
3747fi
3748
3749
3750# Check whether --with-kerberos was given.
3751if test "${with_kerberos+set}" = set; then :
3752 withval=$with_kerberos;
3753else
3754 with_kerberos=no
3755fi
3756
3757if test "$with_kerberos" != no; then
3758 $as_echo "#define KERBEROS 1" >>confdefs.h
3759
3760fi
3761
3762
3763# Check whether --with-kerberos5 was given.
3764if test "${with_kerberos5+set}" = set; then :
3765 withval=$with_kerberos5;
3766else
3767 with_kerberos5=no
3768fi
3769
3770if test "${with_kerberos5}" != no; then
3771 if test "${with_kerberos}" = no; then
3772 with_kerberos=yes
3773 $as_echo "#define KERBEROS 1" >>confdefs.h
3774
3775 fi
3776
3777$as_echo "#define KERBEROS5 1" >>confdefs.h
3778
3779fi
3780
3781
3782# Check whether --with-hesiod was given.
3783if test "${with_hesiod+set}" = set; then :
3784 withval=$with_hesiod;
3785else
3786 with_hesiod=no
3787fi
3788
3789if test "$with_hesiod" != no; then
3790
3791$as_echo "#define HESIOD 1" >>confdefs.h
3792
3793fi
3794
3795
3796# Check whether --with-mmdf was given.
3797if test "${with_mmdf+set}" = set; then :
3798 withval=$with_mmdf;
3799else
3800 with_mmdf=no
3801fi
3802
3803if test "$with_mmdf" != no; then
3804
3805$as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3806
3807fi
3808
3809
3810# Check whether --with-mail-unlink was given.
3811if test "${with_mail_unlink+set}" = set; then :
3812 withval=$with_mail_unlink;
3813else
3814 with_mail_unlink=no
3815fi
3816
3817if test "$with_mail_unlink" != no; then
3818
3819$as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3820
3821fi
3822
3823
3824# Check whether --with-mailhost was given.
3825if test "${with_mailhost+set}" = set; then :
3826 withval=$with_mailhost;
3827cat >>confdefs.h <<_ACEOF
3828#define MAILHOST "$withval"
3829_ACEOF
3830
3831fi
3832
3833
3834
067d23c9
KY
3835# Check whether --with-sound was given.
3836if test "${with_sound+set}" = set; then :
3837 withval=$with_sound;
3838else
3839 with_sound=yes
3840fi
3841
3842
3843
3844# Check whether --with-sync-input was given.
3845if test "${with_sync_input+set}" = set; then :
3846 withval=$with_sync_input;
3847else
3848 with_sync_input=yes
3849fi
3850
3851if test "$with_sync_input" = yes; then
3852
3853$as_echo "#define SYNC_INPUT 1" >>confdefs.h
3854
3855fi
3856
3857
3858# Check whether --with-x-toolkit was given.
3859if test "${with_x_toolkit+set}" = set; then :
3860 withval=$with_x_toolkit; case "${withval}" in
3861 y | ye | yes ) val=gtk ;;
3862 n | no ) val=no ;;
3863 l | lu | luc | luci | lucid ) val=lucid ;;
3864 a | at | ath | athe | athen | athena ) val=athena ;;
3865 m | mo | mot | moti | motif ) val=motif ;;
3866 g | gt | gtk ) val=gtk ;;
3867 gtk3 ) val=gtk3 ;;
3868 * )
a9bec17c 3869as_fn_error "\`--with-x-toolkit=$withval' is invalid;
067d23c9
KY
3870this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3871\`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3872 ;;
3873 esac
3874 with_x_toolkit=$val
3875
3876fi
3877
3878
3879
0442dc7f
GM
3880# Check whether --with-wide-int was given.
3881if test "${with_wide_int+set}" = set; then :
3882 withval=$with_wide_int;
3883else
3884 with_wide_int=no
3885fi
3886
3887if test "$with_wide_int" = yes; then
3888
3889$as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3890
3891fi
3892
3893
067d23c9
KY
3894# Check whether --with-xpm was given.
3895if test "${with_xpm+set}" = set; then :
3896 withval=$with_xpm;
3897else
3898 with_xpm=yes
3899fi
3900
3901
3902# Check whether --with-jpeg was given.
3903if test "${with_jpeg+set}" = set; then :
3904 withval=$with_jpeg;
3905else
3906 with_jpeg=yes
3907fi
3908
3909
3910# Check whether --with-tiff was given.
3911if test "${with_tiff+set}" = set; then :
3912 withval=$with_tiff;
3913else
3914 with_tiff=yes
3915fi
3916
3917
3918# Check whether --with-gif was given.
3919if test "${with_gif+set}" = set; then :
3920 withval=$with_gif;
3921else
3922 with_gif=yes
3923fi
3924
3925
3926# Check whether --with-png was given.
3927if test "${with_png+set}" = set; then :
3928 withval=$with_png;
3929else
3930 with_png=yes
3931fi
3932
3933
3934# Check whether --with-rsvg was given.
3935if test "${with_rsvg+set}" = set; then :
3936 withval=$with_rsvg;
3937else
3938 with_rsvg=yes
3939fi
3940
3941
3942# Check whether --with-xml2 was given.
3943if test "${with_xml2+set}" = set; then :
3944 withval=$with_xml2;
3945else
3946 with_xml2=yes
3947fi
3948
3949
3950# Check whether --with-imagemagick was given.
3951if test "${with_imagemagick+set}" = set; then :
3952 withval=$with_imagemagick;
3953else
3954 with_imagemagick=yes
3955fi
3956
3957
3958
3959# Check whether --with-xft was given.
3960if test "${with_xft+set}" = set; then :
3961 withval=$with_xft;
3962else
3963 with_xft=yes
3964fi
3965
3966
3967# Check whether --with-libotf was given.
3968if test "${with_libotf+set}" = set; then :
3969 withval=$with_libotf;
3970else
3971 with_libotf=yes
3972fi
3973
3974
3975# Check whether --with-m17n-flt was given.
3976if test "${with_m17n_flt+set}" = set; then :
3977 withval=$with_m17n_flt;
3978else
3979 with_m17n_flt=yes
3980fi
3981
3982
3983
3984# Check whether --with-toolkit-scroll-bars was given.
3985if test "${with_toolkit_scroll_bars+set}" = set; then :
3986 withval=$with_toolkit_scroll_bars;
3987else
3988 with_toolkit_scroll_bars=yes
3989fi
3990
3991
3992# Check whether --with-xaw3d was given.
3993if test "${with_xaw3d+set}" = set; then :
3994 withval=$with_xaw3d;
3995else
3996 with_xaw3d=yes
3997fi
3998
3999
4000# Check whether --with-xim was given.
4001if test "${with_xim+set}" = set; then :
4002 withval=$with_xim;
4003else
4004 with_xim=yes
4005fi
4006
4007
4008# Check whether --with-ns was given.
4009if test "${with_ns+set}" = set; then :
4010 withval=$with_ns;
4011else
4012 with_ns=no
4013fi
4014
4015
4016
4017# Check whether --with-gpm was given.
4018if test "${with_gpm+set}" = set; then :
4019 withval=$with_gpm;
4020else
4021 with_gpm=yes
4022fi
4023
4024
4025# Check whether --with-dbus was given.
4026if test "${with_dbus+set}" = set; then :
4027 withval=$with_dbus;
4028else
4029 with_dbus=yes
4030fi
4031
4032
4033# Check whether --with-gconf was given.
4034if test "${with_gconf+set}" = set; then :
4035 withval=$with_gconf;
4036else
4037 with_gconf=yes
4038fi
4039
4040
f527bd02
GM
4041# Check whether --with-gsettings was given.
4042if test "${with_gsettings+set}" = set; then :
4043 withval=$with_gsettings;
4044else
4045 with_gsettings=yes
4046fi
4047
4048
067d23c9
KY
4049# Check whether --with-selinux was given.
4050if test "${with_selinux+set}" = set; then :
4051 withval=$with_selinux;
4052else
4053 with_selinux=yes
4054fi
4055
4056
4057# Check whether --with-gnutls was given.
4058if test "${with_gnutls+set}" = set; then :
4059 withval=$with_gnutls;
4060else
4061 with_gnutls=yes
4062fi
4063
4064
4065## For the times when you want to build Emacs but don't have
4066## a suitable makeinfo, and can live without the manuals.
4067
4068# Check whether --with-makeinfo was given.
4069if test "${with_makeinfo+set}" = set; then :
4070 withval=$with_makeinfo;
4071else
4072 with_makeinfo=yes
4073fi
4074
4075
c3a461a5
GM
4076## Makefile.in needs the cache file name.
4077
4078
067d23c9
KY
4079## This is an option because I do not know if all info/man support
4080## compressed files, nor how to test if they do so.
4081
4082# Check whether --with-compress-info was given.
4083if test "${with_compress_info+set}" = set; then :
4084 withval=$with_compress_info;
4085else
4086 with_compress_info=yes
4087fi
4088
4089if test $with_compress_info = yes; then
4090 GZIP_INFO=yes
4091else
4092 GZIP_INFO=
4093fi
4094
4095
4096
4097# Check whether --with-pkg-config-prog was given.
4098if test "${with_pkg_config_prog+set}" = set; then :
4099 withval=$with_pkg_config_prog;
4100fi
4101
4102if test "X${with_pkg_config_prog}" != X; then
4103 if test "${with_pkg_config_prog}" != yes; then
4104 PKG_CONFIG="${with_pkg_config_prog}"
4105 fi
4106fi
4107
4108CRT_DIR=
4109
4110# Check whether --with-crt-dir was given.
4111if test "${with_crt_dir+set}" = set; then :
4112 withval=$with_crt_dir;
4113fi
4114
4115CRT_DIR="${with_crt_dir}"
4116
4117
4fc5868a
UM
4118# Check whether --with-gameuser was given.
4119if test "${with_gameuser+set}" = set; then :
4120 withval=$with_gameuser;
4121fi
4122
4123test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4124 && gameuser="${with_gameuser}"
4125test "X$gameuser" = X && gameuser=games
4126
4127
067d23c9
KY
4128# Check whether --with-gnustep-conf was given.
4129if test "${with_gnustep_conf+set}" = set; then :
4130 withval=$with_gnustep_conf;
4131fi
4132
4133test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4134 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4135test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4136 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4137
4138# Check whether --enable-ns-self-contained was given.
4139if test "${enable_ns_self_contained+set}" = set; then :
4140 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4141else
4142 EN_NS_SELF_CONTAINED=yes
4143fi
4144
4145
4146# Check whether --enable-asserts was given.
4147if test "${enable_asserts+set}" = set; then :
4148 enableval=$enable_asserts; USE_XASSERTS=$enableval
4149else
4150 USE_XASSERTS=no
4151fi
4152
4153
4154# Check whether --enable-maintainer-mode was given.
4155if test "${enable_maintainer_mode+set}" = set; then :
4156 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
4157else
dccef361 4158 USE_MAINTAINER_MODE=yes
067d23c9
KY
4159fi
4160
4161if test $USE_MAINTAINER_MODE = yes; then
4162 MAINT=
4163else
4164 MAINT=#
4165fi
4166
4167
4168# Check whether --enable-locallisppath was given.
4169if test "${enable_locallisppath+set}" = set; then :
4170 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4171 locallisppath=
4172elif test "${enableval}" != "yes"; then
4173 locallisppath=${enableval}
4174fi
4175fi
4176
4177
4178# Check whether --enable-checking was given.
4179if test "${enable_checking+set}" = set; then :
4180 enableval=$enable_checking; ac_checking_flags="${enableval}"
4181fi
4182
4183IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4184for check in $ac_checking_flags
4185do
4186 case $check in
4187 # these set all the flags to specific states
4188 yes) ac_enable_checking=1 ;;
4189 no) ac_enable_checking= ;
4190 ac_gc_check_stringbytes= ;
4191 ac_gc_check_string_overrun= ;
4192 ac_gc_check_string_free_list= ;
4193 ac_xmalloc_overrun= ;
4194 ac_gc_check_cons_list= ;;
4195 all) ac_enable_checking=1 ;
4196 ac_gc_check_stringbytes=1 ;
4197 ac_gc_check_string_overrun=1 ;
4198 ac_gc_check_string_free_list=1 ;
4199 ac_xmalloc_overrun=1 ;
4200 ac_gc_check_cons_list=1 ;;
4201 # these enable particular checks
4202 stringbytes) ac_gc_check_stringbytes=1 ;;
4203 stringoverrun) ac_gc_check_string_overrun=1 ;;
4204 stringfreelist) ac_gc_check_string_free_list=1 ;;
4205 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4206 conslist) ac_gc_check_cons_list=1 ;;
a9bec17c 4207 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
067d23c9
KY
4208 esac
4209done
4210IFS="$ac_save_IFS"
4211
4212if test x$ac_enable_checking != x ; then
4213
4214$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4215
4216fi
4217if test x$ac_gc_check_stringbytes != x ; then
4218
4219$as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4220
4221fi
4fda9c95 4222if test x$ac_gc_check_string_overrun != x ; then
067d23c9
KY
4223
4224$as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4225
4226fi
4227if test x$ac_gc_check_string_free_list != x ; then
4228
4229$as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4230
4231fi
4232if test x$ac_xmalloc_overrun != x ; then
4233
4234$as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4235
4236fi
4237if test x$ac_gc_check_cons_list != x ; then
4238
4239$as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4240
4241fi
4242
4243# Check whether --enable-use-lisp-union-type was given.
4244if test "${enable_use_lisp_union_type+set}" = set; then :
4245 enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then
4246
4247$as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h
4248
4249fi
4250fi
4251
4252
4253
4254# Check whether --enable-profiling was given.
4255if test "${enable_profiling+set}" = set; then :
4256 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4257fi
4258
4259if test x$ac_enable_profiling != x ; then
4260 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4261else
4262 PROFILING_CFLAGS=
4263fi
4264
4265
4266# Check whether --enable-autodepend was given.
4267if test "${enable_autodepend+set}" = set; then :
4268 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4269else
4270 ac_enable_autodepend=yes
4271fi
4272
4273
4274#### Make srcdir absolute, if it isn't already. It's important to
4275#### avoid running the path through pwd unnecessarily, since pwd can
4276#### give you automounter prefixes, which can go away. We do all this
4277#### so Emacs can find its files when run uninstalled.
4278## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4279unset CDPATH
4280case "${srcdir}" in
4281 /* ) ;;
4282 . )
4283 ## We may be able to use the $PWD environment variable to make this
4284 ## absolute. But sometimes PWD is inaccurate.
4285 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4286 ## but that tested only for a well-formed and valid PWD,
4287 ## it did not object when PWD was well-formed and valid but just wrong.
4288 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4289 then
4290 srcdir="$PWD"
4291 else
4292 srcdir="`(cd ${srcdir}; pwd)`"
4293 fi
4294 ;;
4295 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4296esac
4297
067d23c9
KY
4298#### Given the configuration name, set machfile and opsysfile to the
4299#### names of the m/*.h and s/*.h files we should use.
4300
4301### Canonicalize the configuration name.
4302
067d23c9
KY
4303# Make sure we can run config.sub.
4304$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
a9bec17c 4305 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
067d23c9
KY
4306
4307{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4308$as_echo_n "checking build system type... " >&6; }
a9bec17c 4309if test "${ac_cv_build+set}" = set; then :
067d23c9
KY
4310 $as_echo_n "(cached) " >&6
4311else
4312 ac_build_alias=$build_alias
4313test "x$ac_build_alias" = x &&
4314 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4315test "x$ac_build_alias" = x &&
a9bec17c 4316 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
067d23c9 4317ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
a9bec17c 4318 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
067d23c9
KY
4319
4320fi
4321{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4322$as_echo "$ac_cv_build" >&6; }
4323case $ac_cv_build in
4324*-*-*) ;;
a9bec17c 4325*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
067d23c9
KY
4326esac
4327build=$ac_cv_build
4328ac_save_IFS=$IFS; IFS='-'
4329set x $ac_cv_build
4330shift
4331build_cpu=$1
4332build_vendor=$2
4333shift; shift
4334# Remember, the first character of IFS is used to create $*,
4335# except with old shells:
4336build_os=$*
4337IFS=$ac_save_IFS
4338case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4339
4340
4341{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4342$as_echo_n "checking host system type... " >&6; }
a9bec17c 4343if test "${ac_cv_host+set}" = set; then :
067d23c9
KY
4344 $as_echo_n "(cached) " >&6
4345else
4346 if test "x$host_alias" = x; then
4347 ac_cv_host=$ac_cv_build
4348else
4349 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
a9bec17c 4350 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
067d23c9
KY
4351fi
4352
4353fi
4354{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4355$as_echo "$ac_cv_host" >&6; }
4356case $ac_cv_host in
4357*-*-*) ;;
a9bec17c 4358*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
067d23c9
KY
4359esac
4360host=$ac_cv_host
4361ac_save_IFS=$IFS; IFS='-'
4362set x $ac_cv_host
4363shift
4364host_cpu=$1
4365host_vendor=$2
4366shift; shift
4367# Remember, the first character of IFS is used to create $*,
4368# except with old shells:
4369host_os=$*
4370IFS=$ac_save_IFS
4371case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4372
4373
4374canonical=$host
4375configuration=${host_alias-${build_alias-$host}}
4376
4377
4378
4379### If you add support for a new configuration, add code to this
4380### switch statement to recognize your configuration name and select
4381### the appropriate operating system and machine description files.
4382
4383### You would hope that you could choose an m/*.h file pretty much
4384### based on the machine portion of the configuration name, and an s/*.h
4385### file based on the operating system portion. However, it turns out
4386### that each m/*.h file is pretty manufacturer-specific - for
4387### example mips.h is MIPS
4388### So we basically have to have a special case for each
4389### configuration name.
4390###
4391### As far as handling version numbers on operating systems is
4392### concerned, make sure things will fail in a fixable way. If
4393### /etc/MACHINES doesn't say anything about version numbers, be
4394### prepared to handle anything reasonably. If version numbers
4395### matter, be sure /etc/MACHINES says something about it.
4396
4397machine='' opsys='' unported=no
4398case "${canonical}" in
4399
9b6e5515
GM
4400 ## GNU/Linux and similar ports
4401 *-*-linux* )
d6a003a8
AS
4402 opsys=gnu-linux
4403 case ${canonical} in
4404 alpha*) machine=alpha ;;
d6a003a8
AS
4405 s390x-*) machine=ibms390x ;;
4406 powerpc*) machine=macppc ;;
4407 sparc*) machine=sparc ;;
4408 ia64*) machine=ia64 ;;
4409 m68k*) machine=m68k ;;
4410 x86_64*) machine=amdx86-64 ;;
4411 esac
4412 ;;
4413
067d23c9
KY
4414 ## FreeBSD ports
4415 *-*-freebsd* )
4416 opsys=freebsd
4417 case "${canonical}" in
4418 alpha*) machine=alpha ;;
4419 amd64-*|x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4420 ia64-*) machine=ia64 ;;
4421 i[3456]86-*) machine=intel386 ;;
4422 powerpc-*) machine=macppc ;;
4423 sparc-*) machine=sparc ;;
4424 sparc64-*) machine=sparc ;;
4425 esac
4426 ;;
4427
4428 ## FreeBSD kernel + glibc based userland
4429 *-*-kfreebsd*gnu* )
4430 opsys=gnu-kfreebsd
4431 case "${canonical}" in
4432 alpha*) machine=alpha ;;
4433 amd64-*|x86_64-*) machine=amdx86-64 ;;
4434 ia64-*) machine=ia64 ;;
4435 i[3456]86-*) machine=intel386 ;;
4436 powerpc-*) machine=macppc ;;
4437 sparc-*) machine=sparc ;;
4438 sparc64-*) machine=sparc ;;
4439 esac
4440 ;;
4441
4442 ## NetBSD ports
4443 *-*-netbsd* )
4444 opsys=netbsd
4445 case "${canonical}" in
4446 alpha*) machine=alpha ;;
4447 x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4448 i[3456]86-*) machine=intel386 ;;
4449 m68k-*) machine=m68k ;;
4450 powerpc-*) machine=macppc ;;
067d23c9
KY
4451 sparc*-) machine=sparc ;;
4452 vax-*) machine=vax ;;
4453 esac
4454 ;;
4455
4456 ## OpenBSD ports
4457 *-*-openbsd* )
4458 opsys=openbsd
4459 case "${canonical}" in
4460 alpha*) machine=alpha ;;
4461 x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4462 i386-*) machine=intel386 ;;
4463 powerpc-*) machine=macppc ;;
4464 sparc*) machine=sparc ;;
4465 vax-*) machine=vax ;;
4466 esac
4467 ;;
4468
067d23c9
KY
4469 ## Apple Darwin / Mac OS X
4470 *-apple-darwin* )
4471 case "${canonical}" in
4472 i[3456]86-* ) machine=intel386 ;;
4473 powerpc-* ) machine=macppc ;;
4474 x86_64-* ) machine=amdx86-64 ;;
4475 * ) unported=yes ;;
4476 esac
4477 opsys=darwin
4478 # Define CPP as follows to make autoconf work correctly.
4479 CPP="${CC-cc} -E -no-cpp-precomp"
4480 # Use fink packages if available.
4481 if test -d /sw/include && test -d /sw/lib; then
4482 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4483 CPP="${CPP} ${GCC_TEST_OPTIONS}"
4484 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4485 fi
4486 ;;
4487
4488 ## HP 9000 series 700 and 800, running HP/UX
4489 hppa*-hp-hpux10.2* )
d6a003a8 4490 opsys=hpux10-20
067d23c9
KY
4491 ;;
4492 hppa*-hp-hpux1[1-9]* )
d6a003a8 4493 opsys=hpux11
067d23c9
KY
4494 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4495 ;;
4496
067d23c9 4497 ## IBM machines
067d23c9
KY
4498 rs6000-ibm-aix4.[23]* )
4499 machine=ibmrs6000 opsys=aix4-2
4500 ;;
4501 powerpc-ibm-aix4.[23]* )
4502 machine=ibmrs6000 opsys=aix4-2
4503 ;;
4504 rs6000-ibm-aix[56]* )
4505 machine=ibmrs6000 opsys=aix4-2
4506 ;;
4507 powerpc-ibm-aix[56]* )
4508 machine=ibmrs6000 opsys=aix4-2
4509 ;;
4510
067d23c9
KY
4511 ## Silicon Graphics machines
4512 ## Iris 4D
4513 mips-sgi-irix6.5 )
fd44db7f 4514 opsys=irix6-5
067d23c9
KY
4515 # Without defining _LANGUAGE_C, things get masked out in the headers
4516 # so that, for instance, grepping for `free' in stdlib.h fails and
4517 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4518 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
4519 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4520 ;;
4521
4522 ## Suns
067d23c9
KY
4523 *-sun-solaris* \
4524 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4525 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4526 case "${canonical}" in
4527 i[3456]86-*-* ) machine=intel386 ;;
4528 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
4529 sparc* ) machine=sparc ;;
4530 * ) unported=yes ;;
4531 esac
4532 case "${canonical}" in
4533 *-sunos5.6* | *-solaris2.6* )
4534 opsys=sol2-6
4535 NON_GNU_CPP=/usr/ccs/lib/cpp
4536 RANLIB="ar -ts"
4537 ;;
4538 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4539 opsys=sol2-6
4540 emacs_check_sunpro_c=yes
4541 NON_GNU_CPP=/usr/ccs/lib/cpp
4542 ;;
4543 *-sunos5* | *-solaris* )
4544 opsys=sol2-10
4545 emacs_check_sunpro_c=yes
4546 NON_GNU_CPP=/usr/ccs/lib/cpp
4547 ;;
4548 esac
4549 ## Watch out for a compiler that we know will not work.
4550 case "${canonical}" in
4551 *-solaris* | *-sunos5* )
4552 if [ "x$CC" = x/usr/ucb/cc ]; then
4553 ## /usr/ucb/cc doesn't work;
4554 ## we should find some other compiler that does work.
4555 unset CC
4556 fi
4557 ;;
4558 *) ;;
4559 esac
4560 ;;
4561
067d23c9
KY
4562 ## Intel 386 machines where we don't care about the manufacturer.
4563 i[3456]86-*-* )
4564 machine=intel386
4565 case "${canonical}" in
4566 *-cygwin ) opsys=cygwin ;;
4567 *-darwin* ) opsys=darwin
4568 CPP="${CC-cc} -E -no-cpp-precomp"
4569 ;;
067d23c9
KY
4570 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4571 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4572 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4573 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4574 esac
4575 ;;
4576
067d23c9
KY
4577 * )
4578 unported=yes
4579 ;;
4580esac
4581
4582### If the code above didn't choose an operating system, just choose
4583### an operating system based on the configuration name. You really
4584### only want to use this when you have no idea what the right
4585### operating system is; if you know what operating systems a machine
4586### runs, it's cleaner to make it explicit in the case statement
4587### above.
4588if test x"${opsys}" = x; then
4589 case "${canonical}" in
4590 *-gnu* ) opsys=gnu ;;
4591 * )
4592 unported=yes
4593 ;;
4594 esac
4595fi
4596
4597
4598
4599if test $unported = yes; then
a9bec17c 4600 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
067d23c9
KY
4601Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4602fi
4603
d6a003a8
AS
4604if test -n "$machine"; then
4605 machfile="m/${machine}.h"
4606else
4607 machfile=
4608fi
067d23c9
KY
4609opsysfile="s/${opsys}.h"
4610
4611
4612#### Choose a compiler.
4613test -n "$CC" && cc_specified=yes
4614
4615# Save the value of CFLAGS that the user specified.
4616SPECIFIED_CFLAGS="$CFLAGS"
4617
4618ac_ext=c
4619ac_cpp='$CPP $CPPFLAGS'
4620ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4621ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4622ac_compiler_gnu=$ac_cv_c_compiler_gnu
4623if test -n "$ac_tool_prefix"; then
4624 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4625set dummy ${ac_tool_prefix}gcc; ac_word=$2
4626{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4627$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4628if test "${ac_cv_prog_CC+set}" = set; then :
067d23c9
KY
4629 $as_echo_n "(cached) " >&6
4630else
4631 if test -n "$CC"; then
4632 ac_cv_prog_CC="$CC" # Let the user override the test.
4633else
4634as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4635for as_dir in $PATH
4636do
4637 IFS=$as_save_IFS
4638 test -z "$as_dir" && as_dir=.
4639 for ac_exec_ext in '' $ac_executable_extensions; do
4640 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4641 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4643 break 2
4644 fi
4645done
4646 done
4647IFS=$as_save_IFS
4648
4649fi
4650fi
4651CC=$ac_cv_prog_CC
4652if test -n "$CC"; then
4653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4654$as_echo "$CC" >&6; }
4655else
4656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4657$as_echo "no" >&6; }
4658fi
4659
4660
4661fi
4662if test -z "$ac_cv_prog_CC"; then
4663 ac_ct_CC=$CC
4664 # Extract the first word of "gcc", so it can be a program name with args.
4665set dummy gcc; ac_word=$2
4666{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4667$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4668if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
067d23c9
KY
4669 $as_echo_n "(cached) " >&6
4670else
4671 if test -n "$ac_ct_CC"; then
4672 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4673else
4674as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4675for as_dir in $PATH
4676do
4677 IFS=$as_save_IFS
4678 test -z "$as_dir" && as_dir=.
4679 for ac_exec_ext in '' $ac_executable_extensions; do
4680 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4681 ac_cv_prog_ac_ct_CC="gcc"
4682 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4683 break 2
4684 fi
4685done
4686 done
4687IFS=$as_save_IFS
4688
4689fi
4690fi
4691ac_ct_CC=$ac_cv_prog_ac_ct_CC
4692if test -n "$ac_ct_CC"; then
4693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4694$as_echo "$ac_ct_CC" >&6; }
4695else
4696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4697$as_echo "no" >&6; }
4698fi
4699
4700 if test "x$ac_ct_CC" = x; then
4701 CC=""
4702 else
4703 case $cross_compiling:$ac_tool_warned in
4704yes:)
4705{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4706$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4707ac_tool_warned=yes ;;
4708esac
4709 CC=$ac_ct_CC
4710 fi
4711else
4712 CC="$ac_cv_prog_CC"
4713fi
4714
4715if test -z "$CC"; then
4716 if test -n "$ac_tool_prefix"; then
4717 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4718set dummy ${ac_tool_prefix}cc; ac_word=$2
4719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4720$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4721if test "${ac_cv_prog_CC+set}" = set; then :
067d23c9
KY
4722 $as_echo_n "(cached) " >&6
4723else
4724 if test -n "$CC"; then
4725 ac_cv_prog_CC="$CC" # Let the user override the test.
4726else
4727as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4728for as_dir in $PATH
4729do
4730 IFS=$as_save_IFS
4731 test -z "$as_dir" && as_dir=.
4732 for ac_exec_ext in '' $ac_executable_extensions; do
4733 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4734 ac_cv_prog_CC="${ac_tool_prefix}cc"
4735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4736 break 2
4737 fi
4738done
4739 done
4740IFS=$as_save_IFS
4741
4742fi
4743fi
4744CC=$ac_cv_prog_CC
4745if test -n "$CC"; then
4746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4747$as_echo "$CC" >&6; }
4748else
4749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4750$as_echo "no" >&6; }
4751fi
4752
4753
4754 fi
4755fi
4756if test -z "$CC"; then
4757 # Extract the first word of "cc", so it can be a program name with args.
4758set dummy cc; ac_word=$2
4759{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4760$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4761if test "${ac_cv_prog_CC+set}" = set; then :
067d23c9
KY
4762 $as_echo_n "(cached) " >&6
4763else
4764 if test -n "$CC"; then
4765 ac_cv_prog_CC="$CC" # Let the user override the test.
4766else
4767 ac_prog_rejected=no
4768as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4769for as_dir in $PATH
4770do
4771 IFS=$as_save_IFS
4772 test -z "$as_dir" && as_dir=.
4773 for ac_exec_ext in '' $ac_executable_extensions; do
4774 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4775 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4776 ac_prog_rejected=yes
4777 continue
4778 fi
4779 ac_cv_prog_CC="cc"
4780 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4781 break 2
4782 fi
4783done
4784 done
4785IFS=$as_save_IFS
4786
4787if test $ac_prog_rejected = yes; then
4788 # We found a bogon in the path, so make sure we never use it.
4789 set dummy $ac_cv_prog_CC
4790 shift
4791 if test $# != 0; then
4792 # We chose a different compiler from the bogus one.
4793 # However, it has the same basename, so the bogon will be chosen
4794 # first if we set CC to just the basename; use the full file name.
4795 shift
4796 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4797 fi
4798fi
4799fi
4800fi
4801CC=$ac_cv_prog_CC
4802if test -n "$CC"; then
4803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4804$as_echo "$CC" >&6; }
4805else
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4807$as_echo "no" >&6; }
4808fi
4809
4810
4811fi
4812if test -z "$CC"; then
4813 if test -n "$ac_tool_prefix"; then
4814 for ac_prog in cl.exe
4815 do
4816 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4817set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4819$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4820if test "${ac_cv_prog_CC+set}" = set; then :
067d23c9
KY
4821 $as_echo_n "(cached) " >&6
4822else
4823 if test -n "$CC"; then
4824 ac_cv_prog_CC="$CC" # Let the user override the test.
4825else
4826as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4827for as_dir in $PATH
4828do
4829 IFS=$as_save_IFS
4830 test -z "$as_dir" && as_dir=.
4831 for ac_exec_ext in '' $ac_executable_extensions; do
4832 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4833 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4835 break 2
4836 fi
4837done
4838 done
4839IFS=$as_save_IFS
4840
4841fi
4842fi
4843CC=$ac_cv_prog_CC
4844if test -n "$CC"; then
4845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4846$as_echo "$CC" >&6; }
4847else
4848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4849$as_echo "no" >&6; }
4850fi
4851
4852
4853 test -n "$CC" && break
4854 done
4855fi
4856if test -z "$CC"; then
4857 ac_ct_CC=$CC
4858 for ac_prog in cl.exe
4859do
4860 # Extract the first word of "$ac_prog", so it can be a program name with args.
4861set dummy $ac_prog; ac_word=$2
4862{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4863$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 4864if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
067d23c9
KY
4865 $as_echo_n "(cached) " >&6
4866else
4867 if test -n "$ac_ct_CC"; then
4868 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4869else
4870as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4871for as_dir in $PATH
4872do
4873 IFS=$as_save_IFS
4874 test -z "$as_dir" && as_dir=.
4875 for ac_exec_ext in '' $ac_executable_extensions; do
4876 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4877 ac_cv_prog_ac_ct_CC="$ac_prog"
4878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4879 break 2
4880 fi
4881done
4882 done
4883IFS=$as_save_IFS
4884
4885fi
4886fi
4887ac_ct_CC=$ac_cv_prog_ac_ct_CC
4888if test -n "$ac_ct_CC"; then
4889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4890$as_echo "$ac_ct_CC" >&6; }
4891else
4892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4893$as_echo "no" >&6; }
4894fi
4895
4896
4897 test -n "$ac_ct_CC" && break
4898done
4899
4900 if test "x$ac_ct_CC" = x; then
4901 CC=""
4902 else
4903 case $cross_compiling:$ac_tool_warned in
4904yes:)
4905{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4906$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4907ac_tool_warned=yes ;;
4908esac
4909 CC=$ac_ct_CC
4910 fi
4911fi
4912
4913fi
4914
4915
4916test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4917$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
4918as_fn_error "no acceptable C compiler found in \$PATH
4919See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
4920
4921# Provide some information about the compiler.
4922$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4923set X $ac_compile
4924ac_compiler=$2
4925for ac_option in --version -v -V -qversion; do
4926 { { ac_try="$ac_compiler $ac_option >&5"
4927case "(($ac_try" in
4928 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4929 *) ac_try_echo=$ac_try;;
4930esac
4931eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4932$as_echo "$ac_try_echo"; } >&5
4933 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4934 ac_status=$?
4935 if test -s conftest.err; then
4936 sed '10a\
4937... rest of stderr output deleted ...
4938 10q' conftest.err >conftest.er1
4939 cat conftest.er1 >&5
4940 fi
4941 rm -f conftest.er1 conftest.err
4942 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4943 test $ac_status = 0; }
4944done
4945
4946cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4947/* end confdefs.h. */
4948
4949int
4950main ()
4951{
4952
4953 ;
4954 return 0;
4955}
4956_ACEOF
4957ac_clean_files_save=$ac_clean_files
4958ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4959# Try to create an executable without -o first, disregard a.out.
4960# It will help us diagnose broken compilers, and finding out an intuition
4961# of exeext.
4962{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4963$as_echo_n "checking whether the C compiler works... " >&6; }
4964ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4965
4966# The possible output files:
4967ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4968
4969ac_rmfiles=
4970for ac_file in $ac_files
4971do
4972 case $ac_file in
4973 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4974 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4975 esac
4976done
4977rm -f $ac_rmfiles
4978
4979if { { ac_try="$ac_link_default"
4980case "(($ac_try" in
4981 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4982 *) ac_try_echo=$ac_try;;
4983esac
4984eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4985$as_echo "$ac_try_echo"; } >&5
4986 (eval "$ac_link_default") 2>&5
4987 ac_status=$?
4988 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4989 test $ac_status = 0; }; then :
4990 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4991# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4992# in a Makefile. We should not override ac_cv_exeext if it was cached,
4993# so that the user can short-circuit this test for compilers unknown to
4994# Autoconf.
4995for ac_file in $ac_files ''
4996do
4997 test -f "$ac_file" || continue
4998 case $ac_file in
4999 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5000 ;;
5001 [ab].out )
5002 # We found the default executable, but exeext='' is most
5003 # certainly right.
5004 break;;
5005 *.* )
5006 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5007 then :; else
5008 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5009 fi
5010 # We set ac_cv_exeext here because the later test for it is not
5011 # safe: cross compilers may not add the suffix if given an `-o'
5012 # argument, so we may need to know it at that point already.
5013 # Even if this section looks crufty: it has the advantage of
5014 # actually working.
5015 break;;
5016 * )
5017 break;;
5018 esac
5019done
5020test "$ac_cv_exeext" = no && ac_cv_exeext=
5021
5022else
5023 ac_file=''
5024fi
5025if test -z "$ac_file"; then :
5026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5027$as_echo "no" >&6; }
5028$as_echo "$as_me: failed program was:" >&5
5029sed 's/^/| /' conftest.$ac_ext >&5
5030
5031{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5032$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
5033{ as_fn_set_status 77
5034as_fn_error "C compiler cannot create executables
5035See \`config.log' for more details." "$LINENO" 5; }; }
067d23c9
KY
5036else
5037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5038$as_echo "yes" >&6; }
5039fi
5040{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5041$as_echo_n "checking for C compiler default output file name... " >&6; }
5042{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5043$as_echo "$ac_file" >&6; }
5044ac_exeext=$ac_cv_exeext
5045
5046rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5047ac_clean_files=$ac_clean_files_save
5048{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5049$as_echo_n "checking for suffix of executables... " >&6; }
5050if { { ac_try="$ac_link"
5051case "(($ac_try" in
5052 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5053 *) ac_try_echo=$ac_try;;
5054esac
5055eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5056$as_echo "$ac_try_echo"; } >&5
5057 (eval "$ac_link") 2>&5
5058 ac_status=$?
5059 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5060 test $ac_status = 0; }; then :
5061 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5062# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5063# work properly (i.e., refer to `conftest.exe'), while it won't with
5064# `rm'.
5065for ac_file in conftest.exe conftest conftest.*; do
5066 test -f "$ac_file" || continue
5067 case $ac_file in
5068 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5069 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5070 break;;
5071 * ) break;;
5072 esac
5073done
5074else
5075 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5076$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
5077as_fn_error "cannot compute suffix of executables: cannot compile and link
5078See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
5079fi
5080rm -f conftest conftest$ac_cv_exeext
5081{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5082$as_echo "$ac_cv_exeext" >&6; }
5083
5084rm -f conftest.$ac_ext
5085EXEEXT=$ac_cv_exeext
5086ac_exeext=$EXEEXT
5087cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5088/* end confdefs.h. */
5089#include <stdio.h>
5090int
5091main ()
5092{
5093FILE *f = fopen ("conftest.out", "w");
5094 return ferror (f) || fclose (f) != 0;
5095
5096 ;
5097 return 0;
5098}
5099_ACEOF
5100ac_clean_files="$ac_clean_files conftest.out"
5101# Check that the compiler produces executables we can run. If not, either
5102# the compiler is broken, or we cross compile.
5103{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5104$as_echo_n "checking whether we are cross compiling... " >&6; }
5105if test "$cross_compiling" != yes; then
5106 { { ac_try="$ac_link"
5107case "(($ac_try" in
5108 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5109 *) ac_try_echo=$ac_try;;
5110esac
5111eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5112$as_echo "$ac_try_echo"; } >&5
5113 (eval "$ac_link") 2>&5
5114 ac_status=$?
5115 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5116 test $ac_status = 0; }
5117 if { ac_try='./conftest$ac_cv_exeext'
5118 { { case "(($ac_try" in
5119 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5120 *) ac_try_echo=$ac_try;;
5121esac
5122eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5123$as_echo "$ac_try_echo"; } >&5
5124 (eval "$ac_try") 2>&5
5125 ac_status=$?
5126 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5127 test $ac_status = 0; }; }; then
5128 cross_compiling=no
5129 else
5130 if test "$cross_compiling" = maybe; then
5131 cross_compiling=yes
5132 else
5133 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5134$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c 5135as_fn_error "cannot run C compiled programs.
067d23c9 5136If you meant to cross compile, use \`--host'.
a9bec17c 5137See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
5138 fi
5139 fi
5140fi
5141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5142$as_echo "$cross_compiling" >&6; }
5143
5144rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5145ac_clean_files=$ac_clean_files_save
5146{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5147$as_echo_n "checking for suffix of object files... " >&6; }
a9bec17c 5148if test "${ac_cv_objext+set}" = set; then :
067d23c9
KY
5149 $as_echo_n "(cached) " >&6
5150else
5151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5152/* end confdefs.h. */
5153
5154int
5155main ()
5156{
5157
5158 ;
5159 return 0;
5160}
5161_ACEOF
5162rm -f conftest.o conftest.obj
5163if { { ac_try="$ac_compile"
5164case "(($ac_try" in
5165 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5166 *) ac_try_echo=$ac_try;;
5167esac
5168eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5169$as_echo "$ac_try_echo"; } >&5
5170 (eval "$ac_compile") 2>&5
5171 ac_status=$?
5172 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5173 test $ac_status = 0; }; then :
5174 for ac_file in conftest.o conftest.obj conftest.*; do
5175 test -f "$ac_file" || continue;
5176 case $ac_file in
5177 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5178 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5179 break;;
5180 esac
5181done
5182else
5183 $as_echo "$as_me: failed program was:" >&5
5184sed 's/^/| /' conftest.$ac_ext >&5
5185
5186{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5187$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
5188as_fn_error "cannot compute suffix of object files: cannot compile
5189See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
5190fi
5191rm -f conftest.$ac_cv_objext conftest.$ac_ext
5192fi
5193{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5194$as_echo "$ac_cv_objext" >&6; }
5195OBJEXT=$ac_cv_objext
5196ac_objext=$OBJEXT
5197{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5198$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
a9bec17c 5199if test "${ac_cv_c_compiler_gnu+set}" = set; then :
067d23c9
KY
5200 $as_echo_n "(cached) " >&6
5201else
5202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5203/* end confdefs.h. */
5204
5205int
5206main ()
5207{
5208#ifndef __GNUC__
5209 choke me
5210#endif
5211
5212 ;
5213 return 0;
5214}
5215_ACEOF
5216if ac_fn_c_try_compile "$LINENO"; then :
5217 ac_compiler_gnu=yes
5218else
5219 ac_compiler_gnu=no
5220fi
5221rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5222ac_cv_c_compiler_gnu=$ac_compiler_gnu
5223
5224fi
5225{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5226$as_echo "$ac_cv_c_compiler_gnu" >&6; }
5227if test $ac_compiler_gnu = yes; then
5228 GCC=yes
5229else
5230 GCC=
5231fi
5232ac_test_CFLAGS=${CFLAGS+set}
5233ac_save_CFLAGS=$CFLAGS
5234{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5235$as_echo_n "checking whether $CC accepts -g... " >&6; }
a9bec17c 5236if test "${ac_cv_prog_cc_g+set}" = set; then :
067d23c9
KY
5237 $as_echo_n "(cached) " >&6
5238else
5239 ac_save_c_werror_flag=$ac_c_werror_flag
5240 ac_c_werror_flag=yes
5241 ac_cv_prog_cc_g=no
5242 CFLAGS="-g"
5243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5244/* end confdefs.h. */
5245
5246int
5247main ()
5248{
5249
5250 ;
5251 return 0;
5252}
5253_ACEOF
5254if ac_fn_c_try_compile "$LINENO"; then :
5255 ac_cv_prog_cc_g=yes
5256else
5257 CFLAGS=""
5258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5259/* end confdefs.h. */
5260
5261int
5262main ()
5263{
5264
5265 ;
5266 return 0;
5267}
5268_ACEOF
5269if ac_fn_c_try_compile "$LINENO"; then :
5270
5271else
5272 ac_c_werror_flag=$ac_save_c_werror_flag
5273 CFLAGS="-g"
5274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5275/* end confdefs.h. */
5276
5277int
5278main ()
5279{
5280
5281 ;
5282 return 0;
5283}
5284_ACEOF
5285if ac_fn_c_try_compile "$LINENO"; then :
5286 ac_cv_prog_cc_g=yes
5287fi
5288rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5289fi
5290rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5291fi
5292rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5293 ac_c_werror_flag=$ac_save_c_werror_flag
5294fi
5295{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5296$as_echo "$ac_cv_prog_cc_g" >&6; }
5297if test "$ac_test_CFLAGS" = set; then
5298 CFLAGS=$ac_save_CFLAGS
5299elif test $ac_cv_prog_cc_g = yes; then
5300 if test "$GCC" = yes; then
5301 CFLAGS="-g -O2"
5302 else
5303 CFLAGS="-g"
5304 fi
5305else
5306 if test "$GCC" = yes; then
5307 CFLAGS="-O2"
5308 else
5309 CFLAGS=
5310 fi
5311fi
5312{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5313$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
a9bec17c 5314if test "${ac_cv_prog_cc_c89+set}" = set; then :
067d23c9
KY
5315 $as_echo_n "(cached) " >&6
5316else
5317 ac_cv_prog_cc_c89=no
5318ac_save_CC=$CC
5319cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5320/* end confdefs.h. */
5321#include <stdarg.h>
5322#include <stdio.h>
5323#include <sys/types.h>
5324#include <sys/stat.h>
5325/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5326struct buf { int x; };
5327FILE * (*rcsopen) (struct buf *, struct stat *, int);
5328static char *e (p, i)
5329 char **p;
5330 int i;
5331{
5332 return p[i];
5333}
5334static char *f (char * (*g) (char **, int), char **p, ...)
5335{
5336 char *s;
5337 va_list v;
5338 va_start (v,p);
5339 s = g (p, va_arg (v,int));
5340 va_end (v);
5341 return s;
5342}
5343
5344/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5345 function prototypes and stuff, but not '\xHH' hex character constants.
5346 These don't provoke an error unfortunately, instead are silently treated
5347 as 'x'. The following induces an error, until -std is added to get
5348 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5349 array size at least. It's necessary to write '\x00'==0 to get something
5350 that's true only with -std. */
5351int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5352
5353/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5354 inside strings and character constants. */
5355#define FOO(x) 'x'
5356int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5357
5358int test (int i, double x);
5359struct s1 {int (*f) (int a);};
5360struct s2 {int (*f) (double a);};
5361int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5362int argc;
5363char **argv;
5364int
5365main ()
5366{
5367return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5368 ;
5369 return 0;
5370}
5371_ACEOF
5372for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5373 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5374do
5375 CC="$ac_save_CC $ac_arg"
5376 if ac_fn_c_try_compile "$LINENO"; then :
5377 ac_cv_prog_cc_c89=$ac_arg
5378fi
5379rm -f core conftest.err conftest.$ac_objext
5380 test "x$ac_cv_prog_cc_c89" != "xno" && break
5381done
743c80a7
PE
5382rm -f conftest.$ac_ext
5383CC=$ac_save_CC
5384
5385fi
5386# AC_CACHE_VAL
5387case "x$ac_cv_prog_cc_c89" in
5388 x)
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5390$as_echo "none needed" >&6; } ;;
5391 xno)
5392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5393$as_echo "unsupported" >&6; } ;;
5394 *)
5395 CC="$CC $ac_cv_prog_cc_c89"
5396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5397$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5398esac
5399if test "x$ac_cv_prog_cc_c89" != xno; then :
5400
5401fi
5402
5403ac_ext=c
5404ac_cpp='$CPP $CPPFLAGS'
5405ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5406ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5407ac_compiler_gnu=$ac_cv_c_compiler_gnu
5408DEPDIR="${am__leading_dot}deps"
5409
5410ac_config_commands="$ac_config_commands depfiles"
5411
5412
5413am_make=${MAKE-make}
5414cat > confinc << 'END'
5415am__doit:
5416 @echo this is the am__doit target
5417.PHONY: am__doit
5418END
5419# If we don't find an include directive, just comment out the code.
5420{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5421$as_echo_n "checking for style of include used by $am_make... " >&6; }
5422am__include="#"
5423am__quote=
5424_am_result=none
5425# First try GNU make style include.
5426echo "include confinc" > confmf
5427# Ignore all kinds of additional output from `make'.
5428case `$am_make -s -f confmf 2> /dev/null` in #(
5429*the\ am__doit\ target*)
5430 am__include=include
5431 am__quote=
5432 _am_result=GNU
5433 ;;
5434esac
5435# Now try BSD make style include.
5436if test "$am__include" = "#"; then
5437 echo '.include "confinc"' > confmf
5438 case `$am_make -s -f confmf 2> /dev/null` in #(
5439 *the\ am__doit\ target*)
5440 am__include=.include
5441 am__quote="\""
5442 _am_result=BSD
5443 ;;
5444 esac
5445fi
5446
5447
5448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5449$as_echo "$_am_result" >&6; }
5450rm -f confinc confmf
5451
5452# Check whether --enable-dependency-tracking was given.
5453if test "${enable_dependency_tracking+set}" = set; then :
5454 enableval=$enable_dependency_tracking;
5455fi
5456
5457if test "x$enable_dependency_tracking" != xno; then
5458 am_depcomp="$ac_aux_dir/depcomp"
5459 AMDEPBACKSLASH='\'
5460fi
5461 if test "x$enable_dependency_tracking" != xno; then
5462 AMDEP_TRUE=
5463 AMDEP_FALSE='#'
5464else
5465 AMDEP_TRUE='#'
5466 AMDEP_FALSE=
5467fi
5468
5469
5470
5471depcc="$CC" am_compiler_list=
5472
5473{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5474$as_echo_n "checking dependency style of $depcc... " >&6; }
a9bec17c 5475if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
743c80a7
PE
5476 $as_echo_n "(cached) " >&6
5477else
5478 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5479 # We make a subdir and do the tests there. Otherwise we can end up
5480 # making bogus files that we don't know about and never remove. For
5481 # instance it was reported that on HP-UX the gcc test will end up
5482 # making a dummy file named `D' -- because `-MD' means `put the output
5483 # in D'.
5484 mkdir conftest.dir
5485 # Copy depcomp to subdir because otherwise we won't find it if we're
5486 # using a relative directory.
5487 cp "$am_depcomp" conftest.dir
5488 cd conftest.dir
5489 # We will build objects and dependencies in a subdirectory because
5490 # it helps to detect inapplicable dependency modes. For instance
5491 # both Tru64's cc and ICC support -MD to output dependencies as a
5492 # side effect of compilation, but ICC will put the dependencies in
5493 # the current directory while Tru64 will put them in the object
5494 # directory.
5495 mkdir sub
5496
5497 am_cv_CC_dependencies_compiler_type=none
5498 if test "$am_compiler_list" = ""; then
5499 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5500 fi
5501 am__universal=false
5502 case " $depcc " in #(
5503 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5504 esac
5505
5506 for depmode in $am_compiler_list; do
5507 # Setup a source with many dependencies, because some compilers
5508 # like to wrap large dependency lists on column 80 (with \), and
5509 # we should not choose a depcomp mode which is confused by this.
5510 #
5511 # We need to recreate these files for each test, as the compiler may
5512 # overwrite some of them when testing with obscure command lines.
5513 # This happens at least with the AIX C compiler.
5514 : > sub/conftest.c
5515 for i in 1 2 3 4 5 6; do
5516 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5517 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5518 # Solaris 8's {/usr,}/bin/sh.
5519 touch sub/conftst$i.h
5520 done
5521 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5522
5523 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5524 # mode. It turns out that the SunPro C++ compiler does not properly
5525 # handle `-M -o', and we need to detect this. Also, some Intel
5526 # versions had trouble with output in subdirs
5527 am__obj=sub/conftest.${OBJEXT-o}
5528 am__minus_obj="-o $am__obj"
5529 case $depmode in
5530 gcc)
5531 # This depmode causes a compiler race in universal mode.
5532 test "$am__universal" = false || continue
5533 ;;
5534 nosideeffect)
5535 # after this tag, mechanisms are not by side-effect, so they'll
5536 # only be used when explicitly requested
5537 if test "x$enable_dependency_tracking" = xyes; then
5538 continue
5539 else
5540 break
5541 fi
5542 ;;
5543 msvisualcpp | msvcmsys)
5544 # This compiler won't grok `-c -o', but also, the minuso test has
5545 # not run yet. These depmodes are late enough in the game, and
5546 # so weak that their functioning should not be impacted.
5547 am__obj=conftest.${OBJEXT-o}
5548 am__minus_obj=
5549 ;;
5550 none) break ;;
5551 esac
5552 if depmode=$depmode \
5553 source=sub/conftest.c object=$am__obj \
5554 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5555 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5556 >/dev/null 2>conftest.err &&
5557 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5558 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5559 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5560 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5561 # icc doesn't choke on unknown options, it will just issue warnings
5562 # or remarks (even with -Werror). So we grep stderr for any message
5563 # that says an option was ignored or not supported.
5564 # When given -MP, icc 7.0 and 7.1 complain thusly:
5565 # icc: Command line warning: ignoring option '-M'; no argument required
5566 # The diagnosis changed in icc 8.0:
5567 # icc: Command line remark: option '-MP' not supported
5568 if (grep 'ignoring option' conftest.err ||
5569 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5570 am_cv_CC_dependencies_compiler_type=$depmode
5571 break
5572 fi
5573 fi
5574 done
5575
5576 cd ..
5577 rm -rf conftest.dir
5578else
5579 am_cv_CC_dependencies_compiler_type=none
5580fi
5581
5582fi
5583{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5584$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5585CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5586
5587 if
5588 test "x$enable_dependency_tracking" != xno \
5589 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5590 am__fastdepCC_TRUE=
5591 am__fastdepCC_FALSE='#'
5592else
5593 am__fastdepCC_TRUE='#'
5594 am__fastdepCC_FALSE=
5595fi
5596
5597
5598if test "x$CC" != xcc; then
5599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5600$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5601else
5602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5603$as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5604fi
5605set dummy $CC; ac_cc=`$as_echo "$2" |
5606 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
a9bec17c 5607if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
743c80a7
PE
5608 $as_echo_n "(cached) " >&6
5609else
5610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5611/* end confdefs.h. */
5612
5613int
5614main ()
5615{
5616
5617 ;
5618 return 0;
5619}
5620_ACEOF
5621# Make sure it works both with $CC and with simple cc.
5622# We do the test twice because some compilers refuse to overwrite an
5623# existing .o file with -o, though they will create one.
5624ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5625rm -f conftest2.*
5626if { { case "(($ac_try" in
5627 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5628 *) ac_try_echo=$ac_try;;
5629esac
5630eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5631$as_echo "$ac_try_echo"; } >&5
5632 (eval "$ac_try") 2>&5
5633 ac_status=$?
5634 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5635 test $ac_status = 0; } &&
5636 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5637 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5638 *) ac_try_echo=$ac_try;;
5639esac
5640eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5641$as_echo "$ac_try_echo"; } >&5
5642 (eval "$ac_try") 2>&5
5643 ac_status=$?
5644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5645 test $ac_status = 0; };
5646then
5647 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5648 if test "x$CC" != xcc; then
5649 # Test first that cc exists at all.
5650 if { ac_try='cc -c conftest.$ac_ext >&5'
5651 { { case "(($ac_try" in
5652 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5653 *) ac_try_echo=$ac_try;;
5654esac
5655eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5656$as_echo "$ac_try_echo"; } >&5
5657 (eval "$ac_try") 2>&5
5658 ac_status=$?
5659 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5660 test $ac_status = 0; }; }; then
5661 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5662 rm -f conftest2.*
5663 if { { case "(($ac_try" in
5664 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5665 *) ac_try_echo=$ac_try;;
5666esac
5667eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5668$as_echo "$ac_try_echo"; } >&5
5669 (eval "$ac_try") 2>&5
5670 ac_status=$?
5671 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5672 test $ac_status = 0; } &&
5673 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5674 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5675 *) ac_try_echo=$ac_try;;
5676esac
5677eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5678$as_echo "$ac_try_echo"; } >&5
5679 (eval "$ac_try") 2>&5
5680 ac_status=$?
5681 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5682 test $ac_status = 0; };
5683 then
5684 # cc works too.
5685 :
5686 else
5687 # cc exists but doesn't like -o.
5688 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5689 fi
5690 fi
5691 fi
5692else
5693 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5694fi
5695rm -f core conftest*
5696
5697fi
5698if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5700$as_echo "yes" >&6; }
5701else
5702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5703$as_echo "no" >&6; }
5704
5705$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5706
5707fi
5708
5709# FIXME: we rely on the cache variable name because
5710# there is no other way.
5711set dummy $CC
5712am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5713eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5714if test "$am_t" != yes; then
5715 # Losing compiler, so override with the script.
5716 # FIXME: It is wrong to rewrite CC.
5717 # But if we don't then we get into trouble of one sort or another.
5718 # A longer-term fix would be to have automake use am__CC in this case,
5719 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5720 CC="$am_aux_dir/compile $CC"
5721fi
5722
5723
5724
5725# Initialize gnulib right after verifying that the C compiler works.
743c80a7 5726
067d23c9
KY
5727ac_ext=c
5728ac_cpp='$CPP $CPPFLAGS'
5729ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5730ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5731ac_compiler_gnu=$ac_cv_c_compiler_gnu
5732{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5733$as_echo_n "checking how to run the C preprocessor... " >&6; }
5734# On Suns, sometimes $CPP names a directory.
5735if test -n "$CPP" && test -d "$CPP"; then
5736 CPP=
5737fi
5738if test -z "$CPP"; then
a9bec17c 5739 if test "${ac_cv_prog_CPP+set}" = set; then :
067d23c9
KY
5740 $as_echo_n "(cached) " >&6
5741else
5742 # Double quotes because CPP needs to be expanded
5743 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5744 do
5745 ac_preproc_ok=false
5746for ac_c_preproc_warn_flag in '' yes
5747do
5748 # Use a header file that comes with gcc, so configuring glibc
5749 # with a fresh cross-compiler works.
5750 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5751 # <limits.h> exists even on freestanding compilers.
5752 # On the NeXT, cc -E runs the code through the compiler's parser,
5753 # not just through cpp. "Syntax error" is here to catch this case.
5754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5755/* end confdefs.h. */
5756#ifdef __STDC__
5757# include <limits.h>
5758#else
5759# include <assert.h>
5760#endif
5761 Syntax error
5762_ACEOF
5763if ac_fn_c_try_cpp "$LINENO"; then :
5764
5765else
5766 # Broken: fails on valid input.
5767continue
5768fi
a9bec17c 5769rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5770
5771 # OK, works on sane cases. Now check whether nonexistent headers
5772 # can be detected and how.
5773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5774/* end confdefs.h. */
5775#include <ac_nonexistent.h>
5776_ACEOF
5777if ac_fn_c_try_cpp "$LINENO"; then :
5778 # Broken: success on invalid input.
5779continue
5780else
5781 # Passes both tests.
5782ac_preproc_ok=:
5783break
5784fi
a9bec17c 5785rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5786
5787done
5788# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
a9bec17c 5789rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5790if $ac_preproc_ok; then :
5791 break
5792fi
5793
5794 done
5795 ac_cv_prog_CPP=$CPP
5796
5797fi
5798 CPP=$ac_cv_prog_CPP
5799else
5800 ac_cv_prog_CPP=$CPP
5801fi
5802{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5803$as_echo "$CPP" >&6; }
5804ac_preproc_ok=false
5805for ac_c_preproc_warn_flag in '' yes
5806do
5807 # Use a header file that comes with gcc, so configuring glibc
5808 # with a fresh cross-compiler works.
5809 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5810 # <limits.h> exists even on freestanding compilers.
5811 # On the NeXT, cc -E runs the code through the compiler's parser,
5812 # not just through cpp. "Syntax error" is here to catch this case.
5813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5814/* end confdefs.h. */
5815#ifdef __STDC__
5816# include <limits.h>
5817#else
5818# include <assert.h>
5819#endif
5820 Syntax error
5821_ACEOF
5822if ac_fn_c_try_cpp "$LINENO"; then :
5823
5824else
5825 # Broken: fails on valid input.
5826continue
5827fi
a9bec17c 5828rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5829
5830 # OK, works on sane cases. Now check whether nonexistent headers
5831 # can be detected and how.
5832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5833/* end confdefs.h. */
5834#include <ac_nonexistent.h>
5835_ACEOF
5836if ac_fn_c_try_cpp "$LINENO"; then :
5837 # Broken: success on invalid input.
5838continue
5839else
5840 # Passes both tests.
5841ac_preproc_ok=:
5842break
5843fi
a9bec17c 5844rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5845
5846done
5847# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
a9bec17c 5848rm -f conftest.err conftest.$ac_ext
067d23c9
KY
5849if $ac_preproc_ok; then :
5850
5851else
5852 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5853$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
5854as_fn_error "C preprocessor \"$CPP\" fails sanity check
5855See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
5856fi
5857
5858ac_ext=c
5859ac_cpp='$CPP $CPPFLAGS'
5860ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5861ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5862ac_compiler_gnu=$ac_cv_c_compiler_gnu
5863
5864
5865{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5866$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
a9bec17c 5867if test "${ac_cv_path_GREP+set}" = set; then :
067d23c9
KY
5868 $as_echo_n "(cached) " >&6
5869else
5870 if test -z "$GREP"; then
5871 ac_path_GREP_found=false
5872 # Loop through the user's path and test for each of PROGNAME-LIST
5873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5874for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5875do
5876 IFS=$as_save_IFS
5877 test -z "$as_dir" && as_dir=.
5878 for ac_prog in grep ggrep; do
5879 for ac_exec_ext in '' $ac_executable_extensions; do
5880 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5881 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5882# Check for GNU ac_path_GREP and select it if it is found.
5883 # Check for GNU $ac_path_GREP
5884case `"$ac_path_GREP" --version 2>&1` in
5885*GNU*)
5886 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5887*)
5888 ac_count=0
5889 $as_echo_n 0123456789 >"conftest.in"
5890 while :
5891 do
5892 cat "conftest.in" "conftest.in" >"conftest.tmp"
5893 mv "conftest.tmp" "conftest.in"
5894 cp "conftest.in" "conftest.nl"
5895 $as_echo 'GREP' >> "conftest.nl"
5896 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5897 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5898 as_fn_arith $ac_count + 1 && ac_count=$as_val
5899 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5900 # Best one so far, save it but keep looking for a better one
5901 ac_cv_path_GREP="$ac_path_GREP"
5902 ac_path_GREP_max=$ac_count
5903 fi
5904 # 10*(2^10) chars as input seems more than enough
5905 test $ac_count -gt 10 && break
5906 done
5907 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5908esac
5909
5910 $ac_path_GREP_found && break 3
5911 done
5912 done
5913 done
5914IFS=$as_save_IFS
5915 if test -z "$ac_cv_path_GREP"; then
a9bec17c 5916 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
067d23c9
KY
5917 fi
5918else
5919 ac_cv_path_GREP=$GREP
5920fi
5921
5922fi
5923{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5924$as_echo "$ac_cv_path_GREP" >&6; }
5925 GREP="$ac_cv_path_GREP"
5926
5927
5928{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5929$as_echo_n "checking for egrep... " >&6; }
a9bec17c 5930if test "${ac_cv_path_EGREP+set}" = set; then :
067d23c9
KY
5931 $as_echo_n "(cached) " >&6
5932else
5933 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5934 then ac_cv_path_EGREP="$GREP -E"
5935 else
5936 if test -z "$EGREP"; then
5937 ac_path_EGREP_found=false
5938 # Loop through the user's path and test for each of PROGNAME-LIST
5939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5940for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5941do
5942 IFS=$as_save_IFS
5943 test -z "$as_dir" && as_dir=.
5944 for ac_prog in egrep; do
5945 for ac_exec_ext in '' $ac_executable_extensions; do
5946 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5947 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5948# Check for GNU ac_path_EGREP and select it if it is found.
5949 # Check for GNU $ac_path_EGREP
5950case `"$ac_path_EGREP" --version 2>&1` in
5951*GNU*)
5952 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5953*)
5954 ac_count=0
5955 $as_echo_n 0123456789 >"conftest.in"
5956 while :
5957 do
5958 cat "conftest.in" "conftest.in" >"conftest.tmp"
5959 mv "conftest.tmp" "conftest.in"
5960 cp "conftest.in" "conftest.nl"
5961 $as_echo 'EGREP' >> "conftest.nl"
5962 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5963 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5964 as_fn_arith $ac_count + 1 && ac_count=$as_val
5965 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5966 # Best one so far, save it but keep looking for a better one
5967 ac_cv_path_EGREP="$ac_path_EGREP"
5968 ac_path_EGREP_max=$ac_count
5969 fi
5970 # 10*(2^10) chars as input seems more than enough
5971 test $ac_count -gt 10 && break
5972 done
5973 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5974esac
5975
5976 $ac_path_EGREP_found && break 3
5977 done
5978 done
5979 done
5980IFS=$as_save_IFS
5981 if test -z "$ac_cv_path_EGREP"; then
a9bec17c 5982 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
067d23c9
KY
5983 fi
5984else
5985 ac_cv_path_EGREP=$EGREP
5986fi
5987
5988 fi
5989fi
5990{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5991$as_echo "$ac_cv_path_EGREP" >&6; }
5992 EGREP="$ac_cv_path_EGREP"
5993
5994
369e19fc
PE
5995
5996
5997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5998$as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
a9bec17c 5999if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
369e19fc
PE
6000 $as_echo_n "(cached) " >&6
6001else
6002
6003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6004/* end confdefs.h. */
6005
6006#ifdef __ACK__
6007Amsterdam
6008#endif
6009
6010_ACEOF
6011if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6012 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6013 gl_cv_c_amsterdam_compiler=yes
6014else
6015 gl_cv_c_amsterdam_compiler=no
6016fi
6017rm -f conftest*
6018
6019
6020fi
6021{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6022$as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6023 if test -z "$AR"; then
6024 if test $gl_cv_c_amsterdam_compiler = yes; then
6025 AR='cc -c.a'
6026 if test -z "$ARFLAGS"; then
6027 ARFLAGS='-o'
6028 fi
6029 else
6030 if test -n "$ac_tool_prefix"; then
6031 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6032set dummy ${ac_tool_prefix}ar; ac_word=$2
6033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6034$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 6035if test "${ac_cv_prog_AR+set}" = set; then :
369e19fc
PE
6036 $as_echo_n "(cached) " >&6
6037else
6038 if test -n "$AR"; then
6039 ac_cv_prog_AR="$AR" # Let the user override the test.
6040else
6041as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6042for as_dir in $PATH
6043do
6044 IFS=$as_save_IFS
6045 test -z "$as_dir" && as_dir=.
6046 for ac_exec_ext in '' $ac_executable_extensions; do
6047 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6048 ac_cv_prog_AR="${ac_tool_prefix}ar"
6049 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6050 break 2
6051 fi
6052done
6053 done
6054IFS=$as_save_IFS
6055
6056fi
6057fi
6058AR=$ac_cv_prog_AR
6059if test -n "$AR"; then
6060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6061$as_echo "$AR" >&6; }
6062else
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6064$as_echo "no" >&6; }
6065fi
6066
6067
6068fi
6069if test -z "$ac_cv_prog_AR"; then
6070 ac_ct_AR=$AR
6071 # Extract the first word of "ar", so it can be a program name with args.
6072set dummy ar; ac_word=$2
6073{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6074$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 6075if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
369e19fc
PE
6076 $as_echo_n "(cached) " >&6
6077else
6078 if test -n "$ac_ct_AR"; then
6079 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6080else
6081as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6082for as_dir in $PATH
6083do
6084 IFS=$as_save_IFS
6085 test -z "$as_dir" && as_dir=.
6086 for ac_exec_ext in '' $ac_executable_extensions; do
6087 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6088 ac_cv_prog_ac_ct_AR="ar"
6089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6090 break 2
6091 fi
6092done
6093 done
6094IFS=$as_save_IFS
6095
6096fi
6097fi
6098ac_ct_AR=$ac_cv_prog_ac_ct_AR
6099if test -n "$ac_ct_AR"; then
6100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6101$as_echo "$ac_ct_AR" >&6; }
6102else
6103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6104$as_echo "no" >&6; }
6105fi
6106
6107 if test "x$ac_ct_AR" = x; then
6108 AR="ar"
6109 else
6110 case $cross_compiling:$ac_tool_warned in
6111yes:)
6112{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6113$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6114ac_tool_warned=yes ;;
6115esac
6116 AR=$ac_ct_AR
6117 fi
6118else
6119 AR="$ac_cv_prog_AR"
6120fi
6121
6122 if test -z "$ARFLAGS"; then
6123 ARFLAGS='cru'
6124 fi
6125 fi
6126 else
6127 if test -z "$ARFLAGS"; then
6128 ARFLAGS='cru'
6129 fi
6130 fi
6131
6132
6133 if test -z "$RANLIB"; then
6134 if test $gl_cv_c_amsterdam_compiler = yes; then
6135 RANLIB=':'
6136 else
6137 if test -n "$ac_tool_prefix"; then
6138 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6139set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6141$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 6142if test "${ac_cv_prog_RANLIB+set}" = set; then :
369e19fc
PE
6143 $as_echo_n "(cached) " >&6
6144else
6145 if test -n "$RANLIB"; then
6146 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6147else
6148as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6149for as_dir in $PATH
6150do
6151 IFS=$as_save_IFS
6152 test -z "$as_dir" && as_dir=.
6153 for ac_exec_ext in '' $ac_executable_extensions; do
6154 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6155 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6157 break 2
6158 fi
6159done
6160 done
6161IFS=$as_save_IFS
6162
6163fi
6164fi
6165RANLIB=$ac_cv_prog_RANLIB
6166if test -n "$RANLIB"; then
6167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6168$as_echo "$RANLIB" >&6; }
6169else
6170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6171$as_echo "no" >&6; }
6172fi
6173
6174
6175fi
6176if test -z "$ac_cv_prog_RANLIB"; then
6177 ac_ct_RANLIB=$RANLIB
6178 # Extract the first word of "ranlib", so it can be a program name with args.
6179set dummy ranlib; ac_word=$2
6180{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6181$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 6182if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
369e19fc
PE
6183 $as_echo_n "(cached) " >&6
6184else
6185 if test -n "$ac_ct_RANLIB"; then
6186 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6187else
6188as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6189for as_dir in $PATH
6190do
6191 IFS=$as_save_IFS
6192 test -z "$as_dir" && as_dir=.
6193 for ac_exec_ext in '' $ac_executable_extensions; do
6194 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6195 ac_cv_prog_ac_ct_RANLIB="ranlib"
6196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6197 break 2
6198 fi
6199done
6200 done
6201IFS=$as_save_IFS
6202
6203fi
6204fi
6205ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6206if test -n "$ac_ct_RANLIB"; then
6207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6208$as_echo "$ac_ct_RANLIB" >&6; }
6209else
6210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6211$as_echo "no" >&6; }
6212fi
6213
6214 if test "x$ac_ct_RANLIB" = x; then
6215 RANLIB=":"
6216 else
6217 case $cross_compiling:$ac_tool_warned in
6218yes:)
6219{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6220$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6221ac_tool_warned=yes ;;
6222esac
6223 RANLIB=$ac_ct_RANLIB
6224 fi
6225else
6226 RANLIB="$ac_cv_prog_RANLIB"
6227fi
6228
6229 fi
6230 fi
6231
6232
067d23c9
KY
6233{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6234$as_echo_n "checking for ANSI C header files... " >&6; }
a9bec17c 6235if test "${ac_cv_header_stdc+set}" = set; then :
067d23c9
KY
6236 $as_echo_n "(cached) " >&6
6237else
6238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6239/* end confdefs.h. */
6240#include <stdlib.h>
6241#include <stdarg.h>
6242#include <string.h>
6243#include <float.h>
6244
6245int
6246main ()
6247{
6248
6249 ;
6250 return 0;
6251}
6252_ACEOF
6253if ac_fn_c_try_compile "$LINENO"; then :
6254 ac_cv_header_stdc=yes
6255else
6256 ac_cv_header_stdc=no
6257fi
6258rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6259
6260if test $ac_cv_header_stdc = yes; then
6261 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6263/* end confdefs.h. */
6264#include <string.h>
6265
6266_ACEOF
6267if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6268 $EGREP "memchr" >/dev/null 2>&1; then :
6269
6270else
6271 ac_cv_header_stdc=no
6272fi
6273rm -f conftest*
6274
6275fi
6276
6277if test $ac_cv_header_stdc = yes; then
6278 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6280/* end confdefs.h. */
6281#include <stdlib.h>
6282
6283_ACEOF
6284if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6285 $EGREP "free" >/dev/null 2>&1; then :
6286
6287else
6288 ac_cv_header_stdc=no
6289fi
6290rm -f conftest*
6291
6292fi
6293
6294if test $ac_cv_header_stdc = yes; then
6295 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6296 if test "$cross_compiling" = yes; then :
6297 :
6298else
6299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6300/* end confdefs.h. */
6301#include <ctype.h>
6302#include <stdlib.h>
6303#if ((' ' & 0x0FF) == 0x020)
6304# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6305# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6306#else
6307# define ISLOWER(c) \
6308 (('a' <= (c) && (c) <= 'i') \
6309 || ('j' <= (c) && (c) <= 'r') \
6310 || ('s' <= (c) && (c) <= 'z'))
6311# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6312#endif
6313
6314#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6315int
6316main ()
6317{
6318 int i;
6319 for (i = 0; i < 256; i++)
6320 if (XOR (islower (i), ISLOWER (i))
6321 || toupper (i) != TOUPPER (i))
6322 return 2;
6323 return 0;
6324}
6325_ACEOF
6326if ac_fn_c_try_run "$LINENO"; then :
6327
6328else
6329 ac_cv_header_stdc=no
6330fi
6331rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6332 conftest.$ac_objext conftest.beam conftest.$ac_ext
6333fi
6334
6335fi
6336fi
6337{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6338$as_echo "$ac_cv_header_stdc" >&6; }
6339if test $ac_cv_header_stdc = yes; then
6340
6341$as_echo "#define STDC_HEADERS 1" >>confdefs.h
6342
6343fi
6344
6345# On IRIX 5.3, sys/types and inttypes.h are conflicting.
6346for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6347 inttypes.h stdint.h unistd.h
6348do :
6349 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6350ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6351"
a9bec17c
GM
6352eval as_val=\$$as_ac_Header
6353 if test "x$as_val" = x""yes; then :
067d23c9
KY
6354 cat >>confdefs.h <<_ACEOF
6355#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6356_ACEOF
6357
6358fi
6359
6360done
6361
6362
6363
1fd182f0
PE
6364
6365
067d23c9 6366 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
a9bec17c 6367if test "x$ac_cv_header_minix_config_h" = x""yes; then :
067d23c9
KY
6368 MINIX=yes
6369else
6370 MINIX=
6371fi
6372
6373
6374 if test "$MINIX" = yes; then
6375
6376$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6377
6378
6379$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6380
6381
6382$as_echo "#define _MINIX 1" >>confdefs.h
6383
6384 fi
6385
1fd182f0
PE
6386 case "$host_os" in
6387 hpux*)
6388
6389$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6390
6391 ;;
6392 esac
6393
067d23c9
KY
6394
6395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6396$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
a9bec17c 6397if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
067d23c9
KY
6398 $as_echo_n "(cached) " >&6
6399else
6400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6401/* end confdefs.h. */
369e19fc
PE
6402
6403# define __EXTENSIONS__ 1
6404 $ac_includes_default
6405int
6406main ()
6407{
6408
6409 ;
6410 return 0;
6411}
6412_ACEOF
6413if ac_fn_c_try_compile "$LINENO"; then :
6414 ac_cv_safe_to_define___extensions__=yes
6415else
6416 ac_cv_safe_to_define___extensions__=no
6417fi
6418rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6419fi
6420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6421$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6422 test $ac_cv_safe_to_define___extensions__ = yes &&
6423 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6424
6425 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6426
6427 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6428
6429 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6430
6431 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6432
6433 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6434
6435
6436
6437
6438
6439
6440
6441
6442# Check whether --enable-largefile was given.
6443if test "${enable_largefile+set}" = set; then :
6444 enableval=$enable_largefile;
6445fi
6446
6447if test "$enable_largefile" != no; then
6448
6449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6450$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
a9bec17c 6451if test "${ac_cv_sys_largefile_CC+set}" = set; then :
369e19fc
PE
6452 $as_echo_n "(cached) " >&6
6453else
6454 ac_cv_sys_largefile_CC=no
6455 if test "$GCC" != yes; then
6456 ac_save_CC=$CC
6457 while :; do
6458 # IRIX 6.2 and later do not support large files by default,
6459 # so use the C compiler's -n32 option if that helps.
6460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6461/* end confdefs.h. */
6462#include <sys/types.h>
6463 /* Check that off_t can represent 2**63 - 1 correctly.
6464 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6465 since some C++ compilers masquerading as C compilers
6466 incorrectly reject 9223372036854775807. */
6467#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6468 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6469 && LARGE_OFF_T % 2147483647 == 1)
6470 ? 1 : -1];
6471int
6472main ()
6473{
6474
6475 ;
6476 return 0;
6477}
6478_ACEOF
6479 if ac_fn_c_try_compile "$LINENO"; then :
6480 break
6481fi
6482rm -f core conftest.err conftest.$ac_objext
6483 CC="$CC -n32"
6484 if ac_fn_c_try_compile "$LINENO"; then :
6485 ac_cv_sys_largefile_CC=' -n32'; break
6486fi
6487rm -f core conftest.err conftest.$ac_objext
6488 break
6489 done
6490 CC=$ac_save_CC
6491 rm -f conftest.$ac_ext
6492 fi
6493fi
6494{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6495$as_echo "$ac_cv_sys_largefile_CC" >&6; }
6496 if test "$ac_cv_sys_largefile_CC" != no; then
6497 CC=$CC$ac_cv_sys_largefile_CC
6498 fi
6499
6500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6501$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
a9bec17c 6502if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
369e19fc
PE
6503 $as_echo_n "(cached) " >&6
6504else
6505 while :; do
6506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6507/* end confdefs.h. */
6508#include <sys/types.h>
6509 /* Check that off_t can represent 2**63 - 1 correctly.
6510 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6511 since some C++ compilers masquerading as C compilers
6512 incorrectly reject 9223372036854775807. */
6513#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6514 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6515 && LARGE_OFF_T % 2147483647 == 1)
6516 ? 1 : -1];
6517int
6518main ()
6519{
6520
6521 ;
6522 return 0;
6523}
6524_ACEOF
6525if ac_fn_c_try_compile "$LINENO"; then :
6526 ac_cv_sys_file_offset_bits=no; break
6527fi
6528rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6530/* end confdefs.h. */
6531#define _FILE_OFFSET_BITS 64
6532#include <sys/types.h>
6533 /* Check that off_t can represent 2**63 - 1 correctly.
6534 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6535 since some C++ compilers masquerading as C compilers
6536 incorrectly reject 9223372036854775807. */
6537#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6538 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6539 && LARGE_OFF_T % 2147483647 == 1)
6540 ? 1 : -1];
6541int
6542main ()
6543{
6544
6545 ;
6546 return 0;
6547}
6548_ACEOF
6549if ac_fn_c_try_compile "$LINENO"; then :
6550 ac_cv_sys_file_offset_bits=64; break
6551fi
6552rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6553 ac_cv_sys_file_offset_bits=unknown
6554 break
6555done
6556fi
6557{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6558$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6559case $ac_cv_sys_file_offset_bits in #(
6560 no | unknown) ;;
6561 *)
6562cat >>confdefs.h <<_ACEOF
6563#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6564_ACEOF
6565;;
6566esac
6567rm -rf conftest*
6568 if test $ac_cv_sys_file_offset_bits = unknown; then
6569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6570$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
a9bec17c 6571if test "${ac_cv_sys_large_files+set}" = set; then :
369e19fc
PE
6572 $as_echo_n "(cached) " >&6
6573else
6574 while :; do
6575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6576/* end confdefs.h. */
6577#include <sys/types.h>
6578 /* Check that off_t can represent 2**63 - 1 correctly.
6579 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6580 since some C++ compilers masquerading as C compilers
6581 incorrectly reject 9223372036854775807. */
6582#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6583 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6584 && LARGE_OFF_T % 2147483647 == 1)
6585 ? 1 : -1];
6586int
6587main ()
6588{
6589
6590 ;
6591 return 0;
6592}
6593_ACEOF
6594if ac_fn_c_try_compile "$LINENO"; then :
6595 ac_cv_sys_large_files=no; break
6596fi
6597rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6599/* end confdefs.h. */
6600#define _LARGE_FILES 1
6601#include <sys/types.h>
6602 /* Check that off_t can represent 2**63 - 1 correctly.
6603 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6604 since some C++ compilers masquerading as C compilers
6605 incorrectly reject 9223372036854775807. */
6606#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6607 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6608 && LARGE_OFF_T % 2147483647 == 1)
6609 ? 1 : -1];
067d23c9
KY
6610int
6611main ()
6612{
6613
6614 ;
6615 return 0;
6616}
6617_ACEOF
6618if ac_fn_c_try_compile "$LINENO"; then :
369e19fc 6619 ac_cv_sys_large_files=1; break
067d23c9
KY
6620fi
6621rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
369e19fc
PE
6622 ac_cv_sys_large_files=unknown
6623 break
6624done
067d23c9 6625fi
369e19fc
PE
6626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6627$as_echo "$ac_cv_sys_large_files" >&6; }
6628case $ac_cv_sys_large_files in #(
6629 no | unknown) ;;
6630 *)
6631cat >>confdefs.h <<_ACEOF
6632#define _LARGE_FILES $ac_cv_sys_large_files
6633_ACEOF
6634;;
6635esac
6636rm -rf conftest*
6637 fi
1fd182f0
PE
6638
6639
369e19fc 6640fi
1fd182f0 6641
6d153f56
GM
6642 case $ac_cv_prog_cc_stdc in #(
6643 no) :
6644 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6645 *) :
6646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6647$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
a9bec17c 6648if test "${ac_cv_prog_cc_c99+set}" = set; then :
6d153f56
GM
6649 $as_echo_n "(cached) " >&6
6650else
6651 ac_cv_prog_cc_c99=no
6652ac_save_CC=$CC
6653cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6654/* end confdefs.h. */
6655#include <stdarg.h>
6656#include <stdbool.h>
6657#include <stdlib.h>
6658#include <wchar.h>
6659#include <stdio.h>
6660
6661// Check varargs macros. These examples are taken from C99 6.10.3.5.
6662#define debug(...) fprintf (stderr, __VA_ARGS__)
6663#define showlist(...) puts (#__VA_ARGS__)
6664#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6665static void
6666test_varargs_macros (void)
6667{
6668 int x = 1234;
6669 int y = 5678;
6670 debug ("Flag");
6671 debug ("X = %d\n", x);
6672 showlist (The first, second, and third items.);
6673 report (x>y, "x is %d but y is %d", x, y);
6674}
6675
6676// Check long long types.
6677#define BIG64 18446744073709551615ull
6678#define BIG32 4294967295ul
6679#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6680#if !BIG_OK
6681 your preprocessor is broken;
6682#endif
6683#if BIG_OK
6684#else
6685 your preprocessor is broken;
6686#endif
6687static long long int bignum = -9223372036854775807LL;
6688static unsigned long long int ubignum = BIG64;
6689
6690struct incomplete_array
6691{
6692 int datasize;
6693 double data[];
6694};
6695
6696struct named_init {
6697 int number;
6698 const wchar_t *name;
6699 double average;
6700};
6701
6702typedef const char *ccp;
6703
6704static inline int
6705test_restrict (ccp restrict text)
6706{
6707 // See if C++-style comments work.
6708 // Iterate through items via the restricted pointer.
6709 // Also check for declarations in for loops.
6710 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6711 continue;
6712 return 0;
6713}
6714
6715// Check varargs and va_copy.
6716static void
6717test_varargs (const char *format, ...)
6718{
6719 va_list args;
6720 va_start (args, format);
6721 va_list args_copy;
6722 va_copy (args_copy, args);
6723
6724 const char *str;
6725 int number;
6726 float fnumber;
6727
6728 while (*format)
6729 {
6730 switch (*format++)
6731 {
6732 case 's': // string
6733 str = va_arg (args_copy, const char *);
6734 break;
6735 case 'd': // int
6736 number = va_arg (args_copy, int);
6737 break;
6738 case 'f': // float
6739 fnumber = va_arg (args_copy, double);
6740 break;
6741 default:
6742 break;
6743 }
6744 }
6745 va_end (args_copy);
6746 va_end (args);
6747}
6748
6749int
6750main ()
6751{
6752
6753 // Check bool.
6754 _Bool success = false;
6755
6756 // Check restrict.
6757 if (test_restrict ("String literal") == 0)
6758 success = true;
6759 char *restrict newvar = "Another string";
6760
6761 // Check varargs.
6762 test_varargs ("s, d' f .", "string", 65, 34.234);
6763 test_varargs_macros ();
6764
6765 // Check flexible array members.
6766 struct incomplete_array *ia =
6767 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6768 ia->datasize = 10;
6769 for (int i = 0; i < ia->datasize; ++i)
6770 ia->data[i] = i * 1.234;
6771
6772 // Check named initializers.
6773 struct named_init ni = {
6774 .number = 34,
6775 .name = L"Test wide string",
6776 .average = 543.34343,
6777 };
6778
6779 ni.number = 58;
6780
6781 int dynamic_array[ni.number];
6782 dynamic_array[ni.number - 1] = 543;
6783
6784 // work around unused variable warnings
6785 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6786 || dynamic_array[ni.number - 1] != 543);
6787
6788 ;
6789 return 0;
6790}
6791_ACEOF
6792for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6793do
6794 CC="$ac_save_CC $ac_arg"
6795 if ac_fn_c_try_compile "$LINENO"; then :
6796 ac_cv_prog_cc_c99=$ac_arg
6797fi
6798rm -f core conftest.err conftest.$ac_objext
6799 test "x$ac_cv_prog_cc_c99" != "xno" && break
6800done
6801rm -f conftest.$ac_ext
6802CC=$ac_save_CC
6803
6804fi
6805# AC_CACHE_VAL
6806case "x$ac_cv_prog_cc_c99" in
6807 x)
6808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6809$as_echo "none needed" >&6; } ;;
6810 xno)
6811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6812$as_echo "unsupported" >&6; } ;;
6813 *)
6814 CC="$CC $ac_cv_prog_cc_c99"
6815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6816$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6817esac
6818if test "x$ac_cv_prog_cc_c99" != xno; then :
6819 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6820else
6821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6822$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
a9bec17c 6823if test "${ac_cv_prog_cc_c89+set}" = set; then :
6d153f56
GM
6824 $as_echo_n "(cached) " >&6
6825else
6826 ac_cv_prog_cc_c89=no
6827ac_save_CC=$CC
6828cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6829/* end confdefs.h. */
6830#include <stdarg.h>
6831#include <stdio.h>
6832#include <sys/types.h>
6833#include <sys/stat.h>
6834/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6835struct buf { int x; };
6836FILE * (*rcsopen) (struct buf *, struct stat *, int);
6837static char *e (p, i)
6838 char **p;
6839 int i;
6840{
6841 return p[i];
6842}
6843static char *f (char * (*g) (char **, int), char **p, ...)
6844{
6845 char *s;
6846 va_list v;
6847 va_start (v,p);
6848 s = g (p, va_arg (v,int));
6849 va_end (v);
6850 return s;
6851}
6852
6853/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6854 function prototypes and stuff, but not '\xHH' hex character constants.
6855 These don't provoke an error unfortunately, instead are silently treated
6856 as 'x'. The following induces an error, until -std is added to get
6857 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6858 array size at least. It's necessary to write '\x00'==0 to get something
6859 that's true only with -std. */
6860int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6861
6862/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6863 inside strings and character constants. */
6864#define FOO(x) 'x'
6865int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6866
6867int test (int i, double x);
6868struct s1 {int (*f) (int a);};
6869struct s2 {int (*f) (double a);};
6870int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6871int argc;
6872char **argv;
6873int
6874main ()
6875{
6876return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6877 ;
6878 return 0;
6879}
6880_ACEOF
6881for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6882 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6883do
6884 CC="$ac_save_CC $ac_arg"
6885 if ac_fn_c_try_compile "$LINENO"; then :
6886 ac_cv_prog_cc_c89=$ac_arg
6887fi
6888rm -f core conftest.err conftest.$ac_objext
6889 test "x$ac_cv_prog_cc_c89" != "xno" && break
6890done
6891rm -f conftest.$ac_ext
6892CC=$ac_save_CC
6893
6894fi
6895# AC_CACHE_VAL
6896case "x$ac_cv_prog_cc_c89" in
6897 x)
6898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6899$as_echo "none needed" >&6; } ;;
6900 xno)
6901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6902$as_echo "unsupported" >&6; } ;;
6903 *)
6904 CC="$CC $ac_cv_prog_cc_c89"
6905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6906$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6907esac
6908if test "x$ac_cv_prog_cc_c89" != xno; then :
6909 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6910else
6911 ac_cv_prog_cc_stdc=no
6912fi
6913
6914fi
6915 ;;
6916esac
6917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6918$as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
a9bec17c 6919 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6d153f56
GM
6920 $as_echo_n "(cached) " >&6
6921fi
6922
6923 case $ac_cv_prog_cc_stdc in #(
6924 no) :
6925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6926$as_echo "unsupported" >&6; } ;; #(
6927 '') :
6928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6929$as_echo "none needed" >&6; } ;; #(
6930 *) :
6931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6932$as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6933esac
6934
1fd182f0
PE
6935
6936
4fc2b746 6937 # Code from module alloca-opt:
8d8af66d 6938 # Code from module allocator:
6c051bab 6939 # Code from module careadlinkat:
942f733f 6940 # Code from module crypto/md5:
40e27e7f 6941 # Code from module crypto/sha1:
d87ffdb7
GM
6942 # Code from module crypto/sha256:
6943 # Code from module crypto/sha512:
36f13e16 6944 # Code from module dosname:
f737437b 6945 # Code from module dtoastr:
7d2a1c5e 6946 # Code from module dup2:
1fd182f0
PE
6947 # Code from module extensions:
6948
5fa4ac76 6949 # Code from module filemode:
1f5d53eb 6950 # Code from module getloadavg:
e275c824
PE
6951 # Code from module getopt-gnu:
6952 # Code from module getopt-posix:
6953 # Code from module gettext-h:
67342916 6954 # Code from module ignore-value:
1fd182f0
PE
6955 # Code from module include_next:
6956 # Code from module intprops:
4fda9c95 6957 # Code from module inttypes-incomplete:
369e19fc
PE
6958 # Code from module largefile:
6959
ae0d7250 6960 # Code from module lstat:
1fd182f0
PE
6961 # Code from module mktime:
6962 # Code from module multiarch:
369e19fc 6963 # Code from module nocrash:
a0a61e58 6964 # Code from module pathmax:
3e0be4ab 6965 # Code from module pthread_sigmask:
ae0d7250 6966 # Code from module readlink:
2b1928b8 6967 # Code from module signal-h:
3e0be4ab 6968 # Code from module sigprocmask:
369e19fc
PE
6969 # Code from module snippet/_Noreturn:
6970 # Code from module snippet/arg-nonnull:
6971 # Code from module snippet/c++defs:
6972 # Code from module snippet/warn-on-use:
6ad6792b 6973 # Code from module socklen:
6c051bab 6974 # Code from module ssize_t:
ae0d7250 6975 # Code from module stat:
6d153f56
GM
6976 # Code from module stdarg:
6977
8c069cc7
GM
6978
6979
16c3e636 6980 # Code from module stdbool:
1fd182f0 6981 # Code from module stddef:
5f90be1b 6982 # Code from module stdint:
6ad6792b 6983 # Code from module stdio:
1f5d53eb 6984 # Code from module stdlib:
16c3e636 6985 # Code from module strftime:
3e0be4ab
GM
6986 # Code from module strtoimax:
6987 # Code from module strtoll:
4fda9c95
GM
6988 # Code from module strtoull:
6989 # Code from module strtoumax:
ae0d7250 6990 # Code from module symlink:
5fa4ac76 6991 # Code from module sys_stat:
1fd182f0
PE
6992 # Code from module time:
6993 # Code from module time_r:
d87ffdb7 6994 # Code from module u64:
e275c824 6995 # Code from module unistd:
4fda9c95 6996 # Code from module verify:
1fd182f0
PE
6997
6998
6999# On Suns, sometimes $CPP names a directory.
7000if test -n "$CPP" && test -d "$CPP"; then
7001 CPP=
7002fi
7003
7004## If not using gcc, and on Solaris, and no CPP specified, see if
7005## using a Sun compiler, which needs -Xs to prevent whitespace.
7006if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
7007 test x"$CPP" = x; then
7008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
7009$as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
a9bec17c 7010 if test "${emacs_cv_sunpro_c+set}" = set; then :
1fd182f0
PE
7011 $as_echo_n "(cached) " >&6
7012else
7013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7014/* end confdefs.h. */
7015
7016int
7017main ()
7018{
7019#ifndef __SUNPRO_C
7020fail;
7021#endif
7022
7023 ;
7024 return 0;
7025}
7026_ACEOF
7027if ac_fn_c_try_link "$LINENO"; then :
7028 emacs_cv_sunpro_c=yes
7029else
7030 emacs_cv_sunpro_c=no
7031fi
7032rm -f core conftest.err conftest.$ac_objext \
7033 conftest$ac_exeext conftest.$ac_ext
7034fi
7035
7036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
7037$as_echo "$emacs_cv_sunpro_c" >&6; }
7038
7039 if test x"$emacs_cv_sunpro_c" = xyes; then
7040 NON_GNU_CPP="$CC -E -Xs"
7041 fi
7042fi
7043
7044#### Some systems specify a CPP to use unless we are using GCC.
7045#### Now that we know whether we are using GCC, we can decide whether
7046#### to use that one.
7047if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
7048then
7049 CPP="$NON_GNU_CPP"
7050fi
7051
7052#### Some systems specify a CC to use unless we are using GCC.
7053#### Now that we know whether we are using GCC, we can decide whether
7054#### to use that one.
7055if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
7056 test x$cc_specified != xyes
7057then
7058 CC="$NON_GNU_CC"
7059fi
7060
7061if test x$GCC = xyes; then
7062 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
7063else
7064 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
7065fi
7066
067d23c9
KY
7067### Use -Wdeclaration-after-statement if the compiler supports it
7068{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
7069$as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
7070SAVE_CFLAGS="$CFLAGS"
7071CFLAGS="$CFLAGS -Wdeclaration-after-statement"
7072cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7073/* end confdefs.h. */
7074
7075int
7076main ()
7077{
7078
7079 ;
7080 return 0;
7081}
7082_ACEOF
7083if ac_fn_c_try_compile "$LINENO"; then :
7084 has_option=yes
7085else
7086 has_option=no
7087fi
7088rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7089if test $has_option = yes; then
7090 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
7091fi
7092{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7093$as_echo "$has_option" >&6; }
7094CFLAGS="$SAVE_CFLAGS"
7095unset has_option
7096unset SAVE_CFLAGS
7097
7098### Use -Wold-style-definition if the compiler supports it
7099# This can be removed when conversion to standard C is finished.
7100{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5
7101$as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; }
7102SAVE_CFLAGS="$CFLAGS"
7103CFLAGS="$CFLAGS -Wold-style-definition"
7104cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7105/* end confdefs.h. */
7106
7107int
7108main ()
7109{
7110
7111 ;
7112 return 0;
7113}
7114_ACEOF
7115if ac_fn_c_try_compile "$LINENO"; then :
7116 has_option=yes
7117else
7118 has_option=no
7119fi
7120rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7121if test $has_option = yes; then
7122 C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH"
7123fi
7124{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7125$as_echo "$has_option" >&6; }
7126CFLAGS="$SAVE_CFLAGS"
7127unset has_option
7128unset SAVE_CFLAGS
7129
7130### Use -Wimplicit-function-declaration if the compiler supports it
7131{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5
7132$as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; }
7133SAVE_CFLAGS="$CFLAGS"
7134CFLAGS="$CFLAGS -Wimplicit-function-declaration"
7135cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7136/* end confdefs.h. */
7137
7138int
7139main ()
7140{
7141
7142 ;
7143 return 0;
7144}
7145_ACEOF
7146if ac_fn_c_try_compile "$LINENO"; then :
7147 has_option=yes
7148else
7149 has_option=no
7150fi
7151rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7152if test $has_option = yes; then
7153 C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH"
7154fi
7155{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7156$as_echo "$has_option" >&6; }
7157CFLAGS="$SAVE_CFLAGS"
7158unset has_option
7159unset SAVE_CFLAGS
7160
7161
7162
7163
7164#### Some other nice autoconf tests.
7165
7166ac_ext=c
7167ac_cpp='$CPP $CPPFLAGS'
7168ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7169ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7170ac_compiler_gnu=$ac_cv_c_compiler_gnu
7171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
7172$as_echo_n "checking how to run the C preprocessor... " >&6; }
7173# On Suns, sometimes $CPP names a directory.
7174if test -n "$CPP" && test -d "$CPP"; then
7175 CPP=
7176fi
7177if test -z "$CPP"; then
a9bec17c 7178 if test "${ac_cv_prog_CPP+set}" = set; then :
067d23c9
KY
7179 $as_echo_n "(cached) " >&6
7180else
7181 # Double quotes because CPP needs to be expanded
7182 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
7183 do
7184 ac_preproc_ok=false
7185for ac_c_preproc_warn_flag in '' yes
7186do
7187 # Use a header file that comes with gcc, so configuring glibc
7188 # with a fresh cross-compiler works.
7189 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7190 # <limits.h> exists even on freestanding compilers.
7191 # On the NeXT, cc -E runs the code through the compiler's parser,
7192 # not just through cpp. "Syntax error" is here to catch this case.
7193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7194/* end confdefs.h. */
7195#ifdef __STDC__
7196# include <limits.h>
7197#else
7198# include <assert.h>
7199#endif
7200 Syntax error
7201_ACEOF
7202if ac_fn_c_try_cpp "$LINENO"; then :
7203
7204else
7205 # Broken: fails on valid input.
7206continue
7207fi
a9bec17c 7208rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7209
7210 # OK, works on sane cases. Now check whether nonexistent headers
7211 # can be detected and how.
7212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7213/* end confdefs.h. */
7214#include <ac_nonexistent.h>
7215_ACEOF
7216if ac_fn_c_try_cpp "$LINENO"; then :
7217 # Broken: success on invalid input.
7218continue
7219else
7220 # Passes both tests.
7221ac_preproc_ok=:
7222break
7223fi
a9bec17c 7224rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7225
7226done
7227# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
a9bec17c 7228rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7229if $ac_preproc_ok; then :
7230 break
7231fi
7232
7233 done
7234 ac_cv_prog_CPP=$CPP
7235
7236fi
7237 CPP=$ac_cv_prog_CPP
7238else
7239 ac_cv_prog_CPP=$CPP
7240fi
7241{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7242$as_echo "$CPP" >&6; }
7243ac_preproc_ok=false
7244for ac_c_preproc_warn_flag in '' yes
7245do
7246 # Use a header file that comes with gcc, so configuring glibc
7247 # with a fresh cross-compiler works.
7248 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7249 # <limits.h> exists even on freestanding compilers.
7250 # On the NeXT, cc -E runs the code through the compiler's parser,
7251 # not just through cpp. "Syntax error" is here to catch this case.
7252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7253/* end confdefs.h. */
7254#ifdef __STDC__
7255# include <limits.h>
7256#else
7257# include <assert.h>
7258#endif
7259 Syntax error
7260_ACEOF
7261if ac_fn_c_try_cpp "$LINENO"; then :
7262
7263else
7264 # Broken: fails on valid input.
7265continue
7266fi
a9bec17c 7267rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7268
7269 # OK, works on sane cases. Now check whether nonexistent headers
7270 # can be detected and how.
7271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7272/* end confdefs.h. */
7273#include <ac_nonexistent.h>
7274_ACEOF
7275if ac_fn_c_try_cpp "$LINENO"; then :
7276 # Broken: success on invalid input.
7277continue
7278else
7279 # Passes both tests.
7280ac_preproc_ok=:
7281break
7282fi
a9bec17c 7283rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7284
7285done
7286# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
a9bec17c 7287rm -f conftest.err conftest.$ac_ext
067d23c9
KY
7288if $ac_preproc_ok; then :
7289
7290else
7291 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7292$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
a9bec17c
GM
7293as_fn_error "C preprocessor \"$CPP\" fails sanity check
7294See \`config.log' for more details." "$LINENO" 5; }
067d23c9
KY
7295fi
7296
7297ac_ext=c
7298ac_cpp='$CPP $CPPFLAGS'
7299ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7300ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7301ac_compiler_gnu=$ac_cv_c_compiler_gnu
7302
067d23c9
KY
7303
7304if test "x$RANLIB" = x; then
7305 if test -n "$ac_tool_prefix"; then
7306 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7307set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7308{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7309$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7310if test "${ac_cv_prog_RANLIB+set}" = set; then :
067d23c9
KY
7311 $as_echo_n "(cached) " >&6
7312else
7313 if test -n "$RANLIB"; then
7314 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7315else
7316as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7317for as_dir in $PATH
7318do
7319 IFS=$as_save_IFS
7320 test -z "$as_dir" && as_dir=.
7321 for ac_exec_ext in '' $ac_executable_extensions; do
7322 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7323 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7325 break 2
7326 fi
7327done
7328 done
7329IFS=$as_save_IFS
7330
7331fi
7332fi
7333RANLIB=$ac_cv_prog_RANLIB
7334if test -n "$RANLIB"; then
7335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7336$as_echo "$RANLIB" >&6; }
7337else
7338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7339$as_echo "no" >&6; }
7340fi
7341
7342
7343fi
7344if test -z "$ac_cv_prog_RANLIB"; then
7345 ac_ct_RANLIB=$RANLIB
7346 # Extract the first word of "ranlib", so it can be a program name with args.
7347set dummy ranlib; ac_word=$2
7348{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7349$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7350if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
067d23c9
KY
7351 $as_echo_n "(cached) " >&6
7352else
7353 if test -n "$ac_ct_RANLIB"; then
7354 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7355else
7356as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7357for as_dir in $PATH
7358do
7359 IFS=$as_save_IFS
7360 test -z "$as_dir" && as_dir=.
7361 for ac_exec_ext in '' $ac_executable_extensions; do
7362 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7363 ac_cv_prog_ac_ct_RANLIB="ranlib"
7364 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7365 break 2
7366 fi
7367done
7368 done
7369IFS=$as_save_IFS
7370
7371fi
7372fi
7373ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7374if test -n "$ac_ct_RANLIB"; then
7375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7376$as_echo "$ac_ct_RANLIB" >&6; }
7377else
7378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7379$as_echo "no" >&6; }
7380fi
7381
7382 if test "x$ac_ct_RANLIB" = x; then
7383 RANLIB=":"
7384 else
7385 case $cross_compiling:$ac_tool_warned in
7386yes:)
7387{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7388$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7389ac_tool_warned=yes ;;
7390esac
7391 RANLIB=$ac_ct_RANLIB
7392 fi
7393else
7394 RANLIB="$ac_cv_prog_RANLIB"
7395fi
7396
7397fi
7398
7399## Although we're running on an amd64 kernel, we're actually compiling for
7400## the x86 architecture. The user should probably have provided an
7401## explicit --build to `configure', but if everything else than the kernel
7402## is running in i386 mode, we can help them out.
7403if test "$machine" = "amdx86-64"; then
7404 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
a9bec17c 7405if test "x$ac_cv_have_decl_i386" = x""yes; then :
067d23c9
KY
7406
7407fi
7408
7409 if test "$ac_cv_have_decl_i386" = "yes"; then
7410 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
7411 machine=intel386
7412 machfile="m/${machine}.h"
7413 fi
7414fi
7415
7416# Extract the first word of "install-info", so it can be a program name with args.
7417set dummy install-info; ac_word=$2
7418{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7419$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7420if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
067d23c9
KY
7421 $as_echo_n "(cached) " >&6
7422else
7423 case $INSTALL_INFO in
7424 [\\/]* | ?:[\\/]*)
7425 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7426 ;;
7427 *)
7428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7429for as_dir in $PATH
7430do
7431 IFS=$as_save_IFS
7432 test -z "$as_dir" && as_dir=.
7433 for ac_exec_ext in '' $ac_executable_extensions; do
7434 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7435 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7436 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7437 break 2
7438 fi
7439done
7440 done
7441IFS=$as_save_IFS
7442
7443 ;;
7444esac
7445fi
7446INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7447if test -n "$INSTALL_INFO"; then
7448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7449$as_echo "$INSTALL_INFO" >&6; }
7450else
7451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7452$as_echo "no" >&6; }
7453fi
7454
7455
7456# Extract the first word of "install-info", so it can be a program name with args.
7457set dummy install-info; ac_word=$2
7458{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7459$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7460if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
067d23c9
KY
7461 $as_echo_n "(cached) " >&6
7462else
7463 case $INSTALL_INFO in
7464 [\\/]* | ?:[\\/]*)
7465 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7466 ;;
7467 *)
7468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7469for as_dir in /usr/sbin
7470do
7471 IFS=$as_save_IFS
7472 test -z "$as_dir" && as_dir=.
7473 for ac_exec_ext in '' $ac_executable_extensions; do
7474 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7475 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7477 break 2
7478 fi
7479done
7480 done
7481IFS=$as_save_IFS
7482
7483 ;;
7484esac
7485fi
7486INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7487if test -n "$INSTALL_INFO"; then
7488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7489$as_echo "$INSTALL_INFO" >&6; }
7490else
7491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7492$as_echo "no" >&6; }
7493fi
7494
7495
7496# Extract the first word of "install-info", so it can be a program name with args.
7497set dummy install-info; ac_word=$2
7498{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7499$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7500if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
067d23c9
KY
7501 $as_echo_n "(cached) " >&6
7502else
7503 case $INSTALL_INFO in
7504 [\\/]* | ?:[\\/]*)
7505 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7506 ;;
7507 *)
7508 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7509for as_dir in /sbin
7510do
7511 IFS=$as_save_IFS
7512 test -z "$as_dir" && as_dir=.
7513 for ac_exec_ext in '' $ac_executable_extensions; do
7514 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7515 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7517 break 2
7518 fi
7519done
7520 done
7521IFS=$as_save_IFS
7522
7523 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7524 ;;
7525esac
7526fi
7527INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7528if test -n "$INSTALL_INFO"; then
7529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7530$as_echo "$INSTALL_INFO" >&6; }
7531else
7532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7533$as_echo "no" >&6; }
7534fi
7535
7536
7537# Extract the first word of "gzip", so it can be a program name with args.
7538set dummy gzip; ac_word=$2
7539{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7540$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7541if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
067d23c9
KY
7542 $as_echo_n "(cached) " >&6
7543else
7544 case $GZIP_PROG in
7545 [\\/]* | ?:[\\/]*)
7546 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7547 ;;
7548 *)
7549 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7550for as_dir in $PATH
7551do
7552 IFS=$as_save_IFS
7553 test -z "$as_dir" && as_dir=.
7554 for ac_exec_ext in '' $ac_executable_extensions; do
7555 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7556 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7557 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7558 break 2
7559 fi
7560done
7561 done
7562IFS=$as_save_IFS
7563
7564 ;;
7565esac
7566fi
7567GZIP_PROG=$ac_cv_path_GZIP_PROG
7568if test -n "$GZIP_PROG"; then
7569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7570$as_echo "$GZIP_PROG" >&6; }
7571else
7572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7573$as_echo "no" >&6; }
7574fi
7575
7576
7577
7578
7579## Need makeinfo >= 4.6 (?) to build the manuals.
7580# Extract the first word of "makeinfo", so it can be a program name with args.
7581set dummy makeinfo; ac_word=$2
7582{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7583$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 7584if test "${ac_cv_path_MAKEINFO+set}" = set; then :
067d23c9
KY
7585 $as_echo_n "(cached) " >&6
7586else
7587 case $MAKEINFO in
7588 [\\/]* | ?:[\\/]*)
7589 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7590 ;;
7591 *)
7592 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7593for as_dir in $PATH
7594do
7595 IFS=$as_save_IFS
7596 test -z "$as_dir" && as_dir=.
7597 for ac_exec_ext in '' $ac_executable_extensions; do
7598 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7599 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
7600 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7601 break 2
7602 fi
7603done
7604 done
7605IFS=$as_save_IFS
7606
7607 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
7608 ;;
7609esac
7610fi
7611MAKEINFO=$ac_cv_path_MAKEINFO
7612if test -n "$MAKEINFO"; then
7613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
7614$as_echo "$MAKEINFO" >&6; }
7615else
7616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7617$as_echo "no" >&6; }
7618fi
7619
7620
7621if test "$MAKEINFO" != "no" && \
7622 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[6-9]|4\.[1-5][0-9]+)'`" = x; then
7623 MAKEINFO=no
7624fi
7625
7626## Makeinfo is unusual. For a released Emacs, the manuals are
7627## pre-built, and not deleted by the normal clean rules. makeinfo is
7628## therefore in the category of "special tools" not normally required, which
7629## configure does not have to check for (eg autoconf itself).
7630## In a Bazaar checkout on the other hand, the manuals are not included.
7631## So makeinfo is a requirement to build from Bazaar, and configure
7632## should test for it as it does for any other build requirement.
7633## We use the presence of $srcdir/info/emacs to distinguish a release,
7634## with pre-built manuals, from a Bazaar checkout.
96f129d5
GM
7635HAVE_MAKEINFO=yes
7636
067d23c9 7637if test "$MAKEINFO" = "no"; then
96f129d5 7638 MAKEINFO=makeinfo
067d23c9 7639 if test "x${with_makeinfo}" = "xno"; then
96f129d5 7640 HAVE_MAKEINFO=no
067d23c9 7641 elif test ! -e $srcdir/info/emacs; then
a9bec17c 7642 as_fn_error "You do not seem to have makeinfo >= 4.6, and your
067d23c9
KY
7643source tree does not seem to have pre-built manuals in the \`info' directory.
7644Either install a suitable version of makeinfo, or re-run configure
7645with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
7646 fi
7647fi
7648
7649
96f129d5 7650
067d23c9
KY
7651if test x$GCC = xyes; then
7652 test "x$GCC_LINK_TEST_OPTIONS" != x && \
7653 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
7654else
7655 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
7656 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
7657fi
7658
7659
7660late_LDFLAGS=$LDFLAGS
7661if test x$GCC = xyes; then
7662 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
7663else
7664 LDFLAGS="$LDFLAGS -znocombreloc"
7665fi
7666
7667{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
7668$as_echo_n "checking for -znocombreloc... " >&6; }
7669cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7670/* end confdefs.h. */
7671
7672int
7673main ()
7674{
7675
7676 ;
7677 return 0;
7678}
7679_ACEOF
7680if ac_fn_c_try_link "$LINENO"; then :
7681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7682$as_echo "yes" >&6; }
7683else
7684 LDFLAGS=$late_LDFLAGS
7685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7686$as_echo "no" >&6; }
7687fi
7688rm -f core conftest.err conftest.$ac_objext \
7689 conftest$ac_exeext conftest.$ac_ext
7690
7691
7692# The value of CPP is a quoted variable reference, so we need to do this
7693# to get its actual value...
7694CPP=`eval "echo $CPP"`
7695
7696
125c3718 7697test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
067d23c9 7698case "$opsys" in
125c3718
PE
7699 your-opsys-here) CANNOT_DUMP=yes ;;
7700esac
7701
7702test "$CANNOT_DUMP" = "yes" && \
067d23c9
KY
7703
7704$as_echo "#define CANNOT_DUMP 1" >>confdefs.h
7705
125c3718 7706
067d23c9
KY
7707
7708
7709
7710UNEXEC_OBJ=unexelf.o
7711case "$opsys" in
7712 # MSDOS uses unexcoff.o
7713 # MSWindows uses unexw32.o
7714 aix4-2)
7715 UNEXEC_OBJ=unexaix.o
7716 ;;
7717 cygwin)
7718 UNEXEC_OBJ=unexcw.o
7719 ;;
7720 darwin)
7721 UNEXEC_OBJ=unexmacosx.o
7722 ;;
7723 hpux10-20 | hpux11)
7724 UNEXEC_OBJ=unexhp9k800.o
7725 ;;
7726 sol2-10)
7727 # Use the Solaris dldump() function, called from unexsol.c, to dump
7728 # emacs, instead of the generic ELF dump code found in unexelf.c.
7729 # The resulting binary has a complete symbol table, and is better
7730 # for debugging and other observability tools (debuggers, pstack, etc).
7731 #
7732 # If you encounter a problem using dldump(), please consider sending
7733 # a message to the OpenSolaris tools-linking mailing list:
7734 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
7735 #
7736 # It is likely that dldump() works with older Solaris too, but this has
7737 # not been tested, so for now this change is for Solaris 10 or newer.
7738 UNEXEC_OBJ=unexsol.o
7739 ;;
7740esac
7741
7742LD_SWITCH_SYSTEM=
7743case "$opsys" in
7744 freebsd)
7745 ## Let `ld' find image libs and similar things in /usr/local/lib.
7746 ## The system compiler, GCC, has apparently been modified to not
7747 ## look there, contrary to what a stock GCC would do.
7748 LD_SWITCH_SYSTEM=-L/usr/local/lib
7749 ;;
7750
7751 gnu-linux)
7752 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
d6a003a8 7753 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
067d23c9
KY
7754 ;;
7755
7756 netbsd)
7757 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
7758 ;;
7759
7760 openbsd)
7761 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
7762 ## otherwise Emacs dumps core on elf systems.
7763 LD_SWITCH_SYSTEM="-Z"
7764 ;;
7765esac
7766
7767
7768ac_link="$ac_link $LD_SWITCH_SYSTEM"
7769
7770## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
7771## which has not been defined yet. When this was handled with cpp,
7772## it was expanded to null when configure sourced the s/*.h file.
7773## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
7774## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
7775## (or somesuch), but because it is supposed to go at the _front_
7776## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
7777## Compare with the gnu-linux case below, which added to the end
7778## of LD_SWITCH_SYSTEM, and so can instead go at the front of
7779## LD_SWITCH_SYSTEM_TEMACS.
7780case "$opsys" in
7781 netbsd|openbsd)
7782 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
7783 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
7784esac
7785
7786
7787C_SWITCH_MACHINE=
7788if test "$machine" = "alpha"; then
7789 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
a9bec17c 7790if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
067d23c9
KY
7791
7792fi
7793
7794 if test "$ac_cv_have_decl___ELF__" = "yes"; then
7795 ## With ELF, make sure that all common symbols get allocated to in the
7796 ## data section. Otherwise, the dump of temacs may miss variables in
7797 ## the shared library that have been initialized. For example, with
7798 ## GNU libc, __malloc_initialized would normally be resolved to the
7799 ## shared library's .bss section, which is fatal.
7800 if test "x$GCC" = "xyes"; then
7801 C_SWITCH_MACHINE="-fno-common"
7802 else
a9bec17c 7803 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
067d23c9
KY
7804 fi
7805 else
7806 UNEXEC_OBJ=unexalpha.o
7807 fi
7808fi
7809
7810
7811
7812
7813C_SWITCH_SYSTEM=
7814## Some programs in src produce warnings saying certain subprograms
7815## are too complex and need a MAXMEM value greater than 2000 for
7816## additional optimization. --nils@exp-math.uni-essen.de
7817test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
7818 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
7819## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
7820## It is redundant in glibc2, since we define _GNU_SOURCE.
7821
7822
7823
7824LIBS_SYSTEM=
7825case "$opsys" in
7826 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
7827 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
7828
7829 freebsd) LIBS_SYSTEM="-lutil" ;;
7830
7831 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
7832
1f5d53eb 7833 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
067d23c9
KY
7834
7835 ## Motif needs -lgen.
7836 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
7837esac
7838
7839
7840
7841### Make sure subsequent tests use flags consistent with the build flags.
7842
7843if test x"${OVERRIDE_CPPFLAGS}" != x; then
7844 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
7845else
7846 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
7847fi
7848
4fda9c95
GM
7849# Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
7850
3e0be4ab
GM
7851# Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
7852
4fda9c95 7853
067d23c9
KY
7854# Check whether --enable-largefile was given.
7855if test "${enable_largefile+set}" = set; then :
7856 enableval=$enable_largefile;
7857fi
7858
7859if test "$enable_largefile" != no; then
7860
7861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7862$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
a9bec17c 7863if test "${ac_cv_sys_largefile_CC+set}" = set; then :
067d23c9
KY
7864 $as_echo_n "(cached) " >&6
7865else
7866 ac_cv_sys_largefile_CC=no
7867 if test "$GCC" != yes; then
7868 ac_save_CC=$CC
7869 while :; do
369e19fc
PE
7870 # IRIX 6.2 and later do not support large files by default,
7871 # so use the C compiler's -n32 option if that helps.
7872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9
KY
7873/* end confdefs.h. */
7874#include <sys/types.h>
7875 /* Check that off_t can represent 2**63 - 1 correctly.
7876 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7877 since some C++ compilers masquerading as C compilers
7878 incorrectly reject 9223372036854775807. */
7879#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7880 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
369e19fc
PE
7881 && LARGE_OFF_T % 2147483647 == 1)
7882 ? 1 : -1];
067d23c9
KY
7883int
7884main ()
7885{
7886
7887 ;
7888 return 0;
7889}
7890_ACEOF
369e19fc 7891 if ac_fn_c_try_compile "$LINENO"; then :
067d23c9
KY
7892 break
7893fi
7894rm -f core conftest.err conftest.$ac_objext
369e19fc
PE
7895 CC="$CC -n32"
7896 if ac_fn_c_try_compile "$LINENO"; then :
067d23c9
KY
7897 ac_cv_sys_largefile_CC=' -n32'; break
7898fi
7899rm -f core conftest.err conftest.$ac_objext
369e19fc 7900 break
067d23c9
KY
7901 done
7902 CC=$ac_save_CC
7903 rm -f conftest.$ac_ext
7904 fi
7905fi
7906{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7907$as_echo "$ac_cv_sys_largefile_CC" >&6; }
7908 if test "$ac_cv_sys_largefile_CC" != no; then
7909 CC=$CC$ac_cv_sys_largefile_CC
7910 fi
7911
7912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7913$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
a9bec17c 7914if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
067d23c9
KY
7915 $as_echo_n "(cached) " >&6
7916else
7917 while :; do
7918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7919/* end confdefs.h. */
7920#include <sys/types.h>
7921 /* Check that off_t can represent 2**63 - 1 correctly.
7922 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7923 since some C++ compilers masquerading as C compilers
7924 incorrectly reject 9223372036854775807. */
7925#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7926 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
369e19fc
PE
7927 && LARGE_OFF_T % 2147483647 == 1)
7928 ? 1 : -1];
067d23c9
KY
7929int
7930main ()
7931{
7932
7933 ;
7934 return 0;
7935}
7936_ACEOF
7937if ac_fn_c_try_compile "$LINENO"; then :
7938 ac_cv_sys_file_offset_bits=no; break
7939fi
7940rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7942/* end confdefs.h. */
7943#define _FILE_OFFSET_BITS 64
7944#include <sys/types.h>
7945 /* Check that off_t can represent 2**63 - 1 correctly.
7946 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7947 since some C++ compilers masquerading as C compilers
7948 incorrectly reject 9223372036854775807. */
7949#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7950 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
369e19fc
PE
7951 && LARGE_OFF_T % 2147483647 == 1)
7952 ? 1 : -1];
067d23c9
KY
7953int
7954main ()
7955{
7956
7957 ;
7958 return 0;
7959}
7960_ACEOF
7961if ac_fn_c_try_compile "$LINENO"; then :
7962 ac_cv_sys_file_offset_bits=64; break
7963fi
7964rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7965 ac_cv_sys_file_offset_bits=unknown
7966 break
7967done
7968fi
7969{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7970$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7971case $ac_cv_sys_file_offset_bits in #(
7972 no | unknown) ;;
7973 *)
7974cat >>confdefs.h <<_ACEOF
7975#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7976_ACEOF
7977;;
7978esac
7979rm -rf conftest*
7980 if test $ac_cv_sys_file_offset_bits = unknown; then
7981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7982$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
a9bec17c 7983if test "${ac_cv_sys_large_files+set}" = set; then :
067d23c9
KY
7984 $as_echo_n "(cached) " >&6
7985else
7986 while :; do
7987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7988/* end confdefs.h. */
7989#include <sys/types.h>
7990 /* Check that off_t can represent 2**63 - 1 correctly.
7991 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7992 since some C++ compilers masquerading as C compilers
7993 incorrectly reject 9223372036854775807. */
7994#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7995 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
369e19fc
PE
7996 && LARGE_OFF_T % 2147483647 == 1)
7997 ? 1 : -1];
067d23c9
KY
7998int
7999main ()
8000{
8001
8002 ;
8003 return 0;
8004}
8005_ACEOF
8006if ac_fn_c_try_compile "$LINENO"; then :
8007 ac_cv_sys_large_files=no; break
8008fi
8009rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8011/* end confdefs.h. */
8012#define _LARGE_FILES 1
8013#include <sys/types.h>
8014 /* Check that off_t can represent 2**63 - 1 correctly.
8015 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8016 since some C++ compilers masquerading as C compilers
8017 incorrectly reject 9223372036854775807. */
8018#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8019 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
369e19fc
PE
8020 && LARGE_OFF_T % 2147483647 == 1)
8021 ? 1 : -1];
067d23c9
KY
8022int
8023main ()
8024{
8025
8026 ;
8027 return 0;
8028}
8029_ACEOF
8030if ac_fn_c_try_compile "$LINENO"; then :
8031 ac_cv_sys_large_files=1; break
8032fi
8033rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8034 ac_cv_sys_large_files=unknown
8035 break
8036done
8037fi
8038{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
8039$as_echo "$ac_cv_sys_large_files" >&6; }
8040case $ac_cv_sys_large_files in #(
8041 no | unknown) ;;
8042 *)
8043cat >>confdefs.h <<_ACEOF
8044#define _LARGE_FILES $ac_cv_sys_large_files
8045_ACEOF
8046;;
8047esac
8048rm -rf conftest*
8049 fi
369e19fc
PE
8050
8051
067d23c9
KY
8052fi
8053
8054
8055
067d23c9
KY
8056LIB_MATH=-lm
8057LIB_STANDARD=
8058START_FILES=
8059
8060case $opsys in
8061 cygwin )
8062 LIB_MATH=
8063 START_FILES='pre-crt0.o'
8064 ;;
8065 darwin )
8066 ## Adding -lm confuses the dynamic linker, so omit it.
8067 LIB_MATH=
8068 START_FILES='pre-crt0.o'
8069 ;;
8070 freebsd )
8071 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8072 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8073 ;;
8074 gnu-linux | gnu-kfreebsd )
8075 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8076 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8077 ;;
8078 hpux10-20 | hpux11 )
8079 LIB_STANDARD=-lc
8080 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8081 ;;
bb72ce91
GM
8082 netbsd | openbsd )
8083 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8084 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
067d23c9
KY
8085 ;;
8086esac
8087
8088
8089
8090
130f1dac
GM
8091crt_files=
8092
8093for file in x $LIB_STANDARD $START_FILES; do
8094 case "$file" in
8095 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8096 esac
8097done
8098
8099if test "x$crt_files" != x; then
8100
8101 ## If user specified a crt-dir, use that unconditionally.
8102 crt_gcc=no
8103
8104 if test "X$CRT_DIR" = "X"; then
8105
8106 CRT_DIR=/usr/lib # default
8107
8108 case "$canonical" in
8109 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8110 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8111 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8112 ## For anything else (eg /usr/lib32), it is up the user to specify
8113 ## the location (bug#5655).
8114 ## Test for crtn.o, not just the directory, because sometimes the
8115 ## directory exists but does not have the relevant files (bug#1287).
8116 ## FIXME better to test for binary compatibility somehow.
8117 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8118 ;;
8119
8120 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8121 esac
8122
8123 case "$opsys" in
8124 hpux10-20) CRT_DIR=/lib ;;
8125 esac
8126
8127 test "x${GCC}" = xyes && crt_gcc=yes
8128
8129 fi # CRT_DIR = ""
8130
8131 crt_missing=
8132
8133 for file in $crt_files; do
8134
8135 ## If we're using gcc, try to determine it automatically by asking
8136 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8137 ## system-dependent default from above.]
8138 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8139
8140 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8141 case "$crt_file" in
8142 */*)
8143 CRT_DIR=`$as_dirname -- "$crt_file" ||
8144$as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8145 X"$crt_file" : 'X\(//\)[^/]' \| \
8146 X"$crt_file" : 'X\(//\)$' \| \
8147 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8148$as_echo X"$crt_file" |
8149 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8150 s//\1/
8151 q
8152 }
8153 /^X\(\/\/\)[^/].*/{
8154 s//\1/
8155 q
8156 }
8157 /^X\(\/\/\)$/{
8158 s//\1/
8159 q
8160 }
8161 /^X\(\/\).*/{
8162 s//\1/
8163 q
8164 }
8165 s/.*/./; q'`
8166 ;;
8167 esac
8168 fi
8169
8170 crt_gcc=no
8171
8172 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8173 done # $crt_files
8174
8175 test "x$crt_missing" = x || \
a9bec17c 8176 as_fn_error "Required file(s) not found:$crt_missing
130f1dac
GM
8177Try using the --with-crt-dir option." "$LINENO" 5
8178
8179fi # crt_files != ""
8180
8181
8182
bb72ce91
GM
8183case $opsys in
8184 netbsd | openbsd )
8185 if test -f $CRT_DIR/crti.o; then
8186
8187 test -f $CRT_DIR/crtn.o || \
8188 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8189
8190 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8191 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8192 fi
8193 ;;
8194esac
8195
130f1dac 8196
067d23c9
KY
8197
8198
8199
8200if test "${with_sound}" != "no"; then
8201 # Sound support for GNU/Linux and the free BSDs.
8202 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8203do :
8204 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8205ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
a9bec17c
GM
8206eval as_val=\$$as_ac_Header
8207 if test "x$as_val" = x""yes; then :
067d23c9
KY
8208 cat >>confdefs.h <<_ACEOF
8209#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8210_ACEOF
8211 have_sound_header=yes
8212fi
8213
8214done
8215
8216 # Emulation library used on NetBSD.
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8218$as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
a9bec17c 8219if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
067d23c9
KY
8220 $as_echo_n "(cached) " >&6
8221else
8222 ac_check_lib_save_LIBS=$LIBS
8223LIBS="-lossaudio $LIBS"
8224cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8225/* end confdefs.h. */
8226
8227/* Override any GCC internal prototype to avoid an error.
8228 Use char because int might match the return type of a GCC
8229 builtin and then its argument prototype would still apply. */
8230#ifdef __cplusplus
8231extern "C"
8232#endif
8233char _oss_ioctl ();
8234int
8235main ()
8236{
8237return _oss_ioctl ();
8238 ;
8239 return 0;
8240}
8241_ACEOF
8242if ac_fn_c_try_link "$LINENO"; then :
8243 ac_cv_lib_ossaudio__oss_ioctl=yes
8244else
8245 ac_cv_lib_ossaudio__oss_ioctl=no
8246fi
8247rm -f core conftest.err conftest.$ac_objext \
8248 conftest$ac_exeext conftest.$ac_ext
8249LIBS=$ac_check_lib_save_LIBS
8250fi
8251{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8252$as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
a9bec17c 8253if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
067d23c9
KY
8254 LIBSOUND=-lossaudio
8255else
8256 LIBSOUND=
8257fi
8258
8259
8260
8261 ALSA_REQUIRED=1.0.0
8262 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8263
8264 succeeded=no
8265
8266 # Extract the first word of "pkg-config", so it can be a program name with args.
8267set dummy pkg-config; ac_word=$2
8268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8269$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 8270if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
8271 $as_echo_n "(cached) " >&6
8272else
8273 case $PKG_CONFIG in
8274 [\\/]* | ?:[\\/]*)
8275 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8276 ;;
8277 *)
8278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8279for as_dir in $PATH
8280do
8281 IFS=$as_save_IFS
8282 test -z "$as_dir" && as_dir=.
8283 for ac_exec_ext in '' $ac_executable_extensions; do
8284 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8285 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8287 break 2
8288 fi
8289done
8290 done
8291IFS=$as_save_IFS
8292
8293 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8294 ;;
8295esac
8296fi
8297PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8298if test -n "$PKG_CONFIG"; then
8299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8300$as_echo "$PKG_CONFIG" >&6; }
8301else
8302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8303$as_echo "no" >&6; }
8304fi
8305
8306
8307
8308 if test "$PKG_CONFIG" = "no" ; then
8309 HAVE_ALSA=no
8310 else
8311 PKG_CONFIG_MIN_VERSION=0.9.0
8312 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8314$as_echo_n "checking for $ALSA_MODULES... " >&6; }
8315
8316 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
8317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8318$as_echo "yes" >&6; }
8319 succeeded=yes
8320
8321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5
8322$as_echo_n "checking ALSA_CFLAGS... " >&6; }
8323 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
8324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5
8325$as_echo "$ALSA_CFLAGS" >&6; }
8326
8327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5
8328$as_echo_n "checking ALSA_LIBS... " >&6; }
8329 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
8330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5
8331$as_echo "$ALSA_LIBS" >&6; }
8332 else
8333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8334$as_echo "no" >&6; }
8335 ALSA_CFLAGS=""
8336 ALSA_LIBS=""
8337 ## If we have a custom action on failure, don't print errors, but
8338 ## do set a variable so people can do so.
8339 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
8340
8341 fi
8342
8343
8344
8345 else
8346 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8347 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8348 fi
8349 fi
8350
8351 if test $succeeded = yes; then
8352 HAVE_ALSA=yes
8353 else
8354 HAVE_ALSA=no
8355 fi
8356
8357 if test $HAVE_ALSA = yes; then
8358 SAVE_CFLAGS="$CFLAGS"
d7932d31 8359 SAVE_LIBS="$LIBS"
067d23c9 8360 CFLAGS="$ALSA_CFLAGS $CFLAGS"
d7932d31 8361 LIBS="$ALSA_LIBS $LIBS"
067d23c9
KY
8362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8363/* end confdefs.h. */
8364#include <asoundlib.h>
8365int
8366main ()
8367{
8368snd_lib_error_set_handler (0);
8369 ;
8370 return 0;
8371}
8372_ACEOF
8373if ac_fn_c_try_compile "$LINENO"; then :
8374 emacs_alsa_normal=yes
8375else
8376 emacs_alsa_normal=no
8377fi
8378rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8379 if test "$emacs_alsa_normal" != yes; then
8380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8381/* end confdefs.h. */
8382#include <alsa/asoundlib.h>
8383int
8384main ()
8385{
8386snd_lib_error_set_handler (0);
8387 ;
8388 return 0;
8389}
8390_ACEOF
8391if ac_fn_c_try_compile "$LINENO"; then :
8392 emacs_alsa_subdir=yes
8393else
8394 emacs_alsa_subdir=no
8395fi
8396rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8397 if test "$emacs_alsa_subdir" != yes; then
a9bec17c 8398 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
067d23c9
KY
8399 fi
8400 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8401 fi
8402
8403 CFLAGS="$SAVE_CFLAGS"
d7932d31 8404 LIBS="$SAVE_LIBS"
067d23c9
KY
8405 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8406 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8407
8408$as_echo "#define HAVE_ALSA 1" >>confdefs.h
8409
8410 fi
8411
8412 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8413 case "$opsys" in
8414 gnu-linux|freebsd|netbsd)
8415
8416$as_echo "#define HAVE_SOUND 1" >>confdefs.h
8417
8418 ;;
8419 esac
8420 fi
8421
8422
8423fi
8424
8425for ac_header in sys/select.h sys/time.h unistd.h utime.h \
1fb8351b 8426 linux/version.h sys/systeminfo.h \
067d23c9
KY
8427 stdio_ext.h fcntl.h coff.h pty.h sys/mman.h \
8428 sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
8429 sys/utsname.h pwd.h utmp.h dirent.h util.h
8430do :
8431 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8432ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
a9bec17c
GM
8433eval as_val=\$$as_ac_Header
8434 if test "x$as_val" = x""yes; then :
067d23c9
KY
8435 cat >>confdefs.h <<_ACEOF
8436#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8437_ACEOF
8438
8439fi
8440
8441done
8442
8443
8444{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8445$as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8446cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8447/* end confdefs.h. */
8448#include <sys/personality.h>
8449int
8450main ()
8451{
8452personality (PER_LINUX32)
8453 ;
8454 return 0;
8455}
8456_ACEOF
8457if ac_fn_c_try_compile "$LINENO"; then :
8458 emacs_cv_personality_linux32=yes
8459else
8460 emacs_cv_personality_linux32=no
8461fi
8462rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8463{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8464$as_echo "$emacs_cv_personality_linux32" >&6; }
8465
8466if test $emacs_cv_personality_linux32 = yes; then
8467
8468$as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8469
8470fi
8471
8472for ac_header in term.h
8473do :
8474 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
a9bec17c 8475if test "x$ac_cv_header_term_h" = x""yes; then :
067d23c9
KY
8476 cat >>confdefs.h <<_ACEOF
8477#define HAVE_TERM_H 1
8478_ACEOF
8479
8480fi
8481
8482done
8483
067d23c9
KY
8484{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8485$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
a9bec17c 8486if test "${ac_cv_header_time+set}" = set; then :
067d23c9
KY
8487 $as_echo_n "(cached) " >&6
8488else
8489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8490/* end confdefs.h. */
8491#include <sys/types.h>
8492#include <sys/time.h>
8493#include <time.h>
8494
8495int
8496main ()
8497{
8498if ((struct tm *) 0)
8499return 0;
8500 ;
8501 return 0;
8502}
8503_ACEOF
8504if ac_fn_c_try_compile "$LINENO"; then :
8505 ac_cv_header_time=yes
8506else
8507 ac_cv_header_time=no
8508fi
8509rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8510fi
8511{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8512$as_echo "$ac_cv_header_time" >&6; }
8513if test $ac_cv_header_time = yes; then
8514
8515$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8516
8517fi
8518
8519ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
a9bec17c 8520if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
067d23c9
KY
8521 ac_have_decl=1
8522else
8523 ac_have_decl=0
8524fi
8525
8526cat >>confdefs.h <<_ACEOF
8527#define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8528_ACEOF
8529
8530if test $ac_cv_have_decl_sys_siglist != yes; then
8531 # For Tru64, at least:
8532 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
a9bec17c 8533if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
067d23c9
KY
8534 ac_have_decl=1
8535else
8536 ac_have_decl=0
8537fi
8538
8539cat >>confdefs.h <<_ACEOF
8540#define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8541_ACEOF
8542
8543 if test $ac_cv_have_decl___sys_siglist = yes; then
8544
8545$as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8546
8547 fi
8548fi
8549{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8550$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
a9bec17c 8551if test "${ac_cv_header_sys_wait_h+set}" = set; then :
067d23c9
KY
8552 $as_echo_n "(cached) " >&6
8553else
8554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8555/* end confdefs.h. */
8556#include <sys/types.h>
8557#include <sys/wait.h>
8558#ifndef WEXITSTATUS
8559# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8560#endif
8561#ifndef WIFEXITED
8562# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8563#endif
8564
8565int
8566main ()
8567{
8568 int s;
8569 wait (&s);
8570 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8571 ;
8572 return 0;
8573}
8574_ACEOF
8575if ac_fn_c_try_compile "$LINENO"; then :
8576 ac_cv_header_sys_wait_h=yes
8577else
8578 ac_cv_header_sys_wait_h=no
8579fi
8580rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8581fi
8582{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8583$as_echo "$ac_cv_header_sys_wait_h" >&6; }
8584if test $ac_cv_header_sys_wait_h = yes; then
8585
8586$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8587
8588fi
8589
8590
8591{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
8592$as_echo_n "checking for struct utimbuf... " >&6; }
a9bec17c 8593if test "${emacs_cv_struct_utimbuf+set}" = set; then :
067d23c9
KY
8594 $as_echo_n "(cached) " >&6
8595else
8596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8597/* end confdefs.h. */
8598#ifdef TIME_WITH_SYS_TIME
8599#include <sys/time.h>
8600#include <time.h>
8601#else
8602#ifdef HAVE_SYS_TIME_H
8603#include <sys/time.h>
8604#else
8605#include <time.h>
8606#endif
8607#endif
8608#ifdef HAVE_UTIME_H
8609#include <utime.h>
8610#endif
8611int
8612main ()
8613{
8614static struct utimbuf x; x.actime = x.modtime;
8615 ;
8616 return 0;
8617}
8618_ACEOF
8619if ac_fn_c_try_compile "$LINENO"; then :
8620 emacs_cv_struct_utimbuf=yes
8621else
8622 emacs_cv_struct_utimbuf=no
8623fi
8624rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8625fi
8626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
8627$as_echo "$emacs_cv_struct_utimbuf" >&6; }
8628if test $emacs_cv_struct_utimbuf = yes; then
8629
8630$as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
8631
8632fi
8633
067d23c9
KY
8634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8635$as_echo_n "checking for speed_t... " >&6; }
a9bec17c 8636if test "${emacs_cv_speed_t+set}" = set; then :
067d23c9
KY
8637 $as_echo_n "(cached) " >&6
8638else
8639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8640/* end confdefs.h. */
8641#include <termios.h>
8642int
8643main ()
8644{
8645speed_t x = 1;
8646 ;
8647 return 0;
8648}
8649_ACEOF
8650if ac_fn_c_try_compile "$LINENO"; then :
8651 emacs_cv_speed_t=yes
8652else
8653 emacs_cv_speed_t=no
8654fi
8655rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8656fi
8657{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8658$as_echo "$emacs_cv_speed_t" >&6; }
8659if test $emacs_cv_speed_t = yes; then
8660
8661$as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8662
8663fi
8664
8665{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
8666$as_echo_n "checking for struct timeval... " >&6; }
a9bec17c 8667if test "${emacs_cv_struct_timeval+set}" = set; then :
067d23c9
KY
8668 $as_echo_n "(cached) " >&6
8669else
8670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8671/* end confdefs.h. */
8672#ifdef TIME_WITH_SYS_TIME
8673#include <sys/time.h>
8674#include <time.h>
8675#else
8676#ifdef HAVE_SYS_TIME_H
8677#include <sys/time.h>
8678#else
8679#include <time.h>
8680#endif
8681#endif
8682int
8683main ()
8684{
8685static struct timeval x; x.tv_sec = x.tv_usec;
8686 ;
8687 return 0;
8688}
8689_ACEOF
8690if ac_fn_c_try_compile "$LINENO"; then :
8691 emacs_cv_struct_timeval=yes
8692else
8693 emacs_cv_struct_timeval=no
8694fi
8695rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8696fi
8697{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
8698$as_echo "$emacs_cv_struct_timeval" >&6; }
8699HAVE_TIMEVAL=$emacs_cv_struct_timeval
8700if test $emacs_cv_struct_timeval = yes; then
8701
8702$as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
8703
8704fi
8705
8706{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8707$as_echo_n "checking for struct exception... " >&6; }
a9bec17c 8708if test "${emacs_cv_struct_exception+set}" = set; then :
067d23c9
KY
8709 $as_echo_n "(cached) " >&6
8710else
8711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8712/* end confdefs.h. */
8713#include <math.h>
8714int
8715main ()
8716{
8717static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8718 ;
8719 return 0;
8720}
8721_ACEOF
8722if ac_fn_c_try_compile "$LINENO"; then :
8723 emacs_cv_struct_exception=yes
8724else
8725 emacs_cv_struct_exception=no
8726fi
8727rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8728fi
8729{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8730$as_echo "$emacs_cv_struct_exception" >&6; }
8731HAVE_EXCEPTION=$emacs_cv_struct_exception
8732if test $emacs_cv_struct_exception != yes; then
8733
8734$as_echo "#define NO_MATHERR 1" >>confdefs.h
8735
8736fi
8737
7417b37c
GM
8738for ac_header in sys/socket.h
8739do :
8740 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
a9bec17c 8741if test "x$ac_cv_header_sys_socket_h" = x""yes; then :
7417b37c
GM
8742 cat >>confdefs.h <<_ACEOF
8743#define HAVE_SYS_SOCKET_H 1
8744_ACEOF
8745
8746fi
8747
8748done
8749
067d23c9
KY
8750for ac_header in net/if.h
8751do :
8752 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8753#if HAVE_SYS_SOCKET_H
8754#include <sys/socket.h>
8755#endif
8756"
a9bec17c 8757if test "x$ac_cv_header_net_if_h" = x""yes; then :
067d23c9
KY
8758 cat >>confdefs.h <<_ACEOF
8759#define HAVE_NET_IF_H 1
8760_ACEOF
8761
8762fi
8763
8764done
8765
7417b37c
GM
8766for ac_header in ifaddrs.h
8767do :
8768 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8769#if HAVE_SYS_SOCKET_H
8770#include <sys/socket.h>
8771#endif
8772"
a9bec17c 8773if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
7417b37c
GM
8774 cat >>confdefs.h <<_ACEOF
8775#define HAVE_IFADDRS_H 1
8776_ACEOF
8777
8778fi
8779
8780done
8781
8782for ac_header in net/if_dl.h
8783do :
8784 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8785#if HAVE_SYS_SOCKET_H
8786#include <sys/socket.h>
8787#endif
8788"
a9bec17c 8789if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
7417b37c
GM
8790 cat >>confdefs.h <<_ACEOF
8791#define HAVE_NET_IF_DL_H 1
8792_ACEOF
8793
8794fi
8795
8796done
8797
8798for ac_func in getifaddrs freeifaddrs
8799do :
8800 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8801ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
8802eval as_val=\$$as_ac_var
8803 if test "x$as_val" = x""yes; then :
7417b37c
GM
8804 cat >>confdefs.h <<_ACEOF
8805#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8806_ACEOF
8807
8808fi
8809done
8810
067d23c9 8811
067d23c9
KY
8812ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8813#if HAVE_SYS_SOCKET_H
8814#include <sys/socket.h>
8815#endif
8816#if HAVE_NET_IF_H
8817#include <net/if.h>
8818#endif
8819"
a9bec17c 8820if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
067d23c9
KY
8821
8822cat >>confdefs.h <<_ACEOF
8823#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8824_ACEOF
8825
8826
8827fi
8828ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8829#if HAVE_SYS_SOCKET_H
8830#include <sys/socket.h>
8831#endif
8832#if HAVE_NET_IF_H
8833#include <net/if.h>
8834#endif
8835"
a9bec17c 8836if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
067d23c9
KY
8837
8838cat >>confdefs.h <<_ACEOF
8839#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8840_ACEOF
8841
8842
8843fi
8844ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8845#if HAVE_SYS_SOCKET_H
8846#include <sys/socket.h>
8847#endif
8848#if HAVE_NET_IF_H
8849#include <net/if.h>
8850#endif
8851"
a9bec17c 8852if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
067d23c9
KY
8853
8854cat >>confdefs.h <<_ACEOF
8855#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8856_ACEOF
8857
8858
8859fi
8860ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8861#if HAVE_SYS_SOCKET_H
8862#include <sys/socket.h>
8863#endif
8864#if HAVE_NET_IF_H
8865#include <net/if.h>
8866#endif
8867"
a9bec17c 8868if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
067d23c9
KY
8869
8870cat >>confdefs.h <<_ACEOF
8871#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8872_ACEOF
8873
8874
8875fi
8876ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8877#if HAVE_SYS_SOCKET_H
8878#include <sys/socket.h>
8879#endif
8880#if HAVE_NET_IF_H
8881#include <net/if.h>
8882#endif
8883"
a9bec17c 8884if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
067d23c9
KY
8885
8886cat >>confdefs.h <<_ACEOF
8887#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8888_ACEOF
8889
8890
7417b37c
GM
8891fi
8892ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
8893#if HAVE_SYS_SOCKET_H
8894#include <sys/socket.h>
8895#endif
8896#if HAVE_NET_IF_H
8897#include <net/if.h>
8898#endif
8899"
a9bec17c 8900if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
7417b37c
GM
8901
8902cat >>confdefs.h <<_ACEOF
8903#define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
8904_ACEOF
8905
8906
067d23c9
KY
8907fi
8908
8909
8910
8911{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
8912$as_echo_n "checking for function prototypes... " >&6; }
8913if test "$ac_cv_prog_cc_c89" != no; then
8914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8915$as_echo "yes" >&6; }
8916
8917$as_echo "#define PROTOTYPES 1" >>confdefs.h
8918
8919
8920$as_echo "#define __PROTOTYPES 1" >>confdefs.h
8921
8922else
8923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8924$as_echo "no" >&6; }
8925fi
8926
8927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
8928$as_echo_n "checking for working volatile... " >&6; }
a9bec17c 8929if test "${ac_cv_c_volatile+set}" = set; then :
067d23c9
KY
8930 $as_echo_n "(cached) " >&6
8931else
8932 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8933/* end confdefs.h. */
8934
8935int
8936main ()
8937{
8938
8939volatile int x;
8940int * volatile y = (int *) 0;
8941return !x && !y;
8942 ;
8943 return 0;
8944}
8945_ACEOF
8946if ac_fn_c_try_compile "$LINENO"; then :
8947 ac_cv_c_volatile=yes
8948else
8949 ac_cv_c_volatile=no
8950fi
8951rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8952fi
8953{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
8954$as_echo "$ac_cv_c_volatile" >&6; }
8955if test $ac_cv_c_volatile = no; then
8956
8957$as_echo "#define volatile /**/" >>confdefs.h
8958
8959fi
8960
8961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
8962$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
a9bec17c 8963if test "${ac_cv_c_const+set}" = set; then :
067d23c9
KY
8964 $as_echo_n "(cached) " >&6
8965else
8966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8967/* end confdefs.h. */
8968
8969int
8970main ()
8971{
8972/* FIXME: Include the comments suggested by Paul. */
8973#ifndef __cplusplus
8974 /* Ultrix mips cc rejects this. */
8975 typedef int charset[2];
8976 const charset cs;
8977 /* SunOS 4.1.1 cc rejects this. */
8978 char const *const *pcpcc;
8979 char **ppc;
8980 /* NEC SVR4.0.2 mips cc rejects this. */
8981 struct point {int x, y;};
8982 static struct point const zero = {0,0};
8983 /* AIX XL C 1.02.0.0 rejects this.
8984 It does not let you subtract one const X* pointer from another in
8985 an arm of an if-expression whose if-part is not a constant
8986 expression */
8987 const char *g = "string";
8988 pcpcc = &g + (g ? g-g : 0);
8989 /* HPUX 7.0 cc rejects these. */
8990 ++pcpcc;
8991 ppc = (char**) pcpcc;
8992 pcpcc = (char const *const *) ppc;
8993 { /* SCO 3.2v4 cc rejects this. */
8994 char *t;
8995 char const *s = 0 ? (char *) 0 : (char const *) 0;
8996
8997 *t++ = 0;
8998 if (s) return 0;
8999 }
9000 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
9001 int x[] = {25, 17};
9002 const int *foo = &x[0];
9003 ++foo;
9004 }
9005 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9006 typedef const int *iptr;
9007 iptr p = 0;
9008 ++p;
9009 }
9010 { /* AIX XL C 1.02.0.0 rejects this saying
9011 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9012 struct s { int j; const int *ap[3]; };
9013 struct s *b; b->j = 5;
9014 }
9015 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9016 const int foo = 10;
9017 if (!foo) return 0;
9018 }
9019 return !cs[0] && !zero.x;
9020#endif
9021
9022 ;
9023 return 0;
9024}
9025_ACEOF
9026if ac_fn_c_try_compile "$LINENO"; then :
9027 ac_cv_c_const=yes
9028else
9029 ac_cv_c_const=no
9030fi
9031rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9032fi
9033{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
9034$as_echo "$ac_cv_c_const" >&6; }
9035if test $ac_cv_c_const = no; then
9036
9037$as_echo "#define const /**/" >>confdefs.h
9038
9039fi
9040
9041{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
9042$as_echo_n "checking for void * support... " >&6; }
a9bec17c 9043if test "${emacs_cv_void_star+set}" = set; then :
067d23c9
KY
9044 $as_echo_n "(cached) " >&6
9045else
9046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9047/* end confdefs.h. */
9048
9049int
9050main ()
9051{
9052void * foo;
9053 ;
9054 return 0;
9055}
9056_ACEOF
9057if ac_fn_c_try_compile "$LINENO"; then :
9058 emacs_cv_void_star=yes
9059else
9060 emacs_cv_void_star=no
9061fi
9062rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9063fi
9064{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
9065$as_echo "$emacs_cv_void_star" >&6; }
9066if test $emacs_cv_void_star = yes; then
9067 $as_echo "#define POINTER_TYPE void" >>confdefs.h
9068
9069else
9070 $as_echo "#define POINTER_TYPE char" >>confdefs.h
9071
9072fi
9073
9074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9075$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
a9bec17c 9076if test "${ac_cv_c_bigendian+set}" = set; then :
067d23c9
KY
9077 $as_echo_n "(cached) " >&6
9078else
9079 ac_cv_c_bigendian=unknown
9080 # See if we're dealing with a universal compiler.
9081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9082/* end confdefs.h. */
9083#ifndef __APPLE_CC__
9084 not a universal capable compiler
9085 #endif
9086 typedef int dummy;
9087
9088_ACEOF
9089if ac_fn_c_try_compile "$LINENO"; then :
9090
9091 # Check for potential -arch flags. It is not universal unless
9092 # there are at least two -arch flags with different values.
9093 ac_arch=
9094 ac_prev=
9095 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9096 if test -n "$ac_prev"; then
9097 case $ac_word in
9098 i?86 | x86_64 | ppc | ppc64)
9099 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9100 ac_arch=$ac_word
9101 else
9102 ac_cv_c_bigendian=universal
9103 break
9104 fi
9105 ;;
9106 esac
9107 ac_prev=
9108 elif test "x$ac_word" = "x-arch"; then
9109 ac_prev=arch
9110 fi
9111 done
9112fi
9113rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9114 if test $ac_cv_c_bigendian = unknown; then
9115 # See if sys/param.h defines the BYTE_ORDER macro.
9116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9117/* end confdefs.h. */
9118#include <sys/types.h>
9119 #include <sys/param.h>
9120
9121int
9122main ()
9123{
9124#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9125 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9126 && LITTLE_ENDIAN)
9127 bogus endian macros
9128 #endif
9129
9130 ;
9131 return 0;
9132}
9133_ACEOF
9134if ac_fn_c_try_compile "$LINENO"; then :
9135 # It does; now see whether it defined to BIG_ENDIAN or not.
9136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9137/* end confdefs.h. */
9138#include <sys/types.h>
9139 #include <sys/param.h>
9140
9141int
9142main ()
9143{
9144#if BYTE_ORDER != BIG_ENDIAN
9145 not big endian
9146 #endif
9147
9148 ;
9149 return 0;
9150}
9151_ACEOF
9152if ac_fn_c_try_compile "$LINENO"; then :
9153 ac_cv_c_bigendian=yes
9154else
9155 ac_cv_c_bigendian=no
9156fi
9157rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9158fi
9159rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9160 fi
9161 if test $ac_cv_c_bigendian = unknown; then
9162 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9164/* end confdefs.h. */
9165#include <limits.h>
9166
9167int
9168main ()
9169{
9170#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9171 bogus endian macros
9172 #endif
9173
9174 ;
9175 return 0;
9176}
9177_ACEOF
9178if ac_fn_c_try_compile "$LINENO"; then :
9179 # It does; now see whether it defined to _BIG_ENDIAN or not.
9180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9181/* end confdefs.h. */
9182#include <limits.h>
9183
9184int
9185main ()
9186{
9187#ifndef _BIG_ENDIAN
9188 not big endian
9189 #endif
9190
9191 ;
9192 return 0;
9193}
9194_ACEOF
9195if ac_fn_c_try_compile "$LINENO"; then :
9196 ac_cv_c_bigendian=yes
9197else
9198 ac_cv_c_bigendian=no
9199fi
9200rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9201fi
9202rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9203 fi
9204 if test $ac_cv_c_bigendian = unknown; then
9205 # Compile a test program.
9206 if test "$cross_compiling" = yes; then :
9207 # Try to guess by grepping values from an object file.
9208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9209/* end confdefs.h. */
9210short int ascii_mm[] =
9211 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9212 short int ascii_ii[] =
9213 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9214 int use_ascii (int i) {
9215 return ascii_mm[i] + ascii_ii[i];
9216 }
9217 short int ebcdic_ii[] =
9218 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9219 short int ebcdic_mm[] =
9220 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9221 int use_ebcdic (int i) {
9222 return ebcdic_mm[i] + ebcdic_ii[i];
9223 }
9224 extern int foo;
9225
9226int
9227main ()
9228{
9229return use_ascii (foo) == use_ebcdic (foo);
9230 ;
9231 return 0;
9232}
9233_ACEOF
9234if ac_fn_c_try_compile "$LINENO"; then :
9235 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9236 ac_cv_c_bigendian=yes
9237 fi
9238 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9239 if test "$ac_cv_c_bigendian" = unknown; then
9240 ac_cv_c_bigendian=no
9241 else
9242 # finding both strings is unlikely to happen, but who knows?
9243 ac_cv_c_bigendian=unknown
9244 fi
9245 fi
9246fi
9247rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9248else
9249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9250/* end confdefs.h. */
9251$ac_includes_default
9252int
9253main ()
9254{
9255
9256 /* Are we little or big endian? From Harbison&Steele. */
9257 union
9258 {
9259 long int l;
9260 char c[sizeof (long int)];
9261 } u;
9262 u.l = 1;
9263 return u.c[sizeof (long int) - 1] == 1;
9264
9265 ;
9266 return 0;
9267}
9268_ACEOF
9269if ac_fn_c_try_run "$LINENO"; then :
9270 ac_cv_c_bigendian=no
9271else
9272 ac_cv_c_bigendian=yes
9273fi
9274rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9275 conftest.$ac_objext conftest.beam conftest.$ac_ext
9276fi
9277
9278 fi
9279fi
9280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9281$as_echo "$ac_cv_c_bigendian" >&6; }
9282 case $ac_cv_c_bigendian in #(
9283 yes)
9284 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9285;; #(
9286 no)
9287 ;; #(
9288 universal)
9289
9290$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9291
9292 ;; #(
9293 *)
a9bec17c 9294 as_fn_error "unknown endianness
0afb4571 9295 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
067d23c9
KY
9296 esac
9297
9298
7cae64b4
PE
9299{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__ ((__aligned__ (expr)))" >&5
9300$as_echo_n "checking for __attribute__ ((__aligned__ (expr)))... " >&6; }
a9bec17c 9301if test "${emacs_cv_attribute_aligned+set}" = set; then :
7cae64b4
PE
9302 $as_echo_n "(cached) " >&6
9303else
9304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9305/* end confdefs.h. */
9306char __attribute__ ((__aligned__ (1 << 3))) c;
9307int
9308main ()
9309{
9310
9311 ;
9312 return 0;
9313}
9314_ACEOF
9315if ac_fn_c_try_compile "$LINENO"; then :
9316 emacs_cv_attribute_aligned=yes
9317else
9318 emacs_cv_attribute_aligned=no
9319fi
9320rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9321fi
9322{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_attribute_aligned" >&5
9323$as_echo "$emacs_cv_attribute_aligned" >&6; }
9324if test $emacs_cv_attribute_aligned = yes; then
9325
9326$as_echo "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h
9327
9328fi
9329
067d23c9
KY
9330{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
9331$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
9332set x ${MAKE-make}
9333ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
a9bec17c 9334if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
067d23c9
KY
9335 $as_echo_n "(cached) " >&6
9336else
9337 cat >conftest.make <<\_ACEOF
9338SHELL = /bin/sh
9339all:
9340 @echo '@@@%%%=$(MAKE)=@@@%%%'
9341_ACEOF
a9bec17c 9342# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
067d23c9
KY
9343case `${MAKE-make} -f conftest.make 2>/dev/null` in
9344 *@@@%%%=?*=@@@%%%*)
9345 eval ac_cv_prog_make_${ac_make}_set=yes;;
9346 *)
9347 eval ac_cv_prog_make_${ac_make}_set=no;;
9348esac
9349rm -f conftest.make
9350fi
9351if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
9352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9353$as_echo "yes" >&6; }
9354 SET_MAKE=
9355else
9356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9357$as_echo "no" >&6; }
9358 SET_MAKE="MAKE=${MAKE-make}"
9359fi
9360
9361
9362DEPFLAGS=
9363MKDEPDIR=":"
9364deps_frag=deps.mk
9365if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9367$as_echo_n "checking whether we are using GNU Make... " >&6; }
9368 HAVE_GNU_MAKE=no
3d0788a9 9369 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
067d23c9
KY
9370 if test "x$testval" != x; then
9371 HAVE_GNU_MAKE=yes
9372 else
9373 ac_enable_autodepend=no
9374 fi
9375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9376$as_echo "$HAVE_GNU_MAKE" >&6; }
9377 if test $HAVE_GNU_MAKE = yes; then
9378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9379$as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9380 SAVE_CFLAGS="$CFLAGS"
37846983 9381 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
067d23c9
KY
9382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9383/* end confdefs.h. */
9384
9385int
9386main ()
9387{
9388
9389 ;
9390 return 0;
9391}
9392_ACEOF
9393if ac_fn_c_try_compile "$LINENO"; then :
9394
9395else
9396 ac_enable_autodepend=no
9397fi
9398rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9399 CFLAGS="$SAVE_CFLAGS"
9400 test -f deps.d || ac_enable_autodepend=no
9401 rm -rf deps.d
9402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9403$as_echo "$ac_enable_autodepend" >&6; }
9404 fi
9405 if test $ac_enable_autodepend = yes; then
37846983 9406 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
067d23c9
KY
9407 ## In parallel builds, another make might create depdir between
9408 ## the first test and mkdir, so stick another test on the end.
6ad6792b 9409 ## Or use install-sh -d? mkdir -p is not portable.
067d23c9
KY
9410 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
9411 deps_frag=autodeps.mk
9412 fi
9413fi
9414deps_frag=$srcdir/src/$deps_frag
9415
9416
9417
9418
9419
4d4b75e8
GM
9420lisp_frag=$srcdir/src/lisp.mk
9421
9422
9423
067d23c9
KY
9424{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9425$as_echo_n "checking for long file names... " >&6; }
a9bec17c 9426if test "${ac_cv_sys_long_file_names+set}" = set; then :
067d23c9
KY
9427 $as_echo_n "(cached) " >&6
9428else
9429 ac_cv_sys_long_file_names=yes
9430# Test for long file names in all the places we know might matter:
9431# . the current directory, where building will happen
9432# $prefix/lib where we will be installing things
9433# $exec_prefix/lib likewise
9434# $TMPDIR if set, where it might want to write temporary files
9435# /tmp where it might want to write temporary files
9436# /var/tmp likewise
9437# /usr/tmp likewise
9438for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9439 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9440 # in the usual case where exec_prefix is '${prefix}'.
9441 case $ac_dir in #(
9442 . | /* | ?:[\\/]*) ;; #(
9443 *) continue;;
9444 esac
9445 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9446 ac_xdir=$ac_dir/cf$$
9447 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9448 ac_tf1=$ac_xdir/conftest9012345
9449 ac_tf2=$ac_xdir/conftest9012346
9450 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9451 ac_cv_sys_long_file_names=no
9452 rm -f -r "$ac_xdir" 2>/dev/null
9453 test $ac_cv_sys_long_file_names = no && break
9454done
9455fi
9456{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9457$as_echo "$ac_cv_sys_long_file_names" >&6; }
9458if test $ac_cv_sys_long_file_names = yes; then
9459
9460$as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9461
9462fi
9463
9464
9465#### Choose a window system.
9466
9467{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9468$as_echo_n "checking for X... " >&6; }
9469
9470
9471# Check whether --with-x was given.
9472if test "${with_x+set}" = set; then :
9473 withval=$with_x;
9474fi
9475
9476# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9477if test "x$with_x" = xno; then
9478 # The user explicitly disabled X.
9479 have_x=disabled
9480else
9481 case $x_includes,$x_libraries in #(
a9bec17c
GM
9482 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9483 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
067d23c9
KY
9484 $as_echo_n "(cached) " >&6
9485else
9486 # One or both of the vars are not set, and there is no cached value.
9487ac_x_includes=no ac_x_libraries=no
9488rm -f -r conftest.dir
9489if mkdir conftest.dir; then
9490 cd conftest.dir
9491 cat >Imakefile <<'_ACEOF'
9492incroot:
9493 @echo incroot='${INCROOT}'
9494usrlibdir:
9495 @echo usrlibdir='${USRLIBDIR}'
9496libdir:
9497 @echo libdir='${LIBDIR}'
9498_ACEOF
9499 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
a9bec17c 9500 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
067d23c9
KY
9501 for ac_var in incroot usrlibdir libdir; do
9502 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9503 done
9504 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9505 for ac_extension in a so sl dylib la dll; do
9506 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9507 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9508 ac_im_usrlibdir=$ac_im_libdir; break
9509 fi
9510 done
9511 # Screen out bogus values from the imake configuration. They are
9512 # bogus both because they are the default anyway, and because
9513 # using them would break gcc on systems where it needs fixed includes.
9514 case $ac_im_incroot in
9515 /usr/include) ac_x_includes= ;;
9516 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9517 esac
9518 case $ac_im_usrlibdir in
9519 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9520 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9521 esac
9522 fi
9523 cd ..
9524 rm -f -r conftest.dir
9525fi
9526
9527# Standard set of common directories for X headers.
9528# Check X11 before X11Rn because it is often a symlink to the current release.
9529ac_x_header_dirs='
9530/usr/X11/include
9531/usr/X11R7/include
9532/usr/X11R6/include
9533/usr/X11R5/include
9534/usr/X11R4/include
9535
9536/usr/include/X11
9537/usr/include/X11R7
9538/usr/include/X11R6
9539/usr/include/X11R5
9540/usr/include/X11R4
9541
9542/usr/local/X11/include
9543/usr/local/X11R7/include
9544/usr/local/X11R6/include
9545/usr/local/X11R5/include
9546/usr/local/X11R4/include
9547
9548/usr/local/include/X11
9549/usr/local/include/X11R7
9550/usr/local/include/X11R6
9551/usr/local/include/X11R5
9552/usr/local/include/X11R4
9553
9554/usr/X386/include
9555/usr/x386/include
9556/usr/XFree86/include/X11
9557
9558/usr/include
9559/usr/local/include
9560/usr/unsupported/include
9561/usr/athena/include
9562/usr/local/x11r5/include
9563/usr/lpp/Xamples/include
9564
9565/usr/openwin/include
9566/usr/openwin/share/include'
9567
9568if test "$ac_x_includes" = no; then
9569 # Guess where to find include files, by looking for Xlib.h.
9570 # First, try using that file with no special directory specified.
9571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9572/* end confdefs.h. */
9573#include <X11/Xlib.h>
9574_ACEOF
9575if ac_fn_c_try_cpp "$LINENO"; then :
9576 # We can compile using X headers with no special include directory.
9577ac_x_includes=
9578else
9579 for ac_dir in $ac_x_header_dirs; do
9580 if test -r "$ac_dir/X11/Xlib.h"; then
9581 ac_x_includes=$ac_dir
9582 break
9583 fi
9584done
9585fi
a9bec17c 9586rm -f conftest.err conftest.$ac_ext
067d23c9
KY
9587fi # $ac_x_includes = no
9588
9589if test "$ac_x_libraries" = no; then
9590 # Check for the libraries.
9591 # See if we find them without any special options.
9592 # Don't add to $LIBS permanently.
9593 ac_save_LIBS=$LIBS
9594 LIBS="-lX11 $LIBS"
9595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9596/* end confdefs.h. */
9597#include <X11/Xlib.h>
9598int
9599main ()
9600{
9601XrmInitialize ()
9602 ;
9603 return 0;
9604}
9605_ACEOF
9606if ac_fn_c_try_link "$LINENO"; then :
9607 LIBS=$ac_save_LIBS
9608# We can link X programs with no special library path.
9609ac_x_libraries=
9610else
9611 LIBS=$ac_save_LIBS
9612for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9613do
9614 # Don't even attempt the hair of trying to link an X program!
9615 for ac_extension in a so sl dylib la dll; do
9616 if test -r "$ac_dir/libX11.$ac_extension"; then
9617 ac_x_libraries=$ac_dir
9618 break 2
9619 fi
9620 done
9621done
9622fi
9623rm -f core conftest.err conftest.$ac_objext \
9624 conftest$ac_exeext conftest.$ac_ext
9625fi # $ac_x_libraries = no
9626
9627case $ac_x_includes,$ac_x_libraries in #(
9628 no,* | *,no | *\'*)
9629 # Didn't find X, or a directory has "'" in its name.
9630 ac_cv_have_x="have_x=no";; #(
9631 *)
9632 # Record where we found X for the cache.
9633 ac_cv_have_x="have_x=yes\
9634 ac_x_includes='$ac_x_includes'\
9635 ac_x_libraries='$ac_x_libraries'"
9636esac
9637fi
9638;; #(
9639 *) have_x=yes;;
9640 esac
9641 eval "$ac_cv_have_x"
9642fi # $with_x != no
9643
9644if test "$have_x" != yes; then
9645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9646$as_echo "$have_x" >&6; }
9647 no_x=yes
9648else
9649 # If each of the values was on the command line, it overrides each guess.
9650 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9651 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9652 # Update the cache value to reflect the command line values.
9653 ac_cv_have_x="have_x=yes\
9654 ac_x_includes='$x_includes'\
9655 ac_x_libraries='$x_libraries'"
9656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9657$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9658fi
9659
9660if test "$no_x" = yes; then
9661 window_system=none
9662else
9663 window_system=x11
9664fi
9665
9666## Workaround for bug in autoconf <= 2.62.
9667## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
9668## No need to do anything special for these standard directories.
9669if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
9670
9671 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
9672
9673fi
9674
9675LD_SWITCH_X_SITE_AUX=
9676LD_SWITCH_X_SITE_AUX_RPATH=
9677if test "${x_libraries}" != NONE; then
9678 if test -n "${x_libraries}"; then
9679 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9680 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
9681 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
9682 fi
9683 x_default_search_path=""
9684 x_search_path=${x_libraries}
9685 if test -z "${x_search_path}"; then
9686 x_search_path=/usr/lib
9687 fi
9688 for x_library in `echo ${x_search_path}: | \
9689 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9690 x_search_path="\
9691${x_library}/X11/%L/%T/%N%C%S:\
9692${x_library}/X11/%l/%T/%N%C%S:\
9693${x_library}/X11/%T/%N%C%S:\
9694${x_library}/X11/%L/%T/%N%S:\
9695${x_library}/X11/%l/%T/%N%S:\
9696${x_library}/X11/%T/%N%S"
9697 if test x"${x_default_search_path}" = x; then
9698 x_default_search_path=${x_search_path}
9699 else
9700 x_default_search_path="${x_search_path}:${x_default_search_path}"
9701 fi
9702 done
9703fi
9704
9705
9706
9707if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9708 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
9709fi
9710
9711if test x"${x_includes}" = x; then
9712 bitmapdir=/usr/include/X11/bitmaps
9713else
9714 # accumulate include directories that have X11 bitmap subdirectories
9715 bmd_acc="dummyval"
9716 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9717 if test -d "${bmd}/X11/bitmaps"; then
9718 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9719 fi
9720 if test -d "${bmd}/bitmaps"; then
9721 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9722 fi
9723 done
9724 if test ${bmd_acc} != "dummyval"; then
9725 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9726 fi
9727fi
9728
9729HAVE_NS=no
9730NS_IMPL_COCOA=no
9731NS_IMPL_GNUSTEP=no
9732tmp_CPPFLAGS="$CPPFLAGS"
9733tmp_CFLAGS="$CFLAGS"
9734CPPFLAGS="$CPPFLAGS -x objective-c"
9735CFLAGS="$CFLAGS -x objective-c"
9736TEMACS_LDFLAGS2="\${LDFLAGS}"
39b3d70b 9737GNU_OBJC_CFLAGS=
067d23c9
KY
9738if test "${with_ns}" != no; then
9739 if test "${opsys}" = darwin; then
9740 NS_IMPL_COCOA=yes
9741 ns_appdir=`pwd`/nextstep/Emacs.app
9742 ns_appbindir=${ns_appdir}/Contents/MacOS/
9743 ns_appresdir=${ns_appdir}/Contents/Resources
9744 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9745 elif test -f $GNUSTEP_CONFIG_FILE; then
9746 NS_IMPL_GNUSTEP=yes
9747 ns_appdir=`pwd`/nextstep/Emacs.app
9748 ns_appbindir=${ns_appdir}/
9749 ns_appresdir=${ns_appdir}/Resources
9750 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9751 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9752 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9753 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9754 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9755 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9756 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9757 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9758 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9759 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9760 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9761 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9762 LIB_STANDARD=
9763 START_FILES=
9764 TEMACS_LDFLAGS2=
39b3d70b
GM
9765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9766$as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9767if test "${emacs_cv_objc_exceptions+set}" = set; then :
9768 $as_echo_n "(cached) " >&6
9769else
9770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9771/* end confdefs.h. */
9772#include <GNUstepBase/GSConfig.h>
9773int
9774main ()
9775{
9776#if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
97771;
9778#else
9779fail;
9780#endif
9781 ;
9782 return 0;
9783}
9784_ACEOF
9785if ac_fn_c_try_compile "$LINENO"; then :
9786 emacs_cv_objc_exceptions=yes
9787else
9788 emacs_cv_objc_exceptions=no
9789fi
9790rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9791fi
9792{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9793$as_echo "$emacs_cv_objc_exceptions" >&6; }
9794 if test $emacs_cv_objc_exceptions = yes; then
9795
9796$as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9797
9798 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9799 fi
067d23c9 9800 fi
39b3d70b
GM
9801
9802 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9803
067d23c9 9804 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
a9bec17c 9805if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
067d23c9
KY
9806 HAVE_NS=yes
9807else
a9bec17c 9808 as_fn_error "\`--with-ns' was specified, but the include
067d23c9
KY
9809 files are missing or cannot be compiled." "$LINENO" 5
9810fi
9811
9812
9813 NS_HAVE_NSINTEGER=yes
9814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9815/* end confdefs.h. */
9816#include <Foundation/NSObjCRuntime.h>
9817int
9818main ()
9819{
9820NSInteger i;
9821 ;
9822 return 0;
9823}
9824_ACEOF
9825if ac_fn_c_try_compile "$LINENO"; then :
9826 ns_have_nsinteger=yes
9827else
9828 ns_have_nsinteger=no
9829fi
9830rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9831 if test $ns_have_nsinteger = no; then
9832 NS_HAVE_NSINTEGER=no
9833 fi
9834fi
9835
9836
9837ns_frag=/dev/null
9838NS_OBJ=
00b3c7ac 9839NS_OBJC_OBJ=
067d23c9 9840if test "${HAVE_NS}" = yes; then
002cc2e1 9841 if test "$with_toolkit_scroll_bars" = "no"; then
f52bac22 9842 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
002cc2e1
GM
9843 fi
9844
067d23c9
KY
9845 window_system=nextstep
9846 with_xft=no
9847 # set up packaging dirs
067d23c9
KY
9848 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9849 prefix=${ns_appresdir}
eb39a72d
GM
9850 exec_prefix=${ns_appbindir}
9851 libexecdir=${ns_appbindir}/libexec
067d23c9
KY
9852 fi
9853 ns_frag=$srcdir/src/ns.mk
00b3c7ac
TT
9854 NS_OBJ="fontset.o fringe.o image.o"
9855 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
067d23c9
KY
9856fi
9857CFLAGS="$tmp_CFLAGS"
9858CPPFLAGS="$tmp_CPPFLAGS"
9859
9860
9861
9862
9863
9864case "${window_system}" in
9865 x11 )
9866 HAVE_X_WINDOWS=yes
9867 HAVE_X11=yes
9868 case "${with_x_toolkit}" in
9869 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9870 motif ) USE_X_TOOLKIT=MOTIF ;;
9871 gtk ) with_gtk=yes
9872 USE_X_TOOLKIT=none ;;
9873 gtk3 ) with_gtk3=yes
9874 USE_X_TOOLKIT=none ;;
9875 no ) USE_X_TOOLKIT=none ;;
9876 * ) USE_X_TOOLKIT=maybe ;;
9877 esac
9878 ;;
9879 nextstep | none )
9880 HAVE_X_WINDOWS=no
9881 HAVE_X11=no
9882 USE_X_TOOLKIT=none
9883 ;;
9884esac
9885
9886if test "$window_system" = none && test "X$with_x" != "Xno"; then
9887 # Extract the first word of "X", so it can be a program name with args.
9888set dummy X; ac_word=$2
9889{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9890$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 9891if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
067d23c9
KY
9892 $as_echo_n "(cached) " >&6
9893else
9894 if test -n "$HAVE_XSERVER"; then
9895 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9896else
9897as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9898for as_dir in $PATH
9899do
9900 IFS=$as_save_IFS
9901 test -z "$as_dir" && as_dir=.
9902 for ac_exec_ext in '' $ac_executable_extensions; do
9903 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9904 ac_cv_prog_HAVE_XSERVER="true"
9905 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9906 break 2
9907 fi
9908done
9909 done
9910IFS=$as_save_IFS
9911
9912 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9913fi
9914fi
9915HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9916if test -n "$HAVE_XSERVER"; then
9917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9918$as_echo "$HAVE_XSERVER" >&6; }
9919else
9920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9921$as_echo "no" >&6; }
9922fi
9923
9924
9925 if test "$HAVE_XSERVER" = true ||
9926 test -n "$DISPLAY" ||
9927 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
a9bec17c 9928 as_fn_error "You seem to be running X, but no X development libraries
067d23c9
KY
9929were found. You should install the relevant development files for X
9930and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9931sure you have development files for image handling, i.e.
9932tiff, gif, jpeg, png and xpm.
9933If you are sure you want Emacs compiled without X window support, pass
9934 --without-x
9935to configure." "$LINENO" 5
9936 fi
9937fi
9938
9939### If we're using X11, we should use the X menu package.
9940HAVE_MENUS=no
9941case ${HAVE_X11} in
9942 yes ) HAVE_MENUS=yes ;;
9943esac
9944
9945# Do the opsystem or machine files prohibit the use of the GNU malloc?
9946# Assume not, until told otherwise.
9947GNU_MALLOC=yes
9948doug_lea_malloc=yes
9949ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
a9bec17c 9950if test "x$ac_cv_func_malloc_get_state" = x""yes; then :
067d23c9
KY
9951
9952else
9953 doug_lea_malloc=no
9954fi
9955
9956ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
a9bec17c 9957if test "x$ac_cv_func_malloc_set_state" = x""yes; then :
067d23c9
KY
9958
9959else
9960 doug_lea_malloc=no
9961fi
9962
9963{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
9964$as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
a9bec17c 9965if test "${emacs_cv_var___after_morecore_hook+set}" = set; then :
067d23c9
KY
9966 $as_echo_n "(cached) " >&6
9967else
9968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9969/* end confdefs.h. */
9970extern void (* __after_morecore_hook)();
9971int
9972main ()
9973{
9974__after_morecore_hook = 0
9975 ;
9976 return 0;
9977}
9978_ACEOF
9979if ac_fn_c_try_link "$LINENO"; then :
9980 emacs_cv_var___after_morecore_hook=yes
9981else
9982 emacs_cv_var___after_morecore_hook=no
9983fi
9984rm -f core conftest.err conftest.$ac_objext \
9985 conftest$ac_exeext conftest.$ac_ext
9986fi
9987{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
9988$as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
9989if test $emacs_cv_var___after_morecore_hook = no; then
9990 doug_lea_malloc=no
9991fi
9992
9993
9994system_malloc=no
9995case "$opsys" in
9996 ## darwin ld insists on the use of malloc routines in the System framework.
9997 darwin|sol2-10) system_malloc=yes ;;
9998esac
9999
10000if test "${system_malloc}" = "yes"; then
10001
10002$as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10003
10004 GNU_MALLOC=no
10005 GNU_MALLOC_reason="
10006 (The GNU allocators don't work with this system configuration.)"
10007 GMALLOC_OBJ=
10008 VMLIMIT_OBJ=
10009else
10010 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10011 VMLIMIT_OBJ=vm-limit.o
10012fi
10013
10014
10015
10016if test "$doug_lea_malloc" = "yes" ; then
10017 if test "$GNU_MALLOC" = yes ; then
10018 GNU_MALLOC_reason="
10019 (Using Doug Lea's new malloc from the GNU C Library.)"
10020 fi
10021
10022$as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10023
10024
10025 ## Use mmap directly for allocating larger buffers.
10026 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10027 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
b6d6d607 10028 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
067d23c9
KY
10029 case "$opsys" in
10030 gnu*) REL_ALLOC=no ;;
10031 esac
10032fi
10033
10034if test x"${REL_ALLOC}" = x; then
10035 REL_ALLOC=${GNU_MALLOC}
10036fi
10037
10038use_mmap_for_buffers=no
10039case "$opsys" in
e7dcef2a 10040 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
067d23c9
KY
10041esac
10042
10043
10044
10045
10046 for ac_header in $ac_header_list
10047do :
10048 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10049ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10050"
a9bec17c
GM
10051eval as_val=\$$as_ac_Header
10052 if test "x$as_val" = x""yes; then :
067d23c9
KY
10053 cat >>confdefs.h <<_ACEOF
10054#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10055_ACEOF
10056
10057fi
10058
10059done
10060
10061
10062
10063
10064
10065
10066
10067
10068for ac_func in getpagesize
10069do :
10070 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
a9bec17c 10071if test "x$ac_cv_func_getpagesize" = x""yes; then :
067d23c9
KY
10072 cat >>confdefs.h <<_ACEOF
10073#define HAVE_GETPAGESIZE 1
10074_ACEOF
10075
10076fi
10077done
10078
10079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10080$as_echo_n "checking for working mmap... " >&6; }
a9bec17c 10081if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
067d23c9
KY
10082 $as_echo_n "(cached) " >&6
10083else
10084 if test "$cross_compiling" = yes; then :
10085 ac_cv_func_mmap_fixed_mapped=no
10086else
10087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10088/* end confdefs.h. */
10089$ac_includes_default
10090/* malloc might have been renamed as rpl_malloc. */
10091#undef malloc
10092
10093/* Thanks to Mike Haertel and Jim Avera for this test.
10094 Here is a matrix of mmap possibilities:
10095 mmap private not fixed
10096 mmap private fixed at somewhere currently unmapped
10097 mmap private fixed at somewhere already mapped
10098 mmap shared not fixed
10099 mmap shared fixed at somewhere currently unmapped
10100 mmap shared fixed at somewhere already mapped
10101 For private mappings, we should verify that changes cannot be read()
10102 back from the file, nor mmap's back from the file at a different
10103 address. (There have been systems where private was not correctly
10104 implemented like the infamous i386 svr4.0, and systems where the
10105 VM page cache was not coherent with the file system buffer cache
10106 like early versions of FreeBSD and possibly contemporary NetBSD.)
10107 For shared mappings, we should conversely verify that changes get
10108 propagated back to all the places they're supposed to be.
10109
10110 Grep wants private fixed already mapped.
10111 The main things grep needs to know about mmap are:
10112 * does it exist and is it safe to write into the mmap'd area
10113 * how to use it (BSD variants) */
10114
10115#include <fcntl.h>
10116#include <sys/mman.h>
10117
10118#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10119char *malloc ();
10120#endif
10121
10122/* This mess was copied from the GNU getpagesize.h. */
10123#ifndef HAVE_GETPAGESIZE
10124# ifdef _SC_PAGESIZE
10125# define getpagesize() sysconf(_SC_PAGESIZE)
10126# else /* no _SC_PAGESIZE */
10127# ifdef HAVE_SYS_PARAM_H
10128# include <sys/param.h>
10129# ifdef EXEC_PAGESIZE
10130# define getpagesize() EXEC_PAGESIZE
10131# else /* no EXEC_PAGESIZE */
10132# ifdef NBPG
10133# define getpagesize() NBPG * CLSIZE
10134# ifndef CLSIZE
10135# define CLSIZE 1
10136# endif /* no CLSIZE */
10137# else /* no NBPG */
10138# ifdef NBPC
10139# define getpagesize() NBPC
10140# else /* no NBPC */
10141# ifdef PAGESIZE
10142# define getpagesize() PAGESIZE
10143# endif /* PAGESIZE */
10144# endif /* no NBPC */
10145# endif /* no NBPG */
10146# endif /* no EXEC_PAGESIZE */
10147# else /* no HAVE_SYS_PARAM_H */
10148# define getpagesize() 8192 /* punt totally */
10149# endif /* no HAVE_SYS_PARAM_H */
10150# endif /* no _SC_PAGESIZE */
10151
10152#endif /* no HAVE_GETPAGESIZE */
10153
10154int
10155main ()
10156{
10157 char *data, *data2, *data3;
1ef6de05 10158 const char *cdata2;
067d23c9
KY
10159 int i, pagesize;
10160 int fd, fd2;
10161
10162 pagesize = getpagesize ();
10163
10164 /* First, make a file with some known garbage in it. */
10165 data = (char *) malloc (pagesize);
10166 if (!data)
10167 return 1;
10168 for (i = 0; i < pagesize; ++i)
10169 *(data + i) = rand ();
10170 umask (0);
10171 fd = creat ("conftest.mmap", 0600);
10172 if (fd < 0)
10173 return 2;
10174 if (write (fd, data, pagesize) != pagesize)
10175 return 3;
10176 close (fd);
10177
10178 /* Next, check that the tail of a page is zero-filled. File must have
10179 non-zero length, otherwise we risk SIGBUS for entire page. */
10180 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10181 if (fd2 < 0)
10182 return 4;
1ef6de05
PE
10183 cdata2 = "";
10184 if (write (fd2, cdata2, 1) != 1)
067d23c9 10185 return 5;
1ef6de05 10186 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
067d23c9
KY
10187 if (data2 == MAP_FAILED)
10188 return 6;
10189 for (i = 0; i < pagesize; ++i)
10190 if (*(data2 + i))
10191 return 7;
10192 close (fd2);
10193 if (munmap (data2, pagesize))
10194 return 8;
10195
10196 /* Next, try to mmap the file at a fixed address which already has
10197 something else allocated at it. If we can, also make sure that
10198 we see the same garbage. */
10199 fd = open ("conftest.mmap", O_RDWR);
10200 if (fd < 0)
10201 return 9;
10202 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10203 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10204 return 10;
10205 for (i = 0; i < pagesize; ++i)
10206 if (*(data + i) != *(data2 + i))
10207 return 11;
10208
10209 /* Finally, make sure that changes to the mapped area do not
10210 percolate back to the file as seen by read(). (This is a bug on
10211 some variants of i386 svr4.0.) */
10212 for (i = 0; i < pagesize; ++i)
10213 *(data2 + i) = *(data2 + i) + 1;
10214 data3 = (char *) malloc (pagesize);
10215 if (!data3)
10216 return 12;
10217 if (read (fd, data3, pagesize) != pagesize)
10218 return 13;
10219 for (i = 0; i < pagesize; ++i)
10220 if (*(data + i) != *(data3 + i))
10221 return 14;
10222 close (fd);
10223 return 0;
10224}
10225_ACEOF
10226if ac_fn_c_try_run "$LINENO"; then :
10227 ac_cv_func_mmap_fixed_mapped=yes
10228else
10229 ac_cv_func_mmap_fixed_mapped=no
10230fi
10231rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10232 conftest.$ac_objext conftest.beam conftest.$ac_ext
10233fi
10234
10235fi
10236{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10237$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10238if test $ac_cv_func_mmap_fixed_mapped = yes; then
10239
10240$as_echo "#define HAVE_MMAP 1" >>confdefs.h
10241
10242fi
10243rm -f conftest.mmap conftest.txt
10244
10245if test $use_mmap_for_buffers = yes; then
10246
10247$as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10248
10249 REL_ALLOC=no
10250fi
10251
10252LIBS="$LIBS_SYSTEM $LIBS"
10253
10254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10255$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
a9bec17c 10256if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
067d23c9
KY
10257 $as_echo_n "(cached) " >&6
10258else
10259 ac_check_lib_save_LIBS=$LIBS
10260LIBS="-ldnet $LIBS"
10261cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10262/* end confdefs.h. */
10263
10264/* Override any GCC internal prototype to avoid an error.
10265 Use char because int might match the return type of a GCC
10266 builtin and then its argument prototype would still apply. */
10267#ifdef __cplusplus
10268extern "C"
10269#endif
10270char dnet_ntoa ();
10271int
10272main ()
10273{
10274return dnet_ntoa ();
10275 ;
10276 return 0;
10277}
10278_ACEOF
10279if ac_fn_c_try_link "$LINENO"; then :
10280 ac_cv_lib_dnet_dnet_ntoa=yes
10281else
10282 ac_cv_lib_dnet_dnet_ntoa=no
10283fi
10284rm -f core conftest.err conftest.$ac_objext \
10285 conftest$ac_exeext conftest.$ac_ext
10286LIBS=$ac_check_lib_save_LIBS
10287fi
10288{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10289$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
a9bec17c 10290if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
067d23c9
KY
10291 cat >>confdefs.h <<_ACEOF
10292#define HAVE_LIBDNET 1
10293_ACEOF
10294
10295 LIBS="-ldnet $LIBS"
10296
10297fi
10298
10299
10300{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10301$as_echo_n "checking for main in -lXbsd... " >&6; }
a9bec17c 10302if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
067d23c9
KY
10303 $as_echo_n "(cached) " >&6
10304else
10305 ac_check_lib_save_LIBS=$LIBS
10306LIBS="-lXbsd $LIBS"
10307cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10308/* end confdefs.h. */
10309
10310
10311int
10312main ()
10313{
10314return main ();
10315 ;
10316 return 0;
10317}
10318_ACEOF
10319if ac_fn_c_try_link "$LINENO"; then :
10320 ac_cv_lib_Xbsd_main=yes
10321else
10322 ac_cv_lib_Xbsd_main=no
10323fi
10324rm -f core conftest.err conftest.$ac_objext \
10325 conftest$ac_exeext conftest.$ac_ext
10326LIBS=$ac_check_lib_save_LIBS
10327fi
10328{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10329$as_echo "$ac_cv_lib_Xbsd_main" >&6; }
a9bec17c 10330if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
067d23c9
KY
10331 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10332fi
10333
10334
1abfdc54
GM
10335LIB_PTHREAD=
10336for ac_header in pthread.h
10337do :
10338 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
a9bec17c 10339if test "x$ac_cv_header_pthread_h" = x""yes; then :
1abfdc54
GM
10340 cat >>confdefs.h <<_ACEOF
10341#define HAVE_PTHREAD_H 1
10342_ACEOF
10343
10344fi
10345
10346done
10347
10348if test "$ac_cv_header_pthread_h"; then
e1fefc61
GM
10349 if test "$GMALLOC_OBJ" = gmalloc.o; then
10350 emacs_pthread_function=pthread_atfork
10351 else
10352 emacs_pthread_function=pthread_self
10353 fi
10354 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10355{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10356$as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10357if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
1abfdc54
GM
10358 $as_echo_n "(cached) " >&6
10359else
10360 ac_check_lib_save_LIBS=$LIBS
10361LIBS="-lpthread $LIBS"
10362cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10363/* end confdefs.h. */
10364
10365/* Override any GCC internal prototype to avoid an error.
10366 Use char because int might match the return type of a GCC
10367 builtin and then its argument prototype would still apply. */
10368#ifdef __cplusplus
10369extern "C"
10370#endif
e1fefc61 10371char $emacs_pthread_function ();
1abfdc54
GM
10372int
10373main ()
10374{
e1fefc61 10375return $emacs_pthread_function ();
1abfdc54
GM
10376 ;
10377 return 0;
10378}
10379_ACEOF
10380if ac_fn_c_try_link "$LINENO"; then :
e1fefc61 10381 eval "$as_ac_Lib=yes"
1abfdc54 10382else
e1fefc61 10383 eval "$as_ac_Lib=no"
1abfdc54
GM
10384fi
10385rm -f core conftest.err conftest.$ac_objext \
10386 conftest$ac_exeext conftest.$ac_ext
10387LIBS=$ac_check_lib_save_LIBS
10388fi
e1fefc61
GM
10389eval ac_res=\$$as_ac_Lib
10390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10391$as_echo "$ac_res" >&6; }
10392eval as_val=\$$as_ac_Lib
10393 if test "x$as_val" = x""yes; then :
1abfdc54
GM
10394 HAVE_PTHREAD=yes
10395fi
10396
10397fi
10398if test "$HAVE_PTHREAD" = yes; then
10399 case "${canonical}" in
10400 *-hpux*) ;;
fbecbfb9
GM
10401 *) LIB_PTHREAD="-lpthread"
10402 LIBS="$LIB_PTHREAD $LIBS" ;;
1abfdc54
GM
10403 esac
10404
10405$as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10406
10407fi
10408
10409
067d23c9
KY
10410{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10411$as_echo_n "checking for cma_open in -lpthreads... " >&6; }
a9bec17c 10412if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
067d23c9
KY
10413 $as_echo_n "(cached) " >&6
10414else
10415 ac_check_lib_save_LIBS=$LIBS
10416LIBS="-lpthreads $LIBS"
10417cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10418/* end confdefs.h. */
10419
10420/* Override any GCC internal prototype to avoid an error.
10421 Use char because int might match the return type of a GCC
10422 builtin and then its argument prototype would still apply. */
10423#ifdef __cplusplus
10424extern "C"
10425#endif
10426char cma_open ();
10427int
10428main ()
10429{
10430return cma_open ();
10431 ;
10432 return 0;
10433}
10434_ACEOF
10435if ac_fn_c_try_link "$LINENO"; then :
10436 ac_cv_lib_pthreads_cma_open=yes
10437else
10438 ac_cv_lib_pthreads_cma_open=no
10439fi
10440rm -f core conftest.err conftest.$ac_objext \
10441 conftest$ac_exeext conftest.$ac_ext
10442LIBS=$ac_check_lib_save_LIBS
10443fi
10444{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10445$as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
a9bec17c 10446if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
067d23c9
KY
10447 cat >>confdefs.h <<_ACEOF
10448#define HAVE_LIBPTHREADS 1
10449_ACEOF
10450
10451 LIBS="-lpthreads $LIBS"
10452
10453fi
10454
10455
10456## Note: when using cpp in s/aix4.2.h, this definition depended on
10457## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10458## the system file was sourced. Hence the value of LIBS_SYSTEM
10459## added to LIBS in configure would never contain the pthreads part,
10460## but the value used in Makefiles might. FIXME?
10461##
10462## -lpthreads seems to be necessary for Xlib in X11R6, and should
10463## be harmless on older versions of X where it happens to exist.
10464test "$opsys" = "aix4-2" && \
10465 test $ac_cv_lib_pthreads_cma_open = yes && \
10466 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10467
10468
10469case ${host_os} in
10470aix*)
10471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10472$as_echo_n "checking for -bbigtoc option... " >&6; }
a9bec17c 10473if test "${gdb_cv_bigtoc+set}" = set; then :
067d23c9
KY
10474 $as_echo_n "(cached) " >&6
10475else
10476
10477 case $GCC in
10478 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10479 *) gdb_cv_bigtoc=-bbigtoc ;;
10480 esac
10481
10482 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10484/* end confdefs.h. */
10485
10486int
10487main ()
10488{
10489int i;
10490 ;
10491 return 0;
10492}
10493_ACEOF
10494if ac_fn_c_try_link "$LINENO"; then :
10495
10496else
10497 gdb_cv_bigtoc=
10498fi
10499rm -f core conftest.err conftest.$ac_objext \
10500 conftest$ac_exeext conftest.$ac_ext
10501
10502fi
10503{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10504$as_echo "$gdb_cv_bigtoc" >&6; }
10505 ;;
10506esac
10507
10508# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10509# used for the tests that follow. We set them back to REAL_CFLAGS and
10510# REAL_CPPFLAGS later on.
10511
10512REAL_CFLAGS="$CFLAGS"
10513REAL_CPPFLAGS="$CPPFLAGS"
10514
10515if test "${HAVE_X11}" = "yes"; then
10516 DEFS="$C_SWITCH_X_SITE $DEFS"
10517 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10518 LIBS="-lX11 $LIBS"
10519 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10520 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10521
10522 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10523 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
10524 # but it's more convenient here to set LD_RUN_PATH
10525 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
10526 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10527 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10528 export LD_RUN_PATH
10529 fi
10530
10531 if test "${opsys}" = "gnu-linux"; then
10532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10533$as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10535/* end confdefs.h. */
10536
10537int
10538main ()
10539{
10540XOpenDisplay ("foo");
10541 ;
10542 return 0;
10543}
10544_ACEOF
10545if ac_fn_c_try_link "$LINENO"; then :
0e2a0628 10546 xgnu_linux_first_failure=no
067d23c9 10547else
0e2a0628 10548 xgnu_linux_first_failure=yes
067d23c9
KY
10549fi
10550rm -f core conftest.err conftest.$ac_objext \
10551 conftest$ac_exeext conftest.$ac_ext
0e2a0628 10552 if test "${xgnu_linux_first_failure}" = "yes"; then
067d23c9
KY
10553 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10554 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10555 OLD_CPPFLAGS="$CPPFLAGS"
10556 OLD_LIBS="$LIBS"
10557 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10558 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10559 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10560 LIBS="$LIBS -b i486-linuxaout"
10561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10562/* end confdefs.h. */
10563
10564int
10565main ()
10566{
10567XOpenDisplay ("foo");
10568 ;
10569 return 0;
10570}
10571_ACEOF
10572if ac_fn_c_try_link "$LINENO"; then :
0e2a0628 10573 xgnu_linux_second_failure=no
067d23c9 10574else
0e2a0628 10575 xgnu_linux_second_failure=yes
067d23c9
KY
10576fi
10577rm -f core conftest.err conftest.$ac_objext \
10578 conftest$ac_exeext conftest.$ac_ext
0e2a0628 10579 if test "${xgnu_linux_second_failure}" = "yes"; then
067d23c9
KY
10580 # If we get the same failure with -b, there is no use adding -b.
10581 # So take it out. This plays safe.
10582 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10583 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10584 CPPFLAGS="$OLD_CPPFLAGS"
10585 LIBS="$OLD_LIBS"
10586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10587$as_echo "no" >&6; }
10588 else
10589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10590$as_echo "yes" >&6; }
10591 fi
10592 else
10593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10594$as_echo "no" >&6; }
10595 fi
10596 fi
10597
10598 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10599 # header files included from there.
10600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10601$as_echo_n "checking for Xkb... " >&6; }
10602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10603/* end confdefs.h. */
10604#include <X11/Xlib.h>
10605#include <X11/XKBlib.h>
10606int
10607main ()
10608{
10609XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10610 ;
10611 return 0;
10612}
10613_ACEOF
10614if ac_fn_c_try_link "$LINENO"; then :
10615 emacs_xkb=yes
10616else
10617 emacs_xkb=no
10618fi
10619rm -f core conftest.err conftest.$ac_objext \
10620 conftest$ac_exeext conftest.$ac_ext
10621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10622$as_echo "$emacs_xkb" >&6; }
10623 if test $emacs_xkb = yes; then
10624
10625$as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10626
10627 fi
10628
10629 for ac_func in XrmSetDatabase XScreenResourceString \
10630XScreenNumberOfScreen XSetWMProtocols
10631do :
10632 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10633ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
10634eval as_val=\$$as_ac_var
10635 if test "x$as_val" = x""yes; then :
067d23c9
KY
10636 cat >>confdefs.h <<_ACEOF
10637#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10638_ACEOF
10639
10640fi
10641done
10642
10643fi
10644
10645if test "${window_system}" = "x11"; then
10646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10647$as_echo_n "checking X11 version 6... " >&6; }
a9bec17c 10648 if test "${emacs_cv_x11_version_6+set}" = set; then :
067d23c9
KY
10649 $as_echo_n "(cached) " >&6
10650else
10651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10652/* end confdefs.h. */
10653#include <X11/Xlib.h>
10654int
10655main ()
10656{
10657#if XlibSpecificationRelease < 6
10658fail;
10659#endif
10660
10661 ;
10662 return 0;
10663}
10664_ACEOF
10665if ac_fn_c_try_link "$LINENO"; then :
10666 emacs_cv_x11_version_6=yes
10667else
10668 emacs_cv_x11_version_6=no
10669fi
10670rm -f core conftest.err conftest.$ac_objext \
10671 conftest$ac_exeext conftest.$ac_ext
10672fi
10673
10674 if test $emacs_cv_x11_version_6 = yes; then
10675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10676$as_echo "6 or newer" >&6; }
10677
10678$as_echo "#define HAVE_X11R6 1" >>confdefs.h
10679
10680
10681$as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10682
10683 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10684 ## XIM support.
10685 case "$opsys" in
10686 sol2-*) : ;;
10687 *)
10688$as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10689
10690 ;;
10691 esac
10692 else
10693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10694$as_echo "before 6" >&6; }
10695 fi
10696fi
10697
10698
10699### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10700HAVE_RSVG=no
096a6052 10701if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
067d23c9
KY
10702 if test "${with_rsvg}" != "no"; then
10703 RSVG_REQUIRED=2.11.0
10704 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10705
10706
10707 succeeded=no
10708
10709 # Extract the first word of "pkg-config", so it can be a program name with args.
10710set dummy pkg-config; ac_word=$2
10711{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10712$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 10713if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
10714 $as_echo_n "(cached) " >&6
10715else
10716 case $PKG_CONFIG in
10717 [\\/]* | ?:[\\/]*)
10718 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10719 ;;
10720 *)
10721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10722for as_dir in $PATH
10723do
10724 IFS=$as_save_IFS
10725 test -z "$as_dir" && as_dir=.
10726 for ac_exec_ext in '' $ac_executable_extensions; do
10727 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10728 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10729 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10730 break 2
10731 fi
10732done
10733 done
10734IFS=$as_save_IFS
10735
10736 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10737 ;;
10738esac
10739fi
10740PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10741if test -n "$PKG_CONFIG"; then
10742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10743$as_echo "$PKG_CONFIG" >&6; }
10744else
10745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10746$as_echo "no" >&6; }
10747fi
10748
10749
10750
10751 if test "$PKG_CONFIG" = "no" ; then
10752 :
10753 else
10754 PKG_CONFIG_MIN_VERSION=0.9.0
10755 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10757$as_echo_n "checking for $RSVG_MODULE... " >&6; }
10758
10759 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then
10760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10761$as_echo "yes" >&6; }
10762 succeeded=yes
10763
10764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5
10765$as_echo_n "checking RSVG_CFLAGS... " >&6; }
10766 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'`
10767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5
10768$as_echo "$RSVG_CFLAGS" >&6; }
10769
10770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5
10771$as_echo_n "checking RSVG_LIBS... " >&6; }
10772 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'`
10773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5
10774$as_echo "$RSVG_LIBS" >&6; }
10775 else
10776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10777$as_echo "no" >&6; }
10778 RSVG_CFLAGS=""
10779 RSVG_LIBS=""
10780 ## If we have a custom action on failure, don't print errors, but
10781 ## do set a variable so people can do so.
10782 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10783
10784 fi
10785
10786
10787
10788 else
10789 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10790 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10791 fi
10792 fi
10793
10794 if test $succeeded = yes; then
10795 HAVE_RSVG=yes
10796 else
10797 :
10798 fi
10799
10800
10801
10802
10803 if test $HAVE_RSVG = yes; then
10804
10805$as_echo "#define HAVE_RSVG 1" >>confdefs.h
10806
10807 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10808 LIBS="$RSVG_LIBS $LIBS"
10809 fi
10810 fi
10811fi
10812
10813HAVE_IMAGEMAGICK=no
10814if test "${HAVE_X11}" = "yes"; then
10815 if test "${with_imagemagick}" != "no"; then
718ad21a
GM
10816 ## 6.2.8 is the earliest version known to work, but earlier versions
10817 ## might work - let us know if you find one.
10818 ## 6.0.7 does not work. See bug#7955.
10819 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
067d23c9
KY
10820
10821 succeeded=no
10822
10823 # Extract the first word of "pkg-config", so it can be a program name with args.
10824set dummy pkg-config; ac_word=$2
10825{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10826$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 10827if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
10828 $as_echo_n "(cached) " >&6
10829else
10830 case $PKG_CONFIG in
10831 [\\/]* | ?:[\\/]*)
10832 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10833 ;;
10834 *)
10835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10836for as_dir in $PATH
10837do
10838 IFS=$as_save_IFS
10839 test -z "$as_dir" && as_dir=.
10840 for ac_exec_ext in '' $ac_executable_extensions; do
10841 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10842 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10844 break 2
10845 fi
10846done
10847 done
10848IFS=$as_save_IFS
10849
10850 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10851 ;;
10852esac
10853fi
10854PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10855if test -n "$PKG_CONFIG"; then
10856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10857$as_echo "$PKG_CONFIG" >&6; }
10858else
10859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10860$as_echo "no" >&6; }
10861fi
10862
10863
10864
10865 if test "$PKG_CONFIG" = "no" ; then
10866 :
10867 else
10868 PKG_CONFIG_MIN_VERSION=0.9.0
10869 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10871$as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10872
10873 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5; then
10874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10875$as_echo "yes" >&6; }
10876 succeeded=yes
10877
10878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_CFLAGS" >&5
10879$as_echo_n "checking IMAGEMAGICK_CFLAGS... " >&6; }
10880 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_CFLAGS" >&5
10882$as_echo "$IMAGEMAGICK_CFLAGS" >&6; }
10883
10884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_LIBS" >&5
10885$as_echo_n "checking IMAGEMAGICK_LIBS... " >&6; }
10886 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_LIBS" >&5
10888$as_echo "$IMAGEMAGICK_LIBS" >&6; }
10889 else
10890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10891$as_echo "no" >&6; }
10892 IMAGEMAGICK_CFLAGS=""
10893 IMAGEMAGICK_LIBS=""
10894 ## If we have a custom action on failure, don't print errors, but
10895 ## do set a variable so people can do so.
10896 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10897
10898 fi
10899
10900
10901
10902 else
10903 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10904 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10905 fi
10906 fi
10907
10908 if test $succeeded = yes; then
10909 HAVE_IMAGEMAGICK=yes
10910 else
10911 :
10912 fi
10913
10914
10915
10916
10917 if test $HAVE_IMAGEMAGICK = yes; then
10918
10919$as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10920
10921 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10922 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10923 for ac_func in MagickExportImagePixels
10924do :
10925 ac_fn_c_check_func "$LINENO" "MagickExportImagePixels" "ac_cv_func_MagickExportImagePixels"
a9bec17c 10926if test "x$ac_cv_func_MagickExportImagePixels" = x""yes; then :
067d23c9
KY
10927 cat >>confdefs.h <<_ACEOF
10928#define HAVE_MAGICKEXPORTIMAGEPIXELS 1
10929_ACEOF
10930
10931fi
10932done
10933
10934 fi
10935 fi
10936fi
10937
10938
10939HAVE_GTK=no
571e1872 10940GTK_OBJ=
067d23c9 10941if test "${with_gtk3}" = "yes"; then
0afb4571
J
10942 GLIB_REQUIRED=2.28
10943 GTK_REQUIRED=3.0
067d23c9
KY
10944 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10945
10946
10947 succeeded=no
10948
10949 # Extract the first word of "pkg-config", so it can be a program name with args.
10950set dummy pkg-config; ac_word=$2
10951{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10952$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 10953if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
10954 $as_echo_n "(cached) " >&6
10955else
10956 case $PKG_CONFIG in
10957 [\\/]* | ?:[\\/]*)
10958 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10959 ;;
10960 *)
10961 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10962for as_dir in $PATH
10963do
10964 IFS=$as_save_IFS
10965 test -z "$as_dir" && as_dir=.
10966 for ac_exec_ext in '' $ac_executable_extensions; do
10967 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10968 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10969 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10970 break 2
10971 fi
10972done
10973 done
10974IFS=$as_save_IFS
10975
10976 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10977 ;;
10978esac
10979fi
10980PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10981if test -n "$PKG_CONFIG"; then
10982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10983$as_echo "$PKG_CONFIG" >&6; }
10984else
10985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10986$as_echo "no" >&6; }
10987fi
10988
10989
10990
10991 if test "$PKG_CONFIG" = "no" ; then
10992 pkg_check_gtk=no
10993 else
10994 PKG_CONFIG_MIN_VERSION=0.9.0
10995 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10997$as_echo_n "checking for $GTK_MODULES... " >&6; }
10998
10999 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
11000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11001$as_echo "yes" >&6; }
11002 succeeded=yes
11003
11004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
11005$as_echo_n "checking GTK_CFLAGS... " >&6; }
11006 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
11007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
11008$as_echo "$GTK_CFLAGS" >&6; }
11009
11010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
11011$as_echo_n "checking GTK_LIBS... " >&6; }
11012 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
11013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
11014$as_echo "$GTK_LIBS" >&6; }
11015 else
11016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11017$as_echo "no" >&6; }
11018 GTK_CFLAGS=""
11019 GTK_LIBS=""
11020 ## If we have a custom action on failure, don't print errors, but
11021 ## do set a variable so people can do so.
11022 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
11023
11024 fi
11025
11026
11027
11028 else
11029 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11030 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11031 fi
11032 fi
11033
11034 if test $succeeded = yes; then
11035 pkg_check_gtk=yes
11036 else
11037 pkg_check_gtk=no
11038 fi
11039
11040 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
a9bec17c 11041 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
067d23c9 11042 fi
0afb4571
J
11043
11044$as_echo "#define HAVE_GTK3 1" >>confdefs.h
11045
571e1872 11046 GTK_OBJ=emacsgtkfixed.o
067d23c9
KY
11047fi
11048
11049if test "$pkg_check_gtk" != "yes"; then
11050 HAVE_GTK=no
11051if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
ba9d54be
GM
11052 GLIB_REQUIRED=2.10
11053 GTK_REQUIRED=2.10
067d23c9
KY
11054 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11055
11056
11057 succeeded=no
11058
11059 # Extract the first word of "pkg-config", so it can be a program name with args.
11060set dummy pkg-config; ac_word=$2
11061{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11062$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 11063if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
11064 $as_echo_n "(cached) " >&6
11065else
11066 case $PKG_CONFIG in
11067 [\\/]* | ?:[\\/]*)
11068 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11069 ;;
11070 *)
11071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11072for as_dir in $PATH
11073do
11074 IFS=$as_save_IFS
11075 test -z "$as_dir" && as_dir=.
11076 for ac_exec_ext in '' $ac_executable_extensions; do
11077 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11078 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11080 break 2
11081 fi
11082done
11083 done
11084IFS=$as_save_IFS
11085
11086 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11087 ;;
11088esac
11089fi
11090PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11091if test -n "$PKG_CONFIG"; then
11092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11093$as_echo "$PKG_CONFIG" >&6; }
11094else
11095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11096$as_echo "no" >&6; }
11097fi
11098
11099
11100
11101 if test "$PKG_CONFIG" = "no" ; then
11102 pkg_check_gtk=no
11103 else
11104 PKG_CONFIG_MIN_VERSION=0.9.0
11105 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11107$as_echo_n "checking for $GTK_MODULES... " >&6; }
11108
11109 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
11110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11111$as_echo "yes" >&6; }
11112 succeeded=yes
11113
11114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
11115$as_echo_n "checking GTK_CFLAGS... " >&6; }
11116 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
11117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
11118$as_echo "$GTK_CFLAGS" >&6; }
11119
11120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
11121$as_echo_n "checking GTK_LIBS... " >&6; }
11122 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
11123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
11124$as_echo "$GTK_LIBS" >&6; }
11125 else
11126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11127$as_echo "no" >&6; }
11128 GTK_CFLAGS=""
11129 GTK_LIBS=""
11130 ## If we have a custom action on failure, don't print errors, but
11131 ## do set a variable so people can do so.
11132 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
11133
11134 fi
11135
11136
11137
11138 else
11139 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11140 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11141 fi
11142 fi
11143
11144 if test $succeeded = yes; then
11145 pkg_check_gtk=yes
11146 else
11147 pkg_check_gtk=no
11148 fi
11149
11150 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
a9bec17c 11151 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
067d23c9
KY
11152 fi
11153fi
11154fi
11155
067d23c9
KY
11156if test x"$pkg_check_gtk" = xyes; then
11157
11158
11159
11160 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11161 CFLAGS="$CFLAGS $GTK_CFLAGS"
11162 LIBS="$GTK_LIBS $LIBS"
11163 GTK_COMPILES=no
11164 for ac_func in gtk_main
11165do :
11166 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
a9bec17c 11167if test "x$ac_cv_func_gtk_main" = x""yes; then :
067d23c9
KY
11168 cat >>confdefs.h <<_ACEOF
11169#define HAVE_GTK_MAIN 1
11170_ACEOF
11171 GTK_COMPILES=yes
11172fi
11173done
11174
11175 if test "${GTK_COMPILES}" != "yes"; then
11176 if test "$USE_X_TOOLKIT" != "maybe"; then
a9bec17c 11177 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
067d23c9
KY
11178 fi
11179 else
11180 HAVE_GTK=yes
11181
11182$as_echo "#define USE_GTK 1" >>confdefs.h
11183
571e1872 11184 GTK_OBJ="gtkutil.o $GTK_OBJ"
067d23c9
KY
11185 USE_X_TOOLKIT=none
11186 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
11187 :
11188 else
11189 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11190 closing open displays. This is no problem if you just use
11191 one display, but if you use more than one and close one of them
11192 Emacs may crash." >&5
11193$as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11194 closing open displays. This is no problem if you just use
11195 one display, but if you use more than one and close one of them
11196 Emacs may crash." >&2;}
11197 sleep 3
11198 fi
11199 fi
11200
11201fi
11202
11203
11204
11205if test "${HAVE_GTK}" = "yes"; then
11206
11207 if test "$with_toolkit_scroll_bars" != no; then
11208 with_toolkit_scroll_bars=yes
11209 fi
11210
11211 HAVE_GTK_FILE_SELECTION=no
11212 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11213#include <gtk/gtk.h>
11214"
a9bec17c 11215if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
067d23c9
KY
11216 HAVE_GTK_FILE_SELECTION=yes
11217else
11218 HAVE_GTK_FILE_SELECTION=no
11219fi
11220
11221 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11222 for ac_func in gtk_file_selection_new
11223do :
11224 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
a9bec17c 11225if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
067d23c9
KY
11226 cat >>confdefs.h <<_ACEOF
11227#define HAVE_GTK_FILE_SELECTION_NEW 1
11228_ACEOF
11229
11230fi
11231done
11232
11233 fi
11234
067d23c9
KY
11235
11236 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11237 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11238 gtk_widget_get_mapped gtk_adjustment_get_page_size \
e15c184e
GM
11239 gtk_orientable_set_orientation \
11240 gtk_window_set_has_resize_grip
067d23c9
KY
11241do :
11242 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11243ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
11244eval as_val=\$$as_ac_var
11245 if test "x$as_val" = x""yes; then :
067d23c9
KY
11246 cat >>confdefs.h <<_ACEOF
11247#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11248_ACEOF
11249
11250fi
11251done
11252
067d23c9
KY
11253fi
11254
11255HAVE_DBUS=no
11256DBUS_OBJ=
11257if test "${with_dbus}" = "yes"; then
11258
11259 succeeded=no
11260
11261 # Extract the first word of "pkg-config", so it can be a program name with args.
11262set dummy pkg-config; ac_word=$2
11263{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11264$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 11265if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
11266 $as_echo_n "(cached) " >&6
11267else
11268 case $PKG_CONFIG in
11269 [\\/]* | ?:[\\/]*)
11270 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11271 ;;
11272 *)
11273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11274for as_dir in $PATH
11275do
11276 IFS=$as_save_IFS
11277 test -z "$as_dir" && as_dir=.
11278 for ac_exec_ext in '' $ac_executable_extensions; do
11279 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11280 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11281 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11282 break 2
11283 fi
11284done
11285 done
11286IFS=$as_save_IFS
11287
11288 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11289 ;;
11290esac
11291fi
11292PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11293if test -n "$PKG_CONFIG"; then
11294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11295$as_echo "$PKG_CONFIG" >&6; }
11296else
11297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11298$as_echo "no" >&6; }
11299fi
11300
11301
11302
11303 if test "$PKG_CONFIG" = "no" ; then
11304 HAVE_DBUS=no
11305 else
11306 PKG_CONFIG_MIN_VERSION=0.9.0
11307 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11309$as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11310
11311 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then
11312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11313$as_echo "yes" >&6; }
11314 succeeded=yes
11315
11316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5
11317$as_echo_n "checking DBUS_CFLAGS... " >&6; }
11318 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
11319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5
11320$as_echo "$DBUS_CFLAGS" >&6; }
11321
11322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5
11323$as_echo_n "checking DBUS_LIBS... " >&6; }
11324 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
11325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5
11326$as_echo "$DBUS_LIBS" >&6; }
11327 else
11328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11329$as_echo "no" >&6; }
11330 DBUS_CFLAGS=""
11331 DBUS_LIBS=""
11332 ## If we have a custom action on failure, don't print errors, but
11333 ## do set a variable so people can do so.
11334 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
11335
11336 fi
11337
11338
11339
11340 else
11341 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11342 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11343 fi
11344 fi
11345
11346 if test $succeeded = yes; then
11347 HAVE_DBUS=yes
11348 else
11349 HAVE_DBUS=no
11350 fi
11351
11352 if test "$HAVE_DBUS" = yes; then
11353 LIBS="$LIBS $DBUS_LIBS"
11354
11355$as_echo "#define HAVE_DBUS 1" >>confdefs.h
11356
11357 for ac_func in dbus_watch_get_unix_fd
11358do :
11359 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
a9bec17c 11360if test "x$ac_cv_func_dbus_watch_get_unix_fd" = x""yes; then :
067d23c9
KY
11361 cat >>confdefs.h <<_ACEOF
11362#define HAVE_DBUS_WATCH_GET_UNIX_FD 1
11363_ACEOF
11364
11365fi
11366done
11367
11368 DBUS_OBJ=dbusbind.o
11369 fi
11370fi
11371
11372
f527bd02
GM
11373HAVE_GSETTINGS=no
11374if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11375
11376 succeeded=no
11377
11378 # Extract the first word of "pkg-config", so it can be a program name with args.
11379set dummy pkg-config; ac_word=$2
11380{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11381$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 11382if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
f527bd02
GM
11383 $as_echo_n "(cached) " >&6
11384else
11385 case $PKG_CONFIG in
11386 [\\/]* | ?:[\\/]*)
11387 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11388 ;;
11389 *)
11390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11391for as_dir in $PATH
11392do
11393 IFS=$as_save_IFS
11394 test -z "$as_dir" && as_dir=.
11395 for ac_exec_ext in '' $ac_executable_extensions; do
11396 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11397 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11398 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11399 break 2
11400 fi
11401done
11402 done
11403IFS=$as_save_IFS
11404
11405 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11406 ;;
11407esac
11408fi
11409PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11410if test -n "$PKG_CONFIG"; then
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11412$as_echo "$PKG_CONFIG" >&6; }
11413else
11414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11415$as_echo "no" >&6; }
11416fi
11417
11418
11419
11420 if test "$PKG_CONFIG" = "no" ; then
11421 HAVE_GSETTINGS=no
11422 else
11423 PKG_CONFIG_MIN_VERSION=0.9.0
11424 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
85c1ab0b
GM
11425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11426$as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
f527bd02 11427
85c1ab0b 11428 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5; then
f527bd02
GM
11429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11430$as_echo "yes" >&6; }
11431 succeeded=yes
11432
11433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GSETTINGS_CFLAGS" >&5
11434$as_echo_n "checking GSETTINGS_CFLAGS... " >&6; }
85c1ab0b 11435 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26"|sed -e 's,///*,/,g'`
f527bd02
GM
11436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GSETTINGS_CFLAGS" >&5
11437$as_echo "$GSETTINGS_CFLAGS" >&6; }
11438
11439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GSETTINGS_LIBS" >&5
11440$as_echo_n "checking GSETTINGS_LIBS... " >&6; }
85c1ab0b 11441 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26"|sed -e 's,///*,/,g'`
f527bd02
GM
11442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GSETTINGS_LIBS" >&5
11443$as_echo "$GSETTINGS_LIBS" >&6; }
11444 else
11445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11446$as_echo "no" >&6; }
11447 GSETTINGS_CFLAGS=""
11448 GSETTINGS_LIBS=""
11449 ## If we have a custom action on failure, don't print errors, but
11450 ## do set a variable so people can do so.
85c1ab0b 11451 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gio-2.0 >= 2.26"`
f527bd02
GM
11452
11453 fi
11454
11455
11456
11457 else
11458 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11459 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11460 fi
11461 fi
11462
11463 if test $succeeded = yes; then
11464 HAVE_GSETTINGS=yes
11465 else
11466 HAVE_GSETTINGS=no
11467 fi
11468
11469 if test "$HAVE_GSETTINGS" = "yes"; then
11470
11471$as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11472
11473 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11474 SETTINGS_LIBS="$GSETTINGS_LIBS"
11475 fi
11476fi
11477
067d23c9 11478HAVE_GCONF=no
17410582 11479if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
067d23c9
KY
11480
11481 succeeded=no
11482
11483 # Extract the first word of "pkg-config", so it can be a program name with args.
11484set dummy pkg-config; ac_word=$2
11485{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11486$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 11487if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
11488 $as_echo_n "(cached) " >&6
11489else
11490 case $PKG_CONFIG in
11491 [\\/]* | ?:[\\/]*)
11492 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11493 ;;
11494 *)
11495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11496for as_dir in $PATH
11497do
11498 IFS=$as_save_IFS
11499 test -z "$as_dir" && as_dir=.
11500 for ac_exec_ext in '' $ac_executable_extensions; do
11501 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11502 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11503 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11504 break 2
11505 fi
11506done
11507 done
11508IFS=$as_save_IFS
11509
11510 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11511 ;;
11512esac
11513fi
11514PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11515if test -n "$PKG_CONFIG"; then
11516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11517$as_echo "$PKG_CONFIG" >&6; }
11518else
11519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11520$as_echo "no" >&6; }
11521fi
11522
11523
11524
11525 if test "$PKG_CONFIG" = "no" ; then
11526 HAVE_GCONF=no
11527 else
11528 PKG_CONFIG_MIN_VERSION=0.9.0
11529 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11531$as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11532
11533 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then
11534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11535$as_echo "yes" >&6; }
11536 succeeded=yes
11537
11538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5
11539$as_echo_n "checking GCONF_CFLAGS... " >&6; }
11540 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
11541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5
11542$as_echo "$GCONF_CFLAGS" >&6; }
11543
11544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5
11545$as_echo_n "checking GCONF_LIBS... " >&6; }
11546 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
11547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5
11548$as_echo "$GCONF_LIBS" >&6; }
11549 else
11550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11551$as_echo "no" >&6; }
11552 GCONF_CFLAGS=""
11553 GCONF_LIBS=""
11554 ## If we have a custom action on failure, don't print errors, but
11555 ## do set a variable so people can do so.
11556 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
11557
11558 fi
11559
11560
11561
11562 else
11563 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11564 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11565 fi
11566 fi
11567
11568 if test $succeeded = yes; then
11569 HAVE_GCONF=yes
11570 else
11571 HAVE_GCONF=no
11572 fi
11573
11574 if test "$HAVE_GCONF" = yes; then
11575
11576$as_echo "#define HAVE_GCONF 1" >>confdefs.h
11577
17410582
GM
11578 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11579 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
f527bd02
GM
11580 fi
11581fi
11582
11583if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11584 SAVE_CFLAGS="$CFLAGS"
d7932d31 11585 SAVE_LIBS="$LIBS"
f527bd02 11586 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
d7932d31 11587 LIBS="$SETTINGS_LIBS $LIBS"
f527bd02 11588 for ac_func in g_type_init
067d23c9
KY
11589do :
11590 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
a9bec17c 11591if test "x$ac_cv_func_g_type_init" = x""yes; then :
067d23c9
KY
11592 cat >>confdefs.h <<_ACEOF
11593#define HAVE_G_TYPE_INIT 1
11594_ACEOF
11595
11596fi
11597done
11598
f527bd02 11599 CFLAGS="$SAVE_CFLAGS"
d7932d31 11600 LIBS="$SAVE_LIBS"
067d23c9
KY
11601fi
11602
f527bd02
GM
11603
11604
11605
067d23c9
KY
11606HAVE_LIBSELINUX=no
11607LIBSELINUX_LIBS=
11608if test "${with_selinux}" = "yes"; then
11609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11610$as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
a9bec17c 11611if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
067d23c9
KY
11612 $as_echo_n "(cached) " >&6
11613else
11614 ac_check_lib_save_LIBS=$LIBS
11615LIBS="-lselinux $LIBS"
11616cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11617/* end confdefs.h. */
11618
11619/* Override any GCC internal prototype to avoid an error.
11620 Use char because int might match the return type of a GCC
11621 builtin and then its argument prototype would still apply. */
11622#ifdef __cplusplus
11623extern "C"
11624#endif
11625char lgetfilecon ();
11626int
11627main ()
11628{
11629return lgetfilecon ();
11630 ;
11631 return 0;
11632}
11633_ACEOF
11634if ac_fn_c_try_link "$LINENO"; then :
11635 ac_cv_lib_selinux_lgetfilecon=yes
11636else
11637 ac_cv_lib_selinux_lgetfilecon=no
11638fi
11639rm -f core conftest.err conftest.$ac_objext \
11640 conftest$ac_exeext conftest.$ac_ext
11641LIBS=$ac_check_lib_save_LIBS
11642fi
11643{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11644$as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
a9bec17c 11645if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
067d23c9
KY
11646 HAVE_LIBSELINUX=yes
11647else
11648 HAVE_LIBSELINUX=no
11649fi
11650
11651 if test "$HAVE_LIBSELINUX" = yes; then
11652
11653$as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11654
11655 LIBSELINUX_LIBS=-lselinux
11656 fi
11657fi
11658
11659
11660HAVE_GNUTLS=no
e7d4e61f 11661HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
067d23c9
KY
11662if test "${with_gnutls}" = "yes" ; then
11663
11664 succeeded=no
11665
11666 # Extract the first word of "pkg-config", so it can be a program name with args.
11667set dummy pkg-config; ac_word=$2
11668{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11669$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 11670if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
11671 $as_echo_n "(cached) " >&6
11672else
11673 case $PKG_CONFIG in
11674 [\\/]* | ?:[\\/]*)
11675 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11676 ;;
11677 *)
11678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11679for as_dir in $PATH
11680do
11681 IFS=$as_save_IFS
11682 test -z "$as_dir" && as_dir=.
11683 for ac_exec_ext in '' $ac_executable_extensions; do
11684 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11685 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11687 break 2
11688 fi
11689done
11690 done
11691IFS=$as_save_IFS
11692
11693 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11694 ;;
11695esac
11696fi
11697PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11698if test -n "$PKG_CONFIG"; then
11699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11700$as_echo "$PKG_CONFIG" >&6; }
11701else
11702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11703$as_echo "no" >&6; }
11704fi
11705
11706
11707
11708 if test "$PKG_CONFIG" = "no" ; then
11709 HAVE_GNUTLS=no
11710 else
11711 PKG_CONFIG_MIN_VERSION=0.9.0
11712 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
27f5a136
GM
11713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11714$as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
067d23c9 11715
27f5a136 11716 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5; then
067d23c9
KY
11717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11718$as_echo "yes" >&6; }
11719 succeeded=yes
11720
11721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_CFLAGS" >&5
11722$as_echo_n "checking LIBGNUTLS_CFLAGS... " >&6; }
27f5a136 11723 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6"|sed -e 's,///*,/,g'`
067d23c9
KY
11724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_CFLAGS" >&5
11725$as_echo "$LIBGNUTLS_CFLAGS" >&6; }
11726
11727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_LIBS" >&5
11728$as_echo_n "checking LIBGNUTLS_LIBS... " >&6; }
27f5a136 11729 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6"|sed -e 's,///*,/,g'`
067d23c9
KY
11730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_LIBS" >&5
11731$as_echo "$LIBGNUTLS_LIBS" >&6; }
11732 else
11733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11734$as_echo "no" >&6; }
11735 LIBGNUTLS_CFLAGS=""
11736 LIBGNUTLS_LIBS=""
11737 ## If we have a custom action on failure, don't print errors, but
11738 ## do set a variable so people can do so.
27f5a136 11739 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.6"`
067d23c9
KY
11740
11741 fi
11742
11743
11744
11745 else
11746 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11747 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11748 fi
11749 fi
11750
11751 if test $succeeded = yes; then
11752 HAVE_GNUTLS=yes
11753 else
11754 HAVE_GNUTLS=no
11755 fi
11756
11757 if test "${HAVE_GNUTLS}" = "yes"; then
11758
11759$as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11760
11761 fi
e7d4e61f
GM
11762
11763 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11764 LIBS="$LIBGNUTLS_LIBS $LIBS"
11765 for ac_func in gnutls_certificate_set_verify_function
11766do :
11767 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
a9bec17c 11768if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
e7d4e61f
GM
11769 cat >>confdefs.h <<_ACEOF
11770#define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11771_ACEOF
11772 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11773fi
11774done
11775
11776
11777 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11778
11779$as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11780
11781 fi
067d23c9
KY
11782fi
11783
11784
11785
e7d4e61f 11786
067d23c9
KY
11787HAVE_XAW3D=no
11788LUCID_LIBW=
11789if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11790 if test "$with_xaw3d" != no; then
11791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11792$as_echo_n "checking for xaw3d... " >&6; }
a9bec17c 11793 if test "${emacs_cv_xaw3d+set}" = set; then :
067d23c9
KY
11794 $as_echo_n "(cached) " >&6
11795else
11796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11797/* end confdefs.h. */
11798
11799#include <X11/Intrinsic.h>
11800#include <X11/Xaw3d/Simple.h>
11801int
11802main ()
11803{
11804
11805 ;
11806 return 0;
11807}
11808_ACEOF
11809if ac_fn_c_try_link "$LINENO"; then :
14beddf4
CY
11810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11811$as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
a9bec17c 11812if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
ae1362a3
AS
11813 $as_echo_n "(cached) " >&6
11814else
11815 ac_check_lib_save_LIBS=$LIBS
14beddf4 11816LIBS="-lXaw3d $LIBS"
ae1362a3
AS
11817cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11818/* end confdefs.h. */
bf89cb4d 11819
ae1362a3
AS
11820/* Override any GCC internal prototype to avoid an error.
11821 Use char because int might match the return type of a GCC
11822 builtin and then its argument prototype would still apply. */
11823#ifdef __cplusplus
11824extern "C"
11825#endif
14beddf4 11826char XawScrollbarSetThumb ();
ae1362a3
AS
11827int
11828main ()
11829{
14beddf4 11830return XawScrollbarSetThumb ();
ae1362a3
AS
11831 ;
11832 return 0;
11833}
11834_ACEOF
11835if ac_fn_c_try_link "$LINENO"; then :
14beddf4 11836 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ae1362a3 11837else
14beddf4 11838 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ae1362a3
AS
11839fi
11840rm -f core conftest.err conftest.$ac_objext \
11841 conftest$ac_exeext conftest.$ac_ext
11842LIBS=$ac_check_lib_save_LIBS
11843fi
14beddf4
CY
11844{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11845$as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
a9bec17c 11846if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
067d23c9
KY
11847 emacs_cv_xaw3d=yes
11848else
11849 emacs_cv_xaw3d=no
11850fi
14beddf4
CY
11851
11852else
11853 emacs_cv_xaw3d=no
11854fi
067d23c9
KY
11855rm -f core conftest.err conftest.$ac_objext \
11856 conftest$ac_exeext conftest.$ac_ext
11857fi
11858
11859 else
11860 emacs_cv_xaw3d=no
11861 fi
11862 if test $emacs_cv_xaw3d = yes; then
11863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11864$as_echo "yes; using Lucid toolkit" >&6; }
11865 USE_X_TOOLKIT=LUCID
11866 HAVE_XAW3D=yes
11867 LUCID_LIBW=-lXaw3d
11868
11869$as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11870
11871 else
11872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11873$as_echo "no" >&6; }
11874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11875$as_echo_n "checking for libXaw... " >&6; }
a9bec17c 11876 if test "${emacs_cv_xaw+set}" = set; then :
067d23c9
KY
11877 $as_echo_n "(cached) " >&6
11878else
11879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11880/* end confdefs.h. */
11881
11882#include <X11/Intrinsic.h>
11883#include <X11/Xaw/Simple.h>
11884int
11885main ()
11886{
11887
11888 ;
11889 return 0;
11890}
11891_ACEOF
11892if ac_fn_c_try_link "$LINENO"; then :
11893 emacs_cv_xaw=yes
11894else
11895 emacs_cv_xaw=no
11896fi
11897rm -f core conftest.err conftest.$ac_objext \
11898 conftest$ac_exeext conftest.$ac_ext
11899fi
11900
11901 if test $emacs_cv_xaw = yes; then
11902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11903$as_echo "yes; using Lucid toolkit" >&6; }
11904 USE_X_TOOLKIT=LUCID
11905 LUCID_LIBW=-lXaw
11906 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
a9bec17c 11907 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
067d23c9 11908 else
a9bec17c 11909 as_fn_error "No X toolkit could be found.
cf6f3ed8
GM
11910If you are sure you want Emacs compiled without an X toolkit, pass
11911 --with-x-toolkit=no
11912to configure. Otherwise, install the development libraries for the toolkit
11913that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
067d23c9
KY
11914 fi
11915 fi
11916fi
11917
11918X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11919
11920LIBXTR6=
11921if test "${USE_X_TOOLKIT}" != "none"; then
11922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11923$as_echo_n "checking X11 toolkit version... " >&6; }
a9bec17c 11924 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
067d23c9
KY
11925 $as_echo_n "(cached) " >&6
11926else
11927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11928/* end confdefs.h. */
11929#include <X11/Intrinsic.h>
11930int
11931main ()
11932{
11933#if XtSpecificationRelease < 6
11934fail;
11935#endif
11936
11937 ;
11938 return 0;
11939}
11940_ACEOF
11941if ac_fn_c_try_link "$LINENO"; then :
11942 emacs_cv_x11_toolkit_version_6=yes
11943else
11944 emacs_cv_x11_toolkit_version_6=no
11945fi
11946rm -f core conftest.err conftest.$ac_objext \
11947 conftest$ac_exeext conftest.$ac_ext
11948fi
11949
11950 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11951 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11953$as_echo "6 or newer" >&6; }
11954
11955$as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11956
11957 LIBXTR6="-lSM -lICE"
11958 case "$opsys" in
11959 ## Use libw.a along with X11R6 Xt.
11960 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11961 esac
11962 else
11963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11964$as_echo "before 6" >&6; }
11965 fi
11966
11967 OLDLIBS="$LIBS"
11968 if test x$HAVE_X11XTR6 = xyes; then
11969 LIBS="-lXt -lSM -lICE $LIBS"
11970 else
11971 LIBS="-lXt $LIBS"
11972 fi
11973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11974$as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
a9bec17c 11975if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
067d23c9
KY
11976 $as_echo_n "(cached) " >&6
11977else
11978 ac_check_lib_save_LIBS=$LIBS
11979LIBS="-lXmu $LIBS"
11980cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11981/* end confdefs.h. */
11982
11983/* Override any GCC internal prototype to avoid an error.
11984 Use char because int might match the return type of a GCC
11985 builtin and then its argument prototype would still apply. */
11986#ifdef __cplusplus
11987extern "C"
11988#endif
11989char XmuConvertStandardSelection ();
11990int
11991main ()
11992{
11993return XmuConvertStandardSelection ();
11994 ;
11995 return 0;
11996}
11997_ACEOF
11998if ac_fn_c_try_link "$LINENO"; then :
11999 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12000else
12001 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12002fi
12003rm -f core conftest.err conftest.$ac_objext \
12004 conftest$ac_exeext conftest.$ac_ext
12005LIBS=$ac_check_lib_save_LIBS
12006fi
12007{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12008$as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
a9bec17c 12009if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
067d23c9
KY
12010 cat >>confdefs.h <<_ACEOF
12011#define HAVE_LIBXMU 1
12012_ACEOF
12013
12014 LIBS="-lXmu $LIBS"
12015
12016fi
12017
12018 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12019fi
12020
12021
12022LIBXMU=-lXmu
d6a003a8
AS
12023case $opsys in
12024 ## These systems don't supply Xmu.
067d23c9
KY
12025 hpux* | aix4-2 )
12026 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12027 ;;
12028esac
12029
12030
12031# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12032if test "${HAVE_X11}" = "yes"; then
12033 if test "${USE_X_TOOLKIT}" != "none"; then
12034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12035$as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
a9bec17c 12036if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
067d23c9
KY
12037 $as_echo_n "(cached) " >&6
12038else
12039 ac_check_lib_save_LIBS=$LIBS
12040LIBS="-lXext $LIBS"
12041cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12042/* end confdefs.h. */
12043
12044/* Override any GCC internal prototype to avoid an error.
12045 Use char because int might match the return type of a GCC
12046 builtin and then its argument prototype would still apply. */
12047#ifdef __cplusplus
12048extern "C"
12049#endif
12050char XShapeQueryExtension ();
12051int
12052main ()
12053{
12054return XShapeQueryExtension ();
12055 ;
12056 return 0;
12057}
12058_ACEOF
12059if ac_fn_c_try_link "$LINENO"; then :
12060 ac_cv_lib_Xext_XShapeQueryExtension=yes
12061else
12062 ac_cv_lib_Xext_XShapeQueryExtension=no
12063fi
12064rm -f core conftest.err conftest.$ac_objext \
12065 conftest$ac_exeext conftest.$ac_ext
12066LIBS=$ac_check_lib_save_LIBS
12067fi
12068{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12069$as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
a9bec17c 12070if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
067d23c9
KY
12071 cat >>confdefs.h <<_ACEOF
12072#define HAVE_LIBXEXT 1
12073_ACEOF
12074
12075 LIBS="-lXext $LIBS"
12076
12077fi
12078
12079 fi
12080fi
12081
12082LIBXP=
12083if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
12085$as_echo_n "checking for Motif version 2.1... " >&6; }
a9bec17c 12086if test "${emacs_cv_motif_version_2_1+set}" = set; then :
067d23c9
KY
12087 $as_echo_n "(cached) " >&6
12088else
12089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12090/* end confdefs.h. */
12091#include <Xm/Xm.h>
12092int
12093main ()
12094{
12095#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12096int x = 5;
12097#else
12098Motif version prior to 2.1.
12099#endif
12100 ;
12101 return 0;
12102}
12103_ACEOF
12104if ac_fn_c_try_compile "$LINENO"; then :
12105 emacs_cv_motif_version_2_1=yes
12106else
12107 emacs_cv_motif_version_2_1=no
12108fi
12109rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12110fi
12111{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12112$as_echo "$emacs_cv_motif_version_2_1" >&6; }
12113 if test $emacs_cv_motif_version_2_1 = yes; then
12114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12115$as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
a9bec17c 12116if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
067d23c9
KY
12117 $as_echo_n "(cached) " >&6
12118else
12119 ac_check_lib_save_LIBS=$LIBS
12120LIBS="-lXp $LIBS"
12121cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12122/* end confdefs.h. */
12123
12124/* Override any GCC internal prototype to avoid an error.
12125 Use char because int might match the return type of a GCC
12126 builtin and then its argument prototype would still apply. */
12127#ifdef __cplusplus
12128extern "C"
12129#endif
12130char XpCreateContext ();
12131int
12132main ()
12133{
12134return XpCreateContext ();
12135 ;
12136 return 0;
12137}
12138_ACEOF
12139if ac_fn_c_try_link "$LINENO"; then :
12140 ac_cv_lib_Xp_XpCreateContext=yes
12141else
12142 ac_cv_lib_Xp_XpCreateContext=no
12143fi
12144rm -f core conftest.err conftest.$ac_objext \
12145 conftest$ac_exeext conftest.$ac_ext
12146LIBS=$ac_check_lib_save_LIBS
12147fi
12148{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12149$as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
a9bec17c 12150if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
067d23c9
KY
12151 LIBXP=-lXp
12152fi
12153
12154 else
12155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12156$as_echo_n "checking for LessTif where some systems put it... " >&6; }
a9bec17c 12157if test "${emacs_cv_lesstif+set}" = set; then :
067d23c9
KY
12158 $as_echo_n "(cached) " >&6
12159else
12160 # We put this in CFLAGS temporarily to precede other -I options
12161 # that might be in CFLAGS temporarily.
12162 # We put this in CPPFLAGS where it precedes the other -I options.
12163 OLD_CPPFLAGS=$CPPFLAGS
12164 OLD_CFLAGS=$CFLAGS
12165 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12166 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12168/* end confdefs.h. */
12169#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12170int
12171main ()
12172{
12173int x = 5;
12174 ;
12175 return 0;
12176}
12177_ACEOF
12178if ac_fn_c_try_compile "$LINENO"; then :
12179 emacs_cv_lesstif=yes
12180else
12181 emacs_cv_lesstif=no
12182fi
12183rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12184fi
12185{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12186$as_echo "$emacs_cv_lesstif" >&6; }
12187 if test $emacs_cv_lesstif = yes; then
12188 # Make sure this -I option remains in CPPFLAGS after it is set
12189 # back to REAL_CPPFLAGS.
12190 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12191 # have those other -I options anyway. Ultimately, having this
12192 # directory ultimately in CPPFLAGS will be enough.
12193 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12194 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12195 else
12196 CFLAGS=$OLD_CFLAGS
12197 CPPFLAGS=$OLD_CPPFLAGS
12198 fi
12199 fi
fd3e94ec
GM
12200 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12201if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12202
12203else
12204 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12205fi
12206
12207
067d23c9
KY
12208fi
12209
12210
12211USE_TOOLKIT_SCROLL_BARS=no
12212if test "${with_toolkit_scroll_bars}" != "no"; then
12213 if test "${USE_X_TOOLKIT}" != "none"; then
12214 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12215 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12216
12217 HAVE_XAW3D=no
12218 USE_TOOLKIT_SCROLL_BARS=yes
fd3e94ec 12219 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
067d23c9
KY
12220 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12221
12222 USE_TOOLKIT_SCROLL_BARS=yes
12223 fi
12224 elif test "${HAVE_GTK}" = "yes"; then
12225 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12226
12227 USE_TOOLKIT_SCROLL_BARS=yes
12228 elif test "${HAVE_NS}" = "yes"; then
12229 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12230
12231 USE_TOOLKIT_SCROLL_BARS=yes
12232 fi
12233fi
12234
12235cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12236/* end confdefs.h. */
12237
12238 #include <X11/Xlib.h>
12239 #include <X11/Xresource.h>
12240int
12241main ()
12242{
12243XIMProc callback;
12244 ;
12245 return 0;
12246}
12247_ACEOF
12248if ac_fn_c_try_compile "$LINENO"; then :
12249 HAVE_XIM=yes
12250
12251$as_echo "#define HAVE_XIM 1" >>confdefs.h
12252
12253else
12254 HAVE_XIM=no
12255fi
12256rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12257
12258
12259if test "${with_xim}" != "no"; then
12260
12261$as_echo "#define USE_XIM 1" >>confdefs.h
12262
12263fi
12264
12265
12266if test "${HAVE_XIM}" != "no"; then
12267 late_CFLAGS=$CFLAGS
12268 if test "$GCC" = yes; then
12269 CFLAGS="$CFLAGS --pedantic-errors"
12270 fi
12271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12272/* end confdefs.h. */
12273
12274#include <X11/Xlib.h>
12275#include <X11/Xresource.h>
12276int
12277main ()
12278{
12279Display *display;
12280XrmDatabase db;
12281char *res_name;
12282char *res_class;
12283XIMProc callback;
12284XPointer *client_data;
12285#ifndef __GNUC__
12286/* If we're not using GCC, it's probably not XFree86, and this is
12287 probably right, but we can't use something like --pedantic-errors. */
12288extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12289 char*, XIMProc, XPointer*);
12290#endif
12291(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12292 client_data);
12293 ;
12294 return 0;
12295}
12296_ACEOF
12297if ac_fn_c_try_compile "$LINENO"; then :
12298 emacs_cv_arg6_star=yes
12299fi
12300rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12301 if test "$emacs_cv_arg6_star" = yes; then
12302 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12303
12304 else
12305 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12306
12307 fi
12308 CFLAGS=$late_CFLAGS
12309fi
12310
12311### Start of font-backend (under any platform) section.
12312# (nothing here yet -- this is a placeholder)
12313### End of font-backend (under any platform) section.
12314
12315### Start of font-backend (under X11) section.
12316if test "${HAVE_X11}" = "yes"; then
12317
12318 succeeded=no
12319
12320 # Extract the first word of "pkg-config", so it can be a program name with args.
12321set dummy pkg-config; ac_word=$2
12322{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12323$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 12324if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
12325 $as_echo_n "(cached) " >&6
12326else
12327 case $PKG_CONFIG in
12328 [\\/]* | ?:[\\/]*)
12329 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12330 ;;
12331 *)
12332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12333for as_dir in $PATH
12334do
12335 IFS=$as_save_IFS
12336 test -z "$as_dir" && as_dir=.
12337 for ac_exec_ext in '' $ac_executable_extensions; do
12338 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12339 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12341 break 2
12342 fi
12343done
12344 done
12345IFS=$as_save_IFS
12346
12347 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12348 ;;
12349esac
12350fi
12351PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12352if test -n "$PKG_CONFIG"; then
12353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12354$as_echo "$PKG_CONFIG" >&6; }
12355else
12356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12357$as_echo "no" >&6; }
12358fi
12359
12360
12361
12362 if test "$PKG_CONFIG" = "no" ; then
12363 HAVE_FC=no
12364 else
12365 PKG_CONFIG_MIN_VERSION=0.9.0
12366 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12368$as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12369
12370 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then
12371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12372$as_echo "yes" >&6; }
12373 succeeded=yes
12374
12375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5
12376$as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; }
12377 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
12378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5
12379$as_echo "$FONTCONFIG_CFLAGS" >&6; }
12380
12381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5
12382$as_echo_n "checking FONTCONFIG_LIBS... " >&6; }
12383 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
12384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5
12385$as_echo "$FONTCONFIG_LIBS" >&6; }
12386 else
12387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12388$as_echo "no" >&6; }
12389 FONTCONFIG_CFLAGS=""
12390 FONTCONFIG_LIBS=""
12391 ## If we have a custom action on failure, don't print errors, but
12392 ## do set a variable so people can do so.
12393 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
12394
12395 fi
12396
12397
12398
12399 else
12400 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12401 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12402 fi
12403 fi
12404
12405 if test $succeeded = yes; then
12406 HAVE_FC=yes
12407 else
12408 HAVE_FC=no
12409 fi
12410
12411
12412 ## Use -lXft if available, unless `--with-xft=no'.
12413 HAVE_XFT=maybe
12414 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12415 with_xft="no";
12416 fi
12417 if test "x${with_xft}" != "xno"; then
12418
12419
12420 succeeded=no
12421
12422 # Extract the first word of "pkg-config", so it can be a program name with args.
12423set dummy pkg-config; ac_word=$2
12424{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12425$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 12426if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
12427 $as_echo_n "(cached) " >&6
12428else
12429 case $PKG_CONFIG in
12430 [\\/]* | ?:[\\/]*)
12431 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12432 ;;
12433 *)
12434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12435for as_dir in $PATH
12436do
12437 IFS=$as_save_IFS
12438 test -z "$as_dir" && as_dir=.
12439 for ac_exec_ext in '' $ac_executable_extensions; do
12440 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12441 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12443 break 2
12444 fi
12445done
12446 done
12447IFS=$as_save_IFS
12448
12449 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12450 ;;
12451esac
12452fi
12453PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12454if test -n "$PKG_CONFIG"; then
12455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12456$as_echo "$PKG_CONFIG" >&6; }
12457else
12458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12459$as_echo "no" >&6; }
12460fi
12461
12462
12463
12464 if test "$PKG_CONFIG" = "no" ; then
12465 HAVE_XFT=no
12466 else
12467 PKG_CONFIG_MIN_VERSION=0.9.0
12468 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12470$as_echo_n "checking for xft >= 0.13.0... " >&6; }
12471
12472 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
12473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12474$as_echo "yes" >&6; }
12475 succeeded=yes
12476
12477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5
12478$as_echo_n "checking XFT_CFLAGS... " >&6; }
12479 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
12480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5
12481$as_echo "$XFT_CFLAGS" >&6; }
12482
12483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5
12484$as_echo_n "checking XFT_LIBS... " >&6; }
12485 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
12486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5
12487$as_echo "$XFT_LIBS" >&6; }
12488 else
12489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12490$as_echo "no" >&6; }
12491 XFT_CFLAGS=""
12492 XFT_LIBS=""
12493 ## If we have a custom action on failure, don't print errors, but
12494 ## do set a variable so people can do so.
12495 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
12496
12497 fi
12498
12499
12500
12501 else
12502 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12503 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12504 fi
12505 fi
12506
12507 if test $succeeded = yes; then
12508 :
12509 else
12510 HAVE_XFT=no
12511 fi
12512
12513 ## Because xftfont.c uses XRenderQueryExtension, we also
12514 ## need to link to -lXrender.
12515 HAVE_XRENDER=no
12516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12517$as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
a9bec17c 12518if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
067d23c9
KY
12519 $as_echo_n "(cached) " >&6
12520else
12521 ac_check_lib_save_LIBS=$LIBS
12522LIBS="-lXrender $LIBS"
12523cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12524/* end confdefs.h. */
12525
12526/* Override any GCC internal prototype to avoid an error.
12527 Use char because int might match the return type of a GCC
12528 builtin and then its argument prototype would still apply. */
12529#ifdef __cplusplus
12530extern "C"
12531#endif
12532char XRenderQueryExtension ();
12533int
12534main ()
12535{
12536return XRenderQueryExtension ();
12537 ;
12538 return 0;
12539}
12540_ACEOF
12541if ac_fn_c_try_link "$LINENO"; then :
12542 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12543else
12544 ac_cv_lib_Xrender_XRenderQueryExtension=no
12545fi
12546rm -f core conftest.err conftest.$ac_objext \
12547 conftest$ac_exeext conftest.$ac_ext
12548LIBS=$ac_check_lib_save_LIBS
12549fi
12550{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12551$as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
a9bec17c 12552if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
067d23c9
KY
12553 HAVE_XRENDER=yes
12554fi
12555
12556 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12557 OLD_CPPFLAGS="$CPPFLAGS"
12558 OLD_CFLAGS="$CFLAGS"
12559 OLD_LIBS="$LIBS"
12560 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12561 CFLAGS="$CFLAGS $XFT_CFLAGS"
12562 XFT_LIBS="-lXrender $XFT_LIBS"
12563 LIBS="$XFT_LIBS $LIBS"
12564 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
a9bec17c 12565if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
067d23c9
KY
12566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12567$as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
a9bec17c 12568if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
067d23c9
KY
12569 $as_echo_n "(cached) " >&6
12570else
12571 ac_check_lib_save_LIBS=$LIBS
12572LIBS="-lXft $XFT_LIBS $LIBS"
12573cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12574/* end confdefs.h. */
12575
12576/* Override any GCC internal prototype to avoid an error.
12577 Use char because int might match the return type of a GCC
12578 builtin and then its argument prototype would still apply. */
12579#ifdef __cplusplus
12580extern "C"
12581#endif
12582char XftFontOpen ();
12583int
12584main ()
12585{
12586return XftFontOpen ();
12587 ;
12588 return 0;
12589}
12590_ACEOF
12591if ac_fn_c_try_link "$LINENO"; then :
12592 ac_cv_lib_Xft_XftFontOpen=yes
12593else
12594 ac_cv_lib_Xft_XftFontOpen=no
12595fi
12596rm -f core conftest.err conftest.$ac_objext \
12597 conftest$ac_exeext conftest.$ac_ext
12598LIBS=$ac_check_lib_save_LIBS
12599fi
12600{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12601$as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
a9bec17c 12602if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
067d23c9
KY
12603 HAVE_XFT=yes
12604fi
12605
12606fi
12607
12608
12609
12610 if test "${HAVE_XFT}" = "yes"; then
12611
12612$as_echo "#define HAVE_XFT 1" >>confdefs.h
12613
12614
12615 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12616 else
12617 CPPFLAGS="$OLD_CPPFLAGS"
12618 CFLAGS="$OLD_CFLAGS"
12619 LIBS="$OLD_LIBS"
12620 fi # "${HAVE_XFT}" = "yes"
12621 fi # "$HAVE_XFT" != no
12622 fi # "x${with_xft}" != "xno"
12623
067d23c9
KY
12624 ## We used to allow building with FreeType and without Xft.
12625 ## However, the ftx font backend driver is not in good shape.
7834125e
GM
12626 if test "$HAVE_XFT" != "yes"; then
12627 HAVE_XFT=no
12628 HAVE_FREETYPE=no
12629 else
12630
12631 succeeded=no
12632
12633 # Extract the first word of "pkg-config", so it can be a program name with args.
12634set dummy pkg-config; ac_word=$2
12635{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12636$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 12637if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
7834125e
GM
12638 $as_echo_n "(cached) " >&6
12639else
12640 case $PKG_CONFIG in
12641 [\\/]* | ?:[\\/]*)
12642 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12643 ;;
12644 *)
12645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12646for as_dir in $PATH
12647do
12648 IFS=$as_save_IFS
12649 test -z "$as_dir" && as_dir=.
12650 for ac_exec_ext in '' $ac_executable_extensions; do
12651 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12652 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12654 break 2
12655 fi
12656done
12657 done
12658IFS=$as_save_IFS
12659
12660 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12661 ;;
12662esac
12663fi
12664PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12665if test -n "$PKG_CONFIG"; then
12666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12667$as_echo "$PKG_CONFIG" >&6; }
12668else
12669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12670$as_echo "no" >&6; }
12671fi
12672
12673
12674
12675 if test "$PKG_CONFIG" = "no" ; then
12676 HAVE_FREETYPE=no
12677 else
12678 PKG_CONFIG_MIN_VERSION=0.9.0
12679 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12681$as_echo_n "checking for freetype2... " >&6; }
12682
12683 if $PKG_CONFIG --exists "freetype2" 2>&5; then
12684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12685$as_echo "yes" >&6; }
12686 succeeded=yes
12687
12688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FREETYPE_CFLAGS" >&5
12689$as_echo_n "checking FREETYPE_CFLAGS... " >&6; }
12690 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2"|sed -e 's,///*,/,g'`
12691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_CFLAGS" >&5
12692$as_echo "$FREETYPE_CFLAGS" >&6; }
12693
12694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FREETYPE_LIBS" >&5
12695$as_echo_n "checking FREETYPE_LIBS... " >&6; }
12696 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2"|sed -e 's,///*,/,g'`
12697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIBS" >&5
12698$as_echo "$FREETYPE_LIBS" >&6; }
12699 else
12700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12701$as_echo "no" >&6; }
12702 FREETYPE_CFLAGS=""
12703 FREETYPE_LIBS=""
12704 ## If we have a custom action on failure, don't print errors, but
12705 ## do set a variable so people can do so.
12706 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
12707
12708 fi
12709
12710
12711
12712 else
12713 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12714 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12715 fi
12716 fi
12717
12718 if test $succeeded = yes; then
12719 HAVE_FREETYPE=yes
12720 else
12721 HAVE_FREETYPE=no
12722 fi
12723
12724
a9bec17c 12725 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
7834125e 12726 fi
067d23c9
KY
12727
12728 HAVE_LIBOTF=no
12729 if test "${HAVE_FREETYPE}" = "yes"; then
12730
12731$as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12732
12733 if test "${with_libotf}" != "no"; then
12734
12735 succeeded=no
12736
12737 # Extract the first word of "pkg-config", so it can be a program name with args.
12738set dummy pkg-config; ac_word=$2
12739{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12740$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 12741if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
12742 $as_echo_n "(cached) " >&6
12743else
12744 case $PKG_CONFIG in
12745 [\\/]* | ?:[\\/]*)
12746 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12747 ;;
12748 *)
12749 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12750for as_dir in $PATH
12751do
12752 IFS=$as_save_IFS
12753 test -z "$as_dir" && as_dir=.
12754 for ac_exec_ext in '' $ac_executable_extensions; do
12755 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12756 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12757 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12758 break 2
12759 fi
12760done
12761 done
12762IFS=$as_save_IFS
12763
12764 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12765 ;;
12766esac
12767fi
12768PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12769if test -n "$PKG_CONFIG"; then
12770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12771$as_echo "$PKG_CONFIG" >&6; }
12772else
12773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12774$as_echo "no" >&6; }
12775fi
12776
12777
12778
12779 if test "$PKG_CONFIG" = "no" ; then
12780 HAVE_LIBOTF=no
12781 else
12782 PKG_CONFIG_MIN_VERSION=0.9.0
12783 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12785$as_echo_n "checking for libotf... " >&6; }
12786
12787 if $PKG_CONFIG --exists "libotf" 2>&5; then
12788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12789$as_echo "yes" >&6; }
12790 succeeded=yes
12791
12792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5
12793$as_echo_n "checking LIBOTF_CFLAGS... " >&6; }
12794 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'`
12795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5
12796$as_echo "$LIBOTF_CFLAGS" >&6; }
12797
12798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5
12799$as_echo_n "checking LIBOTF_LIBS... " >&6; }
12800 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'`
12801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5
12802$as_echo "$LIBOTF_LIBS" >&6; }
12803 else
12804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12805$as_echo "no" >&6; }
12806 LIBOTF_CFLAGS=""
12807 LIBOTF_LIBS=""
12808 ## If we have a custom action on failure, don't print errors, but
12809 ## do set a variable so people can do so.
12810 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
12811
12812 fi
12813
12814
12815
12816 else
12817 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12818 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12819 fi
12820 fi
12821
12822 if test $succeeded = yes; then
12823 HAVE_LIBOTF=yes
12824 else
12825 HAVE_LIBOTF=no
12826 fi
12827
12828 if test "$HAVE_LIBOTF" = "yes"; then
12829
12830$as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12831
12832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12833$as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
a9bec17c 12834if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
067d23c9
KY
12835 $as_echo_n "(cached) " >&6
12836else
12837 ac_check_lib_save_LIBS=$LIBS
12838LIBS="-lotf $LIBS"
12839cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12840/* end confdefs.h. */
12841
12842/* Override any GCC internal prototype to avoid an error.
12843 Use char because int might match the return type of a GCC
12844 builtin and then its argument prototype would still apply. */
12845#ifdef __cplusplus
12846extern "C"
12847#endif
12848char OTF_get_variation_glyphs ();
12849int
12850main ()
12851{
12852return OTF_get_variation_glyphs ();
12853 ;
12854 return 0;
12855}
12856_ACEOF
12857if ac_fn_c_try_link "$LINENO"; then :
12858 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12859else
12860 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12861fi
12862rm -f core conftest.err conftest.$ac_objext \
12863 conftest$ac_exeext conftest.$ac_ext
12864LIBS=$ac_check_lib_save_LIBS
12865fi
12866{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12867$as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
a9bec17c 12868if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
067d23c9
KY
12869 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12870else
12871 HAVE_OTF_GET_VARIATION_GLYPHS=no
12872fi
12873
12874 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12875
12876$as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12877
12878 fi
12879 fi
12880 fi
12881 fi
12882
12883 HAVE_M17N_FLT=no
12884 if test "${HAVE_LIBOTF}" = yes; then
12885 if test "${with_m17n_flt}" != "no"; then
12886
12887 succeeded=no
12888
12889 # Extract the first word of "pkg-config", so it can be a program name with args.
12890set dummy pkg-config; ac_word=$2
12891{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12892$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 12893if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
12894 $as_echo_n "(cached) " >&6
12895else
12896 case $PKG_CONFIG in
12897 [\\/]* | ?:[\\/]*)
12898 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12899 ;;
12900 *)
12901 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12902for as_dir in $PATH
12903do
12904 IFS=$as_save_IFS
12905 test -z "$as_dir" && as_dir=.
12906 for ac_exec_ext in '' $ac_executable_extensions; do
12907 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12908 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12909 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12910 break 2
12911 fi
12912done
12913 done
12914IFS=$as_save_IFS
12915
12916 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12917 ;;
12918esac
12919fi
12920PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12921if test -n "$PKG_CONFIG"; then
12922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12923$as_echo "$PKG_CONFIG" >&6; }
12924else
12925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12926$as_echo "no" >&6; }
12927fi
12928
12929
12930
12931 if test "$PKG_CONFIG" = "no" ; then
12932 HAVE_M17N_FLT=no
12933 else
12934 PKG_CONFIG_MIN_VERSION=0.9.0
12935 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12937$as_echo_n "checking for m17n-flt... " >&6; }
12938
12939 if $PKG_CONFIG --exists "m17n-flt" 2>&5; then
12940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12941$as_echo "yes" >&6; }
12942 succeeded=yes
12943
12944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5
12945$as_echo_n "checking M17N_FLT_CFLAGS... " >&6; }
12946 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'`
12947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5
12948$as_echo "$M17N_FLT_CFLAGS" >&6; }
12949
12950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5
12951$as_echo_n "checking M17N_FLT_LIBS... " >&6; }
12952 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'`
12953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5
12954$as_echo "$M17N_FLT_LIBS" >&6; }
12955 else
12956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12957$as_echo "no" >&6; }
12958 M17N_FLT_CFLAGS=""
12959 M17N_FLT_LIBS=""
12960 ## If we have a custom action on failure, don't print errors, but
12961 ## do set a variable so people can do so.
12962 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
12963
12964 fi
12965
12966
12967
12968 else
12969 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12970 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12971 fi
12972 fi
12973
12974 if test $succeeded = yes; then
12975 HAVE_M17N_FLT=yes
12976 else
12977 HAVE_M17N_FLT=no
12978 fi
12979
12980 if test "$HAVE_M17N_FLT" = "yes"; then
12981
12982$as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12983
12984 fi
12985 fi
12986 fi
12987else
12988 HAVE_XFT=no
12989 HAVE_FREETYPE=no
12990 HAVE_LIBOTF=no
12991 HAVE_M17N_FLT=no
12992fi
12993
12994### End of font-backend (under X11) section.
12995
12996
12997
12998
12999
13000
13001
13002
13003
13004
13005### Use -lXpm if available, unless `--with-xpm=no'.
13006HAVE_XPM=no
13007LIBXPM=
13008if test "${HAVE_X11}" = "yes"; then
13009 if test "${with_xpm}" != "no"; then
13010 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
a9bec17c 13011if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
067d23c9
KY
13012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13013$as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
a9bec17c 13014if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
067d23c9
KY
13015 $as_echo_n "(cached) " >&6
13016else
13017 ac_check_lib_save_LIBS=$LIBS
13018LIBS="-lXpm -lX11 $LIBS"
13019cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13020/* end confdefs.h. */
13021
13022/* Override any GCC internal prototype to avoid an error.
13023 Use char because int might match the return type of a GCC
13024 builtin and then its argument prototype would still apply. */
13025#ifdef __cplusplus
13026extern "C"
13027#endif
13028char XpmReadFileToPixmap ();
13029int
13030main ()
13031{
13032return XpmReadFileToPixmap ();
13033 ;
13034 return 0;
13035}
13036_ACEOF
13037if ac_fn_c_try_link "$LINENO"; then :
13038 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13039else
13040 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13041fi
13042rm -f core conftest.err conftest.$ac_objext \
13043 conftest$ac_exeext conftest.$ac_ext
13044LIBS=$ac_check_lib_save_LIBS
13045fi
13046{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13047$as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
a9bec17c 13048if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
067d23c9
KY
13049 HAVE_XPM=yes
13050fi
13051
13052fi
13053
13054
13055 if test "${HAVE_XPM}" = "yes"; then
13056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13057$as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13059/* end confdefs.h. */
13060#include "X11/xpm.h"
13061#ifndef XpmReturnAllocPixels
13062no_return_alloc_pixels
13063#endif
13064
13065_ACEOF
13066if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13067 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13068 HAVE_XPM=no
13069else
13070 HAVE_XPM=yes
13071fi
13072rm -f conftest*
13073
13074
13075 if test "${HAVE_XPM}" = "yes"; then
13076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13077$as_echo "yes" >&6; }
13078 else
13079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13080$as_echo "no" >&6; }
13081 fi
13082 fi
13083 fi
13084
13085 if test "${HAVE_XPM}" = "yes"; then
13086
13087$as_echo "#define HAVE_XPM 1" >>confdefs.h
13088
13089 LIBXPM=-lXpm
13090 fi
13091fi
13092
13093
13094### Use -ljpeg if available, unless `--with-jpeg=no'.
13095HAVE_JPEG=no
13096LIBJPEG=
13097if test "${HAVE_X11}" = "yes"; then
13098 if test "${with_jpeg}" != "no"; then
13099 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
a9bec17c 13100if test "x$ac_cv_header_jerror_h" = x""yes; then :
067d23c9
KY
13101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13102$as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
a9bec17c 13103if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
067d23c9
KY
13104 $as_echo_n "(cached) " >&6
13105else
13106 ac_check_lib_save_LIBS=$LIBS
13107LIBS="-ljpeg $LIBS"
13108cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13109/* end confdefs.h. */
13110
13111/* Override any GCC internal prototype to avoid an error.
13112 Use char because int might match the return type of a GCC
13113 builtin and then its argument prototype would still apply. */
13114#ifdef __cplusplus
13115extern "C"
13116#endif
13117char jpeg_destroy_compress ();
13118int
13119main ()
13120{
13121return jpeg_destroy_compress ();
13122 ;
13123 return 0;
13124}
13125_ACEOF
13126if ac_fn_c_try_link "$LINENO"; then :
13127 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13128else
13129 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13130fi
13131rm -f core conftest.err conftest.$ac_objext \
13132 conftest$ac_exeext conftest.$ac_ext
13133LIBS=$ac_check_lib_save_LIBS
13134fi
13135{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13136$as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
a9bec17c 13137if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
067d23c9
KY
13138 HAVE_JPEG=yes
13139fi
13140
13141fi
13142
13143
13144 fi
13145
13146 if test "${HAVE_JPEG}" = "yes"; then
13147 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13148
13149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13150/* end confdefs.h. */
13151#include <jpeglib.h>
13152 version=JPEG_LIB_VERSION
13153
13154_ACEOF
13155if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13156 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13157 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13158
13159else
13160 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13161$as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13162 HAVE_JPEG=no
13163fi
13164rm -f conftest*
13165
13166 fi
13167 if test "${HAVE_JPEG}" = "yes"; then
13168 LIBJPEG=-ljpeg
13169 fi
13170fi
13171
13172
13173### Use -lpng if available, unless `--with-png=no'.
13174HAVE_PNG=no
13175LIBPNG=
13176if test "${HAVE_X11}" = "yes"; then
13177 if test "${with_png}" != "no"; then
13178 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13179 # in /usr/include/libpng.
13180 for ac_header in png.h libpng/png.h
13181do :
13182 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13183ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
a9bec17c
GM
13184eval as_val=\$$as_ac_Header
13185 if test "x$as_val" = x""yes; then :
067d23c9
KY
13186 cat >>confdefs.h <<_ACEOF
13187#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13188_ACEOF
13189
13190fi
13191
13192done
13193
13194 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13196$as_echo_n "checking for png_get_channels in -lpng... " >&6; }
a9bec17c 13197if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
067d23c9
KY
13198 $as_echo_n "(cached) " >&6
13199else
13200 ac_check_lib_save_LIBS=$LIBS
13201LIBS="-lpng -lz -lm $LIBS"
13202cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13203/* end confdefs.h. */
13204
13205/* Override any GCC internal prototype to avoid an error.
13206 Use char because int might match the return type of a GCC
13207 builtin and then its argument prototype would still apply. */
13208#ifdef __cplusplus
13209extern "C"
13210#endif
13211char png_get_channels ();
13212int
13213main ()
13214{
13215return png_get_channels ();
13216 ;
13217 return 0;
13218}
13219_ACEOF
13220if ac_fn_c_try_link "$LINENO"; then :
13221 ac_cv_lib_png_png_get_channels=yes
13222else
13223 ac_cv_lib_png_png_get_channels=no
13224fi
13225rm -f core conftest.err conftest.$ac_objext \
13226 conftest$ac_exeext conftest.$ac_ext
13227LIBS=$ac_check_lib_save_LIBS
13228fi
13229{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13230$as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
a9bec17c 13231if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
067d23c9
KY
13232 HAVE_PNG=yes
13233fi
13234
13235 fi
13236 fi
13237
13238 if test "${HAVE_PNG}" = "yes"; then
13239
13240$as_echo "#define HAVE_PNG 1" >>confdefs.h
13241
13242 LIBPNG="-lpng -lz -lm"
13243 fi
13244fi
13245
13246
13247### Use -ltiff if available, unless `--with-tiff=no'.
13248HAVE_TIFF=no
13249LIBTIFF=
13250if test "${HAVE_X11}" = "yes"; then
13251 if test "${with_tiff}" != "no"; then
13252 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
a9bec17c 13253if test "x$ac_cv_header_tiffio_h" = x""yes; then :
067d23c9
KY
13254 tifflibs="-lz -lm"
13255 # At least one tiff package requires the jpeg library.
13256 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13258$as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
a9bec17c 13259if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
067d23c9
KY
13260 $as_echo_n "(cached) " >&6
13261else
13262 ac_check_lib_save_LIBS=$LIBS
13263LIBS="-ltiff $tifflibs $LIBS"
13264cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13265/* end confdefs.h. */
13266
13267/* Override any GCC internal prototype to avoid an error.
13268 Use char because int might match the return type of a GCC
13269 builtin and then its argument prototype would still apply. */
13270#ifdef __cplusplus
13271extern "C"
13272#endif
13273char TIFFGetVersion ();
13274int
13275main ()
13276{
13277return TIFFGetVersion ();
13278 ;
13279 return 0;
13280}
13281_ACEOF
13282if ac_fn_c_try_link "$LINENO"; then :
13283 ac_cv_lib_tiff_TIFFGetVersion=yes
13284else
13285 ac_cv_lib_tiff_TIFFGetVersion=no
13286fi
13287rm -f core conftest.err conftest.$ac_objext \
13288 conftest$ac_exeext conftest.$ac_ext
13289LIBS=$ac_check_lib_save_LIBS
13290fi
13291{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13292$as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
a9bec17c 13293if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
067d23c9
KY
13294 HAVE_TIFF=yes
13295fi
13296
13297fi
13298
13299
13300 fi
13301
13302 if test "${HAVE_TIFF}" = "yes"; then
13303
13304$as_echo "#define HAVE_TIFF 1" >>confdefs.h
13305
13306 LIBTIFF=-ltiff
13307 fi
13308fi
13309
13310
13311### Use -lgif or -lungif if available, unless `--with-gif=no'.
13312HAVE_GIF=no
13313LIBGIF=
13314if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
13315 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
a9bec17c 13316if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
067d23c9
KY
13317 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13318# Earlier versions can crash Emacs.
13319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13320$as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
a9bec17c 13321if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
067d23c9
KY
13322 $as_echo_n "(cached) " >&6
13323else
13324 ac_check_lib_save_LIBS=$LIBS
13325LIBS="-lgif $LIBS"
13326cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13327/* end confdefs.h. */
13328
13329/* Override any GCC internal prototype to avoid an error.
13330 Use char because int might match the return type of a GCC
13331 builtin and then its argument prototype would still apply. */
13332#ifdef __cplusplus
13333extern "C"
13334#endif
13335char EGifPutExtensionLast ();
13336int
13337main ()
13338{
13339return EGifPutExtensionLast ();
13340 ;
13341 return 0;
13342}
13343_ACEOF
13344if ac_fn_c_try_link "$LINENO"; then :
13345 ac_cv_lib_gif_EGifPutExtensionLast=yes
13346else
13347 ac_cv_lib_gif_EGifPutExtensionLast=no
13348fi
13349rm -f core conftest.err conftest.$ac_objext \
13350 conftest$ac_exeext conftest.$ac_ext
13351LIBS=$ac_check_lib_save_LIBS
13352fi
13353{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13354$as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
a9bec17c 13355if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
067d23c9
KY
13356 HAVE_GIF=yes
13357else
13358 HAVE_GIF=maybe
13359fi
13360
13361fi
13362
13363
13364
13365 if test "$HAVE_GIF" = yes; then
13366 LIBGIF=-lgif
13367 elif test "$HAVE_GIF" = maybe; then
13368# If gif_lib.h but no libgif, try libungif.
13369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13370$as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
a9bec17c 13371if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
067d23c9
KY
13372 $as_echo_n "(cached) " >&6
13373else
13374 ac_check_lib_save_LIBS=$LIBS
13375LIBS="-lungif $LIBS"
13376cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13377/* end confdefs.h. */
13378
13379/* Override any GCC internal prototype to avoid an error.
13380 Use char because int might match the return type of a GCC
13381 builtin and then its argument prototype would still apply. */
13382#ifdef __cplusplus
13383extern "C"
13384#endif
13385char EGifPutExtensionLast ();
13386int
13387main ()
13388{
13389return EGifPutExtensionLast ();
13390 ;
13391 return 0;
13392}
13393_ACEOF
13394if ac_fn_c_try_link "$LINENO"; then :
13395 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13396else
13397 ac_cv_lib_ungif_EGifPutExtensionLast=no
13398fi
13399rm -f core conftest.err conftest.$ac_objext \
13400 conftest$ac_exeext conftest.$ac_ext
13401LIBS=$ac_check_lib_save_LIBS
13402fi
13403{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13404$as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
a9bec17c 13405if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
067d23c9
KY
13406 HAVE_GIF=yes
13407else
13408 HAVE_GIF=no
13409fi
13410
13411 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13412 fi
13413
13414 if test "${HAVE_GIF}" = "yes"; then
13415
13416$as_echo "#define HAVE_GIF 1" >>confdefs.h
13417
13418 fi
13419fi
13420
13421
13422if test "${HAVE_X11}" = "yes"; then
13423 MISSING=""
13424 WITH_NO=""
13425 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13426 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13427 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13428 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13429 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13430 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13431 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13432 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13433 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13434 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13435
13436 if test "X${MISSING}" != X; then
a9bec17c 13437 as_fn_error "The following required libraries were not found:
067d23c9
KY
13438 $MISSING
13439Maybe some development libraries/packages are missing?
13440If you don't want to link with them give
13441 $WITH_NO
13442as options to configure" "$LINENO" 5
13443 fi
13444fi
13445
13446### Use -lgpm if available, unless `--with-gpm=no'.
13447HAVE_GPM=no
13448LIBGPM=
067d23c9
KY
13449if test "${with_gpm}" != "no"; then
13450 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
a9bec17c 13451if test "x$ac_cv_header_gpm_h" = x""yes; then :
067d23c9
KY
13452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13453$as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
a9bec17c 13454if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
067d23c9
KY
13455 $as_echo_n "(cached) " >&6
13456else
13457 ac_check_lib_save_LIBS=$LIBS
13458LIBS="-lgpm $LIBS"
13459cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13460/* end confdefs.h. */
13461
13462/* Override any GCC internal prototype to avoid an error.
13463 Use char because int might match the return type of a GCC
13464 builtin and then its argument prototype would still apply. */
13465#ifdef __cplusplus
13466extern "C"
13467#endif
13468char Gpm_Open ();
13469int
13470main ()
13471{
13472return Gpm_Open ();
13473 ;
13474 return 0;
13475}
13476_ACEOF
13477if ac_fn_c_try_link "$LINENO"; then :
13478 ac_cv_lib_gpm_Gpm_Open=yes
13479else
13480 ac_cv_lib_gpm_Gpm_Open=no
13481fi
13482rm -f core conftest.err conftest.$ac_objext \
13483 conftest$ac_exeext conftest.$ac_ext
13484LIBS=$ac_check_lib_save_LIBS
13485fi
13486{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13487$as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
a9bec17c 13488if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
067d23c9
KY
13489 HAVE_GPM=yes
13490fi
13491
13492fi
13493
13494
13495
13496 if test "${HAVE_GPM}" = "yes"; then
13497
13498$as_echo "#define HAVE_GPM 1" >>confdefs.h
13499
13500 LIBGPM=-lgpm
067d23c9
KY
13501 fi
13502fi
13503
13504
13505ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
a9bec17c 13506if test "x$ac_cv_header_malloc_malloc_h" = x""yes; then :
067d23c9
KY
13507
13508$as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
13509
13510fi
13511
13512
13513
13514C_SWITCH_X_SYSTEM=
13515### Use NeXTstep API to implement GUI.
13516if test "${HAVE_NS}" = "yes"; then
13517
13518$as_echo "#define HAVE_NS 1" >>confdefs.h
13519
13520 if test "${NS_IMPL_COCOA}" = "yes"; then
13521
13522$as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13523
067d23c9
KY
13524 fi
13525 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13526
13527$as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13528
13529 # See also .m.o rule in Makefile.in */
13530 # FIXME: are all these flags really needed? Document here why. */
eb39a72d 13531 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
39b3d70b
GM
13532 ## Extra CFLAGS applied to src/*.m files.
13533 GNU_OBJC_CFLAGS="$GNU_OBJC_CFLAGS -fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
067d23c9
KY
13534 fi
13535 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
13536
13537$as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
13538
13539 fi
13540 # We also have mouse menus.
13541 HAVE_MENUS=yes
13542 OTHER_FILES=ns-app
13543fi
13544
13545
13546### Use session management (-lSM -lICE) if available
13547HAVE_X_SM=no
13548LIBXSM=
13549if test "${HAVE_X11}" = "yes"; then
13550 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
a9bec17c 13551if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
067d23c9
KY
13552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13553$as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
a9bec17c 13554if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
067d23c9
KY
13555 $as_echo_n "(cached) " >&6
13556else
13557 ac_check_lib_save_LIBS=$LIBS
13558LIBS="-lSM -lICE $LIBS"
13559cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13560/* end confdefs.h. */
13561
13562/* Override any GCC internal prototype to avoid an error.
13563 Use char because int might match the return type of a GCC
13564 builtin and then its argument prototype would still apply. */
13565#ifdef __cplusplus
13566extern "C"
13567#endif
13568char SmcOpenConnection ();
13569int
13570main ()
13571{
13572return SmcOpenConnection ();
13573 ;
13574 return 0;
13575}
13576_ACEOF
13577if ac_fn_c_try_link "$LINENO"; then :
13578 ac_cv_lib_SM_SmcOpenConnection=yes
13579else
13580 ac_cv_lib_SM_SmcOpenConnection=no
13581fi
13582rm -f core conftest.err conftest.$ac_objext \
13583 conftest$ac_exeext conftest.$ac_ext
13584LIBS=$ac_check_lib_save_LIBS
13585fi
13586{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13587$as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
a9bec17c 13588if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
067d23c9
KY
13589 HAVE_X_SM=yes
13590fi
13591
13592fi
13593
13594
13595
13596 if test "${HAVE_X_SM}" = "yes"; then
13597
13598$as_echo "#define HAVE_X_SM 1" >>confdefs.h
13599
13600 LIBXSM="-lSM -lICE"
13601 case "$LIBS" in
13602 *-lSM*) ;;
13603 *) LIBS="$LIBXSM $LIBS" ;;
13604 esac
13605 fi
13606fi
13607
13608
13609### Use libxml (-lxml2) if available
2b1928b8 13610HAVE_LIBXML2=no
067d23c9
KY
13611if test "${with_xml2}" != "no"; then
13612 ### I'm not sure what the version number should be, so I just guessed.
13613
13614 succeeded=no
13615
13616 # Extract the first word of "pkg-config", so it can be a program name with args.
13617set dummy pkg-config; ac_word=$2
13618{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13619$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 13620if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
067d23c9
KY
13621 $as_echo_n "(cached) " >&6
13622else
13623 case $PKG_CONFIG in
13624 [\\/]* | ?:[\\/]*)
13625 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
13626 ;;
13627 *)
13628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13629for as_dir in $PATH
13630do
13631 IFS=$as_save_IFS
13632 test -z "$as_dir" && as_dir=.
13633 for ac_exec_ext in '' $ac_executable_extensions; do
13634 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13635 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
13636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13637 break 2
13638 fi
13639done
13640 done
13641IFS=$as_save_IFS
13642
13643 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
13644 ;;
13645esac
13646fi
13647PKG_CONFIG=$ac_cv_path_PKG_CONFIG
13648if test -n "$PKG_CONFIG"; then
13649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
13650$as_echo "$PKG_CONFIG" >&6; }
13651else
13652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13653$as_echo "no" >&6; }
13654fi
13655
13656
13657
13658 if test "$PKG_CONFIG" = "no" ; then
13659 HAVE_LIBXML2=no
13660 else
13661 PKG_CONFIG_MIN_VERSION=0.9.0
13662 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
dab73760
CY
13663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13664$as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
067d23c9 13665
dab73760 13666 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5; then
067d23c9
KY
13667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13668$as_echo "yes" >&6; }
13669 succeeded=yes
13670
13671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_CFLAGS" >&5
13672$as_echo_n "checking LIBXML2_CFLAGS... " >&6; }
dab73760 13673 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
067d23c9
KY
13674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_CFLAGS" >&5
13675$as_echo "$LIBXML2_CFLAGS" >&6; }
13676
13677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_LIBS" >&5
13678$as_echo_n "checking LIBXML2_LIBS... " >&6; }
dab73760 13679 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
067d23c9
KY
13680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_LIBS" >&5
13681$as_echo "$LIBXML2_LIBS" >&6; }
13682 else
13683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13684$as_echo "no" >&6; }
13685 LIBXML2_CFLAGS=""
13686 LIBXML2_LIBS=""
13687 ## If we have a custom action on failure, don't print errors, but
13688 ## do set a variable so people can do so.
dab73760 13689 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
067d23c9
KY
13690
13691 fi
13692
13693
13694
13695 else
13696 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13697 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13698 fi
13699 fi
13700
13701 if test $succeeded = yes; then
13702 HAVE_LIBXML2=yes
13703 else
13704 HAVE_LIBXML2=no
13705 fi
13706
13707 if test "${HAVE_LIBXML2}" = "yes"; then
13708 LIBS="$LIBXML2_LIBS $LIBS"
13709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13710$as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
a9bec17c 13711if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
067d23c9
KY
13712 $as_echo_n "(cached) " >&6
13713else
13714 ac_check_lib_save_LIBS=$LIBS
13715LIBS="-lxml2 $LIBS"
13716cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13717/* end confdefs.h. */
13718
13719/* Override any GCC internal prototype to avoid an error.
13720 Use char because int might match the return type of a GCC
13721 builtin and then its argument prototype would still apply. */
13722#ifdef __cplusplus
13723extern "C"
13724#endif
13725char htmlReadMemory ();
13726int
13727main ()
13728{
13729return htmlReadMemory ();
13730 ;
13731 return 0;
13732}
13733_ACEOF
13734if ac_fn_c_try_link "$LINENO"; then :
13735 ac_cv_lib_xml2_htmlReadMemory=yes
13736else
13737 ac_cv_lib_xml2_htmlReadMemory=no
13738fi
13739rm -f core conftest.err conftest.$ac_objext \
13740 conftest$ac_exeext conftest.$ac_ext
13741LIBS=$ac_check_lib_save_LIBS
13742fi
13743{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13744$as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
a9bec17c 13745if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
067d23c9
KY
13746 HAVE_LIBXML2=yes
13747else
13748 HAVE_LIBXML2=no
13749fi
13750
13751 if test "${HAVE_LIBXML2}" = "yes"; then
13752
13753$as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13754
13755 else
13756 LIBXML2_LIBS=""
13757 LIBXML2_CFLAGS=""
13758 fi
13759 fi
13760fi
13761
13762
13763
13764# If netdb.h doesn't declare h_errno, we must declare it by hand.
13765{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13766$as_echo_n "checking whether netdb declares h_errno... " >&6; }
a9bec17c 13767if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
067d23c9
KY
13768 $as_echo_n "(cached) " >&6
13769else
13770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13771/* end confdefs.h. */
13772#include <netdb.h>
13773int
13774main ()
13775{
13776return h_errno;
13777 ;
13778 return 0;
13779}
13780_ACEOF
13781if ac_fn_c_try_link "$LINENO"; then :
13782 emacs_cv_netdb_declares_h_errno=yes
13783else
13784 emacs_cv_netdb_declares_h_errno=no
13785fi
13786rm -f core conftest.err conftest.$ac_objext \
13787 conftest$ac_exeext conftest.$ac_ext
13788fi
13789{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13790$as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13791if test $emacs_cv_netdb_declares_h_errno = yes; then
13792
13793$as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13794
13795fi
13796
067d23c9
KY
13797# fmod, logb, and frexp are found in -lm on most systems.
13798# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
13799{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13800$as_echo_n "checking for sqrt in -lm... " >&6; }
a9bec17c 13801if test "${ac_cv_lib_m_sqrt+set}" = set; then :
067d23c9
KY
13802 $as_echo_n "(cached) " >&6
13803else
13804 ac_check_lib_save_LIBS=$LIBS
13805LIBS="-lm $LIBS"
13806cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13807/* end confdefs.h. */
13808
13809/* Override any GCC internal prototype to avoid an error.
13810 Use char because int might match the return type of a GCC
13811 builtin and then its argument prototype would still apply. */
13812#ifdef __cplusplus
13813extern "C"
13814#endif
13815char sqrt ();
13816int
13817main ()
13818{
13819return sqrt ();
13820 ;
13821 return 0;
13822}
13823_ACEOF
13824if ac_fn_c_try_link "$LINENO"; then :
13825 ac_cv_lib_m_sqrt=yes
13826else
13827 ac_cv_lib_m_sqrt=no
13828fi
13829rm -f core conftest.err conftest.$ac_objext \
13830 conftest$ac_exeext conftest.$ac_ext
13831LIBS=$ac_check_lib_save_LIBS
13832fi
13833{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13834$as_echo "$ac_cv_lib_m_sqrt" >&6; }
a9bec17c 13835if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
067d23c9
KY
13836 cat >>confdefs.h <<_ACEOF
13837#define HAVE_LIBM 1
13838_ACEOF
13839
13840 LIBS="-lm $LIBS"
13841
13842fi
13843
13844
13845# Check for mail-locking functions in a "mail" library. Probably this should
13846# have the same check as for liblockfile below.
13847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13848$as_echo_n "checking for maillock in -lmail... " >&6; }
a9bec17c 13849if test "${ac_cv_lib_mail_maillock+set}" = set; then :
067d23c9
KY
13850 $as_echo_n "(cached) " >&6
13851else
13852 ac_check_lib_save_LIBS=$LIBS
13853LIBS="-lmail $LIBS"
13854cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13855/* end confdefs.h. */
13856
13857/* Override any GCC internal prototype to avoid an error.
13858 Use char because int might match the return type of a GCC
13859 builtin and then its argument prototype would still apply. */
13860#ifdef __cplusplus
13861extern "C"
13862#endif
13863char maillock ();
13864int
13865main ()
13866{
13867return maillock ();
13868 ;
13869 return 0;
13870}
13871_ACEOF
13872if ac_fn_c_try_link "$LINENO"; then :
13873 ac_cv_lib_mail_maillock=yes
13874else
13875 ac_cv_lib_mail_maillock=no
13876fi
13877rm -f core conftest.err conftest.$ac_objext \
13878 conftest$ac_exeext conftest.$ac_ext
13879LIBS=$ac_check_lib_save_LIBS
13880fi
13881{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13882$as_echo "$ac_cv_lib_mail_maillock" >&6; }
a9bec17c 13883if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
067d23c9
KY
13884 have_mail=yes
13885else
13886 have_mail=no
13887fi
13888
13889if test $have_mail = yes; then
13890 LIBS_MAIL=-lmail
13891 LIBS="$LIBS_MAIL $LIBS"
13892
13893$as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13894
13895else
13896 LIBS_MAIL=
13897fi
13898{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13899$as_echo_n "checking for maillock in -llockfile... " >&6; }
a9bec17c 13900if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
067d23c9
KY
13901 $as_echo_n "(cached) " >&6
13902else
13903 ac_check_lib_save_LIBS=$LIBS
13904LIBS="-llockfile $LIBS"
13905cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13906/* end confdefs.h. */
13907
13908/* Override any GCC internal prototype to avoid an error.
13909 Use char because int might match the return type of a GCC
13910 builtin and then its argument prototype would still apply. */
13911#ifdef __cplusplus
13912extern "C"
13913#endif
13914char maillock ();
13915int
13916main ()
13917{
13918return maillock ();
13919 ;
13920 return 0;
13921}
13922_ACEOF
13923if ac_fn_c_try_link "$LINENO"; then :
13924 ac_cv_lib_lockfile_maillock=yes
13925else
13926 ac_cv_lib_lockfile_maillock=no
13927fi
13928rm -f core conftest.err conftest.$ac_objext \
13929 conftest$ac_exeext conftest.$ac_ext
13930LIBS=$ac_check_lib_save_LIBS
13931fi
13932{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13933$as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
a9bec17c 13934if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
067d23c9
KY
13935 have_lockfile=yes
13936else
13937 have_lockfile=no
13938fi
13939
13940if test $have_lockfile = yes; then
13941 LIBS_MAIL=-llockfile
13942 LIBS="$LIBS_MAIL $LIBS"
13943
13944$as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13945
13946else
13947# If we have the shared liblockfile, assume we must use it for mail
13948# locking (e.g. Debian). If we couldn't link against liblockfile
13949# (no liblockfile.a installed), ensure that we don't need to.
13950 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13951set dummy liblockfile.so; ac_word=$2
13952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13953$as_echo_n "checking for $ac_word... " >&6; }
a9bec17c 13954if test "${ac_cv_prog_liblockfile+set}" = set; then :
067d23c9
KY
13955 $as_echo_n "(cached) " >&6
13956else
13957 if test -n "$liblockfile"; then
13958 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13959else
13960as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13961as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13962for as_dir in $as_dummy
13963do
13964 IFS=$as_save_IFS
13965 test -z "$as_dir" && as_dir=.
13966 for ac_exec_ext in '' $ac_executable_extensions; do
13967 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13968 ac_cv_prog_liblockfile="yes"
13969 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13970 break 2
13971 fi
13972done
13973 done
13974IFS=$as_save_IFS
13975
13976 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13977fi
13978fi
13979liblockfile=$ac_cv_prog_liblockfile
13980if test -n "$liblockfile"; then
13981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13982$as_echo "$liblockfile" >&6; }
13983else
13984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13985$as_echo "no" >&6; }
13986fi
13987
13988
13989 if test $ac_cv_prog_liblockfile = yes; then
a9bec17c 13990 as_fn_error "Shared liblockfile found but can't link against it.
067d23c9
KY
13991This probably means that movemail could lose mail.
13992There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13993 fi
13994fi
13995for ac_func in touchlock
13996do :
13997 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
a9bec17c 13998if test "x$ac_cv_func_touchlock" = x""yes; then :
067d23c9
KY
13999 cat >>confdefs.h <<_ACEOF
14000#define HAVE_TOUCHLOCK 1
14001_ACEOF
14002
14003fi
14004done
14005
14006for ac_header in maillock.h
14007do :
14008 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
a9bec17c 14009if test "x$ac_cv_header_maillock_h" = x""yes; then :
067d23c9
KY
14010 cat >>confdefs.h <<_ACEOF
14011#define HAVE_MAILLOCK_H 1
14012_ACEOF
14013
14014fi
14015
14016done
14017
14018
14019
14020## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
14021## interlock access to the mail spool. The alternative is a lock file named
14022## /usr/spool/mail/$USER.lock.
14023mail_lock=no
14024case "$opsys" in
14025 aix4-2) mail_lock="lockf" ;;
14026
14027 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
14028
14029 ## On GNU/Linux systems, both methods are used by various mail programs.
14030 ## I assume most people are using newer mailers that have heard of flock.
14031 ## Change this if you need to.
14032 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
14033 ## configure gets the right answers, and that means *NOT* using flock.
14034 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
14035 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
14036 ## Debian maintainer hasn't provided a clean fix for Emacs.
14037 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
14038 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
14039 ## correct logic. -- fx
14040 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
14041 ## liblockfile is a Free Software replacement for libmail, used on
14042 ## Debian systems and elsewhere. -rfr.
14043 gnu-*)
14044 mail_lock="flock"
14045 if test $have_mail = yes || test $have_lockfile = yes; then
14046 test $ac_cv_header_maillock_h = yes && mail_lock=no
14047 fi
14048 ;;
14049esac
14050
14051BLESSMAIL_TARGET=
14052case "$mail_lock" in
14053 flock)
14054$as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
14055 ;;
14056
14057 lockf)
14058$as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
14059 ;;
14060
14061 *) BLESSMAIL_TARGET="need-blessmail" ;;
14062esac
14063
14064
14065
7d2a1c5e 14066for ac_func in gethostname getdomainname \
067d23c9
KY
14067rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
14068random lrand48 logb frexp fmod rint cbrt ftime setsid \
1fd182f0 14069strerror fpathconf select euidaccess getpagesize tzset setlocale \
067d23c9 14070utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
1fb8351b 14071__fpending mblen mbrlen mbsinit strsignal setitimer ualarm \
067d23c9 14072sendto recvfrom getsockopt setsockopt getsockname getpeername \
1fb8351b
GM
14073gai_strerror mkstemp getline getdelim mremap fsync sync \
14074difftime mempcpy mblen mbrlen posix_memalign \
a9bec17c 14075cfmakeraw cfsetspeed copysign __executable_start
067d23c9
KY
14076do :
14077 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14078ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
14079eval as_val=\$$as_ac_var
14080 if test "x$as_val" = x""yes; then :
067d23c9
KY
14081 cat >>confdefs.h <<_ACEOF
14082#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14083_ACEOF
14084
14085fi
14086done
14087
14088
2018939f
AS
14089{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
14090$as_echo_n "checking for __builtin_unwind_init... " >&6; }
a9bec17c 14091if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
2018939f
AS
14092 $as_echo_n "(cached) " >&6
14093else
14094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14095/* end confdefs.h. */
14096
14097int
14098main ()
14099{
14100__builtin_unwind_init ();
14101 ;
14102 return 0;
14103}
14104_ACEOF
14105if ac_fn_c_try_link "$LINENO"; then :
14106 emacs_cv_func___builtin_unwind_init=yes
14107else
14108 emacs_cv_func___builtin_unwind_init=no
14109fi
14110rm -f core conftest.err conftest.$ac_objext \
14111 conftest$ac_exeext conftest.$ac_ext
14112fi
14113{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
14114$as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
14115if test $emacs_cv_func___builtin_unwind_init = yes; then
14116
14117$as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
14118
14119fi
14120
067d23c9
KY
14121for ac_header in sys/un.h
14122do :
14123 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
a9bec17c 14124if test "x$ac_cv_header_sys_un_h" = x""yes; then :
067d23c9
KY
14125 cat >>confdefs.h <<_ACEOF
14126#define HAVE_SYS_UN_H 1
14127_ACEOF
14128
14129fi
14130
14131done
14132
14133
1f5d53eb
PE
14134{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14135$as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
a9bec17c 14136if test "${ac_cv_sys_largefile_source+set}" = set; then :
067d23c9
KY
14137 $as_echo_n "(cached) " >&6
14138else
1f5d53eb
PE
14139 while :; do
14140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 14141/* end confdefs.h. */
1f5d53eb
PE
14142#include <sys/types.h> /* for off_t */
14143 #include <stdio.h>
067d23c9
KY
14144int
14145main ()
14146{
1f5d53eb
PE
14147int (*fp) (FILE *, off_t, int) = fseeko;
14148 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
067d23c9
KY
14149 ;
14150 return 0;
14151}
14152_ACEOF
14153if ac_fn_c_try_link "$LINENO"; then :
1f5d53eb 14154 ac_cv_sys_largefile_source=no; break
067d23c9
KY
14155fi
14156rm -f core conftest.err conftest.$ac_objext \
14157 conftest$ac_exeext conftest.$ac_ext
1f5d53eb 14158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 14159/* end confdefs.h. */
1f5d53eb
PE
14160#define _LARGEFILE_SOURCE 1
14161#include <sys/types.h> /* for off_t */
14162 #include <stdio.h>
067d23c9
KY
14163int
14164main ()
14165{
1f5d53eb
PE
14166int (*fp) (FILE *, off_t, int) = fseeko;
14167 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
067d23c9
KY
14168 ;
14169 return 0;
14170}
14171_ACEOF
14172if ac_fn_c_try_link "$LINENO"; then :
1f5d53eb 14173 ac_cv_sys_largefile_source=1; break
067d23c9
KY
14174fi
14175rm -f core conftest.err conftest.$ac_objext \
14176 conftest$ac_exeext conftest.$ac_ext
1f5d53eb
PE
14177 ac_cv_sys_largefile_source=unknown
14178 break
14179done
067d23c9 14180fi
1f5d53eb
PE
14181{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14182$as_echo "$ac_cv_sys_largefile_source" >&6; }
14183case $ac_cv_sys_largefile_source in #(
14184 no | unknown) ;;
14185 *)
14186cat >>confdefs.h <<_ACEOF
14187#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14188_ACEOF
14189;;
14190esac
14191rm -rf conftest*
067d23c9 14192
1f5d53eb
PE
14193# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14194# in glibc 2.1.3, but that breaks too many other things.
14195# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14196if test $ac_cv_sys_largefile_source != unknown; then
14197
14198$as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
067d23c9 14199
067d23c9
KY
14200fi
14201
1f5d53eb
PE
14202
14203{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
14204$as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
a9bec17c 14205if test "${ac_cv_func_getpgrp_void+set}" = set; then :
067d23c9
KY
14206 $as_echo_n "(cached) " >&6
14207else
1f5d53eb 14208 # Use it with a single arg.
067d23c9
KY
14209cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14210/* end confdefs.h. */
1f5d53eb 14211$ac_includes_default
067d23c9
KY
14212int
14213main ()
14214{
1f5d53eb 14215getpgrp (0);
067d23c9
KY
14216 ;
14217 return 0;
14218}
14219_ACEOF
1f5d53eb
PE
14220if ac_fn_c_try_compile "$LINENO"; then :
14221 ac_cv_func_getpgrp_void=no
067d23c9 14222else
1f5d53eb 14223 ac_cv_func_getpgrp_void=yes
067d23c9 14224fi
1f5d53eb
PE
14225rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14226
067d23c9 14227fi
1f5d53eb
PE
14228{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
14229$as_echo "$ac_cv_func_getpgrp_void" >&6; }
14230if test $ac_cv_func_getpgrp_void = yes; then
14231
14232$as_echo "#define GETPGRP_VOID 1" >>confdefs.h
067d23c9
KY
14233
14234fi
14235
1f5d53eb 14236
3e0be4ab
GM
14237# UNIX98 PTYs.
14238for ac_func in grantpt
14239do :
14240 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
a9bec17c 14241if test "x$ac_cv_func_grantpt" = x""yes; then :
3e0be4ab
GM
14242 cat >>confdefs.h <<_ACEOF
14243#define HAVE_GRANTPT 1
14244_ACEOF
1f5d53eb 14245
3e0be4ab
GM
14246fi
14247done
1f5d53eb
PE
14248
14249
3e0be4ab
GM
14250# PTY-related GNU extensions.
14251for ac_func in getpt
14252do :
14253 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
a9bec17c 14254if test "x$ac_cv_func_getpt" = x""yes; then :
3e0be4ab
GM
14255 cat >>confdefs.h <<_ACEOF
14256#define HAVE_GETPT 1
14257_ACEOF
1f5d53eb 14258
3e0be4ab
GM
14259fi
14260done
1f5d53eb 14261
1f5d53eb 14262
3e0be4ab
GM
14263# Check this now, so that we will NOT find the above functions in ncurses.
14264# That is because we have not set up to link ncurses in lib-src.
14265# It's better to believe a function is not available
14266# than to expect to find it in ncurses.
14267# Also we need tputs and friends to be able to build at all.
14268have_tputs_et_al=true
3e72c16e
GM
14269# Maybe curses should be tried earlier?
14270# See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
3e0be4ab
GM
14271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
14272$as_echo_n "checking for library containing tputs... " >&6; }
a9bec17c 14273if test "${ac_cv_search_tputs+set}" = set; then :
4fc2b746
GM
14274 $as_echo_n "(cached) " >&6
14275else
3e0be4ab
GM
14276 ac_func_search_save_LIBS=$LIBS
14277cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4fc2b746 14278/* end confdefs.h. */
3e0be4ab
GM
14279
14280/* Override any GCC internal prototype to avoid an error.
14281 Use char because int might match the return type of a GCC
14282 builtin and then its argument prototype would still apply. */
14283#ifdef __cplusplus
14284extern "C"
14285#endif
14286char tputs ();
14287int
14288main ()
14289{
14290return tputs ();
4fc2b746
GM
14291 ;
14292 return 0;
14293}
14294_ACEOF
3e72c16e 14295for ac_lib in '' ncurses terminfo termcap curses; do
3e0be4ab
GM
14296 if test -z "$ac_lib"; then
14297 ac_res="none required"
14298 else
14299 ac_res=-l$ac_lib
14300 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
14301 fi
14302 if ac_fn_c_try_link "$LINENO"; then :
14303 ac_cv_search_tputs=$ac_res
4fc2b746
GM
14304fi
14305rm -f core conftest.err conftest.$ac_objext \
3e0be4ab 14306 conftest$ac_exeext
a9bec17c 14307 if test "${ac_cv_search_tputs+set}" = set; then :
3e0be4ab 14308 break
4fc2b746 14309fi
3e0be4ab 14310done
a9bec17c 14311if test "${ac_cv_search_tputs+set}" = set; then :
4fc2b746 14312
3e0be4ab
GM
14313else
14314 ac_cv_search_tputs=no
14315fi
14316rm conftest.$ac_ext
14317LIBS=$ac_func_search_save_LIBS
14318fi
14319{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5
14320$as_echo "$ac_cv_search_tputs" >&6; }
14321ac_res=$ac_cv_search_tputs
14322if test "$ac_res" != no; then :
14323 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14324
14325else
14326 have_tputs_et_al=false
14327fi
4fc2b746 14328
3e0be4ab 14329if test "$have_tputs_et_al" != true; then
3e72c16e
GM
14330 as_fn_error "The required function \`tputs' was not found in any library.
14331These libraries were tried: libncurses, libterminfo, libtermcap, libcurses.
14332Please try installing whichever of these libraries is most appropriate
14333for your system, together with its header files.
14334For example, a libncurses-dev(el) or similar package." "$LINENO" 5
4fc2b746 14335fi
3e0be4ab 14336# Must define this when any termcap library is found.
4fc2b746 14337
3e0be4ab
GM
14338$as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
14339
14340## FIXME This was the cpp logic, but I am not sure it is right.
14341## The above test has not necessarily found libncurses.
14342HAVE_LIBNCURSES=yes
14343
14344## Use terminfo instead of termcap?
14345## Note only system files NOT using terminfo are:
14346## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
14347## darwin|gnu without ncurses.
14348TERMINFO=no
14349LIBS_TERMCAP=
14350case "$opsys" in
14351 ## cygwin: Fewer environment variables to go wrong, more terminal types.
14352 ## hpux10-20: Use the system provided termcap(3) library.
14353 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
14354 ## is necessary. Otherwise Emacs dumps core when run -nw.
14355 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
14356
14357 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
14358 ## The ncurses library has been moved out of the System framework in
14359 ## Mac OS X 10.2. So if configure detects it, set the command-line
14360 ## option to use it.
14361 darwin|gnu*)
14362 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
14363 if test "x$HAVE_LIBNCURSES" = "xyes"; then
14364 TERMINFO=yes
14365 LIBS_TERMCAP="-lncurses"
14366 fi
14367 ;;
14368
14369 freebsd)
14370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
14371$as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
a9bec17c 14372 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
4fc2b746
GM
14373 $as_echo_n "(cached) " >&6
14374else
14375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14376/* end confdefs.h. */
3e0be4ab 14377#include <osreldate.h>
4fc2b746
GM
14378int
14379main ()
14380{
3e0be4ab
GM
14381#if __FreeBSD_version < 400000
14382fail;
14383#endif
14384
4fc2b746
GM
14385 ;
14386 return 0;
14387}
14388_ACEOF
14389if ac_fn_c_try_link "$LINENO"; then :
3e0be4ab 14390 emacs_cv_freebsd_terminfo=yes
4fc2b746 14391else
3e0be4ab 14392 emacs_cv_freebsd_terminfo=no
4fc2b746
GM
14393fi
14394rm -f core conftest.err conftest.$ac_objext \
14395 conftest$ac_exeext conftest.$ac_ext
14396fi
4fc2b746 14397
4fc2b746 14398
3e0be4ab
GM
14399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
14400$as_echo "$emacs_cv_freebsd_terminfo" >&6; }
4fc2b746 14401
3e0be4ab
GM
14402 if test $emacs_cv_freebsd_terminfo = yes; then
14403 TERMINFO=yes
14404 LIBS_TERMCAP="-lncurses"
14405 else
14406 LIBS_TERMCAP="-ltermcap"
14407 fi
14408 ;;
4fc2b746 14409
3e0be4ab
GM
14410 netbsd)
14411 if test $ac_cv_search_tputs = -lterminfo; then
14412 TERMINFO=yes
14413 LIBS_TERMCAP="-lterminfo"
14414 else
14415 LIBS_TERMCAP="-ltermcap"
14416 fi
14417 ;;
4fc2b746 14418
3e0be4ab 14419esac
4fc2b746 14420
3e0be4ab
GM
14421case "$opsys" in
14422 ## hpux: Make sure we get select from libc rather than from libcurses
14423 ## because libcurses on HPUX 10.10 has a broken version of select.
14424 ## We used to use -lc -lcurses, but this may be cleaner.
14425 hpux*) LIBS_TERMCAP="-ltermcap" ;;
4fc2b746 14426
3e0be4ab 14427 openbsd) LIBS_TERMCAP="-lncurses" ;;
4fc2b746 14428
3e0be4ab
GM
14429 ## Must use system termcap, if we use any termcap. It does special things.
14430 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
14431esac
4fc2b746 14432
3e0be4ab
GM
14433TERMCAP_OBJ=tparam.o
14434if test $TERMINFO = yes; then
4fc2b746 14435
3e0be4ab 14436$as_echo "#define TERMINFO 1" >>confdefs.h
4fc2b746 14437
4fc2b746 14438
3e0be4ab
GM
14439 ## Default used to be -ltermcap. Add a case above if need something else.
14440 test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
4fc2b746 14441
3e0be4ab 14442 TERMCAP_OBJ=terminfo.o
4fc2b746 14443fi
4fc2b746 14444
4fc2b746 14445
4fc2b746 14446
4fc2b746 14447
3e0be4ab
GM
14448# Do we have res_init, for detecting changes in /etc/resolv.conf?
14449resolv=no
14450cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4fc2b746 14451/* end confdefs.h. */
3e0be4ab
GM
14452#include <netinet/in.h>
14453#include <arpa/nameser.h>
14454#include <resolv.h>
4fc2b746 14455int
3e0be4ab 14456main ()
4fc2b746 14457{
3e0be4ab
GM
14458return res_init();
14459 ;
14460 return 0;
4fc2b746
GM
14461}
14462_ACEOF
3e0be4ab
GM
14463if ac_fn_c_try_link "$LINENO"; then :
14464 have_res_init=yes
4fc2b746 14465else
3e0be4ab 14466 have_res_init=no
4fc2b746 14467fi
3e0be4ab
GM
14468rm -f core conftest.err conftest.$ac_objext \
14469 conftest$ac_exeext conftest.$ac_ext
14470if test "$have_res_init" = no; then
14471 OLIBS="$LIBS"
14472 LIBS="$LIBS -lresolv"
14473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
14474$as_echo_n "checking for res_init with -lresolv... " >&6; }
14475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14476/* end confdefs.h. */
14477#include <netinet/in.h>
14478#include <arpa/nameser.h>
14479#include <resolv.h>
14480int
14481main ()
14482{
14483return res_init();
14484 ;
14485 return 0;
14486}
14487_ACEOF
14488if ac_fn_c_try_link "$LINENO"; then :
14489 have_res_init=yes
14490else
14491 have_res_init=no
14492fi
14493rm -f core conftest.err conftest.$ac_objext \
14494 conftest$ac_exeext conftest.$ac_ext
14495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
14496$as_echo "$have_res_init" >&6; }
14497 if test "$have_res_init" = yes ; then
14498 resolv=yes
14499 fi
14500 LIBS="$OLIBS"
4fc2b746
GM
14501fi
14502
3e0be4ab 14503if test "$have_res_init" = yes; then
1f5d53eb 14504
3e0be4ab 14505$as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
6c051bab
GM
14506
14507fi
6c051bab 14508
3e0be4ab
GM
14509# Do we need the Hesiod library to provide the support routines?
14510LIBHESIOD=
14511if test "$with_hesiod" != no ; then
14512 # Don't set $LIBS here -- see comments above. FIXME which comments?
14513 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
a9bec17c 14514if test "x$ac_cv_func_res_send" = x""yes; then :
6c051bab 14515
3e0be4ab
GM
14516else
14517 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
a9bec17c 14518if test "x$ac_cv_func___res_send" = x""yes; then :
6c051bab 14519
3e0be4ab
GM
14520else
14521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
14522$as_echo_n "checking for res_send in -lresolv... " >&6; }
a9bec17c 14523if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
942f733f
PE
14524 $as_echo_n "(cached) " >&6
14525else
3e0be4ab
GM
14526 ac_check_lib_save_LIBS=$LIBS
14527LIBS="-lresolv $LIBS"
14528cat confdefs.h - <<_ACEOF >conftest.$ac_ext
942f733f 14529/* end confdefs.h. */
942f733f 14530
3e0be4ab
GM
14531/* Override any GCC internal prototype to avoid an error.
14532 Use char because int might match the return type of a GCC
14533 builtin and then its argument prototype would still apply. */
14534#ifdef __cplusplus
14535extern "C"
14536#endif
14537char res_send ();
942f733f
PE
14538int
14539main ()
14540{
3e0be4ab 14541return res_send ();
942f733f
PE
14542 ;
14543 return 0;
14544}
14545_ACEOF
3e0be4ab
GM
14546if ac_fn_c_try_link "$LINENO"; then :
14547 ac_cv_lib_resolv_res_send=yes
14548else
14549 ac_cv_lib_resolv_res_send=no
14550fi
14551rm -f core conftest.err conftest.$ac_objext \
14552 conftest$ac_exeext conftest.$ac_ext
14553LIBS=$ac_check_lib_save_LIBS
14554fi
14555{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
14556$as_echo "$ac_cv_lib_resolv_res_send" >&6; }
a9bec17c 14557if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
3e0be4ab
GM
14558 resolv=yes
14559else
14560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
14561$as_echo_n "checking for __res_send in -lresolv... " >&6; }
a9bec17c 14562if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
3e0be4ab
GM
14563 $as_echo_n "(cached) " >&6
14564else
14565 ac_check_lib_save_LIBS=$LIBS
14566LIBS="-lresolv $LIBS"
14567cat confdefs.h - <<_ACEOF >conftest.$ac_ext
942f733f 14568/* end confdefs.h. */
942f733f 14569
3e0be4ab
GM
14570/* Override any GCC internal prototype to avoid an error.
14571 Use char because int might match the return type of a GCC
14572 builtin and then its argument prototype would still apply. */
14573#ifdef __cplusplus
14574extern "C"
14575#endif
14576char __res_send ();
942f733f
PE
14577int
14578main ()
14579{
3e0be4ab 14580return __res_send ();
942f733f
PE
14581 ;
14582 return 0;
14583}
14584_ACEOF
3e0be4ab
GM
14585if ac_fn_c_try_link "$LINENO"; then :
14586 ac_cv_lib_resolv___res_send=yes
942f733f 14587else
3e0be4ab 14588 ac_cv_lib_resolv___res_send=no
942f733f 14589fi
3e0be4ab
GM
14590rm -f core conftest.err conftest.$ac_objext \
14591 conftest$ac_exeext conftest.$ac_ext
14592LIBS=$ac_check_lib_save_LIBS
14593fi
14594{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
14595$as_echo "$ac_cv_lib_resolv___res_send" >&6; }
a9bec17c 14596if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
3e0be4ab 14597 resolv=yes
942f733f 14598fi
942f733f 14599
3e0be4ab 14600fi
942f733f 14601
3e0be4ab
GM
14602fi
14603
14604fi
14605
14606 if test "$resolv" = yes ; then
14607 RESOLVLIB=-lresolv
14608 else
14609 RESOLVLIB=
14610 fi
14611 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
a9bec17c 14612if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
3e0be4ab
GM
14613
14614else
14615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
14616$as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
a9bec17c 14617if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
3e0be4ab
GM
14618 $as_echo_n "(cached) " >&6
14619else
14620 ac_check_lib_save_LIBS=$LIBS
14621LIBS="-lhesiod $RESOLVLIB $LIBS"
14622cat confdefs.h - <<_ACEOF >conftest.$ac_ext
942f733f 14623/* end confdefs.h. */
942f733f 14624
3e0be4ab
GM
14625/* Override any GCC internal prototype to avoid an error.
14626 Use char because int might match the return type of a GCC
14627 builtin and then its argument prototype would still apply. */
14628#ifdef __cplusplus
14629extern "C"
14630#endif
14631char hes_getmailhost ();
942f733f
PE
14632int
14633main ()
14634{
3e0be4ab 14635return hes_getmailhost ();
942f733f
PE
14636 ;
14637 return 0;
14638}
14639_ACEOF
3e0be4ab
GM
14640if ac_fn_c_try_link "$LINENO"; then :
14641 ac_cv_lib_hesiod_hes_getmailhost=yes
942f733f 14642else
3e0be4ab 14643 ac_cv_lib_hesiod_hes_getmailhost=no
942f733f 14644fi
3e0be4ab
GM
14645rm -f core conftest.err conftest.$ac_objext \
14646 conftest$ac_exeext conftest.$ac_ext
14647LIBS=$ac_check_lib_save_LIBS
14648fi
14649{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
14650$as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
a9bec17c 14651if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
3e0be4ab
GM
14652 hesiod=yes
14653else
14654 :
942f733f 14655fi
942f733f 14656
942f733f 14657fi
3e0be4ab
GM
14658
14659
14660 if test x"$hesiod" = xyes; then
14661
14662$as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14663
14664 LIBHESIOD=-lhesiod
14665 fi
14666fi
14667
14668
14669# Do we need libresolv (due to res_init or Hesiod)?
14670if test "$resolv" = yes ; then
14671
14672$as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14673
14674 LIBRESOLV=-lresolv
942f733f 14675else
3e0be4ab
GM
14676 LIBRESOLV=
14677fi
14678
14679
14680# These tell us which Kerberos-related libraries to use.
14681COM_ERRLIB=
14682CRYPTOLIB=
14683KRB5LIB=
14684DESLIB=
14685KRB4LIB=
14686
14687if test "${with_kerberos}" != no; then
14688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14689$as_echo_n "checking for com_err in -lcom_err... " >&6; }
a9bec17c 14690if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
3e0be4ab
GM
14691 $as_echo_n "(cached) " >&6
14692else
14693 ac_check_lib_save_LIBS=$LIBS
14694LIBS="-lcom_err $LIBS"
14695cat confdefs.h - <<_ACEOF >conftest.$ac_ext
942f733f 14696/* end confdefs.h. */
3e0be4ab
GM
14697
14698/* Override any GCC internal prototype to avoid an error.
14699 Use char because int might match the return type of a GCC
14700 builtin and then its argument prototype would still apply. */
14701#ifdef __cplusplus
14702extern "C"
14703#endif
14704char com_err ();
942f733f
PE
14705int
14706main ()
14707{
3e0be4ab 14708return com_err ();
942f733f
PE
14709 ;
14710 return 0;
14711}
14712_ACEOF
3e0be4ab
GM
14713if ac_fn_c_try_link "$LINENO"; then :
14714 ac_cv_lib_com_err_com_err=yes
942f733f 14715else
3e0be4ab 14716 ac_cv_lib_com_err_com_err=no
942f733f 14717fi
3e0be4ab
GM
14718rm -f core conftest.err conftest.$ac_objext \
14719 conftest$ac_exeext conftest.$ac_ext
14720LIBS=$ac_check_lib_save_LIBS
942f733f 14721fi
3e0be4ab
GM
14722{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14723$as_echo "$ac_cv_lib_com_err_com_err" >&6; }
a9bec17c 14724if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
3e0be4ab
GM
14725 have_com_err=yes
14726else
14727 have_com_err=no
942f733f 14728fi
942f733f 14729
3e0be4ab
GM
14730 if test $have_com_err = yes; then
14731 COM_ERRLIB=-lcom_err
14732 LIBS="$COM_ERRLIB $LIBS"
942f733f 14733
3e0be4ab 14734$as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
942f733f 14735
3e0be4ab
GM
14736 fi
14737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14738$as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
a9bec17c 14739if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
942f733f
PE
14740 $as_echo_n "(cached) " >&6
14741else
3e0be4ab
GM
14742 ac_check_lib_save_LIBS=$LIBS
14743LIBS="-lcrypto $LIBS"
14744cat confdefs.h - <<_ACEOF >conftest.$ac_ext
942f733f 14745/* end confdefs.h. */
942f733f 14746
3e0be4ab
GM
14747/* Override any GCC internal prototype to avoid an error.
14748 Use char because int might match the return type of a GCC
14749 builtin and then its argument prototype would still apply. */
14750#ifdef __cplusplus
14751extern "C"
14752#endif
14753char mit_des_cbc_encrypt ();
14754int
14755main ()
14756{
14757return mit_des_cbc_encrypt ();
14758 ;
14759 return 0;
14760}
942f733f 14761_ACEOF
3e0be4ab
GM
14762if ac_fn_c_try_link "$LINENO"; then :
14763 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14764else
14765 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
942f733f 14766fi
3e0be4ab
GM
14767rm -f core conftest.err conftest.$ac_objext \
14768 conftest$ac_exeext conftest.$ac_ext
14769LIBS=$ac_check_lib_save_LIBS
14770fi
14771{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14772$as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
a9bec17c 14773if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
3e0be4ab
GM
14774 have_crypto=yes
14775else
14776 have_crypto=no
942f733f 14777fi
942f733f 14778
3e0be4ab
GM
14779 if test $have_crypto = yes; then
14780 CRYPTOLIB=-lcrypto
14781 LIBS="$CRYPTOLIB $LIBS"
942f733f 14782
3e0be4ab 14783$as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
942f733f 14784
3e0be4ab
GM
14785 fi
14786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14787$as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
a9bec17c 14788if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
067d23c9
KY
14789 $as_echo_n "(cached) " >&6
14790else
3e0be4ab
GM
14791 ac_check_lib_save_LIBS=$LIBS
14792LIBS="-lk5crypto $LIBS"
14793cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 14794/* end confdefs.h. */
3e0be4ab
GM
14795
14796/* Override any GCC internal prototype to avoid an error.
14797 Use char because int might match the return type of a GCC
14798 builtin and then its argument prototype would still apply. */
14799#ifdef __cplusplus
14800extern "C"
14801#endif
14802char mit_des_cbc_encrypt ();
067d23c9
KY
14803int
14804main ()
14805{
3e0be4ab 14806return mit_des_cbc_encrypt ();
067d23c9
KY
14807 ;
14808 return 0;
14809}
14810_ACEOF
14811if ac_fn_c_try_link "$LINENO"; then :
3e0be4ab 14812 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
067d23c9 14813else
3e0be4ab 14814 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
067d23c9
KY
14815fi
14816rm -f core conftest.err conftest.$ac_objext \
14817 conftest$ac_exeext conftest.$ac_ext
3e0be4ab
GM
14818LIBS=$ac_check_lib_save_LIBS
14819fi
14820{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14821$as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
a9bec17c 14822if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
3e0be4ab
GM
14823 have_k5crypto=yes
14824else
14825 have_k5crypto=no
067d23c9
KY
14826fi
14827
3e0be4ab
GM
14828 if test $have_k5crypto = yes; then
14829 CRYPTOLIB=-lk5crypto
14830 LIBS="$CRYPTOLIB $LIBS"
067d23c9 14831
3e0be4ab 14832$as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
067d23c9 14833
3e0be4ab
GM
14834 fi
14835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14836$as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
a9bec17c 14837if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
3e0be4ab
GM
14838 $as_echo_n "(cached) " >&6
14839else
14840 ac_check_lib_save_LIBS=$LIBS
14841LIBS="-lkrb5 $LIBS"
14842cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14843/* end confdefs.h. */
067d23c9 14844
3e0be4ab
GM
14845/* Override any GCC internal prototype to avoid an error.
14846 Use char because int might match the return type of a GCC
14847 builtin and then its argument prototype would still apply. */
14848#ifdef __cplusplus
14849extern "C"
14850#endif
14851char krb5_init_context ();
14852int
14853main ()
14854{
14855return krb5_init_context ();
14856 ;
14857 return 0;
14858}
14859_ACEOF
14860if ac_fn_c_try_link "$LINENO"; then :
14861 ac_cv_lib_krb5_krb5_init_context=yes
14862else
14863 ac_cv_lib_krb5_krb5_init_context=no
14864fi
14865rm -f core conftest.err conftest.$ac_objext \
14866 conftest$ac_exeext conftest.$ac_ext
14867LIBS=$ac_check_lib_save_LIBS
14868fi
14869{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14870$as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
a9bec17c 14871if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
3e0be4ab
GM
14872 have_krb5=yes
14873else
14874 have_krb5=no
14875fi
067d23c9 14876
3e0be4ab
GM
14877 if test $have_krb5=yes; then
14878 KRB5LIB=-lkrb5
14879 LIBS="$KRB5LIB $LIBS"
1f5d53eb 14880
3e0be4ab 14881$as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
1f5d53eb 14882
3e0be4ab
GM
14883 fi
14884 if test "${with_kerberos5}" = no; then
14885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14886$as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
a9bec17c 14887if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
7d2a1c5e
GM
14888 $as_echo_n "(cached) " >&6
14889else
3e0be4ab
GM
14890 ac_check_lib_save_LIBS=$LIBS
14891LIBS="-ldes425 $LIBS"
14892cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7d2a1c5e
GM
14893/* end confdefs.h. */
14894
3e0be4ab
GM
14895/* Override any GCC internal prototype to avoid an error.
14896 Use char because int might match the return type of a GCC
14897 builtin and then its argument prototype would still apply. */
14898#ifdef __cplusplus
14899extern "C"
14900#endif
14901char des_cbc_encrypt ();
7d2a1c5e
GM
14902int
14903main ()
14904{
3e0be4ab 14905return des_cbc_encrypt ();
7d2a1c5e
GM
14906 ;
14907 return 0;
14908}
14909_ACEOF
3e0be4ab
GM
14910if ac_fn_c_try_link "$LINENO"; then :
14911 ac_cv_lib_des425_des_cbc_encrypt=yes
7d2a1c5e 14912else
3e0be4ab 14913 ac_cv_lib_des425_des_cbc_encrypt=no
7d2a1c5e 14914fi
3e0be4ab
GM
14915rm -f core conftest.err conftest.$ac_objext \
14916 conftest$ac_exeext conftest.$ac_ext
14917LIBS=$ac_check_lib_save_LIBS
14918fi
14919{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14920$as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
a9bec17c 14921if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
3e0be4ab
GM
14922 have_des425=yes
14923else
14924 have_des425=no
7d2a1c5e 14925fi
7d2a1c5e 14926
3e0be4ab
GM
14927 if test $have_des425 = yes; then
14928 DESLIB=-ldes425
14929 LIBS="$DESLIB $LIBS"
7d2a1c5e 14930
3e0be4ab 14931$as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
7d2a1c5e 14932
3e0be4ab
GM
14933 else
14934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14935$as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
a9bec17c 14936if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
3e0be4ab 14937 $as_echo_n "(cached) " >&6
7d2a1c5e 14938else
3e0be4ab
GM
14939 ac_check_lib_save_LIBS=$LIBS
14940LIBS="-ldes $LIBS"
14941cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14942/* end confdefs.h. */
7d2a1c5e 14943
3e0be4ab
GM
14944/* Override any GCC internal prototype to avoid an error.
14945 Use char because int might match the return type of a GCC
14946 builtin and then its argument prototype would still apply. */
14947#ifdef __cplusplus
14948extern "C"
14949#endif
14950char des_cbc_encrypt ();
14951int
14952main ()
14953{
14954return des_cbc_encrypt ();
14955 ;
14956 return 0;
14957}
7d2a1c5e 14958_ACEOF
3e0be4ab
GM
14959if ac_fn_c_try_link "$LINENO"; then :
14960 ac_cv_lib_des_des_cbc_encrypt=yes
14961else
14962 ac_cv_lib_des_des_cbc_encrypt=no
14963fi
14964rm -f core conftest.err conftest.$ac_objext \
14965 conftest$ac_exeext conftest.$ac_ext
14966LIBS=$ac_check_lib_save_LIBS
14967fi
14968{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14969$as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
a9bec17c 14970if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
3e0be4ab
GM
14971 have_des=yes
14972else
14973 have_des=no
14974fi
7d2a1c5e 14975
3e0be4ab
GM
14976 if test $have_des = yes; then
14977 DESLIB=-ldes
14978 LIBS="$DESLIB $LIBS"
7d2a1c5e 14979
3e0be4ab 14980$as_echo "#define HAVE_LIBDES 1" >>confdefs.h
7d2a1c5e 14981
3e0be4ab
GM
14982 fi
14983 fi
14984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14985$as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
a9bec17c 14986if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
067d23c9
KY
14987 $as_echo_n "(cached) " >&6
14988else
3e0be4ab
GM
14989 ac_check_lib_save_LIBS=$LIBS
14990LIBS="-lkrb4 $LIBS"
14991cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1f5d53eb 14992/* end confdefs.h. */
3e0be4ab
GM
14993
14994/* Override any GCC internal prototype to avoid an error.
14995 Use char because int might match the return type of a GCC
14996 builtin and then its argument prototype would still apply. */
14997#ifdef __cplusplus
14998extern "C"
14999#endif
15000char krb_get_cred ();
15001int
15002main ()
15003{
15004return krb_get_cred ();
15005 ;
15006 return 0;
15007}
067d23c9 15008_ACEOF
3e0be4ab
GM
15009if ac_fn_c_try_link "$LINENO"; then :
15010 ac_cv_lib_krb4_krb_get_cred=yes
1f5d53eb 15011else
3e0be4ab 15012 ac_cv_lib_krb4_krb_get_cred=no
067d23c9 15013fi
3e0be4ab
GM
15014rm -f core conftest.err conftest.$ac_objext \
15015 conftest$ac_exeext conftest.$ac_ext
15016LIBS=$ac_check_lib_save_LIBS
067d23c9 15017fi
3e0be4ab
GM
15018{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
15019$as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
a9bec17c 15020if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
3e0be4ab
GM
15021 have_krb4=yes
15022else
15023 have_krb4=no
1f5d53eb 15024fi
067d23c9 15025
3e0be4ab
GM
15026 if test $have_krb4 = yes; then
15027 KRB4LIB=-lkrb4
15028 LIBS="$KRB4LIB $LIBS"
067d23c9 15029
3e0be4ab 15030$as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
067d23c9 15031
3e0be4ab
GM
15032 else
15033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
15034$as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
a9bec17c 15035if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
1f5d53eb
PE
15036 $as_echo_n "(cached) " >&6
15037else
3e0be4ab
GM
15038 ac_check_lib_save_LIBS=$LIBS
15039LIBS="-lkrb $LIBS"
15040cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1f5d53eb 15041/* end confdefs.h. */
067d23c9 15042
3e0be4ab
GM
15043/* Override any GCC internal prototype to avoid an error.
15044 Use char because int might match the return type of a GCC
15045 builtin and then its argument prototype would still apply. */
15046#ifdef __cplusplus
15047extern "C"
1f5d53eb 15048#endif
3e0be4ab
GM
15049char krb_get_cred ();
15050int
15051main ()
15052{
15053return krb_get_cred ();
15054 ;
15055 return 0;
15056}
067d23c9 15057_ACEOF
3e0be4ab
GM
15058if ac_fn_c_try_link "$LINENO"; then :
15059 ac_cv_lib_krb_krb_get_cred=yes
1f5d53eb 15060else
3e0be4ab 15061 ac_cv_lib_krb_krb_get_cred=no
067d23c9 15062fi
3e0be4ab
GM
15063rm -f core conftest.err conftest.$ac_objext \
15064 conftest$ac_exeext conftest.$ac_ext
15065LIBS=$ac_check_lib_save_LIBS
15066fi
15067{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
15068$as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
a9bec17c 15069if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
3e0be4ab
GM
15070 have_krb=yes
15071else
15072 have_krb=no
067d23c9 15073fi
067d23c9 15074
3e0be4ab
GM
15075 if test $have_krb = yes; then
15076 KRB4LIB=-lkrb
15077 LIBS="$KRB4LIB $LIBS"
067d23c9 15078
3e0be4ab 15079$as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
067d23c9 15080
3e0be4ab
GM
15081 fi
15082 fi
15083 fi
067d23c9 15084
3e0be4ab
GM
15085 if test "${with_kerberos5}" != no; then
15086 for ac_header in krb5.h
15087do :
15088 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
a9bec17c 15089if test "x$ac_cv_header_krb5_h" = x""yes; then :
3e0be4ab
GM
15090 cat >>confdefs.h <<_ACEOF
15091#define HAVE_KRB5_H 1
15092_ACEOF
15093 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
15094"
a9bec17c 15095if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
067d23c9 15096
3e0be4ab
GM
15097cat >>confdefs.h <<_ACEOF
15098#define HAVE_KRB5_ERROR_TEXT 1
15099_ACEOF
067d23c9 15100
067d23c9 15101
3e0be4ab
GM
15102fi
15103ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
15104"
a9bec17c 15105if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
067d23c9 15106
3e0be4ab
GM
15107cat >>confdefs.h <<_ACEOF
15108#define HAVE_KRB5_ERROR_E_TEXT 1
15109_ACEOF
067d23c9 15110
067d23c9 15111
3e0be4ab 15112fi
067d23c9 15113
3e0be4ab 15114fi
067d23c9 15115
3e0be4ab 15116done
067d23c9 15117
3e0be4ab
GM
15118 else
15119 for ac_header in des.h
15120do :
15121 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
a9bec17c 15122if test "x$ac_cv_header_des_h" = x""yes; then :
3e0be4ab
GM
15123 cat >>confdefs.h <<_ACEOF
15124#define HAVE_DES_H 1
15125_ACEOF
067d23c9 15126
1f5d53eb 15127else
3e0be4ab
GM
15128 for ac_header in kerberosIV/des.h
15129do :
15130 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
a9bec17c 15131if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
3e0be4ab
GM
15132 cat >>confdefs.h <<_ACEOF
15133#define HAVE_KERBEROSIV_DES_H 1
1f5d53eb 15134_ACEOF
067d23c9 15135
3e0be4ab
GM
15136else
15137 for ac_header in kerberos/des.h
15138do :
15139 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
a9bec17c 15140if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
3e0be4ab
GM
15141 cat >>confdefs.h <<_ACEOF
15142#define HAVE_KERBEROS_DES_H 1
15143_ACEOF
067d23c9
KY
15144
15145fi
067d23c9 15146
3e0be4ab 15147done
067d23c9 15148
3e0be4ab 15149fi
067d23c9 15150
3e0be4ab 15151done
067d23c9 15152
3e0be4ab 15153fi
067d23c9 15154
3e0be4ab 15155done
1f5d53eb 15156
3e0be4ab
GM
15157 for ac_header in krb.h
15158do :
15159 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
a9bec17c 15160if test "x$ac_cv_header_krb_h" = x""yes; then :
3e0be4ab
GM
15161 cat >>confdefs.h <<_ACEOF
15162#define HAVE_KRB_H 1
15163_ACEOF
1f5d53eb 15164
3e0be4ab
GM
15165else
15166 for ac_header in kerberosIV/krb.h
1f5d53eb 15167do :
3e0be4ab 15168 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
a9bec17c 15169if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
1f5d53eb 15170 cat >>confdefs.h <<_ACEOF
3e0be4ab 15171#define HAVE_KERBEROSIV_KRB_H 1
1f5d53eb 15172_ACEOF
067d23c9
KY
15173
15174else
3e0be4ab
GM
15175 for ac_header in kerberos/krb.h
15176do :
15177 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
a9bec17c 15178if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
3e0be4ab
GM
15179 cat >>confdefs.h <<_ACEOF
15180#define HAVE_KERBEROS_KRB_H 1
15181_ACEOF
15182
067d23c9
KY
15183fi
15184
1f5d53eb
PE
15185done
15186
3e0be4ab 15187fi
1f5d53eb 15188
3e0be4ab
GM
15189done
15190
15191fi
15192
15193done
15194
15195 fi
15196 for ac_header in com_err.h
1f5d53eb 15197do :
3e0be4ab 15198 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
a9bec17c 15199if test "x$ac_cv_header_com_err_h" = x""yes; then :
1f5d53eb 15200 cat >>confdefs.h <<_ACEOF
3e0be4ab 15201#define HAVE_COM_ERR_H 1
1f5d53eb 15202_ACEOF
067d23c9 15203
067d23c9 15204fi
3e0be4ab 15205
1f5d53eb 15206done
067d23c9 15207
3e0be4ab 15208fi
067d23c9 15209
3e0be4ab
GM
15210
15211
15212
15213
15214
15215
3e0be4ab
GM
15216{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
15217$as_echo_n "checking whether localtime caches TZ... " >&6; }
a9bec17c 15218if test "${emacs_cv_localtime_cache+set}" = set; then :
3e0be4ab
GM
15219 $as_echo_n "(cached) " >&6
15220else
15221 if test x$ac_cv_func_tzset = xyes; then
15222if test "$cross_compiling" = yes; then :
15223 # If we have tzset, assume the worst when cross-compiling.
15224emacs_cv_localtime_cache=yes
1fd182f0 15225else
1f5d53eb 15226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15227/* end confdefs.h. */
3e0be4ab
GM
15228#include <time.h>
15229char TZ_GMT0[] = "TZ=GMT0";
15230char TZ_PST8[] = "TZ=PST8";
15231main()
1fd182f0 15232{
3e0be4ab
GM
15233 time_t now = time ((time_t *) 0);
15234 int hour_GMT0, hour_unset;
15235 if (putenv (TZ_GMT0) != 0)
15236 exit (1);
15237 hour_GMT0 = localtime (&now)->tm_hour;
15238 unsetenv("TZ");
15239 hour_unset = localtime (&now)->tm_hour;
15240 if (putenv (TZ_PST8) != 0)
15241 exit (1);
15242 if (localtime (&now)->tm_hour == hour_GMT0)
15243 exit (1);
15244 unsetenv("TZ");
15245 if (localtime (&now)->tm_hour != hour_unset)
15246 exit (1);
15247 exit (0);
1fd182f0
PE
15248}
15249_ACEOF
3e0be4ab
GM
15250if ac_fn_c_try_run "$LINENO"; then :
15251 emacs_cv_localtime_cache=no
1fd182f0 15252else
3e0be4ab 15253 emacs_cv_localtime_cache=yes
1fd182f0 15254fi
3e0be4ab
GM
15255rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15256 conftest.$ac_objext conftest.beam conftest.$ac_ext
1fd182f0 15257fi
1fd182f0 15258
1f5d53eb 15259else
3e0be4ab
GM
15260 # If we lack tzset, report that localtime does not cache TZ,
15261 # since we can't invalidate the cache if we don't have tzset.
15262 emacs_cv_localtime_cache=no
15263fi
15264fi
15265{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
15266$as_echo "$emacs_cv_localtime_cache" >&6; }
15267if test $emacs_cv_localtime_cache = yes; then
1fd182f0 15268
3e0be4ab 15269$as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
1fd182f0 15270
1f5d53eb 15271fi
d6974efa 15272
3e0be4ab
GM
15273if test "x$HAVE_TIMEVAL" = xyes; then
15274 for ac_func in gettimeofday
15275do :
15276 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
a9bec17c 15277if test "x$ac_cv_func_gettimeofday" = x""yes; then :
3e0be4ab
GM
15278 cat >>confdefs.h <<_ACEOF
15279#define HAVE_GETTIMEOFDAY 1
15280_ACEOF
1fd182f0 15281
1f5d53eb 15282fi
3e0be4ab 15283done
1fd182f0 15284
3e0be4ab
GM
15285 if test $ac_cv_func_gettimeofday = yes; then
15286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
15287$as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
a9bec17c 15288if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then :
1fd182f0
PE
15289 $as_echo_n "(cached) " >&6
15290else
15291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15292/* end confdefs.h. */
1f5d53eb 15293
3e0be4ab
GM
15294#ifdef TIME_WITH_SYS_TIME
15295#include <sys/time.h>
15296#include <time.h>
15297#else
15298#ifdef HAVE_SYS_TIME_H
15299#include <sys/time.h>
15300#else
15301#include <time.h>
15302#endif
15303#endif
1fd182f0
PE
15304int
15305main ()
15306{
3e0be4ab
GM
15307struct timeval time;
15308 gettimeofday (&time, 0);
1fd182f0
PE
15309 ;
15310 return 0;
15311}
15312_ACEOF
3e0be4ab
GM
15313if ac_fn_c_try_compile "$LINENO"; then :
15314 emacs_cv_gettimeofday_two_arguments=yes
1fd182f0 15315else
3e0be4ab 15316 emacs_cv_gettimeofday_two_arguments=no
1fd182f0 15317fi
3e0be4ab 15318rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1fd182f0 15319fi
3e0be4ab
GM
15320{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
15321$as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
15322 if test $emacs_cv_gettimeofday_two_arguments = no; then
1fd182f0 15323
3e0be4ab 15324$as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
1fd182f0 15325
1f5d53eb 15326 fi
1fd182f0 15327 fi
3e0be4ab 15328fi
1fd182f0 15329
3e0be4ab
GM
15330ok_so_far=yes
15331ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
a9bec17c 15332if test "x$ac_cv_func_socket" = x""yes; then :
1fd182f0 15333
3e0be4ab
GM
15334else
15335 ok_so_far=no
15336fi
1fd182f0 15337
3e0be4ab
GM
15338if test $ok_so_far = yes; then
15339 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
a9bec17c 15340if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
1fd182f0 15341
3e0be4ab
GM
15342else
15343 ok_so_far=no
15344fi
1fd182f0 15345
1f5d53eb 15346
52724a05 15347fi
3e0be4ab
GM
15348if test $ok_so_far = yes; then
15349 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
a9bec17c 15350if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
1f5d53eb 15351
3e0be4ab
GM
15352else
15353 ok_so_far=no
15354fi
1f5d53eb 15355
1f5d53eb 15356
3e0be4ab
GM
15357fi
15358if test $ok_so_far = yes; then
1f5d53eb 15359
3e0be4ab 15360$as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
1f5d53eb 15361
3e0be4ab 15362fi
1f5d53eb 15363
3e0be4ab 15364if test -f /usr/lpp/X11/bin/smt.exp; then
1f5d53eb 15365
3e0be4ab 15366$as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
1f5d53eb
PE
15367
15368fi
15369
3e0be4ab
GM
15370{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
15371$as_echo_n "checking whether system supports dynamic ptys... " >&6; }
15372if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
15373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15374$as_echo "yes" >&6; }
1f5d53eb 15375
3e0be4ab 15376$as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
1f5d53eb 15377
ae0d7250 15378else
3e0be4ab
GM
15379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15380$as_echo "no" >&6; }
15381fi
4fda9c95 15382
3e0be4ab 15383ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
a9bec17c 15384if test "x$ac_cv_type_pid_t" = x""yes; then :
3e0be4ab
GM
15385
15386else
4fda9c95 15387
3e0be4ab
GM
15388cat >>confdefs.h <<_ACEOF
15389#define pid_t int
ae0d7250 15390_ACEOF
4fda9c95 15391
4fda9c95 15392fi
4fda9c95 15393
3e0be4ab
GM
15394for ac_header in vfork.h
15395do :
15396 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
a9bec17c 15397if test "x$ac_cv_header_vfork_h" = x""yes; then :
3e0be4ab
GM
15398 cat >>confdefs.h <<_ACEOF
15399#define HAVE_VFORK_H 1
15400_ACEOF
4fda9c95 15401
3e0be4ab
GM
15402fi
15403
15404done
4fda9c95 15405
3e0be4ab
GM
15406for ac_func in fork vfork
15407do :
15408 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15409ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
15410eval as_val=\$$as_ac_var
15411 if test "x$as_val" = x""yes; then :
3e0be4ab
GM
15412 cat >>confdefs.h <<_ACEOF
15413#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15414_ACEOF
4fda9c95 15415
3e0be4ab
GM
15416fi
15417done
4fda9c95 15418
3e0be4ab
GM
15419if test "x$ac_cv_func_fork" = xyes; then
15420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15421$as_echo_n "checking for working fork... " >&6; }
a9bec17c 15422if test "${ac_cv_func_fork_works+set}" = set; then :
4fda9c95
GM
15423 $as_echo_n "(cached) " >&6
15424else
3e0be4ab
GM
15425 if test "$cross_compiling" = yes; then :
15426 ac_cv_func_fork_works=cross
4fda9c95
GM
15427else
15428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15429/* end confdefs.h. */
3e0be4ab 15430$ac_includes_default
4fda9c95
GM
15431int
15432main ()
15433{
3e0be4ab
GM
15434
15435 /* By Ruediger Kuhlmann. */
15436 return fork () < 0;
15437
4fda9c95
GM
15438 ;
15439 return 0;
15440}
15441_ACEOF
15442if ac_fn_c_try_run "$LINENO"; then :
3e0be4ab 15443 ac_cv_func_fork_works=yes
4fda9c95 15444else
3e0be4ab 15445 ac_cv_func_fork_works=no
4fda9c95
GM
15446fi
15447rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15448 conftest.$ac_objext conftest.beam conftest.$ac_ext
15449fi
15450
4fda9c95 15451fi
3e0be4ab
GM
15452{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15453$as_echo "$ac_cv_func_fork_works" >&6; }
4fda9c95 15454
3e0be4ab
GM
15455else
15456 ac_cv_func_fork_works=$ac_cv_func_fork
15457fi
15458if test "x$ac_cv_func_fork_works" = xcross; then
15459 case $host in
15460 *-*-amigaos* | *-*-msdosdjgpp*)
15461 # Override, as these systems have only a dummy fork() stub
15462 ac_cv_func_fork_works=no
15463 ;;
15464 *)
15465 ac_cv_func_fork_works=yes
15466 ;;
15467 esac
15468 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15469$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15470fi
15471ac_cv_func_vfork_works=$ac_cv_func_vfork
15472if test "x$ac_cv_func_vfork" = xyes; then
15473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15474$as_echo_n "checking for working vfork... " >&6; }
a9bec17c 15475if test "${ac_cv_func_vfork_works+set}" = set; then :
3e0be4ab
GM
15476 $as_echo_n "(cached) " >&6
15477else
15478 if test "$cross_compiling" = yes; then :
15479 ac_cv_func_vfork_works=cross
15480else
15481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15482/* end confdefs.h. */
15483/* Thanks to Paul Eggert for this test. */
15484$ac_includes_default
15485#include <sys/wait.h>
15486#ifdef HAVE_VFORK_H
15487# include <vfork.h>
15488#endif
15489/* On some sparc systems, changes by the child to local and incoming
15490 argument registers are propagated back to the parent. The compiler
15491 is told about this with #include <vfork.h>, but some compilers
15492 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15493 static variable whose address is put into a register that is
15494 clobbered by the vfork. */
15495static void
15496#ifdef __cplusplus
15497sparc_address_test (int arg)
15498# else
15499sparc_address_test (arg) int arg;
15500#endif
15501{
15502 static pid_t child;
15503 if (!child) {
15504 child = vfork ();
15505 if (child < 0) {
15506 perror ("vfork");
15507 _exit(2);
15508 }
15509 if (!child) {
15510 arg = getpid();
15511 write(-1, "", 0);
15512 _exit (arg);
15513 }
15514 }
15515}
4fda9c95 15516
3e0be4ab
GM
15517int
15518main ()
15519{
15520 pid_t parent = getpid ();
15521 pid_t child;
4fda9c95 15522
3e0be4ab 15523 sparc_address_test (0);
4fda9c95 15524
3e0be4ab 15525 child = vfork ();
4fda9c95 15526
3e0be4ab
GM
15527 if (child == 0) {
15528 /* Here is another test for sparc vfork register problems. This
15529 test uses lots of local variables, at least as many local
15530 variables as main has allocated so far including compiler
15531 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
15532 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
15533 reuse the register of parent for one of the local variables,
15534 since it will think that parent can't possibly be used any more
15535 in this routine. Assigning to the local variable will thus
15536 munge parent in the parent process. */
15537 pid_t
15538 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15539 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15540 /* Convince the compiler that p..p7 are live; otherwise, it might
15541 use the same hardware register for all 8 local variables. */
15542 if (p != p1 || p != p2 || p != p3 || p != p4
15543 || p != p5 || p != p6 || p != p7)
15544 _exit(1);
4fda9c95 15545
3e0be4ab
GM
15546 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15547 from child file descriptors. If the child closes a descriptor
15548 before it execs or exits, this munges the parent's descriptor
15549 as well. Test for this by closing stdout in the child. */
15550 _exit(close(fileno(stdout)) != 0);
15551 } else {
15552 int status;
15553 struct stat st;
4fda9c95 15554
3e0be4ab
GM
15555 while (wait(&status) != child)
15556 ;
15557 return (
15558 /* Was there some problem with vforking? */
15559 child < 0
15560
15561 /* Did the child fail? (This shouldn't happen.) */
15562 || status
4fda9c95 15563
3e0be4ab
GM
15564 /* Did the vfork/compiler bug occur? */
15565 || parent != getpid()
15566
15567 /* Did the file descriptor bug occur? */
15568 || fstat(fileno(stdout), &st) != 0
15569 );
15570 }
15571}
4fda9c95 15572_ACEOF
3e0be4ab
GM
15573if ac_fn_c_try_run "$LINENO"; then :
15574 ac_cv_func_vfork_works=yes
15575else
15576 ac_cv_func_vfork_works=no
15577fi
15578rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15579 conftest.$ac_objext conftest.beam conftest.$ac_ext
15580fi
4fda9c95 15581
3e0be4ab
GM
15582fi
15583{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15584$as_echo "$ac_cv_func_vfork_works" >&6; }
4fda9c95 15585
3e0be4ab
GM
15586fi;
15587if test "x$ac_cv_func_fork_works" = xcross; then
15588 ac_cv_func_vfork_works=$ac_cv_func_vfork
15589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15590$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
4fda9c95 15591fi
4fda9c95 15592
3e0be4ab 15593if test "x$ac_cv_func_vfork_works" = xyes; then
4fda9c95 15594
3e0be4ab 15595$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
4fda9c95 15596
3e0be4ab 15597else
4fda9c95 15598
3e0be4ab 15599$as_echo "#define vfork fork" >>confdefs.h
4fda9c95 15600
3e0be4ab
GM
15601fi
15602if test "x$ac_cv_func_fork_works" = xyes; then
4fda9c95 15603
3e0be4ab 15604$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
4fda9c95 15605
3e0be4ab 15606fi
4fda9c95
GM
15607
15608
697210c4
GM
15609for ac_func in snprintf
15610do :
15611 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
a9bec17c 15612if test "x$ac_cv_func_snprintf" = x""yes; then :
697210c4
GM
15613 cat >>confdefs.h <<_ACEOF
15614#define HAVE_SNPRINTF 1
15615_ACEOF
15616
15617fi
15618done
15619
15620
3e0be4ab
GM
15621{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
15622$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
a9bec17c 15623if test "${emacs_cv_langinfo_codeset+set}" = set; then :
3e0be4ab
GM
15624 $as_echo_n "(cached) " >&6
15625else
15626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15627/* end confdefs.h. */
15628#include <langinfo.h>
15629int
15630main ()
15631{
15632char* cs = nl_langinfo(CODESET);
15633 ;
15634 return 0;
15635}
15636_ACEOF
15637if ac_fn_c_try_link "$LINENO"; then :
15638 emacs_cv_langinfo_codeset=yes
15639else
15640 emacs_cv_langinfo_codeset=no
15641fi
15642rm -f core conftest.err conftest.$ac_objext \
15643 conftest$ac_exeext conftest.$ac_ext
4fda9c95 15644
3e0be4ab
GM
15645fi
15646{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
15647$as_echo "$emacs_cv_langinfo_codeset" >&6; }
15648if test $emacs_cv_langinfo_codeset = yes; then
4fda9c95 15649
3e0be4ab 15650$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
4fda9c95 15651
3e0be4ab 15652fi
4fda9c95 15653
3e0be4ab
GM
15654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
15655$as_echo_n "checking for mbstate_t... " >&6; }
a9bec17c 15656if test "${ac_cv_type_mbstate_t+set}" = set; then :
3e0be4ab
GM
15657 $as_echo_n "(cached) " >&6
15658else
15659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15660/* end confdefs.h. */
15661$ac_includes_default
15662# include <wchar.h>
15663int
15664main ()
15665{
15666mbstate_t x; return sizeof x;
15667 ;
15668 return 0;
15669}
15670_ACEOF
15671if ac_fn_c_try_compile "$LINENO"; then :
15672 ac_cv_type_mbstate_t=yes
15673else
15674 ac_cv_type_mbstate_t=no
15675fi
15676rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15677fi
15678{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
15679$as_echo "$ac_cv_type_mbstate_t" >&6; }
15680 if test $ac_cv_type_mbstate_t = yes; then
4fda9c95 15681
3e0be4ab 15682$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
4fda9c95 15683
3e0be4ab 15684 else
4fda9c95 15685
3e0be4ab 15686$as_echo "#define mbstate_t int" >>confdefs.h
4fda9c95 15687
3e0be4ab 15688 fi
4fda9c95 15689
3e0be4ab
GM
15690{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15691$as_echo_n "checking for C restricted array declarations... " >&6; }
a9bec17c 15692if test "${emacs_cv_c_restrict_arr+set}" = set; then :
3e0be4ab
GM
15693 $as_echo_n "(cached) " >&6
15694else
15695 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15696/* end confdefs.h. */
15697void fred (int x[__restrict]);
15698int
15699main ()
15700{
4fda9c95 15701
3e0be4ab
GM
15702 ;
15703 return 0;
15704}
15705_ACEOF
15706if ac_fn_c_try_compile "$LINENO"; then :
15707 emacs_cv_c_restrict_arr=yes
15708else
15709 emacs_cv_c_restrict_arr=no
15710fi
15711rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15712fi
15713{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15714$as_echo "$emacs_cv_c_restrict_arr" >&6; }
15715if test "$emacs_cv_c_restrict_arr" = yes; then
4fda9c95 15716
3e0be4ab 15717$as_echo "#define __restrict_arr __restrict" >>confdefs.h
4fda9c95 15718
3e0be4ab 15719fi
4fda9c95
GM
15720
15721
3e0be4ab
GM
15722# Set up the CFLAGS for real compilation, so we can substitute it.
15723CFLAGS="$REAL_CFLAGS"
15724CPPFLAGS="$REAL_CPPFLAGS"
4fda9c95 15725
3e0be4ab
GM
15726## Hack to detect a buggy GCC version.
15727if test "x$GCC" = xyes \
15728 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15729 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15730 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
a9bec17c 15731 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
3e0be4ab 15732fi
4fda9c95 15733
3e0be4ab 15734version=$PACKAGE_VERSION
4fda9c95 15735
3e0be4ab
GM
15736### Specify what sort of things we'll be editing into Makefile and config.h.
15737### Use configuration here uncanonicalized to avoid exceeding size limits.
4fda9c95 15738
4fda9c95 15739
3e0be4ab 15740## Unused?
4fda9c95
GM
15741
15742
4fda9c95 15743
4fda9c95
GM
15744
15745
15746
15747
4fda9c95
GM
15748
15749
4fda9c95
GM
15750
15751
4fda9c95
GM
15752
15753
4fda9c95
GM
15754
15755
4fda9c95 15756
4fda9c95 15757
4fda9c95 15758
4fda9c95 15759
4fda9c95 15760
3e0be4ab
GM
15761## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15762## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15763## end of LIBX_BASE, but nothing ever set it.
15764
15765
15766
4fda9c95 15767
3e0be4ab
GM
15768## Used in lwlib/Makefile.in.
15769
15770if test -n "${machfile}"; then
15771 M_FILE="\$(srcdir)/${machfile}"
4fda9c95 15772else
3e0be4ab
GM
15773 M_FILE=
15774fi
15775S_FILE="\$(srcdir)/${opsysfile}"
4fda9c95
GM
15776
15777
4fda9c95
GM
15778
15779
4fda9c95
GM
15780
15781
4fda9c95 15782
4fda9c95 15783
4fda9c95 15784
3e0be4ab
GM
15785
15786cat >>confdefs.h <<_ACEOF
15787#define EMACS_CONFIGURATION "${canonical}"
4fda9c95 15788_ACEOF
4fda9c95
GM
15789
15790
3e0be4ab
GM
15791cat >>confdefs.h <<_ACEOF
15792#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15793_ACEOF
15794
15795if test -n "$machfile"; then
15796
15797cat >>confdefs.h <<_ACEOF
15798#define config_machfile "${machfile}"
15799_ACEOF
4fda9c95
GM
15800
15801fi
3e0be4ab
GM
15802
15803cat >>confdefs.h <<_ACEOF
15804#define config_opsysfile "${opsysfile}"
4fda9c95
GM
15805_ACEOF
15806
3e0be4ab
GM
15807
15808XMENU_OBJ=
15809XOBJ=
15810FONT_OBJ=
15811if test "${HAVE_X_WINDOWS}" = "yes" ; then
15812
15813$as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15814
15815 XMENU_OBJ=xmenu.o
15816 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
15817 FONT_OBJ=xfont.o
15818 if test "$HAVE_XFT" = "yes"; then
15819 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15820 elif test "$HAVE_FREETYPE" = "yes"; then
15821 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15822 fi
15823
4fda9c95
GM
15824fi
15825
4fda9c95 15826
4fda9c95 15827
4fda9c95 15828
3e0be4ab
GM
15829WIDGET_OBJ=
15830MOTIF_LIBW=
15831if test "${USE_X_TOOLKIT}" != "none" ; then
15832 WIDGET_OBJ=widget.o
15833
15834$as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
4fda9c95 15835
3e0be4ab 15836 if test "${USE_X_TOOLKIT}" = "LUCID"; then
4fda9c95 15837
3e0be4ab 15838$as_echo "#define USE_LUCID 1" >>confdefs.h
4fda9c95 15839
3e0be4ab 15840 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
4fda9c95 15841
3e0be4ab 15842$as_echo "#define USE_MOTIF 1" >>confdefs.h
4fda9c95 15843
3e0be4ab
GM
15844 MOTIF_LIBW=-lXm
15845 case "$opsys" in
15846 gnu-linux)
15847 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15848 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15849 ;;
15850
15851 unixware)
15852 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15853 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15854 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15855 ;;
15856
15857 aix4-2)
15858 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15859 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15860 ;;
15861 esac
15862 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15863 fi
15864fi
15865
15866
15867TOOLKIT_LIBW=
15868case "$USE_X_TOOLKIT" in
15869 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15870 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15871 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15872esac
15873
15874
15875if test "$USE_X_TOOLKIT" = "none"; then
15876 LIBXT_OTHER="\$(LIBXSM)"
15877 OLDXMENU_TARGET="really-oldXMenu"
4fda9c95 15878else
3e0be4ab
GM
15879 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15880 OLDXMENU_TARGET="really-lwlib"
15881fi
4fda9c95 15882
4fda9c95 15883
3e0be4ab
GM
15884## The X Menu stuff is present in the X10 distribution, but missing
15885## from X11. If we have X10, just use the installed library;
15886## otherwise, use our own copy.
15887if test "${HAVE_X11}" = "yes" ; then
15888
15889$as_echo "#define HAVE_X11 1" >>confdefs.h
15890
15891
15892 if test "$USE_X_TOOLKIT" = "none"; then
15893 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15894 else
15895 OLDXMENU="\${lwlibdir}/liblw.a"
15896 fi
15897 LIBXMENU="\$(OLDXMENU)"
15898 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15899 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
4fda9c95 15900else
3e0be4ab
GM
15901 ## For a syntactically valid Makefile; not actually used for anything.
15902 ## See comments in src/Makefile.in.
15903 OLDXMENU=nothing
15904 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15905 if test "${HAVE_X_WINDOWS}" = "yes"; then
15906 LIBXMENU="-lXMenu"
15907 else
15908 LIBXMENU=
15909 fi
15910 LIBX_OTHER=
15911 OLDXMENU_DEPS=
4fda9c95
GM
15912fi
15913
3e0be4ab
GM
15914if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15915 OLDXMENU_TARGET=
15916 OLDXMENU=nothing
15917 LIBXMENU=
15918 OLDXMENU_DEPS=
15919fi
15920
15921
15922
15923
15924
15925
15926
15927if test "${HAVE_MENUS}" = "yes" ; then
15928
15929$as_echo "#define HAVE_MENUS 1" >>confdefs.h
4fda9c95
GM
15930
15931fi
4fda9c95 15932
3e0be4ab 15933if test "${GNU_MALLOC}" = "yes" ; then
4fda9c95 15934
3e0be4ab 15935$as_echo "#define GNU_MALLOC 1" >>confdefs.h
4fda9c95 15936
3e0be4ab 15937fi
4fda9c95 15938
3e0be4ab
GM
15939RALLOC_OBJ=
15940if test "${REL_ALLOC}" = "yes" ; then
4fda9c95 15941
3e0be4ab 15942$as_echo "#define REL_ALLOC 1" >>confdefs.h
4fda9c95 15943
4fda9c95 15944
3e0be4ab 15945 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
4fda9c95
GM
15946fi
15947
4fda9c95 15948
3e0be4ab
GM
15949if test "$opsys" = "cygwin"; then
15950 CYGWIN_OBJ="sheap.o"
15951 ## Cygwin differs because of its unexec().
15952 PRE_ALLOC_OBJ=
15953 POST_ALLOC_OBJ=lastfile.o
15954else
15955 CYGWIN_OBJ=
15956 PRE_ALLOC_OBJ=lastfile.o
15957 POST_ALLOC_OBJ=
4fda9c95 15958fi
4fda9c95 15959
4fda9c95
GM
15960
15961
15962
3e0be4ab 15963# Configure gnulib here, now that we know LIBS.
4fda9c95 15964
3e0be4ab
GM
15965
15966
15967
15968
15969
15970
15971
15972
15973
369e19fc 15974
3e0be4ab
GM
15975 LIBC_FATAL_STDERR_=1
15976 export LIBC_FATAL_STDERR_
15977
15978# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15979# for constant arguments. Useless!
15980{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15981$as_echo_n "checking for working alloca.h... " >&6; }
a9bec17c 15982if test "${ac_cv_working_alloca_h+set}" = set; then :
4fda9c95
GM
15983 $as_echo_n "(cached) " >&6
15984else
15985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15986/* end confdefs.h. */
3e0be4ab 15987#include <alloca.h>
4fda9c95
GM
15988int
15989main ()
15990{
3e0be4ab
GM
15991char *p = (char *) alloca (2 * sizeof (int));
15992 if (p) return 0;
4fda9c95
GM
15993 ;
15994 return 0;
15995}
15996_ACEOF
3e0be4ab
GM
15997if ac_fn_c_try_link "$LINENO"; then :
15998 ac_cv_working_alloca_h=yes
4fda9c95 15999else
3e0be4ab 16000 ac_cv_working_alloca_h=no
4fda9c95 16001fi
3e0be4ab
GM
16002rm -f core conftest.err conftest.$ac_objext \
16003 conftest$ac_exeext conftest.$ac_ext
4fda9c95 16004fi
3e0be4ab
GM
16005{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16006$as_echo "$ac_cv_working_alloca_h" >&6; }
16007if test $ac_cv_working_alloca_h = yes; then
4fda9c95 16008
3e0be4ab 16009$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
4fda9c95 16010
3e0be4ab 16011fi
4fda9c95 16012
3e0be4ab
GM
16013{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16014$as_echo_n "checking for alloca... " >&6; }
a9bec17c 16015if test "${ac_cv_func_alloca_works+set}" = set; then :
4fda9c95
GM
16016 $as_echo_n "(cached) " >&6
16017else
3e0be4ab 16018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4fda9c95 16019/* end confdefs.h. */
3e0be4ab
GM
16020#ifdef __GNUC__
16021# define alloca __builtin_alloca
16022#else
16023# ifdef _MSC_VER
16024# include <malloc.h>
16025# define alloca _alloca
16026# else
16027# ifdef HAVE_ALLOCA_H
16028# include <alloca.h>
16029# else
16030# ifdef _AIX
16031 #pragma alloca
16032# else
16033# ifndef alloca /* predefined by HP cc +Olibcalls */
a9bec17c 16034char *alloca ();
3e0be4ab
GM
16035# endif
16036# endif
16037# endif
16038# endif
16039#endif
4fda9c95 16040
4fda9c95
GM
16041int
16042main ()
16043{
3e0be4ab
GM
16044char *p = (char *) alloca (1);
16045 if (p) return 0;
4fda9c95
GM
16046 ;
16047 return 0;
16048}
16049_ACEOF
3e0be4ab
GM
16050if ac_fn_c_try_link "$LINENO"; then :
16051 ac_cv_func_alloca_works=yes
16052else
16053 ac_cv_func_alloca_works=no
4fda9c95 16054fi
3e0be4ab
GM
16055rm -f core conftest.err conftest.$ac_objext \
16056 conftest$ac_exeext conftest.$ac_ext
4fda9c95 16057fi
3e0be4ab
GM
16058{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16059$as_echo "$ac_cv_func_alloca_works" >&6; }
4fda9c95 16060
3e0be4ab 16061if test $ac_cv_func_alloca_works = yes; then
4fda9c95 16062
3e0be4ab 16063$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
4fda9c95 16064
3e0be4ab
GM
16065else
16066 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16067# that cause trouble. Some versions do not even contain alloca or
16068# contain a buggy version. If you still want to use their alloca,
16069# use ar to extract alloca.o from them instead of compiling alloca.c.
4fda9c95
GM
16070
16071
3e0be4ab
GM
16072
16073
16074
16075ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16076
16077$as_echo "#define C_ALLOCA 1" >>confdefs.h
16078
16079
16080{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
16081$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
a9bec17c 16082if test "${ac_cv_os_cray+set}" = set; then :
4fda9c95
GM
16083 $as_echo_n "(cached) " >&6
16084else
3e0be4ab 16085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4fda9c95 16086/* end confdefs.h. */
3e0be4ab
GM
16087#if defined CRAY && ! defined CRAY2
16088webecray
16089#else
16090wenotbecray
16091#endif
4fda9c95 16092
3e0be4ab
GM
16093_ACEOF
16094if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16095 $EGREP "webecray" >/dev/null 2>&1; then :
16096 ac_cv_os_cray=yes
16097else
16098 ac_cv_os_cray=no
16099fi
16100rm -f conftest*
4fda9c95 16101
3e0be4ab
GM
16102fi
16103{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16104$as_echo "$ac_cv_os_cray" >&6; }
16105if test $ac_cv_os_cray = yes; then
16106 for ac_func in _getb67 GETB67 getb67; do
16107 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16108ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
16109eval as_val=\$$as_ac_var
16110 if test "x$as_val" = x""yes; then :
3e0be4ab
GM
16111
16112cat >>confdefs.h <<_ACEOF
16113#define CRAY_STACKSEG_END $ac_func
16114_ACEOF
16115
16116 break
16117fi
16118
16119 done
16120fi
16121
16122{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16123$as_echo_n "checking stack direction for C alloca... " >&6; }
a9bec17c 16124if test "${ac_cv_c_stack_direction+set}" = set; then :
3e0be4ab
GM
16125 $as_echo_n "(cached) " >&6
16126else
16127 if test "$cross_compiling" = yes; then :
16128 ac_cv_c_stack_direction=0
16129else
16130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16131/* end confdefs.h. */
16132$ac_includes_default
4fda9c95 16133int
3e0be4ab 16134find_stack_direction (int *addr, int depth)
4fda9c95 16135{
3e0be4ab
GM
16136 int dir, dummy = 0;
16137 if (! addr)
16138 addr = &dummy;
16139 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16140 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16141 return dir + dummy;
16142}
4fda9c95 16143
3e0be4ab
GM
16144int
16145main (int argc, char **argv)
16146{
16147 return find_stack_direction (0, argc + !argv + 20) < 0;
4fda9c95
GM
16148}
16149_ACEOF
3e0be4ab
GM
16150if ac_fn_c_try_run "$LINENO"; then :
16151 ac_cv_c_stack_direction=1
16152else
16153 ac_cv_c_stack_direction=-1
4fda9c95 16154fi
3e0be4ab
GM
16155rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16156 conftest.$ac_objext conftest.beam conftest.$ac_ext
4fda9c95 16157fi
3e0be4ab
GM
16158
16159fi
16160{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16161$as_echo "$ac_cv_c_stack_direction" >&6; }
16162cat >>confdefs.h <<_ACEOF
16163#define STACK_DIRECTION $ac_cv_c_stack_direction
4fda9c95
GM
16164_ACEOF
16165
da6c8463 16166
3e0be4ab 16167fi
da6c8463
GM
16168
16169
16170
16171
3e0be4ab
GM
16172 for ac_func in $ac_func_list
16173do :
16174 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16175ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
a9bec17c
GM
16176eval as_val=\$$as_ac_var
16177 if test "x$as_val" = x""yes; then :
3e0be4ab
GM
16178 cat >>confdefs.h <<_ACEOF
16179#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16180_ACEOF
da6c8463 16181
3e0be4ab
GM
16182fi
16183done
da6c8463
GM
16184
16185
16186
16187
3e0be4ab
GM
16188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16189$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
a9bec17c 16190if test "${ac_cv_c_bigendian+set}" = set; then :
da6c8463
GM
16191 $as_echo_n "(cached) " >&6
16192else
3e0be4ab
GM
16193 ac_cv_c_bigendian=unknown
16194 # See if we're dealing with a universal compiler.
16195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
da6c8463 16196/* end confdefs.h. */
3e0be4ab
GM
16197#ifndef __APPLE_CC__
16198 not a universal capable compiler
16199 #endif
16200 typedef int dummy;
da6c8463
GM
16201
16202_ACEOF
3e0be4ab 16203if ac_fn_c_try_compile "$LINENO"; then :
da6c8463 16204
3e0be4ab
GM
16205 # Check for potential -arch flags. It is not universal unless
16206 # there are at least two -arch flags with different values.
16207 ac_arch=
16208 ac_prev=
16209 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16210 if test -n "$ac_prev"; then
16211 case $ac_word in
16212 i?86 | x86_64 | ppc | ppc64)
16213 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16214 ac_arch=$ac_word
16215 else
16216 ac_cv_c_bigendian=universal
16217 break
16218 fi
16219 ;;
16220 esac
16221 ac_prev=
16222 elif test "x$ac_word" = "x-arch"; then
16223 ac_prev=arch
16224 fi
16225 done
da6c8463 16226fi
3e0be4ab
GM
16227rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16228 if test $ac_cv_c_bigendian = unknown; then
16229 # See if sys/param.h defines the BYTE_ORDER macro.
16230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16231/* end confdefs.h. */
16232#include <sys/types.h>
16233 #include <sys/param.h>
ce4331ef 16234
3e0be4ab
GM
16235int
16236main ()
16237{
16238#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16239 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16240 && LITTLE_ENDIAN)
16241 bogus endian macros
16242 #endif
ce4331ef 16243
3e0be4ab
GM
16244 ;
16245 return 0;
16246}
16247_ACEOF
16248if ac_fn_c_try_compile "$LINENO"; then :
16249 # It does; now see whether it defined to BIG_ENDIAN or not.
16250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4fda9c95 16251/* end confdefs.h. */
3e0be4ab
GM
16252#include <sys/types.h>
16253 #include <sys/param.h>
16254
4fda9c95
GM
16255int
16256main ()
16257{
3e0be4ab
GM
16258#if BYTE_ORDER != BIG_ENDIAN
16259 not big endian
16260 #endif
ce4331ef 16261
4fda9c95
GM
16262 ;
16263 return 0;
16264}
16265_ACEOF
3e0be4ab
GM
16266if ac_fn_c_try_compile "$LINENO"; then :
16267 ac_cv_c_bigendian=yes
ae0d7250 16268else
3e0be4ab 16269 ac_cv_c_bigendian=no
ae0d7250 16270fi
3e0be4ab 16271rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ae0d7250 16272fi
3e0be4ab
GM
16273rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16274 fi
16275 if test $ac_cv_c_bigendian = unknown; then
16276 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16278/* end confdefs.h. */
16279#include <limits.h>
ae0d7250 16280
3e0be4ab
GM
16281int
16282main ()
16283{
16284#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16285 bogus endian macros
16286 #endif
ae0d7250 16287
3e0be4ab
GM
16288 ;
16289 return 0;
16290}
6ad6792b 16291_ACEOF
3e0be4ab
GM
16292if ac_fn_c_try_compile "$LINENO"; then :
16293 # It does; now see whether it defined to _BIG_ENDIAN or not.
16294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1f5d53eb 16295/* end confdefs.h. */
3e0be4ab 16296#include <limits.h>
4fda9c95 16297
5f90be1b
PE
16298int
16299main ()
16300{
3e0be4ab
GM
16301#ifndef _BIG_ENDIAN
16302 not big endian
16303 #endif
4fda9c95 16304
5f90be1b
PE
16305 ;
16306 return 0;
16307}
5f90be1b 16308_ACEOF
4fda9c95 16309if ac_fn_c_try_compile "$LINENO"; then :
3e0be4ab 16310 ac_cv_c_bigendian=yes
5f90be1b 16311else
3e0be4ab 16312 ac_cv_c_bigendian=no
5f90be1b 16313fi
4fda9c95 16314rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5f90be1b 16315fi
3e0be4ab
GM
16316rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16317 fi
16318 if test $ac_cv_c_bigendian = unknown; then
16319 # Compile a test program.
16320 if test "$cross_compiling" = yes; then :
16321 # Try to guess by grepping values from an object file.
16322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16323/* end confdefs.h. */
16324short int ascii_mm[] =
16325 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16326 short int ascii_ii[] =
16327 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16328 int use_ascii (int i) {
16329 return ascii_mm[i] + ascii_ii[i];
16330 }
16331 short int ebcdic_ii[] =
16332 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16333 short int ebcdic_mm[] =
16334 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16335 int use_ebcdic (int i) {
16336 return ebcdic_mm[i] + ebcdic_ii[i];
16337 }
16338 extern int foo;
5f90be1b 16339
3e0be4ab
GM
16340int
16341main ()
16342{
16343return use_ascii (foo) == use_ebcdic (foo);
16344 ;
16345 return 0;
16346}
4fda9c95 16347_ACEOF
3e0be4ab
GM
16348if ac_fn_c_try_compile "$LINENO"; then :
16349 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16350 ac_cv_c_bigendian=yes
16351 fi
16352 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16353 if test "$ac_cv_c_bigendian" = unknown; then
16354 ac_cv_c_bigendian=no
16355 else
16356 # finding both strings is unlikely to happen, but who knows?
16357 ac_cv_c_bigendian=unknown
16358 fi
16359 fi
16360fi
16361rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16362else
16363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16364/* end confdefs.h. */
16365$ac_includes_default
16366int
16367main ()
16368{
5f90be1b 16369
3e0be4ab
GM
16370 /* Are we little or big endian? From Harbison&Steele. */
16371 union
16372 {
16373 long int l;
16374 char c[sizeof (long int)];
16375 } u;
16376 u.l = 1;
16377 return u.c[sizeof (long int) - 1] == 1;
4fda9c95 16378
3e0be4ab
GM
16379 ;
16380 return 0;
16381}
16382_ACEOF
16383if ac_fn_c_try_run "$LINENO"; then :
16384 ac_cv_c_bigendian=no
16385else
16386 ac_cv_c_bigendian=yes
16387fi
16388rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16389 conftest.$ac_objext conftest.beam conftest.$ac_ext
4fda9c95 16390fi
5f90be1b 16391
3e0be4ab
GM
16392 fi
16393fi
16394{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16395$as_echo "$ac_cv_c_bigendian" >&6; }
16396 case $ac_cv_c_bigendian in #(
16397 yes)
16398 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16399;; #(
16400 no)
16401 ;; #(
16402 universal)
5f90be1b 16403
3e0be4ab 16404$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
5f90be1b 16405
3e0be4ab
GM
16406 ;; #(
16407 *)
a9bec17c 16408 as_fn_error "unknown endianness
3e0be4ab
GM
16409 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16410 esac
4fda9c95
GM
16411
16412
3e0be4ab
GM
16413{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16414$as_echo_n "checking for inline... " >&6; }
a9bec17c 16415if test "${ac_cv_c_inline+set}" = set; then :
5f90be1b 16416 $as_echo_n "(cached) " >&6
5f90be1b 16417else
3e0be4ab
GM
16418 ac_cv_c_inline=no
16419for ac_kw in inline __inline__ __inline; do
5f90be1b
PE
16420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16421/* end confdefs.h. */
3e0be4ab
GM
16422#ifndef __cplusplus
16423typedef int foo_t;
16424static $ac_kw foo_t static_foo () {return 0; }
16425$ac_kw foo_t foo () {return 0; }
16426#endif
4fda9c95 16427
5f90be1b 16428_ACEOF
4fda9c95 16429if ac_fn_c_try_compile "$LINENO"; then :
3e0be4ab 16430 ac_cv_c_inline=$ac_kw
5f90be1b 16431fi
4fda9c95 16432rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3e0be4ab
GM
16433 test "$ac_cv_c_inline" != no && break
16434done
5f90be1b 16435
3e0be4ab
GM
16436fi
16437{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16438$as_echo "$ac_cv_c_inline" >&6; }
5f90be1b 16439
3e0be4ab
GM
16440case $ac_cv_c_inline in
16441 inline | yes) ;;
16442 *)
16443 case $ac_cv_c_inline in
16444 no) ac_val=;;
16445 *) ac_val=$ac_cv_c_inline;;
16446 esac
16447 cat >>confdefs.h <<_ACEOF
16448#ifndef __cplusplus
16449#define inline $ac_val
16450#endif
16451_ACEOF
16452 ;;
16453esac
5f90be1b
PE
16454
16455
3e0be4ab
GM
16456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16457$as_echo_n "checking whether strtold conforms to C99... " >&6; }
a9bec17c 16458if test "${gl_cv_func_c99_strtold+set}" = set; then :
3e0be4ab
GM
16459 $as_echo_n "(cached) " >&6
16460else
16461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16462/* end confdefs.h. */
16463/* On HP-UX before 11.23, strtold returns a struct instead of
16464 long double. Reject implementations like that, by requiring
16465 compatibility with the C99 prototype. */
16466 #include <stdlib.h>
16467 static long double (*p) (char const *, char **) = strtold;
16468 static long double
16469 test (char const *nptr, char **endptr)
16470 {
16471 long double r;
16472 r = strtold (nptr, endptr);
16473 return r;
16474 }
16475int
16476main ()
16477{
16478return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16479 ;
16480 return 0;
16481}
16482_ACEOF
16483if ac_fn_c_try_link "$LINENO"; then :
16484 gl_cv_func_c99_strtold=yes
16485else
16486 gl_cv_func_c99_strtold=no
16487fi
16488rm -f core conftest.err conftest.$ac_objext \
16489 conftest$ac_exeext conftest.$ac_ext
16490fi
16491{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16492$as_echo "$gl_cv_func_c99_strtold" >&6; }
16493 if test $gl_cv_func_c99_strtold = yes; then
16494
16495$as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16496
16497 fi
16498
16499
2b1928b8 16500 GNULIB_CHDIR=0;
3e0be4ab
GM
16501 GNULIB_CHOWN=0;
16502 GNULIB_CLOSE=0;
2b1928b8 16503 GNULIB_DUP=0;
3e0be4ab
GM
16504 GNULIB_DUP2=0;
16505 GNULIB_DUP3=0;
16506 GNULIB_ENVIRON=0;
16507 GNULIB_EUIDACCESS=0;
16508 GNULIB_FACCESSAT=0;
16509 GNULIB_FCHDIR=0;
16510 GNULIB_FCHOWNAT=0;
2b1928b8 16511 GNULIB_FDATASYNC=0;
3e0be4ab
GM
16512 GNULIB_FSYNC=0;
16513 GNULIB_FTRUNCATE=0;
16514 GNULIB_GETCWD=0;
16515 GNULIB_GETDOMAINNAME=0;
16516 GNULIB_GETDTABLESIZE=0;
16517 GNULIB_GETGROUPS=0;
16518 GNULIB_GETHOSTNAME=0;
16519 GNULIB_GETLOGIN=0;
16520 GNULIB_GETLOGIN_R=0;
16521 GNULIB_GETPAGESIZE=0;
16522 GNULIB_GETUSERSHELL=0;
16523 GNULIB_GROUP_MEMBER=0;
16524 GNULIB_LCHOWN=0;
16525 GNULIB_LINK=0;
16526 GNULIB_LINKAT=0;
16527 GNULIB_LSEEK=0;
16528 GNULIB_PIPE=0;
16529 GNULIB_PIPE2=0;
16530 GNULIB_PREAD=0;
16531 GNULIB_PWRITE=0;
16532 GNULIB_READ=0;
16533 GNULIB_READLINK=0;
16534 GNULIB_READLINKAT=0;
16535 GNULIB_RMDIR=0;
16536 GNULIB_SLEEP=0;
16537 GNULIB_SYMLINK=0;
16538 GNULIB_SYMLINKAT=0;
16539 GNULIB_TTYNAME_R=0;
16540 GNULIB_UNISTD_H_GETOPT=0;
16541 GNULIB_UNISTD_H_NONBLOCKING=0;
16542 GNULIB_UNISTD_H_SIGPIPE=0;
16543 GNULIB_UNLINK=0;
16544 GNULIB_UNLINKAT=0;
16545 GNULIB_USLEEP=0;
16546 GNULIB_WRITE=0;
16547 HAVE_CHOWN=1;
16548 HAVE_DUP2=1;
16549 HAVE_DUP3=1;
16550 HAVE_EUIDACCESS=1;
16551 HAVE_FACCESSAT=1;
16552 HAVE_FCHDIR=1;
16553 HAVE_FCHOWNAT=1;
2b1928b8 16554 HAVE_FDATASYNC=1;
3e0be4ab
GM
16555 HAVE_FSYNC=1;
16556 HAVE_FTRUNCATE=1;
16557 HAVE_GETDTABLESIZE=1;
16558 HAVE_GETGROUPS=1;
16559 HAVE_GETHOSTNAME=1;
16560 HAVE_GETLOGIN=1;
16561 HAVE_GETPAGESIZE=1;
16562 HAVE_GROUP_MEMBER=1;
16563 HAVE_LCHOWN=1;
16564 HAVE_LINK=1;
16565 HAVE_LINKAT=1;
16566 HAVE_PIPE=1;
16567 HAVE_PIPE2=1;
16568 HAVE_PREAD=1;
16569 HAVE_PWRITE=1;
16570 HAVE_READLINK=1;
16571 HAVE_READLINKAT=1;
16572 HAVE_SLEEP=1;
16573 HAVE_SYMLINK=1;
16574 HAVE_SYMLINKAT=1;
16575 HAVE_UNLINKAT=1;
16576 HAVE_USLEEP=1;
16577 HAVE_DECL_ENVIRON=1;
16578 HAVE_DECL_FCHDIR=1;
2b1928b8 16579 HAVE_DECL_FDATASYNC=1;
3e0be4ab
GM
16580 HAVE_DECL_GETDOMAINNAME=1;
16581 HAVE_DECL_GETLOGIN_R=1;
16582 HAVE_DECL_GETPAGESIZE=1;
16583 HAVE_DECL_GETUSERSHELL=1;
16584 HAVE_DECL_TTYNAME_R=1;
16585 HAVE_OS_H=0;
16586 HAVE_SYS_PARAM_H=0;
16587 REPLACE_CHOWN=0;
16588 REPLACE_CLOSE=0;
16589 REPLACE_DUP=0;
16590 REPLACE_DUP2=0;
16591 REPLACE_FCHOWNAT=0;
16592 REPLACE_GETCWD=0;
16593 REPLACE_GETDOMAINNAME=0;
16594 REPLACE_GETLOGIN_R=0;
16595 REPLACE_GETGROUPS=0;
16596 REPLACE_GETPAGESIZE=0;
16597 REPLACE_LCHOWN=0;
16598 REPLACE_LINK=0;
16599 REPLACE_LINKAT=0;
16600 REPLACE_LSEEK=0;
16601 REPLACE_PREAD=0;
16602 REPLACE_PWRITE=0;
16603 REPLACE_READ=0;
16604 REPLACE_READLINK=0;
16605 REPLACE_RMDIR=0;
16606 REPLACE_SLEEP=0;
16607 REPLACE_SYMLINK=0;
16608 REPLACE_TTYNAME_R=0;
16609 REPLACE_UNLINK=0;
16610 REPLACE_UNLINKAT=0;
16611 REPLACE_USLEEP=0;
16612 REPLACE_WRITE=0;
16613 UNISTD_H_HAVE_WINSOCK2_H=0;
16614 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16615
16616
3e0be4ab
GM
16617{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16618$as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
a9bec17c 16619if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
3e0be4ab
GM
16620 $as_echo_n "(cached) " >&6
16621else
16622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16623/* end confdefs.h. */
16624
16625#include <sys/types.h>
16626#include <sys/stat.h>
16627int
16628main ()
16629{
16630struct stat s; s.st_dm_mode;
16631 ;
16632 return 0;
16633}
16634_ACEOF
16635if ac_fn_c_try_compile "$LINENO"; then :
16636 ac_cv_struct_st_dm_mode=yes
16637else
16638 ac_cv_struct_st_dm_mode=no
16639fi
16640rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16641fi
16642{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16643$as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16644
16645 if test $ac_cv_struct_st_dm_mode = yes; then
16646
16647$as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16648
16649 fi
16650
16651
16652ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
a9bec17c 16653if test "x$ac_cv_have_decl_strmode" = x""yes; then :
3e0be4ab
GM
16654 ac_have_decl=1
16655else
16656 ac_have_decl=0
16657fi
16658
16659cat >>confdefs.h <<_ACEOF
16660#define HAVE_DECL_STRMODE $ac_have_decl
16661_ACEOF
16662
16663
16664 GNULIB__EXIT=0;
16665 GNULIB_ATOLL=0;
16666 GNULIB_CALLOC_POSIX=0;
16667 GNULIB_CANONICALIZE_FILE_NAME=0;
16668 GNULIB_GETLOADAVG=0;
16669 GNULIB_GETSUBOPT=0;
16670 GNULIB_GRANTPT=0;
16671 GNULIB_MALLOC_POSIX=0;
16672 GNULIB_MBTOWC=0;
16673 GNULIB_MKDTEMP=0;
16674 GNULIB_MKOSTEMP=0;
16675 GNULIB_MKOSTEMPS=0;
16676 GNULIB_MKSTEMP=0;
16677 GNULIB_MKSTEMPS=0;
16678 GNULIB_PTSNAME=0;
16679 GNULIB_PUTENV=0;
16680 GNULIB_RANDOM_R=0;
16681 GNULIB_REALLOC_POSIX=0;
16682 GNULIB_REALPATH=0;
16683 GNULIB_RPMATCH=0;
16684 GNULIB_SETENV=0;
16685 GNULIB_STRTOD=0;
16686 GNULIB_STRTOLL=0;
16687 GNULIB_STRTOULL=0;
16688 GNULIB_SYSTEM_POSIX=0;
16689 GNULIB_UNLOCKPT=0;
16690 GNULIB_UNSETENV=0;
16691 GNULIB_WCTOMB=0;
16692 HAVE__EXIT=1;
16693 HAVE_ATOLL=1;
16694 HAVE_CANONICALIZE_FILE_NAME=1;
16695 HAVE_DECL_GETLOADAVG=1;
16696 HAVE_GETSUBOPT=1;
16697 HAVE_GRANTPT=1;
16698 HAVE_MKDTEMP=1;
16699 HAVE_MKOSTEMP=1;
16700 HAVE_MKOSTEMPS=1;
16701 HAVE_MKSTEMP=1;
16702 HAVE_MKSTEMPS=1;
16703 HAVE_PTSNAME=1;
16704 HAVE_RANDOM_H=1;
16705 HAVE_RANDOM_R=1;
16706 HAVE_REALPATH=1;
16707 HAVE_RPMATCH=1;
16708 HAVE_SETENV=1;
16709 HAVE_DECL_SETENV=1;
16710 HAVE_STRTOD=1;
16711 HAVE_STRTOLL=1;
16712 HAVE_STRTOULL=1;
16713 HAVE_STRUCT_RANDOM_DATA=1;
16714 HAVE_SYS_LOADAVG_H=0;
16715 HAVE_UNLOCKPT=1;
16716 HAVE_DECL_UNSETENV=1;
16717 REPLACE_CALLOC=0;
16718 REPLACE_CANONICALIZE_FILE_NAME=0;
16719 REPLACE_MALLOC=0;
16720 REPLACE_MBTOWC=0;
16721 REPLACE_MKSTEMP=0;
16722 REPLACE_PUTENV=0;
16723 REPLACE_REALLOC=0;
16724 REPLACE_REALPATH=0;
16725 REPLACE_SETENV=0;
16726 REPLACE_STRTOD=0;
16727 REPLACE_UNSETENV=0;
16728 REPLACE_WCTOMB=0;
16729
16730
16731
16732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16733$as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
a9bec17c 16734if test "${gl_cv_have_include_next+set}" = set; then :
3e0be4ab
GM
16735 $as_echo_n "(cached) " >&6
16736else
16737 rm -rf conftestd1a conftestd1b conftestd2
16738 mkdir conftestd1a conftestd1b conftestd2
16739 cat <<EOF > conftestd1a/conftest.h
16740#define DEFINED_IN_CONFTESTD1
16741#include_next <conftest.h>
16742#ifdef DEFINED_IN_CONFTESTD2
16743int foo;
16744#else
16745#error "include_next doesn't work"
16746#endif
16747EOF
16748 cat <<EOF > conftestd1b/conftest.h
16749#define DEFINED_IN_CONFTESTD1
16750#include <stdio.h>
16751#include_next <conftest.h>
16752#ifdef DEFINED_IN_CONFTESTD2
16753int foo;
16754#else
16755#error "include_next doesn't work"
16756#endif
16757EOF
16758 cat <<EOF > conftestd2/conftest.h
16759#ifndef DEFINED_IN_CONFTESTD1
16760#error "include_next test doesn't work"
16761#endif
16762#define DEFINED_IN_CONFTESTD2
16763EOF
16764 gl_save_CPPFLAGS="$CPPFLAGS"
16765 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16767/* end confdefs.h. */
16768#include <conftest.h>
16769_ACEOF
16770if ac_fn_c_try_compile "$LINENO"; then :
16771 gl_cv_have_include_next=yes
16772else
16773 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16775/* end confdefs.h. */
16776#include <conftest.h>
16777_ACEOF
16778if ac_fn_c_try_compile "$LINENO"; then :
16779 gl_cv_have_include_next=buggy
16780else
16781 gl_cv_have_include_next=no
16782fi
16783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16784
16785fi
16786rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16787 CPPFLAGS="$gl_save_CPPFLAGS"
16788 rm -rf conftestd1a conftestd1b conftestd2
16789
16790fi
16791{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16792$as_echo "$gl_cv_have_include_next" >&6; }
16793 PRAGMA_SYSTEM_HEADER=
16794 if test $gl_cv_have_include_next = yes; then
16795 INCLUDE_NEXT=include_next
16796 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16797 if test -n "$GCC"; then
16798 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16799 fi
16800 else
16801 if test $gl_cv_have_include_next = buggy; then
16802 INCLUDE_NEXT=include
16803 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16804 else
16805 INCLUDE_NEXT=include
16806 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16807 fi
16808 fi
16809
16810
16811
16812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16813$as_echo_n "checking whether system header files limit the line length... " >&6; }
a9bec17c 16814if test "${gl_cv_pragma_columns+set}" = set; then :
3e0be4ab
GM
16815 $as_echo_n "(cached) " >&6
16816else
16817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16818/* end confdefs.h. */
16819
16820#ifdef __TANDEM
16821choke me
16822#endif
16823
16824_ACEOF
16825if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16826 $EGREP "choke me" >/dev/null 2>&1; then :
16827 gl_cv_pragma_columns=yes
16828else
16829 gl_cv_pragma_columns=no
16830fi
16831rm -f conftest*
16832
16833
16834fi
16835{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16836$as_echo "$gl_cv_pragma_columns" >&6; }
16837 if test $gl_cv_pragma_columns = yes; then
16838 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16839 else
16840 PRAGMA_COLUMNS=
16841 fi
16842
16843
16844
16845
16846
16847
16848
16849
16850
16851
16852
16853
16854
16855
16856
16857
16858
16859 if test $gl_cv_have_include_next = yes; then
16860 gl_cv_next_getopt_h='<'getopt.h'>'
16861 else
16862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16863$as_echo_n "checking absolute name of <getopt.h>... " >&6; }
a9bec17c 16864if test "${gl_cv_next_getopt_h+set}" = set; then :
3e0be4ab
GM
16865 $as_echo_n "(cached) " >&6
16866else
16867
16868 if test $ac_cv_header_getopt_h = yes; then
16869
16870
16871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16872/* end confdefs.h. */
16873#include <getopt.h>
16874
16875_ACEOF
16876 case "$host_os" in
16877 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16878 *) gl_absname_cpp="$ac_cpp" ;;
16879 esac
b0415a03
GM
16880
16881 case "$host_os" in
16882 mingw*)
16883 gl_dirsep_regex='[/\\]'
16884 ;;
16885 *)
16886 gl_dirsep_regex='/'
16887 ;;
16888 esac
16889
2b1928b8
GM
16890 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'getopt.h|{
16891 s|.*"\(.*'"${gl_dirsep_regex}"'getopt.h\)".*|\1|
16892 s|^/[^/]|//&|
b0415a03
GM
16893 p
16894 q
16895 }'
3e0be4ab 16896 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 16897 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
16898 else
16899 gl_cv_next_getopt_h='<'getopt.h'>'
16900 fi
16901
16902
16903fi
16904{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
16905$as_echo "$gl_cv_next_getopt_h" >&6; }
16906 fi
16907 NEXT_GETOPT_H=$gl_cv_next_getopt_h
16908
16909 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16910 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16911 gl_next_as_first_directive='<'getopt.h'>'
16912 else
16913 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16914 gl_next_as_first_directive=$gl_cv_next_getopt_h
16915 fi
16916 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
16917
16918
16919
16920
16921 if test $ac_cv_header_getopt_h = yes; then
16922 HAVE_GETOPT_H=1
16923 else
16924 HAVE_GETOPT_H=0
16925 fi
16926
16927
16928 gl_replace_getopt=
16929
16930 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16931 for ac_header in getopt.h
16932do :
16933 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
a9bec17c 16934if test "x$ac_cv_header_getopt_h" = x""yes; then :
3e0be4ab
GM
16935 cat >>confdefs.h <<_ACEOF
16936#define HAVE_GETOPT_H 1
16937_ACEOF
16938
16939else
16940 gl_replace_getopt=yes
16941fi
16942
16943done
16944
16945 fi
16946
16947 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16948 for ac_func in getopt_long_only
16949do :
16950 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
a9bec17c 16951if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
3e0be4ab
GM
16952 cat >>confdefs.h <<_ACEOF
16953#define HAVE_GETOPT_LONG_ONLY 1
16954_ACEOF
16955
16956else
16957 gl_replace_getopt=yes
16958fi
16959done
16960
16961 fi
16962
16963 if test -z "$gl_replace_getopt"; then
16964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
16965$as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
a9bec17c 16966if test "${gl_cv_func_getopt_posix+set}" = set; then :
3e0be4ab
GM
16967 $as_echo_n "(cached) " >&6
16968else
16969
16970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16971/* end confdefs.h. */
16972#include <unistd.h>
16973int
16974main ()
16975{
16976int *p = &optreset; return optreset;
16977 ;
16978 return 0;
16979}
16980_ACEOF
16981if ac_fn_c_try_link "$LINENO"; then :
16982 gl_optind_min=1
16983else
16984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16985/* end confdefs.h. */
16986#include <getopt.h>
16987int
16988main ()
16989{
16990return !getopt_clip;
16991 ;
16992 return 0;
16993}
16994_ACEOF
16995if ac_fn_c_try_compile "$LINENO"; then :
16996 gl_optind_min=1
16997else
16998 gl_optind_min=0
16999fi
17000rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17001fi
17002rm -f core conftest.err conftest.$ac_objext \
17003 conftest$ac_exeext conftest.$ac_ext
17004
17005 gl_save_CPPFLAGS=$CPPFLAGS
17006 CPPFLAGS="$CPPFLAGS -DOPTIND_MIN=$gl_optind_min"
17007 if test "$cross_compiling" = yes; then :
17008 case "$host_os" in
17009 mingw*) gl_cv_func_getopt_posix="guessing no";;
17010 darwin* | aix*) gl_cv_func_getopt_posix="guessing no";;
17011 *) gl_cv_func_getopt_posix="guessing yes";;
17012 esac
17013
17014else
17015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17016/* end confdefs.h. */
17017
17018#include <unistd.h>
17019#include <stdlib.h>
17020#include <string.h>
17021
17022int
17023main ()
17024{
17025 {
17026 static char program[] = "program";
17027 static char a[] = "-a";
17028 static char foo[] = "foo";
17029 static char bar[] = "bar";
17030 char *argv[] = { program, a, foo, bar, NULL };
17031 int c;
17032
17033 optind = OPTIND_MIN;
17034 opterr = 0;
17035
17036 c = getopt (4, argv, "ab");
17037 if (!(c == 'a'))
17038 return 1;
17039 c = getopt (4, argv, "ab");
17040 if (!(c == -1))
17041 return 2;
17042 if (!(optind == 2))
17043 return 3;
17044 }
17045 /* Some internal state exists at this point. */
17046 {
17047 static char program[] = "program";
17048 static char donald[] = "donald";
17049 static char p[] = "-p";
17050 static char billy[] = "billy";
17051 static char duck[] = "duck";
17052 static char a[] = "-a";
17053 static char bar[] = "bar";
17054 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17055 int c;
17056
17057 optind = OPTIND_MIN;
17058 opterr = 0;
17059
17060 c = getopt (7, argv, "+abp:q:");
17061 if (!(c == -1))
17062 return 4;
17063 if (!(strcmp (argv[0], "program") == 0))
17064 return 5;
17065 if (!(strcmp (argv[1], "donald") == 0))
17066 return 6;
17067 if (!(strcmp (argv[2], "-p") == 0))
17068 return 7;
17069 if (!(strcmp (argv[3], "billy") == 0))
17070 return 8;
17071 if (!(strcmp (argv[4], "duck") == 0))
17072 return 9;
17073 if (!(strcmp (argv[5], "-a") == 0))
17074 return 10;
17075 if (!(strcmp (argv[6], "bar") == 0))
17076 return 11;
17077 if (!(optind == 1))
17078 return 12;
17079 }
17080 /* Detect MacOS 10.5, AIX 7.1 bug. */
17081 {
17082 static char program[] = "program";
17083 static char ab[] = "-ab";
17084 char *argv[3] = { program, ab, NULL };
17085 optind = OPTIND_MIN;
17086 opterr = 0;
17087 if (getopt (2, argv, "ab:") != 'a')
17088 return 13;
17089 if (getopt (2, argv, "ab:") != '?')
17090 return 14;
17091 if (optopt != 'b')
17092 return 15;
17093 if (optind != 2)
17094 return 16;
17095 }
17096
17097 return 0;
17098}
17099
17100_ACEOF
17101if ac_fn_c_try_run "$LINENO"; then :
17102 gl_cv_func_getopt_posix=yes
17103else
17104 gl_cv_func_getopt_posix=no
17105fi
17106rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17107 conftest.$ac_objext conftest.beam conftest.$ac_ext
17108fi
17109
17110 CPPFLAGS=$gl_save_CPPFLAGS
17111
17112fi
17113{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17114$as_echo "$gl_cv_func_getopt_posix" >&6; }
17115 case "$gl_cv_func_getopt_posix" in
17116 *no) gl_replace_getopt=yes ;;
17117 esac
17118 fi
17119
17120 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17122$as_echo_n "checking for working GNU getopt function... " >&6; }
a9bec17c 17123if test "${gl_cv_func_getopt_gnu+set}" = set; then :
3e0be4ab
GM
17124 $as_echo_n "(cached) " >&6
17125else
17126 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17127 # optstring is necessary for programs like m4 that have POSIX-mandated
17128 # semantics for supporting options interspersed with files.
17129 # Also, since getopt_long is a GNU extension, we require optind=0.
17130 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17131 # so take care to revert to the correct (non-)export state.
17132 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17133 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17134 xx) gl_had_POSIXLY_CORRECT=exported ;;
17135 x) gl_had_POSIXLY_CORRECT=yes ;;
17136 *) gl_had_POSIXLY_CORRECT= ;;
17137 esac
17138 POSIXLY_CORRECT=1
17139 export POSIXLY_CORRECT
17140 if test "$cross_compiling" = yes; then :
17141 case $host_os:$ac_cv_have_decl_optreset in
17142 *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;;
17143 *:yes) gl_cv_func_getopt_gnu=no;;
17144 *) gl_cv_func_getopt_gnu=yes;;
17145 esac
17146
17147else
17148 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17149/* end confdefs.h. */
17150#include <getopt.h>
17151 #include <stddef.h>
17152 #include <string.h>
17153
369e19fc
PE
17154#include <stdlib.h>
17155#if defined __MACH__ && defined __APPLE__
17156/* Avoid a crash on MacOS X. */
17157#include <mach/mach.h>
17158#include <mach/mach_error.h>
17159#include <mach/thread_status.h>
17160#include <mach/exception.h>
17161#include <mach/task.h>
17162#include <pthread.h>
17163/* The exception port on which our thread listens. */
17164static mach_port_t our_exception_port;
17165/* The main function of the thread listening for exceptions of type
17166 EXC_BAD_ACCESS. */
17167static void *
17168mach_exception_thread (void *arg)
17169{
17170 /* Buffer for a message to be received. */
17171 struct {
17172 mach_msg_header_t head;
17173 mach_msg_body_t msgh_body;
17174 char data[1024];
17175 } msg;
17176 mach_msg_return_t retval;
17177 /* Wait for a message on the exception port. */
17178 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17179 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17180 if (retval != MACH_MSG_SUCCESS)
17181 abort ();
17182 exit (1);
17183}
17184static void
17185nocrash_init (void)
17186{
17187 mach_port_t self = mach_task_self ();
17188 /* Allocate a port on which the thread shall listen for exceptions. */
17189 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17190 == KERN_SUCCESS) {
17191 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17192 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17193 MACH_MSG_TYPE_MAKE_SEND)
17194 == KERN_SUCCESS) {
17195 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17196 for us. */
17197 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17198 /* Create the thread listening on the exception port. */
17199 pthread_attr_t attr;
17200 pthread_t thread;
17201 if (pthread_attr_init (&attr) == 0
17202 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17203 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17204 pthread_attr_destroy (&attr);
17205 /* Replace the exception port info for these exceptions with our own.
17206 Note that we replace the exception port for the entire task, not only
17207 for a particular thread. This has the effect that when our exception
17208 port gets the message, the thread specific exception port has already
17209 been asked, and we don't need to bother about it.
17210 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17211 task_set_exception_ports (self, mask, our_exception_port,
17212 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17213 }
17214 }
17215 }
17216}
b0415a03
GM
17217#elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17218/* Avoid a crash on native Windows. */
17219#define WIN32_LEAN_AND_MEAN
17220#include <windows.h>
17221#include <winerror.h>
17222static LONG WINAPI
17223exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17224{
17225 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17226 {
17227 case EXCEPTION_ACCESS_VIOLATION:
17228 case EXCEPTION_IN_PAGE_ERROR:
17229 case EXCEPTION_STACK_OVERFLOW:
17230 case EXCEPTION_GUARD_PAGE:
17231 case EXCEPTION_PRIV_INSTRUCTION:
17232 case EXCEPTION_ILLEGAL_INSTRUCTION:
17233 case EXCEPTION_DATATYPE_MISALIGNMENT:
17234 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17235 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17236 exit (1);
17237 }
17238 return EXCEPTION_CONTINUE_SEARCH;
17239}
17240static void
17241nocrash_init (void)
17242{
17243 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17244}
369e19fc
PE
17245#else
17246/* Avoid a crash on POSIX systems. */
17247#include <signal.h>
17248/* A POSIX signal handler. */
17249static void
17250exception_handler (int sig)
17251{
17252 exit (1);
17253}
17254static void
17255nocrash_init (void)
17256{
17257#ifdef SIGSEGV
17258 signal (SIGSEGV, exception_handler);
17259#endif
17260#ifdef SIGBUS
17261 signal (SIGBUS, exception_handler);
17262#endif
17263}
17264#endif
17265
17266
3e0be4ab
GM
17267int
17268main ()
17269{
17270
17271 int result = 0;
369e19fc
PE
17272
17273 nocrash_init();
17274
3e0be4ab
GM
17275 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17276 and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17277 OSF/1 5.1, Solaris 10. */
17278 {
17279 static char conftest[] = "conftest";
17280 static char plus[] = "-+";
17281 char *argv[3] = { conftest, plus, NULL };
17282 opterr = 0;
17283 if (getopt (2, argv, "+a") != '?')
17284 result |= 1;
17285 }
17286 /* This code succeeds on glibc 2.8, mingw,
17287 and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17288 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17289 {
17290 static char program[] = "program";
17291 static char p[] = "-p";
17292 static char foo[] = "foo";
17293 static char bar[] = "bar";
17294 char *argv[] = { program, p, foo, bar, NULL };
6ad6792b 17295
3e0be4ab
GM
17296 optind = 1;
17297 if (getopt (4, argv, "p::") != 'p')
17298 result |= 2;
17299 else if (optarg != NULL)
17300 result |= 4;
17301 else if (getopt (4, argv, "p::") != -1)
17302 result |= 6;
17303 else if (optind != 2)
17304 result |= 8;
17305 }
17306 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17307 {
17308 static char program[] = "program";
17309 static char foo[] = "foo";
17310 static char p[] = "-p";
17311 char *argv[] = { program, foo, p, NULL };
17312 optind = 0;
17313 if (getopt (3, argv, "-p") != 1)
17314 result |= 16;
17315 else if (getopt (3, argv, "-p") != 'p')
17316 result |= 32;
17317 }
17318 /* This code fails on glibc 2.11. */
17319 {
17320 static char program[] = "program";
17321 static char b[] = "-b";
17322 static char a[] = "-a";
17323 char *argv[] = { program, b, a, NULL };
17324 optind = opterr = 0;
17325 if (getopt (3, argv, "+:a:b") != 'b')
17326 result |= 64;
17327 else if (getopt (3, argv, "+:a:b") != ':')
17328 result |= 64;
17329 }
17330 /* This code dumps core on glibc 2.14. */
17331 {
17332 static char program[] = "program";
17333 static char w[] = "-W";
17334 static char dummy[] = "dummy";
17335 char *argv[] = { program, w, dummy, NULL };
17336 optind = opterr = 1;
17337 if (getopt (3, argv, "W;") != 'W')
17338 result |= 128;
17339 }
17340 return result;
6ad6792b 17341
3e0be4ab
GM
17342 ;
17343 return 0;
17344}
17345_ACEOF
17346if ac_fn_c_try_run "$LINENO"; then :
17347 gl_cv_func_getopt_gnu=yes
17348else
17349 gl_cv_func_getopt_gnu=no
17350fi
17351rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17352 conftest.$ac_objext conftest.beam conftest.$ac_ext
17353fi
e275c824 17354
3e0be4ab
GM
17355 case $gl_had_POSIXLY_CORRECT in
17356 exported) ;;
17357 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17358 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17359 esac
e275c824 17360
e275c824 17361fi
3e0be4ab
GM
17362{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17363$as_echo "$gl_cv_func_getopt_gnu" >&6; }
17364 if test "$gl_cv_func_getopt_gnu" = "no"; then
17365 gl_replace_getopt=yes
17366 fi
17367 fi
e275c824 17368
e275c824 17369
e275c824 17370
e275c824 17371
4fda9c95 17372
3e0be4ab 17373 REPLACE_GETOPT=0
5fa4ac76 17374
5fa4ac76 17375
3e0be4ab 17376 if test -n "$gl_replace_getopt"; then :
5fa4ac76 17377
3e0be4ab 17378 REPLACE_GETOPT=1
5fa4ac76 17379
3e0be4ab 17380fi
5fa4ac76 17381
5fa4ac76 17382
3e0be4ab 17383 if test $REPLACE_GETOPT = 1; then
5fa4ac76 17384
3e0be4ab 17385 GETOPT_H=getopt.h
5fa4ac76 17386
3e0be4ab 17387$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
5fa4ac76 17388
5fa4ac76
PE
17389
17390
3e0be4ab
GM
17391 GNULIB_UNISTD_H_GETOPT=1
17392 fi
5fa4ac76 17393
3e0be4ab 17394ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
a9bec17c 17395if test "x$ac_cv_have_decl_getenv" = x""yes; then :
3e0be4ab 17396 ac_have_decl=1
e275c824 17397else
3e0be4ab 17398 ac_have_decl=0
1f5d53eb 17399fi
1f5d53eb 17400
3e0be4ab
GM
17401cat >>confdefs.h <<_ACEOF
17402#define HAVE_DECL_GETENV $ac_have_decl
1f5d53eb 17403_ACEOF
1f5d53eb
PE
17404
17405
3e0be4ab
GM
17406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17407$as_echo_n "checking for unsigned long long int... " >&6; }
a9bec17c 17408if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
1f5d53eb 17409 $as_echo_n "(cached) " >&6
e275c824 17410else
3e0be4ab
GM
17411 ac_cv_type_unsigned_long_long_int=yes
17412 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d6974efa 17414/* end confdefs.h. */
1f5d53eb 17415
3e0be4ab
GM
17416 /* For now, do not test the preprocessor; as of 2007 there are too many
17417 implementations with broken preprocessors. Perhaps this can
17418 be revisited in 2012. In the meantime, code should not expect
17419 #if to work with literals wider than 32 bits. */
17420 /* Test literals. */
17421 long long int ll = 9223372036854775807ll;
17422 long long int nll = -9223372036854775807LL;
17423 unsigned long long int ull = 18446744073709551615ULL;
17424 /* Test constant expressions. */
17425 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17426 ? 1 : -1)];
17427 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17428 ? 1 : -1)];
17429 int i = 63;
d6974efa
PE
17430int
17431main ()
17432{
3e0be4ab
GM
17433/* Test availability of runtime routines for shift and division. */
17434 long long int llmax = 9223372036854775807ll;
17435 unsigned long long int ullmax = 18446744073709551615ull;
17436 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17437 | (llmax / ll) | (llmax % ll)
17438 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17439 | (ullmax / ull) | (ullmax % ull));
d6974efa
PE
17440 ;
17441 return 0;
17442}
3e0be4ab 17443
d6974efa 17444_ACEOF
3e0be4ab
GM
17445if ac_fn_c_try_link "$LINENO"; then :
17446
e275c824 17447else
3e0be4ab 17448 ac_cv_type_unsigned_long_long_int=no
e275c824 17449fi
3e0be4ab
GM
17450rm -f core conftest.err conftest.$ac_objext \
17451 conftest$ac_exeext conftest.$ac_ext
17452 fi
e275c824 17453fi
3e0be4ab
GM
17454{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17455$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17456 if test $ac_cv_type_unsigned_long_long_int = yes; then
e275c824 17457
3e0be4ab 17458$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
e275c824 17459
3e0be4ab
GM
17460 fi
17461
17462
17463
17464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17465$as_echo_n "checking for long long int... " >&6; }
a9bec17c 17466if test "${ac_cv_type_long_long_int+set}" = set; then :
e275c824 17467 $as_echo_n "(cached) " >&6
3e0be4ab
GM
17468else
17469 ac_cv_type_long_long_int=yes
17470 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17471 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17472 if test $ac_cv_type_long_long_int = yes; then
17473 if test "$cross_compiling" = yes; then :
17474 :
e275c824
PE
17475else
17476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17477/* end confdefs.h. */
3e0be4ab
GM
17478#include <limits.h>
17479 #ifndef LLONG_MAX
17480 # define HALF \
17481 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17482 # define LLONG_MAX (HALF - 1 + HALF)
17483 #endif
e275c824
PE
17484int
17485main ()
17486{
3e0be4ab
GM
17487long long int n = 1;
17488 int i;
17489 for (i = 0; ; i++)
17490 {
17491 long long int m = n << i;
17492 if (m >> i != n)
17493 return 1;
17494 if (LLONG_MAX / 2 < m)
17495 break;
17496 }
17497 return 0;
e275c824
PE
17498 ;
17499 return 0;
17500}
17501_ACEOF
3e0be4ab
GM
17502if ac_fn_c_try_run "$LINENO"; then :
17503
e275c824 17504else
3e0be4ab 17505 ac_cv_type_long_long_int=no
e275c824 17506fi
3e0be4ab
GM
17507rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17508 conftest.$ac_objext conftest.beam conftest.$ac_ext
e275c824 17509fi
e275c824 17510
3e0be4ab
GM
17511 fi
17512 fi
17513fi
17514{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17515$as_echo "$ac_cv_type_long_long_int" >&6; }
17516 if test $ac_cv_type_long_long_int = yes; then
e275c824 17517
3e0be4ab 17518$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
e275c824 17519
3e0be4ab 17520 fi
e275c824
PE
17521
17522
17523
17524
e275c824
PE
17525
17526
3e0be4ab
GM
17527 gl_cv_c_multiarch=no
17528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1f5d53eb 17529/* end confdefs.h. */
3e0be4ab
GM
17530#ifndef __APPLE_CC__
17531 not a universal capable compiler
17532 #endif
17533 typedef int dummy;
e275c824 17534
1f5d53eb 17535_ACEOF
3e0be4ab 17536if ac_fn_c_try_compile "$LINENO"; then :
e275c824 17537
3e0be4ab
GM
17538 arch=
17539 prev=
17540 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17541 if test -n "$prev"; then
17542 case $word in
17543 i?86 | x86_64 | ppc | ppc64)
17544 if test -z "$arch" || test "$arch" = "$word"; then
17545 arch="$word"
17546 else
17547 gl_cv_c_multiarch=yes
17548 fi
17549 ;;
17550 esac
17551 prev=
17552 else
17553 if test "x$word" = "x-arch"; then
17554 prev=arch
17555 fi
17556 fi
17557 done
e275c824 17558
1f5d53eb 17559fi
3e0be4ab
GM
17560rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17561 if test $gl_cv_c_multiarch = yes; then
17562 APPLE_UNIVERSAL_BUILD=1
17563 else
17564 APPLE_UNIVERSAL_BUILD=0
17565 fi
e275c824
PE
17566
17567
17568
17569
e275c824 17570
3e0be4ab
GM
17571 if test $ac_cv_type_long_long_int = yes; then
17572 HAVE_LONG_LONG_INT=1
17573 else
17574 HAVE_LONG_LONG_INT=0
17575 fi
e275c824
PE
17576
17577
3e0be4ab
GM
17578 if test $ac_cv_type_unsigned_long_long_int = yes; then
17579 HAVE_UNSIGNED_LONG_LONG_INT=1
17580 else
17581 HAVE_UNSIGNED_LONG_LONG_INT=0
17582 fi
e275c824
PE
17583
17584
17585
3e0be4ab
GM
17586 if test $ac_cv_header_wchar_h = yes; then
17587 HAVE_WCHAR_H=1
17588 else
17589 HAVE_WCHAR_H=0
17590 fi
e275c824
PE
17591
17592
3e0be4ab
GM
17593 if test $ac_cv_header_inttypes_h = yes; then
17594 HAVE_INTTYPES_H=1
17595 else
17596 HAVE_INTTYPES_H=0
17597 fi
67342916 17598
67342916 17599
3e0be4ab
GM
17600 if test $ac_cv_header_sys_types_h = yes; then
17601 HAVE_SYS_TYPES_H=1
17602 else
17603 HAVE_SYS_TYPES_H=0
17604 fi
67342916 17605
e275c824 17606
e275c824
PE
17607
17608
17609
17610
e275c824 17611
e275c824 17612
6c051bab 17613
942f733f 17614
4fc2b746 17615
3e0be4ab
GM
17616 if test $gl_cv_have_include_next = yes; then
17617 gl_cv_next_stdint_h='<'stdint.h'>'
17618 else
17619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17620$as_echo_n "checking absolute name of <stdint.h>... " >&6; }
a9bec17c 17621if test "${gl_cv_next_stdint_h+set}" = set; then :
4fc2b746
GM
17622 $as_echo_n "(cached) " >&6
17623else
17624
3e0be4ab 17625 if test $ac_cv_header_stdint_h = yes; then
4fc2b746
GM
17626
17627
3e0be4ab
GM
17628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17629/* end confdefs.h. */
17630#include <stdint.h>
4fc2b746 17631
3e0be4ab
GM
17632_ACEOF
17633 case "$host_os" in
17634 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17635 *) gl_absname_cpp="$ac_cpp" ;;
17636 esac
b0415a03
GM
17637
17638 case "$host_os" in
17639 mingw*)
17640 gl_dirsep_regex='[/\\]'
17641 ;;
17642 *)
17643 gl_dirsep_regex='/'
17644 ;;
17645 esac
17646
2b1928b8
GM
17647 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdint.h|{
17648 s|.*"\(.*'"${gl_dirsep_regex}"'stdint.h\)".*|\1|
17649 s|^/[^/]|//&|
b0415a03
GM
17650 p
17651 q
17652 }'
3e0be4ab 17653 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 17654 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
17655 else
17656 gl_cv_next_stdint_h='<'stdint.h'>'
17657 fi
4fc2b746 17658
4fc2b746 17659
4fc2b746 17660fi
3e0be4ab
GM
17661{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
17662$as_echo "$gl_cv_next_stdint_h" >&6; }
17663 fi
17664 NEXT_STDINT_H=$gl_cv_next_stdint_h
4fc2b746 17665
3e0be4ab
GM
17666 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17667 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17668 gl_next_as_first_directive='<'stdint.h'>'
17669 else
17670 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17671 gl_next_as_first_directive=$gl_cv_next_stdint_h
17672 fi
17673 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
4fc2b746
GM
17674
17675
17676
942f733f 17677
3e0be4ab
GM
17678 if test $ac_cv_header_stdint_h = yes; then
17679 HAVE_STDINT_H=1
17680 else
17681 HAVE_STDINT_H=0
17682 fi
e275c824 17683
5fa4ac76 17684
3e0be4ab
GM
17685 if test $ac_cv_header_stdint_h = yes; then
17686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
17687$as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
a9bec17c 17688if test "${gl_cv_header_working_stdint_h+set}" = set; then :
3e0be4ab
GM
17689 $as_echo_n "(cached) " >&6
17690else
17691 gl_cv_header_working_stdint_h=no
17692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17693/* end confdefs.h. */
5fa4ac76 17694
40e27e7f 17695
3e0be4ab
GM
17696#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
17697#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
17698#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17699#include <stdint.h>
17700/* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
17701#if !(defined WCHAR_MIN && defined WCHAR_MAX)
17702#error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
17703#endif
40e27e7f
GM
17704
17705
3e0be4ab
GM
17706 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17707 included before <wchar.h>. */
17708 #include <stddef.h>
17709 #include <signal.h>
17710 #if HAVE_WCHAR_H
17711 # include <stdio.h>
17712 # include <time.h>
17713 # include <wchar.h>
17714 #endif
40e27e7f
GM
17715
17716
3e0be4ab
GM
17717#ifdef INT8_MAX
17718int8_t a1 = INT8_MAX;
17719int8_t a1min = INT8_MIN;
17720#endif
17721#ifdef INT16_MAX
17722int16_t a2 = INT16_MAX;
17723int16_t a2min = INT16_MIN;
17724#endif
17725#ifdef INT32_MAX
17726int32_t a3 = INT32_MAX;
17727int32_t a3min = INT32_MIN;
17728#endif
17729#ifdef INT64_MAX
17730int64_t a4 = INT64_MAX;
17731int64_t a4min = INT64_MIN;
17732#endif
17733#ifdef UINT8_MAX
17734uint8_t b1 = UINT8_MAX;
17735#else
17736typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
17737#endif
17738#ifdef UINT16_MAX
17739uint16_t b2 = UINT16_MAX;
17740#endif
17741#ifdef UINT32_MAX
17742uint32_t b3 = UINT32_MAX;
17743#endif
17744#ifdef UINT64_MAX
17745uint64_t b4 = UINT64_MAX;
17746#endif
17747int_least8_t c1 = INT8_C (0x7f);
17748int_least8_t c1max = INT_LEAST8_MAX;
17749int_least8_t c1min = INT_LEAST8_MIN;
17750int_least16_t c2 = INT16_C (0x7fff);
17751int_least16_t c2max = INT_LEAST16_MAX;
17752int_least16_t c2min = INT_LEAST16_MIN;
17753int_least32_t c3 = INT32_C (0x7fffffff);
17754int_least32_t c3max = INT_LEAST32_MAX;
17755int_least32_t c3min = INT_LEAST32_MIN;
17756int_least64_t c4 = INT64_C (0x7fffffffffffffff);
17757int_least64_t c4max = INT_LEAST64_MAX;
17758int_least64_t c4min = INT_LEAST64_MIN;
17759uint_least8_t d1 = UINT8_C (0xff);
17760uint_least8_t d1max = UINT_LEAST8_MAX;
17761uint_least16_t d2 = UINT16_C (0xffff);
17762uint_least16_t d2max = UINT_LEAST16_MAX;
17763uint_least32_t d3 = UINT32_C (0xffffffff);
17764uint_least32_t d3max = UINT_LEAST32_MAX;
17765uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
17766uint_least64_t d4max = UINT_LEAST64_MAX;
17767int_fast8_t e1 = INT_FAST8_MAX;
17768int_fast8_t e1min = INT_FAST8_MIN;
17769int_fast16_t e2 = INT_FAST16_MAX;
17770int_fast16_t e2min = INT_FAST16_MIN;
17771int_fast32_t e3 = INT_FAST32_MAX;
17772int_fast32_t e3min = INT_FAST32_MIN;
17773int_fast64_t e4 = INT_FAST64_MAX;
17774int_fast64_t e4min = INT_FAST64_MIN;
17775uint_fast8_t f1 = UINT_FAST8_MAX;
17776uint_fast16_t f2 = UINT_FAST16_MAX;
17777uint_fast32_t f3 = UINT_FAST32_MAX;
17778uint_fast64_t f4 = UINT_FAST64_MAX;
17779#ifdef INTPTR_MAX
17780intptr_t g = INTPTR_MAX;
17781intptr_t gmin = INTPTR_MIN;
17782#endif
17783#ifdef UINTPTR_MAX
17784uintptr_t h = UINTPTR_MAX;
17785#endif
17786intmax_t i = INTMAX_MAX;
17787uintmax_t j = UINTMAX_MAX;
40e27e7f 17788
3e0be4ab
GM
17789#include <limits.h> /* for CHAR_BIT */
17790#define TYPE_MINIMUM(t) \
17791 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
17792#define TYPE_MAXIMUM(t) \
17793 ((t) ((t) 0 < (t) -1 \
17794 ? (t) -1 \
17795 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
17796struct s {
17797 int check_PTRDIFF:
17798 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
17799 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
17800 ? 1 : -1;
17801 /* Detect bug in FreeBSD 6.0 / ia64. */
17802 int check_SIG_ATOMIC:
17803 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
17804 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
17805 ? 1 : -1;
17806 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
17807 int check_WCHAR:
17808 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
17809 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
17810 ? 1 : -1;
17811 /* Detect bug in mingw. */
17812 int check_WINT:
17813 WINT_MIN == TYPE_MINIMUM (wint_t)
17814 && WINT_MAX == TYPE_MAXIMUM (wint_t)
17815 ? 1 : -1;
40e27e7f 17816
3e0be4ab
GM
17817 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
17818 int check_UINT8_C:
17819 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
17820 int check_UINT16_C:
17821 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
40e27e7f 17822
3e0be4ab
GM
17823 /* Detect bugs in OpenBSD 3.9 stdint.h. */
17824#ifdef UINT8_MAX
17825 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
17826#endif
17827#ifdef UINT16_MAX
17828 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
17829#endif
17830#ifdef UINT32_MAX
17831 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
17832#endif
17833#ifdef UINT64_MAX
17834 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
17835#endif
17836 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
17837 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
17838 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
17839 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
17840 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
17841 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
17842 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
17843 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
17844 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
17845 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
17846 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
17847};
d87ffdb7 17848
3e0be4ab
GM
17849int
17850main ()
17851{
d87ffdb7 17852
3e0be4ab
GM
17853 ;
17854 return 0;
17855}
17856_ACEOF
17857if ac_fn_c_try_compile "$LINENO"; then :
17858 if test "$cross_compiling" = yes; then :
17859 gl_cv_header_working_stdint_h=yes
d87ffdb7 17860
3e0be4ab
GM
17861else
17862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17863/* end confdefs.h. */
d87ffdb7
GM
17864
17865
3e0be4ab
GM
17866#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
17867#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
17868#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17869#include <stdint.h>
d87ffdb7
GM
17870
17871
3e0be4ab
GM
17872 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17873 included before <wchar.h>. */
17874 #include <stddef.h>
17875 #include <signal.h>
17876 #if HAVE_WCHAR_H
17877 # include <stdio.h>
17878 # include <time.h>
17879 # include <wchar.h>
17880 #endif
7d2a1c5e
GM
17881
17882
3e0be4ab
GM
17883#include <stdio.h>
17884#include <string.h>
17885#define MVAL(macro) MVAL1(macro)
17886#define MVAL1(expression) #expression
17887static const char *macro_values[] =
17888 {
17889#ifdef INT8_MAX
17890 MVAL (INT8_MAX),
17891#endif
17892#ifdef INT16_MAX
17893 MVAL (INT16_MAX),
17894#endif
17895#ifdef INT32_MAX
17896 MVAL (INT32_MAX),
17897#endif
17898#ifdef INT64_MAX
17899 MVAL (INT64_MAX),
17900#endif
17901#ifdef UINT8_MAX
17902 MVAL (UINT8_MAX),
17903#endif
17904#ifdef UINT16_MAX
17905 MVAL (UINT16_MAX),
17906#endif
17907#ifdef UINT32_MAX
17908 MVAL (UINT32_MAX),
17909#endif
17910#ifdef UINT64_MAX
17911 MVAL (UINT64_MAX),
17912#endif
17913 NULL
17914 };
7d2a1c5e 17915
7d2a1c5e
GM
17916int
17917main ()
17918{
3e0be4ab
GM
17919
17920 const char **mv;
17921 for (mv = macro_values; *mv != NULL; mv++)
17922 {
17923 const char *value = *mv;
17924 /* Test whether it looks like a cast expression. */
17925 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
17926 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
17927 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
17928 || strncmp (value, "((int)"/*)*/, 6) == 0
17929 || strncmp (value, "((signed short)"/*)*/, 15) == 0
17930 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
17931 return mv - macro_values + 1;
17932 }
17933 return 0;
7d2a1c5e
GM
17934
17935 ;
17936 return 0;
17937}
7d2a1c5e
GM
17938_ACEOF
17939if ac_fn_c_try_run "$LINENO"; then :
3e0be4ab 17940 gl_cv_header_working_stdint_h=yes
7d2a1c5e
GM
17941fi
17942rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17943 conftest.$ac_objext conftest.beam conftest.$ac_ext
17944fi
17945
17946
17947fi
3e0be4ab 17948rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7d2a1c5e 17949
3e0be4ab
GM
17950fi
17951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
17952$as_echo "$gl_cv_header_working_stdint_h" >&6; }
7d2a1c5e 17953 fi
3e0be4ab
GM
17954 if test "$gl_cv_header_working_stdint_h" = yes; then
17955 STDINT_H=
17956 else
17957 for ac_header in sys/inttypes.h sys/bitypes.h
17958do :
17959 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17960ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
a9bec17c
GM
17961eval as_val=\$$as_ac_Header
17962 if test "x$as_val" = x""yes; then :
3e0be4ab
GM
17963 cat >>confdefs.h <<_ACEOF
17964#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17965_ACEOF
7d2a1c5e 17966
3e0be4ab 17967fi
7d2a1c5e 17968
3e0be4ab 17969done
7d2a1c5e 17970
3e0be4ab
GM
17971 if test $ac_cv_header_sys_inttypes_h = yes; then
17972 HAVE_SYS_INTTYPES_H=1
17973 else
17974 HAVE_SYS_INTTYPES_H=0
7d2a1c5e 17975 fi
7d2a1c5e 17976
3e0be4ab
GM
17977 if test $ac_cv_header_sys_bitypes_h = yes; then
17978 HAVE_SYS_BITYPES_H=1
17979 else
17980 HAVE_SYS_BITYPES_H=0
17981 fi
7d2a1c5e
GM
17982
17983
17984
17985
3e0be4ab 17986 if test $APPLE_UNIVERSAL_BUILD = 0; then
7d2a1c5e
GM
17987
17988
3e0be4ab
GM
17989 for gltype in ptrdiff_t size_t ; do
17990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
17991$as_echo_n "checking for bit size of $gltype... " >&6; }
a9bec17c 17992if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
3e0be4ab
GM
17993 $as_echo_n "(cached) " >&6
17994else
17995 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
17996 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17997 included before <wchar.h>. */
17998 #include <stddef.h>
17999 #include <signal.h>
18000 #if HAVE_WCHAR_H
18001 # include <stdio.h>
18002 # include <time.h>
18003 # include <wchar.h>
18004 #endif
7d2a1c5e 18005
3e0be4ab 18006#include <limits.h>"; then :
7d2a1c5e 18007
3e0be4ab
GM
18008else
18009 result=unknown
18010fi
7d2a1c5e 18011
3e0be4ab 18012 eval gl_cv_bitsizeof_${gltype}=\$result
d87ffdb7 18013
3e0be4ab
GM
18014fi
18015eval ac_res=\$gl_cv_bitsizeof_${gltype}
18016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18017$as_echo "$ac_res" >&6; }
18018 eval result=\$gl_cv_bitsizeof_${gltype}
18019 if test $result = unknown; then
18020 result=0
18021 fi
18022 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18023 cat >>confdefs.h <<_ACEOF
18024#define BITSIZEOF_${GLTYPE} $result
18025_ACEOF
e275c824 18026
3e0be4ab
GM
18027 eval BITSIZEOF_${GLTYPE}=\$result
18028 done
e275c824 18029
e275c824 18030
3e0be4ab 18031 fi
e275c824 18032
1f5d53eb 18033
3e0be4ab
GM
18034 for gltype in sig_atomic_t wchar_t wint_t ; do
18035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18036$as_echo_n "checking for bit size of $gltype... " >&6; }
a9bec17c 18037if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
16c3e636
PE
18038 $as_echo_n "(cached) " >&6
18039else
3e0be4ab
GM
18040 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18041 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18042 included before <wchar.h>. */
18043 #include <stddef.h>
18044 #include <signal.h>
18045 #if HAVE_WCHAR_H
18046 # include <stdio.h>
18047 # include <time.h>
18048 # include <wchar.h>
18049 #endif
18050
18051#include <limits.h>"; then :
16c3e636 18052
1f5d53eb 18053else
3e0be4ab 18054 result=unknown
1f5d53eb
PE
18055fi
18056
3e0be4ab 18057 eval gl_cv_bitsizeof_${gltype}=\$result
16c3e636 18058
16c3e636 18059fi
3e0be4ab
GM
18060eval ac_res=\$gl_cv_bitsizeof_${gltype}
18061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18062$as_echo "$ac_res" >&6; }
18063 eval result=\$gl_cv_bitsizeof_${gltype}
18064 if test $result = unknown; then
18065 result=0
18066 fi
18067 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18068 cat >>confdefs.h <<_ACEOF
18069#define BITSIZEOF_${GLTYPE} $result
18070_ACEOF
16c3e636 18071
3e0be4ab
GM
18072 eval BITSIZEOF_${GLTYPE}=\$result
18073 done
1f5d53eb 18074
16c3e636
PE
18075
18076
3e0be4ab
GM
18077
18078 for gltype in sig_atomic_t wchar_t wint_t ; do
18079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18080$as_echo_n "checking whether $gltype is signed... " >&6; }
a9bec17c 18081if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
1fd182f0
PE
18082 $as_echo_n "(cached) " >&6
18083else
3e0be4ab 18084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 18085/* end confdefs.h. */
1f5d53eb 18086
3e0be4ab
GM
18087 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18088 included before <wchar.h>. */
18089 #include <stddef.h>
18090 #include <signal.h>
18091 #if HAVE_WCHAR_H
18092 # include <stdio.h>
18093 # include <time.h>
18094 # include <wchar.h>
18095 #endif
18096
18097 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
1fd182f0
PE
18098int
18099main ()
18100{
3e0be4ab 18101
1fd182f0
PE
18102 ;
18103 return 0;
18104}
18105_ACEOF
3e0be4ab
GM
18106if ac_fn_c_try_compile "$LINENO"; then :
18107 result=yes
1f5d53eb 18108else
3e0be4ab 18109 result=no
1f5d53eb 18110fi
3e0be4ab
GM
18111rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18112 eval gl_cv_type_${gltype}_signed=\$result
18113
1fd182f0 18114fi
3e0be4ab
GM
18115eval ac_res=\$gl_cv_type_${gltype}_signed
18116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18117$as_echo "$ac_res" >&6; }
18118 eval result=\$gl_cv_type_${gltype}_signed
18119 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18120 if test "$result" = yes; then
18121 cat >>confdefs.h <<_ACEOF
18122#define HAVE_SIGNED_${GLTYPE} 1
18123_ACEOF
1fd182f0 18124
3e0be4ab
GM
18125 eval HAVE_SIGNED_${GLTYPE}=1
18126 else
18127 eval HAVE_SIGNED_${GLTYPE}=0
18128 fi
18129 done
1fd182f0 18130
1f5d53eb 18131
3e0be4ab
GM
18132 gl_cv_type_ptrdiff_t_signed=yes
18133 gl_cv_type_size_t_signed=no
18134 if test $APPLE_UNIVERSAL_BUILD = 0; then
18135
18136
18137 for gltype in ptrdiff_t size_t ; do
18138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18139$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
a9bec17c 18140if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
1fd182f0
PE
18141 $as_echo_n "(cached) " >&6
18142else
3e0be4ab
GM
18143 eval gl_cv_type_${gltype}_suffix=no
18144 eval result=\$gl_cv_type_${gltype}_signed
18145 if test "$result" = yes; then
18146 glsufu=
18147 else
18148 glsufu=u
18149 fi
18150 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18151 case $glsuf in
18152 '') gltype1='int';;
18153 l) gltype1='long int';;
18154 ll) gltype1='long long int';;
18155 i64) gltype1='__int64';;
18156 u) gltype1='unsigned int';;
18157 ul) gltype1='unsigned long int';;
18158 ull) gltype1='unsigned long long int';;
18159 ui64)gltype1='unsigned __int64';;
18160 esac
18161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 18162/* end confdefs.h. */
1fd182f0 18163
3e0be4ab
GM
18164 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18165 included before <wchar.h>. */
18166 #include <stddef.h>
18167 #include <signal.h>
18168 #if HAVE_WCHAR_H
18169 # include <stdio.h>
18170 # include <time.h>
18171 # include <wchar.h>
18172 #endif
18173
18174 extern $gltype foo;
18175 extern $gltype1 foo;
1fd182f0
PE
18176int
18177main ()
18178{
3e0be4ab 18179
1fd182f0
PE
18180 ;
18181 return 0;
18182}
18183_ACEOF
3e0be4ab
GM
18184if ac_fn_c_try_compile "$LINENO"; then :
18185 eval gl_cv_type_${gltype}_suffix=\$glsuf
1fd182f0 18186fi
3e0be4ab
GM
18187rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18188 eval result=\$gl_cv_type_${gltype}_suffix
18189 test "$result" != no && break
18190 done
1fd182f0 18191fi
3e0be4ab
GM
18192eval ac_res=\$gl_cv_type_${gltype}_suffix
18193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18194$as_echo "$ac_res" >&6; }
18195 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18196 eval result=\$gl_cv_type_${gltype}_suffix
18197 test "$result" = no && result=
18198 eval ${GLTYPE}_SUFFIX=\$result
18199 cat >>confdefs.h <<_ACEOF
18200#define ${GLTYPE}_SUFFIX $result
1f5d53eb 18201_ACEOF
1fd182f0 18202
3e0be4ab 18203 done
1f5d53eb 18204
1f5d53eb 18205
3e0be4ab 18206 fi
1f5d53eb 18207
3e0be4ab
GM
18208
18209 for gltype in sig_atomic_t wchar_t wint_t ; do
18210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18211$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
a9bec17c 18212if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
1fd182f0
PE
18213 $as_echo_n "(cached) " >&6
18214else
3e0be4ab
GM
18215 eval gl_cv_type_${gltype}_suffix=no
18216 eval result=\$gl_cv_type_${gltype}_signed
18217 if test "$result" = yes; then
18218 glsufu=
18219 else
18220 glsufu=u
18221 fi
18222 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18223 case $glsuf in
18224 '') gltype1='int';;
18225 l) gltype1='long int';;
18226 ll) gltype1='long long int';;
18227 i64) gltype1='__int64';;
18228 u) gltype1='unsigned int';;
18229 ul) gltype1='unsigned long int';;
18230 ull) gltype1='unsigned long long int';;
18231 ui64)gltype1='unsigned __int64';;
18232 esac
18233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 18234/* end confdefs.h. */
1fd182f0 18235
3e0be4ab
GM
18236 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18237 included before <wchar.h>. */
18238 #include <stddef.h>
18239 #include <signal.h>
18240 #if HAVE_WCHAR_H
18241 # include <stdio.h>
18242 # include <time.h>
18243 # include <wchar.h>
18244 #endif
18245
18246 extern $gltype foo;
18247 extern $gltype1 foo;
1fd182f0
PE
18248int
18249main ()
18250{
3e0be4ab 18251
1fd182f0
PE
18252 ;
18253 return 0;
18254}
18255_ACEOF
3e0be4ab
GM
18256if ac_fn_c_try_compile "$LINENO"; then :
18257 eval gl_cv_type_${gltype}_suffix=\$glsuf
1fd182f0 18258fi
3e0be4ab
GM
18259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18260 eval result=\$gl_cv_type_${gltype}_suffix
18261 test "$result" != no && break
18262 done
1fd182f0 18263fi
3e0be4ab
GM
18264eval ac_res=\$gl_cv_type_${gltype}_suffix
18265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18266$as_echo "$ac_res" >&6; }
18267 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18268 eval result=\$gl_cv_type_${gltype}_suffix
18269 test "$result" = no && result=
18270 eval ${GLTYPE}_SUFFIX=\$result
18271 cat >>confdefs.h <<_ACEOF
18272#define ${GLTYPE}_SUFFIX $result
1f5d53eb
PE
18273_ACEOF
18274
3e0be4ab
GM
18275 done
18276
18277
18278
2b1928b8
GM
18279 if test $BITSIZEOF_WINT_T -lt 32; then
18280 BITSIZEOF_WINT_T=32
18281 fi
18282
3e0be4ab
GM
18283 STDINT_H=stdint.h
18284 fi
18285
18286 if test -n "$STDINT_H"; then
18287 GL_GENERATE_STDINT_H_TRUE=
18288 GL_GENERATE_STDINT_H_FALSE='#'
18289else
18290 GL_GENERATE_STDINT_H_TRUE='#'
18291 GL_GENERATE_STDINT_H_FALSE=
18292fi
18293
18294
18295
18296
18297
18298 GNULIB_IMAXABS=0;
18299 GNULIB_IMAXDIV=0;
18300 GNULIB_STRTOIMAX=0;
18301 GNULIB_STRTOUMAX=0;
18302 HAVE_DECL_IMAXABS=1;
18303 HAVE_DECL_IMAXDIV=1;
18304 HAVE_DECL_STRTOIMAX=1;
18305 HAVE_DECL_STRTOUMAX=1;
18306 INT32_MAX_LT_INTMAX_MAX=1;
18307 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18308 PRI_MACROS_BROKEN=0;
18309 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18310 UINT32_MAX_LT_UINTMAX_MAX=1;
18311 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18312
1f5d53eb 18313
1f5d53eb 18314
1f5d53eb 18315
1f5d53eb 18316
1f5d53eb 18317
1fd182f0 18318
1fd182f0
PE
18319
18320
18321
18322
18323
34119902
GM
18324
18325
3e0be4ab
GM
18326
18327 if test $gl_cv_have_include_next = yes; then
18328 gl_cv_next_inttypes_h='<'inttypes.h'>'
18329 else
18330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18331$as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
a9bec17c 18332if test "${gl_cv_next_inttypes_h+set}" = set; then :
3e0be4ab 18333 $as_echo_n "(cached) " >&6
34119902 18334else
34119902 18335
3e0be4ab
GM
18336 if test $ac_cv_header_inttypes_h = yes; then
18337
18338
18339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18340/* end confdefs.h. */
18341#include <inttypes.h>
34119902 18342
34119902 18343_ACEOF
3e0be4ab
GM
18344 case "$host_os" in
18345 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18346 *) gl_absname_cpp="$ac_cpp" ;;
18347 esac
b0415a03
GM
18348
18349 case "$host_os" in
18350 mingw*)
18351 gl_dirsep_regex='[/\\]'
18352 ;;
18353 *)
18354 gl_dirsep_regex='/'
18355 ;;
18356 esac
18357
2b1928b8
GM
18358 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'inttypes.h|{
18359 s|.*"\(.*'"${gl_dirsep_regex}"'inttypes.h\)".*|\1|
18360 s|^/[^/]|//&|
b0415a03
GM
18361 p
18362 q
18363 }'
3e0be4ab 18364 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 18365 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
18366 else
18367 gl_cv_next_inttypes_h='<'inttypes.h'>'
18368 fi
18369
34119902
GM
18370
18371fi
3e0be4ab
GM
18372{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18373$as_echo "$gl_cv_next_inttypes_h" >&6; }
18374 fi
18375 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
34119902 18376
3e0be4ab
GM
18377 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18378 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18379 gl_next_as_first_directive='<'inttypes.h'>'
18380 else
18381 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18382 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18383 fi
18384 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
34119902 18385
34119902 18386
34119902
GM
18387
18388
34119902
GM
18389
18390
18391
18392
3e0be4ab 18393$as_echo "#define GL_TRIGGER_STDC_LIMIT_MACROS 1" >>confdefs.h
34119902
GM
18394
18395
18396
18397
34119902
GM
18398
18399
3e0be4ab 18400 GNULIB_FCHMODAT=0;
2b1928b8 18401 GNULIB_FSTAT=0;
3e0be4ab
GM
18402 GNULIB_FSTATAT=0;
18403 GNULIB_FUTIMENS=0;
18404 GNULIB_LCHMOD=0;
18405 GNULIB_LSTAT=0;
18406 GNULIB_MKDIRAT=0;
18407 GNULIB_MKFIFO=0;
18408 GNULIB_MKFIFOAT=0;
18409 GNULIB_MKNOD=0;
18410 GNULIB_MKNODAT=0;
18411 GNULIB_STAT=0;
18412 GNULIB_UTIMENSAT=0;
18413 HAVE_FCHMODAT=1;
18414 HAVE_FSTATAT=1;
18415 HAVE_FUTIMENS=1;
18416 HAVE_LCHMOD=1;
18417 HAVE_LSTAT=1;
18418 HAVE_MKDIRAT=1;
18419 HAVE_MKFIFO=1;
18420 HAVE_MKFIFOAT=1;
18421 HAVE_MKNOD=1;
18422 HAVE_MKNODAT=1;
18423 HAVE_UTIMENSAT=1;
18424 REPLACE_FSTAT=0;
18425 REPLACE_FSTATAT=0;
18426 REPLACE_FUTIMENS=0;
18427 REPLACE_LSTAT=0;
18428 REPLACE_MKDIR=0;
18429 REPLACE_MKFIFO=0;
18430 REPLACE_MKNOD=0;
18431 REPLACE_STAT=0;
18432 REPLACE_UTIMENSAT=0;
34119902 18433
3e0be4ab
GM
18434
18435
18436
18437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18438$as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
a9bec17c 18439if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
3e0be4ab
GM
18440 $as_echo_n "(cached) " >&6
18441else
18442 rm -f conftest.sym conftest.file
18443 echo >conftest.file
18444 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18445 if test "$cross_compiling" = yes; then :
18446 # When cross-compiling, be pessimistic so we will end up using the
18447 # replacement version of lstat that checks for trailing slashes and
18448 # calls lstat a second time when necessary.
18449 gl_cv_func_lstat_dereferences_slashed_symlink=no
18450
18451else
18452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18453/* end confdefs.h. */
18454$ac_includes_default
18455int
18456main ()
18457{
18458struct stat sbuf;
18459 /* Linux will dereference the symlink and fail, as required by
18460 POSIX. That is better in the sense that it means we will not
18461 have to compile and use the lstat wrapper. */
18462 return lstat ("conftest.sym/", &sbuf) == 0;
18463
18464 ;
18465 return 0;
18466}
34119902 18467_ACEOF
3e0be4ab
GM
18468if ac_fn_c_try_run "$LINENO"; then :
18469 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18470else
18471 gl_cv_func_lstat_dereferences_slashed_symlink=no
34119902 18472fi
3e0be4ab
GM
18473rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18474 conftest.$ac_objext conftest.beam conftest.$ac_ext
18475fi
18476
18477 else
18478 # If the 'ln -s' command failed, then we probably don't even
18479 # have an lstat function.
18480 gl_cv_func_lstat_dereferences_slashed_symlink=no
18481 fi
18482 rm -f conftest.sym conftest.file
34119902 18483
1f5d53eb 18484fi
3e0be4ab
GM
18485{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18486$as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18487 test $gl_cv_func_lstat_dereferences_slashed_symlink = yes &&
18488
18489cat >>confdefs.h <<_ACEOF
18490#define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18491_ACEOF
18492
18493
18494
18495 GNULIB_MKTIME=0;
18496 GNULIB_NANOSLEEP=0;
18497 GNULIB_STRPTIME=0;
18498 GNULIB_TIMEGM=0;
18499 GNULIB_TIME_R=0;
18500 HAVE_DECL_LOCALTIME_R=1;
18501 HAVE_NANOSLEEP=1;
18502 HAVE_STRPTIME=1;
18503 HAVE_TIMEGM=1;
18504 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18505 REPLACE_MKTIME=GNULIB_PORTCHECK;
18506 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18507 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18508
18509
18510
1fd182f0
PE
18511
18512
18513
3e0be4ab 18514 GNULIB_PTHREAD_SIGMASK=0;
2b1928b8 18515 GNULIB_RAISE=0;
3e0be4ab
GM
18516 GNULIB_SIGNAL_H_SIGPIPE=0;
18517 GNULIB_SIGPROCMASK=0;
18518 GNULIB_SIGACTION=0;
18519 HAVE_POSIX_SIGNALBLOCKING=1;
18520 HAVE_PTHREAD_SIGMASK=1;
2b1928b8 18521 HAVE_RAISE=1;
3e0be4ab
GM
18522 HAVE_SIGSET_T=1;
18523 HAVE_SIGINFO_T=1;
18524 HAVE_SIGACTION=1;
18525 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
1fd182f0 18526
3e0be4ab 18527 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
1fd182f0 18528
3e0be4ab
GM
18529 HAVE_SIGHANDLER_T=1;
18530 REPLACE_PTHREAD_SIGMASK=0;
2b1928b8 18531 REPLACE_RAISE=0;
1fd182f0
PE
18532
18533
18534
b06b1098 18535
3e0be4ab
GM
18536 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
18537 #include <signal.h>
18538 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
18539 #include <sys/types.h>
b06b1098 18540
3e0be4ab 18541"
a9bec17c 18542if test "x$ac_cv_type_sigset_t" = x""yes; then :
1fd182f0 18543
3e0be4ab
GM
18544cat >>confdefs.h <<_ACEOF
18545#define HAVE_SIGSET_T 1
18546_ACEOF
1fd182f0 18547
3e0be4ab
GM
18548gl_cv_type_sigset_t=yes
18549else
18550 gl_cv_type_sigset_t=no
1f5d53eb 18551fi
b06b1098 18552
3e0be4ab
GM
18553 if test $gl_cv_type_sigset_t != yes; then
18554 HAVE_SIGSET_T=0
18555 fi
1fd182f0 18556
1fd182f0 18557
3e0be4ab
GM
18558
18559
18560
18561 if test $ac_cv_header_sys_socket_h = no; then
18562 for ac_header in ws2tcpip.h
1f5d53eb 18563do :
3e0be4ab 18564 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
a9bec17c 18565if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
1f5d53eb 18566 cat >>confdefs.h <<_ACEOF
3e0be4ab 18567#define HAVE_WS2TCPIP_H 1
1f5d53eb 18568_ACEOF
1fd182f0 18569
1f5d53eb 18570fi
1fd182f0 18571
1f5d53eb 18572done
1fd182f0 18573
3e0be4ab 18574 fi
1fd182f0 18575
3e0be4ab
GM
18576{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
18577$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
a9bec17c 18578if test "${ac_cv_header_stdbool_h+set}" = set; then :
3e0be4ab
GM
18579 $as_echo_n "(cached) " >&6
18580else
18581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18582/* end confdefs.h. */
18583
18584 #include <stdbool.h>
18585 #ifndef bool
18586 "error: bool is not defined"
18587 #endif
18588 #ifndef false
18589 "error: false is not defined"
18590 #endif
18591 #if false
18592 "error: false is not 0"
18593 #endif
18594 #ifndef true
18595 "error: true is not defined"
18596 #endif
18597 #if true != 1
18598 "error: true is not 1"
18599 #endif
18600 #ifndef __bool_true_false_are_defined
18601 "error: __bool_true_false_are_defined is not defined"
18602 #endif
18603
18604 struct s { _Bool s: 1; _Bool t; } s;
18605
18606 char a[true == 1 ? 1 : -1];
18607 char b[false == 0 ? 1 : -1];
18608 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
18609 char d[(bool) 0.5 == true ? 1 : -1];
18610 /* See body of main program for 'e'. */
18611 char f[(_Bool) 0.0 == false ? 1 : -1];
18612 char g[true];
18613 char h[sizeof (_Bool)];
18614 char i[sizeof s.t];
18615 enum { j = false, k = true, l = false * true, m = true * 256 };
18616 /* The following fails for
18617 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
18618 _Bool n[m];
18619 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
18620 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
18621 /* Catch a bug in an HP-UX C compiler. See
18622 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
18623 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
18624 */
18625 _Bool q = true;
18626 _Bool *pq = &q;
18627
18628int
18629main ()
18630{
18631
18632 bool e = &s;
18633 *pq |= q;
18634 *pq |= ! q;
18635 /* Refer to every declared value, to avoid compiler optimizations. */
18636 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
18637 + !m + !n + !o + !p + !q + !pq);
18638
18639 ;
18640 return 0;
18641}
1f5d53eb 18642_ACEOF
3e0be4ab
GM
18643if ac_fn_c_try_compile "$LINENO"; then :
18644 ac_cv_header_stdbool_h=yes
18645else
18646 ac_cv_header_stdbool_h=no
18647fi
18648rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18649fi
18650{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
18651$as_echo "$ac_cv_header_stdbool_h" >&6; }
18652 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
a9bec17c 18653if test "x$ac_cv_type__Bool" = x""yes; then :
1f5d53eb
PE
18654
18655cat >>confdefs.h <<_ACEOF
3e0be4ab 18656#define HAVE__BOOL 1
1f5d53eb 18657_ACEOF
1fd182f0 18658
b06b1098 18659
1fd182f0
PE
18660fi
18661
3e0be4ab
GM
18662
18663
18664 REPLACE_NULL=0;
18665 HAVE_WCHAR_T=1;
18666
18667
18668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
18669$as_echo_n "checking for wchar_t... " >&6; }
a9bec17c 18670if test "${gt_cv_c_wchar_t+set}" = set; then :
3e0be4ab
GM
18671 $as_echo_n "(cached) " >&6
18672else
18673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1f5d53eb 18674/* end confdefs.h. */
3e0be4ab
GM
18675#include <stddef.h>
18676 wchar_t foo = (wchar_t)'\0';
1f5d53eb
PE
18677int
18678main ()
18679{
3e0be4ab 18680
1f5d53eb
PE
18681 ;
18682 return 0;
18683}
1fd182f0 18684_ACEOF
3e0be4ab
GM
18685if ac_fn_c_try_compile "$LINENO"; then :
18686 gt_cv_c_wchar_t=yes
18687else
18688 gt_cv_c_wchar_t=no
18689fi
18690rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18691fi
18692{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
18693$as_echo "$gt_cv_c_wchar_t" >&6; }
18694 if test $gt_cv_c_wchar_t = yes; then
1f5d53eb 18695
3e0be4ab
GM
18696$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
18697
18698 fi
18699
18700
18701 GNULIB_DPRINTF=0;
18702 GNULIB_FCLOSE=0;
2b1928b8 18703 GNULIB_FDOPEN=0;
3e0be4ab
GM
18704 GNULIB_FFLUSH=0;
18705 GNULIB_FGETC=0;
18706 GNULIB_FGETS=0;
18707 GNULIB_FOPEN=0;
18708 GNULIB_FPRINTF=0;
18709 GNULIB_FPRINTF_POSIX=0;
18710 GNULIB_FPURGE=0;
18711 GNULIB_FPUTC=0;
18712 GNULIB_FPUTS=0;
18713 GNULIB_FREAD=0;
18714 GNULIB_FREOPEN=0;
18715 GNULIB_FSCANF=0;
18716 GNULIB_FSEEK=0;
18717 GNULIB_FSEEKO=0;
18718 GNULIB_FTELL=0;
18719 GNULIB_FTELLO=0;
18720 GNULIB_FWRITE=0;
18721 GNULIB_GETC=0;
18722 GNULIB_GETCHAR=0;
18723 GNULIB_GETDELIM=0;
18724 GNULIB_GETLINE=0;
18725 GNULIB_GETS=0;
18726 GNULIB_OBSTACK_PRINTF=0;
18727 GNULIB_OBSTACK_PRINTF_POSIX=0;
2b1928b8 18728 GNULIB_PCLOSE=0;
3e0be4ab
GM
18729 GNULIB_PERROR=0;
18730 GNULIB_POPEN=0;
18731 GNULIB_PRINTF=0;
18732 GNULIB_PRINTF_POSIX=0;
18733 GNULIB_PUTC=0;
18734 GNULIB_PUTCHAR=0;
18735 GNULIB_PUTS=0;
18736 GNULIB_REMOVE=0;
18737 GNULIB_RENAME=0;
18738 GNULIB_RENAMEAT=0;
18739 GNULIB_SCANF=0;
18740 GNULIB_SNPRINTF=0;
18741 GNULIB_SPRINTF_POSIX=0;
18742 GNULIB_STDIO_H_NONBLOCKING=0;
18743 GNULIB_STDIO_H_SIGPIPE=0;
18744 GNULIB_TMPFILE=0;
18745 GNULIB_VASPRINTF=0;
18746 GNULIB_VFSCANF=0;
18747 GNULIB_VSCANF=0;
18748 GNULIB_VDPRINTF=0;
18749 GNULIB_VFPRINTF=0;
18750 GNULIB_VFPRINTF_POSIX=0;
18751 GNULIB_VPRINTF=0;
18752 GNULIB_VPRINTF_POSIX=0;
18753 GNULIB_VSNPRINTF=0;
18754 GNULIB_VSPRINTF_POSIX=0;
18755 HAVE_DECL_FPURGE=1;
18756 HAVE_DECL_FSEEKO=1;
18757 HAVE_DECL_FTELLO=1;
18758 HAVE_DECL_GETDELIM=1;
18759 HAVE_DECL_GETLINE=1;
18760 HAVE_DECL_OBSTACK_PRINTF=1;
18761 HAVE_DECL_SNPRINTF=1;
18762 HAVE_DECL_VSNPRINTF=1;
18763 HAVE_DPRINTF=1;
18764 HAVE_FSEEKO=1;
18765 HAVE_FTELLO=1;
2b1928b8
GM
18766 HAVE_PCLOSE=1;
18767 HAVE_POPEN=1;
3e0be4ab
GM
18768 HAVE_RENAMEAT=1;
18769 HAVE_VASPRINTF=1;
18770 HAVE_VDPRINTF=1;
18771 REPLACE_DPRINTF=0;
18772 REPLACE_FCLOSE=0;
2b1928b8 18773 REPLACE_FDOPEN=0;
3e0be4ab
GM
18774 REPLACE_FFLUSH=0;
18775 REPLACE_FOPEN=0;
18776 REPLACE_FPRINTF=0;
18777 REPLACE_FPURGE=0;
18778 REPLACE_FREOPEN=0;
18779 REPLACE_FSEEK=0;
18780 REPLACE_FSEEKO=0;
18781 REPLACE_FTELL=0;
18782 REPLACE_FTELLO=0;
18783 REPLACE_GETDELIM=0;
18784 REPLACE_GETLINE=0;
18785 REPLACE_OBSTACK_PRINTF=0;
18786 REPLACE_PERROR=0;
18787 REPLACE_POPEN=0;
18788 REPLACE_PRINTF=0;
18789 REPLACE_REMOVE=0;
18790 REPLACE_RENAME=0;
18791 REPLACE_RENAMEAT=0;
18792 REPLACE_SNPRINTF=0;
18793 REPLACE_SPRINTF=0;
18794 REPLACE_STDIO_READ_FUNCS=0;
18795 REPLACE_STDIO_WRITE_FUNCS=0;
18796 REPLACE_TMPFILE=0;
18797 REPLACE_VASPRINTF=0;
18798 REPLACE_VDPRINTF=0;
18799 REPLACE_VFPRINTF=0;
18800 REPLACE_VPRINTF=0;
18801 REPLACE_VSNPRINTF=0;
18802 REPLACE_VSPRINTF=0;
1f5d53eb 18803
1ebc9c87
GM
18804{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
18805$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
18806if test "${ac_cv_struct_tm+set}" = set; then :
18807 $as_echo_n "(cached) " >&6
18808else
18809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18810/* end confdefs.h. */
18811#include <sys/types.h>
18812#include <time.h>
18813
18814int
18815main ()
18816{
18817struct tm tm;
18818 int *p = &tm.tm_sec;
18819 return !p;
18820 ;
18821 return 0;
18822}
18823_ACEOF
18824if ac_fn_c_try_compile "$LINENO"; then :
18825 ac_cv_struct_tm=time.h
18826else
18827 ac_cv_struct_tm=sys/time.h
18828fi
18829rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18830fi
18831{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
18832$as_echo "$ac_cv_struct_tm" >&6; }
18833if test $ac_cv_struct_tm = sys/time.h; then
18834
18835$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
18836
18837fi
18838
18839ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
18840#include <$ac_cv_struct_tm>
18841
18842"
18843if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
18844
18845cat >>confdefs.h <<_ACEOF
18846#define HAVE_STRUCT_TM_TM_ZONE 1
18847_ACEOF
18848
18849
18850fi
18851
18852if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
18853
18854$as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
18855
18856else
18857 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
18858"
18859if test "x$ac_cv_have_decl_tzname" = x""yes; then :
18860 ac_have_decl=1
18861else
18862 ac_have_decl=0
18863fi
18864
18865cat >>confdefs.h <<_ACEOF
18866#define HAVE_DECL_TZNAME $ac_have_decl
18867_ACEOF
18868
18869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
18870$as_echo_n "checking for tzname... " >&6; }
18871if test "${ac_cv_var_tzname+set}" = set; then :
18872 $as_echo_n "(cached) " >&6
18873else
18874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18875/* end confdefs.h. */
18876#include <time.h>
18877#if !HAVE_DECL_TZNAME
18878extern char *tzname[];
18879#endif
18880
18881int
18882main ()
18883{
18884return tzname[0][0];
18885 ;
18886 return 0;
18887}
18888_ACEOF
18889if ac_fn_c_try_link "$LINENO"; then :
18890 ac_cv_var_tzname=yes
18891else
18892 ac_cv_var_tzname=no
18893fi
18894rm -f core conftest.err conftest.$ac_objext \
18895 conftest$ac_exeext conftest.$ac_ext
18896fi
18897{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
18898$as_echo "$ac_cv_var_tzname" >&6; }
18899 if test $ac_cv_var_tzname = yes; then
18900
18901$as_echo "#define HAVE_TZNAME 1" >>confdefs.h
18902
18903 fi
18904fi
18905
1fd182f0 18906
3e0be4ab
GM
18907 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
18908"
a9bec17c 18909if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
1fd182f0 18910
3e0be4ab 18911$as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
1fd182f0 18912
1f5d53eb 18913fi
1fd182f0 18914
1f5d53eb 18915
1fd182f0 18916
1fd182f0 18917
369e19fc
PE
18918
18919
3e0be4ab 18920ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
a9bec17c 18921if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
3e0be4ab
GM
18922 ac_have_decl=1
18923else
18924 ac_have_decl=0
18925fi
1f5d53eb 18926
3e0be4ab
GM
18927cat >>confdefs.h <<_ACEOF
18928#define HAVE_DECL_STRTOIMAX $ac_have_decl
18929_ACEOF
cc322c06 18930
369e19fc
PE
18931
18932
3e0be4ab 18933ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
a9bec17c 18934if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
3e0be4ab
GM
18935 ac_have_decl=1
18936else
18937 ac_have_decl=0
18938fi
cc322c06 18939
3e0be4ab
GM
18940cat >>confdefs.h <<_ACEOF
18941#define HAVE_DECL_STRTOUMAX $ac_have_decl
18942_ACEOF
cc322c06
GM
18943
18944
1f5d53eb 18945
3e0be4ab
GM
18946{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
18947$as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
a9bec17c 18948if test "${ac_cv_header_stat_broken+set}" = set; then :
3e0be4ab
GM
18949 $as_echo_n "(cached) " >&6
18950else
18951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18952/* end confdefs.h. */
18953#include <sys/types.h>
18954#include <sys/stat.h>
1f5d53eb 18955
3e0be4ab
GM
18956#if defined S_ISBLK && defined S_IFDIR
18957extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
18958#endif
1fd182f0 18959
3e0be4ab
GM
18960#if defined S_ISBLK && defined S_IFCHR
18961extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
18962#endif
e275c824 18963
3e0be4ab
GM
18964#if defined S_ISLNK && defined S_IFREG
18965extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
18966#endif
e275c824 18967
3e0be4ab
GM
18968#if defined S_ISSOCK && defined S_IFREG
18969extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
18970#endif
e275c824 18971
3e0be4ab
GM
18972_ACEOF
18973if ac_fn_c_try_compile "$LINENO"; then :
18974 ac_cv_header_stat_broken=no
18975else
18976 ac_cv_header_stat_broken=yes
18977fi
18978rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18979fi
18980{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
18981$as_echo "$ac_cv_header_stat_broken" >&6; }
18982if test $ac_cv_header_stat_broken = yes; then
e275c824 18983
3e0be4ab 18984$as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
e275c824 18985
3e0be4ab 18986fi
e275c824 18987
e275c824
PE
18988
18989
2b1928b8
GM
18990ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18991if test "x$ac_cv_type_mode_t" = x""yes; then :
18992
18993else
18994
18995cat >>confdefs.h <<_ACEOF
18996#define mode_t int
18997_ACEOF
18998
18999fi
19000
3e0be4ab
GM
19001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19002$as_echo_n "checking for C/C++ restrict keyword... " >&6; }
a9bec17c 19003if test "${ac_cv_c_restrict+set}" = set; then :
3e0be4ab
GM
19004 $as_echo_n "(cached) " >&6
19005else
19006 ac_cv_c_restrict=no
19007 # The order here caters to the fact that C++ does not require restrict.
19008 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19010/* end confdefs.h. */
19011typedef int * int_ptr;
19012 int foo (int_ptr $ac_kw ip) {
19013 return ip[0];
19014 }
19015int
19016main ()
19017{
19018int s[1];
19019 int * $ac_kw t = s;
19020 t[0] = 0;
19021 return foo(t)
19022 ;
19023 return 0;
19024}
19025_ACEOF
19026if ac_fn_c_try_compile "$LINENO"; then :
19027 ac_cv_c_restrict=$ac_kw
19028fi
19029rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19030 test "$ac_cv_c_restrict" != no && break
19031 done
e275c824 19032
3e0be4ab
GM
19033fi
19034{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19035$as_echo "$ac_cv_c_restrict" >&6; }
e275c824 19036
3e0be4ab
GM
19037 case $ac_cv_c_restrict in
19038 restrict) ;;
19039 no) $as_echo "#define restrict /**/" >>confdefs.h
19040 ;;
19041 *) cat >>confdefs.h <<_ACEOF
19042#define restrict $ac_cv_c_restrict
19043_ACEOF
19044 ;;
19045 esac
e275c824 19046
52724a05 19047
52724a05
GM
19048
19049
19050
3e0be4ab
GM
19051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19052$as_echo_n "checking for struct timespec in <time.h>... " >&6; }
a9bec17c 19053if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
3e0be4ab
GM
19054 $as_echo_n "(cached) " >&6
19055else
19056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19057/* end confdefs.h. */
19058#include <time.h>
52724a05 19059
3e0be4ab
GM
19060int
19061main ()
19062{
19063static struct timespec x; x.tv_sec = x.tv_nsec;
19064 ;
19065 return 0;
19066}
19067_ACEOF
19068if ac_fn_c_try_compile "$LINENO"; then :
19069 gl_cv_sys_struct_timespec_in_time_h=yes
19070else
19071 gl_cv_sys_struct_timespec_in_time_h=no
52724a05 19072fi
3e0be4ab
GM
19073rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19074fi
19075{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19076$as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
52724a05 19077
3e0be4ab
GM
19078 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19079 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19080 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19081 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19082 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19083 else
19084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19085$as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
a9bec17c 19086if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
3e0be4ab
GM
19087 $as_echo_n "(cached) " >&6
19088else
19089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19090/* end confdefs.h. */
19091#include <sys/time.h>
52724a05 19092
3e0be4ab
GM
19093int
19094main ()
19095{
19096static struct timespec x; x.tv_sec = x.tv_nsec;
19097 ;
19098 return 0;
19099}
19100_ACEOF
19101if ac_fn_c_try_compile "$LINENO"; then :
19102 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19103else
19104 gl_cv_sys_struct_timespec_in_sys_time_h=no
19105fi
19106rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19107fi
19108{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19109$as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19110 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19111 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19112 else
19113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19114$as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
a9bec17c 19115if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
3e0be4ab
GM
19116 $as_echo_n "(cached) " >&6
19117else
19118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19119/* end confdefs.h. */
19120#include <pthread.h>
52724a05 19121
3e0be4ab
GM
19122int
19123main ()
19124{
19125static struct timespec x; x.tv_sec = x.tv_nsec;
19126 ;
19127 return 0;
19128}
19129_ACEOF
19130if ac_fn_c_try_compile "$LINENO"; then :
19131 gl_cv_sys_struct_timespec_in_pthread_h=yes
19132else
19133 gl_cv_sys_struct_timespec_in_pthread_h=no
19134fi
19135rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19136fi
19137{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19138$as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19139 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19140 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19141 fi
19142 fi
19143 fi
52724a05
GM
19144
19145
52724a05 19146
e275c824
PE
19147
19148
e275c824 19149
e275c824
PE
19150
19151
19152
52724a05 19153
e275c824
PE
19154
19155
19156
19157
19158
3e0be4ab
GM
19159 if test $gl_cv_have_include_next = yes; then
19160 gl_cv_next_time_h='<'time.h'>'
19161 else
19162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19163$as_echo_n "checking absolute name of <time.h>... " >&6; }
a9bec17c 19164if test "${gl_cv_next_time_h+set}" = set; then :
3e0be4ab
GM
19165 $as_echo_n "(cached) " >&6
19166else
e275c824 19167
3e0be4ab
GM
19168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19169/* end confdefs.h. */
19170#include <time.h>
e275c824 19171
3e0be4ab
GM
19172_ACEOF
19173 case "$host_os" in
19174 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19175 *) gl_absname_cpp="$ac_cpp" ;;
19176 esac
b0415a03
GM
19177
19178 case "$host_os" in
19179 mingw*)
19180 gl_dirsep_regex='[/\\]'
19181 ;;
19182 *)
19183 gl_dirsep_regex='/'
19184 ;;
19185 esac
19186
2b1928b8
GM
19187 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'time.h|{
19188 s|.*"\(.*'"${gl_dirsep_regex}"'time.h\)".*|\1|
19189 s|^/[^/]|//&|
b0415a03
GM
19190 p
19191 q
19192 }'
3e0be4ab 19193 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 19194 sed -n "$gl_absolute_header_sed"`'"'
e275c824 19195
e275c824 19196
3e0be4ab
GM
19197fi
19198{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19199$as_echo "$gl_cv_next_time_h" >&6; }
19200 fi
19201 NEXT_TIME_H=$gl_cv_next_time_h
e275c824 19202
3e0be4ab
GM
19203 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19204 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19205 gl_next_as_first_directive='<'time.h'>'
19206 else
19207 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19208 gl_next_as_first_directive=$gl_cv_next_time_h
19209 fi
19210 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
e275c824
PE
19211
19212
19213
19214
19215
19216
3e0be4ab 19217ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "$ac_includes_default"
a9bec17c 19218if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
3e0be4ab
GM
19219 ac_have_decl=1
19220else
19221 ac_have_decl=0
19222fi
e275c824 19223
3e0be4ab
GM
19224cat >>confdefs.h <<_ACEOF
19225#define HAVE_DECL_LOCALTIME_R $ac_have_decl
19226_ACEOF
e275c824
PE
19227
19228
19229
19230
3e0be4ab
GM
19231 if false; then
19232 GL_COND_LIBTOOL_TRUE=
19233 GL_COND_LIBTOOL_FALSE='#'
19234else
19235 GL_COND_LIBTOOL_TRUE='#'
19236 GL_COND_LIBTOOL_FALSE=
e275c824
PE
19237fi
19238
3e0be4ab
GM
19239 gl_cond_libtool=false
19240 gl_libdeps=
19241 gl_ltlibdeps=
19242 gl_m4_base='m4'
e275c824 19243
67342916 19244
4fda9c95
GM
19245
19246
52724a05
GM
19247
19248
19249
19250
19251
3e0be4ab 19252 gl_source_base='lib'
52724a05
GM
19253
19254
3e0be4ab
GM
19255 if test $ac_cv_func_alloca_works = no; then
19256 :
19257 fi
52724a05 19258
3e0be4ab
GM
19259 # Define an additional variable used in the Makefile substitution.
19260 if test $ac_cv_working_alloca_h = yes; then
19261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
19262$as_echo_n "checking for alloca as a compiler built-in... " >&6; }
a9bec17c 19263if test "${gl_cv_rpl_alloca+set}" = set; then :
3e0be4ab
GM
19264 $as_echo_n "(cached) " >&6
19265else
52724a05 19266
3e0be4ab
GM
19267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19268/* end confdefs.h. */
52724a05 19269
3e0be4ab
GM
19270#if defined __GNUC__ || defined _AIX || defined _MSC_VER
19271 Need own alloca
19272#endif
52724a05 19273
3e0be4ab
GM
19274_ACEOF
19275if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19276 $EGREP "Need own alloca" >/dev/null 2>&1; then :
19277 gl_cv_rpl_alloca=yes
19278else
19279 gl_cv_rpl_alloca=no
52724a05 19280fi
3e0be4ab 19281rm -f conftest*
ae0d7250
PE
19282
19283
3e0be4ab
GM
19284fi
19285{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
19286$as_echo "$gl_cv_rpl_alloca" >&6; }
19287 if test $gl_cv_rpl_alloca = yes; then
ae0d7250 19288
3e0be4ab 19289$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
cc322c06 19290
3e0be4ab
GM
19291 ALLOCA_H=alloca.h
19292 else
19293 ALLOCA_H=
19294 fi
19295 else
19296 ALLOCA_H=alloca.h
19297 fi
cc322c06 19298
3e0be4ab
GM
19299 if test -n "$ALLOCA_H"; then
19300 GL_GENERATE_ALLOCA_H_TRUE=
19301 GL_GENERATE_ALLOCA_H_FALSE='#'
19302else
19303 GL_GENERATE_ALLOCA_H_TRUE='#'
19304 GL_GENERATE_ALLOCA_H_FALSE=
19305fi
1fd182f0
PE
19306
19307
19308
19309
19310
52724a05 19311
3e0be4ab 19312 :
1fd182f0 19313
1fd182f0 19314
1fd182f0 19315
1fd182f0 19316
3e0be4ab 19317 :
1fd182f0 19318
1fd182f0 19319
1fd182f0 19320
1fd182f0 19321
1fd182f0 19322
1fd182f0 19323
1fd182f0 19324
1fd182f0 19325
1fd182f0 19326
1fd182f0 19327
1fd182f0 19328
1fd182f0 19329
1fd182f0 19330
1fd182f0 19331
1fd182f0 19332
3e0be4ab 19333$as_echo "#define HAVE_DUP2 1" >>confdefs.h
1fd182f0 19334
1fd182f0 19335
3e0be4ab
GM
19336 if test $HAVE_DUP2 = 1; then
19337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
19338$as_echo_n "checking whether dup2 works... " >&6; }
a9bec17c 19339if test "${gl_cv_func_dup2_works+set}" = set; then :
3e0be4ab
GM
19340 $as_echo_n "(cached) " >&6
19341else
19342 if test "$cross_compiling" = yes; then :
19343 case "$host_os" in
19344 mingw*) # on this platform, dup2 always returns 0 for success
19345 gl_cv_func_dup2_works=no;;
19346 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
19347 gl_cv_func_dup2_works=no;;
19348 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
19349 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
19350 gl_cv_func_dup2_works=no;;
19351 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
19352 gl_cv_func_dup2_works=no;;
19353 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
19354 gl_cv_func_dup2_works=no;;
19355 *) gl_cv_func_dup2_works=yes;;
19356 esac
19357else
19358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19359/* end confdefs.h. */
1fd182f0 19360
3e0be4ab
GM
19361 #include <unistd.h>
19362#include <fcntl.h>
19363#include <errno.h>
19364int
19365main ()
19366{
19367int result = 0;
19368#ifdef FD_CLOEXEC
19369 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
19370 result |= 1;
19371#endif
19372 if (dup2 (1, 1) == 0)
19373 result |= 2;
19374#ifdef FD_CLOEXEC
19375 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
19376 result |= 4;
19377#endif
19378 close (0);
19379 if (dup2 (0, 0) != -1)
19380 result |= 8;
19381 /* Many gnulib modules require POSIX conformance of EBADF. */
19382 if (dup2 (2, 1000000) == -1 && errno != EBADF)
19383 result |= 16;
19384 return result;
1fd182f0 19385
3e0be4ab
GM
19386 ;
19387 return 0;
1fd182f0 19388}
3e0be4ab 19389
1fd182f0
PE
19390_ACEOF
19391if ac_fn_c_try_run "$LINENO"; then :
3e0be4ab 19392 gl_cv_func_dup2_works=yes
1fd182f0 19393else
3e0be4ab 19394 gl_cv_func_dup2_works=no
1fd182f0
PE
19395fi
19396rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19397 conftest.$ac_objext conftest.beam conftest.$ac_ext
067d23c9 19398fi
067d23c9 19399
067d23c9 19400
1fd182f0 19401fi
3e0be4ab
GM
19402{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
19403$as_echo "$gl_cv_func_dup2_works" >&6; }
19404 if test "$gl_cv_func_dup2_works" = no; then
369e19fc
PE
19405 REPLACE_DUP2=1
19406 fi
1fd182f0 19407 fi
067d23c9
KY
19408
19409
369e19fc 19410if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
067d23c9 19411
067d23c9 19412
cc322c06
GM
19413
19414
cc322c06
GM
19415
19416
067d23c9
KY
19417
19418
369e19fc 19419 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
067d23c9 19420
2b1928b8 19421
369e19fc 19422fi
067d23c9 19423
ae0d7250 19424
52724a05 19425
ae0d7250
PE
19426
19427
3e0be4ab 19428 GNULIB_DUP2=1
ae0d7250
PE
19429
19430
19431
19432
19433
19434
19435
19436
ae0d7250
PE
19437
19438
ae0d7250 19439
3e0be4ab
GM
19440# Persuade glibc <stdlib.h> to declare getloadavg().
19441
19442
19443gl_save_LIBS=$LIBS
19444
19445# getloadvg is present in libc on glibc >= 2.2, MacOS X, FreeBSD >= 2.0,
19446# NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
19447HAVE_GETLOADAVG=1
19448ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
a9bec17c 19449if test "x$ac_cv_func_getloadavg" = x""yes; then :
3e0be4ab
GM
19450
19451else
19452 gl_func_getloadavg_done=no
19453
19454 # Some systems with -lutil have (and need) -lkvm as well, some do not.
19455 # On Solaris, -lkvm requires nlist from -lelf, so check that first
19456 # to get the right answer into the cache.
19457 # For kstat on solaris, we need to test for libelf and libkvm to force the
19458 # definition of SVR4 below.
19459 if test $gl_func_getloadavg_done = no; then
19460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
19461$as_echo_n "checking for elf_begin in -lelf... " >&6; }
a9bec17c 19462if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
ae0d7250
PE
19463 $as_echo_n "(cached) " >&6
19464else
3e0be4ab
GM
19465 ac_check_lib_save_LIBS=$LIBS
19466LIBS="-lelf $LIBS"
19467cat confdefs.h - <<_ACEOF >conftest.$ac_ext
ae0d7250 19468/* end confdefs.h. */
3e0be4ab
GM
19469
19470/* Override any GCC internal prototype to avoid an error.
19471 Use char because int might match the return type of a GCC
19472 builtin and then its argument prototype would still apply. */
19473#ifdef __cplusplus
19474extern "C"
19475#endif
19476char elf_begin ();
ae0d7250
PE
19477int
19478main ()
19479{
3e0be4ab
GM
19480return elf_begin ();
19481 ;
19482 return 0;
19483}
19484_ACEOF
19485if ac_fn_c_try_link "$LINENO"; then :
19486 ac_cv_lib_elf_elf_begin=yes
19487else
19488 ac_cv_lib_elf_elf_begin=no
19489fi
19490rm -f core conftest.err conftest.$ac_objext \
19491 conftest$ac_exeext conftest.$ac_ext
19492LIBS=$ac_check_lib_save_LIBS
19493fi
19494{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
19495$as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
a9bec17c 19496if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
3e0be4ab
GM
19497 LIBS="-lelf $LIBS"
19498fi
19499
19500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
19501$as_echo_n "checking for kvm_open in -lkvm... " >&6; }
a9bec17c 19502if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
3e0be4ab
GM
19503 $as_echo_n "(cached) " >&6
19504else
19505 ac_check_lib_save_LIBS=$LIBS
19506LIBS="-lkvm $LIBS"
19507cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19508/* end confdefs.h. */
ae0d7250 19509
3e0be4ab
GM
19510/* Override any GCC internal prototype to avoid an error.
19511 Use char because int might match the return type of a GCC
19512 builtin and then its argument prototype would still apply. */
19513#ifdef __cplusplus
19514extern "C"
19515#endif
19516char kvm_open ();
19517int
19518main ()
19519{
19520return kvm_open ();
ae0d7250
PE
19521 ;
19522 return 0;
19523}
19524_ACEOF
3e0be4ab
GM
19525if ac_fn_c_try_link "$LINENO"; then :
19526 ac_cv_lib_kvm_kvm_open=yes
ae0d7250 19527else
3e0be4ab 19528 ac_cv_lib_kvm_kvm_open=no
ae0d7250 19529fi
3e0be4ab
GM
19530rm -f core conftest.err conftest.$ac_objext \
19531 conftest$ac_exeext conftest.$ac_ext
19532LIBS=$ac_check_lib_save_LIBS
ae0d7250 19533fi
3e0be4ab
GM
19534{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
19535$as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
a9bec17c 19536if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
3e0be4ab
GM
19537 LIBS="-lkvm $LIBS"
19538fi
19539
19540 # Check for the 4.4BSD definition of getloadavg.
19541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
19542$as_echo_n "checking for getloadavg in -lutil... " >&6; }
a9bec17c 19543if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
ae0d7250
PE
19544 $as_echo_n "(cached) " >&6
19545else
3e0be4ab
GM
19546 ac_check_lib_save_LIBS=$LIBS
19547LIBS="-lutil $LIBS"
19548cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19549/* end confdefs.h. */
19550
19551/* Override any GCC internal prototype to avoid an error.
19552 Use char because int might match the return type of a GCC
19553 builtin and then its argument prototype would still apply. */
19554#ifdef __cplusplus
19555extern "C"
19556#endif
19557char getloadavg ();
19558int
19559main ()
19560{
19561return getloadavg ();
19562 ;
19563 return 0;
19564}
19565_ACEOF
19566if ac_fn_c_try_link "$LINENO"; then :
19567 ac_cv_lib_util_getloadavg=yes
ae0d7250 19568else
3e0be4ab
GM
19569 ac_cv_lib_util_getloadavg=no
19570fi
19571rm -f core conftest.err conftest.$ac_objext \
19572 conftest$ac_exeext conftest.$ac_ext
19573LIBS=$ac_check_lib_save_LIBS
19574fi
19575{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
19576$as_echo "$ac_cv_lib_util_getloadavg" >&6; }
a9bec17c 19577if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
3e0be4ab
GM
19578 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
19579fi
19580
19581 fi
19582
19583 if test $gl_func_getloadavg_done = no; then
19584 # There is a commonly available library for RS/6000 AIX.
19585 # Since it is not a standard part of AIX, it might be installed locally.
19586 gl_getloadavg_LIBS=$LIBS
19587 LIBS="-L/usr/local/lib $LIBS"
19588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
19589$as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
a9bec17c 19590if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
3e0be4ab
GM
19591 $as_echo_n "(cached) " >&6
19592else
19593 ac_check_lib_save_LIBS=$LIBS
19594LIBS="-lgetloadavg $LIBS"
19595cat confdefs.h - <<_ACEOF >conftest.$ac_ext
ae0d7250 19596/* end confdefs.h. */
ae0d7250 19597
3e0be4ab
GM
19598/* Override any GCC internal prototype to avoid an error.
19599 Use char because int might match the return type of a GCC
19600 builtin and then its argument prototype would still apply. */
19601#ifdef __cplusplus
19602extern "C"
19603#endif
19604char getloadavg ();
ae0d7250
PE
19605int
19606main ()
19607{
3e0be4ab 19608return getloadavg ();
ae0d7250
PE
19609 ;
19610 return 0;
19611}
19612_ACEOF
3e0be4ab
GM
19613if ac_fn_c_try_link "$LINENO"; then :
19614 ac_cv_lib_getloadavg_getloadavg=yes
ae0d7250 19615else
3e0be4ab 19616 ac_cv_lib_getloadavg_getloadavg=no
ae0d7250 19617fi
3e0be4ab
GM
19618rm -f core conftest.err conftest.$ac_objext \
19619 conftest$ac_exeext conftest.$ac_ext
19620LIBS=$ac_check_lib_save_LIBS
ae0d7250 19621fi
3e0be4ab
GM
19622{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
19623$as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
a9bec17c 19624if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
3e0be4ab
GM
19625 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
19626else
19627 LIBS=$gl_getloadavg_LIBS
52724a05 19628fi
ae0d7250 19629
3e0be4ab 19630 fi
ae0d7250 19631
3e0be4ab
GM
19632 # Set up the replacement function if necessary.
19633 if test $gl_func_getloadavg_done = no; then
19634 HAVE_GETLOADAVG=0
ae0d7250 19635
3e0be4ab
GM
19636 # Solaris has libkstat which does not require root.
19637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
19638$as_echo_n "checking for kstat_open in -lkstat... " >&6; }
a9bec17c 19639if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
6ad6792b
GM
19640 $as_echo_n "(cached) " >&6
19641else
3e0be4ab
GM
19642 ac_check_lib_save_LIBS=$LIBS
19643LIBS="-lkstat $LIBS"
19644cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6ad6792b 19645/* end confdefs.h. */
6ad6792b 19646
3e0be4ab
GM
19647/* Override any GCC internal prototype to avoid an error.
19648 Use char because int might match the return type of a GCC
19649 builtin and then its argument prototype would still apply. */
19650#ifdef __cplusplus
19651extern "C"
19652#endif
19653char kstat_open ();
6ad6792b
GM
19654int
19655main ()
19656{
3e0be4ab 19657return kstat_open ();
6ad6792b
GM
19658 ;
19659 return 0;
19660}
19661_ACEOF
3e0be4ab
GM
19662if ac_fn_c_try_link "$LINENO"; then :
19663 ac_cv_lib_kstat_kstat_open=yes
19664else
19665 ac_cv_lib_kstat_kstat_open=no
6ad6792b 19666fi
3e0be4ab
GM
19667rm -f core conftest.err conftest.$ac_objext \
19668 conftest$ac_exeext conftest.$ac_ext
19669LIBS=$ac_check_lib_save_LIBS
6ad6792b 19670fi
3e0be4ab
GM
19671{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
19672$as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
a9bec17c 19673if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
3e0be4ab
GM
19674 cat >>confdefs.h <<_ACEOF
19675#define HAVE_LIBKSTAT 1
6ad6792b
GM
19676_ACEOF
19677
3e0be4ab
GM
19678 LIBS="-lkstat $LIBS"
19679
6ad6792b
GM
19680fi
19681
3e0be4ab 19682 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
6c051bab 19683
3e0be4ab
GM
19684 # AIX has libperfstat which does not require root
19685 if test $gl_func_getloadavg_done = no; then
19686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
19687$as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
a9bec17c 19688if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
6c051bab
GM
19689 $as_echo_n "(cached) " >&6
19690else
3e0be4ab
GM
19691 ac_check_lib_save_LIBS=$LIBS
19692LIBS="-lperfstat $LIBS"
19693cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6c051bab 19694/* end confdefs.h. */
3e0be4ab
GM
19695
19696/* Override any GCC internal prototype to avoid an error.
19697 Use char because int might match the return type of a GCC
19698 builtin and then its argument prototype would still apply. */
19699#ifdef __cplusplus
19700extern "C"
19701#endif
19702char perfstat_cpu_total ();
6c051bab
GM
19703int
19704main ()
19705{
3e0be4ab 19706return perfstat_cpu_total ();
6c051bab
GM
19707 ;
19708 return 0;
19709}
19710_ACEOF
3e0be4ab
GM
19711if ac_fn_c_try_link "$LINENO"; then :
19712 ac_cv_lib_perfstat_perfstat_cpu_total=yes
6c051bab 19713else
3e0be4ab 19714 ac_cv_lib_perfstat_perfstat_cpu_total=no
6c051bab 19715fi
3e0be4ab
GM
19716rm -f core conftest.err conftest.$ac_objext \
19717 conftest$ac_exeext conftest.$ac_ext
19718LIBS=$ac_check_lib_save_LIBS
6c051bab 19719fi
3e0be4ab
GM
19720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
19721$as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
a9bec17c 19722if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
3e0be4ab
GM
19723 cat >>confdefs.h <<_ACEOF
19724#define HAVE_LIBPERFSTAT 1
19725_ACEOF
6c051bab 19726
3e0be4ab 19727 LIBS="-lperfstat $LIBS"
6c051bab 19728
3e0be4ab 19729fi
6c051bab 19730
3e0be4ab
GM
19731 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
19732 fi
ae0d7250 19733
3e0be4ab
GM
19734 if test $gl_func_getloadavg_done = no; then
19735 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
a9bec17c 19736if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
3e0be4ab
GM
19737 gl_func_getloadavg_done=yes
19738
19739$as_echo "#define DGUX 1" >>confdefs.h
19740
19741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
19742$as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
a9bec17c 19743if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
ae0d7250
PE
19744 $as_echo_n "(cached) " >&6
19745else
3e0be4ab
GM
19746 ac_check_lib_save_LIBS=$LIBS
19747LIBS="-ldgc $LIBS"
19748cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6d153f56 19749/* end confdefs.h. */
3e0be4ab
GM
19750
19751/* Override any GCC internal prototype to avoid an error.
19752 Use char because int might match the return type of a GCC
19753 builtin and then its argument prototype would still apply. */
19754#ifdef __cplusplus
19755extern "C"
19756#endif
19757char dg_sys_info ();
ae0d7250
PE
19758int
19759main ()
19760{
3e0be4ab 19761return dg_sys_info ();
ae0d7250
PE
19762 ;
19763 return 0;
19764}
19765_ACEOF
3e0be4ab
GM
19766if ac_fn_c_try_link "$LINENO"; then :
19767 ac_cv_lib_dgc_dg_sys_info=yes
ae0d7250 19768else
3e0be4ab 19769 ac_cv_lib_dgc_dg_sys_info=no
ae0d7250 19770fi
3e0be4ab
GM
19771rm -f core conftest.err conftest.$ac_objext \
19772 conftest$ac_exeext conftest.$ac_ext
19773LIBS=$ac_check_lib_save_LIBS
ae0d7250 19774fi
3e0be4ab
GM
19775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
19776$as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
a9bec17c 19777if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
3e0be4ab
GM
19778 cat >>confdefs.h <<_ACEOF
19779#define HAVE_LIBDGC 1
19780_ACEOF
ae0d7250 19781
3e0be4ab
GM
19782 LIBS="-ldgc $LIBS"
19783
19784fi
6d153f56 19785
ae0d7250 19786fi
6d153f56 19787
6d153f56 19788
3e0be4ab
GM
19789 fi
19790 fi
19791fi
6d153f56
GM
19792
19793
3e0be4ab
GM
19794if test "x$gl_save_LIBS" = x; then
19795 GETLOADAVG_LIBS=$LIBS
19796else
19797 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
19798fi
19799LIBS=$gl_save_LIBS
6d153f56
GM
19800
19801
3e0be4ab
GM
19802# Test whether the system declares getloadavg. Solaris has the function
19803# but declares it in <sys/loadavg.h>, not <stdlib.h>.
19804for ac_header in sys/loadavg.h
19805do :
19806 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
a9bec17c 19807if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
3e0be4ab
GM
19808 cat >>confdefs.h <<_ACEOF
19809#define HAVE_SYS_LOADAVG_H 1
19810_ACEOF
6d153f56 19811
3e0be4ab 19812fi
6d153f56 19813
3e0be4ab 19814done
6d153f56 19815
3e0be4ab
GM
19816if test $ac_cv_header_sys_loadavg_h = yes; then
19817 HAVE_SYS_LOADAVG_H=1
ae0d7250 19818else
3e0be4ab
GM
19819 HAVE_SYS_LOADAVG_H=0
19820fi
19821ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
2b1928b8
GM
19822 # include <sys/loadavg.h>
19823 #endif
19824 #include <stdlib.h>
3e0be4ab 19825"
a9bec17c 19826if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
6d153f56 19827
3e0be4ab
GM
19828else
19829 HAVE_DECL_GETLOADAVG=0
19830fi
ae0d7250 19831
6d153f56 19832
3e0be4ab 19833if test $HAVE_GETLOADAVG = 0; then
6d153f56 19834
6d153f56 19835
6d153f56
GM
19836
19837
19838
19839
6d153f56 19840
6d153f56 19841
3e0be4ab 19842 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
6d153f56 19843
ae0d7250 19844
3e0be4ab
GM
19845# Figure out what our getloadavg.c needs.
19846
19847# On HPUX9, an unprivileged user can get load averages this way.
19848if test $gl_func_getloadavg_done = no; then
19849 for ac_func in pstat_getdynamic
19850do :
19851 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
a9bec17c 19852if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
3e0be4ab
GM
19853 cat >>confdefs.h <<_ACEOF
19854#define HAVE_PSTAT_GETDYNAMIC 1
ae0d7250 19855_ACEOF
3e0be4ab 19856 gl_func_getloadavg_done=yes
ae0d7250 19857fi
3e0be4ab
GM
19858done
19859
ae0d7250
PE
19860fi
19861
3e0be4ab
GM
19862# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
19863# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
19864# Irix 4.0.5F has the header but not the library.
19865if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
19866 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
19867 gl_func_getloadavg_done=yes
ae0d7250 19868
3e0be4ab 19869$as_echo "#define SVR4 1" >>confdefs.h
ae0d7250 19870
3e0be4ab 19871fi
ae0d7250 19872
3e0be4ab
GM
19873if test $gl_func_getloadavg_done = no; then
19874 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
a9bec17c 19875if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
3e0be4ab 19876 gl_func_getloadavg_done=yes
ae0d7250 19877
3e0be4ab 19878$as_echo "#define UMAX 1" >>confdefs.h
ae0d7250
PE
19879
19880
3e0be4ab 19881$as_echo "#define UMAX4_3 1" >>confdefs.h
ae0d7250 19882
6d153f56 19883fi
ae0d7250
PE
19884
19885
3e0be4ab 19886fi
ae0d7250 19887
3e0be4ab
GM
19888if test $gl_func_getloadavg_done = no; then
19889 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
a9bec17c 19890if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
3e0be4ab 19891 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
16c3e636 19892
3e0be4ab 19893fi
16c3e636
PE
19894
19895
3e0be4ab 19896fi
5f90be1b 19897
3e0be4ab
GM
19898if test $gl_func_getloadavg_done = no; then
19899 for ac_header in mach/mach.h
19900do :
19901 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
a9bec17c 19902if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
3e0be4ab
GM
19903 cat >>confdefs.h <<_ACEOF
19904#define HAVE_MACH_MACH_H 1
19905_ACEOF
da6c8463 19906
5f90be1b 19907fi
5f90be1b 19908
3e0be4ab 19909done
5f90be1b 19910
3e0be4ab 19911fi
5f90be1b 19912
3e0be4ab
GM
19913for ac_header in nlist.h
19914do :
19915 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
a9bec17c 19916if test "x$ac_cv_header_nlist_h" = x""yes; then :
3e0be4ab
GM
19917 cat >>confdefs.h <<_ACEOF
19918#define HAVE_NLIST_H 1
19919_ACEOF
19920 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
19921"
a9bec17c 19922if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
5f90be1b 19923
3e0be4ab
GM
19924cat >>confdefs.h <<_ACEOF
19925#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
19926_ACEOF
5f90be1b
PE
19927
19928
3e0be4ab 19929fi
da6c8463 19930
3e0be4ab 19931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5f90be1b 19932/* end confdefs.h. */
3e0be4ab 19933#include <nlist.h>
5f90be1b
PE
19934int
19935main ()
19936{
3e0be4ab
GM
19937struct nlist x;
19938 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
19939 x.n_un.n_name = "";
19940 #else
19941 x.n_name = "";
19942 #endif
5f90be1b
PE
19943 ;
19944 return 0;
19945}
19946_ACEOF
3e0be4ab
GM
19947if ac_fn_c_try_link "$LINENO"; then :
19948
19949$as_echo "#define N_NAME_POINTER 1" >>confdefs.h
19950
5f90be1b 19951fi
3e0be4ab
GM
19952rm -f core conftest.err conftest.$ac_objext \
19953 conftest$ac_exeext conftest.$ac_ext
19954
5f90be1b 19955fi
5f90be1b 19956
3e0be4ab
GM
19957done
19958
da6c8463
GM
19959fi
19960
5f90be1b
PE
19961
19962
5f90be1b
PE
19963
19964
3e0be4ab 19965 GNULIB_GETLOADAVG=1
da6c8463
GM
19966
19967
19968
19969
da6c8463 19970
5f90be1b 19971
5f90be1b 19972
5f90be1b 19973
5f90be1b 19974
3e0be4ab
GM
19975
19976if test $REPLACE_GETOPT = 1; then
19977
19978
19979
19980
19981
5f90be1b
PE
19982
19983
19984
3e0be4ab
GM
19985 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
19986
19987
5f90be1b 19988
6c051bab 19989
5f90be1b 19990
6ad6792b
GM
19991
19992
19993
19994
3e0be4ab 19995 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
6ad6792b
GM
19996
19997
19998
19999
3e0be4ab 20000fi
6ad6792b
GM
20001
20002
20003
6ad6792b 20004
6ad6792b 20005
3e0be4ab
GM
20006 REPLACE_GETOPT=0
20007
20008
20009 if test -n "$gl_replace_getopt"; then :
6ad6792b 20010
3e0be4ab 20011 REPLACE_GETOPT=1
6ad6792b
GM
20012
20013fi
6ad6792b 20014
6ad6792b 20015
3e0be4ab 20016 if test $REPLACE_GETOPT = 1; then
6ad6792b 20017
3e0be4ab 20018 GETOPT_H=getopt.h
6ad6792b 20019
3e0be4ab 20020$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
6ad6792b 20021
ca36e0ff 20022
ca36e0ff 20023
3e0be4ab
GM
20024 GNULIB_UNISTD_H_GETOPT=1
20025 fi
ca36e0ff 20026
3e0be4ab 20027if test $REPLACE_GETOPT = 1; then
6ad6792b
GM
20028
20029
20030
20031
ca36e0ff 20032
1f5d53eb
PE
20033
20034
20035
3e0be4ab 20036 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
1f5d53eb
PE
20037
20038
20039
20040
20041
20042
20043
1f5d53eb 20044
1f5d53eb 20045
3e0be4ab
GM
20046 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
20047
20048
1f5d53eb
PE
20049
20050
20051fi
1f5d53eb 20052
1f5d53eb
PE
20053
20054
20055
20056
3e0be4ab 20057 if test $ac_cv_func_lstat = yes; then
1f5d53eb 20058
3e0be4ab
GM
20059 if test $gl_cv_func_lstat_dereferences_slashed_symlink = no; then
20060 REPLACE_LSTAT=1
20061 fi
20062 else
20063 HAVE_LSTAT=0
20064 fi
1f5d53eb 20065
3e0be4ab 20066if test $REPLACE_LSTAT = 1; then
1f5d53eb 20067
16c3e636
PE
20068
20069
16c3e636
PE
20070
20071
20072
20073
20074
3e0be4ab 20075 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
16c3e636
PE
20076
20077
16c3e636 20078
3e0be4ab 20079 :
16c3e636 20080
3e0be4ab 20081fi
16c3e636 20082
4fda9c95
GM
20083
20084
20085
20086
3e0be4ab 20087 GNULIB_LSTAT=1
4fda9c95
GM
20088
20089
20090
20091
20092
20093
20094
20095
20096
4fda9c95 20097
4fda9c95 20098
3e0be4ab
GM
20099 if test $APPLE_UNIVERSAL_BUILD = 1; then
20100 # A universal build on Apple MacOS X platforms.
20101 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
20102 # But we need a configuration result that is valid in both modes.
20103 gl_cv_func_working_mktime=no
20104 fi
20105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
20106$as_echo_n "checking for working mktime... " >&6; }
a9bec17c 20107if test "${gl_cv_func_working_mktime+set}" = set; then :
3e0be4ab
GM
20108 $as_echo_n "(cached) " >&6
20109else
20110 if test "$cross_compiling" = yes; then :
20111 gl_cv_func_working_mktime=no
20112else
20113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20114/* end confdefs.h. */
20115/* Test program from Paul Eggert and Tony Leneis. */
20116#include <limits.h>
20117#include <stdlib.h>
20118#include <time.h>
4fda9c95 20119
3e0be4ab
GM
20120#ifdef HAVE_UNISTD_H
20121# include <unistd.h>
20122#endif
4fda9c95 20123
3e0be4ab
GM
20124#ifndef HAVE_ALARM
20125# define alarm(X) /* empty */
20126#endif
4fda9c95 20127
3e0be4ab
GM
20128/* Work around redefinition to rpl_putenv by other config tests. */
20129#undef putenv
4fda9c95 20130
3e0be4ab
GM
20131static time_t time_t_max;
20132static time_t time_t_min;
20133
20134/* Values we'll use to set the TZ environment variable. */
20135static char *tz_strings[] = {
20136 (char *) 0, "TZ=GMT0", "TZ=JST-9",
20137 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
20138};
20139#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
4fda9c95 20140
3e0be4ab
GM
20141/* Return 0 if mktime fails to convert a date in the spring-forward gap.
20142 Based on a problem report from Andreas Jaeger. */
20143static int
20144spring_forward_gap ()
20145{
20146 /* glibc (up to about 1998-10-07) failed this test. */
20147 struct tm tm;
4fda9c95 20148
3e0be4ab
GM
20149 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
20150 instead of "TZ=America/Vancouver" in order to detect the bug even
20151 on systems that don't support the Olson extension, or don't have the
20152 full zoneinfo tables installed. */
20153 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
4fda9c95 20154
3e0be4ab
GM
20155 tm.tm_year = 98;
20156 tm.tm_mon = 3;
20157 tm.tm_mday = 5;
20158 tm.tm_hour = 2;
20159 tm.tm_min = 0;
20160 tm.tm_sec = 0;
20161 tm.tm_isdst = -1;
20162 return mktime (&tm) != (time_t) -1;
20163}
20164
20165static int
20166mktime_test1 (time_t now)
20167{
20168 struct tm *lt;
20169 return ! (lt = localtime (&now)) || mktime (lt) == now;
20170}
4fda9c95 20171
3e0be4ab
GM
20172static int
20173mktime_test (time_t now)
20174{
20175 return (mktime_test1 (now)
20176 && mktime_test1 ((time_t) (time_t_max - now))
20177 && mktime_test1 ((time_t) (time_t_min + now)));
20178}
4fda9c95 20179
3e0be4ab
GM
20180static int
20181irix_6_4_bug ()
20182{
20183 /* Based on code from Ariel Faigon. */
20184 struct tm tm;
20185 tm.tm_year = 96;
20186 tm.tm_mon = 3;
20187 tm.tm_mday = 0;
20188 tm.tm_hour = 0;
20189 tm.tm_min = 0;
20190 tm.tm_sec = 0;
20191 tm.tm_isdst = -1;
20192 mktime (&tm);
20193 return tm.tm_mon == 2 && tm.tm_mday == 31;
20194}
4fda9c95 20195
3e0be4ab
GM
20196static int
20197bigtime_test (int j)
20198{
20199 struct tm tm;
20200 time_t now;
20201 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
20202 now = mktime (&tm);
20203 if (now != (time_t) -1)
20204 {
20205 struct tm *lt = localtime (&now);
20206 if (! (lt
20207 && lt->tm_year == tm.tm_year
20208 && lt->tm_mon == tm.tm_mon
20209 && lt->tm_mday == tm.tm_mday
20210 && lt->tm_hour == tm.tm_hour
20211 && lt->tm_min == tm.tm_min
20212 && lt->tm_sec == tm.tm_sec
20213 && lt->tm_yday == tm.tm_yday
20214 && lt->tm_wday == tm.tm_wday
20215 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
20216 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
20217 return 0;
20218 }
20219 return 1;
20220}
cc322c06 20221
3e0be4ab
GM
20222static int
20223year_2050_test ()
20224{
20225 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
20226 ignoring leap seconds. */
20227 unsigned long int answer = 2527315200UL;
cc322c06 20228
3e0be4ab
GM
20229 struct tm tm;
20230 time_t t;
20231 tm.tm_year = 2050 - 1900;
20232 tm.tm_mon = 2 - 1;
20233 tm.tm_mday = 1;
20234 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
20235 tm.tm_isdst = -1;
cc322c06 20236
3e0be4ab
GM
20237 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
20238 instead of "TZ=America/Vancouver" in order to detect the bug even
20239 on systems that don't support the Olson extension, or don't have the
20240 full zoneinfo tables installed. */
20241 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
cc322c06 20242
3e0be4ab 20243 t = mktime (&tm);
4fda9c95 20244
3e0be4ab
GM
20245 /* Check that the result is either a failure, or close enough
20246 to the correct answer that we can assume the discrepancy is
20247 due to leap seconds. */
20248 return (t == (time_t) -1
20249 || (0 < t && answer - 120 <= t && t <= answer + 120));
20250}
4fda9c95 20251
3e0be4ab
GM
20252int
20253main ()
20254{
20255 int result = 0;
20256 time_t t, delta;
20257 int i, j;
20258 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
20259 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
ae0d7250 20260
3e0be4ab
GM
20261 /* This test makes some buggy mktime implementations loop.
20262 Give up after 60 seconds; a mktime slower than that
20263 isn't worth using anyway. */
20264 alarm (60);
ae0d7250 20265
3e0be4ab
GM
20266 time_t_max = (! time_t_signed
20267 ? (time_t) -1
20268 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
20269 * 2 + 1));
20270 time_t_min = (! time_t_signed
20271 ? (time_t) 0
20272 : time_t_signed_magnitude
20273 ? ~ (time_t) 0
20274 : ~ time_t_max);
ae0d7250 20275
3e0be4ab
GM
20276 delta = time_t_max / 997; /* a suitable prime number */
20277 for (i = 0; i < N_STRINGS; i++)
20278 {
20279 if (tz_strings[i])
20280 putenv (tz_strings[i]);
ae0d7250 20281
3e0be4ab
GM
20282 for (t = 0; t <= time_t_max - delta; t += delta)
20283 if (! mktime_test (t))
20284 result |= 1;
20285 if (! (mktime_test ((time_t) 1)
20286 && mktime_test ((time_t) (60 * 60))
20287 && mktime_test ((time_t) (60 * 60 * 24))))
20288 result |= 2;
ae0d7250 20289
3e0be4ab
GM
20290 for (j = 1; ; j <<= 1)
20291 if (! bigtime_test (j))
20292 result |= 4;
20293 else if (INT_MAX / 2 < j)
20294 break;
20295 if (! bigtime_test (INT_MAX))
20296 result |= 8;
20297 }
20298 if (! irix_6_4_bug ())
20299 result |= 16;
20300 if (! spring_forward_gap ())
20301 result |= 32;
20302 if (! year_2050_test ())
20303 result |= 64;
20304 return result;
ae0d7250
PE
20305}
20306_ACEOF
20307if ac_fn_c_try_run "$LINENO"; then :
3e0be4ab 20308 gl_cv_func_working_mktime=yes
ae0d7250 20309else
3e0be4ab 20310 gl_cv_func_working_mktime=no
ae0d7250
PE
20311fi
20312rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20313 conftest.$ac_objext conftest.beam conftest.$ac_ext
20314fi
20315
ae0d7250 20316
52724a05 20317fi
3e0be4ab
GM
20318{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
20319$as_echo "$gl_cv_func_working_mktime" >&6; }
20320
20321 if test $gl_cv_func_working_mktime = no; then
20322 REPLACE_MKTIME=1
20323 else
20324 REPLACE_MKTIME=0
20325 fi
ae0d7250 20326
3e0be4ab 20327if test $REPLACE_MKTIME = 1; then
ae0d7250
PE
20328
20329
cc322c06
GM
20330
20331
cc322c06
GM
20332
20333
ae0d7250
PE
20334
20335
3e0be4ab 20336 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
ae0d7250 20337
5fa4ac76
PE
20338
20339
20340
3e0be4ab 20341fi
5fa4ac76
PE
20342
20343
20344
20345
20346
3e0be4ab 20347 GNULIB_MKTIME=1
5fa4ac76
PE
20348
20349
20350
20351
20352
20353
20354
20355
3e0be4ab 20356 LIB_PTHREAD_SIGMASK=
369e19fc
PE
20357
20358
20359 if test $ac_cv_func_pthread_sigmask = yes; then
20360 :
20361 else
20362 HAVE_PTHREAD_SIGMASK=0
20363 REPLACE_PTHREAD_SIGMASK=1
20364 fi
20365
20366
20367
20368
20369 if test $HAVE_PTHREAD_SIGMASK = 1; then
20370
20371
20372 if test -z "$LIB_PTHREAD_SIGMASK"; then
20373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
20374$as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
a9bec17c 20375if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
5fa4ac76
PE
20376 $as_echo_n "(cached) " >&6
20377else
369e19fc
PE
20378
20379 if test "$cross_compiling" = yes; then :
20380
20381 case "$host_os" in
20382 freebsd* | hpux* | solaris | solaris2.[2-9]*)
20383 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
20384 *)
20385 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
20386 esac
20387
20388else
20389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5fa4ac76 20390/* end confdefs.h. */
5fa4ac76 20391
369e19fc
PE
20392#include <pthread.h>
20393#include <signal.h>
20394#include <stddef.h>
20395int main ()
3e0be4ab 20396{
369e19fc
PE
20397 sigset_t set;
20398 sigemptyset (&set);
20399 return pthread_sigmask (1729, &set, NULL) != 0;
20400}
20401_ACEOF
20402if ac_fn_c_try_run "$LINENO"; then :
20403 gl_cv_func_pthread_sigmask_in_libc_works=no
20404else
20405 gl_cv_func_pthread_sigmask_in_libc_works=yes
20406fi
20407rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20408 conftest.$ac_objext conftest.beam conftest.$ac_ext
20409fi
20410
20411
20412fi
20413{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
20414$as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
20415 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
20416 *no)
20417 REPLACE_PTHREAD_SIGMASK=1
20418
20419$as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
20420
20421 ;;
20422 esac
20423 fi
20424
20425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
20426$as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
a9bec17c 20427if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
369e19fc
PE
20428 $as_echo_n "(cached) " >&6
20429else
20430
20431 gl_save_LIBS="$LIBS"
20432 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
20433 if test "$cross_compiling" = yes; then :
20434 case "$host_os" in
20435 cygwin*)
20436 gl_cv_func_pthread_sigmask_return_works="guessing no";;
20437 *)
20438 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
20439 esac
20440
20441else
20442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20443/* end confdefs.h. */
20444
20445#include <pthread.h>
20446#include <signal.h>
20447#include <stddef.h>
20448int main ()
20449{
20450 sigset_t set;
20451 sigemptyset (&set);
20452 if (pthread_sigmask (1729, &set, NULL) == -1)
20453 return 1;
3e0be4ab
GM
20454 return 0;
20455}
5fa4ac76 20456_ACEOF
369e19fc
PE
20457if ac_fn_c_try_run "$LINENO"; then :
20458 gl_cv_func_pthread_sigmask_return_works=yes
20459else
20460 gl_cv_func_pthread_sigmask_return_works=no
5fa4ac76 20461fi
369e19fc
PE
20462rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20463 conftest.$ac_objext conftest.beam conftest.$ac_ext
3e0be4ab 20464fi
5fa4ac76 20465
369e19fc
PE
20466 LIBS="$gl_save_LIBS"
20467
20468fi
20469{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
20470$as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
20471 case "$gl_cv_func_pthread_sigmask_return_works" in
20472 *no)
20473 REPLACE_PTHREAD_SIGMASK=1
20474
20475$as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
20476
20477 ;;
20478 esac
20479
20480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
20481$as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
a9bec17c 20482if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
369e19fc
PE
20483 $as_echo_n "(cached) " >&6
20484else
20485
20486 case "$host_os" in
20487 irix*)
20488 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
20489 *)
20490 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
20491 esac
20492 gl_save_LIBS="$LIBS"
20493 LIBS="$LIBS $LIBMULTITHREAD"
20494 if test "$cross_compiling" = yes; then :
20495 :
20496else
20497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20498/* end confdefs.h. */
20499
20500#include <pthread.h>
20501#include <signal.h>
20502#include <stdio.h>
20503#include <stdlib.h>
20504#include <unistd.h>
20505static volatile int sigint_occurred;
20506static void
20507sigint_handler (int sig)
20508{
20509 sigint_occurred++;
20510}
20511int main ()
20512{
20513 sigset_t set;
20514 int pid = getpid ();
20515 char command[80];
20516 signal (SIGINT, sigint_handler);
20517 sigemptyset (&set);
20518 sigaddset (&set, SIGINT);
20519 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
20520 return 1;
20521 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
20522 if (!(system (command) == 0))
20523 return 2;
20524 sleep (2);
20525 if (!(sigint_occurred == 0))
20526 return 3;
20527 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
20528 return 4;
20529 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
20530 return 5;
20531 return 0;
20532}
20533_ACEOF
20534if ac_fn_c_try_run "$LINENO"; then :
20535 :
3e0be4ab 20536else
369e19fc 20537 gl_cv_func_pthread_sigmask_unblock_works=no
3e0be4ab 20538fi
369e19fc
PE
20539rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20540 conftest.$ac_objext conftest.beam conftest.$ac_ext
3e0be4ab 20541fi
369e19fc
PE
20542
20543 LIBS="$gl_save_LIBS"
5fa4ac76 20544
3e0be4ab 20545fi
369e19fc
PE
20546{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
20547$as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
20548 case "$gl_cv_func_pthread_sigmask_unblock_works" in
20549 *no)
20550 REPLACE_PTHREAD_SIGMASK=1
5fa4ac76 20551
369e19fc 20552$as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
5fa4ac76 20553
369e19fc
PE
20554 ;;
20555 esac
20556 fi
5fa4ac76 20557
3e0be4ab 20558if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
5fa4ac76 20559
5fa4ac76 20560
5fa4ac76 20561
5fa4ac76
PE
20562
20563
20564
20565
20566
3e0be4ab 20567 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
067d23c9 20568
369e19fc
PE
20569
20570 if test $HAVE_PTHREAD_SIGMASK = 1; then
20571
20572$as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
20573
20574 fi
20575
3e0be4ab 20576fi
067d23c9 20577
067d23c9
KY
20578
20579
067d23c9 20580
067d23c9 20581
3e0be4ab 20582 GNULIB_PTHREAD_SIGMASK=1
067d23c9
KY
20583
20584
067d23c9 20585
067d23c9
KY
20586
20587
20588
3e0be4ab
GM
20589
20590
20591 if test $ac_cv_func_readlink = no; then
20592 HAVE_READLINK=0
20593 else
20594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
20595$as_echo_n "checking whether readlink signature is correct... " >&6; }
a9bec17c 20596if test "${gl_cv_decl_readlink_works+set}" = set; then :
067d23c9
KY
20597 $as_echo_n "(cached) " >&6
20598else
1fd182f0 20599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 20600/* end confdefs.h. */
3e0be4ab
GM
20601#include <unistd.h>
20602 /* Cause compilation failure if original declaration has wrong type. */
20603 ssize_t readlink (const char *, char *, size_t);
067d23c9
KY
20604int
20605main ()
20606{
3e0be4ab 20607
067d23c9
KY
20608 ;
20609 return 0;
20610}
20611_ACEOF
20612if ac_fn_c_try_compile "$LINENO"; then :
3e0be4ab 20613 gl_cv_decl_readlink_works=yes
067d23c9 20614else
3e0be4ab 20615 gl_cv_decl_readlink_works=no
067d23c9
KY
20616fi
20617rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3e0be4ab
GM
20618fi
20619{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
20620$as_echo "$gl_cv_decl_readlink_works" >&6; }
20621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
20622$as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
a9bec17c 20623if test "${gl_cv_func_readlink_works+set}" = set; then :
3e0be4ab
GM
20624 $as_echo_n "(cached) " >&6
20625else
20626 # We have readlink, so assume ln -s works.
20627 ln -s conftest.no-such conftest.link
20628 ln -s conftest.link conftest.lnk2
20629 if test "$cross_compiling" = yes; then :
20630 gl_cv_func_readlink_works="guessing no"
20631else
20632 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20633/* end confdefs.h. */
20634#include <unistd.h>
067d23c9 20635
3e0be4ab
GM
20636int
20637main ()
20638{
20639char buf[20];
20640 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
20641 ;
20642 return 0;
20643}
20644_ACEOF
20645if ac_fn_c_try_run "$LINENO"; then :
20646 gl_cv_func_readlink_works=yes
20647else
20648 gl_cv_func_readlink_works=no
067d23c9 20649fi
3e0be4ab
GM
20650rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20651 conftest.$ac_objext conftest.beam conftest.$ac_ext
20652fi
20653
20654 rm -f conftest.link conftest.lnk2
20655fi
20656{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
20657$as_echo "$gl_cv_func_readlink_works" >&6; }
20658 if test "$gl_cv_func_readlink_works" != yes; then
20659
20660$as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
20661
20662 REPLACE_READLINK=1
20663 elif test "$gl_cv_decl_readlink_works" != yes; then
20664 REPLACE_READLINK=1
1fd182f0 20665 fi
1fd182f0 20666 fi
52724a05 20667
3e0be4ab 20668if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
067d23c9 20669
067d23c9
KY
20670
20671
743c80a7 20672
a451f14b
PE
20673
20674
20675
a451f14b 20676
3e0be4ab 20677 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
a451f14b 20678
a451f14b 20679
1fd182f0 20680 :
a451f14b 20681
52724a05 20682fi
a451f14b 20683
743c80a7
PE
20684
20685
cc322c06
GM
20686
20687
3e0be4ab 20688 GNULIB_READLINK=1
743c80a7
PE
20689
20690
a451f14b
PE
20691
20692
20693
e275c824
PE
20694
20695
20696
20697
20698
20699
20700
20701
20702
20703
d87ffdb7 20704
e275c824 20705 if test $gl_cv_have_include_next = yes; then
3e0be4ab 20706 gl_cv_next_signal_h='<'signal.h'>'
e275c824 20707 else
3e0be4ab
GM
20708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
20709$as_echo_n "checking absolute name of <signal.h>... " >&6; }
a9bec17c 20710if test "${gl_cv_next_signal_h+set}" = set; then :
e275c824
PE
20711 $as_echo_n "(cached) " >&6
20712else
20713
b06b1098 20714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e275c824 20715/* end confdefs.h. */
3e0be4ab 20716#include <signal.h>
e275c824
PE
20717
20718_ACEOF
b06b1098
PE
20719 case "$host_os" in
20720 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20721 *) gl_absname_cpp="$ac_cpp" ;;
20722 esac
b0415a03
GM
20723
20724 case "$host_os" in
20725 mingw*)
20726 gl_dirsep_regex='[/\\]'
20727 ;;
20728 *)
20729 gl_dirsep_regex='/'
20730 ;;
20731 esac
20732
2b1928b8
GM
20733 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'signal.h|{
20734 s|.*"\(.*'"${gl_dirsep_regex}"'signal.h\)".*|\1|
20735 s|^/[^/]|//&|
b0415a03
GM
20736 p
20737 q
20738 }'
3e0be4ab 20739 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 20740 sed -n "$gl_absolute_header_sed"`'"'
b06b1098 20741
e275c824
PE
20742
20743fi
3e0be4ab
GM
20744{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
20745$as_echo "$gl_cv_next_signal_h" >&6; }
e275c824 20746 fi
3e0be4ab 20747 NEXT_SIGNAL_H=$gl_cv_next_signal_h
e275c824
PE
20748
20749 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20750 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
3e0be4ab 20751 gl_next_as_first_directive='<'signal.h'>'
e275c824
PE
20752 else
20753 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
3e0be4ab 20754 gl_next_as_first_directive=$gl_cv_next_signal_h
e275c824 20755 fi
3e0be4ab 20756 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
e275c824
PE
20757
20758
20759
20760
e275c824 20761
3e0be4ab
GM
20762# AIX declares sig_atomic_t to already include volatile, and C89 compilers
20763# then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
20764 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
20765#include <signal.h>
e275c824 20766
3e0be4ab 20767"
a9bec17c 20768if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
e275c824 20769
3e0be4ab
GM
20770else
20771 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
20772fi
e275c824 20773
6d153f56
GM
20774
20775
6d153f56
GM
20776
20777
b0415a03
GM
20778
20779
3e0be4ab
GM
20780 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
20781#include <signal.h>
6d153f56 20782
3e0be4ab 20783"
a9bec17c 20784if test "x$ac_cv_type_sighandler_t" = x""yes; then :
3e0be4ab
GM
20785
20786else
20787 HAVE_SIGHANDLER_T=0
20788fi
20789
20790
20791
20792
20793 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
20794/* <sys/types.h> is not needed according to POSIX, but the
20795 <sys/socket.h> in i386-unknown-freebsd4.10 and
20796 powerpc-apple-darwin5.5 required it. */
20797#include <sys/types.h>
20798#if HAVE_SYS_SOCKET_H
20799# include <sys/socket.h>
20800#elif HAVE_WS2TCPIP_H
20801# include <ws2tcpip.h>
20802#endif
20803
20804"
a9bec17c 20805if test "x$ac_cv_type_socklen_t" = x""yes; then :
3e0be4ab
GM
20806
20807else
20808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
20809$as_echo_n "checking for socklen_t equivalent... " >&6; }
a9bec17c 20810 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
6d153f56
GM
20811 $as_echo_n "(cached) " >&6
20812else
3e0be4ab
GM
20813 # Systems have either "struct sockaddr *" or
20814 # "void *" as the second argument to getpeername
20815 gl_cv_socklen_t_equiv=
20816 for arg2 in "struct sockaddr" void; do
20817 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
20818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20819/* end confdefs.h. */
20820#include <sys/types.h>
20821 #include <sys/socket.h>
20822
20823 int getpeername (int, $arg2 *, $t *);
20824int
20825main ()
20826{
20827$t len;
20828 getpeername (0, 0, &len);
20829 ;
20830 return 0;
20831}
20832_ACEOF
20833if ac_fn_c_try_compile "$LINENO"; then :
20834 gl_cv_socklen_t_equiv="$t"
20835fi
20836rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20837 test "$gl_cv_socklen_t_equiv" != "" && break
20838 done
20839 test "$gl_cv_socklen_t_equiv" != "" && break
20840 done
20841
20842fi
20843
20844 if test "$gl_cv_socklen_t_equiv" = ""; then
a9bec17c 20845 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
3e0be4ab
GM
20846 fi
20847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
20848$as_echo "$gl_cv_socklen_t_equiv" >&6; }
20849
20850cat >>confdefs.h <<_ACEOF
20851#define socklen_t $gl_cv_socklen_t_equiv
20852_ACEOF
20853
20854fi
20855
20856
20857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
20858$as_echo_n "checking for ssize_t... " >&6; }
a9bec17c 20859if test "${gt_cv_ssize_t+set}" = set; then :
3e0be4ab 20860 $as_echo_n "(cached) " >&6
6d153f56
GM
20861else
20862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20863/* end confdefs.h. */
3e0be4ab 20864#include <sys/types.h>
6d153f56
GM
20865int
20866main ()
20867{
3e0be4ab
GM
20868int x = sizeof (ssize_t *) + sizeof (ssize_t);
20869 return !x;
6d153f56
GM
20870 ;
20871 return 0;
20872}
20873_ACEOF
3e0be4ab
GM
20874if ac_fn_c_try_compile "$LINENO"; then :
20875 gt_cv_ssize_t=yes
6d153f56 20876else
3e0be4ab 20877 gt_cv_ssize_t=no
6d153f56 20878fi
3e0be4ab 20879rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6d153f56 20880fi
3e0be4ab
GM
20881{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
20882$as_echo "$gt_cv_ssize_t" >&6; }
20883 if test $gt_cv_ssize_t = no; then
6d153f56 20884
3e0be4ab
GM
20885$as_echo "#define ssize_t int" >>confdefs.h
20886
20887 fi
20888
20889
20890 STDARG_H=''
20891 NEXT_STDARG_H='<stdarg.h>'
20892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
20893$as_echo_n "checking for va_copy... " >&6; }
a9bec17c 20894 if test "${gl_cv_func_va_copy+set}" = set; then :
6d153f56
GM
20895 $as_echo_n "(cached) " >&6
20896else
6d153f56 20897
3e0be4ab
GM
20898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20899/* end confdefs.h. */
20900#include <stdarg.h>
6d153f56
GM
20901int
20902main ()
20903{
3e0be4ab
GM
20904
20905#ifndef va_copy
20906void (*func) (va_list, va_list) = va_copy;
6d153f56 20907#endif
6d153f56
GM
20908
20909 ;
20910 return 0;
20911}
20912_ACEOF
3e0be4ab
GM
20913if ac_fn_c_try_compile "$LINENO"; then :
20914 gl_cv_func_va_copy=yes
6d153f56 20915else
3e0be4ab 20916 gl_cv_func_va_copy=no
6d153f56 20917fi
3e0be4ab 20918rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6d153f56 20919fi
6d153f56 20920
3e0be4ab
GM
20921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
20922$as_echo "$gl_cv_func_va_copy" >&6; }
20923 if test $gl_cv_func_va_copy = no; then
20924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20925/* end confdefs.h. */
20926#if defined _AIX && !defined __GNUC__
20927 AIX vaccine
20928 #endif
6d153f56 20929
3e0be4ab
GM
20930_ACEOF
20931if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20932 $EGREP "vaccine" >/dev/null 2>&1; then :
20933 gl_aixcc=yes
20934else
20935 gl_aixcc=no
20936fi
20937rm -f conftest*
52724a05 20938
3e0be4ab
GM
20939 if test $gl_aixcc = yes; then
20940 STDARG_H=stdarg.h
6d153f56
GM
20941
20942
20943
20944
20945
20946
20947
20948
3e0be4ab
GM
20949 if test $gl_cv_have_include_next = yes; then
20950 gl_cv_next_stdarg_h='<'stdarg.h'>'
20951 else
20952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
20953$as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
a9bec17c 20954if test "${gl_cv_next_stdarg_h+set}" = set; then :
3e0be4ab
GM
20955 $as_echo_n "(cached) " >&6
20956else
6d153f56 20957
3e0be4ab
GM
20958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20959/* end confdefs.h. */
20960#include <stdarg.h>
6d153f56 20961
3e0be4ab
GM
20962_ACEOF
20963 case "$host_os" in
20964 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20965 *) gl_absname_cpp="$ac_cpp" ;;
20966 esac
b0415a03
GM
20967
20968 case "$host_os" in
20969 mingw*)
20970 gl_dirsep_regex='[/\\]'
20971 ;;
20972 *)
20973 gl_dirsep_regex='/'
20974 ;;
20975 esac
20976
2b1928b8
GM
20977 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdarg.h|{
20978 s|.*"\(.*'"${gl_dirsep_regex}"'stdarg.h\)".*|\1|
20979 s|^/[^/]|//&|
b0415a03
GM
20980 p
20981 q
20982 }'
3e0be4ab 20983 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 20984 sed -n "$gl_absolute_header_sed"`'"'
6d153f56 20985
52724a05
GM
20986
20987fi
3e0be4ab
GM
20988{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
20989$as_echo "$gl_cv_next_stdarg_h" >&6; }
20990 fi
20991 NEXT_STDARG_H=$gl_cv_next_stdarg_h
6d153f56 20992
3e0be4ab
GM
20993 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20994 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20995 gl_next_as_first_directive='<'stdarg.h'>'
20996 else
20997 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20998 gl_next_as_first_directive=$gl_cv_next_stdarg_h
20999 fi
21000 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
6d153f56
GM
21001
21002
cc322c06
GM
21003
21004
3e0be4ab
GM
21005 if test "$gl_cv_next_stdarg_h" = '""'; then
21006 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
21007 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
4fc2b746 21008 fi
3e0be4ab
GM
21009 else
21010
21011 saved_as_echo_n="$as_echo_n"
21012 as_echo_n=':'
a9bec17c 21013 if test "${gl_cv_func___va_copy+set}" = set; then :
3e0be4ab
GM
21014 $as_echo_n "(cached) " >&6
21015else
6d153f56 21016
3e0be4ab
GM
21017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21018/* end confdefs.h. */
21019#include <stdarg.h>
21020int
21021main ()
21022{
6d153f56 21023
3e0be4ab
GM
21024#ifndef __va_copy
21025error, bail out
21026#endif
6d153f56 21027
3e0be4ab
GM
21028 ;
21029 return 0;
21030}
6d153f56 21031_ACEOF
3e0be4ab
GM
21032if ac_fn_c_try_compile "$LINENO"; then :
21033 gl_cv_func___va_copy=yes
21034else
21035 gl_cv_func___va_copy=no
6d153f56 21036fi
3e0be4ab 21037rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
52724a05 21038fi
6d153f56 21039
3e0be4ab 21040 as_echo_n="$saved_as_echo_n"
6d153f56 21041
3e0be4ab 21042 if test $gl_cv_func___va_copy = yes; then
6d153f56 21043
3e0be4ab 21044$as_echo "#define va_copy __va_copy" >>confdefs.h
cc322c06 21045
3e0be4ab 21046 else
6d153f56
GM
21047
21048
3e0be4ab 21049$as_echo "#define va_copy gl_va_copy" >>confdefs.h
6d153f56 21050
3e0be4ab 21051 fi
6d153f56 21052 fi
6d153f56 21053 fi
6d153f56 21054
3e0be4ab
GM
21055 if test -n "$STDARG_H"; then
21056 GL_GENERATE_STDARG_H_TRUE=
21057 GL_GENERATE_STDARG_H_FALSE='#'
6d153f56 21058else
3e0be4ab
GM
21059 GL_GENERATE_STDARG_H_TRUE='#'
21060 GL_GENERATE_STDARG_H_FALSE=
6d153f56
GM
21061fi
21062
a451f14b 21063
a451f14b 21064
743c80a7
PE
21065
21066
21067
3e0be4ab 21068 # Define two additional variables used in the Makefile substitution.
743c80a7 21069
3e0be4ab
GM
21070 if test "$ac_cv_header_stdbool_h" = yes; then
21071 STDBOOL_H=''
21072 else
21073 STDBOOL_H='stdbool.h'
21074 fi
743c80a7 21075
3e0be4ab
GM
21076 if test -n "$STDBOOL_H"; then
21077 GL_GENERATE_STDBOOL_H_TRUE=
21078 GL_GENERATE_STDBOOL_H_FALSE='#'
21079else
21080 GL_GENERATE_STDBOOL_H_TRUE='#'
21081 GL_GENERATE_STDBOOL_H_FALSE=
21082fi
743c80a7
PE
21083
21084
3e0be4ab
GM
21085 if test "$ac_cv_type__Bool" = yes; then
21086 HAVE__BOOL=1
21087 else
21088 HAVE__BOOL=0
21089 fi
743c80a7
PE
21090
21091
21092
21093
21094
3e0be4ab
GM
21095 STDDEF_H=
21096 if test $gt_cv_c_wchar_t = no; then
21097 HAVE_WCHAR_T=0
21098 STDDEF_H=stddef.h
21099 fi
21100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
21101$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
a9bec17c 21102if test "${gl_cv_decl_null_works+set}" = set; then :
3e0be4ab
GM
21103 $as_echo_n "(cached) " >&6
21104else
21105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21106/* end confdefs.h. */
21107#include <stddef.h>
21108 int test[2 * (sizeof NULL == sizeof (void *)) -1];
a451f14b 21109
3e0be4ab
GM
21110int
21111main ()
21112{
a451f14b 21113
3e0be4ab
GM
21114 ;
21115 return 0;
21116}
21117_ACEOF
21118if ac_fn_c_try_compile "$LINENO"; then :
21119 gl_cv_decl_null_works=yes
21120else
21121 gl_cv_decl_null_works=no
21122fi
21123rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21124fi
21125{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
21126$as_echo "$gl_cv_decl_null_works" >&6; }
21127 if test $gl_cv_decl_null_works = no; then
21128 REPLACE_NULL=1
21129 STDDEF_H=stddef.h
21130 fi
a451f14b 21131
3e0be4ab
GM
21132 if test -n "$STDDEF_H"; then
21133 GL_GENERATE_STDDEF_H_TRUE=
21134 GL_GENERATE_STDDEF_H_FALSE='#'
21135else
21136 GL_GENERATE_STDDEF_H_TRUE='#'
21137 GL_GENERATE_STDDEF_H_FALSE=
21138fi
a451f14b 21139
3e0be4ab 21140 if test -n "$STDDEF_H"; then
743c80a7 21141
743c80a7
PE
21142
21143
21144
21145
21146
21147
21148
3e0be4ab
GM
21149 if test $gl_cv_have_include_next = yes; then
21150 gl_cv_next_stddef_h='<'stddef.h'>'
21151 else
21152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
21153$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
a9bec17c 21154if test "${gl_cv_next_stddef_h+set}" = set; then :
3e0be4ab
GM
21155 $as_echo_n "(cached) " >&6
21156else
743c80a7 21157
3e0be4ab
GM
21158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21159/* end confdefs.h. */
21160#include <stddef.h>
743c80a7 21161
3e0be4ab
GM
21162_ACEOF
21163 case "$host_os" in
21164 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21165 *) gl_absname_cpp="$ac_cpp" ;;
21166 esac
b0415a03
GM
21167
21168 case "$host_os" in
21169 mingw*)
21170 gl_dirsep_regex='[/\\]'
21171 ;;
21172 *)
21173 gl_dirsep_regex='/'
21174 ;;
21175 esac
21176
2b1928b8
GM
21177 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stddef.h|{
21178 s|.*"\(.*'"${gl_dirsep_regex}"'stddef.h\)".*|\1|
21179 s|^/[^/]|//&|
b0415a03
GM
21180 p
21181 q
21182 }'
3e0be4ab 21183 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 21184 sed -n "$gl_absolute_header_sed"`'"'
6d153f56 21185
743c80a7 21186
3e0be4ab
GM
21187fi
21188{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
21189$as_echo "$gl_cv_next_stddef_h" >&6; }
21190 fi
21191 NEXT_STDDEF_H=$gl_cv_next_stddef_h
743c80a7 21192
3e0be4ab
GM
21193 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21194 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21195 gl_next_as_first_directive='<'stddef.h'>'
21196 else
21197 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21198 gl_next_as_first_directive=$gl_cv_next_stddef_h
21199 fi
21200 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
743c80a7
PE
21201
21202
067d23c9 21203
067d23c9 21204
3e0be4ab 21205 fi
067d23c9 21206
067d23c9 21207
067d23c9
KY
21208
21209
067d23c9 21210
067d23c9 21211
067d23c9 21212
067d23c9 21213
067d23c9 21214
067d23c9 21215
067d23c9 21216
067d23c9 21217
067d23c9 21218
3e0be4ab
GM
21219 if test $gl_cv_have_include_next = yes; then
21220 gl_cv_next_stdio_h='<'stdio.h'>'
21221 else
21222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
21223$as_echo_n "checking absolute name of <stdio.h>... " >&6; }
a9bec17c 21224if test "${gl_cv_next_stdio_h+set}" = set; then :
067d23c9
KY
21225 $as_echo_n "(cached) " >&6
21226else
3e0be4ab
GM
21227
21228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 21229/* end confdefs.h. */
3e0be4ab 21230#include <stdio.h>
067d23c9 21231
067d23c9 21232_ACEOF
3e0be4ab
GM
21233 case "$host_os" in
21234 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21235 *) gl_absname_cpp="$ac_cpp" ;;
21236 esac
b0415a03
GM
21237
21238 case "$host_os" in
21239 mingw*)
21240 gl_dirsep_regex='[/\\]'
21241 ;;
21242 *)
21243 gl_dirsep_regex='/'
21244 ;;
21245 esac
21246
2b1928b8
GM
21247 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdio.h|{
21248 s|.*"\(.*'"${gl_dirsep_regex}"'stdio.h\)".*|\1|
21249 s|^/[^/]|//&|
b0415a03
GM
21250 p
21251 q
21252 }'
3e0be4ab 21253 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 21254 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
21255
21256
067d23c9 21257fi
3e0be4ab
GM
21258{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
21259$as_echo "$gl_cv_next_stdio_h" >&6; }
21260 fi
21261 NEXT_STDIO_H=$gl_cv_next_stdio_h
067d23c9 21262
3e0be4ab
GM
21263 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21264 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21265 gl_next_as_first_directive='<'stdio.h'>'
21266 else
21267 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21268 gl_next_as_first_directive=$gl_cv_next_stdio_h
21269 fi
21270 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
067d23c9 21271
067d23c9 21272
067d23c9 21273
067d23c9 21274
067d23c9 21275
3e0be4ab
GM
21276 GNULIB_FSCANF=1
21277 GNULIB_SCANF=1
21278 GNULIB_FGETC=1
21279 GNULIB_GETC=1
21280 GNULIB_GETCHAR=1
21281 GNULIB_FGETS=1
21282 GNULIB_GETS=1
21283 GNULIB_FREAD=1
067d23c9 21284
067d23c9 21285
3e0be4ab
GM
21286 GNULIB_FPRINTF=1
21287 GNULIB_PRINTF=1
21288 GNULIB_VFPRINTF=1
21289 GNULIB_VPRINTF=1
21290 GNULIB_FPUTC=1
21291 GNULIB_PUTC=1
21292 GNULIB_PUTCHAR=1
21293 GNULIB_FPUTS=1
21294 GNULIB_PUTS=1
21295 GNULIB_FWRITE=1
067d23c9 21296
067d23c9 21297
067d23c9
KY
21298
21299
067d23c9 21300
067d23c9
KY
21301
21302
21303
21304
067d23c9 21305
067d23c9 21306
067d23c9 21307
067d23c9 21308
067d23c9 21309
067d23c9 21310
3e0be4ab
GM
21311 if test $gl_cv_have_include_next = yes; then
21312 gl_cv_next_stdlib_h='<'stdlib.h'>'
21313 else
21314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
21315$as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
a9bec17c 21316if test "${gl_cv_next_stdlib_h+set}" = set; then :
067d23c9
KY
21317 $as_echo_n "(cached) " >&6
21318else
067d23c9 21319
3e0be4ab 21320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 21321/* end confdefs.h. */
3e0be4ab 21322#include <stdlib.h>
067d23c9 21323
067d23c9 21324_ACEOF
3e0be4ab
GM
21325 case "$host_os" in
21326 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21327 *) gl_absname_cpp="$ac_cpp" ;;
21328 esac
b0415a03
GM
21329
21330 case "$host_os" in
21331 mingw*)
21332 gl_dirsep_regex='[/\\]'
21333 ;;
21334 *)
21335 gl_dirsep_regex='/'
21336 ;;
21337 esac
21338
2b1928b8
GM
21339 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdlib.h|{
21340 s|.*"\(.*'"${gl_dirsep_regex}"'stdlib.h\)".*|\1|
21341 s|^/[^/]|//&|
b0415a03
GM
21342 p
21343 q
21344 }'
3e0be4ab 21345 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 21346 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
21347
21348
067d23c9 21349fi
3e0be4ab
GM
21350{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
21351$as_echo "$gl_cv_next_stdlib_h" >&6; }
21352 fi
21353 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
21354
21355 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21356 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21357 gl_next_as_first_directive='<'stdlib.h'>'
21358 else
21359 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21360 gl_next_as_first_directive=$gl_cv_next_stdlib_h
21361 fi
21362 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
21363
21364
21365
21366
21367
21368
21369
21370
21371
21372 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
21373
21374
21375
21376
067d23c9 21377
067d23c9 21378
067d23c9 21379
3e0be4ab 21380$as_echo "#define my_strftime nstrftime" >>confdefs.h
067d23c9 21381
067d23c9 21382
067d23c9 21383
067d23c9 21384
067d23c9
KY
21385
21386
067d23c9 21387
369e19fc 21388
3e0be4ab
GM
21389 if test "$ac_cv_have_decl_strtoimax" != yes; then
21390 HAVE_DECL_STRTOIMAX=0
3e0be4ab 21391 fi
067d23c9 21392
369e19fc 21393if test $ac_cv_func_strtoimax = no; then
067d23c9 21394
067d23c9 21395
067d23c9
KY
21396
21397
067d23c9 21398
067d23c9 21399
067d23c9 21400
067d23c9 21401
3e0be4ab 21402 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
067d23c9 21403
067d23c9 21404
3e0be4ab 21405 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
a9bec17c 21406if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
3e0be4ab 21407 ac_have_decl=1
067d23c9 21408else
3e0be4ab 21409 ac_have_decl=0
067d23c9
KY
21410fi
21411
3e0be4ab
GM
21412cat >>confdefs.h <<_ACEOF
21413#define HAVE_DECL_STRTOLL $ac_have_decl
21414_ACEOF
067d23c9 21415
067d23c9 21416
067d23c9 21417
067d23c9
KY
21418fi
21419
067d23c9 21420
067d23c9 21421
067d23c9 21422
067d23c9 21423
3e0be4ab
GM
21424 GNULIB_STRTOIMAX=1
21425
21426
21427
067d23c9 21428
067d23c9 21429
067d23c9 21430
3e0be4ab
GM
21431
21432
369e19fc 21433
3e0be4ab
GM
21434 if test "$ac_cv_have_decl_strtoumax" != yes; then
21435 HAVE_DECL_STRTOUMAX=0
3e0be4ab 21436 fi
067d23c9 21437
369e19fc 21438if test $ac_cv_func_strtoumax = no; then
067d23c9 21439
067d23c9 21440
067d23c9 21441
067d23c9 21442
067d23c9 21443
067d23c9 21444
3e0be4ab
GM
21445
21446
21447 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
21448
21449
21450 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
a9bec17c 21451if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
3e0be4ab 21452 ac_have_decl=1
067d23c9 21453else
3e0be4ab 21454 ac_have_decl=0
067d23c9 21455fi
3e0be4ab
GM
21456
21457cat >>confdefs.h <<_ACEOF
21458#define HAVE_DECL_STRTOULL $ac_have_decl
21459_ACEOF
21460
21461
21462
067d23c9
KY
21463fi
21464
067d23c9 21465
067d23c9 21466
3e0be4ab
GM
21467
21468
21469 GNULIB_STRTOUMAX=1
21470
21471
21472
21473
21474
21475
21476
21477 if test $ac_cv_func_symlink = no; then
21478 HAVE_SYMLINK=0
21479 else
21480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
21481$as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
a9bec17c 21482if test "${gl_cv_func_symlink_works+set}" = set; then :
067d23c9
KY
21483 $as_echo_n "(cached) " >&6
21484else
3e0be4ab
GM
21485 if test "$cross_compiling" = yes; then :
21486 gl_cv_func_symlink_works="guessing no"
21487else
21488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 21489/* end confdefs.h. */
3e0be4ab 21490#include <unistd.h>
067d23c9 21491
067d23c9
KY
21492int
21493main ()
21494{
3e0be4ab
GM
21495int result = 0;
21496 if (!symlink ("a", "conftest.link/"))
21497 result |= 1;
21498 if (symlink ("conftest.f", "conftest.lnk2"))
21499 result |= 2;
21500 else if (!symlink ("a", "conftest.lnk2/"))
21501 result |= 4;
21502 return result;
21503
067d23c9
KY
21504 ;
21505 return 0;
21506}
21507_ACEOF
3e0be4ab
GM
21508if ac_fn_c_try_run "$LINENO"; then :
21509 gl_cv_func_symlink_works=yes
067d23c9 21510else
3e0be4ab
GM
21511 gl_cv_func_symlink_works=no
21512fi
21513rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21514 conftest.$ac_objext conftest.beam conftest.$ac_ext
067d23c9
KY
21515fi
21516
3e0be4ab 21517 rm -f conftest.f conftest.link conftest.lnk2
067d23c9 21518fi
3e0be4ab
GM
21519{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
21520$as_echo "$gl_cv_func_symlink_works" >&6; }
21521 if test "$gl_cv_func_symlink_works" != yes; then
21522 REPLACE_SYMLINK=1
21523 fi
21524 fi
067d23c9 21525
3e0be4ab 21526if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
067d23c9
KY
21527
21528
067d23c9 21529
067d23c9 21530
067d23c9 21531
067d23c9 21532
067d23c9 21533
3e0be4ab
GM
21534
21535 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
067d23c9
KY
21536
21537fi
21538
067d23c9 21539
067d23c9 21540
067d23c9 21541
067d23c9 21542
3e0be4ab 21543 GNULIB_SYMLINK=1
067d23c9 21544
067d23c9 21545
067d23c9 21546
067d23c9 21547
067d23c9 21548
067d23c9 21549
067d23c9 21550
067d23c9 21551
067d23c9 21552
067d23c9 21553
067d23c9 21554
067d23c9 21555
067d23c9 21556
067d23c9
KY
21557
21558
21559
21560
21561
21562
21563
3e0be4ab
GM
21564
21565 if test $gl_cv_have_include_next = yes; then
21566 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
21567 else
21568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
21569$as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
a9bec17c 21570if test "${gl_cv_next_sys_stat_h+set}" = set; then :
067d23c9
KY
21571 $as_echo_n "(cached) " >&6
21572else
3e0be4ab
GM
21573
21574 if test $ac_cv_header_sys_stat_h = yes; then
21575
21576
21577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 21578/* end confdefs.h. */
3e0be4ab 21579#include <sys/stat.h>
067d23c9 21580
067d23c9 21581_ACEOF
3e0be4ab
GM
21582 case "$host_os" in
21583 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21584 *) gl_absname_cpp="$ac_cpp" ;;
21585 esac
b0415a03
GM
21586
21587 case "$host_os" in
21588 mingw*)
21589 gl_dirsep_regex='[/\\]'
21590 ;;
21591 *)
21592 gl_dirsep_regex='/'
21593 ;;
21594 esac
21595
2b1928b8
GM
21596 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'sys/stat.h|{
21597 s|.*"\(.*'"${gl_dirsep_regex}"'sys/stat.h\)".*|\1|
21598 s|^/[^/]|//&|
b0415a03
GM
21599 p
21600 q
21601 }'
3e0be4ab 21602 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 21603 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
21604 else
21605 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
21606 fi
067d23c9 21607
067d23c9
KY
21608
21609fi
3e0be4ab
GM
21610{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
21611$as_echo "$gl_cv_next_sys_stat_h" >&6; }
21612 fi
21613 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
067d23c9 21614
3e0be4ab
GM
21615 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21616 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21617 gl_next_as_first_directive='<'sys/stat.h'>'
21618 else
21619 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21620 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
21621 fi
21622 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
067d23c9 21623
3e0be4ab
GM
21624
21625
21626
21627
2b1928b8
GM
21628
21629
3e0be4ab
GM
21630 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
21631 #include <sys/stat.h>
21632"
a9bec17c 21633if test "x$ac_cv_type_nlink_t" = x""yes; then :
067d23c9
KY
21634
21635else
067d23c9 21636
3e0be4ab 21637$as_echo "#define nlink_t int" >>confdefs.h
067d23c9
KY
21638
21639fi
21640
067d23c9 21641
067d23c9 21642
3e0be4ab
GM
21643
21644
21645
21646
21647
21648
21649
21650
21651
21652
21653
21654
21655 if test $ac_cv_have_decl_localtime_r = no; then
21656 HAVE_DECL_LOCALTIME_R=0
21657 fi
21658
21659
21660 if test $ac_cv_func_localtime_r = yes; then
21661 HAVE_LOCALTIME_R=1
21662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
21663$as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
a9bec17c 21664if test "${gl_cv_time_r_posix+set}" = set; then :
067d23c9
KY
21665 $as_echo_n "(cached) " >&6
21666else
21667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21668/* end confdefs.h. */
067d23c9 21669#include <time.h>
067d23c9
KY
21670int
21671main ()
21672{
3e0be4ab
GM
21673/* We don't need to append 'restrict's to the argument types,
21674 even though the POSIX signature has the 'restrict's,
21675 since C99 says they can't affect type compatibility. */
21676 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
21677 if (ptr) return 0;
21678 /* Check the return type is a pointer.
21679 On HP-UX 10 it is 'int'. */
21680 *localtime_r (0, 0);
067d23c9
KY
21681 ;
21682 return 0;
21683}
3e0be4ab 21684
067d23c9
KY
21685_ACEOF
21686if ac_fn_c_try_compile "$LINENO"; then :
3e0be4ab 21687 gl_cv_time_r_posix=yes
067d23c9 21688else
3e0be4ab 21689 gl_cv_time_r_posix=no
067d23c9
KY
21690fi
21691rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
067d23c9 21692
3e0be4ab
GM
21693fi
21694{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
21695$as_echo "$gl_cv_time_r_posix" >&6; }
21696 if test $gl_cv_time_r_posix = yes; then
21697 REPLACE_LOCALTIME_R=0
21698 else
21699 REPLACE_LOCALTIME_R=1
067d23c9 21700 fi
3e0be4ab
GM
21701 else
21702 HAVE_LOCALTIME_R=0
067d23c9 21703 fi
067d23c9 21704
3e0be4ab 21705if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
067d23c9 21706
067d23c9 21707
067d23c9 21708
067d23c9
KY
21709
21710
067d23c9 21711
067d23c9
KY
21712
21713
3e0be4ab 21714 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
067d23c9 21715
3e0be4ab
GM
21716
21717 :
067d23c9
KY
21718
21719fi
21720
067d23c9 21721
067d23c9 21722
067d23c9 21723
067d23c9 21724
3e0be4ab 21725 GNULIB_TIME_R=1
067d23c9 21726
067d23c9 21727
067d23c9 21728
067d23c9 21729
067d23c9 21730
067d23c9 21731
067d23c9 21732
067d23c9 21733
067d23c9 21734
067d23c9 21735
067d23c9 21736
3e0be4ab
GM
21737
21738
21739
21740
21741
21742
21743
21744
21745 if test $gl_cv_have_include_next = yes; then
21746 gl_cv_next_unistd_h='<'unistd.h'>'
21747 else
21748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
21749$as_echo_n "checking absolute name of <unistd.h>... " >&6; }
a9bec17c 21750if test "${gl_cv_next_unistd_h+set}" = set; then :
067d23c9
KY
21751 $as_echo_n "(cached) " >&6
21752else
067d23c9 21753
3e0be4ab
GM
21754 if test $ac_cv_header_unistd_h = yes; then
21755
21756
21757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21758/* end confdefs.h. */
21759#include <unistd.h>
067d23c9 21760
067d23c9 21761_ACEOF
3e0be4ab
GM
21762 case "$host_os" in
21763 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21764 *) gl_absname_cpp="$ac_cpp" ;;
21765 esac
b0415a03
GM
21766
21767 case "$host_os" in
21768 mingw*)
21769 gl_dirsep_regex='[/\\]'
21770 ;;
21771 *)
21772 gl_dirsep_regex='/'
21773 ;;
21774 esac
21775
2b1928b8
GM
21776 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'unistd.h|{
21777 s|.*"\(.*'"${gl_dirsep_regex}"'unistd.h\)".*|\1|
21778 s|^/[^/]|//&|
b0415a03
GM
21779 p
21780 q
21781 }'
3e0be4ab 21782 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
b0415a03 21783 sed -n "$gl_absolute_header_sed"`'"'
3e0be4ab
GM
21784 else
21785 gl_cv_next_unistd_h='<'unistd.h'>'
21786 fi
067d23c9 21787
067d23c9 21788
067d23c9 21789fi
3e0be4ab
GM
21790{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
21791$as_echo "$gl_cv_next_unistd_h" >&6; }
21792 fi
21793 NEXT_UNISTD_H=$gl_cv_next_unistd_h
067d23c9 21794
3e0be4ab
GM
21795 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21796 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21797 gl_next_as_first_directive='<'unistd.h'>'
21798 else
21799 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21800 gl_next_as_first_directive=$gl_cv_next_unistd_h
21801 fi
21802 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
067d23c9 21803
067d23c9 21804
067d23c9 21805
067d23c9 21806
3e0be4ab
GM
21807 if test $ac_cv_header_unistd_h = yes; then
21808 HAVE_UNISTD_H=1
21809 else
21810 HAVE_UNISTD_H=0
21811 fi
067d23c9 21812
067d23c9 21813
067d23c9 21814
067d23c9 21815
b0415a03
GM
21816
21817
3e0be4ab
GM
21818 gl_gnulib_enabled_dosname=false
21819 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
a0a61e58 21820 gl_gnulib_enabled_pathmax=false
3e0be4ab
GM
21821 gl_gnulib_enabled_sigprocmask=false
21822 gl_gnulib_enabled_stat=false
21823 gl_gnulib_enabled_strtoll=false
21824 gl_gnulib_enabled_strtoull=false
21825 gl_gnulib_enabled_verify=false
21826 func_gl_gnulib_m4code_dosname ()
21827 {
21828 if ! $gl_gnulib_enabled_dosname; then
21829 gl_gnulib_enabled_dosname=true
21830 fi
067d23c9 21831 }
3e0be4ab
GM
21832 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
21833 {
21834 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
067d23c9 21835
067d23c9 21836
3e0be4ab
GM
21837 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
21838 fi
21839 }
a0a61e58
GM
21840 func_gl_gnulib_m4code_pathmax ()
21841 {
21842 if ! $gl_gnulib_enabled_pathmax; then
21843
21844
21845
21846 gl_gnulib_enabled_pathmax=true
21847 fi
21848 }
3e0be4ab
GM
21849 func_gl_gnulib_m4code_sigprocmask ()
21850 {
21851 if ! $gl_gnulib_enabled_sigprocmask; then
21852
21853
21854
21855 if test $gl_cv_type_sigset_t = yes; then
21856 ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
a9bec17c 21857if test "x$ac_cv_func_sigprocmask" = x""yes; then :
3e0be4ab 21858 gl_cv_func_sigprocmask=1
067d23c9
KY
21859fi
21860
3e0be4ab
GM
21861 fi
21862 if test -z "$gl_cv_func_sigprocmask"; then
21863 HAVE_POSIX_SIGNALBLOCKING=0
21864 fi
21865
21866if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
21867
21868
067d23c9 21869
067d23c9 21870
067d23c9 21871
067d23c9 21872
067d23c9 21873
067d23c9 21874
3e0be4ab
GM
21875 gl_LIBOBJS="$gl_LIBOBJS sigprocmask.$ac_objext"
21876
2b1928b8
GM
21877
21878
21879
067d23c9
KY
21880fi
21881
21882
3e0be4ab
GM
21883
21884
21885
21886 GNULIB_SIGPROCMASK=1
21887
21888
21889
21890
21891
21892 gl_gnulib_enabled_sigprocmask=true
21893 fi
21894 }
21895 func_gl_gnulib_m4code_stat ()
21896 {
21897 if ! $gl_gnulib_enabled_stat; then
21898
21899
21900
21901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
21902$as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
a9bec17c 21903if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
067d23c9 21904 $as_echo_n "(cached) " >&6
3e0be4ab
GM
21905else
21906 if test "$cross_compiling" = yes; then :
21907 case $host_os in
21908 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
21909 *) gl_cv_func_stat_dir_slash="guessing yes";;
21910 esac
067d23c9
KY
21911else
21912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21913/* end confdefs.h. */
3e0be4ab
GM
21914#include <sys/stat.h>
21915
067d23c9
KY
21916int
21917main ()
21918{
3e0be4ab 21919struct stat st; return stat (".", &st) != stat ("./", &st);
067d23c9
KY
21920 ;
21921 return 0;
21922}
21923_ACEOF
3e0be4ab
GM
21924if ac_fn_c_try_run "$LINENO"; then :
21925 gl_cv_func_stat_dir_slash=yes
067d23c9 21926else
3e0be4ab 21927 gl_cv_func_stat_dir_slash=no
067d23c9 21928fi
3e0be4ab
GM
21929rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21930 conftest.$ac_objext conftest.beam conftest.$ac_ext
067d23c9 21931fi
067d23c9
KY
21932
21933fi
3e0be4ab
GM
21934{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
21935$as_echo "$gl_cv_func_stat_dir_slash" >&6; }
21936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
21937$as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
a9bec17c 21938if test "${gl_cv_func_stat_file_slash+set}" = set; then :
067d23c9 21939 $as_echo_n "(cached) " >&6
3e0be4ab
GM
21940else
21941 touch conftest.tmp
21942 # Assume that if we have lstat, we can also check symlinks.
21943 if test $ac_cv_func_lstat = yes; then
21944 ln -s conftest.tmp conftest.lnk
21945 fi
21946 if test "$cross_compiling" = yes; then :
21947 gl_cv_func_stat_file_slash="guessing no"
067d23c9
KY
21948else
21949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21950/* end confdefs.h. */
3e0be4ab
GM
21951#include <sys/stat.h>
21952
067d23c9
KY
21953int
21954main ()
21955{
3e0be4ab
GM
21956int result = 0;
21957 struct stat st;
21958 if (!stat ("conftest.tmp/", &st))
21959 result |= 1;
21960#if HAVE_LSTAT
21961 if (!stat ("conftest.lnk/", &st))
21962 result |= 2;
21963#endif
21964 return result;
21965
067d23c9
KY
21966 ;
21967 return 0;
21968}
21969_ACEOF
3e0be4ab
GM
21970if ac_fn_c_try_run "$LINENO"; then :
21971 gl_cv_func_stat_file_slash=yes
067d23c9 21972else
3e0be4ab 21973 gl_cv_func_stat_file_slash=no
067d23c9 21974fi
3e0be4ab
GM
21975rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21976 conftest.$ac_objext conftest.beam conftest.$ac_ext
067d23c9 21977fi
067d23c9 21978
3e0be4ab
GM
21979 rm -f conftest.tmp conftest.lnk
21980fi
21981{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
21982$as_echo "$gl_cv_func_stat_file_slash" >&6; }
21983 case $gl_cv_func_stat_dir_slash in
21984 *no) REPLACE_STAT=1
067d23c9 21985
3e0be4ab
GM
21986$as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
21987;;
21988 esac
21989 case $gl_cv_func_stat_file_slash in
21990 *no) REPLACE_STAT=1
067d23c9 21991
3e0be4ab
GM
21992$as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
21993;;
21994 esac
067d23c9 21995
3e0be4ab 21996if test $REPLACE_STAT = 1; then
067d23c9 21997
067d23c9 21998
067d23c9 21999
067d23c9 22000
067d23c9
KY
22001
22002
22003
067d23c9 22004
3e0be4ab 22005 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
067d23c9 22006
067d23c9 22007
3e0be4ab
GM
22008
22009 :
22010
22011fi
067d23c9
KY
22012
22013
067d23c9
KY
22014
22015
22016
3e0be4ab 22017 GNULIB_STAT=1
067d23c9
KY
22018
22019
22020
22021
22022
3e0be4ab 22023 gl_gnulib_enabled_stat=true
8c069cc7 22024 if test $REPLACE_STAT = 1; then
3e0be4ab
GM
22025 func_gl_gnulib_m4code_dosname
22026 fi
a0a61e58
GM
22027 if test $REPLACE_STAT = 1; then
22028 func_gl_gnulib_m4code_pathmax
22029 fi
8c069cc7 22030 if test $REPLACE_STAT = 1; then
3e0be4ab
GM
22031 func_gl_gnulib_m4code_verify
22032 fi
22033 fi
22034 }
22035 func_gl_gnulib_m4code_strtoll ()
22036 {
22037 if ! $gl_gnulib_enabled_strtoll; then
067d23c9
KY
22038
22039
22040
3e0be4ab
GM
22041 if test "$ac_cv_type_long_long_int" = yes; then
22042 for ac_func in strtoll
22043do :
22044 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
a9bec17c 22045if test "x$ac_cv_func_strtoll" = x""yes; then :
3e0be4ab
GM
22046 cat >>confdefs.h <<_ACEOF
22047#define HAVE_STRTOLL 1
22048_ACEOF
067d23c9 22049
3e0be4ab
GM
22050fi
22051done
067d23c9 22052
3e0be4ab
GM
22053 if test $ac_cv_func_strtoll = no; then
22054 HAVE_STRTOLL=0
22055 fi
22056 fi
067d23c9 22057
3e0be4ab 22058if test $HAVE_STRTOLL = 0; then
067d23c9
KY
22059
22060
22061
22062
22063
22064
067d23c9
KY
22065
22066
3e0be4ab 22067 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
067d23c9
KY
22068
22069
3e0be4ab 22070 :
067d23c9 22071
d6a003a8 22072fi
067d23c9
KY
22073
22074
22075
22076
22077
3e0be4ab 22078 GNULIB_STRTOLL=1
067d23c9
KY
22079
22080
22081
22082
22083
3e0be4ab
GM
22084 gl_gnulib_enabled_strtoll=true
22085 fi
22086 }
22087 func_gl_gnulib_m4code_strtoull ()
22088 {
22089 if ! $gl_gnulib_enabled_strtoull; then
067d23c9 22090
067d23c9
KY
22091
22092
3e0be4ab
GM
22093 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
22094 for ac_func in strtoull
22095do :
22096 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
a9bec17c 22097if test "x$ac_cv_func_strtoull" = x""yes; then :
3e0be4ab
GM
22098 cat >>confdefs.h <<_ACEOF
22099#define HAVE_STRTOULL 1
067d23c9
KY
22100_ACEOF
22101
d6a003a8 22102fi
3e0be4ab 22103done
067d23c9 22104
3e0be4ab
GM
22105 if test $ac_cv_func_strtoull = no; then
22106 HAVE_STRTOULL=0
22107 fi
22108 fi
067d23c9 22109
3e0be4ab 22110if test $HAVE_STRTOULL = 0; then
067d23c9 22111
067d23c9 22112
067d23c9 22113
067d23c9 22114
067d23c9
KY
22115
22116
22117
22118
3e0be4ab 22119 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
067d23c9 22120
067d23c9 22121
3e0be4ab 22122 :
067d23c9 22123
3e0be4ab 22124fi
067d23c9 22125
067d23c9 22126
067d23c9 22127
067d23c9 22128
067d23c9 22129
3e0be4ab 22130 GNULIB_STRTOULL=1
067d23c9
KY
22131
22132
067d23c9
KY
22133
22134
3e0be4ab
GM
22135
22136 gl_gnulib_enabled_strtoull=true
22137 fi
22138 }
22139 func_gl_gnulib_m4code_verify ()
22140 {
22141 if ! $gl_gnulib_enabled_verify; then
22142 gl_gnulib_enabled_verify=true
22143 fi
22144 }
22145 if test $REPLACE_GETOPT = 1; then
22146 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
22147 fi
22148 if test $REPLACE_LSTAT = 1; then
22149 func_gl_gnulib_m4code_dosname
22150 fi
22151 if test $REPLACE_LSTAT = 1; then
22152 func_gl_gnulib_m4code_stat
22153 fi
22154 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22155 func_gl_gnulib_m4code_sigprocmask
22156 fi
22157 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22158 func_gl_gnulib_m4code_stat
22159 fi
369e19fc 22160 if test $ac_cv_func_strtoimax = no; then
3e0be4ab
GM
22161 func_gl_gnulib_m4code_verify
22162 fi
369e19fc 22163 if test $ac_cv_func_strtoimax = no && test $ac_cv_type_long_long_int = yes; then
3e0be4ab
GM
22164 func_gl_gnulib_m4code_strtoll
22165 fi
369e19fc 22166 if test $ac_cv_func_strtoumax = no; then
3e0be4ab
GM
22167 func_gl_gnulib_m4code_verify
22168 fi
369e19fc 22169 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
3e0be4ab
GM
22170 func_gl_gnulib_m4code_strtoull
22171 fi
22172
22173 if $gl_gnulib_enabled_dosname; then
22174 gl_GNULIB_ENABLED_dosname_TRUE=
22175 gl_GNULIB_ENABLED_dosname_FALSE='#'
067d23c9 22176else
3e0be4ab
GM
22177 gl_GNULIB_ENABLED_dosname_TRUE='#'
22178 gl_GNULIB_ENABLED_dosname_FALSE=
067d23c9
KY
22179fi
22180
3e0be4ab
GM
22181 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
22182 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
22183 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
22184else
22185 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
22186 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
22187fi
067d23c9 22188
a0a61e58
GM
22189 if $gl_gnulib_enabled_pathmax; then
22190 gl_GNULIB_ENABLED_pathmax_TRUE=
22191 gl_GNULIB_ENABLED_pathmax_FALSE='#'
22192else
22193 gl_GNULIB_ENABLED_pathmax_TRUE='#'
22194 gl_GNULIB_ENABLED_pathmax_FALSE=
22195fi
22196
3e0be4ab
GM
22197 if $gl_gnulib_enabled_sigprocmask; then
22198 gl_GNULIB_ENABLED_sigprocmask_TRUE=
22199 gl_GNULIB_ENABLED_sigprocmask_FALSE='#'
22200else
22201 gl_GNULIB_ENABLED_sigprocmask_TRUE='#'
22202 gl_GNULIB_ENABLED_sigprocmask_FALSE=
22203fi
067d23c9 22204
3e0be4ab
GM
22205 if $gl_gnulib_enabled_stat; then
22206 gl_GNULIB_ENABLED_stat_TRUE=
22207 gl_GNULIB_ENABLED_stat_FALSE='#'
22208else
22209 gl_GNULIB_ENABLED_stat_TRUE='#'
22210 gl_GNULIB_ENABLED_stat_FALSE=
22211fi
067d23c9 22212
3e0be4ab
GM
22213 if $gl_gnulib_enabled_strtoll; then
22214 gl_GNULIB_ENABLED_strtoll_TRUE=
22215 gl_GNULIB_ENABLED_strtoll_FALSE='#'
22216else
22217 gl_GNULIB_ENABLED_strtoll_TRUE='#'
22218 gl_GNULIB_ENABLED_strtoll_FALSE=
22219fi
067d23c9 22220
3e0be4ab
GM
22221 if $gl_gnulib_enabled_strtoull; then
22222 gl_GNULIB_ENABLED_strtoull_TRUE=
22223 gl_GNULIB_ENABLED_strtoull_FALSE='#'
067d23c9 22224else
3e0be4ab
GM
22225 gl_GNULIB_ENABLED_strtoull_TRUE='#'
22226 gl_GNULIB_ENABLED_strtoull_FALSE=
067d23c9
KY
22227fi
22228
3e0be4ab
GM
22229 if $gl_gnulib_enabled_verify; then
22230 gl_GNULIB_ENABLED_verify_TRUE=
22231 gl_GNULIB_ENABLED_verify_FALSE='#'
22232else
22233 gl_GNULIB_ENABLED_verify_TRUE='#'
22234 gl_GNULIB_ENABLED_verify_FALSE=
067d23c9
KY
22235fi
22236
3e0be4ab 22237 # End of code from modules
067d23c9
KY
22238
22239
22240
22241
22242
22243
067d23c9 22244
067d23c9 22245
067d23c9 22246
3e0be4ab
GM
22247 gltests_libdeps=
22248 gltests_ltlibdeps=
067d23c9 22249
067d23c9 22250
067d23c9 22251
067d23c9 22252
067d23c9
KY
22253
22254
067d23c9
KY
22255
22256
3e0be4ab
GM
22257
22258 gl_source_base='tests'
22259 gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
22260
22261 gl_module_indicator_condition=$gltests_WITNESS
22262
22263
22264
22265
22266
22267
22268
067d23c9
KY
22269
22270
22271
3e0be4ab
GM
22272 LIBGNU_LIBDEPS="$gl_libdeps"
22273
22274 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
22275
067d23c9
KY
22276
22277
22278case "$opsys" in
22279 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
22280
22281 darwin)
22282 ## The -headerpad option tells ld (see man page) to leave room at the
22283 ## end of the header for adding load commands. Needed for dumping.
22284 ## 0x690 is the total size of 30 segment load commands (at 56
22285 ## each); under Cocoa 31 commands are required.
22286 if test "$HAVE_NS" = "yes"; then
22287 libs_nsgui="-framework AppKit"
22288 headerpad_extra=6C8
22289 else
22290 libs_nsgui=
22291 headerpad_extra=690
22292 fi
85cf5029 22293 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
067d23c9
KY
22294
22295 ## This is here because src/Makefile.in did some extra fiddling around
22296 ## with LD_SWITCH_SYSTEM. The cpp logic was:
22297 ## #ifndef LD_SWITCH_SYSTEM
22298 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
22299 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
22300 ## not using gcc, darwin system not on an alpha (ie darwin, since
22301 ## darwin + alpha does not occur).
22302 ## Because this was done in src/Makefile.in, the resulting part of
22303 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
22304 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
22305 ## rather than LD_SWITCH_SYSTEM.
22306 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
22307 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
22308 ;;
22309
22310 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
22311 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
22312 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
22313 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
22314 ## had different values in configure (in ac_link) and src/Makefile.in.
22315 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
22316 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
22317
22318 *) LD_SWITCH_SYSTEM_TEMACS= ;;
22319esac
22320
22321if test "$NS_IMPL_GNUSTEP" = "yes"; then
22322 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
22323fi
22324
22325
22326
22327
22328LD_FIRSTFLAG=
22329ORDINARY_LINK=
22330case "$opsys" in
22331 ## gnu: GNU needs its own crt0.
22332 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
22333
22334 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
22335 ## library search parth, i.e. it won't search /usr/lib for libc and
22336 ## friends. Using -nostartfiles instead avoids this problem, and
22337 ## will also work on earlier NetBSD releases.
22338 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
22339
22340 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
22341 ## MkLinux/LinuxPPC needs this.
22342 ## ibms390x only supports opsys = gnu-linux so it can be added here.
22343 gnu-*)
22344 case "$machine" in
22345 macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;;
22346 esac
22347 ;;
22348esac
22349
22350
22351if test "x$ORDINARY_LINK" = "xyes"; then
22352
22353 LD_FIRSTFLAG=""
22354
22355$as_echo "#define ORDINARY_LINK 1" >>confdefs.h
22356
22357
22358## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
22359## freebsd, gnu-* not on macppc|ibms390x.
22360elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
22361
22362 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
22363 ## places that are difficult to figure out at make time. Fortunately,
22364 ## these same versions allow you to pass arbitrary flags on to the
22365 ## linker, so there is no reason not to use it as a linker.
22366 ##
22367 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
22368 ## searching for libraries in its internal directories, so we have to
22369 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
22370 LD_FIRSTFLAG="-nostdlib"
22371fi
22372
22373## FIXME? What setting of EDIT_LDFLAGS should this have?
22374test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
22375
22376
22377
22378
22379## FIXME? The logic here is not precisely the same as that above.
22380## There is no check here for a pre-defined LD_FIRSTFLAG.
22381## Should we only be setting LIB_GCC if LD ~ -nostdlib?
22382LIB_GCC=
22383if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
22384
22385 case "$opsys" in
22386 freebsd|netbsd|openbsd) LIB_GCC= ;;
22387
22388 gnu-*)
22389 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
22390 ## build on ARM EABI under GNU/Linux. (Bug#5518)
d6a003a8
AS
22391 case $host_cpu in
22392 arm*)
067d23c9 22393 LIB_GCC="-lgcc_s"
d6a003a8
AS
22394 ;;
22395 *)
067d23c9
KY
22396 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
22397 ## immediately undefine it again and redefine it to empty.
22398 ## Was the C_SWITCH_X_SITE part really necessary?
22399## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
22400 LIB_GCC=
d6a003a8
AS
22401 ;;
22402 esac
067d23c9
KY
22403 ;;
22404
22405 ## Ask GCC where to find libgcc.a.
22406 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
22407 esac
22408fi
22409
22410
067d23c9
KY
22411## If we're using X11/GNUstep, define some consequences.
22412if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
22413
22414$as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
22415
22416
22417$as_echo "#define HAVE_MOUSE 1" >>confdefs.h
22418
067d23c9
KY
22419fi
22420
22421
22422
22423
067d23c9
KY
22424#### Report on what we decided to do.
22425#### Report GTK as a toolkit, even if it doesn't use Xt.
22426#### It makes printing result more understandable as using GTK sets
22427#### toolkit_scroll_bars to yes by default.
22428if test "${HAVE_GTK}" = "yes"; then
22429 USE_X_TOOLKIT=GTK
22430fi
22431
2b7f50d8
AS
22432and_machfile=
22433if test -n "$machfile"; then
22434 and_machfile=" and \`${machfile}'"
22435fi
22436
067d23c9
KY
22437echo "
22438Configured for \`${canonical}'.
22439
22440 Where should the build process find the source code? ${srcdir}
22441 What operating system and machine description files should Emacs use?
2b7f50d8 22442 \`${opsysfile}'${and_machfile}
067d23c9
KY
22443 What compiler should emacs be built with? ${CC} ${CFLAGS}
22444 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
22445 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
22446 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
22447 What window system should Emacs use? ${window_system}
22448 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
22449
22450if test -n "${x_includes}"; then
22451echo " Where do we find X Windows header files? ${x_includes}"
22452else
22453echo " Where do we find X Windows header files? Standard dirs"
22454fi
22455if test -n "${x_libraries}"; then
22456echo " Where do we find X Windows libraries? ${x_libraries}"
22457else
22458echo " Where do we find X Windows libraries? Standard dirs"
22459fi
22460
22461echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
22462echo " Does Emacs use -lXpm? ${HAVE_XPM}"
22463echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
22464echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
22465echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
22466echo " Does Emacs use -lpng? ${HAVE_PNG}"
22467echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
22468echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
22469
22470echo " Does Emacs use -lgpm? ${HAVE_GPM}"
22471echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
22472echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
f527bd02 22473echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
067d23c9 22474echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
27f5a136 22475echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
067d23c9
KY
22476echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
22477
22478echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
22479echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
22480echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
22481echo " Does Emacs use -lxft? ${HAVE_XFT}"
22482
22483echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
22484echo
22485
eb39a72d
GM
22486if test -n "${EMACSDATA}"; then
22487 echo " Environment variable EMACSDATA set to: $EMACSDATA"
22488fi
22489if test -n "${EMACSDOC}"; then
22490 echo " Environment variable EMACSDOC set to: $EMACSDOC"
22491fi
22492
067d23c9
KY
22493if test $USE_XASSERTS = yes; then
22494 echo " Compiling with asserts turned on."
22495 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
22496fi
22497
22498echo
22499
22500if test "$HAVE_NS" = "yes"; then
22501 echo
3d0788a9 22502 echo "You must run \"${MAKE-make} install\" in order to test the built application.
067d23c9
KY
22503The installed application will go to nextstep/Emacs.app and can be
22504run or moved from there."
22505 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
22506 echo "The application will be fully self-contained."
22507 else
22508 echo "The lisp resources for the application will be installed under ${prefix}.
3d0788a9 22509You may need to run \"${MAKE-make} install\" with sudo. The application will fail
067d23c9
KY
22510to run if these resources are not installed."
22511 fi
22512 echo
22513fi
22514
22515
22516# Remove any trailing slashes in these variables.
22517test "${prefix}" != NONE &&
22518 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
22519test "${exec_prefix}" != NONE &&
22520 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
22521
56ade35c
GM
22522SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile"
22523
22524ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile"
22525
a877df06 22526
73b78882 22527opt_makefile=test/automated/Makefile
a877df06 22528
56ade35c 22529if test -f $srcdir/${opt_makefile}.in; then
73b78882 22530 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
56ade35c 22531 ac_config_files="$ac_config_files test/automated/Makefile"
a877df06 22532
56ade35c 22533fi
73b78882 22534
56ade35c 22535SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
73b78882 22536
067d23c9 22537
9411886d
PE
22538
22539ac_config_commands="$ac_config_commands mkdirs"
22540
22541
22542ac_config_commands="$ac_config_commands epaths"
22543
22544
22545ac_config_commands="$ac_config_commands gdbinit"
22546
067d23c9
KY
22547
22548cat >confcache <<\_ACEOF
22549# This file is a shell script that caches the results of configure
22550# tests run on this system so they can be shared between configure
22551# scripts and configure runs, see configure's option --config-cache.
22552# It is not useful on other systems. If it contains results you don't
22553# want to keep, you may remove or edit it.
22554#
22555# config.status only pays attention to the cache file if you give it
22556# the --recheck option to rerun configure.
22557#
22558# `ac_cv_env_foo' variables (set or unset) will be overridden when
22559# loading this file, other *unset* `ac_cv_foo' will be assigned the
22560# following values.
22561
22562_ACEOF
22563
22564# The following way of writing the cache mishandles newlines in values,
22565# but we know of no workaround that is simple, portable, and efficient.
22566# So, we kill variables containing newlines.
22567# Ultrix sh set writes to stderr and can't be redirected directly,
22568# and sets the high bit in the cache file unless we assign to the vars.
22569(
22570 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
22571 eval ac_val=\$$ac_var
22572 case $ac_val in #(
22573 *${as_nl}*)
22574 case $ac_var in #(
22575 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
22576$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
22577 esac
22578 case $ac_var in #(
22579 _ | IFS | as_nl) ;; #(
22580 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
22581 *) { eval $ac_var=; unset $ac_var;} ;;
22582 esac ;;
22583 esac
22584 done
22585
22586 (set) 2>&1 |
22587 case $as_nl`(ac_space=' '; set) 2>&1` in #(
22588 *${as_nl}ac_space=\ *)
22589 # `set' does not quote correctly, so add quotes: double-quote
22590 # substitution turns \\\\ into \\, and sed turns \\ into \.
22591 sed -n \
22592 "s/'/'\\\\''/g;
22593 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22594 ;; #(
22595 *)
22596 # `set' quotes correctly as required by POSIX, so do not add quotes.
22597 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
22598 ;;
22599 esac |
22600 sort
22601) |
22602 sed '
22603 /^ac_cv_env_/b end
22604 t clear
22605 :clear
22606 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22607 t end
22608 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22609 :end' >>confcache
22610if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
22611 if test -w "$cache_file"; then
a9bec17c 22612 test "x$cache_file" != "x/dev/null" &&
067d23c9
KY
22613 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
22614$as_echo "$as_me: updating cache $cache_file" >&6;}
a9bec17c 22615 cat confcache >$cache_file
067d23c9
KY
22616 else
22617 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
22618$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
22619 fi
22620fi
22621rm -f confcache
22622
22623test "x$prefix" = xNONE && prefix=$ac_default_prefix
22624# Let make expand exec_prefix.
22625test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22626
22627DEFS=-DHAVE_CONFIG_H
22628
22629ac_libobjs=
22630ac_ltlibobjs=
22631for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22632 # 1. Remove the extension, and $U if already installed.
22633 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
22634 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
22635 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
22636 # will be set to the directory where LIBOBJS objects are built.
22637 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
22638 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
22639done
22640LIBOBJS=$ac_libobjs
22641
22642LTLIBOBJS=$ac_ltlibobjs
22643
22644
743c80a7
PE
22645 if test -n "$EXEEXT"; then
22646 am__EXEEXT_TRUE=
22647 am__EXEEXT_FALSE='#'
22648else
22649 am__EXEEXT_TRUE='#'
22650 am__EXEEXT_FALSE=
22651fi
22652
22653if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
a9bec17c 22654 as_fn_error "conditional \"AMDEP\" was never defined.
743c80a7
PE
22655Usually this means the macro was only invoked conditionally." "$LINENO" 5
22656fi
22657if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
a9bec17c 22658 as_fn_error "conditional \"am__fastdepCC\" was never defined.
743c80a7
PE
22659Usually this means the macro was only invoked conditionally." "$LINENO" 5
22660fi
22661
22662if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
a9bec17c 22663 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
743c80a7
PE
22664Usually this means the macro was only invoked conditionally." "$LINENO" 5
22665fi
4fc2b746 22666if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
a9bec17c 22667 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
4fc2b746
GM
22668Usually this means the macro was only invoked conditionally." "$LINENO" 5
22669fi
743c80a7 22670
4fda9c95 22671if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
a9bec17c 22672 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
4fda9c95
GM
22673Usually this means the macro was only invoked conditionally." "$LINENO" 5
22674fi
6d153f56 22675if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
a9bec17c 22676 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
6d153f56
GM
22677Usually this means the macro was only invoked conditionally." "$LINENO" 5
22678fi
6c051bab 22679if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
a9bec17c 22680 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
6c051bab
GM
22681Usually this means the macro was only invoked conditionally." "$LINENO" 5
22682fi
22683if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
a9bec17c 22684 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
6c051bab
GM
22685Usually this means the macro was only invoked conditionally." "$LINENO" 5
22686fi
6d153f56 22687if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
a9bec17c 22688 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
6d153f56
GM
22689Usually this means the macro was only invoked conditionally." "$LINENO" 5
22690fi
22691if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
a9bec17c 22692 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
6d153f56
GM
22693Usually this means the macro was only invoked conditionally." "$LINENO" 5
22694fi
a0a61e58
GM
22695if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
22696 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
22697Usually this means the macro was only invoked conditionally." "$LINENO" 5
22698fi
3e0be4ab 22699if test -z "${gl_GNULIB_ENABLED_sigprocmask_TRUE}" && test -z "${gl_GNULIB_ENABLED_sigprocmask_FALSE}"; then
a9bec17c 22700 as_fn_error "conditional \"gl_GNULIB_ENABLED_sigprocmask\" was never defined.
3e0be4ab
GM
22701Usually this means the macro was only invoked conditionally." "$LINENO" 5
22702fi
6d153f56 22703if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
a9bec17c 22704 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
6d153f56
GM
22705Usually this means the macro was only invoked conditionally." "$LINENO" 5
22706fi
3e0be4ab 22707if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
a9bec17c 22708 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
3e0be4ab
GM
22709Usually this means the macro was only invoked conditionally." "$LINENO" 5
22710fi
6d153f56 22711if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
a9bec17c 22712 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
6d153f56
GM
22713Usually this means the macro was only invoked conditionally." "$LINENO" 5
22714fi
22715if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
a9bec17c 22716 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
6d153f56 22717Usually this means the macro was only invoked conditionally." "$LINENO" 5
6c051bab 22718fi
942f733f 22719
743c80a7
PE
22720 gl_libobjs=
22721 gl_ltlibobjs=
22722 if test -n "$gl_LIBOBJS"; then
22723 # Remove the extension.
22724 sed_drop_objext='s/\.o$//;s/\.obj$//'
22725 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
22726 gl_libobjs="$gl_libobjs $i.$ac_objext"
22727 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
22728 done
22729 fi
22730 gl_LIBOBJS=$gl_libobjs
22731
22732 gl_LTLIBOBJS=$gl_ltlibobjs
22733
22734
22735
22736 gltests_libobjs=
22737 gltests_ltlibobjs=
22738 if test -n "$gltests_LIBOBJS"; then
22739 # Remove the extension.
22740 sed_drop_objext='s/\.o$//;s/\.obj$//'
22741 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
22742 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
22743 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
22744 done
22745 fi
22746 gltests_LIBOBJS=$gltests_libobjs
22747
22748 gltests_LTLIBOBJS=$gltests_ltlibobjs
22749
067d23c9
KY
22750
22751
a9bec17c 22752: ${CONFIG_STATUS=./config.status}
067d23c9
KY
22753ac_write_fail=0
22754ac_clean_files_save=$ac_clean_files
22755ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22756{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
22757$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
22758as_write_fail=0
22759cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
22760#! $SHELL
22761# Generated by $as_me.
22762# Run this file to recreate the current configuration.
22763# Compiler output produced by configure, useful for debugging
22764# configure, is in config.log if it exists.
22765
22766debug=false
22767ac_cs_recheck=false
22768ac_cs_silent=false
22769
22770SHELL=\${CONFIG_SHELL-$SHELL}
22771export SHELL
22772_ASEOF
22773cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
22774## -------------------- ##
22775## M4sh Initialization. ##
22776## -------------------- ##
22777
22778# Be more Bourne compatible
22779DUALCASE=1; export DUALCASE # for MKS sh
22780if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22781 emulate sh
22782 NULLCMD=:
22783 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
22784 # is contrary to our usage. Disable this feature.
22785 alias -g '${1+"$@"}'='"$@"'
22786 setopt NO_GLOB_SUBST
22787else
22788 case `(set -o) 2>/dev/null` in #(
22789 *posix*) :
22790 set -o posix ;; #(
22791 *) :
22792 ;;
22793esac
22794fi
22795
22796
22797as_nl='
22798'
22799export as_nl
22800# Printing a long string crashes Solaris 7 /usr/bin/printf.
22801as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
22802as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
22803as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
22804# Prefer a ksh shell builtin over an external printf program on Solaris,
22805# but without wasting forks for bash or zsh.
22806if test -z "$BASH_VERSION$ZSH_VERSION" \
22807 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
22808 as_echo='print -r --'
22809 as_echo_n='print -rn --'
22810elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
22811 as_echo='printf %s\n'
22812 as_echo_n='printf %s'
22813else
22814 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
22815 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
22816 as_echo_n='/usr/ucb/echo -n'
22817 else
22818 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
22819 as_echo_n_body='eval
22820 arg=$1;
22821 case $arg in #(
22822 *"$as_nl"*)
22823 expr "X$arg" : "X\\(.*\\)$as_nl";
22824 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
22825 esac;
22826 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
22827 '
22828 export as_echo_n_body
22829 as_echo_n='sh -c $as_echo_n_body as_echo'
22830 fi
22831 export as_echo_body
22832 as_echo='sh -c $as_echo_body as_echo'
22833fi
22834
22835# The user is always right.
22836if test "${PATH_SEPARATOR+set}" != set; then
22837 PATH_SEPARATOR=:
22838 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
22839 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
22840 PATH_SEPARATOR=';'
22841 }
22842fi
22843
22844
22845# IFS
22846# We need space, tab and new line, in precisely that order. Quoting is
22847# there to prevent editors from complaining about space-tab.
22848# (If _AS_PATH_WALK were called with IFS unset, it would disable word
22849# splitting by setting IFS to empty value.)
22850IFS=" "" $as_nl"
22851
22852# Find who we are. Look in the path if we contain no directory separator.
22853case $0 in #((
22854 *[\\/]* ) as_myself=$0 ;;
22855 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22856for as_dir in $PATH
22857do
22858 IFS=$as_save_IFS
22859 test -z "$as_dir" && as_dir=.
22860 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22861 done
22862IFS=$as_save_IFS
22863
22864 ;;
22865esac
22866# We did not find ourselves, most probably we were run as `sh COMMAND'
22867# in which case we are not to be found in the path.
22868if test "x$as_myself" = x; then
22869 as_myself=$0
22870fi
22871if test ! -f "$as_myself"; then
22872 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
22873 exit 1
22874fi
22875
22876# Unset variables that we do not need and which cause bugs (e.g. in
22877# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
22878# suppresses any "Segmentation fault" message there. '((' could
22879# trigger a bug in pdksh 5.2.14.
22880for as_var in BASH_ENV ENV MAIL MAILPATH
22881do eval test x\${$as_var+set} = xset \
22882 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
22883done
22884PS1='$ '
22885PS2='> '
22886PS4='+ '
22887
22888# NLS nuisances.
22889LC_ALL=C
22890export LC_ALL
22891LANGUAGE=C
22892export LANGUAGE
22893
22894# CDPATH.
22895(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22896
22897
a9bec17c
GM
22898# as_fn_error ERROR [LINENO LOG_FD]
22899# ---------------------------------
067d23c9
KY
22900# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
22901# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
a9bec17c 22902# script with status $?, using 1 if that was 0.
067d23c9
KY
22903as_fn_error ()
22904{
a9bec17c
GM
22905 as_status=$?; test $as_status -eq 0 && as_status=1
22906 if test "$3"; then
22907 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
22908 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
067d23c9 22909 fi
a9bec17c 22910 $as_echo "$as_me: error: $1" >&2
067d23c9
KY
22911 as_fn_exit $as_status
22912} # as_fn_error
22913
22914
22915# as_fn_set_status STATUS
22916# -----------------------
22917# Set $? to STATUS, without forking.
22918as_fn_set_status ()
22919{
22920 return $1
22921} # as_fn_set_status
22922
22923# as_fn_exit STATUS
22924# -----------------
22925# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
22926as_fn_exit ()
22927{
22928 set +e
22929 as_fn_set_status $1
22930 exit $1
22931} # as_fn_exit
22932
22933# as_fn_unset VAR
22934# ---------------
22935# Portably unset VAR.
22936as_fn_unset ()
22937{
22938 { eval $1=; unset $1;}
22939}
22940as_unset=as_fn_unset
22941# as_fn_append VAR VALUE
22942# ----------------------
22943# Append the text in VALUE to the end of the definition contained in VAR. Take
22944# advantage of any shell optimizations that allow amortized linear growth over
22945# repeated appends, instead of the typical quadratic growth present in naive
22946# implementations.
22947if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
22948 eval 'as_fn_append ()
22949 {
22950 eval $1+=\$2
22951 }'
22952else
22953 as_fn_append ()
22954 {
22955 eval $1=\$$1\$2
22956 }
22957fi # as_fn_append
22958
22959# as_fn_arith ARG...
22960# ------------------
22961# Perform arithmetic evaluation on the ARGs, and store the result in the
22962# global $as_val. Take advantage of shells that can avoid forks. The arguments
22963# must be portable across $(()) and expr.
22964if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
22965 eval 'as_fn_arith ()
22966 {
22967 as_val=$(( $* ))
22968 }'
22969else
22970 as_fn_arith ()
22971 {
22972 as_val=`expr "$@" || test $? -eq 1`
22973 }
22974fi # as_fn_arith
22975
22976
22977if expr a : '\(a\)' >/dev/null 2>&1 &&
22978 test "X`expr 00001 : '.*\(...\)'`" = X001; then
22979 as_expr=expr
22980else
22981 as_expr=false
22982fi
22983
22984if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
22985 as_basename=basename
22986else
22987 as_basename=false
22988fi
22989
22990if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
22991 as_dirname=dirname
22992else
22993 as_dirname=false
22994fi
22995
22996as_me=`$as_basename -- "$0" ||
22997$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22998 X"$0" : 'X\(//\)$' \| \
22999 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
23000$as_echo X/"$0" |
23001 sed '/^.*\/\([^/][^/]*\)\/*$/{
23002 s//\1/
23003 q
23004 }
23005 /^X\/\(\/\/\)$/{
23006 s//\1/
23007 q
23008 }
23009 /^X\/\(\/\).*/{
23010 s//\1/
23011 q
23012 }
23013 s/.*/./; q'`
23014
23015# Avoid depending upon Character Ranges.
23016as_cr_letters='abcdefghijklmnopqrstuvwxyz'
23017as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
23018as_cr_Letters=$as_cr_letters$as_cr_LETTERS
23019as_cr_digits='0123456789'
23020as_cr_alnum=$as_cr_Letters$as_cr_digits
23021
23022ECHO_C= ECHO_N= ECHO_T=
23023case `echo -n x` in #(((((
23024-n*)
23025 case `echo 'xy\c'` in
23026 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
23027 xy) ECHO_C='\c';;
23028 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
23029 ECHO_T=' ';;
23030 esac;;
23031*)
23032 ECHO_N='-n';;
23033esac
23034
23035rm -f conf$$ conf$$.exe conf$$.file
23036if test -d conf$$.dir; then
23037 rm -f conf$$.dir/conf$$.file
23038else
23039 rm -f conf$$.dir
23040 mkdir conf$$.dir 2>/dev/null
23041fi
23042if (echo >conf$$.file) 2>/dev/null; then
23043 if ln -s conf$$.file conf$$ 2>/dev/null; then
23044 as_ln_s='ln -s'
23045 # ... but there are two gotchas:
23046 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
23047 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
23048 # In both cases, we have to default to `cp -p'.
23049 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
23050 as_ln_s='cp -p'
23051 elif ln conf$$.file conf$$ 2>/dev/null; then
23052 as_ln_s=ln
23053 else
23054 as_ln_s='cp -p'
23055 fi
23056else
23057 as_ln_s='cp -p'
23058fi
23059rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
23060rmdir conf$$.dir 2>/dev/null
23061
23062
23063# as_fn_mkdir_p
23064# -------------
23065# Create "$as_dir" as a directory, including parents if necessary.
23066as_fn_mkdir_p ()
23067{
23068
23069 case $as_dir in #(
23070 -*) as_dir=./$as_dir;;
23071 esac
23072 test -d "$as_dir" || eval $as_mkdir_p || {
23073 as_dirs=
23074 while :; do
23075 case $as_dir in #(
23076 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
23077 *) as_qdir=$as_dir;;
23078 esac
23079 as_dirs="'$as_qdir' $as_dirs"
23080 as_dir=`$as_dirname -- "$as_dir" ||
23081$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23082 X"$as_dir" : 'X\(//\)[^/]' \| \
23083 X"$as_dir" : 'X\(//\)$' \| \
23084 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
23085$as_echo X"$as_dir" |
23086 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23087 s//\1/
23088 q
23089 }
23090 /^X\(\/\/\)[^/].*/{
23091 s//\1/
23092 q
23093 }
23094 /^X\(\/\/\)$/{
23095 s//\1/
23096 q
23097 }
23098 /^X\(\/\).*/{
23099 s//\1/
23100 q
23101 }
23102 s/.*/./; q'`
23103 test -d "$as_dir" && break
23104 done
23105 test -z "$as_dirs" || eval "mkdir $as_dirs"
a9bec17c 23106 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
067d23c9
KY
23107
23108
23109} # as_fn_mkdir_p
23110if mkdir -p . 2>/dev/null; then
23111 as_mkdir_p='mkdir -p "$as_dir"'
23112else
23113 test -d ./-p && rmdir ./-p
23114 as_mkdir_p=false
23115fi
23116
23117if test -x / >/dev/null 2>&1; then
23118 as_test_x='test -x'
23119else
23120 if ls -dL / >/dev/null 2>&1; then
23121 as_ls_L_option=L
23122 else
23123 as_ls_L_option=
23124 fi
23125 as_test_x='
23126 eval sh -c '\''
23127 if test -d "$1"; then
23128 test -d "$1/.";
23129 else
23130 case $1 in #(
23131 -*)set "./$1";;
23132 esac;
23133 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
23134 ???[sx]*):;;*)false;;esac;fi
23135 '\'' sh
23136 '
23137fi
23138as_executable_p=$as_test_x
23139
23140# Sed expression to map a string onto a valid CPP name.
23141as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
23142
23143# Sed expression to map a string onto a valid variable name.
23144as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
23145
23146
23147exec 6>&1
23148## ----------------------------------- ##
23149## Main body of $CONFIG_STATUS script. ##
23150## ----------------------------------- ##
23151_ASEOF
23152test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
23153
23154cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23155# Save the log message, to keep $0 and so on meaningful, and to
23156# report actual input values of CONFIG_FILES etc. instead of their
23157# values after options handling.
23158ac_log="
d570ce1c 23159This file was extended by emacs $as_me 24.0.93, which was
a9bec17c 23160generated by GNU Autoconf 2.65. Invocation command line was
067d23c9
KY
23161
23162 CONFIG_FILES = $CONFIG_FILES
23163 CONFIG_HEADERS = $CONFIG_HEADERS
23164 CONFIG_LINKS = $CONFIG_LINKS
23165 CONFIG_COMMANDS = $CONFIG_COMMANDS
23166 $ $0 $@
23167
23168on `(hostname || uname -n) 2>/dev/null | sed 1q`
23169"
23170
23171_ACEOF
23172
23173case $ac_config_files in *"
23174"*) set x $ac_config_files; shift; ac_config_files=$*;;
23175esac
23176
23177case $ac_config_headers in *"
23178"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
23179esac
23180
23181
23182cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23183# Files that config.status was made for.
23184config_files="$ac_config_files"
23185config_headers="$ac_config_headers"
23186config_commands="$ac_config_commands"
23187
23188_ACEOF
23189
23190cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23191ac_cs_usage="\
23192\`$as_me' instantiates files and other configuration actions
23193from templates according to the current configuration. Unless the files
23194and actions are specified as TAGs, all are instantiated by default.
23195
23196Usage: $0 [OPTION]... [TAG]...
23197
23198 -h, --help print this help, then exit
23199 -V, --version print version number and configuration settings, then exit
23200 --config print configuration, then exit
23201 -q, --quiet, --silent
23202 do not print progress messages
23203 -d, --debug don't remove temporary files
23204 --recheck update $as_me by reconfiguring in the same conditions
23205 --file=FILE[:TEMPLATE]
23206 instantiate the configuration file FILE
23207 --header=FILE[:TEMPLATE]
23208 instantiate the configuration header FILE
23209
23210Configuration files:
23211$config_files
23212
23213Configuration headers:
23214$config_headers
23215
23216Configuration commands:
23217$config_commands
23218
23219Report bugs to the package provider."
23220
23221_ACEOF
23222cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23223ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
23224ac_cs_version="\\
d570ce1c 23225emacs config.status 24.0.93
a9bec17c 23226configured by $0, generated by GNU Autoconf 2.65,
067d23c9
KY
23227 with options \\"\$ac_cs_config\\"
23228
a9bec17c 23229Copyright (C) 2009 Free Software Foundation, Inc.
067d23c9
KY
23230This config.status script is free software; the Free Software Foundation
23231gives unlimited permission to copy, distribute and modify it."
23232
23233ac_pwd='$ac_pwd'
23234srcdir='$srcdir'
23235INSTALL='$INSTALL'
743c80a7
PE
23236MKDIR_P='$MKDIR_P'
23237AWK='$AWK'
067d23c9
KY
23238test -n "\$AWK" || AWK=awk
23239_ACEOF
23240
23241cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23242# The default lists apply if the user does not specify any file.
23243ac_need_defaults=:
23244while test $# != 0
23245do
23246 case $1 in
a9bec17c 23247 --*=*)
067d23c9
KY
23248 ac_option=`expr "X$1" : 'X\([^=]*\)='`
23249 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
23250 ac_shift=:
23251 ;;
23252 *)
23253 ac_option=$1
23254 ac_optarg=$2
23255 ac_shift=shift
23256 ;;
23257 esac
23258
23259 case $ac_option in
23260 # Handling of the options.
23261 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23262 ac_cs_recheck=: ;;
23263 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
23264 $as_echo "$ac_cs_version"; exit ;;
23265 --config | --confi | --conf | --con | --co | --c )
23266 $as_echo "$ac_cs_config"; exit ;;
23267 --debug | --debu | --deb | --de | --d | -d )
23268 debug=: ;;
23269 --file | --fil | --fi | --f )
23270 $ac_shift
23271 case $ac_optarg in
23272 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23273 esac
23274 as_fn_append CONFIG_FILES " '$ac_optarg'"
23275 ac_need_defaults=false;;
23276 --header | --heade | --head | --hea )
23277 $ac_shift
23278 case $ac_optarg in
23279 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23280 esac
23281 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
23282 ac_need_defaults=false;;
23283 --he | --h)
23284 # Conflict between --help and --header
a9bec17c 23285 as_fn_error "ambiguous option: \`$1'
067d23c9
KY
23286Try \`$0 --help' for more information.";;
23287 --help | --hel | -h )
23288 $as_echo "$ac_cs_usage"; exit ;;
23289 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23290 | -silent | --silent | --silen | --sile | --sil | --si | --s)
23291 ac_cs_silent=: ;;
23292
23293 # This is an error.
a9bec17c 23294 -*) as_fn_error "unrecognized option: \`$1'
067d23c9
KY
23295Try \`$0 --help' for more information." ;;
23296
23297 *) as_fn_append ac_config_targets " $1"
23298 ac_need_defaults=false ;;
23299
23300 esac
23301 shift
23302done
23303
23304ac_configure_extra_args=
23305
23306if $ac_cs_silent; then
23307 exec 6>/dev/null
23308 ac_configure_extra_args="$ac_configure_extra_args --silent"
23309fi
23310
23311_ACEOF
23312cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23313if \$ac_cs_recheck; then
23314 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23315 shift
23316 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
23317 CONFIG_SHELL='$SHELL'
23318 export CONFIG_SHELL
23319 exec "\$@"
23320fi
23321
23322_ACEOF
23323cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23324exec 5>>config.log
23325{
23326 echo
23327 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23328## Running $as_me. ##
23329_ASBOX
23330 $as_echo "$ac_log"
23331} >&5
23332
23333_ACEOF
23334cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23335#
23336# INIT-COMMANDS
23337#
743c80a7 23338AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
067d23c9
KY
23339GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
23340
23341_ACEOF
23342
23343cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23344
23345# Handling of arguments.
23346for ac_config_target in $ac_config_targets
23347do
23348 case $ac_config_target in
23349 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
743c80a7 23350 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
067d23c9 23351 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
743c80a7 23352 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
56ade35c
GM
23353 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
23354 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
23355 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
23356 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
23357 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
23358 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
23359 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
23360 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
23361 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23362 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
23363 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
9411886d
PE
23364 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
23365 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
23366 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
067d23c9 23367
a9bec17c 23368 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
067d23c9
KY
23369 esac
23370done
23371
23372
23373# If the user did not use the arguments to specify the items to instantiate,
23374# then the envvar interface is used. Set only those that are not.
23375# We use the long form for the default assignment because of an extremely
23376# bizarre bug on SunOS 4.1.3.
23377if $ac_need_defaults; then
23378 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23379 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23380 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23381fi
23382
23383# Have a temporary directory for convenience. Make it in the build tree
23384# simply because there is no reason against having it here, and in addition,
23385# creating and moving files from /tmp can sometimes cause problems.
23386# Hook for its removal unless debugging.
23387# Note that there is a small window in which the directory will not be cleaned:
23388# after its creation but before its name has been assigned to `$tmp'.
23389$debug ||
23390{
a9bec17c 23391 tmp=
067d23c9 23392 trap 'exit_status=$?
a9bec17c 23393 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
067d23c9
KY
23394' 0
23395 trap 'as_fn_exit 1' 1 2 13 15
23396}
23397# Create a (secure) tmp directory for tmp files.
23398
23399{
23400 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
a9bec17c 23401 test -n "$tmp" && test -d "$tmp"
067d23c9
KY
23402} ||
23403{
23404 tmp=./conf$$-$RANDOM
23405 (umask 077 && mkdir "$tmp")
a9bec17c 23406} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
067d23c9
KY
23407
23408# Set up the scripts for CONFIG_FILES section.
23409# No need to generate them if there are no CONFIG_FILES.
23410# This happens for instance with `./config.status config.h'.
23411if test -n "$CONFIG_FILES"; then
23412
23413if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
23414 ac_cs_awk_getline=:
23415 ac_cs_awk_pipe_init=
23416 ac_cs_awk_read_file='
23417 while ((getline aline < (F[key])) > 0)
23418 print(aline)
23419 close(F[key])'
23420 ac_cs_awk_pipe_fini=
23421else
23422 ac_cs_awk_getline=false
23423 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
23424 ac_cs_awk_read_file='
23425 print "|#_!!_#|"
23426 print "cat " F[key] " &&"
23427 '$ac_cs_awk_pipe_init
23428 # The final `:' finishes the AND list.
23429 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
23430fi
23431ac_cr=`echo X | tr X '\015'`
23432# On cygwin, bash can eat \r inside `` if the user requested igncr.
23433# But we know of no other shell where ac_cr would be empty at this
23434# point, so we can use a bashism as a fallback.
23435if test "x$ac_cr" = x; then
23436 eval ac_cr=\$\'\\r\'
23437fi
23438ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
23439if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
a9bec17c 23440 ac_cs_awk_cr='\r'
067d23c9
KY
23441else
23442 ac_cs_awk_cr=$ac_cr
23443fi
23444
a9bec17c 23445echo 'BEGIN {' >"$tmp/subs1.awk" &&
067d23c9
KY
23446_ACEOF
23447
23448# Create commands to substitute file output variables.
23449{
23450 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
a9bec17c 23451 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
067d23c9
KY
23452 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
23453 echo "_ACAWK" &&
23454 echo "_ACEOF"
23455} >conf$$files.sh &&
23456. ./conf$$files.sh ||
a9bec17c 23457 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
23458rm -f conf$$files.sh
23459
23460{
23461 echo "cat >conf$$subs.awk <<_ACEOF" &&
23462 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
23463 echo "_ACEOF"
23464} >conf$$subs.sh ||
a9bec17c
GM
23465 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23466ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
067d23c9
KY
23467ac_delim='%!_!# '
23468for ac_last_try in false false false false false :; do
23469 . ./conf$$subs.sh ||
a9bec17c 23470 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
23471
23472 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
23473 if test $ac_delim_n = $ac_delim_num; then
23474 break
23475 elif $ac_last_try; then
a9bec17c 23476 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
23477 else
23478 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23479 fi
23480done
23481rm -f conf$$subs.sh
23482
23483cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
a9bec17c 23484cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
067d23c9
KY
23485_ACEOF
23486sed -n '
23487h
23488s/^/S["/; s/!.*/"]=/
23489p
23490g
23491s/^[^!]*!//
23492:repl
23493t repl
23494s/'"$ac_delim"'$//
23495t delim
23496:nl
23497h
23498s/\(.\{148\}\)..*/\1/
23499t more1
23500s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
23501p
23502n
23503b repl
23504:more1
23505s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23506p
23507g
23508s/.\{148\}//
23509t nl
23510:delim
23511h
23512s/\(.\{148\}\)..*/\1/
23513t more2
23514s/["\\]/\\&/g; s/^/"/; s/$/"/
23515p
23516b
23517:more2
23518s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23519p
23520g
23521s/.\{148\}//
23522t delim
23523' <conf$$subs.awk | sed '
23524/^[^""]/{
23525 N
23526 s/\n//
23527}
23528' >>$CONFIG_STATUS || ac_write_fail=1
23529rm -f conf$$subs.awk
23530cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23531_ACAWK
a9bec17c 23532cat >>"\$tmp/subs1.awk" <<_ACAWK &&
067d23c9
KY
23533 for (key in S) S_is_set[key] = 1
23534 FS = "\a"
23535 \$ac_cs_awk_pipe_init
23536}
23537{
23538 line = $ 0
23539 nfields = split(line, field, "@")
23540 substed = 0
23541 len = length(field[1])
23542 for (i = 2; i < nfields; i++) {
23543 key = field[i]
23544 keylen = length(key)
23545 if (S_is_set[key]) {
23546 value = S[key]
23547 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
23548 len += length(value) + length(field[++i])
23549 substed = 1
23550 } else
23551 len += 1 + keylen
23552 }
23553 if (nfields == 3 && !substed) {
23554 key = field[2]
23555 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
23556 \$ac_cs_awk_read_file
23557 next
23558 }
23559 }
23560 print line
23561}
23562\$ac_cs_awk_pipe_fini
23563_ACAWK
23564_ACEOF
23565cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23566if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
23567 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
23568else
23569 cat
a9bec17c
GM
23570fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
23571 || as_fn_error "could not setup config files machinery" "$LINENO" 5
067d23c9
KY
23572_ACEOF
23573
a9bec17c
GM
23574# VPATH may cause trouble with some makes, so we remove $(srcdir),
23575# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
067d23c9
KY
23576# trailing colons and then remove the whole line if VPATH becomes empty
23577# (actually we leave an empty line to preserve line numbers).
23578if test "x$srcdir" = x.; then
a9bec17c
GM
23579 ac_vpsub='/^[ ]*VPATH[ ]*=/{
23580s/:*\$(srcdir):*/:/
23581s/:*\${srcdir}:*/:/
23582s/:*@srcdir@:*/:/
23583s/^\([^=]*=[ ]*\):*/\1/
067d23c9
KY
23584s/:*$//
23585s/^[^=]*=[ ]*$//
23586}'
23587fi
23588
23589cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23590fi # test -n "$CONFIG_FILES"
23591
23592# Set up the scripts for CONFIG_HEADERS section.
23593# No need to generate them if there are no CONFIG_HEADERS.
23594# This happens for instance with `./config.status Makefile'.
23595if test -n "$CONFIG_HEADERS"; then
a9bec17c 23596cat >"$tmp/defines.awk" <<\_ACAWK ||
067d23c9
KY
23597BEGIN {
23598_ACEOF
23599
23600# Transform confdefs.h into an awk script `defines.awk', embedded as
23601# here-document in config.status, that substitutes the proper values into
23602# config.h.in to produce config.h.
23603
23604# Create a delimiter string that does not exist in confdefs.h, to ease
23605# handling of long lines.
23606ac_delim='%!_!# '
23607for ac_last_try in false false :; do
a9bec17c
GM
23608 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
23609 if test -z "$ac_t"; then
067d23c9
KY
23610 break
23611 elif $ac_last_try; then
a9bec17c 23612 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
067d23c9
KY
23613 else
23614 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23615 fi
23616done
23617
23618# For the awk script, D is an array of macro values keyed by name,
23619# likewise P contains macro parameters if any. Preserve backslash
23620# newline sequences.
23621
23622ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
23623sed -n '
23624s/.\{148\}/&'"$ac_delim"'/g
23625t rset
23626:rset
23627s/^[ ]*#[ ]*define[ ][ ]*/ /
23628t def
23629d
23630:def
23631s/\\$//
23632t bsnl
23633s/["\\]/\\&/g
23634s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
23635D["\1"]=" \3"/p
23636s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
23637d
23638:bsnl
23639s/["\\]/\\&/g
23640s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
23641D["\1"]=" \3\\\\\\n"\\/p
23642t cont
23643s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
23644t cont
23645d
23646:cont
23647n
23648s/.\{148\}/&'"$ac_delim"'/g
23649t clear
23650:clear
23651s/\\$//
23652t bsnlc
23653s/["\\]/\\&/g; s/^/"/; s/$/"/p
23654d
23655:bsnlc
23656s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
23657b cont
23658' <confdefs.h | sed '
23659s/'"$ac_delim"'/"\\\
23660"/g' >>$CONFIG_STATUS || ac_write_fail=1
23661
23662cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23663 for (key in D) D_is_set[key] = 1
23664 FS = "\a"
23665}
23666/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
23667 line = \$ 0
23668 split(line, arg, " ")
23669 if (arg[1] == "#") {
23670 defundef = arg[2]
23671 mac1 = arg[3]
23672 } else {
23673 defundef = substr(arg[1], 2)
23674 mac1 = arg[2]
23675 }
23676 split(mac1, mac2, "(") #)
23677 macro = mac2[1]
23678 prefix = substr(line, 1, index(line, defundef) - 1)
23679 if (D_is_set[macro]) {
23680 # Preserve the white space surrounding the "#".
23681 print prefix "define", macro P[macro] D[macro]
23682 next
23683 } else {
23684 # Replace #undef with comments. This is necessary, for example,
23685 # in the case of _POSIX_SOURCE, which is predefined and required
23686 # on some systems where configure will not decide to define it.
23687 if (defundef == "undef") {
23688 print "/*", prefix defundef, macro, "*/"
23689 next
23690 }
23691 }
23692}
23693{ print }
23694_ACAWK
23695_ACEOF
23696cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
a9bec17c 23697 as_fn_error "could not setup config headers machinery" "$LINENO" 5
067d23c9
KY
23698fi # test -n "$CONFIG_HEADERS"
23699
23700
23701eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
23702shift
23703for ac_tag
23704do
23705 case $ac_tag in
23706 :[FHLC]) ac_mode=$ac_tag; continue;;
23707 esac
23708 case $ac_mode$ac_tag in
23709 :[FHL]*:*);;
a9bec17c 23710 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
067d23c9
KY
23711 :[FH]-) ac_tag=-:-;;
23712 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
23713 esac
23714 ac_save_IFS=$IFS
23715 IFS=:
23716 set x $ac_tag
23717 IFS=$ac_save_IFS
23718 shift
23719 ac_file=$1
23720 shift
23721
23722 case $ac_mode in
23723 :L) ac_source=$1;;
23724 :[FH])
23725 ac_file_inputs=
23726 for ac_f
23727 do
23728 case $ac_f in
a9bec17c 23729 -) ac_f="$tmp/stdin";;
067d23c9
KY
23730 *) # Look for the file first in the build tree, then in the source tree
23731 # (if the path is not absolute). The absolute path cannot be DOS-style,
23732 # because $ac_f cannot contain `:'.
23733 test -f "$ac_f" ||
23734 case $ac_f in
23735 [\\/$]*) false;;
23736 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
23737 esac ||
a9bec17c 23738 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
067d23c9
KY
23739 esac
23740 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
23741 as_fn_append ac_file_inputs " '$ac_f'"
23742 done
23743
23744 # Let's still pretend it is `configure' which instantiates (i.e., don't
23745 # use $as_me), people would be surprised to read:
23746 # /* config.h. Generated by config.status. */
23747 configure_input='Generated from '`
23748 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
23749 `' by configure.'
23750 if test x"$ac_file" != x-; then
23751 configure_input="$ac_file. $configure_input"
23752 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
23753$as_echo "$as_me: creating $ac_file" >&6;}
23754 fi
23755 # Neutralize special characters interpreted by sed in replacement strings.
23756 case $configure_input in #(
23757 *\&* | *\|* | *\\* )
23758 ac_sed_conf_input=`$as_echo "$configure_input" |
23759 sed 's/[\\\\&|]/\\\\&/g'`;; #(
23760 *) ac_sed_conf_input=$configure_input;;
23761 esac
23762
23763 case $ac_tag in
a9bec17c
GM
23764 *:-:* | *:-) cat >"$tmp/stdin" \
23765 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
067d23c9
KY
23766 esac
23767 ;;
23768 esac
23769
23770 ac_dir=`$as_dirname -- "$ac_file" ||
23771$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23772 X"$ac_file" : 'X\(//\)[^/]' \| \
23773 X"$ac_file" : 'X\(//\)$' \| \
23774 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
23775$as_echo X"$ac_file" |
23776 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23777 s//\1/
23778 q
23779 }
23780 /^X\(\/\/\)[^/].*/{
23781 s//\1/
23782 q
23783 }
23784 /^X\(\/\/\)$/{
23785 s//\1/
23786 q
23787 }
23788 /^X\(\/\).*/{
23789 s//\1/
23790 q
23791 }
23792 s/.*/./; q'`
23793 as_dir="$ac_dir"; as_fn_mkdir_p
23794 ac_builddir=.
23795
23796case "$ac_dir" in
23797.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
23798*)
23799 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
23800 # A ".." for each directory in $ac_dir_suffix.
23801 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
23802 case $ac_top_builddir_sub in
23803 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
23804 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
23805 esac ;;
23806esac
23807ac_abs_top_builddir=$ac_pwd
23808ac_abs_builddir=$ac_pwd$ac_dir_suffix
23809# for backward compatibility:
23810ac_top_builddir=$ac_top_build_prefix
23811
23812case $srcdir in
23813 .) # We are building in place.
23814 ac_srcdir=.
23815 ac_top_srcdir=$ac_top_builddir_sub
23816 ac_abs_top_srcdir=$ac_pwd ;;
23817 [\\/]* | ?:[\\/]* ) # Absolute name.
23818 ac_srcdir=$srcdir$ac_dir_suffix;
23819 ac_top_srcdir=$srcdir
23820 ac_abs_top_srcdir=$srcdir ;;
23821 *) # Relative name.
23822 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
23823 ac_top_srcdir=$ac_top_build_prefix$srcdir
23824 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
23825esac
23826ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
23827
23828
23829 case $ac_mode in
23830 :F)
23831 #
23832 # CONFIG_FILE
23833 #
23834
23835 case $INSTALL in
23836 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
23837 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
23838 esac
743c80a7
PE
23839 ac_MKDIR_P=$MKDIR_P
23840 case $MKDIR_P in
23841 [\\/$]* | ?:[\\/]* ) ;;
23842 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
23843 esac
067d23c9
KY
23844_ACEOF
23845
23846cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23847# If the template does not know about datarootdir, expand it.
23848# FIXME: This hack should be removed a few years after 2.60.
23849ac_datarootdir_hack=; ac_datarootdir_seen=
23850ac_sed_dataroot='
23851/datarootdir/ {
23852 p
23853 q
23854}
23855/@datadir@/p
23856/@docdir@/p
23857/@infodir@/p
23858/@localedir@/p
23859/@mandir@/p'
23860case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
23861*datarootdir*) ac_datarootdir_seen=yes;;
23862*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
23863 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
23864$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
23865_ACEOF
23866cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23867 ac_datarootdir_hack='
23868 s&@datadir@&$datadir&g
23869 s&@docdir@&$docdir&g
23870 s&@infodir@&$infodir&g
23871 s&@localedir@&$localedir&g
23872 s&@mandir@&$mandir&g
23873 s&\\\${datarootdir}&$datarootdir&g' ;;
23874esac
23875_ACEOF
23876
23877# Neutralize VPATH when `$srcdir' = `.'.
23878# Shell code in configure.ac might set extrasub.
23879# FIXME: do we really want to maintain this feature?
23880cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23881ac_sed_extra="$ac_vpsub
23882$extrasub
23883_ACEOF
23884cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23885:t
23886/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23887s|@configure_input@|$ac_sed_conf_input|;t t
23888s&@top_builddir@&$ac_top_builddir_sub&;t t
23889s&@top_build_prefix@&$ac_top_build_prefix&;t t
23890s&@srcdir@&$ac_srcdir&;t t
23891s&@abs_srcdir@&$ac_abs_srcdir&;t t
23892s&@top_srcdir@&$ac_top_srcdir&;t t
23893s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
23894s&@builddir@&$ac_builddir&;t t
23895s&@abs_builddir@&$ac_abs_builddir&;t t
23896s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
23897s&@INSTALL@&$ac_INSTALL&;t t
743c80a7 23898s&@MKDIR_P@&$ac_MKDIR_P&;t t
067d23c9
KY
23899$ac_datarootdir_hack
23900"
23901eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
23902if $ac_cs_awk_getline; then
a9bec17c 23903 $AWK -f "$tmp/subs.awk"
067d23c9 23904else
a9bec17c
GM
23905 $AWK -f "$tmp/subs.awk" | $SHELL
23906fi >$tmp/out \
23907 || as_fn_error "could not create $ac_file" "$LINENO" 5
067d23c9
KY
23908
23909test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
a9bec17c
GM
23910 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
23911 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
067d23c9 23912 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
a9bec17c 23913which seems to be undefined. Please make sure it is defined." >&5
067d23c9 23914$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
a9bec17c 23915which seems to be undefined. Please make sure it is defined." >&2;}
067d23c9 23916
a9bec17c 23917 rm -f "$tmp/stdin"
067d23c9 23918 case $ac_file in
a9bec17c
GM
23919 -) cat "$tmp/out" && rm -f "$tmp/out";;
23920 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
067d23c9 23921 esac \
a9bec17c 23922 || as_fn_error "could not create $ac_file" "$LINENO" 5
067d23c9
KY
23923 ;;
23924 :H)
23925 #
23926 # CONFIG_HEADER
23927 #
23928 if test x"$ac_file" != x-; then
23929 {
23930 $as_echo "/* $configure_input */" \
a9bec17c
GM
23931 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
23932 } >"$tmp/config.h" \
23933 || as_fn_error "could not create $ac_file" "$LINENO" 5
23934 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
067d23c9
KY
23935 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
23936$as_echo "$as_me: $ac_file is unchanged" >&6;}
23937 else
23938 rm -f "$ac_file"
a9bec17c
GM
23939 mv "$tmp/config.h" "$ac_file" \
23940 || as_fn_error "could not create $ac_file" "$LINENO" 5
067d23c9
KY
23941 fi
23942 else
23943 $as_echo "/* $configure_input */" \
a9bec17c
GM
23944 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
23945 || as_fn_error "could not create -" "$LINENO" 5
067d23c9 23946 fi
743c80a7
PE
23947# Compute "$ac_file"'s index in $config_headers.
23948_am_arg="$ac_file"
23949_am_stamp_count=1
23950for _am_header in $config_headers :; do
23951 case $_am_header in
23952 $_am_arg | $_am_arg:* )
23953 break ;;
23954 * )
23955 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
23956 esac
23957done
23958echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
23959$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23960 X"$_am_arg" : 'X\(//\)[^/]' \| \
23961 X"$_am_arg" : 'X\(//\)$' \| \
23962 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
23963$as_echo X"$_am_arg" |
23964 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23965 s//\1/
23966 q
23967 }
23968 /^X\(\/\/\)[^/].*/{
23969 s//\1/
23970 q
23971 }
23972 /^X\(\/\/\)$/{
23973 s//\1/
23974 q
23975 }
23976 /^X\(\/\).*/{
23977 s//\1/
23978 q
23979 }
23980 s/.*/./; q'`/stamp-h$_am_stamp_count
067d23c9
KY
23981 ;;
23982
23983 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
23984$as_echo "$as_me: executing $ac_file commands" >&6;}
23985 ;;
23986 esac
23987
23988
23989 case $ac_file$ac_mode in
743c80a7
PE
23990 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
23991 # Autoconf 2.62 quotes --file arguments for eval, but not when files
23992 # are listed without --file. Let's play safe and only enable the eval
23993 # if we detect the quoting.
23994 case $CONFIG_FILES in
23995 *\'*) eval set x "$CONFIG_FILES" ;;
23996 *) set x $CONFIG_FILES ;;
23997 esac
23998 shift
23999 for mf
24000 do
24001 # Strip MF so we end up with the name of the file.
24002 mf=`echo "$mf" | sed -e 's/:.*$//'`
24003 # Check whether this is an Automake generated Makefile or not.
24004 # We used to match only the files named `Makefile.in', but
24005 # some people rename them; so instead we look at the file content.
24006 # Grep'ing the first line is not enough: some people post-process
24007 # each Makefile.in and add a new line on top of each file to say so.
24008 # Grep'ing the whole file is not good either: AIX grep has a line
24009 # limit of 2048, but all sed's we know have understand at least 4000.
24010 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
24011 dirpart=`$as_dirname -- "$mf" ||
24012$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24013 X"$mf" : 'X\(//\)[^/]' \| \
24014 X"$mf" : 'X\(//\)$' \| \
24015 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
24016$as_echo X"$mf" |
24017 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24018 s//\1/
24019 q
24020 }
24021 /^X\(\/\/\)[^/].*/{
24022 s//\1/
24023 q
24024 }
24025 /^X\(\/\/\)$/{
24026 s//\1/
24027 q
24028 }
24029 /^X\(\/\).*/{
24030 s//\1/
24031 q
24032 }
24033 s/.*/./; q'`
24034 else
24035 continue
24036 fi
24037 # Extract the definition of DEPDIR, am__include, and am__quote
24038 # from the Makefile without running `make'.
24039 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
24040 test -z "$DEPDIR" && continue
24041 am__include=`sed -n 's/^am__include = //p' < "$mf"`
24042 test -z "am__include" && continue
24043 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
24044 # When using ansi2knr, U may be empty or an underscore; expand it
24045 U=`sed -n 's/^U = //p' < "$mf"`
24046 # Find all dependency output files, they are included files with
24047 # $(DEPDIR) in their names. We invoke sed twice because it is the
24048 # simplest approach to changing $(DEPDIR) to its actual value in the
24049 # expansion.
24050 for file in `sed -n "
24051 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
24052 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
24053 # Make sure the directory exists.
24054 test -f "$dirpart/$file" && continue
24055 fdir=`$as_dirname -- "$file" ||
24056$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24057 X"$file" : 'X\(//\)[^/]' \| \
24058 X"$file" : 'X\(//\)$' \| \
24059 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
24060$as_echo X"$file" |
24061 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24062 s//\1/
24063 q
24064 }
24065 /^X\(\/\/\)[^/].*/{
24066 s//\1/
24067 q
24068 }
24069 /^X\(\/\/\)$/{
24070 s//\1/
24071 q
24072 }
24073 /^X\(\/\).*/{
24074 s//\1/
24075 q
24076 }
24077 s/.*/./; q'`
24078 as_dir=$dirpart/$fdir; as_fn_mkdir_p
24079 # echo "creating $dirpart/$file"
24080 echo '# dummy' > "$dirpart/$file"
24081 done
24082 done
24083}
24084 ;;
9411886d 24085 "mkdirs":C)
067d23c9
KY
24086for dir in etc lisp ; do
24087 test -d ${dir} || mkdir ${dir}
24088done
9411886d
PE
24089 ;;
24090 "epaths":C)
067d23c9
KY
24091echo creating src/epaths.h
24092${MAKE-make} epaths-force
9411886d
PE
24093 ;;
24094 "gdbinit":C)
067d23c9
KY
24095if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
24096 echo creating src/.gdbinit
24097 echo source $srcdir/src/.gdbinit > src/.gdbinit
24098fi
067d23c9
KY
24099 ;;
24100
24101 esac
24102done # for ac_tag
24103
24104
24105as_fn_exit 0
24106_ACEOF
24107ac_clean_files=$ac_clean_files_save
24108
24109test $ac_write_fail = 0 ||
a9bec17c 24110 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
24111
24112
24113# configure is writing to config.log, and then calls config.status.
24114# config.status does its own redirection, appending to config.log.
24115# Unfortunately, on DOS this fails, as config.log is still kept open
24116# by configure, so config.status won't be able to write to it; its
24117# output is simply discarded. So we exec the FD to /dev/null,
24118# effectively closing config.log, so it can be properly (re)opened and
24119# appended to by config.status. When coming back to configure, we
24120# need to make the FD available again.
24121if test "$no_create" != yes; then
24122 ac_cs_success=:
24123 ac_config_status_args=
24124 test "$silent" = yes &&
24125 ac_config_status_args="$ac_config_status_args --quiet"
24126 exec 5>/dev/null
24127 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24128 exec 5>>config.log
24129 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24130 # would make configure fail if this is the last instruction.
a9bec17c 24131 $ac_cs_success || as_fn_exit $?
067d23c9
KY
24132fi
24133if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24134 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24135$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
24136fi
24137
9411886d 24138