merge from trunk
[emacs.git] / autogen / configure
blobf35ce6d62cb8f291ec6dee25b3c139aefeac0eb5
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.3.50.
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
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 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if 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
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
32 esac
36 as_nl='
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_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.
45 if 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 --'
49 elif (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'
52 else
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"
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
74 # The user is always right.
75 if 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=';'
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.)
89 IFS=" "" $as_nl"
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
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
101 IFS=$as_save_IFS
104 esac
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.
107 if test "x$as_myself" = x; then
108 as_myself=$0
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
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.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136 if 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
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
150 esac
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
166 else
167 exitcode=1; echo positional parameters were not saved.
169 test 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
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
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
202 done;;
203 esac
204 as_found=false
205 done
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
209 fi; }
210 IFS=$as_save_IFS
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
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
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."
236 exit 1
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
254 { eval $1=; unset $1;}
256 as_unset=as_fn_unset
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
263 return $1
264 } # as_fn_set_status
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
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/
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
307 /^X\(\/\/\)$/{
308 s//\1/
311 /^X\(\/\).*/{
312 s//\1/
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
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.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
332 eval $1+=\$2
334 else
335 as_fn_append ()
337 eval $1=\$$1\$2
339 fi # as_fn_append
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.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
349 as_val=$(( $* ))
351 else
352 as_fn_arith ()
354 as_val=`expr "$@" || test $? -eq 1`
356 fi # as_fn_arith
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
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
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
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
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
394 as_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/
403 /^X\/\(\/\/\)$/{
404 s//\1/
407 /^X\/\(\/\).*/{
408 s//\1/
411 s/.*/./; q'`
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
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 '
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
434 :lineno
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; }
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
452 ECHO_C= ECHO_N= ECHO_T=
453 case `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;;
462 ECHO_N='-n';;
463 esac
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
472 if (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'
486 else
487 as_ln_s='cp -p'
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
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
520 as_executable_p=$as_test_x
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
538 # Initializations.
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.3.50'
553 PACKAGE_STRING='emacs 24.3.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_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"
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 WINDOW_SYSTEM_OBJ
608 EMACS_HEAPSIZE
609 TEMACS_POST_LINK
610 ADDSECTION
611 LD_SWITCH_SYSTEM_TEMACS
612 LIBGNU_LTLIBDEPS
613 LIBGNU_LIBDEPS
614 gltests_WITNESS
615 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE
616 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE
617 gl_GNULIB_ENABLED_tempname_FALSE
618 gl_GNULIB_ENABLED_tempname_TRUE
619 gl_GNULIB_ENABLED_strtoull_FALSE
620 gl_GNULIB_ENABLED_strtoull_TRUE
621 gl_GNULIB_ENABLED_strtoll_FALSE
622 gl_GNULIB_ENABLED_strtoll_TRUE
623 gl_GNULIB_ENABLED_stat_FALSE
624 gl_GNULIB_ENABLED_stat_TRUE
625 gl_GNULIB_ENABLED_secure_getenv_FALSE
626 gl_GNULIB_ENABLED_secure_getenv_TRUE
627 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
628 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
629 gl_GNULIB_ENABLED_pathmax_FALSE
630 gl_GNULIB_ENABLED_pathmax_TRUE
631 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
632 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
633 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
634 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
635 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
636 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
637 gl_GNULIB_ENABLED_getgroups_FALSE
638 gl_GNULIB_ENABLED_getgroups_TRUE
639 gl_GNULIB_ENABLED_getdtablesize_FALSE
640 gl_GNULIB_ENABLED_getdtablesize_TRUE
641 gl_GNULIB_ENABLED_euidaccess_FALSE
642 gl_GNULIB_ENABLED_euidaccess_TRUE
643 gl_GNULIB_ENABLED_dosname_FALSE
644 gl_GNULIB_ENABLED_dosname_TRUE
645 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE
646 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE
647 LTLIBINTL
648 LIBINTL
649 LIB_EACCESS
650 WINDOWS_64_BIT_OFF_T
651 HAVE_UNISTD_H
652 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
653 NEXT_UNISTD_H
654 LIB_TIMER_TIME
655 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
656 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
657 TIME_H_DEFINES_STRUCT_TIMESPEC
658 NEXT_AS_FIRST_DIRECTIVE_TIME_H
659 NEXT_TIME_H
660 WINDOWS_64_BIT_ST_SIZE
661 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
662 NEXT_SYS_STAT_H
663 NEXT_AS_FIRST_DIRECTIVE_STRING_H
664 NEXT_STRING_H
665 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
666 NEXT_STDLIB_H
667 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
668 NEXT_STDIO_H
669 REPLACE_VSPRINTF
670 REPLACE_VSNPRINTF
671 REPLACE_VPRINTF
672 REPLACE_VFPRINTF
673 REPLACE_VDPRINTF
674 REPLACE_VASPRINTF
675 REPLACE_TMPFILE
676 REPLACE_STDIO_WRITE_FUNCS
677 REPLACE_STDIO_READ_FUNCS
678 REPLACE_SPRINTF
679 REPLACE_SNPRINTF
680 REPLACE_RENAMEAT
681 REPLACE_RENAME
682 REPLACE_REMOVE
683 REPLACE_PRINTF
684 REPLACE_POPEN
685 REPLACE_PERROR
686 REPLACE_OBSTACK_PRINTF
687 REPLACE_GETLINE
688 REPLACE_GETDELIM
689 REPLACE_FTELLO
690 REPLACE_FTELL
691 REPLACE_FSEEKO
692 REPLACE_FSEEK
693 REPLACE_FREOPEN
694 REPLACE_FPURGE
695 REPLACE_FPRINTF
696 REPLACE_FOPEN
697 REPLACE_FFLUSH
698 REPLACE_FDOPEN
699 REPLACE_FCLOSE
700 REPLACE_DPRINTF
701 HAVE_VDPRINTF
702 HAVE_VASPRINTF
703 HAVE_RENAMEAT
704 HAVE_POPEN
705 HAVE_PCLOSE
706 HAVE_FTELLO
707 HAVE_FSEEKO
708 HAVE_DPRINTF
709 HAVE_DECL_VSNPRINTF
710 HAVE_DECL_SNPRINTF
711 HAVE_DECL_OBSTACK_PRINTF
712 HAVE_DECL_GETLINE
713 HAVE_DECL_GETDELIM
714 HAVE_DECL_FTELLO
715 HAVE_DECL_FSEEKO
716 HAVE_DECL_FPURGE
717 GNULIB_VSPRINTF_POSIX
718 GNULIB_VSNPRINTF
719 GNULIB_VPRINTF_POSIX
720 GNULIB_VPRINTF
721 GNULIB_VFPRINTF_POSIX
722 GNULIB_VFPRINTF
723 GNULIB_VDPRINTF
724 GNULIB_VSCANF
725 GNULIB_VFSCANF
726 GNULIB_VASPRINTF
727 GNULIB_TMPFILE
728 GNULIB_STDIO_H_SIGPIPE
729 GNULIB_STDIO_H_NONBLOCKING
730 GNULIB_SPRINTF_POSIX
731 GNULIB_SNPRINTF
732 GNULIB_SCANF
733 GNULIB_RENAMEAT
734 GNULIB_RENAME
735 GNULIB_REMOVE
736 GNULIB_PUTS
737 GNULIB_PUTCHAR
738 GNULIB_PUTC
739 GNULIB_PRINTF_POSIX
740 GNULIB_PRINTF
741 GNULIB_POPEN
742 GNULIB_PERROR
743 GNULIB_PCLOSE
744 GNULIB_OBSTACK_PRINTF_POSIX
745 GNULIB_OBSTACK_PRINTF
746 GNULIB_GETLINE
747 GNULIB_GETDELIM
748 GNULIB_GETCHAR
749 GNULIB_GETC
750 GNULIB_FWRITE
751 GNULIB_FTELLO
752 GNULIB_FTELL
753 GNULIB_FSEEKO
754 GNULIB_FSEEK
755 GNULIB_FSCANF
756 GNULIB_FREOPEN
757 GNULIB_FREAD
758 GNULIB_FPUTS
759 GNULIB_FPUTC
760 GNULIB_FPURGE
761 GNULIB_FPRINTF_POSIX
762 GNULIB_FPRINTF
763 GNULIB_FOPEN
764 GNULIB_FGETS
765 GNULIB_FGETC
766 GNULIB_FFLUSH
767 GNULIB_FDOPEN
768 GNULIB_FCLOSE
769 GNULIB_DPRINTF
770 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
771 NEXT_STDDEF_H
772 GL_GENERATE_STDDEF_H_FALSE
773 GL_GENERATE_STDDEF_H_TRUE
774 STDDEF_H
775 HAVE_WCHAR_T
776 REPLACE_NULL
777 HAVE__BOOL
778 GL_GENERATE_STDBOOL_H_FALSE
779 GL_GENERATE_STDBOOL_H_TRUE
780 STDBOOL_H
781 GL_GENERATE_STDARG_H_FALSE
782 GL_GENERATE_STDARG_H_TRUE
783 STDARG_H
784 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
785 NEXT_STDARG_H
786 GL_GENERATE_STDALIGN_H_FALSE
787 GL_GENERATE_STDALIGN_H_TRUE
788 STDALIGN_H
789 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
790 NEXT_SIGNAL_H
791 USE_ACL
792 LIB_ACL
793 LIB_PTHREAD_SIGMASK
794 REPLACE_RAISE
795 REPLACE_PTHREAD_SIGMASK
796 HAVE_SIGHANDLER_T
797 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
798 HAVE_STRUCT_SIGACTION_SA_SIGACTION
799 HAVE_SIGACTION
800 HAVE_SIGINFO_T
801 HAVE_SIGSET_T
802 HAVE_RAISE
803 HAVE_PTHREAD_SIGMASK
804 HAVE_POSIX_SIGNALBLOCKING
805 GNULIB_SIGACTION
806 GNULIB_SIGPROCMASK
807 GNULIB_SIGNAL_H_SIGPIPE
808 GNULIB_RAISE
809 GNULIB_PTHREAD_SIGMASK
810 HAVE_SYS_SELECT_H
811 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
812 NEXT_SYS_SELECT_H
813 REPLACE_SELECT
814 REPLACE_PSELECT
815 HAVE_PSELECT
816 GNULIB_SELECT
817 GNULIB_PSELECT
818 REPLACE_TIMEGM
819 REPLACE_NANOSLEEP
820 REPLACE_MKTIME
821 REPLACE_LOCALTIME_R
822 HAVE_TIMEGM
823 HAVE_STRPTIME
824 HAVE_NANOSLEEP
825 HAVE_DECL_LOCALTIME_R
826 GNULIB_TIME_R
827 GNULIB_TIMEGM
828 GNULIB_STRPTIME
829 GNULIB_NANOSLEEP
830 GNULIB_MKTIME
831 UNDEFINE_STRTOK_R
832 REPLACE_STRTOK_R
833 REPLACE_STRSIGNAL
834 REPLACE_STRNLEN
835 REPLACE_STRNDUP
836 REPLACE_STRNCAT
837 REPLACE_STRERROR_R
838 REPLACE_STRERROR
839 REPLACE_STRCHRNUL
840 REPLACE_STRCASESTR
841 REPLACE_STRSTR
842 REPLACE_STRDUP
843 REPLACE_STPNCPY
844 REPLACE_MEMMEM
845 REPLACE_MEMCHR
846 HAVE_STRVERSCMP
847 HAVE_DECL_STRSIGNAL
848 HAVE_DECL_STRERROR_R
849 HAVE_DECL_STRTOK_R
850 HAVE_STRCASESTR
851 HAVE_STRSEP
852 HAVE_STRPBRK
853 HAVE_DECL_STRNLEN
854 HAVE_DECL_STRNDUP
855 HAVE_DECL_STRDUP
856 HAVE_STRCHRNUL
857 HAVE_STPNCPY
858 HAVE_STPCPY
859 HAVE_RAWMEMCHR
860 HAVE_DECL_MEMRCHR
861 HAVE_MEMPCPY
862 HAVE_DECL_MEMMEM
863 HAVE_MEMCHR
864 HAVE_FFSLL
865 HAVE_FFSL
866 HAVE_MBSLEN
867 GNULIB_STRVERSCMP
868 GNULIB_STRSIGNAL
869 GNULIB_STRERROR_R
870 GNULIB_STRERROR
871 GNULIB_MBSTOK_R
872 GNULIB_MBSSEP
873 GNULIB_MBSSPN
874 GNULIB_MBSPBRK
875 GNULIB_MBSCSPN
876 GNULIB_MBSCASESTR
877 GNULIB_MBSPCASECMP
878 GNULIB_MBSNCASECMP
879 GNULIB_MBSCASECMP
880 GNULIB_MBSSTR
881 GNULIB_MBSRCHR
882 GNULIB_MBSCHR
883 GNULIB_MBSNLEN
884 GNULIB_MBSLEN
885 GNULIB_STRTOK_R
886 GNULIB_STRCASESTR
887 GNULIB_STRSTR
888 GNULIB_STRSEP
889 GNULIB_STRPBRK
890 GNULIB_STRNLEN
891 GNULIB_STRNDUP
892 GNULIB_STRNCAT
893 GNULIB_STRDUP
894 GNULIB_STRCHRNUL
895 GNULIB_STPNCPY
896 GNULIB_STPCPY
897 GNULIB_RAWMEMCHR
898 GNULIB_MEMRCHR
899 GNULIB_MEMPCPY
900 GNULIB_MEMMEM
901 GNULIB_MEMCHR
902 GNULIB_FFSLL
903 GNULIB_FFSL
904 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
905 NEXT_INTTYPES_H
906 UINT64_MAX_EQ_ULONG_MAX
907 UINT32_MAX_LT_UINTMAX_MAX
908 PRIPTR_PREFIX
909 PRI_MACROS_BROKEN
910 INT64_MAX_EQ_LONG_MAX
911 INT32_MAX_LT_INTMAX_MAX
912 REPLACE_STRTOIMAX
913 HAVE_DECL_STRTOUMAX
914 HAVE_DECL_STRTOIMAX
915 HAVE_DECL_IMAXDIV
916 HAVE_DECL_IMAXABS
917 GNULIB_STRTOUMAX
918 GNULIB_STRTOIMAX
919 GNULIB_IMAXDIV
920 GNULIB_IMAXABS
921 GL_GENERATE_STDINT_H_FALSE
922 GL_GENERATE_STDINT_H_TRUE
923 STDINT_H
924 WINT_T_SUFFIX
925 WCHAR_T_SUFFIX
926 SIG_ATOMIC_T_SUFFIX
927 SIZE_T_SUFFIX
928 PTRDIFF_T_SUFFIX
929 HAVE_SIGNED_WINT_T
930 HAVE_SIGNED_WCHAR_T
931 HAVE_SIGNED_SIG_ATOMIC_T
932 BITSIZEOF_WINT_T
933 BITSIZEOF_WCHAR_T
934 BITSIZEOF_SIG_ATOMIC_T
935 BITSIZEOF_SIZE_T
936 BITSIZEOF_PTRDIFF_T
937 APPLE_UNIVERSAL_BUILD
938 HAVE_SYS_BITYPES_H
939 HAVE_SYS_INTTYPES_H
940 HAVE_STDINT_H
941 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
942 NEXT_STDINT_H
943 HAVE_SYS_TYPES_H
944 HAVE_INTTYPES_H
945 HAVE_WCHAR_H
946 HAVE_UNSIGNED_LONG_LONG_INT
947 HAVE_LONG_LONG_INT
948 HAVE_WINSOCK2_H
949 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
950 NEXT_SYS_TIME_H
951 REPLACE_STRUCT_TIMEVAL
952 REPLACE_GETTIMEOFDAY
953 HAVE_SYS_TIME_H
954 HAVE_STRUCT_TIMEVAL
955 HAVE_GETTIMEOFDAY
956 GNULIB_GETTIMEOFDAY
957 GNULIB_GL_UNISTD_H_GETOPT
958 GETOPT_H
959 HAVE_GETOPT_H
960 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
961 NEXT_GETOPT_H
962 GETLOADAVG_LIBS
963 REPLACE_WCTOMB
964 REPLACE_UNSETENV
965 REPLACE_STRTOD
966 REPLACE_SETENV
967 REPLACE_REALPATH
968 REPLACE_REALLOC
969 REPLACE_RANDOM_R
970 REPLACE_PUTENV
971 REPLACE_PTSNAME_R
972 REPLACE_PTSNAME
973 REPLACE_MKSTEMP
974 REPLACE_MBTOWC
975 REPLACE_MALLOC
976 REPLACE_CANONICALIZE_FILE_NAME
977 REPLACE_CALLOC
978 HAVE_DECL_UNSETENV
979 HAVE_UNLOCKPT
980 HAVE_SYS_LOADAVG_H
981 HAVE_STRUCT_RANDOM_DATA
982 HAVE_STRTOULL
983 HAVE_STRTOLL
984 HAVE_STRTOD
985 HAVE_DECL_SETENV
986 HAVE_SETENV
987 HAVE_SECURE_GETENV
988 HAVE_RPMATCH
989 HAVE_REALPATH
990 HAVE_RANDOM_R
991 HAVE_RANDOM_H
992 HAVE_RANDOM
993 HAVE_PTSNAME_R
994 HAVE_PTSNAME
995 HAVE_POSIX_OPENPT
996 HAVE_MKSTEMPS
997 HAVE_MKSTEMP
998 HAVE_MKOSTEMPS
999 HAVE_MKOSTEMP
1000 HAVE_MKDTEMP
1001 HAVE_GRANTPT
1002 HAVE_GETSUBOPT
1003 HAVE_DECL_GETLOADAVG
1004 HAVE_CANONICALIZE_FILE_NAME
1005 HAVE_ATOLL
1006 HAVE__EXIT
1007 GNULIB_WCTOMB
1008 GNULIB_UNSETENV
1009 GNULIB_UNLOCKPT
1010 GNULIB_SYSTEM_POSIX
1011 GNULIB_STRTOULL
1012 GNULIB_STRTOLL
1013 GNULIB_STRTOD
1014 GNULIB_SETENV
1015 GNULIB_SECURE_GETENV
1016 GNULIB_RPMATCH
1017 GNULIB_REALPATH
1018 GNULIB_REALLOC_POSIX
1019 GNULIB_RANDOM_R
1020 GNULIB_RANDOM
1021 GNULIB_PUTENV
1022 GNULIB_PTSNAME_R
1023 GNULIB_PTSNAME
1024 GNULIB_POSIX_OPENPT
1025 GNULIB_MKSTEMPS
1026 GNULIB_MKSTEMP
1027 GNULIB_MKOSTEMPS
1028 GNULIB_MKOSTEMP
1029 GNULIB_MKDTEMP
1030 GNULIB_MBTOWC
1031 GNULIB_MALLOC_POSIX
1032 GNULIB_GRANTPT
1033 GNULIB_GETSUBOPT
1034 GNULIB_GETLOADAVG
1035 GNULIB_CANONICALIZE_FILE_NAME
1036 GNULIB_CALLOC_POSIX
1037 GNULIB_ATOLL
1038 GNULIB__EXIT
1039 REPLACE_UTIMENSAT
1040 REPLACE_STAT
1041 REPLACE_MKNOD
1042 REPLACE_MKFIFO
1043 REPLACE_MKDIR
1044 REPLACE_LSTAT
1045 REPLACE_FUTIMENS
1046 REPLACE_FSTATAT
1047 REPLACE_FSTAT
1048 HAVE_UTIMENSAT
1049 HAVE_MKNODAT
1050 HAVE_MKNOD
1051 HAVE_MKFIFOAT
1052 HAVE_MKFIFO
1053 HAVE_MKDIRAT
1054 HAVE_LSTAT
1055 HAVE_LCHMOD
1056 HAVE_FUTIMENS
1057 HAVE_FSTATAT
1058 HAVE_FCHMODAT
1059 GNULIB_UTIMENSAT
1060 GNULIB_STAT
1061 GNULIB_MKNODAT
1062 GNULIB_MKNOD
1063 GNULIB_MKFIFOAT
1064 GNULIB_MKFIFO
1065 GNULIB_MKDIRAT
1066 GNULIB_LSTAT
1067 GNULIB_LCHMOD
1068 GNULIB_FUTIMENS
1069 GNULIB_FSTATAT
1070 GNULIB_FSTAT
1071 GNULIB_FCHMODAT
1072 LIB_FDATASYNC
1073 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1074 NEXT_FCNTL_H
1075 REPLACE_OPENAT
1076 REPLACE_OPEN
1077 REPLACE_FCNTL
1078 HAVE_OPENAT
1079 HAVE_FCNTL
1080 GNULIB_OPENAT
1081 GNULIB_OPEN
1082 GNULIB_NONBLOCKING
1083 GNULIB_FCNTL
1084 GL_GENERATE_EXECINFO_H_FALSE
1085 GL_GENERATE_EXECINFO_H_TRUE
1086 LIB_EXECINFO
1087 EXECINFO_H
1088 EOVERFLOW_VALUE
1089 EOVERFLOW_HIDDEN
1090 ENOLINK_VALUE
1091 ENOLINK_HIDDEN
1092 EMULTIHOP_VALUE
1093 EMULTIHOP_HIDDEN
1094 GL_GENERATE_ERRNO_H_FALSE
1095 GL_GENERATE_ERRNO_H_TRUE
1096 ERRNO_H
1097 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1098 NEXT_ERRNO_H
1099 HAVE_DIRENT_H
1100 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1101 NEXT_DIRENT_H
1102 PRAGMA_COLUMNS
1103 PRAGMA_SYSTEM_HEADER
1104 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1105 INCLUDE_NEXT
1106 REPLACE_FDOPENDIR
1107 REPLACE_DIRFD
1108 REPLACE_CLOSEDIR
1109 REPLACE_OPENDIR
1110 HAVE_ALPHASORT
1111 HAVE_SCANDIR
1112 HAVE_FDOPENDIR
1113 HAVE_DECL_FDOPENDIR
1114 HAVE_DECL_DIRFD
1115 HAVE_CLOSEDIR
1116 HAVE_REWINDDIR
1117 HAVE_READDIR
1118 HAVE_OPENDIR
1119 GNULIB_ALPHASORT
1120 GNULIB_SCANDIR
1121 GNULIB_FDOPENDIR
1122 GNULIB_DIRFD
1123 GNULIB_CLOSEDIR
1124 GNULIB_REWINDDIR
1125 GNULIB_READDIR
1126 GNULIB_OPENDIR
1127 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1128 UNISTD_H_HAVE_WINSOCK2_H
1129 REPLACE_WRITE
1130 REPLACE_USLEEP
1131 REPLACE_UNLINKAT
1132 REPLACE_UNLINK
1133 REPLACE_TTYNAME_R
1134 REPLACE_SYMLINK
1135 REPLACE_SLEEP
1136 REPLACE_RMDIR
1137 REPLACE_READLINK
1138 REPLACE_READ
1139 REPLACE_PWRITE
1140 REPLACE_PREAD
1141 REPLACE_LSEEK
1142 REPLACE_LINKAT
1143 REPLACE_LINK
1144 REPLACE_LCHOWN
1145 REPLACE_ISATTY
1146 REPLACE_GETPAGESIZE
1147 REPLACE_GETGROUPS
1148 REPLACE_GETLOGIN_R
1149 REPLACE_GETDOMAINNAME
1150 REPLACE_GETCWD
1151 REPLACE_FTRUNCATE
1152 REPLACE_FCHOWNAT
1153 REPLACE_DUP2
1154 REPLACE_DUP
1155 REPLACE_CLOSE
1156 REPLACE_CHOWN
1157 HAVE_SYS_PARAM_H
1158 HAVE_OS_H
1159 HAVE_DECL_TTYNAME_R
1160 HAVE_DECL_SETHOSTNAME
1161 HAVE_DECL_GETUSERSHELL
1162 HAVE_DECL_GETPAGESIZE
1163 HAVE_DECL_GETLOGIN_R
1164 HAVE_DECL_GETDOMAINNAME
1165 HAVE_DECL_FDATASYNC
1166 HAVE_DECL_FCHDIR
1167 HAVE_DECL_ENVIRON
1168 HAVE_USLEEP
1169 HAVE_UNLINKAT
1170 HAVE_SYMLINKAT
1171 HAVE_SYMLINK
1172 HAVE_SLEEP
1173 HAVE_SETHOSTNAME
1174 HAVE_READLINKAT
1175 HAVE_READLINK
1176 HAVE_PWRITE
1177 HAVE_PREAD
1178 HAVE_PIPE2
1179 HAVE_PIPE
1180 HAVE_LINKAT
1181 HAVE_LINK
1182 HAVE_LCHOWN
1183 HAVE_GROUP_MEMBER
1184 HAVE_GETPAGESIZE
1185 HAVE_GETLOGIN
1186 HAVE_GETHOSTNAME
1187 HAVE_GETGROUPS
1188 HAVE_GETDTABLESIZE
1189 HAVE_FTRUNCATE
1190 HAVE_FSYNC
1191 HAVE_FDATASYNC
1192 HAVE_FCHOWNAT
1193 HAVE_FCHDIR
1194 HAVE_FACCESSAT
1195 HAVE_EUIDACCESS
1196 HAVE_DUP3
1197 HAVE_DUP2
1198 HAVE_CHOWN
1199 GNULIB_WRITE
1200 GNULIB_USLEEP
1201 GNULIB_UNLINKAT
1202 GNULIB_UNLINK
1203 GNULIB_UNISTD_H_SIGPIPE
1204 GNULIB_UNISTD_H_NONBLOCKING
1205 GNULIB_TTYNAME_R
1206 GNULIB_SYMLINKAT
1207 GNULIB_SYMLINK
1208 GNULIB_SLEEP
1209 GNULIB_SETHOSTNAME
1210 GNULIB_RMDIR
1211 GNULIB_READLINKAT
1212 GNULIB_READLINK
1213 GNULIB_READ
1214 GNULIB_PWRITE
1215 GNULIB_PREAD
1216 GNULIB_PIPE2
1217 GNULIB_PIPE
1218 GNULIB_LSEEK
1219 GNULIB_LINKAT
1220 GNULIB_LINK
1221 GNULIB_LCHOWN
1222 GNULIB_ISATTY
1223 GNULIB_GROUP_MEMBER
1224 GNULIB_GETUSERSHELL
1225 GNULIB_GETPAGESIZE
1226 GNULIB_GETLOGIN_R
1227 GNULIB_GETLOGIN
1228 GNULIB_GETHOSTNAME
1229 GNULIB_GETGROUPS
1230 GNULIB_GETDTABLESIZE
1231 GNULIB_GETDOMAINNAME
1232 GNULIB_GETCWD
1233 GNULIB_FTRUNCATE
1234 GNULIB_FSYNC
1235 GNULIB_FDATASYNC
1236 GNULIB_FCHOWNAT
1237 GNULIB_FCHDIR
1238 GNULIB_FACCESSAT
1239 GNULIB_EUIDACCESS
1240 GNULIB_ENVIRON
1241 GNULIB_DUP3
1242 GNULIB_DUP2
1243 GNULIB_DUP
1244 GNULIB_CLOSE
1245 GNULIB_CHOWN
1246 GNULIB_CHDIR
1247 LIB_CLOCK_GETTIME
1248 GL_GENERATE_ALLOCA_H_FALSE
1249 GL_GENERATE_ALLOCA_H_TRUE
1250 ALLOCA_H
1251 ALLOCA
1252 GL_COND_LIBTOOL_FALSE
1253 GL_COND_LIBTOOL_TRUE
1254 POST_ALLOC_OBJ
1255 PRE_ALLOC_OBJ
1256 CYGWIN_OBJ
1257 RALLOC_OBJ
1258 OLDXMENU_DEPS
1259 LIBX_OTHER
1260 LIBXMENU
1261 OLDXMENU
1262 OLDXMENU_TARGET
1263 LIBXT_OTHER
1264 TOOLKIT_LIBW
1265 WIDGET_OBJ
1266 XOBJ
1267 XMENU_OBJ
1268 FONT_OBJ
1269 OTHER_FILES
1270 GNU_OBJC_CFLAGS
1271 ns_appsrc
1272 ns_appresdir
1273 ns_appbindir
1274 ns_appdir
1275 X_TOOLKIT_TYPE
1276 GNUSTEP_CFLAGS
1277 C_SWITCH_X_SITE
1278 LD_SWITCH_X_SITE
1279 gameuser
1280 gamedir
1281 bitmapdir
1282 etcdocdir
1283 archlibdir
1284 etcdir
1285 x_default_search_path
1286 lisppath
1287 locallisppath
1288 standardlisppath
1289 leimdir
1290 lispdir
1291 srcdir
1292 canonical
1293 configuration
1294 version
1295 copyright
1296 XGSELOBJ
1297 KRB4LIB
1298 DESLIB
1299 KRB5LIB
1300 CRYPTOLIB
1301 COM_ERRLIB
1302 LIBRESOLV
1303 LIBHESIOD
1304 TERMCAP_OBJ
1305 LIBS_TERMCAP
1306 BLESSMAIL_TARGET
1307 LIBS_MAIL
1308 liblockfile
1309 LIBXML2_LIBS
1310 LIBXML2_CFLAGS
1311 XINERAMA_LIBS
1312 XINERAMA_CFLAGS
1313 XRANDR_LIBS
1314 XRANDR_CFLAGS
1315 LIBXSM
1316 LIBGPM
1317 LIBGIF
1318 LIBTIFF
1319 LIBZ
1320 LIBPNG
1321 LIBJPEG
1322 LIBXPM
1323 M17N_FLT_LIBS
1324 M17N_FLT_CFLAGS
1325 LIBOTF_LIBS
1326 LIBOTF_CFLAGS
1327 FREETYPE_LIBS
1328 FREETYPE_CFLAGS
1329 XFT_LIBS
1330 XFT_CFLAGS
1331 FONTCONFIG_LIBS
1332 FONTCONFIG_CFLAGS
1333 LIBXMU
1334 LIBXTR6
1335 NOTIFY_OBJ
1336 GFILENOTIFY_LIBS
1337 GFILENOTIFY_CFLAGS
1338 LIBGNUTLS_LIBS
1339 LIBGNUTLS_CFLAGS
1340 LIBSELINUX_LIBS
1341 SETTINGS_LIBS
1342 SETTINGS_CFLAGS
1343 GOBJECT_LIBS
1344 GOBJECT_CFLAGS
1345 GCONF_LIBS
1346 GCONF_CFLAGS
1347 GSETTINGS_LIBS
1348 GSETTINGS_CFLAGS
1349 DBUS_OBJ
1350 DBUS_LIBS
1351 DBUS_CFLAGS
1352 GTK_OBJ
1353 GTK_LIBS
1354 GTK_CFLAGS
1355 IMAGEMAGICK_LIBS
1356 IMAGEMAGICK_CFLAGS
1357 RSVG_LIBS
1358 RSVG_CFLAGS
1359 LIB_PTHREAD
1360 VMLIMIT_OBJ
1361 GMALLOC_OBJ
1362 HAVE_XSERVER
1363 XARGS_LIMIT
1364 NTLIB
1365 LIB_WSOCK32
1366 LIBS_ECLIENT
1367 CM_OBJ
1368 NTDIR
1369 FIRSTFILE_OBJ
1370 W32_RES_LINK
1371 CLIENTW
1372 CLIENTRES
1373 UPDATE_MANIFEST
1374 EMACS_MANIFEST
1375 EMACSRES
1376 W32_LIBS
1377 W32_OBJ
1378 WINDRES
1379 NS_OBJC_OBJ
1380 NS_OBJ
1381 ns_self_contained
1382 INSTALL_ARCH_INDEP_EXTRA
1383 LIBS_GNUSTEP
1384 LD_SWITCH_X_SITE_RPATH
1385 XMKMF
1386 DEPFLAGS
1387 MKDEPDIR
1388 CFLAGS_SOUND
1389 ALSA_LIBS
1390 ALSA_CFLAGS
1391 LIBSOUND
1392 PKG_CONFIG
1393 LIB_MATH
1394 LIBS_SYSTEM
1395 C_SWITCH_SYSTEM
1396 UNEXEC_OBJ
1397 C_SWITCH_MACHINE
1398 LD_SWITCH_SYSTEM
1399 CANNOT_DUMP
1400 INFO_OPTS
1401 INFO_EXT
1402 HAVE_MAKEINFO
1403 PAXCTL
1404 GZIP_PROG
1405 INSTALL_INFO
1406 LN_S_FILEONLY
1407 GNULIB_WARN_CFLAGS
1408 WARN_CFLAGS
1409 WERROR_CFLAGS
1410 RANLIB
1411 ARFLAGS
1413 EGREP
1414 GREP
1416 BUILDING_FOR_WINDOWSNT_FALSE
1417 BUILDING_FOR_WINDOWSNT_TRUE
1418 am__fastdepCC_FALSE
1419 am__fastdepCC_TRUE
1420 CCDEPMODE
1421 AMDEPBACKSLASH
1422 AMDEP_FALSE
1423 AMDEP_TRUE
1424 am__quote
1425 am__include
1426 DEPDIR
1427 OBJEXT
1428 EXEEXT
1429 ac_ct_CC
1430 CPPFLAGS
1431 LDFLAGS
1432 CFLAGS
1434 host_os
1435 host_vendor
1436 host_cpu
1437 host
1438 build_os
1439 build_vendor
1440 build_cpu
1441 build
1442 PROFILING_CFLAGS
1443 GZIP_INFO
1444 cache_file
1445 am__untar
1446 am__tar
1447 AMTAR
1448 am__leading_dot
1449 SET_MAKE
1451 mkdir_p
1452 MKDIR_P
1453 INSTALL_STRIP_PROGRAM
1454 STRIP
1455 install_sh
1456 MAKEINFO
1457 AUTOHEADER
1458 AUTOMAKE
1459 AUTOCONF
1460 ACLOCAL
1461 VERSION
1462 PACKAGE
1463 CYGPATH_W
1464 am__isrc
1465 INSTALL_DATA
1466 INSTALL_SCRIPT
1467 INSTALL_PROGRAM
1468 target_alias
1469 host_alias
1470 build_alias
1471 LIBS
1472 ECHO_T
1473 ECHO_N
1474 ECHO_C
1475 DEFS
1476 mandir
1477 localedir
1478 libdir
1479 psdir
1480 pdfdir
1481 dvidir
1482 htmldir
1483 infodir
1484 docdir
1485 oldincludedir
1486 includedir
1487 localstatedir
1488 sharedstatedir
1489 sysconfdir
1490 datadir
1491 datarootdir
1492 libexecdir
1493 sbindir
1494 bindir
1495 program_transform_name
1496 prefix
1497 exec_prefix
1498 PACKAGE_URL
1499 PACKAGE_BUGREPORT
1500 PACKAGE_STRING
1501 PACKAGE_VERSION
1502 PACKAGE_TARNAME
1503 PACKAGE_NAME
1504 PATH_SEPARATOR
1505 SHELL'
1506 ac_subst_files='deps_frag
1507 lisp_frag'
1508 ac_user_opts='
1509 enable_option_checking
1510 with_all
1511 with_pop
1512 with_kerberos
1513 with_kerberos5
1514 with_hesiod
1515 with_mmdf
1516 with_mail_unlink
1517 with_mailhost
1518 with_sound
1519 with_x_toolkit
1520 with_wide_int
1521 with_xpm
1522 with_jpeg
1523 with_tiff
1524 with_gif
1525 with_png
1526 with_rsvg
1527 with_xml2
1528 with_imagemagick
1529 with_xft
1530 with_libotf
1531 with_m17n_flt
1532 with_toolkit_scroll_bars
1533 with_xaw3d
1534 with_xim
1535 with_ns
1536 with_w32
1537 with_gpm
1538 with_dbus
1539 with_gconf
1540 with_gsettings
1541 with_selinux
1542 with_gnutls
1543 with_zlib
1544 with_file_notification
1545 with_makeinfo
1546 with_compress_info
1547 with_pkg_config_prog
1548 with_gameuser
1549 with_gnustep_conf
1550 enable_ns_self_contained
1551 enable_locallisppath
1552 enable_checking
1553 enable_check_lisp_object_type
1554 enable_profiling
1555 enable_autodepend
1556 enable_gtk_deprecation_warnings
1557 enable_dependency_tracking
1558 enable_largefile
1559 enable_gcc_warnings
1560 enable_link_time_optimization
1561 with_x
1562 enable_acl
1564 ac_precious_vars='build_alias
1565 host_alias
1566 target_alias
1568 CFLAGS
1569 LDFLAGS
1570 LIBS
1571 CPPFLAGS
1573 XMKMF'
1576 # Initialize some variables set by options.
1577 ac_init_help=
1578 ac_init_version=false
1579 ac_unrecognized_opts=
1580 ac_unrecognized_sep=
1581 # The variables have the same names as the options, with
1582 # dashes changed to underlines.
1583 cache_file=/dev/null
1584 exec_prefix=NONE
1585 no_create=
1586 no_recursion=
1587 prefix=NONE
1588 program_prefix=NONE
1589 program_suffix=NONE
1590 program_transform_name=s,x,x,
1591 silent=
1592 site=
1593 srcdir=
1594 verbose=
1595 x_includes=NONE
1596 x_libraries=NONE
1598 # Installation directory options.
1599 # These are left unexpanded so users can "make install exec_prefix=/foo"
1600 # and all the variables that are supposed to be based on exec_prefix
1601 # by default will actually change.
1602 # Use braces instead of parens because sh, perl, etc. also accept them.
1603 # (The list follows the same order as the GNU Coding Standards.)
1604 bindir='${exec_prefix}/bin'
1605 sbindir='${exec_prefix}/sbin'
1606 libexecdir='${exec_prefix}/libexec'
1607 datarootdir='${prefix}/share'
1608 datadir='${datarootdir}'
1609 sysconfdir='${prefix}/etc'
1610 sharedstatedir='${prefix}/com'
1611 localstatedir='${prefix}/var'
1612 includedir='${prefix}/include'
1613 oldincludedir='/usr/include'
1614 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1615 infodir='${datarootdir}/info'
1616 htmldir='${docdir}'
1617 dvidir='${docdir}'
1618 pdfdir='${docdir}'
1619 psdir='${docdir}'
1620 libdir='${exec_prefix}/lib'
1621 localedir='${datarootdir}/locale'
1622 mandir='${datarootdir}/man'
1624 ac_prev=
1625 ac_dashdash=
1626 for ac_option
1628 # If the previous option needs an argument, assign it.
1629 if test -n "$ac_prev"; then
1630 eval $ac_prev=\$ac_option
1631 ac_prev=
1632 continue
1635 case $ac_option in
1636 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1637 *) ac_optarg=yes ;;
1638 esac
1640 # Accept the important Cygnus configure options, so we can diagnose typos.
1642 case $ac_dashdash$ac_option in
1644 ac_dashdash=yes ;;
1646 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1647 ac_prev=bindir ;;
1648 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1649 bindir=$ac_optarg ;;
1651 -build | --build | --buil | --bui | --bu)
1652 ac_prev=build_alias ;;
1653 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1654 build_alias=$ac_optarg ;;
1656 -cache-file | --cache-file | --cache-fil | --cache-fi \
1657 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1658 ac_prev=cache_file ;;
1659 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1660 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1661 cache_file=$ac_optarg ;;
1663 --config-cache | -C)
1664 cache_file=config.cache ;;
1666 -datadir | --datadir | --datadi | --datad)
1667 ac_prev=datadir ;;
1668 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1669 datadir=$ac_optarg ;;
1671 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1672 | --dataroo | --dataro | --datar)
1673 ac_prev=datarootdir ;;
1674 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1675 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1676 datarootdir=$ac_optarg ;;
1678 -disable-* | --disable-*)
1679 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1680 # Reject names that are not valid shell variable names.
1681 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1682 as_fn_error "invalid feature name: $ac_useropt"
1683 ac_useropt_orig=$ac_useropt
1684 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1685 case $ac_user_opts in
1687 "enable_$ac_useropt"
1688 "*) ;;
1689 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1690 ac_unrecognized_sep=', ';;
1691 esac
1692 eval enable_$ac_useropt=no ;;
1694 -docdir | --docdir | --docdi | --doc | --do)
1695 ac_prev=docdir ;;
1696 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1697 docdir=$ac_optarg ;;
1699 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1700 ac_prev=dvidir ;;
1701 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1702 dvidir=$ac_optarg ;;
1704 -enable-* | --enable-*)
1705 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1706 # Reject names that are not valid shell variable names.
1707 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1708 as_fn_error "invalid feature name: $ac_useropt"
1709 ac_useropt_orig=$ac_useropt
1710 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1711 case $ac_user_opts in
1713 "enable_$ac_useropt"
1714 "*) ;;
1715 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1716 ac_unrecognized_sep=', ';;
1717 esac
1718 eval enable_$ac_useropt=\$ac_optarg ;;
1720 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1721 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1722 | --exec | --exe | --ex)
1723 ac_prev=exec_prefix ;;
1724 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1725 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1726 | --exec=* | --exe=* | --ex=*)
1727 exec_prefix=$ac_optarg ;;
1729 -gas | --gas | --ga | --g)
1730 # Obsolete; use --with-gas.
1731 with_gas=yes ;;
1733 -help | --help | --hel | --he | -h)
1734 ac_init_help=long ;;
1735 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1736 ac_init_help=recursive ;;
1737 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1738 ac_init_help=short ;;
1740 -host | --host | --hos | --ho)
1741 ac_prev=host_alias ;;
1742 -host=* | --host=* | --hos=* | --ho=*)
1743 host_alias=$ac_optarg ;;
1745 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1746 ac_prev=htmldir ;;
1747 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1748 | --ht=*)
1749 htmldir=$ac_optarg ;;
1751 -includedir | --includedir | --includedi | --included | --include \
1752 | --includ | --inclu | --incl | --inc)
1753 ac_prev=includedir ;;
1754 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1755 | --includ=* | --inclu=* | --incl=* | --inc=*)
1756 includedir=$ac_optarg ;;
1758 -infodir | --infodir | --infodi | --infod | --info | --inf)
1759 ac_prev=infodir ;;
1760 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1761 infodir=$ac_optarg ;;
1763 -libdir | --libdir | --libdi | --libd)
1764 ac_prev=libdir ;;
1765 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1766 libdir=$ac_optarg ;;
1768 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1769 | --libexe | --libex | --libe)
1770 ac_prev=libexecdir ;;
1771 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1772 | --libexe=* | --libex=* | --libe=*)
1773 libexecdir=$ac_optarg ;;
1775 -localedir | --localedir | --localedi | --localed | --locale)
1776 ac_prev=localedir ;;
1777 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1778 localedir=$ac_optarg ;;
1780 -localstatedir | --localstatedir | --localstatedi | --localstated \
1781 | --localstate | --localstat | --localsta | --localst | --locals)
1782 ac_prev=localstatedir ;;
1783 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1784 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1785 localstatedir=$ac_optarg ;;
1787 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1788 ac_prev=mandir ;;
1789 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1790 mandir=$ac_optarg ;;
1792 -nfp | --nfp | --nf)
1793 # Obsolete; use --without-fp.
1794 with_fp=no ;;
1796 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1797 | --no-cr | --no-c | -n)
1798 no_create=yes ;;
1800 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1801 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1802 no_recursion=yes ;;
1804 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1805 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1806 | --oldin | --oldi | --old | --ol | --o)
1807 ac_prev=oldincludedir ;;
1808 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1809 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1810 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1811 oldincludedir=$ac_optarg ;;
1813 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1814 ac_prev=prefix ;;
1815 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1816 prefix=$ac_optarg ;;
1818 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1819 | --program-pre | --program-pr | --program-p)
1820 ac_prev=program_prefix ;;
1821 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1822 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1823 program_prefix=$ac_optarg ;;
1825 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1826 | --program-suf | --program-su | --program-s)
1827 ac_prev=program_suffix ;;
1828 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1829 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1830 program_suffix=$ac_optarg ;;
1832 -program-transform-name | --program-transform-name \
1833 | --program-transform-nam | --program-transform-na \
1834 | --program-transform-n | --program-transform- \
1835 | --program-transform | --program-transfor \
1836 | --program-transfo | --program-transf \
1837 | --program-trans | --program-tran \
1838 | --progr-tra | --program-tr | --program-t)
1839 ac_prev=program_transform_name ;;
1840 -program-transform-name=* | --program-transform-name=* \
1841 | --program-transform-nam=* | --program-transform-na=* \
1842 | --program-transform-n=* | --program-transform-=* \
1843 | --program-transform=* | --program-transfor=* \
1844 | --program-transfo=* | --program-transf=* \
1845 | --program-trans=* | --program-tran=* \
1846 | --progr-tra=* | --program-tr=* | --program-t=*)
1847 program_transform_name=$ac_optarg ;;
1849 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1850 ac_prev=pdfdir ;;
1851 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1852 pdfdir=$ac_optarg ;;
1854 -psdir | --psdir | --psdi | --psd | --ps)
1855 ac_prev=psdir ;;
1856 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1857 psdir=$ac_optarg ;;
1859 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1860 | -silent | --silent | --silen | --sile | --sil)
1861 silent=yes ;;
1863 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1864 ac_prev=sbindir ;;
1865 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1866 | --sbi=* | --sb=*)
1867 sbindir=$ac_optarg ;;
1869 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1870 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1871 | --sharedst | --shareds | --shared | --share | --shar \
1872 | --sha | --sh)
1873 ac_prev=sharedstatedir ;;
1874 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1875 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1876 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1877 | --sha=* | --sh=*)
1878 sharedstatedir=$ac_optarg ;;
1880 -site | --site | --sit)
1881 ac_prev=site ;;
1882 -site=* | --site=* | --sit=*)
1883 site=$ac_optarg ;;
1885 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1886 ac_prev=srcdir ;;
1887 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1888 srcdir=$ac_optarg ;;
1890 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1891 | --syscon | --sysco | --sysc | --sys | --sy)
1892 ac_prev=sysconfdir ;;
1893 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1894 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1895 sysconfdir=$ac_optarg ;;
1897 -target | --target | --targe | --targ | --tar | --ta | --t)
1898 ac_prev=target_alias ;;
1899 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1900 target_alias=$ac_optarg ;;
1902 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1903 verbose=yes ;;
1905 -version | --version | --versio | --versi | --vers | -V)
1906 ac_init_version=: ;;
1908 -with-* | --with-*)
1909 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1910 # Reject names that are not valid shell variable names.
1911 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1912 as_fn_error "invalid package name: $ac_useropt"
1913 ac_useropt_orig=$ac_useropt
1914 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1915 case $ac_user_opts in
1917 "with_$ac_useropt"
1918 "*) ;;
1919 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1920 ac_unrecognized_sep=', ';;
1921 esac
1922 eval with_$ac_useropt=\$ac_optarg ;;
1924 -without-* | --without-*)
1925 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1926 # Reject names that are not valid shell variable names.
1927 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1928 as_fn_error "invalid package name: $ac_useropt"
1929 ac_useropt_orig=$ac_useropt
1930 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1931 case $ac_user_opts in
1933 "with_$ac_useropt"
1934 "*) ;;
1935 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1936 ac_unrecognized_sep=', ';;
1937 esac
1938 eval with_$ac_useropt=no ;;
1940 --x)
1941 # Obsolete; use --with-x.
1942 with_x=yes ;;
1944 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1945 | --x-incl | --x-inc | --x-in | --x-i)
1946 ac_prev=x_includes ;;
1947 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1948 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1949 x_includes=$ac_optarg ;;
1951 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1952 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1953 ac_prev=x_libraries ;;
1954 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1955 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1956 x_libraries=$ac_optarg ;;
1958 -*) as_fn_error "unrecognized option: \`$ac_option'
1959 Try \`$0 --help' for more information."
1962 *=*)
1963 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1964 # Reject names that are not valid shell variable names.
1965 case $ac_envvar in #(
1966 '' | [0-9]* | *[!_$as_cr_alnum]* )
1967 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1968 esac
1969 eval $ac_envvar=\$ac_optarg
1970 export $ac_envvar ;;
1973 # FIXME: should be removed in autoconf 3.0.
1974 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1975 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1976 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1977 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1980 esac
1981 done
1983 if test -n "$ac_prev"; then
1984 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1985 as_fn_error "missing argument to $ac_option"
1988 if test -n "$ac_unrecognized_opts"; then
1989 case $enable_option_checking in
1990 no) ;;
1991 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1992 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1993 esac
1996 # Check all directory arguments for consistency.
1997 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1998 datadir sysconfdir sharedstatedir localstatedir includedir \
1999 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2000 libdir localedir mandir
2002 eval ac_val=\$$ac_var
2003 # Remove trailing slashes.
2004 case $ac_val in
2005 */ )
2006 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2007 eval $ac_var=\$ac_val;;
2008 esac
2009 # Be sure to have absolute directory names.
2010 case $ac_val in
2011 [\\/$]* | ?:[\\/]* ) continue;;
2012 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2013 esac
2014 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2015 done
2017 # There might be people who depend on the old broken behavior: `$host'
2018 # used to hold the argument of --host etc.
2019 # FIXME: To remove some day.
2020 build=$build_alias
2021 host=$host_alias
2022 target=$target_alias
2024 # FIXME: To remove some day.
2025 if test "x$host_alias" != x; then
2026 if test "x$build_alias" = x; then
2027 cross_compiling=maybe
2028 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2029 If a cross compiler is detected then cross compile mode will be used." >&2
2030 elif test "x$build_alias" != "x$host_alias"; then
2031 cross_compiling=yes
2035 ac_tool_prefix=
2036 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2038 test "$silent" = yes && exec 6>/dev/null
2041 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2042 ac_ls_di=`ls -di .` &&
2043 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2044 as_fn_error "working directory cannot be determined"
2045 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2046 as_fn_error "pwd does not report name of working directory"
2049 # Find the source files, if location was not specified.
2050 if test -z "$srcdir"; then
2051 ac_srcdir_defaulted=yes
2052 # Try the directory containing this script, then the parent directory.
2053 ac_confdir=`$as_dirname -- "$as_myself" ||
2054 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2055 X"$as_myself" : 'X\(//\)[^/]' \| \
2056 X"$as_myself" : 'X\(//\)$' \| \
2057 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2058 $as_echo X"$as_myself" |
2059 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2060 s//\1/
2063 /^X\(\/\/\)[^/].*/{
2064 s//\1/
2067 /^X\(\/\/\)$/{
2068 s//\1/
2071 /^X\(\/\).*/{
2072 s//\1/
2075 s/.*/./; q'`
2076 srcdir=$ac_confdir
2077 if test ! -r "$srcdir/$ac_unique_file"; then
2078 srcdir=..
2080 else
2081 ac_srcdir_defaulted=no
2083 if test ! -r "$srcdir/$ac_unique_file"; then
2084 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2085 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2087 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2088 ac_abs_confdir=`(
2089 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2090 pwd)`
2091 # When building in place, set srcdir=.
2092 if test "$ac_abs_confdir" = "$ac_pwd"; then
2093 srcdir=.
2095 # Remove unnecessary trailing slashes from srcdir.
2096 # Double slashes in file names in object file debugging info
2097 # mess up M-x gdb in Emacs.
2098 case $srcdir in
2099 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2100 esac
2101 for ac_var in $ac_precious_vars; do
2102 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2103 eval ac_env_${ac_var}_value=\$${ac_var}
2104 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2105 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2106 done
2109 # Report the --help message.
2111 if test "$ac_init_help" = "long"; then
2112 # Omit some internal or obsolete options to make the list less imposing.
2113 # This message is too long to be a string in the A/UX 3.1 sh.
2114 cat <<_ACEOF
2115 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
2117 Usage: $0 [OPTION]... [VAR=VALUE]...
2119 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2120 VAR=VALUE. See below for descriptions of some of the useful variables.
2122 Defaults for the options are specified in brackets.
2124 Configuration:
2125 -h, --help display this help and exit
2126 --help=short display options specific to this package
2127 --help=recursive display the short help of all the included packages
2128 -V, --version display version information and exit
2129 -q, --quiet, --silent do not print \`checking...' messages
2130 --cache-file=FILE cache test results in FILE [disabled]
2131 -C, --config-cache alias for \`--cache-file=config.cache'
2132 -n, --no-create do not create output files
2133 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2135 Installation directories:
2136 --prefix=PREFIX install architecture-independent files in PREFIX
2137 [$ac_default_prefix]
2138 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2139 [PREFIX]
2141 By default, \`make install' will install all the files in
2142 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2143 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2144 for instance \`--prefix=\$HOME'.
2146 For better control, use the options below.
2148 Fine tuning of the installation directories:
2149 --bindir=DIR user executables [EPREFIX/bin]
2150 --sbindir=DIR system admin executables [EPREFIX/sbin]
2151 --libexecdir=DIR program executables [EPREFIX/libexec]
2152 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2153 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2154 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2155 --libdir=DIR object code libraries [EPREFIX/lib]
2156 --includedir=DIR C header files [PREFIX/include]
2157 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2158 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2159 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2160 --infodir=DIR info documentation [DATAROOTDIR/info]
2161 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2162 --mandir=DIR man documentation [DATAROOTDIR/man]
2163 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2164 --htmldir=DIR html documentation [DOCDIR]
2165 --dvidir=DIR dvi documentation [DOCDIR]
2166 --pdfdir=DIR pdf documentation [DOCDIR]
2167 --psdir=DIR ps documentation [DOCDIR]
2168 _ACEOF
2170 cat <<\_ACEOF
2172 Program names:
2173 --program-prefix=PREFIX prepend PREFIX to installed program names
2174 --program-suffix=SUFFIX append SUFFIX to installed program names
2175 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2177 X features:
2178 --x-includes=DIR X include files are in DIR
2179 --x-libraries=DIR X library files are in DIR
2181 System types:
2182 --build=BUILD configure for building on BUILD [guessed]
2183 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2184 _ACEOF
2187 if test -n "$ac_init_help"; then
2188 case $ac_init_help in
2189 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2190 esac
2191 cat <<\_ACEOF
2193 Optional Features:
2194 --disable-option-checking ignore unrecognized --enable/--with options
2195 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2196 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2197 --disable-ns-self-contained
2198 disable self contained build under NeXTstep
2199 --enable-locallisppath=PATH
2200 directories Emacs should search for lisp files
2201 specific to this site
2202 --enable-checking[=LIST]
2203 enable expensive run-time checks. With LIST, enable
2204 only specific categories of checks. Categories are:
2205 all,yes,no. Flags are: stringbytes, stringoverrun,
2206 stringfreelist, xmallocoverrun, conslist, glyphs
2207 --enable-check-lisp-object-type
2208 enable compile time checks for the Lisp_Object data
2209 type. This is useful for development for catching
2210 certain types of bugs.
2211 --enable-profiling build emacs with low-level, gprof profiling support.
2212 Mainly useful for debugging Emacs itself. May not
2213 work on all platforms. Stops profiler.el working.
2214 --enable-autodepend automatically generate dependencies to .h-files.
2215 Requires GNU Make and Gcc. Enabled if GNU Make and
2216 Gcc is found
2217 --enable-gtk-deprecation-warnings
2218 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2219 --disable-dependency-tracking speeds up one-time build
2220 --enable-dependency-tracking do not reject slow dependency extractors
2221 --disable-largefile omit support for large files
2222 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2223 intended for developers, and may generate false
2224 alarms when used with older or non-GNU development
2225 tools.
2226 --enable-link-time-optimization
2227 build emacs with link-time optimization. This is
2228 supported only for GCC since 4.5.0.
2229 --disable-acl do not support ACLs
2231 Optional Packages:
2232 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2233 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2234 --without-all omit almost all features and build small executable
2235 with minimal dependencies
2236 --without-pop don't support POP mail retrieval with movemail
2237 --with-kerberos support Kerberos-authenticated POP
2238 --with-kerberos5 support Kerberos version 5 authenticated POP
2239 --with-hesiod support Hesiod to get the POP server host
2240 --with-mmdf support MMDF mailboxes
2241 --with-mail-unlink unlink, rather than empty, mail spool after reading
2242 --with-mailhost=HOSTNAME
2243 string giving default POP mail host
2244 --with-sound=VALUE compile with sound support (VALUE one of: yes,
2245 ossaudio, alsa, no; default yes). Only for
2246 GNU/Linux, FreeBSD, NetBSD, MinGW.
2247 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2248 gtk3, lucid or athena, motif, no)
2249 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2250 --without-xpm don't compile with XPM image support
2251 --without-jpeg don't compile with JPEG image support
2252 --without-tiff don't compile with TIFF image support
2253 --without-gif don't compile with GIF image support
2254 --without-png don't compile with PNG image support
2255 --without-rsvg don't compile with SVG image support
2256 --without-xml2 don't compile with XML parsing support
2257 --without-imagemagick don't compile with ImageMagick image support
2258 --without-xft don't use XFT for anti aliased fonts
2259 --without-libotf don't use libotf for OpenType font support
2260 --without-m17n-flt don't use m17n-flt for text shaping
2261 --without-toolkit-scroll-bars
2262 don't use Motif or Xaw3d scroll bars
2263 --without-xaw3d don't use Xaw3d
2264 --without-xim don't use X11 XIM
2265 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2266 --with-w32 use native MS Windows GUI in a Cygwin build
2267 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2268 console
2269 --without-dbus don't compile with D-Bus support
2270 --without-gconf don't compile with GConf support
2271 --without-gsettings don't compile with GSettings support
2272 --without-selinux don't compile with SELinux support
2273 --without-gnutls don't use -lgnutls for SSL/TLS support
2274 --without-zlib don't compile with zlib decompression support
2275 --with-file-notification=LIB
2276 use a file notification library (LIB one of: yes,
2277 gfile, inotify, w32, no)
2278 --without-makeinfo don't require makeinfo for building manuals
2279 --without-compress-info don't compress the installed Info pages
2280 --with-pkg-config-prog=FILENAME
2281 file name of pkg-config for finding GTK and librsvg
2282 --with-gameuser=USER user for shared game score files
2283 --with-gnustep-conf=FILENAME
2284 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2285 or /etc/GNUstep/GNUstep.conf
2286 --with-x use the X Window System
2288 Some influential environment variables:
2289 CC C compiler command
2290 CFLAGS C compiler flags
2291 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2292 nonstandard directory <lib dir>
2293 LIBS libraries to pass to the linker, e.g. -l<library>
2294 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2295 you have headers in a nonstandard directory <include dir>
2296 CPP C preprocessor
2297 XMKMF Path to xmkmf, Makefile generator for X Window System
2299 Use these variables to override the choices made by `configure' or to help
2300 it to find libraries and programs with nonstandard names/locations.
2302 Report bugs to the package provider.
2303 _ACEOF
2304 ac_status=$?
2307 if test "$ac_init_help" = "recursive"; then
2308 # If there are subdirs, report their specific --help.
2309 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2310 test -d "$ac_dir" ||
2311 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2312 continue
2313 ac_builddir=.
2315 case "$ac_dir" in
2316 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2318 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2319 # A ".." for each directory in $ac_dir_suffix.
2320 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2321 case $ac_top_builddir_sub in
2322 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2323 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2324 esac ;;
2325 esac
2326 ac_abs_top_builddir=$ac_pwd
2327 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2328 # for backward compatibility:
2329 ac_top_builddir=$ac_top_build_prefix
2331 case $srcdir in
2332 .) # We are building in place.
2333 ac_srcdir=.
2334 ac_top_srcdir=$ac_top_builddir_sub
2335 ac_abs_top_srcdir=$ac_pwd ;;
2336 [\\/]* | ?:[\\/]* ) # Absolute name.
2337 ac_srcdir=$srcdir$ac_dir_suffix;
2338 ac_top_srcdir=$srcdir
2339 ac_abs_top_srcdir=$srcdir ;;
2340 *) # Relative name.
2341 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2342 ac_top_srcdir=$ac_top_build_prefix$srcdir
2343 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2344 esac
2345 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2347 cd "$ac_dir" || { ac_status=$?; continue; }
2348 # Check for guested configure.
2349 if test -f "$ac_srcdir/configure.gnu"; then
2350 echo &&
2351 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2352 elif test -f "$ac_srcdir/configure"; then
2353 echo &&
2354 $SHELL "$ac_srcdir/configure" --help=recursive
2355 else
2356 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2357 fi || ac_status=$?
2358 cd "$ac_pwd" || { ac_status=$?; break; }
2359 done
2362 test -n "$ac_init_help" && exit $ac_status
2363 if $ac_init_version; then
2364 cat <<\_ACEOF
2365 emacs configure 24.3.50
2366 generated by GNU Autoconf 2.65
2368 Copyright (C) 2009 Free Software Foundation, Inc.
2369 This configure script is free software; the Free Software Foundation
2370 gives unlimited permission to copy, distribute and modify it.
2371 _ACEOF
2372 exit
2375 ## ------------------------ ##
2376 ## Autoconf initialization. ##
2377 ## ------------------------ ##
2379 # ac_fn_c_try_compile LINENO
2380 # --------------------------
2381 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2382 ac_fn_c_try_compile ()
2384 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2385 rm -f conftest.$ac_objext
2386 if { { ac_try="$ac_compile"
2387 case "(($ac_try" in
2388 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2389 *) ac_try_echo=$ac_try;;
2390 esac
2391 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2392 $as_echo "$ac_try_echo"; } >&5
2393 (eval "$ac_compile") 2>conftest.err
2394 ac_status=$?
2395 if test -s conftest.err; then
2396 grep -v '^ *+' conftest.err >conftest.er1
2397 cat conftest.er1 >&5
2398 mv -f conftest.er1 conftest.err
2400 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2401 test $ac_status = 0; } && {
2402 test -z "$ac_c_werror_flag" ||
2403 test ! -s conftest.err
2404 } && test -s conftest.$ac_objext; then :
2405 ac_retval=0
2406 else
2407 $as_echo "$as_me: failed program was:" >&5
2408 sed 's/^/| /' conftest.$ac_ext >&5
2410 ac_retval=1
2412 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2413 as_fn_set_status $ac_retval
2415 } # ac_fn_c_try_compile
2417 # ac_fn_c_try_cpp LINENO
2418 # ----------------------
2419 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2420 ac_fn_c_try_cpp ()
2422 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2423 if { { ac_try="$ac_cpp conftest.$ac_ext"
2424 case "(($ac_try" in
2425 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2426 *) ac_try_echo=$ac_try;;
2427 esac
2428 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2429 $as_echo "$ac_try_echo"; } >&5
2430 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2431 ac_status=$?
2432 if test -s conftest.err; then
2433 grep -v '^ *+' conftest.err >conftest.er1
2434 cat conftest.er1 >&5
2435 mv -f conftest.er1 conftest.err
2437 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2438 test $ac_status = 0; } >/dev/null && {
2439 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2440 test ! -s conftest.err
2441 }; then :
2442 ac_retval=0
2443 else
2444 $as_echo "$as_me: failed program was:" >&5
2445 sed 's/^/| /' conftest.$ac_ext >&5
2447 ac_retval=1
2449 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2450 as_fn_set_status $ac_retval
2452 } # ac_fn_c_try_cpp
2454 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2455 # -------------------------------------------------------
2456 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2457 # the include files in INCLUDES and setting the cache variable VAR
2458 # accordingly.
2459 ac_fn_c_check_header_mongrel ()
2461 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2462 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2464 $as_echo_n "checking for $2... " >&6; }
2465 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2466 $as_echo_n "(cached) " >&6
2468 eval ac_res=\$$3
2469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2470 $as_echo "$ac_res" >&6; }
2471 else
2472 # Is the header compilable?
2473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2474 $as_echo_n "checking $2 usability... " >&6; }
2475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2476 /* end confdefs.h. */
2478 #include <$2>
2479 _ACEOF
2480 if ac_fn_c_try_compile "$LINENO"; then :
2481 ac_header_compiler=yes
2482 else
2483 ac_header_compiler=no
2485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2487 $as_echo "$ac_header_compiler" >&6; }
2489 # Is the header present?
2490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2491 $as_echo_n "checking $2 presence... " >&6; }
2492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2493 /* end confdefs.h. */
2494 #include <$2>
2495 _ACEOF
2496 if ac_fn_c_try_cpp "$LINENO"; then :
2497 ac_header_preproc=yes
2498 else
2499 ac_header_preproc=no
2501 rm -f conftest.err conftest.$ac_ext
2502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2503 $as_echo "$ac_header_preproc" >&6; }
2505 # So? What about this header?
2506 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2507 yes:no: )
2508 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2509 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2510 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2511 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2513 no:yes:* )
2514 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2515 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2517 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2518 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2519 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2520 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2521 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2523 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2525 esac
2526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2527 $as_echo_n "checking for $2... " >&6; }
2528 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2529 $as_echo_n "(cached) " >&6
2530 else
2531 eval "$3=\$ac_header_compiler"
2533 eval ac_res=\$$3
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2535 $as_echo "$ac_res" >&6; }
2537 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2539 } # ac_fn_c_check_header_mongrel
2541 # ac_fn_c_try_run LINENO
2542 # ----------------------
2543 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2544 # that executables *can* be run.
2545 ac_fn_c_try_run ()
2547 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2548 if { { ac_try="$ac_link"
2549 case "(($ac_try" in
2550 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2551 *) ac_try_echo=$ac_try;;
2552 esac
2553 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2554 $as_echo "$ac_try_echo"; } >&5
2555 (eval "$ac_link") 2>&5
2556 ac_status=$?
2557 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2558 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2559 { { case "(($ac_try" in
2560 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2561 *) ac_try_echo=$ac_try;;
2562 esac
2563 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2564 $as_echo "$ac_try_echo"; } >&5
2565 (eval "$ac_try") 2>&5
2566 ac_status=$?
2567 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2568 test $ac_status = 0; }; }; then :
2569 ac_retval=0
2570 else
2571 $as_echo "$as_me: program exited with status $ac_status" >&5
2572 $as_echo "$as_me: failed program was:" >&5
2573 sed 's/^/| /' conftest.$ac_ext >&5
2575 ac_retval=$ac_status
2577 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2578 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2579 as_fn_set_status $ac_retval
2581 } # ac_fn_c_try_run
2583 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2584 # -------------------------------------------------------
2585 # Tests whether HEADER exists and can be compiled using the include files in
2586 # INCLUDES, setting the cache variable VAR accordingly.
2587 ac_fn_c_check_header_compile ()
2589 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2591 $as_echo_n "checking for $2... " >&6; }
2592 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2593 $as_echo_n "(cached) " >&6
2594 else
2595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2596 /* end confdefs.h. */
2598 #include <$2>
2599 _ACEOF
2600 if ac_fn_c_try_compile "$LINENO"; then :
2601 eval "$3=yes"
2602 else
2603 eval "$3=no"
2605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2607 eval ac_res=\$$3
2608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2609 $as_echo "$ac_res" >&6; }
2610 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2612 } # ac_fn_c_check_header_compile
2614 # ac_fn_c_try_link LINENO
2615 # -----------------------
2616 # Try to link conftest.$ac_ext, and return whether this succeeded.
2617 ac_fn_c_try_link ()
2619 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2620 rm -f conftest.$ac_objext conftest$ac_exeext
2621 if { { ac_try="$ac_link"
2622 case "(($ac_try" in
2623 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2624 *) ac_try_echo=$ac_try;;
2625 esac
2626 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2627 $as_echo "$ac_try_echo"; } >&5
2628 (eval "$ac_link") 2>conftest.err
2629 ac_status=$?
2630 if test -s conftest.err; then
2631 grep -v '^ *+' conftest.err >conftest.er1
2632 cat conftest.er1 >&5
2633 mv -f conftest.er1 conftest.err
2635 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2636 test $ac_status = 0; } && {
2637 test -z "$ac_c_werror_flag" ||
2638 test ! -s conftest.err
2639 } && test -s conftest$ac_exeext && {
2640 test "$cross_compiling" = yes ||
2641 $as_test_x conftest$ac_exeext
2642 }; then :
2643 ac_retval=0
2644 else
2645 $as_echo "$as_me: failed program was:" >&5
2646 sed 's/^/| /' conftest.$ac_ext >&5
2648 ac_retval=1
2650 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2651 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2652 # interfere with the next link command; also delete a directory that is
2653 # left behind by Apple's compiler. We do this before executing the actions.
2654 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2655 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2656 as_fn_set_status $ac_retval
2658 } # ac_fn_c_try_link
2660 # ac_fn_c_check_decl LINENO SYMBOL VAR
2661 # ------------------------------------
2662 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2663 ac_fn_c_check_decl ()
2665 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2667 $as_echo_n "checking whether $2 is declared... " >&6; }
2668 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2669 $as_echo_n "(cached) " >&6
2670 else
2671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2672 /* end confdefs.h. */
2675 main ()
2677 #ifndef $2
2678 (void) $2;
2679 #endif
2682 return 0;
2684 _ACEOF
2685 if ac_fn_c_try_compile "$LINENO"; then :
2686 eval "$3=yes"
2687 else
2688 eval "$3=no"
2690 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2692 eval ac_res=\$$3
2693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2694 $as_echo "$ac_res" >&6; }
2695 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2697 } # ac_fn_c_check_decl
2699 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2700 # ----------------------------------------------
2701 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2702 ac_fn_c_check_header_preproc ()
2704 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2706 $as_echo_n "checking for $2... " >&6; }
2707 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2708 $as_echo_n "(cached) " >&6
2709 else
2710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2711 /* end confdefs.h. */
2712 #include <$2>
2713 _ACEOF
2714 if ac_fn_c_try_cpp "$LINENO"; then :
2715 eval "$3=yes"
2716 else
2717 eval "$3=no"
2719 rm -f conftest.err conftest.$ac_ext
2721 eval ac_res=\$$3
2722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2723 $as_echo "$ac_res" >&6; }
2724 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2726 } # ac_fn_c_check_header_preproc
2728 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2729 # ----------------------------------------------------
2730 # Tries to find if the field MEMBER exists in type AGGR, after including
2731 # INCLUDES, setting cache variable VAR accordingly.
2732 ac_fn_c_check_member ()
2734 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2736 $as_echo_n "checking for $2.$3... " >&6; }
2737 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2738 $as_echo_n "(cached) " >&6
2739 else
2740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2741 /* end confdefs.h. */
2744 main ()
2746 static $2 ac_aggr;
2747 if (ac_aggr.$3)
2748 return 0;
2750 return 0;
2752 _ACEOF
2753 if ac_fn_c_try_compile "$LINENO"; then :
2754 eval "$4=yes"
2755 else
2756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2757 /* end confdefs.h. */
2760 main ()
2762 static $2 ac_aggr;
2763 if (sizeof ac_aggr.$3)
2764 return 0;
2766 return 0;
2768 _ACEOF
2769 if ac_fn_c_try_compile "$LINENO"; then :
2770 eval "$4=yes"
2771 else
2772 eval "$4=no"
2774 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2778 eval ac_res=\$$4
2779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2780 $as_echo "$ac_res" >&6; }
2781 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2783 } # ac_fn_c_check_member
2785 # ac_fn_c_check_func LINENO FUNC VAR
2786 # ----------------------------------
2787 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2788 ac_fn_c_check_func ()
2790 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2792 $as_echo_n "checking for $2... " >&6; }
2793 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2794 $as_echo_n "(cached) " >&6
2795 else
2796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2797 /* end confdefs.h. */
2798 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2799 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2800 #define $2 innocuous_$2
2802 /* System header to define __stub macros and hopefully few prototypes,
2803 which can conflict with char $2 (); below.
2804 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2805 <limits.h> exists even on freestanding compilers. */
2807 #ifdef __STDC__
2808 # include <limits.h>
2809 #else
2810 # include <assert.h>
2811 #endif
2813 #undef $2
2815 /* Override any GCC internal prototype to avoid an error.
2816 Use char because int might match the return type of a GCC
2817 builtin and then its argument prototype would still apply. */
2818 #ifdef __cplusplus
2819 extern "C"
2820 #endif
2821 char $2 ();
2822 /* The GNU C library defines this for functions which it implements
2823 to always fail with ENOSYS. Some functions are actually named
2824 something starting with __ and the normal name is an alias. */
2825 #if defined __stub_$2 || defined __stub___$2
2826 choke me
2827 #endif
2830 main ()
2832 return $2 ();
2834 return 0;
2836 _ACEOF
2837 if ac_fn_c_try_link "$LINENO"; then :
2838 eval "$3=yes"
2839 else
2840 eval "$3=no"
2842 rm -f core conftest.err conftest.$ac_objext \
2843 conftest$ac_exeext conftest.$ac_ext
2845 eval ac_res=\$$3
2846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2847 $as_echo "$ac_res" >&6; }
2848 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2850 } # ac_fn_c_check_func
2852 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2853 # -------------------------------------------
2854 # Tests whether TYPE exists after having included INCLUDES, setting cache
2855 # variable VAR accordingly.
2856 ac_fn_c_check_type ()
2858 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2860 $as_echo_n "checking for $2... " >&6; }
2861 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2862 $as_echo_n "(cached) " >&6
2863 else
2864 eval "$3=no"
2865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2866 /* end confdefs.h. */
2869 main ()
2871 if (sizeof ($2))
2872 return 0;
2874 return 0;
2876 _ACEOF
2877 if ac_fn_c_try_compile "$LINENO"; then :
2878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2879 /* end confdefs.h. */
2882 main ()
2884 if (sizeof (($2)))
2885 return 0;
2887 return 0;
2889 _ACEOF
2890 if ac_fn_c_try_compile "$LINENO"; then :
2892 else
2893 eval "$3=yes"
2895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2899 eval ac_res=\$$3
2900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2901 $as_echo "$ac_res" >&6; }
2902 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2904 } # ac_fn_c_check_type
2906 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2907 # --------------------------------------------
2908 # Tries to find the compile-time value of EXPR in a program that includes
2909 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2910 # computed
2911 ac_fn_c_compute_int ()
2913 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2914 if test "$cross_compiling" = yes; then
2915 # Depending upon the size, compute the lo and hi bounds.
2916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2917 /* end confdefs.h. */
2920 main ()
2922 static int test_array [1 - 2 * !(($2) >= 0)];
2923 test_array [0] = 0
2926 return 0;
2928 _ACEOF
2929 if ac_fn_c_try_compile "$LINENO"; then :
2930 ac_lo=0 ac_mid=0
2931 while :; do
2932 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2933 /* end confdefs.h. */
2936 main ()
2938 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2939 test_array [0] = 0
2942 return 0;
2944 _ACEOF
2945 if ac_fn_c_try_compile "$LINENO"; then :
2946 ac_hi=$ac_mid; break
2947 else
2948 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2949 if test $ac_lo -le $ac_mid; then
2950 ac_lo= ac_hi=
2951 break
2953 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2955 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2956 done
2957 else
2958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2959 /* end confdefs.h. */
2962 main ()
2964 static int test_array [1 - 2 * !(($2) < 0)];
2965 test_array [0] = 0
2968 return 0;
2970 _ACEOF
2971 if ac_fn_c_try_compile "$LINENO"; then :
2972 ac_hi=-1 ac_mid=-1
2973 while :; do
2974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2975 /* end confdefs.h. */
2978 main ()
2980 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2981 test_array [0] = 0
2984 return 0;
2986 _ACEOF
2987 if ac_fn_c_try_compile "$LINENO"; then :
2988 ac_lo=$ac_mid; break
2989 else
2990 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2991 if test $ac_mid -le $ac_hi; then
2992 ac_lo= ac_hi=
2993 break
2995 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2998 done
2999 else
3000 ac_lo= ac_hi=
3002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3005 # Binary search between lo and hi bounds.
3006 while test "x$ac_lo" != "x$ac_hi"; do
3007 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
3008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3009 /* end confdefs.h. */
3012 main ()
3014 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3015 test_array [0] = 0
3018 return 0;
3020 _ACEOF
3021 if ac_fn_c_try_compile "$LINENO"; then :
3022 ac_hi=$ac_mid
3023 else
3024 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3027 done
3028 case $ac_lo in #((
3029 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3030 '') ac_retval=1 ;;
3031 esac
3032 else
3033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3034 /* end confdefs.h. */
3036 static long int longval () { return $2; }
3037 static unsigned long int ulongval () { return $2; }
3038 #include <stdio.h>
3039 #include <stdlib.h>
3041 main ()
3044 FILE *f = fopen ("conftest.val", "w");
3045 if (! f)
3046 return 1;
3047 if (($2) < 0)
3049 long int i = longval ();
3050 if (i != ($2))
3051 return 1;
3052 fprintf (f, "%ld", i);
3054 else
3056 unsigned long int i = ulongval ();
3057 if (i != ($2))
3058 return 1;
3059 fprintf (f, "%lu", i);
3061 /* Do not output a trailing newline, as this causes \r\n confusion
3062 on some platforms. */
3063 return ferror (f) || fclose (f) != 0;
3066 return 0;
3068 _ACEOF
3069 if ac_fn_c_try_run "$LINENO"; then :
3070 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3071 else
3072 ac_retval=1
3074 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3075 conftest.$ac_objext conftest.beam conftest.$ac_ext
3076 rm -f conftest.val
3079 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3080 as_fn_set_status $ac_retval
3082 } # ac_fn_c_compute_int
3083 cat >config.log <<_ACEOF
3084 This file contains any messages produced by compilers while
3085 running configure, to aid debugging if configure makes a mistake.
3087 It was created by emacs $as_me 24.3.50, which was
3088 generated by GNU Autoconf 2.65. Invocation command line was
3090 $ $0 $@
3092 _ACEOF
3093 exec 5>>config.log
3095 cat <<_ASUNAME
3096 ## --------- ##
3097 ## Platform. ##
3098 ## --------- ##
3100 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3101 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3102 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3103 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3104 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3106 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3107 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3109 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3110 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3111 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3112 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3113 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3114 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3115 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3117 _ASUNAME
3119 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3120 for as_dir in $PATH
3122 IFS=$as_save_IFS
3123 test -z "$as_dir" && as_dir=.
3124 $as_echo "PATH: $as_dir"
3125 done
3126 IFS=$as_save_IFS
3128 } >&5
3130 cat >&5 <<_ACEOF
3133 ## ----------- ##
3134 ## Core tests. ##
3135 ## ----------- ##
3137 _ACEOF
3140 # Keep a trace of the command line.
3141 # Strip out --no-create and --no-recursion so they do not pile up.
3142 # Strip out --silent because we don't want to record it for future runs.
3143 # Also quote any args containing shell meta-characters.
3144 # Make two passes to allow for proper duplicate-argument suppression.
3145 ac_configure_args=
3146 ac_configure_args0=
3147 ac_configure_args1=
3148 ac_must_keep_next=false
3149 for ac_pass in 1 2
3151 for ac_arg
3153 case $ac_arg in
3154 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3155 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3156 | -silent | --silent | --silen | --sile | --sil)
3157 continue ;;
3158 *\'*)
3159 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3160 esac
3161 case $ac_pass in
3162 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3164 as_fn_append ac_configure_args1 " '$ac_arg'"
3165 if test $ac_must_keep_next = true; then
3166 ac_must_keep_next=false # Got value, back to normal.
3167 else
3168 case $ac_arg in
3169 *=* | --config-cache | -C | -disable-* | --disable-* \
3170 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3171 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3172 | -with-* | --with-* | -without-* | --without-* | --x)
3173 case "$ac_configure_args0 " in
3174 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3175 esac
3177 -* ) ac_must_keep_next=true ;;
3178 esac
3180 as_fn_append ac_configure_args " '$ac_arg'"
3182 esac
3183 done
3184 done
3185 { ac_configure_args0=; unset ac_configure_args0;}
3186 { ac_configure_args1=; unset ac_configure_args1;}
3188 # When interrupted or exit'd, cleanup temporary files, and complete
3189 # config.log. We remove comments because anyway the quotes in there
3190 # would cause problems or look ugly.
3191 # WARNING: Use '\'' to represent an apostrophe within the trap.
3192 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3193 trap 'exit_status=$?
3194 # Save into config.log some information that might help in debugging.
3196 echo
3198 cat <<\_ASBOX
3199 ## ---------------- ##
3200 ## Cache variables. ##
3201 ## ---------------- ##
3202 _ASBOX
3203 echo
3204 # The following way of writing the cache mishandles newlines in values,
3206 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3207 eval ac_val=\$$ac_var
3208 case $ac_val in #(
3209 *${as_nl}*)
3210 case $ac_var in #(
3211 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3212 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3213 esac
3214 case $ac_var in #(
3215 _ | IFS | as_nl) ;; #(
3216 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3217 *) { eval $ac_var=; unset $ac_var;} ;;
3218 esac ;;
3219 esac
3220 done
3221 (set) 2>&1 |
3222 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3223 *${as_nl}ac_space=\ *)
3224 sed -n \
3225 "s/'\''/'\''\\\\'\'''\''/g;
3226 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3227 ;; #(
3229 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3231 esac |
3232 sort
3234 echo
3236 cat <<\_ASBOX
3237 ## ----------------- ##
3238 ## Output variables. ##
3239 ## ----------------- ##
3240 _ASBOX
3241 echo
3242 for ac_var in $ac_subst_vars
3244 eval ac_val=\$$ac_var
3245 case $ac_val in
3246 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3247 esac
3248 $as_echo "$ac_var='\''$ac_val'\''"
3249 done | sort
3250 echo
3252 if test -n "$ac_subst_files"; then
3253 cat <<\_ASBOX
3254 ## ------------------- ##
3255 ## File substitutions. ##
3256 ## ------------------- ##
3257 _ASBOX
3258 echo
3259 for ac_var in $ac_subst_files
3261 eval ac_val=\$$ac_var
3262 case $ac_val in
3263 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3264 esac
3265 $as_echo "$ac_var='\''$ac_val'\''"
3266 done | sort
3267 echo
3270 if test -s confdefs.h; then
3271 cat <<\_ASBOX
3272 ## ----------- ##
3273 ## confdefs.h. ##
3274 ## ----------- ##
3275 _ASBOX
3276 echo
3277 cat confdefs.h
3278 echo
3280 test "$ac_signal" != 0 &&
3281 $as_echo "$as_me: caught signal $ac_signal"
3282 $as_echo "$as_me: exit $exit_status"
3283 } >&5
3284 rm -f core *.core core.conftest.* &&
3285 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3286 exit $exit_status
3288 for ac_signal in 1 2 13 15; do
3289 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3290 done
3291 ac_signal=0
3293 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3294 rm -f -r conftest* confdefs.h
3296 $as_echo "/* confdefs.h */" > confdefs.h
3298 # Predefined preprocessor variables.
3300 cat >>confdefs.h <<_ACEOF
3301 #define PACKAGE_NAME "$PACKAGE_NAME"
3302 _ACEOF
3304 cat >>confdefs.h <<_ACEOF
3305 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3306 _ACEOF
3308 cat >>confdefs.h <<_ACEOF
3309 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3310 _ACEOF
3312 cat >>confdefs.h <<_ACEOF
3313 #define PACKAGE_STRING "$PACKAGE_STRING"
3314 _ACEOF
3316 cat >>confdefs.h <<_ACEOF
3317 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3318 _ACEOF
3320 cat >>confdefs.h <<_ACEOF
3321 #define PACKAGE_URL "$PACKAGE_URL"
3322 _ACEOF
3325 # Let the site file select an alternate cache file if it wants to.
3326 # Prefer an explicitly selected file to automatically selected ones.
3327 ac_site_file1=NONE
3328 ac_site_file2=NONE
3329 if test -n "$CONFIG_SITE"; then
3330 ac_site_file1=$CONFIG_SITE
3331 elif test "x$prefix" != xNONE; then
3332 ac_site_file1=$prefix/share/config.site
3333 ac_site_file2=$prefix/etc/config.site
3334 else
3335 ac_site_file1=$ac_default_prefix/share/config.site
3336 ac_site_file2=$ac_default_prefix/etc/config.site
3338 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3340 test "x$ac_site_file" = xNONE && continue
3341 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3342 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3343 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3344 sed 's/^/| /' "$ac_site_file" >&5
3345 . "$ac_site_file"
3347 done
3349 if test -r "$cache_file"; then
3350 # Some versions of bash will fail to source /dev/null (special files
3351 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3352 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3353 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3354 $as_echo "$as_me: loading cache $cache_file" >&6;}
3355 case $cache_file in
3356 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3357 *) . "./$cache_file";;
3358 esac
3360 else
3361 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3362 $as_echo "$as_me: creating cache $cache_file" >&6;}
3363 >$cache_file
3366 as_fn_append ac_header_list " sys/systeminfo.h"
3367 as_fn_append ac_header_list " coff.h"
3368 as_fn_append ac_header_list " pty.h"
3369 as_fn_append ac_header_list " sys/resource.h"
3370 as_fn_append ac_header_list " sys/utsname.h"
3371 as_fn_append ac_header_list " pwd.h"
3372 as_fn_append ac_header_list " utmp.h"
3373 as_fn_append ac_header_list " util.h"
3374 as_fn_append ac_header_list " sys/socket.h"
3375 as_fn_append ac_header_list " stdlib.h"
3376 as_fn_append ac_header_list " unistd.h"
3377 as_fn_append ac_header_list " sys/param.h"
3378 as_fn_append ac_header_list " pthread.h"
3379 as_fn_append ac_header_list " malloc/malloc.h"
3380 as_fn_append ac_header_list " maillock.h"
3381 as_fn_append ac_header_list " sys/un.h"
3382 as_fn_append ac_func_list " tzset"
3383 as_fn_append ac_func_list " readlinkat"
3384 as_fn_append ac_header_list " dirent.h"
3385 as_fn_append ac_header_list " execinfo.h"
3386 as_fn_append ac_func_list " faccessat"
3387 as_fn_append ac_func_list " fcntl"
3388 as_fn_append ac_func_list " fdopendir"
3389 as_fn_append ac_header_list " stdio_ext.h"
3390 as_fn_append ac_func_list " fstatat"
3391 as_fn_append ac_func_list " fsync"
3392 gl_getopt_required=GNU
3393 as_fn_append ac_header_list " getopt.h"
3394 as_fn_append ac_func_list " gettimeofday"
3395 as_fn_append ac_func_list " nanotime"
3396 as_fn_append ac_header_list " sys/time.h"
3397 as_fn_append ac_header_list " wchar.h"
3398 as_fn_append ac_header_list " stdint.h"
3399 as_fn_append ac_header_list " inttypes.h"
3400 as_fn_append ac_func_list " lstat"
3401 as_fn_append ac_func_list " mkostemp"
3402 as_fn_append ac_func_list " pipe2"
3403 as_fn_append ac_header_list " sys/select.h"
3404 as_fn_append ac_func_list " pselect"
3405 as_fn_append ac_func_list " pthread_sigmask"
3406 as_fn_append ac_func_list " readlink"
3407 as_fn_append ac_func_list " strtoimax"
3408 as_fn_append ac_func_list " strtoumax"
3409 as_fn_append ac_func_list " symlink"
3410 as_fn_append ac_header_list " sys/stat.h"
3411 as_fn_append ac_func_list " localtime_r"
3412 as_fn_append ac_header_list " utime.h"
3413 as_fn_append ac_func_list " futimes"
3414 as_fn_append ac_func_list " futimesat"
3415 as_fn_append ac_func_list " futimens"
3416 as_fn_append ac_func_list " utimensat"
3417 as_fn_append ac_func_list " lutimes"
3418 as_fn_append ac_func_list " getdtablesize"
3419 as_fn_append ac_func_list " secure_getenv"
3420 # Check that the precious variables saved in the cache have kept the same
3421 # value.
3422 ac_cache_corrupted=false
3423 for ac_var in $ac_precious_vars; do
3424 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3425 eval ac_new_set=\$ac_env_${ac_var}_set
3426 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3427 eval ac_new_val=\$ac_env_${ac_var}_value
3428 case $ac_old_set,$ac_new_set in
3429 set,)
3430 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3431 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3432 ac_cache_corrupted=: ;;
3433 ,set)
3434 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3435 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3436 ac_cache_corrupted=: ;;
3437 ,);;
3439 if test "x$ac_old_val" != "x$ac_new_val"; then
3440 # differences in whitespace do not lead to failure.
3441 ac_old_val_w=`echo x $ac_old_val`
3442 ac_new_val_w=`echo x $ac_new_val`
3443 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3444 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3445 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3446 ac_cache_corrupted=:
3447 else
3448 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3449 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3450 eval $ac_var=\$ac_old_val
3452 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3453 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3454 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3455 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3456 fi;;
3457 esac
3458 # Pass precious variables to config.status.
3459 if test "$ac_new_set" = set; then
3460 case $ac_new_val in
3461 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3462 *) ac_arg=$ac_var=$ac_new_val ;;
3463 esac
3464 case " $ac_configure_args " in
3465 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3466 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3467 esac
3469 done
3470 if $ac_cache_corrupted; then
3471 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3472 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3473 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3474 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3475 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3477 ## -------------------- ##
3478 ## Main body of script. ##
3479 ## -------------------- ##
3481 ac_ext=c
3482 ac_cpp='$CPP $CPPFLAGS'
3483 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3484 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3485 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3489 emacs_config_options=
3490 optsep=
3491 for opt in ${1+"$@"} CFLAGS CPPFLAGS LDFLAGS; do
3492 case $opt in
3493 -n | --no-create | --no-recursion)
3494 continue ;;
3495 CFLAGS | CPPFLAGS | LDFLAGS)
3496 eval 'test "${'$opt'+set}" = set' || continue
3497 case " $*" in
3498 *" $opt="*) continue ;;
3499 esac
3500 eval opt=$opt=\$$opt ;;
3501 esac
3503 emacs_shell_specials=$IFS\''"#$&()*;<>?[\\`{|~'
3504 case $opt in
3505 *["$emacs_shell_specials"]*)
3506 case $opt in
3507 *\'*)
3508 emacs_quote_apostrophes="s/'/'\\\\''/g"
3509 opt=`$as_echo "$opt" | sed "$emacs_quote_apostrophes"` ;;
3510 esac
3511 opt="'$opt'"
3512 case $opt in
3513 *['"\\']*)
3514 emacs_quote_for_c='s/["\\]/\\&/g; $!s/$/\\n\\/'
3515 opt=`$as_echo "$opt" | sed "$emacs_quote_for_c"` ;;
3516 esac ;;
3517 esac
3518 as_fn_append emacs_config_options "$optsep$opt"
3519 optsep=' '
3520 done
3522 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3525 ac_aux_dir=
3526 for ac_dir in build-aux "$srcdir"/build-aux; do
3527 for ac_t in install-sh install.sh shtool; do
3528 if test -f "$ac_dir/$ac_t"; then
3529 ac_aux_dir=$ac_dir
3530 ac_install_sh="$ac_aux_dir/$ac_t -c"
3531 break 2
3533 done
3534 done
3535 if test -z "$ac_aux_dir"; then
3536 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3539 # These three variables are undocumented and unsupported,
3540 # and are intended to be withdrawn in a future Autoconf release.
3541 # They can cause serious problems if a builder's source tree is in a directory
3542 # whose full name contains unusual characters.
3543 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3544 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3545 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3548 am__api_version='1.11'
3550 # Find a good install program. We prefer a C program (faster),
3551 # so one script is as good as another. But avoid the broken or
3552 # incompatible versions:
3553 # SysV /etc/install, /usr/sbin/install
3554 # SunOS /usr/etc/install
3555 # IRIX /sbin/install
3556 # AIX /bin/install
3557 # AmigaOS /C/install, which installs bootblocks on floppy discs
3558 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3559 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3560 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3561 # OS/2's system install, which has a completely different semantic
3562 # ./install, which can be erroneously created by make from ./install.sh.
3563 # Reject install programs that cannot install multiple files.
3564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3565 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3566 if test -z "$INSTALL"; then
3567 if test "${ac_cv_path_install+set}" = set; then :
3568 $as_echo_n "(cached) " >&6
3569 else
3570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3571 for as_dir in $PATH
3573 IFS=$as_save_IFS
3574 test -z "$as_dir" && as_dir=.
3575 # Account for people who put trailing slashes in PATH elements.
3576 case $as_dir/ in #((
3577 ./ | .// | /[cC]/* | \
3578 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3579 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3580 /usr/ucb/* ) ;;
3582 # OSF1 and SCO ODT 3.0 have their own names for install.
3583 # Don't use installbsd from OSF since it installs stuff as root
3584 # by default.
3585 for ac_prog in ginstall scoinst install; do
3586 for ac_exec_ext in '' $ac_executable_extensions; do
3587 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3588 if test $ac_prog = install &&
3589 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3590 # AIX install. It has an incompatible calling convention.
3592 elif test $ac_prog = install &&
3593 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3594 # program-specific install script used by HP pwplus--don't use.
3596 else
3597 rm -rf conftest.one conftest.two conftest.dir
3598 echo one > conftest.one
3599 echo two > conftest.two
3600 mkdir conftest.dir
3601 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3602 test -s conftest.one && test -s conftest.two &&
3603 test -s conftest.dir/conftest.one &&
3604 test -s conftest.dir/conftest.two
3605 then
3606 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3607 break 3
3611 done
3612 done
3614 esac
3616 done
3617 IFS=$as_save_IFS
3619 rm -rf conftest.one conftest.two conftest.dir
3622 if test "${ac_cv_path_install+set}" = set; then
3623 INSTALL=$ac_cv_path_install
3624 else
3625 # As a last resort, use the slow shell script. Don't cache a
3626 # value for INSTALL within a source directory, because that will
3627 # break other packages using the cache if that directory is
3628 # removed, or if the value is a relative name.
3629 INSTALL=$ac_install_sh
3632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3633 $as_echo "$INSTALL" >&6; }
3635 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3636 # It thinks the first close brace ends the variable substitution.
3637 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3639 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3641 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3644 $as_echo_n "checking whether build environment is sane... " >&6; }
3645 # Just in case
3646 sleep 1
3647 echo timestamp > conftest.file
3648 # Reject unsafe characters in $srcdir or the absolute working directory
3649 # name. Accept space and tab only in the latter.
3650 am_lf='
3652 case `pwd` in
3653 *[\\\"\#\$\&\'\`$am_lf]*)
3654 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3655 esac
3656 case $srcdir in
3657 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3658 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3659 esac
3661 # Do `set' in a subshell so we don't clobber the current shell's
3662 # arguments. Must try -L first in case configure is actually a
3663 # symlink; some systems play weird games with the mod time of symlinks
3664 # (eg FreeBSD returns the mod time of the symlink's containing
3665 # directory).
3666 if (
3667 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3668 if test "$*" = "X"; then
3669 # -L didn't work.
3670 set X `ls -t "$srcdir/configure" conftest.file`
3672 rm -f conftest.file
3673 if test "$*" != "X $srcdir/configure conftest.file" \
3674 && test "$*" != "X conftest.file $srcdir/configure"; then
3676 # If neither matched, then we have a broken ls. This can happen
3677 # if, for instance, CONFIG_SHELL is bash and it inherits a
3678 # broken ls alias from the environment. This has actually
3679 # happened. Such a system could not be considered "sane".
3680 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3681 alias in your environment" "$LINENO" 5
3684 test "$2" = conftest.file
3686 then
3687 # Ok.
3689 else
3690 as_fn_error "newly created file is older than distributed files!
3691 Check your system clock" "$LINENO" 5
3693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3694 $as_echo "yes" >&6; }
3695 test "$program_prefix" != NONE &&
3696 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3697 # Use a double $ so make ignores it.
3698 test "$program_suffix" != NONE &&
3699 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3700 # Double any \ or $.
3701 # By default was `s,x,x', remove it if useless.
3702 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3703 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3705 # expand $ac_aux_dir to an absolute path
3706 am_aux_dir=`cd $ac_aux_dir && pwd`
3708 if test x"${MISSING+set}" != xset; then
3709 case $am_aux_dir in
3710 *\ * | *\ *)
3711 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3713 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3714 esac
3716 # Use eval to expand $SHELL
3717 if eval "$MISSING --run true"; then
3718 am_missing_run="$MISSING --run "
3719 else
3720 am_missing_run=
3721 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3722 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3725 if test x"${install_sh}" != xset; then
3726 case $am_aux_dir in
3727 *\ * | *\ *)
3728 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3730 install_sh="\${SHELL} $am_aux_dir/install-sh"
3731 esac
3734 # Installed binaries are usually stripped using `strip' when the user
3735 # run `make install-strip'. However `strip' might not be the right
3736 # tool to use in cross-compilation environments, therefore Automake
3737 # will honor the `STRIP' environment variable to overrule this program.
3738 if test "$cross_compiling" != no; then
3739 if test -n "$ac_tool_prefix"; then
3740 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3741 set dummy ${ac_tool_prefix}strip; ac_word=$2
3742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3743 $as_echo_n "checking for $ac_word... " >&6; }
3744 if test "${ac_cv_prog_STRIP+set}" = set; then :
3745 $as_echo_n "(cached) " >&6
3746 else
3747 if test -n "$STRIP"; then
3748 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3749 else
3750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3751 for as_dir in $PATH
3753 IFS=$as_save_IFS
3754 test -z "$as_dir" && as_dir=.
3755 for ac_exec_ext in '' $ac_executable_extensions; do
3756 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3757 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3758 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3759 break 2
3761 done
3762 done
3763 IFS=$as_save_IFS
3767 STRIP=$ac_cv_prog_STRIP
3768 if test -n "$STRIP"; then
3769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3770 $as_echo "$STRIP" >&6; }
3771 else
3772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3773 $as_echo "no" >&6; }
3778 if test -z "$ac_cv_prog_STRIP"; then
3779 ac_ct_STRIP=$STRIP
3780 # Extract the first word of "strip", so it can be a program name with args.
3781 set dummy strip; ac_word=$2
3782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3783 $as_echo_n "checking for $ac_word... " >&6; }
3784 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3785 $as_echo_n "(cached) " >&6
3786 else
3787 if test -n "$ac_ct_STRIP"; then
3788 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3789 else
3790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3791 for as_dir in $PATH
3793 IFS=$as_save_IFS
3794 test -z "$as_dir" && as_dir=.
3795 for ac_exec_ext in '' $ac_executable_extensions; do
3796 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3797 ac_cv_prog_ac_ct_STRIP="strip"
3798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3799 break 2
3801 done
3802 done
3803 IFS=$as_save_IFS
3807 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3808 if test -n "$ac_ct_STRIP"; then
3809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3810 $as_echo "$ac_ct_STRIP" >&6; }
3811 else
3812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3813 $as_echo "no" >&6; }
3816 if test "x$ac_ct_STRIP" = x; then
3817 STRIP=":"
3818 else
3819 case $cross_compiling:$ac_tool_warned in
3820 yes:)
3821 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3822 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3823 ac_tool_warned=yes ;;
3824 esac
3825 STRIP=$ac_ct_STRIP
3827 else
3828 STRIP="$ac_cv_prog_STRIP"
3832 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3835 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3836 if test -z "$MKDIR_P"; then
3837 if test "${ac_cv_path_mkdir+set}" = set; then :
3838 $as_echo_n "(cached) " >&6
3839 else
3840 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3841 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3843 IFS=$as_save_IFS
3844 test -z "$as_dir" && as_dir=.
3845 for ac_prog in mkdir gmkdir; do
3846 for ac_exec_ext in '' $ac_executable_extensions; do
3847 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3848 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3849 'mkdir (GNU coreutils) '* | \
3850 'mkdir (coreutils) '* | \
3851 'mkdir (fileutils) '4.1*)
3852 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3853 break 3;;
3854 esac
3855 done
3856 done
3857 done
3858 IFS=$as_save_IFS
3862 test -d ./--version && rmdir ./--version
3863 if test "${ac_cv_path_mkdir+set}" = set; then
3864 MKDIR_P="$ac_cv_path_mkdir -p"
3865 else
3866 # As a last resort, use the slow shell script. Don't cache a
3867 # value for MKDIR_P within a source directory, because that will
3868 # break other packages using the cache if that directory is
3869 # removed, or if the value is a relative name.
3870 MKDIR_P="$ac_install_sh -d"
3873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3874 $as_echo "$MKDIR_P" >&6; }
3876 mkdir_p="$MKDIR_P"
3877 case $mkdir_p in
3878 [\\/$]* | ?:[\\/]*) ;;
3879 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3880 esac
3882 for ac_prog in gawk mawk nawk awk
3884 # Extract the first word of "$ac_prog", so it can be a program name with args.
3885 set dummy $ac_prog; ac_word=$2
3886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3887 $as_echo_n "checking for $ac_word... " >&6; }
3888 if test "${ac_cv_prog_AWK+set}" = set; then :
3889 $as_echo_n "(cached) " >&6
3890 else
3891 if test -n "$AWK"; then
3892 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3893 else
3894 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3895 for as_dir in $PATH
3897 IFS=$as_save_IFS
3898 test -z "$as_dir" && as_dir=.
3899 for ac_exec_ext in '' $ac_executable_extensions; do
3900 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3901 ac_cv_prog_AWK="$ac_prog"
3902 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3903 break 2
3905 done
3906 done
3907 IFS=$as_save_IFS
3911 AWK=$ac_cv_prog_AWK
3912 if test -n "$AWK"; then
3913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3914 $as_echo "$AWK" >&6; }
3915 else
3916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3917 $as_echo "no" >&6; }
3921 test -n "$AWK" && break
3922 done
3924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3925 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3926 set x ${MAKE-make}
3927 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3928 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3929 $as_echo_n "(cached) " >&6
3930 else
3931 cat >conftest.make <<\_ACEOF
3932 SHELL = /bin/sh
3933 all:
3934 @echo '@@@%%%=$(MAKE)=@@@%%%'
3935 _ACEOF
3936 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3937 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3938 *@@@%%%=?*=@@@%%%*)
3939 eval ac_cv_prog_make_${ac_make}_set=yes;;
3941 eval ac_cv_prog_make_${ac_make}_set=no;;
3942 esac
3943 rm -f conftest.make
3945 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3947 $as_echo "yes" >&6; }
3948 SET_MAKE=
3949 else
3950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3951 $as_echo "no" >&6; }
3952 SET_MAKE="MAKE=${MAKE-make}"
3955 rm -rf .tst 2>/dev/null
3956 mkdir .tst 2>/dev/null
3957 if test -d .tst; then
3958 am__leading_dot=.
3959 else
3960 am__leading_dot=_
3962 rmdir .tst 2>/dev/null
3964 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3965 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3966 # is not polluted with repeated "-I."
3967 am__isrc=' -I$(srcdir)'
3968 # test to see if srcdir already configured
3969 if test -f $srcdir/config.status; then
3970 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3974 # test whether we have cygpath
3975 if test -z "$CYGPATH_W"; then
3976 if (cygpath --version) >/dev/null 2>/dev/null; then
3977 CYGPATH_W='cygpath -w'
3978 else
3979 CYGPATH_W=echo
3984 # Define the identity of the package.
3985 PACKAGE='emacs'
3986 VERSION='24.3.50'
3989 cat >>confdefs.h <<_ACEOF
3990 #define PACKAGE "$PACKAGE"
3991 _ACEOF
3994 cat >>confdefs.h <<_ACEOF
3995 #define VERSION "$VERSION"
3996 _ACEOF
3998 # Some tools Automake needs.
4000 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4003 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4006 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4009 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4012 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4014 # We need awk for the "check" target. The system "awk" is bad on
4015 # some platforms.
4016 # Always define AMTAR for backward compatibility.
4018 AMTAR=${AMTAR-"${am_missing_run}tar"}
4020 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
4029 lispdir='${datadir}/emacs/${version}/lisp'
4030 leimdir='${datadir}/emacs/${version}/leim'
4031 standardlisppath='${lispdir}:${leimdir}'
4032 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
4033 '${datadir}/emacs/site-lisp'
4034 lisppath='${locallisppath}:${standardlisppath}'
4035 etcdir='${datadir}/emacs/${version}/etc'
4036 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4037 etcdocdir='${datadir}/emacs/${version}/etc'
4038 gamedir='${localstatedir}/games/emacs'
4041 # Check whether --with-all was given.
4042 if test "${with_all+set}" = set; then :
4043 withval=$with_all; with_features=$withval
4044 else
4045 with_features=yes
4052 # Check whether --with-pop was given.
4053 if test "${with_pop+set}" = set; then :
4054 withval=$with_pop;
4055 else
4056 with_pop=$with_features
4059 if test "$with_pop" = yes; then
4060 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4065 # Check whether --with-kerberos was given.
4066 if test "${with_kerberos+set}" = set; then :
4067 withval=$with_kerberos;
4068 else
4069 with_kerberos=no
4072 if test "$with_kerberos" != no; then
4073 $as_echo "#define KERBEROS 1" >>confdefs.h
4078 # Check whether --with-kerberos5 was given.
4079 if test "${with_kerberos5+set}" = set; then :
4080 withval=$with_kerberos5;
4081 else
4082 with_kerberos5=no
4085 if test "${with_kerberos5}" != no; then
4086 if test "${with_kerberos}" = no; then
4087 with_kerberos=yes
4088 $as_echo "#define KERBEROS 1" >>confdefs.h
4092 $as_echo "#define KERBEROS5 1" >>confdefs.h
4097 # Check whether --with-hesiod was given.
4098 if test "${with_hesiod+set}" = set; then :
4099 withval=$with_hesiod;
4100 else
4101 with_hesiod=no
4104 if test "$with_hesiod" != no; then
4106 $as_echo "#define HESIOD 1" >>confdefs.h
4111 # Check whether --with-mmdf was given.
4112 if test "${with_mmdf+set}" = set; then :
4113 withval=$with_mmdf;
4114 else
4115 with_mmdf=no
4118 if test "$with_mmdf" != no; then
4120 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4125 # Check whether --with-mail-unlink was given.
4126 if test "${with_mail_unlink+set}" = set; then :
4127 withval=$with_mail_unlink;
4128 else
4129 with_mail_unlink=no
4132 if test "$with_mail_unlink" != no; then
4134 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4139 # Check whether --with-mailhost was given.
4140 if test "${with_mailhost+set}" = set; then :
4141 withval=$with_mailhost;
4142 cat >>confdefs.h <<_ACEOF
4143 #define MAILHOST "$withval"
4144 _ACEOF
4150 # Check whether --with-sound was given.
4151 if test "${with_sound+set}" = set; then :
4152 withval=$with_sound; case "${withval}" in
4153 yes|no|ossaudio|alsa) val=$withval ;;
4154 *) as_fn_error "\`--with-sound=$withval' is invalid;
4155 this option's value should be \`yes', \`no', \`ossaudio', or \`alsa'." "$LINENO" 5
4157 esac
4158 with_sound=$val
4160 else
4161 with_sound=$with_features
4166 # Check whether --with-x-toolkit was given.
4167 if test "${with_x_toolkit+set}" = set; then :
4168 withval=$with_x_toolkit; case "${withval}" in
4169 y | ye | yes ) val=gtk ;;
4170 n | no ) val=no ;;
4171 l | lu | luc | luci | lucid ) val=lucid ;;
4172 a | at | ath | athe | athen | athena ) val=athena ;;
4173 m | mo | mot | moti | motif ) val=motif ;;
4174 g | gt | gtk ) val=gtk ;;
4175 gtk2 ) val=gtk2 ;;
4176 gtk3 ) val=gtk3 ;;
4178 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4179 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4180 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4181 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4183 esac
4184 with_x_toolkit=$val
4190 # Check whether --with-wide-int was given.
4191 if test "${with_wide_int+set}" = set; then :
4192 withval=$with_wide_int;
4193 else
4194 with_wide_int=no
4197 if test "$with_wide_int" = yes; then
4199 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4204 # Check whether --with-xpm was given.
4205 if test "${with_xpm+set}" = set; then :
4206 withval=$with_xpm;
4207 else
4208 with_xpm=$with_features
4212 # Check whether --with-jpeg was given.
4213 if test "${with_jpeg+set}" = set; then :
4214 withval=$with_jpeg;
4215 else
4216 with_jpeg=$with_features
4220 # Check whether --with-tiff was given.
4221 if test "${with_tiff+set}" = set; then :
4222 withval=$with_tiff;
4223 else
4224 with_tiff=$with_features
4228 # Check whether --with-gif was given.
4229 if test "${with_gif+set}" = set; then :
4230 withval=$with_gif;
4231 else
4232 with_gif=$with_features
4236 # Check whether --with-png was given.
4237 if test "${with_png+set}" = set; then :
4238 withval=$with_png;
4239 else
4240 with_png=$with_features
4244 # Check whether --with-rsvg was given.
4245 if test "${with_rsvg+set}" = set; then :
4246 withval=$with_rsvg;
4247 else
4248 with_rsvg=$with_features
4252 # Check whether --with-xml2 was given.
4253 if test "${with_xml2+set}" = set; then :
4254 withval=$with_xml2;
4255 else
4256 with_xml2=$with_features
4260 # Check whether --with-imagemagick was given.
4261 if test "${with_imagemagick+set}" = set; then :
4262 withval=$with_imagemagick;
4263 else
4264 with_imagemagick=$with_features
4269 # Check whether --with-xft was given.
4270 if test "${with_xft+set}" = set; then :
4271 withval=$with_xft;
4272 else
4273 with_xft=$with_features
4277 # Check whether --with-libotf was given.
4278 if test "${with_libotf+set}" = set; then :
4279 withval=$with_libotf;
4280 else
4281 with_libotf=$with_features
4285 # Check whether --with-m17n-flt was given.
4286 if test "${with_m17n_flt+set}" = set; then :
4287 withval=$with_m17n_flt;
4288 else
4289 with_m17n_flt=$with_features
4294 # Check whether --with-toolkit-scroll-bars was given.
4295 if test "${with_toolkit_scroll_bars+set}" = set; then :
4296 withval=$with_toolkit_scroll_bars;
4297 else
4298 with_toolkit_scroll_bars=$with_features
4302 # Check whether --with-xaw3d was given.
4303 if test "${with_xaw3d+set}" = set; then :
4304 withval=$with_xaw3d;
4305 else
4306 with_xaw3d=$with_features
4310 # Check whether --with-xim was given.
4311 if test "${with_xim+set}" = set; then :
4312 withval=$with_xim;
4313 else
4314 with_xim=$with_features
4318 # Check whether --with-ns was given.
4319 if test "${with_ns+set}" = set; then :
4320 withval=$with_ns;
4321 else
4322 with_ns=no
4326 # Check whether --with-w32 was given.
4327 if test "${with_w32+set}" = set; then :
4328 withval=$with_w32;
4329 else
4330 with_w32=no
4335 # Check whether --with-gpm was given.
4336 if test "${with_gpm+set}" = set; then :
4337 withval=$with_gpm;
4338 else
4339 with_gpm=$with_features
4343 # Check whether --with-dbus was given.
4344 if test "${with_dbus+set}" = set; then :
4345 withval=$with_dbus;
4346 else
4347 with_dbus=$with_features
4351 # Check whether --with-gconf was given.
4352 if test "${with_gconf+set}" = set; then :
4353 withval=$with_gconf;
4354 else
4355 with_gconf=$with_features
4359 # Check whether --with-gsettings was given.
4360 if test "${with_gsettings+set}" = set; then :
4361 withval=$with_gsettings;
4362 else
4363 with_gsettings=$with_features
4367 # Check whether --with-selinux was given.
4368 if test "${with_selinux+set}" = set; then :
4369 withval=$with_selinux;
4370 else
4371 with_selinux=$with_features
4375 # Check whether --with-gnutls was given.
4376 if test "${with_gnutls+set}" = set; then :
4377 withval=$with_gnutls;
4378 else
4379 with_gnutls=$with_features
4383 # Check whether --with-zlib was given.
4384 if test "${with_zlib+set}" = set; then :
4385 withval=$with_zlib;
4386 else
4387 with_zlib=$with_features
4392 # Check whether --with-file-notification was given.
4393 if test "${with_file_notification+set}" = set; then :
4394 withval=$with_file_notification; case "${withval}" in
4395 y | ye | yes ) val=yes ;;
4396 n | no ) val=no ;;
4397 g | gf | gfi | gfil | gfile ) val=gfile ;;
4398 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4399 w | w3 | w32 ) val=w32 ;;
4400 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4401 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4402 \`yes' is a synonym for \`w32' on MS-Windows, for \`no' on Nextstep,
4403 otherwise for the first of \`gfile' or \`inotify' that is usable." "$LINENO" 5
4405 esac
4406 with_file_notification=$val
4408 else
4409 with_file_notification=$with_features
4413 ## For the times when you want to build Emacs but don't have
4414 ## a suitable makeinfo, and can live without the manuals.
4416 # Check whether --with-makeinfo was given.
4417 if test "${with_makeinfo+set}" = set; then :
4418 withval=$with_makeinfo;
4419 else
4420 with_makeinfo=$with_features
4424 ## Makefile.in needs the cache file name.
4427 ## This is an option because I do not know if all info/man support
4428 ## compressed files, nor how to test if they do so.
4430 # Check whether --with-compress-info was given.
4431 if test "${with_compress_info+set}" = set; then :
4432 withval=$with_compress_info;
4433 else
4434 with_compress_info=$with_features
4437 if test $with_compress_info = yes; then
4438 GZIP_INFO=yes
4439 else
4440 GZIP_INFO=
4445 # Check whether --with-pkg-config-prog was given.
4446 if test "${with_pkg_config_prog+set}" = set; then :
4447 withval=$with_pkg_config_prog;
4450 if test "X${with_pkg_config_prog}" != X; then
4451 if test "${with_pkg_config_prog}" != yes; then
4452 PKG_CONFIG="${with_pkg_config_prog}"
4457 # Check whether --with-gameuser was given.
4458 if test "${with_gameuser+set}" = set; then :
4459 withval=$with_gameuser;
4462 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4463 && gameuser="${with_gameuser}"
4464 test "X$gameuser" = X && gameuser=games
4467 # Check whether --with-gnustep-conf was given.
4468 if test "${with_gnustep_conf+set}" = set; then :
4469 withval=$with_gnustep_conf;
4472 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4473 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4474 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4475 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4477 # Check whether --enable-ns-self-contained was given.
4478 if test "${enable_ns_self_contained+set}" = set; then :
4479 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4480 else
4481 EN_NS_SELF_CONTAINED=yes
4485 # Check whether --enable-locallisppath was given.
4486 if test "${enable_locallisppath+set}" = set; then :
4487 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4488 locallisppath=
4489 elif test "${enableval}" != "yes"; then
4490 locallisppath=${enableval}
4495 # Check whether --enable-checking was given.
4496 if test "${enable_checking+set}" = set; then :
4497 enableval=$enable_checking; ac_checking_flags="${enableval}"
4500 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4501 for check in $ac_checking_flags
4503 case $check in
4504 # these set all the flags to specific states
4505 yes) ac_enable_checking=1 ;;
4506 no) ac_enable_checking= ;
4507 ac_gc_check_stringbytes= ;
4508 ac_gc_check_string_overrun= ;
4509 ac_gc_check_string_free_list= ;
4510 ac_xmalloc_overrun= ;
4511 ac_gc_check_cons_list= ;
4512 ac_glyphs_debug= ;;
4513 all) ac_enable_checking=1 ;
4514 ac_gc_check_stringbytes=1 ;
4515 ac_gc_check_string_overrun=1 ;
4516 ac_gc_check_string_free_list=1 ;
4517 ac_xmalloc_overrun=1 ;
4518 ac_gc_check_cons_list=1 ;
4519 ac_glyphs_debug=1 ;;
4520 # these enable particular checks
4521 stringbytes) ac_gc_check_stringbytes=1 ;;
4522 stringoverrun) ac_gc_check_string_overrun=1 ;;
4523 stringfreelist) ac_gc_check_string_free_list=1 ;;
4524 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4525 conslist) ac_gc_check_cons_list=1 ;;
4526 glyphs) ac_glyphs_debug=1 ;;
4527 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4528 esac
4529 done
4530 IFS="$ac_save_IFS"
4532 if test x$ac_enable_checking != x ; then
4534 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4537 if test x$ac_gc_check_stringbytes != x ; then
4539 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4542 if test x$ac_gc_check_string_overrun != x ; then
4544 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4547 if test x$ac_gc_check_string_free_list != x ; then
4549 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4552 if test x$ac_xmalloc_overrun != x ; then
4554 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4557 if test x$ac_gc_check_cons_list != x ; then
4559 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4562 if test x$ac_glyphs_debug != x ; then
4564 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4568 # Check whether --enable-check-lisp-object-type was given.
4569 if test "${enable_check_lisp_object_type+set}" = set; then :
4570 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4572 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4579 # Check whether --enable-profiling was given.
4580 if test "${enable_profiling+set}" = set; then :
4581 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4584 if test x$ac_enable_profiling != x ; then
4585 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4586 else
4587 PROFILING_CFLAGS=
4591 # Check whether --enable-autodepend was given.
4592 if test "${enable_autodepend+set}" = set; then :
4593 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4594 else
4595 ac_enable_autodepend=yes
4599 # Check whether --enable-gtk-deprecation-warnings was given.
4600 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4601 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4605 #### Make srcdir absolute, if it isn't already. It's important to
4606 #### avoid running the file name through pwd unnecessarily, since pwd can
4607 #### give you automounter prefixes, which can go away. We do all this
4608 #### so Emacs can find its files when run uninstalled.
4609 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4610 unset CDPATH
4611 case "${srcdir}" in
4612 [\\/]* | ?:[\\/]*) ;;
4614 ## We may be able to use the $PWD environment variable to make this
4615 ## absolute. But sometimes PWD is inaccurate.
4616 ## Note: we used to use $PWD at the end instead of `pwd`,
4617 ## but that tested only for a well-formed and valid PWD,
4618 ## it did not object when PWD was well-formed and valid but just wrong.
4619 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4620 then
4621 srcdir="$PWD"
4622 else
4623 srcdir=`(cd "$srcdir"; pwd)`
4626 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4627 esac
4629 ### Canonicalize the configuration name.
4631 # Make sure we can run config.sub.
4632 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4633 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4636 $as_echo_n "checking build system type... " >&6; }
4637 if test "${ac_cv_build+set}" = set; then :
4638 $as_echo_n "(cached) " >&6
4639 else
4640 ac_build_alias=$build_alias
4641 test "x$ac_build_alias" = x &&
4642 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4643 test "x$ac_build_alias" = x &&
4644 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4645 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4646 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4650 $as_echo "$ac_cv_build" >&6; }
4651 case $ac_cv_build in
4652 *-*-*) ;;
4653 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4654 esac
4655 build=$ac_cv_build
4656 ac_save_IFS=$IFS; IFS='-'
4657 set x $ac_cv_build
4658 shift
4659 build_cpu=$1
4660 build_vendor=$2
4661 shift; shift
4662 # Remember, the first character of IFS is used to create $*,
4663 # except with old shells:
4664 build_os=$*
4665 IFS=$ac_save_IFS
4666 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4670 $as_echo_n "checking host system type... " >&6; }
4671 if test "${ac_cv_host+set}" = set; then :
4672 $as_echo_n "(cached) " >&6
4673 else
4674 if test "x$host_alias" = x; then
4675 ac_cv_host=$ac_cv_build
4676 else
4677 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4678 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4683 $as_echo "$ac_cv_host" >&6; }
4684 case $ac_cv_host in
4685 *-*-*) ;;
4686 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4687 esac
4688 host=$ac_cv_host
4689 ac_save_IFS=$IFS; IFS='-'
4690 set x $ac_cv_host
4691 shift
4692 host_cpu=$1
4693 host_vendor=$2
4694 shift; shift
4695 # Remember, the first character of IFS is used to create $*,
4696 # except with old shells:
4697 host_os=$*
4698 IFS=$ac_save_IFS
4699 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4702 canonical=$host
4703 configuration=${host_alias-${build_alias-$host}}
4707 ### If you add support for a new configuration, add code to this
4708 ### switch statement to recognize your configuration name and select
4709 ### the appropriate operating system file.
4711 ### You would hope that you could choose an s/*.h
4712 ### file based on the operating system portion. However, it turns out
4713 ### that each s/*.h file is pretty manufacturer-specific.
4714 ### So we basically have to have a special case for each
4715 ### configuration name.
4717 ### As far as handling version numbers on operating systems is
4718 ### concerned, make sure things will fail in a fixable way. If
4719 ### /etc/MACHINES doesn't say anything about version numbers, be
4720 ### prepared to handle anything reasonably. If version numbers
4721 ### matter, be sure /etc/MACHINES says something about it.
4723 opsys='' unported=no
4724 case "${canonical}" in
4726 ## GNU/Linux and similar ports
4727 *-*-linux* )
4728 opsys=gnu-linux
4731 ## FreeBSD ports
4732 *-*-freebsd* )
4733 opsys=freebsd
4736 ## DragonFly ports
4737 *-*-dragonfly* )
4738 opsys=dragonfly
4741 ## FreeBSD kernel + glibc based userland
4742 *-*-kfreebsd*gnu* )
4743 opsys=gnu-kfreebsd
4746 ## NetBSD ports
4747 *-*-netbsd* )
4748 opsys=netbsd
4751 ## OpenBSD ports
4752 *-*-openbsd* )
4753 opsys=openbsd
4756 ## Apple Darwin / Mac OS X
4757 *-apple-darwin* )
4758 case "${canonical}" in
4759 i[3456]86-* ) ;;
4760 powerpc-* ) ;;
4761 x86_64-* ) ;;
4762 * ) unported=yes ;;
4763 esac
4764 opsys=darwin
4765 ## Use fink packages if available.
4766 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4767 ## if test -d /sw/include && test -d /sw/lib; then
4768 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4769 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4770 ## fi
4773 ## Cygwin ports
4774 *-*-cygwin )
4775 opsys=cygwin
4778 ## HP 9000 series 700 and 800, running HP/UX
4779 hppa*-hp-hpux10.2* )
4780 opsys=hpux10-20
4782 hppa*-hp-hpux1[1-9]* )
4783 opsys=hpux11
4784 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4787 ## IBM machines
4788 rs6000-ibm-aix4.[23]* )
4789 opsys=aix4-2
4791 powerpc-ibm-aix4.[23]* )
4792 opsys=aix4-2
4794 rs6000-ibm-aix[56]* )
4795 opsys=aix4-2
4797 powerpc-ibm-aix[56]* )
4798 opsys=aix4-2
4801 ## Silicon Graphics machines
4802 ## Iris 4D
4803 mips-sgi-irix6.5 )
4804 opsys=irix6-5
4805 # Without defining _LANGUAGE_C, things get masked out in the headers
4806 # so that, for instance, grepping for `free' in stdlib.h fails and
4807 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4808 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4811 ## Suns
4812 *-sun-solaris* \
4813 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4814 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4815 case "${canonical}" in
4816 i[3456]86-*-* ) ;;
4817 amd64-*-*|x86_64-*-*) ;;
4818 sparc* ) ;;
4819 * ) unported=yes ;;
4820 esac
4821 case "${canonical}" in
4822 *-sunos5.6* | *-solaris2.6* )
4823 opsys=sol2-6
4824 RANLIB="ar -ts"
4826 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4827 opsys=sol2-6
4828 emacs_check_sunpro_c=yes
4830 *-sunos5* | *-solaris* )
4831 opsys=sol2-10
4832 emacs_check_sunpro_c=yes
4834 esac
4835 ## Watch out for a compiler that we know will not work.
4836 case "${canonical}" in
4837 *-solaris* | *-sunos5* )
4838 if [ "x$CC" = x/usr/ucb/cc ]; then
4839 ## /usr/ucb/cc doesn't work;
4840 ## we should find some other compiler that does work.
4841 unset CC
4844 *) ;;
4845 esac
4848 ## Intel 386 machines where we don't care about the manufacturer.
4849 i[3456]86-*-* )
4850 case "${canonical}" in
4851 *-darwin* ) opsys=darwin ;;
4852 *-mingw32 )
4853 opsys=mingw32
4854 # MinGW overrides and adds some system headers in nt/inc.
4855 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4857 *-sysv4.2uw* ) opsys=unixware ;;
4858 *-sysv5uw* ) opsys=unixware ;;
4859 *-sysv5OpenUNIX* ) opsys=unixware ;;
4860 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4861 esac
4865 unported=yes
4867 esac
4869 ### If the code above didn't choose an operating system, just choose
4870 ### an operating system based on the configuration name. You really
4871 ### only want to use this when you have no idea what the right
4872 ### operating system is; if you know what operating systems a machine
4873 ### runs, it's cleaner to make it explicit in the case statement
4874 ### above.
4875 if test x"${opsys}" = x; then
4876 case "${canonical}" in
4877 *-gnu* ) opsys=gnu ;;
4879 unported=yes
4881 esac
4886 if test $unported = yes; then
4887 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4888 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4892 #### Choose a compiler.
4894 ac_ext=c
4895 ac_cpp='$CPP $CPPFLAGS'
4896 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4897 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4898 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4899 if test -n "$ac_tool_prefix"; then
4900 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4901 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4903 $as_echo_n "checking for $ac_word... " >&6; }
4904 if test "${ac_cv_prog_CC+set}" = set; then :
4905 $as_echo_n "(cached) " >&6
4906 else
4907 if test -n "$CC"; then
4908 ac_cv_prog_CC="$CC" # Let the user override the test.
4909 else
4910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4911 for as_dir in $PATH
4913 IFS=$as_save_IFS
4914 test -z "$as_dir" && as_dir=.
4915 for ac_exec_ext in '' $ac_executable_extensions; do
4916 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4917 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4918 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4919 break 2
4921 done
4922 done
4923 IFS=$as_save_IFS
4927 CC=$ac_cv_prog_CC
4928 if test -n "$CC"; then
4929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4930 $as_echo "$CC" >&6; }
4931 else
4932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4933 $as_echo "no" >&6; }
4938 if test -z "$ac_cv_prog_CC"; then
4939 ac_ct_CC=$CC
4940 # Extract the first word of "gcc", so it can be a program name with args.
4941 set dummy gcc; ac_word=$2
4942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4943 $as_echo_n "checking for $ac_word... " >&6; }
4944 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4945 $as_echo_n "(cached) " >&6
4946 else
4947 if test -n "$ac_ct_CC"; then
4948 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4949 else
4950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4951 for as_dir in $PATH
4953 IFS=$as_save_IFS
4954 test -z "$as_dir" && as_dir=.
4955 for ac_exec_ext in '' $ac_executable_extensions; do
4956 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4957 ac_cv_prog_ac_ct_CC="gcc"
4958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4959 break 2
4961 done
4962 done
4963 IFS=$as_save_IFS
4967 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4968 if test -n "$ac_ct_CC"; then
4969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4970 $as_echo "$ac_ct_CC" >&6; }
4971 else
4972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4973 $as_echo "no" >&6; }
4976 if test "x$ac_ct_CC" = x; then
4977 CC=""
4978 else
4979 case $cross_compiling:$ac_tool_warned in
4980 yes:)
4981 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4982 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4983 ac_tool_warned=yes ;;
4984 esac
4985 CC=$ac_ct_CC
4987 else
4988 CC="$ac_cv_prog_CC"
4991 if test -z "$CC"; then
4992 if test -n "$ac_tool_prefix"; then
4993 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4994 set dummy ${ac_tool_prefix}cc; ac_word=$2
4995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4996 $as_echo_n "checking for $ac_word... " >&6; }
4997 if test "${ac_cv_prog_CC+set}" = set; then :
4998 $as_echo_n "(cached) " >&6
4999 else
5000 if test -n "$CC"; then
5001 ac_cv_prog_CC="$CC" # Let the user override the test.
5002 else
5003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5004 for as_dir in $PATH
5006 IFS=$as_save_IFS
5007 test -z "$as_dir" && as_dir=.
5008 for ac_exec_ext in '' $ac_executable_extensions; do
5009 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5010 ac_cv_prog_CC="${ac_tool_prefix}cc"
5011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5012 break 2
5014 done
5015 done
5016 IFS=$as_save_IFS
5020 CC=$ac_cv_prog_CC
5021 if test -n "$CC"; then
5022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5023 $as_echo "$CC" >&6; }
5024 else
5025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5026 $as_echo "no" >&6; }
5032 if test -z "$CC"; then
5033 # Extract the first word of "cc", so it can be a program name with args.
5034 set dummy cc; ac_word=$2
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5036 $as_echo_n "checking for $ac_word... " >&6; }
5037 if test "${ac_cv_prog_CC+set}" = set; then :
5038 $as_echo_n "(cached) " >&6
5039 else
5040 if test -n "$CC"; then
5041 ac_cv_prog_CC="$CC" # Let the user override the test.
5042 else
5043 ac_prog_rejected=no
5044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5045 for as_dir in $PATH
5047 IFS=$as_save_IFS
5048 test -z "$as_dir" && as_dir=.
5049 for ac_exec_ext in '' $ac_executable_extensions; do
5050 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5051 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5052 ac_prog_rejected=yes
5053 continue
5055 ac_cv_prog_CC="cc"
5056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5057 break 2
5059 done
5060 done
5061 IFS=$as_save_IFS
5063 if test $ac_prog_rejected = yes; then
5064 # We found a bogon in the path, so make sure we never use it.
5065 set dummy $ac_cv_prog_CC
5066 shift
5067 if test $# != 0; then
5068 # We chose a different compiler from the bogus one.
5069 # However, it has the same basename, so the bogon will be chosen
5070 # first if we set CC to just the basename; use the full file name.
5071 shift
5072 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5077 CC=$ac_cv_prog_CC
5078 if test -n "$CC"; then
5079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5080 $as_echo "$CC" >&6; }
5081 else
5082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5083 $as_echo "no" >&6; }
5088 if test -z "$CC"; then
5089 if test -n "$ac_tool_prefix"; then
5090 for ac_prog in cl.exe
5092 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5093 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5095 $as_echo_n "checking for $ac_word... " >&6; }
5096 if test "${ac_cv_prog_CC+set}" = set; then :
5097 $as_echo_n "(cached) " >&6
5098 else
5099 if test -n "$CC"; then
5100 ac_cv_prog_CC="$CC" # Let the user override the test.
5101 else
5102 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5103 for as_dir in $PATH
5105 IFS=$as_save_IFS
5106 test -z "$as_dir" && as_dir=.
5107 for ac_exec_ext in '' $ac_executable_extensions; do
5108 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5109 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5110 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5111 break 2
5113 done
5114 done
5115 IFS=$as_save_IFS
5119 CC=$ac_cv_prog_CC
5120 if test -n "$CC"; then
5121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5122 $as_echo "$CC" >&6; }
5123 else
5124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5125 $as_echo "no" >&6; }
5129 test -n "$CC" && break
5130 done
5132 if test -z "$CC"; then
5133 ac_ct_CC=$CC
5134 for ac_prog in cl.exe
5136 # Extract the first word of "$ac_prog", so it can be a program name with args.
5137 set dummy $ac_prog; ac_word=$2
5138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5139 $as_echo_n "checking for $ac_word... " >&6; }
5140 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5141 $as_echo_n "(cached) " >&6
5142 else
5143 if test -n "$ac_ct_CC"; then
5144 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5145 else
5146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5147 for as_dir in $PATH
5149 IFS=$as_save_IFS
5150 test -z "$as_dir" && as_dir=.
5151 for ac_exec_ext in '' $ac_executable_extensions; do
5152 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5153 ac_cv_prog_ac_ct_CC="$ac_prog"
5154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5155 break 2
5157 done
5158 done
5159 IFS=$as_save_IFS
5163 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5164 if test -n "$ac_ct_CC"; then
5165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5166 $as_echo "$ac_ct_CC" >&6; }
5167 else
5168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5169 $as_echo "no" >&6; }
5173 test -n "$ac_ct_CC" && break
5174 done
5176 if test "x$ac_ct_CC" = x; then
5177 CC=""
5178 else
5179 case $cross_compiling:$ac_tool_warned in
5180 yes:)
5181 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5182 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5183 ac_tool_warned=yes ;;
5184 esac
5185 CC=$ac_ct_CC
5192 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5193 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5194 as_fn_error "no acceptable C compiler found in \$PATH
5195 See \`config.log' for more details." "$LINENO" 5; }
5197 # Provide some information about the compiler.
5198 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5199 set X $ac_compile
5200 ac_compiler=$2
5201 for ac_option in --version -v -V -qversion; do
5202 { { ac_try="$ac_compiler $ac_option >&5"
5203 case "(($ac_try" in
5204 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5205 *) ac_try_echo=$ac_try;;
5206 esac
5207 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5208 $as_echo "$ac_try_echo"; } >&5
5209 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5210 ac_status=$?
5211 if test -s conftest.err; then
5212 sed '10a\
5213 ... rest of stderr output deleted ...
5214 10q' conftest.err >conftest.er1
5215 cat conftest.er1 >&5
5217 rm -f conftest.er1 conftest.err
5218 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5219 test $ac_status = 0; }
5220 done
5222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5223 /* end confdefs.h. */
5226 main ()
5230 return 0;
5232 _ACEOF
5233 ac_clean_files_save=$ac_clean_files
5234 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5235 # Try to create an executable without -o first, disregard a.out.
5236 # It will help us diagnose broken compilers, and finding out an intuition
5237 # of exeext.
5238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5239 $as_echo_n "checking whether the C compiler works... " >&6; }
5240 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5242 # The possible output files:
5243 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5245 ac_rmfiles=
5246 for ac_file in $ac_files
5248 case $ac_file in
5249 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5250 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5251 esac
5252 done
5253 rm -f $ac_rmfiles
5255 if { { ac_try="$ac_link_default"
5256 case "(($ac_try" in
5257 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5258 *) ac_try_echo=$ac_try;;
5259 esac
5260 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5261 $as_echo "$ac_try_echo"; } >&5
5262 (eval "$ac_link_default") 2>&5
5263 ac_status=$?
5264 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5265 test $ac_status = 0; }; then :
5266 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5267 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5268 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5269 # so that the user can short-circuit this test for compilers unknown to
5270 # Autoconf.
5271 for ac_file in $ac_files ''
5273 test -f "$ac_file" || continue
5274 case $ac_file in
5275 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5277 [ab].out )
5278 # We found the default executable, but exeext='' is most
5279 # certainly right.
5280 break;;
5281 *.* )
5282 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5283 then :; else
5284 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5286 # We set ac_cv_exeext here because the later test for it is not
5287 # safe: cross compilers may not add the suffix if given an `-o'
5288 # argument, so we may need to know it at that point already.
5289 # Even if this section looks crufty: it has the advantage of
5290 # actually working.
5291 break;;
5293 break;;
5294 esac
5295 done
5296 test "$ac_cv_exeext" = no && ac_cv_exeext=
5298 else
5299 ac_file=''
5301 if test -z "$ac_file"; then :
5302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5303 $as_echo "no" >&6; }
5304 $as_echo "$as_me: failed program was:" >&5
5305 sed 's/^/| /' conftest.$ac_ext >&5
5307 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5308 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5309 { as_fn_set_status 77
5310 as_fn_error "C compiler cannot create executables
5311 See \`config.log' for more details." "$LINENO" 5; }; }
5312 else
5313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5314 $as_echo "yes" >&6; }
5316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5317 $as_echo_n "checking for C compiler default output file name... " >&6; }
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5319 $as_echo "$ac_file" >&6; }
5320 ac_exeext=$ac_cv_exeext
5322 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5323 ac_clean_files=$ac_clean_files_save
5324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5325 $as_echo_n "checking for suffix of executables... " >&6; }
5326 if { { ac_try="$ac_link"
5327 case "(($ac_try" in
5328 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5329 *) ac_try_echo=$ac_try;;
5330 esac
5331 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5332 $as_echo "$ac_try_echo"; } >&5
5333 (eval "$ac_link") 2>&5
5334 ac_status=$?
5335 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5336 test $ac_status = 0; }; then :
5337 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5338 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5339 # work properly (i.e., refer to `conftest.exe'), while it won't with
5340 # `rm'.
5341 for ac_file in conftest.exe conftest conftest.*; do
5342 test -f "$ac_file" || continue
5343 case $ac_file in
5344 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5345 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5346 break;;
5347 * ) break;;
5348 esac
5349 done
5350 else
5351 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5352 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5353 as_fn_error "cannot compute suffix of executables: cannot compile and link
5354 See \`config.log' for more details." "$LINENO" 5; }
5356 rm -f conftest conftest$ac_cv_exeext
5357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5358 $as_echo "$ac_cv_exeext" >&6; }
5360 rm -f conftest.$ac_ext
5361 EXEEXT=$ac_cv_exeext
5362 ac_exeext=$EXEEXT
5363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5364 /* end confdefs.h. */
5365 #include <stdio.h>
5367 main ()
5369 FILE *f = fopen ("conftest.out", "w");
5370 return ferror (f) || fclose (f) != 0;
5373 return 0;
5375 _ACEOF
5376 ac_clean_files="$ac_clean_files conftest.out"
5377 # Check that the compiler produces executables we can run. If not, either
5378 # the compiler is broken, or we cross compile.
5379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5380 $as_echo_n "checking whether we are cross compiling... " >&6; }
5381 if test "$cross_compiling" != yes; then
5382 { { ac_try="$ac_link"
5383 case "(($ac_try" in
5384 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5385 *) ac_try_echo=$ac_try;;
5386 esac
5387 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5388 $as_echo "$ac_try_echo"; } >&5
5389 (eval "$ac_link") 2>&5
5390 ac_status=$?
5391 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5392 test $ac_status = 0; }
5393 if { ac_try='./conftest$ac_cv_exeext'
5394 { { case "(($ac_try" in
5395 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5396 *) ac_try_echo=$ac_try;;
5397 esac
5398 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5399 $as_echo "$ac_try_echo"; } >&5
5400 (eval "$ac_try") 2>&5
5401 ac_status=$?
5402 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5403 test $ac_status = 0; }; }; then
5404 cross_compiling=no
5405 else
5406 if test "$cross_compiling" = maybe; then
5407 cross_compiling=yes
5408 else
5409 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5410 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5411 as_fn_error "cannot run C compiled programs.
5412 If you meant to cross compile, use \`--host'.
5413 See \`config.log' for more details." "$LINENO" 5; }
5417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5418 $as_echo "$cross_compiling" >&6; }
5420 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5421 ac_clean_files=$ac_clean_files_save
5422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5423 $as_echo_n "checking for suffix of object files... " >&6; }
5424 if test "${ac_cv_objext+set}" = set; then :
5425 $as_echo_n "(cached) " >&6
5426 else
5427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5428 /* end confdefs.h. */
5431 main ()
5435 return 0;
5437 _ACEOF
5438 rm -f conftest.o conftest.obj
5439 if { { ac_try="$ac_compile"
5440 case "(($ac_try" in
5441 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5442 *) ac_try_echo=$ac_try;;
5443 esac
5444 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5445 $as_echo "$ac_try_echo"; } >&5
5446 (eval "$ac_compile") 2>&5
5447 ac_status=$?
5448 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5449 test $ac_status = 0; }; then :
5450 for ac_file in conftest.o conftest.obj conftest.*; do
5451 test -f "$ac_file" || continue;
5452 case $ac_file in
5453 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5454 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5455 break;;
5456 esac
5457 done
5458 else
5459 $as_echo "$as_me: failed program was:" >&5
5460 sed 's/^/| /' conftest.$ac_ext >&5
5462 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5463 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5464 as_fn_error "cannot compute suffix of object files: cannot compile
5465 See \`config.log' for more details." "$LINENO" 5; }
5467 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5470 $as_echo "$ac_cv_objext" >&6; }
5471 OBJEXT=$ac_cv_objext
5472 ac_objext=$OBJEXT
5473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5474 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5475 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5476 $as_echo_n "(cached) " >&6
5477 else
5478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5479 /* end confdefs.h. */
5482 main ()
5484 #ifndef __GNUC__
5485 choke me
5486 #endif
5489 return 0;
5491 _ACEOF
5492 if ac_fn_c_try_compile "$LINENO"; then :
5493 ac_compiler_gnu=yes
5494 else
5495 ac_compiler_gnu=no
5497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5498 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5502 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5503 if test $ac_compiler_gnu = yes; then
5504 GCC=yes
5505 else
5506 GCC=
5508 ac_test_CFLAGS=${CFLAGS+set}
5509 ac_save_CFLAGS=$CFLAGS
5510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5511 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5512 if test "${ac_cv_prog_cc_g+set}" = set; then :
5513 $as_echo_n "(cached) " >&6
5514 else
5515 ac_save_c_werror_flag=$ac_c_werror_flag
5516 ac_c_werror_flag=yes
5517 ac_cv_prog_cc_g=no
5518 CFLAGS="-g"
5519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5520 /* end confdefs.h. */
5523 main ()
5527 return 0;
5529 _ACEOF
5530 if ac_fn_c_try_compile "$LINENO"; then :
5531 ac_cv_prog_cc_g=yes
5532 else
5533 CFLAGS=""
5534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5535 /* end confdefs.h. */
5538 main ()
5542 return 0;
5544 _ACEOF
5545 if ac_fn_c_try_compile "$LINENO"; then :
5547 else
5548 ac_c_werror_flag=$ac_save_c_werror_flag
5549 CFLAGS="-g"
5550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5551 /* end confdefs.h. */
5554 main ()
5558 return 0;
5560 _ACEOF
5561 if ac_fn_c_try_compile "$LINENO"; then :
5562 ac_cv_prog_cc_g=yes
5564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5568 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5569 ac_c_werror_flag=$ac_save_c_werror_flag
5571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5572 $as_echo "$ac_cv_prog_cc_g" >&6; }
5573 if test "$ac_test_CFLAGS" = set; then
5574 CFLAGS=$ac_save_CFLAGS
5575 elif test $ac_cv_prog_cc_g = yes; then
5576 if test "$GCC" = yes; then
5577 CFLAGS="-g -O2"
5578 else
5579 CFLAGS="-g"
5581 else
5582 if test "$GCC" = yes; then
5583 CFLAGS="-O2"
5584 else
5585 CFLAGS=
5588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5589 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5590 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5591 $as_echo_n "(cached) " >&6
5592 else
5593 ac_cv_prog_cc_c89=no
5594 ac_save_CC=$CC
5595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5596 /* end confdefs.h. */
5597 #include <stdarg.h>
5598 #include <stdio.h>
5599 #include <sys/types.h>
5600 #include <sys/stat.h>
5601 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5602 struct buf { int x; };
5603 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5604 static char *e (p, i)
5605 char **p;
5606 int i;
5608 return p[i];
5610 static char *f (char * (*g) (char **, int), char **p, ...)
5612 char *s;
5613 va_list v;
5614 va_start (v,p);
5615 s = g (p, va_arg (v,int));
5616 va_end (v);
5617 return s;
5620 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5621 function prototypes and stuff, but not '\xHH' hex character constants.
5622 These don't provoke an error unfortunately, instead are silently treated
5623 as 'x'. The following induces an error, until -std is added to get
5624 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5625 array size at least. It's necessary to write '\x00'==0 to get something
5626 that's true only with -std. */
5627 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5629 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5630 inside strings and character constants. */
5631 #define FOO(x) 'x'
5632 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5634 int test (int i, double x);
5635 struct s1 {int (*f) (int a);};
5636 struct s2 {int (*f) (double a);};
5637 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5638 int argc;
5639 char **argv;
5641 main ()
5643 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5645 return 0;
5647 _ACEOF
5648 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5649 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5651 CC="$ac_save_CC $ac_arg"
5652 if ac_fn_c_try_compile "$LINENO"; then :
5653 ac_cv_prog_cc_c89=$ac_arg
5655 rm -f core conftest.err conftest.$ac_objext
5656 test "x$ac_cv_prog_cc_c89" != "xno" && break
5657 done
5658 rm -f conftest.$ac_ext
5659 CC=$ac_save_CC
5662 # AC_CACHE_VAL
5663 case "x$ac_cv_prog_cc_c89" in
5665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5666 $as_echo "none needed" >&6; } ;;
5667 xno)
5668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5669 $as_echo "unsupported" >&6; } ;;
5671 CC="$CC $ac_cv_prog_cc_c89"
5672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5673 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5674 esac
5675 if test "x$ac_cv_prog_cc_c89" != xno; then :
5679 ac_ext=c
5680 ac_cpp='$CPP $CPPFLAGS'
5681 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5682 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5683 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5684 DEPDIR="${am__leading_dot}deps"
5686 ac_config_commands="$ac_config_commands depfiles"
5689 am_make=${MAKE-make}
5690 cat > confinc << 'END'
5691 am__doit:
5692 @echo this is the am__doit target
5693 .PHONY: am__doit
5695 # If we don't find an include directive, just comment out the code.
5696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5697 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5698 am__include="#"
5699 am__quote=
5700 _am_result=none
5701 # First try GNU make style include.
5702 echo "include confinc" > confmf
5703 # Ignore all kinds of additional output from `make'.
5704 case `$am_make -s -f confmf 2> /dev/null` in #(
5705 *the\ am__doit\ target*)
5706 am__include=include
5707 am__quote=
5708 _am_result=GNU
5710 esac
5711 # Now try BSD make style include.
5712 if test "$am__include" = "#"; then
5713 echo '.include "confinc"' > confmf
5714 case `$am_make -s -f confmf 2> /dev/null` in #(
5715 *the\ am__doit\ target*)
5716 am__include=.include
5717 am__quote="\""
5718 _am_result=BSD
5720 esac
5724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5725 $as_echo "$_am_result" >&6; }
5726 rm -f confinc confmf
5728 # Check whether --enable-dependency-tracking was given.
5729 if test "${enable_dependency_tracking+set}" = set; then :
5730 enableval=$enable_dependency_tracking;
5733 if test "x$enable_dependency_tracking" != xno; then
5734 am_depcomp="$ac_aux_dir/depcomp"
5735 AMDEPBACKSLASH='\'
5737 if test "x$enable_dependency_tracking" != xno; then
5738 AMDEP_TRUE=
5739 AMDEP_FALSE='#'
5740 else
5741 AMDEP_TRUE='#'
5742 AMDEP_FALSE=
5747 depcc="$CC" am_compiler_list=
5749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5750 $as_echo_n "checking dependency style of $depcc... " >&6; }
5751 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5752 $as_echo_n "(cached) " >&6
5753 else
5754 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5755 # We make a subdir and do the tests there. Otherwise we can end up
5756 # making bogus files that we don't know about and never remove. For
5757 # instance it was reported that on HP-UX the gcc test will end up
5758 # making a dummy file named `D' -- because `-MD' means `put the output
5759 # in D'.
5760 mkdir conftest.dir
5761 # Copy depcomp to subdir because otherwise we won't find it if we're
5762 # using a relative directory.
5763 cp "$am_depcomp" conftest.dir
5764 cd conftest.dir
5765 # We will build objects and dependencies in a subdirectory because
5766 # it helps to detect inapplicable dependency modes. For instance
5767 # both Tru64's cc and ICC support -MD to output dependencies as a
5768 # side effect of compilation, but ICC will put the dependencies in
5769 # the current directory while Tru64 will put them in the object
5770 # directory.
5771 mkdir sub
5773 am_cv_CC_dependencies_compiler_type=none
5774 if test "$am_compiler_list" = ""; then
5775 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5777 am__universal=false
5778 case " $depcc " in #(
5779 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5780 esac
5782 for depmode in $am_compiler_list; do
5783 # Setup a source with many dependencies, because some compilers
5784 # like to wrap large dependency lists on column 80 (with \), and
5785 # we should not choose a depcomp mode which is confused by this.
5787 # We need to recreate these files for each test, as the compiler may
5788 # overwrite some of them when testing with obscure command lines.
5789 # This happens at least with the AIX C compiler.
5790 : > sub/conftest.c
5791 for i in 1 2 3 4 5 6; do
5792 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5793 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5794 # Solaris 8's {/usr,}/bin/sh.
5795 touch sub/conftst$i.h
5796 done
5797 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5799 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5800 # mode. It turns out that the SunPro C++ compiler does not properly
5801 # handle `-M -o', and we need to detect this. Also, some Intel
5802 # versions had trouble with output in subdirs
5803 am__obj=sub/conftest.${OBJEXT-o}
5804 am__minus_obj="-o $am__obj"
5805 case $depmode in
5806 gcc)
5807 # This depmode causes a compiler race in universal mode.
5808 test "$am__universal" = false || continue
5810 nosideeffect)
5811 # after this tag, mechanisms are not by side-effect, so they'll
5812 # only be used when explicitly requested
5813 if test "x$enable_dependency_tracking" = xyes; then
5814 continue
5815 else
5816 break
5819 msvisualcpp | msvcmsys)
5820 # This compiler won't grok `-c -o', but also, the minuso test has
5821 # not run yet. These depmodes are late enough in the game, and
5822 # so weak that their functioning should not be impacted.
5823 am__obj=conftest.${OBJEXT-o}
5824 am__minus_obj=
5826 none) break ;;
5827 esac
5828 if depmode=$depmode \
5829 source=sub/conftest.c object=$am__obj \
5830 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5831 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5832 >/dev/null 2>conftest.err &&
5833 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5834 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5835 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5836 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5837 # icc doesn't choke on unknown options, it will just issue warnings
5838 # or remarks (even with -Werror). So we grep stderr for any message
5839 # that says an option was ignored or not supported.
5840 # When given -MP, icc 7.0 and 7.1 complain thusly:
5841 # icc: Command line warning: ignoring option '-M'; no argument required
5842 # The diagnosis changed in icc 8.0:
5843 # icc: Command line remark: option '-MP' not supported
5844 if (grep 'ignoring option' conftest.err ||
5845 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5846 am_cv_CC_dependencies_compiler_type=$depmode
5847 break
5850 done
5852 cd ..
5853 rm -rf conftest.dir
5854 else
5855 am_cv_CC_dependencies_compiler_type=none
5859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5860 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5861 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5864 test "x$enable_dependency_tracking" != xno \
5865 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5866 am__fastdepCC_TRUE=
5867 am__fastdepCC_FALSE='#'
5868 else
5869 am__fastdepCC_TRUE='#'
5870 am__fastdepCC_FALSE=
5874 if test "x$CC" != xcc; then
5875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5876 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5877 else
5878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5879 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5881 set dummy $CC; ac_cc=`$as_echo "$2" |
5882 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5883 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5884 $as_echo_n "(cached) " >&6
5885 else
5886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5887 /* end confdefs.h. */
5890 main ()
5894 return 0;
5896 _ACEOF
5897 # Make sure it works both with $CC and with simple cc.
5898 # We do the test twice because some compilers refuse to overwrite an
5899 # existing .o file with -o, though they will create one.
5900 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5901 rm -f conftest2.*
5902 if { { case "(($ac_try" in
5903 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5904 *) ac_try_echo=$ac_try;;
5905 esac
5906 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5907 $as_echo "$ac_try_echo"; } >&5
5908 (eval "$ac_try") 2>&5
5909 ac_status=$?
5910 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5911 test $ac_status = 0; } &&
5912 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5913 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5914 *) ac_try_echo=$ac_try;;
5915 esac
5916 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5917 $as_echo "$ac_try_echo"; } >&5
5918 (eval "$ac_try") 2>&5
5919 ac_status=$?
5920 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5921 test $ac_status = 0; };
5922 then
5923 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5924 if test "x$CC" != xcc; then
5925 # Test first that cc exists at all.
5926 if { ac_try='cc -c conftest.$ac_ext >&5'
5927 { { case "(($ac_try" in
5928 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5929 *) ac_try_echo=$ac_try;;
5930 esac
5931 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5932 $as_echo "$ac_try_echo"; } >&5
5933 (eval "$ac_try") 2>&5
5934 ac_status=$?
5935 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5936 test $ac_status = 0; }; }; then
5937 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5938 rm -f conftest2.*
5939 if { { case "(($ac_try" in
5940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5941 *) ac_try_echo=$ac_try;;
5942 esac
5943 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5944 $as_echo "$ac_try_echo"; } >&5
5945 (eval "$ac_try") 2>&5
5946 ac_status=$?
5947 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5948 test $ac_status = 0; } &&
5949 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5950 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5951 *) ac_try_echo=$ac_try;;
5952 esac
5953 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5954 $as_echo "$ac_try_echo"; } >&5
5955 (eval "$ac_try") 2>&5
5956 ac_status=$?
5957 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5958 test $ac_status = 0; };
5959 then
5960 # cc works too.
5962 else
5963 # cc exists but doesn't like -o.
5964 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5968 else
5969 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5971 rm -f core conftest*
5974 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5976 $as_echo "yes" >&6; }
5977 else
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5979 $as_echo "no" >&6; }
5981 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5985 # FIXME: we rely on the cache variable name because
5986 # there is no other way.
5987 set dummy $CC
5988 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5989 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5990 if test "$am_t" != yes; then
5991 # Losing compiler, so override with the script.
5992 # FIXME: It is wrong to rewrite CC.
5993 # But if we don't then we get into trouble of one sort or another.
5994 # A longer-term fix would be to have automake use am__CC in this case,
5995 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5996 CC="$am_aux_dir/compile $CC"
6001 if test x$GCC = xyes; then
6002 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
6003 else
6004 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
6007 if test "x$opsys" = "xmingw32"; then
6008 BUILDING_FOR_WINDOWSNT_TRUE=
6009 BUILDING_FOR_WINDOWSNT_FALSE='#'
6010 else
6011 BUILDING_FOR_WINDOWSNT_TRUE='#'
6012 BUILDING_FOR_WINDOWSNT_FALSE=
6016 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
6017 # as we don't use them.
6019 # Avoid gnulib's threadlib module, as we do threads our own way.
6022 # Initialize gnulib right after choosing the compiler.
6024 ac_ext=c
6025 ac_cpp='$CPP $CPPFLAGS'
6026 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6027 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6028 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6030 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6031 # On Suns, sometimes $CPP names a directory.
6032 if test -n "$CPP" && test -d "$CPP"; then
6033 CPP=
6035 if test -z "$CPP"; then
6036 if test "${ac_cv_prog_CPP+set}" = set; then :
6037 $as_echo_n "(cached) " >&6
6038 else
6039 # Double quotes because CPP needs to be expanded
6040 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6042 ac_preproc_ok=false
6043 for ac_c_preproc_warn_flag in '' yes
6045 # Use a header file that comes with gcc, so configuring glibc
6046 # with a fresh cross-compiler works.
6047 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6048 # <limits.h> exists even on freestanding compilers.
6049 # On the NeXT, cc -E runs the code through the compiler's parser,
6050 # not just through cpp. "Syntax error" is here to catch this case.
6051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6052 /* end confdefs.h. */
6053 #ifdef __STDC__
6054 # include <limits.h>
6055 #else
6056 # include <assert.h>
6057 #endif
6058 Syntax error
6059 _ACEOF
6060 if ac_fn_c_try_cpp "$LINENO"; then :
6062 else
6063 # Broken: fails on valid input.
6064 continue
6066 rm -f conftest.err conftest.$ac_ext
6068 # OK, works on sane cases. Now check whether nonexistent headers
6069 # can be detected and how.
6070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6071 /* end confdefs.h. */
6072 #include <ac_nonexistent.h>
6073 _ACEOF
6074 if ac_fn_c_try_cpp "$LINENO"; then :
6075 # Broken: success on invalid input.
6076 continue
6077 else
6078 # Passes both tests.
6079 ac_preproc_ok=:
6080 break
6082 rm -f conftest.err conftest.$ac_ext
6084 done
6085 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6086 rm -f conftest.err conftest.$ac_ext
6087 if $ac_preproc_ok; then :
6088 break
6091 done
6092 ac_cv_prog_CPP=$CPP
6095 CPP=$ac_cv_prog_CPP
6096 else
6097 ac_cv_prog_CPP=$CPP
6099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6100 $as_echo "$CPP" >&6; }
6101 ac_preproc_ok=false
6102 for ac_c_preproc_warn_flag in '' yes
6104 # Use a header file that comes with gcc, so configuring glibc
6105 # with a fresh cross-compiler works.
6106 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6107 # <limits.h> exists even on freestanding compilers.
6108 # On the NeXT, cc -E runs the code through the compiler's parser,
6109 # not just through cpp. "Syntax error" is here to catch this case.
6110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6111 /* end confdefs.h. */
6112 #ifdef __STDC__
6113 # include <limits.h>
6114 #else
6115 # include <assert.h>
6116 #endif
6117 Syntax error
6118 _ACEOF
6119 if ac_fn_c_try_cpp "$LINENO"; then :
6121 else
6122 # Broken: fails on valid input.
6123 continue
6125 rm -f conftest.err conftest.$ac_ext
6127 # OK, works on sane cases. Now check whether nonexistent headers
6128 # can be detected and how.
6129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6130 /* end confdefs.h. */
6131 #include <ac_nonexistent.h>
6132 _ACEOF
6133 if ac_fn_c_try_cpp "$LINENO"; then :
6134 # Broken: success on invalid input.
6135 continue
6136 else
6137 # Passes both tests.
6138 ac_preproc_ok=:
6139 break
6141 rm -f conftest.err conftest.$ac_ext
6143 done
6144 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6145 rm -f conftest.err conftest.$ac_ext
6146 if $ac_preproc_ok; then :
6148 else
6149 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6150 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6151 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6152 See \`config.log' for more details." "$LINENO" 5; }
6155 ac_ext=c
6156 ac_cpp='$CPP $CPPFLAGS'
6157 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6158 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6159 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6163 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6164 if test "${ac_cv_path_GREP+set}" = set; then :
6165 $as_echo_n "(cached) " >&6
6166 else
6167 if test -z "$GREP"; then
6168 ac_path_GREP_found=false
6169 # Loop through the user's path and test for each of PROGNAME-LIST
6170 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6171 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6173 IFS=$as_save_IFS
6174 test -z "$as_dir" && as_dir=.
6175 for ac_prog in grep ggrep; do
6176 for ac_exec_ext in '' $ac_executable_extensions; do
6177 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6178 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6179 # Check for GNU ac_path_GREP and select it if it is found.
6180 # Check for GNU $ac_path_GREP
6181 case `"$ac_path_GREP" --version 2>&1` in
6182 *GNU*)
6183 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6185 ac_count=0
6186 $as_echo_n 0123456789 >"conftest.in"
6187 while :
6189 cat "conftest.in" "conftest.in" >"conftest.tmp"
6190 mv "conftest.tmp" "conftest.in"
6191 cp "conftest.in" "conftest.nl"
6192 $as_echo 'GREP' >> "conftest.nl"
6193 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6194 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6195 as_fn_arith $ac_count + 1 && ac_count=$as_val
6196 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6197 # Best one so far, save it but keep looking for a better one
6198 ac_cv_path_GREP="$ac_path_GREP"
6199 ac_path_GREP_max=$ac_count
6201 # 10*(2^10) chars as input seems more than enough
6202 test $ac_count -gt 10 && break
6203 done
6204 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6205 esac
6207 $ac_path_GREP_found && break 3
6208 done
6209 done
6210 done
6211 IFS=$as_save_IFS
6212 if test -z "$ac_cv_path_GREP"; then
6213 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6215 else
6216 ac_cv_path_GREP=$GREP
6220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6221 $as_echo "$ac_cv_path_GREP" >&6; }
6222 GREP="$ac_cv_path_GREP"
6225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6226 $as_echo_n "checking for egrep... " >&6; }
6227 if test "${ac_cv_path_EGREP+set}" = set; then :
6228 $as_echo_n "(cached) " >&6
6229 else
6230 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6231 then ac_cv_path_EGREP="$GREP -E"
6232 else
6233 if test -z "$EGREP"; then
6234 ac_path_EGREP_found=false
6235 # Loop through the user's path and test for each of PROGNAME-LIST
6236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6237 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6239 IFS=$as_save_IFS
6240 test -z "$as_dir" && as_dir=.
6241 for ac_prog in egrep; do
6242 for ac_exec_ext in '' $ac_executable_extensions; do
6243 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6244 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6245 # Check for GNU ac_path_EGREP and select it if it is found.
6246 # Check for GNU $ac_path_EGREP
6247 case `"$ac_path_EGREP" --version 2>&1` in
6248 *GNU*)
6249 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6251 ac_count=0
6252 $as_echo_n 0123456789 >"conftest.in"
6253 while :
6255 cat "conftest.in" "conftest.in" >"conftest.tmp"
6256 mv "conftest.tmp" "conftest.in"
6257 cp "conftest.in" "conftest.nl"
6258 $as_echo 'EGREP' >> "conftest.nl"
6259 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6260 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6261 as_fn_arith $ac_count + 1 && ac_count=$as_val
6262 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6263 # Best one so far, save it but keep looking for a better one
6264 ac_cv_path_EGREP="$ac_path_EGREP"
6265 ac_path_EGREP_max=$ac_count
6267 # 10*(2^10) chars as input seems more than enough
6268 test $ac_count -gt 10 && break
6269 done
6270 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6271 esac
6273 $ac_path_EGREP_found && break 3
6274 done
6275 done
6276 done
6277 IFS=$as_save_IFS
6278 if test -z "$ac_cv_path_EGREP"; then
6279 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6281 else
6282 ac_cv_path_EGREP=$EGREP
6287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6288 $as_echo "$ac_cv_path_EGREP" >&6; }
6289 EGREP="$ac_cv_path_EGREP"
6294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6295 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6296 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6297 $as_echo_n "(cached) " >&6
6298 else
6300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6301 /* end confdefs.h. */
6303 #ifdef __ACK__
6304 Amsterdam
6305 #endif
6307 _ACEOF
6308 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6309 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6310 gl_cv_c_amsterdam_compiler=yes
6311 else
6312 gl_cv_c_amsterdam_compiler=no
6314 rm -f conftest*
6318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6319 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6320 if test -z "$AR"; then
6321 if test $gl_cv_c_amsterdam_compiler = yes; then
6322 AR='cc -c.a'
6323 if test -z "$ARFLAGS"; then
6324 ARFLAGS='-o'
6326 else
6327 if test -n "$ac_tool_prefix"; then
6328 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6329 set dummy ${ac_tool_prefix}ar; ac_word=$2
6330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6331 $as_echo_n "checking for $ac_word... " >&6; }
6332 if test "${ac_cv_prog_AR+set}" = set; then :
6333 $as_echo_n "(cached) " >&6
6334 else
6335 if test -n "$AR"; then
6336 ac_cv_prog_AR="$AR" # Let the user override the test.
6337 else
6338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6339 for as_dir in $PATH
6341 IFS=$as_save_IFS
6342 test -z "$as_dir" && as_dir=.
6343 for ac_exec_ext in '' $ac_executable_extensions; do
6344 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6345 ac_cv_prog_AR="${ac_tool_prefix}ar"
6346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6347 break 2
6349 done
6350 done
6351 IFS=$as_save_IFS
6355 AR=$ac_cv_prog_AR
6356 if test -n "$AR"; then
6357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6358 $as_echo "$AR" >&6; }
6359 else
6360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6361 $as_echo "no" >&6; }
6366 if test -z "$ac_cv_prog_AR"; then
6367 ac_ct_AR=$AR
6368 # Extract the first word of "ar", so it can be a program name with args.
6369 set dummy ar; ac_word=$2
6370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6371 $as_echo_n "checking for $ac_word... " >&6; }
6372 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6373 $as_echo_n "(cached) " >&6
6374 else
6375 if test -n "$ac_ct_AR"; then
6376 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6377 else
6378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6379 for as_dir in $PATH
6381 IFS=$as_save_IFS
6382 test -z "$as_dir" && as_dir=.
6383 for ac_exec_ext in '' $ac_executable_extensions; do
6384 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6385 ac_cv_prog_ac_ct_AR="ar"
6386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6387 break 2
6389 done
6390 done
6391 IFS=$as_save_IFS
6395 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6396 if test -n "$ac_ct_AR"; then
6397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6398 $as_echo "$ac_ct_AR" >&6; }
6399 else
6400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6401 $as_echo "no" >&6; }
6404 if test "x$ac_ct_AR" = x; then
6405 AR="ar"
6406 else
6407 case $cross_compiling:$ac_tool_warned in
6408 yes:)
6409 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6410 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6411 ac_tool_warned=yes ;;
6412 esac
6413 AR=$ac_ct_AR
6415 else
6416 AR="$ac_cv_prog_AR"
6419 if test -z "$ARFLAGS"; then
6420 ARFLAGS='cru'
6423 else
6424 if test -z "$ARFLAGS"; then
6425 ARFLAGS='cru'
6430 if test -z "$RANLIB"; then
6431 if test $gl_cv_c_amsterdam_compiler = yes; then
6432 RANLIB=':'
6433 else
6434 if test -n "$ac_tool_prefix"; then
6435 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6436 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6438 $as_echo_n "checking for $ac_word... " >&6; }
6439 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6440 $as_echo_n "(cached) " >&6
6441 else
6442 if test -n "$RANLIB"; then
6443 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6444 else
6445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6446 for as_dir in $PATH
6448 IFS=$as_save_IFS
6449 test -z "$as_dir" && as_dir=.
6450 for ac_exec_ext in '' $ac_executable_extensions; do
6451 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6452 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6454 break 2
6456 done
6457 done
6458 IFS=$as_save_IFS
6462 RANLIB=$ac_cv_prog_RANLIB
6463 if test -n "$RANLIB"; then
6464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6465 $as_echo "$RANLIB" >&6; }
6466 else
6467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6468 $as_echo "no" >&6; }
6473 if test -z "$ac_cv_prog_RANLIB"; then
6474 ac_ct_RANLIB=$RANLIB
6475 # Extract the first word of "ranlib", so it can be a program name with args.
6476 set dummy ranlib; ac_word=$2
6477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6478 $as_echo_n "checking for $ac_word... " >&6; }
6479 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6480 $as_echo_n "(cached) " >&6
6481 else
6482 if test -n "$ac_ct_RANLIB"; then
6483 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6484 else
6485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6486 for as_dir in $PATH
6488 IFS=$as_save_IFS
6489 test -z "$as_dir" && as_dir=.
6490 for ac_exec_ext in '' $ac_executable_extensions; do
6491 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6492 ac_cv_prog_ac_ct_RANLIB="ranlib"
6493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6494 break 2
6496 done
6497 done
6498 IFS=$as_save_IFS
6502 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6503 if test -n "$ac_ct_RANLIB"; then
6504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6505 $as_echo "$ac_ct_RANLIB" >&6; }
6506 else
6507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6508 $as_echo "no" >&6; }
6511 if test "x$ac_ct_RANLIB" = x; then
6512 RANLIB=":"
6513 else
6514 case $cross_compiling:$ac_tool_warned in
6515 yes:)
6516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6517 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6518 ac_tool_warned=yes ;;
6519 esac
6520 RANLIB=$ac_ct_RANLIB
6522 else
6523 RANLIB="$ac_cv_prog_RANLIB"
6530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6531 $as_echo_n "checking for ANSI C header files... " >&6; }
6532 if test "${ac_cv_header_stdc+set}" = set; then :
6533 $as_echo_n "(cached) " >&6
6534 else
6535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6536 /* end confdefs.h. */
6537 #include <stdlib.h>
6538 #include <stdarg.h>
6539 #include <string.h>
6540 #include <float.h>
6543 main ()
6547 return 0;
6549 _ACEOF
6550 if ac_fn_c_try_compile "$LINENO"; then :
6551 ac_cv_header_stdc=yes
6552 else
6553 ac_cv_header_stdc=no
6555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6557 if test $ac_cv_header_stdc = yes; then
6558 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6560 /* end confdefs.h. */
6561 #include <string.h>
6563 _ACEOF
6564 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6565 $EGREP "memchr" >/dev/null 2>&1; then :
6567 else
6568 ac_cv_header_stdc=no
6570 rm -f conftest*
6574 if test $ac_cv_header_stdc = yes; then
6575 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6577 /* end confdefs.h. */
6578 #include <stdlib.h>
6580 _ACEOF
6581 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6582 $EGREP "free" >/dev/null 2>&1; then :
6584 else
6585 ac_cv_header_stdc=no
6587 rm -f conftest*
6591 if test $ac_cv_header_stdc = yes; then
6592 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6593 if test "$cross_compiling" = yes; then :
6595 else
6596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6597 /* end confdefs.h. */
6598 #include <ctype.h>
6599 #include <stdlib.h>
6600 #if ((' ' & 0x0FF) == 0x020)
6601 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6602 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6603 #else
6604 # define ISLOWER(c) \
6605 (('a' <= (c) && (c) <= 'i') \
6606 || ('j' <= (c) && (c) <= 'r') \
6607 || ('s' <= (c) && (c) <= 'z'))
6608 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6609 #endif
6611 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6613 main ()
6615 int i;
6616 for (i = 0; i < 256; i++)
6617 if (XOR (islower (i), ISLOWER (i))
6618 || toupper (i) != TOUPPER (i))
6619 return 2;
6620 return 0;
6622 _ACEOF
6623 if ac_fn_c_try_run "$LINENO"; then :
6625 else
6626 ac_cv_header_stdc=no
6628 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6629 conftest.$ac_objext conftest.beam conftest.$ac_ext
6634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6635 $as_echo "$ac_cv_header_stdc" >&6; }
6636 if test $ac_cv_header_stdc = yes; then
6638 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6642 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6643 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6644 inttypes.h stdint.h unistd.h
6645 do :
6646 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6647 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6649 eval as_val=\$$as_ac_Header
6650 if test "x$as_val" = x""yes; then :
6651 cat >>confdefs.h <<_ACEOF
6652 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6653 _ACEOF
6657 done
6661 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6662 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6663 MINIX=yes
6664 else
6665 MINIX=
6669 if test "$MINIX" = yes; then
6671 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6674 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6677 $as_echo "#define _MINIX 1" >>confdefs.h
6680 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6686 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6687 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6688 $as_echo_n "(cached) " >&6
6689 else
6690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6691 /* end confdefs.h. */
6693 # define __EXTENSIONS__ 1
6694 $ac_includes_default
6696 main ()
6700 return 0;
6702 _ACEOF
6703 if ac_fn_c_try_compile "$LINENO"; then :
6704 ac_cv_safe_to_define___extensions__=yes
6705 else
6706 ac_cv_safe_to_define___extensions__=no
6708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6711 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6712 test $ac_cv_safe_to_define___extensions__ = yes &&
6713 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6715 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6717 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6719 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6721 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6723 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6726 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6727 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6728 $as_echo_n "(cached) " >&6
6729 else
6730 ac_cv_should_define__xopen_source=no
6731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6732 /* end confdefs.h. */
6734 #include <wchar.h>
6735 mbstate_t x;
6737 main ()
6741 return 0;
6743 _ACEOF
6744 if ac_fn_c_try_compile "$LINENO"; then :
6746 else
6747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6748 /* end confdefs.h. */
6750 #define _XOPEN_SOURCE 500
6751 #include <wchar.h>
6752 mbstate_t x;
6754 main ()
6758 return 0;
6760 _ACEOF
6761 if ac_fn_c_try_compile "$LINENO"; then :
6762 ac_cv_should_define__xopen_source=yes
6764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6766 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6769 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6770 test $ac_cv_should_define__xopen_source = yes &&
6771 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6780 # Check whether --enable-largefile was given.
6781 if test "${enable_largefile+set}" = set; then :
6782 enableval=$enable_largefile;
6785 if test "$enable_largefile" != no; then
6787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6788 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6789 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6790 $as_echo_n "(cached) " >&6
6791 else
6792 ac_cv_sys_largefile_CC=no
6793 if test "$GCC" != yes; then
6794 ac_save_CC=$CC
6795 while :; do
6796 # IRIX 6.2 and later do not support large files by default,
6797 # so use the C compiler's -n32 option if that helps.
6798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6799 /* end confdefs.h. */
6800 #include <sys/types.h>
6801 /* Check that off_t can represent 2**63 - 1 correctly.
6802 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6803 since some C++ compilers masquerading as C compilers
6804 incorrectly reject 9223372036854775807. */
6805 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6806 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6807 && LARGE_OFF_T % 2147483647 == 1)
6808 ? 1 : -1];
6810 main ()
6814 return 0;
6816 _ACEOF
6817 if ac_fn_c_try_compile "$LINENO"; then :
6818 break
6820 rm -f core conftest.err conftest.$ac_objext
6821 CC="$CC -n32"
6822 if ac_fn_c_try_compile "$LINENO"; then :
6823 ac_cv_sys_largefile_CC=' -n32'; break
6825 rm -f core conftest.err conftest.$ac_objext
6826 break
6827 done
6828 CC=$ac_save_CC
6829 rm -f conftest.$ac_ext
6832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6833 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6834 if test "$ac_cv_sys_largefile_CC" != no; then
6835 CC=$CC$ac_cv_sys_largefile_CC
6838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6839 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6840 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6841 $as_echo_n "(cached) " >&6
6842 else
6843 while :; do
6844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6845 /* end confdefs.h. */
6846 #include <sys/types.h>
6847 /* Check that off_t can represent 2**63 - 1 correctly.
6848 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6849 since some C++ compilers masquerading as C compilers
6850 incorrectly reject 9223372036854775807. */
6851 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6852 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6853 && LARGE_OFF_T % 2147483647 == 1)
6854 ? 1 : -1];
6856 main ()
6860 return 0;
6862 _ACEOF
6863 if ac_fn_c_try_compile "$LINENO"; then :
6864 ac_cv_sys_file_offset_bits=no; break
6866 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6868 /* end confdefs.h. */
6869 #define _FILE_OFFSET_BITS 64
6870 #include <sys/types.h>
6871 /* Check that off_t can represent 2**63 - 1 correctly.
6872 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6873 since some C++ compilers masquerading as C compilers
6874 incorrectly reject 9223372036854775807. */
6875 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6876 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6877 && LARGE_OFF_T % 2147483647 == 1)
6878 ? 1 : -1];
6880 main ()
6884 return 0;
6886 _ACEOF
6887 if ac_fn_c_try_compile "$LINENO"; then :
6888 ac_cv_sys_file_offset_bits=64; break
6890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6891 ac_cv_sys_file_offset_bits=unknown
6892 break
6893 done
6895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6896 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6897 case $ac_cv_sys_file_offset_bits in #(
6898 no | unknown) ;;
6900 cat >>confdefs.h <<_ACEOF
6901 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6902 _ACEOF
6904 esac
6905 rm -rf conftest*
6906 if test $ac_cv_sys_file_offset_bits = unknown; then
6907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6908 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6909 if test "${ac_cv_sys_large_files+set}" = set; then :
6910 $as_echo_n "(cached) " >&6
6911 else
6912 while :; do
6913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6914 /* end confdefs.h. */
6915 #include <sys/types.h>
6916 /* Check that off_t can represent 2**63 - 1 correctly.
6917 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6918 since some C++ compilers masquerading as C compilers
6919 incorrectly reject 9223372036854775807. */
6920 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6921 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6922 && LARGE_OFF_T % 2147483647 == 1)
6923 ? 1 : -1];
6925 main ()
6929 return 0;
6931 _ACEOF
6932 if ac_fn_c_try_compile "$LINENO"; then :
6933 ac_cv_sys_large_files=no; break
6935 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6937 /* end confdefs.h. */
6938 #define _LARGE_FILES 1
6939 #include <sys/types.h>
6940 /* Check that off_t can represent 2**63 - 1 correctly.
6941 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6942 since some C++ compilers masquerading as C compilers
6943 incorrectly reject 9223372036854775807. */
6944 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6945 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6946 && LARGE_OFF_T % 2147483647 == 1)
6947 ? 1 : -1];
6949 main ()
6953 return 0;
6955 _ACEOF
6956 if ac_fn_c_try_compile "$LINENO"; then :
6957 ac_cv_sys_large_files=1; break
6959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6960 ac_cv_sys_large_files=unknown
6961 break
6962 done
6964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6965 $as_echo "$ac_cv_sys_large_files" >&6; }
6966 case $ac_cv_sys_large_files in #(
6967 no | unknown) ;;
6969 cat >>confdefs.h <<_ACEOF
6970 #define _LARGE_FILES $ac_cv_sys_large_files
6971 _ACEOF
6973 esac
6974 rm -rf conftest*
6978 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6982 case $ac_cv_prog_cc_stdc in #(
6983 no) :
6984 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6985 *) :
6986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6987 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6988 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6989 $as_echo_n "(cached) " >&6
6990 else
6991 ac_cv_prog_cc_c99=no
6992 ac_save_CC=$CC
6993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6994 /* end confdefs.h. */
6995 #include <stdarg.h>
6996 #include <stdbool.h>
6997 #include <stdlib.h>
6998 #include <wchar.h>
6999 #include <stdio.h>
7001 // Check varargs macros. These examples are taken from C99 6.10.3.5.
7002 #define debug(...) fprintf (stderr, __VA_ARGS__)
7003 #define showlist(...) puts (#__VA_ARGS__)
7004 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
7005 static void
7006 test_varargs_macros (void)
7008 int x = 1234;
7009 int y = 5678;
7010 debug ("Flag");
7011 debug ("X = %d\n", x);
7012 showlist (The first, second, and third items.);
7013 report (x>y, "x is %d but y is %d", x, y);
7016 // Check long long types.
7017 #define BIG64 18446744073709551615ull
7018 #define BIG32 4294967295ul
7019 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
7020 #if !BIG_OK
7021 your preprocessor is broken;
7022 #endif
7023 #if BIG_OK
7024 #else
7025 your preprocessor is broken;
7026 #endif
7027 static long long int bignum = -9223372036854775807LL;
7028 static unsigned long long int ubignum = BIG64;
7030 struct incomplete_array
7032 int datasize;
7033 double data[];
7036 struct named_init {
7037 int number;
7038 const wchar_t *name;
7039 double average;
7042 typedef const char *ccp;
7044 static inline int
7045 test_restrict (ccp restrict text)
7047 // See if C++-style comments work.
7048 // Iterate through items via the restricted pointer.
7049 // Also check for declarations in for loops.
7050 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7051 continue;
7052 return 0;
7055 // Check varargs and va_copy.
7056 static void
7057 test_varargs (const char *format, ...)
7059 va_list args;
7060 va_start (args, format);
7061 va_list args_copy;
7062 va_copy (args_copy, args);
7064 const char *str;
7065 int number;
7066 float fnumber;
7068 while (*format)
7070 switch (*format++)
7072 case 's': // string
7073 str = va_arg (args_copy, const char *);
7074 break;
7075 case 'd': // int
7076 number = va_arg (args_copy, int);
7077 break;
7078 case 'f': // float
7079 fnumber = va_arg (args_copy, double);
7080 break;
7081 default:
7082 break;
7085 va_end (args_copy);
7086 va_end (args);
7090 main ()
7093 // Check bool.
7094 _Bool success = false;
7096 // Check restrict.
7097 if (test_restrict ("String literal") == 0)
7098 success = true;
7099 char *restrict newvar = "Another string";
7101 // Check varargs.
7102 test_varargs ("s, d' f .", "string", 65, 34.234);
7103 test_varargs_macros ();
7105 // Check flexible array members.
7106 struct incomplete_array *ia =
7107 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7108 ia->datasize = 10;
7109 for (int i = 0; i < ia->datasize; ++i)
7110 ia->data[i] = i * 1.234;
7112 // Check named initializers.
7113 struct named_init ni = {
7114 .number = 34,
7115 .name = L"Test wide string",
7116 .average = 543.34343,
7119 ni.number = 58;
7121 int dynamic_array[ni.number];
7122 dynamic_array[ni.number - 1] = 543;
7124 // work around unused variable warnings
7125 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7126 || dynamic_array[ni.number - 1] != 543);
7129 return 0;
7131 _ACEOF
7132 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7134 CC="$ac_save_CC $ac_arg"
7135 if ac_fn_c_try_compile "$LINENO"; then :
7136 ac_cv_prog_cc_c99=$ac_arg
7138 rm -f core conftest.err conftest.$ac_objext
7139 test "x$ac_cv_prog_cc_c99" != "xno" && break
7140 done
7141 rm -f conftest.$ac_ext
7142 CC=$ac_save_CC
7145 # AC_CACHE_VAL
7146 case "x$ac_cv_prog_cc_c99" in
7148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7149 $as_echo "none needed" >&6; } ;;
7150 xno)
7151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7152 $as_echo "unsupported" >&6; } ;;
7154 CC="$CC $ac_cv_prog_cc_c99"
7155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7156 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7157 esac
7158 if test "x$ac_cv_prog_cc_c99" != xno; then :
7159 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7160 else
7161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7162 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7163 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7164 $as_echo_n "(cached) " >&6
7165 else
7166 ac_cv_prog_cc_c89=no
7167 ac_save_CC=$CC
7168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7169 /* end confdefs.h. */
7170 #include <stdarg.h>
7171 #include <stdio.h>
7172 #include <sys/types.h>
7173 #include <sys/stat.h>
7174 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7175 struct buf { int x; };
7176 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7177 static char *e (p, i)
7178 char **p;
7179 int i;
7181 return p[i];
7183 static char *f (char * (*g) (char **, int), char **p, ...)
7185 char *s;
7186 va_list v;
7187 va_start (v,p);
7188 s = g (p, va_arg (v,int));
7189 va_end (v);
7190 return s;
7193 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7194 function prototypes and stuff, but not '\xHH' hex character constants.
7195 These don't provoke an error unfortunately, instead are silently treated
7196 as 'x'. The following induces an error, until -std is added to get
7197 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7198 array size at least. It's necessary to write '\x00'==0 to get something
7199 that's true only with -std. */
7200 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7202 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7203 inside strings and character constants. */
7204 #define FOO(x) 'x'
7205 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7207 int test (int i, double x);
7208 struct s1 {int (*f) (int a);};
7209 struct s2 {int (*f) (double a);};
7210 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7211 int argc;
7212 char **argv;
7214 main ()
7216 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7218 return 0;
7220 _ACEOF
7221 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7222 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7224 CC="$ac_save_CC $ac_arg"
7225 if ac_fn_c_try_compile "$LINENO"; then :
7226 ac_cv_prog_cc_c89=$ac_arg
7228 rm -f core conftest.err conftest.$ac_objext
7229 test "x$ac_cv_prog_cc_c89" != "xno" && break
7230 done
7231 rm -f conftest.$ac_ext
7232 CC=$ac_save_CC
7235 # AC_CACHE_VAL
7236 case "x$ac_cv_prog_cc_c89" in
7238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7239 $as_echo "none needed" >&6; } ;;
7240 xno)
7241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7242 $as_echo "unsupported" >&6; } ;;
7244 CC="$CC $ac_cv_prog_cc_c89"
7245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7246 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7247 esac
7248 if test "x$ac_cv_prog_cc_c89" != xno; then :
7249 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7250 else
7251 ac_cv_prog_cc_stdc=no
7256 esac
7257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7258 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7259 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7260 $as_echo_n "(cached) " >&6
7263 case $ac_cv_prog_cc_stdc in #(
7264 no) :
7265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7266 $as_echo "unsupported" >&6; } ;; #(
7267 '') :
7268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7269 $as_echo "none needed" >&6; } ;; #(
7270 *) :
7271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7272 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7273 esac
7277 # Code from module alloca-opt:
7278 # Code from module allocator:
7279 # Code from module at-internal:
7280 # Code from module binary-io:
7281 # Code from module c-ctype:
7282 # Code from module c-strcase:
7283 # Code from module careadlinkat:
7284 # Code from module clock-time:
7285 # Code from module close-stream:
7286 # Code from module crypto/md5:
7287 # Code from module crypto/sha1:
7288 # Code from module crypto/sha256:
7289 # Code from module crypto/sha512:
7290 # Code from module dirent:
7291 # Code from module dosname:
7292 # Code from module dtoastr:
7293 # Code from module dtotimespec:
7294 # Code from module dup2:
7295 # Code from module environ:
7296 # Code from module errno:
7297 # Code from module euidaccess:
7298 # Code from module execinfo:
7299 # Code from module extensions:
7301 # Code from module extern-inline:
7302 # Code from module faccessat:
7303 # Code from module fcntl:
7304 # Code from module fcntl-h:
7305 # Code from module fdatasync:
7306 # Code from module fdopendir:
7307 # Code from module filemode:
7308 # Code from module fpending:
7309 # Code from module fstatat:
7310 # Code from module fsync:
7311 # Code from module getdtablesize:
7312 # Code from module getgroups:
7313 # Code from module getloadavg:
7314 # Code from module getopt-gnu:
7315 # Code from module getopt-posix:
7316 # Code from module gettext-h:
7317 # Code from module gettime:
7318 # Code from module gettimeofday:
7319 # Code from module group-member:
7320 # Code from module include_next:
7321 # Code from module intprops:
7322 # Code from module inttypes-incomplete:
7323 # Code from module largefile:
7325 # Code from module lstat:
7326 # Code from module manywarnings:
7327 # Code from module memrchr:
7328 # Code from module mkostemp:
7329 # Code from module mktime:
7330 # Code from module multiarch:
7331 # Code from module nocrash:
7332 # Code from module openat-h:
7333 # Code from module pathmax:
7334 # Code from module pipe2:
7335 # Code from module pselect:
7336 # Code from module pthread_sigmask:
7337 # Code from module putenv:
7338 # Code from module qacl:
7339 # Code from module readlink:
7340 # Code from module readlinkat:
7341 # Code from module root-uid:
7342 # Code from module secure_getenv:
7343 # Code from module sig2str:
7344 # Code from module signal-h:
7345 # Code from module snippet/_Noreturn:
7346 # Code from module snippet/arg-nonnull:
7347 # Code from module snippet/c++defs:
7348 # Code from module snippet/warn-on-use:
7349 # Code from module socklen:
7350 # Code from module ssize_t:
7351 # Code from module stat:
7352 # Code from module stat-time:
7353 # Code from module stdalign:
7354 # Code from module stdarg:
7358 # Code from module stdbool:
7359 # Code from module stddef:
7360 # Code from module stdint:
7361 # Code from module stdio:
7362 # Code from module stdlib:
7363 # Code from module strftime:
7364 # Code from module string:
7365 # Code from module strtoimax:
7366 # Code from module strtoll:
7367 # Code from module strtoull:
7368 # Code from module strtoumax:
7369 # Code from module symlink:
7370 # Code from module sys_select:
7371 # Code from module sys_stat:
7372 # Code from module sys_time:
7373 # Code from module tempname:
7374 # Code from module time:
7375 # Code from module time_r:
7376 # Code from module timer-time:
7377 # Code from module timespec:
7378 # Code from module timespec-add:
7379 # Code from module timespec-sub:
7380 # Code from module u64:
7381 # Code from module unistd:
7382 # Code from module unsetenv:
7383 # Code from module utimens:
7384 # Code from module verify:
7385 # Code from module warnings:
7386 # Code from module xalloc-oversized:
7389 if test "$ac_test_CFLAGS" != set; then
7390 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7391 # if -g3 works and the user does not specify CFLAGS.
7392 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7393 case $CFLAGS in
7394 '-g')
7395 emacs_g3_CFLAGS='-g3';;
7396 '-g -O2')
7397 emacs_g3_CFLAGS='-g3 -O2';;
7399 emacs_g3_CFLAGS='';;
7400 esac
7401 if test -n "$emacs_g3_CFLAGS"; then
7402 emacs_save_CFLAGS=$CFLAGS
7403 CFLAGS=$emacs_g3_CFLAGS
7404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7405 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7406 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7407 $as_echo_n "(cached) " >&6
7408 else
7409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7410 /* end confdefs.h. */
7413 main ()
7417 return 0;
7419 _ACEOF
7420 if ac_fn_c_try_link "$LINENO"; then :
7421 emacs_cv_prog_cc_g3=yes
7422 else
7423 emacs_cv_prog_cc_g3=no
7425 rm -f core conftest.err conftest.$ac_objext \
7426 conftest$ac_exeext conftest.$ac_ext
7428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7429 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7430 if test $emacs_cv_prog_cc_g3 != yes; then
7431 CFLAGS=$emacs_save_CFLAGS
7433 if test $opsys = mingw32; then
7434 CFLAGS="$CFLAGS -gdwarf-2"
7438 case $CFLAGS in
7439 *-O*) ;;
7441 # No optimization flag was inferred for this non-GCC compiler.
7442 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7443 emacs_save_CFLAGS=$CFLAGS
7444 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7445 CFLAGS=${CFLAGS}-O
7446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7447 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7448 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7449 $as_echo_n "(cached) " >&6
7450 else
7451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7452 /* end confdefs.h. */
7455 main ()
7459 return 0;
7461 _ACEOF
7462 if ac_fn_c_try_link "$LINENO"; then :
7463 emacs_cv_prog_cc_o=yes
7464 else
7465 emacs_cv_prog_cc_o=no
7467 rm -f core conftest.err conftest.$ac_objext \
7468 conftest$ac_exeext conftest.$ac_ext
7470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7471 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7472 if test $emacs_cv_prog_cc_o != yes; then
7473 CFLAGS=$emacs_save_CFLAGS
7474 fi ;;
7475 esac
7478 # Check whether --enable-gcc-warnings was given.
7479 if test "${enable_gcc_warnings+set}" = set; then :
7480 enableval=$enable_gcc_warnings; case $enableval in
7481 yes|no) ;;
7482 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7483 esac
7484 gl_gcc_warnings=$enableval
7485 else
7486 gl_gcc_warnings=no
7491 # Check whether --enable-link-time-optimization was given.
7492 if test "${enable_link_time_optimization+set}" = set; then :
7493 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7495 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7496 ac_lto_supported=no
7497 if test x$GCC = xyes; then
7498 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7499 if test x$CPUS != x; then
7500 LTO="-flto=$CPUS"
7501 else
7502 LTO="-flto"
7504 old_CFLAGS=$CFLAGS
7505 CFLAGS="$CFLAGS $LTO"
7506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7507 /* end confdefs.h. */
7510 main ()
7514 return 0;
7516 _ACEOF
7517 if ac_fn_c_try_compile "$LINENO"; then :
7518 ac_lto_supported=yes
7519 else
7520 ac_lto_supported=no
7522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7523 CFLAGS="$old_CFLAGS"
7525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7526 $as_echo "$ac_lto_supported" >&6; }
7527 if test "$ac_lto_supported" = "yes"; then
7528 CFLAGS="$CFLAGS $LTO"
7534 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7535 # ------------------------------------------------
7536 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7537 # Otherwise, run RUN-IF-NOT-FOUND.
7540 # When compiling with GCC, prefer -isystem to -I when including system
7541 # include files, to avoid generating useless diagnostics for the files.
7542 if test "$gl_gcc_warnings" != yes; then
7543 isystem='-I'
7544 else
7545 isystem='-isystem '
7547 # This, $nw, is the list of warnings we disable.
7550 case $with_x_toolkit in
7551 lucid | athena | motif)
7552 # Old toolkits mishandle 'const'.
7553 nw="$nw -Wwrite-strings"
7556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7557 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7558 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7559 $as_echo_n "(cached) " >&6
7560 else
7562 gl_save_compiler_FLAGS="$CFLAGS"
7563 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7565 /* end confdefs.h. */
7568 main ()
7572 return 0;
7574 _ACEOF
7575 if ac_fn_c_try_compile "$LINENO"; then :
7576 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7577 else
7578 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7581 CFLAGS="$gl_save_compiler_FLAGS"
7584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7585 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7586 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7587 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7588 else
7589 gl_unknown_warnings_are_errors=
7593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7594 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7595 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7596 $as_echo_n "(cached) " >&6
7597 else
7599 gl_save_compiler_FLAGS="$CFLAGS"
7600 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7602 /* end confdefs.h. */
7605 main ()
7609 return 0;
7611 _ACEOF
7612 if ac_fn_c_try_compile "$LINENO"; then :
7613 gl_cv_warn_c__Werror=yes
7614 else
7615 gl_cv_warn_c__Werror=no
7617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7618 CFLAGS="$gl_save_compiler_FLAGS"
7621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7622 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7623 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7624 as_fn_append WERROR_CFLAGS " -Werror"
7629 esac
7632 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7633 nw="$nw -Woverlength-strings" # Not a problem these days
7634 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7635 nw="$nw -Wformat-nonliteral" # we do this a lot
7636 nw="$nw -Wvla" # warnings in gettext.h
7637 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7638 nw="$nw -Wswitch-default" # Too many warnings for now
7639 nw="$nw -Winline" # OK to ignore 'inline'
7640 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7641 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7642 # signed overflow has undefined behavior
7643 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7644 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7645 nw="$nw -Wbad-function-cast" # These casts are no worse than others.
7647 # Emacs doesn't care about shadowing; see
7648 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7649 nw="$nw -Wshadow"
7651 # Emacs's use of alloca inhibits protecting the stack.
7652 nw="$nw -Wstack-protector"
7654 # The following line should be removable at some point.
7655 nw="$nw -Wsuggest-attribute=pure"
7657 # clang is unduly picky about some things.
7658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7659 $as_echo_n "checking whether the compiler is clang... " >&6; }
7660 if test "${emacs_cv_clang+set}" = set; then :
7661 $as_echo_n "(cached) " >&6
7662 else
7663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7664 /* end confdefs.h. */
7666 #ifndef __clang__
7667 #error "not clang"
7668 #endif
7671 main ()
7675 return 0;
7677 _ACEOF
7678 if ac_fn_c_try_compile "$LINENO"; then :
7679 emacs_cv_clang=yes
7680 else
7681 emacs_cv_clang=no
7683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7686 $as_echo "$emacs_cv_clang" >&6; }
7687 if test $emacs_cv_clang = yes; then
7688 nw="$nw -Wcast-align"
7693 if test -n "$GCC"; then
7695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7696 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7697 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7698 $as_echo_n "(cached) " >&6
7699 else
7701 gl_save_CFLAGS="$CFLAGS"
7702 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7704 /* end confdefs.h. */
7707 main ()
7711 return 0;
7713 _ACEOF
7714 if ac_fn_c_try_compile "$LINENO"; then :
7715 gl_cv_cc_nomfi_supported=yes
7716 else
7717 gl_cv_cc_nomfi_supported=no
7719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7720 CFLAGS="$gl_save_CFLAGS"
7723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7724 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7726 if test "$gl_cv_cc_nomfi_supported" = yes; then
7727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7728 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7729 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7730 $as_echo_n "(cached) " >&6
7731 else
7733 gl_save_CFLAGS="$CFLAGS"
7734 CFLAGS="$CFLAGS -W -Werror"
7735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7736 /* end confdefs.h. */
7737 void f (void)
7739 typedef struct { int a; int b; } s_t;
7740 s_t s1 = { 0, };
7744 main ()
7748 return 0;
7750 _ACEOF
7751 if ac_fn_c_try_compile "$LINENO"; then :
7752 gl_cv_cc_nomfi_needed=no
7753 else
7754 gl_cv_cc_nomfi_needed=yes
7756 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7757 CFLAGS="$gl_save_CFLAGS"
7761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7762 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7766 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7767 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7768 $as_echo_n "(cached) " >&6
7769 else
7771 gl_save_CFLAGS="$CFLAGS"
7772 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7774 /* end confdefs.h. */
7777 main ()
7781 return 0;
7783 _ACEOF
7784 if ac_fn_c_try_compile "$LINENO"; then :
7785 gl_cv_cc_uninitialized_supported=yes
7786 else
7787 gl_cv_cc_uninitialized_supported=no
7789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7790 CFLAGS="$gl_save_CFLAGS"
7793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7794 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7798 # List all gcc warning categories.
7799 gl_manywarn_set=
7800 for gl_manywarn_item in \
7801 -W \
7802 -Wabi \
7803 -Waddress \
7804 -Waggressive-loop-optimizations \
7805 -Wall \
7806 -Warray-bounds \
7807 -Wattributes \
7808 -Wbad-function-cast \
7809 -Wbuiltin-macro-redefined \
7810 -Wcast-align \
7811 -Wchar-subscripts \
7812 -Wclobbered \
7813 -Wcomment \
7814 -Wcomments \
7815 -Wcoverage-mismatch \
7816 -Wcpp \
7817 -Wdeprecated \
7818 -Wdeprecated-declarations \
7819 -Wdisabled-optimization \
7820 -Wdiv-by-zero \
7821 -Wdouble-promotion \
7822 -Wempty-body \
7823 -Wendif-labels \
7824 -Wenum-compare \
7825 -Wextra \
7826 -Wformat-contains-nul \
7827 -Wformat-extra-args \
7828 -Wformat-nonliteral \
7829 -Wformat-security \
7830 -Wformat-y2k \
7831 -Wformat-zero-length \
7832 -Wfree-nonheap-object \
7833 -Wignored-qualifiers \
7834 -Wimplicit \
7835 -Wimplicit-function-declaration \
7836 -Wimplicit-int \
7837 -Winit-self \
7838 -Winline \
7839 -Wint-to-pointer-cast \
7840 -Winvalid-memory-model \
7841 -Winvalid-pch \
7842 -Wjump-misses-init \
7843 -Wlogical-op \
7844 -Wmain \
7845 -Wmaybe-uninitialized \
7846 -Wmissing-braces \
7847 -Wmissing-declarations \
7848 -Wmissing-field-initializers \
7849 -Wmissing-include-dirs \
7850 -Wmissing-parameter-type \
7851 -Wmissing-prototypes \
7852 -Wmudflap \
7853 -Wmultichar \
7854 -Wnarrowing \
7855 -Wnested-externs \
7856 -Wnonnull \
7857 -Wnormalized=nfc \
7858 -Wold-style-declaration \
7859 -Wold-style-definition \
7860 -Woverflow \
7861 -Woverlength-strings \
7862 -Woverride-init \
7863 -Wpacked \
7864 -Wpacked-bitfield-compat \
7865 -Wparentheses \
7866 -Wpointer-arith \
7867 -Wpointer-sign \
7868 -Wpointer-to-int-cast \
7869 -Wpragmas \
7870 -Wreturn-local-addr \
7871 -Wreturn-type \
7872 -Wsequence-point \
7873 -Wshadow \
7874 -Wsizeof-pointer-memaccess \
7875 -Wstack-protector \
7876 -Wstrict-aliasing \
7877 -Wstrict-overflow \
7878 -Wstrict-prototypes \
7879 -Wsuggest-attribute=const \
7880 -Wsuggest-attribute=format \
7881 -Wsuggest-attribute=noreturn \
7882 -Wsuggest-attribute=pure \
7883 -Wswitch \
7884 -Wswitch-default \
7885 -Wsync-nand \
7886 -Wsystem-headers \
7887 -Wtrampolines \
7888 -Wtrigraphs \
7889 -Wtype-limits \
7890 -Wuninitialized \
7891 -Wunknown-pragmas \
7892 -Wunsafe-loop-optimizations \
7893 -Wunused \
7894 -Wunused-but-set-parameter \
7895 -Wunused-but-set-variable \
7896 -Wunused-function \
7897 -Wunused-label \
7898 -Wunused-local-typedefs \
7899 -Wunused-macros \
7900 -Wunused-parameter \
7901 -Wunused-result \
7902 -Wunused-value \
7903 -Wunused-variable \
7904 -Wvarargs \
7905 -Wvariadic-macros \
7906 -Wvector-operation-performance \
7907 -Wvla \
7908 -Wvolatile-register-var \
7909 -Wwrite-strings \
7911 ; do
7912 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7913 done
7915 # Disable specific options as needed.
7916 if test "$gl_cv_cc_nomfi_needed" = yes; then
7917 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7920 if test "$gl_cv_cc_uninitialized_supported" = no; then
7921 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7924 ws=$gl_manywarn_set
7927 gl_warn_set=
7928 set x $ws; shift
7929 for gl_warn_item
7931 case " $nw " in
7932 *" $gl_warn_item "*)
7935 gl_warn_set="$gl_warn_set $gl_warn_item"
7937 esac
7938 done
7939 ws=$gl_warn_set
7941 for w in $ws; do
7943 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7944 gl_positive="$w"
7945 case $gl_positive in
7946 -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
7947 esac
7948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7949 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7950 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7951 $as_echo_n "(cached) " >&6
7952 else
7954 gl_save_compiler_FLAGS="$CFLAGS"
7955 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive"
7956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7957 /* end confdefs.h. */
7960 main ()
7964 return 0;
7966 _ACEOF
7967 if ac_fn_c_try_compile "$LINENO"; then :
7968 eval "$as_gl_Warn=yes"
7969 else
7970 eval "$as_gl_Warn=no"
7972 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7973 CFLAGS="$gl_save_compiler_FLAGS"
7976 eval ac_res=\$$as_gl_Warn
7977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7978 $as_echo "$ac_res" >&6; }
7979 eval as_val=\$$as_gl_Warn
7980 if test "x$as_val" = x""yes; then :
7981 as_fn_append WARN_CFLAGS " $w"
7985 done
7987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7988 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7989 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7990 $as_echo_n "(cached) " >&6
7991 else
7993 gl_save_compiler_FLAGS="$CFLAGS"
7994 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wmissing-field-initializers"
7995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7996 /* end confdefs.h. */
7999 main ()
8003 return 0;
8005 _ACEOF
8006 if ac_fn_c_try_compile "$LINENO"; then :
8007 gl_cv_warn_c__Wno_missing_field_initializers=yes
8008 else
8009 gl_cv_warn_c__Wno_missing_field_initializers=no
8011 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8012 CFLAGS="$gl_save_compiler_FLAGS"
8015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
8016 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
8017 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
8018 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
8021 # We need this one
8023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
8024 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
8025 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
8026 $as_echo_n "(cached) " >&6
8027 else
8029 gl_save_compiler_FLAGS="$CFLAGS"
8030 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wsign-compare"
8031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8032 /* end confdefs.h. */
8035 main ()
8039 return 0;
8041 _ACEOF
8042 if ac_fn_c_try_compile "$LINENO"; then :
8043 gl_cv_warn_c__Wno_sign_compare=yes
8044 else
8045 gl_cv_warn_c__Wno_sign_compare=no
8047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8048 CFLAGS="$gl_save_compiler_FLAGS"
8051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
8052 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
8053 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
8054 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
8057 # Too many warnings for now
8059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
8060 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
8061 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8062 $as_echo_n "(cached) " >&6
8063 else
8065 gl_save_compiler_FLAGS="$CFLAGS"
8066 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtype-limits"
8067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8068 /* end confdefs.h. */
8071 main ()
8075 return 0;
8077 _ACEOF
8078 if ac_fn_c_try_compile "$LINENO"; then :
8079 gl_cv_warn_c__Wno_type_limits=yes
8080 else
8081 gl_cv_warn_c__Wno_type_limits=no
8083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8084 CFLAGS="$gl_save_compiler_FLAGS"
8087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8088 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8089 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8090 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8093 # Too many warnings for now
8095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8096 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8097 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8098 $as_echo_n "(cached) " >&6
8099 else
8101 gl_save_compiler_FLAGS="$CFLAGS"
8102 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
8103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8104 /* end confdefs.h. */
8107 main ()
8111 return 0;
8113 _ACEOF
8114 if ac_fn_c_try_compile "$LINENO"; then :
8115 gl_cv_warn_c__Wno_switch=yes
8116 else
8117 gl_cv_warn_c__Wno_switch=no
8119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8120 CFLAGS="$gl_save_compiler_FLAGS"
8123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8124 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8125 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8126 as_fn_append WARN_CFLAGS " -Wno-switch"
8129 # Too many warnings for now
8131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8132 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8133 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8134 $as_echo_n "(cached) " >&6
8135 else
8137 gl_save_compiler_FLAGS="$CFLAGS"
8138 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-parameter"
8139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8140 /* end confdefs.h. */
8143 main ()
8147 return 0;
8149 _ACEOF
8150 if ac_fn_c_try_compile "$LINENO"; then :
8151 gl_cv_warn_c__Wno_unused_parameter=yes
8152 else
8153 gl_cv_warn_c__Wno_unused_parameter=no
8155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8156 CFLAGS="$gl_save_compiler_FLAGS"
8159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8160 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8161 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8162 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8165 # Too many warnings for now
8167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8168 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8169 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8170 $as_echo_n "(cached) " >&6
8171 else
8173 gl_save_compiler_FLAGS="$CFLAGS"
8174 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-nonliteral"
8175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8176 /* end confdefs.h. */
8179 main ()
8183 return 0;
8185 _ACEOF
8186 if ac_fn_c_try_compile "$LINENO"; then :
8187 gl_cv_warn_c__Wno_format_nonliteral=yes
8188 else
8189 gl_cv_warn_c__Wno_format_nonliteral=no
8191 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8192 CFLAGS="$gl_save_compiler_FLAGS"
8195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8196 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8197 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8198 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8203 # In spite of excluding -Wlogical-op above, it is enabled, as of
8204 # gcc 4.5.0 20090517.
8206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8207 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8208 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8209 $as_echo_n "(cached) " >&6
8210 else
8212 gl_save_compiler_FLAGS="$CFLAGS"
8213 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wlogical-op"
8214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8215 /* end confdefs.h. */
8218 main ()
8222 return 0;
8224 _ACEOF
8225 if ac_fn_c_try_compile "$LINENO"; then :
8226 gl_cv_warn_c__Wno_logical_op=yes
8227 else
8228 gl_cv_warn_c__Wno_logical_op=no
8230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8231 CFLAGS="$gl_save_compiler_FLAGS"
8234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8235 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8236 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8237 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8242 # More things that clang is unduly picky about.
8243 if test $emacs_cv_clang = yes; then
8245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8246 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8247 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8248 $as_echo_n "(cached) " >&6
8249 else
8251 gl_save_compiler_FLAGS="$CFLAGS"
8252 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-extra-args"
8253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8254 /* end confdefs.h. */
8257 main ()
8261 return 0;
8263 _ACEOF
8264 if ac_fn_c_try_compile "$LINENO"; then :
8265 gl_cv_warn_c__Wno_format_extra_args=yes
8266 else
8267 gl_cv_warn_c__Wno_format_extra_args=no
8269 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8270 CFLAGS="$gl_save_compiler_FLAGS"
8273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8274 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8275 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8276 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8282 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8283 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8284 $as_echo_n "(cached) " >&6
8285 else
8287 gl_save_compiler_FLAGS="$CFLAGS"
8288 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
8289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8290 /* end confdefs.h. */
8293 main ()
8297 return 0;
8299 _ACEOF
8300 if ac_fn_c_try_compile "$LINENO"; then :
8301 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8302 else
8303 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8306 CFLAGS="$gl_save_compiler_FLAGS"
8309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8310 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8311 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8312 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8318 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8319 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8320 $as_echo_n "(cached) " >&6
8321 else
8323 gl_save_compiler_FLAGS="$CFLAGS"
8324 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-command-line-argument"
8325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8326 /* end confdefs.h. */
8329 main ()
8333 return 0;
8335 _ACEOF
8336 if ac_fn_c_try_compile "$LINENO"; then :
8337 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8338 else
8339 gl_cv_warn_c__Wno_unused_command_line_argument=no
8341 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8342 CFLAGS="$gl_save_compiler_FLAGS"
8345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8346 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8347 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8348 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8354 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8355 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8356 $as_echo_n "(cached) " >&6
8357 else
8359 gl_save_compiler_FLAGS="$CFLAGS"
8360 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-value"
8361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8362 /* end confdefs.h. */
8365 main ()
8369 return 0;
8371 _ACEOF
8372 if ac_fn_c_try_compile "$LINENO"; then :
8373 gl_cv_warn_c__Wno_unused_value=yes
8374 else
8375 gl_cv_warn_c__Wno_unused_value=no
8377 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8378 CFLAGS="$gl_save_compiler_FLAGS"
8381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8382 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8383 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8384 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
8392 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
8393 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
8394 $as_echo_n "(cached) " >&6
8395 else
8397 gl_save_compiler_FLAGS="$CFLAGS"
8398 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
8399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8400 /* end confdefs.h. */
8403 main ()
8407 return 0;
8409 _ACEOF
8410 if ac_fn_c_try_compile "$LINENO"; then :
8411 gl_cv_warn_c__fdiagnostics_show_option=yes
8412 else
8413 gl_cv_warn_c__fdiagnostics_show_option=no
8415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8416 CFLAGS="$gl_save_compiler_FLAGS"
8419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
8420 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
8421 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
8422 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
8427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
8428 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
8429 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
8430 $as_echo_n "(cached) " >&6
8431 else
8433 gl_save_compiler_FLAGS="$CFLAGS"
8434 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
8435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8436 /* end confdefs.h. */
8439 main ()
8443 return 0;
8445 _ACEOF
8446 if ac_fn_c_try_compile "$LINENO"; then :
8447 gl_cv_warn_c__funit_at_a_time=yes
8448 else
8449 gl_cv_warn_c__funit_at_a_time=no
8451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8452 CFLAGS="$gl_save_compiler_FLAGS"
8455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
8456 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
8457 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
8458 as_fn_append WARN_CFLAGS " -funit-at-a-time"
8464 $as_echo "#define lint 1" >>confdefs.h
8468 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8471 # We use a slightly smaller set of warning options for lib/.
8472 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8474 nw="$nw -Wunused-macros"
8477 gl_warn_set=
8478 set x $WARN_CFLAGS; shift
8479 for gl_warn_item
8481 case " $nw " in
8482 *" $gl_warn_item "*)
8485 gl_warn_set="$gl_warn_set $gl_warn_item"
8487 esac
8488 done
8489 GNULIB_WARN_CFLAGS=$gl_warn_set
8499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8500 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8501 rm -f conf$$ conf$$.file
8503 LN_S_FILEONLY='cp -p'
8505 if (echo >conf$$.file) 2>/dev/null; then
8506 if ln -s conf$$.file conf$$ 2>/dev/null; then
8507 LN_S_FILEONLY='ln -s'
8508 elif ln conf$$.file conf$$ 2>/dev/null; then
8509 LN_S_FILEONLY=ln
8513 rm -f conf$$ conf$$.file
8515 if test "$LN_S_FILEONLY" = "ln -s"; then
8516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8517 $as_echo "yes" >&6; }
8518 else
8519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8520 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8526 if test "$opsys" = "mingw32"; then
8527 LN_S="ln"
8530 # Extract the first word of "install-info", so it can be a program name with args.
8531 set dummy install-info; ac_word=$2
8532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8533 $as_echo_n "checking for $ac_word... " >&6; }
8534 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8535 $as_echo_n "(cached) " >&6
8536 else
8537 case $INSTALL_INFO in
8538 [\\/]* | ?:[\\/]*)
8539 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8543 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8545 IFS=$as_save_IFS
8546 test -z "$as_dir" && as_dir=.
8547 for ac_exec_ext in '' $ac_executable_extensions; do
8548 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8549 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8551 break 2
8553 done
8554 done
8555 IFS=$as_save_IFS
8557 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8559 esac
8561 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8562 if test -n "$INSTALL_INFO"; then
8563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8564 $as_echo "$INSTALL_INFO" >&6; }
8565 else
8566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8567 $as_echo "no" >&6; }
8571 # Extract the first word of "gzip", so it can be a program name with args.
8572 set dummy gzip; ac_word=$2
8573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8574 $as_echo_n "checking for $ac_word... " >&6; }
8575 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8576 $as_echo_n "(cached) " >&6
8577 else
8578 case $GZIP_PROG in
8579 [\\/]* | ?:[\\/]*)
8580 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8584 for as_dir in $PATH
8586 IFS=$as_save_IFS
8587 test -z "$as_dir" && as_dir=.
8588 for ac_exec_ext in '' $ac_executable_extensions; do
8589 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8590 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8592 break 2
8594 done
8595 done
8596 IFS=$as_save_IFS
8599 esac
8601 GZIP_PROG=$ac_cv_path_GZIP_PROG
8602 if test -n "$GZIP_PROG"; then
8603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8604 $as_echo "$GZIP_PROG" >&6; }
8605 else
8606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8607 $as_echo "no" >&6; }
8612 if test $opsys = gnu-linux; then
8613 # Extract the first word of "paxctl", so it can be a program name with args.
8614 set dummy paxctl; ac_word=$2
8615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8616 $as_echo_n "checking for $ac_word... " >&6; }
8617 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8618 $as_echo_n "(cached) " >&6
8619 else
8620 case $PAXCTL in
8621 [\\/]* | ?:[\\/]*)
8622 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8626 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8628 IFS=$as_save_IFS
8629 test -z "$as_dir" && as_dir=.
8630 for ac_exec_ext in '' $ac_executable_extensions; do
8631 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8632 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8633 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8634 break 2
8636 done
8637 done
8638 IFS=$as_save_IFS
8641 esac
8643 PAXCTL=$ac_cv_path_PAXCTL
8644 if test -n "$PAXCTL"; then
8645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8646 $as_echo "$PAXCTL" >&6; }
8647 else
8648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8649 $as_echo "no" >&6; }
8653 if test "X$PAXCTL" != X; then
8654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8655 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8657 /* end confdefs.h. */
8660 main ()
8664 return 0;
8666 _ACEOF
8667 if ac_fn_c_try_link "$LINENO"; then :
8668 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8669 $as_echo "yes" >&6; }
8670 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8671 $as_echo "no" >&6; }; PAXCTL=""; fi
8673 rm -f core conftest.err conftest.$ac_objext \
8674 conftest$ac_exeext conftest.$ac_ext
8678 ## Need makeinfo >= 4.7 (?) to build the manuals.
8679 # Extract the first word of "makeinfo", so it can be a program name with args.
8680 set dummy makeinfo; ac_word=$2
8681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8682 $as_echo_n "checking for $ac_word... " >&6; }
8683 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8684 $as_echo_n "(cached) " >&6
8685 else
8686 case $MAKEINFO in
8687 [\\/]* | ?:[\\/]*)
8688 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8691 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8692 for as_dir in $PATH
8694 IFS=$as_save_IFS
8695 test -z "$as_dir" && as_dir=.
8696 for ac_exec_ext in '' $ac_executable_extensions; do
8697 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8698 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8699 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8700 break 2
8702 done
8703 done
8704 IFS=$as_save_IFS
8706 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8708 esac
8710 MAKEINFO=$ac_cv_path_MAKEINFO
8711 if test -n "$MAKEINFO"; then
8712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8713 $as_echo "$MAKEINFO" >&6; }
8714 else
8715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8716 $as_echo "no" >&6; }
8720 if test "$MAKEINFO" != "no"; then
8721 case `
8722 $MAKEINFO --version 2> /dev/null |
8723 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8724 ` in
8725 '') MAKEINFO=no;;
8726 esac
8729 ## Makeinfo is unusual. For a released Emacs, the manuals are
8730 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8731 ## therefore in the category of "special tools" not normally required, which
8732 ## configure does not have to check for (eg autoconf itself).
8733 ## In a Bazaar checkout on the other hand, the manuals are not included.
8734 ## So makeinfo is a requirement to build from Bazaar, and configure
8735 ## should test for it as it does for any other build requirement.
8736 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8737 ## with pre-built manuals, from a Bazaar checkout.
8738 HAVE_MAKEINFO=yes
8740 if test "$MAKEINFO" = "no"; then
8741 MAKEINFO=makeinfo
8742 if test "x${with_makeinfo}" = "xno"; then
8743 HAVE_MAKEINFO=no
8744 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8745 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8746 source tree does not seem to have pre-built manuals in the \`info' directory.
8747 Either install a suitable version of makeinfo, or re-run configure
8748 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8753 INFO_EXT=.info
8754 INFO_OPTS=--no-split
8759 if test x$GCC = xyes; then
8760 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8761 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8762 else
8763 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8764 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8768 late_LDFLAGS=$LDFLAGS
8769 if test x$GCC = xyes; then
8770 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8771 else
8772 LDFLAGS="$LDFLAGS -znocombreloc"
8775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8776 $as_echo_n "checking for -znocombreloc... " >&6; }
8777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8778 /* end confdefs.h. */
8781 main ()
8785 return 0;
8787 _ACEOF
8788 if ac_fn_c_try_link "$LINENO"; then :
8789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8790 $as_echo "yes" >&6; }
8791 else
8792 LDFLAGS=$late_LDFLAGS
8793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8794 $as_echo "no" >&6; }
8796 rm -f core conftest.err conftest.$ac_objext \
8797 conftest$ac_exeext conftest.$ac_ext
8800 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8801 case "$opsys" in
8802 your-opsys-here) CANNOT_DUMP=yes ;;
8803 esac
8805 test "$CANNOT_DUMP" = "yes" && \
8807 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8813 UNEXEC_OBJ=unexelf.o
8814 case "$opsys" in
8815 # MSDOS uses unexcoff.o
8816 aix4-2)
8817 UNEXEC_OBJ=unexaix.o
8819 cygwin)
8820 UNEXEC_OBJ=unexcw.o
8822 darwin)
8823 UNEXEC_OBJ=unexmacosx.o
8825 hpux10-20 | hpux11)
8826 UNEXEC_OBJ=unexhp9k800.o
8828 mingw32)
8829 UNEXEC_OBJ=unexw32.o
8831 sol2-10)
8832 # Use the Solaris dldump() function, called from unexsol.c, to dump
8833 # emacs, instead of the generic ELF dump code found in unexelf.c.
8834 # The resulting binary has a complete symbol table, and is better
8835 # for debugging and other observability tools (debuggers, pstack, etc).
8837 # If you encounter a problem using dldump(), please consider sending
8838 # a message to the OpenSolaris tools-linking mailing list:
8839 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8841 # It is likely that dldump() works with older Solaris too, but this has
8842 # not been tested, so for now this change is for Solaris 10 or newer.
8843 UNEXEC_OBJ=unexsol.o
8845 esac
8847 LD_SWITCH_SYSTEM=
8848 case "$opsys" in
8849 freebsd|dragonfly)
8850 ## Let `ld' find image libs and similar things in /usr/local/lib.
8851 ## The system compiler, GCC, has apparently been modified to not
8852 ## look there, contrary to what a stock GCC would do.
8853 ### It's not our place to do this. See bug#10313#17.
8854 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8858 gnu-linux)
8859 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8860 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8863 netbsd)
8864 ### It's not our place to do this. See bug#10313#17.
8865 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8869 openbsd)
8870 ## Han Boetes <han@boetes.org> says this is necessary,
8871 ## otherwise Emacs dumps core on elf systems.
8872 LD_SWITCH_SYSTEM="-Z"
8874 esac
8877 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8879 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8880 ## which has not been defined yet. When this was handled with cpp,
8881 ## it was expanded to null when configure sourced the s/*.h file.
8882 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8883 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8884 ## (or somesuch), but because it is supposed to go at the _front_
8885 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8886 ## Compare with the gnu-linux case below, which added to the end
8887 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8888 ## LD_SWITCH_SYSTEM_TEMACS.
8889 case "$opsys" in
8890 netbsd|openbsd)
8891 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8892 esac
8895 C_SWITCH_MACHINE=
8896 case $canonical in
8897 alpha*)
8898 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8899 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8903 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8904 ## With ELF, make sure that all common symbols get allocated to in the
8905 ## data section. Otherwise, the dump of temacs may miss variables in
8906 ## the shared library that have been initialized. For example, with
8907 ## GNU libc, __malloc_initialized would normally be resolved to the
8908 ## shared library's .bss section, which is fatal.
8909 if test "x$GCC" = "xyes"; then
8910 C_SWITCH_MACHINE="-fno-common"
8911 else
8912 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8914 else
8915 UNEXEC_OBJ=unexalpha.o
8918 esac
8923 C_SWITCH_SYSTEM=
8924 ## Some programs in src produce warnings saying certain subprograms
8925 ## are too complex and need a MAXMEM value greater than 2000 for
8926 ## additional optimization. --nils@exp-math.uni-essen.de
8927 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8928 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8929 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
8930 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8931 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8935 LIBS_SYSTEM=
8936 case "$opsys" in
8937 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8938 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8940 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
8942 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8944 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8946 ## Motif needs -lgen.
8947 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8948 esac
8952 ### Make sure subsequent tests use flags consistent with the build flags.
8954 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8955 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8956 else
8957 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8960 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8962 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8966 LIB_MATH=-lm
8967 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8969 case $opsys in
8970 cygwin )
8971 LIB_MATH=
8973 darwin )
8974 ## Adding -lm confuses the dynamic linker, so omit it.
8975 LIB_MATH=
8977 freebsd | dragonfly )
8978 SYSTEM_TYPE=berkeley-unix
8980 gnu-linux | gnu-kfreebsd )
8982 hpux10-20 | hpux11 )
8984 mingw32 )
8985 LIB_MATH=
8986 SYSTEM_TYPE=windows-nt
8988 netbsd | openbsd )
8989 SYSTEM_TYPE=berkeley-unix
8992 sol2* | unixware )
8993 SYSTEM_TYPE=usg-unix-v
8996 esac
9000 cat >>confdefs.h <<_ACEOF
9001 #define SYSTEM_TYPE "$SYSTEM_TYPE"
9002 _ACEOF
9006 pre_PKG_CONFIG_CFLAGS=$CFLAGS
9007 pre_PKG_CONFIG_LIBS=$LIBS
9009 # Extract the first word of "pkg-config", so it can be a program name with args.
9010 set dummy pkg-config; ac_word=$2
9011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9012 $as_echo_n "checking for $ac_word... " >&6; }
9013 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9014 $as_echo_n "(cached) " >&6
9015 else
9016 case $PKG_CONFIG in
9017 [\\/]* | ?:[\\/]*)
9018 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9021 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9022 for as_dir in $PATH
9024 IFS=$as_save_IFS
9025 test -z "$as_dir" && as_dir=.
9026 for ac_exec_ext in '' $ac_executable_extensions; do
9027 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9028 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9029 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9030 break 2
9032 done
9033 done
9034 IFS=$as_save_IFS
9036 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9038 esac
9040 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9041 if test -n "$PKG_CONFIG"; then
9042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9043 $as_echo "$PKG_CONFIG" >&6; }
9044 else
9045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9046 $as_echo "no" >&6; }
9053 HAVE_SOUND=no
9054 if test "${with_sound}" != "no"; then
9055 # Sound support for GNU/Linux, the free BSDs, and MinGW.
9056 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
9057 do :
9058 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9059 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9060 #ifdef __MINGW32__
9061 #define WIN32_LEAN_AND_MEAN
9062 #include <windows.h>
9063 #endif
9066 eval as_val=\$$as_ac_Header
9067 if test "x$as_val" = x""yes; then :
9068 cat >>confdefs.h <<_ACEOF
9069 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9070 _ACEOF
9071 have_sound_header=yes
9074 done
9076 if test "${with_sound}" = "ossaudio" || test "${with_sound}" = "yes"; then
9077 # Emulation library used on NetBSD.
9078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9079 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9080 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9081 $as_echo_n "(cached) " >&6
9082 else
9083 ac_check_lib_save_LIBS=$LIBS
9084 LIBS="-lossaudio $LIBS"
9085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9086 /* end confdefs.h. */
9088 /* Override any GCC internal prototype to avoid an error.
9089 Use char because int might match the return type of a GCC
9090 builtin and then its argument prototype would still apply. */
9091 #ifdef __cplusplus
9092 extern "C"
9093 #endif
9094 char _oss_ioctl ();
9096 main ()
9098 return _oss_ioctl ();
9100 return 0;
9102 _ACEOF
9103 if ac_fn_c_try_link "$LINENO"; then :
9104 ac_cv_lib_ossaudio__oss_ioctl=yes
9105 else
9106 ac_cv_lib_ossaudio__oss_ioctl=no
9108 rm -f core conftest.err conftest.$ac_objext \
9109 conftest$ac_exeext conftest.$ac_ext
9110 LIBS=$ac_check_lib_save_LIBS
9112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9113 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9114 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9115 LIBSOUND=-lossaudio
9116 else
9117 LIBSOUND=
9120 test "${with_sound}" = "ossaudio" && test -z "$LIBSOUND" && \
9121 as_fn_error "ossaudio sound support requested but not found." "$LINENO" 5
9125 if test "${with_sound}" = "alsa" || test "${with_sound}" = "yes"; then
9126 ALSA_REQUIRED=1.0.0
9127 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9129 succeeded=no
9131 if test "$PKG_CONFIG" = "no" ; then
9132 HAVE_ALSA=no
9133 else
9134 PKG_CONFIG_MIN_VERSION=0.9.0
9135 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9137 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9139 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9140 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9141 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9142 edit_cflags="
9143 s,///*,/,g
9144 s/^/ /
9145 s/ -I/ $isystem/g
9146 s/^ //
9148 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9149 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9151 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9152 succeeded=yes
9153 else
9154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9155 $as_echo "no" >&6; }
9156 ALSA_CFLAGS=""
9157 ALSA_LIBS=""
9158 ## If we have a custom action on failure, don't print errors, but
9159 ## do set a variable so people can do so. Do it in a subshell
9160 ## to capture any diagnostics in invoking pkg-config.
9161 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9167 else
9168 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9169 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9173 if test $succeeded = yes; then
9174 HAVE_ALSA=yes
9175 else
9176 HAVE_ALSA=no
9179 if test $HAVE_ALSA = yes; then
9180 SAVE_CFLAGS="$CFLAGS"
9181 SAVE_LIBS="$LIBS"
9182 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9183 LIBS="$ALSA_LIBS $LIBS"
9184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9185 /* end confdefs.h. */
9186 #include <asoundlib.h>
9188 main ()
9190 snd_lib_error_set_handler (0);
9192 return 0;
9194 _ACEOF
9195 if ac_fn_c_try_compile "$LINENO"; then :
9196 emacs_alsa_normal=yes
9197 else
9198 emacs_alsa_normal=no
9200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9201 if test "$emacs_alsa_normal" != yes; then
9202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9203 /* end confdefs.h. */
9204 #include <alsa/asoundlib.h>
9206 main ()
9208 snd_lib_error_set_handler (0);
9210 return 0;
9212 _ACEOF
9213 if ac_fn_c_try_compile "$LINENO"; then :
9214 emacs_alsa_subdir=yes
9215 else
9216 emacs_alsa_subdir=no
9218 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9219 if test "$emacs_alsa_subdir" != yes; then
9220 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9222 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9225 CFLAGS="$SAVE_CFLAGS"
9226 LIBS="$SAVE_LIBS"
9227 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9228 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9230 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9232 elif test "${with_sound}" = "alsa"; then
9233 as_fn_error "ALSA sound support requested but not found." "$LINENO" 5
9236 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9237 case "$opsys" in
9238 gnu-linux|freebsd|netbsd|mingw32)
9240 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9242 HAVE_SOUND=yes
9244 esac
9253 for ac_header in $ac_header_list
9254 do :
9255 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9256 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9258 eval as_val=\$$as_ac_Header
9259 if test "x$as_val" = x""yes; then :
9260 cat >>confdefs.h <<_ACEOF
9261 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9262 _ACEOF
9266 done
9286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9287 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9289 /* end confdefs.h. */
9290 #include <sys/personality.h>
9292 main ()
9294 personality (PER_LINUX32)
9296 return 0;
9298 _ACEOF
9299 if ac_fn_c_try_compile "$LINENO"; then :
9300 emacs_cv_personality_linux32=yes
9301 else
9302 emacs_cv_personality_linux32=no
9304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9306 $as_echo "$emacs_cv_personality_linux32" >&6; }
9308 if test $emacs_cv_personality_linux32 = yes; then
9310 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9314 for ac_header in term.h
9315 do :
9316 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9317 if test "x$ac_cv_header_term_h" = x""yes; then :
9318 cat >>confdefs.h <<_ACEOF
9319 #define HAVE_TERM_H 1
9320 _ACEOF
9324 done
9326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9327 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9328 if test "${ac_cv_header_time+set}" = set; then :
9329 $as_echo_n "(cached) " >&6
9330 else
9331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9332 /* end confdefs.h. */
9333 #include <sys/types.h>
9334 #include <sys/time.h>
9335 #include <time.h>
9338 main ()
9340 if ((struct tm *) 0)
9341 return 0;
9343 return 0;
9345 _ACEOF
9346 if ac_fn_c_try_compile "$LINENO"; then :
9347 ac_cv_header_time=yes
9348 else
9349 ac_cv_header_time=no
9351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9354 $as_echo "$ac_cv_header_time" >&6; }
9355 if test $ac_cv_header_time = yes; then
9357 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9361 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9364 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9365 ac_have_decl=1
9366 else
9367 ac_have_decl=0
9370 cat >>confdefs.h <<_ACEOF
9371 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9372 _ACEOF
9374 if test $ac_cv_have_decl_sys_siglist != yes; then
9375 # For Tru64, at least:
9376 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9379 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9380 ac_have_decl=1
9381 else
9382 ac_have_decl=0
9385 cat >>confdefs.h <<_ACEOF
9386 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9387 _ACEOF
9390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9391 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9392 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
9393 $as_echo_n "(cached) " >&6
9394 else
9395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9396 /* end confdefs.h. */
9397 #include <sys/types.h>
9398 #include <sys/wait.h>
9399 #ifndef WEXITSTATUS
9400 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9401 #endif
9402 #ifndef WIFEXITED
9403 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9404 #endif
9407 main ()
9409 int s;
9410 wait (&s);
9411 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9413 return 0;
9415 _ACEOF
9416 if ac_fn_c_try_compile "$LINENO"; then :
9417 ac_cv_header_sys_wait_h=yes
9418 else
9419 ac_cv_header_sys_wait_h=no
9421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9424 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9425 if test $ac_cv_header_sys_wait_h = yes; then
9427 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9435 for ac_header in net/if.h
9436 do :
9437 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9438 #if HAVE_SYS_SOCKET_H
9439 #include <sys/socket.h>
9440 #endif
9442 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9443 cat >>confdefs.h <<_ACEOF
9444 #define HAVE_NET_IF_H 1
9445 _ACEOF
9449 done
9451 for ac_header in ifaddrs.h
9452 do :
9453 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9454 #if HAVE_SYS_SOCKET_H
9455 #include <sys/socket.h>
9456 #endif
9458 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9459 cat >>confdefs.h <<_ACEOF
9460 #define HAVE_IFADDRS_H 1
9461 _ACEOF
9465 done
9467 for ac_header in net/if_dl.h
9468 do :
9469 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9470 #if HAVE_SYS_SOCKET_H
9471 #include <sys/socket.h>
9472 #endif
9474 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9475 cat >>confdefs.h <<_ACEOF
9476 #define HAVE_NET_IF_DL_H 1
9477 _ACEOF
9481 done
9484 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9485 #if HAVE_SYS_SOCKET_H
9486 #include <sys/socket.h>
9487 #endif
9488 #if HAVE_NET_IF_H
9489 #include <net/if.h>
9490 #endif
9492 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9494 cat >>confdefs.h <<_ACEOF
9495 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9496 _ACEOF
9500 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9501 #if HAVE_SYS_SOCKET_H
9502 #include <sys/socket.h>
9503 #endif
9504 #if HAVE_NET_IF_H
9505 #include <net/if.h>
9506 #endif
9508 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9510 cat >>confdefs.h <<_ACEOF
9511 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9512 _ACEOF
9516 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9517 #if HAVE_SYS_SOCKET_H
9518 #include <sys/socket.h>
9519 #endif
9520 #if HAVE_NET_IF_H
9521 #include <net/if.h>
9522 #endif
9524 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9526 cat >>confdefs.h <<_ACEOF
9527 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9528 _ACEOF
9532 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9533 #if HAVE_SYS_SOCKET_H
9534 #include <sys/socket.h>
9535 #endif
9536 #if HAVE_NET_IF_H
9537 #include <net/if.h>
9538 #endif
9540 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9542 cat >>confdefs.h <<_ACEOF
9543 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9544 _ACEOF
9548 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9549 #if HAVE_SYS_SOCKET_H
9550 #include <sys/socket.h>
9551 #endif
9552 #if HAVE_NET_IF_H
9553 #include <net/if.h>
9554 #endif
9556 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9558 cat >>confdefs.h <<_ACEOF
9559 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9560 _ACEOF
9564 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9565 #if HAVE_SYS_SOCKET_H
9566 #include <sys/socket.h>
9567 #endif
9568 #if HAVE_NET_IF_H
9569 #include <net/if.h>
9570 #endif
9572 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9574 cat >>confdefs.h <<_ACEOF
9575 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9576 _ACEOF
9584 DEPFLAGS=
9585 MKDEPDIR=":"
9586 deps_frag=deps.mk
9587 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9589 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9590 HAVE_GNU_MAKE=no
9591 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9592 if test "x$testval" != x; then
9593 HAVE_GNU_MAKE=yes
9594 else
9595 ac_enable_autodepend=no
9597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9598 $as_echo "$HAVE_GNU_MAKE" >&6; }
9599 if test $HAVE_GNU_MAKE = yes; then
9600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9601 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9602 SAVE_CFLAGS="$CFLAGS"
9603 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9605 /* end confdefs.h. */
9608 main ()
9612 return 0;
9614 _ACEOF
9615 if ac_fn_c_try_compile "$LINENO"; then :
9617 else
9618 ac_enable_autodepend=no
9620 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9621 CFLAGS="$SAVE_CFLAGS"
9622 test -f deps.d || ac_enable_autodepend=no
9623 rm -rf deps.d
9624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9625 $as_echo "$ac_enable_autodepend" >&6; }
9627 if test $ac_enable_autodepend = yes; then
9628 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9629 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9630 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9631 deps_frag=autodeps.mk
9634 deps_frag=$srcdir/src/$deps_frag
9640 lisp_frag=$srcdir/src/lisp.mk
9644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9645 $as_echo_n "checking for long file names... " >&6; }
9646 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9647 $as_echo_n "(cached) " >&6
9648 else
9649 ac_cv_sys_long_file_names=yes
9650 # Test for long file names in all the places we know might matter:
9651 # . the current directory, where building will happen
9652 # $prefix/lib where we will be installing things
9653 # $exec_prefix/lib likewise
9654 # $TMPDIR if set, where it might want to write temporary files
9655 # /tmp where it might want to write temporary files
9656 # /var/tmp likewise
9657 # /usr/tmp likewise
9658 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9659 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9660 # in the usual case where exec_prefix is '${prefix}'.
9661 case $ac_dir in #(
9662 . | /* | ?:[\\/]*) ;; #(
9663 *) continue;;
9664 esac
9665 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9666 ac_xdir=$ac_dir/cf$$
9667 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9668 ac_tf1=$ac_xdir/conftest9012345
9669 ac_tf2=$ac_xdir/conftest9012346
9670 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9671 ac_cv_sys_long_file_names=no
9672 rm -f -r "$ac_xdir" 2>/dev/null
9673 test $ac_cv_sys_long_file_names = no && break
9674 done
9676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9677 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9678 if test $ac_cv_sys_long_file_names = yes; then
9680 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9685 #### Choose a window system.
9687 ## We leave window_system equal to none if
9688 ## we end up building without one. Any new window system should
9689 ## set window_system to an appropriate value and add objects to
9690 ## window-system-specific substs.
9692 window_system=none
9693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9694 $as_echo_n "checking for X... " >&6; }
9697 # Check whether --with-x was given.
9698 if test "${with_x+set}" = set; then :
9699 withval=$with_x;
9702 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9703 if test "x$with_x" = xno; then
9704 # The user explicitly disabled X.
9705 have_x=disabled
9706 else
9707 case $x_includes,$x_libraries in #(
9708 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9709 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9710 $as_echo_n "(cached) " >&6
9711 else
9712 # One or both of the vars are not set, and there is no cached value.
9713 ac_x_includes=no ac_x_libraries=no
9714 rm -f -r conftest.dir
9715 if mkdir conftest.dir; then
9716 cd conftest.dir
9717 cat >Imakefile <<'_ACEOF'
9718 incroot:
9719 @echo incroot='${INCROOT}'
9720 usrlibdir:
9721 @echo usrlibdir='${USRLIBDIR}'
9722 libdir:
9723 @echo libdir='${LIBDIR}'
9724 _ACEOF
9725 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9726 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9727 for ac_var in incroot usrlibdir libdir; do
9728 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9729 done
9730 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9731 for ac_extension in a so sl dylib la dll; do
9732 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9733 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9734 ac_im_usrlibdir=$ac_im_libdir; break
9736 done
9737 # Screen out bogus values from the imake configuration. They are
9738 # bogus both because they are the default anyway, and because
9739 # using them would break gcc on systems where it needs fixed includes.
9740 case $ac_im_incroot in
9741 /usr/include) ac_x_includes= ;;
9742 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9743 esac
9744 case $ac_im_usrlibdir in
9745 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9746 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9747 esac
9749 cd ..
9750 rm -f -r conftest.dir
9753 # Standard set of common directories for X headers.
9754 # Check X11 before X11Rn because it is often a symlink to the current release.
9755 ac_x_header_dirs='
9756 /usr/X11/include
9757 /usr/X11R7/include
9758 /usr/X11R6/include
9759 /usr/X11R5/include
9760 /usr/X11R4/include
9762 /usr/include/X11
9763 /usr/include/X11R7
9764 /usr/include/X11R6
9765 /usr/include/X11R5
9766 /usr/include/X11R4
9768 /usr/local/X11/include
9769 /usr/local/X11R7/include
9770 /usr/local/X11R6/include
9771 /usr/local/X11R5/include
9772 /usr/local/X11R4/include
9774 /usr/local/include/X11
9775 /usr/local/include/X11R7
9776 /usr/local/include/X11R6
9777 /usr/local/include/X11R5
9778 /usr/local/include/X11R4
9780 /usr/X386/include
9781 /usr/x386/include
9782 /usr/XFree86/include/X11
9784 /usr/include
9785 /usr/local/include
9786 /usr/unsupported/include
9787 /usr/athena/include
9788 /usr/local/x11r5/include
9789 /usr/lpp/Xamples/include
9791 /usr/openwin/include
9792 /usr/openwin/share/include'
9794 if test "$ac_x_includes" = no; then
9795 # Guess where to find include files, by looking for Xlib.h.
9796 # First, try using that file with no special directory specified.
9797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9798 /* end confdefs.h. */
9799 #include <X11/Xlib.h>
9800 _ACEOF
9801 if ac_fn_c_try_cpp "$LINENO"; then :
9802 # We can compile using X headers with no special include directory.
9803 ac_x_includes=
9804 else
9805 for ac_dir in $ac_x_header_dirs; do
9806 if test -r "$ac_dir/X11/Xlib.h"; then
9807 ac_x_includes=$ac_dir
9808 break
9810 done
9812 rm -f conftest.err conftest.$ac_ext
9813 fi # $ac_x_includes = no
9815 if test "$ac_x_libraries" = no; then
9816 # Check for the libraries.
9817 # See if we find them without any special options.
9818 # Don't add to $LIBS permanently.
9819 ac_save_LIBS=$LIBS
9820 LIBS="-lX11 $LIBS"
9821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9822 /* end confdefs.h. */
9823 #include <X11/Xlib.h>
9825 main ()
9827 XrmInitialize ()
9829 return 0;
9831 _ACEOF
9832 if ac_fn_c_try_link "$LINENO"; then :
9833 LIBS=$ac_save_LIBS
9834 # We can link X programs with no special library path.
9835 ac_x_libraries=
9836 else
9837 LIBS=$ac_save_LIBS
9838 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9840 # Don't even attempt the hair of trying to link an X program!
9841 for ac_extension in a so sl dylib la dll; do
9842 if test -r "$ac_dir/libX11.$ac_extension"; then
9843 ac_x_libraries=$ac_dir
9844 break 2
9846 done
9847 done
9849 rm -f core conftest.err conftest.$ac_objext \
9850 conftest$ac_exeext conftest.$ac_ext
9851 fi # $ac_x_libraries = no
9853 case $ac_x_includes,$ac_x_libraries in #(
9854 no,* | *,no | *\'*)
9855 # Didn't find X, or a directory has "'" in its name.
9856 ac_cv_have_x="have_x=no";; #(
9858 # Record where we found X for the cache.
9859 ac_cv_have_x="have_x=yes\
9860 ac_x_includes='$ac_x_includes'\
9861 ac_x_libraries='$ac_x_libraries'"
9862 esac
9864 ;; #(
9865 *) have_x=yes;;
9866 esac
9867 eval "$ac_cv_have_x"
9868 fi # $with_x != no
9870 if test "$have_x" != yes; then
9871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9872 $as_echo "$have_x" >&6; }
9873 no_x=yes
9874 else
9875 # If each of the values was on the command line, it overrides each guess.
9876 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9877 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9878 # Update the cache value to reflect the command line values.
9879 ac_cv_have_x="have_x=yes\
9880 ac_x_includes='$x_includes'\
9881 ac_x_libraries='$x_libraries'"
9882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9883 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9886 if test "$no_x" != yes; then
9887 window_system=x11
9890 LD_SWITCH_X_SITE_RPATH=
9891 if test "${x_libraries}" != NONE; then
9892 if test -n "${x_libraries}"; then
9893 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9894 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9896 x_default_search_path=""
9897 x_search_path=${x_libraries}
9898 if test -z "${x_search_path}"; then
9899 x_search_path=/usr/lib
9901 for x_library in `echo ${x_search_path}: | \
9902 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9903 x_search_path="\
9904 ${x_library}/X11/%L/%T/%N%C%S:\
9905 ${x_library}/X11/%l/%T/%N%C%S:\
9906 ${x_library}/X11/%T/%N%C%S:\
9907 ${x_library}/X11/%L/%T/%N%S:\
9908 ${x_library}/X11/%l/%T/%N%S:\
9909 ${x_library}/X11/%T/%N%S"
9910 if test x"${x_default_search_path}" = x; then
9911 x_default_search_path=${x_search_path}
9912 else
9913 x_default_search_path="${x_search_path}:${x_default_search_path}"
9915 done
9919 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9920 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9923 if test x"${x_includes}" = x; then
9924 bitmapdir=/usr/include/X11/bitmaps
9925 else
9926 # accumulate include directories that have X11 bitmap subdirectories
9927 bmd_acc="dummyval"
9928 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9929 if test -d "${bmd}/X11/bitmaps"; then
9930 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9932 if test -d "${bmd}/bitmaps"; then
9933 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9935 done
9936 if test ${bmd_acc} != "dummyval"; then
9937 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9941 HAVE_NS=no
9942 NS_IMPL_COCOA=no
9943 NS_IMPL_GNUSTEP=no
9944 tmp_CPPFLAGS="$CPPFLAGS"
9945 tmp_CFLAGS="$CFLAGS"
9946 CPPFLAGS="$CPPFLAGS -x objective-c"
9947 CFLAGS="$CFLAGS -x objective-c"
9948 GNU_OBJC_CFLAGS=
9949 LIBS_GNUSTEP=
9950 if test "${with_ns}" != no; then
9951 if test "${opsys}" = darwin; then
9952 NS_IMPL_COCOA=yes
9953 ns_appdir=`pwd`/nextstep/Emacs.app
9954 ns_appbindir=${ns_appdir}/Contents/MacOS
9955 ns_appresdir=${ns_appdir}/Contents/Resources
9956 ns_appsrc=Cocoa/Emacs.base
9957 elif test -f $GNUSTEP_CONFIG_FILE; then
9958 NS_IMPL_GNUSTEP=yes
9959 ns_appdir=`pwd`/nextstep/Emacs.app
9960 ns_appbindir=${ns_appdir}
9961 ns_appresdir=${ns_appdir}/Resources
9962 ns_appsrc=GNUstep/Emacs.base
9963 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9964 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9965 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9966 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9967 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9968 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9969 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9970 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9971 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9972 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9973 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9974 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
9975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9976 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9977 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9978 $as_echo_n "(cached) " >&6
9979 else
9980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9981 /* end confdefs.h. */
9982 #include <GNUstepBase/GSConfig.h>
9984 main ()
9986 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9988 #else
9989 fail;
9990 #endif
9992 return 0;
9994 _ACEOF
9995 if ac_fn_c_try_compile "$LINENO"; then :
9996 emacs_cv_objc_exceptions=yes
9997 else
9998 emacs_cv_objc_exceptions=no
10000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
10003 $as_echo "$emacs_cv_objc_exceptions" >&6; }
10004 if test $emacs_cv_objc_exceptions = yes; then
10006 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
10008 GNU_OBJC_CFLAGS="-fobjc-exceptions"
10012 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
10014 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
10015 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
10016 HAVE_NS=yes
10017 else
10018 as_fn_error "\`--with-ns' was specified, but the include
10019 files are missing or cannot be compiled." "$LINENO" 5
10024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10025 /* end confdefs.h. */
10026 #include <AppKit/AppKit.h>
10028 main ()
10031 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10032 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
10033 ; /* OK */
10034 #else
10035 #error "OSX 10.4 or newer required"
10036 #endif
10037 #endif
10040 return 0;
10042 _ACEOF
10043 if ac_fn_c_try_compile "$LINENO"; then :
10044 ns_osx_have_104=yes
10045 else
10046 ns_osx_have_104=no
10048 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10050 /* end confdefs.h. */
10051 #include <Foundation/NSObjCRuntime.h>
10053 main ()
10055 NSInteger i;
10057 return 0;
10059 _ACEOF
10060 if ac_fn_c_try_compile "$LINENO"; then :
10061 ns_have_nsinteger=yes
10062 else
10063 ns_have_nsinteger=no
10065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10066 if test $ns_osx_have_104 = no; then
10067 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10069 if test $ns_have_nsinteger = yes; then
10071 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10078 INSTALL_ARCH_INDEP_EXTRA=install-etc
10079 ns_self_contained=no
10080 NS_OBJ=
10081 NS_OBJC_OBJ=
10082 if test "${HAVE_NS}" = yes; then
10083 if test "$with_toolkit_scroll_bars" = "no"; then
10084 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10087 window_system=nextstep
10088 # set up packaging dirs
10089 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10090 ns_self_contained=yes
10091 prefix=${ns_appresdir}
10092 exec_prefix=${ns_appbindir}
10093 libexecdir="\${ns_appbindir}/libexec"
10094 archlibdir="\${ns_appbindir}/libexec"
10095 etcdocdir="\${ns_appresdir}/etc"
10096 etcdir="\${ns_appresdir}/etc"
10097 infodir="\${ns_appresdir}/info"
10098 mandir="\${ns_appresdir}/man"
10099 lispdir="\${ns_appresdir}/lisp"
10100 leimdir="\${ns_appresdir}/leim"
10101 INSTALL_ARCH_INDEP_EXTRA=
10103 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
10105 CFLAGS="$tmp_CFLAGS"
10106 CPPFLAGS="$tmp_CPPFLAGS"
10112 HAVE_W32=no
10113 W32_OBJ=
10114 W32_LIBS=
10115 EMACSRES=
10116 CLIENTRES=
10117 CLIENTW=
10118 W32_RES_LINK=
10119 EMACS_MANIFEST=
10120 UPDATE_MANIFEST=
10121 if test "${with_w32}" != no; then
10122 case "${opsys}" in
10123 cygwin)
10124 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10125 if test "x$ac_cv_header_windows_h" = x""yes; then :
10126 HAVE_W32=yes
10127 else
10128 as_fn_error "\`--with-w32' was specified, but windows.h
10129 cannot be found." "$LINENO" 5
10134 mingw32)
10135 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10138 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10140 esac
10143 if test "${opsys}" = "mingw32"; then
10144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10145 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10147 /* end confdefs.h. */
10149 #include <windows.h>
10150 #include <usp10.h>
10152 main ()
10154 PIMAGE_NT_HEADERS pHeader;
10155 PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader)
10157 return 0;
10159 _ACEOF
10160 if ac_fn_c_try_compile "$LINENO"; then :
10161 emacs_cv_w32api=yes
10162 HAVE_W32=yes
10163 else
10164 emacs_cv_w32api=no
10166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10168 $as_echo "$emacs_cv_w32api" >&6; }
10169 if test "${emacs_cv_w32api}" = "no"; then
10170 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10174 FIRSTFILE_OBJ=
10175 NTDIR=
10176 LIBS_ECLIENT=
10177 LIB_WSOCK32=
10178 NTLIB=
10179 CM_OBJ="cm.o"
10180 XARGS_LIMIT=
10181 if test "${HAVE_W32}" = "yes"; then
10183 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10185 if test -n "$ac_tool_prefix"; then
10186 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10187 set dummy ${ac_tool_prefix}windres; ac_word=$2
10188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10189 $as_echo_n "checking for $ac_word... " >&6; }
10190 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10191 $as_echo_n "(cached) " >&6
10192 else
10193 if test -n "$WINDRES"; then
10194 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10195 else
10196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10197 for as_dir in $PATH
10199 IFS=$as_save_IFS
10200 test -z "$as_dir" && as_dir=.
10201 for ac_exec_ext in '' $ac_executable_extensions; do
10202 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10203 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10205 break 2
10207 done
10208 done
10209 IFS=$as_save_IFS
10213 WINDRES=$ac_cv_prog_WINDRES
10214 if test -n "$WINDRES"; then
10215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10216 $as_echo "$WINDRES" >&6; }
10217 else
10218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10219 $as_echo "no" >&6; }
10224 if test -z "$ac_cv_prog_WINDRES"; then
10225 ac_ct_WINDRES=$WINDRES
10226 # Extract the first word of "windres", so it can be a program name with args.
10227 set dummy windres; ac_word=$2
10228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10229 $as_echo_n "checking for $ac_word... " >&6; }
10230 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10231 $as_echo_n "(cached) " >&6
10232 else
10233 if test -n "$ac_ct_WINDRES"; then
10234 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10235 else
10236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10237 for as_dir in $PATH
10239 IFS=$as_save_IFS
10240 test -z "$as_dir" && as_dir=.
10241 for ac_exec_ext in '' $ac_executable_extensions; do
10242 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10243 ac_cv_prog_ac_ct_WINDRES="windres"
10244 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10245 break 2
10247 done
10248 done
10249 IFS=$as_save_IFS
10253 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10254 if test -n "$ac_ct_WINDRES"; then
10255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10256 $as_echo "$ac_ct_WINDRES" >&6; }
10257 else
10258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10259 $as_echo "no" >&6; }
10262 if test "x$ac_ct_WINDRES" = x; then
10263 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10264 else
10265 case $cross_compiling:$ac_tool_warned in
10266 yes:)
10267 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10268 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10269 ac_tool_warned=yes ;;
10270 esac
10271 WINDRES=$ac_ct_WINDRES
10273 else
10274 WINDRES="$ac_cv_prog_WINDRES"
10277 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10278 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10279 EMACSRES="emacs.res"
10280 case "$canonical" in
10281 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10282 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10283 esac
10284 UPDATE_MANIFEST=update-game-score.exe.manifest
10285 if test "${opsys}" = "cygwin"; then
10286 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10287 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10288 # Tell the linker that emacs.res is an object (which we compile from
10289 # the rc file), not a linker script.
10290 W32_RES_LINK="-Wl,emacs.res"
10291 else
10292 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10293 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10294 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10295 W32_RES_LINK="\$(EMACSRES)"
10296 CLIENTRES="emacsclient.res"
10297 CLIENTW="emacsclientw\$(EXEEXT)"
10298 FIRSTFILE_OBJ=firstfile.o
10299 NTDIR=nt
10300 CM_OBJ=
10301 LIBS_ECLIENT="-lcomctl32"
10302 LIB_WSOCK32="-lwsock32"
10303 NTLIB="ntlib.$ac_objext"
10304 XARGS_LIMIT="-s 10000"
10323 if test "${HAVE_W32}" = "yes"; then
10324 window_system=w32
10325 with_xft=no
10328 ## $window_system is now set to the window system we will
10329 ## ultimately use.
10331 term_header=
10332 HAVE_X_WINDOWS=no
10333 HAVE_X11=no
10334 USE_X_TOOLKIT=none
10336 case "${window_system}" in
10337 x11 )
10338 HAVE_X_WINDOWS=yes
10339 HAVE_X11=yes
10340 term_header=xterm.h
10341 case "${with_x_toolkit}" in
10342 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10343 motif ) USE_X_TOOLKIT=MOTIF ;;
10344 gtk ) with_gtk=yes
10345 term_header=gtkutil.h
10346 USE_X_TOOLKIT=none ;;
10347 gtk2 ) with_gtk2=yes
10348 term_header=gtkutil.h
10349 USE_X_TOOLKIT=none ;;
10350 gtk3 ) with_gtk3=yes
10351 term_header=gtkutil.h
10352 USE_X_TOOLKIT=none ;;
10353 no ) USE_X_TOOLKIT=none ;;
10354 * ) USE_X_TOOLKIT=maybe ;;
10355 esac
10357 nextstep )
10358 term_header=nsterm.h
10360 w32 )
10361 term_header=w32term.h
10363 esac
10365 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10366 # Extract the first word of "X", so it can be a program name with args.
10367 set dummy X; ac_word=$2
10368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10369 $as_echo_n "checking for $ac_word... " >&6; }
10370 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10371 $as_echo_n "(cached) " >&6
10372 else
10373 if test -n "$HAVE_XSERVER"; then
10374 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10375 else
10376 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10377 for as_dir in $PATH
10379 IFS=$as_save_IFS
10380 test -z "$as_dir" && as_dir=.
10381 for ac_exec_ext in '' $ac_executable_extensions; do
10382 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10383 ac_cv_prog_HAVE_XSERVER="true"
10384 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10385 break 2
10387 done
10388 done
10389 IFS=$as_save_IFS
10391 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10394 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10395 if test -n "$HAVE_XSERVER"; then
10396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10397 $as_echo "$HAVE_XSERVER" >&6; }
10398 else
10399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10400 $as_echo "no" >&6; }
10404 if test "$HAVE_XSERVER" = true ||
10405 test -n "$DISPLAY" ||
10406 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10407 as_fn_error "You seem to be running X, but no X development libraries
10408 were found. You should install the relevant development files for X
10409 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10410 sure you have development files for image handling, i.e.
10411 tiff, gif, jpeg, png and xpm.
10412 If you are sure you want Emacs compiled without X window support, pass
10413 --without-x
10414 to configure." "$LINENO" 5
10418 ### If we're using X11, we should use the X menu package.
10419 HAVE_MENUS=no
10420 case ${HAVE_X11} in
10421 yes ) HAVE_MENUS=yes ;;
10422 esac
10424 # Does the opsystem file prohibit the use of the GNU malloc?
10425 # Assume not, until told otherwise.
10426 GNU_MALLOC=yes
10428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10429 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10430 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10431 $as_echo_n "(cached) " >&6
10432 else
10433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10434 /* end confdefs.h. */
10435 #include <malloc.h>
10436 static void hook (void) {}
10438 main ()
10440 malloc_set_state (malloc_get_state ());
10441 __after_morecore_hook = hook;
10442 __malloc_initialize_hook = hook;
10444 return 0;
10446 _ACEOF
10447 if ac_fn_c_try_link "$LINENO"; then :
10448 emacs_cv_var_doug_lea_malloc=yes
10449 else
10450 emacs_cv_var_doug_lea_malloc=no
10452 rm -f core conftest.err conftest.$ac_objext \
10453 conftest$ac_exeext conftest.$ac_ext
10455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10456 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10457 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10460 system_malloc=no
10461 case "$opsys" in
10462 ## darwin ld insists on the use of malloc routines in the System framework.
10463 darwin|sol2-10) system_malloc=yes ;;
10464 esac
10466 if test "${system_malloc}" = "yes"; then
10468 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10470 GNU_MALLOC=no
10471 GNU_MALLOC_reason="
10472 (The GNU allocators don't work with this system configuration.)"
10473 GMALLOC_OBJ=
10474 VMLIMIT_OBJ=
10475 else
10476 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10477 VMLIMIT_OBJ=vm-limit.o
10479 for ac_header in sys/vlimit.h
10480 do :
10481 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10482 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10483 cat >>confdefs.h <<_ACEOF
10484 #define HAVE_SYS_VLIMIT_H 1
10485 _ACEOF
10489 done
10491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10492 $as_echo_n "checking for data_start... " >&6; }
10493 if test "${emacs_cv_data_start+set}" = set; then :
10494 $as_echo_n "(cached) " >&6
10495 else
10496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10497 /* end confdefs.h. */
10498 extern char data_start[]; char ch;
10500 main ()
10502 return data_start < &ch;
10504 return 0;
10506 _ACEOF
10507 if ac_fn_c_try_link "$LINENO"; then :
10508 emacs_cv_data_start=yes
10509 else
10510 emacs_cv_data_start=no
10512 rm -f core conftest.err conftest.$ac_objext \
10513 conftest$ac_exeext conftest.$ac_ext
10515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10516 $as_echo "$emacs_cv_data_start" >&6; }
10517 if test $emacs_cv_data_start = yes; then
10519 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10526 if test "$doug_lea_malloc" = "yes" ; then
10527 if test "$GNU_MALLOC" = yes ; then
10528 GNU_MALLOC_reason="
10529 (Using Doug Lea's new malloc from the GNU C Library.)"
10532 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10535 ## Use mmap directly for allocating larger buffers.
10536 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10537 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10538 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10539 case "$opsys" in
10540 gnu*) REL_ALLOC=no ;;
10541 esac
10544 if test x"${REL_ALLOC}" = x; then
10545 REL_ALLOC=${GNU_MALLOC}
10548 use_mmap_for_buffers=no
10549 case "$opsys" in
10550 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10551 esac
10560 for ac_func in getpagesize
10561 do :
10562 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10563 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10564 cat >>confdefs.h <<_ACEOF
10565 #define HAVE_GETPAGESIZE 1
10566 _ACEOF
10569 done
10571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10572 $as_echo_n "checking for working mmap... " >&6; }
10573 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10574 $as_echo_n "(cached) " >&6
10575 else
10576 if test "$cross_compiling" = yes; then :
10577 ac_cv_func_mmap_fixed_mapped=no
10578 else
10579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10580 /* end confdefs.h. */
10581 $ac_includes_default
10582 /* malloc might have been renamed as rpl_malloc. */
10583 #undef malloc
10585 /* Thanks to Mike Haertel and Jim Avera for this test.
10586 Here is a matrix of mmap possibilities:
10587 mmap private not fixed
10588 mmap private fixed at somewhere currently unmapped
10589 mmap private fixed at somewhere already mapped
10590 mmap shared not fixed
10591 mmap shared fixed at somewhere currently unmapped
10592 mmap shared fixed at somewhere already mapped
10593 For private mappings, we should verify that changes cannot be read()
10594 back from the file, nor mmap's back from the file at a different
10595 address. (There have been systems where private was not correctly
10596 implemented like the infamous i386 svr4.0, and systems where the
10597 VM page cache was not coherent with the file system buffer cache
10598 like early versions of FreeBSD and possibly contemporary NetBSD.)
10599 For shared mappings, we should conversely verify that changes get
10600 propagated back to all the places they're supposed to be.
10602 Grep wants private fixed already mapped.
10603 The main things grep needs to know about mmap are:
10604 * does it exist and is it safe to write into the mmap'd area
10605 * how to use it (BSD variants) */
10607 #include <fcntl.h>
10608 #include <sys/mman.h>
10610 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10611 char *malloc ();
10612 #endif
10614 /* This mess was copied from the GNU getpagesize.h. */
10615 #ifndef HAVE_GETPAGESIZE
10616 # ifdef _SC_PAGESIZE
10617 # define getpagesize() sysconf(_SC_PAGESIZE)
10618 # else /* no _SC_PAGESIZE */
10619 # ifdef HAVE_SYS_PARAM_H
10620 # include <sys/param.h>
10621 # ifdef EXEC_PAGESIZE
10622 # define getpagesize() EXEC_PAGESIZE
10623 # else /* no EXEC_PAGESIZE */
10624 # ifdef NBPG
10625 # define getpagesize() NBPG * CLSIZE
10626 # ifndef CLSIZE
10627 # define CLSIZE 1
10628 # endif /* no CLSIZE */
10629 # else /* no NBPG */
10630 # ifdef NBPC
10631 # define getpagesize() NBPC
10632 # else /* no NBPC */
10633 # ifdef PAGESIZE
10634 # define getpagesize() PAGESIZE
10635 # endif /* PAGESIZE */
10636 # endif /* no NBPC */
10637 # endif /* no NBPG */
10638 # endif /* no EXEC_PAGESIZE */
10639 # else /* no HAVE_SYS_PARAM_H */
10640 # define getpagesize() 8192 /* punt totally */
10641 # endif /* no HAVE_SYS_PARAM_H */
10642 # endif /* no _SC_PAGESIZE */
10644 #endif /* no HAVE_GETPAGESIZE */
10647 main ()
10649 char *data, *data2, *data3;
10650 const char *cdata2;
10651 int i, pagesize;
10652 int fd, fd2;
10654 pagesize = getpagesize ();
10656 /* First, make a file with some known garbage in it. */
10657 data = (char *) malloc (pagesize);
10658 if (!data)
10659 return 1;
10660 for (i = 0; i < pagesize; ++i)
10661 *(data + i) = rand ();
10662 umask (0);
10663 fd = creat ("conftest.mmap", 0600);
10664 if (fd < 0)
10665 return 2;
10666 if (write (fd, data, pagesize) != pagesize)
10667 return 3;
10668 close (fd);
10670 /* Next, check that the tail of a page is zero-filled. File must have
10671 non-zero length, otherwise we risk SIGBUS for entire page. */
10672 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10673 if (fd2 < 0)
10674 return 4;
10675 cdata2 = "";
10676 if (write (fd2, cdata2, 1) != 1)
10677 return 5;
10678 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10679 if (data2 == MAP_FAILED)
10680 return 6;
10681 for (i = 0; i < pagesize; ++i)
10682 if (*(data2 + i))
10683 return 7;
10684 close (fd2);
10685 if (munmap (data2, pagesize))
10686 return 8;
10688 /* Next, try to mmap the file at a fixed address which already has
10689 something else allocated at it. If we can, also make sure that
10690 we see the same garbage. */
10691 fd = open ("conftest.mmap", O_RDWR);
10692 if (fd < 0)
10693 return 9;
10694 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10695 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10696 return 10;
10697 for (i = 0; i < pagesize; ++i)
10698 if (*(data + i) != *(data2 + i))
10699 return 11;
10701 /* Finally, make sure that changes to the mapped area do not
10702 percolate back to the file as seen by read(). (This is a bug on
10703 some variants of i386 svr4.0.) */
10704 for (i = 0; i < pagesize; ++i)
10705 *(data2 + i) = *(data2 + i) + 1;
10706 data3 = (char *) malloc (pagesize);
10707 if (!data3)
10708 return 12;
10709 if (read (fd, data3, pagesize) != pagesize)
10710 return 13;
10711 for (i = 0; i < pagesize; ++i)
10712 if (*(data + i) != *(data3 + i))
10713 return 14;
10714 close (fd);
10715 return 0;
10717 _ACEOF
10718 if ac_fn_c_try_run "$LINENO"; then :
10719 ac_cv_func_mmap_fixed_mapped=yes
10720 else
10721 ac_cv_func_mmap_fixed_mapped=no
10723 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10724 conftest.$ac_objext conftest.beam conftest.$ac_ext
10728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10729 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10730 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10732 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10735 rm -f conftest.mmap conftest.txt
10737 if test $use_mmap_for_buffers = yes; then
10739 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10741 REL_ALLOC=no
10744 LIBS="$LIBS_SYSTEM $LIBS"
10746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10747 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10748 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10749 $as_echo_n "(cached) " >&6
10750 else
10751 ac_check_lib_save_LIBS=$LIBS
10752 LIBS="-ldnet $LIBS"
10753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10754 /* end confdefs.h. */
10756 /* Override any GCC internal prototype to avoid an error.
10757 Use char because int might match the return type of a GCC
10758 builtin and then its argument prototype would still apply. */
10759 #ifdef __cplusplus
10760 extern "C"
10761 #endif
10762 char dnet_ntoa ();
10764 main ()
10766 return dnet_ntoa ();
10768 return 0;
10770 _ACEOF
10771 if ac_fn_c_try_link "$LINENO"; then :
10772 ac_cv_lib_dnet_dnet_ntoa=yes
10773 else
10774 ac_cv_lib_dnet_dnet_ntoa=no
10776 rm -f core conftest.err conftest.$ac_objext \
10777 conftest$ac_exeext conftest.$ac_ext
10778 LIBS=$ac_check_lib_save_LIBS
10780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10781 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10782 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10783 cat >>confdefs.h <<_ACEOF
10784 #define HAVE_LIBDNET 1
10785 _ACEOF
10787 LIBS="-ldnet $LIBS"
10792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10793 $as_echo_n "checking for main in -lXbsd... " >&6; }
10794 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10795 $as_echo_n "(cached) " >&6
10796 else
10797 ac_check_lib_save_LIBS=$LIBS
10798 LIBS="-lXbsd $LIBS"
10799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10800 /* end confdefs.h. */
10804 main ()
10806 return main ();
10808 return 0;
10810 _ACEOF
10811 if ac_fn_c_try_link "$LINENO"; then :
10812 ac_cv_lib_Xbsd_main=yes
10813 else
10814 ac_cv_lib_Xbsd_main=no
10816 rm -f core conftest.err conftest.$ac_objext \
10817 conftest$ac_exeext conftest.$ac_ext
10818 LIBS=$ac_check_lib_save_LIBS
10820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10821 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10822 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10823 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10827 LIB_PTHREAD=
10831 if test "$ac_cv_header_pthread_h"; then
10832 if test "$GMALLOC_OBJ" = gmalloc.o; then
10833 emacs_pthread_function=pthread_atfork
10834 else
10835 emacs_pthread_function=pthread_self
10837 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10839 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10840 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10841 $as_echo_n "(cached) " >&6
10842 else
10843 ac_check_lib_save_LIBS=$LIBS
10844 LIBS="-lpthread $LIBS"
10845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10846 /* end confdefs.h. */
10848 /* Override any GCC internal prototype to avoid an error.
10849 Use char because int might match the return type of a GCC
10850 builtin and then its argument prototype would still apply. */
10851 #ifdef __cplusplus
10852 extern "C"
10853 #endif
10854 char $emacs_pthread_function ();
10856 main ()
10858 return $emacs_pthread_function ();
10860 return 0;
10862 _ACEOF
10863 if ac_fn_c_try_link "$LINENO"; then :
10864 eval "$as_ac_Lib=yes"
10865 else
10866 eval "$as_ac_Lib=no"
10868 rm -f core conftest.err conftest.$ac_objext \
10869 conftest$ac_exeext conftest.$ac_ext
10870 LIBS=$ac_check_lib_save_LIBS
10872 eval ac_res=\$$as_ac_Lib
10873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10874 $as_echo "$ac_res" >&6; }
10875 eval as_val=\$$as_ac_Lib
10876 if test "x$as_val" = x""yes; then :
10877 HAVE_PTHREAD=yes
10881 if test "$HAVE_PTHREAD" = yes; then
10882 case "${canonical}" in
10883 *-hpux*) ;;
10884 *) LIB_PTHREAD="-lpthread"
10885 LIBS="$LIB_PTHREAD $LIBS" ;;
10886 esac
10888 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10894 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10895 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10896 $as_echo_n "(cached) " >&6
10897 else
10898 ac_check_lib_save_LIBS=$LIBS
10899 LIBS="-lpthreads $LIBS"
10900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10901 /* end confdefs.h. */
10903 /* Override any GCC internal prototype to avoid an error.
10904 Use char because int might match the return type of a GCC
10905 builtin and then its argument prototype would still apply. */
10906 #ifdef __cplusplus
10907 extern "C"
10908 #endif
10909 char cma_open ();
10911 main ()
10913 return cma_open ();
10915 return 0;
10917 _ACEOF
10918 if ac_fn_c_try_link "$LINENO"; then :
10919 ac_cv_lib_pthreads_cma_open=yes
10920 else
10921 ac_cv_lib_pthreads_cma_open=no
10923 rm -f core conftest.err conftest.$ac_objext \
10924 conftest$ac_exeext conftest.$ac_ext
10925 LIBS=$ac_check_lib_save_LIBS
10927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10928 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10929 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10930 cat >>confdefs.h <<_ACEOF
10931 #define HAVE_LIBPTHREADS 1
10932 _ACEOF
10934 LIBS="-lpthreads $LIBS"
10939 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10940 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10941 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10942 ## added to LIBS in configure would never contain the pthreads part,
10943 ## but the value used in Makefiles might. FIXME?
10945 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10946 ## be harmless on older versions of X where it happens to exist.
10947 test "$opsys" = "aix4-2" && \
10948 test $ac_cv_lib_pthreads_cma_open = yes && \
10949 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10952 case ${host_os} in
10953 aix*)
10954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10955 $as_echo_n "checking for -bbigtoc option... " >&6; }
10956 if test "${gdb_cv_bigtoc+set}" = set; then :
10957 $as_echo_n "(cached) " >&6
10958 else
10960 case $GCC in
10961 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10962 *) gdb_cv_bigtoc=-bbigtoc ;;
10963 esac
10965 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10967 /* end confdefs.h. */
10970 main ()
10972 int i;
10974 return 0;
10976 _ACEOF
10977 if ac_fn_c_try_link "$LINENO"; then :
10979 else
10980 gdb_cv_bigtoc=
10982 rm -f core conftest.err conftest.$ac_objext \
10983 conftest$ac_exeext conftest.$ac_ext
10986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10987 $as_echo "$gdb_cv_bigtoc" >&6; }
10989 esac
10991 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10992 # used for the tests that follow. We set them back to REAL_CFLAGS and
10993 # REAL_CPPFLAGS later on.
10995 REAL_CFLAGS="$CFLAGS"
10996 REAL_CPPFLAGS="$CPPFLAGS"
10998 if test "${HAVE_X11}" = "yes"; then
10999 DEFS="$C_SWITCH_X_SITE $DEFS"
11000 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
11001 LIBS="-lX11 $LIBS"
11002 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
11003 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
11005 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
11006 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
11007 # but it's more convenient here to set LD_RUN_PATH since this
11008 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
11009 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
11010 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
11011 export LD_RUN_PATH
11014 if test "${opsys}" = "gnu-linux"; then
11015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
11016 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
11017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11018 /* end confdefs.h. */
11021 main ()
11023 XOpenDisplay ("foo");
11025 return 0;
11027 _ACEOF
11028 if ac_fn_c_try_link "$LINENO"; then :
11029 xgnu_linux_first_failure=no
11030 else
11031 xgnu_linux_first_failure=yes
11033 rm -f core conftest.err conftest.$ac_objext \
11034 conftest$ac_exeext conftest.$ac_ext
11035 if test "${xgnu_linux_first_failure}" = "yes"; then
11036 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
11037 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
11038 OLD_CPPFLAGS="$CPPFLAGS"
11039 OLD_LIBS="$LIBS"
11040 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
11041 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
11042 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
11043 LIBS="$LIBS -b i486-linuxaout"
11044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11045 /* end confdefs.h. */
11048 main ()
11050 XOpenDisplay ("foo");
11052 return 0;
11054 _ACEOF
11055 if ac_fn_c_try_link "$LINENO"; then :
11056 xgnu_linux_second_failure=no
11057 else
11058 xgnu_linux_second_failure=yes
11060 rm -f core conftest.err conftest.$ac_objext \
11061 conftest$ac_exeext conftest.$ac_ext
11062 if test "${xgnu_linux_second_failure}" = "yes"; then
11063 # If we get the same failure with -b, there is no use adding -b.
11064 # So take it out. This plays safe.
11065 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11066 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11067 CPPFLAGS="$OLD_CPPFLAGS"
11068 LIBS="$OLD_LIBS"
11069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11070 $as_echo "no" >&6; }
11071 else
11072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11073 $as_echo "yes" >&6; }
11075 else
11076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11077 $as_echo "no" >&6; }
11081 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11082 # header files included from there.
11083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11084 $as_echo_n "checking for Xkb... " >&6; }
11085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11086 /* end confdefs.h. */
11087 #include <X11/Xlib.h>
11088 #include <X11/XKBlib.h>
11090 main ()
11092 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11094 return 0;
11096 _ACEOF
11097 if ac_fn_c_try_link "$LINENO"; then :
11098 emacs_xkb=yes
11099 else
11100 emacs_xkb=no
11102 rm -f core conftest.err conftest.$ac_objext \
11103 conftest$ac_exeext conftest.$ac_ext
11104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11105 $as_echo "$emacs_xkb" >&6; }
11106 if test $emacs_xkb = yes; then
11108 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11112 for ac_func in XrmSetDatabase XScreenResourceString \
11113 XScreenNumberOfScreen
11114 do :
11115 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11116 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11117 eval as_val=\$$as_ac_var
11118 if test "x$as_val" = x""yes; then :
11119 cat >>confdefs.h <<_ACEOF
11120 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11121 _ACEOF
11124 done
11128 if test "${window_system}" = "x11"; then
11129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11130 $as_echo_n "checking X11 version 6... " >&6; }
11131 if test "${emacs_cv_x11_version_6+set}" = set; then :
11132 $as_echo_n "(cached) " >&6
11133 else
11134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11135 /* end confdefs.h. */
11136 #include <X11/Xlib.h>
11138 main ()
11140 #if XlibSpecificationRelease < 6
11141 fail;
11142 #endif
11145 return 0;
11147 _ACEOF
11148 if ac_fn_c_try_link "$LINENO"; then :
11149 emacs_cv_x11_version_6=yes
11150 else
11151 emacs_cv_x11_version_6=no
11153 rm -f core conftest.err conftest.$ac_objext \
11154 conftest$ac_exeext conftest.$ac_ext
11157 if test $emacs_cv_x11_version_6 = yes; then
11158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11159 $as_echo "6 or newer" >&6; }
11161 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11164 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11166 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11167 ## XIM support.
11168 case "$opsys" in
11169 sol2-*) : ;;
11171 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11174 esac
11175 else
11176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11177 $as_echo "before 6" >&6; }
11182 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11183 HAVE_RSVG=no
11184 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11185 if test "${with_rsvg}" != "no"; then
11186 RSVG_REQUIRED=2.11.0
11187 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11190 succeeded=no
11192 if test "$PKG_CONFIG" = "no" ; then
11194 else
11195 PKG_CONFIG_MIN_VERSION=0.9.0
11196 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11198 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11200 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11201 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11202 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11203 edit_cflags="
11204 s,///*,/,g
11205 s/^/ /
11206 s/ -I/ $isystem/g
11207 s/^ //
11209 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11210 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11212 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11213 succeeded=yes
11214 else
11215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11216 $as_echo "no" >&6; }
11217 RSVG_CFLAGS=""
11218 RSVG_LIBS=""
11219 ## If we have a custom action on failure, don't print errors, but
11220 ## do set a variable so people can do so. Do it in a subshell
11221 ## to capture any diagnostics in invoking pkg-config.
11222 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11228 else
11229 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11230 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11234 if test $succeeded = yes; then
11235 HAVE_RSVG=yes
11236 else
11243 if test $HAVE_RSVG = yes; then
11245 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11247 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11248 LIBS="$RSVG_LIBS $LIBS"
11253 HAVE_IMAGEMAGICK=no
11254 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
11255 if test "${with_imagemagick}" != "no"; then
11256 ## 6.2.8 is the earliest version known to work, but earlier versions
11257 ## might work - let us know if you find one.
11258 ## 6.0.7 does not work. See bug#7955.
11259 ## 6.8.2 makes Emacs crash; see Bug#13867.
11260 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11262 succeeded=no
11264 if test "$PKG_CONFIG" = "no" ; then
11266 else
11267 PKG_CONFIG_MIN_VERSION=0.9.0
11268 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11270 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11272 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11273 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11274 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11275 edit_cflags="
11276 s,///*,/,g
11277 s/^/ /
11278 s/ -I/ $isystem/g
11279 s/^ //
11281 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11282 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11284 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11285 succeeded=yes
11286 else
11287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11288 $as_echo "no" >&6; }
11289 IMAGEMAGICK_CFLAGS=""
11290 IMAGEMAGICK_LIBS=""
11291 ## If we have a custom action on failure, don't print errors, but
11292 ## do set a variable so people can do so. Do it in a subshell
11293 ## to capture any diagnostics in invoking pkg-config.
11294 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11300 else
11301 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11302 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11306 if test $succeeded = yes; then
11307 HAVE_IMAGEMAGICK=yes
11308 else
11315 if test $HAVE_IMAGEMAGICK = yes; then
11317 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11319 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11320 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11321 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11322 do :
11323 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11324 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11325 eval as_val=\$$as_ac_var
11326 if test "x$as_val" = x""yes; then :
11327 cat >>confdefs.h <<_ACEOF
11328 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11329 _ACEOF
11332 done
11339 HAVE_GTK=no
11340 GTK_OBJ=
11341 gtk_term_header=$term_header
11342 check_gtk2=no
11343 gtk3_pkg_errors=
11344 if test "${opsys}" != "mingw32"; then
11345 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11346 GLIB_REQUIRED=2.28
11347 GTK_REQUIRED=3.0
11348 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11351 succeeded=no
11353 if test "$PKG_CONFIG" = "no" ; then
11354 pkg_check_gtk=no
11355 else
11356 PKG_CONFIG_MIN_VERSION=0.9.0
11357 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11359 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11361 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11362 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11363 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11364 edit_cflags="
11365 s,///*,/,g
11366 s/^/ /
11367 s/ -I/ $isystem/g
11368 s/^ //
11370 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11371 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11373 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11374 succeeded=yes
11375 else
11376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11377 $as_echo "no" >&6; }
11378 GTK_CFLAGS=""
11379 GTK_LIBS=""
11380 ## If we have a custom action on failure, don't print errors, but
11381 ## do set a variable so people can do so. Do it in a subshell
11382 ## to capture any diagnostics in invoking pkg-config.
11383 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11389 else
11390 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11391 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11395 if test $succeeded = yes; then
11396 pkg_check_gtk=yes
11397 else
11398 pkg_check_gtk=no
11401 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11402 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11404 if test "$pkg_check_gtk" = "yes"; then
11406 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11408 GTK_OBJ=emacsgtkfixed.o
11409 gtk_term_header=gtkutil.h
11410 USE_GTK_TOOLKIT="GTK3"
11411 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11412 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11413 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11415 else
11416 check_gtk2=yes
11417 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11421 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11422 GLIB_REQUIRED=2.10
11423 GTK_REQUIRED=2.10
11424 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11427 succeeded=no
11429 if test "$PKG_CONFIG" = "no" ; then
11430 pkg_check_gtk=no
11431 else
11432 PKG_CONFIG_MIN_VERSION=0.9.0
11433 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11435 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11437 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11438 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11439 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11440 edit_cflags="
11441 s,///*,/,g
11442 s/^/ /
11443 s/ -I/ $isystem/g
11444 s/^ //
11446 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11447 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11449 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11450 succeeded=yes
11451 else
11452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11453 $as_echo "no" >&6; }
11454 GTK_CFLAGS=""
11455 GTK_LIBS=""
11456 ## If we have a custom action on failure, don't print errors, but
11457 ## do set a variable so people can do so. Do it in a subshell
11458 ## to capture any diagnostics in invoking pkg-config.
11459 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11465 else
11466 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11467 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11471 if test $succeeded = yes; then
11472 pkg_check_gtk=yes
11473 else
11474 pkg_check_gtk=no
11477 if test "$pkg_check_gtk" = "no" &&
11478 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11479 then
11480 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11482 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11486 if test x"$pkg_check_gtk" = xyes; then
11490 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11491 CFLAGS="$CFLAGS $GTK_CFLAGS"
11492 LIBS="$GTK_LIBS $LIBS"
11493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GTK compiles" >&5
11494 $as_echo_n "checking whether GTK compiles... " >&6; }
11495 GTK_COMPILES=no
11496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11497 /* end confdefs.h. */
11498 /* Check the Gtk and Glib APIs. */
11499 #include <gtk/gtk.h>
11500 #include <glib-object.h>
11501 static void
11502 callback (GObject *go, GParamSpec *spec, gpointer user_data)
11506 main ()
11509 GtkSettings *gs = 0;
11510 /* Use G_CALLBACK to make sure function pointers can be cast to void *;
11511 strict C prohibits this. Use gtk_main_iteration to test that the
11512 libraries are there. */
11513 if (g_signal_handler_find (G_OBJECT (gs), G_SIGNAL_MATCH_FUNC,
11514 0, 0, 0, G_CALLBACK (callback), 0))
11515 gtk_main_iteration ();
11518 return 0;
11520 _ACEOF
11521 if ac_fn_c_try_link "$LINENO"; then :
11522 GTK_COMPILES=yes
11524 rm -f core conftest.err conftest.$ac_objext \
11525 conftest$ac_exeext conftest.$ac_ext
11526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_COMPILES" >&5
11527 $as_echo "$GTK_COMPILES" >&6; }
11528 if test "${GTK_COMPILES}" != "yes"; then
11529 GTK_OBJ=
11530 if test "$USE_X_TOOLKIT" != "maybe"; then
11531 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11533 else
11534 HAVE_GTK=yes
11536 $as_echo "#define USE_GTK 1" >>confdefs.h
11538 GTK_OBJ="gtkutil.o $GTK_OBJ"
11539 term_header=$gtk_term_header
11540 USE_X_TOOLKIT=none
11541 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11543 else
11544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11545 closing open displays. This is no problem if you just use
11546 one display, but if you use more than one and close one of them
11547 Emacs may crash." >&5
11548 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11549 closing open displays. This is no problem if you just use
11550 one display, but if you use more than one and close one of them
11551 Emacs may crash." >&2;}
11552 sleep 3
11560 if test "${HAVE_GTK}" = "yes"; then
11562 if test "$with_toolkit_scroll_bars" != no; then
11563 with_toolkit_scroll_bars=yes
11566 HAVE_GTK_FILE_SELECTION=no
11567 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11568 #include <gtk/gtk.h>
11570 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11571 HAVE_GTK_FILE_SELECTION=yes
11572 else
11573 HAVE_GTK_FILE_SELECTION=no
11576 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11577 for ac_func in gtk_file_selection_new
11578 do :
11579 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11580 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11581 cat >>confdefs.h <<_ACEOF
11582 #define HAVE_GTK_FILE_SELECTION_NEW 1
11583 _ACEOF
11586 done
11590 HAVE_GTK_HANDLE_BOX=no
11591 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11592 #include <gtk/gtk.h>
11594 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11595 HAVE_GTK_HANDLE_BOX=yes
11596 else
11597 HAVE_GTK_HANDLE_BOX=no
11600 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11601 for ac_func in gtk_handle_box_new
11602 do :
11603 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11604 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11605 cat >>confdefs.h <<_ACEOF
11606 #define HAVE_GTK_HANDLE_BOX_NEW 1
11607 _ACEOF
11610 done
11614 HAVE_GTK_TEAROFF_MENU_ITEM=no
11615 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11616 #include <gtk/gtk.h>
11618 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11619 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11620 else
11621 HAVE_GTK_TEAROFF_MENU_ITEM=no
11624 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11625 for ac_func in gtk_tearoff_menu_item_new
11626 do :
11627 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11628 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11629 cat >>confdefs.h <<_ACEOF
11630 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11631 _ACEOF
11634 done
11638 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11639 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11640 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11641 gtk_orientable_set_orientation \
11642 gtk_window_set_has_resize_grip
11643 do :
11644 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11645 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11646 eval as_val=\$$as_ac_var
11647 if test "x$as_val" = x""yes; then :
11648 cat >>confdefs.h <<_ACEOF
11649 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11650 _ACEOF
11653 done
11656 term_header=gtkutil.h
11659 HAVE_DBUS=no
11660 DBUS_OBJ=
11661 if test "${with_dbus}" = "yes"; then
11663 succeeded=no
11665 if test "$PKG_CONFIG" = "no" ; then
11666 HAVE_DBUS=no
11667 else
11668 PKG_CONFIG_MIN_VERSION=0.9.0
11669 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11671 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11673 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11674 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11675 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11676 edit_cflags="
11677 s,///*,/,g
11678 s/^/ /
11679 s/ -I/ $isystem/g
11680 s/^ //
11682 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11683 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11685 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11686 succeeded=yes
11687 else
11688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11689 $as_echo "no" >&6; }
11690 DBUS_CFLAGS=""
11691 DBUS_LIBS=""
11692 ## If we have a custom action on failure, don't print errors, but
11693 ## do set a variable so people can do so. Do it in a subshell
11694 ## to capture any diagnostics in invoking pkg-config.
11695 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11701 else
11702 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11703 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11707 if test $succeeded = yes; then
11708 HAVE_DBUS=yes
11709 else
11710 HAVE_DBUS=no
11713 if test "$HAVE_DBUS" = yes; then
11714 LIBS="$LIBS $DBUS_LIBS"
11716 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11718 for ac_func in dbus_watch_get_unix_fd \
11719 dbus_type_is_valid \
11720 dbus_validate_bus_name \
11721 dbus_validate_path \
11722 dbus_validate_interface \
11723 dbus_validate_member
11724 do :
11725 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11726 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11727 eval as_val=\$$as_ac_var
11728 if test "x$as_val" = x""yes; then :
11729 cat >>confdefs.h <<_ACEOF
11730 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11731 _ACEOF
11734 done
11736 DBUS_OBJ=dbusbind.o
11741 HAVE_GSETTINGS=no
11742 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11744 succeeded=no
11746 if test "$PKG_CONFIG" = "no" ; then
11747 HAVE_GSETTINGS=no
11748 else
11749 PKG_CONFIG_MIN_VERSION=0.9.0
11750 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11752 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11754 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11755 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11756 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11757 edit_cflags="
11758 s,///*,/,g
11759 s/^/ /
11760 s/ -I/ $isystem/g
11761 s/^ //
11763 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11764 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11766 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11767 succeeded=yes
11768 else
11769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11770 $as_echo "no" >&6; }
11771 GSETTINGS_CFLAGS=""
11772 GSETTINGS_LIBS=""
11773 ## If we have a custom action on failure, don't print errors, but
11774 ## do set a variable so people can do so. Do it in a subshell
11775 ## to capture any diagnostics in invoking pkg-config.
11776 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11782 else
11783 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11784 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11788 if test $succeeded = yes; then
11789 HAVE_GSETTINGS=yes
11790 else
11791 HAVE_GSETTINGS=no
11794 if test "$HAVE_GSETTINGS" = "yes"; then
11796 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11798 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11799 SETTINGS_LIBS="$GSETTINGS_LIBS"
11803 HAVE_GCONF=no
11804 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11806 succeeded=no
11808 if test "$PKG_CONFIG" = "no" ; then
11809 HAVE_GCONF=no
11810 else
11811 PKG_CONFIG_MIN_VERSION=0.9.0
11812 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11814 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11816 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
11817 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11818 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
11819 edit_cflags="
11820 s,///*,/,g
11821 s/^/ /
11822 s/ -I/ $isystem/g
11823 s/^ //
11825 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11826 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11828 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11829 succeeded=yes
11830 else
11831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11832 $as_echo "no" >&6; }
11833 GCONF_CFLAGS=""
11834 GCONF_LIBS=""
11835 ## If we have a custom action on failure, don't print errors, but
11836 ## do set a variable so people can do so. Do it in a subshell
11837 ## to capture any diagnostics in invoking pkg-config.
11838 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
11844 else
11845 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11846 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11850 if test $succeeded = yes; then
11851 HAVE_GCONF=yes
11852 else
11853 HAVE_GCONF=no
11856 if test "$HAVE_GCONF" = yes; then
11858 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11860 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11861 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11865 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11867 succeeded=no
11869 if test "$PKG_CONFIG" = "no" ; then
11870 HAVE_GOBJECT=no
11871 else
11872 PKG_CONFIG_MIN_VERSION=0.9.0
11873 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11875 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11877 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
11878 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11879 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
11880 edit_cflags="
11881 s,///*,/,g
11882 s/^/ /
11883 s/ -I/ $isystem/g
11884 s/^ //
11886 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11887 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11889 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11890 succeeded=yes
11891 else
11892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11893 $as_echo "no" >&6; }
11894 GOBJECT_CFLAGS=""
11895 GOBJECT_LIBS=""
11896 ## If we have a custom action on failure, don't print errors, but
11897 ## do set a variable so people can do so. Do it in a subshell
11898 ## to capture any diagnostics in invoking pkg-config.
11899 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
11905 else
11906 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11907 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11911 if test $succeeded = yes; then
11912 HAVE_GOBJECT=yes
11913 else
11914 HAVE_GOBJECT=no
11917 if test "$HAVE_GOBJECT" = "yes"; then
11918 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11919 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11921 SAVE_CFLAGS="$CFLAGS"
11922 SAVE_LIBS="$LIBS"
11923 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11924 LIBS="$SETTINGS_LIBS $LIBS"
11925 for ac_func in g_type_init
11926 do :
11927 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11928 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11929 cat >>confdefs.h <<_ACEOF
11930 #define HAVE_G_TYPE_INIT 1
11931 _ACEOF
11934 done
11936 CFLAGS="$SAVE_CFLAGS"
11937 LIBS="$SAVE_LIBS"
11943 HAVE_LIBSELINUX=no
11944 LIBSELINUX_LIBS=
11945 if test "${with_selinux}" = "yes"; then
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11947 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11948 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11949 $as_echo_n "(cached) " >&6
11950 else
11951 ac_check_lib_save_LIBS=$LIBS
11952 LIBS="-lselinux $LIBS"
11953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11954 /* end confdefs.h. */
11956 /* Override any GCC internal prototype to avoid an error.
11957 Use char because int might match the return type of a GCC
11958 builtin and then its argument prototype would still apply. */
11959 #ifdef __cplusplus
11960 extern "C"
11961 #endif
11962 char lgetfilecon ();
11964 main ()
11966 return lgetfilecon ();
11968 return 0;
11970 _ACEOF
11971 if ac_fn_c_try_link "$LINENO"; then :
11972 ac_cv_lib_selinux_lgetfilecon=yes
11973 else
11974 ac_cv_lib_selinux_lgetfilecon=no
11976 rm -f core conftest.err conftest.$ac_objext \
11977 conftest$ac_exeext conftest.$ac_ext
11978 LIBS=$ac_check_lib_save_LIBS
11980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11981 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11982 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11983 HAVE_LIBSELINUX=yes
11984 else
11985 HAVE_LIBSELINUX=no
11988 if test "$HAVE_LIBSELINUX" = yes; then
11990 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11992 LIBSELINUX_LIBS=-lselinux
11997 HAVE_GNUTLS=no
11998 if test "${with_gnutls}" = "yes" ; then
12000 succeeded=no
12002 if test "$PKG_CONFIG" = "no" ; then
12003 HAVE_GNUTLS=no
12004 else
12005 PKG_CONFIG_MIN_VERSION=0.9.0
12006 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
12008 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
12010 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
12011 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
12012 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
12013 edit_cflags="
12014 s,///*,/,g
12015 s/^/ /
12016 s/ -I/ $isystem/g
12017 s/^ //
12019 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
12020 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
12021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
12022 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
12023 succeeded=yes
12024 else
12025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12026 $as_echo "no" >&6; }
12027 LIBGNUTLS_CFLAGS=""
12028 LIBGNUTLS_LIBS=""
12029 ## If we have a custom action on failure, don't print errors, but
12030 ## do set a variable so people can do so. Do it in a subshell
12031 ## to capture any diagnostics in invoking pkg-config.
12032 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
12038 else
12039 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12040 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12044 if test $succeeded = yes; then
12045 HAVE_GNUTLS=yes
12046 else
12047 HAVE_GNUTLS=no
12050 if test "${HAVE_GNUTLS}" = "yes"; then
12052 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
12056 # Windows loads GnuTLS dynamically
12057 if test "${opsys}" = "mingw32"; then
12058 LIBGNUTLS_LIBS=
12059 else
12060 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
12061 LIBS="$LIBGNUTLS_LIBS $LIBS"
12068 NOTIFY_OBJ=
12069 NOTIFY_SUMMARY=no
12071 if test "${with_ns}" = yes && test ${with_file_notification} = yes; then
12072 with_file_notification=no
12075 case $with_file_notification,$opsys in
12076 w32,* | yes,mingw32)
12077 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12078 if test "x$ac_cv_header_windows_h" = x""yes; then :
12083 if test "$ac_cv_header_windows_h" = yes ; then
12085 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12087 NOTIFY_OBJ=w32notify.o
12088 NOTIFY_SUMMARY="yes (w32)"
12089 fi ;;
12090 esac
12092 case $with_file_notification,$NOTIFY_OBJ in
12093 gfile, | yes,)
12095 succeeded=no
12097 if test "$PKG_CONFIG" = "no" ; then
12098 HAVE_GFILENOTIFY=no
12099 else
12100 PKG_CONFIG_MIN_VERSION=0.9.0
12101 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12103 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12105 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12106 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12107 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12108 edit_cflags="
12109 s,///*,/,g
12110 s/^/ /
12111 s/ -I/ $isystem/g
12112 s/^ //
12114 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12115 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12117 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12118 succeeded=yes
12119 else
12120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12121 $as_echo "no" >&6; }
12122 GFILENOTIFY_CFLAGS=""
12123 GFILENOTIFY_LIBS=""
12124 ## If we have a custom action on failure, don't print errors, but
12125 ## do set a variable so people can do so. Do it in a subshell
12126 ## to capture any diagnostics in invoking pkg-config.
12127 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12133 else
12134 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12135 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12139 if test $succeeded = yes; then
12140 HAVE_GFILENOTIFY=yes
12141 else
12142 HAVE_GFILENOTIFY=no
12145 if test "$HAVE_GFILENOTIFY" = "yes"; then
12147 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12149 NOTIFY_OBJ=gfilenotify.o
12150 NOTIFY_SUMMARY="yes -lgio (gfile)"
12151 fi ;;
12152 esac
12154 case $with_file_notification,$NOTIFY_OBJ in
12155 inotify, | yes,)
12156 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12157 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12162 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12163 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12164 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12168 if test "$ac_cv_func_inotify_init1" = yes; then
12170 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12172 NOTIFY_OBJ=inotify.o
12173 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12175 fi ;;
12176 esac
12178 case $with_file_notification,$NOTIFY_OBJ in
12179 yes,* | no,* | *,?*) ;;
12180 *) as_fn_error "File notification \`$with_file_notification' requested but requirements not found." "$LINENO" 5 ;;
12181 esac
12183 if test -n "$NOTIFY_OBJ"; then
12185 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12192 HAVE_XAW3D=no
12193 LUCID_LIBW=
12194 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12195 if test "$with_xaw3d" != no; then
12196 if test "${emacs_cv_xaw3d+set}" = set; then :
12197 $as_echo_n "(cached) " >&6
12198 else
12199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12200 /* end confdefs.h. */
12202 #include <X11/Intrinsic.h>
12203 #include <X11/Xaw3d/Simple.h>
12205 main ()
12209 return 0;
12211 _ACEOF
12212 if ac_fn_c_try_link "$LINENO"; then :
12213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12214 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12215 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12216 $as_echo_n "(cached) " >&6
12217 else
12218 ac_check_lib_save_LIBS=$LIBS
12219 LIBS="-lXaw3d $LIBS"
12220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12221 /* end confdefs.h. */
12223 /* Override any GCC internal prototype to avoid an error.
12224 Use char because int might match the return type of a GCC
12225 builtin and then its argument prototype would still apply. */
12226 #ifdef __cplusplus
12227 extern "C"
12228 #endif
12229 char XawScrollbarSetThumb ();
12231 main ()
12233 return XawScrollbarSetThumb ();
12235 return 0;
12237 _ACEOF
12238 if ac_fn_c_try_link "$LINENO"; then :
12239 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12240 else
12241 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12243 rm -f core conftest.err conftest.$ac_objext \
12244 conftest$ac_exeext conftest.$ac_ext
12245 LIBS=$ac_check_lib_save_LIBS
12247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12248 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12249 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12250 emacs_cv_xaw3d=yes
12251 else
12252 emacs_cv_xaw3d=no
12255 else
12256 emacs_cv_xaw3d=no
12258 rm -f core conftest.err conftest.$ac_objext \
12259 conftest$ac_exeext conftest.$ac_ext
12262 else
12263 emacs_cv_xaw3d=no
12265 if test $emacs_cv_xaw3d = yes; then
12266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12267 $as_echo_n "checking for xaw3d... " >&6; }
12268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12269 $as_echo "yes; using Lucid toolkit" >&6; }
12270 USE_X_TOOLKIT=LUCID
12271 HAVE_XAW3D=yes
12272 LUCID_LIBW=-lXaw3d
12274 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12276 else
12277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12278 $as_echo_n "checking for xaw3d... " >&6; }
12279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12280 $as_echo "no" >&6; }
12281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12282 $as_echo_n "checking for libXaw... " >&6; }
12283 if test "${emacs_cv_xaw+set}" = set; then :
12284 $as_echo_n "(cached) " >&6
12285 else
12286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12287 /* end confdefs.h. */
12289 #include <X11/Intrinsic.h>
12290 #include <X11/Xaw/Simple.h>
12292 main ()
12296 return 0;
12298 _ACEOF
12299 if ac_fn_c_try_link "$LINENO"; then :
12300 emacs_cv_xaw=yes
12301 else
12302 emacs_cv_xaw=no
12304 rm -f core conftest.err conftest.$ac_objext \
12305 conftest$ac_exeext conftest.$ac_ext
12308 if test $emacs_cv_xaw = yes; then
12309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12310 $as_echo "yes; using Lucid toolkit" >&6; }
12311 USE_X_TOOLKIT=LUCID
12312 LUCID_LIBW=-lXaw
12313 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12314 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12315 else
12316 as_fn_error "No X toolkit could be found.
12317 If you are sure you want Emacs compiled without an X toolkit, pass
12318 --with-x-toolkit=no
12319 to configure. Otherwise, install the development libraries for the toolkit
12320 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12325 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12327 LIBXTR6=
12328 if test "${USE_X_TOOLKIT}" != "none"; then
12329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12330 $as_echo_n "checking X11 toolkit version... " >&6; }
12331 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12332 $as_echo_n "(cached) " >&6
12333 else
12334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12335 /* end confdefs.h. */
12336 #include <X11/Intrinsic.h>
12338 main ()
12340 #if XtSpecificationRelease < 6
12341 fail;
12342 #endif
12345 return 0;
12347 _ACEOF
12348 if ac_fn_c_try_link "$LINENO"; then :
12349 emacs_cv_x11_toolkit_version_6=yes
12350 else
12351 emacs_cv_x11_toolkit_version_6=no
12353 rm -f core conftest.err conftest.$ac_objext \
12354 conftest$ac_exeext conftest.$ac_ext
12357 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12358 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12360 $as_echo "6 or newer" >&6; }
12362 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12364 LIBXTR6="-lSM -lICE"
12365 case "$opsys" in
12366 ## Use libw.a along with X11R6 Xt.
12367 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12368 esac
12369 else
12370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12371 $as_echo "before 6" >&6; }
12374 OLDLIBS="$LIBS"
12375 if test x$HAVE_X11XTR6 = xyes; then
12376 LIBS="-lXt -lSM -lICE $LIBS"
12377 else
12378 LIBS="-lXt $LIBS"
12380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12381 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12382 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12383 $as_echo_n "(cached) " >&6
12384 else
12385 ac_check_lib_save_LIBS=$LIBS
12386 LIBS="-lXmu $LIBS"
12387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12388 /* end confdefs.h. */
12390 /* Override any GCC internal prototype to avoid an error.
12391 Use char because int might match the return type of a GCC
12392 builtin and then its argument prototype would still apply. */
12393 #ifdef __cplusplus
12394 extern "C"
12395 #endif
12396 char XmuConvertStandardSelection ();
12398 main ()
12400 return XmuConvertStandardSelection ();
12402 return 0;
12404 _ACEOF
12405 if ac_fn_c_try_link "$LINENO"; then :
12406 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12407 else
12408 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12410 rm -f core conftest.err conftest.$ac_objext \
12411 conftest$ac_exeext conftest.$ac_ext
12412 LIBS=$ac_check_lib_save_LIBS
12414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12415 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12416 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12417 cat >>confdefs.h <<_ACEOF
12418 #define HAVE_LIBXMU 1
12419 _ACEOF
12421 LIBS="-lXmu $LIBS"
12425 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12429 LIBXMU=-lXmu
12430 case $opsys in
12431 ## These systems don't supply Xmu.
12432 hpux* | aix4-2 )
12433 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12435 mingw32 )
12436 LIBXMU=
12438 esac
12441 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12442 if test "${HAVE_X11}" = "yes"; then
12443 if test "${USE_X_TOOLKIT}" != "none"; then
12444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12445 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12446 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12447 $as_echo_n "(cached) " >&6
12448 else
12449 ac_check_lib_save_LIBS=$LIBS
12450 LIBS="-lXext $LIBS"
12451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12452 /* end confdefs.h. */
12454 /* Override any GCC internal prototype to avoid an error.
12455 Use char because int might match the return type of a GCC
12456 builtin and then its argument prototype would still apply. */
12457 #ifdef __cplusplus
12458 extern "C"
12459 #endif
12460 char XShapeQueryExtension ();
12462 main ()
12464 return XShapeQueryExtension ();
12466 return 0;
12468 _ACEOF
12469 if ac_fn_c_try_link "$LINENO"; then :
12470 ac_cv_lib_Xext_XShapeQueryExtension=yes
12471 else
12472 ac_cv_lib_Xext_XShapeQueryExtension=no
12474 rm -f core conftest.err conftest.$ac_objext \
12475 conftest$ac_exeext conftest.$ac_ext
12476 LIBS=$ac_check_lib_save_LIBS
12478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12479 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12480 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12481 cat >>confdefs.h <<_ACEOF
12482 #define HAVE_LIBXEXT 1
12483 _ACEOF
12485 LIBS="-lXext $LIBS"
12492 LIBXP=
12493 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12494 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12495 if test -d /usr/include/openmotif; then
12496 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12497 emacs_cv_openmotif=yes
12498 case "$canonical" in
12499 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12500 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12503 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12504 esac
12505 else
12506 emacs_cv_openmotif=no
12508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12509 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12510 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12511 $as_echo_n "(cached) " >&6
12512 else
12513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12514 /* end confdefs.h. */
12515 #include <Xm/Xm.h>
12517 main ()
12519 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12520 int x = 5;
12521 #else
12522 Motif version prior to 2.1.
12523 #endif
12525 return 0;
12527 _ACEOF
12528 if ac_fn_c_try_compile "$LINENO"; then :
12529 emacs_cv_motif_version_2_1=yes
12530 else
12531 emacs_cv_motif_version_2_1=no
12533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12536 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12537 if test $emacs_cv_motif_version_2_1 = yes; then
12538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12539 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12540 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12541 $as_echo_n "(cached) " >&6
12542 else
12543 ac_check_lib_save_LIBS=$LIBS
12544 LIBS="-lXp $LIBS"
12545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12546 /* end confdefs.h. */
12548 /* Override any GCC internal prototype to avoid an error.
12549 Use char because int might match the return type of a GCC
12550 builtin and then its argument prototype would still apply. */
12551 #ifdef __cplusplus
12552 extern "C"
12553 #endif
12554 char XpCreateContext ();
12556 main ()
12558 return XpCreateContext ();
12560 return 0;
12562 _ACEOF
12563 if ac_fn_c_try_link "$LINENO"; then :
12564 ac_cv_lib_Xp_XpCreateContext=yes
12565 else
12566 ac_cv_lib_Xp_XpCreateContext=no
12568 rm -f core conftest.err conftest.$ac_objext \
12569 conftest$ac_exeext conftest.$ac_ext
12570 LIBS=$ac_check_lib_save_LIBS
12572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12573 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12574 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12575 LIBXP=-lXp
12578 if test x$emacs_cv_openmotif = xyes; then
12579 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12581 else
12582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12583 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12584 if test "${emacs_cv_lesstif+set}" = set; then :
12585 $as_echo_n "(cached) " >&6
12586 else
12587 # We put this in CFLAGS temporarily to precede other -I options
12588 # that might be in CFLAGS temporarily.
12589 # We put this in CPPFLAGS where it precedes the other -I options.
12590 OLD_CPPFLAGS=$CPPFLAGS
12591 OLD_CFLAGS=$CFLAGS
12592 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12593 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12595 /* end confdefs.h. */
12596 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12598 main ()
12600 int x = 5;
12602 return 0;
12604 _ACEOF
12605 if ac_fn_c_try_compile "$LINENO"; then :
12606 emacs_cv_lesstif=yes
12607 else
12608 emacs_cv_lesstif=no
12610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12613 $as_echo "$emacs_cv_lesstif" >&6; }
12614 if test $emacs_cv_lesstif = yes; then
12615 # Make sure this -I option remains in CPPFLAGS after it is set
12616 # back to REAL_CPPFLAGS.
12617 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12618 # have those other -I options anyway. Ultimately, having this
12619 # directory ultimately in CPPFLAGS will be enough.
12620 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12621 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12622 else
12623 CFLAGS=$OLD_CFLAGS
12624 CPPFLAGS=$OLD_CPPFLAGS
12627 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12628 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12630 else
12631 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12638 USE_TOOLKIT_SCROLL_BARS=no
12639 if test "${with_toolkit_scroll_bars}" != "no"; then
12640 if test "${USE_X_TOOLKIT}" != "none"; then
12641 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12642 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12644 HAVE_XAW3D=no
12645 USE_TOOLKIT_SCROLL_BARS=yes
12646 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12647 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12649 USE_TOOLKIT_SCROLL_BARS=yes
12651 elif test "${HAVE_GTK}" = "yes"; then
12652 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12654 USE_TOOLKIT_SCROLL_BARS=yes
12655 elif test "${HAVE_NS}" = "yes"; then
12656 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12658 USE_TOOLKIT_SCROLL_BARS=yes
12659 elif test "${HAVE_W32}" = "yes"; then
12660 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12662 USE_TOOLKIT_SCROLL_BARS=yes
12666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12667 /* end confdefs.h. */
12669 #include <X11/Xlib.h>
12670 #include <X11/Xresource.h>
12672 main ()
12674 XIMProc callback;
12676 return 0;
12678 _ACEOF
12679 if ac_fn_c_try_compile "$LINENO"; then :
12680 HAVE_XIM=yes
12682 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12684 else
12685 HAVE_XIM=no
12687 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12690 if test "${with_xim}" != "no"; then
12692 $as_echo "#define USE_XIM 1" >>confdefs.h
12697 if test "${HAVE_XIM}" != "no"; then
12698 late_CFLAGS=$CFLAGS
12699 if test "$GCC" = yes; then
12700 CFLAGS="$CFLAGS --pedantic-errors"
12702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12703 /* end confdefs.h. */
12705 #include <X11/Xlib.h>
12706 #include <X11/Xresource.h>
12708 main ()
12710 Display *display;
12711 XrmDatabase db;
12712 char *res_name;
12713 char *res_class;
12714 XIMProc callback;
12715 XPointer *client_data;
12716 #ifndef __GNUC__
12717 /* If we're not using GCC, it's probably not XFree86, and this is
12718 probably right, but we can't use something like --pedantic-errors. */
12719 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12720 char*, XIMProc, XPointer*);
12721 #endif
12722 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12723 client_data);
12725 return 0;
12727 _ACEOF
12728 if ac_fn_c_try_compile "$LINENO"; then :
12729 emacs_cv_arg6_star=yes
12731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12732 if test "$emacs_cv_arg6_star" = yes; then
12733 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12735 else
12736 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12739 CFLAGS=$late_CFLAGS
12742 ### Start of font-backend (under any platform) section.
12743 # (nothing here yet -- this is a placeholder)
12744 ### End of font-backend (under any platform) section.
12746 ### Start of font-backend (under X11) section.
12747 if test "${HAVE_X11}" = "yes"; then
12749 succeeded=no
12751 if test "$PKG_CONFIG" = "no" ; then
12752 HAVE_FC=no
12753 else
12754 PKG_CONFIG_MIN_VERSION=0.9.0
12755 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12757 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12759 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12760 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12761 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12762 edit_cflags="
12763 s,///*,/,g
12764 s/^/ /
12765 s/ -I/ $isystem/g
12766 s/^ //
12768 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12769 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12771 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12772 succeeded=yes
12773 else
12774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12775 $as_echo "no" >&6; }
12776 FONTCONFIG_CFLAGS=""
12777 FONTCONFIG_LIBS=""
12778 ## If we have a custom action on failure, don't print errors, but
12779 ## do set a variable so people can do so. Do it in a subshell
12780 ## to capture any diagnostics in invoking pkg-config.
12781 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12787 else
12788 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12789 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12793 if test $succeeded = yes; then
12794 HAVE_FC=yes
12795 else
12796 HAVE_FC=no
12800 ## Use -lXft if available, unless `--with-xft=no'.
12801 HAVE_XFT=maybe
12802 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12803 with_xft="no";
12805 if test "x${with_xft}" != "xno"; then
12808 succeeded=no
12810 if test "$PKG_CONFIG" = "no" ; then
12811 HAVE_XFT=no
12812 else
12813 PKG_CONFIG_MIN_VERSION=0.9.0
12814 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12816 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12818 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
12819 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
12820 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
12821 edit_cflags="
12822 s,///*,/,g
12823 s/^/ /
12824 s/ -I/ $isystem/g
12825 s/^ //
12827 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
12828 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12830 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12831 succeeded=yes
12832 else
12833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12834 $as_echo "no" >&6; }
12835 XFT_CFLAGS=""
12836 XFT_LIBS=""
12837 ## If we have a custom action on failure, don't print errors, but
12838 ## do set a variable so people can do so. Do it in a subshell
12839 ## to capture any diagnostics in invoking pkg-config.
12840 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
12846 else
12847 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12848 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12852 if test $succeeded = yes; then
12854 else
12855 HAVE_XFT=no
12858 ## Because xftfont.c uses XRenderQueryExtension, we also
12859 ## need to link to -lXrender.
12860 HAVE_XRENDER=no
12861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12862 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12863 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12864 $as_echo_n "(cached) " >&6
12865 else
12866 ac_check_lib_save_LIBS=$LIBS
12867 LIBS="-lXrender $LIBS"
12868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12869 /* end confdefs.h. */
12871 /* Override any GCC internal prototype to avoid an error.
12872 Use char because int might match the return type of a GCC
12873 builtin and then its argument prototype would still apply. */
12874 #ifdef __cplusplus
12875 extern "C"
12876 #endif
12877 char XRenderQueryExtension ();
12879 main ()
12881 return XRenderQueryExtension ();
12883 return 0;
12885 _ACEOF
12886 if ac_fn_c_try_link "$LINENO"; then :
12887 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12888 else
12889 ac_cv_lib_Xrender_XRenderQueryExtension=no
12891 rm -f core conftest.err conftest.$ac_objext \
12892 conftest$ac_exeext conftest.$ac_ext
12893 LIBS=$ac_check_lib_save_LIBS
12895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12896 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12897 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12898 HAVE_XRENDER=yes
12901 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12902 OLD_CPPFLAGS="$CPPFLAGS"
12903 OLD_CFLAGS="$CFLAGS"
12904 OLD_LIBS="$LIBS"
12905 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12906 CFLAGS="$CFLAGS $XFT_CFLAGS"
12907 XFT_LIBS="-lXrender $XFT_LIBS"
12908 LIBS="$XFT_LIBS $LIBS"
12909 ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/X.h>
12911 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12913 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12914 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12915 $as_echo_n "(cached) " >&6
12916 else
12917 ac_check_lib_save_LIBS=$LIBS
12918 LIBS="-lXft $XFT_LIBS $LIBS"
12919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12920 /* end confdefs.h. */
12922 /* Override any GCC internal prototype to avoid an error.
12923 Use char because int might match the return type of a GCC
12924 builtin and then its argument prototype would still apply. */
12925 #ifdef __cplusplus
12926 extern "C"
12927 #endif
12928 char XftFontOpen ();
12930 main ()
12932 return XftFontOpen ();
12934 return 0;
12936 _ACEOF
12937 if ac_fn_c_try_link "$LINENO"; then :
12938 ac_cv_lib_Xft_XftFontOpen=yes
12939 else
12940 ac_cv_lib_Xft_XftFontOpen=no
12942 rm -f core conftest.err conftest.$ac_objext \
12943 conftest$ac_exeext conftest.$ac_ext
12944 LIBS=$ac_check_lib_save_LIBS
12946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12947 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12948 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12949 HAVE_XFT=yes
12956 if test "${HAVE_XFT}" = "yes"; then
12958 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12961 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12962 else
12963 CPPFLAGS="$OLD_CPPFLAGS"
12964 CFLAGS="$OLD_CFLAGS"
12965 LIBS="$OLD_LIBS"
12966 fi # "${HAVE_XFT}" = "yes"
12967 fi # "$HAVE_XFT" != no
12968 fi # "x${with_xft}" != "xno"
12970 ## We used to allow building with FreeType and without Xft.
12971 ## However, the ftx font backend driver is not in good shape.
12972 if test "$HAVE_XFT" != "yes"; then
12973 HAVE_XFT=no
12974 HAVE_FREETYPE=no
12975 else
12977 succeeded=no
12979 if test "$PKG_CONFIG" = "no" ; then
12980 HAVE_FREETYPE=no
12981 else
12982 PKG_CONFIG_MIN_VERSION=0.9.0
12983 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12985 $as_echo_n "checking for freetype2... " >&6; }
12987 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
12988 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
12989 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
12990 edit_cflags="
12991 s,///*,/,g
12992 s/^/ /
12993 s/ -I/ $isystem/g
12994 s/^ //
12996 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12997 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12999 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
13000 succeeded=yes
13001 else
13002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13003 $as_echo "no" >&6; }
13004 FREETYPE_CFLAGS=""
13005 FREETYPE_LIBS=""
13006 ## If we have a custom action on failure, don't print errors, but
13007 ## do set a variable so people can do so. Do it in a subshell
13008 ## to capture any diagnostics in invoking pkg-config.
13009 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
13015 else
13016 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13017 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13021 if test $succeeded = yes; then
13022 HAVE_FREETYPE=yes
13023 else
13024 HAVE_FREETYPE=no
13028 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
13031 HAVE_LIBOTF=no
13032 if test "${HAVE_FREETYPE}" = "yes"; then
13034 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
13036 if test "${with_libotf}" != "no"; then
13038 succeeded=no
13040 if test "$PKG_CONFIG" = "no" ; then
13041 HAVE_LIBOTF=no
13042 else
13043 PKG_CONFIG_MIN_VERSION=0.9.0
13044 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
13046 $as_echo_n "checking for libotf... " >&6; }
13048 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13049 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13050 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13051 edit_cflags="
13052 s,///*,/,g
13053 s/^/ /
13054 s/ -I/ $isystem/g
13055 s/^ //
13057 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13058 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13060 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13061 succeeded=yes
13062 else
13063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13064 $as_echo "no" >&6; }
13065 LIBOTF_CFLAGS=""
13066 LIBOTF_LIBS=""
13067 ## If we have a custom action on failure, don't print errors, but
13068 ## do set a variable so people can do so. Do it in a subshell
13069 ## to capture any diagnostics in invoking pkg-config.
13070 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13076 else
13077 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13078 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13082 if test $succeeded = yes; then
13083 HAVE_LIBOTF=yes
13084 else
13085 HAVE_LIBOTF=no
13088 if test "$HAVE_LIBOTF" = "yes"; then
13090 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13093 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13094 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13095 $as_echo_n "(cached) " >&6
13096 else
13097 ac_check_lib_save_LIBS=$LIBS
13098 LIBS="-lotf $LIBS"
13099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13100 /* end confdefs.h. */
13102 /* Override any GCC internal prototype to avoid an error.
13103 Use char because int might match the return type of a GCC
13104 builtin and then its argument prototype would still apply. */
13105 #ifdef __cplusplus
13106 extern "C"
13107 #endif
13108 char OTF_get_variation_glyphs ();
13110 main ()
13112 return OTF_get_variation_glyphs ();
13114 return 0;
13116 _ACEOF
13117 if ac_fn_c_try_link "$LINENO"; then :
13118 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13119 else
13120 ac_cv_lib_otf_OTF_get_variation_glyphs=no
13122 rm -f core conftest.err conftest.$ac_objext \
13123 conftest$ac_exeext conftest.$ac_ext
13124 LIBS=$ac_check_lib_save_LIBS
13126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
13127 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13128 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13129 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13130 else
13131 HAVE_OTF_GET_VARIATION_GLYPHS=no
13134 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13136 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13143 HAVE_M17N_FLT=no
13144 if test "${HAVE_LIBOTF}" = yes; then
13145 if test "${with_m17n_flt}" != "no"; then
13147 succeeded=no
13149 if test "$PKG_CONFIG" = "no" ; then
13150 HAVE_M17N_FLT=no
13151 else
13152 PKG_CONFIG_MIN_VERSION=0.9.0
13153 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13155 $as_echo_n "checking for m17n-flt... " >&6; }
13157 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13158 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13159 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13160 edit_cflags="
13161 s,///*,/,g
13162 s/^/ /
13163 s/ -I/ $isystem/g
13164 s/^ //
13166 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13167 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13169 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13170 succeeded=yes
13171 else
13172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13173 $as_echo "no" >&6; }
13174 M17N_FLT_CFLAGS=""
13175 M17N_FLT_LIBS=""
13176 ## If we have a custom action on failure, don't print errors, but
13177 ## do set a variable so people can do so. Do it in a subshell
13178 ## to capture any diagnostics in invoking pkg-config.
13179 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13185 else
13186 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13187 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13191 if test $succeeded = yes; then
13192 HAVE_M17N_FLT=yes
13193 else
13194 HAVE_M17N_FLT=no
13197 if test "$HAVE_M17N_FLT" = "yes"; then
13199 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13204 else
13205 HAVE_XFT=no
13206 HAVE_FREETYPE=no
13207 HAVE_LIBOTF=no
13208 HAVE_M17N_FLT=no
13211 ### End of font-backend (under X11) section.
13222 ### Use -lXpm if available, unless `--with-xpm=no'.
13223 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13224 HAVE_XPM=no
13225 LIBXPM=
13226 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13227 if test "${with_xpm}" != "no"; then
13228 SAVE_CPPFLAGS="$CPPFLAGS"
13229 SAVE_LDFLAGS="$LDFLAGS"
13230 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13231 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13232 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13233 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13235 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13236 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13237 $as_echo_n "(cached) " >&6
13238 else
13239 ac_check_lib_save_LIBS=$LIBS
13240 LIBS="-lXpm $LIBS"
13241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13242 /* end confdefs.h. */
13244 /* Override any GCC internal prototype to avoid an error.
13245 Use char because int might match the return type of a GCC
13246 builtin and then its argument prototype would still apply. */
13247 #ifdef __cplusplus
13248 extern "C"
13249 #endif
13250 char XpmReadFileToImage ();
13252 main ()
13254 return XpmReadFileToImage ();
13256 return 0;
13258 _ACEOF
13259 if ac_fn_c_try_link "$LINENO"; then :
13260 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13261 else
13262 ac_cv_lib_Xpm_XpmReadFileToImage=no
13264 rm -f core conftest.err conftest.$ac_objext \
13265 conftest$ac_exeext conftest.$ac_ext
13266 LIBS=$ac_check_lib_save_LIBS
13268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13269 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13270 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13271 HAVE_XPM=yes
13277 if test "${HAVE_XPM}" = "yes"; then
13278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13279 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13281 /* end confdefs.h. */
13282 #include "X11/xpm.h"
13283 #ifndef XpmReturnAllocPixels
13284 no_return_alloc_pixels
13285 #endif
13287 _ACEOF
13288 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13289 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13290 HAVE_XPM=no
13291 else
13292 HAVE_XPM=yes
13294 rm -f conftest*
13297 if test "${HAVE_XPM}" = "yes"; then
13298 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13300 $as_echo "yes" >&6; }
13301 else
13302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13303 $as_echo "no" >&6; }
13304 CPPFLAGS="$SAVE_CPPFLAGS"
13305 LDFLAGS="$SAVE_LDFLAGS"
13310 if test "${HAVE_XPM}" = "yes"; then
13312 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13314 LIBXPM=-lXpm
13318 if test "${HAVE_X11}" = "yes"; then
13319 if test "${with_xpm}" != "no"; then
13320 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13321 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13323 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13324 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13325 $as_echo_n "(cached) " >&6
13326 else
13327 ac_check_lib_save_LIBS=$LIBS
13328 LIBS="-lXpm -lX11 $LIBS"
13329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13330 /* end confdefs.h. */
13332 /* Override any GCC internal prototype to avoid an error.
13333 Use char because int might match the return type of a GCC
13334 builtin and then its argument prototype would still apply. */
13335 #ifdef __cplusplus
13336 extern "C"
13337 #endif
13338 char XpmReadFileToPixmap ();
13340 main ()
13342 return XpmReadFileToPixmap ();
13344 return 0;
13346 _ACEOF
13347 if ac_fn_c_try_link "$LINENO"; then :
13348 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13349 else
13350 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13352 rm -f core conftest.err conftest.$ac_objext \
13353 conftest$ac_exeext conftest.$ac_ext
13354 LIBS=$ac_check_lib_save_LIBS
13356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13357 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13358 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13359 HAVE_XPM=yes
13365 if test "${HAVE_XPM}" = "yes"; then
13366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13367 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13369 /* end confdefs.h. */
13370 #include "X11/xpm.h"
13371 #ifndef XpmReturnAllocPixels
13372 no_return_alloc_pixels
13373 #endif
13375 _ACEOF
13376 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13377 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13378 HAVE_XPM=no
13379 else
13380 HAVE_XPM=yes
13382 rm -f conftest*
13385 if test "${HAVE_XPM}" = "yes"; then
13386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13387 $as_echo "yes" >&6; }
13388 else
13389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13390 $as_echo "no" >&6; }
13395 if test "${HAVE_XPM}" = "yes"; then
13397 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13399 LIBXPM=-lXpm
13403 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13404 ### slightly different requirements wrt image libraries (it doesn't
13405 ### use -lXpm because it loads the xpm shared library dynamically at
13406 ### run time).
13407 if test "${opsys}" = "mingw32"; then
13408 if test "${with_xpm}" != "no"; then
13409 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13410 #define FOR_MSW 1
13412 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13413 HAVE_XPM=yes
13414 else
13415 HAVE_XPM=no
13421 if test "${HAVE_XPM}" = "yes"; then
13423 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13430 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13431 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13432 HAVE_JPEG=no
13433 LIBJPEG=
13434 if test "${opsys}" = "mingw32"; then
13435 if test "${with_jpeg}" != "no"; then
13436 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13437 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13438 HAVE_JPEG=yes
13439 else
13440 HAVE_JPEG=no
13445 if test "${HAVE_JPEG}" = "yes"; then
13446 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13449 /* end confdefs.h. */
13450 #include <jpeglib.h>
13451 version=JPEG_LIB_VERSION
13453 _ACEOF
13454 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13455 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13456 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13458 else
13459 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13460 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13461 HAVE_JPEG=no
13463 rm -f conftest*
13466 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13467 if test "${with_jpeg}" != "no"; then
13468 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13469 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13471 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13472 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13473 $as_echo_n "(cached) " >&6
13474 else
13475 ac_check_lib_save_LIBS=$LIBS
13476 LIBS="-ljpeg $LIBS"
13477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13478 /* end confdefs.h. */
13480 /* Override any GCC internal prototype to avoid an error.
13481 Use char because int might match the return type of a GCC
13482 builtin and then its argument prototype would still apply. */
13483 #ifdef __cplusplus
13484 extern "C"
13485 #endif
13486 char jpeg_destroy_compress ();
13488 main ()
13490 return jpeg_destroy_compress ();
13492 return 0;
13494 _ACEOF
13495 if ac_fn_c_try_link "$LINENO"; then :
13496 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13497 else
13498 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13500 rm -f core conftest.err conftest.$ac_objext \
13501 conftest$ac_exeext conftest.$ac_ext
13502 LIBS=$ac_check_lib_save_LIBS
13504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13505 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13506 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13507 HAVE_JPEG=yes
13515 if test "${HAVE_JPEG}" = "yes"; then
13516 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13519 /* end confdefs.h. */
13520 #include <jpeglib.h>
13521 version=JPEG_LIB_VERSION
13523 _ACEOF
13524 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13525 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13526 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13528 else
13529 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13530 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13531 HAVE_JPEG=no
13533 rm -f conftest*
13536 if test "${HAVE_JPEG}" = "yes"; then
13537 LIBJPEG=-ljpeg
13542 ### Use -lpng if available, unless `--with-png=no'.
13543 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13544 HAVE_PNG=no
13545 LIBPNG=
13546 if test "${opsys}" = "mingw32"; then
13547 if test "${with_png}" != "no"; then
13548 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13549 if test "x$ac_cv_header_png_h" = x""yes; then :
13550 HAVE_PNG=yes
13551 else
13552 HAVE_PNG=no
13557 if test "${HAVE_PNG}" = "yes"; then
13559 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13562 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13563 # include <libpng/png.h>
13564 #else
13565 # include <png.h>
13566 #endif
13569 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13571 else
13573 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13578 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13579 if test "${with_png}" != "no"; then
13580 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13581 # in /usr/include/libpng.
13582 for ac_header in png.h libpng/png.h
13583 do :
13584 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13585 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13586 eval as_val=\$$as_ac_Header
13587 if test "x$as_val" = x""yes; then :
13588 cat >>confdefs.h <<_ACEOF
13589 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13590 _ACEOF
13591 break
13594 done
13596 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13598 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13599 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13600 $as_echo_n "(cached) " >&6
13601 else
13602 ac_check_lib_save_LIBS=$LIBS
13603 LIBS="-lpng -lz -lm $LIBS"
13604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13605 /* end confdefs.h. */
13607 /* Override any GCC internal prototype to avoid an error.
13608 Use char because int might match the return type of a GCC
13609 builtin and then its argument prototype would still apply. */
13610 #ifdef __cplusplus
13611 extern "C"
13612 #endif
13613 char png_get_channels ();
13615 main ()
13617 return png_get_channels ();
13619 return 0;
13621 _ACEOF
13622 if ac_fn_c_try_link "$LINENO"; then :
13623 ac_cv_lib_png_png_get_channels=yes
13624 else
13625 ac_cv_lib_png_png_get_channels=no
13627 rm -f core conftest.err conftest.$ac_objext \
13628 conftest$ac_exeext conftest.$ac_ext
13629 LIBS=$ac_check_lib_save_LIBS
13631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13632 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13633 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13634 HAVE_PNG=yes
13640 if test "${HAVE_PNG}" = "yes"; then
13642 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13644 LIBPNG="-lpng -lz -lm"
13646 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13647 # include <libpng/png.h>
13648 #else
13649 # include <png.h>
13650 #endif
13653 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13655 else
13657 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13665 HAVE_ZLIB=no
13666 LIBZ=
13667 if test "${with_zlib}" != "no"; then
13668 OLIBS=$LIBS
13669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inflateEnd" >&5
13670 $as_echo_n "checking for library containing inflateEnd... " >&6; }
13671 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13672 $as_echo_n "(cached) " >&6
13673 else
13674 ac_func_search_save_LIBS=$LIBS
13675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13676 /* end confdefs.h. */
13678 /* Override any GCC internal prototype to avoid an error.
13679 Use char because int might match the return type of a GCC
13680 builtin and then its argument prototype would still apply. */
13681 #ifdef __cplusplus
13682 extern "C"
13683 #endif
13684 char inflateEnd ();
13686 main ()
13688 return inflateEnd ();
13690 return 0;
13692 _ACEOF
13693 for ac_lib in '' z; do
13694 if test -z "$ac_lib"; then
13695 ac_res="none required"
13696 else
13697 ac_res=-l$ac_lib
13698 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
13700 if ac_fn_c_try_link "$LINENO"; then :
13701 ac_cv_search_inflateEnd=$ac_res
13703 rm -f core conftest.err conftest.$ac_objext \
13704 conftest$ac_exeext
13705 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13706 break
13708 done
13709 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13711 else
13712 ac_cv_search_inflateEnd=no
13714 rm conftest.$ac_ext
13715 LIBS=$ac_func_search_save_LIBS
13717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inflateEnd" >&5
13718 $as_echo "$ac_cv_search_inflateEnd" >&6; }
13719 ac_res=$ac_cv_search_inflateEnd
13720 if test "$ac_res" != no; then :
13721 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13722 HAVE_ZLIB=yes
13725 LIBS=$OLIBS
13726 case $ac_cv_search_inflateEnd in
13727 -*) LIBZ=$ac_cv_search_inflateEnd ;;
13728 esac
13730 if test "${HAVE_ZLIB}" = "yes"; then
13732 $as_echo "#define HAVE_ZLIB 1" >>confdefs.h
13734 ### mingw32 doesn't use -lz, since it loads the library dynamically.
13735 if test "${opsys}" = "mingw32"; then
13736 LIBZ=
13742 ### Use -ltiff if available, unless `--with-tiff=no'.
13743 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
13744 HAVE_TIFF=no
13745 LIBTIFF=
13746 if test "${opsys}" = "mingw32"; then
13747 if test "${with_tiff}" != "no"; then
13748 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13749 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13750 HAVE_TIFF=yes
13751 else
13752 HAVE_TIFF=no
13757 if test "${HAVE_TIFF}" = "yes"; then
13759 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13762 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13763 if test "${with_tiff}" != "no"; then
13764 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13765 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13766 tifflibs="-lz -lm"
13767 # At least one tiff package requires the jpeg library.
13768 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13770 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
13771 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
13772 $as_echo_n "(cached) " >&6
13773 else
13774 ac_check_lib_save_LIBS=$LIBS
13775 LIBS="-ltiff $tifflibs $LIBS"
13776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13777 /* end confdefs.h. */
13779 /* Override any GCC internal prototype to avoid an error.
13780 Use char because int might match the return type of a GCC
13781 builtin and then its argument prototype would still apply. */
13782 #ifdef __cplusplus
13783 extern "C"
13784 #endif
13785 char TIFFGetVersion ();
13787 main ()
13789 return TIFFGetVersion ();
13791 return 0;
13793 _ACEOF
13794 if ac_fn_c_try_link "$LINENO"; then :
13795 ac_cv_lib_tiff_TIFFGetVersion=yes
13796 else
13797 ac_cv_lib_tiff_TIFFGetVersion=no
13799 rm -f core conftest.err conftest.$ac_objext \
13800 conftest$ac_exeext conftest.$ac_ext
13801 LIBS=$ac_check_lib_save_LIBS
13803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13804 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13805 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13806 HAVE_TIFF=yes
13814 if test "${HAVE_TIFF}" = "yes"; then
13816 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13818 LIBTIFF=-ltiff
13823 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13824 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
13825 HAVE_GIF=no
13826 LIBGIF=
13827 if test "${opsys}" = "mingw32"; then
13828 if test "${with_gif}" != "no"; then
13829 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13830 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13831 HAVE_GIF=yes
13832 else
13833 HAVE_GIF=no
13838 if test "${HAVE_GIF}" = "yes"; then
13840 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13843 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
13844 || test "${HAVE_W32}" = "yes"; then
13845 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13846 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13847 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13848 # Earlier versions can crash Emacs.
13849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13850 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13851 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13852 $as_echo_n "(cached) " >&6
13853 else
13854 ac_check_lib_save_LIBS=$LIBS
13855 LIBS="-lgif $LIBS"
13856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13857 /* end confdefs.h. */
13859 /* Override any GCC internal prototype to avoid an error.
13860 Use char because int might match the return type of a GCC
13861 builtin and then its argument prototype would still apply. */
13862 #ifdef __cplusplus
13863 extern "C"
13864 #endif
13865 char EGifPutExtensionLast ();
13867 main ()
13869 return EGifPutExtensionLast ();
13871 return 0;
13873 _ACEOF
13874 if ac_fn_c_try_link "$LINENO"; then :
13875 ac_cv_lib_gif_EGifPutExtensionLast=yes
13876 else
13877 ac_cv_lib_gif_EGifPutExtensionLast=no
13879 rm -f core conftest.err conftest.$ac_objext \
13880 conftest$ac_exeext conftest.$ac_ext
13881 LIBS=$ac_check_lib_save_LIBS
13883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13884 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13885 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13886 HAVE_GIF=yes
13887 else
13888 HAVE_GIF=maybe
13895 if test "$HAVE_GIF" = yes; then
13896 LIBGIF=-lgif
13897 elif test "$HAVE_GIF" = maybe; then
13898 # If gif_lib.h but no libgif, try libungif.
13899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13900 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13901 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13902 $as_echo_n "(cached) " >&6
13903 else
13904 ac_check_lib_save_LIBS=$LIBS
13905 LIBS="-lungif $LIBS"
13906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13907 /* end confdefs.h. */
13909 /* Override any GCC internal prototype to avoid an error.
13910 Use char because int might match the return type of a GCC
13911 builtin and then its argument prototype would still apply. */
13912 #ifdef __cplusplus
13913 extern "C"
13914 #endif
13915 char EGifPutExtensionLast ();
13917 main ()
13919 return EGifPutExtensionLast ();
13921 return 0;
13923 _ACEOF
13924 if ac_fn_c_try_link "$LINENO"; then :
13925 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13926 else
13927 ac_cv_lib_ungif_EGifPutExtensionLast=no
13929 rm -f core conftest.err conftest.$ac_objext \
13930 conftest$ac_exeext conftest.$ac_ext
13931 LIBS=$ac_check_lib_save_LIBS
13933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13934 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13935 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13936 HAVE_GIF=yes
13937 else
13938 HAVE_GIF=no
13941 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13944 if test "${HAVE_GIF}" = "yes"; then
13946 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13952 if test "${HAVE_X11}" = "yes"; then
13953 MISSING=""
13954 WITH_NO=""
13955 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13956 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13957 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13958 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13959 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13960 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13961 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13962 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13963 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13964 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13966 if test "X${MISSING}" != X; then
13967 as_fn_error "The following required libraries were not found:
13968 $MISSING
13969 Maybe some development libraries/packages are missing?
13970 If you don't want to link with them give
13971 $WITH_NO
13972 as options to configure" "$LINENO" 5
13976 ### Use -lgpm if available, unless `--with-gpm=no'.
13977 HAVE_GPM=no
13978 LIBGPM=
13979 if test "${with_gpm}" != "no"; then
13980 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13981 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13983 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13984 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13985 $as_echo_n "(cached) " >&6
13986 else
13987 ac_check_lib_save_LIBS=$LIBS
13988 LIBS="-lgpm $LIBS"
13989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13990 /* end confdefs.h. */
13992 /* Override any GCC internal prototype to avoid an error.
13993 Use char because int might match the return type of a GCC
13994 builtin and then its argument prototype would still apply. */
13995 #ifdef __cplusplus
13996 extern "C"
13997 #endif
13998 char Gpm_Open ();
14000 main ()
14002 return Gpm_Open ();
14004 return 0;
14006 _ACEOF
14007 if ac_fn_c_try_link "$LINENO"; then :
14008 ac_cv_lib_gpm_Gpm_Open=yes
14009 else
14010 ac_cv_lib_gpm_Gpm_Open=no
14012 rm -f core conftest.err conftest.$ac_objext \
14013 conftest$ac_exeext conftest.$ac_ext
14014 LIBS=$ac_check_lib_save_LIBS
14016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
14017 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
14018 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
14019 HAVE_GPM=yes
14026 if test "${HAVE_GPM}" = "yes"; then
14028 $as_echo "#define HAVE_GPM 1" >>confdefs.h
14030 LIBGPM=-lgpm
14039 GNUSTEP_CFLAGS=
14040 ### Use NeXTstep API to implement GUI.
14041 if test "${HAVE_NS}" = "yes"; then
14043 $as_echo "#define HAVE_NS 1" >>confdefs.h
14045 if test "${NS_IMPL_COCOA}" = "yes"; then
14047 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
14050 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
14052 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
14054 # See also .m.o rule in Makefile.in */
14055 # FIXME: are all these flags really needed? Document here why. */
14056 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
14057 ## Extra CFLAGS applied to src/*.m files.
14058 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"
14060 # We also have mouse menus.
14061 HAVE_MENUS=yes
14062 OTHER_FILES=ns-app
14065 if test "${HAVE_W32}" = "yes"; then
14066 HAVE_MENUS=yes
14069 ### Use session management (-lSM -lICE) if available
14070 HAVE_X_SM=no
14071 LIBXSM=
14072 if test "${HAVE_X11}" = "yes"; then
14073 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
14074 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
14075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
14076 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
14077 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
14078 $as_echo_n "(cached) " >&6
14079 else
14080 ac_check_lib_save_LIBS=$LIBS
14081 LIBS="-lSM -lICE $LIBS"
14082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14083 /* end confdefs.h. */
14085 /* Override any GCC internal prototype to avoid an error.
14086 Use char because int might match the return type of a GCC
14087 builtin and then its argument prototype would still apply. */
14088 #ifdef __cplusplus
14089 extern "C"
14090 #endif
14091 char SmcOpenConnection ();
14093 main ()
14095 return SmcOpenConnection ();
14097 return 0;
14099 _ACEOF
14100 if ac_fn_c_try_link "$LINENO"; then :
14101 ac_cv_lib_SM_SmcOpenConnection=yes
14102 else
14103 ac_cv_lib_SM_SmcOpenConnection=no
14105 rm -f core conftest.err conftest.$ac_objext \
14106 conftest$ac_exeext conftest.$ac_ext
14107 LIBS=$ac_check_lib_save_LIBS
14109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
14110 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
14111 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
14112 HAVE_X_SM=yes
14119 if test "${HAVE_X_SM}" = "yes"; then
14121 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
14123 LIBXSM="-lSM -lICE"
14124 case "$LIBS" in
14125 *-lSM*) ;;
14126 *) LIBS="$LIBXSM $LIBS" ;;
14127 esac
14132 ### Use XRandr (-lXrandr) if available
14133 HAVE_XRANDR=no
14134 if test "${HAVE_X11}" = "yes"; then
14135 XRANDR_REQUIRED=1.2.2
14136 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14138 succeeded=no
14140 if test "$PKG_CONFIG" = "no" ; then
14141 HAVE_XRANDR=no
14142 else
14143 PKG_CONFIG_MIN_VERSION=0.9.0
14144 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14146 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14148 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14149 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14150 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14151 edit_cflags="
14152 s,///*,/,g
14153 s/^/ /
14154 s/ -I/ $isystem/g
14155 s/^ //
14157 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14158 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14160 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14161 succeeded=yes
14162 else
14163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14164 $as_echo "no" >&6; }
14165 XRANDR_CFLAGS=""
14166 XRANDR_LIBS=""
14167 ## If we have a custom action on failure, don't print errors, but
14168 ## do set a variable so people can do so. Do it in a subshell
14169 ## to capture any diagnostics in invoking pkg-config.
14170 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14176 else
14177 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14178 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14182 if test $succeeded = yes; then
14183 HAVE_XRANDR=yes
14184 else
14185 HAVE_XRANDR=no
14188 if test $HAVE_XRANDR = no; then
14189 # Test old way in case pkg-config doesn't have it (older machines).
14190 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14191 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14193 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14194 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14195 $as_echo_n "(cached) " >&6
14196 else
14197 ac_check_lib_save_LIBS=$LIBS
14198 LIBS="-lXrandr $LIBS"
14199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14200 /* end confdefs.h. */
14202 /* Override any GCC internal prototype to avoid an error.
14203 Use char because int might match the return type of a GCC
14204 builtin and then its argument prototype would still apply. */
14205 #ifdef __cplusplus
14206 extern "C"
14207 #endif
14208 char XRRGetScreenResources ();
14210 main ()
14212 return XRRGetScreenResources ();
14214 return 0;
14216 _ACEOF
14217 if ac_fn_c_try_link "$LINENO"; then :
14218 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14219 else
14220 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14222 rm -f core conftest.err conftest.$ac_objext \
14223 conftest$ac_exeext conftest.$ac_ext
14224 LIBS=$ac_check_lib_save_LIBS
14226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14227 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14228 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14229 HAVE_XRANDR=yes
14235 if test $HAVE_XRANDR = yes; then
14236 XRANDR_LIBS=-lXrandr
14240 if test $HAVE_XRANDR = yes; then
14241 SAVE_CFLAGS="$CFLAGS"
14242 SAVE_LIBS="$LIBS"
14243 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14244 LIBS="$XRANDR_LIBS $LIBS"
14245 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14246 do :
14247 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14248 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14249 eval as_val=\$$as_ac_var
14250 if test "x$as_val" = x""yes; then :
14251 cat >>confdefs.h <<_ACEOF
14252 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14253 _ACEOF
14256 done
14258 CFLAGS="$SAVE_CFLAGS"
14259 LIBS="$SAVE_LIBS"
14262 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14267 ### Use Xinerama (-lXinerama) if available
14268 HAVE_XINERAMA=no
14269 if test "${HAVE_X11}" = "yes"; then
14270 XINERAMA_REQUIRED=1.0.2
14271 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14273 succeeded=no
14275 if test "$PKG_CONFIG" = "no" ; then
14276 HAVE_XINERAMA=no
14277 else
14278 PKG_CONFIG_MIN_VERSION=0.9.0
14279 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14281 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14283 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14284 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14285 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14286 edit_cflags="
14287 s,///*,/,g
14288 s/^/ /
14289 s/ -I/ $isystem/g
14290 s/^ //
14292 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14293 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14295 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14296 succeeded=yes
14297 else
14298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14299 $as_echo "no" >&6; }
14300 XINERAMA_CFLAGS=""
14301 XINERAMA_LIBS=""
14302 ## If we have a custom action on failure, don't print errors, but
14303 ## do set a variable so people can do so. Do it in a subshell
14304 ## to capture any diagnostics in invoking pkg-config.
14305 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14311 else
14312 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14313 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14317 if test $succeeded = yes; then
14318 HAVE_XINERAMA=yes
14319 else
14320 HAVE_XINERAMA=no
14323 if test $HAVE_XINERAMA = no; then
14324 # Test old way in case pkg-config doesn't have it (older machines).
14325 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14326 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14328 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14329 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14330 $as_echo_n "(cached) " >&6
14331 else
14332 ac_check_lib_save_LIBS=$LIBS
14333 LIBS="-lXinerama $LIBS"
14334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14335 /* end confdefs.h. */
14337 /* Override any GCC internal prototype to avoid an error.
14338 Use char because int might match the return type of a GCC
14339 builtin and then its argument prototype would still apply. */
14340 #ifdef __cplusplus
14341 extern "C"
14342 #endif
14343 char XineramaQueryExtension ();
14345 main ()
14347 return XineramaQueryExtension ();
14349 return 0;
14351 _ACEOF
14352 if ac_fn_c_try_link "$LINENO"; then :
14353 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14354 else
14355 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14357 rm -f core conftest.err conftest.$ac_objext \
14358 conftest$ac_exeext conftest.$ac_ext
14359 LIBS=$ac_check_lib_save_LIBS
14361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14362 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14363 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14364 HAVE_XINERAMA=yes
14370 if test $HAVE_XINERAMA = yes; then
14371 XINERAMA_LIBS=-lXinerama
14375 if test $HAVE_XINERAMA = yes; then
14377 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14383 ### Use libxml (-lxml2) if available
14384 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14385 HAVE_LIBXML2=no
14386 if test "${with_xml2}" != "no"; then
14387 ### I'm not sure what the version number should be, so I just guessed.
14389 succeeded=no
14391 if test "$PKG_CONFIG" = "no" ; then
14392 HAVE_LIBXML2=no
14393 else
14394 PKG_CONFIG_MIN_VERSION=0.9.0
14395 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14397 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14399 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14400 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14401 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14402 edit_cflags="
14403 s,///*,/,g
14404 s/^/ /
14405 s/ -I/ $isystem/g
14406 s/^ //
14408 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14409 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14411 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14412 succeeded=yes
14413 else
14414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14415 $as_echo "no" >&6; }
14416 LIBXML2_CFLAGS=""
14417 LIBXML2_LIBS=""
14418 ## If we have a custom action on failure, don't print errors, but
14419 ## do set a variable so people can do so. Do it in a subshell
14420 ## to capture any diagnostics in invoking pkg-config.
14421 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14427 else
14428 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14429 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14433 if test $succeeded = yes; then
14434 HAVE_LIBXML2=yes
14435 else
14436 HAVE_LIBXML2=no
14439 # Built-in libxml2 on OS X 10.8 lacks libxml-2.0.pc.
14440 if test "${HAVE_LIBXML2}" != "yes" -a "$opsys" = "darwin"; then
14441 SAVE_CPPFLAGS="$CPPFLAGS"
14442 CPPFLAGS="$CPPFLAGS -I/usr/include/libxml2"
14443 ac_fn_c_check_header_mongrel "$LINENO" "libxml/HTMLparser.h" "ac_cv_header_libxml_HTMLparser_h" "$ac_includes_default"
14444 if test "x$ac_cv_header_libxml_HTMLparser_h" = x""yes; then :
14445 ac_fn_c_check_decl "$LINENO" "HTML_PARSE_RECOVER" "ac_cv_have_decl_HTML_PARSE_RECOVER" "#include <libxml/HTMLparser.h>
14447 if test "x$ac_cv_have_decl_HTML_PARSE_RECOVER" = x""yes; then :
14448 HAVE_LIBXML2=yes
14454 CPPFLAGS="$SAVE_CPPFLAGS"
14455 if test "${HAVE_LIBXML2}" = "yes"; then
14456 LIBXML2_LIBS="-lxml2"
14457 LIBXML2_CFLAGS="-I/usr/include/libxml2"
14460 if test "${HAVE_LIBXML2}" = "yes"; then
14461 if test "${opsys}" != "mingw32"; then
14462 LIBS="$LIBXML2_LIBS $LIBS"
14463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14464 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14465 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14466 $as_echo_n "(cached) " >&6
14467 else
14468 ac_check_lib_save_LIBS=$LIBS
14469 LIBS="-lxml2 $LIBS"
14470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14471 /* end confdefs.h. */
14473 /* Override any GCC internal prototype to avoid an error.
14474 Use char because int might match the return type of a GCC
14475 builtin and then its argument prototype would still apply. */
14476 #ifdef __cplusplus
14477 extern "C"
14478 #endif
14479 char htmlReadMemory ();
14481 main ()
14483 return htmlReadMemory ();
14485 return 0;
14487 _ACEOF
14488 if ac_fn_c_try_link "$LINENO"; then :
14489 ac_cv_lib_xml2_htmlReadMemory=yes
14490 else
14491 ac_cv_lib_xml2_htmlReadMemory=no
14493 rm -f core conftest.err conftest.$ac_objext \
14494 conftest$ac_exeext conftest.$ac_ext
14495 LIBS=$ac_check_lib_save_LIBS
14497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14498 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14499 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14500 HAVE_LIBXML2=yes
14501 else
14502 HAVE_LIBXML2=no
14505 else
14506 LIBXML2_LIBS=""
14508 if test "${HAVE_LIBXML2}" = "yes"; then
14510 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14512 else
14513 LIBXML2_LIBS=""
14514 LIBXML2_CFLAGS=""
14521 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14522 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14523 if test "${opsys}" = "mingw32"; then
14524 emacs_cv_netdb_declares_h_errno=yes
14526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14527 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14528 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14529 $as_echo_n "(cached) " >&6
14530 else
14531 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14532 /* end confdefs.h. */
14533 #include <netdb.h>
14535 main ()
14537 return h_errno;
14539 return 0;
14541 _ACEOF
14542 if ac_fn_c_try_link "$LINENO"; then :
14543 emacs_cv_netdb_declares_h_errno=yes
14544 else
14545 emacs_cv_netdb_declares_h_errno=no
14547 rm -f core conftest.err conftest.$ac_objext \
14548 conftest$ac_exeext conftest.$ac_ext
14550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14551 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14552 if test $emacs_cv_netdb_declares_h_errno = yes; then
14554 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14558 # sqrt and other floating-point functions such as fmod and frexp
14559 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14560 if test "${opsys}" != "mingw32"; then
14561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14562 $as_echo_n "checking for sqrt in -lm... " >&6; }
14563 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14564 $as_echo_n "(cached) " >&6
14565 else
14566 ac_check_lib_save_LIBS=$LIBS
14567 LIBS="-lm $LIBS"
14568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14569 /* end confdefs.h. */
14571 /* Override any GCC internal prototype to avoid an error.
14572 Use char because int might match the return type of a GCC
14573 builtin and then its argument prototype would still apply. */
14574 #ifdef __cplusplus
14575 extern "C"
14576 #endif
14577 char sqrt ();
14579 main ()
14581 return sqrt ();
14583 return 0;
14585 _ACEOF
14586 if ac_fn_c_try_link "$LINENO"; then :
14587 ac_cv_lib_m_sqrt=yes
14588 else
14589 ac_cv_lib_m_sqrt=no
14591 rm -f core conftest.err conftest.$ac_objext \
14592 conftest$ac_exeext conftest.$ac_ext
14593 LIBS=$ac_check_lib_save_LIBS
14595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14596 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14597 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14598 cat >>confdefs.h <<_ACEOF
14599 #define HAVE_LIBM 1
14600 _ACEOF
14602 LIBS="-lm $LIBS"
14608 # Check for mail-locking functions in a "mail" library. Probably this should
14609 # have the same check as for liblockfile below.
14610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14611 $as_echo_n "checking for maillock in -lmail... " >&6; }
14612 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14613 $as_echo_n "(cached) " >&6
14614 else
14615 ac_check_lib_save_LIBS=$LIBS
14616 LIBS="-lmail $LIBS"
14617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14618 /* end confdefs.h. */
14620 /* Override any GCC internal prototype to avoid an error.
14621 Use char because int might match the return type of a GCC
14622 builtin and then its argument prototype would still apply. */
14623 #ifdef __cplusplus
14624 extern "C"
14625 #endif
14626 char maillock ();
14628 main ()
14630 return maillock ();
14632 return 0;
14634 _ACEOF
14635 if ac_fn_c_try_link "$LINENO"; then :
14636 ac_cv_lib_mail_maillock=yes
14637 else
14638 ac_cv_lib_mail_maillock=no
14640 rm -f core conftest.err conftest.$ac_objext \
14641 conftest$ac_exeext conftest.$ac_ext
14642 LIBS=$ac_check_lib_save_LIBS
14644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14645 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14646 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14647 have_mail=yes
14648 else
14649 have_mail=no
14652 if test $have_mail = yes; then
14653 LIBS_MAIL=-lmail
14654 LIBS="$LIBS_MAIL $LIBS"
14656 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14658 else
14659 LIBS_MAIL=
14661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14662 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14663 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14664 $as_echo_n "(cached) " >&6
14665 else
14666 ac_check_lib_save_LIBS=$LIBS
14667 LIBS="-llockfile $LIBS"
14668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14669 /* end confdefs.h. */
14671 /* Override any GCC internal prototype to avoid an error.
14672 Use char because int might match the return type of a GCC
14673 builtin and then its argument prototype would still apply. */
14674 #ifdef __cplusplus
14675 extern "C"
14676 #endif
14677 char maillock ();
14679 main ()
14681 return maillock ();
14683 return 0;
14685 _ACEOF
14686 if ac_fn_c_try_link "$LINENO"; then :
14687 ac_cv_lib_lockfile_maillock=yes
14688 else
14689 ac_cv_lib_lockfile_maillock=no
14691 rm -f core conftest.err conftest.$ac_objext \
14692 conftest$ac_exeext conftest.$ac_ext
14693 LIBS=$ac_check_lib_save_LIBS
14695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
14696 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
14697 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
14698 have_lockfile=yes
14699 else
14700 have_lockfile=no
14703 if test $have_lockfile = yes; then
14704 LIBS_MAIL=-llockfile
14705 LIBS="$LIBS_MAIL $LIBS"
14707 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
14709 else
14710 # If we have the shared liblockfile, assume we must use it for mail
14711 # locking (e.g. Debian). If we couldn't link against liblockfile
14712 # (no liblockfile.a installed), ensure that we don't need to.
14713 # Extract the first word of "liblockfile.so", so it can be a program name with args.
14714 set dummy liblockfile.so; ac_word=$2
14715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14716 $as_echo_n "checking for $ac_word... " >&6; }
14717 if test "${ac_cv_prog_liblockfile+set}" = set; then :
14718 $as_echo_n "(cached) " >&6
14719 else
14720 if test -n "$liblockfile"; then
14721 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
14722 else
14723 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14724 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
14725 for as_dir in $as_dummy
14727 IFS=$as_save_IFS
14728 test -z "$as_dir" && as_dir=.
14729 for ac_exec_ext in '' $ac_executable_extensions; do
14730 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14731 ac_cv_prog_liblockfile="yes"
14732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14733 break 2
14735 done
14736 done
14737 IFS=$as_save_IFS
14739 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
14742 liblockfile=$ac_cv_prog_liblockfile
14743 if test -n "$liblockfile"; then
14744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
14745 $as_echo "$liblockfile" >&6; }
14746 else
14747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14748 $as_echo "no" >&6; }
14752 if test $ac_cv_prog_liblockfile = yes; then
14753 as_fn_error "Shared liblockfile found but can't link against it.
14754 This probably means that movemail could lose mail.
14755 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
14763 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
14764 ## interlock access to the mail spool. The alternative is a lock file named
14765 ## /usr/spool/mail/$USER.lock.
14766 mail_lock=no
14767 case "$opsys" in
14768 aix4-2) mail_lock="lockf" ;;
14770 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
14772 ## On GNU/Linux systems, both methods are used by various mail programs.
14773 ## I assume most people are using newer mailers that have heard of flock.
14774 ## Change this if you need to.
14775 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
14776 ## configure gets the right answers, and that means *NOT* using flock.
14777 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
14778 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
14779 ## Debian maintainer hasn't provided a clean fix for Emacs.
14780 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
14781 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
14782 ## correct logic. -- fx
14783 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
14784 ## liblockfile is a Free Software replacement for libmail, used on
14785 ## Debian systems and elsewhere. -rfr.
14786 gnu-*)
14787 mail_lock="flock"
14788 if test $have_mail = yes || test $have_lockfile = yes; then
14789 test $ac_cv_header_maillock_h = yes && mail_lock=no
14793 mingw32)
14794 mail_lock="none-needed" ;;
14795 esac
14797 BLESSMAIL_TARGET=
14798 case "$mail_lock" in
14799 flock)
14800 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
14803 lockf)
14804 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
14807 none-needed) ;;
14809 *) BLESSMAIL_TARGET="need-blessmail" ;;
14810 esac
14814 for ac_func in accept4 gethostname \
14815 getrusage get_current_dir_name \
14816 lrand48 \
14817 select getpagesize setlocale \
14818 getrlimit setrlimit shutdown getaddrinfo \
14819 strsignal setitimer \
14820 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
14821 gai_strerror getline getdelim sync \
14822 difftime posix_memalign \
14823 getpwent endpwent getgrent endgrent \
14824 touchlock \
14825 cfmakeraw cfsetspeed copysign __executable_start log2
14826 do :
14827 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14828 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14829 eval as_val=\$$as_ac_var
14830 if test "x$as_val" = x""yes; then :
14831 cat >>confdefs.h <<_ACEOF
14832 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14833 _ACEOF
14836 done
14839 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
14840 ## has a broken `rint' in some library versions including math library
14841 ## version number A.09.05.
14842 ## You can fix the math library by installing patch number PHSS_4630.
14843 ## But we can fix it more reliably for Emacs by just not using rint.
14844 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
14845 case $opsys in
14846 hpux*) : ;;
14847 *) for ac_func in random rint
14848 do :
14849 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14850 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14851 eval as_val=\$$as_ac_var
14852 if test "x$as_val" = x""yes; then :
14853 cat >>confdefs.h <<_ACEOF
14854 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14855 _ACEOF
14858 done
14860 esac
14862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
14863 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
14864 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
14865 $as_echo_n "(cached) " >&6
14866 else
14867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14868 /* end confdefs.h. */
14871 main ()
14873 __builtin_unwind_init ();
14875 return 0;
14877 _ACEOF
14878 if ac_fn_c_try_link "$LINENO"; then :
14879 emacs_cv_func___builtin_unwind_init=yes
14880 else
14881 emacs_cv_func___builtin_unwind_init=no
14883 rm -f core conftest.err conftest.$ac_objext \
14884 conftest$ac_exeext conftest.$ac_ext
14886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
14887 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
14888 if test $emacs_cv_func___builtin_unwind_init = yes; then
14890 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
14898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14899 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
14900 if test "${ac_cv_sys_largefile_source+set}" = set; then :
14901 $as_echo_n "(cached) " >&6
14902 else
14903 while :; do
14904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14905 /* end confdefs.h. */
14906 #include <sys/types.h> /* for off_t */
14907 #include <stdio.h>
14909 main ()
14911 int (*fp) (FILE *, off_t, int) = fseeko;
14912 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14914 return 0;
14916 _ACEOF
14917 if ac_fn_c_try_link "$LINENO"; then :
14918 ac_cv_sys_largefile_source=no; break
14920 rm -f core conftest.err conftest.$ac_objext \
14921 conftest$ac_exeext conftest.$ac_ext
14922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14923 /* end confdefs.h. */
14924 #define _LARGEFILE_SOURCE 1
14925 #include <sys/types.h> /* for off_t */
14926 #include <stdio.h>
14928 main ()
14930 int (*fp) (FILE *, off_t, int) = fseeko;
14931 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14933 return 0;
14935 _ACEOF
14936 if ac_fn_c_try_link "$LINENO"; then :
14937 ac_cv_sys_largefile_source=1; break
14939 rm -f core conftest.err conftest.$ac_objext \
14940 conftest$ac_exeext conftest.$ac_ext
14941 ac_cv_sys_largefile_source=unknown
14942 break
14943 done
14945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14946 $as_echo "$ac_cv_sys_largefile_source" >&6; }
14947 case $ac_cv_sys_largefile_source in #(
14948 no | unknown) ;;
14950 cat >>confdefs.h <<_ACEOF
14951 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14952 _ACEOF
14954 esac
14955 rm -rf conftest*
14957 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14958 # in glibc 2.1.3, but that breaks too many other things.
14959 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14960 if test $ac_cv_sys_largefile_source != unknown; then
14962 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14967 # UNIX98 PTYs.
14968 for ac_func in grantpt
14969 do :
14970 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
14971 if test "x$ac_cv_func_grantpt" = x""yes; then :
14972 cat >>confdefs.h <<_ACEOF
14973 #define HAVE_GRANTPT 1
14974 _ACEOF
14977 done
14980 # PTY-related GNU extensions.
14981 for ac_func in getpt posix_openpt
14982 do :
14983 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14984 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14985 eval as_val=\$$as_ac_var
14986 if test "x$as_val" = x""yes; then :
14987 cat >>confdefs.h <<_ACEOF
14988 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14989 _ACEOF
14992 done
14995 # Check this now, so that we will NOT find the above functions in ncurses.
14996 # That is because we have not set up to link ncurses in lib-src.
14997 # It's better to believe a function is not available
14998 # than to expect to find it in ncurses.
14999 # Also we need tputs and friends to be able to build at all.
15000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
15001 $as_echo_n "checking for library containing tputs... " >&6; }
15002 # Run a test program that contains a call to tputs, a call that is
15003 # never executed. This tests whether a pre-'main' dynamic linker
15004 # works with the library. It's too much trouble to actually call
15005 # tputs in the test program, due to portability hassles. When
15006 # cross-compiling, assume the test program will run if it links.
15008 if test "${opsys}" = "mingw32"; then
15009 msg='none required'
15010 else
15011 # Maybe curses should be tried earlier?
15012 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
15013 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
15014 OLIBS=$LIBS
15015 if test -z "$tputs_library"; then
15016 LIBS_TERMCAP=
15017 msg='none required'
15018 else
15019 LIBS_TERMCAP=-l$tputs_library
15020 msg=$LIBS_TERMCAP
15021 LIBS="$LIBS_TERMCAP $LIBS"
15023 if test "$cross_compiling" = yes; then :
15024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15025 /* end confdefs.h. */
15027 extern void tputs (const char *, int, int (*)(int));
15028 int main (int argc, char **argv)
15030 if (argc == 10000)
15031 tputs (argv[0], 0, 0);
15032 return 0;
15035 _ACEOF
15036 if ac_fn_c_try_link "$LINENO"; then :
15038 else
15039 msg=no
15041 rm -f core conftest.err conftest.$ac_objext \
15042 conftest$ac_exeext conftest.$ac_ext
15043 else
15044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15045 /* end confdefs.h. */
15047 extern void tputs (const char *, int, int (*)(int));
15048 int main (int argc, char **argv)
15050 if (argc == 10000)
15051 tputs (argv[0], 0, 0);
15052 return 0;
15055 _ACEOF
15056 if ac_fn_c_try_run "$LINENO"; then :
15058 else
15059 msg=no
15061 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15062 conftest.$ac_objext conftest.beam conftest.$ac_ext
15065 LIBS=$OLIBS
15066 if test "X$msg" != Xno; then
15067 break
15069 done
15071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
15072 $as_echo "$msg" >&6; }
15073 if test "X$msg" = Xno; then
15074 as_fn_error "The required function \`tputs' was not found in any library.
15075 The following libraries were tried (in order):
15076 libtinfo, libncurses, libterminfo, libtermcap, libcurses
15077 Please try installing whichever of these libraries is most appropriate
15078 for your system, together with its header files.
15079 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
15082 ## Use termcap instead of terminfo?
15083 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
15084 TERMINFO=yes
15085 ## FIXME? In the cases below where we unconditionally set
15086 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
15087 ## if that was found above to have tputs.
15088 ## Should we use the gnu* logic everywhere?
15089 case "$opsys" in
15090 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
15091 ## The ncurses library has been moved out of the System framework in
15092 ## Mac OS X 10.2. So if configure detects it, set the command-line
15093 ## option to use it.
15094 darwin) LIBS_TERMCAP="-lncurses" ;;
15096 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
15098 freebsd)
15099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
15100 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
15101 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
15102 $as_echo_n "(cached) " >&6
15103 else
15104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15105 /* end confdefs.h. */
15106 #include <osreldate.h>
15108 main ()
15110 #if __FreeBSD_version < 400000
15111 fail;
15112 #endif
15115 return 0;
15117 _ACEOF
15118 if ac_fn_c_try_link "$LINENO"; then :
15119 emacs_cv_freebsd_terminfo=yes
15120 else
15121 emacs_cv_freebsd_terminfo=no
15123 rm -f core conftest.err conftest.$ac_objext \
15124 conftest$ac_exeext conftest.$ac_ext
15128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
15129 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
15131 if test $emacs_cv_freebsd_terminfo = yes; then
15132 LIBS_TERMCAP="-lncurses"
15133 else
15134 TERMINFO=no
15135 LIBS_TERMCAP="-ltermcap"
15139 mingw32)
15140 TERMINFO=no
15141 LIBS_TERMCAP=
15144 netbsd)
15145 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15146 TERMINFO=no
15147 LIBS_TERMCAP="-ltermcap"
15151 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15153 ## hpux: Make sure we get select from libc rather than from libcurses
15154 ## because libcurses on HPUX 10.10 has a broken version of select.
15155 ## We used to use -lc -lcurses, but this may be cleaner.
15156 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15157 # set that way, now it uses the default). Isn't this a contradiction?
15158 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15160 esac
15162 TERMCAP_OBJ=tparam.o
15163 if test $TERMINFO = yes; then
15165 $as_echo "#define TERMINFO 1" >>confdefs.h
15167 TERMCAP_OBJ=terminfo.o
15169 if test "X$LIBS_TERMCAP" = "X-lncurses"; then
15171 $as_echo "#define USE_NCURSES 1" >>confdefs.h
15178 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15179 # On Darwin, res_init appears not to be useful: see bug#562 and
15180 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15181 resolv=no
15183 if test $opsys != darwin; then
15185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15186 /* end confdefs.h. */
15187 #include <netinet/in.h>
15188 #include <arpa/nameser.h>
15189 #include <resolv.h>
15191 main ()
15193 return res_init();
15195 return 0;
15197 _ACEOF
15198 if ac_fn_c_try_link "$LINENO"; then :
15199 have_res_init=yes
15200 else
15201 have_res_init=no
15203 rm -f core conftest.err conftest.$ac_objext \
15204 conftest$ac_exeext conftest.$ac_ext
15205 if test "$have_res_init" = no; then
15206 OLIBS="$LIBS"
15207 LIBS="$LIBS -lresolv"
15208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15209 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15211 /* end confdefs.h. */
15212 #include <netinet/in.h>
15213 #include <arpa/nameser.h>
15214 #include <resolv.h>
15216 main ()
15218 return res_init();
15220 return 0;
15222 _ACEOF
15223 if ac_fn_c_try_link "$LINENO"; then :
15224 have_res_init=yes
15225 else
15226 have_res_init=no
15228 rm -f core conftest.err conftest.$ac_objext \
15229 conftest$ac_exeext conftest.$ac_ext
15230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15231 $as_echo "$have_res_init" >&6; }
15232 if test "$have_res_init" = yes ; then
15233 resolv=yes
15235 LIBS="$OLIBS"
15238 if test "$have_res_init" = yes; then
15240 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15244 # Do we need the Hesiod library to provide the support routines?
15245 LIBHESIOD=
15246 if test "$with_hesiod" != no ; then
15247 # Don't set $LIBS here -- see comments above. FIXME which comments?
15248 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15249 if test "x$ac_cv_func_res_send" = x""yes; then :
15251 else
15252 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15253 if test "x$ac_cv_func___res_send" = x""yes; then :
15255 else
15256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15257 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15258 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15259 $as_echo_n "(cached) " >&6
15260 else
15261 ac_check_lib_save_LIBS=$LIBS
15262 LIBS="-lresolv $LIBS"
15263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15264 /* end confdefs.h. */
15266 /* Override any GCC internal prototype to avoid an error.
15267 Use char because int might match the return type of a GCC
15268 builtin and then its argument prototype would still apply. */
15269 #ifdef __cplusplus
15270 extern "C"
15271 #endif
15272 char res_send ();
15274 main ()
15276 return res_send ();
15278 return 0;
15280 _ACEOF
15281 if ac_fn_c_try_link "$LINENO"; then :
15282 ac_cv_lib_resolv_res_send=yes
15283 else
15284 ac_cv_lib_resolv_res_send=no
15286 rm -f core conftest.err conftest.$ac_objext \
15287 conftest$ac_exeext conftest.$ac_ext
15288 LIBS=$ac_check_lib_save_LIBS
15290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15291 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15292 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15293 resolv=yes
15294 else
15295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15296 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15297 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15298 $as_echo_n "(cached) " >&6
15299 else
15300 ac_check_lib_save_LIBS=$LIBS
15301 LIBS="-lresolv $LIBS"
15302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15303 /* end confdefs.h. */
15305 /* Override any GCC internal prototype to avoid an error.
15306 Use char because int might match the return type of a GCC
15307 builtin and then its argument prototype would still apply. */
15308 #ifdef __cplusplus
15309 extern "C"
15310 #endif
15311 char __res_send ();
15313 main ()
15315 return __res_send ();
15317 return 0;
15319 _ACEOF
15320 if ac_fn_c_try_link "$LINENO"; then :
15321 ac_cv_lib_resolv___res_send=yes
15322 else
15323 ac_cv_lib_resolv___res_send=no
15325 rm -f core conftest.err conftest.$ac_objext \
15326 conftest$ac_exeext conftest.$ac_ext
15327 LIBS=$ac_check_lib_save_LIBS
15329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15330 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15331 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15332 resolv=yes
15341 if test "$resolv" = yes ; then
15342 RESOLVLIB=-lresolv
15343 else
15344 RESOLVLIB=
15346 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15347 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15349 else
15350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15351 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15352 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15353 $as_echo_n "(cached) " >&6
15354 else
15355 ac_check_lib_save_LIBS=$LIBS
15356 LIBS="-lhesiod $RESOLVLIB $LIBS"
15357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15358 /* end confdefs.h. */
15360 /* Override any GCC internal prototype to avoid an error.
15361 Use char because int might match the return type of a GCC
15362 builtin and then its argument prototype would still apply. */
15363 #ifdef __cplusplus
15364 extern "C"
15365 #endif
15366 char hes_getmailhost ();
15368 main ()
15370 return hes_getmailhost ();
15372 return 0;
15374 _ACEOF
15375 if ac_fn_c_try_link "$LINENO"; then :
15376 ac_cv_lib_hesiod_hes_getmailhost=yes
15377 else
15378 ac_cv_lib_hesiod_hes_getmailhost=no
15380 rm -f core conftest.err conftest.$ac_objext \
15381 conftest$ac_exeext conftest.$ac_ext
15382 LIBS=$ac_check_lib_save_LIBS
15384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15385 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15386 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15387 hesiod=yes
15388 else
15395 if test x"$hesiod" = xyes; then
15396 LIBHESIOD=-lhesiod
15401 # Do we need libresolv (due to res_init or Hesiod)?
15402 if test "$resolv" = yes && test $opsys != darwin; then
15403 LIBRESOLV=-lresolv
15404 else
15405 LIBRESOLV=
15409 # These tell us which Kerberos-related libraries to use.
15410 COM_ERRLIB=
15411 CRYPTOLIB=
15412 KRB5LIB=
15413 DESLIB=
15414 KRB4LIB=
15416 if test "${with_kerberos}" != no; then
15417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15418 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15419 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15420 $as_echo_n "(cached) " >&6
15421 else
15422 ac_check_lib_save_LIBS=$LIBS
15423 LIBS="-lcom_err $LIBS"
15424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15425 /* end confdefs.h. */
15427 /* Override any GCC internal prototype to avoid an error.
15428 Use char because int might match the return type of a GCC
15429 builtin and then its argument prototype would still apply. */
15430 #ifdef __cplusplus
15431 extern "C"
15432 #endif
15433 char com_err ();
15435 main ()
15437 return com_err ();
15439 return 0;
15441 _ACEOF
15442 if ac_fn_c_try_link "$LINENO"; then :
15443 ac_cv_lib_com_err_com_err=yes
15444 else
15445 ac_cv_lib_com_err_com_err=no
15447 rm -f core conftest.err conftest.$ac_objext \
15448 conftest$ac_exeext conftest.$ac_ext
15449 LIBS=$ac_check_lib_save_LIBS
15451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15452 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15453 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15454 have_com_err=yes
15455 else
15456 have_com_err=no
15459 if test $have_com_err = yes; then
15460 COM_ERRLIB=-lcom_err
15461 LIBS="$COM_ERRLIB $LIBS"
15463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15464 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15465 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15466 $as_echo_n "(cached) " >&6
15467 else
15468 ac_check_lib_save_LIBS=$LIBS
15469 LIBS="-lcrypto $LIBS"
15470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15471 /* end confdefs.h. */
15473 /* Override any GCC internal prototype to avoid an error.
15474 Use char because int might match the return type of a GCC
15475 builtin and then its argument prototype would still apply. */
15476 #ifdef __cplusplus
15477 extern "C"
15478 #endif
15479 char mit_des_cbc_encrypt ();
15481 main ()
15483 return mit_des_cbc_encrypt ();
15485 return 0;
15487 _ACEOF
15488 if ac_fn_c_try_link "$LINENO"; then :
15489 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15490 else
15491 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15493 rm -f core conftest.err conftest.$ac_objext \
15494 conftest$ac_exeext conftest.$ac_ext
15495 LIBS=$ac_check_lib_save_LIBS
15497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15498 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15499 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15500 have_crypto=yes
15501 else
15502 have_crypto=no
15505 if test $have_crypto = yes; then
15506 CRYPTOLIB=-lcrypto
15507 LIBS="$CRYPTOLIB $LIBS"
15509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15510 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15511 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15512 $as_echo_n "(cached) " >&6
15513 else
15514 ac_check_lib_save_LIBS=$LIBS
15515 LIBS="-lk5crypto $LIBS"
15516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15517 /* end confdefs.h. */
15519 /* Override any GCC internal prototype to avoid an error.
15520 Use char because int might match the return type of a GCC
15521 builtin and then its argument prototype would still apply. */
15522 #ifdef __cplusplus
15523 extern "C"
15524 #endif
15525 char mit_des_cbc_encrypt ();
15527 main ()
15529 return mit_des_cbc_encrypt ();
15531 return 0;
15533 _ACEOF
15534 if ac_fn_c_try_link "$LINENO"; then :
15535 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15536 else
15537 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15539 rm -f core conftest.err conftest.$ac_objext \
15540 conftest$ac_exeext conftest.$ac_ext
15541 LIBS=$ac_check_lib_save_LIBS
15543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15544 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15545 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15546 have_k5crypto=yes
15547 else
15548 have_k5crypto=no
15551 if test $have_k5crypto = yes; then
15552 CRYPTOLIB=-lk5crypto
15553 LIBS="$CRYPTOLIB $LIBS"
15555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15556 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15557 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15558 $as_echo_n "(cached) " >&6
15559 else
15560 ac_check_lib_save_LIBS=$LIBS
15561 LIBS="-lkrb5 $LIBS"
15562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15563 /* end confdefs.h. */
15565 /* Override any GCC internal prototype to avoid an error.
15566 Use char because int might match the return type of a GCC
15567 builtin and then its argument prototype would still apply. */
15568 #ifdef __cplusplus
15569 extern "C"
15570 #endif
15571 char krb5_init_context ();
15573 main ()
15575 return krb5_init_context ();
15577 return 0;
15579 _ACEOF
15580 if ac_fn_c_try_link "$LINENO"; then :
15581 ac_cv_lib_krb5_krb5_init_context=yes
15582 else
15583 ac_cv_lib_krb5_krb5_init_context=no
15585 rm -f core conftest.err conftest.$ac_objext \
15586 conftest$ac_exeext conftest.$ac_ext
15587 LIBS=$ac_check_lib_save_LIBS
15589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15590 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15591 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15592 have_krb5=yes
15593 else
15594 have_krb5=no
15597 if test $have_krb5=yes; then
15598 KRB5LIB=-lkrb5
15599 LIBS="$KRB5LIB $LIBS"
15601 if test "${with_kerberos5}" = no; then
15602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15603 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15604 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15605 $as_echo_n "(cached) " >&6
15606 else
15607 ac_check_lib_save_LIBS=$LIBS
15608 LIBS="-ldes425 $LIBS"
15609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15610 /* end confdefs.h. */
15612 /* Override any GCC internal prototype to avoid an error.
15613 Use char because int might match the return type of a GCC
15614 builtin and then its argument prototype would still apply. */
15615 #ifdef __cplusplus
15616 extern "C"
15617 #endif
15618 char des_cbc_encrypt ();
15620 main ()
15622 return des_cbc_encrypt ();
15624 return 0;
15626 _ACEOF
15627 if ac_fn_c_try_link "$LINENO"; then :
15628 ac_cv_lib_des425_des_cbc_encrypt=yes
15629 else
15630 ac_cv_lib_des425_des_cbc_encrypt=no
15632 rm -f core conftest.err conftest.$ac_objext \
15633 conftest$ac_exeext conftest.$ac_ext
15634 LIBS=$ac_check_lib_save_LIBS
15636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15637 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15638 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15639 have_des425=yes
15640 else
15641 have_des425=no
15644 if test $have_des425 = yes; then
15645 DESLIB=-ldes425
15646 LIBS="$DESLIB $LIBS"
15647 else
15648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15649 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15650 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15651 $as_echo_n "(cached) " >&6
15652 else
15653 ac_check_lib_save_LIBS=$LIBS
15654 LIBS="-ldes $LIBS"
15655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15656 /* end confdefs.h. */
15658 /* Override any GCC internal prototype to avoid an error.
15659 Use char because int might match the return type of a GCC
15660 builtin and then its argument prototype would still apply. */
15661 #ifdef __cplusplus
15662 extern "C"
15663 #endif
15664 char des_cbc_encrypt ();
15666 main ()
15668 return des_cbc_encrypt ();
15670 return 0;
15672 _ACEOF
15673 if ac_fn_c_try_link "$LINENO"; then :
15674 ac_cv_lib_des_des_cbc_encrypt=yes
15675 else
15676 ac_cv_lib_des_des_cbc_encrypt=no
15678 rm -f core conftest.err conftest.$ac_objext \
15679 conftest$ac_exeext conftest.$ac_ext
15680 LIBS=$ac_check_lib_save_LIBS
15682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
15683 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
15684 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
15685 have_des=yes
15686 else
15687 have_des=no
15690 if test $have_des = yes; then
15691 DESLIB=-ldes
15692 LIBS="$DESLIB $LIBS"
15695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
15696 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
15697 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
15698 $as_echo_n "(cached) " >&6
15699 else
15700 ac_check_lib_save_LIBS=$LIBS
15701 LIBS="-lkrb4 $LIBS"
15702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15703 /* end confdefs.h. */
15705 /* Override any GCC internal prototype to avoid an error.
15706 Use char because int might match the return type of a GCC
15707 builtin and then its argument prototype would still apply. */
15708 #ifdef __cplusplus
15709 extern "C"
15710 #endif
15711 char krb_get_cred ();
15713 main ()
15715 return krb_get_cred ();
15717 return 0;
15719 _ACEOF
15720 if ac_fn_c_try_link "$LINENO"; then :
15721 ac_cv_lib_krb4_krb_get_cred=yes
15722 else
15723 ac_cv_lib_krb4_krb_get_cred=no
15725 rm -f core conftest.err conftest.$ac_objext \
15726 conftest$ac_exeext conftest.$ac_ext
15727 LIBS=$ac_check_lib_save_LIBS
15729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
15730 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
15731 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
15732 have_krb4=yes
15733 else
15734 have_krb4=no
15737 if test $have_krb4 = yes; then
15738 KRB4LIB=-lkrb4
15739 LIBS="$KRB4LIB $LIBS"
15740 else
15741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
15742 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
15743 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
15744 $as_echo_n "(cached) " >&6
15745 else
15746 ac_check_lib_save_LIBS=$LIBS
15747 LIBS="-lkrb $LIBS"
15748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15749 /* end confdefs.h. */
15751 /* Override any GCC internal prototype to avoid an error.
15752 Use char because int might match the return type of a GCC
15753 builtin and then its argument prototype would still apply. */
15754 #ifdef __cplusplus
15755 extern "C"
15756 #endif
15757 char krb_get_cred ();
15759 main ()
15761 return krb_get_cred ();
15763 return 0;
15765 _ACEOF
15766 if ac_fn_c_try_link "$LINENO"; then :
15767 ac_cv_lib_krb_krb_get_cred=yes
15768 else
15769 ac_cv_lib_krb_krb_get_cred=no
15771 rm -f core conftest.err conftest.$ac_objext \
15772 conftest$ac_exeext conftest.$ac_ext
15773 LIBS=$ac_check_lib_save_LIBS
15775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
15776 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
15777 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
15778 have_krb=yes
15779 else
15780 have_krb=no
15783 if test $have_krb = yes; then
15784 KRB4LIB=-lkrb
15785 LIBS="$KRB4LIB $LIBS"
15790 if test "${with_kerberos5}" != no; then
15791 for ac_header in krb5.h
15792 do :
15793 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
15794 if test "x$ac_cv_header_krb5_h" = x""yes; then :
15795 cat >>confdefs.h <<_ACEOF
15796 #define HAVE_KRB5_H 1
15797 _ACEOF
15798 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
15800 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
15802 cat >>confdefs.h <<_ACEOF
15803 #define HAVE_KRB5_ERROR_TEXT 1
15804 _ACEOF
15808 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
15810 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
15812 cat >>confdefs.h <<_ACEOF
15813 #define HAVE_KRB5_ERROR_E_TEXT 1
15814 _ACEOF
15821 done
15823 else
15824 for ac_header in krb.h
15825 do :
15826 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
15827 if test "x$ac_cv_header_krb_h" = x""yes; then :
15828 cat >>confdefs.h <<_ACEOF
15829 #define HAVE_KRB_H 1
15830 _ACEOF
15832 else
15833 for ac_header in kerberosIV/krb.h
15834 do :
15835 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
15836 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
15837 cat >>confdefs.h <<_ACEOF
15838 #define HAVE_KERBEROSIV_KRB_H 1
15839 _ACEOF
15841 else
15842 for ac_header in kerberos/krb.h
15843 do :
15844 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
15845 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
15846 cat >>confdefs.h <<_ACEOF
15847 #define HAVE_KERBEROS_KRB_H 1
15848 _ACEOF
15852 done
15856 done
15860 done
15863 for ac_header in com_err.h
15864 do :
15865 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
15866 if test "x$ac_cv_header_com_err_h" = x""yes; then :
15867 cat >>confdefs.h <<_ACEOF
15868 #define HAVE_COM_ERR_H 1
15869 _ACEOF
15873 done
15886 for ac_func in $ac_func_list
15887 do :
15888 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15889 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15890 eval as_val=\$$as_ac_var
15891 if test "x$as_val" = x""yes; then :
15892 cat >>confdefs.h <<_ACEOF
15893 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15894 _ACEOF
15897 done
15902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
15903 $as_echo_n "checking whether localtime caches TZ... " >&6; }
15904 if test "${emacs_cv_localtime_cache+set}" = set; then :
15905 $as_echo_n "(cached) " >&6
15906 else
15907 if test x$ac_cv_func_tzset = xyes; then
15908 if test "$cross_compiling" = yes; then :
15909 # If we have tzset, assume the worst when cross-compiling.
15910 emacs_cv_localtime_cache=yes
15911 else
15912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15913 /* end confdefs.h. */
15914 #include <time.h>
15915 char TZ_GMT0[] = "TZ=GMT0";
15916 char TZ_PST8[] = "TZ=PST8";
15917 main()
15919 time_t now = time ((time_t *) 0);
15920 int hour_GMT0, hour_unset;
15921 if (putenv (TZ_GMT0) != 0)
15922 exit (1);
15923 hour_GMT0 = localtime (&now)->tm_hour;
15924 unsetenv("TZ");
15925 hour_unset = localtime (&now)->tm_hour;
15926 if (putenv (TZ_PST8) != 0)
15927 exit (1);
15928 if (localtime (&now)->tm_hour == hour_GMT0)
15929 exit (1);
15930 unsetenv("TZ");
15931 if (localtime (&now)->tm_hour != hour_unset)
15932 exit (1);
15933 exit (0);
15935 _ACEOF
15936 if ac_fn_c_try_run "$LINENO"; then :
15937 emacs_cv_localtime_cache=no
15938 else
15939 emacs_cv_localtime_cache=yes
15941 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15942 conftest.$ac_objext conftest.beam conftest.$ac_ext
15945 else
15946 # If we lack tzset, report that localtime does not cache TZ,
15947 # since we can't invalidate the cache if we don't have tzset.
15948 emacs_cv_localtime_cache=no
15951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
15952 $as_echo "$emacs_cv_localtime_cache" >&6; }
15953 if test $emacs_cv_localtime_cache = yes; then
15955 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
15959 ok_so_far=yes
15960 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
15961 if test "x$ac_cv_func_socket" = x""yes; then :
15963 else
15964 ok_so_far=no
15967 if test $ok_so_far = yes; then
15968 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
15969 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
15971 else
15972 ok_so_far=no
15977 if test $ok_so_far = yes; then
15978 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
15979 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
15981 else
15982 ok_so_far=no
15987 if test $ok_so_far = yes; then
15989 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
15993 case $canonical in
15994 *-solaris2.4 | *-solaris2.4.*)
15995 : ${ac_cv_func_vfork_works=no};;
15996 esac
15998 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15999 if test "x$ac_cv_type_pid_t" = x""yes; then :
16001 else
16003 cat >>confdefs.h <<_ACEOF
16004 #define pid_t int
16005 _ACEOF
16009 for ac_header in vfork.h
16010 do :
16011 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
16012 if test "x$ac_cv_header_vfork_h" = x""yes; then :
16013 cat >>confdefs.h <<_ACEOF
16014 #define HAVE_VFORK_H 1
16015 _ACEOF
16019 done
16021 for ac_func in fork vfork
16022 do :
16023 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16024 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16025 eval as_val=\$$as_ac_var
16026 if test "x$as_val" = x""yes; then :
16027 cat >>confdefs.h <<_ACEOF
16028 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16029 _ACEOF
16032 done
16034 if test "x$ac_cv_func_fork" = xyes; then
16035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
16036 $as_echo_n "checking for working fork... " >&6; }
16037 if test "${ac_cv_func_fork_works+set}" = set; then :
16038 $as_echo_n "(cached) " >&6
16039 else
16040 if test "$cross_compiling" = yes; then :
16041 ac_cv_func_fork_works=cross
16042 else
16043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16044 /* end confdefs.h. */
16045 $ac_includes_default
16047 main ()
16050 /* By Ruediger Kuhlmann. */
16051 return fork () < 0;
16054 return 0;
16056 _ACEOF
16057 if ac_fn_c_try_run "$LINENO"; then :
16058 ac_cv_func_fork_works=yes
16059 else
16060 ac_cv_func_fork_works=no
16062 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16063 conftest.$ac_objext conftest.beam conftest.$ac_ext
16067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
16068 $as_echo "$ac_cv_func_fork_works" >&6; }
16070 else
16071 ac_cv_func_fork_works=$ac_cv_func_fork
16073 if test "x$ac_cv_func_fork_works" = xcross; then
16074 case $host in
16075 *-*-amigaos* | *-*-msdosdjgpp*)
16076 # Override, as these systems have only a dummy fork() stub
16077 ac_cv_func_fork_works=no
16080 ac_cv_func_fork_works=yes
16082 esac
16083 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
16084 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
16086 ac_cv_func_vfork_works=$ac_cv_func_vfork
16087 if test "x$ac_cv_func_vfork" = xyes; then
16088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
16089 $as_echo_n "checking for working vfork... " >&6; }
16090 if test "${ac_cv_func_vfork_works+set}" = set; then :
16091 $as_echo_n "(cached) " >&6
16092 else
16093 if test "$cross_compiling" = yes; then :
16094 ac_cv_func_vfork_works=cross
16095 else
16096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16097 /* end confdefs.h. */
16098 /* Thanks to Paul Eggert for this test. */
16099 $ac_includes_default
16100 #include <sys/wait.h>
16101 #ifdef HAVE_VFORK_H
16102 # include <vfork.h>
16103 #endif
16104 /* On some sparc systems, changes by the child to local and incoming
16105 argument registers are propagated back to the parent. The compiler
16106 is told about this with #include <vfork.h>, but some compilers
16107 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
16108 static variable whose address is put into a register that is
16109 clobbered by the vfork. */
16110 static void
16111 #ifdef __cplusplus
16112 sparc_address_test (int arg)
16113 # else
16114 sparc_address_test (arg) int arg;
16115 #endif
16117 static pid_t child;
16118 if (!child) {
16119 child = vfork ();
16120 if (child < 0) {
16121 perror ("vfork");
16122 _exit(2);
16124 if (!child) {
16125 arg = getpid();
16126 write(-1, "", 0);
16127 _exit (arg);
16133 main ()
16135 pid_t parent = getpid ();
16136 pid_t child;
16138 sparc_address_test (0);
16140 child = vfork ();
16142 if (child == 0) {
16143 /* Here is another test for sparc vfork register problems. This
16144 test uses lots of local variables, at least as many local
16145 variables as main has allocated so far including compiler
16146 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16147 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16148 reuse the register of parent for one of the local variables,
16149 since it will think that parent can't possibly be used any more
16150 in this routine. Assigning to the local variable will thus
16151 munge parent in the parent process. */
16152 pid_t
16153 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16154 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16155 /* Convince the compiler that p..p7 are live; otherwise, it might
16156 use the same hardware register for all 8 local variables. */
16157 if (p != p1 || p != p2 || p != p3 || p != p4
16158 || p != p5 || p != p6 || p != p7)
16159 _exit(1);
16161 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16162 from child file descriptors. If the child closes a descriptor
16163 before it execs or exits, this munges the parent's descriptor
16164 as well. Test for this by closing stdout in the child. */
16165 _exit(close(fileno(stdout)) != 0);
16166 } else {
16167 int status;
16168 struct stat st;
16170 while (wait(&status) != child)
16172 return (
16173 /* Was there some problem with vforking? */
16174 child < 0
16176 /* Did the child fail? (This shouldn't happen.) */
16177 || status
16179 /* Did the vfork/compiler bug occur? */
16180 || parent != getpid()
16182 /* Did the file descriptor bug occur? */
16183 || fstat(fileno(stdout), &st) != 0
16187 _ACEOF
16188 if ac_fn_c_try_run "$LINENO"; then :
16189 ac_cv_func_vfork_works=yes
16190 else
16191 ac_cv_func_vfork_works=no
16193 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16194 conftest.$ac_objext conftest.beam conftest.$ac_ext
16198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16199 $as_echo "$ac_cv_func_vfork_works" >&6; }
16202 if test "x$ac_cv_func_fork_works" = xcross; then
16203 ac_cv_func_vfork_works=$ac_cv_func_vfork
16204 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16205 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16208 if test "x$ac_cv_func_vfork_works" = xyes; then
16210 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16212 else
16214 $as_echo "#define vfork fork" >>confdefs.h
16217 if test "x$ac_cv_func_fork_works" = xyes; then
16219 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16224 for ac_func in snprintf
16225 do :
16226 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16227 if test "x$ac_cv_func_snprintf" = x""yes; then :
16228 cat >>confdefs.h <<_ACEOF
16229 #define HAVE_SNPRINTF 1
16230 _ACEOF
16233 done
16236 XGSELOBJ=
16237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16238 $as_echo_n "checking whether GLib is linked in... " >&6; }
16239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16240 /* end confdefs.h. */
16241 #include <glib.h>
16244 main ()
16246 g_print ("Hello world");
16248 return 0;
16250 _ACEOF
16251 if ac_fn_c_try_link "$LINENO"; then :
16252 links_glib=yes
16253 else
16254 links_glib=no
16256 rm -f core conftest.err conftest.$ac_objext \
16257 conftest$ac_exeext conftest.$ac_ext
16258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16259 $as_echo "$links_glib" >&6; }
16260 if test "${links_glib}" = "yes"; then
16262 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16264 if test "$HAVE_NS" = no;then
16265 XGSELOBJ=xgselect.o
16270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16271 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16272 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16273 $as_echo_n "(cached) " >&6
16274 else
16275 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16276 /* end confdefs.h. */
16277 #include <langinfo.h>
16279 main ()
16281 char* cs = nl_langinfo(CODESET);
16283 return 0;
16285 _ACEOF
16286 if ac_fn_c_try_link "$LINENO"; then :
16287 emacs_cv_langinfo_codeset=yes
16288 else
16289 emacs_cv_langinfo_codeset=no
16291 rm -f core conftest.err conftest.$ac_objext \
16292 conftest$ac_exeext conftest.$ac_ext
16295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16296 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16297 if test $emacs_cv_langinfo_codeset = yes; then
16299 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16304 $as_echo_n "checking for mbstate_t... " >&6; }
16305 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16306 $as_echo_n "(cached) " >&6
16307 else
16308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16309 /* end confdefs.h. */
16310 $ac_includes_default
16311 # include <wchar.h>
16313 main ()
16315 mbstate_t x; return sizeof x;
16317 return 0;
16319 _ACEOF
16320 if ac_fn_c_try_compile "$LINENO"; then :
16321 ac_cv_type_mbstate_t=yes
16322 else
16323 ac_cv_type_mbstate_t=no
16325 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16328 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16329 if test $ac_cv_type_mbstate_t = yes; then
16331 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16333 else
16335 $as_echo "#define mbstate_t int" >>confdefs.h
16339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16340 $as_echo_n "checking for C restricted array declarations... " >&6; }
16341 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16342 $as_echo_n "(cached) " >&6
16343 else
16344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16345 /* end confdefs.h. */
16346 void fred (int x[__restrict]);
16348 main ()
16352 return 0;
16354 _ACEOF
16355 if ac_fn_c_try_compile "$LINENO"; then :
16356 emacs_cv_c_restrict_arr=yes
16357 else
16358 emacs_cv_c_restrict_arr=no
16360 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16363 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16364 if test "$emacs_cv_c_restrict_arr" = yes; then
16366 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16371 if test "${opsys}" != "mingw32"; then
16373 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16378 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16381 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16382 if test "${opsys}" != "mingw32"; then
16384 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16389 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16395 if test "${opsys}" = "mingw32"; then
16396 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16398 else
16399 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16404 if test "${opsys}" = "mingw32"; then
16405 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16407 else
16408 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16413 $as_echo "#define subprocesses 1" >>confdefs.h
16417 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16422 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16425 if test "${opsys}" = "mingw32"; then
16427 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == ':')" >>confdefs.h
16431 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16435 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16437 else
16439 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16443 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16447 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16453 case $opsys in
16454 aix4-2)
16455 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16456 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16461 hpux*)
16462 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16465 esac
16468 case $opsys in
16469 irix6-5 | sol2* | unixware )
16471 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16474 esac
16476 emacs_broken_SIGIO=no
16478 case $opsys in
16479 hpux* | irix6-5 | openbsd | sol2* | unixware | gnu-kfreebsd )
16480 emacs_broken_SIGIO=yes
16483 aix4-2)
16485 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16489 freebsd)
16491 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16494 esac
16496 case $opsys in
16497 gnu-* | sol2-10 )
16499 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16502 esac
16504 case $opsys in
16505 darwin | dragonfly | freebsd | netbsd | openbsd )
16507 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16510 esac
16512 case $opsys in
16513 netbsd | openbsd) sound_device="/dev/audio" ;;
16514 *) sound_device="/dev/dsp" ;;
16515 esac
16518 cat >>confdefs.h <<_ACEOF
16519 #define DEFAULT_SOUND_DEVICE "$sound_device"
16520 _ACEOF
16524 case $opsys in
16525 darwin | gnu-linux | gnu-kfreebsd )
16527 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16530 esac
16533 case $opsys in
16534 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16536 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16539 esac
16548 case $opsys in
16549 aix4-2 )
16550 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16552 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16554 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16558 cygwin )
16559 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16561 $as_echo "#define PTY_OPEN do { int dummy; sigset_t blocked, procmask; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, &procmask); if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) fd = -1; pthread_sigmask (SIG_SETMASK, &procmask, 0); if (fd >= 0) emacs_close (dummy); } while (0)" >>confdefs.h
16563 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16565 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16569 darwin )
16570 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16572 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16574 $as_echo "#define PTY_OPEN do { int slave; if (openpty (&fd, &slave, pty_name, NULL, NULL) == -1) fd = -1; else emacs_close (slave); } while (0)" >>confdefs.h
16576 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16578 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16582 gnu | openbsd )
16583 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16587 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16588 if test "x$ac_cv_func_grantpt" = xyes; then
16590 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16592 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16594 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16596 if test "x$ac_cv_func_posix_openpt" = xyes; then
16597 $as_echo "#define PTY_OPEN do { fd = posix_openpt (O_RDWR | O_CLOEXEC | O_NOCTTY); if (fd < 0 && errno == EINVAL) fd = posix_openpt (O_RDWR | O_NOCTTY); } while (0)" >>confdefs.h
16599 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16601 elif test "x$ac_cv_func_getpt" = xyes; then
16602 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16604 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16606 else
16607 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16610 else
16611 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16616 hpux*)
16617 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16619 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16621 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16625 irix6-5 )
16626 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16628 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16630 $as_echo "#define PTY_OPEN { struct sigaction ocstat, cstat; struct stat stb; char * name; sigemptyset(&cstat.sa_mask); cstat.sa_handler = SIG_DFL; cstat.sa_flags = 0; sigaction(SIGCHLD, &cstat, &ocstat); name = _getpty (&fd, O_RDWR | O_NDELAY, 0600, 0); sigaction(SIGCHLD, &ocstat, (struct sigaction *)0); if (name == 0) return -1; if (fd < 0) return -1; if (fstat (fd, &stb) < 0) return -1; strcpy (pty_name, name); }" >>confdefs.h
16632 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16634 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16638 sol2* )
16639 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16643 unixware )
16644 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16647 esac
16650 case $opsys in
16651 sol2* | unixware )
16652 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16654 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16657 $as_echo "#define SETUP_SLAVE_PTY if (ioctl (xforkin, I_PUSH, \"ptem\") == -1) fatal (\"ioctl I_PUSH ptem\"); if (ioctl (xforkin, I_PUSH, \"ldterm\") == -1) fatal (\"ioctl I_PUSH ldterm\"); if (ioctl (xforkin, I_PUSH, \"ttcompat\") == -1) fatal (\"ioctl I_PUSH ttcompat\");" >>confdefs.h
16660 esac
16665 case $opsys in
16666 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
16667 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16671 gnu-linux | gnu-kfreebsd )
16673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
16674 $as_echo_n "checking for signals via characters... " >&6; }
16675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16676 /* end confdefs.h. */
16678 #include <linux/version.h>
16679 #if LINUX_VERSION_CODE < 0x20400
16680 # error "Linux version too old"
16681 #endif
16684 main ()
16688 return 0;
16690 _ACEOF
16691 if ac_fn_c_try_cpp "$LINENO"; then :
16692 emacs_signals_via_chars=yes
16693 else
16694 emacs_signals_via_chars=no
16696 rm -f conftest.err conftest.$ac_ext
16698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
16699 $as_echo "$emacs_signals_via_chars" >&6; }
16700 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16703 esac
16708 case $opsys in
16709 aix*)
16710 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
16713 hpux*)
16714 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
16717 irix6-5)
16718 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
16721 esac
16726 case $opsys in
16727 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
16730 gnu | dragonfly | freebsd | netbsd | openbsd )
16732 $as_echo "#define TABDLY OXTABS" >>confdefs.h
16734 $as_echo "#define TAB3 OXTABS" >>confdefs.h
16738 gnu-linux | gnu-kfreebsd )
16739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16740 /* end confdefs.h. */
16742 #ifndef __ia64__
16743 # error "not ia64"
16744 #endif
16747 main ()
16751 return 0;
16753 _ACEOF
16754 if ac_fn_c_try_cpp "$LINENO"; then :
16756 $as_echo "#define GC_MARK_SECONDARY_STACK() do { extern void *__libc_ia64_register_backing_store_base; __builtin_ia64_flushrs (); mark_memory (__libc_ia64_register_backing_store_base, __builtin_ia64_bsp ());} while (0)" >>confdefs.h
16759 rm -f conftest.err conftest.$ac_ext
16762 hpux*)
16764 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
16767 esac
16773 case $opsys in
16774 gnu-linux | gnu-kfreebsd )
16775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16776 /* end confdefs.h. */
16778 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
16779 || defined __alpha__ || defined __mips__ || defined __s390__ \
16780 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
16781 || defined __ia64__ || defined __sh__
16782 /* ok */
16783 #else
16784 # error "setjmp not known to work on this arch"
16785 #endif
16788 main ()
16792 return 0;
16794 _ACEOF
16795 if ac_fn_c_try_cpp "$LINENO"; then :
16796 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16799 rm -f conftest.err conftest.$ac_ext
16801 esac
16804 if test x$GCC = xyes; then
16805 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16807 else
16808 case $opsys in
16809 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
16810 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16813 esac
16815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
16816 $as_echo_n "checking for _setjmp... " >&6; }
16817 if test "${emacs_cv_func__setjmp+set}" = set; then :
16818 $as_echo_n "(cached) " >&6
16819 else
16820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16821 /* end confdefs.h. */
16822 #include <setjmp.h>
16823 #ifdef __MINGW32__
16824 # define _longjmp longjmp
16825 #endif
16828 main ()
16830 jmp_buf j;
16831 if (! _setjmp (j))
16832 _longjmp (j, 1);
16834 return 0;
16836 _ACEOF
16837 if ac_fn_c_try_link "$LINENO"; then :
16838 emacs_cv_func__setjmp=yes
16839 else
16840 emacs_cv_func__setjmp=no
16842 rm -f core conftest.err conftest.$ac_objext \
16843 conftest$ac_exeext conftest.$ac_ext
16845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
16846 $as_echo "$emacs_cv_func__setjmp" >&6; }
16847 if test $emacs_cv_func__setjmp = yes; then
16849 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
16851 else
16852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
16853 $as_echo_n "checking for sigsetjmp... " >&6; }
16854 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
16855 $as_echo_n "(cached) " >&6
16856 else
16857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16858 /* end confdefs.h. */
16859 #include <setjmp.h>
16862 main ()
16864 sigjmp_buf j;
16865 if (! sigsetjmp (j, 1))
16866 siglongjmp (j, 1);
16868 return 0;
16870 _ACEOF
16871 if ac_fn_c_try_link "$LINENO"; then :
16872 emacs_cv_func_sigsetjmp=yes
16873 else
16874 emacs_cv_func_sigsetjmp=no
16876 rm -f core conftest.err conftest.$ac_objext \
16877 conftest$ac_exeext conftest.$ac_ext
16879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
16880 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
16881 if test $emacs_cv_func_sigsetjmp = yes; then
16883 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
16888 case $opsys in
16889 sol2* | unixware )
16891 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
16894 esac
16897 case $opsys in
16898 hpux* | sol2* )
16900 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
16903 esac
16911 case $opsys in
16912 aix4-2)
16913 $as_echo "#define USG /**/" >>confdefs.h
16915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16916 /* end confdefs.h. */
16918 #ifndef _AIX
16919 # error "_AIX not defined"
16920 #endif
16923 main ()
16927 return 0;
16929 _ACEOF
16930 if ac_fn_c_try_cpp "$LINENO"; then :
16932 else
16934 $as_echo "#define _AIX /**/" >>confdefs.h
16937 rm -f conftest.err conftest.$ac_ext
16940 cygwin)
16942 $as_echo "#define CYGWIN 1" >>confdefs.h
16946 darwin)
16948 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
16952 gnu-linux | gnu-kfreebsd )
16953 $as_echo "#define USG /**/" >>confdefs.h
16956 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
16960 hpux*)
16961 $as_echo "#define USG /**/" >>confdefs.h
16964 $as_echo "#define HPUX /**/" >>confdefs.h
16968 irix6-5)
16969 $as_echo "#define USG /**/" >>confdefs.h
16971 $as_echo "#define USG5_4 /**/" >>confdefs.h
16974 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
16978 mingw32)
16979 $as_echo "#define DOS_NT /**/" >>confdefs.h
16982 $as_echo "#define WINDOWSNT 1" >>confdefs.h
16984 if test "x$ac_enable_checking" != "x" ; then
16986 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
16991 sol2*)
16992 $as_echo "#define USG /**/" >>confdefs.h
16994 $as_echo "#define USG5_4 /**/" >>confdefs.h
16997 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
17001 unixware)
17002 $as_echo "#define USG /**/" >>confdefs.h
17004 $as_echo "#define USG5_4 /**/" >>confdefs.h
17007 esac
17009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
17010 $as_echo_n "checking for usable FIONREAD... " >&6; }
17011 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
17012 $as_echo_n "(cached) " >&6
17013 else
17014 case $opsys in
17015 aix4-2)
17016 emacs_cv_usable_FIONREAD=no
17019 mingw32)
17020 emacs_cv_usable_FIONREAD=yes
17024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17025 /* end confdefs.h. */
17026 #include <sys/types.h>
17027 #include <sys/ioctl.h>
17028 #ifdef USG5_4
17029 # include <sys/filio.h>
17030 #endif
17033 main ()
17035 int foo = ioctl (0, FIONREAD, &foo);
17037 return 0;
17039 _ACEOF
17040 if ac_fn_c_try_compile "$LINENO"; then :
17041 emacs_cv_usable_FIONREAD=yes
17042 else
17043 emacs_cv_usable_FIONREAD=no
17045 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17047 esac
17049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
17050 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
17051 if test $emacs_cv_usable_FIONREAD = yes; then
17053 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
17056 if test $emacs_broken_SIGIO = no; then
17057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
17058 $as_echo_n "checking for usable SIGIO... " >&6; }
17059 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
17060 $as_echo_n "(cached) " >&6
17061 else
17062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17063 /* end confdefs.h. */
17064 #include <fcntl.h>
17065 #include <signal.h>
17068 main ()
17070 int foo = SIGIO | F_SETFL | FASYNC;
17072 return 0;
17074 _ACEOF
17075 if ac_fn_c_try_compile "$LINENO"; then :
17076 emacs_cv_usable_SIGIO=yes
17077 else
17078 emacs_cv_usable_SIGIO=no
17080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
17083 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
17084 if test $emacs_cv_usable_SIGIO = yes; then
17086 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
17093 case $opsys in
17094 cygwin)
17096 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
17100 hpux11)
17102 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
17106 irix6-5)
17108 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
17112 sol2-10)
17114 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
17117 esac
17119 # Set up the CFLAGS for real compilation, so we can substitute it.
17120 CFLAGS="$REAL_CFLAGS"
17121 CPPFLAGS="$REAL_CPPFLAGS"
17123 ## Hack to detect a buggy GCC version.
17124 if test "x$GCC" = xyes \
17125 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17126 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17127 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17128 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17131 version=$PACKAGE_VERSION
17133 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17135 cat >>confdefs.h <<_ACEOF
17136 #define COPYRIGHT "$copyright"
17137 _ACEOF
17141 ### Specify what sort of things we'll be editing into Makefile and config.h.
17142 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17145 ## Unused?
17168 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17169 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17170 ## end of LIBX_BASE, but nothing ever set it.
17175 ## Used in lwlib/Makefile.in.
17184 if test -n "${term_header}"; then
17186 cat >>confdefs.h <<_ACEOF
17187 #define TERM_HEADER "${term_header}"
17188 _ACEOF
17193 cat >>confdefs.h <<_ACEOF
17194 #define EMACS_CONFIGURATION "${canonical}"
17195 _ACEOF
17198 cat >>confdefs.h <<_ACEOF
17199 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17200 _ACEOF
17204 case $opsys in
17205 mingw32)
17206 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17209 esac
17211 XMENU_OBJ=
17212 XOBJ=
17213 FONT_OBJ=
17214 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17216 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17218 XMENU_OBJ=xmenu.o
17219 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17220 FONT_OBJ=xfont.o
17221 if test "$HAVE_XFT" = "yes"; then
17222 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17223 elif test "$HAVE_FREETYPE" = "yes"; then
17224 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17232 WIDGET_OBJ=
17233 MOTIF_LIBW=
17234 if test "${USE_X_TOOLKIT}" != "none" ; then
17235 WIDGET_OBJ=widget.o
17237 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17239 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17241 $as_echo "#define USE_LUCID 1" >>confdefs.h
17243 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17245 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17247 MOTIF_LIBW=-lXm
17248 case "$opsys" in
17249 gnu-linux)
17250 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17251 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17254 unixware)
17255 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17256 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17257 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17260 aix4-2)
17261 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17262 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17264 esac
17265 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17270 TOOLKIT_LIBW=
17271 case "$USE_X_TOOLKIT" in
17272 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17273 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17274 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17275 esac
17278 if test "${opsys}" != "mingw32"; then
17279 if test "$USE_X_TOOLKIT" = "none"; then
17280 LIBXT_OTHER="\$(LIBXSM)"
17281 OLDXMENU_TARGET="really-oldXMenu"
17282 else
17283 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17284 OLDXMENU_TARGET="really-lwlib"
17289 ## The X Menu stuff is present in the X10 distribution, but missing
17290 ## from X11. If we have X10, just use the installed library;
17291 ## otherwise, use our own copy.
17292 if test "${HAVE_X11}" = "yes" ; then
17294 $as_echo "#define HAVE_X11 1" >>confdefs.h
17297 if test "$USE_X_TOOLKIT" = "none"; then
17298 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17299 else
17300 OLDXMENU="\${lwlibdir}/liblw.a"
17302 LIBXMENU="\$(OLDXMENU)"
17303 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17304 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17305 else
17306 ## For a syntactically valid Makefile; not actually used for anything.
17307 ## See comments in src/Makefile.in.
17308 OLDXMENU=nothing
17309 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17310 if test "${HAVE_X_WINDOWS}" = "yes"; then
17311 LIBXMENU="-lXMenu"
17312 else
17313 LIBXMENU=
17315 LIBX_OTHER=
17316 OLDXMENU_DEPS=
17319 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17320 OLDXMENU_TARGET=
17321 OLDXMENU=nothing
17322 LIBXMENU=
17323 OLDXMENU_DEPS=
17332 if test "${HAVE_MENUS}" = "yes" ; then
17334 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17338 if test "${GNU_MALLOC}" = "yes" ; then
17340 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17344 RALLOC_OBJ=
17345 if test "${REL_ALLOC}" = "yes" ; then
17347 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17350 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17354 if test "$opsys" = "cygwin"; then
17355 CYGWIN_OBJ="sheap.o cygw32.o"
17356 ## Cygwin differs because of its unexec().
17357 PRE_ALLOC_OBJ=
17358 POST_ALLOC_OBJ=lastfile.o
17359 elif test "$opsys" = "mingw32"; then
17360 CYGWIN_OBJ=
17361 PRE_ALLOC_OBJ=
17362 POST_ALLOC_OBJ=lastfile.o
17363 else
17364 CYGWIN_OBJ=
17365 PRE_ALLOC_OBJ=lastfile.o
17366 POST_ALLOC_OBJ=
17372 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17373 # it temporarily reverts them to their pre-pkg-config values,
17374 # because gnulib needs to work with both src (which uses the
17375 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17376 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17377 # and it therefore needs to run in an environment where LIBS does not
17378 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17379 # for some package unrelated to lib-src.
17380 SAVE_CFLAGS=$CFLAGS
17381 SAVE_LIBS=$LIBS
17382 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17383 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17395 LIBC_FATAL_STDERR_=1
17396 export LIBC_FATAL_STDERR_
17398 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17399 # for constant arguments. Useless!
17400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17401 $as_echo_n "checking for working alloca.h... " >&6; }
17402 if test "${ac_cv_working_alloca_h+set}" = set; then :
17403 $as_echo_n "(cached) " >&6
17404 else
17405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17406 /* end confdefs.h. */
17407 #include <alloca.h>
17409 main ()
17411 char *p = (char *) alloca (2 * sizeof (int));
17412 if (p) return 0;
17414 return 0;
17416 _ACEOF
17417 if ac_fn_c_try_link "$LINENO"; then :
17418 ac_cv_working_alloca_h=yes
17419 else
17420 ac_cv_working_alloca_h=no
17422 rm -f core conftest.err conftest.$ac_objext \
17423 conftest$ac_exeext conftest.$ac_ext
17425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17426 $as_echo "$ac_cv_working_alloca_h" >&6; }
17427 if test $ac_cv_working_alloca_h = yes; then
17429 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17434 $as_echo_n "checking for alloca... " >&6; }
17435 if test "${ac_cv_func_alloca_works+set}" = set; then :
17436 $as_echo_n "(cached) " >&6
17437 else
17438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17439 /* end confdefs.h. */
17440 #ifdef __GNUC__
17441 # define alloca __builtin_alloca
17442 #else
17443 # ifdef _MSC_VER
17444 # include <malloc.h>
17445 # define alloca _alloca
17446 # else
17447 # ifdef HAVE_ALLOCA_H
17448 # include <alloca.h>
17449 # else
17450 # ifdef _AIX
17451 #pragma alloca
17452 # else
17453 # ifndef alloca /* predefined by HP cc +Olibcalls */
17454 char *alloca ();
17455 # endif
17456 # endif
17457 # endif
17458 # endif
17459 #endif
17462 main ()
17464 char *p = (char *) alloca (1);
17465 if (p) return 0;
17467 return 0;
17469 _ACEOF
17470 if ac_fn_c_try_link "$LINENO"; then :
17471 ac_cv_func_alloca_works=yes
17472 else
17473 ac_cv_func_alloca_works=no
17475 rm -f core conftest.err conftest.$ac_objext \
17476 conftest$ac_exeext conftest.$ac_ext
17478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17479 $as_echo "$ac_cv_func_alloca_works" >&6; }
17481 if test $ac_cv_func_alloca_works = yes; then
17483 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17485 else
17486 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17487 # that cause trouble. Some versions do not even contain alloca or
17488 # contain a buggy version. If you still want to use their alloca,
17489 # use ar to extract alloca.o from them instead of compiling alloca.c.
17495 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17497 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17501 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17502 if test "${ac_cv_os_cray+set}" = set; then :
17503 $as_echo_n "(cached) " >&6
17504 else
17505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17506 /* end confdefs.h. */
17507 #if defined CRAY && ! defined CRAY2
17508 webecray
17509 #else
17510 wenotbecray
17511 #endif
17513 _ACEOF
17514 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17515 $EGREP "webecray" >/dev/null 2>&1; then :
17516 ac_cv_os_cray=yes
17517 else
17518 ac_cv_os_cray=no
17520 rm -f conftest*
17523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17524 $as_echo "$ac_cv_os_cray" >&6; }
17525 if test $ac_cv_os_cray = yes; then
17526 for ac_func in _getb67 GETB67 getb67; do
17527 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17528 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17529 eval as_val=\$$as_ac_var
17530 if test "x$as_val" = x""yes; then :
17532 cat >>confdefs.h <<_ACEOF
17533 #define CRAY_STACKSEG_END $ac_func
17534 _ACEOF
17536 break
17539 done
17542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17543 $as_echo_n "checking stack direction for C alloca... " >&6; }
17544 if test "${ac_cv_c_stack_direction+set}" = set; then :
17545 $as_echo_n "(cached) " >&6
17546 else
17547 if test "$cross_compiling" = yes; then :
17548 ac_cv_c_stack_direction=0
17549 else
17550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17551 /* end confdefs.h. */
17552 $ac_includes_default
17554 find_stack_direction (int *addr, int depth)
17556 int dir, dummy = 0;
17557 if (! addr)
17558 addr = &dummy;
17559 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17560 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17561 return dir + dummy;
17565 main (int argc, char **argv)
17567 return find_stack_direction (0, argc + !argv + 20) < 0;
17569 _ACEOF
17570 if ac_fn_c_try_run "$LINENO"; then :
17571 ac_cv_c_stack_direction=1
17572 else
17573 ac_cv_c_stack_direction=-1
17575 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17576 conftest.$ac_objext conftest.beam conftest.$ac_ext
17580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17581 $as_echo "$ac_cv_c_stack_direction" >&6; }
17582 cat >>confdefs.h <<_ACEOF
17583 #define STACK_DIRECTION $ac_cv_c_stack_direction
17584 _ACEOF
17592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17593 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17594 if test "${ac_cv_c_bigendian+set}" = set; then :
17595 $as_echo_n "(cached) " >&6
17596 else
17597 ac_cv_c_bigendian=unknown
17598 # See if we're dealing with a universal compiler.
17599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17600 /* end confdefs.h. */
17601 #ifndef __APPLE_CC__
17602 not a universal capable compiler
17603 #endif
17604 typedef int dummy;
17606 _ACEOF
17607 if ac_fn_c_try_compile "$LINENO"; then :
17609 # Check for potential -arch flags. It is not universal unless
17610 # there are at least two -arch flags with different values.
17611 ac_arch=
17612 ac_prev=
17613 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17614 if test -n "$ac_prev"; then
17615 case $ac_word in
17616 i?86 | x86_64 | ppc | ppc64)
17617 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17618 ac_arch=$ac_word
17619 else
17620 ac_cv_c_bigendian=universal
17621 break
17624 esac
17625 ac_prev=
17626 elif test "x$ac_word" = "x-arch"; then
17627 ac_prev=arch
17629 done
17631 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17632 if test $ac_cv_c_bigendian = unknown; then
17633 # See if sys/param.h defines the BYTE_ORDER macro.
17634 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17635 /* end confdefs.h. */
17636 #include <sys/types.h>
17637 #include <sys/param.h>
17640 main ()
17642 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17643 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17644 && LITTLE_ENDIAN)
17645 bogus endian macros
17646 #endif
17649 return 0;
17651 _ACEOF
17652 if ac_fn_c_try_compile "$LINENO"; then :
17653 # It does; now see whether it defined to BIG_ENDIAN or not.
17654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17655 /* end confdefs.h. */
17656 #include <sys/types.h>
17657 #include <sys/param.h>
17660 main ()
17662 #if BYTE_ORDER != BIG_ENDIAN
17663 not big endian
17664 #endif
17667 return 0;
17669 _ACEOF
17670 if ac_fn_c_try_compile "$LINENO"; then :
17671 ac_cv_c_bigendian=yes
17672 else
17673 ac_cv_c_bigendian=no
17675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17679 if test $ac_cv_c_bigendian = unknown; then
17680 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
17681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17682 /* end confdefs.h. */
17683 #include <limits.h>
17686 main ()
17688 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
17689 bogus endian macros
17690 #endif
17693 return 0;
17695 _ACEOF
17696 if ac_fn_c_try_compile "$LINENO"; then :
17697 # It does; now see whether it defined to _BIG_ENDIAN or not.
17698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17699 /* end confdefs.h. */
17700 #include <limits.h>
17703 main ()
17705 #ifndef _BIG_ENDIAN
17706 not big endian
17707 #endif
17710 return 0;
17712 _ACEOF
17713 if ac_fn_c_try_compile "$LINENO"; then :
17714 ac_cv_c_bigendian=yes
17715 else
17716 ac_cv_c_bigendian=no
17718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17722 if test $ac_cv_c_bigendian = unknown; then
17723 # Compile a test program.
17724 if test "$cross_compiling" = yes; then :
17725 # Try to guess by grepping values from an object file.
17726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17727 /* end confdefs.h. */
17728 short int ascii_mm[] =
17729 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
17730 short int ascii_ii[] =
17731 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17732 int use_ascii (int i) {
17733 return ascii_mm[i] + ascii_ii[i];
17735 short int ebcdic_ii[] =
17736 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
17737 short int ebcdic_mm[] =
17738 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17739 int use_ebcdic (int i) {
17740 return ebcdic_mm[i] + ebcdic_ii[i];
17742 extern int foo;
17745 main ()
17747 return use_ascii (foo) == use_ebcdic (foo);
17749 return 0;
17751 _ACEOF
17752 if ac_fn_c_try_compile "$LINENO"; then :
17753 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
17754 ac_cv_c_bigendian=yes
17756 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
17757 if test "$ac_cv_c_bigendian" = unknown; then
17758 ac_cv_c_bigendian=no
17759 else
17760 # finding both strings is unlikely to happen, but who knows?
17761 ac_cv_c_bigendian=unknown
17765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17766 else
17767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17768 /* end confdefs.h. */
17769 $ac_includes_default
17771 main ()
17774 /* Are we little or big endian? From Harbison&Steele. */
17775 union
17777 long int l;
17778 char c[sizeof (long int)];
17779 } u;
17780 u.l = 1;
17781 return u.c[sizeof (long int) - 1] == 1;
17784 return 0;
17786 _ACEOF
17787 if ac_fn_c_try_run "$LINENO"; then :
17788 ac_cv_c_bigendian=no
17789 else
17790 ac_cv_c_bigendian=yes
17792 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17793 conftest.$ac_objext conftest.beam conftest.$ac_ext
17798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
17799 $as_echo "$ac_cv_c_bigendian" >&6; }
17800 case $ac_cv_c_bigendian in #(
17801 yes)
17802 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
17803 ;; #(
17805 ;; #(
17806 universal)
17808 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
17810 ;; #(
17812 as_fn_error "unknown endianness
17813 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
17814 esac
17818 GNULIB_CHDIR=0;
17819 GNULIB_CHOWN=0;
17820 GNULIB_CLOSE=0;
17821 GNULIB_DUP=0;
17822 GNULIB_DUP2=0;
17823 GNULIB_DUP3=0;
17824 GNULIB_ENVIRON=0;
17825 GNULIB_EUIDACCESS=0;
17826 GNULIB_FACCESSAT=0;
17827 GNULIB_FCHDIR=0;
17828 GNULIB_FCHOWNAT=0;
17829 GNULIB_FDATASYNC=0;
17830 GNULIB_FSYNC=0;
17831 GNULIB_FTRUNCATE=0;
17832 GNULIB_GETCWD=0;
17833 GNULIB_GETDOMAINNAME=0;
17834 GNULIB_GETDTABLESIZE=0;
17835 GNULIB_GETGROUPS=0;
17836 GNULIB_GETHOSTNAME=0;
17837 GNULIB_GETLOGIN=0;
17838 GNULIB_GETLOGIN_R=0;
17839 GNULIB_GETPAGESIZE=0;
17840 GNULIB_GETUSERSHELL=0;
17841 GNULIB_GROUP_MEMBER=0;
17842 GNULIB_ISATTY=0;
17843 GNULIB_LCHOWN=0;
17844 GNULIB_LINK=0;
17845 GNULIB_LINKAT=0;
17846 GNULIB_LSEEK=0;
17847 GNULIB_PIPE=0;
17848 GNULIB_PIPE2=0;
17849 GNULIB_PREAD=0;
17850 GNULIB_PWRITE=0;
17851 GNULIB_READ=0;
17852 GNULIB_READLINK=0;
17853 GNULIB_READLINKAT=0;
17854 GNULIB_RMDIR=0;
17855 GNULIB_SETHOSTNAME=0;
17856 GNULIB_SLEEP=0;
17857 GNULIB_SYMLINK=0;
17858 GNULIB_SYMLINKAT=0;
17859 GNULIB_TTYNAME_R=0;
17860 GNULIB_UNISTD_H_NONBLOCKING=0;
17861 GNULIB_UNISTD_H_SIGPIPE=0;
17862 GNULIB_UNLINK=0;
17863 GNULIB_UNLINKAT=0;
17864 GNULIB_USLEEP=0;
17865 GNULIB_WRITE=0;
17866 HAVE_CHOWN=1;
17867 HAVE_DUP2=1;
17868 HAVE_DUP3=1;
17869 HAVE_EUIDACCESS=1;
17870 HAVE_FACCESSAT=1;
17871 HAVE_FCHDIR=1;
17872 HAVE_FCHOWNAT=1;
17873 HAVE_FDATASYNC=1;
17874 HAVE_FSYNC=1;
17875 HAVE_FTRUNCATE=1;
17876 HAVE_GETDTABLESIZE=1;
17877 HAVE_GETGROUPS=1;
17878 HAVE_GETHOSTNAME=1;
17879 HAVE_GETLOGIN=1;
17880 HAVE_GETPAGESIZE=1;
17881 HAVE_GROUP_MEMBER=1;
17882 HAVE_LCHOWN=1;
17883 HAVE_LINK=1;
17884 HAVE_LINKAT=1;
17885 HAVE_PIPE=1;
17886 HAVE_PIPE2=1;
17887 HAVE_PREAD=1;
17888 HAVE_PWRITE=1;
17889 HAVE_READLINK=1;
17890 HAVE_READLINKAT=1;
17891 HAVE_SETHOSTNAME=1;
17892 HAVE_SLEEP=1;
17893 HAVE_SYMLINK=1;
17894 HAVE_SYMLINKAT=1;
17895 HAVE_UNLINKAT=1;
17896 HAVE_USLEEP=1;
17897 HAVE_DECL_ENVIRON=1;
17898 HAVE_DECL_FCHDIR=1;
17899 HAVE_DECL_FDATASYNC=1;
17900 HAVE_DECL_GETDOMAINNAME=1;
17901 HAVE_DECL_GETLOGIN_R=1;
17902 HAVE_DECL_GETPAGESIZE=1;
17903 HAVE_DECL_GETUSERSHELL=1;
17904 HAVE_DECL_SETHOSTNAME=1;
17905 HAVE_DECL_TTYNAME_R=1;
17906 HAVE_OS_H=0;
17907 HAVE_SYS_PARAM_H=0;
17908 REPLACE_CHOWN=0;
17909 REPLACE_CLOSE=0;
17910 REPLACE_DUP=0;
17911 REPLACE_DUP2=0;
17912 REPLACE_FCHOWNAT=0;
17913 REPLACE_FTRUNCATE=0;
17914 REPLACE_GETCWD=0;
17915 REPLACE_GETDOMAINNAME=0;
17916 REPLACE_GETLOGIN_R=0;
17917 REPLACE_GETGROUPS=0;
17918 REPLACE_GETPAGESIZE=0;
17919 REPLACE_ISATTY=0;
17920 REPLACE_LCHOWN=0;
17921 REPLACE_LINK=0;
17922 REPLACE_LINKAT=0;
17923 REPLACE_LSEEK=0;
17924 REPLACE_PREAD=0;
17925 REPLACE_PWRITE=0;
17926 REPLACE_READ=0;
17927 REPLACE_READLINK=0;
17928 REPLACE_RMDIR=0;
17929 REPLACE_SLEEP=0;
17930 REPLACE_SYMLINK=0;
17931 REPLACE_TTYNAME_R=0;
17932 REPLACE_UNLINK=0;
17933 REPLACE_UNLINKAT=0;
17934 REPLACE_USLEEP=0;
17935 REPLACE_WRITE=0;
17936 UNISTD_H_HAVE_WINSOCK2_H=0;
17937 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
17941 GNULIB_OPENDIR=0;
17942 GNULIB_READDIR=0;
17943 GNULIB_REWINDDIR=0;
17944 GNULIB_CLOSEDIR=0;
17945 GNULIB_DIRFD=0;
17946 GNULIB_FDOPENDIR=0;
17947 GNULIB_SCANDIR=0;
17948 GNULIB_ALPHASORT=0;
17949 HAVE_OPENDIR=1;
17950 HAVE_READDIR=1;
17951 HAVE_REWINDDIR=1;
17952 HAVE_CLOSEDIR=1;
17953 HAVE_DECL_DIRFD=1;
17954 HAVE_DECL_FDOPENDIR=1;
17955 HAVE_FDOPENDIR=1;
17956 HAVE_SCANDIR=1;
17957 HAVE_ALPHASORT=1;
17958 REPLACE_OPENDIR=0;
17959 REPLACE_CLOSEDIR=0;
17960 REPLACE_DIRFD=0;
17961 REPLACE_FDOPENDIR=0;
17965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
17966 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
17967 if test "${gl_cv_have_include_next+set}" = set; then :
17968 $as_echo_n "(cached) " >&6
17969 else
17970 rm -rf conftestd1a conftestd1b conftestd2
17971 mkdir conftestd1a conftestd1b conftestd2
17972 cat <<EOF > conftestd1a/conftest.h
17973 #define DEFINED_IN_CONFTESTD1
17974 #include_next <conftest.h>
17975 #ifdef DEFINED_IN_CONFTESTD2
17976 int foo;
17977 #else
17978 #error "include_next doesn't work"
17979 #endif
17981 cat <<EOF > conftestd1b/conftest.h
17982 #define DEFINED_IN_CONFTESTD1
17983 #include <stdio.h>
17984 #include_next <conftest.h>
17985 #ifdef DEFINED_IN_CONFTESTD2
17986 int foo;
17987 #else
17988 #error "include_next doesn't work"
17989 #endif
17991 cat <<EOF > conftestd2/conftest.h
17992 #ifndef DEFINED_IN_CONFTESTD1
17993 #error "include_next test doesn't work"
17994 #endif
17995 #define DEFINED_IN_CONFTESTD2
17997 gl_save_CPPFLAGS="$CPPFLAGS"
17998 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18000 /* end confdefs.h. */
18001 #include <conftest.h>
18002 _ACEOF
18003 if ac_fn_c_try_compile "$LINENO"; then :
18004 gl_cv_have_include_next=yes
18005 else
18006 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
18007 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18008 /* end confdefs.h. */
18009 #include <conftest.h>
18010 _ACEOF
18011 if ac_fn_c_try_compile "$LINENO"; then :
18012 gl_cv_have_include_next=buggy
18013 else
18014 gl_cv_have_include_next=no
18016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18019 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18020 CPPFLAGS="$gl_save_CPPFLAGS"
18021 rm -rf conftestd1a conftestd1b conftestd2
18024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
18025 $as_echo "$gl_cv_have_include_next" >&6; }
18026 PRAGMA_SYSTEM_HEADER=
18027 if test $gl_cv_have_include_next = yes; then
18028 INCLUDE_NEXT=include_next
18029 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18030 if test -n "$GCC"; then
18031 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
18033 else
18034 if test $gl_cv_have_include_next = buggy; then
18035 INCLUDE_NEXT=include
18036 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18037 else
18038 INCLUDE_NEXT=include
18039 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
18045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
18046 $as_echo_n "checking whether system header files limit the line length... " >&6; }
18047 if test "${gl_cv_pragma_columns+set}" = set; then :
18048 $as_echo_n "(cached) " >&6
18049 else
18050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18051 /* end confdefs.h. */
18053 #ifdef __TANDEM
18054 choke me
18055 #endif
18057 _ACEOF
18058 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18059 $EGREP "choke me" >/dev/null 2>&1; then :
18060 gl_cv_pragma_columns=yes
18061 else
18062 gl_cv_pragma_columns=no
18064 rm -f conftest*
18068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
18069 $as_echo "$gl_cv_pragma_columns" >&6; }
18070 if test $gl_cv_pragma_columns = yes; then
18071 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
18072 else
18073 PRAGMA_COLUMNS=
18080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
18081 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
18082 if test "${gl_cv_func_c99_strtold+set}" = set; then :
18083 $as_echo_n "(cached) " >&6
18084 else
18085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18086 /* end confdefs.h. */
18087 /* On HP-UX before 11.23, strtold returns a struct instead of
18088 long double. Reject implementations like that, by requiring
18089 compatibility with the C99 prototype. */
18090 #include <stdlib.h>
18091 static long double (*p) (char const *, char **) = strtold;
18092 static long double
18093 test (char const *nptr, char **endptr)
18095 long double r;
18096 r = strtold (nptr, endptr);
18097 return r;
18100 main ()
18102 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
18104 return 0;
18106 _ACEOF
18107 if ac_fn_c_try_link "$LINENO"; then :
18108 gl_cv_func_c99_strtold=yes
18109 else
18110 gl_cv_func_c99_strtold=no
18112 rm -f core conftest.err conftest.$ac_objext \
18113 conftest$ac_exeext conftest.$ac_ext
18115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
18116 $as_echo "$gl_cv_func_c99_strtold" >&6; }
18117 if test $gl_cv_func_c99_strtold = yes; then
18119 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18131 $as_echo_n "checking if environ is properly declared... " >&6; }
18132 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18133 $as_echo_n "(cached) " >&6
18134 else
18136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18137 /* end confdefs.h. */
18138 #if HAVE_UNISTD_H
18139 #include <unistd.h>
18140 #endif
18141 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18142 #include <stdlib.h>
18144 extern struct { int foo; } environ;
18146 main ()
18148 environ.foo = 1;
18150 return 0;
18152 _ACEOF
18153 if ac_fn_c_try_compile "$LINENO"; then :
18154 gt_cv_var_environ_declaration=no
18155 else
18156 gt_cv_var_environ_declaration=yes
18158 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18162 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18163 if test $gt_cv_var_environ_declaration = yes; then
18165 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18170 if test $gt_cv_var_environ_declaration != yes; then
18171 HAVE_DECL_ENVIRON=0
18176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18177 $as_echo_n "checking for complete errno.h... " >&6; }
18178 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18179 $as_echo_n "(cached) " >&6
18180 else
18182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18183 /* end confdefs.h. */
18185 #include <errno.h>
18186 #if !defined ETXTBSY
18187 booboo
18188 #endif
18189 #if !defined ENOMSG
18190 booboo
18191 #endif
18192 #if !defined EIDRM
18193 booboo
18194 #endif
18195 #if !defined ENOLINK
18196 booboo
18197 #endif
18198 #if !defined EPROTO
18199 booboo
18200 #endif
18201 #if !defined EMULTIHOP
18202 booboo
18203 #endif
18204 #if !defined EBADMSG
18205 booboo
18206 #endif
18207 #if !defined EOVERFLOW
18208 booboo
18209 #endif
18210 #if !defined ENOTSUP
18211 booboo
18212 #endif
18213 #if !defined ENETRESET
18214 booboo
18215 #endif
18216 #if !defined ECONNABORTED
18217 booboo
18218 #endif
18219 #if !defined ESTALE
18220 booboo
18221 #endif
18222 #if !defined EDQUOT
18223 booboo
18224 #endif
18225 #if !defined ECANCELED
18226 booboo
18227 #endif
18228 #if !defined EOWNERDEAD
18229 booboo
18230 #endif
18231 #if !defined ENOTRECOVERABLE
18232 booboo
18233 #endif
18234 #if !defined EILSEQ
18235 booboo
18236 #endif
18238 _ACEOF
18239 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18240 $EGREP "booboo" >/dev/null 2>&1; then :
18241 gl_cv_header_errno_h_complete=no
18242 else
18243 gl_cv_header_errno_h_complete=yes
18245 rm -f conftest*
18249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18250 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18251 if test $gl_cv_header_errno_h_complete = yes; then
18252 ERRNO_H=''
18253 else
18262 if test $gl_cv_have_include_next = yes; then
18263 gl_cv_next_errno_h='<'errno.h'>'
18264 else
18265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18266 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18267 if test "${gl_cv_next_errno_h+set}" = set; then :
18268 $as_echo_n "(cached) " >&6
18269 else
18271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18272 /* end confdefs.h. */
18273 #include <errno.h>
18275 _ACEOF
18276 case "$host_os" in
18277 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18278 *) gl_absname_cpp="$ac_cpp" ;;
18279 esac
18281 case "$host_os" in
18282 mingw*)
18283 gl_dirsep_regex='[/\\]'
18286 gl_dirsep_regex='\/'
18288 esac
18289 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18291 gl_header_literal_regex=`echo 'errno.h' \
18292 | sed -e "$gl_make_literal_regex_sed"`
18293 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18294 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18295 s|^/[^/]|//&|
18299 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18300 sed -n "$gl_absolute_header_sed"`'"'
18304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18305 $as_echo "$gl_cv_next_errno_h" >&6; }
18307 NEXT_ERRNO_H=$gl_cv_next_errno_h
18309 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18310 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18311 gl_next_as_first_directive='<'errno.h'>'
18312 else
18313 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18314 gl_next_as_first_directive=$gl_cv_next_errno_h
18316 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18321 ERRNO_H='errno.h'
18324 if test -n "$ERRNO_H"; then
18325 GL_GENERATE_ERRNO_H_TRUE=
18326 GL_GENERATE_ERRNO_H_FALSE='#'
18327 else
18328 GL_GENERATE_ERRNO_H_TRUE='#'
18329 GL_GENERATE_ERRNO_H_FALSE=
18333 if test -n "$ERRNO_H"; then
18334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18335 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18336 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18337 $as_echo_n "(cached) " >&6
18338 else
18340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18341 /* end confdefs.h. */
18343 #include <errno.h>
18344 #ifdef EMULTIHOP
18346 #endif
18348 _ACEOF
18349 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18350 $EGREP "yes" >/dev/null 2>&1; then :
18351 gl_cv_header_errno_h_EMULTIHOP=yes
18352 else
18353 gl_cv_header_errno_h_EMULTIHOP=no
18355 rm -f conftest*
18357 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18359 /* end confdefs.h. */
18361 #define _XOPEN_SOURCE_EXTENDED 1
18362 #include <errno.h>
18363 #ifdef EMULTIHOP
18365 #endif
18367 _ACEOF
18368 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18369 $EGREP "yes" >/dev/null 2>&1; then :
18370 gl_cv_header_errno_h_EMULTIHOP=hidden
18372 rm -f conftest*
18374 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18375 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18376 #define _XOPEN_SOURCE_EXTENDED 1
18377 #include <errno.h>
18378 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18379 #include <stdio.h>
18380 #include <stdlib.h>
18381 "; then :
18389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18390 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18391 case $gl_cv_header_errno_h_EMULTIHOP in
18392 yes | no)
18393 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18396 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18398 esac
18404 if test -n "$ERRNO_H"; then
18405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18406 $as_echo_n "checking for ENOLINK value... " >&6; }
18407 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18408 $as_echo_n "(cached) " >&6
18409 else
18411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18412 /* end confdefs.h. */
18414 #include <errno.h>
18415 #ifdef ENOLINK
18417 #endif
18419 _ACEOF
18420 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18421 $EGREP "yes" >/dev/null 2>&1; then :
18422 gl_cv_header_errno_h_ENOLINK=yes
18423 else
18424 gl_cv_header_errno_h_ENOLINK=no
18426 rm -f conftest*
18428 if test $gl_cv_header_errno_h_ENOLINK = no; then
18429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18430 /* end confdefs.h. */
18432 #define _XOPEN_SOURCE_EXTENDED 1
18433 #include <errno.h>
18434 #ifdef ENOLINK
18436 #endif
18438 _ACEOF
18439 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18440 $EGREP "yes" >/dev/null 2>&1; then :
18441 gl_cv_header_errno_h_ENOLINK=hidden
18443 rm -f conftest*
18445 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18446 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18447 #define _XOPEN_SOURCE_EXTENDED 1
18448 #include <errno.h>
18449 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18450 #include <stdio.h>
18451 #include <stdlib.h>
18452 "; then :
18460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18461 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18462 case $gl_cv_header_errno_h_ENOLINK in
18463 yes | no)
18464 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18467 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18469 esac
18475 if test -n "$ERRNO_H"; then
18476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18477 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18478 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18479 $as_echo_n "(cached) " >&6
18480 else
18482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18483 /* end confdefs.h. */
18485 #include <errno.h>
18486 #ifdef EOVERFLOW
18488 #endif
18490 _ACEOF
18491 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18492 $EGREP "yes" >/dev/null 2>&1; then :
18493 gl_cv_header_errno_h_EOVERFLOW=yes
18494 else
18495 gl_cv_header_errno_h_EOVERFLOW=no
18497 rm -f conftest*
18499 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18501 /* end confdefs.h. */
18503 #define _XOPEN_SOURCE_EXTENDED 1
18504 #include <errno.h>
18505 #ifdef EOVERFLOW
18507 #endif
18509 _ACEOF
18510 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18511 $EGREP "yes" >/dev/null 2>&1; then :
18512 gl_cv_header_errno_h_EOVERFLOW=hidden
18514 rm -f conftest*
18516 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18517 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18518 #define _XOPEN_SOURCE_EXTENDED 1
18519 #include <errno.h>
18520 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18521 #include <stdio.h>
18522 #include <stdlib.h>
18523 "; then :
18531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18532 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18533 case $gl_cv_header_errno_h_EOVERFLOW in
18534 yes | no)
18535 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18538 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18540 esac
18554 GNULIB_FCNTL=0;
18555 GNULIB_NONBLOCKING=0;
18556 GNULIB_OPEN=0;
18557 GNULIB_OPENAT=0;
18558 HAVE_FCNTL=1;
18559 HAVE_OPENAT=1;
18560 REPLACE_FCNTL=0;
18561 REPLACE_OPEN=0;
18562 REPLACE_OPENAT=0;
18567 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18568 if test "x$ac_cv_type_mode_t" = x""yes; then :
18570 else
18572 cat >>confdefs.h <<_ACEOF
18573 #define mode_t int
18574 _ACEOF
18578 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18579 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18580 ac_have_decl=1
18581 else
18582 ac_have_decl=0
18585 cat >>confdefs.h <<_ACEOF
18586 #define HAVE_DECL_FDATASYNC $ac_have_decl
18587 _ACEOF
18591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18592 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18593 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18594 $as_echo_n "(cached) " >&6
18595 else
18596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18597 /* end confdefs.h. */
18599 #include <sys/types.h>
18600 #include <sys/stat.h>
18602 main ()
18604 struct stat s; s.st_dm_mode;
18606 return 0;
18608 _ACEOF
18609 if ac_fn_c_try_compile "$LINENO"; then :
18610 ac_cv_struct_st_dm_mode=yes
18611 else
18612 ac_cv_struct_st_dm_mode=no
18614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
18617 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
18619 if test $ac_cv_struct_st_dm_mode = yes; then
18621 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
18626 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
18627 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
18628 ac_have_decl=1
18629 else
18630 ac_have_decl=0
18633 cat >>confdefs.h <<_ACEOF
18634 #define HAVE_DECL_STRMODE $ac_have_decl
18635 _ACEOF
18640 GNULIB_FCHMODAT=0;
18641 GNULIB_FSTAT=0;
18642 GNULIB_FSTATAT=0;
18643 GNULIB_FUTIMENS=0;
18644 GNULIB_LCHMOD=0;
18645 GNULIB_LSTAT=0;
18646 GNULIB_MKDIRAT=0;
18647 GNULIB_MKFIFO=0;
18648 GNULIB_MKFIFOAT=0;
18649 GNULIB_MKNOD=0;
18650 GNULIB_MKNODAT=0;
18651 GNULIB_STAT=0;
18652 GNULIB_UTIMENSAT=0;
18653 HAVE_FCHMODAT=1;
18654 HAVE_FSTATAT=1;
18655 HAVE_FUTIMENS=1;
18656 HAVE_LCHMOD=1;
18657 HAVE_LSTAT=1;
18658 HAVE_MKDIRAT=1;
18659 HAVE_MKFIFO=1;
18660 HAVE_MKFIFOAT=1;
18661 HAVE_MKNOD=1;
18662 HAVE_MKNODAT=1;
18663 HAVE_UTIMENSAT=1;
18664 REPLACE_FSTAT=0;
18665 REPLACE_FSTATAT=0;
18666 REPLACE_FUTIMENS=0;
18667 REPLACE_LSTAT=0;
18668 REPLACE_MKDIR=0;
18669 REPLACE_MKFIFO=0;
18670 REPLACE_MKNOD=0;
18671 REPLACE_STAT=0;
18672 REPLACE_UTIMENSAT=0;
18675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18676 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18677 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18678 $as_echo_n "(cached) " >&6
18679 else
18680 rm -f conftest.sym conftest.file
18681 echo >conftest.file
18682 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18683 if test "$cross_compiling" = yes; then :
18684 case "$host_os" in
18685 # Guess yes on glibc systems.
18686 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18687 # If we don't know, assume the worst.
18688 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18689 esac
18691 else
18692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18693 /* end confdefs.h. */
18694 $ac_includes_default
18696 main ()
18698 struct stat sbuf;
18699 /* Linux will dereference the symlink and fail, as required by
18700 POSIX. That is better in the sense that it means we will not
18701 have to compile and use the lstat wrapper. */
18702 return lstat ("conftest.sym/", &sbuf) == 0;
18705 return 0;
18707 _ACEOF
18708 if ac_fn_c_try_run "$LINENO"; then :
18709 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18710 else
18711 gl_cv_func_lstat_dereferences_slashed_symlink=no
18713 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18714 conftest.$ac_objext conftest.beam conftest.$ac_ext
18717 else
18718 # If the 'ln -s' command failed, then we probably don't even
18719 # have an lstat function.
18720 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18722 rm -f conftest.sym conftest.file
18725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18726 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18727 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18728 *yes)
18730 cat >>confdefs.h <<_ACEOF
18731 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18732 _ACEOF
18735 esac
18742 GNULIB__EXIT=0;
18743 GNULIB_ATOLL=0;
18744 GNULIB_CALLOC_POSIX=0;
18745 GNULIB_CANONICALIZE_FILE_NAME=0;
18746 GNULIB_GETLOADAVG=0;
18747 GNULIB_GETSUBOPT=0;
18748 GNULIB_GRANTPT=0;
18749 GNULIB_MALLOC_POSIX=0;
18750 GNULIB_MBTOWC=0;
18751 GNULIB_MKDTEMP=0;
18752 GNULIB_MKOSTEMP=0;
18753 GNULIB_MKOSTEMPS=0;
18754 GNULIB_MKSTEMP=0;
18755 GNULIB_MKSTEMPS=0;
18756 GNULIB_POSIX_OPENPT=0;
18757 GNULIB_PTSNAME=0;
18758 GNULIB_PTSNAME_R=0;
18759 GNULIB_PUTENV=0;
18760 GNULIB_RANDOM=0;
18761 GNULIB_RANDOM_R=0;
18762 GNULIB_REALLOC_POSIX=0;
18763 GNULIB_REALPATH=0;
18764 GNULIB_RPMATCH=0;
18765 GNULIB_SECURE_GETENV=0;
18766 GNULIB_SETENV=0;
18767 GNULIB_STRTOD=0;
18768 GNULIB_STRTOLL=0;
18769 GNULIB_STRTOULL=0;
18770 GNULIB_SYSTEM_POSIX=0;
18771 GNULIB_UNLOCKPT=0;
18772 GNULIB_UNSETENV=0;
18773 GNULIB_WCTOMB=0;
18774 HAVE__EXIT=1;
18775 HAVE_ATOLL=1;
18776 HAVE_CANONICALIZE_FILE_NAME=1;
18777 HAVE_DECL_GETLOADAVG=1;
18778 HAVE_GETSUBOPT=1;
18779 HAVE_GRANTPT=1;
18780 HAVE_MKDTEMP=1;
18781 HAVE_MKOSTEMP=1;
18782 HAVE_MKOSTEMPS=1;
18783 HAVE_MKSTEMP=1;
18784 HAVE_MKSTEMPS=1;
18785 HAVE_POSIX_OPENPT=1;
18786 HAVE_PTSNAME=1;
18787 HAVE_PTSNAME_R=1;
18788 HAVE_RANDOM=1;
18789 HAVE_RANDOM_H=1;
18790 HAVE_RANDOM_R=1;
18791 HAVE_REALPATH=1;
18792 HAVE_RPMATCH=1;
18793 HAVE_SECURE_GETENV=1;
18794 HAVE_SETENV=1;
18795 HAVE_DECL_SETENV=1;
18796 HAVE_STRTOD=1;
18797 HAVE_STRTOLL=1;
18798 HAVE_STRTOULL=1;
18799 HAVE_STRUCT_RANDOM_DATA=1;
18800 HAVE_SYS_LOADAVG_H=0;
18801 HAVE_UNLOCKPT=1;
18802 HAVE_DECL_UNSETENV=1;
18803 REPLACE_CALLOC=0;
18804 REPLACE_CANONICALIZE_FILE_NAME=0;
18805 REPLACE_MALLOC=0;
18806 REPLACE_MBTOWC=0;
18807 REPLACE_MKSTEMP=0;
18808 REPLACE_PTSNAME=0;
18809 REPLACE_PTSNAME_R=0;
18810 REPLACE_PUTENV=0;
18811 REPLACE_RANDOM_R=0;
18812 REPLACE_REALLOC=0;
18813 REPLACE_REALPATH=0;
18814 REPLACE_SETENV=0;
18815 REPLACE_STRTOD=0;
18816 REPLACE_UNSETENV=0;
18817 REPLACE_WCTOMB=0;
18834 if test $gl_cv_have_include_next = yes; then
18835 gl_cv_next_getopt_h='<'getopt.h'>'
18836 else
18837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
18838 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
18839 if test "${gl_cv_next_getopt_h+set}" = set; then :
18840 $as_echo_n "(cached) " >&6
18841 else
18843 if test $ac_cv_header_getopt_h = yes; then
18846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18847 /* end confdefs.h. */
18848 #include <getopt.h>
18850 _ACEOF
18851 case "$host_os" in
18852 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18853 *) gl_absname_cpp="$ac_cpp" ;;
18854 esac
18856 case "$host_os" in
18857 mingw*)
18858 gl_dirsep_regex='[/\\]'
18861 gl_dirsep_regex='\/'
18863 esac
18864 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18866 gl_header_literal_regex=`echo 'getopt.h' \
18867 | sed -e "$gl_make_literal_regex_sed"`
18868 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18869 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18870 s|^/[^/]|//&|
18874 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18875 sed -n "$gl_absolute_header_sed"`'"'
18876 else
18877 gl_cv_next_getopt_h='<'getopt.h'>'
18882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
18883 $as_echo "$gl_cv_next_getopt_h" >&6; }
18885 NEXT_GETOPT_H=$gl_cv_next_getopt_h
18887 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18888 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18889 gl_next_as_first_directive='<'getopt.h'>'
18890 else
18891 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18892 gl_next_as_first_directive=$gl_cv_next_getopt_h
18894 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
18899 if test $ac_cv_header_getopt_h = yes; then
18900 HAVE_GETOPT_H=1
18901 else
18902 HAVE_GETOPT_H=0
18906 gl_replace_getopt=
18908 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18909 for ac_header in getopt.h
18910 do :
18911 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
18912 if test "x$ac_cv_header_getopt_h" = x""yes; then :
18913 cat >>confdefs.h <<_ACEOF
18914 #define HAVE_GETOPT_H 1
18915 _ACEOF
18917 else
18918 gl_replace_getopt=yes
18921 done
18925 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18926 for ac_func in getopt_long_only
18927 do :
18928 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
18929 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
18930 cat >>confdefs.h <<_ACEOF
18931 #define HAVE_GETOPT_LONG_ONLY 1
18932 _ACEOF
18934 else
18935 gl_replace_getopt=yes
18937 done
18941 if test -z "$gl_replace_getopt"; then
18942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
18943 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
18944 if test "${gl_cv_func_getopt_posix+set}" = set; then :
18945 $as_echo_n "(cached) " >&6
18946 else
18948 if test $cross_compiling = no; then
18949 if test "$cross_compiling" = yes; then :
18950 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18951 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18952 as_fn_error "cannot run test program while cross compiling
18953 See \`config.log' for more details." "$LINENO" 5; }
18954 else
18955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18956 /* end confdefs.h. */
18958 #include <unistd.h>
18959 #include <stdlib.h>
18960 #include <string.h>
18963 main ()
18965 static char program[] = "program";
18966 static char a[] = "-a";
18967 static char foo[] = "foo";
18968 static char bar[] = "bar";
18969 char *argv[] = { program, a, foo, bar, NULL };
18970 int c;
18972 c = getopt (4, argv, "ab");
18973 if (!(c == 'a'))
18974 return 1;
18975 c = getopt (4, argv, "ab");
18976 if (!(c == -1))
18977 return 2;
18978 if (!(optind == 2))
18979 return 3;
18980 return 0;
18983 _ACEOF
18984 if ac_fn_c_try_run "$LINENO"; then :
18985 gl_cv_func_getopt_posix=maybe
18986 else
18987 gl_cv_func_getopt_posix=no
18989 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18990 conftest.$ac_objext conftest.beam conftest.$ac_ext
18993 if test $gl_cv_func_getopt_posix = maybe; then
18994 if test "$cross_compiling" = yes; then :
18995 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18996 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18997 as_fn_error "cannot run test program while cross compiling
18998 See \`config.log' for more details." "$LINENO" 5; }
18999 else
19000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19001 /* end confdefs.h. */
19003 #include <unistd.h>
19004 #include <stdlib.h>
19005 #include <string.h>
19008 main ()
19010 static char program[] = "program";
19011 static char donald[] = "donald";
19012 static char p[] = "-p";
19013 static char billy[] = "billy";
19014 static char duck[] = "duck";
19015 static char a[] = "-a";
19016 static char bar[] = "bar";
19017 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
19018 int c;
19020 c = getopt (7, argv, "+abp:q:");
19021 if (!(c == -1))
19022 return 4;
19023 if (!(strcmp (argv[0], "program") == 0))
19024 return 5;
19025 if (!(strcmp (argv[1], "donald") == 0))
19026 return 6;
19027 if (!(strcmp (argv[2], "-p") == 0))
19028 return 7;
19029 if (!(strcmp (argv[3], "billy") == 0))
19030 return 8;
19031 if (!(strcmp (argv[4], "duck") == 0))
19032 return 9;
19033 if (!(strcmp (argv[5], "-a") == 0))
19034 return 10;
19035 if (!(strcmp (argv[6], "bar") == 0))
19036 return 11;
19037 if (!(optind == 1))
19038 return 12;
19039 return 0;
19042 _ACEOF
19043 if ac_fn_c_try_run "$LINENO"; then :
19044 gl_cv_func_getopt_posix=maybe
19045 else
19046 gl_cv_func_getopt_posix=no
19048 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19049 conftest.$ac_objext conftest.beam conftest.$ac_ext
19053 if test $gl_cv_func_getopt_posix = maybe; then
19054 if test "$cross_compiling" = yes; then :
19055 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19056 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19057 as_fn_error "cannot run test program while cross compiling
19058 See \`config.log' for more details." "$LINENO" 5; }
19059 else
19060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19061 /* end confdefs.h. */
19063 #include <unistd.h>
19064 #include <stdlib.h>
19065 #include <string.h>
19068 main ()
19070 static char program[] = "program";
19071 static char ab[] = "-ab";
19072 char *argv[3] = { program, ab, NULL };
19073 if (getopt (2, argv, "ab:") != 'a')
19074 return 13;
19075 if (getopt (2, argv, "ab:") != '?')
19076 return 14;
19077 if (optopt != 'b')
19078 return 15;
19079 if (optind != 2)
19080 return 16;
19081 return 0;
19084 _ACEOF
19085 if ac_fn_c_try_run "$LINENO"; then :
19086 gl_cv_func_getopt_posix=yes
19087 else
19088 gl_cv_func_getopt_posix=no
19090 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19091 conftest.$ac_objext conftest.beam conftest.$ac_ext
19095 else
19096 case "$host_os" in
19097 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
19098 *) gl_cv_func_getopt_posix="guessing yes";;
19099 esac
19103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
19104 $as_echo "$gl_cv_func_getopt_posix" >&6; }
19105 case "$gl_cv_func_getopt_posix" in
19106 *no) gl_replace_getopt=yes ;;
19107 esac
19110 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
19112 $as_echo_n "checking for working GNU getopt function... " >&6; }
19113 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
19114 $as_echo_n "(cached) " >&6
19115 else
19116 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
19117 # optstring is necessary for programs like m4 that have POSIX-mandated
19118 # semantics for supporting options interspersed with files.
19119 # Also, since getopt_long is a GNU extension, we require optind=0.
19120 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
19121 # so take care to revert to the correct (non-)export state.
19122 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19123 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19124 xx) gl_had_POSIXLY_CORRECT=exported ;;
19125 x) gl_had_POSIXLY_CORRECT=yes ;;
19126 *) gl_had_POSIXLY_CORRECT= ;;
19127 esac
19128 POSIXLY_CORRECT=1
19129 export POSIXLY_CORRECT
19130 if test "$cross_compiling" = yes; then :
19131 gl_cv_func_getopt_gnu="guessing no"
19133 else
19134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19135 /* end confdefs.h. */
19136 #include <getopt.h>
19137 #include <stddef.h>
19138 #include <string.h>
19140 #include <stdlib.h>
19141 #if defined __MACH__ && defined __APPLE__
19142 /* Avoid a crash on Mac OS X. */
19143 #include <mach/mach.h>
19144 #include <mach/mach_error.h>
19145 #include <mach/thread_status.h>
19146 #include <mach/exception.h>
19147 #include <mach/task.h>
19148 #include <pthread.h>
19149 /* The exception port on which our thread listens. */
19150 static mach_port_t our_exception_port;
19151 /* The main function of the thread listening for exceptions of type
19152 EXC_BAD_ACCESS. */
19153 static void *
19154 mach_exception_thread (void *arg)
19156 /* Buffer for a message to be received. */
19157 struct {
19158 mach_msg_header_t head;
19159 mach_msg_body_t msgh_body;
19160 char data[1024];
19161 } msg;
19162 mach_msg_return_t retval;
19163 /* Wait for a message on the exception port. */
19164 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19165 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19166 if (retval != MACH_MSG_SUCCESS)
19167 abort ();
19168 exit (1);
19170 static void
19171 nocrash_init (void)
19173 mach_port_t self = mach_task_self ();
19174 /* Allocate a port on which the thread shall listen for exceptions. */
19175 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19176 == KERN_SUCCESS) {
19177 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19178 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19179 MACH_MSG_TYPE_MAKE_SEND)
19180 == KERN_SUCCESS) {
19181 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19182 for us. */
19183 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19184 /* Create the thread listening on the exception port. */
19185 pthread_attr_t attr;
19186 pthread_t thread;
19187 if (pthread_attr_init (&attr) == 0
19188 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19189 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19190 pthread_attr_destroy (&attr);
19191 /* Replace the exception port info for these exceptions with our own.
19192 Note that we replace the exception port for the entire task, not only
19193 for a particular thread. This has the effect that when our exception
19194 port gets the message, the thread specific exception port has already
19195 been asked, and we don't need to bother about it.
19196 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19197 task_set_exception_ports (self, mask, our_exception_port,
19198 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19203 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19204 /* Avoid a crash on native Windows. */
19205 #define WIN32_LEAN_AND_MEAN
19206 #include <windows.h>
19207 #include <winerror.h>
19208 static LONG WINAPI
19209 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19211 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19213 case EXCEPTION_ACCESS_VIOLATION:
19214 case EXCEPTION_IN_PAGE_ERROR:
19215 case EXCEPTION_STACK_OVERFLOW:
19216 case EXCEPTION_GUARD_PAGE:
19217 case EXCEPTION_PRIV_INSTRUCTION:
19218 case EXCEPTION_ILLEGAL_INSTRUCTION:
19219 case EXCEPTION_DATATYPE_MISALIGNMENT:
19220 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19221 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19222 exit (1);
19224 return EXCEPTION_CONTINUE_SEARCH;
19226 static void
19227 nocrash_init (void)
19229 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19231 #else
19232 /* Avoid a crash on POSIX systems. */
19233 #include <signal.h>
19234 /* A POSIX signal handler. */
19235 static void
19236 exception_handler (int sig)
19238 exit (1);
19240 static void
19241 nocrash_init (void)
19243 #ifdef SIGSEGV
19244 signal (SIGSEGV, exception_handler);
19245 #endif
19246 #ifdef SIGBUS
19247 signal (SIGBUS, exception_handler);
19248 #endif
19250 #endif
19254 main ()
19257 int result = 0;
19259 nocrash_init();
19261 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19262 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19263 OSF/1 5.1, Solaris 10. */
19265 static char conftest[] = "conftest";
19266 static char plus[] = "-+";
19267 char *argv[3] = { conftest, plus, NULL };
19268 opterr = 0;
19269 if (getopt (2, argv, "+a") != '?')
19270 result |= 1;
19272 /* This code succeeds on glibc 2.8, mingw,
19273 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19274 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19276 static char program[] = "program";
19277 static char p[] = "-p";
19278 static char foo[] = "foo";
19279 static char bar[] = "bar";
19280 char *argv[] = { program, p, foo, bar, NULL };
19282 optind = 1;
19283 if (getopt (4, argv, "p::") != 'p')
19284 result |= 2;
19285 else if (optarg != NULL)
19286 result |= 4;
19287 else if (getopt (4, argv, "p::") != -1)
19288 result |= 6;
19289 else if (optind != 2)
19290 result |= 8;
19292 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19294 static char program[] = "program";
19295 static char foo[] = "foo";
19296 static char p[] = "-p";
19297 char *argv[] = { program, foo, p, NULL };
19298 optind = 0;
19299 if (getopt (3, argv, "-p") != 1)
19300 result |= 16;
19301 else if (getopt (3, argv, "-p") != 'p')
19302 result |= 16;
19304 /* This code fails on glibc 2.11. */
19306 static char program[] = "program";
19307 static char b[] = "-b";
19308 static char a[] = "-a";
19309 char *argv[] = { program, b, a, NULL };
19310 optind = opterr = 0;
19311 if (getopt (3, argv, "+:a:b") != 'b')
19312 result |= 32;
19313 else if (getopt (3, argv, "+:a:b") != ':')
19314 result |= 32;
19316 /* This code dumps core on glibc 2.14. */
19318 static char program[] = "program";
19319 static char w[] = "-W";
19320 static char dummy[] = "dummy";
19321 char *argv[] = { program, w, dummy, NULL };
19322 optind = opterr = 1;
19323 if (getopt (3, argv, "W;") != 'W')
19324 result |= 64;
19326 return result;
19329 return 0;
19331 _ACEOF
19332 if ac_fn_c_try_run "$LINENO"; then :
19333 gl_cv_func_getopt_gnu=yes
19334 else
19335 gl_cv_func_getopt_gnu=no
19337 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19338 conftest.$ac_objext conftest.beam conftest.$ac_ext
19341 case $gl_had_POSIXLY_CORRECT in
19342 exported) ;;
19343 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19344 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19345 esac
19348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19349 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19350 if test "$gl_cv_func_getopt_gnu" != yes; then
19351 gl_replace_getopt=yes
19352 else
19353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19354 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19355 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19356 $as_echo_n "(cached) " >&6
19357 else
19358 if test "$cross_compiling" = yes; then :
19359 case "$host_os" in
19360 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19361 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19362 esac
19364 else
19365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19366 /* end confdefs.h. */
19367 #include <getopt.h>
19368 #include <stddef.h>
19369 #include <string.h>
19372 main ()
19374 static const struct option long_options[] =
19376 { "xtremely-",no_argument, NULL, 1003 },
19377 { "xtra", no_argument, NULL, 1001 },
19378 { "xtreme", no_argument, NULL, 1002 },
19379 { "xtremely", no_argument, NULL, 1003 },
19380 { NULL, 0, NULL, 0 }
19382 /* This code fails on OpenBSD 5.0. */
19384 static char program[] = "program";
19385 static char xtremel[] = "--xtremel";
19386 char *argv[] = { program, xtremel, NULL };
19387 int option_index;
19388 optind = 1; opterr = 0;
19389 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19390 return 1;
19392 return 0;
19395 return 0;
19397 _ACEOF
19398 if ac_fn_c_try_run "$LINENO"; then :
19399 gl_cv_func_getopt_long_gnu=yes
19400 else
19401 gl_cv_func_getopt_long_gnu=no
19403 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19404 conftest.$ac_objext conftest.beam conftest.$ac_ext
19409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19410 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19411 case "$gl_cv_func_getopt_long_gnu" in
19412 *yes) ;;
19413 *) gl_replace_getopt=yes ;;
19414 esac
19423 REPLACE_GETOPT=0
19424 if test -n "$gl_replace_getopt"; then
19425 REPLACE_GETOPT=1
19428 if test $REPLACE_GETOPT = 1; then
19430 GETOPT_H=getopt.h
19432 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19438 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19439 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19440 ac_have_decl=1
19441 else
19442 ac_have_decl=0
19445 cat >>confdefs.h <<_ACEOF
19446 #define HAVE_DECL_GETENV $ac_have_decl
19447 _ACEOF
19454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19455 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19456 if test "${ac_cv_c_restrict+set}" = set; then :
19457 $as_echo_n "(cached) " >&6
19458 else
19459 ac_cv_c_restrict=no
19460 # The order here caters to the fact that C++ does not require restrict.
19461 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19463 /* end confdefs.h. */
19464 typedef int * int_ptr;
19465 int foo (int_ptr $ac_kw ip) {
19466 return ip[0];
19469 main ()
19471 int s[1];
19472 int * $ac_kw t = s;
19473 t[0] = 0;
19474 return foo(t)
19476 return 0;
19478 _ACEOF
19479 if ac_fn_c_try_compile "$LINENO"; then :
19480 ac_cv_c_restrict=$ac_kw
19482 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19483 test "$ac_cv_c_restrict" != no && break
19484 done
19487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19488 $as_echo "$ac_cv_c_restrict" >&6; }
19490 case $ac_cv_c_restrict in
19491 restrict) ;;
19492 no) $as_echo "#define restrict /**/" >>confdefs.h
19494 *) cat >>confdefs.h <<_ACEOF
19495 #define restrict $ac_cv_c_restrict
19496 _ACEOF
19498 esac
19501 GNULIB_GETTIMEOFDAY=0;
19502 HAVE_GETTIMEOFDAY=1;
19503 HAVE_STRUCT_TIMEVAL=1;
19504 HAVE_SYS_TIME_H=1;
19505 REPLACE_GETTIMEOFDAY=0;
19506 REPLACE_STRUCT_TIMEVAL=0;
19523 if test $gl_cv_have_include_next = yes; then
19524 gl_cv_next_sys_time_h='<'sys/time.h'>'
19525 else
19526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19527 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19528 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19529 $as_echo_n "(cached) " >&6
19530 else
19532 if test $ac_cv_header_sys_time_h = yes; then
19535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19536 /* end confdefs.h. */
19537 #include <sys/time.h>
19539 _ACEOF
19540 case "$host_os" in
19541 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19542 *) gl_absname_cpp="$ac_cpp" ;;
19543 esac
19545 case "$host_os" in
19546 mingw*)
19547 gl_dirsep_regex='[/\\]'
19550 gl_dirsep_regex='\/'
19552 esac
19553 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19555 gl_header_literal_regex=`echo 'sys/time.h' \
19556 | sed -e "$gl_make_literal_regex_sed"`
19557 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19558 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19559 s|^/[^/]|//&|
19563 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19564 sed -n "$gl_absolute_header_sed"`'"'
19565 else
19566 gl_cv_next_sys_time_h='<'sys/time.h'>'
19571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19572 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19574 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19576 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19577 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19578 gl_next_as_first_directive='<'sys/time.h'>'
19579 else
19580 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19581 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19583 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19589 if test $ac_cv_header_sys_time_h != yes; then
19590 HAVE_SYS_TIME_H=0
19597 if test $ac_cv_header_sys_socket_h != yes; then
19598 for ac_header in winsock2.h
19599 do :
19600 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19601 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19602 cat >>confdefs.h <<_ACEOF
19603 #define HAVE_WINSOCK2_H 1
19604 _ACEOF
19608 done
19611 if test "$ac_cv_header_winsock2_h" = yes; then
19612 HAVE_WINSOCK2_H=1
19613 UNISTD_H_HAVE_WINSOCK2_H=1
19614 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19615 else
19616 HAVE_WINSOCK2_H=0
19620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
19621 $as_echo_n "checking for struct timeval... " >&6; }
19622 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
19623 $as_echo_n "(cached) " >&6
19624 else
19625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19626 /* end confdefs.h. */
19627 #if HAVE_SYS_TIME_H
19628 #include <sys/time.h>
19629 #endif
19630 #include <time.h>
19631 #if HAVE_WINSOCK2_H
19632 # include <winsock2.h>
19633 #endif
19636 main ()
19638 static struct timeval x; x.tv_sec = x.tv_usec;
19640 return 0;
19642 _ACEOF
19643 if ac_fn_c_try_compile "$LINENO"; then :
19644 gl_cv_sys_struct_timeval=yes
19645 else
19646 gl_cv_sys_struct_timeval=no
19648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
19652 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
19653 if test $gl_cv_sys_struct_timeval != yes; then
19654 HAVE_STRUCT_TIMEVAL=0
19655 else
19656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
19657 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
19658 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
19659 $as_echo_n "(cached) " >&6
19660 else
19661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19662 /* end confdefs.h. */
19663 #if HAVE_SYS_TIME_H
19664 #include <sys/time.h>
19665 #endif
19666 #include <time.h>
19667 #if HAVE_WINSOCK2_H
19668 # include <winsock2.h>
19669 #endif
19672 main ()
19674 static struct timeval x;
19675 typedef int verify_tv_sec_type[
19676 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
19680 return 0;
19682 _ACEOF
19683 if ac_fn_c_try_compile "$LINENO"; then :
19684 gl_cv_sys_struct_timeval_tv_sec=yes
19685 else
19686 gl_cv_sys_struct_timeval_tv_sec=no
19688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
19692 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
19693 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
19694 REPLACE_STRUCT_TIMEVAL=1
19704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
19705 $as_echo_n "checking for unsigned long long int... " >&6; }
19706 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
19707 $as_echo_n "(cached) " >&6
19708 else
19709 ac_cv_type_unsigned_long_long_int=yes
19710 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19712 /* end confdefs.h. */
19714 /* For now, do not test the preprocessor; as of 2007 there are too many
19715 implementations with broken preprocessors. Perhaps this can
19716 be revisited in 2012. In the meantime, code should not expect
19717 #if to work with literals wider than 32 bits. */
19718 /* Test literals. */
19719 long long int ll = 9223372036854775807ll;
19720 long long int nll = -9223372036854775807LL;
19721 unsigned long long int ull = 18446744073709551615ULL;
19722 /* Test constant expressions. */
19723 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
19724 ? 1 : -1)];
19725 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
19726 ? 1 : -1)];
19727 int i = 63;
19729 main ()
19731 /* Test availability of runtime routines for shift and division. */
19732 long long int llmax = 9223372036854775807ll;
19733 unsigned long long int ullmax = 18446744073709551615ull;
19734 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
19735 | (llmax / ll) | (llmax % ll)
19736 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
19737 | (ullmax / ull) | (ullmax % ull));
19739 return 0;
19742 _ACEOF
19743 if ac_fn_c_try_link "$LINENO"; then :
19745 else
19746 ac_cv_type_unsigned_long_long_int=no
19748 rm -f core conftest.err conftest.$ac_objext \
19749 conftest$ac_exeext conftest.$ac_ext
19752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
19753 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
19754 if test $ac_cv_type_unsigned_long_long_int = yes; then
19756 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
19762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
19763 $as_echo_n "checking for long long int... " >&6; }
19764 if test "${ac_cv_type_long_long_int+set}" = set; then :
19765 $as_echo_n "(cached) " >&6
19766 else
19767 ac_cv_type_long_long_int=yes
19768 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19769 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
19770 if test $ac_cv_type_long_long_int = yes; then
19771 if test "$cross_compiling" = yes; then :
19773 else
19774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19775 /* end confdefs.h. */
19776 #include <limits.h>
19777 #ifndef LLONG_MAX
19778 # define HALF \
19779 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
19780 # define LLONG_MAX (HALF - 1 + HALF)
19781 #endif
19783 main ()
19785 long long int n = 1;
19786 int i;
19787 for (i = 0; ; i++)
19789 long long int m = n << i;
19790 if (m >> i != n)
19791 return 1;
19792 if (LLONG_MAX / 2 < m)
19793 break;
19795 return 0;
19797 return 0;
19799 _ACEOF
19800 if ac_fn_c_try_run "$LINENO"; then :
19802 else
19803 ac_cv_type_long_long_int=no
19805 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19806 conftest.$ac_objext conftest.beam conftest.$ac_ext
19812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
19813 $as_echo "$ac_cv_type_long_long_int" >&6; }
19814 if test $ac_cv_type_long_long_int = yes; then
19816 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
19825 gl_cv_c_multiarch=no
19826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19827 /* end confdefs.h. */
19828 #ifndef __APPLE_CC__
19829 not a universal capable compiler
19830 #endif
19831 typedef int dummy;
19833 _ACEOF
19834 if ac_fn_c_try_compile "$LINENO"; then :
19836 arch=
19837 prev=
19838 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
19839 if test -n "$prev"; then
19840 case $word in
19841 i?86 | x86_64 | ppc | ppc64)
19842 if test -z "$arch" || test "$arch" = "$word"; then
19843 arch="$word"
19844 else
19845 gl_cv_c_multiarch=yes
19848 esac
19849 prev=
19850 else
19851 if test "x$word" = "x-arch"; then
19852 prev=arch
19855 done
19858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19859 if test $gl_cv_c_multiarch = yes; then
19860 APPLE_UNIVERSAL_BUILD=1
19861 else
19862 APPLE_UNIVERSAL_BUILD=0
19869 if test $ac_cv_type_long_long_int = yes; then
19870 HAVE_LONG_LONG_INT=1
19871 else
19872 HAVE_LONG_LONG_INT=0
19876 if test $ac_cv_type_unsigned_long_long_int = yes; then
19877 HAVE_UNSIGNED_LONG_LONG_INT=1
19878 else
19879 HAVE_UNSIGNED_LONG_LONG_INT=0
19884 if test $ac_cv_header_wchar_h = yes; then
19885 HAVE_WCHAR_H=1
19886 else
19887 HAVE_WCHAR_H=0
19891 if test $ac_cv_header_inttypes_h = yes; then
19892 HAVE_INTTYPES_H=1
19893 else
19894 HAVE_INTTYPES_H=0
19898 if test $ac_cv_header_sys_types_h = yes; then
19899 HAVE_SYS_TYPES_H=1
19900 else
19901 HAVE_SYS_TYPES_H=0
19914 if test $gl_cv_have_include_next = yes; then
19915 gl_cv_next_stdint_h='<'stdint.h'>'
19916 else
19917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
19918 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
19919 if test "${gl_cv_next_stdint_h+set}" = set; then :
19920 $as_echo_n "(cached) " >&6
19921 else
19923 if test $ac_cv_header_stdint_h = yes; then
19926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19927 /* end confdefs.h. */
19928 #include <stdint.h>
19930 _ACEOF
19931 case "$host_os" in
19932 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19933 *) gl_absname_cpp="$ac_cpp" ;;
19934 esac
19936 case "$host_os" in
19937 mingw*)
19938 gl_dirsep_regex='[/\\]'
19941 gl_dirsep_regex='\/'
19943 esac
19944 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19946 gl_header_literal_regex=`echo 'stdint.h' \
19947 | sed -e "$gl_make_literal_regex_sed"`
19948 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19949 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19950 s|^/[^/]|//&|
19954 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19955 sed -n "$gl_absolute_header_sed"`'"'
19956 else
19957 gl_cv_next_stdint_h='<'stdint.h'>'
19962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
19963 $as_echo "$gl_cv_next_stdint_h" >&6; }
19965 NEXT_STDINT_H=$gl_cv_next_stdint_h
19967 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19968 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19969 gl_next_as_first_directive='<'stdint.h'>'
19970 else
19971 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19972 gl_next_as_first_directive=$gl_cv_next_stdint_h
19974 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
19979 if test $ac_cv_header_stdint_h = yes; then
19980 HAVE_STDINT_H=1
19981 else
19982 HAVE_STDINT_H=0
19986 if test $ac_cv_header_stdint_h = yes; then
19987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
19988 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
19989 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
19990 $as_echo_n "(cached) " >&6
19991 else
19992 gl_cv_header_working_stdint_h=no
19993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19994 /* end confdefs.h. */
19997 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
19998 #include <stdint.h>
19999 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
20000 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
20001 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
20002 #endif
20005 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20006 included before <wchar.h>. */
20007 #include <stddef.h>
20008 #include <signal.h>
20009 #if HAVE_WCHAR_H
20010 # include <stdio.h>
20011 # include <time.h>
20012 # include <wchar.h>
20013 #endif
20016 #ifdef INT8_MAX
20017 int8_t a1 = INT8_MAX;
20018 int8_t a1min = INT8_MIN;
20019 #endif
20020 #ifdef INT16_MAX
20021 int16_t a2 = INT16_MAX;
20022 int16_t a2min = INT16_MIN;
20023 #endif
20024 #ifdef INT32_MAX
20025 int32_t a3 = INT32_MAX;
20026 int32_t a3min = INT32_MIN;
20027 #endif
20028 #ifdef INT64_MAX
20029 int64_t a4 = INT64_MAX;
20030 int64_t a4min = INT64_MIN;
20031 #endif
20032 #ifdef UINT8_MAX
20033 uint8_t b1 = UINT8_MAX;
20034 #else
20035 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
20036 #endif
20037 #ifdef UINT16_MAX
20038 uint16_t b2 = UINT16_MAX;
20039 #endif
20040 #ifdef UINT32_MAX
20041 uint32_t b3 = UINT32_MAX;
20042 #endif
20043 #ifdef UINT64_MAX
20044 uint64_t b4 = UINT64_MAX;
20045 #endif
20046 int_least8_t c1 = INT8_C (0x7f);
20047 int_least8_t c1max = INT_LEAST8_MAX;
20048 int_least8_t c1min = INT_LEAST8_MIN;
20049 int_least16_t c2 = INT16_C (0x7fff);
20050 int_least16_t c2max = INT_LEAST16_MAX;
20051 int_least16_t c2min = INT_LEAST16_MIN;
20052 int_least32_t c3 = INT32_C (0x7fffffff);
20053 int_least32_t c3max = INT_LEAST32_MAX;
20054 int_least32_t c3min = INT_LEAST32_MIN;
20055 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20056 int_least64_t c4max = INT_LEAST64_MAX;
20057 int_least64_t c4min = INT_LEAST64_MIN;
20058 uint_least8_t d1 = UINT8_C (0xff);
20059 uint_least8_t d1max = UINT_LEAST8_MAX;
20060 uint_least16_t d2 = UINT16_C (0xffff);
20061 uint_least16_t d2max = UINT_LEAST16_MAX;
20062 uint_least32_t d3 = UINT32_C (0xffffffff);
20063 uint_least32_t d3max = UINT_LEAST32_MAX;
20064 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20065 uint_least64_t d4max = UINT_LEAST64_MAX;
20066 int_fast8_t e1 = INT_FAST8_MAX;
20067 int_fast8_t e1min = INT_FAST8_MIN;
20068 int_fast16_t e2 = INT_FAST16_MAX;
20069 int_fast16_t e2min = INT_FAST16_MIN;
20070 int_fast32_t e3 = INT_FAST32_MAX;
20071 int_fast32_t e3min = INT_FAST32_MIN;
20072 int_fast64_t e4 = INT_FAST64_MAX;
20073 int_fast64_t e4min = INT_FAST64_MIN;
20074 uint_fast8_t f1 = UINT_FAST8_MAX;
20075 uint_fast16_t f2 = UINT_FAST16_MAX;
20076 uint_fast32_t f3 = UINT_FAST32_MAX;
20077 uint_fast64_t f4 = UINT_FAST64_MAX;
20078 #ifdef INTPTR_MAX
20079 intptr_t g = INTPTR_MAX;
20080 intptr_t gmin = INTPTR_MIN;
20081 #endif
20082 #ifdef UINTPTR_MAX
20083 uintptr_t h = UINTPTR_MAX;
20084 #endif
20085 intmax_t i = INTMAX_MAX;
20086 uintmax_t j = UINTMAX_MAX;
20088 #include <limits.h> /* for CHAR_BIT */
20089 #define TYPE_MINIMUM(t) \
20090 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
20091 #define TYPE_MAXIMUM(t) \
20092 ((t) ((t) 0 < (t) -1 \
20093 ? (t) -1 \
20094 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
20095 struct s {
20096 int check_PTRDIFF:
20097 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20098 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20099 ? 1 : -1;
20100 /* Detect bug in FreeBSD 6.0 / ia64. */
20101 int check_SIG_ATOMIC:
20102 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20103 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20104 ? 1 : -1;
20105 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20106 int check_WCHAR:
20107 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20108 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20109 ? 1 : -1;
20110 /* Detect bug in mingw. */
20111 int check_WINT:
20112 WINT_MIN == TYPE_MINIMUM (wint_t)
20113 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20114 ? 1 : -1;
20116 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20117 int check_UINT8_C:
20118 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20119 int check_UINT16_C:
20120 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20122 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20123 #ifdef UINT8_MAX
20124 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20125 #endif
20126 #ifdef UINT16_MAX
20127 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20128 #endif
20129 #ifdef UINT32_MAX
20130 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20131 #endif
20132 #ifdef UINT64_MAX
20133 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20134 #endif
20135 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20136 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20137 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20138 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20139 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20140 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20141 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20142 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20143 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20144 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20145 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20149 main ()
20153 return 0;
20155 _ACEOF
20156 if ac_fn_c_try_compile "$LINENO"; then :
20157 if test "$cross_compiling" = yes; then :
20158 gl_cv_header_working_stdint_h=yes
20160 else
20161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20162 /* end confdefs.h. */
20165 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20166 #include <stdint.h>
20169 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20170 included before <wchar.h>. */
20171 #include <stddef.h>
20172 #include <signal.h>
20173 #if HAVE_WCHAR_H
20174 # include <stdio.h>
20175 # include <time.h>
20176 # include <wchar.h>
20177 #endif
20180 #include <stdio.h>
20181 #include <string.h>
20182 #define MVAL(macro) MVAL1(macro)
20183 #define MVAL1(expression) #expression
20184 static const char *macro_values[] =
20186 #ifdef INT8_MAX
20187 MVAL (INT8_MAX),
20188 #endif
20189 #ifdef INT16_MAX
20190 MVAL (INT16_MAX),
20191 #endif
20192 #ifdef INT32_MAX
20193 MVAL (INT32_MAX),
20194 #endif
20195 #ifdef INT64_MAX
20196 MVAL (INT64_MAX),
20197 #endif
20198 #ifdef UINT8_MAX
20199 MVAL (UINT8_MAX),
20200 #endif
20201 #ifdef UINT16_MAX
20202 MVAL (UINT16_MAX),
20203 #endif
20204 #ifdef UINT32_MAX
20205 MVAL (UINT32_MAX),
20206 #endif
20207 #ifdef UINT64_MAX
20208 MVAL (UINT64_MAX),
20209 #endif
20210 NULL
20214 main ()
20217 const char **mv;
20218 for (mv = macro_values; *mv != NULL; mv++)
20220 const char *value = *mv;
20221 /* Test whether it looks like a cast expression. */
20222 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20223 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20224 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20225 || strncmp (value, "((int)"/*)*/, 6) == 0
20226 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20227 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20228 return mv - macro_values + 1;
20230 return 0;
20233 return 0;
20235 _ACEOF
20236 if ac_fn_c_try_run "$LINENO"; then :
20237 gl_cv_header_working_stdint_h=yes
20239 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20240 conftest.$ac_objext conftest.beam conftest.$ac_ext
20245 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20249 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20251 if test "$gl_cv_header_working_stdint_h" = yes; then
20252 STDINT_H=
20253 else
20254 for ac_header in sys/inttypes.h sys/bitypes.h
20255 do :
20256 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20257 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20258 eval as_val=\$$as_ac_Header
20259 if test "x$as_val" = x""yes; then :
20260 cat >>confdefs.h <<_ACEOF
20261 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20262 _ACEOF
20266 done
20268 if test $ac_cv_header_sys_inttypes_h = yes; then
20269 HAVE_SYS_INTTYPES_H=1
20270 else
20271 HAVE_SYS_INTTYPES_H=0
20274 if test $ac_cv_header_sys_bitypes_h = yes; then
20275 HAVE_SYS_BITYPES_H=1
20276 else
20277 HAVE_SYS_BITYPES_H=0
20283 if test $APPLE_UNIVERSAL_BUILD = 0; then
20286 for gltype in ptrdiff_t size_t ; do
20287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20288 $as_echo_n "checking for bit size of $gltype... " >&6; }
20289 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20290 $as_echo_n "(cached) " >&6
20291 else
20292 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20293 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20294 included before <wchar.h>. */
20295 #include <stddef.h>
20296 #include <signal.h>
20297 #if HAVE_WCHAR_H
20298 # include <stdio.h>
20299 # include <time.h>
20300 # include <wchar.h>
20301 #endif
20303 #include <limits.h>"; then :
20305 else
20306 result=unknown
20309 eval gl_cv_bitsizeof_${gltype}=\$result
20312 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20314 $as_echo "$ac_res" >&6; }
20315 eval result=\$gl_cv_bitsizeof_${gltype}
20316 if test $result = unknown; then
20317 result=0
20319 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20320 cat >>confdefs.h <<_ACEOF
20321 #define BITSIZEOF_${GLTYPE} $result
20322 _ACEOF
20324 eval BITSIZEOF_${GLTYPE}=\$result
20325 done
20331 for gltype in sig_atomic_t wchar_t wint_t ; do
20332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20333 $as_echo_n "checking for bit size of $gltype... " >&6; }
20334 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20335 $as_echo_n "(cached) " >&6
20336 else
20337 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20338 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20339 included before <wchar.h>. */
20340 #include <stddef.h>
20341 #include <signal.h>
20342 #if HAVE_WCHAR_H
20343 # include <stdio.h>
20344 # include <time.h>
20345 # include <wchar.h>
20346 #endif
20348 #include <limits.h>"; then :
20350 else
20351 result=unknown
20354 eval gl_cv_bitsizeof_${gltype}=\$result
20357 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20359 $as_echo "$ac_res" >&6; }
20360 eval result=\$gl_cv_bitsizeof_${gltype}
20361 if test $result = unknown; then
20362 result=0
20364 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20365 cat >>confdefs.h <<_ACEOF
20366 #define BITSIZEOF_${GLTYPE} $result
20367 _ACEOF
20369 eval BITSIZEOF_${GLTYPE}=\$result
20370 done
20375 for gltype in sig_atomic_t wchar_t wint_t ; do
20376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20377 $as_echo_n "checking whether $gltype is signed... " >&6; }
20378 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20379 $as_echo_n "(cached) " >&6
20380 else
20381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20382 /* end confdefs.h. */
20384 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20385 included before <wchar.h>. */
20386 #include <stddef.h>
20387 #include <signal.h>
20388 #if HAVE_WCHAR_H
20389 # include <stdio.h>
20390 # include <time.h>
20391 # include <wchar.h>
20392 #endif
20394 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20396 main ()
20400 return 0;
20402 _ACEOF
20403 if ac_fn_c_try_compile "$LINENO"; then :
20404 result=yes
20405 else
20406 result=no
20408 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20409 eval gl_cv_type_${gltype}_signed=\$result
20412 eval ac_res=\$gl_cv_type_${gltype}_signed
20413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20414 $as_echo "$ac_res" >&6; }
20415 eval result=\$gl_cv_type_${gltype}_signed
20416 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20417 if test "$result" = yes; then
20418 cat >>confdefs.h <<_ACEOF
20419 #define HAVE_SIGNED_${GLTYPE} 1
20420 _ACEOF
20422 eval HAVE_SIGNED_${GLTYPE}=1
20423 else
20424 eval HAVE_SIGNED_${GLTYPE}=0
20426 done
20429 gl_cv_type_ptrdiff_t_signed=yes
20430 gl_cv_type_size_t_signed=no
20431 if test $APPLE_UNIVERSAL_BUILD = 0; then
20434 for gltype in ptrdiff_t size_t ; do
20435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20436 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20437 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20438 $as_echo_n "(cached) " >&6
20439 else
20440 eval gl_cv_type_${gltype}_suffix=no
20441 eval result=\$gl_cv_type_${gltype}_signed
20442 if test "$result" = yes; then
20443 glsufu=
20444 else
20445 glsufu=u
20447 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20448 case $glsuf in
20449 '') gltype1='int';;
20450 l) gltype1='long int';;
20451 ll) gltype1='long long int';;
20452 i64) gltype1='__int64';;
20453 u) gltype1='unsigned int';;
20454 ul) gltype1='unsigned long int';;
20455 ull) gltype1='unsigned long long int';;
20456 ui64)gltype1='unsigned __int64';;
20457 esac
20458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20459 /* end confdefs.h. */
20461 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20462 included before <wchar.h>. */
20463 #include <stddef.h>
20464 #include <signal.h>
20465 #if HAVE_WCHAR_H
20466 # include <stdio.h>
20467 # include <time.h>
20468 # include <wchar.h>
20469 #endif
20471 extern $gltype foo;
20472 extern $gltype1 foo;
20474 main ()
20478 return 0;
20480 _ACEOF
20481 if ac_fn_c_try_compile "$LINENO"; then :
20482 eval gl_cv_type_${gltype}_suffix=\$glsuf
20484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20485 eval result=\$gl_cv_type_${gltype}_suffix
20486 test "$result" != no && break
20487 done
20489 eval ac_res=\$gl_cv_type_${gltype}_suffix
20490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20491 $as_echo "$ac_res" >&6; }
20492 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20493 eval result=\$gl_cv_type_${gltype}_suffix
20494 test "$result" = no && result=
20495 eval ${GLTYPE}_SUFFIX=\$result
20496 cat >>confdefs.h <<_ACEOF
20497 #define ${GLTYPE}_SUFFIX $result
20498 _ACEOF
20500 done
20506 for gltype in sig_atomic_t wchar_t wint_t ; do
20507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20508 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20509 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20510 $as_echo_n "(cached) " >&6
20511 else
20512 eval gl_cv_type_${gltype}_suffix=no
20513 eval result=\$gl_cv_type_${gltype}_signed
20514 if test "$result" = yes; then
20515 glsufu=
20516 else
20517 glsufu=u
20519 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20520 case $glsuf in
20521 '') gltype1='int';;
20522 l) gltype1='long int';;
20523 ll) gltype1='long long int';;
20524 i64) gltype1='__int64';;
20525 u) gltype1='unsigned int';;
20526 ul) gltype1='unsigned long int';;
20527 ull) gltype1='unsigned long long int';;
20528 ui64)gltype1='unsigned __int64';;
20529 esac
20530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20531 /* end confdefs.h. */
20533 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20534 included before <wchar.h>. */
20535 #include <stddef.h>
20536 #include <signal.h>
20537 #if HAVE_WCHAR_H
20538 # include <stdio.h>
20539 # include <time.h>
20540 # include <wchar.h>
20541 #endif
20543 extern $gltype foo;
20544 extern $gltype1 foo;
20546 main ()
20550 return 0;
20552 _ACEOF
20553 if ac_fn_c_try_compile "$LINENO"; then :
20554 eval gl_cv_type_${gltype}_suffix=\$glsuf
20556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20557 eval result=\$gl_cv_type_${gltype}_suffix
20558 test "$result" != no && break
20559 done
20561 eval ac_res=\$gl_cv_type_${gltype}_suffix
20562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20563 $as_echo "$ac_res" >&6; }
20564 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20565 eval result=\$gl_cv_type_${gltype}_suffix
20566 test "$result" = no && result=
20567 eval ${GLTYPE}_SUFFIX=\$result
20568 cat >>confdefs.h <<_ACEOF
20569 #define ${GLTYPE}_SUFFIX $result
20570 _ACEOF
20572 done
20576 if test $BITSIZEOF_WINT_T -lt 32; then
20577 BITSIZEOF_WINT_T=32
20580 STDINT_H=stdint.h
20583 if test -n "$STDINT_H"; then
20584 GL_GENERATE_STDINT_H_TRUE=
20585 GL_GENERATE_STDINT_H_FALSE='#'
20586 else
20587 GL_GENERATE_STDINT_H_TRUE='#'
20588 GL_GENERATE_STDINT_H_FALSE=
20595 GNULIB_IMAXABS=0;
20596 GNULIB_IMAXDIV=0;
20597 GNULIB_STRTOIMAX=0;
20598 GNULIB_STRTOUMAX=0;
20599 HAVE_DECL_IMAXABS=1;
20600 HAVE_DECL_IMAXDIV=1;
20601 HAVE_DECL_STRTOIMAX=1;
20602 HAVE_DECL_STRTOUMAX=1;
20603 REPLACE_STRTOIMAX=0;
20604 INT32_MAX_LT_INTMAX_MAX=1;
20605 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20606 PRI_MACROS_BROKEN=0;
20607 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20608 UINT32_MAX_LT_UINTMAX_MAX=1;
20609 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20625 if test $gl_cv_have_include_next = yes; then
20626 gl_cv_next_inttypes_h='<'inttypes.h'>'
20627 else
20628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20629 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20630 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20631 $as_echo_n "(cached) " >&6
20632 else
20634 if test $ac_cv_header_inttypes_h = yes; then
20637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20638 /* end confdefs.h. */
20639 #include <inttypes.h>
20641 _ACEOF
20642 case "$host_os" in
20643 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20644 *) gl_absname_cpp="$ac_cpp" ;;
20645 esac
20647 case "$host_os" in
20648 mingw*)
20649 gl_dirsep_regex='[/\\]'
20652 gl_dirsep_regex='\/'
20654 esac
20655 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20657 gl_header_literal_regex=`echo 'inttypes.h' \
20658 | sed -e "$gl_make_literal_regex_sed"`
20659 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20660 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20661 s|^/[^/]|//&|
20665 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20666 sed -n "$gl_absolute_header_sed"`'"'
20667 else
20668 gl_cv_next_inttypes_h='<'inttypes.h'>'
20673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
20674 $as_echo "$gl_cv_next_inttypes_h" >&6; }
20676 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
20678 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20679 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20680 gl_next_as_first_directive='<'inttypes.h'>'
20681 else
20682 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20683 gl_next_as_first_directive=$gl_cv_next_inttypes_h
20685 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
20697 case "$host_os" in
20698 mingw*)
20699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
20700 $as_echo_n "checking for 64-bit off_t... " >&6; }
20701 if test "${gl_cv_type_off_t_64+set}" = set; then :
20702 $as_echo_n "(cached) " >&6
20703 else
20704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20705 /* end confdefs.h. */
20706 #include <sys/types.h>
20707 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
20710 main ()
20714 return 0;
20716 _ACEOF
20717 if ac_fn_c_try_compile "$LINENO"; then :
20718 gl_cv_type_off_t_64=yes
20719 else
20720 gl_cv_type_off_t_64=no
20722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
20726 $as_echo "$gl_cv_type_off_t_64" >&6; }
20727 if test $gl_cv_type_off_t_64 = no; then
20728 WINDOWS_64_BIT_OFF_T=1
20729 else
20730 WINDOWS_64_BIT_OFF_T=0
20732 WINDOWS_64_BIT_ST_SIZE=1
20735 WINDOWS_64_BIT_OFF_T=0
20736 WINDOWS_64_BIT_ST_SIZE=0
20738 esac
20743 GNULIB_FFSL=0;
20744 GNULIB_FFSLL=0;
20745 GNULIB_MEMCHR=0;
20746 GNULIB_MEMMEM=0;
20747 GNULIB_MEMPCPY=0;
20748 GNULIB_MEMRCHR=0;
20749 GNULIB_RAWMEMCHR=0;
20750 GNULIB_STPCPY=0;
20751 GNULIB_STPNCPY=0;
20752 GNULIB_STRCHRNUL=0;
20753 GNULIB_STRDUP=0;
20754 GNULIB_STRNCAT=0;
20755 GNULIB_STRNDUP=0;
20756 GNULIB_STRNLEN=0;
20757 GNULIB_STRPBRK=0;
20758 GNULIB_STRSEP=0;
20759 GNULIB_STRSTR=0;
20760 GNULIB_STRCASESTR=0;
20761 GNULIB_STRTOK_R=0;
20762 GNULIB_MBSLEN=0;
20763 GNULIB_MBSNLEN=0;
20764 GNULIB_MBSCHR=0;
20765 GNULIB_MBSRCHR=0;
20766 GNULIB_MBSSTR=0;
20767 GNULIB_MBSCASECMP=0;
20768 GNULIB_MBSNCASECMP=0;
20769 GNULIB_MBSPCASECMP=0;
20770 GNULIB_MBSCASESTR=0;
20771 GNULIB_MBSCSPN=0;
20772 GNULIB_MBSPBRK=0;
20773 GNULIB_MBSSPN=0;
20774 GNULIB_MBSSEP=0;
20775 GNULIB_MBSTOK_R=0;
20776 GNULIB_STRERROR=0;
20777 GNULIB_STRERROR_R=0;
20778 GNULIB_STRSIGNAL=0;
20779 GNULIB_STRVERSCMP=0;
20780 HAVE_MBSLEN=0;
20781 HAVE_FFSL=1;
20782 HAVE_FFSLL=1;
20783 HAVE_MEMCHR=1;
20784 HAVE_DECL_MEMMEM=1;
20785 HAVE_MEMPCPY=1;
20786 HAVE_DECL_MEMRCHR=1;
20787 HAVE_RAWMEMCHR=1;
20788 HAVE_STPCPY=1;
20789 HAVE_STPNCPY=1;
20790 HAVE_STRCHRNUL=1;
20791 HAVE_DECL_STRDUP=1;
20792 HAVE_DECL_STRNDUP=1;
20793 HAVE_DECL_STRNLEN=1;
20794 HAVE_STRPBRK=1;
20795 HAVE_STRSEP=1;
20796 HAVE_STRCASESTR=1;
20797 HAVE_DECL_STRTOK_R=1;
20798 HAVE_DECL_STRERROR_R=1;
20799 HAVE_DECL_STRSIGNAL=1;
20800 HAVE_STRVERSCMP=1;
20801 REPLACE_MEMCHR=0;
20802 REPLACE_MEMMEM=0;
20803 REPLACE_STPNCPY=0;
20804 REPLACE_STRDUP=0;
20805 REPLACE_STRSTR=0;
20806 REPLACE_STRCASESTR=0;
20807 REPLACE_STRCHRNUL=0;
20808 REPLACE_STRERROR=0;
20809 REPLACE_STRERROR_R=0;
20810 REPLACE_STRNCAT=0;
20811 REPLACE_STRNDUP=0;
20812 REPLACE_STRNLEN=0;
20813 REPLACE_STRSIGNAL=0;
20814 REPLACE_STRTOK_R=0;
20815 UNDEFINE_STRTOK_R=0;
20817 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
20818 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
20819 ac_have_decl=1
20820 else
20821 ac_have_decl=0
20824 cat >>confdefs.h <<_ACEOF
20825 #define HAVE_DECL_MEMRCHR $ac_have_decl
20826 _ACEOF
20831 GNULIB_MKTIME=0;
20832 GNULIB_NANOSLEEP=0;
20833 GNULIB_STRPTIME=0;
20834 GNULIB_TIMEGM=0;
20835 GNULIB_TIME_R=0;
20836 HAVE_DECL_LOCALTIME_R=1;
20837 HAVE_NANOSLEEP=1;
20838 HAVE_STRPTIME=1;
20839 HAVE_TIMEGM=1;
20840 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
20841 REPLACE_MKTIME=GNULIB_PORTCHECK;
20842 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
20843 REPLACE_TIMEGM=GNULIB_PORTCHECK;
20845 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
20846 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
20847 ac_have_decl=1
20848 else
20849 ac_have_decl=0
20852 cat >>confdefs.h <<_ACEOF
20853 #define HAVE_DECL_ALARM $ac_have_decl
20854 _ACEOF
20859 GNULIB_PSELECT=0;
20860 GNULIB_SELECT=0;
20861 HAVE_PSELECT=1;
20862 REPLACE_PSELECT=0;
20863 REPLACE_SELECT=0;
20870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
20871 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
20872 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
20873 $as_echo_n "(cached) " >&6
20874 else
20876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20877 /* end confdefs.h. */
20878 #include <sys/select.h>
20880 main ()
20882 struct timeval b;
20884 return 0;
20886 _ACEOF
20887 if ac_fn_c_try_compile "$LINENO"; then :
20888 gl_cv_header_sys_select_h_selfcontained=yes
20889 else
20890 gl_cv_header_sys_select_h_selfcontained=no
20892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20893 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
20894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20895 /* end confdefs.h. */
20896 #include <sys/select.h>
20898 main ()
20900 int memset; int bzero;
20902 return 0;
20905 _ACEOF
20906 if ac_fn_c_try_compile "$LINENO"; then :
20907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20908 /* end confdefs.h. */
20909 #include <sys/select.h>
20911 main ()
20914 #undef memset
20915 #define memset nonexistent_memset
20916 extern
20917 #ifdef __cplusplus
20919 #endif
20920 void *memset (void *, int, unsigned long);
20921 #undef bzero
20922 #define bzero nonexistent_bzero
20923 extern
20924 #ifdef __cplusplus
20926 #endif
20927 void bzero (void *, unsigned long);
20928 fd_set fds;
20929 FD_ZERO (&fds);
20932 return 0;
20935 _ACEOF
20936 if ac_fn_c_try_link "$LINENO"; then :
20938 else
20939 gl_cv_header_sys_select_h_selfcontained=no
20941 rm -f core conftest.err conftest.$ac_objext \
20942 conftest$ac_exeext conftest.$ac_ext
20945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
20950 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
20960 if test $gl_cv_have_include_next = yes; then
20961 gl_cv_next_sys_select_h='<'sys/select.h'>'
20962 else
20963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
20964 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
20965 if test "${gl_cv_next_sys_select_h+set}" = set; then :
20966 $as_echo_n "(cached) " >&6
20967 else
20969 if test $ac_cv_header_sys_select_h = yes; then
20972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20973 /* end confdefs.h. */
20974 #include <sys/select.h>
20976 _ACEOF
20977 case "$host_os" in
20978 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20979 *) gl_absname_cpp="$ac_cpp" ;;
20980 esac
20982 case "$host_os" in
20983 mingw*)
20984 gl_dirsep_regex='[/\\]'
20987 gl_dirsep_regex='\/'
20989 esac
20990 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20992 gl_header_literal_regex=`echo 'sys/select.h' \
20993 | sed -e "$gl_make_literal_regex_sed"`
20994 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20995 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20996 s|^/[^/]|//&|
21000 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21001 sed -n "$gl_absolute_header_sed"`'"'
21002 else
21003 gl_cv_next_sys_select_h='<'sys/select.h'>'
21008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
21009 $as_echo "$gl_cv_next_sys_select_h" >&6; }
21011 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
21013 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21014 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21015 gl_next_as_first_directive='<'sys/select.h'>'
21016 else
21017 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21018 gl_next_as_first_directive=$gl_cv_next_sys_select_h
21020 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
21025 if test $ac_cv_header_sys_select_h = yes; then
21026 HAVE_SYS_SELECT_H=1
21027 else
21028 HAVE_SYS_SELECT_H=0
21035 if test $ac_cv_header_sys_socket_h != yes; then
21036 for ac_header in winsock2.h
21037 do :
21038 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21039 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
21040 cat >>confdefs.h <<_ACEOF
21041 #define HAVE_WINSOCK2_H 1
21042 _ACEOF
21046 done
21049 if test "$ac_cv_header_winsock2_h" = yes; then
21050 HAVE_WINSOCK2_H=1
21051 UNISTD_H_HAVE_WINSOCK2_H=1
21052 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21053 else
21054 HAVE_WINSOCK2_H=0
21064 GNULIB_PTHREAD_SIGMASK=0;
21065 GNULIB_RAISE=0;
21066 GNULIB_SIGNAL_H_SIGPIPE=0;
21067 GNULIB_SIGPROCMASK=0;
21068 GNULIB_SIGACTION=0;
21069 HAVE_POSIX_SIGNALBLOCKING=1;
21070 HAVE_PTHREAD_SIGMASK=1;
21071 HAVE_RAISE=1;
21072 HAVE_SIGSET_T=1;
21073 HAVE_SIGINFO_T=1;
21074 HAVE_SIGACTION=1;
21075 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
21077 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
21079 HAVE_SIGHANDLER_T=1;
21080 REPLACE_PTHREAD_SIGMASK=0;
21081 REPLACE_RAISE=0;
21089 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
21090 #include <signal.h>
21091 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
21092 #include <sys/types.h>
21095 if test "x$ac_cv_type_sigset_t" = x""yes; then :
21097 cat >>confdefs.h <<_ACEOF
21098 #define HAVE_SIGSET_T 1
21099 _ACEOF
21101 gl_cv_type_sigset_t=yes
21102 else
21103 gl_cv_type_sigset_t=no
21106 if test $gl_cv_type_sigset_t != yes; then
21107 HAVE_SIGSET_T=0
21112 if test $ac_cv_header_sys_socket_h = no; then
21113 for ac_header in ws2tcpip.h
21114 do :
21115 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
21116 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
21117 cat >>confdefs.h <<_ACEOF
21118 #define HAVE_WS2TCPIP_H 1
21119 _ACEOF
21123 done
21127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21128 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21129 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21130 $as_echo_n "(cached) " >&6
21131 else
21132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21133 /* end confdefs.h. */
21135 #include <stdbool.h>
21136 #ifndef bool
21137 "error: bool is not defined"
21138 #endif
21139 #ifndef false
21140 "error: false is not defined"
21141 #endif
21142 #if false
21143 "error: false is not 0"
21144 #endif
21145 #ifndef true
21146 "error: true is not defined"
21147 #endif
21148 #if true != 1
21149 "error: true is not 1"
21150 #endif
21151 #ifndef __bool_true_false_are_defined
21152 "error: __bool_true_false_are_defined is not defined"
21153 #endif
21155 struct s { _Bool s: 1; _Bool t; } s;
21157 char a[true == 1 ? 1 : -1];
21158 char b[false == 0 ? 1 : -1];
21159 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21160 char d[(bool) 0.5 == true ? 1 : -1];
21161 /* See body of main program for 'e'. */
21162 char f[(_Bool) 0.0 == false ? 1 : -1];
21163 char g[true];
21164 char h[sizeof (_Bool)];
21165 char i[sizeof s.t];
21166 enum { j = false, k = true, l = false * true, m = true * 256 };
21167 /* The following fails for
21168 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21169 _Bool n[m];
21170 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21171 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21172 /* Catch a bug in an HP-UX C compiler. See
21173 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21174 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21176 _Bool q = true;
21177 _Bool *pq = &q;
21180 main ()
21183 bool e = &s;
21184 *pq |= q;
21185 *pq |= ! q;
21186 /* Refer to every declared value, to avoid compiler optimizations. */
21187 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21188 + !m + !n + !o + !p + !q + !pq);
21191 return 0;
21193 _ACEOF
21194 if ac_fn_c_try_compile "$LINENO"; then :
21195 ac_cv_header_stdbool_h=yes
21196 else
21197 ac_cv_header_stdbool_h=no
21199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21202 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21203 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21204 if test "x$ac_cv_type__Bool" = x""yes; then :
21206 cat >>confdefs.h <<_ACEOF
21207 #define HAVE__BOOL 1
21208 _ACEOF
21215 REPLACE_NULL=0;
21216 HAVE_WCHAR_T=1;
21219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21220 $as_echo_n "checking for wchar_t... " >&6; }
21221 if test "${gt_cv_c_wchar_t+set}" = set; then :
21222 $as_echo_n "(cached) " >&6
21223 else
21224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21225 /* end confdefs.h. */
21226 #include <stddef.h>
21227 wchar_t foo = (wchar_t)'\0';
21229 main ()
21233 return 0;
21235 _ACEOF
21236 if ac_fn_c_try_compile "$LINENO"; then :
21237 gt_cv_c_wchar_t=yes
21238 else
21239 gt_cv_c_wchar_t=no
21241 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21244 $as_echo "$gt_cv_c_wchar_t" >&6; }
21245 if test $gt_cv_c_wchar_t = yes; then
21247 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21252 GNULIB_DPRINTF=0;
21253 GNULIB_FCLOSE=0;
21254 GNULIB_FDOPEN=0;
21255 GNULIB_FFLUSH=0;
21256 GNULIB_FGETC=0;
21257 GNULIB_FGETS=0;
21258 GNULIB_FOPEN=0;
21259 GNULIB_FPRINTF=0;
21260 GNULIB_FPRINTF_POSIX=0;
21261 GNULIB_FPURGE=0;
21262 GNULIB_FPUTC=0;
21263 GNULIB_FPUTS=0;
21264 GNULIB_FREAD=0;
21265 GNULIB_FREOPEN=0;
21266 GNULIB_FSCANF=0;
21267 GNULIB_FSEEK=0;
21268 GNULIB_FSEEKO=0;
21269 GNULIB_FTELL=0;
21270 GNULIB_FTELLO=0;
21271 GNULIB_FWRITE=0;
21272 GNULIB_GETC=0;
21273 GNULIB_GETCHAR=0;
21274 GNULIB_GETDELIM=0;
21275 GNULIB_GETLINE=0;
21276 GNULIB_OBSTACK_PRINTF=0;
21277 GNULIB_OBSTACK_PRINTF_POSIX=0;
21278 GNULIB_PCLOSE=0;
21279 GNULIB_PERROR=0;
21280 GNULIB_POPEN=0;
21281 GNULIB_PRINTF=0;
21282 GNULIB_PRINTF_POSIX=0;
21283 GNULIB_PUTC=0;
21284 GNULIB_PUTCHAR=0;
21285 GNULIB_PUTS=0;
21286 GNULIB_REMOVE=0;
21287 GNULIB_RENAME=0;
21288 GNULIB_RENAMEAT=0;
21289 GNULIB_SCANF=0;
21290 GNULIB_SNPRINTF=0;
21291 GNULIB_SPRINTF_POSIX=0;
21292 GNULIB_STDIO_H_NONBLOCKING=0;
21293 GNULIB_STDIO_H_SIGPIPE=0;
21294 GNULIB_TMPFILE=0;
21295 GNULIB_VASPRINTF=0;
21296 GNULIB_VFSCANF=0;
21297 GNULIB_VSCANF=0;
21298 GNULIB_VDPRINTF=0;
21299 GNULIB_VFPRINTF=0;
21300 GNULIB_VFPRINTF_POSIX=0;
21301 GNULIB_VPRINTF=0;
21302 GNULIB_VPRINTF_POSIX=0;
21303 GNULIB_VSNPRINTF=0;
21304 GNULIB_VSPRINTF_POSIX=0;
21305 HAVE_DECL_FPURGE=1;
21306 HAVE_DECL_FSEEKO=1;
21307 HAVE_DECL_FTELLO=1;
21308 HAVE_DECL_GETDELIM=1;
21309 HAVE_DECL_GETLINE=1;
21310 HAVE_DECL_OBSTACK_PRINTF=1;
21311 HAVE_DECL_SNPRINTF=1;
21312 HAVE_DECL_VSNPRINTF=1;
21313 HAVE_DPRINTF=1;
21314 HAVE_FSEEKO=1;
21315 HAVE_FTELLO=1;
21316 HAVE_PCLOSE=1;
21317 HAVE_POPEN=1;
21318 HAVE_RENAMEAT=1;
21319 HAVE_VASPRINTF=1;
21320 HAVE_VDPRINTF=1;
21321 REPLACE_DPRINTF=0;
21322 REPLACE_FCLOSE=0;
21323 REPLACE_FDOPEN=0;
21324 REPLACE_FFLUSH=0;
21325 REPLACE_FOPEN=0;
21326 REPLACE_FPRINTF=0;
21327 REPLACE_FPURGE=0;
21328 REPLACE_FREOPEN=0;
21329 REPLACE_FSEEK=0;
21330 REPLACE_FSEEKO=0;
21331 REPLACE_FTELL=0;
21332 REPLACE_FTELLO=0;
21333 REPLACE_GETDELIM=0;
21334 REPLACE_GETLINE=0;
21335 REPLACE_OBSTACK_PRINTF=0;
21336 REPLACE_PERROR=0;
21337 REPLACE_POPEN=0;
21338 REPLACE_PRINTF=0;
21339 REPLACE_REMOVE=0;
21340 REPLACE_RENAME=0;
21341 REPLACE_RENAMEAT=0;
21342 REPLACE_SNPRINTF=0;
21343 REPLACE_SPRINTF=0;
21344 REPLACE_STDIO_READ_FUNCS=0;
21345 REPLACE_STDIO_WRITE_FUNCS=0;
21346 REPLACE_TMPFILE=0;
21347 REPLACE_VASPRINTF=0;
21348 REPLACE_VDPRINTF=0;
21349 REPLACE_VFPRINTF=0;
21350 REPLACE_VPRINTF=0;
21351 REPLACE_VSNPRINTF=0;
21352 REPLACE_VSPRINTF=0;
21354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21355 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21356 if test "${ac_cv_struct_tm+set}" = set; then :
21357 $as_echo_n "(cached) " >&6
21358 else
21359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21360 /* end confdefs.h. */
21361 #include <sys/types.h>
21362 #include <time.h>
21365 main ()
21367 struct tm tm;
21368 int *p = &tm.tm_sec;
21369 return !p;
21371 return 0;
21373 _ACEOF
21374 if ac_fn_c_try_compile "$LINENO"; then :
21375 ac_cv_struct_tm=time.h
21376 else
21377 ac_cv_struct_tm=sys/time.h
21379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21382 $as_echo "$ac_cv_struct_tm" >&6; }
21383 if test $ac_cv_struct_tm = sys/time.h; then
21385 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21389 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21390 #include <$ac_cv_struct_tm>
21393 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21395 cat >>confdefs.h <<_ACEOF
21396 #define HAVE_STRUCT_TM_TM_ZONE 1
21397 _ACEOF
21402 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21404 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21406 else
21407 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21409 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21410 ac_have_decl=1
21411 else
21412 ac_have_decl=0
21415 cat >>confdefs.h <<_ACEOF
21416 #define HAVE_DECL_TZNAME $ac_have_decl
21417 _ACEOF
21419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21420 $as_echo_n "checking for tzname... " >&6; }
21421 if test "${ac_cv_var_tzname+set}" = set; then :
21422 $as_echo_n "(cached) " >&6
21423 else
21424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21425 /* end confdefs.h. */
21426 #include <time.h>
21427 #if !HAVE_DECL_TZNAME
21428 extern char *tzname[];
21429 #endif
21432 main ()
21434 return tzname[0][0];
21436 return 0;
21438 _ACEOF
21439 if ac_fn_c_try_link "$LINENO"; then :
21440 ac_cv_var_tzname=yes
21441 else
21442 ac_cv_var_tzname=no
21444 rm -f core conftest.err conftest.$ac_objext \
21445 conftest$ac_exeext conftest.$ac_ext
21447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21448 $as_echo "$ac_cv_var_tzname" >&6; }
21449 if test $ac_cv_var_tzname = yes; then
21451 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21457 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21459 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21461 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21477 if test $gl_cv_have_include_next = yes; then
21478 gl_cv_next_string_h='<'string.h'>'
21479 else
21480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21481 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21482 if test "${gl_cv_next_string_h+set}" = set; then :
21483 $as_echo_n "(cached) " >&6
21484 else
21486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21487 /* end confdefs.h. */
21488 #include <string.h>
21490 _ACEOF
21491 case "$host_os" in
21492 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21493 *) gl_absname_cpp="$ac_cpp" ;;
21494 esac
21496 case "$host_os" in
21497 mingw*)
21498 gl_dirsep_regex='[/\\]'
21501 gl_dirsep_regex='\/'
21503 esac
21504 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21506 gl_header_literal_regex=`echo 'string.h' \
21507 | sed -e "$gl_make_literal_regex_sed"`
21508 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21509 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21510 s|^/[^/]|//&|
21514 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21515 sed -n "$gl_absolute_header_sed"`'"'
21519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21520 $as_echo "$gl_cv_next_string_h" >&6; }
21522 NEXT_STRING_H=$gl_cv_next_string_h
21524 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21525 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21526 gl_next_as_first_directive='<'string.h'>'
21527 else
21528 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21529 gl_next_as_first_directive=$gl_cv_next_string_h
21531 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21541 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21542 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21543 ac_have_decl=1
21544 else
21545 ac_have_decl=0
21548 cat >>confdefs.h <<_ACEOF
21549 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21550 _ACEOF
21554 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21555 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21556 ac_have_decl=1
21557 else
21558 ac_have_decl=0
21561 cat >>confdefs.h <<_ACEOF
21562 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21563 _ACEOF
21567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21568 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21569 if test "${ac_cv_header_stat_broken+set}" = set; then :
21570 $as_echo_n "(cached) " >&6
21571 else
21572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21573 /* end confdefs.h. */
21574 #include <sys/types.h>
21575 #include <sys/stat.h>
21577 #if defined S_ISBLK && defined S_IFDIR
21578 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21579 #endif
21581 #if defined S_ISBLK && defined S_IFCHR
21582 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21583 #endif
21585 #if defined S_ISLNK && defined S_IFREG
21586 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21587 #endif
21589 #if defined S_ISSOCK && defined S_IFREG
21590 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21591 #endif
21593 _ACEOF
21594 if ac_fn_c_try_compile "$LINENO"; then :
21595 ac_cv_header_stat_broken=no
21596 else
21597 ac_cv_header_stat_broken=yes
21599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21602 $as_echo "$ac_cv_header_stat_broken" >&6; }
21603 if test $ac_cv_header_stat_broken = yes; then
21605 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21614 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21615 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21616 $as_echo_n "(cached) " >&6
21617 else
21618 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21619 /* end confdefs.h. */
21620 #include <time.h>
21623 main ()
21625 static struct timespec x; x.tv_sec = x.tv_nsec;
21627 return 0;
21629 _ACEOF
21630 if ac_fn_c_try_compile "$LINENO"; then :
21631 gl_cv_sys_struct_timespec_in_time_h=yes
21632 else
21633 gl_cv_sys_struct_timespec_in_time_h=no
21635 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21638 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21640 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21641 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21642 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21643 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21644 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21645 else
21646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21647 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21648 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21649 $as_echo_n "(cached) " >&6
21650 else
21651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21652 /* end confdefs.h. */
21653 #include <sys/time.h>
21656 main ()
21658 static struct timespec x; x.tv_sec = x.tv_nsec;
21660 return 0;
21662 _ACEOF
21663 if ac_fn_c_try_compile "$LINENO"; then :
21664 gl_cv_sys_struct_timespec_in_sys_time_h=yes
21665 else
21666 gl_cv_sys_struct_timespec_in_sys_time_h=no
21668 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
21671 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
21672 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
21673 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
21674 else
21675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
21676 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
21677 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
21678 $as_echo_n "(cached) " >&6
21679 else
21680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21681 /* end confdefs.h. */
21682 #include <pthread.h>
21685 main ()
21687 static struct timespec x; x.tv_sec = x.tv_nsec;
21689 return 0;
21691 _ACEOF
21692 if ac_fn_c_try_compile "$LINENO"; then :
21693 gl_cv_sys_struct_timespec_in_pthread_h=yes
21694 else
21695 gl_cv_sys_struct_timespec_in_pthread_h=no
21697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
21700 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
21701 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
21702 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
21721 if test $gl_cv_have_include_next = yes; then
21722 gl_cv_next_time_h='<'time.h'>'
21723 else
21724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
21725 $as_echo_n "checking absolute name of <time.h>... " >&6; }
21726 if test "${gl_cv_next_time_h+set}" = set; then :
21727 $as_echo_n "(cached) " >&6
21728 else
21730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21731 /* end confdefs.h. */
21732 #include <time.h>
21734 _ACEOF
21735 case "$host_os" in
21736 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21737 *) gl_absname_cpp="$ac_cpp" ;;
21738 esac
21740 case "$host_os" in
21741 mingw*)
21742 gl_dirsep_regex='[/\\]'
21745 gl_dirsep_regex='\/'
21747 esac
21748 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21750 gl_header_literal_regex=`echo 'time.h' \
21751 | sed -e "$gl_make_literal_regex_sed"`
21752 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21753 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21754 s|^/[^/]|//&|
21758 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21759 sed -n "$gl_absolute_header_sed"`'"'
21763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
21764 $as_echo "$gl_cv_next_time_h" >&6; }
21766 NEXT_TIME_H=$gl_cv_next_time_h
21768 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21769 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21770 gl_next_as_first_directive='<'time.h'>'
21771 else
21772 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21773 gl_next_as_first_directive=$gl_cv_next_time_h
21775 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
21790 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
21791 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
21792 ac_have_decl=1
21793 else
21794 ac_have_decl=0
21797 cat >>confdefs.h <<_ACEOF
21798 #define HAVE_DECL_UNSETENV $ac_have_decl
21799 _ACEOF
21802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
21803 $as_echo_n "checking whether the utimes function works... " >&6; }
21804 if test "${gl_cv_func_working_utimes+set}" = set; then :
21805 $as_echo_n "(cached) " >&6
21806 else
21808 if test "$cross_compiling" = yes; then :
21809 gl_cv_func_working_utimes=no
21810 else
21811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21812 /* end confdefs.h. */
21814 #include <sys/types.h>
21815 #include <sys/stat.h>
21816 #include <fcntl.h>
21817 #include <sys/time.h>
21818 #include <time.h>
21819 #include <unistd.h>
21820 #include <stdlib.h>
21821 #include <stdio.h>
21822 #include <utime.h>
21824 static int
21825 inorder (time_t a, time_t b, time_t c)
21827 return a <= b && b <= c;
21831 main ()
21833 int result = 0;
21834 char const *file = "conftest.utimes";
21835 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
21837 /* Test whether utimes() essentially works. */
21839 struct stat sbuf;
21840 FILE *f = fopen (file, "w");
21841 if (f == NULL)
21842 result |= 1;
21843 else if (fclose (f) != 0)
21844 result |= 1;
21845 else if (utimes (file, timeval) != 0)
21846 result |= 2;
21847 else if (lstat (file, &sbuf) != 0)
21848 result |= 1;
21849 else if (!(sbuf.st_atime == timeval[0].tv_sec
21850 && sbuf.st_mtime == timeval[1].tv_sec))
21851 result |= 4;
21852 if (unlink (file) != 0)
21853 result |= 1;
21856 /* Test whether utimes() with a NULL argument sets the file's timestamp
21857 to the current time. Use 'fstat' as well as 'time' to
21858 determine the "current" time, to accommodate NFS file systems
21859 if there is a time skew between the host and the NFS server. */
21861 int fd = open (file, O_WRONLY|O_CREAT, 0644);
21862 if (fd < 0)
21863 result |= 1;
21864 else
21866 time_t t0, t2;
21867 struct stat st0, st1, st2;
21868 if (time (&t0) == (time_t) -1)
21869 result |= 1;
21870 else if (fstat (fd, &st0) != 0)
21871 result |= 1;
21872 else if (utimes (file, timeval) != 0)
21873 result |= 2;
21874 else if (utimes (file, NULL) != 0)
21875 result |= 8;
21876 else if (fstat (fd, &st1) != 0)
21877 result |= 1;
21878 else if (write (fd, "\n", 1) != 1)
21879 result |= 1;
21880 else if (fstat (fd, &st2) != 0)
21881 result |= 1;
21882 else if (time (&t2) == (time_t) -1)
21883 result |= 1;
21884 else
21886 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
21887 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
21888 if (! (st1.st_atime == st1.st_mtime))
21889 result |= 16;
21890 if (! (m_ok_POSIX || m_ok_NFS))
21891 result |= 32;
21893 if (close (fd) != 0)
21894 result |= 1;
21896 if (unlink (file) != 0)
21897 result |= 1;
21900 /* Test whether utimes() with a NULL argument works on read-only files. */
21902 int fd = open (file, O_WRONLY|O_CREAT, 0444);
21903 if (fd < 0)
21904 result |= 1;
21905 else if (close (fd) != 0)
21906 result |= 1;
21907 else if (utimes (file, NULL) != 0)
21908 result |= 64;
21909 if (unlink (file) != 0)
21910 result |= 1;
21913 return result;
21916 _ACEOF
21917 if ac_fn_c_try_run "$LINENO"; then :
21918 gl_cv_func_working_utimes=yes
21919 else
21920 gl_cv_func_working_utimes=no
21922 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21923 conftest.$ac_objext conftest.beam conftest.$ac_ext
21927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
21928 $as_echo "$gl_cv_func_working_utimes" >&6; }
21930 if test $gl_cv_func_working_utimes = yes; then
21932 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
21940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
21941 $as_echo_n "checking for struct utimbuf... " >&6; }
21942 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
21943 $as_echo_n "(cached) " >&6
21944 else
21945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21946 /* end confdefs.h. */
21947 #if HAVE_SYS_TIME_H
21948 #include <sys/time.h>
21949 #endif
21950 #include <time.h>
21951 #ifdef HAVE_UTIME_H
21952 #include <utime.h>
21953 #endif
21956 main ()
21958 static struct utimbuf x; x.actime = x.modtime;
21960 return 0;
21962 _ACEOF
21963 if ac_fn_c_try_compile "$LINENO"; then :
21964 gl_cv_sys_struct_utimbuf=yes
21965 else
21966 gl_cv_sys_struct_utimbuf=no
21968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
21971 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
21973 if test $gl_cv_sys_struct_utimbuf = yes; then
21975 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
21989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
21990 $as_echo_n "checking type of array argument to getgroups... " >&6; }
21991 if test "${ac_cv_type_getgroups+set}" = set; then :
21992 $as_echo_n "(cached) " >&6
21993 else
21994 if test "$cross_compiling" = yes; then :
21995 ac_cv_type_getgroups=cross
21996 else
21997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21998 /* end confdefs.h. */
21999 /* Thanks to Mike Rendell for this test. */
22000 $ac_includes_default
22001 #define NGID 256
22002 #undef MAX
22003 #define MAX(x, y) ((x) > (y) ? (x) : (y))
22006 main ()
22008 gid_t gidset[NGID];
22009 int i, n;
22010 union { gid_t gval; long int lval; } val;
22012 val.lval = -1;
22013 for (i = 0; i < NGID; i++)
22014 gidset[i] = val.gval;
22015 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
22016 gidset);
22017 /* Exit non-zero if getgroups seems to require an array of ints. This
22018 happens when gid_t is short int but getgroups modifies an array
22019 of ints. */
22020 return n > 0 && gidset[n] != val.gval;
22022 _ACEOF
22023 if ac_fn_c_try_run "$LINENO"; then :
22024 ac_cv_type_getgroups=gid_t
22025 else
22026 ac_cv_type_getgroups=int
22028 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22029 conftest.$ac_objext conftest.beam conftest.$ac_ext
22032 if test $ac_cv_type_getgroups = cross; then
22033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22034 /* end confdefs.h. */
22035 #include <unistd.h>
22037 _ACEOF
22038 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22039 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
22040 ac_cv_type_getgroups=gid_t
22041 else
22042 ac_cv_type_getgroups=int
22044 rm -f conftest*
22048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
22049 $as_echo "$ac_cv_type_getgroups" >&6; }
22051 cat >>confdefs.h <<_ACEOF
22052 #define GETGROUPS_T $ac_cv_type_getgroups
22053 _ACEOF
22062 if false; then
22063 GL_COND_LIBTOOL_TRUE=
22064 GL_COND_LIBTOOL_FALSE='#'
22065 else
22066 GL_COND_LIBTOOL_TRUE='#'
22067 GL_COND_LIBTOOL_FALSE=
22070 gl_cond_libtool=false
22071 gl_libdeps=
22072 gl_ltlibdeps=
22073 gl_m4_base='m4'
22083 gl_source_base='lib'
22086 if test $ac_cv_func_alloca_works = no; then
22090 # Define an additional variable used in the Makefile substitution.
22091 if test $ac_cv_working_alloca_h = yes; then
22092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
22093 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
22094 if test "${gl_cv_rpl_alloca+set}" = set; then :
22095 $as_echo_n "(cached) " >&6
22096 else
22098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22099 /* end confdefs.h. */
22101 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
22102 Need own alloca
22103 #endif
22105 _ACEOF
22106 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22107 $EGREP "Need own alloca" >/dev/null 2>&1; then :
22108 gl_cv_rpl_alloca=yes
22109 else
22110 gl_cv_rpl_alloca=no
22112 rm -f conftest*
22116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
22117 $as_echo "$gl_cv_rpl_alloca" >&6; }
22118 if test $gl_cv_rpl_alloca = yes; then
22120 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
22122 ALLOCA_H=alloca.h
22123 else
22124 ALLOCA_H=
22126 else
22127 ALLOCA_H=alloca.h
22130 if test -n "$ALLOCA_H"; then
22131 GL_GENERATE_ALLOCA_H_TRUE=
22132 GL_GENERATE_ALLOCA_H_FALSE='#'
22133 else
22134 GL_GENERATE_ALLOCA_H_TRUE='#'
22135 GL_GENERATE_ALLOCA_H_FALSE=
22143 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22144 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22146 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22147 # programs in the package would end up linked with that potentially-shared
22148 # library, inducing unnecessary run-time overhead.
22149 LIB_CLOCK_GETTIME=
22151 gl_saved_libs=$LIBS
22152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22153 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22154 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22155 $as_echo_n "(cached) " >&6
22156 else
22157 ac_func_search_save_LIBS=$LIBS
22158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22159 /* end confdefs.h. */
22161 /* Override any GCC internal prototype to avoid an error.
22162 Use char because int might match the return type of a GCC
22163 builtin and then its argument prototype would still apply. */
22164 #ifdef __cplusplus
22165 extern "C"
22166 #endif
22167 char clock_gettime ();
22169 main ()
22171 return clock_gettime ();
22173 return 0;
22175 _ACEOF
22176 for ac_lib in '' rt posix4; do
22177 if test -z "$ac_lib"; then
22178 ac_res="none required"
22179 else
22180 ac_res=-l$ac_lib
22181 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22183 if ac_fn_c_try_link "$LINENO"; then :
22184 ac_cv_search_clock_gettime=$ac_res
22186 rm -f core conftest.err conftest.$ac_objext \
22187 conftest$ac_exeext
22188 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22189 break
22191 done
22192 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22194 else
22195 ac_cv_search_clock_gettime=no
22197 rm conftest.$ac_ext
22198 LIBS=$ac_func_search_save_LIBS
22200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22201 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22202 ac_res=$ac_cv_search_clock_gettime
22203 if test "$ac_res" != no; then :
22204 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22205 test "$ac_cv_search_clock_gettime" = "none required" ||
22206 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22209 for ac_func in clock_gettime clock_settime
22210 do :
22211 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22212 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22213 eval as_val=\$$as_ac_var
22214 if test "x$as_val" = x""yes; then :
22215 cat >>confdefs.h <<_ACEOF
22216 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22217 _ACEOF
22220 done
22222 LIBS=$gl_saved_libs
22229 cat >>confdefs.h <<_ACEOF
22230 #define GNULIB_CLOSE_STREAM 1
22231 _ACEOF
22260 if test $gl_cv_have_include_next = yes; then
22261 gl_cv_next_dirent_h='<'dirent.h'>'
22262 else
22263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22264 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22265 if test "${gl_cv_next_dirent_h+set}" = set; then :
22266 $as_echo_n "(cached) " >&6
22267 else
22269 if test $ac_cv_header_dirent_h = yes; then
22272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22273 /* end confdefs.h. */
22274 #include <dirent.h>
22276 _ACEOF
22277 case "$host_os" in
22278 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22279 *) gl_absname_cpp="$ac_cpp" ;;
22280 esac
22282 case "$host_os" in
22283 mingw*)
22284 gl_dirsep_regex='[/\\]'
22287 gl_dirsep_regex='\/'
22289 esac
22290 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22292 gl_header_literal_regex=`echo 'dirent.h' \
22293 | sed -e "$gl_make_literal_regex_sed"`
22294 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22295 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22296 s|^/[^/]|//&|
22300 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22301 sed -n "$gl_absolute_header_sed"`'"'
22302 else
22303 gl_cv_next_dirent_h='<'dirent.h'>'
22308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22309 $as_echo "$gl_cv_next_dirent_h" >&6; }
22311 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22313 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22314 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22315 gl_next_as_first_directive='<'dirent.h'>'
22316 else
22317 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22318 gl_next_as_first_directive=$gl_cv_next_dirent_h
22320 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22325 if test $ac_cv_header_dirent_h = yes; then
22326 HAVE_DIRENT_H=1
22327 else
22328 HAVE_DIRENT_H=0
22340 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22343 if test $HAVE_DUP2 = 1; then
22344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22345 $as_echo_n "checking whether dup2 works... " >&6; }
22346 if test "${gl_cv_func_dup2_works+set}" = set; then :
22347 $as_echo_n "(cached) " >&6
22348 else
22349 if test "$cross_compiling" = yes; then :
22350 case "$host_os" in
22351 mingw*) # on this platform, dup2 always returns 0 for success
22352 gl_cv_func_dup2_works="guessing no" ;;
22353 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22354 gl_cv_func_dup2_works="guessing no" ;;
22355 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22356 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22357 gl_cv_func_dup2_works="guessing no" ;;
22358 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22359 gl_cv_func_dup2_works="guessing no" ;;
22360 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22361 gl_cv_func_dup2_works="guessing no" ;;
22362 *) gl_cv_func_dup2_works="guessing yes" ;;
22363 esac
22364 else
22365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22366 /* end confdefs.h. */
22368 #include <unistd.h>
22369 #include <fcntl.h>
22370 #include <errno.h>
22372 main ()
22374 int result = 0;
22375 #ifdef FD_CLOEXEC
22376 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22377 result |= 1;
22378 #endif
22379 if (dup2 (1, 1) == 0)
22380 result |= 2;
22381 #ifdef FD_CLOEXEC
22382 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22383 result |= 4;
22384 #endif
22385 close (0);
22386 if (dup2 (0, 0) != -1)
22387 result |= 8;
22388 /* Many gnulib modules require POSIX conformance of EBADF. */
22389 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22390 result |= 16;
22391 /* Flush out a cygwin core dump. */
22392 if (dup2 (2, -1) != -1 || errno != EBADF)
22393 result |= 32;
22394 return result;
22397 return 0;
22400 _ACEOF
22401 if ac_fn_c_try_run "$LINENO"; then :
22402 gl_cv_func_dup2_works=yes
22403 else
22404 gl_cv_func_dup2_works=no
22406 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22407 conftest.$ac_objext conftest.beam conftest.$ac_ext
22412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22413 $as_echo "$gl_cv_func_dup2_works" >&6; }
22414 case "$gl_cv_func_dup2_works" in
22415 *yes) ;;
22417 REPLACE_DUP2=1
22419 esac
22423 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22432 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22441 GNULIB_DUP2=1
22453 GNULIB_ENVIRON=1
22463 LIB_EXECINFO=''
22464 EXECINFO_H='execinfo.h'
22466 if test $ac_cv_header_execinfo_h = yes; then
22467 gl_saved_libs=$LIBS
22468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22469 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22470 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22471 $as_echo_n "(cached) " >&6
22472 else
22473 ac_func_search_save_LIBS=$LIBS
22474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22475 /* end confdefs.h. */
22477 /* Override any GCC internal prototype to avoid an error.
22478 Use char because int might match the return type of a GCC
22479 builtin and then its argument prototype would still apply. */
22480 #ifdef __cplusplus
22481 extern "C"
22482 #endif
22483 char backtrace_symbols_fd ();
22485 main ()
22487 return backtrace_symbols_fd ();
22489 return 0;
22491 _ACEOF
22492 for ac_lib in '' execinfo; do
22493 if test -z "$ac_lib"; then
22494 ac_res="none required"
22495 else
22496 ac_res=-l$ac_lib
22497 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22499 if ac_fn_c_try_link "$LINENO"; then :
22500 ac_cv_search_backtrace_symbols_fd=$ac_res
22502 rm -f core conftest.err conftest.$ac_objext \
22503 conftest$ac_exeext
22504 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22505 break
22507 done
22508 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22510 else
22511 ac_cv_search_backtrace_symbols_fd=no
22513 rm conftest.$ac_ext
22514 LIBS=$ac_func_search_save_LIBS
22516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22517 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22518 ac_res=$ac_cv_search_backtrace_symbols_fd
22519 if test "$ac_res" != no; then :
22520 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22521 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22522 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22525 LIBS=$gl_saved_libs
22526 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22529 if test -n "$EXECINFO_H"; then
22538 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22544 if test -n "$EXECINFO_H"; then
22545 GL_GENERATE_EXECINFO_H_TRUE=
22546 GL_GENERATE_EXECINFO_H_FALSE='#'
22547 else
22548 GL_GENERATE_EXECINFO_H_TRUE='#'
22549 GL_GENERATE_EXECINFO_H_FALSE=
22560 if test $ac_cv_func_faccessat = no; then
22561 HAVE_FACCESSAT=0
22564 if test $HAVE_FACCESSAT = 0; then
22573 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22576 for ac_func in access
22577 do :
22578 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22579 if test "x$ac_cv_func_access" = x""yes; then :
22580 cat >>confdefs.h <<_ACEOF
22581 #define HAVE_ACCESS 1
22582 _ACEOF
22585 done
22591 cat >>confdefs.h <<_ACEOF
22592 #define GNULIB_FACCESSAT 1
22593 _ACEOF
22601 GNULIB_FACCESSAT=1
22612 if test $ac_cv_func_fcntl = no; then
22616 if test $ac_cv_func_fcntl = no; then
22617 HAVE_FCNTL=0
22618 else
22619 REPLACE_FCNTL=1
22622 else
22623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
22624 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
22625 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
22626 $as_echo_n "(cached) " >&6
22627 else
22628 if test "$cross_compiling" = yes; then :
22629 # Guess that it works on glibc systems
22630 case $host_os in #((
22631 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
22632 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
22633 esac
22634 else
22635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22636 /* end confdefs.h. */
22638 #include <fcntl.h>
22639 #include <errno.h>
22642 main ()
22644 int result = 0;
22645 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
22646 if (errno != EINVAL) result |= 2;
22647 return result;
22650 return 0;
22652 _ACEOF
22653 if ac_fn_c_try_run "$LINENO"; then :
22654 gl_cv_func_fcntl_f_dupfd_works=yes
22655 else
22656 gl_cv_func_fcntl_f_dupfd_works=no
22658 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22659 conftest.$ac_objext conftest.beam conftest.$ac_ext
22663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
22664 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
22665 case $gl_cv_func_fcntl_f_dupfd_works in
22666 *yes) ;;
22670 if test $ac_cv_func_fcntl = no; then
22671 HAVE_FCNTL=0
22672 else
22673 REPLACE_FCNTL=1
22677 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
22679 esac
22681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
22682 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
22683 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
22684 $as_echo_n "(cached) " >&6
22685 else
22686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22687 /* end confdefs.h. */
22689 #include <fcntl.h>
22690 #ifndef F_DUPFD_CLOEXEC
22691 choke me
22692 #endif
22695 main ()
22699 return 0;
22701 _ACEOF
22702 if ac_fn_c_try_compile "$LINENO"; then :
22703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22704 /* end confdefs.h. */
22706 #ifdef __linux__
22707 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
22708 it to support the semantics on older kernels that failed with EINVAL. */
22709 choke me
22710 #endif
22713 main ()
22717 return 0;
22719 _ACEOF
22720 if ac_fn_c_try_compile "$LINENO"; then :
22721 gl_cv_func_fcntl_f_dupfd_cloexec=yes
22722 else
22723 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
22725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22726 else
22727 gl_cv_func_fcntl_f_dupfd_cloexec=no
22729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
22732 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
22733 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
22737 if test $ac_cv_func_fcntl = no; then
22738 HAVE_FCNTL=0
22739 else
22740 REPLACE_FCNTL=1
22747 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
22756 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
22764 GNULIB_FCNTL=1
22781 if test $gl_cv_have_include_next = yes; then
22782 gl_cv_next_fcntl_h='<'fcntl.h'>'
22783 else
22784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
22785 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
22786 if test "${gl_cv_next_fcntl_h+set}" = set; then :
22787 $as_echo_n "(cached) " >&6
22788 else
22790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22791 /* end confdefs.h. */
22792 #include <fcntl.h>
22794 _ACEOF
22795 case "$host_os" in
22796 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22797 *) gl_absname_cpp="$ac_cpp" ;;
22798 esac
22800 case "$host_os" in
22801 mingw*)
22802 gl_dirsep_regex='[/\\]'
22805 gl_dirsep_regex='\/'
22807 esac
22808 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22810 gl_header_literal_regex=`echo 'fcntl.h' \
22811 | sed -e "$gl_make_literal_regex_sed"`
22812 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22813 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22814 s|^/[^/]|//&|
22818 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22819 sed -n "$gl_absolute_header_sed"`'"'
22823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
22824 $as_echo "$gl_cv_next_fcntl_h" >&6; }
22826 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
22828 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22829 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22830 gl_next_as_first_directive='<'fcntl.h'>'
22831 else
22832 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22833 gl_next_as_first_directive=$gl_cv_next_fcntl_h
22835 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
22851 LIB_FDATASYNC=
22854 if test $ac_cv_have_decl_fdatasync = no; then
22855 HAVE_DECL_FDATASYNC=0
22856 for ac_func in fdatasync
22857 do :
22858 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
22859 if test "x$ac_cv_func_fdatasync" = x""yes; then :
22860 cat >>confdefs.h <<_ACEOF
22861 #define HAVE_FDATASYNC 1
22862 _ACEOF
22865 done
22867 if test $ac_cv_func_fdatasync = no; then
22868 HAVE_FDATASYNC=0
22870 else
22871 gl_saved_libs=$LIBS
22872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
22873 $as_echo_n "checking for library containing fdatasync... " >&6; }
22874 if test "${ac_cv_search_fdatasync+set}" = set; then :
22875 $as_echo_n "(cached) " >&6
22876 else
22877 ac_func_search_save_LIBS=$LIBS
22878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22879 /* end confdefs.h. */
22881 /* Override any GCC internal prototype to avoid an error.
22882 Use char because int might match the return type of a GCC
22883 builtin and then its argument prototype would still apply. */
22884 #ifdef __cplusplus
22885 extern "C"
22886 #endif
22887 char fdatasync ();
22889 main ()
22891 return fdatasync ();
22893 return 0;
22895 _ACEOF
22896 for ac_lib in '' rt posix4; do
22897 if test -z "$ac_lib"; then
22898 ac_res="none required"
22899 else
22900 ac_res=-l$ac_lib
22901 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22903 if ac_fn_c_try_link "$LINENO"; then :
22904 ac_cv_search_fdatasync=$ac_res
22906 rm -f core conftest.err conftest.$ac_objext \
22907 conftest$ac_exeext
22908 if test "${ac_cv_search_fdatasync+set}" = set; then :
22909 break
22911 done
22912 if test "${ac_cv_search_fdatasync+set}" = set; then :
22914 else
22915 ac_cv_search_fdatasync=no
22917 rm conftest.$ac_ext
22918 LIBS=$ac_func_search_save_LIBS
22920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
22921 $as_echo "$ac_cv_search_fdatasync" >&6; }
22922 ac_res=$ac_cv_search_fdatasync
22923 if test "$ac_res" != no; then :
22924 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22925 test "$ac_cv_search_fdatasync" = "none required" ||
22926 LIB_FDATASYNC=$ac_cv_search_fdatasync
22929 LIBS=$gl_saved_libs
22932 if test $HAVE_FDATASYNC = 0; then
22941 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
22949 GNULIB_FDATASYNC=1
22960 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
22961 #include <dirent.h>
22964 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
22965 ac_have_decl=1
22966 else
22967 ac_have_decl=0
22970 cat >>confdefs.h <<_ACEOF
22971 #define HAVE_DECL_FDOPENDIR $ac_have_decl
22972 _ACEOF
22973 if test $ac_have_decl = 1; then :
22975 else
22976 HAVE_DECL_FDOPENDIR=0
22980 if test $ac_cv_func_fdopendir = no; then
22981 HAVE_FDOPENDIR=0
22982 else
22983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
22984 $as_echo_n "checking whether fdopendir works... " >&6; }
22985 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
22986 $as_echo_n "(cached) " >&6
22987 else
22988 if test "$cross_compiling" = yes; then :
22989 case "$host_os" in
22990 # Guess yes on glibc systems.
22991 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
22992 # If we don't know, assume the worst.
22993 *) gl_cv_func_fdopendir_works="guessing no" ;;
22994 esac
22996 else
22997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22998 /* end confdefs.h. */
23000 #include <dirent.h>
23001 #include <fcntl.h>
23002 #include <unistd.h>
23003 #if !HAVE_DECL_FDOPENDIR
23004 extern
23005 # ifdef __cplusplus
23007 # endif
23008 DIR *fdopendir (int);
23009 #endif
23012 main ()
23014 int result = 0;
23015 int fd = open ("conftest.c", O_RDONLY);
23016 if (fd < 0) result |= 1;
23017 if (fdopendir (fd)) result |= 2;
23018 if (close (fd)) result |= 4;
23019 return result;
23021 return 0;
23023 _ACEOF
23024 if ac_fn_c_try_run "$LINENO"; then :
23025 gl_cv_func_fdopendir_works=yes
23026 else
23027 gl_cv_func_fdopendir_works=no
23029 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23030 conftest.$ac_objext conftest.beam conftest.$ac_ext
23034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
23035 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
23036 case "$gl_cv_func_fdopendir_works" in
23037 *yes) ;;
23039 REPLACE_FDOPENDIR=1
23041 esac
23044 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
23053 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
23061 GNULIB_FDOPENDIR=1
23069 cat >>confdefs.h <<_ACEOF
23070 #define GNULIB_FDOPENDIR 1
23071 _ACEOF
23080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpending" >&5
23081 $as_echo_n "checking for __fpending... " >&6; }
23082 if test "${gl_cv_func___fpending+set}" = set; then :
23083 $as_echo_n "(cached) " >&6
23084 else
23086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23087 /* end confdefs.h. */
23088 #include <stdio.h>
23089 #if HAVE_STDIO_EXT_H
23090 # include <stdio_ext.h>
23091 #endif
23094 main ()
23096 return ! __fpending (stdin);
23098 return 0;
23100 _ACEOF
23101 if ac_fn_c_try_link "$LINENO"; then :
23102 gl_cv_func___fpending=yes
23103 else
23104 gl_cv_func___fpending=no
23106 rm -f core conftest.err conftest.$ac_objext \
23107 conftest$ac_exeext conftest.$ac_ext
23110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func___fpending" >&5
23111 $as_echo "$gl_cv_func___fpending" >&6; }
23113 if test $gl_cv_func___fpending = no; then
23122 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
23125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
23126 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
23127 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
23128 $as_echo_n "(cached) " >&6
23129 else
23131 for ac_expr in \
23133 '# glibc2' \
23134 'fp->_IO_write_ptr - fp->_IO_write_base' \
23136 '# traditional Unix' \
23137 'fp->_ptr - fp->_base' \
23139 '# BSD' \
23140 'fp->_p - fp->_bf._base' \
23142 '# SCO, Unixware' \
23143 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
23145 '# QNX' \
23146 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
23148 '# old glibc?' \
23149 'fp->__bufp - fp->__buffer' \
23151 '# old glibc iostream?' \
23152 'fp->_pptr - fp->_pbase' \
23154 '# emx+gcc' \
23155 'fp->_ptr - fp->_buffer' \
23157 '# Minix' \
23158 'fp->_ptr - fp->_buf' \
23160 '# Plan9' \
23161 'fp->wp - fp->buf' \
23163 '# VMS' \
23164 '(*fp)->_ptr - (*fp)->_base' \
23166 '# e.g., DGUX R4.11; the info is not available' \
23168 ; do
23170 # Skip each embedded comment.
23171 case "$ac_expr" in '#'*) continue;; esac
23173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23174 /* end confdefs.h. */
23175 #include <stdio.h>
23177 main ()
23179 FILE *fp = stdin; (void) ($ac_expr);
23181 return 0;
23183 _ACEOF
23184 if ac_fn_c_try_compile "$LINENO"; then :
23185 fp_done=yes
23188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23189 test "$fp_done" = yes && break
23190 done
23192 ac_cv_sys_pending_output_n_bytes=$ac_expr
23196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
23197 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
23199 cat >>confdefs.h <<_ACEOF
23200 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
23201 _ACEOF
23211 if test $ac_cv_func_fstatat = no; then
23212 HAVE_FSTATAT=0
23213 else
23214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
23215 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
23216 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
23217 $as_echo_n "(cached) " >&6
23218 else
23219 if test "$cross_compiling" = yes; then :
23220 case "$host_os" in
23221 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
23222 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
23223 esac
23225 else
23226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23227 /* end confdefs.h. */
23229 #include <fcntl.h>
23230 #include <sys/stat.h>
23232 main (void)
23234 struct stat a;
23235 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23238 _ACEOF
23239 if ac_fn_c_try_run "$LINENO"; then :
23240 gl_cv_func_fstatat_zero_flag=yes
23241 else
23242 gl_cv_func_fstatat_zero_flag=no
23244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23245 conftest.$ac_objext conftest.beam conftest.$ac_ext
23250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23251 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23253 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23254 *yes+*yes) ;;
23255 *) REPLACE_FSTATAT=1
23256 case $gl_cv_func_fstatat_zero_flag in
23257 *yes)
23259 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23262 esac
23264 esac
23267 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23276 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23284 GNULIB_FSTATAT=1
23293 if test $ac_cv_func_fsync = no; then
23294 HAVE_FSYNC=0
23297 if test $HAVE_FSYNC = 0; then
23306 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23315 GNULIB_FSYNC=1
23323 # Persuade glibc <stdlib.h> to declare getloadavg().
23326 gl_save_LIBS=$LIBS
23328 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23329 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23330 HAVE_GETLOADAVG=1
23331 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23332 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23334 else
23335 gl_func_getloadavg_done=no
23337 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23338 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23339 # to get the right answer into the cache.
23340 # For kstat on solaris, we need to test for libelf and libkvm to force the
23341 # definition of SVR4 below.
23342 if test $gl_func_getloadavg_done = no; then
23343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23344 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23345 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23346 $as_echo_n "(cached) " >&6
23347 else
23348 ac_check_lib_save_LIBS=$LIBS
23349 LIBS="-lelf $LIBS"
23350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23351 /* end confdefs.h. */
23353 /* Override any GCC internal prototype to avoid an error.
23354 Use char because int might match the return type of a GCC
23355 builtin and then its argument prototype would still apply. */
23356 #ifdef __cplusplus
23357 extern "C"
23358 #endif
23359 char elf_begin ();
23361 main ()
23363 return elf_begin ();
23365 return 0;
23367 _ACEOF
23368 if ac_fn_c_try_link "$LINENO"; then :
23369 ac_cv_lib_elf_elf_begin=yes
23370 else
23371 ac_cv_lib_elf_elf_begin=no
23373 rm -f core conftest.err conftest.$ac_objext \
23374 conftest$ac_exeext conftest.$ac_ext
23375 LIBS=$ac_check_lib_save_LIBS
23377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23378 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23379 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23380 LIBS="-lelf $LIBS"
23383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23384 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23385 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23386 $as_echo_n "(cached) " >&6
23387 else
23388 ac_check_lib_save_LIBS=$LIBS
23389 LIBS="-lkvm $LIBS"
23390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23391 /* end confdefs.h. */
23393 /* Override any GCC internal prototype to avoid an error.
23394 Use char because int might match the return type of a GCC
23395 builtin and then its argument prototype would still apply. */
23396 #ifdef __cplusplus
23397 extern "C"
23398 #endif
23399 char kvm_open ();
23401 main ()
23403 return kvm_open ();
23405 return 0;
23407 _ACEOF
23408 if ac_fn_c_try_link "$LINENO"; then :
23409 ac_cv_lib_kvm_kvm_open=yes
23410 else
23411 ac_cv_lib_kvm_kvm_open=no
23413 rm -f core conftest.err conftest.$ac_objext \
23414 conftest$ac_exeext conftest.$ac_ext
23415 LIBS=$ac_check_lib_save_LIBS
23417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23418 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23419 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23420 LIBS="-lkvm $LIBS"
23423 # Check for the 4.4BSD definition of getloadavg.
23424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23425 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23426 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23427 $as_echo_n "(cached) " >&6
23428 else
23429 ac_check_lib_save_LIBS=$LIBS
23430 LIBS="-lutil $LIBS"
23431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23432 /* end confdefs.h. */
23434 /* Override any GCC internal prototype to avoid an error.
23435 Use char because int might match the return type of a GCC
23436 builtin and then its argument prototype would still apply. */
23437 #ifdef __cplusplus
23438 extern "C"
23439 #endif
23440 char getloadavg ();
23442 main ()
23444 return getloadavg ();
23446 return 0;
23448 _ACEOF
23449 if ac_fn_c_try_link "$LINENO"; then :
23450 ac_cv_lib_util_getloadavg=yes
23451 else
23452 ac_cv_lib_util_getloadavg=no
23454 rm -f core conftest.err conftest.$ac_objext \
23455 conftest$ac_exeext conftest.$ac_ext
23456 LIBS=$ac_check_lib_save_LIBS
23458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23459 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23460 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23461 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23466 if test $gl_func_getloadavg_done = no; then
23467 # There is a commonly available library for RS/6000 AIX.
23468 # Since it is not a standard part of AIX, it might be installed locally.
23469 gl_getloadavg_LIBS=$LIBS
23470 LIBS="-L/usr/local/lib $LIBS"
23471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23472 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23473 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23474 $as_echo_n "(cached) " >&6
23475 else
23476 ac_check_lib_save_LIBS=$LIBS
23477 LIBS="-lgetloadavg $LIBS"
23478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23479 /* end confdefs.h. */
23481 /* Override any GCC internal prototype to avoid an error.
23482 Use char because int might match the return type of a GCC
23483 builtin and then its argument prototype would still apply. */
23484 #ifdef __cplusplus
23485 extern "C"
23486 #endif
23487 char getloadavg ();
23489 main ()
23491 return getloadavg ();
23493 return 0;
23495 _ACEOF
23496 if ac_fn_c_try_link "$LINENO"; then :
23497 ac_cv_lib_getloadavg_getloadavg=yes
23498 else
23499 ac_cv_lib_getloadavg_getloadavg=no
23501 rm -f core conftest.err conftest.$ac_objext \
23502 conftest$ac_exeext conftest.$ac_ext
23503 LIBS=$ac_check_lib_save_LIBS
23505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23506 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23507 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23508 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23509 else
23510 LIBS=$gl_getloadavg_LIBS
23515 # Set up the replacement function if necessary.
23516 if test $gl_func_getloadavg_done = no; then
23517 HAVE_GETLOADAVG=0
23519 # Solaris has libkstat which does not require root.
23520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23521 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23522 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23523 $as_echo_n "(cached) " >&6
23524 else
23525 ac_check_lib_save_LIBS=$LIBS
23526 LIBS="-lkstat $LIBS"
23527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23528 /* end confdefs.h. */
23530 /* Override any GCC internal prototype to avoid an error.
23531 Use char because int might match the return type of a GCC
23532 builtin and then its argument prototype would still apply. */
23533 #ifdef __cplusplus
23534 extern "C"
23535 #endif
23536 char kstat_open ();
23538 main ()
23540 return kstat_open ();
23542 return 0;
23544 _ACEOF
23545 if ac_fn_c_try_link "$LINENO"; then :
23546 ac_cv_lib_kstat_kstat_open=yes
23547 else
23548 ac_cv_lib_kstat_kstat_open=no
23550 rm -f core conftest.err conftest.$ac_objext \
23551 conftest$ac_exeext conftest.$ac_ext
23552 LIBS=$ac_check_lib_save_LIBS
23554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23555 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23556 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23557 cat >>confdefs.h <<_ACEOF
23558 #define HAVE_LIBKSTAT 1
23559 _ACEOF
23561 LIBS="-lkstat $LIBS"
23565 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23567 # AIX has libperfstat which does not require root
23568 if test $gl_func_getloadavg_done = no; then
23569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23570 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23571 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23572 $as_echo_n "(cached) " >&6
23573 else
23574 ac_check_lib_save_LIBS=$LIBS
23575 LIBS="-lperfstat $LIBS"
23576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23577 /* end confdefs.h. */
23579 /* Override any GCC internal prototype to avoid an error.
23580 Use char because int might match the return type of a GCC
23581 builtin and then its argument prototype would still apply. */
23582 #ifdef __cplusplus
23583 extern "C"
23584 #endif
23585 char perfstat_cpu_total ();
23587 main ()
23589 return perfstat_cpu_total ();
23591 return 0;
23593 _ACEOF
23594 if ac_fn_c_try_link "$LINENO"; then :
23595 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23596 else
23597 ac_cv_lib_perfstat_perfstat_cpu_total=no
23599 rm -f core conftest.err conftest.$ac_objext \
23600 conftest$ac_exeext conftest.$ac_ext
23601 LIBS=$ac_check_lib_save_LIBS
23603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
23604 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
23605 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
23606 cat >>confdefs.h <<_ACEOF
23607 #define HAVE_LIBPERFSTAT 1
23608 _ACEOF
23610 LIBS="-lperfstat $LIBS"
23614 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
23617 if test $gl_func_getloadavg_done = no; then
23618 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
23619 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
23620 gl_func_getloadavg_done=yes
23622 $as_echo "#define DGUX 1" >>confdefs.h
23624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
23625 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
23626 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
23627 $as_echo_n "(cached) " >&6
23628 else
23629 ac_check_lib_save_LIBS=$LIBS
23630 LIBS="-ldgc $LIBS"
23631 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23632 /* end confdefs.h. */
23634 /* Override any GCC internal prototype to avoid an error.
23635 Use char because int might match the return type of a GCC
23636 builtin and then its argument prototype would still apply. */
23637 #ifdef __cplusplus
23638 extern "C"
23639 #endif
23640 char dg_sys_info ();
23642 main ()
23644 return dg_sys_info ();
23646 return 0;
23648 _ACEOF
23649 if ac_fn_c_try_link "$LINENO"; then :
23650 ac_cv_lib_dgc_dg_sys_info=yes
23651 else
23652 ac_cv_lib_dgc_dg_sys_info=no
23654 rm -f core conftest.err conftest.$ac_objext \
23655 conftest$ac_exeext conftest.$ac_ext
23656 LIBS=$ac_check_lib_save_LIBS
23658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
23659 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
23660 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
23661 cat >>confdefs.h <<_ACEOF
23662 #define HAVE_LIBDGC 1
23663 _ACEOF
23665 LIBS="-ldgc $LIBS"
23677 if test "x$gl_save_LIBS" = x; then
23678 GETLOADAVG_LIBS=$LIBS
23679 else
23680 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
23682 LIBS=$gl_save_LIBS
23685 # Test whether the system declares getloadavg. Solaris has the function
23686 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
23687 for ac_header in sys/loadavg.h
23688 do :
23689 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
23690 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
23691 cat >>confdefs.h <<_ACEOF
23692 #define HAVE_SYS_LOADAVG_H 1
23693 _ACEOF
23697 done
23699 if test $ac_cv_header_sys_loadavg_h = yes; then
23700 HAVE_SYS_LOADAVG_H=1
23701 else
23702 HAVE_SYS_LOADAVG_H=0
23704 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
23705 # include <sys/loadavg.h>
23706 #endif
23707 #include <stdlib.h>
23709 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
23711 else
23712 HAVE_DECL_GETLOADAVG=0
23716 if test $HAVE_GETLOADAVG = 0; then
23725 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
23728 # Figure out what our getloadavg.c needs.
23732 # On HPUX9, an unprivileged user can get load averages this way.
23733 if test $gl_func_getloadavg_done = no; then
23734 for ac_func in pstat_getdynamic
23735 do :
23736 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
23737 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
23738 cat >>confdefs.h <<_ACEOF
23739 #define HAVE_PSTAT_GETDYNAMIC 1
23740 _ACEOF
23741 gl_func_getloadavg_done=yes
23743 done
23747 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
23748 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
23749 # Irix 4.0.5F has the header but not the library.
23750 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
23751 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
23752 gl_func_getloadavg_done=yes
23754 $as_echo "#define SVR4 1" >>confdefs.h
23758 if test $gl_func_getloadavg_done = no; then
23759 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
23760 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
23761 gl_func_getloadavg_done=yes
23763 $as_echo "#define UMAX 1" >>confdefs.h
23766 $as_echo "#define UMAX4_3 1" >>confdefs.h
23773 if test $gl_func_getloadavg_done = no; then
23774 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
23775 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
23776 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
23783 if test $gl_func_getloadavg_done = no; then
23784 for ac_header in mach/mach.h
23785 do :
23786 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
23787 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
23788 cat >>confdefs.h <<_ACEOF
23789 #define HAVE_MACH_MACH_H 1
23790 _ACEOF
23794 done
23798 for ac_header in nlist.h
23799 do :
23800 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
23801 if test "x$ac_cv_header_nlist_h" = x""yes; then :
23802 cat >>confdefs.h <<_ACEOF
23803 #define HAVE_NLIST_H 1
23804 _ACEOF
23805 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
23807 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
23809 cat >>confdefs.h <<_ACEOF
23810 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
23811 _ACEOF
23816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23817 /* end confdefs.h. */
23818 #include <nlist.h>
23820 main ()
23822 struct nlist x;
23823 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
23824 x.n_un.n_name = "";
23825 #else
23826 x.n_name = "";
23827 #endif
23829 return 0;
23831 _ACEOF
23832 if ac_fn_c_try_link "$LINENO"; then :
23834 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
23837 rm -f core conftest.err conftest.$ac_objext \
23838 conftest$ac_exeext conftest.$ac_ext
23842 done
23850 GNULIB_GETLOADAVG=1
23861 if test $REPLACE_GETOPT = 1; then
23870 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23880 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23885 GNULIB_GL_UNISTD_H_GETOPT=1
23894 REPLACE_GETOPT=0
23895 if test -n "$gl_replace_getopt"; then
23896 REPLACE_GETOPT=1
23899 if test $REPLACE_GETOPT = 1; then
23901 GETOPT_H=getopt.h
23903 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
23909 if test $REPLACE_GETOPT = 1; then
23918 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23928 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23933 GNULIB_GL_UNISTD_H_GETOPT=1
23947 gl_gettimeofday_timezone=void
23948 if test $ac_cv_func_gettimeofday != yes; then
23949 HAVE_GETTIMEOFDAY=0
23950 else
23954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
23955 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
23956 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
23957 $as_echo_n "(cached) " >&6
23958 else
23959 if test "$cross_compiling" = yes; then :
23960 # When cross-compiling:
23961 case "$host_os" in
23962 # Guess all is fine on glibc systems.
23963 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
23964 # If we don't know, assume the worst.
23965 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
23966 esac
23968 else
23969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23970 /* end confdefs.h. */
23971 #include <string.h>
23972 #include <sys/time.h>
23973 #include <time.h>
23974 #include <stdlib.h>
23977 main ()
23980 time_t t = 0;
23981 struct tm *lt;
23982 struct tm saved_lt;
23983 struct timeval tv;
23984 lt = localtime (&t);
23985 saved_lt = *lt;
23986 gettimeofday (&tv, NULL);
23987 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
23990 return 0;
23992 _ACEOF
23993 if ac_fn_c_try_run "$LINENO"; then :
23994 gl_cv_func_gettimeofday_clobber=no
23995 else
23996 gl_cv_func_gettimeofday_clobber=yes
23998 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23999 conftest.$ac_objext conftest.beam conftest.$ac_ext
24003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
24004 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
24006 case "$gl_cv_func_gettimeofday_clobber" in
24007 *yes)
24008 REPLACE_GETTIMEOFDAY=1
24011 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
24014 $as_echo "#define localtime rpl_localtime" >>confdefs.h
24018 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
24021 esac
24023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
24024 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
24025 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
24026 $as_echo_n "(cached) " >&6
24027 else
24028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24029 /* end confdefs.h. */
24030 #include <sys/time.h>
24031 struct timeval c;
24032 int gettimeofday (struct timeval *restrict, void *restrict);
24035 main ()
24037 /* glibc uses struct timezone * rather than the POSIX void *
24038 if _GNU_SOURCE is defined. However, since the only portable
24039 use of gettimeofday uses NULL as the second parameter, and
24040 since the glibc definition is actually more typesafe, it is
24041 not worth wrapping this to get a compliant signature. */
24042 int (*f) (struct timeval *restrict, void *restrict)
24043 = gettimeofday;
24044 int x = f (&c, 0);
24045 return !(x | c.tv_sec | c.tv_usec);
24048 return 0;
24050 _ACEOF
24051 if ac_fn_c_try_compile "$LINENO"; then :
24052 gl_cv_func_gettimeofday_posix_signature=yes
24053 else
24054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24055 /* end confdefs.h. */
24056 #include <sys/time.h>
24057 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
24060 main ()
24064 return 0;
24066 _ACEOF
24067 if ac_fn_c_try_compile "$LINENO"; then :
24068 gl_cv_func_gettimeofday_posix_signature=almost
24069 else
24070 gl_cv_func_gettimeofday_posix_signature=no
24072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24074 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
24077 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
24078 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
24079 gl_gettimeofday_timezone='struct timezone'
24080 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
24081 REPLACE_GETTIMEOFDAY=1
24083 if test $REPLACE_STRUCT_TIMEVAL = 1; then
24084 REPLACE_GETTIMEOFDAY=1
24089 cat >>confdefs.h <<_ACEOF
24090 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
24091 _ACEOF
24094 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
24103 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
24106 for ac_header in sys/timeb.h
24107 do :
24108 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
24109 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
24110 cat >>confdefs.h <<_ACEOF
24111 #define HAVE_SYS_TIMEB_H 1
24112 _ACEOF
24116 done
24118 for ac_func in _ftime
24119 do :
24120 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
24121 if test "x$ac_cv_func__ftime" = x""yes; then :
24122 cat >>confdefs.h <<_ACEOF
24123 #define HAVE__FTIME 1
24124 _ACEOF
24127 done
24136 GNULIB_GETTIMEOFDAY=1
24147 if test $ac_cv_func_lstat = yes; then
24149 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
24150 *no)
24151 REPLACE_LSTAT=1
24153 esac
24154 else
24155 HAVE_LSTAT=0
24158 if test $REPLACE_LSTAT = 1; then
24167 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
24176 GNULIB_LSTAT=1
24187 if test $ac_cv_have_decl_memrchr = no; then
24188 HAVE_DECL_MEMRCHR=0
24191 for ac_func in memrchr
24192 do :
24193 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
24194 if test "x$ac_cv_func_memrchr" = x""yes; then :
24195 cat >>confdefs.h <<_ACEOF
24196 #define HAVE_MEMRCHR 1
24197 _ACEOF
24200 done
24203 if test $ac_cv_func_memrchr = no; then
24212 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24221 GNULIB_MEMRCHR=1
24233 if test $ac_cv_func_mkostemp != yes; then
24234 HAVE_MKOSTEMP=0
24237 if test $HAVE_MKOSTEMP = 0; then
24246 gl_LIBOBJS="$gl_LIBOBJS mkostemp.$ac_objext"
24253 cat >>confdefs.h <<_ACEOF
24254 #define GNULIB_MKOSTEMP 1
24255 _ACEOF
24263 GNULIB_MKOSTEMP=1
24275 if test $APPLE_UNIVERSAL_BUILD = 1; then
24276 # A universal build on Apple Mac OS X platforms.
24277 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24278 # But we need a configuration result that is valid in both modes.
24279 gl_cv_func_working_mktime=no
24281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24282 $as_echo_n "checking for working mktime... " >&6; }
24283 if test "${gl_cv_func_working_mktime+set}" = set; then :
24284 $as_echo_n "(cached) " >&6
24285 else
24286 if test "$cross_compiling" = yes; then :
24287 gl_cv_func_working_mktime=no
24288 else
24289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24290 /* end confdefs.h. */
24291 /* Test program from Paul Eggert and Tony Leneis. */
24292 #include <limits.h>
24293 #include <stdlib.h>
24294 #include <time.h>
24296 #ifdef HAVE_UNISTD_H
24297 # include <unistd.h>
24298 #endif
24300 #if HAVE_DECL_ALARM
24301 # include <signal.h>
24302 #endif
24304 /* Work around redefinition to rpl_putenv by other config tests. */
24305 #undef putenv
24307 static time_t time_t_max;
24308 static time_t time_t_min;
24310 /* Values we'll use to set the TZ environment variable. */
24311 static char *tz_strings[] = {
24312 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24313 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24315 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24317 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24318 Based on a problem report from Andreas Jaeger. */
24319 static int
24320 spring_forward_gap ()
24322 /* glibc (up to about 1998-10-07) failed this test. */
24323 struct tm tm;
24325 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24326 instead of "TZ=America/Vancouver" in order to detect the bug even
24327 on systems that don't support the Olson extension, or don't have the
24328 full zoneinfo tables installed. */
24329 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24331 tm.tm_year = 98;
24332 tm.tm_mon = 3;
24333 tm.tm_mday = 5;
24334 tm.tm_hour = 2;
24335 tm.tm_min = 0;
24336 tm.tm_sec = 0;
24337 tm.tm_isdst = -1;
24338 return mktime (&tm) != (time_t) -1;
24341 static int
24342 mktime_test1 (time_t now)
24344 struct tm *lt;
24345 return ! (lt = localtime (&now)) || mktime (lt) == now;
24348 static int
24349 mktime_test (time_t now)
24351 return (mktime_test1 (now)
24352 && mktime_test1 ((time_t) (time_t_max - now))
24353 && mktime_test1 ((time_t) (time_t_min + now)));
24356 static int
24357 irix_6_4_bug ()
24359 /* Based on code from Ariel Faigon. */
24360 struct tm tm;
24361 tm.tm_year = 96;
24362 tm.tm_mon = 3;
24363 tm.tm_mday = 0;
24364 tm.tm_hour = 0;
24365 tm.tm_min = 0;
24366 tm.tm_sec = 0;
24367 tm.tm_isdst = -1;
24368 mktime (&tm);
24369 return tm.tm_mon == 2 && tm.tm_mday == 31;
24372 static int
24373 bigtime_test (int j)
24375 struct tm tm;
24376 time_t now;
24377 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24378 now = mktime (&tm);
24379 if (now != (time_t) -1)
24381 struct tm *lt = localtime (&now);
24382 if (! (lt
24383 && lt->tm_year == tm.tm_year
24384 && lt->tm_mon == tm.tm_mon
24385 && lt->tm_mday == tm.tm_mday
24386 && lt->tm_hour == tm.tm_hour
24387 && lt->tm_min == tm.tm_min
24388 && lt->tm_sec == tm.tm_sec
24389 && lt->tm_yday == tm.tm_yday
24390 && lt->tm_wday == tm.tm_wday
24391 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24392 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24393 return 0;
24395 return 1;
24398 static int
24399 year_2050_test ()
24401 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24402 ignoring leap seconds. */
24403 unsigned long int answer = 2527315200UL;
24405 struct tm tm;
24406 time_t t;
24407 tm.tm_year = 2050 - 1900;
24408 tm.tm_mon = 2 - 1;
24409 tm.tm_mday = 1;
24410 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24411 tm.tm_isdst = -1;
24413 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24414 instead of "TZ=America/Vancouver" in order to detect the bug even
24415 on systems that don't support the Olson extension, or don't have the
24416 full zoneinfo tables installed. */
24417 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24419 t = mktime (&tm);
24421 /* Check that the result is either a failure, or close enough
24422 to the correct answer that we can assume the discrepancy is
24423 due to leap seconds. */
24424 return (t == (time_t) -1
24425 || (0 < t && answer - 120 <= t && t <= answer + 120));
24429 main ()
24431 int result = 0;
24432 time_t t, delta;
24433 int i, j;
24434 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24435 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24437 #if HAVE_DECL_ALARM
24438 /* This test makes some buggy mktime implementations loop.
24439 Give up after 60 seconds; a mktime slower than that
24440 isn't worth using anyway. */
24441 signal (SIGALRM, SIG_DFL);
24442 alarm (60);
24443 #endif
24445 time_t_max = (! time_t_signed
24446 ? (time_t) -1
24447 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24448 * 2 + 1));
24449 time_t_min = (! time_t_signed
24450 ? (time_t) 0
24451 : time_t_signed_magnitude
24452 ? ~ (time_t) 0
24453 : ~ time_t_max);
24455 delta = time_t_max / 997; /* a suitable prime number */
24456 for (i = 0; i < N_STRINGS; i++)
24458 if (tz_strings[i])
24459 putenv (tz_strings[i]);
24461 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24462 if (! mktime_test (t))
24463 result |= 1;
24464 if ((result & 2) == 0
24465 && ! (mktime_test ((time_t) 1)
24466 && mktime_test ((time_t) (60 * 60))
24467 && mktime_test ((time_t) (60 * 60 * 24))))
24468 result |= 2;
24470 for (j = 1; (result & 4) == 0; j <<= 1)
24472 if (! bigtime_test (j))
24473 result |= 4;
24474 if (INT_MAX / 2 < j)
24475 break;
24477 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24478 result |= 8;
24480 if (! irix_6_4_bug ())
24481 result |= 16;
24482 if (! spring_forward_gap ())
24483 result |= 32;
24484 if (! year_2050_test ())
24485 result |= 64;
24486 return result;
24488 _ACEOF
24489 if ac_fn_c_try_run "$LINENO"; then :
24490 gl_cv_func_working_mktime=yes
24491 else
24492 gl_cv_func_working_mktime=no
24494 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24495 conftest.$ac_objext conftest.beam conftest.$ac_ext
24500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24501 $as_echo "$gl_cv_func_working_mktime" >&6; }
24503 if test $gl_cv_func_working_mktime = no; then
24504 REPLACE_MKTIME=1
24505 else
24506 REPLACE_MKTIME=0
24509 if test $REPLACE_MKTIME = 1; then
24518 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24527 GNULIB_MKTIME=1
24540 if test $ac_cv_func_pipe2 != yes; then
24541 HAVE_PIPE2=0
24549 GNULIB_PIPE2=1
24560 if test $ac_cv_func_pselect = yes; then
24561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24562 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24563 if test "${gl_cv_sig_pselect+set}" = set; then :
24564 $as_echo_n "(cached) " >&6
24565 else
24566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24567 /* end confdefs.h. */
24568 #include <sys/select.h>
24571 main ()
24573 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24574 struct timespec const *restrict,
24575 sigset_t const *restrict) = pselect;
24576 return !p;
24578 return 0;
24580 _ACEOF
24581 if ac_fn_c_try_link "$LINENO"; then :
24582 gl_cv_sig_pselect=yes
24583 else
24584 gl_cv_sig_pselect=no
24586 rm -f core conftest.err conftest.$ac_objext \
24587 conftest$ac_exeext conftest.$ac_ext
24589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24590 $as_echo "$gl_cv_sig_pselect" >&6; }
24592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24593 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24594 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24595 $as_echo_n "(cached) " >&6
24596 else
24598 if test "$cross_compiling" = yes; then :
24600 case "$host_os" in
24601 # Guess yes on glibc systems.
24602 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24603 # If we don't know, assume the worst.
24604 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
24605 esac
24607 else
24608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24609 /* end confdefs.h. */
24611 #include <sys/types.h>
24612 #include <sys/time.h>
24613 #if HAVE_SYS_SELECT_H
24614 # include <sys/select.h>
24615 #endif
24616 #include <unistd.h>
24617 #include <errno.h>
24620 main ()
24623 fd_set set;
24624 dup2(0, 16);
24625 FD_ZERO(&set);
24626 FD_SET(16, &set);
24627 close(16);
24628 struct timespec timeout;
24629 timeout.tv_sec = 0;
24630 timeout.tv_nsec = 5000;
24631 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
24634 return 0;
24636 _ACEOF
24637 if ac_fn_c_try_run "$LINENO"; then :
24638 gl_cv_func_pselect_detects_ebadf=yes
24639 else
24640 gl_cv_func_pselect_detects_ebadf=no
24642 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24643 conftest.$ac_objext conftest.beam conftest.$ac_ext
24648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
24649 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
24650 case $gl_cv_func_pselect_detects_ebadf in
24651 *yes) ;;
24652 *) REPLACE_PSELECT=1 ;;
24653 esac
24656 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
24657 REPLACE_PSELECT=1
24660 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
24669 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
24677 GNULIB_PSELECT=1
24687 LIB_PTHREAD_SIGMASK=
24692 if test "$gl_threads_api" = posix; then
24693 if test $ac_cv_func_pthread_sigmask = yes; then
24695 else
24696 if test -n "$LIBMULTITHREAD"; then
24697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
24698 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
24699 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
24700 $as_echo_n "(cached) " >&6
24701 else
24702 gl_save_LIBS="$LIBS"
24703 LIBS="$LIBS $LIBMULTITHREAD"
24704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24705 /* end confdefs.h. */
24706 #include <pthread.h>
24707 #include <signal.h>
24710 main ()
24712 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
24714 return 0;
24717 _ACEOF
24718 if ac_fn_c_try_link "$LINENO"; then :
24719 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
24720 else
24721 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
24723 rm -f core conftest.err conftest.$ac_objext \
24724 conftest$ac_exeext conftest.$ac_ext
24725 LIBS="$gl_save_LIBS"
24728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
24729 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
24730 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
24731 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
24732 else
24733 HAVE_PTHREAD_SIGMASK=0
24735 else
24736 HAVE_PTHREAD_SIGMASK=0
24739 else
24740 if test $ac_cv_func_pthread_sigmask = yes; then
24741 REPLACE_PTHREAD_SIGMASK=1
24742 else
24743 HAVE_PTHREAD_SIGMASK=0
24750 if test $HAVE_PTHREAD_SIGMASK = 1; then
24753 if test -z "$LIB_PTHREAD_SIGMASK"; then
24754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
24755 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
24756 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
24757 $as_echo_n "(cached) " >&6
24758 else
24760 if test "$cross_compiling" = yes; then :
24762 case "$host_os" in
24763 freebsd* | hpux* | solaris | solaris2.[2-9]*)
24764 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
24766 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
24767 esac
24769 else
24770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24771 /* end confdefs.h. */
24773 #include <pthread.h>
24774 #include <signal.h>
24775 #include <stddef.h>
24776 int main ()
24778 sigset_t set;
24779 sigemptyset (&set);
24780 return pthread_sigmask (1729, &set, NULL) != 0;
24782 _ACEOF
24783 if ac_fn_c_try_run "$LINENO"; then :
24784 gl_cv_func_pthread_sigmask_in_libc_works=no
24785 else
24786 gl_cv_func_pthread_sigmask_in_libc_works=yes
24788 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24789 conftest.$ac_objext conftest.beam conftest.$ac_ext
24794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
24795 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
24796 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
24797 *no)
24798 REPLACE_PTHREAD_SIGMASK=1
24800 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
24803 esac
24806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
24807 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
24808 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
24809 $as_echo_n "(cached) " >&6
24810 else
24812 gl_save_LIBS="$LIBS"
24813 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
24814 if test "$cross_compiling" = yes; then :
24815 case "$host_os" in
24816 cygwin*)
24817 gl_cv_func_pthread_sigmask_return_works="guessing no";;
24819 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
24820 esac
24822 else
24823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24824 /* end confdefs.h. */
24826 #include <pthread.h>
24827 #include <signal.h>
24828 #include <stddef.h>
24829 int main ()
24831 sigset_t set;
24832 sigemptyset (&set);
24833 if (pthread_sigmask (1729, &set, NULL) == -1)
24834 return 1;
24835 return 0;
24837 _ACEOF
24838 if ac_fn_c_try_run "$LINENO"; then :
24839 gl_cv_func_pthread_sigmask_return_works=yes
24840 else
24841 gl_cv_func_pthread_sigmask_return_works=no
24843 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24844 conftest.$ac_objext conftest.beam conftest.$ac_ext
24847 LIBS="$gl_save_LIBS"
24850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
24851 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
24852 case "$gl_cv_func_pthread_sigmask_return_works" in
24853 *no)
24854 REPLACE_PTHREAD_SIGMASK=1
24856 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
24859 esac
24861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
24862 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
24863 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
24864 $as_echo_n "(cached) " >&6
24865 else
24867 case "$host_os" in
24868 irix*)
24869 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
24871 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
24872 esac
24873 gl_save_LIBS="$LIBS"
24874 LIBS="$LIBS $LIBMULTITHREAD"
24875 if test "$cross_compiling" = yes; then :
24877 else
24878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24879 /* end confdefs.h. */
24881 #include <pthread.h>
24882 #include <signal.h>
24883 #include <stdio.h>
24884 #include <stdlib.h>
24885 #include <unistd.h>
24886 static volatile int sigint_occurred;
24887 static void
24888 sigint_handler (int sig)
24890 sigint_occurred++;
24892 int main ()
24894 sigset_t set;
24895 int pid = getpid ();
24896 char command[80];
24897 signal (SIGINT, sigint_handler);
24898 sigemptyset (&set);
24899 sigaddset (&set, SIGINT);
24900 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
24901 return 1;
24902 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
24903 if (!(system (command) == 0))
24904 return 2;
24905 sleep (2);
24906 if (!(sigint_occurred == 0))
24907 return 3;
24908 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
24909 return 4;
24910 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
24911 return 5;
24912 return 0;
24914 _ACEOF
24915 if ac_fn_c_try_run "$LINENO"; then :
24917 else
24918 gl_cv_func_pthread_sigmask_unblock_works=no
24920 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24921 conftest.$ac_objext conftest.beam conftest.$ac_ext
24924 LIBS="$gl_save_LIBS"
24927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
24928 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
24929 case "$gl_cv_func_pthread_sigmask_unblock_works" in
24930 *no)
24931 REPLACE_PTHREAD_SIGMASK=1
24933 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
24936 esac
24939 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
24948 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
24951 if test $HAVE_PTHREAD_SIGMASK = 1; then
24953 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
24963 GNULIB_PTHREAD_SIGMASK=1
24971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
24972 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
24973 if test "${gl_cv_func_svid_putenv+set}" = set; then :
24974 $as_echo_n "(cached) " >&6
24975 else
24976 if test "$cross_compiling" = yes; then :
24977 case "$host_os" in
24978 # Guess yes on glibc systems.
24979 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
24980 # If we don't know, assume the worst.
24981 *) gl_cv_func_svid_putenv="guessing no" ;;
24982 esac
24984 else
24985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24986 /* end confdefs.h. */
24987 $ac_includes_default
24989 main ()
24992 /* Put it in env. */
24993 if (putenv ("CONFTEST_putenv=val"))
24994 return 1;
24996 /* Try to remove it. */
24997 if (putenv ("CONFTEST_putenv"))
24998 return 2;
25000 /* Make sure it was deleted. */
25001 if (getenv ("CONFTEST_putenv") != 0)
25002 return 3;
25004 return 0;
25007 return 0;
25009 _ACEOF
25010 if ac_fn_c_try_run "$LINENO"; then :
25011 gl_cv_func_svid_putenv=yes
25012 else
25013 gl_cv_func_svid_putenv=no
25015 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25016 conftest.$ac_objext conftest.beam conftest.$ac_ext
25021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
25022 $as_echo "$gl_cv_func_svid_putenv" >&6; }
25023 case "$gl_cv_func_svid_putenv" in
25024 *yes) ;;
25026 REPLACE_PUTENV=1
25028 esac
25030 if test $REPLACE_PUTENV = 1; then
25039 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
25042 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
25043 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
25044 ac_have_decl=1
25045 else
25046 ac_have_decl=0
25049 cat >>confdefs.h <<_ACEOF
25050 #define HAVE_DECL__PUTENV $ac_have_decl
25051 _ACEOF
25060 GNULIB_PUTENV=1
25067 # Check whether --enable-acl was given.
25068 if test "${enable_acl+set}" = set; then :
25069 enableval=$enable_acl;
25070 else
25071 enable_acl=auto
25075 LIB_ACL=
25076 use_acl=0
25077 if test "x$enable_acl" != "xno"; then
25078 for ac_header in sys/acl.h
25079 do :
25080 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
25081 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
25082 cat >>confdefs.h <<_ACEOF
25083 #define HAVE_SYS_ACL_H 1
25084 _ACEOF
25088 done
25090 if test $ac_cv_header_sys_acl_h = yes; then
25091 ac_save_LIBS=$LIBS
25093 if test $use_acl = 0; then
25094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
25095 $as_echo_n "checking for library containing acl_get_file... " >&6; }
25096 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25097 $as_echo_n "(cached) " >&6
25098 else
25099 ac_func_search_save_LIBS=$LIBS
25100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25101 /* end confdefs.h. */
25103 /* Override any GCC internal prototype to avoid an error.
25104 Use char because int might match the return type of a GCC
25105 builtin and then its argument prototype would still apply. */
25106 #ifdef __cplusplus
25107 extern "C"
25108 #endif
25109 char acl_get_file ();
25111 main ()
25113 return acl_get_file ();
25115 return 0;
25117 _ACEOF
25118 for ac_lib in '' acl pacl; do
25119 if test -z "$ac_lib"; then
25120 ac_res="none required"
25121 else
25122 ac_res=-l$ac_lib
25123 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25125 if ac_fn_c_try_link "$LINENO"; then :
25126 ac_cv_search_acl_get_file=$ac_res
25128 rm -f core conftest.err conftest.$ac_objext \
25129 conftest$ac_exeext
25130 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25131 break
25133 done
25134 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25136 else
25137 ac_cv_search_acl_get_file=no
25139 rm conftest.$ac_ext
25140 LIBS=$ac_func_search_save_LIBS
25142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
25143 $as_echo "$ac_cv_search_acl_get_file" >&6; }
25144 ac_res=$ac_cv_search_acl_get_file
25145 if test "$ac_res" != no; then :
25146 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25147 if test "$ac_cv_search_acl_get_file" != "none required"; then
25148 LIB_ACL=$ac_cv_search_acl_get_file
25150 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
25151 acl_free acl_from_mode acl_from_text \
25152 acl_delete_def_file acl_extended_file \
25153 acl_delete_fd_np acl_delete_file_np \
25154 acl_copy_ext_native acl_create_entry_np \
25155 acl_to_short_text acl_free_text
25156 do :
25157 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25158 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
25159 eval as_val=\$$as_ac_var
25160 if test "x$as_val" = x""yes; then :
25161 cat >>confdefs.h <<_ACEOF
25162 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25163 _ACEOF
25166 done
25168 # If the acl_get_file bug is detected, don't enable the ACL support.
25170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
25171 $as_echo_n "checking for working acl_get_file... " >&6; }
25172 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
25173 $as_echo_n "(cached) " >&6
25174 else
25175 if test "$cross_compiling" = yes; then :
25176 gl_cv_func_working_acl_get_file=cross-compiling
25177 else
25178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25179 /* end confdefs.h. */
25180 #include <sys/types.h>
25181 #include <sys/acl.h>
25182 #include <errno.h>
25185 main ()
25187 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25188 return 1;
25189 return 0;
25192 return 0;
25194 _ACEOF
25195 if ac_fn_c_try_run "$LINENO"; then :
25196 gl_cv_func_working_acl_get_file=yes
25197 else
25198 gl_cv_func_working_acl_get_file=no
25200 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25201 conftest.$ac_objext conftest.beam conftest.$ac_ext
25205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25206 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25208 if test $gl_cv_func_working_acl_get_file = yes; then :
25209 use_acl=1
25212 if test $use_acl = 1; then
25213 for ac_header in acl/libacl.h
25214 do :
25215 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25216 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
25217 cat >>confdefs.h <<_ACEOF
25218 #define HAVE_ACL_LIBACL_H 1
25219 _ACEOF
25223 done
25233 for ac_func in acl_entries
25234 do :
25235 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25236 if test "x$ac_cv_func_acl_entries" = x""yes; then :
25237 cat >>confdefs.h <<_ACEOF
25238 #define HAVE_ACL_ENTRIES 1
25239 _ACEOF
25241 else
25243 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25246 done
25249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25250 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25251 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
25252 $as_echo_n "(cached) " >&6
25253 else
25254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25255 /* end confdefs.h. */
25256 #include <sys/types.h>
25257 #include <sys/acl.h>
25258 int type = ACL_FIRST_ENTRY;
25260 main ()
25264 return 0;
25266 _ACEOF
25267 if ac_fn_c_try_compile "$LINENO"; then :
25268 gl_cv_acl_ACL_FIRST_ENTRY=yes
25269 else
25270 gl_cv_acl_ACL_FIRST_ENTRY=no
25272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25275 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25276 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25278 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25282 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25283 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
25284 $as_echo_n "(cached) " >&6
25285 else
25286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25287 /* end confdefs.h. */
25288 #include <sys/types.h>
25289 #include <sys/acl.h>
25290 int type = ACL_TYPE_EXTENDED;
25292 main ()
25296 return 0;
25298 _ACEOF
25299 if ac_fn_c_try_compile "$LINENO"; then :
25300 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25301 else
25302 gl_cv_acl_ACL_TYPE_EXTENDED=no
25304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25307 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25308 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25310 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25313 else
25314 LIB_ACL=
25321 if test $use_acl = 0; then
25322 for ac_func in facl
25323 do :
25324 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25325 if test "x$ac_cv_func_facl" = x""yes; then :
25326 cat >>confdefs.h <<_ACEOF
25327 #define HAVE_FACL 1
25328 _ACEOF
25331 done
25333 if test $ac_cv_func_facl = yes; then
25334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25335 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25336 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25337 $as_echo_n "(cached) " >&6
25338 else
25339 ac_func_search_save_LIBS=$LIBS
25340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25341 /* end confdefs.h. */
25343 /* Override any GCC internal prototype to avoid an error.
25344 Use char because int might match the return type of a GCC
25345 builtin and then its argument prototype would still apply. */
25346 #ifdef __cplusplus
25347 extern "C"
25348 #endif
25349 char acl_trivial ();
25351 main ()
25353 return acl_trivial ();
25355 return 0;
25357 _ACEOF
25358 for ac_lib in '' sec; do
25359 if test -z "$ac_lib"; then
25360 ac_res="none required"
25361 else
25362 ac_res=-l$ac_lib
25363 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25365 if ac_fn_c_try_link "$LINENO"; then :
25366 ac_cv_search_acl_trivial=$ac_res
25368 rm -f core conftest.err conftest.$ac_objext \
25369 conftest$ac_exeext
25370 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25371 break
25373 done
25374 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25376 else
25377 ac_cv_search_acl_trivial=no
25379 rm conftest.$ac_ext
25380 LIBS=$ac_func_search_save_LIBS
25382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25383 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25384 ac_res=$ac_cv_search_acl_trivial
25385 if test "$ac_res" != no; then :
25386 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25387 if test "$ac_cv_search_acl_trivial" != "none required"; then
25388 LIB_ACL=$ac_cv_search_acl_trivial
25393 for ac_func in acl_trivial
25394 do :
25395 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25396 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25397 cat >>confdefs.h <<_ACEOF
25398 #define HAVE_ACL_TRIVIAL 1
25399 _ACEOF
25402 done
25404 use_acl=1
25408 if test $use_acl = 0; then
25409 for ac_func in getacl
25410 do :
25411 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25412 if test "x$ac_cv_func_getacl" = x""yes; then :
25413 cat >>confdefs.h <<_ACEOF
25414 #define HAVE_GETACL 1
25415 _ACEOF
25418 done
25420 if test $ac_cv_func_getacl = yes; then
25421 use_acl=1
25423 for ac_header in aclv.h
25424 do :
25425 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25427 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25428 cat >>confdefs.h <<_ACEOF
25429 #define HAVE_ACLV_H 1
25430 _ACEOF
25434 done
25438 if test $use_acl = 0; then
25439 for ac_func in aclx_get
25440 do :
25441 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25442 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25443 cat >>confdefs.h <<_ACEOF
25444 #define HAVE_ACLX_GET 1
25445 _ACEOF
25448 done
25450 if test $ac_cv_func_aclx_get = yes; then
25451 use_acl=1
25455 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25456 for ac_func in statacl
25457 do :
25458 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25459 if test "x$ac_cv_func_statacl" = x""yes; then :
25460 cat >>confdefs.h <<_ACEOF
25461 #define HAVE_STATACL 1
25462 _ACEOF
25465 done
25467 if test $ac_cv_func_statacl = yes; then
25468 use_acl=1
25472 if test $use_acl = 0; then
25473 for ac_func in aclsort
25474 do :
25475 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25476 if test "x$ac_cv_func_aclsort" = x""yes; then :
25477 cat >>confdefs.h <<_ACEOF
25478 #define HAVE_ACLSORT 1
25479 _ACEOF
25482 done
25484 if test $ac_cv_func_aclsort = yes; then
25485 use_acl=1
25489 LIBS=$ac_save_LIBS
25491 if test "x$enable_acl$use_acl" = "xyes0"; then
25492 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25493 elif test "x$enable_acl$use_acl" = "xauto0"; then
25494 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25495 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25496 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25497 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25502 cat >>confdefs.h <<_ACEOF
25503 #define USE_ACL $use_acl
25504 _ACEOF
25506 USE_ACL=$use_acl
25512 if test $ac_cv_func_readlink = no; then
25513 HAVE_READLINK=0
25514 else
25515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25516 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25517 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25518 $as_echo_n "(cached) " >&6
25519 else
25520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25521 /* end confdefs.h. */
25522 #include <unistd.h>
25523 /* Cause compilation failure if original declaration has wrong type. */
25524 ssize_t readlink (const char *, char *, size_t);
25526 main ()
25530 return 0;
25532 _ACEOF
25533 if ac_fn_c_try_compile "$LINENO"; then :
25534 gl_cv_decl_readlink_works=yes
25535 else
25536 gl_cv_decl_readlink_works=no
25538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25541 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25543 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25544 if test "${gl_cv_func_readlink_works+set}" = set; then :
25545 $as_echo_n "(cached) " >&6
25546 else
25547 # We have readlink, so assume ln -s works.
25548 ln -s conftest.no-such conftest.link
25549 ln -s conftest.link conftest.lnk2
25550 if test "$cross_compiling" = yes; then :
25551 case "$host_os" in
25552 # Guess yes on glibc systems.
25553 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25554 # If we don't know, assume the worst.
25555 *) gl_cv_func_readlink_works="guessing no" ;;
25556 esac
25558 else
25559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25560 /* end confdefs.h. */
25561 #include <unistd.h>
25564 main ()
25566 char buf[20];
25567 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25569 return 0;
25571 _ACEOF
25572 if ac_fn_c_try_run "$LINENO"; then :
25573 gl_cv_func_readlink_works=yes
25574 else
25575 gl_cv_func_readlink_works=no
25577 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25578 conftest.$ac_objext conftest.beam conftest.$ac_ext
25581 rm -f conftest.link conftest.lnk2
25583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25584 $as_echo "$gl_cv_func_readlink_works" >&6; }
25585 case "$gl_cv_func_readlink_works" in
25586 *yes)
25587 if test "$gl_cv_decl_readlink_works" != yes; then
25588 REPLACE_READLINK=1
25593 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25595 REPLACE_READLINK=1
25597 esac
25600 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25609 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
25620 GNULIB_READLINK=1
25630 if test $ac_cv_func_readlinkat = no; then
25631 HAVE_READLINKAT=0
25634 if test $HAVE_READLINKAT = 0; then
25643 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
25651 GNULIB_READLINKAT=1
25658 for ac_func in sig2str
25659 do :
25660 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
25661 if test "x$ac_cv_func_sig2str" = x""yes; then :
25662 cat >>confdefs.h <<_ACEOF
25663 #define HAVE_SIG2STR 1
25664 _ACEOF
25667 done
25670 if test $ac_cv_func_sig2str = no; then
25679 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
25696 if test $gl_cv_have_include_next = yes; then
25697 gl_cv_next_signal_h='<'signal.h'>'
25698 else
25699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
25700 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
25701 if test "${gl_cv_next_signal_h+set}" = set; then :
25702 $as_echo_n "(cached) " >&6
25703 else
25705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25706 /* end confdefs.h. */
25707 #include <signal.h>
25709 _ACEOF
25710 case "$host_os" in
25711 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25712 *) gl_absname_cpp="$ac_cpp" ;;
25713 esac
25715 case "$host_os" in
25716 mingw*)
25717 gl_dirsep_regex='[/\\]'
25720 gl_dirsep_regex='\/'
25722 esac
25723 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25725 gl_header_literal_regex=`echo 'signal.h' \
25726 | sed -e "$gl_make_literal_regex_sed"`
25727 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25728 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25729 s|^/[^/]|//&|
25733 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25734 sed -n "$gl_absolute_header_sed"`'"'
25738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
25739 $as_echo "$gl_cv_next_signal_h" >&6; }
25741 NEXT_SIGNAL_H=$gl_cv_next_signal_h
25743 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25744 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25745 gl_next_as_first_directive='<'signal.h'>'
25746 else
25747 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25748 gl_next_as_first_directive=$gl_cv_next_signal_h
25750 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
25756 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
25757 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
25758 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
25759 #include <signal.h>
25762 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
25764 else
25765 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
25774 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
25775 #include <signal.h>
25778 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
25780 else
25781 HAVE_SIGHANDLER_T=0
25787 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
25788 /* <sys/types.h> is not needed according to POSIX, but the
25789 <sys/socket.h> in i386-unknown-freebsd4.10 and
25790 powerpc-apple-darwin5.5 required it. */
25791 #include <sys/types.h>
25792 #if HAVE_SYS_SOCKET_H
25793 # include <sys/socket.h>
25794 #elif HAVE_WS2TCPIP_H
25795 # include <ws2tcpip.h>
25796 #endif
25799 if test "x$ac_cv_type_socklen_t" = x""yes; then :
25801 else
25802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
25803 $as_echo_n "checking for socklen_t equivalent... " >&6; }
25804 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
25805 $as_echo_n "(cached) " >&6
25806 else
25807 # Systems have either "struct sockaddr *" or
25808 # "void *" as the second argument to getpeername
25809 gl_cv_socklen_t_equiv=
25810 for arg2 in "struct sockaddr" void; do
25811 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
25812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25813 /* end confdefs.h. */
25814 #include <sys/types.h>
25815 #include <sys/socket.h>
25817 int getpeername (int, $arg2 *, $t *);
25819 main ()
25821 $t len;
25822 getpeername (0, 0, &len);
25824 return 0;
25826 _ACEOF
25827 if ac_fn_c_try_compile "$LINENO"; then :
25828 gl_cv_socklen_t_equiv="$t"
25830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25831 test "$gl_cv_socklen_t_equiv" != "" && break
25832 done
25833 test "$gl_cv_socklen_t_equiv" != "" && break
25834 done
25838 if test "$gl_cv_socklen_t_equiv" = ""; then
25839 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
25841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
25842 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
25844 cat >>confdefs.h <<_ACEOF
25845 #define socklen_t $gl_cv_socklen_t_equiv
25846 _ACEOF
25851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
25852 $as_echo_n "checking for ssize_t... " >&6; }
25853 if test "${gt_cv_ssize_t+set}" = set; then :
25854 $as_echo_n "(cached) " >&6
25855 else
25856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25857 /* end confdefs.h. */
25858 #include <sys/types.h>
25860 main ()
25862 int x = sizeof (ssize_t *) + sizeof (ssize_t);
25863 return !x;
25865 return 0;
25867 _ACEOF
25868 if ac_fn_c_try_compile "$LINENO"; then :
25869 gt_cv_ssize_t=yes
25870 else
25871 gt_cv_ssize_t=no
25873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
25876 $as_echo "$gt_cv_ssize_t" >&6; }
25877 if test $gt_cv_ssize_t = no; then
25879 $as_echo "#define ssize_t int" >>confdefs.h
25887 ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
25888 #include <sys/stat.h>
25890 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
25892 cat >>confdefs.h <<_ACEOF
25893 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
25894 _ACEOF
25896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
25897 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
25898 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
25899 $as_echo_n "(cached) " >&6
25900 else
25901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25902 /* end confdefs.h. */
25904 #include <sys/types.h>
25905 #include <sys/stat.h>
25906 #if HAVE_SYS_TIME_H
25907 # include <sys/time.h>
25908 #endif
25909 #include <time.h>
25910 struct timespec ts;
25911 struct stat st;
25914 main ()
25917 st.st_atim = ts;
25920 return 0;
25922 _ACEOF
25923 if ac_fn_c_try_compile "$LINENO"; then :
25924 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
25925 else
25926 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
25928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
25931 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
25932 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
25934 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
25937 else
25938 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
25939 #include <sys/stat.h>
25941 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
25943 cat >>confdefs.h <<_ACEOF
25944 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
25945 _ACEOF
25948 else
25949 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
25950 #include <sys/stat.h>
25952 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
25954 cat >>confdefs.h <<_ACEOF
25955 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
25956 _ACEOF
25959 else
25960 ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
25961 #include <sys/stat.h>
25963 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
25965 cat >>confdefs.h <<_ACEOF
25966 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
25967 _ACEOF
25982 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimespec.tv_nsec" "ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" "#include <sys/types.h>
25983 #include <sys/stat.h>
25985 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
25987 cat >>confdefs.h <<_ACEOF
25988 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
25989 _ACEOF
25992 else
25993 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
25994 #include <sys/stat.h>
25996 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
25998 cat >>confdefs.h <<_ACEOF
25999 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
26000 _ACEOF
26003 else
26004 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtim.tv_nsec" "ac_cv_member_struct_stat_st_birthtim_tv_nsec" "#include <sys/types.h>
26005 #include <sys/stat.h>
26007 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
26009 cat >>confdefs.h <<_ACEOF
26010 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
26011 _ACEOF
26022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
26023 $as_echo_n "checking for working stdalign.h... " >&6; }
26024 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
26025 $as_echo_n "(cached) " >&6
26026 else
26027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26028 /* end confdefs.h. */
26029 #include <stdalign.h>
26030 #include <stddef.h>
26032 /* Test that alignof yields a result consistent with offsetof.
26033 This catches GCC bug 52023
26034 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
26035 #ifdef __cplusplus
26036 template <class t> struct alignof_helper { char a; t b; };
26037 # define ao(type) offsetof (alignof_helper<type>, b)
26038 #else
26039 # define ao(type) offsetof (struct { char a; type b; }, b)
26040 #endif
26041 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
26042 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
26043 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
26045 /* Test _Alignas only on platforms where gnulib can help. */
26046 #if \
26047 ((defined __cplusplus && 201103 <= __cplusplus) \
26048 || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
26049 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
26050 struct alignas_test { char c; char alignas (8) alignas_8; };
26051 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
26052 ? 1 : -1];
26053 #endif
26056 main ()
26060 return 0;
26062 _ACEOF
26063 if ac_fn_c_try_compile "$LINENO"; then :
26064 gl_cv_header_working_stdalign_h=yes
26065 else
26066 gl_cv_header_working_stdalign_h=no
26068 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
26071 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
26073 if test $gl_cv_header_working_stdalign_h = yes; then
26074 STDALIGN_H=''
26075 else
26076 STDALIGN_H='stdalign.h'
26080 if test -n "$STDALIGN_H"; then
26081 GL_GENERATE_STDALIGN_H_TRUE=
26082 GL_GENERATE_STDALIGN_H_FALSE='#'
26083 else
26084 GL_GENERATE_STDALIGN_H_TRUE='#'
26085 GL_GENERATE_STDALIGN_H_FALSE=
26090 STDARG_H=''
26091 NEXT_STDARG_H='<stdarg.h>'
26092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
26093 $as_echo_n "checking for va_copy... " >&6; }
26094 if test "${gl_cv_func_va_copy+set}" = set; then :
26095 $as_echo_n "(cached) " >&6
26096 else
26098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26099 /* end confdefs.h. */
26100 #include <stdarg.h>
26102 main ()
26105 #ifndef va_copy
26106 void (*func) (va_list, va_list) = va_copy;
26107 #endif
26110 return 0;
26112 _ACEOF
26113 if ac_fn_c_try_compile "$LINENO"; then :
26114 gl_cv_func_va_copy=yes
26115 else
26116 gl_cv_func_va_copy=no
26118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
26122 $as_echo "$gl_cv_func_va_copy" >&6; }
26123 if test $gl_cv_func_va_copy = no; then
26124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26125 /* end confdefs.h. */
26126 #if defined _AIX && !defined __GNUC__
26127 AIX vaccine
26128 #endif
26130 _ACEOF
26131 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26132 $EGREP "vaccine" >/dev/null 2>&1; then :
26133 gl_aixcc=yes
26134 else
26135 gl_aixcc=no
26137 rm -f conftest*
26139 if test $gl_aixcc = yes; then
26140 STDARG_H=stdarg.h
26149 if test $gl_cv_have_include_next = yes; then
26150 gl_cv_next_stdarg_h='<'stdarg.h'>'
26151 else
26152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
26153 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
26154 if test "${gl_cv_next_stdarg_h+set}" = set; then :
26155 $as_echo_n "(cached) " >&6
26156 else
26158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26159 /* end confdefs.h. */
26160 #include <stdarg.h>
26162 _ACEOF
26163 case "$host_os" in
26164 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26165 *) gl_absname_cpp="$ac_cpp" ;;
26166 esac
26168 case "$host_os" in
26169 mingw*)
26170 gl_dirsep_regex='[/\\]'
26173 gl_dirsep_regex='\/'
26175 esac
26176 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26178 gl_header_literal_regex=`echo 'stdarg.h' \
26179 | sed -e "$gl_make_literal_regex_sed"`
26180 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26181 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26182 s|^/[^/]|//&|
26186 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26187 sed -n "$gl_absolute_header_sed"`'"'
26191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
26192 $as_echo "$gl_cv_next_stdarg_h" >&6; }
26194 NEXT_STDARG_H=$gl_cv_next_stdarg_h
26196 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26197 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26198 gl_next_as_first_directive='<'stdarg.h'>'
26199 else
26200 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26201 gl_next_as_first_directive=$gl_cv_next_stdarg_h
26203 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
26208 if test "$gl_cv_next_stdarg_h" = '""'; then
26209 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
26210 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
26212 else
26214 saved_as_echo_n="$as_echo_n"
26215 as_echo_n=':'
26216 if test "${gl_cv_func___va_copy+set}" = set; then :
26217 $as_echo_n "(cached) " >&6
26218 else
26220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26221 /* end confdefs.h. */
26222 #include <stdarg.h>
26224 main ()
26227 #ifndef __va_copy
26228 error, bail out
26229 #endif
26232 return 0;
26234 _ACEOF
26235 if ac_fn_c_try_compile "$LINENO"; then :
26236 gl_cv_func___va_copy=yes
26237 else
26238 gl_cv_func___va_copy=no
26240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26243 as_echo_n="$saved_as_echo_n"
26245 if test $gl_cv_func___va_copy = yes; then
26247 $as_echo "#define va_copy __va_copy" >>confdefs.h
26249 else
26252 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
26258 if test -n "$STDARG_H"; then
26259 GL_GENERATE_STDARG_H_TRUE=
26260 GL_GENERATE_STDARG_H_FALSE='#'
26261 else
26262 GL_GENERATE_STDARG_H_TRUE='#'
26263 GL_GENERATE_STDARG_H_FALSE=
26271 # Define two additional variables used in the Makefile substitution.
26273 if test "$ac_cv_header_stdbool_h" = yes; then
26274 STDBOOL_H=''
26275 else
26276 STDBOOL_H='stdbool.h'
26279 if test -n "$STDBOOL_H"; then
26280 GL_GENERATE_STDBOOL_H_TRUE=
26281 GL_GENERATE_STDBOOL_H_FALSE='#'
26282 else
26283 GL_GENERATE_STDBOOL_H_TRUE='#'
26284 GL_GENERATE_STDBOOL_H_FALSE=
26288 if test "$ac_cv_type__Bool" = yes; then
26289 HAVE__BOOL=1
26290 else
26291 HAVE__BOOL=0
26298 STDDEF_H=
26299 if test $gt_cv_c_wchar_t = no; then
26300 HAVE_WCHAR_T=0
26301 STDDEF_H=stddef.h
26303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26304 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26305 if test "${gl_cv_decl_null_works+set}" = set; then :
26306 $as_echo_n "(cached) " >&6
26307 else
26308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26309 /* end confdefs.h. */
26310 #include <stddef.h>
26311 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26314 main ()
26318 return 0;
26320 _ACEOF
26321 if ac_fn_c_try_compile "$LINENO"; then :
26322 gl_cv_decl_null_works=yes
26323 else
26324 gl_cv_decl_null_works=no
26326 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26329 $as_echo "$gl_cv_decl_null_works" >&6; }
26330 if test $gl_cv_decl_null_works = no; then
26331 REPLACE_NULL=1
26332 STDDEF_H=stddef.h
26335 if test -n "$STDDEF_H"; then
26336 GL_GENERATE_STDDEF_H_TRUE=
26337 GL_GENERATE_STDDEF_H_FALSE='#'
26338 else
26339 GL_GENERATE_STDDEF_H_TRUE='#'
26340 GL_GENERATE_STDDEF_H_FALSE=
26343 if test -n "$STDDEF_H"; then
26352 if test $gl_cv_have_include_next = yes; then
26353 gl_cv_next_stddef_h='<'stddef.h'>'
26354 else
26355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26356 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26357 if test "${gl_cv_next_stddef_h+set}" = set; then :
26358 $as_echo_n "(cached) " >&6
26359 else
26361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26362 /* end confdefs.h. */
26363 #include <stddef.h>
26365 _ACEOF
26366 case "$host_os" in
26367 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26368 *) gl_absname_cpp="$ac_cpp" ;;
26369 esac
26371 case "$host_os" in
26372 mingw*)
26373 gl_dirsep_regex='[/\\]'
26376 gl_dirsep_regex='\/'
26378 esac
26379 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26381 gl_header_literal_regex=`echo 'stddef.h' \
26382 | sed -e "$gl_make_literal_regex_sed"`
26383 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26384 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26385 s|^/[^/]|//&|
26389 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26390 sed -n "$gl_absolute_header_sed"`'"'
26394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26395 $as_echo "$gl_cv_next_stddef_h" >&6; }
26397 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26399 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26400 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26401 gl_next_as_first_directive='<'stddef.h'>'
26402 else
26403 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26404 gl_next_as_first_directive=$gl_cv_next_stddef_h
26406 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26424 if test $gl_cv_have_include_next = yes; then
26425 gl_cv_next_stdio_h='<'stdio.h'>'
26426 else
26427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26428 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26429 if test "${gl_cv_next_stdio_h+set}" = set; then :
26430 $as_echo_n "(cached) " >&6
26431 else
26433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26434 /* end confdefs.h. */
26435 #include <stdio.h>
26437 _ACEOF
26438 case "$host_os" in
26439 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26440 *) gl_absname_cpp="$ac_cpp" ;;
26441 esac
26443 case "$host_os" in
26444 mingw*)
26445 gl_dirsep_regex='[/\\]'
26448 gl_dirsep_regex='\/'
26450 esac
26451 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26453 gl_header_literal_regex=`echo 'stdio.h' \
26454 | sed -e "$gl_make_literal_regex_sed"`
26455 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26456 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26457 s|^/[^/]|//&|
26461 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26462 sed -n "$gl_absolute_header_sed"`'"'
26466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26467 $as_echo "$gl_cv_next_stdio_h" >&6; }
26469 NEXT_STDIO_H=$gl_cv_next_stdio_h
26471 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26472 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26473 gl_next_as_first_directive='<'stdio.h'>'
26474 else
26475 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26476 gl_next_as_first_directive=$gl_cv_next_stdio_h
26478 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26484 GNULIB_FSCANF=1
26487 cat >>confdefs.h <<_ACEOF
26488 #define GNULIB_FSCANF 1
26489 _ACEOF
26492 GNULIB_SCANF=1
26495 cat >>confdefs.h <<_ACEOF
26496 #define GNULIB_SCANF 1
26497 _ACEOF
26500 GNULIB_FGETC=1
26501 GNULIB_GETC=1
26502 GNULIB_GETCHAR=1
26503 GNULIB_FGETS=1
26504 GNULIB_FREAD=1
26507 GNULIB_FPRINTF=1
26508 GNULIB_PRINTF=1
26509 GNULIB_VFPRINTF=1
26510 GNULIB_VPRINTF=1
26511 GNULIB_FPUTC=1
26512 GNULIB_PUTC=1
26513 GNULIB_PUTCHAR=1
26514 GNULIB_FPUTS=1
26515 GNULIB_PUTS=1
26516 GNULIB_FWRITE=1
26532 if test $gl_cv_have_include_next = yes; then
26533 gl_cv_next_stdlib_h='<'stdlib.h'>'
26534 else
26535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26536 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26537 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26538 $as_echo_n "(cached) " >&6
26539 else
26541 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26542 /* end confdefs.h. */
26543 #include <stdlib.h>
26545 _ACEOF
26546 case "$host_os" in
26547 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26548 *) gl_absname_cpp="$ac_cpp" ;;
26549 esac
26551 case "$host_os" in
26552 mingw*)
26553 gl_dirsep_regex='[/\\]'
26556 gl_dirsep_regex='\/'
26558 esac
26559 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26561 gl_header_literal_regex=`echo 'stdlib.h' \
26562 | sed -e "$gl_make_literal_regex_sed"`
26563 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26564 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26565 s|^/[^/]|//&|
26569 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26570 sed -n "$gl_absolute_header_sed"`'"'
26574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26575 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26577 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26579 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26580 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26581 gl_next_as_first_directive='<'stdlib.h'>'
26582 else
26583 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26584 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26586 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26596 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26604 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26616 if test "$ac_cv_have_decl_strtoimax" != yes; then
26617 HAVE_DECL_STRTOIMAX=0
26620 if test $ac_cv_func_strtoimax = yes; then
26621 HAVE_STRTOIMAX=1
26622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
26623 $as_echo_n "checking whether strtoimax works... " >&6; }
26624 if test "${gl_cv_func_strtoimax+set}" = set; then :
26625 $as_echo_n "(cached) " >&6
26626 else
26627 if test "$cross_compiling" = yes; then :
26628 case "$host_os" in
26629 # Guess no on AIX 5.
26630 aix5*) gl_cv_func_strtoimax="guessing no" ;;
26631 # Guess yes otherwise.
26632 *) gl_cv_func_strtoimax="guessing yes" ;;
26633 esac
26635 else
26636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26637 /* end confdefs.h. */
26639 #include <errno.h>
26640 #include <string.h>
26641 #include <inttypes.h>
26642 int main ()
26644 if (sizeof (intmax_t) > sizeof (int))
26646 const char *s = "4294967295";
26647 char *p;
26648 intmax_t res;
26649 errno = 0;
26650 res = strtoimax (s, &p, 10);
26651 if (p != s + strlen (s))
26652 return 1;
26653 if (errno != 0)
26654 return 2;
26655 if (res != (intmax_t) 65535 * (intmax_t) 65537)
26656 return 3;
26658 else
26660 const char *s = "2147483647";
26661 char *p;
26662 intmax_t res;
26663 errno = 0;
26664 res = strtoimax (s, &p, 10);
26665 if (p != s + strlen (s))
26666 return 1;
26667 if (errno != 0)
26668 return 2;
26669 if (res != 2147483647)
26670 return 3;
26672 return 0;
26675 _ACEOF
26676 if ac_fn_c_try_run "$LINENO"; then :
26677 gl_cv_func_strtoimax=yes
26678 else
26679 gl_cv_func_strtoimax=no
26681 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26682 conftest.$ac_objext conftest.beam conftest.$ac_ext
26687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
26688 $as_echo "$gl_cv_func_strtoimax" >&6; }
26689 case "$gl_cv_func_strtoimax" in
26690 *no) REPLACE_STRTOIMAX=1 ;;
26691 esac
26692 else
26693 HAVE_STRTOIMAX=0
26696 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
26705 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
26708 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
26709 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
26710 ac_have_decl=1
26711 else
26712 ac_have_decl=0
26715 cat >>confdefs.h <<_ACEOF
26716 #define HAVE_DECL_STRTOLL $ac_have_decl
26717 _ACEOF
26727 GNULIB_STRTOIMAX=1
26737 if test "$ac_cv_have_decl_strtoumax" != yes; then
26738 HAVE_DECL_STRTOUMAX=0
26741 if test $ac_cv_func_strtoumax = no; then
26750 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
26753 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
26754 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
26755 ac_have_decl=1
26756 else
26757 ac_have_decl=0
26760 cat >>confdefs.h <<_ACEOF
26761 #define HAVE_DECL_STRTOULL $ac_have_decl
26762 _ACEOF
26772 GNULIB_STRTOUMAX=1
26780 if test $ac_cv_func_symlink = no; then
26781 HAVE_SYMLINK=0
26782 else
26783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
26784 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
26785 if test "${gl_cv_func_symlink_works+set}" = set; then :
26786 $as_echo_n "(cached) " >&6
26787 else
26788 if test "$cross_compiling" = yes; then :
26789 case "$host_os" in
26790 # Guess yes on glibc systems.
26791 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
26792 # If we don't know, assume the worst.
26793 *) gl_cv_func_symlink_works="guessing no" ;;
26794 esac
26796 else
26797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26798 /* end confdefs.h. */
26799 #include <unistd.h>
26802 main ()
26804 int result = 0;
26805 if (!symlink ("a", "conftest.link/"))
26806 result |= 1;
26807 if (symlink ("conftest.f", "conftest.lnk2"))
26808 result |= 2;
26809 else if (!symlink ("a", "conftest.lnk2/"))
26810 result |= 4;
26811 return result;
26814 return 0;
26816 _ACEOF
26817 if ac_fn_c_try_run "$LINENO"; then :
26818 gl_cv_func_symlink_works=yes
26819 else
26820 gl_cv_func_symlink_works=no
26822 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26823 conftest.$ac_objext conftest.beam conftest.$ac_ext
26826 rm -f conftest.f conftest.link conftest.lnk2
26828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
26829 $as_echo "$gl_cv_func_symlink_works" >&6; }
26830 case "$gl_cv_func_symlink_works" in
26831 *yes) ;;
26833 REPLACE_SYMLINK=1
26835 esac
26838 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
26847 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
26855 GNULIB_SYMLINK=1
26864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
26865 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
26866 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
26867 $as_echo_n "(cached) " >&6
26868 else
26870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26871 /* end confdefs.h. */
26872 #include <sys/select.h>
26874 main ()
26876 struct timeval b;
26878 return 0;
26880 _ACEOF
26881 if ac_fn_c_try_compile "$LINENO"; then :
26882 gl_cv_header_sys_select_h_selfcontained=yes
26883 else
26884 gl_cv_header_sys_select_h_selfcontained=no
26886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26887 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
26888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26889 /* end confdefs.h. */
26890 #include <sys/select.h>
26892 main ()
26894 int memset; int bzero;
26896 return 0;
26899 _ACEOF
26900 if ac_fn_c_try_compile "$LINENO"; then :
26901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26902 /* end confdefs.h. */
26903 #include <sys/select.h>
26905 main ()
26908 #undef memset
26909 #define memset nonexistent_memset
26910 extern
26911 #ifdef __cplusplus
26913 #endif
26914 void *memset (void *, int, unsigned long);
26915 #undef bzero
26916 #define bzero nonexistent_bzero
26917 extern
26918 #ifdef __cplusplus
26920 #endif
26921 void bzero (void *, unsigned long);
26922 fd_set fds;
26923 FD_ZERO (&fds);
26926 return 0;
26929 _ACEOF
26930 if ac_fn_c_try_link "$LINENO"; then :
26932 else
26933 gl_cv_header_sys_select_h_selfcontained=no
26935 rm -f core conftest.err conftest.$ac_objext \
26936 conftest$ac_exeext conftest.$ac_ext
26939 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
26944 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
26954 if test $gl_cv_have_include_next = yes; then
26955 gl_cv_next_sys_select_h='<'sys/select.h'>'
26956 else
26957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
26958 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
26959 if test "${gl_cv_next_sys_select_h+set}" = set; then :
26960 $as_echo_n "(cached) " >&6
26961 else
26963 if test $ac_cv_header_sys_select_h = yes; then
26966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26967 /* end confdefs.h. */
26968 #include <sys/select.h>
26970 _ACEOF
26971 case "$host_os" in
26972 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26973 *) gl_absname_cpp="$ac_cpp" ;;
26974 esac
26976 case "$host_os" in
26977 mingw*)
26978 gl_dirsep_regex='[/\\]'
26981 gl_dirsep_regex='\/'
26983 esac
26984 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26986 gl_header_literal_regex=`echo 'sys/select.h' \
26987 | sed -e "$gl_make_literal_regex_sed"`
26988 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26989 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26990 s|^/[^/]|//&|
26994 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26995 sed -n "$gl_absolute_header_sed"`'"'
26996 else
26997 gl_cv_next_sys_select_h='<'sys/select.h'>'
27002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
27003 $as_echo "$gl_cv_next_sys_select_h" >&6; }
27005 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
27007 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27008 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27009 gl_next_as_first_directive='<'sys/select.h'>'
27010 else
27011 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27012 gl_next_as_first_directive=$gl_cv_next_sys_select_h
27014 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
27019 if test $ac_cv_header_sys_select_h = yes; then
27020 HAVE_SYS_SELECT_H=1
27021 else
27022 HAVE_SYS_SELECT_H=0
27029 if test $ac_cv_header_sys_socket_h != yes; then
27030 for ac_header in winsock2.h
27031 do :
27032 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
27033 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
27034 cat >>confdefs.h <<_ACEOF
27035 #define HAVE_WINSOCK2_H 1
27036 _ACEOF
27040 done
27043 if test "$ac_cv_header_winsock2_h" = yes; then
27044 HAVE_WINSOCK2_H=1
27045 UNISTD_H_HAVE_WINSOCK2_H=1
27046 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
27047 else
27048 HAVE_WINSOCK2_H=0
27070 if test $gl_cv_have_include_next = yes; then
27071 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27072 else
27073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
27074 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
27075 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
27076 $as_echo_n "(cached) " >&6
27077 else
27079 if test $ac_cv_header_sys_stat_h = yes; then
27082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27083 /* end confdefs.h. */
27084 #include <sys/stat.h>
27086 _ACEOF
27087 case "$host_os" in
27088 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27089 *) gl_absname_cpp="$ac_cpp" ;;
27090 esac
27092 case "$host_os" in
27093 mingw*)
27094 gl_dirsep_regex='[/\\]'
27097 gl_dirsep_regex='\/'
27099 esac
27100 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27102 gl_header_literal_regex=`echo 'sys/stat.h' \
27103 | sed -e "$gl_make_literal_regex_sed"`
27104 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27105 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27106 s|^/[^/]|//&|
27110 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27111 sed -n "$gl_absolute_header_sed"`'"'
27112 else
27113 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
27119 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
27121 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
27123 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27124 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27125 gl_next_as_first_directive='<'sys/stat.h'>'
27126 else
27127 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27128 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
27130 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
27142 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
27144 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
27148 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
27149 #include <sys/stat.h>
27151 if test "x$ac_cv_type_nlink_t" = x""yes; then :
27153 else
27155 $as_echo "#define nlink_t int" >>confdefs.h
27176 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
27178 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
27179 ac_have_decl=1
27180 else
27181 ac_have_decl=0
27184 cat >>confdefs.h <<_ACEOF
27185 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
27186 _ACEOF
27188 if test $ac_cv_have_decl_localtime_r = no; then
27189 HAVE_DECL_LOCALTIME_R=0
27193 if test $ac_cv_func_localtime_r = yes; then
27194 HAVE_LOCALTIME_R=1
27195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
27196 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
27197 if test "${gl_cv_time_r_posix+set}" = set; then :
27198 $as_echo_n "(cached) " >&6
27199 else
27200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27201 /* end confdefs.h. */
27202 #include <time.h>
27204 main ()
27206 /* We don't need to append 'restrict's to the argument types,
27207 even though the POSIX signature has the 'restrict's,
27208 since C99 says they can't affect type compatibility. */
27209 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
27210 if (ptr) return 0;
27211 /* Check the return type is a pointer.
27212 On HP-UX 10 it is 'int'. */
27213 *localtime_r (0, 0);
27215 return 0;
27218 _ACEOF
27219 if ac_fn_c_try_compile "$LINENO"; then :
27220 gl_cv_time_r_posix=yes
27221 else
27222 gl_cv_time_r_posix=no
27224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
27228 $as_echo "$gl_cv_time_r_posix" >&6; }
27229 if test $gl_cv_time_r_posix = yes; then
27230 REPLACE_LOCALTIME_R=0
27231 else
27232 REPLACE_LOCALTIME_R=1
27234 else
27235 HAVE_LOCALTIME_R=0
27238 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
27247 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
27258 GNULIB_TIME_R=1
27269 LIB_TIMER_TIME=
27271 gl_saved_libs=$LIBS
27272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
27273 $as_echo_n "checking for library containing timer_settime... " >&6; }
27274 if test "${ac_cv_search_timer_settime+set}" = set; then :
27275 $as_echo_n "(cached) " >&6
27276 else
27277 ac_func_search_save_LIBS=$LIBS
27278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27279 /* end confdefs.h. */
27281 /* Override any GCC internal prototype to avoid an error.
27282 Use char because int might match the return type of a GCC
27283 builtin and then its argument prototype would still apply. */
27284 #ifdef __cplusplus
27285 extern "C"
27286 #endif
27287 char timer_settime ();
27289 main ()
27291 return timer_settime ();
27293 return 0;
27295 _ACEOF
27296 for ac_lib in '' rt posix4; do
27297 if test -z "$ac_lib"; then
27298 ac_res="none required"
27299 else
27300 ac_res=-l$ac_lib
27301 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27303 if ac_fn_c_try_link "$LINENO"; then :
27304 ac_cv_search_timer_settime=$ac_res
27306 rm -f core conftest.err conftest.$ac_objext \
27307 conftest$ac_exeext
27308 if test "${ac_cv_search_timer_settime+set}" = set; then :
27309 break
27311 done
27312 if test "${ac_cv_search_timer_settime+set}" = set; then :
27314 else
27315 ac_cv_search_timer_settime=no
27317 rm conftest.$ac_ext
27318 LIBS=$ac_func_search_save_LIBS
27320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27321 $as_echo "$ac_cv_search_timer_settime" >&6; }
27322 ac_res=$ac_cv_search_timer_settime
27323 if test "$ac_res" != no; then :
27324 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27325 test "$ac_cv_search_timer_settime" = "none required" ||
27326 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27330 /* end confdefs.h. */
27332 #include <features.h>
27333 #ifdef __GNU_LIBRARY__
27334 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27335 && !defined __UCLIBC__
27336 Thread emulation available
27337 #endif
27338 #endif
27340 _ACEOF
27341 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27342 $EGREP "Thread" >/dev/null 2>&1; then :
27343 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27345 rm -f conftest*
27347 for ac_func in timer_settime
27348 do :
27349 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27350 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27351 cat >>confdefs.h <<_ACEOF
27352 #define HAVE_TIMER_SETTIME 1
27353 _ACEOF
27356 done
27358 LIBS=$gl_saved_libs
27373 if test $gl_cv_have_include_next = yes; then
27374 gl_cv_next_unistd_h='<'unistd.h'>'
27375 else
27376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27377 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27378 if test "${gl_cv_next_unistd_h+set}" = set; then :
27379 $as_echo_n "(cached) " >&6
27380 else
27382 if test $ac_cv_header_unistd_h = yes; then
27385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27386 /* end confdefs.h. */
27387 #include <unistd.h>
27389 _ACEOF
27390 case "$host_os" in
27391 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27392 *) gl_absname_cpp="$ac_cpp" ;;
27393 esac
27395 case "$host_os" in
27396 mingw*)
27397 gl_dirsep_regex='[/\\]'
27400 gl_dirsep_regex='\/'
27402 esac
27403 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27405 gl_header_literal_regex=`echo 'unistd.h' \
27406 | sed -e "$gl_make_literal_regex_sed"`
27407 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27408 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27409 s|^/[^/]|//&|
27413 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27414 sed -n "$gl_absolute_header_sed"`'"'
27415 else
27416 gl_cv_next_unistd_h='<'unistd.h'>'
27421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27422 $as_echo "$gl_cv_next_unistd_h" >&6; }
27424 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27426 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27427 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27428 gl_next_as_first_directive='<'unistd.h'>'
27429 else
27430 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27431 gl_next_as_first_directive=$gl_cv_next_unistd_h
27433 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27438 if test $ac_cv_header_unistd_h = yes; then
27439 HAVE_UNISTD_H=1
27440 else
27441 HAVE_UNISTD_H=0
27454 if test $ac_cv_have_decl_unsetenv = no; then
27455 HAVE_DECL_UNSETENV=0
27457 for ac_func in unsetenv
27458 do :
27459 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27460 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27461 cat >>confdefs.h <<_ACEOF
27462 #define HAVE_UNSETENV 1
27463 _ACEOF
27466 done
27468 if test $ac_cv_func_unsetenv = no; then
27469 HAVE_UNSETENV=0
27470 else
27471 HAVE_UNSETENV=1
27472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27473 $as_echo_n "checking for unsetenv() return type... " >&6; }
27474 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27475 $as_echo_n "(cached) " >&6
27476 else
27477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27478 /* end confdefs.h. */
27480 #undef _BSD
27481 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27482 #include <stdlib.h>
27483 extern
27484 #ifdef __cplusplus
27486 #endif
27487 int unsetenv (const char *name);
27490 main ()
27494 return 0;
27496 _ACEOF
27497 if ac_fn_c_try_compile "$LINENO"; then :
27498 gt_cv_func_unsetenv_ret='int'
27499 else
27500 gt_cv_func_unsetenv_ret='void'
27502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27505 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27506 if test $gt_cv_func_unsetenv_ret = 'void'; then
27508 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27510 REPLACE_UNSETENV=1
27513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27514 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27515 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27516 $as_echo_n "(cached) " >&6
27517 else
27518 if test "$cross_compiling" = yes; then :
27519 case "$host_os" in
27520 # Guess yes on glibc systems.
27521 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27522 # If we don't know, assume the worst.
27523 *) gl_cv_func_unsetenv_works="guessing no" ;;
27524 esac
27526 else
27527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27528 /* end confdefs.h. */
27530 #include <stdlib.h>
27531 #include <errno.h>
27532 extern char **environ;
27535 main ()
27538 char entry1[] = "a=1";
27539 char entry2[] = "b=2";
27540 char *env[] = { entry1, entry2, NULL };
27541 if (putenv ((char *) "a=1")) return 1;
27542 if (putenv (entry2)) return 2;
27543 entry2[0] = 'a';
27544 unsetenv ("a");
27545 if (getenv ("a")) return 3;
27546 if (!unsetenv ("") || errno != EINVAL) return 4;
27547 entry2[0] = 'b';
27548 environ = env;
27549 if (!getenv ("a")) return 5;
27550 entry2[0] = 'a';
27551 unsetenv ("a");
27552 if (getenv ("a")) return 6;
27555 return 0;
27557 _ACEOF
27558 if ac_fn_c_try_run "$LINENO"; then :
27559 gl_cv_func_unsetenv_works=yes
27560 else
27561 gl_cv_func_unsetenv_works=no
27563 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27564 conftest.$ac_objext conftest.beam conftest.$ac_ext
27568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27569 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27570 case "$gl_cv_func_unsetenv_works" in
27571 *yes) ;;
27573 REPLACE_UNSETENV=1
27575 esac
27578 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27587 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27599 GNULIB_UNSETENV=1
27611 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
27612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
27613 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
27614 if test "${gl_cv_func_futimesat_works+set}" = set; then :
27615 $as_echo_n "(cached) " >&6
27616 else
27617 touch conftest.file
27618 if test "$cross_compiling" = yes; then :
27619 case "$host_os" in
27620 # Guess yes on glibc systems.
27621 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
27622 # If we don't know, assume the worst.
27623 *) gl_cv_func_futimesat_works="guessing no" ;;
27624 esac
27626 else
27627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27628 /* end confdefs.h. */
27630 #include <stddef.h>
27631 #include <sys/times.h>
27632 #include <fcntl.h>
27635 main ()
27637 int fd = open ("conftest.file", O_RDWR);
27638 if (fd < 0) return 1;
27639 if (futimesat (fd, NULL, NULL)) return 2;
27642 return 0;
27644 _ACEOF
27645 if ac_fn_c_try_run "$LINENO"; then :
27646 gl_cv_func_futimesat_works=yes
27647 else
27648 gl_cv_func_futimesat_works=no
27650 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27651 conftest.$ac_objext conftest.beam conftest.$ac_ext
27654 rm -f conftest.file
27656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
27657 $as_echo "$gl_cv_func_futimesat_works" >&6; }
27658 case "$gl_cv_func_futimesat_works" in
27659 *yes) ;;
27662 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
27665 esac
27668 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
27669 gl_gnulib_enabled_dosname=false
27670 gl_gnulib_enabled_euidaccess=false
27671 gl_gnulib_enabled_getdtablesize=false
27672 gl_gnulib_enabled_getgroups=false
27673 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
27674 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
27675 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
27676 gl_gnulib_enabled_pathmax=false
27677 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
27678 gl_gnulib_enabled_secure_getenv=false
27679 gl_gnulib_enabled_stat=false
27680 gl_gnulib_enabled_strtoll=false
27681 gl_gnulib_enabled_strtoull=false
27682 gl_gnulib_enabled_tempname=false
27683 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
27684 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
27686 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
27695 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
27697 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
27700 func_gl_gnulib_m4code_dosname ()
27702 if ! $gl_gnulib_enabled_dosname; then
27703 gl_gnulib_enabled_dosname=true
27706 func_gl_gnulib_m4code_euidaccess ()
27708 if ! $gl_gnulib_enabled_euidaccess; then
27714 for ac_func in euidaccess
27715 do :
27716 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
27717 if test "x$ac_cv_func_euidaccess" = x""yes; then :
27718 cat >>confdefs.h <<_ACEOF
27719 #define HAVE_EUIDACCESS 1
27720 _ACEOF
27723 done
27725 if test $ac_cv_func_euidaccess = no; then
27726 HAVE_EUIDACCESS=0
27729 if test $HAVE_EUIDACCESS = 0; then
27738 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
27742 for ac_header in libgen.h
27743 do :
27744 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
27745 if test "x$ac_cv_header_libgen_h" = x""yes; then :
27746 cat >>confdefs.h <<_ACEOF
27747 #define HAVE_LIBGEN_H 1
27748 _ACEOF
27752 done
27755 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27756 if test "x$ac_cv_func_getgroups" = x""yes; then :
27761 # If we don't yet have getgroups, see if it's in -lbsd.
27762 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27763 ac_save_LIBS=$LIBS
27764 if test $ac_cv_func_getgroups = no; then
27765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27766 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27767 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27768 $as_echo_n "(cached) " >&6
27769 else
27770 ac_check_lib_save_LIBS=$LIBS
27771 LIBS="-lbsd $LIBS"
27772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27773 /* end confdefs.h. */
27775 /* Override any GCC internal prototype to avoid an error.
27776 Use char because int might match the return type of a GCC
27777 builtin and then its argument prototype would still apply. */
27778 #ifdef __cplusplus
27779 extern "C"
27780 #endif
27781 char getgroups ();
27783 main ()
27785 return getgroups ();
27787 return 0;
27789 _ACEOF
27790 if ac_fn_c_try_link "$LINENO"; then :
27791 ac_cv_lib_bsd_getgroups=yes
27792 else
27793 ac_cv_lib_bsd_getgroups=no
27795 rm -f core conftest.err conftest.$ac_objext \
27796 conftest$ac_exeext conftest.$ac_ext
27797 LIBS=$ac_check_lib_save_LIBS
27799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27800 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27801 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27802 GETGROUPS_LIB=-lbsd
27807 # Run the program to test the functionality of the system-supplied
27808 # getgroups function only if there is such a function.
27809 if test $ac_cv_func_getgroups = yes; then
27810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
27811 $as_echo_n "checking for working getgroups... " >&6; }
27812 if test "${ac_cv_func_getgroups_works+set}" = set; then :
27813 $as_echo_n "(cached) " >&6
27814 else
27815 if test "$cross_compiling" = yes; then :
27816 case "$host_os" in # ((
27817 # Guess yes on glibc systems.
27818 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
27819 # If we don't know, assume the worst.
27820 *) ac_cv_func_getgroups_works="guessing no" ;;
27821 esac
27823 else
27824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27825 /* end confdefs.h. */
27826 $ac_includes_default
27828 main ()
27830 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
27831 return getgroups (0, 0) == -1;
27833 return 0;
27836 _ACEOF
27837 if ac_fn_c_try_run "$LINENO"; then :
27838 ac_cv_func_getgroups_works=yes
27839 else
27840 ac_cv_func_getgroups_works=no
27842 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27843 conftest.$ac_objext conftest.beam conftest.$ac_ext
27848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
27849 $as_echo "$ac_cv_func_getgroups_works" >&6; }
27850 else
27851 ac_cv_func_getgroups_works=no
27853 case "$ac_cv_func_getgroups_works" in
27854 *yes)
27856 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
27859 esac
27860 LIBS=$ac_save_LIBS
27863 # Solaris 9 and 10 need -lgen to get the eaccess function.
27864 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
27865 # programs in the package would end up linked with that potentially-shared
27866 # library, inducing unnecessary run-time overhead.
27867 LIB_EACCESS=
27869 gl_saved_libs=$LIBS
27870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
27871 $as_echo_n "checking for library containing eaccess... " >&6; }
27872 if test "${ac_cv_search_eaccess+set}" = set; then :
27873 $as_echo_n "(cached) " >&6
27874 else
27875 ac_func_search_save_LIBS=$LIBS
27876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27877 /* end confdefs.h. */
27879 /* Override any GCC internal prototype to avoid an error.
27880 Use char because int might match the return type of a GCC
27881 builtin and then its argument prototype would still apply. */
27882 #ifdef __cplusplus
27883 extern "C"
27884 #endif
27885 char eaccess ();
27887 main ()
27889 return eaccess ();
27891 return 0;
27893 _ACEOF
27894 for ac_lib in '' gen; do
27895 if test -z "$ac_lib"; then
27896 ac_res="none required"
27897 else
27898 ac_res=-l$ac_lib
27899 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27901 if ac_fn_c_try_link "$LINENO"; then :
27902 ac_cv_search_eaccess=$ac_res
27904 rm -f core conftest.err conftest.$ac_objext \
27905 conftest$ac_exeext
27906 if test "${ac_cv_search_eaccess+set}" = set; then :
27907 break
27909 done
27910 if test "${ac_cv_search_eaccess+set}" = set; then :
27912 else
27913 ac_cv_search_eaccess=no
27915 rm conftest.$ac_ext
27916 LIBS=$ac_func_search_save_LIBS
27918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
27919 $as_echo "$ac_cv_search_eaccess" >&6; }
27920 ac_res=$ac_cv_search_eaccess
27921 if test "$ac_res" != no; then :
27922 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27923 test "$ac_cv_search_eaccess" = "none required" ||
27924 LIB_EACCESS=$ac_cv_search_eaccess
27927 for ac_func in eaccess
27928 do :
27929 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
27930 if test "x$ac_cv_func_eaccess" = x""yes; then :
27931 cat >>confdefs.h <<_ACEOF
27932 #define HAVE_EACCESS 1
27933 _ACEOF
27936 done
27938 LIBS=$gl_saved_libs
27946 GNULIB_EUIDACCESS=1
27952 gl_gnulib_enabled_euidaccess=true
27953 if test $HAVE_EUIDACCESS = 0; then
27954 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
27956 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
27957 if test $HAVE_EUIDACCESS = 0; then
27958 func_gl_gnulib_m4code_stat
27962 func_gl_gnulib_m4code_getdtablesize ()
27964 if ! $gl_gnulib_enabled_getdtablesize; then
27968 if test $ac_cv_func_getdtablesize != yes; then
27969 HAVE_GETDTABLESIZE=0
27972 if test $HAVE_GETDTABLESIZE = 0; then
27981 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
27990 GNULIB_GETDTABLESIZE=1
27996 gl_gnulib_enabled_getdtablesize=true
27999 func_gl_gnulib_m4code_getgroups ()
28001 if ! $gl_gnulib_enabled_getgroups; then
28007 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28008 if test "x$ac_cv_func_getgroups" = x""yes; then :
28013 # If we don't yet have getgroups, see if it's in -lbsd.
28014 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28015 ac_save_LIBS=$LIBS
28016 if test $ac_cv_func_getgroups = no; then
28017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28018 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28019 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28020 $as_echo_n "(cached) " >&6
28021 else
28022 ac_check_lib_save_LIBS=$LIBS
28023 LIBS="-lbsd $LIBS"
28024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28025 /* end confdefs.h. */
28027 /* Override any GCC internal prototype to avoid an error.
28028 Use char because int might match the return type of a GCC
28029 builtin and then its argument prototype would still apply. */
28030 #ifdef __cplusplus
28031 extern "C"
28032 #endif
28033 char getgroups ();
28035 main ()
28037 return getgroups ();
28039 return 0;
28041 _ACEOF
28042 if ac_fn_c_try_link "$LINENO"; then :
28043 ac_cv_lib_bsd_getgroups=yes
28044 else
28045 ac_cv_lib_bsd_getgroups=no
28047 rm -f core conftest.err conftest.$ac_objext \
28048 conftest$ac_exeext conftest.$ac_ext
28049 LIBS=$ac_check_lib_save_LIBS
28051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28052 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28053 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28054 GETGROUPS_LIB=-lbsd
28059 # Run the program to test the functionality of the system-supplied
28060 # getgroups function only if there is such a function.
28061 if test $ac_cv_func_getgroups = yes; then
28062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28063 $as_echo_n "checking for working getgroups... " >&6; }
28064 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28065 $as_echo_n "(cached) " >&6
28066 else
28067 if test "$cross_compiling" = yes; then :
28068 case "$host_os" in # ((
28069 # Guess yes on glibc systems.
28070 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28071 # If we don't know, assume the worst.
28072 *) ac_cv_func_getgroups_works="guessing no" ;;
28073 esac
28075 else
28076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28077 /* end confdefs.h. */
28078 $ac_includes_default
28080 main ()
28082 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28083 return getgroups (0, 0) == -1;
28085 return 0;
28088 _ACEOF
28089 if ac_fn_c_try_run "$LINENO"; then :
28090 ac_cv_func_getgroups_works=yes
28091 else
28092 ac_cv_func_getgroups_works=no
28094 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28095 conftest.$ac_objext conftest.beam conftest.$ac_ext
28100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28101 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28102 else
28103 ac_cv_func_getgroups_works=no
28105 case "$ac_cv_func_getgroups_works" in
28106 *yes)
28108 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28111 esac
28112 LIBS=$ac_save_LIBS
28114 if test $ac_cv_func_getgroups != yes; then
28115 HAVE_GETGROUPS=0
28116 else
28117 if test "$ac_cv_type_getgroups" != gid_t \
28118 || { case "$ac_cv_func_getgroups_works" in
28119 *yes) false;;
28120 *) true;;
28121 esac
28122 }; then
28123 REPLACE_GETGROUPS=1
28125 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
28127 else
28128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
28129 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
28130 if test "${gl_cv_func_getgroups_works+set}" = set; then :
28131 $as_echo_n "(cached) " >&6
28132 else
28133 if test "$cross_compiling" = yes; then :
28134 case "$host_os" in
28135 # Guess yes on glibc systems.
28136 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
28137 # If we don't know, assume the worst.
28138 *) gl_cv_func_getgroups_works="guessing no" ;;
28139 esac
28141 else
28142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28143 /* end confdefs.h. */
28144 $ac_includes_default
28146 main ()
28148 int size = getgroups (0, 0);
28149 gid_t *list = malloc (size * sizeof *list);
28150 return getgroups (-1, list) != -1;
28152 return 0;
28154 _ACEOF
28155 if ac_fn_c_try_run "$LINENO"; then :
28156 gl_cv_func_getgroups_works=yes
28157 else
28158 gl_cv_func_getgroups_works=no
28160 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28161 conftest.$ac_objext conftest.beam conftest.$ac_ext
28165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
28166 $as_echo "$gl_cv_func_getgroups_works" >&6; }
28167 case "$gl_cv_func_getgroups_works" in
28168 *yes) ;;
28169 *) REPLACE_GETGROUPS=1 ;;
28170 esac
28173 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
28175 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
28184 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
28192 GNULIB_GETGROUPS=1
28198 gl_gnulib_enabled_getgroups=true
28201 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
28203 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28206 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
28209 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
28211 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28217 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
28218 if test "x$ac_cv_func_group_member" = x""yes; then :
28220 else
28222 HAVE_GROUP_MEMBER=0
28227 if test $HAVE_GROUP_MEMBER = 0; then
28236 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
28247 GNULIB_GROUP_MEMBER=1
28253 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
28254 if test $HAVE_GROUP_MEMBER = 0; then
28255 func_gl_gnulib_m4code_getgroups
28257 if test $HAVE_GROUP_MEMBER = 0; then
28258 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
28262 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
28264 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28265 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
28268 func_gl_gnulib_m4code_pathmax ()
28270 if ! $gl_gnulib_enabled_pathmax; then
28274 gl_gnulib_enabled_pathmax=true
28277 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
28279 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28280 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
28283 func_gl_gnulib_m4code_secure_getenv ()
28285 if ! $gl_gnulib_enabled_secure_getenv; then
28291 if test $ac_cv_func_secure_getenv = no; then
28292 HAVE_SECURE_GETENV=0
28295 if test $HAVE_SECURE_GETENV = 0; then
28304 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
28307 for ac_func in __secure_getenv
28308 do :
28309 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
28310 if test "x$ac_cv_func___secure_getenv" = x""yes; then :
28311 cat >>confdefs.h <<_ACEOF
28312 #define HAVE___SECURE_GETENV 1
28313 _ACEOF
28316 done
28318 if test $ac_cv_func___secure_getenv = no; then
28319 for ac_func in issetugid
28320 do :
28321 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
28322 if test "x$ac_cv_func_issetugid" = x""yes; then :
28323 cat >>confdefs.h <<_ACEOF
28324 #define HAVE_ISSETUGID 1
28325 _ACEOF
28328 done
28338 GNULIB_SECURE_GETENV=1
28344 gl_gnulib_enabled_secure_getenv=true
28347 func_gl_gnulib_m4code_stat ()
28349 if ! $gl_gnulib_enabled_stat; then
28353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
28354 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
28355 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
28356 $as_echo_n "(cached) " >&6
28357 else
28358 if test "$cross_compiling" = yes; then :
28359 case $host_os in
28360 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
28361 *) gl_cv_func_stat_dir_slash="guessing yes";;
28362 esac
28363 else
28364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28365 /* end confdefs.h. */
28366 #include <sys/stat.h>
28369 main ()
28371 struct stat st; return stat (".", &st) != stat ("./", &st);
28373 return 0;
28375 _ACEOF
28376 if ac_fn_c_try_run "$LINENO"; then :
28377 gl_cv_func_stat_dir_slash=yes
28378 else
28379 gl_cv_func_stat_dir_slash=no
28381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28382 conftest.$ac_objext conftest.beam conftest.$ac_ext
28386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
28387 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
28388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28389 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28390 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
28391 $as_echo_n "(cached) " >&6
28392 else
28393 touch conftest.tmp
28394 # Assume that if we have lstat, we can also check symlinks.
28395 if test $ac_cv_func_lstat = yes; then
28396 ln -s conftest.tmp conftest.lnk
28398 if test "$cross_compiling" = yes; then :
28399 case "$host_os" in
28400 # Guess yes on glibc systems.
28401 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28402 # If we don't know, assume the worst.
28403 *) gl_cv_func_stat_file_slash="guessing no" ;;
28404 esac
28406 else
28407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28408 /* end confdefs.h. */
28409 #include <sys/stat.h>
28412 main ()
28414 int result = 0;
28415 struct stat st;
28416 if (!stat ("conftest.tmp/", &st))
28417 result |= 1;
28418 #if HAVE_LSTAT
28419 if (!stat ("conftest.lnk/", &st))
28420 result |= 2;
28421 #endif
28422 return result;
28425 return 0;
28427 _ACEOF
28428 if ac_fn_c_try_run "$LINENO"; then :
28429 gl_cv_func_stat_file_slash=yes
28430 else
28431 gl_cv_func_stat_file_slash=no
28433 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28434 conftest.$ac_objext conftest.beam conftest.$ac_ext
28437 rm -f conftest.tmp conftest.lnk
28439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28440 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28441 case $gl_cv_func_stat_dir_slash in
28442 *no) REPLACE_STAT=1
28444 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28446 esac
28447 case $gl_cv_func_stat_file_slash in
28448 *no) REPLACE_STAT=1
28450 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28452 esac
28454 if test $REPLACE_STAT = 1; then
28463 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28472 GNULIB_STAT=1
28478 gl_gnulib_enabled_stat=true
28479 if test $REPLACE_STAT = 1; then
28480 func_gl_gnulib_m4code_dosname
28482 if test $REPLACE_STAT = 1; then
28483 func_gl_gnulib_m4code_pathmax
28487 func_gl_gnulib_m4code_strtoll ()
28489 if ! $gl_gnulib_enabled_strtoll; then
28493 if test "$ac_cv_type_long_long_int" = yes; then
28494 for ac_func in strtoll
28495 do :
28496 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28497 if test "x$ac_cv_func_strtoll" = x""yes; then :
28498 cat >>confdefs.h <<_ACEOF
28499 #define HAVE_STRTOLL 1
28500 _ACEOF
28503 done
28505 if test $ac_cv_func_strtoll = no; then
28506 HAVE_STRTOLL=0
28510 if test $HAVE_STRTOLL = 0; then
28519 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28530 GNULIB_STRTOLL=1
28536 gl_gnulib_enabled_strtoll=true
28539 func_gl_gnulib_m4code_strtoull ()
28541 if ! $gl_gnulib_enabled_strtoull; then
28545 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28546 for ac_func in strtoull
28547 do :
28548 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
28549 if test "x$ac_cv_func_strtoull" = x""yes; then :
28550 cat >>confdefs.h <<_ACEOF
28551 #define HAVE_STRTOULL 1
28552 _ACEOF
28555 done
28557 if test $ac_cv_func_strtoull = no; then
28558 HAVE_STRTOULL=0
28562 if test $HAVE_STRTOULL = 0; then
28571 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
28582 GNULIB_STRTOULL=1
28588 gl_gnulib_enabled_strtoull=true
28591 func_gl_gnulib_m4code_tempname ()
28593 if ! $gl_gnulib_enabled_tempname; then
28599 gl_gnulib_enabled_tempname=true
28600 func_gl_gnulib_m4code_secure_getenv
28603 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
28605 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28606 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
28609 if test $HAVE_FACCESSAT = 0; then
28610 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28612 if test $HAVE_FACCESSAT = 0; then
28613 func_gl_gnulib_m4code_dosname
28615 if test $HAVE_FACCESSAT = 0; then
28616 func_gl_gnulib_m4code_euidaccess
28618 if test $HAVE_FACCESSAT = 0; then
28619 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28621 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
28622 func_gl_gnulib_m4code_getdtablesize
28624 if test $HAVE_FDOPENDIR = 0; then
28625 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28627 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28628 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28630 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28631 func_gl_gnulib_m4code_dosname
28633 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28634 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28636 if test $REPLACE_GETOPT = 1; then
28637 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
28639 if test $REPLACE_LSTAT = 1; then
28640 func_gl_gnulib_m4code_dosname
28642 if test $REPLACE_LSTAT = 1; then
28643 func_gl_gnulib_m4code_stat
28645 if test $HAVE_MKOSTEMP = 0; then
28646 func_gl_gnulib_m4code_tempname
28648 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
28649 func_gl_gnulib_m4code_stat
28651 if test $HAVE_READLINKAT = 0; then
28652 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28654 if test $HAVE_READLINKAT = 0; then
28655 func_gl_gnulib_m4code_dosname
28657 if test $HAVE_READLINKAT = 0; then
28658 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28660 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
28661 func_gl_gnulib_m4code_strtoll
28663 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
28664 func_gl_gnulib_m4code_strtoull
28667 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28668 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
28669 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
28670 else
28671 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
28672 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
28675 if $gl_gnulib_enabled_dosname; then
28676 gl_GNULIB_ENABLED_dosname_TRUE=
28677 gl_GNULIB_ENABLED_dosname_FALSE='#'
28678 else
28679 gl_GNULIB_ENABLED_dosname_TRUE='#'
28680 gl_GNULIB_ENABLED_dosname_FALSE=
28683 if $gl_gnulib_enabled_euidaccess; then
28684 gl_GNULIB_ENABLED_euidaccess_TRUE=
28685 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
28686 else
28687 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
28688 gl_GNULIB_ENABLED_euidaccess_FALSE=
28691 if $gl_gnulib_enabled_getdtablesize; then
28692 gl_GNULIB_ENABLED_getdtablesize_TRUE=
28693 gl_GNULIB_ENABLED_getdtablesize_FALSE='#'
28694 else
28695 gl_GNULIB_ENABLED_getdtablesize_TRUE='#'
28696 gl_GNULIB_ENABLED_getdtablesize_FALSE=
28699 if $gl_gnulib_enabled_getgroups; then
28700 gl_GNULIB_ENABLED_getgroups_TRUE=
28701 gl_GNULIB_ENABLED_getgroups_FALSE='#'
28702 else
28703 gl_GNULIB_ENABLED_getgroups_TRUE='#'
28704 gl_GNULIB_ENABLED_getgroups_FALSE=
28707 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28708 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
28709 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
28710 else
28711 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
28712 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
28715 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28716 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
28717 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
28718 else
28719 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
28720 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
28723 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28724 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
28725 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
28726 else
28727 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
28728 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
28731 if $gl_gnulib_enabled_pathmax; then
28732 gl_GNULIB_ENABLED_pathmax_TRUE=
28733 gl_GNULIB_ENABLED_pathmax_FALSE='#'
28734 else
28735 gl_GNULIB_ENABLED_pathmax_TRUE='#'
28736 gl_GNULIB_ENABLED_pathmax_FALSE=
28739 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28740 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
28741 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
28742 else
28743 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
28744 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
28747 if $gl_gnulib_enabled_secure_getenv; then
28748 gl_GNULIB_ENABLED_secure_getenv_TRUE=
28749 gl_GNULIB_ENABLED_secure_getenv_FALSE='#'
28750 else
28751 gl_GNULIB_ENABLED_secure_getenv_TRUE='#'
28752 gl_GNULIB_ENABLED_secure_getenv_FALSE=
28755 if $gl_gnulib_enabled_stat; then
28756 gl_GNULIB_ENABLED_stat_TRUE=
28757 gl_GNULIB_ENABLED_stat_FALSE='#'
28758 else
28759 gl_GNULIB_ENABLED_stat_TRUE='#'
28760 gl_GNULIB_ENABLED_stat_FALSE=
28763 if $gl_gnulib_enabled_strtoll; then
28764 gl_GNULIB_ENABLED_strtoll_TRUE=
28765 gl_GNULIB_ENABLED_strtoll_FALSE='#'
28766 else
28767 gl_GNULIB_ENABLED_strtoll_TRUE='#'
28768 gl_GNULIB_ENABLED_strtoll_FALSE=
28771 if $gl_gnulib_enabled_strtoull; then
28772 gl_GNULIB_ENABLED_strtoull_TRUE=
28773 gl_GNULIB_ENABLED_strtoull_FALSE='#'
28774 else
28775 gl_GNULIB_ENABLED_strtoull_TRUE='#'
28776 gl_GNULIB_ENABLED_strtoull_FALSE=
28779 if $gl_gnulib_enabled_tempname; then
28780 gl_GNULIB_ENABLED_tempname_TRUE=
28781 gl_GNULIB_ENABLED_tempname_FALSE='#'
28782 else
28783 gl_GNULIB_ENABLED_tempname_TRUE='#'
28784 gl_GNULIB_ENABLED_tempname_FALSE=
28787 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28788 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
28789 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
28790 else
28791 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
28792 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
28795 # End of code from modules
28805 gltests_libdeps=
28806 gltests_ltlibdeps=
28816 gl_source_base='tests'
28817 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
28819 gl_module_indicator_condition=$gltests_WITNESS
28830 LIBGNU_LIBDEPS="$gl_libdeps"
28832 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
28835 CFLAGS=$SAVE_CFLAGS
28836 LIBS=$SAVE_LIBS
28838 if test "${opsys}" = "mingw32"; then
28839 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
28840 # Remove unneeded switches from the value of CC that goes to Makefiles
28841 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
28844 case "$opsys" in
28845 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
28847 darwin)
28848 ## The -headerpad option tells ld (see man page) to leave room at the
28849 ## end of the header for adding load commands. Needed for dumping.
28850 ## 0x690 is the total size of 30 segment load commands (at 56
28851 ## each); under Cocoa 31 commands are required.
28852 if test "$HAVE_NS" = "yes"; then
28853 libs_nsgui="-framework AppKit"
28854 if test "$NS_IMPL_COCOA" = "yes"; then
28855 libs_nsgui="$libs_nsgui -framework IOKit"
28857 headerpad_extra=6C8
28858 else
28859 libs_nsgui=
28860 headerpad_extra=690
28862 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
28864 ## This is here because src/Makefile.in did some extra fiddling around
28865 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
28866 ## LD_SWITCH_SYSTEM_TEMACS instead,
28867 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
28868 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
28871 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
28872 ## find X at run-time.
28873 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
28874 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
28875 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
28876 ## had different values in configure (in ac_link) and src/Makefile.in.
28877 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
28878 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
28880 mingw32)
28881 ## MinGW64 does not prepend an underscore to symbols, so we must
28882 ## pass a different -entry switch to linker. FIXME: It is better
28883 ## to make the entry points the same by changing unexw32.c.
28884 case "$canonical" in
28885 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
28886 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
28887 esac
28890 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
28892 *) LD_SWITCH_SYSTEM_TEMACS= ;;
28893 esac
28895 if test x$ac_enable_profiling != x ; then
28896 case $opsys in
28897 *freebsd | gnu-linux) ;;
28898 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
28899 esac
28904 ## MinGW-specific post-link processing of temacs.
28905 TEMACS_POST_LINK=":"
28906 ADDSECTION=
28907 EMACS_HEAPSIZE=
28908 if test "${opsys}" = "mingw32"; then
28909 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
28910 ADDSECTION="../nt/addsection\$(EXEEXT)"
28911 ## Preload heap size of temacs.exe in MB.
28912 case "$canonical" in
28913 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
28914 *) EMACS_HEAPSIZE=27 ;;
28915 esac
28922 ## Common for all window systems
28923 if test "$window_system" != "none"; then
28925 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
28927 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
28934 #### Report on what we decided to do.
28935 #### Report GTK as a toolkit, even if it doesn't use Xt.
28936 #### It makes printing result more understandable as using GTK sets
28937 #### toolkit_scroll_bars to yes by default.
28938 if test "${HAVE_GTK}" = "yes"; then
28939 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
28942 if test $USE_ACL -ne 0; then
28943 acl_summary="yes $LIB_ACL"
28944 else
28945 acl_summary=no
28948 echo "
28949 Configured for \`${canonical}'.
28951 Where should the build process find the source code? ${srcdir}
28952 What compiler should emacs be built with? ${CC} ${CFLAGS}
28953 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
28954 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
28955 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
28956 What window system should Emacs use? ${window_system}
28957 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
28959 if test -n "${x_includes}"; then
28960 echo " Where do we find X Windows header files? ${x_includes}"
28961 else
28962 echo " Where do we find X Windows header files? Standard dirs"
28964 if test -n "${x_libraries}"; then
28965 echo " Where do we find X Windows libraries? ${x_libraries}"
28966 else
28967 echo " Where do we find X Windows libraries? Standard dirs"
28970 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
28971 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
28972 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
28973 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
28974 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
28975 echo " Does Emacs use -lpng? ${HAVE_PNG}"
28976 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
28977 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
28979 echo " Does Emacs support sound? ${HAVE_SOUND}"
28981 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
28982 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
28983 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
28984 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
28985 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
28986 echo " Does Emacs use access control lists? ${acl_summary}"
28987 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
28988 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
28989 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
28991 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
28992 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
28993 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
28994 echo " Does Emacs use -lxft? ${HAVE_XFT}"
28995 echo " Does Emacs directly use zlib? ${HAVE_ZLIB}"
28997 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
28998 echo
29000 if test -n "${EMACSDATA}"; then
29001 echo " Environment variable EMACSDATA set to: $EMACSDATA"
29003 if test -n "${EMACSDOC}"; then
29004 echo " Environment variable EMACSDOC set to: $EMACSDOC"
29007 echo
29009 if test "$HAVE_NS" = "yes"; then
29010 echo
29011 echo "You must run \"${MAKE-make} install\" in order to test the built application.
29012 The installed application will go to nextstep/Emacs.app and can be
29013 run or moved from there."
29014 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
29015 echo "The application will be fully self-contained."
29016 else
29017 echo "The lisp resources for the application will be installed under ${prefix}.
29018 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
29019 to run if these resources are not installed."
29021 echo
29024 if test "${opsys}" = "cygwin"; then
29025 case `uname -r` in
29026 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
29027 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
29028 echo
29030 esac
29033 # Remove any trailing slashes in these variables.
29034 test "${prefix}" != NONE &&
29035 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
29036 test "${exec_prefix}" != NONE &&
29037 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
29039 if test "$HAVE_NS" = "yes"; then
29040 if test "$NS_IMPL_GNUSTEP" = yes; then
29041 ac_config_files="$ac_config_files nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in"
29043 else
29044 ac_config_files="$ac_config_files nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in"
29049 SUBDIR_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 nextstep/Makefile nt/Makefile"
29051 ac_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 nextstep/Makefile nt/Makefile"
29054 opt_makefile=test/automated/Makefile
29056 if test -f "$srcdir/$opt_makefile.in"; then
29057 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29058 ac_config_files="$ac_config_files test/automated/Makefile"
29063 opt_makefile=admin/unidata/Makefile
29065 if test -f "$srcdir/$opt_makefile.in"; then
29066 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29067 ac_config_files="$ac_config_files admin/unidata/Makefile"
29072 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
29076 ac_config_commands="$ac_config_commands src/epaths.h"
29079 ac_config_commands="$ac_config_commands src/.gdbinit"
29082 cat >confcache <<\_ACEOF
29083 # This file is a shell script that caches the results of configure
29084 # tests run on this system so they can be shared between configure
29085 # scripts and configure runs, see configure's option --config-cache.
29086 # It is not useful on other systems. If it contains results you don't
29087 # want to keep, you may remove or edit it.
29089 # config.status only pays attention to the cache file if you give it
29090 # the --recheck option to rerun configure.
29092 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29093 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29094 # following values.
29096 _ACEOF
29098 # The following way of writing the cache mishandles newlines in values,
29099 # but we know of no workaround that is simple, portable, and efficient.
29100 # So, we kill variables containing newlines.
29101 # Ultrix sh set writes to stderr and can't be redirected directly,
29102 # and sets the high bit in the cache file unless we assign to the vars.
29104 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29105 eval ac_val=\$$ac_var
29106 case $ac_val in #(
29107 *${as_nl}*)
29108 case $ac_var in #(
29109 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
29110 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29111 esac
29112 case $ac_var in #(
29113 _ | IFS | as_nl) ;; #(
29114 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29115 *) { eval $ac_var=; unset $ac_var;} ;;
29116 esac ;;
29117 esac
29118 done
29120 (set) 2>&1 |
29121 case $as_nl`(ac_space=' '; set) 2>&1` in #(
29122 *${as_nl}ac_space=\ *)
29123 # `set' does not quote correctly, so add quotes: double-quote
29124 # substitution turns \\\\ into \\, and sed turns \\ into \.
29125 sed -n \
29126 "s/'/'\\\\''/g;
29127 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29128 ;; #(
29130 # `set' quotes correctly as required by POSIX, so do not add quotes.
29131 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29133 esac |
29134 sort
29136 sed '
29137 /^ac_cv_env_/b end
29138 t clear
29139 :clear
29140 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29141 t end
29142 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29143 :end' >>confcache
29144 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29145 if test -w "$cache_file"; then
29146 test "x$cache_file" != "x/dev/null" &&
29147 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
29148 $as_echo "$as_me: updating cache $cache_file" >&6;}
29149 cat confcache >$cache_file
29150 else
29151 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
29152 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29155 rm -f confcache
29157 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29158 # Let make expand exec_prefix.
29159 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29161 DEFS=-DHAVE_CONFIG_H
29163 ac_libobjs=
29164 ac_ltlibobjs=
29165 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29166 # 1. Remove the extension, and $U if already installed.
29167 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29168 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29169 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
29170 # will be set to the directory where LIBOBJS objects are built.
29171 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29172 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
29173 done
29174 LIBOBJS=$ac_libobjs
29176 LTLIBOBJS=$ac_ltlibobjs
29179 if test -n "$EXEEXT"; then
29180 am__EXEEXT_TRUE=
29181 am__EXEEXT_FALSE='#'
29182 else
29183 am__EXEEXT_TRUE='#'
29184 am__EXEEXT_FALSE=
29187 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
29188 as_fn_error "conditional \"AMDEP\" was never defined.
29189 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29191 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
29192 as_fn_error "conditional \"am__fastdepCC\" was never defined.
29193 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29195 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
29196 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
29197 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29199 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
29200 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
29201 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29203 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
29204 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
29205 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29208 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
29209 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
29210 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29212 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
29213 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
29214 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29216 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
29217 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
29218 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29220 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
29221 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
29222 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29224 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
29225 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
29226 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29228 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
29229 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
29230 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29232 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
29233 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
29234 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29236 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
29237 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
29238 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29240 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
29241 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
29242 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29244 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
29245 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
29246 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29248 if test -z "${gl_GNULIB_ENABLED_getdtablesize_TRUE}" && test -z "${gl_GNULIB_ENABLED_getdtablesize_FALSE}"; then
29249 as_fn_error "conditional \"gl_GNULIB_ENABLED_getdtablesize\" was never defined.
29250 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29252 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
29253 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
29254 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29256 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
29257 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
29258 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29260 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
29261 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
29262 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29264 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
29265 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
29266 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29268 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
29269 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
29270 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29272 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
29273 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
29274 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29276 if test -z "${gl_GNULIB_ENABLED_secure_getenv_TRUE}" && test -z "${gl_GNULIB_ENABLED_secure_getenv_FALSE}"; then
29277 as_fn_error "conditional \"gl_GNULIB_ENABLED_secure_getenv\" was never defined.
29278 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29280 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
29281 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
29282 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29284 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
29285 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
29286 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29288 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
29289 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
29290 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29292 if test -z "${gl_GNULIB_ENABLED_tempname_TRUE}" && test -z "${gl_GNULIB_ENABLED_tempname_FALSE}"; then
29293 as_fn_error "conditional \"gl_GNULIB_ENABLED_tempname\" was never defined.
29294 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29296 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
29297 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
29298 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29301 gl_libobjs=
29302 gl_ltlibobjs=
29303 if test -n "$gl_LIBOBJS"; then
29304 # Remove the extension.
29305 sed_drop_objext='s/\.o$//;s/\.obj$//'
29306 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29307 gl_libobjs="$gl_libobjs $i.$ac_objext"
29308 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
29309 done
29311 gl_LIBOBJS=$gl_libobjs
29313 gl_LTLIBOBJS=$gl_ltlibobjs
29317 gltests_libobjs=
29318 gltests_ltlibobjs=
29319 if test -n "$gltests_LIBOBJS"; then
29320 # Remove the extension.
29321 sed_drop_objext='s/\.o$//;s/\.obj$//'
29322 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29323 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
29324 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
29325 done
29327 gltests_LIBOBJS=$gltests_libobjs
29329 gltests_LTLIBOBJS=$gltests_ltlibobjs
29333 : ${CONFIG_STATUS=./config.status}
29334 ac_write_fail=0
29335 ac_clean_files_save=$ac_clean_files
29336 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29337 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29338 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29339 as_write_fail=0
29340 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29341 #! $SHELL
29342 # Generated by $as_me.
29343 # Run this file to recreate the current configuration.
29344 # Compiler output produced by configure, useful for debugging
29345 # configure, is in config.log if it exists.
29347 debug=false
29348 ac_cs_recheck=false
29349 ac_cs_silent=false
29351 SHELL=\${CONFIG_SHELL-$SHELL}
29352 export SHELL
29353 _ASEOF
29354 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29355 ## -------------------- ##
29356 ## M4sh Initialization. ##
29357 ## -------------------- ##
29359 # Be more Bourne compatible
29360 DUALCASE=1; export DUALCASE # for MKS sh
29361 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29362 emulate sh
29363 NULLCMD=:
29364 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29365 # is contrary to our usage. Disable this feature.
29366 alias -g '${1+"$@"}'='"$@"'
29367 setopt NO_GLOB_SUBST
29368 else
29369 case `(set -o) 2>/dev/null` in #(
29370 *posix*) :
29371 set -o posix ;; #(
29372 *) :
29374 esac
29378 as_nl='
29380 export as_nl
29381 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29382 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29383 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29384 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29385 # Prefer a ksh shell builtin over an external printf program on Solaris,
29386 # but without wasting forks for bash or zsh.
29387 if test -z "$BASH_VERSION$ZSH_VERSION" \
29388 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29389 as_echo='print -r --'
29390 as_echo_n='print -rn --'
29391 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29392 as_echo='printf %s\n'
29393 as_echo_n='printf %s'
29394 else
29395 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29396 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29397 as_echo_n='/usr/ucb/echo -n'
29398 else
29399 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29400 as_echo_n_body='eval
29401 arg=$1;
29402 case $arg in #(
29403 *"$as_nl"*)
29404 expr "X$arg" : "X\\(.*\\)$as_nl";
29405 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29406 esac;
29407 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29409 export as_echo_n_body
29410 as_echo_n='sh -c $as_echo_n_body as_echo'
29412 export as_echo_body
29413 as_echo='sh -c $as_echo_body as_echo'
29416 # The user is always right.
29417 if test "${PATH_SEPARATOR+set}" != set; then
29418 PATH_SEPARATOR=:
29419 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29420 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29421 PATH_SEPARATOR=';'
29426 # IFS
29427 # We need space, tab and new line, in precisely that order. Quoting is
29428 # there to prevent editors from complaining about space-tab.
29429 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29430 # splitting by setting IFS to empty value.)
29431 IFS=" "" $as_nl"
29433 # Find who we are. Look in the path if we contain no directory separator.
29434 case $0 in #((
29435 *[\\/]* ) as_myself=$0 ;;
29436 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29437 for as_dir in $PATH
29439 IFS=$as_save_IFS
29440 test -z "$as_dir" && as_dir=.
29441 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29442 done
29443 IFS=$as_save_IFS
29446 esac
29447 # We did not find ourselves, most probably we were run as `sh COMMAND'
29448 # in which case we are not to be found in the path.
29449 if test "x$as_myself" = x; then
29450 as_myself=$0
29452 if test ! -f "$as_myself"; then
29453 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29454 exit 1
29457 # Unset variables that we do not need and which cause bugs (e.g. in
29458 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29459 # suppresses any "Segmentation fault" message there. '((' could
29460 # trigger a bug in pdksh 5.2.14.
29461 for as_var in BASH_ENV ENV MAIL MAILPATH
29462 do eval test x\${$as_var+set} = xset \
29463 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29464 done
29465 PS1='$ '
29466 PS2='> '
29467 PS4='+ '
29469 # NLS nuisances.
29470 LC_ALL=C
29471 export LC_ALL
29472 LANGUAGE=C
29473 export LANGUAGE
29475 # CDPATH.
29476 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29479 # as_fn_error ERROR [LINENO LOG_FD]
29480 # ---------------------------------
29481 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29482 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29483 # script with status $?, using 1 if that was 0.
29484 as_fn_error ()
29486 as_status=$?; test $as_status -eq 0 && as_status=1
29487 if test "$3"; then
29488 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29489 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29491 $as_echo "$as_me: error: $1" >&2
29492 as_fn_exit $as_status
29493 } # as_fn_error
29496 # as_fn_set_status STATUS
29497 # -----------------------
29498 # Set $? to STATUS, without forking.
29499 as_fn_set_status ()
29501 return $1
29502 } # as_fn_set_status
29504 # as_fn_exit STATUS
29505 # -----------------
29506 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29507 as_fn_exit ()
29509 set +e
29510 as_fn_set_status $1
29511 exit $1
29512 } # as_fn_exit
29514 # as_fn_unset VAR
29515 # ---------------
29516 # Portably unset VAR.
29517 as_fn_unset ()
29519 { eval $1=; unset $1;}
29521 as_unset=as_fn_unset
29522 # as_fn_append VAR VALUE
29523 # ----------------------
29524 # Append the text in VALUE to the end of the definition contained in VAR. Take
29525 # advantage of any shell optimizations that allow amortized linear growth over
29526 # repeated appends, instead of the typical quadratic growth present in naive
29527 # implementations.
29528 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29529 eval 'as_fn_append ()
29531 eval $1+=\$2
29533 else
29534 as_fn_append ()
29536 eval $1=\$$1\$2
29538 fi # as_fn_append
29540 # as_fn_arith ARG...
29541 # ------------------
29542 # Perform arithmetic evaluation on the ARGs, and store the result in the
29543 # global $as_val. Take advantage of shells that can avoid forks. The arguments
29544 # must be portable across $(()) and expr.
29545 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29546 eval 'as_fn_arith ()
29548 as_val=$(( $* ))
29550 else
29551 as_fn_arith ()
29553 as_val=`expr "$@" || test $? -eq 1`
29555 fi # as_fn_arith
29558 if expr a : '\(a\)' >/dev/null 2>&1 &&
29559 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29560 as_expr=expr
29561 else
29562 as_expr=false
29565 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29566 as_basename=basename
29567 else
29568 as_basename=false
29571 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29572 as_dirname=dirname
29573 else
29574 as_dirname=false
29577 as_me=`$as_basename -- "$0" ||
29578 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29579 X"$0" : 'X\(//\)$' \| \
29580 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29581 $as_echo X/"$0" |
29582 sed '/^.*\/\([^/][^/]*\)\/*$/{
29583 s//\1/
29586 /^X\/\(\/\/\)$/{
29587 s//\1/
29590 /^X\/\(\/\).*/{
29591 s//\1/
29594 s/.*/./; q'`
29596 # Avoid depending upon Character Ranges.
29597 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29598 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29599 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29600 as_cr_digits='0123456789'
29601 as_cr_alnum=$as_cr_Letters$as_cr_digits
29603 ECHO_C= ECHO_N= ECHO_T=
29604 case `echo -n x` in #(((((
29605 -n*)
29606 case `echo 'xy\c'` in
29607 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29608 xy) ECHO_C='\c';;
29609 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29610 ECHO_T=' ';;
29611 esac;;
29613 ECHO_N='-n';;
29614 esac
29616 rm -f conf$$ conf$$.exe conf$$.file
29617 if test -d conf$$.dir; then
29618 rm -f conf$$.dir/conf$$.file
29619 else
29620 rm -f conf$$.dir
29621 mkdir conf$$.dir 2>/dev/null
29623 if (echo >conf$$.file) 2>/dev/null; then
29624 if ln -s conf$$.file conf$$ 2>/dev/null; then
29625 as_ln_s='ln -s'
29626 # ... but there are two gotchas:
29627 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29628 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29629 # In both cases, we have to default to `cp -p'.
29630 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29631 as_ln_s='cp -p'
29632 elif ln conf$$.file conf$$ 2>/dev/null; then
29633 as_ln_s=ln
29634 else
29635 as_ln_s='cp -p'
29637 else
29638 as_ln_s='cp -p'
29640 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29641 rmdir conf$$.dir 2>/dev/null
29644 # as_fn_mkdir_p
29645 # -------------
29646 # Create "$as_dir" as a directory, including parents if necessary.
29647 as_fn_mkdir_p ()
29650 case $as_dir in #(
29651 -*) as_dir=./$as_dir;;
29652 esac
29653 test -d "$as_dir" || eval $as_mkdir_p || {
29654 as_dirs=
29655 while :; do
29656 case $as_dir in #(
29657 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29658 *) as_qdir=$as_dir;;
29659 esac
29660 as_dirs="'$as_qdir' $as_dirs"
29661 as_dir=`$as_dirname -- "$as_dir" ||
29662 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29663 X"$as_dir" : 'X\(//\)[^/]' \| \
29664 X"$as_dir" : 'X\(//\)$' \| \
29665 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29666 $as_echo X"$as_dir" |
29667 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29668 s//\1/
29671 /^X\(\/\/\)[^/].*/{
29672 s//\1/
29675 /^X\(\/\/\)$/{
29676 s//\1/
29679 /^X\(\/\).*/{
29680 s//\1/
29683 s/.*/./; q'`
29684 test -d "$as_dir" && break
29685 done
29686 test -z "$as_dirs" || eval "mkdir $as_dirs"
29687 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
29690 } # as_fn_mkdir_p
29691 if mkdir -p . 2>/dev/null; then
29692 as_mkdir_p='mkdir -p "$as_dir"'
29693 else
29694 test -d ./-p && rmdir ./-p
29695 as_mkdir_p=false
29698 if test -x / >/dev/null 2>&1; then
29699 as_test_x='test -x'
29700 else
29701 if ls -dL / >/dev/null 2>&1; then
29702 as_ls_L_option=L
29703 else
29704 as_ls_L_option=
29706 as_test_x='
29707 eval sh -c '\''
29708 if test -d "$1"; then
29709 test -d "$1/.";
29710 else
29711 case $1 in #(
29712 -*)set "./$1";;
29713 esac;
29714 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
29715 ???[sx]*):;;*)false;;esac;fi
29716 '\'' sh
29719 as_executable_p=$as_test_x
29721 # Sed expression to map a string onto a valid CPP name.
29722 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29724 # Sed expression to map a string onto a valid variable name.
29725 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29728 exec 6>&1
29729 ## ----------------------------------- ##
29730 ## Main body of $CONFIG_STATUS script. ##
29731 ## ----------------------------------- ##
29732 _ASEOF
29733 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
29735 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29736 # Save the log message, to keep $0 and so on meaningful, and to
29737 # report actual input values of CONFIG_FILES etc. instead of their
29738 # values after options handling.
29739 ac_log="
29740 This file was extended by emacs $as_me 24.3.50, which was
29741 generated by GNU Autoconf 2.65. Invocation command line was
29743 CONFIG_FILES = $CONFIG_FILES
29744 CONFIG_HEADERS = $CONFIG_HEADERS
29745 CONFIG_LINKS = $CONFIG_LINKS
29746 CONFIG_COMMANDS = $CONFIG_COMMANDS
29747 $ $0 $@
29749 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29752 _ACEOF
29754 case $ac_config_files in *"
29755 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29756 esac
29758 case $ac_config_headers in *"
29759 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29760 esac
29763 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29764 # Files that config.status was made for.
29765 config_files="$ac_config_files"
29766 config_headers="$ac_config_headers"
29767 config_commands="$ac_config_commands"
29769 _ACEOF
29771 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29772 ac_cs_usage="\
29773 \`$as_me' instantiates files and other configuration actions
29774 from templates according to the current configuration. Unless the files
29775 and actions are specified as TAGs, all are instantiated by default.
29777 Usage: $0 [OPTION]... [TAG]...
29779 -h, --help print this help, then exit
29780 -V, --version print version number and configuration settings, then exit
29781 --config print configuration, then exit
29782 -q, --quiet, --silent
29783 do not print progress messages
29784 -d, --debug don't remove temporary files
29785 --recheck update $as_me by reconfiguring in the same conditions
29786 --file=FILE[:TEMPLATE]
29787 instantiate the configuration file FILE
29788 --header=FILE[:TEMPLATE]
29789 instantiate the configuration header FILE
29791 Configuration files:
29792 $config_files
29794 Configuration headers:
29795 $config_headers
29797 Configuration commands:
29798 $config_commands
29800 Report bugs to the package provider."
29802 _ACEOF
29803 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29804 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
29805 ac_cs_version="\\
29806 emacs config.status 24.3.50
29807 configured by $0, generated by GNU Autoconf 2.65,
29808 with options \\"\$ac_cs_config\\"
29810 Copyright (C) 2009 Free Software Foundation, Inc.
29811 This config.status script is free software; the Free Software Foundation
29812 gives unlimited permission to copy, distribute and modify it."
29814 ac_pwd='$ac_pwd'
29815 srcdir='$srcdir'
29816 INSTALL='$INSTALL'
29817 MKDIR_P='$MKDIR_P'
29818 AWK='$AWK'
29819 test -n "\$AWK" || AWK=awk
29820 _ACEOF
29822 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29823 # The default lists apply if the user does not specify any file.
29824 ac_need_defaults=:
29825 while test $# != 0
29827 case $1 in
29828 --*=*)
29829 ac_option=`expr "X$1" : 'X\([^=]*\)='`
29830 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29831 ac_shift=:
29834 ac_option=$1
29835 ac_optarg=$2
29836 ac_shift=shift
29838 esac
29840 case $ac_option in
29841 # Handling of the options.
29842 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29843 ac_cs_recheck=: ;;
29844 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29845 $as_echo "$ac_cs_version"; exit ;;
29846 --config | --confi | --conf | --con | --co | --c )
29847 $as_echo "$ac_cs_config"; exit ;;
29848 --debug | --debu | --deb | --de | --d | -d )
29849 debug=: ;;
29850 --file | --fil | --fi | --f )
29851 $ac_shift
29852 case $ac_optarg in
29853 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29854 esac
29855 as_fn_append CONFIG_FILES " '$ac_optarg'"
29856 ac_need_defaults=false;;
29857 --header | --heade | --head | --hea )
29858 $ac_shift
29859 case $ac_optarg in
29860 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29861 esac
29862 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
29863 ac_need_defaults=false;;
29864 --he | --h)
29865 # Conflict between --help and --header
29866 as_fn_error "ambiguous option: \`$1'
29867 Try \`$0 --help' for more information.";;
29868 --help | --hel | -h )
29869 $as_echo "$ac_cs_usage"; exit ;;
29870 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29871 | -silent | --silent | --silen | --sile | --sil | --si | --s)
29872 ac_cs_silent=: ;;
29874 # This is an error.
29875 -*) as_fn_error "unrecognized option: \`$1'
29876 Try \`$0 --help' for more information." ;;
29878 *) as_fn_append ac_config_targets " $1"
29879 ac_need_defaults=false ;;
29881 esac
29882 shift
29883 done
29885 ac_configure_extra_args=
29887 if $ac_cs_silent; then
29888 exec 6>/dev/null
29889 ac_configure_extra_args="$ac_configure_extra_args --silent"
29892 _ACEOF
29893 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29894 if \$ac_cs_recheck; then
29895 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29896 shift
29897 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29898 CONFIG_SHELL='$SHELL'
29899 export CONFIG_SHELL
29900 exec "\$@"
29903 _ACEOF
29904 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29905 exec 5>>config.log
29907 echo
29908 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29909 ## Running $as_me. ##
29910 _ASBOX
29911 $as_echo "$ac_log"
29912 } >&5
29914 _ACEOF
29915 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29917 # INIT-COMMANDS
29919 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
29920 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
29922 _ACEOF
29924 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29926 # Handling of arguments.
29927 for ac_config_target in $ac_config_targets
29929 case $ac_config_target in
29930 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
29931 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
29932 "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in" ;;
29933 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
29934 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
29935 "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in" ;;
29936 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
29937 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
29938 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
29939 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
29940 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
29941 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
29942 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
29943 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
29944 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
29945 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
29946 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
29947 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
29948 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
29949 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
29950 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
29951 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
29952 "src/epaths.h") CONFIG_COMMANDS="$CONFIG_COMMANDS src/epaths.h" ;;
29953 "src/.gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS src/.gdbinit" ;;
29955 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
29956 esac
29957 done
29960 # If the user did not use the arguments to specify the items to instantiate,
29961 # then the envvar interface is used. Set only those that are not.
29962 # We use the long form for the default assignment because of an extremely
29963 # bizarre bug on SunOS 4.1.3.
29964 if $ac_need_defaults; then
29965 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29966 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29967 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29970 # Have a temporary directory for convenience. Make it in the build tree
29971 # simply because there is no reason against having it here, and in addition,
29972 # creating and moving files from /tmp can sometimes cause problems.
29973 # Hook for its removal unless debugging.
29974 # Note that there is a small window in which the directory will not be cleaned:
29975 # after its creation but before its name has been assigned to `$tmp'.
29976 $debug ||
29978 tmp=
29979 trap 'exit_status=$?
29980 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29982 trap 'as_fn_exit 1' 1 2 13 15
29984 # Create a (secure) tmp directory for tmp files.
29987 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29988 test -n "$tmp" && test -d "$tmp"
29989 } ||
29991 tmp=./conf$$-$RANDOM
29992 (umask 077 && mkdir "$tmp")
29993 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
29995 # Set up the scripts for CONFIG_FILES section.
29996 # No need to generate them if there are no CONFIG_FILES.
29997 # This happens for instance with `./config.status config.h'.
29998 if test -n "$CONFIG_FILES"; then
30000 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
30001 ac_cs_awk_getline=:
30002 ac_cs_awk_pipe_init=
30003 ac_cs_awk_read_file='
30004 while ((getline aline < (F[key])) > 0)
30005 print(aline)
30006 close(F[key])'
30007 ac_cs_awk_pipe_fini=
30008 else
30009 ac_cs_awk_getline=false
30010 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
30011 ac_cs_awk_read_file='
30012 print "|#_!!_#|"
30013 print "cat " F[key] " &&"
30014 '$ac_cs_awk_pipe_init
30015 # The final `:' finishes the AND list.
30016 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
30018 ac_cr=`echo X | tr X '\015'`
30019 # On cygwin, bash can eat \r inside `` if the user requested igncr.
30020 # But we know of no other shell where ac_cr would be empty at this
30021 # point, so we can use a bashism as a fallback.
30022 if test "x$ac_cr" = x; then
30023 eval ac_cr=\$\'\\r\'
30025 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30026 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30027 ac_cs_awk_cr='\r'
30028 else
30029 ac_cs_awk_cr=$ac_cr
30032 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30033 _ACEOF
30035 # Create commands to substitute file output variables.
30037 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
30038 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
30039 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
30040 echo "_ACAWK" &&
30041 echo "_ACEOF"
30042 } >conf$$files.sh &&
30043 . ./conf$$files.sh ||
30044 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30045 rm -f conf$$files.sh
30048 echo "cat >conf$$subs.awk <<_ACEOF" &&
30049 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30050 echo "_ACEOF"
30051 } >conf$$subs.sh ||
30052 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30053 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30054 ac_delim='%!_!# '
30055 for ac_last_try in false false false false false :; do
30056 . ./conf$$subs.sh ||
30057 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30059 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30060 if test $ac_delim_n = $ac_delim_num; then
30061 break
30062 elif $ac_last_try; then
30063 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30064 else
30065 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30067 done
30068 rm -f conf$$subs.sh
30070 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30071 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30072 _ACEOF
30073 sed -n '
30075 s/^/S["/; s/!.*/"]=/
30078 s/^[^!]*!//
30079 :repl
30080 t repl
30081 s/'"$ac_delim"'$//
30082 t delim
30085 s/\(.\{148\}\)..*/\1/
30086 t more1
30087 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30090 b repl
30091 :more1
30092 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30095 s/.\{148\}//
30096 t nl
30097 :delim
30099 s/\(.\{148\}\)..*/\1/
30100 t more2
30101 s/["\\]/\\&/g; s/^/"/; s/$/"/
30104 :more2
30105 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30108 s/.\{148\}//
30109 t delim
30110 ' <conf$$subs.awk | sed '
30111 /^[^""]/{
30113 s/\n//
30115 ' >>$CONFIG_STATUS || ac_write_fail=1
30116 rm -f conf$$subs.awk
30117 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30118 _ACAWK
30119 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30120 for (key in S) S_is_set[key] = 1
30121 FS = "\a"
30122 \$ac_cs_awk_pipe_init
30125 line = $ 0
30126 nfields = split(line, field, "@")
30127 substed = 0
30128 len = length(field[1])
30129 for (i = 2; i < nfields; i++) {
30130 key = field[i]
30131 keylen = length(key)
30132 if (S_is_set[key]) {
30133 value = S[key]
30134 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30135 len += length(value) + length(field[++i])
30136 substed = 1
30137 } else
30138 len += 1 + keylen
30140 if (nfields == 3 && !substed) {
30141 key = field[2]
30142 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
30143 \$ac_cs_awk_read_file
30144 next
30147 print line
30149 \$ac_cs_awk_pipe_fini
30150 _ACAWK
30151 _ACEOF
30152 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30153 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30154 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30155 else
30157 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30158 || as_fn_error "could not setup config files machinery" "$LINENO" 5
30159 _ACEOF
30161 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30162 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30163 # trailing colons and then remove the whole line if VPATH becomes empty
30164 # (actually we leave an empty line to preserve line numbers).
30165 if test "x$srcdir" = x.; then
30166 ac_vpsub='/^[ ]*VPATH[ ]*=/{
30167 s/:*\$(srcdir):*/:/
30168 s/:*\${srcdir}:*/:/
30169 s/:*@srcdir@:*/:/
30170 s/^\([^=]*=[ ]*\):*/\1/
30171 s/:*$//
30172 s/^[^=]*=[ ]*$//
30176 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30177 fi # test -n "$CONFIG_FILES"
30179 # Set up the scripts for CONFIG_HEADERS section.
30180 # No need to generate them if there are no CONFIG_HEADERS.
30181 # This happens for instance with `./config.status Makefile'.
30182 if test -n "$CONFIG_HEADERS"; then
30183 cat >"$tmp/defines.awk" <<\_ACAWK ||
30184 BEGIN {
30185 _ACEOF
30187 # Transform confdefs.h into an awk script `defines.awk', embedded as
30188 # here-document in config.status, that substitutes the proper values into
30189 # config.h.in to produce config.h.
30191 # Create a delimiter string that does not exist in confdefs.h, to ease
30192 # handling of long lines.
30193 ac_delim='%!_!# '
30194 for ac_last_try in false false :; do
30195 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30196 if test -z "$ac_t"; then
30197 break
30198 elif $ac_last_try; then
30199 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
30200 else
30201 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30203 done
30205 # For the awk script, D is an array of macro values keyed by name,
30206 # likewise P contains macro parameters if any. Preserve backslash
30207 # newline sequences.
30209 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30210 sed -n '
30211 s/.\{148\}/&'"$ac_delim"'/g
30212 t rset
30213 :rset
30214 s/^[ ]*#[ ]*define[ ][ ]*/ /
30215 t def
30217 :def
30218 s/\\$//
30219 t bsnl
30220 s/["\\]/\\&/g
30221 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30222 D["\1"]=" \3"/p
30223 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
30225 :bsnl
30226 s/["\\]/\\&/g
30227 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30228 D["\1"]=" \3\\\\\\n"\\/p
30229 t cont
30230 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30231 t cont
30233 :cont
30235 s/.\{148\}/&'"$ac_delim"'/g
30236 t clear
30237 :clear
30238 s/\\$//
30239 t bsnlc
30240 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30242 :bsnlc
30243 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30244 b cont
30245 ' <confdefs.h | sed '
30246 s/'"$ac_delim"'/"\\\
30247 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30249 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30250 for (key in D) D_is_set[key] = 1
30251 FS = "\a"
30253 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30254 line = \$ 0
30255 split(line, arg, " ")
30256 if (arg[1] == "#") {
30257 defundef = arg[2]
30258 mac1 = arg[3]
30259 } else {
30260 defundef = substr(arg[1], 2)
30261 mac1 = arg[2]
30263 split(mac1, mac2, "(") #)
30264 macro = mac2[1]
30265 prefix = substr(line, 1, index(line, defundef) - 1)
30266 if (D_is_set[macro]) {
30267 # Preserve the white space surrounding the "#".
30268 print prefix "define", macro P[macro] D[macro]
30269 next
30270 } else {
30271 # Replace #undef with comments. This is necessary, for example,
30272 # in the case of _POSIX_SOURCE, which is predefined and required
30273 # on some systems where configure will not decide to define it.
30274 if (defundef == "undef") {
30275 print "/*", prefix defundef, macro, "*/"
30276 next
30280 { print }
30281 _ACAWK
30282 _ACEOF
30283 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30284 as_fn_error "could not setup config headers machinery" "$LINENO" 5
30285 fi # test -n "$CONFIG_HEADERS"
30288 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
30289 shift
30290 for ac_tag
30292 case $ac_tag in
30293 :[FHLC]) ac_mode=$ac_tag; continue;;
30294 esac
30295 case $ac_mode$ac_tag in
30296 :[FHL]*:*);;
30297 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
30298 :[FH]-) ac_tag=-:-;;
30299 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30300 esac
30301 ac_save_IFS=$IFS
30302 IFS=:
30303 set x $ac_tag
30304 IFS=$ac_save_IFS
30305 shift
30306 ac_file=$1
30307 shift
30309 case $ac_mode in
30310 :L) ac_source=$1;;
30311 :[FH])
30312 ac_file_inputs=
30313 for ac_f
30315 case $ac_f in
30316 -) ac_f="$tmp/stdin";;
30317 *) # Look for the file first in the build tree, then in the source tree
30318 # (if the path is not absolute). The absolute path cannot be DOS-style,
30319 # because $ac_f cannot contain `:'.
30320 test -f "$ac_f" ||
30321 case $ac_f in
30322 [\\/$]*) false;;
30323 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30324 esac ||
30325 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30326 esac
30327 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30328 as_fn_append ac_file_inputs " '$ac_f'"
30329 done
30331 # Let's still pretend it is `configure' which instantiates (i.e., don't
30332 # use $as_me), people would be surprised to read:
30333 # /* config.h. Generated by config.status. */
30334 configure_input='Generated from '`
30335 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30336 `' by configure.'
30337 if test x"$ac_file" != x-; then
30338 configure_input="$ac_file. $configure_input"
30339 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30340 $as_echo "$as_me: creating $ac_file" >&6;}
30342 # Neutralize special characters interpreted by sed in replacement strings.
30343 case $configure_input in #(
30344 *\&* | *\|* | *\\* )
30345 ac_sed_conf_input=`$as_echo "$configure_input" |
30346 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30347 *) ac_sed_conf_input=$configure_input;;
30348 esac
30350 case $ac_tag in
30351 *:-:* | *:-) cat >"$tmp/stdin" \
30352 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
30353 esac
30355 esac
30357 ac_dir=`$as_dirname -- "$ac_file" ||
30358 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30359 X"$ac_file" : 'X\(//\)[^/]' \| \
30360 X"$ac_file" : 'X\(//\)$' \| \
30361 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30362 $as_echo X"$ac_file" |
30363 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30364 s//\1/
30367 /^X\(\/\/\)[^/].*/{
30368 s//\1/
30371 /^X\(\/\/\)$/{
30372 s//\1/
30375 /^X\(\/\).*/{
30376 s//\1/
30379 s/.*/./; q'`
30380 as_dir="$ac_dir"; as_fn_mkdir_p
30381 ac_builddir=.
30383 case "$ac_dir" in
30384 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30386 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30387 # A ".." for each directory in $ac_dir_suffix.
30388 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30389 case $ac_top_builddir_sub in
30390 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30391 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30392 esac ;;
30393 esac
30394 ac_abs_top_builddir=$ac_pwd
30395 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30396 # for backward compatibility:
30397 ac_top_builddir=$ac_top_build_prefix
30399 case $srcdir in
30400 .) # We are building in place.
30401 ac_srcdir=.
30402 ac_top_srcdir=$ac_top_builddir_sub
30403 ac_abs_top_srcdir=$ac_pwd ;;
30404 [\\/]* | ?:[\\/]* ) # Absolute name.
30405 ac_srcdir=$srcdir$ac_dir_suffix;
30406 ac_top_srcdir=$srcdir
30407 ac_abs_top_srcdir=$srcdir ;;
30408 *) # Relative name.
30409 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30410 ac_top_srcdir=$ac_top_build_prefix$srcdir
30411 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30412 esac
30413 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30416 case $ac_mode in
30419 # CONFIG_FILE
30422 case $INSTALL in
30423 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30424 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30425 esac
30426 ac_MKDIR_P=$MKDIR_P
30427 case $MKDIR_P in
30428 [\\/$]* | ?:[\\/]* ) ;;
30429 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30430 esac
30431 _ACEOF
30433 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30434 # If the template does not know about datarootdir, expand it.
30435 # FIXME: This hack should be removed a few years after 2.60.
30436 ac_datarootdir_hack=; ac_datarootdir_seen=
30437 ac_sed_dataroot='
30438 /datarootdir/ {
30442 /@datadir@/p
30443 /@docdir@/p
30444 /@infodir@/p
30445 /@localedir@/p
30446 /@mandir@/p'
30447 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30448 *datarootdir*) ac_datarootdir_seen=yes;;
30449 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30450 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30451 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30452 _ACEOF
30453 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30454 ac_datarootdir_hack='
30455 s&@datadir@&$datadir&g
30456 s&@docdir@&$docdir&g
30457 s&@infodir@&$infodir&g
30458 s&@localedir@&$localedir&g
30459 s&@mandir@&$mandir&g
30460 s&\\\${datarootdir}&$datarootdir&g' ;;
30461 esac
30462 _ACEOF
30464 # Neutralize VPATH when `$srcdir' = `.'.
30465 # Shell code in configure.ac might set extrasub.
30466 # FIXME: do we really want to maintain this feature?
30467 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30468 ac_sed_extra="$ac_vpsub
30469 $extrasub
30470 _ACEOF
30471 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30473 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30474 s|@configure_input@|$ac_sed_conf_input|;t t
30475 s&@top_builddir@&$ac_top_builddir_sub&;t t
30476 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30477 s&@srcdir@&$ac_srcdir&;t t
30478 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30479 s&@top_srcdir@&$ac_top_srcdir&;t t
30480 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30481 s&@builddir@&$ac_builddir&;t t
30482 s&@abs_builddir@&$ac_abs_builddir&;t t
30483 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30484 s&@INSTALL@&$ac_INSTALL&;t t
30485 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30486 $ac_datarootdir_hack
30488 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30489 if $ac_cs_awk_getline; then
30490 $AWK -f "$tmp/subs.awk"
30491 else
30492 $AWK -f "$tmp/subs.awk" | $SHELL
30493 fi >$tmp/out \
30494 || as_fn_error "could not create $ac_file" "$LINENO" 5
30496 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30497 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30498 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30500 which seems to be undefined. Please make sure it is defined." >&5
30501 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30502 which seems to be undefined. Please make sure it is defined." >&2;}
30504 rm -f "$tmp/stdin"
30505 case $ac_file in
30506 -) cat "$tmp/out" && rm -f "$tmp/out";;
30507 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30508 esac \
30509 || as_fn_error "could not create $ac_file" "$LINENO" 5
30513 # CONFIG_HEADER
30515 if test x"$ac_file" != x-; then
30517 $as_echo "/* $configure_input */" \
30518 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30519 } >"$tmp/config.h" \
30520 || as_fn_error "could not create $ac_file" "$LINENO" 5
30521 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30522 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30523 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30524 else
30525 rm -f "$ac_file"
30526 mv "$tmp/config.h" "$ac_file" \
30527 || as_fn_error "could not create $ac_file" "$LINENO" 5
30529 else
30530 $as_echo "/* $configure_input */" \
30531 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30532 || as_fn_error "could not create -" "$LINENO" 5
30534 # Compute "$ac_file"'s index in $config_headers.
30535 _am_arg="$ac_file"
30536 _am_stamp_count=1
30537 for _am_header in $config_headers :; do
30538 case $_am_header in
30539 $_am_arg | $_am_arg:* )
30540 break ;;
30542 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30543 esac
30544 done
30545 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30546 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30547 X"$_am_arg" : 'X\(//\)[^/]' \| \
30548 X"$_am_arg" : 'X\(//\)$' \| \
30549 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30550 $as_echo X"$_am_arg" |
30551 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30552 s//\1/
30555 /^X\(\/\/\)[^/].*/{
30556 s//\1/
30559 /^X\(\/\/\)$/{
30560 s//\1/
30563 /^X\(\/\).*/{
30564 s//\1/
30567 s/.*/./; q'`/stamp-h$_am_stamp_count
30570 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30571 $as_echo "$as_me: executing $ac_file commands" >&6;}
30573 esac
30576 case $ac_file$ac_mode in
30577 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30578 # Autoconf 2.62 quotes --file arguments for eval, but not when files
30579 # are listed without --file. Let's play safe and only enable the eval
30580 # if we detect the quoting.
30581 case $CONFIG_FILES in
30582 *\'*) eval set x "$CONFIG_FILES" ;;
30583 *) set x $CONFIG_FILES ;;
30584 esac
30585 shift
30586 for mf
30588 # Strip MF so we end up with the name of the file.
30589 mf=`echo "$mf" | sed -e 's/:.*$//'`
30590 # Check whether this is an Automake generated Makefile or not.
30591 # We used to match only the files named `Makefile.in', but
30592 # some people rename them; so instead we look at the file content.
30593 # Grep'ing the first line is not enough: some people post-process
30594 # each Makefile.in and add a new line on top of each file to say so.
30595 # Grep'ing the whole file is not good either: AIX grep has a line
30596 # limit of 2048, but all sed's we know have understand at least 4000.
30597 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30598 dirpart=`$as_dirname -- "$mf" ||
30599 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30600 X"$mf" : 'X\(//\)[^/]' \| \
30601 X"$mf" : 'X\(//\)$' \| \
30602 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30603 $as_echo X"$mf" |
30604 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30605 s//\1/
30608 /^X\(\/\/\)[^/].*/{
30609 s//\1/
30612 /^X\(\/\/\)$/{
30613 s//\1/
30616 /^X\(\/\).*/{
30617 s//\1/
30620 s/.*/./; q'`
30621 else
30622 continue
30624 # Extract the definition of DEPDIR, am__include, and am__quote
30625 # from the Makefile without running `make'.
30626 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30627 test -z "$DEPDIR" && continue
30628 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30629 test -z "am__include" && continue
30630 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30631 # When using ansi2knr, U may be empty or an underscore; expand it
30632 U=`sed -n 's/^U = //p' < "$mf"`
30633 # Find all dependency output files, they are included files with
30634 # $(DEPDIR) in their names. We invoke sed twice because it is the
30635 # simplest approach to changing $(DEPDIR) to its actual value in the
30636 # expansion.
30637 for file in `sed -n "
30638 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30639 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
30640 # Make sure the directory exists.
30641 test -f "$dirpart/$file" && continue
30642 fdir=`$as_dirname -- "$file" ||
30643 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30644 X"$file" : 'X\(//\)[^/]' \| \
30645 X"$file" : 'X\(//\)$' \| \
30646 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30647 $as_echo X"$file" |
30648 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30649 s//\1/
30652 /^X\(\/\/\)[^/].*/{
30653 s//\1/
30656 /^X\(\/\/\)$/{
30657 s//\1/
30660 /^X\(\/\).*/{
30661 s//\1/
30664 s/.*/./; q'`
30665 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30666 # echo "creating $dirpart/$file"
30667 echo '# dummy' > "$dirpart/$file"
30668 done
30669 done
30672 "src/epaths.h":C)
30673 if test "${opsys}" = "mingw32"; then
30674 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
30675 else
30676 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
30679 "src/.gdbinit":C)
30680 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
30681 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
30685 esac
30686 done # for ac_tag
30689 as_fn_exit 0
30690 _ACEOF
30691 ac_clean_files=$ac_clean_files_save
30693 test $ac_write_fail = 0 ||
30694 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
30697 # configure is writing to config.log, and then calls config.status.
30698 # config.status does its own redirection, appending to config.log.
30699 # Unfortunately, on DOS this fails, as config.log is still kept open
30700 # by configure, so config.status won't be able to write to it; its
30701 # output is simply discarded. So we exec the FD to /dev/null,
30702 # effectively closing config.log, so it can be properly (re)opened and
30703 # appended to by config.status. When coming back to configure, we
30704 # need to make the FD available again.
30705 if test "$no_create" != yes; then
30706 ac_cs_success=:
30707 ac_config_status_args=
30708 test "$silent" = yes &&
30709 ac_config_status_args="$ac_config_status_args --quiet"
30710 exec 5>/dev/null
30711 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30712 exec 5>>config.log
30713 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30714 # would make configure fail if this is the last instruction.
30715 $ac_cs_success || as_fn_exit $?
30717 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30718 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30719 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}