Fix bug #14540 with inaccurate doc string of pos-visible-in-window-p.
[emacs.git] / autogen / configure
blob628a856f6724422239d612514d47f976dc90744e
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_verify_FALSE
618 gl_GNULIB_ENABLED_verify_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_6099e9737f757db36c47fa9d9f02e88c_FALSE
626 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
627 gl_GNULIB_ENABLED_pathmax_FALSE
628 gl_GNULIB_ENABLED_pathmax_TRUE
629 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
630 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
631 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
632 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
633 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
634 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
635 gl_GNULIB_ENABLED_getgroups_FALSE
636 gl_GNULIB_ENABLED_getgroups_TRUE
637 gl_GNULIB_ENABLED_euidaccess_FALSE
638 gl_GNULIB_ENABLED_euidaccess_TRUE
639 gl_GNULIB_ENABLED_dosname_FALSE
640 gl_GNULIB_ENABLED_dosname_TRUE
641 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE
642 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE
643 LTLIBINTL
644 LIBINTL
645 LIB_EACCESS
646 WINDOWS_64_BIT_OFF_T
647 HAVE_UNISTD_H
648 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
649 NEXT_UNISTD_H
650 LIB_TIMER_TIME
651 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
652 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
653 TIME_H_DEFINES_STRUCT_TIMESPEC
654 NEXT_AS_FIRST_DIRECTIVE_TIME_H
655 NEXT_TIME_H
656 WINDOWS_64_BIT_ST_SIZE
657 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
658 NEXT_SYS_STAT_H
659 NEXT_AS_FIRST_DIRECTIVE_STRING_H
660 NEXT_STRING_H
661 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
662 NEXT_STDLIB_H
663 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
664 NEXT_STDIO_H
665 REPLACE_VSPRINTF
666 REPLACE_VSNPRINTF
667 REPLACE_VPRINTF
668 REPLACE_VFPRINTF
669 REPLACE_VDPRINTF
670 REPLACE_VASPRINTF
671 REPLACE_TMPFILE
672 REPLACE_STDIO_WRITE_FUNCS
673 REPLACE_STDIO_READ_FUNCS
674 REPLACE_SPRINTF
675 REPLACE_SNPRINTF
676 REPLACE_RENAMEAT
677 REPLACE_RENAME
678 REPLACE_REMOVE
679 REPLACE_PRINTF
680 REPLACE_POPEN
681 REPLACE_PERROR
682 REPLACE_OBSTACK_PRINTF
683 REPLACE_GETLINE
684 REPLACE_GETDELIM
685 REPLACE_FTELLO
686 REPLACE_FTELL
687 REPLACE_FSEEKO
688 REPLACE_FSEEK
689 REPLACE_FREOPEN
690 REPLACE_FPURGE
691 REPLACE_FPRINTF
692 REPLACE_FOPEN
693 REPLACE_FFLUSH
694 REPLACE_FDOPEN
695 REPLACE_FCLOSE
696 REPLACE_DPRINTF
697 HAVE_VDPRINTF
698 HAVE_VASPRINTF
699 HAVE_RENAMEAT
700 HAVE_POPEN
701 HAVE_PCLOSE
702 HAVE_FTELLO
703 HAVE_FSEEKO
704 HAVE_DPRINTF
705 HAVE_DECL_VSNPRINTF
706 HAVE_DECL_SNPRINTF
707 HAVE_DECL_OBSTACK_PRINTF
708 HAVE_DECL_GETLINE
709 HAVE_DECL_GETDELIM
710 HAVE_DECL_FTELLO
711 HAVE_DECL_FSEEKO
712 HAVE_DECL_FPURGE
713 GNULIB_VSPRINTF_POSIX
714 GNULIB_VSNPRINTF
715 GNULIB_VPRINTF_POSIX
716 GNULIB_VPRINTF
717 GNULIB_VFPRINTF_POSIX
718 GNULIB_VFPRINTF
719 GNULIB_VDPRINTF
720 GNULIB_VSCANF
721 GNULIB_VFSCANF
722 GNULIB_VASPRINTF
723 GNULIB_TMPFILE
724 GNULIB_STDIO_H_SIGPIPE
725 GNULIB_STDIO_H_NONBLOCKING
726 GNULIB_SPRINTF_POSIX
727 GNULIB_SNPRINTF
728 GNULIB_SCANF
729 GNULIB_RENAMEAT
730 GNULIB_RENAME
731 GNULIB_REMOVE
732 GNULIB_PUTS
733 GNULIB_PUTCHAR
734 GNULIB_PUTC
735 GNULIB_PRINTF_POSIX
736 GNULIB_PRINTF
737 GNULIB_POPEN
738 GNULIB_PERROR
739 GNULIB_PCLOSE
740 GNULIB_OBSTACK_PRINTF_POSIX
741 GNULIB_OBSTACK_PRINTF
742 GNULIB_GETLINE
743 GNULIB_GETDELIM
744 GNULIB_GETCHAR
745 GNULIB_GETC
746 GNULIB_FWRITE
747 GNULIB_FTELLO
748 GNULIB_FTELL
749 GNULIB_FSEEKO
750 GNULIB_FSEEK
751 GNULIB_FSCANF
752 GNULIB_FREOPEN
753 GNULIB_FREAD
754 GNULIB_FPUTS
755 GNULIB_FPUTC
756 GNULIB_FPURGE
757 GNULIB_FPRINTF_POSIX
758 GNULIB_FPRINTF
759 GNULIB_FOPEN
760 GNULIB_FGETS
761 GNULIB_FGETC
762 GNULIB_FFLUSH
763 GNULIB_FDOPEN
764 GNULIB_FCLOSE
765 GNULIB_DPRINTF
766 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
767 NEXT_STDDEF_H
768 GL_GENERATE_STDDEF_H_FALSE
769 GL_GENERATE_STDDEF_H_TRUE
770 STDDEF_H
771 HAVE_WCHAR_T
772 REPLACE_NULL
773 HAVE__BOOL
774 GL_GENERATE_STDBOOL_H_FALSE
775 GL_GENERATE_STDBOOL_H_TRUE
776 STDBOOL_H
777 GL_GENERATE_STDARG_H_FALSE
778 GL_GENERATE_STDARG_H_TRUE
779 STDARG_H
780 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
781 NEXT_STDARG_H
782 GL_GENERATE_STDALIGN_H_FALSE
783 GL_GENERATE_STDALIGN_H_TRUE
784 STDALIGN_H
785 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
786 NEXT_SIGNAL_H
787 USE_ACL
788 LIB_ACL
789 LIB_PTHREAD_SIGMASK
790 REPLACE_RAISE
791 REPLACE_PTHREAD_SIGMASK
792 HAVE_SIGHANDLER_T
793 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
794 HAVE_STRUCT_SIGACTION_SA_SIGACTION
795 HAVE_SIGACTION
796 HAVE_SIGINFO_T
797 HAVE_SIGSET_T
798 HAVE_RAISE
799 HAVE_PTHREAD_SIGMASK
800 HAVE_POSIX_SIGNALBLOCKING
801 GNULIB_SIGACTION
802 GNULIB_SIGPROCMASK
803 GNULIB_SIGNAL_H_SIGPIPE
804 GNULIB_RAISE
805 GNULIB_PTHREAD_SIGMASK
806 HAVE_SYS_SELECT_H
807 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
808 NEXT_SYS_SELECT_H
809 REPLACE_SELECT
810 REPLACE_PSELECT
811 HAVE_PSELECT
812 GNULIB_SELECT
813 GNULIB_PSELECT
814 REPLACE_TIMEGM
815 REPLACE_NANOSLEEP
816 REPLACE_MKTIME
817 REPLACE_LOCALTIME_R
818 HAVE_TIMEGM
819 HAVE_STRPTIME
820 HAVE_NANOSLEEP
821 HAVE_DECL_LOCALTIME_R
822 GNULIB_TIME_R
823 GNULIB_TIMEGM
824 GNULIB_STRPTIME
825 GNULIB_NANOSLEEP
826 GNULIB_MKTIME
827 UNDEFINE_STRTOK_R
828 REPLACE_STRTOK_R
829 REPLACE_STRSIGNAL
830 REPLACE_STRNLEN
831 REPLACE_STRNDUP
832 REPLACE_STRNCAT
833 REPLACE_STRERROR_R
834 REPLACE_STRERROR
835 REPLACE_STRCHRNUL
836 REPLACE_STRCASESTR
837 REPLACE_STRSTR
838 REPLACE_STRDUP
839 REPLACE_STPNCPY
840 REPLACE_MEMMEM
841 REPLACE_MEMCHR
842 HAVE_STRVERSCMP
843 HAVE_DECL_STRSIGNAL
844 HAVE_DECL_STRERROR_R
845 HAVE_DECL_STRTOK_R
846 HAVE_STRCASESTR
847 HAVE_STRSEP
848 HAVE_STRPBRK
849 HAVE_DECL_STRNLEN
850 HAVE_DECL_STRNDUP
851 HAVE_DECL_STRDUP
852 HAVE_STRCHRNUL
853 HAVE_STPNCPY
854 HAVE_STPCPY
855 HAVE_RAWMEMCHR
856 HAVE_DECL_MEMRCHR
857 HAVE_MEMPCPY
858 HAVE_DECL_MEMMEM
859 HAVE_MEMCHR
860 HAVE_FFSLL
861 HAVE_FFSL
862 HAVE_MBSLEN
863 GNULIB_STRVERSCMP
864 GNULIB_STRSIGNAL
865 GNULIB_STRERROR_R
866 GNULIB_STRERROR
867 GNULIB_MBSTOK_R
868 GNULIB_MBSSEP
869 GNULIB_MBSSPN
870 GNULIB_MBSPBRK
871 GNULIB_MBSCSPN
872 GNULIB_MBSCASESTR
873 GNULIB_MBSPCASECMP
874 GNULIB_MBSNCASECMP
875 GNULIB_MBSCASECMP
876 GNULIB_MBSSTR
877 GNULIB_MBSRCHR
878 GNULIB_MBSCHR
879 GNULIB_MBSNLEN
880 GNULIB_MBSLEN
881 GNULIB_STRTOK_R
882 GNULIB_STRCASESTR
883 GNULIB_STRSTR
884 GNULIB_STRSEP
885 GNULIB_STRPBRK
886 GNULIB_STRNLEN
887 GNULIB_STRNDUP
888 GNULIB_STRNCAT
889 GNULIB_STRDUP
890 GNULIB_STRCHRNUL
891 GNULIB_STPNCPY
892 GNULIB_STPCPY
893 GNULIB_RAWMEMCHR
894 GNULIB_MEMRCHR
895 GNULIB_MEMPCPY
896 GNULIB_MEMMEM
897 GNULIB_MEMCHR
898 GNULIB_FFSLL
899 GNULIB_FFSL
900 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
901 NEXT_INTTYPES_H
902 UINT64_MAX_EQ_ULONG_MAX
903 UINT32_MAX_LT_UINTMAX_MAX
904 PRIPTR_PREFIX
905 PRI_MACROS_BROKEN
906 INT64_MAX_EQ_LONG_MAX
907 INT32_MAX_LT_INTMAX_MAX
908 REPLACE_STRTOIMAX
909 HAVE_DECL_STRTOUMAX
910 HAVE_DECL_STRTOIMAX
911 HAVE_DECL_IMAXDIV
912 HAVE_DECL_IMAXABS
913 GNULIB_STRTOUMAX
914 GNULIB_STRTOIMAX
915 GNULIB_IMAXDIV
916 GNULIB_IMAXABS
917 GL_GENERATE_STDINT_H_FALSE
918 GL_GENERATE_STDINT_H_TRUE
919 STDINT_H
920 WINT_T_SUFFIX
921 WCHAR_T_SUFFIX
922 SIG_ATOMIC_T_SUFFIX
923 SIZE_T_SUFFIX
924 PTRDIFF_T_SUFFIX
925 HAVE_SIGNED_WINT_T
926 HAVE_SIGNED_WCHAR_T
927 HAVE_SIGNED_SIG_ATOMIC_T
928 BITSIZEOF_WINT_T
929 BITSIZEOF_WCHAR_T
930 BITSIZEOF_SIG_ATOMIC_T
931 BITSIZEOF_SIZE_T
932 BITSIZEOF_PTRDIFF_T
933 APPLE_UNIVERSAL_BUILD
934 HAVE_SYS_BITYPES_H
935 HAVE_SYS_INTTYPES_H
936 HAVE_STDINT_H
937 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
938 NEXT_STDINT_H
939 HAVE_SYS_TYPES_H
940 HAVE_INTTYPES_H
941 HAVE_WCHAR_H
942 HAVE_UNSIGNED_LONG_LONG_INT
943 HAVE_LONG_LONG_INT
944 HAVE_WINSOCK2_H
945 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
946 NEXT_SYS_TIME_H
947 REPLACE_STRUCT_TIMEVAL
948 REPLACE_GETTIMEOFDAY
949 HAVE_SYS_TIME_H
950 HAVE_STRUCT_TIMEVAL
951 HAVE_GETTIMEOFDAY
952 GNULIB_GETTIMEOFDAY
953 GNULIB_GL_UNISTD_H_GETOPT
954 GETOPT_H
955 HAVE_GETOPT_H
956 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
957 NEXT_GETOPT_H
958 GETLOADAVG_LIBS
959 REPLACE_WCTOMB
960 REPLACE_UNSETENV
961 REPLACE_STRTOD
962 REPLACE_SETENV
963 REPLACE_REALPATH
964 REPLACE_REALLOC
965 REPLACE_RANDOM_R
966 REPLACE_PUTENV
967 REPLACE_PTSNAME_R
968 REPLACE_PTSNAME
969 REPLACE_MKSTEMP
970 REPLACE_MBTOWC
971 REPLACE_MALLOC
972 REPLACE_CANONICALIZE_FILE_NAME
973 REPLACE_CALLOC
974 HAVE_DECL_UNSETENV
975 HAVE_UNLOCKPT
976 HAVE_SYS_LOADAVG_H
977 HAVE_STRUCT_RANDOM_DATA
978 HAVE_STRTOULL
979 HAVE_STRTOLL
980 HAVE_STRTOD
981 HAVE_DECL_SETENV
982 HAVE_SETENV
983 HAVE_SECURE_GETENV
984 HAVE_RPMATCH
985 HAVE_REALPATH
986 HAVE_RANDOM_R
987 HAVE_RANDOM_H
988 HAVE_RANDOM
989 HAVE_PTSNAME_R
990 HAVE_PTSNAME
991 HAVE_POSIX_OPENPT
992 HAVE_MKSTEMPS
993 HAVE_MKSTEMP
994 HAVE_MKOSTEMPS
995 HAVE_MKOSTEMP
996 HAVE_MKDTEMP
997 HAVE_GRANTPT
998 HAVE_GETSUBOPT
999 HAVE_DECL_GETLOADAVG
1000 HAVE_CANONICALIZE_FILE_NAME
1001 HAVE_ATOLL
1002 HAVE__EXIT
1003 GNULIB_WCTOMB
1004 GNULIB_UNSETENV
1005 GNULIB_UNLOCKPT
1006 GNULIB_SYSTEM_POSIX
1007 GNULIB_STRTOULL
1008 GNULIB_STRTOLL
1009 GNULIB_STRTOD
1010 GNULIB_SETENV
1011 GNULIB_SECURE_GETENV
1012 GNULIB_RPMATCH
1013 GNULIB_REALPATH
1014 GNULIB_REALLOC_POSIX
1015 GNULIB_RANDOM_R
1016 GNULIB_RANDOM
1017 GNULIB_PUTENV
1018 GNULIB_PTSNAME_R
1019 GNULIB_PTSNAME
1020 GNULIB_POSIX_OPENPT
1021 GNULIB_MKSTEMPS
1022 GNULIB_MKSTEMP
1023 GNULIB_MKOSTEMPS
1024 GNULIB_MKOSTEMP
1025 GNULIB_MKDTEMP
1026 GNULIB_MBTOWC
1027 GNULIB_MALLOC_POSIX
1028 GNULIB_GRANTPT
1029 GNULIB_GETSUBOPT
1030 GNULIB_GETLOADAVG
1031 GNULIB_CANONICALIZE_FILE_NAME
1032 GNULIB_CALLOC_POSIX
1033 GNULIB_ATOLL
1034 GNULIB__EXIT
1035 REPLACE_UTIMENSAT
1036 REPLACE_STAT
1037 REPLACE_MKNOD
1038 REPLACE_MKFIFO
1039 REPLACE_MKDIR
1040 REPLACE_LSTAT
1041 REPLACE_FUTIMENS
1042 REPLACE_FSTATAT
1043 REPLACE_FSTAT
1044 HAVE_UTIMENSAT
1045 HAVE_MKNODAT
1046 HAVE_MKNOD
1047 HAVE_MKFIFOAT
1048 HAVE_MKFIFO
1049 HAVE_MKDIRAT
1050 HAVE_LSTAT
1051 HAVE_LCHMOD
1052 HAVE_FUTIMENS
1053 HAVE_FSTATAT
1054 HAVE_FCHMODAT
1055 GNULIB_UTIMENSAT
1056 GNULIB_STAT
1057 GNULIB_MKNODAT
1058 GNULIB_MKNOD
1059 GNULIB_MKFIFOAT
1060 GNULIB_MKFIFO
1061 GNULIB_MKDIRAT
1062 GNULIB_LSTAT
1063 GNULIB_LCHMOD
1064 GNULIB_FUTIMENS
1065 GNULIB_FSTATAT
1066 GNULIB_FSTAT
1067 GNULIB_FCHMODAT
1068 LIB_FDATASYNC
1069 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1070 NEXT_FCNTL_H
1071 REPLACE_OPENAT
1072 REPLACE_OPEN
1073 REPLACE_FCNTL
1074 HAVE_OPENAT
1075 HAVE_FCNTL
1076 GNULIB_OPENAT
1077 GNULIB_OPEN
1078 GNULIB_NONBLOCKING
1079 GNULIB_FCNTL
1080 GL_GENERATE_EXECINFO_H_FALSE
1081 GL_GENERATE_EXECINFO_H_TRUE
1082 LIB_EXECINFO
1083 EXECINFO_H
1084 EOVERFLOW_VALUE
1085 EOVERFLOW_HIDDEN
1086 ENOLINK_VALUE
1087 ENOLINK_HIDDEN
1088 EMULTIHOP_VALUE
1089 EMULTIHOP_HIDDEN
1090 GL_GENERATE_ERRNO_H_FALSE
1091 GL_GENERATE_ERRNO_H_TRUE
1092 ERRNO_H
1093 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1094 NEXT_ERRNO_H
1095 HAVE_DIRENT_H
1096 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1097 NEXT_DIRENT_H
1098 PRAGMA_COLUMNS
1099 PRAGMA_SYSTEM_HEADER
1100 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1101 INCLUDE_NEXT
1102 REPLACE_FDOPENDIR
1103 REPLACE_DIRFD
1104 REPLACE_CLOSEDIR
1105 REPLACE_OPENDIR
1106 HAVE_ALPHASORT
1107 HAVE_SCANDIR
1108 HAVE_FDOPENDIR
1109 HAVE_DECL_FDOPENDIR
1110 HAVE_DECL_DIRFD
1111 HAVE_CLOSEDIR
1112 HAVE_REWINDDIR
1113 HAVE_READDIR
1114 HAVE_OPENDIR
1115 GNULIB_ALPHASORT
1116 GNULIB_SCANDIR
1117 GNULIB_FDOPENDIR
1118 GNULIB_DIRFD
1119 GNULIB_CLOSEDIR
1120 GNULIB_REWINDDIR
1121 GNULIB_READDIR
1122 GNULIB_OPENDIR
1123 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1124 UNISTD_H_HAVE_WINSOCK2_H
1125 REPLACE_WRITE
1126 REPLACE_USLEEP
1127 REPLACE_UNLINKAT
1128 REPLACE_UNLINK
1129 REPLACE_TTYNAME_R
1130 REPLACE_SYMLINK
1131 REPLACE_SLEEP
1132 REPLACE_RMDIR
1133 REPLACE_READLINK
1134 REPLACE_READ
1135 REPLACE_PWRITE
1136 REPLACE_PREAD
1137 REPLACE_LSEEK
1138 REPLACE_LINKAT
1139 REPLACE_LINK
1140 REPLACE_LCHOWN
1141 REPLACE_ISATTY
1142 REPLACE_GETPAGESIZE
1143 REPLACE_GETGROUPS
1144 REPLACE_GETLOGIN_R
1145 REPLACE_GETDOMAINNAME
1146 REPLACE_GETCWD
1147 REPLACE_FTRUNCATE
1148 REPLACE_FCHOWNAT
1149 REPLACE_DUP2
1150 REPLACE_DUP
1151 REPLACE_CLOSE
1152 REPLACE_CHOWN
1153 HAVE_SYS_PARAM_H
1154 HAVE_OS_H
1155 HAVE_DECL_TTYNAME_R
1156 HAVE_DECL_SETHOSTNAME
1157 HAVE_DECL_GETUSERSHELL
1158 HAVE_DECL_GETPAGESIZE
1159 HAVE_DECL_GETLOGIN_R
1160 HAVE_DECL_GETDOMAINNAME
1161 HAVE_DECL_FDATASYNC
1162 HAVE_DECL_FCHDIR
1163 HAVE_DECL_ENVIRON
1164 HAVE_USLEEP
1165 HAVE_UNLINKAT
1166 HAVE_SYMLINKAT
1167 HAVE_SYMLINK
1168 HAVE_SLEEP
1169 HAVE_SETHOSTNAME
1170 HAVE_READLINKAT
1171 HAVE_READLINK
1172 HAVE_PWRITE
1173 HAVE_PREAD
1174 HAVE_PIPE2
1175 HAVE_PIPE
1176 HAVE_LINKAT
1177 HAVE_LINK
1178 HAVE_LCHOWN
1179 HAVE_GROUP_MEMBER
1180 HAVE_GETPAGESIZE
1181 HAVE_GETLOGIN
1182 HAVE_GETHOSTNAME
1183 HAVE_GETGROUPS
1184 HAVE_GETDTABLESIZE
1185 HAVE_FTRUNCATE
1186 HAVE_FSYNC
1187 HAVE_FDATASYNC
1188 HAVE_FCHOWNAT
1189 HAVE_FCHDIR
1190 HAVE_FACCESSAT
1191 HAVE_EUIDACCESS
1192 HAVE_DUP3
1193 HAVE_DUP2
1194 HAVE_CHOWN
1195 GNULIB_WRITE
1196 GNULIB_USLEEP
1197 GNULIB_UNLINKAT
1198 GNULIB_UNLINK
1199 GNULIB_UNISTD_H_SIGPIPE
1200 GNULIB_UNISTD_H_NONBLOCKING
1201 GNULIB_TTYNAME_R
1202 GNULIB_SYMLINKAT
1203 GNULIB_SYMLINK
1204 GNULIB_SLEEP
1205 GNULIB_SETHOSTNAME
1206 GNULIB_RMDIR
1207 GNULIB_READLINKAT
1208 GNULIB_READLINK
1209 GNULIB_READ
1210 GNULIB_PWRITE
1211 GNULIB_PREAD
1212 GNULIB_PIPE2
1213 GNULIB_PIPE
1214 GNULIB_LSEEK
1215 GNULIB_LINKAT
1216 GNULIB_LINK
1217 GNULIB_LCHOWN
1218 GNULIB_ISATTY
1219 GNULIB_GROUP_MEMBER
1220 GNULIB_GETUSERSHELL
1221 GNULIB_GETPAGESIZE
1222 GNULIB_GETLOGIN_R
1223 GNULIB_GETLOGIN
1224 GNULIB_GETHOSTNAME
1225 GNULIB_GETGROUPS
1226 GNULIB_GETDTABLESIZE
1227 GNULIB_GETDOMAINNAME
1228 GNULIB_GETCWD
1229 GNULIB_FTRUNCATE
1230 GNULIB_FSYNC
1231 GNULIB_FDATASYNC
1232 GNULIB_FCHOWNAT
1233 GNULIB_FCHDIR
1234 GNULIB_FACCESSAT
1235 GNULIB_EUIDACCESS
1236 GNULIB_ENVIRON
1237 GNULIB_DUP3
1238 GNULIB_DUP2
1239 GNULIB_DUP
1240 GNULIB_CLOSE
1241 GNULIB_CHOWN
1242 GNULIB_CHDIR
1243 LIB_CLOCK_GETTIME
1244 GL_GENERATE_ALLOCA_H_FALSE
1245 GL_GENERATE_ALLOCA_H_TRUE
1246 ALLOCA_H
1247 ALLOCA
1248 GL_COND_LIBTOOL_FALSE
1249 GL_COND_LIBTOOL_TRUE
1250 POST_ALLOC_OBJ
1251 PRE_ALLOC_OBJ
1252 CYGWIN_OBJ
1253 RALLOC_OBJ
1254 OLDXMENU_DEPS
1255 LIBX_OTHER
1256 LIBXMENU
1257 OLDXMENU
1258 OLDXMENU_TARGET
1259 LIBXT_OTHER
1260 TOOLKIT_LIBW
1261 WIDGET_OBJ
1262 XOBJ
1263 XMENU_OBJ
1264 FONT_OBJ
1265 OTHER_FILES
1266 GNU_OBJC_CFLAGS
1267 ns_appsrc
1268 ns_appresdir
1269 ns_appbindir
1270 ns_appdir
1271 X_TOOLKIT_TYPE
1272 GNUSTEP_CFLAGS
1273 C_SWITCH_X_SITE
1274 LD_SWITCH_X_SITE
1275 gameuser
1276 gamedir
1277 bitmapdir
1278 archlibdir
1279 etcdir
1280 x_default_search_path
1281 lisppath
1282 locallisppath
1283 standardlisppath
1284 leimdir
1285 lispdir
1286 srcdir
1287 canonical
1288 configuration
1289 version
1290 copyright
1291 XGSELOBJ
1292 KRB4LIB
1293 DESLIB
1294 KRB5LIB
1295 CRYPTOLIB
1296 COM_ERRLIB
1297 LIBRESOLV
1298 LIBHESIOD
1299 TERMCAP_OBJ
1300 LIBS_TERMCAP
1301 BLESSMAIL_TARGET
1302 LIBS_MAIL
1303 liblockfile
1304 LIBXML2_LIBS
1305 LIBXML2_CFLAGS
1306 XINERAMA_LIBS
1307 XINERAMA_CFLAGS
1308 XRANDR_LIBS
1309 XRANDR_CFLAGS
1310 LIBXSM
1311 LIBGPM
1312 LIBGIF
1313 LIBTIFF
1314 LIBPNG
1315 LIBJPEG
1316 LIBXPM
1317 M17N_FLT_LIBS
1318 M17N_FLT_CFLAGS
1319 LIBOTF_LIBS
1320 LIBOTF_CFLAGS
1321 FREETYPE_LIBS
1322 FREETYPE_CFLAGS
1323 XFT_LIBS
1324 XFT_CFLAGS
1325 FONTCONFIG_LIBS
1326 FONTCONFIG_CFLAGS
1327 LIBXMU
1328 LIBXTR6
1329 NOTIFY_OBJ
1330 GFILENOTIFY_LIBS
1331 GFILENOTIFY_CFLAGS
1332 LIBGNUTLS_LIBS
1333 LIBGNUTLS_CFLAGS
1334 LIBSELINUX_LIBS
1335 SETTINGS_LIBS
1336 SETTINGS_CFLAGS
1337 GOBJECT_LIBS
1338 GOBJECT_CFLAGS
1339 GCONF_LIBS
1340 GCONF_CFLAGS
1341 GSETTINGS_LIBS
1342 GSETTINGS_CFLAGS
1343 DBUS_OBJ
1344 DBUS_LIBS
1345 DBUS_CFLAGS
1346 GTK_OBJ
1347 GTK_LIBS
1348 GTK_CFLAGS
1349 IMAGEMAGICK_LIBS
1350 IMAGEMAGICK_CFLAGS
1351 RSVG_LIBS
1352 RSVG_CFLAGS
1353 LIB_PTHREAD
1354 VMLIMIT_OBJ
1355 GMALLOC_OBJ
1356 HAVE_XSERVER
1357 XARGS_LIMIT
1358 NTLIB
1359 LIB_WSOCK32
1360 LIBS_ECLIENT
1361 CM_OBJ
1362 NTDIR
1363 FIRSTFILE_OBJ
1364 W32_RES_LINK
1365 CLIENTW
1366 CLIENTRES
1367 EMACS_MANIFEST
1368 EMACSRES
1369 W32_LIBS
1370 W32_OBJ
1371 WINDRES
1372 NS_OBJC_OBJ
1373 NS_OBJ
1374 ns_self_contained
1375 INSTALL_ARCH_INDEP_EXTRA
1376 LIBS_GNUSTEP
1377 LD_SWITCH_X_SITE_RPATH
1378 XMKMF
1379 DEPFLAGS
1380 MKDEPDIR
1381 CFLAGS_SOUND
1382 ALSA_LIBS
1383 ALSA_CFLAGS
1384 LIBSOUND
1385 PKG_CONFIG
1386 LIB_MATH
1387 LIBS_SYSTEM
1388 C_SWITCH_SYSTEM
1389 UNEXEC_OBJ
1390 C_SWITCH_MACHINE
1391 LD_SWITCH_SYSTEM
1392 CANNOT_DUMP
1393 INFO_OPTS
1394 INFO_EXT
1395 HAVE_MAKEINFO
1396 PAXCTL
1397 GZIP_PROG
1398 INSTALL_INFO
1399 LN_S_FILEONLY
1400 GNULIB_WARN_CFLAGS
1401 WARN_CFLAGS
1402 WERROR_CFLAGS
1403 RANLIB
1404 ARFLAGS
1406 EGREP
1407 GREP
1409 BUILDING_FOR_WINDOWSNT_FALSE
1410 BUILDING_FOR_WINDOWSNT_TRUE
1411 am__fastdepCC_FALSE
1412 am__fastdepCC_TRUE
1413 CCDEPMODE
1414 AMDEPBACKSLASH
1415 AMDEP_FALSE
1416 AMDEP_TRUE
1417 am__quote
1418 am__include
1419 DEPDIR
1420 OBJEXT
1421 EXEEXT
1422 ac_ct_CC
1423 CPPFLAGS
1424 LDFLAGS
1425 CFLAGS
1427 host_os
1428 host_vendor
1429 host_cpu
1430 host
1431 build_os
1432 build_vendor
1433 build_cpu
1434 build
1435 PROFILING_CFLAGS
1436 GZIP_INFO
1437 cache_file
1438 am__untar
1439 am__tar
1440 AMTAR
1441 am__leading_dot
1442 SET_MAKE
1444 mkdir_p
1445 MKDIR_P
1446 INSTALL_STRIP_PROGRAM
1447 STRIP
1448 install_sh
1449 MAKEINFO
1450 AUTOHEADER
1451 AUTOMAKE
1452 AUTOCONF
1453 ACLOCAL
1454 VERSION
1455 PACKAGE
1456 CYGPATH_W
1457 am__isrc
1458 INSTALL_DATA
1459 INSTALL_SCRIPT
1460 INSTALL_PROGRAM
1461 target_alias
1462 host_alias
1463 build_alias
1464 LIBS
1465 ECHO_T
1466 ECHO_N
1467 ECHO_C
1468 DEFS
1469 mandir
1470 localedir
1471 libdir
1472 psdir
1473 pdfdir
1474 dvidir
1475 htmldir
1476 infodir
1477 docdir
1478 oldincludedir
1479 includedir
1480 localstatedir
1481 sharedstatedir
1482 sysconfdir
1483 datadir
1484 datarootdir
1485 libexecdir
1486 sbindir
1487 bindir
1488 program_transform_name
1489 prefix
1490 exec_prefix
1491 PACKAGE_URL
1492 PACKAGE_BUGREPORT
1493 PACKAGE_STRING
1494 PACKAGE_VERSION
1495 PACKAGE_TARNAME
1496 PACKAGE_NAME
1497 PATH_SEPARATOR
1498 SHELL'
1499 ac_subst_files='deps_frag
1500 lisp_frag'
1501 ac_user_opts='
1502 enable_option_checking
1503 with_all
1504 with_pop
1505 with_kerberos
1506 with_kerberos5
1507 with_hesiod
1508 with_mmdf
1509 with_mail_unlink
1510 with_mailhost
1511 with_sound
1512 with_x_toolkit
1513 with_wide_int
1514 with_xpm
1515 with_jpeg
1516 with_tiff
1517 with_gif
1518 with_png
1519 with_rsvg
1520 with_xml2
1521 with_imagemagick
1522 with_xft
1523 with_libotf
1524 with_m17n_flt
1525 with_toolkit_scroll_bars
1526 with_xaw3d
1527 with_xim
1528 with_ns
1529 with_w32
1530 with_gpm
1531 with_dbus
1532 with_gconf
1533 with_gsettings
1534 with_selinux
1535 with_gnutls
1536 with_file_notification
1537 with_makeinfo
1538 with_compress_info
1539 with_pkg_config_prog
1540 with_gameuser
1541 with_gnustep_conf
1542 enable_ns_self_contained
1543 enable_locallisppath
1544 enable_checking
1545 enable_check_lisp_object_type
1546 enable_profiling
1547 enable_autodepend
1548 enable_gtk_deprecation_warnings
1549 enable_dependency_tracking
1550 enable_largefile
1551 enable_gcc_warnings
1552 enable_link_time_optimization
1553 with_x
1554 enable_acl
1556 ac_precious_vars='build_alias
1557 host_alias
1558 target_alias
1560 CFLAGS
1561 LDFLAGS
1562 LIBS
1563 CPPFLAGS
1565 XMKMF'
1568 # Initialize some variables set by options.
1569 ac_init_help=
1570 ac_init_version=false
1571 ac_unrecognized_opts=
1572 ac_unrecognized_sep=
1573 # The variables have the same names as the options, with
1574 # dashes changed to underlines.
1575 cache_file=/dev/null
1576 exec_prefix=NONE
1577 no_create=
1578 no_recursion=
1579 prefix=NONE
1580 program_prefix=NONE
1581 program_suffix=NONE
1582 program_transform_name=s,x,x,
1583 silent=
1584 site=
1585 srcdir=
1586 verbose=
1587 x_includes=NONE
1588 x_libraries=NONE
1590 # Installation directory options.
1591 # These are left unexpanded so users can "make install exec_prefix=/foo"
1592 # and all the variables that are supposed to be based on exec_prefix
1593 # by default will actually change.
1594 # Use braces instead of parens because sh, perl, etc. also accept them.
1595 # (The list follows the same order as the GNU Coding Standards.)
1596 bindir='${exec_prefix}/bin'
1597 sbindir='${exec_prefix}/sbin'
1598 libexecdir='${exec_prefix}/libexec'
1599 datarootdir='${prefix}/share'
1600 datadir='${datarootdir}'
1601 sysconfdir='${prefix}/etc'
1602 sharedstatedir='${prefix}/com'
1603 localstatedir='${prefix}/var'
1604 includedir='${prefix}/include'
1605 oldincludedir='/usr/include'
1606 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1607 infodir='${datarootdir}/info'
1608 htmldir='${docdir}'
1609 dvidir='${docdir}'
1610 pdfdir='${docdir}'
1611 psdir='${docdir}'
1612 libdir='${exec_prefix}/lib'
1613 localedir='${datarootdir}/locale'
1614 mandir='${datarootdir}/man'
1616 ac_prev=
1617 ac_dashdash=
1618 for ac_option
1620 # If the previous option needs an argument, assign it.
1621 if test -n "$ac_prev"; then
1622 eval $ac_prev=\$ac_option
1623 ac_prev=
1624 continue
1627 case $ac_option in
1628 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1629 *) ac_optarg=yes ;;
1630 esac
1632 # Accept the important Cygnus configure options, so we can diagnose typos.
1634 case $ac_dashdash$ac_option in
1636 ac_dashdash=yes ;;
1638 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1639 ac_prev=bindir ;;
1640 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1641 bindir=$ac_optarg ;;
1643 -build | --build | --buil | --bui | --bu)
1644 ac_prev=build_alias ;;
1645 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1646 build_alias=$ac_optarg ;;
1648 -cache-file | --cache-file | --cache-fil | --cache-fi \
1649 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1650 ac_prev=cache_file ;;
1651 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1652 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1653 cache_file=$ac_optarg ;;
1655 --config-cache | -C)
1656 cache_file=config.cache ;;
1658 -datadir | --datadir | --datadi | --datad)
1659 ac_prev=datadir ;;
1660 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1661 datadir=$ac_optarg ;;
1663 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1664 | --dataroo | --dataro | --datar)
1665 ac_prev=datarootdir ;;
1666 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1667 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1668 datarootdir=$ac_optarg ;;
1670 -disable-* | --disable-*)
1671 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1672 # Reject names that are not valid shell variable names.
1673 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1674 as_fn_error "invalid feature name: $ac_useropt"
1675 ac_useropt_orig=$ac_useropt
1676 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1677 case $ac_user_opts in
1679 "enable_$ac_useropt"
1680 "*) ;;
1681 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1682 ac_unrecognized_sep=', ';;
1683 esac
1684 eval enable_$ac_useropt=no ;;
1686 -docdir | --docdir | --docdi | --doc | --do)
1687 ac_prev=docdir ;;
1688 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1689 docdir=$ac_optarg ;;
1691 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1692 ac_prev=dvidir ;;
1693 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1694 dvidir=$ac_optarg ;;
1696 -enable-* | --enable-*)
1697 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1698 # Reject names that are not valid shell variable names.
1699 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1700 as_fn_error "invalid feature name: $ac_useropt"
1701 ac_useropt_orig=$ac_useropt
1702 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1703 case $ac_user_opts in
1705 "enable_$ac_useropt"
1706 "*) ;;
1707 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1708 ac_unrecognized_sep=', ';;
1709 esac
1710 eval enable_$ac_useropt=\$ac_optarg ;;
1712 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1713 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1714 | --exec | --exe | --ex)
1715 ac_prev=exec_prefix ;;
1716 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1717 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1718 | --exec=* | --exe=* | --ex=*)
1719 exec_prefix=$ac_optarg ;;
1721 -gas | --gas | --ga | --g)
1722 # Obsolete; use --with-gas.
1723 with_gas=yes ;;
1725 -help | --help | --hel | --he | -h)
1726 ac_init_help=long ;;
1727 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1728 ac_init_help=recursive ;;
1729 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1730 ac_init_help=short ;;
1732 -host | --host | --hos | --ho)
1733 ac_prev=host_alias ;;
1734 -host=* | --host=* | --hos=* | --ho=*)
1735 host_alias=$ac_optarg ;;
1737 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1738 ac_prev=htmldir ;;
1739 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1740 | --ht=*)
1741 htmldir=$ac_optarg ;;
1743 -includedir | --includedir | --includedi | --included | --include \
1744 | --includ | --inclu | --incl | --inc)
1745 ac_prev=includedir ;;
1746 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1747 | --includ=* | --inclu=* | --incl=* | --inc=*)
1748 includedir=$ac_optarg ;;
1750 -infodir | --infodir | --infodi | --infod | --info | --inf)
1751 ac_prev=infodir ;;
1752 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1753 infodir=$ac_optarg ;;
1755 -libdir | --libdir | --libdi | --libd)
1756 ac_prev=libdir ;;
1757 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1758 libdir=$ac_optarg ;;
1760 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1761 | --libexe | --libex | --libe)
1762 ac_prev=libexecdir ;;
1763 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1764 | --libexe=* | --libex=* | --libe=*)
1765 libexecdir=$ac_optarg ;;
1767 -localedir | --localedir | --localedi | --localed | --locale)
1768 ac_prev=localedir ;;
1769 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1770 localedir=$ac_optarg ;;
1772 -localstatedir | --localstatedir | --localstatedi | --localstated \
1773 | --localstate | --localstat | --localsta | --localst | --locals)
1774 ac_prev=localstatedir ;;
1775 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1776 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1777 localstatedir=$ac_optarg ;;
1779 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1780 ac_prev=mandir ;;
1781 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1782 mandir=$ac_optarg ;;
1784 -nfp | --nfp | --nf)
1785 # Obsolete; use --without-fp.
1786 with_fp=no ;;
1788 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1789 | --no-cr | --no-c | -n)
1790 no_create=yes ;;
1792 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1793 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1794 no_recursion=yes ;;
1796 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1797 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1798 | --oldin | --oldi | --old | --ol | --o)
1799 ac_prev=oldincludedir ;;
1800 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1801 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1802 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1803 oldincludedir=$ac_optarg ;;
1805 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1806 ac_prev=prefix ;;
1807 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1808 prefix=$ac_optarg ;;
1810 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1811 | --program-pre | --program-pr | --program-p)
1812 ac_prev=program_prefix ;;
1813 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1814 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1815 program_prefix=$ac_optarg ;;
1817 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1818 | --program-suf | --program-su | --program-s)
1819 ac_prev=program_suffix ;;
1820 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1821 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1822 program_suffix=$ac_optarg ;;
1824 -program-transform-name | --program-transform-name \
1825 | --program-transform-nam | --program-transform-na \
1826 | --program-transform-n | --program-transform- \
1827 | --program-transform | --program-transfor \
1828 | --program-transfo | --program-transf \
1829 | --program-trans | --program-tran \
1830 | --progr-tra | --program-tr | --program-t)
1831 ac_prev=program_transform_name ;;
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 program_transform_name=$ac_optarg ;;
1841 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1842 ac_prev=pdfdir ;;
1843 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1844 pdfdir=$ac_optarg ;;
1846 -psdir | --psdir | --psdi | --psd | --ps)
1847 ac_prev=psdir ;;
1848 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1849 psdir=$ac_optarg ;;
1851 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1852 | -silent | --silent | --silen | --sile | --sil)
1853 silent=yes ;;
1855 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1856 ac_prev=sbindir ;;
1857 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1858 | --sbi=* | --sb=*)
1859 sbindir=$ac_optarg ;;
1861 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1862 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1863 | --sharedst | --shareds | --shared | --share | --shar \
1864 | --sha | --sh)
1865 ac_prev=sharedstatedir ;;
1866 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1867 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1868 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1869 | --sha=* | --sh=*)
1870 sharedstatedir=$ac_optarg ;;
1872 -site | --site | --sit)
1873 ac_prev=site ;;
1874 -site=* | --site=* | --sit=*)
1875 site=$ac_optarg ;;
1877 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1878 ac_prev=srcdir ;;
1879 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1880 srcdir=$ac_optarg ;;
1882 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1883 | --syscon | --sysco | --sysc | --sys | --sy)
1884 ac_prev=sysconfdir ;;
1885 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1886 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1887 sysconfdir=$ac_optarg ;;
1889 -target | --target | --targe | --targ | --tar | --ta | --t)
1890 ac_prev=target_alias ;;
1891 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1892 target_alias=$ac_optarg ;;
1894 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1895 verbose=yes ;;
1897 -version | --version | --versio | --versi | --vers | -V)
1898 ac_init_version=: ;;
1900 -with-* | --with-*)
1901 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1902 # Reject names that are not valid shell variable names.
1903 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1904 as_fn_error "invalid package name: $ac_useropt"
1905 ac_useropt_orig=$ac_useropt
1906 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1907 case $ac_user_opts in
1909 "with_$ac_useropt"
1910 "*) ;;
1911 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1912 ac_unrecognized_sep=', ';;
1913 esac
1914 eval with_$ac_useropt=\$ac_optarg ;;
1916 -without-* | --without-*)
1917 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1918 # Reject names that are not valid shell variable names.
1919 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1920 as_fn_error "invalid package name: $ac_useropt"
1921 ac_useropt_orig=$ac_useropt
1922 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1923 case $ac_user_opts in
1925 "with_$ac_useropt"
1926 "*) ;;
1927 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1928 ac_unrecognized_sep=', ';;
1929 esac
1930 eval with_$ac_useropt=no ;;
1932 --x)
1933 # Obsolete; use --with-x.
1934 with_x=yes ;;
1936 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1937 | --x-incl | --x-inc | --x-in | --x-i)
1938 ac_prev=x_includes ;;
1939 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1940 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1941 x_includes=$ac_optarg ;;
1943 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1944 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1945 ac_prev=x_libraries ;;
1946 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1947 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1948 x_libraries=$ac_optarg ;;
1950 -*) as_fn_error "unrecognized option: \`$ac_option'
1951 Try \`$0 --help' for more information."
1954 *=*)
1955 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1956 # Reject names that are not valid shell variable names.
1957 case $ac_envvar in #(
1958 '' | [0-9]* | *[!_$as_cr_alnum]* )
1959 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1960 esac
1961 eval $ac_envvar=\$ac_optarg
1962 export $ac_envvar ;;
1965 # FIXME: should be removed in autoconf 3.0.
1966 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1967 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1968 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1969 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1972 esac
1973 done
1975 if test -n "$ac_prev"; then
1976 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1977 as_fn_error "missing argument to $ac_option"
1980 if test -n "$ac_unrecognized_opts"; then
1981 case $enable_option_checking in
1982 no) ;;
1983 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1984 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1985 esac
1988 # Check all directory arguments for consistency.
1989 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1990 datadir sysconfdir sharedstatedir localstatedir includedir \
1991 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1992 libdir localedir mandir
1994 eval ac_val=\$$ac_var
1995 # Remove trailing slashes.
1996 case $ac_val in
1997 */ )
1998 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1999 eval $ac_var=\$ac_val;;
2000 esac
2001 # Be sure to have absolute directory names.
2002 case $ac_val in
2003 [\\/$]* | ?:[\\/]* ) continue;;
2004 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2005 esac
2006 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2007 done
2009 # There might be people who depend on the old broken behavior: `$host'
2010 # used to hold the argument of --host etc.
2011 # FIXME: To remove some day.
2012 build=$build_alias
2013 host=$host_alias
2014 target=$target_alias
2016 # FIXME: To remove some day.
2017 if test "x$host_alias" != x; then
2018 if test "x$build_alias" = x; then
2019 cross_compiling=maybe
2020 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2021 If a cross compiler is detected then cross compile mode will be used." >&2
2022 elif test "x$build_alias" != "x$host_alias"; then
2023 cross_compiling=yes
2027 ac_tool_prefix=
2028 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2030 test "$silent" = yes && exec 6>/dev/null
2033 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2034 ac_ls_di=`ls -di .` &&
2035 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2036 as_fn_error "working directory cannot be determined"
2037 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2038 as_fn_error "pwd does not report name of working directory"
2041 # Find the source files, if location was not specified.
2042 if test -z "$srcdir"; then
2043 ac_srcdir_defaulted=yes
2044 # Try the directory containing this script, then the parent directory.
2045 ac_confdir=`$as_dirname -- "$as_myself" ||
2046 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2047 X"$as_myself" : 'X\(//\)[^/]' \| \
2048 X"$as_myself" : 'X\(//\)$' \| \
2049 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2050 $as_echo X"$as_myself" |
2051 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2052 s//\1/
2055 /^X\(\/\/\)[^/].*/{
2056 s//\1/
2059 /^X\(\/\/\)$/{
2060 s//\1/
2063 /^X\(\/\).*/{
2064 s//\1/
2067 s/.*/./; q'`
2068 srcdir=$ac_confdir
2069 if test ! -r "$srcdir/$ac_unique_file"; then
2070 srcdir=..
2072 else
2073 ac_srcdir_defaulted=no
2075 if test ! -r "$srcdir/$ac_unique_file"; then
2076 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2077 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2079 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2080 ac_abs_confdir=`(
2081 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2082 pwd)`
2083 # When building in place, set srcdir=.
2084 if test "$ac_abs_confdir" = "$ac_pwd"; then
2085 srcdir=.
2087 # Remove unnecessary trailing slashes from srcdir.
2088 # Double slashes in file names in object file debugging info
2089 # mess up M-x gdb in Emacs.
2090 case $srcdir in
2091 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2092 esac
2093 for ac_var in $ac_precious_vars; do
2094 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2095 eval ac_env_${ac_var}_value=\$${ac_var}
2096 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2097 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2098 done
2101 # Report the --help message.
2103 if test "$ac_init_help" = "long"; then
2104 # Omit some internal or obsolete options to make the list less imposing.
2105 # This message is too long to be a string in the A/UX 3.1 sh.
2106 cat <<_ACEOF
2107 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
2109 Usage: $0 [OPTION]... [VAR=VALUE]...
2111 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2112 VAR=VALUE. See below for descriptions of some of the useful variables.
2114 Defaults for the options are specified in brackets.
2116 Configuration:
2117 -h, --help display this help and exit
2118 --help=short display options specific to this package
2119 --help=recursive display the short help of all the included packages
2120 -V, --version display version information and exit
2121 -q, --quiet, --silent do not print \`checking...' messages
2122 --cache-file=FILE cache test results in FILE [disabled]
2123 -C, --config-cache alias for \`--cache-file=config.cache'
2124 -n, --no-create do not create output files
2125 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2127 Installation directories:
2128 --prefix=PREFIX install architecture-independent files in PREFIX
2129 [$ac_default_prefix]
2130 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2131 [PREFIX]
2133 By default, \`make install' will install all the files in
2134 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2135 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2136 for instance \`--prefix=\$HOME'.
2138 For better control, use the options below.
2140 Fine tuning of the installation directories:
2141 --bindir=DIR user executables [EPREFIX/bin]
2142 --sbindir=DIR system admin executables [EPREFIX/sbin]
2143 --libexecdir=DIR program executables [EPREFIX/libexec]
2144 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2145 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2146 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2147 --libdir=DIR object code libraries [EPREFIX/lib]
2148 --includedir=DIR C header files [PREFIX/include]
2149 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2150 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2151 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2152 --infodir=DIR info documentation [DATAROOTDIR/info]
2153 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2154 --mandir=DIR man documentation [DATAROOTDIR/man]
2155 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2156 --htmldir=DIR html documentation [DOCDIR]
2157 --dvidir=DIR dvi documentation [DOCDIR]
2158 --pdfdir=DIR pdf documentation [DOCDIR]
2159 --psdir=DIR ps documentation [DOCDIR]
2160 _ACEOF
2162 cat <<\_ACEOF
2164 Program names:
2165 --program-prefix=PREFIX prepend PREFIX to installed program names
2166 --program-suffix=SUFFIX append SUFFIX to installed program names
2167 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2169 X features:
2170 --x-includes=DIR X include files are in DIR
2171 --x-libraries=DIR X library files are in DIR
2173 System types:
2174 --build=BUILD configure for building on BUILD [guessed]
2175 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2176 _ACEOF
2179 if test -n "$ac_init_help"; then
2180 case $ac_init_help in
2181 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2182 esac
2183 cat <<\_ACEOF
2185 Optional Features:
2186 --disable-option-checking ignore unrecognized --enable/--with options
2187 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2188 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2189 --disable-ns-self-contained
2190 disable self contained build under NeXTstep
2191 --enable-locallisppath=PATH
2192 directories Emacs should search for lisp files
2193 specific to this site
2194 --enable-checking[=LIST]
2195 enable expensive run-time checks. With LIST, enable
2196 only specific categories of checks. Categories are:
2197 all,yes,no. Flags are: stringbytes, stringoverrun,
2198 stringfreelist, xmallocoverrun, conslist, glyphs
2199 --enable-check-lisp-object-type
2200 enable compile time checks for the Lisp_Object data
2201 type. This is useful for development for catching
2202 certain types of bugs.
2203 --enable-profiling build emacs with low-level, gprof profiling support.
2204 Mainly useful for debugging Emacs itself. May not
2205 work on all platforms. Stops profiler.el working.
2206 --enable-autodepend automatically generate dependencies to .h-files.
2207 Requires GNU Make and Gcc. Enabled if GNU Make and
2208 Gcc is found
2209 --enable-gtk-deprecation-warnings
2210 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2211 --disable-dependency-tracking speeds up one-time build
2212 --enable-dependency-tracking do not reject slow dependency extractors
2213 --disable-largefile omit support for large files
2214 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2215 intended for developers, and may generate false
2216 alarms when used with older or non-GNU development
2217 tools.
2218 --enable-link-time-optimization
2219 build emacs with link-time optimization. This is
2220 supported only for GCC since 4.5.0.
2221 --disable-acl do not support ACLs
2223 Optional Packages:
2224 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2225 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2226 --without-all omit almost all features and build small executable
2227 with minimal dependencies
2228 --without-pop don't support POP mail retrieval with movemail
2229 --with-kerberos support Kerberos-authenticated POP
2230 --with-kerberos5 support Kerberos version 5 authenticated POP
2231 --with-hesiod support Hesiod to get the POP server host
2232 --with-mmdf support MMDF mailboxes
2233 --with-mail-unlink unlink, rather than empty, mail spool after reading
2234 --with-mailhost=HOSTNAME
2235 string giving default POP mail host
2236 --without-sound don't compile with sound support
2237 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2238 gtk3, lucid or athena, motif, no)
2239 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2240 --without-xpm don't compile with XPM image support
2241 --without-jpeg don't compile with JPEG image support
2242 --without-tiff don't compile with TIFF image support
2243 --without-gif don't compile with GIF image support
2244 --without-png don't compile with PNG image support
2245 --without-rsvg don't compile with SVG image support
2246 --without-xml2 don't compile with XML parsing support
2247 --without-imagemagick don't compile with ImageMagick image support
2248 --without-xft don't use XFT for anti aliased fonts
2249 --without-libotf don't use libotf for OpenType font support
2250 --without-m17n-flt don't use m17n-flt for text shaping
2251 --without-toolkit-scroll-bars
2252 don't use Motif or Xaw3d scroll bars
2253 --without-xaw3d don't use Xaw3d
2254 --without-xim don't use X11 XIM
2255 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2256 --with-w32 use native MS Windows GUI in a Cygwin build
2257 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2258 console
2259 --without-dbus don't compile with D-Bus support
2260 --without-gconf don't compile with GConf support
2261 --without-gsettings don't compile with GSettings support
2262 --without-selinux don't compile with SELinux support
2263 --without-gnutls don't use -lgnutls for SSL/TLS support
2264 --with-file-notification=LIB
2265 use a file notification library (LIB one of: yes,
2266 gfile, inotify, w32, no)
2267 --without-makeinfo don't require makeinfo for building manuals
2268 --without-compress-info don't compress the installed Info pages
2269 --with-pkg-config-prog=FILENAME
2270 file name of pkg-config for finding GTK and librsvg
2271 --with-gameuser=USER user for shared game score files
2272 --with-gnustep-conf=FILENAME
2273 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2274 or /etc/GNUstep/GNUstep.conf
2275 --with-x use the X Window System
2277 Some influential environment variables:
2278 CC C compiler command
2279 CFLAGS C compiler flags
2280 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2281 nonstandard directory <lib dir>
2282 LIBS libraries to pass to the linker, e.g. -l<library>
2283 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2284 you have headers in a nonstandard directory <include dir>
2285 CPP C preprocessor
2286 XMKMF Path to xmkmf, Makefile generator for X Window System
2288 Use these variables to override the choices made by `configure' or to help
2289 it to find libraries and programs with nonstandard names/locations.
2291 Report bugs to the package provider.
2292 _ACEOF
2293 ac_status=$?
2296 if test "$ac_init_help" = "recursive"; then
2297 # If there are subdirs, report their specific --help.
2298 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2299 test -d "$ac_dir" ||
2300 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2301 continue
2302 ac_builddir=.
2304 case "$ac_dir" in
2305 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2307 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2308 # A ".." for each directory in $ac_dir_suffix.
2309 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2310 case $ac_top_builddir_sub in
2311 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2312 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2313 esac ;;
2314 esac
2315 ac_abs_top_builddir=$ac_pwd
2316 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2317 # for backward compatibility:
2318 ac_top_builddir=$ac_top_build_prefix
2320 case $srcdir in
2321 .) # We are building in place.
2322 ac_srcdir=.
2323 ac_top_srcdir=$ac_top_builddir_sub
2324 ac_abs_top_srcdir=$ac_pwd ;;
2325 [\\/]* | ?:[\\/]* ) # Absolute name.
2326 ac_srcdir=$srcdir$ac_dir_suffix;
2327 ac_top_srcdir=$srcdir
2328 ac_abs_top_srcdir=$srcdir ;;
2329 *) # Relative name.
2330 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2331 ac_top_srcdir=$ac_top_build_prefix$srcdir
2332 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2333 esac
2334 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2336 cd "$ac_dir" || { ac_status=$?; continue; }
2337 # Check for guested configure.
2338 if test -f "$ac_srcdir/configure.gnu"; then
2339 echo &&
2340 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2341 elif test -f "$ac_srcdir/configure"; then
2342 echo &&
2343 $SHELL "$ac_srcdir/configure" --help=recursive
2344 else
2345 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2346 fi || ac_status=$?
2347 cd "$ac_pwd" || { ac_status=$?; break; }
2348 done
2351 test -n "$ac_init_help" && exit $ac_status
2352 if $ac_init_version; then
2353 cat <<\_ACEOF
2354 emacs configure 24.3.50
2355 generated by GNU Autoconf 2.65
2357 Copyright (C) 2009 Free Software Foundation, Inc.
2358 This configure script is free software; the Free Software Foundation
2359 gives unlimited permission to copy, distribute and modify it.
2360 _ACEOF
2361 exit
2364 ## ------------------------ ##
2365 ## Autoconf initialization. ##
2366 ## ------------------------ ##
2368 # ac_fn_c_try_compile LINENO
2369 # --------------------------
2370 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2371 ac_fn_c_try_compile ()
2373 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2374 rm -f conftest.$ac_objext
2375 if { { ac_try="$ac_compile"
2376 case "(($ac_try" in
2377 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2378 *) ac_try_echo=$ac_try;;
2379 esac
2380 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2381 $as_echo "$ac_try_echo"; } >&5
2382 (eval "$ac_compile") 2>conftest.err
2383 ac_status=$?
2384 if test -s conftest.err; then
2385 grep -v '^ *+' conftest.err >conftest.er1
2386 cat conftest.er1 >&5
2387 mv -f conftest.er1 conftest.err
2389 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2390 test $ac_status = 0; } && {
2391 test -z "$ac_c_werror_flag" ||
2392 test ! -s conftest.err
2393 } && test -s conftest.$ac_objext; then :
2394 ac_retval=0
2395 else
2396 $as_echo "$as_me: failed program was:" >&5
2397 sed 's/^/| /' conftest.$ac_ext >&5
2399 ac_retval=1
2401 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2402 as_fn_set_status $ac_retval
2404 } # ac_fn_c_try_compile
2406 # ac_fn_c_try_cpp LINENO
2407 # ----------------------
2408 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2409 ac_fn_c_try_cpp ()
2411 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2412 if { { ac_try="$ac_cpp conftest.$ac_ext"
2413 case "(($ac_try" in
2414 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2415 *) ac_try_echo=$ac_try;;
2416 esac
2417 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2418 $as_echo "$ac_try_echo"; } >&5
2419 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2420 ac_status=$?
2421 if test -s conftest.err; then
2422 grep -v '^ *+' conftest.err >conftest.er1
2423 cat conftest.er1 >&5
2424 mv -f conftest.er1 conftest.err
2426 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2427 test $ac_status = 0; } >/dev/null && {
2428 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2429 test ! -s conftest.err
2430 }; then :
2431 ac_retval=0
2432 else
2433 $as_echo "$as_me: failed program was:" >&5
2434 sed 's/^/| /' conftest.$ac_ext >&5
2436 ac_retval=1
2438 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2439 as_fn_set_status $ac_retval
2441 } # ac_fn_c_try_cpp
2443 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2444 # -------------------------------------------------------
2445 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2446 # the include files in INCLUDES and setting the cache variable VAR
2447 # accordingly.
2448 ac_fn_c_check_header_mongrel ()
2450 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2451 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2453 $as_echo_n "checking for $2... " >&6; }
2454 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2455 $as_echo_n "(cached) " >&6
2457 eval ac_res=\$$3
2458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2459 $as_echo "$ac_res" >&6; }
2460 else
2461 # Is the header compilable?
2462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2463 $as_echo_n "checking $2 usability... " >&6; }
2464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2465 /* end confdefs.h. */
2467 #include <$2>
2468 _ACEOF
2469 if ac_fn_c_try_compile "$LINENO"; then :
2470 ac_header_compiler=yes
2471 else
2472 ac_header_compiler=no
2474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2476 $as_echo "$ac_header_compiler" >&6; }
2478 # Is the header present?
2479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2480 $as_echo_n "checking $2 presence... " >&6; }
2481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2482 /* end confdefs.h. */
2483 #include <$2>
2484 _ACEOF
2485 if ac_fn_c_try_cpp "$LINENO"; then :
2486 ac_header_preproc=yes
2487 else
2488 ac_header_preproc=no
2490 rm -f conftest.err conftest.$ac_ext
2491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2492 $as_echo "$ac_header_preproc" >&6; }
2494 # So? What about this header?
2495 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2496 yes:no: )
2497 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2498 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2500 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2502 no:yes:* )
2503 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2504 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2505 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2506 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2507 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2508 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2509 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2510 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2512 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2514 esac
2515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2516 $as_echo_n "checking for $2... " >&6; }
2517 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2518 $as_echo_n "(cached) " >&6
2519 else
2520 eval "$3=\$ac_header_compiler"
2522 eval ac_res=\$$3
2523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2524 $as_echo "$ac_res" >&6; }
2526 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2528 } # ac_fn_c_check_header_mongrel
2530 # ac_fn_c_try_run LINENO
2531 # ----------------------
2532 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2533 # that executables *can* be run.
2534 ac_fn_c_try_run ()
2536 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2537 if { { ac_try="$ac_link"
2538 case "(($ac_try" in
2539 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2540 *) ac_try_echo=$ac_try;;
2541 esac
2542 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2543 $as_echo "$ac_try_echo"; } >&5
2544 (eval "$ac_link") 2>&5
2545 ac_status=$?
2546 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2547 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2548 { { case "(($ac_try" in
2549 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2550 *) ac_try_echo=$ac_try;;
2551 esac
2552 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2553 $as_echo "$ac_try_echo"; } >&5
2554 (eval "$ac_try") 2>&5
2555 ac_status=$?
2556 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2557 test $ac_status = 0; }; }; then :
2558 ac_retval=0
2559 else
2560 $as_echo "$as_me: program exited with status $ac_status" >&5
2561 $as_echo "$as_me: failed program was:" >&5
2562 sed 's/^/| /' conftest.$ac_ext >&5
2564 ac_retval=$ac_status
2566 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2567 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2568 as_fn_set_status $ac_retval
2570 } # ac_fn_c_try_run
2572 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2573 # -------------------------------------------------------
2574 # Tests whether HEADER exists and can be compiled using the include files in
2575 # INCLUDES, setting the cache variable VAR accordingly.
2576 ac_fn_c_check_header_compile ()
2578 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2580 $as_echo_n "checking for $2... " >&6; }
2581 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2582 $as_echo_n "(cached) " >&6
2583 else
2584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2585 /* end confdefs.h. */
2587 #include <$2>
2588 _ACEOF
2589 if ac_fn_c_try_compile "$LINENO"; then :
2590 eval "$3=yes"
2591 else
2592 eval "$3=no"
2594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2596 eval ac_res=\$$3
2597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2598 $as_echo "$ac_res" >&6; }
2599 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2601 } # ac_fn_c_check_header_compile
2603 # ac_fn_c_try_link LINENO
2604 # -----------------------
2605 # Try to link conftest.$ac_ext, and return whether this succeeded.
2606 ac_fn_c_try_link ()
2608 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2609 rm -f conftest.$ac_objext conftest$ac_exeext
2610 if { { ac_try="$ac_link"
2611 case "(($ac_try" in
2612 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2613 *) ac_try_echo=$ac_try;;
2614 esac
2615 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2616 $as_echo "$ac_try_echo"; } >&5
2617 (eval "$ac_link") 2>conftest.err
2618 ac_status=$?
2619 if test -s conftest.err; then
2620 grep -v '^ *+' conftest.err >conftest.er1
2621 cat conftest.er1 >&5
2622 mv -f conftest.er1 conftest.err
2624 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2625 test $ac_status = 0; } && {
2626 test -z "$ac_c_werror_flag" ||
2627 test ! -s conftest.err
2628 } && test -s conftest$ac_exeext && {
2629 test "$cross_compiling" = yes ||
2630 $as_test_x conftest$ac_exeext
2631 }; then :
2632 ac_retval=0
2633 else
2634 $as_echo "$as_me: failed program was:" >&5
2635 sed 's/^/| /' conftest.$ac_ext >&5
2637 ac_retval=1
2639 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2640 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2641 # interfere with the next link command; also delete a directory that is
2642 # left behind by Apple's compiler. We do this before executing the actions.
2643 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2644 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2645 as_fn_set_status $ac_retval
2647 } # ac_fn_c_try_link
2649 # ac_fn_c_check_decl LINENO SYMBOL VAR
2650 # ------------------------------------
2651 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2652 ac_fn_c_check_decl ()
2654 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2656 $as_echo_n "checking whether $2 is declared... " >&6; }
2657 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2658 $as_echo_n "(cached) " >&6
2659 else
2660 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2661 /* end confdefs.h. */
2664 main ()
2666 #ifndef $2
2667 (void) $2;
2668 #endif
2671 return 0;
2673 _ACEOF
2674 if ac_fn_c_try_compile "$LINENO"; then :
2675 eval "$3=yes"
2676 else
2677 eval "$3=no"
2679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2681 eval ac_res=\$$3
2682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2683 $as_echo "$ac_res" >&6; }
2684 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2686 } # ac_fn_c_check_decl
2688 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2689 # ----------------------------------------------
2690 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2691 ac_fn_c_check_header_preproc ()
2693 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2695 $as_echo_n "checking for $2... " >&6; }
2696 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2697 $as_echo_n "(cached) " >&6
2698 else
2699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2700 /* end confdefs.h. */
2701 #include <$2>
2702 _ACEOF
2703 if ac_fn_c_try_cpp "$LINENO"; then :
2704 eval "$3=yes"
2705 else
2706 eval "$3=no"
2708 rm -f conftest.err conftest.$ac_ext
2710 eval ac_res=\$$3
2711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2712 $as_echo "$ac_res" >&6; }
2713 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2715 } # ac_fn_c_check_header_preproc
2717 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2718 # ----------------------------------------------------
2719 # Tries to find if the field MEMBER exists in type AGGR, after including
2720 # INCLUDES, setting cache variable VAR accordingly.
2721 ac_fn_c_check_member ()
2723 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2725 $as_echo_n "checking for $2.$3... " >&6; }
2726 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2727 $as_echo_n "(cached) " >&6
2728 else
2729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2730 /* end confdefs.h. */
2733 main ()
2735 static $2 ac_aggr;
2736 if (ac_aggr.$3)
2737 return 0;
2739 return 0;
2741 _ACEOF
2742 if ac_fn_c_try_compile "$LINENO"; then :
2743 eval "$4=yes"
2744 else
2745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2746 /* end confdefs.h. */
2749 main ()
2751 static $2 ac_aggr;
2752 if (sizeof ac_aggr.$3)
2753 return 0;
2755 return 0;
2757 _ACEOF
2758 if ac_fn_c_try_compile "$LINENO"; then :
2759 eval "$4=yes"
2760 else
2761 eval "$4=no"
2763 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2767 eval ac_res=\$$4
2768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2769 $as_echo "$ac_res" >&6; }
2770 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2772 } # ac_fn_c_check_member
2774 # ac_fn_c_check_func LINENO FUNC VAR
2775 # ----------------------------------
2776 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2777 ac_fn_c_check_func ()
2779 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2781 $as_echo_n "checking for $2... " >&6; }
2782 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2783 $as_echo_n "(cached) " >&6
2784 else
2785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2786 /* end confdefs.h. */
2787 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2788 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2789 #define $2 innocuous_$2
2791 /* System header to define __stub macros and hopefully few prototypes,
2792 which can conflict with char $2 (); below.
2793 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2794 <limits.h> exists even on freestanding compilers. */
2796 #ifdef __STDC__
2797 # include <limits.h>
2798 #else
2799 # include <assert.h>
2800 #endif
2802 #undef $2
2804 /* Override any GCC internal prototype to avoid an error.
2805 Use char because int might match the return type of a GCC
2806 builtin and then its argument prototype would still apply. */
2807 #ifdef __cplusplus
2808 extern "C"
2809 #endif
2810 char $2 ();
2811 /* The GNU C library defines this for functions which it implements
2812 to always fail with ENOSYS. Some functions are actually named
2813 something starting with __ and the normal name is an alias. */
2814 #if defined __stub_$2 || defined __stub___$2
2815 choke me
2816 #endif
2819 main ()
2821 return $2 ();
2823 return 0;
2825 _ACEOF
2826 if ac_fn_c_try_link "$LINENO"; then :
2827 eval "$3=yes"
2828 else
2829 eval "$3=no"
2831 rm -f core conftest.err conftest.$ac_objext \
2832 conftest$ac_exeext conftest.$ac_ext
2834 eval ac_res=\$$3
2835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2836 $as_echo "$ac_res" >&6; }
2837 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2839 } # ac_fn_c_check_func
2841 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2842 # -------------------------------------------
2843 # Tests whether TYPE exists after having included INCLUDES, setting cache
2844 # variable VAR accordingly.
2845 ac_fn_c_check_type ()
2847 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2849 $as_echo_n "checking for $2... " >&6; }
2850 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2851 $as_echo_n "(cached) " >&6
2852 else
2853 eval "$3=no"
2854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2855 /* end confdefs.h. */
2858 main ()
2860 if (sizeof ($2))
2861 return 0;
2863 return 0;
2865 _ACEOF
2866 if ac_fn_c_try_compile "$LINENO"; then :
2867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2868 /* end confdefs.h. */
2871 main ()
2873 if (sizeof (($2)))
2874 return 0;
2876 return 0;
2878 _ACEOF
2879 if ac_fn_c_try_compile "$LINENO"; then :
2881 else
2882 eval "$3=yes"
2884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2886 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2888 eval ac_res=\$$3
2889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2890 $as_echo "$ac_res" >&6; }
2891 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2893 } # ac_fn_c_check_type
2895 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2896 # --------------------------------------------
2897 # Tries to find the compile-time value of EXPR in a program that includes
2898 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2899 # computed
2900 ac_fn_c_compute_int ()
2902 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2903 if test "$cross_compiling" = yes; then
2904 # Depending upon the size, compute the lo and hi bounds.
2905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2906 /* end confdefs.h. */
2909 main ()
2911 static int test_array [1 - 2 * !(($2) >= 0)];
2912 test_array [0] = 0
2915 return 0;
2917 _ACEOF
2918 if ac_fn_c_try_compile "$LINENO"; then :
2919 ac_lo=0 ac_mid=0
2920 while :; do
2921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2922 /* end confdefs.h. */
2925 main ()
2927 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2928 test_array [0] = 0
2931 return 0;
2933 _ACEOF
2934 if ac_fn_c_try_compile "$LINENO"; then :
2935 ac_hi=$ac_mid; break
2936 else
2937 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2938 if test $ac_lo -le $ac_mid; then
2939 ac_lo= ac_hi=
2940 break
2942 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2945 done
2946 else
2947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2948 /* end confdefs.h. */
2951 main ()
2953 static int test_array [1 - 2 * !(($2) < 0)];
2954 test_array [0] = 0
2957 return 0;
2959 _ACEOF
2960 if ac_fn_c_try_compile "$LINENO"; then :
2961 ac_hi=-1 ac_mid=-1
2962 while :; do
2963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2964 /* end confdefs.h. */
2967 main ()
2969 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2970 test_array [0] = 0
2973 return 0;
2975 _ACEOF
2976 if ac_fn_c_try_compile "$LINENO"; then :
2977 ac_lo=$ac_mid; break
2978 else
2979 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2980 if test $ac_mid -le $ac_hi; then
2981 ac_lo= ac_hi=
2982 break
2984 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2986 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2987 done
2988 else
2989 ac_lo= ac_hi=
2991 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2994 # Binary search between lo and hi bounds.
2995 while test "x$ac_lo" != "x$ac_hi"; do
2996 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2998 /* end confdefs.h. */
3001 main ()
3003 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3004 test_array [0] = 0
3007 return 0;
3009 _ACEOF
3010 if ac_fn_c_try_compile "$LINENO"; then :
3011 ac_hi=$ac_mid
3012 else
3013 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3016 done
3017 case $ac_lo in #((
3018 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3019 '') ac_retval=1 ;;
3020 esac
3021 else
3022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3023 /* end confdefs.h. */
3025 static long int longval () { return $2; }
3026 static unsigned long int ulongval () { return $2; }
3027 #include <stdio.h>
3028 #include <stdlib.h>
3030 main ()
3033 FILE *f = fopen ("conftest.val", "w");
3034 if (! f)
3035 return 1;
3036 if (($2) < 0)
3038 long int i = longval ();
3039 if (i != ($2))
3040 return 1;
3041 fprintf (f, "%ld", i);
3043 else
3045 unsigned long int i = ulongval ();
3046 if (i != ($2))
3047 return 1;
3048 fprintf (f, "%lu", i);
3050 /* Do not output a trailing newline, as this causes \r\n confusion
3051 on some platforms. */
3052 return ferror (f) || fclose (f) != 0;
3055 return 0;
3057 _ACEOF
3058 if ac_fn_c_try_run "$LINENO"; then :
3059 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3060 else
3061 ac_retval=1
3063 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3064 conftest.$ac_objext conftest.beam conftest.$ac_ext
3065 rm -f conftest.val
3068 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3069 as_fn_set_status $ac_retval
3071 } # ac_fn_c_compute_int
3072 cat >config.log <<_ACEOF
3073 This file contains any messages produced by compilers while
3074 running configure, to aid debugging if configure makes a mistake.
3076 It was created by emacs $as_me 24.3.50, which was
3077 generated by GNU Autoconf 2.65. Invocation command line was
3079 $ $0 $@
3081 _ACEOF
3082 exec 5>>config.log
3084 cat <<_ASUNAME
3085 ## --------- ##
3086 ## Platform. ##
3087 ## --------- ##
3089 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3090 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3091 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3092 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3093 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3095 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3096 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3098 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3099 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3100 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3101 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3102 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3103 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3104 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3106 _ASUNAME
3108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3109 for as_dir in $PATH
3111 IFS=$as_save_IFS
3112 test -z "$as_dir" && as_dir=.
3113 $as_echo "PATH: $as_dir"
3114 done
3115 IFS=$as_save_IFS
3117 } >&5
3119 cat >&5 <<_ACEOF
3122 ## ----------- ##
3123 ## Core tests. ##
3124 ## ----------- ##
3126 _ACEOF
3129 # Keep a trace of the command line.
3130 # Strip out --no-create and --no-recursion so they do not pile up.
3131 # Strip out --silent because we don't want to record it for future runs.
3132 # Also quote any args containing shell meta-characters.
3133 # Make two passes to allow for proper duplicate-argument suppression.
3134 ac_configure_args=
3135 ac_configure_args0=
3136 ac_configure_args1=
3137 ac_must_keep_next=false
3138 for ac_pass in 1 2
3140 for ac_arg
3142 case $ac_arg in
3143 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3144 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3145 | -silent | --silent | --silen | --sile | --sil)
3146 continue ;;
3147 *\'*)
3148 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3149 esac
3150 case $ac_pass in
3151 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3153 as_fn_append ac_configure_args1 " '$ac_arg'"
3154 if test $ac_must_keep_next = true; then
3155 ac_must_keep_next=false # Got value, back to normal.
3156 else
3157 case $ac_arg in
3158 *=* | --config-cache | -C | -disable-* | --disable-* \
3159 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3160 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3161 | -with-* | --with-* | -without-* | --without-* | --x)
3162 case "$ac_configure_args0 " in
3163 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3164 esac
3166 -* ) ac_must_keep_next=true ;;
3167 esac
3169 as_fn_append ac_configure_args " '$ac_arg'"
3171 esac
3172 done
3173 done
3174 { ac_configure_args0=; unset ac_configure_args0;}
3175 { ac_configure_args1=; unset ac_configure_args1;}
3177 # When interrupted or exit'd, cleanup temporary files, and complete
3178 # config.log. We remove comments because anyway the quotes in there
3179 # would cause problems or look ugly.
3180 # WARNING: Use '\'' to represent an apostrophe within the trap.
3181 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3182 trap 'exit_status=$?
3183 # Save into config.log some information that might help in debugging.
3185 echo
3187 cat <<\_ASBOX
3188 ## ---------------- ##
3189 ## Cache variables. ##
3190 ## ---------------- ##
3191 _ASBOX
3192 echo
3193 # The following way of writing the cache mishandles newlines in values,
3195 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3196 eval ac_val=\$$ac_var
3197 case $ac_val in #(
3198 *${as_nl}*)
3199 case $ac_var in #(
3200 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3201 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3202 esac
3203 case $ac_var in #(
3204 _ | IFS | as_nl) ;; #(
3205 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3206 *) { eval $ac_var=; unset $ac_var;} ;;
3207 esac ;;
3208 esac
3209 done
3210 (set) 2>&1 |
3211 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3212 *${as_nl}ac_space=\ *)
3213 sed -n \
3214 "s/'\''/'\''\\\\'\'''\''/g;
3215 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3216 ;; #(
3218 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3220 esac |
3221 sort
3223 echo
3225 cat <<\_ASBOX
3226 ## ----------------- ##
3227 ## Output variables. ##
3228 ## ----------------- ##
3229 _ASBOX
3230 echo
3231 for ac_var in $ac_subst_vars
3233 eval ac_val=\$$ac_var
3234 case $ac_val in
3235 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3236 esac
3237 $as_echo "$ac_var='\''$ac_val'\''"
3238 done | sort
3239 echo
3241 if test -n "$ac_subst_files"; then
3242 cat <<\_ASBOX
3243 ## ------------------- ##
3244 ## File substitutions. ##
3245 ## ------------------- ##
3246 _ASBOX
3247 echo
3248 for ac_var in $ac_subst_files
3250 eval ac_val=\$$ac_var
3251 case $ac_val in
3252 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3253 esac
3254 $as_echo "$ac_var='\''$ac_val'\''"
3255 done | sort
3256 echo
3259 if test -s confdefs.h; then
3260 cat <<\_ASBOX
3261 ## ----------- ##
3262 ## confdefs.h. ##
3263 ## ----------- ##
3264 _ASBOX
3265 echo
3266 cat confdefs.h
3267 echo
3269 test "$ac_signal" != 0 &&
3270 $as_echo "$as_me: caught signal $ac_signal"
3271 $as_echo "$as_me: exit $exit_status"
3272 } >&5
3273 rm -f core *.core core.conftest.* &&
3274 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3275 exit $exit_status
3277 for ac_signal in 1 2 13 15; do
3278 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3279 done
3280 ac_signal=0
3282 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3283 rm -f -r conftest* confdefs.h
3285 $as_echo "/* confdefs.h */" > confdefs.h
3287 # Predefined preprocessor variables.
3289 cat >>confdefs.h <<_ACEOF
3290 #define PACKAGE_NAME "$PACKAGE_NAME"
3291 _ACEOF
3293 cat >>confdefs.h <<_ACEOF
3294 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3295 _ACEOF
3297 cat >>confdefs.h <<_ACEOF
3298 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3299 _ACEOF
3301 cat >>confdefs.h <<_ACEOF
3302 #define PACKAGE_STRING "$PACKAGE_STRING"
3303 _ACEOF
3305 cat >>confdefs.h <<_ACEOF
3306 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3307 _ACEOF
3309 cat >>confdefs.h <<_ACEOF
3310 #define PACKAGE_URL "$PACKAGE_URL"
3311 _ACEOF
3314 # Let the site file select an alternate cache file if it wants to.
3315 # Prefer an explicitly selected file to automatically selected ones.
3316 ac_site_file1=NONE
3317 ac_site_file2=NONE
3318 if test -n "$CONFIG_SITE"; then
3319 ac_site_file1=$CONFIG_SITE
3320 elif test "x$prefix" != xNONE; then
3321 ac_site_file1=$prefix/share/config.site
3322 ac_site_file2=$prefix/etc/config.site
3323 else
3324 ac_site_file1=$ac_default_prefix/share/config.site
3325 ac_site_file2=$ac_default_prefix/etc/config.site
3327 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3329 test "x$ac_site_file" = xNONE && continue
3330 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3331 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3332 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3333 sed 's/^/| /' "$ac_site_file" >&5
3334 . "$ac_site_file"
3336 done
3338 if test -r "$cache_file"; then
3339 # Some versions of bash will fail to source /dev/null (special files
3340 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3341 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3342 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3343 $as_echo "$as_me: loading cache $cache_file" >&6;}
3344 case $cache_file in
3345 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3346 *) . "./$cache_file";;
3347 esac
3349 else
3350 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3351 $as_echo "$as_me: creating cache $cache_file" >&6;}
3352 >$cache_file
3355 as_fn_append ac_header_list " linux/version.h"
3356 as_fn_append ac_header_list " sys/systeminfo.h"
3357 as_fn_append ac_header_list " coff.h"
3358 as_fn_append ac_header_list " pty.h"
3359 as_fn_append ac_header_list " sys/resource.h"
3360 as_fn_append ac_header_list " sys/utsname.h"
3361 as_fn_append ac_header_list " pwd.h"
3362 as_fn_append ac_header_list " utmp.h"
3363 as_fn_append ac_header_list " util.h"
3364 as_fn_append ac_header_list " sys/socket.h"
3365 as_fn_append ac_header_list " stdlib.h"
3366 as_fn_append ac_header_list " unistd.h"
3367 as_fn_append ac_header_list " sys/param.h"
3368 as_fn_append ac_header_list " pthread.h"
3369 as_fn_append ac_header_list " malloc/malloc.h"
3370 as_fn_append ac_header_list " maillock.h"
3371 as_fn_append ac_header_list " sys/un.h"
3372 as_fn_append ac_func_list " tzset"
3373 as_fn_append ac_func_list " readlinkat"
3374 as_fn_append ac_header_list " dirent.h"
3375 as_fn_append ac_header_list " execinfo.h"
3376 as_fn_append ac_func_list " faccessat"
3377 as_fn_append ac_func_list " fdopendir"
3378 as_fn_append ac_header_list " stdio_ext.h"
3379 as_fn_append ac_func_list " __fpending"
3380 as_fn_append ac_func_list " fstatat"
3381 as_fn_append ac_func_list " fsync"
3382 gl_getopt_required=GNU
3383 as_fn_append ac_header_list " getopt.h"
3384 as_fn_append ac_func_list " gettimeofday"
3385 as_fn_append ac_func_list " nanotime"
3386 as_fn_append ac_header_list " sys/time.h"
3387 as_fn_append ac_header_list " wchar.h"
3388 as_fn_append ac_header_list " stdint.h"
3389 as_fn_append ac_header_list " inttypes.h"
3390 as_fn_append ac_func_list " lstat"
3391 as_fn_append ac_header_list " sys/select.h"
3392 as_fn_append ac_func_list " pselect"
3393 as_fn_append ac_func_list " pthread_sigmask"
3394 as_fn_append ac_func_list " readlink"
3395 as_fn_append ac_func_list " strtoimax"
3396 as_fn_append ac_func_list " strtoumax"
3397 as_fn_append ac_func_list " symlink"
3398 as_fn_append ac_header_list " sys/stat.h"
3399 as_fn_append ac_func_list " localtime_r"
3400 as_fn_append ac_header_list " utime.h"
3401 as_fn_append ac_func_list " futimes"
3402 as_fn_append ac_func_list " futimesat"
3403 as_fn_append ac_func_list " futimens"
3404 as_fn_append ac_func_list " utimensat"
3405 as_fn_append ac_func_list " lutimes"
3406 # Check that the precious variables saved in the cache have kept the same
3407 # value.
3408 ac_cache_corrupted=false
3409 for ac_var in $ac_precious_vars; do
3410 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3411 eval ac_new_set=\$ac_env_${ac_var}_set
3412 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3413 eval ac_new_val=\$ac_env_${ac_var}_value
3414 case $ac_old_set,$ac_new_set in
3415 set,)
3416 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3417 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3418 ac_cache_corrupted=: ;;
3419 ,set)
3420 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3421 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3422 ac_cache_corrupted=: ;;
3423 ,);;
3425 if test "x$ac_old_val" != "x$ac_new_val"; then
3426 # differences in whitespace do not lead to failure.
3427 ac_old_val_w=`echo x $ac_old_val`
3428 ac_new_val_w=`echo x $ac_new_val`
3429 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3430 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3431 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3432 ac_cache_corrupted=:
3433 else
3434 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3435 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3436 eval $ac_var=\$ac_old_val
3438 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3439 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3440 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3441 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3442 fi;;
3443 esac
3444 # Pass precious variables to config.status.
3445 if test "$ac_new_set" = set; then
3446 case $ac_new_val in
3447 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3448 *) ac_arg=$ac_var=$ac_new_val ;;
3449 esac
3450 case " $ac_configure_args " in
3451 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3452 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3453 esac
3455 done
3456 if $ac_cache_corrupted; then
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3458 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3459 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3460 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3461 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3463 ## -------------------- ##
3464 ## Main body of script. ##
3465 ## -------------------- ##
3467 ac_ext=c
3468 ac_cpp='$CPP $CPPFLAGS'
3469 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3470 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3471 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3475 emacs_config_options="$@"
3476 ## Add some environment variables, if they were passed via the environment
3477 ## rather than on the command-line.
3478 for var in CFLAGS CPPFLAGS LDFLAGS; do
3479 case "$emacs_config_options" in
3480 *$var=*) continue ;;
3481 esac
3482 eval val="\$${var}"
3483 test x"$val" = x && continue
3484 emacs_config_options="${emacs_config_options}${emacs_config_options:+ }$var=\"$val\""
3485 done
3487 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3490 ac_aux_dir=
3491 for ac_dir in build-aux "$srcdir"/build-aux; do
3492 for ac_t in install-sh install.sh shtool; do
3493 if test -f "$ac_dir/$ac_t"; then
3494 ac_aux_dir=$ac_dir
3495 ac_install_sh="$ac_aux_dir/$ac_t -c"
3496 break 2
3498 done
3499 done
3500 if test -z "$ac_aux_dir"; then
3501 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3504 # These three variables are undocumented and unsupported,
3505 # and are intended to be withdrawn in a future Autoconf release.
3506 # They can cause serious problems if a builder's source tree is in a directory
3507 # whose full name contains unusual characters.
3508 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3509 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3510 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3513 am__api_version='1.11'
3515 # Find a good install program. We prefer a C program (faster),
3516 # so one script is as good as another. But avoid the broken or
3517 # incompatible versions:
3518 # SysV /etc/install, /usr/sbin/install
3519 # SunOS /usr/etc/install
3520 # IRIX /sbin/install
3521 # AIX /bin/install
3522 # AmigaOS /C/install, which installs bootblocks on floppy discs
3523 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3524 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3525 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3526 # OS/2's system install, which has a completely different semantic
3527 # ./install, which can be erroneously created by make from ./install.sh.
3528 # Reject install programs that cannot install multiple files.
3529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3530 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3531 if test -z "$INSTALL"; then
3532 if test "${ac_cv_path_install+set}" = set; then :
3533 $as_echo_n "(cached) " >&6
3534 else
3535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3536 for as_dir in $PATH
3538 IFS=$as_save_IFS
3539 test -z "$as_dir" && as_dir=.
3540 # Account for people who put trailing slashes in PATH elements.
3541 case $as_dir/ in #((
3542 ./ | .// | /[cC]/* | \
3543 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3544 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3545 /usr/ucb/* ) ;;
3547 # OSF1 and SCO ODT 3.0 have their own names for install.
3548 # Don't use installbsd from OSF since it installs stuff as root
3549 # by default.
3550 for ac_prog in ginstall scoinst install; do
3551 for ac_exec_ext in '' $ac_executable_extensions; do
3552 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3553 if test $ac_prog = install &&
3554 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3555 # AIX install. It has an incompatible calling convention.
3557 elif test $ac_prog = install &&
3558 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3559 # program-specific install script used by HP pwplus--don't use.
3561 else
3562 rm -rf conftest.one conftest.two conftest.dir
3563 echo one > conftest.one
3564 echo two > conftest.two
3565 mkdir conftest.dir
3566 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3567 test -s conftest.one && test -s conftest.two &&
3568 test -s conftest.dir/conftest.one &&
3569 test -s conftest.dir/conftest.two
3570 then
3571 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3572 break 3
3576 done
3577 done
3579 esac
3581 done
3582 IFS=$as_save_IFS
3584 rm -rf conftest.one conftest.two conftest.dir
3587 if test "${ac_cv_path_install+set}" = set; then
3588 INSTALL=$ac_cv_path_install
3589 else
3590 # As a last resort, use the slow shell script. Don't cache a
3591 # value for INSTALL within a source directory, because that will
3592 # break other packages using the cache if that directory is
3593 # removed, or if the value is a relative name.
3594 INSTALL=$ac_install_sh
3597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3598 $as_echo "$INSTALL" >&6; }
3600 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3601 # It thinks the first close brace ends the variable substitution.
3602 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3604 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3606 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3609 $as_echo_n "checking whether build environment is sane... " >&6; }
3610 # Just in case
3611 sleep 1
3612 echo timestamp > conftest.file
3613 # Reject unsafe characters in $srcdir or the absolute working directory
3614 # name. Accept space and tab only in the latter.
3615 am_lf='
3617 case `pwd` in
3618 *[\\\"\#\$\&\'\`$am_lf]*)
3619 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3620 esac
3621 case $srcdir in
3622 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3623 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3624 esac
3626 # Do `set' in a subshell so we don't clobber the current shell's
3627 # arguments. Must try -L first in case configure is actually a
3628 # symlink; some systems play weird games with the mod time of symlinks
3629 # (eg FreeBSD returns the mod time of the symlink's containing
3630 # directory).
3631 if (
3632 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3633 if test "$*" = "X"; then
3634 # -L didn't work.
3635 set X `ls -t "$srcdir/configure" conftest.file`
3637 rm -f conftest.file
3638 if test "$*" != "X $srcdir/configure conftest.file" \
3639 && test "$*" != "X conftest.file $srcdir/configure"; then
3641 # If neither matched, then we have a broken ls. This can happen
3642 # if, for instance, CONFIG_SHELL is bash and it inherits a
3643 # broken ls alias from the environment. This has actually
3644 # happened. Such a system could not be considered "sane".
3645 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3646 alias in your environment" "$LINENO" 5
3649 test "$2" = conftest.file
3651 then
3652 # Ok.
3654 else
3655 as_fn_error "newly created file is older than distributed files!
3656 Check your system clock" "$LINENO" 5
3658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3659 $as_echo "yes" >&6; }
3660 test "$program_prefix" != NONE &&
3661 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3662 # Use a double $ so make ignores it.
3663 test "$program_suffix" != NONE &&
3664 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3665 # Double any \ or $.
3666 # By default was `s,x,x', remove it if useless.
3667 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3668 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3670 # expand $ac_aux_dir to an absolute path
3671 am_aux_dir=`cd $ac_aux_dir && pwd`
3673 if test x"${MISSING+set}" != xset; then
3674 case $am_aux_dir in
3675 *\ * | *\ *)
3676 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3678 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3679 esac
3681 # Use eval to expand $SHELL
3682 if eval "$MISSING --run true"; then
3683 am_missing_run="$MISSING --run "
3684 else
3685 am_missing_run=
3686 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3687 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3690 if test x"${install_sh}" != xset; then
3691 case $am_aux_dir in
3692 *\ * | *\ *)
3693 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3695 install_sh="\${SHELL} $am_aux_dir/install-sh"
3696 esac
3699 # Installed binaries are usually stripped using `strip' when the user
3700 # run `make install-strip'. However `strip' might not be the right
3701 # tool to use in cross-compilation environments, therefore Automake
3702 # will honor the `STRIP' environment variable to overrule this program.
3703 if test "$cross_compiling" != no; then
3704 if test -n "$ac_tool_prefix"; then
3705 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3706 set dummy ${ac_tool_prefix}strip; ac_word=$2
3707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3708 $as_echo_n "checking for $ac_word... " >&6; }
3709 if test "${ac_cv_prog_STRIP+set}" = set; then :
3710 $as_echo_n "(cached) " >&6
3711 else
3712 if test -n "$STRIP"; then
3713 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3714 else
3715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3716 for as_dir in $PATH
3718 IFS=$as_save_IFS
3719 test -z "$as_dir" && as_dir=.
3720 for ac_exec_ext in '' $ac_executable_extensions; do
3721 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3722 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3723 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3724 break 2
3726 done
3727 done
3728 IFS=$as_save_IFS
3732 STRIP=$ac_cv_prog_STRIP
3733 if test -n "$STRIP"; then
3734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3735 $as_echo "$STRIP" >&6; }
3736 else
3737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3738 $as_echo "no" >&6; }
3743 if test -z "$ac_cv_prog_STRIP"; then
3744 ac_ct_STRIP=$STRIP
3745 # Extract the first word of "strip", so it can be a program name with args.
3746 set dummy strip; ac_word=$2
3747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3748 $as_echo_n "checking for $ac_word... " >&6; }
3749 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3750 $as_echo_n "(cached) " >&6
3751 else
3752 if test -n "$ac_ct_STRIP"; then
3753 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3754 else
3755 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3756 for as_dir in $PATH
3758 IFS=$as_save_IFS
3759 test -z "$as_dir" && as_dir=.
3760 for ac_exec_ext in '' $ac_executable_extensions; do
3761 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3762 ac_cv_prog_ac_ct_STRIP="strip"
3763 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3764 break 2
3766 done
3767 done
3768 IFS=$as_save_IFS
3772 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3773 if test -n "$ac_ct_STRIP"; then
3774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3775 $as_echo "$ac_ct_STRIP" >&6; }
3776 else
3777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3778 $as_echo "no" >&6; }
3781 if test "x$ac_ct_STRIP" = x; then
3782 STRIP=":"
3783 else
3784 case $cross_compiling:$ac_tool_warned in
3785 yes:)
3786 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3787 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3788 ac_tool_warned=yes ;;
3789 esac
3790 STRIP=$ac_ct_STRIP
3792 else
3793 STRIP="$ac_cv_prog_STRIP"
3797 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3800 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3801 if test -z "$MKDIR_P"; then
3802 if test "${ac_cv_path_mkdir+set}" = set; then :
3803 $as_echo_n "(cached) " >&6
3804 else
3805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3806 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3808 IFS=$as_save_IFS
3809 test -z "$as_dir" && as_dir=.
3810 for ac_prog in mkdir gmkdir; do
3811 for ac_exec_ext in '' $ac_executable_extensions; do
3812 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3813 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3814 'mkdir (GNU coreutils) '* | \
3815 'mkdir (coreutils) '* | \
3816 'mkdir (fileutils) '4.1*)
3817 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3818 break 3;;
3819 esac
3820 done
3821 done
3822 done
3823 IFS=$as_save_IFS
3827 test -d ./--version && rmdir ./--version
3828 if test "${ac_cv_path_mkdir+set}" = set; then
3829 MKDIR_P="$ac_cv_path_mkdir -p"
3830 else
3831 # As a last resort, use the slow shell script. Don't cache a
3832 # value for MKDIR_P within a source directory, because that will
3833 # break other packages using the cache if that directory is
3834 # removed, or if the value is a relative name.
3835 MKDIR_P="$ac_install_sh -d"
3838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3839 $as_echo "$MKDIR_P" >&6; }
3841 mkdir_p="$MKDIR_P"
3842 case $mkdir_p in
3843 [\\/$]* | ?:[\\/]*) ;;
3844 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3845 esac
3847 for ac_prog in gawk mawk nawk awk
3849 # Extract the first word of "$ac_prog", so it can be a program name with args.
3850 set dummy $ac_prog; ac_word=$2
3851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3852 $as_echo_n "checking for $ac_word... " >&6; }
3853 if test "${ac_cv_prog_AWK+set}" = set; then :
3854 $as_echo_n "(cached) " >&6
3855 else
3856 if test -n "$AWK"; then
3857 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3858 else
3859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3860 for as_dir in $PATH
3862 IFS=$as_save_IFS
3863 test -z "$as_dir" && as_dir=.
3864 for ac_exec_ext in '' $ac_executable_extensions; do
3865 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3866 ac_cv_prog_AWK="$ac_prog"
3867 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3868 break 2
3870 done
3871 done
3872 IFS=$as_save_IFS
3876 AWK=$ac_cv_prog_AWK
3877 if test -n "$AWK"; then
3878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3879 $as_echo "$AWK" >&6; }
3880 else
3881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3882 $as_echo "no" >&6; }
3886 test -n "$AWK" && break
3887 done
3889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3890 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3891 set x ${MAKE-make}
3892 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3893 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3894 $as_echo_n "(cached) " >&6
3895 else
3896 cat >conftest.make <<\_ACEOF
3897 SHELL = /bin/sh
3898 all:
3899 @echo '@@@%%%=$(MAKE)=@@@%%%'
3900 _ACEOF
3901 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3902 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3903 *@@@%%%=?*=@@@%%%*)
3904 eval ac_cv_prog_make_${ac_make}_set=yes;;
3906 eval ac_cv_prog_make_${ac_make}_set=no;;
3907 esac
3908 rm -f conftest.make
3910 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3912 $as_echo "yes" >&6; }
3913 SET_MAKE=
3914 else
3915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3916 $as_echo "no" >&6; }
3917 SET_MAKE="MAKE=${MAKE-make}"
3920 rm -rf .tst 2>/dev/null
3921 mkdir .tst 2>/dev/null
3922 if test -d .tst; then
3923 am__leading_dot=.
3924 else
3925 am__leading_dot=_
3927 rmdir .tst 2>/dev/null
3929 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3930 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3931 # is not polluted with repeated "-I."
3932 am__isrc=' -I$(srcdir)'
3933 # test to see if srcdir already configured
3934 if test -f $srcdir/config.status; then
3935 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3939 # test whether we have cygpath
3940 if test -z "$CYGPATH_W"; then
3941 if (cygpath --version) >/dev/null 2>/dev/null; then
3942 CYGPATH_W='cygpath -w'
3943 else
3944 CYGPATH_W=echo
3949 # Define the identity of the package.
3950 PACKAGE='emacs'
3951 VERSION='24.3.50'
3954 cat >>confdefs.h <<_ACEOF
3955 #define PACKAGE "$PACKAGE"
3956 _ACEOF
3959 cat >>confdefs.h <<_ACEOF
3960 #define VERSION "$VERSION"
3961 _ACEOF
3963 # Some tools Automake needs.
3965 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3968 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3971 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3974 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3977 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3979 # We need awk for the "check" target. The system "awk" is bad on
3980 # some platforms.
3981 # Always define AMTAR for backward compatibility.
3983 AMTAR=${AMTAR-"${am_missing_run}tar"}
3985 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3994 lispdir='${datadir}/emacs/${version}/lisp'
3995 leimdir='${datadir}/emacs/${version}/leim'
3996 standardlisppath='${lispdir}:${leimdir}'
3997 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3998 '${datadir}/emacs/site-lisp'
3999 lisppath='${locallisppath}:${standardlisppath}'
4000 etcdir='${datadir}/emacs/${version}/etc'
4001 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4002 docdir='${datadir}/emacs/${version}/etc'
4003 gamedir='${localstatedir}/games/emacs'
4006 # Check whether --with-all was given.
4007 if test "${with_all+set}" = set; then :
4008 withval=$with_all; with_features=$withval
4009 else
4010 with_features=yes
4017 # Check whether --with-pop was given.
4018 if test "${with_pop+set}" = set; then :
4019 withval=$with_pop;
4020 else
4021 with_pop=$with_features
4024 if test "$with_pop" = yes; then
4025 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4030 # Check whether --with-kerberos was given.
4031 if test "${with_kerberos+set}" = set; then :
4032 withval=$with_kerberos;
4033 else
4034 with_kerberos=no
4037 if test "$with_kerberos" != no; then
4038 $as_echo "#define KERBEROS 1" >>confdefs.h
4043 # Check whether --with-kerberos5 was given.
4044 if test "${with_kerberos5+set}" = set; then :
4045 withval=$with_kerberos5;
4046 else
4047 with_kerberos5=no
4050 if test "${with_kerberos5}" != no; then
4051 if test "${with_kerberos}" = no; then
4052 with_kerberos=yes
4053 $as_echo "#define KERBEROS 1" >>confdefs.h
4057 $as_echo "#define KERBEROS5 1" >>confdefs.h
4062 # Check whether --with-hesiod was given.
4063 if test "${with_hesiod+set}" = set; then :
4064 withval=$with_hesiod;
4065 else
4066 with_hesiod=no
4069 if test "$with_hesiod" != no; then
4071 $as_echo "#define HESIOD 1" >>confdefs.h
4076 # Check whether --with-mmdf was given.
4077 if test "${with_mmdf+set}" = set; then :
4078 withval=$with_mmdf;
4079 else
4080 with_mmdf=no
4083 if test "$with_mmdf" != no; then
4085 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4090 # Check whether --with-mail-unlink was given.
4091 if test "${with_mail_unlink+set}" = set; then :
4092 withval=$with_mail_unlink;
4093 else
4094 with_mail_unlink=no
4097 if test "$with_mail_unlink" != no; then
4099 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4104 # Check whether --with-mailhost was given.
4105 if test "${with_mailhost+set}" = set; then :
4106 withval=$with_mailhost;
4107 cat >>confdefs.h <<_ACEOF
4108 #define MAILHOST "$withval"
4109 _ACEOF
4115 # Check whether --with-sound was given.
4116 if test "${with_sound+set}" = set; then :
4117 withval=$with_sound;
4118 else
4119 with_sound=$with_features
4124 # Check whether --with-x-toolkit was given.
4125 if test "${with_x_toolkit+set}" = set; then :
4126 withval=$with_x_toolkit; case "${withval}" in
4127 y | ye | yes ) val=gtk ;;
4128 n | no ) val=no ;;
4129 l | lu | luc | luci | lucid ) val=lucid ;;
4130 a | at | ath | athe | athen | athena ) val=athena ;;
4131 m | mo | mot | moti | motif ) val=motif ;;
4132 g | gt | gtk ) val=gtk ;;
4133 gtk2 ) val=gtk2 ;;
4134 gtk3 ) val=gtk3 ;;
4136 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4137 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4138 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4139 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4141 esac
4142 with_x_toolkit=$val
4148 # Check whether --with-wide-int was given.
4149 if test "${with_wide_int+set}" = set; then :
4150 withval=$with_wide_int;
4151 else
4152 with_wide_int=no
4155 if test "$with_wide_int" = yes; then
4157 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4162 # Check whether --with-xpm was given.
4163 if test "${with_xpm+set}" = set; then :
4164 withval=$with_xpm;
4165 else
4166 with_xpm=$with_features
4170 # Check whether --with-jpeg was given.
4171 if test "${with_jpeg+set}" = set; then :
4172 withval=$with_jpeg;
4173 else
4174 with_jpeg=$with_features
4178 # Check whether --with-tiff was given.
4179 if test "${with_tiff+set}" = set; then :
4180 withval=$with_tiff;
4181 else
4182 with_tiff=$with_features
4186 # Check whether --with-gif was given.
4187 if test "${with_gif+set}" = set; then :
4188 withval=$with_gif;
4189 else
4190 with_gif=$with_features
4194 # Check whether --with-png was given.
4195 if test "${with_png+set}" = set; then :
4196 withval=$with_png;
4197 else
4198 with_png=$with_features
4202 # Check whether --with-rsvg was given.
4203 if test "${with_rsvg+set}" = set; then :
4204 withval=$with_rsvg;
4205 else
4206 with_rsvg=$with_features
4210 # Check whether --with-xml2 was given.
4211 if test "${with_xml2+set}" = set; then :
4212 withval=$with_xml2;
4213 else
4214 with_xml2=$with_features
4218 # Check whether --with-imagemagick was given.
4219 if test "${with_imagemagick+set}" = set; then :
4220 withval=$with_imagemagick;
4221 else
4222 with_imagemagick=$with_features
4227 # Check whether --with-xft was given.
4228 if test "${with_xft+set}" = set; then :
4229 withval=$with_xft;
4230 else
4231 with_xft=$with_features
4235 # Check whether --with-libotf was given.
4236 if test "${with_libotf+set}" = set; then :
4237 withval=$with_libotf;
4238 else
4239 with_libotf=$with_features
4243 # Check whether --with-m17n-flt was given.
4244 if test "${with_m17n_flt+set}" = set; then :
4245 withval=$with_m17n_flt;
4246 else
4247 with_m17n_flt=$with_features
4252 # Check whether --with-toolkit-scroll-bars was given.
4253 if test "${with_toolkit_scroll_bars+set}" = set; then :
4254 withval=$with_toolkit_scroll_bars;
4255 else
4256 with_toolkit_scroll_bars=$with_features
4260 # Check whether --with-xaw3d was given.
4261 if test "${with_xaw3d+set}" = set; then :
4262 withval=$with_xaw3d;
4263 else
4264 with_xaw3d=$with_features
4268 # Check whether --with-xim was given.
4269 if test "${with_xim+set}" = set; then :
4270 withval=$with_xim;
4271 else
4272 with_xim=$with_features
4276 # Check whether --with-ns was given.
4277 if test "${with_ns+set}" = set; then :
4278 withval=$with_ns;
4279 else
4280 with_ns=no
4284 # Check whether --with-w32 was given.
4285 if test "${with_w32+set}" = set; then :
4286 withval=$with_w32;
4287 else
4288 with_w32=no
4293 # Check whether --with-gpm was given.
4294 if test "${with_gpm+set}" = set; then :
4295 withval=$with_gpm;
4296 else
4297 with_gpm=$with_features
4301 # Check whether --with-dbus was given.
4302 if test "${with_dbus+set}" = set; then :
4303 withval=$with_dbus;
4304 else
4305 with_dbus=$with_features
4309 # Check whether --with-gconf was given.
4310 if test "${with_gconf+set}" = set; then :
4311 withval=$with_gconf;
4312 else
4313 with_gconf=$with_features
4317 # Check whether --with-gsettings was given.
4318 if test "${with_gsettings+set}" = set; then :
4319 withval=$with_gsettings;
4320 else
4321 with_gsettings=$with_features
4325 # Check whether --with-selinux was given.
4326 if test "${with_selinux+set}" = set; then :
4327 withval=$with_selinux;
4328 else
4329 with_selinux=$with_features
4333 # Check whether --with-gnutls was given.
4334 if test "${with_gnutls+set}" = set; then :
4335 withval=$with_gnutls;
4336 else
4337 with_gnutls=$with_features
4342 # Check whether --with-file-notification was given.
4343 if test "${with_file_notification+set}" = set; then :
4344 withval=$with_file_notification; case "${withval}" in
4345 y | ye | yes ) val=yes ;;
4346 n | no ) val=no ;;
4347 g | gf | gfi | gfil | gfile ) val=gfile ;;
4348 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4349 w | w3 | w32 ) val=w32 ;;
4350 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4351 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4352 \`yes' is a synonym for \`w32' on MS-Windows, and for \`gfile' otherwise." "$LINENO" 5
4354 esac
4355 with_file_notification=$val
4357 else
4358 with_file_notification=yes
4362 ## For the times when you want to build Emacs but don't have
4363 ## a suitable makeinfo, and can live without the manuals.
4365 # Check whether --with-makeinfo was given.
4366 if test "${with_makeinfo+set}" = set; then :
4367 withval=$with_makeinfo;
4368 else
4369 with_makeinfo=$with_features
4373 ## Makefile.in needs the cache file name.
4376 ## This is an option because I do not know if all info/man support
4377 ## compressed files, nor how to test if they do so.
4379 # Check whether --with-compress-info was given.
4380 if test "${with_compress_info+set}" = set; then :
4381 withval=$with_compress_info;
4382 else
4383 with_compress_info=$with_features
4386 if test $with_compress_info = yes; then
4387 GZIP_INFO=yes
4388 else
4389 GZIP_INFO=
4394 # Check whether --with-pkg-config-prog was given.
4395 if test "${with_pkg_config_prog+set}" = set; then :
4396 withval=$with_pkg_config_prog;
4399 if test "X${with_pkg_config_prog}" != X; then
4400 if test "${with_pkg_config_prog}" != yes; then
4401 PKG_CONFIG="${with_pkg_config_prog}"
4406 # Check whether --with-gameuser was given.
4407 if test "${with_gameuser+set}" = set; then :
4408 withval=$with_gameuser;
4411 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4412 && gameuser="${with_gameuser}"
4413 test "X$gameuser" = X && gameuser=games
4416 # Check whether --with-gnustep-conf was given.
4417 if test "${with_gnustep_conf+set}" = set; then :
4418 withval=$with_gnustep_conf;
4421 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4422 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4423 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4424 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4426 # Check whether --enable-ns-self-contained was given.
4427 if test "${enable_ns_self_contained+set}" = set; then :
4428 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4429 else
4430 EN_NS_SELF_CONTAINED=yes
4434 # Check whether --enable-locallisppath was given.
4435 if test "${enable_locallisppath+set}" = set; then :
4436 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4437 locallisppath=
4438 elif test "${enableval}" != "yes"; then
4439 locallisppath=${enableval}
4444 # Check whether --enable-checking was given.
4445 if test "${enable_checking+set}" = set; then :
4446 enableval=$enable_checking; ac_checking_flags="${enableval}"
4449 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4450 for check in $ac_checking_flags
4452 case $check in
4453 # these set all the flags to specific states
4454 yes) ac_enable_checking=1 ;;
4455 no) ac_enable_checking= ;
4456 ac_gc_check_stringbytes= ;
4457 ac_gc_check_string_overrun= ;
4458 ac_gc_check_string_free_list= ;
4459 ac_xmalloc_overrun= ;
4460 ac_gc_check_cons_list= ;
4461 ac_glyphs_debug= ;;
4462 all) ac_enable_checking=1 ;
4463 ac_gc_check_stringbytes=1 ;
4464 ac_gc_check_string_overrun=1 ;
4465 ac_gc_check_string_free_list=1 ;
4466 ac_xmalloc_overrun=1 ;
4467 ac_gc_check_cons_list=1 ;
4468 ac_glyphs_debug=1 ;;
4469 # these enable particular checks
4470 stringbytes) ac_gc_check_stringbytes=1 ;;
4471 stringoverrun) ac_gc_check_string_overrun=1 ;;
4472 stringfreelist) ac_gc_check_string_free_list=1 ;;
4473 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4474 conslist) ac_gc_check_cons_list=1 ;;
4475 glyphs) ac_glyphs_debug=1 ;;
4476 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4477 esac
4478 done
4479 IFS="$ac_save_IFS"
4481 if test x$ac_enable_checking != x ; then
4483 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4486 if test x$ac_gc_check_stringbytes != x ; then
4488 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4491 if test x$ac_gc_check_string_overrun != x ; then
4493 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4496 if test x$ac_gc_check_string_free_list != x ; then
4498 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4501 if test x$ac_xmalloc_overrun != x ; then
4503 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4506 if test x$ac_gc_check_cons_list != x ; then
4508 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4511 if test x$ac_glyphs_debug != x ; then
4513 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4517 # Check whether --enable-check-lisp-object-type was given.
4518 if test "${enable_check_lisp_object_type+set}" = set; then :
4519 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4521 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4528 # Check whether --enable-profiling was given.
4529 if test "${enable_profiling+set}" = set; then :
4530 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4533 if test x$ac_enable_profiling != x ; then
4534 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4535 else
4536 PROFILING_CFLAGS=
4540 # Check whether --enable-autodepend was given.
4541 if test "${enable_autodepend+set}" = set; then :
4542 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4543 else
4544 ac_enable_autodepend=yes
4548 # Check whether --enable-gtk-deprecation-warnings was given.
4549 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4550 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4554 #### Make srcdir absolute, if it isn't already. It's important to
4555 #### avoid running the file name through pwd unnecessarily, since pwd can
4556 #### give you automounter prefixes, which can go away. We do all this
4557 #### so Emacs can find its files when run uninstalled.
4558 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4559 unset CDPATH
4560 case "${srcdir}" in
4561 [\\/]* | ?:[\\/]*) ;;
4563 ## We may be able to use the $PWD environment variable to make this
4564 ## absolute. But sometimes PWD is inaccurate.
4565 ## Note: we used to use $PWD at the end instead of `pwd`,
4566 ## but that tested only for a well-formed and valid PWD,
4567 ## it did not object when PWD was well-formed and valid but just wrong.
4568 if test ".$PWD" != "." && test ".`(cd "$PWD" ; sh -c pwd)`" = ".`pwd`" ;
4569 then
4570 srcdir="$PWD"
4571 else
4572 srcdir=`(cd "$srcdir"; pwd)`
4575 * ) srcdir=`(cd "$srcdir"; pwd)` ;;
4576 esac
4578 ### Canonicalize the configuration name.
4580 # Make sure we can run config.sub.
4581 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4582 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4585 $as_echo_n "checking build system type... " >&6; }
4586 if test "${ac_cv_build+set}" = set; then :
4587 $as_echo_n "(cached) " >&6
4588 else
4589 ac_build_alias=$build_alias
4590 test "x$ac_build_alias" = x &&
4591 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4592 test "x$ac_build_alias" = x &&
4593 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4594 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4595 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4599 $as_echo "$ac_cv_build" >&6; }
4600 case $ac_cv_build in
4601 *-*-*) ;;
4602 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4603 esac
4604 build=$ac_cv_build
4605 ac_save_IFS=$IFS; IFS='-'
4606 set x $ac_cv_build
4607 shift
4608 build_cpu=$1
4609 build_vendor=$2
4610 shift; shift
4611 # Remember, the first character of IFS is used to create $*,
4612 # except with old shells:
4613 build_os=$*
4614 IFS=$ac_save_IFS
4615 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4619 $as_echo_n "checking host system type... " >&6; }
4620 if test "${ac_cv_host+set}" = set; then :
4621 $as_echo_n "(cached) " >&6
4622 else
4623 if test "x$host_alias" = x; then
4624 ac_cv_host=$ac_cv_build
4625 else
4626 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4627 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4632 $as_echo "$ac_cv_host" >&6; }
4633 case $ac_cv_host in
4634 *-*-*) ;;
4635 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4636 esac
4637 host=$ac_cv_host
4638 ac_save_IFS=$IFS; IFS='-'
4639 set x $ac_cv_host
4640 shift
4641 host_cpu=$1
4642 host_vendor=$2
4643 shift; shift
4644 # Remember, the first character of IFS is used to create $*,
4645 # except with old shells:
4646 host_os=$*
4647 IFS=$ac_save_IFS
4648 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4651 canonical=$host
4652 configuration=${host_alias-${build_alias-$host}}
4656 ### If you add support for a new configuration, add code to this
4657 ### switch statement to recognize your configuration name and select
4658 ### the appropriate operating system file.
4660 ### You would hope that you could choose an s/*.h
4661 ### file based on the operating system portion. However, it turns out
4662 ### that each s/*.h file is pretty manufacturer-specific.
4663 ### So we basically have to have a special case for each
4664 ### configuration name.
4666 ### As far as handling version numbers on operating systems is
4667 ### concerned, make sure things will fail in a fixable way. If
4668 ### /etc/MACHINES doesn't say anything about version numbers, be
4669 ### prepared to handle anything reasonably. If version numbers
4670 ### matter, be sure /etc/MACHINES says something about it.
4672 opsys='' unported=no
4673 case "${canonical}" in
4675 ## GNU/Linux and similar ports
4676 *-*-linux* )
4677 opsys=gnu-linux
4680 ## FreeBSD ports
4681 *-*-freebsd* )
4682 opsys=freebsd
4685 ## DragonFly ports
4686 *-*-dragonfly* )
4687 opsys=dragonfly
4690 ## FreeBSD kernel + glibc based userland
4691 *-*-kfreebsd*gnu* )
4692 opsys=gnu-kfreebsd
4695 ## NetBSD ports
4696 *-*-netbsd* )
4697 opsys=netbsd
4700 ## OpenBSD ports
4701 *-*-openbsd* )
4702 opsys=openbsd
4705 ## Apple Darwin / Mac OS X
4706 *-apple-darwin* )
4707 case "${canonical}" in
4708 i[3456]86-* ) ;;
4709 powerpc-* ) ;;
4710 x86_64-* ) ;;
4711 * ) unported=yes ;;
4712 esac
4713 opsys=darwin
4714 ## Use fink packages if available.
4715 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4716 ## if test -d /sw/include && test -d /sw/lib; then
4717 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4718 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4719 ## fi
4722 ## Cygwin ports
4723 *-*-cygwin )
4724 opsys=cygwin
4727 ## HP 9000 series 700 and 800, running HP/UX
4728 hppa*-hp-hpux10.2* )
4729 opsys=hpux10-20
4731 hppa*-hp-hpux1[1-9]* )
4732 opsys=hpux11
4733 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4736 ## IBM machines
4737 rs6000-ibm-aix4.[23]* )
4738 opsys=aix4-2
4740 powerpc-ibm-aix4.[23]* )
4741 opsys=aix4-2
4743 rs6000-ibm-aix[56]* )
4744 opsys=aix4-2
4746 powerpc-ibm-aix[56]* )
4747 opsys=aix4-2
4750 ## Silicon Graphics machines
4751 ## Iris 4D
4752 mips-sgi-irix6.5 )
4753 opsys=irix6-5
4754 # Without defining _LANGUAGE_C, things get masked out in the headers
4755 # so that, for instance, grepping for `free' in stdlib.h fails and
4756 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4757 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4760 ## Suns
4761 *-sun-solaris* \
4762 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4763 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4764 case "${canonical}" in
4765 i[3456]86-*-* ) ;;
4766 amd64-*-*|x86_64-*-*) ;;
4767 sparc* ) ;;
4768 * ) unported=yes ;;
4769 esac
4770 case "${canonical}" in
4771 *-sunos5.6* | *-solaris2.6* )
4772 opsys=sol2-6
4773 RANLIB="ar -ts"
4775 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4776 opsys=sol2-6
4777 emacs_check_sunpro_c=yes
4779 *-sunos5* | *-solaris* )
4780 opsys=sol2-10
4781 emacs_check_sunpro_c=yes
4783 esac
4784 ## Watch out for a compiler that we know will not work.
4785 case "${canonical}" in
4786 *-solaris* | *-sunos5* )
4787 if [ "x$CC" = x/usr/ucb/cc ]; then
4788 ## /usr/ucb/cc doesn't work;
4789 ## we should find some other compiler that does work.
4790 unset CC
4793 *) ;;
4794 esac
4797 ## Intel 386 machines where we don't care about the manufacturer.
4798 i[3456]86-*-* )
4799 case "${canonical}" in
4800 *-darwin* ) opsys=darwin ;;
4801 *-mingw32 )
4802 opsys=mingw32
4803 # MinGW overrides and adds some system headers in nt/inc.
4804 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4806 *-sysv4.2uw* ) opsys=unixware ;;
4807 *-sysv5uw* ) opsys=unixware ;;
4808 *-sysv5OpenUNIX* ) opsys=unixware ;;
4809 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4810 esac
4814 unported=yes
4816 esac
4818 ### If the code above didn't choose an operating system, just choose
4819 ### an operating system based on the configuration name. You really
4820 ### only want to use this when you have no idea what the right
4821 ### operating system is; if you know what operating systems a machine
4822 ### runs, it's cleaner to make it explicit in the case statement
4823 ### above.
4824 if test x"${opsys}" = x; then
4825 case "${canonical}" in
4826 *-gnu* ) opsys=gnu ;;
4828 unported=yes
4830 esac
4835 if test $unported = yes; then
4836 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4837 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4841 #### Choose a compiler.
4843 ac_ext=c
4844 ac_cpp='$CPP $CPPFLAGS'
4845 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4846 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4847 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4848 if test -n "$ac_tool_prefix"; then
4849 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4850 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4852 $as_echo_n "checking for $ac_word... " >&6; }
4853 if test "${ac_cv_prog_CC+set}" = set; then :
4854 $as_echo_n "(cached) " >&6
4855 else
4856 if test -n "$CC"; then
4857 ac_cv_prog_CC="$CC" # Let the user override the test.
4858 else
4859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4860 for as_dir in $PATH
4862 IFS=$as_save_IFS
4863 test -z "$as_dir" && as_dir=.
4864 for ac_exec_ext in '' $ac_executable_extensions; do
4865 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4866 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4867 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4868 break 2
4870 done
4871 done
4872 IFS=$as_save_IFS
4876 CC=$ac_cv_prog_CC
4877 if test -n "$CC"; then
4878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4879 $as_echo "$CC" >&6; }
4880 else
4881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4882 $as_echo "no" >&6; }
4887 if test -z "$ac_cv_prog_CC"; then
4888 ac_ct_CC=$CC
4889 # Extract the first word of "gcc", so it can be a program name with args.
4890 set dummy gcc; ac_word=$2
4891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4892 $as_echo_n "checking for $ac_word... " >&6; }
4893 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4894 $as_echo_n "(cached) " >&6
4895 else
4896 if test -n "$ac_ct_CC"; then
4897 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4898 else
4899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4900 for as_dir in $PATH
4902 IFS=$as_save_IFS
4903 test -z "$as_dir" && as_dir=.
4904 for ac_exec_ext in '' $ac_executable_extensions; do
4905 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4906 ac_cv_prog_ac_ct_CC="gcc"
4907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4908 break 2
4910 done
4911 done
4912 IFS=$as_save_IFS
4916 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4917 if test -n "$ac_ct_CC"; then
4918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4919 $as_echo "$ac_ct_CC" >&6; }
4920 else
4921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4922 $as_echo "no" >&6; }
4925 if test "x$ac_ct_CC" = x; then
4926 CC=""
4927 else
4928 case $cross_compiling:$ac_tool_warned in
4929 yes:)
4930 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4931 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4932 ac_tool_warned=yes ;;
4933 esac
4934 CC=$ac_ct_CC
4936 else
4937 CC="$ac_cv_prog_CC"
4940 if test -z "$CC"; then
4941 if test -n "$ac_tool_prefix"; then
4942 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4943 set dummy ${ac_tool_prefix}cc; ac_word=$2
4944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4945 $as_echo_n "checking for $ac_word... " >&6; }
4946 if test "${ac_cv_prog_CC+set}" = set; then :
4947 $as_echo_n "(cached) " >&6
4948 else
4949 if test -n "$CC"; then
4950 ac_cv_prog_CC="$CC" # Let the user override the test.
4951 else
4952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4953 for as_dir in $PATH
4955 IFS=$as_save_IFS
4956 test -z "$as_dir" && as_dir=.
4957 for ac_exec_ext in '' $ac_executable_extensions; do
4958 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4959 ac_cv_prog_CC="${ac_tool_prefix}cc"
4960 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4961 break 2
4963 done
4964 done
4965 IFS=$as_save_IFS
4969 CC=$ac_cv_prog_CC
4970 if test -n "$CC"; then
4971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4972 $as_echo "$CC" >&6; }
4973 else
4974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4975 $as_echo "no" >&6; }
4981 if test -z "$CC"; then
4982 # Extract the first word of "cc", so it can be a program name with args.
4983 set dummy cc; ac_word=$2
4984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4985 $as_echo_n "checking for $ac_word... " >&6; }
4986 if test "${ac_cv_prog_CC+set}" = set; then :
4987 $as_echo_n "(cached) " >&6
4988 else
4989 if test -n "$CC"; then
4990 ac_cv_prog_CC="$CC" # Let the user override the test.
4991 else
4992 ac_prog_rejected=no
4993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4994 for as_dir in $PATH
4996 IFS=$as_save_IFS
4997 test -z "$as_dir" && as_dir=.
4998 for ac_exec_ext in '' $ac_executable_extensions; do
4999 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5000 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5001 ac_prog_rejected=yes
5002 continue
5004 ac_cv_prog_CC="cc"
5005 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5006 break 2
5008 done
5009 done
5010 IFS=$as_save_IFS
5012 if test $ac_prog_rejected = yes; then
5013 # We found a bogon in the path, so make sure we never use it.
5014 set dummy $ac_cv_prog_CC
5015 shift
5016 if test $# != 0; then
5017 # We chose a different compiler from the bogus one.
5018 # However, it has the same basename, so the bogon will be chosen
5019 # first if we set CC to just the basename; use the full file name.
5020 shift
5021 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5026 CC=$ac_cv_prog_CC
5027 if test -n "$CC"; then
5028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5029 $as_echo "$CC" >&6; }
5030 else
5031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5032 $as_echo "no" >&6; }
5037 if test -z "$CC"; then
5038 if test -n "$ac_tool_prefix"; then
5039 for ac_prog in cl.exe
5041 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5042 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5044 $as_echo_n "checking for $ac_word... " >&6; }
5045 if test "${ac_cv_prog_CC+set}" = set; then :
5046 $as_echo_n "(cached) " >&6
5047 else
5048 if test -n "$CC"; then
5049 ac_cv_prog_CC="$CC" # Let the user override the test.
5050 else
5051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5052 for as_dir in $PATH
5054 IFS=$as_save_IFS
5055 test -z "$as_dir" && as_dir=.
5056 for ac_exec_ext in '' $ac_executable_extensions; do
5057 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5058 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5060 break 2
5062 done
5063 done
5064 IFS=$as_save_IFS
5068 CC=$ac_cv_prog_CC
5069 if test -n "$CC"; then
5070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5071 $as_echo "$CC" >&6; }
5072 else
5073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5074 $as_echo "no" >&6; }
5078 test -n "$CC" && break
5079 done
5081 if test -z "$CC"; then
5082 ac_ct_CC=$CC
5083 for ac_prog in cl.exe
5085 # Extract the first word of "$ac_prog", so it can be a program name with args.
5086 set dummy $ac_prog; ac_word=$2
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5088 $as_echo_n "checking for $ac_word... " >&6; }
5089 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5090 $as_echo_n "(cached) " >&6
5091 else
5092 if test -n "$ac_ct_CC"; then
5093 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5094 else
5095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5096 for as_dir in $PATH
5098 IFS=$as_save_IFS
5099 test -z "$as_dir" && as_dir=.
5100 for ac_exec_ext in '' $ac_executable_extensions; do
5101 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5102 ac_cv_prog_ac_ct_CC="$ac_prog"
5103 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5104 break 2
5106 done
5107 done
5108 IFS=$as_save_IFS
5112 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5113 if test -n "$ac_ct_CC"; then
5114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5115 $as_echo "$ac_ct_CC" >&6; }
5116 else
5117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5118 $as_echo "no" >&6; }
5122 test -n "$ac_ct_CC" && break
5123 done
5125 if test "x$ac_ct_CC" = x; then
5126 CC=""
5127 else
5128 case $cross_compiling:$ac_tool_warned in
5129 yes:)
5130 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5131 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5132 ac_tool_warned=yes ;;
5133 esac
5134 CC=$ac_ct_CC
5141 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5142 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5143 as_fn_error "no acceptable C compiler found in \$PATH
5144 See \`config.log' for more details." "$LINENO" 5; }
5146 # Provide some information about the compiler.
5147 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5148 set X $ac_compile
5149 ac_compiler=$2
5150 for ac_option in --version -v -V -qversion; do
5151 { { ac_try="$ac_compiler $ac_option >&5"
5152 case "(($ac_try" in
5153 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5154 *) ac_try_echo=$ac_try;;
5155 esac
5156 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5157 $as_echo "$ac_try_echo"; } >&5
5158 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5159 ac_status=$?
5160 if test -s conftest.err; then
5161 sed '10a\
5162 ... rest of stderr output deleted ...
5163 10q' conftest.err >conftest.er1
5164 cat conftest.er1 >&5
5166 rm -f conftest.er1 conftest.err
5167 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5168 test $ac_status = 0; }
5169 done
5171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5172 /* end confdefs.h. */
5175 main ()
5179 return 0;
5181 _ACEOF
5182 ac_clean_files_save=$ac_clean_files
5183 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5184 # Try to create an executable without -o first, disregard a.out.
5185 # It will help us diagnose broken compilers, and finding out an intuition
5186 # of exeext.
5187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5188 $as_echo_n "checking whether the C compiler works... " >&6; }
5189 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5191 # The possible output files:
5192 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5194 ac_rmfiles=
5195 for ac_file in $ac_files
5197 case $ac_file in
5198 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5199 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5200 esac
5201 done
5202 rm -f $ac_rmfiles
5204 if { { ac_try="$ac_link_default"
5205 case "(($ac_try" in
5206 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5207 *) ac_try_echo=$ac_try;;
5208 esac
5209 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5210 $as_echo "$ac_try_echo"; } >&5
5211 (eval "$ac_link_default") 2>&5
5212 ac_status=$?
5213 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5214 test $ac_status = 0; }; then :
5215 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5216 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5217 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5218 # so that the user can short-circuit this test for compilers unknown to
5219 # Autoconf.
5220 for ac_file in $ac_files ''
5222 test -f "$ac_file" || continue
5223 case $ac_file in
5224 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5226 [ab].out )
5227 # We found the default executable, but exeext='' is most
5228 # certainly right.
5229 break;;
5230 *.* )
5231 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5232 then :; else
5233 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5235 # We set ac_cv_exeext here because the later test for it is not
5236 # safe: cross compilers may not add the suffix if given an `-o'
5237 # argument, so we may need to know it at that point already.
5238 # Even if this section looks crufty: it has the advantage of
5239 # actually working.
5240 break;;
5242 break;;
5243 esac
5244 done
5245 test "$ac_cv_exeext" = no && ac_cv_exeext=
5247 else
5248 ac_file=''
5250 if test -z "$ac_file"; then :
5251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5252 $as_echo "no" >&6; }
5253 $as_echo "$as_me: failed program was:" >&5
5254 sed 's/^/| /' conftest.$ac_ext >&5
5256 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5257 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5258 { as_fn_set_status 77
5259 as_fn_error "C compiler cannot create executables
5260 See \`config.log' for more details." "$LINENO" 5; }; }
5261 else
5262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5263 $as_echo "yes" >&6; }
5265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5266 $as_echo_n "checking for C compiler default output file name... " >&6; }
5267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5268 $as_echo "$ac_file" >&6; }
5269 ac_exeext=$ac_cv_exeext
5271 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5272 ac_clean_files=$ac_clean_files_save
5273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5274 $as_echo_n "checking for suffix of executables... " >&6; }
5275 if { { ac_try="$ac_link"
5276 case "(($ac_try" in
5277 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5278 *) ac_try_echo=$ac_try;;
5279 esac
5280 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5281 $as_echo "$ac_try_echo"; } >&5
5282 (eval "$ac_link") 2>&5
5283 ac_status=$?
5284 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5285 test $ac_status = 0; }; then :
5286 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5287 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5288 # work properly (i.e., refer to `conftest.exe'), while it won't with
5289 # `rm'.
5290 for ac_file in conftest.exe conftest conftest.*; do
5291 test -f "$ac_file" || continue
5292 case $ac_file in
5293 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5294 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5295 break;;
5296 * ) break;;
5297 esac
5298 done
5299 else
5300 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5301 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5302 as_fn_error "cannot compute suffix of executables: cannot compile and link
5303 See \`config.log' for more details." "$LINENO" 5; }
5305 rm -f conftest conftest$ac_cv_exeext
5306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5307 $as_echo "$ac_cv_exeext" >&6; }
5309 rm -f conftest.$ac_ext
5310 EXEEXT=$ac_cv_exeext
5311 ac_exeext=$EXEEXT
5312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5313 /* end confdefs.h. */
5314 #include <stdio.h>
5316 main ()
5318 FILE *f = fopen ("conftest.out", "w");
5319 return ferror (f) || fclose (f) != 0;
5322 return 0;
5324 _ACEOF
5325 ac_clean_files="$ac_clean_files conftest.out"
5326 # Check that the compiler produces executables we can run. If not, either
5327 # the compiler is broken, or we cross compile.
5328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5329 $as_echo_n "checking whether we are cross compiling... " >&6; }
5330 if test "$cross_compiling" != yes; then
5331 { { ac_try="$ac_link"
5332 case "(($ac_try" in
5333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5334 *) ac_try_echo=$ac_try;;
5335 esac
5336 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5337 $as_echo "$ac_try_echo"; } >&5
5338 (eval "$ac_link") 2>&5
5339 ac_status=$?
5340 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5341 test $ac_status = 0; }
5342 if { ac_try='./conftest$ac_cv_exeext'
5343 { { case "(($ac_try" in
5344 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5345 *) ac_try_echo=$ac_try;;
5346 esac
5347 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5348 $as_echo "$ac_try_echo"; } >&5
5349 (eval "$ac_try") 2>&5
5350 ac_status=$?
5351 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5352 test $ac_status = 0; }; }; then
5353 cross_compiling=no
5354 else
5355 if test "$cross_compiling" = maybe; then
5356 cross_compiling=yes
5357 else
5358 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5359 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5360 as_fn_error "cannot run C compiled programs.
5361 If you meant to cross compile, use \`--host'.
5362 See \`config.log' for more details." "$LINENO" 5; }
5366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5367 $as_echo "$cross_compiling" >&6; }
5369 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5370 ac_clean_files=$ac_clean_files_save
5371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5372 $as_echo_n "checking for suffix of object files... " >&6; }
5373 if test "${ac_cv_objext+set}" = set; then :
5374 $as_echo_n "(cached) " >&6
5375 else
5376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5377 /* end confdefs.h. */
5380 main ()
5384 return 0;
5386 _ACEOF
5387 rm -f conftest.o conftest.obj
5388 if { { ac_try="$ac_compile"
5389 case "(($ac_try" in
5390 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5391 *) ac_try_echo=$ac_try;;
5392 esac
5393 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5394 $as_echo "$ac_try_echo"; } >&5
5395 (eval "$ac_compile") 2>&5
5396 ac_status=$?
5397 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5398 test $ac_status = 0; }; then :
5399 for ac_file in conftest.o conftest.obj conftest.*; do
5400 test -f "$ac_file" || continue;
5401 case $ac_file in
5402 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5403 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5404 break;;
5405 esac
5406 done
5407 else
5408 $as_echo "$as_me: failed program was:" >&5
5409 sed 's/^/| /' conftest.$ac_ext >&5
5411 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5412 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5413 as_fn_error "cannot compute suffix of object files: cannot compile
5414 See \`config.log' for more details." "$LINENO" 5; }
5416 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5419 $as_echo "$ac_cv_objext" >&6; }
5420 OBJEXT=$ac_cv_objext
5421 ac_objext=$OBJEXT
5422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5423 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5424 if test "${ac_cv_c_compiler_gnu+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 ()
5433 #ifndef __GNUC__
5434 choke me
5435 #endif
5438 return 0;
5440 _ACEOF
5441 if ac_fn_c_try_compile "$LINENO"; then :
5442 ac_compiler_gnu=yes
5443 else
5444 ac_compiler_gnu=no
5446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5447 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5451 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5452 if test $ac_compiler_gnu = yes; then
5453 GCC=yes
5454 else
5455 GCC=
5457 ac_test_CFLAGS=${CFLAGS+set}
5458 ac_save_CFLAGS=$CFLAGS
5459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5460 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5461 if test "${ac_cv_prog_cc_g+set}" = set; then :
5462 $as_echo_n "(cached) " >&6
5463 else
5464 ac_save_c_werror_flag=$ac_c_werror_flag
5465 ac_c_werror_flag=yes
5466 ac_cv_prog_cc_g=no
5467 CFLAGS="-g"
5468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5469 /* end confdefs.h. */
5472 main ()
5476 return 0;
5478 _ACEOF
5479 if ac_fn_c_try_compile "$LINENO"; then :
5480 ac_cv_prog_cc_g=yes
5481 else
5482 CFLAGS=""
5483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5484 /* end confdefs.h. */
5487 main ()
5491 return 0;
5493 _ACEOF
5494 if ac_fn_c_try_compile "$LINENO"; then :
5496 else
5497 ac_c_werror_flag=$ac_save_c_werror_flag
5498 CFLAGS="-g"
5499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5500 /* end confdefs.h. */
5503 main ()
5507 return 0;
5509 _ACEOF
5510 if ac_fn_c_try_compile "$LINENO"; then :
5511 ac_cv_prog_cc_g=yes
5513 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5517 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5518 ac_c_werror_flag=$ac_save_c_werror_flag
5520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5521 $as_echo "$ac_cv_prog_cc_g" >&6; }
5522 if test "$ac_test_CFLAGS" = set; then
5523 CFLAGS=$ac_save_CFLAGS
5524 elif test $ac_cv_prog_cc_g = yes; then
5525 if test "$GCC" = yes; then
5526 CFLAGS="-g -O2"
5527 else
5528 CFLAGS="-g"
5530 else
5531 if test "$GCC" = yes; then
5532 CFLAGS="-O2"
5533 else
5534 CFLAGS=
5537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5538 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5539 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5540 $as_echo_n "(cached) " >&6
5541 else
5542 ac_cv_prog_cc_c89=no
5543 ac_save_CC=$CC
5544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5545 /* end confdefs.h. */
5546 #include <stdarg.h>
5547 #include <stdio.h>
5548 #include <sys/types.h>
5549 #include <sys/stat.h>
5550 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5551 struct buf { int x; };
5552 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5553 static char *e (p, i)
5554 char **p;
5555 int i;
5557 return p[i];
5559 static char *f (char * (*g) (char **, int), char **p, ...)
5561 char *s;
5562 va_list v;
5563 va_start (v,p);
5564 s = g (p, va_arg (v,int));
5565 va_end (v);
5566 return s;
5569 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5570 function prototypes and stuff, but not '\xHH' hex character constants.
5571 These don't provoke an error unfortunately, instead are silently treated
5572 as 'x'. The following induces an error, until -std is added to get
5573 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5574 array size at least. It's necessary to write '\x00'==0 to get something
5575 that's true only with -std. */
5576 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5578 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5579 inside strings and character constants. */
5580 #define FOO(x) 'x'
5581 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5583 int test (int i, double x);
5584 struct s1 {int (*f) (int a);};
5585 struct s2 {int (*f) (double a);};
5586 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5587 int argc;
5588 char **argv;
5590 main ()
5592 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5594 return 0;
5596 _ACEOF
5597 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5598 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5600 CC="$ac_save_CC $ac_arg"
5601 if ac_fn_c_try_compile "$LINENO"; then :
5602 ac_cv_prog_cc_c89=$ac_arg
5604 rm -f core conftest.err conftest.$ac_objext
5605 test "x$ac_cv_prog_cc_c89" != "xno" && break
5606 done
5607 rm -f conftest.$ac_ext
5608 CC=$ac_save_CC
5611 # AC_CACHE_VAL
5612 case "x$ac_cv_prog_cc_c89" in
5614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5615 $as_echo "none needed" >&6; } ;;
5616 xno)
5617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5618 $as_echo "unsupported" >&6; } ;;
5620 CC="$CC $ac_cv_prog_cc_c89"
5621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5622 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5623 esac
5624 if test "x$ac_cv_prog_cc_c89" != xno; then :
5628 ac_ext=c
5629 ac_cpp='$CPP $CPPFLAGS'
5630 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5631 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5632 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5633 DEPDIR="${am__leading_dot}deps"
5635 ac_config_commands="$ac_config_commands depfiles"
5638 am_make=${MAKE-make}
5639 cat > confinc << 'END'
5640 am__doit:
5641 @echo this is the am__doit target
5642 .PHONY: am__doit
5644 # If we don't find an include directive, just comment out the code.
5645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5646 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5647 am__include="#"
5648 am__quote=
5649 _am_result=none
5650 # First try GNU make style include.
5651 echo "include confinc" > confmf
5652 # Ignore all kinds of additional output from `make'.
5653 case `$am_make -s -f confmf 2> /dev/null` in #(
5654 *the\ am__doit\ target*)
5655 am__include=include
5656 am__quote=
5657 _am_result=GNU
5659 esac
5660 # Now try BSD make style include.
5661 if test "$am__include" = "#"; then
5662 echo '.include "confinc"' > confmf
5663 case `$am_make -s -f confmf 2> /dev/null` in #(
5664 *the\ am__doit\ target*)
5665 am__include=.include
5666 am__quote="\""
5667 _am_result=BSD
5669 esac
5673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5674 $as_echo "$_am_result" >&6; }
5675 rm -f confinc confmf
5677 # Check whether --enable-dependency-tracking was given.
5678 if test "${enable_dependency_tracking+set}" = set; then :
5679 enableval=$enable_dependency_tracking;
5682 if test "x$enable_dependency_tracking" != xno; then
5683 am_depcomp="$ac_aux_dir/depcomp"
5684 AMDEPBACKSLASH='\'
5686 if test "x$enable_dependency_tracking" != xno; then
5687 AMDEP_TRUE=
5688 AMDEP_FALSE='#'
5689 else
5690 AMDEP_TRUE='#'
5691 AMDEP_FALSE=
5696 depcc="$CC" am_compiler_list=
5698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5699 $as_echo_n "checking dependency style of $depcc... " >&6; }
5700 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5701 $as_echo_n "(cached) " >&6
5702 else
5703 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5704 # We make a subdir and do the tests there. Otherwise we can end up
5705 # making bogus files that we don't know about and never remove. For
5706 # instance it was reported that on HP-UX the gcc test will end up
5707 # making a dummy file named `D' -- because `-MD' means `put the output
5708 # in D'.
5709 mkdir conftest.dir
5710 # Copy depcomp to subdir because otherwise we won't find it if we're
5711 # using a relative directory.
5712 cp "$am_depcomp" conftest.dir
5713 cd conftest.dir
5714 # We will build objects and dependencies in a subdirectory because
5715 # it helps to detect inapplicable dependency modes. For instance
5716 # both Tru64's cc and ICC support -MD to output dependencies as a
5717 # side effect of compilation, but ICC will put the dependencies in
5718 # the current directory while Tru64 will put them in the object
5719 # directory.
5720 mkdir sub
5722 am_cv_CC_dependencies_compiler_type=none
5723 if test "$am_compiler_list" = ""; then
5724 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5726 am__universal=false
5727 case " $depcc " in #(
5728 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5729 esac
5731 for depmode in $am_compiler_list; do
5732 # Setup a source with many dependencies, because some compilers
5733 # like to wrap large dependency lists on column 80 (with \), and
5734 # we should not choose a depcomp mode which is confused by this.
5736 # We need to recreate these files for each test, as the compiler may
5737 # overwrite some of them when testing with obscure command lines.
5738 # This happens at least with the AIX C compiler.
5739 : > sub/conftest.c
5740 for i in 1 2 3 4 5 6; do
5741 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5742 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5743 # Solaris 8's {/usr,}/bin/sh.
5744 touch sub/conftst$i.h
5745 done
5746 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5748 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5749 # mode. It turns out that the SunPro C++ compiler does not properly
5750 # handle `-M -o', and we need to detect this. Also, some Intel
5751 # versions had trouble with output in subdirs
5752 am__obj=sub/conftest.${OBJEXT-o}
5753 am__minus_obj="-o $am__obj"
5754 case $depmode in
5755 gcc)
5756 # This depmode causes a compiler race in universal mode.
5757 test "$am__universal" = false || continue
5759 nosideeffect)
5760 # after this tag, mechanisms are not by side-effect, so they'll
5761 # only be used when explicitly requested
5762 if test "x$enable_dependency_tracking" = xyes; then
5763 continue
5764 else
5765 break
5768 msvisualcpp | msvcmsys)
5769 # This compiler won't grok `-c -o', but also, the minuso test has
5770 # not run yet. These depmodes are late enough in the game, and
5771 # so weak that their functioning should not be impacted.
5772 am__obj=conftest.${OBJEXT-o}
5773 am__minus_obj=
5775 none) break ;;
5776 esac
5777 if depmode=$depmode \
5778 source=sub/conftest.c object=$am__obj \
5779 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5780 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5781 >/dev/null 2>conftest.err &&
5782 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5783 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5784 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5785 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5786 # icc doesn't choke on unknown options, it will just issue warnings
5787 # or remarks (even with -Werror). So we grep stderr for any message
5788 # that says an option was ignored or not supported.
5789 # When given -MP, icc 7.0 and 7.1 complain thusly:
5790 # icc: Command line warning: ignoring option '-M'; no argument required
5791 # The diagnosis changed in icc 8.0:
5792 # icc: Command line remark: option '-MP' not supported
5793 if (grep 'ignoring option' conftest.err ||
5794 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5795 am_cv_CC_dependencies_compiler_type=$depmode
5796 break
5799 done
5801 cd ..
5802 rm -rf conftest.dir
5803 else
5804 am_cv_CC_dependencies_compiler_type=none
5808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5809 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5810 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5813 test "x$enable_dependency_tracking" != xno \
5814 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5815 am__fastdepCC_TRUE=
5816 am__fastdepCC_FALSE='#'
5817 else
5818 am__fastdepCC_TRUE='#'
5819 am__fastdepCC_FALSE=
5823 if test "x$CC" != xcc; then
5824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5825 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5826 else
5827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5828 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5830 set dummy $CC; ac_cc=`$as_echo "$2" |
5831 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5832 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5833 $as_echo_n "(cached) " >&6
5834 else
5835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5836 /* end confdefs.h. */
5839 main ()
5843 return 0;
5845 _ACEOF
5846 # Make sure it works both with $CC and with simple cc.
5847 # We do the test twice because some compilers refuse to overwrite an
5848 # existing .o file with -o, though they will create one.
5849 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5850 rm -f conftest2.*
5851 if { { case "(($ac_try" in
5852 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5853 *) ac_try_echo=$ac_try;;
5854 esac
5855 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5856 $as_echo "$ac_try_echo"; } >&5
5857 (eval "$ac_try") 2>&5
5858 ac_status=$?
5859 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5860 test $ac_status = 0; } &&
5861 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5862 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5863 *) ac_try_echo=$ac_try;;
5864 esac
5865 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5866 $as_echo "$ac_try_echo"; } >&5
5867 (eval "$ac_try") 2>&5
5868 ac_status=$?
5869 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5870 test $ac_status = 0; };
5871 then
5872 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5873 if test "x$CC" != xcc; then
5874 # Test first that cc exists at all.
5875 if { ac_try='cc -c conftest.$ac_ext >&5'
5876 { { case "(($ac_try" in
5877 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5878 *) ac_try_echo=$ac_try;;
5879 esac
5880 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5881 $as_echo "$ac_try_echo"; } >&5
5882 (eval "$ac_try") 2>&5
5883 ac_status=$?
5884 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5885 test $ac_status = 0; }; }; then
5886 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5887 rm -f conftest2.*
5888 if { { case "(($ac_try" in
5889 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5890 *) ac_try_echo=$ac_try;;
5891 esac
5892 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5893 $as_echo "$ac_try_echo"; } >&5
5894 (eval "$ac_try") 2>&5
5895 ac_status=$?
5896 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5897 test $ac_status = 0; } &&
5898 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5899 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5900 *) ac_try_echo=$ac_try;;
5901 esac
5902 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5903 $as_echo "$ac_try_echo"; } >&5
5904 (eval "$ac_try") 2>&5
5905 ac_status=$?
5906 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5907 test $ac_status = 0; };
5908 then
5909 # cc works too.
5911 else
5912 # cc exists but doesn't like -o.
5913 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5917 else
5918 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5920 rm -f core conftest*
5923 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5925 $as_echo "yes" >&6; }
5926 else
5927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5928 $as_echo "no" >&6; }
5930 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5934 # FIXME: we rely on the cache variable name because
5935 # there is no other way.
5936 set dummy $CC
5937 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5938 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5939 if test "$am_t" != yes; then
5940 # Losing compiler, so override with the script.
5941 # FIXME: It is wrong to rewrite CC.
5942 # But if we don't then we get into trouble of one sort or another.
5943 # A longer-term fix would be to have automake use am__CC in this case,
5944 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5945 CC="$am_aux_dir/compile $CC"
5950 if test x$GCC = xyes; then
5951 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5952 else
5953 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5956 if test "x$opsys" = "xmingw32"; then
5957 BUILDING_FOR_WINDOWSNT_TRUE=
5958 BUILDING_FOR_WINDOWSNT_FALSE='#'
5959 else
5960 BUILDING_FOR_WINDOWSNT_TRUE='#'
5961 BUILDING_FOR_WINDOWSNT_FALSE=
5965 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
5966 # as we don't use them.
5968 # Avoid gnulib's threadlib module, as we do threads our own way.
5971 # Initialize gnulib right after choosing the compiler.
5973 ac_ext=c
5974 ac_cpp='$CPP $CPPFLAGS'
5975 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5976 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5977 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5979 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5980 # On Suns, sometimes $CPP names a directory.
5981 if test -n "$CPP" && test -d "$CPP"; then
5982 CPP=
5984 if test -z "$CPP"; then
5985 if test "${ac_cv_prog_CPP+set}" = set; then :
5986 $as_echo_n "(cached) " >&6
5987 else
5988 # Double quotes because CPP needs to be expanded
5989 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5991 ac_preproc_ok=false
5992 for ac_c_preproc_warn_flag in '' yes
5994 # Use a header file that comes with gcc, so configuring glibc
5995 # with a fresh cross-compiler works.
5996 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5997 # <limits.h> exists even on freestanding compilers.
5998 # On the NeXT, cc -E runs the code through the compiler's parser,
5999 # not just through cpp. "Syntax error" is here to catch this case.
6000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6001 /* end confdefs.h. */
6002 #ifdef __STDC__
6003 # include <limits.h>
6004 #else
6005 # include <assert.h>
6006 #endif
6007 Syntax error
6008 _ACEOF
6009 if ac_fn_c_try_cpp "$LINENO"; then :
6011 else
6012 # Broken: fails on valid input.
6013 continue
6015 rm -f conftest.err conftest.$ac_ext
6017 # OK, works on sane cases. Now check whether nonexistent headers
6018 # can be detected and how.
6019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6020 /* end confdefs.h. */
6021 #include <ac_nonexistent.h>
6022 _ACEOF
6023 if ac_fn_c_try_cpp "$LINENO"; then :
6024 # Broken: success on invalid input.
6025 continue
6026 else
6027 # Passes both tests.
6028 ac_preproc_ok=:
6029 break
6031 rm -f conftest.err conftest.$ac_ext
6033 done
6034 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6035 rm -f conftest.err conftest.$ac_ext
6036 if $ac_preproc_ok; then :
6037 break
6040 done
6041 ac_cv_prog_CPP=$CPP
6044 CPP=$ac_cv_prog_CPP
6045 else
6046 ac_cv_prog_CPP=$CPP
6048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6049 $as_echo "$CPP" >&6; }
6050 ac_preproc_ok=false
6051 for ac_c_preproc_warn_flag in '' yes
6053 # Use a header file that comes with gcc, so configuring glibc
6054 # with a fresh cross-compiler works.
6055 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6056 # <limits.h> exists even on freestanding compilers.
6057 # On the NeXT, cc -E runs the code through the compiler's parser,
6058 # not just through cpp. "Syntax error" is here to catch this case.
6059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h. */
6061 #ifdef __STDC__
6062 # include <limits.h>
6063 #else
6064 # include <assert.h>
6065 #endif
6066 Syntax error
6067 _ACEOF
6068 if ac_fn_c_try_cpp "$LINENO"; then :
6070 else
6071 # Broken: fails on valid input.
6072 continue
6074 rm -f conftest.err conftest.$ac_ext
6076 # OK, works on sane cases. Now check whether nonexistent headers
6077 # can be detected and how.
6078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6079 /* end confdefs.h. */
6080 #include <ac_nonexistent.h>
6081 _ACEOF
6082 if ac_fn_c_try_cpp "$LINENO"; then :
6083 # Broken: success on invalid input.
6084 continue
6085 else
6086 # Passes both tests.
6087 ac_preproc_ok=:
6088 break
6090 rm -f conftest.err conftest.$ac_ext
6092 done
6093 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6094 rm -f conftest.err conftest.$ac_ext
6095 if $ac_preproc_ok; then :
6097 else
6098 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6099 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6100 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6101 See \`config.log' for more details." "$LINENO" 5; }
6104 ac_ext=c
6105 ac_cpp='$CPP $CPPFLAGS'
6106 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6107 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6108 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6112 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6113 if test "${ac_cv_path_GREP+set}" = set; then :
6114 $as_echo_n "(cached) " >&6
6115 else
6116 if test -z "$GREP"; then
6117 ac_path_GREP_found=false
6118 # Loop through the user's path and test for each of PROGNAME-LIST
6119 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6120 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6122 IFS=$as_save_IFS
6123 test -z "$as_dir" && as_dir=.
6124 for ac_prog in grep ggrep; do
6125 for ac_exec_ext in '' $ac_executable_extensions; do
6126 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6127 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6128 # Check for GNU ac_path_GREP and select it if it is found.
6129 # Check for GNU $ac_path_GREP
6130 case `"$ac_path_GREP" --version 2>&1` in
6131 *GNU*)
6132 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6134 ac_count=0
6135 $as_echo_n 0123456789 >"conftest.in"
6136 while :
6138 cat "conftest.in" "conftest.in" >"conftest.tmp"
6139 mv "conftest.tmp" "conftest.in"
6140 cp "conftest.in" "conftest.nl"
6141 $as_echo 'GREP' >> "conftest.nl"
6142 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6143 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6144 as_fn_arith $ac_count + 1 && ac_count=$as_val
6145 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6146 # Best one so far, save it but keep looking for a better one
6147 ac_cv_path_GREP="$ac_path_GREP"
6148 ac_path_GREP_max=$ac_count
6150 # 10*(2^10) chars as input seems more than enough
6151 test $ac_count -gt 10 && break
6152 done
6153 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6154 esac
6156 $ac_path_GREP_found && break 3
6157 done
6158 done
6159 done
6160 IFS=$as_save_IFS
6161 if test -z "$ac_cv_path_GREP"; then
6162 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6164 else
6165 ac_cv_path_GREP=$GREP
6169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6170 $as_echo "$ac_cv_path_GREP" >&6; }
6171 GREP="$ac_cv_path_GREP"
6174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6175 $as_echo_n "checking for egrep... " >&6; }
6176 if test "${ac_cv_path_EGREP+set}" = set; then :
6177 $as_echo_n "(cached) " >&6
6178 else
6179 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6180 then ac_cv_path_EGREP="$GREP -E"
6181 else
6182 if test -z "$EGREP"; then
6183 ac_path_EGREP_found=false
6184 # Loop through the user's path and test for each of PROGNAME-LIST
6185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6186 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6188 IFS=$as_save_IFS
6189 test -z "$as_dir" && as_dir=.
6190 for ac_prog in egrep; do
6191 for ac_exec_ext in '' $ac_executable_extensions; do
6192 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6193 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6194 # Check for GNU ac_path_EGREP and select it if it is found.
6195 # Check for GNU $ac_path_EGREP
6196 case `"$ac_path_EGREP" --version 2>&1` in
6197 *GNU*)
6198 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6200 ac_count=0
6201 $as_echo_n 0123456789 >"conftest.in"
6202 while :
6204 cat "conftest.in" "conftest.in" >"conftest.tmp"
6205 mv "conftest.tmp" "conftest.in"
6206 cp "conftest.in" "conftest.nl"
6207 $as_echo 'EGREP' >> "conftest.nl"
6208 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6209 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6210 as_fn_arith $ac_count + 1 && ac_count=$as_val
6211 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6212 # Best one so far, save it but keep looking for a better one
6213 ac_cv_path_EGREP="$ac_path_EGREP"
6214 ac_path_EGREP_max=$ac_count
6216 # 10*(2^10) chars as input seems more than enough
6217 test $ac_count -gt 10 && break
6218 done
6219 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6220 esac
6222 $ac_path_EGREP_found && break 3
6223 done
6224 done
6225 done
6226 IFS=$as_save_IFS
6227 if test -z "$ac_cv_path_EGREP"; then
6228 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6230 else
6231 ac_cv_path_EGREP=$EGREP
6236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6237 $as_echo "$ac_cv_path_EGREP" >&6; }
6238 EGREP="$ac_cv_path_EGREP"
6243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6244 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6245 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6246 $as_echo_n "(cached) " >&6
6247 else
6249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6250 /* end confdefs.h. */
6252 #ifdef __ACK__
6253 Amsterdam
6254 #endif
6256 _ACEOF
6257 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6258 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6259 gl_cv_c_amsterdam_compiler=yes
6260 else
6261 gl_cv_c_amsterdam_compiler=no
6263 rm -f conftest*
6267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6268 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6269 if test -z "$AR"; then
6270 if test $gl_cv_c_amsterdam_compiler = yes; then
6271 AR='cc -c.a'
6272 if test -z "$ARFLAGS"; then
6273 ARFLAGS='-o'
6275 else
6276 if test -n "$ac_tool_prefix"; then
6277 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6278 set dummy ${ac_tool_prefix}ar; ac_word=$2
6279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6280 $as_echo_n "checking for $ac_word... " >&6; }
6281 if test "${ac_cv_prog_AR+set}" = set; then :
6282 $as_echo_n "(cached) " >&6
6283 else
6284 if test -n "$AR"; then
6285 ac_cv_prog_AR="$AR" # Let the user override the test.
6286 else
6287 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6288 for as_dir in $PATH
6290 IFS=$as_save_IFS
6291 test -z "$as_dir" && as_dir=.
6292 for ac_exec_ext in '' $ac_executable_extensions; do
6293 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6294 ac_cv_prog_AR="${ac_tool_prefix}ar"
6295 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6296 break 2
6298 done
6299 done
6300 IFS=$as_save_IFS
6304 AR=$ac_cv_prog_AR
6305 if test -n "$AR"; then
6306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6307 $as_echo "$AR" >&6; }
6308 else
6309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6310 $as_echo "no" >&6; }
6315 if test -z "$ac_cv_prog_AR"; then
6316 ac_ct_AR=$AR
6317 # Extract the first word of "ar", so it can be a program name with args.
6318 set dummy ar; ac_word=$2
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6320 $as_echo_n "checking for $ac_word... " >&6; }
6321 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6322 $as_echo_n "(cached) " >&6
6323 else
6324 if test -n "$ac_ct_AR"; then
6325 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6326 else
6327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6328 for as_dir in $PATH
6330 IFS=$as_save_IFS
6331 test -z "$as_dir" && as_dir=.
6332 for ac_exec_ext in '' $ac_executable_extensions; do
6333 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6334 ac_cv_prog_ac_ct_AR="ar"
6335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6336 break 2
6338 done
6339 done
6340 IFS=$as_save_IFS
6344 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6345 if test -n "$ac_ct_AR"; then
6346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6347 $as_echo "$ac_ct_AR" >&6; }
6348 else
6349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6350 $as_echo "no" >&6; }
6353 if test "x$ac_ct_AR" = x; then
6354 AR="ar"
6355 else
6356 case $cross_compiling:$ac_tool_warned in
6357 yes:)
6358 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6359 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6360 ac_tool_warned=yes ;;
6361 esac
6362 AR=$ac_ct_AR
6364 else
6365 AR="$ac_cv_prog_AR"
6368 if test -z "$ARFLAGS"; then
6369 ARFLAGS='cru'
6372 else
6373 if test -z "$ARFLAGS"; then
6374 ARFLAGS='cru'
6379 if test -z "$RANLIB"; then
6380 if test $gl_cv_c_amsterdam_compiler = yes; then
6381 RANLIB=':'
6382 else
6383 if test -n "$ac_tool_prefix"; then
6384 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6385 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6387 $as_echo_n "checking for $ac_word... " >&6; }
6388 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6389 $as_echo_n "(cached) " >&6
6390 else
6391 if test -n "$RANLIB"; then
6392 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6393 else
6394 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6395 for as_dir in $PATH
6397 IFS=$as_save_IFS
6398 test -z "$as_dir" && as_dir=.
6399 for ac_exec_ext in '' $ac_executable_extensions; do
6400 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6401 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6402 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6403 break 2
6405 done
6406 done
6407 IFS=$as_save_IFS
6411 RANLIB=$ac_cv_prog_RANLIB
6412 if test -n "$RANLIB"; then
6413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6414 $as_echo "$RANLIB" >&6; }
6415 else
6416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6417 $as_echo "no" >&6; }
6422 if test -z "$ac_cv_prog_RANLIB"; then
6423 ac_ct_RANLIB=$RANLIB
6424 # Extract the first word of "ranlib", so it can be a program name with args.
6425 set dummy ranlib; ac_word=$2
6426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6427 $as_echo_n "checking for $ac_word... " >&6; }
6428 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6429 $as_echo_n "(cached) " >&6
6430 else
6431 if test -n "$ac_ct_RANLIB"; then
6432 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6433 else
6434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6435 for as_dir in $PATH
6437 IFS=$as_save_IFS
6438 test -z "$as_dir" && as_dir=.
6439 for ac_exec_ext in '' $ac_executable_extensions; do
6440 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6441 ac_cv_prog_ac_ct_RANLIB="ranlib"
6442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6443 break 2
6445 done
6446 done
6447 IFS=$as_save_IFS
6451 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6452 if test -n "$ac_ct_RANLIB"; then
6453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6454 $as_echo "$ac_ct_RANLIB" >&6; }
6455 else
6456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6457 $as_echo "no" >&6; }
6460 if test "x$ac_ct_RANLIB" = x; then
6461 RANLIB=":"
6462 else
6463 case $cross_compiling:$ac_tool_warned in
6464 yes:)
6465 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6466 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6467 ac_tool_warned=yes ;;
6468 esac
6469 RANLIB=$ac_ct_RANLIB
6471 else
6472 RANLIB="$ac_cv_prog_RANLIB"
6479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6480 $as_echo_n "checking for ANSI C header files... " >&6; }
6481 if test "${ac_cv_header_stdc+set}" = set; then :
6482 $as_echo_n "(cached) " >&6
6483 else
6484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6485 /* end confdefs.h. */
6486 #include <stdlib.h>
6487 #include <stdarg.h>
6488 #include <string.h>
6489 #include <float.h>
6492 main ()
6496 return 0;
6498 _ACEOF
6499 if ac_fn_c_try_compile "$LINENO"; then :
6500 ac_cv_header_stdc=yes
6501 else
6502 ac_cv_header_stdc=no
6504 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6506 if test $ac_cv_header_stdc = yes; then
6507 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6509 /* end confdefs.h. */
6510 #include <string.h>
6512 _ACEOF
6513 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6514 $EGREP "memchr" >/dev/null 2>&1; then :
6516 else
6517 ac_cv_header_stdc=no
6519 rm -f conftest*
6523 if test $ac_cv_header_stdc = yes; then
6524 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6526 /* end confdefs.h. */
6527 #include <stdlib.h>
6529 _ACEOF
6530 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6531 $EGREP "free" >/dev/null 2>&1; then :
6533 else
6534 ac_cv_header_stdc=no
6536 rm -f conftest*
6540 if test $ac_cv_header_stdc = yes; then
6541 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6542 if test "$cross_compiling" = yes; then :
6544 else
6545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6546 /* end confdefs.h. */
6547 #include <ctype.h>
6548 #include <stdlib.h>
6549 #if ((' ' & 0x0FF) == 0x020)
6550 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6551 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6552 #else
6553 # define ISLOWER(c) \
6554 (('a' <= (c) && (c) <= 'i') \
6555 || ('j' <= (c) && (c) <= 'r') \
6556 || ('s' <= (c) && (c) <= 'z'))
6557 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6558 #endif
6560 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6562 main ()
6564 int i;
6565 for (i = 0; i < 256; i++)
6566 if (XOR (islower (i), ISLOWER (i))
6567 || toupper (i) != TOUPPER (i))
6568 return 2;
6569 return 0;
6571 _ACEOF
6572 if ac_fn_c_try_run "$LINENO"; then :
6574 else
6575 ac_cv_header_stdc=no
6577 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6578 conftest.$ac_objext conftest.beam conftest.$ac_ext
6583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6584 $as_echo "$ac_cv_header_stdc" >&6; }
6585 if test $ac_cv_header_stdc = yes; then
6587 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6591 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6592 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6593 inttypes.h stdint.h unistd.h
6594 do :
6595 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6596 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6598 eval as_val=\$$as_ac_Header
6599 if test "x$as_val" = x""yes; then :
6600 cat >>confdefs.h <<_ACEOF
6601 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6602 _ACEOF
6606 done
6610 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6611 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6612 MINIX=yes
6613 else
6614 MINIX=
6618 if test "$MINIX" = yes; then
6620 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6623 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6626 $as_echo "#define _MINIX 1" >>confdefs.h
6629 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6635 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6636 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6637 $as_echo_n "(cached) " >&6
6638 else
6639 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6640 /* end confdefs.h. */
6642 # define __EXTENSIONS__ 1
6643 $ac_includes_default
6645 main ()
6649 return 0;
6651 _ACEOF
6652 if ac_fn_c_try_compile "$LINENO"; then :
6653 ac_cv_safe_to_define___extensions__=yes
6654 else
6655 ac_cv_safe_to_define___extensions__=no
6657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6660 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6661 test $ac_cv_safe_to_define___extensions__ = yes &&
6662 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6664 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6666 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6668 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6670 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6672 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6675 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6676 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6677 $as_echo_n "(cached) " >&6
6678 else
6679 ac_cv_should_define__xopen_source=no
6680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6681 /* end confdefs.h. */
6683 #include <wchar.h>
6684 mbstate_t x;
6686 main ()
6690 return 0;
6692 _ACEOF
6693 if ac_fn_c_try_compile "$LINENO"; then :
6695 else
6696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6697 /* end confdefs.h. */
6699 #define _XOPEN_SOURCE 500
6700 #include <wchar.h>
6701 mbstate_t x;
6703 main ()
6707 return 0;
6709 _ACEOF
6710 if ac_fn_c_try_compile "$LINENO"; then :
6711 ac_cv_should_define__xopen_source=yes
6713 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6715 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6718 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6719 test $ac_cv_should_define__xopen_source = yes &&
6720 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6729 # Check whether --enable-largefile was given.
6730 if test "${enable_largefile+set}" = set; then :
6731 enableval=$enable_largefile;
6734 if test "$enable_largefile" != no; then
6736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6737 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6738 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6739 $as_echo_n "(cached) " >&6
6740 else
6741 ac_cv_sys_largefile_CC=no
6742 if test "$GCC" != yes; then
6743 ac_save_CC=$CC
6744 while :; do
6745 # IRIX 6.2 and later do not support large files by default,
6746 # so use the C compiler's -n32 option if that helps.
6747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6748 /* end confdefs.h. */
6749 #include <sys/types.h>
6750 /* Check that off_t can represent 2**63 - 1 correctly.
6751 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6752 since some C++ compilers masquerading as C compilers
6753 incorrectly reject 9223372036854775807. */
6754 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6755 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6756 && LARGE_OFF_T % 2147483647 == 1)
6757 ? 1 : -1];
6759 main ()
6763 return 0;
6765 _ACEOF
6766 if ac_fn_c_try_compile "$LINENO"; then :
6767 break
6769 rm -f core conftest.err conftest.$ac_objext
6770 CC="$CC -n32"
6771 if ac_fn_c_try_compile "$LINENO"; then :
6772 ac_cv_sys_largefile_CC=' -n32'; break
6774 rm -f core conftest.err conftest.$ac_objext
6775 break
6776 done
6777 CC=$ac_save_CC
6778 rm -f conftest.$ac_ext
6781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6782 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6783 if test "$ac_cv_sys_largefile_CC" != no; then
6784 CC=$CC$ac_cv_sys_largefile_CC
6787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6788 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6789 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6790 $as_echo_n "(cached) " >&6
6791 else
6792 while :; do
6793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6794 /* end confdefs.h. */
6795 #include <sys/types.h>
6796 /* Check that off_t can represent 2**63 - 1 correctly.
6797 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6798 since some C++ compilers masquerading as C compilers
6799 incorrectly reject 9223372036854775807. */
6800 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6801 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6802 && LARGE_OFF_T % 2147483647 == 1)
6803 ? 1 : -1];
6805 main ()
6809 return 0;
6811 _ACEOF
6812 if ac_fn_c_try_compile "$LINENO"; then :
6813 ac_cv_sys_file_offset_bits=no; break
6815 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6817 /* end confdefs.h. */
6818 #define _FILE_OFFSET_BITS 64
6819 #include <sys/types.h>
6820 /* Check that off_t can represent 2**63 - 1 correctly.
6821 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6822 since some C++ compilers masquerading as C compilers
6823 incorrectly reject 9223372036854775807. */
6824 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6825 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6826 && LARGE_OFF_T % 2147483647 == 1)
6827 ? 1 : -1];
6829 main ()
6833 return 0;
6835 _ACEOF
6836 if ac_fn_c_try_compile "$LINENO"; then :
6837 ac_cv_sys_file_offset_bits=64; break
6839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6840 ac_cv_sys_file_offset_bits=unknown
6841 break
6842 done
6844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6845 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6846 case $ac_cv_sys_file_offset_bits in #(
6847 no | unknown) ;;
6849 cat >>confdefs.h <<_ACEOF
6850 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6851 _ACEOF
6853 esac
6854 rm -rf conftest*
6855 if test $ac_cv_sys_file_offset_bits = unknown; then
6856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6857 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6858 if test "${ac_cv_sys_large_files+set}" = set; then :
6859 $as_echo_n "(cached) " >&6
6860 else
6861 while :; do
6862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6863 /* end confdefs.h. */
6864 #include <sys/types.h>
6865 /* Check that off_t can represent 2**63 - 1 correctly.
6866 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6867 since some C++ compilers masquerading as C compilers
6868 incorrectly reject 9223372036854775807. */
6869 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6870 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6871 && LARGE_OFF_T % 2147483647 == 1)
6872 ? 1 : -1];
6874 main ()
6878 return 0;
6880 _ACEOF
6881 if ac_fn_c_try_compile "$LINENO"; then :
6882 ac_cv_sys_large_files=no; break
6884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6886 /* end confdefs.h. */
6887 #define _LARGE_FILES 1
6888 #include <sys/types.h>
6889 /* Check that off_t can represent 2**63 - 1 correctly.
6890 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6891 since some C++ compilers masquerading as C compilers
6892 incorrectly reject 9223372036854775807. */
6893 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6894 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6895 && LARGE_OFF_T % 2147483647 == 1)
6896 ? 1 : -1];
6898 main ()
6902 return 0;
6904 _ACEOF
6905 if ac_fn_c_try_compile "$LINENO"; then :
6906 ac_cv_sys_large_files=1; break
6908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6909 ac_cv_sys_large_files=unknown
6910 break
6911 done
6913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6914 $as_echo "$ac_cv_sys_large_files" >&6; }
6915 case $ac_cv_sys_large_files in #(
6916 no | unknown) ;;
6918 cat >>confdefs.h <<_ACEOF
6919 #define _LARGE_FILES $ac_cv_sys_large_files
6920 _ACEOF
6922 esac
6923 rm -rf conftest*
6927 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6931 case $ac_cv_prog_cc_stdc in #(
6932 no) :
6933 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6934 *) :
6935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6936 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6937 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6938 $as_echo_n "(cached) " >&6
6939 else
6940 ac_cv_prog_cc_c99=no
6941 ac_save_CC=$CC
6942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6943 /* end confdefs.h. */
6944 #include <stdarg.h>
6945 #include <stdbool.h>
6946 #include <stdlib.h>
6947 #include <wchar.h>
6948 #include <stdio.h>
6950 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6951 #define debug(...) fprintf (stderr, __VA_ARGS__)
6952 #define showlist(...) puts (#__VA_ARGS__)
6953 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6954 static void
6955 test_varargs_macros (void)
6957 int x = 1234;
6958 int y = 5678;
6959 debug ("Flag");
6960 debug ("X = %d\n", x);
6961 showlist (The first, second, and third items.);
6962 report (x>y, "x is %d but y is %d", x, y);
6965 // Check long long types.
6966 #define BIG64 18446744073709551615ull
6967 #define BIG32 4294967295ul
6968 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6969 #if !BIG_OK
6970 your preprocessor is broken;
6971 #endif
6972 #if BIG_OK
6973 #else
6974 your preprocessor is broken;
6975 #endif
6976 static long long int bignum = -9223372036854775807LL;
6977 static unsigned long long int ubignum = BIG64;
6979 struct incomplete_array
6981 int datasize;
6982 double data[];
6985 struct named_init {
6986 int number;
6987 const wchar_t *name;
6988 double average;
6991 typedef const char *ccp;
6993 static inline int
6994 test_restrict (ccp restrict text)
6996 // See if C++-style comments work.
6997 // Iterate through items via the restricted pointer.
6998 // Also check for declarations in for loops.
6999 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7000 continue;
7001 return 0;
7004 // Check varargs and va_copy.
7005 static void
7006 test_varargs (const char *format, ...)
7008 va_list args;
7009 va_start (args, format);
7010 va_list args_copy;
7011 va_copy (args_copy, args);
7013 const char *str;
7014 int number;
7015 float fnumber;
7017 while (*format)
7019 switch (*format++)
7021 case 's': // string
7022 str = va_arg (args_copy, const char *);
7023 break;
7024 case 'd': // int
7025 number = va_arg (args_copy, int);
7026 break;
7027 case 'f': // float
7028 fnumber = va_arg (args_copy, double);
7029 break;
7030 default:
7031 break;
7034 va_end (args_copy);
7035 va_end (args);
7039 main ()
7042 // Check bool.
7043 _Bool success = false;
7045 // Check restrict.
7046 if (test_restrict ("String literal") == 0)
7047 success = true;
7048 char *restrict newvar = "Another string";
7050 // Check varargs.
7051 test_varargs ("s, d' f .", "string", 65, 34.234);
7052 test_varargs_macros ();
7054 // Check flexible array members.
7055 struct incomplete_array *ia =
7056 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7057 ia->datasize = 10;
7058 for (int i = 0; i < ia->datasize; ++i)
7059 ia->data[i] = i * 1.234;
7061 // Check named initializers.
7062 struct named_init ni = {
7063 .number = 34,
7064 .name = L"Test wide string",
7065 .average = 543.34343,
7068 ni.number = 58;
7070 int dynamic_array[ni.number];
7071 dynamic_array[ni.number - 1] = 543;
7073 // work around unused variable warnings
7074 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7075 || dynamic_array[ni.number - 1] != 543);
7078 return 0;
7080 _ACEOF
7081 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7083 CC="$ac_save_CC $ac_arg"
7084 if ac_fn_c_try_compile "$LINENO"; then :
7085 ac_cv_prog_cc_c99=$ac_arg
7087 rm -f core conftest.err conftest.$ac_objext
7088 test "x$ac_cv_prog_cc_c99" != "xno" && break
7089 done
7090 rm -f conftest.$ac_ext
7091 CC=$ac_save_CC
7094 # AC_CACHE_VAL
7095 case "x$ac_cv_prog_cc_c99" in
7097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7098 $as_echo "none needed" >&6; } ;;
7099 xno)
7100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7101 $as_echo "unsupported" >&6; } ;;
7103 CC="$CC $ac_cv_prog_cc_c99"
7104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7105 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7106 esac
7107 if test "x$ac_cv_prog_cc_c99" != xno; then :
7108 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7109 else
7110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7111 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7112 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7113 $as_echo_n "(cached) " >&6
7114 else
7115 ac_cv_prog_cc_c89=no
7116 ac_save_CC=$CC
7117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7118 /* end confdefs.h. */
7119 #include <stdarg.h>
7120 #include <stdio.h>
7121 #include <sys/types.h>
7122 #include <sys/stat.h>
7123 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7124 struct buf { int x; };
7125 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7126 static char *e (p, i)
7127 char **p;
7128 int i;
7130 return p[i];
7132 static char *f (char * (*g) (char **, int), char **p, ...)
7134 char *s;
7135 va_list v;
7136 va_start (v,p);
7137 s = g (p, va_arg (v,int));
7138 va_end (v);
7139 return s;
7142 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7143 function prototypes and stuff, but not '\xHH' hex character constants.
7144 These don't provoke an error unfortunately, instead are silently treated
7145 as 'x'. The following induces an error, until -std is added to get
7146 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7147 array size at least. It's necessary to write '\x00'==0 to get something
7148 that's true only with -std. */
7149 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7151 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7152 inside strings and character constants. */
7153 #define FOO(x) 'x'
7154 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7156 int test (int i, double x);
7157 struct s1 {int (*f) (int a);};
7158 struct s2 {int (*f) (double a);};
7159 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7160 int argc;
7161 char **argv;
7163 main ()
7165 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7167 return 0;
7169 _ACEOF
7170 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7171 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7173 CC="$ac_save_CC $ac_arg"
7174 if ac_fn_c_try_compile "$LINENO"; then :
7175 ac_cv_prog_cc_c89=$ac_arg
7177 rm -f core conftest.err conftest.$ac_objext
7178 test "x$ac_cv_prog_cc_c89" != "xno" && break
7179 done
7180 rm -f conftest.$ac_ext
7181 CC=$ac_save_CC
7184 # AC_CACHE_VAL
7185 case "x$ac_cv_prog_cc_c89" in
7187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7188 $as_echo "none needed" >&6; } ;;
7189 xno)
7190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7191 $as_echo "unsupported" >&6; } ;;
7193 CC="$CC $ac_cv_prog_cc_c89"
7194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7195 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7196 esac
7197 if test "x$ac_cv_prog_cc_c89" != xno; then :
7198 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7199 else
7200 ac_cv_prog_cc_stdc=no
7205 esac
7206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7207 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7208 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7209 $as_echo_n "(cached) " >&6
7212 case $ac_cv_prog_cc_stdc in #(
7213 no) :
7214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7215 $as_echo "unsupported" >&6; } ;; #(
7216 '') :
7217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7218 $as_echo "none needed" >&6; } ;; #(
7219 *) :
7220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7221 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7222 esac
7226 # Code from module alloca-opt:
7227 # Code from module allocator:
7228 # Code from module at-internal:
7229 # Code from module c-ctype:
7230 # Code from module c-strcase:
7231 # Code from module careadlinkat:
7232 # Code from module clock-time:
7233 # Code from module close-stream:
7234 # Code from module crypto/md5:
7235 # Code from module crypto/sha1:
7236 # Code from module crypto/sha256:
7237 # Code from module crypto/sha512:
7238 # Code from module dirent:
7239 # Code from module dosname:
7240 # Code from module dtoastr:
7241 # Code from module dtotimespec:
7242 # Code from module dup2:
7243 # Code from module environ:
7244 # Code from module errno:
7245 # Code from module euidaccess:
7246 # Code from module execinfo:
7247 # Code from module extensions:
7249 # Code from module extern-inline:
7250 # Code from module faccessat:
7251 # Code from module fcntl-h:
7252 # Code from module fdatasync:
7253 # Code from module fdopendir:
7254 # Code from module filemode:
7255 # Code from module fpending:
7256 # Code from module fstatat:
7257 # Code from module fsync:
7258 # Code from module getgroups:
7259 # Code from module getloadavg:
7260 # Code from module getopt-gnu:
7261 # Code from module getopt-posix:
7262 # Code from module gettext-h:
7263 # Code from module gettime:
7264 # Code from module gettimeofday:
7265 # Code from module group-member:
7266 # Code from module ignore-value:
7267 # Code from module include_next:
7268 # Code from module intprops:
7269 # Code from module inttypes-incomplete:
7270 # Code from module largefile:
7272 # Code from module lstat:
7273 # Code from module manywarnings:
7274 # Code from module memrchr:
7275 # Code from module mktime:
7276 # Code from module multiarch:
7277 # Code from module nocrash:
7278 # Code from module openat-h:
7279 # Code from module pathmax:
7280 # Code from module pselect:
7281 # Code from module pthread_sigmask:
7282 # Code from module putenv:
7283 # Code from module qacl:
7284 # Code from module readlink:
7285 # Code from module readlinkat:
7286 # Code from module root-uid:
7287 # Code from module sig2str:
7288 # Code from module signal-h:
7289 # Code from module snippet/_Noreturn:
7290 # Code from module snippet/arg-nonnull:
7291 # Code from module snippet/c++defs:
7292 # Code from module snippet/warn-on-use:
7293 # Code from module socklen:
7294 # Code from module ssize_t:
7295 # Code from module stat:
7296 # Code from module stat-time:
7297 # Code from module stdalign:
7298 # Code from module stdarg:
7302 # Code from module stdbool:
7303 # Code from module stddef:
7304 # Code from module stdint:
7305 # Code from module stdio:
7306 # Code from module stdlib:
7307 # Code from module strftime:
7308 # Code from module string:
7309 # Code from module strtoimax:
7310 # Code from module strtoll:
7311 # Code from module strtoull:
7312 # Code from module strtoumax:
7313 # Code from module symlink:
7314 # Code from module sys_select:
7315 # Code from module sys_stat:
7316 # Code from module sys_time:
7317 # Code from module time:
7318 # Code from module time_r:
7319 # Code from module timer-time:
7320 # Code from module timespec:
7321 # Code from module timespec-add:
7322 # Code from module timespec-sub:
7323 # Code from module u64:
7324 # Code from module unistd:
7325 # Code from module unsetenv:
7326 # Code from module utimens:
7327 # Code from module verify:
7328 # Code from module warnings:
7329 # Code from module xalloc-oversized:
7332 if test "$ac_test_CFLAGS" != set; then
7333 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7334 # if -g3 works and the user does not specify CFLAGS.
7335 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7336 case $CFLAGS in
7337 '-g')
7338 emacs_g3_CFLAGS='-g3';;
7339 '-g -O2')
7340 emacs_g3_CFLAGS='-g3 -O2';;
7342 emacs_g3_CFLAGS='';;
7343 esac
7344 if test -n "$emacs_g3_CFLAGS"; then
7345 emacs_save_CFLAGS=$CFLAGS
7346 CFLAGS=$emacs_g3_CFLAGS
7347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7348 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7349 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7350 $as_echo_n "(cached) " >&6
7351 else
7352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7353 /* end confdefs.h. */
7356 main ()
7360 return 0;
7362 _ACEOF
7363 if ac_fn_c_try_link "$LINENO"; then :
7364 emacs_cv_prog_cc_g3=yes
7365 else
7366 emacs_cv_prog_cc_g3=no
7368 rm -f core conftest.err conftest.$ac_objext \
7369 conftest$ac_exeext conftest.$ac_ext
7371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7372 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7373 if test $emacs_cv_prog_cc_g3 != yes; then
7374 CFLAGS=$emacs_save_CFLAGS
7376 if test $opsys = mingw32; then
7377 CFLAGS="$CFLAGS -gdwarf-2"
7381 case $CFLAGS in
7382 *-O*) ;;
7384 # No optimization flag was inferred for this non-GCC compiler.
7385 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7386 emacs_save_CFLAGS=$CFLAGS
7387 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7388 CFLAGS=${CFLAGS}-O
7389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7390 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7391 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7392 $as_echo_n "(cached) " >&6
7393 else
7394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7395 /* end confdefs.h. */
7398 main ()
7402 return 0;
7404 _ACEOF
7405 if ac_fn_c_try_link "$LINENO"; then :
7406 emacs_cv_prog_cc_o=yes
7407 else
7408 emacs_cv_prog_cc_o=no
7410 rm -f core conftest.err conftest.$ac_objext \
7411 conftest$ac_exeext conftest.$ac_ext
7413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7414 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7415 if test $emacs_cv_prog_cc_o != yes; then
7416 CFLAGS=$emacs_save_CFLAGS
7417 fi ;;
7418 esac
7421 # Check whether --enable-gcc-warnings was given.
7422 if test "${enable_gcc_warnings+set}" = set; then :
7423 enableval=$enable_gcc_warnings; case $enableval in
7424 yes|no) ;;
7425 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7426 esac
7427 gl_gcc_warnings=$enableval
7428 else
7429 gl_gcc_warnings=no
7434 # Check whether --enable-link-time-optimization was given.
7435 if test "${enable_link_time_optimization+set}" = set; then :
7436 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7438 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7439 ac_lto_supported=no
7440 if test x$GCC = xyes; then
7441 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7442 if test x$CPUS != x; then
7443 LTO="-flto=$CPUS"
7444 else
7445 LTO="-flto"
7447 old_CFLAGS=$CFLAGS
7448 CFLAGS="$CFLAGS $LTO"
7449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7450 /* end confdefs.h. */
7453 main ()
7457 return 0;
7459 _ACEOF
7460 if ac_fn_c_try_compile "$LINENO"; then :
7461 ac_lto_supported=yes
7462 else
7463 ac_lto_supported=no
7465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7466 CFLAGS="$old_CFLAGS"
7468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7469 $as_echo "$ac_lto_supported" >&6; }
7470 if test "$ac_lto_supported" = "yes"; then
7471 CFLAGS="$CFLAGS $LTO"
7477 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7478 # ------------------------------------------------
7479 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7480 # Otherwise, run RUN-IF-NOT-FOUND.
7483 # When compiling with GCC, prefer -isystem to -I when including system
7484 # include files, to avoid generating useless diagnostics for the files.
7485 if test "$gl_gcc_warnings" != yes; then
7486 isystem='-I'
7487 else
7488 isystem='-isystem '
7490 # This, $nw, is the list of warnings we disable.
7493 case $with_x_toolkit in
7494 lucid | athena | motif)
7495 # Old toolkits mishandle 'const'.
7496 nw="$nw -Wwrite-strings"
7499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7500 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7501 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7502 $as_echo_n "(cached) " >&6
7503 else
7505 gl_save_compiler_FLAGS="$CFLAGS"
7506 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7508 /* end confdefs.h. */
7511 main ()
7515 return 0;
7517 _ACEOF
7518 if ac_fn_c_try_compile "$LINENO"; then :
7519 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7520 else
7521 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7523 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7524 CFLAGS="$gl_save_compiler_FLAGS"
7527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7528 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7529 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7530 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7531 else
7532 gl_unknown_warnings_are_errors=
7536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7537 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7538 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7539 $as_echo_n "(cached) " >&6
7540 else
7542 gl_save_compiler_FLAGS="$CFLAGS"
7543 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7545 /* end confdefs.h. */
7548 main ()
7552 return 0;
7554 _ACEOF
7555 if ac_fn_c_try_compile "$LINENO"; then :
7556 gl_cv_warn_c__Werror=yes
7557 else
7558 gl_cv_warn_c__Werror=no
7560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7561 CFLAGS="$gl_save_compiler_FLAGS"
7564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7565 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7566 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7567 as_fn_append WERROR_CFLAGS " -Werror"
7572 esac
7575 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7576 nw="$nw -Woverlength-strings" # Not a problem these days
7577 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7578 nw="$nw -Wformat-nonliteral" # we do this a lot
7579 nw="$nw -Wvla" # warnings in gettext.h
7580 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7581 nw="$nw -Wswitch-default" # Too many warnings for now
7582 nw="$nw -Winline" # OK to ignore 'inline'
7583 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7584 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7585 # signed overflow has undefined behavior
7586 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7587 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7589 # Emacs doesn't care about shadowing; see
7590 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7591 nw="$nw -Wshadow"
7593 # Emacs's use of alloca inhibits protecting the stack.
7594 nw="$nw -Wstack-protector"
7596 # The following line should be removable at some point.
7597 nw="$nw -Wsuggest-attribute=pure"
7599 # clang is unduly picky about some things.
7600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7601 $as_echo_n "checking whether the compiler is clang... " >&6; }
7602 if test "${emacs_cv_clang+set}" = set; then :
7603 $as_echo_n "(cached) " >&6
7604 else
7605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7606 /* end confdefs.h. */
7608 #ifndef __clang__
7609 #error "not clang"
7610 #endif
7613 main ()
7617 return 0;
7619 _ACEOF
7620 if ac_fn_c_try_compile "$LINENO"; then :
7621 emacs_cv_clang=yes
7622 else
7623 emacs_cv_clang=no
7625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7628 $as_echo "$emacs_cv_clang" >&6; }
7629 if test $emacs_cv_clang = yes; then
7630 nw="$nw -Wcast-align"
7635 if test -n "$GCC"; then
7637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7638 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7639 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7640 $as_echo_n "(cached) " >&6
7641 else
7643 gl_save_CFLAGS="$CFLAGS"
7644 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7646 /* end confdefs.h. */
7649 main ()
7653 return 0;
7655 _ACEOF
7656 if ac_fn_c_try_compile "$LINENO"; then :
7657 gl_cv_cc_nomfi_supported=yes
7658 else
7659 gl_cv_cc_nomfi_supported=no
7661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7662 CFLAGS="$gl_save_CFLAGS"
7665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7666 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7668 if test "$gl_cv_cc_nomfi_supported" = yes; then
7669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7670 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7671 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7672 $as_echo_n "(cached) " >&6
7673 else
7675 gl_save_CFLAGS="$CFLAGS"
7676 CFLAGS="$CFLAGS -W -Werror"
7677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7678 /* end confdefs.h. */
7679 void f (void)
7681 typedef struct { int a; int b; } s_t;
7682 s_t s1 = { 0, };
7686 main ()
7690 return 0;
7692 _ACEOF
7693 if ac_fn_c_try_compile "$LINENO"; then :
7694 gl_cv_cc_nomfi_needed=no
7695 else
7696 gl_cv_cc_nomfi_needed=yes
7698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7699 CFLAGS="$gl_save_CFLAGS"
7703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7704 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7708 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7709 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7710 $as_echo_n "(cached) " >&6
7711 else
7713 gl_save_CFLAGS="$CFLAGS"
7714 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7716 /* end confdefs.h. */
7719 main ()
7723 return 0;
7725 _ACEOF
7726 if ac_fn_c_try_compile "$LINENO"; then :
7727 gl_cv_cc_uninitialized_supported=yes
7728 else
7729 gl_cv_cc_uninitialized_supported=no
7731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7732 CFLAGS="$gl_save_CFLAGS"
7735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7736 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7740 # List all gcc warning categories.
7741 gl_manywarn_set=
7742 for gl_manywarn_item in \
7743 -W \
7744 -Wabi \
7745 -Waddress \
7746 -Waggressive-loop-optimizations \
7747 -Wall \
7748 -Warray-bounds \
7749 -Wattributes \
7750 -Wbad-function-cast \
7751 -Wbuiltin-macro-redefined \
7752 -Wcast-align \
7753 -Wchar-subscripts \
7754 -Wclobbered \
7755 -Wcomment \
7756 -Wcomments \
7757 -Wcoverage-mismatch \
7758 -Wcpp \
7759 -Wdeprecated \
7760 -Wdeprecated-declarations \
7761 -Wdisabled-optimization \
7762 -Wdiv-by-zero \
7763 -Wdouble-promotion \
7764 -Wempty-body \
7765 -Wendif-labels \
7766 -Wenum-compare \
7767 -Wextra \
7768 -Wformat-contains-nul \
7769 -Wformat-extra-args \
7770 -Wformat-nonliteral \
7771 -Wformat-security \
7772 -Wformat-y2k \
7773 -Wformat-zero-length \
7774 -Wfree-nonheap-object \
7775 -Wignored-qualifiers \
7776 -Wimplicit \
7777 -Wimplicit-function-declaration \
7778 -Wimplicit-int \
7779 -Winit-self \
7780 -Winline \
7781 -Wint-to-pointer-cast \
7782 -Winvalid-memory-model \
7783 -Winvalid-pch \
7784 -Wjump-misses-init \
7785 -Wlogical-op \
7786 -Wmain \
7787 -Wmaybe-uninitialized \
7788 -Wmissing-braces \
7789 -Wmissing-declarations \
7790 -Wmissing-field-initializers \
7791 -Wmissing-include-dirs \
7792 -Wmissing-parameter-type \
7793 -Wmissing-prototypes \
7794 -Wmudflap \
7795 -Wmultichar \
7796 -Wnarrowing \
7797 -Wnested-externs \
7798 -Wnonnull \
7799 -Wnormalized=nfc \
7800 -Wold-style-declaration \
7801 -Wold-style-definition \
7802 -Woverflow \
7803 -Woverlength-strings \
7804 -Woverride-init \
7805 -Wpacked \
7806 -Wpacked-bitfield-compat \
7807 -Wparentheses \
7808 -Wpointer-arith \
7809 -Wpointer-sign \
7810 -Wpointer-to-int-cast \
7811 -Wpragmas \
7812 -Wreturn-local-addr \
7813 -Wreturn-type \
7814 -Wsequence-point \
7815 -Wshadow \
7816 -Wsizeof-pointer-memaccess \
7817 -Wstack-protector \
7818 -Wstrict-aliasing \
7819 -Wstrict-overflow \
7820 -Wstrict-prototypes \
7821 -Wsuggest-attribute=const \
7822 -Wsuggest-attribute=format \
7823 -Wsuggest-attribute=noreturn \
7824 -Wsuggest-attribute=pure \
7825 -Wswitch \
7826 -Wswitch-default \
7827 -Wsync-nand \
7828 -Wsystem-headers \
7829 -Wtrampolines \
7830 -Wtrigraphs \
7831 -Wtype-limits \
7832 -Wuninitialized \
7833 -Wunknown-pragmas \
7834 -Wunsafe-loop-optimizations \
7835 -Wunused \
7836 -Wunused-but-set-parameter \
7837 -Wunused-but-set-variable \
7838 -Wunused-function \
7839 -Wunused-label \
7840 -Wunused-local-typedefs \
7841 -Wunused-macros \
7842 -Wunused-parameter \
7843 -Wunused-result \
7844 -Wunused-value \
7845 -Wunused-variable \
7846 -Wvarargs \
7847 -Wvariadic-macros \
7848 -Wvector-operation-performance \
7849 -Wvla \
7850 -Wvolatile-register-var \
7851 -Wwrite-strings \
7853 ; do
7854 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7855 done
7857 # Disable specific options as needed.
7858 if test "$gl_cv_cc_nomfi_needed" = yes; then
7859 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7862 if test "$gl_cv_cc_uninitialized_supported" = no; then
7863 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
7866 ws=$gl_manywarn_set
7869 gl_warn_set=
7870 set x $ws; shift
7871 for gl_warn_item
7873 case " $nw " in
7874 *" $gl_warn_item "*)
7877 gl_warn_set="$gl_warn_set $gl_warn_item"
7879 esac
7880 done
7881 ws=$gl_warn_set
7883 for w in $ws; do
7885 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7887 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7888 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7889 $as_echo_n "(cached) " >&6
7890 else
7892 gl_save_compiler_FLAGS="$CFLAGS"
7893 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $w"
7894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7895 /* end confdefs.h. */
7898 main ()
7902 return 0;
7904 _ACEOF
7905 if ac_fn_c_try_compile "$LINENO"; then :
7906 eval "$as_gl_Warn=yes"
7907 else
7908 eval "$as_gl_Warn=no"
7910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7911 CFLAGS="$gl_save_compiler_FLAGS"
7914 eval ac_res=\$$as_gl_Warn
7915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7916 $as_echo "$ac_res" >&6; }
7917 eval as_val=\$$as_gl_Warn
7918 if test "x$as_val" = x""yes; then :
7919 as_fn_append WARN_CFLAGS " $w"
7923 done
7925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7926 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7927 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7928 $as_echo_n "(cached) " >&6
7929 else
7931 gl_save_compiler_FLAGS="$CFLAGS"
7932 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-missing-field-initializers"
7933 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7934 /* end confdefs.h. */
7937 main ()
7941 return 0;
7943 _ACEOF
7944 if ac_fn_c_try_compile "$LINENO"; then :
7945 gl_cv_warn_c__Wno_missing_field_initializers=yes
7946 else
7947 gl_cv_warn_c__Wno_missing_field_initializers=no
7949 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7950 CFLAGS="$gl_save_compiler_FLAGS"
7953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7954 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7955 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7956 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7959 # We need this one
7961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7962 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7963 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7964 $as_echo_n "(cached) " >&6
7965 else
7967 gl_save_compiler_FLAGS="$CFLAGS"
7968 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-sign-compare"
7969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7970 /* end confdefs.h. */
7973 main ()
7977 return 0;
7979 _ACEOF
7980 if ac_fn_c_try_compile "$LINENO"; then :
7981 gl_cv_warn_c__Wno_sign_compare=yes
7982 else
7983 gl_cv_warn_c__Wno_sign_compare=no
7985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7986 CFLAGS="$gl_save_compiler_FLAGS"
7989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7990 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7991 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7992 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7995 # Too many warnings for now
7997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7998 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7999 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8000 $as_echo_n "(cached) " >&6
8001 else
8003 gl_save_compiler_FLAGS="$CFLAGS"
8004 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-type-limits"
8005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8006 /* end confdefs.h. */
8009 main ()
8013 return 0;
8015 _ACEOF
8016 if ac_fn_c_try_compile "$LINENO"; then :
8017 gl_cv_warn_c__Wno_type_limits=yes
8018 else
8019 gl_cv_warn_c__Wno_type_limits=no
8021 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8022 CFLAGS="$gl_save_compiler_FLAGS"
8025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8026 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8027 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8028 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8031 # Too many warnings for now
8033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8034 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8035 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8036 $as_echo_n "(cached) " >&6
8037 else
8039 gl_save_compiler_FLAGS="$CFLAGS"
8040 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-switch"
8041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8042 /* end confdefs.h. */
8045 main ()
8049 return 0;
8051 _ACEOF
8052 if ac_fn_c_try_compile "$LINENO"; then :
8053 gl_cv_warn_c__Wno_switch=yes
8054 else
8055 gl_cv_warn_c__Wno_switch=no
8057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8058 CFLAGS="$gl_save_compiler_FLAGS"
8061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8062 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8063 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8064 as_fn_append WARN_CFLAGS " -Wno-switch"
8067 # Too many warnings for now
8069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8070 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8071 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8072 $as_echo_n "(cached) " >&6
8073 else
8075 gl_save_compiler_FLAGS="$CFLAGS"
8076 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-parameter"
8077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8078 /* end confdefs.h. */
8081 main ()
8085 return 0;
8087 _ACEOF
8088 if ac_fn_c_try_compile "$LINENO"; then :
8089 gl_cv_warn_c__Wno_unused_parameter=yes
8090 else
8091 gl_cv_warn_c__Wno_unused_parameter=no
8093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8094 CFLAGS="$gl_save_compiler_FLAGS"
8097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8098 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8099 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8100 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8103 # Too many warnings for now
8105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8106 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8107 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8108 $as_echo_n "(cached) " >&6
8109 else
8111 gl_save_compiler_FLAGS="$CFLAGS"
8112 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-format-nonliteral"
8113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8114 /* end confdefs.h. */
8117 main ()
8121 return 0;
8123 _ACEOF
8124 if ac_fn_c_try_compile "$LINENO"; then :
8125 gl_cv_warn_c__Wno_format_nonliteral=yes
8126 else
8127 gl_cv_warn_c__Wno_format_nonliteral=no
8129 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8130 CFLAGS="$gl_save_compiler_FLAGS"
8133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8134 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8135 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8136 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8141 # In spite of excluding -Wlogical-op above, it is enabled, as of
8142 # gcc 4.5.0 20090517.
8144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8145 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8146 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8147 $as_echo_n "(cached) " >&6
8148 else
8150 gl_save_compiler_FLAGS="$CFLAGS"
8151 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-logical-op"
8152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8153 /* end confdefs.h. */
8156 main ()
8160 return 0;
8162 _ACEOF
8163 if ac_fn_c_try_compile "$LINENO"; then :
8164 gl_cv_warn_c__Wno_logical_op=yes
8165 else
8166 gl_cv_warn_c__Wno_logical_op=no
8168 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8169 CFLAGS="$gl_save_compiler_FLAGS"
8172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8173 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8174 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8175 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8180 # More things that clang is unduly picky about.
8181 if test $emacs_cv_clang = yes; then
8183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8184 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8185 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8186 $as_echo_n "(cached) " >&6
8187 else
8189 gl_save_compiler_FLAGS="$CFLAGS"
8190 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-format-extra-args"
8191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8192 /* end confdefs.h. */
8195 main ()
8199 return 0;
8201 _ACEOF
8202 if ac_fn_c_try_compile "$LINENO"; then :
8203 gl_cv_warn_c__Wno_format_extra_args=yes
8204 else
8205 gl_cv_warn_c__Wno_format_extra_args=no
8207 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8208 CFLAGS="$gl_save_compiler_FLAGS"
8211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8212 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8213 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8214 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8220 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8221 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8222 $as_echo_n "(cached) " >&6
8223 else
8225 gl_save_compiler_FLAGS="$CFLAGS"
8226 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-tautological-constant-out-of-range-compare"
8227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8228 /* end confdefs.h. */
8231 main ()
8235 return 0;
8237 _ACEOF
8238 if ac_fn_c_try_compile "$LINENO"; then :
8239 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8240 else
8241 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8243 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8244 CFLAGS="$gl_save_compiler_FLAGS"
8247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8248 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8249 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8250 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8256 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8257 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8258 $as_echo_n "(cached) " >&6
8259 else
8261 gl_save_compiler_FLAGS="$CFLAGS"
8262 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-command-line-argument"
8263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8264 /* end confdefs.h. */
8267 main ()
8271 return 0;
8273 _ACEOF
8274 if ac_fn_c_try_compile "$LINENO"; then :
8275 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8276 else
8277 gl_cv_warn_c__Wno_unused_command_line_argument=no
8279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8280 CFLAGS="$gl_save_compiler_FLAGS"
8283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8284 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8285 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8286 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8292 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8293 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8294 $as_echo_n "(cached) " >&6
8295 else
8297 gl_save_compiler_FLAGS="$CFLAGS"
8298 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wno-unused-value"
8299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8300 /* end confdefs.h. */
8303 main ()
8307 return 0;
8309 _ACEOF
8310 if ac_fn_c_try_compile "$LINENO"; then :
8311 gl_cv_warn_c__Wno_unused_value=yes
8312 else
8313 gl_cv_warn_c__Wno_unused_value=no
8315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8316 CFLAGS="$gl_save_compiler_FLAGS"
8319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8320 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8321 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8322 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
8330 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
8331 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
8332 $as_echo_n "(cached) " >&6
8333 else
8335 gl_save_compiler_FLAGS="$CFLAGS"
8336 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fdiagnostics-show-option"
8337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8338 /* end confdefs.h. */
8341 main ()
8345 return 0;
8347 _ACEOF
8348 if ac_fn_c_try_compile "$LINENO"; then :
8349 gl_cv_warn_c__fdiagnostics_show_option=yes
8350 else
8351 gl_cv_warn_c__fdiagnostics_show_option=no
8353 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8354 CFLAGS="$gl_save_compiler_FLAGS"
8357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
8358 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
8359 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
8360 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
8365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
8366 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
8367 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
8368 $as_echo_n "(cached) " >&6
8369 else
8371 gl_save_compiler_FLAGS="$CFLAGS"
8372 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -funit-at-a-time"
8373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8374 /* end confdefs.h. */
8377 main ()
8381 return 0;
8383 _ACEOF
8384 if ac_fn_c_try_compile "$LINENO"; then :
8385 gl_cv_warn_c__funit_at_a_time=yes
8386 else
8387 gl_cv_warn_c__funit_at_a_time=no
8389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8390 CFLAGS="$gl_save_compiler_FLAGS"
8393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
8394 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
8395 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
8396 as_fn_append WARN_CFLAGS " -funit-at-a-time"
8402 $as_echo "#define lint 1" >>confdefs.h
8406 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8409 # We use a slightly smaller set of warning options for lib/.
8410 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8412 nw="$nw -Wunused-macros"
8415 gl_warn_set=
8416 set x $WARN_CFLAGS; shift
8417 for gl_warn_item
8419 case " $nw " in
8420 *" $gl_warn_item "*)
8423 gl_warn_set="$gl_warn_set $gl_warn_item"
8425 esac
8426 done
8427 GNULIB_WARN_CFLAGS=$gl_warn_set
8437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8438 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8439 rm -f conf$$ conf$$.file
8441 LN_S_FILEONLY='cp -p'
8443 if (echo >conf$$.file) 2>/dev/null; then
8444 if ln -s conf$$.file conf$$ 2>/dev/null; then
8445 LN_S_FILEONLY='ln -s'
8446 elif ln conf$$.file conf$$ 2>/dev/null; then
8447 LN_S_FILEONLY=ln
8451 rm -f conf$$ conf$$.file
8453 if test "$LN_S_FILEONLY" = "ln -s"; then
8454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8455 $as_echo "yes" >&6; }
8456 else
8457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8458 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8464 if test "$opsys" = "mingw32"; then
8465 LN_S="ln"
8468 # Extract the first word of "install-info", so it can be a program name with args.
8469 set dummy install-info; ac_word=$2
8470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8471 $as_echo_n "checking for $ac_word... " >&6; }
8472 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8473 $as_echo_n "(cached) " >&6
8474 else
8475 case $INSTALL_INFO in
8476 [\\/]* | ?:[\\/]*)
8477 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8481 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8483 IFS=$as_save_IFS
8484 test -z "$as_dir" && as_dir=.
8485 for ac_exec_ext in '' $ac_executable_extensions; do
8486 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8487 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8489 break 2
8491 done
8492 done
8493 IFS=$as_save_IFS
8495 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8497 esac
8499 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8500 if test -n "$INSTALL_INFO"; then
8501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8502 $as_echo "$INSTALL_INFO" >&6; }
8503 else
8504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8505 $as_echo "no" >&6; }
8509 # Extract the first word of "gzip", so it can be a program name with args.
8510 set dummy gzip; ac_word=$2
8511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8512 $as_echo_n "checking for $ac_word... " >&6; }
8513 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8514 $as_echo_n "(cached) " >&6
8515 else
8516 case $GZIP_PROG in
8517 [\\/]* | ?:[\\/]*)
8518 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8522 for as_dir in $PATH
8524 IFS=$as_save_IFS
8525 test -z "$as_dir" && as_dir=.
8526 for ac_exec_ext in '' $ac_executable_extensions; do
8527 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8528 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8530 break 2
8532 done
8533 done
8534 IFS=$as_save_IFS
8537 esac
8539 GZIP_PROG=$ac_cv_path_GZIP_PROG
8540 if test -n "$GZIP_PROG"; then
8541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8542 $as_echo "$GZIP_PROG" >&6; }
8543 else
8544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8545 $as_echo "no" >&6; }
8550 if test $opsys = gnu-linux; then
8551 # Extract the first word of "paxctl", so it can be a program name with args.
8552 set dummy paxctl; ac_word=$2
8553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8554 $as_echo_n "checking for $ac_word... " >&6; }
8555 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8556 $as_echo_n "(cached) " >&6
8557 else
8558 case $PAXCTL in
8559 [\\/]* | ?:[\\/]*)
8560 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8564 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8566 IFS=$as_save_IFS
8567 test -z "$as_dir" && as_dir=.
8568 for ac_exec_ext in '' $ac_executable_extensions; do
8569 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8570 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8572 break 2
8574 done
8575 done
8576 IFS=$as_save_IFS
8579 esac
8581 PAXCTL=$ac_cv_path_PAXCTL
8582 if test -n "$PAXCTL"; then
8583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8584 $as_echo "$PAXCTL" >&6; }
8585 else
8586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8587 $as_echo "no" >&6; }
8591 if test "X$PAXCTL" != X; then
8592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8593 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8595 /* end confdefs.h. */
8598 main ()
8602 return 0;
8604 _ACEOF
8605 if ac_fn_c_try_link "$LINENO"; then :
8606 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8607 $as_echo "yes" >&6; }
8608 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8609 $as_echo "no" >&6; }; PAXCTL=""; fi
8611 rm -f core conftest.err conftest.$ac_objext \
8612 conftest$ac_exeext conftest.$ac_ext
8616 ## Need makeinfo >= 4.7 (?) to build the manuals.
8617 # Extract the first word of "makeinfo", so it can be a program name with args.
8618 set dummy makeinfo; ac_word=$2
8619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8620 $as_echo_n "checking for $ac_word... " >&6; }
8621 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8622 $as_echo_n "(cached) " >&6
8623 else
8624 case $MAKEINFO in
8625 [\\/]* | ?:[\\/]*)
8626 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8630 for as_dir in $PATH
8632 IFS=$as_save_IFS
8633 test -z "$as_dir" && as_dir=.
8634 for ac_exec_ext in '' $ac_executable_extensions; do
8635 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8636 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8638 break 2
8640 done
8641 done
8642 IFS=$as_save_IFS
8644 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8646 esac
8648 MAKEINFO=$ac_cv_path_MAKEINFO
8649 if test -n "$MAKEINFO"; then
8650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8651 $as_echo "$MAKEINFO" >&6; }
8652 else
8653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8654 $as_echo "no" >&6; }
8658 if test "$MAKEINFO" != "no"; then
8659 case `
8660 $MAKEINFO --version 2> /dev/null |
8661 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8662 ` in
8663 '') MAKEINFO=no;;
8664 esac
8667 ## Makeinfo is unusual. For a released Emacs, the manuals are
8668 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8669 ## therefore in the category of "special tools" not normally required, which
8670 ## configure does not have to check for (eg autoconf itself).
8671 ## In a Bazaar checkout on the other hand, the manuals are not included.
8672 ## So makeinfo is a requirement to build from Bazaar, and configure
8673 ## should test for it as it does for any other build requirement.
8674 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8675 ## with pre-built manuals, from a Bazaar checkout.
8676 HAVE_MAKEINFO=yes
8678 if test "$MAKEINFO" = "no"; then
8679 MAKEINFO=makeinfo
8680 if test "x${with_makeinfo}" = "xno"; then
8681 HAVE_MAKEINFO=no
8682 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8683 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8684 source tree does not seem to have pre-built manuals in the \`info' directory.
8685 Either install a suitable version of makeinfo, or re-run configure
8686 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8691 INFO_EXT=.info
8692 INFO_OPTS=--no-split
8697 if test x$GCC = xyes; then
8698 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8699 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8700 else
8701 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8702 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8706 late_LDFLAGS=$LDFLAGS
8707 if test x$GCC = xyes; then
8708 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8709 else
8710 LDFLAGS="$LDFLAGS -znocombreloc"
8713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8714 $as_echo_n "checking for -znocombreloc... " >&6; }
8715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8716 /* end confdefs.h. */
8719 main ()
8723 return 0;
8725 _ACEOF
8726 if ac_fn_c_try_link "$LINENO"; then :
8727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8728 $as_echo "yes" >&6; }
8729 else
8730 LDFLAGS=$late_LDFLAGS
8731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8732 $as_echo "no" >&6; }
8734 rm -f core conftest.err conftest.$ac_objext \
8735 conftest$ac_exeext conftest.$ac_ext
8738 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8739 case "$opsys" in
8740 your-opsys-here) CANNOT_DUMP=yes ;;
8741 esac
8743 test "$CANNOT_DUMP" = "yes" && \
8745 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8751 UNEXEC_OBJ=unexelf.o
8752 case "$opsys" in
8753 # MSDOS uses unexcoff.o
8754 aix4-2)
8755 UNEXEC_OBJ=unexaix.o
8757 cygwin)
8758 UNEXEC_OBJ=unexcw.o
8760 darwin)
8761 UNEXEC_OBJ=unexmacosx.o
8763 hpux10-20 | hpux11)
8764 UNEXEC_OBJ=unexhp9k800.o
8766 mingw32)
8767 UNEXEC_OBJ=unexw32.o
8769 sol2-10)
8770 # Use the Solaris dldump() function, called from unexsol.c, to dump
8771 # emacs, instead of the generic ELF dump code found in unexelf.c.
8772 # The resulting binary has a complete symbol table, and is better
8773 # for debugging and other observability tools (debuggers, pstack, etc).
8775 # If you encounter a problem using dldump(), please consider sending
8776 # a message to the OpenSolaris tools-linking mailing list:
8777 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8779 # It is likely that dldump() works with older Solaris too, but this has
8780 # not been tested, so for now this change is for Solaris 10 or newer.
8781 UNEXEC_OBJ=unexsol.o
8783 esac
8785 LD_SWITCH_SYSTEM=
8786 case "$opsys" in
8787 freebsd|dragonfly)
8788 ## Let `ld' find image libs and similar things in /usr/local/lib.
8789 ## The system compiler, GCC, has apparently been modified to not
8790 ## look there, contrary to what a stock GCC would do.
8791 ### It's not our place to do this. See bug#10313#17.
8792 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8796 gnu-linux)
8797 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8798 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8801 netbsd)
8802 ### It's not our place to do this. See bug#10313#17.
8803 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8807 openbsd)
8808 ## Han Boetes <han@boetes.org> says this is necessary,
8809 ## otherwise Emacs dumps core on elf systems.
8810 LD_SWITCH_SYSTEM="-Z"
8812 esac
8815 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8817 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8818 ## which has not been defined yet. When this was handled with cpp,
8819 ## it was expanded to null when configure sourced the s/*.h file.
8820 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8821 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8822 ## (or somesuch), but because it is supposed to go at the _front_
8823 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8824 ## Compare with the gnu-linux case below, which added to the end
8825 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8826 ## LD_SWITCH_SYSTEM_TEMACS.
8827 case "$opsys" in
8828 netbsd|openbsd)
8829 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8830 esac
8833 C_SWITCH_MACHINE=
8834 case $canonical in
8835 alpha*)
8836 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8837 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8841 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8842 ## With ELF, make sure that all common symbols get allocated to in the
8843 ## data section. Otherwise, the dump of temacs may miss variables in
8844 ## the shared library that have been initialized. For example, with
8845 ## GNU libc, __malloc_initialized would normally be resolved to the
8846 ## shared library's .bss section, which is fatal.
8847 if test "x$GCC" = "xyes"; then
8848 C_SWITCH_MACHINE="-fno-common"
8849 else
8850 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8852 else
8853 UNEXEC_OBJ=unexalpha.o
8856 esac
8861 C_SWITCH_SYSTEM=
8862 ## Some programs in src produce warnings saying certain subprograms
8863 ## are too complex and need a MAXMEM value greater than 2000 for
8864 ## additional optimization. --nils@exp-math.uni-essen.de
8865 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8866 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8867 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
8868 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8869 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8873 LIBS_SYSTEM=
8874 case "$opsys" in
8875 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8876 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8878 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
8880 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8882 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8884 ## Motif needs -lgen.
8885 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8886 esac
8890 ### Make sure subsequent tests use flags consistent with the build flags.
8892 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8893 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8894 else
8895 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8898 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8900 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8904 LIB_MATH=-lm
8905 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8907 case $opsys in
8908 cygwin )
8909 LIB_MATH=
8911 darwin )
8912 ## Adding -lm confuses the dynamic linker, so omit it.
8913 LIB_MATH=
8915 freebsd | dragonfly )
8916 SYSTEM_TYPE=berkeley-unix
8918 gnu-linux | gnu-kfreebsd )
8920 hpux10-20 | hpux11 )
8922 mingw32 )
8923 LIB_MATH=
8924 SYSTEM_TYPE=windows-nt
8926 netbsd | openbsd )
8927 SYSTEM_TYPE=berkeley-unix
8930 sol2* | unixware )
8931 SYSTEM_TYPE=usg-unix-v
8934 esac
8938 cat >>confdefs.h <<_ACEOF
8939 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8940 _ACEOF
8944 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8945 pre_PKG_CONFIG_LIBS=$LIBS
8947 # Extract the first word of "pkg-config", so it can be a program name with args.
8948 set dummy pkg-config; ac_word=$2
8949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8950 $as_echo_n "checking for $ac_word... " >&6; }
8951 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8952 $as_echo_n "(cached) " >&6
8953 else
8954 case $PKG_CONFIG in
8955 [\\/]* | ?:[\\/]*)
8956 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8959 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8960 for as_dir in $PATH
8962 IFS=$as_save_IFS
8963 test -z "$as_dir" && as_dir=.
8964 for ac_exec_ext in '' $ac_executable_extensions; do
8965 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8966 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8967 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8968 break 2
8970 done
8971 done
8972 IFS=$as_save_IFS
8974 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8976 esac
8978 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8979 if test -n "$PKG_CONFIG"; then
8980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8981 $as_echo "$PKG_CONFIG" >&6; }
8982 else
8983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8984 $as_echo "no" >&6; }
8991 if test "${with_sound}" != "no"; then
8992 # Sound support for GNU/Linux, the free BSDs, and MinGW.
8993 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h mmsystem.h
8994 do :
8995 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8996 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
8997 #ifdef __MINGW32__
8998 #define WIN32_LEAN_AND_MEAN
8999 #include <windows.h>
9000 #endif
9003 eval as_val=\$$as_ac_Header
9004 if test "x$as_val" = x""yes; then :
9005 cat >>confdefs.h <<_ACEOF
9006 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9007 _ACEOF
9008 have_sound_header=yes
9011 done
9013 # Emulation library used on NetBSD.
9014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9015 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9016 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9017 $as_echo_n "(cached) " >&6
9018 else
9019 ac_check_lib_save_LIBS=$LIBS
9020 LIBS="-lossaudio $LIBS"
9021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9022 /* end confdefs.h. */
9024 /* Override any GCC internal prototype to avoid an error.
9025 Use char because int might match the return type of a GCC
9026 builtin and then its argument prototype would still apply. */
9027 #ifdef __cplusplus
9028 extern "C"
9029 #endif
9030 char _oss_ioctl ();
9032 main ()
9034 return _oss_ioctl ();
9036 return 0;
9038 _ACEOF
9039 if ac_fn_c_try_link "$LINENO"; then :
9040 ac_cv_lib_ossaudio__oss_ioctl=yes
9041 else
9042 ac_cv_lib_ossaudio__oss_ioctl=no
9044 rm -f core conftest.err conftest.$ac_objext \
9045 conftest$ac_exeext conftest.$ac_ext
9046 LIBS=$ac_check_lib_save_LIBS
9048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9049 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9050 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9051 LIBSOUND=-lossaudio
9052 else
9053 LIBSOUND=
9058 ALSA_REQUIRED=1.0.0
9059 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9061 succeeded=no
9063 if test "$PKG_CONFIG" = "no" ; then
9064 HAVE_ALSA=no
9065 else
9066 PKG_CONFIG_MIN_VERSION=0.9.0
9067 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9069 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9071 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9072 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9073 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9074 edit_cflags="
9075 s,///*,/,g
9076 s/^/ /
9077 s/ -I/ $isystem/g
9078 s/^ //
9080 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9081 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9083 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9084 succeeded=yes
9085 else
9086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9087 $as_echo "no" >&6; }
9088 ALSA_CFLAGS=""
9089 ALSA_LIBS=""
9090 ## If we have a custom action on failure, don't print errors, but
9091 ## do set a variable so people can do so. Do it in a subshell
9092 ## to capture any diagnostics in invoking pkg-config.
9093 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9099 else
9100 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9101 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9105 if test $succeeded = yes; then
9106 HAVE_ALSA=yes
9107 else
9108 HAVE_ALSA=no
9111 if test $HAVE_ALSA = yes; then
9112 SAVE_CFLAGS="$CFLAGS"
9113 SAVE_LIBS="$LIBS"
9114 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9115 LIBS="$ALSA_LIBS $LIBS"
9116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9117 /* end confdefs.h. */
9118 #include <asoundlib.h>
9120 main ()
9122 snd_lib_error_set_handler (0);
9124 return 0;
9126 _ACEOF
9127 if ac_fn_c_try_compile "$LINENO"; then :
9128 emacs_alsa_normal=yes
9129 else
9130 emacs_alsa_normal=no
9132 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9133 if test "$emacs_alsa_normal" != yes; then
9134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9135 /* end confdefs.h. */
9136 #include <alsa/asoundlib.h>
9138 main ()
9140 snd_lib_error_set_handler (0);
9142 return 0;
9144 _ACEOF
9145 if ac_fn_c_try_compile "$LINENO"; then :
9146 emacs_alsa_subdir=yes
9147 else
9148 emacs_alsa_subdir=no
9150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9151 if test "$emacs_alsa_subdir" != yes; then
9152 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9154 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9157 CFLAGS="$SAVE_CFLAGS"
9158 LIBS="$SAVE_LIBS"
9159 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9160 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9162 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9166 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9167 case "$opsys" in
9168 gnu-linux|freebsd|netbsd|mingw32)
9170 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9173 esac
9182 for ac_header in $ac_header_list
9183 do :
9184 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9185 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9187 eval as_val=\$$as_ac_Header
9188 if test "x$as_val" = x""yes; then :
9189 cat >>confdefs.h <<_ACEOF
9190 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9191 _ACEOF
9195 done
9217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9218 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9220 /* end confdefs.h. */
9221 #include <sys/personality.h>
9223 main ()
9225 personality (PER_LINUX32)
9227 return 0;
9229 _ACEOF
9230 if ac_fn_c_try_compile "$LINENO"; then :
9231 emacs_cv_personality_linux32=yes
9232 else
9233 emacs_cv_personality_linux32=no
9235 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9237 $as_echo "$emacs_cv_personality_linux32" >&6; }
9239 if test $emacs_cv_personality_linux32 = yes; then
9241 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9245 for ac_header in term.h
9246 do :
9247 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9248 if test "x$ac_cv_header_term_h" = x""yes; then :
9249 cat >>confdefs.h <<_ACEOF
9250 #define HAVE_TERM_H 1
9251 _ACEOF
9255 done
9257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9258 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9259 if test "${ac_cv_header_time+set}" = set; then :
9260 $as_echo_n "(cached) " >&6
9261 else
9262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9263 /* end confdefs.h. */
9264 #include <sys/types.h>
9265 #include <sys/time.h>
9266 #include <time.h>
9269 main ()
9271 if ((struct tm *) 0)
9272 return 0;
9274 return 0;
9276 _ACEOF
9277 if ac_fn_c_try_compile "$LINENO"; then :
9278 ac_cv_header_time=yes
9279 else
9280 ac_cv_header_time=no
9282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9285 $as_echo "$ac_cv_header_time" >&6; }
9286 if test $ac_cv_header_time = yes; then
9288 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9292 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9295 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9296 ac_have_decl=1
9297 else
9298 ac_have_decl=0
9301 cat >>confdefs.h <<_ACEOF
9302 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9303 _ACEOF
9305 if test $ac_cv_have_decl_sys_siglist != yes; then
9306 # For Tru64, at least:
9307 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9310 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9311 ac_have_decl=1
9312 else
9313 ac_have_decl=0
9316 cat >>confdefs.h <<_ACEOF
9317 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9318 _ACEOF
9320 if test $ac_cv_have_decl___sys_siglist = yes; then
9322 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
9326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9327 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9328 if test "${ac_cv_header_sys_wait_h+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/wait.h>
9335 #ifndef WEXITSTATUS
9336 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9337 #endif
9338 #ifndef WIFEXITED
9339 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9340 #endif
9343 main ()
9345 int s;
9346 wait (&s);
9347 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9349 return 0;
9351 _ACEOF
9352 if ac_fn_c_try_compile "$LINENO"; then :
9353 ac_cv_header_sys_wait_h=yes
9354 else
9355 ac_cv_header_sys_wait_h=no
9357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9360 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9361 if test $ac_cv_header_sys_wait_h = yes; then
9363 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
9369 $as_echo_n "checking for speed_t... " >&6; }
9370 if test "${emacs_cv_speed_t+set}" = set; then :
9371 $as_echo_n "(cached) " >&6
9372 else
9373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9374 /* end confdefs.h. */
9375 #include <termios.h>
9377 main ()
9379 speed_t x = 1;
9381 return 0;
9383 _ACEOF
9384 if ac_fn_c_try_compile "$LINENO"; then :
9385 emacs_cv_speed_t=yes
9386 else
9387 emacs_cv_speed_t=no
9389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
9392 $as_echo "$emacs_cv_speed_t" >&6; }
9393 if test $emacs_cv_speed_t = yes; then
9395 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
9402 for ac_header in net/if.h
9403 do :
9404 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9405 #if HAVE_SYS_SOCKET_H
9406 #include <sys/socket.h>
9407 #endif
9409 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9410 cat >>confdefs.h <<_ACEOF
9411 #define HAVE_NET_IF_H 1
9412 _ACEOF
9416 done
9418 for ac_header in ifaddrs.h
9419 do :
9420 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9421 #if HAVE_SYS_SOCKET_H
9422 #include <sys/socket.h>
9423 #endif
9425 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9426 cat >>confdefs.h <<_ACEOF
9427 #define HAVE_IFADDRS_H 1
9428 _ACEOF
9432 done
9434 for ac_header in net/if_dl.h
9435 do :
9436 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9437 #if HAVE_SYS_SOCKET_H
9438 #include <sys/socket.h>
9439 #endif
9441 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9442 cat >>confdefs.h <<_ACEOF
9443 #define HAVE_NET_IF_DL_H 1
9444 _ACEOF
9448 done
9451 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9452 #if HAVE_SYS_SOCKET_H
9453 #include <sys/socket.h>
9454 #endif
9455 #if HAVE_NET_IF_H
9456 #include <net/if.h>
9457 #endif
9459 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9461 cat >>confdefs.h <<_ACEOF
9462 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9463 _ACEOF
9467 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9468 #if HAVE_SYS_SOCKET_H
9469 #include <sys/socket.h>
9470 #endif
9471 #if HAVE_NET_IF_H
9472 #include <net/if.h>
9473 #endif
9475 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9477 cat >>confdefs.h <<_ACEOF
9478 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9479 _ACEOF
9483 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9484 #if HAVE_SYS_SOCKET_H
9485 #include <sys/socket.h>
9486 #endif
9487 #if HAVE_NET_IF_H
9488 #include <net/if.h>
9489 #endif
9491 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9493 cat >>confdefs.h <<_ACEOF
9494 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9495 _ACEOF
9499 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9500 #if HAVE_SYS_SOCKET_H
9501 #include <sys/socket.h>
9502 #endif
9503 #if HAVE_NET_IF_H
9504 #include <net/if.h>
9505 #endif
9507 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9509 cat >>confdefs.h <<_ACEOF
9510 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9511 _ACEOF
9515 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9516 #if HAVE_SYS_SOCKET_H
9517 #include <sys/socket.h>
9518 #endif
9519 #if HAVE_NET_IF_H
9520 #include <net/if.h>
9521 #endif
9523 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9525 cat >>confdefs.h <<_ACEOF
9526 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9527 _ACEOF
9531 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9532 #if HAVE_SYS_SOCKET_H
9533 #include <sys/socket.h>
9534 #endif
9535 #if HAVE_NET_IF_H
9536 #include <net/if.h>
9537 #endif
9539 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9541 cat >>confdefs.h <<_ACEOF
9542 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9543 _ACEOF
9551 DEPFLAGS=
9552 MKDEPDIR=":"
9553 deps_frag=deps.mk
9554 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9556 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9557 HAVE_GNU_MAKE=no
9558 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9559 if test "x$testval" != x; then
9560 HAVE_GNU_MAKE=yes
9561 else
9562 ac_enable_autodepend=no
9564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9565 $as_echo "$HAVE_GNU_MAKE" >&6; }
9566 if test $HAVE_GNU_MAKE = yes; then
9567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9568 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9569 SAVE_CFLAGS="$CFLAGS"
9570 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9572 /* end confdefs.h. */
9575 main ()
9579 return 0;
9581 _ACEOF
9582 if ac_fn_c_try_compile "$LINENO"; then :
9584 else
9585 ac_enable_autodepend=no
9587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9588 CFLAGS="$SAVE_CFLAGS"
9589 test -f deps.d || ac_enable_autodepend=no
9590 rm -rf deps.d
9591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9592 $as_echo "$ac_enable_autodepend" >&6; }
9594 if test $ac_enable_autodepend = yes; then
9595 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9596 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9597 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9598 deps_frag=autodeps.mk
9601 deps_frag=$srcdir/src/$deps_frag
9607 lisp_frag=$srcdir/src/lisp.mk
9611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9612 $as_echo_n "checking for long file names... " >&6; }
9613 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9614 $as_echo_n "(cached) " >&6
9615 else
9616 ac_cv_sys_long_file_names=yes
9617 # Test for long file names in all the places we know might matter:
9618 # . the current directory, where building will happen
9619 # $prefix/lib where we will be installing things
9620 # $exec_prefix/lib likewise
9621 # $TMPDIR if set, where it might want to write temporary files
9622 # /tmp where it might want to write temporary files
9623 # /var/tmp likewise
9624 # /usr/tmp likewise
9625 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9626 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9627 # in the usual case where exec_prefix is '${prefix}'.
9628 case $ac_dir in #(
9629 . | /* | ?:[\\/]*) ;; #(
9630 *) continue;;
9631 esac
9632 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9633 ac_xdir=$ac_dir/cf$$
9634 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9635 ac_tf1=$ac_xdir/conftest9012345
9636 ac_tf2=$ac_xdir/conftest9012346
9637 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9638 ac_cv_sys_long_file_names=no
9639 rm -f -r "$ac_xdir" 2>/dev/null
9640 test $ac_cv_sys_long_file_names = no && break
9641 done
9643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9644 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9645 if test $ac_cv_sys_long_file_names = yes; then
9647 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9652 #### Choose a window system.
9654 ## We leave window_system equal to none if
9655 ## we end up building without one. Any new window system should
9656 ## set window_system to an appropriate value and add objects to
9657 ## window-system-specific substs.
9659 window_system=none
9660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9661 $as_echo_n "checking for X... " >&6; }
9664 # Check whether --with-x was given.
9665 if test "${with_x+set}" = set; then :
9666 withval=$with_x;
9669 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9670 if test "x$with_x" = xno; then
9671 # The user explicitly disabled X.
9672 have_x=disabled
9673 else
9674 case $x_includes,$x_libraries in #(
9675 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9676 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9677 $as_echo_n "(cached) " >&6
9678 else
9679 # One or both of the vars are not set, and there is no cached value.
9680 ac_x_includes=no ac_x_libraries=no
9681 rm -f -r conftest.dir
9682 if mkdir conftest.dir; then
9683 cd conftest.dir
9684 cat >Imakefile <<'_ACEOF'
9685 incroot:
9686 @echo incroot='${INCROOT}'
9687 usrlibdir:
9688 @echo usrlibdir='${USRLIBDIR}'
9689 libdir:
9690 @echo libdir='${LIBDIR}'
9691 _ACEOF
9692 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9693 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9694 for ac_var in incroot usrlibdir libdir; do
9695 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9696 done
9697 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9698 for ac_extension in a so sl dylib la dll; do
9699 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9700 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9701 ac_im_usrlibdir=$ac_im_libdir; break
9703 done
9704 # Screen out bogus values from the imake configuration. They are
9705 # bogus both because they are the default anyway, and because
9706 # using them would break gcc on systems where it needs fixed includes.
9707 case $ac_im_incroot in
9708 /usr/include) ac_x_includes= ;;
9709 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9710 esac
9711 case $ac_im_usrlibdir in
9712 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9713 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9714 esac
9716 cd ..
9717 rm -f -r conftest.dir
9720 # Standard set of common directories for X headers.
9721 # Check X11 before X11Rn because it is often a symlink to the current release.
9722 ac_x_header_dirs='
9723 /usr/X11/include
9724 /usr/X11R7/include
9725 /usr/X11R6/include
9726 /usr/X11R5/include
9727 /usr/X11R4/include
9729 /usr/include/X11
9730 /usr/include/X11R7
9731 /usr/include/X11R6
9732 /usr/include/X11R5
9733 /usr/include/X11R4
9735 /usr/local/X11/include
9736 /usr/local/X11R7/include
9737 /usr/local/X11R6/include
9738 /usr/local/X11R5/include
9739 /usr/local/X11R4/include
9741 /usr/local/include/X11
9742 /usr/local/include/X11R7
9743 /usr/local/include/X11R6
9744 /usr/local/include/X11R5
9745 /usr/local/include/X11R4
9747 /usr/X386/include
9748 /usr/x386/include
9749 /usr/XFree86/include/X11
9751 /usr/include
9752 /usr/local/include
9753 /usr/unsupported/include
9754 /usr/athena/include
9755 /usr/local/x11r5/include
9756 /usr/lpp/Xamples/include
9758 /usr/openwin/include
9759 /usr/openwin/share/include'
9761 if test "$ac_x_includes" = no; then
9762 # Guess where to find include files, by looking for Xlib.h.
9763 # First, try using that file with no special directory specified.
9764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9765 /* end confdefs.h. */
9766 #include <X11/Xlib.h>
9767 _ACEOF
9768 if ac_fn_c_try_cpp "$LINENO"; then :
9769 # We can compile using X headers with no special include directory.
9770 ac_x_includes=
9771 else
9772 for ac_dir in $ac_x_header_dirs; do
9773 if test -r "$ac_dir/X11/Xlib.h"; then
9774 ac_x_includes=$ac_dir
9775 break
9777 done
9779 rm -f conftest.err conftest.$ac_ext
9780 fi # $ac_x_includes = no
9782 if test "$ac_x_libraries" = no; then
9783 # Check for the libraries.
9784 # See if we find them without any special options.
9785 # Don't add to $LIBS permanently.
9786 ac_save_LIBS=$LIBS
9787 LIBS="-lX11 $LIBS"
9788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9789 /* end confdefs.h. */
9790 #include <X11/Xlib.h>
9792 main ()
9794 XrmInitialize ()
9796 return 0;
9798 _ACEOF
9799 if ac_fn_c_try_link "$LINENO"; then :
9800 LIBS=$ac_save_LIBS
9801 # We can link X programs with no special library path.
9802 ac_x_libraries=
9803 else
9804 LIBS=$ac_save_LIBS
9805 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9807 # Don't even attempt the hair of trying to link an X program!
9808 for ac_extension in a so sl dylib la dll; do
9809 if test -r "$ac_dir/libX11.$ac_extension"; then
9810 ac_x_libraries=$ac_dir
9811 break 2
9813 done
9814 done
9816 rm -f core conftest.err conftest.$ac_objext \
9817 conftest$ac_exeext conftest.$ac_ext
9818 fi # $ac_x_libraries = no
9820 case $ac_x_includes,$ac_x_libraries in #(
9821 no,* | *,no | *\'*)
9822 # Didn't find X, or a directory has "'" in its name.
9823 ac_cv_have_x="have_x=no";; #(
9825 # Record where we found X for the cache.
9826 ac_cv_have_x="have_x=yes\
9827 ac_x_includes='$ac_x_includes'\
9828 ac_x_libraries='$ac_x_libraries'"
9829 esac
9831 ;; #(
9832 *) have_x=yes;;
9833 esac
9834 eval "$ac_cv_have_x"
9835 fi # $with_x != no
9837 if test "$have_x" != yes; then
9838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9839 $as_echo "$have_x" >&6; }
9840 no_x=yes
9841 else
9842 # If each of the values was on the command line, it overrides each guess.
9843 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9844 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9845 # Update the cache value to reflect the command line values.
9846 ac_cv_have_x="have_x=yes\
9847 ac_x_includes='$x_includes'\
9848 ac_x_libraries='$x_libraries'"
9849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9850 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9853 if test "$no_x" != yes; then
9854 window_system=x11
9857 LD_SWITCH_X_SITE_RPATH=
9858 if test "${x_libraries}" != NONE; then
9859 if test -n "${x_libraries}"; then
9860 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9861 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9863 x_default_search_path=""
9864 x_search_path=${x_libraries}
9865 if test -z "${x_search_path}"; then
9866 x_search_path=/usr/lib
9868 for x_library in `echo ${x_search_path}: | \
9869 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9870 x_search_path="\
9871 ${x_library}/X11/%L/%T/%N%C%S:\
9872 ${x_library}/X11/%l/%T/%N%C%S:\
9873 ${x_library}/X11/%T/%N%C%S:\
9874 ${x_library}/X11/%L/%T/%N%S:\
9875 ${x_library}/X11/%l/%T/%N%S:\
9876 ${x_library}/X11/%T/%N%S"
9877 if test x"${x_default_search_path}" = x; then
9878 x_default_search_path=${x_search_path}
9879 else
9880 x_default_search_path="${x_search_path}:${x_default_search_path}"
9882 done
9886 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9887 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9890 if test x"${x_includes}" = x; then
9891 bitmapdir=/usr/include/X11/bitmaps
9892 else
9893 # accumulate include directories that have X11 bitmap subdirectories
9894 bmd_acc="dummyval"
9895 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9896 if test -d "${bmd}/X11/bitmaps"; then
9897 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9899 if test -d "${bmd}/bitmaps"; then
9900 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9902 done
9903 if test ${bmd_acc} != "dummyval"; then
9904 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9908 HAVE_NS=no
9909 NS_IMPL_COCOA=no
9910 NS_IMPL_GNUSTEP=no
9911 tmp_CPPFLAGS="$CPPFLAGS"
9912 tmp_CFLAGS="$CFLAGS"
9913 CPPFLAGS="$CPPFLAGS -x objective-c"
9914 CFLAGS="$CFLAGS -x objective-c"
9915 GNU_OBJC_CFLAGS=
9916 LIBS_GNUSTEP=
9917 if test "${with_ns}" != no; then
9918 if test "${opsys}" = darwin; then
9919 NS_IMPL_COCOA=yes
9920 ns_appdir=`pwd`/nextstep/Emacs.app
9921 ns_appbindir=${ns_appdir}/Contents/MacOS
9922 ns_appresdir=${ns_appdir}/Contents/Resources
9923 ns_appsrc=Cocoa/Emacs.base
9924 elif test -f $GNUSTEP_CONFIG_FILE; then
9925 NS_IMPL_GNUSTEP=yes
9926 ns_appdir=`pwd`/nextstep/Emacs.app
9927 ns_appbindir=${ns_appdir}
9928 ns_appresdir=${ns_appdir}/Resources
9929 ns_appsrc=GNUstep/Emacs.base
9930 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9931 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9932 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9933 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9934 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9935 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9936 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9937 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9938 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9939 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9940 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9941 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
9942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9943 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9944 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9945 $as_echo_n "(cached) " >&6
9946 else
9947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9948 /* end confdefs.h. */
9949 #include <GNUstepBase/GSConfig.h>
9951 main ()
9953 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9955 #else
9956 fail;
9957 #endif
9959 return 0;
9961 _ACEOF
9962 if ac_fn_c_try_compile "$LINENO"; then :
9963 emacs_cv_objc_exceptions=yes
9964 else
9965 emacs_cv_objc_exceptions=no
9967 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9970 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9971 if test $emacs_cv_objc_exceptions = yes; then
9973 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9975 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9979 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9981 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9982 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9983 HAVE_NS=yes
9984 else
9985 as_fn_error "\`--with-ns' was specified, but the include
9986 files are missing or cannot be compiled." "$LINENO" 5
9991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9992 /* end confdefs.h. */
9993 #include <AppKit/AppKit.h>
9995 main ()
9998 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
9999 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
10000 ; /* OK */
10001 #else
10002 #error "OSX 10.4 or newer required"
10003 #endif
10004 #endif
10007 return 0;
10009 _ACEOF
10010 if ac_fn_c_try_compile "$LINENO"; then :
10011 ns_osx_have_104=yes
10012 else
10013 ns_osx_have_104=no
10015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10017 /* end confdefs.h. */
10018 #include <Foundation/NSObjCRuntime.h>
10020 main ()
10022 NSInteger i;
10024 return 0;
10026 _ACEOF
10027 if ac_fn_c_try_compile "$LINENO"; then :
10028 ns_have_nsinteger=yes
10029 else
10030 ns_have_nsinteger=no
10032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10033 if test $ns_osx_have_104 = no; then
10034 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10036 if test $ns_have_nsinteger = yes; then
10038 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10045 INSTALL_ARCH_INDEP_EXTRA=install-etc
10046 ns_self_contained=no
10047 NS_OBJ=
10048 NS_OBJC_OBJ=
10049 if test "${HAVE_NS}" = yes; then
10050 if test "$with_toolkit_scroll_bars" = "no"; then
10051 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10054 window_system=nextstep
10055 # set up packaging dirs
10056 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10057 ns_self_contained=yes
10058 prefix=${ns_appresdir}
10059 exec_prefix=${ns_appbindir}
10060 libexecdir="\${ns_appbindir}/libexec"
10061 archlibdir="\${ns_appbindir}/libexec"
10062 docdir="\${ns_appresdir}/etc"
10063 etcdir="\${ns_appresdir}/etc"
10064 infodir="\${ns_appresdir}/info"
10065 mandir="\${ns_appresdir}/man"
10066 lispdir="\${ns_appresdir}/lisp"
10067 leimdir="\${ns_appresdir}/leim"
10068 INSTALL_ARCH_INDEP_EXTRA=
10070 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
10072 CFLAGS="$tmp_CFLAGS"
10073 CPPFLAGS="$tmp_CPPFLAGS"
10079 HAVE_W32=no
10080 W32_OBJ=
10081 W32_LIBS=
10082 EMACSRES=
10083 CLIENTRES=
10084 CLIENTW=
10085 W32_RES_LINK=
10086 EMACS_MANIFEST=
10087 if test "${with_w32}" != no; then
10088 case "${opsys}" in
10089 cygwin)
10090 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10091 if test "x$ac_cv_header_windows_h" = x""yes; then :
10092 HAVE_W32=yes
10093 else
10094 as_fn_error "\`--with-w32' was specified, but windows.h
10095 cannot be found." "$LINENO" 5
10100 mingw32)
10101 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10104 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10106 esac
10109 if test "${opsys}" = "mingw32"; then
10110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10111 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10113 /* end confdefs.h. */
10115 #include <windows.h>
10116 #include <usp10.h>
10118 main ()
10120 void test(PIMAGE_NT_HEADERS pHeader)
10121 {PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader);}
10123 return 0;
10125 _ACEOF
10126 if ac_fn_c_try_compile "$LINENO"; then :
10127 emacs_cv_w32api=yes
10128 HAVE_W32=yes
10129 else
10130 emacs_cv_w32api=no
10132 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10134 $as_echo "$emacs_cv_w32api" >&6; }
10135 if test "${emacs_cv_w32api}" = "no"; then
10136 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10140 FIRSTFILE_OBJ=
10141 NTDIR=
10142 LIBS_ECLIENT=
10143 LIB_WSOCK32=
10144 NTLIB=
10145 CM_OBJ="cm.o"
10146 XARGS_LIMIT=
10147 if test "${HAVE_W32}" = "yes"; then
10149 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10151 if test -n "$ac_tool_prefix"; then
10152 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10153 set dummy ${ac_tool_prefix}windres; ac_word=$2
10154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10155 $as_echo_n "checking for $ac_word... " >&6; }
10156 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10157 $as_echo_n "(cached) " >&6
10158 else
10159 if test -n "$WINDRES"; then
10160 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10161 else
10162 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10163 for as_dir in $PATH
10165 IFS=$as_save_IFS
10166 test -z "$as_dir" && as_dir=.
10167 for ac_exec_ext in '' $ac_executable_extensions; do
10168 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10169 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10170 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10171 break 2
10173 done
10174 done
10175 IFS=$as_save_IFS
10179 WINDRES=$ac_cv_prog_WINDRES
10180 if test -n "$WINDRES"; then
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10182 $as_echo "$WINDRES" >&6; }
10183 else
10184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10185 $as_echo "no" >&6; }
10190 if test -z "$ac_cv_prog_WINDRES"; then
10191 ac_ct_WINDRES=$WINDRES
10192 # Extract the first word of "windres", so it can be a program name with args.
10193 set dummy windres; ac_word=$2
10194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10195 $as_echo_n "checking for $ac_word... " >&6; }
10196 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10197 $as_echo_n "(cached) " >&6
10198 else
10199 if test -n "$ac_ct_WINDRES"; then
10200 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10201 else
10202 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10203 for as_dir in $PATH
10205 IFS=$as_save_IFS
10206 test -z "$as_dir" && as_dir=.
10207 for ac_exec_ext in '' $ac_executable_extensions; do
10208 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10209 ac_cv_prog_ac_ct_WINDRES="windres"
10210 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10211 break 2
10213 done
10214 done
10215 IFS=$as_save_IFS
10219 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10220 if test -n "$ac_ct_WINDRES"; then
10221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10222 $as_echo "$ac_ct_WINDRES" >&6; }
10223 else
10224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10225 $as_echo "no" >&6; }
10228 if test "x$ac_ct_WINDRES" = x; then
10229 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10230 else
10231 case $cross_compiling:$ac_tool_warned in
10232 yes:)
10233 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10234 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10235 ac_tool_warned=yes ;;
10236 esac
10237 WINDRES=$ac_ct_WINDRES
10239 else
10240 WINDRES="$ac_cv_prog_WINDRES"
10243 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10244 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10245 EMACSRES="emacs.res"
10246 case "$canonical" in
10247 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10248 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10249 esac
10250 if test "${opsys}" = "cygwin"; then
10251 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10252 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10253 # Tell the linker that emacs.res is an object (which we compile from
10254 # the rc file), not a linker script.
10255 W32_RES_LINK="-Wl,emacs.res"
10256 else
10257 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10258 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10259 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10260 W32_RES_LINK="\$(EMACSRES)"
10261 CLIENTRES="emacsclient.res"
10262 CLIENTW="emacsclientw\$(EXEEXT)"
10263 FIRSTFILE_OBJ=firstfile.o
10264 NTDIR=nt
10265 CM_OBJ=
10266 LIBS_ECLIENT="-lcomctl32"
10267 LIB_WSOCK32="-lwsock32"
10268 NTLIB="ntlib.$ac_objext"
10269 XARGS_LIMIT="-s 10000"
10287 if test "${HAVE_W32}" = "yes"; then
10288 window_system=w32
10289 with_xft=no
10292 ## $window_system is now set to the window system we will
10293 ## ultimately use.
10295 term_header=
10296 HAVE_X_WINDOWS=no
10297 HAVE_X11=no
10298 USE_X_TOOLKIT=none
10300 case "${window_system}" in
10301 x11 )
10302 HAVE_X_WINDOWS=yes
10303 HAVE_X11=yes
10304 term_header=xterm.h
10305 case "${with_x_toolkit}" in
10306 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10307 motif ) USE_X_TOOLKIT=MOTIF ;;
10308 gtk ) with_gtk=yes
10309 term_header=gtkutil.h
10310 USE_X_TOOLKIT=none ;;
10311 gtk2 ) with_gtk2=yes
10312 term_header=gtkutil.h
10313 USE_X_TOOLKIT=none ;;
10314 gtk3 ) with_gtk3=yes
10315 term_header=gtkutil.h
10316 USE_X_TOOLKIT=none ;;
10317 no ) USE_X_TOOLKIT=none ;;
10318 * ) USE_X_TOOLKIT=maybe ;;
10319 esac
10321 nextstep )
10322 term_header=nsterm.h
10324 w32 )
10325 term_header=w32term.h
10327 esac
10329 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10330 # Extract the first word of "X", so it can be a program name with args.
10331 set dummy X; ac_word=$2
10332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10333 $as_echo_n "checking for $ac_word... " >&6; }
10334 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10335 $as_echo_n "(cached) " >&6
10336 else
10337 if test -n "$HAVE_XSERVER"; then
10338 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10339 else
10340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10341 for as_dir in $PATH
10343 IFS=$as_save_IFS
10344 test -z "$as_dir" && as_dir=.
10345 for ac_exec_ext in '' $ac_executable_extensions; do
10346 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10347 ac_cv_prog_HAVE_XSERVER="true"
10348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10349 break 2
10351 done
10352 done
10353 IFS=$as_save_IFS
10355 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10358 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10359 if test -n "$HAVE_XSERVER"; then
10360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10361 $as_echo "$HAVE_XSERVER" >&6; }
10362 else
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10364 $as_echo "no" >&6; }
10368 if test "$HAVE_XSERVER" = true ||
10369 test -n "$DISPLAY" ||
10370 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10371 as_fn_error "You seem to be running X, but no X development libraries
10372 were found. You should install the relevant development files for X
10373 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10374 sure you have development files for image handling, i.e.
10375 tiff, gif, jpeg, png and xpm.
10376 If you are sure you want Emacs compiled without X window support, pass
10377 --without-x
10378 to configure." "$LINENO" 5
10382 ### If we're using X11, we should use the X menu package.
10383 HAVE_MENUS=no
10384 case ${HAVE_X11} in
10385 yes ) HAVE_MENUS=yes ;;
10386 esac
10388 # Does the opsystem file prohibit the use of the GNU malloc?
10389 # Assume not, until told otherwise.
10390 GNU_MALLOC=yes
10392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10393 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10394 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10395 $as_echo_n "(cached) " >&6
10396 else
10397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10398 /* end confdefs.h. */
10399 #include <malloc.h>
10400 static void hook (void) {}
10402 main ()
10404 malloc_set_state (malloc_get_state ());
10405 __after_morecore_hook = hook;
10406 __malloc_initialize_hook = hook;
10408 return 0;
10410 _ACEOF
10411 if ac_fn_c_try_link "$LINENO"; then :
10412 emacs_cv_var_doug_lea_malloc=yes
10413 else
10414 emacs_cv_var_doug_lea_malloc=no
10416 rm -f core conftest.err conftest.$ac_objext \
10417 conftest$ac_exeext conftest.$ac_ext
10419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10420 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10421 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10424 system_malloc=no
10425 case "$opsys" in
10426 ## darwin ld insists on the use of malloc routines in the System framework.
10427 darwin|sol2-10) system_malloc=yes ;;
10428 esac
10430 if test "${system_malloc}" = "yes"; then
10432 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10434 GNU_MALLOC=no
10435 GNU_MALLOC_reason="
10436 (The GNU allocators don't work with this system configuration.)"
10437 GMALLOC_OBJ=
10438 VMLIMIT_OBJ=
10439 else
10440 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10441 VMLIMIT_OBJ=vm-limit.o
10443 for ac_header in sys/vlimit.h
10444 do :
10445 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10446 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10447 cat >>confdefs.h <<_ACEOF
10448 #define HAVE_SYS_VLIMIT_H 1
10449 _ACEOF
10453 done
10455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10456 $as_echo_n "checking for data_start... " >&6; }
10457 if test "${emacs_cv_data_start+set}" = set; then :
10458 $as_echo_n "(cached) " >&6
10459 else
10460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10461 /* end confdefs.h. */
10462 extern char data_start[]; char ch;
10464 main ()
10466 return data_start < &ch;
10468 return 0;
10470 _ACEOF
10471 if ac_fn_c_try_link "$LINENO"; then :
10472 emacs_cv_data_start=yes
10473 else
10474 emacs_cv_data_start=no
10476 rm -f core conftest.err conftest.$ac_objext \
10477 conftest$ac_exeext conftest.$ac_ext
10479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10480 $as_echo "$emacs_cv_data_start" >&6; }
10481 if test $emacs_cv_data_start = yes; then
10483 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10490 if test "$doug_lea_malloc" = "yes" ; then
10491 if test "$GNU_MALLOC" = yes ; then
10492 GNU_MALLOC_reason="
10493 (Using Doug Lea's new malloc from the GNU C Library.)"
10496 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10499 ## Use mmap directly for allocating larger buffers.
10500 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10501 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10502 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10503 case "$opsys" in
10504 gnu*) REL_ALLOC=no ;;
10505 esac
10508 if test x"${REL_ALLOC}" = x; then
10509 REL_ALLOC=${GNU_MALLOC}
10512 use_mmap_for_buffers=no
10513 case "$opsys" in
10514 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10515 esac
10524 for ac_func in getpagesize
10525 do :
10526 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10527 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10528 cat >>confdefs.h <<_ACEOF
10529 #define HAVE_GETPAGESIZE 1
10530 _ACEOF
10533 done
10535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10536 $as_echo_n "checking for working mmap... " >&6; }
10537 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10538 $as_echo_n "(cached) " >&6
10539 else
10540 if test "$cross_compiling" = yes; then :
10541 ac_cv_func_mmap_fixed_mapped=no
10542 else
10543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10544 /* end confdefs.h. */
10545 $ac_includes_default
10546 /* malloc might have been renamed as rpl_malloc. */
10547 #undef malloc
10549 /* Thanks to Mike Haertel and Jim Avera for this test.
10550 Here is a matrix of mmap possibilities:
10551 mmap private not fixed
10552 mmap private fixed at somewhere currently unmapped
10553 mmap private fixed at somewhere already mapped
10554 mmap shared not fixed
10555 mmap shared fixed at somewhere currently unmapped
10556 mmap shared fixed at somewhere already mapped
10557 For private mappings, we should verify that changes cannot be read()
10558 back from the file, nor mmap's back from the file at a different
10559 address. (There have been systems where private was not correctly
10560 implemented like the infamous i386 svr4.0, and systems where the
10561 VM page cache was not coherent with the file system buffer cache
10562 like early versions of FreeBSD and possibly contemporary NetBSD.)
10563 For shared mappings, we should conversely verify that changes get
10564 propagated back to all the places they're supposed to be.
10566 Grep wants private fixed already mapped.
10567 The main things grep needs to know about mmap are:
10568 * does it exist and is it safe to write into the mmap'd area
10569 * how to use it (BSD variants) */
10571 #include <fcntl.h>
10572 #include <sys/mman.h>
10574 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10575 char *malloc ();
10576 #endif
10578 /* This mess was copied from the GNU getpagesize.h. */
10579 #ifndef HAVE_GETPAGESIZE
10580 # ifdef _SC_PAGESIZE
10581 # define getpagesize() sysconf(_SC_PAGESIZE)
10582 # else /* no _SC_PAGESIZE */
10583 # ifdef HAVE_SYS_PARAM_H
10584 # include <sys/param.h>
10585 # ifdef EXEC_PAGESIZE
10586 # define getpagesize() EXEC_PAGESIZE
10587 # else /* no EXEC_PAGESIZE */
10588 # ifdef NBPG
10589 # define getpagesize() NBPG * CLSIZE
10590 # ifndef CLSIZE
10591 # define CLSIZE 1
10592 # endif /* no CLSIZE */
10593 # else /* no NBPG */
10594 # ifdef NBPC
10595 # define getpagesize() NBPC
10596 # else /* no NBPC */
10597 # ifdef PAGESIZE
10598 # define getpagesize() PAGESIZE
10599 # endif /* PAGESIZE */
10600 # endif /* no NBPC */
10601 # endif /* no NBPG */
10602 # endif /* no EXEC_PAGESIZE */
10603 # else /* no HAVE_SYS_PARAM_H */
10604 # define getpagesize() 8192 /* punt totally */
10605 # endif /* no HAVE_SYS_PARAM_H */
10606 # endif /* no _SC_PAGESIZE */
10608 #endif /* no HAVE_GETPAGESIZE */
10611 main ()
10613 char *data, *data2, *data3;
10614 const char *cdata2;
10615 int i, pagesize;
10616 int fd, fd2;
10618 pagesize = getpagesize ();
10620 /* First, make a file with some known garbage in it. */
10621 data = (char *) malloc (pagesize);
10622 if (!data)
10623 return 1;
10624 for (i = 0; i < pagesize; ++i)
10625 *(data + i) = rand ();
10626 umask (0);
10627 fd = creat ("conftest.mmap", 0600);
10628 if (fd < 0)
10629 return 2;
10630 if (write (fd, data, pagesize) != pagesize)
10631 return 3;
10632 close (fd);
10634 /* Next, check that the tail of a page is zero-filled. File must have
10635 non-zero length, otherwise we risk SIGBUS for entire page. */
10636 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10637 if (fd2 < 0)
10638 return 4;
10639 cdata2 = "";
10640 if (write (fd2, cdata2, 1) != 1)
10641 return 5;
10642 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10643 if (data2 == MAP_FAILED)
10644 return 6;
10645 for (i = 0; i < pagesize; ++i)
10646 if (*(data2 + i))
10647 return 7;
10648 close (fd2);
10649 if (munmap (data2, pagesize))
10650 return 8;
10652 /* Next, try to mmap the file at a fixed address which already has
10653 something else allocated at it. If we can, also make sure that
10654 we see the same garbage. */
10655 fd = open ("conftest.mmap", O_RDWR);
10656 if (fd < 0)
10657 return 9;
10658 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10659 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10660 return 10;
10661 for (i = 0; i < pagesize; ++i)
10662 if (*(data + i) != *(data2 + i))
10663 return 11;
10665 /* Finally, make sure that changes to the mapped area do not
10666 percolate back to the file as seen by read(). (This is a bug on
10667 some variants of i386 svr4.0.) */
10668 for (i = 0; i < pagesize; ++i)
10669 *(data2 + i) = *(data2 + i) + 1;
10670 data3 = (char *) malloc (pagesize);
10671 if (!data3)
10672 return 12;
10673 if (read (fd, data3, pagesize) != pagesize)
10674 return 13;
10675 for (i = 0; i < pagesize; ++i)
10676 if (*(data + i) != *(data3 + i))
10677 return 14;
10678 close (fd);
10679 return 0;
10681 _ACEOF
10682 if ac_fn_c_try_run "$LINENO"; then :
10683 ac_cv_func_mmap_fixed_mapped=yes
10684 else
10685 ac_cv_func_mmap_fixed_mapped=no
10687 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10688 conftest.$ac_objext conftest.beam conftest.$ac_ext
10692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10693 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10694 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10696 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10699 rm -f conftest.mmap conftest.txt
10701 if test $use_mmap_for_buffers = yes; then
10703 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10705 REL_ALLOC=no
10708 LIBS="$LIBS_SYSTEM $LIBS"
10710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10711 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10712 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10713 $as_echo_n "(cached) " >&6
10714 else
10715 ac_check_lib_save_LIBS=$LIBS
10716 LIBS="-ldnet $LIBS"
10717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10718 /* end confdefs.h. */
10720 /* Override any GCC internal prototype to avoid an error.
10721 Use char because int might match the return type of a GCC
10722 builtin and then its argument prototype would still apply. */
10723 #ifdef __cplusplus
10724 extern "C"
10725 #endif
10726 char dnet_ntoa ();
10728 main ()
10730 return dnet_ntoa ();
10732 return 0;
10734 _ACEOF
10735 if ac_fn_c_try_link "$LINENO"; then :
10736 ac_cv_lib_dnet_dnet_ntoa=yes
10737 else
10738 ac_cv_lib_dnet_dnet_ntoa=no
10740 rm -f core conftest.err conftest.$ac_objext \
10741 conftest$ac_exeext conftest.$ac_ext
10742 LIBS=$ac_check_lib_save_LIBS
10744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10745 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10746 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10747 cat >>confdefs.h <<_ACEOF
10748 #define HAVE_LIBDNET 1
10749 _ACEOF
10751 LIBS="-ldnet $LIBS"
10756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10757 $as_echo_n "checking for main in -lXbsd... " >&6; }
10758 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10759 $as_echo_n "(cached) " >&6
10760 else
10761 ac_check_lib_save_LIBS=$LIBS
10762 LIBS="-lXbsd $LIBS"
10763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10764 /* end confdefs.h. */
10768 main ()
10770 return main ();
10772 return 0;
10774 _ACEOF
10775 if ac_fn_c_try_link "$LINENO"; then :
10776 ac_cv_lib_Xbsd_main=yes
10777 else
10778 ac_cv_lib_Xbsd_main=no
10780 rm -f core conftest.err conftest.$ac_objext \
10781 conftest$ac_exeext conftest.$ac_ext
10782 LIBS=$ac_check_lib_save_LIBS
10784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10785 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10786 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10787 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10791 LIB_PTHREAD=
10795 if test "$ac_cv_header_pthread_h"; then
10796 if test "$GMALLOC_OBJ" = gmalloc.o; then
10797 emacs_pthread_function=pthread_atfork
10798 else
10799 emacs_pthread_function=pthread_self
10801 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10803 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10804 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10805 $as_echo_n "(cached) " >&6
10806 else
10807 ac_check_lib_save_LIBS=$LIBS
10808 LIBS="-lpthread $LIBS"
10809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10810 /* end confdefs.h. */
10812 /* Override any GCC internal prototype to avoid an error.
10813 Use char because int might match the return type of a GCC
10814 builtin and then its argument prototype would still apply. */
10815 #ifdef __cplusplus
10816 extern "C"
10817 #endif
10818 char $emacs_pthread_function ();
10820 main ()
10822 return $emacs_pthread_function ();
10824 return 0;
10826 _ACEOF
10827 if ac_fn_c_try_link "$LINENO"; then :
10828 eval "$as_ac_Lib=yes"
10829 else
10830 eval "$as_ac_Lib=no"
10832 rm -f core conftest.err conftest.$ac_objext \
10833 conftest$ac_exeext conftest.$ac_ext
10834 LIBS=$ac_check_lib_save_LIBS
10836 eval ac_res=\$$as_ac_Lib
10837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10838 $as_echo "$ac_res" >&6; }
10839 eval as_val=\$$as_ac_Lib
10840 if test "x$as_val" = x""yes; then :
10841 HAVE_PTHREAD=yes
10845 if test "$HAVE_PTHREAD" = yes; then
10846 case "${canonical}" in
10847 *-hpux*) ;;
10848 *) LIB_PTHREAD="-lpthread"
10849 LIBS="$LIB_PTHREAD $LIBS" ;;
10850 esac
10852 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10858 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10859 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10860 $as_echo_n "(cached) " >&6
10861 else
10862 ac_check_lib_save_LIBS=$LIBS
10863 LIBS="-lpthreads $LIBS"
10864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10865 /* end confdefs.h. */
10867 /* Override any GCC internal prototype to avoid an error.
10868 Use char because int might match the return type of a GCC
10869 builtin and then its argument prototype would still apply. */
10870 #ifdef __cplusplus
10871 extern "C"
10872 #endif
10873 char cma_open ();
10875 main ()
10877 return cma_open ();
10879 return 0;
10881 _ACEOF
10882 if ac_fn_c_try_link "$LINENO"; then :
10883 ac_cv_lib_pthreads_cma_open=yes
10884 else
10885 ac_cv_lib_pthreads_cma_open=no
10887 rm -f core conftest.err conftest.$ac_objext \
10888 conftest$ac_exeext conftest.$ac_ext
10889 LIBS=$ac_check_lib_save_LIBS
10891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10892 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10893 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10894 cat >>confdefs.h <<_ACEOF
10895 #define HAVE_LIBPTHREADS 1
10896 _ACEOF
10898 LIBS="-lpthreads $LIBS"
10903 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10904 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10905 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10906 ## added to LIBS in configure would never contain the pthreads part,
10907 ## but the value used in Makefiles might. FIXME?
10909 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10910 ## be harmless on older versions of X where it happens to exist.
10911 test "$opsys" = "aix4-2" && \
10912 test $ac_cv_lib_pthreads_cma_open = yes && \
10913 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10916 case ${host_os} in
10917 aix*)
10918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10919 $as_echo_n "checking for -bbigtoc option... " >&6; }
10920 if test "${gdb_cv_bigtoc+set}" = set; then :
10921 $as_echo_n "(cached) " >&6
10922 else
10924 case $GCC in
10925 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10926 *) gdb_cv_bigtoc=-bbigtoc ;;
10927 esac
10929 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10931 /* end confdefs.h. */
10934 main ()
10936 int i;
10938 return 0;
10940 _ACEOF
10941 if ac_fn_c_try_link "$LINENO"; then :
10943 else
10944 gdb_cv_bigtoc=
10946 rm -f core conftest.err conftest.$ac_objext \
10947 conftest$ac_exeext conftest.$ac_ext
10950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10951 $as_echo "$gdb_cv_bigtoc" >&6; }
10953 esac
10955 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10956 # used for the tests that follow. We set them back to REAL_CFLAGS and
10957 # REAL_CPPFLAGS later on.
10959 REAL_CFLAGS="$CFLAGS"
10960 REAL_CPPFLAGS="$CPPFLAGS"
10962 if test "${HAVE_X11}" = "yes"; then
10963 DEFS="$C_SWITCH_X_SITE $DEFS"
10964 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10965 LIBS="-lX11 $LIBS"
10966 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10967 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10969 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10970 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10971 # but it's more convenient here to set LD_RUN_PATH since this
10972 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10973 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10974 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10975 export LD_RUN_PATH
10978 if test "${opsys}" = "gnu-linux"; then
10979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10980 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10982 /* end confdefs.h. */
10985 main ()
10987 XOpenDisplay ("foo");
10989 return 0;
10991 _ACEOF
10992 if ac_fn_c_try_link "$LINENO"; then :
10993 xgnu_linux_first_failure=no
10994 else
10995 xgnu_linux_first_failure=yes
10997 rm -f core conftest.err conftest.$ac_objext \
10998 conftest$ac_exeext conftest.$ac_ext
10999 if test "${xgnu_linux_first_failure}" = "yes"; then
11000 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
11001 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
11002 OLD_CPPFLAGS="$CPPFLAGS"
11003 OLD_LIBS="$LIBS"
11004 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
11005 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
11006 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
11007 LIBS="$LIBS -b i486-linuxaout"
11008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11009 /* end confdefs.h. */
11012 main ()
11014 XOpenDisplay ("foo");
11016 return 0;
11018 _ACEOF
11019 if ac_fn_c_try_link "$LINENO"; then :
11020 xgnu_linux_second_failure=no
11021 else
11022 xgnu_linux_second_failure=yes
11024 rm -f core conftest.err conftest.$ac_objext \
11025 conftest$ac_exeext conftest.$ac_ext
11026 if test "${xgnu_linux_second_failure}" = "yes"; then
11027 # If we get the same failure with -b, there is no use adding -b.
11028 # So take it out. This plays safe.
11029 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11030 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11031 CPPFLAGS="$OLD_CPPFLAGS"
11032 LIBS="$OLD_LIBS"
11033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11034 $as_echo "no" >&6; }
11035 else
11036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11037 $as_echo "yes" >&6; }
11039 else
11040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11041 $as_echo "no" >&6; }
11045 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11046 # header files included from there.
11047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11048 $as_echo_n "checking for Xkb... " >&6; }
11049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11050 /* end confdefs.h. */
11051 #include <X11/Xlib.h>
11052 #include <X11/XKBlib.h>
11054 main ()
11056 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11058 return 0;
11060 _ACEOF
11061 if ac_fn_c_try_link "$LINENO"; then :
11062 emacs_xkb=yes
11063 else
11064 emacs_xkb=no
11066 rm -f core conftest.err conftest.$ac_objext \
11067 conftest$ac_exeext conftest.$ac_ext
11068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11069 $as_echo "$emacs_xkb" >&6; }
11070 if test $emacs_xkb = yes; then
11072 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11076 for ac_func in XrmSetDatabase XScreenResourceString \
11077 XScreenNumberOfScreen
11078 do :
11079 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11080 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11081 eval as_val=\$$as_ac_var
11082 if test "x$as_val" = x""yes; then :
11083 cat >>confdefs.h <<_ACEOF
11084 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11085 _ACEOF
11088 done
11092 if test "${window_system}" = "x11"; then
11093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11094 $as_echo_n "checking X11 version 6... " >&6; }
11095 if test "${emacs_cv_x11_version_6+set}" = set; then :
11096 $as_echo_n "(cached) " >&6
11097 else
11098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11099 /* end confdefs.h. */
11100 #include <X11/Xlib.h>
11102 main ()
11104 #if XlibSpecificationRelease < 6
11105 fail;
11106 #endif
11109 return 0;
11111 _ACEOF
11112 if ac_fn_c_try_link "$LINENO"; then :
11113 emacs_cv_x11_version_6=yes
11114 else
11115 emacs_cv_x11_version_6=no
11117 rm -f core conftest.err conftest.$ac_objext \
11118 conftest$ac_exeext conftest.$ac_ext
11121 if test $emacs_cv_x11_version_6 = yes; then
11122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11123 $as_echo "6 or newer" >&6; }
11125 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11128 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11130 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11131 ## XIM support.
11132 case "$opsys" in
11133 sol2-*) : ;;
11135 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11138 esac
11139 else
11140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11141 $as_echo "before 6" >&6; }
11146 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11147 HAVE_RSVG=no
11148 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11149 if test "${with_rsvg}" != "no"; then
11150 RSVG_REQUIRED=2.11.0
11151 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11154 succeeded=no
11156 if test "$PKG_CONFIG" = "no" ; then
11158 else
11159 PKG_CONFIG_MIN_VERSION=0.9.0
11160 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11162 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11164 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11165 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11166 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11167 edit_cflags="
11168 s,///*,/,g
11169 s/^/ /
11170 s/ -I/ $isystem/g
11171 s/^ //
11173 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11174 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11176 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11177 succeeded=yes
11178 else
11179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11180 $as_echo "no" >&6; }
11181 RSVG_CFLAGS=""
11182 RSVG_LIBS=""
11183 ## If we have a custom action on failure, don't print errors, but
11184 ## do set a variable so people can do so. Do it in a subshell
11185 ## to capture any diagnostics in invoking pkg-config.
11186 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11192 else
11193 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11194 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11198 if test $succeeded = yes; then
11199 HAVE_RSVG=yes
11200 else
11207 if test $HAVE_RSVG = yes; then
11209 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11211 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11212 LIBS="$RSVG_LIBS $LIBS"
11217 HAVE_IMAGEMAGICK=no
11218 if test "${HAVE_X11}" = "yes"; then
11219 if test "${with_imagemagick}" != "no"; then
11220 ## 6.2.8 is the earliest version known to work, but earlier versions
11221 ## might work - let us know if you find one.
11222 ## 6.0.7 does not work. See bug#7955.
11223 ## 6.8.2 makes Emacs crash; see Bug#13867.
11224 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11226 succeeded=no
11228 if test "$PKG_CONFIG" = "no" ; then
11230 else
11231 PKG_CONFIG_MIN_VERSION=0.9.0
11232 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11234 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11236 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11237 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11238 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11239 edit_cflags="
11240 s,///*,/,g
11241 s/^/ /
11242 s/ -I/ $isystem/g
11243 s/^ //
11245 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11246 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11248 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11249 succeeded=yes
11250 else
11251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11252 $as_echo "no" >&6; }
11253 IMAGEMAGICK_CFLAGS=""
11254 IMAGEMAGICK_LIBS=""
11255 ## If we have a custom action on failure, don't print errors, but
11256 ## do set a variable so people can do so. Do it in a subshell
11257 ## to capture any diagnostics in invoking pkg-config.
11258 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11264 else
11265 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11266 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11270 if test $succeeded = yes; then
11271 HAVE_IMAGEMAGICK=yes
11272 else
11279 if test $HAVE_IMAGEMAGICK = yes; then
11281 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11283 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11284 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11285 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11286 do :
11287 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11288 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11289 eval as_val=\$$as_ac_var
11290 if test "x$as_val" = x""yes; then :
11291 cat >>confdefs.h <<_ACEOF
11292 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11293 _ACEOF
11296 done
11303 HAVE_GTK=no
11304 GTK_OBJ=
11305 check_gtk2=no
11306 gtk3_pkg_errors=
11307 if test "${opsys}" != "mingw32"; then
11308 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11309 GLIB_REQUIRED=2.28
11310 GTK_REQUIRED=3.0
11311 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11314 succeeded=no
11316 if test "$PKG_CONFIG" = "no" ; then
11317 pkg_check_gtk=no
11318 else
11319 PKG_CONFIG_MIN_VERSION=0.9.0
11320 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11322 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11324 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11325 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11326 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11327 edit_cflags="
11328 s,///*,/,g
11329 s/^/ /
11330 s/ -I/ $isystem/g
11331 s/^ //
11333 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11334 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11336 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11337 succeeded=yes
11338 else
11339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11340 $as_echo "no" >&6; }
11341 GTK_CFLAGS=""
11342 GTK_LIBS=""
11343 ## If we have a custom action on failure, don't print errors, but
11344 ## do set a variable so people can do so. Do it in a subshell
11345 ## to capture any diagnostics in invoking pkg-config.
11346 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11352 else
11353 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11354 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11358 if test $succeeded = yes; then
11359 pkg_check_gtk=yes
11360 else
11361 pkg_check_gtk=no
11364 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11365 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11367 if test "$pkg_check_gtk" = "yes"; then
11369 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11371 GTK_OBJ=emacsgtkfixed.o
11372 term_header=gtkutil.h
11373 USE_GTK_TOOLKIT="GTK3"
11374 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11375 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11376 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11378 else
11379 check_gtk2=yes
11380 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11384 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11385 GLIB_REQUIRED=2.10
11386 GTK_REQUIRED=2.10
11387 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11390 succeeded=no
11392 if test "$PKG_CONFIG" = "no" ; then
11393 pkg_check_gtk=no
11394 else
11395 PKG_CONFIG_MIN_VERSION=0.9.0
11396 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11398 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11400 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11401 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11402 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11403 edit_cflags="
11404 s,///*,/,g
11405 s/^/ /
11406 s/ -I/ $isystem/g
11407 s/^ //
11409 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11410 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11412 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11413 succeeded=yes
11414 else
11415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11416 $as_echo "no" >&6; }
11417 GTK_CFLAGS=""
11418 GTK_LIBS=""
11419 ## If we have a custom action on failure, don't print errors, but
11420 ## do set a variable so people can do so. Do it in a subshell
11421 ## to capture any diagnostics in invoking pkg-config.
11422 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11428 else
11429 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11430 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11434 if test $succeeded = yes; then
11435 pkg_check_gtk=yes
11436 else
11437 pkg_check_gtk=no
11440 if test "$pkg_check_gtk" = "no" &&
11441 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11442 then
11443 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11445 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11449 if test x"$pkg_check_gtk" = xyes; then
11453 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11454 CFLAGS="$CFLAGS $GTK_CFLAGS"
11455 LIBS="$GTK_LIBS $LIBS"
11456 GTK_COMPILES=no
11457 for ac_func in gtk_main
11458 do :
11459 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
11460 if test "x$ac_cv_func_gtk_main" = x""yes; then :
11461 cat >>confdefs.h <<_ACEOF
11462 #define HAVE_GTK_MAIN 1
11463 _ACEOF
11464 GTK_COMPILES=yes
11466 done
11468 if test "${GTK_COMPILES}" != "yes"; then
11469 if test "$USE_X_TOOLKIT" != "maybe"; then
11470 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11472 else
11473 HAVE_GTK=yes
11475 $as_echo "#define USE_GTK 1" >>confdefs.h
11477 GTK_OBJ="gtkutil.o $GTK_OBJ"
11478 USE_X_TOOLKIT=none
11479 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11481 else
11482 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11483 closing open displays. This is no problem if you just use
11484 one display, but if you use more than one and close one of them
11485 Emacs may crash." >&5
11486 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11487 closing open displays. This is no problem if you just use
11488 one display, but if you use more than one and close one of them
11489 Emacs may crash." >&2;}
11490 sleep 3
11498 if test "${HAVE_GTK}" = "yes"; then
11500 if test "$with_toolkit_scroll_bars" != no; then
11501 with_toolkit_scroll_bars=yes
11504 HAVE_GTK_FILE_SELECTION=no
11505 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11506 #include <gtk/gtk.h>
11508 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11509 HAVE_GTK_FILE_SELECTION=yes
11510 else
11511 HAVE_GTK_FILE_SELECTION=no
11514 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11515 for ac_func in gtk_file_selection_new
11516 do :
11517 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11518 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11519 cat >>confdefs.h <<_ACEOF
11520 #define HAVE_GTK_FILE_SELECTION_NEW 1
11521 _ACEOF
11524 done
11528 HAVE_GTK_HANDLE_BOX=no
11529 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11530 #include <gtk/gtk.h>
11532 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11533 HAVE_GTK_HANDLE_BOX=yes
11534 else
11535 HAVE_GTK_HANDLE_BOX=no
11538 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11539 for ac_func in gtk_handle_box_new
11540 do :
11541 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11542 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11543 cat >>confdefs.h <<_ACEOF
11544 #define HAVE_GTK_HANDLE_BOX_NEW 1
11545 _ACEOF
11548 done
11552 HAVE_GTK_TEAROFF_MENU_ITEM=no
11553 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11554 #include <gtk/gtk.h>
11556 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11557 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11558 else
11559 HAVE_GTK_TEAROFF_MENU_ITEM=no
11562 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11563 for ac_func in gtk_tearoff_menu_item_new
11564 do :
11565 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11566 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11567 cat >>confdefs.h <<_ACEOF
11568 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11569 _ACEOF
11572 done
11576 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11577 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11578 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11579 gtk_orientable_set_orientation \
11580 gtk_window_set_has_resize_grip
11581 do :
11582 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11583 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11584 eval as_val=\$$as_ac_var
11585 if test "x$as_val" = x""yes; then :
11586 cat >>confdefs.h <<_ACEOF
11587 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11588 _ACEOF
11591 done
11594 term_header=gtkutil.h
11597 HAVE_DBUS=no
11598 DBUS_OBJ=
11599 if test "${with_dbus}" = "yes"; then
11601 succeeded=no
11603 if test "$PKG_CONFIG" = "no" ; then
11604 HAVE_DBUS=no
11605 else
11606 PKG_CONFIG_MIN_VERSION=0.9.0
11607 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11609 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11611 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11612 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11613 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11614 edit_cflags="
11615 s,///*,/,g
11616 s/^/ /
11617 s/ -I/ $isystem/g
11618 s/^ //
11620 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11621 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11623 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11624 succeeded=yes
11625 else
11626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11627 $as_echo "no" >&6; }
11628 DBUS_CFLAGS=""
11629 DBUS_LIBS=""
11630 ## If we have a custom action on failure, don't print errors, but
11631 ## do set a variable so people can do so. Do it in a subshell
11632 ## to capture any diagnostics in invoking pkg-config.
11633 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11639 else
11640 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11641 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11645 if test $succeeded = yes; then
11646 HAVE_DBUS=yes
11647 else
11648 HAVE_DBUS=no
11651 if test "$HAVE_DBUS" = yes; then
11652 LIBS="$LIBS $DBUS_LIBS"
11654 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11656 for ac_func in dbus_watch_get_unix_fd \
11657 dbus_type_is_valid \
11658 dbus_validate_bus_name \
11659 dbus_validate_path \
11660 dbus_validate_interface \
11661 dbus_validate_member
11662 do :
11663 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11664 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11665 eval as_val=\$$as_ac_var
11666 if test "x$as_val" = x""yes; then :
11667 cat >>confdefs.h <<_ACEOF
11668 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11669 _ACEOF
11672 done
11674 DBUS_OBJ=dbusbind.o
11679 HAVE_GSETTINGS=no
11680 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11682 succeeded=no
11684 if test "$PKG_CONFIG" = "no" ; then
11685 HAVE_GSETTINGS=no
11686 else
11687 PKG_CONFIG_MIN_VERSION=0.9.0
11688 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11690 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11692 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
11693 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
11694 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
11695 edit_cflags="
11696 s,///*,/,g
11697 s/^/ /
11698 s/ -I/ $isystem/g
11699 s/^ //
11701 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
11702 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11704 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11705 succeeded=yes
11706 else
11707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11708 $as_echo "no" >&6; }
11709 GSETTINGS_CFLAGS=""
11710 GSETTINGS_LIBS=""
11711 ## If we have a custom action on failure, don't print errors, but
11712 ## do set a variable so people can do so. Do it in a subshell
11713 ## to capture any diagnostics in invoking pkg-config.
11714 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
11720 else
11721 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11722 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11726 if test $succeeded = yes; then
11727 HAVE_GSETTINGS=yes
11728 else
11729 HAVE_GSETTINGS=no
11732 if test "$HAVE_GSETTINGS" = "yes"; then
11734 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11736 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11737 SETTINGS_LIBS="$GSETTINGS_LIBS"
11741 HAVE_GCONF=no
11742 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11744 succeeded=no
11746 if test "$PKG_CONFIG" = "no" ; then
11747 HAVE_GCONF=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 gconf-2.0 >= 2.13" >&5
11752 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11754 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
11755 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11756 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
11757 edit_cflags="
11758 s,///*,/,g
11759 s/^/ /
11760 s/ -I/ $isystem/g
11761 s/^ //
11763 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
11764 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11766 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11767 succeeded=yes
11768 else
11769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11770 $as_echo "no" >&6; }
11771 GCONF_CFLAGS=""
11772 GCONF_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 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 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_GCONF=yes
11790 else
11791 HAVE_GCONF=no
11794 if test "$HAVE_GCONF" = yes; then
11796 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11798 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11799 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11803 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11805 succeeded=no
11807 if test "$PKG_CONFIG" = "no" ; then
11808 HAVE_GOBJECT=no
11809 else
11810 PKG_CONFIG_MIN_VERSION=0.9.0
11811 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
11813 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
11815 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
11816 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
11817 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
11818 edit_cflags="
11819 s,///*,/,g
11820 s/^/ /
11821 s/ -I/ $isystem/g
11822 s/^ //
11824 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
11825 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
11826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
11827 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
11828 succeeded=yes
11829 else
11830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11831 $as_echo "no" >&6; }
11832 GOBJECT_CFLAGS=""
11833 GOBJECT_LIBS=""
11834 ## If we have a custom action on failure, don't print errors, but
11835 ## do set a variable so people can do so. Do it in a subshell
11836 ## to capture any diagnostics in invoking pkg-config.
11837 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
11843 else
11844 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11845 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11849 if test $succeeded = yes; then
11850 HAVE_GOBJECT=yes
11851 else
11852 HAVE_GOBJECT=no
11855 if test "$HAVE_GOBJECT" = "yes"; then
11856 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11857 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11859 SAVE_CFLAGS="$CFLAGS"
11860 SAVE_LIBS="$LIBS"
11861 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11862 LIBS="$SETTINGS_LIBS $LIBS"
11863 for ac_func in g_type_init
11864 do :
11865 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11866 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11867 cat >>confdefs.h <<_ACEOF
11868 #define HAVE_G_TYPE_INIT 1
11869 _ACEOF
11872 done
11874 CFLAGS="$SAVE_CFLAGS"
11875 LIBS="$SAVE_LIBS"
11881 HAVE_LIBSELINUX=no
11882 LIBSELINUX_LIBS=
11883 if test "${with_selinux}" = "yes"; then
11884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11885 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11886 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11887 $as_echo_n "(cached) " >&6
11888 else
11889 ac_check_lib_save_LIBS=$LIBS
11890 LIBS="-lselinux $LIBS"
11891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11892 /* end confdefs.h. */
11894 /* Override any GCC internal prototype to avoid an error.
11895 Use char because int might match the return type of a GCC
11896 builtin and then its argument prototype would still apply. */
11897 #ifdef __cplusplus
11898 extern "C"
11899 #endif
11900 char lgetfilecon ();
11902 main ()
11904 return lgetfilecon ();
11906 return 0;
11908 _ACEOF
11909 if ac_fn_c_try_link "$LINENO"; then :
11910 ac_cv_lib_selinux_lgetfilecon=yes
11911 else
11912 ac_cv_lib_selinux_lgetfilecon=no
11914 rm -f core conftest.err conftest.$ac_objext \
11915 conftest$ac_exeext conftest.$ac_ext
11916 LIBS=$ac_check_lib_save_LIBS
11918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11919 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11920 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11921 HAVE_LIBSELINUX=yes
11922 else
11923 HAVE_LIBSELINUX=no
11926 if test "$HAVE_LIBSELINUX" = yes; then
11928 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11930 LIBSELINUX_LIBS=-lselinux
11935 HAVE_GNUTLS=no
11936 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11937 if test "${with_gnutls}" = "yes" ; then
11939 succeeded=no
11941 if test "$PKG_CONFIG" = "no" ; then
11942 HAVE_GNUTLS=no
11943 else
11944 PKG_CONFIG_MIN_VERSION=0.9.0
11945 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11947 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11949 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
11950 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
11951 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
11952 edit_cflags="
11953 s,///*,/,g
11954 s/^/ /
11955 s/ -I/ $isystem/g
11956 s/^ //
11958 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11959 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11961 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11962 succeeded=yes
11963 else
11964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11965 $as_echo "no" >&6; }
11966 LIBGNUTLS_CFLAGS=""
11967 LIBGNUTLS_LIBS=""
11968 ## If we have a custom action on failure, don't print errors, but
11969 ## do set a variable so people can do so. Do it in a subshell
11970 ## to capture any diagnostics in invoking pkg-config.
11971 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
11977 else
11978 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11979 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11983 if test $succeeded = yes; then
11984 HAVE_GNUTLS=yes
11985 else
11986 HAVE_GNUTLS=no
11989 if test "${HAVE_GNUTLS}" = "yes"; then
11991 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11995 OLD_CFLAGS=$CFLAGS
11996 OLD_LIBS=$LIBS
11997 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11998 LIBS="$LIBGNUTLS_LIBS $LIBS"
11999 for ac_func in gnutls_certificate_set_verify_function
12000 do :
12001 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
12002 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
12003 cat >>confdefs.h <<_ACEOF
12004 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
12005 _ACEOF
12006 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
12008 done
12011 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
12013 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
12017 # Windows loads GnuTLS dynamically
12018 if test "${opsys}" = "mingw32"; then
12019 CFLAGS=$OLD_CFLAGS
12020 LIBS=$OLD_LIBS
12021 LIBGNUTLS_LIBS=
12028 NOTIFY_OBJ=
12029 NOTIFY_SUMMARY=no
12031 if test "${with_file_notification}" = "yes"; then
12032 if test "${opsys}" = "mingw32"; then
12033 with_file_notification=w32
12034 else
12035 with_file_notification=gfile
12039 if test "${with_file_notification}" = "gfile"; then
12041 succeeded=no
12043 if test "$PKG_CONFIG" = "no" ; then
12044 HAVE_GFILENOTIFY=no
12045 else
12046 PKG_CONFIG_MIN_VERSION=0.9.0
12047 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12049 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12051 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12052 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12053 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12054 edit_cflags="
12055 s,///*,/,g
12056 s/^/ /
12057 s/ -I/ $isystem/g
12058 s/^ //
12060 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12061 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12063 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12064 succeeded=yes
12065 else
12066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12067 $as_echo "no" >&6; }
12068 GFILENOTIFY_CFLAGS=""
12069 GFILENOTIFY_LIBS=""
12070 ## If we have a custom action on failure, don't print errors, but
12071 ## do set a variable so people can do so. Do it in a subshell
12072 ## to capture any diagnostics in invoking pkg-config.
12073 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12079 else
12080 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12081 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12085 if test $succeeded = yes; then
12086 HAVE_GFILENOTIFY=yes
12087 else
12088 HAVE_GFILENOTIFY=no
12091 if test "$HAVE_GFILENOTIFY" = "yes"; then
12093 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12095 NOTIFY_OBJ=gfilenotify.o
12096 NOTIFY_SUMMARY="yes -lgio (gfile)"
12099 if test "${with_file_notification}" = "inotify"; then
12100 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12101 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12106 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12107 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12108 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12112 if test "$ac_cv_func_inotify_init1" = yes; then
12114 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12116 NOTIFY_OBJ=inotify.o
12117 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12121 if test "${with_file_notification}" = "w32"; then
12122 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12123 if test "x$ac_cv_header_windows_h" = x""yes; then :
12128 if test "$ac_cv_header_windows_h" = yes ; then
12130 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12132 NOTIFY_OBJ=w32notify.o
12133 NOTIFY_SUMMARY="yes (w32)"
12136 if test -n "$NOTIFY_OBJ"; then
12138 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12145 HAVE_XAW3D=no
12146 LUCID_LIBW=
12147 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12148 if test "$with_xaw3d" != no; then
12149 if test "${emacs_cv_xaw3d+set}" = set; then :
12150 $as_echo_n "(cached) " >&6
12151 else
12152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12153 /* end confdefs.h. */
12155 #include <X11/Intrinsic.h>
12156 #include <X11/Xaw3d/Simple.h>
12158 main ()
12162 return 0;
12164 _ACEOF
12165 if ac_fn_c_try_link "$LINENO"; then :
12166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12167 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12168 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12169 $as_echo_n "(cached) " >&6
12170 else
12171 ac_check_lib_save_LIBS=$LIBS
12172 LIBS="-lXaw3d $LIBS"
12173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12174 /* end confdefs.h. */
12176 /* Override any GCC internal prototype to avoid an error.
12177 Use char because int might match the return type of a GCC
12178 builtin and then its argument prototype would still apply. */
12179 #ifdef __cplusplus
12180 extern "C"
12181 #endif
12182 char XawScrollbarSetThumb ();
12184 main ()
12186 return XawScrollbarSetThumb ();
12188 return 0;
12190 _ACEOF
12191 if ac_fn_c_try_link "$LINENO"; then :
12192 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12193 else
12194 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12196 rm -f core conftest.err conftest.$ac_objext \
12197 conftest$ac_exeext conftest.$ac_ext
12198 LIBS=$ac_check_lib_save_LIBS
12200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12201 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12202 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12203 emacs_cv_xaw3d=yes
12204 else
12205 emacs_cv_xaw3d=no
12208 else
12209 emacs_cv_xaw3d=no
12211 rm -f core conftest.err conftest.$ac_objext \
12212 conftest$ac_exeext conftest.$ac_ext
12215 else
12216 emacs_cv_xaw3d=no
12218 if test $emacs_cv_xaw3d = yes; then
12219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12220 $as_echo_n "checking for xaw3d... " >&6; }
12221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12222 $as_echo "yes; using Lucid toolkit" >&6; }
12223 USE_X_TOOLKIT=LUCID
12224 HAVE_XAW3D=yes
12225 LUCID_LIBW=-lXaw3d
12227 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12229 else
12230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12231 $as_echo_n "checking for xaw3d... " >&6; }
12232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12233 $as_echo "no" >&6; }
12234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12235 $as_echo_n "checking for libXaw... " >&6; }
12236 if test "${emacs_cv_xaw+set}" = set; then :
12237 $as_echo_n "(cached) " >&6
12238 else
12239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12240 /* end confdefs.h. */
12242 #include <X11/Intrinsic.h>
12243 #include <X11/Xaw/Simple.h>
12245 main ()
12249 return 0;
12251 _ACEOF
12252 if ac_fn_c_try_link "$LINENO"; then :
12253 emacs_cv_xaw=yes
12254 else
12255 emacs_cv_xaw=no
12257 rm -f core conftest.err conftest.$ac_objext \
12258 conftest$ac_exeext conftest.$ac_ext
12261 if test $emacs_cv_xaw = yes; then
12262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12263 $as_echo "yes; using Lucid toolkit" >&6; }
12264 USE_X_TOOLKIT=LUCID
12265 LUCID_LIBW=-lXaw
12266 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12267 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12268 else
12269 as_fn_error "No X toolkit could be found.
12270 If you are sure you want Emacs compiled without an X toolkit, pass
12271 --with-x-toolkit=no
12272 to configure. Otherwise, install the development libraries for the toolkit
12273 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12278 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12280 LIBXTR6=
12281 if test "${USE_X_TOOLKIT}" != "none"; then
12282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12283 $as_echo_n "checking X11 toolkit version... " >&6; }
12284 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12285 $as_echo_n "(cached) " >&6
12286 else
12287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12288 /* end confdefs.h. */
12289 #include <X11/Intrinsic.h>
12291 main ()
12293 #if XtSpecificationRelease < 6
12294 fail;
12295 #endif
12298 return 0;
12300 _ACEOF
12301 if ac_fn_c_try_link "$LINENO"; then :
12302 emacs_cv_x11_toolkit_version_6=yes
12303 else
12304 emacs_cv_x11_toolkit_version_6=no
12306 rm -f core conftest.err conftest.$ac_objext \
12307 conftest$ac_exeext conftest.$ac_ext
12310 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12311 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12313 $as_echo "6 or newer" >&6; }
12315 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12317 LIBXTR6="-lSM -lICE"
12318 case "$opsys" in
12319 ## Use libw.a along with X11R6 Xt.
12320 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12321 esac
12322 else
12323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12324 $as_echo "before 6" >&6; }
12327 OLDLIBS="$LIBS"
12328 if test x$HAVE_X11XTR6 = xyes; then
12329 LIBS="-lXt -lSM -lICE $LIBS"
12330 else
12331 LIBS="-lXt $LIBS"
12333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12334 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12335 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12336 $as_echo_n "(cached) " >&6
12337 else
12338 ac_check_lib_save_LIBS=$LIBS
12339 LIBS="-lXmu $LIBS"
12340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12341 /* end confdefs.h. */
12343 /* Override any GCC internal prototype to avoid an error.
12344 Use char because int might match the return type of a GCC
12345 builtin and then its argument prototype would still apply. */
12346 #ifdef __cplusplus
12347 extern "C"
12348 #endif
12349 char XmuConvertStandardSelection ();
12351 main ()
12353 return XmuConvertStandardSelection ();
12355 return 0;
12357 _ACEOF
12358 if ac_fn_c_try_link "$LINENO"; then :
12359 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12360 else
12361 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12363 rm -f core conftest.err conftest.$ac_objext \
12364 conftest$ac_exeext conftest.$ac_ext
12365 LIBS=$ac_check_lib_save_LIBS
12367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12368 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12369 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12370 cat >>confdefs.h <<_ACEOF
12371 #define HAVE_LIBXMU 1
12372 _ACEOF
12374 LIBS="-lXmu $LIBS"
12378 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12382 LIBXMU=-lXmu
12383 case $opsys in
12384 ## These systems don't supply Xmu.
12385 hpux* | aix4-2 )
12386 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12388 mingw32 )
12389 LIBXMU=
12391 esac
12394 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12395 if test "${HAVE_X11}" = "yes"; then
12396 if test "${USE_X_TOOLKIT}" != "none"; then
12397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12398 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12399 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12400 $as_echo_n "(cached) " >&6
12401 else
12402 ac_check_lib_save_LIBS=$LIBS
12403 LIBS="-lXext $LIBS"
12404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12405 /* end confdefs.h. */
12407 /* Override any GCC internal prototype to avoid an error.
12408 Use char because int might match the return type of a GCC
12409 builtin and then its argument prototype would still apply. */
12410 #ifdef __cplusplus
12411 extern "C"
12412 #endif
12413 char XShapeQueryExtension ();
12415 main ()
12417 return XShapeQueryExtension ();
12419 return 0;
12421 _ACEOF
12422 if ac_fn_c_try_link "$LINENO"; then :
12423 ac_cv_lib_Xext_XShapeQueryExtension=yes
12424 else
12425 ac_cv_lib_Xext_XShapeQueryExtension=no
12427 rm -f core conftest.err conftest.$ac_objext \
12428 conftest$ac_exeext conftest.$ac_ext
12429 LIBS=$ac_check_lib_save_LIBS
12431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12432 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12433 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12434 cat >>confdefs.h <<_ACEOF
12435 #define HAVE_LIBXEXT 1
12436 _ACEOF
12438 LIBS="-lXext $LIBS"
12445 LIBXP=
12446 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12447 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12448 if test -d /usr/include/openmotif; then
12449 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12450 emacs_cv_openmotif=yes
12451 case "$canonical" in
12452 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12453 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12456 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12457 esac
12458 else
12459 emacs_cv_openmotif=no
12461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12462 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12463 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12464 $as_echo_n "(cached) " >&6
12465 else
12466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12467 /* end confdefs.h. */
12468 #include <Xm/Xm.h>
12470 main ()
12472 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12473 int x = 5;
12474 #else
12475 Motif version prior to 2.1.
12476 #endif
12478 return 0;
12480 _ACEOF
12481 if ac_fn_c_try_compile "$LINENO"; then :
12482 emacs_cv_motif_version_2_1=yes
12483 else
12484 emacs_cv_motif_version_2_1=no
12486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12489 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12490 if test $emacs_cv_motif_version_2_1 = yes; then
12491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12492 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12493 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12494 $as_echo_n "(cached) " >&6
12495 else
12496 ac_check_lib_save_LIBS=$LIBS
12497 LIBS="-lXp $LIBS"
12498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12499 /* end confdefs.h. */
12501 /* Override any GCC internal prototype to avoid an error.
12502 Use char because int might match the return type of a GCC
12503 builtin and then its argument prototype would still apply. */
12504 #ifdef __cplusplus
12505 extern "C"
12506 #endif
12507 char XpCreateContext ();
12509 main ()
12511 return XpCreateContext ();
12513 return 0;
12515 _ACEOF
12516 if ac_fn_c_try_link "$LINENO"; then :
12517 ac_cv_lib_Xp_XpCreateContext=yes
12518 else
12519 ac_cv_lib_Xp_XpCreateContext=no
12521 rm -f core conftest.err conftest.$ac_objext \
12522 conftest$ac_exeext conftest.$ac_ext
12523 LIBS=$ac_check_lib_save_LIBS
12525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12526 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12527 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12528 LIBXP=-lXp
12531 if test x$emacs_cv_openmotif = xyes; then
12532 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12534 else
12535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12536 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12537 if test "${emacs_cv_lesstif+set}" = set; then :
12538 $as_echo_n "(cached) " >&6
12539 else
12540 # We put this in CFLAGS temporarily to precede other -I options
12541 # that might be in CFLAGS temporarily.
12542 # We put this in CPPFLAGS where it precedes the other -I options.
12543 OLD_CPPFLAGS=$CPPFLAGS
12544 OLD_CFLAGS=$CFLAGS
12545 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12546 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12548 /* end confdefs.h. */
12549 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12551 main ()
12553 int x = 5;
12555 return 0;
12557 _ACEOF
12558 if ac_fn_c_try_compile "$LINENO"; then :
12559 emacs_cv_lesstif=yes
12560 else
12561 emacs_cv_lesstif=no
12563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12566 $as_echo "$emacs_cv_lesstif" >&6; }
12567 if test $emacs_cv_lesstif = yes; then
12568 # Make sure this -I option remains in CPPFLAGS after it is set
12569 # back to REAL_CPPFLAGS.
12570 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12571 # have those other -I options anyway. Ultimately, having this
12572 # directory ultimately in CPPFLAGS will be enough.
12573 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12574 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12575 else
12576 CFLAGS=$OLD_CFLAGS
12577 CPPFLAGS=$OLD_CPPFLAGS
12580 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12581 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12583 else
12584 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12591 USE_TOOLKIT_SCROLL_BARS=no
12592 if test "${with_toolkit_scroll_bars}" != "no"; then
12593 if test "${USE_X_TOOLKIT}" != "none"; then
12594 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12595 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12597 HAVE_XAW3D=no
12598 USE_TOOLKIT_SCROLL_BARS=yes
12599 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12600 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12602 USE_TOOLKIT_SCROLL_BARS=yes
12604 elif test "${HAVE_GTK}" = "yes"; then
12605 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12607 USE_TOOLKIT_SCROLL_BARS=yes
12608 elif test "${HAVE_NS}" = "yes"; then
12609 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12611 USE_TOOLKIT_SCROLL_BARS=yes
12612 elif test "${HAVE_W32}" = "yes"; then
12613 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12615 USE_TOOLKIT_SCROLL_BARS=yes
12619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12620 /* end confdefs.h. */
12622 #include <X11/Xlib.h>
12623 #include <X11/Xresource.h>
12625 main ()
12627 XIMProc callback;
12629 return 0;
12631 _ACEOF
12632 if ac_fn_c_try_compile "$LINENO"; then :
12633 HAVE_XIM=yes
12635 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12637 else
12638 HAVE_XIM=no
12640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12643 if test "${with_xim}" != "no"; then
12645 $as_echo "#define USE_XIM 1" >>confdefs.h
12650 if test "${HAVE_XIM}" != "no"; then
12651 late_CFLAGS=$CFLAGS
12652 if test "$GCC" = yes; then
12653 CFLAGS="$CFLAGS --pedantic-errors"
12655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12656 /* end confdefs.h. */
12658 #include <X11/Xlib.h>
12659 #include <X11/Xresource.h>
12661 main ()
12663 Display *display;
12664 XrmDatabase db;
12665 char *res_name;
12666 char *res_class;
12667 XIMProc callback;
12668 XPointer *client_data;
12669 #ifndef __GNUC__
12670 /* If we're not using GCC, it's probably not XFree86, and this is
12671 probably right, but we can't use something like --pedantic-errors. */
12672 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12673 char*, XIMProc, XPointer*);
12674 #endif
12675 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12676 client_data);
12678 return 0;
12680 _ACEOF
12681 if ac_fn_c_try_compile "$LINENO"; then :
12682 emacs_cv_arg6_star=yes
12684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12685 if test "$emacs_cv_arg6_star" = yes; then
12686 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12688 else
12689 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12692 CFLAGS=$late_CFLAGS
12695 ### Start of font-backend (under any platform) section.
12696 # (nothing here yet -- this is a placeholder)
12697 ### End of font-backend (under any platform) section.
12699 ### Start of font-backend (under X11) section.
12700 if test "${HAVE_X11}" = "yes"; then
12702 succeeded=no
12704 if test "$PKG_CONFIG" = "no" ; then
12705 HAVE_FC=no
12706 else
12707 PKG_CONFIG_MIN_VERSION=0.9.0
12708 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12710 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12712 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
12713 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
12714 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
12715 edit_cflags="
12716 s,///*,/,g
12717 s/^/ /
12718 s/ -I/ $isystem/g
12719 s/^ //
12721 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
12722 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12724 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12725 succeeded=yes
12726 else
12727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12728 $as_echo "no" >&6; }
12729 FONTCONFIG_CFLAGS=""
12730 FONTCONFIG_LIBS=""
12731 ## If we have a custom action on failure, don't print errors, but
12732 ## do set a variable so people can do so. Do it in a subshell
12733 ## to capture any diagnostics in invoking pkg-config.
12734 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
12740 else
12741 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12742 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12746 if test $succeeded = yes; then
12747 HAVE_FC=yes
12748 else
12749 HAVE_FC=no
12753 ## Use -lXft if available, unless `--with-xft=no'.
12754 HAVE_XFT=maybe
12755 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12756 with_xft="no";
12758 if test "x${with_xft}" != "xno"; then
12761 succeeded=no
12763 if test "$PKG_CONFIG" = "no" ; then
12764 HAVE_XFT=no
12765 else
12766 PKG_CONFIG_MIN_VERSION=0.9.0
12767 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12769 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12771 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
12772 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
12773 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
12774 edit_cflags="
12775 s,///*,/,g
12776 s/^/ /
12777 s/ -I/ $isystem/g
12778 s/^ //
12780 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
12781 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12783 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12784 succeeded=yes
12785 else
12786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12787 $as_echo "no" >&6; }
12788 XFT_CFLAGS=""
12789 XFT_LIBS=""
12790 ## If we have a custom action on failure, don't print errors, but
12791 ## do set a variable so people can do so. Do it in a subshell
12792 ## to capture any diagnostics in invoking pkg-config.
12793 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
12799 else
12800 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12801 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12805 if test $succeeded = yes; then
12807 else
12808 HAVE_XFT=no
12811 ## Because xftfont.c uses XRenderQueryExtension, we also
12812 ## need to link to -lXrender.
12813 HAVE_XRENDER=no
12814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12815 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12816 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12817 $as_echo_n "(cached) " >&6
12818 else
12819 ac_check_lib_save_LIBS=$LIBS
12820 LIBS="-lXrender $LIBS"
12821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12822 /* end confdefs.h. */
12824 /* Override any GCC internal prototype to avoid an error.
12825 Use char because int might match the return type of a GCC
12826 builtin and then its argument prototype would still apply. */
12827 #ifdef __cplusplus
12828 extern "C"
12829 #endif
12830 char XRenderQueryExtension ();
12832 main ()
12834 return XRenderQueryExtension ();
12836 return 0;
12838 _ACEOF
12839 if ac_fn_c_try_link "$LINENO"; then :
12840 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12841 else
12842 ac_cv_lib_Xrender_XRenderQueryExtension=no
12844 rm -f core conftest.err conftest.$ac_objext \
12845 conftest$ac_exeext conftest.$ac_ext
12846 LIBS=$ac_check_lib_save_LIBS
12848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12849 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12850 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12851 HAVE_XRENDER=yes
12854 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12855 OLD_CPPFLAGS="$CPPFLAGS"
12856 OLD_CFLAGS="$CFLAGS"
12857 OLD_LIBS="$LIBS"
12858 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12859 CFLAGS="$CFLAGS $XFT_CFLAGS"
12860 XFT_LIBS="-lXrender $XFT_LIBS"
12861 LIBS="$XFT_LIBS $LIBS"
12862 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12863 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12865 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12866 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12867 $as_echo_n "(cached) " >&6
12868 else
12869 ac_check_lib_save_LIBS=$LIBS
12870 LIBS="-lXft $XFT_LIBS $LIBS"
12871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12872 /* end confdefs.h. */
12874 /* Override any GCC internal prototype to avoid an error.
12875 Use char because int might match the return type of a GCC
12876 builtin and then its argument prototype would still apply. */
12877 #ifdef __cplusplus
12878 extern "C"
12879 #endif
12880 char XftFontOpen ();
12882 main ()
12884 return XftFontOpen ();
12886 return 0;
12888 _ACEOF
12889 if ac_fn_c_try_link "$LINENO"; then :
12890 ac_cv_lib_Xft_XftFontOpen=yes
12891 else
12892 ac_cv_lib_Xft_XftFontOpen=no
12894 rm -f core conftest.err conftest.$ac_objext \
12895 conftest$ac_exeext conftest.$ac_ext
12896 LIBS=$ac_check_lib_save_LIBS
12898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12899 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12900 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12901 HAVE_XFT=yes
12908 if test "${HAVE_XFT}" = "yes"; then
12910 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12913 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12914 else
12915 CPPFLAGS="$OLD_CPPFLAGS"
12916 CFLAGS="$OLD_CFLAGS"
12917 LIBS="$OLD_LIBS"
12918 fi # "${HAVE_XFT}" = "yes"
12919 fi # "$HAVE_XFT" != no
12920 fi # "x${with_xft}" != "xno"
12922 ## We used to allow building with FreeType and without Xft.
12923 ## However, the ftx font backend driver is not in good shape.
12924 if test "$HAVE_XFT" != "yes"; then
12925 HAVE_XFT=no
12926 HAVE_FREETYPE=no
12927 else
12929 succeeded=no
12931 if test "$PKG_CONFIG" = "no" ; then
12932 HAVE_FREETYPE=no
12933 else
12934 PKG_CONFIG_MIN_VERSION=0.9.0
12935 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12937 $as_echo_n "checking for freetype2... " >&6; }
12939 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
12940 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
12941 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
12942 edit_cflags="
12943 s,///*,/,g
12944 s/^/ /
12945 s/ -I/ $isystem/g
12946 s/^ //
12948 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
12949 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12951 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12952 succeeded=yes
12953 else
12954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12955 $as_echo "no" >&6; }
12956 FREETYPE_CFLAGS=""
12957 FREETYPE_LIBS=""
12958 ## If we have a custom action on failure, don't print errors, but
12959 ## do set a variable so people can do so. Do it in a subshell
12960 ## to capture any diagnostics in invoking pkg-config.
12961 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
12967 else
12968 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12969 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12973 if test $succeeded = yes; then
12974 HAVE_FREETYPE=yes
12975 else
12976 HAVE_FREETYPE=no
12980 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12983 HAVE_LIBOTF=no
12984 if test "${HAVE_FREETYPE}" = "yes"; then
12986 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12988 if test "${with_libotf}" != "no"; then
12990 succeeded=no
12992 if test "$PKG_CONFIG" = "no" ; then
12993 HAVE_LIBOTF=no
12994 else
12995 PKG_CONFIG_MIN_VERSION=0.9.0
12996 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12998 $as_echo_n "checking for libotf... " >&6; }
13000 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13001 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13002 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13003 edit_cflags="
13004 s,///*,/,g
13005 s/^/ /
13006 s/ -I/ $isystem/g
13007 s/^ //
13009 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13010 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13012 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13013 succeeded=yes
13014 else
13015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13016 $as_echo "no" >&6; }
13017 LIBOTF_CFLAGS=""
13018 LIBOTF_LIBS=""
13019 ## If we have a custom action on failure, don't print errors, but
13020 ## do set a variable so people can do so. Do it in a subshell
13021 ## to capture any diagnostics in invoking pkg-config.
13022 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13028 else
13029 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13030 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13034 if test $succeeded = yes; then
13035 HAVE_LIBOTF=yes
13036 else
13037 HAVE_LIBOTF=no
13040 if test "$HAVE_LIBOTF" = "yes"; then
13042 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13045 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13046 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13047 $as_echo_n "(cached) " >&6
13048 else
13049 ac_check_lib_save_LIBS=$LIBS
13050 LIBS="-lotf $LIBS"
13051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13052 /* end confdefs.h. */
13054 /* Override any GCC internal prototype to avoid an error.
13055 Use char because int might match the return type of a GCC
13056 builtin and then its argument prototype would still apply. */
13057 #ifdef __cplusplus
13058 extern "C"
13059 #endif
13060 char OTF_get_variation_glyphs ();
13062 main ()
13064 return OTF_get_variation_glyphs ();
13066 return 0;
13068 _ACEOF
13069 if ac_fn_c_try_link "$LINENO"; then :
13070 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13071 else
13072 ac_cv_lib_otf_OTF_get_variation_glyphs=no
13074 rm -f core conftest.err conftest.$ac_objext \
13075 conftest$ac_exeext conftest.$ac_ext
13076 LIBS=$ac_check_lib_save_LIBS
13078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
13079 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13080 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13081 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13082 else
13083 HAVE_OTF_GET_VARIATION_GLYPHS=no
13086 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13088 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13095 HAVE_M17N_FLT=no
13096 if test "${HAVE_LIBOTF}" = yes; then
13097 if test "${with_m17n_flt}" != "no"; then
13099 succeeded=no
13101 if test "$PKG_CONFIG" = "no" ; then
13102 HAVE_M17N_FLT=no
13103 else
13104 PKG_CONFIG_MIN_VERSION=0.9.0
13105 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13107 $as_echo_n "checking for m17n-flt... " >&6; }
13109 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13110 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13111 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13112 edit_cflags="
13113 s,///*,/,g
13114 s/^/ /
13115 s/ -I/ $isystem/g
13116 s/^ //
13118 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13119 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13121 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13122 succeeded=yes
13123 else
13124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13125 $as_echo "no" >&6; }
13126 M17N_FLT_CFLAGS=""
13127 M17N_FLT_LIBS=""
13128 ## If we have a custom action on failure, don't print errors, but
13129 ## do set a variable so people can do so. Do it in a subshell
13130 ## to capture any diagnostics in invoking pkg-config.
13131 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13137 else
13138 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13139 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13143 if test $succeeded = yes; then
13144 HAVE_M17N_FLT=yes
13145 else
13146 HAVE_M17N_FLT=no
13149 if test "$HAVE_M17N_FLT" = "yes"; then
13151 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13156 else
13157 HAVE_XFT=no
13158 HAVE_FREETYPE=no
13159 HAVE_LIBOTF=no
13160 HAVE_M17N_FLT=no
13163 ### End of font-backend (under X11) section.
13174 ### Use -lXpm if available, unless `--with-xpm=no'.
13175 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13176 HAVE_XPM=no
13177 LIBXPM=
13178 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13179 if test "${with_xpm}" != "no"; then
13180 SAVE_CPPFLAGS="$CPPFLAGS"
13181 SAVE_LDFLAGS="$LDFLAGS"
13182 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13183 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13184 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13185 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13187 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13188 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13189 $as_echo_n "(cached) " >&6
13190 else
13191 ac_check_lib_save_LIBS=$LIBS
13192 LIBS="-lXpm $LIBS"
13193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13194 /* end confdefs.h. */
13196 /* Override any GCC internal prototype to avoid an error.
13197 Use char because int might match the return type of a GCC
13198 builtin and then its argument prototype would still apply. */
13199 #ifdef __cplusplus
13200 extern "C"
13201 #endif
13202 char XpmReadFileToImage ();
13204 main ()
13206 return XpmReadFileToImage ();
13208 return 0;
13210 _ACEOF
13211 if ac_fn_c_try_link "$LINENO"; then :
13212 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13213 else
13214 ac_cv_lib_Xpm_XpmReadFileToImage=no
13216 rm -f core conftest.err conftest.$ac_objext \
13217 conftest$ac_exeext conftest.$ac_ext
13218 LIBS=$ac_check_lib_save_LIBS
13220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13221 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13222 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13223 HAVE_XPM=yes
13229 if test "${HAVE_XPM}" = "yes"; then
13230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13231 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13233 /* end confdefs.h. */
13234 #include "X11/xpm.h"
13235 #ifndef XpmReturnAllocPixels
13236 no_return_alloc_pixels
13237 #endif
13239 _ACEOF
13240 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13241 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13242 HAVE_XPM=no
13243 else
13244 HAVE_XPM=yes
13246 rm -f conftest*
13249 if test "${HAVE_XPM}" = "yes"; then
13250 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13252 $as_echo "yes" >&6; }
13253 else
13254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13255 $as_echo "no" >&6; }
13256 CPPFLAGS="$SAVE_CPPFLAGS"
13257 LDFLAGS="$SAVE_LDFLAGS"
13262 if test "${HAVE_XPM}" = "yes"; then
13264 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13266 LIBXPM=-lXpm
13270 if test "${HAVE_X11}" = "yes"; then
13271 if test "${with_xpm}" != "no"; then
13272 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13273 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13275 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13276 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13277 $as_echo_n "(cached) " >&6
13278 else
13279 ac_check_lib_save_LIBS=$LIBS
13280 LIBS="-lXpm -lX11 $LIBS"
13281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13282 /* end confdefs.h. */
13284 /* Override any GCC internal prototype to avoid an error.
13285 Use char because int might match the return type of a GCC
13286 builtin and then its argument prototype would still apply. */
13287 #ifdef __cplusplus
13288 extern "C"
13289 #endif
13290 char XpmReadFileToPixmap ();
13292 main ()
13294 return XpmReadFileToPixmap ();
13296 return 0;
13298 _ACEOF
13299 if ac_fn_c_try_link "$LINENO"; then :
13300 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13301 else
13302 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13304 rm -f core conftest.err conftest.$ac_objext \
13305 conftest$ac_exeext conftest.$ac_ext
13306 LIBS=$ac_check_lib_save_LIBS
13308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13309 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13310 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13311 HAVE_XPM=yes
13317 if test "${HAVE_XPM}" = "yes"; then
13318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13319 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13321 /* end confdefs.h. */
13322 #include "X11/xpm.h"
13323 #ifndef XpmReturnAllocPixels
13324 no_return_alloc_pixels
13325 #endif
13327 _ACEOF
13328 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13329 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13330 HAVE_XPM=no
13331 else
13332 HAVE_XPM=yes
13334 rm -f conftest*
13337 if test "${HAVE_XPM}" = "yes"; then
13338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13339 $as_echo "yes" >&6; }
13340 else
13341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13342 $as_echo "no" >&6; }
13347 if test "${HAVE_XPM}" = "yes"; then
13349 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13351 LIBXPM=-lXpm
13355 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13356 ### slightly different requirements wrt image libraries (it doesn't
13357 ### use -lXpm because it loads the xpm shared library dynamically at
13358 ### run time).
13359 if test "${opsys}" = "mingw32"; then
13360 if test "${with_xpm}" != "no"; then
13361 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13362 #define FOR_MSW 1
13364 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13365 HAVE_XPM=yes
13366 else
13367 HAVE_XPM=no
13373 if test "${HAVE_XPM}" = "yes"; then
13375 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13382 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13383 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13384 HAVE_JPEG=no
13385 LIBJPEG=
13386 if test "${opsys}" = "mingw32"; then
13387 if test "${with_jpeg}" != "no"; then
13388 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13389 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13390 HAVE_JPEG=yes
13391 else
13392 HAVE_JPEG=no
13397 if test "${HAVE_JPEG}" = "yes"; then
13398 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13401 /* end confdefs.h. */
13402 #include <jpeglib.h>
13403 version=JPEG_LIB_VERSION
13405 _ACEOF
13406 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13407 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13408 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13410 else
13411 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13412 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13413 HAVE_JPEG=no
13415 rm -f conftest*
13418 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13419 if test "${with_jpeg}" != "no"; then
13420 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13421 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13423 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13424 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13425 $as_echo_n "(cached) " >&6
13426 else
13427 ac_check_lib_save_LIBS=$LIBS
13428 LIBS="-ljpeg $LIBS"
13429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13430 /* end confdefs.h. */
13432 /* Override any GCC internal prototype to avoid an error.
13433 Use char because int might match the return type of a GCC
13434 builtin and then its argument prototype would still apply. */
13435 #ifdef __cplusplus
13436 extern "C"
13437 #endif
13438 char jpeg_destroy_compress ();
13440 main ()
13442 return jpeg_destroy_compress ();
13444 return 0;
13446 _ACEOF
13447 if ac_fn_c_try_link "$LINENO"; then :
13448 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13449 else
13450 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13452 rm -f core conftest.err conftest.$ac_objext \
13453 conftest$ac_exeext conftest.$ac_ext
13454 LIBS=$ac_check_lib_save_LIBS
13456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13457 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13458 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13459 HAVE_JPEG=yes
13467 if test "${HAVE_JPEG}" = "yes"; then
13468 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13471 /* end confdefs.h. */
13472 #include <jpeglib.h>
13473 version=JPEG_LIB_VERSION
13475 _ACEOF
13476 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13477 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13478 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13480 else
13481 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13482 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13483 HAVE_JPEG=no
13485 rm -f conftest*
13488 if test "${HAVE_JPEG}" = "yes"; then
13489 LIBJPEG=-ljpeg
13494 ### Use -lpng if available, unless `--with-png=no'.
13495 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13496 HAVE_PNG=no
13497 LIBPNG=
13498 if test "${opsys}" = "mingw32"; then
13499 if test "${with_png}" != "no"; then
13500 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13501 if test "x$ac_cv_header_png_h" = x""yes; then :
13502 HAVE_PNG=yes
13503 else
13504 HAVE_PNG=no
13509 if test "${HAVE_PNG}" = "yes"; then
13511 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13514 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13515 # include <libpng/png.h>
13516 #else
13517 # include <png.h>
13518 #endif
13521 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13523 else
13525 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13530 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13531 if test "${with_png}" != "no"; then
13532 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13533 # in /usr/include/libpng.
13534 for ac_header in png.h libpng/png.h
13535 do :
13536 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13537 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13538 eval as_val=\$$as_ac_Header
13539 if test "x$as_val" = x""yes; then :
13540 cat >>confdefs.h <<_ACEOF
13541 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13542 _ACEOF
13543 break
13546 done
13548 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13550 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13551 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13552 $as_echo_n "(cached) " >&6
13553 else
13554 ac_check_lib_save_LIBS=$LIBS
13555 LIBS="-lpng -lz -lm $LIBS"
13556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13557 /* end confdefs.h. */
13559 /* Override any GCC internal prototype to avoid an error.
13560 Use char because int might match the return type of a GCC
13561 builtin and then its argument prototype would still apply. */
13562 #ifdef __cplusplus
13563 extern "C"
13564 #endif
13565 char png_get_channels ();
13567 main ()
13569 return png_get_channels ();
13571 return 0;
13573 _ACEOF
13574 if ac_fn_c_try_link "$LINENO"; then :
13575 ac_cv_lib_png_png_get_channels=yes
13576 else
13577 ac_cv_lib_png_png_get_channels=no
13579 rm -f core conftest.err conftest.$ac_objext \
13580 conftest$ac_exeext conftest.$ac_ext
13581 LIBS=$ac_check_lib_save_LIBS
13583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13584 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13585 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13586 HAVE_PNG=yes
13592 if test "${HAVE_PNG}" = "yes"; then
13594 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13596 LIBPNG="-lpng -lz -lm"
13598 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13599 # include <libpng/png.h>
13600 #else
13601 # include <png.h>
13602 #endif
13605 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13607 else
13609 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13617 ### Use -ltiff if available, unless `--with-tiff=no'.
13618 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
13619 HAVE_TIFF=no
13620 LIBTIFF=
13621 if test "${opsys}" = "mingw32"; then
13622 if test "${with_tiff}" != "no"; then
13623 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13624 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13625 HAVE_TIFF=yes
13626 else
13627 HAVE_TIFF=no
13632 if test "${HAVE_TIFF}" = "yes"; then
13634 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13637 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13638 if test "${with_tiff}" != "no"; then
13639 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13640 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13641 tifflibs="-lz -lm"
13642 # At least one tiff package requires the jpeg library.
13643 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13645 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
13646 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
13647 $as_echo_n "(cached) " >&6
13648 else
13649 ac_check_lib_save_LIBS=$LIBS
13650 LIBS="-ltiff $tifflibs $LIBS"
13651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13652 /* end confdefs.h. */
13654 /* Override any GCC internal prototype to avoid an error.
13655 Use char because int might match the return type of a GCC
13656 builtin and then its argument prototype would still apply. */
13657 #ifdef __cplusplus
13658 extern "C"
13659 #endif
13660 char TIFFGetVersion ();
13662 main ()
13664 return TIFFGetVersion ();
13666 return 0;
13668 _ACEOF
13669 if ac_fn_c_try_link "$LINENO"; then :
13670 ac_cv_lib_tiff_TIFFGetVersion=yes
13671 else
13672 ac_cv_lib_tiff_TIFFGetVersion=no
13674 rm -f core conftest.err conftest.$ac_objext \
13675 conftest$ac_exeext conftest.$ac_ext
13676 LIBS=$ac_check_lib_save_LIBS
13678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13679 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13680 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13681 HAVE_TIFF=yes
13689 if test "${HAVE_TIFF}" = "yes"; then
13691 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13693 LIBTIFF=-ltiff
13698 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13699 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
13700 HAVE_GIF=no
13701 LIBGIF=
13702 if test "${opsys}" = "mingw32"; then
13703 if test "${with_gif}" != "no"; then
13704 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13705 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13706 HAVE_GIF=yes
13707 else
13708 HAVE_GIF=no
13713 if test "${HAVE_GIF}" = "yes"; then
13715 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13718 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
13719 || test "${HAVE_W32}" = "yes"; then
13720 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13721 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13722 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13723 # Earlier versions can crash Emacs.
13724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13725 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13726 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13727 $as_echo_n "(cached) " >&6
13728 else
13729 ac_check_lib_save_LIBS=$LIBS
13730 LIBS="-lgif $LIBS"
13731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13732 /* end confdefs.h. */
13734 /* Override any GCC internal prototype to avoid an error.
13735 Use char because int might match the return type of a GCC
13736 builtin and then its argument prototype would still apply. */
13737 #ifdef __cplusplus
13738 extern "C"
13739 #endif
13740 char EGifPutExtensionLast ();
13742 main ()
13744 return EGifPutExtensionLast ();
13746 return 0;
13748 _ACEOF
13749 if ac_fn_c_try_link "$LINENO"; then :
13750 ac_cv_lib_gif_EGifPutExtensionLast=yes
13751 else
13752 ac_cv_lib_gif_EGifPutExtensionLast=no
13754 rm -f core conftest.err conftest.$ac_objext \
13755 conftest$ac_exeext conftest.$ac_ext
13756 LIBS=$ac_check_lib_save_LIBS
13758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13759 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13760 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13761 HAVE_GIF=yes
13762 else
13763 HAVE_GIF=maybe
13770 if test "$HAVE_GIF" = yes; then
13771 LIBGIF=-lgif
13772 elif test "$HAVE_GIF" = maybe; then
13773 # If gif_lib.h but no libgif, try libungif.
13774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13775 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13776 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13777 $as_echo_n "(cached) " >&6
13778 else
13779 ac_check_lib_save_LIBS=$LIBS
13780 LIBS="-lungif $LIBS"
13781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13782 /* end confdefs.h. */
13784 /* Override any GCC internal prototype to avoid an error.
13785 Use char because int might match the return type of a GCC
13786 builtin and then its argument prototype would still apply. */
13787 #ifdef __cplusplus
13788 extern "C"
13789 #endif
13790 char EGifPutExtensionLast ();
13792 main ()
13794 return EGifPutExtensionLast ();
13796 return 0;
13798 _ACEOF
13799 if ac_fn_c_try_link "$LINENO"; then :
13800 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13801 else
13802 ac_cv_lib_ungif_EGifPutExtensionLast=no
13804 rm -f core conftest.err conftest.$ac_objext \
13805 conftest$ac_exeext conftest.$ac_ext
13806 LIBS=$ac_check_lib_save_LIBS
13808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13809 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13810 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13811 HAVE_GIF=yes
13812 else
13813 HAVE_GIF=no
13816 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13819 if test "${HAVE_GIF}" = "yes"; then
13821 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13827 if test "${HAVE_X11}" = "yes"; then
13828 MISSING=""
13829 WITH_NO=""
13830 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13831 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13832 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13833 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13834 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13835 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13836 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13837 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13838 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13839 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13841 if test "X${MISSING}" != X; then
13842 as_fn_error "The following required libraries were not found:
13843 $MISSING
13844 Maybe some development libraries/packages are missing?
13845 If you don't want to link with them give
13846 $WITH_NO
13847 as options to configure" "$LINENO" 5
13851 ### Use -lgpm if available, unless `--with-gpm=no'.
13852 HAVE_GPM=no
13853 LIBGPM=
13854 if test "${with_gpm}" != "no"; then
13855 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13856 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13858 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13859 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13860 $as_echo_n "(cached) " >&6
13861 else
13862 ac_check_lib_save_LIBS=$LIBS
13863 LIBS="-lgpm $LIBS"
13864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13865 /* end confdefs.h. */
13867 /* Override any GCC internal prototype to avoid an error.
13868 Use char because int might match the return type of a GCC
13869 builtin and then its argument prototype would still apply. */
13870 #ifdef __cplusplus
13871 extern "C"
13872 #endif
13873 char Gpm_Open ();
13875 main ()
13877 return Gpm_Open ();
13879 return 0;
13881 _ACEOF
13882 if ac_fn_c_try_link "$LINENO"; then :
13883 ac_cv_lib_gpm_Gpm_Open=yes
13884 else
13885 ac_cv_lib_gpm_Gpm_Open=no
13887 rm -f core conftest.err conftest.$ac_objext \
13888 conftest$ac_exeext conftest.$ac_ext
13889 LIBS=$ac_check_lib_save_LIBS
13891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13892 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13893 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13894 HAVE_GPM=yes
13901 if test "${HAVE_GPM}" = "yes"; then
13903 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13905 LIBGPM=-lgpm
13914 GNUSTEP_CFLAGS=
13915 ### Use NeXTstep API to implement GUI.
13916 if test "${HAVE_NS}" = "yes"; then
13918 $as_echo "#define HAVE_NS 1" >>confdefs.h
13920 if test "${NS_IMPL_COCOA}" = "yes"; then
13922 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13925 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13927 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13929 # See also .m.o rule in Makefile.in */
13930 # FIXME: are all these flags really needed? Document here why. */
13931 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
13932 ## Extra CFLAGS applied to src/*.m files.
13933 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"
13935 # We also have mouse menus.
13936 HAVE_MENUS=yes
13937 OTHER_FILES=ns-app
13940 if test "${HAVE_W32}" = "yes"; then
13941 HAVE_MENUS=yes
13944 ### Use session management (-lSM -lICE) if available
13945 HAVE_X_SM=no
13946 LIBXSM=
13947 if test "${HAVE_X11}" = "yes"; then
13948 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13949 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13951 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13952 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13953 $as_echo_n "(cached) " >&6
13954 else
13955 ac_check_lib_save_LIBS=$LIBS
13956 LIBS="-lSM -lICE $LIBS"
13957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13958 /* end confdefs.h. */
13960 /* Override any GCC internal prototype to avoid an error.
13961 Use char because int might match the return type of a GCC
13962 builtin and then its argument prototype would still apply. */
13963 #ifdef __cplusplus
13964 extern "C"
13965 #endif
13966 char SmcOpenConnection ();
13968 main ()
13970 return SmcOpenConnection ();
13972 return 0;
13974 _ACEOF
13975 if ac_fn_c_try_link "$LINENO"; then :
13976 ac_cv_lib_SM_SmcOpenConnection=yes
13977 else
13978 ac_cv_lib_SM_SmcOpenConnection=no
13980 rm -f core conftest.err conftest.$ac_objext \
13981 conftest$ac_exeext conftest.$ac_ext
13982 LIBS=$ac_check_lib_save_LIBS
13984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13985 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13986 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13987 HAVE_X_SM=yes
13994 if test "${HAVE_X_SM}" = "yes"; then
13996 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13998 LIBXSM="-lSM -lICE"
13999 case "$LIBS" in
14000 *-lSM*) ;;
14001 *) LIBS="$LIBXSM $LIBS" ;;
14002 esac
14007 ### Use XRandr (-lXrandr) if available
14008 HAVE_XRANDR=no
14009 if test "${HAVE_X11}" = "yes"; then
14010 XRANDR_REQUIRED=1.2.2
14011 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14013 succeeded=no
14015 if test "$PKG_CONFIG" = "no" ; then
14016 HAVE_XRANDR=no
14017 else
14018 PKG_CONFIG_MIN_VERSION=0.9.0
14019 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14021 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14023 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14024 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14025 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14026 edit_cflags="
14027 s,///*,/,g
14028 s/^/ /
14029 s/ -I/ $isystem/g
14030 s/^ //
14032 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14033 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14035 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14036 succeeded=yes
14037 else
14038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14039 $as_echo "no" >&6; }
14040 XRANDR_CFLAGS=""
14041 XRANDR_LIBS=""
14042 ## If we have a custom action on failure, don't print errors, but
14043 ## do set a variable so people can do so. Do it in a subshell
14044 ## to capture any diagnostics in invoking pkg-config.
14045 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14051 else
14052 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14053 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14057 if test $succeeded = yes; then
14058 HAVE_XRANDR=yes
14059 else
14060 HAVE_XRANDR=no
14063 if test $HAVE_XRANDR = no; then
14064 # Test old way in case pkg-config doesn't have it (older machines).
14065 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14066 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14068 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14069 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14070 $as_echo_n "(cached) " >&6
14071 else
14072 ac_check_lib_save_LIBS=$LIBS
14073 LIBS="-lXrandr $LIBS"
14074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14075 /* end confdefs.h. */
14077 /* Override any GCC internal prototype to avoid an error.
14078 Use char because int might match the return type of a GCC
14079 builtin and then its argument prototype would still apply. */
14080 #ifdef __cplusplus
14081 extern "C"
14082 #endif
14083 char XRRGetScreenResources ();
14085 main ()
14087 return XRRGetScreenResources ();
14089 return 0;
14091 _ACEOF
14092 if ac_fn_c_try_link "$LINENO"; then :
14093 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14094 else
14095 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14097 rm -f core conftest.err conftest.$ac_objext \
14098 conftest$ac_exeext conftest.$ac_ext
14099 LIBS=$ac_check_lib_save_LIBS
14101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14102 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14103 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14104 HAVE_XRANDR=yes
14110 if test $HAVE_XRANDR = yes; then
14111 XRANDR_LIBS=-lXrandr
14115 if test $HAVE_XRANDR = yes; then
14116 SAVE_CFLAGS="$CFLAGS"
14117 SAVE_LIBS="$LIBS"
14118 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14119 LIBS="$XRANDR_LIBS $LIBS"
14120 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14121 do :
14122 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14123 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14124 eval as_val=\$$as_ac_var
14125 if test "x$as_val" = x""yes; then :
14126 cat >>confdefs.h <<_ACEOF
14127 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14128 _ACEOF
14131 done
14133 CFLAGS="$SAVE_CFLAGS"
14134 LIBS="$SAVE_LIBS"
14137 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14142 ### Use Xinerama (-lXinerama) if available
14143 HAVE_XINERAMA=no
14144 if test "${HAVE_X11}" = "yes"; then
14145 XINERAMA_REQUIRED=1.0.2
14146 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14148 succeeded=no
14150 if test "$PKG_CONFIG" = "no" ; then
14151 HAVE_XINERAMA=no
14152 else
14153 PKG_CONFIG_MIN_VERSION=0.9.0
14154 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14156 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14158 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14159 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14160 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14161 edit_cflags="
14162 s,///*,/,g
14163 s/^/ /
14164 s/ -I/ $isystem/g
14165 s/^ //
14167 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14168 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14170 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14171 succeeded=yes
14172 else
14173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14174 $as_echo "no" >&6; }
14175 XINERAMA_CFLAGS=""
14176 XINERAMA_LIBS=""
14177 ## If we have a custom action on failure, don't print errors, but
14178 ## do set a variable so people can do so. Do it in a subshell
14179 ## to capture any diagnostics in invoking pkg-config.
14180 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14186 else
14187 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14188 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14192 if test $succeeded = yes; then
14193 HAVE_XINERAMA=yes
14194 else
14195 HAVE_XINERAMA=no
14198 if test $HAVE_XINERAMA = no; then
14199 # Test old way in case pkg-config doesn't have it (older machines).
14200 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14201 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14203 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14204 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14205 $as_echo_n "(cached) " >&6
14206 else
14207 ac_check_lib_save_LIBS=$LIBS
14208 LIBS="-lXinerama $LIBS"
14209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14210 /* end confdefs.h. */
14212 /* Override any GCC internal prototype to avoid an error.
14213 Use char because int might match the return type of a GCC
14214 builtin and then its argument prototype would still apply. */
14215 #ifdef __cplusplus
14216 extern "C"
14217 #endif
14218 char XineramaQueryExtension ();
14220 main ()
14222 return XineramaQueryExtension ();
14224 return 0;
14226 _ACEOF
14227 if ac_fn_c_try_link "$LINENO"; then :
14228 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14229 else
14230 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14232 rm -f core conftest.err conftest.$ac_objext \
14233 conftest$ac_exeext conftest.$ac_ext
14234 LIBS=$ac_check_lib_save_LIBS
14236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14237 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14238 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14239 HAVE_XINERAMA=yes
14245 if test $HAVE_XINERAMA = yes; then
14246 XINERAMA_LIBS=-lXinerama
14250 if test $HAVE_XINERAMA = yes; then
14252 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14258 ### Use libxml (-lxml2) if available
14259 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14260 HAVE_LIBXML2=no
14261 if test "${with_xml2}" != "no"; then
14262 ### I'm not sure what the version number should be, so I just guessed.
14264 succeeded=no
14266 if test "$PKG_CONFIG" = "no" ; then
14267 HAVE_LIBXML2=no
14268 else
14269 PKG_CONFIG_MIN_VERSION=0.9.0
14270 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14272 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14274 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14275 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14276 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14277 edit_cflags="
14278 s,///*,/,g
14279 s/^/ /
14280 s/ -I/ $isystem/g
14281 s/^ //
14283 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14284 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14286 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14287 succeeded=yes
14288 else
14289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14290 $as_echo "no" >&6; }
14291 LIBXML2_CFLAGS=""
14292 LIBXML2_LIBS=""
14293 ## If we have a custom action on failure, don't print errors, but
14294 ## do set a variable so people can do so. Do it in a subshell
14295 ## to capture any diagnostics in invoking pkg-config.
14296 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14302 else
14303 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14304 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14308 if test $succeeded = yes; then
14309 HAVE_LIBXML2=yes
14310 else
14311 HAVE_LIBXML2=no
14314 if test "${HAVE_LIBXML2}" = "yes"; then
14315 if test "${opsys}" != "mingw32"; then
14316 LIBS="$LIBXML2_LIBS $LIBS"
14317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14318 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14319 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14320 $as_echo_n "(cached) " >&6
14321 else
14322 ac_check_lib_save_LIBS=$LIBS
14323 LIBS="-lxml2 $LIBS"
14324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14325 /* end confdefs.h. */
14327 /* Override any GCC internal prototype to avoid an error.
14328 Use char because int might match the return type of a GCC
14329 builtin and then its argument prototype would still apply. */
14330 #ifdef __cplusplus
14331 extern "C"
14332 #endif
14333 char htmlReadMemory ();
14335 main ()
14337 return htmlReadMemory ();
14339 return 0;
14341 _ACEOF
14342 if ac_fn_c_try_link "$LINENO"; then :
14343 ac_cv_lib_xml2_htmlReadMemory=yes
14344 else
14345 ac_cv_lib_xml2_htmlReadMemory=no
14347 rm -f core conftest.err conftest.$ac_objext \
14348 conftest$ac_exeext conftest.$ac_ext
14349 LIBS=$ac_check_lib_save_LIBS
14351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14352 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14353 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14354 HAVE_LIBXML2=yes
14355 else
14356 HAVE_LIBXML2=no
14359 else
14360 LIBXML2_LIBS=""
14362 if test "${HAVE_LIBXML2}" = "yes"; then
14364 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14366 else
14367 LIBXML2_LIBS=""
14368 LIBXML2_CFLAGS=""
14375 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14376 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14377 if test "${opsys}" = "mingw32"; then
14378 emacs_cv_netdb_declares_h_errno=yes
14380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14381 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14382 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14383 $as_echo_n "(cached) " >&6
14384 else
14385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14386 /* end confdefs.h. */
14387 #include <netdb.h>
14389 main ()
14391 return h_errno;
14393 return 0;
14395 _ACEOF
14396 if ac_fn_c_try_link "$LINENO"; then :
14397 emacs_cv_netdb_declares_h_errno=yes
14398 else
14399 emacs_cv_netdb_declares_h_errno=no
14401 rm -f core conftest.err conftest.$ac_objext \
14402 conftest$ac_exeext conftest.$ac_ext
14404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14405 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14406 if test $emacs_cv_netdb_declares_h_errno = yes; then
14408 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14412 # sqrt and other floating-point functions such as fmod and frexp
14413 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14414 if test "${opsys}" != "mingw32"; then
14415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14416 $as_echo_n "checking for sqrt in -lm... " >&6; }
14417 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14418 $as_echo_n "(cached) " >&6
14419 else
14420 ac_check_lib_save_LIBS=$LIBS
14421 LIBS="-lm $LIBS"
14422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14423 /* end confdefs.h. */
14425 /* Override any GCC internal prototype to avoid an error.
14426 Use char because int might match the return type of a GCC
14427 builtin and then its argument prototype would still apply. */
14428 #ifdef __cplusplus
14429 extern "C"
14430 #endif
14431 char sqrt ();
14433 main ()
14435 return sqrt ();
14437 return 0;
14439 _ACEOF
14440 if ac_fn_c_try_link "$LINENO"; then :
14441 ac_cv_lib_m_sqrt=yes
14442 else
14443 ac_cv_lib_m_sqrt=no
14445 rm -f core conftest.err conftest.$ac_objext \
14446 conftest$ac_exeext conftest.$ac_ext
14447 LIBS=$ac_check_lib_save_LIBS
14449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14450 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14451 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14452 cat >>confdefs.h <<_ACEOF
14453 #define HAVE_LIBM 1
14454 _ACEOF
14456 LIBS="-lm $LIBS"
14462 # Check for mail-locking functions in a "mail" library. Probably this should
14463 # have the same check as for liblockfile below.
14464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14465 $as_echo_n "checking for maillock in -lmail... " >&6; }
14466 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14467 $as_echo_n "(cached) " >&6
14468 else
14469 ac_check_lib_save_LIBS=$LIBS
14470 LIBS="-lmail $LIBS"
14471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14472 /* end confdefs.h. */
14474 /* Override any GCC internal prototype to avoid an error.
14475 Use char because int might match the return type of a GCC
14476 builtin and then its argument prototype would still apply. */
14477 #ifdef __cplusplus
14478 extern "C"
14479 #endif
14480 char maillock ();
14482 main ()
14484 return maillock ();
14486 return 0;
14488 _ACEOF
14489 if ac_fn_c_try_link "$LINENO"; then :
14490 ac_cv_lib_mail_maillock=yes
14491 else
14492 ac_cv_lib_mail_maillock=no
14494 rm -f core conftest.err conftest.$ac_objext \
14495 conftest$ac_exeext conftest.$ac_ext
14496 LIBS=$ac_check_lib_save_LIBS
14498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14499 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14500 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14501 have_mail=yes
14502 else
14503 have_mail=no
14506 if test $have_mail = yes; then
14507 LIBS_MAIL=-lmail
14508 LIBS="$LIBS_MAIL $LIBS"
14510 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14512 else
14513 LIBS_MAIL=
14515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14516 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14517 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14518 $as_echo_n "(cached) " >&6
14519 else
14520 ac_check_lib_save_LIBS=$LIBS
14521 LIBS="-llockfile $LIBS"
14522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14523 /* end confdefs.h. */
14525 /* Override any GCC internal prototype to avoid an error.
14526 Use char because int might match the return type of a GCC
14527 builtin and then its argument prototype would still apply. */
14528 #ifdef __cplusplus
14529 extern "C"
14530 #endif
14531 char maillock ();
14533 main ()
14535 return maillock ();
14537 return 0;
14539 _ACEOF
14540 if ac_fn_c_try_link "$LINENO"; then :
14541 ac_cv_lib_lockfile_maillock=yes
14542 else
14543 ac_cv_lib_lockfile_maillock=no
14545 rm -f core conftest.err conftest.$ac_objext \
14546 conftest$ac_exeext conftest.$ac_ext
14547 LIBS=$ac_check_lib_save_LIBS
14549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
14550 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
14551 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
14552 have_lockfile=yes
14553 else
14554 have_lockfile=no
14557 if test $have_lockfile = yes; then
14558 LIBS_MAIL=-llockfile
14559 LIBS="$LIBS_MAIL $LIBS"
14561 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
14563 else
14564 # If we have the shared liblockfile, assume we must use it for mail
14565 # locking (e.g. Debian). If we couldn't link against liblockfile
14566 # (no liblockfile.a installed), ensure that we don't need to.
14567 # Extract the first word of "liblockfile.so", so it can be a program name with args.
14568 set dummy liblockfile.so; ac_word=$2
14569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14570 $as_echo_n "checking for $ac_word... " >&6; }
14571 if test "${ac_cv_prog_liblockfile+set}" = set; then :
14572 $as_echo_n "(cached) " >&6
14573 else
14574 if test -n "$liblockfile"; then
14575 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
14576 else
14577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14578 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
14579 for as_dir in $as_dummy
14581 IFS=$as_save_IFS
14582 test -z "$as_dir" && as_dir=.
14583 for ac_exec_ext in '' $ac_executable_extensions; do
14584 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14585 ac_cv_prog_liblockfile="yes"
14586 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14587 break 2
14589 done
14590 done
14591 IFS=$as_save_IFS
14593 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
14596 liblockfile=$ac_cv_prog_liblockfile
14597 if test -n "$liblockfile"; then
14598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
14599 $as_echo "$liblockfile" >&6; }
14600 else
14601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14602 $as_echo "no" >&6; }
14606 if test $ac_cv_prog_liblockfile = yes; then
14607 as_fn_error "Shared liblockfile found but can't link against it.
14608 This probably means that movemail could lose mail.
14609 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
14617 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
14618 ## interlock access to the mail spool. The alternative is a lock file named
14619 ## /usr/spool/mail/$USER.lock.
14620 mail_lock=no
14621 case "$opsys" in
14622 aix4-2) mail_lock="lockf" ;;
14624 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
14626 ## On GNU/Linux systems, both methods are used by various mail programs.
14627 ## I assume most people are using newer mailers that have heard of flock.
14628 ## Change this if you need to.
14629 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
14630 ## configure gets the right answers, and that means *NOT* using flock.
14631 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
14632 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
14633 ## Debian maintainer hasn't provided a clean fix for Emacs.
14634 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
14635 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
14636 ## correct logic. -- fx
14637 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
14638 ## liblockfile is a Free Software replacement for libmail, used on
14639 ## Debian systems and elsewhere. -rfr.
14640 gnu-*)
14641 mail_lock="flock"
14642 if test $have_mail = yes || test $have_lockfile = yes; then
14643 test $ac_cv_header_maillock_h = yes && mail_lock=no
14647 mingw32)
14648 mail_lock="none-needed" ;;
14649 esac
14651 BLESSMAIL_TARGET=
14652 case "$mail_lock" in
14653 flock)
14654 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
14657 lockf)
14658 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
14661 none-needed) ;;
14663 *) BLESSMAIL_TARGET="need-blessmail" ;;
14664 esac
14668 for ac_func in gethostname \
14669 getrusage get_current_dir_name \
14670 lrand48 \
14671 select getpagesize setlocale \
14672 utimes getrlimit setrlimit shutdown getaddrinfo \
14673 strsignal setitimer \
14674 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
14675 gai_strerror mkstemp getline getdelim sync \
14676 difftime posix_memalign \
14677 getpwent endpwent getgrent endgrent \
14678 touchlock \
14679 cfmakeraw cfsetspeed copysign __executable_start
14680 do :
14681 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14682 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14683 eval as_val=\$$as_ac_var
14684 if test "x$as_val" = x""yes; then :
14685 cat >>confdefs.h <<_ACEOF
14686 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14687 _ACEOF
14690 done
14693 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
14694 ## has a broken `rint' in some library versions including math library
14695 ## version number A.09.05.
14696 ## You can fix the math library by installing patch number PHSS_4630.
14697 ## But we can fix it more reliably for Emacs by just not using rint.
14698 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
14699 case $opsys in
14700 hpux*) : ;;
14701 *) for ac_func in random rint
14702 do :
14703 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14704 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14705 eval as_val=\$$as_ac_var
14706 if test "x$as_val" = x""yes; then :
14707 cat >>confdefs.h <<_ACEOF
14708 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14709 _ACEOF
14712 done
14714 esac
14716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
14717 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
14718 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
14719 $as_echo_n "(cached) " >&6
14720 else
14721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14722 /* end confdefs.h. */
14725 main ()
14727 __builtin_unwind_init ();
14729 return 0;
14731 _ACEOF
14732 if ac_fn_c_try_link "$LINENO"; then :
14733 emacs_cv_func___builtin_unwind_init=yes
14734 else
14735 emacs_cv_func___builtin_unwind_init=no
14737 rm -f core conftest.err conftest.$ac_objext \
14738 conftest$ac_exeext conftest.$ac_ext
14740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
14741 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
14742 if test $emacs_cv_func___builtin_unwind_init = yes; then
14744 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
14752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14753 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
14754 if test "${ac_cv_sys_largefile_source+set}" = set; then :
14755 $as_echo_n "(cached) " >&6
14756 else
14757 while :; do
14758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14759 /* end confdefs.h. */
14760 #include <sys/types.h> /* for off_t */
14761 #include <stdio.h>
14763 main ()
14765 int (*fp) (FILE *, off_t, int) = fseeko;
14766 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14768 return 0;
14770 _ACEOF
14771 if ac_fn_c_try_link "$LINENO"; then :
14772 ac_cv_sys_largefile_source=no; break
14774 rm -f core conftest.err conftest.$ac_objext \
14775 conftest$ac_exeext conftest.$ac_ext
14776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14777 /* end confdefs.h. */
14778 #define _LARGEFILE_SOURCE 1
14779 #include <sys/types.h> /* for off_t */
14780 #include <stdio.h>
14782 main ()
14784 int (*fp) (FILE *, off_t, int) = fseeko;
14785 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14787 return 0;
14789 _ACEOF
14790 if ac_fn_c_try_link "$LINENO"; then :
14791 ac_cv_sys_largefile_source=1; break
14793 rm -f core conftest.err conftest.$ac_objext \
14794 conftest$ac_exeext conftest.$ac_ext
14795 ac_cv_sys_largefile_source=unknown
14796 break
14797 done
14799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14800 $as_echo "$ac_cv_sys_largefile_source" >&6; }
14801 case $ac_cv_sys_largefile_source in #(
14802 no | unknown) ;;
14804 cat >>confdefs.h <<_ACEOF
14805 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14806 _ACEOF
14808 esac
14809 rm -rf conftest*
14811 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14812 # in glibc 2.1.3, but that breaks too many other things.
14813 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14814 if test $ac_cv_sys_largefile_source != unknown; then
14816 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14821 # UNIX98 PTYs.
14822 for ac_func in grantpt
14823 do :
14824 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
14825 if test "x$ac_cv_func_grantpt" = x""yes; then :
14826 cat >>confdefs.h <<_ACEOF
14827 #define HAVE_GRANTPT 1
14828 _ACEOF
14831 done
14834 # PTY-related GNU extensions.
14835 for ac_func in getpt posix_openpt
14836 do :
14837 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14838 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14839 eval as_val=\$$as_ac_var
14840 if test "x$as_val" = x""yes; then :
14841 cat >>confdefs.h <<_ACEOF
14842 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14843 _ACEOF
14846 done
14849 # Check this now, so that we will NOT find the above functions in ncurses.
14850 # That is because we have not set up to link ncurses in lib-src.
14851 # It's better to believe a function is not available
14852 # than to expect to find it in ncurses.
14853 # Also we need tputs and friends to be able to build at all.
14854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
14855 $as_echo_n "checking for library containing tputs... " >&6; }
14856 # Run a test program that contains a call to tputs, a call that is
14857 # never executed. This tests whether a pre-'main' dynamic linker
14858 # works with the library. It's too much trouble to actually call
14859 # tputs in the test program, due to portability hassles. When
14860 # cross-compiling, assume the test program will run if it links.
14862 if test "${opsys}" = "mingw32"; then
14863 msg='none required'
14864 else
14865 # Maybe curses should be tried earlier?
14866 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
14867 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
14868 OLIBS=$LIBS
14869 if test -z "$tputs_library"; then
14870 LIBS_TERMCAP=
14871 msg='none required'
14872 else
14873 LIBS_TERMCAP=-l$tputs_library
14874 msg=$LIBS_TERMCAP
14875 LIBS="$LIBS_TERMCAP $LIBS"
14877 if test "$cross_compiling" = yes; then :
14878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14879 /* end confdefs.h. */
14881 extern void tputs (const char *, int, int (*)(int));
14882 int main (int argc, char **argv)
14884 if (argc == 10000)
14885 tputs (argv[0], 0, 0);
14886 return 0;
14889 _ACEOF
14890 if ac_fn_c_try_link "$LINENO"; then :
14892 else
14893 msg=no
14895 rm -f core conftest.err conftest.$ac_objext \
14896 conftest$ac_exeext conftest.$ac_ext
14897 else
14898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14899 /* end confdefs.h. */
14901 extern void tputs (const char *, int, int (*)(int));
14902 int main (int argc, char **argv)
14904 if (argc == 10000)
14905 tputs (argv[0], 0, 0);
14906 return 0;
14909 _ACEOF
14910 if ac_fn_c_try_run "$LINENO"; then :
14912 else
14913 msg=no
14915 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14916 conftest.$ac_objext conftest.beam conftest.$ac_ext
14919 LIBS=$OLIBS
14920 if test "X$msg" != Xno; then
14921 break
14923 done
14925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
14926 $as_echo "$msg" >&6; }
14927 if test "X$msg" = Xno; then
14928 as_fn_error "The required function \`tputs' was not found in any library.
14929 The following libraries were tried (in order):
14930 libtinfo, libncurses, libterminfo, libtermcap, libcurses
14931 Please try installing whichever of these libraries is most appropriate
14932 for your system, together with its header files.
14933 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
14936 ## Use termcap instead of terminfo?
14937 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
14938 TERMINFO=yes
14939 ## FIXME? In the cases below where we unconditionally set
14940 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
14941 ## if that was found above to have tputs.
14942 ## Should we use the gnu* logic everywhere?
14943 case "$opsys" in
14944 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
14945 ## The ncurses library has been moved out of the System framework in
14946 ## Mac OS X 10.2. So if configure detects it, set the command-line
14947 ## option to use it.
14948 darwin) LIBS_TERMCAP="-lncurses" ;;
14950 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
14952 freebsd)
14953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
14954 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
14955 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
14956 $as_echo_n "(cached) " >&6
14957 else
14958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14959 /* end confdefs.h. */
14960 #include <osreldate.h>
14962 main ()
14964 #if __FreeBSD_version < 400000
14965 fail;
14966 #endif
14969 return 0;
14971 _ACEOF
14972 if ac_fn_c_try_link "$LINENO"; then :
14973 emacs_cv_freebsd_terminfo=yes
14974 else
14975 emacs_cv_freebsd_terminfo=no
14977 rm -f core conftest.err conftest.$ac_objext \
14978 conftest$ac_exeext conftest.$ac_ext
14982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
14983 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
14985 if test $emacs_cv_freebsd_terminfo = yes; then
14986 LIBS_TERMCAP="-lncurses"
14987 else
14988 TERMINFO=no
14989 LIBS_TERMCAP="-ltermcap"
14993 mingw32)
14994 TERMINFO=no
14995 LIBS_TERMCAP=
14998 netbsd)
14999 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15000 TERMINFO=no
15001 LIBS_TERMCAP="-ltermcap"
15005 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15007 ## hpux: Make sure we get select from libc rather than from libcurses
15008 ## because libcurses on HPUX 10.10 has a broken version of select.
15009 ## We used to use -lc -lcurses, but this may be cleaner.
15010 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15011 # set that way, now it uses the default). Isn't this a contradiction?
15012 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15014 esac
15016 TERMCAP_OBJ=tparam.o
15017 if test $TERMINFO = yes; then
15019 $as_echo "#define TERMINFO 1" >>confdefs.h
15021 TERMCAP_OBJ=terminfo.o
15027 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15028 # On Darwin, res_init appears not to be useful: see bug#562 and
15029 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15030 resolv=no
15032 if test $opsys != darwin; then
15034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15035 /* end confdefs.h. */
15036 #include <netinet/in.h>
15037 #include <arpa/nameser.h>
15038 #include <resolv.h>
15040 main ()
15042 return res_init();
15044 return 0;
15046 _ACEOF
15047 if ac_fn_c_try_link "$LINENO"; then :
15048 have_res_init=yes
15049 else
15050 have_res_init=no
15052 rm -f core conftest.err conftest.$ac_objext \
15053 conftest$ac_exeext conftest.$ac_ext
15054 if test "$have_res_init" = no; then
15055 OLIBS="$LIBS"
15056 LIBS="$LIBS -lresolv"
15057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15058 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15060 /* end confdefs.h. */
15061 #include <netinet/in.h>
15062 #include <arpa/nameser.h>
15063 #include <resolv.h>
15065 main ()
15067 return res_init();
15069 return 0;
15071 _ACEOF
15072 if ac_fn_c_try_link "$LINENO"; then :
15073 have_res_init=yes
15074 else
15075 have_res_init=no
15077 rm -f core conftest.err conftest.$ac_objext \
15078 conftest$ac_exeext conftest.$ac_ext
15079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15080 $as_echo "$have_res_init" >&6; }
15081 if test "$have_res_init" = yes ; then
15082 resolv=yes
15084 LIBS="$OLIBS"
15087 if test "$have_res_init" = yes; then
15089 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15093 # Do we need the Hesiod library to provide the support routines?
15094 LIBHESIOD=
15095 if test "$with_hesiod" != no ; then
15096 # Don't set $LIBS here -- see comments above. FIXME which comments?
15097 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15098 if test "x$ac_cv_func_res_send" = x""yes; then :
15100 else
15101 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15102 if test "x$ac_cv_func___res_send" = x""yes; then :
15104 else
15105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15106 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15107 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15108 $as_echo_n "(cached) " >&6
15109 else
15110 ac_check_lib_save_LIBS=$LIBS
15111 LIBS="-lresolv $LIBS"
15112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15113 /* end confdefs.h. */
15115 /* Override any GCC internal prototype to avoid an error.
15116 Use char because int might match the return type of a GCC
15117 builtin and then its argument prototype would still apply. */
15118 #ifdef __cplusplus
15119 extern "C"
15120 #endif
15121 char res_send ();
15123 main ()
15125 return res_send ();
15127 return 0;
15129 _ACEOF
15130 if ac_fn_c_try_link "$LINENO"; then :
15131 ac_cv_lib_resolv_res_send=yes
15132 else
15133 ac_cv_lib_resolv_res_send=no
15135 rm -f core conftest.err conftest.$ac_objext \
15136 conftest$ac_exeext conftest.$ac_ext
15137 LIBS=$ac_check_lib_save_LIBS
15139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15140 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15141 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15142 resolv=yes
15143 else
15144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15145 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15146 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15147 $as_echo_n "(cached) " >&6
15148 else
15149 ac_check_lib_save_LIBS=$LIBS
15150 LIBS="-lresolv $LIBS"
15151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15152 /* end confdefs.h. */
15154 /* Override any GCC internal prototype to avoid an error.
15155 Use char because int might match the return type of a GCC
15156 builtin and then its argument prototype would still apply. */
15157 #ifdef __cplusplus
15158 extern "C"
15159 #endif
15160 char __res_send ();
15162 main ()
15164 return __res_send ();
15166 return 0;
15168 _ACEOF
15169 if ac_fn_c_try_link "$LINENO"; then :
15170 ac_cv_lib_resolv___res_send=yes
15171 else
15172 ac_cv_lib_resolv___res_send=no
15174 rm -f core conftest.err conftest.$ac_objext \
15175 conftest$ac_exeext conftest.$ac_ext
15176 LIBS=$ac_check_lib_save_LIBS
15178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15179 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15180 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15181 resolv=yes
15190 if test "$resolv" = yes ; then
15191 RESOLVLIB=-lresolv
15192 else
15193 RESOLVLIB=
15195 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15196 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15198 else
15199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15200 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15201 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15202 $as_echo_n "(cached) " >&6
15203 else
15204 ac_check_lib_save_LIBS=$LIBS
15205 LIBS="-lhesiod $RESOLVLIB $LIBS"
15206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15207 /* end confdefs.h. */
15209 /* Override any GCC internal prototype to avoid an error.
15210 Use char because int might match the return type of a GCC
15211 builtin and then its argument prototype would still apply. */
15212 #ifdef __cplusplus
15213 extern "C"
15214 #endif
15215 char hes_getmailhost ();
15217 main ()
15219 return hes_getmailhost ();
15221 return 0;
15223 _ACEOF
15224 if ac_fn_c_try_link "$LINENO"; then :
15225 ac_cv_lib_hesiod_hes_getmailhost=yes
15226 else
15227 ac_cv_lib_hesiod_hes_getmailhost=no
15229 rm -f core conftest.err conftest.$ac_objext \
15230 conftest$ac_exeext conftest.$ac_ext
15231 LIBS=$ac_check_lib_save_LIBS
15233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15234 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15235 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15236 hesiod=yes
15237 else
15244 if test x"$hesiod" = xyes; then
15246 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
15248 LIBHESIOD=-lhesiod
15253 # Do we need libresolv (due to res_init or Hesiod)?
15254 if test "$resolv" = yes && test $opsys != darwin; then
15256 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
15258 LIBRESOLV=-lresolv
15259 else
15260 LIBRESOLV=
15264 # These tell us which Kerberos-related libraries to use.
15265 COM_ERRLIB=
15266 CRYPTOLIB=
15267 KRB5LIB=
15268 DESLIB=
15269 KRB4LIB=
15271 if test "${with_kerberos}" != no; then
15272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15273 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15274 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15275 $as_echo_n "(cached) " >&6
15276 else
15277 ac_check_lib_save_LIBS=$LIBS
15278 LIBS="-lcom_err $LIBS"
15279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15280 /* end confdefs.h. */
15282 /* Override any GCC internal prototype to avoid an error.
15283 Use char because int might match the return type of a GCC
15284 builtin and then its argument prototype would still apply. */
15285 #ifdef __cplusplus
15286 extern "C"
15287 #endif
15288 char com_err ();
15290 main ()
15292 return com_err ();
15294 return 0;
15296 _ACEOF
15297 if ac_fn_c_try_link "$LINENO"; then :
15298 ac_cv_lib_com_err_com_err=yes
15299 else
15300 ac_cv_lib_com_err_com_err=no
15302 rm -f core conftest.err conftest.$ac_objext \
15303 conftest$ac_exeext conftest.$ac_ext
15304 LIBS=$ac_check_lib_save_LIBS
15306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15307 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15308 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15309 have_com_err=yes
15310 else
15311 have_com_err=no
15314 if test $have_com_err = yes; then
15315 COM_ERRLIB=-lcom_err
15316 LIBS="$COM_ERRLIB $LIBS"
15318 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
15321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15322 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15323 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15324 $as_echo_n "(cached) " >&6
15325 else
15326 ac_check_lib_save_LIBS=$LIBS
15327 LIBS="-lcrypto $LIBS"
15328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15329 /* end confdefs.h. */
15331 /* Override any GCC internal prototype to avoid an error.
15332 Use char because int might match the return type of a GCC
15333 builtin and then its argument prototype would still apply. */
15334 #ifdef __cplusplus
15335 extern "C"
15336 #endif
15337 char mit_des_cbc_encrypt ();
15339 main ()
15341 return mit_des_cbc_encrypt ();
15343 return 0;
15345 _ACEOF
15346 if ac_fn_c_try_link "$LINENO"; then :
15347 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15348 else
15349 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15351 rm -f core conftest.err conftest.$ac_objext \
15352 conftest$ac_exeext conftest.$ac_ext
15353 LIBS=$ac_check_lib_save_LIBS
15355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15356 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15357 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15358 have_crypto=yes
15359 else
15360 have_crypto=no
15363 if test $have_crypto = yes; then
15364 CRYPTOLIB=-lcrypto
15365 LIBS="$CRYPTOLIB $LIBS"
15367 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
15370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15371 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15372 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15373 $as_echo_n "(cached) " >&6
15374 else
15375 ac_check_lib_save_LIBS=$LIBS
15376 LIBS="-lk5crypto $LIBS"
15377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15378 /* end confdefs.h. */
15380 /* Override any GCC internal prototype to avoid an error.
15381 Use char because int might match the return type of a GCC
15382 builtin and then its argument prototype would still apply. */
15383 #ifdef __cplusplus
15384 extern "C"
15385 #endif
15386 char mit_des_cbc_encrypt ();
15388 main ()
15390 return mit_des_cbc_encrypt ();
15392 return 0;
15394 _ACEOF
15395 if ac_fn_c_try_link "$LINENO"; then :
15396 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15397 else
15398 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15400 rm -f core conftest.err conftest.$ac_objext \
15401 conftest$ac_exeext conftest.$ac_ext
15402 LIBS=$ac_check_lib_save_LIBS
15404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15405 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15406 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15407 have_k5crypto=yes
15408 else
15409 have_k5crypto=no
15412 if test $have_k5crypto = yes; then
15413 CRYPTOLIB=-lk5crypto
15414 LIBS="$CRYPTOLIB $LIBS"
15416 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
15419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15420 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15421 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15422 $as_echo_n "(cached) " >&6
15423 else
15424 ac_check_lib_save_LIBS=$LIBS
15425 LIBS="-lkrb5 $LIBS"
15426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15427 /* end confdefs.h. */
15429 /* Override any GCC internal prototype to avoid an error.
15430 Use char because int might match the return type of a GCC
15431 builtin and then its argument prototype would still apply. */
15432 #ifdef __cplusplus
15433 extern "C"
15434 #endif
15435 char krb5_init_context ();
15437 main ()
15439 return krb5_init_context ();
15441 return 0;
15443 _ACEOF
15444 if ac_fn_c_try_link "$LINENO"; then :
15445 ac_cv_lib_krb5_krb5_init_context=yes
15446 else
15447 ac_cv_lib_krb5_krb5_init_context=no
15449 rm -f core conftest.err conftest.$ac_objext \
15450 conftest$ac_exeext conftest.$ac_ext
15451 LIBS=$ac_check_lib_save_LIBS
15453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15454 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15455 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15456 have_krb5=yes
15457 else
15458 have_krb5=no
15461 if test $have_krb5=yes; then
15462 KRB5LIB=-lkrb5
15463 LIBS="$KRB5LIB $LIBS"
15465 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
15468 if test "${with_kerberos5}" = no; then
15469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15470 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15471 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15472 $as_echo_n "(cached) " >&6
15473 else
15474 ac_check_lib_save_LIBS=$LIBS
15475 LIBS="-ldes425 $LIBS"
15476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15477 /* end confdefs.h. */
15479 /* Override any GCC internal prototype to avoid an error.
15480 Use char because int might match the return type of a GCC
15481 builtin and then its argument prototype would still apply. */
15482 #ifdef __cplusplus
15483 extern "C"
15484 #endif
15485 char des_cbc_encrypt ();
15487 main ()
15489 return des_cbc_encrypt ();
15491 return 0;
15493 _ACEOF
15494 if ac_fn_c_try_link "$LINENO"; then :
15495 ac_cv_lib_des425_des_cbc_encrypt=yes
15496 else
15497 ac_cv_lib_des425_des_cbc_encrypt=no
15499 rm -f core conftest.err conftest.$ac_objext \
15500 conftest$ac_exeext conftest.$ac_ext
15501 LIBS=$ac_check_lib_save_LIBS
15503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15504 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15505 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15506 have_des425=yes
15507 else
15508 have_des425=no
15511 if test $have_des425 = yes; then
15512 DESLIB=-ldes425
15513 LIBS="$DESLIB $LIBS"
15515 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
15517 else
15518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15519 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15520 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15521 $as_echo_n "(cached) " >&6
15522 else
15523 ac_check_lib_save_LIBS=$LIBS
15524 LIBS="-ldes $LIBS"
15525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15526 /* end confdefs.h. */
15528 /* Override any GCC internal prototype to avoid an error.
15529 Use char because int might match the return type of a GCC
15530 builtin and then its argument prototype would still apply. */
15531 #ifdef __cplusplus
15532 extern "C"
15533 #endif
15534 char des_cbc_encrypt ();
15536 main ()
15538 return des_cbc_encrypt ();
15540 return 0;
15542 _ACEOF
15543 if ac_fn_c_try_link "$LINENO"; then :
15544 ac_cv_lib_des_des_cbc_encrypt=yes
15545 else
15546 ac_cv_lib_des_des_cbc_encrypt=no
15548 rm -f core conftest.err conftest.$ac_objext \
15549 conftest$ac_exeext conftest.$ac_ext
15550 LIBS=$ac_check_lib_save_LIBS
15552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
15553 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
15554 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
15555 have_des=yes
15556 else
15557 have_des=no
15560 if test $have_des = yes; then
15561 DESLIB=-ldes
15562 LIBS="$DESLIB $LIBS"
15564 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
15568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
15569 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
15570 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
15571 $as_echo_n "(cached) " >&6
15572 else
15573 ac_check_lib_save_LIBS=$LIBS
15574 LIBS="-lkrb4 $LIBS"
15575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15576 /* end confdefs.h. */
15578 /* Override any GCC internal prototype to avoid an error.
15579 Use char because int might match the return type of a GCC
15580 builtin and then its argument prototype would still apply. */
15581 #ifdef __cplusplus
15582 extern "C"
15583 #endif
15584 char krb_get_cred ();
15586 main ()
15588 return krb_get_cred ();
15590 return 0;
15592 _ACEOF
15593 if ac_fn_c_try_link "$LINENO"; then :
15594 ac_cv_lib_krb4_krb_get_cred=yes
15595 else
15596 ac_cv_lib_krb4_krb_get_cred=no
15598 rm -f core conftest.err conftest.$ac_objext \
15599 conftest$ac_exeext conftest.$ac_ext
15600 LIBS=$ac_check_lib_save_LIBS
15602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
15603 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
15604 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
15605 have_krb4=yes
15606 else
15607 have_krb4=no
15610 if test $have_krb4 = yes; then
15611 KRB4LIB=-lkrb4
15612 LIBS="$KRB4LIB $LIBS"
15614 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
15616 else
15617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
15618 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
15619 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
15620 $as_echo_n "(cached) " >&6
15621 else
15622 ac_check_lib_save_LIBS=$LIBS
15623 LIBS="-lkrb $LIBS"
15624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15625 /* end confdefs.h. */
15627 /* Override any GCC internal prototype to avoid an error.
15628 Use char because int might match the return type of a GCC
15629 builtin and then its argument prototype would still apply. */
15630 #ifdef __cplusplus
15631 extern "C"
15632 #endif
15633 char krb_get_cred ();
15635 main ()
15637 return krb_get_cred ();
15639 return 0;
15641 _ACEOF
15642 if ac_fn_c_try_link "$LINENO"; then :
15643 ac_cv_lib_krb_krb_get_cred=yes
15644 else
15645 ac_cv_lib_krb_krb_get_cred=no
15647 rm -f core conftest.err conftest.$ac_objext \
15648 conftest$ac_exeext conftest.$ac_ext
15649 LIBS=$ac_check_lib_save_LIBS
15651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
15652 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
15653 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
15654 have_krb=yes
15655 else
15656 have_krb=no
15659 if test $have_krb = yes; then
15660 KRB4LIB=-lkrb
15661 LIBS="$KRB4LIB $LIBS"
15663 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
15669 if test "${with_kerberos5}" != no; then
15670 for ac_header in krb5.h
15671 do :
15672 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
15673 if test "x$ac_cv_header_krb5_h" = x""yes; then :
15674 cat >>confdefs.h <<_ACEOF
15675 #define HAVE_KRB5_H 1
15676 _ACEOF
15677 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
15679 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
15681 cat >>confdefs.h <<_ACEOF
15682 #define HAVE_KRB5_ERROR_TEXT 1
15683 _ACEOF
15687 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
15689 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
15691 cat >>confdefs.h <<_ACEOF
15692 #define HAVE_KRB5_ERROR_E_TEXT 1
15693 _ACEOF
15700 done
15702 else
15703 for ac_header in des.h
15704 do :
15705 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
15706 if test "x$ac_cv_header_des_h" = x""yes; then :
15707 cat >>confdefs.h <<_ACEOF
15708 #define HAVE_DES_H 1
15709 _ACEOF
15711 else
15712 for ac_header in kerberosIV/des.h
15713 do :
15714 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
15715 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
15716 cat >>confdefs.h <<_ACEOF
15717 #define HAVE_KERBEROSIV_DES_H 1
15718 _ACEOF
15720 else
15721 for ac_header in kerberos/des.h
15722 do :
15723 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
15724 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
15725 cat >>confdefs.h <<_ACEOF
15726 #define HAVE_KERBEROS_DES_H 1
15727 _ACEOF
15731 done
15735 done
15739 done
15741 for ac_header in krb.h
15742 do :
15743 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
15744 if test "x$ac_cv_header_krb_h" = x""yes; then :
15745 cat >>confdefs.h <<_ACEOF
15746 #define HAVE_KRB_H 1
15747 _ACEOF
15749 else
15750 for ac_header in kerberosIV/krb.h
15751 do :
15752 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
15753 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
15754 cat >>confdefs.h <<_ACEOF
15755 #define HAVE_KERBEROSIV_KRB_H 1
15756 _ACEOF
15758 else
15759 for ac_header in kerberos/krb.h
15760 do :
15761 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
15762 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
15763 cat >>confdefs.h <<_ACEOF
15764 #define HAVE_KERBEROS_KRB_H 1
15765 _ACEOF
15769 done
15773 done
15777 done
15780 for ac_header in com_err.h
15781 do :
15782 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
15783 if test "x$ac_cv_header_com_err_h" = x""yes; then :
15784 cat >>confdefs.h <<_ACEOF
15785 #define HAVE_COM_ERR_H 1
15786 _ACEOF
15790 done
15803 for ac_func in $ac_func_list
15804 do :
15805 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15806 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15807 eval as_val=\$$as_ac_var
15808 if test "x$as_val" = x""yes; then :
15809 cat >>confdefs.h <<_ACEOF
15810 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15811 _ACEOF
15814 done
15819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
15820 $as_echo_n "checking whether localtime caches TZ... " >&6; }
15821 if test "${emacs_cv_localtime_cache+set}" = set; then :
15822 $as_echo_n "(cached) " >&6
15823 else
15824 if test x$ac_cv_func_tzset = xyes; then
15825 if test "$cross_compiling" = yes; then :
15826 # If we have tzset, assume the worst when cross-compiling.
15827 emacs_cv_localtime_cache=yes
15828 else
15829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15830 /* end confdefs.h. */
15831 #include <time.h>
15832 char TZ_GMT0[] = "TZ=GMT0";
15833 char TZ_PST8[] = "TZ=PST8";
15834 main()
15836 time_t now = time ((time_t *) 0);
15837 int hour_GMT0, hour_unset;
15838 if (putenv (TZ_GMT0) != 0)
15839 exit (1);
15840 hour_GMT0 = localtime (&now)->tm_hour;
15841 unsetenv("TZ");
15842 hour_unset = localtime (&now)->tm_hour;
15843 if (putenv (TZ_PST8) != 0)
15844 exit (1);
15845 if (localtime (&now)->tm_hour == hour_GMT0)
15846 exit (1);
15847 unsetenv("TZ");
15848 if (localtime (&now)->tm_hour != hour_unset)
15849 exit (1);
15850 exit (0);
15852 _ACEOF
15853 if ac_fn_c_try_run "$LINENO"; then :
15854 emacs_cv_localtime_cache=no
15855 else
15856 emacs_cv_localtime_cache=yes
15858 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15859 conftest.$ac_objext conftest.beam conftest.$ac_ext
15862 else
15863 # If we lack tzset, report that localtime does not cache TZ,
15864 # since we can't invalidate the cache if we don't have tzset.
15865 emacs_cv_localtime_cache=no
15868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
15869 $as_echo "$emacs_cv_localtime_cache" >&6; }
15870 if test $emacs_cv_localtime_cache = yes; then
15872 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
15876 ok_so_far=yes
15877 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
15878 if test "x$ac_cv_func_socket" = x""yes; then :
15880 else
15881 ok_so_far=no
15884 if test $ok_so_far = yes; then
15885 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
15886 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
15888 else
15889 ok_so_far=no
15894 if test $ok_so_far = yes; then
15895 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
15896 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
15898 else
15899 ok_so_far=no
15904 if test $ok_so_far = yes; then
15906 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
15910 if test -f /usr/lpp/X11/bin/smt.exp; then
15912 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
15916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
15917 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
15918 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
15919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15920 $as_echo "yes" >&6; }
15922 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
15924 else
15925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15926 $as_echo "no" >&6; }
15929 case $canonical in
15930 *-solaris2.4 | *-solaris2.4.*)
15931 : ${ac_cv_func_vfork_works=no};;
15932 esac
15934 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15935 if test "x$ac_cv_type_pid_t" = x""yes; then :
15937 else
15939 cat >>confdefs.h <<_ACEOF
15940 #define pid_t int
15941 _ACEOF
15945 for ac_header in vfork.h
15946 do :
15947 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15948 if test "x$ac_cv_header_vfork_h" = x""yes; then :
15949 cat >>confdefs.h <<_ACEOF
15950 #define HAVE_VFORK_H 1
15951 _ACEOF
15955 done
15957 for ac_func in fork vfork
15958 do :
15959 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15960 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15961 eval as_val=\$$as_ac_var
15962 if test "x$as_val" = x""yes; then :
15963 cat >>confdefs.h <<_ACEOF
15964 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15965 _ACEOF
15968 done
15970 if test "x$ac_cv_func_fork" = xyes; then
15971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15972 $as_echo_n "checking for working fork... " >&6; }
15973 if test "${ac_cv_func_fork_works+set}" = set; then :
15974 $as_echo_n "(cached) " >&6
15975 else
15976 if test "$cross_compiling" = yes; then :
15977 ac_cv_func_fork_works=cross
15978 else
15979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15980 /* end confdefs.h. */
15981 $ac_includes_default
15983 main ()
15986 /* By Ruediger Kuhlmann. */
15987 return fork () < 0;
15990 return 0;
15992 _ACEOF
15993 if ac_fn_c_try_run "$LINENO"; then :
15994 ac_cv_func_fork_works=yes
15995 else
15996 ac_cv_func_fork_works=no
15998 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15999 conftest.$ac_objext conftest.beam conftest.$ac_ext
16003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
16004 $as_echo "$ac_cv_func_fork_works" >&6; }
16006 else
16007 ac_cv_func_fork_works=$ac_cv_func_fork
16009 if test "x$ac_cv_func_fork_works" = xcross; then
16010 case $host in
16011 *-*-amigaos* | *-*-msdosdjgpp*)
16012 # Override, as these systems have only a dummy fork() stub
16013 ac_cv_func_fork_works=no
16016 ac_cv_func_fork_works=yes
16018 esac
16019 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
16020 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
16022 ac_cv_func_vfork_works=$ac_cv_func_vfork
16023 if test "x$ac_cv_func_vfork" = xyes; then
16024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
16025 $as_echo_n "checking for working vfork... " >&6; }
16026 if test "${ac_cv_func_vfork_works+set}" = set; then :
16027 $as_echo_n "(cached) " >&6
16028 else
16029 if test "$cross_compiling" = yes; then :
16030 ac_cv_func_vfork_works=cross
16031 else
16032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16033 /* end confdefs.h. */
16034 /* Thanks to Paul Eggert for this test. */
16035 $ac_includes_default
16036 #include <sys/wait.h>
16037 #ifdef HAVE_VFORK_H
16038 # include <vfork.h>
16039 #endif
16040 /* On some sparc systems, changes by the child to local and incoming
16041 argument registers are propagated back to the parent. The compiler
16042 is told about this with #include <vfork.h>, but some compilers
16043 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
16044 static variable whose address is put into a register that is
16045 clobbered by the vfork. */
16046 static void
16047 #ifdef __cplusplus
16048 sparc_address_test (int arg)
16049 # else
16050 sparc_address_test (arg) int arg;
16051 #endif
16053 static pid_t child;
16054 if (!child) {
16055 child = vfork ();
16056 if (child < 0) {
16057 perror ("vfork");
16058 _exit(2);
16060 if (!child) {
16061 arg = getpid();
16062 write(-1, "", 0);
16063 _exit (arg);
16069 main ()
16071 pid_t parent = getpid ();
16072 pid_t child;
16074 sparc_address_test (0);
16076 child = vfork ();
16078 if (child == 0) {
16079 /* Here is another test for sparc vfork register problems. This
16080 test uses lots of local variables, at least as many local
16081 variables as main has allocated so far including compiler
16082 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16083 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16084 reuse the register of parent for one of the local variables,
16085 since it will think that parent can't possibly be used any more
16086 in this routine. Assigning to the local variable will thus
16087 munge parent in the parent process. */
16088 pid_t
16089 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16090 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16091 /* Convince the compiler that p..p7 are live; otherwise, it might
16092 use the same hardware register for all 8 local variables. */
16093 if (p != p1 || p != p2 || p != p3 || p != p4
16094 || p != p5 || p != p6 || p != p7)
16095 _exit(1);
16097 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16098 from child file descriptors. If the child closes a descriptor
16099 before it execs or exits, this munges the parent's descriptor
16100 as well. Test for this by closing stdout in the child. */
16101 _exit(close(fileno(stdout)) != 0);
16102 } else {
16103 int status;
16104 struct stat st;
16106 while (wait(&status) != child)
16108 return (
16109 /* Was there some problem with vforking? */
16110 child < 0
16112 /* Did the child fail? (This shouldn't happen.) */
16113 || status
16115 /* Did the vfork/compiler bug occur? */
16116 || parent != getpid()
16118 /* Did the file descriptor bug occur? */
16119 || fstat(fileno(stdout), &st) != 0
16123 _ACEOF
16124 if ac_fn_c_try_run "$LINENO"; then :
16125 ac_cv_func_vfork_works=yes
16126 else
16127 ac_cv_func_vfork_works=no
16129 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16130 conftest.$ac_objext conftest.beam conftest.$ac_ext
16134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16135 $as_echo "$ac_cv_func_vfork_works" >&6; }
16138 if test "x$ac_cv_func_fork_works" = xcross; then
16139 ac_cv_func_vfork_works=$ac_cv_func_vfork
16140 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16141 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16144 if test "x$ac_cv_func_vfork_works" = xyes; then
16146 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16148 else
16150 $as_echo "#define vfork fork" >>confdefs.h
16153 if test "x$ac_cv_func_fork_works" = xyes; then
16155 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16160 for ac_func in snprintf
16161 do :
16162 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16163 if test "x$ac_cv_func_snprintf" = x""yes; then :
16164 cat >>confdefs.h <<_ACEOF
16165 #define HAVE_SNPRINTF 1
16166 _ACEOF
16169 done
16172 XGSELOBJ=
16173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16174 $as_echo_n "checking whether GLib is linked in... " >&6; }
16175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16176 /* end confdefs.h. */
16177 #include <glib.h>
16180 main ()
16182 g_print ("Hello world");
16184 return 0;
16186 _ACEOF
16187 if ac_fn_c_try_link "$LINENO"; then :
16188 links_glib=yes
16189 else
16190 links_glib=no
16192 rm -f core conftest.err conftest.$ac_objext \
16193 conftest$ac_exeext conftest.$ac_ext
16194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16195 $as_echo "$links_glib" >&6; }
16196 if test "${links_glib}" = "yes"; then
16198 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16200 XGSELOBJ=xgselect.o
16204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16205 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16206 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16207 $as_echo_n "(cached) " >&6
16208 else
16209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16210 /* end confdefs.h. */
16211 #include <langinfo.h>
16213 main ()
16215 char* cs = nl_langinfo(CODESET);
16217 return 0;
16219 _ACEOF
16220 if ac_fn_c_try_link "$LINENO"; then :
16221 emacs_cv_langinfo_codeset=yes
16222 else
16223 emacs_cv_langinfo_codeset=no
16225 rm -f core conftest.err conftest.$ac_objext \
16226 conftest$ac_exeext conftest.$ac_ext
16229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16230 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16231 if test $emacs_cv_langinfo_codeset = yes; then
16233 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16238 $as_echo_n "checking for mbstate_t... " >&6; }
16239 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16240 $as_echo_n "(cached) " >&6
16241 else
16242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16243 /* end confdefs.h. */
16244 $ac_includes_default
16245 # include <wchar.h>
16247 main ()
16249 mbstate_t x; return sizeof x;
16251 return 0;
16253 _ACEOF
16254 if ac_fn_c_try_compile "$LINENO"; then :
16255 ac_cv_type_mbstate_t=yes
16256 else
16257 ac_cv_type_mbstate_t=no
16259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16262 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16263 if test $ac_cv_type_mbstate_t = yes; then
16265 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16267 else
16269 $as_echo "#define mbstate_t int" >>confdefs.h
16273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16274 $as_echo_n "checking for C restricted array declarations... " >&6; }
16275 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16276 $as_echo_n "(cached) " >&6
16277 else
16278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16279 /* end confdefs.h. */
16280 void fred (int x[__restrict]);
16282 main ()
16286 return 0;
16288 _ACEOF
16289 if ac_fn_c_try_compile "$LINENO"; then :
16290 emacs_cv_c_restrict_arr=yes
16291 else
16292 emacs_cv_c_restrict_arr=no
16294 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16297 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16298 if test "$emacs_cv_c_restrict_arr" = yes; then
16300 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16305 if test "${opsys}" != "mingw32"; then
16307 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16312 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16315 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16316 if test "${opsys}" != "mingw32"; then
16318 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16323 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16329 if test "${opsys}" = "mingw32"; then
16330 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16332 else
16333 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16338 if test "${opsys}" = "mingw32"; then
16339 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16341 else
16342 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16347 $as_echo "#define subprocesses 1" >>confdefs.h
16351 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16356 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16360 if test "${opsys}" = "mingw32"; then
16361 $as_echo "#define DEVICE_SEP ':'" >>confdefs.h
16364 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == DEVICE_SEP)" >>confdefs.h
16368 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16372 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16374 else
16376 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16380 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16384 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16390 case $opsys in
16391 aix4-2)
16392 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16393 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16398 hpux*)
16399 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16402 esac
16405 case $opsys in
16406 irix6-5 | sol2* | unixware )
16408 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16411 esac
16413 emacs_broken_SIGIO=no
16415 case $opsys in
16416 hpux* | irix6-5 | openbsd | sol2* | unixware )
16417 emacs_broken_SIGIO=yes
16420 aix4-2)
16422 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16426 freebsd)
16428 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16431 esac
16433 case $opsys in
16434 gnu-* | sol2-10 )
16436 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16439 esac
16441 case $opsys in
16442 darwin | dragonfly | freebsd | netbsd | openbsd )
16444 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16447 esac
16449 case $opsys in
16450 netbsd | openbsd) sound_device="/dev/audio" ;;
16451 *) sound_device="/dev/dsp" ;;
16452 esac
16455 cat >>confdefs.h <<_ACEOF
16456 #define DEFAULT_SOUND_DEVICE "$sound_device"
16457 _ACEOF
16461 case $opsys in
16462 darwin | gnu-linux | gnu-kfreebsd )
16464 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16467 esac
16470 case $opsys in
16471 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16473 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16476 esac
16485 case $opsys in
16486 aix4-2 )
16487 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16489 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16491 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16495 cygwin )
16496 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16498 $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
16500 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16502 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16506 darwin )
16507 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16509 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16511 $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
16513 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16515 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16519 gnu | openbsd )
16520 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16524 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16525 if test "x$ac_cv_func_grantpt" = xyes; then
16527 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16529 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16531 $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) { close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
16533 if test "x$ac_cv_func_posix_openpt" = xyes; then
16534 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
16536 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16538 elif test "x$ac_cv_func_getpt" = xyes; then
16539 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16541 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16543 else
16544 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16547 else
16548 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16553 hpux*)
16554 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16556 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16558 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16562 irix6-5 )
16563 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16565 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16567 $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
16569 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16571 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16575 sol2* )
16576 $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, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
16580 unixware )
16581 $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, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
16584 esac
16587 case $opsys in
16588 sol2* | unixware )
16589 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16591 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16594 $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
16597 esac
16602 case $opsys in
16603 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
16604 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16608 gnu-linux | gnu-kfreebsd )
16610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
16611 $as_echo_n "checking for signals via characters... " >&6; }
16612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16613 /* end confdefs.h. */
16615 #include <linux/version.h>
16616 #if LINUX_VERSION_CODE < 0x20400
16617 # error "Linux version too old"
16618 #endif
16621 main ()
16625 return 0;
16627 _ACEOF
16628 if ac_fn_c_try_cpp "$LINENO"; then :
16629 emacs_signals_via_chars=yes
16630 else
16631 emacs_signals_via_chars=no
16633 rm -f conftest.err conftest.$ac_ext
16635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
16636 $as_echo "$emacs_signals_via_chars" >&6; }
16637 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
16640 esac
16645 case $opsys in
16646 aix*)
16647 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
16650 hpux*)
16651 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
16654 irix6-5)
16655 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
16658 esac
16663 case $opsys in
16664 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
16667 gnu | dragonfly | freebsd | netbsd | openbsd )
16669 $as_echo "#define TABDLY OXTABS" >>confdefs.h
16671 $as_echo "#define TAB3 OXTABS" >>confdefs.h
16675 gnu-linux | gnu-kfreebsd )
16676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16677 /* end confdefs.h. */
16679 #ifndef __ia64__
16680 # error "not ia64"
16681 #endif
16684 main ()
16688 return 0;
16690 _ACEOF
16691 if ac_fn_c_try_cpp "$LINENO"; then :
16693 $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
16696 rm -f conftest.err conftest.$ac_ext
16699 hpux*)
16701 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
16704 esac
16710 case $opsys in
16711 gnu-linux | gnu-kfreebsd )
16712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16713 /* end confdefs.h. */
16715 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
16716 || defined __alpha__ || defined __mips__ || defined __s390__ \
16717 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
16718 || defined __ia64__ || defined __sh__
16719 /* ok */
16720 #else
16721 # error "setjmp not known to work on this arch"
16722 #endif
16725 main ()
16729 return 0;
16731 _ACEOF
16732 if ac_fn_c_try_cpp "$LINENO"; then :
16733 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16736 rm -f conftest.err conftest.$ac_ext
16738 esac
16741 if test x$GCC = xyes; then
16742 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16744 else
16745 case $opsys in
16746 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
16747 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
16750 esac
16752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
16753 $as_echo_n "checking for _setjmp... " >&6; }
16754 if test "${emacs_cv_func__setjmp+set}" = set; then :
16755 $as_echo_n "(cached) " >&6
16756 else
16757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16758 /* end confdefs.h. */
16759 #include <setjmp.h>
16760 #ifdef __MINGW32__
16761 # define _longjmp longjmp
16762 #endif
16765 main ()
16767 jmp_buf j;
16768 if (! _setjmp (j))
16769 _longjmp (j, 1);
16771 return 0;
16773 _ACEOF
16774 if ac_fn_c_try_link "$LINENO"; then :
16775 emacs_cv_func__setjmp=yes
16776 else
16777 emacs_cv_func__setjmp=no
16779 rm -f core conftest.err conftest.$ac_objext \
16780 conftest$ac_exeext conftest.$ac_ext
16782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
16783 $as_echo "$emacs_cv_func__setjmp" >&6; }
16784 if test $emacs_cv_func__setjmp = yes; then
16786 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
16788 else
16789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
16790 $as_echo_n "checking for sigsetjmp... " >&6; }
16791 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
16792 $as_echo_n "(cached) " >&6
16793 else
16794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16795 /* end confdefs.h. */
16796 #include <setjmp.h>
16799 main ()
16801 sigjmp_buf j;
16802 if (! sigsetjmp (j, 1))
16803 siglongjmp (j, 1);
16805 return 0;
16807 _ACEOF
16808 if ac_fn_c_try_link "$LINENO"; then :
16809 emacs_cv_func_sigsetjmp=yes
16810 else
16811 emacs_cv_func_sigsetjmp=no
16813 rm -f core conftest.err conftest.$ac_objext \
16814 conftest$ac_exeext conftest.$ac_ext
16816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
16817 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
16818 if test $emacs_cv_func_sigsetjmp = yes; then
16820 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
16825 case $opsys in
16826 sol2* | unixware )
16828 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
16831 esac
16834 case $opsys in
16835 hpux* | sol2* )
16837 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
16840 esac
16849 case $opsys in
16850 aix4-2)
16851 $as_echo "#define USG /**/" >>confdefs.h
16853 $as_echo "#define USG5 /**/" >>confdefs.h
16855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16856 /* end confdefs.h. */
16858 #ifndef _AIX
16859 # error "_AIX not defined"
16860 #endif
16863 main ()
16867 return 0;
16869 _ACEOF
16870 if ac_fn_c_try_cpp "$LINENO"; then :
16872 else
16874 $as_echo "#define _AIX /**/" >>confdefs.h
16877 rm -f conftest.err conftest.$ac_ext
16880 cygwin)
16882 $as_echo "#define CYGWIN 1" >>confdefs.h
16886 darwin)
16888 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
16892 gnu-linux | gnu-kfreebsd )
16893 $as_echo "#define USG /**/" >>confdefs.h
16896 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
16900 hpux*)
16901 $as_echo "#define USG /**/" >>confdefs.h
16903 $as_echo "#define USG5 /**/" >>confdefs.h
16906 $as_echo "#define HPUX /**/" >>confdefs.h
16910 irix6-5)
16911 $as_echo "#define USG /**/" >>confdefs.h
16913 $as_echo "#define USG5 /**/" >>confdefs.h
16915 $as_echo "#define USG5_4 /**/" >>confdefs.h
16918 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
16922 mingw32)
16923 $as_echo "#define DOS_NT /**/" >>confdefs.h
16926 $as_echo "#define WINDOWSNT 1" >>confdefs.h
16928 if test "x$ac_enable_checking" != "x" ; then
16930 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
16935 sol2*)
16936 $as_echo "#define USG /**/" >>confdefs.h
16938 $as_echo "#define USG5 /**/" >>confdefs.h
16940 $as_echo "#define USG5_4 /**/" >>confdefs.h
16943 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
16947 unixware)
16948 $as_echo "#define USG /**/" >>confdefs.h
16950 $as_echo "#define USG5 /**/" >>confdefs.h
16952 $as_echo "#define USG5_4 /**/" >>confdefs.h
16955 esac
16957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
16958 $as_echo_n "checking for usable FIONREAD... " >&6; }
16959 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
16960 $as_echo_n "(cached) " >&6
16961 else
16962 case $opsys in
16963 aix4-2)
16964 emacs_cv_usable_FIONREAD=no
16967 mingw32)
16968 emacs_cv_usable_FIONREAD=yes
16972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16973 /* end confdefs.h. */
16974 #include <sys/types.h>
16975 #include <sys/ioctl.h>
16976 #ifdef USG5_4
16977 # include <sys/filio.h>
16978 #endif
16981 main ()
16983 int foo = ioctl (0, FIONREAD, &foo);
16985 return 0;
16987 _ACEOF
16988 if ac_fn_c_try_compile "$LINENO"; then :
16989 emacs_cv_usable_FIONREAD=yes
16990 else
16991 emacs_cv_usable_FIONREAD=no
16993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16995 esac
16997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
16998 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
16999 if test $emacs_cv_usable_FIONREAD = yes; then
17001 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
17004 if test $emacs_broken_SIGIO = no; then
17005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
17006 $as_echo_n "checking for usable SIGIO... " >&6; }
17007 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
17008 $as_echo_n "(cached) " >&6
17009 else
17010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17011 /* end confdefs.h. */
17012 #include <fcntl.h>
17013 #include <signal.h>
17016 main ()
17018 int foo = SIGIO | F_SETFL | FASYNC;
17020 return 0;
17022 _ACEOF
17023 if ac_fn_c_try_compile "$LINENO"; then :
17024 emacs_cv_usable_SIGIO=yes
17025 else
17026 emacs_cv_usable_SIGIO=no
17028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
17031 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
17032 if test $emacs_cv_usable_SIGIO = yes; then
17034 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
17041 case $opsys in
17042 cygwin)
17044 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
17048 hpux11)
17050 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
17054 irix6-5)
17056 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
17060 sol2-10)
17062 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
17065 esac
17067 # Set up the CFLAGS for real compilation, so we can substitute it.
17068 CFLAGS="$REAL_CFLAGS"
17069 CPPFLAGS="$REAL_CPPFLAGS"
17071 ## Hack to detect a buggy GCC version.
17072 if test "x$GCC" = xyes \
17073 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17074 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17075 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17076 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17079 version=$PACKAGE_VERSION
17081 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17083 cat >>confdefs.h <<_ACEOF
17084 #define COPYRIGHT "$copyright"
17085 _ACEOF
17089 ### Specify what sort of things we'll be editing into Makefile and config.h.
17090 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17093 ## Unused?
17116 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17117 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17118 ## end of LIBX_BASE, but nothing ever set it.
17123 ## Used in lwlib/Makefile.in.
17132 if test -n "${term_header}"; then
17134 cat >>confdefs.h <<_ACEOF
17135 #define TERM_HEADER "${term_header}"
17136 _ACEOF
17141 cat >>confdefs.h <<_ACEOF
17142 #define EMACS_CONFIGURATION "${canonical}"
17143 _ACEOF
17145 emacs_config_options=`echo "$emacs_config_options " | sed -e 's/--no-create //' -e 's/--no-recursion //' -e 's/ *$//' -e "s/\"/'/g"`
17147 cat >>confdefs.h <<_ACEOF
17148 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17149 _ACEOF
17153 case $opsys in
17154 mingw32)
17155 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17158 esac
17160 XMENU_OBJ=
17161 XOBJ=
17162 FONT_OBJ=
17163 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17165 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17167 XMENU_OBJ=xmenu.o
17168 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17169 FONT_OBJ=xfont.o
17170 if test "$HAVE_XFT" = "yes"; then
17171 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17172 elif test "$HAVE_FREETYPE" = "yes"; then
17173 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17181 WIDGET_OBJ=
17182 MOTIF_LIBW=
17183 if test "${USE_X_TOOLKIT}" != "none" ; then
17184 WIDGET_OBJ=widget.o
17186 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17188 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17190 $as_echo "#define USE_LUCID 1" >>confdefs.h
17192 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17194 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17196 MOTIF_LIBW=-lXm
17197 case "$opsys" in
17198 gnu-linux)
17199 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17200 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17203 unixware)
17204 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17205 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17206 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17209 aix4-2)
17210 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17211 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17213 esac
17214 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17219 TOOLKIT_LIBW=
17220 case "$USE_X_TOOLKIT" in
17221 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17222 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17223 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17224 esac
17227 if test "${opsys}" != "mingw32"; then
17228 if test "$USE_X_TOOLKIT" = "none"; then
17229 LIBXT_OTHER="\$(LIBXSM)"
17230 OLDXMENU_TARGET="really-oldXMenu"
17231 else
17232 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17233 OLDXMENU_TARGET="really-lwlib"
17238 ## The X Menu stuff is present in the X10 distribution, but missing
17239 ## from X11. If we have X10, just use the installed library;
17240 ## otherwise, use our own copy.
17241 if test "${HAVE_X11}" = "yes" ; then
17243 $as_echo "#define HAVE_X11 1" >>confdefs.h
17246 if test "$USE_X_TOOLKIT" = "none"; then
17247 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17248 else
17249 OLDXMENU="\${lwlibdir}/liblw.a"
17251 LIBXMENU="\$(OLDXMENU)"
17252 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17253 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17254 else
17255 ## For a syntactically valid Makefile; not actually used for anything.
17256 ## See comments in src/Makefile.in.
17257 OLDXMENU=nothing
17258 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17259 if test "${HAVE_X_WINDOWS}" = "yes"; then
17260 LIBXMENU="-lXMenu"
17261 else
17262 LIBXMENU=
17264 LIBX_OTHER=
17265 OLDXMENU_DEPS=
17268 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17269 OLDXMENU_TARGET=
17270 OLDXMENU=nothing
17271 LIBXMENU=
17272 OLDXMENU_DEPS=
17281 if test "${HAVE_MENUS}" = "yes" ; then
17283 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17287 if test "${GNU_MALLOC}" = "yes" ; then
17289 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17293 RALLOC_OBJ=
17294 if test "${REL_ALLOC}" = "yes" ; then
17296 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17299 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17303 if test "$opsys" = "cygwin"; then
17304 CYGWIN_OBJ="sheap.o cygw32.o"
17305 ## Cygwin differs because of its unexec().
17306 PRE_ALLOC_OBJ=
17307 POST_ALLOC_OBJ=lastfile.o
17308 elif test "$opsys" = "mingw32"; then
17309 CYGWIN_OBJ=
17310 PRE_ALLOC_OBJ=
17311 POST_ALLOC_OBJ=lastfile.o
17312 else
17313 CYGWIN_OBJ=
17314 PRE_ALLOC_OBJ=lastfile.o
17315 POST_ALLOC_OBJ=
17321 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17322 # it temporarily reverts them to their pre-pkg-config values,
17323 # because gnulib needs to work with both src (which uses the
17324 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17325 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17326 # and it therefore needs to run in an environment where LIBS does not
17327 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17328 # for some package unrelated to lib-src.
17329 SAVE_CFLAGS=$CFLAGS
17330 SAVE_LIBS=$LIBS
17331 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17332 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17344 LIBC_FATAL_STDERR_=1
17345 export LIBC_FATAL_STDERR_
17347 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17348 # for constant arguments. Useless!
17349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17350 $as_echo_n "checking for working alloca.h... " >&6; }
17351 if test "${ac_cv_working_alloca_h+set}" = set; then :
17352 $as_echo_n "(cached) " >&6
17353 else
17354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17355 /* end confdefs.h. */
17356 #include <alloca.h>
17358 main ()
17360 char *p = (char *) alloca (2 * sizeof (int));
17361 if (p) return 0;
17363 return 0;
17365 _ACEOF
17366 if ac_fn_c_try_link "$LINENO"; then :
17367 ac_cv_working_alloca_h=yes
17368 else
17369 ac_cv_working_alloca_h=no
17371 rm -f core conftest.err conftest.$ac_objext \
17372 conftest$ac_exeext conftest.$ac_ext
17374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17375 $as_echo "$ac_cv_working_alloca_h" >&6; }
17376 if test $ac_cv_working_alloca_h = yes; then
17378 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17383 $as_echo_n "checking for alloca... " >&6; }
17384 if test "${ac_cv_func_alloca_works+set}" = set; then :
17385 $as_echo_n "(cached) " >&6
17386 else
17387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17388 /* end confdefs.h. */
17389 #ifdef __GNUC__
17390 # define alloca __builtin_alloca
17391 #else
17392 # ifdef _MSC_VER
17393 # include <malloc.h>
17394 # define alloca _alloca
17395 # else
17396 # ifdef HAVE_ALLOCA_H
17397 # include <alloca.h>
17398 # else
17399 # ifdef _AIX
17400 #pragma alloca
17401 # else
17402 # ifndef alloca /* predefined by HP cc +Olibcalls */
17403 char *alloca ();
17404 # endif
17405 # endif
17406 # endif
17407 # endif
17408 #endif
17411 main ()
17413 char *p = (char *) alloca (1);
17414 if (p) return 0;
17416 return 0;
17418 _ACEOF
17419 if ac_fn_c_try_link "$LINENO"; then :
17420 ac_cv_func_alloca_works=yes
17421 else
17422 ac_cv_func_alloca_works=no
17424 rm -f core conftest.err conftest.$ac_objext \
17425 conftest$ac_exeext conftest.$ac_ext
17427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17428 $as_echo "$ac_cv_func_alloca_works" >&6; }
17430 if test $ac_cv_func_alloca_works = yes; then
17432 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17434 else
17435 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17436 # that cause trouble. Some versions do not even contain alloca or
17437 # contain a buggy version. If you still want to use their alloca,
17438 # use ar to extract alloca.o from them instead of compiling alloca.c.
17444 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17446 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17450 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17451 if test "${ac_cv_os_cray+set}" = set; then :
17452 $as_echo_n "(cached) " >&6
17453 else
17454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17455 /* end confdefs.h. */
17456 #if defined CRAY && ! defined CRAY2
17457 webecray
17458 #else
17459 wenotbecray
17460 #endif
17462 _ACEOF
17463 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17464 $EGREP "webecray" >/dev/null 2>&1; then :
17465 ac_cv_os_cray=yes
17466 else
17467 ac_cv_os_cray=no
17469 rm -f conftest*
17472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17473 $as_echo "$ac_cv_os_cray" >&6; }
17474 if test $ac_cv_os_cray = yes; then
17475 for ac_func in _getb67 GETB67 getb67; do
17476 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17477 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17478 eval as_val=\$$as_ac_var
17479 if test "x$as_val" = x""yes; then :
17481 cat >>confdefs.h <<_ACEOF
17482 #define CRAY_STACKSEG_END $ac_func
17483 _ACEOF
17485 break
17488 done
17491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17492 $as_echo_n "checking stack direction for C alloca... " >&6; }
17493 if test "${ac_cv_c_stack_direction+set}" = set; then :
17494 $as_echo_n "(cached) " >&6
17495 else
17496 if test "$cross_compiling" = yes; then :
17497 ac_cv_c_stack_direction=0
17498 else
17499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17500 /* end confdefs.h. */
17501 $ac_includes_default
17503 find_stack_direction (int *addr, int depth)
17505 int dir, dummy = 0;
17506 if (! addr)
17507 addr = &dummy;
17508 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17509 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17510 return dir + dummy;
17514 main (int argc, char **argv)
17516 return find_stack_direction (0, argc + !argv + 20) < 0;
17518 _ACEOF
17519 if ac_fn_c_try_run "$LINENO"; then :
17520 ac_cv_c_stack_direction=1
17521 else
17522 ac_cv_c_stack_direction=-1
17524 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17525 conftest.$ac_objext conftest.beam conftest.$ac_ext
17529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17530 $as_echo "$ac_cv_c_stack_direction" >&6; }
17531 cat >>confdefs.h <<_ACEOF
17532 #define STACK_DIRECTION $ac_cv_c_stack_direction
17533 _ACEOF
17541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17542 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17543 if test "${ac_cv_c_bigendian+set}" = set; then :
17544 $as_echo_n "(cached) " >&6
17545 else
17546 ac_cv_c_bigendian=unknown
17547 # See if we're dealing with a universal compiler.
17548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17549 /* end confdefs.h. */
17550 #ifndef __APPLE_CC__
17551 not a universal capable compiler
17552 #endif
17553 typedef int dummy;
17555 _ACEOF
17556 if ac_fn_c_try_compile "$LINENO"; then :
17558 # Check for potential -arch flags. It is not universal unless
17559 # there are at least two -arch flags with different values.
17560 ac_arch=
17561 ac_prev=
17562 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17563 if test -n "$ac_prev"; then
17564 case $ac_word in
17565 i?86 | x86_64 | ppc | ppc64)
17566 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17567 ac_arch=$ac_word
17568 else
17569 ac_cv_c_bigendian=universal
17570 break
17573 esac
17574 ac_prev=
17575 elif test "x$ac_word" = "x-arch"; then
17576 ac_prev=arch
17578 done
17580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17581 if test $ac_cv_c_bigendian = unknown; then
17582 # See if sys/param.h defines the BYTE_ORDER macro.
17583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17584 /* end confdefs.h. */
17585 #include <sys/types.h>
17586 #include <sys/param.h>
17589 main ()
17591 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17592 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17593 && LITTLE_ENDIAN)
17594 bogus endian macros
17595 #endif
17598 return 0;
17600 _ACEOF
17601 if ac_fn_c_try_compile "$LINENO"; then :
17602 # It does; now see whether it defined to BIG_ENDIAN or not.
17603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17604 /* end confdefs.h. */
17605 #include <sys/types.h>
17606 #include <sys/param.h>
17609 main ()
17611 #if BYTE_ORDER != BIG_ENDIAN
17612 not big endian
17613 #endif
17616 return 0;
17618 _ACEOF
17619 if ac_fn_c_try_compile "$LINENO"; then :
17620 ac_cv_c_bigendian=yes
17621 else
17622 ac_cv_c_bigendian=no
17624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17628 if test $ac_cv_c_bigendian = unknown; then
17629 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
17630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17631 /* end confdefs.h. */
17632 #include <limits.h>
17635 main ()
17637 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
17638 bogus endian macros
17639 #endif
17642 return 0;
17644 _ACEOF
17645 if ac_fn_c_try_compile "$LINENO"; then :
17646 # It does; now see whether it defined to _BIG_ENDIAN or not.
17647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17648 /* end confdefs.h. */
17649 #include <limits.h>
17652 main ()
17654 #ifndef _BIG_ENDIAN
17655 not big endian
17656 #endif
17659 return 0;
17661 _ACEOF
17662 if ac_fn_c_try_compile "$LINENO"; then :
17663 ac_cv_c_bigendian=yes
17664 else
17665 ac_cv_c_bigendian=no
17667 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17671 if test $ac_cv_c_bigendian = unknown; then
17672 # Compile a test program.
17673 if test "$cross_compiling" = yes; then :
17674 # Try to guess by grepping values from an object file.
17675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17676 /* end confdefs.h. */
17677 short int ascii_mm[] =
17678 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
17679 short int ascii_ii[] =
17680 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17681 int use_ascii (int i) {
17682 return ascii_mm[i] + ascii_ii[i];
17684 short int ebcdic_ii[] =
17685 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
17686 short int ebcdic_mm[] =
17687 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17688 int use_ebcdic (int i) {
17689 return ebcdic_mm[i] + ebcdic_ii[i];
17691 extern int foo;
17694 main ()
17696 return use_ascii (foo) == use_ebcdic (foo);
17698 return 0;
17700 _ACEOF
17701 if ac_fn_c_try_compile "$LINENO"; then :
17702 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
17703 ac_cv_c_bigendian=yes
17705 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
17706 if test "$ac_cv_c_bigendian" = unknown; then
17707 ac_cv_c_bigendian=no
17708 else
17709 # finding both strings is unlikely to happen, but who knows?
17710 ac_cv_c_bigendian=unknown
17714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17715 else
17716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17717 /* end confdefs.h. */
17718 $ac_includes_default
17720 main ()
17723 /* Are we little or big endian? From Harbison&Steele. */
17724 union
17726 long int l;
17727 char c[sizeof (long int)];
17728 } u;
17729 u.l = 1;
17730 return u.c[sizeof (long int) - 1] == 1;
17733 return 0;
17735 _ACEOF
17736 if ac_fn_c_try_run "$LINENO"; then :
17737 ac_cv_c_bigendian=no
17738 else
17739 ac_cv_c_bigendian=yes
17741 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17742 conftest.$ac_objext conftest.beam conftest.$ac_ext
17747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
17748 $as_echo "$ac_cv_c_bigendian" >&6; }
17749 case $ac_cv_c_bigendian in #(
17750 yes)
17751 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
17752 ;; #(
17754 ;; #(
17755 universal)
17757 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
17759 ;; #(
17761 as_fn_error "unknown endianness
17762 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
17763 esac
17767 GNULIB_CHDIR=0;
17768 GNULIB_CHOWN=0;
17769 GNULIB_CLOSE=0;
17770 GNULIB_DUP=0;
17771 GNULIB_DUP2=0;
17772 GNULIB_DUP3=0;
17773 GNULIB_ENVIRON=0;
17774 GNULIB_EUIDACCESS=0;
17775 GNULIB_FACCESSAT=0;
17776 GNULIB_FCHDIR=0;
17777 GNULIB_FCHOWNAT=0;
17778 GNULIB_FDATASYNC=0;
17779 GNULIB_FSYNC=0;
17780 GNULIB_FTRUNCATE=0;
17781 GNULIB_GETCWD=0;
17782 GNULIB_GETDOMAINNAME=0;
17783 GNULIB_GETDTABLESIZE=0;
17784 GNULIB_GETGROUPS=0;
17785 GNULIB_GETHOSTNAME=0;
17786 GNULIB_GETLOGIN=0;
17787 GNULIB_GETLOGIN_R=0;
17788 GNULIB_GETPAGESIZE=0;
17789 GNULIB_GETUSERSHELL=0;
17790 GNULIB_GROUP_MEMBER=0;
17791 GNULIB_ISATTY=0;
17792 GNULIB_LCHOWN=0;
17793 GNULIB_LINK=0;
17794 GNULIB_LINKAT=0;
17795 GNULIB_LSEEK=0;
17796 GNULIB_PIPE=0;
17797 GNULIB_PIPE2=0;
17798 GNULIB_PREAD=0;
17799 GNULIB_PWRITE=0;
17800 GNULIB_READ=0;
17801 GNULIB_READLINK=0;
17802 GNULIB_READLINKAT=0;
17803 GNULIB_RMDIR=0;
17804 GNULIB_SETHOSTNAME=0;
17805 GNULIB_SLEEP=0;
17806 GNULIB_SYMLINK=0;
17807 GNULIB_SYMLINKAT=0;
17808 GNULIB_TTYNAME_R=0;
17809 GNULIB_UNISTD_H_NONBLOCKING=0;
17810 GNULIB_UNISTD_H_SIGPIPE=0;
17811 GNULIB_UNLINK=0;
17812 GNULIB_UNLINKAT=0;
17813 GNULIB_USLEEP=0;
17814 GNULIB_WRITE=0;
17815 HAVE_CHOWN=1;
17816 HAVE_DUP2=1;
17817 HAVE_DUP3=1;
17818 HAVE_EUIDACCESS=1;
17819 HAVE_FACCESSAT=1;
17820 HAVE_FCHDIR=1;
17821 HAVE_FCHOWNAT=1;
17822 HAVE_FDATASYNC=1;
17823 HAVE_FSYNC=1;
17824 HAVE_FTRUNCATE=1;
17825 HAVE_GETDTABLESIZE=1;
17826 HAVE_GETGROUPS=1;
17827 HAVE_GETHOSTNAME=1;
17828 HAVE_GETLOGIN=1;
17829 HAVE_GETPAGESIZE=1;
17830 HAVE_GROUP_MEMBER=1;
17831 HAVE_LCHOWN=1;
17832 HAVE_LINK=1;
17833 HAVE_LINKAT=1;
17834 HAVE_PIPE=1;
17835 HAVE_PIPE2=1;
17836 HAVE_PREAD=1;
17837 HAVE_PWRITE=1;
17838 HAVE_READLINK=1;
17839 HAVE_READLINKAT=1;
17840 HAVE_SETHOSTNAME=1;
17841 HAVE_SLEEP=1;
17842 HAVE_SYMLINK=1;
17843 HAVE_SYMLINKAT=1;
17844 HAVE_UNLINKAT=1;
17845 HAVE_USLEEP=1;
17846 HAVE_DECL_ENVIRON=1;
17847 HAVE_DECL_FCHDIR=1;
17848 HAVE_DECL_FDATASYNC=1;
17849 HAVE_DECL_GETDOMAINNAME=1;
17850 HAVE_DECL_GETLOGIN_R=1;
17851 HAVE_DECL_GETPAGESIZE=1;
17852 HAVE_DECL_GETUSERSHELL=1;
17853 HAVE_DECL_SETHOSTNAME=1;
17854 HAVE_DECL_TTYNAME_R=1;
17855 HAVE_OS_H=0;
17856 HAVE_SYS_PARAM_H=0;
17857 REPLACE_CHOWN=0;
17858 REPLACE_CLOSE=0;
17859 REPLACE_DUP=0;
17860 REPLACE_DUP2=0;
17861 REPLACE_FCHOWNAT=0;
17862 REPLACE_FTRUNCATE=0;
17863 REPLACE_GETCWD=0;
17864 REPLACE_GETDOMAINNAME=0;
17865 REPLACE_GETLOGIN_R=0;
17866 REPLACE_GETGROUPS=0;
17867 REPLACE_GETPAGESIZE=0;
17868 REPLACE_ISATTY=0;
17869 REPLACE_LCHOWN=0;
17870 REPLACE_LINK=0;
17871 REPLACE_LINKAT=0;
17872 REPLACE_LSEEK=0;
17873 REPLACE_PREAD=0;
17874 REPLACE_PWRITE=0;
17875 REPLACE_READ=0;
17876 REPLACE_READLINK=0;
17877 REPLACE_RMDIR=0;
17878 REPLACE_SLEEP=0;
17879 REPLACE_SYMLINK=0;
17880 REPLACE_TTYNAME_R=0;
17881 REPLACE_UNLINK=0;
17882 REPLACE_UNLINKAT=0;
17883 REPLACE_USLEEP=0;
17884 REPLACE_WRITE=0;
17885 UNISTD_H_HAVE_WINSOCK2_H=0;
17886 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
17890 GNULIB_OPENDIR=0;
17891 GNULIB_READDIR=0;
17892 GNULIB_REWINDDIR=0;
17893 GNULIB_CLOSEDIR=0;
17894 GNULIB_DIRFD=0;
17895 GNULIB_FDOPENDIR=0;
17896 GNULIB_SCANDIR=0;
17897 GNULIB_ALPHASORT=0;
17898 HAVE_OPENDIR=1;
17899 HAVE_READDIR=1;
17900 HAVE_REWINDDIR=1;
17901 HAVE_CLOSEDIR=1;
17902 HAVE_DECL_DIRFD=1;
17903 HAVE_DECL_FDOPENDIR=1;
17904 HAVE_FDOPENDIR=1;
17905 HAVE_SCANDIR=1;
17906 HAVE_ALPHASORT=1;
17907 REPLACE_OPENDIR=0;
17908 REPLACE_CLOSEDIR=0;
17909 REPLACE_DIRFD=0;
17910 REPLACE_FDOPENDIR=0;
17914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
17915 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
17916 if test "${gl_cv_have_include_next+set}" = set; then :
17917 $as_echo_n "(cached) " >&6
17918 else
17919 rm -rf conftestd1a conftestd1b conftestd2
17920 mkdir conftestd1a conftestd1b conftestd2
17921 cat <<EOF > conftestd1a/conftest.h
17922 #define DEFINED_IN_CONFTESTD1
17923 #include_next <conftest.h>
17924 #ifdef DEFINED_IN_CONFTESTD2
17925 int foo;
17926 #else
17927 #error "include_next doesn't work"
17928 #endif
17930 cat <<EOF > conftestd1b/conftest.h
17931 #define DEFINED_IN_CONFTESTD1
17932 #include <stdio.h>
17933 #include_next <conftest.h>
17934 #ifdef DEFINED_IN_CONFTESTD2
17935 int foo;
17936 #else
17937 #error "include_next doesn't work"
17938 #endif
17940 cat <<EOF > conftestd2/conftest.h
17941 #ifndef DEFINED_IN_CONFTESTD1
17942 #error "include_next test doesn't work"
17943 #endif
17944 #define DEFINED_IN_CONFTESTD2
17946 gl_save_CPPFLAGS="$CPPFLAGS"
17947 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
17948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17949 /* end confdefs.h. */
17950 #include <conftest.h>
17951 _ACEOF
17952 if ac_fn_c_try_compile "$LINENO"; then :
17953 gl_cv_have_include_next=yes
17954 else
17955 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
17956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17957 /* end confdefs.h. */
17958 #include <conftest.h>
17959 _ACEOF
17960 if ac_fn_c_try_compile "$LINENO"; then :
17961 gl_cv_have_include_next=buggy
17962 else
17963 gl_cv_have_include_next=no
17965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17969 CPPFLAGS="$gl_save_CPPFLAGS"
17970 rm -rf conftestd1a conftestd1b conftestd2
17973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
17974 $as_echo "$gl_cv_have_include_next" >&6; }
17975 PRAGMA_SYSTEM_HEADER=
17976 if test $gl_cv_have_include_next = yes; then
17977 INCLUDE_NEXT=include_next
17978 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17979 if test -n "$GCC"; then
17980 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
17982 else
17983 if test $gl_cv_have_include_next = buggy; then
17984 INCLUDE_NEXT=include
17985 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
17986 else
17987 INCLUDE_NEXT=include
17988 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
17994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
17995 $as_echo_n "checking whether system header files limit the line length... " >&6; }
17996 if test "${gl_cv_pragma_columns+set}" = set; then :
17997 $as_echo_n "(cached) " >&6
17998 else
17999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18000 /* end confdefs.h. */
18002 #ifdef __TANDEM
18003 choke me
18004 #endif
18006 _ACEOF
18007 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18008 $EGREP "choke me" >/dev/null 2>&1; then :
18009 gl_cv_pragma_columns=yes
18010 else
18011 gl_cv_pragma_columns=no
18013 rm -f conftest*
18017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
18018 $as_echo "$gl_cv_pragma_columns" >&6; }
18019 if test $gl_cv_pragma_columns = yes; then
18020 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
18021 else
18022 PRAGMA_COLUMNS=
18029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
18030 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
18031 if test "${gl_cv_func_c99_strtold+set}" = set; then :
18032 $as_echo_n "(cached) " >&6
18033 else
18034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18035 /* end confdefs.h. */
18036 /* On HP-UX before 11.23, strtold returns a struct instead of
18037 long double. Reject implementations like that, by requiring
18038 compatibility with the C99 prototype. */
18039 #include <stdlib.h>
18040 static long double (*p) (char const *, char **) = strtold;
18041 static long double
18042 test (char const *nptr, char **endptr)
18044 long double r;
18045 r = strtold (nptr, endptr);
18046 return r;
18049 main ()
18051 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
18053 return 0;
18055 _ACEOF
18056 if ac_fn_c_try_link "$LINENO"; then :
18057 gl_cv_func_c99_strtold=yes
18058 else
18059 gl_cv_func_c99_strtold=no
18061 rm -f core conftest.err conftest.$ac_objext \
18062 conftest$ac_exeext conftest.$ac_ext
18064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
18065 $as_echo "$gl_cv_func_c99_strtold" >&6; }
18066 if test $gl_cv_func_c99_strtold = yes; then
18068 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18080 $as_echo_n "checking if environ is properly declared... " >&6; }
18081 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18082 $as_echo_n "(cached) " >&6
18083 else
18085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18086 /* end confdefs.h. */
18087 #if HAVE_UNISTD_H
18088 #include <unistd.h>
18089 #endif
18090 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18091 #include <stdlib.h>
18093 extern struct { int foo; } environ;
18095 main ()
18097 environ.foo = 1;
18099 return 0;
18101 _ACEOF
18102 if ac_fn_c_try_compile "$LINENO"; then :
18103 gt_cv_var_environ_declaration=no
18104 else
18105 gt_cv_var_environ_declaration=yes
18107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18111 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18112 if test $gt_cv_var_environ_declaration = yes; then
18114 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18119 if test $gt_cv_var_environ_declaration != yes; then
18120 HAVE_DECL_ENVIRON=0
18125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18126 $as_echo_n "checking for complete errno.h... " >&6; }
18127 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18128 $as_echo_n "(cached) " >&6
18129 else
18131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18132 /* end confdefs.h. */
18134 #include <errno.h>
18135 #if !defined ETXTBSY
18136 booboo
18137 #endif
18138 #if !defined ENOMSG
18139 booboo
18140 #endif
18141 #if !defined EIDRM
18142 booboo
18143 #endif
18144 #if !defined ENOLINK
18145 booboo
18146 #endif
18147 #if !defined EPROTO
18148 booboo
18149 #endif
18150 #if !defined EMULTIHOP
18151 booboo
18152 #endif
18153 #if !defined EBADMSG
18154 booboo
18155 #endif
18156 #if !defined EOVERFLOW
18157 booboo
18158 #endif
18159 #if !defined ENOTSUP
18160 booboo
18161 #endif
18162 #if !defined ENETRESET
18163 booboo
18164 #endif
18165 #if !defined ECONNABORTED
18166 booboo
18167 #endif
18168 #if !defined ESTALE
18169 booboo
18170 #endif
18171 #if !defined EDQUOT
18172 booboo
18173 #endif
18174 #if !defined ECANCELED
18175 booboo
18176 #endif
18177 #if !defined EOWNERDEAD
18178 booboo
18179 #endif
18180 #if !defined ENOTRECOVERABLE
18181 booboo
18182 #endif
18183 #if !defined EILSEQ
18184 booboo
18185 #endif
18187 _ACEOF
18188 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18189 $EGREP "booboo" >/dev/null 2>&1; then :
18190 gl_cv_header_errno_h_complete=no
18191 else
18192 gl_cv_header_errno_h_complete=yes
18194 rm -f conftest*
18198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18199 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18200 if test $gl_cv_header_errno_h_complete = yes; then
18201 ERRNO_H=''
18202 else
18211 if test $gl_cv_have_include_next = yes; then
18212 gl_cv_next_errno_h='<'errno.h'>'
18213 else
18214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18215 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18216 if test "${gl_cv_next_errno_h+set}" = set; then :
18217 $as_echo_n "(cached) " >&6
18218 else
18220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18221 /* end confdefs.h. */
18222 #include <errno.h>
18224 _ACEOF
18225 case "$host_os" in
18226 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18227 *) gl_absname_cpp="$ac_cpp" ;;
18228 esac
18230 case "$host_os" in
18231 mingw*)
18232 gl_dirsep_regex='[/\\]'
18235 gl_dirsep_regex='\/'
18237 esac
18238 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18240 gl_header_literal_regex=`echo 'errno.h' \
18241 | sed -e "$gl_make_literal_regex_sed"`
18242 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18243 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18244 s|^/[^/]|//&|
18248 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18249 sed -n "$gl_absolute_header_sed"`'"'
18253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18254 $as_echo "$gl_cv_next_errno_h" >&6; }
18256 NEXT_ERRNO_H=$gl_cv_next_errno_h
18258 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18259 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18260 gl_next_as_first_directive='<'errno.h'>'
18261 else
18262 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18263 gl_next_as_first_directive=$gl_cv_next_errno_h
18265 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18270 ERRNO_H='errno.h'
18273 if test -n "$ERRNO_H"; then
18274 GL_GENERATE_ERRNO_H_TRUE=
18275 GL_GENERATE_ERRNO_H_FALSE='#'
18276 else
18277 GL_GENERATE_ERRNO_H_TRUE='#'
18278 GL_GENERATE_ERRNO_H_FALSE=
18282 if test -n "$ERRNO_H"; then
18283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18284 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18285 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18286 $as_echo_n "(cached) " >&6
18287 else
18289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18290 /* end confdefs.h. */
18292 #include <errno.h>
18293 #ifdef EMULTIHOP
18295 #endif
18297 _ACEOF
18298 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18299 $EGREP "yes" >/dev/null 2>&1; then :
18300 gl_cv_header_errno_h_EMULTIHOP=yes
18301 else
18302 gl_cv_header_errno_h_EMULTIHOP=no
18304 rm -f conftest*
18306 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18307 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18308 /* end confdefs.h. */
18310 #define _XOPEN_SOURCE_EXTENDED 1
18311 #include <errno.h>
18312 #ifdef EMULTIHOP
18314 #endif
18316 _ACEOF
18317 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18318 $EGREP "yes" >/dev/null 2>&1; then :
18319 gl_cv_header_errno_h_EMULTIHOP=hidden
18321 rm -f conftest*
18323 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18324 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18325 #define _XOPEN_SOURCE_EXTENDED 1
18326 #include <errno.h>
18327 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18328 #include <stdio.h>
18329 #include <stdlib.h>
18330 "; then :
18338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18339 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18340 case $gl_cv_header_errno_h_EMULTIHOP in
18341 yes | no)
18342 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18345 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18347 esac
18353 if test -n "$ERRNO_H"; then
18354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18355 $as_echo_n "checking for ENOLINK value... " >&6; }
18356 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18357 $as_echo_n "(cached) " >&6
18358 else
18360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18361 /* end confdefs.h. */
18363 #include <errno.h>
18364 #ifdef ENOLINK
18366 #endif
18368 _ACEOF
18369 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18370 $EGREP "yes" >/dev/null 2>&1; then :
18371 gl_cv_header_errno_h_ENOLINK=yes
18372 else
18373 gl_cv_header_errno_h_ENOLINK=no
18375 rm -f conftest*
18377 if test $gl_cv_header_errno_h_ENOLINK = no; then
18378 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18379 /* end confdefs.h. */
18381 #define _XOPEN_SOURCE_EXTENDED 1
18382 #include <errno.h>
18383 #ifdef ENOLINK
18385 #endif
18387 _ACEOF
18388 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18389 $EGREP "yes" >/dev/null 2>&1; then :
18390 gl_cv_header_errno_h_ENOLINK=hidden
18392 rm -f conftest*
18394 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18395 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18396 #define _XOPEN_SOURCE_EXTENDED 1
18397 #include <errno.h>
18398 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18399 #include <stdio.h>
18400 #include <stdlib.h>
18401 "; then :
18409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18410 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18411 case $gl_cv_header_errno_h_ENOLINK in
18412 yes | no)
18413 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18416 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18418 esac
18424 if test -n "$ERRNO_H"; then
18425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18426 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18427 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18428 $as_echo_n "(cached) " >&6
18429 else
18431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18432 /* end confdefs.h. */
18434 #include <errno.h>
18435 #ifdef EOVERFLOW
18437 #endif
18439 _ACEOF
18440 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18441 $EGREP "yes" >/dev/null 2>&1; then :
18442 gl_cv_header_errno_h_EOVERFLOW=yes
18443 else
18444 gl_cv_header_errno_h_EOVERFLOW=no
18446 rm -f conftest*
18448 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18450 /* end confdefs.h. */
18452 #define _XOPEN_SOURCE_EXTENDED 1
18453 #include <errno.h>
18454 #ifdef EOVERFLOW
18456 #endif
18458 _ACEOF
18459 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18460 $EGREP "yes" >/dev/null 2>&1; then :
18461 gl_cv_header_errno_h_EOVERFLOW=hidden
18463 rm -f conftest*
18465 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18466 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18467 #define _XOPEN_SOURCE_EXTENDED 1
18468 #include <errno.h>
18469 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18470 #include <stdio.h>
18471 #include <stdlib.h>
18472 "; then :
18480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18481 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18482 case $gl_cv_header_errno_h_EOVERFLOW in
18483 yes | no)
18484 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18487 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18489 esac
18503 GNULIB_FCNTL=0;
18504 GNULIB_NONBLOCKING=0;
18505 GNULIB_OPEN=0;
18506 GNULIB_OPENAT=0;
18507 HAVE_FCNTL=1;
18508 HAVE_OPENAT=1;
18509 REPLACE_FCNTL=0;
18510 REPLACE_OPEN=0;
18511 REPLACE_OPENAT=0;
18514 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18515 if test "x$ac_cv_type_mode_t" = x""yes; then :
18517 else
18519 cat >>confdefs.h <<_ACEOF
18520 #define mode_t int
18521 _ACEOF
18525 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18526 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18527 ac_have_decl=1
18528 else
18529 ac_have_decl=0
18532 cat >>confdefs.h <<_ACEOF
18533 #define HAVE_DECL_FDATASYNC $ac_have_decl
18534 _ACEOF
18538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18539 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18540 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18541 $as_echo_n "(cached) " >&6
18542 else
18543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18544 /* end confdefs.h. */
18546 #include <sys/types.h>
18547 #include <sys/stat.h>
18549 main ()
18551 struct stat s; s.st_dm_mode;
18553 return 0;
18555 _ACEOF
18556 if ac_fn_c_try_compile "$LINENO"; then :
18557 ac_cv_struct_st_dm_mode=yes
18558 else
18559 ac_cv_struct_st_dm_mode=no
18561 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
18564 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
18566 if test $ac_cv_struct_st_dm_mode = yes; then
18568 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
18573 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
18574 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
18575 ac_have_decl=1
18576 else
18577 ac_have_decl=0
18580 cat >>confdefs.h <<_ACEOF
18581 #define HAVE_DECL_STRMODE $ac_have_decl
18582 _ACEOF
18589 GNULIB_FCHMODAT=0;
18590 GNULIB_FSTAT=0;
18591 GNULIB_FSTATAT=0;
18592 GNULIB_FUTIMENS=0;
18593 GNULIB_LCHMOD=0;
18594 GNULIB_LSTAT=0;
18595 GNULIB_MKDIRAT=0;
18596 GNULIB_MKFIFO=0;
18597 GNULIB_MKFIFOAT=0;
18598 GNULIB_MKNOD=0;
18599 GNULIB_MKNODAT=0;
18600 GNULIB_STAT=0;
18601 GNULIB_UTIMENSAT=0;
18602 HAVE_FCHMODAT=1;
18603 HAVE_FSTATAT=1;
18604 HAVE_FUTIMENS=1;
18605 HAVE_LCHMOD=1;
18606 HAVE_LSTAT=1;
18607 HAVE_MKDIRAT=1;
18608 HAVE_MKFIFO=1;
18609 HAVE_MKFIFOAT=1;
18610 HAVE_MKNOD=1;
18611 HAVE_MKNODAT=1;
18612 HAVE_UTIMENSAT=1;
18613 REPLACE_FSTAT=0;
18614 REPLACE_FSTATAT=0;
18615 REPLACE_FUTIMENS=0;
18616 REPLACE_LSTAT=0;
18617 REPLACE_MKDIR=0;
18618 REPLACE_MKFIFO=0;
18619 REPLACE_MKNOD=0;
18620 REPLACE_STAT=0;
18621 REPLACE_UTIMENSAT=0;
18624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18625 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18626 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18627 $as_echo_n "(cached) " >&6
18628 else
18629 rm -f conftest.sym conftest.file
18630 echo >conftest.file
18631 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18632 if test "$cross_compiling" = yes; then :
18633 case "$host_os" in
18634 # Guess yes on glibc systems.
18635 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18636 # If we don't know, assume the worst.
18637 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18638 esac
18640 else
18641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18642 /* end confdefs.h. */
18643 $ac_includes_default
18645 main ()
18647 struct stat sbuf;
18648 /* Linux will dereference the symlink and fail, as required by
18649 POSIX. That is better in the sense that it means we will not
18650 have to compile and use the lstat wrapper. */
18651 return lstat ("conftest.sym/", &sbuf) == 0;
18654 return 0;
18656 _ACEOF
18657 if ac_fn_c_try_run "$LINENO"; then :
18658 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18659 else
18660 gl_cv_func_lstat_dereferences_slashed_symlink=no
18662 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18663 conftest.$ac_objext conftest.beam conftest.$ac_ext
18666 else
18667 # If the 'ln -s' command failed, then we probably don't even
18668 # have an lstat function.
18669 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18671 rm -f conftest.sym conftest.file
18674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18675 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18676 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18677 *yes)
18679 cat >>confdefs.h <<_ACEOF
18680 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18681 _ACEOF
18684 esac
18691 GNULIB__EXIT=0;
18692 GNULIB_ATOLL=0;
18693 GNULIB_CALLOC_POSIX=0;
18694 GNULIB_CANONICALIZE_FILE_NAME=0;
18695 GNULIB_GETLOADAVG=0;
18696 GNULIB_GETSUBOPT=0;
18697 GNULIB_GRANTPT=0;
18698 GNULIB_MALLOC_POSIX=0;
18699 GNULIB_MBTOWC=0;
18700 GNULIB_MKDTEMP=0;
18701 GNULIB_MKOSTEMP=0;
18702 GNULIB_MKOSTEMPS=0;
18703 GNULIB_MKSTEMP=0;
18704 GNULIB_MKSTEMPS=0;
18705 GNULIB_POSIX_OPENPT=0;
18706 GNULIB_PTSNAME=0;
18707 GNULIB_PTSNAME_R=0;
18708 GNULIB_PUTENV=0;
18709 GNULIB_RANDOM=0;
18710 GNULIB_RANDOM_R=0;
18711 GNULIB_REALLOC_POSIX=0;
18712 GNULIB_REALPATH=0;
18713 GNULIB_RPMATCH=0;
18714 GNULIB_SECURE_GETENV=0;
18715 GNULIB_SETENV=0;
18716 GNULIB_STRTOD=0;
18717 GNULIB_STRTOLL=0;
18718 GNULIB_STRTOULL=0;
18719 GNULIB_SYSTEM_POSIX=0;
18720 GNULIB_UNLOCKPT=0;
18721 GNULIB_UNSETENV=0;
18722 GNULIB_WCTOMB=0;
18723 HAVE__EXIT=1;
18724 HAVE_ATOLL=1;
18725 HAVE_CANONICALIZE_FILE_NAME=1;
18726 HAVE_DECL_GETLOADAVG=1;
18727 HAVE_GETSUBOPT=1;
18728 HAVE_GRANTPT=1;
18729 HAVE_MKDTEMP=1;
18730 HAVE_MKOSTEMP=1;
18731 HAVE_MKOSTEMPS=1;
18732 HAVE_MKSTEMP=1;
18733 HAVE_MKSTEMPS=1;
18734 HAVE_POSIX_OPENPT=1;
18735 HAVE_PTSNAME=1;
18736 HAVE_PTSNAME_R=1;
18737 HAVE_RANDOM=1;
18738 HAVE_RANDOM_H=1;
18739 HAVE_RANDOM_R=1;
18740 HAVE_REALPATH=1;
18741 HAVE_RPMATCH=1;
18742 HAVE_SECURE_GETENV=1;
18743 HAVE_SETENV=1;
18744 HAVE_DECL_SETENV=1;
18745 HAVE_STRTOD=1;
18746 HAVE_STRTOLL=1;
18747 HAVE_STRTOULL=1;
18748 HAVE_STRUCT_RANDOM_DATA=1;
18749 HAVE_SYS_LOADAVG_H=0;
18750 HAVE_UNLOCKPT=1;
18751 HAVE_DECL_UNSETENV=1;
18752 REPLACE_CALLOC=0;
18753 REPLACE_CANONICALIZE_FILE_NAME=0;
18754 REPLACE_MALLOC=0;
18755 REPLACE_MBTOWC=0;
18756 REPLACE_MKSTEMP=0;
18757 REPLACE_PTSNAME=0;
18758 REPLACE_PTSNAME_R=0;
18759 REPLACE_PUTENV=0;
18760 REPLACE_RANDOM_R=0;
18761 REPLACE_REALLOC=0;
18762 REPLACE_REALPATH=0;
18763 REPLACE_SETENV=0;
18764 REPLACE_STRTOD=0;
18765 REPLACE_UNSETENV=0;
18766 REPLACE_WCTOMB=0;
18783 if test $gl_cv_have_include_next = yes; then
18784 gl_cv_next_getopt_h='<'getopt.h'>'
18785 else
18786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
18787 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
18788 if test "${gl_cv_next_getopt_h+set}" = set; then :
18789 $as_echo_n "(cached) " >&6
18790 else
18792 if test $ac_cv_header_getopt_h = yes; then
18795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18796 /* end confdefs.h. */
18797 #include <getopt.h>
18799 _ACEOF
18800 case "$host_os" in
18801 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18802 *) gl_absname_cpp="$ac_cpp" ;;
18803 esac
18805 case "$host_os" in
18806 mingw*)
18807 gl_dirsep_regex='[/\\]'
18810 gl_dirsep_regex='\/'
18812 esac
18813 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18815 gl_header_literal_regex=`echo 'getopt.h' \
18816 | sed -e "$gl_make_literal_regex_sed"`
18817 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18818 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18819 s|^/[^/]|//&|
18823 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18824 sed -n "$gl_absolute_header_sed"`'"'
18825 else
18826 gl_cv_next_getopt_h='<'getopt.h'>'
18831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
18832 $as_echo "$gl_cv_next_getopt_h" >&6; }
18834 NEXT_GETOPT_H=$gl_cv_next_getopt_h
18836 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18837 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18838 gl_next_as_first_directive='<'getopt.h'>'
18839 else
18840 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18841 gl_next_as_first_directive=$gl_cv_next_getopt_h
18843 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
18848 if test $ac_cv_header_getopt_h = yes; then
18849 HAVE_GETOPT_H=1
18850 else
18851 HAVE_GETOPT_H=0
18855 gl_replace_getopt=
18857 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18858 for ac_header in getopt.h
18859 do :
18860 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
18861 if test "x$ac_cv_header_getopt_h" = x""yes; then :
18862 cat >>confdefs.h <<_ACEOF
18863 #define HAVE_GETOPT_H 1
18864 _ACEOF
18866 else
18867 gl_replace_getopt=yes
18870 done
18874 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
18875 for ac_func in getopt_long_only
18876 do :
18877 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
18878 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
18879 cat >>confdefs.h <<_ACEOF
18880 #define HAVE_GETOPT_LONG_ONLY 1
18881 _ACEOF
18883 else
18884 gl_replace_getopt=yes
18886 done
18890 if test -z "$gl_replace_getopt"; then
18891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
18892 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
18893 if test "${gl_cv_func_getopt_posix+set}" = set; then :
18894 $as_echo_n "(cached) " >&6
18895 else
18897 if test $cross_compiling = no; then
18898 if test "$cross_compiling" = yes; then :
18899 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18900 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18901 as_fn_error "cannot run test program while cross compiling
18902 See \`config.log' for more details." "$LINENO" 5; }
18903 else
18904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18905 /* end confdefs.h. */
18907 #include <unistd.h>
18908 #include <stdlib.h>
18909 #include <string.h>
18912 main ()
18914 static char program[] = "program";
18915 static char a[] = "-a";
18916 static char foo[] = "foo";
18917 static char bar[] = "bar";
18918 char *argv[] = { program, a, foo, bar, NULL };
18919 int c;
18921 c = getopt (4, argv, "ab");
18922 if (!(c == 'a'))
18923 return 1;
18924 c = getopt (4, argv, "ab");
18925 if (!(c == -1))
18926 return 2;
18927 if (!(optind == 2))
18928 return 3;
18929 return 0;
18932 _ACEOF
18933 if ac_fn_c_try_run "$LINENO"; then :
18934 gl_cv_func_getopt_posix=maybe
18935 else
18936 gl_cv_func_getopt_posix=no
18938 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18939 conftest.$ac_objext conftest.beam conftest.$ac_ext
18942 if test $gl_cv_func_getopt_posix = maybe; then
18943 if test "$cross_compiling" = yes; then :
18944 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18945 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18946 as_fn_error "cannot run test program while cross compiling
18947 See \`config.log' for more details." "$LINENO" 5; }
18948 else
18949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18950 /* end confdefs.h. */
18952 #include <unistd.h>
18953 #include <stdlib.h>
18954 #include <string.h>
18957 main ()
18959 static char program[] = "program";
18960 static char donald[] = "donald";
18961 static char p[] = "-p";
18962 static char billy[] = "billy";
18963 static char duck[] = "duck";
18964 static char a[] = "-a";
18965 static char bar[] = "bar";
18966 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
18967 int c;
18969 c = getopt (7, argv, "+abp:q:");
18970 if (!(c == -1))
18971 return 4;
18972 if (!(strcmp (argv[0], "program") == 0))
18973 return 5;
18974 if (!(strcmp (argv[1], "donald") == 0))
18975 return 6;
18976 if (!(strcmp (argv[2], "-p") == 0))
18977 return 7;
18978 if (!(strcmp (argv[3], "billy") == 0))
18979 return 8;
18980 if (!(strcmp (argv[4], "duck") == 0))
18981 return 9;
18982 if (!(strcmp (argv[5], "-a") == 0))
18983 return 10;
18984 if (!(strcmp (argv[6], "bar") == 0))
18985 return 11;
18986 if (!(optind == 1))
18987 return 12;
18988 return 0;
18991 _ACEOF
18992 if ac_fn_c_try_run "$LINENO"; then :
18993 gl_cv_func_getopt_posix=maybe
18994 else
18995 gl_cv_func_getopt_posix=no
18997 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18998 conftest.$ac_objext conftest.beam conftest.$ac_ext
19002 if test $gl_cv_func_getopt_posix = maybe; then
19003 if test "$cross_compiling" = yes; then :
19004 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19005 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19006 as_fn_error "cannot run test program while cross compiling
19007 See \`config.log' for more details." "$LINENO" 5; }
19008 else
19009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19010 /* end confdefs.h. */
19012 #include <unistd.h>
19013 #include <stdlib.h>
19014 #include <string.h>
19017 main ()
19019 static char program[] = "program";
19020 static char ab[] = "-ab";
19021 char *argv[3] = { program, ab, NULL };
19022 if (getopt (2, argv, "ab:") != 'a')
19023 return 13;
19024 if (getopt (2, argv, "ab:") != '?')
19025 return 14;
19026 if (optopt != 'b')
19027 return 15;
19028 if (optind != 2)
19029 return 16;
19030 return 0;
19033 _ACEOF
19034 if ac_fn_c_try_run "$LINENO"; then :
19035 gl_cv_func_getopt_posix=yes
19036 else
19037 gl_cv_func_getopt_posix=no
19039 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19040 conftest.$ac_objext conftest.beam conftest.$ac_ext
19044 else
19045 case "$host_os" in
19046 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
19047 *) gl_cv_func_getopt_posix="guessing yes";;
19048 esac
19052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
19053 $as_echo "$gl_cv_func_getopt_posix" >&6; }
19054 case "$gl_cv_func_getopt_posix" in
19055 *no) gl_replace_getopt=yes ;;
19056 esac
19059 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
19061 $as_echo_n "checking for working GNU getopt function... " >&6; }
19062 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
19063 $as_echo_n "(cached) " >&6
19064 else
19065 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
19066 # optstring is necessary for programs like m4 that have POSIX-mandated
19067 # semantics for supporting options interspersed with files.
19068 # Also, since getopt_long is a GNU extension, we require optind=0.
19069 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
19070 # so take care to revert to the correct (non-)export state.
19071 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19072 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19073 xx) gl_had_POSIXLY_CORRECT=exported ;;
19074 x) gl_had_POSIXLY_CORRECT=yes ;;
19075 *) gl_had_POSIXLY_CORRECT= ;;
19076 esac
19077 POSIXLY_CORRECT=1
19078 export POSIXLY_CORRECT
19079 if test "$cross_compiling" = yes; then :
19080 gl_cv_func_getopt_gnu="guessing no"
19082 else
19083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19084 /* end confdefs.h. */
19085 #include <getopt.h>
19086 #include <stddef.h>
19087 #include <string.h>
19089 #include <stdlib.h>
19090 #if defined __MACH__ && defined __APPLE__
19091 /* Avoid a crash on Mac OS X. */
19092 #include <mach/mach.h>
19093 #include <mach/mach_error.h>
19094 #include <mach/thread_status.h>
19095 #include <mach/exception.h>
19096 #include <mach/task.h>
19097 #include <pthread.h>
19098 /* The exception port on which our thread listens. */
19099 static mach_port_t our_exception_port;
19100 /* The main function of the thread listening for exceptions of type
19101 EXC_BAD_ACCESS. */
19102 static void *
19103 mach_exception_thread (void *arg)
19105 /* Buffer for a message to be received. */
19106 struct {
19107 mach_msg_header_t head;
19108 mach_msg_body_t msgh_body;
19109 char data[1024];
19110 } msg;
19111 mach_msg_return_t retval;
19112 /* Wait for a message on the exception port. */
19113 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19114 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19115 if (retval != MACH_MSG_SUCCESS)
19116 abort ();
19117 exit (1);
19119 static void
19120 nocrash_init (void)
19122 mach_port_t self = mach_task_self ();
19123 /* Allocate a port on which the thread shall listen for exceptions. */
19124 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19125 == KERN_SUCCESS) {
19126 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19127 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19128 MACH_MSG_TYPE_MAKE_SEND)
19129 == KERN_SUCCESS) {
19130 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19131 for us. */
19132 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19133 /* Create the thread listening on the exception port. */
19134 pthread_attr_t attr;
19135 pthread_t thread;
19136 if (pthread_attr_init (&attr) == 0
19137 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19138 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19139 pthread_attr_destroy (&attr);
19140 /* Replace the exception port info for these exceptions with our own.
19141 Note that we replace the exception port for the entire task, not only
19142 for a particular thread. This has the effect that when our exception
19143 port gets the message, the thread specific exception port has already
19144 been asked, and we don't need to bother about it.
19145 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19146 task_set_exception_ports (self, mask, our_exception_port,
19147 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19152 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19153 /* Avoid a crash on native Windows. */
19154 #define WIN32_LEAN_AND_MEAN
19155 #include <windows.h>
19156 #include <winerror.h>
19157 static LONG WINAPI
19158 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19160 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19162 case EXCEPTION_ACCESS_VIOLATION:
19163 case EXCEPTION_IN_PAGE_ERROR:
19164 case EXCEPTION_STACK_OVERFLOW:
19165 case EXCEPTION_GUARD_PAGE:
19166 case EXCEPTION_PRIV_INSTRUCTION:
19167 case EXCEPTION_ILLEGAL_INSTRUCTION:
19168 case EXCEPTION_DATATYPE_MISALIGNMENT:
19169 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19170 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19171 exit (1);
19173 return EXCEPTION_CONTINUE_SEARCH;
19175 static void
19176 nocrash_init (void)
19178 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19180 #else
19181 /* Avoid a crash on POSIX systems. */
19182 #include <signal.h>
19183 /* A POSIX signal handler. */
19184 static void
19185 exception_handler (int sig)
19187 exit (1);
19189 static void
19190 nocrash_init (void)
19192 #ifdef SIGSEGV
19193 signal (SIGSEGV, exception_handler);
19194 #endif
19195 #ifdef SIGBUS
19196 signal (SIGBUS, exception_handler);
19197 #endif
19199 #endif
19203 main ()
19206 int result = 0;
19208 nocrash_init();
19210 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19211 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19212 OSF/1 5.1, Solaris 10. */
19214 static char conftest[] = "conftest";
19215 static char plus[] = "-+";
19216 char *argv[3] = { conftest, plus, NULL };
19217 opterr = 0;
19218 if (getopt (2, argv, "+a") != '?')
19219 result |= 1;
19221 /* This code succeeds on glibc 2.8, mingw,
19222 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19223 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19225 static char program[] = "program";
19226 static char p[] = "-p";
19227 static char foo[] = "foo";
19228 static char bar[] = "bar";
19229 char *argv[] = { program, p, foo, bar, NULL };
19231 optind = 1;
19232 if (getopt (4, argv, "p::") != 'p')
19233 result |= 2;
19234 else if (optarg != NULL)
19235 result |= 4;
19236 else if (getopt (4, argv, "p::") != -1)
19237 result |= 6;
19238 else if (optind != 2)
19239 result |= 8;
19241 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19243 static char program[] = "program";
19244 static char foo[] = "foo";
19245 static char p[] = "-p";
19246 char *argv[] = { program, foo, p, NULL };
19247 optind = 0;
19248 if (getopt (3, argv, "-p") != 1)
19249 result |= 16;
19250 else if (getopt (3, argv, "-p") != 'p')
19251 result |= 16;
19253 /* This code fails on glibc 2.11. */
19255 static char program[] = "program";
19256 static char b[] = "-b";
19257 static char a[] = "-a";
19258 char *argv[] = { program, b, a, NULL };
19259 optind = opterr = 0;
19260 if (getopt (3, argv, "+:a:b") != 'b')
19261 result |= 32;
19262 else if (getopt (3, argv, "+:a:b") != ':')
19263 result |= 32;
19265 /* This code dumps core on glibc 2.14. */
19267 static char program[] = "program";
19268 static char w[] = "-W";
19269 static char dummy[] = "dummy";
19270 char *argv[] = { program, w, dummy, NULL };
19271 optind = opterr = 1;
19272 if (getopt (3, argv, "W;") != 'W')
19273 result |= 64;
19275 return result;
19278 return 0;
19280 _ACEOF
19281 if ac_fn_c_try_run "$LINENO"; then :
19282 gl_cv_func_getopt_gnu=yes
19283 else
19284 gl_cv_func_getopt_gnu=no
19286 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19287 conftest.$ac_objext conftest.beam conftest.$ac_ext
19290 case $gl_had_POSIXLY_CORRECT in
19291 exported) ;;
19292 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19293 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19294 esac
19297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19298 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19299 if test "$gl_cv_func_getopt_gnu" != yes; then
19300 gl_replace_getopt=yes
19301 else
19302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19303 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19304 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19305 $as_echo_n "(cached) " >&6
19306 else
19307 if test "$cross_compiling" = yes; then :
19308 case "$host_os" in
19309 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19310 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19311 esac
19313 else
19314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19315 /* end confdefs.h. */
19316 #include <getopt.h>
19317 #include <stddef.h>
19318 #include <string.h>
19321 main ()
19323 static const struct option long_options[] =
19325 { "xtremely-",no_argument, NULL, 1003 },
19326 { "xtra", no_argument, NULL, 1001 },
19327 { "xtreme", no_argument, NULL, 1002 },
19328 { "xtremely", no_argument, NULL, 1003 },
19329 { NULL, 0, NULL, 0 }
19331 /* This code fails on OpenBSD 5.0. */
19333 static char program[] = "program";
19334 static char xtremel[] = "--xtremel";
19335 char *argv[] = { program, xtremel, NULL };
19336 int option_index;
19337 optind = 1; opterr = 0;
19338 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19339 return 1;
19341 return 0;
19344 return 0;
19346 _ACEOF
19347 if ac_fn_c_try_run "$LINENO"; then :
19348 gl_cv_func_getopt_long_gnu=yes
19349 else
19350 gl_cv_func_getopt_long_gnu=no
19352 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19353 conftest.$ac_objext conftest.beam conftest.$ac_ext
19358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19359 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19360 case "$gl_cv_func_getopt_long_gnu" in
19361 *yes) ;;
19362 *) gl_replace_getopt=yes ;;
19363 esac
19372 REPLACE_GETOPT=0
19373 if test -n "$gl_replace_getopt"; then
19374 REPLACE_GETOPT=1
19377 if test $REPLACE_GETOPT = 1; then
19379 GETOPT_H=getopt.h
19381 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19387 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19388 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19389 ac_have_decl=1
19390 else
19391 ac_have_decl=0
19394 cat >>confdefs.h <<_ACEOF
19395 #define HAVE_DECL_GETENV $ac_have_decl
19396 _ACEOF
19403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19404 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19405 if test "${ac_cv_c_restrict+set}" = set; then :
19406 $as_echo_n "(cached) " >&6
19407 else
19408 ac_cv_c_restrict=no
19409 # The order here caters to the fact that C++ does not require restrict.
19410 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19412 /* end confdefs.h. */
19413 typedef int * int_ptr;
19414 int foo (int_ptr $ac_kw ip) {
19415 return ip[0];
19418 main ()
19420 int s[1];
19421 int * $ac_kw t = s;
19422 t[0] = 0;
19423 return foo(t)
19425 return 0;
19427 _ACEOF
19428 if ac_fn_c_try_compile "$LINENO"; then :
19429 ac_cv_c_restrict=$ac_kw
19431 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19432 test "$ac_cv_c_restrict" != no && break
19433 done
19436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19437 $as_echo "$ac_cv_c_restrict" >&6; }
19439 case $ac_cv_c_restrict in
19440 restrict) ;;
19441 no) $as_echo "#define restrict /**/" >>confdefs.h
19443 *) cat >>confdefs.h <<_ACEOF
19444 #define restrict $ac_cv_c_restrict
19445 _ACEOF
19447 esac
19450 GNULIB_GETTIMEOFDAY=0;
19451 HAVE_GETTIMEOFDAY=1;
19452 HAVE_STRUCT_TIMEVAL=1;
19453 HAVE_SYS_TIME_H=1;
19454 REPLACE_GETTIMEOFDAY=0;
19455 REPLACE_STRUCT_TIMEVAL=0;
19472 if test $gl_cv_have_include_next = yes; then
19473 gl_cv_next_sys_time_h='<'sys/time.h'>'
19474 else
19475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19476 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19477 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19478 $as_echo_n "(cached) " >&6
19479 else
19481 if test $ac_cv_header_sys_time_h = yes; then
19484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19485 /* end confdefs.h. */
19486 #include <sys/time.h>
19488 _ACEOF
19489 case "$host_os" in
19490 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19491 *) gl_absname_cpp="$ac_cpp" ;;
19492 esac
19494 case "$host_os" in
19495 mingw*)
19496 gl_dirsep_regex='[/\\]'
19499 gl_dirsep_regex='\/'
19501 esac
19502 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19504 gl_header_literal_regex=`echo 'sys/time.h' \
19505 | sed -e "$gl_make_literal_regex_sed"`
19506 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19507 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19508 s|^/[^/]|//&|
19512 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19513 sed -n "$gl_absolute_header_sed"`'"'
19514 else
19515 gl_cv_next_sys_time_h='<'sys/time.h'>'
19520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19521 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19523 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19525 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19526 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19527 gl_next_as_first_directive='<'sys/time.h'>'
19528 else
19529 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19530 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19532 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19538 if test $ac_cv_header_sys_time_h != yes; then
19539 HAVE_SYS_TIME_H=0
19546 if test $ac_cv_header_sys_socket_h != yes; then
19547 for ac_header in winsock2.h
19548 do :
19549 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19550 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19551 cat >>confdefs.h <<_ACEOF
19552 #define HAVE_WINSOCK2_H 1
19553 _ACEOF
19557 done
19560 if test "$ac_cv_header_winsock2_h" = yes; then
19561 HAVE_WINSOCK2_H=1
19562 UNISTD_H_HAVE_WINSOCK2_H=1
19563 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19564 else
19565 HAVE_WINSOCK2_H=0
19569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
19570 $as_echo_n "checking for struct timeval... " >&6; }
19571 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
19572 $as_echo_n "(cached) " >&6
19573 else
19574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19575 /* end confdefs.h. */
19576 #if HAVE_SYS_TIME_H
19577 #include <sys/time.h>
19578 #endif
19579 #include <time.h>
19580 #if HAVE_WINSOCK2_H
19581 # include <winsock2.h>
19582 #endif
19585 main ()
19587 static struct timeval x; x.tv_sec = x.tv_usec;
19589 return 0;
19591 _ACEOF
19592 if ac_fn_c_try_compile "$LINENO"; then :
19593 gl_cv_sys_struct_timeval=yes
19594 else
19595 gl_cv_sys_struct_timeval=no
19597 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
19601 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
19602 if test $gl_cv_sys_struct_timeval != yes; then
19603 HAVE_STRUCT_TIMEVAL=0
19604 else
19605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
19606 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
19607 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
19608 $as_echo_n "(cached) " >&6
19609 else
19610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19611 /* end confdefs.h. */
19612 #if HAVE_SYS_TIME_H
19613 #include <sys/time.h>
19614 #endif
19615 #include <time.h>
19616 #if HAVE_WINSOCK2_H
19617 # include <winsock2.h>
19618 #endif
19621 main ()
19623 static struct timeval x;
19624 typedef int verify_tv_sec_type[
19625 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
19629 return 0;
19631 _ACEOF
19632 if ac_fn_c_try_compile "$LINENO"; then :
19633 gl_cv_sys_struct_timeval_tv_sec=yes
19634 else
19635 gl_cv_sys_struct_timeval_tv_sec=no
19637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
19641 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
19642 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
19643 REPLACE_STRUCT_TIMEVAL=1
19653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
19654 $as_echo_n "checking for unsigned long long int... " >&6; }
19655 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
19656 $as_echo_n "(cached) " >&6
19657 else
19658 ac_cv_type_unsigned_long_long_int=yes
19659 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19660 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19661 /* end confdefs.h. */
19663 /* For now, do not test the preprocessor; as of 2007 there are too many
19664 implementations with broken preprocessors. Perhaps this can
19665 be revisited in 2012. In the meantime, code should not expect
19666 #if to work with literals wider than 32 bits. */
19667 /* Test literals. */
19668 long long int ll = 9223372036854775807ll;
19669 long long int nll = -9223372036854775807LL;
19670 unsigned long long int ull = 18446744073709551615ULL;
19671 /* Test constant expressions. */
19672 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
19673 ? 1 : -1)];
19674 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
19675 ? 1 : -1)];
19676 int i = 63;
19678 main ()
19680 /* Test availability of runtime routines for shift and division. */
19681 long long int llmax = 9223372036854775807ll;
19682 unsigned long long int ullmax = 18446744073709551615ull;
19683 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
19684 | (llmax / ll) | (llmax % ll)
19685 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
19686 | (ullmax / ull) | (ullmax % ull));
19688 return 0;
19691 _ACEOF
19692 if ac_fn_c_try_link "$LINENO"; then :
19694 else
19695 ac_cv_type_unsigned_long_long_int=no
19697 rm -f core conftest.err conftest.$ac_objext \
19698 conftest$ac_exeext conftest.$ac_ext
19701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
19702 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
19703 if test $ac_cv_type_unsigned_long_long_int = yes; then
19705 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
19711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
19712 $as_echo_n "checking for long long int... " >&6; }
19713 if test "${ac_cv_type_long_long_int+set}" = set; then :
19714 $as_echo_n "(cached) " >&6
19715 else
19716 ac_cv_type_long_long_int=yes
19717 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
19718 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
19719 if test $ac_cv_type_long_long_int = yes; then
19720 if test "$cross_compiling" = yes; then :
19722 else
19723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19724 /* end confdefs.h. */
19725 #include <limits.h>
19726 #ifndef LLONG_MAX
19727 # define HALF \
19728 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
19729 # define LLONG_MAX (HALF - 1 + HALF)
19730 #endif
19732 main ()
19734 long long int n = 1;
19735 int i;
19736 for (i = 0; ; i++)
19738 long long int m = n << i;
19739 if (m >> i != n)
19740 return 1;
19741 if (LLONG_MAX / 2 < m)
19742 break;
19744 return 0;
19746 return 0;
19748 _ACEOF
19749 if ac_fn_c_try_run "$LINENO"; then :
19751 else
19752 ac_cv_type_long_long_int=no
19754 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19755 conftest.$ac_objext conftest.beam conftest.$ac_ext
19761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
19762 $as_echo "$ac_cv_type_long_long_int" >&6; }
19763 if test $ac_cv_type_long_long_int = yes; then
19765 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
19774 gl_cv_c_multiarch=no
19775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19776 /* end confdefs.h. */
19777 #ifndef __APPLE_CC__
19778 not a universal capable compiler
19779 #endif
19780 typedef int dummy;
19782 _ACEOF
19783 if ac_fn_c_try_compile "$LINENO"; then :
19785 arch=
19786 prev=
19787 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
19788 if test -n "$prev"; then
19789 case $word in
19790 i?86 | x86_64 | ppc | ppc64)
19791 if test -z "$arch" || test "$arch" = "$word"; then
19792 arch="$word"
19793 else
19794 gl_cv_c_multiarch=yes
19797 esac
19798 prev=
19799 else
19800 if test "x$word" = "x-arch"; then
19801 prev=arch
19804 done
19807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19808 if test $gl_cv_c_multiarch = yes; then
19809 APPLE_UNIVERSAL_BUILD=1
19810 else
19811 APPLE_UNIVERSAL_BUILD=0
19818 if test $ac_cv_type_long_long_int = yes; then
19819 HAVE_LONG_LONG_INT=1
19820 else
19821 HAVE_LONG_LONG_INT=0
19825 if test $ac_cv_type_unsigned_long_long_int = yes; then
19826 HAVE_UNSIGNED_LONG_LONG_INT=1
19827 else
19828 HAVE_UNSIGNED_LONG_LONG_INT=0
19833 if test $ac_cv_header_wchar_h = yes; then
19834 HAVE_WCHAR_H=1
19835 else
19836 HAVE_WCHAR_H=0
19840 if test $ac_cv_header_inttypes_h = yes; then
19841 HAVE_INTTYPES_H=1
19842 else
19843 HAVE_INTTYPES_H=0
19847 if test $ac_cv_header_sys_types_h = yes; then
19848 HAVE_SYS_TYPES_H=1
19849 else
19850 HAVE_SYS_TYPES_H=0
19863 if test $gl_cv_have_include_next = yes; then
19864 gl_cv_next_stdint_h='<'stdint.h'>'
19865 else
19866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
19867 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
19868 if test "${gl_cv_next_stdint_h+set}" = set; then :
19869 $as_echo_n "(cached) " >&6
19870 else
19872 if test $ac_cv_header_stdint_h = yes; then
19875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19876 /* end confdefs.h. */
19877 #include <stdint.h>
19879 _ACEOF
19880 case "$host_os" in
19881 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19882 *) gl_absname_cpp="$ac_cpp" ;;
19883 esac
19885 case "$host_os" in
19886 mingw*)
19887 gl_dirsep_regex='[/\\]'
19890 gl_dirsep_regex='\/'
19892 esac
19893 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19895 gl_header_literal_regex=`echo 'stdint.h' \
19896 | sed -e "$gl_make_literal_regex_sed"`
19897 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19898 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19899 s|^/[^/]|//&|
19903 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19904 sed -n "$gl_absolute_header_sed"`'"'
19905 else
19906 gl_cv_next_stdint_h='<'stdint.h'>'
19911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
19912 $as_echo "$gl_cv_next_stdint_h" >&6; }
19914 NEXT_STDINT_H=$gl_cv_next_stdint_h
19916 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19917 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19918 gl_next_as_first_directive='<'stdint.h'>'
19919 else
19920 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19921 gl_next_as_first_directive=$gl_cv_next_stdint_h
19923 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
19928 if test $ac_cv_header_stdint_h = yes; then
19929 HAVE_STDINT_H=1
19930 else
19931 HAVE_STDINT_H=0
19935 if test $ac_cv_header_stdint_h = yes; then
19936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
19937 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
19938 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
19939 $as_echo_n "(cached) " >&6
19940 else
19941 gl_cv_header_working_stdint_h=no
19942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19943 /* end confdefs.h. */
19946 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
19947 #include <stdint.h>
19948 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
19949 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
19950 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
19951 #endif
19954 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
19955 included before <wchar.h>. */
19956 #include <stddef.h>
19957 #include <signal.h>
19958 #if HAVE_WCHAR_H
19959 # include <stdio.h>
19960 # include <time.h>
19961 # include <wchar.h>
19962 #endif
19965 #ifdef INT8_MAX
19966 int8_t a1 = INT8_MAX;
19967 int8_t a1min = INT8_MIN;
19968 #endif
19969 #ifdef INT16_MAX
19970 int16_t a2 = INT16_MAX;
19971 int16_t a2min = INT16_MIN;
19972 #endif
19973 #ifdef INT32_MAX
19974 int32_t a3 = INT32_MAX;
19975 int32_t a3min = INT32_MIN;
19976 #endif
19977 #ifdef INT64_MAX
19978 int64_t a4 = INT64_MAX;
19979 int64_t a4min = INT64_MIN;
19980 #endif
19981 #ifdef UINT8_MAX
19982 uint8_t b1 = UINT8_MAX;
19983 #else
19984 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
19985 #endif
19986 #ifdef UINT16_MAX
19987 uint16_t b2 = UINT16_MAX;
19988 #endif
19989 #ifdef UINT32_MAX
19990 uint32_t b3 = UINT32_MAX;
19991 #endif
19992 #ifdef UINT64_MAX
19993 uint64_t b4 = UINT64_MAX;
19994 #endif
19995 int_least8_t c1 = INT8_C (0x7f);
19996 int_least8_t c1max = INT_LEAST8_MAX;
19997 int_least8_t c1min = INT_LEAST8_MIN;
19998 int_least16_t c2 = INT16_C (0x7fff);
19999 int_least16_t c2max = INT_LEAST16_MAX;
20000 int_least16_t c2min = INT_LEAST16_MIN;
20001 int_least32_t c3 = INT32_C (0x7fffffff);
20002 int_least32_t c3max = INT_LEAST32_MAX;
20003 int_least32_t c3min = INT_LEAST32_MIN;
20004 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20005 int_least64_t c4max = INT_LEAST64_MAX;
20006 int_least64_t c4min = INT_LEAST64_MIN;
20007 uint_least8_t d1 = UINT8_C (0xff);
20008 uint_least8_t d1max = UINT_LEAST8_MAX;
20009 uint_least16_t d2 = UINT16_C (0xffff);
20010 uint_least16_t d2max = UINT_LEAST16_MAX;
20011 uint_least32_t d3 = UINT32_C (0xffffffff);
20012 uint_least32_t d3max = UINT_LEAST32_MAX;
20013 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20014 uint_least64_t d4max = UINT_LEAST64_MAX;
20015 int_fast8_t e1 = INT_FAST8_MAX;
20016 int_fast8_t e1min = INT_FAST8_MIN;
20017 int_fast16_t e2 = INT_FAST16_MAX;
20018 int_fast16_t e2min = INT_FAST16_MIN;
20019 int_fast32_t e3 = INT_FAST32_MAX;
20020 int_fast32_t e3min = INT_FAST32_MIN;
20021 int_fast64_t e4 = INT_FAST64_MAX;
20022 int_fast64_t e4min = INT_FAST64_MIN;
20023 uint_fast8_t f1 = UINT_FAST8_MAX;
20024 uint_fast16_t f2 = UINT_FAST16_MAX;
20025 uint_fast32_t f3 = UINT_FAST32_MAX;
20026 uint_fast64_t f4 = UINT_FAST64_MAX;
20027 #ifdef INTPTR_MAX
20028 intptr_t g = INTPTR_MAX;
20029 intptr_t gmin = INTPTR_MIN;
20030 #endif
20031 #ifdef UINTPTR_MAX
20032 uintptr_t h = UINTPTR_MAX;
20033 #endif
20034 intmax_t i = INTMAX_MAX;
20035 uintmax_t j = UINTMAX_MAX;
20037 #include <limits.h> /* for CHAR_BIT */
20038 #define TYPE_MINIMUM(t) \
20039 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
20040 #define TYPE_MAXIMUM(t) \
20041 ((t) ((t) 0 < (t) -1 \
20042 ? (t) -1 \
20043 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
20044 struct s {
20045 int check_PTRDIFF:
20046 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20047 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20048 ? 1 : -1;
20049 /* Detect bug in FreeBSD 6.0 / ia64. */
20050 int check_SIG_ATOMIC:
20051 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20052 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20053 ? 1 : -1;
20054 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20055 int check_WCHAR:
20056 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20057 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20058 ? 1 : -1;
20059 /* Detect bug in mingw. */
20060 int check_WINT:
20061 WINT_MIN == TYPE_MINIMUM (wint_t)
20062 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20063 ? 1 : -1;
20065 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20066 int check_UINT8_C:
20067 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20068 int check_UINT16_C:
20069 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20071 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20072 #ifdef UINT8_MAX
20073 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20074 #endif
20075 #ifdef UINT16_MAX
20076 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20077 #endif
20078 #ifdef UINT32_MAX
20079 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20080 #endif
20081 #ifdef UINT64_MAX
20082 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20083 #endif
20084 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20085 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20086 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20087 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20088 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20089 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20090 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20091 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20092 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20093 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20094 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20098 main ()
20102 return 0;
20104 _ACEOF
20105 if ac_fn_c_try_compile "$LINENO"; then :
20106 if test "$cross_compiling" = yes; then :
20107 gl_cv_header_working_stdint_h=yes
20109 else
20110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20111 /* end confdefs.h. */
20114 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20115 #include <stdint.h>
20118 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20119 included before <wchar.h>. */
20120 #include <stddef.h>
20121 #include <signal.h>
20122 #if HAVE_WCHAR_H
20123 # include <stdio.h>
20124 # include <time.h>
20125 # include <wchar.h>
20126 #endif
20129 #include <stdio.h>
20130 #include <string.h>
20131 #define MVAL(macro) MVAL1(macro)
20132 #define MVAL1(expression) #expression
20133 static const char *macro_values[] =
20135 #ifdef INT8_MAX
20136 MVAL (INT8_MAX),
20137 #endif
20138 #ifdef INT16_MAX
20139 MVAL (INT16_MAX),
20140 #endif
20141 #ifdef INT32_MAX
20142 MVAL (INT32_MAX),
20143 #endif
20144 #ifdef INT64_MAX
20145 MVAL (INT64_MAX),
20146 #endif
20147 #ifdef UINT8_MAX
20148 MVAL (UINT8_MAX),
20149 #endif
20150 #ifdef UINT16_MAX
20151 MVAL (UINT16_MAX),
20152 #endif
20153 #ifdef UINT32_MAX
20154 MVAL (UINT32_MAX),
20155 #endif
20156 #ifdef UINT64_MAX
20157 MVAL (UINT64_MAX),
20158 #endif
20159 NULL
20163 main ()
20166 const char **mv;
20167 for (mv = macro_values; *mv != NULL; mv++)
20169 const char *value = *mv;
20170 /* Test whether it looks like a cast expression. */
20171 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20172 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20173 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20174 || strncmp (value, "((int)"/*)*/, 6) == 0
20175 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20176 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20177 return mv - macro_values + 1;
20179 return 0;
20182 return 0;
20184 _ACEOF
20185 if ac_fn_c_try_run "$LINENO"; then :
20186 gl_cv_header_working_stdint_h=yes
20188 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20189 conftest.$ac_objext conftest.beam conftest.$ac_ext
20194 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20198 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20200 if test "$gl_cv_header_working_stdint_h" = yes; then
20201 STDINT_H=
20202 else
20203 for ac_header in sys/inttypes.h sys/bitypes.h
20204 do :
20205 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20206 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20207 eval as_val=\$$as_ac_Header
20208 if test "x$as_val" = x""yes; then :
20209 cat >>confdefs.h <<_ACEOF
20210 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20211 _ACEOF
20215 done
20217 if test $ac_cv_header_sys_inttypes_h = yes; then
20218 HAVE_SYS_INTTYPES_H=1
20219 else
20220 HAVE_SYS_INTTYPES_H=0
20223 if test $ac_cv_header_sys_bitypes_h = yes; then
20224 HAVE_SYS_BITYPES_H=1
20225 else
20226 HAVE_SYS_BITYPES_H=0
20232 if test $APPLE_UNIVERSAL_BUILD = 0; then
20235 for gltype in ptrdiff_t size_t ; do
20236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20237 $as_echo_n "checking for bit size of $gltype... " >&6; }
20238 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20239 $as_echo_n "(cached) " >&6
20240 else
20241 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20242 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20243 included before <wchar.h>. */
20244 #include <stddef.h>
20245 #include <signal.h>
20246 #if HAVE_WCHAR_H
20247 # include <stdio.h>
20248 # include <time.h>
20249 # include <wchar.h>
20250 #endif
20252 #include <limits.h>"; then :
20254 else
20255 result=unknown
20258 eval gl_cv_bitsizeof_${gltype}=\$result
20261 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20263 $as_echo "$ac_res" >&6; }
20264 eval result=\$gl_cv_bitsizeof_${gltype}
20265 if test $result = unknown; then
20266 result=0
20268 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20269 cat >>confdefs.h <<_ACEOF
20270 #define BITSIZEOF_${GLTYPE} $result
20271 _ACEOF
20273 eval BITSIZEOF_${GLTYPE}=\$result
20274 done
20280 for gltype in sig_atomic_t wchar_t wint_t ; do
20281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20282 $as_echo_n "checking for bit size of $gltype... " >&6; }
20283 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20284 $as_echo_n "(cached) " >&6
20285 else
20286 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20287 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20288 included before <wchar.h>. */
20289 #include <stddef.h>
20290 #include <signal.h>
20291 #if HAVE_WCHAR_H
20292 # include <stdio.h>
20293 # include <time.h>
20294 # include <wchar.h>
20295 #endif
20297 #include <limits.h>"; then :
20299 else
20300 result=unknown
20303 eval gl_cv_bitsizeof_${gltype}=\$result
20306 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20308 $as_echo "$ac_res" >&6; }
20309 eval result=\$gl_cv_bitsizeof_${gltype}
20310 if test $result = unknown; then
20311 result=0
20313 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20314 cat >>confdefs.h <<_ACEOF
20315 #define BITSIZEOF_${GLTYPE} $result
20316 _ACEOF
20318 eval BITSIZEOF_${GLTYPE}=\$result
20319 done
20324 for gltype in sig_atomic_t wchar_t wint_t ; do
20325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20326 $as_echo_n "checking whether $gltype is signed... " >&6; }
20327 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20328 $as_echo_n "(cached) " >&6
20329 else
20330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20331 /* end confdefs.h. */
20333 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20334 included before <wchar.h>. */
20335 #include <stddef.h>
20336 #include <signal.h>
20337 #if HAVE_WCHAR_H
20338 # include <stdio.h>
20339 # include <time.h>
20340 # include <wchar.h>
20341 #endif
20343 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20345 main ()
20349 return 0;
20351 _ACEOF
20352 if ac_fn_c_try_compile "$LINENO"; then :
20353 result=yes
20354 else
20355 result=no
20357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20358 eval gl_cv_type_${gltype}_signed=\$result
20361 eval ac_res=\$gl_cv_type_${gltype}_signed
20362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20363 $as_echo "$ac_res" >&6; }
20364 eval result=\$gl_cv_type_${gltype}_signed
20365 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20366 if test "$result" = yes; then
20367 cat >>confdefs.h <<_ACEOF
20368 #define HAVE_SIGNED_${GLTYPE} 1
20369 _ACEOF
20371 eval HAVE_SIGNED_${GLTYPE}=1
20372 else
20373 eval HAVE_SIGNED_${GLTYPE}=0
20375 done
20378 gl_cv_type_ptrdiff_t_signed=yes
20379 gl_cv_type_size_t_signed=no
20380 if test $APPLE_UNIVERSAL_BUILD = 0; then
20383 for gltype in ptrdiff_t size_t ; do
20384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20385 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20386 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20387 $as_echo_n "(cached) " >&6
20388 else
20389 eval gl_cv_type_${gltype}_suffix=no
20390 eval result=\$gl_cv_type_${gltype}_signed
20391 if test "$result" = yes; then
20392 glsufu=
20393 else
20394 glsufu=u
20396 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20397 case $glsuf in
20398 '') gltype1='int';;
20399 l) gltype1='long int';;
20400 ll) gltype1='long long int';;
20401 i64) gltype1='__int64';;
20402 u) gltype1='unsigned int';;
20403 ul) gltype1='unsigned long int';;
20404 ull) gltype1='unsigned long long int';;
20405 ui64)gltype1='unsigned __int64';;
20406 esac
20407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20408 /* end confdefs.h. */
20410 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20411 included before <wchar.h>. */
20412 #include <stddef.h>
20413 #include <signal.h>
20414 #if HAVE_WCHAR_H
20415 # include <stdio.h>
20416 # include <time.h>
20417 # include <wchar.h>
20418 #endif
20420 extern $gltype foo;
20421 extern $gltype1 foo;
20423 main ()
20427 return 0;
20429 _ACEOF
20430 if ac_fn_c_try_compile "$LINENO"; then :
20431 eval gl_cv_type_${gltype}_suffix=\$glsuf
20433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20434 eval result=\$gl_cv_type_${gltype}_suffix
20435 test "$result" != no && break
20436 done
20438 eval ac_res=\$gl_cv_type_${gltype}_suffix
20439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20440 $as_echo "$ac_res" >&6; }
20441 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20442 eval result=\$gl_cv_type_${gltype}_suffix
20443 test "$result" = no && result=
20444 eval ${GLTYPE}_SUFFIX=\$result
20445 cat >>confdefs.h <<_ACEOF
20446 #define ${GLTYPE}_SUFFIX $result
20447 _ACEOF
20449 done
20455 for gltype in sig_atomic_t wchar_t wint_t ; do
20456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20457 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20458 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20459 $as_echo_n "(cached) " >&6
20460 else
20461 eval gl_cv_type_${gltype}_suffix=no
20462 eval result=\$gl_cv_type_${gltype}_signed
20463 if test "$result" = yes; then
20464 glsufu=
20465 else
20466 glsufu=u
20468 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20469 case $glsuf in
20470 '') gltype1='int';;
20471 l) gltype1='long int';;
20472 ll) gltype1='long long int';;
20473 i64) gltype1='__int64';;
20474 u) gltype1='unsigned int';;
20475 ul) gltype1='unsigned long int';;
20476 ull) gltype1='unsigned long long int';;
20477 ui64)gltype1='unsigned __int64';;
20478 esac
20479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20480 /* end confdefs.h. */
20482 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20483 included before <wchar.h>. */
20484 #include <stddef.h>
20485 #include <signal.h>
20486 #if HAVE_WCHAR_H
20487 # include <stdio.h>
20488 # include <time.h>
20489 # include <wchar.h>
20490 #endif
20492 extern $gltype foo;
20493 extern $gltype1 foo;
20495 main ()
20499 return 0;
20501 _ACEOF
20502 if ac_fn_c_try_compile "$LINENO"; then :
20503 eval gl_cv_type_${gltype}_suffix=\$glsuf
20505 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20506 eval result=\$gl_cv_type_${gltype}_suffix
20507 test "$result" != no && break
20508 done
20510 eval ac_res=\$gl_cv_type_${gltype}_suffix
20511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20512 $as_echo "$ac_res" >&6; }
20513 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20514 eval result=\$gl_cv_type_${gltype}_suffix
20515 test "$result" = no && result=
20516 eval ${GLTYPE}_SUFFIX=\$result
20517 cat >>confdefs.h <<_ACEOF
20518 #define ${GLTYPE}_SUFFIX $result
20519 _ACEOF
20521 done
20525 if test $BITSIZEOF_WINT_T -lt 32; then
20526 BITSIZEOF_WINT_T=32
20529 STDINT_H=stdint.h
20532 if test -n "$STDINT_H"; then
20533 GL_GENERATE_STDINT_H_TRUE=
20534 GL_GENERATE_STDINT_H_FALSE='#'
20535 else
20536 GL_GENERATE_STDINT_H_TRUE='#'
20537 GL_GENERATE_STDINT_H_FALSE=
20544 GNULIB_IMAXABS=0;
20545 GNULIB_IMAXDIV=0;
20546 GNULIB_STRTOIMAX=0;
20547 GNULIB_STRTOUMAX=0;
20548 HAVE_DECL_IMAXABS=1;
20549 HAVE_DECL_IMAXDIV=1;
20550 HAVE_DECL_STRTOIMAX=1;
20551 HAVE_DECL_STRTOUMAX=1;
20552 REPLACE_STRTOIMAX=0;
20553 INT32_MAX_LT_INTMAX_MAX=1;
20554 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20555 PRI_MACROS_BROKEN=0;
20556 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20557 UINT32_MAX_LT_UINTMAX_MAX=1;
20558 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20574 if test $gl_cv_have_include_next = yes; then
20575 gl_cv_next_inttypes_h='<'inttypes.h'>'
20576 else
20577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20578 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20579 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20580 $as_echo_n "(cached) " >&6
20581 else
20583 if test $ac_cv_header_inttypes_h = yes; then
20586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20587 /* end confdefs.h. */
20588 #include <inttypes.h>
20590 _ACEOF
20591 case "$host_os" in
20592 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20593 *) gl_absname_cpp="$ac_cpp" ;;
20594 esac
20596 case "$host_os" in
20597 mingw*)
20598 gl_dirsep_regex='[/\\]'
20601 gl_dirsep_regex='\/'
20603 esac
20604 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20606 gl_header_literal_regex=`echo 'inttypes.h' \
20607 | sed -e "$gl_make_literal_regex_sed"`
20608 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20609 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20610 s|^/[^/]|//&|
20614 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20615 sed -n "$gl_absolute_header_sed"`'"'
20616 else
20617 gl_cv_next_inttypes_h='<'inttypes.h'>'
20622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
20623 $as_echo "$gl_cv_next_inttypes_h" >&6; }
20625 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
20627 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20628 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20629 gl_next_as_first_directive='<'inttypes.h'>'
20630 else
20631 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20632 gl_next_as_first_directive=$gl_cv_next_inttypes_h
20634 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
20646 case "$host_os" in
20647 mingw*)
20648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
20649 $as_echo_n "checking for 64-bit off_t... " >&6; }
20650 if test "${gl_cv_type_off_t_64+set}" = set; then :
20651 $as_echo_n "(cached) " >&6
20652 else
20653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20654 /* end confdefs.h. */
20655 #include <sys/types.h>
20656 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
20659 main ()
20663 return 0;
20665 _ACEOF
20666 if ac_fn_c_try_compile "$LINENO"; then :
20667 gl_cv_type_off_t_64=yes
20668 else
20669 gl_cv_type_off_t_64=no
20671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
20675 $as_echo "$gl_cv_type_off_t_64" >&6; }
20676 if test $gl_cv_type_off_t_64 = no; then
20677 WINDOWS_64_BIT_OFF_T=1
20678 else
20679 WINDOWS_64_BIT_OFF_T=0
20681 WINDOWS_64_BIT_ST_SIZE=1
20684 WINDOWS_64_BIT_OFF_T=0
20685 WINDOWS_64_BIT_ST_SIZE=0
20687 esac
20692 GNULIB_FFSL=0;
20693 GNULIB_FFSLL=0;
20694 GNULIB_MEMCHR=0;
20695 GNULIB_MEMMEM=0;
20696 GNULIB_MEMPCPY=0;
20697 GNULIB_MEMRCHR=0;
20698 GNULIB_RAWMEMCHR=0;
20699 GNULIB_STPCPY=0;
20700 GNULIB_STPNCPY=0;
20701 GNULIB_STRCHRNUL=0;
20702 GNULIB_STRDUP=0;
20703 GNULIB_STRNCAT=0;
20704 GNULIB_STRNDUP=0;
20705 GNULIB_STRNLEN=0;
20706 GNULIB_STRPBRK=0;
20707 GNULIB_STRSEP=0;
20708 GNULIB_STRSTR=0;
20709 GNULIB_STRCASESTR=0;
20710 GNULIB_STRTOK_R=0;
20711 GNULIB_MBSLEN=0;
20712 GNULIB_MBSNLEN=0;
20713 GNULIB_MBSCHR=0;
20714 GNULIB_MBSRCHR=0;
20715 GNULIB_MBSSTR=0;
20716 GNULIB_MBSCASECMP=0;
20717 GNULIB_MBSNCASECMP=0;
20718 GNULIB_MBSPCASECMP=0;
20719 GNULIB_MBSCASESTR=0;
20720 GNULIB_MBSCSPN=0;
20721 GNULIB_MBSPBRK=0;
20722 GNULIB_MBSSPN=0;
20723 GNULIB_MBSSEP=0;
20724 GNULIB_MBSTOK_R=0;
20725 GNULIB_STRERROR=0;
20726 GNULIB_STRERROR_R=0;
20727 GNULIB_STRSIGNAL=0;
20728 GNULIB_STRVERSCMP=0;
20729 HAVE_MBSLEN=0;
20730 HAVE_FFSL=1;
20731 HAVE_FFSLL=1;
20732 HAVE_MEMCHR=1;
20733 HAVE_DECL_MEMMEM=1;
20734 HAVE_MEMPCPY=1;
20735 HAVE_DECL_MEMRCHR=1;
20736 HAVE_RAWMEMCHR=1;
20737 HAVE_STPCPY=1;
20738 HAVE_STPNCPY=1;
20739 HAVE_STRCHRNUL=1;
20740 HAVE_DECL_STRDUP=1;
20741 HAVE_DECL_STRNDUP=1;
20742 HAVE_DECL_STRNLEN=1;
20743 HAVE_STRPBRK=1;
20744 HAVE_STRSEP=1;
20745 HAVE_STRCASESTR=1;
20746 HAVE_DECL_STRTOK_R=1;
20747 HAVE_DECL_STRERROR_R=1;
20748 HAVE_DECL_STRSIGNAL=1;
20749 HAVE_STRVERSCMP=1;
20750 REPLACE_MEMCHR=0;
20751 REPLACE_MEMMEM=0;
20752 REPLACE_STPNCPY=0;
20753 REPLACE_STRDUP=0;
20754 REPLACE_STRSTR=0;
20755 REPLACE_STRCASESTR=0;
20756 REPLACE_STRCHRNUL=0;
20757 REPLACE_STRERROR=0;
20758 REPLACE_STRERROR_R=0;
20759 REPLACE_STRNCAT=0;
20760 REPLACE_STRNDUP=0;
20761 REPLACE_STRNLEN=0;
20762 REPLACE_STRSIGNAL=0;
20763 REPLACE_STRTOK_R=0;
20764 UNDEFINE_STRTOK_R=0;
20766 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
20767 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
20768 ac_have_decl=1
20769 else
20770 ac_have_decl=0
20773 cat >>confdefs.h <<_ACEOF
20774 #define HAVE_DECL_MEMRCHR $ac_have_decl
20775 _ACEOF
20778 GNULIB_MKTIME=0;
20779 GNULIB_NANOSLEEP=0;
20780 GNULIB_STRPTIME=0;
20781 GNULIB_TIMEGM=0;
20782 GNULIB_TIME_R=0;
20783 HAVE_DECL_LOCALTIME_R=1;
20784 HAVE_NANOSLEEP=1;
20785 HAVE_STRPTIME=1;
20786 HAVE_TIMEGM=1;
20787 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
20788 REPLACE_MKTIME=GNULIB_PORTCHECK;
20789 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
20790 REPLACE_TIMEGM=GNULIB_PORTCHECK;
20792 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
20793 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
20794 ac_have_decl=1
20795 else
20796 ac_have_decl=0
20799 cat >>confdefs.h <<_ACEOF
20800 #define HAVE_DECL_ALARM $ac_have_decl
20801 _ACEOF
20804 GNULIB_PSELECT=0;
20805 GNULIB_SELECT=0;
20806 HAVE_PSELECT=1;
20807 REPLACE_PSELECT=0;
20808 REPLACE_SELECT=0;
20815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
20816 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
20817 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
20818 $as_echo_n "(cached) " >&6
20819 else
20821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20822 /* end confdefs.h. */
20823 #include <sys/select.h>
20825 main ()
20827 struct timeval b;
20829 return 0;
20831 _ACEOF
20832 if ac_fn_c_try_compile "$LINENO"; then :
20833 gl_cv_header_sys_select_h_selfcontained=yes
20834 else
20835 gl_cv_header_sys_select_h_selfcontained=no
20837 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20838 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
20839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20840 /* end confdefs.h. */
20841 #include <sys/select.h>
20843 main ()
20845 int memset; int bzero;
20847 return 0;
20850 _ACEOF
20851 if ac_fn_c_try_compile "$LINENO"; then :
20852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20853 /* end confdefs.h. */
20854 #include <sys/select.h>
20856 main ()
20859 #undef memset
20860 #define memset nonexistent_memset
20861 extern
20862 #ifdef __cplusplus
20864 #endif
20865 void *memset (void *, int, unsigned long);
20866 #undef bzero
20867 #define bzero nonexistent_bzero
20868 extern
20869 #ifdef __cplusplus
20871 #endif
20872 void bzero (void *, unsigned long);
20873 fd_set fds;
20874 FD_ZERO (&fds);
20877 return 0;
20880 _ACEOF
20881 if ac_fn_c_try_link "$LINENO"; then :
20883 else
20884 gl_cv_header_sys_select_h_selfcontained=no
20886 rm -f core conftest.err conftest.$ac_objext \
20887 conftest$ac_exeext conftest.$ac_ext
20890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
20895 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
20905 if test $gl_cv_have_include_next = yes; then
20906 gl_cv_next_sys_select_h='<'sys/select.h'>'
20907 else
20908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
20909 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
20910 if test "${gl_cv_next_sys_select_h+set}" = set; then :
20911 $as_echo_n "(cached) " >&6
20912 else
20914 if test $ac_cv_header_sys_select_h = yes; then
20917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20918 /* end confdefs.h. */
20919 #include <sys/select.h>
20921 _ACEOF
20922 case "$host_os" in
20923 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20924 *) gl_absname_cpp="$ac_cpp" ;;
20925 esac
20927 case "$host_os" in
20928 mingw*)
20929 gl_dirsep_regex='[/\\]'
20932 gl_dirsep_regex='\/'
20934 esac
20935 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20937 gl_header_literal_regex=`echo 'sys/select.h' \
20938 | sed -e "$gl_make_literal_regex_sed"`
20939 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20940 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20941 s|^/[^/]|//&|
20945 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20946 sed -n "$gl_absolute_header_sed"`'"'
20947 else
20948 gl_cv_next_sys_select_h='<'sys/select.h'>'
20953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
20954 $as_echo "$gl_cv_next_sys_select_h" >&6; }
20956 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
20958 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20959 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20960 gl_next_as_first_directive='<'sys/select.h'>'
20961 else
20962 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20963 gl_next_as_first_directive=$gl_cv_next_sys_select_h
20965 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
20970 if test $ac_cv_header_sys_select_h = yes; then
20971 HAVE_SYS_SELECT_H=1
20972 else
20973 HAVE_SYS_SELECT_H=0
20980 if test $ac_cv_header_sys_socket_h != yes; then
20981 for ac_header in winsock2.h
20982 do :
20983 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
20984 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
20985 cat >>confdefs.h <<_ACEOF
20986 #define HAVE_WINSOCK2_H 1
20987 _ACEOF
20991 done
20994 if test "$ac_cv_header_winsock2_h" = yes; then
20995 HAVE_WINSOCK2_H=1
20996 UNISTD_H_HAVE_WINSOCK2_H=1
20997 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
20998 else
20999 HAVE_WINSOCK2_H=0
21009 GNULIB_PTHREAD_SIGMASK=0;
21010 GNULIB_RAISE=0;
21011 GNULIB_SIGNAL_H_SIGPIPE=0;
21012 GNULIB_SIGPROCMASK=0;
21013 GNULIB_SIGACTION=0;
21014 HAVE_POSIX_SIGNALBLOCKING=1;
21015 HAVE_PTHREAD_SIGMASK=1;
21016 HAVE_RAISE=1;
21017 HAVE_SIGSET_T=1;
21018 HAVE_SIGINFO_T=1;
21019 HAVE_SIGACTION=1;
21020 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
21022 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
21024 HAVE_SIGHANDLER_T=1;
21025 REPLACE_PTHREAD_SIGMASK=0;
21026 REPLACE_RAISE=0;
21034 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
21035 #include <signal.h>
21036 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
21037 #include <sys/types.h>
21040 if test "x$ac_cv_type_sigset_t" = x""yes; then :
21042 cat >>confdefs.h <<_ACEOF
21043 #define HAVE_SIGSET_T 1
21044 _ACEOF
21046 gl_cv_type_sigset_t=yes
21047 else
21048 gl_cv_type_sigset_t=no
21051 if test $gl_cv_type_sigset_t != yes; then
21052 HAVE_SIGSET_T=0
21057 if test $ac_cv_header_sys_socket_h = no; then
21058 for ac_header in ws2tcpip.h
21059 do :
21060 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
21061 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
21062 cat >>confdefs.h <<_ACEOF
21063 #define HAVE_WS2TCPIP_H 1
21064 _ACEOF
21068 done
21072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21073 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21074 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21075 $as_echo_n "(cached) " >&6
21076 else
21077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21078 /* end confdefs.h. */
21080 #include <stdbool.h>
21081 #ifndef bool
21082 "error: bool is not defined"
21083 #endif
21084 #ifndef false
21085 "error: false is not defined"
21086 #endif
21087 #if false
21088 "error: false is not 0"
21089 #endif
21090 #ifndef true
21091 "error: true is not defined"
21092 #endif
21093 #if true != 1
21094 "error: true is not 1"
21095 #endif
21096 #ifndef __bool_true_false_are_defined
21097 "error: __bool_true_false_are_defined is not defined"
21098 #endif
21100 struct s { _Bool s: 1; _Bool t; } s;
21102 char a[true == 1 ? 1 : -1];
21103 char b[false == 0 ? 1 : -1];
21104 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21105 char d[(bool) 0.5 == true ? 1 : -1];
21106 /* See body of main program for 'e'. */
21107 char f[(_Bool) 0.0 == false ? 1 : -1];
21108 char g[true];
21109 char h[sizeof (_Bool)];
21110 char i[sizeof s.t];
21111 enum { j = false, k = true, l = false * true, m = true * 256 };
21112 /* The following fails for
21113 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21114 _Bool n[m];
21115 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21116 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21117 /* Catch a bug in an HP-UX C compiler. See
21118 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21119 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21121 _Bool q = true;
21122 _Bool *pq = &q;
21125 main ()
21128 bool e = &s;
21129 *pq |= q;
21130 *pq |= ! q;
21131 /* Refer to every declared value, to avoid compiler optimizations. */
21132 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21133 + !m + !n + !o + !p + !q + !pq);
21136 return 0;
21138 _ACEOF
21139 if ac_fn_c_try_compile "$LINENO"; then :
21140 ac_cv_header_stdbool_h=yes
21141 else
21142 ac_cv_header_stdbool_h=no
21144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21147 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21148 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21149 if test "x$ac_cv_type__Bool" = x""yes; then :
21151 cat >>confdefs.h <<_ACEOF
21152 #define HAVE__BOOL 1
21153 _ACEOF
21160 REPLACE_NULL=0;
21161 HAVE_WCHAR_T=1;
21164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21165 $as_echo_n "checking for wchar_t... " >&6; }
21166 if test "${gt_cv_c_wchar_t+set}" = set; then :
21167 $as_echo_n "(cached) " >&6
21168 else
21169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21170 /* end confdefs.h. */
21171 #include <stddef.h>
21172 wchar_t foo = (wchar_t)'\0';
21174 main ()
21178 return 0;
21180 _ACEOF
21181 if ac_fn_c_try_compile "$LINENO"; then :
21182 gt_cv_c_wchar_t=yes
21183 else
21184 gt_cv_c_wchar_t=no
21186 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21189 $as_echo "$gt_cv_c_wchar_t" >&6; }
21190 if test $gt_cv_c_wchar_t = yes; then
21192 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21197 GNULIB_DPRINTF=0;
21198 GNULIB_FCLOSE=0;
21199 GNULIB_FDOPEN=0;
21200 GNULIB_FFLUSH=0;
21201 GNULIB_FGETC=0;
21202 GNULIB_FGETS=0;
21203 GNULIB_FOPEN=0;
21204 GNULIB_FPRINTF=0;
21205 GNULIB_FPRINTF_POSIX=0;
21206 GNULIB_FPURGE=0;
21207 GNULIB_FPUTC=0;
21208 GNULIB_FPUTS=0;
21209 GNULIB_FREAD=0;
21210 GNULIB_FREOPEN=0;
21211 GNULIB_FSCANF=0;
21212 GNULIB_FSEEK=0;
21213 GNULIB_FSEEKO=0;
21214 GNULIB_FTELL=0;
21215 GNULIB_FTELLO=0;
21216 GNULIB_FWRITE=0;
21217 GNULIB_GETC=0;
21218 GNULIB_GETCHAR=0;
21219 GNULIB_GETDELIM=0;
21220 GNULIB_GETLINE=0;
21221 GNULIB_OBSTACK_PRINTF=0;
21222 GNULIB_OBSTACK_PRINTF_POSIX=0;
21223 GNULIB_PCLOSE=0;
21224 GNULIB_PERROR=0;
21225 GNULIB_POPEN=0;
21226 GNULIB_PRINTF=0;
21227 GNULIB_PRINTF_POSIX=0;
21228 GNULIB_PUTC=0;
21229 GNULIB_PUTCHAR=0;
21230 GNULIB_PUTS=0;
21231 GNULIB_REMOVE=0;
21232 GNULIB_RENAME=0;
21233 GNULIB_RENAMEAT=0;
21234 GNULIB_SCANF=0;
21235 GNULIB_SNPRINTF=0;
21236 GNULIB_SPRINTF_POSIX=0;
21237 GNULIB_STDIO_H_NONBLOCKING=0;
21238 GNULIB_STDIO_H_SIGPIPE=0;
21239 GNULIB_TMPFILE=0;
21240 GNULIB_VASPRINTF=0;
21241 GNULIB_VFSCANF=0;
21242 GNULIB_VSCANF=0;
21243 GNULIB_VDPRINTF=0;
21244 GNULIB_VFPRINTF=0;
21245 GNULIB_VFPRINTF_POSIX=0;
21246 GNULIB_VPRINTF=0;
21247 GNULIB_VPRINTF_POSIX=0;
21248 GNULIB_VSNPRINTF=0;
21249 GNULIB_VSPRINTF_POSIX=0;
21250 HAVE_DECL_FPURGE=1;
21251 HAVE_DECL_FSEEKO=1;
21252 HAVE_DECL_FTELLO=1;
21253 HAVE_DECL_GETDELIM=1;
21254 HAVE_DECL_GETLINE=1;
21255 HAVE_DECL_OBSTACK_PRINTF=1;
21256 HAVE_DECL_SNPRINTF=1;
21257 HAVE_DECL_VSNPRINTF=1;
21258 HAVE_DPRINTF=1;
21259 HAVE_FSEEKO=1;
21260 HAVE_FTELLO=1;
21261 HAVE_PCLOSE=1;
21262 HAVE_POPEN=1;
21263 HAVE_RENAMEAT=1;
21264 HAVE_VASPRINTF=1;
21265 HAVE_VDPRINTF=1;
21266 REPLACE_DPRINTF=0;
21267 REPLACE_FCLOSE=0;
21268 REPLACE_FDOPEN=0;
21269 REPLACE_FFLUSH=0;
21270 REPLACE_FOPEN=0;
21271 REPLACE_FPRINTF=0;
21272 REPLACE_FPURGE=0;
21273 REPLACE_FREOPEN=0;
21274 REPLACE_FSEEK=0;
21275 REPLACE_FSEEKO=0;
21276 REPLACE_FTELL=0;
21277 REPLACE_FTELLO=0;
21278 REPLACE_GETDELIM=0;
21279 REPLACE_GETLINE=0;
21280 REPLACE_OBSTACK_PRINTF=0;
21281 REPLACE_PERROR=0;
21282 REPLACE_POPEN=0;
21283 REPLACE_PRINTF=0;
21284 REPLACE_REMOVE=0;
21285 REPLACE_RENAME=0;
21286 REPLACE_RENAMEAT=0;
21287 REPLACE_SNPRINTF=0;
21288 REPLACE_SPRINTF=0;
21289 REPLACE_STDIO_READ_FUNCS=0;
21290 REPLACE_STDIO_WRITE_FUNCS=0;
21291 REPLACE_TMPFILE=0;
21292 REPLACE_VASPRINTF=0;
21293 REPLACE_VDPRINTF=0;
21294 REPLACE_VFPRINTF=0;
21295 REPLACE_VPRINTF=0;
21296 REPLACE_VSNPRINTF=0;
21297 REPLACE_VSPRINTF=0;
21299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21300 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21301 if test "${ac_cv_struct_tm+set}" = set; then :
21302 $as_echo_n "(cached) " >&6
21303 else
21304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21305 /* end confdefs.h. */
21306 #include <sys/types.h>
21307 #include <time.h>
21310 main ()
21312 struct tm tm;
21313 int *p = &tm.tm_sec;
21314 return !p;
21316 return 0;
21318 _ACEOF
21319 if ac_fn_c_try_compile "$LINENO"; then :
21320 ac_cv_struct_tm=time.h
21321 else
21322 ac_cv_struct_tm=sys/time.h
21324 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21327 $as_echo "$ac_cv_struct_tm" >&6; }
21328 if test $ac_cv_struct_tm = sys/time.h; then
21330 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21334 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21335 #include <$ac_cv_struct_tm>
21338 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21340 cat >>confdefs.h <<_ACEOF
21341 #define HAVE_STRUCT_TM_TM_ZONE 1
21342 _ACEOF
21347 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21349 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21351 else
21352 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21354 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21355 ac_have_decl=1
21356 else
21357 ac_have_decl=0
21360 cat >>confdefs.h <<_ACEOF
21361 #define HAVE_DECL_TZNAME $ac_have_decl
21362 _ACEOF
21364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21365 $as_echo_n "checking for tzname... " >&6; }
21366 if test "${ac_cv_var_tzname+set}" = set; then :
21367 $as_echo_n "(cached) " >&6
21368 else
21369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21370 /* end confdefs.h. */
21371 #include <time.h>
21372 #if !HAVE_DECL_TZNAME
21373 extern char *tzname[];
21374 #endif
21377 main ()
21379 return tzname[0][0];
21381 return 0;
21383 _ACEOF
21384 if ac_fn_c_try_link "$LINENO"; then :
21385 ac_cv_var_tzname=yes
21386 else
21387 ac_cv_var_tzname=no
21389 rm -f core conftest.err conftest.$ac_objext \
21390 conftest$ac_exeext conftest.$ac_ext
21392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21393 $as_echo "$ac_cv_var_tzname" >&6; }
21394 if test $ac_cv_var_tzname = yes; then
21396 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21402 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21404 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21406 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21422 if test $gl_cv_have_include_next = yes; then
21423 gl_cv_next_string_h='<'string.h'>'
21424 else
21425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21426 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21427 if test "${gl_cv_next_string_h+set}" = set; then :
21428 $as_echo_n "(cached) " >&6
21429 else
21431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21432 /* end confdefs.h. */
21433 #include <string.h>
21435 _ACEOF
21436 case "$host_os" in
21437 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21438 *) gl_absname_cpp="$ac_cpp" ;;
21439 esac
21441 case "$host_os" in
21442 mingw*)
21443 gl_dirsep_regex='[/\\]'
21446 gl_dirsep_regex='\/'
21448 esac
21449 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21451 gl_header_literal_regex=`echo 'string.h' \
21452 | sed -e "$gl_make_literal_regex_sed"`
21453 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21454 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21455 s|^/[^/]|//&|
21459 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21460 sed -n "$gl_absolute_header_sed"`'"'
21464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21465 $as_echo "$gl_cv_next_string_h" >&6; }
21467 NEXT_STRING_H=$gl_cv_next_string_h
21469 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21470 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21471 gl_next_as_first_directive='<'string.h'>'
21472 else
21473 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21474 gl_next_as_first_directive=$gl_cv_next_string_h
21476 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21486 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21487 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21488 ac_have_decl=1
21489 else
21490 ac_have_decl=0
21493 cat >>confdefs.h <<_ACEOF
21494 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21495 _ACEOF
21499 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21500 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21501 ac_have_decl=1
21502 else
21503 ac_have_decl=0
21506 cat >>confdefs.h <<_ACEOF
21507 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21508 _ACEOF
21512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21513 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21514 if test "${ac_cv_header_stat_broken+set}" = set; then :
21515 $as_echo_n "(cached) " >&6
21516 else
21517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21518 /* end confdefs.h. */
21519 #include <sys/types.h>
21520 #include <sys/stat.h>
21522 #if defined S_ISBLK && defined S_IFDIR
21523 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21524 #endif
21526 #if defined S_ISBLK && defined S_IFCHR
21527 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21528 #endif
21530 #if defined S_ISLNK && defined S_IFREG
21531 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21532 #endif
21534 #if defined S_ISSOCK && defined S_IFREG
21535 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21536 #endif
21538 _ACEOF
21539 if ac_fn_c_try_compile "$LINENO"; then :
21540 ac_cv_header_stat_broken=no
21541 else
21542 ac_cv_header_stat_broken=yes
21544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21547 $as_echo "$ac_cv_header_stat_broken" >&6; }
21548 if test $ac_cv_header_stat_broken = yes; then
21550 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21559 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21560 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21561 $as_echo_n "(cached) " >&6
21562 else
21563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21564 /* end confdefs.h. */
21565 #include <time.h>
21568 main ()
21570 static struct timespec x; x.tv_sec = x.tv_nsec;
21572 return 0;
21574 _ACEOF
21575 if ac_fn_c_try_compile "$LINENO"; then :
21576 gl_cv_sys_struct_timespec_in_time_h=yes
21577 else
21578 gl_cv_sys_struct_timespec_in_time_h=no
21580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21583 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21585 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21586 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21587 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21588 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21589 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21590 else
21591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21592 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21593 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21594 $as_echo_n "(cached) " >&6
21595 else
21596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21597 /* end confdefs.h. */
21598 #include <sys/time.h>
21601 main ()
21603 static struct timespec x; x.tv_sec = x.tv_nsec;
21605 return 0;
21607 _ACEOF
21608 if ac_fn_c_try_compile "$LINENO"; then :
21609 gl_cv_sys_struct_timespec_in_sys_time_h=yes
21610 else
21611 gl_cv_sys_struct_timespec_in_sys_time_h=no
21613 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
21616 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
21617 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
21618 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
21619 else
21620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
21621 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
21622 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
21623 $as_echo_n "(cached) " >&6
21624 else
21625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21626 /* end confdefs.h. */
21627 #include <pthread.h>
21630 main ()
21632 static struct timespec x; x.tv_sec = x.tv_nsec;
21634 return 0;
21636 _ACEOF
21637 if ac_fn_c_try_compile "$LINENO"; then :
21638 gl_cv_sys_struct_timespec_in_pthread_h=yes
21639 else
21640 gl_cv_sys_struct_timespec_in_pthread_h=no
21642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
21645 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
21646 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
21647 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
21666 if test $gl_cv_have_include_next = yes; then
21667 gl_cv_next_time_h='<'time.h'>'
21668 else
21669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
21670 $as_echo_n "checking absolute name of <time.h>... " >&6; }
21671 if test "${gl_cv_next_time_h+set}" = set; then :
21672 $as_echo_n "(cached) " >&6
21673 else
21675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21676 /* end confdefs.h. */
21677 #include <time.h>
21679 _ACEOF
21680 case "$host_os" in
21681 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21682 *) gl_absname_cpp="$ac_cpp" ;;
21683 esac
21685 case "$host_os" in
21686 mingw*)
21687 gl_dirsep_regex='[/\\]'
21690 gl_dirsep_regex='\/'
21692 esac
21693 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21695 gl_header_literal_regex=`echo 'time.h' \
21696 | sed -e "$gl_make_literal_regex_sed"`
21697 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21698 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21699 s|^/[^/]|//&|
21703 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21704 sed -n "$gl_absolute_header_sed"`'"'
21708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
21709 $as_echo "$gl_cv_next_time_h" >&6; }
21711 NEXT_TIME_H=$gl_cv_next_time_h
21713 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21714 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21715 gl_next_as_first_directive='<'time.h'>'
21716 else
21717 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21718 gl_next_as_first_directive=$gl_cv_next_time_h
21720 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
21735 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
21736 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
21737 ac_have_decl=1
21738 else
21739 ac_have_decl=0
21742 cat >>confdefs.h <<_ACEOF
21743 #define HAVE_DECL_UNSETENV $ac_have_decl
21744 _ACEOF
21747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
21748 $as_echo_n "checking whether the utimes function works... " >&6; }
21749 if test "${gl_cv_func_working_utimes+set}" = set; then :
21750 $as_echo_n "(cached) " >&6
21751 else
21753 if test "$cross_compiling" = yes; then :
21754 gl_cv_func_working_utimes=no
21755 else
21756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21757 /* end confdefs.h. */
21759 #include <sys/types.h>
21760 #include <sys/stat.h>
21761 #include <fcntl.h>
21762 #include <sys/time.h>
21763 #include <time.h>
21764 #include <unistd.h>
21765 #include <stdlib.h>
21766 #include <stdio.h>
21767 #include <utime.h>
21769 static int
21770 inorder (time_t a, time_t b, time_t c)
21772 return a <= b && b <= c;
21776 main ()
21778 int result = 0;
21779 char const *file = "conftest.utimes";
21780 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
21782 /* Test whether utimes() essentially works. */
21784 struct stat sbuf;
21785 FILE *f = fopen (file, "w");
21786 if (f == NULL)
21787 result |= 1;
21788 else if (fclose (f) != 0)
21789 result |= 1;
21790 else if (utimes (file, timeval) != 0)
21791 result |= 2;
21792 else if (lstat (file, &sbuf) != 0)
21793 result |= 1;
21794 else if (!(sbuf.st_atime == timeval[0].tv_sec
21795 && sbuf.st_mtime == timeval[1].tv_sec))
21796 result |= 4;
21797 if (unlink (file) != 0)
21798 result |= 1;
21801 /* Test whether utimes() with a NULL argument sets the file's timestamp
21802 to the current time. Use 'fstat' as well as 'time' to
21803 determine the "current" time, to accommodate NFS file systems
21804 if there is a time skew between the host and the NFS server. */
21806 int fd = open (file, O_WRONLY|O_CREAT, 0644);
21807 if (fd < 0)
21808 result |= 1;
21809 else
21811 time_t t0, t2;
21812 struct stat st0, st1, st2;
21813 if (time (&t0) == (time_t) -1)
21814 result |= 1;
21815 else if (fstat (fd, &st0) != 0)
21816 result |= 1;
21817 else if (utimes (file, timeval) != 0)
21818 result |= 2;
21819 else if (utimes (file, NULL) != 0)
21820 result |= 8;
21821 else if (fstat (fd, &st1) != 0)
21822 result |= 1;
21823 else if (write (fd, "\n", 1) != 1)
21824 result |= 1;
21825 else if (fstat (fd, &st2) != 0)
21826 result |= 1;
21827 else if (time (&t2) == (time_t) -1)
21828 result |= 1;
21829 else
21831 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
21832 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
21833 if (! (st1.st_atime == st1.st_mtime))
21834 result |= 16;
21835 if (! (m_ok_POSIX || m_ok_NFS))
21836 result |= 32;
21838 if (close (fd) != 0)
21839 result |= 1;
21841 if (unlink (file) != 0)
21842 result |= 1;
21845 /* Test whether utimes() with a NULL argument works on read-only files. */
21847 int fd = open (file, O_WRONLY|O_CREAT, 0444);
21848 if (fd < 0)
21849 result |= 1;
21850 else if (close (fd) != 0)
21851 result |= 1;
21852 else if (utimes (file, NULL) != 0)
21853 result |= 64;
21854 if (unlink (file) != 0)
21855 result |= 1;
21858 return result;
21861 _ACEOF
21862 if ac_fn_c_try_run "$LINENO"; then :
21863 gl_cv_func_working_utimes=yes
21864 else
21865 gl_cv_func_working_utimes=no
21867 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21868 conftest.$ac_objext conftest.beam conftest.$ac_ext
21872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
21873 $as_echo "$gl_cv_func_working_utimes" >&6; }
21875 if test $gl_cv_func_working_utimes = yes; then
21877 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
21885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
21886 $as_echo_n "checking for struct utimbuf... " >&6; }
21887 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
21888 $as_echo_n "(cached) " >&6
21889 else
21890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21891 /* end confdefs.h. */
21892 #if HAVE_SYS_TIME_H
21893 #include <sys/time.h>
21894 #endif
21895 #include <time.h>
21896 #ifdef HAVE_UTIME_H
21897 #include <utime.h>
21898 #endif
21901 main ()
21903 static struct utimbuf x; x.actime = x.modtime;
21905 return 0;
21907 _ACEOF
21908 if ac_fn_c_try_compile "$LINENO"; then :
21909 gl_cv_sys_struct_utimbuf=yes
21910 else
21911 gl_cv_sys_struct_utimbuf=no
21913 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
21916 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
21918 if test $gl_cv_sys_struct_utimbuf = yes; then
21920 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
21934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
21935 $as_echo_n "checking type of array argument to getgroups... " >&6; }
21936 if test "${ac_cv_type_getgroups+set}" = set; then :
21937 $as_echo_n "(cached) " >&6
21938 else
21939 if test "$cross_compiling" = yes; then :
21940 ac_cv_type_getgroups=cross
21941 else
21942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21943 /* end confdefs.h. */
21944 /* Thanks to Mike Rendell for this test. */
21945 $ac_includes_default
21946 #define NGID 256
21947 #undef MAX
21948 #define MAX(x, y) ((x) > (y) ? (x) : (y))
21951 main ()
21953 gid_t gidset[NGID];
21954 int i, n;
21955 union { gid_t gval; long int lval; } val;
21957 val.lval = -1;
21958 for (i = 0; i < NGID; i++)
21959 gidset[i] = val.gval;
21960 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
21961 gidset);
21962 /* Exit non-zero if getgroups seems to require an array of ints. This
21963 happens when gid_t is short int but getgroups modifies an array
21964 of ints. */
21965 return n > 0 && gidset[n] != val.gval;
21967 _ACEOF
21968 if ac_fn_c_try_run "$LINENO"; then :
21969 ac_cv_type_getgroups=gid_t
21970 else
21971 ac_cv_type_getgroups=int
21973 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21974 conftest.$ac_objext conftest.beam conftest.$ac_ext
21977 if test $ac_cv_type_getgroups = cross; then
21978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21979 /* end confdefs.h. */
21980 #include <unistd.h>
21982 _ACEOF
21983 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21984 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
21985 ac_cv_type_getgroups=gid_t
21986 else
21987 ac_cv_type_getgroups=int
21989 rm -f conftest*
21993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
21994 $as_echo "$ac_cv_type_getgroups" >&6; }
21996 cat >>confdefs.h <<_ACEOF
21997 #define GETGROUPS_T $ac_cv_type_getgroups
21998 _ACEOF
22003 if false; then
22004 GL_COND_LIBTOOL_TRUE=
22005 GL_COND_LIBTOOL_FALSE='#'
22006 else
22007 GL_COND_LIBTOOL_TRUE='#'
22008 GL_COND_LIBTOOL_FALSE=
22011 gl_cond_libtool=false
22012 gl_libdeps=
22013 gl_ltlibdeps=
22014 gl_m4_base='m4'
22024 gl_source_base='lib'
22027 if test $ac_cv_func_alloca_works = no; then
22031 # Define an additional variable used in the Makefile substitution.
22032 if test $ac_cv_working_alloca_h = yes; then
22033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
22034 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
22035 if test "${gl_cv_rpl_alloca+set}" = set; then :
22036 $as_echo_n "(cached) " >&6
22037 else
22039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22040 /* end confdefs.h. */
22042 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
22043 Need own alloca
22044 #endif
22046 _ACEOF
22047 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22048 $EGREP "Need own alloca" >/dev/null 2>&1; then :
22049 gl_cv_rpl_alloca=yes
22050 else
22051 gl_cv_rpl_alloca=no
22053 rm -f conftest*
22057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
22058 $as_echo "$gl_cv_rpl_alloca" >&6; }
22059 if test $gl_cv_rpl_alloca = yes; then
22061 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
22063 ALLOCA_H=alloca.h
22064 else
22065 ALLOCA_H=
22067 else
22068 ALLOCA_H=alloca.h
22071 if test -n "$ALLOCA_H"; then
22072 GL_GENERATE_ALLOCA_H_TRUE=
22073 GL_GENERATE_ALLOCA_H_FALSE='#'
22074 else
22075 GL_GENERATE_ALLOCA_H_TRUE='#'
22076 GL_GENERATE_ALLOCA_H_FALSE=
22084 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22085 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22087 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22088 # programs in the package would end up linked with that potentially-shared
22089 # library, inducing unnecessary run-time overhead.
22090 LIB_CLOCK_GETTIME=
22092 gl_saved_libs=$LIBS
22093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22094 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22095 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22096 $as_echo_n "(cached) " >&6
22097 else
22098 ac_func_search_save_LIBS=$LIBS
22099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22100 /* end confdefs.h. */
22102 /* Override any GCC internal prototype to avoid an error.
22103 Use char because int might match the return type of a GCC
22104 builtin and then its argument prototype would still apply. */
22105 #ifdef __cplusplus
22106 extern "C"
22107 #endif
22108 char clock_gettime ();
22110 main ()
22112 return clock_gettime ();
22114 return 0;
22116 _ACEOF
22117 for ac_lib in '' rt posix4; do
22118 if test -z "$ac_lib"; then
22119 ac_res="none required"
22120 else
22121 ac_res=-l$ac_lib
22122 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22124 if ac_fn_c_try_link "$LINENO"; then :
22125 ac_cv_search_clock_gettime=$ac_res
22127 rm -f core conftest.err conftest.$ac_objext \
22128 conftest$ac_exeext
22129 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22130 break
22132 done
22133 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22135 else
22136 ac_cv_search_clock_gettime=no
22138 rm conftest.$ac_ext
22139 LIBS=$ac_func_search_save_LIBS
22141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22142 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22143 ac_res=$ac_cv_search_clock_gettime
22144 if test "$ac_res" != no; then :
22145 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22146 test "$ac_cv_search_clock_gettime" = "none required" ||
22147 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22150 for ac_func in clock_gettime clock_settime
22151 do :
22152 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22153 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22154 eval as_val=\$$as_ac_var
22155 if test "x$as_val" = x""yes; then :
22156 cat >>confdefs.h <<_ACEOF
22157 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22158 _ACEOF
22161 done
22163 LIBS=$gl_saved_libs
22170 cat >>confdefs.h <<_ACEOF
22171 #define GNULIB_CLOSE_STREAM 1
22172 _ACEOF
22201 if test $gl_cv_have_include_next = yes; then
22202 gl_cv_next_dirent_h='<'dirent.h'>'
22203 else
22204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22205 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22206 if test "${gl_cv_next_dirent_h+set}" = set; then :
22207 $as_echo_n "(cached) " >&6
22208 else
22210 if test $ac_cv_header_dirent_h = yes; then
22213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22214 /* end confdefs.h. */
22215 #include <dirent.h>
22217 _ACEOF
22218 case "$host_os" in
22219 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22220 *) gl_absname_cpp="$ac_cpp" ;;
22221 esac
22223 case "$host_os" in
22224 mingw*)
22225 gl_dirsep_regex='[/\\]'
22228 gl_dirsep_regex='\/'
22230 esac
22231 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22233 gl_header_literal_regex=`echo 'dirent.h' \
22234 | sed -e "$gl_make_literal_regex_sed"`
22235 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22236 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22237 s|^/[^/]|//&|
22241 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22242 sed -n "$gl_absolute_header_sed"`'"'
22243 else
22244 gl_cv_next_dirent_h='<'dirent.h'>'
22249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22250 $as_echo "$gl_cv_next_dirent_h" >&6; }
22252 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22254 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22255 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22256 gl_next_as_first_directive='<'dirent.h'>'
22257 else
22258 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22259 gl_next_as_first_directive=$gl_cv_next_dirent_h
22261 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22266 if test $ac_cv_header_dirent_h = yes; then
22267 HAVE_DIRENT_H=1
22268 else
22269 HAVE_DIRENT_H=0
22281 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22284 if test $HAVE_DUP2 = 1; then
22285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22286 $as_echo_n "checking whether dup2 works... " >&6; }
22287 if test "${gl_cv_func_dup2_works+set}" = set; then :
22288 $as_echo_n "(cached) " >&6
22289 else
22290 if test "$cross_compiling" = yes; then :
22291 case "$host_os" in
22292 mingw*) # on this platform, dup2 always returns 0 for success
22293 gl_cv_func_dup2_works="guessing no" ;;
22294 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22295 gl_cv_func_dup2_works="guessing no" ;;
22296 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22297 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22298 gl_cv_func_dup2_works="guessing no" ;;
22299 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22300 gl_cv_func_dup2_works="guessing no" ;;
22301 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22302 gl_cv_func_dup2_works="guessing no" ;;
22303 *) gl_cv_func_dup2_works="guessing yes" ;;
22304 esac
22305 else
22306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22307 /* end confdefs.h. */
22309 #include <unistd.h>
22310 #include <fcntl.h>
22311 #include <errno.h>
22313 main ()
22315 int result = 0;
22316 #ifdef FD_CLOEXEC
22317 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22318 result |= 1;
22319 #endif
22320 if (dup2 (1, 1) == 0)
22321 result |= 2;
22322 #ifdef FD_CLOEXEC
22323 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22324 result |= 4;
22325 #endif
22326 close (0);
22327 if (dup2 (0, 0) != -1)
22328 result |= 8;
22329 /* Many gnulib modules require POSIX conformance of EBADF. */
22330 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22331 result |= 16;
22332 /* Flush out a cygwin core dump. */
22333 if (dup2 (2, -1) != -1 || errno != EBADF)
22334 result |= 32;
22335 return result;
22338 return 0;
22341 _ACEOF
22342 if ac_fn_c_try_run "$LINENO"; then :
22343 gl_cv_func_dup2_works=yes
22344 else
22345 gl_cv_func_dup2_works=no
22347 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22348 conftest.$ac_objext conftest.beam conftest.$ac_ext
22353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22354 $as_echo "$gl_cv_func_dup2_works" >&6; }
22355 case "$gl_cv_func_dup2_works" in
22356 *yes) ;;
22358 REPLACE_DUP2=1
22360 esac
22364 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22373 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22382 GNULIB_DUP2=1
22394 GNULIB_ENVIRON=1
22404 LIB_EXECINFO=''
22405 EXECINFO_H='execinfo.h'
22407 if test $ac_cv_header_execinfo_h = yes; then
22408 gl_saved_libs=$LIBS
22409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22410 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22411 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22412 $as_echo_n "(cached) " >&6
22413 else
22414 ac_func_search_save_LIBS=$LIBS
22415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22416 /* end confdefs.h. */
22418 /* Override any GCC internal prototype to avoid an error.
22419 Use char because int might match the return type of a GCC
22420 builtin and then its argument prototype would still apply. */
22421 #ifdef __cplusplus
22422 extern "C"
22423 #endif
22424 char backtrace_symbols_fd ();
22426 main ()
22428 return backtrace_symbols_fd ();
22430 return 0;
22432 _ACEOF
22433 for ac_lib in '' execinfo; do
22434 if test -z "$ac_lib"; then
22435 ac_res="none required"
22436 else
22437 ac_res=-l$ac_lib
22438 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22440 if ac_fn_c_try_link "$LINENO"; then :
22441 ac_cv_search_backtrace_symbols_fd=$ac_res
22443 rm -f core conftest.err conftest.$ac_objext \
22444 conftest$ac_exeext
22445 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22446 break
22448 done
22449 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22451 else
22452 ac_cv_search_backtrace_symbols_fd=no
22454 rm conftest.$ac_ext
22455 LIBS=$ac_func_search_save_LIBS
22457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22458 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22459 ac_res=$ac_cv_search_backtrace_symbols_fd
22460 if test "$ac_res" != no; then :
22461 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22462 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22463 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22466 LIBS=$gl_saved_libs
22467 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22470 if test -n "$EXECINFO_H"; then
22479 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22485 if test -n "$EXECINFO_H"; then
22486 GL_GENERATE_EXECINFO_H_TRUE=
22487 GL_GENERATE_EXECINFO_H_FALSE='#'
22488 else
22489 GL_GENERATE_EXECINFO_H_TRUE='#'
22490 GL_GENERATE_EXECINFO_H_FALSE=
22501 if test $ac_cv_func_faccessat = no; then
22502 HAVE_FACCESSAT=0
22505 if test $HAVE_FACCESSAT = 0; then
22514 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22517 for ac_func in access
22518 do :
22519 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22520 if test "x$ac_cv_func_access" = x""yes; then :
22521 cat >>confdefs.h <<_ACEOF
22522 #define HAVE_ACCESS 1
22523 _ACEOF
22526 done
22532 cat >>confdefs.h <<_ACEOF
22533 #define GNULIB_FACCESSAT 1
22534 _ACEOF
22542 GNULIB_FACCESSAT=1
22559 if test $gl_cv_have_include_next = yes; then
22560 gl_cv_next_fcntl_h='<'fcntl.h'>'
22561 else
22562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
22563 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
22564 if test "${gl_cv_next_fcntl_h+set}" = set; then :
22565 $as_echo_n "(cached) " >&6
22566 else
22568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22569 /* end confdefs.h. */
22570 #include <fcntl.h>
22572 _ACEOF
22573 case "$host_os" in
22574 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22575 *) gl_absname_cpp="$ac_cpp" ;;
22576 esac
22578 case "$host_os" in
22579 mingw*)
22580 gl_dirsep_regex='[/\\]'
22583 gl_dirsep_regex='\/'
22585 esac
22586 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22588 gl_header_literal_regex=`echo 'fcntl.h' \
22589 | sed -e "$gl_make_literal_regex_sed"`
22590 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22591 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22592 s|^/[^/]|//&|
22596 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22597 sed -n "$gl_absolute_header_sed"`'"'
22601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
22602 $as_echo "$gl_cv_next_fcntl_h" >&6; }
22604 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
22606 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22607 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22608 gl_next_as_first_directive='<'fcntl.h'>'
22609 else
22610 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22611 gl_next_as_first_directive=$gl_cv_next_fcntl_h
22613 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
22629 LIB_FDATASYNC=
22632 if test $ac_cv_have_decl_fdatasync = no; then
22633 HAVE_DECL_FDATASYNC=0
22634 for ac_func in fdatasync
22635 do :
22636 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
22637 if test "x$ac_cv_func_fdatasync" = x""yes; then :
22638 cat >>confdefs.h <<_ACEOF
22639 #define HAVE_FDATASYNC 1
22640 _ACEOF
22643 done
22645 if test $ac_cv_func_fdatasync = no; then
22646 HAVE_FDATASYNC=0
22648 else
22649 gl_saved_libs=$LIBS
22650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
22651 $as_echo_n "checking for library containing fdatasync... " >&6; }
22652 if test "${ac_cv_search_fdatasync+set}" = set; then :
22653 $as_echo_n "(cached) " >&6
22654 else
22655 ac_func_search_save_LIBS=$LIBS
22656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22657 /* end confdefs.h. */
22659 /* Override any GCC internal prototype to avoid an error.
22660 Use char because int might match the return type of a GCC
22661 builtin and then its argument prototype would still apply. */
22662 #ifdef __cplusplus
22663 extern "C"
22664 #endif
22665 char fdatasync ();
22667 main ()
22669 return fdatasync ();
22671 return 0;
22673 _ACEOF
22674 for ac_lib in '' rt posix4; do
22675 if test -z "$ac_lib"; then
22676 ac_res="none required"
22677 else
22678 ac_res=-l$ac_lib
22679 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22681 if ac_fn_c_try_link "$LINENO"; then :
22682 ac_cv_search_fdatasync=$ac_res
22684 rm -f core conftest.err conftest.$ac_objext \
22685 conftest$ac_exeext
22686 if test "${ac_cv_search_fdatasync+set}" = set; then :
22687 break
22689 done
22690 if test "${ac_cv_search_fdatasync+set}" = set; then :
22692 else
22693 ac_cv_search_fdatasync=no
22695 rm conftest.$ac_ext
22696 LIBS=$ac_func_search_save_LIBS
22698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
22699 $as_echo "$ac_cv_search_fdatasync" >&6; }
22700 ac_res=$ac_cv_search_fdatasync
22701 if test "$ac_res" != no; then :
22702 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22703 test "$ac_cv_search_fdatasync" = "none required" ||
22704 LIB_FDATASYNC=$ac_cv_search_fdatasync
22707 LIBS=$gl_saved_libs
22710 if test $HAVE_FDATASYNC = 0; then
22719 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
22727 GNULIB_FDATASYNC=1
22738 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
22739 #include <dirent.h>
22742 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
22743 ac_have_decl=1
22744 else
22745 ac_have_decl=0
22748 cat >>confdefs.h <<_ACEOF
22749 #define HAVE_DECL_FDOPENDIR $ac_have_decl
22750 _ACEOF
22751 if test $ac_have_decl = 1; then :
22753 else
22754 HAVE_DECL_FDOPENDIR=0
22758 if test $ac_cv_func_fdopendir = no; then
22759 HAVE_FDOPENDIR=0
22760 else
22761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
22762 $as_echo_n "checking whether fdopendir works... " >&6; }
22763 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
22764 $as_echo_n "(cached) " >&6
22765 else
22766 if test "$cross_compiling" = yes; then :
22767 case "$host_os" in
22768 # Guess yes on glibc systems.
22769 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
22770 # If we don't know, assume the worst.
22771 *) gl_cv_func_fdopendir_works="guessing no" ;;
22772 esac
22774 else
22775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22776 /* end confdefs.h. */
22778 #include <dirent.h>
22779 #include <fcntl.h>
22780 #include <unistd.h>
22781 #if !HAVE_DECL_FDOPENDIR
22782 extern
22783 # ifdef __cplusplus
22785 # endif
22786 DIR *fdopendir (int);
22787 #endif
22790 main ()
22792 int result = 0;
22793 int fd = open ("conftest.c", O_RDONLY);
22794 if (fd < 0) result |= 1;
22795 if (fdopendir (fd)) result |= 2;
22796 if (close (fd)) result |= 4;
22797 return result;
22799 return 0;
22801 _ACEOF
22802 if ac_fn_c_try_run "$LINENO"; then :
22803 gl_cv_func_fdopendir_works=yes
22804 else
22805 gl_cv_func_fdopendir_works=no
22807 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22808 conftest.$ac_objext conftest.beam conftest.$ac_ext
22812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
22813 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
22814 case "$gl_cv_func_fdopendir_works" in
22815 *yes) ;;
22817 REPLACE_FDOPENDIR=1
22819 esac
22822 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
22831 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
22839 GNULIB_FDOPENDIR=1
22847 cat >>confdefs.h <<_ACEOF
22848 #define GNULIB_FDOPENDIR 1
22849 _ACEOF
22859 fp_headers='
22860 # include <stdio.h>
22861 # if HAVE_STDIO_EXT_H
22862 # include <stdio_ext.h>
22863 # endif
22865 ac_fn_c_check_decl "$LINENO" "__fpending" "ac_cv_have_decl___fpending" "$fp_headers
22867 if test "x$ac_cv_have_decl___fpending" = x""yes; then :
22868 ac_have_decl=1
22869 else
22870 ac_have_decl=0
22873 cat >>confdefs.h <<_ACEOF
22874 #define HAVE_DECL___FPENDING $ac_have_decl
22875 _ACEOF
22878 if test $ac_cv_func___fpending = no; then
22887 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
22890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
22891 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
22892 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
22893 $as_echo_n "(cached) " >&6
22894 else
22896 for ac_expr in \
22898 '# glibc2' \
22899 'fp->_IO_write_ptr - fp->_IO_write_base' \
22901 '# traditional Unix' \
22902 'fp->_ptr - fp->_base' \
22904 '# BSD' \
22905 'fp->_p - fp->_bf._base' \
22907 '# SCO, Unixware' \
22908 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
22910 '# QNX' \
22911 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
22913 '# old glibc?' \
22914 'fp->__bufp - fp->__buffer' \
22916 '# old glibc iostream?' \
22917 'fp->_pptr - fp->_pbase' \
22919 '# emx+gcc' \
22920 'fp->_ptr - fp->_buffer' \
22922 '# Minix' \
22923 'fp->_ptr - fp->_buf' \
22925 '# Plan9' \
22926 'fp->wp - fp->buf' \
22928 '# VMS' \
22929 '(*fp)->_ptr - (*fp)->_base' \
22931 '# e.g., DGUX R4.11; the info is not available' \
22933 ; do
22935 # Skip each embedded comment.
22936 case "$ac_expr" in '#'*) continue;; esac
22938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22939 /* end confdefs.h. */
22940 #include <stdio.h>
22942 main ()
22944 FILE *fp = stdin; (void) ($ac_expr);
22946 return 0;
22948 _ACEOF
22949 if ac_fn_c_try_compile "$LINENO"; then :
22950 fp_done=yes
22953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22954 test "$fp_done" = yes && break
22955 done
22957 ac_cv_sys_pending_output_n_bytes=$ac_expr
22961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
22962 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
22964 cat >>confdefs.h <<_ACEOF
22965 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
22966 _ACEOF
22976 if test $ac_cv_func_fstatat = no; then
22977 HAVE_FSTATAT=0
22978 else
22979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
22980 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
22981 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
22982 $as_echo_n "(cached) " >&6
22983 else
22984 if test "$cross_compiling" = yes; then :
22985 case "$host_os" in
22986 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
22987 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
22988 esac
22990 else
22991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22992 /* end confdefs.h. */
22994 #include <fcntl.h>
22995 #include <sys/stat.h>
22997 main (void)
22999 struct stat a;
23000 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23003 _ACEOF
23004 if ac_fn_c_try_run "$LINENO"; then :
23005 gl_cv_func_fstatat_zero_flag=yes
23006 else
23007 gl_cv_func_fstatat_zero_flag=no
23009 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23010 conftest.$ac_objext conftest.beam conftest.$ac_ext
23015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23016 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23018 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23019 *yes+*yes) ;;
23020 *) REPLACE_FSTATAT=1
23021 case $gl_cv_func_fstatat_zero_flag in
23022 *yes)
23024 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23027 esac
23029 esac
23032 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23041 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23049 GNULIB_FSTATAT=1
23058 if test $ac_cv_func_fsync = no; then
23059 HAVE_FSYNC=0
23062 if test $HAVE_FSYNC = 0; then
23071 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23080 GNULIB_FSYNC=1
23088 # Persuade glibc <stdlib.h> to declare getloadavg().
23091 gl_save_LIBS=$LIBS
23093 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23094 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23095 HAVE_GETLOADAVG=1
23096 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23097 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23099 else
23100 gl_func_getloadavg_done=no
23102 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23103 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23104 # to get the right answer into the cache.
23105 # For kstat on solaris, we need to test for libelf and libkvm to force the
23106 # definition of SVR4 below.
23107 if test $gl_func_getloadavg_done = no; then
23108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23109 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23110 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23111 $as_echo_n "(cached) " >&6
23112 else
23113 ac_check_lib_save_LIBS=$LIBS
23114 LIBS="-lelf $LIBS"
23115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23116 /* end confdefs.h. */
23118 /* Override any GCC internal prototype to avoid an error.
23119 Use char because int might match the return type of a GCC
23120 builtin and then its argument prototype would still apply. */
23121 #ifdef __cplusplus
23122 extern "C"
23123 #endif
23124 char elf_begin ();
23126 main ()
23128 return elf_begin ();
23130 return 0;
23132 _ACEOF
23133 if ac_fn_c_try_link "$LINENO"; then :
23134 ac_cv_lib_elf_elf_begin=yes
23135 else
23136 ac_cv_lib_elf_elf_begin=no
23138 rm -f core conftest.err conftest.$ac_objext \
23139 conftest$ac_exeext conftest.$ac_ext
23140 LIBS=$ac_check_lib_save_LIBS
23142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23143 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23144 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23145 LIBS="-lelf $LIBS"
23148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23149 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23150 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23151 $as_echo_n "(cached) " >&6
23152 else
23153 ac_check_lib_save_LIBS=$LIBS
23154 LIBS="-lkvm $LIBS"
23155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23156 /* end confdefs.h. */
23158 /* Override any GCC internal prototype to avoid an error.
23159 Use char because int might match the return type of a GCC
23160 builtin and then its argument prototype would still apply. */
23161 #ifdef __cplusplus
23162 extern "C"
23163 #endif
23164 char kvm_open ();
23166 main ()
23168 return kvm_open ();
23170 return 0;
23172 _ACEOF
23173 if ac_fn_c_try_link "$LINENO"; then :
23174 ac_cv_lib_kvm_kvm_open=yes
23175 else
23176 ac_cv_lib_kvm_kvm_open=no
23178 rm -f core conftest.err conftest.$ac_objext \
23179 conftest$ac_exeext conftest.$ac_ext
23180 LIBS=$ac_check_lib_save_LIBS
23182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23183 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23184 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23185 LIBS="-lkvm $LIBS"
23188 # Check for the 4.4BSD definition of getloadavg.
23189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23190 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23191 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23192 $as_echo_n "(cached) " >&6
23193 else
23194 ac_check_lib_save_LIBS=$LIBS
23195 LIBS="-lutil $LIBS"
23196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23197 /* end confdefs.h. */
23199 /* Override any GCC internal prototype to avoid an error.
23200 Use char because int might match the return type of a GCC
23201 builtin and then its argument prototype would still apply. */
23202 #ifdef __cplusplus
23203 extern "C"
23204 #endif
23205 char getloadavg ();
23207 main ()
23209 return getloadavg ();
23211 return 0;
23213 _ACEOF
23214 if ac_fn_c_try_link "$LINENO"; then :
23215 ac_cv_lib_util_getloadavg=yes
23216 else
23217 ac_cv_lib_util_getloadavg=no
23219 rm -f core conftest.err conftest.$ac_objext \
23220 conftest$ac_exeext conftest.$ac_ext
23221 LIBS=$ac_check_lib_save_LIBS
23223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23224 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23225 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23226 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23231 if test $gl_func_getloadavg_done = no; then
23232 # There is a commonly available library for RS/6000 AIX.
23233 # Since it is not a standard part of AIX, it might be installed locally.
23234 gl_getloadavg_LIBS=$LIBS
23235 LIBS="-L/usr/local/lib $LIBS"
23236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23237 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23238 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23239 $as_echo_n "(cached) " >&6
23240 else
23241 ac_check_lib_save_LIBS=$LIBS
23242 LIBS="-lgetloadavg $LIBS"
23243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23244 /* end confdefs.h. */
23246 /* Override any GCC internal prototype to avoid an error.
23247 Use char because int might match the return type of a GCC
23248 builtin and then its argument prototype would still apply. */
23249 #ifdef __cplusplus
23250 extern "C"
23251 #endif
23252 char getloadavg ();
23254 main ()
23256 return getloadavg ();
23258 return 0;
23260 _ACEOF
23261 if ac_fn_c_try_link "$LINENO"; then :
23262 ac_cv_lib_getloadavg_getloadavg=yes
23263 else
23264 ac_cv_lib_getloadavg_getloadavg=no
23266 rm -f core conftest.err conftest.$ac_objext \
23267 conftest$ac_exeext conftest.$ac_ext
23268 LIBS=$ac_check_lib_save_LIBS
23270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23271 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23272 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23273 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23274 else
23275 LIBS=$gl_getloadavg_LIBS
23280 # Set up the replacement function if necessary.
23281 if test $gl_func_getloadavg_done = no; then
23282 HAVE_GETLOADAVG=0
23284 # Solaris has libkstat which does not require root.
23285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23286 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23287 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23288 $as_echo_n "(cached) " >&6
23289 else
23290 ac_check_lib_save_LIBS=$LIBS
23291 LIBS="-lkstat $LIBS"
23292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23293 /* end confdefs.h. */
23295 /* Override any GCC internal prototype to avoid an error.
23296 Use char because int might match the return type of a GCC
23297 builtin and then its argument prototype would still apply. */
23298 #ifdef __cplusplus
23299 extern "C"
23300 #endif
23301 char kstat_open ();
23303 main ()
23305 return kstat_open ();
23307 return 0;
23309 _ACEOF
23310 if ac_fn_c_try_link "$LINENO"; then :
23311 ac_cv_lib_kstat_kstat_open=yes
23312 else
23313 ac_cv_lib_kstat_kstat_open=no
23315 rm -f core conftest.err conftest.$ac_objext \
23316 conftest$ac_exeext conftest.$ac_ext
23317 LIBS=$ac_check_lib_save_LIBS
23319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23320 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23321 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23322 cat >>confdefs.h <<_ACEOF
23323 #define HAVE_LIBKSTAT 1
23324 _ACEOF
23326 LIBS="-lkstat $LIBS"
23330 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23332 # AIX has libperfstat which does not require root
23333 if test $gl_func_getloadavg_done = no; then
23334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23335 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23336 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23337 $as_echo_n "(cached) " >&6
23338 else
23339 ac_check_lib_save_LIBS=$LIBS
23340 LIBS="-lperfstat $LIBS"
23341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23342 /* end confdefs.h. */
23344 /* Override any GCC internal prototype to avoid an error.
23345 Use char because int might match the return type of a GCC
23346 builtin and then its argument prototype would still apply. */
23347 #ifdef __cplusplus
23348 extern "C"
23349 #endif
23350 char perfstat_cpu_total ();
23352 main ()
23354 return perfstat_cpu_total ();
23356 return 0;
23358 _ACEOF
23359 if ac_fn_c_try_link "$LINENO"; then :
23360 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23361 else
23362 ac_cv_lib_perfstat_perfstat_cpu_total=no
23364 rm -f core conftest.err conftest.$ac_objext \
23365 conftest$ac_exeext conftest.$ac_ext
23366 LIBS=$ac_check_lib_save_LIBS
23368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
23369 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
23370 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
23371 cat >>confdefs.h <<_ACEOF
23372 #define HAVE_LIBPERFSTAT 1
23373 _ACEOF
23375 LIBS="-lperfstat $LIBS"
23379 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
23382 if test $gl_func_getloadavg_done = no; then
23383 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
23384 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
23385 gl_func_getloadavg_done=yes
23387 $as_echo "#define DGUX 1" >>confdefs.h
23389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
23390 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
23391 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
23392 $as_echo_n "(cached) " >&6
23393 else
23394 ac_check_lib_save_LIBS=$LIBS
23395 LIBS="-ldgc $LIBS"
23396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23397 /* end confdefs.h. */
23399 /* Override any GCC internal prototype to avoid an error.
23400 Use char because int might match the return type of a GCC
23401 builtin and then its argument prototype would still apply. */
23402 #ifdef __cplusplus
23403 extern "C"
23404 #endif
23405 char dg_sys_info ();
23407 main ()
23409 return dg_sys_info ();
23411 return 0;
23413 _ACEOF
23414 if ac_fn_c_try_link "$LINENO"; then :
23415 ac_cv_lib_dgc_dg_sys_info=yes
23416 else
23417 ac_cv_lib_dgc_dg_sys_info=no
23419 rm -f core conftest.err conftest.$ac_objext \
23420 conftest$ac_exeext conftest.$ac_ext
23421 LIBS=$ac_check_lib_save_LIBS
23423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
23424 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
23425 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
23426 cat >>confdefs.h <<_ACEOF
23427 #define HAVE_LIBDGC 1
23428 _ACEOF
23430 LIBS="-ldgc $LIBS"
23442 if test "x$gl_save_LIBS" = x; then
23443 GETLOADAVG_LIBS=$LIBS
23444 else
23445 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
23447 LIBS=$gl_save_LIBS
23450 # Test whether the system declares getloadavg. Solaris has the function
23451 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
23452 for ac_header in sys/loadavg.h
23453 do :
23454 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
23455 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
23456 cat >>confdefs.h <<_ACEOF
23457 #define HAVE_SYS_LOADAVG_H 1
23458 _ACEOF
23462 done
23464 if test $ac_cv_header_sys_loadavg_h = yes; then
23465 HAVE_SYS_LOADAVG_H=1
23466 else
23467 HAVE_SYS_LOADAVG_H=0
23469 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
23470 # include <sys/loadavg.h>
23471 #endif
23472 #include <stdlib.h>
23474 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
23476 else
23477 HAVE_DECL_GETLOADAVG=0
23481 if test $HAVE_GETLOADAVG = 0; then
23490 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
23493 # Figure out what our getloadavg.c needs.
23497 # On HPUX9, an unprivileged user can get load averages this way.
23498 if test $gl_func_getloadavg_done = no; then
23499 for ac_func in pstat_getdynamic
23500 do :
23501 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
23502 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
23503 cat >>confdefs.h <<_ACEOF
23504 #define HAVE_PSTAT_GETDYNAMIC 1
23505 _ACEOF
23506 gl_func_getloadavg_done=yes
23508 done
23512 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
23513 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
23514 # Irix 4.0.5F has the header but not the library.
23515 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
23516 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
23517 gl_func_getloadavg_done=yes
23519 $as_echo "#define SVR4 1" >>confdefs.h
23523 if test $gl_func_getloadavg_done = no; then
23524 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
23525 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
23526 gl_func_getloadavg_done=yes
23528 $as_echo "#define UMAX 1" >>confdefs.h
23531 $as_echo "#define UMAX4_3 1" >>confdefs.h
23538 if test $gl_func_getloadavg_done = no; then
23539 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
23540 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
23541 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
23548 if test $gl_func_getloadavg_done = no; then
23549 for ac_header in mach/mach.h
23550 do :
23551 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
23552 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
23553 cat >>confdefs.h <<_ACEOF
23554 #define HAVE_MACH_MACH_H 1
23555 _ACEOF
23559 done
23563 for ac_header in nlist.h
23564 do :
23565 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
23566 if test "x$ac_cv_header_nlist_h" = x""yes; then :
23567 cat >>confdefs.h <<_ACEOF
23568 #define HAVE_NLIST_H 1
23569 _ACEOF
23570 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
23572 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
23574 cat >>confdefs.h <<_ACEOF
23575 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
23576 _ACEOF
23581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23582 /* end confdefs.h. */
23583 #include <nlist.h>
23585 main ()
23587 struct nlist x;
23588 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
23589 x.n_un.n_name = "";
23590 #else
23591 x.n_name = "";
23592 #endif
23594 return 0;
23596 _ACEOF
23597 if ac_fn_c_try_link "$LINENO"; then :
23599 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
23602 rm -f core conftest.err conftest.$ac_objext \
23603 conftest$ac_exeext conftest.$ac_ext
23607 done
23615 GNULIB_GETLOADAVG=1
23626 if test $REPLACE_GETOPT = 1; then
23635 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23645 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23650 GNULIB_GL_UNISTD_H_GETOPT=1
23659 REPLACE_GETOPT=0
23660 if test -n "$gl_replace_getopt"; then
23661 REPLACE_GETOPT=1
23664 if test $REPLACE_GETOPT = 1; then
23666 GETOPT_H=getopt.h
23668 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
23674 if test $REPLACE_GETOPT = 1; then
23683 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
23693 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
23698 GNULIB_GL_UNISTD_H_GETOPT=1
23712 gl_gettimeofday_timezone=void
23713 if test $ac_cv_func_gettimeofday != yes; then
23714 HAVE_GETTIMEOFDAY=0
23715 else
23719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
23720 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
23721 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
23722 $as_echo_n "(cached) " >&6
23723 else
23724 if test "$cross_compiling" = yes; then :
23725 # When cross-compiling:
23726 case "$host_os" in
23727 # Guess all is fine on glibc systems.
23728 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
23729 # If we don't know, assume the worst.
23730 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
23731 esac
23733 else
23734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23735 /* end confdefs.h. */
23736 #include <string.h>
23737 #include <sys/time.h>
23738 #include <time.h>
23739 #include <stdlib.h>
23742 main ()
23745 time_t t = 0;
23746 struct tm *lt;
23747 struct tm saved_lt;
23748 struct timeval tv;
23749 lt = localtime (&t);
23750 saved_lt = *lt;
23751 gettimeofday (&tv, NULL);
23752 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
23755 return 0;
23757 _ACEOF
23758 if ac_fn_c_try_run "$LINENO"; then :
23759 gl_cv_func_gettimeofday_clobber=no
23760 else
23761 gl_cv_func_gettimeofday_clobber=yes
23763 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23764 conftest.$ac_objext conftest.beam conftest.$ac_ext
23768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
23769 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
23771 case "$gl_cv_func_gettimeofday_clobber" in
23772 *yes)
23773 REPLACE_GETTIMEOFDAY=1
23776 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
23779 $as_echo "#define localtime rpl_localtime" >>confdefs.h
23783 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
23786 esac
23788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
23789 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
23790 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
23791 $as_echo_n "(cached) " >&6
23792 else
23793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23794 /* end confdefs.h. */
23795 #include <sys/time.h>
23796 struct timeval c;
23797 int gettimeofday (struct timeval *restrict, void *restrict);
23800 main ()
23802 /* glibc uses struct timezone * rather than the POSIX void *
23803 if _GNU_SOURCE is defined. However, since the only portable
23804 use of gettimeofday uses NULL as the second parameter, and
23805 since the glibc definition is actually more typesafe, it is
23806 not worth wrapping this to get a compliant signature. */
23807 int (*f) (struct timeval *restrict, void *restrict)
23808 = gettimeofday;
23809 int x = f (&c, 0);
23810 return !(x | c.tv_sec | c.tv_usec);
23813 return 0;
23815 _ACEOF
23816 if ac_fn_c_try_compile "$LINENO"; then :
23817 gl_cv_func_gettimeofday_posix_signature=yes
23818 else
23819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23820 /* end confdefs.h. */
23821 #include <sys/time.h>
23822 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
23825 main ()
23829 return 0;
23831 _ACEOF
23832 if ac_fn_c_try_compile "$LINENO"; then :
23833 gl_cv_func_gettimeofday_posix_signature=almost
23834 else
23835 gl_cv_func_gettimeofday_posix_signature=no
23837 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
23842 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
23843 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
23844 gl_gettimeofday_timezone='struct timezone'
23845 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
23846 REPLACE_GETTIMEOFDAY=1
23848 if test $REPLACE_STRUCT_TIMEVAL = 1; then
23849 REPLACE_GETTIMEOFDAY=1
23854 cat >>confdefs.h <<_ACEOF
23855 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
23856 _ACEOF
23859 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
23868 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
23871 for ac_header in sys/timeb.h
23872 do :
23873 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
23874 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
23875 cat >>confdefs.h <<_ACEOF
23876 #define HAVE_SYS_TIMEB_H 1
23877 _ACEOF
23881 done
23883 for ac_func in _ftime
23884 do :
23885 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
23886 if test "x$ac_cv_func__ftime" = x""yes; then :
23887 cat >>confdefs.h <<_ACEOF
23888 #define HAVE__FTIME 1
23889 _ACEOF
23892 done
23901 GNULIB_GETTIMEOFDAY=1
23912 if test $ac_cv_func_lstat = yes; then
23914 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
23915 *no)
23916 REPLACE_LSTAT=1
23918 esac
23919 else
23920 HAVE_LSTAT=0
23923 if test $REPLACE_LSTAT = 1; then
23932 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
23941 GNULIB_LSTAT=1
23952 if test $ac_cv_have_decl_memrchr = no; then
23953 HAVE_DECL_MEMRCHR=0
23956 for ac_func in memrchr
23957 do :
23958 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
23959 if test "x$ac_cv_func_memrchr" = x""yes; then :
23960 cat >>confdefs.h <<_ACEOF
23961 #define HAVE_MEMRCHR 1
23962 _ACEOF
23965 done
23968 if test $ac_cv_func_memrchr = no; then
23977 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
23986 GNULIB_MEMRCHR=1
23998 if test $APPLE_UNIVERSAL_BUILD = 1; then
23999 # A universal build on Apple Mac OS X platforms.
24000 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24001 # But we need a configuration result that is valid in both modes.
24002 gl_cv_func_working_mktime=no
24004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24005 $as_echo_n "checking for working mktime... " >&6; }
24006 if test "${gl_cv_func_working_mktime+set}" = set; then :
24007 $as_echo_n "(cached) " >&6
24008 else
24009 if test "$cross_compiling" = yes; then :
24010 gl_cv_func_working_mktime=no
24011 else
24012 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24013 /* end confdefs.h. */
24014 /* Test program from Paul Eggert and Tony Leneis. */
24015 #include <limits.h>
24016 #include <stdlib.h>
24017 #include <time.h>
24019 #ifdef HAVE_UNISTD_H
24020 # include <unistd.h>
24021 #endif
24023 #if HAVE_DECL_ALARM
24024 # include <signal.h>
24025 #endif
24027 /* Work around redefinition to rpl_putenv by other config tests. */
24028 #undef putenv
24030 static time_t time_t_max;
24031 static time_t time_t_min;
24033 /* Values we'll use to set the TZ environment variable. */
24034 static char *tz_strings[] = {
24035 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24036 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24038 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24040 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24041 Based on a problem report from Andreas Jaeger. */
24042 static int
24043 spring_forward_gap ()
24045 /* glibc (up to about 1998-10-07) failed this test. */
24046 struct tm tm;
24048 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24049 instead of "TZ=America/Vancouver" in order to detect the bug even
24050 on systems that don't support the Olson extension, or don't have the
24051 full zoneinfo tables installed. */
24052 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24054 tm.tm_year = 98;
24055 tm.tm_mon = 3;
24056 tm.tm_mday = 5;
24057 tm.tm_hour = 2;
24058 tm.tm_min = 0;
24059 tm.tm_sec = 0;
24060 tm.tm_isdst = -1;
24061 return mktime (&tm) != (time_t) -1;
24064 static int
24065 mktime_test1 (time_t now)
24067 struct tm *lt;
24068 return ! (lt = localtime (&now)) || mktime (lt) == now;
24071 static int
24072 mktime_test (time_t now)
24074 return (mktime_test1 (now)
24075 && mktime_test1 ((time_t) (time_t_max - now))
24076 && mktime_test1 ((time_t) (time_t_min + now)));
24079 static int
24080 irix_6_4_bug ()
24082 /* Based on code from Ariel Faigon. */
24083 struct tm tm;
24084 tm.tm_year = 96;
24085 tm.tm_mon = 3;
24086 tm.tm_mday = 0;
24087 tm.tm_hour = 0;
24088 tm.tm_min = 0;
24089 tm.tm_sec = 0;
24090 tm.tm_isdst = -1;
24091 mktime (&tm);
24092 return tm.tm_mon == 2 && tm.tm_mday == 31;
24095 static int
24096 bigtime_test (int j)
24098 struct tm tm;
24099 time_t now;
24100 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24101 now = mktime (&tm);
24102 if (now != (time_t) -1)
24104 struct tm *lt = localtime (&now);
24105 if (! (lt
24106 && lt->tm_year == tm.tm_year
24107 && lt->tm_mon == tm.tm_mon
24108 && lt->tm_mday == tm.tm_mday
24109 && lt->tm_hour == tm.tm_hour
24110 && lt->tm_min == tm.tm_min
24111 && lt->tm_sec == tm.tm_sec
24112 && lt->tm_yday == tm.tm_yday
24113 && lt->tm_wday == tm.tm_wday
24114 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24115 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24116 return 0;
24118 return 1;
24121 static int
24122 year_2050_test ()
24124 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24125 ignoring leap seconds. */
24126 unsigned long int answer = 2527315200UL;
24128 struct tm tm;
24129 time_t t;
24130 tm.tm_year = 2050 - 1900;
24131 tm.tm_mon = 2 - 1;
24132 tm.tm_mday = 1;
24133 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24134 tm.tm_isdst = -1;
24136 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24137 instead of "TZ=America/Vancouver" in order to detect the bug even
24138 on systems that don't support the Olson extension, or don't have the
24139 full zoneinfo tables installed. */
24140 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24142 t = mktime (&tm);
24144 /* Check that the result is either a failure, or close enough
24145 to the correct answer that we can assume the discrepancy is
24146 due to leap seconds. */
24147 return (t == (time_t) -1
24148 || (0 < t && answer - 120 <= t && t <= answer + 120));
24152 main ()
24154 int result = 0;
24155 time_t t, delta;
24156 int i, j;
24157 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24158 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24160 #if HAVE_DECL_ALARM
24161 /* This test makes some buggy mktime implementations loop.
24162 Give up after 60 seconds; a mktime slower than that
24163 isn't worth using anyway. */
24164 signal (SIGALRM, SIG_DFL);
24165 alarm (60);
24166 #endif
24168 time_t_max = (! time_t_signed
24169 ? (time_t) -1
24170 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24171 * 2 + 1));
24172 time_t_min = (! time_t_signed
24173 ? (time_t) 0
24174 : time_t_signed_magnitude
24175 ? ~ (time_t) 0
24176 : ~ time_t_max);
24178 delta = time_t_max / 997; /* a suitable prime number */
24179 for (i = 0; i < N_STRINGS; i++)
24181 if (tz_strings[i])
24182 putenv (tz_strings[i]);
24184 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24185 if (! mktime_test (t))
24186 result |= 1;
24187 if ((result & 2) == 0
24188 && ! (mktime_test ((time_t) 1)
24189 && mktime_test ((time_t) (60 * 60))
24190 && mktime_test ((time_t) (60 * 60 * 24))))
24191 result |= 2;
24193 for (j = 1; (result & 4) == 0; j <<= 1)
24195 if (! bigtime_test (j))
24196 result |= 4;
24197 if (INT_MAX / 2 < j)
24198 break;
24200 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24201 result |= 8;
24203 if (! irix_6_4_bug ())
24204 result |= 16;
24205 if (! spring_forward_gap ())
24206 result |= 32;
24207 if (! year_2050_test ())
24208 result |= 64;
24209 return result;
24211 _ACEOF
24212 if ac_fn_c_try_run "$LINENO"; then :
24213 gl_cv_func_working_mktime=yes
24214 else
24215 gl_cv_func_working_mktime=no
24217 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24218 conftest.$ac_objext conftest.beam conftest.$ac_ext
24223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24224 $as_echo "$gl_cv_func_working_mktime" >&6; }
24226 if test $gl_cv_func_working_mktime = no; then
24227 REPLACE_MKTIME=1
24228 else
24229 REPLACE_MKTIME=0
24232 if test $REPLACE_MKTIME = 1; then
24241 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24250 GNULIB_MKTIME=1
24262 if test $ac_cv_func_pselect = yes; then
24263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24264 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24265 if test "${gl_cv_sig_pselect+set}" = set; then :
24266 $as_echo_n "(cached) " >&6
24267 else
24268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24269 /* end confdefs.h. */
24270 #include <sys/select.h>
24273 main ()
24275 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24276 struct timespec const *restrict,
24277 sigset_t const *restrict) = pselect;
24278 return !p;
24280 return 0;
24282 _ACEOF
24283 if ac_fn_c_try_link "$LINENO"; then :
24284 gl_cv_sig_pselect=yes
24285 else
24286 gl_cv_sig_pselect=no
24288 rm -f core conftest.err conftest.$ac_objext \
24289 conftest$ac_exeext conftest.$ac_ext
24291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24292 $as_echo "$gl_cv_sig_pselect" >&6; }
24294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24295 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24296 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24297 $as_echo_n "(cached) " >&6
24298 else
24300 if test "$cross_compiling" = yes; then :
24302 case "$host_os" in
24303 # Guess yes on glibc systems.
24304 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24305 # If we don't know, assume the worst.
24306 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
24307 esac
24309 else
24310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24311 /* end confdefs.h. */
24313 #include <sys/types.h>
24314 #include <sys/time.h>
24315 #if HAVE_SYS_SELECT_H
24316 # include <sys/select.h>
24317 #endif
24318 #include <unistd.h>
24319 #include <errno.h>
24322 main ()
24325 fd_set set;
24326 dup2(0, 16);
24327 FD_ZERO(&set);
24328 FD_SET(16, &set);
24329 close(16);
24330 struct timespec timeout;
24331 timeout.tv_sec = 0;
24332 timeout.tv_nsec = 5000;
24333 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
24336 return 0;
24338 _ACEOF
24339 if ac_fn_c_try_run "$LINENO"; then :
24340 gl_cv_func_pselect_detects_ebadf=yes
24341 else
24342 gl_cv_func_pselect_detects_ebadf=no
24344 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24345 conftest.$ac_objext conftest.beam conftest.$ac_ext
24350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
24351 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
24352 case $gl_cv_func_pselect_detects_ebadf in
24353 *yes) ;;
24354 *) REPLACE_PSELECT=1 ;;
24355 esac
24358 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
24359 REPLACE_PSELECT=1
24362 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
24371 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
24379 GNULIB_PSELECT=1
24389 LIB_PTHREAD_SIGMASK=
24394 if test "$gl_threads_api" = posix; then
24395 if test $ac_cv_func_pthread_sigmask = yes; then
24397 else
24398 if test -n "$LIBMULTITHREAD"; then
24399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
24400 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
24401 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
24402 $as_echo_n "(cached) " >&6
24403 else
24404 gl_save_LIBS="$LIBS"
24405 LIBS="$LIBS $LIBMULTITHREAD"
24406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24407 /* end confdefs.h. */
24408 #include <pthread.h>
24409 #include <signal.h>
24412 main ()
24414 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
24416 return 0;
24419 _ACEOF
24420 if ac_fn_c_try_link "$LINENO"; then :
24421 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
24422 else
24423 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
24425 rm -f core conftest.err conftest.$ac_objext \
24426 conftest$ac_exeext conftest.$ac_ext
24427 LIBS="$gl_save_LIBS"
24430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
24431 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
24432 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
24433 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
24434 else
24435 HAVE_PTHREAD_SIGMASK=0
24437 else
24438 HAVE_PTHREAD_SIGMASK=0
24441 else
24442 if test $ac_cv_func_pthread_sigmask = yes; then
24443 REPLACE_PTHREAD_SIGMASK=1
24444 else
24445 HAVE_PTHREAD_SIGMASK=0
24452 if test $HAVE_PTHREAD_SIGMASK = 1; then
24455 if test -z "$LIB_PTHREAD_SIGMASK"; then
24456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
24457 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
24458 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
24459 $as_echo_n "(cached) " >&6
24460 else
24462 if test "$cross_compiling" = yes; then :
24464 case "$host_os" in
24465 freebsd* | hpux* | solaris | solaris2.[2-9]*)
24466 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
24468 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
24469 esac
24471 else
24472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24473 /* end confdefs.h. */
24475 #include <pthread.h>
24476 #include <signal.h>
24477 #include <stddef.h>
24478 int main ()
24480 sigset_t set;
24481 sigemptyset (&set);
24482 return pthread_sigmask (1729, &set, NULL) != 0;
24484 _ACEOF
24485 if ac_fn_c_try_run "$LINENO"; then :
24486 gl_cv_func_pthread_sigmask_in_libc_works=no
24487 else
24488 gl_cv_func_pthread_sigmask_in_libc_works=yes
24490 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24491 conftest.$ac_objext conftest.beam conftest.$ac_ext
24496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
24497 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
24498 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
24499 *no)
24500 REPLACE_PTHREAD_SIGMASK=1
24502 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
24505 esac
24508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
24509 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
24510 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
24511 $as_echo_n "(cached) " >&6
24512 else
24514 gl_save_LIBS="$LIBS"
24515 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
24516 if test "$cross_compiling" = yes; then :
24517 case "$host_os" in
24518 cygwin*)
24519 gl_cv_func_pthread_sigmask_return_works="guessing no";;
24521 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
24522 esac
24524 else
24525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24526 /* end confdefs.h. */
24528 #include <pthread.h>
24529 #include <signal.h>
24530 #include <stddef.h>
24531 int main ()
24533 sigset_t set;
24534 sigemptyset (&set);
24535 if (pthread_sigmask (1729, &set, NULL) == -1)
24536 return 1;
24537 return 0;
24539 _ACEOF
24540 if ac_fn_c_try_run "$LINENO"; then :
24541 gl_cv_func_pthread_sigmask_return_works=yes
24542 else
24543 gl_cv_func_pthread_sigmask_return_works=no
24545 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24546 conftest.$ac_objext conftest.beam conftest.$ac_ext
24549 LIBS="$gl_save_LIBS"
24552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
24553 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
24554 case "$gl_cv_func_pthread_sigmask_return_works" in
24555 *no)
24556 REPLACE_PTHREAD_SIGMASK=1
24558 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
24561 esac
24563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
24564 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
24565 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
24566 $as_echo_n "(cached) " >&6
24567 else
24569 case "$host_os" in
24570 irix*)
24571 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
24573 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
24574 esac
24575 gl_save_LIBS="$LIBS"
24576 LIBS="$LIBS $LIBMULTITHREAD"
24577 if test "$cross_compiling" = yes; then :
24579 else
24580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24581 /* end confdefs.h. */
24583 #include <pthread.h>
24584 #include <signal.h>
24585 #include <stdio.h>
24586 #include <stdlib.h>
24587 #include <unistd.h>
24588 static volatile int sigint_occurred;
24589 static void
24590 sigint_handler (int sig)
24592 sigint_occurred++;
24594 int main ()
24596 sigset_t set;
24597 int pid = getpid ();
24598 char command[80];
24599 signal (SIGINT, sigint_handler);
24600 sigemptyset (&set);
24601 sigaddset (&set, SIGINT);
24602 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
24603 return 1;
24604 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
24605 if (!(system (command) == 0))
24606 return 2;
24607 sleep (2);
24608 if (!(sigint_occurred == 0))
24609 return 3;
24610 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
24611 return 4;
24612 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
24613 return 5;
24614 return 0;
24616 _ACEOF
24617 if ac_fn_c_try_run "$LINENO"; then :
24619 else
24620 gl_cv_func_pthread_sigmask_unblock_works=no
24622 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24623 conftest.$ac_objext conftest.beam conftest.$ac_ext
24626 LIBS="$gl_save_LIBS"
24629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
24630 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
24631 case "$gl_cv_func_pthread_sigmask_unblock_works" in
24632 *no)
24633 REPLACE_PTHREAD_SIGMASK=1
24635 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
24638 esac
24641 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
24650 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
24653 if test $HAVE_PTHREAD_SIGMASK = 1; then
24655 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
24665 GNULIB_PTHREAD_SIGMASK=1
24673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
24674 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
24675 if test "${gl_cv_func_svid_putenv+set}" = set; then :
24676 $as_echo_n "(cached) " >&6
24677 else
24678 if test "$cross_compiling" = yes; then :
24679 case "$host_os" in
24680 # Guess yes on glibc systems.
24681 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
24682 # If we don't know, assume the worst.
24683 *) gl_cv_func_svid_putenv="guessing no" ;;
24684 esac
24686 else
24687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24688 /* end confdefs.h. */
24689 $ac_includes_default
24691 main ()
24694 /* Put it in env. */
24695 if (putenv ("CONFTEST_putenv=val"))
24696 return 1;
24698 /* Try to remove it. */
24699 if (putenv ("CONFTEST_putenv"))
24700 return 2;
24702 /* Make sure it was deleted. */
24703 if (getenv ("CONFTEST_putenv") != 0)
24704 return 3;
24706 return 0;
24709 return 0;
24711 _ACEOF
24712 if ac_fn_c_try_run "$LINENO"; then :
24713 gl_cv_func_svid_putenv=yes
24714 else
24715 gl_cv_func_svid_putenv=no
24717 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24718 conftest.$ac_objext conftest.beam conftest.$ac_ext
24723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
24724 $as_echo "$gl_cv_func_svid_putenv" >&6; }
24725 case "$gl_cv_func_svid_putenv" in
24726 *yes) ;;
24728 REPLACE_PUTENV=1
24730 esac
24732 if test $REPLACE_PUTENV = 1; then
24741 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
24744 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
24745 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
24746 ac_have_decl=1
24747 else
24748 ac_have_decl=0
24751 cat >>confdefs.h <<_ACEOF
24752 #define HAVE_DECL__PUTENV $ac_have_decl
24753 _ACEOF
24762 GNULIB_PUTENV=1
24769 # Check whether --enable-acl was given.
24770 if test "${enable_acl+set}" = set; then :
24771 enableval=$enable_acl;
24772 else
24773 enable_acl=auto
24777 LIB_ACL=
24778 use_acl=0
24779 if test "x$enable_acl" != "xno"; then
24780 for ac_header in sys/acl.h
24781 do :
24782 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
24783 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
24784 cat >>confdefs.h <<_ACEOF
24785 #define HAVE_SYS_ACL_H 1
24786 _ACEOF
24790 done
24792 if test $ac_cv_header_sys_acl_h = yes; then
24793 ac_save_LIBS=$LIBS
24795 if test $use_acl = 0; then
24796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
24797 $as_echo_n "checking for library containing acl_get_file... " >&6; }
24798 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24799 $as_echo_n "(cached) " >&6
24800 else
24801 ac_func_search_save_LIBS=$LIBS
24802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24803 /* end confdefs.h. */
24805 /* Override any GCC internal prototype to avoid an error.
24806 Use char because int might match the return type of a GCC
24807 builtin and then its argument prototype would still apply. */
24808 #ifdef __cplusplus
24809 extern "C"
24810 #endif
24811 char acl_get_file ();
24813 main ()
24815 return acl_get_file ();
24817 return 0;
24819 _ACEOF
24820 for ac_lib in '' acl pacl; do
24821 if test -z "$ac_lib"; then
24822 ac_res="none required"
24823 else
24824 ac_res=-l$ac_lib
24825 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
24827 if ac_fn_c_try_link "$LINENO"; then :
24828 ac_cv_search_acl_get_file=$ac_res
24830 rm -f core conftest.err conftest.$ac_objext \
24831 conftest$ac_exeext
24832 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24833 break
24835 done
24836 if test "${ac_cv_search_acl_get_file+set}" = set; then :
24838 else
24839 ac_cv_search_acl_get_file=no
24841 rm conftest.$ac_ext
24842 LIBS=$ac_func_search_save_LIBS
24844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
24845 $as_echo "$ac_cv_search_acl_get_file" >&6; }
24846 ac_res=$ac_cv_search_acl_get_file
24847 if test "$ac_res" != no; then :
24848 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24849 if test "$ac_cv_search_acl_get_file" != "none required"; then
24850 LIB_ACL=$ac_cv_search_acl_get_file
24852 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
24853 acl_free acl_from_mode acl_from_text \
24854 acl_delete_def_file acl_extended_file \
24855 acl_delete_fd_np acl_delete_file_np \
24856 acl_copy_ext_native acl_create_entry_np \
24857 acl_to_short_text acl_free_text
24858 do :
24859 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24860 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24861 eval as_val=\$$as_ac_var
24862 if test "x$as_val" = x""yes; then :
24863 cat >>confdefs.h <<_ACEOF
24864 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24865 _ACEOF
24868 done
24870 # If the acl_get_file bug is detected, don't enable the ACL support.
24872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
24873 $as_echo_n "checking for working acl_get_file... " >&6; }
24874 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
24875 $as_echo_n "(cached) " >&6
24876 else
24877 if test "$cross_compiling" = yes; then :
24878 gl_cv_func_working_acl_get_file=cross-compiling
24879 else
24880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24881 /* end confdefs.h. */
24882 #include <sys/types.h>
24883 #include <sys/acl.h>
24884 #include <errno.h>
24887 main ()
24889 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
24890 return 1;
24891 return 0;
24894 return 0;
24896 _ACEOF
24897 if ac_fn_c_try_run "$LINENO"; then :
24898 gl_cv_func_working_acl_get_file=yes
24899 else
24900 gl_cv_func_working_acl_get_file=no
24902 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24903 conftest.$ac_objext conftest.beam conftest.$ac_ext
24907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
24908 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
24910 if test $gl_cv_func_working_acl_get_file = yes; then :
24911 use_acl=1
24914 if test $use_acl = 1; then
24915 for ac_header in acl/libacl.h
24916 do :
24917 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
24918 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
24919 cat >>confdefs.h <<_ACEOF
24920 #define HAVE_ACL_LIBACL_H 1
24921 _ACEOF
24925 done
24935 for ac_func in acl_entries
24936 do :
24937 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
24938 if test "x$ac_cv_func_acl_entries" = x""yes; then :
24939 cat >>confdefs.h <<_ACEOF
24940 #define HAVE_ACL_ENTRIES 1
24941 _ACEOF
24943 else
24945 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
24948 done
24951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
24952 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
24953 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
24954 $as_echo_n "(cached) " >&6
24955 else
24956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24957 /* end confdefs.h. */
24958 #include <sys/types.h>
24959 #include <sys/acl.h>
24960 int type = ACL_FIRST_ENTRY;
24962 main ()
24966 return 0;
24968 _ACEOF
24969 if ac_fn_c_try_compile "$LINENO"; then :
24970 gl_cv_acl_ACL_FIRST_ENTRY=yes
24971 else
24972 gl_cv_acl_ACL_FIRST_ENTRY=no
24974 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
24977 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
24978 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
24980 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
24983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
24984 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
24985 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
24986 $as_echo_n "(cached) " >&6
24987 else
24988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24989 /* end confdefs.h. */
24990 #include <sys/types.h>
24991 #include <sys/acl.h>
24992 int type = ACL_TYPE_EXTENDED;
24994 main ()
24998 return 0;
25000 _ACEOF
25001 if ac_fn_c_try_compile "$LINENO"; then :
25002 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25003 else
25004 gl_cv_acl_ACL_TYPE_EXTENDED=no
25006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25009 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25010 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25012 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25015 else
25016 LIB_ACL=
25023 if test $use_acl = 0; then
25024 for ac_func in facl
25025 do :
25026 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25027 if test "x$ac_cv_func_facl" = x""yes; then :
25028 cat >>confdefs.h <<_ACEOF
25029 #define HAVE_FACL 1
25030 _ACEOF
25033 done
25035 if test $ac_cv_func_facl = yes; then
25036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25037 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25038 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25039 $as_echo_n "(cached) " >&6
25040 else
25041 ac_func_search_save_LIBS=$LIBS
25042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25043 /* end confdefs.h. */
25045 /* Override any GCC internal prototype to avoid an error.
25046 Use char because int might match the return type of a GCC
25047 builtin and then its argument prototype would still apply. */
25048 #ifdef __cplusplus
25049 extern "C"
25050 #endif
25051 char acl_trivial ();
25053 main ()
25055 return acl_trivial ();
25057 return 0;
25059 _ACEOF
25060 for ac_lib in '' sec; do
25061 if test -z "$ac_lib"; then
25062 ac_res="none required"
25063 else
25064 ac_res=-l$ac_lib
25065 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25067 if ac_fn_c_try_link "$LINENO"; then :
25068 ac_cv_search_acl_trivial=$ac_res
25070 rm -f core conftest.err conftest.$ac_objext \
25071 conftest$ac_exeext
25072 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25073 break
25075 done
25076 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25078 else
25079 ac_cv_search_acl_trivial=no
25081 rm conftest.$ac_ext
25082 LIBS=$ac_func_search_save_LIBS
25084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25085 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25086 ac_res=$ac_cv_search_acl_trivial
25087 if test "$ac_res" != no; then :
25088 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25089 if test "$ac_cv_search_acl_trivial" != "none required"; then
25090 LIB_ACL=$ac_cv_search_acl_trivial
25095 for ac_func in acl_trivial
25096 do :
25097 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25098 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25099 cat >>confdefs.h <<_ACEOF
25100 #define HAVE_ACL_TRIVIAL 1
25101 _ACEOF
25104 done
25106 use_acl=1
25110 if test $use_acl = 0; then
25111 for ac_func in getacl
25112 do :
25113 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25114 if test "x$ac_cv_func_getacl" = x""yes; then :
25115 cat >>confdefs.h <<_ACEOF
25116 #define HAVE_GETACL 1
25117 _ACEOF
25120 done
25122 if test $ac_cv_func_getacl = yes; then
25123 use_acl=1
25125 for ac_header in aclv.h
25126 do :
25127 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25129 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25130 cat >>confdefs.h <<_ACEOF
25131 #define HAVE_ACLV_H 1
25132 _ACEOF
25136 done
25140 if test $use_acl = 0; then
25141 for ac_func in aclx_get
25142 do :
25143 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25144 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25145 cat >>confdefs.h <<_ACEOF
25146 #define HAVE_ACLX_GET 1
25147 _ACEOF
25150 done
25152 if test $ac_cv_func_aclx_get = yes; then
25153 use_acl=1
25157 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25158 for ac_func in statacl
25159 do :
25160 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25161 if test "x$ac_cv_func_statacl" = x""yes; then :
25162 cat >>confdefs.h <<_ACEOF
25163 #define HAVE_STATACL 1
25164 _ACEOF
25167 done
25169 if test $ac_cv_func_statacl = yes; then
25170 use_acl=1
25174 if test $use_acl = 0; then
25175 for ac_func in aclsort
25176 do :
25177 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25178 if test "x$ac_cv_func_aclsort" = x""yes; then :
25179 cat >>confdefs.h <<_ACEOF
25180 #define HAVE_ACLSORT 1
25181 _ACEOF
25184 done
25186 if test $ac_cv_func_aclsort = yes; then
25187 use_acl=1
25191 LIBS=$ac_save_LIBS
25193 if test "x$enable_acl$use_acl" = "xyes0"; then
25194 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25195 elif test "x$enable_acl$use_acl" = "xauto0"; then
25196 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25197 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25199 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25204 cat >>confdefs.h <<_ACEOF
25205 #define USE_ACL $use_acl
25206 _ACEOF
25208 USE_ACL=$use_acl
25214 if test $ac_cv_func_readlink = no; then
25215 HAVE_READLINK=0
25216 else
25217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25218 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25219 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25220 $as_echo_n "(cached) " >&6
25221 else
25222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25223 /* end confdefs.h. */
25224 #include <unistd.h>
25225 /* Cause compilation failure if original declaration has wrong type. */
25226 ssize_t readlink (const char *, char *, size_t);
25228 main ()
25232 return 0;
25234 _ACEOF
25235 if ac_fn_c_try_compile "$LINENO"; then :
25236 gl_cv_decl_readlink_works=yes
25237 else
25238 gl_cv_decl_readlink_works=no
25240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25243 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25245 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25246 if test "${gl_cv_func_readlink_works+set}" = set; then :
25247 $as_echo_n "(cached) " >&6
25248 else
25249 # We have readlink, so assume ln -s works.
25250 ln -s conftest.no-such conftest.link
25251 ln -s conftest.link conftest.lnk2
25252 if test "$cross_compiling" = yes; then :
25253 case "$host_os" in
25254 # Guess yes on glibc systems.
25255 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25256 # If we don't know, assume the worst.
25257 *) gl_cv_func_readlink_works="guessing no" ;;
25258 esac
25260 else
25261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25262 /* end confdefs.h. */
25263 #include <unistd.h>
25266 main ()
25268 char buf[20];
25269 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25271 return 0;
25273 _ACEOF
25274 if ac_fn_c_try_run "$LINENO"; then :
25275 gl_cv_func_readlink_works=yes
25276 else
25277 gl_cv_func_readlink_works=no
25279 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25280 conftest.$ac_objext conftest.beam conftest.$ac_ext
25283 rm -f conftest.link conftest.lnk2
25285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25286 $as_echo "$gl_cv_func_readlink_works" >&6; }
25287 case "$gl_cv_func_readlink_works" in
25288 *yes)
25289 if test "$gl_cv_decl_readlink_works" != yes; then
25290 REPLACE_READLINK=1
25295 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25297 REPLACE_READLINK=1
25299 esac
25302 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25311 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
25322 GNULIB_READLINK=1
25332 if test $ac_cv_func_readlinkat = no; then
25333 HAVE_READLINKAT=0
25336 if test $HAVE_READLINKAT = 0; then
25345 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
25353 GNULIB_READLINKAT=1
25360 for ac_func in sig2str
25361 do :
25362 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
25363 if test "x$ac_cv_func_sig2str" = x""yes; then :
25364 cat >>confdefs.h <<_ACEOF
25365 #define HAVE_SIG2STR 1
25366 _ACEOF
25369 done
25372 if test $ac_cv_func_sig2str = no; then
25381 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
25398 if test $gl_cv_have_include_next = yes; then
25399 gl_cv_next_signal_h='<'signal.h'>'
25400 else
25401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
25402 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
25403 if test "${gl_cv_next_signal_h+set}" = set; then :
25404 $as_echo_n "(cached) " >&6
25405 else
25407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25408 /* end confdefs.h. */
25409 #include <signal.h>
25411 _ACEOF
25412 case "$host_os" in
25413 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25414 *) gl_absname_cpp="$ac_cpp" ;;
25415 esac
25417 case "$host_os" in
25418 mingw*)
25419 gl_dirsep_regex='[/\\]'
25422 gl_dirsep_regex='\/'
25424 esac
25425 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25427 gl_header_literal_regex=`echo 'signal.h' \
25428 | sed -e "$gl_make_literal_regex_sed"`
25429 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25430 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25431 s|^/[^/]|//&|
25435 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25436 sed -n "$gl_absolute_header_sed"`'"'
25440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
25441 $as_echo "$gl_cv_next_signal_h" >&6; }
25443 NEXT_SIGNAL_H=$gl_cv_next_signal_h
25445 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25446 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25447 gl_next_as_first_directive='<'signal.h'>'
25448 else
25449 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25450 gl_next_as_first_directive=$gl_cv_next_signal_h
25452 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
25458 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
25459 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
25460 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
25461 #include <signal.h>
25464 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
25466 else
25467 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
25476 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
25477 #include <signal.h>
25480 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
25482 else
25483 HAVE_SIGHANDLER_T=0
25489 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
25490 /* <sys/types.h> is not needed according to POSIX, but the
25491 <sys/socket.h> in i386-unknown-freebsd4.10 and
25492 powerpc-apple-darwin5.5 required it. */
25493 #include <sys/types.h>
25494 #if HAVE_SYS_SOCKET_H
25495 # include <sys/socket.h>
25496 #elif HAVE_WS2TCPIP_H
25497 # include <ws2tcpip.h>
25498 #endif
25501 if test "x$ac_cv_type_socklen_t" = x""yes; then :
25503 else
25504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
25505 $as_echo_n "checking for socklen_t equivalent... " >&6; }
25506 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
25507 $as_echo_n "(cached) " >&6
25508 else
25509 # Systems have either "struct sockaddr *" or
25510 # "void *" as the second argument to getpeername
25511 gl_cv_socklen_t_equiv=
25512 for arg2 in "struct sockaddr" void; do
25513 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
25514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25515 /* end confdefs.h. */
25516 #include <sys/types.h>
25517 #include <sys/socket.h>
25519 int getpeername (int, $arg2 *, $t *);
25521 main ()
25523 $t len;
25524 getpeername (0, 0, &len);
25526 return 0;
25528 _ACEOF
25529 if ac_fn_c_try_compile "$LINENO"; then :
25530 gl_cv_socklen_t_equiv="$t"
25532 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25533 test "$gl_cv_socklen_t_equiv" != "" && break
25534 done
25535 test "$gl_cv_socklen_t_equiv" != "" && break
25536 done
25540 if test "$gl_cv_socklen_t_equiv" = ""; then
25541 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
25543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
25544 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
25546 cat >>confdefs.h <<_ACEOF
25547 #define socklen_t $gl_cv_socklen_t_equiv
25548 _ACEOF
25553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
25554 $as_echo_n "checking for ssize_t... " >&6; }
25555 if test "${gt_cv_ssize_t+set}" = set; then :
25556 $as_echo_n "(cached) " >&6
25557 else
25558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25559 /* end confdefs.h. */
25560 #include <sys/types.h>
25562 main ()
25564 int x = sizeof (ssize_t *) + sizeof (ssize_t);
25565 return !x;
25567 return 0;
25569 _ACEOF
25570 if ac_fn_c_try_compile "$LINENO"; then :
25571 gt_cv_ssize_t=yes
25572 else
25573 gt_cv_ssize_t=no
25575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
25578 $as_echo "$gt_cv_ssize_t" >&6; }
25579 if test $gt_cv_ssize_t = no; then
25581 $as_echo "#define ssize_t int" >>confdefs.h
25589 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>
25590 #include <sys/stat.h>
25592 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
25594 cat >>confdefs.h <<_ACEOF
25595 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
25596 _ACEOF
25598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
25599 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
25600 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
25601 $as_echo_n "(cached) " >&6
25602 else
25603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25604 /* end confdefs.h. */
25606 #include <sys/types.h>
25607 #include <sys/stat.h>
25608 #if HAVE_SYS_TIME_H
25609 # include <sys/time.h>
25610 #endif
25611 #include <time.h>
25612 struct timespec ts;
25613 struct stat st;
25616 main ()
25619 st.st_atim = ts;
25622 return 0;
25624 _ACEOF
25625 if ac_fn_c_try_compile "$LINENO"; then :
25626 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
25627 else
25628 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
25630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
25633 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
25634 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
25636 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
25639 else
25640 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>
25641 #include <sys/stat.h>
25643 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
25645 cat >>confdefs.h <<_ACEOF
25646 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
25647 _ACEOF
25650 else
25651 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
25652 #include <sys/stat.h>
25654 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
25656 cat >>confdefs.h <<_ACEOF
25657 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
25658 _ACEOF
25661 else
25662 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>
25663 #include <sys/stat.h>
25665 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
25667 cat >>confdefs.h <<_ACEOF
25668 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
25669 _ACEOF
25684 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>
25685 #include <sys/stat.h>
25687 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
25689 cat >>confdefs.h <<_ACEOF
25690 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
25691 _ACEOF
25694 else
25695 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
25696 #include <sys/stat.h>
25698 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
25700 cat >>confdefs.h <<_ACEOF
25701 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
25702 _ACEOF
25705 else
25706 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>
25707 #include <sys/stat.h>
25709 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
25711 cat >>confdefs.h <<_ACEOF
25712 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
25713 _ACEOF
25724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
25725 $as_echo_n "checking for working stdalign.h... " >&6; }
25726 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
25727 $as_echo_n "(cached) " >&6
25728 else
25729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25730 /* end confdefs.h. */
25731 #include <stdalign.h>
25732 #include <stddef.h>
25734 /* Test that alignof yields a result consistent with offsetof.
25735 This catches GCC bug 52023
25736 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
25737 #ifdef __cplusplus
25738 template <class t> struct alignof_helper { char a; t b; };
25739 # define ao(type) offsetof (alignof_helper<type>, b)
25740 #else
25741 # define ao(type) offsetof (struct { char a; type b; }, b)
25742 #endif
25743 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
25744 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
25745 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
25747 /* Test _Alignas only on platforms where gnulib can help. */
25748 #if \
25749 (__GNUC__ || __IBMC__ || __IBMCPP__ \
25750 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
25751 struct alignas_test { char c; char alignas (8) alignas_8; };
25752 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
25753 ? 1 : -1];
25754 #endif
25757 main ()
25761 return 0;
25763 _ACEOF
25764 if ac_fn_c_try_compile "$LINENO"; then :
25765 gl_cv_header_working_stdalign_h=yes
25766 else
25767 gl_cv_header_working_stdalign_h=no
25769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
25772 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
25774 if test $gl_cv_header_working_stdalign_h = yes; then
25775 STDALIGN_H=''
25776 else
25777 STDALIGN_H='stdalign.h'
25781 if test -n "$STDALIGN_H"; then
25782 GL_GENERATE_STDALIGN_H_TRUE=
25783 GL_GENERATE_STDALIGN_H_FALSE='#'
25784 else
25785 GL_GENERATE_STDALIGN_H_TRUE='#'
25786 GL_GENERATE_STDALIGN_H_FALSE=
25791 STDARG_H=''
25792 NEXT_STDARG_H='<stdarg.h>'
25793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
25794 $as_echo_n "checking for va_copy... " >&6; }
25795 if test "${gl_cv_func_va_copy+set}" = set; then :
25796 $as_echo_n "(cached) " >&6
25797 else
25799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25800 /* end confdefs.h. */
25801 #include <stdarg.h>
25803 main ()
25806 #ifndef va_copy
25807 void (*func) (va_list, va_list) = va_copy;
25808 #endif
25811 return 0;
25813 _ACEOF
25814 if ac_fn_c_try_compile "$LINENO"; then :
25815 gl_cv_func_va_copy=yes
25816 else
25817 gl_cv_func_va_copy=no
25819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
25823 $as_echo "$gl_cv_func_va_copy" >&6; }
25824 if test $gl_cv_func_va_copy = no; then
25825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25826 /* end confdefs.h. */
25827 #if defined _AIX && !defined __GNUC__
25828 AIX vaccine
25829 #endif
25831 _ACEOF
25832 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25833 $EGREP "vaccine" >/dev/null 2>&1; then :
25834 gl_aixcc=yes
25835 else
25836 gl_aixcc=no
25838 rm -f conftest*
25840 if test $gl_aixcc = yes; then
25841 STDARG_H=stdarg.h
25850 if test $gl_cv_have_include_next = yes; then
25851 gl_cv_next_stdarg_h='<'stdarg.h'>'
25852 else
25853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
25854 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
25855 if test "${gl_cv_next_stdarg_h+set}" = set; then :
25856 $as_echo_n "(cached) " >&6
25857 else
25859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25860 /* end confdefs.h. */
25861 #include <stdarg.h>
25863 _ACEOF
25864 case "$host_os" in
25865 aix*) gl_absname_cpp="$ac_cpp -C" ;;
25866 *) gl_absname_cpp="$ac_cpp" ;;
25867 esac
25869 case "$host_os" in
25870 mingw*)
25871 gl_dirsep_regex='[/\\]'
25874 gl_dirsep_regex='\/'
25876 esac
25877 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
25879 gl_header_literal_regex=`echo 'stdarg.h' \
25880 | sed -e "$gl_make_literal_regex_sed"`
25881 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
25882 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
25883 s|^/[^/]|//&|
25887 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
25888 sed -n "$gl_absolute_header_sed"`'"'
25892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
25893 $as_echo "$gl_cv_next_stdarg_h" >&6; }
25895 NEXT_STDARG_H=$gl_cv_next_stdarg_h
25897 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
25898 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
25899 gl_next_as_first_directive='<'stdarg.h'>'
25900 else
25901 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
25902 gl_next_as_first_directive=$gl_cv_next_stdarg_h
25904 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
25909 if test "$gl_cv_next_stdarg_h" = '""'; then
25910 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
25911 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
25913 else
25915 saved_as_echo_n="$as_echo_n"
25916 as_echo_n=':'
25917 if test "${gl_cv_func___va_copy+set}" = set; then :
25918 $as_echo_n "(cached) " >&6
25919 else
25921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25922 /* end confdefs.h. */
25923 #include <stdarg.h>
25925 main ()
25928 #ifndef __va_copy
25929 error, bail out
25930 #endif
25933 return 0;
25935 _ACEOF
25936 if ac_fn_c_try_compile "$LINENO"; then :
25937 gl_cv_func___va_copy=yes
25938 else
25939 gl_cv_func___va_copy=no
25941 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25944 as_echo_n="$saved_as_echo_n"
25946 if test $gl_cv_func___va_copy = yes; then
25948 $as_echo "#define va_copy __va_copy" >>confdefs.h
25950 else
25953 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
25959 if test -n "$STDARG_H"; then
25960 GL_GENERATE_STDARG_H_TRUE=
25961 GL_GENERATE_STDARG_H_FALSE='#'
25962 else
25963 GL_GENERATE_STDARG_H_TRUE='#'
25964 GL_GENERATE_STDARG_H_FALSE=
25972 # Define two additional variables used in the Makefile substitution.
25974 if test "$ac_cv_header_stdbool_h" = yes; then
25975 STDBOOL_H=''
25976 else
25977 STDBOOL_H='stdbool.h'
25980 if test -n "$STDBOOL_H"; then
25981 GL_GENERATE_STDBOOL_H_TRUE=
25982 GL_GENERATE_STDBOOL_H_FALSE='#'
25983 else
25984 GL_GENERATE_STDBOOL_H_TRUE='#'
25985 GL_GENERATE_STDBOOL_H_FALSE=
25989 if test "$ac_cv_type__Bool" = yes; then
25990 HAVE__BOOL=1
25991 else
25992 HAVE__BOOL=0
25999 STDDEF_H=
26000 if test $gt_cv_c_wchar_t = no; then
26001 HAVE_WCHAR_T=0
26002 STDDEF_H=stddef.h
26004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26005 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26006 if test "${gl_cv_decl_null_works+set}" = set; then :
26007 $as_echo_n "(cached) " >&6
26008 else
26009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26010 /* end confdefs.h. */
26011 #include <stddef.h>
26012 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26015 main ()
26019 return 0;
26021 _ACEOF
26022 if ac_fn_c_try_compile "$LINENO"; then :
26023 gl_cv_decl_null_works=yes
26024 else
26025 gl_cv_decl_null_works=no
26027 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26030 $as_echo "$gl_cv_decl_null_works" >&6; }
26031 if test $gl_cv_decl_null_works = no; then
26032 REPLACE_NULL=1
26033 STDDEF_H=stddef.h
26036 if test -n "$STDDEF_H"; then
26037 GL_GENERATE_STDDEF_H_TRUE=
26038 GL_GENERATE_STDDEF_H_FALSE='#'
26039 else
26040 GL_GENERATE_STDDEF_H_TRUE='#'
26041 GL_GENERATE_STDDEF_H_FALSE=
26044 if test -n "$STDDEF_H"; then
26053 if test $gl_cv_have_include_next = yes; then
26054 gl_cv_next_stddef_h='<'stddef.h'>'
26055 else
26056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26057 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26058 if test "${gl_cv_next_stddef_h+set}" = set; then :
26059 $as_echo_n "(cached) " >&6
26060 else
26062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26063 /* end confdefs.h. */
26064 #include <stddef.h>
26066 _ACEOF
26067 case "$host_os" in
26068 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26069 *) gl_absname_cpp="$ac_cpp" ;;
26070 esac
26072 case "$host_os" in
26073 mingw*)
26074 gl_dirsep_regex='[/\\]'
26077 gl_dirsep_regex='\/'
26079 esac
26080 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26082 gl_header_literal_regex=`echo 'stddef.h' \
26083 | sed -e "$gl_make_literal_regex_sed"`
26084 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26085 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26086 s|^/[^/]|//&|
26090 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26091 sed -n "$gl_absolute_header_sed"`'"'
26095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26096 $as_echo "$gl_cv_next_stddef_h" >&6; }
26098 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26100 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26101 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26102 gl_next_as_first_directive='<'stddef.h'>'
26103 else
26104 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26105 gl_next_as_first_directive=$gl_cv_next_stddef_h
26107 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26125 if test $gl_cv_have_include_next = yes; then
26126 gl_cv_next_stdio_h='<'stdio.h'>'
26127 else
26128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26129 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26130 if test "${gl_cv_next_stdio_h+set}" = set; then :
26131 $as_echo_n "(cached) " >&6
26132 else
26134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26135 /* end confdefs.h. */
26136 #include <stdio.h>
26138 _ACEOF
26139 case "$host_os" in
26140 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26141 *) gl_absname_cpp="$ac_cpp" ;;
26142 esac
26144 case "$host_os" in
26145 mingw*)
26146 gl_dirsep_regex='[/\\]'
26149 gl_dirsep_regex='\/'
26151 esac
26152 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26154 gl_header_literal_regex=`echo 'stdio.h' \
26155 | sed -e "$gl_make_literal_regex_sed"`
26156 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26157 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26158 s|^/[^/]|//&|
26162 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26163 sed -n "$gl_absolute_header_sed"`'"'
26167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26168 $as_echo "$gl_cv_next_stdio_h" >&6; }
26170 NEXT_STDIO_H=$gl_cv_next_stdio_h
26172 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26173 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26174 gl_next_as_first_directive='<'stdio.h'>'
26175 else
26176 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26177 gl_next_as_first_directive=$gl_cv_next_stdio_h
26179 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26185 GNULIB_FSCANF=1
26188 cat >>confdefs.h <<_ACEOF
26189 #define GNULIB_FSCANF 1
26190 _ACEOF
26193 GNULIB_SCANF=1
26196 cat >>confdefs.h <<_ACEOF
26197 #define GNULIB_SCANF 1
26198 _ACEOF
26201 GNULIB_FGETC=1
26202 GNULIB_GETC=1
26203 GNULIB_GETCHAR=1
26204 GNULIB_FGETS=1
26205 GNULIB_FREAD=1
26208 GNULIB_FPRINTF=1
26209 GNULIB_PRINTF=1
26210 GNULIB_VFPRINTF=1
26211 GNULIB_VPRINTF=1
26212 GNULIB_FPUTC=1
26213 GNULIB_PUTC=1
26214 GNULIB_PUTCHAR=1
26215 GNULIB_FPUTS=1
26216 GNULIB_PUTS=1
26217 GNULIB_FWRITE=1
26233 if test $gl_cv_have_include_next = yes; then
26234 gl_cv_next_stdlib_h='<'stdlib.h'>'
26235 else
26236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26237 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26238 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26239 $as_echo_n "(cached) " >&6
26240 else
26242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26243 /* end confdefs.h. */
26244 #include <stdlib.h>
26246 _ACEOF
26247 case "$host_os" in
26248 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26249 *) gl_absname_cpp="$ac_cpp" ;;
26250 esac
26252 case "$host_os" in
26253 mingw*)
26254 gl_dirsep_regex='[/\\]'
26257 gl_dirsep_regex='\/'
26259 esac
26260 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26262 gl_header_literal_regex=`echo 'stdlib.h' \
26263 | sed -e "$gl_make_literal_regex_sed"`
26264 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26265 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26266 s|^/[^/]|//&|
26270 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26271 sed -n "$gl_absolute_header_sed"`'"'
26275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26276 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26278 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26280 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26281 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26282 gl_next_as_first_directive='<'stdlib.h'>'
26283 else
26284 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26285 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26287 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26297 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26305 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26317 if test "$ac_cv_have_decl_strtoimax" != yes; then
26318 HAVE_DECL_STRTOIMAX=0
26321 if test $ac_cv_func_strtoimax = yes; then
26322 HAVE_STRTOIMAX=1
26323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
26324 $as_echo_n "checking whether strtoimax works... " >&6; }
26325 if test "${gl_cv_func_strtoimax+set}" = set; then :
26326 $as_echo_n "(cached) " >&6
26327 else
26328 if test "$cross_compiling" = yes; then :
26329 case "$host_os" in
26330 # Guess no on AIX 5.
26331 aix5*) gl_cv_func_strtoimax="guessing no" ;;
26332 # Guess yes otherwise.
26333 *) gl_cv_func_strtoimax="guessing yes" ;;
26334 esac
26336 else
26337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26338 /* end confdefs.h. */
26340 #include <errno.h>
26341 #include <string.h>
26342 #include <inttypes.h>
26343 int main ()
26345 if (sizeof (intmax_t) > sizeof (int))
26347 const char *s = "4294967295";
26348 char *p;
26349 intmax_t res;
26350 errno = 0;
26351 res = strtoimax (s, &p, 10);
26352 if (p != s + strlen (s))
26353 return 1;
26354 if (errno != 0)
26355 return 2;
26356 if (res != (intmax_t) 65535 * (intmax_t) 65537)
26357 return 3;
26359 else
26361 const char *s = "2147483647";
26362 char *p;
26363 intmax_t res;
26364 errno = 0;
26365 res = strtoimax (s, &p, 10);
26366 if (p != s + strlen (s))
26367 return 1;
26368 if (errno != 0)
26369 return 2;
26370 if (res != 2147483647)
26371 return 3;
26373 return 0;
26376 _ACEOF
26377 if ac_fn_c_try_run "$LINENO"; then :
26378 gl_cv_func_strtoimax=yes
26379 else
26380 gl_cv_func_strtoimax=no
26382 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26383 conftest.$ac_objext conftest.beam conftest.$ac_ext
26388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
26389 $as_echo "$gl_cv_func_strtoimax" >&6; }
26390 case "$gl_cv_func_strtoimax" in
26391 *no) REPLACE_STRTOIMAX=1 ;;
26392 esac
26393 else
26394 HAVE_STRTOIMAX=0
26397 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
26406 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
26409 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
26410 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
26411 ac_have_decl=1
26412 else
26413 ac_have_decl=0
26416 cat >>confdefs.h <<_ACEOF
26417 #define HAVE_DECL_STRTOLL $ac_have_decl
26418 _ACEOF
26428 GNULIB_STRTOIMAX=1
26438 if test "$ac_cv_have_decl_strtoumax" != yes; then
26439 HAVE_DECL_STRTOUMAX=0
26442 if test $ac_cv_func_strtoumax = no; then
26451 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
26454 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
26455 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
26456 ac_have_decl=1
26457 else
26458 ac_have_decl=0
26461 cat >>confdefs.h <<_ACEOF
26462 #define HAVE_DECL_STRTOULL $ac_have_decl
26463 _ACEOF
26473 GNULIB_STRTOUMAX=1
26481 if test $ac_cv_func_symlink = no; then
26482 HAVE_SYMLINK=0
26483 else
26484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
26485 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
26486 if test "${gl_cv_func_symlink_works+set}" = set; then :
26487 $as_echo_n "(cached) " >&6
26488 else
26489 if test "$cross_compiling" = yes; then :
26490 case "$host_os" in
26491 # Guess yes on glibc systems.
26492 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
26493 # If we don't know, assume the worst.
26494 *) gl_cv_func_symlink_works="guessing no" ;;
26495 esac
26497 else
26498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26499 /* end confdefs.h. */
26500 #include <unistd.h>
26503 main ()
26505 int result = 0;
26506 if (!symlink ("a", "conftest.link/"))
26507 result |= 1;
26508 if (symlink ("conftest.f", "conftest.lnk2"))
26509 result |= 2;
26510 else if (!symlink ("a", "conftest.lnk2/"))
26511 result |= 4;
26512 return result;
26515 return 0;
26517 _ACEOF
26518 if ac_fn_c_try_run "$LINENO"; then :
26519 gl_cv_func_symlink_works=yes
26520 else
26521 gl_cv_func_symlink_works=no
26523 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26524 conftest.$ac_objext conftest.beam conftest.$ac_ext
26527 rm -f conftest.f conftest.link conftest.lnk2
26529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
26530 $as_echo "$gl_cv_func_symlink_works" >&6; }
26531 case "$gl_cv_func_symlink_works" in
26532 *yes) ;;
26534 REPLACE_SYMLINK=1
26536 esac
26539 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
26548 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
26556 GNULIB_SYMLINK=1
26565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
26566 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
26567 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
26568 $as_echo_n "(cached) " >&6
26569 else
26571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26572 /* end confdefs.h. */
26573 #include <sys/select.h>
26575 main ()
26577 struct timeval b;
26579 return 0;
26581 _ACEOF
26582 if ac_fn_c_try_compile "$LINENO"; then :
26583 gl_cv_header_sys_select_h_selfcontained=yes
26584 else
26585 gl_cv_header_sys_select_h_selfcontained=no
26587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26588 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
26589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26590 /* end confdefs.h. */
26591 #include <sys/select.h>
26593 main ()
26595 int memset; int bzero;
26597 return 0;
26600 _ACEOF
26601 if ac_fn_c_try_compile "$LINENO"; then :
26602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26603 /* end confdefs.h. */
26604 #include <sys/select.h>
26606 main ()
26609 #undef memset
26610 #define memset nonexistent_memset
26611 extern
26612 #ifdef __cplusplus
26614 #endif
26615 void *memset (void *, int, unsigned long);
26616 #undef bzero
26617 #define bzero nonexistent_bzero
26618 extern
26619 #ifdef __cplusplus
26621 #endif
26622 void bzero (void *, unsigned long);
26623 fd_set fds;
26624 FD_ZERO (&fds);
26627 return 0;
26630 _ACEOF
26631 if ac_fn_c_try_link "$LINENO"; then :
26633 else
26634 gl_cv_header_sys_select_h_selfcontained=no
26636 rm -f core conftest.err conftest.$ac_objext \
26637 conftest$ac_exeext conftest.$ac_ext
26640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
26645 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
26655 if test $gl_cv_have_include_next = yes; then
26656 gl_cv_next_sys_select_h='<'sys/select.h'>'
26657 else
26658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
26659 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
26660 if test "${gl_cv_next_sys_select_h+set}" = set; then :
26661 $as_echo_n "(cached) " >&6
26662 else
26664 if test $ac_cv_header_sys_select_h = yes; then
26667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26668 /* end confdefs.h. */
26669 #include <sys/select.h>
26671 _ACEOF
26672 case "$host_os" in
26673 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26674 *) gl_absname_cpp="$ac_cpp" ;;
26675 esac
26677 case "$host_os" in
26678 mingw*)
26679 gl_dirsep_regex='[/\\]'
26682 gl_dirsep_regex='\/'
26684 esac
26685 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26687 gl_header_literal_regex=`echo 'sys/select.h' \
26688 | sed -e "$gl_make_literal_regex_sed"`
26689 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26690 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26691 s|^/[^/]|//&|
26695 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26696 sed -n "$gl_absolute_header_sed"`'"'
26697 else
26698 gl_cv_next_sys_select_h='<'sys/select.h'>'
26703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
26704 $as_echo "$gl_cv_next_sys_select_h" >&6; }
26706 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
26708 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26709 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26710 gl_next_as_first_directive='<'sys/select.h'>'
26711 else
26712 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26713 gl_next_as_first_directive=$gl_cv_next_sys_select_h
26715 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
26720 if test $ac_cv_header_sys_select_h = yes; then
26721 HAVE_SYS_SELECT_H=1
26722 else
26723 HAVE_SYS_SELECT_H=0
26730 if test $ac_cv_header_sys_socket_h != yes; then
26731 for ac_header in winsock2.h
26732 do :
26733 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
26734 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
26735 cat >>confdefs.h <<_ACEOF
26736 #define HAVE_WINSOCK2_H 1
26737 _ACEOF
26741 done
26744 if test "$ac_cv_header_winsock2_h" = yes; then
26745 HAVE_WINSOCK2_H=1
26746 UNISTD_H_HAVE_WINSOCK2_H=1
26747 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
26748 else
26749 HAVE_WINSOCK2_H=0
26771 if test $gl_cv_have_include_next = yes; then
26772 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
26773 else
26774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
26775 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
26776 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
26777 $as_echo_n "(cached) " >&6
26778 else
26780 if test $ac_cv_header_sys_stat_h = yes; then
26783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26784 /* end confdefs.h. */
26785 #include <sys/stat.h>
26787 _ACEOF
26788 case "$host_os" in
26789 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26790 *) gl_absname_cpp="$ac_cpp" ;;
26791 esac
26793 case "$host_os" in
26794 mingw*)
26795 gl_dirsep_regex='[/\\]'
26798 gl_dirsep_regex='\/'
26800 esac
26801 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26803 gl_header_literal_regex=`echo 'sys/stat.h' \
26804 | sed -e "$gl_make_literal_regex_sed"`
26805 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26806 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26807 s|^/[^/]|//&|
26811 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26812 sed -n "$gl_absolute_header_sed"`'"'
26813 else
26814 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
26819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
26820 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
26822 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
26824 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26825 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26826 gl_next_as_first_directive='<'sys/stat.h'>'
26827 else
26828 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26829 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
26831 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
26843 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
26845 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
26849 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
26850 #include <sys/stat.h>
26852 if test "x$ac_cv_type_nlink_t" = x""yes; then :
26854 else
26856 $as_echo "#define nlink_t int" >>confdefs.h
26877 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
26879 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
26880 ac_have_decl=1
26881 else
26882 ac_have_decl=0
26885 cat >>confdefs.h <<_ACEOF
26886 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
26887 _ACEOF
26889 if test $ac_cv_have_decl_localtime_r = no; then
26890 HAVE_DECL_LOCALTIME_R=0
26894 if test $ac_cv_func_localtime_r = yes; then
26895 HAVE_LOCALTIME_R=1
26896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
26897 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
26898 if test "${gl_cv_time_r_posix+set}" = set; then :
26899 $as_echo_n "(cached) " >&6
26900 else
26901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26902 /* end confdefs.h. */
26903 #include <time.h>
26905 main ()
26907 /* We don't need to append 'restrict's to the argument types,
26908 even though the POSIX signature has the 'restrict's,
26909 since C99 says they can't affect type compatibility. */
26910 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
26911 if (ptr) return 0;
26912 /* Check the return type is a pointer.
26913 On HP-UX 10 it is 'int'. */
26914 *localtime_r (0, 0);
26916 return 0;
26919 _ACEOF
26920 if ac_fn_c_try_compile "$LINENO"; then :
26921 gl_cv_time_r_posix=yes
26922 else
26923 gl_cv_time_r_posix=no
26925 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
26929 $as_echo "$gl_cv_time_r_posix" >&6; }
26930 if test $gl_cv_time_r_posix = yes; then
26931 REPLACE_LOCALTIME_R=0
26932 else
26933 REPLACE_LOCALTIME_R=1
26935 else
26936 HAVE_LOCALTIME_R=0
26939 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
26948 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
26959 GNULIB_TIME_R=1
26970 LIB_TIMER_TIME=
26972 gl_saved_libs=$LIBS
26973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
26974 $as_echo_n "checking for library containing timer_settime... " >&6; }
26975 if test "${ac_cv_search_timer_settime+set}" = set; then :
26976 $as_echo_n "(cached) " >&6
26977 else
26978 ac_func_search_save_LIBS=$LIBS
26979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26980 /* end confdefs.h. */
26982 /* Override any GCC internal prototype to avoid an error.
26983 Use char because int might match the return type of a GCC
26984 builtin and then its argument prototype would still apply. */
26985 #ifdef __cplusplus
26986 extern "C"
26987 #endif
26988 char timer_settime ();
26990 main ()
26992 return timer_settime ();
26994 return 0;
26996 _ACEOF
26997 for ac_lib in '' rt posix4; do
26998 if test -z "$ac_lib"; then
26999 ac_res="none required"
27000 else
27001 ac_res=-l$ac_lib
27002 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27004 if ac_fn_c_try_link "$LINENO"; then :
27005 ac_cv_search_timer_settime=$ac_res
27007 rm -f core conftest.err conftest.$ac_objext \
27008 conftest$ac_exeext
27009 if test "${ac_cv_search_timer_settime+set}" = set; then :
27010 break
27012 done
27013 if test "${ac_cv_search_timer_settime+set}" = set; then :
27015 else
27016 ac_cv_search_timer_settime=no
27018 rm conftest.$ac_ext
27019 LIBS=$ac_func_search_save_LIBS
27021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27022 $as_echo "$ac_cv_search_timer_settime" >&6; }
27023 ac_res=$ac_cv_search_timer_settime
27024 if test "$ac_res" != no; then :
27025 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27026 test "$ac_cv_search_timer_settime" = "none required" ||
27027 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27030 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27031 /* end confdefs.h. */
27033 #include <features.h>
27034 #ifdef __GNU_LIBRARY__
27035 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27036 && !defined __UCLIBC__
27037 Thread emulation available
27038 #endif
27039 #endif
27041 _ACEOF
27042 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27043 $EGREP "Thread" >/dev/null 2>&1; then :
27044 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27046 rm -f conftest*
27048 for ac_func in timer_settime
27049 do :
27050 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27051 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27052 cat >>confdefs.h <<_ACEOF
27053 #define HAVE_TIMER_SETTIME 1
27054 _ACEOF
27057 done
27059 LIBS=$gl_saved_libs
27074 if test $gl_cv_have_include_next = yes; then
27075 gl_cv_next_unistd_h='<'unistd.h'>'
27076 else
27077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27078 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27079 if test "${gl_cv_next_unistd_h+set}" = set; then :
27080 $as_echo_n "(cached) " >&6
27081 else
27083 if test $ac_cv_header_unistd_h = yes; then
27086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27087 /* end confdefs.h. */
27088 #include <unistd.h>
27090 _ACEOF
27091 case "$host_os" in
27092 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27093 *) gl_absname_cpp="$ac_cpp" ;;
27094 esac
27096 case "$host_os" in
27097 mingw*)
27098 gl_dirsep_regex='[/\\]'
27101 gl_dirsep_regex='\/'
27103 esac
27104 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27106 gl_header_literal_regex=`echo 'unistd.h' \
27107 | sed -e "$gl_make_literal_regex_sed"`
27108 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27109 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27110 s|^/[^/]|//&|
27114 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27115 sed -n "$gl_absolute_header_sed"`'"'
27116 else
27117 gl_cv_next_unistd_h='<'unistd.h'>'
27122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27123 $as_echo "$gl_cv_next_unistd_h" >&6; }
27125 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27127 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27128 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27129 gl_next_as_first_directive='<'unistd.h'>'
27130 else
27131 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27132 gl_next_as_first_directive=$gl_cv_next_unistd_h
27134 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27139 if test $ac_cv_header_unistd_h = yes; then
27140 HAVE_UNISTD_H=1
27141 else
27142 HAVE_UNISTD_H=0
27155 if test $ac_cv_have_decl_unsetenv = no; then
27156 HAVE_DECL_UNSETENV=0
27158 for ac_func in unsetenv
27159 do :
27160 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27161 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27162 cat >>confdefs.h <<_ACEOF
27163 #define HAVE_UNSETENV 1
27164 _ACEOF
27167 done
27169 if test $ac_cv_func_unsetenv = no; then
27170 HAVE_UNSETENV=0
27171 else
27172 HAVE_UNSETENV=1
27173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27174 $as_echo_n "checking for unsetenv() return type... " >&6; }
27175 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27176 $as_echo_n "(cached) " >&6
27177 else
27178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27179 /* end confdefs.h. */
27181 #undef _BSD
27182 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27183 #include <stdlib.h>
27184 extern
27185 #ifdef __cplusplus
27187 #endif
27188 int unsetenv (const char *name);
27191 main ()
27195 return 0;
27197 _ACEOF
27198 if ac_fn_c_try_compile "$LINENO"; then :
27199 gt_cv_func_unsetenv_ret='int'
27200 else
27201 gt_cv_func_unsetenv_ret='void'
27203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27206 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27207 if test $gt_cv_func_unsetenv_ret = 'void'; then
27209 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27211 REPLACE_UNSETENV=1
27214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27215 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27216 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27217 $as_echo_n "(cached) " >&6
27218 else
27219 if test "$cross_compiling" = yes; then :
27220 case "$host_os" in
27221 # Guess yes on glibc systems.
27222 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27223 # If we don't know, assume the worst.
27224 *) gl_cv_func_unsetenv_works="guessing no" ;;
27225 esac
27227 else
27228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27229 /* end confdefs.h. */
27231 #include <stdlib.h>
27232 #include <errno.h>
27233 extern char **environ;
27236 main ()
27239 char entry1[] = "a=1";
27240 char entry2[] = "b=2";
27241 char *env[] = { entry1, entry2, NULL };
27242 if (putenv ((char *) "a=1")) return 1;
27243 if (putenv (entry2)) return 2;
27244 entry2[0] = 'a';
27245 unsetenv ("a");
27246 if (getenv ("a")) return 3;
27247 if (!unsetenv ("") || errno != EINVAL) return 4;
27248 entry2[0] = 'b';
27249 environ = env;
27250 if (!getenv ("a")) return 5;
27251 entry2[0] = 'a';
27252 unsetenv ("a");
27253 if (getenv ("a")) return 6;
27256 return 0;
27258 _ACEOF
27259 if ac_fn_c_try_run "$LINENO"; then :
27260 gl_cv_func_unsetenv_works=yes
27261 else
27262 gl_cv_func_unsetenv_works=no
27264 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27265 conftest.$ac_objext conftest.beam conftest.$ac_ext
27269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27270 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27271 case "$gl_cv_func_unsetenv_works" in
27272 *yes) ;;
27274 REPLACE_UNSETENV=1
27276 esac
27279 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27288 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27300 GNULIB_UNSETENV=1
27312 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
27313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
27314 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
27315 if test "${gl_cv_func_futimesat_works+set}" = set; then :
27316 $as_echo_n "(cached) " >&6
27317 else
27318 touch conftest.file
27319 if test "$cross_compiling" = yes; then :
27320 case "$host_os" in
27321 # Guess yes on glibc systems.
27322 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
27323 # If we don't know, assume the worst.
27324 *) gl_cv_func_futimesat_works="guessing no" ;;
27325 esac
27327 else
27328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27329 /* end confdefs.h. */
27331 #include <stddef.h>
27332 #include <sys/times.h>
27333 #include <fcntl.h>
27336 main ()
27338 int fd = open ("conftest.file", O_RDWR);
27339 if (fd < 0) return 1;
27340 if (futimesat (fd, NULL, NULL)) return 2;
27343 return 0;
27345 _ACEOF
27346 if ac_fn_c_try_run "$LINENO"; then :
27347 gl_cv_func_futimesat_works=yes
27348 else
27349 gl_cv_func_futimesat_works=no
27351 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27352 conftest.$ac_objext conftest.beam conftest.$ac_ext
27355 rm -f conftest.file
27357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
27358 $as_echo "$gl_cv_func_futimesat_works" >&6; }
27359 case "$gl_cv_func_futimesat_works" in
27360 *yes) ;;
27363 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
27366 esac
27369 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
27370 gl_gnulib_enabled_dosname=false
27371 gl_gnulib_enabled_euidaccess=false
27372 gl_gnulib_enabled_getgroups=false
27373 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
27374 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
27375 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
27376 gl_gnulib_enabled_pathmax=false
27377 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
27378 gl_gnulib_enabled_stat=false
27379 gl_gnulib_enabled_strtoll=false
27380 gl_gnulib_enabled_strtoull=false
27381 gl_gnulib_enabled_verify=false
27382 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
27383 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
27385 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
27394 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
27396 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
27399 func_gl_gnulib_m4code_dosname ()
27401 if ! $gl_gnulib_enabled_dosname; then
27402 gl_gnulib_enabled_dosname=true
27405 func_gl_gnulib_m4code_euidaccess ()
27407 if ! $gl_gnulib_enabled_euidaccess; then
27413 for ac_func in euidaccess
27414 do :
27415 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
27416 if test "x$ac_cv_func_euidaccess" = x""yes; then :
27417 cat >>confdefs.h <<_ACEOF
27418 #define HAVE_EUIDACCESS 1
27419 _ACEOF
27422 done
27424 if test $ac_cv_func_euidaccess = no; then
27425 HAVE_EUIDACCESS=0
27428 if test $HAVE_EUIDACCESS = 0; then
27437 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
27441 for ac_header in libgen.h
27442 do :
27443 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
27444 if test "x$ac_cv_header_libgen_h" = x""yes; then :
27445 cat >>confdefs.h <<_ACEOF
27446 #define HAVE_LIBGEN_H 1
27447 _ACEOF
27451 done
27454 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27455 if test "x$ac_cv_func_getgroups" = x""yes; then :
27460 # If we don't yet have getgroups, see if it's in -lbsd.
27461 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27462 ac_save_LIBS=$LIBS
27463 if test $ac_cv_func_getgroups = no; then
27464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27465 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27466 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27467 $as_echo_n "(cached) " >&6
27468 else
27469 ac_check_lib_save_LIBS=$LIBS
27470 LIBS="-lbsd $LIBS"
27471 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27472 /* end confdefs.h. */
27474 /* Override any GCC internal prototype to avoid an error.
27475 Use char because int might match the return type of a GCC
27476 builtin and then its argument prototype would still apply. */
27477 #ifdef __cplusplus
27478 extern "C"
27479 #endif
27480 char getgroups ();
27482 main ()
27484 return getgroups ();
27486 return 0;
27488 _ACEOF
27489 if ac_fn_c_try_link "$LINENO"; then :
27490 ac_cv_lib_bsd_getgroups=yes
27491 else
27492 ac_cv_lib_bsd_getgroups=no
27494 rm -f core conftest.err conftest.$ac_objext \
27495 conftest$ac_exeext conftest.$ac_ext
27496 LIBS=$ac_check_lib_save_LIBS
27498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27499 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27500 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27501 GETGROUPS_LIB=-lbsd
27506 # Run the program to test the functionality of the system-supplied
27507 # getgroups function only if there is such a function.
27508 if test $ac_cv_func_getgroups = yes; then
27509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
27510 $as_echo_n "checking for working getgroups... " >&6; }
27511 if test "${ac_cv_func_getgroups_works+set}" = set; then :
27512 $as_echo_n "(cached) " >&6
27513 else
27514 if test "$cross_compiling" = yes; then :
27515 case "$host_os" in # ((
27516 # Guess yes on glibc systems.
27517 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
27518 # If we don't know, assume the worst.
27519 *) ac_cv_func_getgroups_works="guessing no" ;;
27520 esac
27522 else
27523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27524 /* end confdefs.h. */
27525 $ac_includes_default
27527 main ()
27529 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
27530 return getgroups (0, 0) == -1;
27532 return 0;
27535 _ACEOF
27536 if ac_fn_c_try_run "$LINENO"; then :
27537 ac_cv_func_getgroups_works=yes
27538 else
27539 ac_cv_func_getgroups_works=no
27541 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27542 conftest.$ac_objext conftest.beam conftest.$ac_ext
27547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
27548 $as_echo "$ac_cv_func_getgroups_works" >&6; }
27549 else
27550 ac_cv_func_getgroups_works=no
27552 case "$ac_cv_func_getgroups_works" in
27553 *yes)
27555 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
27558 esac
27559 LIBS=$ac_save_LIBS
27562 # Solaris 9 and 10 need -lgen to get the eaccess function.
27563 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
27564 # programs in the package would end up linked with that potentially-shared
27565 # library, inducing unnecessary run-time overhead.
27566 LIB_EACCESS=
27568 gl_saved_libs=$LIBS
27569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
27570 $as_echo_n "checking for library containing eaccess... " >&6; }
27571 if test "${ac_cv_search_eaccess+set}" = set; then :
27572 $as_echo_n "(cached) " >&6
27573 else
27574 ac_func_search_save_LIBS=$LIBS
27575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27576 /* end confdefs.h. */
27578 /* Override any GCC internal prototype to avoid an error.
27579 Use char because int might match the return type of a GCC
27580 builtin and then its argument prototype would still apply. */
27581 #ifdef __cplusplus
27582 extern "C"
27583 #endif
27584 char eaccess ();
27586 main ()
27588 return eaccess ();
27590 return 0;
27592 _ACEOF
27593 for ac_lib in '' gen; do
27594 if test -z "$ac_lib"; then
27595 ac_res="none required"
27596 else
27597 ac_res=-l$ac_lib
27598 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27600 if ac_fn_c_try_link "$LINENO"; then :
27601 ac_cv_search_eaccess=$ac_res
27603 rm -f core conftest.err conftest.$ac_objext \
27604 conftest$ac_exeext
27605 if test "${ac_cv_search_eaccess+set}" = set; then :
27606 break
27608 done
27609 if test "${ac_cv_search_eaccess+set}" = set; then :
27611 else
27612 ac_cv_search_eaccess=no
27614 rm conftest.$ac_ext
27615 LIBS=$ac_func_search_save_LIBS
27617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
27618 $as_echo "$ac_cv_search_eaccess" >&6; }
27619 ac_res=$ac_cv_search_eaccess
27620 if test "$ac_res" != no; then :
27621 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27622 test "$ac_cv_search_eaccess" = "none required" ||
27623 LIB_EACCESS=$ac_cv_search_eaccess
27626 for ac_func in eaccess
27627 do :
27628 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
27629 if test "x$ac_cv_func_eaccess" = x""yes; then :
27630 cat >>confdefs.h <<_ACEOF
27631 #define HAVE_EACCESS 1
27632 _ACEOF
27635 done
27637 LIBS=$gl_saved_libs
27645 GNULIB_EUIDACCESS=1
27651 gl_gnulib_enabled_euidaccess=true
27652 if test $HAVE_EUIDACCESS = 0; then
27653 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
27655 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
27656 if test $HAVE_EUIDACCESS = 0; then
27657 func_gl_gnulib_m4code_stat
27661 func_gl_gnulib_m4code_getgroups ()
27663 if ! $gl_gnulib_enabled_getgroups; then
27669 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
27670 if test "x$ac_cv_func_getgroups" = x""yes; then :
27675 # If we don't yet have getgroups, see if it's in -lbsd.
27676 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
27677 ac_save_LIBS=$LIBS
27678 if test $ac_cv_func_getgroups = no; then
27679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
27680 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
27681 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
27682 $as_echo_n "(cached) " >&6
27683 else
27684 ac_check_lib_save_LIBS=$LIBS
27685 LIBS="-lbsd $LIBS"
27686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27687 /* end confdefs.h. */
27689 /* Override any GCC internal prototype to avoid an error.
27690 Use char because int might match the return type of a GCC
27691 builtin and then its argument prototype would still apply. */
27692 #ifdef __cplusplus
27693 extern "C"
27694 #endif
27695 char getgroups ();
27697 main ()
27699 return getgroups ();
27701 return 0;
27703 _ACEOF
27704 if ac_fn_c_try_link "$LINENO"; then :
27705 ac_cv_lib_bsd_getgroups=yes
27706 else
27707 ac_cv_lib_bsd_getgroups=no
27709 rm -f core conftest.err conftest.$ac_objext \
27710 conftest$ac_exeext conftest.$ac_ext
27711 LIBS=$ac_check_lib_save_LIBS
27713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
27714 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
27715 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
27716 GETGROUPS_LIB=-lbsd
27721 # Run the program to test the functionality of the system-supplied
27722 # getgroups function only if there is such a function.
27723 if test $ac_cv_func_getgroups = yes; then
27724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
27725 $as_echo_n "checking for working getgroups... " >&6; }
27726 if test "${ac_cv_func_getgroups_works+set}" = set; then :
27727 $as_echo_n "(cached) " >&6
27728 else
27729 if test "$cross_compiling" = yes; then :
27730 case "$host_os" in # ((
27731 # Guess yes on glibc systems.
27732 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
27733 # If we don't know, assume the worst.
27734 *) ac_cv_func_getgroups_works="guessing no" ;;
27735 esac
27737 else
27738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27739 /* end confdefs.h. */
27740 $ac_includes_default
27742 main ()
27744 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
27745 return getgroups (0, 0) == -1;
27747 return 0;
27750 _ACEOF
27751 if ac_fn_c_try_run "$LINENO"; then :
27752 ac_cv_func_getgroups_works=yes
27753 else
27754 ac_cv_func_getgroups_works=no
27756 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27757 conftest.$ac_objext conftest.beam conftest.$ac_ext
27762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
27763 $as_echo "$ac_cv_func_getgroups_works" >&6; }
27764 else
27765 ac_cv_func_getgroups_works=no
27767 case "$ac_cv_func_getgroups_works" in
27768 *yes)
27770 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
27773 esac
27774 LIBS=$ac_save_LIBS
27776 if test $ac_cv_func_getgroups != yes; then
27777 HAVE_GETGROUPS=0
27778 else
27779 if test "$ac_cv_type_getgroups" != gid_t \
27780 || { case "$ac_cv_func_getgroups_works" in
27781 *yes) false;;
27782 *) true;;
27783 esac
27784 }; then
27785 REPLACE_GETGROUPS=1
27787 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
27789 else
27790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
27791 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
27792 if test "${gl_cv_func_getgroups_works+set}" = set; then :
27793 $as_echo_n "(cached) " >&6
27794 else
27795 if test "$cross_compiling" = yes; then :
27796 case "$host_os" in
27797 # Guess yes on glibc systems.
27798 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
27799 # If we don't know, assume the worst.
27800 *) gl_cv_func_getgroups_works="guessing no" ;;
27801 esac
27803 else
27804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27805 /* end confdefs.h. */
27806 $ac_includes_default
27808 main ()
27810 int size = getgroups (0, 0);
27811 gid_t *list = malloc (size * sizeof *list);
27812 return getgroups (-1, list) != -1;
27814 return 0;
27816 _ACEOF
27817 if ac_fn_c_try_run "$LINENO"; then :
27818 gl_cv_func_getgroups_works=yes
27819 else
27820 gl_cv_func_getgroups_works=no
27822 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27823 conftest.$ac_objext conftest.beam conftest.$ac_ext
27827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
27828 $as_echo "$gl_cv_func_getgroups_works" >&6; }
27829 case "$gl_cv_func_getgroups_works" in
27830 *yes) ;;
27831 *) REPLACE_GETGROUPS=1 ;;
27832 esac
27835 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
27837 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
27846 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
27854 GNULIB_GETGROUPS=1
27860 gl_gnulib_enabled_getgroups=true
27863 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
27865 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
27868 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
27871 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
27873 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
27879 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
27880 if test "x$ac_cv_func_group_member" = x""yes; then :
27882 else
27884 HAVE_GROUP_MEMBER=0
27889 if test $HAVE_GROUP_MEMBER = 0; then
27898 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
27909 GNULIB_GROUP_MEMBER=1
27915 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
27916 if test $HAVE_GROUP_MEMBER = 0; then
27917 func_gl_gnulib_m4code_getgroups
27919 if test $HAVE_GROUP_MEMBER = 0; then
27920 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
27924 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
27926 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
27927 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
27930 func_gl_gnulib_m4code_pathmax ()
27932 if ! $gl_gnulib_enabled_pathmax; then
27936 gl_gnulib_enabled_pathmax=true
27939 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
27941 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
27942 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
27945 func_gl_gnulib_m4code_stat ()
27947 if ! $gl_gnulib_enabled_stat; then
27951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
27952 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
27953 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
27954 $as_echo_n "(cached) " >&6
27955 else
27956 if test "$cross_compiling" = yes; then :
27957 case $host_os in
27958 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
27959 *) gl_cv_func_stat_dir_slash="guessing yes";;
27960 esac
27961 else
27962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27963 /* end confdefs.h. */
27964 #include <sys/stat.h>
27967 main ()
27969 struct stat st; return stat (".", &st) != stat ("./", &st);
27971 return 0;
27973 _ACEOF
27974 if ac_fn_c_try_run "$LINENO"; then :
27975 gl_cv_func_stat_dir_slash=yes
27976 else
27977 gl_cv_func_stat_dir_slash=no
27979 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27980 conftest.$ac_objext conftest.beam conftest.$ac_ext
27984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
27985 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
27986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
27987 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
27988 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
27989 $as_echo_n "(cached) " >&6
27990 else
27991 touch conftest.tmp
27992 # Assume that if we have lstat, we can also check symlinks.
27993 if test $ac_cv_func_lstat = yes; then
27994 ln -s conftest.tmp conftest.lnk
27996 if test "$cross_compiling" = yes; then :
27997 case "$host_os" in
27998 # Guess yes on glibc systems.
27999 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28000 # If we don't know, assume the worst.
28001 *) gl_cv_func_stat_file_slash="guessing no" ;;
28002 esac
28004 else
28005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28006 /* end confdefs.h. */
28007 #include <sys/stat.h>
28010 main ()
28012 int result = 0;
28013 struct stat st;
28014 if (!stat ("conftest.tmp/", &st))
28015 result |= 1;
28016 #if HAVE_LSTAT
28017 if (!stat ("conftest.lnk/", &st))
28018 result |= 2;
28019 #endif
28020 return result;
28023 return 0;
28025 _ACEOF
28026 if ac_fn_c_try_run "$LINENO"; then :
28027 gl_cv_func_stat_file_slash=yes
28028 else
28029 gl_cv_func_stat_file_slash=no
28031 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28032 conftest.$ac_objext conftest.beam conftest.$ac_ext
28035 rm -f conftest.tmp conftest.lnk
28037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28038 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28039 case $gl_cv_func_stat_dir_slash in
28040 *no) REPLACE_STAT=1
28042 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28044 esac
28045 case $gl_cv_func_stat_file_slash in
28046 *no) REPLACE_STAT=1
28048 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28050 esac
28052 if test $REPLACE_STAT = 1; then
28061 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28070 GNULIB_STAT=1
28076 gl_gnulib_enabled_stat=true
28077 if test $REPLACE_STAT = 1; then
28078 func_gl_gnulib_m4code_dosname
28080 if test $REPLACE_STAT = 1; then
28081 func_gl_gnulib_m4code_pathmax
28083 if test $REPLACE_STAT = 1; then
28084 func_gl_gnulib_m4code_verify
28088 func_gl_gnulib_m4code_strtoll ()
28090 if ! $gl_gnulib_enabled_strtoll; then
28094 if test "$ac_cv_type_long_long_int" = yes; then
28095 for ac_func in strtoll
28096 do :
28097 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28098 if test "x$ac_cv_func_strtoll" = x""yes; then :
28099 cat >>confdefs.h <<_ACEOF
28100 #define HAVE_STRTOLL 1
28101 _ACEOF
28104 done
28106 if test $ac_cv_func_strtoll = no; then
28107 HAVE_STRTOLL=0
28111 if test $HAVE_STRTOLL = 0; then
28120 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28131 GNULIB_STRTOLL=1
28137 gl_gnulib_enabled_strtoll=true
28140 func_gl_gnulib_m4code_strtoull ()
28142 if ! $gl_gnulib_enabled_strtoull; then
28146 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28147 for ac_func in strtoull
28148 do :
28149 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
28150 if test "x$ac_cv_func_strtoull" = x""yes; then :
28151 cat >>confdefs.h <<_ACEOF
28152 #define HAVE_STRTOULL 1
28153 _ACEOF
28156 done
28158 if test $ac_cv_func_strtoull = no; then
28159 HAVE_STRTOULL=0
28163 if test $HAVE_STRTOULL = 0; then
28172 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
28183 GNULIB_STRTOULL=1
28189 gl_gnulib_enabled_strtoull=true
28192 func_gl_gnulib_m4code_verify ()
28194 if ! $gl_gnulib_enabled_verify; then
28195 gl_gnulib_enabled_verify=true
28198 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
28200 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28201 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
28204 if test $HAVE_FACCESSAT = 0; then
28205 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28207 if test $HAVE_FACCESSAT = 0; then
28208 func_gl_gnulib_m4code_dosname
28210 if test $HAVE_FACCESSAT = 0; then
28211 func_gl_gnulib_m4code_euidaccess
28213 if test $HAVE_FACCESSAT = 0; then
28214 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28216 if test $HAVE_FDOPENDIR = 0; then
28217 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28219 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28220 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28222 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28223 func_gl_gnulib_m4code_dosname
28225 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
28226 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28228 if test $REPLACE_GETOPT = 1; then
28229 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
28231 if test $REPLACE_LSTAT = 1; then
28232 func_gl_gnulib_m4code_dosname
28234 if test $REPLACE_LSTAT = 1; then
28235 func_gl_gnulib_m4code_stat
28237 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
28238 func_gl_gnulib_m4code_stat
28240 if test $HAVE_READLINKAT = 0; then
28241 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
28243 if test $HAVE_READLINKAT = 0; then
28244 func_gl_gnulib_m4code_dosname
28246 if test $HAVE_READLINKAT = 0; then
28247 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
28249 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
28250 func_gl_gnulib_m4code_strtoll
28252 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
28253 func_gl_gnulib_m4code_verify
28255 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
28256 func_gl_gnulib_m4code_strtoull
28258 if test $ac_cv_func_strtoumax = no; then
28259 func_gl_gnulib_m4code_verify
28262 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28263 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
28264 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
28265 else
28266 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
28267 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
28270 if $gl_gnulib_enabled_dosname; then
28271 gl_GNULIB_ENABLED_dosname_TRUE=
28272 gl_GNULIB_ENABLED_dosname_FALSE='#'
28273 else
28274 gl_GNULIB_ENABLED_dosname_TRUE='#'
28275 gl_GNULIB_ENABLED_dosname_FALSE=
28278 if $gl_gnulib_enabled_euidaccess; then
28279 gl_GNULIB_ENABLED_euidaccess_TRUE=
28280 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
28281 else
28282 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
28283 gl_GNULIB_ENABLED_euidaccess_FALSE=
28286 if $gl_gnulib_enabled_getgroups; then
28287 gl_GNULIB_ENABLED_getgroups_TRUE=
28288 gl_GNULIB_ENABLED_getgroups_FALSE='#'
28289 else
28290 gl_GNULIB_ENABLED_getgroups_TRUE='#'
28291 gl_GNULIB_ENABLED_getgroups_FALSE=
28294 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28295 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
28296 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
28297 else
28298 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
28299 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
28302 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28303 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
28304 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
28305 else
28306 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
28307 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
28310 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28311 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
28312 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
28313 else
28314 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
28315 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
28318 if $gl_gnulib_enabled_pathmax; then
28319 gl_GNULIB_ENABLED_pathmax_TRUE=
28320 gl_GNULIB_ENABLED_pathmax_FALSE='#'
28321 else
28322 gl_GNULIB_ENABLED_pathmax_TRUE='#'
28323 gl_GNULIB_ENABLED_pathmax_FALSE=
28326 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28327 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
28328 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
28329 else
28330 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
28331 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
28334 if $gl_gnulib_enabled_stat; then
28335 gl_GNULIB_ENABLED_stat_TRUE=
28336 gl_GNULIB_ENABLED_stat_FALSE='#'
28337 else
28338 gl_GNULIB_ENABLED_stat_TRUE='#'
28339 gl_GNULIB_ENABLED_stat_FALSE=
28342 if $gl_gnulib_enabled_strtoll; then
28343 gl_GNULIB_ENABLED_strtoll_TRUE=
28344 gl_GNULIB_ENABLED_strtoll_FALSE='#'
28345 else
28346 gl_GNULIB_ENABLED_strtoll_TRUE='#'
28347 gl_GNULIB_ENABLED_strtoll_FALSE=
28350 if $gl_gnulib_enabled_strtoull; then
28351 gl_GNULIB_ENABLED_strtoull_TRUE=
28352 gl_GNULIB_ENABLED_strtoull_FALSE='#'
28353 else
28354 gl_GNULIB_ENABLED_strtoull_TRUE='#'
28355 gl_GNULIB_ENABLED_strtoull_FALSE=
28358 if $gl_gnulib_enabled_verify; then
28359 gl_GNULIB_ENABLED_verify_TRUE=
28360 gl_GNULIB_ENABLED_verify_FALSE='#'
28361 else
28362 gl_GNULIB_ENABLED_verify_TRUE='#'
28363 gl_GNULIB_ENABLED_verify_FALSE=
28366 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
28367 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
28368 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
28369 else
28370 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
28371 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
28374 # End of code from modules
28384 gltests_libdeps=
28385 gltests_ltlibdeps=
28395 gl_source_base='tests'
28396 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
28398 gl_module_indicator_condition=$gltests_WITNESS
28409 LIBGNU_LIBDEPS="$gl_libdeps"
28411 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
28414 CFLAGS=$SAVE_CFLAGS
28415 LIBS=$SAVE_LIBS
28417 if test "${opsys}" = "mingw32"; then
28418 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
28419 # Remove unneeded switches from the value of CC that goes to Makefiles
28420 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
28423 case "$opsys" in
28424 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
28426 darwin)
28427 ## The -headerpad option tells ld (see man page) to leave room at the
28428 ## end of the header for adding load commands. Needed for dumping.
28429 ## 0x690 is the total size of 30 segment load commands (at 56
28430 ## each); under Cocoa 31 commands are required.
28431 if test "$HAVE_NS" = "yes"; then
28432 libs_nsgui="-framework AppKit"
28433 if test "$NS_IMPL_COCOA" = "yes"; then
28434 libs_nsgui="$libs_nsgui -framework IOKit"
28436 headerpad_extra=6C8
28437 else
28438 libs_nsgui=
28439 headerpad_extra=690
28441 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
28443 ## This is here because src/Makefile.in did some extra fiddling around
28444 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
28445 ## LD_SWITCH_SYSTEM_TEMACS instead,
28446 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
28447 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
28450 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
28451 ## find X at run-time.
28452 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
28453 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
28454 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
28455 ## had different values in configure (in ac_link) and src/Makefile.in.
28456 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
28457 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
28459 mingw32)
28460 ## MinGW64 does not prepend an underscore to symbols, so we must
28461 ## pass a different -entry switch to linker. FIXME: It is better
28462 ## to make the entry points the same by changing unexw32.c.
28463 case "$canonical" in
28464 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
28465 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
28466 esac
28469 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
28471 *) LD_SWITCH_SYSTEM_TEMACS= ;;
28472 esac
28474 if test x$ac_enable_profiling != x ; then
28475 case $opsys in
28476 *freebsd | gnu-linux) ;;
28477 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
28478 esac
28483 ## MinGW-specific post-link processing of temacs.
28484 TEMACS_POST_LINK=":"
28485 ADDSECTION=
28486 EMACS_HEAPSIZE=
28487 if test "${opsys}" = "mingw32"; then
28488 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
28489 ADDSECTION="../nt/addsection\$(EXEEXT)"
28490 ## Preload heap size of temacs.exe in MB.
28491 case "$canonical" in
28492 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
28493 *) EMACS_HEAPSIZE=27 ;;
28494 esac
28501 ## Common for all window systems
28502 if test "$window_system" != "none"; then
28504 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
28506 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
28513 #### Report on what we decided to do.
28514 #### Report GTK as a toolkit, even if it doesn't use Xt.
28515 #### It makes printing result more understandable as using GTK sets
28516 #### toolkit_scroll_bars to yes by default.
28517 if test "${HAVE_GTK}" = "yes"; then
28518 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
28521 echo "
28522 Configured for \`${canonical}'.
28524 Where should the build process find the source code? ${srcdir}
28525 What compiler should emacs be built with? ${CC} ${CFLAGS}
28526 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
28527 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
28528 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
28529 What window system should Emacs use? ${window_system}
28530 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
28532 if test -n "${x_includes}"; then
28533 echo " Where do we find X Windows header files? ${x_includes}"
28534 else
28535 echo " Where do we find X Windows header files? Standard dirs"
28537 if test -n "${x_libraries}"; then
28538 echo " Where do we find X Windows libraries? ${x_libraries}"
28539 else
28540 echo " Where do we find X Windows libraries? Standard dirs"
28543 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
28544 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
28545 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
28546 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
28547 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
28548 echo " Does Emacs use -lpng? ${HAVE_PNG}"
28549 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
28550 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
28552 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
28553 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
28554 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
28555 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
28556 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
28557 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
28558 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
28559 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
28561 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
28562 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
28563 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
28564 echo " Does Emacs use -lxft? ${HAVE_XFT}"
28566 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
28567 echo
28569 if test -n "${EMACSDATA}"; then
28570 echo " Environment variable EMACSDATA set to: $EMACSDATA"
28572 if test -n "${EMACSDOC}"; then
28573 echo " Environment variable EMACSDOC set to: $EMACSDOC"
28576 echo
28578 if test "$HAVE_NS" = "yes"; then
28579 echo
28580 echo "You must run \"${MAKE-make} install\" in order to test the built application.
28581 The installed application will go to nextstep/Emacs.app and can be
28582 run or moved from there."
28583 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
28584 echo "The application will be fully self-contained."
28585 else
28586 echo "The lisp resources for the application will be installed under ${prefix}.
28587 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
28588 to run if these resources are not installed."
28590 echo
28593 if test "${opsys}" = "cygwin"; then
28594 case `uname -r` in
28595 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
28596 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
28597 echo
28599 esac
28602 # Remove any trailing slashes in these variables.
28603 test "${prefix}" != NONE &&
28604 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
28605 test "${exec_prefix}" != NONE &&
28606 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
28608 if test "$HAVE_NS" = "yes"; then
28609 if test "$NS_IMPL_GNUSTEP" = yes; then
28610 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"
28612 else
28613 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"
28618 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"
28620 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"
28623 opt_makefile=test/automated/Makefile
28625 if test -f "$srcdir/$opt_makefile.in"; then
28626 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
28627 ac_config_files="$ac_config_files test/automated/Makefile"
28632 opt_makefile=admin/unidata/Makefile
28634 if test -f "$srcdir/$opt_makefile.in"; then
28635 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
28636 ac_config_files="$ac_config_files admin/unidata/Makefile"
28641 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
28645 ac_config_commands="$ac_config_commands mkdirs"
28648 ac_config_commands="$ac_config_commands epaths"
28651 ac_config_commands="$ac_config_commands gdbinit"
28654 cat >confcache <<\_ACEOF
28655 # This file is a shell script that caches the results of configure
28656 # tests run on this system so they can be shared between configure
28657 # scripts and configure runs, see configure's option --config-cache.
28658 # It is not useful on other systems. If it contains results you don't
28659 # want to keep, you may remove or edit it.
28661 # config.status only pays attention to the cache file if you give it
28662 # the --recheck option to rerun configure.
28664 # `ac_cv_env_foo' variables (set or unset) will be overridden when
28665 # loading this file, other *unset* `ac_cv_foo' will be assigned the
28666 # following values.
28668 _ACEOF
28670 # The following way of writing the cache mishandles newlines in values,
28671 # but we know of no workaround that is simple, portable, and efficient.
28672 # So, we kill variables containing newlines.
28673 # Ultrix sh set writes to stderr and can't be redirected directly,
28674 # and sets the high bit in the cache file unless we assign to the vars.
28676 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
28677 eval ac_val=\$$ac_var
28678 case $ac_val in #(
28679 *${as_nl}*)
28680 case $ac_var in #(
28681 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
28682 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
28683 esac
28684 case $ac_var in #(
28685 _ | IFS | as_nl) ;; #(
28686 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
28687 *) { eval $ac_var=; unset $ac_var;} ;;
28688 esac ;;
28689 esac
28690 done
28692 (set) 2>&1 |
28693 case $as_nl`(ac_space=' '; set) 2>&1` in #(
28694 *${as_nl}ac_space=\ *)
28695 # `set' does not quote correctly, so add quotes: double-quote
28696 # substitution turns \\\\ into \\, and sed turns \\ into \.
28697 sed -n \
28698 "s/'/'\\\\''/g;
28699 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
28700 ;; #(
28702 # `set' quotes correctly as required by POSIX, so do not add quotes.
28703 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
28705 esac |
28706 sort
28708 sed '
28709 /^ac_cv_env_/b end
28710 t clear
28711 :clear
28712 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
28713 t end
28714 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
28715 :end' >>confcache
28716 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
28717 if test -w "$cache_file"; then
28718 test "x$cache_file" != "x/dev/null" &&
28719 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
28720 $as_echo "$as_me: updating cache $cache_file" >&6;}
28721 cat confcache >$cache_file
28722 else
28723 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
28724 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
28727 rm -f confcache
28729 test "x$prefix" = xNONE && prefix=$ac_default_prefix
28730 # Let make expand exec_prefix.
28731 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
28733 DEFS=-DHAVE_CONFIG_H
28735 ac_libobjs=
28736 ac_ltlibobjs=
28737 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
28738 # 1. Remove the extension, and $U if already installed.
28739 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
28740 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
28741 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
28742 # will be set to the directory where LIBOBJS objects are built.
28743 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
28744 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
28745 done
28746 LIBOBJS=$ac_libobjs
28748 LTLIBOBJS=$ac_ltlibobjs
28751 if test -n "$EXEEXT"; then
28752 am__EXEEXT_TRUE=
28753 am__EXEEXT_FALSE='#'
28754 else
28755 am__EXEEXT_TRUE='#'
28756 am__EXEEXT_FALSE=
28759 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
28760 as_fn_error "conditional \"AMDEP\" was never defined.
28761 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28763 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
28764 as_fn_error "conditional \"am__fastdepCC\" was never defined.
28765 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28767 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
28768 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
28769 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28771 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
28772 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
28773 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28775 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
28776 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
28777 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28780 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
28781 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
28782 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28784 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
28785 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
28786 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28788 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
28789 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
28790 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28792 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
28793 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
28794 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28796 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
28797 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
28798 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28800 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
28801 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
28802 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28804 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
28805 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
28806 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28808 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
28809 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
28810 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28812 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
28813 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
28814 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28816 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
28817 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
28818 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28820 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
28821 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
28822 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28824 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
28825 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
28826 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28828 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
28829 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
28830 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28832 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
28833 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
28834 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28836 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
28837 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
28838 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28840 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
28841 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
28842 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28844 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
28845 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
28846 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28848 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
28849 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
28850 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28852 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
28853 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
28854 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28856 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
28857 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
28858 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28860 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
28861 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
28862 Usually this means the macro was only invoked conditionally." "$LINENO" 5
28865 gl_libobjs=
28866 gl_ltlibobjs=
28867 if test -n "$gl_LIBOBJS"; then
28868 # Remove the extension.
28869 sed_drop_objext='s/\.o$//;s/\.obj$//'
28870 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
28871 gl_libobjs="$gl_libobjs $i.$ac_objext"
28872 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
28873 done
28875 gl_LIBOBJS=$gl_libobjs
28877 gl_LTLIBOBJS=$gl_ltlibobjs
28881 gltests_libobjs=
28882 gltests_ltlibobjs=
28883 if test -n "$gltests_LIBOBJS"; then
28884 # Remove the extension.
28885 sed_drop_objext='s/\.o$//;s/\.obj$//'
28886 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
28887 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
28888 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
28889 done
28891 gltests_LIBOBJS=$gltests_libobjs
28893 gltests_LTLIBOBJS=$gltests_ltlibobjs
28897 : ${CONFIG_STATUS=./config.status}
28898 ac_write_fail=0
28899 ac_clean_files_save=$ac_clean_files
28900 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
28901 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
28902 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
28903 as_write_fail=0
28904 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
28905 #! $SHELL
28906 # Generated by $as_me.
28907 # Run this file to recreate the current configuration.
28908 # Compiler output produced by configure, useful for debugging
28909 # configure, is in config.log if it exists.
28911 debug=false
28912 ac_cs_recheck=false
28913 ac_cs_silent=false
28915 SHELL=\${CONFIG_SHELL-$SHELL}
28916 export SHELL
28917 _ASEOF
28918 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
28919 ## -------------------- ##
28920 ## M4sh Initialization. ##
28921 ## -------------------- ##
28923 # Be more Bourne compatible
28924 DUALCASE=1; export DUALCASE # for MKS sh
28925 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
28926 emulate sh
28927 NULLCMD=:
28928 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
28929 # is contrary to our usage. Disable this feature.
28930 alias -g '${1+"$@"}'='"$@"'
28931 setopt NO_GLOB_SUBST
28932 else
28933 case `(set -o) 2>/dev/null` in #(
28934 *posix*) :
28935 set -o posix ;; #(
28936 *) :
28938 esac
28942 as_nl='
28944 export as_nl
28945 # Printing a long string crashes Solaris 7 /usr/bin/printf.
28946 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
28947 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
28948 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
28949 # Prefer a ksh shell builtin over an external printf program on Solaris,
28950 # but without wasting forks for bash or zsh.
28951 if test -z "$BASH_VERSION$ZSH_VERSION" \
28952 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
28953 as_echo='print -r --'
28954 as_echo_n='print -rn --'
28955 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
28956 as_echo='printf %s\n'
28957 as_echo_n='printf %s'
28958 else
28959 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
28960 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
28961 as_echo_n='/usr/ucb/echo -n'
28962 else
28963 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
28964 as_echo_n_body='eval
28965 arg=$1;
28966 case $arg in #(
28967 *"$as_nl"*)
28968 expr "X$arg" : "X\\(.*\\)$as_nl";
28969 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
28970 esac;
28971 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
28973 export as_echo_n_body
28974 as_echo_n='sh -c $as_echo_n_body as_echo'
28976 export as_echo_body
28977 as_echo='sh -c $as_echo_body as_echo'
28980 # The user is always right.
28981 if test "${PATH_SEPARATOR+set}" != set; then
28982 PATH_SEPARATOR=:
28983 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
28984 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
28985 PATH_SEPARATOR=';'
28990 # IFS
28991 # We need space, tab and new line, in precisely that order. Quoting is
28992 # there to prevent editors from complaining about space-tab.
28993 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
28994 # splitting by setting IFS to empty value.)
28995 IFS=" "" $as_nl"
28997 # Find who we are. Look in the path if we contain no directory separator.
28998 case $0 in #((
28999 *[\\/]* ) as_myself=$0 ;;
29000 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29001 for as_dir in $PATH
29003 IFS=$as_save_IFS
29004 test -z "$as_dir" && as_dir=.
29005 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29006 done
29007 IFS=$as_save_IFS
29010 esac
29011 # We did not find ourselves, most probably we were run as `sh COMMAND'
29012 # in which case we are not to be found in the path.
29013 if test "x$as_myself" = x; then
29014 as_myself=$0
29016 if test ! -f "$as_myself"; then
29017 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29018 exit 1
29021 # Unset variables that we do not need and which cause bugs (e.g. in
29022 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29023 # suppresses any "Segmentation fault" message there. '((' could
29024 # trigger a bug in pdksh 5.2.14.
29025 for as_var in BASH_ENV ENV MAIL MAILPATH
29026 do eval test x\${$as_var+set} = xset \
29027 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29028 done
29029 PS1='$ '
29030 PS2='> '
29031 PS4='+ '
29033 # NLS nuisances.
29034 LC_ALL=C
29035 export LC_ALL
29036 LANGUAGE=C
29037 export LANGUAGE
29039 # CDPATH.
29040 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29043 # as_fn_error ERROR [LINENO LOG_FD]
29044 # ---------------------------------
29045 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29046 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29047 # script with status $?, using 1 if that was 0.
29048 as_fn_error ()
29050 as_status=$?; test $as_status -eq 0 && as_status=1
29051 if test "$3"; then
29052 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29053 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29055 $as_echo "$as_me: error: $1" >&2
29056 as_fn_exit $as_status
29057 } # as_fn_error
29060 # as_fn_set_status STATUS
29061 # -----------------------
29062 # Set $? to STATUS, without forking.
29063 as_fn_set_status ()
29065 return $1
29066 } # as_fn_set_status
29068 # as_fn_exit STATUS
29069 # -----------------
29070 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29071 as_fn_exit ()
29073 set +e
29074 as_fn_set_status $1
29075 exit $1
29076 } # as_fn_exit
29078 # as_fn_unset VAR
29079 # ---------------
29080 # Portably unset VAR.
29081 as_fn_unset ()
29083 { eval $1=; unset $1;}
29085 as_unset=as_fn_unset
29086 # as_fn_append VAR VALUE
29087 # ----------------------
29088 # Append the text in VALUE to the end of the definition contained in VAR. Take
29089 # advantage of any shell optimizations that allow amortized linear growth over
29090 # repeated appends, instead of the typical quadratic growth present in naive
29091 # implementations.
29092 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29093 eval 'as_fn_append ()
29095 eval $1+=\$2
29097 else
29098 as_fn_append ()
29100 eval $1=\$$1\$2
29102 fi # as_fn_append
29104 # as_fn_arith ARG...
29105 # ------------------
29106 # Perform arithmetic evaluation on the ARGs, and store the result in the
29107 # global $as_val. Take advantage of shells that can avoid forks. The arguments
29108 # must be portable across $(()) and expr.
29109 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
29110 eval 'as_fn_arith ()
29112 as_val=$(( $* ))
29114 else
29115 as_fn_arith ()
29117 as_val=`expr "$@" || test $? -eq 1`
29119 fi # as_fn_arith
29122 if expr a : '\(a\)' >/dev/null 2>&1 &&
29123 test "X`expr 00001 : '.*\(...\)'`" = X001; then
29124 as_expr=expr
29125 else
29126 as_expr=false
29129 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29130 as_basename=basename
29131 else
29132 as_basename=false
29135 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29136 as_dirname=dirname
29137 else
29138 as_dirname=false
29141 as_me=`$as_basename -- "$0" ||
29142 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29143 X"$0" : 'X\(//\)$' \| \
29144 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29145 $as_echo X/"$0" |
29146 sed '/^.*\/\([^/][^/]*\)\/*$/{
29147 s//\1/
29150 /^X\/\(\/\/\)$/{
29151 s//\1/
29154 /^X\/\(\/\).*/{
29155 s//\1/
29158 s/.*/./; q'`
29160 # Avoid depending upon Character Ranges.
29161 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29162 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29163 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29164 as_cr_digits='0123456789'
29165 as_cr_alnum=$as_cr_Letters$as_cr_digits
29167 ECHO_C= ECHO_N= ECHO_T=
29168 case `echo -n x` in #(((((
29169 -n*)
29170 case `echo 'xy\c'` in
29171 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
29172 xy) ECHO_C='\c';;
29173 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
29174 ECHO_T=' ';;
29175 esac;;
29177 ECHO_N='-n';;
29178 esac
29180 rm -f conf$$ conf$$.exe conf$$.file
29181 if test -d conf$$.dir; then
29182 rm -f conf$$.dir/conf$$.file
29183 else
29184 rm -f conf$$.dir
29185 mkdir conf$$.dir 2>/dev/null
29187 if (echo >conf$$.file) 2>/dev/null; then
29188 if ln -s conf$$.file conf$$ 2>/dev/null; then
29189 as_ln_s='ln -s'
29190 # ... but there are two gotchas:
29191 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29192 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29193 # In both cases, we have to default to `cp -p'.
29194 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29195 as_ln_s='cp -p'
29196 elif ln conf$$.file conf$$ 2>/dev/null; then
29197 as_ln_s=ln
29198 else
29199 as_ln_s='cp -p'
29201 else
29202 as_ln_s='cp -p'
29204 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29205 rmdir conf$$.dir 2>/dev/null
29208 # as_fn_mkdir_p
29209 # -------------
29210 # Create "$as_dir" as a directory, including parents if necessary.
29211 as_fn_mkdir_p ()
29214 case $as_dir in #(
29215 -*) as_dir=./$as_dir;;
29216 esac
29217 test -d "$as_dir" || eval $as_mkdir_p || {
29218 as_dirs=
29219 while :; do
29220 case $as_dir in #(
29221 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29222 *) as_qdir=$as_dir;;
29223 esac
29224 as_dirs="'$as_qdir' $as_dirs"
29225 as_dir=`$as_dirname -- "$as_dir" ||
29226 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29227 X"$as_dir" : 'X\(//\)[^/]' \| \
29228 X"$as_dir" : 'X\(//\)$' \| \
29229 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29230 $as_echo X"$as_dir" |
29231 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29232 s//\1/
29235 /^X\(\/\/\)[^/].*/{
29236 s//\1/
29239 /^X\(\/\/\)$/{
29240 s//\1/
29243 /^X\(\/\).*/{
29244 s//\1/
29247 s/.*/./; q'`
29248 test -d "$as_dir" && break
29249 done
29250 test -z "$as_dirs" || eval "mkdir $as_dirs"
29251 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
29254 } # as_fn_mkdir_p
29255 if mkdir -p . 2>/dev/null; then
29256 as_mkdir_p='mkdir -p "$as_dir"'
29257 else
29258 test -d ./-p && rmdir ./-p
29259 as_mkdir_p=false
29262 if test -x / >/dev/null 2>&1; then
29263 as_test_x='test -x'
29264 else
29265 if ls -dL / >/dev/null 2>&1; then
29266 as_ls_L_option=L
29267 else
29268 as_ls_L_option=
29270 as_test_x='
29271 eval sh -c '\''
29272 if test -d "$1"; then
29273 test -d "$1/.";
29274 else
29275 case $1 in #(
29276 -*)set "./$1";;
29277 esac;
29278 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
29279 ???[sx]*):;;*)false;;esac;fi
29280 '\'' sh
29283 as_executable_p=$as_test_x
29285 # Sed expression to map a string onto a valid CPP name.
29286 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29288 # Sed expression to map a string onto a valid variable name.
29289 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29292 exec 6>&1
29293 ## ----------------------------------- ##
29294 ## Main body of $CONFIG_STATUS script. ##
29295 ## ----------------------------------- ##
29296 _ASEOF
29297 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
29299 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29300 # Save the log message, to keep $0 and so on meaningful, and to
29301 # report actual input values of CONFIG_FILES etc. instead of their
29302 # values after options handling.
29303 ac_log="
29304 This file was extended by emacs $as_me 24.3.50, which was
29305 generated by GNU Autoconf 2.65. Invocation command line was
29307 CONFIG_FILES = $CONFIG_FILES
29308 CONFIG_HEADERS = $CONFIG_HEADERS
29309 CONFIG_LINKS = $CONFIG_LINKS
29310 CONFIG_COMMANDS = $CONFIG_COMMANDS
29311 $ $0 $@
29313 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29316 _ACEOF
29318 case $ac_config_files in *"
29319 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29320 esac
29322 case $ac_config_headers in *"
29323 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29324 esac
29327 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29328 # Files that config.status was made for.
29329 config_files="$ac_config_files"
29330 config_headers="$ac_config_headers"
29331 config_commands="$ac_config_commands"
29333 _ACEOF
29335 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29336 ac_cs_usage="\
29337 \`$as_me' instantiates files and other configuration actions
29338 from templates according to the current configuration. Unless the files
29339 and actions are specified as TAGs, all are instantiated by default.
29341 Usage: $0 [OPTION]... [TAG]...
29343 -h, --help print this help, then exit
29344 -V, --version print version number and configuration settings, then exit
29345 --config print configuration, then exit
29346 -q, --quiet, --silent
29347 do not print progress messages
29348 -d, --debug don't remove temporary files
29349 --recheck update $as_me by reconfiguring in the same conditions
29350 --file=FILE[:TEMPLATE]
29351 instantiate the configuration file FILE
29352 --header=FILE[:TEMPLATE]
29353 instantiate the configuration header FILE
29355 Configuration files:
29356 $config_files
29358 Configuration headers:
29359 $config_headers
29361 Configuration commands:
29362 $config_commands
29364 Report bugs to the package provider."
29366 _ACEOF
29367 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29368 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
29369 ac_cs_version="\\
29370 emacs config.status 24.3.50
29371 configured by $0, generated by GNU Autoconf 2.65,
29372 with options \\"\$ac_cs_config\\"
29374 Copyright (C) 2009 Free Software Foundation, Inc.
29375 This config.status script is free software; the Free Software Foundation
29376 gives unlimited permission to copy, distribute and modify it."
29378 ac_pwd='$ac_pwd'
29379 srcdir='$srcdir'
29380 INSTALL='$INSTALL'
29381 MKDIR_P='$MKDIR_P'
29382 AWK='$AWK'
29383 test -n "\$AWK" || AWK=awk
29384 _ACEOF
29386 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29387 # The default lists apply if the user does not specify any file.
29388 ac_need_defaults=:
29389 while test $# != 0
29391 case $1 in
29392 --*=*)
29393 ac_option=`expr "X$1" : 'X\([^=]*\)='`
29394 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29395 ac_shift=:
29398 ac_option=$1
29399 ac_optarg=$2
29400 ac_shift=shift
29402 esac
29404 case $ac_option in
29405 # Handling of the options.
29406 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29407 ac_cs_recheck=: ;;
29408 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29409 $as_echo "$ac_cs_version"; exit ;;
29410 --config | --confi | --conf | --con | --co | --c )
29411 $as_echo "$ac_cs_config"; exit ;;
29412 --debug | --debu | --deb | --de | --d | -d )
29413 debug=: ;;
29414 --file | --fil | --fi | --f )
29415 $ac_shift
29416 case $ac_optarg in
29417 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29418 esac
29419 as_fn_append CONFIG_FILES " '$ac_optarg'"
29420 ac_need_defaults=false;;
29421 --header | --heade | --head | --hea )
29422 $ac_shift
29423 case $ac_optarg in
29424 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29425 esac
29426 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
29427 ac_need_defaults=false;;
29428 --he | --h)
29429 # Conflict between --help and --header
29430 as_fn_error "ambiguous option: \`$1'
29431 Try \`$0 --help' for more information.";;
29432 --help | --hel | -h )
29433 $as_echo "$ac_cs_usage"; exit ;;
29434 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29435 | -silent | --silent | --silen | --sile | --sil | --si | --s)
29436 ac_cs_silent=: ;;
29438 # This is an error.
29439 -*) as_fn_error "unrecognized option: \`$1'
29440 Try \`$0 --help' for more information." ;;
29442 *) as_fn_append ac_config_targets " $1"
29443 ac_need_defaults=false ;;
29445 esac
29446 shift
29447 done
29449 ac_configure_extra_args=
29451 if $ac_cs_silent; then
29452 exec 6>/dev/null
29453 ac_configure_extra_args="$ac_configure_extra_args --silent"
29456 _ACEOF
29457 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29458 if \$ac_cs_recheck; then
29459 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29460 shift
29461 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29462 CONFIG_SHELL='$SHELL'
29463 export CONFIG_SHELL
29464 exec "\$@"
29467 _ACEOF
29468 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29469 exec 5>>config.log
29471 echo
29472 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29473 ## Running $as_me. ##
29474 _ASBOX
29475 $as_echo "$ac_log"
29476 } >&5
29478 _ACEOF
29479 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29481 # INIT-COMMANDS
29483 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
29484 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
29486 _ACEOF
29488 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29490 # Handling of arguments.
29491 for ac_config_target in $ac_config_targets
29493 case $ac_config_target in
29494 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
29495 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
29496 "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" ;;
29497 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
29498 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
29499 "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" ;;
29500 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
29501 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
29502 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
29503 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
29504 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
29505 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
29506 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
29507 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
29508 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
29509 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
29510 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
29511 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
29512 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
29513 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
29514 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
29515 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
29516 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
29517 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
29518 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
29520 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
29521 esac
29522 done
29525 # If the user did not use the arguments to specify the items to instantiate,
29526 # then the envvar interface is used. Set only those that are not.
29527 # We use the long form for the default assignment because of an extremely
29528 # bizarre bug on SunOS 4.1.3.
29529 if $ac_need_defaults; then
29530 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29531 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29532 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29535 # Have a temporary directory for convenience. Make it in the build tree
29536 # simply because there is no reason against having it here, and in addition,
29537 # creating and moving files from /tmp can sometimes cause problems.
29538 # Hook for its removal unless debugging.
29539 # Note that there is a small window in which the directory will not be cleaned:
29540 # after its creation but before its name has been assigned to `$tmp'.
29541 $debug ||
29543 tmp=
29544 trap 'exit_status=$?
29545 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29547 trap 'as_fn_exit 1' 1 2 13 15
29549 # Create a (secure) tmp directory for tmp files.
29552 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29553 test -n "$tmp" && test -d "$tmp"
29554 } ||
29556 tmp=./conf$$-$RANDOM
29557 (umask 077 && mkdir "$tmp")
29558 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
29560 # Set up the scripts for CONFIG_FILES section.
29561 # No need to generate them if there are no CONFIG_FILES.
29562 # This happens for instance with `./config.status config.h'.
29563 if test -n "$CONFIG_FILES"; then
29565 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
29566 ac_cs_awk_getline=:
29567 ac_cs_awk_pipe_init=
29568 ac_cs_awk_read_file='
29569 while ((getline aline < (F[key])) > 0)
29570 print(aline)
29571 close(F[key])'
29572 ac_cs_awk_pipe_fini=
29573 else
29574 ac_cs_awk_getline=false
29575 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
29576 ac_cs_awk_read_file='
29577 print "|#_!!_#|"
29578 print "cat " F[key] " &&"
29579 '$ac_cs_awk_pipe_init
29580 # The final `:' finishes the AND list.
29581 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
29583 ac_cr=`echo X | tr X '\015'`
29584 # On cygwin, bash can eat \r inside `` if the user requested igncr.
29585 # But we know of no other shell where ac_cr would be empty at this
29586 # point, so we can use a bashism as a fallback.
29587 if test "x$ac_cr" = x; then
29588 eval ac_cr=\$\'\\r\'
29590 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
29591 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
29592 ac_cs_awk_cr='\r'
29593 else
29594 ac_cs_awk_cr=$ac_cr
29597 echo 'BEGIN {' >"$tmp/subs1.awk" &&
29598 _ACEOF
29600 # Create commands to substitute file output variables.
29602 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
29603 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
29604 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
29605 echo "_ACAWK" &&
29606 echo "_ACEOF"
29607 } >conf$$files.sh &&
29608 . ./conf$$files.sh ||
29609 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29610 rm -f conf$$files.sh
29613 echo "cat >conf$$subs.awk <<_ACEOF" &&
29614 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
29615 echo "_ACEOF"
29616 } >conf$$subs.sh ||
29617 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29618 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
29619 ac_delim='%!_!# '
29620 for ac_last_try in false false false false false :; do
29621 . ./conf$$subs.sh ||
29622 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29624 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
29625 if test $ac_delim_n = $ac_delim_num; then
29626 break
29627 elif $ac_last_try; then
29628 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
29629 else
29630 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29632 done
29633 rm -f conf$$subs.sh
29635 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29636 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
29637 _ACEOF
29638 sed -n '
29640 s/^/S["/; s/!.*/"]=/
29643 s/^[^!]*!//
29644 :repl
29645 t repl
29646 s/'"$ac_delim"'$//
29647 t delim
29650 s/\(.\{148\}\)..*/\1/
29651 t more1
29652 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
29655 b repl
29656 :more1
29657 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29660 s/.\{148\}//
29661 t nl
29662 :delim
29664 s/\(.\{148\}\)..*/\1/
29665 t more2
29666 s/["\\]/\\&/g; s/^/"/; s/$/"/
29669 :more2
29670 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29673 s/.\{148\}//
29674 t delim
29675 ' <conf$$subs.awk | sed '
29676 /^[^""]/{
29678 s/\n//
29680 ' >>$CONFIG_STATUS || ac_write_fail=1
29681 rm -f conf$$subs.awk
29682 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29683 _ACAWK
29684 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
29685 for (key in S) S_is_set[key] = 1
29686 FS = "\a"
29687 \$ac_cs_awk_pipe_init
29690 line = $ 0
29691 nfields = split(line, field, "@")
29692 substed = 0
29693 len = length(field[1])
29694 for (i = 2; i < nfields; i++) {
29695 key = field[i]
29696 keylen = length(key)
29697 if (S_is_set[key]) {
29698 value = S[key]
29699 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
29700 len += length(value) + length(field[++i])
29701 substed = 1
29702 } else
29703 len += 1 + keylen
29705 if (nfields == 3 && !substed) {
29706 key = field[2]
29707 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
29708 \$ac_cs_awk_read_file
29709 next
29712 print line
29714 \$ac_cs_awk_pipe_fini
29715 _ACAWK
29716 _ACEOF
29717 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29718 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
29719 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
29720 else
29722 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
29723 || as_fn_error "could not setup config files machinery" "$LINENO" 5
29724 _ACEOF
29726 # VPATH may cause trouble with some makes, so we remove $(srcdir),
29727 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
29728 # trailing colons and then remove the whole line if VPATH becomes empty
29729 # (actually we leave an empty line to preserve line numbers).
29730 if test "x$srcdir" = x.; then
29731 ac_vpsub='/^[ ]*VPATH[ ]*=/{
29732 s/:*\$(srcdir):*/:/
29733 s/:*\${srcdir}:*/:/
29734 s/:*@srcdir@:*/:/
29735 s/^\([^=]*=[ ]*\):*/\1/
29736 s/:*$//
29737 s/^[^=]*=[ ]*$//
29741 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29742 fi # test -n "$CONFIG_FILES"
29744 # Set up the scripts for CONFIG_HEADERS section.
29745 # No need to generate them if there are no CONFIG_HEADERS.
29746 # This happens for instance with `./config.status Makefile'.
29747 if test -n "$CONFIG_HEADERS"; then
29748 cat >"$tmp/defines.awk" <<\_ACAWK ||
29749 BEGIN {
29750 _ACEOF
29752 # Transform confdefs.h into an awk script `defines.awk', embedded as
29753 # here-document in config.status, that substitutes the proper values into
29754 # config.h.in to produce config.h.
29756 # Create a delimiter string that does not exist in confdefs.h, to ease
29757 # handling of long lines.
29758 ac_delim='%!_!# '
29759 for ac_last_try in false false :; do
29760 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
29761 if test -z "$ac_t"; then
29762 break
29763 elif $ac_last_try; then
29764 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
29765 else
29766 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29768 done
29770 # For the awk script, D is an array of macro values keyed by name,
29771 # likewise P contains macro parameters if any. Preserve backslash
29772 # newline sequences.
29774 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
29775 sed -n '
29776 s/.\{148\}/&'"$ac_delim"'/g
29777 t rset
29778 :rset
29779 s/^[ ]*#[ ]*define[ ][ ]*/ /
29780 t def
29782 :def
29783 s/\\$//
29784 t bsnl
29785 s/["\\]/\\&/g
29786 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
29787 D["\1"]=" \3"/p
29788 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
29790 :bsnl
29791 s/["\\]/\\&/g
29792 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
29793 D["\1"]=" \3\\\\\\n"\\/p
29794 t cont
29795 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
29796 t cont
29798 :cont
29800 s/.\{148\}/&'"$ac_delim"'/g
29801 t clear
29802 :clear
29803 s/\\$//
29804 t bsnlc
29805 s/["\\]/\\&/g; s/^/"/; s/$/"/p
29807 :bsnlc
29808 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
29809 b cont
29810 ' <confdefs.h | sed '
29811 s/'"$ac_delim"'/"\\\
29812 "/g' >>$CONFIG_STATUS || ac_write_fail=1
29814 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29815 for (key in D) D_is_set[key] = 1
29816 FS = "\a"
29818 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
29819 line = \$ 0
29820 split(line, arg, " ")
29821 if (arg[1] == "#") {
29822 defundef = arg[2]
29823 mac1 = arg[3]
29824 } else {
29825 defundef = substr(arg[1], 2)
29826 mac1 = arg[2]
29828 split(mac1, mac2, "(") #)
29829 macro = mac2[1]
29830 prefix = substr(line, 1, index(line, defundef) - 1)
29831 if (D_is_set[macro]) {
29832 # Preserve the white space surrounding the "#".
29833 print prefix "define", macro P[macro] D[macro]
29834 next
29835 } else {
29836 # Replace #undef with comments. This is necessary, for example,
29837 # in the case of _POSIX_SOURCE, which is predefined and required
29838 # on some systems where configure will not decide to define it.
29839 if (defundef == "undef") {
29840 print "/*", prefix defundef, macro, "*/"
29841 next
29845 { print }
29846 _ACAWK
29847 _ACEOF
29848 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29849 as_fn_error "could not setup config headers machinery" "$LINENO" 5
29850 fi # test -n "$CONFIG_HEADERS"
29853 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
29854 shift
29855 for ac_tag
29857 case $ac_tag in
29858 :[FHLC]) ac_mode=$ac_tag; continue;;
29859 esac
29860 case $ac_mode$ac_tag in
29861 :[FHL]*:*);;
29862 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
29863 :[FH]-) ac_tag=-:-;;
29864 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
29865 esac
29866 ac_save_IFS=$IFS
29867 IFS=:
29868 set x $ac_tag
29869 IFS=$ac_save_IFS
29870 shift
29871 ac_file=$1
29872 shift
29874 case $ac_mode in
29875 :L) ac_source=$1;;
29876 :[FH])
29877 ac_file_inputs=
29878 for ac_f
29880 case $ac_f in
29881 -) ac_f="$tmp/stdin";;
29882 *) # Look for the file first in the build tree, then in the source tree
29883 # (if the path is not absolute). The absolute path cannot be DOS-style,
29884 # because $ac_f cannot contain `:'.
29885 test -f "$ac_f" ||
29886 case $ac_f in
29887 [\\/$]*) false;;
29888 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
29889 esac ||
29890 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
29891 esac
29892 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
29893 as_fn_append ac_file_inputs " '$ac_f'"
29894 done
29896 # Let's still pretend it is `configure' which instantiates (i.e., don't
29897 # use $as_me), people would be surprised to read:
29898 # /* config.h. Generated by config.status. */
29899 configure_input='Generated from '`
29900 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
29901 `' by configure.'
29902 if test x"$ac_file" != x-; then
29903 configure_input="$ac_file. $configure_input"
29904 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
29905 $as_echo "$as_me: creating $ac_file" >&6;}
29907 # Neutralize special characters interpreted by sed in replacement strings.
29908 case $configure_input in #(
29909 *\&* | *\|* | *\\* )
29910 ac_sed_conf_input=`$as_echo "$configure_input" |
29911 sed 's/[\\\\&|]/\\\\&/g'`;; #(
29912 *) ac_sed_conf_input=$configure_input;;
29913 esac
29915 case $ac_tag in
29916 *:-:* | *:-) cat >"$tmp/stdin" \
29917 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
29918 esac
29920 esac
29922 ac_dir=`$as_dirname -- "$ac_file" ||
29923 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29924 X"$ac_file" : 'X\(//\)[^/]' \| \
29925 X"$ac_file" : 'X\(//\)$' \| \
29926 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
29927 $as_echo X"$ac_file" |
29928 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29929 s//\1/
29932 /^X\(\/\/\)[^/].*/{
29933 s//\1/
29936 /^X\(\/\/\)$/{
29937 s//\1/
29940 /^X\(\/\).*/{
29941 s//\1/
29944 s/.*/./; q'`
29945 as_dir="$ac_dir"; as_fn_mkdir_p
29946 ac_builddir=.
29948 case "$ac_dir" in
29949 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
29951 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
29952 # A ".." for each directory in $ac_dir_suffix.
29953 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
29954 case $ac_top_builddir_sub in
29955 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
29956 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
29957 esac ;;
29958 esac
29959 ac_abs_top_builddir=$ac_pwd
29960 ac_abs_builddir=$ac_pwd$ac_dir_suffix
29961 # for backward compatibility:
29962 ac_top_builddir=$ac_top_build_prefix
29964 case $srcdir in
29965 .) # We are building in place.
29966 ac_srcdir=.
29967 ac_top_srcdir=$ac_top_builddir_sub
29968 ac_abs_top_srcdir=$ac_pwd ;;
29969 [\\/]* | ?:[\\/]* ) # Absolute name.
29970 ac_srcdir=$srcdir$ac_dir_suffix;
29971 ac_top_srcdir=$srcdir
29972 ac_abs_top_srcdir=$srcdir ;;
29973 *) # Relative name.
29974 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
29975 ac_top_srcdir=$ac_top_build_prefix$srcdir
29976 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
29977 esac
29978 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
29981 case $ac_mode in
29984 # CONFIG_FILE
29987 case $INSTALL in
29988 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
29989 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
29990 esac
29991 ac_MKDIR_P=$MKDIR_P
29992 case $MKDIR_P in
29993 [\\/$]* | ?:[\\/]* ) ;;
29994 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
29995 esac
29996 _ACEOF
29998 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29999 # If the template does not know about datarootdir, expand it.
30000 # FIXME: This hack should be removed a few years after 2.60.
30001 ac_datarootdir_hack=; ac_datarootdir_seen=
30002 ac_sed_dataroot='
30003 /datarootdir/ {
30007 /@datadir@/p
30008 /@docdir@/p
30009 /@infodir@/p
30010 /@localedir@/p
30011 /@mandir@/p'
30012 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30013 *datarootdir*) ac_datarootdir_seen=yes;;
30014 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30015 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30016 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30017 _ACEOF
30018 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30019 ac_datarootdir_hack='
30020 s&@datadir@&$datadir&g
30021 s&@docdir@&$docdir&g
30022 s&@infodir@&$infodir&g
30023 s&@localedir@&$localedir&g
30024 s&@mandir@&$mandir&g
30025 s&\\\${datarootdir}&$datarootdir&g' ;;
30026 esac
30027 _ACEOF
30029 # Neutralize VPATH when `$srcdir' = `.'.
30030 # Shell code in configure.ac might set extrasub.
30031 # FIXME: do we really want to maintain this feature?
30032 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30033 ac_sed_extra="$ac_vpsub
30034 $extrasub
30035 _ACEOF
30036 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30038 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30039 s|@configure_input@|$ac_sed_conf_input|;t t
30040 s&@top_builddir@&$ac_top_builddir_sub&;t t
30041 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30042 s&@srcdir@&$ac_srcdir&;t t
30043 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30044 s&@top_srcdir@&$ac_top_srcdir&;t t
30045 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30046 s&@builddir@&$ac_builddir&;t t
30047 s&@abs_builddir@&$ac_abs_builddir&;t t
30048 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30049 s&@INSTALL@&$ac_INSTALL&;t t
30050 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30051 $ac_datarootdir_hack
30053 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30054 if $ac_cs_awk_getline; then
30055 $AWK -f "$tmp/subs.awk"
30056 else
30057 $AWK -f "$tmp/subs.awk" | $SHELL
30058 fi >$tmp/out \
30059 || as_fn_error "could not create $ac_file" "$LINENO" 5
30061 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30062 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30063 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30064 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30065 which seems to be undefined. Please make sure it is defined." >&5
30066 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30067 which seems to be undefined. Please make sure it is defined." >&2;}
30069 rm -f "$tmp/stdin"
30070 case $ac_file in
30071 -) cat "$tmp/out" && rm -f "$tmp/out";;
30072 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30073 esac \
30074 || as_fn_error "could not create $ac_file" "$LINENO" 5
30078 # CONFIG_HEADER
30080 if test x"$ac_file" != x-; then
30082 $as_echo "/* $configure_input */" \
30083 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30084 } >"$tmp/config.h" \
30085 || as_fn_error "could not create $ac_file" "$LINENO" 5
30086 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30087 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30088 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30089 else
30090 rm -f "$ac_file"
30091 mv "$tmp/config.h" "$ac_file" \
30092 || as_fn_error "could not create $ac_file" "$LINENO" 5
30094 else
30095 $as_echo "/* $configure_input */" \
30096 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30097 || as_fn_error "could not create -" "$LINENO" 5
30099 # Compute "$ac_file"'s index in $config_headers.
30100 _am_arg="$ac_file"
30101 _am_stamp_count=1
30102 for _am_header in $config_headers :; do
30103 case $_am_header in
30104 $_am_arg | $_am_arg:* )
30105 break ;;
30107 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
30108 esac
30109 done
30110 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
30111 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30112 X"$_am_arg" : 'X\(//\)[^/]' \| \
30113 X"$_am_arg" : 'X\(//\)$' \| \
30114 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
30115 $as_echo X"$_am_arg" |
30116 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30117 s//\1/
30120 /^X\(\/\/\)[^/].*/{
30121 s//\1/
30124 /^X\(\/\/\)$/{
30125 s//\1/
30128 /^X\(\/\).*/{
30129 s//\1/
30132 s/.*/./; q'`/stamp-h$_am_stamp_count
30135 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
30136 $as_echo "$as_me: executing $ac_file commands" >&6;}
30138 esac
30141 case $ac_file$ac_mode in
30142 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
30143 # Autoconf 2.62 quotes --file arguments for eval, but not when files
30144 # are listed without --file. Let's play safe and only enable the eval
30145 # if we detect the quoting.
30146 case $CONFIG_FILES in
30147 *\'*) eval set x "$CONFIG_FILES" ;;
30148 *) set x $CONFIG_FILES ;;
30149 esac
30150 shift
30151 for mf
30153 # Strip MF so we end up with the name of the file.
30154 mf=`echo "$mf" | sed -e 's/:.*$//'`
30155 # Check whether this is an Automake generated Makefile or not.
30156 # We used to match only the files named `Makefile.in', but
30157 # some people rename them; so instead we look at the file content.
30158 # Grep'ing the first line is not enough: some people post-process
30159 # each Makefile.in and add a new line on top of each file to say so.
30160 # Grep'ing the whole file is not good either: AIX grep has a line
30161 # limit of 2048, but all sed's we know have understand at least 4000.
30162 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
30163 dirpart=`$as_dirname -- "$mf" ||
30164 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30165 X"$mf" : 'X\(//\)[^/]' \| \
30166 X"$mf" : 'X\(//\)$' \| \
30167 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
30168 $as_echo X"$mf" |
30169 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30170 s//\1/
30173 /^X\(\/\/\)[^/].*/{
30174 s//\1/
30177 /^X\(\/\/\)$/{
30178 s//\1/
30181 /^X\(\/\).*/{
30182 s//\1/
30185 s/.*/./; q'`
30186 else
30187 continue
30189 # Extract the definition of DEPDIR, am__include, and am__quote
30190 # from the Makefile without running `make'.
30191 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
30192 test -z "$DEPDIR" && continue
30193 am__include=`sed -n 's/^am__include = //p' < "$mf"`
30194 test -z "am__include" && continue
30195 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
30196 # When using ansi2knr, U may be empty or an underscore; expand it
30197 U=`sed -n 's/^U = //p' < "$mf"`
30198 # Find all dependency output files, they are included files with
30199 # $(DEPDIR) in their names. We invoke sed twice because it is the
30200 # simplest approach to changing $(DEPDIR) to its actual value in the
30201 # expansion.
30202 for file in `sed -n "
30203 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
30204 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
30205 # Make sure the directory exists.
30206 test -f "$dirpart/$file" && continue
30207 fdir=`$as_dirname -- "$file" ||
30208 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30209 X"$file" : 'X\(//\)[^/]' \| \
30210 X"$file" : 'X\(//\)$' \| \
30211 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
30212 $as_echo X"$file" |
30213 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30214 s//\1/
30217 /^X\(\/\/\)[^/].*/{
30218 s//\1/
30221 /^X\(\/\/\)$/{
30222 s//\1/
30225 /^X\(\/\).*/{
30226 s//\1/
30229 s/.*/./; q'`
30230 as_dir=$dirpart/$fdir; as_fn_mkdir_p
30231 # echo "creating $dirpart/$file"
30232 echo '# dummy' > "$dirpart/$file"
30233 done
30234 done
30237 "mkdirs":C)
30238 for dir in etc lisp ; do
30239 test -d ${dir} || mkdir ${dir}
30240 done
30242 "epaths":C)
30243 echo creating src/epaths.h
30244 if test "${opsys}" = "mingw32"; then
30245 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
30246 else
30247 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
30250 "gdbinit":C)
30251 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
30252 echo creating src/.gdbinit
30253 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
30257 esac
30258 done # for ac_tag
30261 as_fn_exit 0
30262 _ACEOF
30263 ac_clean_files=$ac_clean_files_save
30265 test $ac_write_fail = 0 ||
30266 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
30269 # configure is writing to config.log, and then calls config.status.
30270 # config.status does its own redirection, appending to config.log.
30271 # Unfortunately, on DOS this fails, as config.log is still kept open
30272 # by configure, so config.status won't be able to write to it; its
30273 # output is simply discarded. So we exec the FD to /dev/null,
30274 # effectively closing config.log, so it can be properly (re)opened and
30275 # appended to by config.status. When coming back to configure, we
30276 # need to make the FD available again.
30277 if test "$no_create" != yes; then
30278 ac_cs_success=:
30279 ac_config_status_args=
30280 test "$silent" = yes &&
30281 ac_config_status_args="$ac_config_status_args --quiet"
30282 exec 5>/dev/null
30283 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30284 exec 5>>config.log
30285 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30286 # would make configure fail if this is the last instruction.
30287 $ac_cs_success || as_fn_exit $?
30289 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30290 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30291 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}